From a4d8bde54d99790691c7a457633d098bf63617a9 Mon Sep 17 00:00:00 2001 From: Marius Gudauskis Date: Tue, 12 May 2020 16:24:24 +0300 Subject: [PATCH 1/4] prestashop validator fixes --- config/service.yml | 2 - mollie.php | 16 ------ src/Builder/FormBuilder.php | 7 +-- src/Service/CarrierService.php | 54 ------------------- src/Service/IssuerService.php | 1 + src/Service/PaymentMethodService.php | 2 +- src/Service/ShipmentService.php | 2 +- upgrade/Upgrade-4.0.0.php | 1 + .../config/Tests/Fixtures/ParseError.php | 1 + .../admin/_configure/helpers/form/form.tpl | 6 ++- 10 files changed, 13 insertions(+), 79 deletions(-) delete mode 100644 src/Service/CarrierService.php diff --git a/config/service.yml b/config/service.yml index 007e53445..d61a16782 100644 --- a/config/service.yml +++ b/config/service.yml @@ -40,8 +40,6 @@ services: arguments: - '@mollie' - Mollie\Service\CarrierService: - Mollie\Service\OrderStatusService: Mollie\Service\CountryService: diff --git a/mollie.php b/mollie.php index be5a65493..4f14c52ea 100644 --- a/mollie.php +++ b/mollie.php @@ -958,22 +958,6 @@ public function displayAjaxMollieMethodConfig() ]; } - /** - * @return array - * @throws PrestaShopException - * - * @since 3.3.0 - */ - public function displayAjaxMollieCarrierConfig() - { - header('Content-Type: application/json;charset=UTF-8'); - /** @var \Mollie\Service\CarrierService $carrierService */ - $carrierService = $this->getContainer(\Mollie\Service\CarrierService::class); - $dbConfig = @json_decode(Configuration::get(Mollie\Config\Config::MOLLIE_TRACKING_URLS), true); - - return ['success' => true, 'carriers' => $carrierService->carrierConfig($dbConfig)]; - } - /** * @return array * @throws Adapter_Exception diff --git a/src/Builder/FormBuilder.php b/src/Builder/FormBuilder.php index 7e19c4bea..7ec2258de 100644 --- a/src/Builder/FormBuilder.php +++ b/src/Builder/FormBuilder.php @@ -1,6 +1,6 @@ $this->module->display( - $this->module->getPathUri() , 'views/templates/admin/create_new_account_link.tpl' + $this->module->getPathUri(), 'views/templates/admin/create_new_account_link.tpl' ), ], [ @@ -209,7 +209,8 @@ protected function getAccountSettingsSection($isApiKeyProvided) 'class' => 'fixed-width-xxl', ]; - $input = array_merge($input, [ + $input = array_merge($input, + [ [ 'type' => 'mollie-h3', 'tab' => $generalSettings, diff --git a/src/Service/CarrierService.php b/src/Service/CarrierService.php deleted file mode 100644 index acd98033b..000000000 --- a/src/Service/CarrierService.php +++ /dev/null @@ -1,54 +0,0 @@ -language->id, - false, - false, - false, - null, - Carrier::ALL_CARRIERS - ); - - $configCarriers = []; - foreach ($carriers as $carrier) { - $idCarrier = (int)$carrier['id_carrier']; - $configCarriers[] = [ - 'id_carrier' => $idCarrier, - 'name' => $carrier['name'], - 'source' => isset($dbConfig[$idCarrier]) ? $trackingUrls[$idCarrier]['source'] : ($carrier['external_module_name'] ? Config::MOLLIE_CARRIER_MODULE : Config::MOLLIE_CARRIER_CARRIER), - 'module' => !empty($carrier['external_module_name']) ? $carrier['external_module_name'] : null, - 'module_name' => !empty($carrier['external_module_name']) ? $carrier['external_module_name'] : null, - 'custom_url' => isset($dbConfig[$idCarrier]) ? $trackingUrls[$idCarrier]['custom_url'] : '', - ]; - } - if (count($trackingUrls) !== count($configCarriers)) { - Configuration::updateValue(Config::MOLLIE_TRACKING_URLS, json_encode($configCarriers)); - } - - return $configCarriers; - } -} \ No newline at end of file diff --git a/src/Service/IssuerService.php b/src/Service/IssuerService.php index 2f67c0fcb..bb3daabf8 100644 --- a/src/Service/IssuerService.php +++ b/src/Service/IssuerService.php @@ -29,6 +29,7 @@ public function getIdealIssuers() $methodId = $this->paymentMethodRepository->getPaymentMethodIdByMethodId(PaymentMethod::IDEAL); $issuersJson = $this->paymentMethodRepository->getPaymentMethodIssuersByPaymentMethodId($methodId); $issuers = json_decode($issuersJson, true); + $issuerList = []; $issuerList[PaymentMethod::IDEAL] = []; $context = Context::getContext(); foreach ($issuers as $issuer) { diff --git a/src/Service/PaymentMethodService.php b/src/Service/PaymentMethodService.php index aa772ce78..d5a7d9141 100644 --- a/src/Service/PaymentMethodService.php +++ b/src/Service/PaymentMethodService.php @@ -125,7 +125,7 @@ public function getMethodsForCheckout() if ($methodObj->id_method === Mollie\Config\Config::APPLEPAY) { if (!Configuration::get('PS_SSL_ENABLED_EVERYWHERE')) { unset($methods[$index]); - } elseif ($_COOKIE['isApplePayMethod'] === '0') { + } elseif (Context::getContext()->cookie->isApplePayMethod === '0') { unset($methods[$index]); } } diff --git a/src/Service/ShipmentService.php b/src/Service/ShipmentService.php index 2c0f95d91..14c3c2420 100644 --- a/src/Service/ShipmentService.php +++ b/src/Service/ShipmentService.php @@ -152,7 +152,7 @@ public function getShipmentInformation($orderReference) 'url' => str_ireplace( array_keys($info), array_values($info), - $carrierInformation->url_source + $carrierInformation->custom_url ), ], ]; diff --git a/upgrade/Upgrade-4.0.0.php b/upgrade/Upgrade-4.0.0.php index f609e9780..25eb9c398 100644 --- a/upgrade/Upgrade-4.0.0.php +++ b/upgrade/Upgrade-4.0.0.php @@ -42,6 +42,7 @@ */ function upgrade_module_4_0_0() { + $sql = []; $sql[] = 'CREATE TABLE IF NOT EXISTS `' . _DB_PREFIX_ . 'mol_payment_method` ( `id_payment_method` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, `id_method` VARCHAR(64) NOT NULL, diff --git a/vendor/symfony/config/Tests/Fixtures/ParseError.php b/vendor/symfony/config/Tests/Fixtures/ParseError.php index 6bb221382..cb066448c 100644 --- a/vendor/symfony/config/Tests/Fixtures/ParseError.php +++ b/vendor/symfony/config/Tests/Fixtures/ParseError.php @@ -5,3 +5,4 @@ class ParseError { // missing closing bracket +} \ No newline at end of file diff --git a/views/templates/admin/_configure/helpers/form/form.tpl b/views/templates/admin/_configure/helpers/form/form.tpl index a86cbead0..765e88a77 100644 --- a/views/templates/admin/_configure/helpers/form/form.tpl +++ b/views/templates/admin/_configure/helpers/form/form.tpl @@ -259,9 +259,11 @@ From f9a47a8be8e5202999e5058e5ea9a913a6928709 Mon Sep 17 00:00:00 2001 From: Marius Gudauskis Date: Wed, 13 May 2020 15:12:29 +0300 Subject: [PATCH 2/4] added index files and licences --- config/index.php | 36 +++++++++ controllers/front/ajax.php | 6 +- controllers/front/fail.php | 7 +- mollie.php | 11 --- src/Builder/FormBuilder.php | 76 ++++++++++++++----- .../Builder/index.php | 34 ++++----- src/Config/Config.php | 33 ++++++++ src/Config/index.php | 44 +++++++++++ src/Entity/MolCarrierInformation.php | 33 ++++++++ src/Entity/MolOrderFee.php | 33 ++++++++ src/Entity/MolPaymentMethod.php | 33 ++++++++ src/Entity/MolPaymentMethodIssuer.php | 33 ++++++++ src/Entity/index.php | 44 +++++++++++ src/Factory/ContextFactory.php | 42 ++++++---- src/Factory/index.php | 44 +++++++++++ src/Install/Installer.php | 42 +++++++++- src/Install/Uninstall.php | 33 ++++++++ src/Install/index.php | 44 +++++++++++ src/Repository/CountryRepository.php | 33 ++++++++ src/Repository/MethodCountryRepository.php | 33 ++++++++ src/Repository/ModuleRepository.php | 33 ++++++++ .../MolCarrierInformationRepository.php | 34 +++++++++ src/Repository/OrderFeeRepository.php | 33 ++++++++ src/Repository/OrderShipmentRepository.php | 33 ++++++++ src/Repository/PaymentMethodRepository.php | 33 ++++++++ src/Repository/index.php | 44 +++++++++++ src/Service/ApiService.php | 65 ++++++++++++---- src/Service/CancelService.php | 45 ++++++++++- src/Service/CartLinesService.php | 38 +++++++++- src/Service/ConfigFieldService.php | 33 ++++++++ src/Service/CountryService.php | 33 ++++++++ src/Service/IssuerService.php | 33 ++++++++ src/Service/LanguageService.php | 33 ++++++++ src/Service/MolCarrierInformationService.php | 33 ++++++++ src/Service/MollieOrderInfoService.php | 33 ++++++++ src/Service/OrderFeeService.php | 36 ++++++++- src/Service/OrderStatusService.php | 39 +++++++++- src/Service/PaymentMethodService.php | 55 ++++++++++++-- src/Service/RefundService.php | 52 +++++++++++-- src/Service/SettingsSaveService.php | 41 +++++++++- src/Service/ShipService.php | 33 ++++++++ src/Service/ShipmentService.php | 39 +++++++++- src/Service/UrlPathService.php | 33 ++++++++ src/Service/index.php | 44 +++++++++++ src/Utility/AssortUtility.php | 33 ++++++++ src/Utility/CartPriceUtility.php | 33 ++++++++ src/Utility/EnvironmentUtility.php | 33 ++++++++ src/Utility/ImageUtility.php | 33 ++++++++ src/Utility/LocaleUtility.php | 33 ++++++++ src/Utility/MenuLocationUtility.php | 43 ++++++++++- src/Utility/PaymentFeeUtility.php | 33 ++++++++ src/Utility/TagsUtility.php | 33 ++++++++ src/Utility/TextGeneratorUtility.php | 33 ++++++++ src/Utility/UrlPathUtility.php | 35 ++++++++- src/Utility/index.php | 44 +++++++++++ src/index.php | 44 +++++++++++ vendor/composer/ca-bundle/index.php | 36 +++++++++ vendor/composer/ca-bundle/res/index.php | 36 +++++++++ vendor/composer/ca-bundle/src/index.php | 36 +++++++++ vendor/composer/index.php | 36 +++++++++ vendor/guzzlehttp/guzzle/index.php | 36 +++++++++ vendor/guzzlehttp/guzzle/src/Cookie/index.php | 36 +++++++++ .../guzzlehttp/guzzle/src/Exception/index.php | 36 +++++++++ .../guzzlehttp/guzzle/src/Handler/index.php | 36 +++++++++ vendor/guzzlehttp/guzzle/src/index.php | 36 +++++++++ vendor/guzzlehttp/index.php | 36 +++++++++ vendor/guzzlehttp/promises/index.php | 36 +++++++++ vendor/guzzlehttp/promises/src/index.php | 36 +++++++++ vendor/guzzlehttp/psr7/index.php | 36 +++++++++ vendor/guzzlehttp/psr7/src/index.php | 36 +++++++++ vendor/index.php | 36 +++++++++ vendor/mollie/index.php | 36 +++++++++ .../examples/captures/index.php | 36 +++++++++ .../examples/customers/index.php | 36 +++++++++ .../mollie/mollie-api-php/examples/index.php | 36 +++++++++ .../examples/invoices/index.php | 36 +++++++++ .../examples/mandates/index.php | 36 +++++++++ .../mollie-api-php/examples/orders/index.php | 36 +++++++++ .../examples/payments/index.php | 36 +++++++++ .../examples/profiles/index.php | 36 +++++++++ .../examples/settlements/index.php | 36 +++++++++ .../examples/shipments/index.php | 36 +++++++++ .../examples/subscriptions/index.php | 36 +++++++++ vendor/mollie/mollie-api-php/index.php | 36 +++++++++ .../mollie-api-php/src/Endpoints/index.php | 36 +++++++++ .../mollie-api-php/src/Exceptions/index.php | 36 +++++++++ .../mollie-api-php/src/Resources/index.php | 36 +++++++++ .../mollie/mollie-api-php/src/Types/index.php | 36 +++++++++ vendor/mollie/mollie-api-php/src/index.php | 36 +++++++++ vendor/paragonie/index.php | 36 +++++++++ vendor/paragonie/random_compat/dist/index.php | 36 +++++++++ vendor/paragonie/random_compat/index.php | 36 +++++++++ vendor/paragonie/random_compat/lib/index.php | 36 +++++++++ vendor/psr/cache/index.php | 36 +++++++++ vendor/psr/cache/src/index.php | 36 +++++++++ vendor/psr/container/index.php | 36 +++++++++ vendor/psr/container/src/index.php | 36 +++++++++ vendor/psr/http-message/index.php | 36 +++++++++ vendor/psr/http-message/src/index.php | 36 +++++++++ vendor/psr/index.php | 36 +++++++++ .../psr/log/Psr/Log/LoggerAwareInterface.php | 33 ++++++++ vendor/psr/log/Psr/Log/LoggerAwareTrait.php | 33 ++++++++ vendor/psr/log/Psr/Log/Test/index.php | 36 +++++++++ vendor/psr/log/Psr/Log/index.php | 36 +++++++++ vendor/psr/log/Psr/index.php | 36 +++++++++ vendor/psr/log/index.php | 36 +++++++++ vendor/psr/simple-cache/index.php | 36 +++++++++ vendor/psr/simple-cache/src/index.php | 36 +++++++++ vendor/ralouphie/getallheaders/index.php | 36 +++++++++ vendor/ralouphie/getallheaders/src/index.php | 36 +++++++++ vendor/ralouphie/index.php | 36 +++++++++ vendor/symfony/cache/Adapter/index.php | 36 +++++++++ vendor/symfony/cache/DataCollector/index.php | 36 +++++++++ vendor/symfony/cache/Exception/index.php | 36 +++++++++ vendor/symfony/cache/Simple/index.php | 36 +++++++++ vendor/symfony/cache/Tests/Adapter/index.php | 36 +++++++++ vendor/symfony/cache/Tests/Fixtures/index.php | 36 +++++++++ vendor/symfony/cache/Tests/Simple/index.php | 36 +++++++++ vendor/symfony/cache/Tests/Traits/index.php | 36 +++++++++ vendor/symfony/cache/Tests/index.php | 36 +++++++++ vendor/symfony/cache/Traits/ApcuTrait.php | 33 ++++++++ vendor/symfony/cache/Traits/index.php | 36 +++++++++ vendor/symfony/cache/index.php | 36 +++++++++ .../config/Definition/Builder/index.php | 36 +++++++++ .../config/Definition/Dumper/index.php | 36 +++++++++ .../config/Definition/Exception/index.php | 36 +++++++++ vendor/symfony/config/Definition/index.php | 36 +++++++++ .../config/DependencyInjection/index.php | 36 +++++++++ vendor/symfony/config/Exception/index.php | 36 +++++++++ vendor/symfony/config/Loader/index.php | 36 +++++++++ vendor/symfony/config/Resource/index.php | 36 +++++++++ .../config/Tests/Definition/Builder/index.php | 36 +++++++++ .../config/Tests/Definition/Dumper/index.php | 36 +++++++++ .../symfony/config/Tests/Definition/index.php | 36 +++++++++ .../Tests/DependencyInjection/index.php | 36 +++++++++ .../symfony/config/Tests/Exception/index.php | 36 +++++++++ .../config/Tests/Fixtures/Again/index.php | 36 +++++++++ .../config/Tests/Fixtures/Builder/index.php | 36 +++++++++ .../Tests/Fixtures/Configuration/index.php | 36 +++++++++ .../config/Tests/Fixtures/Resource/index.php | 36 +++++++++ .../config/Tests/Fixtures/Util/index.php | 36 +++++++++ .../symfony/config/Tests/Fixtures/index.php | 36 +++++++++ vendor/symfony/config/Tests/Loader/index.php | 36 +++++++++ .../symfony/config/Tests/Resource/index.php | 36 +++++++++ vendor/symfony/config/Tests/Util/index.php | 36 +++++++++ vendor/symfony/config/Tests/index.php | 36 +++++++++ .../symfony/config/Util/Exception/index.php | 36 +++++++++ vendor/symfony/config/Util/index.php | 36 +++++++++ vendor/symfony/config/index.php | 36 +++++++++ .../dependency-injection/Argument/index.php | 36 +++++++++ .../dependency-injection/Compiler/index.php | 36 +++++++++ .../dependency-injection/Config/index.php | 36 +++++++++ .../dependency-injection/Dumper/index.php | 36 +++++++++ .../dependency-injection/Exception/index.php | 36 +++++++++ .../dependency-injection/Extension/index.php | 36 +++++++++ .../LazyProxy/Instantiator/index.php | 36 +++++++++ .../LazyProxy/PhpDumper/index.php | 36 +++++++++ .../dependency-injection/LazyProxy/index.php | 36 +++++++++ .../Loader/Configurator/Traits/index.php | 36 +++++++++ .../Loader/Configurator/index.php | 36 +++++++++ .../dependency-injection/Loader/index.php | 36 +++++++++ .../Loader/schema/dic/index.php | 36 +++++++++ .../Loader/schema/dic/services/index.php | 36 +++++++++ .../Loader/schema/index.php | 36 +++++++++ .../ParameterBag/index.php | 36 +++++++++ .../Tests/Argument/index.php | 36 +++++++++ .../Tests/Compiler/index.php | 36 +++++++++ .../Tests/Config/index.php | 36 +++++++++ .../Tests/Dumper/index.php | 36 +++++++++ .../Tests/Extension/index.php | 36 +++++++++ .../Tests/Fixtures/Container/index.php | 36 +++++++++ .../Fixtures/Prototype/BadClasses/index.php | 36 +++++++++ .../Prototype/OtherDir/AnotherSub/index.php | 36 +++++++++ .../OtherDir/Component1/Dir1/index.php | 36 +++++++++ .../OtherDir/Component1/Dir2/index.php | 36 +++++++++ .../Prototype/OtherDir/Component1/index.php | 36 +++++++++ .../OtherDir/Component2/Dir1/index.php | 36 +++++++++ .../OtherDir/Component2/Dir2/index.php | 36 +++++++++ .../Prototype/OtherDir/Component2/index.php | 36 +++++++++ .../Fixtures/Prototype/OtherDir/index.php | 36 +++++++++ .../Tests/Fixtures/Prototype/Sub/index.php | 36 +++++++++ .../Tests/Fixtures/Prototype/index.php | 36 +++++++++ .../Tests/Fixtures/config/index.php | 36 +++++++++ .../Tests/Fixtures/containers/index.php | 36 +++++++++ .../Tests/Fixtures/directory/import/index.php | 36 +++++++++ .../Tests/Fixtures/directory/index.php | 36 +++++++++ .../Fixtures/directory/recurse/index.php | 36 +++++++++ .../Tests/Fixtures/graphviz/index.php | 36 +++++++++ .../Tests/Fixtures/includes/HotPath/index.php | 36 +++++++++ .../Tests/Fixtures/includes/index.php | 36 +++++++++ .../Tests/Fixtures/includes/schema/index.php | 36 +++++++++ .../Tests/Fixtures/index.php | 36 +++++++++ .../Tests/Fixtures/ini/index.php | 36 +++++++++ .../Tests/Fixtures/php/index.php | 36 +++++++++ .../Tests/Fixtures/xml/extension1/index.php | 36 +++++++++ .../Tests/Fixtures/xml/extension2/index.php | 36 +++++++++ .../Tests/Fixtures/xml/extensions/index.php | 36 +++++++++ .../Tests/Fixtures/xml/index.php | 36 +++++++++ .../Tests/Fixtures/yaml/bar/index.php | 36 +++++++++ .../Tests/Fixtures/yaml/foo/index.php | 36 +++++++++ .../Tests/Fixtures/yaml/index.php | 36 +++++++++ .../autoconfigure_child_not_applied/index.php | 36 +++++++++ .../autoconfigure_parent_child/index.php | 36 +++++++++ .../autoconfigure_parent_child_tags/index.php | 36 +++++++++ .../yaml/integration/child_parent/index.php | 36 +++++++++ .../integration/defaults_child_tags/index.php | 36 +++++++++ .../defaults_instanceof_importance/index.php | 36 +++++++++ .../defaults_parent_child/index.php | 36 +++++++++ .../Tests/Fixtures/yaml/integration/index.php | 36 +++++++++ .../instanceof_parent_child/index.php | 36 +++++++++ .../Tests/LazyProxy/Instantiator/index.php | 36 +++++++++ .../Tests/LazyProxy/PhpDumper/index.php | 36 +++++++++ .../Tests/LazyProxy/index.php | 36 +++++++++ .../Tests/Loader/index.php | 36 +++++++++ .../Tests/ParameterBag/index.php | 36 +++++++++ .../dependency-injection/Tests/index.php | 36 +++++++++ vendor/symfony/dependency-injection/index.php | 36 +++++++++ .../expression-language/Node/index.php | 36 +++++++++ .../expression-language/ParserCache/index.php | 36 +++++++++ .../Resources/bin/index.php | 36 +++++++++ .../expression-language/Resources/index.php | 36 +++++++++ .../Tests/Fixtures/index.php | 36 +++++++++ .../expression-language/Tests/Node/index.php | 36 +++++++++ .../Tests/ParserCache/index.php | 36 +++++++++ .../expression-language/Tests/index.php | 36 +++++++++ vendor/symfony/expression-language/index.php | 36 +++++++++ vendor/symfony/filesystem/Exception/index.php | 36 +++++++++ .../Tests/Fixtures/MockStream/index.php | 36 +++++++++ .../filesystem/Tests/Fixtures/index.php | 36 +++++++++ vendor/symfony/filesystem/Tests/index.php | 36 +++++++++ vendor/symfony/filesystem/index.php | 36 +++++++++ vendor/symfony/index.php | 36 +++++++++ vendor/symfony/polyfill-apcu/index.php | 36 +++++++++ vendor/symfony/polyfill-ctype/index.php | 36 +++++++++ vendor/symfony/polyfill-intl-idn/index.php | 36 +++++++++ .../polyfill-mbstring/Resources/index.php | 36 +++++++++ .../Resources/unidata/index.php | 36 +++++++++ vendor/symfony/polyfill-mbstring/index.php | 36 +++++++++ .../polyfill-php70/Resources/index.php | 36 +++++++++ .../polyfill-php70/Resources/stubs/index.php | 36 +++++++++ vendor/symfony/polyfill-php70/index.php | 36 +++++++++ vendor/symfony/polyfill-php72/index.php | 36 +++++++++ vendor/symfony/yaml/Command/index.php | 36 +++++++++ vendor/symfony/yaml/Exception/index.php | 36 +++++++++ vendor/symfony/yaml/Tag/index.php | 36 +++++++++ vendor/symfony/yaml/Tests/Command/index.php | 36 +++++++++ vendor/symfony/yaml/Tests/Fixtures/index.php | 36 +++++++++ vendor/symfony/yaml/Tests/index.php | 36 +++++++++ vendor/symfony/yaml/index.php | 36 +++++++++ views/js/admin/index.php | 36 +++++++++ views/js/dist/index.php | 36 +++++++++ views/js/front/payment_fee.js | 33 ++++++++ .../front/order-confirmation-table.tpl | 56 ++++++++------ 253 files changed, 9003 insertions(+), 149 deletions(-) create mode 100644 config/index.php rename views/templates/admin/download_update.tpl => src/Builder/index.php (65%) create mode 100644 src/Config/index.php create mode 100644 src/Entity/index.php create mode 100644 src/Factory/index.php create mode 100644 src/Install/index.php create mode 100644 src/Repository/index.php create mode 100644 src/Service/index.php create mode 100644 src/Utility/index.php create mode 100644 src/index.php create mode 100644 vendor/composer/ca-bundle/index.php create mode 100644 vendor/composer/ca-bundle/res/index.php create mode 100644 vendor/composer/ca-bundle/src/index.php create mode 100644 vendor/composer/index.php create mode 100644 vendor/guzzlehttp/guzzle/index.php create mode 100644 vendor/guzzlehttp/guzzle/src/Cookie/index.php create mode 100644 vendor/guzzlehttp/guzzle/src/Exception/index.php create mode 100644 vendor/guzzlehttp/guzzle/src/Handler/index.php create mode 100644 vendor/guzzlehttp/guzzle/src/index.php create mode 100644 vendor/guzzlehttp/index.php create mode 100644 vendor/guzzlehttp/promises/index.php create mode 100644 vendor/guzzlehttp/promises/src/index.php create mode 100644 vendor/guzzlehttp/psr7/index.php create mode 100644 vendor/guzzlehttp/psr7/src/index.php create mode 100644 vendor/index.php create mode 100644 vendor/mollie/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/captures/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/customers/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/invoices/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/mandates/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/orders/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/payments/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/profiles/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/settlements/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/shipments/index.php create mode 100644 vendor/mollie/mollie-api-php/examples/subscriptions/index.php create mode 100644 vendor/mollie/mollie-api-php/index.php create mode 100644 vendor/mollie/mollie-api-php/src/Endpoints/index.php create mode 100644 vendor/mollie/mollie-api-php/src/Exceptions/index.php create mode 100644 vendor/mollie/mollie-api-php/src/Resources/index.php create mode 100644 vendor/mollie/mollie-api-php/src/Types/index.php create mode 100644 vendor/mollie/mollie-api-php/src/index.php create mode 100644 vendor/paragonie/index.php create mode 100644 vendor/paragonie/random_compat/dist/index.php create mode 100644 vendor/paragonie/random_compat/index.php create mode 100644 vendor/paragonie/random_compat/lib/index.php create mode 100644 vendor/psr/cache/index.php create mode 100644 vendor/psr/cache/src/index.php create mode 100644 vendor/psr/container/index.php create mode 100644 vendor/psr/container/src/index.php create mode 100644 vendor/psr/http-message/index.php create mode 100644 vendor/psr/http-message/src/index.php create mode 100644 vendor/psr/index.php create mode 100644 vendor/psr/log/Psr/Log/Test/index.php create mode 100644 vendor/psr/log/Psr/Log/index.php create mode 100644 vendor/psr/log/Psr/index.php create mode 100644 vendor/psr/log/index.php create mode 100644 vendor/psr/simple-cache/index.php create mode 100644 vendor/psr/simple-cache/src/index.php create mode 100644 vendor/ralouphie/getallheaders/index.php create mode 100644 vendor/ralouphie/getallheaders/src/index.php create mode 100644 vendor/ralouphie/index.php create mode 100644 vendor/symfony/cache/Adapter/index.php create mode 100644 vendor/symfony/cache/DataCollector/index.php create mode 100644 vendor/symfony/cache/Exception/index.php create mode 100644 vendor/symfony/cache/Simple/index.php create mode 100644 vendor/symfony/cache/Tests/Adapter/index.php create mode 100644 vendor/symfony/cache/Tests/Fixtures/index.php create mode 100644 vendor/symfony/cache/Tests/Simple/index.php create mode 100644 vendor/symfony/cache/Tests/Traits/index.php create mode 100644 vendor/symfony/cache/Tests/index.php create mode 100644 vendor/symfony/cache/Traits/index.php create mode 100644 vendor/symfony/cache/index.php create mode 100644 vendor/symfony/config/Definition/Builder/index.php create mode 100644 vendor/symfony/config/Definition/Dumper/index.php create mode 100644 vendor/symfony/config/Definition/Exception/index.php create mode 100644 vendor/symfony/config/Definition/index.php create mode 100644 vendor/symfony/config/DependencyInjection/index.php create mode 100644 vendor/symfony/config/Exception/index.php create mode 100644 vendor/symfony/config/Loader/index.php create mode 100644 vendor/symfony/config/Resource/index.php create mode 100644 vendor/symfony/config/Tests/Definition/Builder/index.php create mode 100644 vendor/symfony/config/Tests/Definition/Dumper/index.php create mode 100644 vendor/symfony/config/Tests/Definition/index.php create mode 100644 vendor/symfony/config/Tests/DependencyInjection/index.php create mode 100644 vendor/symfony/config/Tests/Exception/index.php create mode 100644 vendor/symfony/config/Tests/Fixtures/Again/index.php create mode 100644 vendor/symfony/config/Tests/Fixtures/Builder/index.php create mode 100644 vendor/symfony/config/Tests/Fixtures/Configuration/index.php create mode 100644 vendor/symfony/config/Tests/Fixtures/Resource/index.php create mode 100644 vendor/symfony/config/Tests/Fixtures/Util/index.php create mode 100644 vendor/symfony/config/Tests/Fixtures/index.php create mode 100644 vendor/symfony/config/Tests/Loader/index.php create mode 100644 vendor/symfony/config/Tests/Resource/index.php create mode 100644 vendor/symfony/config/Tests/Util/index.php create mode 100644 vendor/symfony/config/Tests/index.php create mode 100644 vendor/symfony/config/Util/Exception/index.php create mode 100644 vendor/symfony/config/Util/index.php create mode 100644 vendor/symfony/config/index.php create mode 100644 vendor/symfony/dependency-injection/Argument/index.php create mode 100644 vendor/symfony/dependency-injection/Compiler/index.php create mode 100644 vendor/symfony/dependency-injection/Config/index.php create mode 100644 vendor/symfony/dependency-injection/Dumper/index.php create mode 100644 vendor/symfony/dependency-injection/Exception/index.php create mode 100644 vendor/symfony/dependency-injection/Extension/index.php create mode 100644 vendor/symfony/dependency-injection/LazyProxy/Instantiator/index.php create mode 100644 vendor/symfony/dependency-injection/LazyProxy/PhpDumper/index.php create mode 100644 vendor/symfony/dependency-injection/LazyProxy/index.php create mode 100644 vendor/symfony/dependency-injection/Loader/Configurator/Traits/index.php create mode 100644 vendor/symfony/dependency-injection/Loader/Configurator/index.php create mode 100644 vendor/symfony/dependency-injection/Loader/index.php create mode 100644 vendor/symfony/dependency-injection/Loader/schema/dic/index.php create mode 100644 vendor/symfony/dependency-injection/Loader/schema/dic/services/index.php create mode 100644 vendor/symfony/dependency-injection/Loader/schema/index.php create mode 100644 vendor/symfony/dependency-injection/ParameterBag/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Argument/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Compiler/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Config/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Dumper/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Extension/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Container/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/BadClasses/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/AnotherSub/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir1/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir2/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir1/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir2/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Sub/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/config/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/containers/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/directory/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/includes/HotPath/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/includes/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/ini/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/php/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/xml/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/LazyProxy/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/Loader/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/ParameterBag/index.php create mode 100644 vendor/symfony/dependency-injection/Tests/index.php create mode 100644 vendor/symfony/dependency-injection/index.php create mode 100644 vendor/symfony/expression-language/Node/index.php create mode 100644 vendor/symfony/expression-language/ParserCache/index.php create mode 100644 vendor/symfony/expression-language/Resources/bin/index.php create mode 100644 vendor/symfony/expression-language/Resources/index.php create mode 100644 vendor/symfony/expression-language/Tests/Fixtures/index.php create mode 100644 vendor/symfony/expression-language/Tests/Node/index.php create mode 100644 vendor/symfony/expression-language/Tests/ParserCache/index.php create mode 100644 vendor/symfony/expression-language/Tests/index.php create mode 100644 vendor/symfony/expression-language/index.php create mode 100644 vendor/symfony/filesystem/Exception/index.php create mode 100644 vendor/symfony/filesystem/Tests/Fixtures/MockStream/index.php create mode 100644 vendor/symfony/filesystem/Tests/Fixtures/index.php create mode 100644 vendor/symfony/filesystem/Tests/index.php create mode 100644 vendor/symfony/filesystem/index.php create mode 100644 vendor/symfony/index.php create mode 100644 vendor/symfony/polyfill-apcu/index.php create mode 100644 vendor/symfony/polyfill-ctype/index.php create mode 100644 vendor/symfony/polyfill-intl-idn/index.php create mode 100644 vendor/symfony/polyfill-mbstring/Resources/index.php create mode 100644 vendor/symfony/polyfill-mbstring/Resources/unidata/index.php create mode 100644 vendor/symfony/polyfill-mbstring/index.php create mode 100644 vendor/symfony/polyfill-php70/Resources/index.php create mode 100644 vendor/symfony/polyfill-php70/Resources/stubs/index.php create mode 100644 vendor/symfony/polyfill-php70/index.php create mode 100644 vendor/symfony/polyfill-php72/index.php create mode 100644 vendor/symfony/yaml/Command/index.php create mode 100644 vendor/symfony/yaml/Exception/index.php create mode 100644 vendor/symfony/yaml/Tag/index.php create mode 100644 vendor/symfony/yaml/Tests/Command/index.php create mode 100644 vendor/symfony/yaml/Tests/Fixtures/index.php create mode 100644 vendor/symfony/yaml/Tests/index.php create mode 100644 vendor/symfony/yaml/index.php create mode 100644 views/js/admin/index.php create mode 100644 views/js/dist/index.php diff --git a/config/index.php b/config/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/config/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/controllers/front/ajax.php b/controllers/front/ajax.php index 24ceb5a53..89b3035c2 100644 --- a/controllers/front/ajax.php +++ b/controllers/front/ajax.php @@ -1,7 +1,4 @@ __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/views/js/dist/', ]); - $updateMessage = ''; - if (!static::ADDONS) { - $updateMessage = defined('_TB_VERSION_') - ? $this->getUpdateMessage('https://github.com/mollie/thirtybees') - : $this->getUpdateMessage('https://github.com/mollie/PrestaShop'); - if ($updateMessage === 'updateAvailable') { - $updateMessage = $this->display(__FILE__, 'views/templates/admin/download_update.tpl'); - } - } $resultMessage = ''; $warningMessage = ''; @@ -287,7 +278,6 @@ public function getContent() /** @var Mollie\Service\LanguageService $langService */ $langService = $this->getContainer(Mollie\Service\LanguageService::class); $data = [ - 'update_message' => $updateMessage, 'title_status' => $this->l('%s statuses:'), 'title_visual' => $this->l('Visual settings:'), 'title_debug' => $this->l('Debug info:'), @@ -323,7 +313,6 @@ public function getContent() $this->context->smarty->assign($data); $html = ''; -// $html .= $updateMessage; $html .= $this->display(__FILE__, 'views/templates/admin/logo.tpl'); diff --git a/src/Builder/FormBuilder.php b/src/Builder/FormBuilder.php index 7ec2258de..ab9e22537 100644 --- a/src/Builder/FormBuilder.php +++ b/src/Builder/FormBuilder.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Builder; @@ -13,9 +46,12 @@ use Mollie\Service\ConfigFieldService; use Mollie\Service\CountryService; use Mollie\Service\MolCarrierInformationService; +use Mollie\Utility\AssortUtility; +use Mollie\Utility\TagsUtility; use OrderState; use Smarty; use Tools; +use Translate; class FormBuilder { @@ -128,7 +164,7 @@ protected function getAccountSettingsSection($isApiKeyProvided) 'type' => 'text', 'label' => $this->module->l('API Key'), 'tab' => $generalSettings, - 'desc' => \Mollie\Utility\TagsUtility::ppTags( + 'desc' => TagsUtility::ppTags( $this->module->l('You can find your API key in your [1]Mollie Profile[/1]; it starts with test or live.'), [$this->module->display($this->module->getPathUri(), 'views/templates/admin/profile.tpl')] ), @@ -149,12 +185,12 @@ protected function getAccountSettingsSection($isApiKeyProvided) [ 'id' => 'active_on', 'value' => true, - 'label' => \Translate::getAdminTranslation('Enabled', 'AdminCarriers'), + 'label' => Translate::getAdminTranslation('Enabled', 'AdminCarriers'), ], [ 'id' => 'active_off', 'value' => false, - 'label' => \Translate::getAdminTranslation('Disabled', 'AdminCarriers'), + 'label' => Translate::getAdminTranslation('Disabled', 'AdminCarriers'), ], ], 'desc' => $this->module->display( @@ -165,7 +201,7 @@ protected function getAccountSettingsSection($isApiKeyProvided) 'type' => 'text', 'label' => $this->module->l('API Key'), 'tab' => $generalSettings, - 'desc' => \Mollie\Utility\TagsUtility::ppTags( + 'desc' => TagsUtility::ppTags( $this->module->l('You can find your API key in your [1]Mollie Profile[/1]; it starts with test or live.'), [$this->module->display($this->module->getPathUri(), 'views/templates/admin/profile.tpl')] ), @@ -186,12 +222,12 @@ protected function getAccountSettingsSection($isApiKeyProvided) [ 'id' => 'active_on', 'value' => true, - 'label' => \Translate::getAdminTranslation('Enabled', 'AdminCarriers'), + 'label' => Translate::getAdminTranslation('Enabled', 'AdminCarriers'), ], [ 'id' => 'active_off', 'value' => false, - 'label' => \Translate::getAdminTranslation('Disabled', 'AdminCarriers'), + 'label' => Translate::getAdminTranslation('Disabled', 'AdminCarriers'), ], ], ]; @@ -200,7 +236,7 @@ protected function getAccountSettingsSection($isApiKeyProvided) 'type' => 'text', 'label' => $this->module->l('Profile ID'), 'tab' => $generalSettings, - 'desc' => \Mollie\Utility\TagsUtility::ppTags( + 'desc' => TagsUtility::ppTags( $this->module->l('You can find your API key in your [1]Mollie Profile[/1];'), [$this->module->display($this->module->getPathUri(), 'views/templates/admin/profile.tpl')] ), @@ -253,7 +289,7 @@ protected function getAccountSettingsSection($isApiKeyProvided) 'paymentMethods' => $this->apiService->getMethodsForConfig($this->module->api, $this->module->getPathUri()), 'countries' => $this->countryService->getActiveCountriesList(), 'tab' => $generalSettings, - 'displayErrors' => Configuration::get(Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS), + 'displayErrors' => Configuration::get(Config::MOLLIE_DISPLAY_ERRORS), ]; } @@ -270,7 +306,7 @@ protected function getAdvancedSettingsSection() 'type' => 'select', 'label' => $this->module->l('Send locale for payment screen'), 'tab' => $advancedSettings, - 'desc' => \Mollie\Utility\TagsUtility::ppTags( + 'desc' => TagsUtility::ppTags( $this->module->l('Should the plugin send the current webshop [1]locale[/1] to Mollie. Mollie payment screens will be in the same language as your webshop. Mollie can also detect the language based on the user\'s browser language.'), [$this->module->display($this->module->getPathUri(), 'views/templates/admin/locale_wiki.tpl')] ), @@ -343,10 +379,10 @@ protected function getAdvancedSettingsSection() PaymentStatus::STATUS_EXPIRED, RefundStatus::STATUS_REFUNDED, PaymentStatus::STATUS_OPEN, - \Mollie\Config\Config::PARTIAL_REFUND_CODE, + Config::PARTIAL_REFUND_CODE, ]); }) as $status) { - if (!in_array($status['name'], ['paid', \Mollie\Config\Config::PARTIAL_REFUND_CODE])) { + if (!in_array($status['name'], ['paid', Config::PARTIAL_REFUND_CODE])) { $input[] = [ 'type' => 'switch', 'label' => $status['message_mail'], @@ -357,12 +393,12 @@ protected function getAdvancedSettingsSection() [ 'id' => 'active_on', 'value' => true, - 'label' => \Translate::getAdminTranslation('Enabled', 'AdminCarriers'), + 'label' => Translate::getAdminTranslation('Enabled', 'AdminCarriers'), ], [ 'id' => 'active_off', 'value' => false, - 'label' => \Translate::getAdminTranslation('Disabled', 'AdminCarriers'), + 'label' => Translate::getAdminTranslation('Disabled', 'AdminCarriers'), ], ], ]; @@ -417,7 +453,7 @@ protected function getAdvancedSettingsSection() 'type' => 'text', 'label' => $this->module->l('CSS file'), 'tab' => $advancedSettings, - 'desc' => \Mollie\Utility\TagsUtility::ppTags( + 'desc' => TagsUtility::ppTags( $this->module->l('Leave empty for default stylesheet. Should include file path when set. Hint: You can use [1]{BASE}[/1], [1]{THEME}[/1], [1]{CSS}[/1], [1]{MOBILE}[/1], [1]{MOBILE_CSS}[/1] and [1]{OVERRIDE}[/1] for easy folder mapping.'), [$this->module->display($this->module->getPathUri(), 'views/templates/front/kbd.tpl')] ), @@ -445,12 +481,12 @@ protected function getAdvancedSettingsSection() [ 'id' => 'active_on', 'value' => true, - 'label' => \Translate::getAdminTranslation('Enabled', 'AdminCarriers'), + 'label' => Translate::getAdminTranslation('Enabled', 'AdminCarriers'), ], [ 'id' => 'active_off', 'value' => false, - 'label' => \Translate::getAdminTranslation('Disabled', 'AdminCarriers'), + 'label' => Translate::getAdminTranslation('Disabled', 'AdminCarriers'), ], ], 'depends' => Config::MOLLIE_API, @@ -490,7 +526,7 @@ protected function getAdvancedSettingsSection() $orderStatuses[$i]['name'] = $orderStatuses[$i]['id_order_state'] . ' - ' . $orderStatuses[$i]['name']; } - \Mollie\Utility\AssortUtility::aasort($orderStatuses, 'id_order_state'); + AssortUtility::aasort($orderStatuses, 'id_order_state'); $this->smarty->assign([ 'logs' => $this->link->getAdminLink('AdminLogs') @@ -515,12 +551,12 @@ protected function getAdvancedSettingsSection() [ 'id' => 'active_on', 'value' => true, - 'label' => \Translate::getAdminTranslation('Enabled', 'AdminCarriers'), + 'label' => Translate::getAdminTranslation('Enabled', 'AdminCarriers'), ], [ 'id' => 'active_off', 'value' => false, - 'label' => \Translate::getAdminTranslation('Disabled', 'AdminCarriers'), + 'label' => Translate::getAdminTranslation('Disabled', 'AdminCarriers'), ], ], ], @@ -528,7 +564,7 @@ protected function getAdvancedSettingsSection() 'type' => 'select', 'label' => $this->module->l('Log level'), 'tab' => $advancedSettings, - 'desc' => \Mollie\Utility\TagsUtility::ppTags( + 'desc' => TagsUtility::ppTags( $this->module->l('Recommended level: Errors. Set to Everything to monitor incoming webhook requests. [1]View logs.[/1]'), [ $this->module->display($this->module->getPathUri(), 'views/templates/admin/view_logs.tpl') diff --git a/views/templates/admin/download_update.tpl b/src/Builder/index.php similarity index 65% rename from views/templates/admin/download_update.tpl rename to src/Builder/index.php index 3e8204d26..9e462a606 100644 --- a/views/templates/admin/download_update.tpl +++ b/src/Builder/index.php @@ -1,5 +1,6 @@ -{** - * Copyright (c) 2012-2019, Mollie B.V. + {l s='Update this module' mod='mollie'} - +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Config/Config.php b/src/Config/Config.php index ca09185ed..308063f28 100644 --- a/src/Config/Config.php +++ b/src/Config/Config.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Config; diff --git a/src/Config/index.php b/src/Config/index.php new file mode 100644 index 000000000..9e462a606 --- /dev/null +++ b/src/Config/index.php @@ -0,0 +1,44 @@ + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Entity/MolCarrierInformation.php b/src/Entity/MolCarrierInformation.php index 4bc88f40a..70131e56b 100644 --- a/src/Entity/MolCarrierInformation.php +++ b/src/Entity/MolCarrierInformation.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ class MolCarrierInformation extends ObjectModel { diff --git a/src/Entity/MolOrderFee.php b/src/Entity/MolOrderFee.php index 11b79693a..b9eced672 100644 --- a/src/Entity/MolOrderFee.php +++ b/src/Entity/MolOrderFee.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ class MolOrderFee extends ObjectModel { diff --git a/src/Entity/MolPaymentMethod.php b/src/Entity/MolPaymentMethod.php index 566ef4438..363435947 100644 --- a/src/Entity/MolPaymentMethod.php +++ b/src/Entity/MolPaymentMethod.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ class MolPaymentMethod extends ObjectModel { diff --git a/src/Entity/MolPaymentMethodIssuer.php b/src/Entity/MolPaymentMethodIssuer.php index dfa7fd101..0b388585a 100644 --- a/src/Entity/MolPaymentMethodIssuer.php +++ b/src/Entity/MolPaymentMethodIssuer.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ class MolPaymentMethodIssuer extends ObjectModel { diff --git a/src/Entity/index.php b/src/Entity/index.php new file mode 100644 index 000000000..9e462a606 --- /dev/null +++ b/src/Entity/index.php @@ -0,0 +1,44 @@ + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Factory/ContextFactory.php b/src/Factory/ContextFactory.php index 5c7d935fb..0f4913c59 100644 --- a/src/Factory/ContextFactory.php +++ b/src/Factory/ContextFactory.php @@ -1,24 +1,36 @@ - * @copyright Fruugo.com Limited - * @license Fruugo + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart */ namespace Mollie\Factory; diff --git a/src/Factory/index.php b/src/Factory/index.php new file mode 100644 index 000000000..9e462a606 --- /dev/null +++ b/src/Factory/index.php @@ -0,0 +1,44 @@ + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Install/Installer.php b/src/Install/Installer.php index f20f9e4e3..6f5d5390e 100644 --- a/src/Install/Installer.php +++ b/src/Install/Installer.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Install; @@ -6,6 +39,7 @@ use Context; use Db; use DbQuery; +use Exception; use Language; use Mollie; use OrderState; @@ -39,26 +73,26 @@ public function install() try { $this->partialRefundOrderState($context->language->id); - } catch (\Exception $e) { + } catch (Exception $e) { $this->errors[] = $this->module->l('Unable to install Mollie partially refunded order state'); return false; } try { $this->awaitingMollieOrderState($context->language->id); - } catch (\Exception $e) { + } catch (Exception $e) { $this->errors[] = $this->module->l('Unable to install Mollie awaiting state'); return false; } try { $this->initConfig(); - } catch (\Exception $e) { + } catch (Exception $e) { $this->errors[] = $this->module->l('Unable to install config'); return false; } try { $this->setDefaultCarrierStatuses(); - } catch (\Exception $e) { + } catch (Exception $e) { $this->errors[] = $this->module->l('Unable to install default carrier statuses'); return false; } diff --git a/src/Install/Uninstall.php b/src/Install/Uninstall.php index 74821cfc3..0bb52ed55 100644 --- a/src/Install/Uninstall.php +++ b/src/Install/Uninstall.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Install; diff --git a/src/Install/index.php b/src/Install/index.php new file mode 100644 index 000000000..9e462a606 --- /dev/null +++ b/src/Install/index.php @@ -0,0 +1,44 @@ + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Repository/CountryRepository.php b/src/Repository/CountryRepository.php index e1e597471..9ddc6ebae 100644 --- a/src/Repository/CountryRepository.php +++ b/src/Repository/CountryRepository.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Repository; diff --git a/src/Repository/MethodCountryRepository.php b/src/Repository/MethodCountryRepository.php index 5010c02dd..0ada582bb 100644 --- a/src/Repository/MethodCountryRepository.php +++ b/src/Repository/MethodCountryRepository.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Repository; diff --git a/src/Repository/ModuleRepository.php b/src/Repository/ModuleRepository.php index 85c753ae6..d9cbb5eca 100644 --- a/src/Repository/ModuleRepository.php +++ b/src/Repository/ModuleRepository.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Repository; diff --git a/src/Repository/MolCarrierInformationRepository.php b/src/Repository/MolCarrierInformationRepository.php index cc5e7e64b..687da688b 100644 --- a/src/Repository/MolCarrierInformationRepository.php +++ b/src/Repository/MolCarrierInformationRepository.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Repository; @@ -16,4 +49,5 @@ public function getMollieCarrierInformationIdByCarrierId($carrierId) return Db::getInstance(_PS_USE_SQL_SLAVE_)->getValue($sql); } + } \ No newline at end of file diff --git a/src/Repository/OrderFeeRepository.php b/src/Repository/OrderFeeRepository.php index 025cd3e95..3efbfbf1f 100644 --- a/src/Repository/OrderFeeRepository.php +++ b/src/Repository/OrderFeeRepository.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Repository; diff --git a/src/Repository/OrderShipmentRepository.php b/src/Repository/OrderShipmentRepository.php index d9772daac..a6b379624 100644 --- a/src/Repository/OrderShipmentRepository.php +++ b/src/Repository/OrderShipmentRepository.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Repository; diff --git a/src/Repository/PaymentMethodRepository.php b/src/Repository/PaymentMethodRepository.php index 599749e26..b76ef9cb3 100644 --- a/src/Repository/PaymentMethodRepository.php +++ b/src/Repository/PaymentMethodRepository.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Repository; diff --git a/src/Repository/index.php b/src/Repository/index.php new file mode 100644 index 000000000..9e462a606 --- /dev/null +++ b/src/Repository/index.php @@ -0,0 +1,44 @@ + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Service/ApiService.php b/src/Service/ApiService.php index 403dfdef1..876d12e95 100644 --- a/src/Service/ApiService.php +++ b/src/Service/ApiService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; @@ -7,14 +40,20 @@ use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order as MollieOrderAlias; use Configuration; use Context; +use ErrorException; use Exception; use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment; use Mollie\Config\Config; use Mollie\Repository\CountryRepository; use Mollie\Repository\PaymentMethodRepository; use Mollie\Utility\CartPriceUtility; +use Mollie\Utility\UrlPathUtility; use MollieWebhookModuleFrontController; use MolPaymentMethod; +use PrestaShop\PrestaShop\Adapter\CoreException; +use PrestaShopDatabaseException; +use PrestaShopException; +use SmartyException; use Tools; class ApiService @@ -150,7 +189,7 @@ public function getMethodsForConfig($api, $path, $active = false) return (array)$apiMethod; }, $apiMethods), 'id'); if (in_array('creditcard', $availableApiMethods)) { - foreach ([\Mollie\Config\Config::CARTES_BANCAIRES => 'Cartes Bancaires'] as $id => $name) { + foreach ([Config::CARTES_BANCAIRES => 'Cartes Bancaires'] as $id => $name) { if (!in_array($id, array_column($dbMethods, 'id'))) { $deferredMethods[] = [ 'id' => $id, @@ -158,9 +197,9 @@ public function getMethodsForConfig($api, $path, $active = false) 'enabled' => true, 'available' => !in_array($id, $notAvailable), 'image' => [ - 'size1x' => \Mollie\Utility\UrlPathUtility::getMediaPath("{$path}views/img/{$id}_small.png"), - 'size2x' => \Mollie\Utility\UrlPathUtility::getMediaPath("{$path}views/img/{$id}.png"), - 'svg' => \Mollie\Utility\UrlPathUtility::getMediaPath("{$path}views/img/{$id}.svg"), + 'size1x' => UrlPathUtility::getMediaPath("{$path}views/img/{$id}_small.png"), + 'size2x' => UrlPathUtility::getMediaPath("{$path}views/img/{$id}.png"), + 'svg' => UrlPathUtility::getMediaPath("{$path}views/img/{$id}.svg"), ], 'issuers' => null, ]; @@ -173,9 +212,9 @@ public function getMethodsForConfig($api, $path, $active = false) 'enabled' => !empty($thisMethod['enabled']) && !empty($cc['enabled']), 'available' => !in_array($id, $notAvailable), 'image' => [ - 'size1x' => \Mollie\Utility\UrlPathUtility::getMediaPath("{$path}views/img/{$id}_small.png"), - 'size2x' => \Mollie\Utility\UrlPathUtility::getMediaPath("{$path}views/img/{$id}.png"), - 'svg' => \Mollie\Utility\UrlPathUtility::getMediaPath("{$path}views/img/{$id}.svg"), + 'size1x' => UrlPathUtility::getMediaPath("{$path}views/img/{$id}_small.png"), + 'size2x' => UrlPathUtility::getMediaPath("{$path}views/img/{$id}.png"), + 'svg' => UrlPathUtility::getMediaPath("{$path}views/img/{$id}.svg"), ], 'issuers' => null, ]; @@ -236,7 +275,7 @@ private function getMethodsObjForConfig($apiMethods) return (array)$apiMethod; }, $apiMethods), 'id'); if (in_array('creditcard', $availableApiMethods)) { - foreach ([\Mollie\Config\Config::CARTES_BANCAIRES => 'Cartes Bancaires'] as $value => $apiMethod) { + foreach ([Config::CARTES_BANCAIRES => 'Cartes Bancaires'] as $value => $apiMethod) { $paymentId = $this->methodRepository->getPaymentMethodIdByMethodId($value); if ($paymentId) { $paymentMethod = new MolPaymentMethod($paymentId); @@ -268,10 +307,10 @@ private function getMethodsCountriesForConfig(&$methods) * @return array|null * * @throws ApiException - * @throws \PrestaShopDatabaseException - * @throws \PrestaShopException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - * @throws \SmartyException + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws CoreException + * @throws SmartyException * @since 3.3.0 * @since 3.3.2 $process option */ @@ -334,7 +373,7 @@ public function getFilteredApiPayment($api, $transactionId, $process = false) * @param string $transactionId * @return array|null * - * @throws \ErrorException + * @throws ErrorException * @throws ApiException * @since 3.3.0 * @since 3.3.2 $process option diff --git a/src/Service/CancelService.php b/src/Service/CancelService.php index bd62f869b..ffb133bab 100644 --- a/src/Service/CancelService.php +++ b/src/Service/CancelService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; @@ -8,6 +41,10 @@ use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment; use Mollie\Utility\EnvironmentUtility; use MollieWebhookModuleFrontController; +use PrestaShop\PrestaShop\Adapter\CoreException; +use PrestaShopDatabaseException; +use PrestaShopException; +use SmartyException; use Tools; class CancelService @@ -28,10 +65,10 @@ public function __construct(Mollie $module) * * @return array * - * @throws \PrestaShopDatabaseException - * @throws \PrestaShopException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - * @throws \SmartyException + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws CoreException + * @throws SmartyException * @since 3.3.0 */ public function doCancelOrderLines($transactionId, $lines = []) diff --git a/src/Service/CartLinesService.php b/src/Service/CartLinesService.php index ea8fc6dd8..c75850614 100644 --- a/src/Service/CartLinesService.php +++ b/src/Service/CartLinesService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; @@ -6,6 +39,7 @@ use Configuration; use Currency; use Mollie; +use Mollie\Utility\CartPriceUtility; use Tools; class CartLinesService @@ -62,7 +96,7 @@ public function getCartLines($amount, $paymentFee, Cart $cart) $aItems[$productHash] = []; // Try to spread this product evenly and account for rounding differences on the order line - foreach (\Mollie\Utility\CartPriceUtility::spreadAmountEvenly($roundedTotalWithTax, $quantity) as $unitPrice => $qty) { + foreach (CartPriceUtility::spreadAmountEvenly($roundedTotalWithTax, $quantity) as $unitPrice => $qty) { $aItems[$productHash][] = [ 'name' => $cartItem['name'], 'sku' => $productHash, @@ -249,7 +283,7 @@ public static function spreadCartLineGroup($cartLineGroup, $newTotal) $newTotal = round($newTotal, $apiRoundingPrecision); $quantity = array_sum(array_column($cartLineGroup, 'quantity')); $newCartLineGroup = []; - $spread = \Mollie\Utility\CartPriceUtility::spreadAmountEvenly($newTotal, $quantity); + $spread = CartPriceUtility::spreadAmountEvenly($newTotal, $quantity); foreach ($spread as $unitPrice => $qty) { $newCartLineGroup[] = [ 'name' => $cartLineGroup[0]['name'], diff --git a/src/Service/ConfigFieldService.php b/src/Service/ConfigFieldService.php index fa2f7649f..e04e6ba83 100644 --- a/src/Service/ConfigFieldService.php +++ b/src/Service/ConfigFieldService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; diff --git a/src/Service/CountryService.php b/src/Service/CountryService.php index dc246d5fb..b839fe01d 100644 --- a/src/Service/CountryService.php +++ b/src/Service/CountryService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; diff --git a/src/Service/IssuerService.php b/src/Service/IssuerService.php index bb3daabf8..58d7455a6 100644 --- a/src/Service/IssuerService.php +++ b/src/Service/IssuerService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; diff --git a/src/Service/LanguageService.php b/src/Service/LanguageService.php index 693edc5c5..2ba6b589c 100644 --- a/src/Service/LanguageService.php +++ b/src/Service/LanguageService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; diff --git a/src/Service/MolCarrierInformationService.php b/src/Service/MolCarrierInformationService.php index af55c3686..61929a9cc 100644 --- a/src/Service/MolCarrierInformationService.php +++ b/src/Service/MolCarrierInformationService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; diff --git a/src/Service/MollieOrderInfoService.php b/src/Service/MollieOrderInfoService.php index f69635bae..c79f3febe 100644 --- a/src/Service/MollieOrderInfoService.php +++ b/src/Service/MollieOrderInfoService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; diff --git a/src/Service/OrderFeeService.php b/src/Service/OrderFeeService.php index 9ed1688e5..ed59fb4e4 100644 --- a/src/Service/OrderFeeService.php +++ b/src/Service/OrderFeeService.php @@ -1,7 +1,41 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; +use Mollie\Utility\PaymentFeeUtility; use MolPaymentMethod; use Tools; @@ -16,7 +50,7 @@ public function getPaymentFees($methods, $totalPrice) continue; } $paymentMethod = new MolPaymentMethod($method['id_payment_method']); - $paymentFee = \Mollie\Utility\PaymentFeeUtility::getPaymentFee($paymentMethod, $totalPrice); + $paymentFee = PaymentFeeUtility::getPaymentFee($paymentMethod, $totalPrice); $methods[$index]['fee'] = $paymentFee; $methods[$index]['fee_display'] = Tools::displayPrice($paymentFee); } diff --git a/src/Service/OrderStatusService.php b/src/Service/OrderStatusService.php index 7b6c70f72..2f2bfae35 100644 --- a/src/Service/OrderStatusService.php +++ b/src/Service/OrderStatusService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; @@ -7,6 +40,8 @@ use Mollie\Config\Config; use Order; use OrderHistory; +use PrestaShopDatabaseException; +use PrestaShopException; use Tools; use Validate; @@ -20,8 +55,8 @@ class OrderStatusService * * @return void * - * @throws \PrestaShopDatabaseException - * @throws \PrestaShopException + * @throws PrestaShopDatabaseException + * @throws PrestaShopException * @since 3.3.2 Accept both Order ID and Order object * @since 3.3.2 Accept both Mollie status string and PrestaShop status ID * @since 3.3.2 $useExistingPayment option diff --git a/src/Service/PaymentMethodService.php b/src/Service/PaymentMethodService.php index d5a7d9141..95a4b3c8b 100644 --- a/src/Service/PaymentMethodService.php +++ b/src/Service/PaymentMethodService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; @@ -13,8 +46,14 @@ use Mollie\Config\Config; use Mollie\Repository\MethodCountryRepository; use Mollie\Repository\PaymentMethodRepository; +use Mollie\Utility\EnvironmentUtility; +use Mollie\Utility\LocaleUtility; +use Mollie\Utility\PaymentFeeUtility; +use Mollie\Utility\TextGeneratorUtility; use MolPaymentMethod; use Order; +use PrestaShopDatabaseException; +use PrestaShopException; use State; use Tools; @@ -82,8 +121,8 @@ public function savePaymentMethod($method) * * @return array * - * @throws \PrestaShopDatabaseException - * @throws \PrestaShopException + * @throws PrestaShopDatabaseException + * @throws PrestaShopException * @since 3.0.0 * @since 3.4.0 public * @@ -176,12 +215,12 @@ public function getPaymentData( if (!$orderReference) { $this->module->currentOrderReference = $orderReference = Order::generateReference(); } - $description = \Mollie\Utility\TextGeneratorUtility::generateDescriptionFromCart($molPaymentMethod->description, $cartId, $orderReference); + $description = TextGeneratorUtility::generateDescriptionFromCart($molPaymentMethod->description, $cartId, $orderReference); $context = Context::getContext(); $cart = new Cart($cartId); $customer = new Customer($cart->id_customer); - $paymentFee = \Mollie\Utility\PaymentFeeUtility::getPaymentFee($molPaymentMethod, $amount); + $paymentFee = PaymentFeeUtility::getPaymentFee($molPaymentMethod, $amount); $totalAmount = (number_format(str_replace(',', '.', $amount), 2, '.', '')); $totalAmount += $paymentFee; @@ -209,7 +248,7 @@ public function getPaymentData( if ($cardToken) { $paymentData['cardToken'] = $cardToken; } - if (!\Mollie\Utility\EnvironmentUtility::isLocalEnvironment()) { + if (!EnvironmentUtility::isLocalEnvironment()) { $paymentData['webhookUrl'] = $context->link->getModuleLink( 'mollie', 'webhook', @@ -229,7 +268,7 @@ public function getPaymentData( && Configuration::get(Mollie\Config\Config::MOLLIE_PAYMENTSCREEN_LOCALE) === Mollie\Config\Config::PAYMENTSCREEN_LOCALE_SEND_WEBSITE_LOCALE) || $molPaymentMethod->method === Mollie\Config\Config::MOLLIE_ORDERS_API ) { - $locale = \Mollie\Utility\LocaleUtility::getWebshopLocale(); + $locale = LocaleUtility::getWebshopLocale(); if (preg_match( '/^[a-z]{2}(?:[\-_][A-Z]{2})?$/iu', $locale @@ -276,7 +315,7 @@ public function getPaymentData( switch ($method) { case PaymentMethod::BANKTRANSFER: $paymentData['billingEmail'] = $customer->email; - $paymentData['locale'] = \Mollie\Utility\LocaleUtility::getWebshopLocale(); + $paymentData['locale'] = LocaleUtility::getWebshopLocale(); break; case PaymentMethod::BITCOIN: $paymentData['billingEmail'] = $customer->email; @@ -313,7 +352,7 @@ public function getPaymentData( $paymentData['lines'] = $this->cartLinesService->getCartLines($amount, $paymentFee, $cart); $paymentData['payment'] = []; - if (!\Mollie\Utility\EnvironmentUtility::isLocalEnvironment()) { + if (!EnvironmentUtility::isLocalEnvironment()) { $paymentData['payment']['webhookUrl'] = $context->link->getModuleLink( 'mollie', 'webhook', diff --git a/src/Service/RefundService.php b/src/Service/RefundService.php index f021f1fd9..5b478f11f 100644 --- a/src/Service/RefundService.php +++ b/src/Service/RefundService.php @@ -1,5 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; @@ -9,6 +41,10 @@ use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment; use Mollie\Utility\EnvironmentUtility; use MollieWebhookModuleFrontController; +use PrestaShop\PrestaShop\Adapter\CoreException; +use PrestaShopDatabaseException; +use PrestaShopException; +use SmartyException; use Tools; class RefundService @@ -29,9 +65,9 @@ public function __construct(Mollie $module) * * @return array * - * @throws \PrestaShopDatabaseException - * @throws \PrestaShopException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws CoreException * @throws ApiException * @since 3.3.0 Renamed `doRefund` to `doPaymentRefund`, added `$amount` * @since 3.3.2 Omit $orderId @@ -88,10 +124,10 @@ public function doPaymentRefund($transactionId, $amount = null) * * @return array * - * @throws \PrestaShopDatabaseException - * @throws \PrestaShopException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - * @throws \SmartyException + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws CoreException + * @throws SmartyException * @since 3.3.0 */ public function doRefundOrderLines($transactionId, $lines = []) diff --git a/src/Service/SettingsSaveService.php b/src/Service/SettingsSaveService.php index 7d438ed37..83d2e1a52 100644 --- a/src/Service/SettingsSaveService.php +++ b/src/Service/SettingsSaveService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; @@ -14,6 +47,8 @@ use Mollie\Repository\PaymentMethodRepository; use MolPaymentMethodIssuer; use OrderState; +use PrestaShopDatabaseException; +use PrestaShopException; use Tools; class SettingsSaveService @@ -65,8 +100,8 @@ public function __construct( * * @return string * @throws ApiException - * @throws \PrestaShopDatabaseException - * @throws \PrestaShopException + * @throws PrestaShopDatabaseException + * @throws PrestaShopException */ public function saveSettings(&$errors = []) { @@ -158,7 +193,7 @@ public function saveSettings(&$errors = []) Config::MOLLIE_TRACKING_URLS, json_encode(@json_decode(Tools::getValue(Config::MOLLIE_TRACKING_URLS))) ); - $carriers = \Carrier::getCarriers( + $carriers = Carrier::getCarriers( Context::getContext()->language->id, false, false, diff --git a/src/Service/ShipService.php b/src/Service/ShipService.php index 452a039b7..786eda880 100644 --- a/src/Service/ShipService.php +++ b/src/Service/ShipService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; diff --git a/src/Service/ShipmentService.php b/src/Service/ShipmentService.php index 14c3c2420..c014d414c 100644 --- a/src/Service/ShipmentService.php +++ b/src/Service/ShipmentService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; @@ -7,12 +40,14 @@ use Context; use Country; use Language; +use MolCarrierInformation; use Mollie\Config\Config; use Mollie\Repository\MolCarrierInformationRepository; use Mollie\Repository\OrderShipmentRepository; use Order; use OrderCarrier; use PrestaShopDatabaseException; +use PrestaShopException; use Tools; use Validate; @@ -45,7 +80,7 @@ public function __construct( * @return array|null * * @throws PrestaShopDatabaseException - * @throws \PrestaShopException + * @throws PrestaShopException * @since 3.3.0 */ public function getShipmentInformation($orderReference) @@ -57,7 +92,7 @@ public function getShipmentInformation($orderReference) $invoiceAddress = new Address($order->id_address_invoice); $deliveryAddress = new Address($order->id_address_delivery); $carrierInformationId = $this->informationRepository->getMollieCarrierInformationIdByCarrierId($order->id_carrier); - $carrierInformation = new \MolCarrierInformation($carrierInformationId); + $carrierInformation = new MolCarrierInformation($carrierInformationId); if (!Validate::isLoadedObject($invoiceAddress) || !Validate::isLoadedObject($deliveryAddress) || !$carrierInformation diff --git a/src/Service/UrlPathService.php b/src/Service/UrlPathService.php index 39cc7a32d..1cfac2ed5 100644 --- a/src/Service/UrlPathService.php +++ b/src/Service/UrlPathService.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Service; diff --git a/src/Service/index.php b/src/Service/index.php new file mode 100644 index 000000000..9e462a606 --- /dev/null +++ b/src/Service/index.php @@ -0,0 +1,44 @@ + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Utility/AssortUtility.php b/src/Utility/AssortUtility.php index 92afe7569..2f98b878a 100644 --- a/src/Utility/AssortUtility.php +++ b/src/Utility/AssortUtility.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Utility; diff --git a/src/Utility/CartPriceUtility.php b/src/Utility/CartPriceUtility.php index e5e6227ca..13c4e0254 100644 --- a/src/Utility/CartPriceUtility.php +++ b/src/Utility/CartPriceUtility.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Utility; diff --git a/src/Utility/EnvironmentUtility.php b/src/Utility/EnvironmentUtility.php index 0b859522d..e58ca3246 100644 --- a/src/Utility/EnvironmentUtility.php +++ b/src/Utility/EnvironmentUtility.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Utility; diff --git a/src/Utility/ImageUtility.php b/src/Utility/ImageUtility.php index 39420afb5..bd4d480ba 100644 --- a/src/Utility/ImageUtility.php +++ b/src/Utility/ImageUtility.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Utility; diff --git a/src/Utility/LocaleUtility.php b/src/Utility/LocaleUtility.php index 62eb0524e..5e9989f94 100644 --- a/src/Utility/LocaleUtility.php +++ b/src/Utility/LocaleUtility.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Utility; diff --git a/src/Utility/MenuLocationUtility.php b/src/Utility/MenuLocationUtility.php index 84dbc7a27..027380919 100644 --- a/src/Utility/MenuLocationUtility.php +++ b/src/Utility/MenuLocationUtility.php @@ -1,8 +1,43 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Utility; use Context; +use PrestaShopDatabaseException; +use PrestaShopException; use Tab; use Validate; @@ -16,8 +51,8 @@ class MenuLocationUtility * * @return string * - * @throws \PrestaShopDatabaseException - * @throws \PrestaShopException + * @throws PrestaShopDatabaseException + * @throws PrestaShopException * @since 3.3.2 */ public static function getMenuLocation($class, $idLang = null) @@ -38,8 +73,8 @@ public static function getMenuLocation($class, $idLang = null) * * @return Tab[]|null * - * @throws \PrestaShopDatabaseException - * @throws \PrestaShopException + * @throws PrestaShopDatabaseException + * @throws PrestaShopException * @since 3.3.2 */ public static function getTabTreeByClass($class) diff --git a/src/Utility/PaymentFeeUtility.php b/src/Utility/PaymentFeeUtility.php index dc28c15bb..7fb4ca735 100644 --- a/src/Utility/PaymentFeeUtility.php +++ b/src/Utility/PaymentFeeUtility.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Utility; diff --git a/src/Utility/TagsUtility.php b/src/Utility/TagsUtility.php index 0314218a7..fe2acb6c3 100644 --- a/src/Utility/TagsUtility.php +++ b/src/Utility/TagsUtility.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Utility; diff --git a/src/Utility/TextGeneratorUtility.php b/src/Utility/TextGeneratorUtility.php index b9199ffb3..f33ac9156 100644 --- a/src/Utility/TextGeneratorUtility.php +++ b/src/Utility/TextGeneratorUtility.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Utility; diff --git a/src/Utility/UrlPathUtility.php b/src/Utility/UrlPathUtility.php index 243bc44d6..3f528f3f6 100644 --- a/src/Utility/UrlPathUtility.php +++ b/src/Utility/UrlPathUtility.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace Mollie\Utility; @@ -119,7 +152,7 @@ public static function getWebpackChunks($entry) $manifest = []; foreach (include(_PS_MODULE_DIR_ . 'mollie/views/js/dist/manifest.php') as $chunk) { $manifest[$chunk['name']] = array_map(function ($chunk) { - return \Mollie\Utility\UrlPathUtility::getMediaPath(_PS_MODULE_DIR_ . "mollie/views/js/dist/{$chunk}"); + return UrlPathUtility::getMediaPath(_PS_MODULE_DIR_ . "mollie/views/js/dist/{$chunk}"); }, $chunk['files']); } } diff --git a/src/Utility/index.php b/src/Utility/index.php new file mode 100644 index 000000000..9e462a606 --- /dev/null +++ b/src/Utility/index.php @@ -0,0 +1,44 @@ + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/index.php b/src/index.php new file mode 100644 index 000000000..9e462a606 --- /dev/null +++ b/src/index.php @@ -0,0 +1,44 @@ + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/composer/ca-bundle/index.php b/vendor/composer/ca-bundle/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/composer/ca-bundle/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/composer/ca-bundle/res/index.php b/vendor/composer/ca-bundle/res/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/composer/ca-bundle/res/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/composer/ca-bundle/src/index.php b/vendor/composer/ca-bundle/src/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/composer/ca-bundle/src/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/composer/index.php b/vendor/composer/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/composer/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/guzzle/index.php b/vendor/guzzlehttp/guzzle/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/guzzlehttp/guzzle/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/guzzle/src/Cookie/index.php b/vendor/guzzlehttp/guzzle/src/Cookie/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/guzzlehttp/guzzle/src/Cookie/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/guzzle/src/Exception/index.php b/vendor/guzzlehttp/guzzle/src/Exception/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/guzzlehttp/guzzle/src/Exception/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/guzzle/src/Handler/index.php b/vendor/guzzlehttp/guzzle/src/Handler/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/guzzlehttp/guzzle/src/Handler/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/guzzle/src/index.php b/vendor/guzzlehttp/guzzle/src/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/guzzlehttp/guzzle/src/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/index.php b/vendor/guzzlehttp/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/guzzlehttp/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/promises/index.php b/vendor/guzzlehttp/promises/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/guzzlehttp/promises/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/promises/src/index.php b/vendor/guzzlehttp/promises/src/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/guzzlehttp/promises/src/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/psr7/index.php b/vendor/guzzlehttp/psr7/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/guzzlehttp/psr7/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/psr7/src/index.php b/vendor/guzzlehttp/psr7/src/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/guzzlehttp/psr7/src/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/index.php b/vendor/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/index.php b/vendor/mollie/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/captures/index.php b/vendor/mollie/mollie-api-php/examples/captures/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/captures/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/customers/index.php b/vendor/mollie/mollie-api-php/examples/customers/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/customers/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/index.php b/vendor/mollie/mollie-api-php/examples/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/invoices/index.php b/vendor/mollie/mollie-api-php/examples/invoices/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/invoices/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/mandates/index.php b/vendor/mollie/mollie-api-php/examples/mandates/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/mandates/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/orders/index.php b/vendor/mollie/mollie-api-php/examples/orders/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/orders/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/payments/index.php b/vendor/mollie/mollie-api-php/examples/payments/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/payments/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/profiles/index.php b/vendor/mollie/mollie-api-php/examples/profiles/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/profiles/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/settlements/index.php b/vendor/mollie/mollie-api-php/examples/settlements/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/settlements/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/shipments/index.php b/vendor/mollie/mollie-api-php/examples/shipments/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/shipments/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/subscriptions/index.php b/vendor/mollie/mollie-api-php/examples/subscriptions/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/examples/subscriptions/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/index.php b/vendor/mollie/mollie-api-php/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/index.php b/vendor/mollie/mollie-api-php/src/Endpoints/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/src/Endpoints/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/src/Exceptions/index.php b/vendor/mollie/mollie-api-php/src/Exceptions/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/src/Exceptions/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/src/Resources/index.php b/vendor/mollie/mollie-api-php/src/Resources/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/src/Resources/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/src/Types/index.php b/vendor/mollie/mollie-api-php/src/Types/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/src/Types/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/src/index.php b/vendor/mollie/mollie-api-php/src/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/mollie/mollie-api-php/src/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/paragonie/index.php b/vendor/paragonie/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/paragonie/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/paragonie/random_compat/dist/index.php b/vendor/paragonie/random_compat/dist/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/paragonie/random_compat/dist/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/paragonie/random_compat/index.php b/vendor/paragonie/random_compat/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/paragonie/random_compat/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/paragonie/random_compat/lib/index.php b/vendor/paragonie/random_compat/lib/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/paragonie/random_compat/lib/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/cache/index.php b/vendor/psr/cache/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/cache/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/cache/src/index.php b/vendor/psr/cache/src/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/cache/src/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/container/index.php b/vendor/psr/container/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/container/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/container/src/index.php b/vendor/psr/container/src/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/container/src/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/http-message/index.php b/vendor/psr/http-message/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/http-message/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/http-message/src/index.php b/vendor/psr/http-message/src/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/http-message/src/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/index.php b/vendor/psr/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/log/Psr/Log/LoggerAwareInterface.php b/vendor/psr/log/Psr/Log/LoggerAwareInterface.php index b9d495fe7..6ef219e50 100644 --- a/vendor/psr/log/Psr/Log/LoggerAwareInterface.php +++ b/vendor/psr/log/Psr/Log/LoggerAwareInterface.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace _PhpScoper5ea00cc67502b\Psr\Log; diff --git a/vendor/psr/log/Psr/Log/LoggerAwareTrait.php b/vendor/psr/log/Psr/Log/LoggerAwareTrait.php index 9edadca01..9443cab7b 100644 --- a/vendor/psr/log/Psr/Log/LoggerAwareTrait.php +++ b/vendor/psr/log/Psr/Log/LoggerAwareTrait.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ namespace _PhpScoper5ea00cc67502b\Psr\Log; diff --git a/vendor/psr/log/Psr/Log/Test/index.php b/vendor/psr/log/Psr/Log/Test/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/log/Psr/Log/Test/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/log/Psr/Log/index.php b/vendor/psr/log/Psr/Log/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/log/Psr/Log/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/log/Psr/index.php b/vendor/psr/log/Psr/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/log/Psr/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/log/index.php b/vendor/psr/log/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/log/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/simple-cache/index.php b/vendor/psr/simple-cache/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/simple-cache/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/simple-cache/src/index.php b/vendor/psr/simple-cache/src/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/psr/simple-cache/src/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/ralouphie/getallheaders/index.php b/vendor/ralouphie/getallheaders/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/ralouphie/getallheaders/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/ralouphie/getallheaders/src/index.php b/vendor/ralouphie/getallheaders/src/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/ralouphie/getallheaders/src/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/ralouphie/index.php b/vendor/ralouphie/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/ralouphie/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Adapter/index.php b/vendor/symfony/cache/Adapter/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/Adapter/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/DataCollector/index.php b/vendor/symfony/cache/DataCollector/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/DataCollector/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Exception/index.php b/vendor/symfony/cache/Exception/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/Exception/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Simple/index.php b/vendor/symfony/cache/Simple/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/Simple/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Tests/Adapter/index.php b/vendor/symfony/cache/Tests/Adapter/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/Tests/Adapter/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Tests/Fixtures/index.php b/vendor/symfony/cache/Tests/Fixtures/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/Tests/Fixtures/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Tests/Simple/index.php b/vendor/symfony/cache/Tests/Simple/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/Tests/Simple/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Tests/Traits/index.php b/vendor/symfony/cache/Tests/Traits/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/Tests/Traits/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Tests/index.php b/vendor/symfony/cache/Tests/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/Tests/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Traits/ApcuTrait.php b/vendor/symfony/cache/Traits/ApcuTrait.php index 4f1337ca8..14eef1487 100644 --- a/vendor/symfony/cache/Traits/ApcuTrait.php +++ b/vendor/symfony/cache/Traits/ApcuTrait.php @@ -1,4 +1,37 @@ + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ /* * This file is part of the Symfony package. diff --git a/vendor/symfony/cache/Traits/index.php b/vendor/symfony/cache/Traits/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/Traits/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/index.php b/vendor/symfony/cache/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/cache/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Definition/Builder/index.php b/vendor/symfony/config/Definition/Builder/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Definition/Builder/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Definition/Dumper/index.php b/vendor/symfony/config/Definition/Dumper/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Definition/Dumper/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Definition/Exception/index.php b/vendor/symfony/config/Definition/Exception/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Definition/Exception/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Definition/index.php b/vendor/symfony/config/Definition/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Definition/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/DependencyInjection/index.php b/vendor/symfony/config/DependencyInjection/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/DependencyInjection/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Exception/index.php b/vendor/symfony/config/Exception/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Exception/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Loader/index.php b/vendor/symfony/config/Loader/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Loader/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Resource/index.php b/vendor/symfony/config/Resource/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Resource/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Definition/Builder/index.php b/vendor/symfony/config/Tests/Definition/Builder/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Definition/Builder/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Definition/Dumper/index.php b/vendor/symfony/config/Tests/Definition/Dumper/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Definition/Dumper/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Definition/index.php b/vendor/symfony/config/Tests/Definition/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Definition/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/DependencyInjection/index.php b/vendor/symfony/config/Tests/DependencyInjection/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/DependencyInjection/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Exception/index.php b/vendor/symfony/config/Tests/Exception/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Exception/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/Again/index.php b/vendor/symfony/config/Tests/Fixtures/Again/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Fixtures/Again/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/Builder/index.php b/vendor/symfony/config/Tests/Fixtures/Builder/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Fixtures/Builder/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/Configuration/index.php b/vendor/symfony/config/Tests/Fixtures/Configuration/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Fixtures/Configuration/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/Resource/index.php b/vendor/symfony/config/Tests/Fixtures/Resource/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Fixtures/Resource/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/Util/index.php b/vendor/symfony/config/Tests/Fixtures/Util/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Fixtures/Util/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/index.php b/vendor/symfony/config/Tests/Fixtures/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Fixtures/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Loader/index.php b/vendor/symfony/config/Tests/Loader/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Loader/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Resource/index.php b/vendor/symfony/config/Tests/Resource/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Resource/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Util/index.php b/vendor/symfony/config/Tests/Util/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/Util/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/index.php b/vendor/symfony/config/Tests/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Tests/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Util/Exception/index.php b/vendor/symfony/config/Util/Exception/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Util/Exception/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Util/index.php b/vendor/symfony/config/Util/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/Util/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/index.php b/vendor/symfony/config/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/config/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Argument/index.php b/vendor/symfony/dependency-injection/Argument/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Argument/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Compiler/index.php b/vendor/symfony/dependency-injection/Compiler/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Compiler/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Config/index.php b/vendor/symfony/dependency-injection/Config/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Config/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Dumper/index.php b/vendor/symfony/dependency-injection/Dumper/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Dumper/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Exception/index.php b/vendor/symfony/dependency-injection/Exception/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Exception/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Extension/index.php b/vendor/symfony/dependency-injection/Extension/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Extension/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/LazyProxy/Instantiator/index.php b/vendor/symfony/dependency-injection/LazyProxy/Instantiator/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/LazyProxy/Instantiator/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/index.php b/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/LazyProxy/index.php b/vendor/symfony/dependency-injection/LazyProxy/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/LazyProxy/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/index.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/index.php b/vendor/symfony/dependency-injection/Loader/Configurator/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Loader/Configurator/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/index.php b/vendor/symfony/dependency-injection/Loader/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Loader/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/schema/dic/index.php b/vendor/symfony/dependency-injection/Loader/schema/dic/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Loader/schema/dic/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/schema/dic/services/index.php b/vendor/symfony/dependency-injection/Loader/schema/dic/services/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Loader/schema/dic/services/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/schema/index.php b/vendor/symfony/dependency-injection/Loader/schema/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Loader/schema/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/ParameterBag/index.php b/vendor/symfony/dependency-injection/ParameterBag/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/ParameterBag/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Argument/index.php b/vendor/symfony/dependency-injection/Tests/Argument/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Argument/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/index.php b/vendor/symfony/dependency-injection/Tests/Compiler/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Compiler/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Config/index.php b/vendor/symfony/dependency-injection/Tests/Config/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Config/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Dumper/index.php b/vendor/symfony/dependency-injection/Tests/Dumper/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Dumper/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Extension/index.php b/vendor/symfony/dependency-injection/Tests/Extension/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Extension/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Container/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Container/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Container/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/BadClasses/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/BadClasses/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/BadClasses/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/AnotherSub/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/AnotherSub/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/AnotherSub/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir1/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir1/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir1/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir2/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir2/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir2/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir1/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir1/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir1/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir2/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir2/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir2/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Sub/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Sub/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Sub/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/HotPath/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/HotPath/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/HotPath/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/index.php b/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/index.php b/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/LazyProxy/index.php b/vendor/symfony/dependency-injection/Tests/LazyProxy/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/LazyProxy/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Loader/index.php b/vendor/symfony/dependency-injection/Tests/Loader/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/Loader/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/ParameterBag/index.php b/vendor/symfony/dependency-injection/Tests/ParameterBag/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/ParameterBag/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/index.php b/vendor/symfony/dependency-injection/Tests/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/Tests/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/index.php b/vendor/symfony/dependency-injection/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/dependency-injection/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Node/index.php b/vendor/symfony/expression-language/Node/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/expression-language/Node/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/ParserCache/index.php b/vendor/symfony/expression-language/ParserCache/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/expression-language/ParserCache/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Resources/bin/index.php b/vendor/symfony/expression-language/Resources/bin/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/expression-language/Resources/bin/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Resources/index.php b/vendor/symfony/expression-language/Resources/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/expression-language/Resources/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Tests/Fixtures/index.php b/vendor/symfony/expression-language/Tests/Fixtures/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/expression-language/Tests/Fixtures/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Tests/Node/index.php b/vendor/symfony/expression-language/Tests/Node/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/expression-language/Tests/Node/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Tests/ParserCache/index.php b/vendor/symfony/expression-language/Tests/ParserCache/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/expression-language/Tests/ParserCache/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Tests/index.php b/vendor/symfony/expression-language/Tests/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/expression-language/Tests/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/index.php b/vendor/symfony/expression-language/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/expression-language/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/filesystem/Exception/index.php b/vendor/symfony/filesystem/Exception/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/filesystem/Exception/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/filesystem/Tests/Fixtures/MockStream/index.php b/vendor/symfony/filesystem/Tests/Fixtures/MockStream/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/filesystem/Tests/Fixtures/MockStream/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/filesystem/Tests/Fixtures/index.php b/vendor/symfony/filesystem/Tests/Fixtures/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/filesystem/Tests/Fixtures/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/filesystem/Tests/index.php b/vendor/symfony/filesystem/Tests/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/filesystem/Tests/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/filesystem/index.php b/vendor/symfony/filesystem/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/filesystem/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/index.php b/vendor/symfony/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-apcu/index.php b/vendor/symfony/polyfill-apcu/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/polyfill-apcu/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-ctype/index.php b/vendor/symfony/polyfill-ctype/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/polyfill-ctype/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-intl-idn/index.php b/vendor/symfony/polyfill-intl-idn/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/polyfill-intl-idn/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-mbstring/Resources/index.php b/vendor/symfony/polyfill-mbstring/Resources/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/polyfill-mbstring/Resources/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-mbstring/Resources/unidata/index.php b/vendor/symfony/polyfill-mbstring/Resources/unidata/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/polyfill-mbstring/Resources/unidata/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-mbstring/index.php b/vendor/symfony/polyfill-mbstring/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/polyfill-mbstring/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-php70/Resources/index.php b/vendor/symfony/polyfill-php70/Resources/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/polyfill-php70/Resources/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-php70/Resources/stubs/index.php b/vendor/symfony/polyfill-php70/Resources/stubs/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/polyfill-php70/Resources/stubs/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-php70/index.php b/vendor/symfony/polyfill-php70/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/polyfill-php70/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-php72/index.php b/vendor/symfony/polyfill-php72/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/polyfill-php72/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Command/index.php b/vendor/symfony/yaml/Command/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/yaml/Command/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Exception/index.php b/vendor/symfony/yaml/Exception/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/yaml/Exception/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Tag/index.php b/vendor/symfony/yaml/Tag/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/yaml/Tag/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Tests/Command/index.php b/vendor/symfony/yaml/Tests/Command/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/yaml/Tests/Command/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Tests/Fixtures/index.php b/vendor/symfony/yaml/Tests/Fixtures/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/yaml/Tests/Fixtures/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Tests/index.php b/vendor/symfony/yaml/Tests/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/yaml/Tests/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/index.php b/vendor/symfony/yaml/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/vendor/symfony/yaml/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/views/js/admin/index.php b/views/js/admin/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/views/js/admin/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/views/js/dist/index.php b/views/js/dist/index.php new file mode 100644 index 000000000..97775fe0f --- /dev/null +++ b/views/js/dist/index.php @@ -0,0 +1,36 @@ + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/views/js/front/payment_fee.js b/views/js/front/payment_fee.js index c30d127b2..7b5fea846 100644 --- a/views/js/front/payment_fee.js +++ b/views/js/front/payment_fee.js @@ -1,3 +1,36 @@ +/** + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ $(document).ready(function () { displayPaymentFee(); function displayPaymentFee() { diff --git a/views/templates/front/order-confirmation-table.tpl b/views/templates/front/order-confirmation-table.tpl index 0b46bcb95..e58a60beb 100644 --- a/views/templates/front/order-confirmation-table.tpl +++ b/views/templates/front/order-confirmation-table.tpl @@ -1,27 +1,35 @@ {** - * 2007-2019 PrestaShop and Contributors - * - * NOTICE OF LICENSE - * - * This source file is subject to the Academic Free License 3.0 (AFL-3.0) - * that is bundled with this package in the file LICENSE.txt. - * It is also available through the world-wide-web at this URL: - * https://opensource.org/licenses/AFL-3.0 - * If you did not receive a copy of the license and are unable to - * obtain it through the world-wide-web, please send an email - * to license@prestashop.com so we can send you a copy immediately. - * - * DISCLAIMER - * - * Do not edit or add to this file if you wish to upgrade PrestaShop to newer - * versions in the future. If you wish to customize PrestaShop for your - * needs please refer to https://www.prestashop.com for more information. - * - * @author PrestaShop SA - * @copyright 2007-2019 PrestaShop SA and Contributors - * @license https://opensource.org/licenses/AFL-3.0 Academic Free License 3.0 (AFL-3.0) - * International Registered Trademark & Property of PrestaShop SA - *} +* Copyright (c) 2012-2020, Mollie B.V. +* All rights reserved. +* +* Redistribution and use in source and binary forms, with or without +* modification, are permitted provided that the following conditions are met: +* +* - Redistributions of source code must retain the above copyright notice, +* this list of conditions and the following disclaimer. +* - Redistributions in binary form must reproduce the above copyright +* notice, this list of conditions and the following disclaimer in the +* documentation and/or other materials provided with the distribution. +* +* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY +* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +* DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY +* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +* DAMAGE. +* +* @author Mollie B.V. +* @copyright Mollie B.V. +* @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php +* @category Mollie +* @package Mollie +* @link https://www.mollie.nl +*} {extends file='checkout/_partials/order-confirmation-table.tpl'} {block name='order_confirmation_table'} {foreach from=$products item=product} @@ -60,7 +68,7 @@
{if $field.type == 'text'} - {if (int)$field.id_module} + {if $field.id_module} {$field.text nofilter} {else} {$field.text} From 862edb6a3396a92199fd35e4444d8c8633b04b26 Mon Sep 17 00:00:00 2001 From: Marius Gudauskis Date: Mon, 18 May 2020 11:51:41 +0300 Subject: [PATCH 3/4] added licenses and index.php files --- .github/ISSUE_TEMPLATE.md | 26 +- .github/index.php | 22 +- .gitignore | 20 +- .travis.yml | 210 +- LICENSE | 16 +- Makefile | 334 +- README.md | 386 +- README_ES.md | 384 +- README_FR.md | 384 +- README_NL.md | 356 +- changelog.md | 164 +- codeception.yml | 32 +- config.xml | 22 +- config/config.yml | 38 +- config/index.php | 72 +- controllers/front/ajax.php | 262 +- controllers/front/fail.php | 286 +- controllers/front/index.php | 22 +- controllers/front/payScreen.php | 158 +- controllers/front/payment.php | 788 +- controllers/front/qrcode.php | 600 +- controllers/front/return.php | 744 +- controllers/front/success.php | 358 +- controllers/front/webhook.php | 764 +- controllers/index.php | 22 +- countries.php | 130 +- docker-compose.yml | 68 +- greenkeeper.json | 18 +- index.php | 22 +- mollie.php | 2272 +++--- node_modules/.yarn-integrity | 18 +- node_modules/index.php | 22 +- php-scoper.phar.pubkey | 28 +- scoper.inc.php | 218 +- sql/index.php | 72 +- sql/install.php | 178 +- sql/uninstall.php | 92 +- src/Builder/index.php | 88 +- src/Config/index.php | 88 +- src/Entity/MolPaymentMethod.php | 260 +- src/Entity/MolPaymentMethodIssuer.php | 116 +- src/Entity/index.php | 88 +- src/Factory/ContextFactory.php | 162 +- src/Factory/index.php | 88 +- src/Install/index.php | 88 +- src/Repository/ModuleRepository.php | 102 +- src/Repository/index.php | 88 +- src/Service/index.php | 88 +- src/Utility/index.php | 88 +- src/index.php | 88 +- translations/de.php | 564 +- translations/en.php | 546 +- translations/es.php | 546 +- translations/fr.php | 564 +- translations/index.php | 22 +- translations/nl.php | 564 +- upgrade/Upgrade-2.0.0.php | 102 +- upgrade/Upgrade-3.1.5.php | 142 +- upgrade/Upgrade-3.3.0.php | 164 +- upgrade/Upgrade-3.3.2.php | 100 +- upgrade/Upgrade-3.4.2.php | 116 +- upgrade/Upgrade-3.4.3.php | 118 +- upgrade/Upgrade-3.5.2.php | 114 +- upgrade/Upgrade-3.5.4.php | 96 +- upgrade/Upgrade-3.5.5.php | 96 +- upgrade/Upgrade-4.0.0.php | 180 +- upgrade/index.php | 22 +- vendor/.htaccess | 20 +- vendor/autoload.php | 14 +- vendor/composer/ClassLoader.php | 890 +-- vendor/composer/LICENSE | 112 +- vendor/composer/autoload_classmap.php | 1136 +-- vendor/composer/autoload_files.php | 40 +- vendor/composer/autoload_namespaces.php | 18 +- vendor/composer/autoload_psr4.php | 66 +- vendor/composer/autoload_real.php | 140 +- vendor/composer/autoload_static.php | 1452 ++-- vendor/composer/ca-bundle/LICENSE | 38 +- vendor/composer/ca-bundle/README.md | 170 +- vendor/composer/ca-bundle/composer.json | 106 +- vendor/composer/ca-bundle/index.php | 72 +- vendor/composer/ca-bundle/res/cacert.pem | 6932 ++++++++--------- vendor/composer/ca-bundle/res/index.php | 72 +- vendor/composer/ca-bundle/src/CaBundle.php | 542 +- vendor/composer/ca-bundle/src/index.php | 72 +- vendor/composer/index.php | 72 +- vendor/composer/installed.json | 2954 +++---- vendor/guzzlehttp/guzzle/CHANGELOG.md | 2654 +++---- vendor/guzzlehttp/guzzle/Dockerfile | 36 +- vendor/guzzlehttp/guzzle/LICENSE | 38 +- vendor/guzzlehttp/guzzle/README.md | 180 +- vendor/guzzlehttp/guzzle/UPGRADING.md | 2406 +++--- vendor/guzzlehttp/guzzle/composer.json | 116 +- vendor/guzzlehttp/guzzle/index.php | 72 +- vendor/guzzlehttp/guzzle/src/Client.php | 850 +- .../guzzlehttp/guzzle/src/ClientInterface.php | 164 +- .../guzzle/src/Cookie/CookieJar.php | 492 +- .../guzzle/src/Cookie/CookieJarInterface.php | 152 +- .../guzzle/src/Cookie/FileCookieJar.php | 168 +- .../guzzle/src/Cookie/SessionCookieJar.php | 134 +- .../guzzle/src/Cookie/SetCookie.php | 686 +- vendor/guzzlehttp/guzzle/src/Cookie/index.php | 72 +- .../src/Exception/BadResponseException.php | 38 +- .../guzzle/src/Exception/ClientException.php | 20 +- .../guzzle/src/Exception/ConnectException.php | 62 +- .../guzzle/src/Exception/GuzzleException.php | 46 +- .../Exception/InvalidArgumentException.php | 14 +- .../guzzle/src/Exception/RequestException.php | 294 +- .../guzzle/src/Exception/SeekException.php | 50 +- .../guzzle/src/Exception/ServerException.php | 20 +- .../Exception/TooManyRedirectsException.php | 14 +- .../src/Exception/TransferException.php | 14 +- .../guzzlehttp/guzzle/src/Exception/index.php | 72 +- .../guzzle/src/Handler/CurlFactory.php | 872 +-- .../src/Handler/CurlFactoryInterface.php | 52 +- .../guzzle/src/Handler/CurlHandler.php | 78 +- .../guzzle/src/Handler/CurlMultiHandler.php | 356 +- .../guzzle/src/Handler/EasyHandle.php | 134 +- .../guzzle/src/Handler/MockHandler.php | 314 +- .../guzzlehttp/guzzle/src/Handler/Proxy.php | 92 +- .../guzzle/src/Handler/StreamHandler.php | 754 +- .../guzzlehttp/guzzle/src/Handler/index.php | 72 +- vendor/guzzlehttp/guzzle/src/HandlerStack.php | 486 +- .../guzzle/src/MessageFormatter.php | 312 +- vendor/guzzlehttp/guzzle/src/Middleware.php | 442 +- vendor/guzzlehttp/guzzle/src/Pool.php | 234 +- .../guzzle/src/PrepareBodyMiddleware.php | 182 +- .../guzzle/src/RedirectMiddleware.php | 354 +- .../guzzlehttp/guzzle/src/RequestOptions.php | 470 +- .../guzzlehttp/guzzle/src/RetryMiddleware.php | 198 +- .../guzzlehttp/guzzle/src/TransferStats.php | 220 +- vendor/guzzlehttp/guzzle/src/UriTemplate.php | 382 +- vendor/guzzlehttp/guzzle/src/Utils.php | 118 +- vendor/guzzlehttp/guzzle/src/functions.php | 588 +- .../guzzle/src/functions_include.php | 16 +- vendor/guzzlehttp/guzzle/src/index.php | 72 +- vendor/guzzlehttp/index.php | 72 +- vendor/guzzlehttp/promises/CHANGELOG.md | 130 +- vendor/guzzlehttp/promises/LICENSE | 38 +- vendor/guzzlehttp/promises/Makefile | 26 +- vendor/guzzlehttp/promises/README.md | 1008 +-- vendor/guzzlehttp/promises/composer.json | 74 +- vendor/guzzlehttp/promises/index.php | 72 +- .../promises/src/AggregateException.php | 28 +- .../promises/src/CancellationException.php | 20 +- vendor/guzzlehttp/promises/src/Coroutine.php | 270 +- .../guzzlehttp/promises/src/EachPromise.php | 380 +- .../promises/src/FulfilledPromise.php | 138 +- vendor/guzzlehttp/promises/src/Promise.php | 462 +- .../promises/src/PromiseInterface.php | 168 +- .../promises/src/PromisorInterface.php | 32 +- .../promises/src/RejectedPromise.php | 148 +- .../promises/src/RejectionException.php | 80 +- vendor/guzzlehttp/promises/src/TaskQueue.php | 124 +- .../promises/src/TaskQueueInterface.php | 48 +- vendor/guzzlehttp/promises/src/functions.php | 774 +- .../promises/src/functions_include.php | 16 +- vendor/guzzlehttp/promises/src/index.php | 72 +- vendor/guzzlehttp/psr7/CHANGELOG.md | 492 +- vendor/guzzlehttp/psr7/LICENSE | 38 +- vendor/guzzlehttp/psr7/README.md | 1490 ++-- vendor/guzzlehttp/psr7/composer.json | 118 +- vendor/guzzlehttp/psr7/index.php | 72 +- vendor/guzzlehttp/psr7/src/AppendStream.php | 404 +- vendor/guzzlehttp/psr7/src/BufferStream.php | 230 +- vendor/guzzlehttp/psr7/src/CachingStream.php | 230 +- vendor/guzzlehttp/psr7/src/DroppingStream.php | 72 +- vendor/guzzlehttp/psr7/src/FnStream.php | 264 +- vendor/guzzlehttp/psr7/src/InflateStream.php | 96 +- vendor/guzzlehttp/psr7/src/LazyOpenStream.php | 70 +- vendor/guzzlehttp/psr7/src/LimitStream.php | 256 +- vendor/guzzlehttp/psr7/src/MessageTrait.php | 342 +- .../guzzlehttp/psr7/src/MultipartStream.php | 246 +- vendor/guzzlehttp/psr7/src/NoSeekStream.php | 40 +- vendor/guzzlehttp/psr7/src/PumpStream.php | 280 +- vendor/guzzlehttp/psr7/src/Request.php | 240 +- vendor/guzzlehttp/psr7/src/Response.php | 152 +- vendor/guzzlehttp/psr7/src/Rfc7230.php | 36 +- vendor/guzzlehttp/psr7/src/ServerRequest.php | 604 +- vendor/guzzlehttp/psr7/src/Stream.php | 442 +- .../psr7/src/StreamDecoratorTrait.php | 256 +- vendor/guzzlehttp/psr7/src/StreamWrapper.php | 204 +- vendor/guzzlehttp/psr7/src/UploadedFile.php | 488 +- vendor/guzzlehttp/psr7/src/Uri.php | 1196 +-- vendor/guzzlehttp/psr7/src/UriNormalizer.php | 358 +- vendor/guzzlehttp/psr7/src/UriResolver.php | 380 +- vendor/guzzlehttp/psr7/src/functions.php | 1314 ++-- .../guzzlehttp/psr7/src/functions_include.php | 16 +- vendor/guzzlehttp/psr7/src/index.php | 72 +- vendor/index.php | 72 +- vendor/mollie/index.php | 72 +- vendor/mollie/mollie-api-php/LICENSE | 16 +- vendor/mollie/mollie-api-php/README.md | 400 +- vendor/mollie/mollie-api-php/composer.json | 160 +- .../examples/captures/get-capture.php | 50 +- .../examples/captures/index.php | 72 +- .../examples/captures/list-captures.php | 52 +- .../create-customer-first-payment.php | 122 +- .../customers/create-customer-payment.php | 100 +- .../create-customer-recurring-payment.php | 114 +- .../examples/customers/create-customer.php | 44 +- .../examples/customers/delete-customer.php | 34 +- .../examples/customers/index.php | 72 +- .../customers/list-customer-payments.php | 102 +- .../examples/customers/update-customer.php | 60 +- .../mollie-api-php/examples/functions.php | 42 +- .../mollie/mollie-api-php/examples/index.php | 72 +- .../mollie-api-php/examples/initialize.php | 38 +- .../examples/initialize_with_oauth.php | 38 +- .../examples/invoices/index.php | 72 +- .../examples/invoices/list-invoices.php | 74 +- .../examples/mandates/create-mandate.php | 50 +- .../examples/mandates/index.php | 72 +- .../examples/mandates/list-mandates.php | 54 +- .../examples/mandates/revoke-mandate.php | 56 +- .../examples/orders/cancel-order-lines.php | 68 +- .../examples/orders/cancel-order.php | 54 +- .../examples/orders/create-order.php | 74 +- .../mollie-api-php/examples/orders/index.php | 72 +- .../examples/orders/list-methods.php | 58 +- .../examples/orders/list-orders.php | 92 +- .../orders/refund-order-completely.php | 48 +- .../orders/refund-order-partially.php | 48 +- .../examples/orders/webhook.php | 98 +- .../payments/create-ideal-payment.php | 122 +- .../payments/create-payment-oauth.php | 102 +- .../examples/payments/create-payment.php | 92 +- .../examples/payments/index.php | 72 +- .../examples/payments/list-methods.php | 58 +- .../examples/payments/list-payments.php | 142 +- .../examples/payments/refund-payment.php | 122 +- .../examples/payments/return.php | 56 +- .../examples/payments/webhook.php | 128 +- .../examples/profiles/create-profile.php | 44 +- .../examples/profiles/delete-profile.php | 44 +- .../examples/profiles/index.php | 72 +- .../examples/profiles/list-profiles.php | 48 +- .../examples/profiles/update-profile.php | 62 +- .../examples/settlements/index.php | 72 +- .../examples/settlements/list-settlements.php | 108 +- .../shipments/create-shipment-all.php | 52 +- .../shipments/create-shipment-partial.php | 56 +- .../examples/shipments/get-shipment.php | 52 +- .../examples/shipments/index.php | 72 +- .../examples/shipments/list-shipments.php | 58 +- .../examples/shipments/update-shipment.php | 66 +- .../subscriptions/cancel-subscription.php | 68 +- .../subscriptions/create-subscription.php | 100 +- .../examples/subscriptions/index.php | 72 +- .../subscriptions/update-subscription.php | 64 +- vendor/mollie/mollie-api-php/index.php | 72 +- vendor/mollie/mollie-api-php/phpstan.neon | 18 +- .../src/CompatibilityChecker.php | 94 +- .../src/Endpoints/ChargebackEndpoint.php | 92 +- .../Endpoints/CollectionEndpointAbstract.php | 34 +- .../src/Endpoints/CustomerEndpoint.php | 178 +- .../Endpoints/CustomerPaymentsEndpoint.php | 176 +- .../src/Endpoints/EndpointAbstract.php | 342 +- .../src/Endpoints/InvoiceEndpoint.php | 144 +- .../src/Endpoints/MandateEndpoint.php | 270 +- .../src/Endpoints/MethodEndpoint.php | 176 +- .../src/Endpoints/OnboardingEndpoint.php | 122 +- .../src/Endpoints/OrderEndpoint.php | 204 +- .../src/Endpoints/OrderLineEndpoint.php | 154 +- .../src/Endpoints/OrderPaymentEndpoint.php | 134 +- .../src/Endpoints/OrderRefundEndpoint.php | 126 +- .../src/Endpoints/OrganizationEndpoint.php | 118 +- .../src/Endpoints/PaymentCaptureEndpoint.php | 114 +- .../Endpoints/PaymentChargebackEndpoint.php | 114 +- .../src/Endpoints/PaymentEndpoint.php | 268 +- .../src/Endpoints/PaymentRefundEndpoint.php | 114 +- .../src/Endpoints/PermissionEndpoint.php | 120 +- .../src/Endpoints/ProfileEndpoint.php | 216 +- .../src/Endpoints/ProfileMethodEndpoint.php | 234 +- .../src/Endpoints/RefundEndpoint.php | 92 +- .../src/Endpoints/SettlementsEndpoint.php | 160 +- .../src/Endpoints/ShipmentEndpoint.php | 248 +- .../src/Endpoints/SubscriptionEndpoint.php | 214 +- .../src/Endpoints/WalletEndpoint.php | 46 +- .../mollie-api-php/src/Endpoints/index.php | 72 +- .../src/Exceptions/ApiException.php | 318 +- .../src/Exceptions/IncompatiblePlatform.php | 22 +- .../mollie-api-php/src/Exceptions/index.php | 72 +- .../mollie-api-php/src/MollieApiClient.php | 902 +-- .../src/Resources/BaseCollection.php | 62 +- .../src/Resources/BaseResource.php | 38 +- .../mollie-api-php/src/Resources/Capture.php | 122 +- .../src/Resources/CaptureCollection.php | 42 +- .../src/Resources/Chargeback.php | 96 +- .../src/Resources/ChargebackCollection.php | 42 +- .../src/Resources/CurrentProfile.php | 64 +- .../src/Resources/CursorCollection.php | 160 +- .../mollie-api-php/src/Resources/Customer.php | 424 +- .../src/Resources/CustomerCollection.php | 42 +- .../mollie-api-php/src/Resources/Invoice.php | 196 +- .../src/Resources/InvoiceCollection.php | 42 +- .../mollie-api-php/src/Resources/Issuer.php | 64 +- .../src/Resources/IssuerCollection.php | 28 +- .../mollie-api-php/src/Resources/Mandate.php | 186 +- .../src/Resources/MandateCollection.php | 70 +- .../mollie-api-php/src/Resources/Method.php | 150 +- .../src/Resources/MethodCollection.php | 28 +- .../src/Resources/MethodPrice.php | 52 +- .../src/Resources/MethodPriceCollection.php | 28 +- .../src/Resources/Onboarding.php | 120 +- .../mollie-api-php/src/Resources/Order.php | 862 +- .../src/Resources/OrderCollection.php | 42 +- .../src/Resources/OrderLine.php | 514 +- .../src/Resources/OrderLineCollection.php | 60 +- .../src/Resources/Organization.php | 110 +- .../src/Resources/OrganizationCollection.php | 42 +- .../mollie-api-php/src/Resources/Payment.php | 1138 +-- .../src/Resources/PaymentCollection.php | 42 +- .../src/Resources/Permission.php | 56 +- .../src/Resources/PermissionCollection.php | 28 +- .../mollie-api-php/src/Resources/Profile.php | 358 +- .../src/Resources/ProfileCollection.php | 42 +- .../mollie-api-php/src/Resources/Refund.php | 244 +- .../src/Resources/RefundCollection.php | 42 +- .../src/Resources/ResourceFactory.php | 120 +- .../src/Resources/Settlement.php | 320 +- .../src/Resources/SettlementCollection.php | 42 +- .../mollie-api-php/src/Resources/Shipment.php | 224 +- .../src/Resources/ShipmentCollection.php | 28 +- .../src/Resources/Subscription.php | 340 +- .../src/Resources/SubscriptionCollection.php | 42 +- .../mollie-api-php/src/Resources/index.php | 72 +- .../src/Types/InvoiceStatus.php | 38 +- .../src/Types/MandateMethod.php | 32 +- .../src/Types/MandateStatus.php | 20 +- .../src/Types/OnboardingStatus.php | 38 +- .../src/Types/OrderLineStatus.php | 72 +- .../src/Types/OrderLineType.php | 28 +- .../mollie-api-php/src/Types/OrderStatus.php | 88 +- .../src/Types/PaymentMethod.php | 184 +- .../src/Types/PaymentStatus.php | 80 +- .../src/Types/ProfileStatus.php | 38 +- .../mollie-api-php/src/Types/RefundStatus.php | 46 +- .../mollie-api-php/src/Types/SequenceType.php | 30 +- .../src/Types/SettlementStatus.php | 46 +- .../src/Types/SubscriptionStatus.php | 28 +- .../mollie/mollie-api-php/src/Types/index.php | 72 +- vendor/mollie/mollie-api-php/src/index.php | 72 +- vendor/paragonie/index.php | 72 +- vendor/paragonie/random_compat/LICENSE | 44 +- vendor/paragonie/random_compat/composer.json | 74 +- vendor/paragonie/random_compat/dist/index.php | 72 +- .../dist/random_compat.phar.pubkey | 10 +- .../dist/random_compat.phar.pubkey.asc | 22 +- vendor/paragonie/random_compat/index.php | 72 +- .../random_compat/lib/byte_safe_strings.php | 294 +- .../random_compat/lib/cast_to_int.php | 136 +- .../random_compat/lib/error_polyfill.php | 94 +- vendor/paragonie/random_compat/lib/index.php | 72 +- vendor/paragonie/random_compat/lib/random.php | 342 +- .../lib/random_bytes_com_dotnet.php | 162 +- .../lib/random_bytes_dev_urandom.php | 346 +- .../lib/random_bytes_libsodium.php | 162 +- .../lib/random_bytes_libsodium_legacy.php | 164 +- .../random_compat/lib/random_bytes_mcrypt.php | 136 +- .../random_compat/lib/random_int.php | 362 +- vendor/prestashop/decimal/.gitignore | 68 +- vendor/prestashop/decimal/.travis.yml | 42 +- vendor/prestashop/decimal/CONTRIBUTING.md | 70 +- vendor/prestashop/decimal/LICENSE.md | 42 +- vendor/prestashop/decimal/README.md | 576 +- vendor/prestashop/decimal/composer.json | 80 +- vendor/prestashop/decimal/phpunit.xml.dist | 58 +- vendor/prestashop/decimal/src/Builder.php | 156 +- .../src/Exception/DivisionByZeroException.php | 32 +- vendor/prestashop/decimal/src/Number.php | 992 +-- .../decimal/src/Operation/Addition.php | 354 +- .../decimal/src/Operation/Comparison.php | 290 +- .../decimal/src/Operation/Division.php | 302 +- .../decimal/src/Operation/MagnitudeChange.php | 98 +- .../decimal/src/Operation/Multiplication.php | 256 +- .../decimal/src/Operation/Rounding.php | 746 +- .../decimal/src/Operation/Subtraction.php | 358 +- .../prestashop/decimal/tests/NumberTest.php | 820 +- .../decimal/tests/Operation/AdditionTest.php | 140 +- .../tests/Operation/ComparisonTest.php | 370 +- .../decimal/tests/Operation/DivisionTest.php | 210 +- .../tests/Operation/MagnitudeChangeTest.php | 74 +- .../tests/Operation/MultiplicationTest.php | 118 +- .../decimal/tests/Operation/RoundingTest.php | 766 +- .../tests/Operation/SubtractionTest.php | 80 +- vendor/psr/cache/CHANGELOG.md | 32 +- vendor/psr/cache/LICENSE.txt | 38 +- vendor/psr/cache/README.md | 18 +- vendor/psr/cache/composer.json | 56 +- vendor/psr/cache/index.php | 72 +- vendor/psr/cache/src/CacheException.php | 20 +- vendor/psr/cache/src/CacheItemInterface.php | 200 +- .../psr/cache/src/CacheItemPoolInterface.php | 258 +- .../cache/src/InvalidArgumentException.php | 26 +- vendor/psr/cache/src/index.php | 72 +- vendor/psr/container/.gitignore | 6 +- vendor/psr/container/LICENSE | 42 +- vendor/psr/container/README.md | 10 +- vendor/psr/container/composer.json | 64 +- vendor/psr/container/index.php | 72 +- .../src/ContainerExceptionInterface.php | 26 +- .../psr/container/src/ContainerInterface.php | 72 +- .../src/NotFoundExceptionInterface.php | 26 +- vendor/psr/container/src/index.php | 72 +- vendor/psr/http-message/CHANGELOG.md | 72 +- vendor/psr/http-message/LICENSE | 38 +- vendor/psr/http-message/README.md | 24 +- vendor/psr/http-message/composer.json | 64 +- vendor/psr/http-message/index.php | 72 +- .../psr/http-message/src/MessageInterface.php | 354 +- .../psr/http-message/src/RequestInterface.php | 248 +- .../http-message/src/ResponseInterface.php | 132 +- .../src/ServerRequestInterface.php | 498 +- .../psr/http-message/src/StreamInterface.php | 288 +- .../src/UploadedFileInterface.php | 236 +- vendor/psr/http-message/src/UriInterface.php | 618 +- vendor/psr/http-message/src/index.php | 72 +- vendor/psr/index.php | 72 +- vendor/psr/log/LICENSE | 38 +- vendor/psr/log/Psr/Log/AbstractLogger.php | 242 +- .../log/Psr/Log/InvalidArgumentException.php | 14 +- vendor/psr/log/Psr/Log/LogLevel.php | 36 +- .../psr/log/Psr/Log/LoggerAwareInterface.php | 102 +- vendor/psr/log/Psr/Log/LoggerAwareTrait.php | 116 +- vendor/psr/log/Psr/Log/LoggerInterface.php | 234 +- vendor/psr/log/Psr/Log/LoggerTrait.php | 268 +- vendor/psr/log/Psr/Log/NullLogger.php | 60 +- vendor/psr/log/Psr/Log/Test/DummyTest.php | 36 +- .../log/Psr/Log/Test/LoggerInterfaceTest.php | 186 +- vendor/psr/log/Psr/Log/Test/TestLogger.php | 264 +- vendor/psr/log/Psr/Log/Test/index.php | 72 +- vendor/psr/log/Psr/Log/index.php | 72 +- vendor/psr/log/Psr/index.php | 72 +- vendor/psr/log/README.md | 116 +- vendor/psr/log/composer.json | 58 +- vendor/psr/log/index.php | 72 +- vendor/psr/simple-cache/.editorconfig | 24 +- vendor/psr/simple-cache/LICENSE.md | 42 +- vendor/psr/simple-cache/README.md | 16 +- vendor/psr/simple-cache/composer.json | 60 +- vendor/psr/simple-cache/index.php | 72 +- .../psr/simple-cache/src/CacheException.php | 20 +- .../psr/simple-cache/src/CacheInterface.php | 214 +- .../src/InvalidArgumentException.php | 26 +- vendor/psr/simple-cache/src/index.php | 72 +- vendor/ralouphie/getallheaders/LICENSE | 42 +- vendor/ralouphie/getallheaders/README.md | 54 +- vendor/ralouphie/getallheaders/composer.json | 54 +- vendor/ralouphie/getallheaders/index.php | 72 +- .../getallheaders/src/getallheaders.php | 76 +- vendor/ralouphie/getallheaders/src/index.php | 72 +- vendor/ralouphie/index.php | 72 +- vendor/symfony/cache/.gitignore | 6 +- .../symfony/cache/Adapter/AbstractAdapter.php | 542 +- .../cache/Adapter/AdapterInterface.php | 68 +- vendor/symfony/cache/Adapter/ApcuAdapter.php | 56 +- vendor/symfony/cache/Adapter/ArrayAdapter.php | 264 +- vendor/symfony/cache/Adapter/ChainAdapter.php | 450 +- .../symfony/cache/Adapter/DoctrineAdapter.php | 56 +- .../cache/Adapter/FilesystemAdapter.php | 56 +- .../cache/Adapter/MemcachedAdapter.php | 64 +- vendor/symfony/cache/Adapter/NullAdapter.php | 202 +- vendor/symfony/cache/Adapter/PdoAdapter.php | 98 +- .../symfony/cache/Adapter/PhpArrayAdapter.php | 518 +- .../symfony/cache/Adapter/PhpFilesAdapter.php | 78 +- vendor/symfony/cache/Adapter/ProxyAdapter.php | 334 +- vendor/symfony/cache/Adapter/RedisAdapter.php | 52 +- .../cache/Adapter/SimpleCacheAdapter.php | 144 +- .../symfony/cache/Adapter/TagAwareAdapter.php | 646 +- .../Adapter/TagAwareAdapterInterface.php | 62 +- .../cache/Adapter/TraceableAdapter.php | 424 +- .../Adapter/TraceableTagAwareAdapter.php | 68 +- vendor/symfony/cache/Adapter/index.php | 72 +- vendor/symfony/cache/CHANGELOG.md | 72 +- vendor/symfony/cache/CacheItem.php | 352 +- .../DataCollector/CacheDataCollector.php | 314 +- vendor/symfony/cache/DataCollector/index.php | 72 +- vendor/symfony/cache/DoctrineProvider.php | 178 +- .../cache/Exception/CacheException.php | 34 +- .../Exception/InvalidArgumentException.php | 34 +- vendor/symfony/cache/Exception/index.php | 72 +- vendor/symfony/cache/LICENSE | 38 +- vendor/symfony/cache/PruneableInterface.php | 44 +- vendor/symfony/cache/README.md | 36 +- vendor/symfony/cache/ResettableInterface.php | 38 +- vendor/symfony/cache/Simple/AbstractCache.php | 334 +- vendor/symfony/cache/Simple/ApcuCache.php | 52 +- vendor/symfony/cache/Simple/ArrayCache.php | 264 +- vendor/symfony/cache/Simple/ChainCache.php | 426 +- vendor/symfony/cache/Simple/DoctrineCache.php | 56 +- .../symfony/cache/Simple/FilesystemCache.php | 56 +- .../symfony/cache/Simple/MemcachedCache.php | 52 +- vendor/symfony/cache/Simple/NullCache.php | 154 +- vendor/symfony/cache/Simple/PdoCache.php | 94 +- vendor/symfony/cache/Simple/PhpArrayCache.php | 452 +- vendor/symfony/cache/Simple/PhpFilesCache.php | 78 +- vendor/symfony/cache/Simple/Psr6Cache.php | 426 +- vendor/symfony/cache/Simple/RedisCache.php | 52 +- .../symfony/cache/Simple/TraceableCache.php | 440 +- vendor/symfony/cache/Simple/index.php | 72 +- .../Adapter/AbstractRedisAdapterTest.php | 72 +- .../cache/Tests/Adapter/AdapterTestCase.php | 282 +- .../cache/Tests/Adapter/ApcuAdapterTest.php | 194 +- .../cache/Tests/Adapter/ArrayAdapterTest.php | 88 +- .../cache/Tests/Adapter/ChainAdapterTest.php | 160 +- .../Tests/Adapter/DoctrineAdapterTest.php | 50 +- .../Tests/Adapter/FilesystemAdapterTest.php | 104 +- .../Tests/Adapter/MaxIdLengthAdapterTest.php | 118 +- .../Tests/Adapter/MemcachedAdapterTest.php | 254 +- .../Adapter/NamespacedProxyAdapterTest.php | 48 +- .../cache/Tests/Adapter/NullAdapterTest.php | 202 +- .../cache/Tests/Adapter/PdoAdapterTest.php | 114 +- .../Tests/Adapter/PdoDbalAdapterTest.php | 80 +- .../Tests/Adapter/PhpArrayAdapterTest.php | 142 +- .../PhpArrayAdapterWithFallbackTest.php | 74 +- .../Tests/Adapter/PhpFilesAdapterTest.php | 76 +- .../cache/Tests/Adapter/PredisAdapterTest.php | 64 +- .../Adapter/PredisClusterAdapterTest.php | 48 +- .../Adapter/PredisRedisClusterAdapterTest.php | 52 +- .../cache/Tests/Adapter/ProxyAdapterTest.php | 110 +- .../cache/Tests/Adapter/RedisAdapterTest.php | 142 +- .../Tests/Adapter/RedisArrayAdapterTest.php | 46 +- .../Tests/Adapter/RedisClusterAdapterTest.php | 50 +- .../Tests/Adapter/SimpleCacheAdapterTest.php | 68 +- .../Tests/Adapter/TagAwareAdapterTest.php | 458 +- ...TagAwareAndProxyAdapterIntegrationTest.php | 68 +- .../Tests/Adapter/TraceableAdapterTest.php | 332 +- .../Adapter/TraceableTagAwareAdapterTest.php | 68 +- vendor/symfony/cache/Tests/Adapter/index.php | 72 +- vendor/symfony/cache/Tests/CacheItemTest.php | 106 +- .../cache/Tests/DoctrineProviderTest.php | 74 +- .../cache/Tests/Fixtures/ArrayCache.php | 80 +- .../cache/Tests/Fixtures/ExternalAdapter.php | 128 +- vendor/symfony/cache/Tests/Fixtures/index.php | 72 +- .../Tests/Simple/AbstractRedisCacheTest.php | 72 +- .../cache/Tests/Simple/ApcuCacheTest.php | 54 +- .../cache/Tests/Simple/ArrayCacheTest.php | 46 +- .../cache/Tests/Simple/CacheTestCase.php | 238 +- .../cache/Tests/Simple/ChainCacheTest.php | 156 +- .../cache/Tests/Simple/DoctrineCacheTest.php | 50 +- .../Tests/Simple/FilesystemCacheTest.php | 60 +- .../cache/Tests/Simple/MemcachedCacheTest.php | 222 +- .../Simple/MemcachedCacheTextModeTest.php | 44 +- .../cache/Tests/Simple/NullCacheTest.php | 154 +- .../cache/Tests/Simple/PdoCacheTest.php | 78 +- .../cache/Tests/Simple/PdoDbalCacheTest.php | 80 +- .../cache/Tests/Simple/PhpArrayCacheTest.php | 170 +- .../Simple/PhpArrayCacheWithFallbackTest.php | 100 +- .../cache/Tests/Simple/PhpFilesCacheTest.php | 68 +- .../cache/Tests/Simple/Psr6CacheTest.php | 50 +- .../Tests/Simple/RedisArrayCacheTest.php | 46 +- .../cache/Tests/Simple/RedisCacheTest.php | 126 +- .../Tests/Simple/RedisClusterCacheTest.php | 50 +- .../cache/Tests/Simple/TraceableCacheTest.php | 296 +- vendor/symfony/cache/Tests/Simple/index.php | 72 +- .../cache/Tests/Traits/PdoPruneableTrait.php | 58 +- vendor/symfony/cache/Tests/Traits/index.php | 72 +- vendor/symfony/cache/Tests/index.php | 72 +- vendor/symfony/cache/Traits/AbstractTrait.php | 472 +- vendor/symfony/cache/Traits/ApcuTrait.php | 268 +- vendor/symfony/cache/Traits/ArrayTrait.php | 186 +- vendor/symfony/cache/Traits/DoctrineTrait.php | 170 +- .../cache/Traits/FilesystemCommonTrait.php | 236 +- .../symfony/cache/Traits/FilesystemTrait.php | 184 +- .../symfony/cache/Traits/MemcachedTrait.php | 512 +- vendor/symfony/cache/Traits/PdoTrait.php | 694 +- vendor/symfony/cache/Traits/PhpArrayTrait.php | 258 +- vendor/symfony/cache/Traits/PhpFilesTrait.php | 276 +- vendor/symfony/cache/Traits/ProxyTrait.php | 78 +- vendor/symfony/cache/Traits/RedisProxy.php | 106 +- vendor/symfony/cache/Traits/RedisTrait.php | 660 +- vendor/symfony/cache/Traits/index.php | 72 +- vendor/symfony/cache/composer.json | 108 +- vendor/symfony/cache/index.php | 72 +- vendor/symfony/cache/phpunit.xml.dist | 100 +- vendor/symfony/config/.gitignore | 6 +- vendor/symfony/config/CHANGELOG.md | 156 +- vendor/symfony/config/ConfigCache.php | 110 +- vendor/symfony/config/ConfigCacheFactory.php | 92 +- .../config/ConfigCacheFactoryInterface.php | 62 +- .../symfony/config/ConfigCacheInterface.php | 90 +- .../symfony/config/Definition/ArrayNode.php | 660 +- vendor/symfony/config/Definition/BaseNode.php | 672 +- .../symfony/config/Definition/BooleanNode.php | 86 +- .../Builder/ArrayNodeDefinition.php | 864 +- .../Builder/BooleanNodeDefinition.php | 96 +- .../Definition/Builder/EnumNodeDefinition.php | 96 +- .../config/Definition/Builder/ExprBuilder.php | 478 +- .../Builder/FloatNodeDefinition.php | 60 +- .../Builder/IntegerNodeDefinition.php | 60 +- .../Definition/Builder/MergeBuilder.php | 120 +- .../config/Definition/Builder/NodeBuilder.php | 408 +- .../Definition/Builder/NodeDefinition.php | 620 +- .../Builder/NodeParentInterface.php | 40 +- .../Builder/NormalizationBuilder.php | 106 +- .../Builder/NumericNodeDefinition.php | 132 +- .../Builder/ParentNodeDefinitionInterface.php | 92 +- .../Builder/ScalarNodeDefinition.php | 60 +- .../config/Definition/Builder/TreeBuilder.php | 120 +- .../Definition/Builder/ValidationBuilder.php | 78 +- .../Builder/VariableNodeDefinition.php | 112 +- .../config/Definition/Builder/index.php | 72 +- .../Definition/ConfigurationInterface.php | 52 +- .../Definition/Dumper/XmlReferenceDumper.php | 514 +- .../Definition/Dumper/YamlReferenceDumper.php | 410 +- .../config/Definition/Dumper/index.php | 72 +- vendor/symfony/config/Definition/EnumNode.php | 90 +- .../Exception/DuplicateKeyException.php | 42 +- .../config/Definition/Exception/Exception.php | 40 +- .../Exception/ForbiddenOverwriteException.php | 42 +- .../InvalidConfigurationException.php | 90 +- .../Exception/InvalidDefinitionException.php | 40 +- .../Exception/InvalidTypeException.php | 40 +- .../Exception/UnsetKeyException.php | 42 +- .../config/Definition/Exception/index.php | 72 +- .../symfony/config/Definition/FloatNode.php | 78 +- .../symfony/config/Definition/IntegerNode.php | 70 +- .../config/Definition/NodeInterface.php | 182 +- .../symfony/config/Definition/NumericNode.php | 114 +- .../symfony/config/Definition/Processor.php | 178 +- .../Definition/PrototypeNodeInterface.php | 52 +- .../config/Definition/PrototypedArrayNode.php | 674 +- .../symfony/config/Definition/ScalarNode.php | 98 +- .../config/Definition/VariableNode.php | 226 +- vendor/symfony/config/Definition/index.php | 72 +- .../DependencyInjection/ConfigCachePass.php | 88 +- .../config/DependencyInjection/index.php | 72 +- ...LoaderImportCircularReferenceException.php | 50 +- .../Exception/FileLoaderLoadException.php | 190 +- .../FileLocatorFileNotFoundException.php | 60 +- vendor/symfony/config/Exception/index.php | 72 +- vendor/symfony/config/FileLocator.php | 156 +- .../symfony/config/FileLocatorInterface.php | 64 +- vendor/symfony/config/LICENSE | 38 +- .../config/Loader/DelegatingLoader.php | 90 +- vendor/symfony/config/Loader/FileLoader.php | 304 +- .../symfony/config/Loader/GlobFileLoader.php | 68 +- vendor/symfony/config/Loader/Loader.php | 138 +- .../symfony/config/Loader/LoaderInterface.php | 96 +- .../symfony/config/Loader/LoaderResolver.php | 124 +- .../config/Loader/LoaderResolverInterface.php | 58 +- vendor/symfony/config/Loader/index.php | 72 +- vendor/symfony/config/README.md | 30 +- .../Resource/ClassExistenceResource.php | 390 +- .../config/Resource/ComposerResource.php | 146 +- .../config/Resource/DirectoryResource.php | 214 +- .../config/Resource/FileExistenceResource.php | 136 +- .../symfony/config/Resource/FileResource.php | 146 +- .../symfony/config/Resource/GlobResource.php | 266 +- .../Resource/ReflectionClassResource.php | 408 +- .../config/Resource/ResourceInterface.php | 64 +- .../Resource/SelfCheckingResourceChecker.php | 66 +- .../SelfCheckingResourceInterface.php | 58 +- vendor/symfony/config/Resource/index.php | 72 +- .../config/ResourceCheckerConfigCache.php | 326 +- .../ResourceCheckerConfigCacheFactory.php | 86 +- .../config/ResourceCheckerInterface.php | 90 +- .../config/Tests/ConfigCacheFactoryTest.php | 48 +- .../symfony/config/Tests/ConfigCacheTest.php | 158 +- .../config/Tests/Definition/ArrayNodeTest.php | 312 +- .../Tests/Definition/BooleanNodeTest.php | 106 +- .../Builder/ArrayNodeDefinitionTest.php | 466 +- .../Builder/BooleanNodeDefinitionTest.php | 64 +- .../Builder/EnumNodeDefinitionTest.php | 122 +- .../Definition/Builder/ExprBuilderTest.php | 338 +- .../Definition/Builder/NodeBuilderTest.php | 132 +- .../Builder/NumericNodeDefinitionTest.php | 158 +- .../Definition/Builder/TreeBuilderTest.php | 166 +- .../config/Tests/Definition/Builder/index.php | 72 +- .../Dumper/XmlReferenceDumperTest.php | 216 +- .../Dumper/YamlReferenceDumperTest.php | 256 +- .../config/Tests/Definition/Dumper/index.php | 72 +- .../config/Tests/Definition/EnumNodeTest.php | 90 +- .../Tests/Definition/FinalizationTest.php | 64 +- .../config/Tests/Definition/FloatNodeTest.php | 124 +- .../Tests/Definition/IntegerNodeTest.php | 106 +- .../config/Tests/Definition/MergeTest.php | 118 +- .../Tests/Definition/NormalizationTest.php | 214 +- .../Definition/PrototypedArrayNodeTest.php | 528 +- .../Tests/Definition/ScalarNodeTest.php | 226 +- .../symfony/config/Tests/Definition/index.php | 72 +- .../ConfigCachePassTest.php | 92 +- .../Tests/DependencyInjection/index.php | 72 +- .../Exception/FileLoaderLoadExceptionTest.php | 114 +- .../symfony/config/Tests/Exception/index.php | 72 +- .../symfony/config/Tests/FileLocatorTest.php | 128 +- .../config/Tests/Fixtures/Again/index.php | 72 +- .../config/Tests/Fixtures/BadFileName.php | 16 +- .../config/Tests/Fixtures/BadParent.php | 14 +- .../symfony/config/Tests/Fixtures/BarNode.php | 32 +- .../Fixtures/Builder/BarNodeDefinition.php | 42 +- .../Tests/Fixtures/Builder/NodeBuilder.php | 62 +- .../Builder/VariableNodeDefinition.php | 32 +- .../config/Tests/Fixtures/Builder/index.php | 72 +- .../Configuration/ExampleConfiguration.php | 204 +- .../Tests/Fixtures/Configuration/index.php | 72 +- .../config/Tests/Fixtures/ParseError.php | 14 +- .../Fixtures/Resource/ConditionalClass.php | 18 +- .../config/Tests/Fixtures/Resource/index.php | 72 +- .../Tests/Fixtures/Util/document_type.xml | 6 +- .../config/Tests/Fixtures/Util/index.php | 72 +- .../config/Tests/Fixtures/Util/invalid.xml | 4 +- .../Tests/Fixtures/Util/invalid_schema.xml | 4 +- .../config/Tests/Fixtures/Util/schema.xsd | 18 +- .../config/Tests/Fixtures/Util/valid.xml | 6 +- .../symfony/config/Tests/Fixtures/index.php | 72 +- .../Tests/Loader/DelegatingLoaderTest.php | 120 +- .../config/Tests/Loader/FileLoaderTest.php | 216 +- .../Tests/Loader/LoaderResolverTest.php | 78 +- .../config/Tests/Loader/LoaderTest.php | 152 +- vendor/symfony/config/Tests/Loader/index.php | 72 +- .../Resource/ClassExistenceResourceTest.php | 212 +- .../Tests/Resource/ComposerResourceTest.php | 78 +- .../Tests/Resource/DirectoryResourceTest.php | 300 +- .../Resource/FileExistenceResourceTest.php | 118 +- .../Tests/Resource/FileResourceTest.php | 138 +- .../Tests/Resource/GlobResourceTest.php | 176 +- .../Resource/ReflectionClassResourceTest.php | 382 +- .../config/Tests/Resource/ResourceStub.php | 58 +- .../symfony/config/Tests/Resource/index.php | 72 +- .../Tests/ResourceCheckerConfigCacheTest.php | 220 +- .../config/Tests/Util/XmlUtilsTest.php | 316 +- vendor/symfony/config/Tests/Util/index.php | 72 +- vendor/symfony/config/Tests/index.php | 72 +- .../Util/Exception/InvalidXmlException.php | 42 +- .../Util/Exception/XmlParsingException.php | 40 +- .../symfony/config/Util/Exception/index.php | 72 +- vendor/symfony/config/Util/XmlUtils.php | 476 +- vendor/symfony/config/Util/index.php | 72 +- vendor/symfony/config/composer.json | 98 +- vendor/symfony/config/index.php | 72 +- vendor/symfony/config/phpunit.xml.dist | 62 +- .../symfony/dependency-injection/.gitignore | 6 +- vendor/symfony/dependency-injection/Alias.php | 170 +- .../Argument/ArgumentInterface.php | 50 +- .../Argument/BoundArgument.php | 82 +- .../Argument/IteratorArgument.php | 98 +- .../Argument/RewindableGenerator.php | 80 +- .../Argument/ServiceClosureArgument.php | 88 +- .../Argument/TaggedIteratorArgument.php | 66 +- .../dependency-injection/Argument/index.php | 72 +- .../symfony/dependency-injection/CHANGELOG.md | 232 +- .../dependency-injection/ChildDefinition.php | 226 +- .../Compiler/AbstractRecursivePass.php | 306 +- .../Compiler/AnalyzeServiceReferencesPass.php | 306 +- .../Compiler/AutoAliasServicePass.php | 76 +- .../Compiler/AutowireExceptionPass.php | 126 +- .../Compiler/AutowirePass.php | 946 +-- .../Compiler/AutowireRequiredMethodsPass.php | 124 +- .../Compiler/CheckArgumentsValidityPass.php | 152 +- .../Compiler/CheckCircularReferencesPass.php | 136 +- .../Compiler/CheckDefinitionValidityPass.php | 162 +- ...xceptionOnInvalidReferenceBehaviorPass.php | 66 +- .../Compiler/CheckReferenceValidityPass.php | 78 +- .../Compiler/Compiler.php | 288 +- .../Compiler/CompilerPassInterface.php | 50 +- .../Compiler/DecoratorServicePass.php | 144 +- .../Compiler/DefinitionErrorExceptionPass.php | 70 +- .../Compiler/ExtensionCompilerPass.php | 68 +- .../Compiler/FactoryReturnTypePass.php | 202 +- .../Compiler/InlineServiceDefinitionsPass.php | 256 +- .../Compiler/LoggingFormatter.php | 94 +- .../MergeExtensionConfigurationPass.php | 356 +- .../Compiler/PassConfig.php | 402 +- .../Compiler/PriorityTaggedServiceTrait.php | 98 +- .../Compiler/RegisterEnvVarProcessorsPass.php | 134 +- .../RegisterServiceSubscribersPass.php | 180 +- .../RemoveAbstractDefinitionsPass.php | 62 +- .../Compiler/RemovePrivateAliasesPass.php | 72 +- .../Compiler/RemoveUnusedDefinitionsPass.php | 152 +- .../Compiler/RepeatablePassInterface.php | 44 +- .../Compiler/RepeatedPass.php | 140 +- .../ReplaceAliasByActualDefinitionPass.php | 166 +- .../Compiler/ResolveBindingsPass.php | 296 +- .../Compiler/ResolveChildDefinitionsPass.php | 354 +- .../Compiler/ResolveClassPass.php | 102 +- .../ResolveDefinitionTemplatesPass.php | 52 +- .../Compiler/ResolveEnvPlaceholdersPass.php | 78 +- .../Compiler/ResolveFactoryClassPass.php | 68 +- .../Compiler/ResolveHotPathPass.php | 128 +- .../ResolveInstanceofConditionalsPass.php | 258 +- .../Compiler/ResolveInvalidReferencesPass.php | 204 +- .../Compiler/ResolveNamedArgumentsPass.php | 172 +- .../ResolveParameterPlaceHoldersPass.php | 168 +- .../Compiler/ResolvePrivatesPass.php | 74 +- .../ResolveReferencesToAliasesPass.php | 136 +- .../ResolveServiceSubscribersPass.php | 88 +- .../ResolveTaggedIteratorArgumentPass.php | 66 +- .../Compiler/ServiceLocatorTagPass.php | 198 +- .../Compiler/ServiceReferenceGraph.php | 228 +- .../Compiler/ServiceReferenceGraphEdge.php | 194 +- .../Compiler/ServiceReferenceGraphNode.php | 212 +- .../dependency-injection/Compiler/index.php | 72 +- .../Config/AutowireServiceResource.php | 152 +- .../Config/ContainerParametersResource.php | 114 +- .../ContainerParametersResourceChecker.php | 92 +- .../dependency-injection/Config/index.php | 72 +- .../dependency-injection/Container.php | 930 +-- .../ContainerAwareInterface.php | 48 +- .../ContainerAwareTrait.php | 56 +- .../dependency-injection/ContainerBuilder.php | 2900 +++---- .../ContainerInterface.php | 182 +- .../dependency-injection/Definition.php | 1686 ++-- .../DefinitionDecorator.php | 52 +- .../dependency-injection/Dumper/Dumper.php | 52 +- .../Dumper/DumperInterface.php | 52 +- .../Dumper/GraphvizDumper.php | 508 +- .../dependency-injection/Dumper/PhpDumper.php | 3500 ++++----- .../dependency-injection/Dumper/XmlDumper.php | 650 +- .../Dumper/YamlDumper.php | 656 +- .../dependency-injection/Dumper/index.php | 72 +- .../dependency-injection/EnvVarProcessor.php | 252 +- .../EnvVarProcessorInterface.php | 74 +- .../Exception/AutowiringFailedException.php | 56 +- .../Exception/BadMethodCallException.php | 36 +- .../Exception/EnvNotFoundException.php | 48 +- .../Exception/EnvParameterException.php | 48 +- .../Exception/ExceptionInterface.php | 44 +- .../Exception/InvalidArgumentException.php | 40 +- .../Exception/LogicException.php | 36 +- .../Exception/OutOfBoundsException.php | 36 +- .../ParameterCircularReferenceException.php | 60 +- .../Exception/ParameterNotFoundException.php | 170 +- .../Exception/RuntimeException.php | 40 +- .../ServiceCircularReferenceException.php | 72 +- .../Exception/ServiceNotFoundException.php | 116 +- .../dependency-injection/Exception/index.php | 72 +- .../ExpressionLanguage.php | 64 +- .../ExpressionLanguageProvider.php | 84 +- .../ConfigurationExtensionInterface.php | 56 +- .../Extension/Extension.php | 232 +- .../Extension/ExtensionInterface.php | 94 +- .../Extension/PrependExtensionInterface.php | 40 +- .../dependency-injection/Extension/index.php | 72 +- vendor/symfony/dependency-injection/LICENSE | 38 +- .../Instantiator/InstantiatorInterface.php | 68 +- .../Instantiator/RealServiceInstantiator.php | 62 +- .../LazyProxy/Instantiator/index.php | 72 +- .../LazyProxy/PhpDumper/DumperInterface.php | 82 +- .../LazyProxy/PhpDumper/NullDumper.php | 88 +- .../LazyProxy/PhpDumper/index.php | 72 +- .../LazyProxy/ProxyHelper.php | 118 +- .../dependency-injection/LazyProxy/index.php | 72 +- .../Loader/ClosureLoader.php | 86 +- .../Configurator/AbstractConfigurator.php | 146 +- .../AbstractServiceConfigurator.php | 206 +- .../Loader/Configurator/AliasConfigurator.php | 52 +- .../Configurator/ContainerConfigurator.php | 246 +- .../Configurator/DefaultsConfigurator.php | 120 +- .../InlineServiceConfigurator.php | 64 +- .../Configurator/InstanceofConfigurator.php | 80 +- .../Configurator/ParametersConfigurator.php | 100 +- .../Configurator/PrototypeConfigurator.php | 146 +- .../Configurator/ReferenceConfigurator.php | 110 +- .../Configurator/ServiceConfigurator.php | 122 +- .../Configurator/ServicesConfigurator.php | 272 +- .../Configurator/Traits/AbstractTrait.php | 62 +- .../Configurator/Traits/ArgumentTrait.php | 80 +- .../Traits/AutoconfigureTrait.php | 68 +- .../Configurator/Traits/AutowireTrait.php | 54 +- .../Loader/Configurator/Traits/BindTrait.php | 80 +- .../Loader/Configurator/Traits/CallTrait.php | 62 +- .../Loader/Configurator/Traits/ClassTrait.php | 60 +- .../Configurator/Traits/ConfiguratorTrait.php | 54 +- .../Configurator/Traits/DecorateTrait.php | 64 +- .../Configurator/Traits/DeprecateTrait.php | 60 +- .../Configurator/Traits/FactoryTrait.php | 64 +- .../Loader/Configurator/Traits/FileTrait.php | 54 +- .../Loader/Configurator/Traits/LazyTrait.php | 54 +- .../Configurator/Traits/ParentTrait.php | 100 +- .../Configurator/Traits/PropertyTrait.php | 56 +- .../Configurator/Traits/PublicTrait.php | 70 +- .../Loader/Configurator/Traits/ShareTrait.php | 54 +- .../Configurator/Traits/SyntheticTrait.php | 56 +- .../Loader/Configurator/Traits/TagTrait.php | 74 +- .../Loader/Configurator/Traits/index.php | 72 +- .../Loader/Configurator/index.php | 72 +- .../Loader/DirectoryLoader.php | 98 +- .../Loader/FileLoader.php | 306 +- .../Loader/GlobFileLoader.php | 74 +- .../Loader/IniFileLoader.php | 162 +- .../Loader/PhpFileLoader.php | 126 +- .../Loader/XmlFileLoader.php | 1242 +-- .../Loader/YamlFileLoader.php | 1324 ++-- .../dependency-injection/Loader/index.php | 72 +- .../Loader/schema/dic/index.php | 72 +- .../Loader/schema/dic/services/index.php | 72 +- .../schema/dic/services/services-1.0.xsd | 562 +- .../Loader/schema/index.php | 72 +- .../dependency-injection/Parameter.php | 70 +- .../EnvPlaceholderParameterBag.php | 216 +- .../ParameterBag/FrozenParameterBag.php | 124 +- .../ParameterBag/ParameterBag.php | 526 +- .../ParameterBag/ParameterBagInterface.php | 206 +- .../ParameterBag/index.php | 72 +- vendor/symfony/dependency-injection/README.md | 28 +- .../dependency-injection/Reference.php | 98 +- .../ResettableContainerInterface.php | 60 +- .../dependency-injection/ServiceLocator.php | 254 +- .../ServiceSubscriberInterface.php | 98 +- .../TaggedContainerInterface.php | 56 +- .../Argument/RewindableGeneratorTest.php | 88 +- .../Tests/Argument/index.php | 72 +- .../Tests/ChildDefinitionTest.php | 232 +- .../AnalyzeServiceReferencesPassTest.php | 230 +- .../Compiler/AutoAliasServicePassTest.php | 158 +- .../Compiler/AutowireExceptionPassTest.php | 192 +- .../Tests/Compiler/AutowirePassTest.php | 1294 +-- .../AutowireRequiredMethodsPassTest.php | 104 +- .../CheckArgumentsValidityPassTest.php | 116 +- .../CheckCircularReferencesPassTest.php | 216 +- .../CheckDefinitionValidityPassTest.php | 178 +- ...tionOnInvalidReferenceBehaviorPassTest.php | 114 +- .../CheckReferenceValidityPassTest.php | 80 +- .../Compiler/DecoratorServicePassTest.php | 214 +- .../DefinitionErrorExceptionPassTest.php | 80 +- .../Compiler/ExtensionCompilerPassTest.php | 136 +- .../Compiler/FactoryReturnTypePassTest.php | 202 +- .../InlineServiceDefinitionsPassTest.php | 370 +- .../Tests/Compiler/IntegrationTest.php | 292 +- .../MergeExtensionConfigurationPassTest.php | 298 +- .../Tests/Compiler/OptionalServiceClass.php | 32 +- .../Tests/Compiler/PassConfigTest.php | 66 +- .../PriorityTaggedServiceTraitTest.php | 82 +- .../RegisterEnvVarProcessorsPassTest.php | 122 +- .../RegisterServiceSubscribersPassTest.php | 162 +- .../RemoveUnusedDefinitionsPassTest.php | 162 +- ...ReplaceAliasByActualDefinitionPassTest.php | 106 +- .../Compiler/ResolveBindingsPassTest.php | 220 +- .../ResolveChildDefinitionsPassTest.php | 502 +- .../Tests/Compiler/ResolveClassPassTest.php | 156 +- .../ResolveDefinitionTemplatesPassTest.php | 446 +- .../Compiler/ResolveFactoryClassPassTest.php | 130 +- .../Tests/Compiler/ResolveHotPathPassTest.php | 80 +- .../ResolveInstanceofConditionalsPassTest.php | 338 +- .../ResolveInvalidReferencesPassTest.php | 152 +- .../ResolveNamedArgumentsPassTest.php | 258 +- .../ResolveParameterPlaceHoldersPassTest.php | 206 +- .../Compiler/ResolvePrivatesPassTest.php | 54 +- .../ResolveReferencesToAliasesPassTest.php | 140 +- .../ResolveTaggedIteratorArgumentPassTest.php | 72 +- .../Compiler/ServiceLocatorTagPassTest.php | 174 +- .../Tests/Compiler/index.php | 72 +- .../Config/AutowireServiceResourceTest.php | 180 +- ...ContainerParametersResourceCheckerTest.php | 116 +- .../ContainerParametersResourceTest.php | 72 +- .../Tests/Config/index.php | 72 +- .../Tests/ContainerBuilderTest.php | 2286 +++--- .../Tests/ContainerTest.php | 1122 +-- .../Tests/CrossCheckTest.php | 132 +- .../Tests/DefinitionDecoratorTest.php | 198 +- .../Tests/DefinitionTest.php | 618 +- .../Tests/Dumper/GraphvizDumperTest.php | 130 +- .../Tests/Dumper/PhpDumperTest.php | 1698 ++-- .../Tests/Dumper/XmlDumperTest.php | 288 +- .../Tests/Dumper/YamlDumperTest.php | 166 +- .../Tests/Dumper/index.php | 72 +- .../Tests/EnvVarProcessorTest.php | 400 +- .../Tests/Extension/ExtensionTest.php | 94 +- .../Tests/Extension/index.php | 72 +- .../Tests/Fixtures/Bar.php | 46 +- .../Tests/Fixtures/BarInterface.php | 30 +- .../Tests/Fixtures/CaseSensitiveClass.php | 40 +- ...tructorWithMandatoryArgumentsContainer.php | 20 +- ...structorWithOptionalArgumentsContainer.php | 20 +- .../ConstructorWithoutArgumentsContainer.php | 20 +- .../Container/NoConstructorContainer.php | 16 +- .../Tests/Fixtures/Container/index.php | 72 +- .../Tests/Fixtures/CustomDefinition.php | 32 +- .../Tests/Fixtures/DeprecatedClass.php | 32 +- .../Tests/Fixtures/FactoryDummy.php | 74 +- .../FactoryDummyWithoutReturnTypes.php | 36 +- .../Fixtures/FooForCircularWithAddCalls.php | 36 +- .../Tests/Fixtures/NamedArgumentsDummy.php | 38 +- .../Tests/Fixtures/ParentNotExists.php | 14 +- .../Prototype/BadClasses/MissingParent.php | 14 +- .../Fixtures/Prototype/BadClasses/index.php | 72 +- .../Tests/Fixtures/Prototype/Foo.php | 26 +- .../Tests/Fixtures/Prototype/FooInterface.php | 14 +- .../OtherDir/AnotherSub/DeeperBaz.php | 14 +- .../Prototype/OtherDir/AnotherSub/index.php | 72 +- .../Tests/Fixtures/Prototype/OtherDir/Baz.php | 14 +- .../OtherDir/Component1/Dir1/Service1.php | 14 +- .../OtherDir/Component1/Dir1/index.php | 72 +- .../OtherDir/Component1/Dir2/Service2.php | 14 +- .../OtherDir/Component1/Dir2/index.php | 72 +- .../Prototype/OtherDir/Component1/index.php | 72 +- .../OtherDir/Component2/Dir1/Service4.php | 14 +- .../OtherDir/Component2/Dir1/index.php | 72 +- .../OtherDir/Component2/Dir2/Service5.php | 14 +- .../OtherDir/Component2/Dir2/index.php | 72 +- .../Prototype/OtherDir/Component2/index.php | 72 +- .../Fixtures/Prototype/OtherDir/index.php | 72 +- .../Tests/Fixtures/Prototype/Sub/Bar.php | 14 +- .../Fixtures/Prototype/Sub/BarInterface.php | 14 +- .../Tests/Fixtures/Prototype/Sub/index.php | 72 +- .../Tests/Fixtures/Prototype/index.php | 72 +- .../Tests/Fixtures/ScalarFactory.php | 28 +- .../Tests/Fixtures/SimilarArgumentsDummy.php | 44 +- .../Tests/Fixtures/StubbedTranslator.php | 50 +- .../Tests/Fixtures/TestDefinition1.php | 32 +- .../Tests/Fixtures/TestDefinition2.php | 16 +- .../Tests/Fixtures/TestServiceSubscriber.php | 30 +- .../Tests/Fixtures/array.json | 2 +- .../Tests/Fixtures/config/basic.expected.yml | 20 +- .../Tests/Fixtures/config/basic.php | 18 +- .../Tests/Fixtures/config/child.expected.yml | 30 +- .../Tests/Fixtures/config/child.php | 16 +- .../Fixtures/config/defaults.expected.yml | 54 +- .../Tests/Fixtures/config/defaults.php | 22 +- .../config/factory_short_notation.php | 14 +- .../Tests/Fixtures/config/index.php | 72 +- .../Fixtures/config/instanceof.expected.yml | 42 +- .../Tests/Fixtures/config/instanceof.php | 24 +- .../Tests/Fixtures/config/php7.expected.yml | 38 +- .../Tests/Fixtures/config/php7.php | 18 +- .../Fixtures/config/prototype.expected.yml | 50 +- .../Tests/Fixtures/config/prototype.php | 22 +- .../Tests/Fixtures/config/services9.php | 86 +- .../services_autoconfigure_with_parent.php | 14 +- .../Fixtures/containers/CustomContainer.php | 30 +- .../Tests/Fixtures/containers/container10.php | 20 +- .../Tests/Fixtures/containers/container11.php | 18 +- .../Tests/Fixtures/containers/container12.php | 16 +- .../Tests/Fixtures/containers/container13.php | 22 +- .../Tests/Fixtures/containers/container14.php | 30 +- .../Tests/Fixtures/containers/container15.php | 16 +- .../Tests/Fixtures/containers/container16.php | 16 +- .../Tests/Fixtures/containers/container17.php | 16 +- .../Tests/Fixtures/containers/container19.php | 30 +- .../Tests/Fixtures/containers/container21.php | 26 +- .../Tests/Fixtures/containers/container24.php | 16 +- .../Tests/Fixtures/containers/container33.php | 18 +- .../Tests/Fixtures/containers/container8.php | 16 +- .../Tests/Fixtures/containers/container9.php | 92 +- .../containers/container_abstract.php | 16 +- .../containers/container_almost_circular.php | 124 +- .../containers/container_env_in_id.php | 30 +- .../containers/container_inline_requires.php | 32 +- .../container_uninitialized_ref.php | 30 +- .../Tests/Fixtures/containers/index.php | 72 +- .../Fixtures/directory/import/import.yml | 4 +- .../Tests/Fixtures/directory/import/index.php | 72 +- .../Tests/Fixtures/directory/index.php | 72 +- .../Fixtures/directory/recurse/index.php | 72 +- .../Fixtures/directory/recurse/simple.ini | 4 +- .../Fixtures/directory/recurse/simple.yml | 4 +- .../Tests/Fixtures/directory/simple.php | 10 +- .../Tests/Fixtures/graphviz/index.php | 72 +- .../Tests/Fixtures/graphviz/services1.dot | 14 +- .../Tests/Fixtures/graphviz/services10-1.dot | 20 +- .../Tests/Fixtures/graphviz/services10.dot | 20 +- .../Tests/Fixtures/graphviz/services13.dot | 20 +- .../Tests/Fixtures/graphviz/services14.dot | 14 +- .../Tests/Fixtures/graphviz/services17.dot | 16 +- .../Tests/Fixtures/graphviz/services18.dot | 16 +- .../Tests/Fixtures/graphviz/services9.dot | 112 +- .../Fixtures/graphviz/services_inline.dot | 20 +- .../Tests/Fixtures/includes/FooVariadic.php | 28 +- .../Tests/Fixtures/includes/HotPath/C1.php | 16 +- .../Tests/Fixtures/includes/HotPath/C2.php | 14 +- .../Tests/Fixtures/includes/HotPath/C3.php | 14 +- .../Tests/Fixtures/includes/HotPath/I1.php | 14 +- .../Tests/Fixtures/includes/HotPath/P1.php | 14 +- .../Tests/Fixtures/includes/HotPath/T1.php | 14 +- .../Tests/Fixtures/includes/HotPath/index.php | 72 +- .../Fixtures/includes/ProjectExtension.php | 82 +- .../includes/ProjectWithXsdExtension.php | 40 +- .../Fixtures/includes/autowiring_classes.php | 576 +- .../Tests/Fixtures/includes/classes.php | 248 +- .../Tests/Fixtures/includes/createphar.php | 98 +- .../Tests/Fixtures/includes/foo.php | 72 +- .../Tests/Fixtures/includes/index.php | 72 +- .../Tests/Fixtures/includes/schema/index.php | 72 +- .../Fixtures/includes/schema/project-1.0.xsd | 26 +- .../Tests/Fixtures/index.php | 72 +- .../Tests/Fixtures/ini/almostvalid.ini | 4 +- .../Tests/Fixtures/ini/index.php | 72 +- .../Tests/Fixtures/ini/ini_with_wrong_ext.xml | 4 +- .../Tests/Fixtures/ini/nonvalid.ini | 4 +- .../Tests/Fixtures/ini/parameters.ini | 6 +- .../Tests/Fixtures/ini/parameters1.ini | 6 +- .../Tests/Fixtures/ini/parameters2.ini | 4 +- .../Tests/Fixtures/ini/types.ini | 56 +- ...er_class_constructor_without_arguments.php | 92 +- ...s_with_mandatory_constructor_arguments.php | 88 +- ...ss_with_optional_constructor_arguments.php | 92 +- ...om_container_class_without_constructor.php | 88 +- .../Tests/Fixtures/php/index.php | 72 +- .../Tests/Fixtures/php/php_with_wrong_ext.yml | 6 +- .../Tests/Fixtures/php/services1-1.php | 88 +- .../Tests/Fixtures/php/services1.php | 102 +- .../Tests/Fixtures/php/services10.php | 268 +- .../Tests/Fixtures/php/services12.php | 298 +- .../Tests/Fixtures/php/services13.php | 126 +- .../Tests/Fixtures/php/services19.php | 306 +- .../Tests/Fixtures/php/services24.php | 122 +- .../Tests/Fixtures/php/services26.php | 336 +- .../Tests/Fixtures/php/services33.php | 142 +- .../Tests/Fixtures/php/services8.php | 248 +- .../Tests/Fixtures/php/services9.php | 722 +- .../Tests/Fixtures/php/services9_as_files.txt | 1016 +-- .../Tests/Fixtures/php/services9_compiled.php | 738 +- .../Tests/Fixtures/php/services_adawson.php | 280 +- .../php/services_almost_circular_private.php | 736 +- .../php/services_almost_circular_public.php | 946 +-- .../Fixtures/php/services_array_params.php | 296 +- .../Fixtures/php/services_base64_env.php | 264 +- .../php/services_dedup_lazy_proxy.php | 154 +- .../Fixtures/php/services_deep_graph.php | 160 +- .../Tests/Fixtures/php/services_env_in_id.php | 308 +- .../Fixtures/php/services_inline_requires.php | 352 +- .../Fixtures/php/services_inline_self_ref.php | 134 +- .../Fixtures/php/services_legacy_privates.php | 294 +- .../Tests/Fixtures/php/services_locator.php | 310 +- .../Fixtures/php/services_non_shared_lazy.php | 154 +- .../Fixtures/php/services_private_frozen.php | 160 +- .../php/services_private_in_expression.php | 142 +- .../Tests/Fixtures/php/services_rot13_env.php | 308 +- .../Fixtures/php/services_subscriber.php | 202 +- .../Tests/Fixtures/php/services_tsantos.php | 146 +- .../php/services_uninitialized_ref.php | 230 +- .../php/services_unsupported_characters.php | 304 +- .../Tests/Fixtures/php/simple.php | 10 +- .../Tests/Fixtures/xml/class_from_id.xml | 12 +- .../Tests/Fixtures/xml/defaults_bindings.xml | 30 +- .../Tests/Fixtures/xml/defaults_bindings2.xml | 20 +- .../Tests/Fixtures/xml/extension1/index.php | 72 +- .../Fixtures/xml/extension1/services.xml | 28 +- .../Tests/Fixtures/xml/extension2/index.php | 72 +- .../Fixtures/xml/extension2/services.xml | 28 +- .../Tests/Fixtures/xml/extensions/index.php | 72 +- .../Fixtures/xml/extensions/services1.xml | 38 +- .../Fixtures/xml/extensions/services2.xml | 38 +- .../Fixtures/xml/extensions/services3.xml | 38 +- .../Fixtures/xml/extensions/services4.xml | 12 +- .../Fixtures/xml/extensions/services5.xml | 22 +- .../Fixtures/xml/extensions/services6.xml | 22 +- .../Fixtures/xml/extensions/services7.xml | 22 +- .../Tests/Fixtures/xml/index.php | 72 +- .../xml/legacy_invalid_alias_definition.xml | 22 +- .../Tests/Fixtures/xml/namespaces.xml | 34 +- .../xml/nested_service_without_id.xml | 20 +- .../Tests/Fixtures/xml/nonvalid.xml | 6 +- .../Tests/Fixtures/xml/services1.xml | 16 +- .../Tests/Fixtures/xml/services10.xml | 32 +- .../Tests/Fixtures/xml/services13.xml | 18 +- .../Tests/Fixtures/xml/services14.xml | 38 +- .../Tests/Fixtures/xml/services2.xml | 62 +- .../Tests/Fixtures/xml/services21.xml | 48 +- .../Tests/Fixtures/xml/services22.xml | 18 +- .../Tests/Fixtures/xml/services23.xml | 12 +- .../Tests/Fixtures/xml/services24.xml | 18 +- .../Tests/Fixtures/xml/services28.xml | 26 +- .../Tests/Fixtures/xml/services3.xml | 26 +- .../Tests/Fixtures/xml/services4.xml | 28 +- .../Fixtures/xml/services4_bad_import.xml | 18 +- .../Tests/Fixtures/xml/services5.xml | 50 +- .../Tests/Fixtures/xml/services6.xml | 138 +- .../Tests/Fixtures/xml/services7.xml | 18 +- .../Tests/Fixtures/xml/services8.xml | 76 +- .../Tests/Fixtures/xml/services9.xml | 294 +- .../Tests/Fixtures/xml/services_abstract.xml | 18 +- .../Fixtures/xml/services_autoconfigure.xml | 18 +- .../services_autoconfigure_with_parent.xml | 14 +- .../Tests/Fixtures/xml/services_bindings.xml | 42 +- .../xml/services_defaults_with_parent.xml | 18 +- .../Fixtures/xml/services_deprecated.xml | 22 +- .../Tests/Fixtures/xml/services_dump_load.xml | 22 +- .../xml/services_inline_not_candidate.xml | 22 +- .../Fixtures/xml/services_instanceof.xml | 24 +- .../xml/services_instanceof_with_parent.xml | 18 +- .../Fixtures/xml/services_named_args.xml | 24 +- .../Tests/Fixtures/xml/services_prototype.xml | 12 +- .../Tests/Fixtures/xml/services_tsantos.xml | 130 +- .../Fixtures/xml/services_without_id.xml | 24 +- .../Fixtures/xml/tag_with_empty_name.xml | 22 +- .../Tests/Fixtures/xml/tag_without_name.xml | 22 +- .../xml/with_key_outside_collection.xml | 18 +- .../Tests/Fixtures/xml/withdoctype.xml | 6 +- .../Tests/Fixtures/xml/xml_with_wrong_ext.php | 20 +- .../Fixtures/yaml/anonymous_services.yml | 28 +- .../yaml/anonymous_services_alias.yml | 14 +- .../yaml/anonymous_services_in_instanceof.yml | 30 +- .../yaml/anonymous_services_in_parameters.yml | 4 +- .../Tests/Fixtures/yaml/bad_calls.yml | 8 +- .../Tests/Fixtures/yaml/bad_decorates.yml | 14 +- .../Fixtures/yaml/bad_empty_defaults.yml | 4 +- .../Fixtures/yaml/bad_empty_instanceof.yml | 4 +- .../Tests/Fixtures/yaml/bad_format.yml | 4 +- .../Tests/Fixtures/yaml/bad_import.yml | 4 +- .../Tests/Fixtures/yaml/bad_imports.yml | 4 +- .../Tests/Fixtures/yaml/bad_parameters.yml | 4 +- .../Tests/Fixtures/yaml/bad_service.yml | 4 +- .../Tests/Fixtures/yaml/bad_services.yml | 2 +- .../Tests/Fixtures/yaml/bad_types1.yml | 10 +- .../Tests/Fixtures/yaml/bad_types2.yml | 10 +- .../Tests/Fixtures/yaml/badtag1.yml | 10 +- .../Tests/Fixtures/yaml/badtag2.yml | 12 +- .../Tests/Fixtures/yaml/badtag3.yml | 12 +- .../Tests/Fixtures/yaml/bar/index.php | 72 +- .../Tests/Fixtures/yaml/bar/services.yml | 8 +- .../Tests/Fixtures/yaml/class_from_id.yml | 6 +- .../Tests/Fixtures/yaml/defaults_bindings.yml | 22 +- .../Fixtures/yaml/defaults_bindings2.yml | 14 +- .../Tests/Fixtures/yaml/foo/index.php | 72 +- .../Tests/Fixtures/yaml/foo/services.yml | 8 +- .../Tests/Fixtures/yaml/index.php | 72 +- .../_child.yml | 8 +- .../expected.yml | 20 +- .../autoconfigure_child_not_applied/index.php | 72 +- .../autoconfigure_child_not_applied/main.yml | 14 +- .../autoconfigure_parent_child/_child.yml | 6 +- .../autoconfigure_parent_child/expected.yml | 10 +- .../autoconfigure_parent_child/index.php | 72 +- .../autoconfigure_parent_child/main.yml | 14 +- .../_child.yml | 6 +- .../expected.yml | 12 +- .../autoconfigure_parent_child_tags/index.php | 72 +- .../autoconfigure_parent_child_tags/main.yml | 14 +- .../integration/child_parent/expected.yml | 18 +- .../yaml/integration/child_parent/index.php | 72 +- .../yaml/integration/child_parent/main.yml | 26 +- .../defaults_child_tags/expected.yml | 16 +- .../integration/defaults_child_tags/index.php | 72 +- .../integration/defaults_child_tags/main.yml | 36 +- .../expected.yml | 52 +- .../defaults_instanceof_importance/index.php | 72 +- .../defaults_instanceof_importance/main.yml | 60 +- .../defaults_parent_child/_child.yml | 8 +- .../defaults_parent_child/expected.yml | 12 +- .../defaults_parent_child/index.php | 72 +- .../defaults_parent_child/main.yml | 18 +- .../Tests/Fixtures/yaml/integration/index.php | 72 +- .../instanceof_parent_child/_child.yml | 8 +- .../instanceof_parent_child/expected.yml | 14 +- .../instanceof_parent_child/index.php | 72 +- .../instanceof_parent_child/main.yml | 22 +- .../yaml/legacy_invalid_alias_definition.yml | 10 +- .../yaml/legacy_invalid_definition.yml | 20 +- .../Tests/Fixtures/yaml/nonvalid1.yml | 4 +- .../Tests/Fixtures/yaml/nonvalid2.yml | 2 +- .../Tests/Fixtures/yaml/null_config.yml | 2 +- .../Tests/Fixtures/yaml/services1.yml | 22 +- .../Tests/Fixtures/yaml/services10.yml | 18 +- .../Tests/Fixtures/yaml/services11.yml | 2 +- .../Tests/Fixtures/yaml/services13.yml | 6 +- .../Tests/Fixtures/yaml/services14.yml | 6 +- .../Tests/Fixtures/yaml/services2.yml | 26 +- .../Tests/Fixtures/yaml/services21.yml | 30 +- .../Tests/Fixtures/yaml/services22.yml | 16 +- .../Tests/Fixtures/yaml/services23.yml | 8 +- .../Tests/Fixtures/yaml/services24.yml | 32 +- .../Tests/Fixtures/yaml/services26.yml | 44 +- .../Tests/Fixtures/yaml/services28.yml | 68 +- .../Tests/Fixtures/yaml/services3.yml | 10 +- .../Fixtures/yaml/services31_invalid_tags.yml | 12 +- .../Tests/Fixtures/yaml/services4.yml | 16 +- .../Fixtures/yaml/services4_bad_import.yml | 4 +- .../Tests/Fixtures/yaml/services6.yml | 86 +- .../Tests/Fixtures/yaml/services7.yml | 4 +- .../Tests/Fixtures/yaml/services8.yml | 58 +- .../Tests/Fixtures/yaml/services9.yml | 326 +- .../Tests/Fixtures/yaml/services_adawson.yml | 56 +- .../Fixtures/yaml/services_autoconfigure.yml | 18 +- .../services_autoconfigure_with_parent.yml | 16 +- .../Tests/Fixtures/yaml/services_bindings.yml | 32 +- .../services_configurator_short_syntax.yml | 16 +- .../Fixtures/yaml/services_deep_graph.yml | 48 +- .../yaml/services_defaults_with_parent.yml | 20 +- .../Fixtures/yaml/services_dump_load.yml | 30 +- .../Tests/Fixtures/yaml/services_inline.yml | 32 +- .../Fixtures/yaml/services_instanceof.yml | 22 +- .../yaml/services_instanceof_with_parent.yml | 22 +- .../yaml/services_legacy_privates.yml | 54 +- .../Fixtures/yaml/services_named_args.yml | 20 +- .../Fixtures/yaml/services_prototype.yml | 8 +- .../yaml/services_prototype_namespace.yml | 20 +- ...s_prototype_namespace_without_resource.yml | 8 +- .../Fixtures/yaml/services_underscore.yml | 6 +- .../Fixtures/yaml/tag_name_empty_string.yml | 12 +- .../Fixtures/yaml/tag_name_no_string.yml | 12 +- .../Tests/Fixtures/yaml/tag_name_only.yml | 10 +- .../Fixtures/yaml/yaml_with_wrong_ext.ini | 4 +- .../RealServiceInstantiatorTest.php | 66 +- .../Tests/LazyProxy/Instantiator/index.php | 72 +- .../LazyProxy/PhpDumper/NullDumperTest.php | 62 +- .../Tests/LazyProxy/PhpDumper/index.php | 72 +- .../Tests/LazyProxy/index.php | 72 +- .../Tests/Loader/ClosureLoaderTest.php | 66 +- .../Tests/Loader/DirectoryLoaderTest.php | 126 +- .../Tests/Loader/FileLoaderTest.php | 286 +- .../Tests/Loader/GlobFileLoaderTest.php | 76 +- .../Tests/Loader/IniFileLoaderTest.php | 242 +- .../Tests/Loader/LoaderResolverTest.php | 88 +- .../Tests/Loader/PhpFileLoaderTest.php | 172 +- .../Tests/Loader/XmlFileLoaderTest.php | 1268 +-- .../Tests/Loader/YamlFileLoaderTest.php | 1160 +-- .../Tests/Loader/index.php | 72 +- .../EnvPlaceholderParameterBagTest.php | 260 +- .../ParameterBag/FrozenParameterBagTest.php | 94 +- .../Tests/ParameterBag/ParameterBagTest.php | 380 +- .../Tests/ParameterBag/index.php | 72 +- .../Tests/ParameterTest.php | 44 +- .../Tests/ReferenceTest.php | 44 +- .../Tests/ServiceLocatorTest.php | 262 +- .../dependency-injection/Tests/index.php | 72 +- .../dependency-injection/TypedReference.php | 92 +- .../symfony/dependency-injection/Variable.php | 80 +- .../dependency-injection/composer.json | 112 +- vendor/symfony/dependency-injection/index.php | 72 +- .../dependency-injection/phpunit.xml.dist | 62 +- vendor/symfony/expression-language/.gitignore | 6 +- .../symfony/expression-language/CHANGELOG.md | 24 +- .../symfony/expression-language/Compiler.php | 252 +- .../expression-language/Expression.php | 74 +- .../ExpressionFunction.php | 178 +- .../ExpressionFunctionProviderInterface.php | 44 +- .../ExpressionLanguage.php | 306 +- vendor/symfony/expression-language/LICENSE | 38 +- vendor/symfony/expression-language/Lexer.php | 190 +- .../Node/ArgumentsNode.php | 70 +- .../expression-language/Node/ArrayNode.php | 196 +- .../expression-language/Node/BinaryNode.php | 234 +- .../Node/ConditionalNode.php | 80 +- .../expression-language/Node/ConstantNode.php | 140 +- .../expression-language/Node/FunctionNode.php | 108 +- .../expression-language/Node/GetAttrNode.php | 160 +- .../expression-language/Node/NameNode.php | 74 +- .../symfony/expression-language/Node/Node.php | 182 +- .../expression-language/Node/UnaryNode.php | 92 +- .../expression-language/Node/index.php | 72 +- .../expression-language/ParsedExpression.php | 70 +- vendor/symfony/expression-language/Parser.php | 554 +- .../ParserCache/ArrayParserCache.php | 74 +- .../ParserCache/ParserCacheAdapter.php | 202 +- .../ParserCache/ParserCacheInterface.php | 74 +- .../expression-language/ParserCache/index.php | 72 +- vendor/symfony/expression-language/README.md | 30 +- .../Resources/bin/generate_operator_regex.php | 46 +- .../Resources/bin/index.php | 72 +- .../expression-language/Resources/index.php | 72 +- .../SerializedParsedExpression.php | 68 +- .../expression-language/SyntaxError.php | 74 +- .../Tests/ExpressionFunctionTest.php | 74 +- .../Tests/ExpressionLanguageTest.php | 416 +- .../Tests/ExpressionTest.php | 48 +- .../Tests/Fixtures/TestProvider.php | 60 +- .../Tests/Fixtures/index.php | 72 +- .../expression-language/Tests/LexerTest.php | 106 +- .../Tests/Node/AbstractNodeTest.php | 86 +- .../Tests/Node/ArgumentsNodeTest.php | 56 +- .../Tests/Node/ArrayNodeTest.php | 114 +- .../Tests/Node/BinaryNodeTest.php | 78 +- .../Tests/Node/ConditionalNodeTest.php | 58 +- .../Tests/Node/ConstantNodeTest.php | 56 +- .../Tests/Node/FunctionNodeTest.php | 76 +- .../Tests/Node/GetAttrNodeTest.php | 92 +- .../Tests/Node/NameNodeTest.php | 56 +- .../Tests/Node/NodeTest.php | 70 +- .../Tests/Node/UnaryNodeTest.php | 58 +- .../expression-language/Tests/Node/index.php | 72 +- .../Tests/ParsedExpressionTest.php | 50 +- .../ParserCache/ParserCacheAdapterTest.php | 196 +- .../Tests/ParserCache/index.php | 72 +- .../expression-language/Tests/ParserTest.php | 206 +- .../expression-language/Tests/index.php | 72 +- vendor/symfony/expression-language/Token.php | 122 +- .../expression-language/TokenStream.php | 174 +- .../symfony/expression-language/composer.json | 72 +- vendor/symfony/expression-language/index.php | 72 +- .../expression-language/phpunit.xml.dist | 60 +- vendor/symfony/filesystem/.gitignore | 6 +- vendor/symfony/filesystem/CHANGELOG.md | 106 +- .../Exception/ExceptionInterface.php | 40 +- .../Exception/FileNotFoundException.php | 64 +- .../filesystem/Exception/IOException.php | 70 +- .../Exception/IOExceptionInterface.php | 52 +- vendor/symfony/filesystem/Exception/index.php | 72 +- vendor/symfony/filesystem/Filesystem.php | 1340 ++-- vendor/symfony/filesystem/LICENSE | 38 +- vendor/symfony/filesystem/LockHandler.php | 212 +- vendor/symfony/filesystem/README.md | 26 +- .../filesystem/Tests/ExceptionTest.php | 84 +- .../filesystem/Tests/FilesystemTest.php | 2298 +++--- .../filesystem/Tests/FilesystemTestCase.php | 272 +- .../Tests/Fixtures/MockStream/MockStream.php | 88 +- .../Tests/Fixtures/MockStream/index.php | 72 +- .../filesystem/Tests/Fixtures/index.php | 72 +- .../filesystem/Tests/LockHandlerTest.php | 226 +- vendor/symfony/filesystem/Tests/index.php | 72 +- vendor/symfony/filesystem/composer.json | 70 +- vendor/symfony/filesystem/index.php | 72 +- vendor/symfony/filesystem/phpunit.xml.dist | 60 +- vendor/symfony/index.php | 72 +- vendor/symfony/polyfill-apcu/Apcu.php | 182 +- vendor/symfony/polyfill-apcu/LICENSE | 38 +- vendor/symfony/polyfill-apcu/README.md | 24 +- vendor/symfony/polyfill-apcu/bootstrap.php | 188 +- vendor/symfony/polyfill-apcu/composer.json | 80 +- vendor/symfony/polyfill-apcu/index.php | 72 +- vendor/symfony/polyfill-ctype/Ctype.php | 402 +- vendor/symfony/polyfill-ctype/LICENSE | 38 +- vendor/symfony/polyfill-ctype/README.md | 24 +- vendor/symfony/polyfill-ctype/bootstrap.php | 118 +- vendor/symfony/polyfill-ctype/composer.json | 84 +- vendor/symfony/polyfill-ctype/index.php | 72 +- vendor/symfony/polyfill-intl-idn/Idn.php | 426 +- vendor/symfony/polyfill-intl-idn/LICENSE | 38 +- vendor/symfony/polyfill-intl-idn/README.md | 24 +- .../symfony/polyfill-intl-idn/bootstrap.php | 144 +- .../symfony/polyfill-intl-idn/composer.json | 92 +- vendor/symfony/polyfill-intl-idn/index.php | 72 +- vendor/symfony/polyfill-mbstring/LICENSE | 38 +- vendor/symfony/polyfill-mbstring/Mbstring.php | 1354 ++-- vendor/symfony/polyfill-mbstring/README.md | 26 +- .../polyfill-mbstring/Resources/index.php | 72 +- .../Resources/unidata/index.php | 72 +- .../Resources/unidata/lowerCase.php | 10 +- .../Resources/unidata/titleCaseRegexp.php | 12 +- .../Resources/unidata/upperCase.php | 10 +- .../symfony/polyfill-mbstring/bootstrap.php | 354 +- .../symfony/polyfill-mbstring/composer.json | 86 +- vendor/symfony/polyfill-mbstring/index.php | 72 +- vendor/symfony/polyfill-php70/LICENSE | 38 +- vendor/symfony/polyfill-php70/Php70.php | 134 +- vendor/symfony/polyfill-php70/README.md | 56 +- .../polyfill-php70/Resources/index.php | 72 +- .../Resources/stubs/ArithmeticError.php | 16 +- .../Resources/stubs/AssertionError.php | 16 +- .../Resources/stubs/DivisionByZeroError.php | 16 +- .../polyfill-php70/Resources/stubs/Error.php | 16 +- .../Resources/stubs/ParseError.php | 16 +- ...SessionUpdateTimestampHandlerInterface.php | 50 +- .../Resources/stubs/TypeError.php | 16 +- .../polyfill-php70/Resources/stubs/index.php | 72 +- vendor/symfony/polyfill-php70/bootstrap.php | 72 +- vendor/symfony/polyfill-php70/composer.json | 86 +- vendor/symfony/polyfill-php70/index.php | 72 +- vendor/symfony/polyfill-php72/LICENSE | 38 +- vendor/symfony/polyfill-php72/Php72.php | 350 +- vendor/symfony/polyfill-php72/README.md | 54 +- vendor/symfony/polyfill-php72/bootstrap.php | 122 +- vendor/symfony/polyfill-php72/composer.json | 78 +- vendor/symfony/polyfill-php72/index.php | 72 +- vendor/symfony/yaml/.gitignore | 6 +- vendor/symfony/yaml/CHANGELOG.md | 298 +- vendor/symfony/yaml/Command/LintCommand.php | 408 +- vendor/symfony/yaml/Command/index.php | 72 +- vendor/symfony/yaml/Dumper.php | 256 +- vendor/symfony/yaml/Escaper.php | 164 +- .../symfony/yaml/Exception/DumpException.php | 40 +- .../yaml/Exception/ExceptionInterface.php | 40 +- .../symfony/yaml/Exception/ParseException.php | 240 +- .../yaml/Exception/RuntimeException.php | 40 +- vendor/symfony/yaml/Exception/index.php | 72 +- vendor/symfony/yaml/Inline.php | 1584 ++-- vendor/symfony/yaml/LICENSE | 38 +- vendor/symfony/yaml/Parser.php | 1900 ++--- vendor/symfony/yaml/README.md | 26 +- vendor/symfony/yaml/Tag/TaggedValue.php | 88 +- vendor/symfony/yaml/Tag/index.php | 72 +- .../yaml/Tests/Command/LintCommandTest.php | 230 +- vendor/symfony/yaml/Tests/Command/index.php | 72 +- vendor/symfony/yaml/Tests/DumperTest.php | 962 +-- .../yaml/Tests/Fixtures/YtsAnchorAlias.yml | 62 +- .../yaml/Tests/Fixtures/YtsBasicTests.yml | 404 +- .../yaml/Tests/Fixtures/YtsBlockMapping.yml | 102 +- .../Tests/Fixtures/YtsDocumentSeparator.yml | 170 +- .../yaml/Tests/Fixtures/YtsErrorTests.yml | 50 +- .../Tests/Fixtures/YtsFlowCollections.yml | 120 +- .../yaml/Tests/Fixtures/YtsFoldedScalars.yml | 352 +- .../Tests/Fixtures/YtsNullsAndEmpties.yml | 90 +- .../Fixtures/YtsSpecificationExamples.yml | 3402 ++++---- .../yaml/Tests/Fixtures/YtsTypeTransfers.yml | 532 +- .../Tests/Fixtures/booleanMappingKeys.yml | 22 +- .../yaml/Tests/Fixtures/embededPhp.yml | 2 +- .../yaml/Tests/Fixtures/escapedCharacters.yml | 310 +- vendor/symfony/yaml/Tests/Fixtures/index.php | 72 +- vendor/symfony/yaml/Tests/Fixtures/index.yml | 36 +- .../Fixtures/legacyBooleanMappingKeys.yml | 46 +- .../Tests/Fixtures/legacyNonStringKeys.yml | 4 +- .../Tests/Fixtures/legacyNullMappingKey.yml | 18 +- .../multiple_lines_as_literal_block.yml | 28 +- ...nes_as_literal_block_for_tagged_values.yml | 4 +- ...eral_block_leading_space_in_first_line.yml | 8 +- .../yaml/Tests/Fixtures/nonStringKeys.yml | 6 +- .../yaml/Tests/Fixtures/not_readable.yml | 36 +- .../yaml/Tests/Fixtures/nullMappingKey.yml | 18 +- .../Tests/Fixtures/numericMappingKeys.yml | 46 +- .../yaml/Tests/Fixtures/sfComments.yml | 152 +- .../symfony/yaml/Tests/Fixtures/sfCompact.yml | 318 +- .../yaml/Tests/Fixtures/sfMergeKey.yml | 122 +- .../symfony/yaml/Tests/Fixtures/sfObjects.yml | 22 +- .../symfony/yaml/Tests/Fixtures/sfQuotes.yml | 66 +- .../symfony/yaml/Tests/Fixtures/sfTests.yml | 280 +- .../Tests/Fixtures/unindentedCollections.yml | 164 +- vendor/symfony/yaml/Tests/InlineTest.php | 1288 +-- .../symfony/yaml/Tests/ParseExceptionTest.php | 58 +- vendor/symfony/yaml/Tests/ParserTest.php | 3434 ++++---- vendor/symfony/yaml/Tests/YamlTest.php | 72 +- vendor/symfony/yaml/Tests/index.php | 72 +- vendor/symfony/yaml/Unescaper.php | 268 +- vendor/symfony/yaml/Yaml.php | 262 +- vendor/symfony/yaml/composer.json | 88 +- vendor/symfony/yaml/index.php | 72 +- vendor/symfony/yaml/phpunit.xml.dist | 60 +- views/css/front.css | 336 +- views/css/index.php | 22 +- views/css/mollie.css | 212 +- views/css/mollie_15.css | 124 +- views/css/mollie_iframe.css | 204 +- views/img/cartasi.svg | 158 +- views/img/cartesbancaires.svg | 238 +- views/img/index.php | 22 +- views/index.php | 86 +- views/js/.babelrc | 44 +- views/js/.eslintrc | 112 +- views/js/.gitignore | 6 +- views/js/admin/index.php | 72 +- views/js/admin/settings.js | 92 +- views/js/apple_payment.js | 76 +- views/js/dist/0.min.js | 64 +- views/js/dist/app.min.js | 64 +- views/js/dist/banks.min.js | 64 +- views/js/dist/carrierconfig.min.js | 74 +- views/js/dist/index.php | 72 +- views/js/dist/manifest.php | 72 +- views/js/dist/methodconfig.min.js | 74 +- views/js/dist/qrcode.min.js | 64 +- views/js/dist/transaction.min.js | 64 +- views/js/dist/transactionOrder.min.js | 64 +- views/js/dist/transactionRefund.min.js | 64 +- views/js/dist/updater.min.js | 64 +- views/js/dist/vendors~app.min.js | 64 +- ...fig~methodconfig~qrcode~transaction.min.js | 64 +- ...odconfig~qrcode~transaction~updater.min.js | 64 +- ...rierconfig~methodconfig~transaction.min.js | 94 +- ...ig~methodconfig~transaction~updater.min.js | 78 +- ...nks~methodconfig~qrcode~transaction.min.js | 64 +- ...odconfig~qrcode~transaction~updater.min.js | 64 +- ...ks~methodconfig~transaction~updater.min.js | 78 +- ...tionOrder~transactionRefund~updater.min.js | 64 +- ...ndors~methodconfig~transactionOrder.min.js | 74 +- views/js/dist/vendors~sweetalert.min.js | 64 +- views/js/dist/vendors~transaction.min.js | 94 +- views/js/dist/vendors~transactionOrder.min.js | 64 +- ...~transactionOrder~transactionRefund.min.js | 74 +- ...tionOrder~transactionRefund~updater.min.js | 64 +- views/js/front/index.php | 72 +- views/js/front/mollie_error_handle.js | 110 +- views/js/front/mollie_iframe.js | 316 +- views/js/front/mollie_iframe_16.js | 306 +- views/js/index.php | 86 +- views/js/method_countries.js | 136 +- views/js/package.json | 160 +- views/js/src/back/index.php | 22 +- .../transaction/components/MolliePanel.tsx | 120 +- .../src/back/transaction/components/index.php | 22 +- .../orderlines/EmptyOrderLinesTable.tsx | 144 +- .../orderlines/OrderLinesEditor.tsx | 284 +- .../components/orderlines/OrderLinesInfo.tsx | 160 +- .../components/orderlines/OrderLinesTable.tsx | 624 +- .../orderlines/OrderLinesTableActions.tsx | 312 +- .../orderlines/OrderLinesTableFooter.tsx | 332 +- .../orderlines/OrderLinesTableHeader.tsx | 188 +- .../components/orderlines/OrderPanel.tsx | 170 +- .../orderlines/OrderPanelContent.tsx | 126 +- .../components/orderlines/PaymentInfo.tsx | 132 +- .../orderlines/PaymentInfoContent.tsx | 114 +- .../orderlines/ShipmentTrackingEditor.tsx | 400 +- .../components/orderlines/WarningContent.tsx | 150 +- .../components/orderlines/index.php | 22 +- .../components/refund/EmptyRefundTable.tsx | 120 +- .../components/refund/PartialRefundButton.tsx | 154 +- .../components/refund/PaymentInfo.tsx | 134 +- .../components/refund/PaymentInfoContent.tsx | 114 +- .../components/refund/RefundButton.tsx | 128 +- .../components/refund/RefundForm.tsx | 386 +- .../components/refund/RefundHistory.tsx | 104 +- .../components/refund/RefundInfo.tsx | 146 +- .../components/refund/RefundPanel.tsx | 198 +- .../components/refund/RefundTable.tsx | 130 +- .../components/refund/RefundTableHeader.tsx | 112 +- .../transaction/components/refund/index.php | 22 +- views/js/src/back/transaction/index.php | 22 +- views/js/src/back/transaction/index.tsx | 188 +- views/js/src/back/transaction/misc/ajax.ts | 402 +- views/js/src/back/transaction/misc/index.php | 22 +- .../js/src/back/transaction/store/actions.ts | 214 +- views/js/src/back/transaction/store/index.php | 22 +- views/js/src/back/transaction/store/index.ts | 92 +- views/js/src/back/transaction/store/order.ts | 262 +- views/js/src/index.php | 22 +- views/js/src/shared/axios.ts | 86 +- .../js/src/shared/components/LoadingDots.tsx | 148 +- .../shared/components/LoadingDotsCentered.tsx | 176 +- views/js/src/shared/components/index.php | 22 +- views/js/src/shared/globals.ts | 452 +- views/js/src/shared/index.php | 22 +- views/js/src/shared/modules.d.ts | 66 +- views/js/src/shared/tools.ts | 752 +- views/js/tsconfig.json | 60 +- views/js/validation.js | 344 +- views/js/webpack.config.js | 328 +- .../admin/_configure/helpers/form/index.php | 86 +- .../admin/_configure/helpers/index.php | 86 +- views/templates/admin/_configure/index.php | 86 +- .../admin/create_new_account_link.tpl | 70 +- views/templates/admin/index.php | 86 +- views/templates/admin/invoice_fee.tpl | 102 +- views/templates/admin/locale_wiki.tpl | 64 +- views/templates/admin/logo.tpl | 72 +- views/templates/admin/manifest.php.tpl | 96 +- views/templates/admin/new_release.tpl | 78 +- views/templates/admin/ordergrid.tpl | 86 +- views/templates/admin/profile.tpl | 64 +- views/templates/admin/view_logs.tpl | 64 +- views/templates/front/17_error.tpl | 76 +- views/templates/front/17_mollie_return.tpl | 72 +- views/templates/front/17_mollie_wait.tpl | 72 +- views/templates/front/break.tpl | 64 +- views/templates/front/break_point.tpl | 64 +- views/templates/front/cart_rules_list.tpl | 70 +- views/templates/front/classname.tpl | 64 +- views/templates/front/custom_css.tpl | 66 +- views/templates/front/error.tpl | 116 +- views/templates/front/index.php | 86 +- views/templates/front/kbd.tpl | 64 +- views/templates/front/mollie_error.tpl | 78 +- views/templates/front/mollie_return.tpl | 74 +- views/templates/front/mollie_wait.tpl | 258 +- views/templates/front/name_block.tpl | 64 +- .../front/order-confirmation-table.tpl | 278 +- views/templates/front/order_fail.tpl | 102 +- views/templates/front/order_success.tpl | 84 +- views/templates/front/product.tpl | 76 +- views/templates/front/qr_done.tpl | 138 +- views/templates/front/strong.tpl | 64 +- views/templates/hook/addjsdef.tpl | 70 +- views/templates/hook/cancel.tpl | 70 +- views/templates/hook/error_message.tpl | 70 +- views/templates/hook/ideal_dropdown.tpl | 164 +- views/templates/hook/index.php | 22 +- views/templates/hook/init_urls.tpl | 86 +- views/templates/hook/mollie_iframe.tpl | 252 +- views/templates/hook/mollie_iframe_16.tpl | 272 +- views/templates/hook/mollie_iframe_js.tpl | 68 +- views/templates/hook/ok.tpl | 66 +- views/templates/hook/order_info.tpl | 254 +- views/templates/hook/qr_code.tpl | 124 +- views/templates/hook/rounding_error.tpl | 74 +- views/templates/hook/smarty_error.tpl | 76 +- views/templates/hook/smarty_warning.tpl | 70 +- views/templates/index.php | 86 +- 1656 files changed, 134411 insertions(+), 134411 deletions(-) diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md index df562f1c2..d8430b514 100644 --- a/.github/ISSUE_TEMPLATE.md +++ b/.github/ISSUE_TEMPLATE.md @@ -1,13 +1,13 @@ -### Expected behavior - - -### Actual behavior - - -### Steps to reproduce the behavior - - -### Environment -* PrestaShop version: 1.7.5.0 -* Mollie module version: 3.3.4 -* PHP version: 7.1.26 +### Expected behavior + + +### Actual behavior + + +### Steps to reproduce the behavior + + +### Environment +* PrestaShop version: 1.7.5.0 +* Mollie module version: 3.3.4 +* PHP version: 7.1.26 diff --git a/.github/index.php b/.github/index.php index 729abf520..a950d02f4 100644 --- a/.github/index.php +++ b/.github/index.php @@ -1,11 +1,11 @@ - - if [[ "${SKIP_NODE}" != "true" ]]; then - curl -o- -L https://yarnpkg.com/install.sh | bash - export PATH="$HOME/.yarn/bin:$PATH" - fi - -before_script: - # Build the release - - > - if [[ "${TEST_UNIT}" = "true" ]] || [[ "${TEST_ACCEPTANCE}" = "true" ]]; then - export MOLLIE_MODULE_VERSION=$(sed -ne "s/\\\$this->version *= *['\"]\([^'\"]*\)['\"] *;.*/\1/p" mollie.php | awk '{$1=$1};1') - make r - cp ./build/mollie-v${MOLLIE_MODULE_VERSION}.zip ./tests/_data/mollie.zip - fi - - > - if [[ "${TEST_ACCEPTANCE}" = "true" ]]; then - yarn global add chromedriver - fi - # Run docker + headless Chrome and wait until PrestaShop is installed - - > - if [[ ${PRESTASHOP_VERSION} ]]; then - git clone https://github.com/PrestaShop/PrestaShop --depth 1 --branch ${PRESTASHOP_VERSION} prestashop - docker-compose up -d - nohup chromedriver --url-base=/wd/hub & - until $(curl --output /dev/null --silent --head --fail http://localhost:${PRESTASHOP_PORT}); do - printf 'Installing PrestaShop...' - sleep 5 - done - printf 'PrestaShop seems to be up and running' - sudo rm ./prestashop/modules/welcome -rf - fi - -script: - # Syntax checker - - if [[ "${TEST_SYNTAX}" = "true" ]]; then find controllers sql translations upgrade views countries.php mollie.php -name '*.php' | xargs -n 1 -P4 php -l; fi - # Unit tests (Codeception) - - if [[ "${TEST_UNIT}" = "true" ]]; then php codecept.phar run unit; fi - # Acceptance tests (Codeception) - - if [[ "{$TEST_ACCEPTANCE}" = "true" ]] && [[ "${TRAVIS_PULL_REQUEST}" = "false" ]]; then php codecept.phar run acceptance; fi - # Frontend tests (Jest) - - if [[ "${TEST_FRONTEND}" = "true" ]]; then cd views/js/src/ && yarn test; fi +language: php +dist: xenial +node_js: + - 10 +sudo: true +services: + - docker +addons: + chrome: stable + +env: + global: + - COMPOSER_NO_INTERACTION=1 + - PRESTASHOP_PORT=8090 + +cache: + - yarn + - npm + - directories: + - "$HOME/.composer/cache" + - node_modules + +matrix: + fast_finish: true + include: + - php: 5.3 + dist: precise + env: TEST_SYNTAX=true SKIP_NODE=true + - php: 5.4 + dist: precise + env: TEST_SYNTAX=true SKIP_NODE=true + - php: 5.5 + dist: precise + env: TEST_SYNTAX=true SKIP_NODE=true + - php: 5.6 + env: TEST_SYNTAX=true + - php: 7.0 + env: TEST_SYNTAX=true + - php: 7.1 + env: TEST_SYNTAX=true + - php: 7.2 + env: TEST_SYNTAX=true + - php: 7.3 + env: TEST_SYNTAX=true + - php: 7.1 + env: TEST_UNIT=true + - php: 7.1 + env: TEST_FRONTEND=true +# - php: 7.1 +# env: PRESTASHOP_VERSION="1.5.4.2" TEST_ACCEPTANCE=true +# - php: 7.1 +# env: PRESTASHOP_VERSION="1.5.6.2" TEST_ACCEPTANCE=true +# - php: 7.1 +# env: PRESTASHOP_VERSION="1.6.0.5" TEST_ACCEPTANCE=true +# - php: 7.1 +# env: PRESTASHOP_VERSION="1.6.1.23" TEST_ACCEPTANCE=true +# - php: 7.1 +# env: PRESTASHOP_VERSION="1.7.3.4" TEST_ACCEPTANCE=true +# - php: 7.1 +# env: PRESTASHOP_VERSION="1.7.4.4" TEST_ACCEPTANCE=true + - php: 7.1 + env: PRESTASHOP_VERSION="1.7.5.0" TEST_ACCEPTANCE=true + +before_install: + - > + if [[ "${SKIP_NODE}" != "true" ]]; then + curl -o- -L https://yarnpkg.com/install.sh | bash + export PATH="$HOME/.yarn/bin:$PATH" + fi + +before_script: + # Build the release + - > + if [[ "${TEST_UNIT}" = "true" ]] || [[ "${TEST_ACCEPTANCE}" = "true" ]]; then + export MOLLIE_MODULE_VERSION=$(sed -ne "s/\\\$this->version *= *['\"]\([^'\"]*\)['\"] *;.*/\1/p" mollie.php | awk '{$1=$1};1') + make r + cp ./build/mollie-v${MOLLIE_MODULE_VERSION}.zip ./tests/_data/mollie.zip + fi + - > + if [[ "${TEST_ACCEPTANCE}" = "true" ]]; then + yarn global add chromedriver + fi + # Run docker + headless Chrome and wait until PrestaShop is installed + - > + if [[ ${PRESTASHOP_VERSION} ]]; then + git clone https://github.com/PrestaShop/PrestaShop --depth 1 --branch ${PRESTASHOP_VERSION} prestashop + docker-compose up -d + nohup chromedriver --url-base=/wd/hub & + until $(curl --output /dev/null --silent --head --fail http://localhost:${PRESTASHOP_PORT}); do + printf 'Installing PrestaShop...' + sleep 5 + done + printf 'PrestaShop seems to be up and running' + sudo rm ./prestashop/modules/welcome -rf + fi + +script: + # Syntax checker + - if [[ "${TEST_SYNTAX}" = "true" ]]; then find controllers sql translations upgrade views countries.php mollie.php -name '*.php' | xargs -n 1 -P4 php -l; fi + # Unit tests (Codeception) + - if [[ "${TEST_UNIT}" = "true" ]]; then php codecept.phar run unit; fi + # Acceptance tests (Codeception) + - if [[ "{$TEST_ACCEPTANCE}" = "true" ]] && [[ "${TRAVIS_PULL_REQUEST}" = "false" ]]; then php codecept.phar run acceptance; fi + # Frontend tests (Jest) + - if [[ "${TEST_FRONTEND}" = "true" ]]; then cd views/js/src/ && yarn test; fi diff --git a/LICENSE b/LICENSE index 04e1af2df..4ec7d54c9 100644 --- a/LICENSE +++ b/LICENSE @@ -1,8 +1,8 @@ -Copyright (c) 2014, Mollie B.V. -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +Copyright (c) 2014, Mollie B.V. +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + +Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. +Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/Makefile b/Makefile index a19dff1f9..5651b8faa 100644 --- a/Makefile +++ b/Makefile @@ -1,167 +1,167 @@ -SHELL:=/bin/bash - -MODULE_NAME:=mollie -MODULE_VERSION:=$(shell sed -ne "s/\\\$$this->version *= *['\"]\([^'\"]*\)['\"] *;.*/\1/p" ${MODULE_NAME}.php | awk '{$$1=$$1};1') - -COLOR_BLACK:=\u001b[30m -COLOR_RED:=\u001b[31m -COLOR_GREEN:=\u001b[32m -COLOR_YELLOW:=\u001b[33m -COLOR_BLUE:=\u001b[34m -COLOR_MAGENTA:=\u001b[35m -COLOR_CYAN:=\u001b[36m -COLOR_WHITE:=\u001b[37m -COLOR_RESET:=\u001b[0m - -FILES:=logo.gif -FILES+=logo.png -FILES+=LICENSE -FILES+=controllers/** -FILES+=countries.php -FILES+=index.php -FILES+=${MODULE_NAME}.php -FILES+=sql/** -FILES+=translations/** -FILES+=upgrade/** -FILES+=vendor/** -FILES+=views/index.php -FILES+=views/css/** -FILES+=views/img/** -FILES+=views/js/index.php -FILES+=views/js/dist/*.min.js -FILES+=views/js/dist/*.php -FILES+=views/js/dist/index.php -FILES+=views/templates/** - -.PHONY: all quick-clean composer php-scoper node webpack zip vartest - -all: - $(MAKE) quick-clean - $(MAKE) prod - -release: - $(MAKE) quick-clean - $(MAKE) prod - -prod: - $(MAKE) composer - $(MAKE) php-scoper - $(MAKE) node - NODE_ENV=production $(MAKE) webpack - $(MAKE) zip - -dev: - export NODE_ENV=development - $(MAKE) composer - $(MAKE) php-scoper - $(MAKE) node - NODE_ENV=development $(MAKE) webpack - -# Quick aliases -a: all -r: release -p: prod -d: dev -qc: quick-clean - -# clean: -# PHP scoper -# @rm -rf pre-scoper/ 2>/dev/null || true -# @rm php-scoper.phar 2>/dev/null || true -# @rm php-scoper.phar.pubkey 2>/dev/null || true - -quick-clean: - @echo -e "${COLOR_BLUE}Cleanup${COLOR_RESET}" -# Remove target file - @rm -rf build/ 2>/dev/null || true - -# Composer - @rm -rf vendor/ 2>/dev/null || true - @rm composer.lock 2>/dev/null || true - -# Webpack / node.js - @rm -rf views/js/node_modules/ 2>/dev/null || true - @rm views/js/package-lock.json 2>/dev/null || true - @rm views/js/yarn.lock 2>/dev/null || true - @rm views/js/yarn.lock 2>/dev/null || true - @rm -rf views/js/dist/ 2>/dev/null || true - -composer: -ifeq (,$(wildcard vendor/)) - @echo -e "${COLOR_BLUE}vendor folder is missing, running composer${COLOR_RESET}" -# Composer install - composer install --no-dev --prefer-dist -# Dump and optimize Composer autoloader - composer -o dump-autoload -# Copy index.php files to vendor folder or Addons validation - @echo Copying index.php files to the vendor folder - @find vendor/ -type d -exec cp index.php {} \; -endif - -php-scoper: -# Check if php scoper is available, otherwise download it - @echo -e "${COLOR_BLUE}Running PHP Scoper${COLOR_RESET}" -ifeq (,$(wildcard php-scoper.phar)) - wget -q https://github.com/humbug/php-scoper/releases/download/0.9.2/php-scoper.phar - wget -q https://github.com/humbug/php-scoper/releases/download/0.9.2/php-scoper.phar.pubkey -endif - @rm -rf pre-scoper/ -rf 2>/dev/null || true - @mkdir pre-scoper - @mv vendor pre-scoper/ - php ./php-scoper.phar add-prefix -p MollieModule -n - @mv build/pre-scoper/vendor vendor - @rm -rf pre-scoper/ -rf 2>/dev/null || true - @rm -rf build/ 2>/dev/null || true -# Create a new autoloader, the one PHP-scoper generates is not compatible with PHP 5.3.29+ - @composer -o dump-autoload - -node: -# Download node modules -# Skip if the node_modules directory already exists - @echo -e "${COLOR_BLUE}Downloading node_modules${COLOR_RESET}" -ifeq (,$(wildcard views/js/node_modules/)) -# Avoid yarn when not available -ifeq (,$(shell which yarn)) - cd views/js/; \ - npm i -else - cd views/js/; \ - yarn -endif -endif - -webpack: -ifndef NODE_ENV -NODE_ENV:=production -endif -webpack: - @echo -e "${COLOR_BLUE}Running webpack${COLOR_RESET}" -ifndef NODE_ENV - @export NODE_ENV=production -endif -# Webpack build -ifeq (,$(wildcard views/js/dist/)) - @mkdir -p views/js/dist/ -endif - @cp views/js/index.php views/js/dist/index.php - @cd views/js/; \ - node_modules/.bin/webpack --mode ${NODE_ENV} - -zip: - @echo -e "${COLOR_BLUE}Going to zip ${COLOR_GREEN}${MODULE_NAME}${COLOR_BLUE} version ${COLOR_GREEN}${MODULE_VERSION}${COLOR_RESET}" -# Remove deprecated files from build - @mkdir -p build/${MODULE_NAME} - @$(foreach f,$(FILES),cp --parents -rf $(f) build/$(MODULE_NAME);) - @cd build/; zip -r -9 ${MODULE_NAME}-v${MODULE_VERSION}.zip ${MODULE_NAME} - @rm -rf build/${MODULE_NAME} || true - -vartest: -ifndef NODE_ENV -NODE_ENV:=production -endif -vartest: -# Use this to test if all environment variables are correctly set - @echo -e "${COLOR_BLUE}Testing environment variables, NODE_ENV is possibly not set${COLOR_RESET}" - @echo -e "${COLOR_BLUE}NODE_ENV:${COLOR_YELLOW} ${NODE_ENV}${COLOR_RESET}" - @echo -e "${COLOR_BLUE}MODULE_NAME:${COLOR_YELLOW} ${MODULE_NAME}${COLOR_RESET}" - @echo -e "${COLOR_BLUE}MODULE_VERSION:${COLOR_YELLOW} ${MODULE_VERSION}${COLOR_RESET}" +SHELL:=/bin/bash + +MODULE_NAME:=mollie +MODULE_VERSION:=$(shell sed -ne "s/\\\$$this->version *= *['\"]\([^'\"]*\)['\"] *;.*/\1/p" ${MODULE_NAME}.php | awk '{$$1=$$1};1') + +COLOR_BLACK:=\u001b[30m +COLOR_RED:=\u001b[31m +COLOR_GREEN:=\u001b[32m +COLOR_YELLOW:=\u001b[33m +COLOR_BLUE:=\u001b[34m +COLOR_MAGENTA:=\u001b[35m +COLOR_CYAN:=\u001b[36m +COLOR_WHITE:=\u001b[37m +COLOR_RESET:=\u001b[0m + +FILES:=logo.gif +FILES+=logo.png +FILES+=LICENSE +FILES+=controllers/** +FILES+=countries.php +FILES+=index.php +FILES+=${MODULE_NAME}.php +FILES+=sql/** +FILES+=translations/** +FILES+=upgrade/** +FILES+=vendor/** +FILES+=views/index.php +FILES+=views/css/** +FILES+=views/img/** +FILES+=views/js/index.php +FILES+=views/js/dist/*.min.js +FILES+=views/js/dist/*.php +FILES+=views/js/dist/index.php +FILES+=views/templates/** + +.PHONY: all quick-clean composer php-scoper node webpack zip vartest + +all: + $(MAKE) quick-clean + $(MAKE) prod + +release: + $(MAKE) quick-clean + $(MAKE) prod + +prod: + $(MAKE) composer + $(MAKE) php-scoper + $(MAKE) node + NODE_ENV=production $(MAKE) webpack + $(MAKE) zip + +dev: + export NODE_ENV=development + $(MAKE) composer + $(MAKE) php-scoper + $(MAKE) node + NODE_ENV=development $(MAKE) webpack + +# Quick aliases +a: all +r: release +p: prod +d: dev +qc: quick-clean + +# clean: +# PHP scoper +# @rm -rf pre-scoper/ 2>/dev/null || true +# @rm php-scoper.phar 2>/dev/null || true +# @rm php-scoper.phar.pubkey 2>/dev/null || true + +quick-clean: + @echo -e "${COLOR_BLUE}Cleanup${COLOR_RESET}" +# Remove target file + @rm -rf build/ 2>/dev/null || true + +# Composer + @rm -rf vendor/ 2>/dev/null || true + @rm composer.lock 2>/dev/null || true + +# Webpack / node.js + @rm -rf views/js/node_modules/ 2>/dev/null || true + @rm views/js/package-lock.json 2>/dev/null || true + @rm views/js/yarn.lock 2>/dev/null || true + @rm views/js/yarn.lock 2>/dev/null || true + @rm -rf views/js/dist/ 2>/dev/null || true + +composer: +ifeq (,$(wildcard vendor/)) + @echo -e "${COLOR_BLUE}vendor folder is missing, running composer${COLOR_RESET}" +# Composer install + composer install --no-dev --prefer-dist +# Dump and optimize Composer autoloader + composer -o dump-autoload +# Copy index.php files to vendor folder or Addons validation + @echo Copying index.php files to the vendor folder + @find vendor/ -type d -exec cp index.php {} \; +endif + +php-scoper: +# Check if php scoper is available, otherwise download it + @echo -e "${COLOR_BLUE}Running PHP Scoper${COLOR_RESET}" +ifeq (,$(wildcard php-scoper.phar)) + wget -q https://github.com/humbug/php-scoper/releases/download/0.9.2/php-scoper.phar + wget -q https://github.com/humbug/php-scoper/releases/download/0.9.2/php-scoper.phar.pubkey +endif + @rm -rf pre-scoper/ -rf 2>/dev/null || true + @mkdir pre-scoper + @mv vendor pre-scoper/ + php ./php-scoper.phar add-prefix -p MollieModule -n + @mv build/pre-scoper/vendor vendor + @rm -rf pre-scoper/ -rf 2>/dev/null || true + @rm -rf build/ 2>/dev/null || true +# Create a new autoloader, the one PHP-scoper generates is not compatible with PHP 5.3.29+ + @composer -o dump-autoload + +node: +# Download node modules +# Skip if the node_modules directory already exists + @echo -e "${COLOR_BLUE}Downloading node_modules${COLOR_RESET}" +ifeq (,$(wildcard views/js/node_modules/)) +# Avoid yarn when not available +ifeq (,$(shell which yarn)) + cd views/js/; \ + npm i +else + cd views/js/; \ + yarn +endif +endif + +webpack: +ifndef NODE_ENV +NODE_ENV:=production +endif +webpack: + @echo -e "${COLOR_BLUE}Running webpack${COLOR_RESET}" +ifndef NODE_ENV + @export NODE_ENV=production +endif +# Webpack build +ifeq (,$(wildcard views/js/dist/)) + @mkdir -p views/js/dist/ +endif + @cp views/js/index.php views/js/dist/index.php + @cd views/js/; \ + node_modules/.bin/webpack --mode ${NODE_ENV} + +zip: + @echo -e "${COLOR_BLUE}Going to zip ${COLOR_GREEN}${MODULE_NAME}${COLOR_BLUE} version ${COLOR_GREEN}${MODULE_VERSION}${COLOR_RESET}" +# Remove deprecated files from build + @mkdir -p build/${MODULE_NAME} + @$(foreach f,$(FILES),cp --parents -rf $(f) build/$(MODULE_NAME);) + @cd build/; zip -r -9 ${MODULE_NAME}-v${MODULE_VERSION}.zip ${MODULE_NAME} + @rm -rf build/${MODULE_NAME} || true + +vartest: +ifndef NODE_ENV +NODE_ENV:=production +endif +vartest: +# Use this to test if all environment variables are correctly set + @echo -e "${COLOR_BLUE}Testing environment variables, NODE_ENV is possibly not set${COLOR_RESET}" + @echo -e "${COLOR_BLUE}NODE_ENV:${COLOR_YELLOW} ${NODE_ENV}${COLOR_RESET}" + @echo -e "${COLOR_BLUE}MODULE_NAME:${COLOR_YELLOW} ${MODULE_NAME}${COLOR_RESET}" + @echo -e "${COLOR_BLUE}MODULE_VERSION:${COLOR_YELLOW} ${MODULE_VERSION}${COLOR_RESET}" diff --git a/README.md b/README.md index 017e63864..85862b951 100644 --- a/README.md +++ b/README.md @@ -1,193 +1,193 @@ -

- -

-

Mollie for Prestashop

- -> [Nederlands](README_NL.md) | [Deutsch](README_DE.md) | [Français](README_FR.md) | [Español](README_ES.md) - -Download the [Mollie](https://www.mollie.com/) module for PrestaShop. Mollie is a payment service provider (PSP) which provides your online store with the most popular online payment methods. - -Receive payments from European customers with ease. Mollie provides payment methods at higly competitive rates. Only pay per transaction and no hidden fees. - -Choose the best payment provider available for your online PrestaShop store. Create your merchant account at [Mollie.com](https://www.mollie.com/). -Download and install the Mollie PrestaShop payment module and start receiving online payments now! - - - -[![Build Status](https://travis-ci.org/mollie/PrestaShop.svg?branch=master)](https://travis-ci.org/mollie/PrestaShop) -[![Greenkeeper badge](https://badges.greenkeeper.io/mollie/PrestaShop.svg)](https://greenkeeper.io/) -[![Release badge](https://img.shields.io/github/release/mollie/PrestaShop.svg)](https://github.com/mollie/PrestaShop/releases/latest) - -## Maintained by [Invertus](https://www.invertus.eu/). ## - -## Compatible with PrestaShop 1.5 to 1.7 ## - -** Please note: ** FTP access to your web server could be required for the installation of this module. -If you have no experience with this, then leave the installation of this module to your website developer or server administrator. - -## Installation PrestaShop 1.7 ## - -* Download the latest version of the module (the '.zip' file) via the [Releases page](https://github.com/mollie/Prestashop/releases) which is compatible -with PrestaShop 1.5 to 1.7. -* Go to the administration panel of your PrestaShop webshop -* In your administration panel, select the 'Modules' tab and then choose 'upload a module' at the top right of your screen -* Select 'select file' and then upload the '.zip' file which you downloaded earlier -* After the module has been installed, choose 'configure' -* Enter your _API-key_ and save the data. - -## Installation PrestaShop 1.5 and 1.6 ## - -* Download the latest version of the module (the '.zip' file) via the [Releases-page](https://github.com/mollie/Prestashop/releases) which is compatible -with PrestaShop 1.5 to 1.7. -* Go to the administration panel of your PrestaShop webshop -* In your administration panel, select the 'Modules' tab and then choose 'upload a module' at the top right of your screen -* Select 'select file' and then upload the '.zip' file which you downloaded earlier -* After the module has been installed, choose 'configure' -* Enter your _API-key_ and save the data. - -## or ## - -* Download the latest version of the module (the '.zip' file) via the [Releases-page](https://github.com/mollie/Prestashop/releases) which is compatible -with PrestaShop 1.5 to 1.7. -* Extract the archive -* Copy the `mollie` folder to the` modules` folder via FTP in your PrestaShop installation -* Go to the tab 'Modules' in your administration panel and choose 'Payments and Gateways' in the 'Categories' list. -* Click on the 'install' button on the right of the Mollie Payment Module -* Enter your _API-key_ and save the data. - -# Supported payment methods - -### iDeal - -[iDEAL](https://www.mollie.com/en/payments/ideal) makes paying for your online purchases safe, secure and easy. -iDEAL is a Dutch payment system which links customers directly to their online banking program when making an online purchase. - -[Mollie](https://www.mollie.com/) makes it easy to connect with iDEAL, without the usual technical and administrative hassle. -Mollie gives you access to your transaction overviews and other statistics at any time. It is also possible to receive a notification by e-mail or SMS after every successful payment. - -[Mollie](https://www.mollie.com/) is the perfect partner for recieving iDEAL payments and it is not surprising that [Mollie](https://www.mollie.com/) provides iDEAL payments -for more than 40,000 websites. - -### Credit card -[Credit card](https://www.mollie.com/en/payments/credit-card) is virtually the best-known method for receiving payments with global coverage. - -Because [Mollie](https://www.mollie.com/) supports the biggest credit card brands like Mastercard, VISA and American Express, your store will attract a lot more potential buyers. - -### Bancontact -[Bancontact](https://www.mollie.com/en/payments/bancontact) uses a physical card that is linked to credit on a Belgian bank account. Payments via Bancontact / Mister Cash are guaranteed and strongly resemble the iDEAL payment system for the Netherlands. - -Because payments are guaranteed, this payment method is a huge surplus for your online store. - -### SOFORT Banking -[SOFORT Banking](https://www.mollie.com/en/payments/sofort) is one of the most popular payment methods in Germany and active in 9 European countries: - -Germany, Belgium, the Netherlands, Italy, Austria, Poland, Switzerland, Spain and the United Kingdom. - -Payments are direct, non-reversible and this payment method opens up a huge market potential for your online store. - -### ING Home’Pay -[ING Home’Pay](https://www.mollie.com/en/payments/ing-homepay). Mollie allows you to quickly and easily accept payments with ING Home'Pay. - -It only takes 10 minutes to start receiving payments and there are no hidden fees involved, you only pay for successful transactions. - -### Bank transfers -[Bank transfers](https://www.mollie.com/en/payments/bank-transfer) received in the SEPA zone via [Mollie](https://www.mollie.com/). This allows you to receive payments from both individuals and business customers in more than 35 European countries. - -### PayPal -[PayPal](https://www.mollie.com/en/payments/paypal) is a very popular payment method which is used worldwide. In a just few clicks, you can receive payments by bank transfer, credit card or PayPal balance. - -### paysafecard -[paysafecard](https://www.mollie.com/en/payments/paysafecard) is the most popular prepaid card for online payments. With paysafecard you can receive prepaid payments from 43 countries. - -### KBC/CBC Payment Button -The [KBC / CBC Payment Button](https://www.mollie.com/en/payments/kbc-cbc) is an online payment method for KBC and CBC customers, together the largest bank in Belgium. - -KBC focuses on Flanders and CBC on Wallonia. - -### Belfius Pay Button -[Belfius](https://www.mollie.com/en/payments/belfius) is one of the largest banks in Belgium. By introducing the Belfius Pay Button, the bank provides its customers with their own payment solution. - -### CartaSi -[CartaSi](https://www.mollie.com/en/payments/cartasi) is one of the most widely used payment methods in Italy. - -There are over 13 million CartaSi credit cards in circulation. - -### Cartes Bancaires -[Cartes Bancaires](https://www.mollie.com/en/payments/cartes-bancaires) are the most used credit cards in France, with more than 64 million cards in circulation. - -The cards are co-branded with Visa. - -### EPS -[EPS](https://www.mollie.com/en/payments/eps). The Electronic Payment Standard (EPS) is a payment method, developed by various Austrian banks. - -This makes EPS the main bank transfer payment method in Austria and highly popular with Austrian shoppers. - -### Giropay -[Giropay](https://www.mollie.com/en/payments/giropay). Giropay is a popular bank transfer payment method in Germany. - -It uses more than 1,500 German banks, which makes it a trusted payment method under German customers. - -### Klarna: Pay later -[Klarna: Pay later](https://www.mollie.com/en/payments/klarna-pay-later). Klarna is a flexible payment solution, which allows your customers various, flexible, ways to pay. - -With Mollie you can integrate Klarna: Pay later quickly and start processing payments right away. - -### Klarna: Slice it -[Klarna: Slice it](https://www.mollie.com/en/payments/klarna-slice-it). Klarna is a flexible payment solution, which allows your customers various, flexible, ways to pay. - -With Mollie you can integrate Klarna: Slice it quickly and start processing payments right away. - -# Frequently Asked Questions # - -**The module can not be installed in PrestaShop 1.7.** - -* Go to the root of your website via FTP and then open the 'modules' folder. -* Delete the folder named 'mollie'. -* Re-install the Mollie module for PrestaShop 1.7. - -**I have installed the module, but the module does not appear during checkout.** - -* Check if the module is switched on and the correct API key is set. See the installation instructions. -* Check if euros is set as currency in your store. Mollie only supports euros. -* Check via "Advanced parameters" -> "Performance" if "Minimize HTML" is disabled. - -**Do I also need to set a return and / or webhook URL?** - -There is no need to set a redirect URL or webhook. The module automatically does this with every order. - -**After a successful payment, my customers will see the order history instead of the order confirmation.** - -This is a bug in PrestaShop which has been fixed from version 1.6.0.7. To resolve this, you should update your PrestaShop version. If you do not want to do this, you could also fix the bug yourself by adjusting one line of code. - -The relevant [github issue](https://github.com/mollie/Prestashop/issues/3) tells you exactly how to do this. - -**The order status is not updated** - -Mollie sends a message to your website when the status of the payment changes. It is possible that Mollie could not reach your website or that your website could not process the status. - -* Check your [Mollie management](https://www.mollie.com/beheer/) whether there are failed reports. -* Check if your website is running in 'maintenance mode'. Mollie can not reach your website if your website is running in maintenance mode if the Mollie module version is below 2.0.0. -From version 2.0.0 and up, the Mollie module does work in maintenance mode. -* Sometimes something goes wrong when creating the invoice. Check if the "Enable image for product" option is turned off in "Orders" -> "Invoices" -> "Invoice options" (from PrestaShop 1.6.1.0) or in "Preferences" -> "Orders" -> "PDF settings "(in PrestaShop 1.6.0.12 to 1.6.0.14). - -# Would you like to help improve this module? # - -Would you like to help make this module for PrestaShop even better? We are always open to [pull requests](https://github.com/mollie/Prestashop/pulls?utf8=%E2%9C%93&q=is%3Apr). - -And how about working at a [technology driven organization](https://jobs.mollie.com/)? Mollie is always looking for developers and system engineers. [Check our vacancies](https://jobs.mollie.com/) or [contact us](mailto:personeel@mollie.com). - -# License # -[BSD (Berkeley Software Distribution) License](http://www.opensource.org/licenses/bsd-license.php). -Copyright (c) 2013-2019, Mollie B.V. - -# Support # - -Do you have problems with the installation or do you think the module contains a bug? Send an email -to info@mollie.com with a accurate description of the problem. +

+ +

+

Mollie for Prestashop

+ +> [Nederlands](README_NL.md) | [Deutsch](README_DE.md) | [Français](README_FR.md) | [Español](README_ES.md) + +Download the [Mollie](https://www.mollie.com/) module for PrestaShop. Mollie is a payment service provider (PSP) which provides your online store with the most popular online payment methods. + +Receive payments from European customers with ease. Mollie provides payment methods at higly competitive rates. Only pay per transaction and no hidden fees. + +Choose the best payment provider available for your online PrestaShop store. Create your merchant account at [Mollie.com](https://www.mollie.com/). +Download and install the Mollie PrestaShop payment module and start receiving online payments now! + + + +[![Build Status](https://travis-ci.org/mollie/PrestaShop.svg?branch=master)](https://travis-ci.org/mollie/PrestaShop) +[![Greenkeeper badge](https://badges.greenkeeper.io/mollie/PrestaShop.svg)](https://greenkeeper.io/) +[![Release badge](https://img.shields.io/github/release/mollie/PrestaShop.svg)](https://github.com/mollie/PrestaShop/releases/latest) + +## Maintained by [Invertus](https://www.invertus.eu/). ## + +## Compatible with PrestaShop 1.5 to 1.7 ## + +** Please note: ** FTP access to your web server could be required for the installation of this module. +If you have no experience with this, then leave the installation of this module to your website developer or server administrator. + +## Installation PrestaShop 1.7 ## + +* Download the latest version of the module (the '.zip' file) via the [Releases page](https://github.com/mollie/Prestashop/releases) which is compatible +with PrestaShop 1.5 to 1.7. +* Go to the administration panel of your PrestaShop webshop +* In your administration panel, select the 'Modules' tab and then choose 'upload a module' at the top right of your screen +* Select 'select file' and then upload the '.zip' file which you downloaded earlier +* After the module has been installed, choose 'configure' +* Enter your _API-key_ and save the data. + +## Installation PrestaShop 1.5 and 1.6 ## + +* Download the latest version of the module (the '.zip' file) via the [Releases-page](https://github.com/mollie/Prestashop/releases) which is compatible +with PrestaShop 1.5 to 1.7. +* Go to the administration panel of your PrestaShop webshop +* In your administration panel, select the 'Modules' tab and then choose 'upload a module' at the top right of your screen +* Select 'select file' and then upload the '.zip' file which you downloaded earlier +* After the module has been installed, choose 'configure' +* Enter your _API-key_ and save the data. + +## or ## + +* Download the latest version of the module (the '.zip' file) via the [Releases-page](https://github.com/mollie/Prestashop/releases) which is compatible +with PrestaShop 1.5 to 1.7. +* Extract the archive +* Copy the `mollie` folder to the` modules` folder via FTP in your PrestaShop installation +* Go to the tab 'Modules' in your administration panel and choose 'Payments and Gateways' in the 'Categories' list. +* Click on the 'install' button on the right of the Mollie Payment Module +* Enter your _API-key_ and save the data. + +# Supported payment methods + +### iDeal + +[iDEAL](https://www.mollie.com/en/payments/ideal) makes paying for your online purchases safe, secure and easy. +iDEAL is a Dutch payment system which links customers directly to their online banking program when making an online purchase. + +[Mollie](https://www.mollie.com/) makes it easy to connect with iDEAL, without the usual technical and administrative hassle. +Mollie gives you access to your transaction overviews and other statistics at any time. It is also possible to receive a notification by e-mail or SMS after every successful payment. + +[Mollie](https://www.mollie.com/) is the perfect partner for recieving iDEAL payments and it is not surprising that [Mollie](https://www.mollie.com/) provides iDEAL payments +for more than 40,000 websites. + +### Credit card +[Credit card](https://www.mollie.com/en/payments/credit-card) is virtually the best-known method for receiving payments with global coverage. + +Because [Mollie](https://www.mollie.com/) supports the biggest credit card brands like Mastercard, VISA and American Express, your store will attract a lot more potential buyers. + +### Bancontact +[Bancontact](https://www.mollie.com/en/payments/bancontact) uses a physical card that is linked to credit on a Belgian bank account. Payments via Bancontact / Mister Cash are guaranteed and strongly resemble the iDEAL payment system for the Netherlands. + +Because payments are guaranteed, this payment method is a huge surplus for your online store. + +### SOFORT Banking +[SOFORT Banking](https://www.mollie.com/en/payments/sofort) is one of the most popular payment methods in Germany and active in 9 European countries: + +Germany, Belgium, the Netherlands, Italy, Austria, Poland, Switzerland, Spain and the United Kingdom. + +Payments are direct, non-reversible and this payment method opens up a huge market potential for your online store. + +### ING Home’Pay +[ING Home’Pay](https://www.mollie.com/en/payments/ing-homepay). Mollie allows you to quickly and easily accept payments with ING Home'Pay. + +It only takes 10 minutes to start receiving payments and there are no hidden fees involved, you only pay for successful transactions. + +### Bank transfers +[Bank transfers](https://www.mollie.com/en/payments/bank-transfer) received in the SEPA zone via [Mollie](https://www.mollie.com/). This allows you to receive payments from both individuals and business customers in more than 35 European countries. + +### PayPal +[PayPal](https://www.mollie.com/en/payments/paypal) is a very popular payment method which is used worldwide. In a just few clicks, you can receive payments by bank transfer, credit card or PayPal balance. + +### paysafecard +[paysafecard](https://www.mollie.com/en/payments/paysafecard) is the most popular prepaid card for online payments. With paysafecard you can receive prepaid payments from 43 countries. + +### KBC/CBC Payment Button +The [KBC / CBC Payment Button](https://www.mollie.com/en/payments/kbc-cbc) is an online payment method for KBC and CBC customers, together the largest bank in Belgium. + +KBC focuses on Flanders and CBC on Wallonia. + +### Belfius Pay Button +[Belfius](https://www.mollie.com/en/payments/belfius) is one of the largest banks in Belgium. By introducing the Belfius Pay Button, the bank provides its customers with their own payment solution. + +### CartaSi +[CartaSi](https://www.mollie.com/en/payments/cartasi) is one of the most widely used payment methods in Italy. + +There are over 13 million CartaSi credit cards in circulation. + +### Cartes Bancaires +[Cartes Bancaires](https://www.mollie.com/en/payments/cartes-bancaires) are the most used credit cards in France, with more than 64 million cards in circulation. + +The cards are co-branded with Visa. + +### EPS +[EPS](https://www.mollie.com/en/payments/eps). The Electronic Payment Standard (EPS) is a payment method, developed by various Austrian banks. + +This makes EPS the main bank transfer payment method in Austria and highly popular with Austrian shoppers. + +### Giropay +[Giropay](https://www.mollie.com/en/payments/giropay). Giropay is a popular bank transfer payment method in Germany. + +It uses more than 1,500 German banks, which makes it a trusted payment method under German customers. + +### Klarna: Pay later +[Klarna: Pay later](https://www.mollie.com/en/payments/klarna-pay-later). Klarna is a flexible payment solution, which allows your customers various, flexible, ways to pay. + +With Mollie you can integrate Klarna: Pay later quickly and start processing payments right away. + +### Klarna: Slice it +[Klarna: Slice it](https://www.mollie.com/en/payments/klarna-slice-it). Klarna is a flexible payment solution, which allows your customers various, flexible, ways to pay. + +With Mollie you can integrate Klarna: Slice it quickly and start processing payments right away. + +# Frequently Asked Questions # + +**The module can not be installed in PrestaShop 1.7.** + +* Go to the root of your website via FTP and then open the 'modules' folder. +* Delete the folder named 'mollie'. +* Re-install the Mollie module for PrestaShop 1.7. + +**I have installed the module, but the module does not appear during checkout.** + +* Check if the module is switched on and the correct API key is set. See the installation instructions. +* Check if euros is set as currency in your store. Mollie only supports euros. +* Check via "Advanced parameters" -> "Performance" if "Minimize HTML" is disabled. + +**Do I also need to set a return and / or webhook URL?** + +There is no need to set a redirect URL or webhook. The module automatically does this with every order. + +**After a successful payment, my customers will see the order history instead of the order confirmation.** + +This is a bug in PrestaShop which has been fixed from version 1.6.0.7. To resolve this, you should update your PrestaShop version. If you do not want to do this, you could also fix the bug yourself by adjusting one line of code. + +The relevant [github issue](https://github.com/mollie/Prestashop/issues/3) tells you exactly how to do this. + +**The order status is not updated** + +Mollie sends a message to your website when the status of the payment changes. It is possible that Mollie could not reach your website or that your website could not process the status. + +* Check your [Mollie management](https://www.mollie.com/beheer/) whether there are failed reports. +* Check if your website is running in 'maintenance mode'. Mollie can not reach your website if your website is running in maintenance mode if the Mollie module version is below 2.0.0. +From version 2.0.0 and up, the Mollie module does work in maintenance mode. +* Sometimes something goes wrong when creating the invoice. Check if the "Enable image for product" option is turned off in "Orders" -> "Invoices" -> "Invoice options" (from PrestaShop 1.6.1.0) or in "Preferences" -> "Orders" -> "PDF settings "(in PrestaShop 1.6.0.12 to 1.6.0.14). + +# Would you like to help improve this module? # + +Would you like to help make this module for PrestaShop even better? We are always open to [pull requests](https://github.com/mollie/Prestashop/pulls?utf8=%E2%9C%93&q=is%3Apr). + +And how about working at a [technology driven organization](https://jobs.mollie.com/)? Mollie is always looking for developers and system engineers. [Check our vacancies](https://jobs.mollie.com/) or [contact us](mailto:personeel@mollie.com). + +# License # +[BSD (Berkeley Software Distribution) License](http://www.opensource.org/licenses/bsd-license.php). +Copyright (c) 2013-2019, Mollie B.V. + +# Support # + +Do you have problems with the installation or do you think the module contains a bug? Send an email +to info@mollie.com with a accurate description of the problem. diff --git a/README_ES.md b/README_ES.md index 1bf6155e9..60ba31832 100644 --- a/README_ES.md +++ b/README_ES.md @@ -1,192 +1,192 @@ -[Nederlands](README_NL.md) [Deutsch](README_DE.md) [Français](README_FR.md) [English](README.md) - -![Mollie](https://www.mollie.com/files/Mollie-Logo-Style-Small.png) - -# Proveedor de servicios de pago PrestaShop [Mollie](https://www.mollie.com/). # - -Descargue el módulo [Mollie](https://www.mollie.com/) para PrestaShop. Mollie es un proveedor de servicios de pago (PSP) que proporciona a su tienda en línea los tipos de pago en línea más populares. - -Reciba pagos de clientes europeos con facilidad. Mollie proporciona tipos de pago a precios altamente competitivos. Solamente pague por transacción sin tarifas ocultas. - -Elija el mejor proveedor de pagos disponible para su tienda PrestaShop en línea. Crea tu cuenta de comerciante en [Mollie.com](https://www.mollie.com/). -¡Descargue e instale el módulo de pago Mollie PrestaShop y comience a recibir pagos en línea ahora mismo! - - - - -## Hecho y mantenido por [Invertus](https://www.invertus.eu). ## - -## Compatible con PrestaShop 1.5 a 1.7 ## - -** Tenga en cuenta: ** el acceso FTP a su servidor web podría ser necesario para la instalación de este módulo. -Si no tiene experiencia con esto, deje la instalación de este módulo al desarrollador de su sitio web o al administrador del servidor. - -## Instalación PrestaShop 1.7 ## - -* Descargue la última versión del módulo (el archivo '.zip') a través de la [página Releases](https://github.com/mollie/Prestashop/releases) que es compatible -con PrestaShop 1.5 a 1.7. -* Vaya al panel de administración de su tienda web PrestaShop -* En su panel de administración, seleccione la pestaña 'Modules' y luego elija 'upload a module' en la parte superior derecha de su pantalla -* Seleccione 'select file' y luego suba el archivo '.zip' que descargó anteriormente -* Después de que el módulo haya sido instalado, elija 'configure' -* Ingrese su _clave API_ y guarde los datos. - -## Instalación PrestaShop 1.5 y 1.6 ## - -* Descargue la última versión del módulo (el archivo '.zip') a través de la [página Releases](https://github.com/mollie/Prestashop/releases) que es compatible -con PrestaShop 1.5 a 1.7. -* Vaya al panel de administración de su tienda web PrestaShop -* En su panel de administración, seleccione la pestaña 'Modules' y luego elija 'upload a module' en la parte superior derecha de su pantalla -* Seleccione 'select file' y luego suba el archivo '.zip' que descargó anteriormente -* Después de que el módulo haya sido instalado, elija 'configure' -* Ingrese su _clave API_ y guarde los datos. - -## o ## - -* Descargue la última versión del módulo (el archivo '.zip') a través de la [página Releases](https://github.com/mollie/Prestashop/releases) que es compatible -con PrestaShop 1.5 a 1.7. -* Extraiga el archivo -* Copie la carpeta 'mollie' a la carpeta 'modules' a través de FTP en su instalación de PrestaShop -* Vaya a la pestaña 'Modules' en su panel de administración y elija 'Payments and Gateways' en la lista 'Categories'. -* Haga clic en el botón 'install' a la derecha del Módulo de pago Mollie -* Ingrese su _clave API_ y guarde los datos. - -# Tipos de pago admitidos - -### iDEAL - -[iDEAL](https://www.mollie.com/en/payments/ideal) hace que el pago de sus compras en línea sea seguro y fácil. -iDEAL es un sistema de pago holandés que vincula a los clientes directamente con su programa de banca en línea al realizar una compra en línea. - -[Mollie](https://www.mollie.com/) facilita la conexión con iDEAL, sin los problemas técnicos y administrativos habituales. -Mollie le da acceso a sus vistas generales de transacciones y otras estadísticas en cualquier momento. También es posible recibir una notificación por correo electrónico o SMS después de cada pago exitoso. - -[Mollie](https://www.mollie.com/) es el socio perfecto para recibir pagos iDEAL y no es sorprendente que [Mollie](https://www.mollie.com/) proporcione pagos iDEAL -para más de 40.000 sitios web. - -### Tarjeta de crédito -La [Tarjeta de crédito](https://www.mollie.com/en/payments/credit-card) es prácticamente el método más conocido para recibir pagos con cobertura global. - -Como [Mollie](https://www.mollie.com/) admite las marcas de tarjetas de crédito más grandes como Mastercard, VISA y American Express, su tienda atraerá a muchos más compradores potenciales. - -### Bancontact -[Bancontact](https://www.mollie.com/en/payments/bancontact) usa una tarjeta física que está vinculada al crédito en una cuenta bancaria belga. Los pagos a través de Bancontact / Mister Cash están garantizados y se asemejan mucho al sistema de pago iDEAL para los Países Bajos. - -Debido a que los pagos están garantizados, este método de pago es un gran aporte para su tienda en línea. - -### SOFORT Banking -[SOFORT Banking](https://www.mollie.com/en/payments/sofort) es uno de los tipos de pago más populares en Alemania y activo en 9 países europeos: - -Alemania, Bélgica, los Países Bajos, Italia, Austria, Polonia, Suiza, España y el Reino Unido. - -Los pagos son directos, no reversibles y este método de pago abre un enorme potencial de mercado para su tienda en línea. - -### ING Home’Pay -[ING Home’Pay](https://www.mollie.com/es/payments/ing-homepay). Mollie le permite aceptar pagos de forma rápida y sencilla con ING Home'Pay. - -Sólo le llevará 10 minutos empezar a recibir pagos y no hay cargos ocultos involucrados, sólo paga por transacciones realizadas con éxito. - -### Transferencias Bancarias -[Transferencias bancarias](https://www.mollie.com/en/payments/bank-transfer) recibidas en la zona SEPA a través de [Mollie](https://www.mollie.com/). Esto le permite recibir pagos de individuos y clientes comerciales en más de 35 países europeos. - -### PayPal -[PayPal](https://www.mollie.com/en/payments/paypal) es un método de pago muy popular que se utiliza en todo el mundo. En unos pocos clics, puede recibir pagos por transferencia bancaria, tarjeta de crédito o saldo de PayPal. - -### Bitcoin -[Bitcoin](https://www.mollie.com/en/payments/bitcoin) es una forma de dinero electrónico. El tipo de cambio se determina en el momento de la transacción, por lo que el monto y el pago están garantizados. - -### paysafecard -[paysafecard](https://www.mollie.com/en/payments/paysafecard) es la tarjeta prepagada más popular para pagos en línea. Con paysafecard puede recibir pagos prepagos de 43 países. - -### Botón de pago KBC/CBC -El [botón de pago KBC / CBC](https://www.mollie.com/en/payments/kbc-cbc) es un tipo de pago en línea para los clientes de KBC y CBC, junto con el banco más grande de Bélgica. - -KBC se enfoca en Flandes y CBC en Valonia. - -### Botón de Pago de Belfius -[Belfius](https://www.mollie.com/en/payments/belfius) es uno de los bancos más grandes de Bélgica. Al introducir el botón de pago Belfius, el banco ofrece a sus clientes su propia solución de pago. - -### CartaSi -[CartaSi](https://www.mollie.com/en/payments/cartasi) es uno de los tipos de pago más utilizados en Italia. - -Hay más de 13 millones de tarjetas de crédito CartaSi en circulación. - -### Cartes Bancaires -[Cartes Bancaires](https://www.mollie.com/en/payments/cartes-bancaires) son las tarjetas de crédito más usadas en Francia, con más de 64 millones de tarjetas en circulación. - -Las tarjetas que comparten marca con Visa. - -### EPS -[EPS](https://www.mollie.com/es/payments/eps). El Electronic Payment Standard (EPS) es un tipo de pago desarrollado por varios bancos austriacos. - -Esto hace que el EPS sea el principal tipo de pago por transferencia bancaria en Austria y muy popular entre los compradores austriacos. - -### Giropay -[Giropay](https://www.mollie.com/es/payments/giropay). Giropay es un tipo de pago por transferencia bancaria, popular en Alemania. - -Utiliza más de 1.500 bancos alemanes, lo que lo convierte en un tipo de pago confiable para los clientes alemanes. - -### Klarna: Pay later -[Klarna: Pay later](https://www.mollie.com/es/payments/klarna-pay-later). Klarna es una solución de pago flexible que les permite a sus clientes diversas formas de pago flexibles. - -Sólo le llevará 10 minutos empezar a recibir pagos a través de Klarna: Pay later y no hay cargos ocultos involucrados, sólo paga por transacciones realizadas con éxito. - -### Klarna: Slice it -[Klarna: Slice it](https://www.mollie.com/es/payments/klarna-slice-it). Klarna es una solución de pago flexible que les permite a sus clientes diversas formas de pago flexibles. - -Sólo le llevará 10 minutos empezar a recibir pagos a través de Klarna: Slice it y no hay cargos ocultos involucrados, sólo paga por transacciones realizadas con éxito. - -# Preguntas frecuentes # - -**El módulo no se puede instalar en PrestaShop 1.7.** - -* Vaya a la raíz de su sitio web a través de FTP y luego abra la carpeta "modules". -* Elimina la carpeta llamada 'mollie'. -* Vuelva a instalar el módulo Mollie para PrestaShop 1.7. - -**He instalado el módulo, pero el módulo no aparece durante el proceso de pago.** - -* Compruebe si el módulo está encendido y la clave API correcta está configurada. Vea las instrucciones de instalación. -* Compruebe si los euros están configurados como moneda en su tienda. Mollie solo admite euros. -* Verifique a través de "Advanced parameters" -> "Performance" si "Minimize HTML" está desactivado. - -**¿También necesito establecer una URL de retorno y / o webhook?** - -No es necesario configurar una URL de redireccionamiento o un enlace web. El módulo hace esto automáticamente con cada orden. - -**Después de un pago exitoso, mis clientes verán el historial de pedidos en lugar de la confirmación del pedido.** - -Este es un error en PrestaShop que se ha corregido desde la versión 1.6.0.7. Para resolver esto, debe actualizar su versión de PrestaShop. Si no quieres hacer esto, también puedes corregir el error ajustando una línea de código. - -El [aspecto relevante de github](https://github.com/mollie/Prestashop/issues/3) es que te dice exactamente cómo hacer esto. - -**El estado del pedido no está actualizado** - -Mollie envía un mensaje a su sitio web cuando cambia el estado del pago. Es posible que Mollie no haya podido acceder a su sitio web o que su sitio web no haya podido procesar el estado. - -* Verifique en su [administración en Mollie](https://www.mollie.com/beheer/) si hay informes fallidos. -* Verifique si su sitio web se está ejecutando en 'modo de mantenimiento'. Mollie no puede acceder a su sitio web si su sitio web se está ejecutando en modo de mantenimiento si la versión del módulo Mollie está por debajo de 2.0.0. -A partir de la versión 2.0.0 y posteriores, el módulo Mollie funciona en modo de mantenimiento. -* A veces, algo sale mal al crear la factura. Compruebe si la opción "Habilitar imagen para el producto" está desactivada en "Pedidos" -> "Facturas" -> "Opciones de factura" (de PrestaShop 1.6.1.0) o en "Preferencias" -> "Pedidos" -> "Configuración de PDF "(en PrestaShop 1.6.0.12 a 1.6.0.14). - -# ¿Te gustaría ayudar a mejorar este módulo? # - -¿Te gustaría ayudar a mejorar aún más este módulo para PrestaShop? Siempre estamos abiertos a [aceptar peticiones](https://github.com/mollie/Prestashop/pulls?utf8=%E2%9C%93&q=is%3Apr). - -¿Y qué tal trabajar en una [organización impulsada por la tecnología](https://jobs.mollie.com/)? Mollie siempre está buscando desarrolladores e ingenieros de sistemas. [Consulte nuestras vacantes](https://jobs.mollie.com/) o [contáctenos](mailto:personeel@mollie.com). - -# Licencia # -[Licencia de BSD (Berkeley Software Distribution)](http://www.opensource.org/licenses/bsd-license.php). -Copyright (c) 2013-2019, Mollie B.V. - -# Soporte # - -¿Tiene problemas con la instalación o cree que el módulo contiene un error? Enviar un correo electrónico -a info@mollie.com con una descripción precisa del problema. +[Nederlands](README_NL.md) [Deutsch](README_DE.md) [Français](README_FR.md) [English](README.md) + +![Mollie](https://www.mollie.com/files/Mollie-Logo-Style-Small.png) + +# Proveedor de servicios de pago PrestaShop [Mollie](https://www.mollie.com/). # + +Descargue el módulo [Mollie](https://www.mollie.com/) para PrestaShop. Mollie es un proveedor de servicios de pago (PSP) que proporciona a su tienda en línea los tipos de pago en línea más populares. + +Reciba pagos de clientes europeos con facilidad. Mollie proporciona tipos de pago a precios altamente competitivos. Solamente pague por transacción sin tarifas ocultas. + +Elija el mejor proveedor de pagos disponible para su tienda PrestaShop en línea. Crea tu cuenta de comerciante en [Mollie.com](https://www.mollie.com/). +¡Descargue e instale el módulo de pago Mollie PrestaShop y comience a recibir pagos en línea ahora mismo! + + + + +## Hecho y mantenido por [Invertus](https://www.invertus.eu). ## + +## Compatible con PrestaShop 1.5 a 1.7 ## + +** Tenga en cuenta: ** el acceso FTP a su servidor web podría ser necesario para la instalación de este módulo. +Si no tiene experiencia con esto, deje la instalación de este módulo al desarrollador de su sitio web o al administrador del servidor. + +## Instalación PrestaShop 1.7 ## + +* Descargue la última versión del módulo (el archivo '.zip') a través de la [página Releases](https://github.com/mollie/Prestashop/releases) que es compatible +con PrestaShop 1.5 a 1.7. +* Vaya al panel de administración de su tienda web PrestaShop +* En su panel de administración, seleccione la pestaña 'Modules' y luego elija 'upload a module' en la parte superior derecha de su pantalla +* Seleccione 'select file' y luego suba el archivo '.zip' que descargó anteriormente +* Después de que el módulo haya sido instalado, elija 'configure' +* Ingrese su _clave API_ y guarde los datos. + +## Instalación PrestaShop 1.5 y 1.6 ## + +* Descargue la última versión del módulo (el archivo '.zip') a través de la [página Releases](https://github.com/mollie/Prestashop/releases) que es compatible +con PrestaShop 1.5 a 1.7. +* Vaya al panel de administración de su tienda web PrestaShop +* En su panel de administración, seleccione la pestaña 'Modules' y luego elija 'upload a module' en la parte superior derecha de su pantalla +* Seleccione 'select file' y luego suba el archivo '.zip' que descargó anteriormente +* Después de que el módulo haya sido instalado, elija 'configure' +* Ingrese su _clave API_ y guarde los datos. + +## o ## + +* Descargue la última versión del módulo (el archivo '.zip') a través de la [página Releases](https://github.com/mollie/Prestashop/releases) que es compatible +con PrestaShop 1.5 a 1.7. +* Extraiga el archivo +* Copie la carpeta 'mollie' a la carpeta 'modules' a través de FTP en su instalación de PrestaShop +* Vaya a la pestaña 'Modules' en su panel de administración y elija 'Payments and Gateways' en la lista 'Categories'. +* Haga clic en el botón 'install' a la derecha del Módulo de pago Mollie +* Ingrese su _clave API_ y guarde los datos. + +# Tipos de pago admitidos + +### iDEAL + +[iDEAL](https://www.mollie.com/en/payments/ideal) hace que el pago de sus compras en línea sea seguro y fácil. +iDEAL es un sistema de pago holandés que vincula a los clientes directamente con su programa de banca en línea al realizar una compra en línea. + +[Mollie](https://www.mollie.com/) facilita la conexión con iDEAL, sin los problemas técnicos y administrativos habituales. +Mollie le da acceso a sus vistas generales de transacciones y otras estadísticas en cualquier momento. También es posible recibir una notificación por correo electrónico o SMS después de cada pago exitoso. + +[Mollie](https://www.mollie.com/) es el socio perfecto para recibir pagos iDEAL y no es sorprendente que [Mollie](https://www.mollie.com/) proporcione pagos iDEAL +para más de 40.000 sitios web. + +### Tarjeta de crédito +La [Tarjeta de crédito](https://www.mollie.com/en/payments/credit-card) es prácticamente el método más conocido para recibir pagos con cobertura global. + +Como [Mollie](https://www.mollie.com/) admite las marcas de tarjetas de crédito más grandes como Mastercard, VISA y American Express, su tienda atraerá a muchos más compradores potenciales. + +### Bancontact +[Bancontact](https://www.mollie.com/en/payments/bancontact) usa una tarjeta física que está vinculada al crédito en una cuenta bancaria belga. Los pagos a través de Bancontact / Mister Cash están garantizados y se asemejan mucho al sistema de pago iDEAL para los Países Bajos. + +Debido a que los pagos están garantizados, este método de pago es un gran aporte para su tienda en línea. + +### SOFORT Banking +[SOFORT Banking](https://www.mollie.com/en/payments/sofort) es uno de los tipos de pago más populares en Alemania y activo en 9 países europeos: + +Alemania, Bélgica, los Países Bajos, Italia, Austria, Polonia, Suiza, España y el Reino Unido. + +Los pagos son directos, no reversibles y este método de pago abre un enorme potencial de mercado para su tienda en línea. + +### ING Home’Pay +[ING Home’Pay](https://www.mollie.com/es/payments/ing-homepay). Mollie le permite aceptar pagos de forma rápida y sencilla con ING Home'Pay. + +Sólo le llevará 10 minutos empezar a recibir pagos y no hay cargos ocultos involucrados, sólo paga por transacciones realizadas con éxito. + +### Transferencias Bancarias +[Transferencias bancarias](https://www.mollie.com/en/payments/bank-transfer) recibidas en la zona SEPA a través de [Mollie](https://www.mollie.com/). Esto le permite recibir pagos de individuos y clientes comerciales en más de 35 países europeos. + +### PayPal +[PayPal](https://www.mollie.com/en/payments/paypal) es un método de pago muy popular que se utiliza en todo el mundo. En unos pocos clics, puede recibir pagos por transferencia bancaria, tarjeta de crédito o saldo de PayPal. + +### Bitcoin +[Bitcoin](https://www.mollie.com/en/payments/bitcoin) es una forma de dinero electrónico. El tipo de cambio se determina en el momento de la transacción, por lo que el monto y el pago están garantizados. + +### paysafecard +[paysafecard](https://www.mollie.com/en/payments/paysafecard) es la tarjeta prepagada más popular para pagos en línea. Con paysafecard puede recibir pagos prepagos de 43 países. + +### Botón de pago KBC/CBC +El [botón de pago KBC / CBC](https://www.mollie.com/en/payments/kbc-cbc) es un tipo de pago en línea para los clientes de KBC y CBC, junto con el banco más grande de Bélgica. + +KBC se enfoca en Flandes y CBC en Valonia. + +### Botón de Pago de Belfius +[Belfius](https://www.mollie.com/en/payments/belfius) es uno de los bancos más grandes de Bélgica. Al introducir el botón de pago Belfius, el banco ofrece a sus clientes su propia solución de pago. + +### CartaSi +[CartaSi](https://www.mollie.com/en/payments/cartasi) es uno de los tipos de pago más utilizados en Italia. + +Hay más de 13 millones de tarjetas de crédito CartaSi en circulación. + +### Cartes Bancaires +[Cartes Bancaires](https://www.mollie.com/en/payments/cartes-bancaires) son las tarjetas de crédito más usadas en Francia, con más de 64 millones de tarjetas en circulación. + +Las tarjetas que comparten marca con Visa. + +### EPS +[EPS](https://www.mollie.com/es/payments/eps). El Electronic Payment Standard (EPS) es un tipo de pago desarrollado por varios bancos austriacos. + +Esto hace que el EPS sea el principal tipo de pago por transferencia bancaria en Austria y muy popular entre los compradores austriacos. + +### Giropay +[Giropay](https://www.mollie.com/es/payments/giropay). Giropay es un tipo de pago por transferencia bancaria, popular en Alemania. + +Utiliza más de 1.500 bancos alemanes, lo que lo convierte en un tipo de pago confiable para los clientes alemanes. + +### Klarna: Pay later +[Klarna: Pay later](https://www.mollie.com/es/payments/klarna-pay-later). Klarna es una solución de pago flexible que les permite a sus clientes diversas formas de pago flexibles. + +Sólo le llevará 10 minutos empezar a recibir pagos a través de Klarna: Pay later y no hay cargos ocultos involucrados, sólo paga por transacciones realizadas con éxito. + +### Klarna: Slice it +[Klarna: Slice it](https://www.mollie.com/es/payments/klarna-slice-it). Klarna es una solución de pago flexible que les permite a sus clientes diversas formas de pago flexibles. + +Sólo le llevará 10 minutos empezar a recibir pagos a través de Klarna: Slice it y no hay cargos ocultos involucrados, sólo paga por transacciones realizadas con éxito. + +# Preguntas frecuentes # + +**El módulo no se puede instalar en PrestaShop 1.7.** + +* Vaya a la raíz de su sitio web a través de FTP y luego abra la carpeta "modules". +* Elimina la carpeta llamada 'mollie'. +* Vuelva a instalar el módulo Mollie para PrestaShop 1.7. + +**He instalado el módulo, pero el módulo no aparece durante el proceso de pago.** + +* Compruebe si el módulo está encendido y la clave API correcta está configurada. Vea las instrucciones de instalación. +* Compruebe si los euros están configurados como moneda en su tienda. Mollie solo admite euros. +* Verifique a través de "Advanced parameters" -> "Performance" si "Minimize HTML" está desactivado. + +**¿También necesito establecer una URL de retorno y / o webhook?** + +No es necesario configurar una URL de redireccionamiento o un enlace web. El módulo hace esto automáticamente con cada orden. + +**Después de un pago exitoso, mis clientes verán el historial de pedidos en lugar de la confirmación del pedido.** + +Este es un error en PrestaShop que se ha corregido desde la versión 1.6.0.7. Para resolver esto, debe actualizar su versión de PrestaShop. Si no quieres hacer esto, también puedes corregir el error ajustando una línea de código. + +El [aspecto relevante de github](https://github.com/mollie/Prestashop/issues/3) es que te dice exactamente cómo hacer esto. + +**El estado del pedido no está actualizado** + +Mollie envía un mensaje a su sitio web cuando cambia el estado del pago. Es posible que Mollie no haya podido acceder a su sitio web o que su sitio web no haya podido procesar el estado. + +* Verifique en su [administración en Mollie](https://www.mollie.com/beheer/) si hay informes fallidos. +* Verifique si su sitio web se está ejecutando en 'modo de mantenimiento'. Mollie no puede acceder a su sitio web si su sitio web se está ejecutando en modo de mantenimiento si la versión del módulo Mollie está por debajo de 2.0.0. +A partir de la versión 2.0.0 y posteriores, el módulo Mollie funciona en modo de mantenimiento. +* A veces, algo sale mal al crear la factura. Compruebe si la opción "Habilitar imagen para el producto" está desactivada en "Pedidos" -> "Facturas" -> "Opciones de factura" (de PrestaShop 1.6.1.0) o en "Preferencias" -> "Pedidos" -> "Configuración de PDF "(en PrestaShop 1.6.0.12 a 1.6.0.14). + +# ¿Te gustaría ayudar a mejorar este módulo? # + +¿Te gustaría ayudar a mejorar aún más este módulo para PrestaShop? Siempre estamos abiertos a [aceptar peticiones](https://github.com/mollie/Prestashop/pulls?utf8=%E2%9C%93&q=is%3Apr). + +¿Y qué tal trabajar en una [organización impulsada por la tecnología](https://jobs.mollie.com/)? Mollie siempre está buscando desarrolladores e ingenieros de sistemas. [Consulte nuestras vacantes](https://jobs.mollie.com/) o [contáctenos](mailto:personeel@mollie.com). + +# Licencia # +[Licencia de BSD (Berkeley Software Distribution)](http://www.opensource.org/licenses/bsd-license.php). +Copyright (c) 2013-2019, Mollie B.V. + +# Soporte # + +¿Tiene problemas con la instalación o cree que el módulo contiene un error? Enviar un correo electrónico +a info@mollie.com con una descripción precisa del problema. diff --git a/README_FR.md b/README_FR.md index ccd4ff9d5..891e75afc 100644 --- a/README_FR.md +++ b/README_FR.md @@ -1,192 +1,192 @@ -[Nederlands](README_NL.md) [Deutsch](README_DE.md) [English](README.md) [Español](README_ES.md) - -![Mollie](https://www.mollie.com/files/Mollie-Logo-Style-Small.png) - -# PrestaShop prestataire de paiement [Mollie](https://www.mollie.com/). # - -Téléchargez le module [Mollie](https://www.mollie.com/) pour PrestaShop. Mollie est un prestataire de paiement (PSP) qui fournit à votre boutique en ligne les modes de paiement en ligne les plus populaires. - -Recevez facilement les paiements de clients européens. Mollie offre des modes de paiement à des tarifs très compétitifs. Ne payez que par transaction et sans frais cachés. - -Choisissez le meilleur prestataire de paiement disponible pour votre boutique en ligne PrestaShop. Créez votre compte marchand sur [Mollie.com](https://www.mollie.com/). -Téléchargez et installez le module de paiement Mollie PrestaShop et commencez à recevoir des paiements en ligne dès maintenant ! - - - - -## Fabriqué et maintenu par [Invertus](https://www.invertus.eu). ## - -## Compatible avec PrestaShop 1.5 à 1.7 ## - -**Veuillez noter que** l'accès FTP à votre serveur web peut être requis pour l'installation de ce module. -Si vous n'avez aucune expérience dans ce domaine, laissez l'installation de ce module au développeur de votre site Web ou à l'administrateur de votre serveur. - -## Installation PrestaShop 1.7 ## - -* Télécharger la dernière version du module (le fichier '.zip') via la [page Releases](https://github.com/mollie/Prestashop/releases) qui est compatible -avec PrestaShop 1.5 à 1.7. -* Allez dans le panneau d'administration de votre boutique en ligne PrestaShop -* Dans votre panneau d'administration, sélectionnez l'onglet 'Modules' et choisissez 'upload a module' en haut à droite de votre écran -* Sélectionnez 'select file' et téléchargez le fichier '.zip' que vous avez téléchargé précédemment -* Après l'installation du module, choisissez 'configure' -* Entrez votre _clé_ API et enregistrez les données. - -## Installation PrestaShop 1.5 et 1.6 ## - -* Télécharger la dernière version du module (le fichier '.zip') via [la](https://github.com/mollie/Prestashop/releases) page Releases compatible -avec PrestaShop 1.5 à 1.7. -* Allez dans le panneau d'administration de votre boutique en ligne PrestaShop -* Dans votre panneau d'administration, sélectionnez l'onglet 'Modules' et choisissez 'upload a module' en haut à droite de votre écran -* Sélectionnez 'select file' et téléchargez le fichier '.zip' que vous avez téléchargé précédemment -* Après l'installation du module, choisissez 'configure' -* Entrez votre _clé_ API et enregistrez les données. - -## ou ## - -* Télécharger la dernière version du module (le fichier '.zip') via [la](https://github.com/mollie/Prestashop/releases) page Releases compatible -avec PrestaShop 1.5 à 1.7. -* Extraire l'archive -* Copiez le dossier `mollie` dans le dossier `modules` via FTP dans votre installation PrestaShop -* Allez dans l'onglet 'Modules' dans votre panneau d'administration et choisissez 'Payments and Gateways' dans la liste 'Categories'. -* Cliquez sur le bouton 'install' à droite du module de paiement Mollie -* Entrez votre _clé_ API et enregistrez les données. - -# Modes de paiement pris en charge - -### iDeal - -[iDEAL](https://www.mollie.com/en/payments/ideal) rend le paiement de vos achats en ligne sûr, sécurisé et facile. -iDEAL est un système de paiement néerlandais qui relie les clients directement à leur programme de banque en ligne lorsqu'ils effectuent un achat en ligne. - -[Mollie](https://www.mollie.com/) facilite la connexion avec iDEAL, sans les tracas techniques et administratifs habituels. -Mollie vous donne accès à vos aperçus de transactions et autres statistiques en tout temps. Il est également possible de recevoir une notification par e-mail ou SMS après chaque paiement réussi. - -[Mollie](https://www.mollie.com/) est le partenaire idéal pour recevoir les paiements iDEAL et il n'est pas surprenant que [Mollie](https://www.mollie.com/) fournisse les paiements iDEAL -pour plus de 40 000 sites Web. - -### Carte de crédit -[La carte de crédit](https://www.mollie.com/en/payments/credit-card) est pratiquement le mode de paiement le plus connu pour recevoir des paiements avec une couverture mondiale. - -Parce que [Mollie](https://www.mollie.com/) supporte les plus grandes marques de cartes de crédit comme Mastercard, VISA et American Express, votre magasin attirera beaucoup plus d'acheteurs potentiels. - -### Bancontact -[Bancontact](https://www.mollie.com/en/payments/bancontact) utilise une carte physique liée à un crédit sur un compte bancaire belge. Les paiements via Bancontact / Mister Cash sont garantis et ressemblent fortement au système de paiement iDEAL pour les Pays-Bas. - -Parce que les paiements sont garantis, ce mode de paiement est un énorme surplus pour votre boutique en ligne. - -### SOFORT Banking -[SOFORT Banking](https://www.mollie.com/en/payments/sofort) est l'un des moyens de paiement les plus populaires en Allemagne et est actif dans 9 pays européens : - -Allemagne, Belgique, Pays-Bas, Italie, Autriche, Pologne, Suisse, Espagne et Royaume-Uni. - -Les paiements sont directs, non réversibles et ce mode de paiement ouvre un énorme potentiel de marché pour votre boutique en ligne. - -### ING Home’Pay -[ING Home’Pay](https://www.mollie.com/fr/payments/ing-homepay). Mollie vous permet d'accepter rapidement et facilement des paiements avec ING Home'Pay. - -Il ne faut que 10 minutes pour commencer à recevoir les paiements et il n'y a pas de frais cachés, vous ne payez que pour les transactions réussies. - -### Virements bancaires -[Virements bancaires](https://www.mollie.com/en/payments/bank-transfer) reçus dans la zone SEPA via [Mollie](https://www.mollie.com/). Cela vous permet de recevoir des paiements de particuliers et d'entreprises dans plus de 35 pays européens. - -### PayPal -[PayPal](https://www.mollie.com/en/payments/paypal) est un mode de paiement très populaire qui est utilisé dans le monde entier. En quelques clics, vous pouvez recevoir des paiements par virement bancaire, carte de crédit ou solde PayPal. - -### Bitcoin -[Bitcoin](https://www.mollie.com/en/payments/bitcoin) est une forme de monnaie électronique. Le taux de change est déterminé au moment de la transaction, de sorte que le montant et le paiement sont garantis. - -### paysafecard -[paysafecard](https://www.mollie.com/en/payments/paysafecard) est la carte prépayée la plus populaire pour les paiements en ligne. Avec paysafecard, vous pouvez recevoir des paiements prépayés de 43 pays. - -### Bouton de paiement KBC / CBC -Le [bouton de paiement KBC / CBC](https://www.mollie.com/en/payments/kbc-cbc) est un mode de paiement en ligne pour les clients de KBC et CBC, la plus grande banque de Belgique. - -KBC se concentre sur la Flandre et CBC sur la Wallonie. - -### Bouton de paiement Belfius -[Belfius](https://www.mollie.com/en/payments/belfius) est l'une des plus grandes banques de Belgique. En introduisant le bouton de paiement Belfius, la banque met à la disposition de ses clients sa propre solution de paiement. - -### CartaSi -[CartaSi](https://www.mollie.com/en/payments/cartasi) est l'un des modes de paiement les plus utilisés en Italie. - -Il y a plus de 13 millions de cartes de crédit CartaSi en circulation. - -### Cartes Bancaires -[Cartes Bancaires](https://www.mollie.com/en/payments/cartes-bancaires) est la carte de crédit la plus utilisée en France, avec plus de 64 millions de cartes en circulation. - -Les cartes sont co-marquées avec Visa. - -### EPS -[EPS](https://www.mollie.com/fr/payments/eps). L'Electronic Payment Standard (EPS) est une méthode de paiement développé par diverses banques autrichiennes. - -Devenue très populaire auprès des consommateurs autrichiens, EPS est la référence en matière de virement bancaire en Autriche. - -### Giropay -[Giropay](https://www.mollie.com/fr/payments/giropay). Giropay est une méthode de paiement très populaire de virement bancaire en Allemagne. - -Utilisé par plus de 15000 à travers le pays, cela en fait un moyen de paiement fiable, réputé auprès des consommateurs allemands. - -### Klarna : Pay later -[Klarna : Pay later](https://www.mollie.com/fr/payments/klarna-pay-later). Klarna est une solution de paiement flexible, qui permet à vos clients des modes de paiement variés. - -Commencer à recevoir des paiements par Klarna Pay later ne prend que quelques minutes. - -### Klarna : Slice it -[Klarna : Slice it](https://www.mollie.com/fr/payments/klarna-slice-it). Klarna est une solution de paiement flexible, qui permet à vos clients des modes de paiement variés. - -Commencer à recevoir des paiements par Klarna Slice it ne prend que quelques minutes. - -# Foire aux questions # - -**Le module ne peut pas être installé dans PrestaShop 1.7.** - -* Allez à la racine de votre site web via FTP puis ouvrez le dossier 'modules'. -* Supprimer le dossier nommé 'mollie'. -* Réinstallez le module Mollie pour PrestaShop 1.7. - -**J'ai installé le module, mais le module n'apparaît pas pendant le check-out.** - -* Vérifier si le module est allumé et si la clé API correcte est réglée. Voir les instructions d'installation. -* Vérifiez si l'euro est défini comme devise dans votre magasin. Mollie ne soutient que les euros. -* Vérifier via "Advanced parameters" -> "Performance" si "Minimize HTML" est désactivé. - -**Dois-je également définir une URL de retour et / ou un webhook ?** - -Il n'est pas nécessaire de définir une URL de redirection ou un Webhook. Le module le fait automatiquement à chaque commande. - -**Après un paiement réussi, mes clients verront l'historique des commandes au lieu de la confirmation de commande.** - -C'est un bug dans PrestaShop qui a été corrigé à partir de la version 1.6.0.7. Pour résoudre ce problème, vous devez mettre à jour votre version de PrestaShop. Si vous ne voulez pas le faire, vous pouvez aussi corriger le bogue vous-même en ajustant une ligne de code. - -Le [numéro correspondant de github](https://github.com/mollie/Prestashop/issues/3) vous indique exactement comment le faire. - -**Le statut de la commande n'est pas mis à jour** - -Mollie envoie un message à votre site Web lorsque le statut du paiement change. Il est possible que Mollie ne puisse pas atteindre votre site Web ou que votre site Web ne puisse pas traiter le statut. - -* Vérifiez la [gestion de votre Mollie](https://www.mollie.com/beheer/) s'il y a des rapports échoués. -* Vérifiez si votre site Web fonctionne en 'maintenance mode'. Mollie ne peut pas accéder à votre site Web si votre site Web est en mode de maintenance si la version du module Mollie est inférieure à 2.0.0.0. -A partir de la version 2.0.0 et plus, le module Mollie fonctionne en mode maintenance. -* Il arrive parfois qu'il y ait un problème lors de la création de la facture. Vérifiez si l'option "Enable image for product" est désactivée dans "Orders" -> "Invoices" -> "Invoice options" (de PrestaShop 1.6.1.0) ou dans "Preferences" -> "Orders" -> "PDF settings"(dans PrestaShop 1.6.0.12 à 1.6.0.14). - -# Souhaitez-vous contribuer à l'amélioration de ce module ? # - -Aimeriez-vous aider à améliorer ce module pour PrestaShop ? Nous sommes toujours ouverts aux [demandes de retrait](https://github.com/mollie/Prestashop/pulls?utf8=%E2%9C%93&q=is%3Apr). - -Et que diriez-vous de travailler dans une [organisation axée sur la technologie](https://jobs.mollie.com/) ? Mollie est toujours à la recherche de développeurs et d'ingénieurs système. [Consultez nos offres d'emploi](https://jobs.mollie.com/) ou [contactez-nous](mailto:personeel@mollie.com). - -# Licence # -[Licence BSD (Berkeley Software Distribution)](http://www.opensource.org/licenses/bsd-license.php). -Copyright (c) 2013-2019, Mollie B.V. - -# Support # - -Avez-vous des problèmes avec l'installation ou pensez-vous que le module contient un bug ? Envoyer un email -à info@mollie.com avec une description précise du problème. +[Nederlands](README_NL.md) [Deutsch](README_DE.md) [English](README.md) [Español](README_ES.md) + +![Mollie](https://www.mollie.com/files/Mollie-Logo-Style-Small.png) + +# PrestaShop prestataire de paiement [Mollie](https://www.mollie.com/). # + +Téléchargez le module [Mollie](https://www.mollie.com/) pour PrestaShop. Mollie est un prestataire de paiement (PSP) qui fournit à votre boutique en ligne les modes de paiement en ligne les plus populaires. + +Recevez facilement les paiements de clients européens. Mollie offre des modes de paiement à des tarifs très compétitifs. Ne payez que par transaction et sans frais cachés. + +Choisissez le meilleur prestataire de paiement disponible pour votre boutique en ligne PrestaShop. Créez votre compte marchand sur [Mollie.com](https://www.mollie.com/). +Téléchargez et installez le module de paiement Mollie PrestaShop et commencez à recevoir des paiements en ligne dès maintenant ! + + + + +## Fabriqué et maintenu par [Invertus](https://www.invertus.eu). ## + +## Compatible avec PrestaShop 1.5 à 1.7 ## + +**Veuillez noter que** l'accès FTP à votre serveur web peut être requis pour l'installation de ce module. +Si vous n'avez aucune expérience dans ce domaine, laissez l'installation de ce module au développeur de votre site Web ou à l'administrateur de votre serveur. + +## Installation PrestaShop 1.7 ## + +* Télécharger la dernière version du module (le fichier '.zip') via la [page Releases](https://github.com/mollie/Prestashop/releases) qui est compatible +avec PrestaShop 1.5 à 1.7. +* Allez dans le panneau d'administration de votre boutique en ligne PrestaShop +* Dans votre panneau d'administration, sélectionnez l'onglet 'Modules' et choisissez 'upload a module' en haut à droite de votre écran +* Sélectionnez 'select file' et téléchargez le fichier '.zip' que vous avez téléchargé précédemment +* Après l'installation du module, choisissez 'configure' +* Entrez votre _clé_ API et enregistrez les données. + +## Installation PrestaShop 1.5 et 1.6 ## + +* Télécharger la dernière version du module (le fichier '.zip') via [la](https://github.com/mollie/Prestashop/releases) page Releases compatible +avec PrestaShop 1.5 à 1.7. +* Allez dans le panneau d'administration de votre boutique en ligne PrestaShop +* Dans votre panneau d'administration, sélectionnez l'onglet 'Modules' et choisissez 'upload a module' en haut à droite de votre écran +* Sélectionnez 'select file' et téléchargez le fichier '.zip' que vous avez téléchargé précédemment +* Après l'installation du module, choisissez 'configure' +* Entrez votre _clé_ API et enregistrez les données. + +## ou ## + +* Télécharger la dernière version du module (le fichier '.zip') via [la](https://github.com/mollie/Prestashop/releases) page Releases compatible +avec PrestaShop 1.5 à 1.7. +* Extraire l'archive +* Copiez le dossier `mollie` dans le dossier `modules` via FTP dans votre installation PrestaShop +* Allez dans l'onglet 'Modules' dans votre panneau d'administration et choisissez 'Payments and Gateways' dans la liste 'Categories'. +* Cliquez sur le bouton 'install' à droite du module de paiement Mollie +* Entrez votre _clé_ API et enregistrez les données. + +# Modes de paiement pris en charge + +### iDeal + +[iDEAL](https://www.mollie.com/en/payments/ideal) rend le paiement de vos achats en ligne sûr, sécurisé et facile. +iDEAL est un système de paiement néerlandais qui relie les clients directement à leur programme de banque en ligne lorsqu'ils effectuent un achat en ligne. + +[Mollie](https://www.mollie.com/) facilite la connexion avec iDEAL, sans les tracas techniques et administratifs habituels. +Mollie vous donne accès à vos aperçus de transactions et autres statistiques en tout temps. Il est également possible de recevoir une notification par e-mail ou SMS après chaque paiement réussi. + +[Mollie](https://www.mollie.com/) est le partenaire idéal pour recevoir les paiements iDEAL et il n'est pas surprenant que [Mollie](https://www.mollie.com/) fournisse les paiements iDEAL +pour plus de 40 000 sites Web. + +### Carte de crédit +[La carte de crédit](https://www.mollie.com/en/payments/credit-card) est pratiquement le mode de paiement le plus connu pour recevoir des paiements avec une couverture mondiale. + +Parce que [Mollie](https://www.mollie.com/) supporte les plus grandes marques de cartes de crédit comme Mastercard, VISA et American Express, votre magasin attirera beaucoup plus d'acheteurs potentiels. + +### Bancontact +[Bancontact](https://www.mollie.com/en/payments/bancontact) utilise une carte physique liée à un crédit sur un compte bancaire belge. Les paiements via Bancontact / Mister Cash sont garantis et ressemblent fortement au système de paiement iDEAL pour les Pays-Bas. + +Parce que les paiements sont garantis, ce mode de paiement est un énorme surplus pour votre boutique en ligne. + +### SOFORT Banking +[SOFORT Banking](https://www.mollie.com/en/payments/sofort) est l'un des moyens de paiement les plus populaires en Allemagne et est actif dans 9 pays européens : + +Allemagne, Belgique, Pays-Bas, Italie, Autriche, Pologne, Suisse, Espagne et Royaume-Uni. + +Les paiements sont directs, non réversibles et ce mode de paiement ouvre un énorme potentiel de marché pour votre boutique en ligne. + +### ING Home’Pay +[ING Home’Pay](https://www.mollie.com/fr/payments/ing-homepay). Mollie vous permet d'accepter rapidement et facilement des paiements avec ING Home'Pay. + +Il ne faut que 10 minutes pour commencer à recevoir les paiements et il n'y a pas de frais cachés, vous ne payez que pour les transactions réussies. + +### Virements bancaires +[Virements bancaires](https://www.mollie.com/en/payments/bank-transfer) reçus dans la zone SEPA via [Mollie](https://www.mollie.com/). Cela vous permet de recevoir des paiements de particuliers et d'entreprises dans plus de 35 pays européens. + +### PayPal +[PayPal](https://www.mollie.com/en/payments/paypal) est un mode de paiement très populaire qui est utilisé dans le monde entier. En quelques clics, vous pouvez recevoir des paiements par virement bancaire, carte de crédit ou solde PayPal. + +### Bitcoin +[Bitcoin](https://www.mollie.com/en/payments/bitcoin) est une forme de monnaie électronique. Le taux de change est déterminé au moment de la transaction, de sorte que le montant et le paiement sont garantis. + +### paysafecard +[paysafecard](https://www.mollie.com/en/payments/paysafecard) est la carte prépayée la plus populaire pour les paiements en ligne. Avec paysafecard, vous pouvez recevoir des paiements prépayés de 43 pays. + +### Bouton de paiement KBC / CBC +Le [bouton de paiement KBC / CBC](https://www.mollie.com/en/payments/kbc-cbc) est un mode de paiement en ligne pour les clients de KBC et CBC, la plus grande banque de Belgique. + +KBC se concentre sur la Flandre et CBC sur la Wallonie. + +### Bouton de paiement Belfius +[Belfius](https://www.mollie.com/en/payments/belfius) est l'une des plus grandes banques de Belgique. En introduisant le bouton de paiement Belfius, la banque met à la disposition de ses clients sa propre solution de paiement. + +### CartaSi +[CartaSi](https://www.mollie.com/en/payments/cartasi) est l'un des modes de paiement les plus utilisés en Italie. + +Il y a plus de 13 millions de cartes de crédit CartaSi en circulation. + +### Cartes Bancaires +[Cartes Bancaires](https://www.mollie.com/en/payments/cartes-bancaires) est la carte de crédit la plus utilisée en France, avec plus de 64 millions de cartes en circulation. + +Les cartes sont co-marquées avec Visa. + +### EPS +[EPS](https://www.mollie.com/fr/payments/eps). L'Electronic Payment Standard (EPS) est une méthode de paiement développé par diverses banques autrichiennes. + +Devenue très populaire auprès des consommateurs autrichiens, EPS est la référence en matière de virement bancaire en Autriche. + +### Giropay +[Giropay](https://www.mollie.com/fr/payments/giropay). Giropay est une méthode de paiement très populaire de virement bancaire en Allemagne. + +Utilisé par plus de 15000 à travers le pays, cela en fait un moyen de paiement fiable, réputé auprès des consommateurs allemands. + +### Klarna : Pay later +[Klarna : Pay later](https://www.mollie.com/fr/payments/klarna-pay-later). Klarna est une solution de paiement flexible, qui permet à vos clients des modes de paiement variés. + +Commencer à recevoir des paiements par Klarna Pay later ne prend que quelques minutes. + +### Klarna : Slice it +[Klarna : Slice it](https://www.mollie.com/fr/payments/klarna-slice-it). Klarna est une solution de paiement flexible, qui permet à vos clients des modes de paiement variés. + +Commencer à recevoir des paiements par Klarna Slice it ne prend que quelques minutes. + +# Foire aux questions # + +**Le module ne peut pas être installé dans PrestaShop 1.7.** + +* Allez à la racine de votre site web via FTP puis ouvrez le dossier 'modules'. +* Supprimer le dossier nommé 'mollie'. +* Réinstallez le module Mollie pour PrestaShop 1.7. + +**J'ai installé le module, mais le module n'apparaît pas pendant le check-out.** + +* Vérifier si le module est allumé et si la clé API correcte est réglée. Voir les instructions d'installation. +* Vérifiez si l'euro est défini comme devise dans votre magasin. Mollie ne soutient que les euros. +* Vérifier via "Advanced parameters" -> "Performance" si "Minimize HTML" est désactivé. + +**Dois-je également définir une URL de retour et / ou un webhook ?** + +Il n'est pas nécessaire de définir une URL de redirection ou un Webhook. Le module le fait automatiquement à chaque commande. + +**Après un paiement réussi, mes clients verront l'historique des commandes au lieu de la confirmation de commande.** + +C'est un bug dans PrestaShop qui a été corrigé à partir de la version 1.6.0.7. Pour résoudre ce problème, vous devez mettre à jour votre version de PrestaShop. Si vous ne voulez pas le faire, vous pouvez aussi corriger le bogue vous-même en ajustant une ligne de code. + +Le [numéro correspondant de github](https://github.com/mollie/Prestashop/issues/3) vous indique exactement comment le faire. + +**Le statut de la commande n'est pas mis à jour** + +Mollie envoie un message à votre site Web lorsque le statut du paiement change. Il est possible que Mollie ne puisse pas atteindre votre site Web ou que votre site Web ne puisse pas traiter le statut. + +* Vérifiez la [gestion de votre Mollie](https://www.mollie.com/beheer/) s'il y a des rapports échoués. +* Vérifiez si votre site Web fonctionne en 'maintenance mode'. Mollie ne peut pas accéder à votre site Web si votre site Web est en mode de maintenance si la version du module Mollie est inférieure à 2.0.0.0. +A partir de la version 2.0.0 et plus, le module Mollie fonctionne en mode maintenance. +* Il arrive parfois qu'il y ait un problème lors de la création de la facture. Vérifiez si l'option "Enable image for product" est désactivée dans "Orders" -> "Invoices" -> "Invoice options" (de PrestaShop 1.6.1.0) ou dans "Preferences" -> "Orders" -> "PDF settings"(dans PrestaShop 1.6.0.12 à 1.6.0.14). + +# Souhaitez-vous contribuer à l'amélioration de ce module ? # + +Aimeriez-vous aider à améliorer ce module pour PrestaShop ? Nous sommes toujours ouverts aux [demandes de retrait](https://github.com/mollie/Prestashop/pulls?utf8=%E2%9C%93&q=is%3Apr). + +Et que diriez-vous de travailler dans une [organisation axée sur la technologie](https://jobs.mollie.com/) ? Mollie est toujours à la recherche de développeurs et d'ingénieurs système. [Consultez nos offres d'emploi](https://jobs.mollie.com/) ou [contactez-nous](mailto:personeel@mollie.com). + +# Licence # +[Licence BSD (Berkeley Software Distribution)](http://www.opensource.org/licenses/bsd-license.php). +Copyright (c) 2013-2019, Mollie B.V. + +# Support # + +Avez-vous des problèmes avec l'installation ou pensez-vous que le module contient un bug ? Envoyer un email +à info@mollie.com avec une description précise du problème. diff --git a/README_NL.md b/README_NL.md index c2d142407..95ca38e70 100644 --- a/README_NL.md +++ b/README_NL.md @@ -1,178 +1,178 @@ -[Deutsch](README_DE.md) [Français](README_FR.md) [English](README.md) [Español](README_ES.md) - -![Mollie](https://www.mollie.com/files/Mollie-Logo-Style-Small.png) - -# PrestaShop betaalprovider [Mollie](https://www.mollie.com/). # - -Download de [Mollie](https://www.mollie.com/) module voor PrestaShop. Mollie is een betaalprovider (Payment Service Provider) die uw webshop van de meest populaire online betaalmethoden voorziet. - -Ontvang eenvoudig betalingen van klanten binnen heel Europa. Mollie biedt betaalmethoden tegen zeer scherpe tarieven. U betaalt alleen per transactie en geen verborgen kosten. - -Kies de beste betaalprovider voor uw PrestaShop webwinkel. Maak direct uw merchant account aan op [Mollie.com](https://www.mollie.com/). -Download en installeer de Mollie betaalmodule voor PrestaShop om direct online betalingen te ontvangen! - - - -## Verzorgd door [Invertus](https://www.invertus.eu). ## - -## Voor PrestaShop 1.5 tot en met 1.7 ## - -**Let op:** voor de installatie van deze module is FTP-toegang tot je webserver benodigd. Heb je hier geen ervaring mee? Laat de installatie van deze module dan over aan je websitebouwer of serverbeheerder. - -## Installatie Prestashop 1.7 ## - -* Download de laatste versie van de module via de [Releases-pagina](https://github.com/mollie/Prestashop/releases) welke geschikt is voor PrestaShop 1.5 tot en met 1.7. -* Ga naar het administratiepaneel van uw PrestaShop webwinkel -* In uw administratiepaneel selecteert u de tab 'Modules' en kiest vervolgens 'upload een module' rechts bovenin uw scherm -* Kies 'selecteer bestand' en upload vervolgens het bestand met de naam 'mollie.zip' dat u eerder heeft gedownload -* Nadat de module zich heeft geïnstalleerd kiest u 'configureer' -* Vul uw _API-key_ in en sla de gegevens vervolgens op. - -## Installatie PrestaShop 1.5 en 1.6 ## - -* Download de laatste versie van de module via de [Releases-pagina](https://github.com/mollie/Prestashop/releases) welke geschikt is voor PrestaShop 1.5 tot en met 1.6. -* Ga naar het administratiepaneel van uw PrestaShop webwinkel -* In uw administratiepaneel selecteert u de tab 'Modules' en kiest vervolgens 'upload een module' rechts bovenin uw scherm -* Kies 'selecteer bestand' en upload vervolgens het bestand met de naam 'mollie.zip' dat u eerder heeft gedownload -* Nadat de module zich heeft geïnstalleerd kiest u 'configureer' -* Vul uw _API-key_ in en sla de gegevens vervolgens op. - -## of ## - -* Download de laatste versie van de module via de [Releases-pagina](https://github.com/mollie/Prestashop/releases) welke geschikt is voor PrestaShop 1.5 tot en met 1.6. -* Pak het archief uit -* Kopieer de map `mollie` naar de map `modules` in uw PrestaShop installatie -* Ga in uw administratiepaneel naar de tab 'Modules' en kies in het lijstje 'Categories' voor 'Payments and Gateways' -* Klik op de 'install' knop rechts van de Mollie Payment Module -* Vul uw _API-key_ in en sla de gegevens vervolgens op. - -# Ondersteunde betaalmethodes - -### iDEAL -Met [iDEAL via Mollie](https://www.mollie.com/nl/payments/ideal) kunt u vertrouwd, veilig en gemakkelijk uw online aankopen afrekenen. iDEAL is het systeem dat u direct koppelt aan uw internetbankierprogramma bij een online aankoop. - -Via [Mollie](https://www.mollie.com/) is iDEAL gemakkelijk aan te sluiten zonder de gebruikelijke technische en administratieve rompslomp. Mollie geeft u op ieder moment toegang tot uw transactieoverzichten en andere statistieken. Tevens is het mogelijk per e-mail of SMS een notificatie te ontvangen bij elke gelukte betaling. - -[Mollie](https://www.mollie.com/) is hierdoor dus een perfecte partner op het gebied van iDEAL en is het dan ook niet verbazingwekkend dat [Mollie](https://www.mollie.com/) ondertussen op meer dan 40.000 websites iDEAL-betalingen mag verzorgen. - -### Creditcard -[Creditcard](https://www.mollie.com/nl/payments/credit-card) is vrijwel de bekendste methode voor het ontvangen van betalingen met wereldwijde dekking. - -Doordat we onder andere de bekende merken Mastercard, VISA en American Express ondersteunen, zorgt dit direct voor veel potentiële kopers. - -### Bancontact -[Bancontact](https://www.mollie.com/nl/payments/bancontact) maakt gebruik van een fysieke kaart die gekoppeld is aan tegoed op een Belgische bankrekening. - -Betalingen via Bancontact/Mister Cash zijn gegarandeerd en lijkt daarmee sterk op iDEAL in Nederland. Daarom is het uitermate geschikt voor uw webwinkel. - -### SOFORT Banking -[SOFORT Banking](https://www.mollie.com/nl/payments/sofort) is één van de populairste betaalmethodes in Duitsland en actief in 9 landen: - -Duitsland, België, Nederland, Italië, Oostenrijk, Polen, Zwitserland, Spanje en Groot-Brittannië. - -Betalingen zijn direct en niet storneerbaar, waarmee het sterk op het Nederlandse iDEAL lijkt. Daarom is het uitermate geschikt voor uw webwinkel. - -### ING Home’Pay -[ING Home’Pay](https://www.mollie.com/nl/payments/ing-homepay). Met Mollie accepteer je snel en eenvoudig betalingen via ING Home'Pay. - -Je bent online binnen 10 minuten en we rekenen nooit verborgen kosten, je betaalt alleen voor succesvolle transacties. - -### Overboekingen -[Overboekingen](https://www.mollie.com/nl/payments/bank-transfer) binnen de SEPA zone ontvangen via Mollie. Hiermee kun je betalingen ontvangen van zowel particulieren als zakelijke klanten in meer dan 35 Europese landen. - -### PayPal -[PayPal](https://www.mollie.com/nl/payments/paypal) is wereldwijd een zeer populaire betaalmethode. In enkele klikken kunt u betalingen ontvangen via een bankoverschrijving, creditcard of het PayPal-saldo. - -### Bitcoin -[Bitcoin](https://www.mollie.com/nl/payments/bitcoin) is een vorm van elektronisch geld. De bitcoin-euro wisselkoers wordt vastgesteld op het moment van de transactie waardoor het bedrag en de uitbetaling zijn gegarandeerd. - -### paysafecard -[paysafecard](https://www.mollie.com/nl/payments/paysafecard) is de populairste prepaidcard voor online betalingen. Met paysafecard kunt u vanuit 43 verschillende landen betalingen ontvangen. - -### KBC/CBC-Betaalknop -De [KBC/CBC-Betaalknop](https://www.mollie.com/nl/payments/kbc-cbc) is een online betaalmethode voor de klanten van de KBC en CBC, samen de grootste bank van België. - -KBC richt zich op Vlaanderen en CBC op Wallonië. - -### Belfius Pay Button -[Belfius](https://www.mollie.com/nl/payments/belfius) is een van de grootste banken van België. Met de Belfius Pay Button voorziet de bank haar klanten van een eigen betaaloplossing. - -### CartaSi -[CartaSi](https://www.mollie.com/nl/payments/cartasi) is een van de meest gebruikte betaalmethoden in Italië. Er zijn ruim 13 miljoen CartaSi-creditcards in circulatie en het is een van de meest gebruikte betaalmethoden in Italië. - -### Cartes Bancaires -[Cartes Bancaires](https://www.mollie.com/nl/payments/cartes-bancaires) zijn de meest gebruikte creditcards in Frankrijk, met meer dan 64 miljoen kaarten in circulatie. - -De kaarten zijn co-branded met Visa. - -### EPS -[EPS](https://www.mollie.com/nl/payments/eps). De Electronic Payment Standard (EPS) is een betaalmethode die door een aantal Oostenrijkse banken is ontwikkeld. - -Dit maakt EPS de belangrijkste betaalmethode voor bankoverboekingen in Oostenrijk en zeer populair bij Oostenrijkse klanten. - -### Giropay -[Giropay](https://www.mollie.com/nl/payments/giropay). Giropay is een populaire bankoverboeking betaalmethode in Duitsland. - -Het maakt gebruik van meer dan 1.500 Duitse banken, waardoor het een vertrouwde betaalmethode is onder Duitse klanten. - -### Klarna: Achteraf betalen -[Klarna: Achteraf betalen](https://www.mollie.com/nl/payments/klarna-pay-later). Klarna is een flexibele betaaloplossing, waarmee je je klanten diverse mogelijkheden voor uitgestelde betaling biedt. - -Met Mollie integreer je Klarna: Achteraf betalen binnen een handomdraai. - -### Klarna: Gespreid betalen -[Klarna: Gespreid betalen](https://www.mollie.com/nl/payments/klarna-slice-it). Klarna is een flexibele betaaloplossing, waarmee je je klanten diverse mogelijkheden voor uitgestelde betaling biedt. - -Met Mollie integreer je Klarna: Gespreid betalen binnen een handomdraai. - -# Veel gestelde vragen # - -**De module kan niet geïnstalleerd worden in PrestaShop 1.7.** - -* Ga via de FTP naar de hoofdmap van uw website en open vervolgens de map 'modules'. -* Verwijder de map met de naam 'mollie'. -* Doorloop wederom het installatieproces voor PrestaShop 1.7. - -**Ik heb alles ingesteld, maar de module verschijnt niet bij het afrekenen.** - -* Controleer of de module staat ingeschakeld en of er een juiste API key staat ingesteld. Zie de installatie-instructies. -* Controleer of euro's als valuta staat ingesteld in uw winkel. Mollie ondersteunt alleen euro's. -* Controleer via "Geavanceerde parameters" -> "Prestatie" of "HTML minimaliseren" staat uigeschakeld. - -**Moet ik ook een return- en / of webhook-URL instellen?** - -Het is niet nodig een redirect URL of webhook in te stellen. Dat doet de module zelf automatisch bij elke order. - -**Na een succesvolle betaling krijgen mijn klanten de order history te zien in plaats van de order confirmation. Hoe los ik dat op?** - -Dit is in feite een bug in PrestaShop die is gefixt vanaf versie 1.6.0.7. Om dit op te lossen zou u PrestaShop moeten updaten. Als u dat niet wilt of kunt zou u ook middels aanpassing van één regel code de bug zelf kunnen fixen. In het relevante [github issue](https://github.com/mollie/Prestashop/issues/3) staat precies hoe u dit moet doen. - -**De status van mijn bestelling wordt niet bijgewerkt** - -Mollie stuurt een bericht aan je website wanneer de status van de betaling veranderd. Het kan zijn dat Mollie je website niet kon bereiken of dat je website de status niet heeft kunnen verwerken. - -* Controleer in je [Mollie beheer](https://www.mollie.com/beheer/) of er gefaalde rapportages zijn. -* Controleer of je website in 'maintenance mode' draait. Mollie kan je website niet bereiken als je website in onderhoudsmodus draait. Vanaf versie 2.0.0 werkt de Mollie module wél in de onderhoudsmodus. -* Soms gaat er iets fout bij het aanmaken van de factuur. Controleer of de optie "Afbeelding voor het product inschakelen" uit staat in "Bestellingen" -> "Facturen" -> "Factuur opties" (vanaf PrestaShop 1.6.1.0) of in "Voorkeuren" -> "Bestellingen" -> "PDF instellingen" (in PrestaShop 1.6.0.12 tot 1.6.0.14). - -# Wil je meewerken aan deze module? # - -Wil je helpen om onze plugin voor PrestaShop nog beter te maken? Wij staan open voor [pull requests](https://github.com/mollie/Prestashop/pulls?utf8=%E2%9C%93&q=is%3Apr) voor onze module. - -Maar wat denk je er over om bij een [technology driven organisatie](https://jobs.mollie.com/) aan de slag te gaan? Mollie is altijd op zoek naar developers en system engineers. [Check onze vacatures](https://jobs.mollie.com/) of [neem contact met ons op](mailto:personeel@mollie.com). - -# Licentie # -[BSD (Berkeley Software Distribution) License](http://www.opensource.org/licenses/bsd-license.php). -Copyright (c) 2013-2019, Mollie B.V. - -# Ondersteuning # - -Heeft u problemen met de installatie of bevat de module volgens u een bug? Stuurt u dan een email -naar info@mollie.com met een zo precies mogelijke omschrijving van het probleem. +[Deutsch](README_DE.md) [Français](README_FR.md) [English](README.md) [Español](README_ES.md) + +![Mollie](https://www.mollie.com/files/Mollie-Logo-Style-Small.png) + +# PrestaShop betaalprovider [Mollie](https://www.mollie.com/). # + +Download de [Mollie](https://www.mollie.com/) module voor PrestaShop. Mollie is een betaalprovider (Payment Service Provider) die uw webshop van de meest populaire online betaalmethoden voorziet. + +Ontvang eenvoudig betalingen van klanten binnen heel Europa. Mollie biedt betaalmethoden tegen zeer scherpe tarieven. U betaalt alleen per transactie en geen verborgen kosten. + +Kies de beste betaalprovider voor uw PrestaShop webwinkel. Maak direct uw merchant account aan op [Mollie.com](https://www.mollie.com/). +Download en installeer de Mollie betaalmodule voor PrestaShop om direct online betalingen te ontvangen! + + + +## Verzorgd door [Invertus](https://www.invertus.eu). ## + +## Voor PrestaShop 1.5 tot en met 1.7 ## + +**Let op:** voor de installatie van deze module is FTP-toegang tot je webserver benodigd. Heb je hier geen ervaring mee? Laat de installatie van deze module dan over aan je websitebouwer of serverbeheerder. + +## Installatie Prestashop 1.7 ## + +* Download de laatste versie van de module via de [Releases-pagina](https://github.com/mollie/Prestashop/releases) welke geschikt is voor PrestaShop 1.5 tot en met 1.7. +* Ga naar het administratiepaneel van uw PrestaShop webwinkel +* In uw administratiepaneel selecteert u de tab 'Modules' en kiest vervolgens 'upload een module' rechts bovenin uw scherm +* Kies 'selecteer bestand' en upload vervolgens het bestand met de naam 'mollie.zip' dat u eerder heeft gedownload +* Nadat de module zich heeft geïnstalleerd kiest u 'configureer' +* Vul uw _API-key_ in en sla de gegevens vervolgens op. + +## Installatie PrestaShop 1.5 en 1.6 ## + +* Download de laatste versie van de module via de [Releases-pagina](https://github.com/mollie/Prestashop/releases) welke geschikt is voor PrestaShop 1.5 tot en met 1.6. +* Ga naar het administratiepaneel van uw PrestaShop webwinkel +* In uw administratiepaneel selecteert u de tab 'Modules' en kiest vervolgens 'upload een module' rechts bovenin uw scherm +* Kies 'selecteer bestand' en upload vervolgens het bestand met de naam 'mollie.zip' dat u eerder heeft gedownload +* Nadat de module zich heeft geïnstalleerd kiest u 'configureer' +* Vul uw _API-key_ in en sla de gegevens vervolgens op. + +## of ## + +* Download de laatste versie van de module via de [Releases-pagina](https://github.com/mollie/Prestashop/releases) welke geschikt is voor PrestaShop 1.5 tot en met 1.6. +* Pak het archief uit +* Kopieer de map `mollie` naar de map `modules` in uw PrestaShop installatie +* Ga in uw administratiepaneel naar de tab 'Modules' en kies in het lijstje 'Categories' voor 'Payments and Gateways' +* Klik op de 'install' knop rechts van de Mollie Payment Module +* Vul uw _API-key_ in en sla de gegevens vervolgens op. + +# Ondersteunde betaalmethodes + +### iDEAL +Met [iDEAL via Mollie](https://www.mollie.com/nl/payments/ideal) kunt u vertrouwd, veilig en gemakkelijk uw online aankopen afrekenen. iDEAL is het systeem dat u direct koppelt aan uw internetbankierprogramma bij een online aankoop. + +Via [Mollie](https://www.mollie.com/) is iDEAL gemakkelijk aan te sluiten zonder de gebruikelijke technische en administratieve rompslomp. Mollie geeft u op ieder moment toegang tot uw transactieoverzichten en andere statistieken. Tevens is het mogelijk per e-mail of SMS een notificatie te ontvangen bij elke gelukte betaling. + +[Mollie](https://www.mollie.com/) is hierdoor dus een perfecte partner op het gebied van iDEAL en is het dan ook niet verbazingwekkend dat [Mollie](https://www.mollie.com/) ondertussen op meer dan 40.000 websites iDEAL-betalingen mag verzorgen. + +### Creditcard +[Creditcard](https://www.mollie.com/nl/payments/credit-card) is vrijwel de bekendste methode voor het ontvangen van betalingen met wereldwijde dekking. + +Doordat we onder andere de bekende merken Mastercard, VISA en American Express ondersteunen, zorgt dit direct voor veel potentiële kopers. + +### Bancontact +[Bancontact](https://www.mollie.com/nl/payments/bancontact) maakt gebruik van een fysieke kaart die gekoppeld is aan tegoed op een Belgische bankrekening. + +Betalingen via Bancontact/Mister Cash zijn gegarandeerd en lijkt daarmee sterk op iDEAL in Nederland. Daarom is het uitermate geschikt voor uw webwinkel. + +### SOFORT Banking +[SOFORT Banking](https://www.mollie.com/nl/payments/sofort) is één van de populairste betaalmethodes in Duitsland en actief in 9 landen: + +Duitsland, België, Nederland, Italië, Oostenrijk, Polen, Zwitserland, Spanje en Groot-Brittannië. + +Betalingen zijn direct en niet storneerbaar, waarmee het sterk op het Nederlandse iDEAL lijkt. Daarom is het uitermate geschikt voor uw webwinkel. + +### ING Home’Pay +[ING Home’Pay](https://www.mollie.com/nl/payments/ing-homepay). Met Mollie accepteer je snel en eenvoudig betalingen via ING Home'Pay. + +Je bent online binnen 10 minuten en we rekenen nooit verborgen kosten, je betaalt alleen voor succesvolle transacties. + +### Overboekingen +[Overboekingen](https://www.mollie.com/nl/payments/bank-transfer) binnen de SEPA zone ontvangen via Mollie. Hiermee kun je betalingen ontvangen van zowel particulieren als zakelijke klanten in meer dan 35 Europese landen. + +### PayPal +[PayPal](https://www.mollie.com/nl/payments/paypal) is wereldwijd een zeer populaire betaalmethode. In enkele klikken kunt u betalingen ontvangen via een bankoverschrijving, creditcard of het PayPal-saldo. + +### Bitcoin +[Bitcoin](https://www.mollie.com/nl/payments/bitcoin) is een vorm van elektronisch geld. De bitcoin-euro wisselkoers wordt vastgesteld op het moment van de transactie waardoor het bedrag en de uitbetaling zijn gegarandeerd. + +### paysafecard +[paysafecard](https://www.mollie.com/nl/payments/paysafecard) is de populairste prepaidcard voor online betalingen. Met paysafecard kunt u vanuit 43 verschillende landen betalingen ontvangen. + +### KBC/CBC-Betaalknop +De [KBC/CBC-Betaalknop](https://www.mollie.com/nl/payments/kbc-cbc) is een online betaalmethode voor de klanten van de KBC en CBC, samen de grootste bank van België. + +KBC richt zich op Vlaanderen en CBC op Wallonië. + +### Belfius Pay Button +[Belfius](https://www.mollie.com/nl/payments/belfius) is een van de grootste banken van België. Met de Belfius Pay Button voorziet de bank haar klanten van een eigen betaaloplossing. + +### CartaSi +[CartaSi](https://www.mollie.com/nl/payments/cartasi) is een van de meest gebruikte betaalmethoden in Italië. Er zijn ruim 13 miljoen CartaSi-creditcards in circulatie en het is een van de meest gebruikte betaalmethoden in Italië. + +### Cartes Bancaires +[Cartes Bancaires](https://www.mollie.com/nl/payments/cartes-bancaires) zijn de meest gebruikte creditcards in Frankrijk, met meer dan 64 miljoen kaarten in circulatie. + +De kaarten zijn co-branded met Visa. + +### EPS +[EPS](https://www.mollie.com/nl/payments/eps). De Electronic Payment Standard (EPS) is een betaalmethode die door een aantal Oostenrijkse banken is ontwikkeld. + +Dit maakt EPS de belangrijkste betaalmethode voor bankoverboekingen in Oostenrijk en zeer populair bij Oostenrijkse klanten. + +### Giropay +[Giropay](https://www.mollie.com/nl/payments/giropay). Giropay is een populaire bankoverboeking betaalmethode in Duitsland. + +Het maakt gebruik van meer dan 1.500 Duitse banken, waardoor het een vertrouwde betaalmethode is onder Duitse klanten. + +### Klarna: Achteraf betalen +[Klarna: Achteraf betalen](https://www.mollie.com/nl/payments/klarna-pay-later). Klarna is een flexibele betaaloplossing, waarmee je je klanten diverse mogelijkheden voor uitgestelde betaling biedt. + +Met Mollie integreer je Klarna: Achteraf betalen binnen een handomdraai. + +### Klarna: Gespreid betalen +[Klarna: Gespreid betalen](https://www.mollie.com/nl/payments/klarna-slice-it). Klarna is een flexibele betaaloplossing, waarmee je je klanten diverse mogelijkheden voor uitgestelde betaling biedt. + +Met Mollie integreer je Klarna: Gespreid betalen binnen een handomdraai. + +# Veel gestelde vragen # + +**De module kan niet geïnstalleerd worden in PrestaShop 1.7.** + +* Ga via de FTP naar de hoofdmap van uw website en open vervolgens de map 'modules'. +* Verwijder de map met de naam 'mollie'. +* Doorloop wederom het installatieproces voor PrestaShop 1.7. + +**Ik heb alles ingesteld, maar de module verschijnt niet bij het afrekenen.** + +* Controleer of de module staat ingeschakeld en of er een juiste API key staat ingesteld. Zie de installatie-instructies. +* Controleer of euro's als valuta staat ingesteld in uw winkel. Mollie ondersteunt alleen euro's. +* Controleer via "Geavanceerde parameters" -> "Prestatie" of "HTML minimaliseren" staat uigeschakeld. + +**Moet ik ook een return- en / of webhook-URL instellen?** + +Het is niet nodig een redirect URL of webhook in te stellen. Dat doet de module zelf automatisch bij elke order. + +**Na een succesvolle betaling krijgen mijn klanten de order history te zien in plaats van de order confirmation. Hoe los ik dat op?** + +Dit is in feite een bug in PrestaShop die is gefixt vanaf versie 1.6.0.7. Om dit op te lossen zou u PrestaShop moeten updaten. Als u dat niet wilt of kunt zou u ook middels aanpassing van één regel code de bug zelf kunnen fixen. In het relevante [github issue](https://github.com/mollie/Prestashop/issues/3) staat precies hoe u dit moet doen. + +**De status van mijn bestelling wordt niet bijgewerkt** + +Mollie stuurt een bericht aan je website wanneer de status van de betaling veranderd. Het kan zijn dat Mollie je website niet kon bereiken of dat je website de status niet heeft kunnen verwerken. + +* Controleer in je [Mollie beheer](https://www.mollie.com/beheer/) of er gefaalde rapportages zijn. +* Controleer of je website in 'maintenance mode' draait. Mollie kan je website niet bereiken als je website in onderhoudsmodus draait. Vanaf versie 2.0.0 werkt de Mollie module wél in de onderhoudsmodus. +* Soms gaat er iets fout bij het aanmaken van de factuur. Controleer of de optie "Afbeelding voor het product inschakelen" uit staat in "Bestellingen" -> "Facturen" -> "Factuur opties" (vanaf PrestaShop 1.6.1.0) of in "Voorkeuren" -> "Bestellingen" -> "PDF instellingen" (in PrestaShop 1.6.0.12 tot 1.6.0.14). + +# Wil je meewerken aan deze module? # + +Wil je helpen om onze plugin voor PrestaShop nog beter te maken? Wij staan open voor [pull requests](https://github.com/mollie/Prestashop/pulls?utf8=%E2%9C%93&q=is%3Apr) voor onze module. + +Maar wat denk je er over om bij een [technology driven organisatie](https://jobs.mollie.com/) aan de slag te gaan? Mollie is altijd op zoek naar developers en system engineers. [Check onze vacatures](https://jobs.mollie.com/) of [neem contact met ons op](mailto:personeel@mollie.com). + +# Licentie # +[BSD (Berkeley Software Distribution) License](http://www.opensource.org/licenses/bsd-license.php). +Copyright (c) 2013-2019, Mollie B.V. + +# Ondersteuning # + +Heeft u problemen met de installatie of bevat de module volgens u een bug? Stuurt u dan een email +naar info@mollie.com met een zo precies mogelijke omschrijving van het probleem. diff --git a/changelog.md b/changelog.md index 0aac3c7bb..dc4c75273 100644 --- a/changelog.md +++ b/changelog.md @@ -1,82 +1,82 @@ -![Mollie](https://www.mollie.nl/files/Mollie-Logo-Style-Small.png) - -# Changelog # - -## Changes in release 2.0.0 ## -+ Compatibility with Prestashop 1.7+ -+ Fix for "Frontcontroller::init - cart cannot be loaded". -+ Fix for recieving payment multiple times. -+ Added option to send customer order to Mollie metadata -+ Mollie now works in maintenance mode. -+ Improved configuration page. -+ Improved User Experience. - -## Changes in release 1.3.0 ## -+ Automatically pass along the customer's email address for banktransfer payment instructions, when available. - -## Changes in release 1.2.6 ## -+ Fixed incorrect install/de-install hooks. -+ Update submodule [mollie-api-php](https://github.com/mollie/mollie-api-php) to `v1.5.1` - -## Changes in release 1.2.5 ## -+ Added some new translations. -+ EU Compliance module has been added. -+ Update submodule mollie-api-php to version 1.4.0. - -## Changes in release 1.2.4 ## -+ Added payment description filters ({cart.id} {customer.firstname} {customer.lastname} {customer.company}) -+ Update submodule mollie-api-php to version 1.3.3 - -## Changes in release 1.2.3 ## -+ Set default language for admin when no language set -+ Update submodule mollie-api-php to version 1.3.1 - -## Changes in release 1.2.2 ## -+ Fixed issue where banktransfer status didn't get updated correctly -+ Update submodule mollie-api-php to version 1.2.8 - -## Changes in release 1.2.1 ## -+ Fixed an issue where the country context is not set when Mollie calls the PrestaShop webhook. -+ Fixed an issue where the iDEAL issuers are not displayed correctly when using module OnePageCheckout. -+ Update submodule mollie-api-php to version 1.2.7 - -## Changes in release 1.2.0 ## -+ Add option to send webshop locale to Mollie to use in payment screens. This will use the -current language and country locale (In admin: Localization -> Advanced) - -## Changes in release 1.1.0 ## -+ Add English and German translations -+ Save Mollie payment id (tr_xxxx) in order payment -+ Update Mollie API client to version 1.2.5, contains system compatibility checker - -## Changes in release 1.0.8 ## -+ Create the order before the payment is finished when payment method is banktransfer. - -## Changes in release 1.0.7 ## -+ Stop Google Analytics from listing payment provider as referrer. - -## Changes in release 1.0.6 ## -+ Fixed redirect issue for cancelled payments. - -## Changes in release 1.0.5 ## -+ Fixed currency issue on return page. - -## Changes in release 1.0.4 ## -+ Added cart ID to payment descriptions. -+ Fixed missing keys warning. - -## Changes in release 1.0.3 ## -+ Fixed error in payment method selection. -+ Prevent customers from returning to an empty cart after cancelling a payment. -+ Fixed issues with Google Analytics by using Prestashop's default return page. - -## Changes in release 1.0.2 ## -+ Added 'open' order status. -+ Fixed bug where order updated twice. -+ Fixed iDEAL bank list not showing. - -## Changes in release 1.0.1 ## -+ Fixed issue with custom statuses for open payments. - -## Changes in release 1.0.0 ## -+ Initial release. +![Mollie](https://www.mollie.nl/files/Mollie-Logo-Style-Small.png) + +# Changelog # + +## Changes in release 2.0.0 ## ++ Compatibility with Prestashop 1.7+ ++ Fix for "Frontcontroller::init - cart cannot be loaded". ++ Fix for recieving payment multiple times. ++ Added option to send customer order to Mollie metadata ++ Mollie now works in maintenance mode. ++ Improved configuration page. ++ Improved User Experience. + +## Changes in release 1.3.0 ## ++ Automatically pass along the customer's email address for banktransfer payment instructions, when available. + +## Changes in release 1.2.6 ## ++ Fixed incorrect install/de-install hooks. ++ Update submodule [mollie-api-php](https://github.com/mollie/mollie-api-php) to `v1.5.1` + +## Changes in release 1.2.5 ## ++ Added some new translations. ++ EU Compliance module has been added. ++ Update submodule mollie-api-php to version 1.4.0. + +## Changes in release 1.2.4 ## ++ Added payment description filters ({cart.id} {customer.firstname} {customer.lastname} {customer.company}) ++ Update submodule mollie-api-php to version 1.3.3 + +## Changes in release 1.2.3 ## ++ Set default language for admin when no language set ++ Update submodule mollie-api-php to version 1.3.1 + +## Changes in release 1.2.2 ## ++ Fixed issue where banktransfer status didn't get updated correctly ++ Update submodule mollie-api-php to version 1.2.8 + +## Changes in release 1.2.1 ## ++ Fixed an issue where the country context is not set when Mollie calls the PrestaShop webhook. ++ Fixed an issue where the iDEAL issuers are not displayed correctly when using module OnePageCheckout. ++ Update submodule mollie-api-php to version 1.2.7 + +## Changes in release 1.2.0 ## ++ Add option to send webshop locale to Mollie to use in payment screens. This will use the +current language and country locale (In admin: Localization -> Advanced) + +## Changes in release 1.1.0 ## ++ Add English and German translations ++ Save Mollie payment id (tr_xxxx) in order payment ++ Update Mollie API client to version 1.2.5, contains system compatibility checker + +## Changes in release 1.0.8 ## ++ Create the order before the payment is finished when payment method is banktransfer. + +## Changes in release 1.0.7 ## ++ Stop Google Analytics from listing payment provider as referrer. + +## Changes in release 1.0.6 ## ++ Fixed redirect issue for cancelled payments. + +## Changes in release 1.0.5 ## ++ Fixed currency issue on return page. + +## Changes in release 1.0.4 ## ++ Added cart ID to payment descriptions. ++ Fixed missing keys warning. + +## Changes in release 1.0.3 ## ++ Fixed error in payment method selection. ++ Prevent customers from returning to an empty cart after cancelling a payment. ++ Fixed issues with Google Analytics by using Prestashop's default return page. + +## Changes in release 1.0.2 ## ++ Added 'open' order status. ++ Fixed bug where order updated twice. ++ Fixed iDEAL bank list not showing. + +## Changes in release 1.0.1 ## ++ Fixed issue with custom statuses for open payments. + +## Changes in release 1.0.0 ## ++ Initial release. diff --git a/codeception.yml b/codeception.yml index 5823c8f8f..2f62db5bb 100644 --- a/codeception.yml +++ b/codeception.yml @@ -1,16 +1,16 @@ -paths: - tests: tests - output: tests/_output - data: tests/_data - support: tests/_support - envs: tests/_envs -actor_suffix: Tester -settings: - bootstrap: _bootstrap.php - colors: true - memory_limit: 1024M -params: - - env -extensions: - enabled: - - Codeception\Extension\RunFailed +paths: + tests: tests + output: tests/_output + data: tests/_data + support: tests/_support + envs: tests/_envs +actor_suffix: Tester +settings: + bootstrap: _bootstrap.php + colors: true + memory_limit: 1024M +params: + - env +extensions: + enabled: + - Codeception\Extension\RunFailed diff --git a/config.xml b/config.xml index 6f1b26c83..af188e620 100644 --- a/config.xml +++ b/config.xml @@ -1,12 +1,12 @@ - - - mollie - - - - - - 1 - 1 - + + + mollie + + + + + + 1 + 1 + \ No newline at end of file diff --git a/config/config.yml b/config/config.yml index 2d2bf9290..df1c36bbc 100644 --- a/config/config.yml +++ b/config/config.yml @@ -1,20 +1,20 @@ -imports: - - { resource: builder.yml } - - { resource: service.yml } - - { resource: repository.yml } - - { resource: context.yml } - -services: - mollie: - class: 'Mollie' - factory: ['Module', 'getInstanceByName'] - arguments: - - 'mollie' - - Mollie\Install\Installer: - arguments: - - '@mollie' - - Mollie\Install\Uninstall: - arguments: +imports: + - { resource: builder.yml } + - { resource: service.yml } + - { resource: repository.yml } + - { resource: context.yml } + +services: + mollie: + class: 'Mollie' + factory: ['Module', 'getInstanceByName'] + arguments: + - 'mollie' + + Mollie\Install\Installer: + arguments: + - '@mollie' + + Mollie\Install\Uninstall: + arguments: - '@mollie' \ No newline at end of file diff --git a/config/index.php b/config/index.php index 97775fe0f..d4a3735f7 100644 --- a/config/index.php +++ b/config/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/controllers/front/ajax.php b/controllers/front/ajax.php index 89b3035c2..4e7d8cd4e 100644 --- a/controllers/front/ajax.php +++ b/controllers/front/ajax.php @@ -1,131 +1,131 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -use PrestaShop\Decimal\Number; - -class MollieAjaxModuleFrontController extends ModuleFrontController -{ - - public function postProcess() - { - $action = Tools::getValue('action'); - switch ($action) { - case 'getTotalCartPrice': - $cart = Context::getContext()->cart; - $paymentFee = Tools::getValue('paymentFee'); - if (!$paymentFee) { - $presentedCart = $this->cart_presenter->present($this->context->cart); - $this->context->smarty->assign([ - 'configuration' => $this->getTemplateVarConfiguration(), - 'cart' => $presentedCart, - 'display_transaction_updated_info' => Tools::getIsset('updatedTransaction'), - ]); - - $this->ajaxDie( - json_encode( - [ - 'cart_summary_totals' => $this->render('checkout/_partials/cart-summary-totals'), - ] - ) - ); - } - - $paymentFee = new Number(Tools::getValue('paymentFee')); - $orderTotal = new Number((string)$cart->getOrderTotal()); - $orderTotalWithFee = $orderTotal->plus($paymentFee); - - $orderTotalNoTax = new Number((string)$cart->getOrderTotal(false)); - $orderTotalNoTaxWithFee = $orderTotalNoTax->plus($paymentFee); - - $total_including_tax = $orderTotalWithFee->toPrecision(2); - $total_excluding_tax = $orderTotalNoTaxWithFee->toPrecision(2); - - $taxConfiguration = new TaxConfiguration(); - $presentedCart = $this->cart_presenter->present($this->context->cart); - - $presentedCart['totals'] = array( - 'total' => array( - 'type' => 'total', - 'label' => $this->translator->trans('Total', array(), 'Shop.Theme.Checkout'), - 'amount' => $taxConfiguration->includeTaxes() ? $total_including_tax : $total_excluding_tax, - 'value' => Tools::displayPrice( - $taxConfiguration->includeTaxes() ? $total_including_tax : $total_excluding_tax - ), - ), - 'total_including_tax' => array( - 'type' => 'total', - 'label' => $this->translator->trans('Total (tax incl.)', array(), 'Shop.Theme.Checkout'), - 'amount' => $total_including_tax, - 'value' => Tools::displayPrice($total_including_tax), - ), - 'total_excluding_tax' => array( - 'type' => 'total', - 'label' => $this->translator->trans('Total (tax excl.)', array(), 'Shop.Theme.Checkout'), - 'amount' => $total_excluding_tax, - 'value' => Tools::displayPrice($total_excluding_tax), - ), - ); - - $this->context->smarty->assign([ - 'configuration' => $this->getTemplateVarConfiguration(), - 'cart' => $presentedCart, - 'display_transaction_updated_info' => Tools::getIsset('updatedTransaction'), - ]); - - $this->ajaxDie( - json_encode( - [ - 'cart_summary_totals' => $this->render('checkout/_partials/cart-summary-totals'), - ] - ) - ); - break; - case 'displayCheckoutError': - $errorMessages = explode('#', Tools::getValue('hashTag')); - foreach ($errorMessages as $errorMessage) { - if (strpos($errorMessage, 'mollieMessage=') === 0) { - $errorMessage = str_replace('mollieMessage=', '', $errorMessage); - $errorMessage = str_replace('_', ' ', $errorMessage); - $this->context->smarty->assign([ - 'errorMessage' => $errorMessage - ]); - $this->ajaxDie($this->context->smarty->fetch("{$this->module->getLocalPath()}views/templates/front/mollie_error.tpl")); - } - } - $this->ajaxDie(); - } - - } -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +use PrestaShop\Decimal\Number; + +class MollieAjaxModuleFrontController extends ModuleFrontController +{ + + public function postProcess() + { + $action = Tools::getValue('action'); + switch ($action) { + case 'getTotalCartPrice': + $cart = Context::getContext()->cart; + $paymentFee = Tools::getValue('paymentFee'); + if (!$paymentFee) { + $presentedCart = $this->cart_presenter->present($this->context->cart); + $this->context->smarty->assign([ + 'configuration' => $this->getTemplateVarConfiguration(), + 'cart' => $presentedCart, + 'display_transaction_updated_info' => Tools::getIsset('updatedTransaction'), + ]); + + $this->ajaxDie( + json_encode( + [ + 'cart_summary_totals' => $this->render('checkout/_partials/cart-summary-totals'), + ] + ) + ); + } + + $paymentFee = new Number(Tools::getValue('paymentFee')); + $orderTotal = new Number((string)$cart->getOrderTotal()); + $orderTotalWithFee = $orderTotal->plus($paymentFee); + + $orderTotalNoTax = new Number((string)$cart->getOrderTotal(false)); + $orderTotalNoTaxWithFee = $orderTotalNoTax->plus($paymentFee); + + $total_including_tax = $orderTotalWithFee->toPrecision(2); + $total_excluding_tax = $orderTotalNoTaxWithFee->toPrecision(2); + + $taxConfiguration = new TaxConfiguration(); + $presentedCart = $this->cart_presenter->present($this->context->cart); + + $presentedCart['totals'] = array( + 'total' => array( + 'type' => 'total', + 'label' => $this->translator->trans('Total', array(), 'Shop.Theme.Checkout'), + 'amount' => $taxConfiguration->includeTaxes() ? $total_including_tax : $total_excluding_tax, + 'value' => Tools::displayPrice( + $taxConfiguration->includeTaxes() ? $total_including_tax : $total_excluding_tax + ), + ), + 'total_including_tax' => array( + 'type' => 'total', + 'label' => $this->translator->trans('Total (tax incl.)', array(), 'Shop.Theme.Checkout'), + 'amount' => $total_including_tax, + 'value' => Tools::displayPrice($total_including_tax), + ), + 'total_excluding_tax' => array( + 'type' => 'total', + 'label' => $this->translator->trans('Total (tax excl.)', array(), 'Shop.Theme.Checkout'), + 'amount' => $total_excluding_tax, + 'value' => Tools::displayPrice($total_excluding_tax), + ), + ); + + $this->context->smarty->assign([ + 'configuration' => $this->getTemplateVarConfiguration(), + 'cart' => $presentedCart, + 'display_transaction_updated_info' => Tools::getIsset('updatedTransaction'), + ]); + + $this->ajaxDie( + json_encode( + [ + 'cart_summary_totals' => $this->render('checkout/_partials/cart-summary-totals'), + ] + ) + ); + break; + case 'displayCheckoutError': + $errorMessages = explode('#', Tools::getValue('hashTag')); + foreach ($errorMessages as $errorMessage) { + if (strpos($errorMessage, 'mollieMessage=') === 0) { + $errorMessage = str_replace('mollieMessage=', '', $errorMessage); + $errorMessage = str_replace('_', ' ', $errorMessage); + $this->context->smarty->assign([ + 'errorMessage' => $errorMessage + ]); + $this->ajaxDie($this->context->smarty->fetch("{$this->module->getLocalPath()}views/templates/front/mollie_error.tpl")); + } + } + $this->ajaxDie(); + } + + } +} diff --git a/controllers/front/fail.php b/controllers/front/fail.php index a3ff81075..f3a5ce4cb 100644 --- a/controllers/front/fail.php +++ b/controllers/front/fail.php @@ -1,143 +1,143 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -use Mollie\Config\Config; -use PrestaShop\PrestaShop\Adapter\Order\OrderPresenter; - -class MollieFailModuleFrontController extends ModuleFrontController -{ - - /** - * ID Order Variable Declaration. - * - * @var - */ - private $id_order; - - /** - * Security Key Variable Declaration. - * - * @var - */ - private $secure_key; - - /** - * ID Cart Variable Declaration. - * - * @var - */ - private $id_cart; - - /** - * Order Presenter Variable Declaration. - * - * @var - */ - private $order_presenter; - - public function init() - { - if (!Config::isVersion17()) { - return parent::init(); - } - parent::init(); - - $this->id_cart = (int) Tools::getValue('cartId', 0); - - $redirectLink = 'index.php?controller=history'; - - $this->id_order = Order::getOrderByCartId((int) $this->id_cart); - $this->secure_key = Tools::getValue('secureKey'); - $order = new Order((int) $this->id_order); - - if (!$this->id_order || !$this->module->id || !$this->secure_key || empty($this->secure_key)) { - Tools::redirect($redirectLink . (Tools::isSubmit('slowvalidation') ? '&slowvalidation' : '')); - } - - if ((string) $this->secure_key !== (string) $order->secure_key || - (int) $order->id_customer !== (int) $this->context->customer->id || - !Validate::isLoadedObject($order) - ) { - Tools::redirect($redirectLink); - } - - if ($order->module !== $this->module->name) { - Tools::redirect($redirectLink); - } - $this->order_presenter = new OrderPresenter(); - } - - public function initContent() - { - parent::initContent(); - - $cartId = Tools::getValue('cartId'); - $moduleId = Tools::getValue('moduleId'); - $orderId = Tools::getValue('orderId'); - $secureKey = Tools::getValue('secureKey'); - - $orderLink = $this->context->link->getPageLink( - 'order-confirmation', - true, - null, - [ - 'id_cart' => $cartId, - 'id_module' => $moduleId, - 'id_order' => $orderId, - 'key' => $secureKey, - 'cancel' => 1, - ] - ); - if (!Config::isVersion17()) { - Tools::redirect($orderLink); - } - - $order = new Order($this->id_order); - if ((bool) version_compare(_PS_VERSION_, '1.7', '>=')) { - $this->context->smarty->assign([ - 'order' => $this->order_presenter->present($order), - ]); - } else { - $this->context->smarty->assign([ - 'id_order' => $this->id_order, - 'email' => $this->context->customer->email, - ]); - } - - $this->setTemplate( - sprintf('module:%s/views/templates/front/order_fail.tpl', $this->module->name) - ); - } -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +use Mollie\Config\Config; +use PrestaShop\PrestaShop\Adapter\Order\OrderPresenter; + +class MollieFailModuleFrontController extends ModuleFrontController +{ + + /** + * ID Order Variable Declaration. + * + * @var + */ + private $id_order; + + /** + * Security Key Variable Declaration. + * + * @var + */ + private $secure_key; + + /** + * ID Cart Variable Declaration. + * + * @var + */ + private $id_cart; + + /** + * Order Presenter Variable Declaration. + * + * @var + */ + private $order_presenter; + + public function init() + { + if (!Config::isVersion17()) { + return parent::init(); + } + parent::init(); + + $this->id_cart = (int) Tools::getValue('cartId', 0); + + $redirectLink = 'index.php?controller=history'; + + $this->id_order = Order::getOrderByCartId((int) $this->id_cart); + $this->secure_key = Tools::getValue('secureKey'); + $order = new Order((int) $this->id_order); + + if (!$this->id_order || !$this->module->id || !$this->secure_key || empty($this->secure_key)) { + Tools::redirect($redirectLink . (Tools::isSubmit('slowvalidation') ? '&slowvalidation' : '')); + } + + if ((string) $this->secure_key !== (string) $order->secure_key || + (int) $order->id_customer !== (int) $this->context->customer->id || + !Validate::isLoadedObject($order) + ) { + Tools::redirect($redirectLink); + } + + if ($order->module !== $this->module->name) { + Tools::redirect($redirectLink); + } + $this->order_presenter = new OrderPresenter(); + } + + public function initContent() + { + parent::initContent(); + + $cartId = Tools::getValue('cartId'); + $moduleId = Tools::getValue('moduleId'); + $orderId = Tools::getValue('orderId'); + $secureKey = Tools::getValue('secureKey'); + + $orderLink = $this->context->link->getPageLink( + 'order-confirmation', + true, + null, + [ + 'id_cart' => $cartId, + 'id_module' => $moduleId, + 'id_order' => $orderId, + 'key' => $secureKey, + 'cancel' => 1, + ] + ); + if (!Config::isVersion17()) { + Tools::redirect($orderLink); + } + + $order = new Order($this->id_order); + if ((bool) version_compare(_PS_VERSION_, '1.7', '>=')) { + $this->context->smarty->assign([ + 'order' => $this->order_presenter->present($order), + ]); + } else { + $this->context->smarty->assign([ + 'id_order' => $this->id_order, + 'email' => $this->context->customer->email, + ]); + } + + $this->setTemplate( + sprintf('module:%s/views/templates/front/order_fail.tpl', $this->module->name) + ); + } +} diff --git a/controllers/front/index.php b/controllers/front/index.php index 729abf520..a950d02f4 100644 --- a/controllers/front/index.php +++ b/controllers/front/index.php @@ -1,11 +1,11 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -use _PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient; -use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod; - -class MolliePayScreenModuleFrontController extends ModuleFrontController -{ - - public function postProcess() - { - $method = Tools::getValue('method'); - $cardToken = Tools::getValue('mollieCardToken' . $method); - - $validateUrl = Context::getContext()->link->getModuleLink( - 'mollie', - 'payment', - array('method' => PaymentMethod::CREDITCARD, 'rand' => time(), 'cardToken' => $cardToken), - true - ); - - Tools::redirect($validateUrl); - } - - public function initContent() - { - parent::initContent(); - - $this->context->smarty->assign([ - 'mollieIFrameJS' => 'https://js.mollie.com/v1/mollie.js', - 'price' => $this->context->cart->getOrderTotal(), - 'priceSign' => $this->context->currency->getSign() - ]); - $this->setTemplate('module:mollie/views/templates/' . 'front/mollie_iframe.tpl'); - } - - public function setMedia() - { - Media::addJsDef([ - 'profileId' => Configuration::get(Mollie\Config\Config::MOLLIE_PROFILE_ID), - ]); - $this->addJS("{$this->module->getPathUri()}views/js/front/mollie_iframe.js"); - $this->addCSS("{$this->module->getPathUri()}views/css/mollie_iframe.css"); - - return parent::setMedia(); // TODO: Change the autogenerated stub - } -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +use _PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient; +use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod; + +class MolliePayScreenModuleFrontController extends ModuleFrontController +{ + + public function postProcess() + { + $method = Tools::getValue('method'); + $cardToken = Tools::getValue('mollieCardToken' . $method); + + $validateUrl = Context::getContext()->link->getModuleLink( + 'mollie', + 'payment', + array('method' => PaymentMethod::CREDITCARD, 'rand' => time(), 'cardToken' => $cardToken), + true + ); + + Tools::redirect($validateUrl); + } + + public function initContent() + { + parent::initContent(); + + $this->context->smarty->assign([ + 'mollieIFrameJS' => 'https://js.mollie.com/v1/mollie.js', + 'price' => $this->context->cart->getOrderTotal(), + 'priceSign' => $this->context->currency->getSign() + ]); + $this->setTemplate('module:mollie/views/templates/' . 'front/mollie_iframe.tpl'); + } + + public function setMedia() + { + Media::addJsDef([ + 'profileId' => Configuration::get(Mollie\Config\Config::MOLLIE_PROFILE_ID), + ]); + $this->addJS("{$this->module->getPathUri()}views/js/front/mollie_iframe.js"); + $this->addCSS("{$this->module->getPathUri()}views/css/mollie_iframe.css"); + + return parent::setMedia(); // TODO: Change the autogenerated stub + } +} diff --git a/controllers/front/payment.php b/controllers/front/payment.php index 75462e858..3ca682b70 100644 --- a/controllers/front/payment.php +++ b/controllers/front/payment.php @@ -1,394 +1,394 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -use _PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException; -use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order as MollieOrderAlias; -use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment as MolliePaymentAlias; -use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod; -use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; -use Mollie\Utility\PaymentFeeUtility; - -if (!defined('_PS_VERSION_')) { - return; -} - -require_once dirname(__FILE__).'/../../mollie.php'; - -/** - * Class MolliePaymentModuleFrontController - * - * @property Context? $context - * @property Mollie $module - */ -class MolliePaymentModuleFrontController extends ModuleFrontController -{ - /** @var bool $ssl */ - public $ssl = true; - /** @var bool $display_column_left */ - public $display_column_left = false; - /** @var bool $display_column_right */ - public $display_column_right = false; - - /** - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws Adapter_Exception - * @throws SmartyException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - * @throws Exception - */ - public function initContent() - { - parent::initContent(); - /** @var Cart $cart */ - $cart = $this->context->cart; - $customer = new Customer($cart->id_customer); - $this->context->smarty->assign('link', $this->context->link); - - if (!$this->validate( - $cart, - $customer - )) { - /** @var Mollie\Service\LanguageService $langService */ - $langService = $this->module->getContainer(Mollie\Service\LanguageService::class); - $this->errors[] = $langService->getLang()['This payment method is not available.']; - $this->setTemplate('error.tpl'); - - return; - } - - $method = Tools::getValue('method'); - if (in_array($method, array(\Mollie\Config\Config::CARTES_BANCAIRES))) { - $method = 'creditcard'; - } - $issuer = Tools::getValue('issuer') ?: null; - - $originalAmount = $cart->getOrderTotal( - true, - Cart::BOTH - ); - $amount = $originalAmount; - if (!$amount) { - Tools::redirectLink('index.php'); - } - - /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->module->getContainer(\Mollie\Repository\PaymentMethodRepository::class); - /** @var \Mollie\Service\PaymentMethodService $paymentMethodService */ - $paymentMethodService = $this->module->getContainer(\Mollie\Service\PaymentMethodService::class); - - $paymentMethodId = $paymentMethodRepo->getPaymentMethodIdByMethodId($method); - $paymentMethodObj = new MolPaymentMethod($paymentMethodId); - // Prepare payment - do { - $orderReference = Order::generateReference(); - } while (Order::getByReference($orderReference)->count()); - $paymentData = $paymentMethodService->getPaymentData( - $amount, - Tools::strtoupper($this->context->currency->iso_code), - $method, - $issuer, - (int) $cart->id, - $customer->secure_key, - $paymentMethodObj, - false, - $orderReference, - Tools::getValue('cardToken') - ); - try { - $apiPayment = $this->createPayment($paymentData, $paymentMethodObj->method); - } catch (ApiException $e) { - $this->setTemplate('error.tpl'); - $this->errors[] = Configuration::get(Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS) - ? $e->getMessage().'. Cart Dump: '.json_encode($paymentData, JSON_PRETTY_PRINT) - : $this->module->l('An error occurred while initializing your payment. Please contact our customer support.', 'payment'); - return; - } catch (PrestaShopException $e) { - $this->setTemplate('error.tpl'); - $this->errors[] = Configuration::get(Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS) - ? $e->getMessage().' Cart Dump: '.json_encode($paymentData, JSON_PRETTY_PRINT) - : $this->module->l('An error occurred while initializing your payment. Please contact our customer support.', 'payment'); - return; - } - $this->createOrder($method, $apiPayment, $cart->id, $originalAmount, $customer->secure_key, $orderReference); - $orderReference = isset($apiPayment->metadata->order_reference) ? pSQL($apiPayment->metadata->order_reference) : ''; - - // Store payment linked to cart - if ($apiPayment->method !== PaymentMethod::BANKTRANSFER) { - try { - Db::getInstance()->insert( - 'mollie_payments', - array( - 'cart_id' => (int) $cart->id, - 'method' => pSQL($apiPayment->method), - 'transaction_id' => pSQL($apiPayment->id), - 'order_reference' => pSQL($orderReference), - 'bank_status' => PaymentStatus::STATUS_OPEN, - 'created_at' => array('type' => 'sql', 'value' => 'NOW()'), - ) - ); - } catch (PrestaShopDatabaseException $e) { - $paymentMethodRepo->tryAddOrderReferenceColumn(); - throw $e; - } - } - - $status = $apiPayment->status; - if (!isset(Mollie\Config\Config::getStatuses()[$apiPayment->status])) { - $status = 'open'; - } - - $paymentStatus = (int) Mollie\Config\Config::getStatuses()[$status]; - - if ($paymentStatus < 1) { - $paymentStatus = Configuration::get(Mollie\Config\Config::STATUS_MOLLIE_AWAITING); - } - - if ($apiPayment->method === PaymentMethod::BANKTRANSFER) { - // Set the `banktransfer` details - if ($apiPayment instanceof MollieOrderAlias) { - // If this is an order, take the first payment - $apiPayment = $apiPayment->payments(); - $apiPayment = $apiPayment[0]; - } - - $details = $apiPayment->details->transferReference; - $address = "IBAN: {$apiPayment->details->bankAccount} / BIC: {$apiPayment->details->bankBic}"; - - $extraVars = array( - '{bankwire_owner}' => 'Stichting Mollie Payments', - '{bankwire_details}' => $details, - '{bankwire_address}' => $address, - ); - - $this->module->currentOrderReference = $orderReference; - $this->module->validateOrder( - (int) $cart->id, - $paymentStatus, - $originalAmount, - isset(Mollie\Config\Config::$methods[$apiPayment->method]) ? Mollie\Config\Config::$methods[$apiPayment->method] : $this->module->name, - null, - $extraVars, - null, - false, - $customer->secure_key - ); - - $orderId = Order::getOrderByCartId((int) $cart->id); - - try { - Db::getInstance()->insert( - 'mollie_payments', - array( - 'cart_id' => (int) $cart->id, - 'order_id' => (int) $orderId, - 'order_reference' => pSQL($orderReference), - 'method' => pSQL($apiPayment->method), - 'transaction_id' => pSQL($apiPayment->id), - 'bank_status' => PaymentStatus::STATUS_OPEN, - 'created_at' => array('type' => 'sql', 'value' => 'NOW()'), - ) - ); - } catch (PrestaShopDatabaseException $e) { - $paymentMethodRepo->tryAddOrderReferenceColumn(); - $redirectLink = $this->context->link->getPageLink( - 'order', - true, - null, - [ - 'step' => 1, - ] - ); - $this->errors[] = $this->l('Failed to validate order', 'payment'); - $this->redirectWithNotifications($redirectLink); - } - } - - - // Go to payment url - Tools::redirect($apiPayment->getCheckoutUrl()); - } - - /** - * Checks if this payment option is still available - * May redirect the user to a more appropriate page - * - * @param Cart $cart - * @param Customer $customer - * - * @return bool - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ - protected function validate($cart, $customer) - { - if (!$cart->id_customer || !$cart->id_address_delivery || !$cart->id_address_invoice || !$this->module->active) { - // We be like: how did you even get here? - Tools::redirect(Context::getContext()->link->getPageLink('index', true)); - return false; - } - - $authorized = false; - - foreach (Module::getPaymentModules() as $module) { - if ($module['name'] === $this->module->name) { - $authorized = true; - break; - } - } - - if (!$authorized) { - return false; - } - - if (!Validate::isLoadedObject($customer)) { - return false; - } - - return true; - } - - /** - * @param array $data - * - * @return MolliePaymentAlias|MollieOrderAlias|null - * - * @throws PrestaShopException - * @throws ApiException - */ - protected function createPayment($data, $selectedApi) - { - try { - if ($selectedApi === Mollie\Config\Config::MOLLIE_ORDERS_API) { - /** @var MollieOrderAlias $payment */ - $payment = $this->module->api->orders->create($data, array('embed' => 'payments')); - } else { - /** @var MolliePaymentAlias $payment */ - $payment = $this->module->api->payments->create($data); - } - } catch (Exception $e) { - throw new ApiException($e->getMessage()); - } - return $payment; - } - - /** - * Prepend module path if PS version >= 1.7 - * - * @param string $template - * @param array $params - * @param string|null $locale - * - * @throws PrestaShopException - * - * @since 3.3.2 - */ - public function setTemplate($template, $params = array(), $locale = null) - { - if (version_compare(_PS_VERSION_, '1.7.0.0', '>=')) { - $template = "module:mollie/views/templates/front/17_{$template}"; - } - - parent::setTemplate($template, $params, $locale); - } - - private function createOrder($method, $apiPayment, $cartId, $originalAmount, $secureKey, $orderReference) - { - $extraVars = []; - if ($method === PaymentMethod::BANKTRANSFER) { - // Set the `banktransfer` details - if ($apiPayment instanceof MollieOrderAlias) { - // If this is an order, take the first payment - $apiPayment = $apiPayment->payments(); - $apiPayment = $apiPayment[0]; - } - - $details = $apiPayment->details->transferReference; - $address = "IBAN: {$apiPayment->details->bankAccount} / BIC: {$apiPayment->details->bankBic}"; - - $extraVars = [ - '{bankwire_owner}' => 'Stichting Mollie Payments', - '{bankwire_details}' => $details, - '{bankwire_address}' => $address, - ]; - } - /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->module->getContainer(\Mollie\Repository\PaymentMethodRepository::class); - - $orderFee = PaymentFeeUtility::getPaymentFee( - new MolPaymentMethod($paymentMethodRepo->getPaymentMethodIdByMethodId($apiPayment->method)), - $this->context->cart->getOrderTotal() - ); - - $totalPrice = new Number((string) $originalAmount); - - if ($orderFee) { - $orderFeeObj = new MolOrderFee(); - $orderFeeObj->id_cart = (int) $cartId; - $orderFeeObj->order_fee = PaymentFeeUtility::getPaymentFee( - new MolPaymentMethod($paymentMethodRepo->getPaymentMethodIdByMethodId($apiPayment->method)), - $this->context->cart->getOrderTotal() - ); - try { - $orderFeeObj->add(); - } catch (Exception $e) { - throw new PrestaShopException('Can\'t save Order fee'); - } - $orderFeeNumber = new Number((string) $orderFeeObj->order_fee); - $totalPrice = $orderFeeNumber->plus($totalPrice); - } - - $this->module->validateOrder( - (int) $cartId, - (int) Configuration::get(Mollie\Config\Config::STATUS_MOLLIE_AWAITING), - $totalPrice->toPrecision(2), - isset(Mollie\Config\Config::$methods[$apiPayment->method]) ? Mollie\Config\Config::$methods[$method] : $this->module->name, - null, - $extraVars, - null, - false, - $secureKey - ); - - $orderid = Order::getOrderByCartId($cartId); - $order = new Order($orderid); - $order->total_paid_tax_excl = $totalPrice->toPrecision(2); - $order->total_paid_tax_incl = $totalPrice->toPrecision(2); - $order->total_paid = $totalPrice->toPrecision(2); - $order->reference = $orderReference; - $order->update(); - } -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +use _PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException; +use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order as MollieOrderAlias; +use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment as MolliePaymentAlias; +use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod; +use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; +use Mollie\Utility\PaymentFeeUtility; + +if (!defined('_PS_VERSION_')) { + return; +} + +require_once dirname(__FILE__).'/../../mollie.php'; + +/** + * Class MolliePaymentModuleFrontController + * + * @property Context? $context + * @property Mollie $module + */ +class MolliePaymentModuleFrontController extends ModuleFrontController +{ + /** @var bool $ssl */ + public $ssl = true; + /** @var bool $display_column_left */ + public $display_column_left = false; + /** @var bool $display_column_right */ + public $display_column_right = false; + + /** + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws Adapter_Exception + * @throws SmartyException + * @throws \PrestaShop\PrestaShop\Adapter\CoreException + * @throws Exception + */ + public function initContent() + { + parent::initContent(); + /** @var Cart $cart */ + $cart = $this->context->cart; + $customer = new Customer($cart->id_customer); + $this->context->smarty->assign('link', $this->context->link); + + if (!$this->validate( + $cart, + $customer + )) { + /** @var Mollie\Service\LanguageService $langService */ + $langService = $this->module->getContainer(Mollie\Service\LanguageService::class); + $this->errors[] = $langService->getLang()['This payment method is not available.']; + $this->setTemplate('error.tpl'); + + return; + } + + $method = Tools::getValue('method'); + if (in_array($method, array(\Mollie\Config\Config::CARTES_BANCAIRES))) { + $method = 'creditcard'; + } + $issuer = Tools::getValue('issuer') ?: null; + + $originalAmount = $cart->getOrderTotal( + true, + Cart::BOTH + ); + $amount = $originalAmount; + if (!$amount) { + Tools::redirectLink('index.php'); + } + + /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->module->getContainer(\Mollie\Repository\PaymentMethodRepository::class); + /** @var \Mollie\Service\PaymentMethodService $paymentMethodService */ + $paymentMethodService = $this->module->getContainer(\Mollie\Service\PaymentMethodService::class); + + $paymentMethodId = $paymentMethodRepo->getPaymentMethodIdByMethodId($method); + $paymentMethodObj = new MolPaymentMethod($paymentMethodId); + // Prepare payment + do { + $orderReference = Order::generateReference(); + } while (Order::getByReference($orderReference)->count()); + $paymentData = $paymentMethodService->getPaymentData( + $amount, + Tools::strtoupper($this->context->currency->iso_code), + $method, + $issuer, + (int) $cart->id, + $customer->secure_key, + $paymentMethodObj, + false, + $orderReference, + Tools::getValue('cardToken') + ); + try { + $apiPayment = $this->createPayment($paymentData, $paymentMethodObj->method); + } catch (ApiException $e) { + $this->setTemplate('error.tpl'); + $this->errors[] = Configuration::get(Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS) + ? $e->getMessage().'. Cart Dump: '.json_encode($paymentData, JSON_PRETTY_PRINT) + : $this->module->l('An error occurred while initializing your payment. Please contact our customer support.', 'payment'); + return; + } catch (PrestaShopException $e) { + $this->setTemplate('error.tpl'); + $this->errors[] = Configuration::get(Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS) + ? $e->getMessage().' Cart Dump: '.json_encode($paymentData, JSON_PRETTY_PRINT) + : $this->module->l('An error occurred while initializing your payment. Please contact our customer support.', 'payment'); + return; + } + $this->createOrder($method, $apiPayment, $cart->id, $originalAmount, $customer->secure_key, $orderReference); + $orderReference = isset($apiPayment->metadata->order_reference) ? pSQL($apiPayment->metadata->order_reference) : ''; + + // Store payment linked to cart + if ($apiPayment->method !== PaymentMethod::BANKTRANSFER) { + try { + Db::getInstance()->insert( + 'mollie_payments', + array( + 'cart_id' => (int) $cart->id, + 'method' => pSQL($apiPayment->method), + 'transaction_id' => pSQL($apiPayment->id), + 'order_reference' => pSQL($orderReference), + 'bank_status' => PaymentStatus::STATUS_OPEN, + 'created_at' => array('type' => 'sql', 'value' => 'NOW()'), + ) + ); + } catch (PrestaShopDatabaseException $e) { + $paymentMethodRepo->tryAddOrderReferenceColumn(); + throw $e; + } + } + + $status = $apiPayment->status; + if (!isset(Mollie\Config\Config::getStatuses()[$apiPayment->status])) { + $status = 'open'; + } + + $paymentStatus = (int) Mollie\Config\Config::getStatuses()[$status]; + + if ($paymentStatus < 1) { + $paymentStatus = Configuration::get(Mollie\Config\Config::STATUS_MOLLIE_AWAITING); + } + + if ($apiPayment->method === PaymentMethod::BANKTRANSFER) { + // Set the `banktransfer` details + if ($apiPayment instanceof MollieOrderAlias) { + // If this is an order, take the first payment + $apiPayment = $apiPayment->payments(); + $apiPayment = $apiPayment[0]; + } + + $details = $apiPayment->details->transferReference; + $address = "IBAN: {$apiPayment->details->bankAccount} / BIC: {$apiPayment->details->bankBic}"; + + $extraVars = array( + '{bankwire_owner}' => 'Stichting Mollie Payments', + '{bankwire_details}' => $details, + '{bankwire_address}' => $address, + ); + + $this->module->currentOrderReference = $orderReference; + $this->module->validateOrder( + (int) $cart->id, + $paymentStatus, + $originalAmount, + isset(Mollie\Config\Config::$methods[$apiPayment->method]) ? Mollie\Config\Config::$methods[$apiPayment->method] : $this->module->name, + null, + $extraVars, + null, + false, + $customer->secure_key + ); + + $orderId = Order::getOrderByCartId((int) $cart->id); + + try { + Db::getInstance()->insert( + 'mollie_payments', + array( + 'cart_id' => (int) $cart->id, + 'order_id' => (int) $orderId, + 'order_reference' => pSQL($orderReference), + 'method' => pSQL($apiPayment->method), + 'transaction_id' => pSQL($apiPayment->id), + 'bank_status' => PaymentStatus::STATUS_OPEN, + 'created_at' => array('type' => 'sql', 'value' => 'NOW()'), + ) + ); + } catch (PrestaShopDatabaseException $e) { + $paymentMethodRepo->tryAddOrderReferenceColumn(); + $redirectLink = $this->context->link->getPageLink( + 'order', + true, + null, + [ + 'step' => 1, + ] + ); + $this->errors[] = $this->l('Failed to validate order', 'payment'); + $this->redirectWithNotifications($redirectLink); + } + } + + + // Go to payment url + Tools::redirect($apiPayment->getCheckoutUrl()); + } + + /** + * Checks if this payment option is still available + * May redirect the user to a more appropriate page + * + * @param Cart $cart + * @param Customer $customer + * + * @return bool + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ + protected function validate($cart, $customer) + { + if (!$cart->id_customer || !$cart->id_address_delivery || !$cart->id_address_invoice || !$this->module->active) { + // We be like: how did you even get here? + Tools::redirect(Context::getContext()->link->getPageLink('index', true)); + return false; + } + + $authorized = false; + + foreach (Module::getPaymentModules() as $module) { + if ($module['name'] === $this->module->name) { + $authorized = true; + break; + } + } + + if (!$authorized) { + return false; + } + + if (!Validate::isLoadedObject($customer)) { + return false; + } + + return true; + } + + /** + * @param array $data + * + * @return MolliePaymentAlias|MollieOrderAlias|null + * + * @throws PrestaShopException + * @throws ApiException + */ + protected function createPayment($data, $selectedApi) + { + try { + if ($selectedApi === Mollie\Config\Config::MOLLIE_ORDERS_API) { + /** @var MollieOrderAlias $payment */ + $payment = $this->module->api->orders->create($data, array('embed' => 'payments')); + } else { + /** @var MolliePaymentAlias $payment */ + $payment = $this->module->api->payments->create($data); + } + } catch (Exception $e) { + throw new ApiException($e->getMessage()); + } + return $payment; + } + + /** + * Prepend module path if PS version >= 1.7 + * + * @param string $template + * @param array $params + * @param string|null $locale + * + * @throws PrestaShopException + * + * @since 3.3.2 + */ + public function setTemplate($template, $params = array(), $locale = null) + { + if (version_compare(_PS_VERSION_, '1.7.0.0', '>=')) { + $template = "module:mollie/views/templates/front/17_{$template}"; + } + + parent::setTemplate($template, $params, $locale); + } + + private function createOrder($method, $apiPayment, $cartId, $originalAmount, $secureKey, $orderReference) + { + $extraVars = []; + if ($method === PaymentMethod::BANKTRANSFER) { + // Set the `banktransfer` details + if ($apiPayment instanceof MollieOrderAlias) { + // If this is an order, take the first payment + $apiPayment = $apiPayment->payments(); + $apiPayment = $apiPayment[0]; + } + + $details = $apiPayment->details->transferReference; + $address = "IBAN: {$apiPayment->details->bankAccount} / BIC: {$apiPayment->details->bankBic}"; + + $extraVars = [ + '{bankwire_owner}' => 'Stichting Mollie Payments', + '{bankwire_details}' => $details, + '{bankwire_address}' => $address, + ]; + } + /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->module->getContainer(\Mollie\Repository\PaymentMethodRepository::class); + + $orderFee = PaymentFeeUtility::getPaymentFee( + new MolPaymentMethod($paymentMethodRepo->getPaymentMethodIdByMethodId($apiPayment->method)), + $this->context->cart->getOrderTotal() + ); + + $totalPrice = new Number((string) $originalAmount); + + if ($orderFee) { + $orderFeeObj = new MolOrderFee(); + $orderFeeObj->id_cart = (int) $cartId; + $orderFeeObj->order_fee = PaymentFeeUtility::getPaymentFee( + new MolPaymentMethod($paymentMethodRepo->getPaymentMethodIdByMethodId($apiPayment->method)), + $this->context->cart->getOrderTotal() + ); + try { + $orderFeeObj->add(); + } catch (Exception $e) { + throw new PrestaShopException('Can\'t save Order fee'); + } + $orderFeeNumber = new Number((string) $orderFeeObj->order_fee); + $totalPrice = $orderFeeNumber->plus($totalPrice); + } + + $this->module->validateOrder( + (int) $cartId, + (int) Configuration::get(Mollie\Config\Config::STATUS_MOLLIE_AWAITING), + $totalPrice->toPrecision(2), + isset(Mollie\Config\Config::$methods[$apiPayment->method]) ? Mollie\Config\Config::$methods[$method] : $this->module->name, + null, + $extraVars, + null, + false, + $secureKey + ); + + $orderid = Order::getOrderByCartId($cartId); + $order = new Order($orderid); + $order->total_paid_tax_excl = $totalPrice->toPrecision(2); + $order->total_paid_tax_incl = $totalPrice->toPrecision(2); + $order->total_paid = $totalPrice->toPrecision(2); + $order->reference = $orderReference; + $order->update(); + } +} diff --git a/controllers/front/qrcode.php b/controllers/front/qrcode.php index cd5a610e7..050e00d0a 100644 --- a/controllers/front/qrcode.php +++ b/controllers/front/qrcode.php @@ -1,300 +1,300 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -use _PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException; -use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment as MolliePaymentAlias; -use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order as MollieOrderAlias; -use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod; -use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus; -use Mollie\Repository\PaymentMethodRepository; -use Mollie\Utility\EnvironmentUtility; - -if (!defined('_PS_VERSION_')) { - exit; -} - -require_once dirname(__FILE__).'/../../mollie.php'; - -/** - * Class MollieQrcodeModuleFrontController - * - * @property Mollie $module - */ -class MollieQrcodeModuleFrontController extends ModuleFrontController -{ - const PENDING = 1; - const SUCCESS = 2; - const REFRESH = 3; - - /** @var bool $ssl */ - public $ssl = true; - /** @var bool If false, does not build left page column content and hides it. */ - public $display_column_left = false; - /** @var bool If false, does not build right page column content and hides it. */ - public $display_column_right = false; - - /** - * @throws Adapter_Exception - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws SmartyException - * @throws ApiException - */ - public function initContent() - { - if (Tools::getValue('ajax')) { - $this->processAjax(); - exit; - } - - if (Tools::getValue('done')) { - $canceled = true; - /** @var PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); - $dbPayment = $paymentMethodRepo->getPaymentBy('cart_id', Tools::getValue('cart_id')); - if (is_array($dbPayment)) { - try { - $apiPayment = $this->module->api->payments->get($dbPayment['transaction_id']); - $canceled = $apiPayment->status !== PaymentStatus::STATUS_PAID; - } catch (ApiException $e) { - } - } - - header('Content-Type: text/html'); - $this->context->smarty->assign(array( - 'ideal_logo' => __PS_BASE_URI__.'modules/mollie/views/img/ideal_logo.png', - 'canceled' => $canceled, - )); - echo $this->context->smarty->fetch(_PS_MODULE_DIR_.'mollie/views/templates/front/qr_done.tpl'); - exit; - } - } - - /** - * @throws Adapter_Exception - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws ApiException - */ - protected function processAjax() - { - switch (Tools::getValue('action')) { -// case 'qrCodeNew': -// return $this->processNewQrCode(); - case 'qrCodeStatus': - return $this->processGetStatus(); - case 'cartAmount': - return $this->processCartAmount(); - } - - exit; - } - - /** - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ - protected function processNewQrCode() - { - header('Content-Type: application/json;charset=UTF-8'); - /** @var Mollie $mollie */ - $mollie = Module::getInstanceByName('mollie'); - $context = Context::getContext(); - $customer = $context->customer; - $cart = $context->cart; - if (!$cart instanceof Cart || !$cart->getOrderTotal(true)) { - die(json_encode(array( - 'success' => false, - 'message' => 'No active cart', - ))); - } - /** @var PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); - /** @var \Mollie\Service\ApiService $apiService */ - $apiService = $this->module->getContainer(\Mollie\Service\ApiService::class); - /** @var \Mollie\Service\PaymentMethodService $paymentMethodService */ - $paymentMethodService = $this->module->getContainer(\Mollie\Service\PaymentMethodService::class); - - $orderTotal = $cart->getOrderTotal(true); - $paymentMethodId = $paymentMethodRepo->getPaymentMethodIdByMethodId(PaymentMethod::IDEAL); - $paymentMethodObj = new MolPaymentMethod($paymentMethodId); - $payment = $mollie->api->{$apiService->selectedApi(Mollie::$selectedApi)}->create($paymentMethodService->getPaymentData( - $orderTotal, - Tools::strtoupper($this->context->currency->iso_code), - PaymentMethod::IDEAL, - null, - (int) $cart->id, - $customer->secure_key, - $paymentMethodObj, - true - ), array( - 'include' => 'details.qrCode', - )); - - try { - Db::getInstance()->insert( - 'mollie_payments', - array( - 'cart_id' => (int) $cart->id, - 'method' => pSQL($payment->method), - 'transaction_id' => pSQL($payment->id), - 'bank_status' => PaymentStatus::STATUS_OPEN, - 'created_at' => array('type' => 'sql', 'value' => 'NOW()'), - ) - ); - } catch (PrestaShopDatabaseException $e) { - $paymentMethodRepo->tryAddOrderReferenceColumn(); - throw $e; - } - - $src = isset($payment->details->qrCode->src) ? $payment->details->qrCode->src : null; - die(json_encode(array( - 'success' => (bool) $src, - 'href' => $src, - 'idTransaction' => $payment->id, - 'expires' => strtotime($payment->expiresAt) * 1000, - 'amount' => (int) ($orderTotal * 100), - ))); - } - - /** - * Get payment status, can be regularly polled - * - * @throws PrestaShopException - * @throws Adapter_Exception - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - * @throws SmartyException - */ - protected function processGetStatus() - { - header('Content-Type: application/json;charset=UTF-8'); - if (empty($this->context->cart)) { - die(json_encode(array( - 'success' => false, - 'status' => false, - 'amount' => null, - ))); - } - - if (EnvironmentUtility::isLocalEnvironment()) { - /** @var MolliePaymentAlias | MollieOrderAlias $payment */ - $apiPayment = $this->module->api->payments->get(Tools::getValue('transaction_id')); - if (!Tools::isSubmit('module')) { - $_GET['module'] = $this->module->name; - } - $webhookController = new MollieWebhookModuleFrontController(); - $webhookController->processTransaction($apiPayment); - } - - try { - /** @var PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); - $payment = $paymentMethodRepo->getPaymentBy('transaction_id', Tools::getValue('transaction_id')); - } catch (PrestaShopDatabaseException $e) { - die(json_encode(array( - 'success' => false, - 'status' => false, - 'amount' => null, - ))); - } catch (PrestaShopException $e) { - die(json_encode(array( - 'success' => false, - 'status' => false, - 'amount' => null, - ))); - } - - switch ($payment['bank_status']) { - case PaymentStatus::STATUS_PAID: - case PaymentStatus::STATUS_AUTHORIZED: - $status = static::SUCCESS; - break; - case PaymentStatus::STATUS_OPEN: - $status = static::PENDING; - break; - default: - $status = static::REFRESH; - break; - } - - $cart = new Cart($payment['cart_id']); - $amount = (int) ($cart->getOrderTotal(true) * 100); - die(json_encode(array( - 'success' => true, - 'status' => $status, - 'amount' => $amount, - 'href' => $this->context->link->getPageLink( - 'order-confirmation', - true, - null, - array( - 'id_cart' => (int) $cart->id, - 'id_module' => (int) $this->module->id, - 'id_order' => Order::getOrderByCartId((int) $cart->id), - 'key' => $cart->secure_key, - ) - ) - ))); - } - - /** - * Get the cart amount - * - * @throws Adapter_Exception - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws Exception - */ - protected function processCartAmount() - { - header('Content-Type: application/json;charset=UTF-8'); - /** @var Context $context */ - $context = Context::getContext(); - /** @var Cart $cart */ - $cart = $context->cart; - if (!$cart) { - die(json_encode(array( - 'success' => true, - 'amount' => 0 - ))); - } - - $cartTotal = (int) ($cart->getOrderTotal(true) * 100); - die(json_encode(array( - 'success' => true, - 'amount' => $cartTotal, - ))); - } -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +use _PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException; +use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment as MolliePaymentAlias; +use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order as MollieOrderAlias; +use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod; +use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus; +use Mollie\Repository\PaymentMethodRepository; +use Mollie\Utility\EnvironmentUtility; + +if (!defined('_PS_VERSION_')) { + exit; +} + +require_once dirname(__FILE__).'/../../mollie.php'; + +/** + * Class MollieQrcodeModuleFrontController + * + * @property Mollie $module + */ +class MollieQrcodeModuleFrontController extends ModuleFrontController +{ + const PENDING = 1; + const SUCCESS = 2; + const REFRESH = 3; + + /** @var bool $ssl */ + public $ssl = true; + /** @var bool If false, does not build left page column content and hides it. */ + public $display_column_left = false; + /** @var bool If false, does not build right page column content and hides it. */ + public $display_column_right = false; + + /** + * @throws Adapter_Exception + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws SmartyException + * @throws ApiException + */ + public function initContent() + { + if (Tools::getValue('ajax')) { + $this->processAjax(); + exit; + } + + if (Tools::getValue('done')) { + $canceled = true; + /** @var PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); + $dbPayment = $paymentMethodRepo->getPaymentBy('cart_id', Tools::getValue('cart_id')); + if (is_array($dbPayment)) { + try { + $apiPayment = $this->module->api->payments->get($dbPayment['transaction_id']); + $canceled = $apiPayment->status !== PaymentStatus::STATUS_PAID; + } catch (ApiException $e) { + } + } + + header('Content-Type: text/html'); + $this->context->smarty->assign(array( + 'ideal_logo' => __PS_BASE_URI__.'modules/mollie/views/img/ideal_logo.png', + 'canceled' => $canceled, + )); + echo $this->context->smarty->fetch(_PS_MODULE_DIR_.'mollie/views/templates/front/qr_done.tpl'); + exit; + } + } + + /** + * @throws Adapter_Exception + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws ApiException + */ + protected function processAjax() + { + switch (Tools::getValue('action')) { +// case 'qrCodeNew': +// return $this->processNewQrCode(); + case 'qrCodeStatus': + return $this->processGetStatus(); + case 'cartAmount': + return $this->processCartAmount(); + } + + exit; + } + + /** + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ + protected function processNewQrCode() + { + header('Content-Type: application/json;charset=UTF-8'); + /** @var Mollie $mollie */ + $mollie = Module::getInstanceByName('mollie'); + $context = Context::getContext(); + $customer = $context->customer; + $cart = $context->cart; + if (!$cart instanceof Cart || !$cart->getOrderTotal(true)) { + die(json_encode(array( + 'success' => false, + 'message' => 'No active cart', + ))); + } + /** @var PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); + /** @var \Mollie\Service\ApiService $apiService */ + $apiService = $this->module->getContainer(\Mollie\Service\ApiService::class); + /** @var \Mollie\Service\PaymentMethodService $paymentMethodService */ + $paymentMethodService = $this->module->getContainer(\Mollie\Service\PaymentMethodService::class); + + $orderTotal = $cart->getOrderTotal(true); + $paymentMethodId = $paymentMethodRepo->getPaymentMethodIdByMethodId(PaymentMethod::IDEAL); + $paymentMethodObj = new MolPaymentMethod($paymentMethodId); + $payment = $mollie->api->{$apiService->selectedApi(Mollie::$selectedApi)}->create($paymentMethodService->getPaymentData( + $orderTotal, + Tools::strtoupper($this->context->currency->iso_code), + PaymentMethod::IDEAL, + null, + (int) $cart->id, + $customer->secure_key, + $paymentMethodObj, + true + ), array( + 'include' => 'details.qrCode', + )); + + try { + Db::getInstance()->insert( + 'mollie_payments', + array( + 'cart_id' => (int) $cart->id, + 'method' => pSQL($payment->method), + 'transaction_id' => pSQL($payment->id), + 'bank_status' => PaymentStatus::STATUS_OPEN, + 'created_at' => array('type' => 'sql', 'value' => 'NOW()'), + ) + ); + } catch (PrestaShopDatabaseException $e) { + $paymentMethodRepo->tryAddOrderReferenceColumn(); + throw $e; + } + + $src = isset($payment->details->qrCode->src) ? $payment->details->qrCode->src : null; + die(json_encode(array( + 'success' => (bool) $src, + 'href' => $src, + 'idTransaction' => $payment->id, + 'expires' => strtotime($payment->expiresAt) * 1000, + 'amount' => (int) ($orderTotal * 100), + ))); + } + + /** + * Get payment status, can be regularly polled + * + * @throws PrestaShopException + * @throws Adapter_Exception + * @throws \PrestaShop\PrestaShop\Adapter\CoreException + * @throws SmartyException + */ + protected function processGetStatus() + { + header('Content-Type: application/json;charset=UTF-8'); + if (empty($this->context->cart)) { + die(json_encode(array( + 'success' => false, + 'status' => false, + 'amount' => null, + ))); + } + + if (EnvironmentUtility::isLocalEnvironment()) { + /** @var MolliePaymentAlias | MollieOrderAlias $payment */ + $apiPayment = $this->module->api->payments->get(Tools::getValue('transaction_id')); + if (!Tools::isSubmit('module')) { + $_GET['module'] = $this->module->name; + } + $webhookController = new MollieWebhookModuleFrontController(); + $webhookController->processTransaction($apiPayment); + } + + try { + /** @var PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); + $payment = $paymentMethodRepo->getPaymentBy('transaction_id', Tools::getValue('transaction_id')); + } catch (PrestaShopDatabaseException $e) { + die(json_encode(array( + 'success' => false, + 'status' => false, + 'amount' => null, + ))); + } catch (PrestaShopException $e) { + die(json_encode(array( + 'success' => false, + 'status' => false, + 'amount' => null, + ))); + } + + switch ($payment['bank_status']) { + case PaymentStatus::STATUS_PAID: + case PaymentStatus::STATUS_AUTHORIZED: + $status = static::SUCCESS; + break; + case PaymentStatus::STATUS_OPEN: + $status = static::PENDING; + break; + default: + $status = static::REFRESH; + break; + } + + $cart = new Cart($payment['cart_id']); + $amount = (int) ($cart->getOrderTotal(true) * 100); + die(json_encode(array( + 'success' => true, + 'status' => $status, + 'amount' => $amount, + 'href' => $this->context->link->getPageLink( + 'order-confirmation', + true, + null, + array( + 'id_cart' => (int) $cart->id, + 'id_module' => (int) $this->module->id, + 'id_order' => Order::getOrderByCartId((int) $cart->id), + 'key' => $cart->secure_key, + ) + ) + ))); + } + + /** + * Get the cart amount + * + * @throws Adapter_Exception + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws Exception + */ + protected function processCartAmount() + { + header('Content-Type: application/json;charset=UTF-8'); + /** @var Context $context */ + $context = Context::getContext(); + /** @var Cart $cart */ + $cart = $context->cart; + if (!$cart) { + die(json_encode(array( + 'success' => true, + 'amount' => 0 + ))); + } + + $cartTotal = (int) ($cart->getOrderTotal(true) * 100); + die(json_encode(array( + 'success' => true, + 'amount' => $cartTotal, + ))); + } +} diff --git a/controllers/front/return.php b/controllers/front/return.php index d719369c8..cccebca0c 100644 --- a/controllers/front/return.php +++ b/controllers/front/return.php @@ -1,372 +1,372 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod; -use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus; -use Mollie\Repository\PaymentMethodRepository; -use Mollie\Service\OrderStatusService; - -if (!defined('_PS_VERSION_')) { - exit; -} - -require_once dirname(__FILE__) . '/../../mollie.php'; - -/** - * Class MollieReturnModuleFrontController - * - * @property Context? $context - * @property Mollie $module - */ -class MollieReturnModuleFrontController extends ModuleFrontController -{ - const PENDING = 1; - const DONE = 2; - - /** @var bool $ssl */ - public $ssl = true; - /** @var bool $display_column_left */ - public $display_column_left = false; - /** @var bool $display_column_left */ - public $display_column_right = false; - - /** - * Unset the cart id from cookie if the order exists - * - * @throws PrestaShopException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - */ - public function init() - { - /** @var Context $context */ - $context = Context::getContext(); - /** @var Cart $cart */ - $cart = new Cart((int)$this->context->cookie->id_cart); - if (Validate::isLoadedObject($cart) && !$cart->orderExists()) { - unset($context->cart); - unset($context->cookie->id_cart); - unset($context->cookie->checkedTOS); - unset($context->cookie->check_cgv); - } - - parent::init(); - } - - /** - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws Adapter_Exception - * @throws SmartyException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - */ - public function initContent() - { - if (Tools::getValue('ajax')) { - $this->processAjax(); - exit; - } - - parent::initContent(); - - $data = []; - $cart = null; - - /** @var PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); - /** - * Set ref is indicative of a payment that is tied to an order instead of a cart, which - * we still support for transitional reasons. - */ - if (Tools::getIsset('ref')) { - $idOrder = (int)Tools::getValue('id'); - // Check if user is allowed to be on the return page - $data['auth'] = $paymentMethodRepo->getUniqReferenceOf($idOrder) === Tools::getValue('ref'); - if ($data['auth']) { - $data['mollie_info'] = $paymentMethodRepo->getPaymentBy('order_id', (int)$idOrder); - } - } elseif (Tools::getIsset('cart_id')) { - $idCart = (int)Tools::getValue('cart_id'); - - // Check if user that's seeing this is the cart-owner - $cart = new Cart($idCart); - $data['auth'] = (int)$cart->id_customer === $this->context->customer->id; - if ($data['auth']) { - $data['mollie_info'] = $paymentMethodRepo->getPaymentBy('cart_id', (int)$idCart); - } - } - - if (isset($data['auth']) && $data['auth']) { - // any paid payments for this cart? - - if ($data['mollie_info'] === false) { - $data['mollie_info'] = []; - $data['msg_details'] = $this->l('The order with this id does not exist.'); - } elseif ($data['mollie_info']['method'] === PaymentMethod::BANKTRANSFER - && $data['mollie_info']['bank_status'] === PaymentStatus::STATUS_OPEN - ) { - $data['msg_details'] = $this->l('We have not received a definite payment status. You will be notified as soon as we receive a confirmation of the bank/merchant.'); - } else { - $data['wait'] = true; - } - } else { - // Not allowed? Don't make query but redirect. - $data['mollie_info'] = []; - $data['msg_details'] = $this->l('You are not authorised to see this page.'); - Tools::redirect(Context::getContext()->link->getPageLink('index', true)); - } - - $this->context->smarty->assign($data); - $this->context->smarty->assign('link', $this->context->link); - - if (!empty($data['wait'])) { - $this->context->smarty->assign( - 'checkStatusEndpoint', - $this->context->link->getModuleLink( - $this->module->name, - 'return', - ['ajax' => 1, 'action' => 'getStatus', 'transaction_id' => $data['mollie_info']['transaction_id']], - true - ) - ); - $this->setTemplate('mollie_wait.tpl'); - } else { - $this->setTemplate('mollie_return.tpl'); - } - } - - /** - * Prepend module path if PS version >= 1.7 - * - * @param string $template - * @param array $params - * @param string|null $locale - * - * @throws PrestaShopException - * - * @since 3.3.2 - */ - public function setTemplate($template, $params = [], $locale = null) - { - if (version_compare(_PS_VERSION_, '1.7.0.0', '>=')) { - $template = "module:mollie/views/templates/front/17_{$template}"; - } - - parent::setTemplate($template, $params, $locale); - } - - /** - * Process ajax calls - * - * @throws Adapter_Exception - * @throws PrestaShopException - * @throws SmartyException - * - * @since 3.3.2 - */ - protected function processAjax() - { - if (empty($this->context->customer->id)) { - return; - } - - switch (Tools::getValue('action')) { - case 'getStatus': - $this->processGetStatus(); - break; - } - - exit; - } - - /** - * Get payment status, can be regularly polled - * - * @throws PrestaShopException - * @throws Adapter_Exception - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - * @throws SmartyException - * - * @since 3.3.2 - */ - protected function processGetStatus() - { - header('Content-Type: application/json;charset=UTF-8'); - /** @var PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); - - $transactionId = Tools::getValue('transaction_id'); - $dbPayment = $paymentMethodRepo->getPaymentBy('transaction_id', $transactionId); - $cart = new Cart($dbPayment['cart_id']); - if (!Validate::isLoadedObject($cart)) { - die(json_encode([ - 'success' => false, - ])); - } - $orderId = Order::getOrderByCartId((int)$cart->id); - $order = new Order((int)$orderId); - - if (!Validate::isLoadedObject($cart)) { - die(json_encode([ - 'success' => false, - ])); - } - - if ((int)$cart->id_customer !== (int)$this->context->customer->id) { - die(json_encode([ - 'success' => false, - ])); - } - - - if (!Tools::isSubmit('module')) { - $_GET['module'] = $this->module->name; - } - - if (Tools::substr($transactionId, 0, 3) === 'ord') { - $transaction = $this->module->api->orders->get($transactionId, ['embed' => 'payments']); - } else { - $transaction = $this->module->api->payments->get($transactionId); - } - /** @var OrderStatusService $orderStatusService */ - $orderStatusService = $this->module->getContainer(OrderStatusService::class); - - $orderStatus = $transaction->status; - switch ($transaction->status) { - case PaymentStatus::STATUS_EXPIRED: - case PaymentStatus::STATUS_FAILED: - case PaymentStatus::STATUS_CANCELED: - $orderStatus = $transaction->status; - $orderStatusId = (int)Mollie\Config\Config::getStatuses()[$orderStatus]; - - $orderStatusService->setOrderStatus($orderId, $orderStatusId); - - $failUrl = $this->context->link->getModuleLink( - $this->module->name, - 'fail', - [ - 'cartId' => $cart->id, - 'secureKey' => $cart->secure_key, - 'orderId' => $orderId, - 'moduleId' => $this->module->name, - ], - true - ); - - die(json_encode([ - 'success' => true, - 'status' => static::DONE, - 'response' => json_encode($transaction), - 'href' => $failUrl - - ])); - case PaymentStatus::STATUS_AUTHORIZED: - case PaymentStatus::STATUS_PAID: - $status = static::DONE; - $orderDetails = $order->getOrderDetailList(); - /** @var OrderDetail $detail */ - foreach ($orderDetails as $detail) { - $orderDetail = new OrderDetail($detail['id_order_detail']); - if ( - Configuration::get('PS_STOCK_MANAGEMENT') && - ($orderDetail->getStockState() || $orderDetail->product_quantity_in_stock < 0) - ) { - $orderStatus = Mollie\Config\Config::STATUS_PAID_ON_BACKORDER; - break; - } - } - break; - default: - $status = static::PENDING; - $orderDetails = $order->getOrderDetailList(); - /** @var OrderDetail $detail */ - foreach ($orderDetails as $detail) { - $orderDetail = new OrderDetail($detail['id_order_detail']); - if ( - Configuration::get('PS_STOCK_MANAGEMENT') && - ($orderDetail->getStockState() || $orderDetail->product_quantity_in_stock < 0) - ) { - $orderStatus = Mollie\Config\Config::STATUS_PENDING_ON_BACKORDER; - break; - } - } - break; - } - - $orderStatusId = (int)Mollie\Config\Config::getStatuses()[$orderStatus]; - $orderStatusService->setOrderStatus($orderId, $orderStatusId); - $this->savePaymentStatus($transactionId, $orderStatus, $orderId); - - $successUrl = $this->context->link->getPageLink( - 'order-confirmation', - true, - null, - [ - 'id_cart' => (int)$cart->id, - 'id_module' => (int)$this->module->id, - 'id_order' => (int)version_compare(_PS_VERSION_, '1.7.1.0', '>=') - ? Order::getIdByCartId((int)$cart->id) - : Order::getOrderByCartId((int)$cart->id), - 'key' => $cart->secure_key, - ] - ); - - die(json_encode([ - 'success' => true, - 'status' => $status, - 'response' => json_encode($transaction), - 'href' => $successUrl - ])); - } - - protected function savePaymentStatus($transactionId, $status, $orderId) - { - try { - return Db::getInstance()->update( - 'mollie_payments', - array( - 'updated_at' => array('type' => 'sql', 'value' => 'NOW()'), - 'bank_status' => pSQL($status), - 'order_id' => (int) $orderId, - ), - '`transaction_id` = \''.pSQL($transactionId).'\'' - ); - } catch (Exception $e) { - /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->module->getContainer(\Mollie\Repository\PaymentMethodRepository::class); - $paymentMethodRepo->tryAddOrderReferenceColumn(); - throw $e; - } - } -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod; +use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus; +use Mollie\Repository\PaymentMethodRepository; +use Mollie\Service\OrderStatusService; + +if (!defined('_PS_VERSION_')) { + exit; +} + +require_once dirname(__FILE__) . '/../../mollie.php'; + +/** + * Class MollieReturnModuleFrontController + * + * @property Context? $context + * @property Mollie $module + */ +class MollieReturnModuleFrontController extends ModuleFrontController +{ + const PENDING = 1; + const DONE = 2; + + /** @var bool $ssl */ + public $ssl = true; + /** @var bool $display_column_left */ + public $display_column_left = false; + /** @var bool $display_column_left */ + public $display_column_right = false; + + /** + * Unset the cart id from cookie if the order exists + * + * @throws PrestaShopException + * @throws \PrestaShop\PrestaShop\Adapter\CoreException + */ + public function init() + { + /** @var Context $context */ + $context = Context::getContext(); + /** @var Cart $cart */ + $cart = new Cart((int)$this->context->cookie->id_cart); + if (Validate::isLoadedObject($cart) && !$cart->orderExists()) { + unset($context->cart); + unset($context->cookie->id_cart); + unset($context->cookie->checkedTOS); + unset($context->cookie->check_cgv); + } + + parent::init(); + } + + /** + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws Adapter_Exception + * @throws SmartyException + * @throws \PrestaShop\PrestaShop\Adapter\CoreException + */ + public function initContent() + { + if (Tools::getValue('ajax')) { + $this->processAjax(); + exit; + } + + parent::initContent(); + + $data = []; + $cart = null; + + /** @var PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); + /** + * Set ref is indicative of a payment that is tied to an order instead of a cart, which + * we still support for transitional reasons. + */ + if (Tools::getIsset('ref')) { + $idOrder = (int)Tools::getValue('id'); + // Check if user is allowed to be on the return page + $data['auth'] = $paymentMethodRepo->getUniqReferenceOf($idOrder) === Tools::getValue('ref'); + if ($data['auth']) { + $data['mollie_info'] = $paymentMethodRepo->getPaymentBy('order_id', (int)$idOrder); + } + } elseif (Tools::getIsset('cart_id')) { + $idCart = (int)Tools::getValue('cart_id'); + + // Check if user that's seeing this is the cart-owner + $cart = new Cart($idCart); + $data['auth'] = (int)$cart->id_customer === $this->context->customer->id; + if ($data['auth']) { + $data['mollie_info'] = $paymentMethodRepo->getPaymentBy('cart_id', (int)$idCart); + } + } + + if (isset($data['auth']) && $data['auth']) { + // any paid payments for this cart? + + if ($data['mollie_info'] === false) { + $data['mollie_info'] = []; + $data['msg_details'] = $this->l('The order with this id does not exist.'); + } elseif ($data['mollie_info']['method'] === PaymentMethod::BANKTRANSFER + && $data['mollie_info']['bank_status'] === PaymentStatus::STATUS_OPEN + ) { + $data['msg_details'] = $this->l('We have not received a definite payment status. You will be notified as soon as we receive a confirmation of the bank/merchant.'); + } else { + $data['wait'] = true; + } + } else { + // Not allowed? Don't make query but redirect. + $data['mollie_info'] = []; + $data['msg_details'] = $this->l('You are not authorised to see this page.'); + Tools::redirect(Context::getContext()->link->getPageLink('index', true)); + } + + $this->context->smarty->assign($data); + $this->context->smarty->assign('link', $this->context->link); + + if (!empty($data['wait'])) { + $this->context->smarty->assign( + 'checkStatusEndpoint', + $this->context->link->getModuleLink( + $this->module->name, + 'return', + ['ajax' => 1, 'action' => 'getStatus', 'transaction_id' => $data['mollie_info']['transaction_id']], + true + ) + ); + $this->setTemplate('mollie_wait.tpl'); + } else { + $this->setTemplate('mollie_return.tpl'); + } + } + + /** + * Prepend module path if PS version >= 1.7 + * + * @param string $template + * @param array $params + * @param string|null $locale + * + * @throws PrestaShopException + * + * @since 3.3.2 + */ + public function setTemplate($template, $params = [], $locale = null) + { + if (version_compare(_PS_VERSION_, '1.7.0.0', '>=')) { + $template = "module:mollie/views/templates/front/17_{$template}"; + } + + parent::setTemplate($template, $params, $locale); + } + + /** + * Process ajax calls + * + * @throws Adapter_Exception + * @throws PrestaShopException + * @throws SmartyException + * + * @since 3.3.2 + */ + protected function processAjax() + { + if (empty($this->context->customer->id)) { + return; + } + + switch (Tools::getValue('action')) { + case 'getStatus': + $this->processGetStatus(); + break; + } + + exit; + } + + /** + * Get payment status, can be regularly polled + * + * @throws PrestaShopException + * @throws Adapter_Exception + * @throws \PrestaShop\PrestaShop\Adapter\CoreException + * @throws SmartyException + * + * @since 3.3.2 + */ + protected function processGetStatus() + { + header('Content-Type: application/json;charset=UTF-8'); + /** @var PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); + + $transactionId = Tools::getValue('transaction_id'); + $dbPayment = $paymentMethodRepo->getPaymentBy('transaction_id', $transactionId); + $cart = new Cart($dbPayment['cart_id']); + if (!Validate::isLoadedObject($cart)) { + die(json_encode([ + 'success' => false, + ])); + } + $orderId = Order::getOrderByCartId((int)$cart->id); + $order = new Order((int)$orderId); + + if (!Validate::isLoadedObject($cart)) { + die(json_encode([ + 'success' => false, + ])); + } + + if ((int)$cart->id_customer !== (int)$this->context->customer->id) { + die(json_encode([ + 'success' => false, + ])); + } + + + if (!Tools::isSubmit('module')) { + $_GET['module'] = $this->module->name; + } + + if (Tools::substr($transactionId, 0, 3) === 'ord') { + $transaction = $this->module->api->orders->get($transactionId, ['embed' => 'payments']); + } else { + $transaction = $this->module->api->payments->get($transactionId); + } + /** @var OrderStatusService $orderStatusService */ + $orderStatusService = $this->module->getContainer(OrderStatusService::class); + + $orderStatus = $transaction->status; + switch ($transaction->status) { + case PaymentStatus::STATUS_EXPIRED: + case PaymentStatus::STATUS_FAILED: + case PaymentStatus::STATUS_CANCELED: + $orderStatus = $transaction->status; + $orderStatusId = (int)Mollie\Config\Config::getStatuses()[$orderStatus]; + + $orderStatusService->setOrderStatus($orderId, $orderStatusId); + + $failUrl = $this->context->link->getModuleLink( + $this->module->name, + 'fail', + [ + 'cartId' => $cart->id, + 'secureKey' => $cart->secure_key, + 'orderId' => $orderId, + 'moduleId' => $this->module->name, + ], + true + ); + + die(json_encode([ + 'success' => true, + 'status' => static::DONE, + 'response' => json_encode($transaction), + 'href' => $failUrl + + ])); + case PaymentStatus::STATUS_AUTHORIZED: + case PaymentStatus::STATUS_PAID: + $status = static::DONE; + $orderDetails = $order->getOrderDetailList(); + /** @var OrderDetail $detail */ + foreach ($orderDetails as $detail) { + $orderDetail = new OrderDetail($detail['id_order_detail']); + if ( + Configuration::get('PS_STOCK_MANAGEMENT') && + ($orderDetail->getStockState() || $orderDetail->product_quantity_in_stock < 0) + ) { + $orderStatus = Mollie\Config\Config::STATUS_PAID_ON_BACKORDER; + break; + } + } + break; + default: + $status = static::PENDING; + $orderDetails = $order->getOrderDetailList(); + /** @var OrderDetail $detail */ + foreach ($orderDetails as $detail) { + $orderDetail = new OrderDetail($detail['id_order_detail']); + if ( + Configuration::get('PS_STOCK_MANAGEMENT') && + ($orderDetail->getStockState() || $orderDetail->product_quantity_in_stock < 0) + ) { + $orderStatus = Mollie\Config\Config::STATUS_PENDING_ON_BACKORDER; + break; + } + } + break; + } + + $orderStatusId = (int)Mollie\Config\Config::getStatuses()[$orderStatus]; + $orderStatusService->setOrderStatus($orderId, $orderStatusId); + $this->savePaymentStatus($transactionId, $orderStatus, $orderId); + + $successUrl = $this->context->link->getPageLink( + 'order-confirmation', + true, + null, + [ + 'id_cart' => (int)$cart->id, + 'id_module' => (int)$this->module->id, + 'id_order' => (int)version_compare(_PS_VERSION_, '1.7.1.0', '>=') + ? Order::getIdByCartId((int)$cart->id) + : Order::getOrderByCartId((int)$cart->id), + 'key' => $cart->secure_key, + ] + ); + + die(json_encode([ + 'success' => true, + 'status' => $status, + 'response' => json_encode($transaction), + 'href' => $successUrl + ])); + } + + protected function savePaymentStatus($transactionId, $status, $orderId) + { + try { + return Db::getInstance()->update( + 'mollie_payments', + array( + 'updated_at' => array('type' => 'sql', 'value' => 'NOW()'), + 'bank_status' => pSQL($status), + 'order_id' => (int) $orderId, + ), + '`transaction_id` = \''.pSQL($transactionId).'\'' + ); + } catch (Exception $e) { + /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->module->getContainer(\Mollie\Repository\PaymentMethodRepository::class); + $paymentMethodRepo->tryAddOrderReferenceColumn(); + throw $e; + } + } +} diff --git a/controllers/front/success.php b/controllers/front/success.php index 1892ae23e..4750c0169 100644 --- a/controllers/front/success.php +++ b/controllers/front/success.php @@ -1,179 +1,179 @@ - - * @copyright 2007-2019 PrestaShop SA and Contributors - * @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0) - * International Registered Trademark & Property of PrestaShop SA - */ - -use Mollie\Repository\OrderFeeRepository; - -class MollieSuccessModuleFrontController extends ModuleFrontController -{ - public $ssl = true; - public $id_cart; - public $id_module; - public $id_order; - public $reference; - public $secure_key; - /** @var OrderPresenter */ - public $order_presenter; - - /** - * Initialize order confirmation controller. - * - * @see FrontController::init() - */ - public function init() - { - parent::init(); - - if (true === (bool) Tools::getValue('free_order')) { - $this->checkFreeOrder(); - } - - $this->id_cart = (int) (Tools::getValue('id_cart', 0)); - - $redirectLink = 'index.php?controller=history'; - - $this->id_module = (int) (Tools::getValue('id_module', 0)); - $this->id_order = Order::getOrderByCartId((int) ($this->id_cart)); - $this->secure_key = Tools::getValue('key', false); - $order = new Order((int) ($this->id_order)); - - if (!$this->id_order || !$this->id_module || !$this->secure_key || empty($this->secure_key)) { - Tools::redirect($redirectLink . (Tools::isSubmit('slowvalidation') ? '&slowvalidation' : '')); - } - $this->reference = $order->reference; - if (!Validate::isLoadedObject($order) || $order->id_customer != $this->context->customer->id || $this->secure_key != $order->secure_key) { - Tools::redirect($redirectLink); - } - $module = Module::getInstanceById((int) ($this->id_module)); - if ($order->module != $module->name) { - Tools::redirect($redirectLink); - } - - $this->order_presenter = new OrderPresenter(); - } - - /** - * Assign template vars related to page content. - * - * @see FrontController::initContent() - */ - public function initContent() - { - $moduleName = Tools::getValue('module_name'); - - if (Configuration::isCatalogMode()) { - Tools::redirect('index.php'); - } - - $order = new Order(Order::getIdByCartId((int) ($this->id_cart))); - $presentedOrder = $this->order_presenter->present($order); - $register_form = $this - ->makeCustomerForm() - ->setGuestAllowed(false) - ->fillWith(Tools::getAllValues()); - - parent::initContent(); - - /** @var OrderFeeRepository $orderFeeRepo */ - $orderFeeRepo = $this->module->getContainer(OrderFeeRepository::class); - $orderFeeId = $orderFeeRepo->getOrderFeeIdByCartId($order->id_cart); - $fee = 0; - if ($orderFeeId) { - $orderFee = new MolOrderFee($orderFeeId); - $fee = $orderFee->order_fee; - } - - $this->context->smarty->assign(array( - 'HOOK_ORDER_CONFIRMATION' => $this->displayOrderConfirmation($order), - 'HOOK_PAYMENT_RETURN' => $this->displayPaymentReturn($order), - 'order' => $presentedOrder, - 'register_form' => $register_form, - 'link' => sprintf('module:%s/views/templates/front/order-confirmation-table.tpl', $moduleName), - 'payment_fee' => Tools::displayPrice($fee) - )); - - if ($this->context->customer->is_guest) { - /* If guest we clear the cookie for security reason */ - $this->context->customer->mylogout(); - } - $this->setTemplate( - sprintf('module:%s/views/templates/front/order_success.tpl', $moduleName) - ); - } - - /** - * Execute the hook displayPaymentReturn. - */ - public function displayPaymentReturn($order) - { - if (!Validate::isUnsignedId($this->id_module)) { - return false; - } - - return Hook::exec('displayPaymentReturn', array('order' => $order), $this->id_module); - } - - /** - * Execute the hook displayOrderConfirmation. - */ - public function displayOrderConfirmation($order) - { - return Hook::exec('displayOrderConfirmation', array('order' => $order)); - } - - /** - * Check if an order is free and create it. - */ - protected function checkFreeOrder() - { - $cart = $this->context->cart; - if ($cart->id_customer == 0 || $cart->id_address_delivery == 0 || $cart->id_address_invoice == 0) { - Tools::redirect($this->context->link->getPageLink('order')); - } - - $customer = new Customer($cart->id_customer); - if (!Validate::isLoadedObject($customer)) { - Tools::redirect($this->context->link->getPageLink('order')); - } - - $total = (float) $cart->getOrderTotal(true, Cart::BOTH); - if ($total > 0) { - Tools::redirect($this->context->link->getPageLink('order')); - } - - $order = new PaymentFree(); - $order->validateOrder( - $cart->id, - Configuration::get('PS_OS_PAYMENT'), - 0, - $this->trans('Free order', array(), 'Admin.Orderscustomers.Feature'), - null, - array(), - null, - false, - $cart->secure_key - ); - } -} + + * @copyright 2007-2019 PrestaShop SA and Contributors + * @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0) + * International Registered Trademark & Property of PrestaShop SA + */ + +use Mollie\Repository\OrderFeeRepository; + +class MollieSuccessModuleFrontController extends ModuleFrontController +{ + public $ssl = true; + public $id_cart; + public $id_module; + public $id_order; + public $reference; + public $secure_key; + /** @var OrderPresenter */ + public $order_presenter; + + /** + * Initialize order confirmation controller. + * + * @see FrontController::init() + */ + public function init() + { + parent::init(); + + if (true === (bool) Tools::getValue('free_order')) { + $this->checkFreeOrder(); + } + + $this->id_cart = (int) (Tools::getValue('id_cart', 0)); + + $redirectLink = 'index.php?controller=history'; + + $this->id_module = (int) (Tools::getValue('id_module', 0)); + $this->id_order = Order::getOrderByCartId((int) ($this->id_cart)); + $this->secure_key = Tools::getValue('key', false); + $order = new Order((int) ($this->id_order)); + + if (!$this->id_order || !$this->id_module || !$this->secure_key || empty($this->secure_key)) { + Tools::redirect($redirectLink . (Tools::isSubmit('slowvalidation') ? '&slowvalidation' : '')); + } + $this->reference = $order->reference; + if (!Validate::isLoadedObject($order) || $order->id_customer != $this->context->customer->id || $this->secure_key != $order->secure_key) { + Tools::redirect($redirectLink); + } + $module = Module::getInstanceById((int) ($this->id_module)); + if ($order->module != $module->name) { + Tools::redirect($redirectLink); + } + + $this->order_presenter = new OrderPresenter(); + } + + /** + * Assign template vars related to page content. + * + * @see FrontController::initContent() + */ + public function initContent() + { + $moduleName = Tools::getValue('module_name'); + + if (Configuration::isCatalogMode()) { + Tools::redirect('index.php'); + } + + $order = new Order(Order::getIdByCartId((int) ($this->id_cart))); + $presentedOrder = $this->order_presenter->present($order); + $register_form = $this + ->makeCustomerForm() + ->setGuestAllowed(false) + ->fillWith(Tools::getAllValues()); + + parent::initContent(); + + /** @var OrderFeeRepository $orderFeeRepo */ + $orderFeeRepo = $this->module->getContainer(OrderFeeRepository::class); + $orderFeeId = $orderFeeRepo->getOrderFeeIdByCartId($order->id_cart); + $fee = 0; + if ($orderFeeId) { + $orderFee = new MolOrderFee($orderFeeId); + $fee = $orderFee->order_fee; + } + + $this->context->smarty->assign(array( + 'HOOK_ORDER_CONFIRMATION' => $this->displayOrderConfirmation($order), + 'HOOK_PAYMENT_RETURN' => $this->displayPaymentReturn($order), + 'order' => $presentedOrder, + 'register_form' => $register_form, + 'link' => sprintf('module:%s/views/templates/front/order-confirmation-table.tpl', $moduleName), + 'payment_fee' => Tools::displayPrice($fee) + )); + + if ($this->context->customer->is_guest) { + /* If guest we clear the cookie for security reason */ + $this->context->customer->mylogout(); + } + $this->setTemplate( + sprintf('module:%s/views/templates/front/order_success.tpl', $moduleName) + ); + } + + /** + * Execute the hook displayPaymentReturn. + */ + public function displayPaymentReturn($order) + { + if (!Validate::isUnsignedId($this->id_module)) { + return false; + } + + return Hook::exec('displayPaymentReturn', array('order' => $order), $this->id_module); + } + + /** + * Execute the hook displayOrderConfirmation. + */ + public function displayOrderConfirmation($order) + { + return Hook::exec('displayOrderConfirmation', array('order' => $order)); + } + + /** + * Check if an order is free and create it. + */ + protected function checkFreeOrder() + { + $cart = $this->context->cart; + if ($cart->id_customer == 0 || $cart->id_address_delivery == 0 || $cart->id_address_invoice == 0) { + Tools::redirect($this->context->link->getPageLink('order')); + } + + $customer = new Customer($cart->id_customer); + if (!Validate::isLoadedObject($customer)) { + Tools::redirect($this->context->link->getPageLink('order')); + } + + $total = (float) $cart->getOrderTotal(true, Cart::BOTH); + if ($total > 0) { + Tools::redirect($this->context->link->getPageLink('order')); + } + + $order = new PaymentFree(); + $order->validateOrder( + $cart->id, + Configuration::get('PS_OS_PAYMENT'), + 0, + $this->trans('Free order', array(), 'Admin.Orderscustomers.Feature'), + null, + array(), + null, + false, + $cart->secure_key + ); + } +} diff --git a/controllers/front/webhook.php b/controllers/front/webhook.php index 988e1dcb6..deda8b4ba 100644 --- a/controllers/front/webhook.php +++ b/controllers/front/webhook.php @@ -1,382 +1,382 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -use _PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException; -use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment; -use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment as MolliePaymentAlias; -use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order as MollieOrderAlias; -use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory; -use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod; -use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus; -use _PhpScoper5ea00cc67502b\Mollie\Api\Types\RefundStatus; -use Mollie\Repository\PaymentMethodRepository; -use Mollie\Service\OrderStatusService; - -if (!defined('_PS_VERSION_')) { - exit; -} - -require_once dirname(__FILE__).'/../../mollie.php'; - -/** - * Class MollieReturnModuleFrontController - * @method setTemplate - * - * @property mixed context - * @property Mollie module - */ -class MollieWebhookModuleFrontController extends ModuleFrontController -{ - /** @var bool $ssl */ - public $ssl = true; - /** @var bool $display_column_left */ - public $display_column_left = false; - /** @var bool $display_column_right */ - public $display_column_right = false; - - /** - * Prevent displaying the maintenance page - * - * @return void - */ - protected function displayMaintenancePage() - { - } - - /** - * @throws Adapter_Exception - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws SmartyException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - * @throws ApiException - */ - public function initContent() - { - if (Configuration::get(Mollie\Config\Config::DEBUG_LOG_ALL)) { - PrestaShopLogger::addLog('Mollie incoming webhook: '.Tools::file_get_contents('php://input')); - } - - die($this->executeWebhook()); - } - - /** - * @return string - * - * @throws Adapter_Exception - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws SmartyException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - * @throws ApiException - */ - protected function executeWebhook() - { - if (Tools::getValue('testByMollie')) { - if (Configuration::get(Mollie\Config\Config::MOLLIE_DEBUG_LOG) >= Mollie\Config\Config::DEBUG_LOG_ERRORS) { - PrestaShopLogger::addLog(__METHOD__.' said: Mollie webhook tester successfully communicated with the shop.', Mollie\Config\Config::NOTICE); - } - - return 'OK'; - } - - $transactionId = Tools::getValue('id'); - if (Tools::substr($transactionId, 0, 3) === 'ord') { - $payment = $this->processTransaction($this->module->api->orders->get($transactionId, array('embed' => 'payments'))); - } else { - $payment = $this->processTransaction($this->module->api->payments->get($transactionId)); - } - if (is_string($payment)) { - return $payment; - } - - return 'OK'; - } - - /** - * @param MolliePaymentAlias|MollieOrderAlias $transaction - * - * @return string|MolliePaymentAlias Returns a single payment (in case of Orders API it returns the highest prio Payment object) or status string - * - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - * @throws ApiException - * @since 3.3.0 - * @since 3.3.2 Returns the ApiPayment / ApiOrder instead of OK string, NOT OK/NO ID stays the same - * @since 3.3.2 Returns the ApiPayment instead of ApiPayment / ApiOrder - */ - public function processTransaction($transaction) - { - if (empty($transaction)) { - if (Configuration::get(Mollie\Config\Config::MOLLIE_DEBUG_LOG) >= Mollie\Config\Config::DEBUG_LOG_ERRORS) { - PrestaShopLogger::addLog(__METHOD__.' said: Received webhook request without proper transaction ID.', Mollie\Config\Config::WARNING); - } - - return $this->module->l('Transaction failed', 'webhook'); - } - - // Ensure that we are dealing with a Payment object, in case of transaction ID or Payment object w/ Order ID, convert - if ($transaction instanceof MolliePaymentAlias) { - if (!empty($transaction->orderId) && Tools::substr($transaction->orderId, 0, 3) === 'ord') { - // Part of order - $transaction = $this->module->api->orders->get($transaction->orderId, array('embed' => 'payments')); - } else { - // Single payment - $apiPayment = $transaction; - } - } - - if (!isset($apiPayment)) { - $apiPayments = array(); - /** @var MollieOrderAlias $transaction */ - foreach ($transaction->_embedded->payments as $embeddedPayment) { - $apiPayment = ResourceFactory::createFromApiResult($embeddedPayment, new Payment($this->module->api)); - $apiPayments[] = $apiPayment; - unset($apiPayment); - } - if (count($apiPayments) === 1) { - $apiPayment = $apiPayments[0]; - } else { - // In case of multiple payments, the one with the paid status is leading - foreach ($apiPayments as $payment) { - if (in_array($payment->status, array(PaymentStatus::STATUS_PAID, PaymentStatus::STATUS_AUTHORIZED))) { - $apiPayment = $payment; - break; - } - } - - // No paid/authorized payments found, looking for payments with a final status - if (!isset($apiPayment)) { - foreach ($apiPayments as $payment) { - if (in_array($payment->status, array( - PaymentStatus::STATUS_CANCELED, - PaymentStatus::STATUS_FAILED, - PaymentStatus::STATUS_EXPIRED, - ))) { - $apiPayment = $payment; - break; - } - } - } - - // In case there is no final payments, we are going to look for any pending payments - if (!isset($apiPayment)) { - foreach ($apiPayments as $payment) { - if (in_array($payment->status, array( - PaymentStatus::STATUS_PENDING, - ))) { - $apiPayment = $payment; - break; - } - } - } - } - if (isset($apiPayment)) { - $apiPayment->metadata = $transaction->metadata; - } - } - - if (!isset($apiPayment)) { - return $this->module->l('Transaction failed', 'webhook'); - } - - /** @var PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); - $psPayment = $paymentMethodRepo->getPaymentBy('transaction_id', $transaction->id); - $this->setCountryContextIfNotSet($apiPayment); - $orderId = Order::getOrderByCartId((int) $apiPayment->metadata->cart_id); - /** @var OrderStatusService $orderStatusService */ - $orderStatusService = $this->module->getContainer(OrderStatusService::class); - $cart = new Cart($apiPayment->metadata->cart_id); - if ($apiPayment->metadata->cart_id) { - if ($apiPayment->hasRefunds() || $apiPayment->hasChargebacks()) { - if (isset($apiPayment->settlementAmount->value, $apiPayment->amountRefunded->value) - && (float) $apiPayment->amountRefunded->value >= (float) $apiPayment->settlementAmount->value - ) { - $orderStatusService->setOrderStatus($orderId, RefundStatus::STATUS_REFUNDED); - } else { - $orderStatusService->setOrderStatus($orderId, Mollie\Config\Config::PARTIAL_REFUND_CODE); - } - } elseif ($psPayment['method'] === PaymentMethod::BANKTRANSFER - && $psPayment['bank_status'] === PaymentStatus::STATUS_OPEN - && $apiPayment->status === PaymentStatus::STATUS_PAID - ) { - $order = new Order($orderId); - $order->payment = isset(Mollie\Config\Config::$methods[$apiPayment->method]) - ? Mollie\Config\Config::$methods[$apiPayment->method] - : $this->module->displayName; - $order->update(); - - $orderStatusService->setOrderStatus($orderId, $apiPayment->status); - } elseif ($psPayment['method'] !== PaymentMethod::BANKTRANSFER - && (empty($psPayment['order_id']) || !Order::getCartIdStatic($psPayment['order_id'])) - && ($apiPayment->isPaid() || $apiPayment->isAuthorized()) - && Tools::encrypt($cart->secure_key) === $apiPayment->metadata->secure_key - ) { - $paymentStatus = (int) Mollie\Config\Config::getStatuses()[$apiPayment->status]; - - if ($paymentStatus < 1) { - $paymentStatus = Configuration::get('PS_OS_PAYMENT'); - } - $orderReference = isset($apiPayment->metadata->order_reference) ? $apiPayment->metadata->order_reference : ''; - - $this->module->currentOrderReference = $orderReference; - $this->module->validateOrder( - (int) $apiPayment->metadata->cart_id, - $paymentStatus, - $apiPayment->amount->value, - isset(Mollie\Config\Config::$methods[$apiPayment->method]) ? Mollie\Config\Config::$methods[$apiPayment->method] : 'Mollie', - null, - array(), - null, - false, - $cart->secure_key - ); - - $orderId = Order::getOrderByCartId((int) $apiPayment->metadata->cart_id); - } - } - - // Store status in database - - $this->saveOrderTransactionData($apiPayment->id, $apiPayment->method, $orderId); - - if (!$this->savePaymentStatus($transaction->id, $apiPayment->status, $orderId)) { - if (Configuration::get(Mollie\Config\Config::MOLLIE_DEBUG_LOG) >= Mollie\Config\Config::DEBUG_LOG_ERRORS) { - PrestaShopLogger::addLog(__METHOD__.' said: Could not save Mollie payment status for transaction "'.$transaction->id.'". Reason: '.Db::getInstance()->getMsgError(), Mollie\Config\Config::WARNING); - } - } - - // Log successful webhook requests in extended log mode only - if (Configuration::get(Mollie\Config\Config::MOLLIE_DEBUG_LOG) == Mollie\Config\Config::DEBUG_LOG_ALL) { - PrestaShopLogger::addLog(__METHOD__.' said: Received webhook request for order '.(int) $orderId.' / transaction '.$transaction->id, Mollie\Config\Config::NOTICE); - } - Hook::exec('actionOrderStatusUpdate', array('newOrderStatus' => (int) Mollie\Config\Config::getStatuses()[$apiPayment->status], 'id_order' => (int) $orderId)); - - return $apiPayment; - } - - /** - * Retrieves the OrderPayment object, created at validateOrder. And add transaction data. - * - * @param string $molliePaymentId - * @param string $molliePaymentMethod - * @param int $orderId - * - * @return void - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ - protected function saveOrderTransactionData($molliePaymentId, $molliePaymentMethod, $orderId) - { - // retrieve ALL payments of order. - // in the case of a cancel or expired on banktransfer, this will fire too. - // if no OrderPayment objects is retrieved in the collection, do nothing. - $order = new Order((int) $orderId); - $collection = OrderPayment::getByOrderReference($order->reference); - if (count($collection) > 0) { - /** @var OrderPayment $orderPayment */ - $orderPayment = $collection[0]; - - // for older versions (1.5) , we check if it hasn't been filled yet. - if (!$orderPayment->transaction_id) { - $orderPayment->transaction_id = $molliePaymentId; - $orderPayment->payment_method = $molliePaymentMethod; - $orderPayment->update(); - } - } - } - - /** - * @param string $transactionId - * @param int $status - * @param int $orderId - * - * @return bool - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ - protected function savePaymentStatus($transactionId, $status, $orderId) - { - try { - return Db::getInstance()->update( - 'mollie_payments', - array( - 'updated_at' => array('type' => 'sql', 'value' => 'NOW()'), - 'bank_status' => pSQL($status), - 'order_id' => (int) $orderId, - ), - '`transaction_id` = \''.pSQL($transactionId).'\'' - ); - } catch (PrestaShopDatabaseException $e) { - /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->module->getContainer(\Mollie\Repository\PaymentMethodRepository::class); - $paymentMethodRepo->tryAddOrderReferenceColumn(); - throw $e; - } - } - - /** - * (Re)sets the controller country context. - * When Prestashop receives a call from Mollie (without context) - * Prestashop always has default context to fall back on, so context->country - * is allways Set before executing any controller methods - * - * @param MolliePaymentAlias $payment - * - * @throws Adapter_Exception - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws \PrestaShop\PrestaShop\Adapter\CoreException - */ - protected function setCountryContextIfNotSet($payment) - { - if (empty($this->context->country) || !$this->context->country->active) { - if ($payment->metadata->cart_id) { - $cart = new Cart((int) $payment->metadata->cart_id); - if (!empty($cart)) { - $address = new Address($cart->id_address_delivery); - if (!empty($address)) { - $country = new Country($address->id_country); - if (!empty($country)) { - $this->context->country = $country; - } - } - } - } - } - } -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +use _PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException; +use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment; +use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment as MolliePaymentAlias; +use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order as MollieOrderAlias; +use _PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory; +use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod; +use _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus; +use _PhpScoper5ea00cc67502b\Mollie\Api\Types\RefundStatus; +use Mollie\Repository\PaymentMethodRepository; +use Mollie\Service\OrderStatusService; + +if (!defined('_PS_VERSION_')) { + exit; +} + +require_once dirname(__FILE__).'/../../mollie.php'; + +/** + * Class MollieReturnModuleFrontController + * @method setTemplate + * + * @property mixed context + * @property Mollie module + */ +class MollieWebhookModuleFrontController extends ModuleFrontController +{ + /** @var bool $ssl */ + public $ssl = true; + /** @var bool $display_column_left */ + public $display_column_left = false; + /** @var bool $display_column_right */ + public $display_column_right = false; + + /** + * Prevent displaying the maintenance page + * + * @return void + */ + protected function displayMaintenancePage() + { + } + + /** + * @throws Adapter_Exception + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws SmartyException + * @throws \PrestaShop\PrestaShop\Adapter\CoreException + * @throws ApiException + */ + public function initContent() + { + if (Configuration::get(Mollie\Config\Config::DEBUG_LOG_ALL)) { + PrestaShopLogger::addLog('Mollie incoming webhook: '.Tools::file_get_contents('php://input')); + } + + die($this->executeWebhook()); + } + + /** + * @return string + * + * @throws Adapter_Exception + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws SmartyException + * @throws \PrestaShop\PrestaShop\Adapter\CoreException + * @throws ApiException + */ + protected function executeWebhook() + { + if (Tools::getValue('testByMollie')) { + if (Configuration::get(Mollie\Config\Config::MOLLIE_DEBUG_LOG) >= Mollie\Config\Config::DEBUG_LOG_ERRORS) { + PrestaShopLogger::addLog(__METHOD__.' said: Mollie webhook tester successfully communicated with the shop.', Mollie\Config\Config::NOTICE); + } + + return 'OK'; + } + + $transactionId = Tools::getValue('id'); + if (Tools::substr($transactionId, 0, 3) === 'ord') { + $payment = $this->processTransaction($this->module->api->orders->get($transactionId, array('embed' => 'payments'))); + } else { + $payment = $this->processTransaction($this->module->api->payments->get($transactionId)); + } + if (is_string($payment)) { + return $payment; + } + + return 'OK'; + } + + /** + * @param MolliePaymentAlias|MollieOrderAlias $transaction + * + * @return string|MolliePaymentAlias Returns a single payment (in case of Orders API it returns the highest prio Payment object) or status string + * + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws \PrestaShop\PrestaShop\Adapter\CoreException + * @throws ApiException + * @since 3.3.0 + * @since 3.3.2 Returns the ApiPayment / ApiOrder instead of OK string, NOT OK/NO ID stays the same + * @since 3.3.2 Returns the ApiPayment instead of ApiPayment / ApiOrder + */ + public function processTransaction($transaction) + { + if (empty($transaction)) { + if (Configuration::get(Mollie\Config\Config::MOLLIE_DEBUG_LOG) >= Mollie\Config\Config::DEBUG_LOG_ERRORS) { + PrestaShopLogger::addLog(__METHOD__.' said: Received webhook request without proper transaction ID.', Mollie\Config\Config::WARNING); + } + + return $this->module->l('Transaction failed', 'webhook'); + } + + // Ensure that we are dealing with a Payment object, in case of transaction ID or Payment object w/ Order ID, convert + if ($transaction instanceof MolliePaymentAlias) { + if (!empty($transaction->orderId) && Tools::substr($transaction->orderId, 0, 3) === 'ord') { + // Part of order + $transaction = $this->module->api->orders->get($transaction->orderId, array('embed' => 'payments')); + } else { + // Single payment + $apiPayment = $transaction; + } + } + + if (!isset($apiPayment)) { + $apiPayments = array(); + /** @var MollieOrderAlias $transaction */ + foreach ($transaction->_embedded->payments as $embeddedPayment) { + $apiPayment = ResourceFactory::createFromApiResult($embeddedPayment, new Payment($this->module->api)); + $apiPayments[] = $apiPayment; + unset($apiPayment); + } + if (count($apiPayments) === 1) { + $apiPayment = $apiPayments[0]; + } else { + // In case of multiple payments, the one with the paid status is leading + foreach ($apiPayments as $payment) { + if (in_array($payment->status, array(PaymentStatus::STATUS_PAID, PaymentStatus::STATUS_AUTHORIZED))) { + $apiPayment = $payment; + break; + } + } + + // No paid/authorized payments found, looking for payments with a final status + if (!isset($apiPayment)) { + foreach ($apiPayments as $payment) { + if (in_array($payment->status, array( + PaymentStatus::STATUS_CANCELED, + PaymentStatus::STATUS_FAILED, + PaymentStatus::STATUS_EXPIRED, + ))) { + $apiPayment = $payment; + break; + } + } + } + + // In case there is no final payments, we are going to look for any pending payments + if (!isset($apiPayment)) { + foreach ($apiPayments as $payment) { + if (in_array($payment->status, array( + PaymentStatus::STATUS_PENDING, + ))) { + $apiPayment = $payment; + break; + } + } + } + } + if (isset($apiPayment)) { + $apiPayment->metadata = $transaction->metadata; + } + } + + if (!isset($apiPayment)) { + return $this->module->l('Transaction failed', 'webhook'); + } + + /** @var PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->module->getContainer(PaymentMethodRepository::class); + $psPayment = $paymentMethodRepo->getPaymentBy('transaction_id', $transaction->id); + $this->setCountryContextIfNotSet($apiPayment); + $orderId = Order::getOrderByCartId((int) $apiPayment->metadata->cart_id); + /** @var OrderStatusService $orderStatusService */ + $orderStatusService = $this->module->getContainer(OrderStatusService::class); + $cart = new Cart($apiPayment->metadata->cart_id); + if ($apiPayment->metadata->cart_id) { + if ($apiPayment->hasRefunds() || $apiPayment->hasChargebacks()) { + if (isset($apiPayment->settlementAmount->value, $apiPayment->amountRefunded->value) + && (float) $apiPayment->amountRefunded->value >= (float) $apiPayment->settlementAmount->value + ) { + $orderStatusService->setOrderStatus($orderId, RefundStatus::STATUS_REFUNDED); + } else { + $orderStatusService->setOrderStatus($orderId, Mollie\Config\Config::PARTIAL_REFUND_CODE); + } + } elseif ($psPayment['method'] === PaymentMethod::BANKTRANSFER + && $psPayment['bank_status'] === PaymentStatus::STATUS_OPEN + && $apiPayment->status === PaymentStatus::STATUS_PAID + ) { + $order = new Order($orderId); + $order->payment = isset(Mollie\Config\Config::$methods[$apiPayment->method]) + ? Mollie\Config\Config::$methods[$apiPayment->method] + : $this->module->displayName; + $order->update(); + + $orderStatusService->setOrderStatus($orderId, $apiPayment->status); + } elseif ($psPayment['method'] !== PaymentMethod::BANKTRANSFER + && (empty($psPayment['order_id']) || !Order::getCartIdStatic($psPayment['order_id'])) + && ($apiPayment->isPaid() || $apiPayment->isAuthorized()) + && Tools::encrypt($cart->secure_key) === $apiPayment->metadata->secure_key + ) { + $paymentStatus = (int) Mollie\Config\Config::getStatuses()[$apiPayment->status]; + + if ($paymentStatus < 1) { + $paymentStatus = Configuration::get('PS_OS_PAYMENT'); + } + $orderReference = isset($apiPayment->metadata->order_reference) ? $apiPayment->metadata->order_reference : ''; + + $this->module->currentOrderReference = $orderReference; + $this->module->validateOrder( + (int) $apiPayment->metadata->cart_id, + $paymentStatus, + $apiPayment->amount->value, + isset(Mollie\Config\Config::$methods[$apiPayment->method]) ? Mollie\Config\Config::$methods[$apiPayment->method] : 'Mollie', + null, + array(), + null, + false, + $cart->secure_key + ); + + $orderId = Order::getOrderByCartId((int) $apiPayment->metadata->cart_id); + } + } + + // Store status in database + + $this->saveOrderTransactionData($apiPayment->id, $apiPayment->method, $orderId); + + if (!$this->savePaymentStatus($transaction->id, $apiPayment->status, $orderId)) { + if (Configuration::get(Mollie\Config\Config::MOLLIE_DEBUG_LOG) >= Mollie\Config\Config::DEBUG_LOG_ERRORS) { + PrestaShopLogger::addLog(__METHOD__.' said: Could not save Mollie payment status for transaction "'.$transaction->id.'". Reason: '.Db::getInstance()->getMsgError(), Mollie\Config\Config::WARNING); + } + } + + // Log successful webhook requests in extended log mode only + if (Configuration::get(Mollie\Config\Config::MOLLIE_DEBUG_LOG) == Mollie\Config\Config::DEBUG_LOG_ALL) { + PrestaShopLogger::addLog(__METHOD__.' said: Received webhook request for order '.(int) $orderId.' / transaction '.$transaction->id, Mollie\Config\Config::NOTICE); + } + Hook::exec('actionOrderStatusUpdate', array('newOrderStatus' => (int) Mollie\Config\Config::getStatuses()[$apiPayment->status], 'id_order' => (int) $orderId)); + + return $apiPayment; + } + + /** + * Retrieves the OrderPayment object, created at validateOrder. And add transaction data. + * + * @param string $molliePaymentId + * @param string $molliePaymentMethod + * @param int $orderId + * + * @return void + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ + protected function saveOrderTransactionData($molliePaymentId, $molliePaymentMethod, $orderId) + { + // retrieve ALL payments of order. + // in the case of a cancel or expired on banktransfer, this will fire too. + // if no OrderPayment objects is retrieved in the collection, do nothing. + $order = new Order((int) $orderId); + $collection = OrderPayment::getByOrderReference($order->reference); + if (count($collection) > 0) { + /** @var OrderPayment $orderPayment */ + $orderPayment = $collection[0]; + + // for older versions (1.5) , we check if it hasn't been filled yet. + if (!$orderPayment->transaction_id) { + $orderPayment->transaction_id = $molliePaymentId; + $orderPayment->payment_method = $molliePaymentMethod; + $orderPayment->update(); + } + } + } + + /** + * @param string $transactionId + * @param int $status + * @param int $orderId + * + * @return bool + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ + protected function savePaymentStatus($transactionId, $status, $orderId) + { + try { + return Db::getInstance()->update( + 'mollie_payments', + array( + 'updated_at' => array('type' => 'sql', 'value' => 'NOW()'), + 'bank_status' => pSQL($status), + 'order_id' => (int) $orderId, + ), + '`transaction_id` = \''.pSQL($transactionId).'\'' + ); + } catch (PrestaShopDatabaseException $e) { + /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->module->getContainer(\Mollie\Repository\PaymentMethodRepository::class); + $paymentMethodRepo->tryAddOrderReferenceColumn(); + throw $e; + } + } + + /** + * (Re)sets the controller country context. + * When Prestashop receives a call from Mollie (without context) + * Prestashop always has default context to fall back on, so context->country + * is allways Set before executing any controller methods + * + * @param MolliePaymentAlias $payment + * + * @throws Adapter_Exception + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws \PrestaShop\PrestaShop\Adapter\CoreException + */ + protected function setCountryContextIfNotSet($payment) + { + if (empty($this->context->country) || !$this->context->country->active) { + if ($payment->metadata->cart_id) { + $cart = new Cart((int) $payment->metadata->cart_id); + if (!empty($cart)) { + $address = new Address($cart->id_address_delivery); + if (!empty($address)) { + $country = new Country($address->id_country); + if (!empty($country)) { + $this->context->country = $country; + } + } + } + } + } + } +} diff --git a/controllers/index.php b/controllers/index.php index 729abf520..a950d02f4 100644 --- a/controllers/index.php +++ b/controllers/index.php @@ -1,11 +1,11 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -$countries = json_decode('[{"translations":{"br":"Afeganistão","pt":"Afeganistão","nl":"Afghanistan","hr":"Afganistan","fa":"اÙغانستان","de":"Afghanistan","es":"Afganistán","fr":"Afghanistan","ja":"アフガニスタン","it":"Afghanistan"},"name":"Afghanistan","alpha2Code":"AF"},{"translations":{"br":"Ilhas de Aland","pt":"Ilhas de Aland","nl":"Ã…landeilanden","hr":"Ã…landski otoci","fa":"جزایر الند","de":"Ã…land","es":"Alandia","fr":"Ã…land","ja":"オーランド諸島","it":"Isole Aland"},"name":"Ã…land Islands","alpha2Code":"AX"},{"translations":{"br":"Albânia","pt":"Albânia","nl":"Albanië","hr":"Albanija","fa":"آلبانی","de":"Albanien","es":"Albania","fr":"Albanie","ja":"アルãƒãƒ‹ã‚¢","it":"Albania"},"name":"Albania","alpha2Code":"AL"},{"translations":{"br":"Argélia","pt":"Argélia","nl":"Algerije","hr":"Alžir","fa":"الجزایر","de":"Algerien","es":"Argelia","fr":"Algérie","ja":"アルジェリア","it":"Algeria"},"name":"Algeria","alpha2Code":"DZ"},{"translations":{"br":"Samoa Americana","pt":"Samoa Americana","nl":"Amerikaans Samoa","hr":"AmeriÄka Samoa","fa":"ساموآی آمریکا","de":"Amerikanisch-Samoa","es":"Samoa Americana","fr":"Samoa américaines","ja":"アメリカ領サモア","it":"Samoa Americane"},"name":"American Samoa","alpha2Code":"AS"},{"translations":{"br":"Andorra","pt":"Andorra","nl":"Andorra","hr":"Andora","fa":"آندورا","de":"Andorra","es":"Andorra","fr":"Andorre","ja":"アンドラ","it":"Andorra"},"name":"Andorra","alpha2Code":"AD"},{"translations":{"br":"Angola","pt":"Angola","nl":"Angola","hr":"Angola","fa":"آنگولا","de":"Angola","es":"Angola","fr":"Angola","ja":"アンゴラ","it":"Angola"},"name":"Angola","alpha2Code":"AO"},{"translations":{"br":"Anguila","pt":"Anguila","nl":"Anguilla","hr":"Angvila","fa":"آنگویلا","de":"Anguilla","es":"Anguilla","fr":"Anguilla","ja":"アンギラ","it":"Anguilla"},"name":"Anguilla","alpha2Code":"AI"},{"translations":{"br":"Antártida","pt":"Antárctida","nl":"Antarctica","hr":"Antarktika","fa":"جنوبگان","de":"Antarktika","es":"Antártida","fr":"Antarctique","ja":"å—極大陸","it":"Antartide"},"name":"Antarctica","alpha2Code":"AQ"},{"translations":{"br":"Antígua e Barbuda","pt":"Antígua e Barbuda","nl":"Antigua en Barbuda","hr":"Antigva i Barbuda","fa":"آنتیگوا Ùˆ باربودا","de":"Antigua und Barbuda","es":"Antigua y Barbuda","fr":"Antigua-et-Barbuda","ja":"アンティグア・ãƒãƒ¼ãƒ–ーダ","it":"Antigua e Barbuda"},"name":"Antigua and Barbuda","alpha2Code":"AG"},{"translations":{"br":"Argentina","pt":"Argentina","nl":"Argentinië","hr":"Argentina","fa":"آرژانتین","de":"Argentinien","es":"Argentina","fr":"Argentine","ja":"アルゼンãƒãƒ³","it":"Argentina"},"name":"Argentina","alpha2Code":"AR"},{"translations":{"br":"Armênia","pt":"Arménia","nl":"Armenië","hr":"Armenija","fa":"ارمنستان","de":"Armenien","es":"Armenia","fr":"Arménie","ja":"アルメニア","it":"Armenia"},"name":"Armenia","alpha2Code":"AM"},{"translations":{"br":"Aruba","pt":"Aruba","nl":"Aruba","hr":"Aruba","fa":"آروبا","de":"Aruba","es":"Aruba","fr":"Aruba","ja":"アルãƒ","it":"Aruba"},"name":"Aruba","alpha2Code":"AW"},{"translations":{"br":"Austrália","pt":"Austrália","nl":"Australië","hr":"Australija","fa":"استرالیا","de":"Australien","es":"Australia","fr":"Australie","ja":"オーストラリア","it":"Australia"},"name":"Australia","alpha2Code":"AU"},{"translations":{"br":"áustria","pt":"áustria","nl":"Oostenrijk","hr":"Austrija","fa":"اتریش","de":"Österreich","es":"Austria","fr":"Autriche","ja":"オーストリア","it":"Austria"},"name":"Austria","alpha2Code":"AT"},{"translations":{"br":"Azerbaijão","pt":"Azerbaijão","nl":"Azerbeidzjan","hr":"Azerbajdžan","fa":"آذربایجان","de":"Aserbaidschan","es":"Azerbaiyán","fr":"Azerbaïdjan","ja":"アゼルãƒã‚¤ã‚¸ãƒ£ãƒ³","it":"Azerbaijan"},"name":"Azerbaijan","alpha2Code":"AZ"},{"translations":{"br":"Bahamas","pt":"Baamas","nl":"Bahama’s","hr":"Bahami","fa":"باهاما","de":"Bahamas","es":"Bahamas","fr":"Bahamas","ja":"ãƒãƒãƒž","it":"Bahamas"},"name":"Bahamas","alpha2Code":"BS"},{"translations":{"br":"Bahrein","pt":"Barém","nl":"Bahrein","hr":"Bahrein","fa":"بحرین","de":"Bahrain","es":"Bahrein","fr":"Bahreïn","ja":"ãƒãƒ¼ãƒ¬ãƒ¼ãƒ³","it":"Bahrein"},"name":"Bahrain","alpha2Code":"BH"},{"translations":{"br":"Bangladesh","pt":"Bangladeche","nl":"Bangladesh","hr":"BangladeÅ¡","fa":"بنگلادش","de":"Bangladesch","es":"Bangladesh","fr":"Bangladesh","ja":"ãƒãƒ³ã‚°ãƒ©ãƒ‡ã‚·ãƒ¥","it":"Bangladesh"},"name":"Bangladesh","alpha2Code":"BD"},{"translations":{"br":"Barbados","pt":"Barbados","nl":"Barbados","hr":"Barbados","fa":"باربادوس","de":"Barbados","es":"Barbados","fr":"Barbade","ja":"ãƒãƒ«ãƒãƒ‰ã‚¹","it":"Barbados"},"name":"Barbados","alpha2Code":"BB"},{"translations":{"br":"Bielorrússia","pt":"Bielorrússia","nl":"Wit-Rusland","hr":"Bjelorusija","fa":"بلاروس","de":"Weißrussland","es":"Bielorrusia","fr":"Biélorussie","ja":"ベラルーシ","it":"Bielorussia"},"name":"Belarus","alpha2Code":"BY"},{"translations":{"br":"Bélgica","pt":"Bélgica","nl":"België","hr":"Belgija","fa":"بلژیک","de":"Belgien","es":"Bélgica","fr":"Belgique","ja":"ベルギー","it":"Belgio"},"name":"Belgium","alpha2Code":"BE"},{"translations":{"br":"Belize","pt":"Belize","nl":"Belize","hr":"Belize","fa":"بلیز","de":"Belize","es":"Belice","fr":"Belize","ja":"ベリーズ","it":"Belize"},"name":"Belize","alpha2Code":"BZ"},{"translations":{"br":"Benin","pt":"Benim","nl":"Benin","hr":"Benin","fa":"بنین","de":"Benin","es":"Benín","fr":"Bénin","ja":"ベナン","it":"Benin"},"name":"Benin","alpha2Code":"BJ"},{"translations":{"br":"Bermudas","pt":"Bermudas","nl":"Bermuda","hr":"Bermudi","fa":"برمودا","de":"Bermuda","es":"Bermudas","fr":"Bermudes","ja":"ãƒãƒŸãƒ¥ãƒ¼ãƒ€","it":"Bermuda"},"name":"Bermuda","alpha2Code":"BM"},{"translations":{"br":"Butão","pt":"Butão","nl":"Bhutan","hr":"Butan","fa":"بوتان","de":"Bhutan","es":"Bután","fr":"Bhoutan","ja":"ブータン","it":"Bhutan"},"name":"Bhutan","alpha2Code":"BT"},{"translations":{"br":"Bolívia","pt":"Bolívia","nl":"Bolivia","hr":"Bolivija","fa":"بولیوی","de":"Bolivien","es":"Bolivia","fr":"Bolivie","ja":"ボリビア多民æ—国","it":"Bolivia"},"name":"Bolivia (Plurinational State of)","alpha2Code":"BO"},{"translations":{"br":"Bonaire","pt":"Bonaire","fa":"بونیر","de":"Bonaire, Sint Eustatius und Saba","fr":"Bonaire, Saint-Eustache et Saba","it":"Bonaire, Saint-Eustache e Saba"},"name":"Bonaire, Sint Eustatius and Saba","alpha2Code":"BQ"},{"translations":{"br":"Bósnia e Herzegovina","pt":"Bósnia e Herzegovina","nl":"Bosnië en Herzegovina","hr":"Bosna i Hercegovina","fa":"بوسنی Ùˆ هرزگوین","de":"Bosnien und Herzegowina","es":"Bosnia y Herzegovina","fr":"Bosnie-Herzégovine","ja":"ボスニア・ヘルツェゴビナ","it":"Bosnia ed Erzegovina"},"name":"Bosnia and Herzegovina","alpha2Code":"BA"},{"translations":{"br":"Botsuana","pt":"Botsuana","nl":"Botswana","hr":"Bocvana","fa":"بوتسوانا","de":"Botswana","es":"Botswana","fr":"Botswana","ja":"ボツワナ","it":"Botswana"},"name":"Botswana","alpha2Code":"BW"},{"translations":{"br":"Ilha Bouvet","pt":"Ilha Bouvet","nl":"Bouveteiland","hr":"Otok Bouvet","fa":"جزیره بووه","de":"Bouvetinsel","es":"Isla Bouvet","fr":"ÃŽle Bouvet","ja":"ブーベ島","it":"Isola Bouvet"},"name":"Bouvet Island","alpha2Code":"BV"},{"translations":{"br":"Brasil","pt":"Brasil","nl":"Brazilië","hr":"Brazil","fa":"برزیل","de":"Brasilien","es":"Brasil","fr":"Brésil","ja":"ブラジル","it":"Brasile"},"name":"Brazil","alpha2Code":"BR"},{"translations":{"br":"Território Britânico do Oceano íÃdico","pt":"Território Britânico do Oceano Ãndico","nl":"Britse Gebieden in de Indische Oceaan","hr":"Britanski Indijskooceanski teritorij","fa":"قلمرو بریتانیا در اقیانوس هند","de":"Britisches Territorium im Indischen Ozean","es":"Territorio Británico del Océano Ãndico","fr":"Territoire britannique de l\'océan Indien","ja":"イギリス領インド洋地域","it":"Territorio britannico dell\'oceano indiano"},"name":"British Indian Ocean Territory","alpha2Code":"IO"},{"translations":{"br":"Ilhas Menores Distantes dos Estados Unidos","pt":"Ilhas Menores Distantes dos Estados Unidos","nl":"Kleine afgelegen eilanden van de Verenigde Staten","hr":"Mali udaljeni otoci SAD-a","fa":"جزایر Ú©ÙˆÚ†Ú© حاشیه‌ای ایالات متحده آمریکا","de":"Kleinere Inselbesitzungen der Vereinigten Staaten","es":"Islas Ultramarinas Menores de Estados Unidos","fr":"ÃŽles mineures éloignées des États-Unis","ja":"åˆè¡†å›½é ˜æœ‰å°é›¢å³¶","it":"Isole minori esterne degli Stati Uniti d\'America"},"name":"United States Minor Outlying Islands","alpha2Code":"UM"},{"translations":{"br":"Ilhas Virgens Britânicas","pt":"Ilhas Virgens Britânicas","nl":"Britse Maagdeneilanden","hr":"Britanski DjeviÄanski Otoci","fa":"جزایر ویرجین بریتانیا","de":"Britische Jungferninseln","es":"Islas Vírgenes del Reino Unido","fr":"ÃŽles Vierges britanniques","ja":"イギリス領ヴァージン諸島","it":"Isole Vergini Britanniche"},"name":"Virgin Islands (British)","alpha2Code":"VG"},{"translations":{"br":"Ilhas Virgens Americanas","pt":"Ilhas Virgens Americanas","nl":"Verenigde Staten Maagdeneilanden","fa":"جزایر ویرجین آمریکا","de":"Amerikanische Jungferninseln","es":"Islas Vírgenes de los Estados Unidos","fr":"ÃŽles Vierges des États-Unis","ja":"アメリカ領ヴァージン諸島","it":"Isole Vergini americane"},"name":"Virgin Islands (U.S.)","alpha2Code":"VI"},{"translations":{"br":"Brunei","pt":"Brunei","nl":"Brunei","hr":"Brunej","fa":"برونئی","de":"Brunei","es":"Brunei","fr":"Brunei","ja":"ブルãƒã‚¤ãƒ»ãƒ€ãƒ«ã‚µãƒ©ãƒ¼ãƒ ","it":"Brunei"},"name":"Brunei Darussalam","alpha2Code":"BN"},{"translations":{"br":"Bulgária","pt":"Bulgária","nl":"Bulgarije","hr":"Bugarska","fa":"بلغارستان","de":"Bulgarien","es":"Bulgaria","fr":"Bulgarie","ja":"ブルガリア","it":"Bulgaria"},"name":"Bulgaria","alpha2Code":"BG"},{"translations":{"br":"Burkina Faso","pt":"Burquina Faso","nl":"Burkina Faso","hr":"Burkina Faso","fa":"بورکیناÙاسو","de":"Burkina Faso","es":"Burkina Faso","fr":"Burkina Faso","ja":"ブルキナファソ","it":"Burkina Faso"},"name":"Burkina Faso","alpha2Code":"BF"},{"translations":{"br":"Burundi","pt":"Burúndi","nl":"Burundi","hr":"Burundi","fa":"بوروندی","de":"Burundi","es":"Burundi","fr":"Burundi","ja":"ブルンジ","it":"Burundi"},"name":"Burundi","alpha2Code":"BI"},{"translations":{"br":"Camboja","pt":"Camboja","nl":"Cambodja","hr":"Kambodža","fa":"کامبوج","de":"Kambodscha","es":"Camboya","fr":"Cambodge","ja":"カンボジア","it":"Cambogia"},"name":"Cambodia","alpha2Code":"KH"},{"translations":{"br":"Camarões","pt":"Camarões","nl":"Kameroen","hr":"Kamerun","fa":"کامرون","de":"Kamerun","es":"Camerún","fr":"Cameroun","ja":"カメルーン","it":"Camerun"},"name":"Cameroon","alpha2Code":"CM"},{"translations":{"br":"Canadá","pt":"Canadá","nl":"Canada","hr":"Kanada","fa":"کانادا","de":"Kanada","es":"Canadá","fr":"Canada","ja":"カナダ","it":"Canada"},"name":"Canada","alpha2Code":"CA"},{"translations":{"br":"Cabo Verde","pt":"Cabo Verde","nl":"Kaapverdië","hr":"Zelenortska Republika","fa":"کیپ ورد","de":"Kap Verde","es":"Cabo Verde","fr":"Cap Vert","ja":"カーボベルデ","it":"Capo Verde"},"name":"Cabo Verde","alpha2Code":"CV"},{"translations":{"br":"Ilhas Cayman","pt":"Ilhas Caimão","nl":"Caymaneilanden","hr":"Kajmanski otoci","fa":"جزایر کیمن","de":"Kaimaninseln","es":"Islas Caimán","fr":"ÃŽles Caïmans","ja":"ケイマン諸島","it":"Isole Cayman"},"name":"Cayman Islands","alpha2Code":"KY"},{"translations":{"br":"República Centro-Africana","pt":"República Centro-Africana","nl":"Centraal-Afrikaanse Republiek","hr":"SrednjoafriÄka Republika","fa":"جمهوری Ø¢Ùریقای مرکزی","de":"Zentralafrikanische Republik","es":"República Centroafricana","fr":"République centrafricaine","ja":"中央アフリカ共和国","it":"Repubblica Centrafricana"},"name":"Central African Republic","alpha2Code":"CF"},{"translations":{"br":"Chade","pt":"Chade","nl":"Tsjaad","hr":"ÄŒad","fa":"چاد","de":"Tschad","es":"Chad","fr":"Tchad","ja":"ãƒãƒ£ãƒ‰","it":"Ciad"},"name":"Chad","alpha2Code":"TD"},{"translations":{"br":"Chile","pt":"Chile","nl":"Chili","hr":"ÄŒile","fa":"شیلی","de":"Chile","es":"Chile","fr":"Chili","ja":"ãƒãƒª","it":"Cile"},"name":"Chile","alpha2Code":"CL"},{"translations":{"br":"China","pt":"China","nl":"China","hr":"Kina","fa":"چین","de":"China","es":"China","fr":"Chine","ja":"中国","it":"Cina"},"name":"China","alpha2Code":"CN"},{"translations":{"br":"Ilha Christmas","pt":"Ilha do Natal","nl":"Christmaseiland","hr":"Božićni otok","fa":"جزیره کریسمس","de":"Weihnachtsinsel","es":"Isla de Navidad","fr":"ÃŽle Christmas","ja":"クリスマス島","it":"Isola di Natale"},"name":"Christmas Island","alpha2Code":"CX"},{"translations":{"br":"Ilhas Cocos","pt":"Ilhas dos Cocos","nl":"Cocoseilanden","hr":"Kokosovi Otoci","fa":"جزایر کوکوس","de":"Kokosinseln","es":"Islas Cocos o Islas Keeling","fr":"ÃŽles Cocos","ja":"ココス(キーリング)諸島","it":"Isole Cocos e Keeling"},"name":"Cocos (Keeling) Islands","alpha2Code":"CC"},{"translations":{"br":"Colômbia","pt":"Colômbia","nl":"Colombia","hr":"Kolumbija","fa":"کلمبیا","de":"Kolumbien","es":"Colombia","fr":"Colombie","ja":"コロンビア","it":"Colombia"},"name":"Colombia","alpha2Code":"CO"},{"translations":{"br":"Comores","pt":"Comores","nl":"Comoren","hr":"Komori","fa":"کومور","de":"Union der Komoren","es":"Comoras","fr":"Comores","ja":"コモロ","it":"Comore"},"name":"Comoros","alpha2Code":"KM"},{"translations":{"br":"Congo","pt":"Congo","nl":"Congo [Republiek]","hr":"Kongo","fa":"Ú©Ù†Ú¯Ùˆ","de":"Kongo","es":"Congo","fr":"Congo","ja":"コンゴ共和国","it":"Congo"},"name":"Congo","alpha2Code":"CG"},{"translations":{"br":"RD Congo","pt":"RD Congo","nl":"Congo [DRC]","hr":"Kongo, Demokratska Republika","fa":"جمهوری Ú©Ù†Ú¯Ùˆ","de":"Kongo (Dem. Rep.)","es":"Congo (Rep. Dem.)","fr":"Congo (Rép. dém.)","ja":"コンゴ民主共和国","it":"Congo (Rep. Dem.)"},"name":"Congo (Democratic Republic of the)","alpha2Code":"CD"},{"translations":{"br":"Ilhas Cook","pt":"Ilhas Cook","nl":"Cookeilanden","hr":"Cookovo OtoÄje","fa":"جزایر Ú©ÙˆÚ©","de":"Cookinseln","es":"Islas Cook","fr":"ÃŽles Cook","ja":"クック諸島","it":"Isole Cook"},"name":"Cook Islands","alpha2Code":"CK"},{"translations":{"br":"Costa Rica","pt":"Costa Rica","nl":"Costa Rica","hr":"Kostarika","fa":"کاستاریکا","de":"Costa Rica","es":"Costa Rica","fr":"Costa Rica","ja":"コスタリカ","it":"Costa Rica"},"name":"Costa Rica","alpha2Code":"CR"},{"translations":{"br":"Croácia","pt":"Croácia","nl":"Kroatië","hr":"Hrvatska","fa":"کرواسی","de":"Kroatien","es":"Croacia","fr":"Croatie","ja":"クロアãƒã‚¢","it":"Croazia"},"name":"Croatia","alpha2Code":"HR"},{"translations":{"br":"Cuba","pt":"Cuba","nl":"Cuba","hr":"Kuba","fa":"کوبا","de":"Kuba","es":"Cuba","fr":"Cuba","ja":"キューãƒ","it":"Cuba"},"name":"Cuba","alpha2Code":"CU"},{"translations":{"br":"Curaçao","pt":"Curaçao","nl":"Curaçao","fa":"کوراسائو","de":"Curaçao","fr":"Curaçao","it":"Curaçao"},"name":"Curaçao","alpha2Code":"CW"},{"translations":{"br":"Chipre","pt":"Chipre","nl":"Cyprus","hr":"Cipar","fa":"قبرس","de":"Zypern","es":"Chipre","fr":"Chypre","ja":"キプロス","it":"Cipro"},"name":"Cyprus","alpha2Code":"CY"},{"translations":{"br":"República Tcheca","pt":"República Checa","nl":"Tsjechië","hr":"ÄŒeÅ¡ka","fa":"جمهوری Ú†Ú©","de":"Tschechische Republik","es":"República Checa","fr":"République tchèque","ja":"ãƒã‚§ã‚³","it":"Repubblica Ceca"},"name":"Czech Republic","alpha2Code":"CZ"},{"translations":{"br":"Dinamarca","pt":"Dinamarca","nl":"Denemarken","hr":"Danska","fa":"دانمارک","de":"Dänemark","es":"Dinamarca","fr":"Danemark","ja":"デンマーク","it":"Danimarca"},"name":"Denmark","alpha2Code":"DK"},{"translations":{"br":"Djibuti","pt":"Djibuti","nl":"Djibouti","hr":"Džibuti","fa":"جیبوتی","de":"Dschibuti","es":"Yibuti","fr":"Djibouti","ja":"ジブãƒ","it":"Gibuti"},"name":"Djibouti","alpha2Code":"DJ"},{"translations":{"br":"Dominica","pt":"Dominica","nl":"Dominica","hr":"Dominika","fa":"دومینیکا","de":"Dominica","es":"Dominica","fr":"Dominique","ja":"ドミニカ国","it":"Dominica"},"name":"Dominica","alpha2Code":"DM"},{"translations":{"br":"República Dominicana","pt":"República Dominicana","nl":"Dominicaanse Republiek","hr":"Dominikanska Republika","fa":"جمهوری دومینیکن","de":"Dominikanische Republik","es":"República Dominicana","fr":"République dominicaine","ja":"ドミニカ共和国","it":"Repubblica Dominicana"},"name":"Dominican Republic","alpha2Code":"DO"},{"translations":{"br":"Equador","pt":"Equador","nl":"Ecuador","hr":"Ekvador","fa":"اکوادور","de":"Ecuador","es":"Ecuador","fr":"Équateur","ja":"エクアドル","it":"Ecuador"},"name":"Ecuador","alpha2Code":"EC"},{"translations":{"br":"Egito","pt":"Egipto","nl":"Egypte","hr":"Egipat","fa":"مصر","de":"Ägypten","es":"Egipto","fr":"Égypte","ja":"エジプト","it":"Egitto"},"name":"Egypt","alpha2Code":"EG"},{"translations":{"br":"El Salvador","pt":"El Salvador","nl":"El Salvador","hr":"Salvador","fa":"السالوادور","de":"El Salvador","es":"El Salvador","fr":"Salvador","ja":"エルサルãƒãƒ‰ãƒ«","it":"El Salvador"},"name":"El Salvador","alpha2Code":"SV"},{"translations":{"br":"Guiné Equatorial","pt":"Guiné Equatorial","nl":"Equatoriaal-Guinea","hr":"Ekvatorijalna Gvineja","fa":"گینه استوایی","de":"Äquatorial-Guinea","es":"Guinea Ecuatorial","fr":"Guinée-Équatoriale","ja":"赤é“ギニア","it":"Guinea Equatoriale"},"name":"Equatorial Guinea","alpha2Code":"GQ"},{"translations":{"br":"Eritreia","pt":"Eritreia","nl":"Eritrea","hr":"Eritreja","fa":"اریتره","de":"Eritrea","es":"Eritrea","fr":"Érythrée","ja":"エリトリア","it":"Eritrea"},"name":"Eritrea","alpha2Code":"ER"},{"translations":{"br":"Estônia","pt":"Estónia","nl":"Estland","hr":"Estonija","fa":"استونی","de":"Estland","es":"Estonia","fr":"Estonie","ja":"エストニア","it":"Estonia"},"name":"Estonia","alpha2Code":"EE"},{"translations":{"br":"Etiópia","pt":"Etiópia","nl":"Ethiopië","hr":"Etiopija","fa":"اتیوپی","de":"Äthiopien","es":"Etiopía","fr":"Éthiopie","ja":"エãƒã‚ªãƒ”ã‚¢","it":"Etiopia"},"name":"Ethiopia","alpha2Code":"ET"},{"translations":{"br":"Ilhas Malvinas","pt":"Ilhas Falkland","nl":"Falklandeilanden [Islas Malvinas]","hr":"Falklandski Otoci","fa":"جزایر Ùالکلند","de":"Falklandinseln","es":"Islas Malvinas","fr":"ÃŽles Malouines","ja":"フォークランド(マルビナス)諸島","it":"Isole Falkland o Isole Malvine"},"name":"Falkland Islands (Malvinas)","alpha2Code":"FK"},{"translations":{"br":"Ilhas Faroé","pt":"Ilhas Faroé","nl":"Faeröer","hr":"Farski Otoci","fa":"جزایر Ùارو","de":"Färöer-Inseln","es":"Islas Faroe","fr":"ÃŽles Féroé","ja":"フェロー諸島","it":"Isole Far Oer"},"name":"Faroe Islands","alpha2Code":"FO"},{"translations":{"br":"Fiji","pt":"Fiji","nl":"Fiji","hr":"FiÄ‘i","fa":"Ùیجی","de":"Fidschi","es":"Fiyi","fr":"Fidji","ja":"フィジー","it":"Figi"},"name":"Fiji","alpha2Code":"FJ"},{"translations":{"br":"Finlândia","pt":"Finlândia","nl":"Finland","hr":"Finska","fa":"Ùنلاند","de":"Finnland","es":"Finlandia","fr":"Finlande","ja":"フィンランド","it":"Finlandia"},"name":"Finland","alpha2Code":"FI"},{"translations":{"br":"França","pt":"França","nl":"Frankrijk","hr":"Francuska","fa":"Ùرانسه","de":"Frankreich","es":"Francia","fr":"France","ja":"フランス","it":"Francia"},"name":"France","alpha2Code":"FR"},{"translations":{"br":"Guiana Francesa","pt":"Guiana Francesa","nl":"Frans-Guyana","hr":"Francuska Gvajana","fa":"گویان Ùرانسه","de":"Französisch Guyana","es":"Guayana Francesa","fr":"Guayane","ja":"フランス領ギアナ","it":"Guyana francese"},"name":"French Guiana","alpha2Code":"GF"},{"translations":{"br":"Polinésia Francesa","pt":"Polinésia Francesa","nl":"Frans-Polynesië","hr":"Francuska Polinezija","fa":"پلی‌نزی Ùرانسه","de":"Französisch-Polynesien","es":"Polinesia Francesa","fr":"Polynésie française","ja":"フランス領ãƒãƒªãƒã‚·ã‚¢","it":"Polinesia Francese"},"name":"French Polynesia","alpha2Code":"PF"},{"translations":{"br":"Terras Austrais e Antárticas Francesas","pt":"Terras Austrais e Antárticas Francesas","nl":"Franse Gebieden in de zuidelijke Indische Oceaan","hr":"Francuski južni i antarktiÄki teritoriji","fa":"سرزمین‌های جنوبی Ùˆ جنوبگانی Ùرانسه","de":"Französische Süd- und Antarktisgebiete","es":"Tierras Australes y Antárticas Francesas","fr":"Terres australes et antarctiques françaises","ja":"フランス領å—方・å—極地域","it":"Territori Francesi del Sud"},"name":"French Southern Territories","alpha2Code":"TF"},{"translations":{"br":"Gabão","pt":"Gabão","nl":"Gabon","hr":"Gabon","fa":"گابن","de":"Gabun","es":"Gabón","fr":"Gabon","ja":"ガボン","it":"Gabon"},"name":"Gabon","alpha2Code":"GA"},{"translations":{"br":"Gâmbia","pt":"Gâmbia","nl":"Gambia","hr":"Gambija","fa":"گامبیا","de":"Gambia","es":"Gambia","fr":"Gambie","ja":"ガンビア","it":"Gambia"},"name":"Gambia","alpha2Code":"GM"},{"translations":{"br":"Geórgia","pt":"Geórgia","nl":"Georgië","hr":"Gruzija","fa":"گرجستان","de":"Georgien","es":"Georgia","fr":"Géorgie","ja":"グルジア","it":"Georgia"},"name":"Georgia","alpha2Code":"GE"},{"translations":{"br":"Alemanha","pt":"Alemanha","nl":"Duitsland","hr":"NjemaÄka","fa":"آلمان","de":"Deutschland","es":"Alemania","fr":"Allemagne","ja":"ドイツ","it":"Germania"},"name":"Germany","alpha2Code":"DE"},{"translations":{"br":"Gana","pt":"Gana","nl":"Ghana","hr":"Gana","fa":"غنا","de":"Ghana","es":"Ghana","fr":"Ghana","ja":"ガーナ","it":"Ghana"},"name":"Ghana","alpha2Code":"GH"},{"translations":{"br":"Gibraltar","pt":"Gibraltar","nl":"Gibraltar","hr":"Gibraltar","fa":"جبل‌طارق","de":"Gibraltar","es":"Gibraltar","fr":"Gibraltar","ja":"ジブラルタル","it":"Gibilterra"},"name":"Gibraltar","alpha2Code":"GI"},{"translations":{"br":"Grécia","pt":"Grécia","nl":"Griekenland","hr":"GrÄka","fa":"یونان","de":"Griechenland","es":"Grecia","fr":"Grèce","ja":"ギリシャ","it":"Grecia"},"name":"Greece","alpha2Code":"GR"},{"translations":{"br":"Groelândia","pt":"Gronelândia","nl":"Groenland","hr":"Grenland","fa":"گرینلند","de":"Grönland","es":"Groenlandia","fr":"Groenland","ja":"グリーンランド","it":"Groenlandia"},"name":"Greenland","alpha2Code":"GL"},{"translations":{"br":"Granada","pt":"Granada","nl":"Grenada","hr":"Grenada","fa":"گرنادا","de":"Grenada","es":"Grenada","fr":"Grenade","ja":"グレナダ","it":"Grenada"},"name":"Grenada","alpha2Code":"GD"},{"translations":{"br":"Guadalupe","pt":"Guadalupe","nl":"Guadeloupe","hr":"Gvadalupa","fa":"جزیره گوادلوپ","de":"Guadeloupe","es":"Guadalupe","fr":"Guadeloupe","ja":"グアドループ","it":"Guadeloupa"},"name":"Guadeloupe","alpha2Code":"GP"},{"translations":{"br":"Guam","pt":"Guame","nl":"Guam","hr":"Guam","fa":"گوام","de":"Guam","es":"Guam","fr":"Guam","ja":"グアム","it":"Guam"},"name":"Guam","alpha2Code":"GU"},{"translations":{"br":"Guatemala","pt":"Guatemala","nl":"Guatemala","hr":"Gvatemala","fa":"گواتمالا","de":"Guatemala","es":"Guatemala","fr":"Guatemala","ja":"グアテマラ","it":"Guatemala"},"name":"Guatemala","alpha2Code":"GT"},{"translations":{"br":"Guernsey","pt":"Guernsey","nl":"Guernsey","hr":"Guernsey","fa":"گرنزی","de":"Guernsey","es":"Guernsey","fr":"Guernesey","ja":"ガーンジー","it":"Guernsey"},"name":"Guernsey","alpha2Code":"GG"},{"translations":{"br":"Guiné","pt":"Guiné","nl":"Guinee","hr":"Gvineja","fa":"گینه","de":"Guinea","es":"Guinea","fr":"Guinée","ja":"ギニア","it":"Guinea"},"name":"Guinea","alpha2Code":"GN"},{"translations":{"br":"Guiné-Bissau","pt":"Guiné-Bissau","nl":"Guinee-Bissau","hr":"Gvineja Bisau","fa":"گینه بیسائو","de":"Guinea-Bissau","es":"Guinea-Bisáu","fr":"Guinée-Bissau","ja":"ギニアビサウ","it":"Guinea-Bissau"},"name":"Guinea-Bissau","alpha2Code":"GW"},{"translations":{"br":"Guiana","pt":"Guiana","nl":"Guyana","hr":"Gvajana","fa":"گویان","de":"Guyana","es":"Guyana","fr":"Guyane","ja":"ガイアナ","it":"Guyana"},"name":"Guyana","alpha2Code":"GY"},{"translations":{"br":"Haiti","pt":"Haiti","nl":"Haïti","hr":"Haiti","fa":"هائیتی","de":"Haiti","es":"Haiti","fr":"Haïti","ja":"ãƒã‚¤ãƒ","it":"Haiti"},"name":"Haiti","alpha2Code":"HT"},{"translations":{"br":"Ilha Heard e Ilhas McDonald","pt":"Ilha Heard e Ilhas McDonald","nl":"Heard- en McDonaldeilanden","hr":"Otok Heard i otoÄje McDonald","fa":"جزیره هرد Ùˆ جزایر مک‌دونالد","de":"Heard und die McDonaldinseln","es":"Islas Heard y McDonald","fr":"ÃŽles Heard-et-MacDonald","ja":"ãƒãƒ¼ãƒ‰å³¶ã¨ãƒžã‚¯ãƒ‰ãƒŠãƒ«ãƒ‰è«¸å³¶","it":"Isole Heard e McDonald"},"name":"Heard Island and McDonald Islands","alpha2Code":"HM"},{"translations":{"br":"Vaticano","pt":"Vaticano","nl":"Heilige Stoel","hr":"Sveta Stolica","fa":"سریر مقدس","de":"Heiliger Stuhl","es":"Santa Sede","fr":"voir Saint","ja":"è–座","it":"Santa Sede"},"name":"Holy See","alpha2Code":"VA"},{"translations":{"br":"Honduras","pt":"Honduras","nl":"Honduras","hr":"Honduras","fa":"هندوراس","de":"Honduras","es":"Honduras","fr":"Honduras","ja":"ホンジュラス","it":"Honduras"},"name":"Honduras","alpha2Code":"HN"},{"translations":{"br":"Hong Kong","pt":"Hong Kong","nl":"Hongkong","hr":"Hong Kong","fa":"هنگ‌کنگ","de":"Hong Kong","es":"Hong Kong","fr":"Hong Kong","ja":"香港","it":"Hong Kong"},"name":"Hong Kong","alpha2Code":"HK"},{"translations":{"br":"Hungria","pt":"Hungria","nl":"Hongarije","hr":"MaÄ‘arska","fa":"مجارستان","de":"Ungarn","es":"Hungría","fr":"Hongrie","ja":"ãƒãƒ³ã‚¬ãƒªãƒ¼","it":"Ungheria"},"name":"Hungary","alpha2Code":"HU"},{"translations":{"br":"Islândia","pt":"Islândia","nl":"IJsland","hr":"Island","fa":"ایسلند","de":"Island","es":"Islandia","fr":"Islande","ja":"アイスランド","it":"Islanda"},"name":"Iceland","alpha2Code":"IS"},{"translations":{"br":"Ãndia","pt":"Ãndia","nl":"India","hr":"Indija","fa":"هند","de":"Indien","es":"India","fr":"Inde","ja":"インド","it":"India"},"name":"India","alpha2Code":"IN"},{"translations":{"br":"Indonésia","pt":"Indonésia","nl":"Indonesië","hr":"Indonezija","fa":"اندونزی","de":"Indonesien","es":"Indonesia","fr":"Indonésie","ja":"インドãƒã‚·ã‚¢","it":"Indonesia"},"name":"Indonesia","alpha2Code":"ID"},{"translations":{"br":"Costa do Marfim","pt":"Costa do Marfim","nl":"Ivoorkust","hr":"Obala Bjelokosti","fa":"ساحل عاج","de":"Elfenbeinküste","es":"Costa de Marfil","fr":"Côte d\'Ivoire","ja":"コートジボワール","it":"Costa D\'Avorio"},"name":"Côte d\'Ivoire","alpha2Code":"CI"},{"translations":{"br":"Irã","pt":"Irão","nl":"Iran","hr":"Iran","fa":"ایران","de":"Iran","es":"Iran","fr":"Iran","ja":"イラン・イスラム共和国"},"name":"Iran (Islamic Republic of)","alpha2Code":"IR"},{"translations":{"br":"Iraque","pt":"Iraque","nl":"Irak","hr":"Irak","fa":"عراق","de":"Irak","es":"Irak","fr":"Irak","ja":"イラク","it":"Iraq"},"name":"Iraq","alpha2Code":"IQ"},{"translations":{"br":"Irlanda","pt":"Irlanda","nl":"Ierland","hr":"Irska","fa":"ایرلند","de":"Irland","es":"Irlanda","fr":"Irlande","ja":"アイルランド","it":"Irlanda"},"name":"Ireland","alpha2Code":"IE"},{"translations":{"br":"Ilha de Man","pt":"Ilha de Man","nl":"Isle of Man","hr":"Otok Man","fa":"جزیره من","de":"Insel Man","es":"Isla de Man","fr":"ÃŽle de Man","ja":"マン島","it":"Isola di Man"},"name":"Isle of Man","alpha2Code":"IM"},{"translations":{"br":"Israel","pt":"Israel","nl":"Israël","hr":"Izrael","fa":"اسرائیل","de":"Israel","es":"Israel","fr":"Israël","ja":"イスラエル","it":"Israele"},"name":"Israel","alpha2Code":"IL"},{"translations":{"br":"Itália","pt":"Itália","nl":"Italië","hr":"Italija","fa":"ایتالیا","de":"Italien","es":"Italia","fr":"Italie","ja":"イタリア","it":"Italia"},"name":"Italy","alpha2Code":"IT"},{"translations":{"br":"Jamaica","pt":"Jamaica","nl":"Jamaica","hr":"Jamajka","fa":"جامائیکا","de":"Jamaika","es":"Jamaica","fr":"Jamaïque","ja":"ジャマイカ","it":"Giamaica"},"name":"Jamaica","alpha2Code":"JM"},{"translations":{"br":"Japão","pt":"Japão","nl":"Japan","hr":"Japan","fa":"ژاپن","de":"Japan","es":"Japón","fr":"Japon","ja":"日本","it":"Giappone"},"name":"Japan","alpha2Code":"JP"},{"translations":{"br":"Jersey","pt":"Jersey","nl":"Jersey","hr":"Jersey","fa":"جرزی","de":"Jersey","es":"Jersey","fr":"Jersey","ja":"ジャージー","it":"Isola di Jersey"},"name":"Jersey","alpha2Code":"JE"},{"translations":{"br":"Jordânia","pt":"Jordânia","nl":"Jordanië","hr":"Jordan","fa":"اردن","de":"Jordanien","es":"Jordania","fr":"Jordanie","ja":"ヨルダン","it":"Giordania"},"name":"Jordan","alpha2Code":"JO"},{"translations":{"br":"Cazaquistão","pt":"Cazaquistão","nl":"Kazachstan","hr":"Kazahstan","fa":"قزاقستان","de":"Kasachstan","es":"Kazajistán","fr":"Kazakhstan","ja":"カザフスタン","it":"Kazakistan"},"name":"Kazakhstan","alpha2Code":"KZ"},{"translations":{"br":"Quênia","pt":"Quénia","nl":"Kenia","hr":"Kenija","fa":"کنیا","de":"Kenia","es":"Kenia","fr":"Kenya","ja":"ケニア","it":"Kenya"},"name":"Kenya","alpha2Code":"KE"},{"translations":{"br":"Kiribati","pt":"Quiribáti","nl":"Kiribati","hr":"Kiribati","fa":"کیریباتی","de":"Kiribati","es":"Kiribati","fr":"Kiribati","ja":"キリãƒã‚¹","it":"Kiribati"},"name":"Kiribati","alpha2Code":"KI"},{"translations":{"br":"Kuwait","pt":"Kuwait","nl":"Koeweit","hr":"Kuvajt","fa":"کویت","de":"Kuwait","es":"Kuwait","fr":"Koweït","ja":"クウェート","it":"Kuwait"},"name":"Kuwait","alpha2Code":"KW"},{"translations":{"br":"Quirguistão","pt":"Quirguizistão","nl":"Kirgizië","hr":"Kirgistan","fa":"قرقیزستان","de":"Kirgisistan","es":"Kirguizistán","fr":"Kirghizistan","ja":"キルギス","it":"Kirghizistan"},"name":"Kyrgyzstan","alpha2Code":"KG"},{"translations":{"br":"Laos","pt":"Laos","nl":"Laos","hr":"Laos","fa":"لائوس","de":"Laos","es":"Laos","fr":"Laos","ja":"ラオス人民民主共和国","it":"Laos"},"name":"Lao People\'s Democratic Republic","alpha2Code":"LA"},{"translations":{"br":"Letônia","pt":"Letónia","nl":"Letland","hr":"Latvija","fa":"لتونی","de":"Lettland","es":"Letonia","fr":"Lettonie","ja":"ラトビア","it":"Lettonia"},"name":"Latvia","alpha2Code":"LV"},{"translations":{"br":"Líbano","pt":"Líbano","nl":"Libanon","hr":"Libanon","fa":"لبنان","de":"Libanon","es":"Líbano","fr":"Liban","ja":"レãƒãƒŽãƒ³","it":"Libano"},"name":"Lebanon","alpha2Code":"LB"},{"translations":{"br":"Lesoto","pt":"Lesoto","nl":"Lesotho","hr":"Lesoto","fa":"لسوتو","de":"Lesotho","es":"Lesotho","fr":"Lesotho","ja":"レソト","it":"Lesotho"},"name":"Lesotho","alpha2Code":"LS"},{"translations":{"br":"Libéria","pt":"Libéria","nl":"Liberia","hr":"Liberija","fa":"لیبریا","de":"Liberia","es":"Liberia","fr":"Liberia","ja":"リベリア","it":"Liberia"},"name":"Liberia","alpha2Code":"LR"},{"translations":{"br":"Líbia","pt":"Líbia","nl":"Libië","hr":"Libija","fa":"لیبی","de":"Libyen","es":"Libia","fr":"Libye","ja":"リビア","it":"Libia"},"name":"Libya","alpha2Code":"LY"},{"translations":{"br":"Liechtenstein","pt":"Listenstaine","nl":"Liechtenstein","hr":"LihtenÅ¡tajn","fa":"لیختن‌اشتاین","de":"Liechtenstein","es":"Liechtenstein","fr":"Liechtenstein","ja":"リヒテンシュタイン","it":"Liechtenstein"},"name":"Liechtenstein","alpha2Code":"LI"},{"translations":{"br":"Lituânia","pt":"Lituânia","nl":"Litouwen","hr":"Litva","fa":"لیتوانی","de":"Litauen","es":"Lituania","fr":"Lituanie","ja":"リトアニア","it":"Lituania"},"name":"Lithuania","alpha2Code":"LT"},{"translations":{"br":"Luxemburgo","pt":"Luxemburgo","nl":"Luxemburg","hr":"Luksemburg","fa":"لوکزامبورگ","de":"Luxemburg","es":"Luxemburgo","fr":"Luxembourg","ja":"ルクセンブルク","it":"Lussemburgo"},"name":"Luxembourg","alpha2Code":"LU"},{"translations":{"br":"Macau","pt":"Macau","nl":"Macao","hr":"Makao","fa":"مکائو","de":"Macao","es":"Macao","fr":"Macao","ja":"マカオ","it":"Macao"},"name":"Macao","alpha2Code":"MO"},{"translations":{"br":"Macedônia","pt":"Macedónia","nl":"Macedonië","hr":"Makedonija","fa":"","de":"Mazedonien","es":"Macedonia","fr":"Macédoine","ja":"マケドニア旧ユーゴスラビア共和国","it":"Macedonia"},"name":"Macedonia (the former Yugoslav Republic of)","alpha2Code":"MK"},{"translations":{"br":"Madagascar","pt":"Madagáscar","nl":"Madagaskar","hr":"Madagaskar","fa":"ماداگاسکار","de":"Madagaskar","es":"Madagascar","fr":"Madagascar","ja":"マダガスカル","it":"Madagascar"},"name":"Madagascar","alpha2Code":"MG"},{"translations":{"br":"Malawi","pt":"Malávi","nl":"Malawi","hr":"Malavi","fa":"مالاوی","de":"Malawi","es":"Malawi","fr":"Malawi","ja":"マラウイ","it":"Malawi"},"name":"Malawi","alpha2Code":"MW"},{"translations":{"br":"Malásia","pt":"Malásia","nl":"Maleisië","hr":"Malezija","fa":"مالزی","de":"Malaysia","es":"Malasia","fr":"Malaisie","ja":"マレーシア","it":"Malesia"},"name":"Malaysia","alpha2Code":"MY"},{"translations":{"br":"Maldivas","pt":"Maldivas","nl":"Maldiven","hr":"Maldivi","fa":"مالدیو","de":"Malediven","es":"Maldivas","fr":"Maldives","ja":"モルディブ","it":"Maldive"},"name":"Maldives","alpha2Code":"MV"},{"translations":{"br":"Mali","pt":"Mali","nl":"Mali","hr":"Mali","fa":"مالی","de":"Mali","es":"Mali","fr":"Mali","ja":"マリ","it":"Mali"},"name":"Mali","alpha2Code":"ML"},{"translations":{"br":"Malta","pt":"Malta","nl":"Malta","hr":"Malta","fa":"مالت","de":"Malta","es":"Malta","fr":"Malte","ja":"マルタ","it":"Malta"},"name":"Malta","alpha2Code":"MT"},{"translations":{"br":"Ilhas Marshall","pt":"Ilhas Marshall","nl":"Marshalleilanden","hr":"MarÅ¡alovi Otoci","fa":"جزایر مارشال","de":"Marshallinseln","es":"Islas Marshall","fr":"ÃŽles Marshall","ja":"マーシャル諸島","it":"Isole Marshall"},"name":"Marshall Islands","alpha2Code":"MH"},{"translations":{"br":"Martinica","pt":"Martinica","nl":"Martinique","hr":"Martinique","fa":"مونتسرات","de":"Martinique","es":"Martinica","fr":"Martinique","ja":"マルティニーク","it":"Martinica"},"name":"Martinique","alpha2Code":"MQ"},{"translations":{"br":"Mauritânia","pt":"Mauritânia","nl":"Mauritanië","hr":"Mauritanija","fa":"موریتانی","de":"Mauretanien","es":"Mauritania","fr":"Mauritanie","ja":"モーリタニア","it":"Mauritania"},"name":"Mauritania","alpha2Code":"MR"},{"translations":{"br":"Maurício","pt":"Maurícia","nl":"Mauritius","hr":"Mauricijus","fa":"موریس","de":"Mauritius","es":"Mauricio","fr":"ÃŽle Maurice","ja":"モーリシャス","it":"Mauritius"},"name":"Mauritius","alpha2Code":"MU"},{"translations":{"br":"Mayotte","pt":"Mayotte","nl":"Mayotte","hr":"Mayotte","fa":"مایوت","de":"Mayotte","es":"Mayotte","fr":"Mayotte","ja":"マヨット","it":"Mayotte"},"name":"Mayotte","alpha2Code":"YT"},{"translations":{"br":"México","pt":"México","nl":"Mexico","hr":"Meksiko","fa":"مکزیک","de":"Mexiko","es":"México","fr":"Mexique","ja":"メキシコ","it":"Messico"},"name":"Mexico","alpha2Code":"MX"},{"translations":{"br":"Micronésia","pt":"Micronésia","nl":"Micronesië","hr":"Mikronezija","fa":"ایالات Ùدرال میکرونزی","de":"Mikronesien","es":"Micronesia","fr":"Micronésie","ja":"ミクロãƒã‚·ã‚¢é€£é‚¦","it":"Micronesia"},"name":"Micronesia (Federated States of)","alpha2Code":"FM"},{"translations":{"br":"Moldávia","pt":"Moldávia","nl":"Moldavië","hr":"Moldova","fa":"مولداوی","de":"Moldawie","es":"Moldavia","fr":"Moldavie","ja":"モルドãƒå…±å’Œå›½","it":"Moldavia"},"name":"Moldova (Republic of)","alpha2Code":"MD"},{"translations":{"br":"Mônaco","pt":"Mónaco","nl":"Monaco","hr":"Monako","fa":"موناکو","de":"Monaco","es":"Mónaco","fr":"Monaco","ja":"モナコ","it":"Principato di Monaco"},"name":"Monaco","alpha2Code":"MC"},{"translations":{"br":"Mongólia","pt":"Mongólia","nl":"Mongolië","hr":"Mongolija","fa":"مغولستان","de":"Mongolei","es":"Mongolia","fr":"Mongolie","ja":"モンゴル","it":"Mongolia"},"name":"Mongolia","alpha2Code":"MN"},{"translations":{"br":"Montenegro","pt":"Montenegro","nl":"Montenegro","hr":"Crna Gora","fa":"مونته‌نگرو","de":"Montenegro","es":"Montenegro","fr":"Monténégro","ja":"モンテãƒã‚°ãƒ­","it":"Montenegro"},"name":"Montenegro","alpha2Code":"ME"},{"translations":{"br":"Montserrat","pt":"Monserrate","nl":"Montserrat","hr":"Montserrat","fa":"مایوت","de":"Montserrat","es":"Montserrat","fr":"Montserrat","ja":"モントセラト","it":"Montserrat"},"name":"Montserrat","alpha2Code":"MS"},{"translations":{"br":"Marrocos","pt":"Marrocos","nl":"Marokko","hr":"Maroko","fa":"مراکش","de":"Marokko","es":"Marruecos","fr":"Maroc","ja":"モロッコ","it":"Marocco"},"name":"Morocco","alpha2Code":"MA"},{"translations":{"br":"Moçambique","pt":"Moçambique","nl":"Mozambique","hr":"Mozambik","fa":"موزامبیک","de":"Mosambik","es":"Mozambique","fr":"Mozambique","ja":"モザンビーク","it":"Mozambico"},"name":"Mozambique","alpha2Code":"MZ"},{"translations":{"br":"Myanmar","pt":"Myanmar","nl":"Myanmar","hr":"Mijanmar","fa":"میانمار","de":"Myanmar","es":"Myanmar","fr":"Myanmar","ja":"ミャンマー","it":"Birmania"},"name":"Myanmar","alpha2Code":"MM"},{"translations":{"br":"Namíbia","pt":"Namíbia","nl":"Namibië","hr":"Namibija","fa":"نامیبیا","de":"Namibia","es":"Namibia","fr":"Namibie","ja":"ナミビア","it":"Namibia"},"name":"Namibia","alpha2Code":"NA"},{"translations":{"br":"Nauru","pt":"Nauru","nl":"Nauru","hr":"Nauru","fa":"نائورو","de":"Nauru","es":"Nauru","fr":"Nauru","ja":"ナウル","it":"Nauru"},"name":"Nauru","alpha2Code":"NR"},{"translations":{"br":"Nepal","pt":"Nepal","nl":"Nepal","hr":"Nepal","fa":"نپال","de":"Népal","es":"Nepal","fr":"Népal","ja":"ãƒãƒ‘ール","it":"Nepal"},"name":"Nepal","alpha2Code":"NP"},{"translations":{"br":"Holanda","pt":"Países Baixos","nl":"Nederland","hr":"Nizozemska","fa":"پادشاهی هلند","de":"Niederlande","es":"Países Bajos","fr":"Pays-Bas","ja":"オランダ","it":"Paesi Bassi"},"name":"Netherlands","alpha2Code":"NL"},{"translations":{"br":"Nova Caledônia","pt":"Nova Caledónia","nl":"Nieuw-Caledonië","hr":"Nova Kaledonija","fa":"کالدونیای جدید","de":"Neukaledonien","es":"Nueva Caledonia","fr":"Nouvelle-Calédonie","ja":"ニューカレドニア","it":"Nuova Caledonia"},"name":"New Caledonia","alpha2Code":"NC"},{"translations":{"br":"Nova Zelândia","pt":"Nova Zelândia","nl":"Nieuw-Zeeland","hr":"Novi Zeland","fa":"نیوزیلند","de":"Neuseeland","es":"Nueva Zelanda","fr":"Nouvelle-Zélande","ja":"ニュージーランド","it":"Nuova Zelanda"},"name":"New Zealand","alpha2Code":"NZ"},{"translations":{"br":"Nicarágua","pt":"Nicarágua","nl":"Nicaragua","hr":"Nikaragva","fa":"نیکاراگوئه","de":"Nicaragua","es":"Nicaragua","fr":"Nicaragua","ja":"ニカラグア","it":"Nicaragua"},"name":"Nicaragua","alpha2Code":"NI"},{"translations":{"br":"Níger","pt":"Níger","nl":"Niger","hr":"Niger","fa":"نیجر","de":"Niger","es":"Níger","fr":"Niger","ja":"ニジェール","it":"Niger"},"name":"Niger","alpha2Code":"NE"},{"translations":{"br":"Nigéria","pt":"Nigéria","nl":"Nigeria","hr":"Nigerija","fa":"نیجریه","de":"Nigeria","es":"Nigeria","fr":"Nigéria","ja":"ナイジェリア","it":"Nigeria"},"name":"Nigeria","alpha2Code":"NG"},{"translations":{"br":"Niue","pt":"Niue","nl":"Niue","hr":"Niue","fa":"نیووی","de":"Niue","es":"Niue","fr":"Niue","ja":"ニウエ","it":"Niue"},"name":"Niue","alpha2Code":"NU"},{"translations":{"br":"Ilha Norfolk","pt":"Ilha Norfolk","nl":"Norfolkeiland","hr":"Otok Norfolk","fa":"جزیره نورÙÚ©","de":"Norfolkinsel","es":"Isla de Norfolk","fr":"ÃŽle de Norfolk","ja":"ノーフォーク島","it":"Isola Norfolk"},"name":"Norfolk Island","alpha2Code":"NF"},{"translations":{"br":"Coreia do Norte","pt":"Coreia do Norte","nl":"Noord-Korea","hr":"Sjeverna Koreja","fa":"کره جنوبی","de":"Nordkorea","es":"Corea del Norte","fr":"Corée du Nord","ja":"æœé®®æ°‘主主義人民共和国","it":"Corea del Nord"},"name":"Korea (Democratic People\'s Republic of)","alpha2Code":"KP"},{"translations":{"br":"Ilhas Marianas","pt":"Ilhas Marianas","nl":"Noordelijke Marianeneilanden","hr":"Sjevernomarijanski otoci","fa":"جزایر ماریانای شمالی","de":"Nördliche Marianen","es":"Islas Marianas del Norte","fr":"ÃŽles Mariannes du Nord","ja":"北マリアナ諸島","it":"Isole Marianne Settentrionali"},"name":"Northern Mariana Islands","alpha2Code":"MP"},{"translations":{"br":"Noruega","pt":"Noruega","nl":"Noorwegen","hr":"NorveÅ¡ka","fa":"نروژ","de":"Norwegen","es":"Noruega","fr":"Norvège","ja":"ノルウェー","it":"Norvegia"},"name":"Norway","alpha2Code":"NO"},{"translations":{"br":"Omã","pt":"Omã","nl":"Oman","hr":"Oman","fa":"عمان","de":"Oman","es":"Omán","fr":"Oman","ja":"オマーン","it":"oman"},"name":"Oman","alpha2Code":"OM"},{"translations":{"br":"Paquistão","pt":"Paquistão","nl":"Pakistan","hr":"Pakistan","fa":"پاکستان","de":"Pakistan","es":"Pakistán","fr":"Pakistan","ja":"パキスタン","it":"Pakistan"},"name":"Pakistan","alpha2Code":"PK"},{"translations":{"br":"Palau","pt":"Palau","nl":"Palau","hr":"Palau","fa":"پالائو","de":"Palau","es":"Palau","fr":"Palaos","ja":"パラオ","it":"Palau"},"name":"Palau","alpha2Code":"PW"},{"translations":{"br":"Palestina","pt":"Palestina","nl":"Palestijnse gebieden","hr":"Palestina","fa":"Ùلسطین","de":"Palästina","es":"Palestina","fr":"Palestine","ja":"パレスãƒãƒŠ","it":"Palestina"},"name":"Palestine, State of","alpha2Code":"PS"},{"translations":{"br":"Panamá","pt":"Panamá","nl":"Panama","hr":"Panama","fa":"پاناما","de":"Panama","es":"Panamá","fr":"Panama","ja":"パナマ","it":"Panama"},"name":"Panama","alpha2Code":"PA"},{"translations":{"br":"Papua Nova Guiné","pt":"Papua Nova Guiné","nl":"Papoea-Nieuw-Guinea","hr":"Papua Nova Gvineja","fa":"پاپوآ گینه نو","de":"Papua-Neuguinea","es":"Papúa Nueva Guinea","fr":"Papouasie-Nouvelle-Guinée","ja":"パプアニューギニア","it":"Papua Nuova Guinea"},"name":"Papua New Guinea","alpha2Code":"PG"},{"translations":{"br":"Paraguai","pt":"Paraguai","nl":"Paraguay","hr":"Paragvaj","fa":"پاراگوئه","de":"Paraguay","es":"Paraguay","fr":"Paraguay","ja":"パラグアイ","it":"Paraguay"},"name":"Paraguay","alpha2Code":"PY"},{"translations":{"br":"Peru","pt":"Peru","nl":"Peru","hr":"Peru","fa":"پرو","de":"Peru","es":"Perú","fr":"Pérou","ja":"ペルー","it":"Perù"},"name":"Peru","alpha2Code":"PE"},{"translations":{"br":"Filipinas","pt":"Filipinas","nl":"Filipijnen","hr":"Filipini","fa":"جزایر الندÙیلیپین","de":"Philippinen","es":"Filipinas","fr":"Philippines","ja":"フィリピン","it":"Filippine"},"name":"Philippines","alpha2Code":"PH"},{"translations":{"br":"Ilhas Pitcairn","pt":"Ilhas Picárnia","nl":"Pitcairneilanden","hr":"Pitcairnovo otoÄje","fa":"پیتکرن","de":"Pitcairn","es":"Islas Pitcairn","fr":"ÃŽles Pitcairn","ja":"ピトケアン","it":"Isole Pitcairn"},"name":"Pitcairn","alpha2Code":"PN"},{"translations":{"br":"Polônia","pt":"Polónia","nl":"Polen","hr":"Poljska","fa":"لهستان","de":"Polen","es":"Polonia","fr":"Pologne","ja":"ãƒãƒ¼ãƒ©ãƒ³ãƒ‰","it":"Polonia"},"name":"Poland","alpha2Code":"PL"},{"translations":{"br":"Portugal","pt":"Portugal","nl":"Portugal","hr":"Portugal","fa":"پرتغال","de":"Portugal","es":"Portugal","fr":"Portugal","ja":"ãƒãƒ«ãƒˆã‚¬ãƒ«","it":"Portogallo"},"name":"Portugal","alpha2Code":"PT"},{"translations":{"br":"Porto Rico","pt":"Porto Rico","nl":"Puerto Rico","hr":"Portoriko","fa":"پورتو ریکو","de":"Puerto Rico","es":"Puerto Rico","fr":"Porto Rico","ja":"プエルトリコ","it":"Porto Rico"},"name":"Puerto Rico","alpha2Code":"PR"},{"translations":{"br":"Catar","pt":"Catar","nl":"Qatar","hr":"Katar","fa":"قطر","de":"Katar","es":"Catar","fr":"Qatar","ja":"カタール","it":"Qatar"},"name":"Qatar","alpha2Code":"QA"},{"translations":{"br":"Kosovo","pt":"Kosovo","hr":"Kosovo","fa":"کوزوو","es":"Kosovo"},"name":"Republic of Kosovo","alpha2Code":"XK"},{"translations":{"br":"Reunião","pt":"Reunião","nl":"Réunion","hr":"Réunion","fa":"رئونیون","de":"Réunion","es":"Reunión","fr":"Réunion","ja":"レユニオン","it":"Riunione"},"name":"Réunion","alpha2Code":"RE"},{"translations":{"br":"Romênia","pt":"Roménia","nl":"Roemenië","hr":"Rumunjska","fa":"رومانی","de":"Rumänien","es":"Rumania","fr":"Roumanie","ja":"ルーマニア","it":"Romania"},"name":"Romania","alpha2Code":"RO"},{"translations":{"br":"Rússia","pt":"Rússia","nl":"Rusland","hr":"Rusija","fa":"روسیه","de":"Russland","es":"Rusia","fr":"Russie","ja":"ロシア連邦","it":"Russia"},"name":"Russian Federation","alpha2Code":"RU"},{"translations":{"br":"Ruanda","pt":"Ruanda","nl":"Rwanda","hr":"Ruanda","fa":"رواندا","de":"Ruanda","es":"Ruanda","fr":"Rwanda","ja":"ルワンダ","it":"Ruanda"},"name":"Rwanda","alpha2Code":"RW"},{"translations":{"br":"São Bartolomeu","pt":"São Bartolomeu","nl":"Saint Barthélemy","hr":"Saint Barthélemy","fa":"سن-بارتلمی","de":"Saint-Barthélemy","es":"San Bartolomé","fr":"Saint-Barthélemy","ja":"サン・ãƒãƒ«ãƒ†ãƒ«ãƒŸãƒ¼","it":"Antille Francesi"},"name":"Saint Barthélemy","alpha2Code":"BL"},{"translations":{"br":"Santa Helena","pt":"Santa Helena","nl":"Sint-Helena","hr":"Sveta Helena","fa":"سنت هلنا، اسنشن Ùˆ تریستان دا کونا","de":"Sankt Helena","es":"Santa Helena","fr":"Sainte-Hélène","ja":"セントヘレナ・アセンションãŠã‚ˆã³ãƒˆãƒªã‚¹ã‚¿ãƒ³ãƒ€ã‚¯ãƒ¼ãƒ‹ãƒ£","it":"Sant\'Elena"},"name":"Saint Helena, Ascension and Tristan da Cunha","alpha2Code":"SH"},{"translations":{"br":"São Cristóvão e Neves","pt":"São Cristóvão e Neves","nl":"Saint Kitts en Nevis","hr":"Sveti Kristof i Nevis","fa":"سنت کیتس Ùˆ نویس","de":"St. Kitts und Nevis","es":"San Cristóbal y Nieves","fr":"Saint-Christophe-et-Niévès","ja":"セントクリストファー・ãƒã‚¤ãƒ“ス","it":"Saint Kitts e Nevis"},"name":"Saint Kitts and Nevis","alpha2Code":"KN"},{"translations":{"br":"Santa Lúcia","pt":"Santa Lúcia","nl":"Saint Lucia","hr":"Sveta Lucija","fa":"سنت لوسیا","de":"Saint Lucia","es":"Santa Lucía","fr":"Saint-Lucie","ja":"セントルシア","it":"Santa Lucia"},"name":"Saint Lucia","alpha2Code":"LC"},{"translations":{"br":"Saint Martin","pt":"Ilha São Martinho","nl":"Saint-Martin","hr":"Sveti Martin","fa":"سینت مارتن","de":"Saint Martin","es":"Saint Martin","fr":"Saint-Martin","ja":"サン・マルタン(フランス領)","it":"Saint Martin"},"name":"Saint Martin (French part)","alpha2Code":"MF"},{"translations":{"br":"Saint-Pierre e Miquelon","pt":"São Pedro e Miquelon","nl":"Saint Pierre en Miquelon","hr":"Sveti Petar i Mikelon","fa":"سن پیر Ùˆ میکلن","de":"Saint-Pierre und Miquelon","es":"San Pedro y Miquelón","fr":"Saint-Pierre-et-Miquelon","ja":"サンピエール島・ミクロン島","it":"Saint-Pierre e Miquelon"},"name":"Saint Pierre and Miquelon","alpha2Code":"PM"},{"translations":{"br":"São Vicente e Granadinas","pt":"São Vicente e Granadinas","nl":"Saint Vincent en de Grenadines","hr":"Sveti Vincent i Grenadini","fa":"سنت وینسنت Ùˆ گرنادین‌ها","de":"Saint Vincent und die Grenadinen","es":"San Vicente y Granadinas","fr":"Saint-Vincent-et-les-Grenadines","ja":"セントビンセントãŠã‚ˆã³ã‚°ãƒ¬ãƒŠãƒ‡ã‚£ãƒ¼ãƒ³è«¸å³¶","it":"Saint Vincent e Grenadine"},"name":"Saint Vincent and the Grenadines","alpha2Code":"VC"},{"translations":{"br":"Samoa","pt":"Samoa","nl":"Samoa","hr":"Samoa","fa":"ساموآ","de":"Samoa","es":"Samoa","fr":"Samoa","ja":"サモア","it":"Samoa"},"name":"Samoa","alpha2Code":"WS"},{"translations":{"br":"San Marino","pt":"São Marinho","nl":"San Marino","hr":"San Marino","fa":"سان مارینو","de":"San Marino","es":"San Marino","fr":"Saint-Marin","ja":"サンマリノ","it":"San Marino"},"name":"San Marino","alpha2Code":"SM"},{"translations":{"br":"São Tomé e Príncipe","pt":"São Tomé e Príncipe","nl":"Sao Tomé en Principe","hr":"Sveti Toma i Princip","fa":"کواترو دو Ùرویرو","de":"São Tomé und Príncipe","es":"Santo Tomé y Príncipe","fr":"Sao Tomé-et-Principe","ja":"サントメ・プリンシペ","it":"São Tomé e Príncipe"},"name":"Sao Tome and Principe","alpha2Code":"ST"},{"translations":{"br":"Arábia Saudita","pt":"Arábia Saudita","nl":"Saoedi-Arabië","hr":"Saudijska Arabija","fa":"عربستان سعودی","de":"Saudi-Arabien","es":"Arabia Saudí","fr":"Arabie Saoudite","ja":"サウジアラビア","it":"Arabia Saudita"},"name":"Saudi Arabia","alpha2Code":"SA"},{"translations":{"br":"Senegal","pt":"Senegal","nl":"Senegal","hr":"Senegal","fa":"سنگال","de":"Senegal","es":"Senegal","fr":"Sénégal","ja":"ã‚»ãƒã‚¬ãƒ«","it":"Senegal"},"name":"Senegal","alpha2Code":"SN"},{"translations":{"br":"Sérvia","pt":"Sérvia","nl":"Servië","hr":"Srbija","fa":"صربستان","de":"Serbien","es":"Serbia","fr":"Serbie","ja":"セルビア","it":"Serbia"},"name":"Serbia","alpha2Code":"RS"},{"translations":{"br":"Seicheles","pt":"Seicheles","nl":"Seychellen","hr":"SejÅ¡eli","fa":"سیشل","de":"Seychellen","es":"Seychelles","fr":"Seychelles","ja":"セーシェル","it":"Seychelles"},"name":"Seychelles","alpha2Code":"SC"},{"translations":{"br":"Serra Leoa","pt":"Serra Leoa","nl":"Sierra Leone","hr":"Sijera Leone","fa":"سیرالئون","de":"Sierra Leone","es":"Sierra Leone","fr":"Sierra Leone","ja":"シエラレオãƒ","it":"Sierra Leone"},"name":"Sierra Leone","alpha2Code":"SL"},{"translations":{"br":"Singapura","pt":"Singapura","nl":"Singapore","hr":"Singapur","fa":"سنگاپور","de":"Singapur","es":"Singapur","fr":"Singapour","ja":"シンガãƒãƒ¼ãƒ«","it":"Singapore"},"name":"Singapore","alpha2Code":"SG"},{"translations":{"br":"Sint Maarten","pt":"São Martinho","nl":"Sint Maarten","fa":"سینت مارتن","de":"Sint Maarten (niederl. Teil)","fr":"Saint Martin (partie néerlandaise)","it":"Saint Martin (parte olandese)"},"name":"Sint Maarten (Dutch part)","alpha2Code":"SX"},{"translations":{"br":"Eslováquia","pt":"Eslováquia","nl":"Slowakije","hr":"SlovaÄka","fa":"اسلواکی","de":"Slowakei","es":"República Eslovaca","fr":"Slovaquie","ja":"スロãƒã‚­ã‚¢","it":"Slovacchia"},"name":"Slovakia","alpha2Code":"SK"},{"translations":{"br":"Eslovênia","pt":"Eslovénia","nl":"Slovenië","hr":"Slovenija","fa":"اسلوونی","de":"Slowenien","es":"Eslovenia","fr":"Slovénie","ja":"スロベニア","it":"Slovenia"},"name":"Slovenia","alpha2Code":"SI"},{"translations":{"br":"Ilhas Salomão","pt":"Ilhas Salomão","nl":"Salomonseilanden","hr":"Solomonski Otoci","fa":"جزایر سلیمان","de":"Salomonen","es":"Islas Salomón","fr":"ÃŽles Salomon","ja":"ソロモン諸島","it":"Isole Salomone"},"name":"Solomon Islands","alpha2Code":"SB"},{"translations":{"br":"Somália","pt":"Somália","nl":"Somalië","hr":"Somalija","fa":"سومالی","de":"Somalia","es":"Somalia","fr":"Somalie","ja":"ソマリア","it":"Somalia"},"name":"Somalia","alpha2Code":"SO"},{"translations":{"br":"República Sul-Africana","pt":"República Sul-Africana","nl":"Zuid-Afrika","hr":"JužnoafriÄka Republika","fa":"Ø¢Ùریقای جنوبی","de":"Republik Südafrika","es":"República de Sudáfrica","fr":"Afrique du Sud","ja":"å—アフリカ","it":"Sud Africa"},"name":"South Africa","alpha2Code":"ZA"},{"translations":{"br":"Ilhas Geórgias do Sul e Sandwich do Sul","pt":"Ilhas Geórgia do Sul e Sanduíche do Sul","nl":"Zuid-Georgia en Zuidelijke Sandwicheilanden","hr":"Južna Georgija i otoÄje Južni Sandwich","fa":"جزایر جورجیای جنوبی Ùˆ ساندویچ جنوبی","de":"Südgeorgien und die Südlichen Sandwichinseln","es":"Islas Georgias del Sur y Sandwich del Sur","fr":"Géorgie du Sud-et-les ÃŽles Sandwich du Sud","ja":"サウスジョージア・サウスサンドウィッãƒè«¸å³¶","it":"Georgia del Sud e Isole Sandwich Meridionali"},"name":"South Georgia and the South Sandwich Islands","alpha2Code":"GS"},{"translations":{"br":"Coreia do Sul","pt":"Coreia do Sul","nl":"Zuid-Korea","hr":"Južna Koreja","fa":"کره شمالی","de":"Südkorea","es":"Corea del Sur","fr":"Corée du Sud","ja":"大韓民国","it":"Corea del Sud"},"name":"Korea (Republic of)","alpha2Code":"KR"},{"translations":{"br":"Sudão do Sul","pt":"Sudão do Sul","nl":"Zuid-Soedan","hr":"Južni Sudan","fa":"سودان جنوبی","de":"Südsudan","es":"Sudán del Sur","fr":"Soudan du Sud","ja":"å—スーダン","it":"Sudan del sud"},"name":"South Sudan","alpha2Code":"SS"},{"translations":{"br":"Espanha","pt":"Espanha","nl":"Spanje","hr":"Å panjolska","fa":"اسپانیا","de":"Spanien","es":"España","fr":"Espagne","ja":"スペイン","it":"Spagna"},"name":"Spain","alpha2Code":"ES"},{"translations":{"br":"Sri Lanka","pt":"Sri Lanka","nl":"Sri Lanka","hr":"Å ri Lanka","fa":"سری‌لانکا","de":"Sri Lanka","es":"Sri Lanka","fr":"Sri Lanka","ja":"スリランカ","it":"Sri Lanka"},"name":"Sri Lanka","alpha2Code":"LK"},{"translations":{"br":"Sudão","pt":"Sudão","nl":"Soedan","hr":"Sudan","fa":"سودان","de":"Sudan","es":"Sudán","fr":"Soudan","ja":"スーダン","it":"Sudan"},"name":"Sudan","alpha2Code":"SD"},{"translations":{"br":"Suriname","pt":"Suriname","nl":"Suriname","hr":"Surinam","fa":"سورینام","de":"Suriname","es":"Surinam","fr":"Surinam","ja":"スリナム","it":"Suriname"},"name":"Suriname","alpha2Code":"SR"},{"translations":{"br":"Svalbard","pt":"Svalbard","nl":"Svalbard en Jan Mayen","hr":"Svalbard i Jan Mayen","fa":"سوالبارد Ùˆ یان ماین","de":"Svalbard und Jan Mayen","es":"Islas Svalbard y Jan Mayen","fr":"Svalbard et Jan Mayen","ja":"スヴァールãƒãƒ«è«¸å³¶ãŠã‚ˆã³ãƒ¤ãƒ³ãƒžã‚¤ã‚¨ãƒ³å³¶","it":"Svalbard e Jan Mayen"},"name":"Svalbard and Jan Mayen","alpha2Code":"SJ"},{"translations":{"br":"Suazilândia","pt":"Suazilândia","nl":"Swaziland","hr":"Svazi","fa":"سوازیلند","de":"Swasiland","es":"Suazilandia","fr":"Swaziland","ja":"スワジランド","it":"Swaziland"},"name":"Swaziland","alpha2Code":"SZ"},{"translations":{"br":"Suécia","pt":"Suécia","nl":"Zweden","hr":"Å vedska","fa":"سوئد","de":"Schweden","es":"Suecia","fr":"Suède","ja":"スウェーデン","it":"Svezia"},"name":"Sweden","alpha2Code":"SE"},{"translations":{"br":"Suíça","pt":"Suíça","nl":"Zwitserland","hr":"Å vicarska","fa":"سوئیس","de":"Schweiz","es":"Suiza","fr":"Suisse","ja":"スイス","it":"Svizzera"},"name":"Switzerland","alpha2Code":"CH"},{"translations":{"br":"Síria","pt":"Síria","nl":"Syrië","hr":"Sirija","fa":"سوریه","de":"Syrien","es":"Siria","fr":"Syrie","ja":"シリア・アラブ共和国","it":"Siria"},"name":"Syrian Arab Republic","alpha2Code":"SY"},{"translations":{"br":"Taiwan","pt":"Taiwan","nl":"Taiwan","hr":"Tajvan","fa":"تایوان","de":"Taiwan","es":"Taiwán","fr":"Taïwan","ja":"å°æ¹¾ï¼ˆä¸­è¯æ°‘国)","it":"Taiwan"},"name":"Taiwan","alpha2Code":"TW"},{"translations":{"br":"Tajiquistão","pt":"Tajiquistão","nl":"Tadzjikistan","hr":"TaÄ‘ikistan","fa":"تاجیکستان","de":"Tadschikistan","es":"Tayikistán","fr":"Tadjikistan","ja":"タジキスタン","it":"Tagikistan"},"name":"Tajikistan","alpha2Code":"TJ"},{"translations":{"br":"Tanzânia","pt":"Tanzânia","nl":"Tanzania","hr":"Tanzanija","fa":"تانزانیا","de":"Tansania","es":"Tanzania","fr":"Tanzanie","ja":"タンザニア","it":"Tanzania"},"name":"Tanzania, United Republic of","alpha2Code":"TZ"},{"translations":{"br":"Tailândia","pt":"Tailândia","nl":"Thailand","hr":"Tajland","fa":"تایلند","de":"Thailand","es":"Tailandia","fr":"Thaïlande","ja":"タイ","it":"Tailandia"},"name":"Thailand","alpha2Code":"TH"},{"translations":{"br":"Timor Leste","pt":"Timor Leste","nl":"Oost-Timor","hr":"IstoÄni Timor","fa":"تیمور شرقی","de":"Timor-Leste","es":"Timor Oriental","fr":"Timor oriental","ja":"æ±ãƒ†ã‚£ãƒ¢ãƒ¼ãƒ«","it":"Timor Est"},"name":"Timor-Leste","alpha2Code":"TL"},{"translations":{"br":"Togo","pt":"Togo","nl":"Togo","hr":"Togo","fa":"توگو","de":"Togo","es":"Togo","fr":"Togo","ja":"トーゴ","it":"Togo"},"name":"Togo","alpha2Code":"TG"},{"translations":{"br":"Tokelau","pt":"Toquelau","nl":"Tokelau","hr":"Tokelau","fa":"توکلائو","de":"Tokelau","es":"Islas Tokelau","fr":"Tokelau","ja":"トケラウ","it":"Isole Tokelau"},"name":"Tokelau","alpha2Code":"TK"},{"translations":{"br":"Tonga","pt":"Tonga","nl":"Tonga","hr":"Tonga","fa":"تونگا","de":"Tonga","es":"Tonga","fr":"Tonga","ja":"トンガ","it":"Tonga"},"name":"Tonga","alpha2Code":"TO"},{"translations":{"br":"Trinidad e Tobago","pt":"Trindade e Tobago","nl":"Trinidad en Tobago","hr":"Trinidad i Tobago","fa":"ترینیداد Ùˆ توباگو","de":"Trinidad und Tobago","es":"Trinidad y Tobago","fr":"Trinité et Tobago","ja":"トリニダード・トãƒã‚´","it":"Trinidad e Tobago"},"name":"Trinidad and Tobago","alpha2Code":"TT"},{"translations":{"br":"Tunísia","pt":"Tunísia","nl":"Tunesië","hr":"Tunis","fa":"تونس","de":"Tunesien","es":"Túnez","fr":"Tunisie","ja":"ãƒãƒ¥ãƒ‹ã‚¸ã‚¢","it":"Tunisia"},"name":"Tunisia","alpha2Code":"TN"},{"translations":{"br":"Turquia","pt":"Turquia","nl":"Turkije","hr":"Turska","fa":"ترکیه","de":"Türkei","es":"Turquía","fr":"Turquie","ja":"トルコ","it":"Turchia"},"name":"Turkey","alpha2Code":"TR"},{"translations":{"br":"Turcomenistão","pt":"Turquemenistão","nl":"Turkmenistan","hr":"Turkmenistan","fa":"ترکمنستان","de":"Turkmenistan","es":"Turkmenistán","fr":"Turkménistan","ja":"トルクメニスタン","it":"Turkmenistan"},"name":"Turkmenistan","alpha2Code":"TM"},{"translations":{"br":"Ilhas Turcas e Caicos","pt":"Ilhas Turcas e Caicos","nl":"Turks- en Caicoseilanden","hr":"Otoci Turks i Caicos","fa":"جزایر تورکس Ùˆ کایکوس","de":"Turks- und Caicosinseln","es":"Islas Turks y Caicos","fr":"ÃŽles Turques-et-Caïques","ja":"タークス・カイコス諸島","it":"Isole Turks e Caicos"},"name":"Turks and Caicos Islands","alpha2Code":"TC"},{"translations":{"br":"Tuvalu","pt":"Tuvalu","nl":"Tuvalu","hr":"Tuvalu","fa":"تووالو","de":"Tuvalu","es":"Tuvalu","fr":"Tuvalu","ja":"ツãƒãƒ«","it":"Tuvalu"},"name":"Tuvalu","alpha2Code":"TV"},{"translations":{"br":"Uganda","pt":"Uganda","nl":"Oeganda","hr":"Uganda","fa":"اوگاندا","de":"Uganda","es":"Uganda","fr":"Uganda","ja":"ウガンダ","it":"Uganda"},"name":"Uganda","alpha2Code":"UG"},{"translations":{"br":"Ucrânia","pt":"Ucrânia","nl":"Oekraïne","hr":"Ukrajina","fa":"وکراین","de":"Ukraine","es":"Ucrania","fr":"Ukraine","ja":"ウクライナ","it":"Ucraina"},"name":"Ukraine","alpha2Code":"UA"},{"translations":{"br":"Emirados árabes Unidos","pt":"Emirados árabes Unidos","nl":"Verenigde Arabische Emiraten","hr":"Ujedinjeni Arapski Emirati","fa":"امارات متحده عربی","de":"Vereinigte Arabische Emirate","es":"Emiratos Ãrabes Unidos","fr":"Émirats arabes unis","ja":"アラブ首長国連邦","it":"Emirati Arabi Uniti"},"name":"United Arab Emirates","alpha2Code":"AE"},{"translations":{"br":"Reino Unido","pt":"Reino Unido","nl":"Verenigd Koninkrijk","hr":"Ujedinjeno Kraljevstvo","fa":"بریتانیای کبیر Ùˆ ایرلند شمالی","de":"Vereinigtes Königreich","es":"Reino Unido","fr":"Royaume-Uni","ja":"イギリス","it":"Regno Unito"},"name":"United Kingdom of Great Britain and Northern Ireland","alpha2Code":"GB"},{"translations":{"br":"Estados Unidos","pt":"Estados Unidos","nl":"Verenigde Staten","hr":"Sjedinjene AmeriÄke Države","fa":"ایالات متحده آمریکا","de":"Vereinigte Staaten von Amerika","es":"Estados Unidos","fr":"États-Unis","ja":"アメリカåˆè¡†å›½","it":"Stati Uniti D\'America"},"name":"United States of America","alpha2Code":"US"},{"translations":{"br":"Uruguai","pt":"Uruguai","nl":"Uruguay","hr":"Urugvaj","fa":"اروگوئه","de":"Uruguay","es":"Uruguay","fr":"Uruguay","ja":"ウルグアイ","it":"Uruguay"},"name":"Uruguay","alpha2Code":"UY"},{"translations":{"br":"Uzbequistão","pt":"Usbequistão","nl":"Oezbekistan","hr":"Uzbekistan","fa":"ازبکستان","de":"Usbekistan","es":"Uzbekistán","fr":"Ouzbékistan","ja":"ウズベキスタン","it":"Uzbekistan"},"name":"Uzbekistan","alpha2Code":"UZ"},{"translations":{"br":"Vanuatu","pt":"Vanuatu","nl":"Vanuatu","hr":"Vanuatu","fa":"وانواتو","de":"Vanuatu","es":"Vanuatu","fr":"Vanuatu","ja":"ãƒãƒŒã‚¢ãƒ„","it":"Vanuatu"},"name":"Vanuatu","alpha2Code":"VU"},{"translations":{"br":"Venezuela","pt":"Venezuela","nl":"Venezuela","hr":"Venezuela","fa":"ونزوئلا","de":"Venezuela","es":"Venezuela","fr":"Venezuela","ja":"ベãƒã‚ºã‚¨ãƒ©ãƒ»ãƒœãƒªãƒãƒ«å…±å’Œå›½","it":"Venezuela"},"name":"Venezuela (Bolivarian Republic of)","alpha2Code":"VE"},{"translations":{"br":"Vietnã","pt":"Vietname","nl":"Vietnam","hr":"Vijetnam","fa":"ویتنام","de":"Vietnam","es":"Vietnam","fr":"Viêt Nam","ja":"ベトナム","it":"Vietnam"},"name":"Viet Nam","alpha2Code":"VN"},{"translations":{"br":"Wallis e Futuna","pt":"Wallis e Futuna","nl":"Wallis en Futuna","hr":"Wallis i Fortuna","fa":"والیس Ùˆ Ùوتونا","de":"Wallis und Futuna","es":"Wallis y Futuna","fr":"Wallis-et-Futuna","ja":"ウォリス・フツナ","it":"Wallis e Futuna"},"name":"Wallis and Futuna","alpha2Code":"WF"},{"translations":{"br":"Saara Ocidental","pt":"Saara Ocidental","nl":"Westelijke Sahara","hr":"Zapadna Sahara","fa":"جمهوری دموکراتیک عربی صحرا","de":"Westsahara","es":"Sahara Occidental","fr":"Sahara Occidental","ja":"西サãƒãƒ©","it":"Sahara Occidentale"},"name":"Western Sahara","alpha2Code":"EH"},{"translations":{"br":"Iêmen","pt":"Iémen","nl":"Jemen","hr":"Jemen","fa":"یمن","de":"Jemen","es":"Yemen","fr":"Yémen","ja":"イエメン","it":"Yemen"},"name":"Yemen","alpha2Code":"YE"},{"translations":{"br":"Zâmbia","pt":"Zâmbia","nl":"Zambia","hr":"Zambija","fa":"زامبیا","de":"Sambia","es":"Zambia","fr":"Zambie","ja":"ザンビア","it":"Zambia"},"name":"Zambia","alpha2Code":"ZM"},{"translations":{"br":"Zimbabwe","pt":"Zimbabué","nl":"Zimbabwe","hr":"Zimbabve","fa":"زیمباوه","de":"Simbabwe","es":"Zimbabue","fr":"Zimbabwe","ja":"ジンãƒãƒ–エ","it":"Zimbabwe"},"name":"Zimbabwe","alpha2Code":"ZW"}]', true); - -$countryKeys = array_map(function ($country) { - return Tools::strtoupper($country['alpha2Code']); -}, $countries); - -$langIso = Tools::strtolower(Context::getContext()->language->iso_code); -if (!in_array($langIso, array_keys($countries[0]['translations']))) { - $langIso = ''; -} - -if ($langIso) { - $countryValues = array_map(function ($country) use ($langIso) { - return $country['translations'][$langIso]; - }, $countries); -} else { - $countryValues = array_map(function ($country) { - return $country['name']; - }, $countries); -} - -$countries = array(); -foreach ($countryKeys as $index => $countryKey) { - $countries[] = array( - 'id' => $countryKey, - 'name' => $countryValues[$index], - ); -} - -return $countries; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +$countries = json_decode('[{"translations":{"br":"Afeganistão","pt":"Afeganistão","nl":"Afghanistan","hr":"Afganistan","fa":"اÙغانستان","de":"Afghanistan","es":"Afganistán","fr":"Afghanistan","ja":"アフガニスタン","it":"Afghanistan"},"name":"Afghanistan","alpha2Code":"AF"},{"translations":{"br":"Ilhas de Aland","pt":"Ilhas de Aland","nl":"Ã…landeilanden","hr":"Ã…landski otoci","fa":"جزایر الند","de":"Ã…land","es":"Alandia","fr":"Ã…land","ja":"オーランド諸島","it":"Isole Aland"},"name":"Ã…land Islands","alpha2Code":"AX"},{"translations":{"br":"Albânia","pt":"Albânia","nl":"Albanië","hr":"Albanija","fa":"آلبانی","de":"Albanien","es":"Albania","fr":"Albanie","ja":"アルãƒãƒ‹ã‚¢","it":"Albania"},"name":"Albania","alpha2Code":"AL"},{"translations":{"br":"Argélia","pt":"Argélia","nl":"Algerije","hr":"Alžir","fa":"الجزایر","de":"Algerien","es":"Argelia","fr":"Algérie","ja":"アルジェリア","it":"Algeria"},"name":"Algeria","alpha2Code":"DZ"},{"translations":{"br":"Samoa Americana","pt":"Samoa Americana","nl":"Amerikaans Samoa","hr":"AmeriÄka Samoa","fa":"ساموآی آمریکا","de":"Amerikanisch-Samoa","es":"Samoa Americana","fr":"Samoa américaines","ja":"アメリカ領サモア","it":"Samoa Americane"},"name":"American Samoa","alpha2Code":"AS"},{"translations":{"br":"Andorra","pt":"Andorra","nl":"Andorra","hr":"Andora","fa":"آندورا","de":"Andorra","es":"Andorra","fr":"Andorre","ja":"アンドラ","it":"Andorra"},"name":"Andorra","alpha2Code":"AD"},{"translations":{"br":"Angola","pt":"Angola","nl":"Angola","hr":"Angola","fa":"آنگولا","de":"Angola","es":"Angola","fr":"Angola","ja":"アンゴラ","it":"Angola"},"name":"Angola","alpha2Code":"AO"},{"translations":{"br":"Anguila","pt":"Anguila","nl":"Anguilla","hr":"Angvila","fa":"آنگویلا","de":"Anguilla","es":"Anguilla","fr":"Anguilla","ja":"アンギラ","it":"Anguilla"},"name":"Anguilla","alpha2Code":"AI"},{"translations":{"br":"Antártida","pt":"Antárctida","nl":"Antarctica","hr":"Antarktika","fa":"جنوبگان","de":"Antarktika","es":"Antártida","fr":"Antarctique","ja":"å—極大陸","it":"Antartide"},"name":"Antarctica","alpha2Code":"AQ"},{"translations":{"br":"Antígua e Barbuda","pt":"Antígua e Barbuda","nl":"Antigua en Barbuda","hr":"Antigva i Barbuda","fa":"آنتیگوا Ùˆ باربودا","de":"Antigua und Barbuda","es":"Antigua y Barbuda","fr":"Antigua-et-Barbuda","ja":"アンティグア・ãƒãƒ¼ãƒ–ーダ","it":"Antigua e Barbuda"},"name":"Antigua and Barbuda","alpha2Code":"AG"},{"translations":{"br":"Argentina","pt":"Argentina","nl":"Argentinië","hr":"Argentina","fa":"آرژانتین","de":"Argentinien","es":"Argentina","fr":"Argentine","ja":"アルゼンãƒãƒ³","it":"Argentina"},"name":"Argentina","alpha2Code":"AR"},{"translations":{"br":"Armênia","pt":"Arménia","nl":"Armenië","hr":"Armenija","fa":"ارمنستان","de":"Armenien","es":"Armenia","fr":"Arménie","ja":"アルメニア","it":"Armenia"},"name":"Armenia","alpha2Code":"AM"},{"translations":{"br":"Aruba","pt":"Aruba","nl":"Aruba","hr":"Aruba","fa":"آروبا","de":"Aruba","es":"Aruba","fr":"Aruba","ja":"アルãƒ","it":"Aruba"},"name":"Aruba","alpha2Code":"AW"},{"translations":{"br":"Austrália","pt":"Austrália","nl":"Australië","hr":"Australija","fa":"استرالیا","de":"Australien","es":"Australia","fr":"Australie","ja":"オーストラリア","it":"Australia"},"name":"Australia","alpha2Code":"AU"},{"translations":{"br":"áustria","pt":"áustria","nl":"Oostenrijk","hr":"Austrija","fa":"اتریش","de":"Österreich","es":"Austria","fr":"Autriche","ja":"オーストリア","it":"Austria"},"name":"Austria","alpha2Code":"AT"},{"translations":{"br":"Azerbaijão","pt":"Azerbaijão","nl":"Azerbeidzjan","hr":"Azerbajdžan","fa":"آذربایجان","de":"Aserbaidschan","es":"Azerbaiyán","fr":"Azerbaïdjan","ja":"アゼルãƒã‚¤ã‚¸ãƒ£ãƒ³","it":"Azerbaijan"},"name":"Azerbaijan","alpha2Code":"AZ"},{"translations":{"br":"Bahamas","pt":"Baamas","nl":"Bahama’s","hr":"Bahami","fa":"باهاما","de":"Bahamas","es":"Bahamas","fr":"Bahamas","ja":"ãƒãƒãƒž","it":"Bahamas"},"name":"Bahamas","alpha2Code":"BS"},{"translations":{"br":"Bahrein","pt":"Barém","nl":"Bahrein","hr":"Bahrein","fa":"بحرین","de":"Bahrain","es":"Bahrein","fr":"Bahreïn","ja":"ãƒãƒ¼ãƒ¬ãƒ¼ãƒ³","it":"Bahrein"},"name":"Bahrain","alpha2Code":"BH"},{"translations":{"br":"Bangladesh","pt":"Bangladeche","nl":"Bangladesh","hr":"BangladeÅ¡","fa":"بنگلادش","de":"Bangladesch","es":"Bangladesh","fr":"Bangladesh","ja":"ãƒãƒ³ã‚°ãƒ©ãƒ‡ã‚·ãƒ¥","it":"Bangladesh"},"name":"Bangladesh","alpha2Code":"BD"},{"translations":{"br":"Barbados","pt":"Barbados","nl":"Barbados","hr":"Barbados","fa":"باربادوس","de":"Barbados","es":"Barbados","fr":"Barbade","ja":"ãƒãƒ«ãƒãƒ‰ã‚¹","it":"Barbados"},"name":"Barbados","alpha2Code":"BB"},{"translations":{"br":"Bielorrússia","pt":"Bielorrússia","nl":"Wit-Rusland","hr":"Bjelorusija","fa":"بلاروس","de":"Weißrussland","es":"Bielorrusia","fr":"Biélorussie","ja":"ベラルーシ","it":"Bielorussia"},"name":"Belarus","alpha2Code":"BY"},{"translations":{"br":"Bélgica","pt":"Bélgica","nl":"België","hr":"Belgija","fa":"بلژیک","de":"Belgien","es":"Bélgica","fr":"Belgique","ja":"ベルギー","it":"Belgio"},"name":"Belgium","alpha2Code":"BE"},{"translations":{"br":"Belize","pt":"Belize","nl":"Belize","hr":"Belize","fa":"بلیز","de":"Belize","es":"Belice","fr":"Belize","ja":"ベリーズ","it":"Belize"},"name":"Belize","alpha2Code":"BZ"},{"translations":{"br":"Benin","pt":"Benim","nl":"Benin","hr":"Benin","fa":"بنین","de":"Benin","es":"Benín","fr":"Bénin","ja":"ベナン","it":"Benin"},"name":"Benin","alpha2Code":"BJ"},{"translations":{"br":"Bermudas","pt":"Bermudas","nl":"Bermuda","hr":"Bermudi","fa":"برمودا","de":"Bermuda","es":"Bermudas","fr":"Bermudes","ja":"ãƒãƒŸãƒ¥ãƒ¼ãƒ€","it":"Bermuda"},"name":"Bermuda","alpha2Code":"BM"},{"translations":{"br":"Butão","pt":"Butão","nl":"Bhutan","hr":"Butan","fa":"بوتان","de":"Bhutan","es":"Bután","fr":"Bhoutan","ja":"ブータン","it":"Bhutan"},"name":"Bhutan","alpha2Code":"BT"},{"translations":{"br":"Bolívia","pt":"Bolívia","nl":"Bolivia","hr":"Bolivija","fa":"بولیوی","de":"Bolivien","es":"Bolivia","fr":"Bolivie","ja":"ボリビア多民æ—国","it":"Bolivia"},"name":"Bolivia (Plurinational State of)","alpha2Code":"BO"},{"translations":{"br":"Bonaire","pt":"Bonaire","fa":"بونیر","de":"Bonaire, Sint Eustatius und Saba","fr":"Bonaire, Saint-Eustache et Saba","it":"Bonaire, Saint-Eustache e Saba"},"name":"Bonaire, Sint Eustatius and Saba","alpha2Code":"BQ"},{"translations":{"br":"Bósnia e Herzegovina","pt":"Bósnia e Herzegovina","nl":"Bosnië en Herzegovina","hr":"Bosna i Hercegovina","fa":"بوسنی Ùˆ هرزگوین","de":"Bosnien und Herzegowina","es":"Bosnia y Herzegovina","fr":"Bosnie-Herzégovine","ja":"ボスニア・ヘルツェゴビナ","it":"Bosnia ed Erzegovina"},"name":"Bosnia and Herzegovina","alpha2Code":"BA"},{"translations":{"br":"Botsuana","pt":"Botsuana","nl":"Botswana","hr":"Bocvana","fa":"بوتسوانا","de":"Botswana","es":"Botswana","fr":"Botswana","ja":"ボツワナ","it":"Botswana"},"name":"Botswana","alpha2Code":"BW"},{"translations":{"br":"Ilha Bouvet","pt":"Ilha Bouvet","nl":"Bouveteiland","hr":"Otok Bouvet","fa":"جزیره بووه","de":"Bouvetinsel","es":"Isla Bouvet","fr":"ÃŽle Bouvet","ja":"ブーベ島","it":"Isola Bouvet"},"name":"Bouvet Island","alpha2Code":"BV"},{"translations":{"br":"Brasil","pt":"Brasil","nl":"Brazilië","hr":"Brazil","fa":"برزیل","de":"Brasilien","es":"Brasil","fr":"Brésil","ja":"ブラジル","it":"Brasile"},"name":"Brazil","alpha2Code":"BR"},{"translations":{"br":"Território Britânico do Oceano íÃdico","pt":"Território Britânico do Oceano Ãndico","nl":"Britse Gebieden in de Indische Oceaan","hr":"Britanski Indijskooceanski teritorij","fa":"قلمرو بریتانیا در اقیانوس هند","de":"Britisches Territorium im Indischen Ozean","es":"Territorio Británico del Océano Ãndico","fr":"Territoire britannique de l\'océan Indien","ja":"イギリス領インド洋地域","it":"Territorio britannico dell\'oceano indiano"},"name":"British Indian Ocean Territory","alpha2Code":"IO"},{"translations":{"br":"Ilhas Menores Distantes dos Estados Unidos","pt":"Ilhas Menores Distantes dos Estados Unidos","nl":"Kleine afgelegen eilanden van de Verenigde Staten","hr":"Mali udaljeni otoci SAD-a","fa":"جزایر Ú©ÙˆÚ†Ú© حاشیه‌ای ایالات متحده آمریکا","de":"Kleinere Inselbesitzungen der Vereinigten Staaten","es":"Islas Ultramarinas Menores de Estados Unidos","fr":"ÃŽles mineures éloignées des États-Unis","ja":"åˆè¡†å›½é ˜æœ‰å°é›¢å³¶","it":"Isole minori esterne degli Stati Uniti d\'America"},"name":"United States Minor Outlying Islands","alpha2Code":"UM"},{"translations":{"br":"Ilhas Virgens Britânicas","pt":"Ilhas Virgens Britânicas","nl":"Britse Maagdeneilanden","hr":"Britanski DjeviÄanski Otoci","fa":"جزایر ویرجین بریتانیا","de":"Britische Jungferninseln","es":"Islas Vírgenes del Reino Unido","fr":"ÃŽles Vierges britanniques","ja":"イギリス領ヴァージン諸島","it":"Isole Vergini Britanniche"},"name":"Virgin Islands (British)","alpha2Code":"VG"},{"translations":{"br":"Ilhas Virgens Americanas","pt":"Ilhas Virgens Americanas","nl":"Verenigde Staten Maagdeneilanden","fa":"جزایر ویرجین آمریکا","de":"Amerikanische Jungferninseln","es":"Islas Vírgenes de los Estados Unidos","fr":"ÃŽles Vierges des États-Unis","ja":"アメリカ領ヴァージン諸島","it":"Isole Vergini americane"},"name":"Virgin Islands (U.S.)","alpha2Code":"VI"},{"translations":{"br":"Brunei","pt":"Brunei","nl":"Brunei","hr":"Brunej","fa":"برونئی","de":"Brunei","es":"Brunei","fr":"Brunei","ja":"ブルãƒã‚¤ãƒ»ãƒ€ãƒ«ã‚µãƒ©ãƒ¼ãƒ ","it":"Brunei"},"name":"Brunei Darussalam","alpha2Code":"BN"},{"translations":{"br":"Bulgária","pt":"Bulgária","nl":"Bulgarije","hr":"Bugarska","fa":"بلغارستان","de":"Bulgarien","es":"Bulgaria","fr":"Bulgarie","ja":"ブルガリア","it":"Bulgaria"},"name":"Bulgaria","alpha2Code":"BG"},{"translations":{"br":"Burkina Faso","pt":"Burquina Faso","nl":"Burkina Faso","hr":"Burkina Faso","fa":"بورکیناÙاسو","de":"Burkina Faso","es":"Burkina Faso","fr":"Burkina Faso","ja":"ブルキナファソ","it":"Burkina Faso"},"name":"Burkina Faso","alpha2Code":"BF"},{"translations":{"br":"Burundi","pt":"Burúndi","nl":"Burundi","hr":"Burundi","fa":"بوروندی","de":"Burundi","es":"Burundi","fr":"Burundi","ja":"ブルンジ","it":"Burundi"},"name":"Burundi","alpha2Code":"BI"},{"translations":{"br":"Camboja","pt":"Camboja","nl":"Cambodja","hr":"Kambodža","fa":"کامبوج","de":"Kambodscha","es":"Camboya","fr":"Cambodge","ja":"カンボジア","it":"Cambogia"},"name":"Cambodia","alpha2Code":"KH"},{"translations":{"br":"Camarões","pt":"Camarões","nl":"Kameroen","hr":"Kamerun","fa":"کامرون","de":"Kamerun","es":"Camerún","fr":"Cameroun","ja":"カメルーン","it":"Camerun"},"name":"Cameroon","alpha2Code":"CM"},{"translations":{"br":"Canadá","pt":"Canadá","nl":"Canada","hr":"Kanada","fa":"کانادا","de":"Kanada","es":"Canadá","fr":"Canada","ja":"カナダ","it":"Canada"},"name":"Canada","alpha2Code":"CA"},{"translations":{"br":"Cabo Verde","pt":"Cabo Verde","nl":"Kaapverdië","hr":"Zelenortska Republika","fa":"کیپ ورد","de":"Kap Verde","es":"Cabo Verde","fr":"Cap Vert","ja":"カーボベルデ","it":"Capo Verde"},"name":"Cabo Verde","alpha2Code":"CV"},{"translations":{"br":"Ilhas Cayman","pt":"Ilhas Caimão","nl":"Caymaneilanden","hr":"Kajmanski otoci","fa":"جزایر کیمن","de":"Kaimaninseln","es":"Islas Caimán","fr":"ÃŽles Caïmans","ja":"ケイマン諸島","it":"Isole Cayman"},"name":"Cayman Islands","alpha2Code":"KY"},{"translations":{"br":"República Centro-Africana","pt":"República Centro-Africana","nl":"Centraal-Afrikaanse Republiek","hr":"SrednjoafriÄka Republika","fa":"جمهوری Ø¢Ùریقای مرکزی","de":"Zentralafrikanische Republik","es":"República Centroafricana","fr":"République centrafricaine","ja":"中央アフリカ共和国","it":"Repubblica Centrafricana"},"name":"Central African Republic","alpha2Code":"CF"},{"translations":{"br":"Chade","pt":"Chade","nl":"Tsjaad","hr":"ÄŒad","fa":"چاد","de":"Tschad","es":"Chad","fr":"Tchad","ja":"ãƒãƒ£ãƒ‰","it":"Ciad"},"name":"Chad","alpha2Code":"TD"},{"translations":{"br":"Chile","pt":"Chile","nl":"Chili","hr":"ÄŒile","fa":"شیلی","de":"Chile","es":"Chile","fr":"Chili","ja":"ãƒãƒª","it":"Cile"},"name":"Chile","alpha2Code":"CL"},{"translations":{"br":"China","pt":"China","nl":"China","hr":"Kina","fa":"چین","de":"China","es":"China","fr":"Chine","ja":"中国","it":"Cina"},"name":"China","alpha2Code":"CN"},{"translations":{"br":"Ilha Christmas","pt":"Ilha do Natal","nl":"Christmaseiland","hr":"Božićni otok","fa":"جزیره کریسمس","de":"Weihnachtsinsel","es":"Isla de Navidad","fr":"ÃŽle Christmas","ja":"クリスマス島","it":"Isola di Natale"},"name":"Christmas Island","alpha2Code":"CX"},{"translations":{"br":"Ilhas Cocos","pt":"Ilhas dos Cocos","nl":"Cocoseilanden","hr":"Kokosovi Otoci","fa":"جزایر کوکوس","de":"Kokosinseln","es":"Islas Cocos o Islas Keeling","fr":"ÃŽles Cocos","ja":"ココス(キーリング)諸島","it":"Isole Cocos e Keeling"},"name":"Cocos (Keeling) Islands","alpha2Code":"CC"},{"translations":{"br":"Colômbia","pt":"Colômbia","nl":"Colombia","hr":"Kolumbija","fa":"کلمبیا","de":"Kolumbien","es":"Colombia","fr":"Colombie","ja":"コロンビア","it":"Colombia"},"name":"Colombia","alpha2Code":"CO"},{"translations":{"br":"Comores","pt":"Comores","nl":"Comoren","hr":"Komori","fa":"کومور","de":"Union der Komoren","es":"Comoras","fr":"Comores","ja":"コモロ","it":"Comore"},"name":"Comoros","alpha2Code":"KM"},{"translations":{"br":"Congo","pt":"Congo","nl":"Congo [Republiek]","hr":"Kongo","fa":"Ú©Ù†Ú¯Ùˆ","de":"Kongo","es":"Congo","fr":"Congo","ja":"コンゴ共和国","it":"Congo"},"name":"Congo","alpha2Code":"CG"},{"translations":{"br":"RD Congo","pt":"RD Congo","nl":"Congo [DRC]","hr":"Kongo, Demokratska Republika","fa":"جمهوری Ú©Ù†Ú¯Ùˆ","de":"Kongo (Dem. Rep.)","es":"Congo (Rep. Dem.)","fr":"Congo (Rép. dém.)","ja":"コンゴ民主共和国","it":"Congo (Rep. Dem.)"},"name":"Congo (Democratic Republic of the)","alpha2Code":"CD"},{"translations":{"br":"Ilhas Cook","pt":"Ilhas Cook","nl":"Cookeilanden","hr":"Cookovo OtoÄje","fa":"جزایر Ú©ÙˆÚ©","de":"Cookinseln","es":"Islas Cook","fr":"ÃŽles Cook","ja":"クック諸島","it":"Isole Cook"},"name":"Cook Islands","alpha2Code":"CK"},{"translations":{"br":"Costa Rica","pt":"Costa Rica","nl":"Costa Rica","hr":"Kostarika","fa":"کاستاریکا","de":"Costa Rica","es":"Costa Rica","fr":"Costa Rica","ja":"コスタリカ","it":"Costa Rica"},"name":"Costa Rica","alpha2Code":"CR"},{"translations":{"br":"Croácia","pt":"Croácia","nl":"Kroatië","hr":"Hrvatska","fa":"کرواسی","de":"Kroatien","es":"Croacia","fr":"Croatie","ja":"クロアãƒã‚¢","it":"Croazia"},"name":"Croatia","alpha2Code":"HR"},{"translations":{"br":"Cuba","pt":"Cuba","nl":"Cuba","hr":"Kuba","fa":"کوبا","de":"Kuba","es":"Cuba","fr":"Cuba","ja":"キューãƒ","it":"Cuba"},"name":"Cuba","alpha2Code":"CU"},{"translations":{"br":"Curaçao","pt":"Curaçao","nl":"Curaçao","fa":"کوراسائو","de":"Curaçao","fr":"Curaçao","it":"Curaçao"},"name":"Curaçao","alpha2Code":"CW"},{"translations":{"br":"Chipre","pt":"Chipre","nl":"Cyprus","hr":"Cipar","fa":"قبرس","de":"Zypern","es":"Chipre","fr":"Chypre","ja":"キプロス","it":"Cipro"},"name":"Cyprus","alpha2Code":"CY"},{"translations":{"br":"República Tcheca","pt":"República Checa","nl":"Tsjechië","hr":"ÄŒeÅ¡ka","fa":"جمهوری Ú†Ú©","de":"Tschechische Republik","es":"República Checa","fr":"République tchèque","ja":"ãƒã‚§ã‚³","it":"Repubblica Ceca"},"name":"Czech Republic","alpha2Code":"CZ"},{"translations":{"br":"Dinamarca","pt":"Dinamarca","nl":"Denemarken","hr":"Danska","fa":"دانمارک","de":"Dänemark","es":"Dinamarca","fr":"Danemark","ja":"デンマーク","it":"Danimarca"},"name":"Denmark","alpha2Code":"DK"},{"translations":{"br":"Djibuti","pt":"Djibuti","nl":"Djibouti","hr":"Džibuti","fa":"جیبوتی","de":"Dschibuti","es":"Yibuti","fr":"Djibouti","ja":"ジブãƒ","it":"Gibuti"},"name":"Djibouti","alpha2Code":"DJ"},{"translations":{"br":"Dominica","pt":"Dominica","nl":"Dominica","hr":"Dominika","fa":"دومینیکا","de":"Dominica","es":"Dominica","fr":"Dominique","ja":"ドミニカ国","it":"Dominica"},"name":"Dominica","alpha2Code":"DM"},{"translations":{"br":"República Dominicana","pt":"República Dominicana","nl":"Dominicaanse Republiek","hr":"Dominikanska Republika","fa":"جمهوری دومینیکن","de":"Dominikanische Republik","es":"República Dominicana","fr":"République dominicaine","ja":"ドミニカ共和国","it":"Repubblica Dominicana"},"name":"Dominican Republic","alpha2Code":"DO"},{"translations":{"br":"Equador","pt":"Equador","nl":"Ecuador","hr":"Ekvador","fa":"اکوادور","de":"Ecuador","es":"Ecuador","fr":"Équateur","ja":"エクアドル","it":"Ecuador"},"name":"Ecuador","alpha2Code":"EC"},{"translations":{"br":"Egito","pt":"Egipto","nl":"Egypte","hr":"Egipat","fa":"مصر","de":"Ägypten","es":"Egipto","fr":"Égypte","ja":"エジプト","it":"Egitto"},"name":"Egypt","alpha2Code":"EG"},{"translations":{"br":"El Salvador","pt":"El Salvador","nl":"El Salvador","hr":"Salvador","fa":"السالوادور","de":"El Salvador","es":"El Salvador","fr":"Salvador","ja":"エルサルãƒãƒ‰ãƒ«","it":"El Salvador"},"name":"El Salvador","alpha2Code":"SV"},{"translations":{"br":"Guiné Equatorial","pt":"Guiné Equatorial","nl":"Equatoriaal-Guinea","hr":"Ekvatorijalna Gvineja","fa":"گینه استوایی","de":"Äquatorial-Guinea","es":"Guinea Ecuatorial","fr":"Guinée-Équatoriale","ja":"赤é“ギニア","it":"Guinea Equatoriale"},"name":"Equatorial Guinea","alpha2Code":"GQ"},{"translations":{"br":"Eritreia","pt":"Eritreia","nl":"Eritrea","hr":"Eritreja","fa":"اریتره","de":"Eritrea","es":"Eritrea","fr":"Érythrée","ja":"エリトリア","it":"Eritrea"},"name":"Eritrea","alpha2Code":"ER"},{"translations":{"br":"Estônia","pt":"Estónia","nl":"Estland","hr":"Estonija","fa":"استونی","de":"Estland","es":"Estonia","fr":"Estonie","ja":"エストニア","it":"Estonia"},"name":"Estonia","alpha2Code":"EE"},{"translations":{"br":"Etiópia","pt":"Etiópia","nl":"Ethiopië","hr":"Etiopija","fa":"اتیوپی","de":"Äthiopien","es":"Etiopía","fr":"Éthiopie","ja":"エãƒã‚ªãƒ”ã‚¢","it":"Etiopia"},"name":"Ethiopia","alpha2Code":"ET"},{"translations":{"br":"Ilhas Malvinas","pt":"Ilhas Falkland","nl":"Falklandeilanden [Islas Malvinas]","hr":"Falklandski Otoci","fa":"جزایر Ùالکلند","de":"Falklandinseln","es":"Islas Malvinas","fr":"ÃŽles Malouines","ja":"フォークランド(マルビナス)諸島","it":"Isole Falkland o Isole Malvine"},"name":"Falkland Islands (Malvinas)","alpha2Code":"FK"},{"translations":{"br":"Ilhas Faroé","pt":"Ilhas Faroé","nl":"Faeröer","hr":"Farski Otoci","fa":"جزایر Ùارو","de":"Färöer-Inseln","es":"Islas Faroe","fr":"ÃŽles Féroé","ja":"フェロー諸島","it":"Isole Far Oer"},"name":"Faroe Islands","alpha2Code":"FO"},{"translations":{"br":"Fiji","pt":"Fiji","nl":"Fiji","hr":"FiÄ‘i","fa":"Ùیجی","de":"Fidschi","es":"Fiyi","fr":"Fidji","ja":"フィジー","it":"Figi"},"name":"Fiji","alpha2Code":"FJ"},{"translations":{"br":"Finlândia","pt":"Finlândia","nl":"Finland","hr":"Finska","fa":"Ùنلاند","de":"Finnland","es":"Finlandia","fr":"Finlande","ja":"フィンランド","it":"Finlandia"},"name":"Finland","alpha2Code":"FI"},{"translations":{"br":"França","pt":"França","nl":"Frankrijk","hr":"Francuska","fa":"Ùرانسه","de":"Frankreich","es":"Francia","fr":"France","ja":"フランス","it":"Francia"},"name":"France","alpha2Code":"FR"},{"translations":{"br":"Guiana Francesa","pt":"Guiana Francesa","nl":"Frans-Guyana","hr":"Francuska Gvajana","fa":"گویان Ùرانسه","de":"Französisch Guyana","es":"Guayana Francesa","fr":"Guayane","ja":"フランス領ギアナ","it":"Guyana francese"},"name":"French Guiana","alpha2Code":"GF"},{"translations":{"br":"Polinésia Francesa","pt":"Polinésia Francesa","nl":"Frans-Polynesië","hr":"Francuska Polinezija","fa":"پلی‌نزی Ùرانسه","de":"Französisch-Polynesien","es":"Polinesia Francesa","fr":"Polynésie française","ja":"フランス領ãƒãƒªãƒã‚·ã‚¢","it":"Polinesia Francese"},"name":"French Polynesia","alpha2Code":"PF"},{"translations":{"br":"Terras Austrais e Antárticas Francesas","pt":"Terras Austrais e Antárticas Francesas","nl":"Franse Gebieden in de zuidelijke Indische Oceaan","hr":"Francuski južni i antarktiÄki teritoriji","fa":"سرزمین‌های جنوبی Ùˆ جنوبگانی Ùرانسه","de":"Französische Süd- und Antarktisgebiete","es":"Tierras Australes y Antárticas Francesas","fr":"Terres australes et antarctiques françaises","ja":"フランス領å—方・å—極地域","it":"Territori Francesi del Sud"},"name":"French Southern Territories","alpha2Code":"TF"},{"translations":{"br":"Gabão","pt":"Gabão","nl":"Gabon","hr":"Gabon","fa":"گابن","de":"Gabun","es":"Gabón","fr":"Gabon","ja":"ガボン","it":"Gabon"},"name":"Gabon","alpha2Code":"GA"},{"translations":{"br":"Gâmbia","pt":"Gâmbia","nl":"Gambia","hr":"Gambija","fa":"گامبیا","de":"Gambia","es":"Gambia","fr":"Gambie","ja":"ガンビア","it":"Gambia"},"name":"Gambia","alpha2Code":"GM"},{"translations":{"br":"Geórgia","pt":"Geórgia","nl":"Georgië","hr":"Gruzija","fa":"گرجستان","de":"Georgien","es":"Georgia","fr":"Géorgie","ja":"グルジア","it":"Georgia"},"name":"Georgia","alpha2Code":"GE"},{"translations":{"br":"Alemanha","pt":"Alemanha","nl":"Duitsland","hr":"NjemaÄka","fa":"آلمان","de":"Deutschland","es":"Alemania","fr":"Allemagne","ja":"ドイツ","it":"Germania"},"name":"Germany","alpha2Code":"DE"},{"translations":{"br":"Gana","pt":"Gana","nl":"Ghana","hr":"Gana","fa":"غنا","de":"Ghana","es":"Ghana","fr":"Ghana","ja":"ガーナ","it":"Ghana"},"name":"Ghana","alpha2Code":"GH"},{"translations":{"br":"Gibraltar","pt":"Gibraltar","nl":"Gibraltar","hr":"Gibraltar","fa":"جبل‌طارق","de":"Gibraltar","es":"Gibraltar","fr":"Gibraltar","ja":"ジブラルタル","it":"Gibilterra"},"name":"Gibraltar","alpha2Code":"GI"},{"translations":{"br":"Grécia","pt":"Grécia","nl":"Griekenland","hr":"GrÄka","fa":"یونان","de":"Griechenland","es":"Grecia","fr":"Grèce","ja":"ギリシャ","it":"Grecia"},"name":"Greece","alpha2Code":"GR"},{"translations":{"br":"Groelândia","pt":"Gronelândia","nl":"Groenland","hr":"Grenland","fa":"گرینلند","de":"Grönland","es":"Groenlandia","fr":"Groenland","ja":"グリーンランド","it":"Groenlandia"},"name":"Greenland","alpha2Code":"GL"},{"translations":{"br":"Granada","pt":"Granada","nl":"Grenada","hr":"Grenada","fa":"گرنادا","de":"Grenada","es":"Grenada","fr":"Grenade","ja":"グレナダ","it":"Grenada"},"name":"Grenada","alpha2Code":"GD"},{"translations":{"br":"Guadalupe","pt":"Guadalupe","nl":"Guadeloupe","hr":"Gvadalupa","fa":"جزیره گوادلوپ","de":"Guadeloupe","es":"Guadalupe","fr":"Guadeloupe","ja":"グアドループ","it":"Guadeloupa"},"name":"Guadeloupe","alpha2Code":"GP"},{"translations":{"br":"Guam","pt":"Guame","nl":"Guam","hr":"Guam","fa":"گوام","de":"Guam","es":"Guam","fr":"Guam","ja":"グアム","it":"Guam"},"name":"Guam","alpha2Code":"GU"},{"translations":{"br":"Guatemala","pt":"Guatemala","nl":"Guatemala","hr":"Gvatemala","fa":"گواتمالا","de":"Guatemala","es":"Guatemala","fr":"Guatemala","ja":"グアテマラ","it":"Guatemala"},"name":"Guatemala","alpha2Code":"GT"},{"translations":{"br":"Guernsey","pt":"Guernsey","nl":"Guernsey","hr":"Guernsey","fa":"گرنزی","de":"Guernsey","es":"Guernsey","fr":"Guernesey","ja":"ガーンジー","it":"Guernsey"},"name":"Guernsey","alpha2Code":"GG"},{"translations":{"br":"Guiné","pt":"Guiné","nl":"Guinee","hr":"Gvineja","fa":"گینه","de":"Guinea","es":"Guinea","fr":"Guinée","ja":"ギニア","it":"Guinea"},"name":"Guinea","alpha2Code":"GN"},{"translations":{"br":"Guiné-Bissau","pt":"Guiné-Bissau","nl":"Guinee-Bissau","hr":"Gvineja Bisau","fa":"گینه بیسائو","de":"Guinea-Bissau","es":"Guinea-Bisáu","fr":"Guinée-Bissau","ja":"ギニアビサウ","it":"Guinea-Bissau"},"name":"Guinea-Bissau","alpha2Code":"GW"},{"translations":{"br":"Guiana","pt":"Guiana","nl":"Guyana","hr":"Gvajana","fa":"گویان","de":"Guyana","es":"Guyana","fr":"Guyane","ja":"ガイアナ","it":"Guyana"},"name":"Guyana","alpha2Code":"GY"},{"translations":{"br":"Haiti","pt":"Haiti","nl":"Haïti","hr":"Haiti","fa":"هائیتی","de":"Haiti","es":"Haiti","fr":"Haïti","ja":"ãƒã‚¤ãƒ","it":"Haiti"},"name":"Haiti","alpha2Code":"HT"},{"translations":{"br":"Ilha Heard e Ilhas McDonald","pt":"Ilha Heard e Ilhas McDonald","nl":"Heard- en McDonaldeilanden","hr":"Otok Heard i otoÄje McDonald","fa":"جزیره هرد Ùˆ جزایر مک‌دونالد","de":"Heard und die McDonaldinseln","es":"Islas Heard y McDonald","fr":"ÃŽles Heard-et-MacDonald","ja":"ãƒãƒ¼ãƒ‰å³¶ã¨ãƒžã‚¯ãƒ‰ãƒŠãƒ«ãƒ‰è«¸å³¶","it":"Isole Heard e McDonald"},"name":"Heard Island and McDonald Islands","alpha2Code":"HM"},{"translations":{"br":"Vaticano","pt":"Vaticano","nl":"Heilige Stoel","hr":"Sveta Stolica","fa":"سریر مقدس","de":"Heiliger Stuhl","es":"Santa Sede","fr":"voir Saint","ja":"è–座","it":"Santa Sede"},"name":"Holy See","alpha2Code":"VA"},{"translations":{"br":"Honduras","pt":"Honduras","nl":"Honduras","hr":"Honduras","fa":"هندوراس","de":"Honduras","es":"Honduras","fr":"Honduras","ja":"ホンジュラス","it":"Honduras"},"name":"Honduras","alpha2Code":"HN"},{"translations":{"br":"Hong Kong","pt":"Hong Kong","nl":"Hongkong","hr":"Hong Kong","fa":"هنگ‌کنگ","de":"Hong Kong","es":"Hong Kong","fr":"Hong Kong","ja":"香港","it":"Hong Kong"},"name":"Hong Kong","alpha2Code":"HK"},{"translations":{"br":"Hungria","pt":"Hungria","nl":"Hongarije","hr":"MaÄ‘arska","fa":"مجارستان","de":"Ungarn","es":"Hungría","fr":"Hongrie","ja":"ãƒãƒ³ã‚¬ãƒªãƒ¼","it":"Ungheria"},"name":"Hungary","alpha2Code":"HU"},{"translations":{"br":"Islândia","pt":"Islândia","nl":"IJsland","hr":"Island","fa":"ایسلند","de":"Island","es":"Islandia","fr":"Islande","ja":"アイスランド","it":"Islanda"},"name":"Iceland","alpha2Code":"IS"},{"translations":{"br":"Ãndia","pt":"Ãndia","nl":"India","hr":"Indija","fa":"هند","de":"Indien","es":"India","fr":"Inde","ja":"インド","it":"India"},"name":"India","alpha2Code":"IN"},{"translations":{"br":"Indonésia","pt":"Indonésia","nl":"Indonesië","hr":"Indonezija","fa":"اندونزی","de":"Indonesien","es":"Indonesia","fr":"Indonésie","ja":"インドãƒã‚·ã‚¢","it":"Indonesia"},"name":"Indonesia","alpha2Code":"ID"},{"translations":{"br":"Costa do Marfim","pt":"Costa do Marfim","nl":"Ivoorkust","hr":"Obala Bjelokosti","fa":"ساحل عاج","de":"Elfenbeinküste","es":"Costa de Marfil","fr":"Côte d\'Ivoire","ja":"コートジボワール","it":"Costa D\'Avorio"},"name":"Côte d\'Ivoire","alpha2Code":"CI"},{"translations":{"br":"Irã","pt":"Irão","nl":"Iran","hr":"Iran","fa":"ایران","de":"Iran","es":"Iran","fr":"Iran","ja":"イラン・イスラム共和国"},"name":"Iran (Islamic Republic of)","alpha2Code":"IR"},{"translations":{"br":"Iraque","pt":"Iraque","nl":"Irak","hr":"Irak","fa":"عراق","de":"Irak","es":"Irak","fr":"Irak","ja":"イラク","it":"Iraq"},"name":"Iraq","alpha2Code":"IQ"},{"translations":{"br":"Irlanda","pt":"Irlanda","nl":"Ierland","hr":"Irska","fa":"ایرلند","de":"Irland","es":"Irlanda","fr":"Irlande","ja":"アイルランド","it":"Irlanda"},"name":"Ireland","alpha2Code":"IE"},{"translations":{"br":"Ilha de Man","pt":"Ilha de Man","nl":"Isle of Man","hr":"Otok Man","fa":"جزیره من","de":"Insel Man","es":"Isla de Man","fr":"ÃŽle de Man","ja":"マン島","it":"Isola di Man"},"name":"Isle of Man","alpha2Code":"IM"},{"translations":{"br":"Israel","pt":"Israel","nl":"Israël","hr":"Izrael","fa":"اسرائیل","de":"Israel","es":"Israel","fr":"Israël","ja":"イスラエル","it":"Israele"},"name":"Israel","alpha2Code":"IL"},{"translations":{"br":"Itália","pt":"Itália","nl":"Italië","hr":"Italija","fa":"ایتالیا","de":"Italien","es":"Italia","fr":"Italie","ja":"イタリア","it":"Italia"},"name":"Italy","alpha2Code":"IT"},{"translations":{"br":"Jamaica","pt":"Jamaica","nl":"Jamaica","hr":"Jamajka","fa":"جامائیکا","de":"Jamaika","es":"Jamaica","fr":"Jamaïque","ja":"ジャマイカ","it":"Giamaica"},"name":"Jamaica","alpha2Code":"JM"},{"translations":{"br":"Japão","pt":"Japão","nl":"Japan","hr":"Japan","fa":"ژاپن","de":"Japan","es":"Japón","fr":"Japon","ja":"日本","it":"Giappone"},"name":"Japan","alpha2Code":"JP"},{"translations":{"br":"Jersey","pt":"Jersey","nl":"Jersey","hr":"Jersey","fa":"جرزی","de":"Jersey","es":"Jersey","fr":"Jersey","ja":"ジャージー","it":"Isola di Jersey"},"name":"Jersey","alpha2Code":"JE"},{"translations":{"br":"Jordânia","pt":"Jordânia","nl":"Jordanië","hr":"Jordan","fa":"اردن","de":"Jordanien","es":"Jordania","fr":"Jordanie","ja":"ヨルダン","it":"Giordania"},"name":"Jordan","alpha2Code":"JO"},{"translations":{"br":"Cazaquistão","pt":"Cazaquistão","nl":"Kazachstan","hr":"Kazahstan","fa":"قزاقستان","de":"Kasachstan","es":"Kazajistán","fr":"Kazakhstan","ja":"カザフスタン","it":"Kazakistan"},"name":"Kazakhstan","alpha2Code":"KZ"},{"translations":{"br":"Quênia","pt":"Quénia","nl":"Kenia","hr":"Kenija","fa":"کنیا","de":"Kenia","es":"Kenia","fr":"Kenya","ja":"ケニア","it":"Kenya"},"name":"Kenya","alpha2Code":"KE"},{"translations":{"br":"Kiribati","pt":"Quiribáti","nl":"Kiribati","hr":"Kiribati","fa":"کیریباتی","de":"Kiribati","es":"Kiribati","fr":"Kiribati","ja":"キリãƒã‚¹","it":"Kiribati"},"name":"Kiribati","alpha2Code":"KI"},{"translations":{"br":"Kuwait","pt":"Kuwait","nl":"Koeweit","hr":"Kuvajt","fa":"کویت","de":"Kuwait","es":"Kuwait","fr":"Koweït","ja":"クウェート","it":"Kuwait"},"name":"Kuwait","alpha2Code":"KW"},{"translations":{"br":"Quirguistão","pt":"Quirguizistão","nl":"Kirgizië","hr":"Kirgistan","fa":"قرقیزستان","de":"Kirgisistan","es":"Kirguizistán","fr":"Kirghizistan","ja":"キルギス","it":"Kirghizistan"},"name":"Kyrgyzstan","alpha2Code":"KG"},{"translations":{"br":"Laos","pt":"Laos","nl":"Laos","hr":"Laos","fa":"لائوس","de":"Laos","es":"Laos","fr":"Laos","ja":"ラオス人民民主共和国","it":"Laos"},"name":"Lao People\'s Democratic Republic","alpha2Code":"LA"},{"translations":{"br":"Letônia","pt":"Letónia","nl":"Letland","hr":"Latvija","fa":"لتونی","de":"Lettland","es":"Letonia","fr":"Lettonie","ja":"ラトビア","it":"Lettonia"},"name":"Latvia","alpha2Code":"LV"},{"translations":{"br":"Líbano","pt":"Líbano","nl":"Libanon","hr":"Libanon","fa":"لبنان","de":"Libanon","es":"Líbano","fr":"Liban","ja":"レãƒãƒŽãƒ³","it":"Libano"},"name":"Lebanon","alpha2Code":"LB"},{"translations":{"br":"Lesoto","pt":"Lesoto","nl":"Lesotho","hr":"Lesoto","fa":"لسوتو","de":"Lesotho","es":"Lesotho","fr":"Lesotho","ja":"レソト","it":"Lesotho"},"name":"Lesotho","alpha2Code":"LS"},{"translations":{"br":"Libéria","pt":"Libéria","nl":"Liberia","hr":"Liberija","fa":"لیبریا","de":"Liberia","es":"Liberia","fr":"Liberia","ja":"リベリア","it":"Liberia"},"name":"Liberia","alpha2Code":"LR"},{"translations":{"br":"Líbia","pt":"Líbia","nl":"Libië","hr":"Libija","fa":"لیبی","de":"Libyen","es":"Libia","fr":"Libye","ja":"リビア","it":"Libia"},"name":"Libya","alpha2Code":"LY"},{"translations":{"br":"Liechtenstein","pt":"Listenstaine","nl":"Liechtenstein","hr":"LihtenÅ¡tajn","fa":"لیختن‌اشتاین","de":"Liechtenstein","es":"Liechtenstein","fr":"Liechtenstein","ja":"リヒテンシュタイン","it":"Liechtenstein"},"name":"Liechtenstein","alpha2Code":"LI"},{"translations":{"br":"Lituânia","pt":"Lituânia","nl":"Litouwen","hr":"Litva","fa":"لیتوانی","de":"Litauen","es":"Lituania","fr":"Lituanie","ja":"リトアニア","it":"Lituania"},"name":"Lithuania","alpha2Code":"LT"},{"translations":{"br":"Luxemburgo","pt":"Luxemburgo","nl":"Luxemburg","hr":"Luksemburg","fa":"لوکزامبورگ","de":"Luxemburg","es":"Luxemburgo","fr":"Luxembourg","ja":"ルクセンブルク","it":"Lussemburgo"},"name":"Luxembourg","alpha2Code":"LU"},{"translations":{"br":"Macau","pt":"Macau","nl":"Macao","hr":"Makao","fa":"مکائو","de":"Macao","es":"Macao","fr":"Macao","ja":"マカオ","it":"Macao"},"name":"Macao","alpha2Code":"MO"},{"translations":{"br":"Macedônia","pt":"Macedónia","nl":"Macedonië","hr":"Makedonija","fa":"","de":"Mazedonien","es":"Macedonia","fr":"Macédoine","ja":"マケドニア旧ユーゴスラビア共和国","it":"Macedonia"},"name":"Macedonia (the former Yugoslav Republic of)","alpha2Code":"MK"},{"translations":{"br":"Madagascar","pt":"Madagáscar","nl":"Madagaskar","hr":"Madagaskar","fa":"ماداگاسکار","de":"Madagaskar","es":"Madagascar","fr":"Madagascar","ja":"マダガスカル","it":"Madagascar"},"name":"Madagascar","alpha2Code":"MG"},{"translations":{"br":"Malawi","pt":"Malávi","nl":"Malawi","hr":"Malavi","fa":"مالاوی","de":"Malawi","es":"Malawi","fr":"Malawi","ja":"マラウイ","it":"Malawi"},"name":"Malawi","alpha2Code":"MW"},{"translations":{"br":"Malásia","pt":"Malásia","nl":"Maleisië","hr":"Malezija","fa":"مالزی","de":"Malaysia","es":"Malasia","fr":"Malaisie","ja":"マレーシア","it":"Malesia"},"name":"Malaysia","alpha2Code":"MY"},{"translations":{"br":"Maldivas","pt":"Maldivas","nl":"Maldiven","hr":"Maldivi","fa":"مالدیو","de":"Malediven","es":"Maldivas","fr":"Maldives","ja":"モルディブ","it":"Maldive"},"name":"Maldives","alpha2Code":"MV"},{"translations":{"br":"Mali","pt":"Mali","nl":"Mali","hr":"Mali","fa":"مالی","de":"Mali","es":"Mali","fr":"Mali","ja":"マリ","it":"Mali"},"name":"Mali","alpha2Code":"ML"},{"translations":{"br":"Malta","pt":"Malta","nl":"Malta","hr":"Malta","fa":"مالت","de":"Malta","es":"Malta","fr":"Malte","ja":"マルタ","it":"Malta"},"name":"Malta","alpha2Code":"MT"},{"translations":{"br":"Ilhas Marshall","pt":"Ilhas Marshall","nl":"Marshalleilanden","hr":"MarÅ¡alovi Otoci","fa":"جزایر مارشال","de":"Marshallinseln","es":"Islas Marshall","fr":"ÃŽles Marshall","ja":"マーシャル諸島","it":"Isole Marshall"},"name":"Marshall Islands","alpha2Code":"MH"},{"translations":{"br":"Martinica","pt":"Martinica","nl":"Martinique","hr":"Martinique","fa":"مونتسرات","de":"Martinique","es":"Martinica","fr":"Martinique","ja":"マルティニーク","it":"Martinica"},"name":"Martinique","alpha2Code":"MQ"},{"translations":{"br":"Mauritânia","pt":"Mauritânia","nl":"Mauritanië","hr":"Mauritanija","fa":"موریتانی","de":"Mauretanien","es":"Mauritania","fr":"Mauritanie","ja":"モーリタニア","it":"Mauritania"},"name":"Mauritania","alpha2Code":"MR"},{"translations":{"br":"Maurício","pt":"Maurícia","nl":"Mauritius","hr":"Mauricijus","fa":"موریس","de":"Mauritius","es":"Mauricio","fr":"ÃŽle Maurice","ja":"モーリシャス","it":"Mauritius"},"name":"Mauritius","alpha2Code":"MU"},{"translations":{"br":"Mayotte","pt":"Mayotte","nl":"Mayotte","hr":"Mayotte","fa":"مایوت","de":"Mayotte","es":"Mayotte","fr":"Mayotte","ja":"マヨット","it":"Mayotte"},"name":"Mayotte","alpha2Code":"YT"},{"translations":{"br":"México","pt":"México","nl":"Mexico","hr":"Meksiko","fa":"مکزیک","de":"Mexiko","es":"México","fr":"Mexique","ja":"メキシコ","it":"Messico"},"name":"Mexico","alpha2Code":"MX"},{"translations":{"br":"Micronésia","pt":"Micronésia","nl":"Micronesië","hr":"Mikronezija","fa":"ایالات Ùدرال میکرونزی","de":"Mikronesien","es":"Micronesia","fr":"Micronésie","ja":"ミクロãƒã‚·ã‚¢é€£é‚¦","it":"Micronesia"},"name":"Micronesia (Federated States of)","alpha2Code":"FM"},{"translations":{"br":"Moldávia","pt":"Moldávia","nl":"Moldavië","hr":"Moldova","fa":"مولداوی","de":"Moldawie","es":"Moldavia","fr":"Moldavie","ja":"モルドãƒå…±å’Œå›½","it":"Moldavia"},"name":"Moldova (Republic of)","alpha2Code":"MD"},{"translations":{"br":"Mônaco","pt":"Mónaco","nl":"Monaco","hr":"Monako","fa":"موناکو","de":"Monaco","es":"Mónaco","fr":"Monaco","ja":"モナコ","it":"Principato di Monaco"},"name":"Monaco","alpha2Code":"MC"},{"translations":{"br":"Mongólia","pt":"Mongólia","nl":"Mongolië","hr":"Mongolija","fa":"مغولستان","de":"Mongolei","es":"Mongolia","fr":"Mongolie","ja":"モンゴル","it":"Mongolia"},"name":"Mongolia","alpha2Code":"MN"},{"translations":{"br":"Montenegro","pt":"Montenegro","nl":"Montenegro","hr":"Crna Gora","fa":"مونته‌نگرو","de":"Montenegro","es":"Montenegro","fr":"Monténégro","ja":"モンテãƒã‚°ãƒ­","it":"Montenegro"},"name":"Montenegro","alpha2Code":"ME"},{"translations":{"br":"Montserrat","pt":"Monserrate","nl":"Montserrat","hr":"Montserrat","fa":"مایوت","de":"Montserrat","es":"Montserrat","fr":"Montserrat","ja":"モントセラト","it":"Montserrat"},"name":"Montserrat","alpha2Code":"MS"},{"translations":{"br":"Marrocos","pt":"Marrocos","nl":"Marokko","hr":"Maroko","fa":"مراکش","de":"Marokko","es":"Marruecos","fr":"Maroc","ja":"モロッコ","it":"Marocco"},"name":"Morocco","alpha2Code":"MA"},{"translations":{"br":"Moçambique","pt":"Moçambique","nl":"Mozambique","hr":"Mozambik","fa":"موزامبیک","de":"Mosambik","es":"Mozambique","fr":"Mozambique","ja":"モザンビーク","it":"Mozambico"},"name":"Mozambique","alpha2Code":"MZ"},{"translations":{"br":"Myanmar","pt":"Myanmar","nl":"Myanmar","hr":"Mijanmar","fa":"میانمار","de":"Myanmar","es":"Myanmar","fr":"Myanmar","ja":"ミャンマー","it":"Birmania"},"name":"Myanmar","alpha2Code":"MM"},{"translations":{"br":"Namíbia","pt":"Namíbia","nl":"Namibië","hr":"Namibija","fa":"نامیبیا","de":"Namibia","es":"Namibia","fr":"Namibie","ja":"ナミビア","it":"Namibia"},"name":"Namibia","alpha2Code":"NA"},{"translations":{"br":"Nauru","pt":"Nauru","nl":"Nauru","hr":"Nauru","fa":"نائورو","de":"Nauru","es":"Nauru","fr":"Nauru","ja":"ナウル","it":"Nauru"},"name":"Nauru","alpha2Code":"NR"},{"translations":{"br":"Nepal","pt":"Nepal","nl":"Nepal","hr":"Nepal","fa":"نپال","de":"Népal","es":"Nepal","fr":"Népal","ja":"ãƒãƒ‘ール","it":"Nepal"},"name":"Nepal","alpha2Code":"NP"},{"translations":{"br":"Holanda","pt":"Países Baixos","nl":"Nederland","hr":"Nizozemska","fa":"پادشاهی هلند","de":"Niederlande","es":"Países Bajos","fr":"Pays-Bas","ja":"オランダ","it":"Paesi Bassi"},"name":"Netherlands","alpha2Code":"NL"},{"translations":{"br":"Nova Caledônia","pt":"Nova Caledónia","nl":"Nieuw-Caledonië","hr":"Nova Kaledonija","fa":"کالدونیای جدید","de":"Neukaledonien","es":"Nueva Caledonia","fr":"Nouvelle-Calédonie","ja":"ニューカレドニア","it":"Nuova Caledonia"},"name":"New Caledonia","alpha2Code":"NC"},{"translations":{"br":"Nova Zelândia","pt":"Nova Zelândia","nl":"Nieuw-Zeeland","hr":"Novi Zeland","fa":"نیوزیلند","de":"Neuseeland","es":"Nueva Zelanda","fr":"Nouvelle-Zélande","ja":"ニュージーランド","it":"Nuova Zelanda"},"name":"New Zealand","alpha2Code":"NZ"},{"translations":{"br":"Nicarágua","pt":"Nicarágua","nl":"Nicaragua","hr":"Nikaragva","fa":"نیکاراگوئه","de":"Nicaragua","es":"Nicaragua","fr":"Nicaragua","ja":"ニカラグア","it":"Nicaragua"},"name":"Nicaragua","alpha2Code":"NI"},{"translations":{"br":"Níger","pt":"Níger","nl":"Niger","hr":"Niger","fa":"نیجر","de":"Niger","es":"Níger","fr":"Niger","ja":"ニジェール","it":"Niger"},"name":"Niger","alpha2Code":"NE"},{"translations":{"br":"Nigéria","pt":"Nigéria","nl":"Nigeria","hr":"Nigerija","fa":"نیجریه","de":"Nigeria","es":"Nigeria","fr":"Nigéria","ja":"ナイジェリア","it":"Nigeria"},"name":"Nigeria","alpha2Code":"NG"},{"translations":{"br":"Niue","pt":"Niue","nl":"Niue","hr":"Niue","fa":"نیووی","de":"Niue","es":"Niue","fr":"Niue","ja":"ニウエ","it":"Niue"},"name":"Niue","alpha2Code":"NU"},{"translations":{"br":"Ilha Norfolk","pt":"Ilha Norfolk","nl":"Norfolkeiland","hr":"Otok Norfolk","fa":"جزیره نورÙÚ©","de":"Norfolkinsel","es":"Isla de Norfolk","fr":"ÃŽle de Norfolk","ja":"ノーフォーク島","it":"Isola Norfolk"},"name":"Norfolk Island","alpha2Code":"NF"},{"translations":{"br":"Coreia do Norte","pt":"Coreia do Norte","nl":"Noord-Korea","hr":"Sjeverna Koreja","fa":"کره جنوبی","de":"Nordkorea","es":"Corea del Norte","fr":"Corée du Nord","ja":"æœé®®æ°‘主主義人民共和国","it":"Corea del Nord"},"name":"Korea (Democratic People\'s Republic of)","alpha2Code":"KP"},{"translations":{"br":"Ilhas Marianas","pt":"Ilhas Marianas","nl":"Noordelijke Marianeneilanden","hr":"Sjevernomarijanski otoci","fa":"جزایر ماریانای شمالی","de":"Nördliche Marianen","es":"Islas Marianas del Norte","fr":"ÃŽles Mariannes du Nord","ja":"北マリアナ諸島","it":"Isole Marianne Settentrionali"},"name":"Northern Mariana Islands","alpha2Code":"MP"},{"translations":{"br":"Noruega","pt":"Noruega","nl":"Noorwegen","hr":"NorveÅ¡ka","fa":"نروژ","de":"Norwegen","es":"Noruega","fr":"Norvège","ja":"ノルウェー","it":"Norvegia"},"name":"Norway","alpha2Code":"NO"},{"translations":{"br":"Omã","pt":"Omã","nl":"Oman","hr":"Oman","fa":"عمان","de":"Oman","es":"Omán","fr":"Oman","ja":"オマーン","it":"oman"},"name":"Oman","alpha2Code":"OM"},{"translations":{"br":"Paquistão","pt":"Paquistão","nl":"Pakistan","hr":"Pakistan","fa":"پاکستان","de":"Pakistan","es":"Pakistán","fr":"Pakistan","ja":"パキスタン","it":"Pakistan"},"name":"Pakistan","alpha2Code":"PK"},{"translations":{"br":"Palau","pt":"Palau","nl":"Palau","hr":"Palau","fa":"پالائو","de":"Palau","es":"Palau","fr":"Palaos","ja":"パラオ","it":"Palau"},"name":"Palau","alpha2Code":"PW"},{"translations":{"br":"Palestina","pt":"Palestina","nl":"Palestijnse gebieden","hr":"Palestina","fa":"Ùلسطین","de":"Palästina","es":"Palestina","fr":"Palestine","ja":"パレスãƒãƒŠ","it":"Palestina"},"name":"Palestine, State of","alpha2Code":"PS"},{"translations":{"br":"Panamá","pt":"Panamá","nl":"Panama","hr":"Panama","fa":"پاناما","de":"Panama","es":"Panamá","fr":"Panama","ja":"パナマ","it":"Panama"},"name":"Panama","alpha2Code":"PA"},{"translations":{"br":"Papua Nova Guiné","pt":"Papua Nova Guiné","nl":"Papoea-Nieuw-Guinea","hr":"Papua Nova Gvineja","fa":"پاپوآ گینه نو","de":"Papua-Neuguinea","es":"Papúa Nueva Guinea","fr":"Papouasie-Nouvelle-Guinée","ja":"パプアニューギニア","it":"Papua Nuova Guinea"},"name":"Papua New Guinea","alpha2Code":"PG"},{"translations":{"br":"Paraguai","pt":"Paraguai","nl":"Paraguay","hr":"Paragvaj","fa":"پاراگوئه","de":"Paraguay","es":"Paraguay","fr":"Paraguay","ja":"パラグアイ","it":"Paraguay"},"name":"Paraguay","alpha2Code":"PY"},{"translations":{"br":"Peru","pt":"Peru","nl":"Peru","hr":"Peru","fa":"پرو","de":"Peru","es":"Perú","fr":"Pérou","ja":"ペルー","it":"Perù"},"name":"Peru","alpha2Code":"PE"},{"translations":{"br":"Filipinas","pt":"Filipinas","nl":"Filipijnen","hr":"Filipini","fa":"جزایر الندÙیلیپین","de":"Philippinen","es":"Filipinas","fr":"Philippines","ja":"フィリピン","it":"Filippine"},"name":"Philippines","alpha2Code":"PH"},{"translations":{"br":"Ilhas Pitcairn","pt":"Ilhas Picárnia","nl":"Pitcairneilanden","hr":"Pitcairnovo otoÄje","fa":"پیتکرن","de":"Pitcairn","es":"Islas Pitcairn","fr":"ÃŽles Pitcairn","ja":"ピトケアン","it":"Isole Pitcairn"},"name":"Pitcairn","alpha2Code":"PN"},{"translations":{"br":"Polônia","pt":"Polónia","nl":"Polen","hr":"Poljska","fa":"لهستان","de":"Polen","es":"Polonia","fr":"Pologne","ja":"ãƒãƒ¼ãƒ©ãƒ³ãƒ‰","it":"Polonia"},"name":"Poland","alpha2Code":"PL"},{"translations":{"br":"Portugal","pt":"Portugal","nl":"Portugal","hr":"Portugal","fa":"پرتغال","de":"Portugal","es":"Portugal","fr":"Portugal","ja":"ãƒãƒ«ãƒˆã‚¬ãƒ«","it":"Portogallo"},"name":"Portugal","alpha2Code":"PT"},{"translations":{"br":"Porto Rico","pt":"Porto Rico","nl":"Puerto Rico","hr":"Portoriko","fa":"پورتو ریکو","de":"Puerto Rico","es":"Puerto Rico","fr":"Porto Rico","ja":"プエルトリコ","it":"Porto Rico"},"name":"Puerto Rico","alpha2Code":"PR"},{"translations":{"br":"Catar","pt":"Catar","nl":"Qatar","hr":"Katar","fa":"قطر","de":"Katar","es":"Catar","fr":"Qatar","ja":"カタール","it":"Qatar"},"name":"Qatar","alpha2Code":"QA"},{"translations":{"br":"Kosovo","pt":"Kosovo","hr":"Kosovo","fa":"کوزوو","es":"Kosovo"},"name":"Republic of Kosovo","alpha2Code":"XK"},{"translations":{"br":"Reunião","pt":"Reunião","nl":"Réunion","hr":"Réunion","fa":"رئونیون","de":"Réunion","es":"Reunión","fr":"Réunion","ja":"レユニオン","it":"Riunione"},"name":"Réunion","alpha2Code":"RE"},{"translations":{"br":"Romênia","pt":"Roménia","nl":"Roemenië","hr":"Rumunjska","fa":"رومانی","de":"Rumänien","es":"Rumania","fr":"Roumanie","ja":"ルーマニア","it":"Romania"},"name":"Romania","alpha2Code":"RO"},{"translations":{"br":"Rússia","pt":"Rússia","nl":"Rusland","hr":"Rusija","fa":"روسیه","de":"Russland","es":"Rusia","fr":"Russie","ja":"ロシア連邦","it":"Russia"},"name":"Russian Federation","alpha2Code":"RU"},{"translations":{"br":"Ruanda","pt":"Ruanda","nl":"Rwanda","hr":"Ruanda","fa":"رواندا","de":"Ruanda","es":"Ruanda","fr":"Rwanda","ja":"ルワンダ","it":"Ruanda"},"name":"Rwanda","alpha2Code":"RW"},{"translations":{"br":"São Bartolomeu","pt":"São Bartolomeu","nl":"Saint Barthélemy","hr":"Saint Barthélemy","fa":"سن-بارتلمی","de":"Saint-Barthélemy","es":"San Bartolomé","fr":"Saint-Barthélemy","ja":"サン・ãƒãƒ«ãƒ†ãƒ«ãƒŸãƒ¼","it":"Antille Francesi"},"name":"Saint Barthélemy","alpha2Code":"BL"},{"translations":{"br":"Santa Helena","pt":"Santa Helena","nl":"Sint-Helena","hr":"Sveta Helena","fa":"سنت هلنا، اسنشن Ùˆ تریستان دا کونا","de":"Sankt Helena","es":"Santa Helena","fr":"Sainte-Hélène","ja":"セントヘレナ・アセンションãŠã‚ˆã³ãƒˆãƒªã‚¹ã‚¿ãƒ³ãƒ€ã‚¯ãƒ¼ãƒ‹ãƒ£","it":"Sant\'Elena"},"name":"Saint Helena, Ascension and Tristan da Cunha","alpha2Code":"SH"},{"translations":{"br":"São Cristóvão e Neves","pt":"São Cristóvão e Neves","nl":"Saint Kitts en Nevis","hr":"Sveti Kristof i Nevis","fa":"سنت کیتس Ùˆ نویس","de":"St. Kitts und Nevis","es":"San Cristóbal y Nieves","fr":"Saint-Christophe-et-Niévès","ja":"セントクリストファー・ãƒã‚¤ãƒ“ス","it":"Saint Kitts e Nevis"},"name":"Saint Kitts and Nevis","alpha2Code":"KN"},{"translations":{"br":"Santa Lúcia","pt":"Santa Lúcia","nl":"Saint Lucia","hr":"Sveta Lucija","fa":"سنت لوسیا","de":"Saint Lucia","es":"Santa Lucía","fr":"Saint-Lucie","ja":"セントルシア","it":"Santa Lucia"},"name":"Saint Lucia","alpha2Code":"LC"},{"translations":{"br":"Saint Martin","pt":"Ilha São Martinho","nl":"Saint-Martin","hr":"Sveti Martin","fa":"سینت مارتن","de":"Saint Martin","es":"Saint Martin","fr":"Saint-Martin","ja":"サン・マルタン(フランス領)","it":"Saint Martin"},"name":"Saint Martin (French part)","alpha2Code":"MF"},{"translations":{"br":"Saint-Pierre e Miquelon","pt":"São Pedro e Miquelon","nl":"Saint Pierre en Miquelon","hr":"Sveti Petar i Mikelon","fa":"سن پیر Ùˆ میکلن","de":"Saint-Pierre und Miquelon","es":"San Pedro y Miquelón","fr":"Saint-Pierre-et-Miquelon","ja":"サンピエール島・ミクロン島","it":"Saint-Pierre e Miquelon"},"name":"Saint Pierre and Miquelon","alpha2Code":"PM"},{"translations":{"br":"São Vicente e Granadinas","pt":"São Vicente e Granadinas","nl":"Saint Vincent en de Grenadines","hr":"Sveti Vincent i Grenadini","fa":"سنت وینسنت Ùˆ گرنادین‌ها","de":"Saint Vincent und die Grenadinen","es":"San Vicente y Granadinas","fr":"Saint-Vincent-et-les-Grenadines","ja":"セントビンセントãŠã‚ˆã³ã‚°ãƒ¬ãƒŠãƒ‡ã‚£ãƒ¼ãƒ³è«¸å³¶","it":"Saint Vincent e Grenadine"},"name":"Saint Vincent and the Grenadines","alpha2Code":"VC"},{"translations":{"br":"Samoa","pt":"Samoa","nl":"Samoa","hr":"Samoa","fa":"ساموآ","de":"Samoa","es":"Samoa","fr":"Samoa","ja":"サモア","it":"Samoa"},"name":"Samoa","alpha2Code":"WS"},{"translations":{"br":"San Marino","pt":"São Marinho","nl":"San Marino","hr":"San Marino","fa":"سان مارینو","de":"San Marino","es":"San Marino","fr":"Saint-Marin","ja":"サンマリノ","it":"San Marino"},"name":"San Marino","alpha2Code":"SM"},{"translations":{"br":"São Tomé e Príncipe","pt":"São Tomé e Príncipe","nl":"Sao Tomé en Principe","hr":"Sveti Toma i Princip","fa":"کواترو دو Ùرویرو","de":"São Tomé und Príncipe","es":"Santo Tomé y Príncipe","fr":"Sao Tomé-et-Principe","ja":"サントメ・プリンシペ","it":"São Tomé e Príncipe"},"name":"Sao Tome and Principe","alpha2Code":"ST"},{"translations":{"br":"Arábia Saudita","pt":"Arábia Saudita","nl":"Saoedi-Arabië","hr":"Saudijska Arabija","fa":"عربستان سعودی","de":"Saudi-Arabien","es":"Arabia Saudí","fr":"Arabie Saoudite","ja":"サウジアラビア","it":"Arabia Saudita"},"name":"Saudi Arabia","alpha2Code":"SA"},{"translations":{"br":"Senegal","pt":"Senegal","nl":"Senegal","hr":"Senegal","fa":"سنگال","de":"Senegal","es":"Senegal","fr":"Sénégal","ja":"ã‚»ãƒã‚¬ãƒ«","it":"Senegal"},"name":"Senegal","alpha2Code":"SN"},{"translations":{"br":"Sérvia","pt":"Sérvia","nl":"Servië","hr":"Srbija","fa":"صربستان","de":"Serbien","es":"Serbia","fr":"Serbie","ja":"セルビア","it":"Serbia"},"name":"Serbia","alpha2Code":"RS"},{"translations":{"br":"Seicheles","pt":"Seicheles","nl":"Seychellen","hr":"SejÅ¡eli","fa":"سیشل","de":"Seychellen","es":"Seychelles","fr":"Seychelles","ja":"セーシェル","it":"Seychelles"},"name":"Seychelles","alpha2Code":"SC"},{"translations":{"br":"Serra Leoa","pt":"Serra Leoa","nl":"Sierra Leone","hr":"Sijera Leone","fa":"سیرالئون","de":"Sierra Leone","es":"Sierra Leone","fr":"Sierra Leone","ja":"シエラレオãƒ","it":"Sierra Leone"},"name":"Sierra Leone","alpha2Code":"SL"},{"translations":{"br":"Singapura","pt":"Singapura","nl":"Singapore","hr":"Singapur","fa":"سنگاپور","de":"Singapur","es":"Singapur","fr":"Singapour","ja":"シンガãƒãƒ¼ãƒ«","it":"Singapore"},"name":"Singapore","alpha2Code":"SG"},{"translations":{"br":"Sint Maarten","pt":"São Martinho","nl":"Sint Maarten","fa":"سینت مارتن","de":"Sint Maarten (niederl. Teil)","fr":"Saint Martin (partie néerlandaise)","it":"Saint Martin (parte olandese)"},"name":"Sint Maarten (Dutch part)","alpha2Code":"SX"},{"translations":{"br":"Eslováquia","pt":"Eslováquia","nl":"Slowakije","hr":"SlovaÄka","fa":"اسلواکی","de":"Slowakei","es":"República Eslovaca","fr":"Slovaquie","ja":"スロãƒã‚­ã‚¢","it":"Slovacchia"},"name":"Slovakia","alpha2Code":"SK"},{"translations":{"br":"Eslovênia","pt":"Eslovénia","nl":"Slovenië","hr":"Slovenija","fa":"اسلوونی","de":"Slowenien","es":"Eslovenia","fr":"Slovénie","ja":"スロベニア","it":"Slovenia"},"name":"Slovenia","alpha2Code":"SI"},{"translations":{"br":"Ilhas Salomão","pt":"Ilhas Salomão","nl":"Salomonseilanden","hr":"Solomonski Otoci","fa":"جزایر سلیمان","de":"Salomonen","es":"Islas Salomón","fr":"ÃŽles Salomon","ja":"ソロモン諸島","it":"Isole Salomone"},"name":"Solomon Islands","alpha2Code":"SB"},{"translations":{"br":"Somália","pt":"Somália","nl":"Somalië","hr":"Somalija","fa":"سومالی","de":"Somalia","es":"Somalia","fr":"Somalie","ja":"ソマリア","it":"Somalia"},"name":"Somalia","alpha2Code":"SO"},{"translations":{"br":"República Sul-Africana","pt":"República Sul-Africana","nl":"Zuid-Afrika","hr":"JužnoafriÄka Republika","fa":"Ø¢Ùریقای جنوبی","de":"Republik Südafrika","es":"República de Sudáfrica","fr":"Afrique du Sud","ja":"å—アフリカ","it":"Sud Africa"},"name":"South Africa","alpha2Code":"ZA"},{"translations":{"br":"Ilhas Geórgias do Sul e Sandwich do Sul","pt":"Ilhas Geórgia do Sul e Sanduíche do Sul","nl":"Zuid-Georgia en Zuidelijke Sandwicheilanden","hr":"Južna Georgija i otoÄje Južni Sandwich","fa":"جزایر جورجیای جنوبی Ùˆ ساندویچ جنوبی","de":"Südgeorgien und die Südlichen Sandwichinseln","es":"Islas Georgias del Sur y Sandwich del Sur","fr":"Géorgie du Sud-et-les ÃŽles Sandwich du Sud","ja":"サウスジョージア・サウスサンドウィッãƒè«¸å³¶","it":"Georgia del Sud e Isole Sandwich Meridionali"},"name":"South Georgia and the South Sandwich Islands","alpha2Code":"GS"},{"translations":{"br":"Coreia do Sul","pt":"Coreia do Sul","nl":"Zuid-Korea","hr":"Južna Koreja","fa":"کره شمالی","de":"Südkorea","es":"Corea del Sur","fr":"Corée du Sud","ja":"大韓民国","it":"Corea del Sud"},"name":"Korea (Republic of)","alpha2Code":"KR"},{"translations":{"br":"Sudão do Sul","pt":"Sudão do Sul","nl":"Zuid-Soedan","hr":"Južni Sudan","fa":"سودان جنوبی","de":"Südsudan","es":"Sudán del Sur","fr":"Soudan du Sud","ja":"å—スーダン","it":"Sudan del sud"},"name":"South Sudan","alpha2Code":"SS"},{"translations":{"br":"Espanha","pt":"Espanha","nl":"Spanje","hr":"Å panjolska","fa":"اسپانیا","de":"Spanien","es":"España","fr":"Espagne","ja":"スペイン","it":"Spagna"},"name":"Spain","alpha2Code":"ES"},{"translations":{"br":"Sri Lanka","pt":"Sri Lanka","nl":"Sri Lanka","hr":"Å ri Lanka","fa":"سری‌لانکا","de":"Sri Lanka","es":"Sri Lanka","fr":"Sri Lanka","ja":"スリランカ","it":"Sri Lanka"},"name":"Sri Lanka","alpha2Code":"LK"},{"translations":{"br":"Sudão","pt":"Sudão","nl":"Soedan","hr":"Sudan","fa":"سودان","de":"Sudan","es":"Sudán","fr":"Soudan","ja":"スーダン","it":"Sudan"},"name":"Sudan","alpha2Code":"SD"},{"translations":{"br":"Suriname","pt":"Suriname","nl":"Suriname","hr":"Surinam","fa":"سورینام","de":"Suriname","es":"Surinam","fr":"Surinam","ja":"スリナム","it":"Suriname"},"name":"Suriname","alpha2Code":"SR"},{"translations":{"br":"Svalbard","pt":"Svalbard","nl":"Svalbard en Jan Mayen","hr":"Svalbard i Jan Mayen","fa":"سوالبارد Ùˆ یان ماین","de":"Svalbard und Jan Mayen","es":"Islas Svalbard y Jan Mayen","fr":"Svalbard et Jan Mayen","ja":"スヴァールãƒãƒ«è«¸å³¶ãŠã‚ˆã³ãƒ¤ãƒ³ãƒžã‚¤ã‚¨ãƒ³å³¶","it":"Svalbard e Jan Mayen"},"name":"Svalbard and Jan Mayen","alpha2Code":"SJ"},{"translations":{"br":"Suazilândia","pt":"Suazilândia","nl":"Swaziland","hr":"Svazi","fa":"سوازیلند","de":"Swasiland","es":"Suazilandia","fr":"Swaziland","ja":"スワジランド","it":"Swaziland"},"name":"Swaziland","alpha2Code":"SZ"},{"translations":{"br":"Suécia","pt":"Suécia","nl":"Zweden","hr":"Å vedska","fa":"سوئد","de":"Schweden","es":"Suecia","fr":"Suède","ja":"スウェーデン","it":"Svezia"},"name":"Sweden","alpha2Code":"SE"},{"translations":{"br":"Suíça","pt":"Suíça","nl":"Zwitserland","hr":"Å vicarska","fa":"سوئیس","de":"Schweiz","es":"Suiza","fr":"Suisse","ja":"スイス","it":"Svizzera"},"name":"Switzerland","alpha2Code":"CH"},{"translations":{"br":"Síria","pt":"Síria","nl":"Syrië","hr":"Sirija","fa":"سوریه","de":"Syrien","es":"Siria","fr":"Syrie","ja":"シリア・アラブ共和国","it":"Siria"},"name":"Syrian Arab Republic","alpha2Code":"SY"},{"translations":{"br":"Taiwan","pt":"Taiwan","nl":"Taiwan","hr":"Tajvan","fa":"تایوان","de":"Taiwan","es":"Taiwán","fr":"Taïwan","ja":"å°æ¹¾ï¼ˆä¸­è¯æ°‘国)","it":"Taiwan"},"name":"Taiwan","alpha2Code":"TW"},{"translations":{"br":"Tajiquistão","pt":"Tajiquistão","nl":"Tadzjikistan","hr":"TaÄ‘ikistan","fa":"تاجیکستان","de":"Tadschikistan","es":"Tayikistán","fr":"Tadjikistan","ja":"タジキスタン","it":"Tagikistan"},"name":"Tajikistan","alpha2Code":"TJ"},{"translations":{"br":"Tanzânia","pt":"Tanzânia","nl":"Tanzania","hr":"Tanzanija","fa":"تانزانیا","de":"Tansania","es":"Tanzania","fr":"Tanzanie","ja":"タンザニア","it":"Tanzania"},"name":"Tanzania, United Republic of","alpha2Code":"TZ"},{"translations":{"br":"Tailândia","pt":"Tailândia","nl":"Thailand","hr":"Tajland","fa":"تایلند","de":"Thailand","es":"Tailandia","fr":"Thaïlande","ja":"タイ","it":"Tailandia"},"name":"Thailand","alpha2Code":"TH"},{"translations":{"br":"Timor Leste","pt":"Timor Leste","nl":"Oost-Timor","hr":"IstoÄni Timor","fa":"تیمور شرقی","de":"Timor-Leste","es":"Timor Oriental","fr":"Timor oriental","ja":"æ±ãƒ†ã‚£ãƒ¢ãƒ¼ãƒ«","it":"Timor Est"},"name":"Timor-Leste","alpha2Code":"TL"},{"translations":{"br":"Togo","pt":"Togo","nl":"Togo","hr":"Togo","fa":"توگو","de":"Togo","es":"Togo","fr":"Togo","ja":"トーゴ","it":"Togo"},"name":"Togo","alpha2Code":"TG"},{"translations":{"br":"Tokelau","pt":"Toquelau","nl":"Tokelau","hr":"Tokelau","fa":"توکلائو","de":"Tokelau","es":"Islas Tokelau","fr":"Tokelau","ja":"トケラウ","it":"Isole Tokelau"},"name":"Tokelau","alpha2Code":"TK"},{"translations":{"br":"Tonga","pt":"Tonga","nl":"Tonga","hr":"Tonga","fa":"تونگا","de":"Tonga","es":"Tonga","fr":"Tonga","ja":"トンガ","it":"Tonga"},"name":"Tonga","alpha2Code":"TO"},{"translations":{"br":"Trinidad e Tobago","pt":"Trindade e Tobago","nl":"Trinidad en Tobago","hr":"Trinidad i Tobago","fa":"ترینیداد Ùˆ توباگو","de":"Trinidad und Tobago","es":"Trinidad y Tobago","fr":"Trinité et Tobago","ja":"トリニダード・トãƒã‚´","it":"Trinidad e Tobago"},"name":"Trinidad and Tobago","alpha2Code":"TT"},{"translations":{"br":"Tunísia","pt":"Tunísia","nl":"Tunesië","hr":"Tunis","fa":"تونس","de":"Tunesien","es":"Túnez","fr":"Tunisie","ja":"ãƒãƒ¥ãƒ‹ã‚¸ã‚¢","it":"Tunisia"},"name":"Tunisia","alpha2Code":"TN"},{"translations":{"br":"Turquia","pt":"Turquia","nl":"Turkije","hr":"Turska","fa":"ترکیه","de":"Türkei","es":"Turquía","fr":"Turquie","ja":"トルコ","it":"Turchia"},"name":"Turkey","alpha2Code":"TR"},{"translations":{"br":"Turcomenistão","pt":"Turquemenistão","nl":"Turkmenistan","hr":"Turkmenistan","fa":"ترکمنستان","de":"Turkmenistan","es":"Turkmenistán","fr":"Turkménistan","ja":"トルクメニスタン","it":"Turkmenistan"},"name":"Turkmenistan","alpha2Code":"TM"},{"translations":{"br":"Ilhas Turcas e Caicos","pt":"Ilhas Turcas e Caicos","nl":"Turks- en Caicoseilanden","hr":"Otoci Turks i Caicos","fa":"جزایر تورکس Ùˆ کایکوس","de":"Turks- und Caicosinseln","es":"Islas Turks y Caicos","fr":"ÃŽles Turques-et-Caïques","ja":"タークス・カイコス諸島","it":"Isole Turks e Caicos"},"name":"Turks and Caicos Islands","alpha2Code":"TC"},{"translations":{"br":"Tuvalu","pt":"Tuvalu","nl":"Tuvalu","hr":"Tuvalu","fa":"تووالو","de":"Tuvalu","es":"Tuvalu","fr":"Tuvalu","ja":"ツãƒãƒ«","it":"Tuvalu"},"name":"Tuvalu","alpha2Code":"TV"},{"translations":{"br":"Uganda","pt":"Uganda","nl":"Oeganda","hr":"Uganda","fa":"اوگاندا","de":"Uganda","es":"Uganda","fr":"Uganda","ja":"ウガンダ","it":"Uganda"},"name":"Uganda","alpha2Code":"UG"},{"translations":{"br":"Ucrânia","pt":"Ucrânia","nl":"Oekraïne","hr":"Ukrajina","fa":"وکراین","de":"Ukraine","es":"Ucrania","fr":"Ukraine","ja":"ウクライナ","it":"Ucraina"},"name":"Ukraine","alpha2Code":"UA"},{"translations":{"br":"Emirados árabes Unidos","pt":"Emirados árabes Unidos","nl":"Verenigde Arabische Emiraten","hr":"Ujedinjeni Arapski Emirati","fa":"امارات متحده عربی","de":"Vereinigte Arabische Emirate","es":"Emiratos Ãrabes Unidos","fr":"Émirats arabes unis","ja":"アラブ首長国連邦","it":"Emirati Arabi Uniti"},"name":"United Arab Emirates","alpha2Code":"AE"},{"translations":{"br":"Reino Unido","pt":"Reino Unido","nl":"Verenigd Koninkrijk","hr":"Ujedinjeno Kraljevstvo","fa":"بریتانیای کبیر Ùˆ ایرلند شمالی","de":"Vereinigtes Königreich","es":"Reino Unido","fr":"Royaume-Uni","ja":"イギリス","it":"Regno Unito"},"name":"United Kingdom of Great Britain and Northern Ireland","alpha2Code":"GB"},{"translations":{"br":"Estados Unidos","pt":"Estados Unidos","nl":"Verenigde Staten","hr":"Sjedinjene AmeriÄke Države","fa":"ایالات متحده آمریکا","de":"Vereinigte Staaten von Amerika","es":"Estados Unidos","fr":"États-Unis","ja":"アメリカåˆè¡†å›½","it":"Stati Uniti D\'America"},"name":"United States of America","alpha2Code":"US"},{"translations":{"br":"Uruguai","pt":"Uruguai","nl":"Uruguay","hr":"Urugvaj","fa":"اروگوئه","de":"Uruguay","es":"Uruguay","fr":"Uruguay","ja":"ウルグアイ","it":"Uruguay"},"name":"Uruguay","alpha2Code":"UY"},{"translations":{"br":"Uzbequistão","pt":"Usbequistão","nl":"Oezbekistan","hr":"Uzbekistan","fa":"ازبکستان","de":"Usbekistan","es":"Uzbekistán","fr":"Ouzbékistan","ja":"ウズベキスタン","it":"Uzbekistan"},"name":"Uzbekistan","alpha2Code":"UZ"},{"translations":{"br":"Vanuatu","pt":"Vanuatu","nl":"Vanuatu","hr":"Vanuatu","fa":"وانواتو","de":"Vanuatu","es":"Vanuatu","fr":"Vanuatu","ja":"ãƒãƒŒã‚¢ãƒ„","it":"Vanuatu"},"name":"Vanuatu","alpha2Code":"VU"},{"translations":{"br":"Venezuela","pt":"Venezuela","nl":"Venezuela","hr":"Venezuela","fa":"ونزوئلا","de":"Venezuela","es":"Venezuela","fr":"Venezuela","ja":"ベãƒã‚ºã‚¨ãƒ©ãƒ»ãƒœãƒªãƒãƒ«å…±å’Œå›½","it":"Venezuela"},"name":"Venezuela (Bolivarian Republic of)","alpha2Code":"VE"},{"translations":{"br":"Vietnã","pt":"Vietname","nl":"Vietnam","hr":"Vijetnam","fa":"ویتنام","de":"Vietnam","es":"Vietnam","fr":"Viêt Nam","ja":"ベトナム","it":"Vietnam"},"name":"Viet Nam","alpha2Code":"VN"},{"translations":{"br":"Wallis e Futuna","pt":"Wallis e Futuna","nl":"Wallis en Futuna","hr":"Wallis i Fortuna","fa":"والیس Ùˆ Ùوتونا","de":"Wallis und Futuna","es":"Wallis y Futuna","fr":"Wallis-et-Futuna","ja":"ウォリス・フツナ","it":"Wallis e Futuna"},"name":"Wallis and Futuna","alpha2Code":"WF"},{"translations":{"br":"Saara Ocidental","pt":"Saara Ocidental","nl":"Westelijke Sahara","hr":"Zapadna Sahara","fa":"جمهوری دموکراتیک عربی صحرا","de":"Westsahara","es":"Sahara Occidental","fr":"Sahara Occidental","ja":"西サãƒãƒ©","it":"Sahara Occidentale"},"name":"Western Sahara","alpha2Code":"EH"},{"translations":{"br":"Iêmen","pt":"Iémen","nl":"Jemen","hr":"Jemen","fa":"یمن","de":"Jemen","es":"Yemen","fr":"Yémen","ja":"イエメン","it":"Yemen"},"name":"Yemen","alpha2Code":"YE"},{"translations":{"br":"Zâmbia","pt":"Zâmbia","nl":"Zambia","hr":"Zambija","fa":"زامبیا","de":"Sambia","es":"Zambia","fr":"Zambie","ja":"ザンビア","it":"Zambia"},"name":"Zambia","alpha2Code":"ZM"},{"translations":{"br":"Zimbabwe","pt":"Zimbabué","nl":"Zimbabwe","hr":"Zimbabve","fa":"زیمباوه","de":"Simbabwe","es":"Zimbabue","fr":"Zimbabwe","ja":"ジンãƒãƒ–エ","it":"Zimbabwe"},"name":"Zimbabwe","alpha2Code":"ZW"}]', true); + +$countryKeys = array_map(function ($country) { + return Tools::strtoupper($country['alpha2Code']); +}, $countries); + +$langIso = Tools::strtolower(Context::getContext()->language->iso_code); +if (!in_array($langIso, array_keys($countries[0]['translations']))) { + $langIso = ''; +} + +if ($langIso) { + $countryValues = array_map(function ($country) use ($langIso) { + return $country['translations'][$langIso]; + }, $countries); +} else { + $countryValues = array_map(function ($country) { + return $country['name']; + }, $countries); +} + +$countries = array(); +foreach ($countryKeys as $index => $countryKey) { + $countries[] = array( + 'id' => $countryKey, + 'name' => $countryValues[$index], + ); +} + +return $countries; diff --git a/docker-compose.yml b/docker-compose.yml index 19760d7f6..c998a37f9 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,34 +1,34 @@ -version: "3" - -volumes: - db-data: - vendor: - var: - -services: - mysql: - image: mysql:5 - ports: - - "3306" - environment: - MYSQL_ROOT_PASSWORD: password - MYSQL_DATABASE: prestashop - restart: always - apache: - container_name: prestashop - image: "prestashop/prestashop:${PRESTASHOP_VERSION}" - environment: - PS_INSTALL_AUTO: 1 - DB_PASSWD: password - DB_NAME: prestashop - DB_SERVER: mysql - PS_DOMAIN: "localhost:${PRESTASHOP_PORT}" - PS_FOLDER_INSTALL: install-dev - PS_FOLDER_ADMIN: admin-dev - ADMIN_MAIL: "prestashop@mollie.com" - ADMIN_PASSWD: "mollie_test_156" - ports: - - "${PRESTASHOP_PORT}:80" - volumes: - - ./prestashop:/var/www/html/:delegated - restart: always +version: "3" + +volumes: + db-data: + vendor: + var: + +services: + mysql: + image: mysql:5 + ports: + - "3306" + environment: + MYSQL_ROOT_PASSWORD: password + MYSQL_DATABASE: prestashop + restart: always + apache: + container_name: prestashop + image: "prestashop/prestashop:${PRESTASHOP_VERSION}" + environment: + PS_INSTALL_AUTO: 1 + DB_PASSWD: password + DB_NAME: prestashop + DB_SERVER: mysql + PS_DOMAIN: "localhost:${PRESTASHOP_PORT}" + PS_FOLDER_INSTALL: install-dev + PS_FOLDER_ADMIN: admin-dev + ADMIN_MAIL: "prestashop@mollie.com" + ADMIN_PASSWD: "mollie_test_156" + ports: + - "${PRESTASHOP_PORT}:80" + volumes: + - ./prestashop:/var/www/html/:delegated + restart: always diff --git a/greenkeeper.json b/greenkeeper.json index 0dedd8ac9..82d10892d 100644 --- a/greenkeeper.json +++ b/greenkeeper.json @@ -1,9 +1,9 @@ -{ - "groups": { - "default": { - "packages": [ - "views/js/src/package.json" - ] - } - } -} +{ + "groups": { + "default": { + "packages": [ + "views/js/src/package.json" + ] + } + } +} diff --git a/index.php b/index.php index 729abf520..a950d02f4 100644 --- a/index.php +++ b/index.php @@ -1,11 +1,11 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ -if (!include_once(dirname(__FILE__) . '/vendor/autoload.php')) { - return; -} -/** - * Class Mollie - * - * // Translation detection: - * $this->l('Shipping); - * $this->l('Gift wrapping'); - */ -class Mollie extends PaymentModule -{ - /** - * Symfony DI Container - **/ - private $moduleContainer; - - const DISABLE_CACHE = true; - /** @var _PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient|null */ - public $api = null; - /** @var string $currentOrderReference */ - public $currentOrderReference; - /** @var string $selectedApi */ - public static $selectedApi; - /** @var bool $cacheCleared Indicates whether the Smarty cache has been cleared during updates */ - public static $cacheCleared; - - // The Addons version does not include the GitHub updater - const ADDONS = false; - - const SUPPORTED_PHP_VERSION = '5.6'; - /** - * Mollie constructor. - * - * @throws ErrorException - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ - public function __construct() - { - $this->name = 'mollie'; - $this->tab = 'payments_gateways'; - $this->version = '4.0.0'; - $this->author = 'Mollie B.V.'; - $this->need_instance = 1; - $this->bootstrap = true; - $this->module_key = 'a48b2f8918358bcbe6436414f48d8915'; - - parent::__construct(); - $this->ps_versions_compliancy = array('min' => '1.6.1.0', 'max' => _PS_VERSION_); - $this->displayName = $this->l('Mollie'); - $this->description = $this->l('Mollie Payments'); - - if (version_compare(phpversion(), $this::SUPPORTED_PHP_VERSION) === -1) { - return; - } - - $this->compile(); - $this->setApiKey(); - } - - /** - * Installs the Mollie Payments Module - * - * @return bool - */ - public function install() - { - if (version_compare(phpversion(), Mollie\Config\Config::SUPPORTED_PHP_VERSION) === -1) { - $this->_errors[] = $this->l('Dear customer, your PHP version is too low. Please upgrade your PHP version to use this module. Mollie module supports PHP 5.6 and higher versions.'); - return false; - } - - if (!parent::install()) { - $this->_errors[] = $this->l('Unable to install module'); - - return false; - } - - /** @var \Mollie\Install\Installer $installer */ - $installer = $this->getContainer(\Mollie\Install\Installer::class); - if (!$installer->install()) { - $this->_errors = array_merge($this->_errors, $installer->getErrors()); - return false; - } - - - return true; - } - - /** - * @return bool - * - */ - public function uninstall() - { - /** @var \Mollie\Install\Uninstall $uninstall */ - $uninstall = $this->getContainer(\Mollie\Install\Uninstall::class); - if (!$uninstall->uninstall()) { - $this->_errors[] = $uninstall->getErrors(); - return false; - } - - return parent::uninstall(); - } - - private function compile() - { - $containerCache = $this->getLocalPath() . 'var/cache/container.php'; - - try { - $containerConfigCache = new _PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($containerCache, self::DISABLE_CACHE); - } catch (Exception $e) { - $this->getContainer()->get('prestashop.core.cache.clearer.cache_clearer_chain')->clear(); - $containerConfigCache = new _PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($containerCache, self::DISABLE_CACHE); - } - $containerClass = get_class($this) . 'Container'; - if (!$containerConfigCache->isFresh()) { - $containerBuilder = new _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $locator = new _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator($this->getLocalPath() . 'config'); - $loader = new _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($containerBuilder, $locator); - $loader->load('config.yml'); - $containerBuilder->compile(); - $dumper = new _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($containerBuilder); - $containerConfigCache->write( - $dumper->dump(['class' => $containerClass]), - $containerBuilder->getResources() - ); - } - require_once $containerCache; - $this->moduleContainer = new $containerClass(); - } - - /** - * @param bool $id - * @return mixed - */ - public function getContainer($id = false) - { - if ($id) { - return $this->moduleContainer->get($id); - } - - return $this->moduleContainer; - } - - /** - * @return mixed - */ - public function getErrors() - { - return $this->_errors; - } - - public function getTable() - { - return $this->table; - } - - public function getContext() - { - return $this->context; - } - public function getIdentifier() - { - return $this->identifier; - } - - /** - * @return string - * - * @throws Exception - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws SmartyException - */ - public function getContent() - { - if (Tools::getValue('ajax')) { - header('Content-Type: application/json;charset=UTF-8'); - - if (!method_exists($this, 'displayAjax' . Tools::ucfirst(Tools::getValue('action')))) { - die(json_encode([ - 'success' => false, - ])); - } - die(json_encode($this->{'displayAjax' . Tools::ucfirst(Tools::getValue('action'))}())); - } - /** @var \Mollie\Repository\ModuleRepository $moduleRepository */ - $moduleRepository = $this->getContainer(\Mollie\Repository\ModuleRepository::class); - $moduleDatabaseVersion = $moduleRepository->getModuleDatabaseVersion($this->name); - if ($moduleDatabaseVersion < $this->version) { - $this->context->controller->errors[] = $this->l('Please upgrade Mollie module.'); - return; - } - /** @var \Mollie\Builder\FormBuilder $settingsFormBuilder */ - $settingsFormBuilder = $this->getContainer(\Mollie\Builder\FormBuilder::class); - if (!Configuration::get('PS_SMARTY_FORCE_COMPILE')) { - $this->context->smarty->assign([ - 'settingKey' => $this->l('Template compilation'), - 'settingValue' => $this->l('Never recompile template files'), - 'settingsPage' => \Mollie\Utility\MenuLocationUtility::getMenuLocation('AdminPerformance'), - ]); - $this->context->controller->warnings[] = $this->display(__FILE__, 'smarty_warning.tpl'); - } - if (Configuration::get('PS_SMARTY_CACHE') && Configuration::get('PS_SMARTY_CLEAR_CACHE') === 'never') { - $this->context->smarty->assign([ - 'settingKey' => $this->l('Clear cache'), - 'settingValue' => $this->l('Never clear cache files'), - 'settingsPage' => \Mollie\Utility\MenuLocationUtility::getMenuLocation('AdminPerformance'), - ]); - $this->context->controller->errors[] = $this->display(__FILE__, 'smarty_error.tpl'); - } - if (\Mollie\Utility\CartPriceUtility::checkRoundingMode()) { - $this->context->smarty->assign([ - 'settingKey' => $this->l('Rounding mode'), - 'settingValue' => $this->l('Round up away from zero, when it is half way there (recommended)'), - 'settingsPage' => \Mollie\Utility\MenuLocationUtility::getMenuLocation('AdminPreferences'), - ]); - $this->context->controller->errors[] = $this->display(__FILE__, 'rounding_error.tpl'); - } - - $this->context->smarty->assign([ - 'link' => Context::getContext()->link, - 'module_dir' => __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/', - 'publicPath' => __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/views/js/dist/', - ]); - - $resultMessage = ''; - $warningMessage = ''; - - $errors = []; - - if (Tools::isSubmit("submit{$this->name}")) { - /** @var \Mollie\Service\SettingsSaveService $saveSettingsService */ - $saveSettingsService = $this->getContainer(\Mollie\Service\SettingsSaveService::class); - $resultMessage = $saveSettingsService->saveSettings($errors); - if (!empty($errors)) { - $this->context->controller->errors = $resultMessage; - } else { - $this->context->controller->confirmations[] = $resultMessage; - } - } - /** @var Mollie\Service\LanguageService $langService */ - $langService = $this->getContainer(Mollie\Service\LanguageService::class); - $data = [ - 'title_status' => $this->l('%s statuses:'), - 'title_visual' => $this->l('Visual settings:'), - 'title_debug' => $this->l('Debug info:'), - 'msg_result' => $resultMessage, - 'msg_warning' => $warningMessage, - 'path' => $this->_path, - 'val_api_key' => Configuration::get(Mollie\Config\Config::MOLLIE_API_KEY), - 'payscreen_locale_value' => Configuration::get(Mollie\Config\Config::MOLLIE_PAYMENTSCREEN_LOCALE), - 'val_images' => Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES), - 'val_issuers' => Configuration::get(Mollie\Config\Config::MOLLIE_ISSUERS), - 'val_css' => Configuration::get(Mollie\Config\Config::MOLLIE_CSS), - 'val_errors' => Configuration::get(Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS), - 'val_qrenabled' => Configuration::get(Mollie\Config\Config::MOLLIE_QRENABLED), - 'val_logger' => Configuration::get(Mollie\Config\Config::MOLLIE_DEBUG_LOG), - 'val_save' => $this->l('Save'), - 'lang' => $langService->getLang(), - 'logo_url' => $this->getPathUri() . 'views/img/mollie_logo.png', - 'webpack_urls' => \Mollie\Utility\UrlPathUtility::getWebpackChunks('app'), - 'description_message' => $this->l('Description cannot be empty'), - 'Profile_id_message' => $this->l('Wrong profile ID') - ]; - - Media::addJsDef([ - 'description_message' => $this->l('Description cannot be empty'), - 'profile_id_message' => $this->l('Wrong profile ID'), - 'profile_id_message_empty' => $this->l('Profile ID cannot be empty'), - 'payment_api' => Mollie\Config\Config::MOLLIE_PAYMENTS_API, - ]); - $this->context->controller->addJS($this->getPathUri() . 'views/js/method_countries.js'); - $this->context->controller->addJS($this->getPathUri() . 'views/js/validation.js'); - $this->context->controller->addJS($this->getPathUri() . 'views/js/admin/settings.js'); - $this->context->controller->addCSS($this->getPathUri() . 'views/css/mollie.css'); - $this->context->smarty->assign($data); - - $html = ''; - $html .= $this->display(__FILE__, 'views/templates/admin/logo.tpl'); - - - try { - $html .= $settingsFormBuilder->buildSettingsForm(); - } catch (PrestaShopDatabaseException $e) { - $this->context->controller->errors[] = $this->l('You are missing database tables. Try resetting module.'); - } - - return $html; - } - - /** - * @param string $str - * - * @return string - */ - public function lang($str) - { - /** @var Mollie\Service\LanguageService $langService */ - $langService = $this->getContainer(Mollie\Service\LanguageService::class); - $lang = $langService->getLang(); - if (array_key_exists($str, $lang)) { - return $lang[$str]; - } - - return $str; - } - - /** - * @param string $url - * - * @return string|true - * @throws Exception - * @throws PrestaShopException - * @throws SmartyException - */ - protected function getUpdateMessage($url) - { - $updateMessage = ''; - $updateXml = $this->getUpdateXML($url); - if ($updateXml === false) { - $updateMessage = $this->l('Warning: Could not retrieve update xml file from github.'); - } else { - try { - /** @var SimpleXMLElement $tags */ - @$tags = new SimpleXMLElement($updateXml); - if (!empty($tags) && isset($tags->entry, $tags->entry[0], $tags->entry[0]->id)) { - $title = $tags->entry[0]->id; - $latestVersion = preg_replace("/[^0-9,.]/", '', Tools::substr($title, strrpos($title, '/'))); - if (!version_compare($this->version, $latestVersion, '>=')) { - $this->context->smarty->assign([ - 'this_version' => $this->version, - 'release_version' => $latestVersion, - ]); - $updateMessage = 'updateAvailable'; - } - } else { - $updateMessage = $this->l('Warning: Update xml file from github follows an unexpected format.'); - } - } catch (Exception $e) { - $updateMessage = $this->l('Warning: Update xml file from github follows an unexpected format.'); - } - } - - return $updateMessage; - } - - /** - * @param string $url - * - * @return string - */ - protected function getUpdateXML($url) - { - if (static::ADDONS) { - return ''; - } - - return @Tools::file_get_contents($url . '/releases.atom'); - } - - /** - * @throws PrestaShopException - */ - public function hookActionFrontControllerSetMedia() - { - $isOrderController = $this->context->controller instanceof OrderControllerCore; - $isOPCController = $this->context->controller instanceof OrderOpcControllerCore; - if ($isOrderController || $isOPCController) { - - Media::addJsDef([ - 'profileId' => Configuration::get(Mollie\Config\Config::MOLLIE_PROFILE_ID), - 'isoCode' => $this->context->language->language_code, - 'isTestMode' => \Mollie\Config\Config::isTestMode() - ]); - if (\Mollie\Config\Config::isVersion17()) { - $this->context->controller->registerJavascript( - 'mollie_iframe_js', - 'https://js.mollie.com/v1/mollie.js', - ['server' => 'remote', 'position' => 'bottom', 'priority' => 150] - ); - $this->context->controller->addJS("{$this->_path}views/js/front/mollie_iframe.js"); - } else { - $this->context->controller->addMedia('https://js.mollie.com/v1/mollie.js', null, null, false, false); - $this->context->controller->addJS("{$this->_path}views/js/front/mollie_iframe_16.js"); - } - Media::addJsDef([ - 'ajaxUrl' => $this->context->link->getModuleLink('mollie', 'ajax'), - 'isPS17' => \Mollie\Config\Config::isVersion17(), - ]); - $this->context->controller->addJS("{$this->_path}views/js/front/mollie_error_handle.js"); - $this->context->controller->addCSS("{$this->_path}views/css/mollie_iframe.css"); - if (Configuration::get('PS_SSL_ENABLED_EVERYWHERE')) { - $this->context->controller->addJS($this->getPathUri() . 'views/js/apple_payment.js'); - } - $this->context->smarty->assign([ - 'custom_css' => Configuration::get(Mollie\Config\Config::MOLLIE_CSS), - ]); - - $this->context->controller->addJS("{$this->_path}views/js/front/payment_fee.js"); - - return $this->display(__FILE__, 'views/templates/front/custom_css.tpl'); - } - } - - /** - * @throws PrestaShopException - * @throws SmartyException - */ - public function hookDisplayBackOfficeHeader() - { - $html = ''; - - if ($this->context->controller instanceof AdminOrdersController) { - $this->context->smarty->assign([ - 'mollieProcessUrl' => $this->context->link->getAdminLink('AdminModules', true) . '&configure=mollie&ajax=1', - 'mollieCheckMethods' => time() > ((int)Configuration::get(Mollie\Config\Config::MOLLIE_METHODS_LAST_CHECK) + Mollie\Config\Config::MOLLIE_METHODS_CHECK_INTERVAL), - ]); - $html .= $this->display(__FILE__, 'views/templates/admin/ordergrid.tpl'); - } - - return $html; - } - - /** - * @param array $params Hook parameters - * - * @return string Hook HTML - * - * @throws Adapter_Exception - * @throws Exception - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws SmartyException - */ - public function hookDisplayAdminOrder($params) - { - /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ - /** @var \Mollie\Service\ShipmentService $shipmentService */ - $paymentMethodRepo = $this->getContainer(\Mollie\Repository\PaymentMethodRepository::class); - $shipmentService = $this->getContainer(\Mollie\Service\ShipmentService::class); - - $cartId = Cart::getCartIdByOrderId((int)$params['id_order']); - $transaction = $paymentMethodRepo->getPaymentBy('cart_id', (int)$cartId); - if (empty($transaction)) { - return false; - } - $currencies = []; - foreach (Currency::getCurrencies() as $currency) { - $currencies[Tools::strtoupper($currency['iso_code'])] = [ - 'name' => $currency['name'], - 'iso_code' => Tools::strtoupper($currency['iso_code']), - 'sign' => $currency['sign'], - 'blank' => (bool)isset($currency['blank']) ? $currency['blank'] : true, - 'format' => (int)$currency['format'], - 'decimals' => (bool)isset($currency['decimals']) ? $currency['decimals'] : true, - ]; - } - - $order = new Order($params['id_order']); - $this->context->smarty->assign([ - 'ajaxEndpoint' => $this->context->link->getAdminLink('AdminModules', true) . '&configure=mollie&ajax=1&action=MollieOrderInfo', - 'transactionId' => $transaction['transaction_id'], - 'currencies' => $currencies, - 'tracking' => $shipmentService->getShipmentInformation($order->reference), - 'publicPath' => __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/views/js/dist/', - 'webPackChunks' => \Mollie\Utility\UrlPathUtility::getWebpackChunks('app'), - 'errorDisplay' => Configuration::get(Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS) - ]); - - return $this->display(__FILE__, 'order_info.tpl'); - } - - /** - * @return string - * @throws Exception - * @throws PrestaShopException - * @throws SmartyException - */ - public function hookDisplayPayment() - { - $smarty = $this->context->smarty; - $issuerSetting = Configuration::get(Mollie\Config\Config::MOLLIE_ISSUERS); - - /** @var \Mollie\Service\PaymentMethodService $paymentMethodService */ - /** @var \Mollie\Service\IssuerService $issuerService */ - /** @var \Mollie\Service\OrderFeeService $orderFeeService */ - $paymentMethodService = $this->getContainer(\Mollie\Service\PaymentMethodService::class); - $issuerService = $this->getContainer(\Mollie\Service\IssuerService::class); - $orderFeeService = $this->getContainer(\Mollie\Service\OrderFeeService::class); - - $apiMethods = $paymentMethodService->getMethodsForCheckout(); - $issuerList = []; - foreach ($apiMethods as $apiMethod) { - if ($apiMethod['id_payment_method'] === _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL) { - $issuerList = $issuerService->getIdealIssuers(); - } - } - $apiMethods = $orderFeeService->getPaymentFees($apiMethods, $this->context->cart->getOrderTotal()); - - $isIFrameEnabled = Configuration::get(Mollie\Config\Config::MOLLIE_IFRAME); - /** @var Cart $cart */ - $cart = Context::getContext()->cart; - $smarty->assign([ - 'mollieIframe' => $isIFrameEnabled, - 'link' => $this->context->link, - 'cartAmount' => (int)($cart->getOrderTotal(true) * 100), - 'methods' => $apiMethods, - 'issuers' => $issuerList, - 'issuer_setting' => $issuerSetting, - 'images' => Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES), - 'warning' => $this->warning, - 'msg_pay_with' => $this->l('Pay with %s'), - 'msg_bankselect' => $this->l('Select your bank:'), - 'module' => $this, - 'publicPath' => __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/views/js/dist/', - 'IsQREnabled' => Mollie\Config\Config::MOLLIE_QRENABLED, - 'CARTES_BANCAIRES' => Mollie\Config\Config::CARTES_BANCAIRES, - 'ISSUERS_ON_CLICK' => Mollie\Config\Config::ISSUERS_ON_CLICK, - 'web_pack_chunks' => Mollie\Utility\UrlPathUtility::getWebpackChunks('app'), - 'display_errors' => Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS, - 'mollie_translations' => [ - 'chooseYourBank' => $this->l('Choose your bank'), - 'orPayByIdealQr' => $this->l('or pay by iDEAL QR'), - 'choose' => $this->l('Choose'), - 'cancel' => $this->l('Cancel'), - ], - ]); - - $iframeDisplay = ''; - if (!\Mollie\Config\Config::isVersion17() && $isIFrameEnabled) { - $iframeDisplay = $this->display(__FILE__, 'mollie_iframe_16.tpl'); - } - return $this->display(__FILE__, 'addjsdef.tpl') . $this->display(__FILE__, 'payment.tpl') . $iframeDisplay; - } - - /** - * EU Advanced Compliance module (PrestaShop module) Advanced Checkout option enabled - * - * @return array|null - * - * @throws PrestaShopException - */ - public function hookDisplayPaymentEU() - { - // Please update your one page checkout module if it depends on `displayPaymentEU` - // Mollie does no longer support this hook on PresaShop v1.7 or higher - // due to the problems caused by mixing the hooks `paymentOptions` and `displayPaymentEU` - // Only uncomment the following three lines if you have no other choice: - if (version_compare(_PS_VERSION_, '1.7.0.0', '>=')) { - return []; - } - /** @var \Mollie\Service\PaymentMethodService $paymentMethodService */ - /** @var \Mollie\Service\IssuerService $issuerService */ - $paymentMethodService = $this->getContainer(\Mollie\Service\PaymentMethodService::class); - $issuerService = $this->getContainer(\Mollie\Service\IssuerService::class); - - $methods = $paymentMethodService->getMethodsForCheckout(); - $issuerList = []; - foreach ($methods as $apiMethod) { - if ($apiMethod['id'] === _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL) { - $issuerList = $issuerService->getIdealIssuers(); - } - } - - $context = Context::getContext(); - $iso = Tools::strtolower($context->currency->iso_code); - $paymentOptions = []; - - foreach ($methods as $method) { - if (!isset(Mollie\Config\Config::$methodCurrencies[$method['id']])) { - continue; - } - if (!in_array($iso, Mollie\Config\Config::$methodCurrencies[$method['id']])) { - continue; - } - - $paymentOptions[] = [ - 'cta_text' => $this->lang($method['name']), - 'logo' => Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES) === Mollie\Config\Config::LOGOS_NORMAL - ? $method['image']['size1x'] - : $method['image']['size2x'], - 'action' => $this->context->link->getModuleLink( - 'mollie', - 'payment', - ['method' => $method['id'], 'rand' => time()], - true - ), - ]; - } - - return $paymentOptions; - } - - /** - * @param array $params - * - * @return array|null - * @throws Exception - * @throws PrestaShopException - * @throws SmartyException - */ - public function hookPaymentOptions() - { - if (version_compare(_PS_VERSION_, '1.7.0.0', '<')) { - return []; - } - /** @var \Mollie\Service\PaymentMethodService $paymentMethodService */ - /** @var \Mollie\Service\IssuerService $issuerService */ - $paymentMethodService = $this->getContainer(\Mollie\Service\PaymentMethodService::class); - $issuerService = $this->getContainer(\Mollie\Service\IssuerService::class); - - $methodIds = $paymentMethodService->getMethodsForCheckout(); - $issuerList = []; - foreach ($methodIds as $methodId) { - $methodObj = new MolPaymentMethod($methodId['id_payment_method']); - if ($methodObj->id_method === _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL) { - $issuerList = $issuerService->getIdealIssuers(); - } - } - - $context = Context::getContext(); - $cart = $context->cart; - - $context->smarty->assign([ - 'idealIssuers' => isset($issuerList[_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL]) - ? $issuerList[_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL] - : [], - 'link' => $this->context->link, - 'qrCodeEnabled' => Configuration::get(Mollie\Config\Config::MOLLIE_QRENABLED), - 'qrAlign' => 'left', - 'cartAmount' => (int)($cart->getOrderTotal(true) * 100), - 'publicPath' => __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/views/js/dist/', - ]); - - $iso = Tools::strtolower($context->currency->iso_code); - $paymentOptions = []; - foreach ($methodIds as $methodId) { - if (!isset(Mollie\Config\Config::$methodCurrencies[$methodObj->id_method])) { - continue; - } - if (!in_array($iso, Mollie\Config\Config::$methodCurrencies[$methodObj->id_method])) { - continue; - } - - $methodObj = new MolPaymentMethod($methodId['id_payment_method']); - $paymentFee = \Mollie\Utility\PaymentFeeUtility::getPaymentFee($methodObj, $cart->getOrderTotal()); - - $isIdealMethod = $methodObj->id_method === _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL; - $isIssuersOnClick = Configuration::get(Mollie\Config\Config::MOLLIE_ISSUERS) === Mollie\Config\Config::ISSUERS_ON_CLICK; - $isCreditCardMethod = $methodObj->id_method === _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::CREDITCARD; - - if ($isIdealMethod && $isIssuersOnClick) { - $newOption = new PrestaShop\PrestaShop\Core\Payment\PaymentOption(); - $newOption - ->setCallToActionText($this->lang($methodObj->method_name)) - ->setModuleName($this->name) - ->setAction(Context::getContext()->link->getModuleLink( - $this->name, - 'payment', - ['method' => $methodObj->id_method, 'rand' => time()], - true - )) - ->setInputs([ - 'token' => [ - 'name' => 'issuer', - 'type' => 'hidden', - 'value' => '', - ], - ]) - ->setAdditionalInformation($this->display(__FILE__, 'ideal_dropdown.tpl')); - - $imageConfig = Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES); - $image = json_decode($methodObj->images_json, true); - $image = \Mollie\Utility\ImageUtility::setOptionImage($image, $imageConfig); - $newOption->setLogo($image); - - if ($paymentFee) { - $newOption->setInputs( - [ - [ - 'type' => 'hidden', - 'name' => "payment-fee-price", - 'value' => $paymentFee - ], - [ - 'type' => 'hidden', - 'name' => "payment-fee-price-display", - 'value' => sprintf($this->l('Payment Fee: %1s'), Tools::displayPrice($paymentFee)) - ], - ] - ); - } - - $paymentOptions[] = $newOption; - } elseif ( - ($isCreditCardMethod || $methodObj->id_method === \Mollie\Config\Config::CARTES_BANCAIRES) && - Configuration::get(Mollie\Config\Config::MOLLIE_IFRAME) - ) { - $this->context->smarty->assign([ - 'mollieIFrameJS' => 'https://js.mollie.com/v1/mollie.js', - 'price' => $this->context->cart->getOrderTotal(), - 'priceSign' => $this->context->currency->getSign(), - 'methodId' => $methodObj->id_method - ]); - $newOption = new PrestaShop\PrestaShop\Core\Payment\PaymentOption(); - $newOption - ->setCallToActionText($this->lang($methodObj->method_name)) - ->setModuleName($this->name) - ->setAdditionalInformation($this->display(__FILE__, 'mollie_iframe.tpl')) - ->setInputs( - [ - [ - 'type' => 'hidden', - 'name' => "mollieCardToken{$methodObj->id_method}", - 'value' => '' - ] - ] - ) - ->setAction(Context::getContext()->link->getModuleLink( - 'mollie', - 'payScreen', - ['method' => $methodObj->id_method, 'rand' => time(), 'cardToken' => ''], - true - )); - - $imageConfig = Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES); - $image = json_decode($methodObj->images_json, true); - $image = \Mollie\Utility\ImageUtility::setOptionImage($image, $imageConfig); - $newOption->setLogo($image); - - if ($paymentFee) { - $newOption->setInputs( - [ - [ - 'type' => 'hidden', - 'name' => "mollieCardToken{$methodObj->id_method}", - 'value' => '' - ], - [ - 'type' => 'hidden', - 'name' => "payment-fee-price", - 'value' => $paymentFee - ], - [ - 'type' => 'hidden', - 'name' => "payment-fee-price-display", - 'value' => sprintf($this->l('Payment Fee: %1s'), Tools::displayPrice($paymentFee)) - ], - ] - ); - } else { - $newOption->setInputs( - [ - [ - 'type' => 'hidden', - 'name' => "mollieCardToken{$methodObj->id_method}", - 'value' => '' - ], - ] - ); - } - - $paymentOptions[] = $newOption; - } else { - $newOption = new PrestaShop\PrestaShop\Core\Payment\PaymentOption(); - $newOption - ->setCallToActionText($this->lang($methodObj->method_name)) - ->setModuleName($this->name) - ->setAction(Context::getContext()->link->getModuleLink( - 'mollie', - 'payment', - ['method' => $methodObj->id_method, 'rand' => time()], - true - )); - - $imageConfig = Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES); - $image = json_decode($methodObj->images_json, true); - $image = \Mollie\Utility\ImageUtility::setOptionImage($image, $imageConfig); - $newOption->setLogo($image); - - if ($paymentFee) { - $newOption->setInputs( - [ - [ - 'type' => 'hidden', - 'name' => "payment-fee-price", - 'value' => $paymentFee - ], - [ - 'type' => 'hidden', - 'name' => "payment-fee-price-display", - 'value' => sprintf($this->l('Payment Fee: %1s'), Tools::displayPrice($paymentFee)) - ], - ] - ); - } - - $paymentOptions[] = $newOption; - } - } - - return $paymentOptions; - } - - /** - * @return string - * - * @throws Exception - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws SmartyException - */ - public function hookDisplayOrderConfirmation() - { - /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->getContainer(\Mollie\Repository\PaymentMethodRepository::class); - $payment = $paymentMethodRepo->getPaymentBy('cart_id', (int)Tools::getValue('id_cart')); - if ($payment && $payment['bank_status'] == _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_PAID) { - $this->context->smarty->assign('okMessage', $this->l('Thank you. Your payment has been received.')); - - return $this->display(__FILE__, 'ok.tpl'); - } - - return ''; - } - - /** - * @return array - * @throws PrestaShopException - * - * @since 3.3.0 - */ - public function displayAjaxMollieMethodConfig() - { - header('Content-Type: application/json;charset=UTF-8'); - /** @var \Mollie\Service\ApiService $apiService */ - $apiService = $this->getContainer(\Mollie\Service\ApiService::class); - /** @var \Mollie\Service\CountryService $countryService */ - $countryService = $this->getContainer(\Mollie\Service\CountryService::class); - try { - - $methodsForConfig = $apiService->getMethodsForConfig($this->api, $this->getPathUri()); - } catch (_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - return [ - 'success' => false, - 'methods' => null, - 'message' => $e->getMessage(), - ]; - } catch (PrestaShopException $e) { - return [ - 'success' => false, - 'methods' => null, - 'message' => $e->getMessage(), - ]; - } - Configuration::updateValue(Mollie\Config\Config::MOLLIE_METHODS_LAST_CHECK, time()); - if (!is_array($methodsForConfig)) { - return [ - 'success' => false, - 'methods' => null, - 'message' => $this->l('No payment methods found'), - ]; - } - - $dbMethods = @json_decode(Configuration::get(Mollie\Config\Config::METHODS_CONFIG), true); - - // Auto update images and issuers - $shouldSave = false; - if (is_array($dbMethods)) { - foreach ($dbMethods as $index => &$dbMethod) { - $found = false; - foreach ($methodsForConfig as $methodForConfig) { - if ($dbMethod['id'] === $methodForConfig['id']) { - $found = true; - foreach (['issuers', 'image', 'name', 'available'] as $prop) { - if (isset($methodForConfig[$prop])) { - $dbMethod[$prop] = $methodForConfig[$prop]; - $shouldSave = true; - } - } - break; - } - } - if (!$found) { - unset($dbMethods[$index]); - $shouldSave = true; - } - } - } else { - $shouldSave = true; - $dbMethods = []; - foreach ($methodsForConfig as $index => $method) { - $dbMethods[] = array_merge( - $method, - [ - 'position' => $index, - ] - ); - } - } - - if ($shouldSave && !empty($dbMethods)) { - Configuration::updateValue(Mollie\Config\Config::METHODS_CONFIG, json_encode($dbMethods)); - } - - return [ - 'success' => true, - 'methods' => $methodsForConfig, - 'countries' => $countryService->getActiveCountriesList(), - ]; - } - - /** - * @return array - * @throws Adapter_Exception - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * - * @since 3.3.0 - */ - public function displayAjaxMollieOrderInfo() - { - header('Content-Type: application/json;charset=UTF-8'); - - /** @var \Mollie\Service\MollieOrderInfoService $orderInfoService */ - $orderInfoService = $this->getContainer(\Mollie\Service\MollieOrderInfoService::class); - - $input = @json_decode(Tools::file_get_contents('php://input'), true); - $adminOrdersController = new AdminOrdersController(); - return $orderInfoService->displayMollieOrderInfo($input, $adminOrdersController->id); - } - - /** - * actionOrderStatusUpdate hook - * - * @param array $params - * - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - * @throws Adapter_Exception - * - * @since 3.3.0 - */ - public function hookActionOrderStatusUpdate($params = []) - { - if (!isset($params['newOrderStatus']) || !isset($params['id_order'])) { - return; - } - - if ($params['newOrderStatus'] instanceof OrderState) { - $orderStatus = $params['newOrderStatus']; - } elseif (is_int($params['newOrderStatus']) || is_string($params['newOrderStatus'])) { - $orderStatus = new OrderState($params['newOrderStatus']); - } - if (isset($orderStatus) - && $orderStatus instanceof OrderState - && Validate::isLoadedObject($orderStatus) - ) { - $orderStatusNumber = $orderStatus->id; - } else { - return; - } - - $idOrder = $params['id_order']; - $order = new Order($idOrder); - $checkStatuses = []; - if (Configuration::get(Mollie\Config\Config::MOLLIE_AUTO_SHIP_STATUSES)) { - $checkStatuses = @json_decode(Configuration::get(Mollie\Config\Config::MOLLIE_AUTO_SHIP_STATUSES)); - } - if (!is_array($checkStatuses)) { - $checkStatuses = []; - } - - /** @var \Mollie\Service\ShipmentService $shipmentService */ - $shipmentService = $this->getContainer(\Mollie\Service\ShipmentService::class); - $shipmentInfo = $shipmentService->getShipmentInformation($order->reference); - - if (!(Configuration::get(Mollie\Config\Config::MOLLIE_AUTO_SHIP_MAIN) && in_array($orderStatusNumber, $checkStatuses) - ) || $shipmentInfo === null - ) { - return; - } - - try { - /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ - $paymentMethodRepo = $this->getContainer(\Mollie\Repository\PaymentMethodRepository::class); - $dbPayment = $paymentMethodRepo->getPaymentBy('order_id', (int)$idOrder); - } catch (PrestaShopDatabaseException $e) { - PrestaShopLogger::addLog("Mollie module error: {$e->getMessage()}"); - return; - } catch (PrestaShopException $e) { - PrestaShopLogger::addLog("Mollie module error: {$e->getMessage()}"); - return; - } - if (empty($dbPayment) || !isset($dbPayment['transaction_id'])) { - // No transaction found - return; - } - - $length = Tools::strlen(_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderEndpoint::RESOURCE_ID_PREFIX); - if (Tools::substr($dbPayment['transaction_id'], 0, $length) !== _PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderEndpoint::RESOURCE_ID_PREFIX - ) { - // No need to check regular payments - return; - } - - try { - $apiOrder = $this->api->orders->get($dbPayment['transaction_id']); - $shippableItems = 0; - foreach ($apiOrder->lines as $line) { - $shippableItems += $line->shippableQuantity; - } - if ($shippableItems <= 0) { - return; - } - - $apiOrder->shipAll($shipmentInfo); - } catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - PrestaShopLogger::addLog("Mollie module error: {$e->getMessage()}"); - return; - } catch (Exception $e) { - PrestaShopLogger::addLog("Mollie module error: {$e->getMessage()}"); - return; - } - } - - public function hookActionEmailSendBefore($params) - { - if ($params['template'] === 'order_conf' || - $params['template'] === 'account' || - $params['template'] === 'backoffice_order' || - $params['template'] === 'contact_form' || - $params['template'] === 'credit_slip' || - $params['template'] === 'in_transit' || - $params['template'] === 'order_changed' || - $params['template'] === 'order_merchant_comment' || - $params['template'] === 'order_return_state' || - $params['template'] === 'cheque' || - $params['template'] === 'payment' || - $params['template'] === 'preparation' || - $params['template'] === 'shipped' || - $params['template'] === 'order_canceled' || - $params['template'] === 'payment_error' || - $params['template'] === 'outofstock' || - $params['template'] === 'bankwire' || - $params['template'] === 'refund') { - if (!isset($params['cart']->id)) { - return; - } - $order = Order::getByCartId($params['cart']->id); - $orderFee = new MolOrderFee($order->id); - if ($orderFee->order_fee) { - $params['templateVars']['{payment_fee}'] = Tools::displayPrice($orderFee->order_fee); - } else { - $params['templateVars']['{payment_fee}'] = Tools::displayPrice(0); - } - } - } - - public function hookDisplayPDFInvoice($params) - { - if ($params['object'] instanceof OrderInvoice) { - $order = $params['object']->getOrder(); - /** @var \Mollie\Repository\OrderFeeRepository $orderFeeRepo */ - $orderFeeRepo = $this->getContainer(\Mollie\Repository\OrderFeeRepository::class); - $orderFeeId = $orderFeeRepo->getOrderFeeIdByCartId(Cart::getCartIdByOrderId($order->id)); - - $orderFee = new MolOrderFee($orderFeeId); - - if (!$orderFee->order_fee) { - return; - } - - $this->context->smarty->assign( - [ - 'order_fee' => Tools::displayPrice($orderFee->order_fee) - ] - ); - - return $this->context->smarty->fetch( - $this->getLocalPath() . 'views/templates/admin/invoice_fee.tpl' - ); - } - - } - - private function setApiKey() - { - /** @var \Mollie\Service\ApiService $apiService */ - $apiService = $this->getContainer(\Mollie\Service\ApiService::class); - try { - $this->api = $apiService->setApiKey(Configuration::get(Mollie\Config\Config::MOLLIE_API_KEY), $this->version); - } catch (_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\IncompatiblePlatform $e) { - PrestaShopLogger::addLog(__METHOD__ . ' - System incompatible: ' . $e->getMessage(), Mollie\Config\Config::CRASH); - } catch (_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - $this->warning = $this->l('Payment error:') . $e->getMessage(); - PrestaShopLogger::addLog(__METHOD__ . ' said: ' . $this->warning, Mollie\Config\Config::CRASH); - } - } + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ +if (!include_once(dirname(__FILE__) . '/vendor/autoload.php')) { + return; +} +/** + * Class Mollie + * + * // Translation detection: + * $this->l('Shipping); + * $this->l('Gift wrapping'); + */ +class Mollie extends PaymentModule +{ + /** + * Symfony DI Container + **/ + private $moduleContainer; + + const DISABLE_CACHE = true; + /** @var _PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient|null */ + public $api = null; + /** @var string $currentOrderReference */ + public $currentOrderReference; + /** @var string $selectedApi */ + public static $selectedApi; + /** @var bool $cacheCleared Indicates whether the Smarty cache has been cleared during updates */ + public static $cacheCleared; + + // The Addons version does not include the GitHub updater + const ADDONS = false; + + const SUPPORTED_PHP_VERSION = '5.6'; + /** + * Mollie constructor. + * + * @throws ErrorException + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ + public function __construct() + { + $this->name = 'mollie'; + $this->tab = 'payments_gateways'; + $this->version = '4.0.0'; + $this->author = 'Mollie B.V.'; + $this->need_instance = 1; + $this->bootstrap = true; + $this->module_key = 'a48b2f8918358bcbe6436414f48d8915'; + + parent::__construct(); + $this->ps_versions_compliancy = array('min' => '1.6.1.0', 'max' => _PS_VERSION_); + $this->displayName = $this->l('Mollie'); + $this->description = $this->l('Mollie Payments'); + + if (version_compare(phpversion(), $this::SUPPORTED_PHP_VERSION) === -1) { + return; + } + + $this->compile(); + $this->setApiKey(); + } + + /** + * Installs the Mollie Payments Module + * + * @return bool + */ + public function install() + { + if (version_compare(phpversion(), Mollie\Config\Config::SUPPORTED_PHP_VERSION) === -1) { + $this->_errors[] = $this->l('Dear customer, your PHP version is too low. Please upgrade your PHP version to use this module. Mollie module supports PHP 5.6 and higher versions.'); + return false; + } + + if (!parent::install()) { + $this->_errors[] = $this->l('Unable to install module'); + + return false; + } + + /** @var \Mollie\Install\Installer $installer */ + $installer = $this->getContainer(\Mollie\Install\Installer::class); + if (!$installer->install()) { + $this->_errors = array_merge($this->_errors, $installer->getErrors()); + return false; + } + + + return true; + } + + /** + * @return bool + * + */ + public function uninstall() + { + /** @var \Mollie\Install\Uninstall $uninstall */ + $uninstall = $this->getContainer(\Mollie\Install\Uninstall::class); + if (!$uninstall->uninstall()) { + $this->_errors[] = $uninstall->getErrors(); + return false; + } + + return parent::uninstall(); + } + + private function compile() + { + $containerCache = $this->getLocalPath() . 'var/cache/container.php'; + + try { + $containerConfigCache = new _PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($containerCache, self::DISABLE_CACHE); + } catch (Exception $e) { + $this->getContainer()->get('prestashop.core.cache.clearer.cache_clearer_chain')->clear(); + $containerConfigCache = new _PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($containerCache, self::DISABLE_CACHE); + } + $containerClass = get_class($this) . 'Container'; + if (!$containerConfigCache->isFresh()) { + $containerBuilder = new _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $locator = new _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator($this->getLocalPath() . 'config'); + $loader = new _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($containerBuilder, $locator); + $loader->load('config.yml'); + $containerBuilder->compile(); + $dumper = new _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($containerBuilder); + $containerConfigCache->write( + $dumper->dump(['class' => $containerClass]), + $containerBuilder->getResources() + ); + } + require_once $containerCache; + $this->moduleContainer = new $containerClass(); + } + + /** + * @param bool $id + * @return mixed + */ + public function getContainer($id = false) + { + if ($id) { + return $this->moduleContainer->get($id); + } + + return $this->moduleContainer; + } + + /** + * @return mixed + */ + public function getErrors() + { + return $this->_errors; + } + + public function getTable() + { + return $this->table; + } + + public function getContext() + { + return $this->context; + } + public function getIdentifier() + { + return $this->identifier; + } + + /** + * @return string + * + * @throws Exception + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws SmartyException + */ + public function getContent() + { + if (Tools::getValue('ajax')) { + header('Content-Type: application/json;charset=UTF-8'); + + if (!method_exists($this, 'displayAjax' . Tools::ucfirst(Tools::getValue('action')))) { + die(json_encode([ + 'success' => false, + ])); + } + die(json_encode($this->{'displayAjax' . Tools::ucfirst(Tools::getValue('action'))}())); + } + /** @var \Mollie\Repository\ModuleRepository $moduleRepository */ + $moduleRepository = $this->getContainer(\Mollie\Repository\ModuleRepository::class); + $moduleDatabaseVersion = $moduleRepository->getModuleDatabaseVersion($this->name); + if ($moduleDatabaseVersion < $this->version) { + $this->context->controller->errors[] = $this->l('Please upgrade Mollie module.'); + return; + } + /** @var \Mollie\Builder\FormBuilder $settingsFormBuilder */ + $settingsFormBuilder = $this->getContainer(\Mollie\Builder\FormBuilder::class); + if (!Configuration::get('PS_SMARTY_FORCE_COMPILE')) { + $this->context->smarty->assign([ + 'settingKey' => $this->l('Template compilation'), + 'settingValue' => $this->l('Never recompile template files'), + 'settingsPage' => \Mollie\Utility\MenuLocationUtility::getMenuLocation('AdminPerformance'), + ]); + $this->context->controller->warnings[] = $this->display(__FILE__, 'smarty_warning.tpl'); + } + if (Configuration::get('PS_SMARTY_CACHE') && Configuration::get('PS_SMARTY_CLEAR_CACHE') === 'never') { + $this->context->smarty->assign([ + 'settingKey' => $this->l('Clear cache'), + 'settingValue' => $this->l('Never clear cache files'), + 'settingsPage' => \Mollie\Utility\MenuLocationUtility::getMenuLocation('AdminPerformance'), + ]); + $this->context->controller->errors[] = $this->display(__FILE__, 'smarty_error.tpl'); + } + if (\Mollie\Utility\CartPriceUtility::checkRoundingMode()) { + $this->context->smarty->assign([ + 'settingKey' => $this->l('Rounding mode'), + 'settingValue' => $this->l('Round up away from zero, when it is half way there (recommended)'), + 'settingsPage' => \Mollie\Utility\MenuLocationUtility::getMenuLocation('AdminPreferences'), + ]); + $this->context->controller->errors[] = $this->display(__FILE__, 'rounding_error.tpl'); + } + + $this->context->smarty->assign([ + 'link' => Context::getContext()->link, + 'module_dir' => __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/', + 'publicPath' => __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/views/js/dist/', + ]); + + $resultMessage = ''; + $warningMessage = ''; + + $errors = []; + + if (Tools::isSubmit("submit{$this->name}")) { + /** @var \Mollie\Service\SettingsSaveService $saveSettingsService */ + $saveSettingsService = $this->getContainer(\Mollie\Service\SettingsSaveService::class); + $resultMessage = $saveSettingsService->saveSettings($errors); + if (!empty($errors)) { + $this->context->controller->errors = $resultMessage; + } else { + $this->context->controller->confirmations[] = $resultMessage; + } + } + /** @var Mollie\Service\LanguageService $langService */ + $langService = $this->getContainer(Mollie\Service\LanguageService::class); + $data = [ + 'title_status' => $this->l('%s statuses:'), + 'title_visual' => $this->l('Visual settings:'), + 'title_debug' => $this->l('Debug info:'), + 'msg_result' => $resultMessage, + 'msg_warning' => $warningMessage, + 'path' => $this->_path, + 'val_api_key' => Configuration::get(Mollie\Config\Config::MOLLIE_API_KEY), + 'payscreen_locale_value' => Configuration::get(Mollie\Config\Config::MOLLIE_PAYMENTSCREEN_LOCALE), + 'val_images' => Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES), + 'val_issuers' => Configuration::get(Mollie\Config\Config::MOLLIE_ISSUERS), + 'val_css' => Configuration::get(Mollie\Config\Config::MOLLIE_CSS), + 'val_errors' => Configuration::get(Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS), + 'val_qrenabled' => Configuration::get(Mollie\Config\Config::MOLLIE_QRENABLED), + 'val_logger' => Configuration::get(Mollie\Config\Config::MOLLIE_DEBUG_LOG), + 'val_save' => $this->l('Save'), + 'lang' => $langService->getLang(), + 'logo_url' => $this->getPathUri() . 'views/img/mollie_logo.png', + 'webpack_urls' => \Mollie\Utility\UrlPathUtility::getWebpackChunks('app'), + 'description_message' => $this->l('Description cannot be empty'), + 'Profile_id_message' => $this->l('Wrong profile ID') + ]; + + Media::addJsDef([ + 'description_message' => $this->l('Description cannot be empty'), + 'profile_id_message' => $this->l('Wrong profile ID'), + 'profile_id_message_empty' => $this->l('Profile ID cannot be empty'), + 'payment_api' => Mollie\Config\Config::MOLLIE_PAYMENTS_API, + ]); + $this->context->controller->addJS($this->getPathUri() . 'views/js/method_countries.js'); + $this->context->controller->addJS($this->getPathUri() . 'views/js/validation.js'); + $this->context->controller->addJS($this->getPathUri() . 'views/js/admin/settings.js'); + $this->context->controller->addCSS($this->getPathUri() . 'views/css/mollie.css'); + $this->context->smarty->assign($data); + + $html = ''; + $html .= $this->display(__FILE__, 'views/templates/admin/logo.tpl'); + + + try { + $html .= $settingsFormBuilder->buildSettingsForm(); + } catch (PrestaShopDatabaseException $e) { + $this->context->controller->errors[] = $this->l('You are missing database tables. Try resetting module.'); + } + + return $html; + } + + /** + * @param string $str + * + * @return string + */ + public function lang($str) + { + /** @var Mollie\Service\LanguageService $langService */ + $langService = $this->getContainer(Mollie\Service\LanguageService::class); + $lang = $langService->getLang(); + if (array_key_exists($str, $lang)) { + return $lang[$str]; + } + + return $str; + } + + /** + * @param string $url + * + * @return string|true + * @throws Exception + * @throws PrestaShopException + * @throws SmartyException + */ + protected function getUpdateMessage($url) + { + $updateMessage = ''; + $updateXml = $this->getUpdateXML($url); + if ($updateXml === false) { + $updateMessage = $this->l('Warning: Could not retrieve update xml file from github.'); + } else { + try { + /** @var SimpleXMLElement $tags */ + @$tags = new SimpleXMLElement($updateXml); + if (!empty($tags) && isset($tags->entry, $tags->entry[0], $tags->entry[0]->id)) { + $title = $tags->entry[0]->id; + $latestVersion = preg_replace("/[^0-9,.]/", '', Tools::substr($title, strrpos($title, '/'))); + if (!version_compare($this->version, $latestVersion, '>=')) { + $this->context->smarty->assign([ + 'this_version' => $this->version, + 'release_version' => $latestVersion, + ]); + $updateMessage = 'updateAvailable'; + } + } else { + $updateMessage = $this->l('Warning: Update xml file from github follows an unexpected format.'); + } + } catch (Exception $e) { + $updateMessage = $this->l('Warning: Update xml file from github follows an unexpected format.'); + } + } + + return $updateMessage; + } + + /** + * @param string $url + * + * @return string + */ + protected function getUpdateXML($url) + { + if (static::ADDONS) { + return ''; + } + + return @Tools::file_get_contents($url . '/releases.atom'); + } + + /** + * @throws PrestaShopException + */ + public function hookActionFrontControllerSetMedia() + { + $isOrderController = $this->context->controller instanceof OrderControllerCore; + $isOPCController = $this->context->controller instanceof OrderOpcControllerCore; + if ($isOrderController || $isOPCController) { + + Media::addJsDef([ + 'profileId' => Configuration::get(Mollie\Config\Config::MOLLIE_PROFILE_ID), + 'isoCode' => $this->context->language->language_code, + 'isTestMode' => \Mollie\Config\Config::isTestMode() + ]); + if (\Mollie\Config\Config::isVersion17()) { + $this->context->controller->registerJavascript( + 'mollie_iframe_js', + 'https://js.mollie.com/v1/mollie.js', + ['server' => 'remote', 'position' => 'bottom', 'priority' => 150] + ); + $this->context->controller->addJS("{$this->_path}views/js/front/mollie_iframe.js"); + } else { + $this->context->controller->addMedia('https://js.mollie.com/v1/mollie.js', null, null, false, false); + $this->context->controller->addJS("{$this->_path}views/js/front/mollie_iframe_16.js"); + } + Media::addJsDef([ + 'ajaxUrl' => $this->context->link->getModuleLink('mollie', 'ajax'), + 'isPS17' => \Mollie\Config\Config::isVersion17(), + ]); + $this->context->controller->addJS("{$this->_path}views/js/front/mollie_error_handle.js"); + $this->context->controller->addCSS("{$this->_path}views/css/mollie_iframe.css"); + if (Configuration::get('PS_SSL_ENABLED_EVERYWHERE')) { + $this->context->controller->addJS($this->getPathUri() . 'views/js/apple_payment.js'); + } + $this->context->smarty->assign([ + 'custom_css' => Configuration::get(Mollie\Config\Config::MOLLIE_CSS), + ]); + + $this->context->controller->addJS("{$this->_path}views/js/front/payment_fee.js"); + + return $this->display(__FILE__, 'views/templates/front/custom_css.tpl'); + } + } + + /** + * @throws PrestaShopException + * @throws SmartyException + */ + public function hookDisplayBackOfficeHeader() + { + $html = ''; + + if ($this->context->controller instanceof AdminOrdersController) { + $this->context->smarty->assign([ + 'mollieProcessUrl' => $this->context->link->getAdminLink('AdminModules', true) . '&configure=mollie&ajax=1', + 'mollieCheckMethods' => time() > ((int)Configuration::get(Mollie\Config\Config::MOLLIE_METHODS_LAST_CHECK) + Mollie\Config\Config::MOLLIE_METHODS_CHECK_INTERVAL), + ]); + $html .= $this->display(__FILE__, 'views/templates/admin/ordergrid.tpl'); + } + + return $html; + } + + /** + * @param array $params Hook parameters + * + * @return string Hook HTML + * + * @throws Adapter_Exception + * @throws Exception + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws SmartyException + */ + public function hookDisplayAdminOrder($params) + { + /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ + /** @var \Mollie\Service\ShipmentService $shipmentService */ + $paymentMethodRepo = $this->getContainer(\Mollie\Repository\PaymentMethodRepository::class); + $shipmentService = $this->getContainer(\Mollie\Service\ShipmentService::class); + + $cartId = Cart::getCartIdByOrderId((int)$params['id_order']); + $transaction = $paymentMethodRepo->getPaymentBy('cart_id', (int)$cartId); + if (empty($transaction)) { + return false; + } + $currencies = []; + foreach (Currency::getCurrencies() as $currency) { + $currencies[Tools::strtoupper($currency['iso_code'])] = [ + 'name' => $currency['name'], + 'iso_code' => Tools::strtoupper($currency['iso_code']), + 'sign' => $currency['sign'], + 'blank' => (bool)isset($currency['blank']) ? $currency['blank'] : true, + 'format' => (int)$currency['format'], + 'decimals' => (bool)isset($currency['decimals']) ? $currency['decimals'] : true, + ]; + } + + $order = new Order($params['id_order']); + $this->context->smarty->assign([ + 'ajaxEndpoint' => $this->context->link->getAdminLink('AdminModules', true) . '&configure=mollie&ajax=1&action=MollieOrderInfo', + 'transactionId' => $transaction['transaction_id'], + 'currencies' => $currencies, + 'tracking' => $shipmentService->getShipmentInformation($order->reference), + 'publicPath' => __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/views/js/dist/', + 'webPackChunks' => \Mollie\Utility\UrlPathUtility::getWebpackChunks('app'), + 'errorDisplay' => Configuration::get(Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS) + ]); + + return $this->display(__FILE__, 'order_info.tpl'); + } + + /** + * @return string + * @throws Exception + * @throws PrestaShopException + * @throws SmartyException + */ + public function hookDisplayPayment() + { + $smarty = $this->context->smarty; + $issuerSetting = Configuration::get(Mollie\Config\Config::MOLLIE_ISSUERS); + + /** @var \Mollie\Service\PaymentMethodService $paymentMethodService */ + /** @var \Mollie\Service\IssuerService $issuerService */ + /** @var \Mollie\Service\OrderFeeService $orderFeeService */ + $paymentMethodService = $this->getContainer(\Mollie\Service\PaymentMethodService::class); + $issuerService = $this->getContainer(\Mollie\Service\IssuerService::class); + $orderFeeService = $this->getContainer(\Mollie\Service\OrderFeeService::class); + + $apiMethods = $paymentMethodService->getMethodsForCheckout(); + $issuerList = []; + foreach ($apiMethods as $apiMethod) { + if ($apiMethod['id_payment_method'] === _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL) { + $issuerList = $issuerService->getIdealIssuers(); + } + } + $apiMethods = $orderFeeService->getPaymentFees($apiMethods, $this->context->cart->getOrderTotal()); + + $isIFrameEnabled = Configuration::get(Mollie\Config\Config::MOLLIE_IFRAME); + /** @var Cart $cart */ + $cart = Context::getContext()->cart; + $smarty->assign([ + 'mollieIframe' => $isIFrameEnabled, + 'link' => $this->context->link, + 'cartAmount' => (int)($cart->getOrderTotal(true) * 100), + 'methods' => $apiMethods, + 'issuers' => $issuerList, + 'issuer_setting' => $issuerSetting, + 'images' => Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES), + 'warning' => $this->warning, + 'msg_pay_with' => $this->l('Pay with %s'), + 'msg_bankselect' => $this->l('Select your bank:'), + 'module' => $this, + 'publicPath' => __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/views/js/dist/', + 'IsQREnabled' => Mollie\Config\Config::MOLLIE_QRENABLED, + 'CARTES_BANCAIRES' => Mollie\Config\Config::CARTES_BANCAIRES, + 'ISSUERS_ON_CLICK' => Mollie\Config\Config::ISSUERS_ON_CLICK, + 'web_pack_chunks' => Mollie\Utility\UrlPathUtility::getWebpackChunks('app'), + 'display_errors' => Mollie\Config\Config::MOLLIE_DISPLAY_ERRORS, + 'mollie_translations' => [ + 'chooseYourBank' => $this->l('Choose your bank'), + 'orPayByIdealQr' => $this->l('or pay by iDEAL QR'), + 'choose' => $this->l('Choose'), + 'cancel' => $this->l('Cancel'), + ], + ]); + + $iframeDisplay = ''; + if (!\Mollie\Config\Config::isVersion17() && $isIFrameEnabled) { + $iframeDisplay = $this->display(__FILE__, 'mollie_iframe_16.tpl'); + } + return $this->display(__FILE__, 'addjsdef.tpl') . $this->display(__FILE__, 'payment.tpl') . $iframeDisplay; + } + + /** + * EU Advanced Compliance module (PrestaShop module) Advanced Checkout option enabled + * + * @return array|null + * + * @throws PrestaShopException + */ + public function hookDisplayPaymentEU() + { + // Please update your one page checkout module if it depends on `displayPaymentEU` + // Mollie does no longer support this hook on PresaShop v1.7 or higher + // due to the problems caused by mixing the hooks `paymentOptions` and `displayPaymentEU` + // Only uncomment the following three lines if you have no other choice: + if (version_compare(_PS_VERSION_, '1.7.0.0', '>=')) { + return []; + } + /** @var \Mollie\Service\PaymentMethodService $paymentMethodService */ + /** @var \Mollie\Service\IssuerService $issuerService */ + $paymentMethodService = $this->getContainer(\Mollie\Service\PaymentMethodService::class); + $issuerService = $this->getContainer(\Mollie\Service\IssuerService::class); + + $methods = $paymentMethodService->getMethodsForCheckout(); + $issuerList = []; + foreach ($methods as $apiMethod) { + if ($apiMethod['id'] === _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL) { + $issuerList = $issuerService->getIdealIssuers(); + } + } + + $context = Context::getContext(); + $iso = Tools::strtolower($context->currency->iso_code); + $paymentOptions = []; + + foreach ($methods as $method) { + if (!isset(Mollie\Config\Config::$methodCurrencies[$method['id']])) { + continue; + } + if (!in_array($iso, Mollie\Config\Config::$methodCurrencies[$method['id']])) { + continue; + } + + $paymentOptions[] = [ + 'cta_text' => $this->lang($method['name']), + 'logo' => Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES) === Mollie\Config\Config::LOGOS_NORMAL + ? $method['image']['size1x'] + : $method['image']['size2x'], + 'action' => $this->context->link->getModuleLink( + 'mollie', + 'payment', + ['method' => $method['id'], 'rand' => time()], + true + ), + ]; + } + + return $paymentOptions; + } + + /** + * @param array $params + * + * @return array|null + * @throws Exception + * @throws PrestaShopException + * @throws SmartyException + */ + public function hookPaymentOptions() + { + if (version_compare(_PS_VERSION_, '1.7.0.0', '<')) { + return []; + } + /** @var \Mollie\Service\PaymentMethodService $paymentMethodService */ + /** @var \Mollie\Service\IssuerService $issuerService */ + $paymentMethodService = $this->getContainer(\Mollie\Service\PaymentMethodService::class); + $issuerService = $this->getContainer(\Mollie\Service\IssuerService::class); + + $methodIds = $paymentMethodService->getMethodsForCheckout(); + $issuerList = []; + foreach ($methodIds as $methodId) { + $methodObj = new MolPaymentMethod($methodId['id_payment_method']); + if ($methodObj->id_method === _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL) { + $issuerList = $issuerService->getIdealIssuers(); + } + } + + $context = Context::getContext(); + $cart = $context->cart; + + $context->smarty->assign([ + 'idealIssuers' => isset($issuerList[_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL]) + ? $issuerList[_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL] + : [], + 'link' => $this->context->link, + 'qrCodeEnabled' => Configuration::get(Mollie\Config\Config::MOLLIE_QRENABLED), + 'qrAlign' => 'left', + 'cartAmount' => (int)($cart->getOrderTotal(true) * 100), + 'publicPath' => __PS_BASE_URI__ . 'modules/' . basename(__FILE__, '.php') . '/views/js/dist/', + ]); + + $iso = Tools::strtolower($context->currency->iso_code); + $paymentOptions = []; + foreach ($methodIds as $methodId) { + if (!isset(Mollie\Config\Config::$methodCurrencies[$methodObj->id_method])) { + continue; + } + if (!in_array($iso, Mollie\Config\Config::$methodCurrencies[$methodObj->id_method])) { + continue; + } + + $methodObj = new MolPaymentMethod($methodId['id_payment_method']); + $paymentFee = \Mollie\Utility\PaymentFeeUtility::getPaymentFee($methodObj, $cart->getOrderTotal()); + + $isIdealMethod = $methodObj->id_method === _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL; + $isIssuersOnClick = Configuration::get(Mollie\Config\Config::MOLLIE_ISSUERS) === Mollie\Config\Config::ISSUERS_ON_CLICK; + $isCreditCardMethod = $methodObj->id_method === _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::CREDITCARD; + + if ($isIdealMethod && $isIssuersOnClick) { + $newOption = new PrestaShop\PrestaShop\Core\Payment\PaymentOption(); + $newOption + ->setCallToActionText($this->lang($methodObj->method_name)) + ->setModuleName($this->name) + ->setAction(Context::getContext()->link->getModuleLink( + $this->name, + 'payment', + ['method' => $methodObj->id_method, 'rand' => time()], + true + )) + ->setInputs([ + 'token' => [ + 'name' => 'issuer', + 'type' => 'hidden', + 'value' => '', + ], + ]) + ->setAdditionalInformation($this->display(__FILE__, 'ideal_dropdown.tpl')); + + $imageConfig = Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES); + $image = json_decode($methodObj->images_json, true); + $image = \Mollie\Utility\ImageUtility::setOptionImage($image, $imageConfig); + $newOption->setLogo($image); + + if ($paymentFee) { + $newOption->setInputs( + [ + [ + 'type' => 'hidden', + 'name' => "payment-fee-price", + 'value' => $paymentFee + ], + [ + 'type' => 'hidden', + 'name' => "payment-fee-price-display", + 'value' => sprintf($this->l('Payment Fee: %1s'), Tools::displayPrice($paymentFee)) + ], + ] + ); + } + + $paymentOptions[] = $newOption; + } elseif ( + ($isCreditCardMethod || $methodObj->id_method === \Mollie\Config\Config::CARTES_BANCAIRES) && + Configuration::get(Mollie\Config\Config::MOLLIE_IFRAME) + ) { + $this->context->smarty->assign([ + 'mollieIFrameJS' => 'https://js.mollie.com/v1/mollie.js', + 'price' => $this->context->cart->getOrderTotal(), + 'priceSign' => $this->context->currency->getSign(), + 'methodId' => $methodObj->id_method + ]); + $newOption = new PrestaShop\PrestaShop\Core\Payment\PaymentOption(); + $newOption + ->setCallToActionText($this->lang($methodObj->method_name)) + ->setModuleName($this->name) + ->setAdditionalInformation($this->display(__FILE__, 'mollie_iframe.tpl')) + ->setInputs( + [ + [ + 'type' => 'hidden', + 'name' => "mollieCardToken{$methodObj->id_method}", + 'value' => '' + ] + ] + ) + ->setAction(Context::getContext()->link->getModuleLink( + 'mollie', + 'payScreen', + ['method' => $methodObj->id_method, 'rand' => time(), 'cardToken' => ''], + true + )); + + $imageConfig = Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES); + $image = json_decode($methodObj->images_json, true); + $image = \Mollie\Utility\ImageUtility::setOptionImage($image, $imageConfig); + $newOption->setLogo($image); + + if ($paymentFee) { + $newOption->setInputs( + [ + [ + 'type' => 'hidden', + 'name' => "mollieCardToken{$methodObj->id_method}", + 'value' => '' + ], + [ + 'type' => 'hidden', + 'name' => "payment-fee-price", + 'value' => $paymentFee + ], + [ + 'type' => 'hidden', + 'name' => "payment-fee-price-display", + 'value' => sprintf($this->l('Payment Fee: %1s'), Tools::displayPrice($paymentFee)) + ], + ] + ); + } else { + $newOption->setInputs( + [ + [ + 'type' => 'hidden', + 'name' => "mollieCardToken{$methodObj->id_method}", + 'value' => '' + ], + ] + ); + } + + $paymentOptions[] = $newOption; + } else { + $newOption = new PrestaShop\PrestaShop\Core\Payment\PaymentOption(); + $newOption + ->setCallToActionText($this->lang($methodObj->method_name)) + ->setModuleName($this->name) + ->setAction(Context::getContext()->link->getModuleLink( + 'mollie', + 'payment', + ['method' => $methodObj->id_method, 'rand' => time()], + true + )); + + $imageConfig = Configuration::get(Mollie\Config\Config::MOLLIE_IMAGES); + $image = json_decode($methodObj->images_json, true); + $image = \Mollie\Utility\ImageUtility::setOptionImage($image, $imageConfig); + $newOption->setLogo($image); + + if ($paymentFee) { + $newOption->setInputs( + [ + [ + 'type' => 'hidden', + 'name' => "payment-fee-price", + 'value' => $paymentFee + ], + [ + 'type' => 'hidden', + 'name' => "payment-fee-price-display", + 'value' => sprintf($this->l('Payment Fee: %1s'), Tools::displayPrice($paymentFee)) + ], + ] + ); + } + + $paymentOptions[] = $newOption; + } + } + + return $paymentOptions; + } + + /** + * @return string + * + * @throws Exception + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws SmartyException + */ + public function hookDisplayOrderConfirmation() + { + /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->getContainer(\Mollie\Repository\PaymentMethodRepository::class); + $payment = $paymentMethodRepo->getPaymentBy('cart_id', (int)Tools::getValue('id_cart')); + if ($payment && $payment['bank_status'] == _PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_PAID) { + $this->context->smarty->assign('okMessage', $this->l('Thank you. Your payment has been received.')); + + return $this->display(__FILE__, 'ok.tpl'); + } + + return ''; + } + + /** + * @return array + * @throws PrestaShopException + * + * @since 3.3.0 + */ + public function displayAjaxMollieMethodConfig() + { + header('Content-Type: application/json;charset=UTF-8'); + /** @var \Mollie\Service\ApiService $apiService */ + $apiService = $this->getContainer(\Mollie\Service\ApiService::class); + /** @var \Mollie\Service\CountryService $countryService */ + $countryService = $this->getContainer(\Mollie\Service\CountryService::class); + try { + + $methodsForConfig = $apiService->getMethodsForConfig($this->api, $this->getPathUri()); + } catch (_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + return [ + 'success' => false, + 'methods' => null, + 'message' => $e->getMessage(), + ]; + } catch (PrestaShopException $e) { + return [ + 'success' => false, + 'methods' => null, + 'message' => $e->getMessage(), + ]; + } + Configuration::updateValue(Mollie\Config\Config::MOLLIE_METHODS_LAST_CHECK, time()); + if (!is_array($methodsForConfig)) { + return [ + 'success' => false, + 'methods' => null, + 'message' => $this->l('No payment methods found'), + ]; + } + + $dbMethods = @json_decode(Configuration::get(Mollie\Config\Config::METHODS_CONFIG), true); + + // Auto update images and issuers + $shouldSave = false; + if (is_array($dbMethods)) { + foreach ($dbMethods as $index => &$dbMethod) { + $found = false; + foreach ($methodsForConfig as $methodForConfig) { + if ($dbMethod['id'] === $methodForConfig['id']) { + $found = true; + foreach (['issuers', 'image', 'name', 'available'] as $prop) { + if (isset($methodForConfig[$prop])) { + $dbMethod[$prop] = $methodForConfig[$prop]; + $shouldSave = true; + } + } + break; + } + } + if (!$found) { + unset($dbMethods[$index]); + $shouldSave = true; + } + } + } else { + $shouldSave = true; + $dbMethods = []; + foreach ($methodsForConfig as $index => $method) { + $dbMethods[] = array_merge( + $method, + [ + 'position' => $index, + ] + ); + } + } + + if ($shouldSave && !empty($dbMethods)) { + Configuration::updateValue(Mollie\Config\Config::METHODS_CONFIG, json_encode($dbMethods)); + } + + return [ + 'success' => true, + 'methods' => $methodsForConfig, + 'countries' => $countryService->getActiveCountriesList(), + ]; + } + + /** + * @return array + * @throws Adapter_Exception + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * + * @since 3.3.0 + */ + public function displayAjaxMollieOrderInfo() + { + header('Content-Type: application/json;charset=UTF-8'); + + /** @var \Mollie\Service\MollieOrderInfoService $orderInfoService */ + $orderInfoService = $this->getContainer(\Mollie\Service\MollieOrderInfoService::class); + + $input = @json_decode(Tools::file_get_contents('php://input'), true); + $adminOrdersController = new AdminOrdersController(); + return $orderInfoService->displayMollieOrderInfo($input, $adminOrdersController->id); + } + + /** + * actionOrderStatusUpdate hook + * + * @param array $params + * + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + * @throws Adapter_Exception + * + * @since 3.3.0 + */ + public function hookActionOrderStatusUpdate($params = []) + { + if (!isset($params['newOrderStatus']) || !isset($params['id_order'])) { + return; + } + + if ($params['newOrderStatus'] instanceof OrderState) { + $orderStatus = $params['newOrderStatus']; + } elseif (is_int($params['newOrderStatus']) || is_string($params['newOrderStatus'])) { + $orderStatus = new OrderState($params['newOrderStatus']); + } + if (isset($orderStatus) + && $orderStatus instanceof OrderState + && Validate::isLoadedObject($orderStatus) + ) { + $orderStatusNumber = $orderStatus->id; + } else { + return; + } + + $idOrder = $params['id_order']; + $order = new Order($idOrder); + $checkStatuses = []; + if (Configuration::get(Mollie\Config\Config::MOLLIE_AUTO_SHIP_STATUSES)) { + $checkStatuses = @json_decode(Configuration::get(Mollie\Config\Config::MOLLIE_AUTO_SHIP_STATUSES)); + } + if (!is_array($checkStatuses)) { + $checkStatuses = []; + } + + /** @var \Mollie\Service\ShipmentService $shipmentService */ + $shipmentService = $this->getContainer(\Mollie\Service\ShipmentService::class); + $shipmentInfo = $shipmentService->getShipmentInformation($order->reference); + + if (!(Configuration::get(Mollie\Config\Config::MOLLIE_AUTO_SHIP_MAIN) && in_array($orderStatusNumber, $checkStatuses) + ) || $shipmentInfo === null + ) { + return; + } + + try { + /** @var \Mollie\Repository\PaymentMethodRepository $paymentMethodRepo */ + $paymentMethodRepo = $this->getContainer(\Mollie\Repository\PaymentMethodRepository::class); + $dbPayment = $paymentMethodRepo->getPaymentBy('order_id', (int)$idOrder); + } catch (PrestaShopDatabaseException $e) { + PrestaShopLogger::addLog("Mollie module error: {$e->getMessage()}"); + return; + } catch (PrestaShopException $e) { + PrestaShopLogger::addLog("Mollie module error: {$e->getMessage()}"); + return; + } + if (empty($dbPayment) || !isset($dbPayment['transaction_id'])) { + // No transaction found + return; + } + + $length = Tools::strlen(_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderEndpoint::RESOURCE_ID_PREFIX); + if (Tools::substr($dbPayment['transaction_id'], 0, $length) !== _PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderEndpoint::RESOURCE_ID_PREFIX + ) { + // No need to check regular payments + return; + } + + try { + $apiOrder = $this->api->orders->get($dbPayment['transaction_id']); + $shippableItems = 0; + foreach ($apiOrder->lines as $line) { + $shippableItems += $line->shippableQuantity; + } + if ($shippableItems <= 0) { + return; + } + + $apiOrder->shipAll($shipmentInfo); + } catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + PrestaShopLogger::addLog("Mollie module error: {$e->getMessage()}"); + return; + } catch (Exception $e) { + PrestaShopLogger::addLog("Mollie module error: {$e->getMessage()}"); + return; + } + } + + public function hookActionEmailSendBefore($params) + { + if ($params['template'] === 'order_conf' || + $params['template'] === 'account' || + $params['template'] === 'backoffice_order' || + $params['template'] === 'contact_form' || + $params['template'] === 'credit_slip' || + $params['template'] === 'in_transit' || + $params['template'] === 'order_changed' || + $params['template'] === 'order_merchant_comment' || + $params['template'] === 'order_return_state' || + $params['template'] === 'cheque' || + $params['template'] === 'payment' || + $params['template'] === 'preparation' || + $params['template'] === 'shipped' || + $params['template'] === 'order_canceled' || + $params['template'] === 'payment_error' || + $params['template'] === 'outofstock' || + $params['template'] === 'bankwire' || + $params['template'] === 'refund') { + if (!isset($params['cart']->id)) { + return; + } + $order = Order::getByCartId($params['cart']->id); + $orderFee = new MolOrderFee($order->id); + if ($orderFee->order_fee) { + $params['templateVars']['{payment_fee}'] = Tools::displayPrice($orderFee->order_fee); + } else { + $params['templateVars']['{payment_fee}'] = Tools::displayPrice(0); + } + } + } + + public function hookDisplayPDFInvoice($params) + { + if ($params['object'] instanceof OrderInvoice) { + $order = $params['object']->getOrder(); + /** @var \Mollie\Repository\OrderFeeRepository $orderFeeRepo */ + $orderFeeRepo = $this->getContainer(\Mollie\Repository\OrderFeeRepository::class); + $orderFeeId = $orderFeeRepo->getOrderFeeIdByCartId(Cart::getCartIdByOrderId($order->id)); + + $orderFee = new MolOrderFee($orderFeeId); + + if (!$orderFee->order_fee) { + return; + } + + $this->context->smarty->assign( + [ + 'order_fee' => Tools::displayPrice($orderFee->order_fee) + ] + ); + + return $this->context->smarty->fetch( + $this->getLocalPath() . 'views/templates/admin/invoice_fee.tpl' + ); + } + + } + + private function setApiKey() + { + /** @var \Mollie\Service\ApiService $apiService */ + $apiService = $this->getContainer(\Mollie\Service\ApiService::class); + try { + $this->api = $apiService->setApiKey(Configuration::get(Mollie\Config\Config::MOLLIE_API_KEY), $this->version); + } catch (_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\IncompatiblePlatform $e) { + PrestaShopLogger::addLog(__METHOD__ . ' - System incompatible: ' . $e->getMessage(), Mollie\Config\Config::CRASH); + } catch (_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + $this->warning = $this->l('Payment error:') . $e->getMessage(); + PrestaShopLogger::addLog(__METHOD__ . ' said: ' . $this->warning, Mollie\Config\Config::CRASH); + } + } } \ No newline at end of file diff --git a/node_modules/.yarn-integrity b/node_modules/.yarn-integrity index dea44209c..3a172f31e 100644 --- a/node_modules/.yarn-integrity +++ b/node_modules/.yarn-integrity @@ -1,10 +1,10 @@ -{ - "systemParams": "linux-x64-57", - "modulesFolders": [], - "flags": [], - "linkedModules": [], - "topLevelPatterns": [], - "lockfileEntries": {}, - "files": [], - "artifacts": {} +{ + "systemParams": "linux-x64-57", + "modulesFolders": [], + "flags": [], + "linkedModules": [], + "topLevelPatterns": [], + "lockfileEntries": {}, + "files": [], + "artifacts": {} } \ No newline at end of file diff --git a/node_modules/index.php b/node_modules/index.php index 729abf520..a950d02f4 100644 --- a/node_modules/index.php +++ b/node_modules/index.php @@ -1,11 +1,11 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -// Not available in Mollie's composer, but part of the php-scoper.phar package, you can safely ignore this missing import -use Isolated\Symfony\Component\Finder\Finder; - -return array( - // By default when running php-scoper add-prefix, it will prefix all relevant code found in the current working - // directory. You can however define which files should be scoped by defining a collection of Finders in the - // following configuration key. - // - // For more see: https://github.com/humbug/php-scoper#finders-and-paths - 'finders' => array( - Finder::create() - ->files() - ->ignoreVCS(true) - ->notName('/LICENSE|.*\\.md|.*\\.dist|Makefile|composer\\.json|composer\\.lock/') - ->exclude(array( - 'doc', - 'vendor-bin', - )) - ->in('pre-scoper'), - Finder::create()->append(array( - 'composer.json', - )), - ), - // When scoping PHP files, there will be scenarios where some of the code being scoped indirectly references the - // original namespace. These will include, for example, strings or string manipulations. PHP-Scoper has limited - // support for prefixing such strings. To circumvent that, you can define patchers to manipulate the file to your - // heart contents. - // - // For more see: https://github.com/humbug/php-scoper#patchers - 'patchers' => array( - function ($filePath, $prefix, $content) { - // Change the content here. vendor = pre-scoper at this time - $curlPath = dirname(__FILE__).'/pre-scoper/vendor/php-curl-class/php-curl-class/'; - if (Tools::substr($filePath, 0, strlen($curlPath)) === $curlPath) { - $content = preg_replace( - '~'.preg_quote("'\\\\Curl\\\\", '~').'~', - "'\\\\\\\\$prefix\\\\\\\\Curl\\\\\\\\", - $content - ); - $content = preg_replace( - '~'.preg_quote("\"\\\\Curl\\\\", '~').'~', - "\"\\\\\\\\$prefix\\\\\\\\Curl\\\\\\\\", - $content - ); - } - - $molliePath = dirname(__FILE__).'/pre-scoper/vendor/firstred/mollie-api-php/'; - if (Tools::substr($filePath, 0, strlen($molliePath)) === $molliePath) { - $content = preg_replace( - '~'.preg_quote("'Mollie\\\\Api\\\\", '~').'~', - "'$prefix\\\\\\\\Mollie\\\\\\\\Api\\\\\\\\", - $content - ); - $content = preg_replace( - '~'.preg_quote("\"Mollie\\\\Api\\\\", '~').'~', - "\"$prefix\\\\\\\\Mollie\\\\\\\\Api\\\\\\\\", - $content - ); - $content = preg_replace( - '~'.preg_quote("'\\\\Mollie\\\\Api\\\\", '~').'~', - "'\\\\\\\\$prefix\\\\\\\\Mollie\\\\\\\\Api\\\\\\\\", - $content - ); - $content = preg_replace( - '~'.preg_quote("\"\\\\\Mollie\\\\Api\\\\", '~').'~', - "\"\\\\\\\\$prefix\\\\\\\\Mollie\\\\\\\\Api\\\\\\\\", - $content - ); - } - - return $content; - }, - ), -); + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +// Not available in Mollie's composer, but part of the php-scoper.phar package, you can safely ignore this missing import +use Isolated\Symfony\Component\Finder\Finder; + +return array( + // By default when running php-scoper add-prefix, it will prefix all relevant code found in the current working + // directory. You can however define which files should be scoped by defining a collection of Finders in the + // following configuration key. + // + // For more see: https://github.com/humbug/php-scoper#finders-and-paths + 'finders' => array( + Finder::create() + ->files() + ->ignoreVCS(true) + ->notName('/LICENSE|.*\\.md|.*\\.dist|Makefile|composer\\.json|composer\\.lock/') + ->exclude(array( + 'doc', + 'vendor-bin', + )) + ->in('pre-scoper'), + Finder::create()->append(array( + 'composer.json', + )), + ), + // When scoping PHP files, there will be scenarios where some of the code being scoped indirectly references the + // original namespace. These will include, for example, strings or string manipulations. PHP-Scoper has limited + // support for prefixing such strings. To circumvent that, you can define patchers to manipulate the file to your + // heart contents. + // + // For more see: https://github.com/humbug/php-scoper#patchers + 'patchers' => array( + function ($filePath, $prefix, $content) { + // Change the content here. vendor = pre-scoper at this time + $curlPath = dirname(__FILE__).'/pre-scoper/vendor/php-curl-class/php-curl-class/'; + if (Tools::substr($filePath, 0, strlen($curlPath)) === $curlPath) { + $content = preg_replace( + '~'.preg_quote("'\\\\Curl\\\\", '~').'~', + "'\\\\\\\\$prefix\\\\\\\\Curl\\\\\\\\", + $content + ); + $content = preg_replace( + '~'.preg_quote("\"\\\\Curl\\\\", '~').'~', + "\"\\\\\\\\$prefix\\\\\\\\Curl\\\\\\\\", + $content + ); + } + + $molliePath = dirname(__FILE__).'/pre-scoper/vendor/firstred/mollie-api-php/'; + if (Tools::substr($filePath, 0, strlen($molliePath)) === $molliePath) { + $content = preg_replace( + '~'.preg_quote("'Mollie\\\\Api\\\\", '~').'~', + "'$prefix\\\\\\\\Mollie\\\\\\\\Api\\\\\\\\", + $content + ); + $content = preg_replace( + '~'.preg_quote("\"Mollie\\\\Api\\\\", '~').'~', + "\"$prefix\\\\\\\\Mollie\\\\\\\\Api\\\\\\\\", + $content + ); + $content = preg_replace( + '~'.preg_quote("'\\\\Mollie\\\\Api\\\\", '~').'~', + "'\\\\\\\\$prefix\\\\\\\\Mollie\\\\\\\\Api\\\\\\\\", + $content + ); + $content = preg_replace( + '~'.preg_quote("\"\\\\\Mollie\\\\Api\\\\", '~').'~', + "\"\\\\\\\\$prefix\\\\\\\\Mollie\\\\\\\\Api\\\\\\\\", + $content + ); + } + + return $content; + }, + ), +); diff --git a/sql/index.php b/sql/index.php index 94281b346..66e41d8ba 100644 --- a/sql/index.php +++ b/sql/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); -header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); - -header('Cache-Control: no-store, no-cache, must-revalidate'); -header('Cache-Control: post-check=0, pre-check=0', false); -header('Pragma: no-cache'); - -header('Location: ../'); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); +header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); + +header('Cache-Control: no-store, no-cache, must-revalidate'); +header('Cache-Control: post-check=0, pre-check=0', false); +header('Pragma: no-cache'); + +header('Location: ../'); +exit; diff --git a/sql/install.php b/sql/install.php index a9630a73b..a4386d61b 100644 --- a/sql/install.php +++ b/sql/install.php @@ -1,89 +1,89 @@ - - * @copyright 2007-2017 PrestaShop SA - * @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) - * International Registered Trademark & Property of PrestaShop SA - */ - -$sql = array(); - -$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mollie_payments` ( - `transaction_id` VARCHAR(64) NOT NULL PRIMARY KEY, - `cart_id` INT(64), - `order_id` INT(64), - `order_reference` VARCHAR(191), - `method` VARCHAR(128) NOT NULL, - `bank_status` VARCHAR(64) NOT NULL, - `created_at` DATETIME NOT NULL, - `updated_at` DATETIME DEFAULT NULL, - INDEX (cart_id) - ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; - -$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_country` ( - `id_mol_country` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, - `id_method` VARCHAR(64), - `id_country` INT(64), - `all_countries` tinyint - ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; - -$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_payment_method` ( - `id_payment_method` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, - `id_method` VARCHAR(64) NOT NULL, - `method_name` VARCHAR(64) NOT NULL, - `enabled` TINYINT(1), - `title` VARCHAR(64), - `method` VARCHAR(64), - `description` VARCHAR(255), - `is_countries_applicable` TINYINT(1), - `minimal_order_value` decimal(20,6), - `max_order_value` decimal(20,6), - `surcharge` INT(10), - `surcharge_fixed_amount` decimal(20,6), - `surcharge_percentage` decimal(20,6), - `surcharge_limit` decimal(20,6), - `images_json` TEXT - ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; - -$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_payment_method_issuer` ( - `id_payment_method_issuer` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, - `id_payment_method` INT(64) NOT NULL, - `issuers_json` TEXT NOT NULL - ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; - -$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_order_fee` ( - `id_mol_order_fee` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, - `id_cart` INT(64) NOT NULL, - `order_fee` decimal(20,6) NOT NULL - ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; - -$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_carrier_information` ( - `id_mol_carrier_information` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, - `id_carrier` INT(64) NOT NULL, - `url_source` VARCHAR(64) NOT NULL, - `custom_url` VARCHAR(255) - ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; - -foreach ($sql as $query) { - if (Db::getInstance()->execute($query) == false) { - return false; - } -} + + * @copyright 2007-2017 PrestaShop SA + * @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) + * International Registered Trademark & Property of PrestaShop SA + */ + +$sql = array(); + +$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mollie_payments` ( + `transaction_id` VARCHAR(64) NOT NULL PRIMARY KEY, + `cart_id` INT(64), + `order_id` INT(64), + `order_reference` VARCHAR(191), + `method` VARCHAR(128) NOT NULL, + `bank_status` VARCHAR(64) NOT NULL, + `created_at` DATETIME NOT NULL, + `updated_at` DATETIME DEFAULT NULL, + INDEX (cart_id) + ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; + +$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_country` ( + `id_mol_country` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, + `id_method` VARCHAR(64), + `id_country` INT(64), + `all_countries` tinyint + ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; + +$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_payment_method` ( + `id_payment_method` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, + `id_method` VARCHAR(64) NOT NULL, + `method_name` VARCHAR(64) NOT NULL, + `enabled` TINYINT(1), + `title` VARCHAR(64), + `method` VARCHAR(64), + `description` VARCHAR(255), + `is_countries_applicable` TINYINT(1), + `minimal_order_value` decimal(20,6), + `max_order_value` decimal(20,6), + `surcharge` INT(10), + `surcharge_fixed_amount` decimal(20,6), + `surcharge_percentage` decimal(20,6), + `surcharge_limit` decimal(20,6), + `images_json` TEXT + ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; + +$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_payment_method_issuer` ( + `id_payment_method_issuer` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, + `id_payment_method` INT(64) NOT NULL, + `issuers_json` TEXT NOT NULL + ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; + +$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_order_fee` ( + `id_mol_order_fee` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, + `id_cart` INT(64) NOT NULL, + `order_fee` decimal(20,6) NOT NULL + ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; + +$sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_carrier_information` ( + `id_mol_carrier_information` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, + `id_carrier` INT(64) NOT NULL, + `url_source` VARCHAR(64) NOT NULL, + `custom_url` VARCHAR(255) + ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; + +foreach ($sql as $query) { + if (Db::getInstance()->execute($query) == false) { + return false; + } +} diff --git a/sql/uninstall.php b/sql/uninstall.php index b1aaa151e..0bef9fd36 100644 --- a/sql/uninstall.php +++ b/sql/uninstall.php @@ -1,46 +1,46 @@ - -* @copyright 2007-2017 PrestaShop SA -* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -/** -* In some cases you should not drop the tables. -* Maybe the merchant will just try to reset the module -* but does not want to loose all of the data associated to the module. -*/ - -$sql = array(); - -$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mollie_payments`;'; -$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mol_country`;'; -$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mol_payment_method`;'; -$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mol_payment_method_issuer`;'; -$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mol_order_fee`;'; -$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mol_carrier_information`;'; - -foreach ($sql as $query) { - if (Db::getInstance()->execute($query) == false) { - return false; - } -} + +* @copyright 2007-2017 PrestaShop SA +* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +/** +* In some cases you should not drop the tables. +* Maybe the merchant will just try to reset the module +* but does not want to loose all of the data associated to the module. +*/ + +$sql = array(); + +$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mollie_payments`;'; +$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mol_country`;'; +$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mol_payment_method`;'; +$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mol_payment_method_issuer`;'; +$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mol_order_fee`;'; +$sql[] = 'DROP TABLE IF EXISTS `'._DB_PREFIX_.'mol_carrier_information`;'; + +foreach ($sql as $query) { + if (Db::getInstance()->execute($query) == false) { + return false; + } +} diff --git a/src/Builder/index.php b/src/Builder/index.php index 9e462a606..36c39559c 100644 --- a/src/Builder/index.php +++ b/src/Builder/index.php @@ -1,44 +1,44 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Config/index.php b/src/Config/index.php index 9e462a606..36c39559c 100644 --- a/src/Config/index.php +++ b/src/Config/index.php @@ -1,44 +1,44 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Entity/MolPaymentMethod.php b/src/Entity/MolPaymentMethod.php index 363435947..997b69ea0 100644 --- a/src/Entity/MolPaymentMethod.php +++ b/src/Entity/MolPaymentMethod.php @@ -1,131 +1,131 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -class MolPaymentMethod extends ObjectModel -{ - /** - * @var bool - */ - public $enabled; - - /** - * @var string - */ - public $id_method; - - /** - * @var string - */ - public $method_name; - - /** - * @var string - */ - public $title; - - /** - * @var string - */ - public $method; - - /** - * @var string - */ - public $description; - - /** - * @var bool - */ - public $is_countries_applicable; - - /** - * @var string - */ - public $minimal_order_value; - - /** - * @var string - */ - public $max_order_value; - - /** - * @var int - */ - public $surcharge; - - /** - * @var string - */ - public $surcharge_fixed_amount; - - /** - * @var string - */ - public $surcharge_percentage; - - /** - * @var string - */ - public $surcharge_limit; - - /** - * @var string - */ - public $images_json; - - /** - * @var array - */ - public static $definition = array( - 'table' => 'mol_payment_method', - 'primary' => 'id_payment_method', - 'fields' => array( - 'id_method' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), - 'method_name' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), - 'enabled' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool'), - 'title' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), - 'method' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), - 'description' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), - 'is_countries_applicable' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool'), - 'minimal_order_value' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'), - 'max_order_value' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'), - 'surcharge' => array('type' => self::TYPE_INT, 'validate' => 'isInt'), - 'surcharge_fixed_amount' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'), - 'surcharge_percentage' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'), - 'surcharge_limit' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'), - 'images_json' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), - ), - ); + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +class MolPaymentMethod extends ObjectModel +{ + /** + * @var bool + */ + public $enabled; + + /** + * @var string + */ + public $id_method; + + /** + * @var string + */ + public $method_name; + + /** + * @var string + */ + public $title; + + /** + * @var string + */ + public $method; + + /** + * @var string + */ + public $description; + + /** + * @var bool + */ + public $is_countries_applicable; + + /** + * @var string + */ + public $minimal_order_value; + + /** + * @var string + */ + public $max_order_value; + + /** + * @var int + */ + public $surcharge; + + /** + * @var string + */ + public $surcharge_fixed_amount; + + /** + * @var string + */ + public $surcharge_percentage; + + /** + * @var string + */ + public $surcharge_limit; + + /** + * @var string + */ + public $images_json; + + /** + * @var array + */ + public static $definition = array( + 'table' => 'mol_payment_method', + 'primary' => 'id_payment_method', + 'fields' => array( + 'id_method' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), + 'method_name' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), + 'enabled' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool'), + 'title' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), + 'method' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), + 'description' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), + 'is_countries_applicable' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool'), + 'minimal_order_value' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'), + 'max_order_value' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'), + 'surcharge' => array('type' => self::TYPE_INT, 'validate' => 'isInt'), + 'surcharge_fixed_amount' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'), + 'surcharge_percentage' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'), + 'surcharge_limit' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'), + 'images_json' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), + ), + ); } \ No newline at end of file diff --git a/src/Entity/MolPaymentMethodIssuer.php b/src/Entity/MolPaymentMethodIssuer.php index 0b388585a..ec686118f 100644 --- a/src/Entity/MolPaymentMethodIssuer.php +++ b/src/Entity/MolPaymentMethodIssuer.php @@ -1,59 +1,59 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -class MolPaymentMethodIssuer extends ObjectModel -{ - /** - * @var int - */ - public $id_payment_method; - - /** - * @var string - */ - public $issuers_json; - - /** - * @var array - */ - public static $definition = array( - 'table' => 'mol_payment_method_issuer', - 'primary' => 'id_payment_method_issuer', - 'fields' => array( - 'id_payment_method' => array('type' => self::TYPE_INT, 'validate' => 'isInt'), - 'issuers_json' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), - ), - ); + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +class MolPaymentMethodIssuer extends ObjectModel +{ + /** + * @var int + */ + public $id_payment_method; + + /** + * @var string + */ + public $issuers_json; + + /** + * @var array + */ + public static $definition = array( + 'table' => 'mol_payment_method_issuer', + 'primary' => 'id_payment_method_issuer', + 'fields' => array( + 'id_payment_method' => array('type' => self::TYPE_INT, 'validate' => 'isInt'), + 'issuers_json' => array('type' => self::TYPE_STRING, 'validate' => 'isString'), + ), + ); } \ No newline at end of file diff --git a/src/Entity/index.php b/src/Entity/index.php index 9e462a606..36c39559c 100644 --- a/src/Entity/index.php +++ b/src/Entity/index.php @@ -1,44 +1,44 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Factory/ContextFactory.php b/src/Factory/ContextFactory.php index 0f4913c59..7ffde4d3f 100644 --- a/src/Factory/ContextFactory.php +++ b/src/Factory/ContextFactory.php @@ -1,81 +1,81 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -namespace Mollie\Factory; - -use Context; - -class ContextFactory -{ - public static function getContext() - { - return Context::getContext(); - } - - public static function getLanguage() - { - return Context::getContext()->language; - } - - public static function getCurrency() - { - return Context::getContext()->currency; - } - - public static function getSmarty() - { - return Context::getContext()->smarty; - } - - public static function getShop() - { - return Context::getContext()->shop; - } - - public static function getController() - { - return Context::getContext()->controller; - } - - public static function getCookie() - { - return Context::getContext()->cookie; - } - - public static function getLink() - { - return Context::getContext()->link; - } -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +namespace Mollie\Factory; + +use Context; + +class ContextFactory +{ + public static function getContext() + { + return Context::getContext(); + } + + public static function getLanguage() + { + return Context::getContext()->language; + } + + public static function getCurrency() + { + return Context::getContext()->currency; + } + + public static function getSmarty() + { + return Context::getContext()->smarty; + } + + public static function getShop() + { + return Context::getContext()->shop; + } + + public static function getController() + { + return Context::getContext()->controller; + } + + public static function getCookie() + { + return Context::getContext()->cookie; + } + + public static function getLink() + { + return Context::getContext()->link; + } +} diff --git a/src/Factory/index.php b/src/Factory/index.php index 9e462a606..36c39559c 100644 --- a/src/Factory/index.php +++ b/src/Factory/index.php @@ -1,44 +1,44 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Install/index.php b/src/Install/index.php index 9e462a606..36c39559c 100644 --- a/src/Install/index.php +++ b/src/Install/index.php @@ -1,44 +1,44 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Repository/ModuleRepository.php b/src/Repository/ModuleRepository.php index d9cbb5eca..a00b614f9 100644 --- a/src/Repository/ModuleRepository.php +++ b/src/Repository/ModuleRepository.php @@ -1,52 +1,52 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -namespace Mollie\Repository; - -use Db; -use DbQuery; - -class ModuleRepository -{ - public function getModuleDatabaseVersion($moduleName) - { - $sql = new DbQuery(); - $sql->select('version'); - $sql->from('module'); - $sql->where('`name` = "' . pSQL($moduleName) . '"'); - - return Db::getInstance()->getValue($sql); - } + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +namespace Mollie\Repository; + +use Db; +use DbQuery; + +class ModuleRepository +{ + public function getModuleDatabaseVersion($moduleName) + { + $sql = new DbQuery(); + $sql->select('version'); + $sql->from('module'); + $sql->where('`name` = "' . pSQL($moduleName) . '"'); + + return Db::getInstance()->getValue($sql); + } } \ No newline at end of file diff --git a/src/Repository/index.php b/src/Repository/index.php index 9e462a606..36c39559c 100644 --- a/src/Repository/index.php +++ b/src/Repository/index.php @@ -1,44 +1,44 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Service/index.php b/src/Service/index.php index 9e462a606..36c39559c 100644 --- a/src/Service/index.php +++ b/src/Service/index.php @@ -1,44 +1,44 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/Utility/index.php b/src/Utility/index.php index 9e462a606..36c39559c 100644 --- a/src/Utility/index.php +++ b/src/Utility/index.php @@ -1,44 +1,44 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/src/index.php b/src/index.php index 9e462a606..36c39559c 100644 --- a/src/index.php +++ b/src/index.php @@ -1,44 +1,44 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/translations/de.php b/translations/de.php index 07852e705..e09118de2 100644 --- a/translations/de.php +++ b/translations/de.php @@ -1,282 +1,282 @@ -mollie_09748ce33c8a71296b20ba8c3bd1d13e'] = 'Mollie Zahlungs-Modul'; -$_MODULE['<{mollie}prestashop>mollie_95b3b272e06dcc3cc2aa62f6887aebc5'] = 'Mollie Zahlungen'; -$_MODULE['<{mollie}prestashop>mollie_48dedcf43487615c84c1bbbf6fe76c76'] = 'Sind Sie sicher, dass Sie das Mollie Zahlungs-Modul deinstallieren wollen?'; -$_MODULE['<{mollie}prestashop>mollie_ab552f085567bbe63872c10a3596cd27'] = 'Zahlungsfehler:'; -$_MODULE['<{mollie}prestashop>mollie_76e084771e78c194efd0e2d5b8920bea'] = 'bezahlt'; -$_MODULE['<{mollie}prestashop>mollie_f7d543c9b824323b84ab11668002f207'] = 'autorisiert'; -$_MODULE['<{mollie}prestashop>mollie_d5c39a1d9aced393f835f334a1fb9206'] = 'annulliert'; -$_MODULE['<{mollie}prestashop>mollie_c4bfb2a0bab0e91bc7dcfbe3bbec246e'] = 'abgelaufen'; -$_MODULE['<{mollie}prestashop>mollie_ad32204fca182b862a5f97a5534c03a2'] = 'zurückerstattet'; -$_MODULE['<{mollie}prestashop>mollie_542ba101e183aea6bc8dab5b1ec5ef7f'] = 'Ãœberweisung ausstehend'; -$_MODULE['<{mollie}prestashop>mollie_837cbb7173db2e32b3783e87597dac90'] = 'teilweise zurückerstattet'; -$_MODULE['<{mollie}prestashop>mollie_e2b7dec8fa4b498156dfee6e4c84b156'] = 'Diese Zahlungsart ist nicht verfügbar.'; -$_MODULE['<{mollie}prestashop>mollie_96d0e2862e0167af0c2fd0c99fe6bc5d'] = 'Klicken Sie hier, um fortzufahren'; -$_MODULE['<{mollie}prestashop>mollie_540d9939d1ca9406e215ee3d78c76813'] = 'Diese Zahlungsmethode ist nur für Euros verfügbar.'; -$_MODULE['<{mollie}prestashop>mollie_1b2631119333d97dbda37f87e378b1e4'] = 'Bei der Verarbeitung Ihrer Anfrage ist ein Fehler aufgetreten:'; -$_MODULE['<{mollie}prestashop>mollie_11bab828edcc0a6d5c97cbf84d61e652'] = 'Eine Bestellung mit dieser Kennung existiert nicht.'; -$_MODULE['<{mollie}prestashop>mollie_b34487c5f391f47b893ee3c61f8f9ab7'] = 'Wir haben keinen definitiven Zahlungsstatus erhalten. Sie werden informiert, sobald wir eine Bestätigung der Bank/des Händlers erhalten haben.'; -$_MODULE['<{mollie}prestashop>mollie_57bc999b3b730ead92ac7243fe254a2a'] = 'Leider ist Ihre Zahlung abgelaufen.'; -$_MODULE['<{mollie}prestashop>mollie_3602f6d5ece34fdbd4ffe0a47f1a2ba4'] = 'Vielen Dank. Wir haben Ihre Zahlung erhalten.'; -$_MODULE['<{mollie}prestashop>mollie_7352a401b3c23b2966c68bc9ab97fa06'] = 'Die Transaktion hat einen unerwarteten Status.'; -$_MODULE['<{mollie}prestashop>mollie_3f83176ddc3f63a5a374a623840bfb09'] = 'Sie sind nicht berechtigt, diese Seite anzusehen.'; -$_MODULE['<{mollie}prestashop>mollie_300225ee958b6350abc51805dab83c24'] = 'Einkauf fortsetzen'; -$_MODULE['<{mollie}prestashop>mollie_ebdf0f490b617d7efa3025d3625cec85'] = 'Willkommen zurück'; -$_MODULE['<{mollie}prestashop>mollie_66dac2278292ff24611ef8a85bc94e0d'] = 'Wählen Sie Ihre Bank aus:'; -$_MODULE['<{mollie}prestashop>mollie_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; -$_MODULE['<{mollie}prestashop>mollie_b98a07c82f0078a1de7fc219fae480fc'] = 'Andere Zahlungsmethode'; -$_MODULE['<{mollie}prestashop>mollie_35895cff7df70dab18783453e2bd241f'] = 'Zahlen mit %s'; -$_MODULE['<{mollie}prestashop>mollie_cc16e103e202a48009df202d9525f75f'] = 'Diese Bestellung räckerstatten'; -$_MODULE['<{mollie}prestashop>mollie_c5222afef6530f674d3acf82ba2ce9dc'] = 'Mollie Räckerstattung'; -$_MODULE['<{mollie}prestashop>mollie_7064b25aa8a732a3db7f230c9867be19'] = 'Bestellung #%d Ãœber die Mollie API räckerstatten.'; -$_MODULE['<{mollie}prestashop>mollie_e12682d2e0650f2783b22d956d2b947a'] = 'Dieser Bestellung wurde zurückerstattet!'; -$_MODULE['<{mollie}prestashop>mollie_95be87afb2734075cf345b633e1384ec'] = 'Mollie B.V. wird das Geld am nächsten Werktag an den Kunden zurücküberweisen.'; -$_MODULE['<{mollie}prestashop>mollie_9770d1f0124abb0d6a894cd79f8703b5'] = 'Warten auf Mollie Zahlung'; -$_MODULE['<{mollie}prestashop>mollie_b9fc80a6e775cb75568db6b6538dacdd'] = 'Mollie teilweise zurück erstattet'; -$_MODULE['<{mollie}prestashop>mollie_f91ab041fe9d6057740394b8b7903a0f'] = 'iDEAL'; -$_MODULE['<{mollie}prestashop>mollie_b749cfb52bfd82c5b12aa49d6906b8e8'] = 'CartaSi'; -$_MODULE['<{mollie}prestashop>mollie_05bfde942b997737b56b9ab405450076'] = 'Cartes Bancaires'; -$_MODULE['<{mollie}prestashop>mollie_e7f9e382dc50889098cbe56f2554c77b'] = 'Kreditkarte'; -$_MODULE['<{mollie}prestashop>mollie_870cf6bc77bbadd038aeb8d942c9cb18'] = 'Bancontact'; -$_MODULE['<{mollie}prestashop>mollie_8ad65eb3da9995173280649f090218c3'] = 'SOFORT Banking'; -$_MODULE['<{mollie}prestashop>mollie_c0db4214f9d7e1b846f4496e03e667d0'] = 'SEPA Lastschriftverfahren'; -$_MODULE['<{mollie}prestashop>mollie_5aa515ce21e8de1ed7416dce455a151f'] = 'Belfius Pay Button'; -$_MODULE['<{mollie}prestashop>mollie_d023ec040f79f1a9b2ac960b43785089'] = 'Bitcoin'; -$_MODULE['<{mollie}prestashop>mollie_4aa65ea89e54d83bb2604c2cc89babc3'] = 'PODIUM Geschenkkarte'; -$_MODULE['<{mollie}prestashop>mollie_58c25c4b8b4382e37d89e0ef6bd625cf'] = 'Gift cards'; -$_MODULE['<{mollie}prestashop>mollie_431647a0a8b2cd589c9fda9535f90d6d'] = 'Ãœberweisung'; -$_MODULE['<{mollie}prestashop>mollie_ad69e733ebae8d264bccaa38d68830e8'] = 'PayPal'; -$_MODULE['<{mollie}prestashop>mollie_6abcd8eecb4f2abb6ccfe36ef7046ba0'] = 'paysafecard'; -$_MODULE['<{mollie}prestashop>mollie_a81bd6195f1abce35fd03a870270100b'] = 'KBC/CBC Payment Button'; -$_MODULE['<{mollie}prestashop>mollie_8184c64d6318b4a42428ae21d0fe2311'] = 'ING Home\'Pay'; -$_MODULE['<{mollie}prestashop>mollie_31911306551723245e7417ae4520fecb'] = 'Giropay'; -$_MODULE['<{mollie}prestashop>mollie_ce8e4a184e2e534c09d6bf6ae773ca4a'] = 'eps'; -$_MODULE['<{mollie}prestashop>mollie_feb1a8ded87483b416427b8457bdc664'] = 'Klarna: Rechnung'; -$_MODULE['<{mollie}prestashop>mollie_a388a6fba0d4b58c334cd9416071cdb1'] = 'Klarna: Ratenkauf'; -$_MODULE['<{mollie}prestashop>mollie_d1913efa9eae51595a33f3c1410d465c'] = 'Die Methode %s wurde durch Modul %s aufgehoben. Dies kann zu Störungen im Zahlungsvorgang führen.'; -$_MODULE['<{mollie}prestashop>mollie_6311eb29dee3acc14071e0b1efb173f5'] = '%s Status:'; -$_MODULE['<{mollie}prestashop>mollie_d438a1d96c6037fccad15d7594737a84'] = 'Visuelle Einstellungen:'; -$_MODULE['<{mollie}prestashop>mollie_49259add73e416838e985a6bf4d0e571'] = 'Debug-Information:'; -$_MODULE['<{mollie}prestashop>mollie_c9cc8cce247e49bae79f15173ce97354'] = 'Speichern'; -$_MODULE['<{mollie}prestashop>mollie_5bef23eb7efff2736c5583bda59e5eb7'] = 'Erstellen Sie Ihr Konto'; -$_MODULE['<{mollie}prestashop>mollie_a77e6fc49f07414fc53336c8d879b73e'] = 'Haben Sie bereits einen API Schlüssel? Dann können Sie diesen Schritt überspringen und mit Ihrem API-Schlüssel fortfahren.'; -$_MODULE['<{mollie}prestashop>mollie_21aef67e8d12503aff027385d0a7867f'] = 'Vor- und Nachname'; -$_MODULE['<{mollie}prestashop>mollie_b357b524e740bc85b9790a0712d84a30'] = 'Email-Adresse'; -$_MODULE['<{mollie}prestashop>mollie_e93c33bd1341ab74195430daeb63db13'] = 'Shop-Name'; -$_MODULE['<{mollie}prestashop>mollie_dd7bf230fde8d4836917806aff6a6b27'] = 'Adresse'; -$_MODULE['<{mollie}prestashop>mollie_8bcdc441379cbf584638b0589a3f9adb'] = 'Postleitzahl'; -$_MODULE['<{mollie}prestashop>mollie_57d056ed0984166336b7879c2af3657f'] = 'Stadt'; -$_MODULE['<{mollie}prestashop>mollie_59716c97497eb9694541f7c3d37b1a4d'] = 'Land'; -$_MODULE['<{mollie}prestashop>mollie_686e697538050e4664636337cc3b834f'] = 'Konto erstellen'; -$_MODULE['<{mollie}prestashop>mollie_7c4e7ada50c8572336f872fced4d1852'] = 'Status für %s Zahlungen'; -$_MODULE['<{mollie}prestashop>mollie_bea3fae02ae079e541199ab6ffc2d1ad'] = '`%s` Zahlungen erhalten den Status \'%s`'; -$_MODULE['<{mollie}prestashop>mollie_b2a2c5a69af7c04c5adc48261fb5dc13'] = 'E-Mails senden, wenn %s'; -$_MODULE['<{mollie}prestashop>mollie_0511c3431d4e32ed4266fe943014d000'] = 'E-Mails senden, wenn Transaktionsstatus in %s geändert wird.'; -$_MODULE['<{mollie}prestashop>mollie_7aace0dc23ee8b74744bdf79c98a2605'] = 'Ãœberspringe diesen Status'; -$_MODULE['<{mollie}prestashop>mollie_dd59e3663865f3fab190e496260608e6'] = '`%s` Zahlungen erhalten keinen Status'; -$_MODULE['<{mollie}prestashop>mollie_824f2c1d1c2ee9aecac9977d9347a2ea'] = 'Mollie Einstellungen'; -$_MODULE['<{mollie}prestashop>mollie_d876ff8da67c3731ae25d8335a4168b4'] = 'API Schlüssel'; -$_MODULE['<{mollie}prestashop>mollie_2ffbc7eb8899865f9e66682d34853195'] = 'Sie finden Ihren API-Schlüssel in Ihrem [1] Mollie-Profil [/1]; Der Schlüssel beginnt mit Test oder Live.'; -$_MODULE['<{mollie}prestashop>mollie_b5a7adde1af5c87d7fd797b6245c2a39'] = 'Beschreibung'; -$_MODULE['<{mollie}prestashop>mollie_3150652ab7f22bafe11a78d4cc0de8be'] = 'Geben Sie hier eine Beschreibung ein. Achtung: Zahlungsmethoden können eine Beschränkung in der Anzahl der Zeichen haben, benutzten Sie nicht mehr als 29 Zeichen für die Beschreibung. Sie können die folgenden Variablen verwenden: %s'; -$_MODULE['<{mollie}prestashop>mollie_8d9143dfc520ed7d982d4e545c7bfc5e'] = 'Gebietsschema für Zahlungsbildschirm senden'; -$_MODULE['<{mollie}prestashop>mollie_1239c091f39c068882e924e34dd9cc40'] = 'Sollte das Plugin den aktuellen Webshop [1] locale [/1] an Mollie senden. Mollie Bezahlfenster werden in der gleichen Sprache wie Ihr Webshop sein. Mollie kann die Sprache auch anhand der Browsersprache des Benutzers erkennen.'; -$_MODULE['<{mollie}prestashop>mollie_80a78bb16945665b6410ae8d93e81c69'] = 'Senden Sie das Gebietsschema nicht über die Browsersprache'; -$_MODULE['<{mollie}prestashop>mollie_3ba67aae5d08d0fa90016685407926f1'] = 'Visuelle Einstellungen'; -$_MODULE['<{mollie}prestashop>mollie_fff0d600f8a0b5e19e88bfb821dd1157'] = 'Bilder'; -$_MODULE['<{mollie}prestashop>mollie_f7a97136df639501521efb243047e0cf'] = 'Zeigen Sie große, normale oder keine Zahlungsmethodenlogos beim Checkout an.'; -$_MODULE['<{mollie}prestashop>mollie_a88f05b6c963e145a45b58c47cd42a41'] = 'ausblenden'; -$_MODULE['<{mollie}prestashop>mollie_fea087517c26fadd409bd4b9dc642555'] = 'normal'; -$_MODULE['<{mollie}prestashop>mollie_d861877da56b8b4ceb35c8cbfdf65bb4'] = 'groß'; -$_MODULE['<{mollie}prestashop>mollie_85fb708f31f585607247f8b868efafcc'] = 'Ausstellerliste'; -$_MODULE['<{mollie}prestashop>mollie_27db39558366d2a9001a0dec69eea4d6'] = 'Einige Zahlungsmethoden (z. B. iDEAL) haben eine Ausstellerliste. Diese Einstellung gibt an, wo sie angezeigt wird.'; -$_MODULE['<{mollie}prestashop>mollie_85a692706bc7597b6e32bc1d354c138f'] = 'Auf Befehl'; -$_MODULE['<{mollie}prestashop>mollie_ea9b19c6f2e9ef60b49778ab9396b293'] = 'Eigene Seite'; -$_MODULE['<{mollie}prestashop>mollie_d35acbb07d2841712a937d5748e9bdc2'] = 'Zahlungsseite'; -$_MODULE['<{mollie}prestashop>mollie_1547ffc579d657d13fd5fedf12cbfae5'] = 'CSS Datei'; -$_MODULE['<{mollie}prestashop>mollie_6602513644161421f58418528d93ac00'] = 'Lassen Sie das Standard-Stylesheet leer. Sollte Dateipfad enthalten, wenn festgelegt. Tipp: Sie können [1] {BASE} [/1], [1] {THEMA} [/1], [1] {CSS} [/1], [1] {MOBILE} [/1], [1] {MOBILE_CSS} [/1] und [1] {OVERRIDE} [/1] für einfache Ordnerzuordnung.'; -$_MODULE['<{mollie}prestashop>mollie_0da8d9a75492046bea7f314521e07cae'] = 'Zahlungsarten'; -$_MODULE['<{mollie}prestashop>mollie_75886bf821fc9c068a280fe52337c0f5'] = 'Aktivieren oder deaktivieren Sie die Zahlungsmethoden. Sie können die Zahlungsmethoden per Drag & Drop verschieben.'; -$_MODULE['<{mollie}prestashop>mollie_c576349bf8ff5fba4e9369ab581a4074'] = 'Aktivieren Sie den iDEAL QR Code'; -$_MODULE['<{mollie}prestashop>mollie_c0ae4417e7a196f3ccfadff68a5064ed'] = 'iDEAL QR Code ist derzeit noch nicht in der Orders API verfügbar. Wir entschuldigen uns für die Unannehmlichkeiten.'; -$_MODULE['<{mollie}prestashop>mollie_e17dc77fb83539b6a4687c6d515791e4'] = '%s Status'; -$_MODULE['<{mollie}prestashop>mollie_b068931cc450442b63f5b3d276ea4297'] = 'Name'; -$_MODULE['<{mollie}prestashop>mollie_4695fd3a22023ab53a2151f797975ff8'] = 'Diesen Status deaktivieren'; -$_MODULE['<{mollie}prestashop>mollie_656f9fd6f874404599220855cfec17ef'] = 'Mollie API'; -$_MODULE['<{mollie}prestashop>mollie_a1532be2c9ef11d7dd5edd974fc6c98c'] = 'Wählen Sie die Mollie-API aus, die verwendet werden soll'; -$_MODULE['<{mollie}prestashop>mollie_9ce1d2272c82bfd7d501a6697df774c7'] = 'Soll das Plugin die neue Mollie Orders API verwenden? Dies schaltet Zahlungsmethoden wie Klarna Pay Later frei.'; -$_MODULE['<{mollie}prestashop>mollie_8c2b4949d892b39b236545951f10bbd4'] = 'Payments API'; -$_MODULE['<{mollie}prestashop>mollie_a8b0255f70ecc140a1b5134ae5217e51'] = 'Orders API'; -$_MODULE['<{mollie}prestashop>mollie_1191f888f0cc23f95aa77aacb094503b'] = 'Versandinformationen'; -$_MODULE['<{mollie}prestashop>mollie_d822c02513be98814bdd39f8bae598d1'] = 'Automatisch versenden, wenn als `versendet`markiert'; -$_MODULE['<{mollie}prestashop>mollie_0eccefc4c96190190add75fe0a74fcd4'] = 'Durch Aktivieren dieser Funktion wird die Versandinformation automatisch versendet, wenn eine Bestellung als `versendet` markiert ist'; -$_MODULE['<{mollie}prestashop>mollie_c1df8a5243557cbd8a7a31c11aab3db4'] = 'Automatisch versenden, wenn einer dieser Status erreicht wird'; -$_MODULE['<{mollie}prestashop>mollie_34bd91e87db36a10b9e847d6304be289'] = 'Falls eine Bestellung eine dieser Status erreicht, wird die Versandinformation automatisch versendet'; -$_MODULE['<{mollie}prestashop>mollie_498f79c4c5bbde77f1bceb6c86fd0f6d'] = 'Anzeigen'; -$_MODULE['<{mollie}prestashop>mollie_62a5e490880a92eef74f167d9dc6dca0'] = 'Verbergen'; -$_MODULE['<{mollie}prestashop>mollie_dc6e4b439165a4e104c9f3cbfcfe2797'] = 'Debug-Ebene'; -$_MODULE['<{mollie}prestashop>mollie_500aa80d6aea3cc9701b566c5f92ed91'] = 'Fehler anzeigen'; -$_MODULE['<{mollie}prestashop>mollie_37f9a8b20930c1dc7488b15872b6d36b'] = 'Wenn Sie diese Funktion aktivieren, werden Fehlermeldungen (falls vorhanden) auf der Startseite angezeigt. Nur zu Debugzwecken verwenden!'; -$_MODULE['<{mollie}prestashop>mollie_e5114c4b69585ba5883d456a74c1cd5d'] = 'Protokollierebene'; -$_MODULE['<{mollie}prestashop>mollie_921a6d905eef99631c9c73c317799e62'] = 'Empfohlene Stufe: Fehler. Wählen Sie Alle, um eingehende Webhook-Anfragen zu überwachen. [1] Protokolle anzeigen. [/1]'; -$_MODULE['<{mollie}prestashop>mollie_f80a4ad87fee7c9fdc19b7769495fdb5'] = 'Nichts'; -$_MODULE['<{mollie}prestashop>mollie_5ef0c737746fae2ca90e66c39333f8f6'] = 'Fehler'; -$_MODULE['<{mollie}prestashop>mollie_709468af25e91284821d1bdbfdded24c'] = 'Alles'; -$_MODULE['<{mollie}prestashop>mollie_7c478959c218087ffc4ad5d96e7f66a6'] = 'Mollie'; -$_MODULE['<{mollie}prestashop>mollie_1f93fc361bfc627c89a46e1b6c28df2b'] = 'Der API Schlüssel beginnt mit \'test\' oder \'live\'.'; -$_MODULE['<{mollie}prestashop>mollie_6ab1adfed768d989b47c908755fe677f'] = 'Die Konfigurierung wurde gespeichert!'; -$_MODULE['<{mollie}prestashop>mollie_1f91cd9f380285bf1219c79ab7fcb75e'] = 'Warnung: Aktualisierungsdatei konnte nicht von github abgerufen werden.'; -$_MODULE['<{mollie}prestashop>mollie_ce1e483d5cd4b349af887fa3e198ea6b'] = 'Kein Download-Paket für die neueste Version gefunden.'; -$_MODULE['<{mollie}prestashop>mollie_048ef1905ff33382d7660a68a6199305'] = 'Warnung: Update xml Datei konnte nicht von github abgerufen werden.'; -$_MODULE['<{mollie}prestashop>mollie_711d42f319398490b32cd0e2f0b8ccb8'] = 'Warnung: Update xml Datei von github folgt einem unbekanntem Format.'; -$_MODULE['<{mollie}prestashop>mollie_48fa0f621f79f451e58f200957da5b52'] = 'Wählen Sie Ihre Bank aus'; -$_MODULE['<{mollie}prestashop>mollie_8953fb7da2299bf905b73720f611baa3'] = 'oder zahlen mit dem iDEAL QR-Code'; -$_MODULE['<{mollie}prestashop>mollie_961f2247a2070bedff9f9cd8d64e2650'] = 'Wählen'; -$_MODULE['<{mollie}prestashop>mollie_ea4788705e6873b424c65e91c2846b19'] = 'Annullieren'; -$_MODULE['<{mollie}prestashop>mollie_f93bd0f858a6e5f70cb458c90a36172b'] = 'Info über die neueste Version konnte nicht abgerufen werden'; -$_MODULE['<{mollie}prestashop>mollie_ced93781bca50eb4d970ea51abcc622c'] = 'Sie haben bereits die neueste Version installiert!'; -$_MODULE['<{mollie}prestashop>mollie_43f3c5a157c67de9b6faf42b637f963a'] = 'Das Modularchiv konnte nicht heruntergeladen werden'; -$_MODULE['<{mollie}prestashop>mollie_31dd57eea0f762b4ea6f022b40acc390'] = 'Beim Extrahieren der Moduldatei ist ein Fehler aufgetreten (Datei ist möglicherweise beschädigt).'; -$_MODULE['<{mollie}prestashop>mollie_bad5a3ab102f6e9c27edd494d7e33323'] = 'Ihr neues Mollie-Konto wurde erfolgreich erstellt. Bitte überprüfen Sie Ihren Posteingang für weitere Informationen.'; -$_MODULE['<{mollie}prestashop>mollie_023b7ade110944180153fd73358fc50c'] = 'Beim Erstellen Ihres Mollie-Kontos ist ein unbekannter Fehler aufgetreten'; -$_MODULE['<{mollie}prestashop>mollie_88183b946cc5f0e8c96b2e66e1c74a7e'] = 'Unbekannt'; -$_MODULE['<{mollie}prestashop>mollie_301b87d33063f687d14004a9014f6759'] = 'Sie sind nicht berechtigt, Zahlungen zu erstatten'; -$_MODULE['<{mollie}prestashop>mollie_8dc6945fb6b59aea38df7935cf3afb6d'] = 'Sie sind nicht berechtigt, Zahlungen zu %s'; -$_MODULE['<{mollie}prestashop>mollie_1bda80f2be4d3658e0baa43fbe7ae8c1'] = 'anzeigen'; -$_MODULE['<{mollie}prestashop>mollie_de95b43bceeb4b998aed4aed5cef1ae7'] = 'bearbeiten'; -$_MODULE['<{mollie}prestashop>mollie_2a3f1166b041928019e4e8718d628665'] = 'versenden'; -$_MODULE['<{mollie}prestashop>mollie_df6f85687a0d5820baa1a069a04eff2d'] = 'Rückerstattung'; -$_MODULE['<{mollie}prestashop>mollie_10aec35353f9c4096a71c38654c3d402'] = 'annullieren'; -$_MODULE['<{mollie}prestashop>payment_c2f73af3130be4b4967a475ab846c546'] = 'Ein Fehler ist aufgetreten während Ihre Zahlung eingeleitet wurde. Bitte kontaktieren Sie unseren Kundenservice.'; -$_MODULE['<{mollie}prestashop>download_update_6de6a882c42b757cd027830399a74de4'] = 'Aktualisieren Sie dieses Modul'; -$_MODULE['<{mollie}prestashop>download_update_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Fehler'; -$_MODULE['<{mollie}prestashop>download_update_5d04a002ea59c8114f9d08b0c6250a3b'] = 'Verbindung konnte nicht hergestellt werden'; -$_MODULE['<{mollie}prestashop>download_update_3844b140df977eee8639de6d1de9e1e0'] = 'Das neue Modul konnte nicht entpackt werden'; -$_MODULE['<{mollie}prestashop>download_update_b50ec141b028d5a8acec4a17c32f3808'] = 'Das Modul wurde aktualisiert!'; -$_MODULE['<{mollie}prestashop>new_release_b7f73af7318580996a3889353b282827'] = 'Sie verwenden momentan Version %s. Wir empfehlen Ihnen dringenst, die neue Version %s! zu installieren.'; -$_MODULE['<{mollie}prestashop>form_93cba07454f06a4a960172bbd6e2a435'] = 'Ja'; -$_MODULE['<{mollie}prestashop>form_bafd7322c6e97d25b6299b5d6fe8920b'] = 'Nein'; -$_MODULE['<{mollie}prestashop>form_2d25c72c1b18e562f6654fff8e11711e'] = 'Nicht verfügbar'; -$_MODULE['<{mollie}prestashop>form_58afe6389d8f42880d1011ef0de542a2'] = 'Diese Zahlungsmethode ist in der Payments API nicht verfügbar. Wechseln Sie zu der nachfolgenden Orders API um diese Zahlungsmethode zu aktivieren.'; -$_MODULE['<{mollie}prestashop>form_9b6a88a9d4a44740f87b1ffa7cb070c4'] = 'Laden der Zahlungsmethoden nicht möglich'; -$_MODULE['<{mollie}prestashop>form_6327b4e59f58137083214a1fec358855'] = 'Erneut versuchen'; -$_MODULE['<{mollie}prestashop>form_49ee3087348e8d44e1feda1917443987'] = 'Name'; -$_MODULE['<{mollie}prestashop>form_b33f1d112cd9d2d32d37cb4cc9a340c8'] = 'Quell-URL'; -$_MODULE['<{mollie}prestashop>form_de28ef21a06f3978c05f3d808b15eaab'] = 'Zusteller URL'; -$_MODULE['<{mollie}prestashop>form_812a48ba719daeda82e4da8e812d426c'] = 'Benutzerdefinierte URL'; -$_MODULE['<{mollie}prestashop>form_e55f75a29310d7b60f7ac1d390c8ae42'] = 'Module'; -$_MODULE['<{mollie}prestashop>form_962b59a5f12eabd9c05f11b5f0aada85'] = 'Nicht automatisch versenden'; -$_MODULE['<{mollie}prestashop>form_703490ffd308d337cd5aac50567e9670'] = 'Keine Tracking-Information'; -$_MODULE['<{mollie}prestashop>form_f421a366f70bd2aa1193eeb5a2990546'] = 'Hier können Sie die Versandinformation, die Mollie mitgeteilt wird, bearbeiten'; -$_MODULE['<{mollie}prestashop>form_53b2566e3519ea98db40ae9e716883a5'] = 'Sie können die folgenden Variablen für die Zusteller URL nutzen'; -$_MODULE['<{mollie}prestashop>form_910d956cb2615e5739ac06c7f08fba26'] = 'Versandnummer'; -$_MODULE['<{mollie}prestashop>form_e7e862a02819a1610f271ffea15ed47d'] = 'Ländercode Rechnungsadresse'; -$_MODULE['<{mollie}prestashop>form_5723a18d8a8a6052a57489df5be59a8f'] = 'Postleitzahl Rechnungsadresse'; -$_MODULE['<{mollie}prestashop>form_0d12e3c554976ad1f76c5db2b6c127ad'] = 'Ländercode Versandadresse'; -$_MODULE['<{mollie}prestashop>form_c824a8b18f09dc7e58bacf446be6735c'] = 'Postleitzahl Versandadresse'; -$_MODULE['<{mollie}prestashop>form_0a867177f4a701a9f33de5ab21c42593'] = 'Sprachcode bestehend aus zwei Buchstaben'; -$_MODULE['<{mollie}prestashop>form_f6fcb64e21455abc4209f8f4440d45f5'] = 'Laden der Zusteller-Liste nicht möglich'; -$_MODULE['<{mollie}prestashop>form_da93de158db2fbe49f35f6038711584a'] = 'Diese Option wird für die derzeit gewählte API nicht benötigt'; -$_MODULE['<{mollie}prestashop>error_c453a4b8e8d98e82f35b67f433e3b4da'] = 'Zahlung'; -$_MODULE['<{mollie}prestashop>error_1e97d97a923eaddd810e056c828e99ea'] = 'Zahlungsfehler'; -$_MODULE['<{mollie}prestashop>error_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Bei der Bearbeitung Ihres Auftrags ist ein Fehler aufgetreten'; -$_MODULE['<{mollie}prestashop>error_47e1924c444fafe9fdfce444790f0ba9'] = ' Zurück zu Ihrem Einkaufswagen'; -$_MODULE['<{mollie}prestashop>mollie_issuers_588540a38eeba525f3598b68e6b788e5'] = 'oder wählen Sie eine andere Zahlungsmethode'; -$_MODULE['<{mollie}prestashop>mollie_return_ebdf0f490b617d7efa3025d3625cec85'] = 'Willkommen zurück'; -$_MODULE['<{mollie}prestashop>mollie_return_300225ee958b6350abc51805dab83c24'] = 'Einkauf fortsetzen'; -$_MODULE['<{mollie}prestashop>qr_done_92816c7248d010591f699db3aaf6287b'] = 'Mollie iDEAL-QR-Code'; -$_MODULE['<{mollie}prestashop>qr_done_ebdf0f490b617d7efa3025d3625cec85'] = 'Willkommen zurück'; -$_MODULE['<{mollie}prestashop>qr_done_4bf3a07ce980c9b007f9e2eed42d7fa2'] = 'Die Zahlung wurde storniert.'; -$_MODULE['<{mollie}prestashop>qr_done_6933c118341d8c06f888c392aa1ceaf5'] = 'Die Zahlung ist abgeschlossen. Vielen Dank für Ihre Bestellung!'; -$_MODULE['<{mollie}prestashop>ideal_dropdown_ab4147235204a436c09e00d6722082ab'] = 'Wähle eine Bank'; -$_MODULE['<{mollie}prestashop>order_info_729a51874fe901b092899e9e8b31c97a'] = 'Sind Sie sicher?'; -$_MODULE['<{mollie}prestashop>order_info_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Sind Sie sicher, dass Sie diese Bestellung zurück erstatten wollen?'; -$_MODULE['<{mollie}prestashop>order_info_76f0ed934de85cc7131910b32ede7714'] = 'Rückerstattung'; -$_MODULE['<{mollie}prestashop>order_info_ea4788705e6873b424c65e91c2846b19'] = 'Annullieren'; -$_MODULE['<{mollie}prestashop>order_info_88ba0dcbc82905637e98317e0302cfd8'] = 'Bestellung rückerstatten'; -$_MODULE['<{mollie}prestashop>order_info_5a1119ecb764165f27cb37b6f50134f2'] = 'Verbleibend'; -$_MODULE['<{mollie}prestashop>order_info_77fd2b4393b379bedd30efcd5df02090'] = 'Teilerstattung'; -$_MODULE['<{mollie}prestashop>order_info_a9ced76f2dd6907220fa95b3a136b04a'] = 'Ungültige Anzahl'; -$_MODULE['<{mollie}prestashop>order_info_3a2c3e97fed586776c2800fb7a0faf4e'] = 'Sie haben eine ungültige Summe eingegeben'; -$_MODULE['<{mollie}prestashop>order_info_3cc4859e502556d0d848c3bc38618782'] = 'Rückerstattung fehlgeschlagen'; -$_MODULE['<{mollie}prestashop>order_info_d5cfd0f69cd548e5d3b9edde5ff1b48f'] = 'Zahlungsinformation'; -$_MODULE['<{mollie}prestashop>order_info_88427ec035734b45aae9f7d8859a5008'] = 'Transaktionsnummer'; -$_MODULE['<{mollie}prestashop>order_info_782678f4ba02feb3e9ecd51e902cd16b'] = 'Historie erstatten'; -$_MODULE['<{mollie}prestashop>order_info_c5b41ae59bd6585750f536615a6bc20b'] = 'Es bestehen keine Rückerstattungen'; -$_MODULE['<{mollie}prestashop>order_info_b718adec73e04ce3ec720dd11a06a308'] = 'Nummer'; -$_MODULE['<{mollie}prestashop>order_info_44749712dbec183e983dcd78a7736c41'] = 'Datum'; -$_MODULE['<{mollie}prestashop>order_info_b2f40690858b404ed10e62bdf422c704'] = 'Betrag'; -$_MODULE['<{mollie}prestashop>order_info_53beb26d8bca00f56fbd295fdee83459'] = 'Rückerstattungen'; -$_MODULE['<{mollie}prestashop>order_info_daef64964ee3b9b904f5d467586e217f'] = 'Zahlungen'; -$_MODULE['<{mollie}prestashop>order_info_e25be354288565757726f3295e4f3ef9'] = 'Aktueller Betrag'; -$_MODULE['<{mollie}prestashop>order_info_068f80c7519d0528fb08e82137a72131'] = 'Produkte'; -$_MODULE['<{mollie}prestashop>order_info_ec53a8c4f07baed5d8825072c89799be'] = 'Status'; -$_MODULE['<{mollie}prestashop>order_info_747cf5c8587184b9e489ff897d97c20d'] = 'Verschickt'; -$_MODULE['<{mollie}prestashop>order_info_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Annulliert'; -$_MODULE['<{mollie}prestashop>order_info_cc61945cbbf46721a053467c395c666f'] = 'Erstattet'; -$_MODULE['<{mollie}prestashop>order_info_197101c4a1b1fc503dcd6ebee127aa10'] = 'Stückpreis'; -$_MODULE['<{mollie}prestashop>order_info_11cd653a2488e260a8a99f39cdffa6e7'] = 'MwSt-Betrag'; -$_MODULE['<{mollie}prestashop>order_info_bc30768048a7bbfd2d158d722c140c6d'] = 'Gesamtbetrag'; -$_MODULE['<{mollie}prestashop>order_info_0387832795db3eb2e05f4365fba5ddac'] = 'Versenden'; -$_MODULE['<{mollie}prestashop>order_info_55453aad10c96e452556a106447313bd'] = 'Versand überprüfen'; -$_MODULE['<{mollie}prestashop>order_info_dbb5bbb116e16973136b9ebd887eaadd'] = 'Bitte überprüfen Sie die Artikel die im Versand inbegriffen sind. Sie können Artikel entfernen oder die Anzahl verändern, wenn nötig.'; -$_MODULE['<{mollie}prestashop>order_info_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; -$_MODULE['<{mollie}prestashop>order_info_163bcc6065b16c6369c7a4de44cff164'] = 'Artikel versenden'; -$_MODULE['<{mollie}prestashop>order_info_433557a938a920888445ce2c7df67d5a'] = 'Details der Sendungsverfolgung'; -$_MODULE['<{mollie}prestashop>order_info_61995a579a6166642e759450a694642b'] = 'Wir empfehlen Ihnen Informationen zur Sendungsverfolgung hinzuzufügen, da dies beweist, dass Sie die Artikel wirklich versendet haben.'; -$_MODULE['<{mollie}prestashop>order_info_26b6254fefc06894825a50dfbe803937'] = 'Informationen zur Sendungsverfolgung überprüfen'; -$_MODULE['<{mollie}prestashop>order_info_d57c24f3fe52d16e7169b912dd647f0d'] = 'optional'; -$_MODULE['<{mollie}prestashop>order_info_2df417909bda5f3ddc210a0abe65231f'] = 'E.g. FedEx'; -$_MODULE['<{mollie}prestashop>order_info_593ed3a37aa1a3ece4a4d796fb4e2e03'] = 'Diese Information wird benötigt'; -$_MODULE['<{mollie}prestashop>order_info_933292561b46133ff5348c7740874c56'] = 'Sendungsverfolgungnummer'; -$_MODULE['<{mollie}prestashop>order_info_e6b391a8d2c4d45902a23a8b6585703d'] = 'URL'; -$_MODULE['<{mollie}prestashop>order_info_914419aa32f04011357d3b604a86d7eb'] = 'Zusteller'; -$_MODULE['<{mollie}prestashop>order_info_23a902ac637359fe67ceaccbe2c68283'] = 'Alles versenden'; -$_MODULE['<{mollie}prestashop>order_info_2a6e9f678c7267fe16f57bcd3285f1d7'] = 'Alles annullieren'; -$_MODULE['<{mollie}prestashop>order_info_05ced64413f9ff5d3602c3e257f36204'] = 'Alles erstatten'; -$_MODULE['<{mollie}prestashop>order_info_bfe005bff7ecacd6ecceacdd7fb79292'] = 'Transaktionsinformationen'; -$_MODULE['<{mollie}prestashop>order_info_1eefa98a18a384699fe611fbfd8ab0c9'] = 'Keine Artikel vorhanden'; -$_MODULE['<{mollie}prestashop>order_info_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Ein Fehler ist aufgetreten'; -$_MODULE['<{mollie}prestashop>order_info_2df3102f3fe061003dee820a72e1b1ed'] = 'Versand nicht möglich'; -$_MODULE['<{mollie}prestashop>order_info_3efc29552025b4e68de04f415b0b8806'] = 'Rückerstattung nicht möglich'; -$_MODULE['<{mollie}prestashop>order_info_468a92810b526750be9664461db6bf91'] = 'Annullierung nicht möglich'; -$_MODULE['<{mollie}prestashop>qr_code_9ba19ddbcfeddfc758eb84fb8ba26b5e'] = 'oder scannen Sie den iDEAL QR-Code'; -$_MODULE['<{mollie}prestashop>refund_729a51874fe901b092899e9e8b31c97a'] = 'Sind Sie sicher?'; -$_MODULE['<{mollie}prestashop>refund_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Möchten Sie diese Bestellung erstatten?'; -$_MODULE['<{mollie}prestashop>refund_76f0ed934de85cc7131910b32ede7714'] = 'Zurückzahlen'; -$_MODULE['<{mollie}prestashop>refund_ea4788705e6873b424c65e91c2846b19'] = 'Abbrechen'; -$_MODULE['"<{mollie}prestashop>mollie_484f5a79672cebe198ebdde45a1d672f"'] = 'Geschenkverpackung'; -$_MODULE['<{mollie}prestashop>mollie_e0010a0a1a3259ab5c06a19bad532851'] = 'Bezahlt'; -$_MODULE['<{mollie}prestashop>mollie_a206428462686af481cb072b8db11784'] = 'Autorisiet'; -$_MODULE['<{mollie}prestashop>mollie_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Annuliert'; -$_MODULE['<{mollie}prestashop>mollie_24fe48030f7d3097d5882535b04c3fa8'] = 'Abgelaufen'; -$_MODULE['<{mollie}prestashop>mollie_cc61945cbbf46721a053467c395c666f'] = 'Zurückerstattet'; -$_MODULE['<{mollie}prestashop>mollie_7026e386bdad92fa6f232394f5b23ffb'] = 'Ãœberweisung ausstehend'; -$_MODULE['<{mollie}prestashop>mollie_9f004157e4c148dac71da3ae5906351f'] = 'Teilweise zurückerstattet'; -$_MODULE['<{mollie}prestashop>mollie_0eceeb45861f9585dd7a97a3e36f85c6'] = 'Erstellt'; -$_MODULE['<{mollie}prestashop>mollie_ea9cf7e47ff33b2be14e6dd07cbcefc6'] = 'Versand'; -$_MODULE['<{mollie}prestashop>mollie_3a6e70059673992f825826f7cf89278d'] = 'Die in diesem Warenkorb verwendete Warenkorbregel "%1s" (ID %2s) ist ungültig und wurde aus dem Warenkorb entfernt'; -$_MODULE['<{mollie}prestashop>mollie_3a1048f8aa3a9f6b604fcf7982811752'] = 'Achtung: Der Sicherheitsschlüssel ist leer. Ãœberprüfen Sie Ihr Zahlungskonto vor der Bestätigung'; -$_MODULE['<{mollie}prestashop>mollie_26beb437d3323bd4bfb0811b3e891315'] = '%d Bild(er)'; -$_MODULE['<{mollie}prestashop>mollie_0791970c961c09eb8caaa61aba6a3ca4'] = 'Beim Speichern der Nachricht ist ein Fehler aufgetreten'; -$_MODULE['<{mollie}prestashop>mollie_ed13b3693357ebed3751cb71cb639e65'] = 'Kein Spediteur'; -$_MODULE['<{mollie}prestashop>mollie_b08d3867be98e6fff3233cd40ab8134a'] = 'Erstellung der Bestellung fehlgeschlagen'; -$_MODULE['<{mollie}prestashop>mollie_43423b4056880b08f2c9aa50d8670531'] = 'Warenkorb kann nicht geladen werden oder es wurde bereits eine Bestellung mit diesem Warenkorb aufgegeben'; -$_MODULE['<{mollie}prestashop>mollie_32c86f9a2a28a9fa544b97024393633e'] = 'Keine Zahlungsarten gefunden'; -$_MODULE['<{mollie}prestashop>form_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Fehler'; -$_MODULE['<{mollie}prestashop>17_error_47e1924c444fafe9fdfce444790f0ba9'] = 'Zurück zu Ihrem Warenkorb'; -$_MODULE['<{mollie}prestashop>mollie_wait_bc0dd919f9a70dbb62f3f7afd68d6d68'] = 'Warten auf den Zahlungsstatus'; -$_MODULE['<{mollie}prestashop>order_info_2427b479f15af44582dc151ef95a90d0'] = 'Rückerstattungen sind derzeit nicht verfügbar'; -$_MODULE['<{mollie}prestashop>rounding_error_7783c757cd1177e60888080e0f4e0593'] = 'Die Konfigurationsoption "%s" wurde auf einen nicht unterstützten Wert gesetzt'; -$_MODULE['<{mollie}prestashop>rounding_error_2279522d0910767ffa75e0b39ed1629f'] = 'Der ausgewählte Rundungsmodus wird von der Mollie Orders API nicht unterstützt'; -$_MODULE['<{mollie}prestashop>rounding_error_3a92c96baa86286685b233e6912e718d'] = 'Bitte gehen Sie zur Seite "%s" und wählen Sie die Option "%s"'; -$_MODULE['<{mollie}prestashop>smarty_error_9d1fbbe0d150b89f068ba72a20366659'] = 'Die Konfigurationsoption "%s" wurde auf "%s" gesetzt.'; -$_MODULE['<{mollie}prestashop>smarty_error_27dd3bb10855eb84f48efedf6924c4c1'] = 'Dadurch ist es nicht möglich, Zahlungsarten an der Kasse aufzulisten'; -$_MODULE['<{mollie}prestashop>smarty_error_4ec23c59d832a2934277a2a040918789'] = 'Bitte gehen Sie zur Seite "%s" und wählen Sie die andere Option'; -$_MODULE['<{mollie}prestashop>smarty_error_92b67311c1a5d6cfc28ba08a1066c901'] = 'Leeren Sie anschließend den Cache noch einmal, damit die Liste der Zahlungsarten aktualisiert werden kann'; -$_MODULE['<{mollie}prestashop>smarty_warning_9d1fbbe0d150b89f068ba72a20366659'] = 'Die Konfigurationsoption "%s" wurde auf "%s" gesetzt.'; -$_MODULE['<{mollie}prestashop>smarty_warning_e7e747f9c74f0b8222c87db24d34f018'] = 'Möglicherweise können nicht alle Zahlungsarten angezeigt werden'; -$_MODULE['<{mollie}prestashop>smarty_warning_1238db0fb782f758b5a54d6333b3610e'] = 'Um dieses Problem zu beheben, navigieren Sie zur Seite "%s" und leeren Sie den Cache manuell oder wählen Sie eine der anderen Optionen aus'; +mollie_09748ce33c8a71296b20ba8c3bd1d13e'] = 'Mollie Zahlungs-Modul'; +$_MODULE['<{mollie}prestashop>mollie_95b3b272e06dcc3cc2aa62f6887aebc5'] = 'Mollie Zahlungen'; +$_MODULE['<{mollie}prestashop>mollie_48dedcf43487615c84c1bbbf6fe76c76'] = 'Sind Sie sicher, dass Sie das Mollie Zahlungs-Modul deinstallieren wollen?'; +$_MODULE['<{mollie}prestashop>mollie_ab552f085567bbe63872c10a3596cd27'] = 'Zahlungsfehler:'; +$_MODULE['<{mollie}prestashop>mollie_76e084771e78c194efd0e2d5b8920bea'] = 'bezahlt'; +$_MODULE['<{mollie}prestashop>mollie_f7d543c9b824323b84ab11668002f207'] = 'autorisiert'; +$_MODULE['<{mollie}prestashop>mollie_d5c39a1d9aced393f835f334a1fb9206'] = 'annulliert'; +$_MODULE['<{mollie}prestashop>mollie_c4bfb2a0bab0e91bc7dcfbe3bbec246e'] = 'abgelaufen'; +$_MODULE['<{mollie}prestashop>mollie_ad32204fca182b862a5f97a5534c03a2'] = 'zurückerstattet'; +$_MODULE['<{mollie}prestashop>mollie_542ba101e183aea6bc8dab5b1ec5ef7f'] = 'Ãœberweisung ausstehend'; +$_MODULE['<{mollie}prestashop>mollie_837cbb7173db2e32b3783e87597dac90'] = 'teilweise zurückerstattet'; +$_MODULE['<{mollie}prestashop>mollie_e2b7dec8fa4b498156dfee6e4c84b156'] = 'Diese Zahlungsart ist nicht verfügbar.'; +$_MODULE['<{mollie}prestashop>mollie_96d0e2862e0167af0c2fd0c99fe6bc5d'] = 'Klicken Sie hier, um fortzufahren'; +$_MODULE['<{mollie}prestashop>mollie_540d9939d1ca9406e215ee3d78c76813'] = 'Diese Zahlungsmethode ist nur für Euros verfügbar.'; +$_MODULE['<{mollie}prestashop>mollie_1b2631119333d97dbda37f87e378b1e4'] = 'Bei der Verarbeitung Ihrer Anfrage ist ein Fehler aufgetreten:'; +$_MODULE['<{mollie}prestashop>mollie_11bab828edcc0a6d5c97cbf84d61e652'] = 'Eine Bestellung mit dieser Kennung existiert nicht.'; +$_MODULE['<{mollie}prestashop>mollie_b34487c5f391f47b893ee3c61f8f9ab7'] = 'Wir haben keinen definitiven Zahlungsstatus erhalten. Sie werden informiert, sobald wir eine Bestätigung der Bank/des Händlers erhalten haben.'; +$_MODULE['<{mollie}prestashop>mollie_57bc999b3b730ead92ac7243fe254a2a'] = 'Leider ist Ihre Zahlung abgelaufen.'; +$_MODULE['<{mollie}prestashop>mollie_3602f6d5ece34fdbd4ffe0a47f1a2ba4'] = 'Vielen Dank. Wir haben Ihre Zahlung erhalten.'; +$_MODULE['<{mollie}prestashop>mollie_7352a401b3c23b2966c68bc9ab97fa06'] = 'Die Transaktion hat einen unerwarteten Status.'; +$_MODULE['<{mollie}prestashop>mollie_3f83176ddc3f63a5a374a623840bfb09'] = 'Sie sind nicht berechtigt, diese Seite anzusehen.'; +$_MODULE['<{mollie}prestashop>mollie_300225ee958b6350abc51805dab83c24'] = 'Einkauf fortsetzen'; +$_MODULE['<{mollie}prestashop>mollie_ebdf0f490b617d7efa3025d3625cec85'] = 'Willkommen zurück'; +$_MODULE['<{mollie}prestashop>mollie_66dac2278292ff24611ef8a85bc94e0d'] = 'Wählen Sie Ihre Bank aus:'; +$_MODULE['<{mollie}prestashop>mollie_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; +$_MODULE['<{mollie}prestashop>mollie_b98a07c82f0078a1de7fc219fae480fc'] = 'Andere Zahlungsmethode'; +$_MODULE['<{mollie}prestashop>mollie_35895cff7df70dab18783453e2bd241f'] = 'Zahlen mit %s'; +$_MODULE['<{mollie}prestashop>mollie_cc16e103e202a48009df202d9525f75f'] = 'Diese Bestellung räckerstatten'; +$_MODULE['<{mollie}prestashop>mollie_c5222afef6530f674d3acf82ba2ce9dc'] = 'Mollie Räckerstattung'; +$_MODULE['<{mollie}prestashop>mollie_7064b25aa8a732a3db7f230c9867be19'] = 'Bestellung #%d Ãœber die Mollie API räckerstatten.'; +$_MODULE['<{mollie}prestashop>mollie_e12682d2e0650f2783b22d956d2b947a'] = 'Dieser Bestellung wurde zurückerstattet!'; +$_MODULE['<{mollie}prestashop>mollie_95be87afb2734075cf345b633e1384ec'] = 'Mollie B.V. wird das Geld am nächsten Werktag an den Kunden zurücküberweisen.'; +$_MODULE['<{mollie}prestashop>mollie_9770d1f0124abb0d6a894cd79f8703b5'] = 'Warten auf Mollie Zahlung'; +$_MODULE['<{mollie}prestashop>mollie_b9fc80a6e775cb75568db6b6538dacdd'] = 'Mollie teilweise zurück erstattet'; +$_MODULE['<{mollie}prestashop>mollie_f91ab041fe9d6057740394b8b7903a0f'] = 'iDEAL'; +$_MODULE['<{mollie}prestashop>mollie_b749cfb52bfd82c5b12aa49d6906b8e8'] = 'CartaSi'; +$_MODULE['<{mollie}prestashop>mollie_05bfde942b997737b56b9ab405450076'] = 'Cartes Bancaires'; +$_MODULE['<{mollie}prestashop>mollie_e7f9e382dc50889098cbe56f2554c77b'] = 'Kreditkarte'; +$_MODULE['<{mollie}prestashop>mollie_870cf6bc77bbadd038aeb8d942c9cb18'] = 'Bancontact'; +$_MODULE['<{mollie}prestashop>mollie_8ad65eb3da9995173280649f090218c3'] = 'SOFORT Banking'; +$_MODULE['<{mollie}prestashop>mollie_c0db4214f9d7e1b846f4496e03e667d0'] = 'SEPA Lastschriftverfahren'; +$_MODULE['<{mollie}prestashop>mollie_5aa515ce21e8de1ed7416dce455a151f'] = 'Belfius Pay Button'; +$_MODULE['<{mollie}prestashop>mollie_d023ec040f79f1a9b2ac960b43785089'] = 'Bitcoin'; +$_MODULE['<{mollie}prestashop>mollie_4aa65ea89e54d83bb2604c2cc89babc3'] = 'PODIUM Geschenkkarte'; +$_MODULE['<{mollie}prestashop>mollie_58c25c4b8b4382e37d89e0ef6bd625cf'] = 'Gift cards'; +$_MODULE['<{mollie}prestashop>mollie_431647a0a8b2cd589c9fda9535f90d6d'] = 'Ãœberweisung'; +$_MODULE['<{mollie}prestashop>mollie_ad69e733ebae8d264bccaa38d68830e8'] = 'PayPal'; +$_MODULE['<{mollie}prestashop>mollie_6abcd8eecb4f2abb6ccfe36ef7046ba0'] = 'paysafecard'; +$_MODULE['<{mollie}prestashop>mollie_a81bd6195f1abce35fd03a870270100b'] = 'KBC/CBC Payment Button'; +$_MODULE['<{mollie}prestashop>mollie_8184c64d6318b4a42428ae21d0fe2311'] = 'ING Home\'Pay'; +$_MODULE['<{mollie}prestashop>mollie_31911306551723245e7417ae4520fecb'] = 'Giropay'; +$_MODULE['<{mollie}prestashop>mollie_ce8e4a184e2e534c09d6bf6ae773ca4a'] = 'eps'; +$_MODULE['<{mollie}prestashop>mollie_feb1a8ded87483b416427b8457bdc664'] = 'Klarna: Rechnung'; +$_MODULE['<{mollie}prestashop>mollie_a388a6fba0d4b58c334cd9416071cdb1'] = 'Klarna: Ratenkauf'; +$_MODULE['<{mollie}prestashop>mollie_d1913efa9eae51595a33f3c1410d465c'] = 'Die Methode %s wurde durch Modul %s aufgehoben. Dies kann zu Störungen im Zahlungsvorgang führen.'; +$_MODULE['<{mollie}prestashop>mollie_6311eb29dee3acc14071e0b1efb173f5'] = '%s Status:'; +$_MODULE['<{mollie}prestashop>mollie_d438a1d96c6037fccad15d7594737a84'] = 'Visuelle Einstellungen:'; +$_MODULE['<{mollie}prestashop>mollie_49259add73e416838e985a6bf4d0e571'] = 'Debug-Information:'; +$_MODULE['<{mollie}prestashop>mollie_c9cc8cce247e49bae79f15173ce97354'] = 'Speichern'; +$_MODULE['<{mollie}prestashop>mollie_5bef23eb7efff2736c5583bda59e5eb7'] = 'Erstellen Sie Ihr Konto'; +$_MODULE['<{mollie}prestashop>mollie_a77e6fc49f07414fc53336c8d879b73e'] = 'Haben Sie bereits einen API Schlüssel? Dann können Sie diesen Schritt überspringen und mit Ihrem API-Schlüssel fortfahren.'; +$_MODULE['<{mollie}prestashop>mollie_21aef67e8d12503aff027385d0a7867f'] = 'Vor- und Nachname'; +$_MODULE['<{mollie}prestashop>mollie_b357b524e740bc85b9790a0712d84a30'] = 'Email-Adresse'; +$_MODULE['<{mollie}prestashop>mollie_e93c33bd1341ab74195430daeb63db13'] = 'Shop-Name'; +$_MODULE['<{mollie}prestashop>mollie_dd7bf230fde8d4836917806aff6a6b27'] = 'Adresse'; +$_MODULE['<{mollie}prestashop>mollie_8bcdc441379cbf584638b0589a3f9adb'] = 'Postleitzahl'; +$_MODULE['<{mollie}prestashop>mollie_57d056ed0984166336b7879c2af3657f'] = 'Stadt'; +$_MODULE['<{mollie}prestashop>mollie_59716c97497eb9694541f7c3d37b1a4d'] = 'Land'; +$_MODULE['<{mollie}prestashop>mollie_686e697538050e4664636337cc3b834f'] = 'Konto erstellen'; +$_MODULE['<{mollie}prestashop>mollie_7c4e7ada50c8572336f872fced4d1852'] = 'Status für %s Zahlungen'; +$_MODULE['<{mollie}prestashop>mollie_bea3fae02ae079e541199ab6ffc2d1ad'] = '`%s` Zahlungen erhalten den Status \'%s`'; +$_MODULE['<{mollie}prestashop>mollie_b2a2c5a69af7c04c5adc48261fb5dc13'] = 'E-Mails senden, wenn %s'; +$_MODULE['<{mollie}prestashop>mollie_0511c3431d4e32ed4266fe943014d000'] = 'E-Mails senden, wenn Transaktionsstatus in %s geändert wird.'; +$_MODULE['<{mollie}prestashop>mollie_7aace0dc23ee8b74744bdf79c98a2605'] = 'Ãœberspringe diesen Status'; +$_MODULE['<{mollie}prestashop>mollie_dd59e3663865f3fab190e496260608e6'] = '`%s` Zahlungen erhalten keinen Status'; +$_MODULE['<{mollie}prestashop>mollie_824f2c1d1c2ee9aecac9977d9347a2ea'] = 'Mollie Einstellungen'; +$_MODULE['<{mollie}prestashop>mollie_d876ff8da67c3731ae25d8335a4168b4'] = 'API Schlüssel'; +$_MODULE['<{mollie}prestashop>mollie_2ffbc7eb8899865f9e66682d34853195'] = 'Sie finden Ihren API-Schlüssel in Ihrem [1] Mollie-Profil [/1]; Der Schlüssel beginnt mit Test oder Live.'; +$_MODULE['<{mollie}prestashop>mollie_b5a7adde1af5c87d7fd797b6245c2a39'] = 'Beschreibung'; +$_MODULE['<{mollie}prestashop>mollie_3150652ab7f22bafe11a78d4cc0de8be'] = 'Geben Sie hier eine Beschreibung ein. Achtung: Zahlungsmethoden können eine Beschränkung in der Anzahl der Zeichen haben, benutzten Sie nicht mehr als 29 Zeichen für die Beschreibung. Sie können die folgenden Variablen verwenden: %s'; +$_MODULE['<{mollie}prestashop>mollie_8d9143dfc520ed7d982d4e545c7bfc5e'] = 'Gebietsschema für Zahlungsbildschirm senden'; +$_MODULE['<{mollie}prestashop>mollie_1239c091f39c068882e924e34dd9cc40'] = 'Sollte das Plugin den aktuellen Webshop [1] locale [/1] an Mollie senden. Mollie Bezahlfenster werden in der gleichen Sprache wie Ihr Webshop sein. Mollie kann die Sprache auch anhand der Browsersprache des Benutzers erkennen.'; +$_MODULE['<{mollie}prestashop>mollie_80a78bb16945665b6410ae8d93e81c69'] = 'Senden Sie das Gebietsschema nicht über die Browsersprache'; +$_MODULE['<{mollie}prestashop>mollie_3ba67aae5d08d0fa90016685407926f1'] = 'Visuelle Einstellungen'; +$_MODULE['<{mollie}prestashop>mollie_fff0d600f8a0b5e19e88bfb821dd1157'] = 'Bilder'; +$_MODULE['<{mollie}prestashop>mollie_f7a97136df639501521efb243047e0cf'] = 'Zeigen Sie große, normale oder keine Zahlungsmethodenlogos beim Checkout an.'; +$_MODULE['<{mollie}prestashop>mollie_a88f05b6c963e145a45b58c47cd42a41'] = 'ausblenden'; +$_MODULE['<{mollie}prestashop>mollie_fea087517c26fadd409bd4b9dc642555'] = 'normal'; +$_MODULE['<{mollie}prestashop>mollie_d861877da56b8b4ceb35c8cbfdf65bb4'] = 'groß'; +$_MODULE['<{mollie}prestashop>mollie_85fb708f31f585607247f8b868efafcc'] = 'Ausstellerliste'; +$_MODULE['<{mollie}prestashop>mollie_27db39558366d2a9001a0dec69eea4d6'] = 'Einige Zahlungsmethoden (z. B. iDEAL) haben eine Ausstellerliste. Diese Einstellung gibt an, wo sie angezeigt wird.'; +$_MODULE['<{mollie}prestashop>mollie_85a692706bc7597b6e32bc1d354c138f'] = 'Auf Befehl'; +$_MODULE['<{mollie}prestashop>mollie_ea9b19c6f2e9ef60b49778ab9396b293'] = 'Eigene Seite'; +$_MODULE['<{mollie}prestashop>mollie_d35acbb07d2841712a937d5748e9bdc2'] = 'Zahlungsseite'; +$_MODULE['<{mollie}prestashop>mollie_1547ffc579d657d13fd5fedf12cbfae5'] = 'CSS Datei'; +$_MODULE['<{mollie}prestashop>mollie_6602513644161421f58418528d93ac00'] = 'Lassen Sie das Standard-Stylesheet leer. Sollte Dateipfad enthalten, wenn festgelegt. Tipp: Sie können [1] {BASE} [/1], [1] {THEMA} [/1], [1] {CSS} [/1], [1] {MOBILE} [/1], [1] {MOBILE_CSS} [/1] und [1] {OVERRIDE} [/1] für einfache Ordnerzuordnung.'; +$_MODULE['<{mollie}prestashop>mollie_0da8d9a75492046bea7f314521e07cae'] = 'Zahlungsarten'; +$_MODULE['<{mollie}prestashop>mollie_75886bf821fc9c068a280fe52337c0f5'] = 'Aktivieren oder deaktivieren Sie die Zahlungsmethoden. Sie können die Zahlungsmethoden per Drag & Drop verschieben.'; +$_MODULE['<{mollie}prestashop>mollie_c576349bf8ff5fba4e9369ab581a4074'] = 'Aktivieren Sie den iDEAL QR Code'; +$_MODULE['<{mollie}prestashop>mollie_c0ae4417e7a196f3ccfadff68a5064ed'] = 'iDEAL QR Code ist derzeit noch nicht in der Orders API verfügbar. Wir entschuldigen uns für die Unannehmlichkeiten.'; +$_MODULE['<{mollie}prestashop>mollie_e17dc77fb83539b6a4687c6d515791e4'] = '%s Status'; +$_MODULE['<{mollie}prestashop>mollie_b068931cc450442b63f5b3d276ea4297'] = 'Name'; +$_MODULE['<{mollie}prestashop>mollie_4695fd3a22023ab53a2151f797975ff8'] = 'Diesen Status deaktivieren'; +$_MODULE['<{mollie}prestashop>mollie_656f9fd6f874404599220855cfec17ef'] = 'Mollie API'; +$_MODULE['<{mollie}prestashop>mollie_a1532be2c9ef11d7dd5edd974fc6c98c'] = 'Wählen Sie die Mollie-API aus, die verwendet werden soll'; +$_MODULE['<{mollie}prestashop>mollie_9ce1d2272c82bfd7d501a6697df774c7'] = 'Soll das Plugin die neue Mollie Orders API verwenden? Dies schaltet Zahlungsmethoden wie Klarna Pay Later frei.'; +$_MODULE['<{mollie}prestashop>mollie_8c2b4949d892b39b236545951f10bbd4'] = 'Payments API'; +$_MODULE['<{mollie}prestashop>mollie_a8b0255f70ecc140a1b5134ae5217e51'] = 'Orders API'; +$_MODULE['<{mollie}prestashop>mollie_1191f888f0cc23f95aa77aacb094503b'] = 'Versandinformationen'; +$_MODULE['<{mollie}prestashop>mollie_d822c02513be98814bdd39f8bae598d1'] = 'Automatisch versenden, wenn als `versendet`markiert'; +$_MODULE['<{mollie}prestashop>mollie_0eccefc4c96190190add75fe0a74fcd4'] = 'Durch Aktivieren dieser Funktion wird die Versandinformation automatisch versendet, wenn eine Bestellung als `versendet` markiert ist'; +$_MODULE['<{mollie}prestashop>mollie_c1df8a5243557cbd8a7a31c11aab3db4'] = 'Automatisch versenden, wenn einer dieser Status erreicht wird'; +$_MODULE['<{mollie}prestashop>mollie_34bd91e87db36a10b9e847d6304be289'] = 'Falls eine Bestellung eine dieser Status erreicht, wird die Versandinformation automatisch versendet'; +$_MODULE['<{mollie}prestashop>mollie_498f79c4c5bbde77f1bceb6c86fd0f6d'] = 'Anzeigen'; +$_MODULE['<{mollie}prestashop>mollie_62a5e490880a92eef74f167d9dc6dca0'] = 'Verbergen'; +$_MODULE['<{mollie}prestashop>mollie_dc6e4b439165a4e104c9f3cbfcfe2797'] = 'Debug-Ebene'; +$_MODULE['<{mollie}prestashop>mollie_500aa80d6aea3cc9701b566c5f92ed91'] = 'Fehler anzeigen'; +$_MODULE['<{mollie}prestashop>mollie_37f9a8b20930c1dc7488b15872b6d36b'] = 'Wenn Sie diese Funktion aktivieren, werden Fehlermeldungen (falls vorhanden) auf der Startseite angezeigt. Nur zu Debugzwecken verwenden!'; +$_MODULE['<{mollie}prestashop>mollie_e5114c4b69585ba5883d456a74c1cd5d'] = 'Protokollierebene'; +$_MODULE['<{mollie}prestashop>mollie_921a6d905eef99631c9c73c317799e62'] = 'Empfohlene Stufe: Fehler. Wählen Sie Alle, um eingehende Webhook-Anfragen zu überwachen. [1] Protokolle anzeigen. [/1]'; +$_MODULE['<{mollie}prestashop>mollie_f80a4ad87fee7c9fdc19b7769495fdb5'] = 'Nichts'; +$_MODULE['<{mollie}prestashop>mollie_5ef0c737746fae2ca90e66c39333f8f6'] = 'Fehler'; +$_MODULE['<{mollie}prestashop>mollie_709468af25e91284821d1bdbfdded24c'] = 'Alles'; +$_MODULE['<{mollie}prestashop>mollie_7c478959c218087ffc4ad5d96e7f66a6'] = 'Mollie'; +$_MODULE['<{mollie}prestashop>mollie_1f93fc361bfc627c89a46e1b6c28df2b'] = 'Der API Schlüssel beginnt mit \'test\' oder \'live\'.'; +$_MODULE['<{mollie}prestashop>mollie_6ab1adfed768d989b47c908755fe677f'] = 'Die Konfigurierung wurde gespeichert!'; +$_MODULE['<{mollie}prestashop>mollie_1f91cd9f380285bf1219c79ab7fcb75e'] = 'Warnung: Aktualisierungsdatei konnte nicht von github abgerufen werden.'; +$_MODULE['<{mollie}prestashop>mollie_ce1e483d5cd4b349af887fa3e198ea6b'] = 'Kein Download-Paket für die neueste Version gefunden.'; +$_MODULE['<{mollie}prestashop>mollie_048ef1905ff33382d7660a68a6199305'] = 'Warnung: Update xml Datei konnte nicht von github abgerufen werden.'; +$_MODULE['<{mollie}prestashop>mollie_711d42f319398490b32cd0e2f0b8ccb8'] = 'Warnung: Update xml Datei von github folgt einem unbekanntem Format.'; +$_MODULE['<{mollie}prestashop>mollie_48fa0f621f79f451e58f200957da5b52'] = 'Wählen Sie Ihre Bank aus'; +$_MODULE['<{mollie}prestashop>mollie_8953fb7da2299bf905b73720f611baa3'] = 'oder zahlen mit dem iDEAL QR-Code'; +$_MODULE['<{mollie}prestashop>mollie_961f2247a2070bedff9f9cd8d64e2650'] = 'Wählen'; +$_MODULE['<{mollie}prestashop>mollie_ea4788705e6873b424c65e91c2846b19'] = 'Annullieren'; +$_MODULE['<{mollie}prestashop>mollie_f93bd0f858a6e5f70cb458c90a36172b'] = 'Info über die neueste Version konnte nicht abgerufen werden'; +$_MODULE['<{mollie}prestashop>mollie_ced93781bca50eb4d970ea51abcc622c'] = 'Sie haben bereits die neueste Version installiert!'; +$_MODULE['<{mollie}prestashop>mollie_43f3c5a157c67de9b6faf42b637f963a'] = 'Das Modularchiv konnte nicht heruntergeladen werden'; +$_MODULE['<{mollie}prestashop>mollie_31dd57eea0f762b4ea6f022b40acc390'] = 'Beim Extrahieren der Moduldatei ist ein Fehler aufgetreten (Datei ist möglicherweise beschädigt).'; +$_MODULE['<{mollie}prestashop>mollie_bad5a3ab102f6e9c27edd494d7e33323'] = 'Ihr neues Mollie-Konto wurde erfolgreich erstellt. Bitte überprüfen Sie Ihren Posteingang für weitere Informationen.'; +$_MODULE['<{mollie}prestashop>mollie_023b7ade110944180153fd73358fc50c'] = 'Beim Erstellen Ihres Mollie-Kontos ist ein unbekannter Fehler aufgetreten'; +$_MODULE['<{mollie}prestashop>mollie_88183b946cc5f0e8c96b2e66e1c74a7e'] = 'Unbekannt'; +$_MODULE['<{mollie}prestashop>mollie_301b87d33063f687d14004a9014f6759'] = 'Sie sind nicht berechtigt, Zahlungen zu erstatten'; +$_MODULE['<{mollie}prestashop>mollie_8dc6945fb6b59aea38df7935cf3afb6d'] = 'Sie sind nicht berechtigt, Zahlungen zu %s'; +$_MODULE['<{mollie}prestashop>mollie_1bda80f2be4d3658e0baa43fbe7ae8c1'] = 'anzeigen'; +$_MODULE['<{mollie}prestashop>mollie_de95b43bceeb4b998aed4aed5cef1ae7'] = 'bearbeiten'; +$_MODULE['<{mollie}prestashop>mollie_2a3f1166b041928019e4e8718d628665'] = 'versenden'; +$_MODULE['<{mollie}prestashop>mollie_df6f85687a0d5820baa1a069a04eff2d'] = 'Rückerstattung'; +$_MODULE['<{mollie}prestashop>mollie_10aec35353f9c4096a71c38654c3d402'] = 'annullieren'; +$_MODULE['<{mollie}prestashop>payment_c2f73af3130be4b4967a475ab846c546'] = 'Ein Fehler ist aufgetreten während Ihre Zahlung eingeleitet wurde. Bitte kontaktieren Sie unseren Kundenservice.'; +$_MODULE['<{mollie}prestashop>download_update_6de6a882c42b757cd027830399a74de4'] = 'Aktualisieren Sie dieses Modul'; +$_MODULE['<{mollie}prestashop>download_update_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Fehler'; +$_MODULE['<{mollie}prestashop>download_update_5d04a002ea59c8114f9d08b0c6250a3b'] = 'Verbindung konnte nicht hergestellt werden'; +$_MODULE['<{mollie}prestashop>download_update_3844b140df977eee8639de6d1de9e1e0'] = 'Das neue Modul konnte nicht entpackt werden'; +$_MODULE['<{mollie}prestashop>download_update_b50ec141b028d5a8acec4a17c32f3808'] = 'Das Modul wurde aktualisiert!'; +$_MODULE['<{mollie}prestashop>new_release_b7f73af7318580996a3889353b282827'] = 'Sie verwenden momentan Version %s. Wir empfehlen Ihnen dringenst, die neue Version %s! zu installieren.'; +$_MODULE['<{mollie}prestashop>form_93cba07454f06a4a960172bbd6e2a435'] = 'Ja'; +$_MODULE['<{mollie}prestashop>form_bafd7322c6e97d25b6299b5d6fe8920b'] = 'Nein'; +$_MODULE['<{mollie}prestashop>form_2d25c72c1b18e562f6654fff8e11711e'] = 'Nicht verfügbar'; +$_MODULE['<{mollie}prestashop>form_58afe6389d8f42880d1011ef0de542a2'] = 'Diese Zahlungsmethode ist in der Payments API nicht verfügbar. Wechseln Sie zu der nachfolgenden Orders API um diese Zahlungsmethode zu aktivieren.'; +$_MODULE['<{mollie}prestashop>form_9b6a88a9d4a44740f87b1ffa7cb070c4'] = 'Laden der Zahlungsmethoden nicht möglich'; +$_MODULE['<{mollie}prestashop>form_6327b4e59f58137083214a1fec358855'] = 'Erneut versuchen'; +$_MODULE['<{mollie}prestashop>form_49ee3087348e8d44e1feda1917443987'] = 'Name'; +$_MODULE['<{mollie}prestashop>form_b33f1d112cd9d2d32d37cb4cc9a340c8'] = 'Quell-URL'; +$_MODULE['<{mollie}prestashop>form_de28ef21a06f3978c05f3d808b15eaab'] = 'Zusteller URL'; +$_MODULE['<{mollie}prestashop>form_812a48ba719daeda82e4da8e812d426c'] = 'Benutzerdefinierte URL'; +$_MODULE['<{mollie}prestashop>form_e55f75a29310d7b60f7ac1d390c8ae42'] = 'Module'; +$_MODULE['<{mollie}prestashop>form_962b59a5f12eabd9c05f11b5f0aada85'] = 'Nicht automatisch versenden'; +$_MODULE['<{mollie}prestashop>form_703490ffd308d337cd5aac50567e9670'] = 'Keine Tracking-Information'; +$_MODULE['<{mollie}prestashop>form_f421a366f70bd2aa1193eeb5a2990546'] = 'Hier können Sie die Versandinformation, die Mollie mitgeteilt wird, bearbeiten'; +$_MODULE['<{mollie}prestashop>form_53b2566e3519ea98db40ae9e716883a5'] = 'Sie können die folgenden Variablen für die Zusteller URL nutzen'; +$_MODULE['<{mollie}prestashop>form_910d956cb2615e5739ac06c7f08fba26'] = 'Versandnummer'; +$_MODULE['<{mollie}prestashop>form_e7e862a02819a1610f271ffea15ed47d'] = 'Ländercode Rechnungsadresse'; +$_MODULE['<{mollie}prestashop>form_5723a18d8a8a6052a57489df5be59a8f'] = 'Postleitzahl Rechnungsadresse'; +$_MODULE['<{mollie}prestashop>form_0d12e3c554976ad1f76c5db2b6c127ad'] = 'Ländercode Versandadresse'; +$_MODULE['<{mollie}prestashop>form_c824a8b18f09dc7e58bacf446be6735c'] = 'Postleitzahl Versandadresse'; +$_MODULE['<{mollie}prestashop>form_0a867177f4a701a9f33de5ab21c42593'] = 'Sprachcode bestehend aus zwei Buchstaben'; +$_MODULE['<{mollie}prestashop>form_f6fcb64e21455abc4209f8f4440d45f5'] = 'Laden der Zusteller-Liste nicht möglich'; +$_MODULE['<{mollie}prestashop>form_da93de158db2fbe49f35f6038711584a'] = 'Diese Option wird für die derzeit gewählte API nicht benötigt'; +$_MODULE['<{mollie}prestashop>error_c453a4b8e8d98e82f35b67f433e3b4da'] = 'Zahlung'; +$_MODULE['<{mollie}prestashop>error_1e97d97a923eaddd810e056c828e99ea'] = 'Zahlungsfehler'; +$_MODULE['<{mollie}prestashop>error_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Bei der Bearbeitung Ihres Auftrags ist ein Fehler aufgetreten'; +$_MODULE['<{mollie}prestashop>error_47e1924c444fafe9fdfce444790f0ba9'] = ' Zurück zu Ihrem Einkaufswagen'; +$_MODULE['<{mollie}prestashop>mollie_issuers_588540a38eeba525f3598b68e6b788e5'] = 'oder wählen Sie eine andere Zahlungsmethode'; +$_MODULE['<{mollie}prestashop>mollie_return_ebdf0f490b617d7efa3025d3625cec85'] = 'Willkommen zurück'; +$_MODULE['<{mollie}prestashop>mollie_return_300225ee958b6350abc51805dab83c24'] = 'Einkauf fortsetzen'; +$_MODULE['<{mollie}prestashop>qr_done_92816c7248d010591f699db3aaf6287b'] = 'Mollie iDEAL-QR-Code'; +$_MODULE['<{mollie}prestashop>qr_done_ebdf0f490b617d7efa3025d3625cec85'] = 'Willkommen zurück'; +$_MODULE['<{mollie}prestashop>qr_done_4bf3a07ce980c9b007f9e2eed42d7fa2'] = 'Die Zahlung wurde storniert.'; +$_MODULE['<{mollie}prestashop>qr_done_6933c118341d8c06f888c392aa1ceaf5'] = 'Die Zahlung ist abgeschlossen. Vielen Dank für Ihre Bestellung!'; +$_MODULE['<{mollie}prestashop>ideal_dropdown_ab4147235204a436c09e00d6722082ab'] = 'Wähle eine Bank'; +$_MODULE['<{mollie}prestashop>order_info_729a51874fe901b092899e9e8b31c97a'] = 'Sind Sie sicher?'; +$_MODULE['<{mollie}prestashop>order_info_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Sind Sie sicher, dass Sie diese Bestellung zurück erstatten wollen?'; +$_MODULE['<{mollie}prestashop>order_info_76f0ed934de85cc7131910b32ede7714'] = 'Rückerstattung'; +$_MODULE['<{mollie}prestashop>order_info_ea4788705e6873b424c65e91c2846b19'] = 'Annullieren'; +$_MODULE['<{mollie}prestashop>order_info_88ba0dcbc82905637e98317e0302cfd8'] = 'Bestellung rückerstatten'; +$_MODULE['<{mollie}prestashop>order_info_5a1119ecb764165f27cb37b6f50134f2'] = 'Verbleibend'; +$_MODULE['<{mollie}prestashop>order_info_77fd2b4393b379bedd30efcd5df02090'] = 'Teilerstattung'; +$_MODULE['<{mollie}prestashop>order_info_a9ced76f2dd6907220fa95b3a136b04a'] = 'Ungültige Anzahl'; +$_MODULE['<{mollie}prestashop>order_info_3a2c3e97fed586776c2800fb7a0faf4e'] = 'Sie haben eine ungültige Summe eingegeben'; +$_MODULE['<{mollie}prestashop>order_info_3cc4859e502556d0d848c3bc38618782'] = 'Rückerstattung fehlgeschlagen'; +$_MODULE['<{mollie}prestashop>order_info_d5cfd0f69cd548e5d3b9edde5ff1b48f'] = 'Zahlungsinformation'; +$_MODULE['<{mollie}prestashop>order_info_88427ec035734b45aae9f7d8859a5008'] = 'Transaktionsnummer'; +$_MODULE['<{mollie}prestashop>order_info_782678f4ba02feb3e9ecd51e902cd16b'] = 'Historie erstatten'; +$_MODULE['<{mollie}prestashop>order_info_c5b41ae59bd6585750f536615a6bc20b'] = 'Es bestehen keine Rückerstattungen'; +$_MODULE['<{mollie}prestashop>order_info_b718adec73e04ce3ec720dd11a06a308'] = 'Nummer'; +$_MODULE['<{mollie}prestashop>order_info_44749712dbec183e983dcd78a7736c41'] = 'Datum'; +$_MODULE['<{mollie}prestashop>order_info_b2f40690858b404ed10e62bdf422c704'] = 'Betrag'; +$_MODULE['<{mollie}prestashop>order_info_53beb26d8bca00f56fbd295fdee83459'] = 'Rückerstattungen'; +$_MODULE['<{mollie}prestashop>order_info_daef64964ee3b9b904f5d467586e217f'] = 'Zahlungen'; +$_MODULE['<{mollie}prestashop>order_info_e25be354288565757726f3295e4f3ef9'] = 'Aktueller Betrag'; +$_MODULE['<{mollie}prestashop>order_info_068f80c7519d0528fb08e82137a72131'] = 'Produkte'; +$_MODULE['<{mollie}prestashop>order_info_ec53a8c4f07baed5d8825072c89799be'] = 'Status'; +$_MODULE['<{mollie}prestashop>order_info_747cf5c8587184b9e489ff897d97c20d'] = 'Verschickt'; +$_MODULE['<{mollie}prestashop>order_info_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Annulliert'; +$_MODULE['<{mollie}prestashop>order_info_cc61945cbbf46721a053467c395c666f'] = 'Erstattet'; +$_MODULE['<{mollie}prestashop>order_info_197101c4a1b1fc503dcd6ebee127aa10'] = 'Stückpreis'; +$_MODULE['<{mollie}prestashop>order_info_11cd653a2488e260a8a99f39cdffa6e7'] = 'MwSt-Betrag'; +$_MODULE['<{mollie}prestashop>order_info_bc30768048a7bbfd2d158d722c140c6d'] = 'Gesamtbetrag'; +$_MODULE['<{mollie}prestashop>order_info_0387832795db3eb2e05f4365fba5ddac'] = 'Versenden'; +$_MODULE['<{mollie}prestashop>order_info_55453aad10c96e452556a106447313bd'] = 'Versand überprüfen'; +$_MODULE['<{mollie}prestashop>order_info_dbb5bbb116e16973136b9ebd887eaadd'] = 'Bitte überprüfen Sie die Artikel die im Versand inbegriffen sind. Sie können Artikel entfernen oder die Anzahl verändern, wenn nötig.'; +$_MODULE['<{mollie}prestashop>order_info_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; +$_MODULE['<{mollie}prestashop>order_info_163bcc6065b16c6369c7a4de44cff164'] = 'Artikel versenden'; +$_MODULE['<{mollie}prestashop>order_info_433557a938a920888445ce2c7df67d5a'] = 'Details der Sendungsverfolgung'; +$_MODULE['<{mollie}prestashop>order_info_61995a579a6166642e759450a694642b'] = 'Wir empfehlen Ihnen Informationen zur Sendungsverfolgung hinzuzufügen, da dies beweist, dass Sie die Artikel wirklich versendet haben.'; +$_MODULE['<{mollie}prestashop>order_info_26b6254fefc06894825a50dfbe803937'] = 'Informationen zur Sendungsverfolgung überprüfen'; +$_MODULE['<{mollie}prestashop>order_info_d57c24f3fe52d16e7169b912dd647f0d'] = 'optional'; +$_MODULE['<{mollie}prestashop>order_info_2df417909bda5f3ddc210a0abe65231f'] = 'E.g. FedEx'; +$_MODULE['<{mollie}prestashop>order_info_593ed3a37aa1a3ece4a4d796fb4e2e03'] = 'Diese Information wird benötigt'; +$_MODULE['<{mollie}prestashop>order_info_933292561b46133ff5348c7740874c56'] = 'Sendungsverfolgungnummer'; +$_MODULE['<{mollie}prestashop>order_info_e6b391a8d2c4d45902a23a8b6585703d'] = 'URL'; +$_MODULE['<{mollie}prestashop>order_info_914419aa32f04011357d3b604a86d7eb'] = 'Zusteller'; +$_MODULE['<{mollie}prestashop>order_info_23a902ac637359fe67ceaccbe2c68283'] = 'Alles versenden'; +$_MODULE['<{mollie}prestashop>order_info_2a6e9f678c7267fe16f57bcd3285f1d7'] = 'Alles annullieren'; +$_MODULE['<{mollie}prestashop>order_info_05ced64413f9ff5d3602c3e257f36204'] = 'Alles erstatten'; +$_MODULE['<{mollie}prestashop>order_info_bfe005bff7ecacd6ecceacdd7fb79292'] = 'Transaktionsinformationen'; +$_MODULE['<{mollie}prestashop>order_info_1eefa98a18a384699fe611fbfd8ab0c9'] = 'Keine Artikel vorhanden'; +$_MODULE['<{mollie}prestashop>order_info_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Ein Fehler ist aufgetreten'; +$_MODULE['<{mollie}prestashop>order_info_2df3102f3fe061003dee820a72e1b1ed'] = 'Versand nicht möglich'; +$_MODULE['<{mollie}prestashop>order_info_3efc29552025b4e68de04f415b0b8806'] = 'Rückerstattung nicht möglich'; +$_MODULE['<{mollie}prestashop>order_info_468a92810b526750be9664461db6bf91'] = 'Annullierung nicht möglich'; +$_MODULE['<{mollie}prestashop>qr_code_9ba19ddbcfeddfc758eb84fb8ba26b5e'] = 'oder scannen Sie den iDEAL QR-Code'; +$_MODULE['<{mollie}prestashop>refund_729a51874fe901b092899e9e8b31c97a'] = 'Sind Sie sicher?'; +$_MODULE['<{mollie}prestashop>refund_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Möchten Sie diese Bestellung erstatten?'; +$_MODULE['<{mollie}prestashop>refund_76f0ed934de85cc7131910b32ede7714'] = 'Zurückzahlen'; +$_MODULE['<{mollie}prestashop>refund_ea4788705e6873b424c65e91c2846b19'] = 'Abbrechen'; +$_MODULE['"<{mollie}prestashop>mollie_484f5a79672cebe198ebdde45a1d672f"'] = 'Geschenkverpackung'; +$_MODULE['<{mollie}prestashop>mollie_e0010a0a1a3259ab5c06a19bad532851'] = 'Bezahlt'; +$_MODULE['<{mollie}prestashop>mollie_a206428462686af481cb072b8db11784'] = 'Autorisiet'; +$_MODULE['<{mollie}prestashop>mollie_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Annuliert'; +$_MODULE['<{mollie}prestashop>mollie_24fe48030f7d3097d5882535b04c3fa8'] = 'Abgelaufen'; +$_MODULE['<{mollie}prestashop>mollie_cc61945cbbf46721a053467c395c666f'] = 'Zurückerstattet'; +$_MODULE['<{mollie}prestashop>mollie_7026e386bdad92fa6f232394f5b23ffb'] = 'Ãœberweisung ausstehend'; +$_MODULE['<{mollie}prestashop>mollie_9f004157e4c148dac71da3ae5906351f'] = 'Teilweise zurückerstattet'; +$_MODULE['<{mollie}prestashop>mollie_0eceeb45861f9585dd7a97a3e36f85c6'] = 'Erstellt'; +$_MODULE['<{mollie}prestashop>mollie_ea9cf7e47ff33b2be14e6dd07cbcefc6'] = 'Versand'; +$_MODULE['<{mollie}prestashop>mollie_3a6e70059673992f825826f7cf89278d'] = 'Die in diesem Warenkorb verwendete Warenkorbregel "%1s" (ID %2s) ist ungültig und wurde aus dem Warenkorb entfernt'; +$_MODULE['<{mollie}prestashop>mollie_3a1048f8aa3a9f6b604fcf7982811752'] = 'Achtung: Der Sicherheitsschlüssel ist leer. Ãœberprüfen Sie Ihr Zahlungskonto vor der Bestätigung'; +$_MODULE['<{mollie}prestashop>mollie_26beb437d3323bd4bfb0811b3e891315'] = '%d Bild(er)'; +$_MODULE['<{mollie}prestashop>mollie_0791970c961c09eb8caaa61aba6a3ca4'] = 'Beim Speichern der Nachricht ist ein Fehler aufgetreten'; +$_MODULE['<{mollie}prestashop>mollie_ed13b3693357ebed3751cb71cb639e65'] = 'Kein Spediteur'; +$_MODULE['<{mollie}prestashop>mollie_b08d3867be98e6fff3233cd40ab8134a'] = 'Erstellung der Bestellung fehlgeschlagen'; +$_MODULE['<{mollie}prestashop>mollie_43423b4056880b08f2c9aa50d8670531'] = 'Warenkorb kann nicht geladen werden oder es wurde bereits eine Bestellung mit diesem Warenkorb aufgegeben'; +$_MODULE['<{mollie}prestashop>mollie_32c86f9a2a28a9fa544b97024393633e'] = 'Keine Zahlungsarten gefunden'; +$_MODULE['<{mollie}prestashop>form_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Fehler'; +$_MODULE['<{mollie}prestashop>17_error_47e1924c444fafe9fdfce444790f0ba9'] = 'Zurück zu Ihrem Warenkorb'; +$_MODULE['<{mollie}prestashop>mollie_wait_bc0dd919f9a70dbb62f3f7afd68d6d68'] = 'Warten auf den Zahlungsstatus'; +$_MODULE['<{mollie}prestashop>order_info_2427b479f15af44582dc151ef95a90d0'] = 'Rückerstattungen sind derzeit nicht verfügbar'; +$_MODULE['<{mollie}prestashop>rounding_error_7783c757cd1177e60888080e0f4e0593'] = 'Die Konfigurationsoption "%s" wurde auf einen nicht unterstützten Wert gesetzt'; +$_MODULE['<{mollie}prestashop>rounding_error_2279522d0910767ffa75e0b39ed1629f'] = 'Der ausgewählte Rundungsmodus wird von der Mollie Orders API nicht unterstützt'; +$_MODULE['<{mollie}prestashop>rounding_error_3a92c96baa86286685b233e6912e718d'] = 'Bitte gehen Sie zur Seite "%s" und wählen Sie die Option "%s"'; +$_MODULE['<{mollie}prestashop>smarty_error_9d1fbbe0d150b89f068ba72a20366659'] = 'Die Konfigurationsoption "%s" wurde auf "%s" gesetzt.'; +$_MODULE['<{mollie}prestashop>smarty_error_27dd3bb10855eb84f48efedf6924c4c1'] = 'Dadurch ist es nicht möglich, Zahlungsarten an der Kasse aufzulisten'; +$_MODULE['<{mollie}prestashop>smarty_error_4ec23c59d832a2934277a2a040918789'] = 'Bitte gehen Sie zur Seite "%s" und wählen Sie die andere Option'; +$_MODULE['<{mollie}prestashop>smarty_error_92b67311c1a5d6cfc28ba08a1066c901'] = 'Leeren Sie anschließend den Cache noch einmal, damit die Liste der Zahlungsarten aktualisiert werden kann'; +$_MODULE['<{mollie}prestashop>smarty_warning_9d1fbbe0d150b89f068ba72a20366659'] = 'Die Konfigurationsoption "%s" wurde auf "%s" gesetzt.'; +$_MODULE['<{mollie}prestashop>smarty_warning_e7e747f9c74f0b8222c87db24d34f018'] = 'Möglicherweise können nicht alle Zahlungsarten angezeigt werden'; +$_MODULE['<{mollie}prestashop>smarty_warning_1238db0fb782f758b5a54d6333b3610e'] = 'Um dieses Problem zu beheben, navigieren Sie zur Seite "%s" und leeren Sie den Cache manuell oder wählen Sie eine der anderen Optionen aus'; diff --git a/translations/en.php b/translations/en.php index 3b960c429..e5a4f47ee 100644 --- a/translations/en.php +++ b/translations/en.php @@ -1,273 +1,273 @@ -mollie_484f5a79672cebe198ebdde45a1d672f'] = 'Gift wrapping'; -$_MODULE['<{mollie}prestashop>mollie_7c478959c218087ffc4ad5d96e7f66a6'] = 'Mollie'; -$_MODULE['<{mollie}prestashop>mollie_95b3b272e06dcc3cc2aa62f6887aebc5'] = 'Mollie Payments'; -$_MODULE['<{mollie}prestashop>mollie_48dedcf43487615c84c1bbbf6fe76c76'] = 'Are you sure you want to uninstall the Mollie Payment Module?'; -$_MODULE['<{mollie}prestashop>mollie_ab552f085567bbe63872c10a3596cd27'] = 'Payment error:'; -$_MODULE['<{mollie}prestashop>mollie_e0010a0a1a3259ab5c06a19bad532851'] = 'Paid'; -$_MODULE['<{mollie}prestashop>mollie_a206428462686af481cb072b8db11784'] = 'Authorized'; -$_MODULE['<{mollie}prestashop>mollie_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Canceled'; -$_MODULE['<{mollie}prestashop>mollie_24fe48030f7d3097d5882535b04c3fa8'] = 'Expired'; -$_MODULE['<{mollie}prestashop>mollie_cc61945cbbf46721a053467c395c666f'] = 'Refunded'; -$_MODULE['<{mollie}prestashop>mollie_7026e386bdad92fa6f232394f5b23ffb'] = 'Bankwire pending'; -$_MODULE['<{mollie}prestashop>mollie_9f004157e4c148dac71da3ae5906351f'] = 'Partially refunded'; -$_MODULE['<{mollie}prestashop>mollie_0eceeb45861f9585dd7a97a3e36f85c6'] = 'Created'; -$_MODULE['<{mollie}prestashop>mollie_e2b7dec8fa4b498156dfee6e4c84b156'] = 'This payment method is not available.'; -$_MODULE['<{mollie}prestashop>mollie_96d0e2862e0167af0c2fd0c99fe6bc5d'] = 'Click here to continue'; -$_MODULE['<{mollie}prestashop>mollie_540d9939d1ca9406e215ee3d78c76813'] = 'This payment method is only available for Euros.'; -$_MODULE['<{mollie}prestashop>mollie_1b2631119333d97dbda37f87e378b1e4'] = 'There was an error while processing your request:'; -$_MODULE['<{mollie}prestashop>mollie_11bab828edcc0a6d5c97cbf84d61e652'] = 'The order with this id does not exist.'; -$_MODULE['<{mollie}prestashop>mollie_b34487c5f391f47b893ee3c61f8f9ab7'] = 'We have not received a definite payment status. You will be notified as soon as we receive a confirmation of the bank/merchant.'; -$_MODULE['<{mollie}prestashop>mollie_57bc999b3b730ead92ac7243fe254a2a'] = 'Unfortunately your payment was expired.'; -$_MODULE['<{mollie}prestashop>mollie_3602f6d5ece34fdbd4ffe0a47f1a2ba4'] = 'Thank you. Your payment has been received.'; -$_MODULE['<{mollie}prestashop>mollie_7352a401b3c23b2966c68bc9ab97fa06'] = 'The transaction has an unexpected status.'; -$_MODULE['<{mollie}prestashop>mollie_3f83176ddc3f63a5a374a623840bfb09'] = 'You are not authorised to see this page.'; -$_MODULE['<{mollie}prestashop>mollie_300225ee958b6350abc51805dab83c24'] = 'Continue shopping'; -$_MODULE['<{mollie}prestashop>mollie_ebdf0f490b617d7efa3025d3625cec85'] = 'Welcome back'; -$_MODULE['<{mollie}prestashop>mollie_66dac2278292ff24611ef8a85bc94e0d'] = 'Select your bank:'; -$_MODULE['<{mollie}prestashop>mollie_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; -$_MODULE['<{mollie}prestashop>mollie_b98a07c82f0078a1de7fc219fae480fc'] = 'Different payment method'; -$_MODULE['<{mollie}prestashop>mollie_35895cff7df70dab18783453e2bd241f'] = 'Pay with %s'; -$_MODULE['<{mollie}prestashop>mollie_cc16e103e202a48009df202d9525f75f'] = 'Refund this order'; -$_MODULE['<{mollie}prestashop>mollie_c5222afef6530f674d3acf82ba2ce9dc'] = 'Mollie refund'; -$_MODULE['<{mollie}prestashop>mollie_7064b25aa8a732a3db7f230c9867be19'] = 'Refund order #%d through the Mollie API.'; -$_MODULE['<{mollie}prestashop>mollie_e12682d2e0650f2783b22d956d2b947a'] = 'The order has been refunded!'; -$_MODULE['<{mollie}prestashop>mollie_95be87afb2734075cf345b633e1384ec'] = 'Mollie B.V. will transfer the money back to the customer on the next business day.'; -$_MODULE['<{mollie}prestashop>mollie_9770d1f0124abb0d6a894cd79f8703b5'] = 'Awaiting Mollie payment'; -$_MODULE['<{mollie}prestashop>mollie_b9fc80a6e775cb75568db6b6538dacdd'] = 'Mollie partially refunded'; -$_MODULE['<{mollie}prestashop>mollie_f91ab041fe9d6057740394b8b7903a0f'] = 'iDEAL'; -$_MODULE['<{mollie}prestashop>mollie_b749cfb52bfd82c5b12aa49d6906b8e8'] = 'CartaSi'; -$_MODULE['<{mollie}prestashop>mollie_05bfde942b997737b56b9ab405450076'] = 'Cartes Bancaires'; -$_MODULE['<{mollie}prestashop>mollie_e7f9e382dc50889098cbe56f2554c77b'] = 'Credit card'; -$_MODULE['<{mollie}prestashop>mollie_870cf6bc77bbadd038aeb8d942c9cb18'] = 'Bancontact'; -$_MODULE['<{mollie}prestashop>mollie_8ad65eb3da9995173280649f090218c3'] = 'SOFORT Banking'; -$_MODULE['<{mollie}prestashop>mollie_c0db4214f9d7e1b846f4496e03e667d0'] = 'SEPA Direct Debit'; -$_MODULE['<{mollie}prestashop>mollie_5aa515ce21e8de1ed7416dce455a151f'] = 'Belfius Pay Button'; -$_MODULE['<{mollie}prestashop>mollie_d023ec040f79f1a9b2ac960b43785089'] = 'Bitcoin'; -$_MODULE['<{mollie}prestashop>mollie_4aa65ea89e54d83bb2604c2cc89babc3'] = 'PODIUM Cadeaukaart'; -$_MODULE['<{mollie}prestashop>mollie_58c25c4b8b4382e37d89e0ef6bd625cf'] = 'Gift cards'; -$_MODULE['<{mollie}prestashop>mollie_431647a0a8b2cd589c9fda9535f90d6d'] = 'Bank transfer'; -$_MODULE['<{mollie}prestashop>mollie_ad69e733ebae8d264bccaa38d68830e8'] = 'PayPal'; -$_MODULE['<{mollie}prestashop>mollie_6abcd8eecb4f2abb6ccfe36ef7046ba0'] = 'paysafecard'; -$_MODULE['<{mollie}prestashop>mollie_a81bd6195f1abce35fd03a870270100b'] = 'KBC/CBC Payment Button'; -$_MODULE['<{mollie}prestashop>mollie_8184c64d6318b4a42428ae21d0fe2311'] = 'ING Home\'Pay'; -$_MODULE['<{mollie}prestashop>mollie_31911306551723245e7417ae4520fecb'] = 'Giropay'; -$_MODULE['<{mollie}prestashop>mollie_ce8e4a184e2e534c09d6bf6ae773ca4a'] = 'eps'; -$_MODULE['<{mollie}prestashop>mollie_feb1a8ded87483b416427b8457bdc664'] = 'Pay later.'; -$_MODULE['<{mollie}prestashop>mollie_a388a6fba0d4b58c334cd9416071cdb1'] = 'Slice it.'; -$_MODULE['<{mollie}prestashop>mollie_d1913efa9eae51595a33f3c1410d465c'] = 'The method %s is overridden by module %s. This can cause interference with payments.'; -$_MODULE['<{mollie}prestashop>mollie_6311eb29dee3acc14071e0b1efb173f5'] = '%s statuses:'; -$_MODULE['<{mollie}prestashop>mollie_d438a1d96c6037fccad15d7594737a84'] = 'Visual settings:'; -$_MODULE['<{mollie}prestashop>mollie_49259add73e416838e985a6bf4d0e571'] = 'Debug info:'; -$_MODULE['<{mollie}prestashop>mollie_c9cc8cce247e49bae79f15173ce97354'] = 'Save'; -$_MODULE['<{mollie}prestashop>mollie_5bef23eb7efff2736c5583bda59e5eb7'] = 'Create your account'; -$_MODULE['<{mollie}prestashop>mollie_a77e6fc49f07414fc53336c8d879b73e'] = 'Do you already have an API Key? Then you can skip this step and proceed to entering your API key.'; -$_MODULE['<{mollie}prestashop>mollie_21aef67e8d12503aff027385d0a7867f'] = 'First and last name'; -$_MODULE['<{mollie}prestashop>mollie_b357b524e740bc85b9790a0712d84a30'] = 'Email address'; -$_MODULE['<{mollie}prestashop>mollie_e93c33bd1341ab74195430daeb63db13'] = 'Shop name'; -$_MODULE['<{mollie}prestashop>mollie_dd7bf230fde8d4836917806aff6a6b27'] = 'Address'; -$_MODULE['<{mollie}prestashop>mollie_8bcdc441379cbf584638b0589a3f9adb'] = 'Postcode'; -$_MODULE['<{mollie}prestashop>mollie_57d056ed0984166336b7879c2af3657f'] = 'City'; -$_MODULE['<{mollie}prestashop>mollie_59716c97497eb9694541f7c3d37b1a4d'] = 'Country'; -$_MODULE['<{mollie}prestashop>mollie_686e697538050e4664636337cc3b834f'] = 'Create'; -$_MODULE['<{mollie}prestashop>mollie_7c4e7ada50c8572336f872fced4d1852'] = 'Status for %s payments'; -$_MODULE['<{mollie}prestashop>mollie_bea3fae02ae079e541199ab6ffc2d1ad'] = '`%s` payments get status `%s`'; -$_MODULE['<{mollie}prestashop>mollie_b2a2c5a69af7c04c5adc48261fb5dc13'] = 'Send mails when %s'; -$_MODULE['<{mollie}prestashop>mollie_0511c3431d4e32ed4266fe943014d000'] = 'Send mails when transaction status becomes %s?'; -$_MODULE['<{mollie}prestashop>mollie_7aace0dc23ee8b74744bdf79c98a2605'] = 'Skip this status'; -$_MODULE['<{mollie}prestashop>mollie_dd59e3663865f3fab190e496260608e6'] = '`%s` payments do not get a status'; -$_MODULE['<{mollie}prestashop>mollie_824f2c1d1c2ee9aecac9977d9347a2ea'] = 'Mollie Settings'; -$_MODULE['<{mollie}prestashop>mollie_d876ff8da67c3731ae25d8335a4168b4'] = 'API Key'; -$_MODULE['<{mollie}prestashop>mollie_2ffbc7eb8899865f9e66682d34853195'] = 'You can find your API key in your [1]Mollie Profile[/1]; it starts with test or live.'; -$_MODULE['<{mollie}prestashop>mollie_b5a7adde1af5c87d7fd797b6245c2a39'] = 'Description'; -$_MODULE['<{mollie}prestashop>mollie_3150652ab7f22bafe11a78d4cc0de8be'] = 'Enter a description here. Note: Payment methods may have a character limit, best keep the description under 29 characters. You can use the following variables: %s'; -$_MODULE['<{mollie}prestashop>mollie_8d9143dfc520ed7d982d4e545c7bfc5e'] = 'Send locale for payment screen'; -$_MODULE['<{mollie}prestashop>mollie_1239c091f39c068882e924e34dd9cc40'] = 'Should the plugin send the current webshop [1]locale[/1] to Mollie. Mollie payment screens will be in the same language as your webshop. Mollie can also detect the language based on the user\'s browser language.'; -$_MODULE['<{mollie}prestashop>mollie_80a78bb16945665b6410ae8d93e81c69'] = 'Do not send locale using browser language'; -$_MODULE['<{mollie}prestashop>mollie_3ba67aae5d08d0fa90016685407926f1'] = 'Visual Settings'; -$_MODULE['<{mollie}prestashop>mollie_fff0d600f8a0b5e19e88bfb821dd1157'] = 'Images'; -$_MODULE['<{mollie}prestashop>mollie_f7a97136df639501521efb243047e0cf'] = 'Show big, normal or no payment method logos on checkout.'; -$_MODULE['<{mollie}prestashop>mollie_a88f05b6c963e145a45b58c47cd42a41'] = 'hide'; -$_MODULE['<{mollie}prestashop>mollie_fea087517c26fadd409bd4b9dc642555'] = 'normal'; -$_MODULE['<{mollie}prestashop>mollie_d861877da56b8b4ceb35c8cbfdf65bb4'] = 'big'; -$_MODULE['<{mollie}prestashop>mollie_85fb708f31f585607247f8b868efafcc'] = 'Issuer list'; -$_MODULE['<{mollie}prestashop>mollie_27db39558366d2a9001a0dec69eea4d6'] = 'Some payment methods (eg. iDEAL) have an issuer list. This setting specifies where it is shown.'; -$_MODULE['<{mollie}prestashop>mollie_85a692706bc7597b6e32bc1d354c138f'] = 'On click'; -$_MODULE['<{mollie}prestashop>mollie_ea9b19c6f2e9ef60b49778ab9396b293'] = 'Own page'; -$_MODULE['<{mollie}prestashop>mollie_d35acbb07d2841712a937d5748e9bdc2'] = 'Payment page'; -$_MODULE['<{mollie}prestashop>mollie_1547ffc579d657d13fd5fedf12cbfae5'] = 'CSS file'; -$_MODULE['<{mollie}prestashop>mollie_6602513644161421f58418528d93ac00'] = 'Leave empty for default stylesheet. Should include file path when set. Hint: You can use [1]{BASE}[/1], [1]{THEME}[/1], [1]{CSS}[/1], [1]{MOBILE}[/1], [1]{MOBILE_CSS}[/1] and [1]{OVERRIDE}[/1] for easy folder mapping.'; -$_MODULE['<{mollie}prestashop>mollie_0da8d9a75492046bea7f314521e07cae'] = 'Payment methods'; -$_MODULE['<{mollie}prestashop>mollie_75886bf821fc9c068a280fe52337c0f5'] = 'Enable or disable the payment methods. You can drag and drop to rearrange the payment methods.'; -$_MODULE['<{mollie}prestashop>mollie_c576349bf8ff5fba4e9369ab581a4074'] = 'Enable iDEAL QR'; -$_MODULE['<{mollie}prestashop>mollie_c0ae4417e7a196f3ccfadff68a5064ed'] = 'QR Codes are currently not supported by the Orders API. Our apologies for the inconvenience!'; -$_MODULE['<{mollie}prestashop>mollie_e17dc77fb83539b6a4687c6d515791e4'] = '%s statuses'; -$_MODULE['<{mollie}prestashop>mollie_4695fd3a22023ab53a2151f797975ff8'] = 'Disable this status'; -$_MODULE['<{mollie}prestashop>mollie_656f9fd6f874404599220855cfec17ef'] = 'Mollie API'; -$_MODULE['<{mollie}prestashop>mollie_a1532be2c9ef11d7dd5edd974fc6c98c'] = 'Select which Mollie API to use'; -$_MODULE['<{mollie}prestashop>mollie_9ce1d2272c82bfd7d501a6697df774c7'] = 'Should the plugin use the new Mollie Orders API? This enables payment methods such as Klarna Pay Later.'; -$_MODULE['<{mollie}prestashop>mollie_8c2b4949d892b39b236545951f10bbd4'] = 'Payments API'; -$_MODULE['<{mollie}prestashop>mollie_a8b0255f70ecc140a1b5134ae5217e51'] = 'Orders API'; -$_MODULE['<{mollie}prestashop>mollie_1191f888f0cc23f95aa77aacb094503b'] = 'Shipment information'; -$_MODULE['<{mollie}prestashop>mollie_d822c02513be98814bdd39f8bae598d1'] = 'Automatically ship when marked as `shipped`'; -$_MODULE['<{mollie}prestashop>mollie_0eccefc4c96190190add75fe0a74fcd4'] = 'Enabling this feature will automatically send shipment information when an order has been marked as `shipped`'; -$_MODULE['<{mollie}prestashop>mollie_c1df8a5243557cbd8a7a31c11aab3db4'] = 'Automatically ship when one of these statuses is reached'; -$_MODULE['<{mollie}prestashop>mollie_34bd91e87db36a10b9e847d6304be289'] = 'If an order reaches one of these statuses the module will automatically send shipment information'; -$_MODULE['<{mollie}prestashop>mollie_498f79c4c5bbde77f1bceb6c86fd0f6d'] = 'Show'; -$_MODULE['<{mollie}prestashop>mollie_62a5e490880a92eef74f167d9dc6dca0'] = 'Hide'; -$_MODULE['<{mollie}prestashop>mollie_dc6e4b439165a4e104c9f3cbfcfe2797'] = 'Debug level'; -$_MODULE['<{mollie}prestashop>mollie_500aa80d6aea3cc9701b566c5f92ed91'] = 'Display errors'; -$_MODULE['<{mollie}prestashop>mollie_37f9a8b20930c1dc7488b15872b6d36b'] = 'Enabling this feature will display error messages (if any) on the front page. Use for debug purposes only!'; -$_MODULE['<{mollie}prestashop>mollie_e5114c4b69585ba5883d456a74c1cd5d'] = 'Log level'; -$_MODULE['<{mollie}prestashop>mollie_921a6d905eef99631c9c73c317799e62'] = 'Recommended level: Errors. Set to Everything to monitor incoming webhook requests. [1]View logs.[/1]'; -$_MODULE['<{mollie}prestashop>mollie_f80a4ad87fee7c9fdc19b7769495fdb5'] = 'Nothing'; -$_MODULE['<{mollie}prestashop>mollie_5ef0c737746fae2ca90e66c39333f8f6'] = 'Errors'; -$_MODULE['<{mollie}prestashop>mollie_709468af25e91284821d1bdbfdded24c'] = 'Everything'; -$_MODULE['<{mollie}prestashop>mollie_1f93fc361bfc627c89a46e1b6c28df2b'] = 'The API key needs to start with test or live.'; -$_MODULE['<{mollie}prestashop>mollie_6ab1adfed768d989b47c908755fe677f'] = 'The configuration has been saved!'; -$_MODULE['<{mollie}prestashop>mollie_1f91cd9f380285bf1219c79ab7fcb75e'] = 'Warning: Could not retrieve update file from github.'; -$_MODULE['<{mollie}prestashop>mollie_ce1e483d5cd4b349af887fa3e198ea6b'] = 'No download package found for the latest release.'; -$_MODULE['<{mollie}prestashop>mollie_048ef1905ff33382d7660a68a6199305'] = 'Warning: Could not retrieve update xml file from github.'; -$_MODULE['<{mollie}prestashop>mollie_711d42f319398490b32cd0e2f0b8ccb8'] = 'Warning: Update xml file from github follows an unexpected format.'; -$_MODULE['<{mollie}prestashop>mollie_48fa0f621f79f451e58f200957da5b52'] = 'Choose your bank'; -$_MODULE['<{mollie}prestashop>mollie_8953fb7da2299bf905b73720f611baa3'] = 'or pay by iDEAL QR'; -$_MODULE['<{mollie}prestashop>mollie_961f2247a2070bedff9f9cd8d64e2650'] = 'Choose'; -$_MODULE['<{mollie}prestashop>mollie_ea4788705e6873b424c65e91c2846b19'] = 'Cancel'; -$_MODULE['<{mollie}prestashop>mollie_ea9cf7e47ff33b2be14e6dd07cbcefc6'] = 'Shipping'; -$_MODULE['<{mollie}prestashop>mollie_f93bd0f858a6e5f70cb458c90a36172b'] = 'Unable to retieve info about the latest version'; -$_MODULE['<{mollie}prestashop>mollie_ced93781bca50eb4d970ea51abcc622c'] = 'You are already running the latest version!'; -$_MODULE['<{mollie}prestashop>mollie_43f3c5a157c67de9b6faf42b637f963a'] = 'Module archive could not be downloaded'; -$_MODULE['<{mollie}prestashop>mollie_31dd57eea0f762b4ea6f022b40acc390'] = 'There was an error while extracting the module file (file may be corrupted).'; -$_MODULE['<{mollie}prestashop>mollie_bad5a3ab102f6e9c27edd494d7e33323'] = 'Successfully created your new Mollie account. Please check your inbox for more information.'; -$_MODULE['<{mollie}prestashop>mollie_023b7ade110944180153fd73358fc50c'] = 'An unknown error occurred while trying to create your Mollie account'; -$_MODULE['<{mollie}prestashop>mollie_3a6e70059673992f825826f7cf89278d'] = 'The cart rule named \"%1s\" (ID %2s) used in this cart is not valid and has been withdrawn from cart'; -$_MODULE['<{mollie}prestashop>mollie_3a1048f8aa3a9f6b604fcf7982811752'] = 'Warning: the secure key is empty, check your payment account before validation'; -$_MODULE['<{mollie}prestashop>mollie_26beb437d3323bd4bfb0811b3e891315'] = '%d image(s)'; -$_MODULE['<{mollie}prestashop>mollie_0791970c961c09eb8caaa61aba6a3ca4'] = 'An error occurred while saving message'; -$_MODULE['<{mollie}prestashop>mollie_ed13b3693357ebed3751cb71cb639e65'] = 'No carrier'; -$_MODULE['<{mollie}prestashop>mollie_b08d3867be98e6fff3233cd40ab8134a'] = 'Order creation failed'; -$_MODULE['<{mollie}prestashop>mollie_43423b4056880b08f2c9aa50d8670531'] = 'Cart cannot be loaded or an order has already been placed using this cart'; -$_MODULE['<{mollie}prestashop>mollie_88183b946cc5f0e8c96b2e66e1c74a7e'] = 'Unknown'; -$_MODULE['<{mollie}prestashop>mollie_32c86f9a2a28a9fa544b97024393633e'] = 'No payment methods found'; -$_MODULE['<{mollie}prestashop>mollie_301b87d33063f687d14004a9014f6759'] = 'You do not have permission to refund payments'; -$_MODULE['<{mollie}prestashop>mollie_8dc6945fb6b59aea38df7935cf3afb6d'] = 'You do not have permission to %s payments'; -$_MODULE['<{mollie}prestashop>mollie_1bda80f2be4d3658e0baa43fbe7ae8c1'] = 'view'; -$_MODULE['<{mollie}prestashop>mollie_de95b43bceeb4b998aed4aed5cef1ae7'] = 'edit'; -$_MODULE['<{mollie}prestashop>mollie_2a3f1166b041928019e4e8718d628665'] = 'ship'; -$_MODULE['<{mollie}prestashop>mollie_df6f85687a0d5820baa1a069a04eff2d'] = 'refund'; -$_MODULE['<{mollie}prestashop>mollie_10aec35353f9c4096a71c38654c3d402'] = 'cancel'; -$_MODULE['<{mollie}prestashop>payment_c2f73af3130be4b4967a475ab846c546'] = 'An error occurred while initializing your payment. Please contact our customer support.'; -$_MODULE['<{mollie}prestashop>download_update_6de6a882c42b757cd027830399a74de4'] = 'Update this module'; -$_MODULE['<{mollie}prestashop>download_update_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Error'; -$_MODULE['<{mollie}prestashop>download_update_5d04a002ea59c8114f9d08b0c6250a3b'] = 'Unable to connect'; -$_MODULE['<{mollie}prestashop>download_update_3844b140df977eee8639de6d1de9e1e0'] = 'Unable to unzip new module'; -$_MODULE['<{mollie}prestashop>download_update_b50ec141b028d5a8acec4a17c32f3808'] = 'The module has been updated!'; -$_MODULE['<{mollie}prestashop>new_release_b7f73af7318580996a3889353b282827'] = 'You are currently using version %s. We strongly recommend you to upgrade to the new version %s!'; -$_MODULE['<{mollie}prestashop>form_93cba07454f06a4a960172bbd6e2a435'] = 'Yes'; -$_MODULE['<{mollie}prestashop>form_bafd7322c6e97d25b6299b5d6fe8920b'] = 'No'; -$_MODULE['<{mollie}prestashop>form_2d25c72c1b18e562f6654fff8e11711e'] = 'Not available'; -$_MODULE['<{mollie}prestashop>form_58afe6389d8f42880d1011ef0de542a2'] = 'This payment method is not available on the Payments API. Switch to the Orders API below in order to activate this method.'; -$_MODULE['<{mollie}prestashop>form_9b6a88a9d4a44740f87b1ffa7cb070c4'] = 'Unable to load payment methods'; -$_MODULE['<{mollie}prestashop>form_6327b4e59f58137083214a1fec358855'] = 'Retry'; -$_MODULE['<{mollie}prestashop>form_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Error'; -$_MODULE['<{mollie}prestashop>form_49ee3087348e8d44e1feda1917443987'] = 'Name'; -$_MODULE['<{mollie}prestashop>form_b33f1d112cd9d2d32d37cb4cc9a340c8'] = 'URL Source'; -$_MODULE['<{mollie}prestashop>form_de28ef21a06f3978c05f3d808b15eaab'] = 'Carrier URL'; -$_MODULE['<{mollie}prestashop>form_812a48ba719daeda82e4da8e812d426c'] = 'Custom URL'; -$_MODULE['<{mollie}prestashop>form_e55f75a29310d7b60f7ac1d390c8ae42'] = 'Module'; -$_MODULE['<{mollie}prestashop>form_962b59a5f12eabd9c05f11b5f0aada85'] = 'Do not automatically ship'; -$_MODULE['<{mollie}prestashop>form_703490ffd308d337cd5aac50567e9670'] = 'No tracking information'; -$_MODULE['<{mollie}prestashop>form_f421a366f70bd2aa1193eeb5a2990546'] = 'Here you can configure what information about the shipment is sent to Mollie'; -$_MODULE['<{mollie}prestashop>form_53b2566e3519ea98db40ae9e716883a5'] = 'You can use the following variables for the Carrier URLs'; -$_MODULE['<{mollie}prestashop>form_910d956cb2615e5739ac06c7f08fba26'] = 'Shipping number'; -$_MODULE['<{mollie}prestashop>form_e7e862a02819a1610f271ffea15ed47d'] = 'Billing country code'; -$_MODULE['<{mollie}prestashop>form_5723a18d8a8a6052a57489df5be59a8f'] = 'Billing postcode'; -$_MODULE['<{mollie}prestashop>form_0d12e3c554976ad1f76c5db2b6c127ad'] = 'Shipping country code'; -$_MODULE['<{mollie}prestashop>form_c824a8b18f09dc7e58bacf446be6735c'] = 'Shipping postcode'; -$_MODULE['<{mollie}prestashop>form_0a867177f4a701a9f33de5ab21c42593'] = '2-letter language code'; -$_MODULE['<{mollie}prestashop>form_f6fcb64e21455abc4209f8f4440d45f5'] = 'Unable to load carrier list'; -$_MODULE['<{mollie}prestashop>form_da93de158db2fbe49f35f6038711584a'] = 'This option is not required for the currently selected API'; -$_MODULE['<{mollie}prestashop>17_error_47e1924c444fafe9fdfce444790f0ba9'] = 'Back to your shopping cart'; -$_MODULE['<{mollie}prestashop>error_c453a4b8e8d98e82f35b67f433e3b4da'] = 'Payment'; -$_MODULE['<{mollie}prestashop>error_1e97d97a923eaddd810e056c828e99ea'] = 'Payment error'; -$_MODULE['<{mollie}prestashop>error_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'An error occurred'; -$_MODULE['<{mollie}prestashop>error_47e1924c444fafe9fdfce444790f0ba9'] = 'Back to your shopping cart'; -$_MODULE['<{mollie}prestashop>mollie_issuers_588540a38eeba525f3598b68e6b788e5'] = 'or choose a different payment method'; -$_MODULE['<{mollie}prestashop>mollie_return_ebdf0f490b617d7efa3025d3625cec85'] = 'Welcome back'; -$_MODULE['<{mollie}prestashop>mollie_return_300225ee958b6350abc51805dab83c24'] = 'Continue shopping'; -$_MODULE['<{mollie}prestashop>mollie_wait_bc0dd919f9a70dbb62f3f7afd68d6d68'] = 'Awaiting payment status'; -$_MODULE['<{mollie}prestashop>qr_done_92816c7248d010591f699db3aaf6287b'] = 'Mollie iDEAL QR'; -$_MODULE['<{mollie}prestashop>qr_done_ebdf0f490b617d7efa3025d3625cec85'] = 'Welcome back'; -$_MODULE['<{mollie}prestashop>qr_done_4bf3a07ce980c9b007f9e2eed42d7fa2'] = 'The payment has been canceled.'; -$_MODULE['<{mollie}prestashop>qr_done_6933c118341d8c06f888c392aa1ceaf5'] = 'The payment has been completed. Thank you for your order!'; -$_MODULE['<{mollie}prestashop>ideal_dropdown_ab4147235204a436c09e00d6722082ab'] = 'Choose a bank'; -$_MODULE['<{mollie}prestashop>order_info_729a51874fe901b092899e9e8b31c97a'] = 'Are you sure?'; -$_MODULE['<{mollie}prestashop>order_info_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Are you sure you want to refund this order?'; -$_MODULE['<{mollie}prestashop>order_info_76f0ed934de85cc7131910b32ede7714'] = 'Refund'; -$_MODULE['<{mollie}prestashop>order_info_ea4788705e6873b424c65e91c2846b19'] = 'Cancel'; -$_MODULE['<{mollie}prestashop>order_info_88ba0dcbc82905637e98317e0302cfd8'] = 'Refund order'; -$_MODULE['<{mollie}prestashop>order_info_5a1119ecb764165f27cb37b6f50134f2'] = 'Remaining'; -$_MODULE['<{mollie}prestashop>order_info_77fd2b4393b379bedd30efcd5df02090'] = 'Partial refund'; -$_MODULE['<{mollie}prestashop>order_info_a9ced76f2dd6907220fa95b3a136b04a'] = 'Invalid amount'; -$_MODULE['<{mollie}prestashop>order_info_3a2c3e97fed586776c2800fb7a0faf4e'] = 'You have entered an invalid amount'; -$_MODULE['<{mollie}prestashop>order_info_3cc4859e502556d0d848c3bc38618782'] = 'Refund failed'; -$_MODULE['<{mollie}prestashop>order_info_d5cfd0f69cd548e5d3b9edde5ff1b48f'] = 'Payment info'; -$_MODULE['<{mollie}prestashop>order_info_88427ec035734b45aae9f7d8859a5008'] = 'Transaction ID'; -$_MODULE['<{mollie}prestashop>order_info_782678f4ba02feb3e9ecd51e902cd16b'] = 'Refund history'; -$_MODULE['<{mollie}prestashop>order_info_c5b41ae59bd6585750f536615a6bc20b'] = 'There are no refunds'; -$_MODULE['<{mollie}prestashop>order_info_b718adec73e04ce3ec720dd11a06a308'] = 'ID'; -$_MODULE['<{mollie}prestashop>order_info_44749712dbec183e983dcd78a7736c41'] = 'Date'; -$_MODULE['<{mollie}prestashop>order_info_b2f40690858b404ed10e62bdf422c704'] = 'Amount'; -$_MODULE['<{mollie}prestashop>order_info_53beb26d8bca00f56fbd295fdee83459'] = 'Refunds'; -$_MODULE['<{mollie}prestashop>order_info_daef64964ee3b9b904f5d467586e217f'] = 'Payments'; -$_MODULE['<{mollie}prestashop>order_info_e25be354288565757726f3295e4f3ef9'] = 'Current amount'; -$_MODULE['<{mollie}prestashop>order_info_068f80c7519d0528fb08e82137a72131'] = 'Products'; -$_MODULE['<{mollie}prestashop>order_info_ec53a8c4f07baed5d8825072c89799be'] = 'Status'; -$_MODULE['<{mollie}prestashop>order_info_747cf5c8587184b9e489ff897d97c20d'] = 'Shipped'; -$_MODULE['<{mollie}prestashop>order_info_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Canceled'; -$_MODULE['<{mollie}prestashop>order_info_cc61945cbbf46721a053467c395c666f'] = 'Refunded'; -$_MODULE['<{mollie}prestashop>order_info_197101c4a1b1fc503dcd6ebee127aa10'] = 'Unit Price'; -$_MODULE['<{mollie}prestashop>order_info_11cd653a2488e260a8a99f39cdffa6e7'] = 'VAT Amount'; -$_MODULE['<{mollie}prestashop>order_info_bc30768048a7bbfd2d158d722c140c6d'] = 'Total amount'; -$_MODULE['<{mollie}prestashop>order_info_0387832795db3eb2e05f4365fba5ddac'] = 'Ship'; -$_MODULE['<{mollie}prestashop>order_info_55453aad10c96e452556a106447313bd'] = 'Review shipment'; -$_MODULE['<{mollie}prestashop>order_info_dbb5bbb116e16973136b9ebd887eaadd'] = 'Please review the products included in your shipment. You can remove items or change quantity if needed.'; -$_MODULE['<{mollie}prestashop>order_info_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; -$_MODULE['<{mollie}prestashop>order_info_163bcc6065b16c6369c7a4de44cff164'] = 'Ship products'; -$_MODULE['<{mollie}prestashop>order_info_433557a938a920888445ce2c7df67d5a'] = 'Tracking details'; -$_MODULE['<{mollie}prestashop>order_info_61995a579a6166642e759450a694642b'] = 'Adding tracking information to your shipment is recommended, as it will prove that you actually shipped your products to your customer.'; -$_MODULE['<{mollie}prestashop>order_info_26b6254fefc06894825a50dfbe803937'] = 'Skip tracking details'; -$_MODULE['<{mollie}prestashop>order_info_d57c24f3fe52d16e7169b912dd647f0d'] = 'optional'; -$_MODULE['<{mollie}prestashop>order_info_2df417909bda5f3ddc210a0abe65231f'] = 'E.g. FedEx'; -$_MODULE['<{mollie}prestashop>order_info_593ed3a37aa1a3ece4a4d796fb4e2e03'] = 'This information is required'; -$_MODULE['<{mollie}prestashop>order_info_933292561b46133ff5348c7740874c56'] = 'Tracking code'; -$_MODULE['<{mollie}prestashop>order_info_e6b391a8d2c4d45902a23a8b6585703d'] = 'URL'; -$_MODULE['<{mollie}prestashop>order_info_914419aa32f04011357d3b604a86d7eb'] = 'Carrier'; -$_MODULE['<{mollie}prestashop>order_info_23a902ac637359fe67ceaccbe2c68283'] = 'Ship all'; -$_MODULE['<{mollie}prestashop>order_info_2a6e9f678c7267fe16f57bcd3285f1d7'] = 'Cancel all'; -$_MODULE['<{mollie}prestashop>order_info_05ced64413f9ff5d3602c3e257f36204'] = 'Refund all'; -$_MODULE['<{mollie}prestashop>order_info_bfe005bff7ecacd6ecceacdd7fb79292'] = 'Transaction info'; -$_MODULE['<{mollie}prestashop>order_info_1eefa98a18a384699fe611fbfd8ab0c9'] = 'There are no products'; -$_MODULE['<{mollie}prestashop>order_info_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'An error occurred'; -$_MODULE['<{mollie}prestashop>order_info_2df3102f3fe061003dee820a72e1b1ed'] = 'Unable to ship'; -$_MODULE['<{mollie}prestashop>order_info_3efc29552025b4e68de04f415b0b8806'] = 'Unable to refund'; -$_MODULE['<{mollie}prestashop>order_info_468a92810b526750be9664461db6bf91'] = 'Unable to cancel'; -$_MODULE['<{mollie}prestashop>order_info_2427b479f15af44582dc151ef95a90d0'] = 'Refunds are currently unavailable'; -$_MODULE['<{mollie}prestashop>qr_code_9ba19ddbcfeddfc758eb84fb8ba26b5e'] = 'or scan the iDEAL QR code'; -$_MODULE['<{mollie}prestashop>refund_729a51874fe901b092899e9e8b31c97a'] = 'Are you sure?'; -$_MODULE['<{mollie}prestashop>refund_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Are you sure you want to refund this order?'; -$_MODULE['<{mollie}prestashop>refund_76f0ed934de85cc7131910b32ede7714'] = 'Refund'; -$_MODULE['<{mollie}prestashop>refund_ea4788705e6873b424c65e91c2846b19'] = 'Cancel'; -$_MODULE['<{mollie}prestashop>rounding_error_7783c757cd1177e60888080e0f4e0593'] = 'The configuration option \"%s\" has been set to an unsupported value'; -$_MODULE['<{mollie}prestashop>rounding_error_2279522d0910767ffa75e0b39ed1629f'] = 'The selected rounding mode is not supported by the Mollie Orders API'; -$_MODULE['<{mollie}prestashop>rounding_error_3a92c96baa86286685b233e6912e718d'] = 'Please navigate to the page \"%s\" and choose the option \"%s\"'; -$_MODULE['<{mollie}prestashop>smarty_error_9d1fbbe0d150b89f068ba72a20366659'] = 'The configuration option \"%s\" has been set to \"%s\"'; -$_MODULE['<{mollie}prestashop>smarty_error_27dd3bb10855eb84f48efedf6924c4c1'] = 'This makes it impossible to list payment methods on the checkout'; -$_MODULE['<{mollie}prestashop>smarty_error_4ec23c59d832a2934277a2a040918789'] = 'Please navigate to the page \"%s\" and choose the other option'; -$_MODULE['<{mollie}prestashop>smarty_error_92b67311c1a5d6cfc28ba08a1066c901'] = 'Afterwards, clear the cache one more time, so the payment method list can be refreshed'; -$_MODULE['<{mollie}prestashop>smarty_warning_9d1fbbe0d150b89f068ba72a20366659'] = 'The configuration option \"%s\" has been set to \"%s\"'; -$_MODULE['<{mollie}prestashop>smarty_warning_e7e747f9c74f0b8222c87db24d34f018'] = 'It is possible that not all payment methods can be displayed'; -$_MODULE['<{mollie}prestashop>smarty_warning_1238db0fb782f758b5a54d6333b3610e'] = 'To fix this problem, navigate to the page \"%s\" and clear the cache manually or choose one of the other options'; +mollie_484f5a79672cebe198ebdde45a1d672f'] = 'Gift wrapping'; +$_MODULE['<{mollie}prestashop>mollie_7c478959c218087ffc4ad5d96e7f66a6'] = 'Mollie'; +$_MODULE['<{mollie}prestashop>mollie_95b3b272e06dcc3cc2aa62f6887aebc5'] = 'Mollie Payments'; +$_MODULE['<{mollie}prestashop>mollie_48dedcf43487615c84c1bbbf6fe76c76'] = 'Are you sure you want to uninstall the Mollie Payment Module?'; +$_MODULE['<{mollie}prestashop>mollie_ab552f085567bbe63872c10a3596cd27'] = 'Payment error:'; +$_MODULE['<{mollie}prestashop>mollie_e0010a0a1a3259ab5c06a19bad532851'] = 'Paid'; +$_MODULE['<{mollie}prestashop>mollie_a206428462686af481cb072b8db11784'] = 'Authorized'; +$_MODULE['<{mollie}prestashop>mollie_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Canceled'; +$_MODULE['<{mollie}prestashop>mollie_24fe48030f7d3097d5882535b04c3fa8'] = 'Expired'; +$_MODULE['<{mollie}prestashop>mollie_cc61945cbbf46721a053467c395c666f'] = 'Refunded'; +$_MODULE['<{mollie}prestashop>mollie_7026e386bdad92fa6f232394f5b23ffb'] = 'Bankwire pending'; +$_MODULE['<{mollie}prestashop>mollie_9f004157e4c148dac71da3ae5906351f'] = 'Partially refunded'; +$_MODULE['<{mollie}prestashop>mollie_0eceeb45861f9585dd7a97a3e36f85c6'] = 'Created'; +$_MODULE['<{mollie}prestashop>mollie_e2b7dec8fa4b498156dfee6e4c84b156'] = 'This payment method is not available.'; +$_MODULE['<{mollie}prestashop>mollie_96d0e2862e0167af0c2fd0c99fe6bc5d'] = 'Click here to continue'; +$_MODULE['<{mollie}prestashop>mollie_540d9939d1ca9406e215ee3d78c76813'] = 'This payment method is only available for Euros.'; +$_MODULE['<{mollie}prestashop>mollie_1b2631119333d97dbda37f87e378b1e4'] = 'There was an error while processing your request:'; +$_MODULE['<{mollie}prestashop>mollie_11bab828edcc0a6d5c97cbf84d61e652'] = 'The order with this id does not exist.'; +$_MODULE['<{mollie}prestashop>mollie_b34487c5f391f47b893ee3c61f8f9ab7'] = 'We have not received a definite payment status. You will be notified as soon as we receive a confirmation of the bank/merchant.'; +$_MODULE['<{mollie}prestashop>mollie_57bc999b3b730ead92ac7243fe254a2a'] = 'Unfortunately your payment was expired.'; +$_MODULE['<{mollie}prestashop>mollie_3602f6d5ece34fdbd4ffe0a47f1a2ba4'] = 'Thank you. Your payment has been received.'; +$_MODULE['<{mollie}prestashop>mollie_7352a401b3c23b2966c68bc9ab97fa06'] = 'The transaction has an unexpected status.'; +$_MODULE['<{mollie}prestashop>mollie_3f83176ddc3f63a5a374a623840bfb09'] = 'You are not authorised to see this page.'; +$_MODULE['<{mollie}prestashop>mollie_300225ee958b6350abc51805dab83c24'] = 'Continue shopping'; +$_MODULE['<{mollie}prestashop>mollie_ebdf0f490b617d7efa3025d3625cec85'] = 'Welcome back'; +$_MODULE['<{mollie}prestashop>mollie_66dac2278292ff24611ef8a85bc94e0d'] = 'Select your bank:'; +$_MODULE['<{mollie}prestashop>mollie_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; +$_MODULE['<{mollie}prestashop>mollie_b98a07c82f0078a1de7fc219fae480fc'] = 'Different payment method'; +$_MODULE['<{mollie}prestashop>mollie_35895cff7df70dab18783453e2bd241f'] = 'Pay with %s'; +$_MODULE['<{mollie}prestashop>mollie_cc16e103e202a48009df202d9525f75f'] = 'Refund this order'; +$_MODULE['<{mollie}prestashop>mollie_c5222afef6530f674d3acf82ba2ce9dc'] = 'Mollie refund'; +$_MODULE['<{mollie}prestashop>mollie_7064b25aa8a732a3db7f230c9867be19'] = 'Refund order #%d through the Mollie API.'; +$_MODULE['<{mollie}prestashop>mollie_e12682d2e0650f2783b22d956d2b947a'] = 'The order has been refunded!'; +$_MODULE['<{mollie}prestashop>mollie_95be87afb2734075cf345b633e1384ec'] = 'Mollie B.V. will transfer the money back to the customer on the next business day.'; +$_MODULE['<{mollie}prestashop>mollie_9770d1f0124abb0d6a894cd79f8703b5'] = 'Awaiting Mollie payment'; +$_MODULE['<{mollie}prestashop>mollie_b9fc80a6e775cb75568db6b6538dacdd'] = 'Mollie partially refunded'; +$_MODULE['<{mollie}prestashop>mollie_f91ab041fe9d6057740394b8b7903a0f'] = 'iDEAL'; +$_MODULE['<{mollie}prestashop>mollie_b749cfb52bfd82c5b12aa49d6906b8e8'] = 'CartaSi'; +$_MODULE['<{mollie}prestashop>mollie_05bfde942b997737b56b9ab405450076'] = 'Cartes Bancaires'; +$_MODULE['<{mollie}prestashop>mollie_e7f9e382dc50889098cbe56f2554c77b'] = 'Credit card'; +$_MODULE['<{mollie}prestashop>mollie_870cf6bc77bbadd038aeb8d942c9cb18'] = 'Bancontact'; +$_MODULE['<{mollie}prestashop>mollie_8ad65eb3da9995173280649f090218c3'] = 'SOFORT Banking'; +$_MODULE['<{mollie}prestashop>mollie_c0db4214f9d7e1b846f4496e03e667d0'] = 'SEPA Direct Debit'; +$_MODULE['<{mollie}prestashop>mollie_5aa515ce21e8de1ed7416dce455a151f'] = 'Belfius Pay Button'; +$_MODULE['<{mollie}prestashop>mollie_d023ec040f79f1a9b2ac960b43785089'] = 'Bitcoin'; +$_MODULE['<{mollie}prestashop>mollie_4aa65ea89e54d83bb2604c2cc89babc3'] = 'PODIUM Cadeaukaart'; +$_MODULE['<{mollie}prestashop>mollie_58c25c4b8b4382e37d89e0ef6bd625cf'] = 'Gift cards'; +$_MODULE['<{mollie}prestashop>mollie_431647a0a8b2cd589c9fda9535f90d6d'] = 'Bank transfer'; +$_MODULE['<{mollie}prestashop>mollie_ad69e733ebae8d264bccaa38d68830e8'] = 'PayPal'; +$_MODULE['<{mollie}prestashop>mollie_6abcd8eecb4f2abb6ccfe36ef7046ba0'] = 'paysafecard'; +$_MODULE['<{mollie}prestashop>mollie_a81bd6195f1abce35fd03a870270100b'] = 'KBC/CBC Payment Button'; +$_MODULE['<{mollie}prestashop>mollie_8184c64d6318b4a42428ae21d0fe2311'] = 'ING Home\'Pay'; +$_MODULE['<{mollie}prestashop>mollie_31911306551723245e7417ae4520fecb'] = 'Giropay'; +$_MODULE['<{mollie}prestashop>mollie_ce8e4a184e2e534c09d6bf6ae773ca4a'] = 'eps'; +$_MODULE['<{mollie}prestashop>mollie_feb1a8ded87483b416427b8457bdc664'] = 'Pay later.'; +$_MODULE['<{mollie}prestashop>mollie_a388a6fba0d4b58c334cd9416071cdb1'] = 'Slice it.'; +$_MODULE['<{mollie}prestashop>mollie_d1913efa9eae51595a33f3c1410d465c'] = 'The method %s is overridden by module %s. This can cause interference with payments.'; +$_MODULE['<{mollie}prestashop>mollie_6311eb29dee3acc14071e0b1efb173f5'] = '%s statuses:'; +$_MODULE['<{mollie}prestashop>mollie_d438a1d96c6037fccad15d7594737a84'] = 'Visual settings:'; +$_MODULE['<{mollie}prestashop>mollie_49259add73e416838e985a6bf4d0e571'] = 'Debug info:'; +$_MODULE['<{mollie}prestashop>mollie_c9cc8cce247e49bae79f15173ce97354'] = 'Save'; +$_MODULE['<{mollie}prestashop>mollie_5bef23eb7efff2736c5583bda59e5eb7'] = 'Create your account'; +$_MODULE['<{mollie}prestashop>mollie_a77e6fc49f07414fc53336c8d879b73e'] = 'Do you already have an API Key? Then you can skip this step and proceed to entering your API key.'; +$_MODULE['<{mollie}prestashop>mollie_21aef67e8d12503aff027385d0a7867f'] = 'First and last name'; +$_MODULE['<{mollie}prestashop>mollie_b357b524e740bc85b9790a0712d84a30'] = 'Email address'; +$_MODULE['<{mollie}prestashop>mollie_e93c33bd1341ab74195430daeb63db13'] = 'Shop name'; +$_MODULE['<{mollie}prestashop>mollie_dd7bf230fde8d4836917806aff6a6b27'] = 'Address'; +$_MODULE['<{mollie}prestashop>mollie_8bcdc441379cbf584638b0589a3f9adb'] = 'Postcode'; +$_MODULE['<{mollie}prestashop>mollie_57d056ed0984166336b7879c2af3657f'] = 'City'; +$_MODULE['<{mollie}prestashop>mollie_59716c97497eb9694541f7c3d37b1a4d'] = 'Country'; +$_MODULE['<{mollie}prestashop>mollie_686e697538050e4664636337cc3b834f'] = 'Create'; +$_MODULE['<{mollie}prestashop>mollie_7c4e7ada50c8572336f872fced4d1852'] = 'Status for %s payments'; +$_MODULE['<{mollie}prestashop>mollie_bea3fae02ae079e541199ab6ffc2d1ad'] = '`%s` payments get status `%s`'; +$_MODULE['<{mollie}prestashop>mollie_b2a2c5a69af7c04c5adc48261fb5dc13'] = 'Send mails when %s'; +$_MODULE['<{mollie}prestashop>mollie_0511c3431d4e32ed4266fe943014d000'] = 'Send mails when transaction status becomes %s?'; +$_MODULE['<{mollie}prestashop>mollie_7aace0dc23ee8b74744bdf79c98a2605'] = 'Skip this status'; +$_MODULE['<{mollie}prestashop>mollie_dd59e3663865f3fab190e496260608e6'] = '`%s` payments do not get a status'; +$_MODULE['<{mollie}prestashop>mollie_824f2c1d1c2ee9aecac9977d9347a2ea'] = 'Mollie Settings'; +$_MODULE['<{mollie}prestashop>mollie_d876ff8da67c3731ae25d8335a4168b4'] = 'API Key'; +$_MODULE['<{mollie}prestashop>mollie_2ffbc7eb8899865f9e66682d34853195'] = 'You can find your API key in your [1]Mollie Profile[/1]; it starts with test or live.'; +$_MODULE['<{mollie}prestashop>mollie_b5a7adde1af5c87d7fd797b6245c2a39'] = 'Description'; +$_MODULE['<{mollie}prestashop>mollie_3150652ab7f22bafe11a78d4cc0de8be'] = 'Enter a description here. Note: Payment methods may have a character limit, best keep the description under 29 characters. You can use the following variables: %s'; +$_MODULE['<{mollie}prestashop>mollie_8d9143dfc520ed7d982d4e545c7bfc5e'] = 'Send locale for payment screen'; +$_MODULE['<{mollie}prestashop>mollie_1239c091f39c068882e924e34dd9cc40'] = 'Should the plugin send the current webshop [1]locale[/1] to Mollie. Mollie payment screens will be in the same language as your webshop. Mollie can also detect the language based on the user\'s browser language.'; +$_MODULE['<{mollie}prestashop>mollie_80a78bb16945665b6410ae8d93e81c69'] = 'Do not send locale using browser language'; +$_MODULE['<{mollie}prestashop>mollie_3ba67aae5d08d0fa90016685407926f1'] = 'Visual Settings'; +$_MODULE['<{mollie}prestashop>mollie_fff0d600f8a0b5e19e88bfb821dd1157'] = 'Images'; +$_MODULE['<{mollie}prestashop>mollie_f7a97136df639501521efb243047e0cf'] = 'Show big, normal or no payment method logos on checkout.'; +$_MODULE['<{mollie}prestashop>mollie_a88f05b6c963e145a45b58c47cd42a41'] = 'hide'; +$_MODULE['<{mollie}prestashop>mollie_fea087517c26fadd409bd4b9dc642555'] = 'normal'; +$_MODULE['<{mollie}prestashop>mollie_d861877da56b8b4ceb35c8cbfdf65bb4'] = 'big'; +$_MODULE['<{mollie}prestashop>mollie_85fb708f31f585607247f8b868efafcc'] = 'Issuer list'; +$_MODULE['<{mollie}prestashop>mollie_27db39558366d2a9001a0dec69eea4d6'] = 'Some payment methods (eg. iDEAL) have an issuer list. This setting specifies where it is shown.'; +$_MODULE['<{mollie}prestashop>mollie_85a692706bc7597b6e32bc1d354c138f'] = 'On click'; +$_MODULE['<{mollie}prestashop>mollie_ea9b19c6f2e9ef60b49778ab9396b293'] = 'Own page'; +$_MODULE['<{mollie}prestashop>mollie_d35acbb07d2841712a937d5748e9bdc2'] = 'Payment page'; +$_MODULE['<{mollie}prestashop>mollie_1547ffc579d657d13fd5fedf12cbfae5'] = 'CSS file'; +$_MODULE['<{mollie}prestashop>mollie_6602513644161421f58418528d93ac00'] = 'Leave empty for default stylesheet. Should include file path when set. Hint: You can use [1]{BASE}[/1], [1]{THEME}[/1], [1]{CSS}[/1], [1]{MOBILE}[/1], [1]{MOBILE_CSS}[/1] and [1]{OVERRIDE}[/1] for easy folder mapping.'; +$_MODULE['<{mollie}prestashop>mollie_0da8d9a75492046bea7f314521e07cae'] = 'Payment methods'; +$_MODULE['<{mollie}prestashop>mollie_75886bf821fc9c068a280fe52337c0f5'] = 'Enable or disable the payment methods. You can drag and drop to rearrange the payment methods.'; +$_MODULE['<{mollie}prestashop>mollie_c576349bf8ff5fba4e9369ab581a4074'] = 'Enable iDEAL QR'; +$_MODULE['<{mollie}prestashop>mollie_c0ae4417e7a196f3ccfadff68a5064ed'] = 'QR Codes are currently not supported by the Orders API. Our apologies for the inconvenience!'; +$_MODULE['<{mollie}prestashop>mollie_e17dc77fb83539b6a4687c6d515791e4'] = '%s statuses'; +$_MODULE['<{mollie}prestashop>mollie_4695fd3a22023ab53a2151f797975ff8'] = 'Disable this status'; +$_MODULE['<{mollie}prestashop>mollie_656f9fd6f874404599220855cfec17ef'] = 'Mollie API'; +$_MODULE['<{mollie}prestashop>mollie_a1532be2c9ef11d7dd5edd974fc6c98c'] = 'Select which Mollie API to use'; +$_MODULE['<{mollie}prestashop>mollie_9ce1d2272c82bfd7d501a6697df774c7'] = 'Should the plugin use the new Mollie Orders API? This enables payment methods such as Klarna Pay Later.'; +$_MODULE['<{mollie}prestashop>mollie_8c2b4949d892b39b236545951f10bbd4'] = 'Payments API'; +$_MODULE['<{mollie}prestashop>mollie_a8b0255f70ecc140a1b5134ae5217e51'] = 'Orders API'; +$_MODULE['<{mollie}prestashop>mollie_1191f888f0cc23f95aa77aacb094503b'] = 'Shipment information'; +$_MODULE['<{mollie}prestashop>mollie_d822c02513be98814bdd39f8bae598d1'] = 'Automatically ship when marked as `shipped`'; +$_MODULE['<{mollie}prestashop>mollie_0eccefc4c96190190add75fe0a74fcd4'] = 'Enabling this feature will automatically send shipment information when an order has been marked as `shipped`'; +$_MODULE['<{mollie}prestashop>mollie_c1df8a5243557cbd8a7a31c11aab3db4'] = 'Automatically ship when one of these statuses is reached'; +$_MODULE['<{mollie}prestashop>mollie_34bd91e87db36a10b9e847d6304be289'] = 'If an order reaches one of these statuses the module will automatically send shipment information'; +$_MODULE['<{mollie}prestashop>mollie_498f79c4c5bbde77f1bceb6c86fd0f6d'] = 'Show'; +$_MODULE['<{mollie}prestashop>mollie_62a5e490880a92eef74f167d9dc6dca0'] = 'Hide'; +$_MODULE['<{mollie}prestashop>mollie_dc6e4b439165a4e104c9f3cbfcfe2797'] = 'Debug level'; +$_MODULE['<{mollie}prestashop>mollie_500aa80d6aea3cc9701b566c5f92ed91'] = 'Display errors'; +$_MODULE['<{mollie}prestashop>mollie_37f9a8b20930c1dc7488b15872b6d36b'] = 'Enabling this feature will display error messages (if any) on the front page. Use for debug purposes only!'; +$_MODULE['<{mollie}prestashop>mollie_e5114c4b69585ba5883d456a74c1cd5d'] = 'Log level'; +$_MODULE['<{mollie}prestashop>mollie_921a6d905eef99631c9c73c317799e62'] = 'Recommended level: Errors. Set to Everything to monitor incoming webhook requests. [1]View logs.[/1]'; +$_MODULE['<{mollie}prestashop>mollie_f80a4ad87fee7c9fdc19b7769495fdb5'] = 'Nothing'; +$_MODULE['<{mollie}prestashop>mollie_5ef0c737746fae2ca90e66c39333f8f6'] = 'Errors'; +$_MODULE['<{mollie}prestashop>mollie_709468af25e91284821d1bdbfdded24c'] = 'Everything'; +$_MODULE['<{mollie}prestashop>mollie_1f93fc361bfc627c89a46e1b6c28df2b'] = 'The API key needs to start with test or live.'; +$_MODULE['<{mollie}prestashop>mollie_6ab1adfed768d989b47c908755fe677f'] = 'The configuration has been saved!'; +$_MODULE['<{mollie}prestashop>mollie_1f91cd9f380285bf1219c79ab7fcb75e'] = 'Warning: Could not retrieve update file from github.'; +$_MODULE['<{mollie}prestashop>mollie_ce1e483d5cd4b349af887fa3e198ea6b'] = 'No download package found for the latest release.'; +$_MODULE['<{mollie}prestashop>mollie_048ef1905ff33382d7660a68a6199305'] = 'Warning: Could not retrieve update xml file from github.'; +$_MODULE['<{mollie}prestashop>mollie_711d42f319398490b32cd0e2f0b8ccb8'] = 'Warning: Update xml file from github follows an unexpected format.'; +$_MODULE['<{mollie}prestashop>mollie_48fa0f621f79f451e58f200957da5b52'] = 'Choose your bank'; +$_MODULE['<{mollie}prestashop>mollie_8953fb7da2299bf905b73720f611baa3'] = 'or pay by iDEAL QR'; +$_MODULE['<{mollie}prestashop>mollie_961f2247a2070bedff9f9cd8d64e2650'] = 'Choose'; +$_MODULE['<{mollie}prestashop>mollie_ea4788705e6873b424c65e91c2846b19'] = 'Cancel'; +$_MODULE['<{mollie}prestashop>mollie_ea9cf7e47ff33b2be14e6dd07cbcefc6'] = 'Shipping'; +$_MODULE['<{mollie}prestashop>mollie_f93bd0f858a6e5f70cb458c90a36172b'] = 'Unable to retieve info about the latest version'; +$_MODULE['<{mollie}prestashop>mollie_ced93781bca50eb4d970ea51abcc622c'] = 'You are already running the latest version!'; +$_MODULE['<{mollie}prestashop>mollie_43f3c5a157c67de9b6faf42b637f963a'] = 'Module archive could not be downloaded'; +$_MODULE['<{mollie}prestashop>mollie_31dd57eea0f762b4ea6f022b40acc390'] = 'There was an error while extracting the module file (file may be corrupted).'; +$_MODULE['<{mollie}prestashop>mollie_bad5a3ab102f6e9c27edd494d7e33323'] = 'Successfully created your new Mollie account. Please check your inbox for more information.'; +$_MODULE['<{mollie}prestashop>mollie_023b7ade110944180153fd73358fc50c'] = 'An unknown error occurred while trying to create your Mollie account'; +$_MODULE['<{mollie}prestashop>mollie_3a6e70059673992f825826f7cf89278d'] = 'The cart rule named \"%1s\" (ID %2s) used in this cart is not valid and has been withdrawn from cart'; +$_MODULE['<{mollie}prestashop>mollie_3a1048f8aa3a9f6b604fcf7982811752'] = 'Warning: the secure key is empty, check your payment account before validation'; +$_MODULE['<{mollie}prestashop>mollie_26beb437d3323bd4bfb0811b3e891315'] = '%d image(s)'; +$_MODULE['<{mollie}prestashop>mollie_0791970c961c09eb8caaa61aba6a3ca4'] = 'An error occurred while saving message'; +$_MODULE['<{mollie}prestashop>mollie_ed13b3693357ebed3751cb71cb639e65'] = 'No carrier'; +$_MODULE['<{mollie}prestashop>mollie_b08d3867be98e6fff3233cd40ab8134a'] = 'Order creation failed'; +$_MODULE['<{mollie}prestashop>mollie_43423b4056880b08f2c9aa50d8670531'] = 'Cart cannot be loaded or an order has already been placed using this cart'; +$_MODULE['<{mollie}prestashop>mollie_88183b946cc5f0e8c96b2e66e1c74a7e'] = 'Unknown'; +$_MODULE['<{mollie}prestashop>mollie_32c86f9a2a28a9fa544b97024393633e'] = 'No payment methods found'; +$_MODULE['<{mollie}prestashop>mollie_301b87d33063f687d14004a9014f6759'] = 'You do not have permission to refund payments'; +$_MODULE['<{mollie}prestashop>mollie_8dc6945fb6b59aea38df7935cf3afb6d'] = 'You do not have permission to %s payments'; +$_MODULE['<{mollie}prestashop>mollie_1bda80f2be4d3658e0baa43fbe7ae8c1'] = 'view'; +$_MODULE['<{mollie}prestashop>mollie_de95b43bceeb4b998aed4aed5cef1ae7'] = 'edit'; +$_MODULE['<{mollie}prestashop>mollie_2a3f1166b041928019e4e8718d628665'] = 'ship'; +$_MODULE['<{mollie}prestashop>mollie_df6f85687a0d5820baa1a069a04eff2d'] = 'refund'; +$_MODULE['<{mollie}prestashop>mollie_10aec35353f9c4096a71c38654c3d402'] = 'cancel'; +$_MODULE['<{mollie}prestashop>payment_c2f73af3130be4b4967a475ab846c546'] = 'An error occurred while initializing your payment. Please contact our customer support.'; +$_MODULE['<{mollie}prestashop>download_update_6de6a882c42b757cd027830399a74de4'] = 'Update this module'; +$_MODULE['<{mollie}prestashop>download_update_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Error'; +$_MODULE['<{mollie}prestashop>download_update_5d04a002ea59c8114f9d08b0c6250a3b'] = 'Unable to connect'; +$_MODULE['<{mollie}prestashop>download_update_3844b140df977eee8639de6d1de9e1e0'] = 'Unable to unzip new module'; +$_MODULE['<{mollie}prestashop>download_update_b50ec141b028d5a8acec4a17c32f3808'] = 'The module has been updated!'; +$_MODULE['<{mollie}prestashop>new_release_b7f73af7318580996a3889353b282827'] = 'You are currently using version %s. We strongly recommend you to upgrade to the new version %s!'; +$_MODULE['<{mollie}prestashop>form_93cba07454f06a4a960172bbd6e2a435'] = 'Yes'; +$_MODULE['<{mollie}prestashop>form_bafd7322c6e97d25b6299b5d6fe8920b'] = 'No'; +$_MODULE['<{mollie}prestashop>form_2d25c72c1b18e562f6654fff8e11711e'] = 'Not available'; +$_MODULE['<{mollie}prestashop>form_58afe6389d8f42880d1011ef0de542a2'] = 'This payment method is not available on the Payments API. Switch to the Orders API below in order to activate this method.'; +$_MODULE['<{mollie}prestashop>form_9b6a88a9d4a44740f87b1ffa7cb070c4'] = 'Unable to load payment methods'; +$_MODULE['<{mollie}prestashop>form_6327b4e59f58137083214a1fec358855'] = 'Retry'; +$_MODULE['<{mollie}prestashop>form_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Error'; +$_MODULE['<{mollie}prestashop>form_49ee3087348e8d44e1feda1917443987'] = 'Name'; +$_MODULE['<{mollie}prestashop>form_b33f1d112cd9d2d32d37cb4cc9a340c8'] = 'URL Source'; +$_MODULE['<{mollie}prestashop>form_de28ef21a06f3978c05f3d808b15eaab'] = 'Carrier URL'; +$_MODULE['<{mollie}prestashop>form_812a48ba719daeda82e4da8e812d426c'] = 'Custom URL'; +$_MODULE['<{mollie}prestashop>form_e55f75a29310d7b60f7ac1d390c8ae42'] = 'Module'; +$_MODULE['<{mollie}prestashop>form_962b59a5f12eabd9c05f11b5f0aada85'] = 'Do not automatically ship'; +$_MODULE['<{mollie}prestashop>form_703490ffd308d337cd5aac50567e9670'] = 'No tracking information'; +$_MODULE['<{mollie}prestashop>form_f421a366f70bd2aa1193eeb5a2990546'] = 'Here you can configure what information about the shipment is sent to Mollie'; +$_MODULE['<{mollie}prestashop>form_53b2566e3519ea98db40ae9e716883a5'] = 'You can use the following variables for the Carrier URLs'; +$_MODULE['<{mollie}prestashop>form_910d956cb2615e5739ac06c7f08fba26'] = 'Shipping number'; +$_MODULE['<{mollie}prestashop>form_e7e862a02819a1610f271ffea15ed47d'] = 'Billing country code'; +$_MODULE['<{mollie}prestashop>form_5723a18d8a8a6052a57489df5be59a8f'] = 'Billing postcode'; +$_MODULE['<{mollie}prestashop>form_0d12e3c554976ad1f76c5db2b6c127ad'] = 'Shipping country code'; +$_MODULE['<{mollie}prestashop>form_c824a8b18f09dc7e58bacf446be6735c'] = 'Shipping postcode'; +$_MODULE['<{mollie}prestashop>form_0a867177f4a701a9f33de5ab21c42593'] = '2-letter language code'; +$_MODULE['<{mollie}prestashop>form_f6fcb64e21455abc4209f8f4440d45f5'] = 'Unable to load carrier list'; +$_MODULE['<{mollie}prestashop>form_da93de158db2fbe49f35f6038711584a'] = 'This option is not required for the currently selected API'; +$_MODULE['<{mollie}prestashop>17_error_47e1924c444fafe9fdfce444790f0ba9'] = 'Back to your shopping cart'; +$_MODULE['<{mollie}prestashop>error_c453a4b8e8d98e82f35b67f433e3b4da'] = 'Payment'; +$_MODULE['<{mollie}prestashop>error_1e97d97a923eaddd810e056c828e99ea'] = 'Payment error'; +$_MODULE['<{mollie}prestashop>error_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'An error occurred'; +$_MODULE['<{mollie}prestashop>error_47e1924c444fafe9fdfce444790f0ba9'] = 'Back to your shopping cart'; +$_MODULE['<{mollie}prestashop>mollie_issuers_588540a38eeba525f3598b68e6b788e5'] = 'or choose a different payment method'; +$_MODULE['<{mollie}prestashop>mollie_return_ebdf0f490b617d7efa3025d3625cec85'] = 'Welcome back'; +$_MODULE['<{mollie}prestashop>mollie_return_300225ee958b6350abc51805dab83c24'] = 'Continue shopping'; +$_MODULE['<{mollie}prestashop>mollie_wait_bc0dd919f9a70dbb62f3f7afd68d6d68'] = 'Awaiting payment status'; +$_MODULE['<{mollie}prestashop>qr_done_92816c7248d010591f699db3aaf6287b'] = 'Mollie iDEAL QR'; +$_MODULE['<{mollie}prestashop>qr_done_ebdf0f490b617d7efa3025d3625cec85'] = 'Welcome back'; +$_MODULE['<{mollie}prestashop>qr_done_4bf3a07ce980c9b007f9e2eed42d7fa2'] = 'The payment has been canceled.'; +$_MODULE['<{mollie}prestashop>qr_done_6933c118341d8c06f888c392aa1ceaf5'] = 'The payment has been completed. Thank you for your order!'; +$_MODULE['<{mollie}prestashop>ideal_dropdown_ab4147235204a436c09e00d6722082ab'] = 'Choose a bank'; +$_MODULE['<{mollie}prestashop>order_info_729a51874fe901b092899e9e8b31c97a'] = 'Are you sure?'; +$_MODULE['<{mollie}prestashop>order_info_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Are you sure you want to refund this order?'; +$_MODULE['<{mollie}prestashop>order_info_76f0ed934de85cc7131910b32ede7714'] = 'Refund'; +$_MODULE['<{mollie}prestashop>order_info_ea4788705e6873b424c65e91c2846b19'] = 'Cancel'; +$_MODULE['<{mollie}prestashop>order_info_88ba0dcbc82905637e98317e0302cfd8'] = 'Refund order'; +$_MODULE['<{mollie}prestashop>order_info_5a1119ecb764165f27cb37b6f50134f2'] = 'Remaining'; +$_MODULE['<{mollie}prestashop>order_info_77fd2b4393b379bedd30efcd5df02090'] = 'Partial refund'; +$_MODULE['<{mollie}prestashop>order_info_a9ced76f2dd6907220fa95b3a136b04a'] = 'Invalid amount'; +$_MODULE['<{mollie}prestashop>order_info_3a2c3e97fed586776c2800fb7a0faf4e'] = 'You have entered an invalid amount'; +$_MODULE['<{mollie}prestashop>order_info_3cc4859e502556d0d848c3bc38618782'] = 'Refund failed'; +$_MODULE['<{mollie}prestashop>order_info_d5cfd0f69cd548e5d3b9edde5ff1b48f'] = 'Payment info'; +$_MODULE['<{mollie}prestashop>order_info_88427ec035734b45aae9f7d8859a5008'] = 'Transaction ID'; +$_MODULE['<{mollie}prestashop>order_info_782678f4ba02feb3e9ecd51e902cd16b'] = 'Refund history'; +$_MODULE['<{mollie}prestashop>order_info_c5b41ae59bd6585750f536615a6bc20b'] = 'There are no refunds'; +$_MODULE['<{mollie}prestashop>order_info_b718adec73e04ce3ec720dd11a06a308'] = 'ID'; +$_MODULE['<{mollie}prestashop>order_info_44749712dbec183e983dcd78a7736c41'] = 'Date'; +$_MODULE['<{mollie}prestashop>order_info_b2f40690858b404ed10e62bdf422c704'] = 'Amount'; +$_MODULE['<{mollie}prestashop>order_info_53beb26d8bca00f56fbd295fdee83459'] = 'Refunds'; +$_MODULE['<{mollie}prestashop>order_info_daef64964ee3b9b904f5d467586e217f'] = 'Payments'; +$_MODULE['<{mollie}prestashop>order_info_e25be354288565757726f3295e4f3ef9'] = 'Current amount'; +$_MODULE['<{mollie}prestashop>order_info_068f80c7519d0528fb08e82137a72131'] = 'Products'; +$_MODULE['<{mollie}prestashop>order_info_ec53a8c4f07baed5d8825072c89799be'] = 'Status'; +$_MODULE['<{mollie}prestashop>order_info_747cf5c8587184b9e489ff897d97c20d'] = 'Shipped'; +$_MODULE['<{mollie}prestashop>order_info_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Canceled'; +$_MODULE['<{mollie}prestashop>order_info_cc61945cbbf46721a053467c395c666f'] = 'Refunded'; +$_MODULE['<{mollie}prestashop>order_info_197101c4a1b1fc503dcd6ebee127aa10'] = 'Unit Price'; +$_MODULE['<{mollie}prestashop>order_info_11cd653a2488e260a8a99f39cdffa6e7'] = 'VAT Amount'; +$_MODULE['<{mollie}prestashop>order_info_bc30768048a7bbfd2d158d722c140c6d'] = 'Total amount'; +$_MODULE['<{mollie}prestashop>order_info_0387832795db3eb2e05f4365fba5ddac'] = 'Ship'; +$_MODULE['<{mollie}prestashop>order_info_55453aad10c96e452556a106447313bd'] = 'Review shipment'; +$_MODULE['<{mollie}prestashop>order_info_dbb5bbb116e16973136b9ebd887eaadd'] = 'Please review the products included in your shipment. You can remove items or change quantity if needed.'; +$_MODULE['<{mollie}prestashop>order_info_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; +$_MODULE['<{mollie}prestashop>order_info_163bcc6065b16c6369c7a4de44cff164'] = 'Ship products'; +$_MODULE['<{mollie}prestashop>order_info_433557a938a920888445ce2c7df67d5a'] = 'Tracking details'; +$_MODULE['<{mollie}prestashop>order_info_61995a579a6166642e759450a694642b'] = 'Adding tracking information to your shipment is recommended, as it will prove that you actually shipped your products to your customer.'; +$_MODULE['<{mollie}prestashop>order_info_26b6254fefc06894825a50dfbe803937'] = 'Skip tracking details'; +$_MODULE['<{mollie}prestashop>order_info_d57c24f3fe52d16e7169b912dd647f0d'] = 'optional'; +$_MODULE['<{mollie}prestashop>order_info_2df417909bda5f3ddc210a0abe65231f'] = 'E.g. FedEx'; +$_MODULE['<{mollie}prestashop>order_info_593ed3a37aa1a3ece4a4d796fb4e2e03'] = 'This information is required'; +$_MODULE['<{mollie}prestashop>order_info_933292561b46133ff5348c7740874c56'] = 'Tracking code'; +$_MODULE['<{mollie}prestashop>order_info_e6b391a8d2c4d45902a23a8b6585703d'] = 'URL'; +$_MODULE['<{mollie}prestashop>order_info_914419aa32f04011357d3b604a86d7eb'] = 'Carrier'; +$_MODULE['<{mollie}prestashop>order_info_23a902ac637359fe67ceaccbe2c68283'] = 'Ship all'; +$_MODULE['<{mollie}prestashop>order_info_2a6e9f678c7267fe16f57bcd3285f1d7'] = 'Cancel all'; +$_MODULE['<{mollie}prestashop>order_info_05ced64413f9ff5d3602c3e257f36204'] = 'Refund all'; +$_MODULE['<{mollie}prestashop>order_info_bfe005bff7ecacd6ecceacdd7fb79292'] = 'Transaction info'; +$_MODULE['<{mollie}prestashop>order_info_1eefa98a18a384699fe611fbfd8ab0c9'] = 'There are no products'; +$_MODULE['<{mollie}prestashop>order_info_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'An error occurred'; +$_MODULE['<{mollie}prestashop>order_info_2df3102f3fe061003dee820a72e1b1ed'] = 'Unable to ship'; +$_MODULE['<{mollie}prestashop>order_info_3efc29552025b4e68de04f415b0b8806'] = 'Unable to refund'; +$_MODULE['<{mollie}prestashop>order_info_468a92810b526750be9664461db6bf91'] = 'Unable to cancel'; +$_MODULE['<{mollie}prestashop>order_info_2427b479f15af44582dc151ef95a90d0'] = 'Refunds are currently unavailable'; +$_MODULE['<{mollie}prestashop>qr_code_9ba19ddbcfeddfc758eb84fb8ba26b5e'] = 'or scan the iDEAL QR code'; +$_MODULE['<{mollie}prestashop>refund_729a51874fe901b092899e9e8b31c97a'] = 'Are you sure?'; +$_MODULE['<{mollie}prestashop>refund_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Are you sure you want to refund this order?'; +$_MODULE['<{mollie}prestashop>refund_76f0ed934de85cc7131910b32ede7714'] = 'Refund'; +$_MODULE['<{mollie}prestashop>refund_ea4788705e6873b424c65e91c2846b19'] = 'Cancel'; +$_MODULE['<{mollie}prestashop>rounding_error_7783c757cd1177e60888080e0f4e0593'] = 'The configuration option \"%s\" has been set to an unsupported value'; +$_MODULE['<{mollie}prestashop>rounding_error_2279522d0910767ffa75e0b39ed1629f'] = 'The selected rounding mode is not supported by the Mollie Orders API'; +$_MODULE['<{mollie}prestashop>rounding_error_3a92c96baa86286685b233e6912e718d'] = 'Please navigate to the page \"%s\" and choose the option \"%s\"'; +$_MODULE['<{mollie}prestashop>smarty_error_9d1fbbe0d150b89f068ba72a20366659'] = 'The configuration option \"%s\" has been set to \"%s\"'; +$_MODULE['<{mollie}prestashop>smarty_error_27dd3bb10855eb84f48efedf6924c4c1'] = 'This makes it impossible to list payment methods on the checkout'; +$_MODULE['<{mollie}prestashop>smarty_error_4ec23c59d832a2934277a2a040918789'] = 'Please navigate to the page \"%s\" and choose the other option'; +$_MODULE['<{mollie}prestashop>smarty_error_92b67311c1a5d6cfc28ba08a1066c901'] = 'Afterwards, clear the cache one more time, so the payment method list can be refreshed'; +$_MODULE['<{mollie}prestashop>smarty_warning_9d1fbbe0d150b89f068ba72a20366659'] = 'The configuration option \"%s\" has been set to \"%s\"'; +$_MODULE['<{mollie}prestashop>smarty_warning_e7e747f9c74f0b8222c87db24d34f018'] = 'It is possible that not all payment methods can be displayed'; +$_MODULE['<{mollie}prestashop>smarty_warning_1238db0fb782f758b5a54d6333b3610e'] = 'To fix this problem, navigate to the page \"%s\" and clear the cache manually or choose one of the other options'; diff --git a/translations/es.php b/translations/es.php index d395fbf92..6961b6d05 100644 --- a/translations/es.php +++ b/translations/es.php @@ -1,273 +1,273 @@ -mollie_484f5a79672cebe198ebdde45a1d672f'] = 'Envoltorio de regalo'; -$_MODULE['<{mollie}prestashop>mollie_7c478959c218087ffc4ad5d96e7f66a6'] = 'Mollie'; -$_MODULE['<{mollie}prestashop>mollie_95b3b272e06dcc3cc2aa62f6887aebc5'] = 'Pagos Mollie'; -$_MODULE['<{mollie}prestashop>mollie_48dedcf43487615c84c1bbbf6fe76c76'] = '¿Estás seguro de que quieres desinstalar el módulo de pagos Mollie?'; -$_MODULE['<{mollie}prestashop>mollie_ab552f085567bbe63872c10a3596cd27'] = 'Error de Pago:'; -$_MODULE['<{mollie}prestashop>mollie_e0010a0a1a3259ab5c06a19bad532851'] = 'Pagado'; -$_MODULE['<{mollie}prestashop>mollie_a206428462686af481cb072b8db11784'] = 'Autorizado'; -$_MODULE['<{mollie}prestashop>mollie_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Cancelado'; -$_MODULE['<{mollie}prestashop>mollie_24fe48030f7d3097d5882535b04c3fa8'] = 'Expirado'; -$_MODULE['<{mollie}prestashop>mollie_cc61945cbbf46721a053467c395c666f'] = 'Reinstegrado'; -$_MODULE['<{mollie}prestashop>mollie_7026e386bdad92fa6f232394f5b23ffb'] = 'Transferencia bancaria pendiente'; -$_MODULE['<{mollie}prestashop>mollie_9f004157e4c148dac71da3ae5906351f'] = 'Parcialmente reintegrado'; -$_MODULE['<{mollie}prestashop>mollie_0eceeb45861f9585dd7a97a3e36f85c6'] = 'Creado'; -$_MODULE['<{mollie}prestashop>mollie_e2b7dec8fa4b498156dfee6e4c84b156'] = 'Este método de pago no esta disponible'; -$_MODULE['<{mollie}prestashop>mollie_96d0e2862e0167af0c2fd0c99fe6bc5d'] = 'Haz click aquí para continuar'; -$_MODULE['<{mollie}prestashop>mollie_540d9939d1ca9406e215ee3d78c76813'] = 'Este método de pago solo está disponible para Euros.'; -$_MODULE['<{mollie}prestashop>mollie_1b2631119333d97dbda37f87e378b1e4'] = 'Ha habido un error al procesar tu petición:'; -$_MODULE['<{mollie}prestashop>mollie_11bab828edcc0a6d5c97cbf84d61e652'] = 'El encargo con esta id no existe.'; -$_MODULE['<{mollie}prestashop>mollie_b34487c5f391f47b893ee3c61f8f9ab7'] = 'No hemos recibido un estado del pago definitivo. Serás notificado tan pronto como recibamos confirmación del banco/mercader.'; -$_MODULE['<{mollie}prestashop>mollie_57bc999b3b730ead92ac7243fe254a2a'] = 'Desafortunadamente tu pago ha expirado.'; -$_MODULE['<{mollie}prestashop>mollie_3602f6d5ece34fdbd4ffe0a47f1a2ba4'] = 'Gracias. Tu pago ha sido recibido.'; -$_MODULE['<{mollie}prestashop>mollie_7352a401b3c23b2966c68bc9ab97fa06'] = 'La transacción tiene un estado inesperado.'; -$_MODULE['<{mollie}prestashop>mollie_3f83176ddc3f63a5a374a623840bfb09'] = 'No estás autorizado a ver esta página.'; -$_MODULE['<{mollie}prestashop>mollie_300225ee958b6350abc51805dab83c24'] = 'Continuar comprando'; -$_MODULE['<{mollie}prestashop>mollie_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenido de nuevo'; -$_MODULE['<{mollie}prestashop>mollie_66dac2278292ff24611ef8a85bc94e0d'] = 'Selecciona tu banco:'; -$_MODULE['<{mollie}prestashop>mollie_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK:'; -$_MODULE['<{mollie}prestashop>mollie_b98a07c82f0078a1de7fc219fae480fc'] = 'Método de pago diferente'; -$_MODULE['<{mollie}prestashop>mollie_35895cff7df70dab18783453e2bd241f'] = 'Paga con %s'; -$_MODULE['<{mollie}prestashop>mollie_cc16e103e202a48009df202d9525f75f'] = 'Devuelve esta compra'; -$_MODULE['<{mollie}prestashop>mollie_c5222afef6530f674d3acf82ba2ce9dc'] = 'Devolución Mollie'; -$_MODULE['<{mollie}prestashop>mollie_7064b25aa8a732a3db7f230c9867be19'] = 'Devuelve el pedido #%d a través de la API Mollie'; -$_MODULE['<{mollie}prestashop>mollie_e12682d2e0650f2783b22d956d2b947a'] = '¡Este pedido ha sido reintegrado!'; -$_MODULE['<{mollie}prestashop>mollie_95be87afb2734075cf345b633e1384ec'] = 'Mollie B.V. Se hará la transferencia de vuelta al cliente en el siguiente día laboral.'; -$_MODULE['<{mollie}prestashop>mollie_9770d1f0124abb0d6a894cd79f8703b5'] = 'Esperando pago Mollie'; -$_MODULE['<{mollie}prestashop>mollie_b9fc80a6e775cb75568db6b6538dacdd'] = 'Mollie parcialmente reintegrado'; -$_MODULE['<{mollie}prestashop>mollie_f91ab041fe9d6057740394b8b7903a0f'] = 'iDEAL'; -$_MODULE['<{mollie}prestashop>mollie_b749cfb52bfd82c5b12aa49d6906b8e8'] = 'CartaSi'; -$_MODULE['<{mollie}prestashop>mollie_05bfde942b997737b56b9ab405450076'] = 'Cartes Bancaires'; -$_MODULE['<{mollie}prestashop>mollie_e7f9e382dc50889098cbe56f2554c77b'] = 'Tarjeta de crédito'; -$_MODULE['<{mollie}prestashop>mollie_870cf6bc77bbadd038aeb8d942c9cb18'] = 'Bancontact'; -$_MODULE['<{mollie}prestashop>mollie_8ad65eb3da9995173280649f090218c3'] = 'Banca SOFORT'; -$_MODULE['<{mollie}prestashop>mollie_c0db4214f9d7e1b846f4496e03e667d0'] = 'Débito directo SEPA'; -$_MODULE['<{mollie}prestashop>mollie_5aa515ce21e8de1ed7416dce455a151f'] = 'Botón de pago Belfius'; -$_MODULE['<{mollie}prestashop>mollie_d023ec040f79f1a9b2ac960b43785089'] = 'Bitcoin'; -$_MODULE['<{mollie}prestashop>mollie_4aa65ea89e54d83bb2604c2cc89babc3'] = 'PODIUM Cadeaukaart'; -$_MODULE['<{mollie}prestashop>mollie_58c25c4b8b4382e37d89e0ef6bd625cf'] = 'Tarjeta de regalo'; -$_MODULE['<{mollie}prestashop>mollie_431647a0a8b2cd589c9fda9535f90d6d'] = 'Transferencia bancaria'; -$_MODULE['<{mollie}prestashop>mollie_ad69e733ebae8d264bccaa38d68830e8'] = 'Paypal'; -$_MODULE['<{mollie}prestashop>mollie_6abcd8eecb4f2abb6ccfe36ef7046ba0'] = 'paysafecard'; -$_MODULE['<{mollie}prestashop>mollie_a81bd6195f1abce35fd03a870270100b'] = 'Botón de pago KBC/CBC'; -$_MODULE['<{mollie}prestashop>mollie_8184c64d6318b4a42428ae21d0fe2311'] = 'ING Home\'Pay '; -$_MODULE['<{mollie}prestashop>mollie_31911306551723245e7417ae4520fecb'] = 'Giropay'; -$_MODULE['<{mollie}prestashop>mollie_ce8e4a184e2e534c09d6bf6ae773ca4a'] = 'eps'; -$_MODULE['<{mollie}prestashop>mollie_feb1a8ded87483b416427b8457bdc664'] = 'Pagar más tarde'; -$_MODULE['<{mollie}prestashop>mollie_a388a6fba0d4b58c334cd9416071cdb1'] = 'Slice it.'; -$_MODULE['<{mollie}prestashop>mollie_d1913efa9eae51595a33f3c1410d465c'] = 'El método %s está sobrescrito por el módulo %s. Esto puede causar interferencias con los pagos.'; -$_MODULE['<{mollie}prestashop>mollie_6311eb29dee3acc14071e0b1efb173f5'] = '%s estados:'; -$_MODULE['<{mollie}prestashop>mollie_d438a1d96c6037fccad15d7594737a84'] = 'Configuración visual:'; -$_MODULE['<{mollie}prestashop>mollie_49259add73e416838e985a6bf4d0e571'] = 'Depurar información:'; -$_MODULE['<{mollie}prestashop>mollie_c9cc8cce247e49bae79f15173ce97354'] = 'Guardar'; -$_MODULE['<{mollie}prestashop>mollie_5bef23eb7efff2736c5583bda59e5eb7'] = 'Crear tu cuenta'; -$_MODULE['<{mollie}prestashop>mollie_a77e6fc49f07414fc53336c8d879b73e'] = '¿Ya tienes una clave API? Si es así puedes saltar este paso y proceder a introducir tu clave API.'; -$_MODULE['<{mollie}prestashop>mollie_21aef67e8d12503aff027385d0a7867f'] = 'Nombre y Apellidos'; -$_MODULE['<{mollie}prestashop>mollie_b357b524e740bc85b9790a0712d84a30'] = 'Dirección de correo'; -$_MODULE['<{mollie}prestashop>mollie_e93c33bd1341ab74195430daeb63db13'] = 'Nombre de la tienda'; -$_MODULE['<{mollie}prestashop>mollie_dd7bf230fde8d4836917806aff6a6b27'] = 'Dirección'; -$_MODULE['<{mollie}prestashop>mollie_8bcdc441379cbf584638b0589a3f9adb'] = 'Código postal'; -$_MODULE['<{mollie}prestashop>mollie_57d056ed0984166336b7879c2af3657f'] = 'Ciudad'; -$_MODULE['<{mollie}prestashop>mollie_59716c97497eb9694541f7c3d37b1a4d'] = 'País'; -$_MODULE['<{mollie}prestashop>mollie_686e697538050e4664636337cc3b834f'] = 'Crear'; -$_MODULE['<{mollie}prestashop>mollie_7c4e7ada50c8572336f872fced4d1852'] = 'Estado para los pagos %s'; -$_MODULE['<{mollie}prestashop>mollie_bea3fae02ae079e541199ab6ffc2d1ad'] = 'Los pagos `%s` tienen el estado `%s`'; -$_MODULE['<{mollie}prestashop>mollie_b2a2c5a69af7c04c5adc48261fb5dc13'] = 'Enviar correos cuando %s'; -$_MODULE['<{mollie}prestashop>mollie_0511c3431d4e32ed4266fe943014d000'] = '¿Enviar correo cuando el estado de la transacción se convierte en %s?'; -$_MODULE['<{mollie}prestashop>mollie_7aace0dc23ee8b74744bdf79c98a2605'] = 'Saltarse este estado'; -$_MODULE['<{mollie}prestashop>mollie_dd59e3663865f3fab190e496260608e6'] = 'Los pagos `%s` no tienen un estado'; -$_MODULE['<{mollie}prestashop>mollie_824f2c1d1c2ee9aecac9977d9347a2ea'] = 'Configuración Mollie'; -$_MODULE['<{mollie}prestashop>mollie_d876ff8da67c3731ae25d8335a4168b4'] = 'Clave API'; -$_MODULE['<{mollie}prestashop>mollie_2ffbc7eb8899865f9e66682d34853195'] = 'Puedes encontrar tu clave API en tu [1]Perfil Mollie[/1]; empieza con test o live.'; -$_MODULE['<{mollie}prestashop>mollie_b5a7adde1af5c87d7fd797b6245c2a39'] = 'Descripción'; -$_MODULE['<{mollie}prestashop>mollie_3150652ab7f22bafe11a78d4cc0de8be'] = 'Introduce una descripción aquí. Nota: los métodos de pago pueden tener un límite de caracteres, lo mejor es mantener la descripción bajo 29 caracteres. Puedes usar las siguientes variables: %s'; -$_MODULE['<{mollie}prestashop>mollie_8d9143dfc520ed7d982d4e545c7bfc5e'] = 'Enviar localización para la pantalla de pago'; -$_MODULE['<{mollie}prestashop>mollie_1239c091f39c068882e924e34dd9cc40'] = 'Debería el plugin enviar la actual [1]Localización[/1] a Mollie. Las pantallas de pago de Mollie estarán en el mismo lenguaje que tu tienda web. Mollie también puede detectar el lenguaje basándose en el lenguaje de navegador del usuario.'; -$_MODULE['<{mollie}prestashop>mollie_80a78bb16945665b6410ae8d93e81c69'] = 'No enviar localización usando el lenguaje del navegador'; -$_MODULE['<{mollie}prestashop>mollie_3ba67aae5d08d0fa90016685407926f1'] = 'Configuración visual'; -$_MODULE['<{mollie}prestashop>mollie_fff0d600f8a0b5e19e88bfb821dd1157'] = 'Imágenes'; -$_MODULE['<{mollie}prestashop>mollie_f7a97136df639501521efb243047e0cf'] = 'Mostrar logos grandes, normales, o no mostrarlos en el checkout.'; -$_MODULE['<{mollie}prestashop>mollie_a88f05b6c963e145a45b58c47cd42a41'] = 'esconder'; -$_MODULE['<{mollie}prestashop>mollie_fea087517c26fadd409bd4b9dc642555'] = 'normal'; -$_MODULE['<{mollie}prestashop>mollie_d861877da56b8b4ceb35c8cbfdf65bb4'] = 'grande'; -$_MODULE['<{mollie}prestashop>mollie_85fb708f31f585607247f8b868efafcc'] = 'Lista de distribuidor'; -$_MODULE['<{mollie}prestashop>mollie_27db39558366d2a9001a0dec69eea4d6'] = 'Algunos métodos de pago (Ej. IDEAL) tienen una lista de distribuidor. Esta configuración especifica donde es mostrada.'; -$_MODULE['<{mollie}prestashop>mollie_85a692706bc7597b6e32bc1d354c138f'] = 'En click'; -$_MODULE['<{mollie}prestashop>mollie_ea9b19c6f2e9ef60b49778ab9396b293'] = 'Página propia'; -$_MODULE['<{mollie}prestashop>mollie_d35acbb07d2841712a937d5748e9bdc2'] = 'Página de pago'; -$_MODULE['<{mollie}prestashop>mollie_1547ffc579d657d13fd5fedf12cbfae5'] = 'Archivo CSS'; -$_MODULE['<{mollie}prestashop>mollie_6602513644161421f58418528d93ac00'] = 'Dejar vacío para el estilo de página por defecto. Debe de incluirse la ruta del archivo cuando se fija. Pista: puedes usar [1]{BASE}[/1], [1]{TEMA}[/1], [1]{CSS}[/1], [1]{MOVIL}[/1], [1]{MOVILCSS}[/1] y [1]{ANULAR}[/1] '; -$_MODULE['<{mollie}prestashop>mollie_0da8d9a75492046bea7f314521e07cae'] = 'Métodos de pago'; -$_MODULE['<{mollie}prestashop>mollie_75886bf821fc9c068a280fe52337c0f5'] = 'Habilitar o deshabilitar los métodos de pago. Puedes arrastrar y soltar para reorganizar los métodos de pago.'; -$_MODULE['<{mollie}prestashop>mollie_c576349bf8ff5fba4e9369ab581a4074'] = 'Habilitar IDEAL QR'; -$_MODULE['<{mollie}prestashop>mollie_c0ae4417e7a196f3ccfadff68a5064ed'] = 'Los códigos QR no están actualmente admitidos para la API de pedidos. ¡Nuestras disculpas por las molestias!'; -$_MODULE['<{mollie}prestashop>mollie_e17dc77fb83539b6a4687c6d515791e4'] = '%s estados'; -$_MODULE['<{mollie}prestashop>mollie_4695fd3a22023ab53a2151f797975ff8'] = 'Deshabilitar este estatus'; -$_MODULE['<{mollie}prestashop>mollie_656f9fd6f874404599220855cfec17ef'] = 'API Mollie'; -$_MODULE['<{mollie}prestashop>mollie_a1532be2c9ef11d7dd5edd974fc6c98c'] = 'Seleccionar que API Mollie usar'; -$_MODULE['<{mollie}prestashop>mollie_9ce1d2272c82bfd7d501a6697df774c7'] = '¿Debería el plugin usar la nueva API de Mollie Orders? Esto habilita los métodos de pago tales como Klarna Pay Later.'; -$_MODULE['<{mollie}prestashop>mollie_8c2b4949d892b39b236545951f10bbd4'] = 'API de pagos'; -$_MODULE['<{mollie}prestashop>mollie_a8b0255f70ecc140a1b5134ae5217e51'] = 'API de Pedidos'; -$_MODULE['<{mollie}prestashop>mollie_1191f888f0cc23f95aa77aacb094503b'] = 'Información de envío'; -$_MODULE['<{mollie}prestashop>mollie_d822c02513be98814bdd39f8bae598d1'] = 'Enviar automáticamente cuando esté marcado como `enviado`'; -$_MODULE['<{mollie}prestashop>mollie_0eccefc4c96190190add75fe0a74fcd4'] = 'Habilitando esta característica se enviará automáticamente tu información de envío cuando un encargo se marce como `enviado`'; -$_MODULE['<{mollie}prestashop>mollie_c1df8a5243557cbd8a7a31c11aab3db4'] = 'Enviar automáticamente cuando se alcanza uno de estos estados'; -$_MODULE['<{mollie}prestashop>mollie_34bd91e87db36a10b9e847d6304be289'] = 'Si un encargo alcanza uno de estos estados el módulo enviará automáticamente la información de envío'; -$_MODULE['<{mollie}prestashop>mollie_498f79c4c5bbde77f1bceb6c86fd0f6d'] = 'Mostrar'; -$_MODULE['<{mollie}prestashop>mollie_62a5e490880a92eef74f167d9dc6dca0'] = 'Esconder'; -$_MODULE['<{mollie}prestashop>mollie_dc6e4b439165a4e104c9f3cbfcfe2797'] = 'Nivel de depuración'; -$_MODULE['<{mollie}prestashop>mollie_500aa80d6aea3cc9701b566c5f92ed91'] = 'Errores de visualización'; -$_MODULE['<{mollie}prestashop>mollie_37f9a8b20930c1dc7488b15872b6d36b'] = 'Si se habilita esta característica se mostrarán los mensajes de error (si existen) en la página principal. ¡Usar para motivos de depuración únicamente!'; -$_MODULE['<{mollie}prestashop>mollie_e5114c4b69585ba5883d456a74c1cd5d'] = 'Nivel de registro'; -$_MODULE['<{mollie}prestashop>mollie_921a6d905eef99631c9c73c317799e62'] = 'Niveles recomendados: Errores. Establecer como "Todo" para monitorizar los pedidos webhook. [1]Ver registros.[/1]'; -$_MODULE['<{mollie}prestashop>mollie_f80a4ad87fee7c9fdc19b7769495fdb5'] = 'Nada'; -$_MODULE['<{mollie}prestashop>mollie_5ef0c737746fae2ca90e66c39333f8f6'] = 'Errores'; -$_MODULE['<{mollie}prestashop>mollie_709468af25e91284821d1bdbfdded24c'] = 'Todo'; -$_MODULE['<{mollie}prestashop>mollie_1f93fc361bfc627c89a46e1b6c28df2b'] = 'La clave API debe de empezar con Test o Live'; -$_MODULE['<{mollie}prestashop>mollie_6ab1adfed768d989b47c908755fe677f'] = '¡La configuración ha sido guardada!'; -$_MODULE['<{mollie}prestashop>mollie_1f91cd9f380285bf1219c79ab7fcb75e'] = 'Advertencia: No se puede recuperar el archivo de actualización de github.'; -$_MODULE['<{mollie}prestashop>mollie_ce1e483d5cd4b349af887fa3e198ea6b'] = 'No se ha encontrado un paquete para el último lanzamiento.'; -$_MODULE['<{mollie}prestashop>mollie_048ef1905ff33382d7660a68a6199305'] = 'Advertencia: No se puede recuperar el archivo de actualización xml de github.'; -$_MODULE['<{mollie}prestashop>mollie_711d42f319398490b32cd0e2f0b8ccb8'] = 'Advertencia: El archivo de actualización xml de github muestra un formato inexperado.'; -$_MODULE['<{mollie}prestashop>mollie_48fa0f621f79f451e58f200957da5b52'] = 'Elige tu banco'; -$_MODULE['<{mollie}prestashop>mollie_8953fb7da2299bf905b73720f611baa3'] = 'o paga con IDEAL QR'; -$_MODULE['<{mollie}prestashop>mollie_961f2247a2070bedff9f9cd8d64e2650'] = 'Elige'; -$_MODULE['<{mollie}prestashop>mollie_ea4788705e6873b424c65e91c2846b19'] = 'Cancelar'; -$_MODULE['<{mollie}prestashop>mollie_ea9cf7e47ff33b2be14e6dd07cbcefc6'] = 'Envío'; -$_MODULE['<{mollie}prestashop>mollie_f93bd0f858a6e5f70cb458c90a36172b'] = 'No es posible recuperar la información de la última versión'; -$_MODULE['<{mollie}prestashop>mollie_ced93781bca50eb4d970ea51abcc622c'] = '¡Ya estás usando la última versión!'; -$_MODULE['<{mollie}prestashop>mollie_43f3c5a157c67de9b6faf42b637f963a'] = 'El módulo de archivo no ha podido ser descargado'; -$_MODULE['<{mollie}prestashop>mollie_31dd57eea0f762b4ea6f022b40acc390'] = 'Ha habido un error al extraer el archivo de módulo (el archivo puede estar corrupto).'; -$_MODULE['<{mollie}prestashop>mollie_bad5a3ab102f6e9c27edd494d7e33323'] = 'Tu nueva cuenta Mollie ha sido creada con éxito. Por favor revisa tu bandeja de entrada para obtener más información.'; -$_MODULE['<{mollie}prestashop>mollie_023b7ade110944180153fd73358fc50c'] = 'Ha ocurrido un error desconocido al intentar crear tu cuenta Mollie'; -$_MODULE['<{mollie}prestashop>mollie_3a6e70059673992f825826f7cf89278d'] = 'La regla de carrito llamada "%1s" (ID %2s) usada en este carrito no es válida y ha sido retirada del carrito'; -$_MODULE['<{mollie}prestashop>mollie_3a1048f8aa3a9f6b604fcf7982811752'] = 'Advertencia: la clave de seguridad está vacía, revisa tu cuenta de pago antes de la validación'; -$_MODULE['<{mollie}prestashop>mollie_26beb437d3323bd4bfb0811b3e891315'] = '%d imágen(es)'; -$_MODULE['<{mollie}prestashop>mollie_0791970c961c09eb8caaa61aba6a3ca4'] = 'Ha ocurrido un error al guardar este mensaje'; -$_MODULE['<{mollie}prestashop>mollie_ed13b3693357ebed3751cb71cb639e65'] = 'Sin operador'; -$_MODULE['<{mollie}prestashop>mollie_b08d3867be98e6fff3233cd40ab8134a'] = 'Creación de encargo fallida'; -$_MODULE['<{mollie}prestashop>mollie_43423b4056880b08f2c9aa50d8670531'] = 'El carrito no puede ser cargado o ya se ha creado un encargo usando este carrito'; -$_MODULE['<{mollie}prestashop>mollie_88183b946cc5f0e8c96b2e66e1c74a7e'] = 'Desconocido'; -$_MODULE['<{mollie}prestashop>mollie_32c86f9a2a28a9fa544b97024393633e'] = 'No se han encontrado métodos de pago'; -$_MODULE['<{mollie}prestashop>mollie_301b87d33063f687d14004a9014f6759'] = 'No tienes permisos para devolver pagos'; -$_MODULE['<{mollie}prestashop>mollie_8dc6945fb6b59aea38df7935cf3afb6d'] = 'No tienes permisos para los %s pagos'; -$_MODULE['<{mollie}prestashop>mollie_1bda80f2be4d3658e0baa43fbe7ae8c1'] = 'ver'; -$_MODULE['<{mollie}prestashop>mollie_de95b43bceeb4b998aed4aed5cef1ae7'] = 'editar'; -$_MODULE['<{mollie}prestashop>mollie_2a3f1166b041928019e4e8718d628665'] = 'enviar'; -$_MODULE['<{mollie}prestashop>mollie_df6f85687a0d5820baa1a069a04eff2d'] = 'reintegrar'; -$_MODULE['<{mollie}prestashop>mollie_10aec35353f9c4096a71c38654c3d402'] = 'cancelar'; -$_MODULE['<{mollie}prestashop>payment_c2f73af3130be4b4967a475ab846c546'] = 'Ha ocurrido un error al inicializar tu pago. Por favor entra en contacto con nuestro soporte.'; -$_MODULE['<{mollie}prestashop>download_update_6de6a882c42b757cd027830399a74de4'] = 'Actualizar este módulo'; -$_MODULE['<{mollie}prestashop>download_update_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Error'; -$_MODULE['<{mollie}prestashop>download_update_5d04a002ea59c8114f9d08b0c6250a3b'] = 'No es posible reconectar'; -$_MODULE['<{mollie}prestashop>download_update_3844b140df977eee8639de6d1de9e1e0'] = 'No se a podido descomprimir el nuevo módulo'; -$_MODULE['<{mollie}prestashop>download_update_b50ec141b028d5a8acec4a17c32f3808'] = '¡El módulo ha sido actualizado!'; -$_MODULE['<{mollie}prestashop>new_release_b7f73af7318580996a3889353b282827'] = 'Actualmente estás usando la versión %s. ¡Te recomendamos encarecidamente que mejores a la nueva versión %s!'; -$_MODULE['<{mollie}prestashop>form_93cba07454f06a4a960172bbd6e2a435'] = 'Si'; -$_MODULE['<{mollie}prestashop>form_bafd7322c6e97d25b6299b5d6fe8920b'] = 'No'; -$_MODULE['<{mollie}prestashop>form_2d25c72c1b18e562f6654fff8e11711e'] = 'No disponible'; -$_MODULE['<{mollie}prestashop>form_58afe6389d8f42880d1011ef0de542a2'] = 'Este método de pago no está disponible en la API de pagos. Cambia a la API de encargos a continuación para activar este método.'; -$_MODULE['<{mollie}prestashop>form_9b6a88a9d4a44740f87b1ffa7cb070c4'] = 'No se pueden cargar los métodos de pago'; -$_MODULE['<{mollie}prestashop>form_6327b4e59f58137083214a1fec358855'] = 'Reintentar'; -$_MODULE['<{mollie}prestashop>form_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Error'; -$_MODULE['<{mollie}prestashop>form_49ee3087348e8d44e1feda1917443987'] = 'Nombre'; -$_MODULE['<{mollie}prestashop>form_b33f1d112cd9d2d32d37cb4cc9a340c8'] = 'Fuente de URL'; -$_MODULE['<{mollie}prestashop>form_de28ef21a06f3978c05f3d808b15eaab'] = 'URL del transportista'; -$_MODULE['<{mollie}prestashop>form_812a48ba719daeda82e4da8e812d426c'] = 'URL personalizada'; -$_MODULE['<{mollie}prestashop>form_e55f75a29310d7b60f7ac1d390c8ae42'] = 'Módulo'; -$_MODULE['<{mollie}prestashop>form_962b59a5f12eabd9c05f11b5f0aada85'] = 'No enviar automáticamente'; -$_MODULE['<{mollie}prestashop>form_703490ffd308d337cd5aac50567e9670'] = 'No hay información de seguimiento'; -$_MODULE['<{mollie}prestashop>form_f421a366f70bd2aa1193eeb5a2990546'] = 'Aquí puedes configurar que información sobre el envío es enviada a Mollie'; -$_MODULE['<{mollie}prestashop>form_53b2566e3519ea98db40ae9e716883a5'] = 'Puedes usar las siguientes variables para la URL de transportista'; -$_MODULE['<{mollie}prestashop>form_910d956cb2615e5739ac06c7f08fba26'] = 'Número de envío'; -$_MODULE['<{mollie}prestashop>form_e7e862a02819a1610f271ffea15ed47d'] = 'Código de facturación de país'; -$_MODULE['<{mollie}prestashop>form_5723a18d8a8a6052a57489df5be59a8f'] = 'Código postal de facturación'; -$_MODULE['<{mollie}prestashop>form_0d12e3c554976ad1f76c5db2b6c127ad'] = 'Código de envío de país'; -$_MODULE['<{mollie}prestashop>form_c824a8b18f09dc7e58bacf446be6735c'] = 'Código postal de envío'; -$_MODULE['<{mollie}prestashop>form_0a867177f4a701a9f33de5ab21c42593'] = 'Código de lenguaje de dos letras'; -$_MODULE['<{mollie}prestashop>form_f6fcb64e21455abc4209f8f4440d45f5'] = 'No se ha podido cargar la lista de transportistas'; -$_MODULE['<{mollie}prestashop>form_da93de158db2fbe49f35f6038711584a'] = 'Esta opción no es requerida para la API seleccionada actualmente'; -$_MODULE['<{mollie}prestashop>17_error_47e1924c444fafe9fdfce444790f0ba9'] = 'Volver a tu carrito de la compra'; -$_MODULE['<{mollie}prestashop>error_c453a4b8e8d98e82f35b67f433e3b4da'] = 'Pago'; -$_MODULE['<{mollie}prestashop>error_1e97d97a923eaddd810e056c828e99ea'] = 'Error de pago'; -$_MODULE['<{mollie}prestashop>error_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Ha ocurrido un error'; -$_MODULE['<{mollie}prestashop>error_47e1924c444fafe9fdfce444790f0ba9'] = 'Volver a tu carrito de la compra'; -$_MODULE['<{mollie}prestashop>mollie_issuers_588540a38eeba525f3598b68e6b788e5'] = 'O escoge un método de pago diferente'; -$_MODULE['<{mollie}prestashop>mollie_return_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenido de nuevo'; -$_MODULE['<{mollie}prestashop>mollie_return_300225ee958b6350abc51805dab83c24'] = 'Continuar comprando'; -$_MODULE['<{mollie}prestashop>mollie_wait_bc0dd919f9a70dbb62f3f7afd68d6d68'] = 'Esperando estado de pago'; -$_MODULE['<{mollie}prestashop>qr_done_92816c7248d010591f699db3aaf6287b'] = 'Mollie iDEAL QR'; -$_MODULE['<{mollie}prestashop>qr_done_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenido de nuevo'; -$_MODULE['<{mollie}prestashop>qr_done_4bf3a07ce980c9b007f9e2eed42d7fa2'] = 'El pago ha sido cancelado.'; -$_MODULE['<{mollie}prestashop>qr_done_6933c118341d8c06f888c392aa1ceaf5'] = 'El pago ha sido completado. ¡Gracias por tu pedido!'; -$_MODULE['<{mollie}prestashop>ideal_dropdown_ab4147235204a436c09e00d6722082ab'] = 'Elige un banco'; -$_MODULE['<{mollie}prestashop>order_info_729a51874fe901b092899e9e8b31c97a'] = '¿Estás seguro?'; -$_MODULE['<{mollie}prestashop>order_info_ccaf4ee393d094ecde7f21b15fdf8f1f'] = '¿Estás seguro de que quieres devolver este pedido?'; -$_MODULE['<{mollie}prestashop>order_info_76f0ed934de85cc7131910b32ede7714'] = 'Reintegrar'; -$_MODULE['<{mollie}prestashop>order_info_ea4788705e6873b424c65e91c2846b19'] = 'Cancelar'; -$_MODULE['<{mollie}prestashop>order_info_88ba0dcbc82905637e98317e0302cfd8'] = 'Devolver pedido'; -$_MODULE['<{mollie}prestashop>order_info_5a1119ecb764165f27cb37b6f50134f2'] = 'Restante'; -$_MODULE['<{mollie}prestashop>order_info_77fd2b4393b379bedd30efcd5df02090'] = 'Devolución parcial'; -$_MODULE['<{mollie}prestashop>order_info_a9ced76f2dd6907220fa95b3a136b04a'] = 'Cantidad inválida'; -$_MODULE['<{mollie}prestashop>order_info_3a2c3e97fed586776c2800fb7a0faf4e'] = 'Has introducido una cantidad inválida'; -$_MODULE['<{mollie}prestashop>order_info_3cc4859e502556d0d848c3bc38618782'] = 'Devolución fallida'; -$_MODULE['<{mollie}prestashop>order_info_d5cfd0f69cd548e5d3b9edde5ff1b48f'] = 'Información de pago'; -$_MODULE['<{mollie}prestashop>order_info_88427ec035734b45aae9f7d8859a5008'] = 'ID de transacción'; -$_MODULE['<{mollie}prestashop>order_info_782678f4ba02feb3e9ecd51e902cd16b'] = 'Historial de devoluciones'; -$_MODULE['<{mollie}prestashop>order_info_c5b41ae59bd6585750f536615a6bc20b'] = 'No hay devoluciones'; -$_MODULE['<{mollie}prestashop>order_info_b718adec73e04ce3ec720dd11a06a308'] = 'ID'; -$_MODULE['<{mollie}prestashop>order_info_44749712dbec183e983dcd78a7736c41'] = 'Fecha'; -$_MODULE['<{mollie}prestashop>order_info_b2f40690858b404ed10e62bdf422c704'] = 'Cantidad'; -$_MODULE['<{mollie}prestashop>order_info_53beb26d8bca00f56fbd295fdee83459'] = 'Devoluciones'; -$_MODULE['<{mollie}prestashop>order_info_daef64964ee3b9b904f5d467586e217f'] = 'Pagos'; -$_MODULE['<{mollie}prestashop>order_info_e25be354288565757726f3295e4f3ef9'] = 'Cantidad actual'; -$_MODULE['<{mollie}prestashop>order_info_068f80c7519d0528fb08e82137a72131'] = 'Productos'; -$_MODULE['<{mollie}prestashop>order_info_ec53a8c4f07baed5d8825072c89799be'] = 'Estado'; -$_MODULE['<{mollie}prestashop>order_info_747cf5c8587184b9e489ff897d97c20d'] = 'Enviado'; -$_MODULE['<{mollie}prestashop>order_info_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Cancelado'; -$_MODULE['<{mollie}prestashop>order_info_cc61945cbbf46721a053467c395c666f'] = 'Reinstegrado'; -$_MODULE['<{mollie}prestashop>order_info_197101c4a1b1fc503dcd6ebee127aa10'] = 'Precio de unidad'; -$_MODULE['<{mollie}prestashop>order_info_11cd653a2488e260a8a99f39cdffa6e7'] = 'Cantidad de IVA'; -$_MODULE['<{mollie}prestashop>order_info_bc30768048a7bbfd2d158d722c140c6d'] = 'Cantidad total'; -$_MODULE['<{mollie}prestashop>order_info_0387832795db3eb2e05f4365fba5ddac'] = 'Enviar'; -$_MODULE['<{mollie}prestashop>order_info_55453aad10c96e452556a106447313bd'] = 'Revisar envío'; -$_MODULE['<{mollie}prestashop>order_info_dbb5bbb116e16973136b9ebd887eaadd'] = 'Por favor revisa los productos incluidos en tu envío Puedes eliminar objetos o cambiar la cantidad si es necesario.'; -$_MODULE['<{mollie}prestashop>order_info_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK:'; -$_MODULE['<{mollie}prestashop>order_info_163bcc6065b16c6369c7a4de44cff164'] = 'Enviar productos'; -$_MODULE['<{mollie}prestashop>order_info_433557a938a920888445ce2c7df67d5a'] = 'Detalles de seguimiento'; -$_MODULE['<{mollie}prestashop>order_info_61995a579a6166642e759450a694642b'] = 'Añadir información de seguimiento a tu envío es recomendable, ya que demuestra que has enviado tus productos al cliente.'; -$_MODULE['<{mollie}prestashop>order_info_26b6254fefc06894825a50dfbe803937'] = 'Saltarse detalles de seguimiento'; -$_MODULE['<{mollie}prestashop>order_info_d57c24f3fe52d16e7169b912dd647f0d'] = 'opcional'; -$_MODULE['<{mollie}prestashop>order_info_2df417909bda5f3ddc210a0abe65231f'] = 'Ej. FedEx'; -$_MODULE['<{mollie}prestashop>order_info_593ed3a37aa1a3ece4a4d796fb4e2e03'] = 'Esta información es necesaria'; -$_MODULE['<{mollie}prestashop>order_info_933292561b46133ff5348c7740874c56'] = 'Código de seguimiento'; -$_MODULE['<{mollie}prestashop>order_info_e6b391a8d2c4d45902a23a8b6585703d'] = 'URL'; -$_MODULE['<{mollie}prestashop>order_info_914419aa32f04011357d3b604a86d7eb'] = 'Transportista'; -$_MODULE['<{mollie}prestashop>order_info_23a902ac637359fe67ceaccbe2c68283'] = 'Enviar todo'; -$_MODULE['<{mollie}prestashop>order_info_2a6e9f678c7267fe16f57bcd3285f1d7'] = 'Cancelar todo'; -$_MODULE['<{mollie}prestashop>order_info_05ced64413f9ff5d3602c3e257f36204'] = 'Devolver todo'; -$_MODULE['<{mollie}prestashop>order_info_bfe005bff7ecacd6ecceacdd7fb79292'] = 'Información de la transacción'; -$_MODULE['<{mollie}prestashop>order_info_1eefa98a18a384699fe611fbfd8ab0c9'] = 'No hay productos'; -$_MODULE['<{mollie}prestashop>order_info_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Ha ocurrido un error'; -$_MODULE['<{mollie}prestashop>order_info_2df3102f3fe061003dee820a72e1b1ed'] = 'No es posible realizar el envío'; -$_MODULE['<{mollie}prestashop>order_info_3efc29552025b4e68de04f415b0b8806'] = 'No es posible realizar la devolución'; -$_MODULE['<{mollie}prestashop>order_info_468a92810b526750be9664461db6bf91'] = 'No es posible cancelar'; -$_MODULE['<{mollie}prestashop>order_info_2427b479f15af44582dc151ef95a90d0'] = 'Las devoluciones no están disponibles actualmente'; -$_MODULE['<{mollie}prestashop>qr_code_9ba19ddbcfeddfc758eb84fb8ba26b5e'] = 'o escanea el código iDEAL QR'; -$_MODULE['<{mollie}prestashop>refund_729a51874fe901b092899e9e8b31c97a'] = '¿Estás seguro?'; -$_MODULE['<{mollie}prestashop>refund_ccaf4ee393d094ecde7f21b15fdf8f1f'] = '¿Estás seguro de que quieres devolver este pedido?'; -$_MODULE['<{mollie}prestashop>refund_76f0ed934de85cc7131910b32ede7714'] = 'Reintegrar'; -$_MODULE['<{mollie}prestashop>refund_ea4788705e6873b424c65e91c2846b19'] = 'Cancelar'; -$_MODULE['<{mollie}prestashop>rounding_error_7783c757cd1177e60888080e0f4e0593'] = 'La opción de configuración "%s" ha sido fijada a un valor no soportado'; -$_MODULE['<{mollie}prestashop>rounding_error_2279522d0910767ffa75e0b39ed1629f'] = 'El modo de redondeo seleccionado no está soportado por la API Mollie Orders'; -$_MODULE['<{mollie}prestashop>rounding_error_3a92c96baa86286685b233e6912e718d'] = 'Por favor navega a la página "%s" y elige la opción "%s"'; -$_MODULE['<{mollie}prestashop>smarty_error_9d1fbbe0d150b89f068ba72a20366659'] = 'La opción de configuración "%s" ha sido fijada a "%s"'; -$_MODULE['<{mollie}prestashop>smarty_error_27dd3bb10855eb84f48efedf6924c4c1'] = 'Esto hace imposible el mostrar métodos de pago en el checkout'; -$_MODULE['<{mollie}prestashop>smarty_error_4ec23c59d832a2934277a2a040918789'] = 'Por favor navega a la página "%s" y elige la otra opción'; -$_MODULE['<{mollie}prestashop>smarty_error_92b67311c1a5d6cfc28ba08a1066c901'] = 'Después, limpia el caché una vez más, para que la lista de métodos de pago sea refrescada'; -$_MODULE['<{mollie}prestashop>smarty_warning_9d1fbbe0d150b89f068ba72a20366659'] = 'La opción de configuración "%s", ha sido establecida como "%s".'; -$_MODULE['<{mollie}prestashop>smarty_warning_e7e747f9c74f0b8222c87db24d34f018'] = 'Es posible que no puedan mostrarse todas las formas de pago.'; -$_MODULE['<{mollie}prestashop>smarty_warning_1238db0fb782f758b5a54d6333b3610e'] = 'Para solucionar este problema, diríjase a la página "%s" y despeje el caché manualmente o escoja otra opción.'; +mollie_484f5a79672cebe198ebdde45a1d672f'] = 'Envoltorio de regalo'; +$_MODULE['<{mollie}prestashop>mollie_7c478959c218087ffc4ad5d96e7f66a6'] = 'Mollie'; +$_MODULE['<{mollie}prestashop>mollie_95b3b272e06dcc3cc2aa62f6887aebc5'] = 'Pagos Mollie'; +$_MODULE['<{mollie}prestashop>mollie_48dedcf43487615c84c1bbbf6fe76c76'] = '¿Estás seguro de que quieres desinstalar el módulo de pagos Mollie?'; +$_MODULE['<{mollie}prestashop>mollie_ab552f085567bbe63872c10a3596cd27'] = 'Error de Pago:'; +$_MODULE['<{mollie}prestashop>mollie_e0010a0a1a3259ab5c06a19bad532851'] = 'Pagado'; +$_MODULE['<{mollie}prestashop>mollie_a206428462686af481cb072b8db11784'] = 'Autorizado'; +$_MODULE['<{mollie}prestashop>mollie_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Cancelado'; +$_MODULE['<{mollie}prestashop>mollie_24fe48030f7d3097d5882535b04c3fa8'] = 'Expirado'; +$_MODULE['<{mollie}prestashop>mollie_cc61945cbbf46721a053467c395c666f'] = 'Reinstegrado'; +$_MODULE['<{mollie}prestashop>mollie_7026e386bdad92fa6f232394f5b23ffb'] = 'Transferencia bancaria pendiente'; +$_MODULE['<{mollie}prestashop>mollie_9f004157e4c148dac71da3ae5906351f'] = 'Parcialmente reintegrado'; +$_MODULE['<{mollie}prestashop>mollie_0eceeb45861f9585dd7a97a3e36f85c6'] = 'Creado'; +$_MODULE['<{mollie}prestashop>mollie_e2b7dec8fa4b498156dfee6e4c84b156'] = 'Este método de pago no esta disponible'; +$_MODULE['<{mollie}prestashop>mollie_96d0e2862e0167af0c2fd0c99fe6bc5d'] = 'Haz click aquí para continuar'; +$_MODULE['<{mollie}prestashop>mollie_540d9939d1ca9406e215ee3d78c76813'] = 'Este método de pago solo está disponible para Euros.'; +$_MODULE['<{mollie}prestashop>mollie_1b2631119333d97dbda37f87e378b1e4'] = 'Ha habido un error al procesar tu petición:'; +$_MODULE['<{mollie}prestashop>mollie_11bab828edcc0a6d5c97cbf84d61e652'] = 'El encargo con esta id no existe.'; +$_MODULE['<{mollie}prestashop>mollie_b34487c5f391f47b893ee3c61f8f9ab7'] = 'No hemos recibido un estado del pago definitivo. Serás notificado tan pronto como recibamos confirmación del banco/mercader.'; +$_MODULE['<{mollie}prestashop>mollie_57bc999b3b730ead92ac7243fe254a2a'] = 'Desafortunadamente tu pago ha expirado.'; +$_MODULE['<{mollie}prestashop>mollie_3602f6d5ece34fdbd4ffe0a47f1a2ba4'] = 'Gracias. Tu pago ha sido recibido.'; +$_MODULE['<{mollie}prestashop>mollie_7352a401b3c23b2966c68bc9ab97fa06'] = 'La transacción tiene un estado inesperado.'; +$_MODULE['<{mollie}prestashop>mollie_3f83176ddc3f63a5a374a623840bfb09'] = 'No estás autorizado a ver esta página.'; +$_MODULE['<{mollie}prestashop>mollie_300225ee958b6350abc51805dab83c24'] = 'Continuar comprando'; +$_MODULE['<{mollie}prestashop>mollie_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenido de nuevo'; +$_MODULE['<{mollie}prestashop>mollie_66dac2278292ff24611ef8a85bc94e0d'] = 'Selecciona tu banco:'; +$_MODULE['<{mollie}prestashop>mollie_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK:'; +$_MODULE['<{mollie}prestashop>mollie_b98a07c82f0078a1de7fc219fae480fc'] = 'Método de pago diferente'; +$_MODULE['<{mollie}prestashop>mollie_35895cff7df70dab18783453e2bd241f'] = 'Paga con %s'; +$_MODULE['<{mollie}prestashop>mollie_cc16e103e202a48009df202d9525f75f'] = 'Devuelve esta compra'; +$_MODULE['<{mollie}prestashop>mollie_c5222afef6530f674d3acf82ba2ce9dc'] = 'Devolución Mollie'; +$_MODULE['<{mollie}prestashop>mollie_7064b25aa8a732a3db7f230c9867be19'] = 'Devuelve el pedido #%d a través de la API Mollie'; +$_MODULE['<{mollie}prestashop>mollie_e12682d2e0650f2783b22d956d2b947a'] = '¡Este pedido ha sido reintegrado!'; +$_MODULE['<{mollie}prestashop>mollie_95be87afb2734075cf345b633e1384ec'] = 'Mollie B.V. Se hará la transferencia de vuelta al cliente en el siguiente día laboral.'; +$_MODULE['<{mollie}prestashop>mollie_9770d1f0124abb0d6a894cd79f8703b5'] = 'Esperando pago Mollie'; +$_MODULE['<{mollie}prestashop>mollie_b9fc80a6e775cb75568db6b6538dacdd'] = 'Mollie parcialmente reintegrado'; +$_MODULE['<{mollie}prestashop>mollie_f91ab041fe9d6057740394b8b7903a0f'] = 'iDEAL'; +$_MODULE['<{mollie}prestashop>mollie_b749cfb52bfd82c5b12aa49d6906b8e8'] = 'CartaSi'; +$_MODULE['<{mollie}prestashop>mollie_05bfde942b997737b56b9ab405450076'] = 'Cartes Bancaires'; +$_MODULE['<{mollie}prestashop>mollie_e7f9e382dc50889098cbe56f2554c77b'] = 'Tarjeta de crédito'; +$_MODULE['<{mollie}prestashop>mollie_870cf6bc77bbadd038aeb8d942c9cb18'] = 'Bancontact'; +$_MODULE['<{mollie}prestashop>mollie_8ad65eb3da9995173280649f090218c3'] = 'Banca SOFORT'; +$_MODULE['<{mollie}prestashop>mollie_c0db4214f9d7e1b846f4496e03e667d0'] = 'Débito directo SEPA'; +$_MODULE['<{mollie}prestashop>mollie_5aa515ce21e8de1ed7416dce455a151f'] = 'Botón de pago Belfius'; +$_MODULE['<{mollie}prestashop>mollie_d023ec040f79f1a9b2ac960b43785089'] = 'Bitcoin'; +$_MODULE['<{mollie}prestashop>mollie_4aa65ea89e54d83bb2604c2cc89babc3'] = 'PODIUM Cadeaukaart'; +$_MODULE['<{mollie}prestashop>mollie_58c25c4b8b4382e37d89e0ef6bd625cf'] = 'Tarjeta de regalo'; +$_MODULE['<{mollie}prestashop>mollie_431647a0a8b2cd589c9fda9535f90d6d'] = 'Transferencia bancaria'; +$_MODULE['<{mollie}prestashop>mollie_ad69e733ebae8d264bccaa38d68830e8'] = 'Paypal'; +$_MODULE['<{mollie}prestashop>mollie_6abcd8eecb4f2abb6ccfe36ef7046ba0'] = 'paysafecard'; +$_MODULE['<{mollie}prestashop>mollie_a81bd6195f1abce35fd03a870270100b'] = 'Botón de pago KBC/CBC'; +$_MODULE['<{mollie}prestashop>mollie_8184c64d6318b4a42428ae21d0fe2311'] = 'ING Home\'Pay '; +$_MODULE['<{mollie}prestashop>mollie_31911306551723245e7417ae4520fecb'] = 'Giropay'; +$_MODULE['<{mollie}prestashop>mollie_ce8e4a184e2e534c09d6bf6ae773ca4a'] = 'eps'; +$_MODULE['<{mollie}prestashop>mollie_feb1a8ded87483b416427b8457bdc664'] = 'Pagar más tarde'; +$_MODULE['<{mollie}prestashop>mollie_a388a6fba0d4b58c334cd9416071cdb1'] = 'Slice it.'; +$_MODULE['<{mollie}prestashop>mollie_d1913efa9eae51595a33f3c1410d465c'] = 'El método %s está sobrescrito por el módulo %s. Esto puede causar interferencias con los pagos.'; +$_MODULE['<{mollie}prestashop>mollie_6311eb29dee3acc14071e0b1efb173f5'] = '%s estados:'; +$_MODULE['<{mollie}prestashop>mollie_d438a1d96c6037fccad15d7594737a84'] = 'Configuración visual:'; +$_MODULE['<{mollie}prestashop>mollie_49259add73e416838e985a6bf4d0e571'] = 'Depurar información:'; +$_MODULE['<{mollie}prestashop>mollie_c9cc8cce247e49bae79f15173ce97354'] = 'Guardar'; +$_MODULE['<{mollie}prestashop>mollie_5bef23eb7efff2736c5583bda59e5eb7'] = 'Crear tu cuenta'; +$_MODULE['<{mollie}prestashop>mollie_a77e6fc49f07414fc53336c8d879b73e'] = '¿Ya tienes una clave API? Si es así puedes saltar este paso y proceder a introducir tu clave API.'; +$_MODULE['<{mollie}prestashop>mollie_21aef67e8d12503aff027385d0a7867f'] = 'Nombre y Apellidos'; +$_MODULE['<{mollie}prestashop>mollie_b357b524e740bc85b9790a0712d84a30'] = 'Dirección de correo'; +$_MODULE['<{mollie}prestashop>mollie_e93c33bd1341ab74195430daeb63db13'] = 'Nombre de la tienda'; +$_MODULE['<{mollie}prestashop>mollie_dd7bf230fde8d4836917806aff6a6b27'] = 'Dirección'; +$_MODULE['<{mollie}prestashop>mollie_8bcdc441379cbf584638b0589a3f9adb'] = 'Código postal'; +$_MODULE['<{mollie}prestashop>mollie_57d056ed0984166336b7879c2af3657f'] = 'Ciudad'; +$_MODULE['<{mollie}prestashop>mollie_59716c97497eb9694541f7c3d37b1a4d'] = 'País'; +$_MODULE['<{mollie}prestashop>mollie_686e697538050e4664636337cc3b834f'] = 'Crear'; +$_MODULE['<{mollie}prestashop>mollie_7c4e7ada50c8572336f872fced4d1852'] = 'Estado para los pagos %s'; +$_MODULE['<{mollie}prestashop>mollie_bea3fae02ae079e541199ab6ffc2d1ad'] = 'Los pagos `%s` tienen el estado `%s`'; +$_MODULE['<{mollie}prestashop>mollie_b2a2c5a69af7c04c5adc48261fb5dc13'] = 'Enviar correos cuando %s'; +$_MODULE['<{mollie}prestashop>mollie_0511c3431d4e32ed4266fe943014d000'] = '¿Enviar correo cuando el estado de la transacción se convierte en %s?'; +$_MODULE['<{mollie}prestashop>mollie_7aace0dc23ee8b74744bdf79c98a2605'] = 'Saltarse este estado'; +$_MODULE['<{mollie}prestashop>mollie_dd59e3663865f3fab190e496260608e6'] = 'Los pagos `%s` no tienen un estado'; +$_MODULE['<{mollie}prestashop>mollie_824f2c1d1c2ee9aecac9977d9347a2ea'] = 'Configuración Mollie'; +$_MODULE['<{mollie}prestashop>mollie_d876ff8da67c3731ae25d8335a4168b4'] = 'Clave API'; +$_MODULE['<{mollie}prestashop>mollie_2ffbc7eb8899865f9e66682d34853195'] = 'Puedes encontrar tu clave API en tu [1]Perfil Mollie[/1]; empieza con test o live.'; +$_MODULE['<{mollie}prestashop>mollie_b5a7adde1af5c87d7fd797b6245c2a39'] = 'Descripción'; +$_MODULE['<{mollie}prestashop>mollie_3150652ab7f22bafe11a78d4cc0de8be'] = 'Introduce una descripción aquí. Nota: los métodos de pago pueden tener un límite de caracteres, lo mejor es mantener la descripción bajo 29 caracteres. Puedes usar las siguientes variables: %s'; +$_MODULE['<{mollie}prestashop>mollie_8d9143dfc520ed7d982d4e545c7bfc5e'] = 'Enviar localización para la pantalla de pago'; +$_MODULE['<{mollie}prestashop>mollie_1239c091f39c068882e924e34dd9cc40'] = 'Debería el plugin enviar la actual [1]Localización[/1] a Mollie. Las pantallas de pago de Mollie estarán en el mismo lenguaje que tu tienda web. Mollie también puede detectar el lenguaje basándose en el lenguaje de navegador del usuario.'; +$_MODULE['<{mollie}prestashop>mollie_80a78bb16945665b6410ae8d93e81c69'] = 'No enviar localización usando el lenguaje del navegador'; +$_MODULE['<{mollie}prestashop>mollie_3ba67aae5d08d0fa90016685407926f1'] = 'Configuración visual'; +$_MODULE['<{mollie}prestashop>mollie_fff0d600f8a0b5e19e88bfb821dd1157'] = 'Imágenes'; +$_MODULE['<{mollie}prestashop>mollie_f7a97136df639501521efb243047e0cf'] = 'Mostrar logos grandes, normales, o no mostrarlos en el checkout.'; +$_MODULE['<{mollie}prestashop>mollie_a88f05b6c963e145a45b58c47cd42a41'] = 'esconder'; +$_MODULE['<{mollie}prestashop>mollie_fea087517c26fadd409bd4b9dc642555'] = 'normal'; +$_MODULE['<{mollie}prestashop>mollie_d861877da56b8b4ceb35c8cbfdf65bb4'] = 'grande'; +$_MODULE['<{mollie}prestashop>mollie_85fb708f31f585607247f8b868efafcc'] = 'Lista de distribuidor'; +$_MODULE['<{mollie}prestashop>mollie_27db39558366d2a9001a0dec69eea4d6'] = 'Algunos métodos de pago (Ej. IDEAL) tienen una lista de distribuidor. Esta configuración especifica donde es mostrada.'; +$_MODULE['<{mollie}prestashop>mollie_85a692706bc7597b6e32bc1d354c138f'] = 'En click'; +$_MODULE['<{mollie}prestashop>mollie_ea9b19c6f2e9ef60b49778ab9396b293'] = 'Página propia'; +$_MODULE['<{mollie}prestashop>mollie_d35acbb07d2841712a937d5748e9bdc2'] = 'Página de pago'; +$_MODULE['<{mollie}prestashop>mollie_1547ffc579d657d13fd5fedf12cbfae5'] = 'Archivo CSS'; +$_MODULE['<{mollie}prestashop>mollie_6602513644161421f58418528d93ac00'] = 'Dejar vacío para el estilo de página por defecto. Debe de incluirse la ruta del archivo cuando se fija. Pista: puedes usar [1]{BASE}[/1], [1]{TEMA}[/1], [1]{CSS}[/1], [1]{MOVIL}[/1], [1]{MOVILCSS}[/1] y [1]{ANULAR}[/1] '; +$_MODULE['<{mollie}prestashop>mollie_0da8d9a75492046bea7f314521e07cae'] = 'Métodos de pago'; +$_MODULE['<{mollie}prestashop>mollie_75886bf821fc9c068a280fe52337c0f5'] = 'Habilitar o deshabilitar los métodos de pago. Puedes arrastrar y soltar para reorganizar los métodos de pago.'; +$_MODULE['<{mollie}prestashop>mollie_c576349bf8ff5fba4e9369ab581a4074'] = 'Habilitar IDEAL QR'; +$_MODULE['<{mollie}prestashop>mollie_c0ae4417e7a196f3ccfadff68a5064ed'] = 'Los códigos QR no están actualmente admitidos para la API de pedidos. ¡Nuestras disculpas por las molestias!'; +$_MODULE['<{mollie}prestashop>mollie_e17dc77fb83539b6a4687c6d515791e4'] = '%s estados'; +$_MODULE['<{mollie}prestashop>mollie_4695fd3a22023ab53a2151f797975ff8'] = 'Deshabilitar este estatus'; +$_MODULE['<{mollie}prestashop>mollie_656f9fd6f874404599220855cfec17ef'] = 'API Mollie'; +$_MODULE['<{mollie}prestashop>mollie_a1532be2c9ef11d7dd5edd974fc6c98c'] = 'Seleccionar que API Mollie usar'; +$_MODULE['<{mollie}prestashop>mollie_9ce1d2272c82bfd7d501a6697df774c7'] = '¿Debería el plugin usar la nueva API de Mollie Orders? Esto habilita los métodos de pago tales como Klarna Pay Later.'; +$_MODULE['<{mollie}prestashop>mollie_8c2b4949d892b39b236545951f10bbd4'] = 'API de pagos'; +$_MODULE['<{mollie}prestashop>mollie_a8b0255f70ecc140a1b5134ae5217e51'] = 'API de Pedidos'; +$_MODULE['<{mollie}prestashop>mollie_1191f888f0cc23f95aa77aacb094503b'] = 'Información de envío'; +$_MODULE['<{mollie}prestashop>mollie_d822c02513be98814bdd39f8bae598d1'] = 'Enviar automáticamente cuando esté marcado como `enviado`'; +$_MODULE['<{mollie}prestashop>mollie_0eccefc4c96190190add75fe0a74fcd4'] = 'Habilitando esta característica se enviará automáticamente tu información de envío cuando un encargo se marce como `enviado`'; +$_MODULE['<{mollie}prestashop>mollie_c1df8a5243557cbd8a7a31c11aab3db4'] = 'Enviar automáticamente cuando se alcanza uno de estos estados'; +$_MODULE['<{mollie}prestashop>mollie_34bd91e87db36a10b9e847d6304be289'] = 'Si un encargo alcanza uno de estos estados el módulo enviará automáticamente la información de envío'; +$_MODULE['<{mollie}prestashop>mollie_498f79c4c5bbde77f1bceb6c86fd0f6d'] = 'Mostrar'; +$_MODULE['<{mollie}prestashop>mollie_62a5e490880a92eef74f167d9dc6dca0'] = 'Esconder'; +$_MODULE['<{mollie}prestashop>mollie_dc6e4b439165a4e104c9f3cbfcfe2797'] = 'Nivel de depuración'; +$_MODULE['<{mollie}prestashop>mollie_500aa80d6aea3cc9701b566c5f92ed91'] = 'Errores de visualización'; +$_MODULE['<{mollie}prestashop>mollie_37f9a8b20930c1dc7488b15872b6d36b'] = 'Si se habilita esta característica se mostrarán los mensajes de error (si existen) en la página principal. ¡Usar para motivos de depuración únicamente!'; +$_MODULE['<{mollie}prestashop>mollie_e5114c4b69585ba5883d456a74c1cd5d'] = 'Nivel de registro'; +$_MODULE['<{mollie}prestashop>mollie_921a6d905eef99631c9c73c317799e62'] = 'Niveles recomendados: Errores. Establecer como "Todo" para monitorizar los pedidos webhook. [1]Ver registros.[/1]'; +$_MODULE['<{mollie}prestashop>mollie_f80a4ad87fee7c9fdc19b7769495fdb5'] = 'Nada'; +$_MODULE['<{mollie}prestashop>mollie_5ef0c737746fae2ca90e66c39333f8f6'] = 'Errores'; +$_MODULE['<{mollie}prestashop>mollie_709468af25e91284821d1bdbfdded24c'] = 'Todo'; +$_MODULE['<{mollie}prestashop>mollie_1f93fc361bfc627c89a46e1b6c28df2b'] = 'La clave API debe de empezar con Test o Live'; +$_MODULE['<{mollie}prestashop>mollie_6ab1adfed768d989b47c908755fe677f'] = '¡La configuración ha sido guardada!'; +$_MODULE['<{mollie}prestashop>mollie_1f91cd9f380285bf1219c79ab7fcb75e'] = 'Advertencia: No se puede recuperar el archivo de actualización de github.'; +$_MODULE['<{mollie}prestashop>mollie_ce1e483d5cd4b349af887fa3e198ea6b'] = 'No se ha encontrado un paquete para el último lanzamiento.'; +$_MODULE['<{mollie}prestashop>mollie_048ef1905ff33382d7660a68a6199305'] = 'Advertencia: No se puede recuperar el archivo de actualización xml de github.'; +$_MODULE['<{mollie}prestashop>mollie_711d42f319398490b32cd0e2f0b8ccb8'] = 'Advertencia: El archivo de actualización xml de github muestra un formato inexperado.'; +$_MODULE['<{mollie}prestashop>mollie_48fa0f621f79f451e58f200957da5b52'] = 'Elige tu banco'; +$_MODULE['<{mollie}prestashop>mollie_8953fb7da2299bf905b73720f611baa3'] = 'o paga con IDEAL QR'; +$_MODULE['<{mollie}prestashop>mollie_961f2247a2070bedff9f9cd8d64e2650'] = 'Elige'; +$_MODULE['<{mollie}prestashop>mollie_ea4788705e6873b424c65e91c2846b19'] = 'Cancelar'; +$_MODULE['<{mollie}prestashop>mollie_ea9cf7e47ff33b2be14e6dd07cbcefc6'] = 'Envío'; +$_MODULE['<{mollie}prestashop>mollie_f93bd0f858a6e5f70cb458c90a36172b'] = 'No es posible recuperar la información de la última versión'; +$_MODULE['<{mollie}prestashop>mollie_ced93781bca50eb4d970ea51abcc622c'] = '¡Ya estás usando la última versión!'; +$_MODULE['<{mollie}prestashop>mollie_43f3c5a157c67de9b6faf42b637f963a'] = 'El módulo de archivo no ha podido ser descargado'; +$_MODULE['<{mollie}prestashop>mollie_31dd57eea0f762b4ea6f022b40acc390'] = 'Ha habido un error al extraer el archivo de módulo (el archivo puede estar corrupto).'; +$_MODULE['<{mollie}prestashop>mollie_bad5a3ab102f6e9c27edd494d7e33323'] = 'Tu nueva cuenta Mollie ha sido creada con éxito. Por favor revisa tu bandeja de entrada para obtener más información.'; +$_MODULE['<{mollie}prestashop>mollie_023b7ade110944180153fd73358fc50c'] = 'Ha ocurrido un error desconocido al intentar crear tu cuenta Mollie'; +$_MODULE['<{mollie}prestashop>mollie_3a6e70059673992f825826f7cf89278d'] = 'La regla de carrito llamada "%1s" (ID %2s) usada en este carrito no es válida y ha sido retirada del carrito'; +$_MODULE['<{mollie}prestashop>mollie_3a1048f8aa3a9f6b604fcf7982811752'] = 'Advertencia: la clave de seguridad está vacía, revisa tu cuenta de pago antes de la validación'; +$_MODULE['<{mollie}prestashop>mollie_26beb437d3323bd4bfb0811b3e891315'] = '%d imágen(es)'; +$_MODULE['<{mollie}prestashop>mollie_0791970c961c09eb8caaa61aba6a3ca4'] = 'Ha ocurrido un error al guardar este mensaje'; +$_MODULE['<{mollie}prestashop>mollie_ed13b3693357ebed3751cb71cb639e65'] = 'Sin operador'; +$_MODULE['<{mollie}prestashop>mollie_b08d3867be98e6fff3233cd40ab8134a'] = 'Creación de encargo fallida'; +$_MODULE['<{mollie}prestashop>mollie_43423b4056880b08f2c9aa50d8670531'] = 'El carrito no puede ser cargado o ya se ha creado un encargo usando este carrito'; +$_MODULE['<{mollie}prestashop>mollie_88183b946cc5f0e8c96b2e66e1c74a7e'] = 'Desconocido'; +$_MODULE['<{mollie}prestashop>mollie_32c86f9a2a28a9fa544b97024393633e'] = 'No se han encontrado métodos de pago'; +$_MODULE['<{mollie}prestashop>mollie_301b87d33063f687d14004a9014f6759'] = 'No tienes permisos para devolver pagos'; +$_MODULE['<{mollie}prestashop>mollie_8dc6945fb6b59aea38df7935cf3afb6d'] = 'No tienes permisos para los %s pagos'; +$_MODULE['<{mollie}prestashop>mollie_1bda80f2be4d3658e0baa43fbe7ae8c1'] = 'ver'; +$_MODULE['<{mollie}prestashop>mollie_de95b43bceeb4b998aed4aed5cef1ae7'] = 'editar'; +$_MODULE['<{mollie}prestashop>mollie_2a3f1166b041928019e4e8718d628665'] = 'enviar'; +$_MODULE['<{mollie}prestashop>mollie_df6f85687a0d5820baa1a069a04eff2d'] = 'reintegrar'; +$_MODULE['<{mollie}prestashop>mollie_10aec35353f9c4096a71c38654c3d402'] = 'cancelar'; +$_MODULE['<{mollie}prestashop>payment_c2f73af3130be4b4967a475ab846c546'] = 'Ha ocurrido un error al inicializar tu pago. Por favor entra en contacto con nuestro soporte.'; +$_MODULE['<{mollie}prestashop>download_update_6de6a882c42b757cd027830399a74de4'] = 'Actualizar este módulo'; +$_MODULE['<{mollie}prestashop>download_update_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Error'; +$_MODULE['<{mollie}prestashop>download_update_5d04a002ea59c8114f9d08b0c6250a3b'] = 'No es posible reconectar'; +$_MODULE['<{mollie}prestashop>download_update_3844b140df977eee8639de6d1de9e1e0'] = 'No se a podido descomprimir el nuevo módulo'; +$_MODULE['<{mollie}prestashop>download_update_b50ec141b028d5a8acec4a17c32f3808'] = '¡El módulo ha sido actualizado!'; +$_MODULE['<{mollie}prestashop>new_release_b7f73af7318580996a3889353b282827'] = 'Actualmente estás usando la versión %s. ¡Te recomendamos encarecidamente que mejores a la nueva versión %s!'; +$_MODULE['<{mollie}prestashop>form_93cba07454f06a4a960172bbd6e2a435'] = 'Si'; +$_MODULE['<{mollie}prestashop>form_bafd7322c6e97d25b6299b5d6fe8920b'] = 'No'; +$_MODULE['<{mollie}prestashop>form_2d25c72c1b18e562f6654fff8e11711e'] = 'No disponible'; +$_MODULE['<{mollie}prestashop>form_58afe6389d8f42880d1011ef0de542a2'] = 'Este método de pago no está disponible en la API de pagos. Cambia a la API de encargos a continuación para activar este método.'; +$_MODULE['<{mollie}prestashop>form_9b6a88a9d4a44740f87b1ffa7cb070c4'] = 'No se pueden cargar los métodos de pago'; +$_MODULE['<{mollie}prestashop>form_6327b4e59f58137083214a1fec358855'] = 'Reintentar'; +$_MODULE['<{mollie}prestashop>form_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Error'; +$_MODULE['<{mollie}prestashop>form_49ee3087348e8d44e1feda1917443987'] = 'Nombre'; +$_MODULE['<{mollie}prestashop>form_b33f1d112cd9d2d32d37cb4cc9a340c8'] = 'Fuente de URL'; +$_MODULE['<{mollie}prestashop>form_de28ef21a06f3978c05f3d808b15eaab'] = 'URL del transportista'; +$_MODULE['<{mollie}prestashop>form_812a48ba719daeda82e4da8e812d426c'] = 'URL personalizada'; +$_MODULE['<{mollie}prestashop>form_e55f75a29310d7b60f7ac1d390c8ae42'] = 'Módulo'; +$_MODULE['<{mollie}prestashop>form_962b59a5f12eabd9c05f11b5f0aada85'] = 'No enviar automáticamente'; +$_MODULE['<{mollie}prestashop>form_703490ffd308d337cd5aac50567e9670'] = 'No hay información de seguimiento'; +$_MODULE['<{mollie}prestashop>form_f421a366f70bd2aa1193eeb5a2990546'] = 'Aquí puedes configurar que información sobre el envío es enviada a Mollie'; +$_MODULE['<{mollie}prestashop>form_53b2566e3519ea98db40ae9e716883a5'] = 'Puedes usar las siguientes variables para la URL de transportista'; +$_MODULE['<{mollie}prestashop>form_910d956cb2615e5739ac06c7f08fba26'] = 'Número de envío'; +$_MODULE['<{mollie}prestashop>form_e7e862a02819a1610f271ffea15ed47d'] = 'Código de facturación de país'; +$_MODULE['<{mollie}prestashop>form_5723a18d8a8a6052a57489df5be59a8f'] = 'Código postal de facturación'; +$_MODULE['<{mollie}prestashop>form_0d12e3c554976ad1f76c5db2b6c127ad'] = 'Código de envío de país'; +$_MODULE['<{mollie}prestashop>form_c824a8b18f09dc7e58bacf446be6735c'] = 'Código postal de envío'; +$_MODULE['<{mollie}prestashop>form_0a867177f4a701a9f33de5ab21c42593'] = 'Código de lenguaje de dos letras'; +$_MODULE['<{mollie}prestashop>form_f6fcb64e21455abc4209f8f4440d45f5'] = 'No se ha podido cargar la lista de transportistas'; +$_MODULE['<{mollie}prestashop>form_da93de158db2fbe49f35f6038711584a'] = 'Esta opción no es requerida para la API seleccionada actualmente'; +$_MODULE['<{mollie}prestashop>17_error_47e1924c444fafe9fdfce444790f0ba9'] = 'Volver a tu carrito de la compra'; +$_MODULE['<{mollie}prestashop>error_c453a4b8e8d98e82f35b67f433e3b4da'] = 'Pago'; +$_MODULE['<{mollie}prestashop>error_1e97d97a923eaddd810e056c828e99ea'] = 'Error de pago'; +$_MODULE['<{mollie}prestashop>error_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Ha ocurrido un error'; +$_MODULE['<{mollie}prestashop>error_47e1924c444fafe9fdfce444790f0ba9'] = 'Volver a tu carrito de la compra'; +$_MODULE['<{mollie}prestashop>mollie_issuers_588540a38eeba525f3598b68e6b788e5'] = 'O escoge un método de pago diferente'; +$_MODULE['<{mollie}prestashop>mollie_return_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenido de nuevo'; +$_MODULE['<{mollie}prestashop>mollie_return_300225ee958b6350abc51805dab83c24'] = 'Continuar comprando'; +$_MODULE['<{mollie}prestashop>mollie_wait_bc0dd919f9a70dbb62f3f7afd68d6d68'] = 'Esperando estado de pago'; +$_MODULE['<{mollie}prestashop>qr_done_92816c7248d010591f699db3aaf6287b'] = 'Mollie iDEAL QR'; +$_MODULE['<{mollie}prestashop>qr_done_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenido de nuevo'; +$_MODULE['<{mollie}prestashop>qr_done_4bf3a07ce980c9b007f9e2eed42d7fa2'] = 'El pago ha sido cancelado.'; +$_MODULE['<{mollie}prestashop>qr_done_6933c118341d8c06f888c392aa1ceaf5'] = 'El pago ha sido completado. ¡Gracias por tu pedido!'; +$_MODULE['<{mollie}prestashop>ideal_dropdown_ab4147235204a436c09e00d6722082ab'] = 'Elige un banco'; +$_MODULE['<{mollie}prestashop>order_info_729a51874fe901b092899e9e8b31c97a'] = '¿Estás seguro?'; +$_MODULE['<{mollie}prestashop>order_info_ccaf4ee393d094ecde7f21b15fdf8f1f'] = '¿Estás seguro de que quieres devolver este pedido?'; +$_MODULE['<{mollie}prestashop>order_info_76f0ed934de85cc7131910b32ede7714'] = 'Reintegrar'; +$_MODULE['<{mollie}prestashop>order_info_ea4788705e6873b424c65e91c2846b19'] = 'Cancelar'; +$_MODULE['<{mollie}prestashop>order_info_88ba0dcbc82905637e98317e0302cfd8'] = 'Devolver pedido'; +$_MODULE['<{mollie}prestashop>order_info_5a1119ecb764165f27cb37b6f50134f2'] = 'Restante'; +$_MODULE['<{mollie}prestashop>order_info_77fd2b4393b379bedd30efcd5df02090'] = 'Devolución parcial'; +$_MODULE['<{mollie}prestashop>order_info_a9ced76f2dd6907220fa95b3a136b04a'] = 'Cantidad inválida'; +$_MODULE['<{mollie}prestashop>order_info_3a2c3e97fed586776c2800fb7a0faf4e'] = 'Has introducido una cantidad inválida'; +$_MODULE['<{mollie}prestashop>order_info_3cc4859e502556d0d848c3bc38618782'] = 'Devolución fallida'; +$_MODULE['<{mollie}prestashop>order_info_d5cfd0f69cd548e5d3b9edde5ff1b48f'] = 'Información de pago'; +$_MODULE['<{mollie}prestashop>order_info_88427ec035734b45aae9f7d8859a5008'] = 'ID de transacción'; +$_MODULE['<{mollie}prestashop>order_info_782678f4ba02feb3e9ecd51e902cd16b'] = 'Historial de devoluciones'; +$_MODULE['<{mollie}prestashop>order_info_c5b41ae59bd6585750f536615a6bc20b'] = 'No hay devoluciones'; +$_MODULE['<{mollie}prestashop>order_info_b718adec73e04ce3ec720dd11a06a308'] = 'ID'; +$_MODULE['<{mollie}prestashop>order_info_44749712dbec183e983dcd78a7736c41'] = 'Fecha'; +$_MODULE['<{mollie}prestashop>order_info_b2f40690858b404ed10e62bdf422c704'] = 'Cantidad'; +$_MODULE['<{mollie}prestashop>order_info_53beb26d8bca00f56fbd295fdee83459'] = 'Devoluciones'; +$_MODULE['<{mollie}prestashop>order_info_daef64964ee3b9b904f5d467586e217f'] = 'Pagos'; +$_MODULE['<{mollie}prestashop>order_info_e25be354288565757726f3295e4f3ef9'] = 'Cantidad actual'; +$_MODULE['<{mollie}prestashop>order_info_068f80c7519d0528fb08e82137a72131'] = 'Productos'; +$_MODULE['<{mollie}prestashop>order_info_ec53a8c4f07baed5d8825072c89799be'] = 'Estado'; +$_MODULE['<{mollie}prestashop>order_info_747cf5c8587184b9e489ff897d97c20d'] = 'Enviado'; +$_MODULE['<{mollie}prestashop>order_info_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Cancelado'; +$_MODULE['<{mollie}prestashop>order_info_cc61945cbbf46721a053467c395c666f'] = 'Reinstegrado'; +$_MODULE['<{mollie}prestashop>order_info_197101c4a1b1fc503dcd6ebee127aa10'] = 'Precio de unidad'; +$_MODULE['<{mollie}prestashop>order_info_11cd653a2488e260a8a99f39cdffa6e7'] = 'Cantidad de IVA'; +$_MODULE['<{mollie}prestashop>order_info_bc30768048a7bbfd2d158d722c140c6d'] = 'Cantidad total'; +$_MODULE['<{mollie}prestashop>order_info_0387832795db3eb2e05f4365fba5ddac'] = 'Enviar'; +$_MODULE['<{mollie}prestashop>order_info_55453aad10c96e452556a106447313bd'] = 'Revisar envío'; +$_MODULE['<{mollie}prestashop>order_info_dbb5bbb116e16973136b9ebd887eaadd'] = 'Por favor revisa los productos incluidos en tu envío Puedes eliminar objetos o cambiar la cantidad si es necesario.'; +$_MODULE['<{mollie}prestashop>order_info_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK:'; +$_MODULE['<{mollie}prestashop>order_info_163bcc6065b16c6369c7a4de44cff164'] = 'Enviar productos'; +$_MODULE['<{mollie}prestashop>order_info_433557a938a920888445ce2c7df67d5a'] = 'Detalles de seguimiento'; +$_MODULE['<{mollie}prestashop>order_info_61995a579a6166642e759450a694642b'] = 'Añadir información de seguimiento a tu envío es recomendable, ya que demuestra que has enviado tus productos al cliente.'; +$_MODULE['<{mollie}prestashop>order_info_26b6254fefc06894825a50dfbe803937'] = 'Saltarse detalles de seguimiento'; +$_MODULE['<{mollie}prestashop>order_info_d57c24f3fe52d16e7169b912dd647f0d'] = 'opcional'; +$_MODULE['<{mollie}prestashop>order_info_2df417909bda5f3ddc210a0abe65231f'] = 'Ej. FedEx'; +$_MODULE['<{mollie}prestashop>order_info_593ed3a37aa1a3ece4a4d796fb4e2e03'] = 'Esta información es necesaria'; +$_MODULE['<{mollie}prestashop>order_info_933292561b46133ff5348c7740874c56'] = 'Código de seguimiento'; +$_MODULE['<{mollie}prestashop>order_info_e6b391a8d2c4d45902a23a8b6585703d'] = 'URL'; +$_MODULE['<{mollie}prestashop>order_info_914419aa32f04011357d3b604a86d7eb'] = 'Transportista'; +$_MODULE['<{mollie}prestashop>order_info_23a902ac637359fe67ceaccbe2c68283'] = 'Enviar todo'; +$_MODULE['<{mollie}prestashop>order_info_2a6e9f678c7267fe16f57bcd3285f1d7'] = 'Cancelar todo'; +$_MODULE['<{mollie}prestashop>order_info_05ced64413f9ff5d3602c3e257f36204'] = 'Devolver todo'; +$_MODULE['<{mollie}prestashop>order_info_bfe005bff7ecacd6ecceacdd7fb79292'] = 'Información de la transacción'; +$_MODULE['<{mollie}prestashop>order_info_1eefa98a18a384699fe611fbfd8ab0c9'] = 'No hay productos'; +$_MODULE['<{mollie}prestashop>order_info_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Ha ocurrido un error'; +$_MODULE['<{mollie}prestashop>order_info_2df3102f3fe061003dee820a72e1b1ed'] = 'No es posible realizar el envío'; +$_MODULE['<{mollie}prestashop>order_info_3efc29552025b4e68de04f415b0b8806'] = 'No es posible realizar la devolución'; +$_MODULE['<{mollie}prestashop>order_info_468a92810b526750be9664461db6bf91'] = 'No es posible cancelar'; +$_MODULE['<{mollie}prestashop>order_info_2427b479f15af44582dc151ef95a90d0'] = 'Las devoluciones no están disponibles actualmente'; +$_MODULE['<{mollie}prestashop>qr_code_9ba19ddbcfeddfc758eb84fb8ba26b5e'] = 'o escanea el código iDEAL QR'; +$_MODULE['<{mollie}prestashop>refund_729a51874fe901b092899e9e8b31c97a'] = '¿Estás seguro?'; +$_MODULE['<{mollie}prestashop>refund_ccaf4ee393d094ecde7f21b15fdf8f1f'] = '¿Estás seguro de que quieres devolver este pedido?'; +$_MODULE['<{mollie}prestashop>refund_76f0ed934de85cc7131910b32ede7714'] = 'Reintegrar'; +$_MODULE['<{mollie}prestashop>refund_ea4788705e6873b424c65e91c2846b19'] = 'Cancelar'; +$_MODULE['<{mollie}prestashop>rounding_error_7783c757cd1177e60888080e0f4e0593'] = 'La opción de configuración "%s" ha sido fijada a un valor no soportado'; +$_MODULE['<{mollie}prestashop>rounding_error_2279522d0910767ffa75e0b39ed1629f'] = 'El modo de redondeo seleccionado no está soportado por la API Mollie Orders'; +$_MODULE['<{mollie}prestashop>rounding_error_3a92c96baa86286685b233e6912e718d'] = 'Por favor navega a la página "%s" y elige la opción "%s"'; +$_MODULE['<{mollie}prestashop>smarty_error_9d1fbbe0d150b89f068ba72a20366659'] = 'La opción de configuración "%s" ha sido fijada a "%s"'; +$_MODULE['<{mollie}prestashop>smarty_error_27dd3bb10855eb84f48efedf6924c4c1'] = 'Esto hace imposible el mostrar métodos de pago en el checkout'; +$_MODULE['<{mollie}prestashop>smarty_error_4ec23c59d832a2934277a2a040918789'] = 'Por favor navega a la página "%s" y elige la otra opción'; +$_MODULE['<{mollie}prestashop>smarty_error_92b67311c1a5d6cfc28ba08a1066c901'] = 'Después, limpia el caché una vez más, para que la lista de métodos de pago sea refrescada'; +$_MODULE['<{mollie}prestashop>smarty_warning_9d1fbbe0d150b89f068ba72a20366659'] = 'La opción de configuración "%s", ha sido establecida como "%s".'; +$_MODULE['<{mollie}prestashop>smarty_warning_e7e747f9c74f0b8222c87db24d34f018'] = 'Es posible que no puedan mostrarse todas las formas de pago.'; +$_MODULE['<{mollie}prestashop>smarty_warning_1238db0fb782f758b5a54d6333b3610e'] = 'Para solucionar este problema, diríjase a la página "%s" y despeje el caché manualmente o escoja otra opción.'; diff --git a/translations/fr.php b/translations/fr.php index 56aed3f8f..40315dd45 100644 --- a/translations/fr.php +++ b/translations/fr.php @@ -1,282 +1,282 @@ -mollie_09748ce33c8a71296b20ba8c3bd1d13e'] = 'Module de paiement Mollie'; -$_MODULE['<{mollie}prestashop>mollie_95b3b272e06dcc3cc2aa62f6887aebc5'] = 'Mollie Paiements'; -$_MODULE['<{mollie}prestashop>mollie_48dedcf43487615c84c1bbbf6fe76c76'] = 'Etes-vous sûr de vouloir installer le module de paiement Mollie ? '; -$_MODULE['<{mollie}prestashop>mollie_ab552f085567bbe63872c10a3596cd27'] = 'Erreur paiement :'; -$_MODULE['<{mollie}prestashop>mollie_76e084771e78c194efd0e2d5b8920bea'] = 'Payé'; -$_MODULE['<{mollie}prestashop>mollie_f7d543c9b824323b84ab11668002f207'] = 'Autorisé'; -$_MODULE['<{mollie}prestashop>mollie_d5c39a1d9aced393f835f334a1fb9206'] = 'Annulé'; -$_MODULE['<{mollie}prestashop>mollie_c4bfb2a0bab0e91bc7dcfbe3bbec246e'] = 'Expiré'; -$_MODULE['<{mollie}prestashop>mollie_ad32204fca182b862a5f97a5534c03a2'] = 'Remboursé'; -$_MODULE['<{mollie}prestashop>mollie_542ba101e183aea6bc8dab5b1ec5ef7f'] = 'Virement en attente'; -$_MODULE['<{mollie}prestashop>mollie_837cbb7173db2e32b3783e87597dac90'] = 'Partiellement remboursé'; -$_MODULE['<{mollie}prestashop>mollie_e2b7dec8fa4b498156dfee6e4c84b156'] = 'Cette méthode de paiement n\'est pas disponible.'; -$_MODULE['<{mollie}prestashop>mollie_96d0e2862e0167af0c2fd0c99fe6bc5d'] = 'Cliquez ici pour continuer'; -$_MODULE['<{mollie}prestashop>mollie_540d9939d1ca9406e215ee3d78c76813'] = 'Cette méthode de paiement est uniquement disponible pour les euros.'; -$_MODULE['<{mollie}prestashop>mollie_1b2631119333d97dbda37f87e378b1e4'] = 'Une erreur s\'est produite lors du traitement de votre demande :'; -$_MODULE['<{mollie}prestashop>mollie_11bab828edcc0a6d5c97cbf84d61e652'] = 'La commande avec cet identifiant n\'existe pas.'; -$_MODULE['<{mollie}prestashop>mollie_b34487c5f391f47b893ee3c61f8f9ab7'] = 'Nous n\'avons pas reçu de statut de paiement définitif. Vous serez averti dès que nous recevrons une confirmation de la banque / du commerçant.'; -$_MODULE['<{mollie}prestashop>mollie_57bc999b3b730ead92ac7243fe254a2a'] = 'Malheureusement, votre paiement a expiré.'; -$_MODULE['<{mollie}prestashop>mollie_3602f6d5ece34fdbd4ffe0a47f1a2ba4'] = 'Merci ! Nous avons bien reçu votre paiement.'; -$_MODULE['<{mollie}prestashop>mollie_7352a401b3c23b2966c68bc9ab97fa06'] = 'La transaction a un statut inattendu.'; -$_MODULE['<{mollie}prestashop>mollie_3f83176ddc3f63a5a374a623840bfb09'] = 'Vous n\'avez pas accès à cette page.'; -$_MODULE['<{mollie}prestashop>mollie_300225ee958b6350abc51805dab83c24'] = 'Continuer mes achats.'; -$_MODULE['<{mollie}prestashop>mollie_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenue !'; -$_MODULE['<{mollie}prestashop>mollie_66dac2278292ff24611ef8a85bc94e0d'] = 'Sélectionnez votre banque :'; -$_MODULE['<{mollie}prestashop>mollie_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; -$_MODULE['<{mollie}prestashop>mollie_b98a07c82f0078a1de7fc219fae480fc'] = 'Méthode de paiement différente'; -$_MODULE['<{mollie}prestashop>mollie_35895cff7df70dab18783453e2bd241f'] = 'Payer avec %s'; -$_MODULE['<{mollie}prestashop>mollie_cc16e103e202a48009df202d9525f75f'] = 'Rembourser cette commande'; -$_MODULE['<{mollie}prestashop>mollie_c5222afef6530f674d3acf82ba2ce9dc'] = 'Remboursement Mollie'; -$_MODULE['<{mollie}prestashop>mollie_7064b25aa8a732a3db7f230c9867be19'] = 'Remboursement de la commande #%d via l\'API de Mollie.'; -$_MODULE['<{mollie}prestashop>mollie_e12682d2e0650f2783b22d956d2b947a'] = 'La commande a bien été remboursée !'; -$_MODULE['<{mollie}prestashop>mollie_95be87afb2734075cf345b633e1384ec'] = 'Mollie B.V. transférera l\'argent sur le compte de votre client au prochain jour ouvrable.'; -$_MODULE['<{mollie}prestashop>mollie_9770d1f0124abb0d6a894cd79f8703b5'] = 'En attente de paiement Mollie'; -$_MODULE['<{mollie}prestashop>mollie_b9fc80a6e775cb75568db6b6538dacdd'] = 'Mollie partiellement remboursé'; -$_MODULE['<{mollie}prestashop>mollie_f91ab041fe9d6057740394b8b7903a0f'] = 'iDEAL'; -$_MODULE['<{mollie}prestashop>mollie_b749cfb52bfd82c5b12aa49d6906b8e8'] = 'CartaSi'; -$_MODULE['<{mollie}prestashop>mollie_05bfde942b997737b56b9ab405450076'] = 'Cartes Bancaires'; -$_MODULE['<{mollie}prestashop>mollie_e7f9e382dc50889098cbe56f2554c77b'] = 'Cartes de crédit'; -$_MODULE['<{mollie}prestashop>mollie_870cf6bc77bbadd038aeb8d942c9cb18'] = 'Bancontact'; -$_MODULE['<{mollie}prestashop>mollie_8ad65eb3da9995173280649f090218c3'] = 'SOFORT Banking'; -$_MODULE['<{mollie}prestashop>mollie_c0db4214f9d7e1b846f4496e03e667d0'] = 'SEPA Direct Debit'; -$_MODULE['<{mollie}prestashop>mollie_5aa515ce21e8de1ed7416dce455a151f'] = 'Belfius Pay Button'; -$_MODULE['<{mollie}prestashop>mollie_d023ec040f79f1a9b2ac960b43785089'] = 'Bitcoin'; -$_MODULE['<{mollie}prestashop>mollie_4aa65ea89e54d83bb2604c2cc89babc3'] = 'PODIUM Cadeaukaart'; -$_MODULE['<{mollie}prestashop>mollie_58c25c4b8b4382e37d89e0ef6bd625cf'] = 'Cartes cadeaux'; -$_MODULE['<{mollie}prestashop>mollie_431647a0a8b2cd589c9fda9535f90d6d'] = 'Virement bancaire'; -$_MODULE['<{mollie}prestashop>mollie_ad69e733ebae8d264bccaa38d68830e8'] = 'PayPal'; -$_MODULE['<{mollie}prestashop>mollie_6abcd8eecb4f2abb6ccfe36ef7046ba0'] = 'paysafecard'; -$_MODULE['<{mollie}prestashop>mollie_a81bd6195f1abce35fd03a870270100b'] = 'KBC/CBC Payment Button'; -$_MODULE['<{mollie}prestashop>mollie_8184c64d6318b4a42428ae21d0fe2311'] = 'ING Home\'Pay'; -$_MODULE['<{mollie}prestashop>mollie_31911306551723245e7417ae4520fecb'] = 'Giropay'; -$_MODULE['<{mollie}prestashop>mollie_ce8e4a184e2e534c09d6bf6ae773ca4a'] = 'eps'; -$_MODULE['<{mollie}prestashop>mollie_feb1a8ded87483b416427b8457bdc664'] = 'Klarna : Pay later'; -$_MODULE['<{mollie}prestashop>mollie_a388a6fba0d4b58c334cd9416071cdb1'] = 'Klarna : Slice it'; -$_MODULE['<{mollie}prestashop>mollie_d1913efa9eae51595a33f3c1410d465c'] = 'La méthode %s a été remplacée par le module %s. Cela peut causer des interférences avec les paiements.'; -$_MODULE['<{mollie}prestashop>mollie_6311eb29dee3acc14071e0b1efb173f5'] = '%s statuts:'; -$_MODULE['<{mollie}prestashop>mollie_d438a1d96c6037fccad15d7594737a84'] = 'Paramètres visuels :'; -$_MODULE['<{mollie}prestashop>mollie_49259add73e416838e985a6bf4d0e571'] = 'Débogguer les informations :'; -$_MODULE['<{mollie}prestashop>mollie_c9cc8cce247e49bae79f15173ce97354'] = 'Sauvegarder'; -$_MODULE['<{mollie}prestashop>mollie_5bef23eb7efff2736c5583bda59e5eb7'] = 'Créer un compte'; -$_MODULE['<{mollie}prestashop>mollie_a77e6fc49f07414fc53336c8d879b73e'] = 'Vous possédez déjà une clé API ? Vous pouvez alors ignorer cette étape et renseigner votre clé API.'; -$_MODULE['<{mollie}prestashop>mollie_21aef67e8d12503aff027385d0a7867f'] = 'Prénom, Nom'; -$_MODULE['<{mollie}prestashop>mollie_b357b524e740bc85b9790a0712d84a30'] = 'Adresse email'; -$_MODULE['<{mollie}prestashop>mollie_e93c33bd1341ab74195430daeb63db13'] = 'Nom de votre boutique'; -$_MODULE['<{mollie}prestashop>mollie_dd7bf230fde8d4836917806aff6a6b27'] = 'Adresse'; -$_MODULE['<{mollie}prestashop>mollie_8bcdc441379cbf584638b0589a3f9adb'] = 'Code postal'; -$_MODULE['<{mollie}prestashop>mollie_57d056ed0984166336b7879c2af3657f'] = 'Ville'; -$_MODULE['<{mollie}prestashop>mollie_59716c97497eb9694541f7c3d37b1a4d'] = 'Pays'; -$_MODULE['<{mollie}prestashop>mollie_686e697538050e4664636337cc3b834f'] = 'Créer'; -$_MODULE['<{mollie}prestashop>mollie_7c4e7ada50c8572336f872fced4d1852'] = 'Statut pour les paiements %s'; -$_MODULE['<{mollie}prestashop>mollie_bea3fae02ae079e541199ab6ffc2d1ad'] = 'Les paiements`%s` reçoivent le statut `%s`'; -$_MODULE['<{mollie}prestashop>mollie_b2a2c5a69af7c04c5adc48261fb5dc13'] = 'Envoyer Emails lorsque %s'; -$_MODULE['<{mollie}prestashop>mollie_0511c3431d4e32ed4266fe943014d000'] = 'Envoyer Emails lorsque le statut de la transaction devient %s?'; -$_MODULE['<{mollie}prestashop>mollie_7aace0dc23ee8b74744bdf79c98a2605'] = 'Ignorer ce statut'; -$_MODULE['<{mollie}prestashop>mollie_dd59e3663865f3fab190e496260608e6'] = 'Les paiements`%s` ne disposent pas de statut'; -$_MODULE['<{mollie}prestashop>mollie_824f2c1d1c2ee9aecac9977d9347a2ea'] = 'Paramètres Mollie'; -$_MODULE['<{mollie}prestashop>mollie_d876ff8da67c3731ae25d8335a4168b4'] = 'Clé API'; -$_MODULE['<{mollie}prestashop>mollie_2ffbc7eb8899865f9e66682d34853195'] = 'Vous trouverez votre clé API dans votre [1]Profil Mollie[/1]; Elle commence par test ou live.'; -$_MODULE['<{mollie}prestashop>mollie_b5a7adde1af5c87d7fd797b6245c2a39'] = 'Description'; -$_MODULE['<{mollie}prestashop>mollie_3150652ab7f22bafe11a78d4cc0de8be'] = 'Entrez une description ici. Notez : Les méthodes de paiement peuvent comporter une limite de caractère. Il est préférable de garder la description en dessous de 29 caractères. Vous pouvez utiliser les variables suivantes : %s'; -$_MODULE['<{mollie}prestashop>mollie_8d9143dfc520ed7d982d4e545c7bfc5e'] = 'Envoyer localisation pour l\'écran de paiement'; -$_MODULE['<{mollie}prestashop>mollie_1239c091f39c068882e924e34dd9cc40'] = 'Le plugin doit-il envoyer la [1]localisation[/1] du site à Mollie. Les écrans de paiement Mollie seront dans la même langue que votre boutique en ligne. Mollie peut également détecter la langue en fonction de la langue du navigateur de l\'utilisateur.'; -$_MODULE['<{mollie}prestashop>mollie_80a78bb16945665b6410ae8d93e81c69'] = 'Ne pas envoyer la localisation en utilisant la langue du navigateur'; -$_MODULE['<{mollie}prestashop>mollie_3ba67aae5d08d0fa90016685407926f1'] = 'Paramètres visuels'; -$_MODULE['<{mollie}prestashop>mollie_fff0d600f8a0b5e19e88bfb821dd1157'] = 'Images'; -$_MODULE['<{mollie}prestashop>mollie_f7a97136df639501521efb243047e0cf'] = 'Lors du paiement, afficher les logos des méthodes de paiement en grand, normal ou masquer logos.'; -$_MODULE['<{mollie}prestashop>mollie_a88f05b6c963e145a45b58c47cd42a41'] = 'Masquer'; -$_MODULE['<{mollie}prestashop>mollie_fea087517c26fadd409bd4b9dc642555'] = 'Normal'; -$_MODULE['<{mollie}prestashop>mollie_d861877da56b8b4ceb35c8cbfdf65bb4'] = 'Grand'; -$_MODULE['<{mollie}prestashop>mollie_85fb708f31f585607247f8b868efafcc'] = 'Liste des émetteurs'; -$_MODULE['<{mollie}prestashop>mollie_27db39558366d2a9001a0dec69eea4d6'] = 'Certaines méthodes de paiement (ex. iDEAL) possèdent une liste d\'émetteurs. Ce paramètre spécifie où il est affiché.'; -$_MODULE['<{mollie}prestashop>mollie_85a692706bc7597b6e32bc1d354c138f'] = 'Un clic'; -$_MODULE['<{mollie}prestashop>mollie_ea9b19c6f2e9ef60b49778ab9396b293'] = 'Nouvelle page'; -$_MODULE['<{mollie}prestashop>mollie_d35acbb07d2841712a937d5748e9bdc2'] = 'Page de paiement'; -$_MODULE['<{mollie}prestashop>mollie_1547ffc579d657d13fd5fedf12cbfae5'] = 'Fichier CSS'; -$_MODULE['<{mollie}prestashop>mollie_6602513644161421f58418528d93ac00'] = 'Veuillez laisser l\'espace libre pour la feuille de styles par défaut. Elle devrait inclure le chemin du fichier lorsqu\'il est défini. Notez : Vous pouvez utiliser [1]{BASE}[/1], [1]{THEME}[/1], [1]{CSS}[/1], [1]{MOBILE}[/1], [1]{MOBILE_CSS}[/1] et [1]{MASQUER}[/1] pour faciliter la configuration des dossiers.'; -$_MODULE['<{mollie}prestashop>mollie_0da8d9a75492046bea7f314521e07cae'] = 'Méthodes de paiement'; -$_MODULE['<{mollie}prestashop>mollie_75886bf821fc9c068a280fe52337c0f5'] = 'Activez ou désactivez les méthodes de paiement. Vous pouvez faire glisser et déposer pour réorganiser les méthodes de paiement.'; -$_MODULE['<{mollie}prestashop>mollie_c576349bf8ff5fba4e9369ab581a4074'] = 'Activer iDEAL QR'; -$_MODULE['<{mollie}prestashop>mollie_c0ae4417e7a196f3ccfadff68a5064ed'] = 'Les codes QR ne sont actuellement pas pris en charge par l\'API Orders. Nous nous excusons pour le désagrément !'; -$_MODULE['<{mollie}prestashop>mollie_e17dc77fb83539b6a4687c6d515791e4'] = '%s statuts'; -$_MODULE['<{mollie}prestashop>mollie_b068931cc450442b63f5b3d276ea4297'] = 'nom'; -$_MODULE['<{mollie}prestashop>mollie_4695fd3a22023ab53a2151f797975ff8'] = 'Désactiver ce statut'; -$_MODULE['<{mollie}prestashop>mollie_656f9fd6f874404599220855cfec17ef'] = 'API Mollie'; -$_MODULE['<{mollie}prestashop>mollie_a1532be2c9ef11d7dd5edd974fc6c98c'] = 'Sélectionnez l\'API Mollie que vous souhaitez utiliser'; -$_MODULE['<{mollie}prestashop>mollie_9ce1d2272c82bfd7d501a6697df774c7'] = 'Le plugin doit-il utiliser la nouvelle API Mollie Orders ? Cela permet d’utiliser des méthodes de paiement telles que Klarna Pay Later.'; -$_MODULE['<{mollie}prestashop>mollie_8c2b4949d892b39b236545951f10bbd4'] = 'API de paiement'; -$_MODULE['<{mollie}prestashop>mollie_a8b0255f70ecc140a1b5134ae5217e51'] = 'API Orders'; -$_MODULE['<{mollie}prestashop>mollie_1191f888f0cc23f95aa77aacb094503b'] = 'Informations sur l\'expédition'; -$_MODULE['<{mollie}prestashop>mollie_d822c02513be98814bdd39f8bae598d1'] = 'Envoi automatique lorsque noté `expédié`'; -$_MODULE['<{mollie}prestashop>mollie_0eccefc4c96190190add75fe0a74fcd4'] = 'L\'activation de cette fonctionnalité enverra automatiquement les informations concernant l\'expédition lorsqu\'une commande a été notée `expédiée`.'; -$_MODULE['<{mollie}prestashop>mollie_c1df8a5243557cbd8a7a31c11aab3db4'] = 'Envoi automatique lorsque l\'un de ces statuts est atteint'; -$_MODULE['<{mollie}prestashop>mollie_34bd91e87db36a10b9e847d6304be289'] = 'Si une commande atteint l\'un de ces statuts, le module enverra automatiquement les informations concernant l\'expédition.'; -$_MODULE['<{mollie}prestashop>mollie_498f79c4c5bbde77f1bceb6c86fd0f6d'] = 'Afficher'; -$_MODULE['<{mollie}prestashop>mollie_62a5e490880a92eef74f167d9dc6dca0'] = 'Masquer'; -$_MODULE['<{mollie}prestashop>mollie_dc6e4b439165a4e104c9f3cbfcfe2797'] = 'Niveau de débogage'; -$_MODULE['<{mollie}prestashop>mollie_500aa80d6aea3cc9701b566c5f92ed91'] = 'Erreurs d\'affichage'; -$_MODULE['<{mollie}prestashop>mollie_37f9a8b20930c1dc7488b15872b6d36b'] = 'L\'activation de cette fonctionnalité affichera des messages d\'erreur (le cas échéant) sur la page d\'accueil'; -$_MODULE['<{mollie}prestashop>mollie_e5114c4b69585ba5883d456a74c1cd5d'] = 'Niveau en logarithme'; -$_MODULE['<{mollie}prestashop>mollie_921a6d905eef99631c9c73c317799e62'] = 'Niveau recommandé : Erreurs. A définir partout afin de surveiller les demandes Webhook entrantes. [1]Voir logarithmes.[/1]'; -$_MODULE['<{mollie}prestashop>mollie_f80a4ad87fee7c9fdc19b7769495fdb5'] = 'Rien'; -$_MODULE['<{mollie}prestashop>mollie_5ef0c737746fae2ca90e66c39333f8f6'] = 'Erreurs'; -$_MODULE['<{mollie}prestashop>mollie_709468af25e91284821d1bdbfdded24c'] = 'Tout'; -$_MODULE['<{mollie}prestashop>mollie_7c478959c218087ffc4ad5d96e7f66a6'] = 'Mollie'; -$_MODULE['<{mollie}prestashop>mollie_1f93fc361bfc627c89a46e1b6c28df2b'] = 'La clé API doit commencer par test ou live.'; -$_MODULE['<{mollie}prestashop>mollie_6ab1adfed768d989b47c908755fe677f'] = 'La configuration a été sauvegardée !'; -$_MODULE['<{mollie}prestashop>mollie_1f91cd9f380285bf1219c79ab7fcb75e'] = 'Avertissement : Impossible de récupérer le fichier de mise à jour à partir de github.'; -$_MODULE['<{mollie}prestashop>mollie_ce1e483d5cd4b349af887fa3e198ea6b'] = 'Aucun package de téléchargement trouvé pour la dernière version.'; -$_MODULE['<{mollie}prestashop>mollie_048ef1905ff33382d7660a68a6199305'] = 'Avertissement : Impossible de récupérer le fichier xml de mise à jour à partir de github.'; -$_MODULE['<{mollie}prestashop>mollie_711d42f319398490b32cd0e2f0b8ccb8'] = 'Avertissement : La mise à jour du fichier xml à partir de github suit un format inattendu.'; -$_MODULE['<{mollie}prestashop>mollie_48fa0f621f79f451e58f200957da5b52'] = 'Sélectionnez votre banque'; -$_MODULE['<{mollie}prestashop>mollie_8953fb7da2299bf905b73720f611baa3'] = 'ou payez avec iDEAL QR'; -$_MODULE['<{mollie}prestashop>mollie_961f2247a2070bedff9f9cd8d64e2650'] = 'Choisir'; -$_MODULE['<{mollie}prestashop>mollie_ea4788705e6873b424c65e91c2846b19'] = 'Annuler'; -$_MODULE['<{mollie}prestashop>mollie_f93bd0f858a6e5f70cb458c90a36172b'] = 'Impossible de récupérer les informations sur la dernière version'; -$_MODULE['<{mollie}prestashop>mollie_ced93781bca50eb4d970ea51abcc622c'] = 'Vous utilisez déjà la dernière version'; -$_MODULE['<{mollie}prestashop>mollie_43f3c5a157c67de9b6faf42b637f963a'] = 'L\'archive du module n\'a pas pu être téléchargée'; -$_MODULE['<{mollie}prestashop>mollie_31dd57eea0f762b4ea6f022b40acc390'] = 'Une erreur s\'est produite lors de l\'extraction du fichier de module (Il se peut que le fichier soit corrompu).'; -$_MODULE['<{mollie}prestashop>mollie_bad5a3ab102f6e9c27edd494d7e33323'] = 'Félicitations vous avez crée votre compte Mollie avec succès ! Veuillez vérifier votre boite mail pour plus d\'informations'; -$_MODULE['<{mollie}prestashop>mollie_023b7ade110944180153fd73358fc50c'] = 'Une erreur inconnue s\'est produite lors de la création de votre compte Mollie.'; -$_MODULE['<{mollie}prestashop>mollie_88183b946cc5f0e8c96b2e66e1c74a7e'] = 'Inconnu'; -$_MODULE['<{mollie}prestashop>mollie_301b87d33063f687d14004a9014f6759'] = 'Vous n\'êtes pas autorisé à effectuer des remboursements de paiement'; -$_MODULE['<{mollie}prestashop>mollie_8dc6945fb6b59aea38df7935cf3afb6d'] = 'Vous n\'êtes pas autorisé à %s des paiements'; -$_MODULE['<{mollie}prestashop>mollie_1bda80f2be4d3658e0baa43fbe7ae8c1'] = 'Voir'; -$_MODULE['<{mollie}prestashop>mollie_de95b43bceeb4b998aed4aed5cef1ae7'] = 'Modifier'; -$_MODULE['<{mollie}prestashop>mollie_2a3f1166b041928019e4e8718d628665'] = 'Expédier'; -$_MODULE['<{mollie}prestashop>mollie_df6f85687a0d5820baa1a069a04eff2d'] = 'Rembourser'; -$_MODULE['<{mollie}prestashop>mollie_10aec35353f9c4096a71c38654c3d402'] = 'Annuler'; -$_MODULE['<{mollie}prestashop>payment_c2f73af3130be4b4967a475ab846c546'] = 'Une erreur s\'est produite lors de l\'initialisation de votre paiement. Veuillez contacter notre support client.'; -$_MODULE['<{mollie}prestashop>download_update_6de6a882c42b757cd027830399a74de4'] = 'Mettre à jour ce module'; -$_MODULE['<{mollie}prestashop>download_update_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Erreur'; -$_MODULE['<{mollie}prestashop>download_update_5d04a002ea59c8114f9d08b0c6250a3b'] = 'Impossible de se connecter'; -$_MODULE['<{mollie}prestashop>download_update_3844b140df977eee8639de6d1de9e1e0'] = 'Impossible de décompresser le nouveau module'; -$_MODULE['<{mollie}prestashop>download_update_b50ec141b028d5a8acec4a17c32f3808'] = 'Le module a été mis à jour'; -$_MODULE['<{mollie}prestashop>new_release_b7f73af7318580996a3889353b282827'] = 'Vous utilisez actuellement la version %s. Nous vous recommandons vivement de passer à la nouvelle version %s!'; -$_MODULE['<{mollie}prestashop>form_93cba07454f06a4a960172bbd6e2a435'] = 'Oui'; -$_MODULE['<{mollie}prestashop>form_bafd7322c6e97d25b6299b5d6fe8920b'] = 'Non'; -$_MODULE['<{mollie}prestashop>form_2d25c72c1b18e562f6654fff8e11711e'] = 'Non disponible'; -$_MODULE['<{mollie}prestashop>form_58afe6389d8f42880d1011ef0de542a2'] = 'Cette méthode de paiement n\'est pas disponible avec l\'API Payments. Basculez sur l\'API Orders ci-dessous pour activer cette méthode.'; -$_MODULE['<{mollie}prestashop>form_9b6a88a9d4a44740f87b1ffa7cb070c4'] = 'Impossible de charger les méthodes de paiement'; -$_MODULE['<{mollie}prestashop>form_6327b4e59f58137083214a1fec358855'] = 'Réessayer'; -$_MODULE['<{mollie}prestashop>form_49ee3087348e8d44e1feda1917443987'] = 'Nom'; -$_MODULE['<{mollie}prestashop>form_b33f1d112cd9d2d32d37cb4cc9a340c8'] = 'Source URL'; -$_MODULE['<{mollie}prestashop>form_de28ef21a06f3978c05f3d808b15eaab'] = 'URL de l\'opérateur'; -$_MODULE['<{mollie}prestashop>form_812a48ba719daeda82e4da8e812d426c'] = 'URL personnalisée'; -$_MODULE['<{mollie}prestashop>form_e55f75a29310d7b60f7ac1d390c8ae42'] = 'Module'; -$_MODULE['<{mollie}prestashop>form_962b59a5f12eabd9c05f11b5f0aada85'] = 'Ne pas expédier automatiquement'; -$_MODULE['<{mollie}prestashop>form_703490ffd308d337cd5aac50567e9670'] = 'Pas d\'information de suivi'; -$_MODULE['<{mollie}prestashop>form_f421a366f70bd2aa1193eeb5a2990546'] = 'Ici, vous pouvez configurer les informations concernant l\'expédition qui seront envoyées à Mollie'; -$_MODULE['<{mollie}prestashop>form_53b2566e3519ea98db40ae9e716883a5'] = 'Vous pouvez utiliser les variables suivantes pour les URL de Transporteurs'; -$_MODULE['<{mollie}prestashop>form_910d956cb2615e5739ac06c7f08fba26'] = 'Numéro d\'expédition'; -$_MODULE['<{mollie}prestashop>form_e7e862a02819a1610f271ffea15ed47d'] = 'Code du pays de facturation'; -$_MODULE['<{mollie}prestashop>form_5723a18d8a8a6052a57489df5be59a8f'] = 'Code postal de facturation'; -$_MODULE['<{mollie}prestashop>form_0d12e3c554976ad1f76c5db2b6c127ad'] = 'Code du pays d\'expédition'; -$_MODULE['<{mollie}prestashop>form_c824a8b18f09dc7e58bacf446be6735c'] = 'Code postal d\'expédition'; -$_MODULE['<{mollie}prestashop>form_0a867177f4a701a9f33de5ab21c42593'] = 'Code de langue à 2 lettres'; -$_MODULE['<{mollie}prestashop>form_f6fcb64e21455abc4209f8f4440d45f5'] = 'Impossible de charger la liste des transporteurs'; -$_MODULE['<{mollie}prestashop>form_da93de158db2fbe49f35f6038711584a'] = 'Cette option n\'est pas nécessaire pour l\'API actuellement sélectionnée.'; -$_MODULE['<{mollie}prestashop>error_c453a4b8e8d98e82f35b67f433e3b4da'] = 'Paiement'; -$_MODULE['<{mollie}prestashop>error_1e97d97a923eaddd810e056c828e99ea'] = 'Erreur paiement'; -$_MODULE['<{mollie}prestashop>error_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Une erreur est survenue'; -$_MODULE['<{mollie}prestashop>error_47e1924c444fafe9fdfce444790f0ba9'] = 'Retour à mon panier'; -$_MODULE['<{mollie}prestashop>mollie_issuers_588540a38eeba525f3598b68e6b788e5'] = 'ou choisissez une autre méthode de paiement'; -$_MODULE['<{mollie}prestashop>mollie_return_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenue !'; -$_MODULE['<{mollie}prestashop>mollie_return_300225ee958b6350abc51805dab83c24'] = 'Continuer mes achats'; -$_MODULE['<{mollie}prestashop>qr_done_92816c7248d010591f699db3aaf6287b'] = 'Mollie iDEAL QR'; -$_MODULE['<{mollie}prestashop>qr_done_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenue !'; -$_MODULE['<{mollie}prestashop>qr_done_4bf3a07ce980c9b007f9e2eed42d7fa2'] = 'Le paiement a été annulé.'; -$_MODULE['<{mollie}prestashop>qr_done_6933c118341d8c06f888c392aa1ceaf5'] = 'Le paiement a été effectué. Merci pour votre commande !'; -$_MODULE['<{mollie}prestashop>ideal_dropdown_ab4147235204a436c09e00d6722082ab'] = 'Sélectionnez une banque'; -$_MODULE['<{mollie}prestashop>order_info_729a51874fe901b092899e9e8b31c97a'] = 'Etes-vous sûr ?'; -$_MODULE['<{mollie}prestashop>order_info_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Etes-vous sûr de vouloir rembourser cette commande ?'; -$_MODULE['<{mollie}prestashop>order_info_76f0ed934de85cc7131910b32ede7714'] = 'Remboursement'; -$_MODULE['<{mollie}prestashop>order_info_ea4788705e6873b424c65e91c2846b19'] = 'Annuler'; -$_MODULE['<{mollie}prestashop>order_info_88ba0dcbc82905637e98317e0302cfd8'] = 'Rembourser commande'; -$_MODULE['<{mollie}prestashop>order_info_5a1119ecb764165f27cb37b6f50134f2'] = 'Restant'; -$_MODULE['<{mollie}prestashop>order_info_77fd2b4393b379bedd30efcd5df02090'] = 'Remboursement partiel'; -$_MODULE['<{mollie}prestashop>order_info_a9ced76f2dd6907220fa95b3a136b04a'] = 'Montant invalide'; -$_MODULE['<{mollie}prestashop>order_info_3a2c3e97fed586776c2800fb7a0faf4e'] = 'Vous avez entré un montant invalide'; -$_MODULE['<{mollie}prestashop>order_info_3cc4859e502556d0d848c3bc38618782'] = 'Le remboursement a échoué'; -$_MODULE['<{mollie}prestashop>order_info_d5cfd0f69cd548e5d3b9edde5ff1b48f'] = 'Informations sur le paiement'; -$_MODULE['<{mollie}prestashop>order_info_88427ec035734b45aae9f7d8859a5008'] = 'Identifiant de transaction'; -$_MODULE['<{mollie}prestashop>order_info_782678f4ba02feb3e9ecd51e902cd16b'] = 'Historique de remboursements'; -$_MODULE['<{mollie}prestashop>order_info_c5b41ae59bd6585750f536615a6bc20b'] = 'Il n\'y a aucun remboursement'; -$_MODULE['<{mollie}prestashop>order_info_b718adec73e04ce3ec720dd11a06a308'] = 'Identifiant'; -$_MODULE['<{mollie}prestashop>order_info_44749712dbec183e983dcd78a7736c41'] = 'Date'; -$_MODULE['<{mollie}prestashop>order_info_b2f40690858b404ed10e62bdf422c704'] = 'Montant'; -$_MODULE['<{mollie}prestashop>order_info_53beb26d8bca00f56fbd295fdee83459'] = 'Remboursements'; -$_MODULE['<{mollie}prestashop>order_info_daef64964ee3b9b904f5d467586e217f'] = 'Paiements'; -$_MODULE['<{mollie}prestashop>order_info_e25be354288565757726f3295e4f3ef9'] = 'Montant actuel'; -$_MODULE['<{mollie}prestashop>order_info_068f80c7519d0528fb08e82137a72131'] = 'Produits'; -$_MODULE['<{mollie}prestashop>order_info_ec53a8c4f07baed5d8825072c89799be'] = 'Statuts'; -$_MODULE['<{mollie}prestashop>order_info_747cf5c8587184b9e489ff897d97c20d'] = 'Expédié'; -$_MODULE['<{mollie}prestashop>order_info_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Annulé'; -$_MODULE['<{mollie}prestashop>order_info_cc61945cbbf46721a053467c395c666f'] = 'Remboursé'; -$_MODULE['<{mollie}prestashop>order_info_197101c4a1b1fc503dcd6ebee127aa10'] = 'Prix unitaire'; -$_MODULE['<{mollie}prestashop>order_info_11cd653a2488e260a8a99f39cdffa6e7'] = 'Montant TVA'; -$_MODULE['<{mollie}prestashop>order_info_bc30768048a7bbfd2d158d722c140c6d'] = 'Montant total'; -$_MODULE['<{mollie}prestashop>order_info_0387832795db3eb2e05f4365fba5ddac'] = 'Expédier'; -$_MODULE['<{mollie}prestashop>order_info_55453aad10c96e452556a106447313bd'] = 'Examiner l\'envoi'; -$_MODULE['<{mollie}prestashop>order_info_dbb5bbb116e16973136b9ebd887eaadd'] = 'Merci de revoir les produits inclus dans votre envoi. Vous pouvez supprimer des articles ou modifier la quantité si nécessaire.'; -$_MODULE['<{mollie}prestashop>order_info_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; -$_MODULE['<{mollie}prestashop>order_info_163bcc6065b16c6369c7a4de44cff164'] = 'Expédier les produits'; -$_MODULE['<{mollie}prestashop>order_info_433557a938a920888445ce2c7df67d5a'] = 'Détails de suivi'; -$_MODULE['<{mollie}prestashop>order_info_61995a579a6166642e759450a694642b'] = 'Il est recommandé d\'ajouter des informations de suivi à votre envoi. Cela prouvera que vous avez bien expédié les produits à votre client.'; -$_MODULE['<{mollie}prestashop>order_info_26b6254fefc06894825a50dfbe803937'] = 'Ignorer les détails de suivi'; -$_MODULE['<{mollie}prestashop>order_info_d57c24f3fe52d16e7169b912dd647f0d'] = 'Optionel'; -$_MODULE['<{mollie}prestashop>order_info_2df417909bda5f3ddc210a0abe65231f'] = 'E.x. FedEx'; -$_MODULE['<{mollie}prestashop>order_info_593ed3a37aa1a3ece4a4d796fb4e2e03'] = 'Cette information est obligatoire'; -$_MODULE['<{mollie}prestashop>order_info_933292561b46133ff5348c7740874c56'] = 'Code de suivi'; -$_MODULE['<{mollie}prestashop>order_info_e6b391a8d2c4d45902a23a8b6585703d'] = 'URL'; -$_MODULE['<{mollie}prestashop>order_info_914419aa32f04011357d3b604a86d7eb'] = 'Transporteur'; -$_MODULE['<{mollie}prestashop>order_info_23a902ac637359fe67ceaccbe2c68283'] = 'Tout expédier'; -$_MODULE['<{mollie}prestashop>order_info_2a6e9f678c7267fe16f57bcd3285f1d7'] = 'Tout annuler'; -$_MODULE['<{mollie}prestashop>order_info_05ced64413f9ff5d3602c3e257f36204'] = 'Tout rembourser'; -$_MODULE['<{mollie}prestashop>order_info_bfe005bff7ecacd6ecceacdd7fb79292'] = 'Informations transaction'; -$_MODULE['<{mollie}prestashop>order_info_1eefa98a18a384699fe611fbfd8ab0c9'] = 'Il n\'y a aucun produit'; -$_MODULE['<{mollie}prestashop>order_info_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Une erreur est survenue'; -$_MODULE['<{mollie}prestashop>order_info_2df3102f3fe061003dee820a72e1b1ed'] = 'Impossible d\'expédier'; -$_MODULE['<{mollie}prestashop>order_info_3efc29552025b4e68de04f415b0b8806'] = 'Impossible d\'effectuer le remboursement'; -$_MODULE['<{mollie}prestashop>order_info_468a92810b526750be9664461db6bf91'] = 'Impossible d\'annuler'; -$_MODULE['<{mollie}prestashop>qr_code_9ba19ddbcfeddfc758eb84fb8ba26b5e'] = 'ou scanner le code iDEAL QR'; -$_MODULE['<{mollie}prestashop>refund_729a51874fe901b092899e9e8b31c97a'] = 'Etes-vous sûr ?'; -$_MODULE['<{mollie}prestashop>refund_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Etes-vous sûr de vouloir rembourser cette commande ?'; -$_MODULE['<{mollie}prestashop>refund_76f0ed934de85cc7131910b32ede7714'] = 'Rembourser'; -$_MODULE['<{mollie}prestashop>refund_ea4788705e6873b424c65e91c2846b19'] = 'Annuler'; -$_MODULE['<{mollie}prestashop>mollie_484f5a79672cebe198ebdde45a1d672f'] = 'Papier cadeau'; -$_MODULE['<{mollie}prestashop>mollie_e0010a0a1a3259ab5c06a19bad532851'] = 'Payé'; -$_MODULE['<{mollie}prestashop>mollie_a206428462686af481cb072b8db11784'] = 'Autorisé'; -$_MODULE['<{mollie}prestashop>mollie_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Annulé'; -$_MODULE['<{mollie}prestashop>mollie_24fe48030f7d3097d5882535b04c3fa8'] = 'Expiré'; -$_MODULE['<{mollie}prestashop>mollie_cc61945cbbf46721a053467c395c666f'] = 'Remboursé'; -$_MODULE['<{mollie}prestashop>mollie_7026e386bdad92fa6f232394f5b23ffb'] = 'Virement bancaire en attente'; -$_MODULE['<{mollie}prestashop>mollie_9f004157e4c148dac71da3ae5906351f'] = 'Partiellement remboursé'; -$_MODULE['<{mollie}prestashop>mollie_0eceeb45861f9585dd7a97a3e36f85c6'] = 'Créé'; -$_MODULE['<{mollie}prestashop>mollie_ea9cf7e47ff33b2be14e6dd07cbcefc6'] = 'Livraison'; -$_MODULE['<{mollie}prestashop>mollie_3a6e70059673992f825826f7cf89278d'] = 'La règle panier "%1s" (ID %2s) utilisée n\'est pas valide et a été retirée du panier'; -$_MODULE['<{mollie}prestashop>mollie_3a1048f8aa3a9f6b604fcf7982811752'] = 'Attention : il n\'y a pas de clé sécurisée. Vérifiez votre compte de paiement avant validation'; -$_MODULE['<{mollie}prestashop>mollie_26beb437d3323bd4bfb0811b3e891315'] = '%d image(s)'; -$_MODULE['<{mollie}prestashop>mollie_0791970c961c09eb8caaa61aba6a3ca4'] = 'Une erreur s\'est produite lors de la sauvegarde du message'; -$_MODULE['<{mollie}prestashop>mollie_ed13b3693357ebed3751cb71cb639e65'] = 'Pas de transporteur'; -$_MODULE['<{mollie}prestashop>mollie_b08d3867be98e6fff3233cd40ab8134a'] = 'La création de la commande a échoué'; -$_MODULE['<{mollie}prestashop>mollie_43423b4056880b08f2c9aa50d8670531'] = 'Impossible de charger le panier ou une commande a déjà été passée avec ce panier.'; -$_MODULE['<{mollie}prestashop>mollie_32c86f9a2a28a9fa544b97024393633e'] = 'Aucune méthode de paiement trouvée'; -$_MODULE['<{mollie}prestashop>form_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Erreur'; -$_MODULE['<{mollie}prestashop>17_error_47e1924c444fafe9fdfce444790f0ba9'] = 'Retour à votre panier'; -$_MODULE['<{mollie}prestashop>mollie_wait_bc0dd919f9a70dbb62f3f7afd68d6d68'] = 'En attente de paiement'; -$_MODULE['<{mollie}prestashop>order_info_2427b479f15af44582dc151ef95a90d0'] = 'Les remboursements ne sont pas disponibles pour le moment'; -$_MODULE['<{mollie}prestashop>rounding_error_7783c757cd1177e60888080e0f4e0593'] = 'L\'option de configuration "%s" a été définie sur une valeur non supportée'; -$_MODULE['<{mollie}prestashop>rounding_error_2279522d0910767ffa75e0b39ed1629f'] = 'Le mode d\'arrondi sélectionné n\'est pas pris en charge par l\'API Mollie Orders'; -$_MODULE['<{mollie}prestashop>rounding_error_3a92c96baa86286685b233e6912e718d'] = 'Veuillez vous rendre sur la page "%s" et choisir l\'option "%s"'; -$_MODULE['<{mollie}prestashop>smarty_error_9d1fbbe0d150b89f068ba72a20366659'] = 'L\'option de configuration "%s" a été définie sur "%s"'; -$_MODULE['<{mollie}prestashop>smarty_error_27dd3bb10855eb84f48efedf6924c4c1'] = 'Cette option ne permet pas de lister les méthodes de paiement à la validation de la commande'; -$_MODULE['<{mollie}prestashop>smarty_error_4ec23c59d832a2934277a2a040918789'] = 'Veuillez vous rendre sur la page"%s" et choisir l\'autre option'; -$_MODULE['<{mollie}prestashop>smarty_error_92b67311c1a5d6cfc28ba08a1066c901'] = 'Effacez ensuite à nouveau le cache afin que la liste des méthodes de paiement puisse être actualisée.'; -$_MODULE['<{mollie}prestashop>smarty_warning_9d1fbbe0d150b89f068ba72a20366659'] = 'L\'option de configuration "%s" a été définie sur "%s"'; -$_MODULE['<{mollie}prestashop>smarty_warning_e7e747f9c74f0b8222c87db24d34f018'] = 'Il est possible que les méthodes de paiement ne soient pas toutes affichées'; -$_MODULE['<{mollie}prestashop>smarty_warning_1238db0fb782f758b5a54d6333b3610e'] = 'Afin de remédier à ce problème, veuillez vous rendre sur la page "%s" et effacez le cache manuellement ou choisissez l\'une des autres options'; +mollie_09748ce33c8a71296b20ba8c3bd1d13e'] = 'Module de paiement Mollie'; +$_MODULE['<{mollie}prestashop>mollie_95b3b272e06dcc3cc2aa62f6887aebc5'] = 'Mollie Paiements'; +$_MODULE['<{mollie}prestashop>mollie_48dedcf43487615c84c1bbbf6fe76c76'] = 'Etes-vous sûr de vouloir installer le module de paiement Mollie ? '; +$_MODULE['<{mollie}prestashop>mollie_ab552f085567bbe63872c10a3596cd27'] = 'Erreur paiement :'; +$_MODULE['<{mollie}prestashop>mollie_76e084771e78c194efd0e2d5b8920bea'] = 'Payé'; +$_MODULE['<{mollie}prestashop>mollie_f7d543c9b824323b84ab11668002f207'] = 'Autorisé'; +$_MODULE['<{mollie}prestashop>mollie_d5c39a1d9aced393f835f334a1fb9206'] = 'Annulé'; +$_MODULE['<{mollie}prestashop>mollie_c4bfb2a0bab0e91bc7dcfbe3bbec246e'] = 'Expiré'; +$_MODULE['<{mollie}prestashop>mollie_ad32204fca182b862a5f97a5534c03a2'] = 'Remboursé'; +$_MODULE['<{mollie}prestashop>mollie_542ba101e183aea6bc8dab5b1ec5ef7f'] = 'Virement en attente'; +$_MODULE['<{mollie}prestashop>mollie_837cbb7173db2e32b3783e87597dac90'] = 'Partiellement remboursé'; +$_MODULE['<{mollie}prestashop>mollie_e2b7dec8fa4b498156dfee6e4c84b156'] = 'Cette méthode de paiement n\'est pas disponible.'; +$_MODULE['<{mollie}prestashop>mollie_96d0e2862e0167af0c2fd0c99fe6bc5d'] = 'Cliquez ici pour continuer'; +$_MODULE['<{mollie}prestashop>mollie_540d9939d1ca9406e215ee3d78c76813'] = 'Cette méthode de paiement est uniquement disponible pour les euros.'; +$_MODULE['<{mollie}prestashop>mollie_1b2631119333d97dbda37f87e378b1e4'] = 'Une erreur s\'est produite lors du traitement de votre demande :'; +$_MODULE['<{mollie}prestashop>mollie_11bab828edcc0a6d5c97cbf84d61e652'] = 'La commande avec cet identifiant n\'existe pas.'; +$_MODULE['<{mollie}prestashop>mollie_b34487c5f391f47b893ee3c61f8f9ab7'] = 'Nous n\'avons pas reçu de statut de paiement définitif. Vous serez averti dès que nous recevrons une confirmation de la banque / du commerçant.'; +$_MODULE['<{mollie}prestashop>mollie_57bc999b3b730ead92ac7243fe254a2a'] = 'Malheureusement, votre paiement a expiré.'; +$_MODULE['<{mollie}prestashop>mollie_3602f6d5ece34fdbd4ffe0a47f1a2ba4'] = 'Merci ! Nous avons bien reçu votre paiement.'; +$_MODULE['<{mollie}prestashop>mollie_7352a401b3c23b2966c68bc9ab97fa06'] = 'La transaction a un statut inattendu.'; +$_MODULE['<{mollie}prestashop>mollie_3f83176ddc3f63a5a374a623840bfb09'] = 'Vous n\'avez pas accès à cette page.'; +$_MODULE['<{mollie}prestashop>mollie_300225ee958b6350abc51805dab83c24'] = 'Continuer mes achats.'; +$_MODULE['<{mollie}prestashop>mollie_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenue !'; +$_MODULE['<{mollie}prestashop>mollie_66dac2278292ff24611ef8a85bc94e0d'] = 'Sélectionnez votre banque :'; +$_MODULE['<{mollie}prestashop>mollie_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; +$_MODULE['<{mollie}prestashop>mollie_b98a07c82f0078a1de7fc219fae480fc'] = 'Méthode de paiement différente'; +$_MODULE['<{mollie}prestashop>mollie_35895cff7df70dab18783453e2bd241f'] = 'Payer avec %s'; +$_MODULE['<{mollie}prestashop>mollie_cc16e103e202a48009df202d9525f75f'] = 'Rembourser cette commande'; +$_MODULE['<{mollie}prestashop>mollie_c5222afef6530f674d3acf82ba2ce9dc'] = 'Remboursement Mollie'; +$_MODULE['<{mollie}prestashop>mollie_7064b25aa8a732a3db7f230c9867be19'] = 'Remboursement de la commande #%d via l\'API de Mollie.'; +$_MODULE['<{mollie}prestashop>mollie_e12682d2e0650f2783b22d956d2b947a'] = 'La commande a bien été remboursée !'; +$_MODULE['<{mollie}prestashop>mollie_95be87afb2734075cf345b633e1384ec'] = 'Mollie B.V. transférera l\'argent sur le compte de votre client au prochain jour ouvrable.'; +$_MODULE['<{mollie}prestashop>mollie_9770d1f0124abb0d6a894cd79f8703b5'] = 'En attente de paiement Mollie'; +$_MODULE['<{mollie}prestashop>mollie_b9fc80a6e775cb75568db6b6538dacdd'] = 'Mollie partiellement remboursé'; +$_MODULE['<{mollie}prestashop>mollie_f91ab041fe9d6057740394b8b7903a0f'] = 'iDEAL'; +$_MODULE['<{mollie}prestashop>mollie_b749cfb52bfd82c5b12aa49d6906b8e8'] = 'CartaSi'; +$_MODULE['<{mollie}prestashop>mollie_05bfde942b997737b56b9ab405450076'] = 'Cartes Bancaires'; +$_MODULE['<{mollie}prestashop>mollie_e7f9e382dc50889098cbe56f2554c77b'] = 'Cartes de crédit'; +$_MODULE['<{mollie}prestashop>mollie_870cf6bc77bbadd038aeb8d942c9cb18'] = 'Bancontact'; +$_MODULE['<{mollie}prestashop>mollie_8ad65eb3da9995173280649f090218c3'] = 'SOFORT Banking'; +$_MODULE['<{mollie}prestashop>mollie_c0db4214f9d7e1b846f4496e03e667d0'] = 'SEPA Direct Debit'; +$_MODULE['<{mollie}prestashop>mollie_5aa515ce21e8de1ed7416dce455a151f'] = 'Belfius Pay Button'; +$_MODULE['<{mollie}prestashop>mollie_d023ec040f79f1a9b2ac960b43785089'] = 'Bitcoin'; +$_MODULE['<{mollie}prestashop>mollie_4aa65ea89e54d83bb2604c2cc89babc3'] = 'PODIUM Cadeaukaart'; +$_MODULE['<{mollie}prestashop>mollie_58c25c4b8b4382e37d89e0ef6bd625cf'] = 'Cartes cadeaux'; +$_MODULE['<{mollie}prestashop>mollie_431647a0a8b2cd589c9fda9535f90d6d'] = 'Virement bancaire'; +$_MODULE['<{mollie}prestashop>mollie_ad69e733ebae8d264bccaa38d68830e8'] = 'PayPal'; +$_MODULE['<{mollie}prestashop>mollie_6abcd8eecb4f2abb6ccfe36ef7046ba0'] = 'paysafecard'; +$_MODULE['<{mollie}prestashop>mollie_a81bd6195f1abce35fd03a870270100b'] = 'KBC/CBC Payment Button'; +$_MODULE['<{mollie}prestashop>mollie_8184c64d6318b4a42428ae21d0fe2311'] = 'ING Home\'Pay'; +$_MODULE['<{mollie}prestashop>mollie_31911306551723245e7417ae4520fecb'] = 'Giropay'; +$_MODULE['<{mollie}prestashop>mollie_ce8e4a184e2e534c09d6bf6ae773ca4a'] = 'eps'; +$_MODULE['<{mollie}prestashop>mollie_feb1a8ded87483b416427b8457bdc664'] = 'Klarna : Pay later'; +$_MODULE['<{mollie}prestashop>mollie_a388a6fba0d4b58c334cd9416071cdb1'] = 'Klarna : Slice it'; +$_MODULE['<{mollie}prestashop>mollie_d1913efa9eae51595a33f3c1410d465c'] = 'La méthode %s a été remplacée par le module %s. Cela peut causer des interférences avec les paiements.'; +$_MODULE['<{mollie}prestashop>mollie_6311eb29dee3acc14071e0b1efb173f5'] = '%s statuts:'; +$_MODULE['<{mollie}prestashop>mollie_d438a1d96c6037fccad15d7594737a84'] = 'Paramètres visuels :'; +$_MODULE['<{mollie}prestashop>mollie_49259add73e416838e985a6bf4d0e571'] = 'Débogguer les informations :'; +$_MODULE['<{mollie}prestashop>mollie_c9cc8cce247e49bae79f15173ce97354'] = 'Sauvegarder'; +$_MODULE['<{mollie}prestashop>mollie_5bef23eb7efff2736c5583bda59e5eb7'] = 'Créer un compte'; +$_MODULE['<{mollie}prestashop>mollie_a77e6fc49f07414fc53336c8d879b73e'] = 'Vous possédez déjà une clé API ? Vous pouvez alors ignorer cette étape et renseigner votre clé API.'; +$_MODULE['<{mollie}prestashop>mollie_21aef67e8d12503aff027385d0a7867f'] = 'Prénom, Nom'; +$_MODULE['<{mollie}prestashop>mollie_b357b524e740bc85b9790a0712d84a30'] = 'Adresse email'; +$_MODULE['<{mollie}prestashop>mollie_e93c33bd1341ab74195430daeb63db13'] = 'Nom de votre boutique'; +$_MODULE['<{mollie}prestashop>mollie_dd7bf230fde8d4836917806aff6a6b27'] = 'Adresse'; +$_MODULE['<{mollie}prestashop>mollie_8bcdc441379cbf584638b0589a3f9adb'] = 'Code postal'; +$_MODULE['<{mollie}prestashop>mollie_57d056ed0984166336b7879c2af3657f'] = 'Ville'; +$_MODULE['<{mollie}prestashop>mollie_59716c97497eb9694541f7c3d37b1a4d'] = 'Pays'; +$_MODULE['<{mollie}prestashop>mollie_686e697538050e4664636337cc3b834f'] = 'Créer'; +$_MODULE['<{mollie}prestashop>mollie_7c4e7ada50c8572336f872fced4d1852'] = 'Statut pour les paiements %s'; +$_MODULE['<{mollie}prestashop>mollie_bea3fae02ae079e541199ab6ffc2d1ad'] = 'Les paiements`%s` reçoivent le statut `%s`'; +$_MODULE['<{mollie}prestashop>mollie_b2a2c5a69af7c04c5adc48261fb5dc13'] = 'Envoyer Emails lorsque %s'; +$_MODULE['<{mollie}prestashop>mollie_0511c3431d4e32ed4266fe943014d000'] = 'Envoyer Emails lorsque le statut de la transaction devient %s?'; +$_MODULE['<{mollie}prestashop>mollie_7aace0dc23ee8b74744bdf79c98a2605'] = 'Ignorer ce statut'; +$_MODULE['<{mollie}prestashop>mollie_dd59e3663865f3fab190e496260608e6'] = 'Les paiements`%s` ne disposent pas de statut'; +$_MODULE['<{mollie}prestashop>mollie_824f2c1d1c2ee9aecac9977d9347a2ea'] = 'Paramètres Mollie'; +$_MODULE['<{mollie}prestashop>mollie_d876ff8da67c3731ae25d8335a4168b4'] = 'Clé API'; +$_MODULE['<{mollie}prestashop>mollie_2ffbc7eb8899865f9e66682d34853195'] = 'Vous trouverez votre clé API dans votre [1]Profil Mollie[/1]; Elle commence par test ou live.'; +$_MODULE['<{mollie}prestashop>mollie_b5a7adde1af5c87d7fd797b6245c2a39'] = 'Description'; +$_MODULE['<{mollie}prestashop>mollie_3150652ab7f22bafe11a78d4cc0de8be'] = 'Entrez une description ici. Notez : Les méthodes de paiement peuvent comporter une limite de caractère. Il est préférable de garder la description en dessous de 29 caractères. Vous pouvez utiliser les variables suivantes : %s'; +$_MODULE['<{mollie}prestashop>mollie_8d9143dfc520ed7d982d4e545c7bfc5e'] = 'Envoyer localisation pour l\'écran de paiement'; +$_MODULE['<{mollie}prestashop>mollie_1239c091f39c068882e924e34dd9cc40'] = 'Le plugin doit-il envoyer la [1]localisation[/1] du site à Mollie. Les écrans de paiement Mollie seront dans la même langue que votre boutique en ligne. Mollie peut également détecter la langue en fonction de la langue du navigateur de l\'utilisateur.'; +$_MODULE['<{mollie}prestashop>mollie_80a78bb16945665b6410ae8d93e81c69'] = 'Ne pas envoyer la localisation en utilisant la langue du navigateur'; +$_MODULE['<{mollie}prestashop>mollie_3ba67aae5d08d0fa90016685407926f1'] = 'Paramètres visuels'; +$_MODULE['<{mollie}prestashop>mollie_fff0d600f8a0b5e19e88bfb821dd1157'] = 'Images'; +$_MODULE['<{mollie}prestashop>mollie_f7a97136df639501521efb243047e0cf'] = 'Lors du paiement, afficher les logos des méthodes de paiement en grand, normal ou masquer logos.'; +$_MODULE['<{mollie}prestashop>mollie_a88f05b6c963e145a45b58c47cd42a41'] = 'Masquer'; +$_MODULE['<{mollie}prestashop>mollie_fea087517c26fadd409bd4b9dc642555'] = 'Normal'; +$_MODULE['<{mollie}prestashop>mollie_d861877da56b8b4ceb35c8cbfdf65bb4'] = 'Grand'; +$_MODULE['<{mollie}prestashop>mollie_85fb708f31f585607247f8b868efafcc'] = 'Liste des émetteurs'; +$_MODULE['<{mollie}prestashop>mollie_27db39558366d2a9001a0dec69eea4d6'] = 'Certaines méthodes de paiement (ex. iDEAL) possèdent une liste d\'émetteurs. Ce paramètre spécifie où il est affiché.'; +$_MODULE['<{mollie}prestashop>mollie_85a692706bc7597b6e32bc1d354c138f'] = 'Un clic'; +$_MODULE['<{mollie}prestashop>mollie_ea9b19c6f2e9ef60b49778ab9396b293'] = 'Nouvelle page'; +$_MODULE['<{mollie}prestashop>mollie_d35acbb07d2841712a937d5748e9bdc2'] = 'Page de paiement'; +$_MODULE['<{mollie}prestashop>mollie_1547ffc579d657d13fd5fedf12cbfae5'] = 'Fichier CSS'; +$_MODULE['<{mollie}prestashop>mollie_6602513644161421f58418528d93ac00'] = 'Veuillez laisser l\'espace libre pour la feuille de styles par défaut. Elle devrait inclure le chemin du fichier lorsqu\'il est défini. Notez : Vous pouvez utiliser [1]{BASE}[/1], [1]{THEME}[/1], [1]{CSS}[/1], [1]{MOBILE}[/1], [1]{MOBILE_CSS}[/1] et [1]{MASQUER}[/1] pour faciliter la configuration des dossiers.'; +$_MODULE['<{mollie}prestashop>mollie_0da8d9a75492046bea7f314521e07cae'] = 'Méthodes de paiement'; +$_MODULE['<{mollie}prestashop>mollie_75886bf821fc9c068a280fe52337c0f5'] = 'Activez ou désactivez les méthodes de paiement. Vous pouvez faire glisser et déposer pour réorganiser les méthodes de paiement.'; +$_MODULE['<{mollie}prestashop>mollie_c576349bf8ff5fba4e9369ab581a4074'] = 'Activer iDEAL QR'; +$_MODULE['<{mollie}prestashop>mollie_c0ae4417e7a196f3ccfadff68a5064ed'] = 'Les codes QR ne sont actuellement pas pris en charge par l\'API Orders. Nous nous excusons pour le désagrément !'; +$_MODULE['<{mollie}prestashop>mollie_e17dc77fb83539b6a4687c6d515791e4'] = '%s statuts'; +$_MODULE['<{mollie}prestashop>mollie_b068931cc450442b63f5b3d276ea4297'] = 'nom'; +$_MODULE['<{mollie}prestashop>mollie_4695fd3a22023ab53a2151f797975ff8'] = 'Désactiver ce statut'; +$_MODULE['<{mollie}prestashop>mollie_656f9fd6f874404599220855cfec17ef'] = 'API Mollie'; +$_MODULE['<{mollie}prestashop>mollie_a1532be2c9ef11d7dd5edd974fc6c98c'] = 'Sélectionnez l\'API Mollie que vous souhaitez utiliser'; +$_MODULE['<{mollie}prestashop>mollie_9ce1d2272c82bfd7d501a6697df774c7'] = 'Le plugin doit-il utiliser la nouvelle API Mollie Orders ? Cela permet d’utiliser des méthodes de paiement telles que Klarna Pay Later.'; +$_MODULE['<{mollie}prestashop>mollie_8c2b4949d892b39b236545951f10bbd4'] = 'API de paiement'; +$_MODULE['<{mollie}prestashop>mollie_a8b0255f70ecc140a1b5134ae5217e51'] = 'API Orders'; +$_MODULE['<{mollie}prestashop>mollie_1191f888f0cc23f95aa77aacb094503b'] = 'Informations sur l\'expédition'; +$_MODULE['<{mollie}prestashop>mollie_d822c02513be98814bdd39f8bae598d1'] = 'Envoi automatique lorsque noté `expédié`'; +$_MODULE['<{mollie}prestashop>mollie_0eccefc4c96190190add75fe0a74fcd4'] = 'L\'activation de cette fonctionnalité enverra automatiquement les informations concernant l\'expédition lorsqu\'une commande a été notée `expédiée`.'; +$_MODULE['<{mollie}prestashop>mollie_c1df8a5243557cbd8a7a31c11aab3db4'] = 'Envoi automatique lorsque l\'un de ces statuts est atteint'; +$_MODULE['<{mollie}prestashop>mollie_34bd91e87db36a10b9e847d6304be289'] = 'Si une commande atteint l\'un de ces statuts, le module enverra automatiquement les informations concernant l\'expédition.'; +$_MODULE['<{mollie}prestashop>mollie_498f79c4c5bbde77f1bceb6c86fd0f6d'] = 'Afficher'; +$_MODULE['<{mollie}prestashop>mollie_62a5e490880a92eef74f167d9dc6dca0'] = 'Masquer'; +$_MODULE['<{mollie}prestashop>mollie_dc6e4b439165a4e104c9f3cbfcfe2797'] = 'Niveau de débogage'; +$_MODULE['<{mollie}prestashop>mollie_500aa80d6aea3cc9701b566c5f92ed91'] = 'Erreurs d\'affichage'; +$_MODULE['<{mollie}prestashop>mollie_37f9a8b20930c1dc7488b15872b6d36b'] = 'L\'activation de cette fonctionnalité affichera des messages d\'erreur (le cas échéant) sur la page d\'accueil'; +$_MODULE['<{mollie}prestashop>mollie_e5114c4b69585ba5883d456a74c1cd5d'] = 'Niveau en logarithme'; +$_MODULE['<{mollie}prestashop>mollie_921a6d905eef99631c9c73c317799e62'] = 'Niveau recommandé : Erreurs. A définir partout afin de surveiller les demandes Webhook entrantes. [1]Voir logarithmes.[/1]'; +$_MODULE['<{mollie}prestashop>mollie_f80a4ad87fee7c9fdc19b7769495fdb5'] = 'Rien'; +$_MODULE['<{mollie}prestashop>mollie_5ef0c737746fae2ca90e66c39333f8f6'] = 'Erreurs'; +$_MODULE['<{mollie}prestashop>mollie_709468af25e91284821d1bdbfdded24c'] = 'Tout'; +$_MODULE['<{mollie}prestashop>mollie_7c478959c218087ffc4ad5d96e7f66a6'] = 'Mollie'; +$_MODULE['<{mollie}prestashop>mollie_1f93fc361bfc627c89a46e1b6c28df2b'] = 'La clé API doit commencer par test ou live.'; +$_MODULE['<{mollie}prestashop>mollie_6ab1adfed768d989b47c908755fe677f'] = 'La configuration a été sauvegardée !'; +$_MODULE['<{mollie}prestashop>mollie_1f91cd9f380285bf1219c79ab7fcb75e'] = 'Avertissement : Impossible de récupérer le fichier de mise à jour à partir de github.'; +$_MODULE['<{mollie}prestashop>mollie_ce1e483d5cd4b349af887fa3e198ea6b'] = 'Aucun package de téléchargement trouvé pour la dernière version.'; +$_MODULE['<{mollie}prestashop>mollie_048ef1905ff33382d7660a68a6199305'] = 'Avertissement : Impossible de récupérer le fichier xml de mise à jour à partir de github.'; +$_MODULE['<{mollie}prestashop>mollie_711d42f319398490b32cd0e2f0b8ccb8'] = 'Avertissement : La mise à jour du fichier xml à partir de github suit un format inattendu.'; +$_MODULE['<{mollie}prestashop>mollie_48fa0f621f79f451e58f200957da5b52'] = 'Sélectionnez votre banque'; +$_MODULE['<{mollie}prestashop>mollie_8953fb7da2299bf905b73720f611baa3'] = 'ou payez avec iDEAL QR'; +$_MODULE['<{mollie}prestashop>mollie_961f2247a2070bedff9f9cd8d64e2650'] = 'Choisir'; +$_MODULE['<{mollie}prestashop>mollie_ea4788705e6873b424c65e91c2846b19'] = 'Annuler'; +$_MODULE['<{mollie}prestashop>mollie_f93bd0f858a6e5f70cb458c90a36172b'] = 'Impossible de récupérer les informations sur la dernière version'; +$_MODULE['<{mollie}prestashop>mollie_ced93781bca50eb4d970ea51abcc622c'] = 'Vous utilisez déjà la dernière version'; +$_MODULE['<{mollie}prestashop>mollie_43f3c5a157c67de9b6faf42b637f963a'] = 'L\'archive du module n\'a pas pu être téléchargée'; +$_MODULE['<{mollie}prestashop>mollie_31dd57eea0f762b4ea6f022b40acc390'] = 'Une erreur s\'est produite lors de l\'extraction du fichier de module (Il se peut que le fichier soit corrompu).'; +$_MODULE['<{mollie}prestashop>mollie_bad5a3ab102f6e9c27edd494d7e33323'] = 'Félicitations vous avez crée votre compte Mollie avec succès ! Veuillez vérifier votre boite mail pour plus d\'informations'; +$_MODULE['<{mollie}prestashop>mollie_023b7ade110944180153fd73358fc50c'] = 'Une erreur inconnue s\'est produite lors de la création de votre compte Mollie.'; +$_MODULE['<{mollie}prestashop>mollie_88183b946cc5f0e8c96b2e66e1c74a7e'] = 'Inconnu'; +$_MODULE['<{mollie}prestashop>mollie_301b87d33063f687d14004a9014f6759'] = 'Vous n\'êtes pas autorisé à effectuer des remboursements de paiement'; +$_MODULE['<{mollie}prestashop>mollie_8dc6945fb6b59aea38df7935cf3afb6d'] = 'Vous n\'êtes pas autorisé à %s des paiements'; +$_MODULE['<{mollie}prestashop>mollie_1bda80f2be4d3658e0baa43fbe7ae8c1'] = 'Voir'; +$_MODULE['<{mollie}prestashop>mollie_de95b43bceeb4b998aed4aed5cef1ae7'] = 'Modifier'; +$_MODULE['<{mollie}prestashop>mollie_2a3f1166b041928019e4e8718d628665'] = 'Expédier'; +$_MODULE['<{mollie}prestashop>mollie_df6f85687a0d5820baa1a069a04eff2d'] = 'Rembourser'; +$_MODULE['<{mollie}prestashop>mollie_10aec35353f9c4096a71c38654c3d402'] = 'Annuler'; +$_MODULE['<{mollie}prestashop>payment_c2f73af3130be4b4967a475ab846c546'] = 'Une erreur s\'est produite lors de l\'initialisation de votre paiement. Veuillez contacter notre support client.'; +$_MODULE['<{mollie}prestashop>download_update_6de6a882c42b757cd027830399a74de4'] = 'Mettre à jour ce module'; +$_MODULE['<{mollie}prestashop>download_update_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Erreur'; +$_MODULE['<{mollie}prestashop>download_update_5d04a002ea59c8114f9d08b0c6250a3b'] = 'Impossible de se connecter'; +$_MODULE['<{mollie}prestashop>download_update_3844b140df977eee8639de6d1de9e1e0'] = 'Impossible de décompresser le nouveau module'; +$_MODULE['<{mollie}prestashop>download_update_b50ec141b028d5a8acec4a17c32f3808'] = 'Le module a été mis à jour'; +$_MODULE['<{mollie}prestashop>new_release_b7f73af7318580996a3889353b282827'] = 'Vous utilisez actuellement la version %s. Nous vous recommandons vivement de passer à la nouvelle version %s!'; +$_MODULE['<{mollie}prestashop>form_93cba07454f06a4a960172bbd6e2a435'] = 'Oui'; +$_MODULE['<{mollie}prestashop>form_bafd7322c6e97d25b6299b5d6fe8920b'] = 'Non'; +$_MODULE['<{mollie}prestashop>form_2d25c72c1b18e562f6654fff8e11711e'] = 'Non disponible'; +$_MODULE['<{mollie}prestashop>form_58afe6389d8f42880d1011ef0de542a2'] = 'Cette méthode de paiement n\'est pas disponible avec l\'API Payments. Basculez sur l\'API Orders ci-dessous pour activer cette méthode.'; +$_MODULE['<{mollie}prestashop>form_9b6a88a9d4a44740f87b1ffa7cb070c4'] = 'Impossible de charger les méthodes de paiement'; +$_MODULE['<{mollie}prestashop>form_6327b4e59f58137083214a1fec358855'] = 'Réessayer'; +$_MODULE['<{mollie}prestashop>form_49ee3087348e8d44e1feda1917443987'] = 'Nom'; +$_MODULE['<{mollie}prestashop>form_b33f1d112cd9d2d32d37cb4cc9a340c8'] = 'Source URL'; +$_MODULE['<{mollie}prestashop>form_de28ef21a06f3978c05f3d808b15eaab'] = 'URL de l\'opérateur'; +$_MODULE['<{mollie}prestashop>form_812a48ba719daeda82e4da8e812d426c'] = 'URL personnalisée'; +$_MODULE['<{mollie}prestashop>form_e55f75a29310d7b60f7ac1d390c8ae42'] = 'Module'; +$_MODULE['<{mollie}prestashop>form_962b59a5f12eabd9c05f11b5f0aada85'] = 'Ne pas expédier automatiquement'; +$_MODULE['<{mollie}prestashop>form_703490ffd308d337cd5aac50567e9670'] = 'Pas d\'information de suivi'; +$_MODULE['<{mollie}prestashop>form_f421a366f70bd2aa1193eeb5a2990546'] = 'Ici, vous pouvez configurer les informations concernant l\'expédition qui seront envoyées à Mollie'; +$_MODULE['<{mollie}prestashop>form_53b2566e3519ea98db40ae9e716883a5'] = 'Vous pouvez utiliser les variables suivantes pour les URL de Transporteurs'; +$_MODULE['<{mollie}prestashop>form_910d956cb2615e5739ac06c7f08fba26'] = 'Numéro d\'expédition'; +$_MODULE['<{mollie}prestashop>form_e7e862a02819a1610f271ffea15ed47d'] = 'Code du pays de facturation'; +$_MODULE['<{mollie}prestashop>form_5723a18d8a8a6052a57489df5be59a8f'] = 'Code postal de facturation'; +$_MODULE['<{mollie}prestashop>form_0d12e3c554976ad1f76c5db2b6c127ad'] = 'Code du pays d\'expédition'; +$_MODULE['<{mollie}prestashop>form_c824a8b18f09dc7e58bacf446be6735c'] = 'Code postal d\'expédition'; +$_MODULE['<{mollie}prestashop>form_0a867177f4a701a9f33de5ab21c42593'] = 'Code de langue à 2 lettres'; +$_MODULE['<{mollie}prestashop>form_f6fcb64e21455abc4209f8f4440d45f5'] = 'Impossible de charger la liste des transporteurs'; +$_MODULE['<{mollie}prestashop>form_da93de158db2fbe49f35f6038711584a'] = 'Cette option n\'est pas nécessaire pour l\'API actuellement sélectionnée.'; +$_MODULE['<{mollie}prestashop>error_c453a4b8e8d98e82f35b67f433e3b4da'] = 'Paiement'; +$_MODULE['<{mollie}prestashop>error_1e97d97a923eaddd810e056c828e99ea'] = 'Erreur paiement'; +$_MODULE['<{mollie}prestashop>error_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Une erreur est survenue'; +$_MODULE['<{mollie}prestashop>error_47e1924c444fafe9fdfce444790f0ba9'] = 'Retour à mon panier'; +$_MODULE['<{mollie}prestashop>mollie_issuers_588540a38eeba525f3598b68e6b788e5'] = 'ou choisissez une autre méthode de paiement'; +$_MODULE['<{mollie}prestashop>mollie_return_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenue !'; +$_MODULE['<{mollie}prestashop>mollie_return_300225ee958b6350abc51805dab83c24'] = 'Continuer mes achats'; +$_MODULE['<{mollie}prestashop>qr_done_92816c7248d010591f699db3aaf6287b'] = 'Mollie iDEAL QR'; +$_MODULE['<{mollie}prestashop>qr_done_ebdf0f490b617d7efa3025d3625cec85'] = 'Bienvenue !'; +$_MODULE['<{mollie}prestashop>qr_done_4bf3a07ce980c9b007f9e2eed42d7fa2'] = 'Le paiement a été annulé.'; +$_MODULE['<{mollie}prestashop>qr_done_6933c118341d8c06f888c392aa1ceaf5'] = 'Le paiement a été effectué. Merci pour votre commande !'; +$_MODULE['<{mollie}prestashop>ideal_dropdown_ab4147235204a436c09e00d6722082ab'] = 'Sélectionnez une banque'; +$_MODULE['<{mollie}prestashop>order_info_729a51874fe901b092899e9e8b31c97a'] = 'Etes-vous sûr ?'; +$_MODULE['<{mollie}prestashop>order_info_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Etes-vous sûr de vouloir rembourser cette commande ?'; +$_MODULE['<{mollie}prestashop>order_info_76f0ed934de85cc7131910b32ede7714'] = 'Remboursement'; +$_MODULE['<{mollie}prestashop>order_info_ea4788705e6873b424c65e91c2846b19'] = 'Annuler'; +$_MODULE['<{mollie}prestashop>order_info_88ba0dcbc82905637e98317e0302cfd8'] = 'Rembourser commande'; +$_MODULE['<{mollie}prestashop>order_info_5a1119ecb764165f27cb37b6f50134f2'] = 'Restant'; +$_MODULE['<{mollie}prestashop>order_info_77fd2b4393b379bedd30efcd5df02090'] = 'Remboursement partiel'; +$_MODULE['<{mollie}prestashop>order_info_a9ced76f2dd6907220fa95b3a136b04a'] = 'Montant invalide'; +$_MODULE['<{mollie}prestashop>order_info_3a2c3e97fed586776c2800fb7a0faf4e'] = 'Vous avez entré un montant invalide'; +$_MODULE['<{mollie}prestashop>order_info_3cc4859e502556d0d848c3bc38618782'] = 'Le remboursement a échoué'; +$_MODULE['<{mollie}prestashop>order_info_d5cfd0f69cd548e5d3b9edde5ff1b48f'] = 'Informations sur le paiement'; +$_MODULE['<{mollie}prestashop>order_info_88427ec035734b45aae9f7d8859a5008'] = 'Identifiant de transaction'; +$_MODULE['<{mollie}prestashop>order_info_782678f4ba02feb3e9ecd51e902cd16b'] = 'Historique de remboursements'; +$_MODULE['<{mollie}prestashop>order_info_c5b41ae59bd6585750f536615a6bc20b'] = 'Il n\'y a aucun remboursement'; +$_MODULE['<{mollie}prestashop>order_info_b718adec73e04ce3ec720dd11a06a308'] = 'Identifiant'; +$_MODULE['<{mollie}prestashop>order_info_44749712dbec183e983dcd78a7736c41'] = 'Date'; +$_MODULE['<{mollie}prestashop>order_info_b2f40690858b404ed10e62bdf422c704'] = 'Montant'; +$_MODULE['<{mollie}prestashop>order_info_53beb26d8bca00f56fbd295fdee83459'] = 'Remboursements'; +$_MODULE['<{mollie}prestashop>order_info_daef64964ee3b9b904f5d467586e217f'] = 'Paiements'; +$_MODULE['<{mollie}prestashop>order_info_e25be354288565757726f3295e4f3ef9'] = 'Montant actuel'; +$_MODULE['<{mollie}prestashop>order_info_068f80c7519d0528fb08e82137a72131'] = 'Produits'; +$_MODULE['<{mollie}prestashop>order_info_ec53a8c4f07baed5d8825072c89799be'] = 'Statuts'; +$_MODULE['<{mollie}prestashop>order_info_747cf5c8587184b9e489ff897d97c20d'] = 'Expédié'; +$_MODULE['<{mollie}prestashop>order_info_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Annulé'; +$_MODULE['<{mollie}prestashop>order_info_cc61945cbbf46721a053467c395c666f'] = 'Remboursé'; +$_MODULE['<{mollie}prestashop>order_info_197101c4a1b1fc503dcd6ebee127aa10'] = 'Prix unitaire'; +$_MODULE['<{mollie}prestashop>order_info_11cd653a2488e260a8a99f39cdffa6e7'] = 'Montant TVA'; +$_MODULE['<{mollie}prestashop>order_info_bc30768048a7bbfd2d158d722c140c6d'] = 'Montant total'; +$_MODULE['<{mollie}prestashop>order_info_0387832795db3eb2e05f4365fba5ddac'] = 'Expédier'; +$_MODULE['<{mollie}prestashop>order_info_55453aad10c96e452556a106447313bd'] = 'Examiner l\'envoi'; +$_MODULE['<{mollie}prestashop>order_info_dbb5bbb116e16973136b9ebd887eaadd'] = 'Merci de revoir les produits inclus dans votre envoi. Vous pouvez supprimer des articles ou modifier la quantité si nécessaire.'; +$_MODULE['<{mollie}prestashop>order_info_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; +$_MODULE['<{mollie}prestashop>order_info_163bcc6065b16c6369c7a4de44cff164'] = 'Expédier les produits'; +$_MODULE['<{mollie}prestashop>order_info_433557a938a920888445ce2c7df67d5a'] = 'Détails de suivi'; +$_MODULE['<{mollie}prestashop>order_info_61995a579a6166642e759450a694642b'] = 'Il est recommandé d\'ajouter des informations de suivi à votre envoi. Cela prouvera que vous avez bien expédié les produits à votre client.'; +$_MODULE['<{mollie}prestashop>order_info_26b6254fefc06894825a50dfbe803937'] = 'Ignorer les détails de suivi'; +$_MODULE['<{mollie}prestashop>order_info_d57c24f3fe52d16e7169b912dd647f0d'] = 'Optionel'; +$_MODULE['<{mollie}prestashop>order_info_2df417909bda5f3ddc210a0abe65231f'] = 'E.x. FedEx'; +$_MODULE['<{mollie}prestashop>order_info_593ed3a37aa1a3ece4a4d796fb4e2e03'] = 'Cette information est obligatoire'; +$_MODULE['<{mollie}prestashop>order_info_933292561b46133ff5348c7740874c56'] = 'Code de suivi'; +$_MODULE['<{mollie}prestashop>order_info_e6b391a8d2c4d45902a23a8b6585703d'] = 'URL'; +$_MODULE['<{mollie}prestashop>order_info_914419aa32f04011357d3b604a86d7eb'] = 'Transporteur'; +$_MODULE['<{mollie}prestashop>order_info_23a902ac637359fe67ceaccbe2c68283'] = 'Tout expédier'; +$_MODULE['<{mollie}prestashop>order_info_2a6e9f678c7267fe16f57bcd3285f1d7'] = 'Tout annuler'; +$_MODULE['<{mollie}prestashop>order_info_05ced64413f9ff5d3602c3e257f36204'] = 'Tout rembourser'; +$_MODULE['<{mollie}prestashop>order_info_bfe005bff7ecacd6ecceacdd7fb79292'] = 'Informations transaction'; +$_MODULE['<{mollie}prestashop>order_info_1eefa98a18a384699fe611fbfd8ab0c9'] = 'Il n\'y a aucun produit'; +$_MODULE['<{mollie}prestashop>order_info_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Une erreur est survenue'; +$_MODULE['<{mollie}prestashop>order_info_2df3102f3fe061003dee820a72e1b1ed'] = 'Impossible d\'expédier'; +$_MODULE['<{mollie}prestashop>order_info_3efc29552025b4e68de04f415b0b8806'] = 'Impossible d\'effectuer le remboursement'; +$_MODULE['<{mollie}prestashop>order_info_468a92810b526750be9664461db6bf91'] = 'Impossible d\'annuler'; +$_MODULE['<{mollie}prestashop>qr_code_9ba19ddbcfeddfc758eb84fb8ba26b5e'] = 'ou scanner le code iDEAL QR'; +$_MODULE['<{mollie}prestashop>refund_729a51874fe901b092899e9e8b31c97a'] = 'Etes-vous sûr ?'; +$_MODULE['<{mollie}prestashop>refund_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Etes-vous sûr de vouloir rembourser cette commande ?'; +$_MODULE['<{mollie}prestashop>refund_76f0ed934de85cc7131910b32ede7714'] = 'Rembourser'; +$_MODULE['<{mollie}prestashop>refund_ea4788705e6873b424c65e91c2846b19'] = 'Annuler'; +$_MODULE['<{mollie}prestashop>mollie_484f5a79672cebe198ebdde45a1d672f'] = 'Papier cadeau'; +$_MODULE['<{mollie}prestashop>mollie_e0010a0a1a3259ab5c06a19bad532851'] = 'Payé'; +$_MODULE['<{mollie}prestashop>mollie_a206428462686af481cb072b8db11784'] = 'Autorisé'; +$_MODULE['<{mollie}prestashop>mollie_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Annulé'; +$_MODULE['<{mollie}prestashop>mollie_24fe48030f7d3097d5882535b04c3fa8'] = 'Expiré'; +$_MODULE['<{mollie}prestashop>mollie_cc61945cbbf46721a053467c395c666f'] = 'Remboursé'; +$_MODULE['<{mollie}prestashop>mollie_7026e386bdad92fa6f232394f5b23ffb'] = 'Virement bancaire en attente'; +$_MODULE['<{mollie}prestashop>mollie_9f004157e4c148dac71da3ae5906351f'] = 'Partiellement remboursé'; +$_MODULE['<{mollie}prestashop>mollie_0eceeb45861f9585dd7a97a3e36f85c6'] = 'Créé'; +$_MODULE['<{mollie}prestashop>mollie_ea9cf7e47ff33b2be14e6dd07cbcefc6'] = 'Livraison'; +$_MODULE['<{mollie}prestashop>mollie_3a6e70059673992f825826f7cf89278d'] = 'La règle panier "%1s" (ID %2s) utilisée n\'est pas valide et a été retirée du panier'; +$_MODULE['<{mollie}prestashop>mollie_3a1048f8aa3a9f6b604fcf7982811752'] = 'Attention : il n\'y a pas de clé sécurisée. Vérifiez votre compte de paiement avant validation'; +$_MODULE['<{mollie}prestashop>mollie_26beb437d3323bd4bfb0811b3e891315'] = '%d image(s)'; +$_MODULE['<{mollie}prestashop>mollie_0791970c961c09eb8caaa61aba6a3ca4'] = 'Une erreur s\'est produite lors de la sauvegarde du message'; +$_MODULE['<{mollie}prestashop>mollie_ed13b3693357ebed3751cb71cb639e65'] = 'Pas de transporteur'; +$_MODULE['<{mollie}prestashop>mollie_b08d3867be98e6fff3233cd40ab8134a'] = 'La création de la commande a échoué'; +$_MODULE['<{mollie}prestashop>mollie_43423b4056880b08f2c9aa50d8670531'] = 'Impossible de charger le panier ou une commande a déjà été passée avec ce panier.'; +$_MODULE['<{mollie}prestashop>mollie_32c86f9a2a28a9fa544b97024393633e'] = 'Aucune méthode de paiement trouvée'; +$_MODULE['<{mollie}prestashop>form_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Erreur'; +$_MODULE['<{mollie}prestashop>17_error_47e1924c444fafe9fdfce444790f0ba9'] = 'Retour à votre panier'; +$_MODULE['<{mollie}prestashop>mollie_wait_bc0dd919f9a70dbb62f3f7afd68d6d68'] = 'En attente de paiement'; +$_MODULE['<{mollie}prestashop>order_info_2427b479f15af44582dc151ef95a90d0'] = 'Les remboursements ne sont pas disponibles pour le moment'; +$_MODULE['<{mollie}prestashop>rounding_error_7783c757cd1177e60888080e0f4e0593'] = 'L\'option de configuration "%s" a été définie sur une valeur non supportée'; +$_MODULE['<{mollie}prestashop>rounding_error_2279522d0910767ffa75e0b39ed1629f'] = 'Le mode d\'arrondi sélectionné n\'est pas pris en charge par l\'API Mollie Orders'; +$_MODULE['<{mollie}prestashop>rounding_error_3a92c96baa86286685b233e6912e718d'] = 'Veuillez vous rendre sur la page "%s" et choisir l\'option "%s"'; +$_MODULE['<{mollie}prestashop>smarty_error_9d1fbbe0d150b89f068ba72a20366659'] = 'L\'option de configuration "%s" a été définie sur "%s"'; +$_MODULE['<{mollie}prestashop>smarty_error_27dd3bb10855eb84f48efedf6924c4c1'] = 'Cette option ne permet pas de lister les méthodes de paiement à la validation de la commande'; +$_MODULE['<{mollie}prestashop>smarty_error_4ec23c59d832a2934277a2a040918789'] = 'Veuillez vous rendre sur la page"%s" et choisir l\'autre option'; +$_MODULE['<{mollie}prestashop>smarty_error_92b67311c1a5d6cfc28ba08a1066c901'] = 'Effacez ensuite à nouveau le cache afin que la liste des méthodes de paiement puisse être actualisée.'; +$_MODULE['<{mollie}prestashop>smarty_warning_9d1fbbe0d150b89f068ba72a20366659'] = 'L\'option de configuration "%s" a été définie sur "%s"'; +$_MODULE['<{mollie}prestashop>smarty_warning_e7e747f9c74f0b8222c87db24d34f018'] = 'Il est possible que les méthodes de paiement ne soient pas toutes affichées'; +$_MODULE['<{mollie}prestashop>smarty_warning_1238db0fb782f758b5a54d6333b3610e'] = 'Afin de remédier à ce problème, veuillez vous rendre sur la page "%s" et effacez le cache manuellement ou choisissez l\'une des autres options'; diff --git a/translations/index.php b/translations/index.php index 729abf520..a950d02f4 100644 --- a/translations/index.php +++ b/translations/index.php @@ -1,11 +1,11 @@ -mollie_09748ce33c8a71296b20ba8c3bd1d13e'] = 'Mollie Payment Module'; -$_MODULE['<{mollie}prestashop>mollie_95b3b272e06dcc3cc2aa62f6887aebc5'] = 'Mollie Betalingen'; -$_MODULE['<{mollie}prestashop>mollie_48dedcf43487615c84c1bbbf6fe76c76'] = 'Weet u zeker dat u de installatie van de Mollie Payment Module ongedaan wilt maken?'; -$_MODULE['<{mollie}prestashop>mollie_ab552f085567bbe63872c10a3596cd27'] = 'Betaalfout:'; -$_MODULE['<{mollie}prestashop>mollie_76e084771e78c194efd0e2d5b8920bea'] = 'betaald'; -$_MODULE['<{mollie}prestashop>mollie_f7d543c9b824323b84ab11668002f207'] = 'geautoriseerd'; -$_MODULE['<{mollie}prestashop>mollie_d5c39a1d9aced393f835f334a1fb9206'] = 'geannuleerd'; -$_MODULE['<{mollie}prestashop>mollie_c4bfb2a0bab0e91bc7dcfbe3bbec246e'] = 'verlopen'; -$_MODULE['<{mollie}prestashop>mollie_ad32204fca182b862a5f97a5534c03a2'] = 'terugbetaald'; -$_MODULE['<{mollie}prestashop>mollie_542ba101e183aea6bc8dab5b1ec5ef7f'] = 'open'; -$_MODULE['<{mollie}prestashop>mollie_837cbb7173db2e32b3783e87597dac90'] = 'gedeeltelijk terugbetaald'; -$_MODULE['<{mollie}prestashop>mollie_e2b7dec8fa4b498156dfee6e4c84b156'] = 'Deze betaalmethode is niet beschikbaar'; -$_MODULE['<{mollie}prestashop>mollie_96d0e2862e0167af0c2fd0c99fe6bc5d'] = 'Klik hier om verder te gaan'; -$_MODULE['<{mollie}prestashop>mollie_540d9939d1ca9406e215ee3d78c76813'] = 'Deze betaalmethode is alleen beschikbaar voor euro\'s.'; -$_MODULE['<{mollie}prestashop>mollie_1b2631119333d97dbda37f87e378b1e4'] = 'Er is een probleem opgetreden bij het verwerken van dit betaalverzoek:'; -$_MODULE['<{mollie}prestashop>mollie_11bab828edcc0a6d5c97cbf84d61e652'] = 'De bestelling met dit id kon niet gevonden worden.'; -$_MODULE['<{mollie}prestashop>mollie_b34487c5f391f47b893ee3c61f8f9ab7'] = 'Er is nog geen definitieve betaalstatus bekend. U wordt op de hoogte gesteld zodra de bank de status doorgeeft.'; -$_MODULE['<{mollie}prestashop>mollie_57bc999b3b730ead92ac7243fe254a2a'] = 'Helaas is uw betaling verlopen.'; -$_MODULE['<{mollie}prestashop>mollie_3602f6d5ece34fdbd4ffe0a47f1a2ba4'] = 'Dank u wel, uw betaling is ontvangen.'; -$_MODULE['<{mollie}prestashop>mollie_7352a401b3c23b2966c68bc9ab97fa06'] = 'De transactie heeft een onverwachte status.'; -$_MODULE['<{mollie}prestashop>mollie_3f83176ddc3f63a5a374a623840bfb09'] = 'U hebt geen toegang tot deze pagina.'; -$_MODULE['<{mollie}prestashop>mollie_300225ee958b6350abc51805dab83c24'] = 'Doorgaan met winkelen'; -$_MODULE['<{mollie}prestashop>mollie_ebdf0f490b617d7efa3025d3625cec85'] = 'Welkom terug'; -$_MODULE['<{mollie}prestashop>mollie_66dac2278292ff24611ef8a85bc94e0d'] = 'Kies uw bank:'; -$_MODULE['<{mollie}prestashop>mollie_e0aa021e21dddbd6d8cecec71e9cf564'] = 'Oke'; -$_MODULE['<{mollie}prestashop>mollie_b98a07c82f0078a1de7fc219fae480fc'] = 'Andere betaalmethode'; -$_MODULE['<{mollie}prestashop>mollie_35895cff7df70dab18783453e2bd241f'] = 'Betalen via %s'; -$_MODULE['<{mollie}prestashop>mollie_cc16e103e202a48009df202d9525f75f'] = 'Bestelling terugbetalen'; -$_MODULE['<{mollie}prestashop>mollie_c5222afef6530f674d3acf82ba2ce9dc'] = 'Mollie Terugbetalingen'; -$_MODULE['<{mollie}prestashop>mollie_7064b25aa8a732a3db7f230c9867be19'] = 'Betaal bestelling #%d volledig terugbetalen via de Mollie API'; -$_MODULE['<{mollie}prestashop>mollie_e12682d2e0650f2783b22d956d2b947a'] = 'Deze bestelling is terugbetaald!'; -$_MODULE['<{mollie}prestashop>mollie_95be87afb2734075cf345b633e1384ec'] = 'Mollie B.V. boekt het bedrag de volgende werkdag terug naar uw klant.'; -$_MODULE['<{mollie}prestashop>mollie_9770d1f0124abb0d6a894cd79f8703b5'] = 'Wachten op betaling Mollie'; -$_MODULE['<{mollie}prestashop>mollie_b9fc80a6e775cb75568db6b6538dacdd'] = 'Mollie Gedeeltelijke Terugbetaling'; -$_MODULE['<{mollie}prestashop>mollie_f91ab041fe9d6057740394b8b7903a0f'] = 'iDEAL'; -$_MODULE['<{mollie}prestashop>mollie_b749cfb52bfd82c5b12aa49d6906b8e8'] = 'CartaSi'; -$_MODULE['<{mollie}prestashop>mollie_05bfde942b997737b56b9ab405450076'] = 'Cartes Bancaires'; -$_MODULE['<{mollie}prestashop>mollie_e7f9e382dc50889098cbe56f2554c77b'] = 'Credit card'; -$_MODULE['<{mollie}prestashop>mollie_870cf6bc77bbadd038aeb8d942c9cb18'] = 'Bancontact'; -$_MODULE['<{mollie}prestashop>mollie_8ad65eb3da9995173280649f090218c3'] = 'SOFORT Banking'; -$_MODULE['<{mollie}prestashop>mollie_c0db4214f9d7e1b846f4496e03e667d0'] = 'SEPA Direct Debit'; -$_MODULE['<{mollie}prestashop>mollie_5aa515ce21e8de1ed7416dce455a151f'] = 'Belfius Pay Button'; -$_MODULE['<{mollie}prestashop>mollie_d023ec040f79f1a9b2ac960b43785089'] = 'Bitcoin'; -$_MODULE['<{mollie}prestashop>mollie_4aa65ea89e54d83bb2604c2cc89babc3'] = 'PODIUM Cadeaukaart'; -$_MODULE['<{mollie}prestashop>mollie_58c25c4b8b4382e37d89e0ef6bd625cf'] = 'Gift cards'; -$_MODULE['<{mollie}prestashop>mollie_431647a0a8b2cd589c9fda9535f90d6d'] = 'Overboeking'; -$_MODULE['<{mollie}prestashop>mollie_ad69e733ebae8d264bccaa38d68830e8'] = 'PayPal'; -$_MODULE['<{mollie}prestashop>mollie_6abcd8eecb4f2abb6ccfe36ef7046ba0'] = 'paysafecard'; -$_MODULE['<{mollie}prestashop>mollie_a81bd6195f1abce35fd03a870270100b'] = 'KBC/CBC Payment Button'; -$_MODULE['<{mollie}prestashop>mollie_8184c64d6318b4a42428ae21d0fe2311'] = 'ING Home\'Pay'; -$_MODULE['<{mollie}prestashop>mollie_31911306551723245e7417ae4520fecb'] = 'Giropay'; -$_MODULE['<{mollie}prestashop>mollie_ce8e4a184e2e534c09d6bf6ae773ca4a'] = 'eps'; -$_MODULE['<{mollie}prestashop>mollie_feb1a8ded87483b416427b8457bdc664'] = 'Klarna: Achteraf betalen'; -$_MODULE['<{mollie}prestashop>mollie_a388a6fba0d4b58c334cd9416071cdb1'] = 'Klarna: Gespreid betalen'; -$_MODULE['<{mollie}prestashop>mollie_d1913efa9eae51595a33f3c1410d465c'] = 'De methode %s is overschreven door de %s module. Dit kan problemen veroorzaken wanneer men betalingen verricht.'; -$_MODULE['<{mollie}prestashop>mollie_6311eb29dee3acc14071e0b1efb173f5'] = 'Status \"%s\":'; -$_MODULE['<{mollie}prestashop>mollie_d438a1d96c6037fccad15d7594737a84'] = 'Visuele instellingen:'; -$_MODULE['<{mollie}prestashop>mollie_49259add73e416838e985a6bf4d0e571'] = 'Debug informatie:'; -$_MODULE['<{mollie}prestashop>mollie_c9cc8cce247e49bae79f15173ce97354'] = 'Opslaan'; -$_MODULE['<{mollie}prestashop>mollie_5bef23eb7efff2736c5583bda59e5eb7'] = 'Maak uw account aan'; -$_MODULE['<{mollie}prestashop>mollie_a77e6fc49f07414fc53336c8d879b73e'] = 'Heeft u al een account? Dan kunt u deze stap overslaan en uw API-key invoeren.'; -$_MODULE['<{mollie}prestashop>mollie_21aef67e8d12503aff027385d0a7867f'] = 'Voor- en achternaam'; -$_MODULE['<{mollie}prestashop>mollie_b357b524e740bc85b9790a0712d84a30'] = 'E-mailadres'; -$_MODULE['<{mollie}prestashop>mollie_e93c33bd1341ab74195430daeb63db13'] = 'Winkelnaam'; -$_MODULE['<{mollie}prestashop>mollie_dd7bf230fde8d4836917806aff6a6b27'] = 'Adres'; -$_MODULE['<{mollie}prestashop>mollie_8bcdc441379cbf584638b0589a3f9adb'] = 'Postcode'; -$_MODULE['<{mollie}prestashop>mollie_57d056ed0984166336b7879c2af3657f'] = 'Stad'; -$_MODULE['<{mollie}prestashop>mollie_59716c97497eb9694541f7c3d37b1a4d'] = 'Land'; -$_MODULE['<{mollie}prestashop>mollie_686e697538050e4664636337cc3b834f'] = 'Account aanmaken'; -$_MODULE['<{mollie}prestashop>mollie_7c4e7ada50c8572336f872fced4d1852'] = 'Status voor betaling %s'; -$_MODULE['<{mollie}prestashop>mollie_bea3fae02ae079e541199ab6ffc2d1ad'] = '`%s` betalingen krijgen de status `%s`'; -$_MODULE['<{mollie}prestashop>mollie_b2a2c5a69af7c04c5adc48261fb5dc13'] = 'Verzend mail bij %s'; -$_MODULE['<{mollie}prestashop>mollie_0511c3431d4e32ed4266fe943014d000'] = 'Verstuur een email als de status in %s verandert?'; -$_MODULE['<{mollie}prestashop>mollie_7aace0dc23ee8b74744bdf79c98a2605'] = 'Sla deze status over'; -$_MODULE['<{mollie}prestashop>mollie_dd59e3663865f3fab190e496260608e6'] = '`%s` betalingen krijgen geen status'; -$_MODULE['<{mollie}prestashop>mollie_824f2c1d1c2ee9aecac9977d9347a2ea'] = 'Mollie instellingen'; -$_MODULE['<{mollie}prestashop>mollie_d876ff8da67c3731ae25d8335a4168b4'] = 'API Key'; -$_MODULE['<{mollie}prestashop>mollie_2ffbc7eb8899865f9e66682d34853195'] = 'U vindt uw API Sleutel in uw [1]Mollie Profiel[/1]; de sleutel begint met test_ of live_.'; -$_MODULE['<{mollie}prestashop>mollie_b5a7adde1af5c87d7fd797b6245c2a39'] = 'Omschrijving'; -$_MODULE['<{mollie}prestashop>mollie_3150652ab7f22bafe11a78d4cc0de8be'] = 'Voer hier een omschrijving in. Let op: betaalmethoden kunnen een tekenlimiet bevatten, houd de beschrijving onder de 29 tekens. U kunt de volgende variabelen gebruiken: %s'; -$_MODULE['<{mollie}prestashop>mollie_8d9143dfc520ed7d982d4e545c7bfc5e'] = 'Stuur locale voor betaalscherm'; -$_MODULE['<{mollie}prestashop>mollie_1239c091f39c068882e924e34dd9cc40'] = 'Moet de plugin de [1]locale[/1] van uw webshop sturen? Het betaalscherm zal dan in dezelfde taal als uw website worden weergegeven. Standaard zal Mollie de taal detecteren aan de hand van de browser taal.'; -$_MODULE['<{mollie}prestashop>mollie_80a78bb16945665b6410ae8d93e81c69'] = 'Stuur geen locale, gebruik browser taal'; -$_MODULE['<{mollie}prestashop>mollie_3ba67aae5d08d0fa90016685407926f1'] = 'Visuele instellingen'; -$_MODULE['<{mollie}prestashop>mollie_fff0d600f8a0b5e19e88bfb821dd1157'] = 'Afbeeldingen'; -$_MODULE['<{mollie}prestashop>mollie_f7a97136df639501521efb243047e0cf'] = 'Laat grote, normale of geen logo zien van betaalmethodes op de afrekenpagina'; -$_MODULE['<{mollie}prestashop>mollie_a88f05b6c963e145a45b58c47cd42a41'] = 'geen'; -$_MODULE['<{mollie}prestashop>mollie_fea087517c26fadd409bd4b9dc642555'] = 'normaal'; -$_MODULE['<{mollie}prestashop>mollie_d861877da56b8b4ceb35c8cbfdf65bb4'] = 'groot'; -$_MODULE['<{mollie}prestashop>mollie_85fb708f31f585607247f8b868efafcc'] = 'Bankenlijst'; -$_MODULE['<{mollie}prestashop>mollie_27db39558366d2a9001a0dec69eea4d6'] = 'Sommige betaalmethoden (zoals iDEAL) hebben een bankenlijst. Deze instelling bepaalt waar die lijst zichtbaar is.'; -$_MODULE['<{mollie}prestashop>mollie_85a692706bc7597b6e32bc1d354c138f'] = 'Zichtbaar na klikken betaalmethode'; -$_MODULE['<{mollie}prestashop>mollie_ea9b19c6f2e9ef60b49778ab9396b293'] = 'Tonen op aparte pagina'; -$_MODULE['<{mollie}prestashop>mollie_d35acbb07d2841712a937d5748e9bdc2'] = 'Tonen op Mollie betaalpagina'; -$_MODULE['<{mollie}prestashop>mollie_1547ffc579d657d13fd5fedf12cbfae5'] = 'CSS-bestand'; -$_MODULE['<{mollie}prestashop>mollie_6602513644161421f58418528d93ac00'] = 'Laat leeg voor standaardvormgeving. Hint: Gebruik [1]{BASE}[/1], [1]{THEME}[/1], [1]{CSS}[/1], [1]{MOBILE}[/1], [1]{MOBILE_CSS}[/1] en [1]{OVERRIDE}[/1] voor de standaard bestandsmappen.'; -$_MODULE['<{mollie}prestashop>mollie_0da8d9a75492046bea7f314521e07cae'] = 'Betaalmethoden'; -$_MODULE['<{mollie}prestashop>mollie_75886bf821fc9c068a280fe52337c0f5'] = 'Schakel betaalmethoden in of uit. U kunt de betaalmethoden rangschikken door deze te slepen.'; -$_MODULE['<{mollie}prestashop>mollie_c576349bf8ff5fba4e9369ab581a4074'] = 'Mollie iDEAL-QR'; -$_MODULE['<{mollie}prestashop>mollie_c0ae4417e7a196f3ccfadff68a5064ed'] = 'iDEAL QR Code is momenteel nog niet beschikbaar in de Orders API. Onze excuses voor het ongemak.'; -$_MODULE['<{mollie}prestashop>mollie_e17dc77fb83539b6a4687c6d515791e4'] = '%s statussen'; -$_MODULE['<{mollie}prestashop>mollie_b068931cc450442b63f5b3d276ea4297'] = 'naam'; -$_MODULE['<{mollie}prestashop>mollie_4695fd3a22023ab53a2151f797975ff8'] = 'Deze status uitschakelen'; -$_MODULE['<{mollie}prestashop>mollie_656f9fd6f874404599220855cfec17ef'] = 'Mollie API'; -$_MODULE['<{mollie}prestashop>mollie_a1532be2c9ef11d7dd5edd974fc6c98c'] = 'Selecteer de Mollie API die u wilt gebruiken'; -$_MODULE['<{mollie}prestashop>mollie_9ce1d2272c82bfd7d501a6697df774c7'] = 'Moet de plugin de nieuwe Mollie Orders API gebruiken? Hiermee kunt u gebruik maken van betaalmethodes zoals Klarna Pay Later.'; -$_MODULE['<{mollie}prestashop>mollie_8c2b4949d892b39b236545951f10bbd4'] = 'Payments API'; -$_MODULE['<{mollie}prestashop>mollie_a8b0255f70ecc140a1b5134ae5217e51'] = 'Orders API'; -$_MODULE['<{mollie}prestashop>mollie_1191f888f0cc23f95aa77aacb094503b'] = 'Verzending informatie'; -$_MODULE['<{mollie}prestashop>mollie_d822c02513be98814bdd39f8bae598d1'] = 'Automatisch verzenden indien gemarkeerd als verzonden'; -$_MODULE['<{mollie}prestashop>mollie_0eccefc4c96190190add75fe0a74fcd4'] = 'Door deze optie in te schakelen wordt de informatie inzake de verzending automatisch verzonden wanneer de order als \'verzonden\' is gemarkeerd'; -$_MODULE['<{mollie}prestashop>mollie_c1df8a5243557cbd8a7a31c11aab3db4'] = 'Automatisch verzenden indien wanneer de order als een van deze statussen is gemarkeerd'; -$_MODULE['<{mollie}prestashop>mollie_34bd91e87db36a10b9e847d6304be289'] = 'Wanneer de order als een van deze statussen is gemarkeerd wordt de informatie inzake de verzending automatisch verzonden'; -$_MODULE['<{mollie}prestashop>mollie_498f79c4c5bbde77f1bceb6c86fd0f6d'] = 'Openen'; -$_MODULE['<{mollie}prestashop>mollie_62a5e490880a92eef74f167d9dc6dca0'] = 'Sluiten'; -$_MODULE['<{mollie}prestashop>mollie_dc6e4b439165a4e104c9f3cbfcfe2797'] = 'Debug informatie'; -$_MODULE['<{mollie}prestashop>mollie_500aa80d6aea3cc9701b566c5f92ed91'] = 'Foutmeldingen weergeven'; -$_MODULE['<{mollie}prestashop>mollie_37f9a8b20930c1dc7488b15872b6d36b'] = 'Door deze optie aan te zetten worden foutmeldingen op de voorpagina weergegeven. Alleen voor debug!'; -$_MODULE['<{mollie}prestashop>mollie_e5114c4b69585ba5883d456a74c1cd5d'] = 'Log niveau'; -$_MODULE['<{mollie}prestashop>mollie_921a6d905eef99631c9c73c317799e62'] = 'Aangeraden niveau: Errors. Zet op alles om de webhook requests te monitoren. [1]Bekijk logs[/1]'; -$_MODULE['<{mollie}prestashop>mollie_f80a4ad87fee7c9fdc19b7769495fdb5'] = 'Geen'; -$_MODULE['<{mollie}prestashop>mollie_5ef0c737746fae2ca90e66c39333f8f6'] = 'Fouten'; -$_MODULE['<{mollie}prestashop>mollie_709468af25e91284821d1bdbfdded24c'] = 'Alles'; -$_MODULE['<{mollie}prestashop>mollie_7c478959c218087ffc4ad5d96e7f66a6'] = 'Mollie'; -$_MODULE['<{mollie}prestashop>mollie_1f93fc361bfc627c89a46e1b6c28df2b'] = 'De API Sleutel dient met test_ of live_ te beginnen.'; -$_MODULE['<{mollie}prestashop>mollie_6ab1adfed768d989b47c908755fe677f'] = 'De configuratie is opgeslagen!'; -$_MODULE['<{mollie}prestashop>mollie_1f91cd9f380285bf1219c79ab7fcb75e'] = 'Waarschuwing: kon het update-bestand niet ophalen vanaf GitHub'; -$_MODULE['<{mollie}prestashop>mollie_ce1e483d5cd4b349af887fa3e198ea6b'] = 'Geen download package gevonden voor de meest recente release.'; -$_MODULE['<{mollie}prestashop>mollie_048ef1905ff33382d7660a68a6199305'] = 'Waarschuwing: Kon de update XML van github niet ophalen.'; -$_MODULE['<{mollie}prestashop>mollie_711d42f319398490b32cd0e2f0b8ccb8'] = 'Waarschuwing: Het update xml bestand van github volgt een onverwacht formaat.'; -$_MODULE['<{mollie}prestashop>mollie_48fa0f621f79f451e58f200957da5b52'] = 'Kies uw bank'; -$_MODULE['<{mollie}prestashop>mollie_8953fb7da2299bf905b73720f611baa3'] = 'of betaal met iDEAL-QR'; -$_MODULE['<{mollie}prestashop>mollie_961f2247a2070bedff9f9cd8d64e2650'] = 'Kiezen'; -$_MODULE['<{mollie}prestashop>mollie_ea4788705e6873b424c65e91c2846b19'] = 'Annuleren'; -$_MODULE['<{mollie}prestashop>mollie_f93bd0f858a6e5f70cb458c90a36172b'] = 'Niet gelukt om informatie te vinden over de meest recente release'; -$_MODULE['<{mollie}prestashop>mollie_ced93781bca50eb4d970ea51abcc622c'] = 'U gebruikt al de meest recente versie!'; -$_MODULE['<{mollie}prestashop>mollie_43f3c5a157c67de9b6faf42b637f963a'] = 'Het zip-bestand van de module kon niet worden gedownload'; -$_MODULE['<{mollie}prestashop>mollie_31dd57eea0f762b4ea6f022b40acc390'] = 'Er is een fout opgetreden bij het uitpakken van de nieuwe module (bestand kan beschadigd zijn).'; -$_MODULE['<{mollie}prestashop>mollie_bad5a3ab102f6e9c27edd494d7e33323'] = 'Het is gelukt om uw nieuwe Mollie-account aan te maken. Bekijk uw e-mailinbox voor meer informatie.'; -$_MODULE['<{mollie}prestashop>mollie_023b7ade110944180153fd73358fc50c'] = 'Er is een onbekende fout opgetreden tijdens het aanmaken van uw account.'; -$_MODULE['<{mollie}prestashop>mollie_88183b946cc5f0e8c96b2e66e1c74a7e'] = 'Onbekend'; -$_MODULE['<{mollie}prestashop>mollie_301b87d33063f687d14004a9014f6759'] = 'U heeft geen toestemming een terugbetaling te verrichten'; -$_MODULE['<{mollie}prestashop>mollie_8dc6945fb6b59aea38df7935cf3afb6d'] = 'U heeft geen toestemming om betalingen te %s'; -$_MODULE['<{mollie}prestashop>mollie_1bda80f2be4d3658e0baa43fbe7ae8c1'] = 'bekijk'; -$_MODULE['<{mollie}prestashop>mollie_de95b43bceeb4b998aed4aed5cef1ae7'] = 'aanpassen'; -$_MODULE['<{mollie}prestashop>mollie_2a3f1166b041928019e4e8718d628665'] = 'verzend'; -$_MODULE['<{mollie}prestashop>mollie_df6f85687a0d5820baa1a069a04eff2d'] = 'terugbetalen'; -$_MODULE['<{mollie}prestashop>mollie_10aec35353f9c4096a71c38654c3d402'] = 'annuleren'; -$_MODULE['<{mollie}prestashop>payment_c2f73af3130be4b4967a475ab846c546'] = 'Er is een fout opgetreden bij uw betaling. Neem a.u.b. contact op met de klantenservice.'; -$_MODULE['<{mollie}prestashop>download_update_6de6a882c42b757cd027830399a74de4'] = 'Werk de module bij'; -$_MODULE['<{mollie}prestashop>download_update_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Er is een fout opgetreden'; -$_MODULE['<{mollie}prestashop>download_update_5d04a002ea59c8114f9d08b0c6250a3b'] = 'Niet gelukt om te verbinden'; -$_MODULE['<{mollie}prestashop>download_update_3844b140df977eee8639de6d1de9e1e0'] = 'Niet gelukt om de update uit te pakken'; -$_MODULE['<{mollie}prestashop>download_update_b50ec141b028d5a8acec4a17c32f3808'] = 'De module is bijgewerkt!'; -$_MODULE['<{mollie}prestashop>new_release_b7f73af7318580996a3889353b282827'] = 'U gebruikt momenteel versie %s. Wij raden u met klem aan om te upgraden naar versie %s!'; -$_MODULE['<{mollie}prestashop>form_93cba07454f06a4a960172bbd6e2a435'] = 'Ja'; -$_MODULE['<{mollie}prestashop>form_bafd7322c6e97d25b6299b5d6fe8920b'] = 'Nee'; -$_MODULE['<{mollie}prestashop>form_2d25c72c1b18e562f6654fff8e11711e'] = 'Niet beschikbaar'; -$_MODULE['<{mollie}prestashop>form_58afe6389d8f42880d1011ef0de542a2'] = 'Deze betaalmethode is niet beschikbaar in de Payments API. Schakel de Orders API in om deze betaalmethode te activeren.'; -$_MODULE['<{mollie}prestashop>form_9b6a88a9d4a44740f87b1ffa7cb070c4'] = 'Kan de betaalmethodes niet laden'; -$_MODULE['<{mollie}prestashop>form_6327b4e59f58137083214a1fec358855'] = 'Opnieuw proberen'; -$_MODULE['<{mollie}prestashop>form_49ee3087348e8d44e1feda1917443987'] = 'Naam'; -$_MODULE['<{mollie}prestashop>form_b33f1d112cd9d2d32d37cb4cc9a340c8'] = 'Bron URL'; -$_MODULE['<{mollie}prestashop>form_de28ef21a06f3978c05f3d808b15eaab'] = 'Vervoerder URL'; -$_MODULE['<{mollie}prestashop>form_812a48ba719daeda82e4da8e812d426c'] = 'Custom URL'; -$_MODULE['<{mollie}prestashop>form_e55f75a29310d7b60f7ac1d390c8ae42'] = 'Module'; -$_MODULE['<{mollie}prestashop>form_962b59a5f12eabd9c05f11b5f0aada85'] = 'Niet automatisch verzenden'; -$_MODULE['<{mollie}prestashop>form_703490ffd308d337cd5aac50567e9670'] = 'Geen tracking informatie'; -$_MODULE['<{mollie}prestashop>form_f421a366f70bd2aa1193eeb5a2990546'] = 'U kunt hier configureren welke informatie inzake de verzending aan Mollie wordt verzonden'; -$_MODULE['<{mollie}prestashop>form_53b2566e3519ea98db40ae9e716883a5'] = 'U kunt de volgende variabelen gebruiken voor de Vervoerder URLs'; -$_MODULE['<{mollie}prestashop>form_910d956cb2615e5739ac06c7f08fba26'] = 'Verzending nummer'; -$_MODULE['<{mollie}prestashop>form_e7e862a02819a1610f271ffea15ed47d'] = 'Landcode inzake facturatie'; -$_MODULE['<{mollie}prestashop>form_5723a18d8a8a6052a57489df5be59a8f'] = 'Postcode inzake facturatie'; -$_MODULE['<{mollie}prestashop>form_0d12e3c554976ad1f76c5db2b6c127ad'] = 'Landcode inzake verzending'; -$_MODULE['<{mollie}prestashop>form_c824a8b18f09dc7e58bacf446be6735c'] = 'Postcode inzake verzending'; -$_MODULE['<{mollie}prestashop>form_0a867177f4a701a9f33de5ab21c42593'] = '2- letterige taal code'; -$_MODULE['<{mollie}prestashop>form_f6fcb64e21455abc4209f8f4440d45f5'] = 'Lijst met vervoerders kan niet geladen worden'; -$_MODULE['<{mollie}prestashop>form_da93de158db2fbe49f35f6038711584a'] = 'Deze optie is niet beschikbaar voor de API die momenteel is geselecteerd'; -$_MODULE['<{mollie}prestashop>error_c453a4b8e8d98e82f35b67f433e3b4da'] = 'Betaling'; -$_MODULE['<{mollie}prestashop>error_1e97d97a923eaddd810e056c828e99ea'] = 'Betalingsfout'; -$_MODULE['<{mollie}prestashop>error_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Er is een fout opgetreden'; -$_MODULE['<{mollie}prestashop>error_47e1924c444fafe9fdfce444790f0ba9'] = 'Terug naar uw winkelwagen'; -$_MODULE['<{mollie}prestashop>mollie_issuers_588540a38eeba525f3598b68e6b788e5'] = 'of kies een andere betaalmethode'; -$_MODULE['<{mollie}prestashop>mollie_return_ebdf0f490b617d7efa3025d3625cec85'] = 'Welkom terug'; -$_MODULE['<{mollie}prestashop>mollie_return_300225ee958b6350abc51805dab83c24'] = 'Doorgaan met winkelen'; -$_MODULE['<{mollie}prestashop>qr_done_92816c7248d010591f699db3aaf6287b'] = 'Mollie iDEAL-QR'; -$_MODULE['<{mollie}prestashop>qr_done_ebdf0f490b617d7efa3025d3625cec85'] = 'Welkom terug'; -$_MODULE['<{mollie}prestashop>qr_done_4bf3a07ce980c9b007f9e2eed42d7fa2'] = 'De betaling is geannuleerd.'; -$_MODULE['<{mollie}prestashop>qr_done_6933c118341d8c06f888c392aa1ceaf5'] = 'De betaling is voltooid. Bedankt voor uw bestelling!'; -$_MODULE['<{mollie}prestashop>ideal_dropdown_ab4147235204a436c09e00d6722082ab'] = 'Kies een bank'; -$_MODULE['<{mollie}prestashop>order_info_729a51874fe901b092899e9e8b31c97a'] = 'Weet u dit zeker?'; -$_MODULE['<{mollie}prestashop>order_info_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Weet u zeker dat u deze bestelling wilt terugbetalen?'; -$_MODULE['<{mollie}prestashop>order_info_76f0ed934de85cc7131910b32ede7714'] = 'Terugbetalen'; -$_MODULE['<{mollie}prestashop>order_info_ea4788705e6873b424c65e91c2846b19'] = 'Annuleren'; -$_MODULE['<{mollie}prestashop>order_info_88ba0dcbc82905637e98317e0302cfd8'] = 'Bestelling terugbetalen'; -$_MODULE['<{mollie}prestashop>order_info_5a1119ecb764165f27cb37b6f50134f2'] = 'Resterend'; -$_MODULE['<{mollie}prestashop>order_info_77fd2b4393b379bedd30efcd5df02090'] = 'Gedeeltelijke terugbetaling'; -$_MODULE['<{mollie}prestashop>order_info_a9ced76f2dd6907220fa95b3a136b04a'] = 'Ongeldig bedrag'; -$_MODULE['<{mollie}prestashop>order_info_3a2c3e97fed586776c2800fb7a0faf4e'] = 'U heeft een ongeldig bedrag ingevuld'; -$_MODULE['<{mollie}prestashop>order_info_3cc4859e502556d0d848c3bc38618782'] = 'Terugbetaling mislukt'; -$_MODULE['<{mollie}prestashop>order_info_d5cfd0f69cd548e5d3b9edde5ff1b48f'] = 'Betaal informatie'; -$_MODULE['<{mollie}prestashop>order_info_88427ec035734b45aae9f7d8859a5008'] = 'Transactie ID'; -$_MODULE['<{mollie}prestashop>order_info_782678f4ba02feb3e9ecd51e902cd16b'] = 'Terugbetaling geschiedenis'; -$_MODULE['<{mollie}prestashop>order_info_c5b41ae59bd6585750f536615a6bc20b'] = 'Er zijn geen terugbetalingen'; -$_MODULE['<{mollie}prestashop>order_info_b718adec73e04ce3ec720dd11a06a308'] = 'ID'; -$_MODULE['<{mollie}prestashop>order_info_44749712dbec183e983dcd78a7736c41'] = 'Datum'; -$_MODULE['<{mollie}prestashop>order_info_b2f40690858b404ed10e62bdf422c704'] = 'Bedrag'; -$_MODULE['<{mollie}prestashop>order_info_53beb26d8bca00f56fbd295fdee83459'] = 'Terugbetalingen'; -$_MODULE['<{mollie}prestashop>order_info_daef64964ee3b9b904f5d467586e217f'] = 'Betalingen'; -$_MODULE['<{mollie}prestashop>order_info_e25be354288565757726f3295e4f3ef9'] = 'Huidig bedrag'; -$_MODULE['<{mollie}prestashop>order_info_068f80c7519d0528fb08e82137a72131'] = 'Producten'; -$_MODULE['<{mollie}prestashop>order_info_ec53a8c4f07baed5d8825072c89799be'] = 'Status'; -$_MODULE['<{mollie}prestashop>order_info_747cf5c8587184b9e489ff897d97c20d'] = 'Verzonden'; -$_MODULE['<{mollie}prestashop>order_info_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Geannuleerd'; -$_MODULE['<{mollie}prestashop>order_info_cc61945cbbf46721a053467c395c666f'] = 'Terugbetaald'; -$_MODULE['<{mollie}prestashop>order_info_197101c4a1b1fc503dcd6ebee127aa10'] = 'Eenheidsprijs'; -$_MODULE['<{mollie}prestashop>order_info_11cd653a2488e260a8a99f39cdffa6e7'] = 'BTW Bedrag'; -$_MODULE['<{mollie}prestashop>order_info_bc30768048a7bbfd2d158d722c140c6d'] = 'Totaalbedrag'; -$_MODULE['<{mollie}prestashop>order_info_0387832795db3eb2e05f4365fba5ddac'] = 'Verzenden'; -$_MODULE['<{mollie}prestashop>order_info_55453aad10c96e452556a106447313bd'] = 'Verzending bekijken'; -$_MODULE['<{mollie}prestashop>order_info_dbb5bbb116e16973136b9ebd887eaadd'] = 'Bekijk de producten die bij uw zending zijn inbegrepen. U kunt items verwijderen of de hoeveelheid wijzigen indien nodig.'; -$_MODULE['<{mollie}prestashop>order_info_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; -$_MODULE['<{mollie}prestashop>order_info_163bcc6065b16c6369c7a4de44cff164'] = 'Producten verzenden'; -$_MODULE['<{mollie}prestashop>order_info_433557a938a920888445ce2c7df67d5a'] = 'Tracking details'; -$_MODULE['<{mollie}prestashop>order_info_61995a579a6166642e759450a694642b'] = 'Het is raadzaam om tracking informatie aan uw zending toe te voegen, omdat u kunt bewijzen dat u uw producten daadwerkelijk naar uw klant hebt verzonden.'; -$_MODULE['<{mollie}prestashop>order_info_26b6254fefc06894825a50dfbe803937'] = 'Sla tracking toevoegen over'; -$_MODULE['<{mollie}prestashop>order_info_d57c24f3fe52d16e7169b912dd647f0d'] = 'optioneel'; -$_MODULE['<{mollie}prestashop>order_info_2df417909bda5f3ddc210a0abe65231f'] = 'Bijv. PostNL'; -$_MODULE['<{mollie}prestashop>order_info_593ed3a37aa1a3ece4a4d796fb4e2e03'] = 'Deze informatie is verplicht'; -$_MODULE['<{mollie}prestashop>order_info_933292561b46133ff5348c7740874c56'] = 'Tracking code'; -$_MODULE['<{mollie}prestashop>order_info_e6b391a8d2c4d45902a23a8b6585703d'] = 'URL'; -$_MODULE['<{mollie}prestashop>order_info_914419aa32f04011357d3b604a86d7eb'] = 'Vervoerder'; -$_MODULE['<{mollie}prestashop>order_info_23a902ac637359fe67ceaccbe2c68283'] = 'Verzend alles'; -$_MODULE['<{mollie}prestashop>order_info_2a6e9f678c7267fe16f57bcd3285f1d7'] = 'Annuleer alles'; -$_MODULE['<{mollie}prestashop>order_info_05ced64413f9ff5d3602c3e257f36204'] = 'Betaal alles terug'; -$_MODULE['<{mollie}prestashop>order_info_bfe005bff7ecacd6ecceacdd7fb79292'] = 'Transactie info'; -$_MODULE['<{mollie}prestashop>order_info_1eefa98a18a384699fe611fbfd8ab0c9'] = 'Er zijn geen producten'; -$_MODULE['<{mollie}prestashop>order_info_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Er is een fout opgetreden'; -$_MODULE['<{mollie}prestashop>order_info_2df3102f3fe061003dee820a72e1b1ed'] = 'Verzending niet mogelijk'; -$_MODULE['<{mollie}prestashop>order_info_3efc29552025b4e68de04f415b0b8806'] = 'Terugbetaling niet mogelijk'; -$_MODULE['<{mollie}prestashop>order_info_468a92810b526750be9664461db6bf91'] = 'Annuleren niet mogelijk'; -$_MODULE['<{mollie}prestashop>qr_code_9ba19ddbcfeddfc758eb84fb8ba26b5e'] = 'of scan de QR-code'; -$_MODULE['<{mollie}prestashop>refund_729a51874fe901b092899e9e8b31c97a'] = 'Weet u dit zeker?'; -$_MODULE['<{mollie}prestashop>refund_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Weet u zeker dat u deze order wilt terugbetalen?'; -$_MODULE['<{mollie}prestashop>refund_76f0ed934de85cc7131910b32ede7714'] = 'Terugbetalen'; -$_MODULE['<{mollie}prestashop>refund_ea4788705e6873b424c65e91c2846b19'] = 'Annuleren'; -$_MODULE['<{mollie}prestashop>mollie_484f5a79672cebe198ebdde45a1d672f'] = 'Cadeaupapier'; -$_MODULE['<{mollie}prestashop>mollie_e0010a0a1a3259ab5c06a19bad532851'] = 'Betaald'; -$_MODULE['<{mollie}prestashop>mollie_a206428462686af481cb072b8db11784'] = 'Geautoriseerd'; -$_MODULE['<{mollie}prestashop>mollie_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Geannuleerd'; -$_MODULE['<{mollie}prestashop>mollie_24fe48030f7d3097d5882535b04c3fa8'] = 'Verlopen'; -$_MODULE['<{mollie}prestashop>mollie_cc61945cbbf46721a053467c395c666f'] = 'Terugbetaald'; -$_MODULE['<{mollie}prestashop>mollie_7026e386bdad92fa6f232394f5b23ffb'] = 'Wachten op overboeking'; -$_MODULE['<{mollie}prestashop>mollie_9f004157e4c148dac71da3ae5906351f'] = 'Gedeeltelijk terugbetaald'; -$_MODULE['<{mollie}prestashop>mollie_0eceeb45861f9585dd7a97a3e36f85c6'] = 'Aangemaakt'; -$_MODULE['<{mollie}prestashop>mollie_ea9cf7e47ff33b2be14e6dd07cbcefc6'] = 'Verzending'; -$_MODULE['<{mollie}prestashop>mollie_3a6e70059673992f825826f7cf89278d'] = 'De winkelwagenregel met de naam "%1s" (ID %2s) die gebruikt wordt in deze winkelwagen is niet geldig en is uit de winkelwagen verwijderd'; -$_MODULE['<{mollie}prestashop>mollie_3a1048f8aa3a9f6b604fcf7982811752'] = 'Waarschuwing: de secure key is leeg, controleer de betaling'; -$_MODULE['<{mollie}prestashop>mollie_26beb437d3323bd4bfb0811b3e891315'] = '%d afbeelding(en)'; -$_MODULE['<{mollie}prestashop>mollie_0791970c961c09eb8caaa61aba6a3ca4'] = 'Er is een fout opgetreden bij het opslaan van het bericht'; -$_MODULE['<{mollie}prestashop>mollie_ed13b3693357ebed3751cb71cb639e65'] = 'Geen vervoerder'; -$_MODULE['<{mollie}prestashop>mollie_b08d3867be98e6fff3233cd40ab8134a'] = 'Niet gelukt om bestelling aan te maken'; -$_MODULE['<{mollie}prestashop>mollie_43423b4056880b08f2c9aa50d8670531'] = 'Winkelwagen kan niet geladen worden of een bestelling is al geplaatst met deze winkelwagen'; -$_MODULE['<{mollie}prestashop>mollie_32c86f9a2a28a9fa544b97024393633e'] = 'Geen betaalmethoden gevonden'; -$_MODULE['<{mollie}prestashop>form_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Fout'; -$_MODULE['<{mollie}prestashop>17_error_47e1924c444fafe9fdfce444790f0ba9'] = 'Terug naar uw winkelwagen'; -$_MODULE['<{mollie}prestashop>mollie_wait_bc0dd919f9a70dbb62f3f7afd68d6d68'] = 'Wachten op betaalstatus'; -$_MODULE['<{mollie}prestashop>order_info_2427b479f15af44582dc151ef95a90d0'] = 'Terugbetalingen zijn momenteel niet mogelijk'; -$_MODULE['<{mollie}prestashop>rounding_error_7783c757cd1177e60888080e0f4e0593'] = 'De configuratieoptie "%s" heeft een ongeldige waarde'; -$_MODULE['<{mollie}prestashop>rounding_error_2279522d0910767ffa75e0b39ed1629f'] = 'De geselecteerde afrondingsmethode wordt niet ondersteund door de Mollie Orders API'; -$_MODULE['<{mollie}prestashop>rounding_error_3a92c96baa86286685b233e6912e718d'] = 'Navigeer naar de pagina "%s" en kies de optie "%s"'; -$_MODULE['<{mollie}prestashop>smarty_error_9d1fbbe0d150b89f068ba72a20366659'] = 'De configuratiepagina "%s" is op "%s" gezet'; -$_MODULE['<{mollie}prestashop>smarty_error_27dd3bb10855eb84f48efedf6924c4c1'] = 'Hierdoor is het niet mogelijk om betaalmethoden op de checkout weer te geven'; -$_MODULE['<{mollie}prestashop>smarty_error_4ec23c59d832a2934277a2a040918789'] = 'Navigeer naar de pagian "%s" en kies één van de andere opties'; -$_MODULE['<{mollie}prestashop>smarty_error_92b67311c1a5d6cfc28ba08a1066c901'] = ' Afterwards, clear the cache one more time, so the payment method list can be refreshed'; -$_MODULE['<{mollie}prestashop>smarty_warning_9d1fbbe0d150b89f068ba72a20366659'] = 'De configuratieoptie "%s" is op "%s" gezet'; -$_MODULE['<{mollie}prestashop>smarty_warning_e7e747f9c74f0b8222c87db24d34f018'] = 'Het is mogelijk dat niet alle betaalmethoden worden weergegeven op de checkout'; -$_MODULE['<{mollie}prestashop>smarty_warning_1238db0fb782f758b5a54d6333b3610e'] = 'Om dit probleem te verhelpen, navigeer naar de pagina "%s" en leeg de cache handmatig of kies één van de andere opties'; +mollie_09748ce33c8a71296b20ba8c3bd1d13e'] = 'Mollie Payment Module'; +$_MODULE['<{mollie}prestashop>mollie_95b3b272e06dcc3cc2aa62f6887aebc5'] = 'Mollie Betalingen'; +$_MODULE['<{mollie}prestashop>mollie_48dedcf43487615c84c1bbbf6fe76c76'] = 'Weet u zeker dat u de installatie van de Mollie Payment Module ongedaan wilt maken?'; +$_MODULE['<{mollie}prestashop>mollie_ab552f085567bbe63872c10a3596cd27'] = 'Betaalfout:'; +$_MODULE['<{mollie}prestashop>mollie_76e084771e78c194efd0e2d5b8920bea'] = 'betaald'; +$_MODULE['<{mollie}prestashop>mollie_f7d543c9b824323b84ab11668002f207'] = 'geautoriseerd'; +$_MODULE['<{mollie}prestashop>mollie_d5c39a1d9aced393f835f334a1fb9206'] = 'geannuleerd'; +$_MODULE['<{mollie}prestashop>mollie_c4bfb2a0bab0e91bc7dcfbe3bbec246e'] = 'verlopen'; +$_MODULE['<{mollie}prestashop>mollie_ad32204fca182b862a5f97a5534c03a2'] = 'terugbetaald'; +$_MODULE['<{mollie}prestashop>mollie_542ba101e183aea6bc8dab5b1ec5ef7f'] = 'open'; +$_MODULE['<{mollie}prestashop>mollie_837cbb7173db2e32b3783e87597dac90'] = 'gedeeltelijk terugbetaald'; +$_MODULE['<{mollie}prestashop>mollie_e2b7dec8fa4b498156dfee6e4c84b156'] = 'Deze betaalmethode is niet beschikbaar'; +$_MODULE['<{mollie}prestashop>mollie_96d0e2862e0167af0c2fd0c99fe6bc5d'] = 'Klik hier om verder te gaan'; +$_MODULE['<{mollie}prestashop>mollie_540d9939d1ca9406e215ee3d78c76813'] = 'Deze betaalmethode is alleen beschikbaar voor euro\'s.'; +$_MODULE['<{mollie}prestashop>mollie_1b2631119333d97dbda37f87e378b1e4'] = 'Er is een probleem opgetreden bij het verwerken van dit betaalverzoek:'; +$_MODULE['<{mollie}prestashop>mollie_11bab828edcc0a6d5c97cbf84d61e652'] = 'De bestelling met dit id kon niet gevonden worden.'; +$_MODULE['<{mollie}prestashop>mollie_b34487c5f391f47b893ee3c61f8f9ab7'] = 'Er is nog geen definitieve betaalstatus bekend. U wordt op de hoogte gesteld zodra de bank de status doorgeeft.'; +$_MODULE['<{mollie}prestashop>mollie_57bc999b3b730ead92ac7243fe254a2a'] = 'Helaas is uw betaling verlopen.'; +$_MODULE['<{mollie}prestashop>mollie_3602f6d5ece34fdbd4ffe0a47f1a2ba4'] = 'Dank u wel, uw betaling is ontvangen.'; +$_MODULE['<{mollie}prestashop>mollie_7352a401b3c23b2966c68bc9ab97fa06'] = 'De transactie heeft een onverwachte status.'; +$_MODULE['<{mollie}prestashop>mollie_3f83176ddc3f63a5a374a623840bfb09'] = 'U hebt geen toegang tot deze pagina.'; +$_MODULE['<{mollie}prestashop>mollie_300225ee958b6350abc51805dab83c24'] = 'Doorgaan met winkelen'; +$_MODULE['<{mollie}prestashop>mollie_ebdf0f490b617d7efa3025d3625cec85'] = 'Welkom terug'; +$_MODULE['<{mollie}prestashop>mollie_66dac2278292ff24611ef8a85bc94e0d'] = 'Kies uw bank:'; +$_MODULE['<{mollie}prestashop>mollie_e0aa021e21dddbd6d8cecec71e9cf564'] = 'Oke'; +$_MODULE['<{mollie}prestashop>mollie_b98a07c82f0078a1de7fc219fae480fc'] = 'Andere betaalmethode'; +$_MODULE['<{mollie}prestashop>mollie_35895cff7df70dab18783453e2bd241f'] = 'Betalen via %s'; +$_MODULE['<{mollie}prestashop>mollie_cc16e103e202a48009df202d9525f75f'] = 'Bestelling terugbetalen'; +$_MODULE['<{mollie}prestashop>mollie_c5222afef6530f674d3acf82ba2ce9dc'] = 'Mollie Terugbetalingen'; +$_MODULE['<{mollie}prestashop>mollie_7064b25aa8a732a3db7f230c9867be19'] = 'Betaal bestelling #%d volledig terugbetalen via de Mollie API'; +$_MODULE['<{mollie}prestashop>mollie_e12682d2e0650f2783b22d956d2b947a'] = 'Deze bestelling is terugbetaald!'; +$_MODULE['<{mollie}prestashop>mollie_95be87afb2734075cf345b633e1384ec'] = 'Mollie B.V. boekt het bedrag de volgende werkdag terug naar uw klant.'; +$_MODULE['<{mollie}prestashop>mollie_9770d1f0124abb0d6a894cd79f8703b5'] = 'Wachten op betaling Mollie'; +$_MODULE['<{mollie}prestashop>mollie_b9fc80a6e775cb75568db6b6538dacdd'] = 'Mollie Gedeeltelijke Terugbetaling'; +$_MODULE['<{mollie}prestashop>mollie_f91ab041fe9d6057740394b8b7903a0f'] = 'iDEAL'; +$_MODULE['<{mollie}prestashop>mollie_b749cfb52bfd82c5b12aa49d6906b8e8'] = 'CartaSi'; +$_MODULE['<{mollie}prestashop>mollie_05bfde942b997737b56b9ab405450076'] = 'Cartes Bancaires'; +$_MODULE['<{mollie}prestashop>mollie_e7f9e382dc50889098cbe56f2554c77b'] = 'Credit card'; +$_MODULE['<{mollie}prestashop>mollie_870cf6bc77bbadd038aeb8d942c9cb18'] = 'Bancontact'; +$_MODULE['<{mollie}prestashop>mollie_8ad65eb3da9995173280649f090218c3'] = 'SOFORT Banking'; +$_MODULE['<{mollie}prestashop>mollie_c0db4214f9d7e1b846f4496e03e667d0'] = 'SEPA Direct Debit'; +$_MODULE['<{mollie}prestashop>mollie_5aa515ce21e8de1ed7416dce455a151f'] = 'Belfius Pay Button'; +$_MODULE['<{mollie}prestashop>mollie_d023ec040f79f1a9b2ac960b43785089'] = 'Bitcoin'; +$_MODULE['<{mollie}prestashop>mollie_4aa65ea89e54d83bb2604c2cc89babc3'] = 'PODIUM Cadeaukaart'; +$_MODULE['<{mollie}prestashop>mollie_58c25c4b8b4382e37d89e0ef6bd625cf'] = 'Gift cards'; +$_MODULE['<{mollie}prestashop>mollie_431647a0a8b2cd589c9fda9535f90d6d'] = 'Overboeking'; +$_MODULE['<{mollie}prestashop>mollie_ad69e733ebae8d264bccaa38d68830e8'] = 'PayPal'; +$_MODULE['<{mollie}prestashop>mollie_6abcd8eecb4f2abb6ccfe36ef7046ba0'] = 'paysafecard'; +$_MODULE['<{mollie}prestashop>mollie_a81bd6195f1abce35fd03a870270100b'] = 'KBC/CBC Payment Button'; +$_MODULE['<{mollie}prestashop>mollie_8184c64d6318b4a42428ae21d0fe2311'] = 'ING Home\'Pay'; +$_MODULE['<{mollie}prestashop>mollie_31911306551723245e7417ae4520fecb'] = 'Giropay'; +$_MODULE['<{mollie}prestashop>mollie_ce8e4a184e2e534c09d6bf6ae773ca4a'] = 'eps'; +$_MODULE['<{mollie}prestashop>mollie_feb1a8ded87483b416427b8457bdc664'] = 'Klarna: Achteraf betalen'; +$_MODULE['<{mollie}prestashop>mollie_a388a6fba0d4b58c334cd9416071cdb1'] = 'Klarna: Gespreid betalen'; +$_MODULE['<{mollie}prestashop>mollie_d1913efa9eae51595a33f3c1410d465c'] = 'De methode %s is overschreven door de %s module. Dit kan problemen veroorzaken wanneer men betalingen verricht.'; +$_MODULE['<{mollie}prestashop>mollie_6311eb29dee3acc14071e0b1efb173f5'] = 'Status \"%s\":'; +$_MODULE['<{mollie}prestashop>mollie_d438a1d96c6037fccad15d7594737a84'] = 'Visuele instellingen:'; +$_MODULE['<{mollie}prestashop>mollie_49259add73e416838e985a6bf4d0e571'] = 'Debug informatie:'; +$_MODULE['<{mollie}prestashop>mollie_c9cc8cce247e49bae79f15173ce97354'] = 'Opslaan'; +$_MODULE['<{mollie}prestashop>mollie_5bef23eb7efff2736c5583bda59e5eb7'] = 'Maak uw account aan'; +$_MODULE['<{mollie}prestashop>mollie_a77e6fc49f07414fc53336c8d879b73e'] = 'Heeft u al een account? Dan kunt u deze stap overslaan en uw API-key invoeren.'; +$_MODULE['<{mollie}prestashop>mollie_21aef67e8d12503aff027385d0a7867f'] = 'Voor- en achternaam'; +$_MODULE['<{mollie}prestashop>mollie_b357b524e740bc85b9790a0712d84a30'] = 'E-mailadres'; +$_MODULE['<{mollie}prestashop>mollie_e93c33bd1341ab74195430daeb63db13'] = 'Winkelnaam'; +$_MODULE['<{mollie}prestashop>mollie_dd7bf230fde8d4836917806aff6a6b27'] = 'Adres'; +$_MODULE['<{mollie}prestashop>mollie_8bcdc441379cbf584638b0589a3f9adb'] = 'Postcode'; +$_MODULE['<{mollie}prestashop>mollie_57d056ed0984166336b7879c2af3657f'] = 'Stad'; +$_MODULE['<{mollie}prestashop>mollie_59716c97497eb9694541f7c3d37b1a4d'] = 'Land'; +$_MODULE['<{mollie}prestashop>mollie_686e697538050e4664636337cc3b834f'] = 'Account aanmaken'; +$_MODULE['<{mollie}prestashop>mollie_7c4e7ada50c8572336f872fced4d1852'] = 'Status voor betaling %s'; +$_MODULE['<{mollie}prestashop>mollie_bea3fae02ae079e541199ab6ffc2d1ad'] = '`%s` betalingen krijgen de status `%s`'; +$_MODULE['<{mollie}prestashop>mollie_b2a2c5a69af7c04c5adc48261fb5dc13'] = 'Verzend mail bij %s'; +$_MODULE['<{mollie}prestashop>mollie_0511c3431d4e32ed4266fe943014d000'] = 'Verstuur een email als de status in %s verandert?'; +$_MODULE['<{mollie}prestashop>mollie_7aace0dc23ee8b74744bdf79c98a2605'] = 'Sla deze status over'; +$_MODULE['<{mollie}prestashop>mollie_dd59e3663865f3fab190e496260608e6'] = '`%s` betalingen krijgen geen status'; +$_MODULE['<{mollie}prestashop>mollie_824f2c1d1c2ee9aecac9977d9347a2ea'] = 'Mollie instellingen'; +$_MODULE['<{mollie}prestashop>mollie_d876ff8da67c3731ae25d8335a4168b4'] = 'API Key'; +$_MODULE['<{mollie}prestashop>mollie_2ffbc7eb8899865f9e66682d34853195'] = 'U vindt uw API Sleutel in uw [1]Mollie Profiel[/1]; de sleutel begint met test_ of live_.'; +$_MODULE['<{mollie}prestashop>mollie_b5a7adde1af5c87d7fd797b6245c2a39'] = 'Omschrijving'; +$_MODULE['<{mollie}prestashop>mollie_3150652ab7f22bafe11a78d4cc0de8be'] = 'Voer hier een omschrijving in. Let op: betaalmethoden kunnen een tekenlimiet bevatten, houd de beschrijving onder de 29 tekens. U kunt de volgende variabelen gebruiken: %s'; +$_MODULE['<{mollie}prestashop>mollie_8d9143dfc520ed7d982d4e545c7bfc5e'] = 'Stuur locale voor betaalscherm'; +$_MODULE['<{mollie}prestashop>mollie_1239c091f39c068882e924e34dd9cc40'] = 'Moet de plugin de [1]locale[/1] van uw webshop sturen? Het betaalscherm zal dan in dezelfde taal als uw website worden weergegeven. Standaard zal Mollie de taal detecteren aan de hand van de browser taal.'; +$_MODULE['<{mollie}prestashop>mollie_80a78bb16945665b6410ae8d93e81c69'] = 'Stuur geen locale, gebruik browser taal'; +$_MODULE['<{mollie}prestashop>mollie_3ba67aae5d08d0fa90016685407926f1'] = 'Visuele instellingen'; +$_MODULE['<{mollie}prestashop>mollie_fff0d600f8a0b5e19e88bfb821dd1157'] = 'Afbeeldingen'; +$_MODULE['<{mollie}prestashop>mollie_f7a97136df639501521efb243047e0cf'] = 'Laat grote, normale of geen logo zien van betaalmethodes op de afrekenpagina'; +$_MODULE['<{mollie}prestashop>mollie_a88f05b6c963e145a45b58c47cd42a41'] = 'geen'; +$_MODULE['<{mollie}prestashop>mollie_fea087517c26fadd409bd4b9dc642555'] = 'normaal'; +$_MODULE['<{mollie}prestashop>mollie_d861877da56b8b4ceb35c8cbfdf65bb4'] = 'groot'; +$_MODULE['<{mollie}prestashop>mollie_85fb708f31f585607247f8b868efafcc'] = 'Bankenlijst'; +$_MODULE['<{mollie}prestashop>mollie_27db39558366d2a9001a0dec69eea4d6'] = 'Sommige betaalmethoden (zoals iDEAL) hebben een bankenlijst. Deze instelling bepaalt waar die lijst zichtbaar is.'; +$_MODULE['<{mollie}prestashop>mollie_85a692706bc7597b6e32bc1d354c138f'] = 'Zichtbaar na klikken betaalmethode'; +$_MODULE['<{mollie}prestashop>mollie_ea9b19c6f2e9ef60b49778ab9396b293'] = 'Tonen op aparte pagina'; +$_MODULE['<{mollie}prestashop>mollie_d35acbb07d2841712a937d5748e9bdc2'] = 'Tonen op Mollie betaalpagina'; +$_MODULE['<{mollie}prestashop>mollie_1547ffc579d657d13fd5fedf12cbfae5'] = 'CSS-bestand'; +$_MODULE['<{mollie}prestashop>mollie_6602513644161421f58418528d93ac00'] = 'Laat leeg voor standaardvormgeving. Hint: Gebruik [1]{BASE}[/1], [1]{THEME}[/1], [1]{CSS}[/1], [1]{MOBILE}[/1], [1]{MOBILE_CSS}[/1] en [1]{OVERRIDE}[/1] voor de standaard bestandsmappen.'; +$_MODULE['<{mollie}prestashop>mollie_0da8d9a75492046bea7f314521e07cae'] = 'Betaalmethoden'; +$_MODULE['<{mollie}prestashop>mollie_75886bf821fc9c068a280fe52337c0f5'] = 'Schakel betaalmethoden in of uit. U kunt de betaalmethoden rangschikken door deze te slepen.'; +$_MODULE['<{mollie}prestashop>mollie_c576349bf8ff5fba4e9369ab581a4074'] = 'Mollie iDEAL-QR'; +$_MODULE['<{mollie}prestashop>mollie_c0ae4417e7a196f3ccfadff68a5064ed'] = 'iDEAL QR Code is momenteel nog niet beschikbaar in de Orders API. Onze excuses voor het ongemak.'; +$_MODULE['<{mollie}prestashop>mollie_e17dc77fb83539b6a4687c6d515791e4'] = '%s statussen'; +$_MODULE['<{mollie}prestashop>mollie_b068931cc450442b63f5b3d276ea4297'] = 'naam'; +$_MODULE['<{mollie}prestashop>mollie_4695fd3a22023ab53a2151f797975ff8'] = 'Deze status uitschakelen'; +$_MODULE['<{mollie}prestashop>mollie_656f9fd6f874404599220855cfec17ef'] = 'Mollie API'; +$_MODULE['<{mollie}prestashop>mollie_a1532be2c9ef11d7dd5edd974fc6c98c'] = 'Selecteer de Mollie API die u wilt gebruiken'; +$_MODULE['<{mollie}prestashop>mollie_9ce1d2272c82bfd7d501a6697df774c7'] = 'Moet de plugin de nieuwe Mollie Orders API gebruiken? Hiermee kunt u gebruik maken van betaalmethodes zoals Klarna Pay Later.'; +$_MODULE['<{mollie}prestashop>mollie_8c2b4949d892b39b236545951f10bbd4'] = 'Payments API'; +$_MODULE['<{mollie}prestashop>mollie_a8b0255f70ecc140a1b5134ae5217e51'] = 'Orders API'; +$_MODULE['<{mollie}prestashop>mollie_1191f888f0cc23f95aa77aacb094503b'] = 'Verzending informatie'; +$_MODULE['<{mollie}prestashop>mollie_d822c02513be98814bdd39f8bae598d1'] = 'Automatisch verzenden indien gemarkeerd als verzonden'; +$_MODULE['<{mollie}prestashop>mollie_0eccefc4c96190190add75fe0a74fcd4'] = 'Door deze optie in te schakelen wordt de informatie inzake de verzending automatisch verzonden wanneer de order als \'verzonden\' is gemarkeerd'; +$_MODULE['<{mollie}prestashop>mollie_c1df8a5243557cbd8a7a31c11aab3db4'] = 'Automatisch verzenden indien wanneer de order als een van deze statussen is gemarkeerd'; +$_MODULE['<{mollie}prestashop>mollie_34bd91e87db36a10b9e847d6304be289'] = 'Wanneer de order als een van deze statussen is gemarkeerd wordt de informatie inzake de verzending automatisch verzonden'; +$_MODULE['<{mollie}prestashop>mollie_498f79c4c5bbde77f1bceb6c86fd0f6d'] = 'Openen'; +$_MODULE['<{mollie}prestashop>mollie_62a5e490880a92eef74f167d9dc6dca0'] = 'Sluiten'; +$_MODULE['<{mollie}prestashop>mollie_dc6e4b439165a4e104c9f3cbfcfe2797'] = 'Debug informatie'; +$_MODULE['<{mollie}prestashop>mollie_500aa80d6aea3cc9701b566c5f92ed91'] = 'Foutmeldingen weergeven'; +$_MODULE['<{mollie}prestashop>mollie_37f9a8b20930c1dc7488b15872b6d36b'] = 'Door deze optie aan te zetten worden foutmeldingen op de voorpagina weergegeven. Alleen voor debug!'; +$_MODULE['<{mollie}prestashop>mollie_e5114c4b69585ba5883d456a74c1cd5d'] = 'Log niveau'; +$_MODULE['<{mollie}prestashop>mollie_921a6d905eef99631c9c73c317799e62'] = 'Aangeraden niveau: Errors. Zet op alles om de webhook requests te monitoren. [1]Bekijk logs[/1]'; +$_MODULE['<{mollie}prestashop>mollie_f80a4ad87fee7c9fdc19b7769495fdb5'] = 'Geen'; +$_MODULE['<{mollie}prestashop>mollie_5ef0c737746fae2ca90e66c39333f8f6'] = 'Fouten'; +$_MODULE['<{mollie}prestashop>mollie_709468af25e91284821d1bdbfdded24c'] = 'Alles'; +$_MODULE['<{mollie}prestashop>mollie_7c478959c218087ffc4ad5d96e7f66a6'] = 'Mollie'; +$_MODULE['<{mollie}prestashop>mollie_1f93fc361bfc627c89a46e1b6c28df2b'] = 'De API Sleutel dient met test_ of live_ te beginnen.'; +$_MODULE['<{mollie}prestashop>mollie_6ab1adfed768d989b47c908755fe677f'] = 'De configuratie is opgeslagen!'; +$_MODULE['<{mollie}prestashop>mollie_1f91cd9f380285bf1219c79ab7fcb75e'] = 'Waarschuwing: kon het update-bestand niet ophalen vanaf GitHub'; +$_MODULE['<{mollie}prestashop>mollie_ce1e483d5cd4b349af887fa3e198ea6b'] = 'Geen download package gevonden voor de meest recente release.'; +$_MODULE['<{mollie}prestashop>mollie_048ef1905ff33382d7660a68a6199305'] = 'Waarschuwing: Kon de update XML van github niet ophalen.'; +$_MODULE['<{mollie}prestashop>mollie_711d42f319398490b32cd0e2f0b8ccb8'] = 'Waarschuwing: Het update xml bestand van github volgt een onverwacht formaat.'; +$_MODULE['<{mollie}prestashop>mollie_48fa0f621f79f451e58f200957da5b52'] = 'Kies uw bank'; +$_MODULE['<{mollie}prestashop>mollie_8953fb7da2299bf905b73720f611baa3'] = 'of betaal met iDEAL-QR'; +$_MODULE['<{mollie}prestashop>mollie_961f2247a2070bedff9f9cd8d64e2650'] = 'Kiezen'; +$_MODULE['<{mollie}prestashop>mollie_ea4788705e6873b424c65e91c2846b19'] = 'Annuleren'; +$_MODULE['<{mollie}prestashop>mollie_f93bd0f858a6e5f70cb458c90a36172b'] = 'Niet gelukt om informatie te vinden over de meest recente release'; +$_MODULE['<{mollie}prestashop>mollie_ced93781bca50eb4d970ea51abcc622c'] = 'U gebruikt al de meest recente versie!'; +$_MODULE['<{mollie}prestashop>mollie_43f3c5a157c67de9b6faf42b637f963a'] = 'Het zip-bestand van de module kon niet worden gedownload'; +$_MODULE['<{mollie}prestashop>mollie_31dd57eea0f762b4ea6f022b40acc390'] = 'Er is een fout opgetreden bij het uitpakken van de nieuwe module (bestand kan beschadigd zijn).'; +$_MODULE['<{mollie}prestashop>mollie_bad5a3ab102f6e9c27edd494d7e33323'] = 'Het is gelukt om uw nieuwe Mollie-account aan te maken. Bekijk uw e-mailinbox voor meer informatie.'; +$_MODULE['<{mollie}prestashop>mollie_023b7ade110944180153fd73358fc50c'] = 'Er is een onbekende fout opgetreden tijdens het aanmaken van uw account.'; +$_MODULE['<{mollie}prestashop>mollie_88183b946cc5f0e8c96b2e66e1c74a7e'] = 'Onbekend'; +$_MODULE['<{mollie}prestashop>mollie_301b87d33063f687d14004a9014f6759'] = 'U heeft geen toestemming een terugbetaling te verrichten'; +$_MODULE['<{mollie}prestashop>mollie_8dc6945fb6b59aea38df7935cf3afb6d'] = 'U heeft geen toestemming om betalingen te %s'; +$_MODULE['<{mollie}prestashop>mollie_1bda80f2be4d3658e0baa43fbe7ae8c1'] = 'bekijk'; +$_MODULE['<{mollie}prestashop>mollie_de95b43bceeb4b998aed4aed5cef1ae7'] = 'aanpassen'; +$_MODULE['<{mollie}prestashop>mollie_2a3f1166b041928019e4e8718d628665'] = 'verzend'; +$_MODULE['<{mollie}prestashop>mollie_df6f85687a0d5820baa1a069a04eff2d'] = 'terugbetalen'; +$_MODULE['<{mollie}prestashop>mollie_10aec35353f9c4096a71c38654c3d402'] = 'annuleren'; +$_MODULE['<{mollie}prestashop>payment_c2f73af3130be4b4967a475ab846c546'] = 'Er is een fout opgetreden bij uw betaling. Neem a.u.b. contact op met de klantenservice.'; +$_MODULE['<{mollie}prestashop>download_update_6de6a882c42b757cd027830399a74de4'] = 'Werk de module bij'; +$_MODULE['<{mollie}prestashop>download_update_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Er is een fout opgetreden'; +$_MODULE['<{mollie}prestashop>download_update_5d04a002ea59c8114f9d08b0c6250a3b'] = 'Niet gelukt om te verbinden'; +$_MODULE['<{mollie}prestashop>download_update_3844b140df977eee8639de6d1de9e1e0'] = 'Niet gelukt om de update uit te pakken'; +$_MODULE['<{mollie}prestashop>download_update_b50ec141b028d5a8acec4a17c32f3808'] = 'De module is bijgewerkt!'; +$_MODULE['<{mollie}prestashop>new_release_b7f73af7318580996a3889353b282827'] = 'U gebruikt momenteel versie %s. Wij raden u met klem aan om te upgraden naar versie %s!'; +$_MODULE['<{mollie}prestashop>form_93cba07454f06a4a960172bbd6e2a435'] = 'Ja'; +$_MODULE['<{mollie}prestashop>form_bafd7322c6e97d25b6299b5d6fe8920b'] = 'Nee'; +$_MODULE['<{mollie}prestashop>form_2d25c72c1b18e562f6654fff8e11711e'] = 'Niet beschikbaar'; +$_MODULE['<{mollie}prestashop>form_58afe6389d8f42880d1011ef0de542a2'] = 'Deze betaalmethode is niet beschikbaar in de Payments API. Schakel de Orders API in om deze betaalmethode te activeren.'; +$_MODULE['<{mollie}prestashop>form_9b6a88a9d4a44740f87b1ffa7cb070c4'] = 'Kan de betaalmethodes niet laden'; +$_MODULE['<{mollie}prestashop>form_6327b4e59f58137083214a1fec358855'] = 'Opnieuw proberen'; +$_MODULE['<{mollie}prestashop>form_49ee3087348e8d44e1feda1917443987'] = 'Naam'; +$_MODULE['<{mollie}prestashop>form_b33f1d112cd9d2d32d37cb4cc9a340c8'] = 'Bron URL'; +$_MODULE['<{mollie}prestashop>form_de28ef21a06f3978c05f3d808b15eaab'] = 'Vervoerder URL'; +$_MODULE['<{mollie}prestashop>form_812a48ba719daeda82e4da8e812d426c'] = 'Custom URL'; +$_MODULE['<{mollie}prestashop>form_e55f75a29310d7b60f7ac1d390c8ae42'] = 'Module'; +$_MODULE['<{mollie}prestashop>form_962b59a5f12eabd9c05f11b5f0aada85'] = 'Niet automatisch verzenden'; +$_MODULE['<{mollie}prestashop>form_703490ffd308d337cd5aac50567e9670'] = 'Geen tracking informatie'; +$_MODULE['<{mollie}prestashop>form_f421a366f70bd2aa1193eeb5a2990546'] = 'U kunt hier configureren welke informatie inzake de verzending aan Mollie wordt verzonden'; +$_MODULE['<{mollie}prestashop>form_53b2566e3519ea98db40ae9e716883a5'] = 'U kunt de volgende variabelen gebruiken voor de Vervoerder URLs'; +$_MODULE['<{mollie}prestashop>form_910d956cb2615e5739ac06c7f08fba26'] = 'Verzending nummer'; +$_MODULE['<{mollie}prestashop>form_e7e862a02819a1610f271ffea15ed47d'] = 'Landcode inzake facturatie'; +$_MODULE['<{mollie}prestashop>form_5723a18d8a8a6052a57489df5be59a8f'] = 'Postcode inzake facturatie'; +$_MODULE['<{mollie}prestashop>form_0d12e3c554976ad1f76c5db2b6c127ad'] = 'Landcode inzake verzending'; +$_MODULE['<{mollie}prestashop>form_c824a8b18f09dc7e58bacf446be6735c'] = 'Postcode inzake verzending'; +$_MODULE['<{mollie}prestashop>form_0a867177f4a701a9f33de5ab21c42593'] = '2- letterige taal code'; +$_MODULE['<{mollie}prestashop>form_f6fcb64e21455abc4209f8f4440d45f5'] = 'Lijst met vervoerders kan niet geladen worden'; +$_MODULE['<{mollie}prestashop>form_da93de158db2fbe49f35f6038711584a'] = 'Deze optie is niet beschikbaar voor de API die momenteel is geselecteerd'; +$_MODULE['<{mollie}prestashop>error_c453a4b8e8d98e82f35b67f433e3b4da'] = 'Betaling'; +$_MODULE['<{mollie}prestashop>error_1e97d97a923eaddd810e056c828e99ea'] = 'Betalingsfout'; +$_MODULE['<{mollie}prestashop>error_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Er is een fout opgetreden'; +$_MODULE['<{mollie}prestashop>error_47e1924c444fafe9fdfce444790f0ba9'] = 'Terug naar uw winkelwagen'; +$_MODULE['<{mollie}prestashop>mollie_issuers_588540a38eeba525f3598b68e6b788e5'] = 'of kies een andere betaalmethode'; +$_MODULE['<{mollie}prestashop>mollie_return_ebdf0f490b617d7efa3025d3625cec85'] = 'Welkom terug'; +$_MODULE['<{mollie}prestashop>mollie_return_300225ee958b6350abc51805dab83c24'] = 'Doorgaan met winkelen'; +$_MODULE['<{mollie}prestashop>qr_done_92816c7248d010591f699db3aaf6287b'] = 'Mollie iDEAL-QR'; +$_MODULE['<{mollie}prestashop>qr_done_ebdf0f490b617d7efa3025d3625cec85'] = 'Welkom terug'; +$_MODULE['<{mollie}prestashop>qr_done_4bf3a07ce980c9b007f9e2eed42d7fa2'] = 'De betaling is geannuleerd.'; +$_MODULE['<{mollie}prestashop>qr_done_6933c118341d8c06f888c392aa1ceaf5'] = 'De betaling is voltooid. Bedankt voor uw bestelling!'; +$_MODULE['<{mollie}prestashop>ideal_dropdown_ab4147235204a436c09e00d6722082ab'] = 'Kies een bank'; +$_MODULE['<{mollie}prestashop>order_info_729a51874fe901b092899e9e8b31c97a'] = 'Weet u dit zeker?'; +$_MODULE['<{mollie}prestashop>order_info_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Weet u zeker dat u deze bestelling wilt terugbetalen?'; +$_MODULE['<{mollie}prestashop>order_info_76f0ed934de85cc7131910b32ede7714'] = 'Terugbetalen'; +$_MODULE['<{mollie}prestashop>order_info_ea4788705e6873b424c65e91c2846b19'] = 'Annuleren'; +$_MODULE['<{mollie}prestashop>order_info_88ba0dcbc82905637e98317e0302cfd8'] = 'Bestelling terugbetalen'; +$_MODULE['<{mollie}prestashop>order_info_5a1119ecb764165f27cb37b6f50134f2'] = 'Resterend'; +$_MODULE['<{mollie}prestashop>order_info_77fd2b4393b379bedd30efcd5df02090'] = 'Gedeeltelijke terugbetaling'; +$_MODULE['<{mollie}prestashop>order_info_a9ced76f2dd6907220fa95b3a136b04a'] = 'Ongeldig bedrag'; +$_MODULE['<{mollie}prestashop>order_info_3a2c3e97fed586776c2800fb7a0faf4e'] = 'U heeft een ongeldig bedrag ingevuld'; +$_MODULE['<{mollie}prestashop>order_info_3cc4859e502556d0d848c3bc38618782'] = 'Terugbetaling mislukt'; +$_MODULE['<{mollie}prestashop>order_info_d5cfd0f69cd548e5d3b9edde5ff1b48f'] = 'Betaal informatie'; +$_MODULE['<{mollie}prestashop>order_info_88427ec035734b45aae9f7d8859a5008'] = 'Transactie ID'; +$_MODULE['<{mollie}prestashop>order_info_782678f4ba02feb3e9ecd51e902cd16b'] = 'Terugbetaling geschiedenis'; +$_MODULE['<{mollie}prestashop>order_info_c5b41ae59bd6585750f536615a6bc20b'] = 'Er zijn geen terugbetalingen'; +$_MODULE['<{mollie}prestashop>order_info_b718adec73e04ce3ec720dd11a06a308'] = 'ID'; +$_MODULE['<{mollie}prestashop>order_info_44749712dbec183e983dcd78a7736c41'] = 'Datum'; +$_MODULE['<{mollie}prestashop>order_info_b2f40690858b404ed10e62bdf422c704'] = 'Bedrag'; +$_MODULE['<{mollie}prestashop>order_info_53beb26d8bca00f56fbd295fdee83459'] = 'Terugbetalingen'; +$_MODULE['<{mollie}prestashop>order_info_daef64964ee3b9b904f5d467586e217f'] = 'Betalingen'; +$_MODULE['<{mollie}prestashop>order_info_e25be354288565757726f3295e4f3ef9'] = 'Huidig bedrag'; +$_MODULE['<{mollie}prestashop>order_info_068f80c7519d0528fb08e82137a72131'] = 'Producten'; +$_MODULE['<{mollie}prestashop>order_info_ec53a8c4f07baed5d8825072c89799be'] = 'Status'; +$_MODULE['<{mollie}prestashop>order_info_747cf5c8587184b9e489ff897d97c20d'] = 'Verzonden'; +$_MODULE['<{mollie}prestashop>order_info_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Geannuleerd'; +$_MODULE['<{mollie}prestashop>order_info_cc61945cbbf46721a053467c395c666f'] = 'Terugbetaald'; +$_MODULE['<{mollie}prestashop>order_info_197101c4a1b1fc503dcd6ebee127aa10'] = 'Eenheidsprijs'; +$_MODULE['<{mollie}prestashop>order_info_11cd653a2488e260a8a99f39cdffa6e7'] = 'BTW Bedrag'; +$_MODULE['<{mollie}prestashop>order_info_bc30768048a7bbfd2d158d722c140c6d'] = 'Totaalbedrag'; +$_MODULE['<{mollie}prestashop>order_info_0387832795db3eb2e05f4365fba5ddac'] = 'Verzenden'; +$_MODULE['<{mollie}prestashop>order_info_55453aad10c96e452556a106447313bd'] = 'Verzending bekijken'; +$_MODULE['<{mollie}prestashop>order_info_dbb5bbb116e16973136b9ebd887eaadd'] = 'Bekijk de producten die bij uw zending zijn inbegrepen. U kunt items verwijderen of de hoeveelheid wijzigen indien nodig.'; +$_MODULE['<{mollie}prestashop>order_info_e0aa021e21dddbd6d8cecec71e9cf564'] = 'OK'; +$_MODULE['<{mollie}prestashop>order_info_163bcc6065b16c6369c7a4de44cff164'] = 'Producten verzenden'; +$_MODULE['<{mollie}prestashop>order_info_433557a938a920888445ce2c7df67d5a'] = 'Tracking details'; +$_MODULE['<{mollie}prestashop>order_info_61995a579a6166642e759450a694642b'] = 'Het is raadzaam om tracking informatie aan uw zending toe te voegen, omdat u kunt bewijzen dat u uw producten daadwerkelijk naar uw klant hebt verzonden.'; +$_MODULE['<{mollie}prestashop>order_info_26b6254fefc06894825a50dfbe803937'] = 'Sla tracking toevoegen over'; +$_MODULE['<{mollie}prestashop>order_info_d57c24f3fe52d16e7169b912dd647f0d'] = 'optioneel'; +$_MODULE['<{mollie}prestashop>order_info_2df417909bda5f3ddc210a0abe65231f'] = 'Bijv. PostNL'; +$_MODULE['<{mollie}prestashop>order_info_593ed3a37aa1a3ece4a4d796fb4e2e03'] = 'Deze informatie is verplicht'; +$_MODULE['<{mollie}prestashop>order_info_933292561b46133ff5348c7740874c56'] = 'Tracking code'; +$_MODULE['<{mollie}prestashop>order_info_e6b391a8d2c4d45902a23a8b6585703d'] = 'URL'; +$_MODULE['<{mollie}prestashop>order_info_914419aa32f04011357d3b604a86d7eb'] = 'Vervoerder'; +$_MODULE['<{mollie}prestashop>order_info_23a902ac637359fe67ceaccbe2c68283'] = 'Verzend alles'; +$_MODULE['<{mollie}prestashop>order_info_2a6e9f678c7267fe16f57bcd3285f1d7'] = 'Annuleer alles'; +$_MODULE['<{mollie}prestashop>order_info_05ced64413f9ff5d3602c3e257f36204'] = 'Betaal alles terug'; +$_MODULE['<{mollie}prestashop>order_info_bfe005bff7ecacd6ecceacdd7fb79292'] = 'Transactie info'; +$_MODULE['<{mollie}prestashop>order_info_1eefa98a18a384699fe611fbfd8ab0c9'] = 'Er zijn geen producten'; +$_MODULE['<{mollie}prestashop>order_info_a25c753ee3e4be15ec0daa5a40deb7b8'] = 'Er is een fout opgetreden'; +$_MODULE['<{mollie}prestashop>order_info_2df3102f3fe061003dee820a72e1b1ed'] = 'Verzending niet mogelijk'; +$_MODULE['<{mollie}prestashop>order_info_3efc29552025b4e68de04f415b0b8806'] = 'Terugbetaling niet mogelijk'; +$_MODULE['<{mollie}prestashop>order_info_468a92810b526750be9664461db6bf91'] = 'Annuleren niet mogelijk'; +$_MODULE['<{mollie}prestashop>qr_code_9ba19ddbcfeddfc758eb84fb8ba26b5e'] = 'of scan de QR-code'; +$_MODULE['<{mollie}prestashop>refund_729a51874fe901b092899e9e8b31c97a'] = 'Weet u dit zeker?'; +$_MODULE['<{mollie}prestashop>refund_ccaf4ee393d094ecde7f21b15fdf8f1f'] = 'Weet u zeker dat u deze order wilt terugbetalen?'; +$_MODULE['<{mollie}prestashop>refund_76f0ed934de85cc7131910b32ede7714'] = 'Terugbetalen'; +$_MODULE['<{mollie}prestashop>refund_ea4788705e6873b424c65e91c2846b19'] = 'Annuleren'; +$_MODULE['<{mollie}prestashop>mollie_484f5a79672cebe198ebdde45a1d672f'] = 'Cadeaupapier'; +$_MODULE['<{mollie}prestashop>mollie_e0010a0a1a3259ab5c06a19bad532851'] = 'Betaald'; +$_MODULE['<{mollie}prestashop>mollie_a206428462686af481cb072b8db11784'] = 'Geautoriseerd'; +$_MODULE['<{mollie}prestashop>mollie_0e22fe7d45f8e5632a4abf369b24e29c'] = 'Geannuleerd'; +$_MODULE['<{mollie}prestashop>mollie_24fe48030f7d3097d5882535b04c3fa8'] = 'Verlopen'; +$_MODULE['<{mollie}prestashop>mollie_cc61945cbbf46721a053467c395c666f'] = 'Terugbetaald'; +$_MODULE['<{mollie}prestashop>mollie_7026e386bdad92fa6f232394f5b23ffb'] = 'Wachten op overboeking'; +$_MODULE['<{mollie}prestashop>mollie_9f004157e4c148dac71da3ae5906351f'] = 'Gedeeltelijk terugbetaald'; +$_MODULE['<{mollie}prestashop>mollie_0eceeb45861f9585dd7a97a3e36f85c6'] = 'Aangemaakt'; +$_MODULE['<{mollie}prestashop>mollie_ea9cf7e47ff33b2be14e6dd07cbcefc6'] = 'Verzending'; +$_MODULE['<{mollie}prestashop>mollie_3a6e70059673992f825826f7cf89278d'] = 'De winkelwagenregel met de naam "%1s" (ID %2s) die gebruikt wordt in deze winkelwagen is niet geldig en is uit de winkelwagen verwijderd'; +$_MODULE['<{mollie}prestashop>mollie_3a1048f8aa3a9f6b604fcf7982811752'] = 'Waarschuwing: de secure key is leeg, controleer de betaling'; +$_MODULE['<{mollie}prestashop>mollie_26beb437d3323bd4bfb0811b3e891315'] = '%d afbeelding(en)'; +$_MODULE['<{mollie}prestashop>mollie_0791970c961c09eb8caaa61aba6a3ca4'] = 'Er is een fout opgetreden bij het opslaan van het bericht'; +$_MODULE['<{mollie}prestashop>mollie_ed13b3693357ebed3751cb71cb639e65'] = 'Geen vervoerder'; +$_MODULE['<{mollie}prestashop>mollie_b08d3867be98e6fff3233cd40ab8134a'] = 'Niet gelukt om bestelling aan te maken'; +$_MODULE['<{mollie}prestashop>mollie_43423b4056880b08f2c9aa50d8670531'] = 'Winkelwagen kan niet geladen worden of een bestelling is al geplaatst met deze winkelwagen'; +$_MODULE['<{mollie}prestashop>mollie_32c86f9a2a28a9fa544b97024393633e'] = 'Geen betaalmethoden gevonden'; +$_MODULE['<{mollie}prestashop>form_902b0d55fddef6f8d651fe1035b7d4bd'] = 'Fout'; +$_MODULE['<{mollie}prestashop>17_error_47e1924c444fafe9fdfce444790f0ba9'] = 'Terug naar uw winkelwagen'; +$_MODULE['<{mollie}prestashop>mollie_wait_bc0dd919f9a70dbb62f3f7afd68d6d68'] = 'Wachten op betaalstatus'; +$_MODULE['<{mollie}prestashop>order_info_2427b479f15af44582dc151ef95a90d0'] = 'Terugbetalingen zijn momenteel niet mogelijk'; +$_MODULE['<{mollie}prestashop>rounding_error_7783c757cd1177e60888080e0f4e0593'] = 'De configuratieoptie "%s" heeft een ongeldige waarde'; +$_MODULE['<{mollie}prestashop>rounding_error_2279522d0910767ffa75e0b39ed1629f'] = 'De geselecteerde afrondingsmethode wordt niet ondersteund door de Mollie Orders API'; +$_MODULE['<{mollie}prestashop>rounding_error_3a92c96baa86286685b233e6912e718d'] = 'Navigeer naar de pagina "%s" en kies de optie "%s"'; +$_MODULE['<{mollie}prestashop>smarty_error_9d1fbbe0d150b89f068ba72a20366659'] = 'De configuratiepagina "%s" is op "%s" gezet'; +$_MODULE['<{mollie}prestashop>smarty_error_27dd3bb10855eb84f48efedf6924c4c1'] = 'Hierdoor is het niet mogelijk om betaalmethoden op de checkout weer te geven'; +$_MODULE['<{mollie}prestashop>smarty_error_4ec23c59d832a2934277a2a040918789'] = 'Navigeer naar de pagian "%s" en kies één van de andere opties'; +$_MODULE['<{mollie}prestashop>smarty_error_92b67311c1a5d6cfc28ba08a1066c901'] = ' Afterwards, clear the cache one more time, so the payment method list can be refreshed'; +$_MODULE['<{mollie}prestashop>smarty_warning_9d1fbbe0d150b89f068ba72a20366659'] = 'De configuratieoptie "%s" is op "%s" gezet'; +$_MODULE['<{mollie}prestashop>smarty_warning_e7e747f9c74f0b8222c87db24d34f018'] = 'Het is mogelijk dat niet alle betaalmethoden worden weergegeven op de checkout'; +$_MODULE['<{mollie}prestashop>smarty_warning_1238db0fb782f758b5a54d6333b3610e'] = 'Om dit probleem te verhelpen, navigeer naar de pagina "%s" en leeg de cache handmatig of kies één van de andere opties'; diff --git a/upgrade/Upgrade-2.0.0.php b/upgrade/Upgrade-2.0.0.php index 6bd4f08f6..542ae684c 100644 --- a/upgrade/Upgrade-2.0.0.php +++ b/upgrade/Upgrade-2.0.0.php @@ -1,51 +1,51 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -if (!defined('_PS_VERSION_')) { - exit; -} - -/** - * @return bool - * - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ -function upgrade_module_2_0_0() -{ - Configuration::deleteByName('MOLLIE_VERSION'); - Configuration::updateValue('MOLLIE_ISSUERS', 'payment-page'); - - return true; -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +if (!defined('_PS_VERSION_')) { + exit; +} + +/** + * @return bool + * + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ +function upgrade_module_2_0_0() +{ + Configuration::deleteByName('MOLLIE_VERSION'); + Configuration::updateValue('MOLLIE_ISSUERS', 'payment-page'); + + return true; +} diff --git a/upgrade/Upgrade-3.1.5.php b/upgrade/Upgrade-3.1.5.php index eb329ee05..7c4337330 100644 --- a/upgrade/Upgrade-3.1.5.php +++ b/upgrade/Upgrade-3.1.5.php @@ -1,71 +1,71 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -if (!defined('_PS_VERSION_')) { - exit; -} - -/** - * @return bool - * - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ -function upgrade_module_3_1_5() -{ - foreach (Shop::getShops(false, null, true) as $shop) { - Configuration::updateValue( - 'MOLLIE_STATUS_CANCELED', - Configuration::get('MOLLIE_STATUS_CANCELLED', null, (int) $shop['id_shop_group'], (int) $shop['id_shop']), - false, - (int) $shop['id_shop_group'], - (int) $shop['id_shop'] - ); - } - Configuration::updateGlobalValue('MOLLIE_STATUS_CANCELED', Configuration::get('MOLLIE_STATUS_CANCELLED')); - Configuration::deleteByName('MOLLIE_STATUS_CANCELLED'); - - // Major changes, need to clear the cache - if (!Mollie::$cacheCleared) { - if (method_exists('Tools', 'clearAllCache')) { - Tools::clearAllCache(); - } - if (method_exists('Tools', 'clearCache')) { - Tools::clearCache(); - } - Mollie::$cacheCleared = true; - } - - return true; -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +if (!defined('_PS_VERSION_')) { + exit; +} + +/** + * @return bool + * + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ +function upgrade_module_3_1_5() +{ + foreach (Shop::getShops(false, null, true) as $shop) { + Configuration::updateValue( + 'MOLLIE_STATUS_CANCELED', + Configuration::get('MOLLIE_STATUS_CANCELLED', null, (int) $shop['id_shop_group'], (int) $shop['id_shop']), + false, + (int) $shop['id_shop_group'], + (int) $shop['id_shop'] + ); + } + Configuration::updateGlobalValue('MOLLIE_STATUS_CANCELED', Configuration::get('MOLLIE_STATUS_CANCELLED')); + Configuration::deleteByName('MOLLIE_STATUS_CANCELLED'); + + // Major changes, need to clear the cache + if (!Mollie::$cacheCleared) { + if (method_exists('Tools', 'clearAllCache')) { + Tools::clearAllCache(); + } + if (method_exists('Tools', 'clearCache')) { + Tools::clearCache(); + } + Mollie::$cacheCleared = true; + } + + return true; +} diff --git a/upgrade/Upgrade-3.3.0.php b/upgrade/Upgrade-3.3.0.php index 82a76e216..219897697 100644 --- a/upgrade/Upgrade-3.3.0.php +++ b/upgrade/Upgrade-3.3.0.php @@ -1,82 +1,82 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -if (!defined('_PS_VERSION_')) { - exit; -} - -/** - * @param Mollie $module - * - * @return bool - * - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ -function upgrade_module_3_3_0($module) -{ - try { - if (!Db::getInstance(_PS_USE_SQL_SLAVE_)->getValue(' - SELECT COUNT(*) - FROM information_schema.COLUMNS - WHERE TABLE_SCHEMA = \''._DB_NAME_.'\' - AND TABLE_NAME = \''._DB_PREFIX_.'mollie_payments\' - AND COLUMN_NAME = \'order_reference\'')) { - Db::getInstance()->execute( - 'ALTER TABLE `'._DB_PREFIX_.'mollie_payments` ADD `order_reference` varchar(191)' - ); - } - } catch (PrestaShopException $e) { - PrestaShopLogger::addLog("Mollie update error: {$e->getMessage()}"); - } - - if (method_exists($module, 'setDefaultCarrierStatuses')) { - $module->setDefaultCarrierStatuses(); - } - - Configuration::updateValue('MOLLIE_API', 'payments'); - - // Major changes, need to clear the cache - if (!Mollie::$cacheCleared) { - if (method_exists('Tools', 'clearAllCache')) { - Tools::clearAllCache(); - } - if (method_exists('Tools', 'clearCache')) { - Tools::clearCache(); - } - Mollie::$cacheCleared = true; - } - - return true; -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +if (!defined('_PS_VERSION_')) { + exit; +} + +/** + * @param Mollie $module + * + * @return bool + * + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ +function upgrade_module_3_3_0($module) +{ + try { + if (!Db::getInstance(_PS_USE_SQL_SLAVE_)->getValue(' + SELECT COUNT(*) + FROM information_schema.COLUMNS + WHERE TABLE_SCHEMA = \''._DB_NAME_.'\' + AND TABLE_NAME = \''._DB_PREFIX_.'mollie_payments\' + AND COLUMN_NAME = \'order_reference\'')) { + Db::getInstance()->execute( + 'ALTER TABLE `'._DB_PREFIX_.'mollie_payments` ADD `order_reference` varchar(191)' + ); + } + } catch (PrestaShopException $e) { + PrestaShopLogger::addLog("Mollie update error: {$e->getMessage()}"); + } + + if (method_exists($module, 'setDefaultCarrierStatuses')) { + $module->setDefaultCarrierStatuses(); + } + + Configuration::updateValue('MOLLIE_API', 'payments'); + + // Major changes, need to clear the cache + if (!Mollie::$cacheCleared) { + if (method_exists('Tools', 'clearAllCache')) { + Tools::clearAllCache(); + } + if (method_exists('Tools', 'clearCache')) { + Tools::clearCache(); + } + Mollie::$cacheCleared = true; + } + + return true; +} diff --git a/upgrade/Upgrade-3.3.2.php b/upgrade/Upgrade-3.3.2.php index 0987ea2d9..3a698774a 100644 --- a/upgrade/Upgrade-3.3.2.php +++ b/upgrade/Upgrade-3.3.2.php @@ -1,50 +1,50 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -if (!defined('_PS_VERSION_')) { - exit; -} - -/** - * @return bool - * - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ -function upgrade_module_3_3_2() -{ - Configuration::deleteByName('MOLLIE_USE_PROFILE_WEBHOOK'); - - return true; -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +if (!defined('_PS_VERSION_')) { + exit; +} + +/** + * @return bool + * + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ +function upgrade_module_3_3_2() +{ + Configuration::deleteByName('MOLLIE_USE_PROFILE_WEBHOOK'); + + return true; +} diff --git a/upgrade/Upgrade-3.4.2.php b/upgrade/Upgrade-3.4.2.php index a1944758b..5db22fbfd 100644 --- a/upgrade/Upgrade-3.4.2.php +++ b/upgrade/Upgrade-3.4.2.php @@ -1,58 +1,58 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -if (!defined('_PS_VERSION_')) { - exit; -} - -/** - * @return bool - * - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ -function upgrade_module_3_4_2() -{ - Configuration::updateGlobalValue(Mollie\Config\Config::MOLLIE_STATUS_OPEN, Configuration::get('PS_OS_BANKWIRE')); - Configuration::updateGlobalValue(Mollie\Config\Config::MOLLIE_STATUS_PAID, Configuration::get('PS_OS_PAYMENT')); - Configuration::updateGlobalValue(Mollie\Config\Config::MOLLIE_STATUS_CANCELED, Configuration::get('PS_OS_CANCELED')); - Configuration::updateGlobalValue(Mollie\Config\Config::MOLLIE_STATUS_EXPIRED, Configuration::get('PS_OS_CANCELED')); - Configuration::updateGlobalValue( - Mollie\Config\Config::MOLLIE_STATUS_PARTIAL_REFUND, - Configuration::get(Mollie\Config\Config::MOLLIE_STATUS_PARTIAL_REFUND) - ); - Configuration::updateGlobalValue(Mollie\Config\Config::MOLLIE_STATUS_REFUNDED, Configuration::get('PS_OS_REFUND')); - - return true; -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +if (!defined('_PS_VERSION_')) { + exit; +} + +/** + * @return bool + * + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ +function upgrade_module_3_4_2() +{ + Configuration::updateGlobalValue(Mollie\Config\Config::MOLLIE_STATUS_OPEN, Configuration::get('PS_OS_BANKWIRE')); + Configuration::updateGlobalValue(Mollie\Config\Config::MOLLIE_STATUS_PAID, Configuration::get('PS_OS_PAYMENT')); + Configuration::updateGlobalValue(Mollie\Config\Config::MOLLIE_STATUS_CANCELED, Configuration::get('PS_OS_CANCELED')); + Configuration::updateGlobalValue(Mollie\Config\Config::MOLLIE_STATUS_EXPIRED, Configuration::get('PS_OS_CANCELED')); + Configuration::updateGlobalValue( + Mollie\Config\Config::MOLLIE_STATUS_PARTIAL_REFUND, + Configuration::get(Mollie\Config\Config::MOLLIE_STATUS_PARTIAL_REFUND) + ); + Configuration::updateGlobalValue(Mollie\Config\Config::MOLLIE_STATUS_REFUNDED, Configuration::get('PS_OS_REFUND')); + + return true; +} diff --git a/upgrade/Upgrade-3.4.3.php b/upgrade/Upgrade-3.4.3.php index b3b7c3f69..1e86e06a2 100644 --- a/upgrade/Upgrade-3.4.3.php +++ b/upgrade/Upgrade-3.4.3.php @@ -1,59 +1,59 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -if (!defined('_PS_VERSION_')) { - exit; -} - -/** - * @return bool - * - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ -function upgrade_module_3_4_3() -{ - $query = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_country` ( - `id_mol_country` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, - `id_method` VARCHAR(64), - `id_country` INT(64), - `all_countries` tinyint - ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; - - if (!Db::getInstance()->execute($query)) { - return false; - } - - return true; -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +if (!defined('_PS_VERSION_')) { + exit; +} + +/** + * @return bool + * + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ +function upgrade_module_3_4_3() +{ + $query = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_country` ( + `id_mol_country` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, + `id_method` VARCHAR(64), + `id_country` INT(64), + `all_countries` tinyint + ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; + + if (!Db::getInstance()->execute($query)) { + return false; + } + + return true; +} diff --git a/upgrade/Upgrade-3.5.2.php b/upgrade/Upgrade-3.5.2.php index 6b580d287..3988f0720 100644 --- a/upgrade/Upgrade-3.5.2.php +++ b/upgrade/Upgrade-3.5.2.php @@ -1,57 +1,57 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -if (!defined('_PS_VERSION_')) { - exit; -} - -/** - * @return bool - * - * @throws PrestaShopDatabaseException - * @throws PrestaShopException - */ -function upgrade_module_3_5_2() -{ - $trackingConfigId = Configuration::getIdByName(Mollie\Config\Config::MOLLIE_TRACKING_URLS); - - $query = 'DELETE FROM`'._DB_PREFIX_.'configuration_lang` - WHERE id_configuration = "' . pSQL($trackingConfigId) . '"'; - - if (!Db::getInstance()->execute($query)) { - return false; - } - - return true; -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +if (!defined('_PS_VERSION_')) { + exit; +} + +/** + * @return bool + * + * @throws PrestaShopDatabaseException + * @throws PrestaShopException + */ +function upgrade_module_3_5_2() +{ + $trackingConfigId = Configuration::getIdByName(Mollie\Config\Config::MOLLIE_TRACKING_URLS); + + $query = 'DELETE FROM`'._DB_PREFIX_.'configuration_lang` + WHERE id_configuration = "' . pSQL($trackingConfigId) . '"'; + + if (!Db::getInstance()->execute($query)) { + return false; + } + + return true; +} diff --git a/upgrade/Upgrade-3.5.4.php b/upgrade/Upgrade-3.5.4.php index 397883a53..f8caf18a6 100644 --- a/upgrade/Upgrade-3.5.4.php +++ b/upgrade/Upgrade-3.5.4.php @@ -1,48 +1,48 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -if (!defined('_PS_VERSION_')) { - exit; -} - -/** - * @param Mollie $module - * @return bool - */ -function upgrade_module_3_5_4(Mollie $module) -{ - $module->registerHook('actionFrontControllerSetMedia'); - - return true; -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +if (!defined('_PS_VERSION_')) { + exit; +} + +/** + * @param Mollie $module + * @return bool + */ +function upgrade_module_3_5_4(Mollie $module) +{ + $module->registerHook('actionFrontControllerSetMedia'); + + return true; +} diff --git a/upgrade/Upgrade-3.5.5.php b/upgrade/Upgrade-3.5.5.php index b3b7bab74..505dc5249 100644 --- a/upgrade/Upgrade-3.5.5.php +++ b/upgrade/Upgrade-3.5.5.php @@ -1,48 +1,48 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -if (!defined('_PS_VERSION_')) { - exit; -} - -/** - * @param Mollie $module - * @return bool - */ -function upgrade_module_3_5_5(Mollie $module) -{ - $module->registerHook('actionFrontControllerSetMedia'); - - return true; -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +if (!defined('_PS_VERSION_')) { + exit; +} + +/** + * @param Mollie $module + * @return bool + */ +function upgrade_module_3_5_5(Mollie $module) +{ + $module->registerHook('actionFrontControllerSetMedia'); + + return true; +} diff --git a/upgrade/Upgrade-4.0.0.php b/upgrade/Upgrade-4.0.0.php index 25eb9c398..8aa3c49cb 100644 --- a/upgrade/Upgrade-4.0.0.php +++ b/upgrade/Upgrade-4.0.0.php @@ -1,90 +1,90 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -if (!defined('_PS_VERSION_')) { - exit; -} - -/** - * @param Mollie $module - * @return bool - */ -function upgrade_module_4_0_0() -{ - $sql = []; - $sql[] = 'CREATE TABLE IF NOT EXISTS `' . _DB_PREFIX_ . 'mol_payment_method` ( - `id_payment_method` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, - `id_method` VARCHAR(64) NOT NULL, - `method_name` VARCHAR(64) NOT NULL, - `enabled` TINYINT(1), - `title` VARCHAR(64), - `method` VARCHAR(64), - `description` VARCHAR(255), - `is_countries_applicable` TINYINT(1), - `minimal_order_value` decimal(20,6), - `max_order_value` decimal(20,6), - `surcharge` INT(10), - `surcharge_fixed_amount` decimal(20,6), - `surcharge_percentage` decimal(20,6), - `surcharge_limit` decimal(20,6), - `images_json` TEXT - ) ENGINE=' . _MYSQL_ENGINE_ . ' DEFAULT CHARSET=utf8;'; - - $sql[] = 'CREATE TABLE IF NOT EXISTS `' . _DB_PREFIX_ . 'mol_payment_method_issuer` ( - `id_payment_method_issuer` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, - `id_payment_method` INT(64) NOT NULL, - `issuers_json` TEXT NOT NULL - ) ENGINE=' . _MYSQL_ENGINE_ . ' DEFAULT CHARSET=utf8;'; - - $sql[] = 'CREATE TABLE IF NOT EXISTS `' . _DB_PREFIX_ . 'mol_order_fee` ( - `id_mol_order_fee` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, - `id_cart` INT(64) NOT NULL, - `order_fee` decimal(20,6) NOT NULL - ) ENGINE=' . _MYSQL_ENGINE_ . ' DEFAULT CHARSET=utf8;'; - - $sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_carrier_information` ( - `id_mol_carrier_information` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, - `id_carrier` INT(64) NOT NULL, - `url_source` VARCHAR(64) NOT NULL, - `custom_url` VARCHAR(255) - ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; - - foreach ($sql as $query) { - if (Db::getInstance()->execute($query) == false) { - return false; - } - } - - return true; -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +if (!defined('_PS_VERSION_')) { + exit; +} + +/** + * @param Mollie $module + * @return bool + */ +function upgrade_module_4_0_0() +{ + $sql = []; + $sql[] = 'CREATE TABLE IF NOT EXISTS `' . _DB_PREFIX_ . 'mol_payment_method` ( + `id_payment_method` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, + `id_method` VARCHAR(64) NOT NULL, + `method_name` VARCHAR(64) NOT NULL, + `enabled` TINYINT(1), + `title` VARCHAR(64), + `method` VARCHAR(64), + `description` VARCHAR(255), + `is_countries_applicable` TINYINT(1), + `minimal_order_value` decimal(20,6), + `max_order_value` decimal(20,6), + `surcharge` INT(10), + `surcharge_fixed_amount` decimal(20,6), + `surcharge_percentage` decimal(20,6), + `surcharge_limit` decimal(20,6), + `images_json` TEXT + ) ENGINE=' . _MYSQL_ENGINE_ . ' DEFAULT CHARSET=utf8;'; + + $sql[] = 'CREATE TABLE IF NOT EXISTS `' . _DB_PREFIX_ . 'mol_payment_method_issuer` ( + `id_payment_method_issuer` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, + `id_payment_method` INT(64) NOT NULL, + `issuers_json` TEXT NOT NULL + ) ENGINE=' . _MYSQL_ENGINE_ . ' DEFAULT CHARSET=utf8;'; + + $sql[] = 'CREATE TABLE IF NOT EXISTS `' . _DB_PREFIX_ . 'mol_order_fee` ( + `id_mol_order_fee` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, + `id_cart` INT(64) NOT NULL, + `order_fee` decimal(20,6) NOT NULL + ) ENGINE=' . _MYSQL_ENGINE_ . ' DEFAULT CHARSET=utf8;'; + + $sql[] = 'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'mol_carrier_information` ( + `id_mol_carrier_information` INT(64) NOT NULL PRIMARY KEY AUTO_INCREMENT, + `id_carrier` INT(64) NOT NULL, + `url_source` VARCHAR(64) NOT NULL, + `custom_url` VARCHAR(255) + ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'; + + foreach ($sql as $query) { + if (Db::getInstance()->execute($query) == false) { + return false; + } + } + + return true; +} diff --git a/upgrade/index.php b/upgrade/index.php index 729abf520..a950d02f4 100644 --- a/upgrade/index.php +++ b/upgrade/index.php @@ -1,11 +1,11 @@ - - Order deny,allow - Deny from all - - -# Apache 2.4 - - Require all denied - +# Apache 2.2 + + Order deny,allow + Deny from all + + +# Apache 2.4 + + Require all denied + diff --git a/vendor/autoload.php b/vendor/autoload.php index 3ed0de2da..50dbaf80e 100644 --- a/vendor/autoload.php +++ b/vendor/autoload.php @@ -1,7 +1,7 @@ - - * Jordi Boggiano - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Composer\Autoload; - -/** - * ClassLoader implements a PSR-0, PSR-4 and classmap class loader. - * - * $loader = new \Composer\Autoload\ClassLoader(); - * - * // register classes with namespaces - * $loader->add('Symfony\Component', __DIR__.'/component'); - * $loader->add('Symfony', __DIR__.'/framework'); - * - * // activate the autoloader - * $loader->register(); - * - * // to enable searching the include path (eg. for PEAR packages) - * $loader->setUseIncludePath(true); - * - * In this example, if you try to use a class in the Symfony\Component - * namespace or one of its children (Symfony\Component\Console for instance), - * the autoloader will first look for the class under the component/ - * directory, and it will then fallback to the framework/ directory if not - * found before giving up. - * - * This class is loosely based on the Symfony UniversalClassLoader. - * - * @author Fabien Potencier - * @author Jordi Boggiano - * @see http://www.php-fig.org/psr/psr-0/ - * @see http://www.php-fig.org/psr/psr-4/ - */ -class ClassLoader -{ - // PSR-4 - private $prefixLengthsPsr4 = array(); - private $prefixDirsPsr4 = array(); - private $fallbackDirsPsr4 = array(); - - // PSR-0 - private $prefixesPsr0 = array(); - private $fallbackDirsPsr0 = array(); - - private $useIncludePath = false; - private $classMap = array(); - private $classMapAuthoritative = false; - private $missingClasses = array(); - private $apcuPrefix; - - public function getPrefixes() - { - if (!empty($this->prefixesPsr0)) { - return call_user_func_array('array_merge', $this->prefixesPsr0); - } - - return array(); - } - - public function getPrefixesPsr4() - { - return $this->prefixDirsPsr4; - } - - public function getFallbackDirs() - { - return $this->fallbackDirsPsr0; - } - - public function getFallbackDirsPsr4() - { - return $this->fallbackDirsPsr4; - } - - public function getClassMap() - { - return $this->classMap; - } - - /** - * @param array $classMap Class to filename map - */ - public function addClassMap(array $classMap) - { - if ($this->classMap) { - $this->classMap = array_merge($this->classMap, $classMap); - } else { - $this->classMap = $classMap; - } - } - - /** - * Registers a set of PSR-0 directories for a given prefix, either - * appending or prepending to the ones previously set for this prefix. - * - * @param string $prefix The prefix - * @param array|string $paths The PSR-0 root directories - * @param bool $prepend Whether to prepend the directories - */ - public function add($prefix, $paths, $prepend = false) - { - if (!$prefix) { - if ($prepend) { - $this->fallbackDirsPsr0 = array_merge( - (array) $paths, - $this->fallbackDirsPsr0 - ); - } else { - $this->fallbackDirsPsr0 = array_merge( - $this->fallbackDirsPsr0, - (array) $paths - ); - } - - return; - } - - $first = $prefix[0]; - if (!isset($this->prefixesPsr0[$first][$prefix])) { - $this->prefixesPsr0[$first][$prefix] = (array) $paths; - - return; - } - if ($prepend) { - $this->prefixesPsr0[$first][$prefix] = array_merge( - (array) $paths, - $this->prefixesPsr0[$first][$prefix] - ); - } else { - $this->prefixesPsr0[$first][$prefix] = array_merge( - $this->prefixesPsr0[$first][$prefix], - (array) $paths - ); - } - } - - /** - * Registers a set of PSR-4 directories for a given namespace, either - * appending or prepending to the ones previously set for this namespace. - * - * @param string $prefix The prefix/namespace, with trailing '\\' - * @param array|string $paths The PSR-4 base directories - * @param bool $prepend Whether to prepend the directories - * - * @throws \InvalidArgumentException - */ - public function addPsr4($prefix, $paths, $prepend = false) - { - if (!$prefix) { - // Register directories for the root namespace. - if ($prepend) { - $this->fallbackDirsPsr4 = array_merge( - (array) $paths, - $this->fallbackDirsPsr4 - ); - } else { - $this->fallbackDirsPsr4 = array_merge( - $this->fallbackDirsPsr4, - (array) $paths - ); - } - } elseif (!isset($this->prefixDirsPsr4[$prefix])) { - // Register directories for a new namespace. - $length = strlen($prefix); - if ('\\' !== $prefix[$length - 1]) { - throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator."); - } - $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; - $this->prefixDirsPsr4[$prefix] = (array) $paths; - } elseif ($prepend) { - // Prepend directories for an already registered namespace. - $this->prefixDirsPsr4[$prefix] = array_merge( - (array) $paths, - $this->prefixDirsPsr4[$prefix] - ); - } else { - // Append directories for an already registered namespace. - $this->prefixDirsPsr4[$prefix] = array_merge( - $this->prefixDirsPsr4[$prefix], - (array) $paths - ); - } - } - - /** - * Registers a set of PSR-0 directories for a given prefix, - * replacing any others previously set for this prefix. - * - * @param string $prefix The prefix - * @param array|string $paths The PSR-0 base directories - */ - public function set($prefix, $paths) - { - if (!$prefix) { - $this->fallbackDirsPsr0 = (array) $paths; - } else { - $this->prefixesPsr0[$prefix[0]][$prefix] = (array) $paths; - } - } - - /** - * Registers a set of PSR-4 directories for a given namespace, - * replacing any others previously set for this namespace. - * - * @param string $prefix The prefix/namespace, with trailing '\\' - * @param array|string $paths The PSR-4 base directories - * - * @throws \InvalidArgumentException - */ - public function setPsr4($prefix, $paths) - { - if (!$prefix) { - $this->fallbackDirsPsr4 = (array) $paths; - } else { - $length = strlen($prefix); - if ('\\' !== $prefix[$length - 1]) { - throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator."); - } - $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; - $this->prefixDirsPsr4[$prefix] = (array) $paths; - } - } - - /** - * Turns on searching the include path for class files. - * - * @param bool $useIncludePath - */ - public function setUseIncludePath($useIncludePath) - { - $this->useIncludePath = $useIncludePath; - } - - /** - * Can be used to check if the autoloader uses the include path to check - * for classes. - * - * @return bool - */ - public function getUseIncludePath() - { - return $this->useIncludePath; - } - - /** - * Turns off searching the prefix and fallback directories for classes - * that have not been registered with the class map. - * - * @param bool $classMapAuthoritative - */ - public function setClassMapAuthoritative($classMapAuthoritative) - { - $this->classMapAuthoritative = $classMapAuthoritative; - } - - /** - * Should class lookup fail if not found in the current class map? - * - * @return bool - */ - public function isClassMapAuthoritative() - { - return $this->classMapAuthoritative; - } - - /** - * APCu prefix to use to cache found/not-found classes, if the extension is enabled. - * - * @param string|null $apcuPrefix - */ - public function setApcuPrefix($apcuPrefix) - { - $this->apcuPrefix = function_exists('apcu_fetch') && ini_get('apc.enabled') ? $apcuPrefix : null; - } - - /** - * The APCu prefix in use, or null if APCu caching is not enabled. - * - * @return string|null - */ - public function getApcuPrefix() - { - return $this->apcuPrefix; - } - - /** - * Registers this instance as an autoloader. - * - * @param bool $prepend Whether to prepend the autoloader or not - */ - public function register($prepend = false) - { - spl_autoload_register(array($this, 'loadClass'), true, $prepend); - } - - /** - * Unregisters this instance as an autoloader. - */ - public function unregister() - { - spl_autoload_unregister(array($this, 'loadClass')); - } - - /** - * Loads the given class or interface. - * - * @param string $class The name of the class - * @return bool|null True if loaded, null otherwise - */ - public function loadClass($class) - { - if ($file = $this->findFile($class)) { - includeFile($file); - - return true; - } - } - - /** - * Finds the path to the file where the class is defined. - * - * @param string $class The name of the class - * - * @return string|false The path if found, false otherwise - */ - public function findFile($class) - { - // class map lookup - if (isset($this->classMap[$class])) { - return $this->classMap[$class]; - } - if ($this->classMapAuthoritative || isset($this->missingClasses[$class])) { - return false; - } - if (null !== $this->apcuPrefix) { - $file = apcu_fetch($this->apcuPrefix.$class, $hit); - if ($hit) { - return $file; - } - } - - $file = $this->findFileWithExtension($class, '.php'); - - // Search for Hack files if we are running on HHVM - if (false === $file && defined('HHVM_VERSION')) { - $file = $this->findFileWithExtension($class, '.hh'); - } - - if (null !== $this->apcuPrefix) { - apcu_add($this->apcuPrefix.$class, $file); - } - - if (false === $file) { - // Remember that this class does not exist. - $this->missingClasses[$class] = true; - } - - return $file; - } - - private function findFileWithExtension($class, $ext) - { - // PSR-4 lookup - $logicalPathPsr4 = strtr($class, '\\', DIRECTORY_SEPARATOR) . $ext; - - $first = $class[0]; - if (isset($this->prefixLengthsPsr4[$first])) { - $subPath = $class; - while (false !== $lastPos = strrpos($subPath, '\\')) { - $subPath = substr($subPath, 0, $lastPos); - $search = $subPath.'\\'; - if (isset($this->prefixDirsPsr4[$search])) { - $pathEnd = DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $lastPos + 1); - foreach ($this->prefixDirsPsr4[$search] as $dir) { - if (file_exists($file = $dir . $pathEnd)) { - return $file; - } - } - } - } - } - - // PSR-4 fallback dirs - foreach ($this->fallbackDirsPsr4 as $dir) { - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr4)) { - return $file; - } - } - - // PSR-0 lookup - if (false !== $pos = strrpos($class, '\\')) { - // namespaced class name - $logicalPathPsr0 = substr($logicalPathPsr4, 0, $pos + 1) - . strtr(substr($logicalPathPsr4, $pos + 1), '_', DIRECTORY_SEPARATOR); - } else { - // PEAR-like class name - $logicalPathPsr0 = strtr($class, '_', DIRECTORY_SEPARATOR) . $ext; - } - - if (isset($this->prefixesPsr0[$first])) { - foreach ($this->prefixesPsr0[$first] as $prefix => $dirs) { - if (0 === strpos($class, $prefix)) { - foreach ($dirs as $dir) { - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) { - return $file; - } - } - } - } - } - - // PSR-0 fallback dirs - foreach ($this->fallbackDirsPsr0 as $dir) { - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) { - return $file; - } - } - - // PSR-0 include paths. - if ($this->useIncludePath && $file = stream_resolve_include_path($logicalPathPsr0)) { - return $file; - } - - return false; - } -} - -/** - * Scope isolated include. - * - * Prevents access to $this/self from included files. - */ -function includeFile($file) -{ - include $file; -} + + * Jordi Boggiano + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Composer\Autoload; + +/** + * ClassLoader implements a PSR-0, PSR-4 and classmap class loader. + * + * $loader = new \Composer\Autoload\ClassLoader(); + * + * // register classes with namespaces + * $loader->add('Symfony\Component', __DIR__.'/component'); + * $loader->add('Symfony', __DIR__.'/framework'); + * + * // activate the autoloader + * $loader->register(); + * + * // to enable searching the include path (eg. for PEAR packages) + * $loader->setUseIncludePath(true); + * + * In this example, if you try to use a class in the Symfony\Component + * namespace or one of its children (Symfony\Component\Console for instance), + * the autoloader will first look for the class under the component/ + * directory, and it will then fallback to the framework/ directory if not + * found before giving up. + * + * This class is loosely based on the Symfony UniversalClassLoader. + * + * @author Fabien Potencier + * @author Jordi Boggiano + * @see http://www.php-fig.org/psr/psr-0/ + * @see http://www.php-fig.org/psr/psr-4/ + */ +class ClassLoader +{ + // PSR-4 + private $prefixLengthsPsr4 = array(); + private $prefixDirsPsr4 = array(); + private $fallbackDirsPsr4 = array(); + + // PSR-0 + private $prefixesPsr0 = array(); + private $fallbackDirsPsr0 = array(); + + private $useIncludePath = false; + private $classMap = array(); + private $classMapAuthoritative = false; + private $missingClasses = array(); + private $apcuPrefix; + + public function getPrefixes() + { + if (!empty($this->prefixesPsr0)) { + return call_user_func_array('array_merge', $this->prefixesPsr0); + } + + return array(); + } + + public function getPrefixesPsr4() + { + return $this->prefixDirsPsr4; + } + + public function getFallbackDirs() + { + return $this->fallbackDirsPsr0; + } + + public function getFallbackDirsPsr4() + { + return $this->fallbackDirsPsr4; + } + + public function getClassMap() + { + return $this->classMap; + } + + /** + * @param array $classMap Class to filename map + */ + public function addClassMap(array $classMap) + { + if ($this->classMap) { + $this->classMap = array_merge($this->classMap, $classMap); + } else { + $this->classMap = $classMap; + } + } + + /** + * Registers a set of PSR-0 directories for a given prefix, either + * appending or prepending to the ones previously set for this prefix. + * + * @param string $prefix The prefix + * @param array|string $paths The PSR-0 root directories + * @param bool $prepend Whether to prepend the directories + */ + public function add($prefix, $paths, $prepend = false) + { + if (!$prefix) { + if ($prepend) { + $this->fallbackDirsPsr0 = array_merge( + (array) $paths, + $this->fallbackDirsPsr0 + ); + } else { + $this->fallbackDirsPsr0 = array_merge( + $this->fallbackDirsPsr0, + (array) $paths + ); + } + + return; + } + + $first = $prefix[0]; + if (!isset($this->prefixesPsr0[$first][$prefix])) { + $this->prefixesPsr0[$first][$prefix] = (array) $paths; + + return; + } + if ($prepend) { + $this->prefixesPsr0[$first][$prefix] = array_merge( + (array) $paths, + $this->prefixesPsr0[$first][$prefix] + ); + } else { + $this->prefixesPsr0[$first][$prefix] = array_merge( + $this->prefixesPsr0[$first][$prefix], + (array) $paths + ); + } + } + + /** + * Registers a set of PSR-4 directories for a given namespace, either + * appending or prepending to the ones previously set for this namespace. + * + * @param string $prefix The prefix/namespace, with trailing '\\' + * @param array|string $paths The PSR-4 base directories + * @param bool $prepend Whether to prepend the directories + * + * @throws \InvalidArgumentException + */ + public function addPsr4($prefix, $paths, $prepend = false) + { + if (!$prefix) { + // Register directories for the root namespace. + if ($prepend) { + $this->fallbackDirsPsr4 = array_merge( + (array) $paths, + $this->fallbackDirsPsr4 + ); + } else { + $this->fallbackDirsPsr4 = array_merge( + $this->fallbackDirsPsr4, + (array) $paths + ); + } + } elseif (!isset($this->prefixDirsPsr4[$prefix])) { + // Register directories for a new namespace. + $length = strlen($prefix); + if ('\\' !== $prefix[$length - 1]) { + throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator."); + } + $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; + $this->prefixDirsPsr4[$prefix] = (array) $paths; + } elseif ($prepend) { + // Prepend directories for an already registered namespace. + $this->prefixDirsPsr4[$prefix] = array_merge( + (array) $paths, + $this->prefixDirsPsr4[$prefix] + ); + } else { + // Append directories for an already registered namespace. + $this->prefixDirsPsr4[$prefix] = array_merge( + $this->prefixDirsPsr4[$prefix], + (array) $paths + ); + } + } + + /** + * Registers a set of PSR-0 directories for a given prefix, + * replacing any others previously set for this prefix. + * + * @param string $prefix The prefix + * @param array|string $paths The PSR-0 base directories + */ + public function set($prefix, $paths) + { + if (!$prefix) { + $this->fallbackDirsPsr0 = (array) $paths; + } else { + $this->prefixesPsr0[$prefix[0]][$prefix] = (array) $paths; + } + } + + /** + * Registers a set of PSR-4 directories for a given namespace, + * replacing any others previously set for this namespace. + * + * @param string $prefix The prefix/namespace, with trailing '\\' + * @param array|string $paths The PSR-4 base directories + * + * @throws \InvalidArgumentException + */ + public function setPsr4($prefix, $paths) + { + if (!$prefix) { + $this->fallbackDirsPsr4 = (array) $paths; + } else { + $length = strlen($prefix); + if ('\\' !== $prefix[$length - 1]) { + throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator."); + } + $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; + $this->prefixDirsPsr4[$prefix] = (array) $paths; + } + } + + /** + * Turns on searching the include path for class files. + * + * @param bool $useIncludePath + */ + public function setUseIncludePath($useIncludePath) + { + $this->useIncludePath = $useIncludePath; + } + + /** + * Can be used to check if the autoloader uses the include path to check + * for classes. + * + * @return bool + */ + public function getUseIncludePath() + { + return $this->useIncludePath; + } + + /** + * Turns off searching the prefix and fallback directories for classes + * that have not been registered with the class map. + * + * @param bool $classMapAuthoritative + */ + public function setClassMapAuthoritative($classMapAuthoritative) + { + $this->classMapAuthoritative = $classMapAuthoritative; + } + + /** + * Should class lookup fail if not found in the current class map? + * + * @return bool + */ + public function isClassMapAuthoritative() + { + return $this->classMapAuthoritative; + } + + /** + * APCu prefix to use to cache found/not-found classes, if the extension is enabled. + * + * @param string|null $apcuPrefix + */ + public function setApcuPrefix($apcuPrefix) + { + $this->apcuPrefix = function_exists('apcu_fetch') && ini_get('apc.enabled') ? $apcuPrefix : null; + } + + /** + * The APCu prefix in use, or null if APCu caching is not enabled. + * + * @return string|null + */ + public function getApcuPrefix() + { + return $this->apcuPrefix; + } + + /** + * Registers this instance as an autoloader. + * + * @param bool $prepend Whether to prepend the autoloader or not + */ + public function register($prepend = false) + { + spl_autoload_register(array($this, 'loadClass'), true, $prepend); + } + + /** + * Unregisters this instance as an autoloader. + */ + public function unregister() + { + spl_autoload_unregister(array($this, 'loadClass')); + } + + /** + * Loads the given class or interface. + * + * @param string $class The name of the class + * @return bool|null True if loaded, null otherwise + */ + public function loadClass($class) + { + if ($file = $this->findFile($class)) { + includeFile($file); + + return true; + } + } + + /** + * Finds the path to the file where the class is defined. + * + * @param string $class The name of the class + * + * @return string|false The path if found, false otherwise + */ + public function findFile($class) + { + // class map lookup + if (isset($this->classMap[$class])) { + return $this->classMap[$class]; + } + if ($this->classMapAuthoritative || isset($this->missingClasses[$class])) { + return false; + } + if (null !== $this->apcuPrefix) { + $file = apcu_fetch($this->apcuPrefix.$class, $hit); + if ($hit) { + return $file; + } + } + + $file = $this->findFileWithExtension($class, '.php'); + + // Search for Hack files if we are running on HHVM + if (false === $file && defined('HHVM_VERSION')) { + $file = $this->findFileWithExtension($class, '.hh'); + } + + if (null !== $this->apcuPrefix) { + apcu_add($this->apcuPrefix.$class, $file); + } + + if (false === $file) { + // Remember that this class does not exist. + $this->missingClasses[$class] = true; + } + + return $file; + } + + private function findFileWithExtension($class, $ext) + { + // PSR-4 lookup + $logicalPathPsr4 = strtr($class, '\\', DIRECTORY_SEPARATOR) . $ext; + + $first = $class[0]; + if (isset($this->prefixLengthsPsr4[$first])) { + $subPath = $class; + while (false !== $lastPos = strrpos($subPath, '\\')) { + $subPath = substr($subPath, 0, $lastPos); + $search = $subPath.'\\'; + if (isset($this->prefixDirsPsr4[$search])) { + $pathEnd = DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $lastPos + 1); + foreach ($this->prefixDirsPsr4[$search] as $dir) { + if (file_exists($file = $dir . $pathEnd)) { + return $file; + } + } + } + } + } + + // PSR-4 fallback dirs + foreach ($this->fallbackDirsPsr4 as $dir) { + if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr4)) { + return $file; + } + } + + // PSR-0 lookup + if (false !== $pos = strrpos($class, '\\')) { + // namespaced class name + $logicalPathPsr0 = substr($logicalPathPsr4, 0, $pos + 1) + . strtr(substr($logicalPathPsr4, $pos + 1), '_', DIRECTORY_SEPARATOR); + } else { + // PEAR-like class name + $logicalPathPsr0 = strtr($class, '_', DIRECTORY_SEPARATOR) . $ext; + } + + if (isset($this->prefixesPsr0[$first])) { + foreach ($this->prefixesPsr0[$first] as $prefix => $dirs) { + if (0 === strpos($class, $prefix)) { + foreach ($dirs as $dir) { + if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) { + return $file; + } + } + } + } + } + + // PSR-0 fallback dirs + foreach ($this->fallbackDirsPsr0 as $dir) { + if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) { + return $file; + } + } + + // PSR-0 include paths. + if ($this->useIncludePath && $file = stream_resolve_include_path($logicalPathPsr0)) { + return $file; + } + + return false; + } +} + +/** + * Scope isolated include. + * + * Prevents access to $this/self from included files. + */ +function includeFile($file) +{ + include $file; +} diff --git a/vendor/composer/LICENSE b/vendor/composer/LICENSE index f0157a6ed..d3c046482 100644 --- a/vendor/composer/LICENSE +++ b/vendor/composer/LICENSE @@ -1,56 +1,56 @@ -Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ -Upstream-Name: Composer -Upstream-Contact: Jordi Boggiano -Source: https://github.com/composer/composer - -Files: * -Copyright: 2016, Nils Adermann - 2016, Jordi Boggiano -License: Expat - -Files: src/Composer/Util/TlsHelper.php -Copyright: 2016, Nils Adermann - 2016, Jordi Boggiano - 2013, Evan Coury -License: Expat and BSD-2-Clause - -License: BSD-2-Clause - Redistribution and use in source and binary forms, with or without modification, - are permitted provided that the following conditions are met: - . - * Redistributions of source code must retain the above copyright notice, - this list of conditions and the following disclaimer. - . - * Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. - . - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND - ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR - ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS - SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -License: Expat - Permission is hereby granted, free of charge, to any person obtaining a copy - of this software and associated documentation files (the "Software"), to deal - in the Software without restriction, including without limitation the rights - to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - copies of the Software, and to permit persons to whom the Software is furnished - to do so, subject to the following conditions: - . - The above copyright notice and this permission notice shall be included in all - copies or substantial portions of the Software. - . - THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN - THE SOFTWARE. +Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: Composer +Upstream-Contact: Jordi Boggiano +Source: https://github.com/composer/composer + +Files: * +Copyright: 2016, Nils Adermann + 2016, Jordi Boggiano +License: Expat + +Files: src/Composer/Util/TlsHelper.php +Copyright: 2016, Nils Adermann + 2016, Jordi Boggiano + 2013, Evan Coury +License: Expat and BSD-2-Clause + +License: BSD-2-Clause + Redistribution and use in source and binary forms, with or without modification, + are permitted provided that the following conditions are met: + . + * Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + . + * Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + . + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND + ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR + ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +License: Expat + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is furnished + to do so, subject to the following conditions: + . + The above copyright notice and this permission notice shall be included in all + copies or substantial portions of the Software. + . + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. diff --git a/vendor/composer/autoload_classmap.php b/vendor/composer/autoload_classmap.php index b962f9dd2..7d3e8a234 100644 --- a/vendor/composer/autoload_classmap.php +++ b/vendor/composer/autoload_classmap.php @@ -1,568 +1,568 @@ - $vendorDir . '/composer/autoload_real.php', - 'Composer\\Autoload\\ClassLoader' => $vendorDir . '/composer/ClassLoader.php', - 'Composer\\Autoload\\ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf' => $vendorDir . '/composer/autoload_static.php', - 'MolCarrierInformation' => $baseDir . '/src/Entity/MolCarrierInformation.php', - 'MolOrderFee' => $baseDir . '/src/Entity/MolOrderFee.php', - 'MolPaymentMethod' => $baseDir . '/src/Entity/MolPaymentMethod.php', - 'MolPaymentMethodIssuer' => $baseDir . '/src/Entity/MolPaymentMethodIssuer.php', - 'MollieAjaxModuleFrontController' => $baseDir . '/controllers/front/ajax.php', - 'MollieFailModuleFrontController' => $baseDir . '/controllers/front/fail.php', - 'MolliePayScreenModuleFrontController' => $baseDir . '/controllers/front/payScreen.php', - 'MolliePaymentModuleFrontController' => $baseDir . '/controllers/front/payment.php', - 'MollieQrcodeModuleFrontController' => $baseDir . '/controllers/front/qrcode.php', - 'MollieReturnModuleFrontController' => $baseDir . '/controllers/front/return.php', - 'MollieSuccessModuleFrontController' => $baseDir . '/controllers/front/success.php', - 'MollieWebhookModuleFrontController' => $baseDir . '/controllers/front/webhook.php', - '_PhpScoper5ea00cc67502b\\APCUIterator' => $vendorDir . '/symfony/polyfill-apcu/bootstrap.php', - '_PhpScoper5ea00cc67502b\\ArithmeticError' => $vendorDir . '/symfony/polyfill-php70/Resources/stubs/ArithmeticError.php', - '_PhpScoper5ea00cc67502b\\AssertionError' => $vendorDir . '/symfony/polyfill-php70/Resources/stubs/AssertionError.php', - '_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\CaBundle' => $vendorDir . '/composer/ca-bundle/src/CaBundle.php', - '_PhpScoper5ea00cc67502b\\DivisionByZeroError' => $vendorDir . '/symfony/polyfill-php70/Resources/stubs/DivisionByZeroError.php', - '_PhpScoper5ea00cc67502b\\Error' => $vendorDir . '/paragonie/random_compat/lib/error_polyfill.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Client' => $vendorDir . '/guzzlehttp/guzzle/src/Client.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\ClientInterface' => $vendorDir . '/guzzlehttp/guzzle/src/ClientInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\CookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/CookieJar.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\CookieJarInterface' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\FileCookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\SessionCookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\SetCookie' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/SetCookie.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\BadResponseException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/BadResponseException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ClientException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ClientException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ConnectException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ConnectException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\GuzzleException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/GuzzleException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\InvalidArgumentException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\RequestException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/RequestException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\SeekException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/SeekException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ServerException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ServerException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\TooManyRedirectsException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\TransferException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/TransferException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\HandlerStack' => $vendorDir . '/guzzlehttp/guzzle/src/HandlerStack.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlFactory' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlFactory.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlFactoryInterface' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlHandler.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlMultiHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\EasyHandle' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/EasyHandle.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\MockHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/MockHandler.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\Proxy' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/Proxy.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\StreamHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/StreamHandler.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\MessageFormatter' => $vendorDir . '/guzzlehttp/guzzle/src/MessageFormatter.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Middleware' => $vendorDir . '/guzzlehttp/guzzle/src/Middleware.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Pool' => $vendorDir . '/guzzlehttp/guzzle/src/Pool.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\PrepareBodyMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\AggregateException' => $vendorDir . '/guzzlehttp/promises/src/AggregateException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\CancellationException' => $vendorDir . '/guzzlehttp/promises/src/CancellationException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\Coroutine' => $vendorDir . '/guzzlehttp/promises/src/Coroutine.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\EachPromise' => $vendorDir . '/guzzlehttp/promises/src/EachPromise.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\FulfilledPromise' => $vendorDir . '/guzzlehttp/promises/src/FulfilledPromise.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\Promise' => $vendorDir . '/guzzlehttp/promises/src/Promise.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\PromiseInterface' => $vendorDir . '/guzzlehttp/promises/src/PromiseInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\PromisorInterface' => $vendorDir . '/guzzlehttp/promises/src/PromisorInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\RejectedPromise' => $vendorDir . '/guzzlehttp/promises/src/RejectedPromise.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\RejectionException' => $vendorDir . '/guzzlehttp/promises/src/RejectionException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\TaskQueue' => $vendorDir . '/guzzlehttp/promises/src/TaskQueue.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\TaskQueueInterface' => $vendorDir . '/guzzlehttp/promises/src/TaskQueueInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\AppendStream' => $vendorDir . '/guzzlehttp/psr7/src/AppendStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\BufferStream' => $vendorDir . '/guzzlehttp/psr7/src/BufferStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\CachingStream' => $vendorDir . '/guzzlehttp/psr7/src/CachingStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\DroppingStream' => $vendorDir . '/guzzlehttp/psr7/src/DroppingStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\FnStream' => $vendorDir . '/guzzlehttp/psr7/src/FnStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\InflateStream' => $vendorDir . '/guzzlehttp/psr7/src/InflateStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\LazyOpenStream' => $vendorDir . '/guzzlehttp/psr7/src/LazyOpenStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\LimitStream' => $vendorDir . '/guzzlehttp/psr7/src/LimitStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\MessageTrait' => $vendorDir . '/guzzlehttp/psr7/src/MessageTrait.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\MultipartStream' => $vendorDir . '/guzzlehttp/psr7/src/MultipartStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\NoSeekStream' => $vendorDir . '/guzzlehttp/psr7/src/NoSeekStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\PumpStream' => $vendorDir . '/guzzlehttp/psr7/src/PumpStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Request' => $vendorDir . '/guzzlehttp/psr7/src/Request.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Response' => $vendorDir . '/guzzlehttp/psr7/src/Response.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Rfc7230' => $vendorDir . '/guzzlehttp/psr7/src/Rfc7230.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\ServerRequest' => $vendorDir . '/guzzlehttp/psr7/src/ServerRequest.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Stream' => $vendorDir . '/guzzlehttp/psr7/src/Stream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\StreamDecoratorTrait' => $vendorDir . '/guzzlehttp/psr7/src/StreamDecoratorTrait.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\StreamWrapper' => $vendorDir . '/guzzlehttp/psr7/src/StreamWrapper.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UploadedFile' => $vendorDir . '/guzzlehttp/psr7/src/UploadedFile.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Uri' => $vendorDir . '/guzzlehttp/psr7/src/Uri.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UriNormalizer' => $vendorDir . '/guzzlehttp/psr7/src/UriNormalizer.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UriResolver' => $vendorDir . '/guzzlehttp/psr7/src/UriResolver.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RedirectMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/RedirectMiddleware.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RequestOptions' => $vendorDir . '/guzzlehttp/guzzle/src/RequestOptions.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RetryMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/RetryMiddleware.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\TransferStats' => $vendorDir . '/guzzlehttp/guzzle/src/TransferStats.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\UriTemplate' => $vendorDir . '/guzzlehttp/guzzle/src/UriTemplate.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Utils' => $vendorDir . '/guzzlehttp/guzzle/src/Utils.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\CompatibilityChecker' => $vendorDir . '/mollie/mollie-api-php/src/CompatibilityChecker.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ChargebackEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/ChargebackEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CollectionEndpointAbstract' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/CollectionEndpointAbstract.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CustomerEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/CustomerEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CustomerPaymentsEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/CustomerPaymentsEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\EndpointAbstract' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/EndpointAbstract.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\InvoiceEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/InvoiceEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\MandateEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/MandateEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\MethodEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/MethodEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OnboardingEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OnboardingEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OrderEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderLineEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OrderLineEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderPaymentEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OrderPaymentEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderRefundEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OrderRefundEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrganizationEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OrganizationEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentCaptureEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/PaymentCaptureEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentChargebackEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/PaymentChargebackEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/PaymentEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentRefundEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/PaymentRefundEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PermissionEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/PermissionEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ProfileEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/ProfileEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ProfileMethodEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/ProfileMethodEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\RefundEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/RefundEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\SettlementsEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/SettlementsEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ShipmentEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/ShipmentEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\SubscriptionEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/SubscriptionEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\WalletEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/WalletEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Exceptions\\ApiException' => $vendorDir . '/mollie/mollie-api-php/src/Exceptions/ApiException.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Exceptions\\IncompatiblePlatform' => $vendorDir . '/mollie/mollie-api-php/src/Exceptions/IncompatiblePlatform.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\MollieApiClient' => $vendorDir . '/mollie/mollie-api-php/src/MollieApiClient.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\BaseCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/BaseCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\BaseResource' => $vendorDir . '/mollie/mollie-api-php/src/Resources/BaseResource.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Capture' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Capture.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CaptureCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/CaptureCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Chargeback' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Chargeback.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ChargebackCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/ChargebackCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CurrentProfile' => $vendorDir . '/mollie/mollie-api-php/src/Resources/CurrentProfile.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CursorCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/CursorCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Customer' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Customer.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CustomerCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/CustomerCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Invoice' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Invoice.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\InvoiceCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/InvoiceCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Issuer' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Issuer.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\IssuerCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/IssuerCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Mandate' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Mandate.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MandateCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/MandateCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Method' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Method.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/MethodCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodPrice' => $vendorDir . '/mollie/mollie-api-php/src/Resources/MethodPrice.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodPriceCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/MethodPriceCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Onboarding' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Onboarding.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Order' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Order.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/OrderCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderLine' => $vendorDir . '/mollie/mollie-api-php/src/Resources/OrderLine.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderLineCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/OrderLineCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Organization' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Organization.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrganizationCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/OrganizationCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Payment' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Payment.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\PaymentCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/PaymentCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Permission' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Permission.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\PermissionCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/PermissionCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Profile' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Profile.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ProfileCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/ProfileCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Refund' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Refund.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\RefundCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/RefundCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ResourceFactory' => $vendorDir . '/mollie/mollie-api-php/src/Resources/ResourceFactory.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Settlement' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Settlement.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\SettlementCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/SettlementCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Shipment' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Shipment.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ShipmentCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/ShipmentCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Subscription' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Subscription.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\SubscriptionCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/SubscriptionCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\InvoiceStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/InvoiceStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\MandateMethod' => $vendorDir . '/mollie/mollie-api-php/src/Types/MandateMethod.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\MandateStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/MandateStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OnboardingStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/OnboardingStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderLineStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/OrderLineStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderLineType' => $vendorDir . '/mollie/mollie-api-php/src/Types/OrderLineType.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/OrderStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\PaymentMethod' => $vendorDir . '/mollie/mollie-api-php/src/Types/PaymentMethod.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\PaymentStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/PaymentStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\ProfileStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/ProfileStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\RefundStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/RefundStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SequenceType' => $vendorDir . '/mollie/mollie-api-php/src/Types/SequenceType.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SettlementStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/SettlementStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SubscriptionStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/SubscriptionStatus.php', - '_PhpScoper5ea00cc67502b\\ParseError' => $vendorDir . '/symfony/polyfill-php70/Resources/stubs/ParseError.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Builder' => $vendorDir . '/prestashop/decimal/src/Builder.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Exception\\DivisionByZeroException' => $vendorDir . '/prestashop/decimal/src/Exception/DivisionByZeroException.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Number' => $vendorDir . '/prestashop/decimal/src/Number.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Addition' => $vendorDir . '/prestashop/decimal/src/Operation/Addition.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Comparison' => $vendorDir . '/prestashop/decimal/src/Operation/Comparison.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Division' => $vendorDir . '/prestashop/decimal/src/Operation/Division.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\MagnitudeChange' => $vendorDir . '/prestashop/decimal/src/Operation/MagnitudeChange.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Multiplication' => $vendorDir . '/prestashop/decimal/src/Operation/Multiplication.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Rounding' => $vendorDir . '/prestashop/decimal/src/Operation/Rounding.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Subtraction' => $vendorDir . '/prestashop/decimal/src/Operation/Subtraction.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\AdditionTest' => $vendorDir . '/prestashop/decimal/tests/Operation/AdditionTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\ComparisonTest' => $vendorDir . '/prestashop/decimal/tests/Operation/ComparisonTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\DivisionTest' => $vendorDir . '/prestashop/decimal/tests/Operation/DivisionTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\MagnitudeChangeTest' => $vendorDir . '/prestashop/decimal/tests/Operation/MagnitudeChangeTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\MultiplicationTest' => $vendorDir . '/prestashop/decimal/tests/Operation/MultiplicationTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\RoundingTest' => $vendorDir . '/prestashop/decimal/tests/Operation/RoundingTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\SubtractionTest' => $vendorDir . '/prestashop/decimal/tests/Operation/SubtractionTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\tests\\Unit\\Core\\Decimal\\NumberTest' => $vendorDir . '/prestashop/decimal/tests/NumberTest.php', - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheException' => $vendorDir . '/psr/cache/src/CacheException.php', - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface' => $vendorDir . '/psr/cache/src/CacheItemInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemPoolInterface' => $vendorDir . '/psr/cache/src/CacheItemPoolInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\InvalidArgumentException' => $vendorDir . '/psr/cache/src/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerExceptionInterface' => $vendorDir . '/psr/container/src/ContainerExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => $vendorDir . '/psr/container/src/ContainerInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Container\\NotFoundExceptionInterface' => $vendorDir . '/psr/container/src/NotFoundExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\MessageInterface' => $vendorDir . '/psr/http-message/src/MessageInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\RequestInterface' => $vendorDir . '/psr/http-message/src/RequestInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\ResponseInterface' => $vendorDir . '/psr/http-message/src/ResponseInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\ServerRequestInterface' => $vendorDir . '/psr/http-message/src/ServerRequestInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\StreamInterface' => $vendorDir . '/psr/http-message/src/StreamInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\UploadedFileInterface' => $vendorDir . '/psr/http-message/src/UploadedFileInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\UriInterface' => $vendorDir . '/psr/http-message/src/UriInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\AbstractLogger' => $vendorDir . '/psr/log/Psr/Log/AbstractLogger.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\InvalidArgumentException' => $vendorDir . '/psr/log/Psr/Log/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\LogLevel' => $vendorDir . '/psr/log/Psr/Log/LogLevel.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerAwareInterface' => $vendorDir . '/psr/log/Psr/Log/LoggerAwareInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerAwareTrait' => $vendorDir . '/psr/log/Psr/Log/LoggerAwareTrait.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerInterface' => $vendorDir . '/psr/log/Psr/Log/LoggerInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerTrait' => $vendorDir . '/psr/log/Psr/Log/LoggerTrait.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\NullLogger' => $vendorDir . '/psr/log/Psr/Log/NullLogger.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\DummyTest' => $vendorDir . '/psr/log/Psr/Log/Test/DummyTest.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\LoggerInterfaceTest' => $vendorDir . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\TestLogger' => $vendorDir . '/psr/log/Psr/Log/Test/TestLogger.php', - '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\CacheException' => $vendorDir . '/psr/simple-cache/src/CacheException.php', - '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\CacheInterface' => $vendorDir . '/psr/simple-cache/src/CacheInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\InvalidArgumentException' => $vendorDir . '/psr/simple-cache/src/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\SessionUpdateTimestampHandlerInterface' => $vendorDir . '/symfony/polyfill-php70/Resources/stubs/SessionUpdateTimestampHandlerInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\AbstractAdapter' => $vendorDir . '/symfony/cache/Adapter/AbstractAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\AdapterInterface' => $vendorDir . '/symfony/cache/Adapter/AdapterInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ApcuAdapter' => $vendorDir . '/symfony/cache/Adapter/ApcuAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ArrayAdapter' => $vendorDir . '/symfony/cache/Adapter/ArrayAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ChainAdapter' => $vendorDir . '/symfony/cache/Adapter/ChainAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\DoctrineAdapter' => $vendorDir . '/symfony/cache/Adapter/DoctrineAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\FilesystemAdapter' => $vendorDir . '/symfony/cache/Adapter/FilesystemAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\MemcachedAdapter' => $vendorDir . '/symfony/cache/Adapter/MemcachedAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\NullAdapter' => $vendorDir . '/symfony/cache/Adapter/NullAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PdoAdapter' => $vendorDir . '/symfony/cache/Adapter/PdoAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PhpArrayAdapter' => $vendorDir . '/symfony/cache/Adapter/PhpArrayAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PhpFilesAdapter' => $vendorDir . '/symfony/cache/Adapter/PhpFilesAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ProxyAdapter' => $vendorDir . '/symfony/cache/Adapter/ProxyAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\RedisAdapter' => $vendorDir . '/symfony/cache/Adapter/RedisAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\SimpleCacheAdapter' => $vendorDir . '/symfony/cache/Adapter/SimpleCacheAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TagAwareAdapter' => $vendorDir . '/symfony/cache/Adapter/TagAwareAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TagAwareAdapterInterface' => $vendorDir . '/symfony/cache/Adapter/TagAwareAdapterInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableAdapter' => $vendorDir . '/symfony/cache/Adapter/TraceableAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableAdapterEvent' => $vendorDir . '/symfony/cache/Adapter/TraceableAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableTagAwareAdapter' => $vendorDir . '/symfony/cache/Adapter/TraceableTagAwareAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\CacheItem' => $vendorDir . '/symfony/cache/CacheItem.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\DataCollector\\CacheDataCollector' => $vendorDir . '/symfony/cache/DataCollector/CacheDataCollector.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\DoctrineProvider' => $vendorDir . '/symfony/cache/DoctrineProvider.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\CacheException' => $vendorDir . '/symfony/cache/Exception/CacheException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException' => $vendorDir . '/symfony/cache/Exception/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\PruneableInterface' => $vendorDir . '/symfony/cache/PruneableInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\ResettableInterface' => $vendorDir . '/symfony/cache/ResettableInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\AbstractCache' => $vendorDir . '/symfony/cache/Simple/AbstractCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ApcuCache' => $vendorDir . '/symfony/cache/Simple/ApcuCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ArrayCache' => $vendorDir . '/symfony/cache/Simple/ArrayCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ChainCache' => $vendorDir . '/symfony/cache/Simple/ChainCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\DoctrineCache' => $vendorDir . '/symfony/cache/Simple/DoctrineCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\FilesystemCache' => $vendorDir . '/symfony/cache/Simple/FilesystemCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\MemcachedCache' => $vendorDir . '/symfony/cache/Simple/MemcachedCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\NullCache' => $vendorDir . '/symfony/cache/Simple/NullCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PdoCache' => $vendorDir . '/symfony/cache/Simple/PdoCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PhpArrayCache' => $vendorDir . '/symfony/cache/Simple/PhpArrayCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PhpFilesCache' => $vendorDir . '/symfony/cache/Simple/PhpFilesCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\Psr6Cache' => $vendorDir . '/symfony/cache/Simple/Psr6Cache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\RedisCache' => $vendorDir . '/symfony/cache/Simple/RedisCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\TraceableCache' => $vendorDir . '/symfony/cache/Simple/TraceableCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\TraceableCacheEvent' => $vendorDir . '/symfony/cache/Simple/TraceableCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\AbstractTrait' => $vendorDir . '/symfony/cache/Traits/AbstractTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ApcuTrait' => $vendorDir . '/symfony/cache/Traits/ApcuTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ArrayTrait' => $vendorDir . '/symfony/cache/Traits/ArrayTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\DoctrineTrait' => $vendorDir . '/symfony/cache/Traits/DoctrineTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\FilesystemCommonTrait' => $vendorDir . '/symfony/cache/Traits/FilesystemCommonTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\FilesystemTrait' => $vendorDir . '/symfony/cache/Traits/FilesystemTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\MemcachedTrait' => $vendorDir . '/symfony/cache/Traits/MemcachedTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PdoTrait' => $vendorDir . '/symfony/cache/Traits/PdoTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PhpArrayTrait' => $vendorDir . '/symfony/cache/Traits/PhpArrayTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PhpFilesTrait' => $vendorDir . '/symfony/cache/Traits/PhpFilesTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ProxyTrait' => $vendorDir . '/symfony/cache/Traits/ProxyTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\RedisProxy' => $vendorDir . '/symfony/cache/Traits/RedisProxy.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\RedisTrait' => $vendorDir . '/symfony/cache/Traits/RedisTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCache' => $vendorDir . '/symfony/config/ConfigCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheFactory' => $vendorDir . '/symfony/config/ConfigCacheFactory.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheFactoryInterface' => $vendorDir . '/symfony/config/ConfigCacheFactoryInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheInterface' => $vendorDir . '/symfony/config/ConfigCacheInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ArrayNode' => $vendorDir . '/symfony/config/Definition/ArrayNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BaseNode' => $vendorDir . '/symfony/config/Definition/BaseNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BooleanNode' => $vendorDir . '/symfony/config/Definition/BooleanNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ArrayNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/ArrayNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\BooleanNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/BooleanNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\EnumNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/EnumNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ExprBuilder' => $vendorDir . '/symfony/config/Definition/Builder/ExprBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\FloatNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/FloatNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\IntegerNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/IntegerNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\MergeBuilder' => $vendorDir . '/symfony/config/Definition/Builder/MergeBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeBuilder' => $vendorDir . '/symfony/config/Definition/Builder/NodeBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/NodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeParentInterface' => $vendorDir . '/symfony/config/Definition/Builder/NodeParentInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NormalizationBuilder' => $vendorDir . '/symfony/config/Definition/Builder/NormalizationBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NumericNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/NumericNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ParentNodeDefinitionInterface' => $vendorDir . '/symfony/config/Definition/Builder/ParentNodeDefinitionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ScalarNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/ScalarNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\TreeBuilder' => $vendorDir . '/symfony/config/Definition/Builder/TreeBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ValidationBuilder' => $vendorDir . '/symfony/config/Definition/Builder/ValidationBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\VariableNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/VariableNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ConfigurationInterface' => $vendorDir . '/symfony/config/Definition/ConfigurationInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Dumper\\XmlReferenceDumper' => $vendorDir . '/symfony/config/Definition/Dumper/XmlReferenceDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Dumper\\YamlReferenceDumper' => $vendorDir . '/symfony/config/Definition/Dumper/YamlReferenceDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\EnumNode' => $vendorDir . '/symfony/config/Definition/EnumNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\DuplicateKeyException' => $vendorDir . '/symfony/config/Definition/Exception/DuplicateKeyException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\Exception' => $vendorDir . '/symfony/config/Definition/Exception/Exception.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\ForbiddenOverwriteException' => $vendorDir . '/symfony/config/Definition/Exception/ForbiddenOverwriteException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException' => $vendorDir . '/symfony/config/Definition/Exception/InvalidConfigurationException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException' => $vendorDir . '/symfony/config/Definition/Exception/InvalidDefinitionException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException' => $vendorDir . '/symfony/config/Definition/Exception/InvalidTypeException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\UnsetKeyException' => $vendorDir . '/symfony/config/Definition/Exception/UnsetKeyException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\FloatNode' => $vendorDir . '/symfony/config/Definition/FloatNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\IntegerNode' => $vendorDir . '/symfony/config/Definition/IntegerNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\NodeInterface' => $vendorDir . '/symfony/config/Definition/NodeInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\NumericNode' => $vendorDir . '/symfony/config/Definition/NumericNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Processor' => $vendorDir . '/symfony/config/Definition/Processor.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypeNodeInterface' => $vendorDir . '/symfony/config/Definition/PrototypeNodeInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypedArrayNode' => $vendorDir . '/symfony/config/Definition/PrototypedArrayNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ScalarNode' => $vendorDir . '/symfony/config/Definition/ScalarNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\VariableNode' => $vendorDir . '/symfony/config/Definition/VariableNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\DependencyInjection\\ConfigCachePass' => $vendorDir . '/symfony/config/DependencyInjection/ConfigCachePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderImportCircularReferenceException' => $vendorDir . '/symfony/config/Exception/FileLoaderImportCircularReferenceException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderLoadException' => $vendorDir . '/symfony/config/Exception/FileLoaderLoadException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLocatorFileNotFoundException' => $vendorDir . '/symfony/config/Exception/FileLocatorFileNotFoundException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocator' => $vendorDir . '/symfony/config/FileLocator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface' => $vendorDir . '/symfony/config/FileLocatorInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\DelegatingLoader' => $vendorDir . '/symfony/config/Loader/DelegatingLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\FileLoader' => $vendorDir . '/symfony/config/Loader/FileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\GlobFileLoader' => $vendorDir . '/symfony/config/Loader/GlobFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\Loader' => $vendorDir . '/symfony/config/Loader/Loader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface' => $vendorDir . '/symfony/config/Loader/LoaderInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolver' => $vendorDir . '/symfony/config/Loader/LoaderResolver.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface' => $vendorDir . '/symfony/config/Loader/LoaderResolverInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerConfigCache' => $vendorDir . '/symfony/config/ResourceCheckerConfigCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerConfigCacheFactory' => $vendorDir . '/symfony/config/ResourceCheckerConfigCacheFactory.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface' => $vendorDir . '/symfony/config/ResourceCheckerInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ClassExistenceResource' => $vendorDir . '/symfony/config/Resource/ClassExistenceResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ComposerResource' => $vendorDir . '/symfony/config/Resource/ComposerResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\DirectoryResource' => $vendorDir . '/symfony/config/Resource/DirectoryResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileExistenceResource' => $vendorDir . '/symfony/config/Resource/FileExistenceResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileResource' => $vendorDir . '/symfony/config/Resource/FileResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\GlobResource' => $vendorDir . '/symfony/config/Resource/GlobResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionClassResource' => $vendorDir . '/symfony/config/Resource/ReflectionClassResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionMethodHhvmWrapper' => $vendorDir . '/symfony/config/Resource/ReflectionClassResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionParameterHhvmWrapper' => $vendorDir . '/symfony/config/Resource/ReflectionClassResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ResourceInterface' => $vendorDir . '/symfony/config/Resource/ResourceInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\SelfCheckingResourceChecker' => $vendorDir . '/symfony/config/Resource/SelfCheckingResourceChecker.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\SelfCheckingResourceInterface' => $vendorDir . '/symfony/config/Resource/SelfCheckingResourceInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\Exception\\InvalidXmlException' => $vendorDir . '/symfony/config/Util/Exception/InvalidXmlException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\Exception\\XmlParsingException' => $vendorDir . '/symfony/config/Util/Exception/XmlParsingException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\XmlUtils' => $vendorDir . '/symfony/config/Util/XmlUtils.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Alias' => $vendorDir . '/symfony/dependency-injection/Alias.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\ArgumentInterface' => $vendorDir . '/symfony/dependency-injection/Argument/ArgumentInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\BoundArgument' => $vendorDir . '/symfony/dependency-injection/Argument/BoundArgument.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\IteratorArgument' => $vendorDir . '/symfony/dependency-injection/Argument/IteratorArgument.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\RewindableGenerator' => $vendorDir . '/symfony/dependency-injection/Argument/RewindableGenerator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\ServiceClosureArgument' => $vendorDir . '/symfony/dependency-injection/Argument/ServiceClosureArgument.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\TaggedIteratorArgument' => $vendorDir . '/symfony/dependency-injection/Argument/TaggedIteratorArgument.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ChildDefinition' => $vendorDir . '/symfony/dependency-injection/ChildDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AbstractRecursivePass' => $vendorDir . '/symfony/dependency-injection/Compiler/AbstractRecursivePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AnalyzeServiceReferencesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/AnalyzeServiceReferencesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutoAliasServicePass' => $vendorDir . '/symfony/dependency-injection/Compiler/AutoAliasServicePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowireExceptionPass' => $vendorDir . '/symfony/dependency-injection/Compiler/AutowireExceptionPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowirePass' => $vendorDir . '/symfony/dependency-injection/Compiler/AutowirePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowireRequiredMethodsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/AutowireRequiredMethodsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckArgumentsValidityPass' => $vendorDir . '/symfony/dependency-injection/Compiler/CheckArgumentsValidityPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckCircularReferencesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/CheckCircularReferencesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckDefinitionValidityPass' => $vendorDir . '/symfony/dependency-injection/Compiler/CheckDefinitionValidityPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckExceptionOnInvalidReferenceBehaviorPass' => $vendorDir . '/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckReferenceValidityPass' => $vendorDir . '/symfony/dependency-injection/Compiler/CheckReferenceValidityPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\Compiler' => $vendorDir . '/symfony/dependency-injection/Compiler/Compiler.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CompilerPassInterface' => $vendorDir . '/symfony/dependency-injection/Compiler/CompilerPassInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\DecoratorServicePass' => $vendorDir . '/symfony/dependency-injection/Compiler/DecoratorServicePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\DefinitionErrorExceptionPass' => $vendorDir . '/symfony/dependency-injection/Compiler/DefinitionErrorExceptionPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ExtensionCompilerPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ExtensionCompilerPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\FactoryReturnTypePass' => $vendorDir . '/symfony/dependency-injection/Compiler/FactoryReturnTypePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\InlineServiceDefinitionsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/InlineServiceDefinitionsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\LoggingFormatter' => $vendorDir . '/symfony/dependency-injection/Compiler/LoggingFormatter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationContainerBuilder' => $vendorDir . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationParameterBag' => $vendorDir . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationPass' => $vendorDir . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\PassConfig' => $vendorDir . '/symfony/dependency-injection/Compiler/PassConfig.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\PriorityTaggedServiceTrait' => $vendorDir . '/symfony/dependency-injection/Compiler/PriorityTaggedServiceTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RegisterEnvVarProcessorsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RegisterEnvVarProcessorsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RegisterServiceSubscribersPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RegisterServiceSubscribersPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemoveAbstractDefinitionsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RemoveAbstractDefinitionsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemovePrivateAliasesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RemovePrivateAliasesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemoveUnusedDefinitionsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RemoveUnusedDefinitionsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RepeatablePassInterface' => $vendorDir . '/symfony/dependency-injection/Compiler/RepeatablePassInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RepeatedPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RepeatedPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ReplaceAliasByActualDefinitionPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ReplaceAliasByActualDefinitionPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveBindingsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveBindingsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveChildDefinitionsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveChildDefinitionsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveClassPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveClassPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveDefinitionTemplatesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveDefinitionTemplatesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveEnvPlaceholdersPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveEnvPlaceholdersPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveFactoryClassPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveFactoryClassPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveHotPathPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveHotPathPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveInstanceofConditionalsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveInstanceofConditionalsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveInvalidReferencesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveInvalidReferencesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveNamedArgumentsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveNamedArgumentsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveParameterPlaceHoldersPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveParameterPlaceHoldersPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolvePrivatesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolvePrivatesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveReferencesToAliasesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveReferencesToAliasesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveServiceSubscribersPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveServiceSubscribersPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveTaggedIteratorArgumentPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveTaggedIteratorArgumentPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceLocatorTagPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ServiceLocatorTagPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraph' => $vendorDir . '/symfony/dependency-injection/Compiler/ServiceReferenceGraph.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraphEdge' => $vendorDir . '/symfony/dependency-injection/Compiler/ServiceReferenceGraphEdge.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraphNode' => $vendorDir . '/symfony/dependency-injection/Compiler/ServiceReferenceGraphNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\AutowireServiceResource' => $vendorDir . '/symfony/dependency-injection/Config/AutowireServiceResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\ContainerParametersResource' => $vendorDir . '/symfony/dependency-injection/Config/ContainerParametersResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\ContainerParametersResourceChecker' => $vendorDir . '/symfony/dependency-injection/Config/ContainerParametersResourceChecker.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Container' => $vendorDir . '/symfony/dependency-injection/Container.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerAwareInterface' => $vendorDir . '/symfony/dependency-injection/ContainerAwareInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerAwareTrait' => $vendorDir . '/symfony/dependency-injection/ContainerAwareTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerBuilder' => $vendorDir . '/symfony/dependency-injection/ContainerBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => $vendorDir . '/symfony/dependency-injection/ContainerInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition' => $vendorDir . '/symfony/dependency-injection/Definition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\DefinitionDecorator' => $vendorDir . '/symfony/dependency-injection/DefinitionDecorator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\Dumper' => $vendorDir . '/symfony/dependency-injection/Dumper/Dumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\DumperInterface' => $vendorDir . '/symfony/dependency-injection/Dumper/DumperInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\GraphvizDumper' => $vendorDir . '/symfony/dependency-injection/Dumper/GraphvizDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\PhpDumper' => $vendorDir . '/symfony/dependency-injection/Dumper/PhpDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\XmlDumper' => $vendorDir . '/symfony/dependency-injection/Dumper/XmlDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\YamlDumper' => $vendorDir . '/symfony/dependency-injection/Dumper/YamlDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\EnvVarProcessor' => $vendorDir . '/symfony/dependency-injection/EnvVarProcessor.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\EnvVarProcessorInterface' => $vendorDir . '/symfony/dependency-injection/EnvVarProcessorInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException' => $vendorDir . '/symfony/dependency-injection/Exception/AutowiringFailedException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\BadMethodCallException' => $vendorDir . '/symfony/dependency-injection/Exception/BadMethodCallException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvNotFoundException' => $vendorDir . '/symfony/dependency-injection/Exception/EnvNotFoundException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvParameterException' => $vendorDir . '/symfony/dependency-injection/Exception/EnvParameterException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ExceptionInterface' => $vendorDir . '/symfony/dependency-injection/Exception/ExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException' => $vendorDir . '/symfony/dependency-injection/Exception/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\LogicException' => $vendorDir . '/symfony/dependency-injection/Exception/LogicException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\OutOfBoundsException' => $vendorDir . '/symfony/dependency-injection/Exception/OutOfBoundsException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterCircularReferenceException' => $vendorDir . '/symfony/dependency-injection/Exception/ParameterCircularReferenceException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException' => $vendorDir . '/symfony/dependency-injection/Exception/ParameterNotFoundException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException' => $vendorDir . '/symfony/dependency-injection/Exception/RuntimeException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException' => $vendorDir . '/symfony/dependency-injection/Exception/ServiceCircularReferenceException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException' => $vendorDir . '/symfony/dependency-injection/Exception/ServiceNotFoundException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ExpressionLanguage' => $vendorDir . '/symfony/dependency-injection/ExpressionLanguage.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ExpressionLanguageProvider' => $vendorDir . '/symfony/dependency-injection/ExpressionLanguageProvider.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ConfigurationExtensionInterface' => $vendorDir . '/symfony/dependency-injection/Extension/ConfigurationExtensionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\Extension' => $vendorDir . '/symfony/dependency-injection/Extension/Extension.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface' => $vendorDir . '/symfony/dependency-injection/Extension/ExtensionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\PrependExtensionInterface' => $vendorDir . '/symfony/dependency-injection/Extension/PrependExtensionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\Instantiator\\InstantiatorInterface' => $vendorDir . '/symfony/dependency-injection/LazyProxy/Instantiator/InstantiatorInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\Instantiator\\RealServiceInstantiator' => $vendorDir . '/symfony/dependency-injection/LazyProxy/Instantiator/RealServiceInstantiator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\PhpDumper\\DumperInterface' => $vendorDir . '/symfony/dependency-injection/LazyProxy/PhpDumper/DumperInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\PhpDumper\\NullDumper' => $vendorDir . '/symfony/dependency-injection/LazyProxy/PhpDumper/NullDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\ProxyHelper' => $vendorDir . '/symfony/dependency-injection/LazyProxy/ProxyHelper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\ClosureLoader' => $vendorDir . '/symfony/dependency-injection/Loader/ClosureLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AbstractConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/AbstractConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AbstractServiceConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/AbstractServiceConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AliasConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/AliasConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ContainerConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/ContainerConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\DefaultsConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/DefaultsConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\InlineServiceConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/InlineServiceConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\InstanceofConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/InstanceofConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ParametersConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/ParametersConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\PrototypeConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/PrototypeConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ReferenceConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/ReferenceConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ServiceConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/ServiceConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ServicesConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/ServicesConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AbstractTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/AbstractTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ArgumentTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/ArgumentTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AutoconfigureTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/AutoconfigureTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AutowireTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/AutowireTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\BindTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/BindTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\CallTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/CallTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ClassTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/ClassTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ConfiguratorTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/ConfiguratorTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\DecorateTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/DecorateTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\DeprecateTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/DeprecateTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\FactoryTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/FactoryTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\FileTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/FileTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\LazyTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/LazyTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ParentTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/ParentTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\PropertyTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/PropertyTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\PublicTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/PublicTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ShareTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/ShareTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\SyntheticTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/SyntheticTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\TagTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/TagTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\DirectoryLoader' => $vendorDir . '/symfony/dependency-injection/Loader/DirectoryLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\FileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/FileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\GlobFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/GlobFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\IniFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/IniFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\PhpFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/PhpFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\ProtectedPhpFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/PhpFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\XmlFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/XmlFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\YamlFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/YamlFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Parameter' => $vendorDir . '/symfony/dependency-injection/Parameter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\EnvPlaceholderParameterBag' => $vendorDir . '/symfony/dependency-injection/ParameterBag/EnvPlaceholderParameterBag.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\FrozenParameterBag' => $vendorDir . '/symfony/dependency-injection/ParameterBag/FrozenParameterBag.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\ParameterBag' => $vendorDir . '/symfony/dependency-injection/ParameterBag/ParameterBag.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\ParameterBagInterface' => $vendorDir . '/symfony/dependency-injection/ParameterBag/ParameterBagInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Reference' => $vendorDir . '/symfony/dependency-injection/Reference.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ResettableContainerInterface' => $vendorDir . '/symfony/dependency-injection/ResettableContainerInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ServiceLocator' => $vendorDir . '/symfony/dependency-injection/ServiceLocator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ServiceSubscriberInterface' => $vendorDir . '/symfony/dependency-injection/ServiceSubscriberInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\TaggedContainerInterface' => $vendorDir . '/symfony/dependency-injection/TaggedContainerInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\TypedReference' => $vendorDir . '/symfony/dependency-injection/TypedReference.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Variable' => $vendorDir . '/symfony/dependency-injection/Variable.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Compiler' => $vendorDir . '/symfony/expression-language/Compiler.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Expression' => $vendorDir . '/symfony/expression-language/Expression.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionFunction' => $vendorDir . '/symfony/expression-language/ExpressionFunction.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionFunctionProviderInterface' => $vendorDir . '/symfony/expression-language/ExpressionFunctionProviderInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage' => $vendorDir . '/symfony/expression-language/ExpressionLanguage.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Lexer' => $vendorDir . '/symfony/expression-language/Lexer.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ArgumentsNode' => $vendorDir . '/symfony/expression-language/Node/ArgumentsNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ArrayNode' => $vendorDir . '/symfony/expression-language/Node/ArrayNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\BinaryNode' => $vendorDir . '/symfony/expression-language/Node/BinaryNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ConditionalNode' => $vendorDir . '/symfony/expression-language/Node/ConditionalNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ConstantNode' => $vendorDir . '/symfony/expression-language/Node/ConstantNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\FunctionNode' => $vendorDir . '/symfony/expression-language/Node/FunctionNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\GetAttrNode' => $vendorDir . '/symfony/expression-language/Node/GetAttrNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\NameNode' => $vendorDir . '/symfony/expression-language/Node/NameNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\Node' => $vendorDir . '/symfony/expression-language/Node/Node.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\UnaryNode' => $vendorDir . '/symfony/expression-language/Node/UnaryNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParsedExpression' => $vendorDir . '/symfony/expression-language/ParsedExpression.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Parser' => $vendorDir . '/symfony/expression-language/Parser.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ArrayParserCache' => $vendorDir . '/symfony/expression-language/ParserCache/ArrayParserCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheAdapter' => $vendorDir . '/symfony/expression-language/ParserCache/ParserCacheAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface' => $vendorDir . '/symfony/expression-language/ParserCache/ParserCacheInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SerializedParsedExpression' => $vendorDir . '/symfony/expression-language/SerializedParsedExpression.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError' => $vendorDir . '/symfony/expression-language/SyntaxError.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Token' => $vendorDir . '/symfony/expression-language/Token.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\TokenStream' => $vendorDir . '/symfony/expression-language/TokenStream.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\ExceptionInterface' => $vendorDir . '/symfony/filesystem/Exception/ExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\FileNotFoundException' => $vendorDir . '/symfony/filesystem/Exception/FileNotFoundException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException' => $vendorDir . '/symfony/filesystem/Exception/IOException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOExceptionInterface' => $vendorDir . '/symfony/filesystem/Exception/IOExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Filesystem' => $vendorDir . '/symfony/filesystem/Filesystem.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\LockHandler' => $vendorDir . '/symfony/filesystem/LockHandler.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Command\\LintCommand' => $vendorDir . '/symfony/yaml/Command/LintCommand.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Dumper' => $vendorDir . '/symfony/yaml/Dumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Escaper' => $vendorDir . '/symfony/yaml/Escaper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\DumpException' => $vendorDir . '/symfony/yaml/Exception/DumpException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ExceptionInterface' => $vendorDir . '/symfony/yaml/Exception/ExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException' => $vendorDir . '/symfony/yaml/Exception/ParseException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\RuntimeException' => $vendorDir . '/symfony/yaml/Exception/RuntimeException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Inline' => $vendorDir . '/symfony/yaml/Inline.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Parser' => $vendorDir . '/symfony/yaml/Parser.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Tag\\TaggedValue' => $vendorDir . '/symfony/yaml/Tag/TaggedValue.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Unescaper' => $vendorDir . '/symfony/yaml/Unescaper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Yaml' => $vendorDir . '/symfony/yaml/Yaml.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\Apcu' => $vendorDir . '/symfony/polyfill-apcu/Apcu.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\Ctype' => $vendorDir . '/symfony/polyfill-ctype/Ctype.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\Idn' => $vendorDir . '/symfony/polyfill-intl-idn/Idn.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\Mbstring' => $vendorDir . '/symfony/polyfill-mbstring/Mbstring.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\Php70' => $vendorDir . '/symfony/polyfill-php70/Php70.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\Php72' => $vendorDir . '/symfony/polyfill-php72/Php72.php', - '_PhpScoper5ea00cc67502b\\TypeError' => $vendorDir . '/paragonie/random_compat/lib/error_polyfill.php', -); + $vendorDir . '/composer/autoload_real.php', + 'Composer\\Autoload\\ClassLoader' => $vendorDir . '/composer/ClassLoader.php', + 'Composer\\Autoload\\ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf' => $vendorDir . '/composer/autoload_static.php', + 'MolCarrierInformation' => $baseDir . '/src/Entity/MolCarrierInformation.php', + 'MolOrderFee' => $baseDir . '/src/Entity/MolOrderFee.php', + 'MolPaymentMethod' => $baseDir . '/src/Entity/MolPaymentMethod.php', + 'MolPaymentMethodIssuer' => $baseDir . '/src/Entity/MolPaymentMethodIssuer.php', + 'MollieAjaxModuleFrontController' => $baseDir . '/controllers/front/ajax.php', + 'MollieFailModuleFrontController' => $baseDir . '/controllers/front/fail.php', + 'MolliePayScreenModuleFrontController' => $baseDir . '/controllers/front/payScreen.php', + 'MolliePaymentModuleFrontController' => $baseDir . '/controllers/front/payment.php', + 'MollieQrcodeModuleFrontController' => $baseDir . '/controllers/front/qrcode.php', + 'MollieReturnModuleFrontController' => $baseDir . '/controllers/front/return.php', + 'MollieSuccessModuleFrontController' => $baseDir . '/controllers/front/success.php', + 'MollieWebhookModuleFrontController' => $baseDir . '/controllers/front/webhook.php', + '_PhpScoper5ea00cc67502b\\APCUIterator' => $vendorDir . '/symfony/polyfill-apcu/bootstrap.php', + '_PhpScoper5ea00cc67502b\\ArithmeticError' => $vendorDir . '/symfony/polyfill-php70/Resources/stubs/ArithmeticError.php', + '_PhpScoper5ea00cc67502b\\AssertionError' => $vendorDir . '/symfony/polyfill-php70/Resources/stubs/AssertionError.php', + '_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\CaBundle' => $vendorDir . '/composer/ca-bundle/src/CaBundle.php', + '_PhpScoper5ea00cc67502b\\DivisionByZeroError' => $vendorDir . '/symfony/polyfill-php70/Resources/stubs/DivisionByZeroError.php', + '_PhpScoper5ea00cc67502b\\Error' => $vendorDir . '/paragonie/random_compat/lib/error_polyfill.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Client' => $vendorDir . '/guzzlehttp/guzzle/src/Client.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\ClientInterface' => $vendorDir . '/guzzlehttp/guzzle/src/ClientInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\CookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/CookieJar.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\CookieJarInterface' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\FileCookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\SessionCookieJar' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\SetCookie' => $vendorDir . '/guzzlehttp/guzzle/src/Cookie/SetCookie.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\BadResponseException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/BadResponseException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ClientException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ClientException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ConnectException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ConnectException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\GuzzleException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/GuzzleException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\InvalidArgumentException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\RequestException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/RequestException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\SeekException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/SeekException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ServerException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/ServerException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\TooManyRedirectsException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\TransferException' => $vendorDir . '/guzzlehttp/guzzle/src/Exception/TransferException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\HandlerStack' => $vendorDir . '/guzzlehttp/guzzle/src/HandlerStack.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlFactory' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlFactory.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlFactoryInterface' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlHandler.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlMultiHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\EasyHandle' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/EasyHandle.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\MockHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/MockHandler.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\Proxy' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/Proxy.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\StreamHandler' => $vendorDir . '/guzzlehttp/guzzle/src/Handler/StreamHandler.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\MessageFormatter' => $vendorDir . '/guzzlehttp/guzzle/src/MessageFormatter.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Middleware' => $vendorDir . '/guzzlehttp/guzzle/src/Middleware.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Pool' => $vendorDir . '/guzzlehttp/guzzle/src/Pool.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\PrepareBodyMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\AggregateException' => $vendorDir . '/guzzlehttp/promises/src/AggregateException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\CancellationException' => $vendorDir . '/guzzlehttp/promises/src/CancellationException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\Coroutine' => $vendorDir . '/guzzlehttp/promises/src/Coroutine.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\EachPromise' => $vendorDir . '/guzzlehttp/promises/src/EachPromise.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\FulfilledPromise' => $vendorDir . '/guzzlehttp/promises/src/FulfilledPromise.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\Promise' => $vendorDir . '/guzzlehttp/promises/src/Promise.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\PromiseInterface' => $vendorDir . '/guzzlehttp/promises/src/PromiseInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\PromisorInterface' => $vendorDir . '/guzzlehttp/promises/src/PromisorInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\RejectedPromise' => $vendorDir . '/guzzlehttp/promises/src/RejectedPromise.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\RejectionException' => $vendorDir . '/guzzlehttp/promises/src/RejectionException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\TaskQueue' => $vendorDir . '/guzzlehttp/promises/src/TaskQueue.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\TaskQueueInterface' => $vendorDir . '/guzzlehttp/promises/src/TaskQueueInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\AppendStream' => $vendorDir . '/guzzlehttp/psr7/src/AppendStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\BufferStream' => $vendorDir . '/guzzlehttp/psr7/src/BufferStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\CachingStream' => $vendorDir . '/guzzlehttp/psr7/src/CachingStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\DroppingStream' => $vendorDir . '/guzzlehttp/psr7/src/DroppingStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\FnStream' => $vendorDir . '/guzzlehttp/psr7/src/FnStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\InflateStream' => $vendorDir . '/guzzlehttp/psr7/src/InflateStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\LazyOpenStream' => $vendorDir . '/guzzlehttp/psr7/src/LazyOpenStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\LimitStream' => $vendorDir . '/guzzlehttp/psr7/src/LimitStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\MessageTrait' => $vendorDir . '/guzzlehttp/psr7/src/MessageTrait.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\MultipartStream' => $vendorDir . '/guzzlehttp/psr7/src/MultipartStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\NoSeekStream' => $vendorDir . '/guzzlehttp/psr7/src/NoSeekStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\PumpStream' => $vendorDir . '/guzzlehttp/psr7/src/PumpStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Request' => $vendorDir . '/guzzlehttp/psr7/src/Request.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Response' => $vendorDir . '/guzzlehttp/psr7/src/Response.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Rfc7230' => $vendorDir . '/guzzlehttp/psr7/src/Rfc7230.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\ServerRequest' => $vendorDir . '/guzzlehttp/psr7/src/ServerRequest.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Stream' => $vendorDir . '/guzzlehttp/psr7/src/Stream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\StreamDecoratorTrait' => $vendorDir . '/guzzlehttp/psr7/src/StreamDecoratorTrait.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\StreamWrapper' => $vendorDir . '/guzzlehttp/psr7/src/StreamWrapper.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UploadedFile' => $vendorDir . '/guzzlehttp/psr7/src/UploadedFile.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Uri' => $vendorDir . '/guzzlehttp/psr7/src/Uri.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UriNormalizer' => $vendorDir . '/guzzlehttp/psr7/src/UriNormalizer.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UriResolver' => $vendorDir . '/guzzlehttp/psr7/src/UriResolver.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RedirectMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/RedirectMiddleware.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RequestOptions' => $vendorDir . '/guzzlehttp/guzzle/src/RequestOptions.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RetryMiddleware' => $vendorDir . '/guzzlehttp/guzzle/src/RetryMiddleware.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\TransferStats' => $vendorDir . '/guzzlehttp/guzzle/src/TransferStats.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\UriTemplate' => $vendorDir . '/guzzlehttp/guzzle/src/UriTemplate.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Utils' => $vendorDir . '/guzzlehttp/guzzle/src/Utils.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\CompatibilityChecker' => $vendorDir . '/mollie/mollie-api-php/src/CompatibilityChecker.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ChargebackEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/ChargebackEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CollectionEndpointAbstract' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/CollectionEndpointAbstract.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CustomerEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/CustomerEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CustomerPaymentsEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/CustomerPaymentsEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\EndpointAbstract' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/EndpointAbstract.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\InvoiceEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/InvoiceEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\MandateEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/MandateEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\MethodEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/MethodEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OnboardingEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OnboardingEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OrderEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderLineEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OrderLineEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderPaymentEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OrderPaymentEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderRefundEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OrderRefundEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrganizationEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/OrganizationEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentCaptureEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/PaymentCaptureEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentChargebackEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/PaymentChargebackEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/PaymentEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentRefundEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/PaymentRefundEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PermissionEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/PermissionEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ProfileEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/ProfileEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ProfileMethodEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/ProfileMethodEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\RefundEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/RefundEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\SettlementsEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/SettlementsEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ShipmentEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/ShipmentEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\SubscriptionEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/SubscriptionEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\WalletEndpoint' => $vendorDir . '/mollie/mollie-api-php/src/Endpoints/WalletEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Exceptions\\ApiException' => $vendorDir . '/mollie/mollie-api-php/src/Exceptions/ApiException.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Exceptions\\IncompatiblePlatform' => $vendorDir . '/mollie/mollie-api-php/src/Exceptions/IncompatiblePlatform.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\MollieApiClient' => $vendorDir . '/mollie/mollie-api-php/src/MollieApiClient.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\BaseCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/BaseCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\BaseResource' => $vendorDir . '/mollie/mollie-api-php/src/Resources/BaseResource.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Capture' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Capture.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CaptureCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/CaptureCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Chargeback' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Chargeback.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ChargebackCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/ChargebackCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CurrentProfile' => $vendorDir . '/mollie/mollie-api-php/src/Resources/CurrentProfile.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CursorCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/CursorCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Customer' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Customer.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CustomerCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/CustomerCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Invoice' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Invoice.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\InvoiceCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/InvoiceCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Issuer' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Issuer.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\IssuerCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/IssuerCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Mandate' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Mandate.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MandateCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/MandateCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Method' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Method.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/MethodCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodPrice' => $vendorDir . '/mollie/mollie-api-php/src/Resources/MethodPrice.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodPriceCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/MethodPriceCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Onboarding' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Onboarding.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Order' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Order.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/OrderCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderLine' => $vendorDir . '/mollie/mollie-api-php/src/Resources/OrderLine.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderLineCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/OrderLineCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Organization' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Organization.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrganizationCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/OrganizationCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Payment' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Payment.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\PaymentCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/PaymentCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Permission' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Permission.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\PermissionCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/PermissionCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Profile' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Profile.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ProfileCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/ProfileCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Refund' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Refund.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\RefundCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/RefundCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ResourceFactory' => $vendorDir . '/mollie/mollie-api-php/src/Resources/ResourceFactory.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Settlement' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Settlement.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\SettlementCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/SettlementCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Shipment' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Shipment.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ShipmentCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/ShipmentCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Subscription' => $vendorDir . '/mollie/mollie-api-php/src/Resources/Subscription.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\SubscriptionCollection' => $vendorDir . '/mollie/mollie-api-php/src/Resources/SubscriptionCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\InvoiceStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/InvoiceStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\MandateMethod' => $vendorDir . '/mollie/mollie-api-php/src/Types/MandateMethod.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\MandateStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/MandateStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OnboardingStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/OnboardingStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderLineStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/OrderLineStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderLineType' => $vendorDir . '/mollie/mollie-api-php/src/Types/OrderLineType.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/OrderStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\PaymentMethod' => $vendorDir . '/mollie/mollie-api-php/src/Types/PaymentMethod.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\PaymentStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/PaymentStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\ProfileStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/ProfileStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\RefundStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/RefundStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SequenceType' => $vendorDir . '/mollie/mollie-api-php/src/Types/SequenceType.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SettlementStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/SettlementStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SubscriptionStatus' => $vendorDir . '/mollie/mollie-api-php/src/Types/SubscriptionStatus.php', + '_PhpScoper5ea00cc67502b\\ParseError' => $vendorDir . '/symfony/polyfill-php70/Resources/stubs/ParseError.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Builder' => $vendorDir . '/prestashop/decimal/src/Builder.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Exception\\DivisionByZeroException' => $vendorDir . '/prestashop/decimal/src/Exception/DivisionByZeroException.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Number' => $vendorDir . '/prestashop/decimal/src/Number.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Addition' => $vendorDir . '/prestashop/decimal/src/Operation/Addition.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Comparison' => $vendorDir . '/prestashop/decimal/src/Operation/Comparison.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Division' => $vendorDir . '/prestashop/decimal/src/Operation/Division.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\MagnitudeChange' => $vendorDir . '/prestashop/decimal/src/Operation/MagnitudeChange.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Multiplication' => $vendorDir . '/prestashop/decimal/src/Operation/Multiplication.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Rounding' => $vendorDir . '/prestashop/decimal/src/Operation/Rounding.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Subtraction' => $vendorDir . '/prestashop/decimal/src/Operation/Subtraction.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\AdditionTest' => $vendorDir . '/prestashop/decimal/tests/Operation/AdditionTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\ComparisonTest' => $vendorDir . '/prestashop/decimal/tests/Operation/ComparisonTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\DivisionTest' => $vendorDir . '/prestashop/decimal/tests/Operation/DivisionTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\MagnitudeChangeTest' => $vendorDir . '/prestashop/decimal/tests/Operation/MagnitudeChangeTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\MultiplicationTest' => $vendorDir . '/prestashop/decimal/tests/Operation/MultiplicationTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\RoundingTest' => $vendorDir . '/prestashop/decimal/tests/Operation/RoundingTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\SubtractionTest' => $vendorDir . '/prestashop/decimal/tests/Operation/SubtractionTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\tests\\Unit\\Core\\Decimal\\NumberTest' => $vendorDir . '/prestashop/decimal/tests/NumberTest.php', + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheException' => $vendorDir . '/psr/cache/src/CacheException.php', + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface' => $vendorDir . '/psr/cache/src/CacheItemInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemPoolInterface' => $vendorDir . '/psr/cache/src/CacheItemPoolInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\InvalidArgumentException' => $vendorDir . '/psr/cache/src/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerExceptionInterface' => $vendorDir . '/psr/container/src/ContainerExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => $vendorDir . '/psr/container/src/ContainerInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Container\\NotFoundExceptionInterface' => $vendorDir . '/psr/container/src/NotFoundExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\MessageInterface' => $vendorDir . '/psr/http-message/src/MessageInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\RequestInterface' => $vendorDir . '/psr/http-message/src/RequestInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\ResponseInterface' => $vendorDir . '/psr/http-message/src/ResponseInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\ServerRequestInterface' => $vendorDir . '/psr/http-message/src/ServerRequestInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\StreamInterface' => $vendorDir . '/psr/http-message/src/StreamInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\UploadedFileInterface' => $vendorDir . '/psr/http-message/src/UploadedFileInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\UriInterface' => $vendorDir . '/psr/http-message/src/UriInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\AbstractLogger' => $vendorDir . '/psr/log/Psr/Log/AbstractLogger.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\InvalidArgumentException' => $vendorDir . '/psr/log/Psr/Log/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\LogLevel' => $vendorDir . '/psr/log/Psr/Log/LogLevel.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerAwareInterface' => $vendorDir . '/psr/log/Psr/Log/LoggerAwareInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerAwareTrait' => $vendorDir . '/psr/log/Psr/Log/LoggerAwareTrait.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerInterface' => $vendorDir . '/psr/log/Psr/Log/LoggerInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerTrait' => $vendorDir . '/psr/log/Psr/Log/LoggerTrait.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\NullLogger' => $vendorDir . '/psr/log/Psr/Log/NullLogger.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\DummyTest' => $vendorDir . '/psr/log/Psr/Log/Test/DummyTest.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\LoggerInterfaceTest' => $vendorDir . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\TestLogger' => $vendorDir . '/psr/log/Psr/Log/Test/TestLogger.php', + '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\CacheException' => $vendorDir . '/psr/simple-cache/src/CacheException.php', + '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\CacheInterface' => $vendorDir . '/psr/simple-cache/src/CacheInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\InvalidArgumentException' => $vendorDir . '/psr/simple-cache/src/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\SessionUpdateTimestampHandlerInterface' => $vendorDir . '/symfony/polyfill-php70/Resources/stubs/SessionUpdateTimestampHandlerInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\AbstractAdapter' => $vendorDir . '/symfony/cache/Adapter/AbstractAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\AdapterInterface' => $vendorDir . '/symfony/cache/Adapter/AdapterInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ApcuAdapter' => $vendorDir . '/symfony/cache/Adapter/ApcuAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ArrayAdapter' => $vendorDir . '/symfony/cache/Adapter/ArrayAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ChainAdapter' => $vendorDir . '/symfony/cache/Adapter/ChainAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\DoctrineAdapter' => $vendorDir . '/symfony/cache/Adapter/DoctrineAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\FilesystemAdapter' => $vendorDir . '/symfony/cache/Adapter/FilesystemAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\MemcachedAdapter' => $vendorDir . '/symfony/cache/Adapter/MemcachedAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\NullAdapter' => $vendorDir . '/symfony/cache/Adapter/NullAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PdoAdapter' => $vendorDir . '/symfony/cache/Adapter/PdoAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PhpArrayAdapter' => $vendorDir . '/symfony/cache/Adapter/PhpArrayAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PhpFilesAdapter' => $vendorDir . '/symfony/cache/Adapter/PhpFilesAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ProxyAdapter' => $vendorDir . '/symfony/cache/Adapter/ProxyAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\RedisAdapter' => $vendorDir . '/symfony/cache/Adapter/RedisAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\SimpleCacheAdapter' => $vendorDir . '/symfony/cache/Adapter/SimpleCacheAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TagAwareAdapter' => $vendorDir . '/symfony/cache/Adapter/TagAwareAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TagAwareAdapterInterface' => $vendorDir . '/symfony/cache/Adapter/TagAwareAdapterInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableAdapter' => $vendorDir . '/symfony/cache/Adapter/TraceableAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableAdapterEvent' => $vendorDir . '/symfony/cache/Adapter/TraceableAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableTagAwareAdapter' => $vendorDir . '/symfony/cache/Adapter/TraceableTagAwareAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\CacheItem' => $vendorDir . '/symfony/cache/CacheItem.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\DataCollector\\CacheDataCollector' => $vendorDir . '/symfony/cache/DataCollector/CacheDataCollector.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\DoctrineProvider' => $vendorDir . '/symfony/cache/DoctrineProvider.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\CacheException' => $vendorDir . '/symfony/cache/Exception/CacheException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException' => $vendorDir . '/symfony/cache/Exception/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\PruneableInterface' => $vendorDir . '/symfony/cache/PruneableInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\ResettableInterface' => $vendorDir . '/symfony/cache/ResettableInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\AbstractCache' => $vendorDir . '/symfony/cache/Simple/AbstractCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ApcuCache' => $vendorDir . '/symfony/cache/Simple/ApcuCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ArrayCache' => $vendorDir . '/symfony/cache/Simple/ArrayCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ChainCache' => $vendorDir . '/symfony/cache/Simple/ChainCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\DoctrineCache' => $vendorDir . '/symfony/cache/Simple/DoctrineCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\FilesystemCache' => $vendorDir . '/symfony/cache/Simple/FilesystemCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\MemcachedCache' => $vendorDir . '/symfony/cache/Simple/MemcachedCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\NullCache' => $vendorDir . '/symfony/cache/Simple/NullCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PdoCache' => $vendorDir . '/symfony/cache/Simple/PdoCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PhpArrayCache' => $vendorDir . '/symfony/cache/Simple/PhpArrayCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PhpFilesCache' => $vendorDir . '/symfony/cache/Simple/PhpFilesCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\Psr6Cache' => $vendorDir . '/symfony/cache/Simple/Psr6Cache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\RedisCache' => $vendorDir . '/symfony/cache/Simple/RedisCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\TraceableCache' => $vendorDir . '/symfony/cache/Simple/TraceableCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\TraceableCacheEvent' => $vendorDir . '/symfony/cache/Simple/TraceableCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\AbstractTrait' => $vendorDir . '/symfony/cache/Traits/AbstractTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ApcuTrait' => $vendorDir . '/symfony/cache/Traits/ApcuTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ArrayTrait' => $vendorDir . '/symfony/cache/Traits/ArrayTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\DoctrineTrait' => $vendorDir . '/symfony/cache/Traits/DoctrineTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\FilesystemCommonTrait' => $vendorDir . '/symfony/cache/Traits/FilesystemCommonTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\FilesystemTrait' => $vendorDir . '/symfony/cache/Traits/FilesystemTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\MemcachedTrait' => $vendorDir . '/symfony/cache/Traits/MemcachedTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PdoTrait' => $vendorDir . '/symfony/cache/Traits/PdoTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PhpArrayTrait' => $vendorDir . '/symfony/cache/Traits/PhpArrayTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PhpFilesTrait' => $vendorDir . '/symfony/cache/Traits/PhpFilesTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ProxyTrait' => $vendorDir . '/symfony/cache/Traits/ProxyTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\RedisProxy' => $vendorDir . '/symfony/cache/Traits/RedisProxy.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\RedisTrait' => $vendorDir . '/symfony/cache/Traits/RedisTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCache' => $vendorDir . '/symfony/config/ConfigCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheFactory' => $vendorDir . '/symfony/config/ConfigCacheFactory.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheFactoryInterface' => $vendorDir . '/symfony/config/ConfigCacheFactoryInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheInterface' => $vendorDir . '/symfony/config/ConfigCacheInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ArrayNode' => $vendorDir . '/symfony/config/Definition/ArrayNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BaseNode' => $vendorDir . '/symfony/config/Definition/BaseNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BooleanNode' => $vendorDir . '/symfony/config/Definition/BooleanNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ArrayNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/ArrayNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\BooleanNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/BooleanNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\EnumNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/EnumNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ExprBuilder' => $vendorDir . '/symfony/config/Definition/Builder/ExprBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\FloatNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/FloatNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\IntegerNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/IntegerNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\MergeBuilder' => $vendorDir . '/symfony/config/Definition/Builder/MergeBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeBuilder' => $vendorDir . '/symfony/config/Definition/Builder/NodeBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/NodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeParentInterface' => $vendorDir . '/symfony/config/Definition/Builder/NodeParentInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NormalizationBuilder' => $vendorDir . '/symfony/config/Definition/Builder/NormalizationBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NumericNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/NumericNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ParentNodeDefinitionInterface' => $vendorDir . '/symfony/config/Definition/Builder/ParentNodeDefinitionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ScalarNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/ScalarNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\TreeBuilder' => $vendorDir . '/symfony/config/Definition/Builder/TreeBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ValidationBuilder' => $vendorDir . '/symfony/config/Definition/Builder/ValidationBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\VariableNodeDefinition' => $vendorDir . '/symfony/config/Definition/Builder/VariableNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ConfigurationInterface' => $vendorDir . '/symfony/config/Definition/ConfigurationInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Dumper\\XmlReferenceDumper' => $vendorDir . '/symfony/config/Definition/Dumper/XmlReferenceDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Dumper\\YamlReferenceDumper' => $vendorDir . '/symfony/config/Definition/Dumper/YamlReferenceDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\EnumNode' => $vendorDir . '/symfony/config/Definition/EnumNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\DuplicateKeyException' => $vendorDir . '/symfony/config/Definition/Exception/DuplicateKeyException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\Exception' => $vendorDir . '/symfony/config/Definition/Exception/Exception.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\ForbiddenOverwriteException' => $vendorDir . '/symfony/config/Definition/Exception/ForbiddenOverwriteException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException' => $vendorDir . '/symfony/config/Definition/Exception/InvalidConfigurationException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException' => $vendorDir . '/symfony/config/Definition/Exception/InvalidDefinitionException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException' => $vendorDir . '/symfony/config/Definition/Exception/InvalidTypeException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\UnsetKeyException' => $vendorDir . '/symfony/config/Definition/Exception/UnsetKeyException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\FloatNode' => $vendorDir . '/symfony/config/Definition/FloatNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\IntegerNode' => $vendorDir . '/symfony/config/Definition/IntegerNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\NodeInterface' => $vendorDir . '/symfony/config/Definition/NodeInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\NumericNode' => $vendorDir . '/symfony/config/Definition/NumericNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Processor' => $vendorDir . '/symfony/config/Definition/Processor.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypeNodeInterface' => $vendorDir . '/symfony/config/Definition/PrototypeNodeInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypedArrayNode' => $vendorDir . '/symfony/config/Definition/PrototypedArrayNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ScalarNode' => $vendorDir . '/symfony/config/Definition/ScalarNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\VariableNode' => $vendorDir . '/symfony/config/Definition/VariableNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\DependencyInjection\\ConfigCachePass' => $vendorDir . '/symfony/config/DependencyInjection/ConfigCachePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderImportCircularReferenceException' => $vendorDir . '/symfony/config/Exception/FileLoaderImportCircularReferenceException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderLoadException' => $vendorDir . '/symfony/config/Exception/FileLoaderLoadException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLocatorFileNotFoundException' => $vendorDir . '/symfony/config/Exception/FileLocatorFileNotFoundException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocator' => $vendorDir . '/symfony/config/FileLocator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface' => $vendorDir . '/symfony/config/FileLocatorInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\DelegatingLoader' => $vendorDir . '/symfony/config/Loader/DelegatingLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\FileLoader' => $vendorDir . '/symfony/config/Loader/FileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\GlobFileLoader' => $vendorDir . '/symfony/config/Loader/GlobFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\Loader' => $vendorDir . '/symfony/config/Loader/Loader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface' => $vendorDir . '/symfony/config/Loader/LoaderInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolver' => $vendorDir . '/symfony/config/Loader/LoaderResolver.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface' => $vendorDir . '/symfony/config/Loader/LoaderResolverInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerConfigCache' => $vendorDir . '/symfony/config/ResourceCheckerConfigCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerConfigCacheFactory' => $vendorDir . '/symfony/config/ResourceCheckerConfigCacheFactory.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface' => $vendorDir . '/symfony/config/ResourceCheckerInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ClassExistenceResource' => $vendorDir . '/symfony/config/Resource/ClassExistenceResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ComposerResource' => $vendorDir . '/symfony/config/Resource/ComposerResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\DirectoryResource' => $vendorDir . '/symfony/config/Resource/DirectoryResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileExistenceResource' => $vendorDir . '/symfony/config/Resource/FileExistenceResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileResource' => $vendorDir . '/symfony/config/Resource/FileResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\GlobResource' => $vendorDir . '/symfony/config/Resource/GlobResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionClassResource' => $vendorDir . '/symfony/config/Resource/ReflectionClassResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionMethodHhvmWrapper' => $vendorDir . '/symfony/config/Resource/ReflectionClassResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionParameterHhvmWrapper' => $vendorDir . '/symfony/config/Resource/ReflectionClassResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ResourceInterface' => $vendorDir . '/symfony/config/Resource/ResourceInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\SelfCheckingResourceChecker' => $vendorDir . '/symfony/config/Resource/SelfCheckingResourceChecker.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\SelfCheckingResourceInterface' => $vendorDir . '/symfony/config/Resource/SelfCheckingResourceInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\Exception\\InvalidXmlException' => $vendorDir . '/symfony/config/Util/Exception/InvalidXmlException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\Exception\\XmlParsingException' => $vendorDir . '/symfony/config/Util/Exception/XmlParsingException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\XmlUtils' => $vendorDir . '/symfony/config/Util/XmlUtils.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Alias' => $vendorDir . '/symfony/dependency-injection/Alias.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\ArgumentInterface' => $vendorDir . '/symfony/dependency-injection/Argument/ArgumentInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\BoundArgument' => $vendorDir . '/symfony/dependency-injection/Argument/BoundArgument.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\IteratorArgument' => $vendorDir . '/symfony/dependency-injection/Argument/IteratorArgument.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\RewindableGenerator' => $vendorDir . '/symfony/dependency-injection/Argument/RewindableGenerator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\ServiceClosureArgument' => $vendorDir . '/symfony/dependency-injection/Argument/ServiceClosureArgument.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\TaggedIteratorArgument' => $vendorDir . '/symfony/dependency-injection/Argument/TaggedIteratorArgument.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ChildDefinition' => $vendorDir . '/symfony/dependency-injection/ChildDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AbstractRecursivePass' => $vendorDir . '/symfony/dependency-injection/Compiler/AbstractRecursivePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AnalyzeServiceReferencesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/AnalyzeServiceReferencesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutoAliasServicePass' => $vendorDir . '/symfony/dependency-injection/Compiler/AutoAliasServicePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowireExceptionPass' => $vendorDir . '/symfony/dependency-injection/Compiler/AutowireExceptionPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowirePass' => $vendorDir . '/symfony/dependency-injection/Compiler/AutowirePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowireRequiredMethodsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/AutowireRequiredMethodsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckArgumentsValidityPass' => $vendorDir . '/symfony/dependency-injection/Compiler/CheckArgumentsValidityPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckCircularReferencesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/CheckCircularReferencesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckDefinitionValidityPass' => $vendorDir . '/symfony/dependency-injection/Compiler/CheckDefinitionValidityPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckExceptionOnInvalidReferenceBehaviorPass' => $vendorDir . '/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckReferenceValidityPass' => $vendorDir . '/symfony/dependency-injection/Compiler/CheckReferenceValidityPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\Compiler' => $vendorDir . '/symfony/dependency-injection/Compiler/Compiler.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CompilerPassInterface' => $vendorDir . '/symfony/dependency-injection/Compiler/CompilerPassInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\DecoratorServicePass' => $vendorDir . '/symfony/dependency-injection/Compiler/DecoratorServicePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\DefinitionErrorExceptionPass' => $vendorDir . '/symfony/dependency-injection/Compiler/DefinitionErrorExceptionPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ExtensionCompilerPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ExtensionCompilerPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\FactoryReturnTypePass' => $vendorDir . '/symfony/dependency-injection/Compiler/FactoryReturnTypePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\InlineServiceDefinitionsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/InlineServiceDefinitionsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\LoggingFormatter' => $vendorDir . '/symfony/dependency-injection/Compiler/LoggingFormatter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationContainerBuilder' => $vendorDir . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationParameterBag' => $vendorDir . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationPass' => $vendorDir . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\PassConfig' => $vendorDir . '/symfony/dependency-injection/Compiler/PassConfig.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\PriorityTaggedServiceTrait' => $vendorDir . '/symfony/dependency-injection/Compiler/PriorityTaggedServiceTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RegisterEnvVarProcessorsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RegisterEnvVarProcessorsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RegisterServiceSubscribersPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RegisterServiceSubscribersPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemoveAbstractDefinitionsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RemoveAbstractDefinitionsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemovePrivateAliasesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RemovePrivateAliasesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemoveUnusedDefinitionsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RemoveUnusedDefinitionsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RepeatablePassInterface' => $vendorDir . '/symfony/dependency-injection/Compiler/RepeatablePassInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RepeatedPass' => $vendorDir . '/symfony/dependency-injection/Compiler/RepeatedPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ReplaceAliasByActualDefinitionPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ReplaceAliasByActualDefinitionPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveBindingsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveBindingsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveChildDefinitionsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveChildDefinitionsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveClassPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveClassPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveDefinitionTemplatesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveDefinitionTemplatesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveEnvPlaceholdersPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveEnvPlaceholdersPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveFactoryClassPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveFactoryClassPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveHotPathPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveHotPathPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveInstanceofConditionalsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveInstanceofConditionalsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveInvalidReferencesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveInvalidReferencesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveNamedArgumentsPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveNamedArgumentsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveParameterPlaceHoldersPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveParameterPlaceHoldersPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolvePrivatesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolvePrivatesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveReferencesToAliasesPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveReferencesToAliasesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveServiceSubscribersPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveServiceSubscribersPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveTaggedIteratorArgumentPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ResolveTaggedIteratorArgumentPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceLocatorTagPass' => $vendorDir . '/symfony/dependency-injection/Compiler/ServiceLocatorTagPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraph' => $vendorDir . '/symfony/dependency-injection/Compiler/ServiceReferenceGraph.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraphEdge' => $vendorDir . '/symfony/dependency-injection/Compiler/ServiceReferenceGraphEdge.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraphNode' => $vendorDir . '/symfony/dependency-injection/Compiler/ServiceReferenceGraphNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\AutowireServiceResource' => $vendorDir . '/symfony/dependency-injection/Config/AutowireServiceResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\ContainerParametersResource' => $vendorDir . '/symfony/dependency-injection/Config/ContainerParametersResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\ContainerParametersResourceChecker' => $vendorDir . '/symfony/dependency-injection/Config/ContainerParametersResourceChecker.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Container' => $vendorDir . '/symfony/dependency-injection/Container.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerAwareInterface' => $vendorDir . '/symfony/dependency-injection/ContainerAwareInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerAwareTrait' => $vendorDir . '/symfony/dependency-injection/ContainerAwareTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerBuilder' => $vendorDir . '/symfony/dependency-injection/ContainerBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => $vendorDir . '/symfony/dependency-injection/ContainerInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition' => $vendorDir . '/symfony/dependency-injection/Definition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\DefinitionDecorator' => $vendorDir . '/symfony/dependency-injection/DefinitionDecorator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\Dumper' => $vendorDir . '/symfony/dependency-injection/Dumper/Dumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\DumperInterface' => $vendorDir . '/symfony/dependency-injection/Dumper/DumperInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\GraphvizDumper' => $vendorDir . '/symfony/dependency-injection/Dumper/GraphvizDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\PhpDumper' => $vendorDir . '/symfony/dependency-injection/Dumper/PhpDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\XmlDumper' => $vendorDir . '/symfony/dependency-injection/Dumper/XmlDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\YamlDumper' => $vendorDir . '/symfony/dependency-injection/Dumper/YamlDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\EnvVarProcessor' => $vendorDir . '/symfony/dependency-injection/EnvVarProcessor.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\EnvVarProcessorInterface' => $vendorDir . '/symfony/dependency-injection/EnvVarProcessorInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException' => $vendorDir . '/symfony/dependency-injection/Exception/AutowiringFailedException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\BadMethodCallException' => $vendorDir . '/symfony/dependency-injection/Exception/BadMethodCallException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvNotFoundException' => $vendorDir . '/symfony/dependency-injection/Exception/EnvNotFoundException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvParameterException' => $vendorDir . '/symfony/dependency-injection/Exception/EnvParameterException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ExceptionInterface' => $vendorDir . '/symfony/dependency-injection/Exception/ExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException' => $vendorDir . '/symfony/dependency-injection/Exception/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\LogicException' => $vendorDir . '/symfony/dependency-injection/Exception/LogicException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\OutOfBoundsException' => $vendorDir . '/symfony/dependency-injection/Exception/OutOfBoundsException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterCircularReferenceException' => $vendorDir . '/symfony/dependency-injection/Exception/ParameterCircularReferenceException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException' => $vendorDir . '/symfony/dependency-injection/Exception/ParameterNotFoundException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException' => $vendorDir . '/symfony/dependency-injection/Exception/RuntimeException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException' => $vendorDir . '/symfony/dependency-injection/Exception/ServiceCircularReferenceException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException' => $vendorDir . '/symfony/dependency-injection/Exception/ServiceNotFoundException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ExpressionLanguage' => $vendorDir . '/symfony/dependency-injection/ExpressionLanguage.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ExpressionLanguageProvider' => $vendorDir . '/symfony/dependency-injection/ExpressionLanguageProvider.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ConfigurationExtensionInterface' => $vendorDir . '/symfony/dependency-injection/Extension/ConfigurationExtensionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\Extension' => $vendorDir . '/symfony/dependency-injection/Extension/Extension.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface' => $vendorDir . '/symfony/dependency-injection/Extension/ExtensionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\PrependExtensionInterface' => $vendorDir . '/symfony/dependency-injection/Extension/PrependExtensionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\Instantiator\\InstantiatorInterface' => $vendorDir . '/symfony/dependency-injection/LazyProxy/Instantiator/InstantiatorInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\Instantiator\\RealServiceInstantiator' => $vendorDir . '/symfony/dependency-injection/LazyProxy/Instantiator/RealServiceInstantiator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\PhpDumper\\DumperInterface' => $vendorDir . '/symfony/dependency-injection/LazyProxy/PhpDumper/DumperInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\PhpDumper\\NullDumper' => $vendorDir . '/symfony/dependency-injection/LazyProxy/PhpDumper/NullDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\ProxyHelper' => $vendorDir . '/symfony/dependency-injection/LazyProxy/ProxyHelper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\ClosureLoader' => $vendorDir . '/symfony/dependency-injection/Loader/ClosureLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AbstractConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/AbstractConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AbstractServiceConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/AbstractServiceConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AliasConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/AliasConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ContainerConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/ContainerConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\DefaultsConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/DefaultsConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\InlineServiceConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/InlineServiceConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\InstanceofConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/InstanceofConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ParametersConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/ParametersConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\PrototypeConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/PrototypeConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ReferenceConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/ReferenceConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ServiceConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/ServiceConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ServicesConfigurator' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/ServicesConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AbstractTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/AbstractTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ArgumentTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/ArgumentTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AutoconfigureTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/AutoconfigureTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AutowireTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/AutowireTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\BindTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/BindTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\CallTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/CallTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ClassTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/ClassTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ConfiguratorTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/ConfiguratorTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\DecorateTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/DecorateTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\DeprecateTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/DeprecateTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\FactoryTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/FactoryTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\FileTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/FileTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\LazyTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/LazyTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ParentTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/ParentTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\PropertyTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/PropertyTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\PublicTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/PublicTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ShareTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/ShareTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\SyntheticTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/SyntheticTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\TagTrait' => $vendorDir . '/symfony/dependency-injection/Loader/Configurator/Traits/TagTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\DirectoryLoader' => $vendorDir . '/symfony/dependency-injection/Loader/DirectoryLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\FileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/FileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\GlobFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/GlobFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\IniFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/IniFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\PhpFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/PhpFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\ProtectedPhpFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/PhpFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\XmlFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/XmlFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\YamlFileLoader' => $vendorDir . '/symfony/dependency-injection/Loader/YamlFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Parameter' => $vendorDir . '/symfony/dependency-injection/Parameter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\EnvPlaceholderParameterBag' => $vendorDir . '/symfony/dependency-injection/ParameterBag/EnvPlaceholderParameterBag.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\FrozenParameterBag' => $vendorDir . '/symfony/dependency-injection/ParameterBag/FrozenParameterBag.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\ParameterBag' => $vendorDir . '/symfony/dependency-injection/ParameterBag/ParameterBag.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\ParameterBagInterface' => $vendorDir . '/symfony/dependency-injection/ParameterBag/ParameterBagInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Reference' => $vendorDir . '/symfony/dependency-injection/Reference.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ResettableContainerInterface' => $vendorDir . '/symfony/dependency-injection/ResettableContainerInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ServiceLocator' => $vendorDir . '/symfony/dependency-injection/ServiceLocator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ServiceSubscriberInterface' => $vendorDir . '/symfony/dependency-injection/ServiceSubscriberInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\TaggedContainerInterface' => $vendorDir . '/symfony/dependency-injection/TaggedContainerInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\TypedReference' => $vendorDir . '/symfony/dependency-injection/TypedReference.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Variable' => $vendorDir . '/symfony/dependency-injection/Variable.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Compiler' => $vendorDir . '/symfony/expression-language/Compiler.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Expression' => $vendorDir . '/symfony/expression-language/Expression.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionFunction' => $vendorDir . '/symfony/expression-language/ExpressionFunction.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionFunctionProviderInterface' => $vendorDir . '/symfony/expression-language/ExpressionFunctionProviderInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage' => $vendorDir . '/symfony/expression-language/ExpressionLanguage.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Lexer' => $vendorDir . '/symfony/expression-language/Lexer.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ArgumentsNode' => $vendorDir . '/symfony/expression-language/Node/ArgumentsNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ArrayNode' => $vendorDir . '/symfony/expression-language/Node/ArrayNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\BinaryNode' => $vendorDir . '/symfony/expression-language/Node/BinaryNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ConditionalNode' => $vendorDir . '/symfony/expression-language/Node/ConditionalNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ConstantNode' => $vendorDir . '/symfony/expression-language/Node/ConstantNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\FunctionNode' => $vendorDir . '/symfony/expression-language/Node/FunctionNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\GetAttrNode' => $vendorDir . '/symfony/expression-language/Node/GetAttrNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\NameNode' => $vendorDir . '/symfony/expression-language/Node/NameNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\Node' => $vendorDir . '/symfony/expression-language/Node/Node.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\UnaryNode' => $vendorDir . '/symfony/expression-language/Node/UnaryNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParsedExpression' => $vendorDir . '/symfony/expression-language/ParsedExpression.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Parser' => $vendorDir . '/symfony/expression-language/Parser.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ArrayParserCache' => $vendorDir . '/symfony/expression-language/ParserCache/ArrayParserCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheAdapter' => $vendorDir . '/symfony/expression-language/ParserCache/ParserCacheAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface' => $vendorDir . '/symfony/expression-language/ParserCache/ParserCacheInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SerializedParsedExpression' => $vendorDir . '/symfony/expression-language/SerializedParsedExpression.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError' => $vendorDir . '/symfony/expression-language/SyntaxError.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Token' => $vendorDir . '/symfony/expression-language/Token.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\TokenStream' => $vendorDir . '/symfony/expression-language/TokenStream.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\ExceptionInterface' => $vendorDir . '/symfony/filesystem/Exception/ExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\FileNotFoundException' => $vendorDir . '/symfony/filesystem/Exception/FileNotFoundException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException' => $vendorDir . '/symfony/filesystem/Exception/IOException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOExceptionInterface' => $vendorDir . '/symfony/filesystem/Exception/IOExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Filesystem' => $vendorDir . '/symfony/filesystem/Filesystem.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\LockHandler' => $vendorDir . '/symfony/filesystem/LockHandler.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Command\\LintCommand' => $vendorDir . '/symfony/yaml/Command/LintCommand.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Dumper' => $vendorDir . '/symfony/yaml/Dumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Escaper' => $vendorDir . '/symfony/yaml/Escaper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\DumpException' => $vendorDir . '/symfony/yaml/Exception/DumpException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ExceptionInterface' => $vendorDir . '/symfony/yaml/Exception/ExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException' => $vendorDir . '/symfony/yaml/Exception/ParseException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\RuntimeException' => $vendorDir . '/symfony/yaml/Exception/RuntimeException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Inline' => $vendorDir . '/symfony/yaml/Inline.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Parser' => $vendorDir . '/symfony/yaml/Parser.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Tag\\TaggedValue' => $vendorDir . '/symfony/yaml/Tag/TaggedValue.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Unescaper' => $vendorDir . '/symfony/yaml/Unescaper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Yaml' => $vendorDir . '/symfony/yaml/Yaml.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\Apcu' => $vendorDir . '/symfony/polyfill-apcu/Apcu.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\Ctype' => $vendorDir . '/symfony/polyfill-ctype/Ctype.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\Idn' => $vendorDir . '/symfony/polyfill-intl-idn/Idn.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\Mbstring' => $vendorDir . '/symfony/polyfill-mbstring/Mbstring.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\Php70' => $vendorDir . '/symfony/polyfill-php70/Php70.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\Php72' => $vendorDir . '/symfony/polyfill-php72/Php72.php', + '_PhpScoper5ea00cc67502b\\TypeError' => $vendorDir . '/paragonie/random_compat/lib/error_polyfill.php', +); diff --git a/vendor/composer/autoload_files.php b/vendor/composer/autoload_files.php index 680e94132..b64894c61 100644 --- a/vendor/composer/autoload_files.php +++ b/vendor/composer/autoload_files.php @@ -1,20 +1,20 @@ - $vendorDir . '/symfony/polyfill-ctype/bootstrap.php', - '5255c38a0faeba867671b61dfda6d864' => $vendorDir . '/paragonie/random_compat/lib/random.php', - '32dcc8afd4335739640db7d200c1971d' => $vendorDir . '/symfony/polyfill-apcu/bootstrap.php', - '023d27dca8066ef29e6739335ea73bad' => $vendorDir . '/symfony/polyfill-php70/bootstrap.php', - '7b11c4dc42b3b3023073cb14e519683c' => $vendorDir . '/ralouphie/getallheaders/src/getallheaders.php', - '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php', - '25072dd6e2470089de65ae7bf11d3109' => $vendorDir . '/symfony/polyfill-php72/bootstrap.php', - 'c964ee0ededf28c96ebd9db5099ef910' => $vendorDir . '/guzzlehttp/promises/src/functions_include.php', - 'a0edc8309cc5e1d60e3047b5df6b7052' => $vendorDir . '/guzzlehttp/psr7/src/functions_include.php', - 'f598d06aa772fa33d905e87be6398fb1' => $vendorDir . '/symfony/polyfill-intl-idn/bootstrap.php', - '37a3dc5111fe8f707ab4c132ef1dbc62' => $vendorDir . '/guzzlehttp/guzzle/src/functions_include.php', -); + $vendorDir . '/symfony/polyfill-ctype/bootstrap.php', + '5255c38a0faeba867671b61dfda6d864' => $vendorDir . '/paragonie/random_compat/lib/random.php', + '32dcc8afd4335739640db7d200c1971d' => $vendorDir . '/symfony/polyfill-apcu/bootstrap.php', + '023d27dca8066ef29e6739335ea73bad' => $vendorDir . '/symfony/polyfill-php70/bootstrap.php', + '7b11c4dc42b3b3023073cb14e519683c' => $vendorDir . '/ralouphie/getallheaders/src/getallheaders.php', + '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php', + '25072dd6e2470089de65ae7bf11d3109' => $vendorDir . '/symfony/polyfill-php72/bootstrap.php', + 'c964ee0ededf28c96ebd9db5099ef910' => $vendorDir . '/guzzlehttp/promises/src/functions_include.php', + 'a0edc8309cc5e1d60e3047b5df6b7052' => $vendorDir . '/guzzlehttp/psr7/src/functions_include.php', + 'f598d06aa772fa33d905e87be6398fb1' => $vendorDir . '/symfony/polyfill-intl-idn/bootstrap.php', + '37a3dc5111fe8f707ab4c132ef1dbc62' => $vendorDir . '/guzzlehttp/guzzle/src/functions_include.php', +); diff --git a/vendor/composer/autoload_namespaces.php b/vendor/composer/autoload_namespaces.php index b7fc0125d..d19daeafd 100644 --- a/vendor/composer/autoload_namespaces.php +++ b/vendor/composer/autoload_namespaces.php @@ -1,9 +1,9 @@ - array($vendorDir . '/symfony/polyfill-php72'), - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\' => array($vendorDir . '/symfony/polyfill-php70'), - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\' => array($vendorDir . '/symfony/polyfill-mbstring'), - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\' => array($vendorDir . '/symfony/polyfill-intl-idn'), - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\' => array($vendorDir . '/symfony/polyfill-ctype'), - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\' => array($vendorDir . '/symfony/polyfill-apcu'), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\' => array($vendorDir . '/symfony/yaml'), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\' => array($vendorDir . '/symfony/filesystem'), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\' => array($vendorDir . '/symfony/expression-language'), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\' => array($vendorDir . '/symfony/dependency-injection'), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\' => array($vendorDir . '/symfony/config'), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\' => array($vendorDir . '/symfony/cache'), - '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\' => array($vendorDir . '/psr/simple-cache/src'), - '_PhpScoper5ea00cc67502b\\Psr\\Log\\' => array($vendorDir . '/psr/log/Psr/Log'), - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\' => array($vendorDir . '/psr/http-message/src'), - '_PhpScoper5ea00cc67502b\\Psr\\Container\\' => array($vendorDir . '/psr/container/src'), - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\' => array($vendorDir . '/psr/cache/src'), - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\' => array($vendorDir . '/prestashop/decimal/src'), - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\' => array($vendorDir . '/mollie/mollie-api-php/src'), - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\' => array($vendorDir . '/guzzlehttp/psr7/src'), - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\' => array($vendorDir . '/guzzlehttp/promises/src'), - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\' => array($vendorDir . '/guzzlehttp/guzzle/src'), - '_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\' => array($vendorDir . '/composer/ca-bundle/src'), - 'Mollie\\' => array($baseDir . '/src'), -); + array($vendorDir . '/symfony/polyfill-php72'), + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\' => array($vendorDir . '/symfony/polyfill-php70'), + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\' => array($vendorDir . '/symfony/polyfill-mbstring'), + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\' => array($vendorDir . '/symfony/polyfill-intl-idn'), + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\' => array($vendorDir . '/symfony/polyfill-ctype'), + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\' => array($vendorDir . '/symfony/polyfill-apcu'), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\' => array($vendorDir . '/symfony/yaml'), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\' => array($vendorDir . '/symfony/filesystem'), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\' => array($vendorDir . '/symfony/expression-language'), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\' => array($vendorDir . '/symfony/dependency-injection'), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\' => array($vendorDir . '/symfony/config'), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\' => array($vendorDir . '/symfony/cache'), + '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\' => array($vendorDir . '/psr/simple-cache/src'), + '_PhpScoper5ea00cc67502b\\Psr\\Log\\' => array($vendorDir . '/psr/log/Psr/Log'), + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\' => array($vendorDir . '/psr/http-message/src'), + '_PhpScoper5ea00cc67502b\\Psr\\Container\\' => array($vendorDir . '/psr/container/src'), + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\' => array($vendorDir . '/psr/cache/src'), + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\' => array($vendorDir . '/prestashop/decimal/src'), + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\' => array($vendorDir . '/mollie/mollie-api-php/src'), + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\' => array($vendorDir . '/guzzlehttp/psr7/src'), + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\' => array($vendorDir . '/guzzlehttp/promises/src'), + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\' => array($vendorDir . '/guzzlehttp/guzzle/src'), + '_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\' => array($vendorDir . '/composer/ca-bundle/src'), + 'Mollie\\' => array($baseDir . '/src'), +); diff --git a/vendor/composer/autoload_real.php b/vendor/composer/autoload_real.php index e5f91332c..f2329488a 100644 --- a/vendor/composer/autoload_real.php +++ b/vendor/composer/autoload_real.php @@ -1,70 +1,70 @@ -= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); - if ($useStaticLoader) { - require_once __DIR__ . '/autoload_static.php'; - - call_user_func(\Composer\Autoload\ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf::getInitializer($loader)); - } else { - $map = require __DIR__ . '/autoload_namespaces.php'; - foreach ($map as $namespace => $path) { - $loader->set($namespace, $path); - } - - $map = require __DIR__ . '/autoload_psr4.php'; - foreach ($map as $namespace => $path) { - $loader->setPsr4($namespace, $path); - } - - $classMap = require __DIR__ . '/autoload_classmap.php'; - if ($classMap) { - $loader->addClassMap($classMap); - } - } - - $loader->register(true); - - if ($useStaticLoader) { - $includeFiles = Composer\Autoload\ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf::$files; - } else { - $includeFiles = require __DIR__ . '/autoload_files.php'; - } - foreach ($includeFiles as $fileIdentifier => $file) { - composerRequirec2b58ae5c6462b5d003510a1194fafcf($fileIdentifier, $file); - } - - return $loader; - } -} - -function composerRequirec2b58ae5c6462b5d003510a1194fafcf($fileIdentifier, $file) -{ - if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { - require $file; - - $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true; - } -} += 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); + if ($useStaticLoader) { + require_once __DIR__ . '/autoload_static.php'; + + call_user_func(\Composer\Autoload\ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf::getInitializer($loader)); + } else { + $map = require __DIR__ . '/autoload_namespaces.php'; + foreach ($map as $namespace => $path) { + $loader->set($namespace, $path); + } + + $map = require __DIR__ . '/autoload_psr4.php'; + foreach ($map as $namespace => $path) { + $loader->setPsr4($namespace, $path); + } + + $classMap = require __DIR__ . '/autoload_classmap.php'; + if ($classMap) { + $loader->addClassMap($classMap); + } + } + + $loader->register(true); + + if ($useStaticLoader) { + $includeFiles = Composer\Autoload\ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf::$files; + } else { + $includeFiles = require __DIR__ . '/autoload_files.php'; + } + foreach ($includeFiles as $fileIdentifier => $file) { + composerRequirec2b58ae5c6462b5d003510a1194fafcf($fileIdentifier, $file); + } + + return $loader; + } +} + +function composerRequirec2b58ae5c6462b5d003510a1194fafcf($fileIdentifier, $file) +{ + if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { + require $file; + + $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true; + } +} diff --git a/vendor/composer/autoload_static.php b/vendor/composer/autoload_static.php index 39b76e9bf..9bdad6206 100644 --- a/vendor/composer/autoload_static.php +++ b/vendor/composer/autoload_static.php @@ -1,726 +1,726 @@ - __DIR__ . '/..' . '/symfony/polyfill-ctype/bootstrap.php', - '5255c38a0faeba867671b61dfda6d864' => __DIR__ . '/..' . '/paragonie/random_compat/lib/random.php', - '32dcc8afd4335739640db7d200c1971d' => __DIR__ . '/..' . '/symfony/polyfill-apcu/bootstrap.php', - '023d27dca8066ef29e6739335ea73bad' => __DIR__ . '/..' . '/symfony/polyfill-php70/bootstrap.php', - '7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php', - '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php', - '25072dd6e2470089de65ae7bf11d3109' => __DIR__ . '/..' . '/symfony/polyfill-php72/bootstrap.php', - 'c964ee0ededf28c96ebd9db5099ef910' => __DIR__ . '/..' . '/guzzlehttp/promises/src/functions_include.php', - 'a0edc8309cc5e1d60e3047b5df6b7052' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/functions_include.php', - 'f598d06aa772fa33d905e87be6398fb1' => __DIR__ . '/..' . '/symfony/polyfill-intl-idn/bootstrap.php', - '37a3dc5111fe8f707ab4c132ef1dbc62' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/functions_include.php', - ); - - public static $prefixLengthsPsr4 = array ( - '_' => - array ( - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\' => 47, - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\' => 47, - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\' => 50, - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\' => 50, - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\' => 47, - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\' => 46, - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\' => 47, - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\' => 53, - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\' => 61, - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\' => 62, - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\' => 49, - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\' => 48, - '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\' => 40, - '_PhpScoper5ea00cc67502b\\Psr\\Log\\' => 32, - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\' => 41, - '_PhpScoper5ea00cc67502b\\Psr\\Container\\' => 38, - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\' => 34, - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\' => 43, - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\' => 35, - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\' => 40, - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\' => 43, - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\' => 35, - '_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\' => 42, - ), - 'M' => - array ( - 'Mollie\\' => 7, - ), - ); - - public static $prefixDirsPsr4 = array ( - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/polyfill-php72', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/polyfill-php70', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/polyfill-mbstring', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/polyfill-intl-idn', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/polyfill-ctype', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/polyfill-apcu', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/yaml', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/filesystem', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/expression-language', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/dependency-injection', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/config', - ), - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\' => - array ( - 0 => __DIR__ . '/..' . '/symfony/cache', - ), - '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\' => - array ( - 0 => __DIR__ . '/..' . '/psr/simple-cache/src', - ), - '_PhpScoper5ea00cc67502b\\Psr\\Log\\' => - array ( - 0 => __DIR__ . '/..' . '/psr/log/Psr/Log', - ), - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\' => - array ( - 0 => __DIR__ . '/..' . '/psr/http-message/src', - ), - '_PhpScoper5ea00cc67502b\\Psr\\Container\\' => - array ( - 0 => __DIR__ . '/..' . '/psr/container/src', - ), - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\' => - array ( - 0 => __DIR__ . '/..' . '/psr/cache/src', - ), - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\' => - array ( - 0 => __DIR__ . '/..' . '/prestashop/decimal/src', - ), - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\' => - array ( - 0 => __DIR__ . '/..' . '/mollie/mollie-api-php/src', - ), - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\' => - array ( - 0 => __DIR__ . '/..' . '/guzzlehttp/psr7/src', - ), - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\' => - array ( - 0 => __DIR__ . '/..' . '/guzzlehttp/promises/src', - ), - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\' => - array ( - 0 => __DIR__ . '/..' . '/guzzlehttp/guzzle/src', - ), - '_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\' => - array ( - 0 => __DIR__ . '/..' . '/composer/ca-bundle/src', - ), - 'Mollie\\' => - array ( - 0 => __DIR__ . '/../..' . '/src', - ), - ); - - public static $classMap = array ( - 'ComposerAutoloaderInitc2b58ae5c6462b5d003510a1194fafcf' => __DIR__ . '/..' . '/composer/autoload_real.php', - 'Composer\\Autoload\\ClassLoader' => __DIR__ . '/..' . '/composer/ClassLoader.php', - 'Composer\\Autoload\\ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf' => __DIR__ . '/..' . '/composer/autoload_static.php', - 'MolCarrierInformation' => __DIR__ . '/../..' . '/src/Entity/MolCarrierInformation.php', - 'MolOrderFee' => __DIR__ . '/../..' . '/src/Entity/MolOrderFee.php', - 'MolPaymentMethod' => __DIR__ . '/../..' . '/src/Entity/MolPaymentMethod.php', - 'MolPaymentMethodIssuer' => __DIR__ . '/../..' . '/src/Entity/MolPaymentMethodIssuer.php', - 'MollieAjaxModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/ajax.php', - 'MollieFailModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/fail.php', - 'MolliePayScreenModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/payScreen.php', - 'MolliePaymentModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/payment.php', - 'MollieQrcodeModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/qrcode.php', - 'MollieReturnModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/return.php', - 'MollieSuccessModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/success.php', - 'MollieWebhookModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/webhook.php', - '_PhpScoper5ea00cc67502b\\APCUIterator' => __DIR__ . '/..' . '/symfony/polyfill-apcu/bootstrap.php', - '_PhpScoper5ea00cc67502b\\ArithmeticError' => __DIR__ . '/..' . '/symfony/polyfill-php70/Resources/stubs/ArithmeticError.php', - '_PhpScoper5ea00cc67502b\\AssertionError' => __DIR__ . '/..' . '/symfony/polyfill-php70/Resources/stubs/AssertionError.php', - '_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\CaBundle' => __DIR__ . '/..' . '/composer/ca-bundle/src/CaBundle.php', - '_PhpScoper5ea00cc67502b\\DivisionByZeroError' => __DIR__ . '/..' . '/symfony/polyfill-php70/Resources/stubs/DivisionByZeroError.php', - '_PhpScoper5ea00cc67502b\\Error' => __DIR__ . '/..' . '/paragonie/random_compat/lib/error_polyfill.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Client' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Client.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\ClientInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/ClientInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\CookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/CookieJar.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\CookieJarInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\FileCookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\SessionCookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\SetCookie' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/SetCookie.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\BadResponseException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/BadResponseException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ClientException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ClientException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ConnectException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ConnectException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\GuzzleException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/GuzzleException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\InvalidArgumentException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\RequestException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/RequestException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\SeekException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/SeekException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ServerException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ServerException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\TooManyRedirectsException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\TransferException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/TransferException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\HandlerStack' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/HandlerStack.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlFactory' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlFactory.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlFactoryInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlHandler.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlMultiHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\EasyHandle' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/EasyHandle.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\MockHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/MockHandler.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\Proxy' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/Proxy.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\StreamHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/StreamHandler.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\MessageFormatter' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/MessageFormatter.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Middleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Middleware.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Pool' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Pool.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\PrepareBodyMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\AggregateException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/AggregateException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\CancellationException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/CancellationException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\Coroutine' => __DIR__ . '/..' . '/guzzlehttp/promises/src/Coroutine.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\EachPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/EachPromise.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\FulfilledPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/FulfilledPromise.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\Promise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/Promise.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\PromiseInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/PromiseInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\PromisorInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/PromisorInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\RejectedPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/RejectedPromise.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\RejectionException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/RejectionException.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\TaskQueue' => __DIR__ . '/..' . '/guzzlehttp/promises/src/TaskQueue.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\TaskQueueInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/TaskQueueInterface.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\AppendStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/AppendStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\BufferStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/BufferStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\CachingStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/CachingStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\DroppingStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/DroppingStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\FnStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/FnStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\InflateStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/InflateStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\LazyOpenStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/LazyOpenStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\LimitStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/LimitStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\MessageTrait' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/MessageTrait.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\MultipartStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/MultipartStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\NoSeekStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/NoSeekStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\PumpStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/PumpStream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Request' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Request.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Response' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Response.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Rfc7230' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Rfc7230.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\ServerRequest' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/ServerRequest.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Stream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Stream.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\StreamDecoratorTrait' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/StreamDecoratorTrait.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\StreamWrapper' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/StreamWrapper.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UploadedFile' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UploadedFile.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Uri' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Uri.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UriNormalizer' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UriNormalizer.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UriResolver' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UriResolver.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RedirectMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RedirectMiddleware.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RequestOptions' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RequestOptions.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RetryMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RetryMiddleware.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\TransferStats' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/TransferStats.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\UriTemplate' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/UriTemplate.php', - '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Utils' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Utils.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\CompatibilityChecker' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/CompatibilityChecker.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ChargebackEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/ChargebackEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CollectionEndpointAbstract' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/CollectionEndpointAbstract.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CustomerEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/CustomerEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CustomerPaymentsEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/CustomerPaymentsEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\EndpointAbstract' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/EndpointAbstract.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\InvoiceEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/InvoiceEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\MandateEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/MandateEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\MethodEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/MethodEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OnboardingEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OnboardingEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OrderEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderLineEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OrderLineEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderPaymentEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OrderPaymentEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderRefundEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OrderRefundEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrganizationEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OrganizationEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentCaptureEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/PaymentCaptureEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentChargebackEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/PaymentChargebackEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/PaymentEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentRefundEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/PaymentRefundEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PermissionEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/PermissionEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ProfileEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/ProfileEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ProfileMethodEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/ProfileMethodEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\RefundEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/RefundEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\SettlementsEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/SettlementsEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ShipmentEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/ShipmentEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\SubscriptionEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/SubscriptionEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\WalletEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/WalletEndpoint.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Exceptions\\ApiException' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Exceptions/ApiException.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Exceptions\\IncompatiblePlatform' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Exceptions/IncompatiblePlatform.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\MollieApiClient' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/MollieApiClient.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\BaseCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/BaseCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\BaseResource' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/BaseResource.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Capture' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Capture.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CaptureCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/CaptureCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Chargeback' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Chargeback.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ChargebackCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/ChargebackCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CurrentProfile' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/CurrentProfile.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CursorCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/CursorCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Customer' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Customer.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CustomerCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/CustomerCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Invoice' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Invoice.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\InvoiceCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/InvoiceCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Issuer' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Issuer.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\IssuerCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/IssuerCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Mandate' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Mandate.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MandateCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/MandateCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Method' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Method.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/MethodCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodPrice' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/MethodPrice.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodPriceCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/MethodPriceCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Onboarding' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Onboarding.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Order' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Order.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/OrderCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderLine' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/OrderLine.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderLineCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/OrderLineCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Organization' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Organization.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrganizationCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/OrganizationCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Payment' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Payment.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\PaymentCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/PaymentCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Permission' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Permission.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\PermissionCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/PermissionCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Profile' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Profile.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ProfileCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/ProfileCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Refund' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Refund.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\RefundCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/RefundCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ResourceFactory' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/ResourceFactory.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Settlement' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Settlement.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\SettlementCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/SettlementCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Shipment' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Shipment.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ShipmentCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/ShipmentCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Subscription' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Subscription.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\SubscriptionCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/SubscriptionCollection.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\InvoiceStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/InvoiceStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\MandateMethod' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/MandateMethod.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\MandateStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/MandateStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OnboardingStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/OnboardingStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderLineStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/OrderLineStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderLineType' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/OrderLineType.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/OrderStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\PaymentMethod' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/PaymentMethod.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\PaymentStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/PaymentStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\ProfileStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/ProfileStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\RefundStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/RefundStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SequenceType' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/SequenceType.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SettlementStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/SettlementStatus.php', - '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SubscriptionStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/SubscriptionStatus.php', - '_PhpScoper5ea00cc67502b\\ParseError' => __DIR__ . '/..' . '/symfony/polyfill-php70/Resources/stubs/ParseError.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Builder' => __DIR__ . '/..' . '/prestashop/decimal/src/Builder.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Exception\\DivisionByZeroException' => __DIR__ . '/..' . '/prestashop/decimal/src/Exception/DivisionByZeroException.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Number' => __DIR__ . '/..' . '/prestashop/decimal/src/Number.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Addition' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Addition.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Comparison' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Comparison.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Division' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Division.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\MagnitudeChange' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/MagnitudeChange.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Multiplication' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Multiplication.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Rounding' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Rounding.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Subtraction' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Subtraction.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\AdditionTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/AdditionTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\ComparisonTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/ComparisonTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\DivisionTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/DivisionTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\MagnitudeChangeTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/MagnitudeChangeTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\MultiplicationTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/MultiplicationTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\RoundingTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/RoundingTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\SubtractionTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/SubtractionTest.php', - '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\tests\\Unit\\Core\\Decimal\\NumberTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/NumberTest.php', - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheException' => __DIR__ . '/..' . '/psr/cache/src/CacheException.php', - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface' => __DIR__ . '/..' . '/psr/cache/src/CacheItemInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemPoolInterface' => __DIR__ . '/..' . '/psr/cache/src/CacheItemPoolInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Cache\\InvalidArgumentException' => __DIR__ . '/..' . '/psr/cache/src/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerExceptionInterface' => __DIR__ . '/..' . '/psr/container/src/ContainerExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => __DIR__ . '/..' . '/psr/container/src/ContainerInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Container\\NotFoundExceptionInterface' => __DIR__ . '/..' . '/psr/container/src/NotFoundExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\MessageInterface' => __DIR__ . '/..' . '/psr/http-message/src/MessageInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\RequestInterface' => __DIR__ . '/..' . '/psr/http-message/src/RequestInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\ResponseInterface' => __DIR__ . '/..' . '/psr/http-message/src/ResponseInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\ServerRequestInterface' => __DIR__ . '/..' . '/psr/http-message/src/ServerRequestInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\StreamInterface' => __DIR__ . '/..' . '/psr/http-message/src/StreamInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\UploadedFileInterface' => __DIR__ . '/..' . '/psr/http-message/src/UploadedFileInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\UriInterface' => __DIR__ . '/..' . '/psr/http-message/src/UriInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\AbstractLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/AbstractLogger.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\InvalidArgumentException' => __DIR__ . '/..' . '/psr/log/Psr/Log/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\LogLevel' => __DIR__ . '/..' . '/psr/log/Psr/Log/LogLevel.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerAwareInterface' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerAwareInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerAwareTrait' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerAwareTrait.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerInterface' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerTrait' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerTrait.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\NullLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/NullLogger.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\DummyTest' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/DummyTest.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\LoggerInterfaceTest' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', - '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\TestLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/TestLogger.php', - '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\CacheException' => __DIR__ . '/..' . '/psr/simple-cache/src/CacheException.php', - '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\CacheInterface' => __DIR__ . '/..' . '/psr/simple-cache/src/CacheInterface.php', - '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\InvalidArgumentException' => __DIR__ . '/..' . '/psr/simple-cache/src/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\SessionUpdateTimestampHandlerInterface' => __DIR__ . '/..' . '/symfony/polyfill-php70/Resources/stubs/SessionUpdateTimestampHandlerInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\AbstractAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/AbstractAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\AdapterInterface' => __DIR__ . '/..' . '/symfony/cache/Adapter/AdapterInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ApcuAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/ApcuAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ArrayAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/ArrayAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ChainAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/ChainAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\DoctrineAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/DoctrineAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\FilesystemAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/FilesystemAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\MemcachedAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/MemcachedAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\NullAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/NullAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PdoAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/PdoAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PhpArrayAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/PhpArrayAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PhpFilesAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/PhpFilesAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ProxyAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/ProxyAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\RedisAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/RedisAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\SimpleCacheAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/SimpleCacheAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TagAwareAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/TagAwareAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TagAwareAdapterInterface' => __DIR__ . '/..' . '/symfony/cache/Adapter/TagAwareAdapterInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/TraceableAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableAdapterEvent' => __DIR__ . '/..' . '/symfony/cache/Adapter/TraceableAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableTagAwareAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/TraceableTagAwareAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\CacheItem' => __DIR__ . '/..' . '/symfony/cache/CacheItem.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\DataCollector\\CacheDataCollector' => __DIR__ . '/..' . '/symfony/cache/DataCollector/CacheDataCollector.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\DoctrineProvider' => __DIR__ . '/..' . '/symfony/cache/DoctrineProvider.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\CacheException' => __DIR__ . '/..' . '/symfony/cache/Exception/CacheException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException' => __DIR__ . '/..' . '/symfony/cache/Exception/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\PruneableInterface' => __DIR__ . '/..' . '/symfony/cache/PruneableInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\ResettableInterface' => __DIR__ . '/..' . '/symfony/cache/ResettableInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\AbstractCache' => __DIR__ . '/..' . '/symfony/cache/Simple/AbstractCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ApcuCache' => __DIR__ . '/..' . '/symfony/cache/Simple/ApcuCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ArrayCache' => __DIR__ . '/..' . '/symfony/cache/Simple/ArrayCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ChainCache' => __DIR__ . '/..' . '/symfony/cache/Simple/ChainCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\DoctrineCache' => __DIR__ . '/..' . '/symfony/cache/Simple/DoctrineCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\FilesystemCache' => __DIR__ . '/..' . '/symfony/cache/Simple/FilesystemCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\MemcachedCache' => __DIR__ . '/..' . '/symfony/cache/Simple/MemcachedCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\NullCache' => __DIR__ . '/..' . '/symfony/cache/Simple/NullCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PdoCache' => __DIR__ . '/..' . '/symfony/cache/Simple/PdoCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PhpArrayCache' => __DIR__ . '/..' . '/symfony/cache/Simple/PhpArrayCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PhpFilesCache' => __DIR__ . '/..' . '/symfony/cache/Simple/PhpFilesCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\Psr6Cache' => __DIR__ . '/..' . '/symfony/cache/Simple/Psr6Cache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\RedisCache' => __DIR__ . '/..' . '/symfony/cache/Simple/RedisCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\TraceableCache' => __DIR__ . '/..' . '/symfony/cache/Simple/TraceableCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\TraceableCacheEvent' => __DIR__ . '/..' . '/symfony/cache/Simple/TraceableCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\AbstractTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/AbstractTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ApcuTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/ApcuTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ArrayTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/ArrayTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\DoctrineTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/DoctrineTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\FilesystemCommonTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/FilesystemCommonTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\FilesystemTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/FilesystemTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\MemcachedTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/MemcachedTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PdoTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/PdoTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PhpArrayTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/PhpArrayTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PhpFilesTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/PhpFilesTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ProxyTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/ProxyTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\RedisProxy' => __DIR__ . '/..' . '/symfony/cache/Traits/RedisProxy.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\RedisTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/RedisTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCache' => __DIR__ . '/..' . '/symfony/config/ConfigCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheFactory' => __DIR__ . '/..' . '/symfony/config/ConfigCacheFactory.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheFactoryInterface' => __DIR__ . '/..' . '/symfony/config/ConfigCacheFactoryInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheInterface' => __DIR__ . '/..' . '/symfony/config/ConfigCacheInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ArrayNode' => __DIR__ . '/..' . '/symfony/config/Definition/ArrayNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BaseNode' => __DIR__ . '/..' . '/symfony/config/Definition/BaseNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BooleanNode' => __DIR__ . '/..' . '/symfony/config/Definition/BooleanNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ArrayNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/ArrayNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\BooleanNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/BooleanNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\EnumNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/EnumNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ExprBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/ExprBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\FloatNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/FloatNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\IntegerNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/IntegerNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\MergeBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/MergeBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/NodeBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/NodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeParentInterface' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/NodeParentInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NormalizationBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/NormalizationBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NumericNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/NumericNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ParentNodeDefinitionInterface' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/ParentNodeDefinitionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ScalarNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/ScalarNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\TreeBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/TreeBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ValidationBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/ValidationBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\VariableNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/VariableNodeDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ConfigurationInterface' => __DIR__ . '/..' . '/symfony/config/Definition/ConfigurationInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Dumper\\XmlReferenceDumper' => __DIR__ . '/..' . '/symfony/config/Definition/Dumper/XmlReferenceDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Dumper\\YamlReferenceDumper' => __DIR__ . '/..' . '/symfony/config/Definition/Dumper/YamlReferenceDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\EnumNode' => __DIR__ . '/..' . '/symfony/config/Definition/EnumNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\DuplicateKeyException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/DuplicateKeyException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\Exception' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/Exception.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\ForbiddenOverwriteException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/ForbiddenOverwriteException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/InvalidConfigurationException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/InvalidDefinitionException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/InvalidTypeException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\UnsetKeyException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/UnsetKeyException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\FloatNode' => __DIR__ . '/..' . '/symfony/config/Definition/FloatNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\IntegerNode' => __DIR__ . '/..' . '/symfony/config/Definition/IntegerNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\NodeInterface' => __DIR__ . '/..' . '/symfony/config/Definition/NodeInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\NumericNode' => __DIR__ . '/..' . '/symfony/config/Definition/NumericNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Processor' => __DIR__ . '/..' . '/symfony/config/Definition/Processor.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypeNodeInterface' => __DIR__ . '/..' . '/symfony/config/Definition/PrototypeNodeInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypedArrayNode' => __DIR__ . '/..' . '/symfony/config/Definition/PrototypedArrayNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ScalarNode' => __DIR__ . '/..' . '/symfony/config/Definition/ScalarNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\VariableNode' => __DIR__ . '/..' . '/symfony/config/Definition/VariableNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\DependencyInjection\\ConfigCachePass' => __DIR__ . '/..' . '/symfony/config/DependencyInjection/ConfigCachePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderImportCircularReferenceException' => __DIR__ . '/..' . '/symfony/config/Exception/FileLoaderImportCircularReferenceException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderLoadException' => __DIR__ . '/..' . '/symfony/config/Exception/FileLoaderLoadException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLocatorFileNotFoundException' => __DIR__ . '/..' . '/symfony/config/Exception/FileLocatorFileNotFoundException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocator' => __DIR__ . '/..' . '/symfony/config/FileLocator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface' => __DIR__ . '/..' . '/symfony/config/FileLocatorInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\DelegatingLoader' => __DIR__ . '/..' . '/symfony/config/Loader/DelegatingLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\FileLoader' => __DIR__ . '/..' . '/symfony/config/Loader/FileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\GlobFileLoader' => __DIR__ . '/..' . '/symfony/config/Loader/GlobFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\Loader' => __DIR__ . '/..' . '/symfony/config/Loader/Loader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface' => __DIR__ . '/..' . '/symfony/config/Loader/LoaderInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolver' => __DIR__ . '/..' . '/symfony/config/Loader/LoaderResolver.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface' => __DIR__ . '/..' . '/symfony/config/Loader/LoaderResolverInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerConfigCache' => __DIR__ . '/..' . '/symfony/config/ResourceCheckerConfigCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerConfigCacheFactory' => __DIR__ . '/..' . '/symfony/config/ResourceCheckerConfigCacheFactory.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface' => __DIR__ . '/..' . '/symfony/config/ResourceCheckerInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ClassExistenceResource' => __DIR__ . '/..' . '/symfony/config/Resource/ClassExistenceResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ComposerResource' => __DIR__ . '/..' . '/symfony/config/Resource/ComposerResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\DirectoryResource' => __DIR__ . '/..' . '/symfony/config/Resource/DirectoryResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileExistenceResource' => __DIR__ . '/..' . '/symfony/config/Resource/FileExistenceResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileResource' => __DIR__ . '/..' . '/symfony/config/Resource/FileResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\GlobResource' => __DIR__ . '/..' . '/symfony/config/Resource/GlobResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionClassResource' => __DIR__ . '/..' . '/symfony/config/Resource/ReflectionClassResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionMethodHhvmWrapper' => __DIR__ . '/..' . '/symfony/config/Resource/ReflectionClassResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionParameterHhvmWrapper' => __DIR__ . '/..' . '/symfony/config/Resource/ReflectionClassResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ResourceInterface' => __DIR__ . '/..' . '/symfony/config/Resource/ResourceInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\SelfCheckingResourceChecker' => __DIR__ . '/..' . '/symfony/config/Resource/SelfCheckingResourceChecker.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\SelfCheckingResourceInterface' => __DIR__ . '/..' . '/symfony/config/Resource/SelfCheckingResourceInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\Exception\\InvalidXmlException' => __DIR__ . '/..' . '/symfony/config/Util/Exception/InvalidXmlException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\Exception\\XmlParsingException' => __DIR__ . '/..' . '/symfony/config/Util/Exception/XmlParsingException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\XmlUtils' => __DIR__ . '/..' . '/symfony/config/Util/XmlUtils.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Alias' => __DIR__ . '/..' . '/symfony/dependency-injection/Alias.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\ArgumentInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/ArgumentInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\BoundArgument' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/BoundArgument.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\IteratorArgument' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/IteratorArgument.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\RewindableGenerator' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/RewindableGenerator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\ServiceClosureArgument' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/ServiceClosureArgument.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\TaggedIteratorArgument' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/TaggedIteratorArgument.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ChildDefinition' => __DIR__ . '/..' . '/symfony/dependency-injection/ChildDefinition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AbstractRecursivePass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AbstractRecursivePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AnalyzeServiceReferencesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AnalyzeServiceReferencesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutoAliasServicePass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AutoAliasServicePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowireExceptionPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AutowireExceptionPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowirePass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AutowirePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowireRequiredMethodsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AutowireRequiredMethodsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckArgumentsValidityPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CheckArgumentsValidityPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckCircularReferencesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CheckCircularReferencesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckDefinitionValidityPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CheckDefinitionValidityPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckExceptionOnInvalidReferenceBehaviorPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckReferenceValidityPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CheckReferenceValidityPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\Compiler' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/Compiler.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CompilerPassInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CompilerPassInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\DecoratorServicePass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/DecoratorServicePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\DefinitionErrorExceptionPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/DefinitionErrorExceptionPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ExtensionCompilerPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ExtensionCompilerPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\FactoryReturnTypePass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/FactoryReturnTypePass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\InlineServiceDefinitionsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/InlineServiceDefinitionsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\LoggingFormatter' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/LoggingFormatter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationContainerBuilder' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationParameterBag' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\PassConfig' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/PassConfig.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\PriorityTaggedServiceTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/PriorityTaggedServiceTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RegisterEnvVarProcessorsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RegisterEnvVarProcessorsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RegisterServiceSubscribersPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RegisterServiceSubscribersPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemoveAbstractDefinitionsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RemoveAbstractDefinitionsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemovePrivateAliasesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RemovePrivateAliasesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemoveUnusedDefinitionsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RemoveUnusedDefinitionsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RepeatablePassInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RepeatablePassInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RepeatedPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RepeatedPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ReplaceAliasByActualDefinitionPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ReplaceAliasByActualDefinitionPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveBindingsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveBindingsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveChildDefinitionsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveChildDefinitionsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveClassPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveClassPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveDefinitionTemplatesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveDefinitionTemplatesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveEnvPlaceholdersPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveEnvPlaceholdersPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveFactoryClassPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveFactoryClassPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveHotPathPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveHotPathPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveInstanceofConditionalsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveInstanceofConditionalsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveInvalidReferencesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveInvalidReferencesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveNamedArgumentsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveNamedArgumentsPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveParameterPlaceHoldersPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveParameterPlaceHoldersPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolvePrivatesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolvePrivatesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveReferencesToAliasesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveReferencesToAliasesPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveServiceSubscribersPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveServiceSubscribersPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveTaggedIteratorArgumentPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveTaggedIteratorArgumentPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceLocatorTagPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ServiceLocatorTagPass.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraph' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ServiceReferenceGraph.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraphEdge' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ServiceReferenceGraphEdge.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraphNode' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ServiceReferenceGraphNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\AutowireServiceResource' => __DIR__ . '/..' . '/symfony/dependency-injection/Config/AutowireServiceResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\ContainerParametersResource' => __DIR__ . '/..' . '/symfony/dependency-injection/Config/ContainerParametersResource.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\ContainerParametersResourceChecker' => __DIR__ . '/..' . '/symfony/dependency-injection/Config/ContainerParametersResourceChecker.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Container' => __DIR__ . '/..' . '/symfony/dependency-injection/Container.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerAwareInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/ContainerAwareInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerAwareTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/ContainerAwareTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerBuilder' => __DIR__ . '/..' . '/symfony/dependency-injection/ContainerBuilder.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/ContainerInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition' => __DIR__ . '/..' . '/symfony/dependency-injection/Definition.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\DefinitionDecorator' => __DIR__ . '/..' . '/symfony/dependency-injection/DefinitionDecorator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\Dumper' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/Dumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\DumperInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/DumperInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\GraphvizDumper' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/GraphvizDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\PhpDumper' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/PhpDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\XmlDumper' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/XmlDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\YamlDumper' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/YamlDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\EnvVarProcessor' => __DIR__ . '/..' . '/symfony/dependency-injection/EnvVarProcessor.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\EnvVarProcessorInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/EnvVarProcessorInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/AutowiringFailedException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\BadMethodCallException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/BadMethodCallException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvNotFoundException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/EnvNotFoundException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvParameterException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/EnvParameterException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ExceptionInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/ExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/InvalidArgumentException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\LogicException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/LogicException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\OutOfBoundsException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/OutOfBoundsException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterCircularReferenceException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/ParameterCircularReferenceException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/ParameterNotFoundException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/RuntimeException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/ServiceCircularReferenceException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/ServiceNotFoundException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ExpressionLanguage' => __DIR__ . '/..' . '/symfony/dependency-injection/ExpressionLanguage.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ExpressionLanguageProvider' => __DIR__ . '/..' . '/symfony/dependency-injection/ExpressionLanguageProvider.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ConfigurationExtensionInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Extension/ConfigurationExtensionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\Extension' => __DIR__ . '/..' . '/symfony/dependency-injection/Extension/Extension.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Extension/ExtensionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\PrependExtensionInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Extension/PrependExtensionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\Instantiator\\InstantiatorInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/LazyProxy/Instantiator/InstantiatorInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\Instantiator\\RealServiceInstantiator' => __DIR__ . '/..' . '/symfony/dependency-injection/LazyProxy/Instantiator/RealServiceInstantiator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\PhpDumper\\DumperInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/LazyProxy/PhpDumper/DumperInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\PhpDumper\\NullDumper' => __DIR__ . '/..' . '/symfony/dependency-injection/LazyProxy/PhpDumper/NullDumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\ProxyHelper' => __DIR__ . '/..' . '/symfony/dependency-injection/LazyProxy/ProxyHelper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\ClosureLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/ClosureLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AbstractConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/AbstractConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AbstractServiceConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/AbstractServiceConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AliasConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/AliasConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ContainerConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/ContainerConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\DefaultsConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/DefaultsConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\InlineServiceConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/InlineServiceConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\InstanceofConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/InstanceofConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ParametersConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/ParametersConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\PrototypeConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/PrototypeConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ReferenceConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/ReferenceConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ServiceConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/ServiceConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ServicesConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/ServicesConfigurator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AbstractTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/AbstractTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ArgumentTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/ArgumentTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AutoconfigureTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/AutoconfigureTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AutowireTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/AutowireTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\BindTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/BindTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\CallTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/CallTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ClassTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/ClassTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ConfiguratorTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/ConfiguratorTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\DecorateTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/DecorateTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\DeprecateTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/DeprecateTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\FactoryTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/FactoryTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\FileTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/FileTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\LazyTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/LazyTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ParentTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/ParentTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\PropertyTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/PropertyTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\PublicTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/PublicTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ShareTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/ShareTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\SyntheticTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/SyntheticTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\TagTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/TagTrait.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\DirectoryLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/DirectoryLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\FileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/FileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\GlobFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/GlobFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\IniFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/IniFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\PhpFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/PhpFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\ProtectedPhpFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/PhpFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\XmlFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/XmlFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\YamlFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/YamlFileLoader.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Parameter' => __DIR__ . '/..' . '/symfony/dependency-injection/Parameter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\EnvPlaceholderParameterBag' => __DIR__ . '/..' . '/symfony/dependency-injection/ParameterBag/EnvPlaceholderParameterBag.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\FrozenParameterBag' => __DIR__ . '/..' . '/symfony/dependency-injection/ParameterBag/FrozenParameterBag.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\ParameterBag' => __DIR__ . '/..' . '/symfony/dependency-injection/ParameterBag/ParameterBag.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\ParameterBagInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/ParameterBag/ParameterBagInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Reference' => __DIR__ . '/..' . '/symfony/dependency-injection/Reference.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ResettableContainerInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/ResettableContainerInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ServiceLocator' => __DIR__ . '/..' . '/symfony/dependency-injection/ServiceLocator.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ServiceSubscriberInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/ServiceSubscriberInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\TaggedContainerInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/TaggedContainerInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\TypedReference' => __DIR__ . '/..' . '/symfony/dependency-injection/TypedReference.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Variable' => __DIR__ . '/..' . '/symfony/dependency-injection/Variable.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Compiler' => __DIR__ . '/..' . '/symfony/expression-language/Compiler.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Expression' => __DIR__ . '/..' . '/symfony/expression-language/Expression.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionFunction' => __DIR__ . '/..' . '/symfony/expression-language/ExpressionFunction.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionFunctionProviderInterface' => __DIR__ . '/..' . '/symfony/expression-language/ExpressionFunctionProviderInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage' => __DIR__ . '/..' . '/symfony/expression-language/ExpressionLanguage.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Lexer' => __DIR__ . '/..' . '/symfony/expression-language/Lexer.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ArgumentsNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/ArgumentsNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ArrayNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/ArrayNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\BinaryNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/BinaryNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ConditionalNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/ConditionalNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ConstantNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/ConstantNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\FunctionNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/FunctionNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\GetAttrNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/GetAttrNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\NameNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/NameNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\Node' => __DIR__ . '/..' . '/symfony/expression-language/Node/Node.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\UnaryNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/UnaryNode.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParsedExpression' => __DIR__ . '/..' . '/symfony/expression-language/ParsedExpression.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Parser' => __DIR__ . '/..' . '/symfony/expression-language/Parser.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ArrayParserCache' => __DIR__ . '/..' . '/symfony/expression-language/ParserCache/ArrayParserCache.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheAdapter' => __DIR__ . '/..' . '/symfony/expression-language/ParserCache/ParserCacheAdapter.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface' => __DIR__ . '/..' . '/symfony/expression-language/ParserCache/ParserCacheInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SerializedParsedExpression' => __DIR__ . '/..' . '/symfony/expression-language/SerializedParsedExpression.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError' => __DIR__ . '/..' . '/symfony/expression-language/SyntaxError.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Token' => __DIR__ . '/..' . '/symfony/expression-language/Token.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\TokenStream' => __DIR__ . '/..' . '/symfony/expression-language/TokenStream.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\ExceptionInterface' => __DIR__ . '/..' . '/symfony/filesystem/Exception/ExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\FileNotFoundException' => __DIR__ . '/..' . '/symfony/filesystem/Exception/FileNotFoundException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException' => __DIR__ . '/..' . '/symfony/filesystem/Exception/IOException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOExceptionInterface' => __DIR__ . '/..' . '/symfony/filesystem/Exception/IOExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Filesystem' => __DIR__ . '/..' . '/symfony/filesystem/Filesystem.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\LockHandler' => __DIR__ . '/..' . '/symfony/filesystem/LockHandler.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Command\\LintCommand' => __DIR__ . '/..' . '/symfony/yaml/Command/LintCommand.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Dumper' => __DIR__ . '/..' . '/symfony/yaml/Dumper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Escaper' => __DIR__ . '/..' . '/symfony/yaml/Escaper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\DumpException' => __DIR__ . '/..' . '/symfony/yaml/Exception/DumpException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ExceptionInterface' => __DIR__ . '/..' . '/symfony/yaml/Exception/ExceptionInterface.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException' => __DIR__ . '/..' . '/symfony/yaml/Exception/ParseException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\RuntimeException' => __DIR__ . '/..' . '/symfony/yaml/Exception/RuntimeException.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Inline' => __DIR__ . '/..' . '/symfony/yaml/Inline.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Parser' => __DIR__ . '/..' . '/symfony/yaml/Parser.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Tag\\TaggedValue' => __DIR__ . '/..' . '/symfony/yaml/Tag/TaggedValue.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Unescaper' => __DIR__ . '/..' . '/symfony/yaml/Unescaper.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Yaml' => __DIR__ . '/..' . '/symfony/yaml/Yaml.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\Apcu' => __DIR__ . '/..' . '/symfony/polyfill-apcu/Apcu.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\Ctype' => __DIR__ . '/..' . '/symfony/polyfill-ctype/Ctype.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\Idn' => __DIR__ . '/..' . '/symfony/polyfill-intl-idn/Idn.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\Mbstring' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/Mbstring.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\Php70' => __DIR__ . '/..' . '/symfony/polyfill-php70/Php70.php', - '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\Php72' => __DIR__ . '/..' . '/symfony/polyfill-php72/Php72.php', - '_PhpScoper5ea00cc67502b\\TypeError' => __DIR__ . '/..' . '/paragonie/random_compat/lib/error_polyfill.php', - ); - - public static function getInitializer(ClassLoader $loader) - { - return \Closure::bind(function () use ($loader) { - $loader->prefixLengthsPsr4 = ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf::$prefixLengthsPsr4; - $loader->prefixDirsPsr4 = ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf::$prefixDirsPsr4; - $loader->classMap = ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf::$classMap; - - }, null, ClassLoader::class); - } -} + __DIR__ . '/..' . '/symfony/polyfill-ctype/bootstrap.php', + '5255c38a0faeba867671b61dfda6d864' => __DIR__ . '/..' . '/paragonie/random_compat/lib/random.php', + '32dcc8afd4335739640db7d200c1971d' => __DIR__ . '/..' . '/symfony/polyfill-apcu/bootstrap.php', + '023d27dca8066ef29e6739335ea73bad' => __DIR__ . '/..' . '/symfony/polyfill-php70/bootstrap.php', + '7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php', + '0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php', + '25072dd6e2470089de65ae7bf11d3109' => __DIR__ . '/..' . '/symfony/polyfill-php72/bootstrap.php', + 'c964ee0ededf28c96ebd9db5099ef910' => __DIR__ . '/..' . '/guzzlehttp/promises/src/functions_include.php', + 'a0edc8309cc5e1d60e3047b5df6b7052' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/functions_include.php', + 'f598d06aa772fa33d905e87be6398fb1' => __DIR__ . '/..' . '/symfony/polyfill-intl-idn/bootstrap.php', + '37a3dc5111fe8f707ab4c132ef1dbc62' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/functions_include.php', + ); + + public static $prefixLengthsPsr4 = array ( + '_' => + array ( + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\' => 47, + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\' => 47, + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\' => 50, + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\' => 50, + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\' => 47, + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\' => 46, + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\' => 47, + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\' => 53, + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\' => 61, + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\' => 62, + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\' => 49, + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\' => 48, + '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\' => 40, + '_PhpScoper5ea00cc67502b\\Psr\\Log\\' => 32, + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\' => 41, + '_PhpScoper5ea00cc67502b\\Psr\\Container\\' => 38, + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\' => 34, + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\' => 43, + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\' => 35, + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\' => 40, + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\' => 43, + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\' => 35, + '_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\' => 42, + ), + 'M' => + array ( + 'Mollie\\' => 7, + ), + ); + + public static $prefixDirsPsr4 = array ( + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/polyfill-php72', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/polyfill-php70', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/polyfill-mbstring', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/polyfill-intl-idn', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/polyfill-ctype', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/polyfill-apcu', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/yaml', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/filesystem', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/expression-language', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/dependency-injection', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/config', + ), + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\' => + array ( + 0 => __DIR__ . '/..' . '/symfony/cache', + ), + '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\' => + array ( + 0 => __DIR__ . '/..' . '/psr/simple-cache/src', + ), + '_PhpScoper5ea00cc67502b\\Psr\\Log\\' => + array ( + 0 => __DIR__ . '/..' . '/psr/log/Psr/Log', + ), + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\' => + array ( + 0 => __DIR__ . '/..' . '/psr/http-message/src', + ), + '_PhpScoper5ea00cc67502b\\Psr\\Container\\' => + array ( + 0 => __DIR__ . '/..' . '/psr/container/src', + ), + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\' => + array ( + 0 => __DIR__ . '/..' . '/psr/cache/src', + ), + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\' => + array ( + 0 => __DIR__ . '/..' . '/prestashop/decimal/src', + ), + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\' => + array ( + 0 => __DIR__ . '/..' . '/mollie/mollie-api-php/src', + ), + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\' => + array ( + 0 => __DIR__ . '/..' . '/guzzlehttp/psr7/src', + ), + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\' => + array ( + 0 => __DIR__ . '/..' . '/guzzlehttp/promises/src', + ), + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\' => + array ( + 0 => __DIR__ . '/..' . '/guzzlehttp/guzzle/src', + ), + '_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\' => + array ( + 0 => __DIR__ . '/..' . '/composer/ca-bundle/src', + ), + 'Mollie\\' => + array ( + 0 => __DIR__ . '/../..' . '/src', + ), + ); + + public static $classMap = array ( + 'ComposerAutoloaderInitc2b58ae5c6462b5d003510a1194fafcf' => __DIR__ . '/..' . '/composer/autoload_real.php', + 'Composer\\Autoload\\ClassLoader' => __DIR__ . '/..' . '/composer/ClassLoader.php', + 'Composer\\Autoload\\ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf' => __DIR__ . '/..' . '/composer/autoload_static.php', + 'MolCarrierInformation' => __DIR__ . '/../..' . '/src/Entity/MolCarrierInformation.php', + 'MolOrderFee' => __DIR__ . '/../..' . '/src/Entity/MolOrderFee.php', + 'MolPaymentMethod' => __DIR__ . '/../..' . '/src/Entity/MolPaymentMethod.php', + 'MolPaymentMethodIssuer' => __DIR__ . '/../..' . '/src/Entity/MolPaymentMethodIssuer.php', + 'MollieAjaxModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/ajax.php', + 'MollieFailModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/fail.php', + 'MolliePayScreenModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/payScreen.php', + 'MolliePaymentModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/payment.php', + 'MollieQrcodeModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/qrcode.php', + 'MollieReturnModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/return.php', + 'MollieSuccessModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/success.php', + 'MollieWebhookModuleFrontController' => __DIR__ . '/../..' . '/controllers/front/webhook.php', + '_PhpScoper5ea00cc67502b\\APCUIterator' => __DIR__ . '/..' . '/symfony/polyfill-apcu/bootstrap.php', + '_PhpScoper5ea00cc67502b\\ArithmeticError' => __DIR__ . '/..' . '/symfony/polyfill-php70/Resources/stubs/ArithmeticError.php', + '_PhpScoper5ea00cc67502b\\AssertionError' => __DIR__ . '/..' . '/symfony/polyfill-php70/Resources/stubs/AssertionError.php', + '_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\CaBundle' => __DIR__ . '/..' . '/composer/ca-bundle/src/CaBundle.php', + '_PhpScoper5ea00cc67502b\\DivisionByZeroError' => __DIR__ . '/..' . '/symfony/polyfill-php70/Resources/stubs/DivisionByZeroError.php', + '_PhpScoper5ea00cc67502b\\Error' => __DIR__ . '/..' . '/paragonie/random_compat/lib/error_polyfill.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Client' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Client.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\ClientInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/ClientInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\CookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/CookieJar.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\CookieJarInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\FileCookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/FileCookieJar.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\SessionCookieJar' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Cookie\\SetCookie' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Cookie/SetCookie.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\BadResponseException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/BadResponseException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ClientException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ClientException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ConnectException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ConnectException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\GuzzleException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/GuzzleException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\InvalidArgumentException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\RequestException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/RequestException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\SeekException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/SeekException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\ServerException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/ServerException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\TooManyRedirectsException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/TooManyRedirectsException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Exception\\TransferException' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Exception/TransferException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\HandlerStack' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/HandlerStack.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlFactory' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlFactory.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlFactoryInterface' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlHandler.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\CurlMultiHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\EasyHandle' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/EasyHandle.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\MockHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/MockHandler.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\Proxy' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/Proxy.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Handler\\StreamHandler' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Handler/StreamHandler.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\MessageFormatter' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/MessageFormatter.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Middleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Middleware.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Pool' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Pool.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\PrepareBodyMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\AggregateException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/AggregateException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\CancellationException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/CancellationException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\Coroutine' => __DIR__ . '/..' . '/guzzlehttp/promises/src/Coroutine.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\EachPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/EachPromise.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\FulfilledPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/FulfilledPromise.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\Promise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/Promise.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\PromiseInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/PromiseInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\PromisorInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/PromisorInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\RejectedPromise' => __DIR__ . '/..' . '/guzzlehttp/promises/src/RejectedPromise.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\RejectionException' => __DIR__ . '/..' . '/guzzlehttp/promises/src/RejectionException.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\TaskQueue' => __DIR__ . '/..' . '/guzzlehttp/promises/src/TaskQueue.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\TaskQueueInterface' => __DIR__ . '/..' . '/guzzlehttp/promises/src/TaskQueueInterface.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\AppendStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/AppendStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\BufferStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/BufferStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\CachingStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/CachingStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\DroppingStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/DroppingStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\FnStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/FnStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\InflateStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/InflateStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\LazyOpenStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/LazyOpenStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\LimitStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/LimitStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\MessageTrait' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/MessageTrait.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\MultipartStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/MultipartStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\NoSeekStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/NoSeekStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\PumpStream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/PumpStream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Request' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Request.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Response' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Response.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Rfc7230' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Rfc7230.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\ServerRequest' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/ServerRequest.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Stream' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Stream.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\StreamDecoratorTrait' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/StreamDecoratorTrait.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\StreamWrapper' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/StreamWrapper.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UploadedFile' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UploadedFile.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\Uri' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/Uri.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UriNormalizer' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UriNormalizer.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\UriResolver' => __DIR__ . '/..' . '/guzzlehttp/psr7/src/UriResolver.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RedirectMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RedirectMiddleware.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RequestOptions' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RequestOptions.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\RetryMiddleware' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/RetryMiddleware.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\TransferStats' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/TransferStats.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\UriTemplate' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/UriTemplate.php', + '_PhpScoper5ea00cc67502b\\GuzzleHttp\\Utils' => __DIR__ . '/..' . '/guzzlehttp/guzzle/src/Utils.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\CompatibilityChecker' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/CompatibilityChecker.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ChargebackEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/ChargebackEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CollectionEndpointAbstract' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/CollectionEndpointAbstract.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CustomerEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/CustomerEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\CustomerPaymentsEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/CustomerPaymentsEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\EndpointAbstract' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/EndpointAbstract.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\InvoiceEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/InvoiceEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\MandateEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/MandateEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\MethodEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/MethodEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OnboardingEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OnboardingEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OrderEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderLineEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OrderLineEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderPaymentEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OrderPaymentEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrderRefundEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OrderRefundEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\OrganizationEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/OrganizationEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentCaptureEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/PaymentCaptureEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentChargebackEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/PaymentChargebackEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/PaymentEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PaymentRefundEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/PaymentRefundEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\PermissionEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/PermissionEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ProfileEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/ProfileEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ProfileMethodEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/ProfileMethodEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\RefundEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/RefundEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\SettlementsEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/SettlementsEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\ShipmentEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/ShipmentEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\SubscriptionEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/SubscriptionEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Endpoints\\WalletEndpoint' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Endpoints/WalletEndpoint.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Exceptions\\ApiException' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Exceptions/ApiException.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Exceptions\\IncompatiblePlatform' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Exceptions/IncompatiblePlatform.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\MollieApiClient' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/MollieApiClient.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\BaseCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/BaseCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\BaseResource' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/BaseResource.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Capture' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Capture.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CaptureCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/CaptureCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Chargeback' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Chargeback.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ChargebackCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/ChargebackCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CurrentProfile' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/CurrentProfile.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CursorCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/CursorCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Customer' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Customer.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\CustomerCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/CustomerCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Invoice' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Invoice.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\InvoiceCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/InvoiceCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Issuer' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Issuer.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\IssuerCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/IssuerCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Mandate' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Mandate.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MandateCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/MandateCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Method' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Method.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/MethodCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodPrice' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/MethodPrice.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\MethodPriceCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/MethodPriceCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Onboarding' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Onboarding.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Order' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Order.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/OrderCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderLine' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/OrderLine.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrderLineCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/OrderLineCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Organization' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Organization.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\OrganizationCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/OrganizationCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Payment' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Payment.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\PaymentCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/PaymentCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Permission' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Permission.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\PermissionCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/PermissionCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Profile' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Profile.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ProfileCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/ProfileCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Refund' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Refund.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\RefundCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/RefundCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ResourceFactory' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/ResourceFactory.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Settlement' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Settlement.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\SettlementCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/SettlementCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Shipment' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Shipment.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\ShipmentCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/ShipmentCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\Subscription' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/Subscription.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Resources\\SubscriptionCollection' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Resources/SubscriptionCollection.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\InvoiceStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/InvoiceStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\MandateMethod' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/MandateMethod.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\MandateStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/MandateStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OnboardingStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/OnboardingStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderLineStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/OrderLineStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderLineType' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/OrderLineType.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\OrderStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/OrderStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\PaymentMethod' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/PaymentMethod.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\PaymentStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/PaymentStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\ProfileStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/ProfileStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\RefundStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/RefundStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SequenceType' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/SequenceType.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SettlementStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/SettlementStatus.php', + '_PhpScoper5ea00cc67502b\\Mollie\\Api\\Types\\SubscriptionStatus' => __DIR__ . '/..' . '/mollie/mollie-api-php/src/Types/SubscriptionStatus.php', + '_PhpScoper5ea00cc67502b\\ParseError' => __DIR__ . '/..' . '/symfony/polyfill-php70/Resources/stubs/ParseError.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Builder' => __DIR__ . '/..' . '/prestashop/decimal/src/Builder.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Exception\\DivisionByZeroException' => __DIR__ . '/..' . '/prestashop/decimal/src/Exception/DivisionByZeroException.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Number' => __DIR__ . '/..' . '/prestashop/decimal/src/Number.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Addition' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Addition.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Comparison' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Comparison.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Division' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Division.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\MagnitudeChange' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/MagnitudeChange.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Multiplication' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Multiplication.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Rounding' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Rounding.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Operation\\Subtraction' => __DIR__ . '/..' . '/prestashop/decimal/src/Operation/Subtraction.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\AdditionTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/AdditionTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\ComparisonTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/ComparisonTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\DivisionTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/DivisionTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\MagnitudeChangeTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/MagnitudeChangeTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\MultiplicationTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/MultiplicationTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\RoundingTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/RoundingTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\Operation\\SubtractionTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/Operation/SubtractionTest.php', + '_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\tests\\Unit\\Core\\Decimal\\NumberTest' => __DIR__ . '/..' . '/prestashop/decimal/tests/NumberTest.php', + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheException' => __DIR__ . '/..' . '/psr/cache/src/CacheException.php', + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface' => __DIR__ . '/..' . '/psr/cache/src/CacheItemInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemPoolInterface' => __DIR__ . '/..' . '/psr/cache/src/CacheItemPoolInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Cache\\InvalidArgumentException' => __DIR__ . '/..' . '/psr/cache/src/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerExceptionInterface' => __DIR__ . '/..' . '/psr/container/src/ContainerExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => __DIR__ . '/..' . '/psr/container/src/ContainerInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Container\\NotFoundExceptionInterface' => __DIR__ . '/..' . '/psr/container/src/NotFoundExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\MessageInterface' => __DIR__ . '/..' . '/psr/http-message/src/MessageInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\RequestInterface' => __DIR__ . '/..' . '/psr/http-message/src/RequestInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\ResponseInterface' => __DIR__ . '/..' . '/psr/http-message/src/ResponseInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\ServerRequestInterface' => __DIR__ . '/..' . '/psr/http-message/src/ServerRequestInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\StreamInterface' => __DIR__ . '/..' . '/psr/http-message/src/StreamInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\UploadedFileInterface' => __DIR__ . '/..' . '/psr/http-message/src/UploadedFileInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\UriInterface' => __DIR__ . '/..' . '/psr/http-message/src/UriInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\AbstractLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/AbstractLogger.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\InvalidArgumentException' => __DIR__ . '/..' . '/psr/log/Psr/Log/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\LogLevel' => __DIR__ . '/..' . '/psr/log/Psr/Log/LogLevel.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerAwareInterface' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerAwareInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerAwareTrait' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerAwareTrait.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerInterface' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerTrait' => __DIR__ . '/..' . '/psr/log/Psr/Log/LoggerTrait.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\NullLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/NullLogger.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\DummyTest' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/DummyTest.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\LoggerInterfaceTest' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/LoggerInterfaceTest.php', + '_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\TestLogger' => __DIR__ . '/..' . '/psr/log/Psr/Log/Test/TestLogger.php', + '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\CacheException' => __DIR__ . '/..' . '/psr/simple-cache/src/CacheException.php', + '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\CacheInterface' => __DIR__ . '/..' . '/psr/simple-cache/src/CacheInterface.php', + '_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\InvalidArgumentException' => __DIR__ . '/..' . '/psr/simple-cache/src/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\SessionUpdateTimestampHandlerInterface' => __DIR__ . '/..' . '/symfony/polyfill-php70/Resources/stubs/SessionUpdateTimestampHandlerInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\AbstractAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/AbstractAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\AdapterInterface' => __DIR__ . '/..' . '/symfony/cache/Adapter/AdapterInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ApcuAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/ApcuAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ArrayAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/ArrayAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ChainAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/ChainAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\DoctrineAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/DoctrineAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\FilesystemAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/FilesystemAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\MemcachedAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/MemcachedAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\NullAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/NullAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PdoAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/PdoAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PhpArrayAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/PhpArrayAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\PhpFilesAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/PhpFilesAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\ProxyAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/ProxyAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\RedisAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/RedisAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\SimpleCacheAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/SimpleCacheAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TagAwareAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/TagAwareAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TagAwareAdapterInterface' => __DIR__ . '/..' . '/symfony/cache/Adapter/TagAwareAdapterInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/TraceableAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableAdapterEvent' => __DIR__ . '/..' . '/symfony/cache/Adapter/TraceableAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Adapter\\TraceableTagAwareAdapter' => __DIR__ . '/..' . '/symfony/cache/Adapter/TraceableTagAwareAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\CacheItem' => __DIR__ . '/..' . '/symfony/cache/CacheItem.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\DataCollector\\CacheDataCollector' => __DIR__ . '/..' . '/symfony/cache/DataCollector/CacheDataCollector.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\DoctrineProvider' => __DIR__ . '/..' . '/symfony/cache/DoctrineProvider.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\CacheException' => __DIR__ . '/..' . '/symfony/cache/Exception/CacheException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException' => __DIR__ . '/..' . '/symfony/cache/Exception/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\PruneableInterface' => __DIR__ . '/..' . '/symfony/cache/PruneableInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\ResettableInterface' => __DIR__ . '/..' . '/symfony/cache/ResettableInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\AbstractCache' => __DIR__ . '/..' . '/symfony/cache/Simple/AbstractCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ApcuCache' => __DIR__ . '/..' . '/symfony/cache/Simple/ApcuCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ArrayCache' => __DIR__ . '/..' . '/symfony/cache/Simple/ArrayCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\ChainCache' => __DIR__ . '/..' . '/symfony/cache/Simple/ChainCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\DoctrineCache' => __DIR__ . '/..' . '/symfony/cache/Simple/DoctrineCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\FilesystemCache' => __DIR__ . '/..' . '/symfony/cache/Simple/FilesystemCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\MemcachedCache' => __DIR__ . '/..' . '/symfony/cache/Simple/MemcachedCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\NullCache' => __DIR__ . '/..' . '/symfony/cache/Simple/NullCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PdoCache' => __DIR__ . '/..' . '/symfony/cache/Simple/PdoCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PhpArrayCache' => __DIR__ . '/..' . '/symfony/cache/Simple/PhpArrayCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\PhpFilesCache' => __DIR__ . '/..' . '/symfony/cache/Simple/PhpFilesCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\Psr6Cache' => __DIR__ . '/..' . '/symfony/cache/Simple/Psr6Cache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\RedisCache' => __DIR__ . '/..' . '/symfony/cache/Simple/RedisCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\TraceableCache' => __DIR__ . '/..' . '/symfony/cache/Simple/TraceableCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Simple\\TraceableCacheEvent' => __DIR__ . '/..' . '/symfony/cache/Simple/TraceableCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\AbstractTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/AbstractTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ApcuTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/ApcuTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ArrayTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/ArrayTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\DoctrineTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/DoctrineTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\FilesystemCommonTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/FilesystemCommonTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\FilesystemTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/FilesystemTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\MemcachedTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/MemcachedTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PdoTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/PdoTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PhpArrayTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/PhpArrayTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\PhpFilesTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/PhpFilesTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\ProxyTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/ProxyTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\RedisProxy' => __DIR__ . '/..' . '/symfony/cache/Traits/RedisProxy.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Traits\\RedisTrait' => __DIR__ . '/..' . '/symfony/cache/Traits/RedisTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCache' => __DIR__ . '/..' . '/symfony/config/ConfigCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheFactory' => __DIR__ . '/..' . '/symfony/config/ConfigCacheFactory.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheFactoryInterface' => __DIR__ . '/..' . '/symfony/config/ConfigCacheFactoryInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ConfigCacheInterface' => __DIR__ . '/..' . '/symfony/config/ConfigCacheInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ArrayNode' => __DIR__ . '/..' . '/symfony/config/Definition/ArrayNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BaseNode' => __DIR__ . '/..' . '/symfony/config/Definition/BaseNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BooleanNode' => __DIR__ . '/..' . '/symfony/config/Definition/BooleanNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ArrayNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/ArrayNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\BooleanNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/BooleanNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\EnumNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/EnumNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ExprBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/ExprBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\FloatNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/FloatNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\IntegerNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/IntegerNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\MergeBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/MergeBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/NodeBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/NodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NodeParentInterface' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/NodeParentInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NormalizationBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/NormalizationBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\NumericNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/NumericNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ParentNodeDefinitionInterface' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/ParentNodeDefinitionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ScalarNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/ScalarNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\TreeBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/TreeBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\ValidationBuilder' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/ValidationBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\VariableNodeDefinition' => __DIR__ . '/..' . '/symfony/config/Definition/Builder/VariableNodeDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ConfigurationInterface' => __DIR__ . '/..' . '/symfony/config/Definition/ConfigurationInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Dumper\\XmlReferenceDumper' => __DIR__ . '/..' . '/symfony/config/Definition/Dumper/XmlReferenceDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Dumper\\YamlReferenceDumper' => __DIR__ . '/..' . '/symfony/config/Definition/Dumper/YamlReferenceDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\EnumNode' => __DIR__ . '/..' . '/symfony/config/Definition/EnumNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\DuplicateKeyException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/DuplicateKeyException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\Exception' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/Exception.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\ForbiddenOverwriteException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/ForbiddenOverwriteException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/InvalidConfigurationException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/InvalidDefinitionException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/InvalidTypeException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\UnsetKeyException' => __DIR__ . '/..' . '/symfony/config/Definition/Exception/UnsetKeyException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\FloatNode' => __DIR__ . '/..' . '/symfony/config/Definition/FloatNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\IntegerNode' => __DIR__ . '/..' . '/symfony/config/Definition/IntegerNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\NodeInterface' => __DIR__ . '/..' . '/symfony/config/Definition/NodeInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\NumericNode' => __DIR__ . '/..' . '/symfony/config/Definition/NumericNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Processor' => __DIR__ . '/..' . '/symfony/config/Definition/Processor.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypeNodeInterface' => __DIR__ . '/..' . '/symfony/config/Definition/PrototypeNodeInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypedArrayNode' => __DIR__ . '/..' . '/symfony/config/Definition/PrototypedArrayNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\ScalarNode' => __DIR__ . '/..' . '/symfony/config/Definition/ScalarNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\VariableNode' => __DIR__ . '/..' . '/symfony/config/Definition/VariableNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\DependencyInjection\\ConfigCachePass' => __DIR__ . '/..' . '/symfony/config/DependencyInjection/ConfigCachePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderImportCircularReferenceException' => __DIR__ . '/..' . '/symfony/config/Exception/FileLoaderImportCircularReferenceException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderLoadException' => __DIR__ . '/..' . '/symfony/config/Exception/FileLoaderLoadException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLocatorFileNotFoundException' => __DIR__ . '/..' . '/symfony/config/Exception/FileLocatorFileNotFoundException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocator' => __DIR__ . '/..' . '/symfony/config/FileLocator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface' => __DIR__ . '/..' . '/symfony/config/FileLocatorInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\DelegatingLoader' => __DIR__ . '/..' . '/symfony/config/Loader/DelegatingLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\FileLoader' => __DIR__ . '/..' . '/symfony/config/Loader/FileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\GlobFileLoader' => __DIR__ . '/..' . '/symfony/config/Loader/GlobFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\Loader' => __DIR__ . '/..' . '/symfony/config/Loader/Loader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface' => __DIR__ . '/..' . '/symfony/config/Loader/LoaderInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolver' => __DIR__ . '/..' . '/symfony/config/Loader/LoaderResolver.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface' => __DIR__ . '/..' . '/symfony/config/Loader/LoaderResolverInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerConfigCache' => __DIR__ . '/..' . '/symfony/config/ResourceCheckerConfigCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerConfigCacheFactory' => __DIR__ . '/..' . '/symfony/config/ResourceCheckerConfigCacheFactory.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface' => __DIR__ . '/..' . '/symfony/config/ResourceCheckerInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ClassExistenceResource' => __DIR__ . '/..' . '/symfony/config/Resource/ClassExistenceResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ComposerResource' => __DIR__ . '/..' . '/symfony/config/Resource/ComposerResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\DirectoryResource' => __DIR__ . '/..' . '/symfony/config/Resource/DirectoryResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileExistenceResource' => __DIR__ . '/..' . '/symfony/config/Resource/FileExistenceResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileResource' => __DIR__ . '/..' . '/symfony/config/Resource/FileResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\GlobResource' => __DIR__ . '/..' . '/symfony/config/Resource/GlobResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionClassResource' => __DIR__ . '/..' . '/symfony/config/Resource/ReflectionClassResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionMethodHhvmWrapper' => __DIR__ . '/..' . '/symfony/config/Resource/ReflectionClassResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ReflectionParameterHhvmWrapper' => __DIR__ . '/..' . '/symfony/config/Resource/ReflectionClassResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ResourceInterface' => __DIR__ . '/..' . '/symfony/config/Resource/ResourceInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\SelfCheckingResourceChecker' => __DIR__ . '/..' . '/symfony/config/Resource/SelfCheckingResourceChecker.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\SelfCheckingResourceInterface' => __DIR__ . '/..' . '/symfony/config/Resource/SelfCheckingResourceInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\Exception\\InvalidXmlException' => __DIR__ . '/..' . '/symfony/config/Util/Exception/InvalidXmlException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\Exception\\XmlParsingException' => __DIR__ . '/..' . '/symfony/config/Util/Exception/XmlParsingException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\XmlUtils' => __DIR__ . '/..' . '/symfony/config/Util/XmlUtils.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Alias' => __DIR__ . '/..' . '/symfony/dependency-injection/Alias.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\ArgumentInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/ArgumentInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\BoundArgument' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/BoundArgument.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\IteratorArgument' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/IteratorArgument.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\RewindableGenerator' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/RewindableGenerator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\ServiceClosureArgument' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/ServiceClosureArgument.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Argument\\TaggedIteratorArgument' => __DIR__ . '/..' . '/symfony/dependency-injection/Argument/TaggedIteratorArgument.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ChildDefinition' => __DIR__ . '/..' . '/symfony/dependency-injection/ChildDefinition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AbstractRecursivePass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AbstractRecursivePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AnalyzeServiceReferencesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AnalyzeServiceReferencesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutoAliasServicePass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AutoAliasServicePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowireExceptionPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AutowireExceptionPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowirePass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AutowirePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\AutowireRequiredMethodsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/AutowireRequiredMethodsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckArgumentsValidityPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CheckArgumentsValidityPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckCircularReferencesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CheckCircularReferencesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckDefinitionValidityPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CheckDefinitionValidityPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckExceptionOnInvalidReferenceBehaviorPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CheckReferenceValidityPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CheckReferenceValidityPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\Compiler' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/Compiler.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CompilerPassInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/CompilerPassInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\DecoratorServicePass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/DecoratorServicePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\DefinitionErrorExceptionPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/DefinitionErrorExceptionPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ExtensionCompilerPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ExtensionCompilerPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\FactoryReturnTypePass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/FactoryReturnTypePass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\InlineServiceDefinitionsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/InlineServiceDefinitionsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\LoggingFormatter' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/LoggingFormatter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationContainerBuilder' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationParameterBag' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\MergeExtensionConfigurationPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\PassConfig' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/PassConfig.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\PriorityTaggedServiceTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/PriorityTaggedServiceTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RegisterEnvVarProcessorsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RegisterEnvVarProcessorsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RegisterServiceSubscribersPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RegisterServiceSubscribersPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemoveAbstractDefinitionsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RemoveAbstractDefinitionsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemovePrivateAliasesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RemovePrivateAliasesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RemoveUnusedDefinitionsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RemoveUnusedDefinitionsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RepeatablePassInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RepeatablePassInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\RepeatedPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/RepeatedPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ReplaceAliasByActualDefinitionPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ReplaceAliasByActualDefinitionPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveBindingsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveBindingsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveChildDefinitionsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveChildDefinitionsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveClassPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveClassPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveDefinitionTemplatesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveDefinitionTemplatesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveEnvPlaceholdersPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveEnvPlaceholdersPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveFactoryClassPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveFactoryClassPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveHotPathPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveHotPathPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveInstanceofConditionalsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveInstanceofConditionalsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveInvalidReferencesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveInvalidReferencesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveNamedArgumentsPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveNamedArgumentsPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveParameterPlaceHoldersPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveParameterPlaceHoldersPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolvePrivatesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolvePrivatesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveReferencesToAliasesPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveReferencesToAliasesPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveServiceSubscribersPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveServiceSubscribersPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ResolveTaggedIteratorArgumentPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ResolveTaggedIteratorArgumentPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceLocatorTagPass' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ServiceLocatorTagPass.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraph' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ServiceReferenceGraph.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraphEdge' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ServiceReferenceGraphEdge.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\ServiceReferenceGraphNode' => __DIR__ . '/..' . '/symfony/dependency-injection/Compiler/ServiceReferenceGraphNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\AutowireServiceResource' => __DIR__ . '/..' . '/symfony/dependency-injection/Config/AutowireServiceResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\ContainerParametersResource' => __DIR__ . '/..' . '/symfony/dependency-injection/Config/ContainerParametersResource.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Config\\ContainerParametersResourceChecker' => __DIR__ . '/..' . '/symfony/dependency-injection/Config/ContainerParametersResourceChecker.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Container' => __DIR__ . '/..' . '/symfony/dependency-injection/Container.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerAwareInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/ContainerAwareInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerAwareTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/ContainerAwareTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerBuilder' => __DIR__ . '/..' . '/symfony/dependency-injection/ContainerBuilder.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/ContainerInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition' => __DIR__ . '/..' . '/symfony/dependency-injection/Definition.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\DefinitionDecorator' => __DIR__ . '/..' . '/symfony/dependency-injection/DefinitionDecorator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\Dumper' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/Dumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\DumperInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/DumperInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\GraphvizDumper' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/GraphvizDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\PhpDumper' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/PhpDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\XmlDumper' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/XmlDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dumper\\YamlDumper' => __DIR__ . '/..' . '/symfony/dependency-injection/Dumper/YamlDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\EnvVarProcessor' => __DIR__ . '/..' . '/symfony/dependency-injection/EnvVarProcessor.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\EnvVarProcessorInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/EnvVarProcessorInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/AutowiringFailedException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\BadMethodCallException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/BadMethodCallException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvNotFoundException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/EnvNotFoundException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvParameterException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/EnvParameterException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ExceptionInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/ExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/InvalidArgumentException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\LogicException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/LogicException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\OutOfBoundsException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/OutOfBoundsException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterCircularReferenceException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/ParameterCircularReferenceException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/ParameterNotFoundException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/RuntimeException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/ServiceCircularReferenceException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException' => __DIR__ . '/..' . '/symfony/dependency-injection/Exception/ServiceNotFoundException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ExpressionLanguage' => __DIR__ . '/..' . '/symfony/dependency-injection/ExpressionLanguage.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ExpressionLanguageProvider' => __DIR__ . '/..' . '/symfony/dependency-injection/ExpressionLanguageProvider.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ConfigurationExtensionInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Extension/ConfigurationExtensionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\Extension' => __DIR__ . '/..' . '/symfony/dependency-injection/Extension/Extension.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Extension/ExtensionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\PrependExtensionInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/Extension/PrependExtensionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\Instantiator\\InstantiatorInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/LazyProxy/Instantiator/InstantiatorInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\Instantiator\\RealServiceInstantiator' => __DIR__ . '/..' . '/symfony/dependency-injection/LazyProxy/Instantiator/RealServiceInstantiator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\PhpDumper\\DumperInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/LazyProxy/PhpDumper/DumperInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\PhpDumper\\NullDumper' => __DIR__ . '/..' . '/symfony/dependency-injection/LazyProxy/PhpDumper/NullDumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\LazyProxy\\ProxyHelper' => __DIR__ . '/..' . '/symfony/dependency-injection/LazyProxy/ProxyHelper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\ClosureLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/ClosureLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AbstractConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/AbstractConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AbstractServiceConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/AbstractServiceConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\AliasConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/AliasConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ContainerConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/ContainerConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\DefaultsConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/DefaultsConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\InlineServiceConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/InlineServiceConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\InstanceofConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/InstanceofConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ParametersConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/ParametersConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\PrototypeConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/PrototypeConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ReferenceConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/ReferenceConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ServiceConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/ServiceConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\ServicesConfigurator' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/ServicesConfigurator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AbstractTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/AbstractTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ArgumentTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/ArgumentTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AutoconfigureTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/AutoconfigureTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\AutowireTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/AutowireTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\BindTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/BindTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\CallTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/CallTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ClassTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/ClassTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ConfiguratorTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/ConfiguratorTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\DecorateTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/DecorateTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\DeprecateTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/DeprecateTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\FactoryTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/FactoryTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\FileTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/FileTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\LazyTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/LazyTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ParentTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/ParentTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\PropertyTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/PropertyTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\PublicTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/PublicTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\ShareTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/ShareTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\SyntheticTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/SyntheticTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\Configurator\\Traits\\TagTrait' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/Configurator/Traits/TagTrait.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\DirectoryLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/DirectoryLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\FileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/FileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\GlobFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/GlobFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\IniFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/IniFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\PhpFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/PhpFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\ProtectedPhpFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/PhpFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\XmlFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/XmlFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Loader\\YamlFileLoader' => __DIR__ . '/..' . '/symfony/dependency-injection/Loader/YamlFileLoader.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Parameter' => __DIR__ . '/..' . '/symfony/dependency-injection/Parameter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\EnvPlaceholderParameterBag' => __DIR__ . '/..' . '/symfony/dependency-injection/ParameterBag/EnvPlaceholderParameterBag.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\FrozenParameterBag' => __DIR__ . '/..' . '/symfony/dependency-injection/ParameterBag/FrozenParameterBag.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\ParameterBag' => __DIR__ . '/..' . '/symfony/dependency-injection/ParameterBag/ParameterBag.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\ParameterBagInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/ParameterBag/ParameterBagInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Reference' => __DIR__ . '/..' . '/symfony/dependency-injection/Reference.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ResettableContainerInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/ResettableContainerInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ServiceLocator' => __DIR__ . '/..' . '/symfony/dependency-injection/ServiceLocator.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ServiceSubscriberInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/ServiceSubscriberInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\TaggedContainerInterface' => __DIR__ . '/..' . '/symfony/dependency-injection/TaggedContainerInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\TypedReference' => __DIR__ . '/..' . '/symfony/dependency-injection/TypedReference.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Variable' => __DIR__ . '/..' . '/symfony/dependency-injection/Variable.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Compiler' => __DIR__ . '/..' . '/symfony/expression-language/Compiler.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Expression' => __DIR__ . '/..' . '/symfony/expression-language/Expression.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionFunction' => __DIR__ . '/..' . '/symfony/expression-language/ExpressionFunction.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionFunctionProviderInterface' => __DIR__ . '/..' . '/symfony/expression-language/ExpressionFunctionProviderInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage' => __DIR__ . '/..' . '/symfony/expression-language/ExpressionLanguage.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Lexer' => __DIR__ . '/..' . '/symfony/expression-language/Lexer.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ArgumentsNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/ArgumentsNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ArrayNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/ArrayNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\BinaryNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/BinaryNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ConditionalNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/ConditionalNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\ConstantNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/ConstantNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\FunctionNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/FunctionNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\GetAttrNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/GetAttrNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\NameNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/NameNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\Node' => __DIR__ . '/..' . '/symfony/expression-language/Node/Node.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Node\\UnaryNode' => __DIR__ . '/..' . '/symfony/expression-language/Node/UnaryNode.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParsedExpression' => __DIR__ . '/..' . '/symfony/expression-language/ParsedExpression.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Parser' => __DIR__ . '/..' . '/symfony/expression-language/Parser.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ArrayParserCache' => __DIR__ . '/..' . '/symfony/expression-language/ParserCache/ArrayParserCache.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheAdapter' => __DIR__ . '/..' . '/symfony/expression-language/ParserCache/ParserCacheAdapter.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface' => __DIR__ . '/..' . '/symfony/expression-language/ParserCache/ParserCacheInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SerializedParsedExpression' => __DIR__ . '/..' . '/symfony/expression-language/SerializedParsedExpression.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError' => __DIR__ . '/..' . '/symfony/expression-language/SyntaxError.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Token' => __DIR__ . '/..' . '/symfony/expression-language/Token.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\TokenStream' => __DIR__ . '/..' . '/symfony/expression-language/TokenStream.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\ExceptionInterface' => __DIR__ . '/..' . '/symfony/filesystem/Exception/ExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\FileNotFoundException' => __DIR__ . '/..' . '/symfony/filesystem/Exception/FileNotFoundException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException' => __DIR__ . '/..' . '/symfony/filesystem/Exception/IOException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOExceptionInterface' => __DIR__ . '/..' . '/symfony/filesystem/Exception/IOExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Filesystem' => __DIR__ . '/..' . '/symfony/filesystem/Filesystem.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\LockHandler' => __DIR__ . '/..' . '/symfony/filesystem/LockHandler.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Command\\LintCommand' => __DIR__ . '/..' . '/symfony/yaml/Command/LintCommand.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Dumper' => __DIR__ . '/..' . '/symfony/yaml/Dumper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Escaper' => __DIR__ . '/..' . '/symfony/yaml/Escaper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\DumpException' => __DIR__ . '/..' . '/symfony/yaml/Exception/DumpException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ExceptionInterface' => __DIR__ . '/..' . '/symfony/yaml/Exception/ExceptionInterface.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException' => __DIR__ . '/..' . '/symfony/yaml/Exception/ParseException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\RuntimeException' => __DIR__ . '/..' . '/symfony/yaml/Exception/RuntimeException.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Inline' => __DIR__ . '/..' . '/symfony/yaml/Inline.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Parser' => __DIR__ . '/..' . '/symfony/yaml/Parser.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Tag\\TaggedValue' => __DIR__ . '/..' . '/symfony/yaml/Tag/TaggedValue.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Unescaper' => __DIR__ . '/..' . '/symfony/yaml/Unescaper.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Yaml' => __DIR__ . '/..' . '/symfony/yaml/Yaml.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\Apcu' => __DIR__ . '/..' . '/symfony/polyfill-apcu/Apcu.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\Ctype' => __DIR__ . '/..' . '/symfony/polyfill-ctype/Ctype.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\Idn' => __DIR__ . '/..' . '/symfony/polyfill-intl-idn/Idn.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\Mbstring' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/Mbstring.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\Php70' => __DIR__ . '/..' . '/symfony/polyfill-php70/Php70.php', + '_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\Php72' => __DIR__ . '/..' . '/symfony/polyfill-php72/Php72.php', + '_PhpScoper5ea00cc67502b\\TypeError' => __DIR__ . '/..' . '/paragonie/random_compat/lib/error_polyfill.php', + ); + + public static function getInitializer(ClassLoader $loader) + { + return \Closure::bind(function () use ($loader) { + $loader->prefixLengthsPsr4 = ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf::$prefixLengthsPsr4; + $loader->prefixDirsPsr4 = ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf::$prefixDirsPsr4; + $loader->classMap = ComposerStaticInitc2b58ae5c6462b5d003510a1194fafcf::$classMap; + + }, null, ClassLoader::class); + } +} diff --git a/vendor/composer/ca-bundle/LICENSE b/vendor/composer/ca-bundle/LICENSE index c5b5220e8..5462ef503 100644 --- a/vendor/composer/ca-bundle/LICENSE +++ b/vendor/composer/ca-bundle/LICENSE @@ -1,19 +1,19 @@ -Copyright (C) 2016 Composer - -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal in -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies -of the Software, and to permit persons to whom the Software is furnished to do -so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +Copyright (C) 2016 Composer + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/vendor/composer/ca-bundle/README.md b/vendor/composer/ca-bundle/README.md index d8205ec53..e6bcaa2f1 100644 --- a/vendor/composer/ca-bundle/README.md +++ b/vendor/composer/ca-bundle/README.md @@ -1,85 +1,85 @@ -composer/ca-bundle -================== - -Small utility library that lets you find a path to the system CA bundle, -and includes a fallback to the Mozilla CA bundle. - -Originally written as part of [composer/composer](https://github.com/composer/composer), -now extracted and made available as a stand-alone library. - - -Installation ------------- - -Install the latest version with: - -```bash -$ composer require composer/ca-bundle -``` - - -Requirements ------------- - -* PHP 5.3.2 is required but using the latest version of PHP is highly recommended. - - -Basic usage ------------ - -### `Composer\CaBundle\CaBundle` - -- `CaBundle::getSystemCaRootBundlePath()`: Returns the system CA bundle path, or a path to the bundled one as fallback -- `CaBundle::getBundledCaBundlePath()`: Returns the path to the bundled CA file -- `CaBundle::validateCaFile($filename)`: Validates a CA file using openssl_x509_parse only if it is safe to use -- `CaBundle::isOpensslParseSafe()`: Test if it is safe to use the PHP function openssl_x509_parse() -- `CaBundle::reset()`: Resets the static caches - - -#### To use with curl - -```php -$curl = curl_init("https://example.org/"); - -$caPathOrFile = \Composer\CaBundle\CaBundle::getSystemCaRootBundlePath(); -if (is_dir($caPathOrFile)) { - curl_setopt($curl, CURLOPT_CAPATH, $caPathOrFile); -} else { - curl_setopt($curl, CURLOPT_CAINFO, $caPathOrFile); -} - -$result = curl_exec($curl); -``` - -#### To use with php streams - -```php -$opts = array( - 'http' => array( - 'method' => "GET" - ) -); - -$caPathOrFile = \Composer\CaBundle\CaBundle::getSystemCaRootBundlePath(); -if (is_dir($caPathOrFile)) { - $opts['ssl']['capath'] = $caPathOrFile; -} else { - $opts['ssl']['cafile'] = $caPathOrFile; -} - -$context = stream_context_create($opts); -$result = file_get_contents('https://example.com', false, $context); -``` - -#### To use with Guzzle - -```php -$client = new \GuzzleHttp\Client([ - \GuzzleHttp\RequestOptions::VERIFY => \Composer\CaBundle\CaBundle::getSystemCaRootBundlePath() -]); -``` - -License -------- - -composer/ca-bundle is licensed under the MIT License, see the LICENSE file for details. +composer/ca-bundle +================== + +Small utility library that lets you find a path to the system CA bundle, +and includes a fallback to the Mozilla CA bundle. + +Originally written as part of [composer/composer](https://github.com/composer/composer), +now extracted and made available as a stand-alone library. + + +Installation +------------ + +Install the latest version with: + +```bash +$ composer require composer/ca-bundle +``` + + +Requirements +------------ + +* PHP 5.3.2 is required but using the latest version of PHP is highly recommended. + + +Basic usage +----------- + +### `Composer\CaBundle\CaBundle` + +- `CaBundle::getSystemCaRootBundlePath()`: Returns the system CA bundle path, or a path to the bundled one as fallback +- `CaBundle::getBundledCaBundlePath()`: Returns the path to the bundled CA file +- `CaBundle::validateCaFile($filename)`: Validates a CA file using openssl_x509_parse only if it is safe to use +- `CaBundle::isOpensslParseSafe()`: Test if it is safe to use the PHP function openssl_x509_parse() +- `CaBundle::reset()`: Resets the static caches + + +#### To use with curl + +```php +$curl = curl_init("https://example.org/"); + +$caPathOrFile = \Composer\CaBundle\CaBundle::getSystemCaRootBundlePath(); +if (is_dir($caPathOrFile)) { + curl_setopt($curl, CURLOPT_CAPATH, $caPathOrFile); +} else { + curl_setopt($curl, CURLOPT_CAINFO, $caPathOrFile); +} + +$result = curl_exec($curl); +``` + +#### To use with php streams + +```php +$opts = array( + 'http' => array( + 'method' => "GET" + ) +); + +$caPathOrFile = \Composer\CaBundle\CaBundle::getSystemCaRootBundlePath(); +if (is_dir($caPathOrFile)) { + $opts['ssl']['capath'] = $caPathOrFile; +} else { + $opts['ssl']['cafile'] = $caPathOrFile; +} + +$context = stream_context_create($opts); +$result = file_get_contents('https://example.com', false, $context); +``` + +#### To use with Guzzle + +```php +$client = new \GuzzleHttp\Client([ + \GuzzleHttp\RequestOptions::VERIFY => \Composer\CaBundle\CaBundle::getSystemCaRootBundlePath() +]); +``` + +License +------- + +composer/ca-bundle is licensed under the MIT License, see the LICENSE file for details. diff --git a/vendor/composer/ca-bundle/composer.json b/vendor/composer/ca-bundle/composer.json index fbdc6a421..d35fc6154 100644 --- a/vendor/composer/ca-bundle/composer.json +++ b/vendor/composer/ca-bundle/composer.json @@ -1,54 +1,54 @@ -{ - "name": "composer\/ca-bundle", - "description": "Lets you find a path to the system CA bundle, and includes a fallback to the Mozilla CA bundle.", - "type": "library", - "license": "MIT", - "keywords": [ - "cabundle", - "cacert", - "certificate", - "ssl", - "tls" - ], - "authors": [ - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http:\/\/seld.be" - } - ], - "support": { - "irc": "irc:\/\/irc.freenode.org\/composer", - "issues": "https:\/\/github.com\/composer\/ca-bundle\/issues" - }, - "require": { - "ext-openssl": "*", - "ext-pcre": "*", - "php": "^5.3.2 || ^7.0 || ^8.0" - }, - "require-dev": { - "phpunit\/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8", - "psr\/log": "^1.0", - "symfony\/process": "^2.5 || ^3.0 || ^4.0 || ^5.0" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\": "src" - } - }, - "autoload-dev": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\": "tests" - } - }, - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "config": { - "platform": { - "php": "5.3.9" - } - } +{ + "name": "composer\/ca-bundle", + "description": "Lets you find a path to the system CA bundle, and includes a fallback to the Mozilla CA bundle.", + "type": "library", + "license": "MIT", + "keywords": [ + "cabundle", + "cacert", + "certificate", + "ssl", + "tls" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http:\/\/seld.be" + } + ], + "support": { + "irc": "irc:\/\/irc.freenode.org\/composer", + "issues": "https:\/\/github.com\/composer\/ca-bundle\/issues" + }, + "require": { + "ext-openssl": "*", + "ext-pcre": "*", + "php": "^5.3.2 || ^7.0 || ^8.0" + }, + "require-dev": { + "phpunit\/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8", + "psr\/log": "^1.0", + "symfony\/process": "^2.5 || ^3.0 || ^4.0 || ^5.0" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\": "src" + } + }, + "autoload-dev": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\": "tests" + } + }, + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "config": { + "platform": { + "php": "5.3.9" + } + } } \ No newline at end of file diff --git a/vendor/composer/ca-bundle/index.php b/vendor/composer/ca-bundle/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/composer/ca-bundle/index.php +++ b/vendor/composer/ca-bundle/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/composer/ca-bundle/res/cacert.pem b/vendor/composer/ca-bundle/res/cacert.pem index 651694e8a..f679c7a35 100644 --- a/vendor/composer/ca-bundle/res/cacert.pem +++ b/vendor/composer/ca-bundle/res/cacert.pem @@ -1,3466 +1,3466 @@ -## -## Bundle of CA Root Certificates -## -## Certificate data from Mozilla as of: Wed Jan 1 04:12:10 2020 GMT -## -## This is a bundle of X.509 certificates of public Certificate Authorities -## (CA). These were automatically extracted from Mozilla's root certificates -## file (certdata.txt). This file can be found in the mozilla source tree: -## https://hg.mozilla.org/releases/mozilla-release/raw-file/default/security/nss/lib/ckfw/builtins/certdata.txt -## -## It contains the certificates in PEM format and therefore -## can be directly used with curl / libcurl / php_curl, or with -## an Apache+mod_ssl webserver for SSL client authentication. -## Just configure this file as the SSLCACertificateFile. -## -## Conversion done with mk-ca-bundle.pl version 1.27. -## SHA256: f3bdcd74612952da8476a9d4147f50b29ad0710b7dd95b4c8690500209986d70 -## - - -GlobalSign Root CA -================== ------BEGIN CERTIFICATE----- -MIIDdTCCAl2gAwIBAgILBAAAAAABFUtaw5QwDQYJKoZIhvcNAQEFBQAwVzELMAkGA1UEBhMCQkUx -GTAXBgNVBAoTEEdsb2JhbFNpZ24gbnYtc2ExEDAOBgNVBAsTB1Jvb3QgQ0ExGzAZBgNVBAMTEkds -b2JhbFNpZ24gUm9vdCBDQTAeFw05ODA5MDExMjAwMDBaFw0yODAxMjgxMjAwMDBaMFcxCzAJBgNV -BAYTAkJFMRkwFwYDVQQKExBHbG9iYWxTaWduIG52LXNhMRAwDgYDVQQLEwdSb290IENBMRswGQYD -VQQDExJHbG9iYWxTaWduIFJvb3QgQ0EwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDa -DuaZjc6j40+Kfvvxi4Mla+pIH/EqsLmVEQS98GPR4mdmzxzdzxtIK+6NiY6arymAZavpxy0Sy6sc -THAHoT0KMM0VjU/43dSMUBUc71DuxC73/OlS8pF94G3VNTCOXkNz8kHp1Wrjsok6Vjk4bwY8iGlb -Kk3Fp1S4bInMm/k8yuX9ifUSPJJ4ltbcdG6TRGHRjcdGsnUOhugZitVtbNV4FpWi6cgKOOvyJBNP -c1STE4U6G7weNLWLBYy5d4ux2x8gkasJU26Qzns3dLlwR5EiUWMWea6xrkEmCMgZK9FGqkjWZCrX -gzT/LCrBbBlDSgeF59N89iFo7+ryUp9/k5DPAgMBAAGjQjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNV -HRMBAf8EBTADAQH/MB0GA1UdDgQWBBRge2YaRQ2XyolQL30EzTSo//z9SzANBgkqhkiG9w0BAQUF -AAOCAQEA1nPnfE920I2/7LqivjTFKDK1fPxsnCwrvQmeU79rXqoRSLblCKOzyj1hTdNGCbM+w6Dj -Y1Ub8rrvrTnhQ7k4o+YviiY776BQVvnGCv04zcQLcFGUl5gE38NflNUVyRRBnMRddWQVDf9VMOyG -j/8N7yy5Y0b2qvzfvGn9LhJIZJrglfCm7ymPAbEVtQwdpf5pLGkkeB6zpxxxYu7KyJesF12KwvhH -hm4qxFYxldBniYUr+WymXUadDKqC5JlR3XC321Y9YeRq4VzW9v493kHMB65jUr9TU/Qr6cf9tveC -X4XSQRjbgbMEHMUfpIBvFSDJ3gyICh3WZlXi/EjJKSZp4A== ------END CERTIFICATE----- - -GlobalSign Root CA - R2 -======================= ------BEGIN CERTIFICATE----- -MIIDujCCAqKgAwIBAgILBAAAAAABD4Ym5g0wDQYJKoZIhvcNAQEFBQAwTDEgMB4GA1UECxMXR2xv -YmFsU2lnbiBSb290IENBIC0gUjIxEzARBgNVBAoTCkdsb2JhbFNpZ24xEzARBgNVBAMTCkdsb2Jh -bFNpZ24wHhcNMDYxMjE1MDgwMDAwWhcNMjExMjE1MDgwMDAwWjBMMSAwHgYDVQQLExdHbG9iYWxT -aWduIFJvb3QgQ0EgLSBSMjETMBEGA1UEChMKR2xvYmFsU2lnbjETMBEGA1UEAxMKR2xvYmFsU2ln -bjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAKbPJA6+Lm8omUVCxKs+IVSbC9N/hHD6 -ErPLv4dfxn+G07IwXNb9rfF73OX4YJYJkhD10FPe+3t+c4isUoh7SqbKSaZeqKeMWhG8eoLrvozp -s6yWJQeXSpkqBy+0Hne/ig+1AnwblrjFuTosvNYSuetZfeLQBoZfXklqtTleiDTsvHgMCJiEbKjN -S7SgfQx5TfC4LcshytVsW33hoCmEofnTlEnLJGKRILzdC9XZzPnqJworc5HGnRusyMvo4KD0L5CL -TfuwNhv2GXqF4G3yYROIXJ/gkwpRl4pazq+r1feqCapgvdzZX99yqWATXgAByUr6P6TqBwMhAo6C -ygPCm48CAwEAAaOBnDCBmTAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4E -FgQUm+IHV2ccHsBqBt5ZtJot39wZhi4wNgYDVR0fBC8wLTAroCmgJ4YlaHR0cDovL2NybC5nbG9i -YWxzaWduLm5ldC9yb290LXIyLmNybDAfBgNVHSMEGDAWgBSb4gdXZxwewGoG3lm0mi3f3BmGLjAN -BgkqhkiG9w0BAQUFAAOCAQEAmYFThxxol4aR7OBKuEQLq4GsJ0/WwbgcQ3izDJr86iw8bmEbTUsp -9Z8FHSbBuOmDAGJFtqkIk7mpM0sYmsL4h4hO291xNBrBVNpGP+DTKqttVCL1OmLNIG+6KYnX3ZHu -01yiPqFbQfXf5WRDLenVOavSot+3i9DAgBkcRcAtjOj4LaR0VknFBbVPFd5uRHg5h6h+u/N5GJG7 -9G+dwfCMNYxdAfvDbbnvRG15RjF+Cv6pgsH/76tuIMRQyV+dTZsXjAzlAcmgQWpzU/qlULRuJQ/7 -TBj0/VLZjmmx6BEP3ojY+x1J96relc8geMJgEtslQIxq/H5COEBkEveegeGTLg== ------END CERTIFICATE----- - -Verisign Class 3 Public Primary Certification Authority - G3 -============================================================ ------BEGIN CERTIFICATE----- -MIIEGjCCAwICEQCbfgZJoz5iudXukEhxKe9XMA0GCSqGSIb3DQEBBQUAMIHKMQswCQYDVQQGEwJV -UzEXMBUGA1UEChMOVmVyaVNpZ24sIEluYy4xHzAdBgNVBAsTFlZlcmlTaWduIFRydXN0IE5ldHdv -cmsxOjA4BgNVBAsTMShjKSAxOTk5IFZlcmlTaWduLCBJbmMuIC0gRm9yIGF1dGhvcml6ZWQgdXNl -IG9ubHkxRTBDBgNVBAMTPFZlcmlTaWduIENsYXNzIDMgUHVibGljIFByaW1hcnkgQ2VydGlmaWNh -dGlvbiBBdXRob3JpdHkgLSBHMzAeFw05OTEwMDEwMDAwMDBaFw0zNjA3MTYyMzU5NTlaMIHKMQsw -CQYDVQQGEwJVUzEXMBUGA1UEChMOVmVyaVNpZ24sIEluYy4xHzAdBgNVBAsTFlZlcmlTaWduIFRy -dXN0IE5ldHdvcmsxOjA4BgNVBAsTMShjKSAxOTk5IFZlcmlTaWduLCBJbmMuIC0gRm9yIGF1dGhv -cml6ZWQgdXNlIG9ubHkxRTBDBgNVBAMTPFZlcmlTaWduIENsYXNzIDMgUHVibGljIFByaW1hcnkg -Q2VydGlmaWNhdGlvbiBBdXRob3JpdHkgLSBHMzCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoC -ggEBAMu6nFL8eB8aHm8bN3O9+MlrlBIwT/A2R/XQkQr1F8ilYcEWQE37imGQ5XYgwREGfassbqb1 -EUGO+i2tKmFZpGcmTNDovFJbcCAEWNF6yaRpvIMXZK0Fi7zQWM6NjPXr8EJJC52XJ2cybuGukxUc -cLwgTS8Y3pKI6GyFVxEa6X7jJhFUokWWVYPKMIno3Nij7SqAP395ZVc+FSBmCC+Vk7+qRy+oRpfw -EuL+wgorUeZ25rdGt+INpsyow0xZVYnm6FNcHOqd8GIWC6fJXwzw3sJ2zq/3avL6QaaiMxTJ5Xpj -055iN9WFZZ4O5lMkdBteHRJTW8cs54NJOxWuimi5V5cCAwEAATANBgkqhkiG9w0BAQUFAAOCAQEA -ERSWwauSCPc/L8my/uRan2Te2yFPhpk0djZX3dAVL8WtfxUfN2JzPtTnX84XA9s1+ivbrmAJXx5f -j267Cz3qWhMeDGBvtcC1IyIuBwvLqXTLR7sdwdela8wv0kL9Sd2nic9TutoAWii/gt/4uhMdUIaC -/Y4wjylGsB49Ndo4YhYYSq3mtlFs3q9i6wHQHiT+eo8SGhJouPtmmRQURVyu565pF4ErWjfJXir0 -xuKhXFSbplQAz/DxwceYMBo7Nhbbo27q/a2ywtrvAkcTisDxszGtTxzhT5yvDwyd93gN2PQ1VoDa -t20Xj50egWTh/sVFuq1ruQp6Tk9LhO5L8X3dEQ== ------END CERTIFICATE----- - -Entrust.net Premium 2048 Secure Server CA -========================================= ------BEGIN CERTIFICATE----- -MIIEKjCCAxKgAwIBAgIEOGPe+DANBgkqhkiG9w0BAQUFADCBtDEUMBIGA1UEChMLRW50cnVzdC5u -ZXQxQDA+BgNVBAsUN3d3dy5lbnRydXN0Lm5ldC9DUFNfMjA0OCBpbmNvcnAuIGJ5IHJlZi4gKGxp -bWl0cyBsaWFiLikxJTAjBgNVBAsTHChjKSAxOTk5IEVudHJ1c3QubmV0IExpbWl0ZWQxMzAxBgNV -BAMTKkVudHJ1c3QubmV0IENlcnRpZmljYXRpb24gQXV0aG9yaXR5ICgyMDQ4KTAeFw05OTEyMjQx -NzUwNTFaFw0yOTA3MjQxNDE1MTJaMIG0MRQwEgYDVQQKEwtFbnRydXN0Lm5ldDFAMD4GA1UECxQ3 -d3d3LmVudHJ1c3QubmV0L0NQU18yMDQ4IGluY29ycC4gYnkgcmVmLiAobGltaXRzIGxpYWIuKTEl -MCMGA1UECxMcKGMpIDE5OTkgRW50cnVzdC5uZXQgTGltaXRlZDEzMDEGA1UEAxMqRW50cnVzdC5u -ZXQgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgKDIwNDgpMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8A -MIIBCgKCAQEArU1LqRKGsuqjIAcVFmQqK0vRvwtKTY7tgHalZ7d4QMBzQshowNtTK91euHaYNZOL -Gp18EzoOH1u3Hs/lJBQesYGpjX24zGtLA/ECDNyrpUAkAH90lKGdCCmziAv1h3edVc3kw37XamSr -hRSGlVuXMlBvPci6Zgzj/L24ScF2iUkZ/cCovYmjZy/Gn7xxGWC4LeksyZB2ZnuU4q941mVTXTzW -nLLPKQP5L6RQstRIzgUyVYr9smRMDuSYB3Xbf9+5CFVghTAp+XtIpGmG4zU/HoZdenoVve8AjhUi -VBcAkCaTvA5JaJG/+EfTnZVCwQ5N328mz8MYIWJmQ3DW1cAH4QIDAQABo0IwQDAOBgNVHQ8BAf8E -BAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUVeSB0RGAvtiJuQijMfmhJAkWuXAwDQYJ -KoZIhvcNAQEFBQADggEBADubj1abMOdTmXx6eadNl9cZlZD7Bh/KM3xGY4+WZiT6QBshJ8rmcnPy -T/4xmf3IDExoU8aAghOY+rat2l098c5u9hURlIIM7j+VrxGrD9cv3h8Dj1csHsm7mhpElesYT6Yf -zX1XEC+bBAlahLVu2B064dae0Wx5XnkcFMXj0EyTO2U87d89vqbllRrDtRnDvV5bu/8j72gZyxKT -J1wDLW8w0B62GqzeWvfRqqgnpv55gcR5mTNXuhKwqeBCbJPKVt7+bYQLCIt+jerXmCHG8+c8eS9e -nNFMFY3h7CI3zJpDC5fcgJCNs2ebb0gIFVbPv/ErfF6adulZkMV8gzURZVE= ------END CERTIFICATE----- - -Baltimore CyberTrust Root -========================= ------BEGIN CERTIFICATE----- -MIIDdzCCAl+gAwIBAgIEAgAAuTANBgkqhkiG9w0BAQUFADBaMQswCQYDVQQGEwJJRTESMBAGA1UE -ChMJQmFsdGltb3JlMRMwEQYDVQQLEwpDeWJlclRydXN0MSIwIAYDVQQDExlCYWx0aW1vcmUgQ3li -ZXJUcnVzdCBSb290MB4XDTAwMDUxMjE4NDYwMFoXDTI1MDUxMjIzNTkwMFowWjELMAkGA1UEBhMC -SUUxEjAQBgNVBAoTCUJhbHRpbW9yZTETMBEGA1UECxMKQ3liZXJUcnVzdDEiMCAGA1UEAxMZQmFs -dGltb3JlIEN5YmVyVHJ1c3QgUm9vdDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAKME -uyKrmD1X6CZymrV51Cni4eiVgLGw41uOKymaZN+hXe2wCQVt2yguzmKiYv60iNoS6zjrIZ3AQSsB -UnuId9Mcj8e6uYi1agnnc+gRQKfRzMpijS3ljwumUNKoUMMo6vWrJYeKmpYcqWe4PwzV9/lSEy/C -G9VwcPCPwBLKBsua4dnKM3p31vjsufFoREJIE9LAwqSuXmD+tqYF/LTdB1kC1FkYmGP1pWPgkAx9 -XbIGevOF6uvUA65ehD5f/xXtabz5OTZydc93Uk3zyZAsuT3lySNTPx8kmCFcB5kpvcY67Oduhjpr -l3RjM71oGDHweI12v/yejl0qhqdNkNwnGjkCAwEAAaNFMEMwHQYDVR0OBBYEFOWdWTCCR1jMrPoI -VDaGezq1BE3wMBIGA1UdEwEB/wQIMAYBAf8CAQMwDgYDVR0PAQH/BAQDAgEGMA0GCSqGSIb3DQEB -BQUAA4IBAQCFDF2O5G9RaEIFoN27TyclhAO992T9Ldcw46QQF+vaKSm2eT929hkTI7gQCvlYpNRh -cL0EYWoSihfVCr3FvDB81ukMJY2GQE/szKN+OMY3EU/t3WgxjkzSswF07r51XgdIGn9w/xZchMB5 -hbgF/X++ZRGjD8ACtPhSNzkE1akxehi/oCr0Epn3o0WC4zxe9Z2etciefC7IpJ5OCBRLbf1wbWsa -Y71k5h+3zvDyny67G7fyUIhzksLi4xaNmjICq44Y3ekQEe5+NauQrz4wlHrQMz2nZQ/1/I6eYs9H -RCwBXbsdtTLSR9I4LtD+gdwyah617jzV/OeBHRnDJELqYzmp ------END CERTIFICATE----- - -AddTrust External Root -====================== ------BEGIN CERTIFICATE----- -MIIENjCCAx6gAwIBAgIBATANBgkqhkiG9w0BAQUFADBvMQswCQYDVQQGEwJTRTEUMBIGA1UEChML -QWRkVHJ1c3QgQUIxJjAkBgNVBAsTHUFkZFRydXN0IEV4dGVybmFsIFRUUCBOZXR3b3JrMSIwIAYD -VQQDExlBZGRUcnVzdCBFeHRlcm5hbCBDQSBSb290MB4XDTAwMDUzMDEwNDgzOFoXDTIwMDUzMDEw -NDgzOFowbzELMAkGA1UEBhMCU0UxFDASBgNVBAoTC0FkZFRydXN0IEFCMSYwJAYDVQQLEx1BZGRU -cnVzdCBFeHRlcm5hbCBUVFAgTmV0d29yazEiMCAGA1UEAxMZQWRkVHJ1c3QgRXh0ZXJuYWwgQ0Eg -Um9vdDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBALf3GjPm8gAELTngTlvtH7xsD821 -+iO2zt6bETOXpClMfZOfvUq8k+0DGuOPz+VtUFrWlymUWoCwSXrbLpX9uMq/NzgtHj6RQa1wVsfw -Tz/oMp50ysiQVOnGXw94nZpAPA6sYapeFI+eh6FqUNzXmk6vBbOmcZSccbNQYArHE504B4YCqOmo -aSYYkKtMsE8jqzpPhNjfzp/haW+710LXa0Tkx63ubUFfclpxCDezeWWkWaCUN/cALw3CknLa0Dhy -2xSoRcRdKn23tNbE7qzNE0S3ySvdQwAl+mG5aWpYIxG3pzOPVnVZ9c0p10a3CitlttNCbxWyuHv7 -7+ldU9U0WicCAwEAAaOB3DCB2TAdBgNVHQ4EFgQUrb2YejS0Jvf6xCZU7wO94CTLVBowCwYDVR0P -BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wgZkGA1UdIwSBkTCBjoAUrb2YejS0Jvf6xCZU7wO94CTL -VBqhc6RxMG8xCzAJBgNVBAYTAlNFMRQwEgYDVQQKEwtBZGRUcnVzdCBBQjEmMCQGA1UECxMdQWRk -VHJ1c3QgRXh0ZXJuYWwgVFRQIE5ldHdvcmsxIjAgBgNVBAMTGUFkZFRydXN0IEV4dGVybmFsIENB -IFJvb3SCAQEwDQYJKoZIhvcNAQEFBQADggEBALCb4IUlwtYj4g+WBpKdQZic2YR5gdkeWxQHIzZl -j7DYd7usQWxHYINRsPkyPef89iYTx4AWpb9a/IfPeHmJIZriTAcKhjW88t5RxNKWt9x+Tu5w/Rw5 -6wwCURQtjr0W4MHfRnXnJK3s9EK0hZNwEGe6nQY1ShjTK3rMUUKhemPR5ruhxSvCNr4TDea9Y355 -e6cJDUCrat2PisP29owaQgVR1EX1n6diIWgVIEM8med8vSTYqZEXc4g/VhsxOBi0cQ+azcgOno4u -G+GMmIPLHzHxREzGBHNJdmAPx/i9F4BrLunMTA5amnkPIAou1Z5jJh5VkpTYghdae9C8x49OhgQ= ------END CERTIFICATE----- - -Entrust Root Certification Authority -==================================== ------BEGIN CERTIFICATE----- -MIIEkTCCA3mgAwIBAgIERWtQVDANBgkqhkiG9w0BAQUFADCBsDELMAkGA1UEBhMCVVMxFjAUBgNV -BAoTDUVudHJ1c3QsIEluYy4xOTA3BgNVBAsTMHd3dy5lbnRydXN0Lm5ldC9DUFMgaXMgaW5jb3Jw -b3JhdGVkIGJ5IHJlZmVyZW5jZTEfMB0GA1UECxMWKGMpIDIwMDYgRW50cnVzdCwgSW5jLjEtMCsG -A1UEAxMkRW50cnVzdCBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MB4XDTA2MTEyNzIwMjM0 -MloXDTI2MTEyNzIwNTM0MlowgbAxCzAJBgNVBAYTAlVTMRYwFAYDVQQKEw1FbnRydXN0LCBJbmMu -MTkwNwYDVQQLEzB3d3cuZW50cnVzdC5uZXQvQ1BTIGlzIGluY29ycG9yYXRlZCBieSByZWZlcmVu -Y2UxHzAdBgNVBAsTFihjKSAyMDA2IEVudHJ1c3QsIEluYy4xLTArBgNVBAMTJEVudHJ1c3QgUm9v -dCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB -ALaVtkNC+sZtKm9I35RMOVcF7sN5EUFoNu3s/poBj6E4KPz3EEZmLk0eGrEaTsbRwJWIsMn/MYsz -A9u3g3s+IIRe7bJWKKf44LlAcTfFy0cOlypowCKVYhXbR9n10Cv/gkvJrT7eTNuQgFA/CYqEAOww -Cj0Yzfv9KlmaI5UXLEWeH25DeW0MXJj+SKfFI0dcXv1u5x609mhF0YaDW6KKjbHjKYD+JXGIrb68 -j6xSlkuqUY3kEzEZ6E5Nn9uss2rVvDlUccp6en+Q3X0dgNmBu1kmwhH+5pPi94DkZfs0Nw4pgHBN -rziGLp5/V6+eF67rHMsoIV+2HNjnogQi+dPa2MsCAwEAAaOBsDCBrTAOBgNVHQ8BAf8EBAMCAQYw -DwYDVR0TAQH/BAUwAwEB/zArBgNVHRAEJDAigA8yMDA2MTEyNzIwMjM0MlqBDzIwMjYxMTI3MjA1 -MzQyWjAfBgNVHSMEGDAWgBRokORnpKZTgMeGZqTx90tD+4S9bTAdBgNVHQ4EFgQUaJDkZ6SmU4DH -hmak8fdLQ/uEvW0wHQYJKoZIhvZ9B0EABBAwDhsIVjcuMTo0LjADAgSQMA0GCSqGSIb3DQEBBQUA -A4IBAQCT1DCw1wMgKtD5Y+iRDAUgqV8ZyntyTtSx29CW+1RaGSwMCPeyvIWonX9tO1KzKtvn1ISM -Y/YPyyYBkVBs9F8U4pN0wBOeMDpQ47RgxRzwIkSNcUesyBrJ6ZuaAGAT/3B+XxFNSRuzFVJ7yVTa -v52Vr2ua2J7p8eRDjeIRRDq/r72DQnNSi6q7pynP9WQcCk3RvKqsnyrQ/39/2n3qse0wJcGE2jTS -W3iDVuycNsMm4hH2Z0kdkquM++v/eu6FSqdQgPCnXEqULl8FmTxSQeDNtGPPAUO6nIPcj2A781q0 -tHuu2guQOHXvgR1m0vdXcDazv/wor3ElhVsT/h5/WrQ8 ------END CERTIFICATE----- - -GeoTrust Global CA -================== ------BEGIN CERTIFICATE----- -MIIDVDCCAjygAwIBAgIDAjRWMA0GCSqGSIb3DQEBBQUAMEIxCzAJBgNVBAYTAlVTMRYwFAYDVQQK -Ew1HZW9UcnVzdCBJbmMuMRswGQYDVQQDExJHZW9UcnVzdCBHbG9iYWwgQ0EwHhcNMDIwNTIxMDQw -MDAwWhcNMjIwNTIxMDQwMDAwWjBCMQswCQYDVQQGEwJVUzEWMBQGA1UEChMNR2VvVHJ1c3QgSW5j -LjEbMBkGA1UEAxMSR2VvVHJ1c3QgR2xvYmFsIENBMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB -CgKCAQEA2swYYzD99BcjGlZ+W988bDjkcbd4kdS8odhM+KhDtgPpTSEHCIjaWC9mOSm9BXiLnTjo -BbdqfnGk5sRgprDvgOSJKA+eJdbtg/OtppHHmMlCGDUUna2YRpIuT8rxh0PBFpVXLVDviS2Aelet -8u5fa9IAjbkU+BQVNdnARqN7csiRv8lVK83Qlz6cJmTM386DGXHKTubU1XupGc1V3sjs0l44U+Vc -T4wt/lAjNvxm5suOpDkZALeVAjmRCw7+OC7RHQWa9k0+bw8HHa8sHo9gOeL6NlMTOdReJivbPagU -vTLrGAMoUgRx5aszPeE4uwc2hGKceeoWMPRfwCvocWvk+QIDAQABo1MwUTAPBgNVHRMBAf8EBTAD -AQH/MB0GA1UdDgQWBBTAephojYn7qwVkDBF9qn1luMrMTjAfBgNVHSMEGDAWgBTAephojYn7qwVk -DBF9qn1luMrMTjANBgkqhkiG9w0BAQUFAAOCAQEANeMpauUvXVSOKVCUn5kaFOSPeCpilKInZ57Q -zxpeR+nBsqTP3UEaBU6bS+5Kb1VSsyShNwrrZHYqLizz/Tt1kL/6cdjHPTfStQWVYrmm3ok9Nns4 -d0iXrKYgjy6myQzCsplFAMfOEVEiIuCl6rYVSAlk6l5PdPcFPseKUgzbFbS9bZvlxrFUaKnjaZC2 -mqUPuLk/IH2uSrW4nOQdtqvmlKXBx4Ot2/Unhw4EbNX/3aBd7YdStysVAq45pmp06drE57xNNB6p -XE0zX5IJL4hmXXeXxx12E6nV5fEWCRE11azbJHFwLJhWC9kXtNHjUStedejV0NxPNO3CBWaAocvm -Mw== ------END CERTIFICATE----- - -GeoTrust Universal CA -===================== ------BEGIN CERTIFICATE----- -MIIFaDCCA1CgAwIBAgIBATANBgkqhkiG9w0BAQUFADBFMQswCQYDVQQGEwJVUzEWMBQGA1UEChMN -R2VvVHJ1c3QgSW5jLjEeMBwGA1UEAxMVR2VvVHJ1c3QgVW5pdmVyc2FsIENBMB4XDTA0MDMwNDA1 -MDAwMFoXDTI5MDMwNDA1MDAwMFowRTELMAkGA1UEBhMCVVMxFjAUBgNVBAoTDUdlb1RydXN0IElu -Yy4xHjAcBgNVBAMTFUdlb1RydXN0IFVuaXZlcnNhbCBDQTCCAiIwDQYJKoZIhvcNAQEBBQADggIP -ADCCAgoCggIBAKYVVaCjxuAfjJ0hUNfBvitbtaSeodlyWL0AG0y/YckUHUWCq8YdgNY96xCcOq9t -JPi8cQGeBvV8Xx7BDlXKg5pZMK4ZyzBIle0iN430SppyZj6tlcDgFgDgEB8rMQ7XlFTTQjOgNB0e -RXbdT8oYN+yFFXoZCPzVx5zw8qkuEKmS5j1YPakWaDwvdSEYfyh3peFhF7em6fgemdtzbvQKoiFs -7tqqhZJmr/Z6a4LauiIINQ/PQvE1+mrufislzDoR5G2vc7J2Ha3QsnhnGqQ5HFELZ1aD/ThdDc7d -8Lsrlh/eezJS/R27tQahsiFepdaVaH/wmZ7cRQg+59IJDTWU3YBOU5fXtQlEIGQWFwMCTFMNaN7V -qnJNk22CDtucvc+081xdVHppCZbW2xHBjXWotM85yM48vCR85mLK4b19p71XZQvk/iXttmkQ3Cga -Rr0BHdCXteGYO8A3ZNY9lO4L4fUorgtWv3GLIylBjobFS1J72HGrH4oVpjuDWtdYAVHGTEHZf9hB -Z3KiKN9gg6meyHv8U3NyWfWTehd2Ds735VzZC1U0oqpbtWpU5xPKV+yXbfReBi9Fi1jUIxaS5BZu -KGNZMN9QAZxjiRqf2xeUgnA3wySemkfWWspOqGmJch+RbNt+nhutxx9z3SxPGWX9f5NAEC7S8O08 -ni4oPmkmM8V7AgMBAAGjYzBhMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFNq7LqqwDLiIJlF0 -XG0D08DYj3rWMB8GA1UdIwQYMBaAFNq7LqqwDLiIJlF0XG0D08DYj3rWMA4GA1UdDwEB/wQEAwIB -hjANBgkqhkiG9w0BAQUFAAOCAgEAMXjmx7XfuJRAyXHEqDXsRh3ChfMoWIawC/yOsjmPRFWrZIRc -aanQmjg8+uUfNeVE44B5lGiku8SfPeE0zTBGi1QrlaXv9z+ZhP015s8xxtxqv6fXIwjhmF7DWgh2 -qaavdy+3YL1ERmrvl/9zlcGO6JP7/TG37FcREUWbMPEaiDnBTzynANXH/KttgCJwpQzgXQQpAvvL -oJHRfNbDflDVnVi+QTjruXU8FdmbyUqDWcDaU/0zuzYYm4UPFd3uLax2k7nZAY1IEKj79TiG8dsK -xr2EoyNB3tZ3b4XUhRxQ4K5RirqNPnbiucon8l+f725ZDQbYKxek0nxru18UGkiPGkzns0ccjkxF -KyDuSN/n3QmOGKjaQI2SJhFTYXNd673nxE0pN2HrrDktZy4W1vUAg4WhzH92xH3kt0tm7wNFYGm2 -DFKWkoRepqO1pD4r2czYG0eq8kTaT/kD6PAUyz/zg97QwVTjt+gKN02LIFkDMBmhLMi9ER/frslK -xfMnZmaGrGiR/9nmUxwPi1xpZQomyB40w11Re9epnAahNt3ViZS82eQtDF4JbAiXfKM9fJP/P6EU -p8+1Xevb2xzEdt+Iub1FBZUbrvxGakyvSOPOrg/SfuvmbJxPgWp6ZKy7PtXny3YuxadIwVyQD8vI -P/rmMuGNG2+k5o7Y+SlIis5z/iw= ------END CERTIFICATE----- - -GeoTrust Universal CA 2 -======================= ------BEGIN CERTIFICATE----- -MIIFbDCCA1SgAwIBAgIBATANBgkqhkiG9w0BAQUFADBHMQswCQYDVQQGEwJVUzEWMBQGA1UEChMN -R2VvVHJ1c3QgSW5jLjEgMB4GA1UEAxMXR2VvVHJ1c3QgVW5pdmVyc2FsIENBIDIwHhcNMDQwMzA0 -MDUwMDAwWhcNMjkwMzA0MDUwMDAwWjBHMQswCQYDVQQGEwJVUzEWMBQGA1UEChMNR2VvVHJ1c3Qg -SW5jLjEgMB4GA1UEAxMXR2VvVHJ1c3QgVW5pdmVyc2FsIENBIDIwggIiMA0GCSqGSIb3DQEBAQUA -A4ICDwAwggIKAoICAQCzVFLByT7y2dyxUxpZKeexw0Uo5dfR7cXFS6GqdHtXr0om/Nj1XqduGdt0 -DE81WzILAePb63p3NeqqWuDW6KFXlPCQo3RWlEQwAx5cTiuFJnSCegx2oG9NzkEtoBUGFF+3Qs17 -j1hhNNwqCPkuwwGmIkQcTAeC5lvO0Ep8BNMZcyfwqph/Lq9O64ceJHdqXbboW0W63MOhBW9Wjo8Q -JqVJwy7XQYci4E+GymC16qFjwAGXEHm9ADwSbSsVsaxLse4YuU6W3Nx2/zu+z18DwPw76L5GG//a -QMJS9/7jOvdqdzXQ2o3rXhhqMcceujwbKNZrVMaqW9eiLBsZzKIC9ptZvTdrhrVtgrrY6slWvKk2 -WP0+GfPtDCapkzj4T8FdIgbQl+rhrcZV4IErKIM6+vR7IVEAvlI4zs1meaj0gVbi0IMJR1FbUGrP -20gaXT73y/Zl92zxlfgCOzJWgjl6W70viRu/obTo/3+NjN8D8WBOWBFM66M/ECuDmgFz2ZRthAAn -ZqzwcEAJQpKtT5MNYQlRJNiS1QuUYbKHsu3/mjX/hVTK7URDrBs8FmtISgocQIgfksILAAX/8sgC -SqSqqcyZlpwvWOB94b67B9xfBHJcMTTD7F8t4D1kkCLm0ey4Lt1ZrtmhN79UNdxzMk+MBB4zsslG -8dhcyFVQyWi9qLo2CQIDAQABo2MwYTAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBR281Xh+qQ2 -+/CfXGJx7Tz0RzgQKzAfBgNVHSMEGDAWgBR281Xh+qQ2+/CfXGJx7Tz0RzgQKzAOBgNVHQ8BAf8E -BAMCAYYwDQYJKoZIhvcNAQEFBQADggIBAGbBxiPz2eAubl/oz66wsCVNK/g7WJtAJDday6sWSf+z -dXkzoS9tcBc0kf5nfo/sm+VegqlVHy/c1FEHEv6sFj4sNcZj/NwQ6w2jqtB8zNHQL1EuxBRa3ugZ -4T7GzKQp5y6EqgYweHZUcyiYWTjgAA1i00J9IZ+uPTqM1fp3DRgrFg5fNuH8KrUwJM/gYwx7WBr+ -mbpCErGR9Hxo4sjoryzqyX6uuyo9DRXcNJW2GHSoag/HtPQTxORb7QrSpJdMKu0vbBKJPfEncKpq -A1Ihn0CoZ1Dy81of398j9tx4TuaYT1U6U+Pv8vSfx3zYWK8pIpe44L2RLrB27FcRz+8pRPPphXpg -Y+RdM4kX2TGq2tbzGDVyz4crL2MjhF2EjD9XoIj8mZEoJmmZ1I+XRL6O1UixpCgp8RW04eWe3fiP -pm8m1wk8OhwRDqZsN/etRIcsKMfYdIKz0G9KV7s1KSegi+ghp4dkNl3M2Basx7InQJJVOCiNUW7d -FGdTbHFcJoRNdVq2fmBWqU2t+5sel/MN2dKXVHfaPRK34B7vCAas+YWH6aLcr34YEoP9VhdBLtUp -gn2Z9DH2canPLAEnpQW5qrJITirvn5NSUZU8UnOOVkwXQMAJKOSLakhT2+zNVVXxxvjpoixMptEm -X36vWkzaH6byHCx+rgIW0lbQL1dTR+iS ------END CERTIFICATE----- - -Comodo AAA Services root -======================== ------BEGIN CERTIFICATE----- -MIIEMjCCAxqgAwIBAgIBATANBgkqhkiG9w0BAQUFADB7MQswCQYDVQQGEwJHQjEbMBkGA1UECAwS -R3JlYXRlciBNYW5jaGVzdGVyMRAwDgYDVQQHDAdTYWxmb3JkMRowGAYDVQQKDBFDb21vZG8gQ0Eg -TGltaXRlZDEhMB8GA1UEAwwYQUFBIENlcnRpZmljYXRlIFNlcnZpY2VzMB4XDTA0MDEwMTAwMDAw -MFoXDTI4MTIzMTIzNTk1OVowezELMAkGA1UEBhMCR0IxGzAZBgNVBAgMEkdyZWF0ZXIgTWFuY2hl -c3RlcjEQMA4GA1UEBwwHU2FsZm9yZDEaMBgGA1UECgwRQ29tb2RvIENBIExpbWl0ZWQxITAfBgNV -BAMMGEFBQSBDZXJ0aWZpY2F0ZSBTZXJ2aWNlczCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoC -ggEBAL5AnfRu4ep2hxxNRUSOvkbIgwadwSr+GB+O5AL686tdUIoWMQuaBtDFcCLNSS1UY8y2bmhG -C1Pqy0wkwLxyTurxFa70VJoSCsN6sjNg4tqJVfMiWPPe3M/vg4aijJRPn2jymJBGhCfHdr/jzDUs -i14HZGWCwEiwqJH5YZ92IFCokcdmtet4YgNW8IoaE+oxox6gmf049vYnMlhvB/VruPsUK6+3qszW -Y19zjNoFmag4qMsXeDZRrOme9Hg6jc8P2ULimAyrL58OAd7vn5lJ8S3frHRNG5i1R8XlKdH5kBjH -Ypy+g8cmez6KJcfA3Z3mNWgQIJ2P2N7Sw4ScDV7oL8kCAwEAAaOBwDCBvTAdBgNVHQ4EFgQUoBEK -Iz6W8Qfs4q8p74Klf9AwpLQwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wewYDVR0f -BHQwcjA4oDagNIYyaHR0cDovL2NybC5jb21vZG9jYS5jb20vQUFBQ2VydGlmaWNhdGVTZXJ2aWNl -cy5jcmwwNqA0oDKGMGh0dHA6Ly9jcmwuY29tb2RvLm5ldC9BQUFDZXJ0aWZpY2F0ZVNlcnZpY2Vz -LmNybDANBgkqhkiG9w0BAQUFAAOCAQEACFb8AvCb6P+k+tZ7xkSAzk/ExfYAWMymtrwUSWgEdujm -7l3sAg9g1o1QGE8mTgHj5rCl7r+8dFRBv/38ErjHT1r0iWAFf2C3BUrz9vHCv8S5dIa2LX1rzNLz -Rt0vxuBqw8M0Ayx9lt1awg6nCpnBBYurDC/zXDrPbDdVCYfeU0BsWO/8tqtlbgT2G9w84FoVxp7Z -8VlIMCFlA2zs6SFz7JsDoeA3raAVGI/6ugLOpyypEBMs1OUIJqsil2D4kF501KKaU73yqWjgom7C -12yxow+ev+to51byrvLjKzg6CYG1a4XXvi3tPxq3smPi9WIsgtRqAEFQ8TmDn5XpNpaYbg== ------END CERTIFICATE----- - -QuoVadis Root CA -================ ------BEGIN CERTIFICATE----- -MIIF0DCCBLigAwIBAgIEOrZQizANBgkqhkiG9w0BAQUFADB/MQswCQYDVQQGEwJCTTEZMBcGA1UE -ChMQUXVvVmFkaXMgTGltaXRlZDElMCMGA1UECxMcUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0 -eTEuMCwGA1UEAxMlUXVvVmFkaXMgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw0wMTAz -MTkxODMzMzNaFw0yMTAzMTcxODMzMzNaMH8xCzAJBgNVBAYTAkJNMRkwFwYDVQQKExBRdW9WYWRp -cyBMaW1pdGVkMSUwIwYDVQQLExxSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MS4wLAYDVQQD -EyVRdW9WYWRpcyBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MIIBIjANBgkqhkiG9w0BAQEF -AAOCAQ8AMIIBCgKCAQEAv2G1lVO6V/z68mcLOhrfEYBklbTRvM16z/Ypli4kVEAkOPcahdxYTMuk -J0KX0J+DisPkBgNbAKVRHnAEdOLB1Dqr1607BxgFjv2DrOpm2RgbaIr1VxqYuvXtdj182d6UajtL -F8HVj71lODqV0D1VNk7feVcxKh7YWWVJWCCYfqtffp/p1k3sg3Spx2zY7ilKhSoGFPlU5tPaZQeL -YzcS19Dsw3sgQUSj7cugF+FxZc4dZjH3dgEZyH0DWLaVSR2mEiboxgx24ONmy+pdpibu5cxfvWen -AScOospUxbF6lR1xHkopigPcakXBpBlebzbNw6Kwt/5cOOJSvPhEQ+aQuwIDAQABo4ICUjCCAk4w -PQYIKwYBBQUHAQEEMTAvMC0GCCsGAQUFBzABhiFodHRwczovL29jc3AucXVvdmFkaXNvZmZzaG9y -ZS5jb20wDwYDVR0TAQH/BAUwAwEB/zCCARoGA1UdIASCAREwggENMIIBCQYJKwYBBAG+WAABMIH7 -MIHUBggrBgEFBQcCAjCBxxqBxFJlbGlhbmNlIG9uIHRoZSBRdW9WYWRpcyBSb290IENlcnRpZmlj -YXRlIGJ5IGFueSBwYXJ0eSBhc3N1bWVzIGFjY2VwdGFuY2Ugb2YgdGhlIHRoZW4gYXBwbGljYWJs -ZSBzdGFuZGFyZCB0ZXJtcyBhbmQgY29uZGl0aW9ucyBvZiB1c2UsIGNlcnRpZmljYXRpb24gcHJh -Y3RpY2VzLCBhbmQgdGhlIFF1b1ZhZGlzIENlcnRpZmljYXRlIFBvbGljeS4wIgYIKwYBBQUHAgEW -Fmh0dHA6Ly93d3cucXVvdmFkaXMuYm0wHQYDVR0OBBYEFItLbe3TKbkGGew5Oanwl4Rqy+/fMIGu -BgNVHSMEgaYwgaOAFItLbe3TKbkGGew5Oanwl4Rqy+/foYGEpIGBMH8xCzAJBgNVBAYTAkJNMRkw -FwYDVQQKExBRdW9WYWRpcyBMaW1pdGVkMSUwIwYDVQQLExxSb290IENlcnRpZmljYXRpb24gQXV0 -aG9yaXR5MS4wLAYDVQQDEyVRdW9WYWRpcyBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5ggQ6 -tlCLMA4GA1UdDwEB/wQEAwIBBjANBgkqhkiG9w0BAQUFAAOCAQEAitQUtf70mpKnGdSkfnIYj9lo -fFIk3WdvOXrEql494liwTXCYhGHoG+NpGA7O+0dQoE7/8CQfvbLO9Sf87C9TqnN7Az10buYWnuul -LsS/VidQK2K6vkscPFVcQR0kvoIgR13VRH56FmjffU1RcHhXHTMe/QKZnAzNCgVPx7uOpHX6Sm2x -gI4JVrmcGmD+XcHXetwReNDWXcG31a0ymQM6isxUJTkxgXsTIlG6Rmyhu576BGxJJnSP0nPrzDCi -5upZIof4l/UO/erMkqQWxFIY6iHOsfHmhIHluqmGKPJDWl0Snawe2ajlCmqnf6CHKc/yiU3U7MXi -5nrQNiOKSnQ2+Q== ------END CERTIFICATE----- - -QuoVadis Root CA 2 -================== ------BEGIN CERTIFICATE----- -MIIFtzCCA5+gAwIBAgICBQkwDQYJKoZIhvcNAQEFBQAwRTELMAkGA1UEBhMCQk0xGTAXBgNVBAoT -EFF1b1ZhZGlzIExpbWl0ZWQxGzAZBgNVBAMTElF1b1ZhZGlzIFJvb3QgQ0EgMjAeFw0wNjExMjQx -ODI3MDBaFw0zMTExMjQxODIzMzNaMEUxCzAJBgNVBAYTAkJNMRkwFwYDVQQKExBRdW9WYWRpcyBM -aW1pdGVkMRswGQYDVQQDExJRdW9WYWRpcyBSb290IENBIDIwggIiMA0GCSqGSIb3DQEBAQUAA4IC -DwAwggIKAoICAQCaGMpLlA0ALa8DKYrwD4HIrkwZhR0In6spRIXzL4GtMh6QRr+jhiYaHv5+HBg6 -XJxgFyo6dIMzMH1hVBHL7avg5tKifvVrbxi3Cgst/ek+7wrGsxDp3MJGF/hd/aTa/55JWpzmM+Yk -lvc/ulsrHHo1wtZn/qtmUIttKGAr79dgw8eTvI02kfN/+NsRE8Scd3bBrrcCaoF6qUWD4gXmuVbB -lDePSHFjIuwXZQeVikvfj8ZaCuWw419eaxGrDPmF60Tp+ARz8un+XJiM9XOva7R+zdRcAitMOeGy -lZUtQofX1bOQQ7dsE/He3fbE+Ik/0XX1ksOR1YqI0JDs3G3eicJlcZaLDQP9nL9bFqyS2+r+eXyt -66/3FsvbzSUr5R/7mp/iUcw6UwxI5g69ybR2BlLmEROFcmMDBOAENisgGQLodKcftslWZvB1Jdxn -wQ5hYIizPtGo/KPaHbDRsSNU30R2be1B2MGyIrZTHN81Hdyhdyox5C315eXbyOD/5YDXC2Og/zOh -D7osFRXql7PSorW+8oyWHhqPHWykYTe5hnMz15eWniN9gqRMgeKh0bpnX5UHoycR7hYQe7xFSkyy -BNKr79X9DFHOUGoIMfmR2gyPZFwDwzqLID9ujWc9Otb+fVuIyV77zGHcizN300QyNQliBJIWENie -J0f7OyHj+OsdWwIDAQABo4GwMIGtMA8GA1UdEwEB/wQFMAMBAf8wCwYDVR0PBAQDAgEGMB0GA1Ud -DgQWBBQahGK8SEwzJQTU7tD2A8QZRtGUazBuBgNVHSMEZzBlgBQahGK8SEwzJQTU7tD2A8QZRtGU -a6FJpEcwRTELMAkGA1UEBhMCQk0xGTAXBgNVBAoTEFF1b1ZhZGlzIExpbWl0ZWQxGzAZBgNVBAMT -ElF1b1ZhZGlzIFJvb3QgQ0EgMoICBQkwDQYJKoZIhvcNAQEFBQADggIBAD4KFk2fBluornFdLwUv -Z+YTRYPENvbzwCYMDbVHZF34tHLJRqUDGCdViXh9duqWNIAXINzng/iN/Ae42l9NLmeyhP3ZRPx3 -UIHmfLTJDQtyU/h2BwdBR5YM++CCJpNVjP4iH2BlfF/nJrP3MpCYUNQ3cVX2kiF495V5+vgtJodm -VjB3pjd4M1IQWK4/YY7yarHvGH5KWWPKjaJW1acvvFYfzznB4vsKqBUsfU16Y8Zsl0Q80m/DShcK -+JDSV6IZUaUtl0HaB0+pUNqQjZRG4T7wlP0QADj1O+hA4bRuVhogzG9Yje0uRY/W6ZM/57Es3zrW -IozchLsib9D45MY56QSIPMO661V6bYCZJPVsAfv4l7CUW+v90m/xd2gNNWQjrLhVoQPRTUIZ3Ph1 -WVaj+ahJefivDrkRoHy3au000LYmYjgahwz46P0u05B/B5EqHdZ+XIWDmbA4CD/pXvk1B+TJYm5X -f6dQlfe6yJvmjqIBxdZmv3lh8zwc4bmCXF2gw+nYSL0ZohEUGW6yhhtoPkg3Goi3XZZenMfvJ2II -4pEZXNLxId26F0KCl3GBUzGpn/Z9Yr9y4aOTHcyKJloJONDO1w2AFrR4pTqHTI2KpdVGl/IsELm8 -VCLAAVBpQ570su9t+Oza8eOx79+Rj1QqCyXBJhnEUhAFZdWCEOrCMc0u ------END CERTIFICATE----- - -QuoVadis Root CA 3 -================== ------BEGIN CERTIFICATE----- -MIIGnTCCBIWgAwIBAgICBcYwDQYJKoZIhvcNAQEFBQAwRTELMAkGA1UEBhMCQk0xGTAXBgNVBAoT -EFF1b1ZhZGlzIExpbWl0ZWQxGzAZBgNVBAMTElF1b1ZhZGlzIFJvb3QgQ0EgMzAeFw0wNjExMjQx -OTExMjNaFw0zMTExMjQxOTA2NDRaMEUxCzAJBgNVBAYTAkJNMRkwFwYDVQQKExBRdW9WYWRpcyBM -aW1pdGVkMRswGQYDVQQDExJRdW9WYWRpcyBSb290IENBIDMwggIiMA0GCSqGSIb3DQEBAQUAA4IC -DwAwggIKAoICAQDMV0IWVJzmmNPTTe7+7cefQzlKZbPoFog02w1ZkXTPkrgEQK0CSzGrvI2RaNgg -DhoB4hp7Thdd4oq3P5kazethq8Jlph+3t723j/z9cI8LoGe+AaJZz3HmDyl2/7FWeUUrH556VOij -KTVopAFPD6QuN+8bv+OPEKhyq1hX51SGyMnzW9os2l2ObjyjPtr7guXd8lyyBTNvijbO0BNO/79K -DDRMpsMhvVAEVeuxu537RR5kFd5VAYwCdrXLoT9CabwvvWhDFlaJKjdhkf2mrk7AyxRllDdLkgbv -BNDInIjbC3uBr7E9KsRlOni27tyAsdLTmZw67mtaa7ONt9XOnMK+pUsvFrGeaDsGb659n/je7Mwp -p5ijJUMv7/FfJuGITfhebtfZFG4ZM2mnO4SJk8RTVROhUXhA+LjJou57ulJCg54U7QVSWllWp5f8 -nT8KKdjcT5EOE7zelaTfi5m+rJsziO+1ga8bxiJTyPbH7pcUsMV8eFLI8M5ud2CEpukqdiDtWAEX -MJPpGovgc2PZapKUSU60rUqFxKMiMPwJ7Wgic6aIDFUhWMXhOp8q3crhkODZc6tsgLjoC2SToJyM -Gf+z0gzskSaHirOi4XCPLArlzW1oUevaPwV/izLmE1xr/l9A4iLItLRkT9a6fUg+qGkM17uGcclz -uD87nSVL2v9A6wIDAQABo4IBlTCCAZEwDwYDVR0TAQH/BAUwAwEB/zCB4QYDVR0gBIHZMIHWMIHT -BgkrBgEEAb5YAAMwgcUwgZMGCCsGAQUFBwICMIGGGoGDQW55IHVzZSBvZiB0aGlzIENlcnRpZmlj -YXRlIGNvbnN0aXR1dGVzIGFjY2VwdGFuY2Ugb2YgdGhlIFF1b1ZhZGlzIFJvb3QgQ0EgMyBDZXJ0 -aWZpY2F0ZSBQb2xpY3kgLyBDZXJ0aWZpY2F0aW9uIFByYWN0aWNlIFN0YXRlbWVudC4wLQYIKwYB -BQUHAgEWIWh0dHA6Ly93d3cucXVvdmFkaXNnbG9iYWwuY29tL2NwczALBgNVHQ8EBAMCAQYwHQYD -VR0OBBYEFPLAE+CCQz777i9nMpY1XNu4ywLQMG4GA1UdIwRnMGWAFPLAE+CCQz777i9nMpY1XNu4 -ywLQoUmkRzBFMQswCQYDVQQGEwJCTTEZMBcGA1UEChMQUXVvVmFkaXMgTGltaXRlZDEbMBkGA1UE -AxMSUXVvVmFkaXMgUm9vdCBDQSAzggIFxjANBgkqhkiG9w0BAQUFAAOCAgEAT62gLEz6wPJv92ZV -qyM07ucp2sNbtrCD2dDQ4iH782CnO11gUyeim/YIIirnv6By5ZwkajGxkHon24QRiSemd1o417+s -hvzuXYO8BsbRd2sPbSQvS3pspweWyuOEn62Iix2rFo1bZhfZFvSLgNLd+LJ2w/w4E6oM3kJpK27z -POuAJ9v1pkQNn1pVWQvVDVJIxa6f8i+AxeoyUDUSly7B4f/xI4hROJ/yZlZ25w9Rl6VSDE1JUZU2 -Pb+iSwwQHYaZTKrzchGT5Or2m9qoXadNt54CrnMAyNojA+j56hl0YgCUyyIgvpSnWbWCar6ZeXqp -8kokUvd0/bpO5qgdAm6xDYBEwa7TIzdfu4V8K5Iu6H6li92Z4b8nby1dqnuH/grdS/yO9SbkbnBC -bjPsMZ57k8HkyWkaPcBrTiJt7qtYTcbQQcEr6k8Sh17rRdhs9ZgC06DYVYoGmRmioHfRMJ6szHXu -g/WwYjnPbFfiTNKRCw51KBuav/0aQ/HKd/s7j2G4aSgWQgRecCocIdiP4b0jWy10QJLZYxkNc91p -vGJHvOB0K7Lrfb5BG7XARsWhIstfTsEokt4YutUqKLsRixeTmJlglFwjz1onl14LBQaTNx47aTbr -qZ5hHY8y2o4M1nQ+ewkk2gF3R8Q7zTSMmfXK4SVhM7JZG+Ju1zdXtg2pEto= ------END CERTIFICATE----- - -Security Communication Root CA -============================== ------BEGIN CERTIFICATE----- -MIIDWjCCAkKgAwIBAgIBADANBgkqhkiG9w0BAQUFADBQMQswCQYDVQQGEwJKUDEYMBYGA1UEChMP -U0VDT00gVHJ1c3QubmV0MScwJQYDVQQLEx5TZWN1cml0eSBDb21tdW5pY2F0aW9uIFJvb3RDQTEw -HhcNMDMwOTMwMDQyMDQ5WhcNMjMwOTMwMDQyMDQ5WjBQMQswCQYDVQQGEwJKUDEYMBYGA1UEChMP -U0VDT00gVHJ1c3QubmV0MScwJQYDVQQLEx5TZWN1cml0eSBDb21tdW5pY2F0aW9uIFJvb3RDQTEw -ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCzs/5/022x7xZ8V6UMbXaKL0u/ZPtM7orw -8yl89f/uKuDp6bpbZCKamm8sOiZpUQWZJtzVHGpxxpp9Hp3dfGzGjGdnSj74cbAZJ6kJDKaVv0uM -DPpVmDvY6CKhS3E4eayXkmmziX7qIWgGmBSWh9JhNrxtJ1aeV+7AwFb9Ms+k2Y7CI9eNqPPYJayX -5HA49LY6tJ07lyZDo6G8SVlyTCMwhwFY9k6+HGhWZq/NQV3Is00qVUarH9oe4kA92819uZKAnDfd -DJZkndwi92SL32HeFZRSFaB9UslLqCHJxrHty8OVYNEP8Ktw+N/LTX7s1vqr2b1/VPKl6Xn62dZ2 -JChzAgMBAAGjPzA9MB0GA1UdDgQWBBSgc0mZaNyFW2XjmygvV5+9M7wHSDALBgNVHQ8EBAMCAQYw -DwYDVR0TAQH/BAUwAwEB/zANBgkqhkiG9w0BAQUFAAOCAQEAaECpqLvkT115swW1F7NgE+vGkl3g -0dNq/vu+m22/xwVtWSDEHPC32oRYAmP6SBbvT6UL90qY8j+eG61Ha2POCEfrUj94nK9NrvjVT8+a -mCoQQTlSxN3Zmw7vkwGusi7KaEIkQmywszo+zenaSMQVy+n5Bw+SUEmK3TGXX8npN6o7WWWXlDLJ -s58+OmJYxUmtYg5xpTKqL8aJdkNAExNnPaJUJRDL8Try2frbSVa7pv6nQTXD4IhhyYjH3zYQIphZ -6rBK+1YWc26sTfcioU+tHXotRSflMMFe8toTyyVCUZVHA4xsIcx0Qu1T/zOLjw9XARYvz6buyXAi -FL39vmwLAw== ------END CERTIFICATE----- - -Sonera Class 2 Root CA -====================== ------BEGIN CERTIFICATE----- -MIIDIDCCAgigAwIBAgIBHTANBgkqhkiG9w0BAQUFADA5MQswCQYDVQQGEwJGSTEPMA0GA1UEChMG -U29uZXJhMRkwFwYDVQQDExBTb25lcmEgQ2xhc3MyIENBMB4XDTAxMDQwNjA3Mjk0MFoXDTIxMDQw -NjA3Mjk0MFowOTELMAkGA1UEBhMCRkkxDzANBgNVBAoTBlNvbmVyYTEZMBcGA1UEAxMQU29uZXJh -IENsYXNzMiBDQTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAJAXSjWdyvANlsdE+hY3 -/Ei9vX+ALTU74W+oZ6m/AxxNjG8yR9VBaKQTBME1DJqEQ/xcHf+Js+gXGM2RX/uJ4+q/Tl18GybT -dXnt5oTjV+WtKcT0OijnpXuENmmz/V52vaMtmdOQTiMofRhj8VQ7Jp12W5dCsv+u8E7s3TmVToMG -f+dJQMjFAbJUWmYdPfz56TwKnoG4cPABi+QjVHzIrviQHgCWctRUz2EjvOr7nQKV0ba5cTppCD8P -tOFCx4j1P5iop7oc4HFx71hXgVB6XGt0Rg6DA5jDjqhu8nYybieDwnPz3BjotJPqdURrBGAgcVeH -nfO+oJAjPYok4doh28MCAwEAAaMzMDEwDwYDVR0TAQH/BAUwAwEB/zARBgNVHQ4ECgQISqCqWITT -XjwwCwYDVR0PBAQDAgEGMA0GCSqGSIb3DQEBBQUAA4IBAQBazof5FnIVV0sd2ZvnoiYw7JNn39Yt -0jSv9zilzqsWuasvfDXLrNAPtEwr/IDva4yRXzZ299uzGxnq9LIR/WFxRL8oszodv7ND6J+/3DEI -cbCdjdY0RzKQxmUk96BKfARzjzlvF4xytb1LyHr4e4PDKE6cCepnP7JnBBvDFNr450kkkdAdavph -Oe9r5yF1BgfYErQhIHBCcYHaPJo2vqZbDWpsmh+Re/n570K6Tk6ezAyNlNzZRZxe7EJQY670XcSx -EtzKO6gunRRaBXW37Ndj4ro1tgQIkejanZz2ZrUYrAqmVCY0M9IbwdR/GjqOC6oybtv8TyWf2TLH -llpwrN9M ------END CERTIFICATE----- - -XRamp Global CA Root -==================== ------BEGIN CERTIFICATE----- -MIIEMDCCAxigAwIBAgIQUJRs7Bjq1ZxN1ZfvdY+grTANBgkqhkiG9w0BAQUFADCBgjELMAkGA1UE -BhMCVVMxHjAcBgNVBAsTFXd3dy54cmFtcHNlY3VyaXR5LmNvbTEkMCIGA1UEChMbWFJhbXAgU2Vj -dXJpdHkgU2VydmljZXMgSW5jMS0wKwYDVQQDEyRYUmFtcCBHbG9iYWwgQ2VydGlmaWNhdGlvbiBB -dXRob3JpdHkwHhcNMDQxMTAxMTcxNDA0WhcNMzUwMTAxMDUzNzE5WjCBgjELMAkGA1UEBhMCVVMx -HjAcBgNVBAsTFXd3dy54cmFtcHNlY3VyaXR5LmNvbTEkMCIGA1UEChMbWFJhbXAgU2VjdXJpdHkg -U2VydmljZXMgSW5jMS0wKwYDVQQDEyRYUmFtcCBHbG9iYWwgQ2VydGlmaWNhdGlvbiBBdXRob3Jp -dHkwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCYJB69FbS638eMpSe2OAtp87ZOqCwu -IR1cRN8hXX4jdP5efrRKt6atH67gBhbim1vZZ3RrXYCPKZ2GG9mcDZhtdhAoWORlsH9KmHmf4MMx -foArtYzAQDsRhtDLooY2YKTVMIJt2W7QDxIEM5dfT2Fa8OT5kavnHTu86M/0ay00fOJIYRyO82FE -zG+gSqmUsE3a56k0enI4qEHMPJQRfevIpoy3hsvKMzvZPTeL+3o+hiznc9cKV6xkmxnr9A8ECIqs -AxcZZPRaJSKNNCyy9mgdEm3Tih4U2sSPpuIjhdV6Db1q4Ons7Be7QhtnqiXtRYMh/MHJfNViPvry -xS3T/dRlAgMBAAGjgZ8wgZwwEwYJKwYBBAGCNxQCBAYeBABDAEEwCwYDVR0PBAQDAgGGMA8GA1Ud -EwEB/wQFMAMBAf8wHQYDVR0OBBYEFMZPoj0GY4QJnM5i5ASsjVy16bYbMDYGA1UdHwQvMC0wK6Ap -oCeGJWh0dHA6Ly9jcmwueHJhbXBzZWN1cml0eS5jb20vWEdDQS5jcmwwEAYJKwYBBAGCNxUBBAMC -AQEwDQYJKoZIhvcNAQEFBQADggEBAJEVOQMBG2f7Shz5CmBbodpNl2L5JFMn14JkTpAuw0kbK5rc -/Kh4ZzXxHfARvbdI4xD2Dd8/0sm2qlWkSLoC295ZLhVbO50WfUfXN+pfTXYSNrsf16GBBEYgoyxt -qZ4Bfj8pzgCT3/3JknOJiWSe5yvkHJEs0rnOfc5vMZnT5r7SHpDwCRR5XCOrTdLaIR9NmXmd4c8n -nxCbHIgNsIpkQTG4DmyQJKSbXHGPurt+HBvbaoAPIbzp26a3QPSyi6mx5O+aGtA9aZnuqCij4Tyz -8LIRnM98QObd50N9otg6tamN8jSZxNQQ4Qb9CYQQO+7ETPTsJ3xCwnR8gooJybQDJbw= ------END CERTIFICATE----- - -Go Daddy Class 2 CA -=================== ------BEGIN CERTIFICATE----- -MIIEADCCAuigAwIBAgIBADANBgkqhkiG9w0BAQUFADBjMQswCQYDVQQGEwJVUzEhMB8GA1UEChMY -VGhlIEdvIERhZGR5IEdyb3VwLCBJbmMuMTEwLwYDVQQLEyhHbyBEYWRkeSBDbGFzcyAyIENlcnRp -ZmljYXRpb24gQXV0aG9yaXR5MB4XDTA0MDYyOTE3MDYyMFoXDTM0MDYyOTE3MDYyMFowYzELMAkG -A1UEBhMCVVMxITAfBgNVBAoTGFRoZSBHbyBEYWRkeSBHcm91cCwgSW5jLjExMC8GA1UECxMoR28g -RGFkZHkgQ2xhc3MgMiBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTCCASAwDQYJKoZIhvcNAQEBBQAD -ggENADCCAQgCggEBAN6d1+pXGEmhW+vXX0iG6r7d/+TvZxz0ZWizV3GgXne77ZtJ6XCAPVYYYwhv -2vLM0D9/AlQiVBDYsoHUwHU9S3/Hd8M+eKsaA7Ugay9qK7HFiH7Eux6wwdhFJ2+qN1j3hybX2C32 -qRe3H3I2TqYXP2WYktsqbl2i/ojgC95/5Y0V4evLOtXiEqITLdiOr18SPaAIBQi2XKVlOARFmR6j -YGB0xUGlcmIbYsUfb18aQr4CUWWoriMYavx4A6lNf4DD+qta/KFApMoZFv6yyO9ecw3ud72a9nmY -vLEHZ6IVDd2gWMZEewo+YihfukEHU1jPEX44dMX4/7VpkI+EdOqXG68CAQOjgcAwgb0wHQYDVR0O -BBYEFNLEsNKR1EwRcbNhyz2h/t2oatTjMIGNBgNVHSMEgYUwgYKAFNLEsNKR1EwRcbNhyz2h/t2o -atTjoWekZTBjMQswCQYDVQQGEwJVUzEhMB8GA1UEChMYVGhlIEdvIERhZGR5IEdyb3VwLCBJbmMu -MTEwLwYDVQQLEyhHbyBEYWRkeSBDbGFzcyAyIENlcnRpZmljYXRpb24gQXV0aG9yaXR5ggEAMAwG -A1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEFBQADggEBADJL87LKPpH8EsahB4yOd6AzBhRckB4Y9wim -PQoZ+YeAEW5p5JYXMP80kWNyOO7MHAGjHZQopDH2esRU1/blMVgDoszOYtuURXO1v0XJJLXVggKt -I3lpjbi2Tc7PTMozI+gciKqdi0FuFskg5YmezTvacPd+mSYgFFQlq25zheabIZ0KbIIOqPjCDPoQ -HmyW74cNxA9hi63ugyuV+I6ShHI56yDqg+2DzZduCLzrTia2cyvk0/ZM/iZx4mERdEr/VxqHD3VI -Ls9RaRegAhJhldXRQLIQTO7ErBBDpqWeCtWVYpoNz4iCxTIM5CufReYNnyicsbkqWletNw+vHX/b -vZ8= ------END CERTIFICATE----- - -Starfield Class 2 CA -==================== ------BEGIN CERTIFICATE----- -MIIEDzCCAvegAwIBAgIBADANBgkqhkiG9w0BAQUFADBoMQswCQYDVQQGEwJVUzElMCMGA1UEChMc -U3RhcmZpZWxkIFRlY2hub2xvZ2llcywgSW5jLjEyMDAGA1UECxMpU3RhcmZpZWxkIENsYXNzIDIg -Q2VydGlmaWNhdGlvbiBBdXRob3JpdHkwHhcNMDQwNjI5MTczOTE2WhcNMzQwNjI5MTczOTE2WjBo -MQswCQYDVQQGEwJVUzElMCMGA1UEChMcU3RhcmZpZWxkIFRlY2hub2xvZ2llcywgSW5jLjEyMDAG -A1UECxMpU3RhcmZpZWxkIENsYXNzIDIgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkwggEgMA0GCSqG -SIb3DQEBAQUAA4IBDQAwggEIAoIBAQC3Msj+6XGmBIWtDBFk385N78gDGIc/oav7PKaf8MOh2tTY -bitTkPskpD6E8J7oX+zlJ0T1KKY/e97gKvDIr1MvnsoFAZMej2YcOadN+lq2cwQlZut3f+dZxkqZ -JRRU6ybH838Z1TBwj6+wRir/resp7defqgSHo9T5iaU0X9tDkYI22WY8sbi5gv2cOj4QyDvvBmVm -epsZGD3/cVE8MC5fvj13c7JdBmzDI1aaK4UmkhynArPkPw2vCHmCuDY96pzTNbO8acr1zJ3o/WSN -F4Azbl5KXZnJHoe0nRrA1W4TNSNe35tfPe/W93bC6j67eA0cQmdrBNj41tpvi/JEoAGrAgEDo4HF -MIHCMB0GA1UdDgQWBBS/X7fRzt0fhvRbVazc1xDCDqmI5zCBkgYDVR0jBIGKMIGHgBS/X7fRzt0f -hvRbVazc1xDCDqmI56FspGowaDELMAkGA1UEBhMCVVMxJTAjBgNVBAoTHFN0YXJmaWVsZCBUZWNo -bm9sb2dpZXMsIEluYy4xMjAwBgNVBAsTKVN0YXJmaWVsZCBDbGFzcyAyIENlcnRpZmljYXRpb24g -QXV0aG9yaXR5ggEAMAwGA1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEFBQADggEBAAWdP4id0ckaVaGs -afPzWdqbAYcaT1epoXkJKtv3L7IezMdeatiDh6GX70k1PncGQVhiv45YuApnP+yz3SFmH8lU+nLM -PUxA2IGvd56Deruix/U0F47ZEUD0/CwqTRV/p2JdLiXTAAsgGh1o+Re49L2L7ShZ3U0WixeDyLJl -xy16paq8U4Zt3VekyvggQQto8PT7dL5WXXp59fkdheMtlb71cZBDzI0fmgAKhynpVSJYACPq4xJD -KVtHCN2MQWplBqjlIapBtJUhlbl90TSrE9atvNziPTnNvT51cKEYWQPJIrSPnNVeKtelttQKbfi3 -QBFGmh95DmK/D5fs4C8fF5Q= ------END CERTIFICATE----- - -Taiwan GRCA -=========== ------BEGIN CERTIFICATE----- -MIIFcjCCA1qgAwIBAgIQH51ZWtcvwgZEpYAIaeNe9jANBgkqhkiG9w0BAQUFADA/MQswCQYDVQQG -EwJUVzEwMC4GA1UECgwnR292ZXJubWVudCBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MB4X -DTAyMTIwNTEzMjMzM1oXDTMyMTIwNTEzMjMzM1owPzELMAkGA1UEBhMCVFcxMDAuBgNVBAoMJ0dv -dmVybm1lbnQgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTCCAiIwDQYJKoZIhvcNAQEBBQAD -ggIPADCCAgoCggIBAJoluOzMonWoe/fOW1mKydGGEghU7Jzy50b2iPN86aXfTEc2pBsBHH8eV4qN -w8XRIePaJD9IK/ufLqGU5ywck9G/GwGHU5nOp/UKIXZ3/6m3xnOUT0b3EEk3+qhZSV1qgQdW8or5 -BtD3cCJNtLdBuTK4sfCxw5w/cP1T3YGq2GN49thTbqGsaoQkclSGxtKyyhwOeYHWtXBiCAEuTk8O -1RGvqa/lmr/czIdtJuTJV6L7lvnM4T9TjGxMfptTCAtsF/tnyMKtsc2AtJfcdgEWFelq16TheEfO -htX7MfP6Mb40qij7cEwdScevLJ1tZqa2jWR+tSBqnTuBto9AAGdLiYa4zGX+FVPpBMHWXx1E1wov -J5pGfaENda1UhhXcSTvxls4Pm6Dso3pdvtUqdULle96ltqqvKKyskKw4t9VoNSZ63Pc78/1Fm9G7 -Q3hub/FCVGqY8A2tl+lSXunVanLeavcbYBT0peS2cWeqH+riTcFCQP5nRhc4L0c/cZyu5SHKYS1t -B6iEfC3uUSXxY5Ce/eFXiGvviiNtsea9P63RPZYLhY3Naye7twWb7LuRqQoHEgKXTiCQ8P8NHuJB -O9NAOueNXdpm5AKwB1KYXA6OM5zCppX7VRluTI6uSw+9wThNXo+EHWbNxWCWtFJaBYmOlXqYwZE8 -lSOyDvR5tMl8wUohAgMBAAGjajBoMB0GA1UdDgQWBBTMzO/MKWCkO7GStjz6MmKPrCUVOzAMBgNV -HRMEBTADAQH/MDkGBGcqBwAEMTAvMC0CAQAwCQYFKw4DAhoFADAHBgVnKgMAAAQUA5vwIhP/lSg2 -09yewDL7MTqKUWUwDQYJKoZIhvcNAQEFBQADggIBAECASvomyc5eMN1PhnR2WPWus4MzeKR6dBcZ -TulStbngCnRiqmjKeKBMmo4sIy7VahIkv9Ro04rQ2JyftB8M3jh+Vzj8jeJPXgyfqzvS/3WXy6Tj -Zwj/5cAWtUgBfen5Cv8b5Wppv3ghqMKnI6mGq3ZW6A4M9hPdKmaKZEk9GhiHkASfQlK3T8v+R0F2 -Ne//AHY2RTKbxkaFXeIksB7jSJaYV0eUVXoPQbFEJPPB/hprv4j9wabak2BegUqZIJxIZhm1AHlU -D7gsL0u8qV1bYH+Mh6XgUmMqvtg7hUAV/h62ZT/FS9p+tXo1KaMuephgIqP0fSdOLeq0dDzpD6Qz -DxARvBMB1uUO07+1EqLhRSPAzAhuYbeJq4PjJB7mXQfnHyA+z2fI56wwbSdLaG5LKlwCCDTb+Hbk -Z6MmnD+iMsJKxYEYMRBWqoTvLQr/uB930r+lWKBi5NdLkXWNiYCYfm3LU05er/ayl4WXudpVBrkk -7tfGOB5jGxI7leFYrPLfhNVfmS8NVVvmONsuP3LpSIXLuykTjx44VbnzssQwmSNOXfJIoRIM3BKQ -CZBUkQM8R+XVyWXgt0t97EfTsws+rZ7QdAAO671RrcDeLMDDav7v3Aun+kbfYNucpllQdSNpc5Oy -+fwC00fmcc4QAu4njIT/rEUNE1yDMuAlpYYsfPQS ------END CERTIFICATE----- - -DigiCert Assured ID Root CA -=========================== ------BEGIN CERTIFICATE----- -MIIDtzCCAp+gAwIBAgIQDOfg5RfYRv6P5WD8G/AwOTANBgkqhkiG9w0BAQUFADBlMQswCQYDVQQG -EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSQw -IgYDVQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgQ0EwHhcNMDYxMTEwMDAwMDAwWhcNMzEx -MTEwMDAwMDAwWjBlMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQL -ExB3d3cuZGlnaWNlcnQuY29tMSQwIgYDVQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgQ0Ew -ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCtDhXO5EOAXLGH87dg+XESpa7cJpSIqvTO -9SA5KFhgDPiA2qkVlTJhPLWxKISKityfCgyDF3qPkKyK53lTXDGEKvYPmDI2dsze3Tyoou9q+yHy -UmHfnyDXH+Kx2f4YZNISW1/5WBg1vEfNoTb5a3/UsDg+wRvDjDPZ2C8Y/igPs6eD1sNuRMBhNZYW -/lmci3Zt1/GiSw0r/wty2p5g0I6QNcZ4VYcgoc/lbQrISXwxmDNsIumH0DJaoroTghHtORedmTpy -oeb6pNnVFzF1roV9Iq4/AUaG9ih5yLHa5FcXxH4cDrC0kqZWs72yl+2qp/C3xag/lRbQ/6GW6whf -GHdPAgMBAAGjYzBhMA4GA1UdDwEB/wQEAwIBhjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBRF -66Kv9JLLgjEtUYunpyGd823IDzAfBgNVHSMEGDAWgBRF66Kv9JLLgjEtUYunpyGd823IDzANBgkq -hkiG9w0BAQUFAAOCAQEAog683+Lt8ONyc3pklL/3cmbYMuRCdWKuh+vy1dneVrOfzM4UKLkNl2Bc -EkxY5NM9g0lFWJc1aRqoR+pWxnmrEthngYTffwk8lOa4JiwgvT2zKIn3X/8i4peEH+ll74fg38Fn -SbNd67IJKusm7Xi+fT8r87cmNW1fiQG2SVufAQWbqz0lwcy2f8Lxb4bG+mRo64EtlOtCt/qMHt1i -8b5QZ7dsvfPxH2sMNgcWfzd8qVttevESRmCD1ycEvkvOl77DZypoEd+A5wwzZr8TDRRu838fYxAe -+o0bJW1sj6W3YQGx0qMmoRBxna3iw/nDmVG3KwcIzi7mULKn+gpFL6Lw8g== ------END CERTIFICATE----- - -DigiCert Global Root CA -======================= ------BEGIN CERTIFICATE----- -MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBhMQswCQYDVQQG -EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSAw -HgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBDQTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAw -MDAwMDBaMGExCzAJBgNVBAYTAlVTMRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3 -dy5kaWdpY2VydC5jb20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkq -hkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsBCSDMAZOn -TjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97nh6Vfe63SKMI2tavegw5 -BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt43C/dxC//AH2hdmoRBBYMql1GNXRor5H -4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7PT19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y -7vrTC0LUq7dBMtoM1O/4gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQAB -o2MwYTAOBgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbRTLtm -8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUwDQYJKoZIhvcNAQEF -BQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/EsrhMAtudXH/vTBH1jLuG2cenTnmCmr -EbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIt -tep3Sp+dWOIrWcBAI+0tKIJFPnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886 -UAb3LujEV0lsYSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk -CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4= ------END CERTIFICATE----- - -DigiCert High Assurance EV Root CA -================================== ------BEGIN CERTIFICATE----- -MIIDxTCCAq2gAwIBAgIQAqxcJmoLQJuPC3nyrkYldzANBgkqhkiG9w0BAQUFADBsMQswCQYDVQQG -EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSsw -KQYDVQQDEyJEaWdpQ2VydCBIaWdoIEFzc3VyYW5jZSBFViBSb290IENBMB4XDTA2MTExMDAwMDAw -MFoXDTMxMTExMDAwMDAwMFowbDELMAkGA1UEBhMCVVMxFTATBgNVBAoTDERpZ2lDZXJ0IEluYzEZ -MBcGA1UECxMQd3d3LmRpZ2ljZXJ0LmNvbTErMCkGA1UEAxMiRGlnaUNlcnQgSGlnaCBBc3N1cmFu -Y2UgRVYgUm9vdCBDQTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAMbM5XPm+9S75S0t -Mqbf5YE/yc0lSbZxKsPVlDRnogocsF9ppkCxxLeyj9CYpKlBWTrT3JTWPNt0OKRKzE0lgvdKpVMS -OO7zSW1xkX5jtqumX8OkhPhPYlG++MXs2ziS4wblCJEMxChBVfvLWokVfnHoNb9Ncgk9vjo4UFt3 -MRuNs8ckRZqnrG0AFFoEt7oT61EKmEFBIk5lYYeBQVCmeVyJ3hlKV9Uu5l0cUyx+mM0aBhakaHPQ -NAQTXKFx01p8VdteZOE3hzBWBOURtCmAEvF5OYiiAhF8J2a3iLd48soKqDirCmTCv2ZdlYTBoSUe -h10aUAsgEsxBu24LUTi4S8sCAwEAAaNjMGEwDgYDVR0PAQH/BAQDAgGGMA8GA1UdEwEB/wQFMAMB -Af8wHQYDVR0OBBYEFLE+w2kD+L9HAdSYJhoIAu9jZCvDMB8GA1UdIwQYMBaAFLE+w2kD+L9HAdSY -JhoIAu9jZCvDMA0GCSqGSIb3DQEBBQUAA4IBAQAcGgaX3NecnzyIZgYIVyHbIUf4KmeqvxgydkAQ -V8GK83rZEWWONfqe/EW1ntlMMUu4kehDLI6zeM7b41N5cdblIZQB2lWHmiRk9opmzN6cN82oNLFp -myPInngiK3BD41VHMWEZ71jFhS9OMPagMRYjyOfiZRYzy78aG6A9+MpeizGLYAiJLQwGXFK3xPkK -mNEVX58Svnw2Yzi9RKR/5CYrCsSXaQ3pjOLAEFe4yHYSkVXySGnYvCoCWw9E1CAx2/S6cCZdkGCe -vEsXCS+0yx5DaMkHJ8HSXPfqIbloEpw8nL+e/IBcm2PN7EeqJSdnoDfzAIJ9VNep+OkuE6N36B9K ------END CERTIFICATE----- - -DST Root CA X3 -============== ------BEGIN CERTIFICATE----- -MIIDSjCCAjKgAwIBAgIQRK+wgNajJ7qJMDmGLvhAazANBgkqhkiG9w0BAQUFADA/MSQwIgYDVQQK -ExtEaWdpdGFsIFNpZ25hdHVyZSBUcnVzdCBDby4xFzAVBgNVBAMTDkRTVCBSb290IENBIFgzMB4X -DTAwMDkzMDIxMTIxOVoXDTIxMDkzMDE0MDExNVowPzEkMCIGA1UEChMbRGlnaXRhbCBTaWduYXR1 -cmUgVHJ1c3QgQ28uMRcwFQYDVQQDEw5EU1QgUm9vdCBDQSBYMzCCASIwDQYJKoZIhvcNAQEBBQAD -ggEPADCCAQoCggEBAN+v6ZdQCINXtMxiZfaQguzH0yxrMMpb7NnDfcdAwRgUi+DoM3ZJKuM/IUmT -rE4Orz5Iy2Xu/NMhD2XSKtkyj4zl93ewEnu1lcCJo6m67XMuegwGMoOifooUMM0RoOEqOLl5CjH9 -UL2AZd+3UWODyOKIYepLYYHsUmu5ouJLGiifSKOeDNoJjj4XLh7dIN9bxiqKqy69cK3FCxolkHRy -xXtqqzTWMIn/5WgTe1QLyNau7Fqckh49ZLOMxt+/yUFw7BZy1SbsOFU5Q9D8/RhcQPGX69Wam40d -utolucbY38EVAjqr2m7xPi71XAicPNaDaeQQmxkqtilX4+U9m5/wAl0CAwEAAaNCMEAwDwYDVR0T -AQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFMSnsaR7LHH62+FLkHX/xBVghYkQ -MA0GCSqGSIb3DQEBBQUAA4IBAQCjGiybFwBcqR7uKGY3Or+Dxz9LwwmglSBd49lZRNI+DT69ikug -dB/OEIKcdBodfpga3csTS7MgROSR6cz8faXbauX+5v3gTt23ADq1cEmv8uXrAvHRAosZy5Q6XkjE -GB5YGV8eAlrwDPGxrancWYaLbumR9YbK+rlmM6pZW87ipxZzR8srzJmwN0jP41ZL9c8PDHIyh8bw -RLtTcm1D9SZImlJnt1ir/md2cXjbDaJWFBM5JDGFoqgCWjBH4d1QB7wCCZAA62RjYJsWvIjJEubS -fZGL+T0yjWW06XyxV3bqxbYoOb8VZRzI9neWagqNdwvYkQsEjgfbKbYK7p2CNTUQ ------END CERTIFICATE----- - -SwissSign Gold CA - G2 -====================== ------BEGIN CERTIFICATE----- -MIIFujCCA6KgAwIBAgIJALtAHEP1Xk+wMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNVBAYTAkNIMRUw -EwYDVQQKEwxTd2lzc1NpZ24gQUcxHzAdBgNVBAMTFlN3aXNzU2lnbiBHb2xkIENBIC0gRzIwHhcN -MDYxMDI1MDgzMDM1WhcNMzYxMDI1MDgzMDM1WjBFMQswCQYDVQQGEwJDSDEVMBMGA1UEChMMU3dp -c3NTaWduIEFHMR8wHQYDVQQDExZTd2lzc1NpZ24gR29sZCBDQSAtIEcyMIICIjANBgkqhkiG9w0B -AQEFAAOCAg8AMIICCgKCAgEAr+TufoskDhJuqVAtFkQ7kpJcyrhdhJJCEyq8ZVeCQD5XJM1QiyUq -t2/876LQwB8CJEoTlo8jE+YoWACjR8cGp4QjK7u9lit/VcyLwVcfDmJlD909Vopz2q5+bbqBHH5C -jCA12UNNhPqE21Is8w4ndwtrvxEvcnifLtg+5hg3Wipy+dpikJKVyh+c6bM8K8vzARO/Ws/BtQpg -vd21mWRTuKCWs2/iJneRjOBiEAKfNA+k1ZIzUd6+jbqEemA8atufK+ze3gE/bk3lUIbLtK/tREDF -ylqM2tIrfKjuvqblCqoOpd8FUrdVxyJdMmqXl2MT28nbeTZ7hTpKxVKJ+STnnXepgv9VHKVxaSvR -AiTysybUa9oEVeXBCsdtMDeQKuSeFDNeFhdVxVu1yzSJkvGdJo+hB9TGsnhQ2wwMC3wLjEHXuend -jIj3o02yMszYF9rNt85mndT9Xv+9lz4pded+p2JYryU0pUHHPbwNUMoDAw8IWh+Vc3hiv69yFGkO -peUDDniOJihC8AcLYiAQZzlG+qkDzAQ4embvIIO1jEpWjpEA/I5cgt6IoMPiaG59je883WX0XaxR -7ySArqpWl2/5rX3aYT+YdzylkbYcjCbaZaIJbcHiVOO5ykxMgI93e2CaHt+28kgeDrpOVG2Y4OGi -GqJ3UM/EY5LsRxmd6+ZrzsECAwEAAaOBrDCBqTAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUw -AwEB/zAdBgNVHQ4EFgQUWyV7lqRlUX64OfPAeGZe6Drn8O4wHwYDVR0jBBgwFoAUWyV7lqRlUX64 -OfPAeGZe6Drn8O4wRgYDVR0gBD8wPTA7BglghXQBWQECAQEwLjAsBggrBgEFBQcCARYgaHR0cDov -L3JlcG9zaXRvcnkuc3dpc3NzaWduLmNvbS8wDQYJKoZIhvcNAQEFBQADggIBACe645R88a7A3hfm -5djV9VSwg/S7zV4Fe0+fdWavPOhWfvxyeDgD2StiGwC5+OlgzczOUYrHUDFu4Up+GC9pWbY9ZIEr -44OE5iKHjn3g7gKZYbge9LgriBIWhMIxkziWMaa5O1M/wySTVltpkuzFwbs4AOPsF6m43Md8AYOf -Mke6UiI0HTJ6CVanfCU2qT1L2sCCbwq7EsiHSycR+R4tx5M/nttfJmtS2S6K8RTGRI0Vqbe/vd6m -Gu6uLftIdxf+u+yvGPUqUfA5hJeVbG4bwyvEdGB5JbAKJ9/fXtI5z0V9QkvfsywexcZdylU6oJxp -mo/a77KwPJ+HbBIrZXAVUjEaJM9vMSNQH4xPjyPDdEFjHFWoFN0+4FFQz/EbMFYOkrCChdiDyyJk -vC24JdVUorgG6q2SpCSgwYa1ShNqR88uC1aVVMvOmttqtKay20EIhid392qgQmwLOM7XdVAyksLf -KzAiSNDVQTglXaTpXZ/GlHXQRf0wl0OPkKsKx4ZzYEppLd6leNcG2mqeSz53OiATIgHQv2ieY2Br -NU0LbbqhPcCT4H8js1WtciVORvnSFu+wZMEBnunKoGqYDs/YYPIvSbjkQuE4NRb0yG5P94FW6Lqj -viOvrv1vA+ACOzB2+httQc8Bsem4yWb02ybzOqR08kkkW8mw0FfB+j564ZfJ ------END CERTIFICATE----- - -SwissSign Silver CA - G2 -======================== ------BEGIN CERTIFICATE----- -MIIFvTCCA6WgAwIBAgIITxvUL1S7L0swDQYJKoZIhvcNAQEFBQAwRzELMAkGA1UEBhMCQ0gxFTAT -BgNVBAoTDFN3aXNzU2lnbiBBRzEhMB8GA1UEAxMYU3dpc3NTaWduIFNpbHZlciBDQSAtIEcyMB4X -DTA2MTAyNTA4MzI0NloXDTM2MTAyNTA4MzI0NlowRzELMAkGA1UEBhMCQ0gxFTATBgNVBAoTDFN3 -aXNzU2lnbiBBRzEhMB8GA1UEAxMYU3dpc3NTaWduIFNpbHZlciBDQSAtIEcyMIICIjANBgkqhkiG -9w0BAQEFAAOCAg8AMIICCgKCAgEAxPGHf9N4Mfc4yfjDmUO8x/e8N+dOcbpLj6VzHVxumK4DV644 -N0MvFz0fyM5oEMF4rhkDKxD6LHmD9ui5aLlV8gREpzn5/ASLHvGiTSf5YXu6t+WiE7brYT7QbNHm -+/pe7R20nqA1W6GSy/BJkv6FCgU+5tkL4k+73JU3/JHpMjUi0R86TieFnbAVlDLaYQ1HTWBCrpJH -6INaUFjpiou5XaHc3ZlKHzZnu0jkg7Y360g6rw9njxcH6ATK72oxh9TAtvmUcXtnZLi2kUpCe2Uu -MGoM9ZDulebyzYLs2aFK7PayS+VFheZteJMELpyCbTapxDFkH4aDCyr0NQp4yVXPQbBH6TCfmb5h -qAaEuSh6XzjZG6k4sIN/c8HDO0gqgg8hm7jMqDXDhBuDsz6+pJVpATqJAHgE2cn0mRmrVn5bi4Y5 -FZGkECwJMoBgs5PAKrYYC51+jUnyEEp/+dVGLxmSo5mnJqy7jDzmDrxHB9xzUfFwZC8I+bRHHTBs -ROopN4WSaGa8gzj+ezku01DwH/teYLappvonQfGbGHLy9YR0SslnxFSuSGTfjNFusB3hB48IHpmc -celM2KX3RxIfdNFRnobzwqIjQAtz20um53MGjMGg6cFZrEb65i/4z3GcRm25xBWNOHkDRUjvxF3X -CO6HOSKGsg0PWEP3calILv3q1h8CAwEAAaOBrDCBqTAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/ -BAUwAwEB/zAdBgNVHQ4EFgQUF6DNweRBtjpbO8tFnb0cwpj6hlgwHwYDVR0jBBgwFoAUF6DNweRB -tjpbO8tFnb0cwpj6hlgwRgYDVR0gBD8wPTA7BglghXQBWQEDAQEwLjAsBggrBgEFBQcCARYgaHR0 -cDovL3JlcG9zaXRvcnkuc3dpc3NzaWduLmNvbS8wDQYJKoZIhvcNAQEFBQADggIBAHPGgeAn0i0P -4JUw4ppBf1AsX19iYamGamkYDHRJ1l2E6kFSGG9YrVBWIGrGvShpWJHckRE1qTodvBqlYJ7YH39F -kWnZfrt4csEGDyrOj4VwYaygzQu4OSlWhDJOhrs9xCrZ1x9y7v5RoSJBsXECYxqCsGKrXlcSH9/L -3XWgwF15kIwb4FDm3jH+mHtwX6WQ2K34ArZv02DdQEsixT2tOnqfGhpHkXkzuoLcMmkDlm4fS/Bx -/uNncqCxv1yL5PqZIseEuRuNI5c/7SXgz2W79WEE790eslpBIlqhn10s6FvJbakMDHiqYMZWjwFa -DGi8aRl5xB9+lwW/xekkUV7U1UtT7dkjWjYDZaPBA61BMPNGG4WQr2W11bHkFlt4dR2Xem1ZqSqP -e97Dh4kQmUlzeMg9vVE1dCrV8X5pGyq7O70luJpaPXJhkGaH7gzWTdQRdAtq/gsD/KNVV4n+Ssuu -WxcFyPKNIzFTONItaj+CuY0IavdeQXRuwxF+B6wpYJE/OMpXEA29MC/HpeZBoNquBYeaoKRlbEwJ -DIm6uNO5wJOKMPqN5ZprFQFOZ6raYlY+hAhm0sQ2fac+EPyI4NSA5QC9qvNOBqN6avlicuMJT+ub -DgEj8Z+7fNzcbBGXJbLytGMU0gYqZ4yD9c7qB9iaah7s5Aq7KkzrCWA5zspi2C5u ------END CERTIFICATE----- - -GeoTrust Primary Certification Authority -======================================== ------BEGIN CERTIFICATE----- -MIIDfDCCAmSgAwIBAgIQGKy1av1pthU6Y2yv2vrEoTANBgkqhkiG9w0BAQUFADBYMQswCQYDVQQG -EwJVUzEWMBQGA1UEChMNR2VvVHJ1c3QgSW5jLjExMC8GA1UEAxMoR2VvVHJ1c3QgUHJpbWFyeSBD -ZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw0wNjExMjcwMDAwMDBaFw0zNjA3MTYyMzU5NTlaMFgx -CzAJBgNVBAYTAlVTMRYwFAYDVQQKEw1HZW9UcnVzdCBJbmMuMTEwLwYDVQQDEyhHZW9UcnVzdCBQ -cmltYXJ5IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB -CgKCAQEAvrgVe//UfH1nrYNke8hCUy3f9oQIIGHWAVlqnEQRr+92/ZV+zmEwu3qDXwK9AWbK7hWN -b6EwnL2hhZ6UOvNWiAAxz9juapYC2e0DjPt1befquFUWBRaa9OBesYjAZIVcFU2Ix7e64HXprQU9 -nceJSOC7KMgD4TCTZF5SwFlwIjVXiIrxlQqD17wxcwE07e9GceBrAqg1cmuXm2bgyxx5X9gaBGge -RwLmnWDiNpcB3841kt++Z8dtd1k7j53WkBWUvEI0EME5+bEnPn7WinXFsq+W06Lem+SYvn3h6YGt -tm/81w7a4DSwDRp35+MImO9Y+pyEtzavwt+s0vQQBnBxNQIDAQABo0IwQDAPBgNVHRMBAf8EBTAD -AQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQULNVQQZcVi/CPNmFbSvtr2ZnJM5IwDQYJKoZI -hvcNAQEFBQADggEBAFpwfyzdtzRP9YZRqSa+S7iq8XEN3GHHoOo0Hnp3DwQ16CePbJC/kRYkRj5K -Ts4rFtULUh38H2eiAkUxT87z+gOneZ1TatnaYzr4gNfTmeGl4b7UVXGYNTq+k+qurUKykG/g/CFN -NWMziUnWm07Kx+dOCQD32sfvmWKZd7aVIl6KoKv0uHiYyjgZmclynnjNS6yvGaBzEi38wkG6gZHa -Floxt/m0cYASSJlyc1pZU8FjUjPtp8nSOQJw+uCxQmYpqptR7TBUIhRf2asdweSU8Pj1K/fqynhG -1riR/aYNKxoUAT6A8EKglQdebc3MS6RFjasS6LPeWuWgfOgPIh1a6Vk= ------END CERTIFICATE----- - -thawte Primary Root CA -====================== ------BEGIN CERTIFICATE----- -MIIEIDCCAwigAwIBAgIQNE7VVyDV7exJ9C/ON9srbTANBgkqhkiG9w0BAQUFADCBqTELMAkGA1UE -BhMCVVMxFTATBgNVBAoTDHRoYXd0ZSwgSW5jLjEoMCYGA1UECxMfQ2VydGlmaWNhdGlvbiBTZXJ2 -aWNlcyBEaXZpc2lvbjE4MDYGA1UECxMvKGMpIDIwMDYgdGhhd3RlLCBJbmMuIC0gRm9yIGF1dGhv -cml6ZWQgdXNlIG9ubHkxHzAdBgNVBAMTFnRoYXd0ZSBQcmltYXJ5IFJvb3QgQ0EwHhcNMDYxMTE3 -MDAwMDAwWhcNMzYwNzE2MjM1OTU5WjCBqTELMAkGA1UEBhMCVVMxFTATBgNVBAoTDHRoYXd0ZSwg -SW5jLjEoMCYGA1UECxMfQ2VydGlmaWNhdGlvbiBTZXJ2aWNlcyBEaXZpc2lvbjE4MDYGA1UECxMv -KGMpIDIwMDYgdGhhd3RlLCBJbmMuIC0gRm9yIGF1dGhvcml6ZWQgdXNlIG9ubHkxHzAdBgNVBAMT -FnRoYXd0ZSBQcmltYXJ5IFJvb3QgQ0EwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCs -oPD7gFnUnMekz52hWXMJEEUMDSxuaPFsW0hoSVk3/AszGcJ3f8wQLZU0HObrTQmnHNK4yZc2AreJ -1CRfBsDMRJSUjQJib+ta3RGNKJpchJAQeg29dGYvajig4tVUROsdB58Hum/u6f1OCyn1PoSgAfGc -q/gcfomk6KHYcWUNo1F77rzSImANuVud37r8UVsLr5iy6S7pBOhih94ryNdOwUxkHt3Ph1i6Sk/K -aAcdHJ1KxtUvkcx8cXIcxcBn6zL9yZJclNqFwJu/U30rCfSMnZEfl2pSy94JNqR32HuHUETVPm4p -afs5SSYeCaWAe0At6+gnhcn+Yf1+5nyXHdWdAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYD -VR0PAQH/BAQDAgEGMB0GA1UdDgQWBBR7W0XPr87Lev0xkhpqtvNG61dIUDANBgkqhkiG9w0BAQUF -AAOCAQEAeRHAS7ORtvzw6WfUDW5FvlXok9LOAz/t2iWwHVfLHjp2oEzsUHboZHIMpKnxuIvW1oeE -uzLlQRHAd9mzYJ3rG9XRbkREqaYB7FViHXe4XI5ISXycO1cRrK1zN44veFyQaEfZYGDm/Ac9IiAX -xPcW6cTYcvnIc3zfFi8VqT79aie2oetaupgf1eNNZAqdE8hhuvU5HIe6uL17In/2/qxAeeWsEG89 -jxt5dovEN7MhGITlNgDrYyCZuen+MwS7QcjBAvlEYyCegc5C09Y/LHbTY5xZ3Y+m4Q6gLkH3LpVH -z7z9M/P2C2F+fpErgUfCJzDupxBdN49cOSvkBPB7jVaMaA== ------END CERTIFICATE----- - -VeriSign Class 3 Public Primary Certification Authority - G5 -============================================================ ------BEGIN CERTIFICATE----- -MIIE0zCCA7ugAwIBAgIQGNrRniZ96LtKIVjNzGs7SjANBgkqhkiG9w0BAQUFADCByjELMAkGA1UE -BhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMR8wHQYDVQQLExZWZXJpU2lnbiBUcnVzdCBO -ZXR3b3JrMTowOAYDVQQLEzEoYykgMjAwNiBWZXJpU2lnbiwgSW5jLiAtIEZvciBhdXRob3JpemVk -IHVzZSBvbmx5MUUwQwYDVQQDEzxWZXJpU2lnbiBDbGFzcyAzIFB1YmxpYyBQcmltYXJ5IENlcnRp -ZmljYXRpb24gQXV0aG9yaXR5IC0gRzUwHhcNMDYxMTA4MDAwMDAwWhcNMzYwNzE2MjM1OTU5WjCB -yjELMAkGA1UEBhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMR8wHQYDVQQLExZWZXJpU2ln -biBUcnVzdCBOZXR3b3JrMTowOAYDVQQLEzEoYykgMjAwNiBWZXJpU2lnbiwgSW5jLiAtIEZvciBh -dXRob3JpemVkIHVzZSBvbmx5MUUwQwYDVQQDEzxWZXJpU2lnbiBDbGFzcyAzIFB1YmxpYyBQcmlt -YXJ5IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IC0gRzUwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAw -ggEKAoIBAQCvJAgIKXo1nmAMqudLO07cfLw8RRy7K+D+KQL5VwijZIUVJ/XxrcgxiV0i6CqqpkKz -j/i5Vbext0uz/o9+B1fs70PbZmIVYc9gDaTY3vjgw2IIPVQT60nKWVSFJuUrjxuf6/WhkcIzSdhD -Y2pSS9KP6HBRTdGJaXvHcPaz3BJ023tdS1bTlr8Vd6Gw9KIl8q8ckmcY5fQGBO+QueQA5N06tRn/ -Arr0PO7gi+s3i+z016zy9vA9r911kTMZHRxAy3QkGSGT2RT+rCpSx4/VBEnkjWNHiDxpg8v+R70r -fk/Fla4OndTRQ8Bnc+MUCH7lP59zuDMKz10/NIeWiu5T6CUVAgMBAAGjgbIwga8wDwYDVR0TAQH/ -BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwbQYIKwYBBQUHAQwEYTBfoV2gWzBZMFcwVRYJaW1hZ2Uv -Z2lmMCEwHzAHBgUrDgMCGgQUj+XTGoasjY5rw8+AatRIGCx7GS4wJRYjaHR0cDovL2xvZ28udmVy -aXNpZ24uY29tL3ZzbG9nby5naWYwHQYDVR0OBBYEFH/TZafC3ey78DAJ80M5+gKvMzEzMA0GCSqG -SIb3DQEBBQUAA4IBAQCTJEowX2LP2BqYLz3q3JktvXf2pXkiOOzEp6B4Eq1iDkVwZMXnl2YtmAl+ -X6/WzChl8gGqCBpH3vn5fJJaCGkgDdk+bW48DW7Y5gaRQBi5+MHt39tBquCWIMnNZBU4gcmU7qKE -KQsTb47bDN0lAtukixlE0kF6BWlKWE9gyn6CagsCqiUXObXbf+eEZSqVir2G3l6BFoMtEMze/aiC -Km0oHw0LxOXnGiYZ4fQRbxC1lfznQgUy286dUV4otp6F01vvpX1FQHKOtw5rDgb7MzVIcbidJ4vE -ZV8NhnacRHr2lVz2XTIIM6RUthg/aFzyQkqFOFSDX9HoLPKsEdao7WNq ------END CERTIFICATE----- - -SecureTrust CA -============== ------BEGIN CERTIFICATE----- -MIIDuDCCAqCgAwIBAgIQDPCOXAgWpa1Cf/DrJxhZ0DANBgkqhkiG9w0BAQUFADBIMQswCQYDVQQG -EwJVUzEgMB4GA1UEChMXU2VjdXJlVHJ1c3QgQ29ycG9yYXRpb24xFzAVBgNVBAMTDlNlY3VyZVRy -dXN0IENBMB4XDTA2MTEwNzE5MzExOFoXDTI5MTIzMTE5NDA1NVowSDELMAkGA1UEBhMCVVMxIDAe -BgNVBAoTF1NlY3VyZVRydXN0IENvcnBvcmF0aW9uMRcwFQYDVQQDEw5TZWN1cmVUcnVzdCBDQTCC -ASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAKukgeWVzfX2FI7CT8rU4niVWJxB4Q2ZQCQX -OZEzZum+4YOvYlyJ0fwkW2Gz4BERQRwdbvC4u/jep4G6pkjGnx29vo6pQT64lO0pGtSO0gMdA+9t -DWccV9cGrcrI9f4Or2YlSASWC12juhbDCE/RRvgUXPLIXgGZbf2IzIaowW8xQmxSPmjL8xk037uH -GFaAJsTQ3MBv396gwpEWoGQRS0S8Hvbn+mPeZqx2pHGj7DaUaHp3pLHnDi+BeuK1cobvomuL8A/b -01k/unK8RCSc43Oz969XL0Imnal0ugBS8kvNU3xHCzaFDmapCJcWNFfBZveA4+1wVMeT4C4oFVmH -ursCAwEAAaOBnTCBmjATBgkrBgEEAYI3FAIEBh4EAEMAQTALBgNVHQ8EBAMCAYYwDwYDVR0TAQH/ -BAUwAwEB/zAdBgNVHQ4EFgQUQjK2FvoE/f5dS3rD/fdMQB1aQ68wNAYDVR0fBC0wKzApoCegJYYj -aHR0cDovL2NybC5zZWN1cmV0cnVzdC5jb20vU1RDQS5jcmwwEAYJKwYBBAGCNxUBBAMCAQAwDQYJ -KoZIhvcNAQEFBQADggEBADDtT0rhWDpSclu1pqNlGKa7UTt36Z3q059c4EVlew3KW+JwULKUBRSu -SceNQQcSc5R+DCMh/bwQf2AQWnL1mA6s7Ll/3XpvXdMc9P+IBWlCqQVxyLesJugutIxq/3HcuLHf -mbx8IVQr5Fiiu1cprp6poxkmD5kuCLDv/WnPmRoJjeOnnyvJNjR7JLN4TJUXpAYmHrZkUjZfYGfZ -nMUFdAvnZyPSCPyI6a6Lf+Ew9Dd+/cYy2i2eRDAwbO4H3tI0/NL/QPZL9GZGBlSm8jIKYyYwa5vR -3ItHuuG51WLQoqD0ZwV4KWMabwTW+MZMo5qxN7SN5ShLHZ4swrhovO0C7jE= ------END CERTIFICATE----- - -Secure Global CA -================ ------BEGIN CERTIFICATE----- -MIIDvDCCAqSgAwIBAgIQB1YipOjUiolN9BPI8PjqpTANBgkqhkiG9w0BAQUFADBKMQswCQYDVQQG -EwJVUzEgMB4GA1UEChMXU2VjdXJlVHJ1c3QgQ29ycG9yYXRpb24xGTAXBgNVBAMTEFNlY3VyZSBH -bG9iYWwgQ0EwHhcNMDYxMTA3MTk0MjI4WhcNMjkxMjMxMTk1MjA2WjBKMQswCQYDVQQGEwJVUzEg -MB4GA1UEChMXU2VjdXJlVHJ1c3QgQ29ycG9yYXRpb24xGTAXBgNVBAMTEFNlY3VyZSBHbG9iYWwg -Q0EwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCvNS7YrGxVaQZx5RNoJLNP2MwhR/jx -YDiJiQPpvepeRlMJ3Fz1Wuj3RSoC6zFh1ykzTM7HfAo3fg+6MpjhHZevj8fcyTiW89sa/FHtaMbQ -bqR8JNGuQsiWUGMu4P51/pinX0kuleM5M2SOHqRfkNJnPLLZ/kG5VacJjnIFHovdRIWCQtBJwB1g -8NEXLJXr9qXBkqPFwqcIYA1gBBCWeZ4WNOaptvolRTnIHmX5k/Wq8VLcmZg9pYYaDDUz+kulBAYV -HDGA76oYa8J719rO+TMg1fW9ajMtgQT7sFzUnKPiXB3jqUJ1XnvUd+85VLrJChgbEplJL4hL/VBi -0XPnj3pDAgMBAAGjgZ0wgZowEwYJKwYBBAGCNxQCBAYeBABDAEEwCwYDVR0PBAQDAgGGMA8GA1Ud -EwEB/wQFMAMBAf8wHQYDVR0OBBYEFK9EBMJBfkiD2045AuzshHrmzsmkMDQGA1UdHwQtMCswKaAn -oCWGI2h0dHA6Ly9jcmwuc2VjdXJldHJ1c3QuY29tL1NHQ0EuY3JsMBAGCSsGAQQBgjcVAQQDAgEA -MA0GCSqGSIb3DQEBBQUAA4IBAQBjGghAfaReUw132HquHw0LURYD7xh8yOOvaliTFGCRsoTciE6+ -OYo68+aCiV0BN7OrJKQVDpI1WkpEXk5X+nXOH0jOZvQ8QCaSmGwb7iRGDBezUqXbpZGRzzfTb+cn -CDpOGR86p1hcF895P4vkp9MmI50mD1hp/Ed+stCNi5O/KU9DaXR2Z0vPB4zmAve14bRDtUstFJ/5 -3CYNv6ZHdAbYiNE6KTCEztI5gGIbqMdXSbxqVVFnFUq+NQfk1XWYN3kwFNspnWzFacxHVaIw98xc -f8LDmBxrThaA63p4ZUWiABqvDA1VZDRIuJK58bRQKfJPIx/abKwfROHdI3hRW8cW ------END CERTIFICATE----- - -COMODO Certification Authority -============================== ------BEGIN CERTIFICATE----- -MIIEHTCCAwWgAwIBAgIQToEtioJl4AsC7j41AkblPTANBgkqhkiG9w0BAQUFADCBgTELMAkGA1UE -BhMCR0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgG -A1UEChMRQ09NT0RPIENBIExpbWl0ZWQxJzAlBgNVBAMTHkNPTU9ETyBDZXJ0aWZpY2F0aW9uIEF1 -dGhvcml0eTAeFw0wNjEyMDEwMDAwMDBaFw0yOTEyMzEyMzU5NTlaMIGBMQswCQYDVQQGEwJHQjEb -MBkGA1UECBMSR3JlYXRlciBNYW5jaGVzdGVyMRAwDgYDVQQHEwdTYWxmb3JkMRowGAYDVQQKExFD -T01PRE8gQ0EgTGltaXRlZDEnMCUGA1UEAxMeQ09NT0RPIENlcnRpZmljYXRpb24gQXV0aG9yaXR5 -MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA0ECLi3LjkRv3UcEbVASY06m/weaKXTuH -+7uIzg3jLz8GlvCiKVCZrts7oVewdFFxze1CkU1B/qnI2GqGd0S7WWaXUF601CxwRM/aN5VCaTww -xHGzUvAhTaHYujl8HJ6jJJ3ygxaYqhZ8Q5sVW7euNJH+1GImGEaaP+vB+fGQV+useg2L23IwambV -4EajcNxo2f8ESIl33rXp+2dtQem8Ob0y2WIC8bGoPW43nOIv4tOiJovGuFVDiOEjPqXSJDlqR6sA -1KGzqSX+DT+nHbrTUcELpNqsOO9VUCQFZUaTNE8tja3G1CEZ0o7KBWFxB3NH5YoZEr0ETc5OnKVI -rLsm9wIDAQABo4GOMIGLMB0GA1UdDgQWBBQLWOWLxkwVN6RAqTCpIb5HNlpW/zAOBgNVHQ8BAf8E -BAMCAQYwDwYDVR0TAQH/BAUwAwEB/zBJBgNVHR8EQjBAMD6gPKA6hjhodHRwOi8vY3JsLmNvbW9k -b2NhLmNvbS9DT01PRE9DZXJ0aWZpY2F0aW9uQXV0aG9yaXR5LmNybDANBgkqhkiG9w0BAQUFAAOC -AQEAPpiem/Yb6dc5t3iuHXIYSdOH5EOC6z/JqvWote9VfCFSZfnVDeFs9D6Mk3ORLgLETgdxb8CP -OGEIqB6BCsAvIC9Bi5HcSEW88cbeunZrM8gALTFGTO3nnc+IlP8zwFboJIYmuNg4ON8qa90SzMc/ -RxdMosIGlgnW2/4/PEZB31jiVg88O8EckzXZOFKs7sjsLjBOlDW0JB9LeGna8gI4zJVSk/BwJVmc -IGfE7vmLV2H0knZ9P4SNVbfo5azV8fUZVqZa+5Acr5Pr5RzUZ5ddBA6+C4OmF4O5MBKgxTMVBbkN -+8cFduPYSo38NBejxiEovjBFMR7HeL5YYTisO+IBZQ== ------END CERTIFICATE----- - -Network Solutions Certificate Authority -======================================= ------BEGIN CERTIFICATE----- -MIID5jCCAs6gAwIBAgIQV8szb8JcFuZHFhfjkDFo4DANBgkqhkiG9w0BAQUFADBiMQswCQYDVQQG -EwJVUzEhMB8GA1UEChMYTmV0d29yayBTb2x1dGlvbnMgTC5MLkMuMTAwLgYDVQQDEydOZXR3b3Jr -IFNvbHV0aW9ucyBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkwHhcNMDYxMjAxMDAwMDAwWhcNMjkxMjMx -MjM1OTU5WjBiMQswCQYDVQQGEwJVUzEhMB8GA1UEChMYTmV0d29yayBTb2x1dGlvbnMgTC5MLkMu -MTAwLgYDVQQDEydOZXR3b3JrIFNvbHV0aW9ucyBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkwggEiMA0G -CSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDkvH6SMG3G2I4rC7xGzuAnlt7e+foS0zwzc7MEL7xx -jOWftiJgPl9dzgn/ggwbmlFQGiaJ3dVhXRncEg8tCqJDXRfQNJIg6nPPOCwGJgl6cvf6UDL4wpPT -aaIjzkGxzOTVHzbRijr4jGPiFFlp7Q3Tf2vouAPlT2rlmGNpSAW+Lv8ztumXWWn4Zxmuk2GWRBXT -crA/vGp97Eh/jcOrqnErU2lBUzS1sLnFBgrEsEX1QV1uiUV7PTsmjHTC5dLRfbIR1PtYMiKagMnc -/Qzpf14Dl847ABSHJ3A4qY5usyd2mFHgBeMhqxrVhSI8KbWaFsWAqPS7azCPL0YCorEMIuDTAgMB -AAGjgZcwgZQwHQYDVR0OBBYEFCEwyfsA106Y2oeqKtCnLrFAMadMMA4GA1UdDwEB/wQEAwIBBjAP -BgNVHRMBAf8EBTADAQH/MFIGA1UdHwRLMEkwR6BFoEOGQWh0dHA6Ly9jcmwubmV0c29sc3NsLmNv -bS9OZXR3b3JrU29sdXRpb25zQ2VydGlmaWNhdGVBdXRob3JpdHkuY3JsMA0GCSqGSIb3DQEBBQUA -A4IBAQC7rkvnt1frf6ott3NHhWrB5KUd5Oc86fRZZXe1eltajSU24HqXLjjAV2CDmAaDn7l2em5Q -4LqILPxFzBiwmZVRDuwduIj/h1AcgsLj4DKAv6ALR8jDMe+ZZzKATxcheQxpXN5eNK4CtSbqUN9/ -GGUsyfJj4akH/nxxH2szJGoeBfcFaMBqEssuXmHLrijTfsK0ZpEmXzwuJF/LWA/rKOyvEZbz3Htv -wKeI8lN3s2Berq4o2jUsbzRF0ybh3uxbTydrFny9RAQYgrOJeRcQcT16ohZO9QHNpGxlaKFJdlxD -ydi8NmdspZS11My5vWo1ViHe2MPr+8ukYEywVaCge1ey ------END CERTIFICATE----- - -COMODO ECC Certification Authority -================================== ------BEGIN CERTIFICATE----- -MIICiTCCAg+gAwIBAgIQH0evqmIAcFBUTAGem2OZKjAKBggqhkjOPQQDAzCBhTELMAkGA1UEBhMC -R0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgGA1UE -ChMRQ09NT0RPIENBIExpbWl0ZWQxKzApBgNVBAMTIkNPTU9ETyBFQ0MgQ2VydGlmaWNhdGlvbiBB -dXRob3JpdHkwHhcNMDgwMzA2MDAwMDAwWhcNMzgwMTE4MjM1OTU5WjCBhTELMAkGA1UEBhMCR0Ix -GzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgGA1UEChMR -Q09NT0RPIENBIExpbWl0ZWQxKzApBgNVBAMTIkNPTU9ETyBFQ0MgQ2VydGlmaWNhdGlvbiBBdXRo -b3JpdHkwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAAQDR3svdcmCFYX7deSRFtSrYpn1PlILBs5BAH+X -4QokPB0BBO490o0JlwzgdeT6+3eKKvUDYEs2ixYjFq0JcfRK9ChQtP6IHG4/bC8vCVlbpVsLM5ni -wz2J+Wos77LTBumjQjBAMB0GA1UdDgQWBBR1cacZSBm8nZ3qQUfflMRId5nTeTAOBgNVHQ8BAf8E -BAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAKBggqhkjOPQQDAwNoADBlAjEA7wNbeqy3eApyt4jf/7VG -FAkK+qDmfQjGGoe9GKhzvSbKYAydzpmfz1wPMOG+FDHqAjAU9JM8SaczepBGR7NjfRObTrdvGDeA -U/7dIOA1mjbRxwG55tzd8/8dLDoWV9mSOdY= ------END CERTIFICATE----- - -OISTE WISeKey Global Root GA CA -=============================== ------BEGIN CERTIFICATE----- -MIID8TCCAtmgAwIBAgIQQT1yx/RrH4FDffHSKFTfmjANBgkqhkiG9w0BAQUFADCBijELMAkGA1UE -BhMCQ0gxEDAOBgNVBAoTB1dJU2VLZXkxGzAZBgNVBAsTEkNvcHlyaWdodCAoYykgMjAwNTEiMCAG -A1UECxMZT0lTVEUgRm91bmRhdGlvbiBFbmRvcnNlZDEoMCYGA1UEAxMfT0lTVEUgV0lTZUtleSBH -bG9iYWwgUm9vdCBHQSBDQTAeFw0wNTEyMTExNjAzNDRaFw0zNzEyMTExNjA5NTFaMIGKMQswCQYD -VQQGEwJDSDEQMA4GA1UEChMHV0lTZUtleTEbMBkGA1UECxMSQ29weXJpZ2h0IChjKSAyMDA1MSIw -IAYDVQQLExlPSVNURSBGb3VuZGF0aW9uIEVuZG9yc2VkMSgwJgYDVQQDEx9PSVNURSBXSVNlS2V5 -IEdsb2JhbCBSb290IEdBIENBMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAy0+zAJs9 -Nt350UlqaxBJH+zYK7LG+DKBKUOVTJoZIyEVRd7jyBxRVVuuk+g3/ytr6dTqvirdqFEr12bDYVxg -Asj1znJ7O7jyTmUIms2kahnBAbtzptf2w93NvKSLtZlhuAGio9RN1AU9ka34tAhxZK9w8RxrfvbD -d50kc3vkDIzh2TbhmYsFmQvtRTEJysIA2/dyoJaqlYfQjse2YXMNdmaM3Bu0Y6Kff5MTMPGhJ9vZ -/yxViJGg4E8HsChWjBgbl0SOid3gF27nKu+POQoxhILYQBRJLnpB5Kf+42TMwVlxSywhp1t94B3R -LoGbw9ho972WG6xwsRYUC9tguSYBBQIDAQABo1EwTzALBgNVHQ8EBAMCAYYwDwYDVR0TAQH/BAUw -AwEB/zAdBgNVHQ4EFgQUswN+rja8sHnR3JQmthG+IbJphpQwEAYJKwYBBAGCNxUBBAMCAQAwDQYJ -KoZIhvcNAQEFBQADggEBAEuh/wuHbrP5wUOxSPMowB0uyQlB+pQAHKSkq0lPjz0e701vvbyk9vIm -MMkQyh2I+3QZH4VFvbBsUfk2ftv1TDI6QU9bR8/oCy22xBmddMVHxjtqD6wU2zz0c5ypBd8A3HR4 -+vg1YFkCExh8vPtNsCBtQ7tgMHpnM1zFmdH4LTlSc/uMqpclXHLZCB6rTjzjgTGfA6b7wP4piFXa -hNVQA7bihKOmNqoROgHhGEvWRGizPflTdISzRpFGlgC3gCy24eMQ4tui5yiPAZZiFj4A4xylNoEY -okxSdsARo27mHbrjWr42U8U+dY+GaSlYU7Wcu2+fXMUY7N0v4ZjJ/L7fCg0= ------END CERTIFICATE----- - -Certigna -======== ------BEGIN CERTIFICATE----- -MIIDqDCCApCgAwIBAgIJAP7c4wEPyUj/MA0GCSqGSIb3DQEBBQUAMDQxCzAJBgNVBAYTAkZSMRIw -EAYDVQQKDAlEaGlteW90aXMxETAPBgNVBAMMCENlcnRpZ25hMB4XDTA3MDYyOTE1MTMwNVoXDTI3 -MDYyOTE1MTMwNVowNDELMAkGA1UEBhMCRlIxEjAQBgNVBAoMCURoaW15b3RpczERMA8GA1UEAwwI -Q2VydGlnbmEwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDIaPHJ1tazNHUmgh7stL7q -XOEm7RFHYeGifBZ4QCHkYJ5ayGPhxLGWkv8YbWkj4Sti993iNi+RB7lIzw7sebYs5zRLcAglozyH -GxnygQcPOJAZ0xH+hrTy0V4eHpbNgGzOOzGTtvKg0KmVEn2lmsxryIRWijOp5yIVUxbwzBfsV1/p -ogqYCd7jX5xv3EjjhQsVWqa6n6xI4wmy9/Qy3l40vhx4XUJbzg4ij02Q130yGLMLLGq/jj8UEYkg -DncUtT2UCIf3JR7VsmAA7G8qKCVuKj4YYxclPz5EIBb2JsglrgVKtOdjLPOMFlN+XPsRGgjBRmKf -Irjxwo1p3Po6WAbfAgMBAAGjgbwwgbkwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUGu3+QTmQ -tCRZvgHyUtVF9lo53BEwZAYDVR0jBF0wW4AUGu3+QTmQtCRZvgHyUtVF9lo53BGhOKQ2MDQxCzAJ -BgNVBAYTAkZSMRIwEAYDVQQKDAlEaGlteW90aXMxETAPBgNVBAMMCENlcnRpZ25hggkA/tzjAQ/J -SP8wDgYDVR0PAQH/BAQDAgEGMBEGCWCGSAGG+EIBAQQEAwIABzANBgkqhkiG9w0BAQUFAAOCAQEA -hQMeknH2Qq/ho2Ge6/PAD/Kl1NqV5ta+aDY9fm4fTIrv0Q8hbV6lUmPOEvjvKtpv6zf+EwLHyzs+ -ImvaYS5/1HI93TDhHkxAGYwP15zRgzB7mFncfca5DClMoTOi62c6ZYTTluLtdkVwj7Ur3vkj1klu -PBS1xp81HlDQwY9qcEQCYsuuHWhBp6pX6FOqB9IG9tUUBguRA3UsbHK1YZWaDYu5Def131TN3ubY -1gkIl2PlwS6wt0QmwCbAr1UwnjvVNioZBPRcHv/PLLf/0P2HQBHVESO7SMAhqaQoLf0V+LBOK/Qw -WyH8EZE0vkHve52Xdf+XlcCWWC/qu0bXu+TZLg== ------END CERTIFICATE----- - -Cybertrust Global Root -====================== ------BEGIN CERTIFICATE----- -MIIDoTCCAomgAwIBAgILBAAAAAABD4WqLUgwDQYJKoZIhvcNAQEFBQAwOzEYMBYGA1UEChMPQ3li -ZXJ0cnVzdCwgSW5jMR8wHQYDVQQDExZDeWJlcnRydXN0IEdsb2JhbCBSb290MB4XDTA2MTIxNTA4 -MDAwMFoXDTIxMTIxNTA4MDAwMFowOzEYMBYGA1UEChMPQ3liZXJ0cnVzdCwgSW5jMR8wHQYDVQQD -ExZDeWJlcnRydXN0IEdsb2JhbCBSb290MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA -+Mi8vRRQZhP/8NN57CPytxrHjoXxEnOmGaoQ25yiZXRadz5RfVb23CO21O1fWLE3TdVJDm71aofW -0ozSJ8bi/zafmGWgE07GKmSb1ZASzxQG9Dvj1Ci+6A74q05IlG2OlTEQXO2iLb3VOm2yHLtgwEZL -AfVJrn5GitB0jaEMAs7u/OePuGtm839EAL9mJRQr3RAwHQeWP032a7iPt3sMpTjr3kfb1V05/Iin -89cqdPHoWqI7n1C6poxFNcJQZZXcY4Lv3b93TZxiyWNzFtApD0mpSPCzqrdsxacwOUBdrsTiXSZT -8M4cIwhhqJQZugRiQOwfOHB3EgZxpzAYXSUnpQIDAQABo4GlMIGiMA4GA1UdDwEB/wQEAwIBBjAP -BgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBS2CHsNesysIEyGVjJez6tuhS1wVzA/BgNVHR8EODA2 -MDSgMqAwhi5odHRwOi8vd3d3Mi5wdWJsaWMtdHJ1c3QuY29tL2NybC9jdC9jdHJvb3QuY3JsMB8G -A1UdIwQYMBaAFLYIew16zKwgTIZWMl7Pq26FLXBXMA0GCSqGSIb3DQEBBQUAA4IBAQBW7wojoFRO -lZfJ+InaRcHUowAl9B8Tq7ejhVhpwjCt2BWKLePJzYFa+HMjWqd8BfP9IjsO0QbE2zZMcwSO5bAi -5MXzLqXZI+O4Tkogp24CJJ8iYGd7ix1yCcUxXOl5n4BHPa2hCwcUPUf/A2kaDAtE52Mlp3+yybh2 -hO0j9n0Hq0V+09+zv+mKts2oomcrUtW3ZfA5TGOgkXmTUg9U3YO7n9GPp1Nzw8v/MOx8BLjYRB+T -X3EJIrduPuocA06dGiBh+4E37F78CkWr1+cXVdCg6mCbpvbjjFspwgZgFJ0tl0ypkxWdYcQBX0jW -WL1WMRJOEcgh4LMRkWXbtKaIOM5V ------END CERTIFICATE----- - -ePKI Root Certification Authority -================================= ------BEGIN CERTIFICATE----- -MIIFsDCCA5igAwIBAgIQFci9ZUdcr7iXAF7kBtK8nTANBgkqhkiG9w0BAQUFADBeMQswCQYDVQQG -EwJUVzEjMCEGA1UECgwaQ2h1bmdod2EgVGVsZWNvbSBDby4sIEx0ZC4xKjAoBgNVBAsMIWVQS0kg -Um9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw0wNDEyMjAwMjMxMjdaFw0zNDEyMjAwMjMx -MjdaMF4xCzAJBgNVBAYTAlRXMSMwIQYDVQQKDBpDaHVuZ2h3YSBUZWxlY29tIENvLiwgTHRkLjEq -MCgGA1UECwwhZVBLSSBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MIICIjANBgkqhkiG9w0B -AQEFAAOCAg8AMIICCgKCAgEA4SUP7o3biDN1Z82tH306Tm2d0y8U82N0ywEhajfqhFAHSyZbCUNs -IZ5qyNUD9WBpj8zwIuQf5/dqIjG3LBXy4P4AakP/h2XGtRrBp0xtInAhijHyl3SJCRImHJ7K2RKi -lTza6We/CKBk49ZCt0Xvl/T29de1ShUCWH2YWEtgvM3XDZoTM1PRYfl61dd4s5oz9wCGzh1NlDiv -qOx4UXCKXBCDUSH3ET00hl7lSM2XgYI1TBnsZfZrxQWh7kcT1rMhJ5QQCtkkO7q+RBNGMD+XPNjX -12ruOzjjK9SXDrkb5wdJfzcq+Xd4z1TtW0ado4AOkUPB1ltfFLqfpo0kR0BZv3I4sjZsN/+Z0V0O -WQqraffAsgRFelQArr5T9rXn4fg8ozHSqf4hUmTFpmfwdQcGlBSBVcYn5AGPF8Fqcde+S/uUWH1+ -ETOxQvdibBjWzwloPn9s9h6PYq2lY9sJpx8iQkEeb5mKPtf5P0B6ebClAZLSnT0IFaUQAS2zMnao -lQ2zepr7BxB4EW/hj8e6DyUadCrlHJhBmd8hh+iVBmoKs2pHdmX2Os+PYhcZewoozRrSgx4hxyy/ -vv9haLdnG7t4TY3OZ+XkwY63I2binZB1NJipNiuKmpS5nezMirH4JYlcWrYvjB9teSSnUmjDhDXi -Zo1jDiVN1Rmy5nk3pyKdVDECAwEAAaNqMGgwHQYDVR0OBBYEFB4M97Zn8uGSJglFwFU5Lnc/Qkqi -MAwGA1UdEwQFMAMBAf8wOQYEZyoHAAQxMC8wLQIBADAJBgUrDgMCGgUAMAcGBWcqAwAABBRFsMLH -ClZ87lt4DJX5GFPBphzYEDANBgkqhkiG9w0BAQUFAAOCAgEACbODU1kBPpVJufGBuvl2ICO1J2B0 -1GqZNF5sAFPZn/KmsSQHRGoqxqWOeBLoR9lYGxMqXnmbnwoqZ6YlPwZpVnPDimZI+ymBV3QGypzq -KOg4ZyYr8dW1P2WT+DZdjo2NQCCHGervJ8A9tDkPJXtoUHRVnAxZfVo9QZQlUgjgRywVMRnVvwdV -xrsStZf0X4OFunHB2WyBEXYKCrC/gpf36j36+uwtqSiUO1bd0lEursC9CBWMd1I0ltabrNMdjmEP -NXubrjlpC2JgQCA2j6/7Nu4tCEoduL+bXPjqpRugc6bY+G7gMwRfaKonh+3ZwZCc7b3jajWvY9+r -GNm65ulK6lCKD2GTHuItGeIwlDWSXQ62B68ZgI9HkFFLLk3dheLSClIKF5r8GrBQAuUBo2M3IUxE -xJtRmREOc5wGj1QupyheRDmHVi03vYVElOEMSyycw5KFNGHLD7ibSkNS/jQ6fbjpKdx2qcgw+BRx -gMYeNkh0IkFch4LoGHGLQYlE535YW6i4jRPpp2zDR+2zGp1iro2C6pSe3VkQw63d4k3jMdXH7Ojy -sP6SHhYKGvzZ8/gntsm+HbRsZJB/9OTEW9c3rkIO3aQab3yIVMUWbuF6aC74Or8NpDyJO3inTmOD -BCEIZ43ygknQW/2xzQ+DhNQ+IIX3Sj0rnP0qCglN6oH4EZw= ------END CERTIFICATE----- - -certSIGN ROOT CA -================ ------BEGIN CERTIFICATE----- -MIIDODCCAiCgAwIBAgIGIAYFFnACMA0GCSqGSIb3DQEBBQUAMDsxCzAJBgNVBAYTAlJPMREwDwYD -VQQKEwhjZXJ0U0lHTjEZMBcGA1UECxMQY2VydFNJR04gUk9PVCBDQTAeFw0wNjA3MDQxNzIwMDRa -Fw0zMTA3MDQxNzIwMDRaMDsxCzAJBgNVBAYTAlJPMREwDwYDVQQKEwhjZXJ0U0lHTjEZMBcGA1UE -CxMQY2VydFNJR04gUk9PVCBDQTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBALczuX7I -JUqOtdu0KBuqV5Do0SLTZLrTk+jUrIZhQGpgV2hUhE28alQCBf/fm5oqrl0Hj0rDKH/v+yv6efHH -rfAQUySQi2bJqIirr1qjAOm+ukbuW3N7LBeCgV5iLKECZbO9xSsAfsT8AzNXDe3i+s5dRdY4zTW2 -ssHQnIFKquSyAVwdj1+ZxLGt24gh65AIgoDzMKND5pCCrlUoSe1b16kQOA7+j0xbm0bqQfWwCHTD -0IgztnzXdN/chNFDDnU5oSVAKOp4yw4sLjmdjItuFhwvJoIQ4uNllAoEwF73XVv4EOLQunpL+943 -AAAaWyjj0pxzPjKHmKHJUS/X3qwzs08CAwEAAaNCMEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8B -Af8EBAMCAcYwHQYDVR0OBBYEFOCMm9slSbPxfIbWskKHC9BroNnkMA0GCSqGSIb3DQEBBQUAA4IB -AQA+0hyJLjX8+HXd5n9liPRyTMks1zJO890ZeUe9jjtbkw9QSSQTaxQGcu8J06Gh40CEyecYMnQ8 -SG4Pn0vU9x7Tk4ZkVJdjclDVVc/6IJMCopvDI5NOFlV2oHB5bc0hH88vLbwZ44gx+FkagQnIl6Z0 -x2DEW8xXjrJ1/RsCCdtZb3KTafcxQdaIOL+Hsr0Wefmq5L6IJd1hJyMctTEHBDa0GpC9oHRxUIlt -vBTjD4au8as+x6AJzKNI0eDbZOeStc+vckNwi/nDhDwTqn6Sm1dTk/pwwpEOMfmbZ13pljheX7Nz -TogVZ96edhBiIL5VaZVDADlN9u6wWk5JRFRYX0KD ------END CERTIFICATE----- - -GeoTrust Primary Certification Authority - G3 -============================================= ------BEGIN CERTIFICATE----- -MIID/jCCAuagAwIBAgIQFaxulBmyeUtB9iepwxgPHzANBgkqhkiG9w0BAQsFADCBmDELMAkGA1UE -BhMCVVMxFjAUBgNVBAoTDUdlb1RydXN0IEluYy4xOTA3BgNVBAsTMChjKSAyMDA4IEdlb1RydXN0 -IEluYy4gLSBGb3IgYXV0aG9yaXplZCB1c2Ugb25seTE2MDQGA1UEAxMtR2VvVHJ1c3QgUHJpbWFy -eSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSAtIEczMB4XDTA4MDQwMjAwMDAwMFoXDTM3MTIwMTIz -NTk1OVowgZgxCzAJBgNVBAYTAlVTMRYwFAYDVQQKEw1HZW9UcnVzdCBJbmMuMTkwNwYDVQQLEzAo -YykgMjAwOCBHZW9UcnVzdCBJbmMuIC0gRm9yIGF1dGhvcml6ZWQgdXNlIG9ubHkxNjA0BgNVBAMT -LUdlb1RydXN0IFByaW1hcnkgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgLSBHMzCCASIwDQYJKoZI -hvcNAQEBBQADggEPADCCAQoCggEBANziXmJYHTNXOTIz+uvLh4yn1ErdBojqZI4xmKU4kB6Yzy5j -K/BGvESyiaHAKAxJcCGVn2TAppMSAmUmhsalifD614SgcK9PGpc/BkTVyetyEH3kMSj7HGHmKAdE -c5IiaacDiGydY8hS2pgn5whMcD60yRLBxWeDXTPzAxHsatBT4tG6NmCUgLthY2xbF37fQJQeqw3C -IShwiP/WJmxsYAQlTlV+fe+/lEjetx3dcI0FX4ilm/LC7urRQEFtYjgdVgbFA0dRIBn8exALDmKu -dlW/X3e+PkkBUz2YJQN2JFodtNuJ6nnltrM7P7pMKEF/BqxqjsHQ9gUdfeZChuOl1UcCAwEAAaNC -MEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFMR5yo6hTgMdHNxr -2zFblD4/MH8tMA0GCSqGSIb3DQEBCwUAA4IBAQAtxRPPVoB7eni9n64smefv2t+UXglpp+duaIy9 -cr5HqQ6XErhK8WTTOd8lNNTBzU6B8A8ExCSzNJbGpqow32hhc9f5joWJ7w5elShKKiePEI4ufIbE -Ap7aDHdlDkQNkv39sxY2+hENHYwOB4lqKVb3cvTdFZx3NWZXqxNT2I7BQMXXExZacse3aQHEerGD -AWh9jUGhlBjBJVz88P6DAod8DQ3PLghcSkANPuyBYeYk28rgDi0Hsj5W3I31QYUHSJsMC8tJP33s -t/3LjWeJGqvtux6jAAgIFyqCXDFdRootD4abdNlF+9RAsXqqaC2Gspki4cErx5z481+oghLrGREt ------END CERTIFICATE----- - -thawte Primary Root CA - G2 -=========================== ------BEGIN CERTIFICATE----- -MIICiDCCAg2gAwIBAgIQNfwmXNmET8k9Jj1Xm67XVjAKBggqhkjOPQQDAzCBhDELMAkGA1UEBhMC -VVMxFTATBgNVBAoTDHRoYXd0ZSwgSW5jLjE4MDYGA1UECxMvKGMpIDIwMDcgdGhhd3RlLCBJbmMu -IC0gRm9yIGF1dGhvcml6ZWQgdXNlIG9ubHkxJDAiBgNVBAMTG3RoYXd0ZSBQcmltYXJ5IFJvb3Qg -Q0EgLSBHMjAeFw0wNzExMDUwMDAwMDBaFw0zODAxMTgyMzU5NTlaMIGEMQswCQYDVQQGEwJVUzEV -MBMGA1UEChMMdGhhd3RlLCBJbmMuMTgwNgYDVQQLEy8oYykgMjAwNyB0aGF3dGUsIEluYy4gLSBG -b3IgYXV0aG9yaXplZCB1c2Ugb25seTEkMCIGA1UEAxMbdGhhd3RlIFByaW1hcnkgUm9vdCBDQSAt -IEcyMHYwEAYHKoZIzj0CAQYFK4EEACIDYgAEotWcgnuVnfFSeIf+iha/BebfowJPDQfGAFG6DAJS -LSKkQjnE/o/qycG+1E3/n3qe4rF8mq2nhglzh9HnmuN6papu+7qzcMBniKI11KOasf2twu8x+qi5 -8/sIxpHR+ymVo0IwQDAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQU -mtgAMADna3+FGO6Lts6KDPgR4bswCgYIKoZIzj0EAwMDaQAwZgIxAN344FdHW6fmCsO99YCKlzUN -G4k8VIZ3KMqh9HneteY4sPBlcIx/AlTCv//YoT7ZzwIxAMSNlPzcU9LcnXgWHxUzI1NS41oxXZ3K -rr0TKUQNJ1uo52icEvdYPy5yAlejj6EULg== ------END CERTIFICATE----- - -thawte Primary Root CA - G3 -=========================== ------BEGIN CERTIFICATE----- -MIIEKjCCAxKgAwIBAgIQYAGXt0an6rS0mtZLL/eQ+zANBgkqhkiG9w0BAQsFADCBrjELMAkGA1UE -BhMCVVMxFTATBgNVBAoTDHRoYXd0ZSwgSW5jLjEoMCYGA1UECxMfQ2VydGlmaWNhdGlvbiBTZXJ2 -aWNlcyBEaXZpc2lvbjE4MDYGA1UECxMvKGMpIDIwMDggdGhhd3RlLCBJbmMuIC0gRm9yIGF1dGhv -cml6ZWQgdXNlIG9ubHkxJDAiBgNVBAMTG3RoYXd0ZSBQcmltYXJ5IFJvb3QgQ0EgLSBHMzAeFw0w -ODA0MDIwMDAwMDBaFw0zNzEyMDEyMzU5NTlaMIGuMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMdGhh -d3RlLCBJbmMuMSgwJgYDVQQLEx9DZXJ0aWZpY2F0aW9uIFNlcnZpY2VzIERpdmlzaW9uMTgwNgYD -VQQLEy8oYykgMjAwOCB0aGF3dGUsIEluYy4gLSBGb3IgYXV0aG9yaXplZCB1c2Ugb25seTEkMCIG -A1UEAxMbdGhhd3RlIFByaW1hcnkgUm9vdCBDQSAtIEczMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8A -MIIBCgKCAQEAsr8nLPvb2FvdeHsbnndmgcs+vHyu86YnmjSjaDFxODNi5PNxZnmxqWWjpYvVj2At -P0LMqmsywCPLLEHd5N/8YZzic7IilRFDGF/Eth9XbAoFWCLINkw6fKXRz4aviKdEAhN0cXMKQlkC -+BsUa0Lfb1+6a4KinVvnSr0eAXLbS3ToO39/fR8EtCab4LRarEc9VbjXsCZSKAExQGbY2SS99irY -7CFJXJv2eul/VTV+lmuNk5Mny5K76qxAwJ/C+IDPXfRa3M50hqY+bAtTyr2SzhkGcuYMXDhpxwTW -vGzOW/b3aJzcJRVIiKHpqfiYnODz1TEoYRFsZ5aNOZnLwkUkOQIDAQABo0IwQDAPBgNVHRMBAf8E -BTADAQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUrWyqlGCc7eT/+j4KdCtjA/e2Wb8wDQYJ -KoZIhvcNAQELBQADggEBABpA2JVlrAmSicY59BDlqQ5mU1143vokkbvnRFHfxhY0Cu9qRFHqKweK -A3rD6z8KLFIWoCtDuSWQP3CpMyVtRRooOyfPqsMpQhvfO0zAMzRbQYi/aytlryjvsvXDqmbOe1bu -t8jLZ8HJnBoYuMTDSQPxYA5QzUbF83d597YV4Djbxy8ooAw/dyZ02SUS2jHaGh7cKUGRIjxpp7sC -8rZcJwOJ9Abqm+RyguOhCcHpABnTPtRwa7pxpqpYrvS76Wy274fMm7v/OeZWYdMKp8RcTGB7BXcm -er/YB1IsYvdwY9k5vG8cwnncdimvzsUsZAReiDZuMdRAGmI0Nj81Aa6sY6A= ------END CERTIFICATE----- - -GeoTrust Primary Certification Authority - G2 -============================================= ------BEGIN CERTIFICATE----- -MIICrjCCAjWgAwIBAgIQPLL0SAoA4v7rJDteYD7DazAKBggqhkjOPQQDAzCBmDELMAkGA1UEBhMC -VVMxFjAUBgNVBAoTDUdlb1RydXN0IEluYy4xOTA3BgNVBAsTMChjKSAyMDA3IEdlb1RydXN0IElu -Yy4gLSBGb3IgYXV0aG9yaXplZCB1c2Ugb25seTE2MDQGA1UEAxMtR2VvVHJ1c3QgUHJpbWFyeSBD -ZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSAtIEcyMB4XDTA3MTEwNTAwMDAwMFoXDTM4MDExODIzNTk1 -OVowgZgxCzAJBgNVBAYTAlVTMRYwFAYDVQQKEw1HZW9UcnVzdCBJbmMuMTkwNwYDVQQLEzAoYykg -MjAwNyBHZW9UcnVzdCBJbmMuIC0gRm9yIGF1dGhvcml6ZWQgdXNlIG9ubHkxNjA0BgNVBAMTLUdl -b1RydXN0IFByaW1hcnkgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgLSBHMjB2MBAGByqGSM49AgEG -BSuBBAAiA2IABBWx6P0DFUPlrOuHNxFi79KDNlJ9RVcLSo17VDs6bl8VAsBQps8lL33KSLjHUGMc -KiEIfJo22Av+0SbFWDEwKCXzXV2juLaltJLtbCyf691DiaI8S0iRHVDsJt/WYC69IaNCMEAwDwYD -VR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFBVfNVdRVfslsq0DafwBo/q+ -EVXVMAoGCCqGSM49BAMDA2cAMGQCMGSWWaboCd6LuvpaiIjwH5HTRqjySkwCY/tsXzjbLkGTqQ7m -ndwxHLKgpxgceeHHNgIwOlavmnRs9vuD4DPTCF+hnMJbn0bWtsuRBmOiBuczrD6ogRLQy7rQkgu2 -npaqBA+K ------END CERTIFICATE----- - -VeriSign Universal Root Certification Authority -=============================================== ------BEGIN CERTIFICATE----- -MIIEuTCCA6GgAwIBAgIQQBrEZCGzEyEDDrvkEhrFHTANBgkqhkiG9w0BAQsFADCBvTELMAkGA1UE -BhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMR8wHQYDVQQLExZWZXJpU2lnbiBUcnVzdCBO -ZXR3b3JrMTowOAYDVQQLEzEoYykgMjAwOCBWZXJpU2lnbiwgSW5jLiAtIEZvciBhdXRob3JpemVk -IHVzZSBvbmx5MTgwNgYDVQQDEy9WZXJpU2lnbiBVbml2ZXJzYWwgUm9vdCBDZXJ0aWZpY2F0aW9u -IEF1dGhvcml0eTAeFw0wODA0MDIwMDAwMDBaFw0zNzEyMDEyMzU5NTlaMIG9MQswCQYDVQQGEwJV -UzEXMBUGA1UEChMOVmVyaVNpZ24sIEluYy4xHzAdBgNVBAsTFlZlcmlTaWduIFRydXN0IE5ldHdv -cmsxOjA4BgNVBAsTMShjKSAyMDA4IFZlcmlTaWduLCBJbmMuIC0gRm9yIGF1dGhvcml6ZWQgdXNl -IG9ubHkxODA2BgNVBAMTL1ZlcmlTaWduIFVuaXZlcnNhbCBSb290IENlcnRpZmljYXRpb24gQXV0 -aG9yaXR5MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAx2E3XrEBNNti1xWb/1hajCMj -1mCOkdeQmIN65lgZOIzF9uVkhbSicfvtvbnazU0AtMgtc6XHaXGVHzk8skQHnOgO+k1KxCHfKWGP -MiJhgsWHH26MfF8WIFFE0XBPV+rjHOPMee5Y2A7Cs0WTwCznmhcrewA3ekEzeOEz4vMQGn+HLL72 -9fdC4uW/h2KJXwBL38Xd5HVEMkE6HnFuacsLdUYI0crSK5XQz/u5QGtkjFdN/BMReYTtXlT2NJ8I -AfMQJQYXStrxHXpma5hgZqTZ79IugvHw7wnqRMkVauIDbjPTrJ9VAMf2CGqUuV/c4DPxhGD5WycR -tPwW8rtWaoAljQIDAQABo4GyMIGvMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMG0G -CCsGAQUFBwEMBGEwX6FdoFswWTBXMFUWCWltYWdlL2dpZjAhMB8wBwYFKw4DAhoEFI/l0xqGrI2O -a8PPgGrUSBgsexkuMCUWI2h0dHA6Ly9sb2dvLnZlcmlzaWduLmNvbS92c2xvZ28uZ2lmMB0GA1Ud -DgQWBBS2d/ppSEefUxLVwuoHMnYH0ZcHGTANBgkqhkiG9w0BAQsFAAOCAQEASvj4sAPmLGd75JR3 -Y8xuTPl9Dg3cyLk1uXBPY/ok+myDjEedO2Pzmvl2MpWRsXe8rJq+seQxIcaBlVZaDrHC1LGmWazx -Y8u4TB1ZkErvkBYoH1quEPuBUDgMbMzxPcP1Y+Oz4yHJJDnp/RVmRvQbEdBNc6N9Rvk97ahfYtTx -P/jgdFcrGJ2BtMQo2pSXpXDrrB2+BxHw1dvd5Yzw1TKwg+ZX4o+/vqGqvz0dtdQ46tewXDpPaj+P -wGZsY6rp2aQW9IHRlRQOfc2VNNnSj3BzgXucfr2YYdhFh5iQxeuGMMY1v/D/w1WIg0vvBZIGcfK4 -mJO37M2CYfE45k+XmCpajQ== ------END CERTIFICATE----- - -VeriSign Class 3 Public Primary Certification Authority - G4 -============================================================ ------BEGIN CERTIFICATE----- -MIIDhDCCAwqgAwIBAgIQL4D+I4wOIg9IZxIokYesszAKBggqhkjOPQQDAzCByjELMAkGA1UEBhMC -VVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMR8wHQYDVQQLExZWZXJpU2lnbiBUcnVzdCBOZXR3 -b3JrMTowOAYDVQQLEzEoYykgMjAwNyBWZXJpU2lnbiwgSW5jLiAtIEZvciBhdXRob3JpemVkIHVz -ZSBvbmx5MUUwQwYDVQQDEzxWZXJpU2lnbiBDbGFzcyAzIFB1YmxpYyBQcmltYXJ5IENlcnRpZmlj -YXRpb24gQXV0aG9yaXR5IC0gRzQwHhcNMDcxMTA1MDAwMDAwWhcNMzgwMTE4MjM1OTU5WjCByjEL -MAkGA1UEBhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMR8wHQYDVQQLExZWZXJpU2lnbiBU -cnVzdCBOZXR3b3JrMTowOAYDVQQLEzEoYykgMjAwNyBWZXJpU2lnbiwgSW5jLiAtIEZvciBhdXRo -b3JpemVkIHVzZSBvbmx5MUUwQwYDVQQDEzxWZXJpU2lnbiBDbGFzcyAzIFB1YmxpYyBQcmltYXJ5 -IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IC0gRzQwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAASnVnp8 -Utpkmw4tXNherJI9/gHmGUo9FANL+mAnINmDiWn6VMaaGF5VKmTeBvaNSjutEDxlPZCIBIngMGGz -rl0Bp3vefLK+ymVhAIau2o970ImtTR1ZmkGxvEeA3J5iw/mjgbIwga8wDwYDVR0TAQH/BAUwAwEB -/zAOBgNVHQ8BAf8EBAMCAQYwbQYIKwYBBQUHAQwEYTBfoV2gWzBZMFcwVRYJaW1hZ2UvZ2lmMCEw -HzAHBgUrDgMCGgQUj+XTGoasjY5rw8+AatRIGCx7GS4wJRYjaHR0cDovL2xvZ28udmVyaXNpZ24u -Y29tL3ZzbG9nby5naWYwHQYDVR0OBBYEFLMWkf3upm7ktS5Jj4d4gYDs5bG1MAoGCCqGSM49BAMD -A2gAMGUCMGYhDBgmYFo4e1ZC4Kf8NoRRkSAsdk1DPcQdhCPQrNZ8NQbOzWm9kA3bbEhCHQ6qQgIx -AJw9SDkjOVgaFRJZap7v1VmyHVIsmXHNxynfGyphe3HR3vPA5Q06Sqotp9iGKt0uEA== ------END CERTIFICATE----- - -NetLock Arany (Class Gold) Főtanúsítvány -======================================== ------BEGIN CERTIFICATE----- -MIIEFTCCAv2gAwIBAgIGSUEs5AAQMA0GCSqGSIb3DQEBCwUAMIGnMQswCQYDVQQGEwJIVTERMA8G -A1UEBwwIQnVkYXBlc3QxFTATBgNVBAoMDE5ldExvY2sgS2Z0LjE3MDUGA1UECwwuVGFuw7pzw610 -dsOhbnlraWFkw7NrIChDZXJ0aWZpY2F0aW9uIFNlcnZpY2VzKTE1MDMGA1UEAwwsTmV0TG9jayBB -cmFueSAoQ2xhc3MgR29sZCkgRsWRdGFuw7pzw610dsOhbnkwHhcNMDgxMjExMTUwODIxWhcNMjgx -MjA2MTUwODIxWjCBpzELMAkGA1UEBhMCSFUxETAPBgNVBAcMCEJ1ZGFwZXN0MRUwEwYDVQQKDAxO -ZXRMb2NrIEtmdC4xNzA1BgNVBAsMLlRhbsO6c8OtdHbDoW55a2lhZMOzayAoQ2VydGlmaWNhdGlv -biBTZXJ2aWNlcykxNTAzBgNVBAMMLE5ldExvY2sgQXJhbnkgKENsYXNzIEdvbGQpIEbFkXRhbsO6 -c8OtdHbDoW55MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAxCRec75LbRTDofTjl5Bu -0jBFHjzuZ9lk4BqKf8owyoPjIMHj9DrTlF8afFttvzBPhCf2nx9JvMaZCpDyD/V/Q4Q3Y1GLeqVw -/HpYzY6b7cNGbIRwXdrzAZAj/E4wqX7hJ2Pn7WQ8oLjJM2P+FpD/sLj916jAwJRDC7bVWaaeVtAk -H3B5r9s5VA1lddkVQZQBr17s9o3x/61k/iCa11zr/qYfCGSji3ZVrR47KGAuhyXoqq8fxmRGILdw -fzzeSNuWU7c5d+Qa4scWhHaXWy+7GRWF+GmF9ZmnqfI0p6m2pgP8b4Y9VHx2BJtr+UBdADTHLpl1 -neWIA6pN+APSQnbAGwIDAKiLo0UwQzASBgNVHRMBAf8ECDAGAQH/AgEEMA4GA1UdDwEB/wQEAwIB -BjAdBgNVHQ4EFgQUzPpnk/C2uNClwB7zU/2MU9+D15YwDQYJKoZIhvcNAQELBQADggEBAKt/7hwW -qZw8UQCgwBEIBaeZ5m8BiFRhbvG5GK1Krf6BQCOUL/t1fC8oS2IkgYIL9WHxHG64YTjrgfpioTta -YtOUZcTh5m2C+C8lcLIhJsFyUR+MLMOEkMNaj7rP9KdlpeuY0fsFskZ1FSNqb4VjMIDw1Z4fKRzC -bLBQWV2QWzuoDTDPv31/zvGdg73JRm4gpvlhUbohL3u+pRVjodSVh/GeufOJ8z2FuLjbvrW5Kfna -NwUASZQDhETnv0Mxz3WLJdH0pmT1kvarBes96aULNmLazAZfNou2XjG4Kvte9nHfRCaexOYNkbQu -dZWAUWpLMKawYqGT8ZvYzsRjdT9ZR7E= ------END CERTIFICATE----- - -Staat der Nederlanden Root CA - G2 -================================== ------BEGIN CERTIFICATE----- -MIIFyjCCA7KgAwIBAgIEAJiWjDANBgkqhkiG9w0BAQsFADBaMQswCQYDVQQGEwJOTDEeMBwGA1UE -CgwVU3RhYXQgZGVyIE5lZGVybGFuZGVuMSswKQYDVQQDDCJTdGFhdCBkZXIgTmVkZXJsYW5kZW4g -Um9vdCBDQSAtIEcyMB4XDTA4MDMyNjExMTgxN1oXDTIwMDMyNTExMDMxMFowWjELMAkGA1UEBhMC -TkwxHjAcBgNVBAoMFVN0YWF0IGRlciBOZWRlcmxhbmRlbjErMCkGA1UEAwwiU3RhYXQgZGVyIE5l -ZGVybGFuZGVuIFJvb3QgQ0EgLSBHMjCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAMVZ -5291qj5LnLW4rJ4L5PnZyqtdj7U5EILXr1HgO+EASGrP2uEGQxGZqhQlEq0i6ABtQ8SpuOUfiUtn -vWFI7/3S4GCI5bkYYCjDdyutsDeqN95kWSpGV+RLufg3fNU254DBtvPUZ5uW6M7XxgpT0GtJlvOj -CwV3SPcl5XCsMBQgJeN/dVrlSPhOewMHBPqCYYdu8DvEpMfQ9XQ+pV0aCPKbJdL2rAQmPlU6Yiil -e7Iwr/g3wtG61jj99O9JMDeZJiFIhQGp5Rbn3JBV3w/oOM2ZNyFPXfUib2rFEhZgF1XyZWampzCR -OME4HYYEhLoaJXhena/MUGDWE4dS7WMfbWV9whUYdMrhfmQpjHLYFhN9C0lK8SgbIHRrxT3dsKpI -CT0ugpTNGmXZK4iambwYfp/ufWZ8Pr2UuIHOzZgweMFvZ9C+X+Bo7d7iscksWXiSqt8rYGPy5V65 -48r6f1CGPqI0GAwJaCgRHOThuVw+R7oyPxjMW4T182t0xHJ04eOLoEq9jWYv6q012iDTiIJh8BIi -trzQ1aTsr1SIJSQ8p22xcik/Plemf1WvbibG/ufMQFxRRIEKeN5KzlW/HdXZt1bv8Hb/C3m1r737 -qWmRRpdogBQ2HbN/uymYNqUg+oJgYjOk7Na6B6duxc8UpufWkjTYgfX8HV2qXB72o007uPc5AgMB -AAGjgZcwgZQwDwYDVR0TAQH/BAUwAwEB/zBSBgNVHSAESzBJMEcGBFUdIAAwPzA9BggrBgEFBQcC -ARYxaHR0cDovL3d3dy5wa2lvdmVyaGVpZC5ubC9wb2xpY2llcy9yb290LXBvbGljeS1HMjAOBgNV -HQ8BAf8EBAMCAQYwHQYDVR0OBBYEFJFoMocVHYnitfGsNig0jQt8YojrMA0GCSqGSIb3DQEBCwUA -A4ICAQCoQUpnKpKBglBu4dfYszk78wIVCVBR7y29JHuIhjv5tLySCZa59sCrI2AGeYwRTlHSeYAz -+51IvuxBQ4EffkdAHOV6CMqqi3WtFMTC6GY8ggen5ieCWxjmD27ZUD6KQhgpxrRW/FYQoAUXvQwj -f/ST7ZwaUb7dRUG/kSS0H4zpX897IZmflZ85OkYcbPnNe5yQzSipx6lVu6xiNGI1E0sUOlWDuYaN -kqbG9AclVMwWVxJKgnjIFNkXgiYtXSAfea7+1HAWFpWD2DU5/1JddRwWxRNVz0fMdWVSSt7wsKfk -CpYL+63C4iWEst3kvX5ZbJvw8NjnyvLplzh+ib7M+zkXYT9y2zqR2GUBGR2tUKRXCnxLvJxxcypF -URmFzI79R6d0lR2o0a9OF7FpJsKqeFdbxU2n5Z4FF5TKsl+gSRiNNOkmbEgeqmiSBeGCc1qb3Adb -CG19ndeNIdn8FCCqwkXfP+cAslHkwvgFuXkajDTznlvkN1trSt8sV4pAWja63XVECDdCcAz+3F4h -oKOKwJCcaNpQ5kUQR3i2TtJlycM33+FCY7BXN0Ute4qcvwXqZVUz9zkQxSgqIXobisQk+T8VyJoV -IPVVYpbtbZNQvOSqeK3Zywplh6ZmwcSBo3c6WB4L7oOLnR7SUqTMHW+wmG2UMbX4cQrcufx9MmDm -66+KAQ== ------END CERTIFICATE----- - -Hongkong Post Root CA 1 -======================= ------BEGIN CERTIFICATE----- -MIIDMDCCAhigAwIBAgICA+gwDQYJKoZIhvcNAQEFBQAwRzELMAkGA1UEBhMCSEsxFjAUBgNVBAoT -DUhvbmdrb25nIFBvc3QxIDAeBgNVBAMTF0hvbmdrb25nIFBvc3QgUm9vdCBDQSAxMB4XDTAzMDUx -NTA1MTMxNFoXDTIzMDUxNTA0NTIyOVowRzELMAkGA1UEBhMCSEsxFjAUBgNVBAoTDUhvbmdrb25n -IFBvc3QxIDAeBgNVBAMTF0hvbmdrb25nIFBvc3QgUm9vdCBDQSAxMIIBIjANBgkqhkiG9w0BAQEF -AAOCAQ8AMIIBCgKCAQEArP84tulmAknjorThkPlAj3n54r15/gK97iSSHSL22oVyaf7XPwnU3ZG1 -ApzQjVrhVcNQhrkpJsLj2aDxaQMoIIBFIi1WpztUlVYiWR8o3x8gPW2iNr4joLFutbEnPzlTCeqr -auh0ssJlXI6/fMN4hM2eFvz1Lk8gKgifd/PFHsSaUmYeSF7jEAaPIpjhZY4bXSNmO7ilMlHIhqqh -qZ5/dpTCpmy3QfDVyAY45tQM4vM7TG1QjMSDJ8EThFk9nnV0ttgCXjqQesBCNnLsak3c78QA3xMY -V18meMjWCnl3v/evt3a5pQuEF10Q6m/hq5URX208o1xNg1vysxmKgIsLhwIDAQABoyYwJDASBgNV -HRMBAf8ECDAGAQH/AgEDMA4GA1UdDwEB/wQEAwIBxjANBgkqhkiG9w0BAQUFAAOCAQEADkbVPK7i -h9legYsCmEEIjEy82tvuJxuC52pF7BaLT4Wg87JwvVqWuspube5Gi27nKi6Wsxkz67SfqLI37pio -l7Yutmcn1KZJ/RyTZXaeQi/cImyaT/JaFTmxcdcrUehtHJjA2Sr0oYJ71clBoiMBdDhViw+5Lmei -IAQ32pwL0xch4I+XeTRvhEgCIDMb5jREn5Fw9IBehEPCKdJsEhTkYY2sEJCehFC78JZvRZ+K88ps -T/oROhUVRsPNH4NbLUES7VBnQRM9IauUiqpOfMGx+6fWtScvl6tu4B3i0RwsH0Ti/L6RoZz71ilT -c4afU9hDDl3WY4JxHYB0yvbiAmvZWg== ------END CERTIFICATE----- - -SecureSign RootCA11 -=================== ------BEGIN CERTIFICATE----- -MIIDbTCCAlWgAwIBAgIBATANBgkqhkiG9w0BAQUFADBYMQswCQYDVQQGEwJKUDErMCkGA1UEChMi -SmFwYW4gQ2VydGlmaWNhdGlvbiBTZXJ2aWNlcywgSW5jLjEcMBoGA1UEAxMTU2VjdXJlU2lnbiBS -b290Q0ExMTAeFw0wOTA0MDgwNDU2NDdaFw0yOTA0MDgwNDU2NDdaMFgxCzAJBgNVBAYTAkpQMSsw -KQYDVQQKEyJKYXBhbiBDZXJ0aWZpY2F0aW9uIFNlcnZpY2VzLCBJbmMuMRwwGgYDVQQDExNTZWN1 -cmVTaWduIFJvb3RDQTExMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA/XeqpRyQBTvL -TJszi1oURaTnkBbR31fSIRCkF/3frNYfp+TbfPfs37gD2pRY/V1yfIw/XwFndBWW4wI8h9uuywGO -wvNmxoVF9ALGOrVisq/6nL+k5tSAMJjzDbaTj6nU2DbysPyKyiyhFTOVMdrAG/LuYpmGYz+/3ZMq -g6h2uRMft85OQoWPIucuGvKVCbIFtUROd6EgvanyTgp9UK31BQ1FT0Zx/Sg+U/sE2C3XZR1KG/rP -O7AxmjVuyIsG0wCR8pQIZUyxNAYAeoni8McDWc/V1uinMrPmmECGxc0nEovMe863ETxiYAcjPitA -bpSACW22s293bzUIUPsCh8U+iQIDAQABo0IwQDAdBgNVHQ4EFgQUW/hNT7KlhtQ60vFjmqC+CfZX -t94wDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wDQYJKoZIhvcNAQEFBQADggEBAKCh -OBZmLqdWHyGcBvod7bkixTgm2E5P7KN/ed5GIaGHd48HCJqypMWvDzKYC3xmKbabfSVSSUOrTC4r -bnpwrxYO4wJs+0LmGJ1F2FXI6Dvd5+H0LgscNFxsWEr7jIhQX5Ucv+2rIrVls4W6ng+4reV6G4pQ -Oh29Dbx7VFALuUKvVaAYga1lme++5Jy/xIWrQbJUb9wlze144o4MjQlJ3WN7WmmWAiGovVJZ6X01 -y8hSyn+B/tlr0/cR7SXf+Of5pPpyl4RTDaXQMhhRdlkUbA/r7F+AjHVDg8OFmP9Mni0N5HeDk061 -lgeLKBObjBmNQSdJQO7e5iNEOdyhIta6A/I= ------END CERTIFICATE----- - -Microsec e-Szigno Root CA 2009 -============================== ------BEGIN CERTIFICATE----- -MIIECjCCAvKgAwIBAgIJAMJ+QwRORz8ZMA0GCSqGSIb3DQEBCwUAMIGCMQswCQYDVQQGEwJIVTER -MA8GA1UEBwwIQnVkYXBlc3QxFjAUBgNVBAoMDU1pY3Jvc2VjIEx0ZC4xJzAlBgNVBAMMHk1pY3Jv -c2VjIGUtU3ppZ25vIFJvb3QgQ0EgMjAwOTEfMB0GCSqGSIb3DQEJARYQaW5mb0BlLXN6aWduby5o -dTAeFw0wOTA2MTYxMTMwMThaFw0yOTEyMzAxMTMwMThaMIGCMQswCQYDVQQGEwJIVTERMA8GA1UE -BwwIQnVkYXBlc3QxFjAUBgNVBAoMDU1pY3Jvc2VjIEx0ZC4xJzAlBgNVBAMMHk1pY3Jvc2VjIGUt -U3ppZ25vIFJvb3QgQ0EgMjAwOTEfMB0GCSqGSIb3DQEJARYQaW5mb0BlLXN6aWduby5odTCCASIw -DQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAOn4j/NjrdqG2KfgQvvPkd6mJviZpWNwrZuuyjNA -fW2WbqEORO7hE52UQlKavXWFdCyoDh2Tthi3jCyoz/tccbna7P7ofo/kLx2yqHWH2Leh5TvPmUpG -0IMZfcChEhyVbUr02MelTTMuhTlAdX4UfIASmFDHQWe4oIBhVKZsTh/gnQ4H6cm6M+f+wFUoLAKA -pxn1ntxVUwOXewdI/5n7N4okxFnMUBBjjqqpGrCEGob5X7uxUG6k0QrM1XF+H6cbfPVTbiJfyyvm -1HxdrtbCxkzlBQHZ7Vf8wSN5/PrIJIOV87VqUQHQd9bpEqH5GoP7ghu5sJf0dgYzQ0mg/wu1+rUC -AwEAAaOBgDB+MA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBTLD8bf -QkPMPcu1SCOhGnqmKrs0aDAfBgNVHSMEGDAWgBTLD8bfQkPMPcu1SCOhGnqmKrs0aDAbBgNVHREE -FDASgRBpbmZvQGUtc3ppZ25vLmh1MA0GCSqGSIb3DQEBCwUAA4IBAQDJ0Q5eLtXMs3w+y/w9/w0o -lZMEyL/azXm4Q5DwpL7v8u8hmLzU1F0G9u5C7DBsoKqpyvGvivo/C3NqPuouQH4frlRheesuCDfX -I/OMn74dseGkddug4lQUsbocKaQY9hK6ohQU4zE1yED/t+AFdlfBHFny+L/k7SViXITwfn4fs775 -tyERzAMBVnCnEJIeGzSBHq2cGsMEPO0CYdYeBvNfOofyK/FFh+U9rNHHV4S9a67c2Pm2G2JwCz02 -yULyMtd6YebS2z3PyKnJm9zbWETXbzivf3jTo60adbocwTZ8jx5tHMN1Rq41Bab2XD0h7lbwyYIi -LXpUq3DDfSJlgnCW ------END CERTIFICATE----- - -GlobalSign Root CA - R3 -======================= ------BEGIN CERTIFICATE----- -MIIDXzCCAkegAwIBAgILBAAAAAABIVhTCKIwDQYJKoZIhvcNAQELBQAwTDEgMB4GA1UECxMXR2xv -YmFsU2lnbiBSb290IENBIC0gUjMxEzARBgNVBAoTCkdsb2JhbFNpZ24xEzARBgNVBAMTCkdsb2Jh -bFNpZ24wHhcNMDkwMzE4MTAwMDAwWhcNMjkwMzE4MTAwMDAwWjBMMSAwHgYDVQQLExdHbG9iYWxT -aWduIFJvb3QgQ0EgLSBSMzETMBEGA1UEChMKR2xvYmFsU2lnbjETMBEGA1UEAxMKR2xvYmFsU2ln -bjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAMwldpB5BngiFvXAg7aEyiie/QV2EcWt -iHL8RgJDx7KKnQRfJMsuS+FggkbhUqsMgUdwbN1k0ev1LKMPgj0MK66X17YUhhB5uzsTgHeMCOFJ -0mpiLx9e+pZo34knlTifBtc+ycsmWQ1z3rDI6SYOgxXG71uL0gRgykmmKPZpO/bLyCiR5Z2KYVc3 -rHQU3HTgOu5yLy6c+9C7v/U9AOEGM+iCK65TpjoWc4zdQQ4gOsC0p6Hpsk+QLjJg6VfLuQSSaGjl -OCZgdbKfd/+RFO+uIEn8rUAVSNECMWEZXriX7613t2Saer9fwRPvm2L7DWzgVGkWqQPabumDk3F2 -xmmFghcCAwEAAaNCMEAwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYE -FI/wS3+oLkUkrk1Q+mOai97i3Ru8MA0GCSqGSIb3DQEBCwUAA4IBAQBLQNvAUKr+yAzv95ZURUm7 -lgAJQayzE4aGKAczymvmdLm6AC2upArT9fHxD4q/c2dKg8dEe3jgr25sbwMpjjM5RcOO5LlXbKr8 -EpbsU8Yt5CRsuZRj+9xTaGdWPoO4zzUhw8lo/s7awlOqzJCK6fBdRoyV3XpYKBovHd7NADdBj+1E -bddTKJd+82cEHhXXipa0095MJ6RMG3NzdvQXmcIfeg7jLQitChws/zyrVQ4PkX4268NXSb7hLi18 -YIvDQVETI53O9zJrlAGomecsMx86OyXShkDOOyyGeMlhLxS67ttVb9+E7gUJTb0o2HLO02JQZR7r -kpeDMdmztcpHWD9f ------END CERTIFICATE----- - -Autoridad de Certificacion Firmaprofesional CIF A62634068 -========================================================= ------BEGIN CERTIFICATE----- -MIIGFDCCA/ygAwIBAgIIU+w77vuySF8wDQYJKoZIhvcNAQEFBQAwUTELMAkGA1UEBhMCRVMxQjBA -BgNVBAMMOUF1dG9yaWRhZCBkZSBDZXJ0aWZpY2FjaW9uIEZpcm1hcHJvZmVzaW9uYWwgQ0lGIEE2 -MjYzNDA2ODAeFw0wOTA1MjAwODM4MTVaFw0zMDEyMzEwODM4MTVaMFExCzAJBgNVBAYTAkVTMUIw -QAYDVQQDDDlBdXRvcmlkYWQgZGUgQ2VydGlmaWNhY2lvbiBGaXJtYXByb2Zlc2lvbmFsIENJRiBB -NjI2MzQwNjgwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDKlmuO6vj78aI14H9M2uDD -Utd9thDIAl6zQyrET2qyyhxdKJp4ERppWVevtSBC5IsP5t9bpgOSL/UR5GLXMnE42QQMcas9UX4P -B99jBVzpv5RvwSmCwLTaUbDBPLutN0pcyvFLNg4kq7/DhHf9qFD0sefGL9ItWY16Ck6WaVICqjaY -7Pz6FIMMNx/Jkjd/14Et5cS54D40/mf0PmbR0/RAz15iNA9wBj4gGFrO93IbJWyTdBSTo3OxDqqH -ECNZXyAFGUftaI6SEspd/NYrspI8IM/hX68gvqB2f3bl7BqGYTM+53u0P6APjqK5am+5hyZvQWyI -plD9amML9ZMWGxmPsu2bm8mQ9QEM3xk9Dz44I8kvjwzRAv4bVdZO0I08r0+k8/6vKtMFnXkIoctX -MbScyJCyZ/QYFpM6/EfY0XiWMR+6KwxfXZmtY4laJCB22N/9q06mIqqdXuYnin1oKaPnirjaEbsX -LZmdEyRG98Xi2J+Of8ePdG1asuhy9azuJBCtLxTa/y2aRnFHvkLfuwHb9H/TKI8xWVvTyQKmtFLK -bpf7Q8UIJm+K9Lv9nyiqDdVF8xM6HdjAeI9BZzwelGSuewvF6NkBiDkal4ZkQdU7hwxu+g/GvUgU -vzlN1J5Bto+WHWOWk9mVBngxaJ43BjuAiUVhOSPHG0SjFeUc+JIwuwIDAQABo4HvMIHsMBIGA1Ud -EwEB/wQIMAYBAf8CAQEwDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBRlzeurNR4APn7VdMActHNH -DhpkLzCBpgYDVR0gBIGeMIGbMIGYBgRVHSAAMIGPMC8GCCsGAQUFBwIBFiNodHRwOi8vd3d3LmZp -cm1hcHJvZmVzaW9uYWwuY29tL2NwczBcBggrBgEFBQcCAjBQHk4AUABhAHMAZQBvACAAZABlACAA -bABhACAAQgBvAG4AYQBuAG8AdgBhACAANAA3ACAAQgBhAHIAYwBlAGwAbwBuAGEAIAAwADgAMAAx -ADcwDQYJKoZIhvcNAQEFBQADggIBABd9oPm03cXF661LJLWhAqvdpYhKsg9VSytXjDvlMd3+xDLx -51tkljYyGOylMnfX40S2wBEqgLk9am58m9Ot/MPWo+ZkKXzR4Tgegiv/J2Wv+xYVxC5xhOW1//qk -R71kMrv2JYSiJ0L1ILDCExARzRAVukKQKtJE4ZYm6zFIEv0q2skGz3QeqUvVhyj5eTSSPi5E6PaP -T481PyWzOdxjKpBrIF/EUhJOlywqrJ2X3kjyo2bbwtKDlaZmp54lD+kLM5FlClrD2VQS3a/DTg4f -Jl4N3LON7NWBcN7STyQF82xO9UxJZo3R/9ILJUFI/lGExkKvgATP0H5kSeTy36LssUzAKh3ntLFl -osS88Zj0qnAHY7S42jtM+kAiMFsRpvAFDsYCA0irhpuF3dvd6qJ2gHN99ZwExEWN57kci57q13XR -crHedUTnQn3iV2t93Jm8PYMo6oCTjcVMZcFwgbg4/EMxsvYDNEeyrPsiBsse3RdHHF9mudMaotoR -saS8I8nkvof/uZS2+F0gStRf571oe2XyFR7SOqkt6dhrJKyXWERHrVkY8SFlcN7ONGCoQPHzPKTD -KCOM/iczQ0CgFzzr6juwcqajuUpLXhZI9LK8yIySxZ2frHI2vDSANGupi5LAuBft7HZT9SQBjLMi -6Et8Vcad+qMUu2WFbm5PEn4KPJ2V ------END CERTIFICATE----- - -Izenpe.com -========== ------BEGIN CERTIFICATE----- -MIIF8TCCA9mgAwIBAgIQALC3WhZIX7/hy/WL1xnmfTANBgkqhkiG9w0BAQsFADA4MQswCQYDVQQG -EwJFUzEUMBIGA1UECgwLSVpFTlBFIFMuQS4xEzARBgNVBAMMCkl6ZW5wZS5jb20wHhcNMDcxMjEz -MTMwODI4WhcNMzcxMjEzMDgyNzI1WjA4MQswCQYDVQQGEwJFUzEUMBIGA1UECgwLSVpFTlBFIFMu -QS4xEzARBgNVBAMMCkl6ZW5wZS5jb20wggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDJ -03rKDx6sp4boFmVqscIbRTJxldn+EFvMr+eleQGPicPK8lVx93e+d5TzcqQsRNiekpsUOqHnJJAK -ClaOxdgmlOHZSOEtPtoKct2jmRXagaKH9HtuJneJWK3W6wyyQXpzbm3benhB6QiIEn6HLmYRY2xU -+zydcsC8Lv/Ct90NduM61/e0aL6i9eOBbsFGb12N4E3GVFWJGjMxCrFXuaOKmMPsOzTFlUFpfnXC -PCDFYbpRR6AgkJOhkEvzTnyFRVSa0QUmQbC1TR0zvsQDyCV8wXDbO/QJLVQnSKwv4cSsPsjLkkxT -OTcj7NMB+eAJRE1NZMDhDVqHIrytG6P+JrUV86f8hBnp7KGItERphIPzidF0BqnMC9bC3ieFUCbK -F7jJeodWLBoBHmy+E60QrLUk9TiRodZL2vG70t5HtfG8gfZZa88ZU+mNFctKy6lvROUbQc/hhqfK -0GqfvEyNBjNaooXlkDWgYlwWTvDjovoDGrQscbNYLN57C9saD+veIR8GdwYDsMnvmfzAuU8Lhij+ -0rnq49qlw0dpEuDb8PYZi+17cNcC1u2HGCgsBCRMd+RIihrGO5rUD8r6ddIBQFqNeb+Lz0vPqhbB -leStTIo+F5HUsWLlguWABKQDfo2/2n+iD5dPDNMN+9fR5XJ+HMh3/1uaD7euBUbl8agW7EekFwID -AQABo4H2MIHzMIGwBgNVHREEgagwgaWBD2luZm9AaXplbnBlLmNvbaSBkTCBjjFHMEUGA1UECgw+ -SVpFTlBFIFMuQS4gLSBDSUYgQTAxMzM3MjYwLVJNZXJjLlZpdG9yaWEtR2FzdGVpeiBUMTA1NSBG -NjIgUzgxQzBBBgNVBAkMOkF2ZGEgZGVsIE1lZGl0ZXJyYW5lbyBFdG9yYmlkZWEgMTQgLSAwMTAx -MCBWaXRvcmlhLUdhc3RlaXowDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0O -BBYEFB0cZQ6o8iV7tJHP5LGx5r1VdGwFMA0GCSqGSIb3DQEBCwUAA4ICAQB4pgwWSp9MiDrAyw6l -Fn2fuUhfGI8NYjb2zRlrrKvV9pF9rnHzP7MOeIWblaQnIUdCSnxIOvVFfLMMjlF4rJUT3sb9fbga -kEyrkgPH7UIBzg/YsfqikuFgba56awmqxinuaElnMIAkejEWOVt+8Rwu3WwJrfIxwYJOubv5vr8q -hT/AQKM6WfxZSzwoJNu0FXWuDYi6LnPAvViH5ULy617uHjAimcs30cQhbIHsvm0m5hzkQiCeR7Cs -g1lwLDXWrzY0tM07+DKo7+N4ifuNRSzanLh+QBxh5z6ikixL8s36mLYp//Pye6kfLqCTVyvehQP5 -aTfLnnhqBbTFMXiJ7HqnheG5ezzevh55hM6fcA5ZwjUukCox2eRFekGkLhObNA5me0mrZJfQRsN5 -nXJQY6aYWwa9SG3YOYNw6DXwBdGqvOPbyALqfP2C2sJbUjWumDqtujWTI6cfSN01RpiyEGjkpTHC -ClguGYEQyVB1/OpaFs4R1+7vUIgtYf8/QnMFlEPVjjxOAToZpR9GTnfQXeWBIiGH/pR9hNiTrdZo -Q0iy2+tzJOeRf1SktoA+naM8THLCV8Sg1Mw4J87VBp6iSNnpn86CcDaTmjvfliHjWbcM2pE38P1Z -WrOZyGlsQyYBNWNgVYkDOnXYukrZVP/u3oDYLdE41V4tC5h9Pmzb/CaIxw== ------END CERTIFICATE----- - -Chambers of Commerce Root - 2008 -================================ ------BEGIN CERTIFICATE----- -MIIHTzCCBTegAwIBAgIJAKPaQn6ksa7aMA0GCSqGSIb3DQEBBQUAMIGuMQswCQYDVQQGEwJFVTFD -MEEGA1UEBxM6TWFkcmlkIChzZWUgY3VycmVudCBhZGRyZXNzIGF0IHd3dy5jYW1lcmZpcm1hLmNv -bS9hZGRyZXNzKTESMBAGA1UEBRMJQTgyNzQzMjg3MRswGQYDVQQKExJBQyBDYW1lcmZpcm1hIFMu -QS4xKTAnBgNVBAMTIENoYW1iZXJzIG9mIENvbW1lcmNlIFJvb3QgLSAyMDA4MB4XDTA4MDgwMTEy -Mjk1MFoXDTM4MDczMTEyMjk1MFowga4xCzAJBgNVBAYTAkVVMUMwQQYDVQQHEzpNYWRyaWQgKHNl -ZSBjdXJyZW50IGFkZHJlc3MgYXQgd3d3LmNhbWVyZmlybWEuY29tL2FkZHJlc3MpMRIwEAYDVQQF -EwlBODI3NDMyODcxGzAZBgNVBAoTEkFDIENhbWVyZmlybWEgUy5BLjEpMCcGA1UEAxMgQ2hhbWJl -cnMgb2YgQ29tbWVyY2UgUm9vdCAtIDIwMDgwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoIC -AQCvAMtwNyuAWko6bHiUfaN/Gh/2NdW928sNRHI+JrKQUrpjOyhYb6WzbZSm891kDFX29ufyIiKA -XuFixrYp4YFs8r/lfTJqVKAyGVn+H4vXPWCGhSRv4xGzdz4gljUha7MI2XAuZPeEklPWDrCQiorj -h40G072QDuKZoRuGDtqaCrsLYVAGUvGef3bsyw/QHg3PmTA9HMRFEFis1tPo1+XqxQEHd9ZR5gN/ -ikilTWh1uem8nk4ZcfUyS5xtYBkL+8ydddy/Js2Pk3g5eXNeJQ7KXOt3EgfLZEFHcpOrUMPrCXZk -NNI5t3YRCQ12RcSprj1qr7V9ZS+UWBDsXHyvfuK2GNnQm05aSd+pZgvMPMZ4fKecHePOjlO+Bd5g -D2vlGts/4+EhySnB8esHnFIbAURRPHsl18TlUlRdJQfKFiC4reRB7noI/plvg6aRArBsNlVq5331 -lubKgdaX8ZSD6e2wsWsSaR6s+12pxZjptFtYer49okQ6Y1nUCyXeG0+95QGezdIp1Z8XGQpvvwyQ -0wlf2eOKNcx5Wk0ZN5K3xMGtr/R5JJqyAQuxr1yW84Ay+1w9mPGgP0revq+ULtlVmhduYJ1jbLhj -ya6BXBg14JC7vjxPNyK5fuvPnnchpj04gftI2jE9K+OJ9dC1vX7gUMQSibMjmhAxhduub+84Mxh2 -EQIDAQABo4IBbDCCAWgwEgYDVR0TAQH/BAgwBgEB/wIBDDAdBgNVHQ4EFgQU+SSsD7K1+HnA+mCI -G8TZTQKeFxkwgeMGA1UdIwSB2zCB2IAU+SSsD7K1+HnA+mCIG8TZTQKeFxmhgbSkgbEwga4xCzAJ -BgNVBAYTAkVVMUMwQQYDVQQHEzpNYWRyaWQgKHNlZSBjdXJyZW50IGFkZHJlc3MgYXQgd3d3LmNh -bWVyZmlybWEuY29tL2FkZHJlc3MpMRIwEAYDVQQFEwlBODI3NDMyODcxGzAZBgNVBAoTEkFDIENh -bWVyZmlybWEgUy5BLjEpMCcGA1UEAxMgQ2hhbWJlcnMgb2YgQ29tbWVyY2UgUm9vdCAtIDIwMDiC -CQCj2kJ+pLGu2jAOBgNVHQ8BAf8EBAMCAQYwPQYDVR0gBDYwNDAyBgRVHSAAMCowKAYIKwYBBQUH -AgEWHGh0dHA6Ly9wb2xpY3kuY2FtZXJmaXJtYS5jb20wDQYJKoZIhvcNAQEFBQADggIBAJASryI1 -wqM58C7e6bXpeHxIvj99RZJe6dqxGfwWPJ+0W2aeaufDuV2I6A+tzyMP3iU6XsxPpcG1Lawk0lgH -3qLPaYRgM+gQDROpI9CF5Y57pp49chNyM/WqfcZjHwj0/gF/JM8rLFQJ3uIrbZLGOU8W6jx+ekbU -RWpGqOt1glanq6B8aBMz9p0w8G8nOSQjKpD9kCk18pPfNKXG9/jvjA9iSnyu0/VU+I22mlaHFoI6 -M6taIgj3grrqLuBHmrS1RaMFO9ncLkVAO+rcf+g769HsJtg1pDDFOqxXnrN2pSB7+R5KBWIBpih1 -YJeSDW4+TTdDDZIVnBgizVGZoCkaPF+KMjNbMMeJL0eYD6MDxvbxrN8y8NmBGuScvfaAFPDRLLmF -9dijscilIeUcE5fuDr3fKanvNFNb0+RqE4QGtjICxFKuItLcsiFCGtpA8CnJ7AoMXOLQusxI0zcK -zBIKinmwPQN/aUv0NCB9szTqjktk9T79syNnFQ0EuPAtwQlRPLJsFfClI9eDdOTlLsn+mCdCxqvG -nrDQWzilm1DefhiYtUU79nm06PcaewaD+9CL2rvHvRirCG88gGtAPxkZumWK5r7VXNM21+9AUiRg -OGcEMeyP84LG3rlV8zsxkVrctQgVrXYlCg17LofiDKYGvCYQbTed7N14jHyAxfDZd0jQ ------END CERTIFICATE----- - -Global Chambersign Root - 2008 -============================== ------BEGIN CERTIFICATE----- -MIIHSTCCBTGgAwIBAgIJAMnN0+nVfSPOMA0GCSqGSIb3DQEBBQUAMIGsMQswCQYDVQQGEwJFVTFD -MEEGA1UEBxM6TWFkcmlkIChzZWUgY3VycmVudCBhZGRyZXNzIGF0IHd3dy5jYW1lcmZpcm1hLmNv -bS9hZGRyZXNzKTESMBAGA1UEBRMJQTgyNzQzMjg3MRswGQYDVQQKExJBQyBDYW1lcmZpcm1hIFMu -QS4xJzAlBgNVBAMTHkdsb2JhbCBDaGFtYmVyc2lnbiBSb290IC0gMjAwODAeFw0wODA4MDExMjMx -NDBaFw0zODA3MzExMjMxNDBaMIGsMQswCQYDVQQGEwJFVTFDMEEGA1UEBxM6TWFkcmlkIChzZWUg -Y3VycmVudCBhZGRyZXNzIGF0IHd3dy5jYW1lcmZpcm1hLmNvbS9hZGRyZXNzKTESMBAGA1UEBRMJ -QTgyNzQzMjg3MRswGQYDVQQKExJBQyBDYW1lcmZpcm1hIFMuQS4xJzAlBgNVBAMTHkdsb2JhbCBD -aGFtYmVyc2lnbiBSb290IC0gMjAwODCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAMDf -VtPkOpt2RbQT2//BthmLN0EYlVJH6xedKYiONWwGMi5HYvNJBL99RDaxccy9Wglz1dmFRP+RVyXf -XjaOcNFccUMd2drvXNL7G706tcuto8xEpw2uIRU/uXpbknXYpBI4iRmKt4DS4jJvVpyR1ogQC7N0 -ZJJ0YPP2zxhPYLIj0Mc7zmFLmY/CDNBAspjcDahOo7kKrmCgrUVSY7pmvWjg+b4aqIG7HkF4ddPB -/gBVsIdU6CeQNR1MM62X/JcumIS/LMmjv9GYERTtY/jKmIhYF5ntRQOXfjyGHoiMvvKRhI9lNNgA -TH23MRdaKXoKGCQwoze1eqkBfSbW+Q6OWfH9GzO1KTsXO0G2Id3UwD2ln58fQ1DJu7xsepeY7s2M -H/ucUa6LcL0nn3HAa6x9kGbo1106DbDVwo3VyJ2dwW3Q0L9R5OP4wzg2rtandeavhENdk5IMagfe -Ox2YItaswTXbo6Al/3K1dh3ebeksZixShNBFks4c5eUzHdwHU1SjqoI7mjcv3N2gZOnm3b2u/GSF -HTynyQbehP9r6GsaPMWis0L7iwk+XwhSx2LE1AVxv8Rk5Pihg+g+EpuoHtQ2TS9x9o0o9oOpE9Jh -wZG7SMA0j0GMS0zbaRL/UJScIINZc+18ofLx/d33SdNDWKBWY8o9PeU1VlnpDsogzCtLkykPAgMB -AAGjggFqMIIBZjASBgNVHRMBAf8ECDAGAQH/AgEMMB0GA1UdDgQWBBS5CcqcHtvTbDprru1U8VuT -BjUuXjCB4QYDVR0jBIHZMIHWgBS5CcqcHtvTbDprru1U8VuTBjUuXqGBsqSBrzCBrDELMAkGA1UE -BhMCRVUxQzBBBgNVBAcTOk1hZHJpZCAoc2VlIGN1cnJlbnQgYWRkcmVzcyBhdCB3d3cuY2FtZXJm -aXJtYS5jb20vYWRkcmVzcykxEjAQBgNVBAUTCUE4Mjc0MzI4NzEbMBkGA1UEChMSQUMgQ2FtZXJm -aXJtYSBTLkEuMScwJQYDVQQDEx5HbG9iYWwgQ2hhbWJlcnNpZ24gUm9vdCAtIDIwMDiCCQDJzdPp -1X0jzjAOBgNVHQ8BAf8EBAMCAQYwPQYDVR0gBDYwNDAyBgRVHSAAMCowKAYIKwYBBQUHAgEWHGh0 -dHA6Ly9wb2xpY3kuY2FtZXJmaXJtYS5jb20wDQYJKoZIhvcNAQEFBQADggIBAICIf3DekijZBZRG -/5BXqfEv3xoNa/p8DhxJJHkn2EaqbylZUohwEurdPfWbU1Rv4WCiqAm57OtZfMY18dwY6fFn5a+6 -ReAJ3spED8IXDneRRXozX1+WLGiLwUePmJs9wOzL9dWCkoQ10b42OFZyMVtHLaoXpGNR6woBrX/s -dZ7LoR/xfxKxueRkf2fWIyr0uDldmOghp+G9PUIadJpwr2hsUF1Jz//7Dl3mLEfXgTpZALVza2Mg -9jFFCDkO9HB+QHBaP9BrQql0PSgvAm11cpUJjUhjxsYjV5KTXjXBjfkK9yydYhz2rXzdpjEetrHH -foUm+qRqtdpjMNHvkzeyZi99Bffnt0uYlDXA2TopwZ2yUDMdSqlapskD7+3056huirRXhOukP9Du -qqqHW2Pok+JrqNS4cnhrG+055F3Lm6qH1U9OAP7Zap88MQ8oAgF9mOinsKJknnn4SPIVqczmyETr -P3iZ8ntxPjzxmKfFGBI/5rsoM0LpRQp8bfKGeS/Fghl9CYl8slR2iK7ewfPM4W7bMdaTrpmg7yVq -c5iJWzouE4gev8CSlDQb4ye3ix5vQv/n6TebUB0tovkC7stYWDpxvGjjqsGvHCgfotwjZT+B6q6Z -09gwzxMNTxXJhLynSC34MCN32EZLeW32jO06f2ARePTpm67VVMB0gNELQp/B ------END CERTIFICATE----- - -Go Daddy Root Certificate Authority - G2 -======================================== ------BEGIN CERTIFICATE----- -MIIDxTCCAq2gAwIBAgIBADANBgkqhkiG9w0BAQsFADCBgzELMAkGA1UEBhMCVVMxEDAOBgNVBAgT -B0FyaXpvbmExEzARBgNVBAcTClNjb3R0c2RhbGUxGjAYBgNVBAoTEUdvRGFkZHkuY29tLCBJbmMu -MTEwLwYDVQQDEyhHbyBEYWRkeSBSb290IENlcnRpZmljYXRlIEF1dGhvcml0eSAtIEcyMB4XDTA5 -MDkwMTAwMDAwMFoXDTM3MTIzMTIzNTk1OVowgYMxCzAJBgNVBAYTAlVTMRAwDgYDVQQIEwdBcml6 -b25hMRMwEQYDVQQHEwpTY290dHNkYWxlMRowGAYDVQQKExFHb0RhZGR5LmNvbSwgSW5jLjExMC8G -A1UEAxMoR28gRGFkZHkgUm9vdCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkgLSBHMjCCASIwDQYJKoZI -hvcNAQEBBQADggEPADCCAQoCggEBAL9xYgjx+lk09xvJGKP3gElY6SKDE6bFIEMBO4Tx5oVJnyfq -9oQbTqC023CYxzIBsQU+B07u9PpPL1kwIuerGVZr4oAH/PMWdYA5UXvl+TW2dE6pjYIT5LY/qQOD -+qK+ihVqf94Lw7YZFAXK6sOoBJQ7RnwyDfMAZiLIjWltNowRGLfTshxgtDj6AozO091GB94KPutd -fMh8+7ArU6SSYmlRJQVhGkSBjCypQ5Yj36w6gZoOKcUcqeldHraenjAKOc7xiID7S13MMuyFYkMl -NAJWJwGRtDtwKj9useiciAF9n9T521NtYJ2/LOdYq7hfRvzOxBsDPAnrSTFcaUaz4EcCAwEAAaNC -MEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFDqahQcQZyi27/a9 -BUFuIMGU2g/eMA0GCSqGSIb3DQEBCwUAA4IBAQCZ21151fmXWWcDYfF+OwYxdS2hII5PZYe096ac -vNjpL9DbWu7PdIxztDhC2gV7+AJ1uP2lsdeu9tfeE8tTEH6KRtGX+rcuKxGrkLAngPnon1rpN5+r -5N9ss4UXnT3ZJE95kTXWXwTrgIOrmgIttRD02JDHBHNA7XIloKmf7J6raBKZV8aPEjoJpL1E/QYV -N8Gb5DKj7Tjo2GTzLH4U/ALqn83/B2gX2yKQOC16jdFU8WnjXzPKej17CuPKf1855eJ1usV2GDPO -LPAvTK33sefOT6jEm0pUBsV/fdUID+Ic/n4XuKxe9tQWskMJDE32p2u0mYRlynqI4uJEvlz36hz1 ------END CERTIFICATE----- - -Starfield Root Certificate Authority - G2 -========================================= ------BEGIN CERTIFICATE----- -MIID3TCCAsWgAwIBAgIBADANBgkqhkiG9w0BAQsFADCBjzELMAkGA1UEBhMCVVMxEDAOBgNVBAgT -B0FyaXpvbmExEzARBgNVBAcTClNjb3R0c2RhbGUxJTAjBgNVBAoTHFN0YXJmaWVsZCBUZWNobm9s -b2dpZXMsIEluYy4xMjAwBgNVBAMTKVN0YXJmaWVsZCBSb290IENlcnRpZmljYXRlIEF1dGhvcml0 -eSAtIEcyMB4XDTA5MDkwMTAwMDAwMFoXDTM3MTIzMTIzNTk1OVowgY8xCzAJBgNVBAYTAlVTMRAw -DgYDVQQIEwdBcml6b25hMRMwEQYDVQQHEwpTY290dHNkYWxlMSUwIwYDVQQKExxTdGFyZmllbGQg -VGVjaG5vbG9naWVzLCBJbmMuMTIwMAYDVQQDEylTdGFyZmllbGQgUm9vdCBDZXJ0aWZpY2F0ZSBB -dXRob3JpdHkgLSBHMjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAL3twQP89o/8ArFv -W59I2Z154qK3A2FWGMNHttfKPTUuiUP3oWmb3ooa/RMgnLRJdzIpVv257IzdIvpy3Cdhl+72WoTs -bhm5iSzchFvVdPtrX8WJpRBSiUZV9Lh1HOZ/5FSuS/hVclcCGfgXcVnrHigHdMWdSL5stPSksPNk -N3mSwOxGXn/hbVNMYq/NHwtjuzqd+/x5AJhhdM8mgkBj87JyahkNmcrUDnXMN/uLicFZ8WJ/X7Nf -ZTD4p7dNdloedl40wOiWVpmKs/B/pM293DIxfJHP4F8R+GuqSVzRmZTRouNjWwl2tVZi4Ut0HZbU -JtQIBFnQmA4O5t78w+wfkPECAwEAAaNCMEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMC -AQYwHQYDVR0OBBYEFHwMMh+n2TB/xH1oo2Kooc6rB1snMA0GCSqGSIb3DQEBCwUAA4IBAQARWfol -TwNvlJk7mh+ChTnUdgWUXuEok21iXQnCoKjUsHU48TRqneSfioYmUeYs0cYtbpUgSpIB7LiKZ3sx -4mcujJUDJi5DnUox9g61DLu34jd/IroAow57UvtruzvE03lRTs2Q9GcHGcg8RnoNAX3FWOdt5oUw -F5okxBDgBPfg8n/Uqgr/Qh037ZTlZFkSIHc40zI+OIF1lnP6aI+xy84fxez6nH7PfrHxBy22/L/K -pL/QlwVKvOoYKAKQvVR4CSFx09F9HdkWsKlhPdAKACL8x3vLCWRFCztAgfd9fDL1mMpYjn0q7pBZ -c2T5NnReJaH1ZgUufzkVqSr7UIuOhWn0 ------END CERTIFICATE----- - -Starfield Services Root Certificate Authority - G2 -================================================== ------BEGIN CERTIFICATE----- -MIID7zCCAtegAwIBAgIBADANBgkqhkiG9w0BAQsFADCBmDELMAkGA1UEBhMCVVMxEDAOBgNVBAgT -B0FyaXpvbmExEzARBgNVBAcTClNjb3R0c2RhbGUxJTAjBgNVBAoTHFN0YXJmaWVsZCBUZWNobm9s -b2dpZXMsIEluYy4xOzA5BgNVBAMTMlN0YXJmaWVsZCBTZXJ2aWNlcyBSb290IENlcnRpZmljYXRl -IEF1dGhvcml0eSAtIEcyMB4XDTA5MDkwMTAwMDAwMFoXDTM3MTIzMTIzNTk1OVowgZgxCzAJBgNV -BAYTAlVTMRAwDgYDVQQIEwdBcml6b25hMRMwEQYDVQQHEwpTY290dHNkYWxlMSUwIwYDVQQKExxT -dGFyZmllbGQgVGVjaG5vbG9naWVzLCBJbmMuMTswOQYDVQQDEzJTdGFyZmllbGQgU2VydmljZXMg -Um9vdCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkgLSBHMjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCC -AQoCggEBANUMOsQq+U7i9b4Zl1+OiFOxHz/Lz58gE20pOsgPfTz3a3Y4Y9k2YKibXlwAgLIvWX/2 -h/klQ4bnaRtSmpDhcePYLQ1Ob/bISdm28xpWriu2dBTrz/sm4xq6HZYuajtYlIlHVv8loJNwU4Pa -hHQUw2eeBGg6345AWh1KTs9DkTvnVtYAcMtS7nt9rjrnvDH5RfbCYM8TWQIrgMw0R9+53pBlbQLP -LJGmpufehRhJfGZOozptqbXuNC66DQO4M99H67FrjSXZm86B0UVGMpZwh94CDklDhbZsc7tk6mFB -rMnUVN+HL8cisibMn1lUaJ/8viovxFUcdUBgF4UCVTmLfwUCAwEAAaNCMEAwDwYDVR0TAQH/BAUw -AwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFJxfAN+qAdcwKziIorhtSpzyEZGDMA0GCSqG -SIb3DQEBCwUAA4IBAQBLNqaEd2ndOxmfZyMIbw5hyf2E3F/YNoHN2BtBLZ9g3ccaaNnRbobhiCPP -E95Dz+I0swSdHynVv/heyNXBve6SbzJ08pGCL72CQnqtKrcgfU28elUSwhXqvfdqlS5sdJ/PHLTy -xQGjhdByPq1zqwubdQxtRbeOlKyWN7Wg0I8VRw7j6IPdj/3vQQF3zCepYoUz8jcI73HPdwbeyBkd -iEDPfUYd/x7H4c7/I9vG+o1VTqkC50cRRj70/b17KSa7qWFiNyi2LSr2EIZkyXCn0q23KXB56jza -YyWf/Wi3MOxw+3WKt21gZ7IeyLnp2KhvAotnDU0mV3HaIPzBSlCNsSi6 ------END CERTIFICATE----- - -AffirmTrust Commercial -====================== ------BEGIN CERTIFICATE----- -MIIDTDCCAjSgAwIBAgIId3cGJyapsXwwDQYJKoZIhvcNAQELBQAwRDELMAkGA1UEBhMCVVMxFDAS -BgNVBAoMC0FmZmlybVRydXN0MR8wHQYDVQQDDBZBZmZpcm1UcnVzdCBDb21tZXJjaWFsMB4XDTEw -MDEyOTE0MDYwNloXDTMwMTIzMTE0MDYwNlowRDELMAkGA1UEBhMCVVMxFDASBgNVBAoMC0FmZmly -bVRydXN0MR8wHQYDVQQDDBZBZmZpcm1UcnVzdCBDb21tZXJjaWFsMIIBIjANBgkqhkiG9w0BAQEF -AAOCAQ8AMIIBCgKCAQEA9htPZwcroRX1BiLLHwGy43NFBkRJLLtJJRTWzsO3qyxPxkEylFf6Eqdb -DuKPHx6GGaeqtS25Xw2Kwq+FNXkyLbscYjfysVtKPcrNcV/pQr6U6Mje+SJIZMblq8Yrba0F8PrV -C8+a5fBQpIs7R6UjW3p6+DM/uO+Zl+MgwdYoic+U+7lF7eNAFxHUdPALMeIrJmqbTFeurCA+ukV6 -BfO9m2kVrn1OIGPENXY6BwLJN/3HR+7o8XYdcxXyl6S1yHp52UKqK39c/s4mT6NmgTWvRLpUHhww -MmWd5jyTXlBOeuM61G7MGvv50jeuJCqrVwMiKA1JdX+3KNp1v47j3A55MQIDAQABo0IwQDAdBgNV -HQ4EFgQUnZPGU4teyq8/nx4P5ZmVvCT2lI8wDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMC -AQYwDQYJKoZIhvcNAQELBQADggEBAFis9AQOzcAN/wr91LoWXym9e2iZWEnStB03TX8nfUYGXUPG -hi4+c7ImfU+TqbbEKpqrIZcUsd6M06uJFdhrJNTxFq7YpFzUf1GO7RgBsZNjvbz4YYCanrHOQnDi -qX0GJX0nof5v7LMeJNrjS1UaADs1tDvZ110w/YETifLCBivtZ8SOyUOyXGsViQK8YvxO8rUzqrJv -0wqiUOP2O+guRMLbZjipM1ZI8W0bM40NjD9gN53Tym1+NH4Nn3J2ixufcv1SNUFFApYvHLKac0kh -sUlHRUe072o0EclNmsxZt9YCnlpOZbWUrhvfKbAW8b8Angc6F2S1BLUjIZkKlTuXfO8= ------END CERTIFICATE----- - -AffirmTrust Networking -====================== ------BEGIN CERTIFICATE----- -MIIDTDCCAjSgAwIBAgIIfE8EORzUmS0wDQYJKoZIhvcNAQEFBQAwRDELMAkGA1UEBhMCVVMxFDAS -BgNVBAoMC0FmZmlybVRydXN0MR8wHQYDVQQDDBZBZmZpcm1UcnVzdCBOZXR3b3JraW5nMB4XDTEw -MDEyOTE0MDgyNFoXDTMwMTIzMTE0MDgyNFowRDELMAkGA1UEBhMCVVMxFDASBgNVBAoMC0FmZmly -bVRydXN0MR8wHQYDVQQDDBZBZmZpcm1UcnVzdCBOZXR3b3JraW5nMIIBIjANBgkqhkiG9w0BAQEF -AAOCAQ8AMIIBCgKCAQEAtITMMxcua5Rsa2FSoOujz3mUTOWUgJnLVWREZY9nZOIG41w3SfYvm4SE -Hi3yYJ0wTsyEheIszx6e/jarM3c1RNg1lho9Nuh6DtjVR6FqaYvZ/Ls6rnla1fTWcbuakCNrmreI -dIcMHl+5ni36q1Mr3Lt2PpNMCAiMHqIjHNRqrSK6mQEubWXLviRmVSRLQESxG9fhwoXA3hA/Pe24 -/PHxI1Pcv2WXb9n5QHGNfb2V1M6+oF4nI979ptAmDgAp6zxG8D1gvz9Q0twmQVGeFDdCBKNwV6gb -h+0t+nvujArjqWaJGctB+d1ENmHP4ndGyH329JKBNv3bNPFyfvMMFr20FQIDAQABo0IwQDAdBgNV -HQ4EFgQUBx/S55zawm6iQLSwelAQUHTEyL0wDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMC -AQYwDQYJKoZIhvcNAQEFBQADggEBAIlXshZ6qML91tmbmzTCnLQyFE2npN/svqe++EPbkTfOtDIu -UFUaNU52Q3Eg75N3ThVwLofDwR1t3Mu1J9QsVtFSUzpE0nPIxBsFZVpikpzuQY0x2+c06lkh1QF6 -12S4ZDnNye2v7UsDSKegmQGA3GWjNq5lWUhPgkvIZfFXHeVZLgo/bNjR9eUJtGxUAArgFU2HdW23 -WJZa3W3SAKD0m0i+wzekujbgfIeFlxoVot4uolu9rxj5kFDNcFn4J2dHy8egBzp90SxdbBk6ZrV9 -/ZFvgrG+CJPbFEfxojfHRZ48x3evZKiT3/Zpg4Jg8klCNO1aAFSFHBY2kgxc+qatv9s= ------END CERTIFICATE----- - -AffirmTrust Premium -=================== ------BEGIN CERTIFICATE----- -MIIFRjCCAy6gAwIBAgIIbYwURrGmCu4wDQYJKoZIhvcNAQEMBQAwQTELMAkGA1UEBhMCVVMxFDAS -BgNVBAoMC0FmZmlybVRydXN0MRwwGgYDVQQDDBNBZmZpcm1UcnVzdCBQcmVtaXVtMB4XDTEwMDEy -OTE0MTAzNloXDTQwMTIzMTE0MTAzNlowQTELMAkGA1UEBhMCVVMxFDASBgNVBAoMC0FmZmlybVRy -dXN0MRwwGgYDVQQDDBNBZmZpcm1UcnVzdCBQcmVtaXVtMIICIjANBgkqhkiG9w0BAQEFAAOCAg8A -MIICCgKCAgEAxBLfqV/+Qd3d9Z+K4/as4Tx4mrzY8H96oDMq3I0gW64tb+eT2TZwamjPjlGjhVtn -BKAQJG9dKILBl1fYSCkTtuG+kU3fhQxTGJoeJKJPj/CihQvL9Cl/0qRY7iZNyaqoe5rZ+jjeRFcV -5fiMyNlI4g0WJx0eyIOFJbe6qlVBzAMiSy2RjYvmia9mx+n/K+k8rNrSs8PhaJyJ+HoAVt70VZVs -+7pk3WKL3wt3MutizCaam7uqYoNMtAZ6MMgpv+0GTZe5HMQxK9VfvFMSF5yZVylmd2EhMQcuJUmd -GPLu8ytxjLW6OQdJd/zvLpKQBY0tL3d770O/Nbua2Plzpyzy0FfuKE4mX4+QaAkvuPjcBukumj5R -p9EixAqnOEhss/n/fauGV+O61oV4d7pD6kh/9ti+I20ev9E2bFhc8e6kGVQa9QPSdubhjL08s9NI -S+LI+H+SqHZGnEJlPqQewQcDWkYtuJfzt9WyVSHvutxMAJf7FJUnM7/oQ0dG0giZFmA7mn7S5u04 -6uwBHjxIVkkJx0w3AJ6IDsBz4W9m6XJHMD4Q5QsDyZpCAGzFlH5hxIrff4IaC1nEWTJ3s7xgaVY5 -/bQGeyzWZDbZvUjthB9+pSKPKrhC9IK31FOQeE4tGv2Bb0TXOwF0lkLgAOIua+rF7nKsu7/+6qqo -+Nz2snmKtmcCAwEAAaNCMEAwHQYDVR0OBBYEFJ3AZ6YMItkm9UWrpmVSESfYRaxjMA8GA1UdEwEB -/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMA0GCSqGSIb3DQEBDAUAA4ICAQCzV00QYk465KzquByv -MiPIs0laUZx2KI15qldGF9X1Uva3ROgIRL8YhNILgM3FEv0AVQVhh0HctSSePMTYyPtwni94loMg -Nt58D2kTiKV1NpgIpsbfrM7jWNa3Pt668+s0QNiigfV4Py/VpfzZotReBA4Xrf5B8OWycvpEgjNC -6C1Y91aMYj+6QrCcDFx+LmUmXFNPALJ4fqENmS2NuB2OosSw/WDQMKSOyARiqcTtNd56l+0OOF6S -L5Nwpamcb6d9Ex1+xghIsV5n61EIJenmJWtSKZGc0jlzCFfemQa0W50QBuHCAKi4HEoCChTQwUHK -+4w1IX2COPKpVJEZNZOUbWo6xbLQu4mGk+ibyQ86p3q4ofB4Rvr8Ny/lioTz3/4E2aFooC8k4gmV -BtWVyuEklut89pMFu+1z6S3RdTnX5yTb2E5fQ4+e0BQ5v1VwSJlXMbSc7kqYA5YwH2AG7hsj/oFg -IxpHYoWlzBk0gG+zrBrjn/B7SK3VAdlntqlyk+otZrWyuOQ9PLLvTIzq6we/qzWaVYa8GKa1qF60 -g2xraUDTn9zxw2lrueFtCfTxqlB2Cnp9ehehVZZCmTEJ3WARjQUwfuaORtGdFNrHF+QFlozEJLUb -zxQHskD4o55BhrwE0GuWyCqANP2/7waj3VjFhT0+j/6eKeC2uAloGRwYQw== ------END CERTIFICATE----- - -AffirmTrust Premium ECC -======================= ------BEGIN CERTIFICATE----- -MIIB/jCCAYWgAwIBAgIIdJclisc/elQwCgYIKoZIzj0EAwMwRTELMAkGA1UEBhMCVVMxFDASBgNV -BAoMC0FmZmlybVRydXN0MSAwHgYDVQQDDBdBZmZpcm1UcnVzdCBQcmVtaXVtIEVDQzAeFw0xMDAx -MjkxNDIwMjRaFw00MDEyMzExNDIwMjRaMEUxCzAJBgNVBAYTAlVTMRQwEgYDVQQKDAtBZmZpcm1U -cnVzdDEgMB4GA1UEAwwXQWZmaXJtVHJ1c3QgUHJlbWl1bSBFQ0MwdjAQBgcqhkjOPQIBBgUrgQQA -IgNiAAQNMF4bFZ0D0KF5Nbc6PJJ6yhUczWLznCZcBz3lVPqj1swS6vQUX+iOGasvLkjmrBhDeKzQ -N8O9ss0s5kfiGuZjuD0uL3jET9v0D6RoTFVya5UdThhClXjMNzyR4ptlKymjQjBAMB0GA1UdDgQW -BBSaryl6wBE1NSZRMADDav5A1a7WPDAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBBjAK -BggqhkjOPQQDAwNnADBkAjAXCfOHiFBar8jAQr9HX/VsaobgxCd05DhT1wV/GzTjxi+zygk8N53X -57hG8f2h4nECMEJZh0PUUd+60wkyWs6Iflc9nF9Ca/UHLbXwgpP5WW+uZPpY5Yse42O+tYHNbwKM -eQ== ------END CERTIFICATE----- - -Certum Trusted Network CA -========================= ------BEGIN CERTIFICATE----- -MIIDuzCCAqOgAwIBAgIDBETAMA0GCSqGSIb3DQEBBQUAMH4xCzAJBgNVBAYTAlBMMSIwIAYDVQQK -ExlVbml6ZXRvIFRlY2hub2xvZ2llcyBTLkEuMScwJQYDVQQLEx5DZXJ0dW0gQ2VydGlmaWNhdGlv -biBBdXRob3JpdHkxIjAgBgNVBAMTGUNlcnR1bSBUcnVzdGVkIE5ldHdvcmsgQ0EwHhcNMDgxMDIy -MTIwNzM3WhcNMjkxMjMxMTIwNzM3WjB+MQswCQYDVQQGEwJQTDEiMCAGA1UEChMZVW5pemV0byBU -ZWNobm9sb2dpZXMgUy5BLjEnMCUGA1UECxMeQ2VydHVtIENlcnRpZmljYXRpb24gQXV0aG9yaXR5 -MSIwIAYDVQQDExlDZXJ0dW0gVHJ1c3RlZCBOZXR3b3JrIENBMIIBIjANBgkqhkiG9w0BAQEFAAOC -AQ8AMIIBCgKCAQEA4/t9o3K6wvDJFIf1awFO4W5AB7ptJ11/91sts1rHUV+rpDKmYYe2bg+G0jAC -l/jXaVehGDldamR5xgFZrDwxSjh80gTSSyjoIF87B6LMTXPb865Px1bVWqeWifrzq2jUI4ZZJ88J -J7ysbnKDHDBy3+Ci6dLhdHUZvSqeexVUBBvXQzmtVSjF4hq79MDkrjhJM8x2hZ85RdKknvISjFH4 -fOQtf/WsX+sWn7Et0brMkUJ3TCXJkDhv2/DM+44el1k+1WBO5gUo7Ul5E0u6SNsv+XLTOcr+H9g0 -cvW0QM8xAcPs3hEtF10fuFDRXhmnad4HMyjKUJX5p1TLVIZQRan5SQIDAQABo0IwQDAPBgNVHRMB -Af8EBTADAQH/MB0GA1UdDgQWBBQIds3LB/8k9sXN7buQvOKEN0Z19zAOBgNVHQ8BAf8EBAMCAQYw -DQYJKoZIhvcNAQEFBQADggEBAKaorSLOAT2mo/9i0Eidi15ysHhE49wcrwn9I0j6vSrEuVUEtRCj -jSfeC4Jj0O7eDDd5QVsisrCaQVymcODU0HfLI9MA4GxWL+FpDQ3Zqr8hgVDZBqWo/5U30Kr+4rP1 -mS1FhIrlQgnXdAIv94nYmem8J9RHjboNRhx3zxSkHLmkMcScKHQDNP8zGSal6Q10tz6XxnboJ5aj -Zt3hrvJBW8qYVoNzcOSGGtIxQbovvi0TWnZvTuhOgQ4/WwMioBK+ZlgRSssDxLQqKi2WF+A5VLxI -03YnnZotBqbJ7DnSq9ufmgsnAjUpsUCV5/nonFWIGUbWtzT1fs45mtk48VH3Tyw= ------END CERTIFICATE----- - -TWCA Root Certification Authority -================================= ------BEGIN CERTIFICATE----- -MIIDezCCAmOgAwIBAgIBATANBgkqhkiG9w0BAQUFADBfMQswCQYDVQQGEwJUVzESMBAGA1UECgwJ -VEFJV0FOLUNBMRAwDgYDVQQLDAdSb290IENBMSowKAYDVQQDDCFUV0NBIFJvb3QgQ2VydGlmaWNh -dGlvbiBBdXRob3JpdHkwHhcNMDgwODI4MDcyNDMzWhcNMzAxMjMxMTU1OTU5WjBfMQswCQYDVQQG -EwJUVzESMBAGA1UECgwJVEFJV0FOLUNBMRAwDgYDVQQLDAdSb290IENBMSowKAYDVQQDDCFUV0NB -IFJvb3QgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEK -AoIBAQCwfnK4pAOU5qfeCTiRShFAh6d8WWQUe7UREN3+v9XAu1bihSX0NXIP+FPQQeFEAcK0HMMx -QhZHhTMidrIKbw/lJVBPhYa+v5guEGcevhEFhgWQxFnQfHgQsIBct+HHK3XLfJ+utdGdIzdjp9xC -oi2SBBtQwXu4PhvJVgSLL1KbralW6cH/ralYhzC2gfeXRfwZVzsrb+RH9JlF/h3x+JejiB03HFyP -4HYlmlD4oFT/RJB2I9IyxsOrBr/8+7/zrX2SYgJbKdM1o5OaQ2RgXbL6Mv87BK9NQGr5x+PvI/1r -y+UPizgN7gr8/g+YnzAx3WxSZfmLgb4i4RxYA7qRG4kHAgMBAAGjQjBAMA4GA1UdDwEB/wQEAwIB -BjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBRqOFsmjd6LWvJPelSDGRjjCDWmujANBgkqhkiG -9w0BAQUFAAOCAQEAPNV3PdrfibqHDAhUaiBQkr6wQT25JmSDCi/oQMCXKCeCMErJk/9q56YAf4lC -mtYR5VPOL8zy2gXE/uJQxDqGfczafhAJO5I1KlOy/usrBdlsXebQ79NqZp4VKIV66IIArB6nCWlW -QtNoURi+VJq/REG6Sb4gumlc7rh3zc5sH62Dlhh9DrUUOYTxKOkto557HnpyWoOzeW/vtPzQCqVY -T0bf+215WfKEIlKuD8z7fDvnaspHYcN6+NOSBB+4IIThNlQWx0DeO4pz3N/GCUzf7Nr/1FNCocny -Yh0igzyXxfkZYiesZSLX0zzG5Y6yU8xJzrww/nsOM5D77dIUkR8Hrw== ------END CERTIFICATE----- - -Security Communication RootCA2 -============================== ------BEGIN CERTIFICATE----- -MIIDdzCCAl+gAwIBAgIBADANBgkqhkiG9w0BAQsFADBdMQswCQYDVQQGEwJKUDElMCMGA1UEChMc -U0VDT00gVHJ1c3QgU3lzdGVtcyBDTy4sTFRELjEnMCUGA1UECxMeU2VjdXJpdHkgQ29tbXVuaWNh -dGlvbiBSb290Q0EyMB4XDTA5MDUyOTA1MDAzOVoXDTI5MDUyOTA1MDAzOVowXTELMAkGA1UEBhMC -SlAxJTAjBgNVBAoTHFNFQ09NIFRydXN0IFN5c3RlbXMgQ08uLExURC4xJzAlBgNVBAsTHlNlY3Vy -aXR5IENvbW11bmljYXRpb24gUm9vdENBMjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB -ANAVOVKxUrO6xVmCxF1SrjpDZYBLx/KWvNs2l9amZIyoXvDjChz335c9S672XewhtUGrzbl+dp++ -+T42NKA7wfYxEUV0kz1XgMX5iZnK5atq1LXaQZAQwdbWQonCv/Q4EpVMVAX3NuRFg3sUZdbcDE3R -3n4MqzvEFb46VqZab3ZpUql6ucjrappdUtAtCms1FgkQhNBqyjoGADdH5H5XTz+L62e4iKrFvlNV -spHEfbmwhRkGeC7bYRr6hfVKkaHnFtWOojnflLhwHyg/i/xAXmODPIMqGplrz95Zajv8bxbXH/1K -EOtOghY6rCcMU/Gt1SSwawNQwS08Ft1ENCcadfsCAwEAAaNCMEAwHQYDVR0OBBYEFAqFqXdlBZh8 -QIH4D5csOPEK7DzPMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MA0GCSqGSIb3DQEB -CwUAA4IBAQBMOqNErLlFsceTfsgLCkLfZOoc7llsCLqJX2rKSpWeeo8HxdpFcoJxDjrSzG+ntKEj -u/Ykn8sX/oymzsLS28yN/HH8AynBbF0zX2S2ZTuJbxh2ePXcokgfGT+Ok+vx+hfuzU7jBBJV1uXk -3fs+BXziHV7Gp7yXT2g69ekuCkO2r1dcYmh8t/2jioSgrGK+KwmHNPBqAbubKVY8/gA3zyNs8U6q -tnRGEmyR7jTV7JqR50S+kDFy1UkC9gLl9B/rfNmWVan/7Ir5mUf/NVoCqgTLiluHcSmRvaS0eg29 -mvVXIwAHIRc/SjnRBUkLp7Y3gaVdjKozXoEofKd9J+sAro03 ------END CERTIFICATE----- - -EC-ACC -====== ------BEGIN CERTIFICATE----- -MIIFVjCCBD6gAwIBAgIQ7is969Qh3hSoYqwE893EATANBgkqhkiG9w0BAQUFADCB8zELMAkGA1UE -BhMCRVMxOzA5BgNVBAoTMkFnZW5jaWEgQ2F0YWxhbmEgZGUgQ2VydGlmaWNhY2lvIChOSUYgUS0w -ODAxMTc2LUkpMSgwJgYDVQQLEx9TZXJ2ZWlzIFB1YmxpY3MgZGUgQ2VydGlmaWNhY2lvMTUwMwYD -VQQLEyxWZWdldSBodHRwczovL3d3dy5jYXRjZXJ0Lm5ldC92ZXJhcnJlbCAoYykwMzE1MDMGA1UE -CxMsSmVyYXJxdWlhIEVudGl0YXRzIGRlIENlcnRpZmljYWNpbyBDYXRhbGFuZXMxDzANBgNVBAMT -BkVDLUFDQzAeFw0wMzAxMDcyMzAwMDBaFw0zMTAxMDcyMjU5NTlaMIHzMQswCQYDVQQGEwJFUzE7 -MDkGA1UEChMyQWdlbmNpYSBDYXRhbGFuYSBkZSBDZXJ0aWZpY2FjaW8gKE5JRiBRLTA4MDExNzYt -SSkxKDAmBgNVBAsTH1NlcnZlaXMgUHVibGljcyBkZSBDZXJ0aWZpY2FjaW8xNTAzBgNVBAsTLFZl -Z2V1IGh0dHBzOi8vd3d3LmNhdGNlcnQubmV0L3ZlcmFycmVsIChjKTAzMTUwMwYDVQQLEyxKZXJh -cnF1aWEgRW50aXRhdHMgZGUgQ2VydGlmaWNhY2lvIENhdGFsYW5lczEPMA0GA1UEAxMGRUMtQUND -MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAsyLHT+KXQpWIR4NA9h0X84NzJB5R85iK -w5K4/0CQBXCHYMkAqbWUZRkiFRfCQ2xmRJoNBD45b6VLeqpjt4pEndljkYRm4CgPukLjbo73FCeT -ae6RDqNfDrHrZqJyTxIThmV6PttPB/SnCWDaOkKZx7J/sxaVHMf5NLWUhdWZXqBIoH7nF2W4onW4 -HvPlQn2v7fOKSGRdghST2MDk/7NQcvJ29rNdQlB50JQ+awwAvthrDk4q7D7SzIKiGGUzE3eeml0a -E9jD2z3Il3rucO2n5nzbcc8tlGLfbdb1OL4/pYUKGbio2Al1QnDE6u/LDsg0qBIimAy4E5S2S+zw -0JDnJwIDAQABo4HjMIHgMB0GA1UdEQQWMBSBEmVjX2FjY0BjYXRjZXJ0Lm5ldDAPBgNVHRMBAf8E -BTADAQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUoMOLRKo3pUW/l4Ba0fF4opvpXY0wfwYD -VR0gBHgwdjB0BgsrBgEEAfV4AQMBCjBlMCwGCCsGAQUFBwIBFiBodHRwczovL3d3dy5jYXRjZXJ0 -Lm5ldC92ZXJhcnJlbDA1BggrBgEFBQcCAjApGidWZWdldSBodHRwczovL3d3dy5jYXRjZXJ0Lm5l -dC92ZXJhcnJlbCAwDQYJKoZIhvcNAQEFBQADggEBAKBIW4IB9k1IuDlVNZyAelOZ1Vr/sXE7zDkJ -lF7W2u++AVtd0x7Y/X1PzaBB4DSTv8vihpw3kpBWHNzrKQXlxJ7HNd+KDM3FIUPpqojlNcAZQmNa -Al6kSBg6hW/cnbw/nZzBh7h6YQjpdwt/cKt63dmXLGQehb+8dJahw3oS7AwaboMMPOhyRp/7SNVe -l+axofjk70YllJyJ22k4vuxcDlbHZVHlUIiIv0LVKz3l+bqeLrPK9HOSAgu+TGbrIP65y7WZf+a2 -E/rKS03Z7lNGBjvGTq2TWoF+bCpLagVFjPIhpDGQh2xlnJ2lYJU6Un/10asIbvPuW/mIPX64b24D -5EI= ------END CERTIFICATE----- - -Hellenic Academic and Research Institutions RootCA 2011 -======================================================= ------BEGIN CERTIFICATE----- -MIIEMTCCAxmgAwIBAgIBADANBgkqhkiG9w0BAQUFADCBlTELMAkGA1UEBhMCR1IxRDBCBgNVBAoT -O0hlbGxlbmljIEFjYWRlbWljIGFuZCBSZXNlYXJjaCBJbnN0aXR1dGlvbnMgQ2VydC4gQXV0aG9y -aXR5MUAwPgYDVQQDEzdIZWxsZW5pYyBBY2FkZW1pYyBhbmQgUmVzZWFyY2ggSW5zdGl0dXRpb25z -IFJvb3RDQSAyMDExMB4XDTExMTIwNjEzNDk1MloXDTMxMTIwMTEzNDk1MlowgZUxCzAJBgNVBAYT -AkdSMUQwQgYDVQQKEztIZWxsZW5pYyBBY2FkZW1pYyBhbmQgUmVzZWFyY2ggSW5zdGl0dXRpb25z -IENlcnQuIEF1dGhvcml0eTFAMD4GA1UEAxM3SGVsbGVuaWMgQWNhZGVtaWMgYW5kIFJlc2VhcmNo -IEluc3RpdHV0aW9ucyBSb290Q0EgMjAxMTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB -AKlTAOMupvaO+mDYLZU++CwqVE7NuYRhlFhPjz2L5EPzdYmNUeTDN9KKiE15HrcS3UN4SoqS5tdI -1Q+kOilENbgH9mgdVc04UfCMJDGFr4PJfel3r+0ae50X+bOdOFAPplp5kYCvN66m0zH7tSYJnTxa -71HFK9+WXesyHgLacEnsbgzImjeN9/E2YEsmLIKe0HjzDQ9jpFEw4fkrJxIH2Oq9GGKYsFk3fb7u -8yBRQlqD75O6aRXxYp2fmTmCobd0LovUxQt7L/DICto9eQqakxylKHJzkUOap9FNhYS5qXSPFEDH -3N6sQWRstBmbAmNtJGSPRLIl6s5ddAxjMlyNh+UCAwEAAaOBiTCBhjAPBgNVHRMBAf8EBTADAQH/ -MAsGA1UdDwQEAwIBBjAdBgNVHQ4EFgQUppFC/RNhSiOeCKQp5dgTBCPuQSUwRwYDVR0eBEAwPqA8 -MAWCAy5ncjAFggMuZXUwBoIELmVkdTAGggQub3JnMAWBAy5ncjAFgQMuZXUwBoEELmVkdTAGgQQu -b3JnMA0GCSqGSIb3DQEBBQUAA4IBAQAf73lB4XtuP7KMhjdCSk4cNx6NZrokgclPEg8hwAOXhiVt -XdMiKahsog2p6z0GW5k6x8zDmjR/qw7IThzh+uTczQ2+vyT+bOdrwg3IBp5OjWEopmr95fZi6hg8 -TqBTnbI6nOulnJEWtk2C4AwFSKls9cz4y51JtPACpf1wA+2KIaWuE4ZJwzNzvoc7dIsXRSZMFpGD -/md9zU1jZ/rzAxKWeAaNsWftjj++n08C9bMJL/NMh98qy5V8AcysNnq/onN694/BtZqhFLKPM58N -7yLcZnuEvUUXBj08yrl3NI/K6s8/MT7jiOOASSXIl7WdmplNsDz4SgCbZN2fOUvRJ9e4 ------END CERTIFICATE----- - -Actalis Authentication Root CA -============================== ------BEGIN CERTIFICATE----- -MIIFuzCCA6OgAwIBAgIIVwoRl0LE48wwDQYJKoZIhvcNAQELBQAwazELMAkGA1UEBhMCSVQxDjAM -BgNVBAcMBU1pbGFuMSMwIQYDVQQKDBpBY3RhbGlzIFMucC5BLi8wMzM1ODUyMDk2NzEnMCUGA1UE -AwweQWN0YWxpcyBBdXRoZW50aWNhdGlvbiBSb290IENBMB4XDTExMDkyMjExMjIwMloXDTMwMDky -MjExMjIwMlowazELMAkGA1UEBhMCSVQxDjAMBgNVBAcMBU1pbGFuMSMwIQYDVQQKDBpBY3RhbGlz -IFMucC5BLi8wMzM1ODUyMDk2NzEnMCUGA1UEAwweQWN0YWxpcyBBdXRoZW50aWNhdGlvbiBSb290 -IENBMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAp8bEpSmkLO/lGMWwUKNvUTufClrJ -wkg4CsIcoBh/kbWHuUA/3R1oHwiD1S0eiKD4j1aPbZkCkpAW1V8IbInX4ay8IMKx4INRimlNAJZa -by/ARH6jDuSRzVju3PvHHkVH3Se5CAGfpiEd9UEtL0z9KK3giq0itFZljoZUj5NDKd45RnijMCO6 -zfB9E1fAXdKDa0hMxKufgFpbOr3JpyI/gCczWw63igxdBzcIy2zSekciRDXFzMwujt0q7bd9Zg1f -YVEiVRvjRuPjPdA1YprbrxTIW6HMiRvhMCb8oJsfgadHHwTrozmSBp+Z07/T6k9QnBn+locePGX2 -oxgkg4YQ51Q+qDp2JE+BIcXjDwL4k5RHILv+1A7TaLndxHqEguNTVHnd25zS8gebLra8Pu2Fbe8l -EfKXGkJh90qX6IuxEAf6ZYGyojnP9zz/GPvG8VqLWeICrHuS0E4UT1lF9gxeKF+w6D9Fz8+vm2/7 -hNN3WpVvrJSEnu68wEqPSpP4RCHiMUVhUE4Q2OM1fEwZtN4Fv6MGn8i1zeQf1xcGDXqVdFUNaBr8 -EBtiZJ1t4JWgw5QHVw0U5r0F+7if5t+L4sbnfpb2U8WANFAoWPASUHEXMLrmeGO89LKtmyuy/uE5 -jF66CyCU3nuDuP/jVo23Eek7jPKxwV2dpAtMK9myGPW1n0sCAwEAAaNjMGEwHQYDVR0OBBYEFFLY -iDrIn3hm7YnzezhwlMkCAjbQMA8GA1UdEwEB/wQFMAMBAf8wHwYDVR0jBBgwFoAUUtiIOsifeGbt -ifN7OHCUyQICNtAwDgYDVR0PAQH/BAQDAgEGMA0GCSqGSIb3DQEBCwUAA4ICAQALe3KHwGCmSUyI -WOYdiPcUZEim2FgKDk8TNd81HdTtBjHIgT5q1d07GjLukD0R0i70jsNjLiNmsGe+b7bAEzlgqqI0 -JZN1Ut6nna0Oh4lScWoWPBkdg/iaKWW+9D+a2fDzWochcYBNy+A4mz+7+uAwTc+G02UQGRjRlwKx -K3JCaKygvU5a2hi/a5iB0P2avl4VSM0RFbnAKVy06Ij3Pjaut2L9HmLecHgQHEhb2rykOLpn7VU+ -Xlff1ANATIGk0k9jpwlCCRT8AKnCgHNPLsBA2RF7SOp6AsDT6ygBJlh0wcBzIm2Tlf05fbsq4/aC -4yyXX04fkZT6/iyj2HYauE2yOE+b+h1IYHkm4vP9qdCa6HCPSXrW5b0KDtst842/6+OkfcvHlXHo -2qN8xcL4dJIEG4aspCJTQLas/kx2z/uUMsA1n3Y/buWQbqCmJqK4LL7RK4X9p2jIugErsWx0Hbhz -lefut8cl8ABMALJ+tguLHPPAUJ4lueAI3jZm/zel0btUZCzJJ7VLkn5l/9Mt4blOvH+kQSGQQXem -OR/qnuOf0GZvBeyqdn6/axag67XH/JJULysRJyU3eExRarDzzFhdFPFqSBX/wge2sY0PjlxQRrM9 -vwGYT7JZVEc+NHt4bVaTLnPqZih4zR0Uv6CPLy64Lo7yFIrM6bV8+2ydDKXhlg== ------END CERTIFICATE----- - -Trustis FPS Root CA -=================== ------BEGIN CERTIFICATE----- -MIIDZzCCAk+gAwIBAgIQGx+ttiD5JNM2a/fH8YygWTANBgkqhkiG9w0BAQUFADBFMQswCQYDVQQG -EwJHQjEYMBYGA1UEChMPVHJ1c3RpcyBMaW1pdGVkMRwwGgYDVQQLExNUcnVzdGlzIEZQUyBSb290 -IENBMB4XDTAzMTIyMzEyMTQwNloXDTI0MDEyMTExMzY1NFowRTELMAkGA1UEBhMCR0IxGDAWBgNV -BAoTD1RydXN0aXMgTGltaXRlZDEcMBoGA1UECxMTVHJ1c3RpcyBGUFMgUm9vdCBDQTCCASIwDQYJ -KoZIhvcNAQEBBQADggEPADCCAQoCggEBAMVQe547NdDfxIzNjpvto8A2mfRC6qc+gIMPpqdZh8mQ -RUN+AOqGeSoDvT03mYlmt+WKVoaTnGhLaASMk5MCPjDSNzoiYYkchU59j9WvezX2fihHiTHcDnlk -H5nSW7r+f2C/revnPDgpai/lkQtV/+xvWNUtyd5MZnGPDNcE2gfmHhjjvSkCqPoc4Vu5g6hBSLwa -cY3nYuUtsuvffM/bq1rKMfFMIvMFE/eC+XN5DL7XSxzA0RU8k0Fk0ea+IxciAIleH2ulrG6nS4zt -o3Lmr2NNL4XSFDWaLk6M6jKYKIahkQlBOrTh4/L68MkKokHdqeMDx4gVOxzUGpTXn2RZEm0CAwEA -AaNTMFEwDwYDVR0TAQH/BAUwAwEB/zAfBgNVHSMEGDAWgBS6+nEleYtXQSUhhgtx67JkDoshZzAd -BgNVHQ4EFgQUuvpxJXmLV0ElIYYLceuyZA6LIWcwDQYJKoZIhvcNAQEFBQADggEBAH5Y//01GX2c -GE+esCu8jowU/yyg2kdbw++BLa8F6nRIW/M+TgfHbcWzk88iNVy2P3UnXwmWzaD+vkAMXBJV+JOC -yinpXj9WV4s4NvdFGkwozZ5BuO1WTISkQMi4sKUraXAEasP41BIy+Q7DsdwyhEQsb8tGD+pmQQ9P -8Vilpg0ND2HepZ5dfWWhPBfnqFVO76DH7cZEf1T1o+CP8HxVIo8ptoGj4W1OLBuAZ+ytIJ8MYmHV -l/9D7S3B2l0pKoU/rGXuhg8FjZBf3+6f9L/uHfuY5H+QK4R4EA5sSVPvFVtlRkpdr7r7OnIdzfYl -iB6XzCGcKQENZetX2fNXlrtIzYE= ------END CERTIFICATE----- - -Buypass Class 2 Root CA -======================= ------BEGIN CERTIFICATE----- -MIIFWTCCA0GgAwIBAgIBAjANBgkqhkiG9w0BAQsFADBOMQswCQYDVQQGEwJOTzEdMBsGA1UECgwU -QnV5cGFzcyBBUy05ODMxNjMzMjcxIDAeBgNVBAMMF0J1eXBhc3MgQ2xhc3MgMiBSb290IENBMB4X -DTEwMTAyNjA4MzgwM1oXDTQwMTAyNjA4MzgwM1owTjELMAkGA1UEBhMCTk8xHTAbBgNVBAoMFEJ1 -eXBhc3MgQVMtOTgzMTYzMzI3MSAwHgYDVQQDDBdCdXlwYXNzIENsYXNzIDIgUm9vdCBDQTCCAiIw -DQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBANfHXvfBB9R3+0Mh9PT1aeTuMgHbo4Yf5FkNuud1 -g1Lr6hxhFUi7HQfKjK6w3Jad6sNgkoaCKHOcVgb/S2TwDCo3SbXlzwx87vFKu3MwZfPVL4O2fuPn -9Z6rYPnT8Z2SdIrkHJasW4DptfQxh6NR/Md+oW+OU3fUl8FVM5I+GC911K2GScuVr1QGbNgGE41b -/+EmGVnAJLqBcXmQRFBoJJRfuLMR8SlBYaNByyM21cHxMlAQTn/0hpPshNOOvEu/XAFOBz3cFIqU -CqTqc/sLUegTBxj6DvEr0VQVfTzh97QZQmdiXnfgolXsttlpF9U6r0TtSsWe5HonfOV116rLJeff -awrbD02TTqigzXsu8lkBarcNuAeBfos4GzjmCleZPe4h6KP1DBbdi+w0jpwqHAAVF41og9JwnxgI -zRFo1clrUs3ERo/ctfPYV3Me6ZQ5BL/T3jjetFPsaRyifsSP5BtwrfKi+fv3FmRmaZ9JUaLiFRhn -Bkp/1Wy1TbMz4GHrXb7pmA8y1x1LPC5aAVKRCfLf6o3YBkBjqhHk/sM3nhRSP/TizPJhk9H9Z2vX -Uq6/aKtAQ6BXNVN48FP4YUIHZMbXb5tMOA1jrGKvNouicwoN9SG9dKpN6nIDSdvHXx1iY8f93ZHs -M+71bbRuMGjeyNYmsHVee7QHIJihdjK4TWxPAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wHQYD -VR0OBBYEFMmAd+BikoL1RpzzuvdMw964o605MA4GA1UdDwEB/wQEAwIBBjANBgkqhkiG9w0BAQsF -AAOCAgEAU18h9bqwOlI5LJKwbADJ784g7wbylp7ppHR/ehb8t/W2+xUbP6umwHJdELFx7rxP462s -A20ucS6vxOOto70MEae0/0qyexAQH6dXQbLArvQsWdZHEIjzIVEpMMpghq9Gqx3tOluwlN5E40EI -osHsHdb9T7bWR9AUC8rmyrV7d35BH16Dx7aMOZawP5aBQW9gkOLo+fsicdl9sz1Gv7SEr5AcD48S -aq/v7h56rgJKihcrdv6sVIkkLE8/trKnToyokZf7KcZ7XC25y2a2t6hbElGFtQl+Ynhw/qlqYLYd -DnkM/crqJIByw5c/8nerQyIKx+u2DISCLIBrQYoIwOula9+ZEsuK1V6ADJHgJgg2SMX6OBE1/yWD -LfJ6v9r9jv6ly0UsH8SIU653DtmadsWOLB2jutXsMq7Aqqz30XpN69QH4kj3Io6wpJ9qzo6ysmD0 -oyLQI+uUWnpp3Q+/QFesa1lQ2aOZ4W7+jQF5JyMV3pKdewlNWudLSDBaGOYKbeaP4NK75t98biGC -wWg5TbSYWGZizEqQXsP6JwSxeRV0mcy+rSDeJmAc61ZRpqPq5KM/p/9h3PFaTWwyI0PurKju7koS -CTxdccK+efrCh2gdC/1cacwG0Jp9VJkqyTkaGa9LKkPzY11aWOIv4x3kqdbQCtCev9eBCfHJxyYN -rJgWVqA= ------END CERTIFICATE----- - -Buypass Class 3 Root CA -======================= ------BEGIN CERTIFICATE----- -MIIFWTCCA0GgAwIBAgIBAjANBgkqhkiG9w0BAQsFADBOMQswCQYDVQQGEwJOTzEdMBsGA1UECgwU -QnV5cGFzcyBBUy05ODMxNjMzMjcxIDAeBgNVBAMMF0J1eXBhc3MgQ2xhc3MgMyBSb290IENBMB4X -DTEwMTAyNjA4Mjg1OFoXDTQwMTAyNjA4Mjg1OFowTjELMAkGA1UEBhMCTk8xHTAbBgNVBAoMFEJ1 -eXBhc3MgQVMtOTgzMTYzMzI3MSAwHgYDVQQDDBdCdXlwYXNzIENsYXNzIDMgUm9vdCBDQTCCAiIw -DQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAKXaCpUWUOOV8l6ddjEGMnqb8RB2uACatVI2zSRH -sJ8YZLya9vrVediQYkwiL944PdbgqOkcLNt4EemOaFEVcsfzM4fkoF0LXOBXByow9c3EN3coTRiR -5r/VUv1xLXA+58bEiuPwKAv0dpihi4dVsjoT/Lc+JzeOIuOoTyrvYLs9tznDDgFHmV0ST9tD+leh -7fmdvhFHJlsTmKtdFoqwNxxXnUX/iJY2v7vKB3tvh2PX0DJq1l1sDPGzbjniazEuOQAnFN44wOwZ -ZoYS6J1yFhNkUsepNxz9gjDthBgd9K5c/3ATAOux9TN6S9ZV+AWNS2mw9bMoNlwUxFFzTWsL8TQH -2xc519woe2v1n/MuwU8XKhDzzMro6/1rqy6any2CbgTUUgGTLT2G/H783+9CHaZr77kgxve9oKeV -/afmiSTYzIw0bOIjL9kSGiG5VZFvC5F5GQytQIgLcOJ60g7YaEi7ghM5EFjp2CoHxhLbWNvSO1UQ -RwUVZ2J+GGOmRj8JDlQyXr8NYnon74Do29lLBlo3WiXQCBJ31G8JUJc9yB3D34xFMFbG02SrZvPA -Xpacw8Tvw3xrizp5f7NJzz3iiZ+gMEuFuZyUJHmPfWupRWgPK9Dx2hzLabjKSWJtyNBjYt1gD1iq -j6G8BaVmos8bdrKEZLFMOVLAMLrwjEsCsLa3AgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wHQYD -VR0OBBYEFEe4zf/lb+74suwvTg75JbCOPGvDMA4GA1UdDwEB/wQEAwIBBjANBgkqhkiG9w0BAQsF -AAOCAgEAACAjQTUEkMJAYmDv4jVM1z+s4jSQuKFvdvoWFqRINyzpkMLyPPgKn9iB5btb2iUspKdV -cSQy9sgL8rxq+JOssgfCX5/bzMiKqr5qb+FJEMwx14C7u8jYog5kV+qi9cKpMRXSIGrs/CIBKM+G -uIAeqcwRpTzyFrNHnfzSgCHEy9BHcEGhyoMZCCxt8l13nIoUE9Q2HJLw5QY33KbmkJs4j1xrG0aG -Q0JfPgEHU1RdZX33inOhmlRaHylDFCfChQ+1iHsaO5S3HWCntZznKWlXWpuTekMwGwPXYshApqr8 -ZORK15FTAaggiG6cX0S5y2CBNOxv033aSF/rtJC8LakcC6wc1aJoIIAE1vyxjy+7SjENSoYc6+I2 -KSb12tjE8nVhz36udmNKekBlk4f4HoCMhuWG1o8O/FMsYOgWYRqiPkN7zTlgVGr18okmAWiDSKIz -6MkEkbIRNBE+6tBDGR8Dk5AM/1E9V/RBbuHLoL7ryWPNbczk+DaqaJ3tvV2XcEQNtg413OEMXbug -UZTLfhbrES+jkkXITHHZvMmZUldGL1DPvTVp9D0VzgalLA8+9oG6lLvDu79leNKGef9JOxqDDPDe -eOzI8k1MGt6CKfjBWtrt7uYnXuhF0J0cUahoq0Tj0Itq4/g7u9xN12TyUb7mqqta6THuBrxzvxNi -Cp/HuZc= ------END CERTIFICATE----- - -T-TeleSec GlobalRoot Class 3 -============================ ------BEGIN CERTIFICATE----- -MIIDwzCCAqugAwIBAgIBATANBgkqhkiG9w0BAQsFADCBgjELMAkGA1UEBhMCREUxKzApBgNVBAoM -IlQtU3lzdGVtcyBFbnRlcnByaXNlIFNlcnZpY2VzIEdtYkgxHzAdBgNVBAsMFlQtU3lzdGVtcyBU -cnVzdCBDZW50ZXIxJTAjBgNVBAMMHFQtVGVsZVNlYyBHbG9iYWxSb290IENsYXNzIDMwHhcNMDgx -MDAxMTAyOTU2WhcNMzMxMDAxMjM1OTU5WjCBgjELMAkGA1UEBhMCREUxKzApBgNVBAoMIlQtU3lz -dGVtcyBFbnRlcnByaXNlIFNlcnZpY2VzIEdtYkgxHzAdBgNVBAsMFlQtU3lzdGVtcyBUcnVzdCBD -ZW50ZXIxJTAjBgNVBAMMHFQtVGVsZVNlYyBHbG9iYWxSb290IENsYXNzIDMwggEiMA0GCSqGSIb3 -DQEBAQUAA4IBDwAwggEKAoIBAQC9dZPwYiJvJK7genasfb3ZJNW4t/zN8ELg63iIVl6bmlQdTQyK -9tPPcPRStdiTBONGhnFBSivwKixVA9ZIw+A5OO3yXDw/RLyTPWGrTs0NvvAgJ1gORH8EGoel15YU -NpDQSXuhdfsaa3Ox+M6pCSzyU9XDFES4hqX2iys52qMzVNn6chr3IhUciJFrf2blw2qAsCTz34ZF -iP0Zf3WHHx+xGwpzJFu5ZeAsVMhg02YXP+HMVDNzkQI6pn97djmiH5a2OK61yJN0HZ65tOVgnS9W -0eDrXltMEnAMbEQgqxHY9Bn20pxSN+f6tsIxO0rUFJmtxxr1XV/6B7h8DR/Wgx6zAgMBAAGjQjBA -MA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBS1A/d2O2GCahKqGFPr -AyGUv/7OyjANBgkqhkiG9w0BAQsFAAOCAQEAVj3vlNW92nOyWL6ukK2YJ5f+AbGwUgC4TeQbIXQb -fsDuXmkqJa9c1h3a0nnJ85cp4IaH3gRZD/FZ1GSFS5mvJQQeyUapl96Cshtwn5z2r3Ex3XsFpSzT -ucpH9sry9uetuUg/vBa3wW306gmv7PO15wWeph6KU1HWk4HMdJP2udqmJQV0eVp+QD6CSyYRMG7h -P0HHRwA11fXT91Q+gT3aSWqas+8QPebrb9HIIkfLzM8BMZLZGOMivgkeGj5asuRrDFR6fUNOuIml -e9eiPZaGzPImNC1qkp2aGtAw4l1OBLBfiyB+d8E9lYLRRpo7PHi4b6HQDWSieB4pTpPDpFQUWw== ------END CERTIFICATE----- - -EE Certification Centre Root CA -=============================== ------BEGIN CERTIFICATE----- -MIIEAzCCAuugAwIBAgIQVID5oHPtPwBMyonY43HmSjANBgkqhkiG9w0BAQUFADB1MQswCQYDVQQG -EwJFRTEiMCAGA1UECgwZQVMgU2VydGlmaXRzZWVyaW1pc2tlc2t1czEoMCYGA1UEAwwfRUUgQ2Vy -dGlmaWNhdGlvbiBDZW50cmUgUm9vdCBDQTEYMBYGCSqGSIb3DQEJARYJcGtpQHNrLmVlMCIYDzIw -MTAxMDMwMTAxMDMwWhgPMjAzMDEyMTcyMzU5NTlaMHUxCzAJBgNVBAYTAkVFMSIwIAYDVQQKDBlB -UyBTZXJ0aWZpdHNlZXJpbWlza2Vza3VzMSgwJgYDVQQDDB9FRSBDZXJ0aWZpY2F0aW9uIENlbnRy -ZSBSb290IENBMRgwFgYJKoZIhvcNAQkBFglwa2lAc2suZWUwggEiMA0GCSqGSIb3DQEBAQUAA4IB -DwAwggEKAoIBAQDIIMDs4MVLqwd4lfNE7vsLDP90jmG7sWLqI9iroWUyeuuOF0+W2Ap7kaJjbMeM -TC55v6kF/GlclY1i+blw7cNRfdCT5mzrMEvhvH2/UpvObntl8jixwKIy72KyaOBhU8E2lf/slLo2 -rpwcpzIP5Xy0xm90/XsY6KxX7QYgSzIwWFv9zajmofxwvI6Sc9uXp3whrj3B9UiHbCe9nyV0gVWw -93X2PaRka9ZP585ArQ/dMtO8ihJTmMmJ+xAdTX7Nfh9WDSFwhfYggx/2uh8Ej+p3iDXE/+pOoYtN -P2MbRMNE1CV2yreN1x5KZmTNXMWcg+HCCIia7E6j8T4cLNlsHaFLAgMBAAGjgYowgYcwDwYDVR0T -AQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFBLyWj7qVhy/zQas8fElyalL1BSZ -MEUGA1UdJQQ+MDwGCCsGAQUFBwMCBggrBgEFBQcDAQYIKwYBBQUHAwMGCCsGAQUFBwMEBggrBgEF -BQcDCAYIKwYBBQUHAwkwDQYJKoZIhvcNAQEFBQADggEBAHv25MANqhlHt01Xo/6tu7Fq1Q+e2+Rj -xY6hUFaTlrg4wCQiZrxTFGGVv9DHKpY5P30osxBAIWrEr7BSdxjhlthWXePdNl4dp1BUoMUq5KqM -lIpPnTX/dqQGE5Gion0ARD9V04I8GtVbvFZMIi5GQ4okQC3zErg7cBqklrkar4dBGmoYDQZPxz5u -uSlNDUmJEYcyW+ZLBMjkXOZ0c5RdFpgTlf7727FE5TpwrDdr5rMzcijJs1eg9gIWiAYLtqZLICjU -3j2LrTcFU3T+bsy8QxdxXvnFzBqpYe73dgzzcvRyrc9yAjYHR8/vGVCJYMzpJJUPwssd8m92kMfM -dcGWxZ0= ------END CERTIFICATE----- - -D-TRUST Root Class 3 CA 2 2009 -============================== ------BEGIN CERTIFICATE----- -MIIEMzCCAxugAwIBAgIDCYPzMA0GCSqGSIb3DQEBCwUAME0xCzAJBgNVBAYTAkRFMRUwEwYDVQQK -DAxELVRydXN0IEdtYkgxJzAlBgNVBAMMHkQtVFJVU1QgUm9vdCBDbGFzcyAzIENBIDIgMjAwOTAe -Fw0wOTExMDUwODM1NThaFw0yOTExMDUwODM1NThaME0xCzAJBgNVBAYTAkRFMRUwEwYDVQQKDAxE -LVRydXN0IEdtYkgxJzAlBgNVBAMMHkQtVFJVU1QgUm9vdCBDbGFzcyAzIENBIDIgMjAwOTCCASIw -DQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBANOySs96R+91myP6Oi/WUEWJNTrGa9v+2wBoqOAD -ER03UAifTUpolDWzU9GUY6cgVq/eUXjsKj3zSEhQPgrfRlWLJ23DEE0NkVJD2IfgXU42tSHKXzlA -BF9bfsyjxiupQB7ZNoTWSPOSHjRGICTBpFGOShrvUD9pXRl/RcPHAY9RySPocq60vFYJfxLLHLGv -KZAKyVXMD9O0Gu1HNVpK7ZxzBCHQqr0ME7UAyiZsxGsMlFqVlNpQmvH/pStmMaTJOKDfHR+4CS7z -p+hnUquVH+BGPtikw8paxTGA6Eian5Rp/hnd2HN8gcqW3o7tszIFZYQ05ub9VxC1X3a/L7AQDcUC -AwEAAaOCARowggEWMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFP3aFMSfMN4hvR5COfyrYyNJ -4PGEMA4GA1UdDwEB/wQEAwIBBjCB0wYDVR0fBIHLMIHIMIGAoH6gfIZ6bGRhcDovL2RpcmVjdG9y -eS5kLXRydXN0Lm5ldC9DTj1ELVRSVVNUJTIwUm9vdCUyMENsYXNzJTIwMyUyMENBJTIwMiUyMDIw -MDksTz1ELVRydXN0JTIwR21iSCxDPURFP2NlcnRpZmljYXRlcmV2b2NhdGlvbmxpc3QwQ6BBoD+G -PWh0dHA6Ly93d3cuZC10cnVzdC5uZXQvY3JsL2QtdHJ1c3Rfcm9vdF9jbGFzc18zX2NhXzJfMjAw -OS5jcmwwDQYJKoZIhvcNAQELBQADggEBAH+X2zDI36ScfSF6gHDOFBJpiBSVYEQBrLLpME+bUMJm -2H6NMLVwMeniacfzcNsgFYbQDfC+rAF1hM5+n02/t2A7nPPKHeJeaNijnZflQGDSNiH+0LS4F9p0 -o3/U37CYAqxva2ssJSRyoWXuJVrl5jLn8t+rSfrzkGkj2wTZ51xY/GXUl77M/C4KzCUqNQT4YJEV -dT1B/yMfGchs64JTBKbkTCJNjYy6zltz7GRUUG3RnFX7acM2w4y8PIWmawomDeCTmGCufsYkl4ph -X5GOZpIJhzbNi5stPvZR1FDUWSi9g/LMKHtThm3YJohw1+qRzT65ysCQblrGXnRl11z+o+I= ------END CERTIFICATE----- - -D-TRUST Root Class 3 CA 2 EV 2009 -================================= ------BEGIN CERTIFICATE----- -MIIEQzCCAyugAwIBAgIDCYP0MA0GCSqGSIb3DQEBCwUAMFAxCzAJBgNVBAYTAkRFMRUwEwYDVQQK -DAxELVRydXN0IEdtYkgxKjAoBgNVBAMMIUQtVFJVU1QgUm9vdCBDbGFzcyAzIENBIDIgRVYgMjAw -OTAeFw0wOTExMDUwODUwNDZaFw0yOTExMDUwODUwNDZaMFAxCzAJBgNVBAYTAkRFMRUwEwYDVQQK -DAxELVRydXN0IEdtYkgxKjAoBgNVBAMMIUQtVFJVU1QgUm9vdCBDbGFzcyAzIENBIDIgRVYgMjAw -OTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAJnxhDRwui+3MKCOvXwEz75ivJn9gpfS -egpnljgJ9hBOlSJzmY3aFS3nBfwZcyK3jpgAvDw9rKFs+9Z5JUut8Mxk2og+KbgPCdM03TP1YtHh -zRnp7hhPTFiu4h7WDFsVWtg6uMQYZB7jM7K1iXdODL/ZlGsTl28So/6ZqQTMFexgaDbtCHu39b+T -7WYxg4zGcTSHThfqr4uRjRxWQa4iN1438h3Z0S0NL2lRp75mpoo6Kr3HGrHhFPC+Oh25z1uxav60 -sUYgovseO3Dvk5h9jHOW8sXvhXCtKSb8HgQ+HKDYD8tSg2J87otTlZCpV6LqYQXY+U3EJ/pure35 -11H3a6UCAwEAAaOCASQwggEgMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFNOUikxiEyoZLsyv -cop9NteaHNxnMA4GA1UdDwEB/wQEAwIBBjCB3QYDVR0fBIHVMIHSMIGHoIGEoIGBhn9sZGFwOi8v -ZGlyZWN0b3J5LmQtdHJ1c3QubmV0L0NOPUQtVFJVU1QlMjBSb290JTIwQ2xhc3MlMjAzJTIwQ0El -MjAyJTIwRVYlMjAyMDA5LE89RC1UcnVzdCUyMEdtYkgsQz1ERT9jZXJ0aWZpY2F0ZXJldm9jYXRp -b25saXN0MEagRKBChkBodHRwOi8vd3d3LmQtdHJ1c3QubmV0L2NybC9kLXRydXN0X3Jvb3RfY2xh -c3NfM19jYV8yX2V2XzIwMDkuY3JsMA0GCSqGSIb3DQEBCwUAA4IBAQA07XtaPKSUiO8aEXUHL7P+ -PPoeUSbrh/Yp3uDx1MYkCenBz1UbtDDZzhr+BlGmFaQt77JLvyAoJUnRpjZ3NOhk31KxEcdzes05 -nsKtjHEh8lprr988TlWvsoRlFIm5d8sqMb7Po23Pb0iUMkZv53GMoKaEGTcH8gNFCSuGdXzfX2lX -ANtu2KZyIktQ1HWYVt+3GP9DQ1CuekR78HlR10M9p9OB0/DJT7naxpeG0ILD5EJt/rDiZE4OJudA -NCa1CInXCGNjOCd1HjPqbqjdn5lPdE2BiYBL3ZqXKVwvvoFBuYz/6n1gBp7N1z3TLqMVvKjmJuVv -w9y4AyHqnxbxLFS1 ------END CERTIFICATE----- - -CA Disig Root R2 -================ ------BEGIN CERTIFICATE----- -MIIFaTCCA1GgAwIBAgIJAJK4iNuwisFjMA0GCSqGSIb3DQEBCwUAMFIxCzAJBgNVBAYTAlNLMRMw -EQYDVQQHEwpCcmF0aXNsYXZhMRMwEQYDVQQKEwpEaXNpZyBhLnMuMRkwFwYDVQQDExBDQSBEaXNp -ZyBSb290IFIyMB4XDTEyMDcxOTA5MTUzMFoXDTQyMDcxOTA5MTUzMFowUjELMAkGA1UEBhMCU0sx -EzARBgNVBAcTCkJyYXRpc2xhdmExEzARBgNVBAoTCkRpc2lnIGEucy4xGTAXBgNVBAMTEENBIERp -c2lnIFJvb3QgUjIwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCio8QACdaFXS1tFPbC -w3OeNcJxVX6B+6tGUODBfEl45qt5WDza/3wcn9iXAng+a0EE6UG9vgMsRfYvZNSrXaNHPWSb6Wia -xswbP7q+sos0Ai6YVRn8jG+qX9pMzk0DIaPY0jSTVpbLTAwAFjxfGs3Ix2ymrdMxp7zo5eFm1tL7 -A7RBZckQrg4FY8aAamkw/dLukO8NJ9+flXP04SXabBbeQTg06ov80egEFGEtQX6sx3dOy1FU+16S -GBsEWmjGycT6txOgmLcRK7fWV8x8nhfRyyX+hk4kLlYMeE2eARKmK6cBZW58Yh2EhN/qwGu1pSqV -g8NTEQxzHQuyRpDRQjrOQG6Vrf/GlK1ul4SOfW+eioANSW1z4nuSHsPzwfPrLgVv2RvPN3YEyLRa -5Beny912H9AZdugsBbPWnDTYltxhh5EF5EQIM8HauQhl1K6yNg3ruji6DOWbnuuNZt2Zz9aJQfYE -koopKW1rOhzndX0CcQ7zwOe9yxndnWCywmZgtrEE7snmhrmaZkCo5xHtgUUDi/ZnWejBBhG93c+A -Ak9lQHhcR1DIm+YfgXvkRKhbhZri3lrVx/k6RGZL5DJUfORsnLMOPReisjQS1n6yqEm70XooQL6i -Fh/f5DcfEXP7kAplQ6INfPgGAVUzfbANuPT1rqVCV3w2EYx7XsQDnYx5nQIDAQABo0IwQDAPBgNV -HRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUtZn4r7CU9eMg1gqtzk5WpC5u -Qu0wDQYJKoZIhvcNAQELBQADggIBACYGXnDnZTPIgm7ZnBc6G3pmsgH2eDtpXi/q/075KMOYKmFM -tCQSin1tERT3nLXK5ryeJ45MGcipvXrA1zYObYVybqjGom32+nNjf7xueQgcnYqfGopTpti72TVV -sRHFqQOzVju5hJMiXn7B9hJSi+osZ7z+Nkz1uM/Rs0mSO9MpDpkblvdhuDvEK7Z4bLQjb/D907Je -dR+Zlais9trhxTF7+9FGs9K8Z7RiVLoJ92Owk6Ka+elSLotgEqv89WBW7xBci8QaQtyDW2QOy7W8 -1k/BfDxujRNt+3vrMNDcTa/F1balTFtxyegxvug4BkihGuLq0t4SOVga/4AOgnXmt8kHbA7v/zjx -mHHEt38OFdAlab0inSvtBfZGR6ztwPDUO+Ls7pZbkBNOHlY667DvlruWIxG68kOGdGSVyCh13x01 -utI3gzhTODY7z2zp+WsO0PsE6E9312UBeIYMej4hYvF/Y3EMyZ9E26gnonW+boE+18DrG5gPcFw0 -sorMwIUY6256s/daoQe/qUKS82Ail+QUoQebTnbAjn39pCXHR+3/H3OszMOl6W8KjptlwlCFtaOg -UxLMVYdh84GuEEZhvUQhuMI9dM9+JDX6HAcOmz0iyu8xL4ysEr3vQCj8KWefshNPZiTEUxnpHikV -7+ZtsH8tZ/3zbBt1RqPlShfppNcL ------END CERTIFICATE----- - -ACCVRAIZ1 -========= ------BEGIN CERTIFICATE----- -MIIH0zCCBbugAwIBAgIIXsO3pkN/pOAwDQYJKoZIhvcNAQEFBQAwQjESMBAGA1UEAwwJQUNDVlJB -SVoxMRAwDgYDVQQLDAdQS0lBQ0NWMQ0wCwYDVQQKDARBQ0NWMQswCQYDVQQGEwJFUzAeFw0xMTA1 -MDUwOTM3MzdaFw0zMDEyMzEwOTM3MzdaMEIxEjAQBgNVBAMMCUFDQ1ZSQUlaMTEQMA4GA1UECwwH -UEtJQUNDVjENMAsGA1UECgwEQUNDVjELMAkGA1UEBhMCRVMwggIiMA0GCSqGSIb3DQEBAQUAA4IC -DwAwggIKAoICAQCbqau/YUqXry+XZpp0X9DZlv3P4uRm7x8fRzPCRKPfmt4ftVTdFXxpNRFvu8gM -jmoYHtiP2Ra8EEg2XPBjs5BaXCQ316PWywlxufEBcoSwfdtNgM3802/J+Nq2DoLSRYWoG2ioPej0 -RGy9ocLLA76MPhMAhN9KSMDjIgro6TenGEyxCQ0jVn8ETdkXhBilyNpAlHPrzg5XPAOBOp0KoVdD -aaxXbXmQeOW1tDvYvEyNKKGno6e6Ak4l0Squ7a4DIrhrIA8wKFSVf+DuzgpmndFALW4ir50awQUZ -0m/A8p/4e7MCQvtQqR0tkw8jq8bBD5L/0KIV9VMJcRz/RROE5iZe+OCIHAr8Fraocwa48GOEAqDG -WuzndN9wrqODJerWx5eHk6fGioozl2A3ED6XPm4pFdahD9GILBKfb6qkxkLrQaLjlUPTAYVtjrs7 -8yM2x/474KElB0iryYl0/wiPgL/AlmXz7uxLaL2diMMxs0Dx6M/2OLuc5NF/1OVYm3z61PMOm3WR -5LpSLhl+0fXNWhn8ugb2+1KoS5kE3fj5tItQo05iifCHJPqDQsGH+tUtKSpacXpkatcnYGMN285J -9Y0fkIkyF/hzQ7jSWpOGYdbhdQrqeWZ2iE9x6wQl1gpaepPluUsXQA+xtrn13k/c4LOsOxFwYIRK -Q26ZIMApcQrAZQIDAQABo4ICyzCCAscwfQYIKwYBBQUHAQEEcTBvMEwGCCsGAQUFBzAChkBodHRw -Oi8vd3d3LmFjY3YuZXMvZmlsZWFkbWluL0FyY2hpdm9zL2NlcnRpZmljYWRvcy9yYWl6YWNjdjEu -Y3J0MB8GCCsGAQUFBzABhhNodHRwOi8vb2NzcC5hY2N2LmVzMB0GA1UdDgQWBBTSh7Tj3zcnk1X2 -VuqB5TbMjB4/vTAPBgNVHRMBAf8EBTADAQH/MB8GA1UdIwQYMBaAFNKHtOPfNyeTVfZW6oHlNsyM -Hj+9MIIBcwYDVR0gBIIBajCCAWYwggFiBgRVHSAAMIIBWDCCASIGCCsGAQUFBwICMIIBFB6CARAA -QQB1AHQAbwByAGkAZABhAGQAIABkAGUAIABDAGUAcgB0AGkAZgBpAGMAYQBjAGkA8wBuACAAUgBh -AO0AegAgAGQAZQAgAGwAYQAgAEEAQwBDAFYAIAAoAEEAZwBlAG4AYwBpAGEAIABkAGUAIABUAGUA -YwBuAG8AbABvAGcA7QBhACAAeQAgAEMAZQByAHQAaQBmAGkAYwBhAGMAaQDzAG4AIABFAGwAZQBj -AHQAcgDzAG4AaQBjAGEALAAgAEMASQBGACAAUQA0ADYAMAAxADEANQA2AEUAKQAuACAAQwBQAFMA -IABlAG4AIABoAHQAdABwADoALwAvAHcAdwB3AC4AYQBjAGMAdgAuAGUAczAwBggrBgEFBQcCARYk -aHR0cDovL3d3dy5hY2N2LmVzL2xlZ2lzbGFjaW9uX2MuaHRtMFUGA1UdHwROMEwwSqBIoEaGRGh0 -dHA6Ly93d3cuYWNjdi5lcy9maWxlYWRtaW4vQXJjaGl2b3MvY2VydGlmaWNhZG9zL3JhaXphY2N2 -MV9kZXIuY3JsMA4GA1UdDwEB/wQEAwIBBjAXBgNVHREEEDAOgQxhY2N2QGFjY3YuZXMwDQYJKoZI -hvcNAQEFBQADggIBAJcxAp/n/UNnSEQU5CmH7UwoZtCPNdpNYbdKl02125DgBS4OxnnQ8pdpD70E -R9m+27Up2pvZrqmZ1dM8MJP1jaGo/AaNRPTKFpV8M9xii6g3+CfYCS0b78gUJyCpZET/LtZ1qmxN -YEAZSUNUY9rizLpm5U9EelvZaoErQNV/+QEnWCzI7UiRfD+mAM/EKXMRNt6GGT6d7hmKG9Ww7Y49 -nCrADdg9ZuM8Db3VlFzi4qc1GwQA9j9ajepDvV+JHanBsMyZ4k0ACtrJJ1vnE5Bc5PUzolVt3OAJ -TS+xJlsndQAJxGJ3KQhfnlmstn6tn1QwIgPBHnFk/vk4CpYY3QIUrCPLBhwepH2NDd4nQeit2hW3 -sCPdK6jT2iWH7ehVRE2I9DZ+hJp4rPcOVkkO1jMl1oRQQmwgEh0q1b688nCBpHBgvgW1m54ERL5h -I6zppSSMEYCUWqKiuUnSwdzRp+0xESyeGabu4VXhwOrPDYTkF7eifKXeVSUG7szAh1xA2syVP1Xg -Nce4hL60Xc16gwFy7ofmXx2utYXGJt/mwZrpHgJHnyqobalbz+xFd3+YJ5oyXSrjhO7FmGYvliAd -3djDJ9ew+f7Zfc3Qn48LFFhRny+Lwzgt3uiP1o2HpPVWQxaZLPSkVrQ0uGE3ycJYgBugl6H8WY3p -EfbRD0tVNEYqi4Y7 ------END CERTIFICATE----- - -TWCA Global Root CA -=================== ------BEGIN CERTIFICATE----- -MIIFQTCCAymgAwIBAgICDL4wDQYJKoZIhvcNAQELBQAwUTELMAkGA1UEBhMCVFcxEjAQBgNVBAoT -CVRBSVdBTi1DQTEQMA4GA1UECxMHUm9vdCBDQTEcMBoGA1UEAxMTVFdDQSBHbG9iYWwgUm9vdCBD -QTAeFw0xMjA2MjcwNjI4MzNaFw0zMDEyMzExNTU5NTlaMFExCzAJBgNVBAYTAlRXMRIwEAYDVQQK -EwlUQUlXQU4tQ0ExEDAOBgNVBAsTB1Jvb3QgQ0ExHDAaBgNVBAMTE1RXQ0EgR2xvYmFsIFJvb3Qg -Q0EwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCwBdvI64zEbooh745NnHEKH1Jw7W2C -nJfF10xORUnLQEK1EjRsGcJ0pDFfhQKX7EMzClPSnIyOt7h52yvVavKOZsTuKwEHktSz0ALfUPZV -r2YOy+BHYC8rMjk1Ujoog/h7FsYYuGLWRyWRzvAZEk2tY/XTP3VfKfChMBwqoJimFb3u/Rk28OKR -Q4/6ytYQJ0lM793B8YVwm8rqqFpD/G2Gb3PpN0Wp8DbHzIh1HrtsBv+baz4X7GGqcXzGHaL3SekV -tTzWoWH1EfcFbx39Eb7QMAfCKbAJTibc46KokWofwpFFiFzlmLhxpRUZyXx1EcxwdE8tmx2RRP1W -KKD+u4ZqyPpcC1jcxkt2yKsi2XMPpfRaAok/T54igu6idFMqPVMnaR1sjjIsZAAmY2E2TqNGtz99 -sy2sbZCilaLOz9qC5wc0GZbpuCGqKX6mOL6OKUohZnkfs8O1CWfe1tQHRvMq2uYiN2DLgbYPoA/p -yJV/v1WRBXrPPRXAb94JlAGD1zQbzECl8LibZ9WYkTunhHiVJqRaCPgrdLQABDzfuBSO6N+pjWxn -kjMdwLfS7JLIvgm/LCkFbwJrnu+8vyq8W8BQj0FwcYeyTbcEqYSjMq+u7msXi7Kx/mzhkIyIqJdI -zshNy/MGz19qCkKxHh53L46g5pIOBvwFItIm4TFRfTLcDwIDAQABoyMwITAOBgNVHQ8BAf8EBAMC -AQYwDwYDVR0TAQH/BAUwAwEB/zANBgkqhkiG9w0BAQsFAAOCAgEAXzSBdu+WHdXltdkCY4QWwa6g -cFGn90xHNcgL1yg9iXHZqjNB6hQbbCEAwGxCGX6faVsgQt+i0trEfJdLjbDorMjupWkEmQqSpqsn -LhpNgb+E1HAerUf+/UqdM+DyucRFCCEK2mlpc3INvjT+lIutwx4116KD7+U4x6WFH6vPNOw/KP4M -8VeGTslV9xzU2KV9Bnpv1d8Q34FOIWWxtuEXeZVFBs5fzNxGiWNoRI2T9GRwoD2dKAXDOXC4Ynsg -/eTb6QihuJ49CcdP+yz4k3ZB3lLg4VfSnQO8d57+nile98FRYB/e2guyLXW3Q0iT5/Z5xoRdgFlg -lPx4mI88k1HtQJAH32RjJMtOcQWh15QaiDLxInQirqWm2BJpTGCjAu4r7NRjkgtevi92a6O2JryP -A9gK8kxkRr05YuWW6zRjESjMlfGt7+/cgFhI6Uu46mWs6fyAtbXIRfmswZ/ZuepiiI7E8UuDEq3m -i4TWnsLrgxifarsbJGAzcMzs9zLzXNl5fe+epP7JI8Mk7hWSsT2RTyaGvWZzJBPqpK5jwa19hAM8 -EHiGG3njxPPyBJUgriOCxLM6AGK/5jYk4Ve6xx6QddVfP5VhK8E7zeWzaGHQRiapIVJpLesux+t3 -zqY6tQMzT3bR51xUAV3LePTJDL/PEo4XLSNolOer/qmyKwbQBM0= ------END CERTIFICATE----- - -TeliaSonera Root CA v1 -====================== ------BEGIN CERTIFICATE----- -MIIFODCCAyCgAwIBAgIRAJW+FqD3LkbxezmCcvqLzZYwDQYJKoZIhvcNAQEFBQAwNzEUMBIGA1UE -CgwLVGVsaWFTb25lcmExHzAdBgNVBAMMFlRlbGlhU29uZXJhIFJvb3QgQ0EgdjEwHhcNMDcxMDE4 -MTIwMDUwWhcNMzIxMDE4MTIwMDUwWjA3MRQwEgYDVQQKDAtUZWxpYVNvbmVyYTEfMB0GA1UEAwwW -VGVsaWFTb25lcmEgUm9vdCBDQSB2MTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAMK+ -6yfwIaPzaSZVfp3FVRaRXP3vIb9TgHot0pGMYzHw7CTww6XScnwQbfQ3t+XmfHnqjLWCi65ItqwA -3GV17CpNX8GH9SBlK4GoRz6JI5UwFpB/6FcHSOcZrr9FZ7E3GwYq/t75rH2D+1665I+XZ75Ljo1k -B1c4VWk0Nj0TSO9P4tNmHqTPGrdeNjPUtAa9GAH9d4RQAEX1jF3oI7x+/jXh7VB7qTCNGdMJjmhn -Xb88lxhTuylixcpecsHHltTbLaC0H2kD7OriUPEMPPCs81Mt8Bz17Ww5OXOAFshSsCPN4D7c3TxH -oLs1iuKYaIu+5b9y7tL6pe0S7fyYGKkmdtwoSxAgHNN/Fnct7W+A90m7UwW7XWjH1Mh1Fj+JWov3 -F0fUTPHSiXk+TT2YqGHeOh7S+F4D4MHJHIzTjU3TlTazN19jY5szFPAtJmtTfImMMsJu7D0hADnJ -oWjiUIMusDor8zagrC/kb2HCUQk5PotTubtn2txTuXZZNp1D5SDgPTJghSJRt8czu90VL6R4pgd7 -gUY2BIbdeTXHlSw7sKMXNeVzH7RcWe/a6hBle3rQf5+ztCo3O3CLm1u5K7fsslESl1MpWtTwEhDc -TwK7EpIvYtQ/aUN8Ddb8WHUBiJ1YFkveupD/RwGJBmr2X7KQarMCpgKIv7NHfirZ1fpoeDVNAgMB -AAGjPzA9MA8GA1UdEwEB/wQFMAMBAf8wCwYDVR0PBAQDAgEGMB0GA1UdDgQWBBTwj1k4ALP1j5qW -DNXr+nuqF+gTEjANBgkqhkiG9w0BAQUFAAOCAgEAvuRcYk4k9AwI//DTDGjkk0kiP0Qnb7tt3oNm -zqjMDfz1mgbldxSR651Be5kqhOX//CHBXfDkH1e3damhXwIm/9fH907eT/j3HEbAek9ALCI18Bmx -0GtnLLCo4MBANzX2hFxc469CeP6nyQ1Q6g2EdvZR74NTxnr/DlZJLo961gzmJ1TjTQpgcmLNkQfW -pb/ImWvtxBnmq0wROMVvMeJuScg/doAmAyYp4Db29iBT4xdwNBedY2gea+zDTYa4EzAvXUYNR0PV -G6pZDrlcjQZIrXSHX8f8MVRBE+LHIQ6e4B4N4cB7Q4WQxYpYxmUKeFfyxiMPAdkgS94P+5KFdSpc -c41teyWRyu5FrgZLAMzTsVlQ2jqIOylDRl6XK1TOU2+NSueW+r9xDkKLfP0ooNBIytrEgUy7onOT -JsjrDNYmiLbAJM+7vVvrdX3pCI6GMyx5dwlppYn8s3CQh3aP0yK7Qs69cwsgJirQmz1wHiRszYd2 -qReWt88NkvuOGKmYSdGe/mBEciG5Ge3C9THxOUiIkCR1VBatzvT4aRRkOfujuLpwQMcnHL/EVlP6 -Y2XQ8xwOFvVrhlhNGNTkDY6lnVuR3HYkUD/GKvvZt5y11ubQ2egZixVxSK236thZiNSQvxaz2ems -WWFUyBy6ysHK4bkgTI86k4mloMy/0/Z1pHWWbVY= ------END CERTIFICATE----- - -E-Tugra Certification Authority -=============================== ------BEGIN CERTIFICATE----- -MIIGSzCCBDOgAwIBAgIIamg+nFGby1MwDQYJKoZIhvcNAQELBQAwgbIxCzAJBgNVBAYTAlRSMQ8w -DQYDVQQHDAZBbmthcmExQDA+BgNVBAoMN0UtVHXEn3JhIEVCRyBCaWxpxZ9pbSBUZWtub2xvamls -ZXJpIHZlIEhpem1ldGxlcmkgQS7Fni4xJjAkBgNVBAsMHUUtVHVncmEgU2VydGlmaWthc3lvbiBN -ZXJrZXppMSgwJgYDVQQDDB9FLVR1Z3JhIENlcnRpZmljYXRpb24gQXV0aG9yaXR5MB4XDTEzMDMw -NTEyMDk0OFoXDTIzMDMwMzEyMDk0OFowgbIxCzAJBgNVBAYTAlRSMQ8wDQYDVQQHDAZBbmthcmEx -QDA+BgNVBAoMN0UtVHXEn3JhIEVCRyBCaWxpxZ9pbSBUZWtub2xvamlsZXJpIHZlIEhpem1ldGxl -cmkgQS7Fni4xJjAkBgNVBAsMHUUtVHVncmEgU2VydGlmaWthc3lvbiBNZXJrZXppMSgwJgYDVQQD -DB9FLVR1Z3JhIENlcnRpZmljYXRpb24gQXV0aG9yaXR5MIICIjANBgkqhkiG9w0BAQEFAAOCAg8A -MIICCgKCAgEA4vU/kwVRHoViVF56C/UYB4Oufq9899SKa6VjQzm5S/fDxmSJPZQuVIBSOTkHS0vd -hQd2h8y/L5VMzH2nPbxHD5hw+IyFHnSOkm0bQNGZDbt1bsipa5rAhDGvykPL6ys06I+XawGb1Q5K -CKpbknSFQ9OArqGIW66z6l7LFpp3RMih9lRozt6Plyu6W0ACDGQXwLWTzeHxE2bODHnv0ZEoq1+g -ElIwcxmOj+GMB6LDu0rw6h8VqO4lzKRG+Bsi77MOQ7osJLjFLFzUHPhdZL3Dk14opz8n8Y4e0ypQ -BaNV2cvnOVPAmJ6MVGKLJrD3fY185MaeZkJVgkfnsliNZvcHfC425lAcP9tDJMW/hkd5s3kc91r0 -E+xs+D/iWR+V7kI+ua2oMoVJl0b+SzGPWsutdEcf6ZG33ygEIqDUD13ieU/qbIWGvaimzuT6w+Gz -rt48Ue7LE3wBf4QOXVGUnhMMti6lTPk5cDZvlsouDERVxcr6XQKj39ZkjFqzAQqptQpHF//vkUAq -jqFGOjGY5RH8zLtJVor8udBhmm9lbObDyz51Sf6Pp+KJxWfXnUYTTjF2OySznhFlhqt/7x3U+Lzn -rFpct1pHXFXOVbQicVtbC/DP3KBhZOqp12gKY6fgDT+gr9Oq0n7vUaDmUStVkhUXU8u3Zg5mTPj5 -dUyQ5xJwx0UCAwEAAaNjMGEwHQYDVR0OBBYEFC7j27JJ0JxUeVz6Jyr+zE7S6E5UMA8GA1UdEwEB -/wQFMAMBAf8wHwYDVR0jBBgwFoAULuPbsknQnFR5XPonKv7MTtLoTlQwDgYDVR0PAQH/BAQDAgEG -MA0GCSqGSIb3DQEBCwUAA4ICAQAFNzr0TbdF4kV1JI+2d1LoHNgQk2Xz8lkGpD4eKexd0dCrfOAK -kEh47U6YA5n+KGCRHTAduGN8qOY1tfrTYXbm1gdLymmasoR6d5NFFxWfJNCYExL/u6Au/U5Mh/jO -XKqYGwXgAEZKgoClM4so3O0409/lPun++1ndYYRP0lSWE2ETPo+Aab6TR7U1Q9Jauz1c77NCR807 -VRMGsAnb/WP2OogKmW9+4c4bU2pEZiNRCHu8W1Ki/QY3OEBhj0qWuJA3+GbHeJAAFS6LrVE1Uweo -a2iu+U48BybNCAVwzDk/dr2l02cmAYamU9JgO3xDf1WKvJUawSg5TB9D0pH0clmKuVb8P7Sd2nCc -dlqMQ1DujjByTd//SffGqWfZbawCEeI6FiWnWAjLb1NBnEg4R2gz0dfHj9R0IdTDBZB6/86WiLEV -KV0jq9BgoRJP3vQXzTLlyb/IQ639Lo7xr+L0mPoSHyDYwKcMhcWQ9DstliaxLL5Mq+ux0orJ23gT -Dx4JnW2PAJ8C2sH6H3p6CcRK5ogql5+Ji/03X186zjhZhkuvcQu02PJwT58yE+Owp1fl2tpDy4Q0 -8ijE6m30Ku/Ba3ba+367hTzSU8JNvnHhRdH9I2cNE3X7z2VnIp2usAnRCf8dNL/+I5c30jn6PQ0G -C7TbO6Orb1wdtn7os4I07QZcJA== ------END CERTIFICATE----- - -T-TeleSec GlobalRoot Class 2 -============================ ------BEGIN CERTIFICATE----- -MIIDwzCCAqugAwIBAgIBATANBgkqhkiG9w0BAQsFADCBgjELMAkGA1UEBhMCREUxKzApBgNVBAoM -IlQtU3lzdGVtcyBFbnRlcnByaXNlIFNlcnZpY2VzIEdtYkgxHzAdBgNVBAsMFlQtU3lzdGVtcyBU -cnVzdCBDZW50ZXIxJTAjBgNVBAMMHFQtVGVsZVNlYyBHbG9iYWxSb290IENsYXNzIDIwHhcNMDgx -MDAxMTA0MDE0WhcNMzMxMDAxMjM1OTU5WjCBgjELMAkGA1UEBhMCREUxKzApBgNVBAoMIlQtU3lz -dGVtcyBFbnRlcnByaXNlIFNlcnZpY2VzIEdtYkgxHzAdBgNVBAsMFlQtU3lzdGVtcyBUcnVzdCBD -ZW50ZXIxJTAjBgNVBAMMHFQtVGVsZVNlYyBHbG9iYWxSb290IENsYXNzIDIwggEiMA0GCSqGSIb3 -DQEBAQUAA4IBDwAwggEKAoIBAQCqX9obX+hzkeXaXPSi5kfl82hVYAUdAqSzm1nzHoqvNK38DcLZ -SBnuaY/JIPwhqgcZ7bBcrGXHX+0CfHt8LRvWurmAwhiCFoT6ZrAIxlQjgeTNuUk/9k9uN0goOA/F -vudocP05l03Sx5iRUKrERLMjfTlH6VJi1hKTXrcxlkIF+3anHqP1wvzpesVsqXFP6st4vGCvx970 -2cu+fjOlbpSD8DT6IavqjnKgP6TeMFvvhk1qlVtDRKgQFRzlAVfFmPHmBiiRqiDFt1MmUUOyCxGV -WOHAD3bZwI18gfNycJ5v/hqO2V81xrJvNHy+SE/iWjnX2J14np+GPgNeGYtEotXHAgMBAAGjQjBA -MA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBS/WSA2AHmgoCJrjNXy -YdK4LMuCSjANBgkqhkiG9w0BAQsFAAOCAQEAMQOiYQsfdOhyNsZt+U2e+iKo4YFWz827n+qrkRk4 -r6p8FU3ztqONpfSO9kSpp+ghla0+AGIWiPACuvxhI+YzmzB6azZie60EI4RYZeLbK4rnJVM3YlNf -vNoBYimipidx5joifsFvHZVwIEoHNN/q/xWA5brXethbdXwFeilHfkCoMRN3zUA7tFFHei4R40cR -3p1m0IvVVGb6g1XqfMIpiRvpb7PO4gWEyS8+eIVibslfwXhjdFjASBgMmTnrpMwatXlajRWc2BQN -9noHV8cigwUtPJslJj0Ys6lDfMjIq2SPDqO/nBudMNva0Bkuqjzx+zOAduTNrRlPBSeOE6Fuwg== ------END CERTIFICATE----- - -Atos TrustedRoot 2011 -===================== ------BEGIN CERTIFICATE----- -MIIDdzCCAl+gAwIBAgIIXDPLYixfszIwDQYJKoZIhvcNAQELBQAwPDEeMBwGA1UEAwwVQXRvcyBU -cnVzdGVkUm9vdCAyMDExMQ0wCwYDVQQKDARBdG9zMQswCQYDVQQGEwJERTAeFw0xMTA3MDcxNDU4 -MzBaFw0zMDEyMzEyMzU5NTlaMDwxHjAcBgNVBAMMFUF0b3MgVHJ1c3RlZFJvb3QgMjAxMTENMAsG -A1UECgwEQXRvczELMAkGA1UEBhMCREUwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCV -hTuXbyo7LjvPpvMpNb7PGKw+qtn4TaA+Gke5vJrf8v7MPkfoepbCJI419KkM/IL9bcFyYie96mvr -54rMVD6QUM+A1JX76LWC1BTFtqlVJVfbsVD2sGBkWXppzwO3bw2+yj5vdHLqqjAqc2K+SZFhyBH+ -DgMq92og3AIVDV4VavzjgsG1xZ1kCWyjWZgHJ8cblithdHFsQ/H3NYkQ4J7sVaE3IqKHBAUsR320 -HLliKWYoyrfhk/WklAOZuXCFteZI6o1Q/NnezG8HDt0Lcp2AMBYHlT8oDv3FdU9T1nSatCQujgKR -z3bFmx5VdJx4IbHwLfELn8LVlhgf8FQieowHAgMBAAGjfTB7MB0GA1UdDgQWBBSnpQaxLKYJYO7R -l+lwrrw7GWzbITAPBgNVHRMBAf8EBTADAQH/MB8GA1UdIwQYMBaAFKelBrEspglg7tGX6XCuvDsZ -bNshMBgGA1UdIAQRMA8wDQYLKwYBBAGwLQMEAQEwDgYDVR0PAQH/BAQDAgGGMA0GCSqGSIb3DQEB -CwUAA4IBAQAmdzTblEiGKkGdLD4GkGDEjKwLVLgfuXvTBznk+j57sj1O7Z8jvZfza1zv7v1Apt+h -k6EKhqzvINB5Ab149xnYJDE0BAGmuhWawyfc2E8PzBhj/5kPDpFrdRbhIfzYJsdHt6bPWHJxfrrh -TZVHO8mvbaG0weyJ9rQPOLXiZNwlz6bb65pcmaHFCN795trV1lpFDMS3wrUU77QR/w4VtfX128a9 -61qn8FYiqTxlVMYVqL2Gns2Dlmh6cYGJ4Qvh6hEbaAjMaZ7snkGeRDImeuKHCnE96+RapNLbxc3G -3mB/ufNPRJLvKrcYPqcZ2Qt9sTdBQrC6YB3y/gkRsPCHe6ed ------END CERTIFICATE----- - -QuoVadis Root CA 1 G3 -===================== ------BEGIN CERTIFICATE----- -MIIFYDCCA0igAwIBAgIUeFhfLq0sGUvjNwc1NBMotZbUZZMwDQYJKoZIhvcNAQELBQAwSDELMAkG -A1UEBhMCQk0xGTAXBgNVBAoTEFF1b1ZhZGlzIExpbWl0ZWQxHjAcBgNVBAMTFVF1b1ZhZGlzIFJv -b3QgQ0EgMSBHMzAeFw0xMjAxMTIxNzI3NDRaFw00MjAxMTIxNzI3NDRaMEgxCzAJBgNVBAYTAkJN -MRkwFwYDVQQKExBRdW9WYWRpcyBMaW1pdGVkMR4wHAYDVQQDExVRdW9WYWRpcyBSb290IENBIDEg -RzMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCgvlAQjunybEC0BJyFuTHK3C3kEakE -PBtVwedYMB0ktMPvhd6MLOHBPd+C5k+tR4ds7FtJwUrVu4/sh6x/gpqG7D0DmVIB0jWerNrwU8lm -PNSsAgHaJNM7qAJGr6Qc4/hzWHa39g6QDbXwz8z6+cZM5cOGMAqNF34168Xfuw6cwI2H44g4hWf6 -Pser4BOcBRiYz5P1sZK0/CPTz9XEJ0ngnjybCKOLXSoh4Pw5qlPafX7PGglTvF0FBM+hSo+LdoIN -ofjSxxR3W5A2B4GbPgb6Ul5jxaYA/qXpUhtStZI5cgMJYr2wYBZupt0lwgNm3fME0UDiTouG9G/l -g6AnhF4EwfWQvTA9xO+oabw4m6SkltFi2mnAAZauy8RRNOoMqv8hjlmPSlzkYZqn0ukqeI1RPToV -7qJZjqlc3sX5kCLliEVx3ZGZbHqfPT2YfF72vhZooF6uCyP8Wg+qInYtyaEQHeTTRCOQiJ/GKubX -9ZqzWB4vMIkIG1SitZgj7Ah3HJVdYdHLiZxfokqRmu8hqkkWCKi9YSgxyXSthfbZxbGL0eUQMk1f -iyA6PEkfM4VZDdvLCXVDaXP7a3F98N/ETH3Goy7IlXnLc6KOTk0k+17kBL5yG6YnLUlamXrXXAkg -t3+UuU/xDRxeiEIbEbfnkduebPRq34wGmAOtzCjvpUfzUwIDAQABo0IwQDAPBgNVHRMBAf8EBTAD -AQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUo5fW816iEOGrRZ88F2Q87gFwnMwwDQYJKoZI -hvcNAQELBQADggIBABj6W3X8PnrHX3fHyt/PX8MSxEBd1DKquGrX1RUVRpgjpeaQWxiZTOOtQqOC -MTaIzen7xASWSIsBx40Bz1szBpZGZnQdT+3Btrm0DWHMY37XLneMlhwqI2hrhVd2cDMT/uFPpiN3 -GPoajOi9ZcnPP/TJF9zrx7zABC4tRi9pZsMbj/7sPtPKlL92CiUNqXsCHKnQO18LwIE6PWThv6ct -Tr1NxNgpxiIY0MWscgKCP6o6ojoilzHdCGPDdRS5YCgtW2jgFqlmgiNR9etT2DGbe+m3nUvriBbP -+V04ikkwj+3x6xn0dxoxGE1nVGwvb2X52z3sIexe9PSLymBlVNFxZPT5pqOBMzYzcfCkeF9OrYMh -3jRJjehZrJ3ydlo28hP0r+AJx2EqbPfgna67hkooby7utHnNkDPDs3b69fBsnQGQ+p6Q9pxyz0fa -wx/kNSBT8lTR32GDpgLiJTjehTItXnOQUl1CxM49S+H5GYQd1aJQzEH7QRTDvdbJWqNjZgKAvQU6 -O0ec7AAmTPWIUb+oI38YB7AL7YsmoWTTYUrrXJ/es69nA7Mf3W1daWhpq1467HxpvMc7hU6eFbm0 -FU/DlXpY18ls6Wy58yljXrQs8C097Vpl4KlbQMJImYFtnh8GKjwStIsPm6Ik8KaN1nrgS7ZklmOV -hMJKzRwuJIczYOXD ------END CERTIFICATE----- - -QuoVadis Root CA 2 G3 -===================== ------BEGIN CERTIFICATE----- -MIIFYDCCA0igAwIBAgIURFc0JFuBiZs18s64KztbpybwdSgwDQYJKoZIhvcNAQELBQAwSDELMAkG -A1UEBhMCQk0xGTAXBgNVBAoTEFF1b1ZhZGlzIExpbWl0ZWQxHjAcBgNVBAMTFVF1b1ZhZGlzIFJv -b3QgQ0EgMiBHMzAeFw0xMjAxMTIxODU5MzJaFw00MjAxMTIxODU5MzJaMEgxCzAJBgNVBAYTAkJN -MRkwFwYDVQQKExBRdW9WYWRpcyBMaW1pdGVkMR4wHAYDVQQDExVRdW9WYWRpcyBSb290IENBIDIg -RzMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQChriWyARjcV4g/Ruv5r+LrI3HimtFh -ZiFfqq8nUeVuGxbULX1QsFN3vXg6YOJkApt8hpvWGo6t/x8Vf9WVHhLL5hSEBMHfNrMWn4rjyduY -NM7YMxcoRvynyfDStNVNCXJJ+fKH46nafaF9a7I6JaltUkSs+L5u+9ymc5GQYaYDFCDy54ejiK2t -oIz/pgslUiXnFgHVy7g1gQyjO/Dh4fxaXc6AcW34Sas+O7q414AB+6XrW7PFXmAqMaCvN+ggOp+o -MiwMzAkd056OXbxMmO7FGmh77FOm6RQ1o9/NgJ8MSPsc9PG/Srj61YxxSscfrf5BmrODXfKEVu+l -V0POKa2Mq1W/xPtbAd0jIaFYAI7D0GoT7RPjEiuA3GfmlbLNHiJuKvhB1PLKFAeNilUSxmn1uIZo -L1NesNKqIcGY5jDjZ1XHm26sGahVpkUG0CM62+tlXSoREfA7T8pt9DTEceT/AFr2XK4jYIVz8eQQ -sSWu1ZK7E8EM4DnatDlXtas1qnIhO4M15zHfeiFuuDIIfR0ykRVKYnLP43ehvNURG3YBZwjgQQvD -6xVu+KQZ2aKrr+InUlYrAoosFCT5v0ICvybIxo/gbjh9Uy3l7ZizlWNof/k19N+IxWA1ksB8aRxh -lRbQ694Lrz4EEEVlWFA4r0jyWbYW8jwNkALGcC4BrTwV1wIDAQABo0IwQDAPBgNVHRMBAf8EBTAD -AQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQU7edvdlq/YOxJW8ald7tyFnGbxD0wDQYJKoZI -hvcNAQELBQADggIBAJHfgD9DCX5xwvfrs4iP4VGyvD11+ShdyLyZm3tdquXK4Qr36LLTn91nMX66 -AarHakE7kNQIXLJgapDwyM4DYvmL7ftuKtwGTTwpD4kWilhMSA/ohGHqPHKmd+RCroijQ1h5fq7K -pVMNqT1wvSAZYaRsOPxDMuHBR//47PERIjKWnML2W2mWeyAMQ0GaW/ZZGYjeVYg3UQt4XAoeo0L9 -x52ID8DyeAIkVJOviYeIyUqAHerQbj5hLja7NQ4nlv1mNDthcnPxFlxHBlRJAHpYErAK74X9sbgz -dWqTHBLmYF5vHX/JHyPLhGGfHoJE+V+tYlUkmlKY7VHnoX6XOuYvHxHaU4AshZ6rNRDbIl9qxV6X -U/IyAgkwo1jwDQHVcsaxfGl7w/U2Rcxhbl5MlMVerugOXou/983g7aEOGzPuVBj+D77vfoRrQ+Nw -mNtddbINWQeFFSM51vHfqSYP1kjHs6Yi9TM3WpVHn3u6GBVv/9YUZINJ0gpnIdsPNWNgKCLjsZWD -zYWm3S8P52dSbrsvhXz1SnPnxT7AvSESBT/8twNJAlvIJebiVDj1eYeMHVOyToV7BjjHLPj4sHKN -JeV3UvQDHEimUF+IIDBu8oJDqz2XhOdT+yHBTw8imoa4WSr2Rz0ZiC3oheGe7IUIarFsNMkd7Egr -O3jtZsSOeWmD3n+M ------END CERTIFICATE----- - -QuoVadis Root CA 3 G3 -===================== ------BEGIN CERTIFICATE----- -MIIFYDCCA0igAwIBAgIULvWbAiin23r/1aOp7r0DoM8Sah0wDQYJKoZIhvcNAQELBQAwSDELMAkG -A1UEBhMCQk0xGTAXBgNVBAoTEFF1b1ZhZGlzIExpbWl0ZWQxHjAcBgNVBAMTFVF1b1ZhZGlzIFJv -b3QgQ0EgMyBHMzAeFw0xMjAxMTIyMDI2MzJaFw00MjAxMTIyMDI2MzJaMEgxCzAJBgNVBAYTAkJN -MRkwFwYDVQQKExBRdW9WYWRpcyBMaW1pdGVkMR4wHAYDVQQDExVRdW9WYWRpcyBSb290IENBIDMg -RzMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCzyw4QZ47qFJenMioKVjZ/aEzHs286 -IxSR/xl/pcqs7rN2nXrpixurazHb+gtTTK/FpRp5PIpM/6zfJd5O2YIyC0TeytuMrKNuFoM7pmRL -Mon7FhY4futD4tN0SsJiCnMK3UmzV9KwCoWdcTzeo8vAMvMBOSBDGzXRU7Ox7sWTaYI+FrUoRqHe -6okJ7UO4BUaKhvVZR74bbwEhELn9qdIoyhA5CcoTNs+cra1AdHkrAj80//ogaX3T7mH1urPnMNA3 -I4ZyYUUpSFlob3emLoG+B01vr87ERRORFHAGjx+f+IdpsQ7vw4kZ6+ocYfx6bIrc1gMLnia6Et3U -VDmrJqMz6nWB2i3ND0/kA9HvFZcba5DFApCTZgIhsUfei5pKgLlVj7WiL8DWM2fafsSntARE60f7 -5li59wzweyuxwHApw0BiLTtIadwjPEjrewl5qW3aqDCYz4ByA4imW0aucnl8CAMhZa634RylsSqi -Md5mBPfAdOhx3v89WcyWJhKLhZVXGqtrdQtEPREoPHtht+KPZ0/l7DxMYIBpVzgeAVuNVejH38DM -dyM0SXV89pgR6y3e7UEuFAUCf+D+IOs15xGsIs5XPd7JMG0QA4XN8f+MFrXBsj6IbGB/kE+V9/Yt -rQE5BwT6dYB9v0lQ7e/JxHwc64B+27bQ3RP+ydOc17KXqQIDAQABo0IwQDAPBgNVHRMBAf8EBTAD -AQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUxhfQvKjqAkPyGwaZXSuQILnXnOQwDQYJKoZI -hvcNAQELBQADggIBADRh2Va1EodVTd2jNTFGu6QHcrxfYWLopfsLN7E8trP6KZ1/AvWkyaiTt3px -KGmPc+FSkNrVvjrlt3ZqVoAh313m6Tqe5T72omnHKgqwGEfcIHB9UqM+WXzBusnIFUBhynLWcKzS -t/Ac5IYp8M7vaGPQtSCKFWGafoaYtMnCdvvMujAWzKNhxnQT5WvvoxXqA/4Ti2Tk08HS6IT7SdEQ -TXlm66r99I0xHnAUrdzeZxNMgRVhvLfZkXdxGYFgu/BYpbWcC/ePIlUnwEsBbTuZDdQdm2NnL9Du -DcpmvJRPpq3t/O5jrFc/ZSXPsoaP0Aj/uHYUbt7lJ+yreLVTubY/6CD50qi+YUbKh4yE8/nxoGib -Ih6BJpsQBJFxwAYf3KDTuVan45gtf4Od34wrnDKOMpTwATwiKp9Dwi7DmDkHOHv8XgBCH/MyJnmD -hPbl8MFREsALHgQjDFSlTC9JxUrRtm5gDWv8a4uFJGS3iQ6rJUdbPM9+Sb3H6QrG2vd+DhcI00iX -0HGS8A85PjRqHH3Y8iKuu2n0M7SmSFXRDw4m6Oy2Cy2nhTXN/VnIn9HNPlopNLk9hM6xZdRZkZFW -dSHBd575euFgndOtBBj0fOtek49TSiIp+EgrPk2GrFt/ywaZWWDYWGWVjUTR939+J399roD1B0y2 -PpxxVJkES/1Y+Zj0 ------END CERTIFICATE----- - -DigiCert Assured ID Root G2 -=========================== ------BEGIN CERTIFICATE----- -MIIDljCCAn6gAwIBAgIQC5McOtY5Z+pnI7/Dr5r0SzANBgkqhkiG9w0BAQsFADBlMQswCQYDVQQG -EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSQw -IgYDVQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgRzIwHhcNMTMwODAxMTIwMDAwWhcNMzgw -MTE1MTIwMDAwWjBlMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQL -ExB3d3cuZGlnaWNlcnQuY29tMSQwIgYDVQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgRzIw -ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDZ5ygvUj82ckmIkzTz+GoeMVSAn61UQbVH -35ao1K+ALbkKz3X9iaV9JPrjIgwrvJUXCzO/GU1BBpAAvQxNEP4HteccbiJVMWWXvdMX0h5i89vq -bFCMP4QMls+3ywPgym2hFEwbid3tALBSfK+RbLE4E9HpEgjAALAcKxHad3A2m67OeYfcgnDmCXRw -VWmvo2ifv922ebPynXApVfSr/5Vh88lAbx3RvpO704gqu52/clpWcTs/1PPRCv4o76Pu2ZmvA9OP -YLfykqGxvYmJHzDNw6YuYjOuFgJ3RFrngQo8p0Quebg/BLxcoIfhG69Rjs3sLPr4/m3wOnyqi+Rn -lTGNAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMB0GA1UdDgQWBBTO -w0q5mVXyuNtgv6l+vVa1lzan1jANBgkqhkiG9w0BAQsFAAOCAQEAyqVVjOPIQW5pJ6d1Ee88hjZv -0p3GeDgdaZaikmkuOGybfQTUiaWxMTeKySHMq2zNixya1r9I0jJmwYrA8y8678Dj1JGG0VDjA9tz -d29KOVPt3ibHtX2vK0LRdWLjSisCx1BL4GnilmwORGYQRI+tBev4eaymG+g3NJ1TyWGqolKvSnAW -hsI6yLETcDbYz+70CjTVW0z9B5yiutkBclzzTcHdDrEcDcRjvq30FPuJ7KJBDkzMyFdA0G4Dqs0M -jomZmWzwPDCvON9vvKO+KSAnq3T/EyJ43pdSVR6DtVQgA+6uwE9W3jfMw3+qBCe703e4YtsXfJwo -IhNzbM8m9Yop5w== ------END CERTIFICATE----- - -DigiCert Assured ID Root G3 -=========================== ------BEGIN CERTIFICATE----- -MIICRjCCAc2gAwIBAgIQC6Fa+h3foLVJRK/NJKBs7DAKBggqhkjOPQQDAzBlMQswCQYDVQQGEwJV -UzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSQwIgYD -VQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgRzMwHhcNMTMwODAxMTIwMDAwWhcNMzgwMTE1 -MTIwMDAwWjBlMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3 -d3cuZGlnaWNlcnQuY29tMSQwIgYDVQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgRzMwdjAQ -BgcqhkjOPQIBBgUrgQQAIgNiAAQZ57ysRGXtzbg/WPuNsVepRC0FFfLvC/8QdJ+1YlJfZn4f5dwb -RXkLzMZTCp2NXQLZqVneAlr2lSoOjThKiknGvMYDOAdfVdp+CW7if17QRSAPWXYQ1qAk8C3eNvJs -KTmjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMB0GA1UdDgQWBBTL0L2p4ZgF -UaFNN6KDec6NHSrkhDAKBggqhkjOPQQDAwNnADBkAjAlpIFFAmsSS3V0T8gj43DydXLefInwz5Fy -YZ5eEJJZVrmDxxDnOOlYJjZ91eQ0hjkCMHw2U/Aw5WJjOpnitqM7mzT6HtoQknFekROn3aRukswy -1vUhZscv6pZjamVFkpUBtA== ------END CERTIFICATE----- - -DigiCert Global Root G2 -======================= ------BEGIN CERTIFICATE----- -MIIDjjCCAnagAwIBAgIQAzrx5qcRqaC7KGSxHQn65TANBgkqhkiG9w0BAQsFADBhMQswCQYDVQQG -EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSAw -HgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBHMjAeFw0xMzA4MDExMjAwMDBaFw0zODAxMTUx -MjAwMDBaMGExCzAJBgNVBAYTAlVTMRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3 -dy5kaWdpY2VydC5jb20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IEcyMIIBIjANBgkq -hkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuzfNNNx7a8myaJCtSnX/RrohCgiN9RlUyfuI2/Ou8jqJ -kTx65qsGGmvPrC3oXgkkRLpimn7Wo6h+4FR1IAWsULecYxpsMNzaHxmx1x7e/dfgy5SDN67sH0NO -3Xss0r0upS/kqbitOtSZpLYl6ZtrAGCSYP9PIUkY92eQq2EGnI/yuum06ZIya7XzV+hdG82MHauV -BJVJ8zUtluNJbd134/tJS7SsVQepj5WztCO7TG1F8PapspUwtP1MVYwnSlcUfIKdzXOS0xZKBgyM -UNGPHgm+F6HmIcr9g+UQvIOlCsRnKPZzFBQ9RnbDhxSJITRNrw9FDKZJobq7nMWxM4MphQIDAQAB -o0IwQDAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBhjAdBgNVHQ4EFgQUTiJUIBiV5uNu -5g/6+rkS7QYXjzkwDQYJKoZIhvcNAQELBQADggEBAGBnKJRvDkhj6zHd6mcY1Yl9PMWLSn/pvtsr -F9+wX3N3KjITOYFnQoQj8kVnNeyIv/iPsGEMNKSuIEyExtv4NeF22d+mQrvHRAiGfzZ0JFrabA0U -WTW98kndth/Jsw1HKj2ZL7tcu7XUIOGZX1NGFdtom/DzMNU+MeKNhJ7jitralj41E6Vf8PlwUHBH -QRFXGU7Aj64GxJUTFy8bJZ918rGOmaFvE7FBcf6IKshPECBV1/MUReXgRPTqh5Uykw7+U0b6LJ3/ -iyK5S9kJRaTepLiaWN0bfVKfjllDiIGknibVb63dDcY3fe0Dkhvld1927jyNxF1WW6LZZm6zNTfl -MrY= ------END CERTIFICATE----- - -DigiCert Global Root G3 -======================= ------BEGIN CERTIFICATE----- -MIICPzCCAcWgAwIBAgIQBVVWvPJepDU1w6QP1atFcjAKBggqhkjOPQQDAzBhMQswCQYDVQQGEwJV -UzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSAwHgYD -VQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBHMzAeFw0xMzA4MDExMjAwMDBaFw0zODAxMTUxMjAw -MDBaMGExCzAJBgNVBAYTAlVTMRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5k -aWdpY2VydC5jb20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IEczMHYwEAYHKoZIzj0C -AQYFK4EEACIDYgAE3afZu4q4C/sLfyHS8L6+c/MzXRq8NOrexpu80JX28MzQC7phW1FGfp4tn+6O -YwwX7Adw9c+ELkCDnOg/QW07rdOkFFk2eJ0DQ+4QE2xy3q6Ip6FrtUPOZ9wj/wMco+I+o0IwQDAP -BgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBhjAdBgNVHQ4EFgQUs9tIpPmhxdiuNkHMEWNp -Yim8S8YwCgYIKoZIzj0EAwMDaAAwZQIxAK288mw/EkrRLTnDCgmXc/SINoyIJ7vmiI1Qhadj+Z4y -3maTD/HMsQmP3Wyr+mt/oAIwOWZbwmSNuJ5Q3KjVSaLtx9zRSX8XAbjIho9OjIgrqJqpisXRAL34 -VOKa5Vt8sycX ------END CERTIFICATE----- - -DigiCert Trusted Root G4 -======================== ------BEGIN CERTIFICATE----- -MIIFkDCCA3igAwIBAgIQBZsbV56OITLiOQe9p3d1XDANBgkqhkiG9w0BAQwFADBiMQswCQYDVQQG -EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSEw -HwYDVQQDExhEaWdpQ2VydCBUcnVzdGVkIFJvb3QgRzQwHhcNMTMwODAxMTIwMDAwWhcNMzgwMTE1 -MTIwMDAwWjBiMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3 -d3cuZGlnaWNlcnQuY29tMSEwHwYDVQQDExhEaWdpQ2VydCBUcnVzdGVkIFJvb3QgRzQwggIiMA0G -CSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC/5pBzaN675F1KPDAiMGkz7MKnJS7JIT3yithZwuEp -pz1Yq3aaza57G4QNxDAf8xukOBbrVsaXbR2rsnnyyhHS5F/WBTxSD1Ifxp4VpX6+n6lXFllVcq9o -k3DCsrp1mWpzMpTREEQQLt+C8weE5nQ7bXHiLQwb7iDVySAdYyktzuxeTsiT+CFhmzTrBcZe7Fsa -vOvJz82sNEBfsXpm7nfISKhmV1efVFiODCu3T6cw2Vbuyntd463JT17lNecxy9qTXtyOj4DatpGY -QJB5w3jHtrHEtWoYOAMQjdjUN6QuBX2I9YI+EJFwq1WCQTLX2wRzKm6RAXwhTNS8rhsDdV14Ztk6 -MUSaM0C/CNdaSaTC5qmgZ92kJ7yhTzm1EVgX9yRcRo9k98FpiHaYdj1ZXUJ2h4mXaXpI8OCiEhtm -mnTK3kse5w5jrubU75KSOp493ADkRSWJtppEGSt+wJS00mFt6zPZxd9LBADMfRyVw4/3IbKyEbe7 -f/LVjHAsQWCqsWMYRJUadmJ+9oCw++hkpjPRiQfhvbfmQ6QYuKZ3AeEPlAwhHbJUKSWJbOUOUlFH -dL4mrLZBdd56rF+NP8m800ERElvlEFDrMcXKchYiCd98THU/Y+whX8QgUWtvsauGi0/C1kVfnSD8 -oR7FwI+isX4KJpn15GkvmB0t9dmpsh3lGwIDAQABo0IwQDAPBgNVHRMBAf8EBTADAQH/MA4GA1Ud -DwEB/wQEAwIBhjAdBgNVHQ4EFgQU7NfjgtJxXWRM3y5nP+e6mK4cD08wDQYJKoZIhvcNAQEMBQAD -ggIBALth2X2pbL4XxJEbw6GiAI3jZGgPVs93rnD5/ZpKmbnJeFwMDF/k5hQpVgs2SV1EY+CtnJYY -ZhsjDT156W1r1lT40jzBQ0CuHVD1UvyQO7uYmWlrx8GnqGikJ9yd+SeuMIW59mdNOj6PWTkiU0Tr -yF0Dyu1Qen1iIQqAyHNm0aAFYF/opbSnr6j3bTWcfFqK1qI4mfN4i/RN0iAL3gTujJtHgXINwBQy -7zBZLq7gcfJW5GqXb5JQbZaNaHqasjYUegbyJLkJEVDXCLG4iXqEI2FCKeWjzaIgQdfRnGTZ6iah -ixTXTBmyUEFxPT9NcCOGDErcgdLMMpSEDQgJlxxPwO5rIHQw0uA5NBCFIRUBCOhVMt5xSdkoF1BN -5r5N0XWs0Mr7QbhDparTwwVETyw2m+L64kW4I1NsBm9nVX9GtUw/bihaeSbSpKhil9Ie4u1Ki7wb -/UdKDd9nZn6yW0HQO+T0O/QEY+nvwlQAUaCKKsnOeMzV6ocEGLPOr0mIr/OSmbaz5mEP0oUA51Aa -5BuVnRmhuZyxm7EAHu/QD09CbMkKvO5D+jpxpchNJqU1/YldvIViHTLSoCtU7ZpXwdv6EM8Zt4tK -G48BtieVU+i2iW1bvGjUI+iLUaJW+fCmgKDWHrO8Dw9TdSmq6hN35N6MgSGtBxBHEa2HPQfRdbzP -82Z+ ------END CERTIFICATE----- - -COMODO RSA Certification Authority -================================== ------BEGIN CERTIFICATE----- -MIIF2DCCA8CgAwIBAgIQTKr5yttjb+Af907YWwOGnTANBgkqhkiG9w0BAQwFADCBhTELMAkGA1UE -BhMCR0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgG -A1UEChMRQ09NT0RPIENBIExpbWl0ZWQxKzApBgNVBAMTIkNPTU9ETyBSU0EgQ2VydGlmaWNhdGlv -biBBdXRob3JpdHkwHhcNMTAwMTE5MDAwMDAwWhcNMzgwMTE4MjM1OTU5WjCBhTELMAkGA1UEBhMC -R0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgGA1UE -ChMRQ09NT0RPIENBIExpbWl0ZWQxKzApBgNVBAMTIkNPTU9ETyBSU0EgQ2VydGlmaWNhdGlvbiBB -dXRob3JpdHkwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCR6FSS0gpWsawNJN3Fz0Rn -dJkrN6N9I3AAcbxT38T6KhKPS38QVr2fcHK3YX/JSw8Xpz3jsARh7v8Rl8f0hj4K+j5c+ZPmNHrZ -FGvnnLOFoIJ6dq9xkNfs/Q36nGz637CC9BR++b7Epi9Pf5l/tfxnQ3K9DADWietrLNPtj5gcFKt+ -5eNu/Nio5JIk2kNrYrhV/erBvGy2i/MOjZrkm2xpmfh4SDBF1a3hDTxFYPwyllEnvGfDyi62a+pG -x8cgoLEfZd5ICLqkTqnyg0Y3hOvozIFIQ2dOciqbXL1MGyiKXCJ7tKuY2e7gUYPDCUZObT6Z+pUX -2nwzV0E8jVHtC7ZcryxjGt9XyD+86V3Em69FmeKjWiS0uqlWPc9vqv9JWL7wqP/0uK3pN/u6uPQL -OvnoQ0IeidiEyxPx2bvhiWC4jChWrBQdnArncevPDt09qZahSL0896+1DSJMwBGB7FY79tOi4lu3 -sgQiUpWAk2nojkxl8ZEDLXB0AuqLZxUpaVICu9ffUGpVRr+goyhhf3DQw6KqLCGqR84onAZFdr+C -GCe01a60y1Dma/RMhnEw6abfFobg2P9A3fvQQoh/ozM6LlweQRGBY84YcWsr7KaKtzFcOmpH4MN5 -WdYgGq/yapiqcrxXStJLnbsQ/LBMQeXtHT1eKJ2czL+zUdqnR+WEUwIDAQABo0IwQDAdBgNVHQ4E -FgQUu69+Aj36pvE8hI6t7jiY7NkyMtQwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8w -DQYJKoZIhvcNAQEMBQADggIBAArx1UaEt65Ru2yyTUEUAJNMnMvlwFTPoCWOAvn9sKIN9SCYPBMt -rFaisNZ+EZLpLrqeLppysb0ZRGxhNaKatBYSaVqM4dc+pBroLwP0rmEdEBsqpIt6xf4FpuHA1sj+ -nq6PK7o9mfjYcwlYRm6mnPTXJ9OV2jeDchzTc+CiR5kDOF3VSXkAKRzH7JsgHAckaVd4sjn8OoSg -tZx8jb8uk2IntznaFxiuvTwJaP+EmzzV1gsD41eeFPfR60/IvYcjt7ZJQ3mFXLrrkguhxuhoqEwW -sRqZCuhTLJK7oQkYdQxlqHvLI7cawiiFwxv/0Cti76R7CZGYZ4wUAc1oBmpjIXUDgIiKboHGhfKp -pC3n9KUkEEeDys30jXlYsQab5xoq2Z0B15R97QNKyvDb6KkBPvVWmckejkk9u+UJueBPSZI9FoJA -zMxZxuY67RIuaTxslbH9qh17f4a+Hg4yRvv7E491f0yLS0Zj/gA0QHDBw7mh3aZw4gSzQbzpgJHq -ZJx64SIDqZxubw5lT2yHh17zbqD5daWbQOhTsiedSrnAdyGN/4fy3ryM7xfft0kL0fJuMAsaDk52 -7RH89elWsn2/x20Kk4yl0MC2Hb46TpSi125sC8KKfPog88Tk5c0NqMuRkrF8hey1FGlmDoLnzc7I -LaZRfyHBNVOFBkpdn627G190 ------END CERTIFICATE----- - -USERTrust RSA Certification Authority -===================================== ------BEGIN CERTIFICATE----- -MIIF3jCCA8agAwIBAgIQAf1tMPyjylGoG7xkDjUDLTANBgkqhkiG9w0BAQwFADCBiDELMAkGA1UE -BhMCVVMxEzARBgNVBAgTCk5ldyBKZXJzZXkxFDASBgNVBAcTC0plcnNleSBDaXR5MR4wHAYDVQQK -ExVUaGUgVVNFUlRSVVNUIE5ldHdvcmsxLjAsBgNVBAMTJVVTRVJUcnVzdCBSU0EgQ2VydGlmaWNh -dGlvbiBBdXRob3JpdHkwHhcNMTAwMjAxMDAwMDAwWhcNMzgwMTE4MjM1OTU5WjCBiDELMAkGA1UE -BhMCVVMxEzARBgNVBAgTCk5ldyBKZXJzZXkxFDASBgNVBAcTC0plcnNleSBDaXR5MR4wHAYDVQQK -ExVUaGUgVVNFUlRSVVNUIE5ldHdvcmsxLjAsBgNVBAMTJVVTRVJUcnVzdCBSU0EgQ2VydGlmaWNh -dGlvbiBBdXRob3JpdHkwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCAEmUXNg7D2wiz -0KxXDXbtzSfTTK1Qg2HiqiBNCS1kCdzOiZ/MPans9s/B3PHTsdZ7NygRK0faOca8Ohm0X6a9fZ2j -Y0K2dvKpOyuR+OJv0OwWIJAJPuLodMkYtJHUYmTbf6MG8YgYapAiPLz+E/CHFHv25B+O1ORRxhFn -RghRy4YUVD+8M/5+bJz/Fp0YvVGONaanZshyZ9shZrHUm3gDwFA66Mzw3LyeTP6vBZY1H1dat//O -+T23LLb2VN3I5xI6Ta5MirdcmrS3ID3KfyI0rn47aGYBROcBTkZTmzNg95S+UzeQc0PzMsNT79uq -/nROacdrjGCT3sTHDN/hMq7MkztReJVni+49Vv4M0GkPGw/zJSZrM233bkf6c0Plfg6lZrEpfDKE -Y1WJxA3Bk1QwGROs0303p+tdOmw1XNtB1xLaqUkL39iAigmTYo61Zs8liM2EuLE/pDkP2QKe6xJM -lXzzawWpXhaDzLhn4ugTncxbgtNMs+1b/97lc6wjOy0AvzVVdAlJ2ElYGn+SNuZRkg7zJn0cTRe8 -yexDJtC/QV9AqURE9JnnV4eeUB9XVKg+/XRjL7FQZQnmWEIuQxpMtPAlR1n6BB6T1CZGSlCBst6+ -eLf8ZxXhyVeEHg9j1uliutZfVS7qXMYoCAQlObgOK6nyTJccBz8NUvXt7y+CDwIDAQABo0IwQDAd -BgNVHQ4EFgQUU3m/WqorSs9UgOHYm8Cd8rIDZsswDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQF -MAMBAf8wDQYJKoZIhvcNAQEMBQADggIBAFzUfA3P9wF9QZllDHPFUp/L+M+ZBn8b2kMVn54CVVeW -FPFSPCeHlCjtHzoBN6J2/FNQwISbxmtOuowhT6KOVWKR82kV2LyI48SqC/3vqOlLVSoGIG1VeCkZ -7l8wXEskEVX/JJpuXior7gtNn3/3ATiUFJVDBwn7YKnuHKsSjKCaXqeYalltiz8I+8jRRa8YFWSQ -Eg9zKC7F4iRO/Fjs8PRF/iKz6y+O0tlFYQXBl2+odnKPi4w2r78NBc5xjeambx9spnFixdjQg3IM -8WcRiQycE0xyNN+81XHfqnHd4blsjDwSXWXavVcStkNr/+XeTWYRUc+ZruwXtuhxkYzeSf7dNXGi -FSeUHM9h4ya7b6NnJSFd5t0dCy5oGzuCr+yDZ4XUmFF0sbmZgIn/f3gZXHlKYC6SQK5MNyosycdi -yA5d9zZbyuAlJQG03RoHnHcAP9Dc1ew91Pq7P8yF1m9/qS3fuQL39ZeatTXaw2ewh0qpKJ4jjv9c -J2vhsE/zB+4ALtRZh8tSQZXq9EfX7mRBVXyNWQKV3WKdwrnuWih0hKWbt5DHDAff9Yk2dDLWKMGw -sAvgnEzDHNb842m1R0aBL6KCq9NjRHDEjf8tM7qtj3u1cIiuPhnPQCjY/MiQu12ZIvVS5ljFH4gx -Q+6IHdfGjjxDah2nGN59PRbxYvnKkKj9 ------END CERTIFICATE----- - -USERTrust ECC Certification Authority -===================================== ------BEGIN CERTIFICATE----- -MIICjzCCAhWgAwIBAgIQXIuZxVqUxdJxVt7NiYDMJjAKBggqhkjOPQQDAzCBiDELMAkGA1UEBhMC -VVMxEzARBgNVBAgTCk5ldyBKZXJzZXkxFDASBgNVBAcTC0plcnNleSBDaXR5MR4wHAYDVQQKExVU -aGUgVVNFUlRSVVNUIE5ldHdvcmsxLjAsBgNVBAMTJVVTRVJUcnVzdCBFQ0MgQ2VydGlmaWNhdGlv -biBBdXRob3JpdHkwHhcNMTAwMjAxMDAwMDAwWhcNMzgwMTE4MjM1OTU5WjCBiDELMAkGA1UEBhMC -VVMxEzARBgNVBAgTCk5ldyBKZXJzZXkxFDASBgNVBAcTC0plcnNleSBDaXR5MR4wHAYDVQQKExVU -aGUgVVNFUlRSVVNUIE5ldHdvcmsxLjAsBgNVBAMTJVVTRVJUcnVzdCBFQ0MgQ2VydGlmaWNhdGlv -biBBdXRob3JpdHkwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAAQarFRaqfloI+d61SRvU8Za2EurxtW2 -0eZzca7dnNYMYf3boIkDuAUU7FfO7l0/4iGzzvfUinngo4N+LZfQYcTxmdwlkWOrfzCjtHDix6Ez -nPO/LlxTsV+zfTJ/ijTjeXmjQjBAMB0GA1UdDgQWBBQ64QmG1M8ZwpZ2dEl23OA1xmNjmjAOBgNV -HQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAKBggqhkjOPQQDAwNoADBlAjA2Z6EWCNzklwBB -HU6+4WMBzzuqQhFkoJ2UOQIReVx7Hfpkue4WQrO/isIJxOzksU0CMQDpKmFHjFJKS04YcPbWRNZu -9YO6bVi9JNlWSOrvxKJGgYhqOkbRqZtNyWHa0V1Xahg= ------END CERTIFICATE----- - -GlobalSign ECC Root CA - R4 -=========================== ------BEGIN CERTIFICATE----- -MIIB4TCCAYegAwIBAgIRKjikHJYKBN5CsiilC+g0mAIwCgYIKoZIzj0EAwIwUDEkMCIGA1UECxMb -R2xvYmFsU2lnbiBFQ0MgUm9vdCBDQSAtIFI0MRMwEQYDVQQKEwpHbG9iYWxTaWduMRMwEQYDVQQD -EwpHbG9iYWxTaWduMB4XDTEyMTExMzAwMDAwMFoXDTM4MDExOTAzMTQwN1owUDEkMCIGA1UECxMb -R2xvYmFsU2lnbiBFQ0MgUm9vdCBDQSAtIFI0MRMwEQYDVQQKEwpHbG9iYWxTaWduMRMwEQYDVQQD -EwpHbG9iYWxTaWduMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEuMZ5049sJQ6fLjkZHAOkrprl -OQcJFspjsbmG+IpXwVfOQvpzofdlQv8ewQCybnMO/8ch5RikqtlxP6jUuc6MHaNCMEAwDgYDVR0P -AQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFFSwe61FuOJAf/sKbvu+M8k8o4TV -MAoGCCqGSM49BAMCA0gAMEUCIQDckqGgE6bPA7DmxCGXkPoUVy0D7O48027KqGx2vKLeuwIgJ6iF -JzWbVsaj8kfSt24bAgAXqmemFZHe+pTsewv4n4Q= ------END CERTIFICATE----- - -GlobalSign ECC Root CA - R5 -=========================== ------BEGIN CERTIFICATE----- -MIICHjCCAaSgAwIBAgIRYFlJ4CYuu1X5CneKcflK2GwwCgYIKoZIzj0EAwMwUDEkMCIGA1UECxMb -R2xvYmFsU2lnbiBFQ0MgUm9vdCBDQSAtIFI1MRMwEQYDVQQKEwpHbG9iYWxTaWduMRMwEQYDVQQD -EwpHbG9iYWxTaWduMB4XDTEyMTExMzAwMDAwMFoXDTM4MDExOTAzMTQwN1owUDEkMCIGA1UECxMb -R2xvYmFsU2lnbiBFQ0MgUm9vdCBDQSAtIFI1MRMwEQYDVQQKEwpHbG9iYWxTaWduMRMwEQYDVQQD -EwpHbG9iYWxTaWduMHYwEAYHKoZIzj0CAQYFK4EEACIDYgAER0UOlvt9Xb/pOdEh+J8LttV7HpI6 -SFkc8GIxLcB6KP4ap1yztsyX50XUWPrRd21DosCHZTQKH3rd6zwzocWdTaRvQZU4f8kehOvRnkmS -h5SHDDqFSmafnVmTTZdhBoZKo0IwQDAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAd -BgNVHQ4EFgQUPeYpSJvqB8ohREom3m7e0oPQn1kwCgYIKoZIzj0EAwMDaAAwZQIxAOVpEslu28Yx -uglB4Zf4+/2a4n0Sye18ZNPLBSWLVtmg515dTguDnFt2KaAJJiFqYgIwcdK1j1zqO+F4CYWodZI7 -yFz9SO8NdCKoCOJuxUnOxwy8p2Fp8fc74SrL+SvzZpA3 ------END CERTIFICATE----- - -Staat der Nederlanden Root CA - G3 -================================== ------BEGIN CERTIFICATE----- -MIIFdDCCA1ygAwIBAgIEAJiiOTANBgkqhkiG9w0BAQsFADBaMQswCQYDVQQGEwJOTDEeMBwGA1UE -CgwVU3RhYXQgZGVyIE5lZGVybGFuZGVuMSswKQYDVQQDDCJTdGFhdCBkZXIgTmVkZXJsYW5kZW4g -Um9vdCBDQSAtIEczMB4XDTEzMTExNDExMjg0MloXDTI4MTExMzIzMDAwMFowWjELMAkGA1UEBhMC -TkwxHjAcBgNVBAoMFVN0YWF0IGRlciBOZWRlcmxhbmRlbjErMCkGA1UEAwwiU3RhYXQgZGVyIE5l -ZGVybGFuZGVuIFJvb3QgQ0EgLSBHMzCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAL4y -olQPcPssXFnrbMSkUeiFKrPMSjTysF/zDsccPVMeiAho2G89rcKezIJnByeHaHE6n3WWIkYFsO2t -x1ueKt6c/DrGlaf1F2cY5y9JCAxcz+bMNO14+1Cx3Gsy8KL+tjzk7FqXxz8ecAgwoNzFs21v0IJy -EavSgWhZghe3eJJg+szeP4TrjTgzkApyI/o1zCZxMdFyKJLZWyNtZrVtB0LrpjPOktvA9mxjeM3K -Tj215VKb8b475lRgsGYeCasH/lSJEULR9yS6YHgamPfJEf0WwTUaVHXvQ9Plrk7O53vDxk5hUUur -mkVLoR9BvUhTFXFkC4az5S6+zqQbwSmEorXLCCN2QyIkHxcE1G6cxvx/K2Ya7Irl1s9N9WMJtxU5 -1nus6+N86U78dULI7ViVDAZCopz35HCz33JvWjdAidiFpNfxC95DGdRKWCyMijmev4SH8RY7Ngzp -07TKbBlBUgmhHbBqv4LvcFEhMtwFdozL92TkA1CvjJFnq8Xy7ljY3r735zHPbMk7ccHViLVlvMDo -FxcHErVc0qsgk7TmgoNwNsXNo42ti+yjwUOH5kPiNL6VizXtBznaqB16nzaeErAMZRKQFWDZJkBE -41ZgpRDUajz9QdwOWke275dhdU/Z/seyHdTtXUmzqWrLZoQT1Vyg3N9udwbRcXXIV2+vD3dbAgMB -AAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBRUrfrHkleu -yjWcLhL75LpdINyUVzANBgkqhkiG9w0BAQsFAAOCAgEAMJmdBTLIXg47mAE6iqTnB/d6+Oea31BD -U5cqPco8R5gu4RV78ZLzYdqQJRZlwJ9UXQ4DO1t3ApyEtg2YXzTdO2PCwyiBwpwpLiniyMMB8jPq -KqrMCQj3ZWfGzd/TtiunvczRDnBfuCPRy5FOCvTIeuXZYzbB1N/8Ipf3YF3qKS9Ysr1YvY2WTxB1 -v0h7PVGHoTx0IsL8B3+A3MSs/mrBcDCw6Y5p4ixpgZQJut3+TcCDjJRYwEYgr5wfAvg1VUkvRtTA -8KCWAg8zxXHzniN9lLf9OtMJgwYh/WA9rjLA0u6NpvDntIJ8CsxwyXmA+P5M9zWEGYox+wrZ13+b -8KKaa8MFSu1BYBQw0aoRQm7TIwIEC8Zl3d1Sd9qBa7Ko+gE4uZbqKmxnl4mUnrzhVNXkanjvSr0r -mj1AfsbAddJu+2gw7OyLnflJNZoaLNmzlTnVHpL3prllL+U9bTpITAjc5CgSKL59NVzq4BZ+Extq -1z7XnvwtdbLBFNUjA9tbbws+eC8N3jONFrdI54OagQ97wUNNVQQXOEpR1VmiiXTTn74eS9fGbbeI -JG9gkaSChVtWQbzQRKtqE77RLFi3EjNYsjdj3BP1lB0/QFH1T/U67cjF68IeHRaVesd+QnGTbksV -tzDfqu1XhUisHWrdOWnk4Xl4vs4Fv6EM94B7IWcnMFk= ------END CERTIFICATE----- - -Staat der Nederlanden EV Root CA -================================ ------BEGIN CERTIFICATE----- -MIIFcDCCA1igAwIBAgIEAJiWjTANBgkqhkiG9w0BAQsFADBYMQswCQYDVQQGEwJOTDEeMBwGA1UE -CgwVU3RhYXQgZGVyIE5lZGVybGFuZGVuMSkwJwYDVQQDDCBTdGFhdCBkZXIgTmVkZXJsYW5kZW4g -RVYgUm9vdCBDQTAeFw0xMDEyMDgxMTE5MjlaFw0yMjEyMDgxMTEwMjhaMFgxCzAJBgNVBAYTAk5M -MR4wHAYDVQQKDBVTdGFhdCBkZXIgTmVkZXJsYW5kZW4xKTAnBgNVBAMMIFN0YWF0IGRlciBOZWRl -cmxhbmRlbiBFViBSb290IENBMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEA48d+ifkk -SzrSM4M1LGns3Amk41GoJSt5uAg94JG6hIXGhaTK5skuU6TJJB79VWZxXSzFYGgEt9nCUiY4iKTW -O0Cmws0/zZiTs1QUWJZV1VD+hq2kY39ch/aO5ieSZxeSAgMs3NZmdO3dZ//BYY1jTw+bbRcwJu+r -0h8QoPnFfxZpgQNH7R5ojXKhTbImxrpsX23Wr9GxE46prfNeaXUmGD5BKyF/7otdBwadQ8QpCiv8 -Kj6GyzyDOvnJDdrFmeK8eEEzduG/L13lpJhQDBXd4Pqcfzho0LKmeqfRMb1+ilgnQ7O6M5HTp5gV -XJrm0w912fxBmJc+qiXbj5IusHsMX/FjqTf5m3VpTCgmJdrV8hJwRVXj33NeN/UhbJCONVrJ0yPr -08C+eKxCKFhmpUZtcALXEPlLVPxdhkqHz3/KRawRWrUgUY0viEeXOcDPusBCAUCZSCELa6fS/ZbV -0b5GnUngC6agIk440ME8MLxwjyx1zNDFjFE7PZQIZCZhfbnDZY8UnCHQqv0XcgOPvZuM5l5Tnrmd -74K74bzickFbIZTTRTeU0d8JOV3nI6qaHcptqAqGhYqCvkIH1vI4gnPah1vlPNOePqc7nvQDs/nx -fRN0Av+7oeX6AHkcpmZBiFxgV6YuCcS6/ZrPpx9Aw7vMWgpVSzs4dlG4Y4uElBbmVvMCAwEAAaNC -MEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFP6rAJCYniT8qcwa -ivsnuL8wbqg7MA0GCSqGSIb3DQEBCwUAA4ICAQDPdyxuVr5Os7aEAJSrR8kN0nbHhp8dB9O2tLsI -eK9p0gtJ3jPFrK3CiAJ9Brc1AsFgyb/E6JTe1NOpEyVa/m6irn0F3H3zbPB+po3u2dfOWBfoqSmu -c0iH55vKbimhZF8ZE/euBhD/UcabTVUlT5OZEAFTdfETzsemQUHSv4ilf0X8rLiltTMMgsT7B/Zq -5SWEXwbKwYY5EdtYzXc7LMJMD16a4/CrPmEbUCTCwPTxGfARKbalGAKb12NMcIxHowNDXLldRqAN -b/9Zjr7dn3LDWyvfjFvO5QxGbJKyCqNMVEIYFRIYvdr8unRu/8G2oGTYqV9Vrp9canaW2HNnh/tN -f1zuacpzEPuKqf2evTY4SUmH9A4U8OmHuD+nT3pajnnUk+S7aFKErGzp85hwVXIy+TSrK0m1zSBi -5Dp6Z2Orltxtrpfs/J92VoguZs9btsmksNcFuuEnL5O7Jiqik7Ab846+HUCjuTaPPoIaGl6I6lD4 -WeKDRikL40Rc4ZW2aZCaFG+XroHPaO+Zmr615+F/+PoTRxZMzG0IQOeLeG9QgkRQP2YGiqtDhFZK -DyAthg710tvSeopLzaXoTvFeJiUBWSOgftL2fiFX1ye8FVdMpEbB4IMeDExNH08GGeL5qPQ6gqGy -eUN51q1veieQA6TqJIc/2b3Z6fJfUEkc7uzXLg== ------END CERTIFICATE----- - -IdenTrust Commercial Root CA 1 -============================== ------BEGIN CERTIFICATE----- -MIIFYDCCA0igAwIBAgIQCgFCgAAAAUUjyES1AAAAAjANBgkqhkiG9w0BAQsFADBKMQswCQYDVQQG -EwJVUzESMBAGA1UEChMJSWRlblRydXN0MScwJQYDVQQDEx5JZGVuVHJ1c3QgQ29tbWVyY2lhbCBS -b290IENBIDEwHhcNMTQwMTE2MTgxMjIzWhcNMzQwMTE2MTgxMjIzWjBKMQswCQYDVQQGEwJVUzES -MBAGA1UEChMJSWRlblRydXN0MScwJQYDVQQDEx5JZGVuVHJ1c3QgQ29tbWVyY2lhbCBSb290IENB -IDEwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCnUBneP5k91DNG8W9RYYKyqU+PZ4ld -hNlT3Qwo2dfw/66VQ3KZ+bVdfIrBQuExUHTRgQ18zZshq0PirK1ehm7zCYofWjK9ouuU+ehcCuz/ -mNKvcbO0U59Oh++SvL3sTzIwiEsXXlfEU8L2ApeN2WIrvyQfYo3fw7gpS0l4PJNgiCL8mdo2yMKi -1CxUAGc1bnO/AljwpN3lsKImesrgNqUZFvX9t++uP0D1bVoE/c40yiTcdCMbXTMTEl3EASX2MN0C -XZ/g1Ue9tOsbobtJSdifWwLziuQkkORiT0/Br4sOdBeo0XKIanoBScy0RnnGF7HamB4HWfp1IYVl -3ZBWzvurpWCdxJ35UrCLvYf5jysjCiN2O/cz4ckA82n5S6LgTrx+kzmEB/dEcH7+B1rlsazRGMzy -NeVJSQjKVsk9+w8YfYs7wRPCTY/JTw436R+hDmrfYi7LNQZReSzIJTj0+kuniVyc0uMNOYZKdHzV -WYfCP04MXFL0PfdSgvHqo6z9STQaKPNBiDoT7uje/5kdX7rL6B7yuVBgwDHTc+XvvqDtMwt0viAg -xGds8AgDelWAf0ZOlqf0Hj7h9tgJ4TNkK2PXMl6f+cB7D3hvl7yTmvmcEpB4eoCHFddydJxVdHix -uuFucAS6T6C6aMN7/zHwcz09lCqxC0EOoP5NiGVreTO01wIDAQABo0IwQDAOBgNVHQ8BAf8EBAMC -AQYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQU7UQZwNPwBovupHu+QucmVMiONnYwDQYJKoZI -hvcNAQELBQADggIBAA2ukDL2pkt8RHYZYR4nKM1eVO8lvOMIkPkp165oCOGUAFjvLi5+U1KMtlwH -6oi6mYtQlNeCgN9hCQCTrQ0U5s7B8jeUeLBfnLOic7iPBZM4zY0+sLj7wM+x8uwtLRvM7Kqas6pg -ghstO8OEPVeKlh6cdbjTMM1gCIOQ045U8U1mwF10A0Cj7oV+wh93nAbowacYXVKV7cndJZ5t+qnt -ozo00Fl72u1Q8zW/7esUTTHHYPTa8Yec4kjixsU3+wYQ+nVZZjFHKdp2mhzpgq7vmrlR94gjmmmV -YjzlVYA211QC//G5Xc7UI2/YRYRKW2XviQzdFKcgyxilJbQN+QHwotL0AMh0jqEqSI5l2xPE4iUX -feu+h1sXIFRRk0pTAwvsXcoz7WL9RccvW9xYoIA55vrX/hMUpu09lEpCdNTDd1lzzY9GvlU47/ro -kTLql1gEIt44w8y8bckzOmoKaT+gyOpyj4xjhiO9bTyWnpXgSUyqorkqG5w2gXjtw+hG4iZZRHUe -2XWJUc0QhJ1hYMtd+ZciTY6Y5uN/9lu7rs3KSoFrXgvzUeF0K+l+J6fZmUlO+KWA2yUPHGNiiskz -Z2s8EIPGrd6ozRaOjfAHN3Gf8qv8QfXBi+wAN10J5U6A7/qxXDgGpRtK4dw4LTzcqx+QGtVKnO7R -cGzM7vRX+Bi6hG6H ------END CERTIFICATE----- - -IdenTrust Public Sector Root CA 1 -================================= ------BEGIN CERTIFICATE----- -MIIFZjCCA06gAwIBAgIQCgFCgAAAAUUjz0Z8AAAAAjANBgkqhkiG9w0BAQsFADBNMQswCQYDVQQG -EwJVUzESMBAGA1UEChMJSWRlblRydXN0MSowKAYDVQQDEyFJZGVuVHJ1c3QgUHVibGljIFNlY3Rv -ciBSb290IENBIDEwHhcNMTQwMTE2MTc1MzMyWhcNMzQwMTE2MTc1MzMyWjBNMQswCQYDVQQGEwJV -UzESMBAGA1UEChMJSWRlblRydXN0MSowKAYDVQQDEyFJZGVuVHJ1c3QgUHVibGljIFNlY3RvciBS -b290IENBIDEwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC2IpT8pEiv6EdrCvsnduTy -P4o7ekosMSqMjbCpwzFrqHd2hCa2rIFCDQjrVVi7evi8ZX3yoG2LqEfpYnYeEe4IFNGyRBb06tD6 -Hi9e28tzQa68ALBKK0CyrOE7S8ItneShm+waOh7wCLPQ5CQ1B5+ctMlSbdsHyo+1W/CD80/HLaXI -rcuVIKQxKFdYWuSNG5qrng0M8gozOSI5Cpcu81N3uURF/YTLNiCBWS2ab21ISGHKTN9T0a9SvESf -qy9rg3LvdYDaBjMbXcjaY8ZNzaxmMc3R3j6HEDbhuaR672BQssvKplbgN6+rNBM5Jeg5ZuSYeqoS -mJxZZoY+rfGwyj4GD3vwEUs3oERte8uojHH01bWRNszwFcYr3lEXsZdMUD2xlVl8BX0tIdUAvwFn -ol57plzy9yLxkA2T26pEUWbMfXYD62qoKjgZl3YNa4ph+bz27nb9cCvdKTz4Ch5bQhyLVi9VGxyh -LrXHFub4qjySjmm2AcG1hp2JDws4lFTo6tyePSW8Uybt1as5qsVATFSrsrTZ2fjXctscvG29ZV/v -iDUqZi/u9rNl8DONfJhBaUYPQxxp+pu10GFqzcpL2UyQRqsVWaFHVCkugyhfHMKiq3IXAAaOReyL -4jM9f9oZRORicsPfIsbyVtTdX5Vy7W1f90gDW/3FKqD2cyOEEBsB5wIDAQABo0IwQDAOBgNVHQ8B -Af8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQU43HgntinQtnbcZFrlJPrw6PRFKMw -DQYJKoZIhvcNAQELBQADggIBAEf63QqwEZE4rU1d9+UOl1QZgkiHVIyqZJnYWv6IAcVYpZmxI1Qj -t2odIFflAWJBF9MJ23XLblSQdf4an4EKwt3X9wnQW3IV5B4Jaj0z8yGa5hV+rVHVDRDtfULAj+7A -mgjVQdZcDiFpboBhDhXAuM/FSRJSzL46zNQuOAXeNf0fb7iAaJg9TaDKQGXSc3z1i9kKlT/YPyNt -GtEqJBnZhbMX73huqVjRI9PHE+1yJX9dsXNw0H8GlwmEKYBhHfpe/3OsoOOJuBxxFcbeMX8S3OFt -m6/n6J91eEyrRjuazr8FGF1NFTwWmhlQBJqymm9li1JfPFgEKCXAZmExfrngdbkaqIHWchezxQMx -NRF4eKLg6TCMf4DfWN88uieW4oA0beOY02QnrEh+KHdcxiVhJfiFDGX6xDIvpZgF5PgLZxYWxoK4 -Mhn5+bl53B/N66+rDt0b20XkeucC4pVd/GnwU2lhlXV5C15V5jgclKlZM57IcXR5f1GJtshquDDI -ajjDbp7hNxbqBWJMWxJH7ae0s1hWx0nzfxJoCTFx8G34Tkf71oXuxVhAGaQdp/lLQzfcaFpPz+vC -ZHTetBXZ9FRUGi8c15dxVJCO2SCdUyt/q4/i6jC8UDfv8Ue1fXwsBOxonbRJRBD0ckscZOf85muQ -3Wl9af0AVqW3rLatt8o+Ae+c ------END CERTIFICATE----- - -Entrust Root Certification Authority - G2 -========================================= ------BEGIN CERTIFICATE----- -MIIEPjCCAyagAwIBAgIESlOMKDANBgkqhkiG9w0BAQsFADCBvjELMAkGA1UEBhMCVVMxFjAUBgNV -BAoTDUVudHJ1c3QsIEluYy4xKDAmBgNVBAsTH1NlZSB3d3cuZW50cnVzdC5uZXQvbGVnYWwtdGVy -bXMxOTA3BgNVBAsTMChjKSAyMDA5IEVudHJ1c3QsIEluYy4gLSBmb3IgYXV0aG9yaXplZCB1c2Ug -b25seTEyMDAGA1UEAxMpRW50cnVzdCBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IC0gRzIw -HhcNMDkwNzA3MTcyNTU0WhcNMzAxMjA3MTc1NTU0WjCBvjELMAkGA1UEBhMCVVMxFjAUBgNVBAoT -DUVudHJ1c3QsIEluYy4xKDAmBgNVBAsTH1NlZSB3d3cuZW50cnVzdC5uZXQvbGVnYWwtdGVybXMx -OTA3BgNVBAsTMChjKSAyMDA5IEVudHJ1c3QsIEluYy4gLSBmb3IgYXV0aG9yaXplZCB1c2Ugb25s -eTEyMDAGA1UEAxMpRW50cnVzdCBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IC0gRzIwggEi -MA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQC6hLZy254Ma+KZ6TABp3bqMriVQRrJ2mFOWHLP -/vaCeb9zYQYKpSfYs1/TRU4cctZOMvJyig/3gxnQaoCAAEUesMfnmr8SVycco2gvCoe9amsOXmXz -HHfV1IWNcCG0szLni6LVhjkCsbjSR87kyUnEO6fe+1R9V77w6G7CebI6C1XiUJgWMhNcL3hWwcKU -s/Ja5CeanyTXxuzQmyWC48zCxEXFjJd6BmsqEZ+pCm5IO2/b1BEZQvePB7/1U1+cPvQXLOZprE4y -TGJ36rfo5bs0vBmLrpxR57d+tVOxMyLlbc9wPBr64ptntoP0jaWvYkxN4FisZDQSA/i2jZRjJKRx -AgMBAAGjQjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBRqciZ6 -0B7vfec7aVHUbI2fkBJmqzANBgkqhkiG9w0BAQsFAAOCAQEAeZ8dlsa2eT8ijYfThwMEYGprmi5Z -iXMRrEPR9RP/jTkrwPK9T3CMqS/qF8QLVJ7UG5aYMzyorWKiAHarWWluBh1+xLlEjZivEtRh2woZ -Rkfz6/djwUAFQKXSt/S1mja/qYh2iARVBCuch38aNzx+LaUa2NSJXsq9rD1s2G2v1fN2D807iDgi -nWyTmsQ9v4IbZT+mD12q/OWyFcq1rca8PdCE6OoGcrBNOTJ4vz4RnAuknZoh8/CbCzB428Hch0P+ -vGOaysXCHMnHjf87ElgI5rY97HosTvuDls4MPGmHVHOkc8KT/1EQrBVUAdj8BbGJoX90g5pJ19xO -e4pIb4tF9g== ------END CERTIFICATE----- - -Entrust Root Certification Authority - EC1 -========================================== ------BEGIN CERTIFICATE----- -MIIC+TCCAoCgAwIBAgINAKaLeSkAAAAAUNCR+TAKBggqhkjOPQQDAzCBvzELMAkGA1UEBhMCVVMx -FjAUBgNVBAoTDUVudHJ1c3QsIEluYy4xKDAmBgNVBAsTH1NlZSB3d3cuZW50cnVzdC5uZXQvbGVn -YWwtdGVybXMxOTA3BgNVBAsTMChjKSAyMDEyIEVudHJ1c3QsIEluYy4gLSBmb3IgYXV0aG9yaXpl -ZCB1c2Ugb25seTEzMDEGA1UEAxMqRW50cnVzdCBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5 -IC0gRUMxMB4XDTEyMTIxODE1MjUzNloXDTM3MTIxODE1NTUzNlowgb8xCzAJBgNVBAYTAlVTMRYw -FAYDVQQKEw1FbnRydXN0LCBJbmMuMSgwJgYDVQQLEx9TZWUgd3d3LmVudHJ1c3QubmV0L2xlZ2Fs -LXRlcm1zMTkwNwYDVQQLEzAoYykgMjAxMiBFbnRydXN0LCBJbmMuIC0gZm9yIGF1dGhvcml6ZWQg -dXNlIG9ubHkxMzAxBgNVBAMTKkVudHJ1c3QgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSAt -IEVDMTB2MBAGByqGSM49AgEGBSuBBAAiA2IABIQTydC6bUF74mzQ61VfZgIaJPRbiWlH47jCffHy -AsWfoPZb1YsGGYZPUxBtByQnoaD41UcZYUx9ypMn6nQM72+WCf5j7HBdNq1nd67JnXxVRDqiY1Ef -9eNi1KlHBz7MIKNCMEAwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYE -FLdj5xrdjekIplWDpOBqUEFlEUJJMAoGCCqGSM49BAMDA2cAMGQCMGF52OVCR98crlOZF7ZvHH3h -vxGU0QOIdeSNiaSKd0bebWHvAvX7td/M/k7//qnmpwIwW5nXhTcGtXsI/esni0qU+eH6p44mCOh8 -kmhtc9hvJqwhAriZtyZBWyVgrtBIGu4G ------END CERTIFICATE----- - -CFCA EV ROOT -============ ------BEGIN CERTIFICATE----- -MIIFjTCCA3WgAwIBAgIEGErM1jANBgkqhkiG9w0BAQsFADBWMQswCQYDVQQGEwJDTjEwMC4GA1UE -CgwnQ2hpbmEgRmluYW5jaWFsIENlcnRpZmljYXRpb24gQXV0aG9yaXR5MRUwEwYDVQQDDAxDRkNB -IEVWIFJPT1QwHhcNMTIwODA4MDMwNzAxWhcNMjkxMjMxMDMwNzAxWjBWMQswCQYDVQQGEwJDTjEw -MC4GA1UECgwnQ2hpbmEgRmluYW5jaWFsIENlcnRpZmljYXRpb24gQXV0aG9yaXR5MRUwEwYDVQQD -DAxDRkNBIEVWIFJPT1QwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDXXWvNED8fBVnV -BU03sQ7smCuOFR36k0sXgiFxEFLXUWRwFsJVaU2OFW2fvwwbwuCjZ9YMrM8irq93VCpLTIpTUnrD -7i7es3ElweldPe6hL6P3KjzJIx1qqx2hp/Hz7KDVRM8Vz3IvHWOX6Jn5/ZOkVIBMUtRSqy5J35DN -uF++P96hyk0g1CXohClTt7GIH//62pCfCqktQT+x8Rgp7hZZLDRJGqgG16iI0gNyejLi6mhNbiyW -ZXvKWfry4t3uMCz7zEasxGPrb382KzRzEpR/38wmnvFyXVBlWY9ps4deMm/DGIq1lY+wejfeWkU7 -xzbh72fROdOXW3NiGUgthxwG+3SYIElz8AXSG7Ggo7cbcNOIabla1jj0Ytwli3i/+Oh+uFzJlU9f -py25IGvPa931DfSCt/SyZi4QKPaXWnuWFo8BGS1sbn85WAZkgwGDg8NNkt0yxoekN+kWzqotaK8K -gWU6cMGbrU1tVMoqLUuFG7OA5nBFDWteNfB/O7ic5ARwiRIlk9oKmSJgamNgTnYGmE69g60dWIol -hdLHZR4tjsbftsbhf4oEIRUpdPA+nJCdDC7xij5aqgwJHsfVPKPtl8MeNPo4+QgO48BdK4PRVmrJ -tqhUUy54Mmc9gn900PvhtgVguXDbjgv5E1hvcWAQUhC5wUEJ73IfZzF4/5YFjQIDAQABo2MwYTAf -BgNVHSMEGDAWgBTj/i39KNALtbq2osS/BqoFjJP7LzAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB -/wQEAwIBBjAdBgNVHQ4EFgQU4/4t/SjQC7W6tqLEvwaqBYyT+y8wDQYJKoZIhvcNAQELBQADggIB -ACXGumvrh8vegjmWPfBEp2uEcwPenStPuiB/vHiyz5ewG5zz13ku9Ui20vsXiObTej/tUxPQ4i9q -ecsAIyjmHjdXNYmEwnZPNDatZ8POQQaIxffu2Bq41gt/UP+TqhdLjOztUmCypAbqTuv0axn96/Ua -4CUqmtzHQTb3yHQFhDmVOdYLO6Qn+gjYXB74BGBSESgoA//vU2YApUo0FmZ8/Qmkrp5nGm9BC2sG -E5uPhnEFtC+NiWYzKXZUmhH4J/qyP5Hgzg0b8zAarb8iXRvTvyUFTeGSGn+ZnzxEk8rUQElsgIfX -BDrDMlI1Dlb4pd19xIsNER9Tyx6yF7Zod1rg1MvIB671Oi6ON7fQAUtDKXeMOZePglr4UeWJoBjn -aH9dCi77o0cOPaYjesYBx4/IXr9tgFa+iiS6M+qf4TIRnvHST4D2G0CvOJ4RUHlzEhLN5mydLIhy -PDCBBpEi6lmt2hkuIsKNuYyH4Ga8cyNfIWRjgEj1oDwYPZTISEEdQLpe/v5WOaHIz16eGWRGENoX -kbcFgKyLmZJ956LYBws2J+dIeWCKw9cTXPhyQN9Ky8+ZAAoACxGV2lZFA4gKn2fQ1XmxqI1AbQ3C -ekD6819kR5LLU7m7Wc5P/dAVUwHY3+vZ5nbv0CO7O6l5s9UCKc2Jo5YPSjXnTkLAdc0Hz+Ys63su ------END CERTIFICATE----- - -OISTE WISeKey Global Root GB CA -=============================== ------BEGIN CERTIFICATE----- -MIIDtTCCAp2gAwIBAgIQdrEgUnTwhYdGs/gjGvbCwDANBgkqhkiG9w0BAQsFADBtMQswCQYDVQQG -EwJDSDEQMA4GA1UEChMHV0lTZUtleTEiMCAGA1UECxMZT0lTVEUgRm91bmRhdGlvbiBFbmRvcnNl -ZDEoMCYGA1UEAxMfT0lTVEUgV0lTZUtleSBHbG9iYWwgUm9vdCBHQiBDQTAeFw0xNDEyMDExNTAw -MzJaFw0zOTEyMDExNTEwMzFaMG0xCzAJBgNVBAYTAkNIMRAwDgYDVQQKEwdXSVNlS2V5MSIwIAYD -VQQLExlPSVNURSBGb3VuZGF0aW9uIEVuZG9yc2VkMSgwJgYDVQQDEx9PSVNURSBXSVNlS2V5IEds -b2JhbCBSb290IEdCIENBMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA2Be3HEokKtaX -scriHvt9OO+Y9bI5mE4nuBFde9IllIiCFSZqGzG7qFshISvYD06fWvGxWuR51jIjK+FTzJlFXHtP -rby/h0oLS5daqPZI7H17Dc0hBt+eFf1Biki3IPShehtX1F1Q/7pn2COZH8g/497/b1t3sWtuuMlk -9+HKQUYOKXHQuSP8yYFfTvdv37+ErXNku7dCjmn21HYdfp2nuFeKUWdy19SouJVUQHMD9ur06/4o -Qnc/nSMbsrY9gBQHTC5P99UKFg29ZkM3fiNDecNAhvVMKdqOmq0NpQSHiB6F4+lT1ZvIiwNjeOvg -GUpuuy9rM2RYk61pv48b74JIxwIDAQABo1EwTzALBgNVHQ8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB -/zAdBgNVHQ4EFgQUNQ/INmNe4qPs+TtmFc5RUuORmj0wEAYJKwYBBAGCNxUBBAMCAQAwDQYJKoZI -hvcNAQELBQADggEBAEBM+4eymYGQfp3FsLAmzYh7KzKNbrghcViXfa43FK8+5/ea4n32cZiZBKpD -dHij40lhPnOMTZTg+XHEthYOU3gf1qKHLwI5gSk8rxWYITD+KJAAjNHhy/peyP34EEY7onhCkRd0 -VQreUGdNZtGn//3ZwLWoo4rOZvUPQ82nK1d7Y0Zqqi5S2PTt4W2tKZB4SLrhI6qjiey1q5bAtEui -HZeeevJuQHHfaPFlTc58Bd9TZaml8LGXBHAVRgOY1NK/VLSgWH1Sb9pWJmLU2NuJMW8c8CLC02Ic -Nc1MaRVUGpCY3useX8p3x8uOPUNpnJpY0CQ73xtAln41rYHHTnG6iBM= ------END CERTIFICATE----- - -SZAFIR ROOT CA2 -=============== ------BEGIN CERTIFICATE----- -MIIDcjCCAlqgAwIBAgIUPopdB+xV0jLVt+O2XwHrLdzk1uQwDQYJKoZIhvcNAQELBQAwUTELMAkG -A1UEBhMCUEwxKDAmBgNVBAoMH0tyYWpvd2EgSXpiYSBSb3psaWN6ZW5pb3dhIFMuQS4xGDAWBgNV -BAMMD1NaQUZJUiBST09UIENBMjAeFw0xNTEwMTkwNzQzMzBaFw0zNTEwMTkwNzQzMzBaMFExCzAJ -BgNVBAYTAlBMMSgwJgYDVQQKDB9LcmFqb3dhIEl6YmEgUm96bGljemVuaW93YSBTLkEuMRgwFgYD -VQQDDA9TWkFGSVIgUk9PVCBDQTIwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQC3vD5Q -qEvNQLXOYeeWyrSh2gwisPq1e3YAd4wLz32ohswmUeQgPYUM1ljj5/QqGJ3a0a4m7utT3PSQ1hNK -DJA8w/Ta0o4NkjrcsbH/ON7Dui1fgLkCvUqdGw+0w8LBZwPd3BucPbOw3gAeqDRHu5rr/gsUvTaE -2g0gv/pby6kWIK05YO4vdbbnl5z5Pv1+TW9NL++IDWr63fE9biCloBK0TXC5ztdyO4mTp4CEHCdJ -ckm1/zuVnsHMyAHs6A6KCpbns6aH5db5BSsNl0BwPLqsdVqc1U2dAgrSS5tmS0YHF2Wtn2yIANwi -ieDhZNRnvDF5YTy7ykHNXGoAyDw4jlivAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0P -AQH/BAQDAgEGMB0GA1UdDgQWBBQuFqlKGLXLzPVvUPMjX/hd56zwyDANBgkqhkiG9w0BAQsFAAOC -AQEAtXP4A9xZWx126aMqe5Aosk3AM0+qmrHUuOQn/6mWmc5G4G18TKI4pAZw8PRBEew/R40/cof5 -O/2kbytTAOD/OblqBw7rHRz2onKQy4I9EYKL0rufKq8h5mOGnXkZ7/e7DDWQw4rtTw/1zBLZpD67 -oPwglV9PJi8RI4NOdQcPv5vRtB3pEAT+ymCPoky4rc/hkA/NrgrHXXu3UNLUYfrVFdvXn4dRVOul -4+vJhaAlIDf7js4MNIThPIGyd05DpYhfhmehPea0XGG2Ptv+tyjFogeutcrKjSoS75ftwjCkySp6 -+/NNIxuZMzSgLvWpCz/UXeHPhJ/iGcJfitYgHuNztw== ------END CERTIFICATE----- - -Certum Trusted Network CA 2 -=========================== ------BEGIN CERTIFICATE----- -MIIF0jCCA7qgAwIBAgIQIdbQSk8lD8kyN/yqXhKN6TANBgkqhkiG9w0BAQ0FADCBgDELMAkGA1UE -BhMCUEwxIjAgBgNVBAoTGVVuaXpldG8gVGVjaG5vbG9naWVzIFMuQS4xJzAlBgNVBAsTHkNlcnR1 -bSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTEkMCIGA1UEAxMbQ2VydHVtIFRydXN0ZWQgTmV0d29y -ayBDQSAyMCIYDzIwMTExMDA2MDgzOTU2WhgPMjA0NjEwMDYwODM5NTZaMIGAMQswCQYDVQQGEwJQ -TDEiMCAGA1UEChMZVW5pemV0byBUZWNobm9sb2dpZXMgUy5BLjEnMCUGA1UECxMeQ2VydHVtIENl -cnRpZmljYXRpb24gQXV0aG9yaXR5MSQwIgYDVQQDExtDZXJ0dW0gVHJ1c3RlZCBOZXR3b3JrIENB -IDIwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC9+Xj45tWADGSdhhuWZGc/IjoedQF9 -7/tcZ4zJzFxrqZHmuULlIEub2pt7uZld2ZuAS9eEQCsn0+i6MLs+CRqnSZXvK0AkwpfHp+6bJe+o -CgCXhVqqndwpyeI1B+twTUrWwbNWuKFBOJvR+zF/j+Bf4bE/D44WSWDXBo0Y+aomEKsq09DRZ40b -Rr5HMNUuctHFY9rnY3lEfktjJImGLjQ/KUxSiyqnwOKRKIm5wFv5HdnnJ63/mgKXwcZQkpsCLL2p -uTRZCr+ESv/f/rOf69me4Jgj7KZrdxYq28ytOxykh9xGc14ZYmhFV+SQgkK7QtbwYeDBoz1mo130 -GO6IyY0XRSmZMnUCMe4pJshrAua1YkV/NxVaI2iJ1D7eTiew8EAMvE0Xy02isx7QBlrd9pPPV3WZ -9fqGGmd4s7+W/jTcvedSVuWz5XV710GRBdxdaeOVDUO5/IOWOZV7bIBaTxNyxtd9KXpEulKkKtVB -Rgkg/iKgtlswjbyJDNXXcPiHUv3a76xRLgezTv7QCdpw75j6VuZt27VXS9zlLCUVyJ4ueE742pye -hizKV/Ma5ciSixqClnrDvFASadgOWkaLOusm+iPJtrCBvkIApPjW/jAux9JG9uWOdf3yzLnQh1vM -BhBgu4M1t15n3kfsmUjxpKEV/q2MYo45VU85FrmxY53/twIDAQABo0IwQDAPBgNVHRMBAf8EBTAD -AQH/MB0GA1UdDgQWBBS2oVQ5AsOgP46KvPrU+Bym0ToO/TAOBgNVHQ8BAf8EBAMCAQYwDQYJKoZI -hvcNAQENBQADggIBAHGlDs7k6b8/ONWJWsQCYftMxRQXLYtPU2sQF/xlhMcQSZDe28cmk4gmb3DW -Al45oPePq5a1pRNcgRRtDoGCERuKTsZPpd1iHkTfCVn0W3cLN+mLIMb4Ck4uWBzrM9DPhmDJ2vuA -L55MYIR4PSFk1vtBHxgP58l1cb29XN40hz5BsA72udY/CROWFC/emh1auVbONTqwX3BNXuMp8SMo -clm2q8KMZiYcdywmdjWLKKdpoPk79SPdhRB0yZADVpHnr7pH1BKXESLjokmUbOe3lEu6LaTaM4tM -pkT/WjzGHWTYtTHkpjx6qFcL2+1hGsvxznN3Y6SHb0xRONbkX8eftoEq5IVIeVheO/jbAoJnwTnb -w3RLPTYe+SmTiGhbqEQZIfCn6IENLOiTNrQ3ssqwGyZ6miUfmpqAnksqP/ujmv5zMnHCnsZy4Ypo -J/HkD7TETKVhk/iXEAcqMCWpuchxuO9ozC1+9eB+D4Kob7a6bINDd82Kkhehnlt4Fj1F4jNy3eFm -ypnTycUm/Q1oBEauttmbjL4ZvrHG8hnjXALKLNhvSgfZyTXaQHXyxKcZb55CEJh15pWLYLztxRLX -is7VmFxWlgPF7ncGNf/P5O4/E2Hu29othfDNrp2yGAlFw5Khchf8R7agCyzxxN5DaAhqXzvwdmP7 -zAYspsbiDrW5viSP ------END CERTIFICATE----- - -Hellenic Academic and Research Institutions RootCA 2015 -======================================================= ------BEGIN CERTIFICATE----- -MIIGCzCCA/OgAwIBAgIBADANBgkqhkiG9w0BAQsFADCBpjELMAkGA1UEBhMCR1IxDzANBgNVBAcT -BkF0aGVuczFEMEIGA1UEChM7SGVsbGVuaWMgQWNhZGVtaWMgYW5kIFJlc2VhcmNoIEluc3RpdHV0 -aW9ucyBDZXJ0LiBBdXRob3JpdHkxQDA+BgNVBAMTN0hlbGxlbmljIEFjYWRlbWljIGFuZCBSZXNl -YXJjaCBJbnN0aXR1dGlvbnMgUm9vdENBIDIwMTUwHhcNMTUwNzA3MTAxMTIxWhcNNDAwNjMwMTAx -MTIxWjCBpjELMAkGA1UEBhMCR1IxDzANBgNVBAcTBkF0aGVuczFEMEIGA1UEChM7SGVsbGVuaWMg -QWNhZGVtaWMgYW5kIFJlc2VhcmNoIEluc3RpdHV0aW9ucyBDZXJ0LiBBdXRob3JpdHkxQDA+BgNV -BAMTN0hlbGxlbmljIEFjYWRlbWljIGFuZCBSZXNlYXJjaCBJbnN0aXR1dGlvbnMgUm9vdENBIDIw -MTUwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDC+Kk/G4n8PDwEXT2QNrCROnk8Zlrv -bTkBSRq0t89/TSNTt5AA4xMqKKYx8ZEA4yjsriFBzh/a/X0SWwGDD7mwX5nh8hKDgE0GPt+sr+eh -iGsxr/CL0BgzuNtFajT0AoAkKAoCFZVedioNmToUW/bLy1O8E00BiDeUJRtCvCLYjqOWXjrZMts+ -6PAQZe104S+nfK8nNLspfZu2zwnI5dMK/IhlZXQK3HMcXM1AsRzUtoSMTFDPaI6oWa7CJ06CojXd -FPQf/7J31Ycvqm59JCfnxssm5uX+Zwdj2EUN3TpZZTlYepKZcj2chF6IIbjV9Cz82XBST3i4vTwr -i5WY9bPRaM8gFH5MXF/ni+X1NYEZN9cRCLdmvtNKzoNXADrDgfgXy5I2XdGj2HUb4Ysn6npIQf1F -GQatJ5lOwXBH3bWfgVMS5bGMSF0xQxfjjMZ6Y5ZLKTBOhE5iGV48zpeQpX8B653g+IuJ3SWYPZK2 -fu/Z8VFRfS0myGlZYeCsargqNhEEelC9MoS+L9xy1dcdFkfkR2YgP/SWxa+OAXqlD3pk9Q0Yh9mu -iNX6hME6wGkoLfINaFGq46V3xqSQDqE3izEjR8EJCOtu93ib14L8hCCZSRm2Ekax+0VVFqmjZayc -Bw/qa9wfLgZy7IaIEuQt218FL+TwA9MmM+eAws1CoRc0CwIDAQABo0IwQDAPBgNVHRMBAf8EBTAD -AQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUcRVnyMjJvXVdctA4GGqd83EkVAswDQYJKoZI -hvcNAQELBQADggIBAHW7bVRLqhBYRjTyYtcWNl0IXtVsyIe9tC5G8jH4fOpCtZMWVdyhDBKg2mF+ -D1hYc2Ryx+hFjtyp8iY/xnmMsVMIM4GwVhO+5lFc2JsKT0ucVlMC6U/2DWDqTUJV6HwbISHTGzrM -d/K4kPFox/la/vot9L/J9UUbzjgQKjeKeaO04wlshYaT/4mWJ3iBj2fjRnRUjtkNaeJK9E10A/+y -d+2VZ5fkscWrv2oj6NSU4kQoYsRL4vDY4ilrGnB+JGGTe08DMiUNRSQrlrRGar9KC/eaj8GsGsVn -82800vpzY4zvFrCopEYq+OsS7HK07/grfoxSwIuEVPkvPuNVqNxmsdnhX9izjFk0WaSrT2y7Hxjb -davYy5LNlDhhDgcGH0tGEPEVvo2FXDtKK4F5D7Rpn0lQl033DlZdwJVqwjbDG2jJ9SrcR5q+ss7F -Jej6A7na+RZukYT1HCjI/CbM1xyQVqdfbzoEvM14iQuODy+jqk+iGxI9FghAD/FGTNeqewjBCvVt -J94Cj8rDtSvK6evIIVM4pcw72Hc3MKJP2W/R8kCtQXoXxdZKNYm3QdV8hn9VTYNKpXMgwDqvkPGa -JI7ZjnHKe7iG2rKPmT4dEw0SEe7Uq/DpFXYC5ODfqiAeW2GFZECpkJcNrVPSWh2HagCXZWK0vm9q -p/UsQu0yrbYhnr68 ------END CERTIFICATE----- - -Hellenic Academic and Research Institutions ECC RootCA 2015 -=========================================================== ------BEGIN CERTIFICATE----- -MIICwzCCAkqgAwIBAgIBADAKBggqhkjOPQQDAjCBqjELMAkGA1UEBhMCR1IxDzANBgNVBAcTBkF0 -aGVuczFEMEIGA1UEChM7SGVsbGVuaWMgQWNhZGVtaWMgYW5kIFJlc2VhcmNoIEluc3RpdHV0aW9u -cyBDZXJ0LiBBdXRob3JpdHkxRDBCBgNVBAMTO0hlbGxlbmljIEFjYWRlbWljIGFuZCBSZXNlYXJj -aCBJbnN0aXR1dGlvbnMgRUNDIFJvb3RDQSAyMDE1MB4XDTE1MDcwNzEwMzcxMloXDTQwMDYzMDEw -MzcxMlowgaoxCzAJBgNVBAYTAkdSMQ8wDQYDVQQHEwZBdGhlbnMxRDBCBgNVBAoTO0hlbGxlbmlj -IEFjYWRlbWljIGFuZCBSZXNlYXJjaCBJbnN0aXR1dGlvbnMgQ2VydC4gQXV0aG9yaXR5MUQwQgYD -VQQDEztIZWxsZW5pYyBBY2FkZW1pYyBhbmQgUmVzZWFyY2ggSW5zdGl0dXRpb25zIEVDQyBSb290 -Q0EgMjAxNTB2MBAGByqGSM49AgEGBSuBBAAiA2IABJKgQehLgoRc4vgxEZmGZE4JJS+dQS8KrjVP -dJWyUWRrjWvmP3CV8AVER6ZyOFB2lQJajq4onvktTpnvLEhvTCUp6NFxW98dwXU3tNf6e3pCnGoK -Vlp8aQuqgAkkbH7BRqNCMEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0O -BBYEFLQiC4KZJAEOnLvkDv2/+5cgk5kqMAoGCCqGSM49BAMCA2cAMGQCMGfOFmI4oqxiRaeplSTA -GiecMjvAwNW6qef4BENThe5SId6d9SWDPp5YSy/XZxMOIQIwBeF1Ad5o7SofTUwJCA3sS61kFyjn -dc5FZXIhF8siQQ6ME5g4mlRtm8rifOoCWCKR ------END CERTIFICATE----- - -ISRG Root X1 -============ ------BEGIN CERTIFICATE----- -MIIFazCCA1OgAwIBAgIRAIIQz7DSQONZRGPgu2OCiwAwDQYJKoZIhvcNAQELBQAwTzELMAkGA1UE -BhMCVVMxKTAnBgNVBAoTIEludGVybmV0IFNlY3VyaXR5IFJlc2VhcmNoIEdyb3VwMRUwEwYDVQQD -EwxJU1JHIFJvb3QgWDEwHhcNMTUwNjA0MTEwNDM4WhcNMzUwNjA0MTEwNDM4WjBPMQswCQYDVQQG -EwJVUzEpMCcGA1UEChMgSW50ZXJuZXQgU2VjdXJpdHkgUmVzZWFyY2ggR3JvdXAxFTATBgNVBAMT -DElTUkcgUm9vdCBYMTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAK3oJHP0FDfzm54r -Vygch77ct984kIxuPOZXoHj3dcKi/vVqbvYATyjb3miGbESTtrFj/RQSa78f0uoxmyF+0TM8ukj1 -3Xnfs7j/EvEhmkvBioZxaUpmZmyPfjxwv60pIgbz5MDmgK7iS4+3mX6UA5/TR5d8mUgjU+g4rk8K -b4Mu0UlXjIB0ttov0DiNewNwIRt18jA8+o+u3dpjq+sWT8KOEUt+zwvo/7V3LvSye0rgTBIlDHCN -Aymg4VMk7BPZ7hm/ELNKjD+Jo2FR3qyHB5T0Y3HsLuJvW5iB4YlcNHlsdu87kGJ55tukmi8mxdAQ -4Q7e2RCOFvu396j3x+UCB5iPNgiV5+I3lg02dZ77DnKxHZu8A/lJBdiB3QW0KtZB6awBdpUKD9jf -1b0SHzUvKBds0pjBqAlkd25HN7rOrFleaJ1/ctaJxQZBKT5ZPt0m9STJEadao0xAH0ahmbWnOlFu -hjuefXKnEgV4We0+UXgVCwOPjdAvBbI+e0ocS3MFEvzG6uBQE3xDk3SzynTnjh8BCNAw1FtxNrQH -usEwMFxIt4I7mKZ9YIqioymCzLq9gwQbooMDQaHWBfEbwrbwqHyGO0aoSCqI3Haadr8faqU9GY/r -OPNk3sgrDQoo//fb4hVC1CLQJ13hef4Y53CIrU7m2Ys6xt0nUW7/vGT1M0NPAgMBAAGjQjBAMA4G -A1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBR5tFnme7bl5AFzgAiIyBpY -9umbbjANBgkqhkiG9w0BAQsFAAOCAgEAVR9YqbyyqFDQDLHYGmkgJykIrGF1XIpu+ILlaS/V9lZL -ubhzEFnTIZd+50xx+7LSYK05qAvqFyFWhfFQDlnrzuBZ6brJFe+GnY+EgPbk6ZGQ3BebYhtF8GaV -0nxvwuo77x/Py9auJ/GpsMiu/X1+mvoiBOv/2X/qkSsisRcOj/KKNFtY2PwByVS5uCbMiogziUwt -hDyC3+6WVwW6LLv3xLfHTjuCvjHIInNzktHCgKQ5ORAzI4JMPJ+GslWYHb4phowim57iaztXOoJw -TdwJx4nLCgdNbOhdjsnvzqvHu7UrTkXWStAmzOVyyghqpZXjFaH3pO3JLF+l+/+sKAIuvtd7u+Nx -e5AW0wdeRlN8NwdCjNPElpzVmbUq4JUagEiuTDkHzsxHpFKVK7q4+63SM1N95R1NbdWhscdCb+ZA -JzVcoyi3B43njTOQ5yOf+1CceWxG1bQVs5ZufpsMljq4Ui0/1lvh+wjChP4kqKOJ2qxq4RgqsahD -YVvTH9w7jXbyLeiNdd8XM2w9U/t7y0Ff/9yi0GE44Za4rF2LN9d11TPAmRGunUHBcnWEvgJBQl9n -JEiU0Zsnvgc/ubhPgXRR4Xq37Z0j4r7g1SgEEzwxA57demyPxgcYxn/eR44/KJ4EBs+lVDR3veyJ -m+kXQ99b21/+jh5Xos1AnX5iItreGCc= ------END CERTIFICATE----- - -AC RAIZ FNMT-RCM -================ ------BEGIN CERTIFICATE----- -MIIFgzCCA2ugAwIBAgIPXZONMGc2yAYdGsdUhGkHMA0GCSqGSIb3DQEBCwUAMDsxCzAJBgNVBAYT -AkVTMREwDwYDVQQKDAhGTk1ULVJDTTEZMBcGA1UECwwQQUMgUkFJWiBGTk1ULVJDTTAeFw0wODEw -MjkxNTU5NTZaFw0zMDAxMDEwMDAwMDBaMDsxCzAJBgNVBAYTAkVTMREwDwYDVQQKDAhGTk1ULVJD -TTEZMBcGA1UECwwQQUMgUkFJWiBGTk1ULVJDTTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoC -ggIBALpxgHpMhm5/yBNtwMZ9HACXjywMI7sQmkCpGreHiPibVmr75nuOi5KOpyVdWRHbNi63URcf -qQgfBBckWKo3Shjf5TnUV/3XwSyRAZHiItQDwFj8d0fsjz50Q7qsNI1NOHZnjrDIbzAzWHFctPVr -btQBULgTfmxKo0nRIBnuvMApGGWn3v7v3QqQIecaZ5JCEJhfTzC8PhxFtBDXaEAUwED653cXeuYL -j2VbPNmaUtu1vZ5Gzz3rkQUCwJaydkxNEJY7kvqcfw+Z374jNUUeAlz+taibmSXaXvMiwzn15Cou -08YfxGyqxRxqAQVKL9LFwag0Jl1mpdICIfkYtwb1TplvqKtMUejPUBjFd8g5CSxJkjKZqLsXF3mw -WsXmo8RZZUc1g16p6DULmbvkzSDGm0oGObVo/CK67lWMK07q87Hj/LaZmtVC+nFNCM+HHmpxffnT -tOmlcYF7wk5HlqX2doWjKI/pgG6BU6VtX7hI+cL5NqYuSf+4lsKMB7ObiFj86xsc3i1w4peSMKGJ -47xVqCfWS+2QrYv6YyVZLag13cqXM7zlzced0ezvXg5KkAYmY6252TUtB7p2ZSysV4999AeU14EC -ll2jB0nVetBX+RvnU0Z1qrB5QstocQjpYL05ac70r8NWQMetUqIJ5G+GR4of6ygnXYMgrwTJbFaa -i0b1AgMBAAGjgYMwgYAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYE -FPd9xf3E6Jobd2Sn9R2gzL+HYJptMD4GA1UdIAQ3MDUwMwYEVR0gADArMCkGCCsGAQUFBwIBFh1o -dHRwOi8vd3d3LmNlcnQuZm5tdC5lcy9kcGNzLzANBgkqhkiG9w0BAQsFAAOCAgEAB5BK3/MjTvDD -nFFlm5wioooMhfNzKWtN/gHiqQxjAb8EZ6WdmF/9ARP67Jpi6Yb+tmLSbkyU+8B1RXxlDPiyN8+s -D8+Nb/kZ94/sHvJwnvDKuO+3/3Y3dlv2bojzr2IyIpMNOmqOFGYMLVN0V2Ue1bLdI4E7pWYjJ2cJ -j+F3qkPNZVEI7VFY/uY5+ctHhKQV8Xa7pO6kO8Rf77IzlhEYt8llvhjho6Tc+hj507wTmzl6NLrT -Qfv6MooqtyuGC2mDOL7Nii4LcK2NJpLuHvUBKwrZ1pebbuCoGRw6IYsMHkCtA+fdZn71uSANA+iW -+YJF1DngoABd15jmfZ5nc8OaKveri6E6FO80vFIOiZiaBECEHX5FaZNXzuvO+FB8TxxuBEOb+dY7 -Ixjp6o7RTUaN8Tvkasq6+yO3m/qZASlaWFot4/nUbQ4mrcFuNLwy+AwF+mWj2zs3gyLp1txyM/1d -8iC9djwj2ij3+RvrWWTV3F9yfiD8zYm1kGdNYno/Tq0dwzn+evQoFt9B9kiABdcPUXmsEKvU7ANm -5mqwujGSQkBqvjrTcuFqN1W8rB2Vt2lh8kORdOag0wokRqEIr9baRRmW1FMdW4R58MD3R++Lj8UG -rp1MYp3/RgT408m2ECVAdf4WqslKYIYvuu8wd+RU4riEmViAqhOLUTpPSPaLtrM= ------END CERTIFICATE----- - -Amazon Root CA 1 -================ ------BEGIN CERTIFICATE----- -MIIDQTCCAimgAwIBAgITBmyfz5m/jAo54vB4ikPmljZbyjANBgkqhkiG9w0BAQsFADA5MQswCQYD -VQQGEwJVUzEPMA0GA1UEChMGQW1hem9uMRkwFwYDVQQDExBBbWF6b24gUm9vdCBDQSAxMB4XDTE1 -MDUyNjAwMDAwMFoXDTM4MDExNzAwMDAwMFowOTELMAkGA1UEBhMCVVMxDzANBgNVBAoTBkFtYXpv -bjEZMBcGA1UEAxMQQW1hem9uIFJvb3QgQ0EgMTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoC -ggEBALJ4gHHKeNXjca9HgFB0fW7Y14h29Jlo91ghYPl0hAEvrAIthtOgQ3pOsqTQNroBvo3bSMgH -FzZM9O6II8c+6zf1tRn4SWiw3te5djgdYZ6k/oI2peVKVuRF4fn9tBb6dNqcmzU5L/qwIFAGbHrQ -gLKm+a/sRxmPUDgH3KKHOVj4utWp+UhnMJbulHheb4mjUcAwhmahRWa6VOujw5H5SNz/0egwLX0t -dHA114gk957EWW67c4cX8jJGKLhD+rcdqsq08p8kDi1L93FcXmn/6pUCyziKrlA4b9v7LWIbxcce -VOF34GfID5yHI9Y/QCB/IIDEgEw+OyQmjgSubJrIqg0CAwEAAaNCMEAwDwYDVR0TAQH/BAUwAwEB -/zAOBgNVHQ8BAf8EBAMCAYYwHQYDVR0OBBYEFIQYzIU07LwMlJQuCFmcx7IQTgoIMA0GCSqGSIb3 -DQEBCwUAA4IBAQCY8jdaQZChGsV2USggNiMOruYou6r4lK5IpDB/G/wkjUu0yKGX9rbxenDIU5PM -CCjjmCXPI6T53iHTfIUJrU6adTrCC2qJeHZERxhlbI1Bjjt/msv0tadQ1wUsN+gDS63pYaACbvXy -8MWy7Vu33PqUXHeeE6V/Uq2V8viTO96LXFvKWlJbYK8U90vvo/ufQJVtMVT8QtPHRh8jrdkPSHCa -2XV4cdFyQzR1bldZwgJcJmApzyMZFo6IQ6XU5MsI+yMRQ+hDKXJioaldXgjUkK642M4UwtBV8ob2 -xJNDd2ZhwLnoQdeXeGADbkpyrqXRfboQnoZsG4q5WTP468SQvvG5 ------END CERTIFICATE----- - -Amazon Root CA 2 -================ ------BEGIN CERTIFICATE----- -MIIFQTCCAymgAwIBAgITBmyf0pY1hp8KD+WGePhbJruKNzANBgkqhkiG9w0BAQwFADA5MQswCQYD -VQQGEwJVUzEPMA0GA1UEChMGQW1hem9uMRkwFwYDVQQDExBBbWF6b24gUm9vdCBDQSAyMB4XDTE1 -MDUyNjAwMDAwMFoXDTQwMDUyNjAwMDAwMFowOTELMAkGA1UEBhMCVVMxDzANBgNVBAoTBkFtYXpv -bjEZMBcGA1UEAxMQQW1hem9uIFJvb3QgQ0EgMjCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoC -ggIBAK2Wny2cSkxKgXlRmeyKy2tgURO8TW0G/LAIjd0ZEGrHJgw12MBvIITplLGbhQPDW9tK6Mj4 -kHbZW0/jTOgGNk3Mmqw9DJArktQGGWCsN0R5hYGCrVo34A3MnaZMUnbqQ523BNFQ9lXg1dKmSYXp -N+nKfq5clU1Imj+uIFptiJXZNLhSGkOQsL9sBbm2eLfq0OQ6PBJTYv9K8nu+NQWpEjTj82R0Yiw9 -AElaKP4yRLuH3WUnAnE72kr3H9rN9yFVkE8P7K6C4Z9r2UXTu/Bfh+08LDmG2j/e7HJV63mjrdvd -fLC6HM783k81ds8P+HgfajZRRidhW+mez/CiVX18JYpvL7TFz4QuK/0NURBs+18bvBt+xa47mAEx -kv8LV/SasrlX6avvDXbR8O70zoan4G7ptGmh32n2M8ZpLpcTnqWHsFcQgTfJU7O7f/aS0ZzQGPSS -btqDT6ZjmUyl+17vIWR6IF9sZIUVyzfpYgwLKhbcAS4y2j5L9Z469hdAlO+ekQiG+r5jqFoz7Mt0 -Q5X5bGlSNscpb/xVA1wf+5+9R+vnSUeVC06JIglJ4PVhHvG/LopyboBZ/1c6+XUyo05f7O0oYtlN -c/LMgRdg7c3r3NunysV+Ar3yVAhU/bQtCSwXVEqY0VThUWcI0u1ufm8/0i2BWSlmy5A5lREedCf+ -3euvAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMB0GA1UdDgQWBBSw -DPBMMPQFWAJI/TPlUq9LhONmUjANBgkqhkiG9w0BAQwFAAOCAgEAqqiAjw54o+Ci1M3m9Zh6O+oA -A7CXDpO8Wqj2LIxyh6mx/H9z/WNxeKWHWc8w4Q0QshNabYL1auaAn6AFC2jkR2vHat+2/XcycuUY -+gn0oJMsXdKMdYV2ZZAMA3m3MSNjrXiDCYZohMr/+c8mmpJ5581LxedhpxfL86kSk5Nrp+gvU5LE -YFiwzAJRGFuFjWJZY7attN6a+yb3ACfAXVU3dJnJUH/jWS5E4ywl7uxMMne0nxrpS10gxdr9HIcW -xkPo1LsmmkVwXqkLN1PiRnsn/eBG8om3zEK2yygmbtmlyTrIQRNg91CMFa6ybRoVGld45pIq2WWQ -gj9sAq+uEjonljYE1x2igGOpm/HlurR8FLBOybEfdF849lHqm/osohHUqS0nGkWxr7JOcQ3AWEbW -aQbLU8uz/mtBzUF+fUwPfHJ5elnNXkoOrJupmHN5fLT0zLm4BwyydFy4x2+IoZCn9Kr5v2c69BoV -Yh63n749sSmvZ6ES8lgQGVMDMBu4Gon2nL2XA46jCfMdiyHxtN/kHNGfZQIG6lzWE7OE76KlXIx3 -KadowGuuQNKotOrN8I1LOJwZmhsoVLiJkO/KdYE+HvJkJMcYr07/R54H9jVlpNMKVv/1F2Rs76gi -JUmTtt8AF9pYfl3uxRuw0dFfIRDH+fO6AgonB8Xx1sfT4PsJYGw= ------END CERTIFICATE----- - -Amazon Root CA 3 -================ ------BEGIN CERTIFICATE----- -MIIBtjCCAVugAwIBAgITBmyf1XSXNmY/Owua2eiedgPySjAKBggqhkjOPQQDAjA5MQswCQYDVQQG -EwJVUzEPMA0GA1UEChMGQW1hem9uMRkwFwYDVQQDExBBbWF6b24gUm9vdCBDQSAzMB4XDTE1MDUy -NjAwMDAwMFoXDTQwMDUyNjAwMDAwMFowOTELMAkGA1UEBhMCVVMxDzANBgNVBAoTBkFtYXpvbjEZ -MBcGA1UEAxMQQW1hem9uIFJvb3QgQ0EgMzBZMBMGByqGSM49AgEGCCqGSM49AwEHA0IABCmXp8ZB -f8ANm+gBG1bG8lKlui2yEujSLtf6ycXYqm0fc4E7O5hrOXwzpcVOho6AF2hiRVd9RFgdszflZwjr -Zt6jQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMB0GA1UdDgQWBBSrttvXBp43 -rDCGB5Fwx5zEGbF4wDAKBggqhkjOPQQDAgNJADBGAiEA4IWSoxe3jfkrBqWTrBqYaGFy+uGh0Psc -eGCmQ5nFuMQCIQCcAu/xlJyzlvnrxir4tiz+OpAUFteMYyRIHN8wfdVoOw== ------END CERTIFICATE----- - -Amazon Root CA 4 -================ ------BEGIN CERTIFICATE----- -MIIB8jCCAXigAwIBAgITBmyf18G7EEwpQ+Vxe3ssyBrBDjAKBggqhkjOPQQDAzA5MQswCQYDVQQG -EwJVUzEPMA0GA1UEChMGQW1hem9uMRkwFwYDVQQDExBBbWF6b24gUm9vdCBDQSA0MB4XDTE1MDUy -NjAwMDAwMFoXDTQwMDUyNjAwMDAwMFowOTELMAkGA1UEBhMCVVMxDzANBgNVBAoTBkFtYXpvbjEZ -MBcGA1UEAxMQQW1hem9uIFJvb3QgQ0EgNDB2MBAGByqGSM49AgEGBSuBBAAiA2IABNKrijdPo1MN -/sGKe0uoe0ZLY7Bi9i0b2whxIdIA6GO9mif78DluXeo9pcmBqqNbIJhFXRbb/egQbeOc4OO9X4Ri -83BkM6DLJC9wuoihKqB1+IGuYgbEgds5bimwHvouXKNCMEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNV -HQ8BAf8EBAMCAYYwHQYDVR0OBBYEFNPsxzplbszh2naaVvuc84ZtV+WBMAoGCCqGSM49BAMDA2gA -MGUCMDqLIfG9fhGt0O9Yli/W651+kI0rz2ZVwyzjKKlwCkcO8DdZEv8tmZQoTipPNU0zWgIxAOp1 -AE47xDqUEpHJWEadIRNyp4iciuRMStuW1KyLa2tJElMzrdfkviT8tQp21KW8EA== ------END CERTIFICATE----- - -LuxTrust Global Root 2 -====================== ------BEGIN CERTIFICATE----- -MIIFwzCCA6ugAwIBAgIUCn6m30tEntpqJIWe5rgV0xZ/u7EwDQYJKoZIhvcNAQELBQAwRjELMAkG -A1UEBhMCTFUxFjAUBgNVBAoMDUx1eFRydXN0IFMuQS4xHzAdBgNVBAMMFkx1eFRydXN0IEdsb2Jh -bCBSb290IDIwHhcNMTUwMzA1MTMyMTU3WhcNMzUwMzA1MTMyMTU3WjBGMQswCQYDVQQGEwJMVTEW -MBQGA1UECgwNTHV4VHJ1c3QgUy5BLjEfMB0GA1UEAwwWTHV4VHJ1c3QgR2xvYmFsIFJvb3QgMjCC -AiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBANeFl78RmOnwYoNMPIf5U2o3C/IPPIfOb9wm -Kb3FibrJgz337spbxm1Jc7TJRqMbNBM/wYlFV/TZsfs2ZUv7COJIcRHIbjuend+JZTemhfY7RBi2 -xjcwYkSSl2l9QjAk5A0MiWtj3sXh306pFGxT4GHO9hcvHTy95iJMHZP1EMShduxq3sVs35a0VkBC -wGKSMKEtFZSg0iAGCW5qbeXrt77U8PEVfIvmTroTzEsnXpk8F12PgX8zPU/TPxvsXD/wPEx1bvKm -1Z3aLQdjAsZy6ZS8TEmVT4hSyNvoaYL4zDRbIvCGp4m9SAptZoFtyMhk+wHh9OHe2Z7d21vUKpkm -FRseTJIpgp7VkoGSQXAZ96Tlk0u8d2cx3Rz9MXANF5kM+Qw5GSoXtTBxVdUPrljhPS80m8+f9niF -wpN6cj5mj5wWEWCPnolvZ77gR1o7DJpni89Gxq44o/KnvObWhWszJHAiS8sIm7vI+AIpHb4gDEa/ -a4ebsypmQjVGbKq6rfmYe+lQVRQxv7HaLe2ArWgk+2mr2HETMOZns4dA/Yl+8kPREd8vZS9kzl8U -ubG/Mb2HeFpZZYiq/FkySIbWTLkpS5XTdvN3JW1CHDiDTf2jX5t/Lax5Gw5CMZdjpPuKadUiDTSQ -MC6otOBttpSsvItO13D8xTiOZCXhTTmQzsmHhFhxAgMBAAGjgagwgaUwDwYDVR0TAQH/BAUwAwEB -/zBCBgNVHSAEOzA5MDcGByuBKwEBAQowLDAqBggrBgEFBQcCARYeaHR0cHM6Ly9yZXBvc2l0b3J5 -Lmx1eHRydXN0Lmx1MA4GA1UdDwEB/wQEAwIBBjAfBgNVHSMEGDAWgBT/GCh2+UgFLKGu8SsbK7JT -+Et8szAdBgNVHQ4EFgQU/xgodvlIBSyhrvErGyuyU/hLfLMwDQYJKoZIhvcNAQELBQADggIBAGoZ -FO1uecEsh9QNcH7X9njJCwROxLHOk3D+sFTAMs2ZMGQXvw/l4jP9BzZAcg4atmpZ1gDlaCDdLnIN -H2pkMSCEfUmmWjfrRcmF9dTHF5kH5ptV5AzoqbTOjFu1EVzPig4N1qx3gf4ynCSecs5U89BvolbW -7MM3LGVYvlcAGvI1+ut7MV3CwRI9loGIlonBWVx65n9wNOeD4rHh4bhY79SV5GCc8JaXcozrhAIu -ZY+kt9J/Z93I055cqqmkoCUUBpvsT34tC38ddfEz2O3OuHVtPlu5mB0xDVbYQw8wkbIEa91WvpWA -VWe+2M2D2RjuLg+GLZKecBPs3lHJQ3gCpU3I+V/EkVhGFndadKpAvAefMLmx9xIX3eP/JEAdemrR -TxgKqpAd60Ae36EeRJIQmvKN4dFLRp7oRUKX6kWZ8+xm1QL68qZKJKrezrnK+T+Tb/mjuuqlPpmt -/f97mfVl7vBZKGfXkJWkE4SphMHozs51k2MavDzq1WQfLSoSOcbDWjLtR5EWDrw4wVDej8oqkDQc -7kGUnF4ZLvhFSZl0kbAEb+MEWrGrKqv+x9CWttrhSmQGbmBNvUJO/3jaJMobtNeWOWyu8Q6qp31I -iyBMz2TWuJdGsE7RKlY6oJO9r4Ak4Ap+58rVyuiFVdw2KuGUaJPHZnJED4AhMmwlxyOAgwrr ------END CERTIFICATE----- - -TUBITAK Kamu SM SSL Kok Sertifikasi - Surum 1 -============================================= ------BEGIN CERTIFICATE----- -MIIEYzCCA0ugAwIBAgIBATANBgkqhkiG9w0BAQsFADCB0jELMAkGA1UEBhMCVFIxGDAWBgNVBAcT -D0dlYnplIC0gS29jYWVsaTFCMEAGA1UEChM5VHVya2l5ZSBCaWxpbXNlbCB2ZSBUZWtub2xvamlr -IEFyYXN0aXJtYSBLdXJ1bXUgLSBUVUJJVEFLMS0wKwYDVQQLEyRLYW11IFNlcnRpZmlrYXN5b24g -TWVya2V6aSAtIEthbXUgU00xNjA0BgNVBAMTLVRVQklUQUsgS2FtdSBTTSBTU0wgS29rIFNlcnRp -ZmlrYXNpIC0gU3VydW0gMTAeFw0xMzExMjUwODI1NTVaFw00MzEwMjUwODI1NTVaMIHSMQswCQYD -VQQGEwJUUjEYMBYGA1UEBxMPR2ViemUgLSBLb2NhZWxpMUIwQAYDVQQKEzlUdXJraXllIEJpbGlt -c2VsIHZlIFRla25vbG9qaWsgQXJhc3Rpcm1hIEt1cnVtdSAtIFRVQklUQUsxLTArBgNVBAsTJEth -bXUgU2VydGlmaWthc3lvbiBNZXJrZXppIC0gS2FtdSBTTTE2MDQGA1UEAxMtVFVCSVRBSyBLYW11 -IFNNIFNTTCBLb2sgU2VydGlmaWthc2kgLSBTdXJ1bSAxMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8A -MIIBCgKCAQEAr3UwM6q7a9OZLBI3hNmNe5eA027n/5tQlT6QlVZC1xl8JoSNkvoBHToP4mQ4t4y8 -6Ij5iySrLqP1N+RAjhgleYN1Hzv/bKjFxlb4tO2KRKOrbEz8HdDc72i9z+SqzvBV96I01INrN3wc -wv61A+xXzry0tcXtAA9TNypN9E8Mg/uGz8v+jE69h/mniyFXnHrfA2eJLJ2XYacQuFWQfw4tJzh0 -3+f92k4S400VIgLI4OD8D62K18lUUMw7D8oWgITQUVbDjlZ/iSIzL+aFCr2lqBs23tPcLG07xxO9 -WSMs5uWk99gL7eqQQESolbuT1dCANLZGeA4fAJNG4e7p+exPFwIDAQABo0IwQDAdBgNVHQ4EFgQU -ZT/HiobGPN08VFw1+DrtUgxHV8gwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wDQYJ -KoZIhvcNAQELBQADggEBACo/4fEyjq7hmFxLXs9rHmoJ0iKpEsdeV31zVmSAhHqT5Am5EM2fKifh -AHe+SMg1qIGf5LgsyX8OsNJLN13qudULXjS99HMpw+0mFZx+CFOKWI3QSyjfwbPfIPP54+M638yc -lNhOT8NrF7f3cuitZjO1JVOr4PhMqZ398g26rrnZqsZr+ZO7rqu4lzwDGrpDxpa5RXI4s6ehlj2R -e37AIVNMh+3yC1SVUZPVIqUNivGTDj5UDrDYyU7c8jEyVupk+eq1nRZmQnLzf9OxMUP8pI4X8W0j -q5Rm+K37DwhuJi1/FwcJsoz7UMCflo3Ptv0AnVoUmr8CRPXBwp8iXqIPoeM= ------END CERTIFICATE----- - -GDCA TrustAUTH R5 ROOT -====================== ------BEGIN CERTIFICATE----- -MIIFiDCCA3CgAwIBAgIIfQmX/vBH6nowDQYJKoZIhvcNAQELBQAwYjELMAkGA1UEBhMCQ04xMjAw -BgNVBAoMKUdVQU5HIERPTkcgQ0VSVElGSUNBVEUgQVVUSE9SSVRZIENPLixMVEQuMR8wHQYDVQQD -DBZHRENBIFRydXN0QVVUSCBSNSBST09UMB4XDTE0MTEyNjA1MTMxNVoXDTQwMTIzMTE1NTk1OVow -YjELMAkGA1UEBhMCQ04xMjAwBgNVBAoMKUdVQU5HIERPTkcgQ0VSVElGSUNBVEUgQVVUSE9SSVRZ -IENPLixMVEQuMR8wHQYDVQQDDBZHRENBIFRydXN0QVVUSCBSNSBST09UMIICIjANBgkqhkiG9w0B -AQEFAAOCAg8AMIICCgKCAgEA2aMW8Mh0dHeb7zMNOwZ+Vfy1YI92hhJCfVZmPoiC7XJjDp6L3TQs -AlFRwxn9WVSEyfFrs0yw6ehGXTjGoqcuEVe6ghWinI9tsJlKCvLriXBjTnnEt1u9ol2x8kECK62p -OqPseQrsXzrj/e+APK00mxqriCZ7VqKChh/rNYmDf1+uKU49tm7srsHwJ5uu4/Ts765/94Y9cnrr -pftZTqfrlYwiOXnhLQiPzLyRuEH3FMEjqcOtmkVEs7LXLM3GKeJQEK5cy4KOFxg2fZfmiJqwTTQJ -9Cy5WmYqsBebnh52nUpmMUHfP/vFBu8btn4aRjb3ZGM74zkYI+dndRTVdVeSN72+ahsmUPI2JgaQ -xXABZG12ZuGR224HwGGALrIuL4xwp9E7PLOR5G62xDtw8mySlwnNR30YwPO7ng/Wi64HtloPzgsM -R6flPri9fcebNaBhlzpBdRfMK5Z3KpIhHtmVdiBnaM8Nvd/WHwlqmuLMc3GkL30SgLdTMEZeS1SZ -D2fJpcjyIMGC7J0R38IC+xo70e0gmu9lZJIQDSri3nDxGGeCjGHeuLzRL5z7D9Ar7Rt2ueQ5Vfj4 -oR24qoAATILnsn8JuLwwoC8N9VKejveSswoAHQBUlwbgsQfZxw9cZX08bVlX5O2ljelAU58VS6Bx -9hoh49pwBiFYFIeFd3mqgnkCAwEAAaNCMEAwHQYDVR0OBBYEFOLJQJ9NzuiaoXzPDj9lxSmIahlR -MA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMA0GCSqGSIb3DQEBCwUAA4ICAQDRSVfg -p8xoWLoBDysZzY2wYUWsEe1jUGn4H3++Fo/9nesLqjJHdtJnJO29fDMylyrHBYZmDRd9FBUb1Ov9 -H5r2XpdptxolpAqzkT9fNqyL7FeoPueBihhXOYV0GkLH6VsTX4/5COmSdI31R9KrO9b7eGZONn35 -6ZLpBN79SWP8bfsUcZNnL0dKt7n/HipzcEYwv1ryL3ml4Y0M2fmyYzeMN2WFcGpcWwlyua1jPLHd -+PwyvzeG5LuOmCd+uh8W4XAR8gPfJWIyJyYYMoSf/wA6E7qaTfRPuBRwIrHKK5DOKcFw9C+df/KQ -HtZa37dG/OaG+svgIHZ6uqbL9XzeYqWxi+7egmaKTjowHz+Ay60nugxe19CxVsp3cbK1daFQqUBD -F8Io2c9Si1vIY9RCPqAzekYu9wogRlR+ak8x8YF+QnQ4ZXMn7sZ8uI7XpTrXmKGcjBBV09tL7ECQ -8s1uV9JiDnxXk7Gnbc2dg7sq5+W2O3FYrf3RRbxake5TFW/TRQl1brqQXR4EzzffHqhmsYzmIGrv -/EhOdJhCrylvLmrH+33RZjEizIYAfmaDDEL0vTSSwxrqT8p+ck0LcIymSLumoRT2+1hEmRSuqguT -aaApJUqlyyvdimYHFngVV3Eb7PVHhPOeMTd61X8kreS8/f3MboPoDKi3QWwH3b08hpcv0g== ------END CERTIFICATE----- - -TrustCor RootCert CA-1 -====================== ------BEGIN CERTIFICATE----- -MIIEMDCCAxigAwIBAgIJANqb7HHzA7AZMA0GCSqGSIb3DQEBCwUAMIGkMQswCQYDVQQGEwJQQTEP -MA0GA1UECAwGUGFuYW1hMRQwEgYDVQQHDAtQYW5hbWEgQ2l0eTEkMCIGA1UECgwbVHJ1c3RDb3Ig -U3lzdGVtcyBTLiBkZSBSLkwuMScwJQYDVQQLDB5UcnVzdENvciBDZXJ0aWZpY2F0ZSBBdXRob3Jp -dHkxHzAdBgNVBAMMFlRydXN0Q29yIFJvb3RDZXJ0IENBLTEwHhcNMTYwMjA0MTIzMjE2WhcNMjkx -MjMxMTcyMzE2WjCBpDELMAkGA1UEBhMCUEExDzANBgNVBAgMBlBhbmFtYTEUMBIGA1UEBwwLUGFu -YW1hIENpdHkxJDAiBgNVBAoMG1RydXN0Q29yIFN5c3RlbXMgUy4gZGUgUi5MLjEnMCUGA1UECwwe -VHJ1c3RDb3IgQ2VydGlmaWNhdGUgQXV0aG9yaXR5MR8wHQYDVQQDDBZUcnVzdENvciBSb290Q2Vy -dCBDQS0xMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAv463leLCJhJrMxnHQFgKq1mq -jQCj/IDHUHuO1CAmujIS2CNUSSUQIpidRtLByZ5OGy4sDjjzGiVoHKZaBeYei0i/mJZ0PmnK6bV4 -pQa81QBeCQryJ3pS/C3Vseq0iWEk8xoT26nPUu0MJLq5nux+AHT6k61sKZKuUbS701e/s/OojZz0 -JEsq1pme9J7+wH5COucLlVPat2gOkEz7cD+PSiyU8ybdY2mplNgQTsVHCJCZGxdNuWxu72CVEY4h -gLW9oHPY0LJ3xEXqWib7ZnZ2+AYfYW0PVcWDtxBWcgYHpfOxGgMFZA6dWorWhnAbJN7+KIor0Gqw -/Hqi3LJ5DotlDwIDAQABo2MwYTAdBgNVHQ4EFgQU7mtJPHo/DeOxCbeKyKsZn3MzUOcwHwYDVR0j -BBgwFoAU7mtJPHo/DeOxCbeKyKsZn3MzUOcwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMC -AYYwDQYJKoZIhvcNAQELBQADggEBACUY1JGPE+6PHh0RU9otRCkZoB5rMZ5NDp6tPVxBb5UrJKF5 -mDo4Nvu7Zp5I/5CQ7z3UuJu0h3U/IJvOcs+hVcFNZKIZBqEHMwwLKeXx6quj7LUKdJDHfXLy11yf -ke+Ri7fc7Waiz45mO7yfOgLgJ90WmMCV1Aqk5IGadZQ1nJBfiDcGrVmVCrDRZ9MZyonnMlo2HD6C -qFqTvsbQZJG2z9m2GM/bftJlo6bEjhcxwft+dtvTheNYsnd6djtsL1Ac59v2Z3kf9YKVmgenFK+P -3CghZwnS1k1aHBkcjndcw5QkPTJrS37UeJSDvjdNzl/HHk484IkzlQsPpTLWPFp5LBk= ------END CERTIFICATE----- - -TrustCor RootCert CA-2 -====================== ------BEGIN CERTIFICATE----- -MIIGLzCCBBegAwIBAgIIJaHfyjPLWQIwDQYJKoZIhvcNAQELBQAwgaQxCzAJBgNVBAYTAlBBMQ8w -DQYDVQQIDAZQYW5hbWExFDASBgNVBAcMC1BhbmFtYSBDaXR5MSQwIgYDVQQKDBtUcnVzdENvciBT -eXN0ZW1zIFMuIGRlIFIuTC4xJzAlBgNVBAsMHlRydXN0Q29yIENlcnRpZmljYXRlIEF1dGhvcml0 -eTEfMB0GA1UEAwwWVHJ1c3RDb3IgUm9vdENlcnQgQ0EtMjAeFw0xNjAyMDQxMjMyMjNaFw0zNDEy -MzExNzI2MzlaMIGkMQswCQYDVQQGEwJQQTEPMA0GA1UECAwGUGFuYW1hMRQwEgYDVQQHDAtQYW5h -bWEgQ2l0eTEkMCIGA1UECgwbVHJ1c3RDb3IgU3lzdGVtcyBTLiBkZSBSLkwuMScwJQYDVQQLDB5U -cnVzdENvciBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkxHzAdBgNVBAMMFlRydXN0Q29yIFJvb3RDZXJ0 -IENBLTIwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCnIG7CKqJiJJWQdsg4foDSq8Gb -ZQWU9MEKENUCrO2fk8eHyLAnK0IMPQo+QVqedd2NyuCb7GgypGmSaIwLgQ5WoD4a3SwlFIIvl9Nk -RvRUqdw6VC0xK5mC8tkq1+9xALgxpL56JAfDQiDyitSSBBtlVkxs1Pu2YVpHI7TYabS3OtB0PAx1 -oYxOdqHp2yqlO/rOsP9+aij9JxzIsekp8VduZLTQwRVtDr4uDkbIXvRR/u8OYzo7cbrPb1nKDOOb -XUm4TOJXsZiKQlecdu/vvdFoqNL0Cbt3Nb4lggjEFixEIFapRBF37120Hapeaz6LMvYHL1cEksr1 -/p3C6eizjkxLAjHZ5DxIgif3GIJ2SDpxsROhOdUuxTTCHWKF3wP+TfSvPd9cW436cOGlfifHhi5q -jxLGhF5DUVCcGZt45vz27Ud+ez1m7xMTiF88oWP7+ayHNZ/zgp6kPwqcMWmLmaSISo5uZk3vFsQP -eSghYA2FFn3XVDjxklb9tTNMg9zXEJ9L/cb4Qr26fHMC4P99zVvh1Kxhe1fVSntb1IVYJ12/+Ctg -rKAmrhQhJ8Z3mjOAPF5GP/fDsaOGM8boXg25NSyqRsGFAnWAoOsk+xWq5Gd/bnc/9ASKL3x74xdh -8N0JqSDIvgmk0H5Ew7IwSjiqqewYmgeCK9u4nBit2uBGF6zPXQIDAQABo2MwYTAdBgNVHQ4EFgQU -2f4hQG6UnrybPZx9mCAZ5YwwYrIwHwYDVR0jBBgwFoAU2f4hQG6UnrybPZx9mCAZ5YwwYrIwDwYD -VR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAYYwDQYJKoZIhvcNAQELBQADggIBAJ5Fngw7tu/h -Osh80QA9z+LqBrWyOrsGS2h60COXdKcs8AjYeVrXWoSK2BKaG9l9XE1wxaX5q+WjiYndAfrs3fnp -kpfbsEZC89NiqpX+MWcUaViQCqoL7jcjx1BRtPV+nuN79+TMQjItSQzL/0kMmx40/W5ulop5A7Zv -2wnL/V9lFDfhOPXzYRZY5LVtDQsEGz9QLX+zx3oaFoBg+Iof6Rsqxvm6ARppv9JYx1RXCI/hOWB3 -S6xZhBqI8d3LT3jX5+EzLfzuQfogsL7L9ziUwOHQhQ+77Sxzq+3+knYaZH9bDTMJBzN7Bj8RpFxw -PIXAz+OQqIN3+tvmxYxoZxBnpVIt8MSZj3+/0WvitUfW2dCFmU2Umw9Lje4AWkcdEQOsQRivh7dv -DDqPys/cA8GiCcjl/YBeyGBCARsaU1q7N6a3vLqE6R5sGtRk2tRD/pOLS/IseRYQ1JMLiI+h2IYU -RpFHmygk71dSTlxCnKr3Sewn6EAes6aJInKc9Q0ztFijMDvd1GpUk74aTfOTlPf8hAs/hCBcNANE -xdqtvArBAs8e5ZTZ845b2EzwnexhF7sUMlQMAimTHpKG9n/v55IFDlndmQguLvqcAFLTxWYp5KeX -RKQOKIETNcX2b2TmQcTVL8w0RSXPQQCWPUouwpaYT05KnJe32x+SMsj/D1Fu1uwJ ------END CERTIFICATE----- - -TrustCor ECA-1 -============== ------BEGIN CERTIFICATE----- -MIIEIDCCAwigAwIBAgIJAISCLF8cYtBAMA0GCSqGSIb3DQEBCwUAMIGcMQswCQYDVQQGEwJQQTEP -MA0GA1UECAwGUGFuYW1hMRQwEgYDVQQHDAtQYW5hbWEgQ2l0eTEkMCIGA1UECgwbVHJ1c3RDb3Ig -U3lzdGVtcyBTLiBkZSBSLkwuMScwJQYDVQQLDB5UcnVzdENvciBDZXJ0aWZpY2F0ZSBBdXRob3Jp -dHkxFzAVBgNVBAMMDlRydXN0Q29yIEVDQS0xMB4XDTE2MDIwNDEyMzIzM1oXDTI5MTIzMTE3Mjgw -N1owgZwxCzAJBgNVBAYTAlBBMQ8wDQYDVQQIDAZQYW5hbWExFDASBgNVBAcMC1BhbmFtYSBDaXR5 -MSQwIgYDVQQKDBtUcnVzdENvciBTeXN0ZW1zIFMuIGRlIFIuTC4xJzAlBgNVBAsMHlRydXN0Q29y -IENlcnRpZmljYXRlIEF1dGhvcml0eTEXMBUGA1UEAwwOVHJ1c3RDb3IgRUNBLTEwggEiMA0GCSqG -SIb3DQEBAQUAA4IBDwAwggEKAoIBAQDPj+ARtZ+odnbb3w9U73NjKYKtR8aja+3+XzP4Q1HpGjOR -MRegdMTUpwHmspI+ap3tDvl0mEDTPwOABoJA6LHip1GnHYMma6ve+heRK9jGrB6xnhkB1Zem6g23 -xFUfJ3zSCNV2HykVh0A53ThFEXXQmqc04L/NyFIduUd+Dbi7xgz2c1cWWn5DkR9VOsZtRASqnKmc -p0yJF4OuowReUoCLHhIlERnXDH19MURB6tuvsBzvgdAsxZohmz3tQjtQJvLsznFhBmIhVE5/wZ0+ -fyCMgMsq2JdiyIMzkX2woloPV+g7zPIlstR8L+xNxqE6FXrntl019fZISjZFZtS6mFjBAgMBAAGj -YzBhMB0GA1UdDgQWBBREnkj1zG1I1KBLf/5ZJC+Dl5mahjAfBgNVHSMEGDAWgBREnkj1zG1I1KBL -f/5ZJC+Dl5mahjAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBhjANBgkqhkiG9w0BAQsF -AAOCAQEABT41XBVwm8nHc2FvcivUwo/yQ10CzsSUuZQRg2dd4mdsdXa/uwyqNsatR5Nj3B5+1t4u -/ukZMjgDfxT2AHMsWbEhBuH7rBiVDKP/mZb3Kyeb1STMHd3BOuCYRLDE5D53sXOpZCz2HAF8P11F -hcCF5yWPldwX8zyfGm6wyuMdKulMY/okYWLW2n62HGz1Ah3UKt1VkOsqEUc8Ll50soIipX1TH0Xs -J5F95yIW6MBoNtjG8U+ARDL54dHRHareqKucBK+tIA5kmE2la8BIWJZpTdwHjFGTot+fDz2LYLSC -jaoITmJF4PkL0uDgPFveXHEnJcLmA4GLEFPjx1WitJ/X5g== ------END CERTIFICATE----- - -SSL.com Root Certification Authority RSA -======================================== ------BEGIN CERTIFICATE----- -MIIF3TCCA8WgAwIBAgIIeyyb0xaAMpkwDQYJKoZIhvcNAQELBQAwfDELMAkGA1UEBhMCVVMxDjAM -BgNVBAgMBVRleGFzMRAwDgYDVQQHDAdIb3VzdG9uMRgwFgYDVQQKDA9TU0wgQ29ycG9yYXRpb24x -MTAvBgNVBAMMKFNTTC5jb20gUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSBSU0EwHhcNMTYw -MjEyMTczOTM5WhcNNDEwMjEyMTczOTM5WjB8MQswCQYDVQQGEwJVUzEOMAwGA1UECAwFVGV4YXMx -EDAOBgNVBAcMB0hvdXN0b24xGDAWBgNVBAoMD1NTTCBDb3Jwb3JhdGlvbjExMC8GA1UEAwwoU1NM -LmNvbSBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IFJTQTCCAiIwDQYJKoZIhvcNAQEBBQAD -ggIPADCCAgoCggIBAPkP3aMrfcvQKv7sZ4Wm5y4bunfh4/WvpOz6Sl2RxFdHaxh3a3by/ZPkPQ/C -Fp4LZsNWlJ4Xg4XOVu/yFv0AYvUiCVToZRdOQbngT0aXqhvIuG5iXmmxX9sqAn78bMrzQdjt0Oj8 -P2FI7bADFB0QDksZ4LtO7IZl/zbzXmcCC52GVWH9ejjt/uIZALdvoVBidXQ8oPrIJZK0bnoix/ge -oeOy3ZExqysdBP+lSgQ36YWkMyv94tZVNHwZpEpox7Ko07fKoZOI68GXvIz5HdkihCR0xwQ9aqkp -k8zruFvh/l8lqjRYyMEjVJ0bmBHDOJx+PYZspQ9AhnwC9FwCTyjLrnGfDzrIM/4RJTXq/LrFYD3Z -fBjVsqnTdXgDciLKOsMf7yzlLqn6niy2UUb9rwPW6mBo6oUWNmuF6R7As93EJNyAKoFBbZQ+yODJ -gUEAnl6/f8UImKIYLEJAs/lvOCdLToD0PYFH4Ih86hzOtXVcUS4cK38acijnALXRdMbX5J+tB5O2 -UzU1/Dfkw/ZdFr4hc96SCvigY2q8lpJqPvi8ZVWb3vUNiSYE/CUapiVpy8JtynziWV+XrOvvLsi8 -1xtZPCvM8hnIk2snYxnP/Okm+Mpxm3+T/jRnhE6Z6/yzeAkzcLpmpnbtG3PrGqUNxCITIJRWCk4s -bE6x/c+cCbqiM+2HAgMBAAGjYzBhMB0GA1UdDgQWBBTdBAkHovV6fVJTEpKV7jiAJQ2mWTAPBgNV -HRMBAf8EBTADAQH/MB8GA1UdIwQYMBaAFN0ECQei9Xp9UlMSkpXuOIAlDaZZMA4GA1UdDwEB/wQE -AwIBhjANBgkqhkiG9w0BAQsFAAOCAgEAIBgRlCn7Jp0cHh5wYfGVcpNxJK1ok1iOMq8bs3AD/CUr -dIWQPXhq9LmLpZc7tRiRux6n+UBbkflVma8eEdBcHadm47GUBwwyOabqG7B52B2ccETjit3E+ZUf -ijhDPwGFpUenPUayvOUiaPd7nNgsPgohyC0zrL/FgZkxdMF1ccW+sfAjRfSda/wZY52jvATGGAsl -u1OJD7OAUN5F7kR/q5R4ZJjT9ijdh9hwZXT7DrkT66cPYakylszeu+1jTBi7qUD3oFRuIIhxdRjq -erQ0cuAjJ3dctpDqhiVAq+8zD8ufgr6iIPv2tS0a5sKFsXQP+8hlAqRSAUfdSSLBv9jra6x+3uxj -MxW3IwiPxg+NQVrdjsW5j+VFP3jbutIbQLH+cU0/4IGiul607BXgk90IH37hVZkLId6Tngr75qNJ -vTYw/ud3sqB1l7UtgYgXZSD32pAAn8lSzDLKNXz1PQ/YK9f1JmzJBjSWFupwWRoyeXkLtoh/D1JI -Pb9s2KJELtFOt3JY04kTlf5Eq/jXixtunLwsoFvVagCvXzfh1foQC5ichucmj87w7G6KVwuA406y -wKBjYZC6VWg3dGq2ktufoYYitmUnDuy2n0Jg5GfCtdpBC8TTi2EbvPofkSvXRAdeuims2cXp71NI -WuuA8ShYIc2wBlX7Jz9TkHCpBB5XJ7k= ------END CERTIFICATE----- - -SSL.com Root Certification Authority ECC -======================================== ------BEGIN CERTIFICATE----- -MIICjTCCAhSgAwIBAgIIdebfy8FoW6gwCgYIKoZIzj0EAwIwfDELMAkGA1UEBhMCVVMxDjAMBgNV -BAgMBVRleGFzMRAwDgYDVQQHDAdIb3VzdG9uMRgwFgYDVQQKDA9TU0wgQ29ycG9yYXRpb24xMTAv -BgNVBAMMKFNTTC5jb20gUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSBFQ0MwHhcNMTYwMjEy -MTgxNDAzWhcNNDEwMjEyMTgxNDAzWjB8MQswCQYDVQQGEwJVUzEOMAwGA1UECAwFVGV4YXMxEDAO -BgNVBAcMB0hvdXN0b24xGDAWBgNVBAoMD1NTTCBDb3Jwb3JhdGlvbjExMC8GA1UEAwwoU1NMLmNv -bSBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IEVDQzB2MBAGByqGSM49AgEGBSuBBAAiA2IA -BEVuqVDEpiM2nl8ojRfLliJkP9x6jh3MCLOicSS6jkm5BBtHllirLZXI7Z4INcgn64mMU1jrYor+ -8FsPazFSY0E7ic3s7LaNGdM0B9y7xgZ/wkWV7Mt/qCPgCemB+vNH06NjMGEwHQYDVR0OBBYEFILR -hXMw5zUE044CkvvlpNHEIejNMA8GA1UdEwEB/wQFMAMBAf8wHwYDVR0jBBgwFoAUgtGFczDnNQTT -jgKS++Wk0cQh6M0wDgYDVR0PAQH/BAQDAgGGMAoGCCqGSM49BAMCA2cAMGQCMG/n61kRpGDPYbCW -e+0F+S8Tkdzt5fxQaxFGRrMcIQBiu77D5+jNB5n5DQtdcj7EqgIwH7y6C+IwJPt8bYBVCpk+gA0z -5Wajs6O7pdWLjwkspl1+4vAHCGht0nxpbl/f5Wpl ------END CERTIFICATE----- - -SSL.com EV Root Certification Authority RSA R2 -============================================== ------BEGIN CERTIFICATE----- -MIIF6zCCA9OgAwIBAgIIVrYpzTS8ePYwDQYJKoZIhvcNAQELBQAwgYIxCzAJBgNVBAYTAlVTMQ4w -DAYDVQQIDAVUZXhhczEQMA4GA1UEBwwHSG91c3RvbjEYMBYGA1UECgwPU1NMIENvcnBvcmF0aW9u -MTcwNQYDVQQDDC5TU0wuY29tIEVWIFJvb3QgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgUlNBIFIy -MB4XDTE3MDUzMTE4MTQzN1oXDTQyMDUzMDE4MTQzN1owgYIxCzAJBgNVBAYTAlVTMQ4wDAYDVQQI -DAVUZXhhczEQMA4GA1UEBwwHSG91c3RvbjEYMBYGA1UECgwPU1NMIENvcnBvcmF0aW9uMTcwNQYD -VQQDDC5TU0wuY29tIEVWIFJvb3QgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgUlNBIFIyMIICIjAN -BgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAjzZlQOHWTcDXtOlG2mvqM0fNTPl9fb69LT3w23jh -hqXZuglXaO1XPqDQCEGD5yhBJB/jchXQARr7XnAjssufOePPxU7Gkm0mxnu7s9onnQqG6YE3Bf7w -cXHswxzpY6IXFJ3vG2fThVUCAtZJycxa4bH3bzKfydQ7iEGonL3Lq9ttewkfokxykNorCPzPPFTO -Zw+oz12WGQvE43LrrdF9HSfvkusQv1vrO6/PgN3B0pYEW3p+pKk8OHakYo6gOV7qd89dAFmPZiw+ -B6KjBSYRaZfqhbcPlgtLyEDhULouisv3D5oi53+aNxPN8k0TayHRwMwi8qFG9kRpnMphNQcAb9Zh -CBHqurj26bNg5U257J8UZslXWNvNh2n4ioYSA0e/ZhN2rHd9NCSFg83XqpyQGp8hLH94t2S42Oim -9HizVcuE0jLEeK6jj2HdzghTreyI/BXkmg3mnxp3zkyPuBQVPWKchjgGAGYS5Fl2WlPAApiiECto -RHuOec4zSnaqW4EWG7WK2NAAe15itAnWhmMOpgWVSbooi4iTsjQc2KRVbrcc0N6ZVTsj9CLg+Slm -JuwgUHfbSguPvuUCYHBBXtSuUDkiFCbLsjtzdFVHB3mBOagwE0TlBIqulhMlQg+5U8Sb/M3kHN48 -+qvWBkofZ6aYMBzdLNvcGJVXZsb/XItW9XcCAwEAAaNjMGEwDwYDVR0TAQH/BAUwAwEB/zAfBgNV -HSMEGDAWgBT5YLvU49U09rj1BoAlp3PbRmmonjAdBgNVHQ4EFgQU+WC71OPVNPa49QaAJadz20Zp -qJ4wDgYDVR0PAQH/BAQDAgGGMA0GCSqGSIb3DQEBCwUAA4ICAQBWs47LCp1Jjr+kxJG7ZhcFUZh1 -++VQLHqe8RT6q9OKPv+RKY9ji9i0qVQBDb6Thi/5Sm3HXvVX+cpVHBK+Rw82xd9qt9t1wkclf7nx -Y/hoLVUE0fKNsKTPvDxeH3jnpaAgcLAExbf3cqfeIg29MyVGjGSSJuM+LmOW2puMPfgYCdcDzH2G -guDKBAdRUNf/ktUM79qGn5nX67evaOI5JpS6aLe/g9Pqemc9YmeuJeVy6OLk7K4S9ksrPJ/psEDz -OFSz/bdoyNrGj1E8svuR3Bznm53htw1yj+KkxKl4+esUrMZDBcJlOSgYAsOCsp0FvmXtll9ldDz7 -CTUue5wT/RsPXcdtgTpWD8w74a8CLyKsRspGPKAcTNZEtF4uXBVmCeEmKf7GUmG6sXP/wwyc5Wxq -lD8UykAWlYTzWamsX0xhk23RO8yilQwipmdnRC652dKKQbNmC1r7fSOl8hqw/96bg5Qu0T/fkreR -rwU7ZcegbLHNYhLDkBvjJc40vG93drEQw/cFGsDWr3RiSBd3kmmQYRzelYB0VI8YHMPzA9C/pEN1 -hlMYegouCRw2n5H9gooiS9EOUCXdywMMF8mDAAhONU2Ki+3wApRmLER/y5UnlhetCTCstnEXbosX -9hwJ1C07mKVx01QT2WDz9UtmT/rx7iASjbSsV7FFY6GsdqnC+w== ------END CERTIFICATE----- - -SSL.com EV Root Certification Authority ECC -=========================================== ------BEGIN CERTIFICATE----- -MIIClDCCAhqgAwIBAgIILCmcWxbtBZUwCgYIKoZIzj0EAwIwfzELMAkGA1UEBhMCVVMxDjAMBgNV -BAgMBVRleGFzMRAwDgYDVQQHDAdIb3VzdG9uMRgwFgYDVQQKDA9TU0wgQ29ycG9yYXRpb24xNDAy -BgNVBAMMK1NTTC5jb20gRVYgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSBFQ0MwHhcNMTYw -MjEyMTgxNTIzWhcNNDEwMjEyMTgxNTIzWjB/MQswCQYDVQQGEwJVUzEOMAwGA1UECAwFVGV4YXMx -EDAOBgNVBAcMB0hvdXN0b24xGDAWBgNVBAoMD1NTTCBDb3Jwb3JhdGlvbjE0MDIGA1UEAwwrU1NM -LmNvbSBFViBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IEVDQzB2MBAGByqGSM49AgEGBSuB -BAAiA2IABKoSR5CYG/vvw0AHgyBO8TCCogbR8pKGYfL2IWjKAMTH6kMAVIbc/R/fALhBYlzccBYy -3h+Z1MzFB8gIH2EWB1E9fVwHU+M1OIzfzZ/ZLg1KthkuWnBaBu2+8KGwytAJKaNjMGEwHQYDVR0O -BBYEFFvKXuXe0oGqzagtZFG22XKbl+ZPMA8GA1UdEwEB/wQFMAMBAf8wHwYDVR0jBBgwFoAUW8pe -5d7SgarNqC1kUbbZcpuX5k8wDgYDVR0PAQH/BAQDAgGGMAoGCCqGSM49BAMCA2gAMGUCMQCK5kCJ -N+vp1RPZytRrJPOwPYdGWBrssd9v+1a6cGvHOMzosYxPD/fxZ3YOg9AeUY8CMD32IygmTMZgh5Mm -m7I1HrrW9zzRHM76JTymGoEVW/MSD2zuZYrJh6j5B+BimoxcSg== ------END CERTIFICATE----- - -GlobalSign Root CA - R6 -======================= ------BEGIN CERTIFICATE----- -MIIFgzCCA2ugAwIBAgIORea7A4Mzw4VlSOb/RVEwDQYJKoZIhvcNAQEMBQAwTDEgMB4GA1UECxMX -R2xvYmFsU2lnbiBSb290IENBIC0gUjYxEzARBgNVBAoTCkdsb2JhbFNpZ24xEzARBgNVBAMTCkds -b2JhbFNpZ24wHhcNMTQxMjEwMDAwMDAwWhcNMzQxMjEwMDAwMDAwWjBMMSAwHgYDVQQLExdHbG9i -YWxTaWduIFJvb3QgQ0EgLSBSNjETMBEGA1UEChMKR2xvYmFsU2lnbjETMBEGA1UEAxMKR2xvYmFs -U2lnbjCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAJUH6HPKZvnsFMp7PPcNCPG0RQss -grRIxutbPK6DuEGSMxSkb3/pKszGsIhrxbaJ0cay/xTOURQh7ErdG1rG1ofuTToVBu1kZguSgMpE -3nOUTvOniX9PeGMIyBJQbUJmL025eShNUhqKGoC3GYEOfsSKvGRMIRxDaNc9PIrFsmbVkJq3MQbF -vuJtMgamHvm566qjuL++gmNQ0PAYid/kD3n16qIfKtJwLnvnvJO7bVPiSHyMEAc4/2ayd2F+4OqM -PKq0pPbzlUoSB239jLKJz9CgYXfIWHSw1CM69106yqLbnQneXUQtkPGBzVeS+n68UARjNN9rkxi+ -azayOeSsJDa38O+2HBNXk7besvjihbdzorg1qkXy4J02oW9UivFyVm4uiMVRQkQVlO6jxTiWm05O -WgtH8wY2SXcwvHE35absIQh1/OZhFj931dmRl4QKbNQCTXTAFO39OfuD8l4UoQSwC+n+7o/hbguy -CLNhZglqsQY6ZZZZwPA1/cnaKI0aEYdwgQqomnUdnjqGBQCe24DWJfncBZ4nWUx2OVvq+aWh2IMP -0f/fMBH5hc8zSPXKbWQULHpYT9NLCEnFlWQaYw55PfWzjMpYrZxCRXluDocZXFSxZba/jJvcE+kN -b7gu3GduyYsRtYQUigAZcIN5kZeR1BonvzceMgfYFGM8KEyvAgMBAAGjYzBhMA4GA1UdDwEB/wQE -AwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBSubAWjkxPioufi1xzWx/B/yGdToDAfBgNV -HSMEGDAWgBSubAWjkxPioufi1xzWx/B/yGdToDANBgkqhkiG9w0BAQwFAAOCAgEAgyXt6NH9lVLN -nsAEoJFp5lzQhN7craJP6Ed41mWYqVuoPId8AorRbrcWc+ZfwFSY1XS+wc3iEZGtIxg93eFyRJa0 -lV7Ae46ZeBZDE1ZXs6KzO7V33EByrKPrmzU+sQghoefEQzd5Mr6155wsTLxDKZmOMNOsIeDjHfrY -BzN2VAAiKrlNIC5waNrlU/yDXNOd8v9EDERm8tLjvUYAGm0CuiVdjaExUd1URhxN25mW7xocBFym -Fe944Hn+Xds+qkxV/ZoVqW/hpvvfcDDpw+5CRu3CkwWJ+n1jez/QcYF8AOiYrg54NMMl+68KnyBr -3TsTjxKM4kEaSHpzoHdpx7Zcf4LIHv5YGygrqGytXm3ABdJ7t+uA/iU3/gKbaKxCXcPu9czc8FB1 -0jZpnOZ7BN9uBmm23goJSFmH63sUYHpkqmlD75HHTOwY3WzvUy2MmeFe8nI+z1TIvWfspA9MRf/T -uTAjB0yPEL+GltmZWrSZVxykzLsViVO6LAUP5MSeGbEYNNVMnbrt9x+vJJUEeKgDu+6B5dpffItK -oZB0JaezPkvILFa9x8jvOOJckvB595yEunQtYQEgfn7R8k8HWV+LLUNS60YMlOH1Zkd5d9VUWx+t -JDfLRVpOoERIyNiwmcUVhAn21klJwGW45hpxbqCo8YLoRT5s1gLXCmeDBVrJpBA= ------END CERTIFICATE----- - -OISTE WISeKey Global Root GC CA -=============================== ------BEGIN CERTIFICATE----- -MIICaTCCAe+gAwIBAgIQISpWDK7aDKtARb8roi066jAKBggqhkjOPQQDAzBtMQswCQYDVQQGEwJD -SDEQMA4GA1UEChMHV0lTZUtleTEiMCAGA1UECxMZT0lTVEUgRm91bmRhdGlvbiBFbmRvcnNlZDEo -MCYGA1UEAxMfT0lTVEUgV0lTZUtleSBHbG9iYWwgUm9vdCBHQyBDQTAeFw0xNzA1MDkwOTQ4MzRa -Fw00MjA1MDkwOTU4MzNaMG0xCzAJBgNVBAYTAkNIMRAwDgYDVQQKEwdXSVNlS2V5MSIwIAYDVQQL -ExlPSVNURSBGb3VuZGF0aW9uIEVuZG9yc2VkMSgwJgYDVQQDEx9PSVNURSBXSVNlS2V5IEdsb2Jh -bCBSb290IEdDIENBMHYwEAYHKoZIzj0CAQYFK4EEACIDYgAETOlQwMYPchi82PG6s4nieUqjFqdr -VCTbUf/q9Akkwwsin8tqJ4KBDdLArzHkdIJuyiXZjHWd8dvQmqJLIX4Wp2OQ0jnUsYd4XxiWD1Ab -NTcPasbc2RNNpI6QN+a9WzGRo1QwUjAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAd -BgNVHQ4EFgQUSIcUrOPDnpBgOtfKie7TrYy0UGYwEAYJKwYBBAGCNxUBBAMCAQAwCgYIKoZIzj0E -AwMDaAAwZQIwJsdpW9zV57LnyAyMjMPdeYwbY9XJUpROTYJKcx6ygISpJcBMWm1JKWB4E+J+SOtk -AjEA2zQgMgj/mkkCtojeFK9dbJlxjRo/i9fgojaGHAeCOnZT/cKi7e97sIBPWA9LUzm9 ------END CERTIFICATE----- - -GTS Root R1 -=========== ------BEGIN CERTIFICATE----- -MIIFWjCCA0KgAwIBAgIQbkepxUtHDA3sM9CJuRz04TANBgkqhkiG9w0BAQwFADBHMQswCQYDVQQG -EwJVUzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJv -b3QgUjEwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAG -A1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjEwggIi -MA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC2EQKLHuOhd5s73L+UPreVp0A8of2C+X0yBoJx -9vaMf/vo27xqLpeXo4xL+Sv2sfnOhB2x+cWX3u+58qPpvBKJXqeqUqv4IyfLpLGcY9vXmX7wCl7r -aKb0xlpHDU0QM+NOsROjyBhsS+z8CZDfnWQpJSMHobTSPS5g4M/SCYe7zUjwTcLCeoiKu7rPWRnW -r4+wB7CeMfGCwcDfLqZtbBkOtdh+JhpFAz2weaSUKK0PfyblqAj+lug8aJRT7oM6iCsVlgmy4HqM -LnXWnOunVmSPlk9orj2XwoSPwLxAwAtcvfaHszVsrBhQf4TgTM2S0yDpM7xSma8ytSmzJSq0SPly -4cpk9+aCEI3oncKKiPo4Zor8Y/kB+Xj9e1x3+naH+uzfsQ55lVe0vSbv1gHR6xYKu44LtcXFilWr -06zqkUspzBmkMiVOKvFlRNACzqrOSbTqn3yDsEB750Orp2yjj32JgfpMpf/VjsPOS+C12LOORc92 -wO1AK/1TD7Cn1TsNsYqiA94xrcx36m97PtbfkSIS5r762DL8EGMUUXLeXdYWk70paDPvOmbsB4om -3xPXV2V4J95eSRQAogB/mqghtqmxlbCluQ0WEdrHbEg8QOB+DVrNVjzRlwW5y0vtOUucxD/SVRNu -JLDWcfr0wbrM7Rv1/oFB2ACYPTrIrnqYNxgFlQIDAQABo0IwQDAOBgNVHQ8BAf8EBAMCAQYwDwYD -VR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQU5K8rJnEaK0gnhS9SZizv8IkTcT4wDQYJKoZIhvcNAQEM -BQADggIBADiWCu49tJYeX++dnAsznyvgyv3SjgofQXSlfKqE1OXyHuY3UjKcC9FhHb8owbZEKTV1 -d5iyfNm9dKyKaOOpMQkpAWBz40d8U6iQSifvS9efk+eCNs6aaAyC58/UEBZvXw6ZXPYfcX3v73sv -fuo21pdwCxXu11xWajOl40k4DLh9+42FpLFZXvRq4d2h9mREruZRgyFmxhE+885H7pwoHyXa/6xm -ld01D1zvICxi/ZG6qcz8WpyTgYMpl0p8WnK0OdC3d8t5/Wk6kjftbjhlRn7pYL15iJdfOBL07q9b -gsiG1eGZbYwE8na6SfZu6W0eX6DvJ4J2QPim01hcDyxC2kLGe4g0x8HYRZvBPsVhHdljUEn2NIVq -4BjFbkerQUIpm/ZgDdIx02OYI5NaAIFItO/Nis3Jz5nu2Z6qNuFoS3FJFDYoOj0dzpqPJeaAcWEr -tXvM+SUWgeExX6GjfhaknBZqlxi9dnKlC54dNuYvoS++cJEPqOba+MSSQGwlfnuzCdyyF62ARPBo -pY+Udf90WuioAnwMCeKpSwughQtiue+hMZL77/ZRBIls6Kl0obsXs7X9SQ98POyDGCBDTtWTurQ0 -sR8WNh8M5mQ5Fkzc4P4dyKliPUDqysU0ArSuiYgzNdwsE3PYJ/HQcu51OyLemGhmW/HGY0dVHLql -CFF1pkgl ------END CERTIFICATE----- - -GTS Root R2 -=========== ------BEGIN CERTIFICATE----- -MIIFWjCCA0KgAwIBAgIQbkepxlqz5yDFMJo/aFLybzANBgkqhkiG9w0BAQwFADBHMQswCQYDVQQG -EwJVUzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJv -b3QgUjIwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAG -A1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjIwggIi -MA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDO3v2m++zsFDQ8BwZabFn3GTXd98GdVarTzTuk -k3LvCvptnfbwhYBboUhSnznFt+4orO/LdmgUud+tAWyZH8QiHZ/+cnfgLFuv5AS/T3KgGjSY6Dlo -7JUle3ah5mm5hRm9iYz+re026nO8/4Piy33B0s5Ks40FnotJk9/BW9BuXvAuMC6C/Pq8tBcKSOWI -m8Wba96wyrQD8Nr0kLhlZPdcTK3ofmZemde4wj7I0BOdre7kRXuJVfeKH2JShBKzwkCX44ofR5Gm -dFrS+LFjKBC4swm4VndAoiaYecb+3yXuPuWgf9RhD1FLPD+M2uFwdNjCaKH5wQzpoeJ/u1U8dgbu -ak7MkogwTZq9TwtImoS1mKPV+3PBV2HdKFZ1E66HjucMUQkQdYhMvI35ezzUIkgfKtzra7tEscsz -cTJGr61K8YzodDqs5xoic4DSMPclQsciOzsSrZYuxsN2B6ogtzVJV+mSSeh2FnIxZyuWfoqjx5RW -Ir9qS34BIbIjMt/kmkRtWVtd9QCgHJvGeJeNkP+byKq0rxFROV7Z+2et1VsRnTKaG73Vululycsl -aVNVJ1zgyjbLiGH7HrfQy+4W+9OmTN6SpdTi3/UGVN4unUu0kzCqgc7dGtxRcw1PcOnlthYhGXmy -5okLdWTK1au8CcEYof/UVKGFPP0UJAOyh9OktwIDAQABo0IwQDAOBgNVHQ8BAf8EBAMCAQYwDwYD -VR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUu//KjiOfT5nK2+JopqUVJxce2Q4wDQYJKoZIhvcNAQEM -BQADggIBALZp8KZ3/p7uC4Gt4cCpx/k1HUCCq+YEtN/L9x0Pg/B+E02NjO7jMyLDOfxA325BS0JT -vhaI8dI4XsRomRyYUpOM52jtG2pzegVATX9lO9ZY8c6DR2Dj/5epnGB3GFW1fgiTz9D2PGcDFWEJ -+YF59exTpJ/JjwGLc8R3dtyDovUMSRqodt6Sm2T4syzFJ9MHwAiApJiS4wGWAqoC7o87xdFtCjMw -c3i5T1QWvwsHoaRc5svJXISPD+AVdyx+Jn7axEvbpxZ3B7DNdehyQtaVhJ2Gg/LkkM0JR9SLA3Da -WsYDQvTtN6LwG1BUSw7YhN4ZKJmBR64JGz9I0cNv4rBgF/XuIwKl2gBbbZCr7qLpGzvpx0QnRY5r -n/WkhLx3+WuXrD5RRaIRpsyF7gpo8j5QOHokYh4XIDdtak23CZvJ/KRY9bb7nE4Yu5UC56Gtmwfu -Nmsk0jmGwZODUNKBRqhfYlcsu2xkiAhu7xNUX90txGdj08+JN7+dIPT7eoOboB6BAFDC5AwiWVIQ -7UNWhwD4FFKnHYuTjKJNRn8nxnGbJN7k2oaLDX5rIMHAnuFl2GqjpuiFizoHCBy69Y9Vmhh1fuXs -gWbRIXOhNUQLgD1bnF5vKheW0YMjiGZt5obicDIvUiLnyOd/xCxgXS/Dr55FBcOEArf9LAhST4Ld -o/DUhgkC ------END CERTIFICATE----- - -GTS Root R3 -=========== ------BEGIN CERTIFICATE----- -MIICDDCCAZGgAwIBAgIQbkepx2ypcyRAiQ8DVd2NHTAKBggqhkjOPQQDAzBHMQswCQYDVQQGEwJV -UzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3Qg -UjMwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAGA1UE -ChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjMwdjAQBgcq -hkjOPQIBBgUrgQQAIgNiAAQfTzOHMymKoYTey8chWEGJ6ladK0uFxh1MJ7x/JlFyb+Kf1qPKzEUU -Rout736GjOyxfi//qXGdGIRFBEFVbivqJn+7kAHjSxm65FSWRQmx1WyRRK2EE46ajA2ADDL24Cej -QjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBTB8Sa6oC2uhYHP -0/EqEr24Cmf9vDAKBggqhkjOPQQDAwNpADBmAjEAgFukfCPAlaUs3L6JbyO5o91lAFJekazInXJ0 -glMLfalAvWhgxeG4VDvBNhcl2MG9AjEAnjWSdIUlUfUk7GRSJFClH9voy8l27OyCbvWFGFPouOOa -KaqW04MjyaR7YbPMAuhd ------END CERTIFICATE----- - -GTS Root R4 -=========== ------BEGIN CERTIFICATE----- -MIICCjCCAZGgAwIBAgIQbkepyIuUtui7OyrYorLBmTAKBggqhkjOPQQDAzBHMQswCQYDVQQGEwJV -UzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3Qg -UjQwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAGA1UE -ChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjQwdjAQBgcq -hkjOPQIBBgUrgQQAIgNiAATzdHOnaItgrkO4NcWBMHtLSZ37wWHO5t5GvWvVYRg1rkDdc/eJkTBa -6zzuhXyiQHY7qca4R9gq55KRanPpsXI5nymfopjTX15YhmUPoYRlBtHci8nHc8iMai/lxKvRHYqj -QjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBSATNbrdP9JNqPV -2Py1PsVq8JQdjDAKBggqhkjOPQQDAwNnADBkAjBqUFJ0CMRw3J5QdCHojXohw0+WbhXRIjVhLfoI -N+4Zba3bssx9BzT1YBkstTTZbyACMANxsbqjYAuG7ZoIapVon+Kz4ZNkfF6Tpt95LY2F45TPI11x -zPKwTdb+mciUqXWi4w== ------END CERTIFICATE----- - -UCA Global G2 Root -================== ------BEGIN CERTIFICATE----- -MIIFRjCCAy6gAwIBAgIQXd+x2lqj7V2+WmUgZQOQ7zANBgkqhkiG9w0BAQsFADA9MQswCQYDVQQG -EwJDTjERMA8GA1UECgwIVW5pVHJ1c3QxGzAZBgNVBAMMElVDQSBHbG9iYWwgRzIgUm9vdDAeFw0x -NjAzMTEwMDAwMDBaFw00MDEyMzEwMDAwMDBaMD0xCzAJBgNVBAYTAkNOMREwDwYDVQQKDAhVbmlU -cnVzdDEbMBkGA1UEAwwSVUNBIEdsb2JhbCBHMiBSb290MIICIjANBgkqhkiG9w0BAQEFAAOCAg8A -MIICCgKCAgEAxeYrb3zvJgUno4Ek2m/LAfmZmqkywiKHYUGRO8vDaBsGxUypK8FnFyIdK+35KYmT -oni9kmugow2ifsqTs6bRjDXVdfkX9s9FxeV67HeToI8jrg4aA3++1NDtLnurRiNb/yzmVHqUwCoV -8MmNsHo7JOHXaOIxPAYzRrZUEaalLyJUKlgNAQLx+hVRZ2zA+te2G3/RVogvGjqNO7uCEeBHANBS -h6v7hn4PJGtAnTRnvI3HLYZveT6OqTwXS3+wmeOwcWDcC/Vkw85DvG1xudLeJ1uK6NjGruFZfc8o -LTW4lVYa8bJYS7cSN8h8s+1LgOGN+jIjtm+3SJUIsUROhYw6AlQgL9+/V087OpAh18EmNVQg7Mc/ -R+zvWr9LesGtOxdQXGLYD0tK3Cv6brxzks3sx1DoQZbXqX5t2Okdj4q1uViSukqSKwxW/YDrCPBe -KW4bHAyvj5OJrdu9o54hyokZ7N+1wxrrFv54NkzWbtA+FxyQF2smuvt6L78RHBgOLXMDj6DlNaBa -4kx1HXHhOThTeEDMg5PXCp6dW4+K5OXgSORIskfNTip1KnvyIvbJvgmRlld6iIis7nCs+dwp4wwc -OxJORNanTrAmyPPZGpeRaOrvjUYG0lZFWJo8DA+DuAUlwznPO6Q0ibd5Ei9Hxeepl2n8pndntd97 -8XplFeRhVmUCAwEAAaNCMEAwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0O -BBYEFIHEjMz15DD/pQwIX4wVZyF0Ad/fMA0GCSqGSIb3DQEBCwUAA4ICAQATZSL1jiutROTL/7lo -5sOASD0Ee/ojL3rtNtqyzm325p7lX1iPyzcyochltq44PTUbPrw7tgTQvPlJ9Zv3hcU2tsu8+Mg5 -1eRfB70VVJd0ysrtT7q6ZHafgbiERUlMjW+i67HM0cOU2kTC5uLqGOiiHycFutfl1qnN3e92mI0A -Ds0b+gO3joBYDic/UvuUospeZcnWhNq5NXHzJsBPd+aBJ9J3O5oUb3n09tDh05S60FdRvScFDcH9 -yBIw7m+NESsIndTUv4BFFJqIRNow6rSn4+7vW4LVPtateJLbXDzz2K36uGt/xDYotgIVilQsnLAX -c47QN6MUPJiVAAwpBVueSUmxX8fjy88nZY41F7dXyDDZQVu5FLbowg+UMaeUmMxq67XhJ/UQqAHo -jhJi6IjMtX9Gl8CbEGY4GjZGXyJoPd/JxhMnq1MGrKI8hgZlb7F+sSlEmqO6SWkoaY/X5V+tBIZk -bxqgDMUIYs6Ao9Dz7GjevjPHF1t/gMRMTLGmhIrDO7gJzRSBuhjjVFc2/tsvfEehOjPI+Vg7RE+x -ygKJBJYoaMVLuCaJu9YzL1DV/pqJuhgyklTGW+Cd+V7lDSKb9triyCGyYiGqhkCyLmTTX8jjfhFn -RR8F/uOi77Oos/N9j/gMHyIfLXC0uAE0djAA5SN4p1bXUB+K+wb1whnw0A== ------END CERTIFICATE----- - -UCA Extended Validation Root -============================ ------BEGIN CERTIFICATE----- -MIIFWjCCA0KgAwIBAgIQT9Irj/VkyDOeTzRYZiNwYDANBgkqhkiG9w0BAQsFADBHMQswCQYDVQQG -EwJDTjERMA8GA1UECgwIVW5pVHJ1c3QxJTAjBgNVBAMMHFVDQSBFeHRlbmRlZCBWYWxpZGF0aW9u -IFJvb3QwHhcNMTUwMzEzMDAwMDAwWhcNMzgxMjMxMDAwMDAwWjBHMQswCQYDVQQGEwJDTjERMA8G -A1UECgwIVW5pVHJ1c3QxJTAjBgNVBAMMHFVDQSBFeHRlbmRlZCBWYWxpZGF0aW9uIFJvb3QwggIi -MA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCpCQcoEwKwmeBkqh5DFnpzsZGgdT6o+uM4AHrs -iWogD4vFsJszA1qGxliG1cGFu0/GnEBNyr7uaZa4rYEwmnySBesFK5pI0Lh2PpbIILvSsPGP2KxF -Rv+qZ2C0d35qHzwaUnoEPQc8hQ2E0B92CvdqFN9y4zR8V05WAT558aopO2z6+I9tTcg1367r3CTu -eUWnhbYFiN6IXSV8l2RnCdm/WhUFhvMJHuxYMjMR83dksHYf5BA1FxvyDrFspCqjc/wJHx4yGVMR -59mzLC52LqGj3n5qiAno8geK+LLNEOfic0CTuwjRP+H8C5SzJe98ptfRr5//lpr1kXuYC3fUfugH -0mK1lTnj8/FtDw5lhIpjVMWAtuCeS31HJqcBCF3RiJ7XwzJE+oJKCmhUfzhTA8ykADNkUVkLo4KR -el7sFsLzKuZi2irbWWIQJUoqgQtHB0MGcIfS+pMRKXpITeuUx3BNr2fVUbGAIAEBtHoIppB/TuDv -B0GHr2qlXov7z1CymlSvw4m6WC31MJixNnI5fkkE/SmnTHnkBVfblLkWU41Gsx2VYVdWf6/wFlth -WG82UBEL2KwrlRYaDh8IzTY0ZRBiZtWAXxQgXy0MoHgKaNYs1+lvK9JKBZP8nm9rZ/+I8U6laUpS -NwXqxhaN0sSZ0YIrO7o1dfdRUVjzyAfd5LQDfwIDAQABo0IwQDAdBgNVHQ4EFgQU2XQ65DA9DfcS -3H5aBZ8eNJr34RQwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAYYwDQYJKoZIhvcNAQEL -BQADggIBADaNl8xCFWQpN5smLNb7rhVpLGsaGvdftvkHTFnq88nIua7Mui563MD1sC3AO6+fcAUR -ap8lTwEpcOPlDOHqWnzcSbvBHiqB9RZLcpHIojG5qtr8nR/zXUACE/xOHAbKsxSQVBcZEhrxH9cM -aVr2cXj0lH2RC47skFSOvG+hTKv8dGT9cZr4QQehzZHkPJrgmzI5c6sq1WnIeJEmMX3ixzDx/BR4 -dxIOE/TdFpS/S2d7cFOFyrC78zhNLJA5wA3CXWvp4uXViI3WLL+rG761KIcSF3Ru/H38j9CHJrAb -+7lsq+KePRXBOy5nAliRn+/4Qh8st2j1da3Ptfb/EX3C8CSlrdP6oDyp+l3cpaDvRKS+1ujl5BOW -F3sGPjLtx7dCvHaj2GU4Kzg1USEODm8uNBNA4StnDG1KQTAYI1oyVZnJF+A83vbsea0rWBmirSwi -GpWOvpaQXUJXxPkUAzUrHC1RVwinOt4/5Mi0A3PCwSaAuwtCH60NryZy2sy+s6ODWA2CxR9GUeOc -GMyNm43sSet1UNWMKFnKdDTajAshqx7qG+XH/RU+wBeq+yNuJkbL+vmxcmtpzyKEC2IPrNkZAJSi -djzULZrtBJ4tBmIQN1IchXIbJ+XMxjHsN+xjWZsLHXbMfjKaiJUINlK73nZfdklJrX+9ZSCyycEr -dhh2n1ax ------END CERTIFICATE----- - -Certigna Root CA -================ ------BEGIN CERTIFICATE----- -MIIGWzCCBEOgAwIBAgIRAMrpG4nxVQMNo+ZBbcTjpuEwDQYJKoZIhvcNAQELBQAwWjELMAkGA1UE -BhMCRlIxEjAQBgNVBAoMCURoaW15b3RpczEcMBoGA1UECwwTMDAwMiA0ODE0NjMwODEwMDAzNjEZ -MBcGA1UEAwwQQ2VydGlnbmEgUm9vdCBDQTAeFw0xMzEwMDEwODMyMjdaFw0zMzEwMDEwODMyMjda -MFoxCzAJBgNVBAYTAkZSMRIwEAYDVQQKDAlEaGlteW90aXMxHDAaBgNVBAsMEzAwMDIgNDgxNDYz -MDgxMDAwMzYxGTAXBgNVBAMMEENlcnRpZ25hIFJvb3QgQ0EwggIiMA0GCSqGSIb3DQEBAQUAA4IC -DwAwggIKAoICAQDNGDllGlmx6mQWDoyUJJV8g9PFOSbcDO8WV43X2KyjQn+Cyu3NW9sOty3tRQgX -stmzy9YXUnIo245Onoq2C/mehJpNdt4iKVzSs9IGPjA5qXSjklYcoW9MCiBtnyN6tMbaLOQdLNyz -KNAT8kxOAkmhVECe5uUFoC2EyP+YbNDrihqECB63aCPuI9Vwzm1RaRDuoXrC0SIxwoKF0vJVdlB8 -JXrJhFwLrN1CTivngqIkicuQstDuI7pmTLtipPlTWmR7fJj6o0ieD5Wupxj0auwuA0Wv8HT4Ks16 -XdG+RCYyKfHx9WzMfgIhC59vpD++nVPiz32pLHxYGpfhPTc3GGYo0kDFUYqMwy3OU4gkWGQwFsWq -4NYKpkDfePb1BHxpE4S80dGnBs8B92jAqFe7OmGtBIyT46388NtEbVncSVmurJqZNjBBe3YzIoej -wpKGbvlw7q6Hh5UbxHq9MfPU0uWZ/75I7HX1eBYdpnDBfzwboZL7z8g81sWTCo/1VTp2lc5ZmIoJ -lXcymoO6LAQ6l73UL77XbJuiyn1tJslV1c/DeVIICZkHJC1kJWumIWmbat10TWuXekG9qxf5kBdI -jzb5LdXF2+6qhUVB+s06RbFo5jZMm5BX7CO5hwjCxAnxl4YqKE3idMDaxIzb3+KhF1nOJFl0Mdp/ -/TBt2dzhauH8XwIDAQABo4IBGjCCARYwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYw -HQYDVR0OBBYEFBiHVuBud+4kNTxOc5of1uHieX4rMB8GA1UdIwQYMBaAFBiHVuBud+4kNTxOc5of -1uHieX4rMEQGA1UdIAQ9MDswOQYEVR0gADAxMC8GCCsGAQUFBwIBFiNodHRwczovL3d3d3cuY2Vy -dGlnbmEuZnIvYXV0b3JpdGVzLzBtBgNVHR8EZjBkMC+gLaArhilodHRwOi8vY3JsLmNlcnRpZ25h -LmZyL2NlcnRpZ25hcm9vdGNhLmNybDAxoC+gLYYraHR0cDovL2NybC5kaGlteW90aXMuY29tL2Nl -cnRpZ25hcm9vdGNhLmNybDANBgkqhkiG9w0BAQsFAAOCAgEAlLieT/DjlQgi581oQfccVdV8AOIt -OoldaDgvUSILSo3L6btdPrtcPbEo/uRTVRPPoZAbAh1fZkYJMyjhDSSXcNMQH+pkV5a7XdrnxIxP -TGRGHVyH41neQtGbqH6mid2PHMkwgu07nM3A6RngatgCdTer9zQoKJHyBApPNeNgJgH60BGM+RFq -7q89w1DTj18zeTyGqHNFkIwgtnJzFyO+B2XleJINugHA64wcZr+shncBlA2c5uk5jR+mUYyZDDl3 -4bSb+hxnV29qao6pK0xXeXpXIs/NX2NGjVxZOob4Mkdio2cNGJHc+6Zr9UhhcyNZjgKnvETq9Emd -8VRY+WCv2hikLyhF3HqgiIZd8zvn/yk1gPxkQ5Tm4xxvvq0OKmOZK8l+hfZx6AYDlf7ej0gcWtSS -6Cvu5zHbugRqh5jnxV/vfaci9wHYTfmJ0A6aBVmknpjZbyvKcL5kwlWj9Omvw5Ip3IgWJJk8jSaY -tlu3zM63Nwf9JtmYhST/WSMDmu2dnajkXjjO11INb9I/bbEFa0nOipFGc/T2L/Coc3cOZayhjWZS -aX5LaAzHHjcng6WMxwLkFM1JAbBzs/3GkDpv0mztO+7skb6iQ12LAEpmJURw3kAP+HwV96LOPNde -E4yBFxgX0b3xdxA61GU5wSesVywlVP+i2k+KYTlerj1KjL0= ------END CERTIFICATE----- - -emSign Root CA - G1 -=================== ------BEGIN CERTIFICATE----- -MIIDlDCCAnygAwIBAgIKMfXkYgxsWO3W2DANBgkqhkiG9w0BAQsFADBnMQswCQYDVQQGEwJJTjET -MBEGA1UECxMKZW1TaWduIFBLSTElMCMGA1UEChMcZU11ZGhyYSBUZWNobm9sb2dpZXMgTGltaXRl -ZDEcMBoGA1UEAxMTZW1TaWduIFJvb3QgQ0EgLSBHMTAeFw0xODAyMTgxODMwMDBaFw00MzAyMTgx -ODMwMDBaMGcxCzAJBgNVBAYTAklOMRMwEQYDVQQLEwplbVNpZ24gUEtJMSUwIwYDVQQKExxlTXVk -aHJhIFRlY2hub2xvZ2llcyBMaW1pdGVkMRwwGgYDVQQDExNlbVNpZ24gUm9vdCBDQSAtIEcxMIIB -IjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAk0u76WaK7p1b1TST0Bsew+eeuGQzf2N4aLTN -LnF115sgxk0pvLZoYIr3IZpWNVrzdr3YzZr/k1ZLpVkGoZM0Kd0WNHVO8oG0x5ZOrRkVUkr+PHB1 -cM2vK6sVmjM8qrOLqs1D/fXqcP/tzxE7lM5OMhbTI0Aqd7OvPAEsbO2ZLIvZTmmYsvePQbAyeGHW -DV/D+qJAkh1cF+ZwPjXnorfCYuKrpDhMtTk1b+oDafo6VGiFbdbyL0NVHpENDtjVaqSW0RM8LHhQ -6DqS0hdW5TUaQBw+jSztOd9C4INBdN+jzcKGYEho42kLVACL5HZpIQ15TjQIXhTCzLG3rdd8cIrH -hQIDAQABo0IwQDAdBgNVHQ4EFgQU++8Nhp6w492pufEhF38+/PB3KxowDgYDVR0PAQH/BAQDAgEG -MA8GA1UdEwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQADggEBAFn/8oz1h31xPaOfG1vR2vjTnGs2 -vZupYeveFix0PZ7mddrXuqe8QhfnPZHr5X3dPpzxz5KsbEjMwiI/aTvFthUvozXGaCocV685743Q -NcMYDHsAVhzNixl03r4PEuDQqqE/AjSxcM6dGNYIAwlG7mDgfrbESQRRfXBgvKqy/3lyeqYdPV8q -+Mri/Tm3R7nrft8EI6/6nAYH6ftjk4BAtcZsCjEozgyfz7MjNYBBjWzEN3uBL4ChQEKF6dk4jeih -U80Bv2noWgbyRQuQ+q7hv53yrlc8pa6yVvSLZUDp/TGBLPQ5Cdjua6e0ph0VpZj3AYHYhX3zUVxx -iN66zB+Afko= ------END CERTIFICATE----- - -emSign ECC Root CA - G3 -======================= ------BEGIN CERTIFICATE----- -MIICTjCCAdOgAwIBAgIKPPYHqWhwDtqLhDAKBggqhkjOPQQDAzBrMQswCQYDVQQGEwJJTjETMBEG -A1UECxMKZW1TaWduIFBLSTElMCMGA1UEChMcZU11ZGhyYSBUZWNobm9sb2dpZXMgTGltaXRlZDEg -MB4GA1UEAxMXZW1TaWduIEVDQyBSb290IENBIC0gRzMwHhcNMTgwMjE4MTgzMDAwWhcNNDMwMjE4 -MTgzMDAwWjBrMQswCQYDVQQGEwJJTjETMBEGA1UECxMKZW1TaWduIFBLSTElMCMGA1UEChMcZU11 -ZGhyYSBUZWNobm9sb2dpZXMgTGltaXRlZDEgMB4GA1UEAxMXZW1TaWduIEVDQyBSb290IENBIC0g -RzMwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAAQjpQy4LRL1KPOxst3iAhKAnjlfSU2fySU0WXTsuwYc -58Byr+iuL+FBVIcUqEqy6HyC5ltqtdyzdc6LBtCGI79G1Y4PPwT01xySfvalY8L1X44uT6EYGQIr -MgqCZH0Wk9GjQjBAMB0GA1UdDgQWBBR8XQKEE9TMipuBzhccLikenEhjQjAOBgNVHQ8BAf8EBAMC -AQYwDwYDVR0TAQH/BAUwAwEB/zAKBggqhkjOPQQDAwNpADBmAjEAvvNhzwIQHWSVB7gYboiFBS+D -CBeQyh+KTOgNG3qxrdWBCUfvO6wIBHxcmbHtRwfSAjEAnbpV/KlK6O3t5nYBQnvI+GDZjVGLVTv7 -jHvrZQnD+JbNR6iC8hZVdyR+EhCVBCyj ------END CERTIFICATE----- - -emSign Root CA - C1 -=================== ------BEGIN CERTIFICATE----- -MIIDczCCAlugAwIBAgILAK7PALrEzzL4Q7IwDQYJKoZIhvcNAQELBQAwVjELMAkGA1UEBhMCVVMx -EzARBgNVBAsTCmVtU2lnbiBQS0kxFDASBgNVBAoTC2VNdWRocmEgSW5jMRwwGgYDVQQDExNlbVNp -Z24gUm9vdCBDQSAtIEMxMB4XDTE4MDIxODE4MzAwMFoXDTQzMDIxODE4MzAwMFowVjELMAkGA1UE -BhMCVVMxEzARBgNVBAsTCmVtU2lnbiBQS0kxFDASBgNVBAoTC2VNdWRocmEgSW5jMRwwGgYDVQQD -ExNlbVNpZ24gUm9vdCBDQSAtIEMxMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAz+up -ufGZBczYKCFK83M0UYRWEPWgTywS4/oTmifQz/l5GnRfHXk5/Fv4cI7gklL35CX5VIPZHdPIWoU/ -Xse2B+4+wM6ar6xWQio5JXDWv7V7Nq2s9nPczdcdioOl+yuQFTdrHCZH3DspVpNqs8FqOp099cGX -OFgFixwR4+S0uF2FHYP+eF8LRWgYSKVGczQ7/g/IdrvHGPMF0Ybzhe3nudkyrVWIzqa2kbBPrH4V -I5b2P/AgNBbeCsbEBEV5f6f9vtKppa+cxSMq9zwhbL2vj07FOrLzNBL834AaSaTUqZX3noleooms -lMuoaJuvimUnzYnu3Yy1aylwQ6BpC+S5DwIDAQABo0IwQDAdBgNVHQ4EFgQU/qHgcB4qAzlSWkK+ -XJGFehiqTbUwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQAD -ggEBAMJKVvoVIXsoounlHfv4LcQ5lkFMOycsxGwYFYDGrK9HWS8mC+M2sO87/kOXSTKZEhVb3xEp -/6tT+LvBeA+snFOvV71ojD1pM/CjoCNjO2RnIkSt1XHLVip4kqNPEjE2NuLe/gDEo2APJ62gsIq1 -NnpSob0n9CAnYuhNlCQT5AoE6TyrLshDCUrGYQTlSTR+08TI9Q/Aqum6VF7zYytPT1DU/rl7mYw9 -wC68AivTxEDkigcxHpvOJpkT+xHqmiIMERnHXhuBUDDIlhJu58tBf5E7oke3VIAb3ADMmpDqw8NQ -BmIMMMAVSKeoWXzhriKi4gp6D/piq1JM4fHfyr6DDUI= ------END CERTIFICATE----- - -emSign ECC Root CA - C3 -======================= ------BEGIN CERTIFICATE----- -MIICKzCCAbGgAwIBAgIKe3G2gla4EnycqDAKBggqhkjOPQQDAzBaMQswCQYDVQQGEwJVUzETMBEG -A1UECxMKZW1TaWduIFBLSTEUMBIGA1UEChMLZU11ZGhyYSBJbmMxIDAeBgNVBAMTF2VtU2lnbiBF -Q0MgUm9vdCBDQSAtIEMzMB4XDTE4MDIxODE4MzAwMFoXDTQzMDIxODE4MzAwMFowWjELMAkGA1UE -BhMCVVMxEzARBgNVBAsTCmVtU2lnbiBQS0kxFDASBgNVBAoTC2VNdWRocmEgSW5jMSAwHgYDVQQD -ExdlbVNpZ24gRUNDIFJvb3QgQ0EgLSBDMzB2MBAGByqGSM49AgEGBSuBBAAiA2IABP2lYa57JhAd -6bciMK4G9IGzsUJxlTm801Ljr6/58pc1kjZGDoeVjbk5Wum739D+yAdBPLtVb4OjavtisIGJAnB9 -SMVK4+kiVCJNk7tCDK93nCOmfddhEc5lx/h//vXyqaNCMEAwHQYDVR0OBBYEFPtaSNCAIEDyqOkA -B2kZd6fmw/TPMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MAoGCCqGSM49BAMDA2gA -MGUCMQC02C8Cif22TGK6Q04ThHK1rt0c3ta13FaPWEBaLd4gTCKDypOofu4SQMfWh0/434UCMBwU -ZOR8loMRnLDRWmFLpg9J0wD8ofzkpf9/rdcw0Md3f76BB1UwUCAU9Vc4CqgxUQ== ------END CERTIFICATE----- - -Hongkong Post Root CA 3 -======================= ------BEGIN CERTIFICATE----- -MIIFzzCCA7egAwIBAgIUCBZfikyl7ADJk0DfxMauI7gcWqQwDQYJKoZIhvcNAQELBQAwbzELMAkG -A1UEBhMCSEsxEjAQBgNVBAgTCUhvbmcgS29uZzESMBAGA1UEBxMJSG9uZyBLb25nMRYwFAYDVQQK -Ew1Ib25na29uZyBQb3N0MSAwHgYDVQQDExdIb25na29uZyBQb3N0IFJvb3QgQ0EgMzAeFw0xNzA2 -MDMwMjI5NDZaFw00MjA2MDMwMjI5NDZaMG8xCzAJBgNVBAYTAkhLMRIwEAYDVQQIEwlIb25nIEtv -bmcxEjAQBgNVBAcTCUhvbmcgS29uZzEWMBQGA1UEChMNSG9uZ2tvbmcgUG9zdDEgMB4GA1UEAxMX -SG9uZ2tvbmcgUG9zdCBSb290IENBIDMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCz -iNfqzg8gTr7m1gNt7ln8wlffKWihgw4+aMdoWJwcYEuJQwy51BWy7sFOdem1p+/l6TWZ5Mwc50tf -jTMwIDNT2aa71T4Tjukfh0mtUC1Qyhi+AViiE3CWu4mIVoBc+L0sPOFMV4i707mV78vH9toxdCim -5lSJ9UExyuUmGs2C4HDaOym71QP1mbpV9WTRYA6ziUm4ii8F0oRFKHyPaFASePwLtVPLwpgchKOe -sL4jpNrcyCse2m5FHomY2vkALgbpDDtw1VAliJnLzXNg99X/NWfFobxeq81KuEXryGgeDQ0URhLj -0mRiikKYvLTGCAj4/ahMZJx2Ab0vqWwzD9g/KLg8aQFChn5pwckGyuV6RmXpwtZQQS4/t+TtbNe/ -JgERohYpSms0BpDsE9K2+2p20jzt8NYt3eEV7KObLyzJPivkaTv/ciWxNoZbx39ri1UbSsUgYT2u -y1DhCDq+sI9jQVMwCFk8mB13umOResoQUGC/8Ne8lYePl8X+l2oBlKN8W4UdKjk60FSh0Tlxnf0h -+bV78OLgAo9uliQlLKAeLKjEiafv7ZkGL7YKTE/bosw3Gq9HhS2KX8Q0NEwA/RiTZxPRN+ZItIsG -xVd7GYYKecsAyVKvQv83j+GjHno9UKtjBucVtT+2RTeUN7F+8kjDf8V1/peNRY8apxpyKBpADwID -AQABo2MwYTAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBBjAfBgNVHSMEGDAWgBQXnc0e -i9Y5K3DTXNSguB+wAPzFYTAdBgNVHQ4EFgQUF53NHovWOStw01zUoLgfsAD8xWEwDQYJKoZIhvcN -AQELBQADggIBAFbVe27mIgHSQpsY1Q7XZiNc4/6gx5LS6ZStS6LG7BJ8dNVI0lkUmcDrudHr9Egw -W62nV3OZqdPlt9EuWSRY3GguLmLYauRwCy0gUCCkMpXRAJi70/33MvJJrsZ64Ee+bs7Lo3I6LWld -y8joRTnU+kLBEUx3XZL7av9YROXrgZ6voJmtvqkBZss4HTzfQx/0TW60uhdG/H39h4F5ag0zD/ov -+BS5gLNdTaqX4fnkGMX41TiMJjz98iji7lpJiCzfeT2OnpA8vUFKOt1b9pq0zj8lMH8yfaIDlNDc -eqFS3m6TjRgm/VWsvY+b0s+v54Ysyx8Jb6NvqYTUc79NoXQbTiNg8swOqn+knEwlqLJmOzj/2ZQw -9nKEvmhVEA/GcywWaZMH/rFF7buiVWqw2rVKAiUnhde3t4ZEFolsgCs+l6mc1X5VTMbeRRAc6uk7 -nwNT7u56AQIWeNTowr5GdogTPyK7SBIdUgC0An4hGh6cJfTzPV4e0hz5sy229zdcxsshTrD3mUcY -hcErulWuBurQB7Lcq9CClnXO0lD+mefPL5/ndtFhKvshuzHQqp9HpLIiyhY6UFfEW0NnxWViA0kB -60PZ2Pierc+xYw5F9KBaLJstxabArahH9CdMOA0uG0k7UvToiIMrVCjU8jVStDKDYmlkDJGcn5fq -dBb9HxEGmpv0 ------END CERTIFICATE----- - -Entrust Root Certification Authority - G4 -========================================= ------BEGIN CERTIFICATE----- -MIIGSzCCBDOgAwIBAgIRANm1Q3+vqTkPAAAAAFVlrVgwDQYJKoZIhvcNAQELBQAwgb4xCzAJBgNV -BAYTAlVTMRYwFAYDVQQKEw1FbnRydXN0LCBJbmMuMSgwJgYDVQQLEx9TZWUgd3d3LmVudHJ1c3Qu -bmV0L2xlZ2FsLXRlcm1zMTkwNwYDVQQLEzAoYykgMjAxNSBFbnRydXN0LCBJbmMuIC0gZm9yIGF1 -dGhvcml6ZWQgdXNlIG9ubHkxMjAwBgNVBAMTKUVudHJ1c3QgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1 -dGhvcml0eSAtIEc0MB4XDTE1MDUyNzExMTExNloXDTM3MTIyNzExNDExNlowgb4xCzAJBgNVBAYT -AlVTMRYwFAYDVQQKEw1FbnRydXN0LCBJbmMuMSgwJgYDVQQLEx9TZWUgd3d3LmVudHJ1c3QubmV0 -L2xlZ2FsLXRlcm1zMTkwNwYDVQQLEzAoYykgMjAxNSBFbnRydXN0LCBJbmMuIC0gZm9yIGF1dGhv -cml6ZWQgdXNlIG9ubHkxMjAwBgNVBAMTKUVudHJ1c3QgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhv -cml0eSAtIEc0MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAsewsQu7i0TD/pZJH4i3D -umSXbcr3DbVZwbPLqGgZ2K+EbTBwXX7zLtJTmeH+H17ZSK9dE43b/2MzTdMAArzE+NEGCJR5WIoV -3imz/f3ET+iq4qA7ec2/a0My3dl0ELn39GjUu9CH1apLiipvKgS1sqbHoHrmSKvS0VnM1n4j5pds -8ELl3FFLFUHtSUrJ3hCX1nbB76W1NhSXNdh4IjVS70O92yfbYVaCNNzLiGAMC1rlLAHGVK/XqsEQ -e9IFWrhAnoanw5CGAlZSCXqc0ieCU0plUmr1POeo8pyvi73TDtTUXm6Hnmo9RR3RXRv06QqsYJn7 -ibT/mCzPfB3pAqoEmh643IhuJbNsZvc8kPNXwbMv9W3y+8qh+CmdRouzavbmZwe+LGcKKh9asj5X -xNMhIWNlUpEbsZmOeX7m640A2Vqq6nPopIICR5b+W45UYaPrL0swsIsjdXJ8ITzI9vF01Bx7owVV -7rtNOzK+mndmnqxpkCIHH2E6lr7lmk/MBTwoWdPBDFSoWWG9yHJM6Nyfh3+9nEg2XpWjDrk4JFX8 -dWbrAuMINClKxuMrLzOg2qOGpRKX/YAr2hRC45K9PvJdXmd0LhyIRyk0X+IyqJwlN4y6mACXi0mW -Hv0liqzc2thddG5msP9E36EYxr5ILzeUePiVSj9/E15dWf10hkNjc0kCAwEAAaNCMEAwDwYDVR0T -AQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFJ84xFYjwznooHFs6FRM5Og6sb9n -MA0GCSqGSIb3DQEBCwUAA4ICAQAS5UKme4sPDORGpbZgQIeMJX6tuGguW8ZAdjwD+MlZ9POrYs4Q -jbRaZIxowLByQzTSGwv2LFPSypBLhmb8qoMi9IsabyZIrHZ3CL/FmFz0Jomee8O5ZDIBf9PD3Vht -7LGrhFV0d4QEJ1JrhkzO3bll/9bGXp+aEJlLdWr+aumXIOTkdnrG0CSqkM0gkLpHZPt/B7NTeLUK -YvJzQ85BK4FqLoUWlFPUa19yIqtRLULVAJyZv967lDtX/Zr1hstWO1uIAeV8KEsD+UmDfLJ/fOPt -jqF/YFOOVZ1QNBIPt5d7bIdKROf1beyAN/BYGW5KaHbwH5Lk6rWS02FREAutp9lfx1/cH6NcjKF+ -m7ee01ZvZl4HliDtC3T7Zk6LERXpgUl+b7DUUH8i119lAg2m9IUe2K4GS0qn0jFmwvjO5QimpAKW -RGhXxNUzzxkvFMSUHHuk2fCfDrGA4tGeEWSpiBE6doLlYsKA2KSD7ZPvfC+QsDJMlhVoSFLUmQjA -JOgc47OlIQ6SwJAfzyBfyjs4x7dtOvPmRLgOMWuIjnDrnBdSqEGULoe256YSxXXfW8AKbnuk5F6G -+TaU33fD6Q3AOfF5u0aOq0NZJ7cguyPpVkAh7DE9ZapD8j3fcEThuk0mEDuYn/PIjhs4ViFqUZPT -kcpG2om3PVODLAgfi49T3f+sHw== ------END CERTIFICATE----- +## +## Bundle of CA Root Certificates +## +## Certificate data from Mozilla as of: Wed Jan 1 04:12:10 2020 GMT +## +## This is a bundle of X.509 certificates of public Certificate Authorities +## (CA). These were automatically extracted from Mozilla's root certificates +## file (certdata.txt). This file can be found in the mozilla source tree: +## https://hg.mozilla.org/releases/mozilla-release/raw-file/default/security/nss/lib/ckfw/builtins/certdata.txt +## +## It contains the certificates in PEM format and therefore +## can be directly used with curl / libcurl / php_curl, or with +## an Apache+mod_ssl webserver for SSL client authentication. +## Just configure this file as the SSLCACertificateFile. +## +## Conversion done with mk-ca-bundle.pl version 1.27. +## SHA256: f3bdcd74612952da8476a9d4147f50b29ad0710b7dd95b4c8690500209986d70 +## + + +GlobalSign Root CA +================== +-----BEGIN CERTIFICATE----- +MIIDdTCCAl2gAwIBAgILBAAAAAABFUtaw5QwDQYJKoZIhvcNAQEFBQAwVzELMAkGA1UEBhMCQkUx +GTAXBgNVBAoTEEdsb2JhbFNpZ24gbnYtc2ExEDAOBgNVBAsTB1Jvb3QgQ0ExGzAZBgNVBAMTEkds +b2JhbFNpZ24gUm9vdCBDQTAeFw05ODA5MDExMjAwMDBaFw0yODAxMjgxMjAwMDBaMFcxCzAJBgNV +BAYTAkJFMRkwFwYDVQQKExBHbG9iYWxTaWduIG52LXNhMRAwDgYDVQQLEwdSb290IENBMRswGQYD +VQQDExJHbG9iYWxTaWduIFJvb3QgQ0EwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDa +DuaZjc6j40+Kfvvxi4Mla+pIH/EqsLmVEQS98GPR4mdmzxzdzxtIK+6NiY6arymAZavpxy0Sy6sc +THAHoT0KMM0VjU/43dSMUBUc71DuxC73/OlS8pF94G3VNTCOXkNz8kHp1Wrjsok6Vjk4bwY8iGlb +Kk3Fp1S4bInMm/k8yuX9ifUSPJJ4ltbcdG6TRGHRjcdGsnUOhugZitVtbNV4FpWi6cgKOOvyJBNP +c1STE4U6G7weNLWLBYy5d4ux2x8gkasJU26Qzns3dLlwR5EiUWMWea6xrkEmCMgZK9FGqkjWZCrX +gzT/LCrBbBlDSgeF59N89iFo7+ryUp9/k5DPAgMBAAGjQjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNV +HRMBAf8EBTADAQH/MB0GA1UdDgQWBBRge2YaRQ2XyolQL30EzTSo//z9SzANBgkqhkiG9w0BAQUF +AAOCAQEA1nPnfE920I2/7LqivjTFKDK1fPxsnCwrvQmeU79rXqoRSLblCKOzyj1hTdNGCbM+w6Dj +Y1Ub8rrvrTnhQ7k4o+YviiY776BQVvnGCv04zcQLcFGUl5gE38NflNUVyRRBnMRddWQVDf9VMOyG +j/8N7yy5Y0b2qvzfvGn9LhJIZJrglfCm7ymPAbEVtQwdpf5pLGkkeB6zpxxxYu7KyJesF12KwvhH +hm4qxFYxldBniYUr+WymXUadDKqC5JlR3XC321Y9YeRq4VzW9v493kHMB65jUr9TU/Qr6cf9tveC +X4XSQRjbgbMEHMUfpIBvFSDJ3gyICh3WZlXi/EjJKSZp4A== +-----END CERTIFICATE----- + +GlobalSign Root CA - R2 +======================= +-----BEGIN CERTIFICATE----- +MIIDujCCAqKgAwIBAgILBAAAAAABD4Ym5g0wDQYJKoZIhvcNAQEFBQAwTDEgMB4GA1UECxMXR2xv +YmFsU2lnbiBSb290IENBIC0gUjIxEzARBgNVBAoTCkdsb2JhbFNpZ24xEzARBgNVBAMTCkdsb2Jh +bFNpZ24wHhcNMDYxMjE1MDgwMDAwWhcNMjExMjE1MDgwMDAwWjBMMSAwHgYDVQQLExdHbG9iYWxT +aWduIFJvb3QgQ0EgLSBSMjETMBEGA1UEChMKR2xvYmFsU2lnbjETMBEGA1UEAxMKR2xvYmFsU2ln +bjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAKbPJA6+Lm8omUVCxKs+IVSbC9N/hHD6 +ErPLv4dfxn+G07IwXNb9rfF73OX4YJYJkhD10FPe+3t+c4isUoh7SqbKSaZeqKeMWhG8eoLrvozp +s6yWJQeXSpkqBy+0Hne/ig+1AnwblrjFuTosvNYSuetZfeLQBoZfXklqtTleiDTsvHgMCJiEbKjN +S7SgfQx5TfC4LcshytVsW33hoCmEofnTlEnLJGKRILzdC9XZzPnqJworc5HGnRusyMvo4KD0L5CL +TfuwNhv2GXqF4G3yYROIXJ/gkwpRl4pazq+r1feqCapgvdzZX99yqWATXgAByUr6P6TqBwMhAo6C +ygPCm48CAwEAAaOBnDCBmTAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4E +FgQUm+IHV2ccHsBqBt5ZtJot39wZhi4wNgYDVR0fBC8wLTAroCmgJ4YlaHR0cDovL2NybC5nbG9i +YWxzaWduLm5ldC9yb290LXIyLmNybDAfBgNVHSMEGDAWgBSb4gdXZxwewGoG3lm0mi3f3BmGLjAN +BgkqhkiG9w0BAQUFAAOCAQEAmYFThxxol4aR7OBKuEQLq4GsJ0/WwbgcQ3izDJr86iw8bmEbTUsp +9Z8FHSbBuOmDAGJFtqkIk7mpM0sYmsL4h4hO291xNBrBVNpGP+DTKqttVCL1OmLNIG+6KYnX3ZHu +01yiPqFbQfXf5WRDLenVOavSot+3i9DAgBkcRcAtjOj4LaR0VknFBbVPFd5uRHg5h6h+u/N5GJG7 +9G+dwfCMNYxdAfvDbbnvRG15RjF+Cv6pgsH/76tuIMRQyV+dTZsXjAzlAcmgQWpzU/qlULRuJQ/7 +TBj0/VLZjmmx6BEP3ojY+x1J96relc8geMJgEtslQIxq/H5COEBkEveegeGTLg== +-----END CERTIFICATE----- + +Verisign Class 3 Public Primary Certification Authority - G3 +============================================================ +-----BEGIN CERTIFICATE----- +MIIEGjCCAwICEQCbfgZJoz5iudXukEhxKe9XMA0GCSqGSIb3DQEBBQUAMIHKMQswCQYDVQQGEwJV +UzEXMBUGA1UEChMOVmVyaVNpZ24sIEluYy4xHzAdBgNVBAsTFlZlcmlTaWduIFRydXN0IE5ldHdv +cmsxOjA4BgNVBAsTMShjKSAxOTk5IFZlcmlTaWduLCBJbmMuIC0gRm9yIGF1dGhvcml6ZWQgdXNl +IG9ubHkxRTBDBgNVBAMTPFZlcmlTaWduIENsYXNzIDMgUHVibGljIFByaW1hcnkgQ2VydGlmaWNh +dGlvbiBBdXRob3JpdHkgLSBHMzAeFw05OTEwMDEwMDAwMDBaFw0zNjA3MTYyMzU5NTlaMIHKMQsw +CQYDVQQGEwJVUzEXMBUGA1UEChMOVmVyaVNpZ24sIEluYy4xHzAdBgNVBAsTFlZlcmlTaWduIFRy +dXN0IE5ldHdvcmsxOjA4BgNVBAsTMShjKSAxOTk5IFZlcmlTaWduLCBJbmMuIC0gRm9yIGF1dGhv +cml6ZWQgdXNlIG9ubHkxRTBDBgNVBAMTPFZlcmlTaWduIENsYXNzIDMgUHVibGljIFByaW1hcnkg +Q2VydGlmaWNhdGlvbiBBdXRob3JpdHkgLSBHMzCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoC +ggEBAMu6nFL8eB8aHm8bN3O9+MlrlBIwT/A2R/XQkQr1F8ilYcEWQE37imGQ5XYgwREGfassbqb1 +EUGO+i2tKmFZpGcmTNDovFJbcCAEWNF6yaRpvIMXZK0Fi7zQWM6NjPXr8EJJC52XJ2cybuGukxUc +cLwgTS8Y3pKI6GyFVxEa6X7jJhFUokWWVYPKMIno3Nij7SqAP395ZVc+FSBmCC+Vk7+qRy+oRpfw +EuL+wgorUeZ25rdGt+INpsyow0xZVYnm6FNcHOqd8GIWC6fJXwzw3sJ2zq/3avL6QaaiMxTJ5Xpj +055iN9WFZZ4O5lMkdBteHRJTW8cs54NJOxWuimi5V5cCAwEAATANBgkqhkiG9w0BAQUFAAOCAQEA +ERSWwauSCPc/L8my/uRan2Te2yFPhpk0djZX3dAVL8WtfxUfN2JzPtTnX84XA9s1+ivbrmAJXx5f +j267Cz3qWhMeDGBvtcC1IyIuBwvLqXTLR7sdwdela8wv0kL9Sd2nic9TutoAWii/gt/4uhMdUIaC +/Y4wjylGsB49Ndo4YhYYSq3mtlFs3q9i6wHQHiT+eo8SGhJouPtmmRQURVyu565pF4ErWjfJXir0 +xuKhXFSbplQAz/DxwceYMBo7Nhbbo27q/a2ywtrvAkcTisDxszGtTxzhT5yvDwyd93gN2PQ1VoDa +t20Xj50egWTh/sVFuq1ruQp6Tk9LhO5L8X3dEQ== +-----END CERTIFICATE----- + +Entrust.net Premium 2048 Secure Server CA +========================================= +-----BEGIN CERTIFICATE----- +MIIEKjCCAxKgAwIBAgIEOGPe+DANBgkqhkiG9w0BAQUFADCBtDEUMBIGA1UEChMLRW50cnVzdC5u +ZXQxQDA+BgNVBAsUN3d3dy5lbnRydXN0Lm5ldC9DUFNfMjA0OCBpbmNvcnAuIGJ5IHJlZi4gKGxp +bWl0cyBsaWFiLikxJTAjBgNVBAsTHChjKSAxOTk5IEVudHJ1c3QubmV0IExpbWl0ZWQxMzAxBgNV +BAMTKkVudHJ1c3QubmV0IENlcnRpZmljYXRpb24gQXV0aG9yaXR5ICgyMDQ4KTAeFw05OTEyMjQx +NzUwNTFaFw0yOTA3MjQxNDE1MTJaMIG0MRQwEgYDVQQKEwtFbnRydXN0Lm5ldDFAMD4GA1UECxQ3 +d3d3LmVudHJ1c3QubmV0L0NQU18yMDQ4IGluY29ycC4gYnkgcmVmLiAobGltaXRzIGxpYWIuKTEl +MCMGA1UECxMcKGMpIDE5OTkgRW50cnVzdC5uZXQgTGltaXRlZDEzMDEGA1UEAxMqRW50cnVzdC5u +ZXQgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgKDIwNDgpMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8A +MIIBCgKCAQEArU1LqRKGsuqjIAcVFmQqK0vRvwtKTY7tgHalZ7d4QMBzQshowNtTK91euHaYNZOL +Gp18EzoOH1u3Hs/lJBQesYGpjX24zGtLA/ECDNyrpUAkAH90lKGdCCmziAv1h3edVc3kw37XamSr +hRSGlVuXMlBvPci6Zgzj/L24ScF2iUkZ/cCovYmjZy/Gn7xxGWC4LeksyZB2ZnuU4q941mVTXTzW +nLLPKQP5L6RQstRIzgUyVYr9smRMDuSYB3Xbf9+5CFVghTAp+XtIpGmG4zU/HoZdenoVve8AjhUi +VBcAkCaTvA5JaJG/+EfTnZVCwQ5N328mz8MYIWJmQ3DW1cAH4QIDAQABo0IwQDAOBgNVHQ8BAf8E +BAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUVeSB0RGAvtiJuQijMfmhJAkWuXAwDQYJ +KoZIhvcNAQEFBQADggEBADubj1abMOdTmXx6eadNl9cZlZD7Bh/KM3xGY4+WZiT6QBshJ8rmcnPy +T/4xmf3IDExoU8aAghOY+rat2l098c5u9hURlIIM7j+VrxGrD9cv3h8Dj1csHsm7mhpElesYT6Yf +zX1XEC+bBAlahLVu2B064dae0Wx5XnkcFMXj0EyTO2U87d89vqbllRrDtRnDvV5bu/8j72gZyxKT +J1wDLW8w0B62GqzeWvfRqqgnpv55gcR5mTNXuhKwqeBCbJPKVt7+bYQLCIt+jerXmCHG8+c8eS9e +nNFMFY3h7CI3zJpDC5fcgJCNs2ebb0gIFVbPv/ErfF6adulZkMV8gzURZVE= +-----END CERTIFICATE----- + +Baltimore CyberTrust Root +========================= +-----BEGIN CERTIFICATE----- +MIIDdzCCAl+gAwIBAgIEAgAAuTANBgkqhkiG9w0BAQUFADBaMQswCQYDVQQGEwJJRTESMBAGA1UE +ChMJQmFsdGltb3JlMRMwEQYDVQQLEwpDeWJlclRydXN0MSIwIAYDVQQDExlCYWx0aW1vcmUgQ3li +ZXJUcnVzdCBSb290MB4XDTAwMDUxMjE4NDYwMFoXDTI1MDUxMjIzNTkwMFowWjELMAkGA1UEBhMC +SUUxEjAQBgNVBAoTCUJhbHRpbW9yZTETMBEGA1UECxMKQ3liZXJUcnVzdDEiMCAGA1UEAxMZQmFs +dGltb3JlIEN5YmVyVHJ1c3QgUm9vdDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAKME +uyKrmD1X6CZymrV51Cni4eiVgLGw41uOKymaZN+hXe2wCQVt2yguzmKiYv60iNoS6zjrIZ3AQSsB +UnuId9Mcj8e6uYi1agnnc+gRQKfRzMpijS3ljwumUNKoUMMo6vWrJYeKmpYcqWe4PwzV9/lSEy/C +G9VwcPCPwBLKBsua4dnKM3p31vjsufFoREJIE9LAwqSuXmD+tqYF/LTdB1kC1FkYmGP1pWPgkAx9 +XbIGevOF6uvUA65ehD5f/xXtabz5OTZydc93Uk3zyZAsuT3lySNTPx8kmCFcB5kpvcY67Oduhjpr +l3RjM71oGDHweI12v/yejl0qhqdNkNwnGjkCAwEAAaNFMEMwHQYDVR0OBBYEFOWdWTCCR1jMrPoI +VDaGezq1BE3wMBIGA1UdEwEB/wQIMAYBAf8CAQMwDgYDVR0PAQH/BAQDAgEGMA0GCSqGSIb3DQEB +BQUAA4IBAQCFDF2O5G9RaEIFoN27TyclhAO992T9Ldcw46QQF+vaKSm2eT929hkTI7gQCvlYpNRh +cL0EYWoSihfVCr3FvDB81ukMJY2GQE/szKN+OMY3EU/t3WgxjkzSswF07r51XgdIGn9w/xZchMB5 +hbgF/X++ZRGjD8ACtPhSNzkE1akxehi/oCr0Epn3o0WC4zxe9Z2etciefC7IpJ5OCBRLbf1wbWsa +Y71k5h+3zvDyny67G7fyUIhzksLi4xaNmjICq44Y3ekQEe5+NauQrz4wlHrQMz2nZQ/1/I6eYs9H +RCwBXbsdtTLSR9I4LtD+gdwyah617jzV/OeBHRnDJELqYzmp +-----END CERTIFICATE----- + +AddTrust External Root +====================== +-----BEGIN CERTIFICATE----- +MIIENjCCAx6gAwIBAgIBATANBgkqhkiG9w0BAQUFADBvMQswCQYDVQQGEwJTRTEUMBIGA1UEChML +QWRkVHJ1c3QgQUIxJjAkBgNVBAsTHUFkZFRydXN0IEV4dGVybmFsIFRUUCBOZXR3b3JrMSIwIAYD +VQQDExlBZGRUcnVzdCBFeHRlcm5hbCBDQSBSb290MB4XDTAwMDUzMDEwNDgzOFoXDTIwMDUzMDEw +NDgzOFowbzELMAkGA1UEBhMCU0UxFDASBgNVBAoTC0FkZFRydXN0IEFCMSYwJAYDVQQLEx1BZGRU +cnVzdCBFeHRlcm5hbCBUVFAgTmV0d29yazEiMCAGA1UEAxMZQWRkVHJ1c3QgRXh0ZXJuYWwgQ0Eg +Um9vdDCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBALf3GjPm8gAELTngTlvtH7xsD821 ++iO2zt6bETOXpClMfZOfvUq8k+0DGuOPz+VtUFrWlymUWoCwSXrbLpX9uMq/NzgtHj6RQa1wVsfw +Tz/oMp50ysiQVOnGXw94nZpAPA6sYapeFI+eh6FqUNzXmk6vBbOmcZSccbNQYArHE504B4YCqOmo +aSYYkKtMsE8jqzpPhNjfzp/haW+710LXa0Tkx63ubUFfclpxCDezeWWkWaCUN/cALw3CknLa0Dhy +2xSoRcRdKn23tNbE7qzNE0S3ySvdQwAl+mG5aWpYIxG3pzOPVnVZ9c0p10a3CitlttNCbxWyuHv7 +7+ldU9U0WicCAwEAAaOB3DCB2TAdBgNVHQ4EFgQUrb2YejS0Jvf6xCZU7wO94CTLVBowCwYDVR0P +BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wgZkGA1UdIwSBkTCBjoAUrb2YejS0Jvf6xCZU7wO94CTL +VBqhc6RxMG8xCzAJBgNVBAYTAlNFMRQwEgYDVQQKEwtBZGRUcnVzdCBBQjEmMCQGA1UECxMdQWRk +VHJ1c3QgRXh0ZXJuYWwgVFRQIE5ldHdvcmsxIjAgBgNVBAMTGUFkZFRydXN0IEV4dGVybmFsIENB +IFJvb3SCAQEwDQYJKoZIhvcNAQEFBQADggEBALCb4IUlwtYj4g+WBpKdQZic2YR5gdkeWxQHIzZl +j7DYd7usQWxHYINRsPkyPef89iYTx4AWpb9a/IfPeHmJIZriTAcKhjW88t5RxNKWt9x+Tu5w/Rw5 +6wwCURQtjr0W4MHfRnXnJK3s9EK0hZNwEGe6nQY1ShjTK3rMUUKhemPR5ruhxSvCNr4TDea9Y355 +e6cJDUCrat2PisP29owaQgVR1EX1n6diIWgVIEM8med8vSTYqZEXc4g/VhsxOBi0cQ+azcgOno4u +G+GMmIPLHzHxREzGBHNJdmAPx/i9F4BrLunMTA5amnkPIAou1Z5jJh5VkpTYghdae9C8x49OhgQ= +-----END CERTIFICATE----- + +Entrust Root Certification Authority +==================================== +-----BEGIN CERTIFICATE----- +MIIEkTCCA3mgAwIBAgIERWtQVDANBgkqhkiG9w0BAQUFADCBsDELMAkGA1UEBhMCVVMxFjAUBgNV +BAoTDUVudHJ1c3QsIEluYy4xOTA3BgNVBAsTMHd3dy5lbnRydXN0Lm5ldC9DUFMgaXMgaW5jb3Jw +b3JhdGVkIGJ5IHJlZmVyZW5jZTEfMB0GA1UECxMWKGMpIDIwMDYgRW50cnVzdCwgSW5jLjEtMCsG +A1UEAxMkRW50cnVzdCBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MB4XDTA2MTEyNzIwMjM0 +MloXDTI2MTEyNzIwNTM0MlowgbAxCzAJBgNVBAYTAlVTMRYwFAYDVQQKEw1FbnRydXN0LCBJbmMu +MTkwNwYDVQQLEzB3d3cuZW50cnVzdC5uZXQvQ1BTIGlzIGluY29ycG9yYXRlZCBieSByZWZlcmVu +Y2UxHzAdBgNVBAsTFihjKSAyMDA2IEVudHJ1c3QsIEluYy4xLTArBgNVBAMTJEVudHJ1c3QgUm9v +dCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB +ALaVtkNC+sZtKm9I35RMOVcF7sN5EUFoNu3s/poBj6E4KPz3EEZmLk0eGrEaTsbRwJWIsMn/MYsz +A9u3g3s+IIRe7bJWKKf44LlAcTfFy0cOlypowCKVYhXbR9n10Cv/gkvJrT7eTNuQgFA/CYqEAOww +Cj0Yzfv9KlmaI5UXLEWeH25DeW0MXJj+SKfFI0dcXv1u5x609mhF0YaDW6KKjbHjKYD+JXGIrb68 +j6xSlkuqUY3kEzEZ6E5Nn9uss2rVvDlUccp6en+Q3X0dgNmBu1kmwhH+5pPi94DkZfs0Nw4pgHBN +rziGLp5/V6+eF67rHMsoIV+2HNjnogQi+dPa2MsCAwEAAaOBsDCBrTAOBgNVHQ8BAf8EBAMCAQYw +DwYDVR0TAQH/BAUwAwEB/zArBgNVHRAEJDAigA8yMDA2MTEyNzIwMjM0MlqBDzIwMjYxMTI3MjA1 +MzQyWjAfBgNVHSMEGDAWgBRokORnpKZTgMeGZqTx90tD+4S9bTAdBgNVHQ4EFgQUaJDkZ6SmU4DH +hmak8fdLQ/uEvW0wHQYJKoZIhvZ9B0EABBAwDhsIVjcuMTo0LjADAgSQMA0GCSqGSIb3DQEBBQUA +A4IBAQCT1DCw1wMgKtD5Y+iRDAUgqV8ZyntyTtSx29CW+1RaGSwMCPeyvIWonX9tO1KzKtvn1ISM +Y/YPyyYBkVBs9F8U4pN0wBOeMDpQ47RgxRzwIkSNcUesyBrJ6ZuaAGAT/3B+XxFNSRuzFVJ7yVTa +v52Vr2ua2J7p8eRDjeIRRDq/r72DQnNSi6q7pynP9WQcCk3RvKqsnyrQ/39/2n3qse0wJcGE2jTS +W3iDVuycNsMm4hH2Z0kdkquM++v/eu6FSqdQgPCnXEqULl8FmTxSQeDNtGPPAUO6nIPcj2A781q0 +tHuu2guQOHXvgR1m0vdXcDazv/wor3ElhVsT/h5/WrQ8 +-----END CERTIFICATE----- + +GeoTrust Global CA +================== +-----BEGIN CERTIFICATE----- +MIIDVDCCAjygAwIBAgIDAjRWMA0GCSqGSIb3DQEBBQUAMEIxCzAJBgNVBAYTAlVTMRYwFAYDVQQK +Ew1HZW9UcnVzdCBJbmMuMRswGQYDVQQDExJHZW9UcnVzdCBHbG9iYWwgQ0EwHhcNMDIwNTIxMDQw +MDAwWhcNMjIwNTIxMDQwMDAwWjBCMQswCQYDVQQGEwJVUzEWMBQGA1UEChMNR2VvVHJ1c3QgSW5j +LjEbMBkGA1UEAxMSR2VvVHJ1c3QgR2xvYmFsIENBMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB +CgKCAQEA2swYYzD99BcjGlZ+W988bDjkcbd4kdS8odhM+KhDtgPpTSEHCIjaWC9mOSm9BXiLnTjo +BbdqfnGk5sRgprDvgOSJKA+eJdbtg/OtppHHmMlCGDUUna2YRpIuT8rxh0PBFpVXLVDviS2Aelet +8u5fa9IAjbkU+BQVNdnARqN7csiRv8lVK83Qlz6cJmTM386DGXHKTubU1XupGc1V3sjs0l44U+Vc +T4wt/lAjNvxm5suOpDkZALeVAjmRCw7+OC7RHQWa9k0+bw8HHa8sHo9gOeL6NlMTOdReJivbPagU +vTLrGAMoUgRx5aszPeE4uwc2hGKceeoWMPRfwCvocWvk+QIDAQABo1MwUTAPBgNVHRMBAf8EBTAD +AQH/MB0GA1UdDgQWBBTAephojYn7qwVkDBF9qn1luMrMTjAfBgNVHSMEGDAWgBTAephojYn7qwVk +DBF9qn1luMrMTjANBgkqhkiG9w0BAQUFAAOCAQEANeMpauUvXVSOKVCUn5kaFOSPeCpilKInZ57Q +zxpeR+nBsqTP3UEaBU6bS+5Kb1VSsyShNwrrZHYqLizz/Tt1kL/6cdjHPTfStQWVYrmm3ok9Nns4 +d0iXrKYgjy6myQzCsplFAMfOEVEiIuCl6rYVSAlk6l5PdPcFPseKUgzbFbS9bZvlxrFUaKnjaZC2 +mqUPuLk/IH2uSrW4nOQdtqvmlKXBx4Ot2/Unhw4EbNX/3aBd7YdStysVAq45pmp06drE57xNNB6p +XE0zX5IJL4hmXXeXxx12E6nV5fEWCRE11azbJHFwLJhWC9kXtNHjUStedejV0NxPNO3CBWaAocvm +Mw== +-----END CERTIFICATE----- + +GeoTrust Universal CA +===================== +-----BEGIN CERTIFICATE----- +MIIFaDCCA1CgAwIBAgIBATANBgkqhkiG9w0BAQUFADBFMQswCQYDVQQGEwJVUzEWMBQGA1UEChMN +R2VvVHJ1c3QgSW5jLjEeMBwGA1UEAxMVR2VvVHJ1c3QgVW5pdmVyc2FsIENBMB4XDTA0MDMwNDA1 +MDAwMFoXDTI5MDMwNDA1MDAwMFowRTELMAkGA1UEBhMCVVMxFjAUBgNVBAoTDUdlb1RydXN0IElu +Yy4xHjAcBgNVBAMTFUdlb1RydXN0IFVuaXZlcnNhbCBDQTCCAiIwDQYJKoZIhvcNAQEBBQADggIP +ADCCAgoCggIBAKYVVaCjxuAfjJ0hUNfBvitbtaSeodlyWL0AG0y/YckUHUWCq8YdgNY96xCcOq9t +JPi8cQGeBvV8Xx7BDlXKg5pZMK4ZyzBIle0iN430SppyZj6tlcDgFgDgEB8rMQ7XlFTTQjOgNB0e +RXbdT8oYN+yFFXoZCPzVx5zw8qkuEKmS5j1YPakWaDwvdSEYfyh3peFhF7em6fgemdtzbvQKoiFs +7tqqhZJmr/Z6a4LauiIINQ/PQvE1+mrufislzDoR5G2vc7J2Ha3QsnhnGqQ5HFELZ1aD/ThdDc7d +8Lsrlh/eezJS/R27tQahsiFepdaVaH/wmZ7cRQg+59IJDTWU3YBOU5fXtQlEIGQWFwMCTFMNaN7V +qnJNk22CDtucvc+081xdVHppCZbW2xHBjXWotM85yM48vCR85mLK4b19p71XZQvk/iXttmkQ3Cga +Rr0BHdCXteGYO8A3ZNY9lO4L4fUorgtWv3GLIylBjobFS1J72HGrH4oVpjuDWtdYAVHGTEHZf9hB +Z3KiKN9gg6meyHv8U3NyWfWTehd2Ds735VzZC1U0oqpbtWpU5xPKV+yXbfReBi9Fi1jUIxaS5BZu +KGNZMN9QAZxjiRqf2xeUgnA3wySemkfWWspOqGmJch+RbNt+nhutxx9z3SxPGWX9f5NAEC7S8O08 +ni4oPmkmM8V7AgMBAAGjYzBhMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFNq7LqqwDLiIJlF0 +XG0D08DYj3rWMB8GA1UdIwQYMBaAFNq7LqqwDLiIJlF0XG0D08DYj3rWMA4GA1UdDwEB/wQEAwIB +hjANBgkqhkiG9w0BAQUFAAOCAgEAMXjmx7XfuJRAyXHEqDXsRh3ChfMoWIawC/yOsjmPRFWrZIRc +aanQmjg8+uUfNeVE44B5lGiku8SfPeE0zTBGi1QrlaXv9z+ZhP015s8xxtxqv6fXIwjhmF7DWgh2 +qaavdy+3YL1ERmrvl/9zlcGO6JP7/TG37FcREUWbMPEaiDnBTzynANXH/KttgCJwpQzgXQQpAvvL +oJHRfNbDflDVnVi+QTjruXU8FdmbyUqDWcDaU/0zuzYYm4UPFd3uLax2k7nZAY1IEKj79TiG8dsK +xr2EoyNB3tZ3b4XUhRxQ4K5RirqNPnbiucon8l+f725ZDQbYKxek0nxru18UGkiPGkzns0ccjkxF +KyDuSN/n3QmOGKjaQI2SJhFTYXNd673nxE0pN2HrrDktZy4W1vUAg4WhzH92xH3kt0tm7wNFYGm2 +DFKWkoRepqO1pD4r2czYG0eq8kTaT/kD6PAUyz/zg97QwVTjt+gKN02LIFkDMBmhLMi9ER/frslK +xfMnZmaGrGiR/9nmUxwPi1xpZQomyB40w11Re9epnAahNt3ViZS82eQtDF4JbAiXfKM9fJP/P6EU +p8+1Xevb2xzEdt+Iub1FBZUbrvxGakyvSOPOrg/SfuvmbJxPgWp6ZKy7PtXny3YuxadIwVyQD8vI +P/rmMuGNG2+k5o7Y+SlIis5z/iw= +-----END CERTIFICATE----- + +GeoTrust Universal CA 2 +======================= +-----BEGIN CERTIFICATE----- +MIIFbDCCA1SgAwIBAgIBATANBgkqhkiG9w0BAQUFADBHMQswCQYDVQQGEwJVUzEWMBQGA1UEChMN +R2VvVHJ1c3QgSW5jLjEgMB4GA1UEAxMXR2VvVHJ1c3QgVW5pdmVyc2FsIENBIDIwHhcNMDQwMzA0 +MDUwMDAwWhcNMjkwMzA0MDUwMDAwWjBHMQswCQYDVQQGEwJVUzEWMBQGA1UEChMNR2VvVHJ1c3Qg +SW5jLjEgMB4GA1UEAxMXR2VvVHJ1c3QgVW5pdmVyc2FsIENBIDIwggIiMA0GCSqGSIb3DQEBAQUA +A4ICDwAwggIKAoICAQCzVFLByT7y2dyxUxpZKeexw0Uo5dfR7cXFS6GqdHtXr0om/Nj1XqduGdt0 +DE81WzILAePb63p3NeqqWuDW6KFXlPCQo3RWlEQwAx5cTiuFJnSCegx2oG9NzkEtoBUGFF+3Qs17 +j1hhNNwqCPkuwwGmIkQcTAeC5lvO0Ep8BNMZcyfwqph/Lq9O64ceJHdqXbboW0W63MOhBW9Wjo8Q +JqVJwy7XQYci4E+GymC16qFjwAGXEHm9ADwSbSsVsaxLse4YuU6W3Nx2/zu+z18DwPw76L5GG//a +QMJS9/7jOvdqdzXQ2o3rXhhqMcceujwbKNZrVMaqW9eiLBsZzKIC9ptZvTdrhrVtgrrY6slWvKk2 +WP0+GfPtDCapkzj4T8FdIgbQl+rhrcZV4IErKIM6+vR7IVEAvlI4zs1meaj0gVbi0IMJR1FbUGrP +20gaXT73y/Zl92zxlfgCOzJWgjl6W70viRu/obTo/3+NjN8D8WBOWBFM66M/ECuDmgFz2ZRthAAn +ZqzwcEAJQpKtT5MNYQlRJNiS1QuUYbKHsu3/mjX/hVTK7URDrBs8FmtISgocQIgfksILAAX/8sgC +SqSqqcyZlpwvWOB94b67B9xfBHJcMTTD7F8t4D1kkCLm0ey4Lt1ZrtmhN79UNdxzMk+MBB4zsslG +8dhcyFVQyWi9qLo2CQIDAQABo2MwYTAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBR281Xh+qQ2 ++/CfXGJx7Tz0RzgQKzAfBgNVHSMEGDAWgBR281Xh+qQ2+/CfXGJx7Tz0RzgQKzAOBgNVHQ8BAf8E +BAMCAYYwDQYJKoZIhvcNAQEFBQADggIBAGbBxiPz2eAubl/oz66wsCVNK/g7WJtAJDday6sWSf+z +dXkzoS9tcBc0kf5nfo/sm+VegqlVHy/c1FEHEv6sFj4sNcZj/NwQ6w2jqtB8zNHQL1EuxBRa3ugZ +4T7GzKQp5y6EqgYweHZUcyiYWTjgAA1i00J9IZ+uPTqM1fp3DRgrFg5fNuH8KrUwJM/gYwx7WBr+ +mbpCErGR9Hxo4sjoryzqyX6uuyo9DRXcNJW2GHSoag/HtPQTxORb7QrSpJdMKu0vbBKJPfEncKpq +A1Ihn0CoZ1Dy81of398j9tx4TuaYT1U6U+Pv8vSfx3zYWK8pIpe44L2RLrB27FcRz+8pRPPphXpg +Y+RdM4kX2TGq2tbzGDVyz4crL2MjhF2EjD9XoIj8mZEoJmmZ1I+XRL6O1UixpCgp8RW04eWe3fiP +pm8m1wk8OhwRDqZsN/etRIcsKMfYdIKz0G9KV7s1KSegi+ghp4dkNl3M2Basx7InQJJVOCiNUW7d +FGdTbHFcJoRNdVq2fmBWqU2t+5sel/MN2dKXVHfaPRK34B7vCAas+YWH6aLcr34YEoP9VhdBLtUp +gn2Z9DH2canPLAEnpQW5qrJITirvn5NSUZU8UnOOVkwXQMAJKOSLakhT2+zNVVXxxvjpoixMptEm +X36vWkzaH6byHCx+rgIW0lbQL1dTR+iS +-----END CERTIFICATE----- + +Comodo AAA Services root +======================== +-----BEGIN CERTIFICATE----- +MIIEMjCCAxqgAwIBAgIBATANBgkqhkiG9w0BAQUFADB7MQswCQYDVQQGEwJHQjEbMBkGA1UECAwS +R3JlYXRlciBNYW5jaGVzdGVyMRAwDgYDVQQHDAdTYWxmb3JkMRowGAYDVQQKDBFDb21vZG8gQ0Eg +TGltaXRlZDEhMB8GA1UEAwwYQUFBIENlcnRpZmljYXRlIFNlcnZpY2VzMB4XDTA0MDEwMTAwMDAw +MFoXDTI4MTIzMTIzNTk1OVowezELMAkGA1UEBhMCR0IxGzAZBgNVBAgMEkdyZWF0ZXIgTWFuY2hl +c3RlcjEQMA4GA1UEBwwHU2FsZm9yZDEaMBgGA1UECgwRQ29tb2RvIENBIExpbWl0ZWQxITAfBgNV +BAMMGEFBQSBDZXJ0aWZpY2F0ZSBTZXJ2aWNlczCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoC +ggEBAL5AnfRu4ep2hxxNRUSOvkbIgwadwSr+GB+O5AL686tdUIoWMQuaBtDFcCLNSS1UY8y2bmhG +C1Pqy0wkwLxyTurxFa70VJoSCsN6sjNg4tqJVfMiWPPe3M/vg4aijJRPn2jymJBGhCfHdr/jzDUs +i14HZGWCwEiwqJH5YZ92IFCokcdmtet4YgNW8IoaE+oxox6gmf049vYnMlhvB/VruPsUK6+3qszW +Y19zjNoFmag4qMsXeDZRrOme9Hg6jc8P2ULimAyrL58OAd7vn5lJ8S3frHRNG5i1R8XlKdH5kBjH +Ypy+g8cmez6KJcfA3Z3mNWgQIJ2P2N7Sw4ScDV7oL8kCAwEAAaOBwDCBvTAdBgNVHQ4EFgQUoBEK +Iz6W8Qfs4q8p74Klf9AwpLQwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wewYDVR0f +BHQwcjA4oDagNIYyaHR0cDovL2NybC5jb21vZG9jYS5jb20vQUFBQ2VydGlmaWNhdGVTZXJ2aWNl +cy5jcmwwNqA0oDKGMGh0dHA6Ly9jcmwuY29tb2RvLm5ldC9BQUFDZXJ0aWZpY2F0ZVNlcnZpY2Vz +LmNybDANBgkqhkiG9w0BAQUFAAOCAQEACFb8AvCb6P+k+tZ7xkSAzk/ExfYAWMymtrwUSWgEdujm +7l3sAg9g1o1QGE8mTgHj5rCl7r+8dFRBv/38ErjHT1r0iWAFf2C3BUrz9vHCv8S5dIa2LX1rzNLz +Rt0vxuBqw8M0Ayx9lt1awg6nCpnBBYurDC/zXDrPbDdVCYfeU0BsWO/8tqtlbgT2G9w84FoVxp7Z +8VlIMCFlA2zs6SFz7JsDoeA3raAVGI/6ugLOpyypEBMs1OUIJqsil2D4kF501KKaU73yqWjgom7C +12yxow+ev+to51byrvLjKzg6CYG1a4XXvi3tPxq3smPi9WIsgtRqAEFQ8TmDn5XpNpaYbg== +-----END CERTIFICATE----- + +QuoVadis Root CA +================ +-----BEGIN CERTIFICATE----- +MIIF0DCCBLigAwIBAgIEOrZQizANBgkqhkiG9w0BAQUFADB/MQswCQYDVQQGEwJCTTEZMBcGA1UE +ChMQUXVvVmFkaXMgTGltaXRlZDElMCMGA1UECxMcUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0 +eTEuMCwGA1UEAxMlUXVvVmFkaXMgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw0wMTAz +MTkxODMzMzNaFw0yMTAzMTcxODMzMzNaMH8xCzAJBgNVBAYTAkJNMRkwFwYDVQQKExBRdW9WYWRp +cyBMaW1pdGVkMSUwIwYDVQQLExxSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MS4wLAYDVQQD +EyVRdW9WYWRpcyBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MIIBIjANBgkqhkiG9w0BAQEF +AAOCAQ8AMIIBCgKCAQEAv2G1lVO6V/z68mcLOhrfEYBklbTRvM16z/Ypli4kVEAkOPcahdxYTMuk +J0KX0J+DisPkBgNbAKVRHnAEdOLB1Dqr1607BxgFjv2DrOpm2RgbaIr1VxqYuvXtdj182d6UajtL +F8HVj71lODqV0D1VNk7feVcxKh7YWWVJWCCYfqtffp/p1k3sg3Spx2zY7ilKhSoGFPlU5tPaZQeL +YzcS19Dsw3sgQUSj7cugF+FxZc4dZjH3dgEZyH0DWLaVSR2mEiboxgx24ONmy+pdpibu5cxfvWen +AScOospUxbF6lR1xHkopigPcakXBpBlebzbNw6Kwt/5cOOJSvPhEQ+aQuwIDAQABo4ICUjCCAk4w +PQYIKwYBBQUHAQEEMTAvMC0GCCsGAQUFBzABhiFodHRwczovL29jc3AucXVvdmFkaXNvZmZzaG9y +ZS5jb20wDwYDVR0TAQH/BAUwAwEB/zCCARoGA1UdIASCAREwggENMIIBCQYJKwYBBAG+WAABMIH7 +MIHUBggrBgEFBQcCAjCBxxqBxFJlbGlhbmNlIG9uIHRoZSBRdW9WYWRpcyBSb290IENlcnRpZmlj +YXRlIGJ5IGFueSBwYXJ0eSBhc3N1bWVzIGFjY2VwdGFuY2Ugb2YgdGhlIHRoZW4gYXBwbGljYWJs +ZSBzdGFuZGFyZCB0ZXJtcyBhbmQgY29uZGl0aW9ucyBvZiB1c2UsIGNlcnRpZmljYXRpb24gcHJh +Y3RpY2VzLCBhbmQgdGhlIFF1b1ZhZGlzIENlcnRpZmljYXRlIFBvbGljeS4wIgYIKwYBBQUHAgEW +Fmh0dHA6Ly93d3cucXVvdmFkaXMuYm0wHQYDVR0OBBYEFItLbe3TKbkGGew5Oanwl4Rqy+/fMIGu +BgNVHSMEgaYwgaOAFItLbe3TKbkGGew5Oanwl4Rqy+/foYGEpIGBMH8xCzAJBgNVBAYTAkJNMRkw +FwYDVQQKExBRdW9WYWRpcyBMaW1pdGVkMSUwIwYDVQQLExxSb290IENlcnRpZmljYXRpb24gQXV0 +aG9yaXR5MS4wLAYDVQQDEyVRdW9WYWRpcyBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5ggQ6 +tlCLMA4GA1UdDwEB/wQEAwIBBjANBgkqhkiG9w0BAQUFAAOCAQEAitQUtf70mpKnGdSkfnIYj9lo +fFIk3WdvOXrEql494liwTXCYhGHoG+NpGA7O+0dQoE7/8CQfvbLO9Sf87C9TqnN7Az10buYWnuul +LsS/VidQK2K6vkscPFVcQR0kvoIgR13VRH56FmjffU1RcHhXHTMe/QKZnAzNCgVPx7uOpHX6Sm2x +gI4JVrmcGmD+XcHXetwReNDWXcG31a0ymQM6isxUJTkxgXsTIlG6Rmyhu576BGxJJnSP0nPrzDCi +5upZIof4l/UO/erMkqQWxFIY6iHOsfHmhIHluqmGKPJDWl0Snawe2ajlCmqnf6CHKc/yiU3U7MXi +5nrQNiOKSnQ2+Q== +-----END CERTIFICATE----- + +QuoVadis Root CA 2 +================== +-----BEGIN CERTIFICATE----- +MIIFtzCCA5+gAwIBAgICBQkwDQYJKoZIhvcNAQEFBQAwRTELMAkGA1UEBhMCQk0xGTAXBgNVBAoT +EFF1b1ZhZGlzIExpbWl0ZWQxGzAZBgNVBAMTElF1b1ZhZGlzIFJvb3QgQ0EgMjAeFw0wNjExMjQx +ODI3MDBaFw0zMTExMjQxODIzMzNaMEUxCzAJBgNVBAYTAkJNMRkwFwYDVQQKExBRdW9WYWRpcyBM +aW1pdGVkMRswGQYDVQQDExJRdW9WYWRpcyBSb290IENBIDIwggIiMA0GCSqGSIb3DQEBAQUAA4IC +DwAwggIKAoICAQCaGMpLlA0ALa8DKYrwD4HIrkwZhR0In6spRIXzL4GtMh6QRr+jhiYaHv5+HBg6 +XJxgFyo6dIMzMH1hVBHL7avg5tKifvVrbxi3Cgst/ek+7wrGsxDp3MJGF/hd/aTa/55JWpzmM+Yk +lvc/ulsrHHo1wtZn/qtmUIttKGAr79dgw8eTvI02kfN/+NsRE8Scd3bBrrcCaoF6qUWD4gXmuVbB +lDePSHFjIuwXZQeVikvfj8ZaCuWw419eaxGrDPmF60Tp+ARz8un+XJiM9XOva7R+zdRcAitMOeGy +lZUtQofX1bOQQ7dsE/He3fbE+Ik/0XX1ksOR1YqI0JDs3G3eicJlcZaLDQP9nL9bFqyS2+r+eXyt +66/3FsvbzSUr5R/7mp/iUcw6UwxI5g69ybR2BlLmEROFcmMDBOAENisgGQLodKcftslWZvB1Jdxn +wQ5hYIizPtGo/KPaHbDRsSNU30R2be1B2MGyIrZTHN81Hdyhdyox5C315eXbyOD/5YDXC2Og/zOh +D7osFRXql7PSorW+8oyWHhqPHWykYTe5hnMz15eWniN9gqRMgeKh0bpnX5UHoycR7hYQe7xFSkyy +BNKr79X9DFHOUGoIMfmR2gyPZFwDwzqLID9ujWc9Otb+fVuIyV77zGHcizN300QyNQliBJIWENie +J0f7OyHj+OsdWwIDAQABo4GwMIGtMA8GA1UdEwEB/wQFMAMBAf8wCwYDVR0PBAQDAgEGMB0GA1Ud +DgQWBBQahGK8SEwzJQTU7tD2A8QZRtGUazBuBgNVHSMEZzBlgBQahGK8SEwzJQTU7tD2A8QZRtGU +a6FJpEcwRTELMAkGA1UEBhMCQk0xGTAXBgNVBAoTEFF1b1ZhZGlzIExpbWl0ZWQxGzAZBgNVBAMT +ElF1b1ZhZGlzIFJvb3QgQ0EgMoICBQkwDQYJKoZIhvcNAQEFBQADggIBAD4KFk2fBluornFdLwUv +Z+YTRYPENvbzwCYMDbVHZF34tHLJRqUDGCdViXh9duqWNIAXINzng/iN/Ae42l9NLmeyhP3ZRPx3 +UIHmfLTJDQtyU/h2BwdBR5YM++CCJpNVjP4iH2BlfF/nJrP3MpCYUNQ3cVX2kiF495V5+vgtJodm +VjB3pjd4M1IQWK4/YY7yarHvGH5KWWPKjaJW1acvvFYfzznB4vsKqBUsfU16Y8Zsl0Q80m/DShcK ++JDSV6IZUaUtl0HaB0+pUNqQjZRG4T7wlP0QADj1O+hA4bRuVhogzG9Yje0uRY/W6ZM/57Es3zrW +IozchLsib9D45MY56QSIPMO661V6bYCZJPVsAfv4l7CUW+v90m/xd2gNNWQjrLhVoQPRTUIZ3Ph1 +WVaj+ahJefivDrkRoHy3au000LYmYjgahwz46P0u05B/B5EqHdZ+XIWDmbA4CD/pXvk1B+TJYm5X +f6dQlfe6yJvmjqIBxdZmv3lh8zwc4bmCXF2gw+nYSL0ZohEUGW6yhhtoPkg3Goi3XZZenMfvJ2II +4pEZXNLxId26F0KCl3GBUzGpn/Z9Yr9y4aOTHcyKJloJONDO1w2AFrR4pTqHTI2KpdVGl/IsELm8 +VCLAAVBpQ570su9t+Oza8eOx79+Rj1QqCyXBJhnEUhAFZdWCEOrCMc0u +-----END CERTIFICATE----- + +QuoVadis Root CA 3 +================== +-----BEGIN CERTIFICATE----- +MIIGnTCCBIWgAwIBAgICBcYwDQYJKoZIhvcNAQEFBQAwRTELMAkGA1UEBhMCQk0xGTAXBgNVBAoT +EFF1b1ZhZGlzIExpbWl0ZWQxGzAZBgNVBAMTElF1b1ZhZGlzIFJvb3QgQ0EgMzAeFw0wNjExMjQx +OTExMjNaFw0zMTExMjQxOTA2NDRaMEUxCzAJBgNVBAYTAkJNMRkwFwYDVQQKExBRdW9WYWRpcyBM +aW1pdGVkMRswGQYDVQQDExJRdW9WYWRpcyBSb290IENBIDMwggIiMA0GCSqGSIb3DQEBAQUAA4IC +DwAwggIKAoICAQDMV0IWVJzmmNPTTe7+7cefQzlKZbPoFog02w1ZkXTPkrgEQK0CSzGrvI2RaNgg +DhoB4hp7Thdd4oq3P5kazethq8Jlph+3t723j/z9cI8LoGe+AaJZz3HmDyl2/7FWeUUrH556VOij +KTVopAFPD6QuN+8bv+OPEKhyq1hX51SGyMnzW9os2l2ObjyjPtr7guXd8lyyBTNvijbO0BNO/79K +DDRMpsMhvVAEVeuxu537RR5kFd5VAYwCdrXLoT9CabwvvWhDFlaJKjdhkf2mrk7AyxRllDdLkgbv +BNDInIjbC3uBr7E9KsRlOni27tyAsdLTmZw67mtaa7ONt9XOnMK+pUsvFrGeaDsGb659n/je7Mwp +p5ijJUMv7/FfJuGITfhebtfZFG4ZM2mnO4SJk8RTVROhUXhA+LjJou57ulJCg54U7QVSWllWp5f8 +nT8KKdjcT5EOE7zelaTfi5m+rJsziO+1ga8bxiJTyPbH7pcUsMV8eFLI8M5ud2CEpukqdiDtWAEX +MJPpGovgc2PZapKUSU60rUqFxKMiMPwJ7Wgic6aIDFUhWMXhOp8q3crhkODZc6tsgLjoC2SToJyM +Gf+z0gzskSaHirOi4XCPLArlzW1oUevaPwV/izLmE1xr/l9A4iLItLRkT9a6fUg+qGkM17uGcclz +uD87nSVL2v9A6wIDAQABo4IBlTCCAZEwDwYDVR0TAQH/BAUwAwEB/zCB4QYDVR0gBIHZMIHWMIHT +BgkrBgEEAb5YAAMwgcUwgZMGCCsGAQUFBwICMIGGGoGDQW55IHVzZSBvZiB0aGlzIENlcnRpZmlj +YXRlIGNvbnN0aXR1dGVzIGFjY2VwdGFuY2Ugb2YgdGhlIFF1b1ZhZGlzIFJvb3QgQ0EgMyBDZXJ0 +aWZpY2F0ZSBQb2xpY3kgLyBDZXJ0aWZpY2F0aW9uIFByYWN0aWNlIFN0YXRlbWVudC4wLQYIKwYB +BQUHAgEWIWh0dHA6Ly93d3cucXVvdmFkaXNnbG9iYWwuY29tL2NwczALBgNVHQ8EBAMCAQYwHQYD +VR0OBBYEFPLAE+CCQz777i9nMpY1XNu4ywLQMG4GA1UdIwRnMGWAFPLAE+CCQz777i9nMpY1XNu4 +ywLQoUmkRzBFMQswCQYDVQQGEwJCTTEZMBcGA1UEChMQUXVvVmFkaXMgTGltaXRlZDEbMBkGA1UE +AxMSUXVvVmFkaXMgUm9vdCBDQSAzggIFxjANBgkqhkiG9w0BAQUFAAOCAgEAT62gLEz6wPJv92ZV +qyM07ucp2sNbtrCD2dDQ4iH782CnO11gUyeim/YIIirnv6By5ZwkajGxkHon24QRiSemd1o417+s +hvzuXYO8BsbRd2sPbSQvS3pspweWyuOEn62Iix2rFo1bZhfZFvSLgNLd+LJ2w/w4E6oM3kJpK27z +POuAJ9v1pkQNn1pVWQvVDVJIxa6f8i+AxeoyUDUSly7B4f/xI4hROJ/yZlZ25w9Rl6VSDE1JUZU2 +Pb+iSwwQHYaZTKrzchGT5Or2m9qoXadNt54CrnMAyNojA+j56hl0YgCUyyIgvpSnWbWCar6ZeXqp +8kokUvd0/bpO5qgdAm6xDYBEwa7TIzdfu4V8K5Iu6H6li92Z4b8nby1dqnuH/grdS/yO9SbkbnBC +bjPsMZ57k8HkyWkaPcBrTiJt7qtYTcbQQcEr6k8Sh17rRdhs9ZgC06DYVYoGmRmioHfRMJ6szHXu +g/WwYjnPbFfiTNKRCw51KBuav/0aQ/HKd/s7j2G4aSgWQgRecCocIdiP4b0jWy10QJLZYxkNc91p +vGJHvOB0K7Lrfb5BG7XARsWhIstfTsEokt4YutUqKLsRixeTmJlglFwjz1onl14LBQaTNx47aTbr +qZ5hHY8y2o4M1nQ+ewkk2gF3R8Q7zTSMmfXK4SVhM7JZG+Ju1zdXtg2pEto= +-----END CERTIFICATE----- + +Security Communication Root CA +============================== +-----BEGIN CERTIFICATE----- +MIIDWjCCAkKgAwIBAgIBADANBgkqhkiG9w0BAQUFADBQMQswCQYDVQQGEwJKUDEYMBYGA1UEChMP +U0VDT00gVHJ1c3QubmV0MScwJQYDVQQLEx5TZWN1cml0eSBDb21tdW5pY2F0aW9uIFJvb3RDQTEw +HhcNMDMwOTMwMDQyMDQ5WhcNMjMwOTMwMDQyMDQ5WjBQMQswCQYDVQQGEwJKUDEYMBYGA1UEChMP +U0VDT00gVHJ1c3QubmV0MScwJQYDVQQLEx5TZWN1cml0eSBDb21tdW5pY2F0aW9uIFJvb3RDQTEw +ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCzs/5/022x7xZ8V6UMbXaKL0u/ZPtM7orw +8yl89f/uKuDp6bpbZCKamm8sOiZpUQWZJtzVHGpxxpp9Hp3dfGzGjGdnSj74cbAZJ6kJDKaVv0uM +DPpVmDvY6CKhS3E4eayXkmmziX7qIWgGmBSWh9JhNrxtJ1aeV+7AwFb9Ms+k2Y7CI9eNqPPYJayX +5HA49LY6tJ07lyZDo6G8SVlyTCMwhwFY9k6+HGhWZq/NQV3Is00qVUarH9oe4kA92819uZKAnDfd +DJZkndwi92SL32HeFZRSFaB9UslLqCHJxrHty8OVYNEP8Ktw+N/LTX7s1vqr2b1/VPKl6Xn62dZ2 +JChzAgMBAAGjPzA9MB0GA1UdDgQWBBSgc0mZaNyFW2XjmygvV5+9M7wHSDALBgNVHQ8EBAMCAQYw +DwYDVR0TAQH/BAUwAwEB/zANBgkqhkiG9w0BAQUFAAOCAQEAaECpqLvkT115swW1F7NgE+vGkl3g +0dNq/vu+m22/xwVtWSDEHPC32oRYAmP6SBbvT6UL90qY8j+eG61Ha2POCEfrUj94nK9NrvjVT8+a +mCoQQTlSxN3Zmw7vkwGusi7KaEIkQmywszo+zenaSMQVy+n5Bw+SUEmK3TGXX8npN6o7WWWXlDLJ +s58+OmJYxUmtYg5xpTKqL8aJdkNAExNnPaJUJRDL8Try2frbSVa7pv6nQTXD4IhhyYjH3zYQIphZ +6rBK+1YWc26sTfcioU+tHXotRSflMMFe8toTyyVCUZVHA4xsIcx0Qu1T/zOLjw9XARYvz6buyXAi +FL39vmwLAw== +-----END CERTIFICATE----- + +Sonera Class 2 Root CA +====================== +-----BEGIN CERTIFICATE----- +MIIDIDCCAgigAwIBAgIBHTANBgkqhkiG9w0BAQUFADA5MQswCQYDVQQGEwJGSTEPMA0GA1UEChMG +U29uZXJhMRkwFwYDVQQDExBTb25lcmEgQ2xhc3MyIENBMB4XDTAxMDQwNjA3Mjk0MFoXDTIxMDQw +NjA3Mjk0MFowOTELMAkGA1UEBhMCRkkxDzANBgNVBAoTBlNvbmVyYTEZMBcGA1UEAxMQU29uZXJh +IENsYXNzMiBDQTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAJAXSjWdyvANlsdE+hY3 +/Ei9vX+ALTU74W+oZ6m/AxxNjG8yR9VBaKQTBME1DJqEQ/xcHf+Js+gXGM2RX/uJ4+q/Tl18GybT +dXnt5oTjV+WtKcT0OijnpXuENmmz/V52vaMtmdOQTiMofRhj8VQ7Jp12W5dCsv+u8E7s3TmVToMG +f+dJQMjFAbJUWmYdPfz56TwKnoG4cPABi+QjVHzIrviQHgCWctRUz2EjvOr7nQKV0ba5cTppCD8P +tOFCx4j1P5iop7oc4HFx71hXgVB6XGt0Rg6DA5jDjqhu8nYybieDwnPz3BjotJPqdURrBGAgcVeH +nfO+oJAjPYok4doh28MCAwEAAaMzMDEwDwYDVR0TAQH/BAUwAwEB/zARBgNVHQ4ECgQISqCqWITT +XjwwCwYDVR0PBAQDAgEGMA0GCSqGSIb3DQEBBQUAA4IBAQBazof5FnIVV0sd2ZvnoiYw7JNn39Yt +0jSv9zilzqsWuasvfDXLrNAPtEwr/IDva4yRXzZ299uzGxnq9LIR/WFxRL8oszodv7ND6J+/3DEI +cbCdjdY0RzKQxmUk96BKfARzjzlvF4xytb1LyHr4e4PDKE6cCepnP7JnBBvDFNr450kkkdAdavph +Oe9r5yF1BgfYErQhIHBCcYHaPJo2vqZbDWpsmh+Re/n570K6Tk6ezAyNlNzZRZxe7EJQY670XcSx +EtzKO6gunRRaBXW37Ndj4ro1tgQIkejanZz2ZrUYrAqmVCY0M9IbwdR/GjqOC6oybtv8TyWf2TLH +llpwrN9M +-----END CERTIFICATE----- + +XRamp Global CA Root +==================== +-----BEGIN CERTIFICATE----- +MIIEMDCCAxigAwIBAgIQUJRs7Bjq1ZxN1ZfvdY+grTANBgkqhkiG9w0BAQUFADCBgjELMAkGA1UE +BhMCVVMxHjAcBgNVBAsTFXd3dy54cmFtcHNlY3VyaXR5LmNvbTEkMCIGA1UEChMbWFJhbXAgU2Vj +dXJpdHkgU2VydmljZXMgSW5jMS0wKwYDVQQDEyRYUmFtcCBHbG9iYWwgQ2VydGlmaWNhdGlvbiBB +dXRob3JpdHkwHhcNMDQxMTAxMTcxNDA0WhcNMzUwMTAxMDUzNzE5WjCBgjELMAkGA1UEBhMCVVMx +HjAcBgNVBAsTFXd3dy54cmFtcHNlY3VyaXR5LmNvbTEkMCIGA1UEChMbWFJhbXAgU2VjdXJpdHkg +U2VydmljZXMgSW5jMS0wKwYDVQQDEyRYUmFtcCBHbG9iYWwgQ2VydGlmaWNhdGlvbiBBdXRob3Jp +dHkwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCYJB69FbS638eMpSe2OAtp87ZOqCwu +IR1cRN8hXX4jdP5efrRKt6atH67gBhbim1vZZ3RrXYCPKZ2GG9mcDZhtdhAoWORlsH9KmHmf4MMx +foArtYzAQDsRhtDLooY2YKTVMIJt2W7QDxIEM5dfT2Fa8OT5kavnHTu86M/0ay00fOJIYRyO82FE +zG+gSqmUsE3a56k0enI4qEHMPJQRfevIpoy3hsvKMzvZPTeL+3o+hiznc9cKV6xkmxnr9A8ECIqs +AxcZZPRaJSKNNCyy9mgdEm3Tih4U2sSPpuIjhdV6Db1q4Ons7Be7QhtnqiXtRYMh/MHJfNViPvry +xS3T/dRlAgMBAAGjgZ8wgZwwEwYJKwYBBAGCNxQCBAYeBABDAEEwCwYDVR0PBAQDAgGGMA8GA1Ud +EwEB/wQFMAMBAf8wHQYDVR0OBBYEFMZPoj0GY4QJnM5i5ASsjVy16bYbMDYGA1UdHwQvMC0wK6Ap +oCeGJWh0dHA6Ly9jcmwueHJhbXBzZWN1cml0eS5jb20vWEdDQS5jcmwwEAYJKwYBBAGCNxUBBAMC +AQEwDQYJKoZIhvcNAQEFBQADggEBAJEVOQMBG2f7Shz5CmBbodpNl2L5JFMn14JkTpAuw0kbK5rc +/Kh4ZzXxHfARvbdI4xD2Dd8/0sm2qlWkSLoC295ZLhVbO50WfUfXN+pfTXYSNrsf16GBBEYgoyxt +qZ4Bfj8pzgCT3/3JknOJiWSe5yvkHJEs0rnOfc5vMZnT5r7SHpDwCRR5XCOrTdLaIR9NmXmd4c8n +nxCbHIgNsIpkQTG4DmyQJKSbXHGPurt+HBvbaoAPIbzp26a3QPSyi6mx5O+aGtA9aZnuqCij4Tyz +8LIRnM98QObd50N9otg6tamN8jSZxNQQ4Qb9CYQQO+7ETPTsJ3xCwnR8gooJybQDJbw= +-----END CERTIFICATE----- + +Go Daddy Class 2 CA +=================== +-----BEGIN CERTIFICATE----- +MIIEADCCAuigAwIBAgIBADANBgkqhkiG9w0BAQUFADBjMQswCQYDVQQGEwJVUzEhMB8GA1UEChMY +VGhlIEdvIERhZGR5IEdyb3VwLCBJbmMuMTEwLwYDVQQLEyhHbyBEYWRkeSBDbGFzcyAyIENlcnRp +ZmljYXRpb24gQXV0aG9yaXR5MB4XDTA0MDYyOTE3MDYyMFoXDTM0MDYyOTE3MDYyMFowYzELMAkG +A1UEBhMCVVMxITAfBgNVBAoTGFRoZSBHbyBEYWRkeSBHcm91cCwgSW5jLjExMC8GA1UECxMoR28g +RGFkZHkgQ2xhc3MgMiBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTCCASAwDQYJKoZIhvcNAQEBBQAD +ggENADCCAQgCggEBAN6d1+pXGEmhW+vXX0iG6r7d/+TvZxz0ZWizV3GgXne77ZtJ6XCAPVYYYwhv +2vLM0D9/AlQiVBDYsoHUwHU9S3/Hd8M+eKsaA7Ugay9qK7HFiH7Eux6wwdhFJ2+qN1j3hybX2C32 +qRe3H3I2TqYXP2WYktsqbl2i/ojgC95/5Y0V4evLOtXiEqITLdiOr18SPaAIBQi2XKVlOARFmR6j +YGB0xUGlcmIbYsUfb18aQr4CUWWoriMYavx4A6lNf4DD+qta/KFApMoZFv6yyO9ecw3ud72a9nmY +vLEHZ6IVDd2gWMZEewo+YihfukEHU1jPEX44dMX4/7VpkI+EdOqXG68CAQOjgcAwgb0wHQYDVR0O +BBYEFNLEsNKR1EwRcbNhyz2h/t2oatTjMIGNBgNVHSMEgYUwgYKAFNLEsNKR1EwRcbNhyz2h/t2o +atTjoWekZTBjMQswCQYDVQQGEwJVUzEhMB8GA1UEChMYVGhlIEdvIERhZGR5IEdyb3VwLCBJbmMu +MTEwLwYDVQQLEyhHbyBEYWRkeSBDbGFzcyAyIENlcnRpZmljYXRpb24gQXV0aG9yaXR5ggEAMAwG +A1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEFBQADggEBADJL87LKPpH8EsahB4yOd6AzBhRckB4Y9wim +PQoZ+YeAEW5p5JYXMP80kWNyOO7MHAGjHZQopDH2esRU1/blMVgDoszOYtuURXO1v0XJJLXVggKt +I3lpjbi2Tc7PTMozI+gciKqdi0FuFskg5YmezTvacPd+mSYgFFQlq25zheabIZ0KbIIOqPjCDPoQ +HmyW74cNxA9hi63ugyuV+I6ShHI56yDqg+2DzZduCLzrTia2cyvk0/ZM/iZx4mERdEr/VxqHD3VI +Ls9RaRegAhJhldXRQLIQTO7ErBBDpqWeCtWVYpoNz4iCxTIM5CufReYNnyicsbkqWletNw+vHX/b +vZ8= +-----END CERTIFICATE----- + +Starfield Class 2 CA +==================== +-----BEGIN CERTIFICATE----- +MIIEDzCCAvegAwIBAgIBADANBgkqhkiG9w0BAQUFADBoMQswCQYDVQQGEwJVUzElMCMGA1UEChMc +U3RhcmZpZWxkIFRlY2hub2xvZ2llcywgSW5jLjEyMDAGA1UECxMpU3RhcmZpZWxkIENsYXNzIDIg +Q2VydGlmaWNhdGlvbiBBdXRob3JpdHkwHhcNMDQwNjI5MTczOTE2WhcNMzQwNjI5MTczOTE2WjBo +MQswCQYDVQQGEwJVUzElMCMGA1UEChMcU3RhcmZpZWxkIFRlY2hub2xvZ2llcywgSW5jLjEyMDAG +A1UECxMpU3RhcmZpZWxkIENsYXNzIDIgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkwggEgMA0GCSqG +SIb3DQEBAQUAA4IBDQAwggEIAoIBAQC3Msj+6XGmBIWtDBFk385N78gDGIc/oav7PKaf8MOh2tTY +bitTkPskpD6E8J7oX+zlJ0T1KKY/e97gKvDIr1MvnsoFAZMej2YcOadN+lq2cwQlZut3f+dZxkqZ +JRRU6ybH838Z1TBwj6+wRir/resp7defqgSHo9T5iaU0X9tDkYI22WY8sbi5gv2cOj4QyDvvBmVm +epsZGD3/cVE8MC5fvj13c7JdBmzDI1aaK4UmkhynArPkPw2vCHmCuDY96pzTNbO8acr1zJ3o/WSN +F4Azbl5KXZnJHoe0nRrA1W4TNSNe35tfPe/W93bC6j67eA0cQmdrBNj41tpvi/JEoAGrAgEDo4HF +MIHCMB0GA1UdDgQWBBS/X7fRzt0fhvRbVazc1xDCDqmI5zCBkgYDVR0jBIGKMIGHgBS/X7fRzt0f +hvRbVazc1xDCDqmI56FspGowaDELMAkGA1UEBhMCVVMxJTAjBgNVBAoTHFN0YXJmaWVsZCBUZWNo +bm9sb2dpZXMsIEluYy4xMjAwBgNVBAsTKVN0YXJmaWVsZCBDbGFzcyAyIENlcnRpZmljYXRpb24g +QXV0aG9yaXR5ggEAMAwGA1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEFBQADggEBAAWdP4id0ckaVaGs +afPzWdqbAYcaT1epoXkJKtv3L7IezMdeatiDh6GX70k1PncGQVhiv45YuApnP+yz3SFmH8lU+nLM +PUxA2IGvd56Deruix/U0F47ZEUD0/CwqTRV/p2JdLiXTAAsgGh1o+Re49L2L7ShZ3U0WixeDyLJl +xy16paq8U4Zt3VekyvggQQto8PT7dL5WXXp59fkdheMtlb71cZBDzI0fmgAKhynpVSJYACPq4xJD +KVtHCN2MQWplBqjlIapBtJUhlbl90TSrE9atvNziPTnNvT51cKEYWQPJIrSPnNVeKtelttQKbfi3 +QBFGmh95DmK/D5fs4C8fF5Q= +-----END CERTIFICATE----- + +Taiwan GRCA +=========== +-----BEGIN CERTIFICATE----- +MIIFcjCCA1qgAwIBAgIQH51ZWtcvwgZEpYAIaeNe9jANBgkqhkiG9w0BAQUFADA/MQswCQYDVQQG +EwJUVzEwMC4GA1UECgwnR292ZXJubWVudCBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MB4X +DTAyMTIwNTEzMjMzM1oXDTMyMTIwNTEzMjMzM1owPzELMAkGA1UEBhMCVFcxMDAuBgNVBAoMJ0dv +dmVybm1lbnQgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTCCAiIwDQYJKoZIhvcNAQEBBQAD +ggIPADCCAgoCggIBAJoluOzMonWoe/fOW1mKydGGEghU7Jzy50b2iPN86aXfTEc2pBsBHH8eV4qN +w8XRIePaJD9IK/ufLqGU5ywck9G/GwGHU5nOp/UKIXZ3/6m3xnOUT0b3EEk3+qhZSV1qgQdW8or5 +BtD3cCJNtLdBuTK4sfCxw5w/cP1T3YGq2GN49thTbqGsaoQkclSGxtKyyhwOeYHWtXBiCAEuTk8O +1RGvqa/lmr/czIdtJuTJV6L7lvnM4T9TjGxMfptTCAtsF/tnyMKtsc2AtJfcdgEWFelq16TheEfO +htX7MfP6Mb40qij7cEwdScevLJ1tZqa2jWR+tSBqnTuBto9AAGdLiYa4zGX+FVPpBMHWXx1E1wov +J5pGfaENda1UhhXcSTvxls4Pm6Dso3pdvtUqdULle96ltqqvKKyskKw4t9VoNSZ63Pc78/1Fm9G7 +Q3hub/FCVGqY8A2tl+lSXunVanLeavcbYBT0peS2cWeqH+riTcFCQP5nRhc4L0c/cZyu5SHKYS1t +B6iEfC3uUSXxY5Ce/eFXiGvviiNtsea9P63RPZYLhY3Naye7twWb7LuRqQoHEgKXTiCQ8P8NHuJB +O9NAOueNXdpm5AKwB1KYXA6OM5zCppX7VRluTI6uSw+9wThNXo+EHWbNxWCWtFJaBYmOlXqYwZE8 +lSOyDvR5tMl8wUohAgMBAAGjajBoMB0GA1UdDgQWBBTMzO/MKWCkO7GStjz6MmKPrCUVOzAMBgNV +HRMEBTADAQH/MDkGBGcqBwAEMTAvMC0CAQAwCQYFKw4DAhoFADAHBgVnKgMAAAQUA5vwIhP/lSg2 +09yewDL7MTqKUWUwDQYJKoZIhvcNAQEFBQADggIBAECASvomyc5eMN1PhnR2WPWus4MzeKR6dBcZ +TulStbngCnRiqmjKeKBMmo4sIy7VahIkv9Ro04rQ2JyftB8M3jh+Vzj8jeJPXgyfqzvS/3WXy6Tj +Zwj/5cAWtUgBfen5Cv8b5Wppv3ghqMKnI6mGq3ZW6A4M9hPdKmaKZEk9GhiHkASfQlK3T8v+R0F2 +Ne//AHY2RTKbxkaFXeIksB7jSJaYV0eUVXoPQbFEJPPB/hprv4j9wabak2BegUqZIJxIZhm1AHlU +D7gsL0u8qV1bYH+Mh6XgUmMqvtg7hUAV/h62ZT/FS9p+tXo1KaMuephgIqP0fSdOLeq0dDzpD6Qz +DxARvBMB1uUO07+1EqLhRSPAzAhuYbeJq4PjJB7mXQfnHyA+z2fI56wwbSdLaG5LKlwCCDTb+Hbk +Z6MmnD+iMsJKxYEYMRBWqoTvLQr/uB930r+lWKBi5NdLkXWNiYCYfm3LU05er/ayl4WXudpVBrkk +7tfGOB5jGxI7leFYrPLfhNVfmS8NVVvmONsuP3LpSIXLuykTjx44VbnzssQwmSNOXfJIoRIM3BKQ +CZBUkQM8R+XVyWXgt0t97EfTsws+rZ7QdAAO671RrcDeLMDDav7v3Aun+kbfYNucpllQdSNpc5Oy ++fwC00fmcc4QAu4njIT/rEUNE1yDMuAlpYYsfPQS +-----END CERTIFICATE----- + +DigiCert Assured ID Root CA +=========================== +-----BEGIN CERTIFICATE----- +MIIDtzCCAp+gAwIBAgIQDOfg5RfYRv6P5WD8G/AwOTANBgkqhkiG9w0BAQUFADBlMQswCQYDVQQG +EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSQw +IgYDVQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgQ0EwHhcNMDYxMTEwMDAwMDAwWhcNMzEx +MTEwMDAwMDAwWjBlMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQL +ExB3d3cuZGlnaWNlcnQuY29tMSQwIgYDVQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgQ0Ew +ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCtDhXO5EOAXLGH87dg+XESpa7cJpSIqvTO +9SA5KFhgDPiA2qkVlTJhPLWxKISKityfCgyDF3qPkKyK53lTXDGEKvYPmDI2dsze3Tyoou9q+yHy +UmHfnyDXH+Kx2f4YZNISW1/5WBg1vEfNoTb5a3/UsDg+wRvDjDPZ2C8Y/igPs6eD1sNuRMBhNZYW +/lmci3Zt1/GiSw0r/wty2p5g0I6QNcZ4VYcgoc/lbQrISXwxmDNsIumH0DJaoroTghHtORedmTpy +oeb6pNnVFzF1roV9Iq4/AUaG9ih5yLHa5FcXxH4cDrC0kqZWs72yl+2qp/C3xag/lRbQ/6GW6whf +GHdPAgMBAAGjYzBhMA4GA1UdDwEB/wQEAwIBhjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBRF +66Kv9JLLgjEtUYunpyGd823IDzAfBgNVHSMEGDAWgBRF66Kv9JLLgjEtUYunpyGd823IDzANBgkq +hkiG9w0BAQUFAAOCAQEAog683+Lt8ONyc3pklL/3cmbYMuRCdWKuh+vy1dneVrOfzM4UKLkNl2Bc +EkxY5NM9g0lFWJc1aRqoR+pWxnmrEthngYTffwk8lOa4JiwgvT2zKIn3X/8i4peEH+ll74fg38Fn +SbNd67IJKusm7Xi+fT8r87cmNW1fiQG2SVufAQWbqz0lwcy2f8Lxb4bG+mRo64EtlOtCt/qMHt1i +8b5QZ7dsvfPxH2sMNgcWfzd8qVttevESRmCD1ycEvkvOl77DZypoEd+A5wwzZr8TDRRu838fYxAe ++o0bJW1sj6W3YQGx0qMmoRBxna3iw/nDmVG3KwcIzi7mULKn+gpFL6Lw8g== +-----END CERTIFICATE----- + +DigiCert Global Root CA +======================= +-----BEGIN CERTIFICATE----- +MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBhMQswCQYDVQQG +EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSAw +HgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBDQTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAw +MDAwMDBaMGExCzAJBgNVBAYTAlVTMRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3 +dy5kaWdpY2VydC5jb20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkq +hkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsBCSDMAZOn +TjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97nh6Vfe63SKMI2tavegw5 +BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt43C/dxC//AH2hdmoRBBYMql1GNXRor5H +4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7PT19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y +7vrTC0LUq7dBMtoM1O/4gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQAB +o2MwYTAOBgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbRTLtm +8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUwDQYJKoZIhvcNAQEF +BQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/EsrhMAtudXH/vTBH1jLuG2cenTnmCmr +EbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIt +tep3Sp+dWOIrWcBAI+0tKIJFPnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886 +UAb3LujEV0lsYSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk +CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4= +-----END CERTIFICATE----- + +DigiCert High Assurance EV Root CA +================================== +-----BEGIN CERTIFICATE----- +MIIDxTCCAq2gAwIBAgIQAqxcJmoLQJuPC3nyrkYldzANBgkqhkiG9w0BAQUFADBsMQswCQYDVQQG +EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSsw +KQYDVQQDEyJEaWdpQ2VydCBIaWdoIEFzc3VyYW5jZSBFViBSb290IENBMB4XDTA2MTExMDAwMDAw +MFoXDTMxMTExMDAwMDAwMFowbDELMAkGA1UEBhMCVVMxFTATBgNVBAoTDERpZ2lDZXJ0IEluYzEZ +MBcGA1UECxMQd3d3LmRpZ2ljZXJ0LmNvbTErMCkGA1UEAxMiRGlnaUNlcnQgSGlnaCBBc3N1cmFu +Y2UgRVYgUm9vdCBDQTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAMbM5XPm+9S75S0t +Mqbf5YE/yc0lSbZxKsPVlDRnogocsF9ppkCxxLeyj9CYpKlBWTrT3JTWPNt0OKRKzE0lgvdKpVMS +OO7zSW1xkX5jtqumX8OkhPhPYlG++MXs2ziS4wblCJEMxChBVfvLWokVfnHoNb9Ncgk9vjo4UFt3 +MRuNs8ckRZqnrG0AFFoEt7oT61EKmEFBIk5lYYeBQVCmeVyJ3hlKV9Uu5l0cUyx+mM0aBhakaHPQ +NAQTXKFx01p8VdteZOE3hzBWBOURtCmAEvF5OYiiAhF8J2a3iLd48soKqDirCmTCv2ZdlYTBoSUe +h10aUAsgEsxBu24LUTi4S8sCAwEAAaNjMGEwDgYDVR0PAQH/BAQDAgGGMA8GA1UdEwEB/wQFMAMB +Af8wHQYDVR0OBBYEFLE+w2kD+L9HAdSYJhoIAu9jZCvDMB8GA1UdIwQYMBaAFLE+w2kD+L9HAdSY +JhoIAu9jZCvDMA0GCSqGSIb3DQEBBQUAA4IBAQAcGgaX3NecnzyIZgYIVyHbIUf4KmeqvxgydkAQ +V8GK83rZEWWONfqe/EW1ntlMMUu4kehDLI6zeM7b41N5cdblIZQB2lWHmiRk9opmzN6cN82oNLFp +myPInngiK3BD41VHMWEZ71jFhS9OMPagMRYjyOfiZRYzy78aG6A9+MpeizGLYAiJLQwGXFK3xPkK +mNEVX58Svnw2Yzi9RKR/5CYrCsSXaQ3pjOLAEFe4yHYSkVXySGnYvCoCWw9E1CAx2/S6cCZdkGCe +vEsXCS+0yx5DaMkHJ8HSXPfqIbloEpw8nL+e/IBcm2PN7EeqJSdnoDfzAIJ9VNep+OkuE6N36B9K +-----END CERTIFICATE----- + +DST Root CA X3 +============== +-----BEGIN CERTIFICATE----- +MIIDSjCCAjKgAwIBAgIQRK+wgNajJ7qJMDmGLvhAazANBgkqhkiG9w0BAQUFADA/MSQwIgYDVQQK +ExtEaWdpdGFsIFNpZ25hdHVyZSBUcnVzdCBDby4xFzAVBgNVBAMTDkRTVCBSb290IENBIFgzMB4X +DTAwMDkzMDIxMTIxOVoXDTIxMDkzMDE0MDExNVowPzEkMCIGA1UEChMbRGlnaXRhbCBTaWduYXR1 +cmUgVHJ1c3QgQ28uMRcwFQYDVQQDEw5EU1QgUm9vdCBDQSBYMzCCASIwDQYJKoZIhvcNAQEBBQAD +ggEPADCCAQoCggEBAN+v6ZdQCINXtMxiZfaQguzH0yxrMMpb7NnDfcdAwRgUi+DoM3ZJKuM/IUmT +rE4Orz5Iy2Xu/NMhD2XSKtkyj4zl93ewEnu1lcCJo6m67XMuegwGMoOifooUMM0RoOEqOLl5CjH9 +UL2AZd+3UWODyOKIYepLYYHsUmu5ouJLGiifSKOeDNoJjj4XLh7dIN9bxiqKqy69cK3FCxolkHRy +xXtqqzTWMIn/5WgTe1QLyNau7Fqckh49ZLOMxt+/yUFw7BZy1SbsOFU5Q9D8/RhcQPGX69Wam40d +utolucbY38EVAjqr2m7xPi71XAicPNaDaeQQmxkqtilX4+U9m5/wAl0CAwEAAaNCMEAwDwYDVR0T +AQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFMSnsaR7LHH62+FLkHX/xBVghYkQ +MA0GCSqGSIb3DQEBBQUAA4IBAQCjGiybFwBcqR7uKGY3Or+Dxz9LwwmglSBd49lZRNI+DT69ikug +dB/OEIKcdBodfpga3csTS7MgROSR6cz8faXbauX+5v3gTt23ADq1cEmv8uXrAvHRAosZy5Q6XkjE +GB5YGV8eAlrwDPGxrancWYaLbumR9YbK+rlmM6pZW87ipxZzR8srzJmwN0jP41ZL9c8PDHIyh8bw +RLtTcm1D9SZImlJnt1ir/md2cXjbDaJWFBM5JDGFoqgCWjBH4d1QB7wCCZAA62RjYJsWvIjJEubS +fZGL+T0yjWW06XyxV3bqxbYoOb8VZRzI9neWagqNdwvYkQsEjgfbKbYK7p2CNTUQ +-----END CERTIFICATE----- + +SwissSign Gold CA - G2 +====================== +-----BEGIN CERTIFICATE----- +MIIFujCCA6KgAwIBAgIJALtAHEP1Xk+wMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNVBAYTAkNIMRUw +EwYDVQQKEwxTd2lzc1NpZ24gQUcxHzAdBgNVBAMTFlN3aXNzU2lnbiBHb2xkIENBIC0gRzIwHhcN +MDYxMDI1MDgzMDM1WhcNMzYxMDI1MDgzMDM1WjBFMQswCQYDVQQGEwJDSDEVMBMGA1UEChMMU3dp +c3NTaWduIEFHMR8wHQYDVQQDExZTd2lzc1NpZ24gR29sZCBDQSAtIEcyMIICIjANBgkqhkiG9w0B +AQEFAAOCAg8AMIICCgKCAgEAr+TufoskDhJuqVAtFkQ7kpJcyrhdhJJCEyq8ZVeCQD5XJM1QiyUq +t2/876LQwB8CJEoTlo8jE+YoWACjR8cGp4QjK7u9lit/VcyLwVcfDmJlD909Vopz2q5+bbqBHH5C +jCA12UNNhPqE21Is8w4ndwtrvxEvcnifLtg+5hg3Wipy+dpikJKVyh+c6bM8K8vzARO/Ws/BtQpg +vd21mWRTuKCWs2/iJneRjOBiEAKfNA+k1ZIzUd6+jbqEemA8atufK+ze3gE/bk3lUIbLtK/tREDF +ylqM2tIrfKjuvqblCqoOpd8FUrdVxyJdMmqXl2MT28nbeTZ7hTpKxVKJ+STnnXepgv9VHKVxaSvR +AiTysybUa9oEVeXBCsdtMDeQKuSeFDNeFhdVxVu1yzSJkvGdJo+hB9TGsnhQ2wwMC3wLjEHXuend +jIj3o02yMszYF9rNt85mndT9Xv+9lz4pded+p2JYryU0pUHHPbwNUMoDAw8IWh+Vc3hiv69yFGkO +peUDDniOJihC8AcLYiAQZzlG+qkDzAQ4embvIIO1jEpWjpEA/I5cgt6IoMPiaG59je883WX0XaxR +7ySArqpWl2/5rX3aYT+YdzylkbYcjCbaZaIJbcHiVOO5ykxMgI93e2CaHt+28kgeDrpOVG2Y4OGi +GqJ3UM/EY5LsRxmd6+ZrzsECAwEAAaOBrDCBqTAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUw +AwEB/zAdBgNVHQ4EFgQUWyV7lqRlUX64OfPAeGZe6Drn8O4wHwYDVR0jBBgwFoAUWyV7lqRlUX64 +OfPAeGZe6Drn8O4wRgYDVR0gBD8wPTA7BglghXQBWQECAQEwLjAsBggrBgEFBQcCARYgaHR0cDov +L3JlcG9zaXRvcnkuc3dpc3NzaWduLmNvbS8wDQYJKoZIhvcNAQEFBQADggIBACe645R88a7A3hfm +5djV9VSwg/S7zV4Fe0+fdWavPOhWfvxyeDgD2StiGwC5+OlgzczOUYrHUDFu4Up+GC9pWbY9ZIEr +44OE5iKHjn3g7gKZYbge9LgriBIWhMIxkziWMaa5O1M/wySTVltpkuzFwbs4AOPsF6m43Md8AYOf +Mke6UiI0HTJ6CVanfCU2qT1L2sCCbwq7EsiHSycR+R4tx5M/nttfJmtS2S6K8RTGRI0Vqbe/vd6m +Gu6uLftIdxf+u+yvGPUqUfA5hJeVbG4bwyvEdGB5JbAKJ9/fXtI5z0V9QkvfsywexcZdylU6oJxp +mo/a77KwPJ+HbBIrZXAVUjEaJM9vMSNQH4xPjyPDdEFjHFWoFN0+4FFQz/EbMFYOkrCChdiDyyJk +vC24JdVUorgG6q2SpCSgwYa1ShNqR88uC1aVVMvOmttqtKay20EIhid392qgQmwLOM7XdVAyksLf +KzAiSNDVQTglXaTpXZ/GlHXQRf0wl0OPkKsKx4ZzYEppLd6leNcG2mqeSz53OiATIgHQv2ieY2Br +NU0LbbqhPcCT4H8js1WtciVORvnSFu+wZMEBnunKoGqYDs/YYPIvSbjkQuE4NRb0yG5P94FW6Lqj +viOvrv1vA+ACOzB2+httQc8Bsem4yWb02ybzOqR08kkkW8mw0FfB+j564ZfJ +-----END CERTIFICATE----- + +SwissSign Silver CA - G2 +======================== +-----BEGIN CERTIFICATE----- +MIIFvTCCA6WgAwIBAgIITxvUL1S7L0swDQYJKoZIhvcNAQEFBQAwRzELMAkGA1UEBhMCQ0gxFTAT +BgNVBAoTDFN3aXNzU2lnbiBBRzEhMB8GA1UEAxMYU3dpc3NTaWduIFNpbHZlciBDQSAtIEcyMB4X +DTA2MTAyNTA4MzI0NloXDTM2MTAyNTA4MzI0NlowRzELMAkGA1UEBhMCQ0gxFTATBgNVBAoTDFN3 +aXNzU2lnbiBBRzEhMB8GA1UEAxMYU3dpc3NTaWduIFNpbHZlciBDQSAtIEcyMIICIjANBgkqhkiG +9w0BAQEFAAOCAg8AMIICCgKCAgEAxPGHf9N4Mfc4yfjDmUO8x/e8N+dOcbpLj6VzHVxumK4DV644 +N0MvFz0fyM5oEMF4rhkDKxD6LHmD9ui5aLlV8gREpzn5/ASLHvGiTSf5YXu6t+WiE7brYT7QbNHm ++/pe7R20nqA1W6GSy/BJkv6FCgU+5tkL4k+73JU3/JHpMjUi0R86TieFnbAVlDLaYQ1HTWBCrpJH +6INaUFjpiou5XaHc3ZlKHzZnu0jkg7Y360g6rw9njxcH6ATK72oxh9TAtvmUcXtnZLi2kUpCe2Uu +MGoM9ZDulebyzYLs2aFK7PayS+VFheZteJMELpyCbTapxDFkH4aDCyr0NQp4yVXPQbBH6TCfmb5h +qAaEuSh6XzjZG6k4sIN/c8HDO0gqgg8hm7jMqDXDhBuDsz6+pJVpATqJAHgE2cn0mRmrVn5bi4Y5 +FZGkECwJMoBgs5PAKrYYC51+jUnyEEp/+dVGLxmSo5mnJqy7jDzmDrxHB9xzUfFwZC8I+bRHHTBs +ROopN4WSaGa8gzj+ezku01DwH/teYLappvonQfGbGHLy9YR0SslnxFSuSGTfjNFusB3hB48IHpmc +celM2KX3RxIfdNFRnobzwqIjQAtz20um53MGjMGg6cFZrEb65i/4z3GcRm25xBWNOHkDRUjvxF3X +CO6HOSKGsg0PWEP3calILv3q1h8CAwEAAaOBrDCBqTAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/ +BAUwAwEB/zAdBgNVHQ4EFgQUF6DNweRBtjpbO8tFnb0cwpj6hlgwHwYDVR0jBBgwFoAUF6DNweRB +tjpbO8tFnb0cwpj6hlgwRgYDVR0gBD8wPTA7BglghXQBWQEDAQEwLjAsBggrBgEFBQcCARYgaHR0 +cDovL3JlcG9zaXRvcnkuc3dpc3NzaWduLmNvbS8wDQYJKoZIhvcNAQEFBQADggIBAHPGgeAn0i0P +4JUw4ppBf1AsX19iYamGamkYDHRJ1l2E6kFSGG9YrVBWIGrGvShpWJHckRE1qTodvBqlYJ7YH39F +kWnZfrt4csEGDyrOj4VwYaygzQu4OSlWhDJOhrs9xCrZ1x9y7v5RoSJBsXECYxqCsGKrXlcSH9/L +3XWgwF15kIwb4FDm3jH+mHtwX6WQ2K34ArZv02DdQEsixT2tOnqfGhpHkXkzuoLcMmkDlm4fS/Bx +/uNncqCxv1yL5PqZIseEuRuNI5c/7SXgz2W79WEE790eslpBIlqhn10s6FvJbakMDHiqYMZWjwFa +DGi8aRl5xB9+lwW/xekkUV7U1UtT7dkjWjYDZaPBA61BMPNGG4WQr2W11bHkFlt4dR2Xem1ZqSqP +e97Dh4kQmUlzeMg9vVE1dCrV8X5pGyq7O70luJpaPXJhkGaH7gzWTdQRdAtq/gsD/KNVV4n+Ssuu +WxcFyPKNIzFTONItaj+CuY0IavdeQXRuwxF+B6wpYJE/OMpXEA29MC/HpeZBoNquBYeaoKRlbEwJ +DIm6uNO5wJOKMPqN5ZprFQFOZ6raYlY+hAhm0sQ2fac+EPyI4NSA5QC9qvNOBqN6avlicuMJT+ub +DgEj8Z+7fNzcbBGXJbLytGMU0gYqZ4yD9c7qB9iaah7s5Aq7KkzrCWA5zspi2C5u +-----END CERTIFICATE----- + +GeoTrust Primary Certification Authority +======================================== +-----BEGIN CERTIFICATE----- +MIIDfDCCAmSgAwIBAgIQGKy1av1pthU6Y2yv2vrEoTANBgkqhkiG9w0BAQUFADBYMQswCQYDVQQG +EwJVUzEWMBQGA1UEChMNR2VvVHJ1c3QgSW5jLjExMC8GA1UEAxMoR2VvVHJ1c3QgUHJpbWFyeSBD +ZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw0wNjExMjcwMDAwMDBaFw0zNjA3MTYyMzU5NTlaMFgx +CzAJBgNVBAYTAlVTMRYwFAYDVQQKEw1HZW9UcnVzdCBJbmMuMTEwLwYDVQQDEyhHZW9UcnVzdCBQ +cmltYXJ5IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB +CgKCAQEAvrgVe//UfH1nrYNke8hCUy3f9oQIIGHWAVlqnEQRr+92/ZV+zmEwu3qDXwK9AWbK7hWN +b6EwnL2hhZ6UOvNWiAAxz9juapYC2e0DjPt1befquFUWBRaa9OBesYjAZIVcFU2Ix7e64HXprQU9 +nceJSOC7KMgD4TCTZF5SwFlwIjVXiIrxlQqD17wxcwE07e9GceBrAqg1cmuXm2bgyxx5X9gaBGge +RwLmnWDiNpcB3841kt++Z8dtd1k7j53WkBWUvEI0EME5+bEnPn7WinXFsq+W06Lem+SYvn3h6YGt +tm/81w7a4DSwDRp35+MImO9Y+pyEtzavwt+s0vQQBnBxNQIDAQABo0IwQDAPBgNVHRMBAf8EBTAD +AQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQULNVQQZcVi/CPNmFbSvtr2ZnJM5IwDQYJKoZI +hvcNAQEFBQADggEBAFpwfyzdtzRP9YZRqSa+S7iq8XEN3GHHoOo0Hnp3DwQ16CePbJC/kRYkRj5K +Ts4rFtULUh38H2eiAkUxT87z+gOneZ1TatnaYzr4gNfTmeGl4b7UVXGYNTq+k+qurUKykG/g/CFN +NWMziUnWm07Kx+dOCQD32sfvmWKZd7aVIl6KoKv0uHiYyjgZmclynnjNS6yvGaBzEi38wkG6gZHa +Floxt/m0cYASSJlyc1pZU8FjUjPtp8nSOQJw+uCxQmYpqptR7TBUIhRf2asdweSU8Pj1K/fqynhG +1riR/aYNKxoUAT6A8EKglQdebc3MS6RFjasS6LPeWuWgfOgPIh1a6Vk= +-----END CERTIFICATE----- + +thawte Primary Root CA +====================== +-----BEGIN CERTIFICATE----- +MIIEIDCCAwigAwIBAgIQNE7VVyDV7exJ9C/ON9srbTANBgkqhkiG9w0BAQUFADCBqTELMAkGA1UE +BhMCVVMxFTATBgNVBAoTDHRoYXd0ZSwgSW5jLjEoMCYGA1UECxMfQ2VydGlmaWNhdGlvbiBTZXJ2 +aWNlcyBEaXZpc2lvbjE4MDYGA1UECxMvKGMpIDIwMDYgdGhhd3RlLCBJbmMuIC0gRm9yIGF1dGhv +cml6ZWQgdXNlIG9ubHkxHzAdBgNVBAMTFnRoYXd0ZSBQcmltYXJ5IFJvb3QgQ0EwHhcNMDYxMTE3 +MDAwMDAwWhcNMzYwNzE2MjM1OTU5WjCBqTELMAkGA1UEBhMCVVMxFTATBgNVBAoTDHRoYXd0ZSwg +SW5jLjEoMCYGA1UECxMfQ2VydGlmaWNhdGlvbiBTZXJ2aWNlcyBEaXZpc2lvbjE4MDYGA1UECxMv +KGMpIDIwMDYgdGhhd3RlLCBJbmMuIC0gRm9yIGF1dGhvcml6ZWQgdXNlIG9ubHkxHzAdBgNVBAMT +FnRoYXd0ZSBQcmltYXJ5IFJvb3QgQ0EwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCs +oPD7gFnUnMekz52hWXMJEEUMDSxuaPFsW0hoSVk3/AszGcJ3f8wQLZU0HObrTQmnHNK4yZc2AreJ +1CRfBsDMRJSUjQJib+ta3RGNKJpchJAQeg29dGYvajig4tVUROsdB58Hum/u6f1OCyn1PoSgAfGc +q/gcfomk6KHYcWUNo1F77rzSImANuVud37r8UVsLr5iy6S7pBOhih94ryNdOwUxkHt3Ph1i6Sk/K +aAcdHJ1KxtUvkcx8cXIcxcBn6zL9yZJclNqFwJu/U30rCfSMnZEfl2pSy94JNqR32HuHUETVPm4p +afs5SSYeCaWAe0At6+gnhcn+Yf1+5nyXHdWdAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYD +VR0PAQH/BAQDAgEGMB0GA1UdDgQWBBR7W0XPr87Lev0xkhpqtvNG61dIUDANBgkqhkiG9w0BAQUF +AAOCAQEAeRHAS7ORtvzw6WfUDW5FvlXok9LOAz/t2iWwHVfLHjp2oEzsUHboZHIMpKnxuIvW1oeE +uzLlQRHAd9mzYJ3rG9XRbkREqaYB7FViHXe4XI5ISXycO1cRrK1zN44veFyQaEfZYGDm/Ac9IiAX +xPcW6cTYcvnIc3zfFi8VqT79aie2oetaupgf1eNNZAqdE8hhuvU5HIe6uL17In/2/qxAeeWsEG89 +jxt5dovEN7MhGITlNgDrYyCZuen+MwS7QcjBAvlEYyCegc5C09Y/LHbTY5xZ3Y+m4Q6gLkH3LpVH +z7z9M/P2C2F+fpErgUfCJzDupxBdN49cOSvkBPB7jVaMaA== +-----END CERTIFICATE----- + +VeriSign Class 3 Public Primary Certification Authority - G5 +============================================================ +-----BEGIN CERTIFICATE----- +MIIE0zCCA7ugAwIBAgIQGNrRniZ96LtKIVjNzGs7SjANBgkqhkiG9w0BAQUFADCByjELMAkGA1UE +BhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMR8wHQYDVQQLExZWZXJpU2lnbiBUcnVzdCBO +ZXR3b3JrMTowOAYDVQQLEzEoYykgMjAwNiBWZXJpU2lnbiwgSW5jLiAtIEZvciBhdXRob3JpemVk +IHVzZSBvbmx5MUUwQwYDVQQDEzxWZXJpU2lnbiBDbGFzcyAzIFB1YmxpYyBQcmltYXJ5IENlcnRp +ZmljYXRpb24gQXV0aG9yaXR5IC0gRzUwHhcNMDYxMTA4MDAwMDAwWhcNMzYwNzE2MjM1OTU5WjCB +yjELMAkGA1UEBhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMR8wHQYDVQQLExZWZXJpU2ln +biBUcnVzdCBOZXR3b3JrMTowOAYDVQQLEzEoYykgMjAwNiBWZXJpU2lnbiwgSW5jLiAtIEZvciBh +dXRob3JpemVkIHVzZSBvbmx5MUUwQwYDVQQDEzxWZXJpU2lnbiBDbGFzcyAzIFB1YmxpYyBQcmlt +YXJ5IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IC0gRzUwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAw +ggEKAoIBAQCvJAgIKXo1nmAMqudLO07cfLw8RRy7K+D+KQL5VwijZIUVJ/XxrcgxiV0i6CqqpkKz +j/i5Vbext0uz/o9+B1fs70PbZmIVYc9gDaTY3vjgw2IIPVQT60nKWVSFJuUrjxuf6/WhkcIzSdhD +Y2pSS9KP6HBRTdGJaXvHcPaz3BJ023tdS1bTlr8Vd6Gw9KIl8q8ckmcY5fQGBO+QueQA5N06tRn/ +Arr0PO7gi+s3i+z016zy9vA9r911kTMZHRxAy3QkGSGT2RT+rCpSx4/VBEnkjWNHiDxpg8v+R70r +fk/Fla4OndTRQ8Bnc+MUCH7lP59zuDMKz10/NIeWiu5T6CUVAgMBAAGjgbIwga8wDwYDVR0TAQH/ +BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwbQYIKwYBBQUHAQwEYTBfoV2gWzBZMFcwVRYJaW1hZ2Uv +Z2lmMCEwHzAHBgUrDgMCGgQUj+XTGoasjY5rw8+AatRIGCx7GS4wJRYjaHR0cDovL2xvZ28udmVy +aXNpZ24uY29tL3ZzbG9nby5naWYwHQYDVR0OBBYEFH/TZafC3ey78DAJ80M5+gKvMzEzMA0GCSqG +SIb3DQEBBQUAA4IBAQCTJEowX2LP2BqYLz3q3JktvXf2pXkiOOzEp6B4Eq1iDkVwZMXnl2YtmAl+ +X6/WzChl8gGqCBpH3vn5fJJaCGkgDdk+bW48DW7Y5gaRQBi5+MHt39tBquCWIMnNZBU4gcmU7qKE +KQsTb47bDN0lAtukixlE0kF6BWlKWE9gyn6CagsCqiUXObXbf+eEZSqVir2G3l6BFoMtEMze/aiC +Km0oHw0LxOXnGiYZ4fQRbxC1lfznQgUy286dUV4otp6F01vvpX1FQHKOtw5rDgb7MzVIcbidJ4vE +ZV8NhnacRHr2lVz2XTIIM6RUthg/aFzyQkqFOFSDX9HoLPKsEdao7WNq +-----END CERTIFICATE----- + +SecureTrust CA +============== +-----BEGIN CERTIFICATE----- +MIIDuDCCAqCgAwIBAgIQDPCOXAgWpa1Cf/DrJxhZ0DANBgkqhkiG9w0BAQUFADBIMQswCQYDVQQG +EwJVUzEgMB4GA1UEChMXU2VjdXJlVHJ1c3QgQ29ycG9yYXRpb24xFzAVBgNVBAMTDlNlY3VyZVRy +dXN0IENBMB4XDTA2MTEwNzE5MzExOFoXDTI5MTIzMTE5NDA1NVowSDELMAkGA1UEBhMCVVMxIDAe +BgNVBAoTF1NlY3VyZVRydXN0IENvcnBvcmF0aW9uMRcwFQYDVQQDEw5TZWN1cmVUcnVzdCBDQTCC +ASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAKukgeWVzfX2FI7CT8rU4niVWJxB4Q2ZQCQX +OZEzZum+4YOvYlyJ0fwkW2Gz4BERQRwdbvC4u/jep4G6pkjGnx29vo6pQT64lO0pGtSO0gMdA+9t +DWccV9cGrcrI9f4Or2YlSASWC12juhbDCE/RRvgUXPLIXgGZbf2IzIaowW8xQmxSPmjL8xk037uH +GFaAJsTQ3MBv396gwpEWoGQRS0S8Hvbn+mPeZqx2pHGj7DaUaHp3pLHnDi+BeuK1cobvomuL8A/b +01k/unK8RCSc43Oz969XL0Imnal0ugBS8kvNU3xHCzaFDmapCJcWNFfBZveA4+1wVMeT4C4oFVmH +ursCAwEAAaOBnTCBmjATBgkrBgEEAYI3FAIEBh4EAEMAQTALBgNVHQ8EBAMCAYYwDwYDVR0TAQH/ +BAUwAwEB/zAdBgNVHQ4EFgQUQjK2FvoE/f5dS3rD/fdMQB1aQ68wNAYDVR0fBC0wKzApoCegJYYj +aHR0cDovL2NybC5zZWN1cmV0cnVzdC5jb20vU1RDQS5jcmwwEAYJKwYBBAGCNxUBBAMCAQAwDQYJ +KoZIhvcNAQEFBQADggEBADDtT0rhWDpSclu1pqNlGKa7UTt36Z3q059c4EVlew3KW+JwULKUBRSu +SceNQQcSc5R+DCMh/bwQf2AQWnL1mA6s7Ll/3XpvXdMc9P+IBWlCqQVxyLesJugutIxq/3HcuLHf +mbx8IVQr5Fiiu1cprp6poxkmD5kuCLDv/WnPmRoJjeOnnyvJNjR7JLN4TJUXpAYmHrZkUjZfYGfZ +nMUFdAvnZyPSCPyI6a6Lf+Ew9Dd+/cYy2i2eRDAwbO4H3tI0/NL/QPZL9GZGBlSm8jIKYyYwa5vR +3ItHuuG51WLQoqD0ZwV4KWMabwTW+MZMo5qxN7SN5ShLHZ4swrhovO0C7jE= +-----END CERTIFICATE----- + +Secure Global CA +================ +-----BEGIN CERTIFICATE----- +MIIDvDCCAqSgAwIBAgIQB1YipOjUiolN9BPI8PjqpTANBgkqhkiG9w0BAQUFADBKMQswCQYDVQQG +EwJVUzEgMB4GA1UEChMXU2VjdXJlVHJ1c3QgQ29ycG9yYXRpb24xGTAXBgNVBAMTEFNlY3VyZSBH +bG9iYWwgQ0EwHhcNMDYxMTA3MTk0MjI4WhcNMjkxMjMxMTk1MjA2WjBKMQswCQYDVQQGEwJVUzEg +MB4GA1UEChMXU2VjdXJlVHJ1c3QgQ29ycG9yYXRpb24xGTAXBgNVBAMTEFNlY3VyZSBHbG9iYWwg +Q0EwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCvNS7YrGxVaQZx5RNoJLNP2MwhR/jx +YDiJiQPpvepeRlMJ3Fz1Wuj3RSoC6zFh1ykzTM7HfAo3fg+6MpjhHZevj8fcyTiW89sa/FHtaMbQ +bqR8JNGuQsiWUGMu4P51/pinX0kuleM5M2SOHqRfkNJnPLLZ/kG5VacJjnIFHovdRIWCQtBJwB1g +8NEXLJXr9qXBkqPFwqcIYA1gBBCWeZ4WNOaptvolRTnIHmX5k/Wq8VLcmZg9pYYaDDUz+kulBAYV +HDGA76oYa8J719rO+TMg1fW9ajMtgQT7sFzUnKPiXB3jqUJ1XnvUd+85VLrJChgbEplJL4hL/VBi +0XPnj3pDAgMBAAGjgZ0wgZowEwYJKwYBBAGCNxQCBAYeBABDAEEwCwYDVR0PBAQDAgGGMA8GA1Ud +EwEB/wQFMAMBAf8wHQYDVR0OBBYEFK9EBMJBfkiD2045AuzshHrmzsmkMDQGA1UdHwQtMCswKaAn +oCWGI2h0dHA6Ly9jcmwuc2VjdXJldHJ1c3QuY29tL1NHQ0EuY3JsMBAGCSsGAQQBgjcVAQQDAgEA +MA0GCSqGSIb3DQEBBQUAA4IBAQBjGghAfaReUw132HquHw0LURYD7xh8yOOvaliTFGCRsoTciE6+ +OYo68+aCiV0BN7OrJKQVDpI1WkpEXk5X+nXOH0jOZvQ8QCaSmGwb7iRGDBezUqXbpZGRzzfTb+cn +CDpOGR86p1hcF895P4vkp9MmI50mD1hp/Ed+stCNi5O/KU9DaXR2Z0vPB4zmAve14bRDtUstFJ/5 +3CYNv6ZHdAbYiNE6KTCEztI5gGIbqMdXSbxqVVFnFUq+NQfk1XWYN3kwFNspnWzFacxHVaIw98xc +f8LDmBxrThaA63p4ZUWiABqvDA1VZDRIuJK58bRQKfJPIx/abKwfROHdI3hRW8cW +-----END CERTIFICATE----- + +COMODO Certification Authority +============================== +-----BEGIN CERTIFICATE----- +MIIEHTCCAwWgAwIBAgIQToEtioJl4AsC7j41AkblPTANBgkqhkiG9w0BAQUFADCBgTELMAkGA1UE +BhMCR0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgG +A1UEChMRQ09NT0RPIENBIExpbWl0ZWQxJzAlBgNVBAMTHkNPTU9ETyBDZXJ0aWZpY2F0aW9uIEF1 +dGhvcml0eTAeFw0wNjEyMDEwMDAwMDBaFw0yOTEyMzEyMzU5NTlaMIGBMQswCQYDVQQGEwJHQjEb +MBkGA1UECBMSR3JlYXRlciBNYW5jaGVzdGVyMRAwDgYDVQQHEwdTYWxmb3JkMRowGAYDVQQKExFD +T01PRE8gQ0EgTGltaXRlZDEnMCUGA1UEAxMeQ09NT0RPIENlcnRpZmljYXRpb24gQXV0aG9yaXR5 +MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA0ECLi3LjkRv3UcEbVASY06m/weaKXTuH ++7uIzg3jLz8GlvCiKVCZrts7oVewdFFxze1CkU1B/qnI2GqGd0S7WWaXUF601CxwRM/aN5VCaTww +xHGzUvAhTaHYujl8HJ6jJJ3ygxaYqhZ8Q5sVW7euNJH+1GImGEaaP+vB+fGQV+useg2L23IwambV +4EajcNxo2f8ESIl33rXp+2dtQem8Ob0y2WIC8bGoPW43nOIv4tOiJovGuFVDiOEjPqXSJDlqR6sA +1KGzqSX+DT+nHbrTUcELpNqsOO9VUCQFZUaTNE8tja3G1CEZ0o7KBWFxB3NH5YoZEr0ETc5OnKVI +rLsm9wIDAQABo4GOMIGLMB0GA1UdDgQWBBQLWOWLxkwVN6RAqTCpIb5HNlpW/zAOBgNVHQ8BAf8E +BAMCAQYwDwYDVR0TAQH/BAUwAwEB/zBJBgNVHR8EQjBAMD6gPKA6hjhodHRwOi8vY3JsLmNvbW9k +b2NhLmNvbS9DT01PRE9DZXJ0aWZpY2F0aW9uQXV0aG9yaXR5LmNybDANBgkqhkiG9w0BAQUFAAOC +AQEAPpiem/Yb6dc5t3iuHXIYSdOH5EOC6z/JqvWote9VfCFSZfnVDeFs9D6Mk3ORLgLETgdxb8CP +OGEIqB6BCsAvIC9Bi5HcSEW88cbeunZrM8gALTFGTO3nnc+IlP8zwFboJIYmuNg4ON8qa90SzMc/ +RxdMosIGlgnW2/4/PEZB31jiVg88O8EckzXZOFKs7sjsLjBOlDW0JB9LeGna8gI4zJVSk/BwJVmc +IGfE7vmLV2H0knZ9P4SNVbfo5azV8fUZVqZa+5Acr5Pr5RzUZ5ddBA6+C4OmF4O5MBKgxTMVBbkN ++8cFduPYSo38NBejxiEovjBFMR7HeL5YYTisO+IBZQ== +-----END CERTIFICATE----- + +Network Solutions Certificate Authority +======================================= +-----BEGIN CERTIFICATE----- +MIID5jCCAs6gAwIBAgIQV8szb8JcFuZHFhfjkDFo4DANBgkqhkiG9w0BAQUFADBiMQswCQYDVQQG +EwJVUzEhMB8GA1UEChMYTmV0d29yayBTb2x1dGlvbnMgTC5MLkMuMTAwLgYDVQQDEydOZXR3b3Jr +IFNvbHV0aW9ucyBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkwHhcNMDYxMjAxMDAwMDAwWhcNMjkxMjMx +MjM1OTU5WjBiMQswCQYDVQQGEwJVUzEhMB8GA1UEChMYTmV0d29yayBTb2x1dGlvbnMgTC5MLkMu +MTAwLgYDVQQDEydOZXR3b3JrIFNvbHV0aW9ucyBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkwggEiMA0G +CSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDkvH6SMG3G2I4rC7xGzuAnlt7e+foS0zwzc7MEL7xx +jOWftiJgPl9dzgn/ggwbmlFQGiaJ3dVhXRncEg8tCqJDXRfQNJIg6nPPOCwGJgl6cvf6UDL4wpPT +aaIjzkGxzOTVHzbRijr4jGPiFFlp7Q3Tf2vouAPlT2rlmGNpSAW+Lv8ztumXWWn4Zxmuk2GWRBXT +crA/vGp97Eh/jcOrqnErU2lBUzS1sLnFBgrEsEX1QV1uiUV7PTsmjHTC5dLRfbIR1PtYMiKagMnc +/Qzpf14Dl847ABSHJ3A4qY5usyd2mFHgBeMhqxrVhSI8KbWaFsWAqPS7azCPL0YCorEMIuDTAgMB +AAGjgZcwgZQwHQYDVR0OBBYEFCEwyfsA106Y2oeqKtCnLrFAMadMMA4GA1UdDwEB/wQEAwIBBjAP +BgNVHRMBAf8EBTADAQH/MFIGA1UdHwRLMEkwR6BFoEOGQWh0dHA6Ly9jcmwubmV0c29sc3NsLmNv +bS9OZXR3b3JrU29sdXRpb25zQ2VydGlmaWNhdGVBdXRob3JpdHkuY3JsMA0GCSqGSIb3DQEBBQUA +A4IBAQC7rkvnt1frf6ott3NHhWrB5KUd5Oc86fRZZXe1eltajSU24HqXLjjAV2CDmAaDn7l2em5Q +4LqILPxFzBiwmZVRDuwduIj/h1AcgsLj4DKAv6ALR8jDMe+ZZzKATxcheQxpXN5eNK4CtSbqUN9/ +GGUsyfJj4akH/nxxH2szJGoeBfcFaMBqEssuXmHLrijTfsK0ZpEmXzwuJF/LWA/rKOyvEZbz3Htv +wKeI8lN3s2Berq4o2jUsbzRF0ybh3uxbTydrFny9RAQYgrOJeRcQcT16ohZO9QHNpGxlaKFJdlxD +ydi8NmdspZS11My5vWo1ViHe2MPr+8ukYEywVaCge1ey +-----END CERTIFICATE----- + +COMODO ECC Certification Authority +================================== +-----BEGIN CERTIFICATE----- +MIICiTCCAg+gAwIBAgIQH0evqmIAcFBUTAGem2OZKjAKBggqhkjOPQQDAzCBhTELMAkGA1UEBhMC +R0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgGA1UE +ChMRQ09NT0RPIENBIExpbWl0ZWQxKzApBgNVBAMTIkNPTU9ETyBFQ0MgQ2VydGlmaWNhdGlvbiBB +dXRob3JpdHkwHhcNMDgwMzA2MDAwMDAwWhcNMzgwMTE4MjM1OTU5WjCBhTELMAkGA1UEBhMCR0Ix +GzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgGA1UEChMR +Q09NT0RPIENBIExpbWl0ZWQxKzApBgNVBAMTIkNPTU9ETyBFQ0MgQ2VydGlmaWNhdGlvbiBBdXRo +b3JpdHkwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAAQDR3svdcmCFYX7deSRFtSrYpn1PlILBs5BAH+X +4QokPB0BBO490o0JlwzgdeT6+3eKKvUDYEs2ixYjFq0JcfRK9ChQtP6IHG4/bC8vCVlbpVsLM5ni +wz2J+Wos77LTBumjQjBAMB0GA1UdDgQWBBR1cacZSBm8nZ3qQUfflMRId5nTeTAOBgNVHQ8BAf8E +BAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAKBggqhkjOPQQDAwNoADBlAjEA7wNbeqy3eApyt4jf/7VG +FAkK+qDmfQjGGoe9GKhzvSbKYAydzpmfz1wPMOG+FDHqAjAU9JM8SaczepBGR7NjfRObTrdvGDeA +U/7dIOA1mjbRxwG55tzd8/8dLDoWV9mSOdY= +-----END CERTIFICATE----- + +OISTE WISeKey Global Root GA CA +=============================== +-----BEGIN CERTIFICATE----- +MIID8TCCAtmgAwIBAgIQQT1yx/RrH4FDffHSKFTfmjANBgkqhkiG9w0BAQUFADCBijELMAkGA1UE +BhMCQ0gxEDAOBgNVBAoTB1dJU2VLZXkxGzAZBgNVBAsTEkNvcHlyaWdodCAoYykgMjAwNTEiMCAG +A1UECxMZT0lTVEUgRm91bmRhdGlvbiBFbmRvcnNlZDEoMCYGA1UEAxMfT0lTVEUgV0lTZUtleSBH +bG9iYWwgUm9vdCBHQSBDQTAeFw0wNTEyMTExNjAzNDRaFw0zNzEyMTExNjA5NTFaMIGKMQswCQYD +VQQGEwJDSDEQMA4GA1UEChMHV0lTZUtleTEbMBkGA1UECxMSQ29weXJpZ2h0IChjKSAyMDA1MSIw +IAYDVQQLExlPSVNURSBGb3VuZGF0aW9uIEVuZG9yc2VkMSgwJgYDVQQDEx9PSVNURSBXSVNlS2V5 +IEdsb2JhbCBSb290IEdBIENBMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAy0+zAJs9 +Nt350UlqaxBJH+zYK7LG+DKBKUOVTJoZIyEVRd7jyBxRVVuuk+g3/ytr6dTqvirdqFEr12bDYVxg +Asj1znJ7O7jyTmUIms2kahnBAbtzptf2w93NvKSLtZlhuAGio9RN1AU9ka34tAhxZK9w8RxrfvbD +d50kc3vkDIzh2TbhmYsFmQvtRTEJysIA2/dyoJaqlYfQjse2YXMNdmaM3Bu0Y6Kff5MTMPGhJ9vZ +/yxViJGg4E8HsChWjBgbl0SOid3gF27nKu+POQoxhILYQBRJLnpB5Kf+42TMwVlxSywhp1t94B3R +LoGbw9ho972WG6xwsRYUC9tguSYBBQIDAQABo1EwTzALBgNVHQ8EBAMCAYYwDwYDVR0TAQH/BAUw +AwEB/zAdBgNVHQ4EFgQUswN+rja8sHnR3JQmthG+IbJphpQwEAYJKwYBBAGCNxUBBAMCAQAwDQYJ +KoZIhvcNAQEFBQADggEBAEuh/wuHbrP5wUOxSPMowB0uyQlB+pQAHKSkq0lPjz0e701vvbyk9vIm +MMkQyh2I+3QZH4VFvbBsUfk2ftv1TDI6QU9bR8/oCy22xBmddMVHxjtqD6wU2zz0c5ypBd8A3HR4 ++vg1YFkCExh8vPtNsCBtQ7tgMHpnM1zFmdH4LTlSc/uMqpclXHLZCB6rTjzjgTGfA6b7wP4piFXa +hNVQA7bihKOmNqoROgHhGEvWRGizPflTdISzRpFGlgC3gCy24eMQ4tui5yiPAZZiFj4A4xylNoEY +okxSdsARo27mHbrjWr42U8U+dY+GaSlYU7Wcu2+fXMUY7N0v4ZjJ/L7fCg0= +-----END CERTIFICATE----- + +Certigna +======== +-----BEGIN CERTIFICATE----- +MIIDqDCCApCgAwIBAgIJAP7c4wEPyUj/MA0GCSqGSIb3DQEBBQUAMDQxCzAJBgNVBAYTAkZSMRIw +EAYDVQQKDAlEaGlteW90aXMxETAPBgNVBAMMCENlcnRpZ25hMB4XDTA3MDYyOTE1MTMwNVoXDTI3 +MDYyOTE1MTMwNVowNDELMAkGA1UEBhMCRlIxEjAQBgNVBAoMCURoaW15b3RpczERMA8GA1UEAwwI +Q2VydGlnbmEwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDIaPHJ1tazNHUmgh7stL7q +XOEm7RFHYeGifBZ4QCHkYJ5ayGPhxLGWkv8YbWkj4Sti993iNi+RB7lIzw7sebYs5zRLcAglozyH +GxnygQcPOJAZ0xH+hrTy0V4eHpbNgGzOOzGTtvKg0KmVEn2lmsxryIRWijOp5yIVUxbwzBfsV1/p +ogqYCd7jX5xv3EjjhQsVWqa6n6xI4wmy9/Qy3l40vhx4XUJbzg4ij02Q130yGLMLLGq/jj8UEYkg +DncUtT2UCIf3JR7VsmAA7G8qKCVuKj4YYxclPz5EIBb2JsglrgVKtOdjLPOMFlN+XPsRGgjBRmKf +Irjxwo1p3Po6WAbfAgMBAAGjgbwwgbkwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUGu3+QTmQ +tCRZvgHyUtVF9lo53BEwZAYDVR0jBF0wW4AUGu3+QTmQtCRZvgHyUtVF9lo53BGhOKQ2MDQxCzAJ +BgNVBAYTAkZSMRIwEAYDVQQKDAlEaGlteW90aXMxETAPBgNVBAMMCENlcnRpZ25hggkA/tzjAQ/J +SP8wDgYDVR0PAQH/BAQDAgEGMBEGCWCGSAGG+EIBAQQEAwIABzANBgkqhkiG9w0BAQUFAAOCAQEA +hQMeknH2Qq/ho2Ge6/PAD/Kl1NqV5ta+aDY9fm4fTIrv0Q8hbV6lUmPOEvjvKtpv6zf+EwLHyzs+ +ImvaYS5/1HI93TDhHkxAGYwP15zRgzB7mFncfca5DClMoTOi62c6ZYTTluLtdkVwj7Ur3vkj1klu +PBS1xp81HlDQwY9qcEQCYsuuHWhBp6pX6FOqB9IG9tUUBguRA3UsbHK1YZWaDYu5Def131TN3ubY +1gkIl2PlwS6wt0QmwCbAr1UwnjvVNioZBPRcHv/PLLf/0P2HQBHVESO7SMAhqaQoLf0V+LBOK/Qw +WyH8EZE0vkHve52Xdf+XlcCWWC/qu0bXu+TZLg== +-----END CERTIFICATE----- + +Cybertrust Global Root +====================== +-----BEGIN CERTIFICATE----- +MIIDoTCCAomgAwIBAgILBAAAAAABD4WqLUgwDQYJKoZIhvcNAQEFBQAwOzEYMBYGA1UEChMPQ3li +ZXJ0cnVzdCwgSW5jMR8wHQYDVQQDExZDeWJlcnRydXN0IEdsb2JhbCBSb290MB4XDTA2MTIxNTA4 +MDAwMFoXDTIxMTIxNTA4MDAwMFowOzEYMBYGA1UEChMPQ3liZXJ0cnVzdCwgSW5jMR8wHQYDVQQD +ExZDeWJlcnRydXN0IEdsb2JhbCBSb290MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA ++Mi8vRRQZhP/8NN57CPytxrHjoXxEnOmGaoQ25yiZXRadz5RfVb23CO21O1fWLE3TdVJDm71aofW +0ozSJ8bi/zafmGWgE07GKmSb1ZASzxQG9Dvj1Ci+6A74q05IlG2OlTEQXO2iLb3VOm2yHLtgwEZL +AfVJrn5GitB0jaEMAs7u/OePuGtm839EAL9mJRQr3RAwHQeWP032a7iPt3sMpTjr3kfb1V05/Iin +89cqdPHoWqI7n1C6poxFNcJQZZXcY4Lv3b93TZxiyWNzFtApD0mpSPCzqrdsxacwOUBdrsTiXSZT +8M4cIwhhqJQZugRiQOwfOHB3EgZxpzAYXSUnpQIDAQABo4GlMIGiMA4GA1UdDwEB/wQEAwIBBjAP +BgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBS2CHsNesysIEyGVjJez6tuhS1wVzA/BgNVHR8EODA2 +MDSgMqAwhi5odHRwOi8vd3d3Mi5wdWJsaWMtdHJ1c3QuY29tL2NybC9jdC9jdHJvb3QuY3JsMB8G +A1UdIwQYMBaAFLYIew16zKwgTIZWMl7Pq26FLXBXMA0GCSqGSIb3DQEBBQUAA4IBAQBW7wojoFRO +lZfJ+InaRcHUowAl9B8Tq7ejhVhpwjCt2BWKLePJzYFa+HMjWqd8BfP9IjsO0QbE2zZMcwSO5bAi +5MXzLqXZI+O4Tkogp24CJJ8iYGd7ix1yCcUxXOl5n4BHPa2hCwcUPUf/A2kaDAtE52Mlp3+yybh2 +hO0j9n0Hq0V+09+zv+mKts2oomcrUtW3ZfA5TGOgkXmTUg9U3YO7n9GPp1Nzw8v/MOx8BLjYRB+T +X3EJIrduPuocA06dGiBh+4E37F78CkWr1+cXVdCg6mCbpvbjjFspwgZgFJ0tl0ypkxWdYcQBX0jW +WL1WMRJOEcgh4LMRkWXbtKaIOM5V +-----END CERTIFICATE----- + +ePKI Root Certification Authority +================================= +-----BEGIN CERTIFICATE----- +MIIFsDCCA5igAwIBAgIQFci9ZUdcr7iXAF7kBtK8nTANBgkqhkiG9w0BAQUFADBeMQswCQYDVQQG +EwJUVzEjMCEGA1UECgwaQ2h1bmdod2EgVGVsZWNvbSBDby4sIEx0ZC4xKjAoBgNVBAsMIWVQS0kg +Um9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTAeFw0wNDEyMjAwMjMxMjdaFw0zNDEyMjAwMjMx +MjdaMF4xCzAJBgNVBAYTAlRXMSMwIQYDVQQKDBpDaHVuZ2h3YSBUZWxlY29tIENvLiwgTHRkLjEq +MCgGA1UECwwhZVBLSSBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5MIICIjANBgkqhkiG9w0B +AQEFAAOCAg8AMIICCgKCAgEA4SUP7o3biDN1Z82tH306Tm2d0y8U82N0ywEhajfqhFAHSyZbCUNs +IZ5qyNUD9WBpj8zwIuQf5/dqIjG3LBXy4P4AakP/h2XGtRrBp0xtInAhijHyl3SJCRImHJ7K2RKi +lTza6We/CKBk49ZCt0Xvl/T29de1ShUCWH2YWEtgvM3XDZoTM1PRYfl61dd4s5oz9wCGzh1NlDiv +qOx4UXCKXBCDUSH3ET00hl7lSM2XgYI1TBnsZfZrxQWh7kcT1rMhJ5QQCtkkO7q+RBNGMD+XPNjX +12ruOzjjK9SXDrkb5wdJfzcq+Xd4z1TtW0ado4AOkUPB1ltfFLqfpo0kR0BZv3I4sjZsN/+Z0V0O +WQqraffAsgRFelQArr5T9rXn4fg8ozHSqf4hUmTFpmfwdQcGlBSBVcYn5AGPF8Fqcde+S/uUWH1+ +ETOxQvdibBjWzwloPn9s9h6PYq2lY9sJpx8iQkEeb5mKPtf5P0B6ebClAZLSnT0IFaUQAS2zMnao +lQ2zepr7BxB4EW/hj8e6DyUadCrlHJhBmd8hh+iVBmoKs2pHdmX2Os+PYhcZewoozRrSgx4hxyy/ +vv9haLdnG7t4TY3OZ+XkwY63I2binZB1NJipNiuKmpS5nezMirH4JYlcWrYvjB9teSSnUmjDhDXi +Zo1jDiVN1Rmy5nk3pyKdVDECAwEAAaNqMGgwHQYDVR0OBBYEFB4M97Zn8uGSJglFwFU5Lnc/Qkqi +MAwGA1UdEwQFMAMBAf8wOQYEZyoHAAQxMC8wLQIBADAJBgUrDgMCGgUAMAcGBWcqAwAABBRFsMLH +ClZ87lt4DJX5GFPBphzYEDANBgkqhkiG9w0BAQUFAAOCAgEACbODU1kBPpVJufGBuvl2ICO1J2B0 +1GqZNF5sAFPZn/KmsSQHRGoqxqWOeBLoR9lYGxMqXnmbnwoqZ6YlPwZpVnPDimZI+ymBV3QGypzq +KOg4ZyYr8dW1P2WT+DZdjo2NQCCHGervJ8A9tDkPJXtoUHRVnAxZfVo9QZQlUgjgRywVMRnVvwdV +xrsStZf0X4OFunHB2WyBEXYKCrC/gpf36j36+uwtqSiUO1bd0lEursC9CBWMd1I0ltabrNMdjmEP +NXubrjlpC2JgQCA2j6/7Nu4tCEoduL+bXPjqpRugc6bY+G7gMwRfaKonh+3ZwZCc7b3jajWvY9+r +GNm65ulK6lCKD2GTHuItGeIwlDWSXQ62B68ZgI9HkFFLLk3dheLSClIKF5r8GrBQAuUBo2M3IUxE +xJtRmREOc5wGj1QupyheRDmHVi03vYVElOEMSyycw5KFNGHLD7ibSkNS/jQ6fbjpKdx2qcgw+BRx +gMYeNkh0IkFch4LoGHGLQYlE535YW6i4jRPpp2zDR+2zGp1iro2C6pSe3VkQw63d4k3jMdXH7Ojy +sP6SHhYKGvzZ8/gntsm+HbRsZJB/9OTEW9c3rkIO3aQab3yIVMUWbuF6aC74Or8NpDyJO3inTmOD +BCEIZ43ygknQW/2xzQ+DhNQ+IIX3Sj0rnP0qCglN6oH4EZw= +-----END CERTIFICATE----- + +certSIGN ROOT CA +================ +-----BEGIN CERTIFICATE----- +MIIDODCCAiCgAwIBAgIGIAYFFnACMA0GCSqGSIb3DQEBBQUAMDsxCzAJBgNVBAYTAlJPMREwDwYD +VQQKEwhjZXJ0U0lHTjEZMBcGA1UECxMQY2VydFNJR04gUk9PVCBDQTAeFw0wNjA3MDQxNzIwMDRa +Fw0zMTA3MDQxNzIwMDRaMDsxCzAJBgNVBAYTAlJPMREwDwYDVQQKEwhjZXJ0U0lHTjEZMBcGA1UE +CxMQY2VydFNJR04gUk9PVCBDQTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBALczuX7I +JUqOtdu0KBuqV5Do0SLTZLrTk+jUrIZhQGpgV2hUhE28alQCBf/fm5oqrl0Hj0rDKH/v+yv6efHH +rfAQUySQi2bJqIirr1qjAOm+ukbuW3N7LBeCgV5iLKECZbO9xSsAfsT8AzNXDe3i+s5dRdY4zTW2 +ssHQnIFKquSyAVwdj1+ZxLGt24gh65AIgoDzMKND5pCCrlUoSe1b16kQOA7+j0xbm0bqQfWwCHTD +0IgztnzXdN/chNFDDnU5oSVAKOp4yw4sLjmdjItuFhwvJoIQ4uNllAoEwF73XVv4EOLQunpL+943 +AAAaWyjj0pxzPjKHmKHJUS/X3qwzs08CAwEAAaNCMEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8B +Af8EBAMCAcYwHQYDVR0OBBYEFOCMm9slSbPxfIbWskKHC9BroNnkMA0GCSqGSIb3DQEBBQUAA4IB +AQA+0hyJLjX8+HXd5n9liPRyTMks1zJO890ZeUe9jjtbkw9QSSQTaxQGcu8J06Gh40CEyecYMnQ8 +SG4Pn0vU9x7Tk4ZkVJdjclDVVc/6IJMCopvDI5NOFlV2oHB5bc0hH88vLbwZ44gx+FkagQnIl6Z0 +x2DEW8xXjrJ1/RsCCdtZb3KTafcxQdaIOL+Hsr0Wefmq5L6IJd1hJyMctTEHBDa0GpC9oHRxUIlt +vBTjD4au8as+x6AJzKNI0eDbZOeStc+vckNwi/nDhDwTqn6Sm1dTk/pwwpEOMfmbZ13pljheX7Nz +TogVZ96edhBiIL5VaZVDADlN9u6wWk5JRFRYX0KD +-----END CERTIFICATE----- + +GeoTrust Primary Certification Authority - G3 +============================================= +-----BEGIN CERTIFICATE----- +MIID/jCCAuagAwIBAgIQFaxulBmyeUtB9iepwxgPHzANBgkqhkiG9w0BAQsFADCBmDELMAkGA1UE +BhMCVVMxFjAUBgNVBAoTDUdlb1RydXN0IEluYy4xOTA3BgNVBAsTMChjKSAyMDA4IEdlb1RydXN0 +IEluYy4gLSBGb3IgYXV0aG9yaXplZCB1c2Ugb25seTE2MDQGA1UEAxMtR2VvVHJ1c3QgUHJpbWFy +eSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSAtIEczMB4XDTA4MDQwMjAwMDAwMFoXDTM3MTIwMTIz +NTk1OVowgZgxCzAJBgNVBAYTAlVTMRYwFAYDVQQKEw1HZW9UcnVzdCBJbmMuMTkwNwYDVQQLEzAo +YykgMjAwOCBHZW9UcnVzdCBJbmMuIC0gRm9yIGF1dGhvcml6ZWQgdXNlIG9ubHkxNjA0BgNVBAMT +LUdlb1RydXN0IFByaW1hcnkgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgLSBHMzCCASIwDQYJKoZI +hvcNAQEBBQADggEPADCCAQoCggEBANziXmJYHTNXOTIz+uvLh4yn1ErdBojqZI4xmKU4kB6Yzy5j +K/BGvESyiaHAKAxJcCGVn2TAppMSAmUmhsalifD614SgcK9PGpc/BkTVyetyEH3kMSj7HGHmKAdE +c5IiaacDiGydY8hS2pgn5whMcD60yRLBxWeDXTPzAxHsatBT4tG6NmCUgLthY2xbF37fQJQeqw3C +IShwiP/WJmxsYAQlTlV+fe+/lEjetx3dcI0FX4ilm/LC7urRQEFtYjgdVgbFA0dRIBn8exALDmKu +dlW/X3e+PkkBUz2YJQN2JFodtNuJ6nnltrM7P7pMKEF/BqxqjsHQ9gUdfeZChuOl1UcCAwEAAaNC +MEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFMR5yo6hTgMdHNxr +2zFblD4/MH8tMA0GCSqGSIb3DQEBCwUAA4IBAQAtxRPPVoB7eni9n64smefv2t+UXglpp+duaIy9 +cr5HqQ6XErhK8WTTOd8lNNTBzU6B8A8ExCSzNJbGpqow32hhc9f5joWJ7w5elShKKiePEI4ufIbE +Ap7aDHdlDkQNkv39sxY2+hENHYwOB4lqKVb3cvTdFZx3NWZXqxNT2I7BQMXXExZacse3aQHEerGD +AWh9jUGhlBjBJVz88P6DAod8DQ3PLghcSkANPuyBYeYk28rgDi0Hsj5W3I31QYUHSJsMC8tJP33s +t/3LjWeJGqvtux6jAAgIFyqCXDFdRootD4abdNlF+9RAsXqqaC2Gspki4cErx5z481+oghLrGREt +-----END CERTIFICATE----- + +thawte Primary Root CA - G2 +=========================== +-----BEGIN CERTIFICATE----- +MIICiDCCAg2gAwIBAgIQNfwmXNmET8k9Jj1Xm67XVjAKBggqhkjOPQQDAzCBhDELMAkGA1UEBhMC +VVMxFTATBgNVBAoTDHRoYXd0ZSwgSW5jLjE4MDYGA1UECxMvKGMpIDIwMDcgdGhhd3RlLCBJbmMu +IC0gRm9yIGF1dGhvcml6ZWQgdXNlIG9ubHkxJDAiBgNVBAMTG3RoYXd0ZSBQcmltYXJ5IFJvb3Qg +Q0EgLSBHMjAeFw0wNzExMDUwMDAwMDBaFw0zODAxMTgyMzU5NTlaMIGEMQswCQYDVQQGEwJVUzEV +MBMGA1UEChMMdGhhd3RlLCBJbmMuMTgwNgYDVQQLEy8oYykgMjAwNyB0aGF3dGUsIEluYy4gLSBG +b3IgYXV0aG9yaXplZCB1c2Ugb25seTEkMCIGA1UEAxMbdGhhd3RlIFByaW1hcnkgUm9vdCBDQSAt +IEcyMHYwEAYHKoZIzj0CAQYFK4EEACIDYgAEotWcgnuVnfFSeIf+iha/BebfowJPDQfGAFG6DAJS +LSKkQjnE/o/qycG+1E3/n3qe4rF8mq2nhglzh9HnmuN6papu+7qzcMBniKI11KOasf2twu8x+qi5 +8/sIxpHR+ymVo0IwQDAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQU +mtgAMADna3+FGO6Lts6KDPgR4bswCgYIKoZIzj0EAwMDaQAwZgIxAN344FdHW6fmCsO99YCKlzUN +G4k8VIZ3KMqh9HneteY4sPBlcIx/AlTCv//YoT7ZzwIxAMSNlPzcU9LcnXgWHxUzI1NS41oxXZ3K +rr0TKUQNJ1uo52icEvdYPy5yAlejj6EULg== +-----END CERTIFICATE----- + +thawte Primary Root CA - G3 +=========================== +-----BEGIN CERTIFICATE----- +MIIEKjCCAxKgAwIBAgIQYAGXt0an6rS0mtZLL/eQ+zANBgkqhkiG9w0BAQsFADCBrjELMAkGA1UE +BhMCVVMxFTATBgNVBAoTDHRoYXd0ZSwgSW5jLjEoMCYGA1UECxMfQ2VydGlmaWNhdGlvbiBTZXJ2 +aWNlcyBEaXZpc2lvbjE4MDYGA1UECxMvKGMpIDIwMDggdGhhd3RlLCBJbmMuIC0gRm9yIGF1dGhv +cml6ZWQgdXNlIG9ubHkxJDAiBgNVBAMTG3RoYXd0ZSBQcmltYXJ5IFJvb3QgQ0EgLSBHMzAeFw0w +ODA0MDIwMDAwMDBaFw0zNzEyMDEyMzU5NTlaMIGuMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMdGhh +d3RlLCBJbmMuMSgwJgYDVQQLEx9DZXJ0aWZpY2F0aW9uIFNlcnZpY2VzIERpdmlzaW9uMTgwNgYD +VQQLEy8oYykgMjAwOCB0aGF3dGUsIEluYy4gLSBGb3IgYXV0aG9yaXplZCB1c2Ugb25seTEkMCIG +A1UEAxMbdGhhd3RlIFByaW1hcnkgUm9vdCBDQSAtIEczMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8A +MIIBCgKCAQEAsr8nLPvb2FvdeHsbnndmgcs+vHyu86YnmjSjaDFxODNi5PNxZnmxqWWjpYvVj2At +P0LMqmsywCPLLEHd5N/8YZzic7IilRFDGF/Eth9XbAoFWCLINkw6fKXRz4aviKdEAhN0cXMKQlkC ++BsUa0Lfb1+6a4KinVvnSr0eAXLbS3ToO39/fR8EtCab4LRarEc9VbjXsCZSKAExQGbY2SS99irY +7CFJXJv2eul/VTV+lmuNk5Mny5K76qxAwJ/C+IDPXfRa3M50hqY+bAtTyr2SzhkGcuYMXDhpxwTW +vGzOW/b3aJzcJRVIiKHpqfiYnODz1TEoYRFsZ5aNOZnLwkUkOQIDAQABo0IwQDAPBgNVHRMBAf8E +BTADAQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUrWyqlGCc7eT/+j4KdCtjA/e2Wb8wDQYJ +KoZIhvcNAQELBQADggEBABpA2JVlrAmSicY59BDlqQ5mU1143vokkbvnRFHfxhY0Cu9qRFHqKweK +A3rD6z8KLFIWoCtDuSWQP3CpMyVtRRooOyfPqsMpQhvfO0zAMzRbQYi/aytlryjvsvXDqmbOe1bu +t8jLZ8HJnBoYuMTDSQPxYA5QzUbF83d597YV4Djbxy8ooAw/dyZ02SUS2jHaGh7cKUGRIjxpp7sC +8rZcJwOJ9Abqm+RyguOhCcHpABnTPtRwa7pxpqpYrvS76Wy274fMm7v/OeZWYdMKp8RcTGB7BXcm +er/YB1IsYvdwY9k5vG8cwnncdimvzsUsZAReiDZuMdRAGmI0Nj81Aa6sY6A= +-----END CERTIFICATE----- + +GeoTrust Primary Certification Authority - G2 +============================================= +-----BEGIN CERTIFICATE----- +MIICrjCCAjWgAwIBAgIQPLL0SAoA4v7rJDteYD7DazAKBggqhkjOPQQDAzCBmDELMAkGA1UEBhMC +VVMxFjAUBgNVBAoTDUdlb1RydXN0IEluYy4xOTA3BgNVBAsTMChjKSAyMDA3IEdlb1RydXN0IElu +Yy4gLSBGb3IgYXV0aG9yaXplZCB1c2Ugb25seTE2MDQGA1UEAxMtR2VvVHJ1c3QgUHJpbWFyeSBD +ZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSAtIEcyMB4XDTA3MTEwNTAwMDAwMFoXDTM4MDExODIzNTk1 +OVowgZgxCzAJBgNVBAYTAlVTMRYwFAYDVQQKEw1HZW9UcnVzdCBJbmMuMTkwNwYDVQQLEzAoYykg +MjAwNyBHZW9UcnVzdCBJbmMuIC0gRm9yIGF1dGhvcml6ZWQgdXNlIG9ubHkxNjA0BgNVBAMTLUdl +b1RydXN0IFByaW1hcnkgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgLSBHMjB2MBAGByqGSM49AgEG +BSuBBAAiA2IABBWx6P0DFUPlrOuHNxFi79KDNlJ9RVcLSo17VDs6bl8VAsBQps8lL33KSLjHUGMc +KiEIfJo22Av+0SbFWDEwKCXzXV2juLaltJLtbCyf691DiaI8S0iRHVDsJt/WYC69IaNCMEAwDwYD +VR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFBVfNVdRVfslsq0DafwBo/q+ +EVXVMAoGCCqGSM49BAMDA2cAMGQCMGSWWaboCd6LuvpaiIjwH5HTRqjySkwCY/tsXzjbLkGTqQ7m +ndwxHLKgpxgceeHHNgIwOlavmnRs9vuD4DPTCF+hnMJbn0bWtsuRBmOiBuczrD6ogRLQy7rQkgu2 +npaqBA+K +-----END CERTIFICATE----- + +VeriSign Universal Root Certification Authority +=============================================== +-----BEGIN CERTIFICATE----- +MIIEuTCCA6GgAwIBAgIQQBrEZCGzEyEDDrvkEhrFHTANBgkqhkiG9w0BAQsFADCBvTELMAkGA1UE +BhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMR8wHQYDVQQLExZWZXJpU2lnbiBUcnVzdCBO +ZXR3b3JrMTowOAYDVQQLEzEoYykgMjAwOCBWZXJpU2lnbiwgSW5jLiAtIEZvciBhdXRob3JpemVk +IHVzZSBvbmx5MTgwNgYDVQQDEy9WZXJpU2lnbiBVbml2ZXJzYWwgUm9vdCBDZXJ0aWZpY2F0aW9u +IEF1dGhvcml0eTAeFw0wODA0MDIwMDAwMDBaFw0zNzEyMDEyMzU5NTlaMIG9MQswCQYDVQQGEwJV +UzEXMBUGA1UEChMOVmVyaVNpZ24sIEluYy4xHzAdBgNVBAsTFlZlcmlTaWduIFRydXN0IE5ldHdv +cmsxOjA4BgNVBAsTMShjKSAyMDA4IFZlcmlTaWduLCBJbmMuIC0gRm9yIGF1dGhvcml6ZWQgdXNl +IG9ubHkxODA2BgNVBAMTL1ZlcmlTaWduIFVuaXZlcnNhbCBSb290IENlcnRpZmljYXRpb24gQXV0 +aG9yaXR5MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAx2E3XrEBNNti1xWb/1hajCMj +1mCOkdeQmIN65lgZOIzF9uVkhbSicfvtvbnazU0AtMgtc6XHaXGVHzk8skQHnOgO+k1KxCHfKWGP +MiJhgsWHH26MfF8WIFFE0XBPV+rjHOPMee5Y2A7Cs0WTwCznmhcrewA3ekEzeOEz4vMQGn+HLL72 +9fdC4uW/h2KJXwBL38Xd5HVEMkE6HnFuacsLdUYI0crSK5XQz/u5QGtkjFdN/BMReYTtXlT2NJ8I +AfMQJQYXStrxHXpma5hgZqTZ79IugvHw7wnqRMkVauIDbjPTrJ9VAMf2CGqUuV/c4DPxhGD5WycR +tPwW8rtWaoAljQIDAQABo4GyMIGvMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMG0G +CCsGAQUFBwEMBGEwX6FdoFswWTBXMFUWCWltYWdlL2dpZjAhMB8wBwYFKw4DAhoEFI/l0xqGrI2O +a8PPgGrUSBgsexkuMCUWI2h0dHA6Ly9sb2dvLnZlcmlzaWduLmNvbS92c2xvZ28uZ2lmMB0GA1Ud +DgQWBBS2d/ppSEefUxLVwuoHMnYH0ZcHGTANBgkqhkiG9w0BAQsFAAOCAQEASvj4sAPmLGd75JR3 +Y8xuTPl9Dg3cyLk1uXBPY/ok+myDjEedO2Pzmvl2MpWRsXe8rJq+seQxIcaBlVZaDrHC1LGmWazx +Y8u4TB1ZkErvkBYoH1quEPuBUDgMbMzxPcP1Y+Oz4yHJJDnp/RVmRvQbEdBNc6N9Rvk97ahfYtTx +P/jgdFcrGJ2BtMQo2pSXpXDrrB2+BxHw1dvd5Yzw1TKwg+ZX4o+/vqGqvz0dtdQ46tewXDpPaj+P +wGZsY6rp2aQW9IHRlRQOfc2VNNnSj3BzgXucfr2YYdhFh5iQxeuGMMY1v/D/w1WIg0vvBZIGcfK4 +mJO37M2CYfE45k+XmCpajQ== +-----END CERTIFICATE----- + +VeriSign Class 3 Public Primary Certification Authority - G4 +============================================================ +-----BEGIN CERTIFICATE----- +MIIDhDCCAwqgAwIBAgIQL4D+I4wOIg9IZxIokYesszAKBggqhkjOPQQDAzCByjELMAkGA1UEBhMC +VVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMR8wHQYDVQQLExZWZXJpU2lnbiBUcnVzdCBOZXR3 +b3JrMTowOAYDVQQLEzEoYykgMjAwNyBWZXJpU2lnbiwgSW5jLiAtIEZvciBhdXRob3JpemVkIHVz +ZSBvbmx5MUUwQwYDVQQDEzxWZXJpU2lnbiBDbGFzcyAzIFB1YmxpYyBQcmltYXJ5IENlcnRpZmlj +YXRpb24gQXV0aG9yaXR5IC0gRzQwHhcNMDcxMTA1MDAwMDAwWhcNMzgwMTE4MjM1OTU5WjCByjEL +MAkGA1UEBhMCVVMxFzAVBgNVBAoTDlZlcmlTaWduLCBJbmMuMR8wHQYDVQQLExZWZXJpU2lnbiBU +cnVzdCBOZXR3b3JrMTowOAYDVQQLEzEoYykgMjAwNyBWZXJpU2lnbiwgSW5jLiAtIEZvciBhdXRo +b3JpemVkIHVzZSBvbmx5MUUwQwYDVQQDEzxWZXJpU2lnbiBDbGFzcyAzIFB1YmxpYyBQcmltYXJ5 +IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IC0gRzQwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAASnVnp8 +Utpkmw4tXNherJI9/gHmGUo9FANL+mAnINmDiWn6VMaaGF5VKmTeBvaNSjutEDxlPZCIBIngMGGz +rl0Bp3vefLK+ymVhAIau2o970ImtTR1ZmkGxvEeA3J5iw/mjgbIwga8wDwYDVR0TAQH/BAUwAwEB +/zAOBgNVHQ8BAf8EBAMCAQYwbQYIKwYBBQUHAQwEYTBfoV2gWzBZMFcwVRYJaW1hZ2UvZ2lmMCEw +HzAHBgUrDgMCGgQUj+XTGoasjY5rw8+AatRIGCx7GS4wJRYjaHR0cDovL2xvZ28udmVyaXNpZ24u +Y29tL3ZzbG9nby5naWYwHQYDVR0OBBYEFLMWkf3upm7ktS5Jj4d4gYDs5bG1MAoGCCqGSM49BAMD +A2gAMGUCMGYhDBgmYFo4e1ZC4Kf8NoRRkSAsdk1DPcQdhCPQrNZ8NQbOzWm9kA3bbEhCHQ6qQgIx +AJw9SDkjOVgaFRJZap7v1VmyHVIsmXHNxynfGyphe3HR3vPA5Q06Sqotp9iGKt0uEA== +-----END CERTIFICATE----- + +NetLock Arany (Class Gold) Főtanúsítvány +======================================== +-----BEGIN CERTIFICATE----- +MIIEFTCCAv2gAwIBAgIGSUEs5AAQMA0GCSqGSIb3DQEBCwUAMIGnMQswCQYDVQQGEwJIVTERMA8G +A1UEBwwIQnVkYXBlc3QxFTATBgNVBAoMDE5ldExvY2sgS2Z0LjE3MDUGA1UECwwuVGFuw7pzw610 +dsOhbnlraWFkw7NrIChDZXJ0aWZpY2F0aW9uIFNlcnZpY2VzKTE1MDMGA1UEAwwsTmV0TG9jayBB +cmFueSAoQ2xhc3MgR29sZCkgRsWRdGFuw7pzw610dsOhbnkwHhcNMDgxMjExMTUwODIxWhcNMjgx +MjA2MTUwODIxWjCBpzELMAkGA1UEBhMCSFUxETAPBgNVBAcMCEJ1ZGFwZXN0MRUwEwYDVQQKDAxO +ZXRMb2NrIEtmdC4xNzA1BgNVBAsMLlRhbsO6c8OtdHbDoW55a2lhZMOzayAoQ2VydGlmaWNhdGlv +biBTZXJ2aWNlcykxNTAzBgNVBAMMLE5ldExvY2sgQXJhbnkgKENsYXNzIEdvbGQpIEbFkXRhbsO6 +c8OtdHbDoW55MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAxCRec75LbRTDofTjl5Bu +0jBFHjzuZ9lk4BqKf8owyoPjIMHj9DrTlF8afFttvzBPhCf2nx9JvMaZCpDyD/V/Q4Q3Y1GLeqVw +/HpYzY6b7cNGbIRwXdrzAZAj/E4wqX7hJ2Pn7WQ8oLjJM2P+FpD/sLj916jAwJRDC7bVWaaeVtAk +H3B5r9s5VA1lddkVQZQBr17s9o3x/61k/iCa11zr/qYfCGSji3ZVrR47KGAuhyXoqq8fxmRGILdw +fzzeSNuWU7c5d+Qa4scWhHaXWy+7GRWF+GmF9ZmnqfI0p6m2pgP8b4Y9VHx2BJtr+UBdADTHLpl1 +neWIA6pN+APSQnbAGwIDAKiLo0UwQzASBgNVHRMBAf8ECDAGAQH/AgEEMA4GA1UdDwEB/wQEAwIB +BjAdBgNVHQ4EFgQUzPpnk/C2uNClwB7zU/2MU9+D15YwDQYJKoZIhvcNAQELBQADggEBAKt/7hwW +qZw8UQCgwBEIBaeZ5m8BiFRhbvG5GK1Krf6BQCOUL/t1fC8oS2IkgYIL9WHxHG64YTjrgfpioTta +YtOUZcTh5m2C+C8lcLIhJsFyUR+MLMOEkMNaj7rP9KdlpeuY0fsFskZ1FSNqb4VjMIDw1Z4fKRzC +bLBQWV2QWzuoDTDPv31/zvGdg73JRm4gpvlhUbohL3u+pRVjodSVh/GeufOJ8z2FuLjbvrW5Kfna +NwUASZQDhETnv0Mxz3WLJdH0pmT1kvarBes96aULNmLazAZfNou2XjG4Kvte9nHfRCaexOYNkbQu +dZWAUWpLMKawYqGT8ZvYzsRjdT9ZR7E= +-----END CERTIFICATE----- + +Staat der Nederlanden Root CA - G2 +================================== +-----BEGIN CERTIFICATE----- +MIIFyjCCA7KgAwIBAgIEAJiWjDANBgkqhkiG9w0BAQsFADBaMQswCQYDVQQGEwJOTDEeMBwGA1UE +CgwVU3RhYXQgZGVyIE5lZGVybGFuZGVuMSswKQYDVQQDDCJTdGFhdCBkZXIgTmVkZXJsYW5kZW4g +Um9vdCBDQSAtIEcyMB4XDTA4MDMyNjExMTgxN1oXDTIwMDMyNTExMDMxMFowWjELMAkGA1UEBhMC +TkwxHjAcBgNVBAoMFVN0YWF0IGRlciBOZWRlcmxhbmRlbjErMCkGA1UEAwwiU3RhYXQgZGVyIE5l +ZGVybGFuZGVuIFJvb3QgQ0EgLSBHMjCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAMVZ +5291qj5LnLW4rJ4L5PnZyqtdj7U5EILXr1HgO+EASGrP2uEGQxGZqhQlEq0i6ABtQ8SpuOUfiUtn +vWFI7/3S4GCI5bkYYCjDdyutsDeqN95kWSpGV+RLufg3fNU254DBtvPUZ5uW6M7XxgpT0GtJlvOj +CwV3SPcl5XCsMBQgJeN/dVrlSPhOewMHBPqCYYdu8DvEpMfQ9XQ+pV0aCPKbJdL2rAQmPlU6Yiil +e7Iwr/g3wtG61jj99O9JMDeZJiFIhQGp5Rbn3JBV3w/oOM2ZNyFPXfUib2rFEhZgF1XyZWampzCR +OME4HYYEhLoaJXhena/MUGDWE4dS7WMfbWV9whUYdMrhfmQpjHLYFhN9C0lK8SgbIHRrxT3dsKpI +CT0ugpTNGmXZK4iambwYfp/ufWZ8Pr2UuIHOzZgweMFvZ9C+X+Bo7d7iscksWXiSqt8rYGPy5V65 +48r6f1CGPqI0GAwJaCgRHOThuVw+R7oyPxjMW4T182t0xHJ04eOLoEq9jWYv6q012iDTiIJh8BIi +trzQ1aTsr1SIJSQ8p22xcik/Plemf1WvbibG/ufMQFxRRIEKeN5KzlW/HdXZt1bv8Hb/C3m1r737 +qWmRRpdogBQ2HbN/uymYNqUg+oJgYjOk7Na6B6duxc8UpufWkjTYgfX8HV2qXB72o007uPc5AgMB +AAGjgZcwgZQwDwYDVR0TAQH/BAUwAwEB/zBSBgNVHSAESzBJMEcGBFUdIAAwPzA9BggrBgEFBQcC +ARYxaHR0cDovL3d3dy5wa2lvdmVyaGVpZC5ubC9wb2xpY2llcy9yb290LXBvbGljeS1HMjAOBgNV +HQ8BAf8EBAMCAQYwHQYDVR0OBBYEFJFoMocVHYnitfGsNig0jQt8YojrMA0GCSqGSIb3DQEBCwUA +A4ICAQCoQUpnKpKBglBu4dfYszk78wIVCVBR7y29JHuIhjv5tLySCZa59sCrI2AGeYwRTlHSeYAz ++51IvuxBQ4EffkdAHOV6CMqqi3WtFMTC6GY8ggen5ieCWxjmD27ZUD6KQhgpxrRW/FYQoAUXvQwj +f/ST7ZwaUb7dRUG/kSS0H4zpX897IZmflZ85OkYcbPnNe5yQzSipx6lVu6xiNGI1E0sUOlWDuYaN +kqbG9AclVMwWVxJKgnjIFNkXgiYtXSAfea7+1HAWFpWD2DU5/1JddRwWxRNVz0fMdWVSSt7wsKfk +CpYL+63C4iWEst3kvX5ZbJvw8NjnyvLplzh+ib7M+zkXYT9y2zqR2GUBGR2tUKRXCnxLvJxxcypF +URmFzI79R6d0lR2o0a9OF7FpJsKqeFdbxU2n5Z4FF5TKsl+gSRiNNOkmbEgeqmiSBeGCc1qb3Adb +CG19ndeNIdn8FCCqwkXfP+cAslHkwvgFuXkajDTznlvkN1trSt8sV4pAWja63XVECDdCcAz+3F4h +oKOKwJCcaNpQ5kUQR3i2TtJlycM33+FCY7BXN0Ute4qcvwXqZVUz9zkQxSgqIXobisQk+T8VyJoV +IPVVYpbtbZNQvOSqeK3Zywplh6ZmwcSBo3c6WB4L7oOLnR7SUqTMHW+wmG2UMbX4cQrcufx9MmDm +66+KAQ== +-----END CERTIFICATE----- + +Hongkong Post Root CA 1 +======================= +-----BEGIN CERTIFICATE----- +MIIDMDCCAhigAwIBAgICA+gwDQYJKoZIhvcNAQEFBQAwRzELMAkGA1UEBhMCSEsxFjAUBgNVBAoT +DUhvbmdrb25nIFBvc3QxIDAeBgNVBAMTF0hvbmdrb25nIFBvc3QgUm9vdCBDQSAxMB4XDTAzMDUx +NTA1MTMxNFoXDTIzMDUxNTA0NTIyOVowRzELMAkGA1UEBhMCSEsxFjAUBgNVBAoTDUhvbmdrb25n +IFBvc3QxIDAeBgNVBAMTF0hvbmdrb25nIFBvc3QgUm9vdCBDQSAxMIIBIjANBgkqhkiG9w0BAQEF +AAOCAQ8AMIIBCgKCAQEArP84tulmAknjorThkPlAj3n54r15/gK97iSSHSL22oVyaf7XPwnU3ZG1 +ApzQjVrhVcNQhrkpJsLj2aDxaQMoIIBFIi1WpztUlVYiWR8o3x8gPW2iNr4joLFutbEnPzlTCeqr +auh0ssJlXI6/fMN4hM2eFvz1Lk8gKgifd/PFHsSaUmYeSF7jEAaPIpjhZY4bXSNmO7ilMlHIhqqh +qZ5/dpTCpmy3QfDVyAY45tQM4vM7TG1QjMSDJ8EThFk9nnV0ttgCXjqQesBCNnLsak3c78QA3xMY +V18meMjWCnl3v/evt3a5pQuEF10Q6m/hq5URX208o1xNg1vysxmKgIsLhwIDAQABoyYwJDASBgNV +HRMBAf8ECDAGAQH/AgEDMA4GA1UdDwEB/wQEAwIBxjANBgkqhkiG9w0BAQUFAAOCAQEADkbVPK7i +h9legYsCmEEIjEy82tvuJxuC52pF7BaLT4Wg87JwvVqWuspube5Gi27nKi6Wsxkz67SfqLI37pio +l7Yutmcn1KZJ/RyTZXaeQi/cImyaT/JaFTmxcdcrUehtHJjA2Sr0oYJ71clBoiMBdDhViw+5Lmei +IAQ32pwL0xch4I+XeTRvhEgCIDMb5jREn5Fw9IBehEPCKdJsEhTkYY2sEJCehFC78JZvRZ+K88ps +T/oROhUVRsPNH4NbLUES7VBnQRM9IauUiqpOfMGx+6fWtScvl6tu4B3i0RwsH0Ti/L6RoZz71ilT +c4afU9hDDl3WY4JxHYB0yvbiAmvZWg== +-----END CERTIFICATE----- + +SecureSign RootCA11 +=================== +-----BEGIN CERTIFICATE----- +MIIDbTCCAlWgAwIBAgIBATANBgkqhkiG9w0BAQUFADBYMQswCQYDVQQGEwJKUDErMCkGA1UEChMi +SmFwYW4gQ2VydGlmaWNhdGlvbiBTZXJ2aWNlcywgSW5jLjEcMBoGA1UEAxMTU2VjdXJlU2lnbiBS +b290Q0ExMTAeFw0wOTA0MDgwNDU2NDdaFw0yOTA0MDgwNDU2NDdaMFgxCzAJBgNVBAYTAkpQMSsw +KQYDVQQKEyJKYXBhbiBDZXJ0aWZpY2F0aW9uIFNlcnZpY2VzLCBJbmMuMRwwGgYDVQQDExNTZWN1 +cmVTaWduIFJvb3RDQTExMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA/XeqpRyQBTvL +TJszi1oURaTnkBbR31fSIRCkF/3frNYfp+TbfPfs37gD2pRY/V1yfIw/XwFndBWW4wI8h9uuywGO +wvNmxoVF9ALGOrVisq/6nL+k5tSAMJjzDbaTj6nU2DbysPyKyiyhFTOVMdrAG/LuYpmGYz+/3ZMq +g6h2uRMft85OQoWPIucuGvKVCbIFtUROd6EgvanyTgp9UK31BQ1FT0Zx/Sg+U/sE2C3XZR1KG/rP +O7AxmjVuyIsG0wCR8pQIZUyxNAYAeoni8McDWc/V1uinMrPmmECGxc0nEovMe863ETxiYAcjPitA +bpSACW22s293bzUIUPsCh8U+iQIDAQABo0IwQDAdBgNVHQ4EFgQUW/hNT7KlhtQ60vFjmqC+CfZX +t94wDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wDQYJKoZIhvcNAQEFBQADggEBAKCh +OBZmLqdWHyGcBvod7bkixTgm2E5P7KN/ed5GIaGHd48HCJqypMWvDzKYC3xmKbabfSVSSUOrTC4r +bnpwrxYO4wJs+0LmGJ1F2FXI6Dvd5+H0LgscNFxsWEr7jIhQX5Ucv+2rIrVls4W6ng+4reV6G4pQ +Oh29Dbx7VFALuUKvVaAYga1lme++5Jy/xIWrQbJUb9wlze144o4MjQlJ3WN7WmmWAiGovVJZ6X01 +y8hSyn+B/tlr0/cR7SXf+Of5pPpyl4RTDaXQMhhRdlkUbA/r7F+AjHVDg8OFmP9Mni0N5HeDk061 +lgeLKBObjBmNQSdJQO7e5iNEOdyhIta6A/I= +-----END CERTIFICATE----- + +Microsec e-Szigno Root CA 2009 +============================== +-----BEGIN CERTIFICATE----- +MIIECjCCAvKgAwIBAgIJAMJ+QwRORz8ZMA0GCSqGSIb3DQEBCwUAMIGCMQswCQYDVQQGEwJIVTER +MA8GA1UEBwwIQnVkYXBlc3QxFjAUBgNVBAoMDU1pY3Jvc2VjIEx0ZC4xJzAlBgNVBAMMHk1pY3Jv +c2VjIGUtU3ppZ25vIFJvb3QgQ0EgMjAwOTEfMB0GCSqGSIb3DQEJARYQaW5mb0BlLXN6aWduby5o +dTAeFw0wOTA2MTYxMTMwMThaFw0yOTEyMzAxMTMwMThaMIGCMQswCQYDVQQGEwJIVTERMA8GA1UE +BwwIQnVkYXBlc3QxFjAUBgNVBAoMDU1pY3Jvc2VjIEx0ZC4xJzAlBgNVBAMMHk1pY3Jvc2VjIGUt +U3ppZ25vIFJvb3QgQ0EgMjAwOTEfMB0GCSqGSIb3DQEJARYQaW5mb0BlLXN6aWduby5odTCCASIw +DQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAOn4j/NjrdqG2KfgQvvPkd6mJviZpWNwrZuuyjNA +fW2WbqEORO7hE52UQlKavXWFdCyoDh2Tthi3jCyoz/tccbna7P7ofo/kLx2yqHWH2Leh5TvPmUpG +0IMZfcChEhyVbUr02MelTTMuhTlAdX4UfIASmFDHQWe4oIBhVKZsTh/gnQ4H6cm6M+f+wFUoLAKA +pxn1ntxVUwOXewdI/5n7N4okxFnMUBBjjqqpGrCEGob5X7uxUG6k0QrM1XF+H6cbfPVTbiJfyyvm +1HxdrtbCxkzlBQHZ7Vf8wSN5/PrIJIOV87VqUQHQd9bpEqH5GoP7ghu5sJf0dgYzQ0mg/wu1+rUC +AwEAAaOBgDB+MA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBTLD8bf +QkPMPcu1SCOhGnqmKrs0aDAfBgNVHSMEGDAWgBTLD8bfQkPMPcu1SCOhGnqmKrs0aDAbBgNVHREE +FDASgRBpbmZvQGUtc3ppZ25vLmh1MA0GCSqGSIb3DQEBCwUAA4IBAQDJ0Q5eLtXMs3w+y/w9/w0o +lZMEyL/azXm4Q5DwpL7v8u8hmLzU1F0G9u5C7DBsoKqpyvGvivo/C3NqPuouQH4frlRheesuCDfX +I/OMn74dseGkddug4lQUsbocKaQY9hK6ohQU4zE1yED/t+AFdlfBHFny+L/k7SViXITwfn4fs775 +tyERzAMBVnCnEJIeGzSBHq2cGsMEPO0CYdYeBvNfOofyK/FFh+U9rNHHV4S9a67c2Pm2G2JwCz02 +yULyMtd6YebS2z3PyKnJm9zbWETXbzivf3jTo60adbocwTZ8jx5tHMN1Rq41Bab2XD0h7lbwyYIi +LXpUq3DDfSJlgnCW +-----END CERTIFICATE----- + +GlobalSign Root CA - R3 +======================= +-----BEGIN CERTIFICATE----- +MIIDXzCCAkegAwIBAgILBAAAAAABIVhTCKIwDQYJKoZIhvcNAQELBQAwTDEgMB4GA1UECxMXR2xv +YmFsU2lnbiBSb290IENBIC0gUjMxEzARBgNVBAoTCkdsb2JhbFNpZ24xEzARBgNVBAMTCkdsb2Jh +bFNpZ24wHhcNMDkwMzE4MTAwMDAwWhcNMjkwMzE4MTAwMDAwWjBMMSAwHgYDVQQLExdHbG9iYWxT +aWduIFJvb3QgQ0EgLSBSMzETMBEGA1UEChMKR2xvYmFsU2lnbjETMBEGA1UEAxMKR2xvYmFsU2ln +bjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAMwldpB5BngiFvXAg7aEyiie/QV2EcWt +iHL8RgJDx7KKnQRfJMsuS+FggkbhUqsMgUdwbN1k0ev1LKMPgj0MK66X17YUhhB5uzsTgHeMCOFJ +0mpiLx9e+pZo34knlTifBtc+ycsmWQ1z3rDI6SYOgxXG71uL0gRgykmmKPZpO/bLyCiR5Z2KYVc3 +rHQU3HTgOu5yLy6c+9C7v/U9AOEGM+iCK65TpjoWc4zdQQ4gOsC0p6Hpsk+QLjJg6VfLuQSSaGjl +OCZgdbKfd/+RFO+uIEn8rUAVSNECMWEZXriX7613t2Saer9fwRPvm2L7DWzgVGkWqQPabumDk3F2 +xmmFghcCAwEAAaNCMEAwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYE +FI/wS3+oLkUkrk1Q+mOai97i3Ru8MA0GCSqGSIb3DQEBCwUAA4IBAQBLQNvAUKr+yAzv95ZURUm7 +lgAJQayzE4aGKAczymvmdLm6AC2upArT9fHxD4q/c2dKg8dEe3jgr25sbwMpjjM5RcOO5LlXbKr8 +EpbsU8Yt5CRsuZRj+9xTaGdWPoO4zzUhw8lo/s7awlOqzJCK6fBdRoyV3XpYKBovHd7NADdBj+1E +bddTKJd+82cEHhXXipa0095MJ6RMG3NzdvQXmcIfeg7jLQitChws/zyrVQ4PkX4268NXSb7hLi18 +YIvDQVETI53O9zJrlAGomecsMx86OyXShkDOOyyGeMlhLxS67ttVb9+E7gUJTb0o2HLO02JQZR7r +kpeDMdmztcpHWD9f +-----END CERTIFICATE----- + +Autoridad de Certificacion Firmaprofesional CIF A62634068 +========================================================= +-----BEGIN CERTIFICATE----- +MIIGFDCCA/ygAwIBAgIIU+w77vuySF8wDQYJKoZIhvcNAQEFBQAwUTELMAkGA1UEBhMCRVMxQjBA +BgNVBAMMOUF1dG9yaWRhZCBkZSBDZXJ0aWZpY2FjaW9uIEZpcm1hcHJvZmVzaW9uYWwgQ0lGIEE2 +MjYzNDA2ODAeFw0wOTA1MjAwODM4MTVaFw0zMDEyMzEwODM4MTVaMFExCzAJBgNVBAYTAkVTMUIw +QAYDVQQDDDlBdXRvcmlkYWQgZGUgQ2VydGlmaWNhY2lvbiBGaXJtYXByb2Zlc2lvbmFsIENJRiBB +NjI2MzQwNjgwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDKlmuO6vj78aI14H9M2uDD +Utd9thDIAl6zQyrET2qyyhxdKJp4ERppWVevtSBC5IsP5t9bpgOSL/UR5GLXMnE42QQMcas9UX4P +B99jBVzpv5RvwSmCwLTaUbDBPLutN0pcyvFLNg4kq7/DhHf9qFD0sefGL9ItWY16Ck6WaVICqjaY +7Pz6FIMMNx/Jkjd/14Et5cS54D40/mf0PmbR0/RAz15iNA9wBj4gGFrO93IbJWyTdBSTo3OxDqqH +ECNZXyAFGUftaI6SEspd/NYrspI8IM/hX68gvqB2f3bl7BqGYTM+53u0P6APjqK5am+5hyZvQWyI +plD9amML9ZMWGxmPsu2bm8mQ9QEM3xk9Dz44I8kvjwzRAv4bVdZO0I08r0+k8/6vKtMFnXkIoctX +MbScyJCyZ/QYFpM6/EfY0XiWMR+6KwxfXZmtY4laJCB22N/9q06mIqqdXuYnin1oKaPnirjaEbsX +LZmdEyRG98Xi2J+Of8ePdG1asuhy9azuJBCtLxTa/y2aRnFHvkLfuwHb9H/TKI8xWVvTyQKmtFLK +bpf7Q8UIJm+K9Lv9nyiqDdVF8xM6HdjAeI9BZzwelGSuewvF6NkBiDkal4ZkQdU7hwxu+g/GvUgU +vzlN1J5Bto+WHWOWk9mVBngxaJ43BjuAiUVhOSPHG0SjFeUc+JIwuwIDAQABo4HvMIHsMBIGA1Ud +EwEB/wQIMAYBAf8CAQEwDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBRlzeurNR4APn7VdMActHNH +DhpkLzCBpgYDVR0gBIGeMIGbMIGYBgRVHSAAMIGPMC8GCCsGAQUFBwIBFiNodHRwOi8vd3d3LmZp +cm1hcHJvZmVzaW9uYWwuY29tL2NwczBcBggrBgEFBQcCAjBQHk4AUABhAHMAZQBvACAAZABlACAA +bABhACAAQgBvAG4AYQBuAG8AdgBhACAANAA3ACAAQgBhAHIAYwBlAGwAbwBuAGEAIAAwADgAMAAx +ADcwDQYJKoZIhvcNAQEFBQADggIBABd9oPm03cXF661LJLWhAqvdpYhKsg9VSytXjDvlMd3+xDLx +51tkljYyGOylMnfX40S2wBEqgLk9am58m9Ot/MPWo+ZkKXzR4Tgegiv/J2Wv+xYVxC5xhOW1//qk +R71kMrv2JYSiJ0L1ILDCExARzRAVukKQKtJE4ZYm6zFIEv0q2skGz3QeqUvVhyj5eTSSPi5E6PaP +T481PyWzOdxjKpBrIF/EUhJOlywqrJ2X3kjyo2bbwtKDlaZmp54lD+kLM5FlClrD2VQS3a/DTg4f +Jl4N3LON7NWBcN7STyQF82xO9UxJZo3R/9ILJUFI/lGExkKvgATP0H5kSeTy36LssUzAKh3ntLFl +osS88Zj0qnAHY7S42jtM+kAiMFsRpvAFDsYCA0irhpuF3dvd6qJ2gHN99ZwExEWN57kci57q13XR +crHedUTnQn3iV2t93Jm8PYMo6oCTjcVMZcFwgbg4/EMxsvYDNEeyrPsiBsse3RdHHF9mudMaotoR +saS8I8nkvof/uZS2+F0gStRf571oe2XyFR7SOqkt6dhrJKyXWERHrVkY8SFlcN7ONGCoQPHzPKTD +KCOM/iczQ0CgFzzr6juwcqajuUpLXhZI9LK8yIySxZ2frHI2vDSANGupi5LAuBft7HZT9SQBjLMi +6Et8Vcad+qMUu2WFbm5PEn4KPJ2V +-----END CERTIFICATE----- + +Izenpe.com +========== +-----BEGIN CERTIFICATE----- +MIIF8TCCA9mgAwIBAgIQALC3WhZIX7/hy/WL1xnmfTANBgkqhkiG9w0BAQsFADA4MQswCQYDVQQG +EwJFUzEUMBIGA1UECgwLSVpFTlBFIFMuQS4xEzARBgNVBAMMCkl6ZW5wZS5jb20wHhcNMDcxMjEz +MTMwODI4WhcNMzcxMjEzMDgyNzI1WjA4MQswCQYDVQQGEwJFUzEUMBIGA1UECgwLSVpFTlBFIFMu +QS4xEzARBgNVBAMMCkl6ZW5wZS5jb20wggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDJ +03rKDx6sp4boFmVqscIbRTJxldn+EFvMr+eleQGPicPK8lVx93e+d5TzcqQsRNiekpsUOqHnJJAK +ClaOxdgmlOHZSOEtPtoKct2jmRXagaKH9HtuJneJWK3W6wyyQXpzbm3benhB6QiIEn6HLmYRY2xU ++zydcsC8Lv/Ct90NduM61/e0aL6i9eOBbsFGb12N4E3GVFWJGjMxCrFXuaOKmMPsOzTFlUFpfnXC +PCDFYbpRR6AgkJOhkEvzTnyFRVSa0QUmQbC1TR0zvsQDyCV8wXDbO/QJLVQnSKwv4cSsPsjLkkxT +OTcj7NMB+eAJRE1NZMDhDVqHIrytG6P+JrUV86f8hBnp7KGItERphIPzidF0BqnMC9bC3ieFUCbK +F7jJeodWLBoBHmy+E60QrLUk9TiRodZL2vG70t5HtfG8gfZZa88ZU+mNFctKy6lvROUbQc/hhqfK +0GqfvEyNBjNaooXlkDWgYlwWTvDjovoDGrQscbNYLN57C9saD+veIR8GdwYDsMnvmfzAuU8Lhij+ +0rnq49qlw0dpEuDb8PYZi+17cNcC1u2HGCgsBCRMd+RIihrGO5rUD8r6ddIBQFqNeb+Lz0vPqhbB +leStTIo+F5HUsWLlguWABKQDfo2/2n+iD5dPDNMN+9fR5XJ+HMh3/1uaD7euBUbl8agW7EekFwID +AQABo4H2MIHzMIGwBgNVHREEgagwgaWBD2luZm9AaXplbnBlLmNvbaSBkTCBjjFHMEUGA1UECgw+ +SVpFTlBFIFMuQS4gLSBDSUYgQTAxMzM3MjYwLVJNZXJjLlZpdG9yaWEtR2FzdGVpeiBUMTA1NSBG +NjIgUzgxQzBBBgNVBAkMOkF2ZGEgZGVsIE1lZGl0ZXJyYW5lbyBFdG9yYmlkZWEgMTQgLSAwMTAx +MCBWaXRvcmlhLUdhc3RlaXowDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0O +BBYEFB0cZQ6o8iV7tJHP5LGx5r1VdGwFMA0GCSqGSIb3DQEBCwUAA4ICAQB4pgwWSp9MiDrAyw6l +Fn2fuUhfGI8NYjb2zRlrrKvV9pF9rnHzP7MOeIWblaQnIUdCSnxIOvVFfLMMjlF4rJUT3sb9fbga +kEyrkgPH7UIBzg/YsfqikuFgba56awmqxinuaElnMIAkejEWOVt+8Rwu3WwJrfIxwYJOubv5vr8q +hT/AQKM6WfxZSzwoJNu0FXWuDYi6LnPAvViH5ULy617uHjAimcs30cQhbIHsvm0m5hzkQiCeR7Cs +g1lwLDXWrzY0tM07+DKo7+N4ifuNRSzanLh+QBxh5z6ikixL8s36mLYp//Pye6kfLqCTVyvehQP5 +aTfLnnhqBbTFMXiJ7HqnheG5ezzevh55hM6fcA5ZwjUukCox2eRFekGkLhObNA5me0mrZJfQRsN5 +nXJQY6aYWwa9SG3YOYNw6DXwBdGqvOPbyALqfP2C2sJbUjWumDqtujWTI6cfSN01RpiyEGjkpTHC +ClguGYEQyVB1/OpaFs4R1+7vUIgtYf8/QnMFlEPVjjxOAToZpR9GTnfQXeWBIiGH/pR9hNiTrdZo +Q0iy2+tzJOeRf1SktoA+naM8THLCV8Sg1Mw4J87VBp6iSNnpn86CcDaTmjvfliHjWbcM2pE38P1Z +WrOZyGlsQyYBNWNgVYkDOnXYukrZVP/u3oDYLdE41V4tC5h9Pmzb/CaIxw== +-----END CERTIFICATE----- + +Chambers of Commerce Root - 2008 +================================ +-----BEGIN CERTIFICATE----- +MIIHTzCCBTegAwIBAgIJAKPaQn6ksa7aMA0GCSqGSIb3DQEBBQUAMIGuMQswCQYDVQQGEwJFVTFD +MEEGA1UEBxM6TWFkcmlkIChzZWUgY3VycmVudCBhZGRyZXNzIGF0IHd3dy5jYW1lcmZpcm1hLmNv +bS9hZGRyZXNzKTESMBAGA1UEBRMJQTgyNzQzMjg3MRswGQYDVQQKExJBQyBDYW1lcmZpcm1hIFMu +QS4xKTAnBgNVBAMTIENoYW1iZXJzIG9mIENvbW1lcmNlIFJvb3QgLSAyMDA4MB4XDTA4MDgwMTEy +Mjk1MFoXDTM4MDczMTEyMjk1MFowga4xCzAJBgNVBAYTAkVVMUMwQQYDVQQHEzpNYWRyaWQgKHNl +ZSBjdXJyZW50IGFkZHJlc3MgYXQgd3d3LmNhbWVyZmlybWEuY29tL2FkZHJlc3MpMRIwEAYDVQQF +EwlBODI3NDMyODcxGzAZBgNVBAoTEkFDIENhbWVyZmlybWEgUy5BLjEpMCcGA1UEAxMgQ2hhbWJl +cnMgb2YgQ29tbWVyY2UgUm9vdCAtIDIwMDgwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoIC +AQCvAMtwNyuAWko6bHiUfaN/Gh/2NdW928sNRHI+JrKQUrpjOyhYb6WzbZSm891kDFX29ufyIiKA +XuFixrYp4YFs8r/lfTJqVKAyGVn+H4vXPWCGhSRv4xGzdz4gljUha7MI2XAuZPeEklPWDrCQiorj +h40G072QDuKZoRuGDtqaCrsLYVAGUvGef3bsyw/QHg3PmTA9HMRFEFis1tPo1+XqxQEHd9ZR5gN/ +ikilTWh1uem8nk4ZcfUyS5xtYBkL+8ydddy/Js2Pk3g5eXNeJQ7KXOt3EgfLZEFHcpOrUMPrCXZk +NNI5t3YRCQ12RcSprj1qr7V9ZS+UWBDsXHyvfuK2GNnQm05aSd+pZgvMPMZ4fKecHePOjlO+Bd5g +D2vlGts/4+EhySnB8esHnFIbAURRPHsl18TlUlRdJQfKFiC4reRB7noI/plvg6aRArBsNlVq5331 +lubKgdaX8ZSD6e2wsWsSaR6s+12pxZjptFtYer49okQ6Y1nUCyXeG0+95QGezdIp1Z8XGQpvvwyQ +0wlf2eOKNcx5Wk0ZN5K3xMGtr/R5JJqyAQuxr1yW84Ay+1w9mPGgP0revq+ULtlVmhduYJ1jbLhj +ya6BXBg14JC7vjxPNyK5fuvPnnchpj04gftI2jE9K+OJ9dC1vX7gUMQSibMjmhAxhduub+84Mxh2 +EQIDAQABo4IBbDCCAWgwEgYDVR0TAQH/BAgwBgEB/wIBDDAdBgNVHQ4EFgQU+SSsD7K1+HnA+mCI +G8TZTQKeFxkwgeMGA1UdIwSB2zCB2IAU+SSsD7K1+HnA+mCIG8TZTQKeFxmhgbSkgbEwga4xCzAJ +BgNVBAYTAkVVMUMwQQYDVQQHEzpNYWRyaWQgKHNlZSBjdXJyZW50IGFkZHJlc3MgYXQgd3d3LmNh +bWVyZmlybWEuY29tL2FkZHJlc3MpMRIwEAYDVQQFEwlBODI3NDMyODcxGzAZBgNVBAoTEkFDIENh +bWVyZmlybWEgUy5BLjEpMCcGA1UEAxMgQ2hhbWJlcnMgb2YgQ29tbWVyY2UgUm9vdCAtIDIwMDiC +CQCj2kJ+pLGu2jAOBgNVHQ8BAf8EBAMCAQYwPQYDVR0gBDYwNDAyBgRVHSAAMCowKAYIKwYBBQUH +AgEWHGh0dHA6Ly9wb2xpY3kuY2FtZXJmaXJtYS5jb20wDQYJKoZIhvcNAQEFBQADggIBAJASryI1 +wqM58C7e6bXpeHxIvj99RZJe6dqxGfwWPJ+0W2aeaufDuV2I6A+tzyMP3iU6XsxPpcG1Lawk0lgH +3qLPaYRgM+gQDROpI9CF5Y57pp49chNyM/WqfcZjHwj0/gF/JM8rLFQJ3uIrbZLGOU8W6jx+ekbU +RWpGqOt1glanq6B8aBMz9p0w8G8nOSQjKpD9kCk18pPfNKXG9/jvjA9iSnyu0/VU+I22mlaHFoI6 +M6taIgj3grrqLuBHmrS1RaMFO9ncLkVAO+rcf+g769HsJtg1pDDFOqxXnrN2pSB7+R5KBWIBpih1 +YJeSDW4+TTdDDZIVnBgizVGZoCkaPF+KMjNbMMeJL0eYD6MDxvbxrN8y8NmBGuScvfaAFPDRLLmF +9dijscilIeUcE5fuDr3fKanvNFNb0+RqE4QGtjICxFKuItLcsiFCGtpA8CnJ7AoMXOLQusxI0zcK +zBIKinmwPQN/aUv0NCB9szTqjktk9T79syNnFQ0EuPAtwQlRPLJsFfClI9eDdOTlLsn+mCdCxqvG +nrDQWzilm1DefhiYtUU79nm06PcaewaD+9CL2rvHvRirCG88gGtAPxkZumWK5r7VXNM21+9AUiRg +OGcEMeyP84LG3rlV8zsxkVrctQgVrXYlCg17LofiDKYGvCYQbTed7N14jHyAxfDZd0jQ +-----END CERTIFICATE----- + +Global Chambersign Root - 2008 +============================== +-----BEGIN CERTIFICATE----- +MIIHSTCCBTGgAwIBAgIJAMnN0+nVfSPOMA0GCSqGSIb3DQEBBQUAMIGsMQswCQYDVQQGEwJFVTFD +MEEGA1UEBxM6TWFkcmlkIChzZWUgY3VycmVudCBhZGRyZXNzIGF0IHd3dy5jYW1lcmZpcm1hLmNv +bS9hZGRyZXNzKTESMBAGA1UEBRMJQTgyNzQzMjg3MRswGQYDVQQKExJBQyBDYW1lcmZpcm1hIFMu +QS4xJzAlBgNVBAMTHkdsb2JhbCBDaGFtYmVyc2lnbiBSb290IC0gMjAwODAeFw0wODA4MDExMjMx +NDBaFw0zODA3MzExMjMxNDBaMIGsMQswCQYDVQQGEwJFVTFDMEEGA1UEBxM6TWFkcmlkIChzZWUg +Y3VycmVudCBhZGRyZXNzIGF0IHd3dy5jYW1lcmZpcm1hLmNvbS9hZGRyZXNzKTESMBAGA1UEBRMJ +QTgyNzQzMjg3MRswGQYDVQQKExJBQyBDYW1lcmZpcm1hIFMuQS4xJzAlBgNVBAMTHkdsb2JhbCBD +aGFtYmVyc2lnbiBSb290IC0gMjAwODCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAMDf +VtPkOpt2RbQT2//BthmLN0EYlVJH6xedKYiONWwGMi5HYvNJBL99RDaxccy9Wglz1dmFRP+RVyXf +XjaOcNFccUMd2drvXNL7G706tcuto8xEpw2uIRU/uXpbknXYpBI4iRmKt4DS4jJvVpyR1ogQC7N0 +ZJJ0YPP2zxhPYLIj0Mc7zmFLmY/CDNBAspjcDahOo7kKrmCgrUVSY7pmvWjg+b4aqIG7HkF4ddPB +/gBVsIdU6CeQNR1MM62X/JcumIS/LMmjv9GYERTtY/jKmIhYF5ntRQOXfjyGHoiMvvKRhI9lNNgA +TH23MRdaKXoKGCQwoze1eqkBfSbW+Q6OWfH9GzO1KTsXO0G2Id3UwD2ln58fQ1DJu7xsepeY7s2M +H/ucUa6LcL0nn3HAa6x9kGbo1106DbDVwo3VyJ2dwW3Q0L9R5OP4wzg2rtandeavhENdk5IMagfe +Ox2YItaswTXbo6Al/3K1dh3ebeksZixShNBFks4c5eUzHdwHU1SjqoI7mjcv3N2gZOnm3b2u/GSF +HTynyQbehP9r6GsaPMWis0L7iwk+XwhSx2LE1AVxv8Rk5Pihg+g+EpuoHtQ2TS9x9o0o9oOpE9Jh +wZG7SMA0j0GMS0zbaRL/UJScIINZc+18ofLx/d33SdNDWKBWY8o9PeU1VlnpDsogzCtLkykPAgMB +AAGjggFqMIIBZjASBgNVHRMBAf8ECDAGAQH/AgEMMB0GA1UdDgQWBBS5CcqcHtvTbDprru1U8VuT +BjUuXjCB4QYDVR0jBIHZMIHWgBS5CcqcHtvTbDprru1U8VuTBjUuXqGBsqSBrzCBrDELMAkGA1UE +BhMCRVUxQzBBBgNVBAcTOk1hZHJpZCAoc2VlIGN1cnJlbnQgYWRkcmVzcyBhdCB3d3cuY2FtZXJm +aXJtYS5jb20vYWRkcmVzcykxEjAQBgNVBAUTCUE4Mjc0MzI4NzEbMBkGA1UEChMSQUMgQ2FtZXJm +aXJtYSBTLkEuMScwJQYDVQQDEx5HbG9iYWwgQ2hhbWJlcnNpZ24gUm9vdCAtIDIwMDiCCQDJzdPp +1X0jzjAOBgNVHQ8BAf8EBAMCAQYwPQYDVR0gBDYwNDAyBgRVHSAAMCowKAYIKwYBBQUHAgEWHGh0 +dHA6Ly9wb2xpY3kuY2FtZXJmaXJtYS5jb20wDQYJKoZIhvcNAQEFBQADggIBAICIf3DekijZBZRG +/5BXqfEv3xoNa/p8DhxJJHkn2EaqbylZUohwEurdPfWbU1Rv4WCiqAm57OtZfMY18dwY6fFn5a+6 +ReAJ3spED8IXDneRRXozX1+WLGiLwUePmJs9wOzL9dWCkoQ10b42OFZyMVtHLaoXpGNR6woBrX/s +dZ7LoR/xfxKxueRkf2fWIyr0uDldmOghp+G9PUIadJpwr2hsUF1Jz//7Dl3mLEfXgTpZALVza2Mg +9jFFCDkO9HB+QHBaP9BrQql0PSgvAm11cpUJjUhjxsYjV5KTXjXBjfkK9yydYhz2rXzdpjEetrHH +foUm+qRqtdpjMNHvkzeyZi99Bffnt0uYlDXA2TopwZ2yUDMdSqlapskD7+3056huirRXhOukP9Du +qqqHW2Pok+JrqNS4cnhrG+055F3Lm6qH1U9OAP7Zap88MQ8oAgF9mOinsKJknnn4SPIVqczmyETr +P3iZ8ntxPjzxmKfFGBI/5rsoM0LpRQp8bfKGeS/Fghl9CYl8slR2iK7ewfPM4W7bMdaTrpmg7yVq +c5iJWzouE4gev8CSlDQb4ye3ix5vQv/n6TebUB0tovkC7stYWDpxvGjjqsGvHCgfotwjZT+B6q6Z +09gwzxMNTxXJhLynSC34MCN32EZLeW32jO06f2ARePTpm67VVMB0gNELQp/B +-----END CERTIFICATE----- + +Go Daddy Root Certificate Authority - G2 +======================================== +-----BEGIN CERTIFICATE----- +MIIDxTCCAq2gAwIBAgIBADANBgkqhkiG9w0BAQsFADCBgzELMAkGA1UEBhMCVVMxEDAOBgNVBAgT +B0FyaXpvbmExEzARBgNVBAcTClNjb3R0c2RhbGUxGjAYBgNVBAoTEUdvRGFkZHkuY29tLCBJbmMu +MTEwLwYDVQQDEyhHbyBEYWRkeSBSb290IENlcnRpZmljYXRlIEF1dGhvcml0eSAtIEcyMB4XDTA5 +MDkwMTAwMDAwMFoXDTM3MTIzMTIzNTk1OVowgYMxCzAJBgNVBAYTAlVTMRAwDgYDVQQIEwdBcml6 +b25hMRMwEQYDVQQHEwpTY290dHNkYWxlMRowGAYDVQQKExFHb0RhZGR5LmNvbSwgSW5jLjExMC8G +A1UEAxMoR28gRGFkZHkgUm9vdCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkgLSBHMjCCASIwDQYJKoZI +hvcNAQEBBQADggEPADCCAQoCggEBAL9xYgjx+lk09xvJGKP3gElY6SKDE6bFIEMBO4Tx5oVJnyfq +9oQbTqC023CYxzIBsQU+B07u9PpPL1kwIuerGVZr4oAH/PMWdYA5UXvl+TW2dE6pjYIT5LY/qQOD ++qK+ihVqf94Lw7YZFAXK6sOoBJQ7RnwyDfMAZiLIjWltNowRGLfTshxgtDj6AozO091GB94KPutd +fMh8+7ArU6SSYmlRJQVhGkSBjCypQ5Yj36w6gZoOKcUcqeldHraenjAKOc7xiID7S13MMuyFYkMl +NAJWJwGRtDtwKj9useiciAF9n9T521NtYJ2/LOdYq7hfRvzOxBsDPAnrSTFcaUaz4EcCAwEAAaNC +MEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFDqahQcQZyi27/a9 +BUFuIMGU2g/eMA0GCSqGSIb3DQEBCwUAA4IBAQCZ21151fmXWWcDYfF+OwYxdS2hII5PZYe096ac +vNjpL9DbWu7PdIxztDhC2gV7+AJ1uP2lsdeu9tfeE8tTEH6KRtGX+rcuKxGrkLAngPnon1rpN5+r +5N9ss4UXnT3ZJE95kTXWXwTrgIOrmgIttRD02JDHBHNA7XIloKmf7J6raBKZV8aPEjoJpL1E/QYV +N8Gb5DKj7Tjo2GTzLH4U/ALqn83/B2gX2yKQOC16jdFU8WnjXzPKej17CuPKf1855eJ1usV2GDPO +LPAvTK33sefOT6jEm0pUBsV/fdUID+Ic/n4XuKxe9tQWskMJDE32p2u0mYRlynqI4uJEvlz36hz1 +-----END CERTIFICATE----- + +Starfield Root Certificate Authority - G2 +========================================= +-----BEGIN CERTIFICATE----- +MIID3TCCAsWgAwIBAgIBADANBgkqhkiG9w0BAQsFADCBjzELMAkGA1UEBhMCVVMxEDAOBgNVBAgT +B0FyaXpvbmExEzARBgNVBAcTClNjb3R0c2RhbGUxJTAjBgNVBAoTHFN0YXJmaWVsZCBUZWNobm9s +b2dpZXMsIEluYy4xMjAwBgNVBAMTKVN0YXJmaWVsZCBSb290IENlcnRpZmljYXRlIEF1dGhvcml0 +eSAtIEcyMB4XDTA5MDkwMTAwMDAwMFoXDTM3MTIzMTIzNTk1OVowgY8xCzAJBgNVBAYTAlVTMRAw +DgYDVQQIEwdBcml6b25hMRMwEQYDVQQHEwpTY290dHNkYWxlMSUwIwYDVQQKExxTdGFyZmllbGQg +VGVjaG5vbG9naWVzLCBJbmMuMTIwMAYDVQQDEylTdGFyZmllbGQgUm9vdCBDZXJ0aWZpY2F0ZSBB +dXRob3JpdHkgLSBHMjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAL3twQP89o/8ArFv +W59I2Z154qK3A2FWGMNHttfKPTUuiUP3oWmb3ooa/RMgnLRJdzIpVv257IzdIvpy3Cdhl+72WoTs +bhm5iSzchFvVdPtrX8WJpRBSiUZV9Lh1HOZ/5FSuS/hVclcCGfgXcVnrHigHdMWdSL5stPSksPNk +N3mSwOxGXn/hbVNMYq/NHwtjuzqd+/x5AJhhdM8mgkBj87JyahkNmcrUDnXMN/uLicFZ8WJ/X7Nf +ZTD4p7dNdloedl40wOiWVpmKs/B/pM293DIxfJHP4F8R+GuqSVzRmZTRouNjWwl2tVZi4Ut0HZbU +JtQIBFnQmA4O5t78w+wfkPECAwEAAaNCMEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMC +AQYwHQYDVR0OBBYEFHwMMh+n2TB/xH1oo2Kooc6rB1snMA0GCSqGSIb3DQEBCwUAA4IBAQARWfol +TwNvlJk7mh+ChTnUdgWUXuEok21iXQnCoKjUsHU48TRqneSfioYmUeYs0cYtbpUgSpIB7LiKZ3sx +4mcujJUDJi5DnUox9g61DLu34jd/IroAow57UvtruzvE03lRTs2Q9GcHGcg8RnoNAX3FWOdt5oUw +F5okxBDgBPfg8n/Uqgr/Qh037ZTlZFkSIHc40zI+OIF1lnP6aI+xy84fxez6nH7PfrHxBy22/L/K +pL/QlwVKvOoYKAKQvVR4CSFx09F9HdkWsKlhPdAKACL8x3vLCWRFCztAgfd9fDL1mMpYjn0q7pBZ +c2T5NnReJaH1ZgUufzkVqSr7UIuOhWn0 +-----END CERTIFICATE----- + +Starfield Services Root Certificate Authority - G2 +================================================== +-----BEGIN CERTIFICATE----- +MIID7zCCAtegAwIBAgIBADANBgkqhkiG9w0BAQsFADCBmDELMAkGA1UEBhMCVVMxEDAOBgNVBAgT +B0FyaXpvbmExEzARBgNVBAcTClNjb3R0c2RhbGUxJTAjBgNVBAoTHFN0YXJmaWVsZCBUZWNobm9s +b2dpZXMsIEluYy4xOzA5BgNVBAMTMlN0YXJmaWVsZCBTZXJ2aWNlcyBSb290IENlcnRpZmljYXRl +IEF1dGhvcml0eSAtIEcyMB4XDTA5MDkwMTAwMDAwMFoXDTM3MTIzMTIzNTk1OVowgZgxCzAJBgNV +BAYTAlVTMRAwDgYDVQQIEwdBcml6b25hMRMwEQYDVQQHEwpTY290dHNkYWxlMSUwIwYDVQQKExxT +dGFyZmllbGQgVGVjaG5vbG9naWVzLCBJbmMuMTswOQYDVQQDEzJTdGFyZmllbGQgU2VydmljZXMg +Um9vdCBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkgLSBHMjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCC +AQoCggEBANUMOsQq+U7i9b4Zl1+OiFOxHz/Lz58gE20pOsgPfTz3a3Y4Y9k2YKibXlwAgLIvWX/2 +h/klQ4bnaRtSmpDhcePYLQ1Ob/bISdm28xpWriu2dBTrz/sm4xq6HZYuajtYlIlHVv8loJNwU4Pa +hHQUw2eeBGg6345AWh1KTs9DkTvnVtYAcMtS7nt9rjrnvDH5RfbCYM8TWQIrgMw0R9+53pBlbQLP +LJGmpufehRhJfGZOozptqbXuNC66DQO4M99H67FrjSXZm86B0UVGMpZwh94CDklDhbZsc7tk6mFB +rMnUVN+HL8cisibMn1lUaJ/8viovxFUcdUBgF4UCVTmLfwUCAwEAAaNCMEAwDwYDVR0TAQH/BAUw +AwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFJxfAN+qAdcwKziIorhtSpzyEZGDMA0GCSqG +SIb3DQEBCwUAA4IBAQBLNqaEd2ndOxmfZyMIbw5hyf2E3F/YNoHN2BtBLZ9g3ccaaNnRbobhiCPP +E95Dz+I0swSdHynVv/heyNXBve6SbzJ08pGCL72CQnqtKrcgfU28elUSwhXqvfdqlS5sdJ/PHLTy +xQGjhdByPq1zqwubdQxtRbeOlKyWN7Wg0I8VRw7j6IPdj/3vQQF3zCepYoUz8jcI73HPdwbeyBkd +iEDPfUYd/x7H4c7/I9vG+o1VTqkC50cRRj70/b17KSa7qWFiNyi2LSr2EIZkyXCn0q23KXB56jza +YyWf/Wi3MOxw+3WKt21gZ7IeyLnp2KhvAotnDU0mV3HaIPzBSlCNsSi6 +-----END CERTIFICATE----- + +AffirmTrust Commercial +====================== +-----BEGIN CERTIFICATE----- +MIIDTDCCAjSgAwIBAgIId3cGJyapsXwwDQYJKoZIhvcNAQELBQAwRDELMAkGA1UEBhMCVVMxFDAS +BgNVBAoMC0FmZmlybVRydXN0MR8wHQYDVQQDDBZBZmZpcm1UcnVzdCBDb21tZXJjaWFsMB4XDTEw +MDEyOTE0MDYwNloXDTMwMTIzMTE0MDYwNlowRDELMAkGA1UEBhMCVVMxFDASBgNVBAoMC0FmZmly +bVRydXN0MR8wHQYDVQQDDBZBZmZpcm1UcnVzdCBDb21tZXJjaWFsMIIBIjANBgkqhkiG9w0BAQEF +AAOCAQ8AMIIBCgKCAQEA9htPZwcroRX1BiLLHwGy43NFBkRJLLtJJRTWzsO3qyxPxkEylFf6Eqdb +DuKPHx6GGaeqtS25Xw2Kwq+FNXkyLbscYjfysVtKPcrNcV/pQr6U6Mje+SJIZMblq8Yrba0F8PrV +C8+a5fBQpIs7R6UjW3p6+DM/uO+Zl+MgwdYoic+U+7lF7eNAFxHUdPALMeIrJmqbTFeurCA+ukV6 +BfO9m2kVrn1OIGPENXY6BwLJN/3HR+7o8XYdcxXyl6S1yHp52UKqK39c/s4mT6NmgTWvRLpUHhww +MmWd5jyTXlBOeuM61G7MGvv50jeuJCqrVwMiKA1JdX+3KNp1v47j3A55MQIDAQABo0IwQDAdBgNV +HQ4EFgQUnZPGU4teyq8/nx4P5ZmVvCT2lI8wDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMC +AQYwDQYJKoZIhvcNAQELBQADggEBAFis9AQOzcAN/wr91LoWXym9e2iZWEnStB03TX8nfUYGXUPG +hi4+c7ImfU+TqbbEKpqrIZcUsd6M06uJFdhrJNTxFq7YpFzUf1GO7RgBsZNjvbz4YYCanrHOQnDi +qX0GJX0nof5v7LMeJNrjS1UaADs1tDvZ110w/YETifLCBivtZ8SOyUOyXGsViQK8YvxO8rUzqrJv +0wqiUOP2O+guRMLbZjipM1ZI8W0bM40NjD9gN53Tym1+NH4Nn3J2ixufcv1SNUFFApYvHLKac0kh +sUlHRUe072o0EclNmsxZt9YCnlpOZbWUrhvfKbAW8b8Angc6F2S1BLUjIZkKlTuXfO8= +-----END CERTIFICATE----- + +AffirmTrust Networking +====================== +-----BEGIN CERTIFICATE----- +MIIDTDCCAjSgAwIBAgIIfE8EORzUmS0wDQYJKoZIhvcNAQEFBQAwRDELMAkGA1UEBhMCVVMxFDAS +BgNVBAoMC0FmZmlybVRydXN0MR8wHQYDVQQDDBZBZmZpcm1UcnVzdCBOZXR3b3JraW5nMB4XDTEw +MDEyOTE0MDgyNFoXDTMwMTIzMTE0MDgyNFowRDELMAkGA1UEBhMCVVMxFDASBgNVBAoMC0FmZmly +bVRydXN0MR8wHQYDVQQDDBZBZmZpcm1UcnVzdCBOZXR3b3JraW5nMIIBIjANBgkqhkiG9w0BAQEF +AAOCAQ8AMIIBCgKCAQEAtITMMxcua5Rsa2FSoOujz3mUTOWUgJnLVWREZY9nZOIG41w3SfYvm4SE +Hi3yYJ0wTsyEheIszx6e/jarM3c1RNg1lho9Nuh6DtjVR6FqaYvZ/Ls6rnla1fTWcbuakCNrmreI +dIcMHl+5ni36q1Mr3Lt2PpNMCAiMHqIjHNRqrSK6mQEubWXLviRmVSRLQESxG9fhwoXA3hA/Pe24 +/PHxI1Pcv2WXb9n5QHGNfb2V1M6+oF4nI979ptAmDgAp6zxG8D1gvz9Q0twmQVGeFDdCBKNwV6gb +h+0t+nvujArjqWaJGctB+d1ENmHP4ndGyH329JKBNv3bNPFyfvMMFr20FQIDAQABo0IwQDAdBgNV +HQ4EFgQUBx/S55zawm6iQLSwelAQUHTEyL0wDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMC +AQYwDQYJKoZIhvcNAQEFBQADggEBAIlXshZ6qML91tmbmzTCnLQyFE2npN/svqe++EPbkTfOtDIu +UFUaNU52Q3Eg75N3ThVwLofDwR1t3Mu1J9QsVtFSUzpE0nPIxBsFZVpikpzuQY0x2+c06lkh1QF6 +12S4ZDnNye2v7UsDSKegmQGA3GWjNq5lWUhPgkvIZfFXHeVZLgo/bNjR9eUJtGxUAArgFU2HdW23 +WJZa3W3SAKD0m0i+wzekujbgfIeFlxoVot4uolu9rxj5kFDNcFn4J2dHy8egBzp90SxdbBk6ZrV9 +/ZFvgrG+CJPbFEfxojfHRZ48x3evZKiT3/Zpg4Jg8klCNO1aAFSFHBY2kgxc+qatv9s= +-----END CERTIFICATE----- + +AffirmTrust Premium +=================== +-----BEGIN CERTIFICATE----- +MIIFRjCCAy6gAwIBAgIIbYwURrGmCu4wDQYJKoZIhvcNAQEMBQAwQTELMAkGA1UEBhMCVVMxFDAS +BgNVBAoMC0FmZmlybVRydXN0MRwwGgYDVQQDDBNBZmZpcm1UcnVzdCBQcmVtaXVtMB4XDTEwMDEy +OTE0MTAzNloXDTQwMTIzMTE0MTAzNlowQTELMAkGA1UEBhMCVVMxFDASBgNVBAoMC0FmZmlybVRy +dXN0MRwwGgYDVQQDDBNBZmZpcm1UcnVzdCBQcmVtaXVtMIICIjANBgkqhkiG9w0BAQEFAAOCAg8A +MIICCgKCAgEAxBLfqV/+Qd3d9Z+K4/as4Tx4mrzY8H96oDMq3I0gW64tb+eT2TZwamjPjlGjhVtn +BKAQJG9dKILBl1fYSCkTtuG+kU3fhQxTGJoeJKJPj/CihQvL9Cl/0qRY7iZNyaqoe5rZ+jjeRFcV +5fiMyNlI4g0WJx0eyIOFJbe6qlVBzAMiSy2RjYvmia9mx+n/K+k8rNrSs8PhaJyJ+HoAVt70VZVs ++7pk3WKL3wt3MutizCaam7uqYoNMtAZ6MMgpv+0GTZe5HMQxK9VfvFMSF5yZVylmd2EhMQcuJUmd +GPLu8ytxjLW6OQdJd/zvLpKQBY0tL3d770O/Nbua2Plzpyzy0FfuKE4mX4+QaAkvuPjcBukumj5R +p9EixAqnOEhss/n/fauGV+O61oV4d7pD6kh/9ti+I20ev9E2bFhc8e6kGVQa9QPSdubhjL08s9NI +S+LI+H+SqHZGnEJlPqQewQcDWkYtuJfzt9WyVSHvutxMAJf7FJUnM7/oQ0dG0giZFmA7mn7S5u04 +6uwBHjxIVkkJx0w3AJ6IDsBz4W9m6XJHMD4Q5QsDyZpCAGzFlH5hxIrff4IaC1nEWTJ3s7xgaVY5 +/bQGeyzWZDbZvUjthB9+pSKPKrhC9IK31FOQeE4tGv2Bb0TXOwF0lkLgAOIua+rF7nKsu7/+6qqo ++Nz2snmKtmcCAwEAAaNCMEAwHQYDVR0OBBYEFJ3AZ6YMItkm9UWrpmVSESfYRaxjMA8GA1UdEwEB +/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMA0GCSqGSIb3DQEBDAUAA4ICAQCzV00QYk465KzquByv +MiPIs0laUZx2KI15qldGF9X1Uva3ROgIRL8YhNILgM3FEv0AVQVhh0HctSSePMTYyPtwni94loMg +Nt58D2kTiKV1NpgIpsbfrM7jWNa3Pt668+s0QNiigfV4Py/VpfzZotReBA4Xrf5B8OWycvpEgjNC +6C1Y91aMYj+6QrCcDFx+LmUmXFNPALJ4fqENmS2NuB2OosSw/WDQMKSOyARiqcTtNd56l+0OOF6S +L5Nwpamcb6d9Ex1+xghIsV5n61EIJenmJWtSKZGc0jlzCFfemQa0W50QBuHCAKi4HEoCChTQwUHK ++4w1IX2COPKpVJEZNZOUbWo6xbLQu4mGk+ibyQ86p3q4ofB4Rvr8Ny/lioTz3/4E2aFooC8k4gmV +BtWVyuEklut89pMFu+1z6S3RdTnX5yTb2E5fQ4+e0BQ5v1VwSJlXMbSc7kqYA5YwH2AG7hsj/oFg +IxpHYoWlzBk0gG+zrBrjn/B7SK3VAdlntqlyk+otZrWyuOQ9PLLvTIzq6we/qzWaVYa8GKa1qF60 +g2xraUDTn9zxw2lrueFtCfTxqlB2Cnp9ehehVZZCmTEJ3WARjQUwfuaORtGdFNrHF+QFlozEJLUb +zxQHskD4o55BhrwE0GuWyCqANP2/7waj3VjFhT0+j/6eKeC2uAloGRwYQw== +-----END CERTIFICATE----- + +AffirmTrust Premium ECC +======================= +-----BEGIN CERTIFICATE----- +MIIB/jCCAYWgAwIBAgIIdJclisc/elQwCgYIKoZIzj0EAwMwRTELMAkGA1UEBhMCVVMxFDASBgNV +BAoMC0FmZmlybVRydXN0MSAwHgYDVQQDDBdBZmZpcm1UcnVzdCBQcmVtaXVtIEVDQzAeFw0xMDAx +MjkxNDIwMjRaFw00MDEyMzExNDIwMjRaMEUxCzAJBgNVBAYTAlVTMRQwEgYDVQQKDAtBZmZpcm1U +cnVzdDEgMB4GA1UEAwwXQWZmaXJtVHJ1c3QgUHJlbWl1bSBFQ0MwdjAQBgcqhkjOPQIBBgUrgQQA +IgNiAAQNMF4bFZ0D0KF5Nbc6PJJ6yhUczWLznCZcBz3lVPqj1swS6vQUX+iOGasvLkjmrBhDeKzQ +N8O9ss0s5kfiGuZjuD0uL3jET9v0D6RoTFVya5UdThhClXjMNzyR4ptlKymjQjBAMB0GA1UdDgQW +BBSaryl6wBE1NSZRMADDav5A1a7WPDAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBBjAK +BggqhkjOPQQDAwNnADBkAjAXCfOHiFBar8jAQr9HX/VsaobgxCd05DhT1wV/GzTjxi+zygk8N53X +57hG8f2h4nECMEJZh0PUUd+60wkyWs6Iflc9nF9Ca/UHLbXwgpP5WW+uZPpY5Yse42O+tYHNbwKM +eQ== +-----END CERTIFICATE----- + +Certum Trusted Network CA +========================= +-----BEGIN CERTIFICATE----- +MIIDuzCCAqOgAwIBAgIDBETAMA0GCSqGSIb3DQEBBQUAMH4xCzAJBgNVBAYTAlBMMSIwIAYDVQQK +ExlVbml6ZXRvIFRlY2hub2xvZ2llcyBTLkEuMScwJQYDVQQLEx5DZXJ0dW0gQ2VydGlmaWNhdGlv +biBBdXRob3JpdHkxIjAgBgNVBAMTGUNlcnR1bSBUcnVzdGVkIE5ldHdvcmsgQ0EwHhcNMDgxMDIy +MTIwNzM3WhcNMjkxMjMxMTIwNzM3WjB+MQswCQYDVQQGEwJQTDEiMCAGA1UEChMZVW5pemV0byBU +ZWNobm9sb2dpZXMgUy5BLjEnMCUGA1UECxMeQ2VydHVtIENlcnRpZmljYXRpb24gQXV0aG9yaXR5 +MSIwIAYDVQQDExlDZXJ0dW0gVHJ1c3RlZCBOZXR3b3JrIENBMIIBIjANBgkqhkiG9w0BAQEFAAOC +AQ8AMIIBCgKCAQEA4/t9o3K6wvDJFIf1awFO4W5AB7ptJ11/91sts1rHUV+rpDKmYYe2bg+G0jAC +l/jXaVehGDldamR5xgFZrDwxSjh80gTSSyjoIF87B6LMTXPb865Px1bVWqeWifrzq2jUI4ZZJ88J +J7ysbnKDHDBy3+Ci6dLhdHUZvSqeexVUBBvXQzmtVSjF4hq79MDkrjhJM8x2hZ85RdKknvISjFH4 +fOQtf/WsX+sWn7Et0brMkUJ3TCXJkDhv2/DM+44el1k+1WBO5gUo7Ul5E0u6SNsv+XLTOcr+H9g0 +cvW0QM8xAcPs3hEtF10fuFDRXhmnad4HMyjKUJX5p1TLVIZQRan5SQIDAQABo0IwQDAPBgNVHRMB +Af8EBTADAQH/MB0GA1UdDgQWBBQIds3LB/8k9sXN7buQvOKEN0Z19zAOBgNVHQ8BAf8EBAMCAQYw +DQYJKoZIhvcNAQEFBQADggEBAKaorSLOAT2mo/9i0Eidi15ysHhE49wcrwn9I0j6vSrEuVUEtRCj +jSfeC4Jj0O7eDDd5QVsisrCaQVymcODU0HfLI9MA4GxWL+FpDQ3Zqr8hgVDZBqWo/5U30Kr+4rP1 +mS1FhIrlQgnXdAIv94nYmem8J9RHjboNRhx3zxSkHLmkMcScKHQDNP8zGSal6Q10tz6XxnboJ5aj +Zt3hrvJBW8qYVoNzcOSGGtIxQbovvi0TWnZvTuhOgQ4/WwMioBK+ZlgRSssDxLQqKi2WF+A5VLxI +03YnnZotBqbJ7DnSq9ufmgsnAjUpsUCV5/nonFWIGUbWtzT1fs45mtk48VH3Tyw= +-----END CERTIFICATE----- + +TWCA Root Certification Authority +================================= +-----BEGIN CERTIFICATE----- +MIIDezCCAmOgAwIBAgIBATANBgkqhkiG9w0BAQUFADBfMQswCQYDVQQGEwJUVzESMBAGA1UECgwJ +VEFJV0FOLUNBMRAwDgYDVQQLDAdSb290IENBMSowKAYDVQQDDCFUV0NBIFJvb3QgQ2VydGlmaWNh +dGlvbiBBdXRob3JpdHkwHhcNMDgwODI4MDcyNDMzWhcNMzAxMjMxMTU1OTU5WjBfMQswCQYDVQQG +EwJUVzESMBAGA1UECgwJVEFJV0FOLUNBMRAwDgYDVQQLDAdSb290IENBMSowKAYDVQQDDCFUV0NB +IFJvb3QgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEK +AoIBAQCwfnK4pAOU5qfeCTiRShFAh6d8WWQUe7UREN3+v9XAu1bihSX0NXIP+FPQQeFEAcK0HMMx +QhZHhTMidrIKbw/lJVBPhYa+v5guEGcevhEFhgWQxFnQfHgQsIBct+HHK3XLfJ+utdGdIzdjp9xC +oi2SBBtQwXu4PhvJVgSLL1KbralW6cH/ralYhzC2gfeXRfwZVzsrb+RH9JlF/h3x+JejiB03HFyP +4HYlmlD4oFT/RJB2I9IyxsOrBr/8+7/zrX2SYgJbKdM1o5OaQ2RgXbL6Mv87BK9NQGr5x+PvI/1r +y+UPizgN7gr8/g+YnzAx3WxSZfmLgb4i4RxYA7qRG4kHAgMBAAGjQjBAMA4GA1UdDwEB/wQEAwIB +BjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBRqOFsmjd6LWvJPelSDGRjjCDWmujANBgkqhkiG +9w0BAQUFAAOCAQEAPNV3PdrfibqHDAhUaiBQkr6wQT25JmSDCi/oQMCXKCeCMErJk/9q56YAf4lC +mtYR5VPOL8zy2gXE/uJQxDqGfczafhAJO5I1KlOy/usrBdlsXebQ79NqZp4VKIV66IIArB6nCWlW +QtNoURi+VJq/REG6Sb4gumlc7rh3zc5sH62Dlhh9DrUUOYTxKOkto557HnpyWoOzeW/vtPzQCqVY +T0bf+215WfKEIlKuD8z7fDvnaspHYcN6+NOSBB+4IIThNlQWx0DeO4pz3N/GCUzf7Nr/1FNCocny +Yh0igzyXxfkZYiesZSLX0zzG5Y6yU8xJzrww/nsOM5D77dIUkR8Hrw== +-----END CERTIFICATE----- + +Security Communication RootCA2 +============================== +-----BEGIN CERTIFICATE----- +MIIDdzCCAl+gAwIBAgIBADANBgkqhkiG9w0BAQsFADBdMQswCQYDVQQGEwJKUDElMCMGA1UEChMc +U0VDT00gVHJ1c3QgU3lzdGVtcyBDTy4sTFRELjEnMCUGA1UECxMeU2VjdXJpdHkgQ29tbXVuaWNh +dGlvbiBSb290Q0EyMB4XDTA5MDUyOTA1MDAzOVoXDTI5MDUyOTA1MDAzOVowXTELMAkGA1UEBhMC +SlAxJTAjBgNVBAoTHFNFQ09NIFRydXN0IFN5c3RlbXMgQ08uLExURC4xJzAlBgNVBAsTHlNlY3Vy +aXR5IENvbW11bmljYXRpb24gUm9vdENBMjCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB +ANAVOVKxUrO6xVmCxF1SrjpDZYBLx/KWvNs2l9amZIyoXvDjChz335c9S672XewhtUGrzbl+dp++ ++T42NKA7wfYxEUV0kz1XgMX5iZnK5atq1LXaQZAQwdbWQonCv/Q4EpVMVAX3NuRFg3sUZdbcDE3R +3n4MqzvEFb46VqZab3ZpUql6ucjrappdUtAtCms1FgkQhNBqyjoGADdH5H5XTz+L62e4iKrFvlNV +spHEfbmwhRkGeC7bYRr6hfVKkaHnFtWOojnflLhwHyg/i/xAXmODPIMqGplrz95Zajv8bxbXH/1K +EOtOghY6rCcMU/Gt1SSwawNQwS08Ft1ENCcadfsCAwEAAaNCMEAwHQYDVR0OBBYEFAqFqXdlBZh8 +QIH4D5csOPEK7DzPMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MA0GCSqGSIb3DQEB +CwUAA4IBAQBMOqNErLlFsceTfsgLCkLfZOoc7llsCLqJX2rKSpWeeo8HxdpFcoJxDjrSzG+ntKEj +u/Ykn8sX/oymzsLS28yN/HH8AynBbF0zX2S2ZTuJbxh2ePXcokgfGT+Ok+vx+hfuzU7jBBJV1uXk +3fs+BXziHV7Gp7yXT2g69ekuCkO2r1dcYmh8t/2jioSgrGK+KwmHNPBqAbubKVY8/gA3zyNs8U6q +tnRGEmyR7jTV7JqR50S+kDFy1UkC9gLl9B/rfNmWVan/7Ir5mUf/NVoCqgTLiluHcSmRvaS0eg29 +mvVXIwAHIRc/SjnRBUkLp7Y3gaVdjKozXoEofKd9J+sAro03 +-----END CERTIFICATE----- + +EC-ACC +====== +-----BEGIN CERTIFICATE----- +MIIFVjCCBD6gAwIBAgIQ7is969Qh3hSoYqwE893EATANBgkqhkiG9w0BAQUFADCB8zELMAkGA1UE +BhMCRVMxOzA5BgNVBAoTMkFnZW5jaWEgQ2F0YWxhbmEgZGUgQ2VydGlmaWNhY2lvIChOSUYgUS0w +ODAxMTc2LUkpMSgwJgYDVQQLEx9TZXJ2ZWlzIFB1YmxpY3MgZGUgQ2VydGlmaWNhY2lvMTUwMwYD +VQQLEyxWZWdldSBodHRwczovL3d3dy5jYXRjZXJ0Lm5ldC92ZXJhcnJlbCAoYykwMzE1MDMGA1UE +CxMsSmVyYXJxdWlhIEVudGl0YXRzIGRlIENlcnRpZmljYWNpbyBDYXRhbGFuZXMxDzANBgNVBAMT +BkVDLUFDQzAeFw0wMzAxMDcyMzAwMDBaFw0zMTAxMDcyMjU5NTlaMIHzMQswCQYDVQQGEwJFUzE7 +MDkGA1UEChMyQWdlbmNpYSBDYXRhbGFuYSBkZSBDZXJ0aWZpY2FjaW8gKE5JRiBRLTA4MDExNzYt +SSkxKDAmBgNVBAsTH1NlcnZlaXMgUHVibGljcyBkZSBDZXJ0aWZpY2FjaW8xNTAzBgNVBAsTLFZl +Z2V1IGh0dHBzOi8vd3d3LmNhdGNlcnQubmV0L3ZlcmFycmVsIChjKTAzMTUwMwYDVQQLEyxKZXJh +cnF1aWEgRW50aXRhdHMgZGUgQ2VydGlmaWNhY2lvIENhdGFsYW5lczEPMA0GA1UEAxMGRUMtQUND +MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAsyLHT+KXQpWIR4NA9h0X84NzJB5R85iK +w5K4/0CQBXCHYMkAqbWUZRkiFRfCQ2xmRJoNBD45b6VLeqpjt4pEndljkYRm4CgPukLjbo73FCeT +ae6RDqNfDrHrZqJyTxIThmV6PttPB/SnCWDaOkKZx7J/sxaVHMf5NLWUhdWZXqBIoH7nF2W4onW4 +HvPlQn2v7fOKSGRdghST2MDk/7NQcvJ29rNdQlB50JQ+awwAvthrDk4q7D7SzIKiGGUzE3eeml0a +E9jD2z3Il3rucO2n5nzbcc8tlGLfbdb1OL4/pYUKGbio2Al1QnDE6u/LDsg0qBIimAy4E5S2S+zw +0JDnJwIDAQABo4HjMIHgMB0GA1UdEQQWMBSBEmVjX2FjY0BjYXRjZXJ0Lm5ldDAPBgNVHRMBAf8E +BTADAQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUoMOLRKo3pUW/l4Ba0fF4opvpXY0wfwYD +VR0gBHgwdjB0BgsrBgEEAfV4AQMBCjBlMCwGCCsGAQUFBwIBFiBodHRwczovL3d3dy5jYXRjZXJ0 +Lm5ldC92ZXJhcnJlbDA1BggrBgEFBQcCAjApGidWZWdldSBodHRwczovL3d3dy5jYXRjZXJ0Lm5l +dC92ZXJhcnJlbCAwDQYJKoZIhvcNAQEFBQADggEBAKBIW4IB9k1IuDlVNZyAelOZ1Vr/sXE7zDkJ +lF7W2u++AVtd0x7Y/X1PzaBB4DSTv8vihpw3kpBWHNzrKQXlxJ7HNd+KDM3FIUPpqojlNcAZQmNa +Al6kSBg6hW/cnbw/nZzBh7h6YQjpdwt/cKt63dmXLGQehb+8dJahw3oS7AwaboMMPOhyRp/7SNVe +l+axofjk70YllJyJ22k4vuxcDlbHZVHlUIiIv0LVKz3l+bqeLrPK9HOSAgu+TGbrIP65y7WZf+a2 +E/rKS03Z7lNGBjvGTq2TWoF+bCpLagVFjPIhpDGQh2xlnJ2lYJU6Un/10asIbvPuW/mIPX64b24D +5EI= +-----END CERTIFICATE----- + +Hellenic Academic and Research Institutions RootCA 2011 +======================================================= +-----BEGIN CERTIFICATE----- +MIIEMTCCAxmgAwIBAgIBADANBgkqhkiG9w0BAQUFADCBlTELMAkGA1UEBhMCR1IxRDBCBgNVBAoT +O0hlbGxlbmljIEFjYWRlbWljIGFuZCBSZXNlYXJjaCBJbnN0aXR1dGlvbnMgQ2VydC4gQXV0aG9y +aXR5MUAwPgYDVQQDEzdIZWxsZW5pYyBBY2FkZW1pYyBhbmQgUmVzZWFyY2ggSW5zdGl0dXRpb25z +IFJvb3RDQSAyMDExMB4XDTExMTIwNjEzNDk1MloXDTMxMTIwMTEzNDk1MlowgZUxCzAJBgNVBAYT +AkdSMUQwQgYDVQQKEztIZWxsZW5pYyBBY2FkZW1pYyBhbmQgUmVzZWFyY2ggSW5zdGl0dXRpb25z +IENlcnQuIEF1dGhvcml0eTFAMD4GA1UEAxM3SGVsbGVuaWMgQWNhZGVtaWMgYW5kIFJlc2VhcmNo +IEluc3RpdHV0aW9ucyBSb290Q0EgMjAxMTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEB +AKlTAOMupvaO+mDYLZU++CwqVE7NuYRhlFhPjz2L5EPzdYmNUeTDN9KKiE15HrcS3UN4SoqS5tdI +1Q+kOilENbgH9mgdVc04UfCMJDGFr4PJfel3r+0ae50X+bOdOFAPplp5kYCvN66m0zH7tSYJnTxa +71HFK9+WXesyHgLacEnsbgzImjeN9/E2YEsmLIKe0HjzDQ9jpFEw4fkrJxIH2Oq9GGKYsFk3fb7u +8yBRQlqD75O6aRXxYp2fmTmCobd0LovUxQt7L/DICto9eQqakxylKHJzkUOap9FNhYS5qXSPFEDH +3N6sQWRstBmbAmNtJGSPRLIl6s5ddAxjMlyNh+UCAwEAAaOBiTCBhjAPBgNVHRMBAf8EBTADAQH/ +MAsGA1UdDwQEAwIBBjAdBgNVHQ4EFgQUppFC/RNhSiOeCKQp5dgTBCPuQSUwRwYDVR0eBEAwPqA8 +MAWCAy5ncjAFggMuZXUwBoIELmVkdTAGggQub3JnMAWBAy5ncjAFgQMuZXUwBoEELmVkdTAGgQQu +b3JnMA0GCSqGSIb3DQEBBQUAA4IBAQAf73lB4XtuP7KMhjdCSk4cNx6NZrokgclPEg8hwAOXhiVt +XdMiKahsog2p6z0GW5k6x8zDmjR/qw7IThzh+uTczQ2+vyT+bOdrwg3IBp5OjWEopmr95fZi6hg8 +TqBTnbI6nOulnJEWtk2C4AwFSKls9cz4y51JtPACpf1wA+2KIaWuE4ZJwzNzvoc7dIsXRSZMFpGD +/md9zU1jZ/rzAxKWeAaNsWftjj++n08C9bMJL/NMh98qy5V8AcysNnq/onN694/BtZqhFLKPM58N +7yLcZnuEvUUXBj08yrl3NI/K6s8/MT7jiOOASSXIl7WdmplNsDz4SgCbZN2fOUvRJ9e4 +-----END CERTIFICATE----- + +Actalis Authentication Root CA +============================== +-----BEGIN CERTIFICATE----- +MIIFuzCCA6OgAwIBAgIIVwoRl0LE48wwDQYJKoZIhvcNAQELBQAwazELMAkGA1UEBhMCSVQxDjAM +BgNVBAcMBU1pbGFuMSMwIQYDVQQKDBpBY3RhbGlzIFMucC5BLi8wMzM1ODUyMDk2NzEnMCUGA1UE +AwweQWN0YWxpcyBBdXRoZW50aWNhdGlvbiBSb290IENBMB4XDTExMDkyMjExMjIwMloXDTMwMDky +MjExMjIwMlowazELMAkGA1UEBhMCSVQxDjAMBgNVBAcMBU1pbGFuMSMwIQYDVQQKDBpBY3RhbGlz +IFMucC5BLi8wMzM1ODUyMDk2NzEnMCUGA1UEAwweQWN0YWxpcyBBdXRoZW50aWNhdGlvbiBSb290 +IENBMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAp8bEpSmkLO/lGMWwUKNvUTufClrJ +wkg4CsIcoBh/kbWHuUA/3R1oHwiD1S0eiKD4j1aPbZkCkpAW1V8IbInX4ay8IMKx4INRimlNAJZa +by/ARH6jDuSRzVju3PvHHkVH3Se5CAGfpiEd9UEtL0z9KK3giq0itFZljoZUj5NDKd45RnijMCO6 +zfB9E1fAXdKDa0hMxKufgFpbOr3JpyI/gCczWw63igxdBzcIy2zSekciRDXFzMwujt0q7bd9Zg1f +YVEiVRvjRuPjPdA1YprbrxTIW6HMiRvhMCb8oJsfgadHHwTrozmSBp+Z07/T6k9QnBn+locePGX2 +oxgkg4YQ51Q+qDp2JE+BIcXjDwL4k5RHILv+1A7TaLndxHqEguNTVHnd25zS8gebLra8Pu2Fbe8l +EfKXGkJh90qX6IuxEAf6ZYGyojnP9zz/GPvG8VqLWeICrHuS0E4UT1lF9gxeKF+w6D9Fz8+vm2/7 +hNN3WpVvrJSEnu68wEqPSpP4RCHiMUVhUE4Q2OM1fEwZtN4Fv6MGn8i1zeQf1xcGDXqVdFUNaBr8 +EBtiZJ1t4JWgw5QHVw0U5r0F+7if5t+L4sbnfpb2U8WANFAoWPASUHEXMLrmeGO89LKtmyuy/uE5 +jF66CyCU3nuDuP/jVo23Eek7jPKxwV2dpAtMK9myGPW1n0sCAwEAAaNjMGEwHQYDVR0OBBYEFFLY +iDrIn3hm7YnzezhwlMkCAjbQMA8GA1UdEwEB/wQFMAMBAf8wHwYDVR0jBBgwFoAUUtiIOsifeGbt +ifN7OHCUyQICNtAwDgYDVR0PAQH/BAQDAgEGMA0GCSqGSIb3DQEBCwUAA4ICAQALe3KHwGCmSUyI +WOYdiPcUZEim2FgKDk8TNd81HdTtBjHIgT5q1d07GjLukD0R0i70jsNjLiNmsGe+b7bAEzlgqqI0 +JZN1Ut6nna0Oh4lScWoWPBkdg/iaKWW+9D+a2fDzWochcYBNy+A4mz+7+uAwTc+G02UQGRjRlwKx +K3JCaKygvU5a2hi/a5iB0P2avl4VSM0RFbnAKVy06Ij3Pjaut2L9HmLecHgQHEhb2rykOLpn7VU+ +Xlff1ANATIGk0k9jpwlCCRT8AKnCgHNPLsBA2RF7SOp6AsDT6ygBJlh0wcBzIm2Tlf05fbsq4/aC +4yyXX04fkZT6/iyj2HYauE2yOE+b+h1IYHkm4vP9qdCa6HCPSXrW5b0KDtst842/6+OkfcvHlXHo +2qN8xcL4dJIEG4aspCJTQLas/kx2z/uUMsA1n3Y/buWQbqCmJqK4LL7RK4X9p2jIugErsWx0Hbhz +lefut8cl8ABMALJ+tguLHPPAUJ4lueAI3jZm/zel0btUZCzJJ7VLkn5l/9Mt4blOvH+kQSGQQXem +OR/qnuOf0GZvBeyqdn6/axag67XH/JJULysRJyU3eExRarDzzFhdFPFqSBX/wge2sY0PjlxQRrM9 +vwGYT7JZVEc+NHt4bVaTLnPqZih4zR0Uv6CPLy64Lo7yFIrM6bV8+2ydDKXhlg== +-----END CERTIFICATE----- + +Trustis FPS Root CA +=================== +-----BEGIN CERTIFICATE----- +MIIDZzCCAk+gAwIBAgIQGx+ttiD5JNM2a/fH8YygWTANBgkqhkiG9w0BAQUFADBFMQswCQYDVQQG +EwJHQjEYMBYGA1UEChMPVHJ1c3RpcyBMaW1pdGVkMRwwGgYDVQQLExNUcnVzdGlzIEZQUyBSb290 +IENBMB4XDTAzMTIyMzEyMTQwNloXDTI0MDEyMTExMzY1NFowRTELMAkGA1UEBhMCR0IxGDAWBgNV +BAoTD1RydXN0aXMgTGltaXRlZDEcMBoGA1UECxMTVHJ1c3RpcyBGUFMgUm9vdCBDQTCCASIwDQYJ +KoZIhvcNAQEBBQADggEPADCCAQoCggEBAMVQe547NdDfxIzNjpvto8A2mfRC6qc+gIMPpqdZh8mQ +RUN+AOqGeSoDvT03mYlmt+WKVoaTnGhLaASMk5MCPjDSNzoiYYkchU59j9WvezX2fihHiTHcDnlk +H5nSW7r+f2C/revnPDgpai/lkQtV/+xvWNUtyd5MZnGPDNcE2gfmHhjjvSkCqPoc4Vu5g6hBSLwa +cY3nYuUtsuvffM/bq1rKMfFMIvMFE/eC+XN5DL7XSxzA0RU8k0Fk0ea+IxciAIleH2ulrG6nS4zt +o3Lmr2NNL4XSFDWaLk6M6jKYKIahkQlBOrTh4/L68MkKokHdqeMDx4gVOxzUGpTXn2RZEm0CAwEA +AaNTMFEwDwYDVR0TAQH/BAUwAwEB/zAfBgNVHSMEGDAWgBS6+nEleYtXQSUhhgtx67JkDoshZzAd +BgNVHQ4EFgQUuvpxJXmLV0ElIYYLceuyZA6LIWcwDQYJKoZIhvcNAQEFBQADggEBAH5Y//01GX2c +GE+esCu8jowU/yyg2kdbw++BLa8F6nRIW/M+TgfHbcWzk88iNVy2P3UnXwmWzaD+vkAMXBJV+JOC +yinpXj9WV4s4NvdFGkwozZ5BuO1WTISkQMi4sKUraXAEasP41BIy+Q7DsdwyhEQsb8tGD+pmQQ9P +8Vilpg0ND2HepZ5dfWWhPBfnqFVO76DH7cZEf1T1o+CP8HxVIo8ptoGj4W1OLBuAZ+ytIJ8MYmHV +l/9D7S3B2l0pKoU/rGXuhg8FjZBf3+6f9L/uHfuY5H+QK4R4EA5sSVPvFVtlRkpdr7r7OnIdzfYl +iB6XzCGcKQENZetX2fNXlrtIzYE= +-----END CERTIFICATE----- + +Buypass Class 2 Root CA +======================= +-----BEGIN CERTIFICATE----- +MIIFWTCCA0GgAwIBAgIBAjANBgkqhkiG9w0BAQsFADBOMQswCQYDVQQGEwJOTzEdMBsGA1UECgwU +QnV5cGFzcyBBUy05ODMxNjMzMjcxIDAeBgNVBAMMF0J1eXBhc3MgQ2xhc3MgMiBSb290IENBMB4X +DTEwMTAyNjA4MzgwM1oXDTQwMTAyNjA4MzgwM1owTjELMAkGA1UEBhMCTk8xHTAbBgNVBAoMFEJ1 +eXBhc3MgQVMtOTgzMTYzMzI3MSAwHgYDVQQDDBdCdXlwYXNzIENsYXNzIDIgUm9vdCBDQTCCAiIw +DQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBANfHXvfBB9R3+0Mh9PT1aeTuMgHbo4Yf5FkNuud1 +g1Lr6hxhFUi7HQfKjK6w3Jad6sNgkoaCKHOcVgb/S2TwDCo3SbXlzwx87vFKu3MwZfPVL4O2fuPn +9Z6rYPnT8Z2SdIrkHJasW4DptfQxh6NR/Md+oW+OU3fUl8FVM5I+GC911K2GScuVr1QGbNgGE41b +/+EmGVnAJLqBcXmQRFBoJJRfuLMR8SlBYaNByyM21cHxMlAQTn/0hpPshNOOvEu/XAFOBz3cFIqU +CqTqc/sLUegTBxj6DvEr0VQVfTzh97QZQmdiXnfgolXsttlpF9U6r0TtSsWe5HonfOV116rLJeff +awrbD02TTqigzXsu8lkBarcNuAeBfos4GzjmCleZPe4h6KP1DBbdi+w0jpwqHAAVF41og9JwnxgI +zRFo1clrUs3ERo/ctfPYV3Me6ZQ5BL/T3jjetFPsaRyifsSP5BtwrfKi+fv3FmRmaZ9JUaLiFRhn +Bkp/1Wy1TbMz4GHrXb7pmA8y1x1LPC5aAVKRCfLf6o3YBkBjqhHk/sM3nhRSP/TizPJhk9H9Z2vX +Uq6/aKtAQ6BXNVN48FP4YUIHZMbXb5tMOA1jrGKvNouicwoN9SG9dKpN6nIDSdvHXx1iY8f93ZHs +M+71bbRuMGjeyNYmsHVee7QHIJihdjK4TWxPAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wHQYD +VR0OBBYEFMmAd+BikoL1RpzzuvdMw964o605MA4GA1UdDwEB/wQEAwIBBjANBgkqhkiG9w0BAQsF +AAOCAgEAU18h9bqwOlI5LJKwbADJ784g7wbylp7ppHR/ehb8t/W2+xUbP6umwHJdELFx7rxP462s +A20ucS6vxOOto70MEae0/0qyexAQH6dXQbLArvQsWdZHEIjzIVEpMMpghq9Gqx3tOluwlN5E40EI +osHsHdb9T7bWR9AUC8rmyrV7d35BH16Dx7aMOZawP5aBQW9gkOLo+fsicdl9sz1Gv7SEr5AcD48S +aq/v7h56rgJKihcrdv6sVIkkLE8/trKnToyokZf7KcZ7XC25y2a2t6hbElGFtQl+Ynhw/qlqYLYd +DnkM/crqJIByw5c/8nerQyIKx+u2DISCLIBrQYoIwOula9+ZEsuK1V6ADJHgJgg2SMX6OBE1/yWD +LfJ6v9r9jv6ly0UsH8SIU653DtmadsWOLB2jutXsMq7Aqqz30XpN69QH4kj3Io6wpJ9qzo6ysmD0 +oyLQI+uUWnpp3Q+/QFesa1lQ2aOZ4W7+jQF5JyMV3pKdewlNWudLSDBaGOYKbeaP4NK75t98biGC +wWg5TbSYWGZizEqQXsP6JwSxeRV0mcy+rSDeJmAc61ZRpqPq5KM/p/9h3PFaTWwyI0PurKju7koS +CTxdccK+efrCh2gdC/1cacwG0Jp9VJkqyTkaGa9LKkPzY11aWOIv4x3kqdbQCtCev9eBCfHJxyYN +rJgWVqA= +-----END CERTIFICATE----- + +Buypass Class 3 Root CA +======================= +-----BEGIN CERTIFICATE----- +MIIFWTCCA0GgAwIBAgIBAjANBgkqhkiG9w0BAQsFADBOMQswCQYDVQQGEwJOTzEdMBsGA1UECgwU +QnV5cGFzcyBBUy05ODMxNjMzMjcxIDAeBgNVBAMMF0J1eXBhc3MgQ2xhc3MgMyBSb290IENBMB4X +DTEwMTAyNjA4Mjg1OFoXDTQwMTAyNjA4Mjg1OFowTjELMAkGA1UEBhMCTk8xHTAbBgNVBAoMFEJ1 +eXBhc3MgQVMtOTgzMTYzMzI3MSAwHgYDVQQDDBdCdXlwYXNzIENsYXNzIDMgUm9vdCBDQTCCAiIw +DQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAKXaCpUWUOOV8l6ddjEGMnqb8RB2uACatVI2zSRH +sJ8YZLya9vrVediQYkwiL944PdbgqOkcLNt4EemOaFEVcsfzM4fkoF0LXOBXByow9c3EN3coTRiR +5r/VUv1xLXA+58bEiuPwKAv0dpihi4dVsjoT/Lc+JzeOIuOoTyrvYLs9tznDDgFHmV0ST9tD+leh +7fmdvhFHJlsTmKtdFoqwNxxXnUX/iJY2v7vKB3tvh2PX0DJq1l1sDPGzbjniazEuOQAnFN44wOwZ +ZoYS6J1yFhNkUsepNxz9gjDthBgd9K5c/3ATAOux9TN6S9ZV+AWNS2mw9bMoNlwUxFFzTWsL8TQH +2xc519woe2v1n/MuwU8XKhDzzMro6/1rqy6any2CbgTUUgGTLT2G/H783+9CHaZr77kgxve9oKeV +/afmiSTYzIw0bOIjL9kSGiG5VZFvC5F5GQytQIgLcOJ60g7YaEi7ghM5EFjp2CoHxhLbWNvSO1UQ +RwUVZ2J+GGOmRj8JDlQyXr8NYnon74Do29lLBlo3WiXQCBJ31G8JUJc9yB3D34xFMFbG02SrZvPA +Xpacw8Tvw3xrizp5f7NJzz3iiZ+gMEuFuZyUJHmPfWupRWgPK9Dx2hzLabjKSWJtyNBjYt1gD1iq +j6G8BaVmos8bdrKEZLFMOVLAMLrwjEsCsLa3AgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wHQYD +VR0OBBYEFEe4zf/lb+74suwvTg75JbCOPGvDMA4GA1UdDwEB/wQEAwIBBjANBgkqhkiG9w0BAQsF +AAOCAgEAACAjQTUEkMJAYmDv4jVM1z+s4jSQuKFvdvoWFqRINyzpkMLyPPgKn9iB5btb2iUspKdV +cSQy9sgL8rxq+JOssgfCX5/bzMiKqr5qb+FJEMwx14C7u8jYog5kV+qi9cKpMRXSIGrs/CIBKM+G +uIAeqcwRpTzyFrNHnfzSgCHEy9BHcEGhyoMZCCxt8l13nIoUE9Q2HJLw5QY33KbmkJs4j1xrG0aG +Q0JfPgEHU1RdZX33inOhmlRaHylDFCfChQ+1iHsaO5S3HWCntZznKWlXWpuTekMwGwPXYshApqr8 +ZORK15FTAaggiG6cX0S5y2CBNOxv033aSF/rtJC8LakcC6wc1aJoIIAE1vyxjy+7SjENSoYc6+I2 +KSb12tjE8nVhz36udmNKekBlk4f4HoCMhuWG1o8O/FMsYOgWYRqiPkN7zTlgVGr18okmAWiDSKIz +6MkEkbIRNBE+6tBDGR8Dk5AM/1E9V/RBbuHLoL7ryWPNbczk+DaqaJ3tvV2XcEQNtg413OEMXbug +UZTLfhbrES+jkkXITHHZvMmZUldGL1DPvTVp9D0VzgalLA8+9oG6lLvDu79leNKGef9JOxqDDPDe +eOzI8k1MGt6CKfjBWtrt7uYnXuhF0J0cUahoq0Tj0Itq4/g7u9xN12TyUb7mqqta6THuBrxzvxNi +Cp/HuZc= +-----END CERTIFICATE----- + +T-TeleSec GlobalRoot Class 3 +============================ +-----BEGIN CERTIFICATE----- +MIIDwzCCAqugAwIBAgIBATANBgkqhkiG9w0BAQsFADCBgjELMAkGA1UEBhMCREUxKzApBgNVBAoM +IlQtU3lzdGVtcyBFbnRlcnByaXNlIFNlcnZpY2VzIEdtYkgxHzAdBgNVBAsMFlQtU3lzdGVtcyBU +cnVzdCBDZW50ZXIxJTAjBgNVBAMMHFQtVGVsZVNlYyBHbG9iYWxSb290IENsYXNzIDMwHhcNMDgx +MDAxMTAyOTU2WhcNMzMxMDAxMjM1OTU5WjCBgjELMAkGA1UEBhMCREUxKzApBgNVBAoMIlQtU3lz +dGVtcyBFbnRlcnByaXNlIFNlcnZpY2VzIEdtYkgxHzAdBgNVBAsMFlQtU3lzdGVtcyBUcnVzdCBD +ZW50ZXIxJTAjBgNVBAMMHFQtVGVsZVNlYyBHbG9iYWxSb290IENsYXNzIDMwggEiMA0GCSqGSIb3 +DQEBAQUAA4IBDwAwggEKAoIBAQC9dZPwYiJvJK7genasfb3ZJNW4t/zN8ELg63iIVl6bmlQdTQyK +9tPPcPRStdiTBONGhnFBSivwKixVA9ZIw+A5OO3yXDw/RLyTPWGrTs0NvvAgJ1gORH8EGoel15YU +NpDQSXuhdfsaa3Ox+M6pCSzyU9XDFES4hqX2iys52qMzVNn6chr3IhUciJFrf2blw2qAsCTz34ZF +iP0Zf3WHHx+xGwpzJFu5ZeAsVMhg02YXP+HMVDNzkQI6pn97djmiH5a2OK61yJN0HZ65tOVgnS9W +0eDrXltMEnAMbEQgqxHY9Bn20pxSN+f6tsIxO0rUFJmtxxr1XV/6B7h8DR/Wgx6zAgMBAAGjQjBA +MA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBS1A/d2O2GCahKqGFPr +AyGUv/7OyjANBgkqhkiG9w0BAQsFAAOCAQEAVj3vlNW92nOyWL6ukK2YJ5f+AbGwUgC4TeQbIXQb +fsDuXmkqJa9c1h3a0nnJ85cp4IaH3gRZD/FZ1GSFS5mvJQQeyUapl96Cshtwn5z2r3Ex3XsFpSzT +ucpH9sry9uetuUg/vBa3wW306gmv7PO15wWeph6KU1HWk4HMdJP2udqmJQV0eVp+QD6CSyYRMG7h +P0HHRwA11fXT91Q+gT3aSWqas+8QPebrb9HIIkfLzM8BMZLZGOMivgkeGj5asuRrDFR6fUNOuIml +e9eiPZaGzPImNC1qkp2aGtAw4l1OBLBfiyB+d8E9lYLRRpo7PHi4b6HQDWSieB4pTpPDpFQUWw== +-----END CERTIFICATE----- + +EE Certification Centre Root CA +=============================== +-----BEGIN CERTIFICATE----- +MIIEAzCCAuugAwIBAgIQVID5oHPtPwBMyonY43HmSjANBgkqhkiG9w0BAQUFADB1MQswCQYDVQQG +EwJFRTEiMCAGA1UECgwZQVMgU2VydGlmaXRzZWVyaW1pc2tlc2t1czEoMCYGA1UEAwwfRUUgQ2Vy +dGlmaWNhdGlvbiBDZW50cmUgUm9vdCBDQTEYMBYGCSqGSIb3DQEJARYJcGtpQHNrLmVlMCIYDzIw +MTAxMDMwMTAxMDMwWhgPMjAzMDEyMTcyMzU5NTlaMHUxCzAJBgNVBAYTAkVFMSIwIAYDVQQKDBlB +UyBTZXJ0aWZpdHNlZXJpbWlza2Vza3VzMSgwJgYDVQQDDB9FRSBDZXJ0aWZpY2F0aW9uIENlbnRy +ZSBSb290IENBMRgwFgYJKoZIhvcNAQkBFglwa2lAc2suZWUwggEiMA0GCSqGSIb3DQEBAQUAA4IB +DwAwggEKAoIBAQDIIMDs4MVLqwd4lfNE7vsLDP90jmG7sWLqI9iroWUyeuuOF0+W2Ap7kaJjbMeM +TC55v6kF/GlclY1i+blw7cNRfdCT5mzrMEvhvH2/UpvObntl8jixwKIy72KyaOBhU8E2lf/slLo2 +rpwcpzIP5Xy0xm90/XsY6KxX7QYgSzIwWFv9zajmofxwvI6Sc9uXp3whrj3B9UiHbCe9nyV0gVWw +93X2PaRka9ZP585ArQ/dMtO8ihJTmMmJ+xAdTX7Nfh9WDSFwhfYggx/2uh8Ej+p3iDXE/+pOoYtN +P2MbRMNE1CV2yreN1x5KZmTNXMWcg+HCCIia7E6j8T4cLNlsHaFLAgMBAAGjgYowgYcwDwYDVR0T +AQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFBLyWj7qVhy/zQas8fElyalL1BSZ +MEUGA1UdJQQ+MDwGCCsGAQUFBwMCBggrBgEFBQcDAQYIKwYBBQUHAwMGCCsGAQUFBwMEBggrBgEF +BQcDCAYIKwYBBQUHAwkwDQYJKoZIhvcNAQEFBQADggEBAHv25MANqhlHt01Xo/6tu7Fq1Q+e2+Rj +xY6hUFaTlrg4wCQiZrxTFGGVv9DHKpY5P30osxBAIWrEr7BSdxjhlthWXePdNl4dp1BUoMUq5KqM +lIpPnTX/dqQGE5Gion0ARD9V04I8GtVbvFZMIi5GQ4okQC3zErg7cBqklrkar4dBGmoYDQZPxz5u +uSlNDUmJEYcyW+ZLBMjkXOZ0c5RdFpgTlf7727FE5TpwrDdr5rMzcijJs1eg9gIWiAYLtqZLICjU +3j2LrTcFU3T+bsy8QxdxXvnFzBqpYe73dgzzcvRyrc9yAjYHR8/vGVCJYMzpJJUPwssd8m92kMfM +dcGWxZ0= +-----END CERTIFICATE----- + +D-TRUST Root Class 3 CA 2 2009 +============================== +-----BEGIN CERTIFICATE----- +MIIEMzCCAxugAwIBAgIDCYPzMA0GCSqGSIb3DQEBCwUAME0xCzAJBgNVBAYTAkRFMRUwEwYDVQQK +DAxELVRydXN0IEdtYkgxJzAlBgNVBAMMHkQtVFJVU1QgUm9vdCBDbGFzcyAzIENBIDIgMjAwOTAe +Fw0wOTExMDUwODM1NThaFw0yOTExMDUwODM1NThaME0xCzAJBgNVBAYTAkRFMRUwEwYDVQQKDAxE +LVRydXN0IEdtYkgxJzAlBgNVBAMMHkQtVFJVU1QgUm9vdCBDbGFzcyAzIENBIDIgMjAwOTCCASIw +DQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBANOySs96R+91myP6Oi/WUEWJNTrGa9v+2wBoqOAD +ER03UAifTUpolDWzU9GUY6cgVq/eUXjsKj3zSEhQPgrfRlWLJ23DEE0NkVJD2IfgXU42tSHKXzlA +BF9bfsyjxiupQB7ZNoTWSPOSHjRGICTBpFGOShrvUD9pXRl/RcPHAY9RySPocq60vFYJfxLLHLGv +KZAKyVXMD9O0Gu1HNVpK7ZxzBCHQqr0ME7UAyiZsxGsMlFqVlNpQmvH/pStmMaTJOKDfHR+4CS7z +p+hnUquVH+BGPtikw8paxTGA6Eian5Rp/hnd2HN8gcqW3o7tszIFZYQ05ub9VxC1X3a/L7AQDcUC +AwEAAaOCARowggEWMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFP3aFMSfMN4hvR5COfyrYyNJ +4PGEMA4GA1UdDwEB/wQEAwIBBjCB0wYDVR0fBIHLMIHIMIGAoH6gfIZ6bGRhcDovL2RpcmVjdG9y +eS5kLXRydXN0Lm5ldC9DTj1ELVRSVVNUJTIwUm9vdCUyMENsYXNzJTIwMyUyMENBJTIwMiUyMDIw +MDksTz1ELVRydXN0JTIwR21iSCxDPURFP2NlcnRpZmljYXRlcmV2b2NhdGlvbmxpc3QwQ6BBoD+G +PWh0dHA6Ly93d3cuZC10cnVzdC5uZXQvY3JsL2QtdHJ1c3Rfcm9vdF9jbGFzc18zX2NhXzJfMjAw +OS5jcmwwDQYJKoZIhvcNAQELBQADggEBAH+X2zDI36ScfSF6gHDOFBJpiBSVYEQBrLLpME+bUMJm +2H6NMLVwMeniacfzcNsgFYbQDfC+rAF1hM5+n02/t2A7nPPKHeJeaNijnZflQGDSNiH+0LS4F9p0 +o3/U37CYAqxva2ssJSRyoWXuJVrl5jLn8t+rSfrzkGkj2wTZ51xY/GXUl77M/C4KzCUqNQT4YJEV +dT1B/yMfGchs64JTBKbkTCJNjYy6zltz7GRUUG3RnFX7acM2w4y8PIWmawomDeCTmGCufsYkl4ph +X5GOZpIJhzbNi5stPvZR1FDUWSi9g/LMKHtThm3YJohw1+qRzT65ysCQblrGXnRl11z+o+I= +-----END CERTIFICATE----- + +D-TRUST Root Class 3 CA 2 EV 2009 +================================= +-----BEGIN CERTIFICATE----- +MIIEQzCCAyugAwIBAgIDCYP0MA0GCSqGSIb3DQEBCwUAMFAxCzAJBgNVBAYTAkRFMRUwEwYDVQQK +DAxELVRydXN0IEdtYkgxKjAoBgNVBAMMIUQtVFJVU1QgUm9vdCBDbGFzcyAzIENBIDIgRVYgMjAw +OTAeFw0wOTExMDUwODUwNDZaFw0yOTExMDUwODUwNDZaMFAxCzAJBgNVBAYTAkRFMRUwEwYDVQQK +DAxELVRydXN0IEdtYkgxKjAoBgNVBAMMIUQtVFJVU1QgUm9vdCBDbGFzcyAzIENBIDIgRVYgMjAw +OTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAJnxhDRwui+3MKCOvXwEz75ivJn9gpfS +egpnljgJ9hBOlSJzmY3aFS3nBfwZcyK3jpgAvDw9rKFs+9Z5JUut8Mxk2og+KbgPCdM03TP1YtHh +zRnp7hhPTFiu4h7WDFsVWtg6uMQYZB7jM7K1iXdODL/ZlGsTl28So/6ZqQTMFexgaDbtCHu39b+T +7WYxg4zGcTSHThfqr4uRjRxWQa4iN1438h3Z0S0NL2lRp75mpoo6Kr3HGrHhFPC+Oh25z1uxav60 +sUYgovseO3Dvk5h9jHOW8sXvhXCtKSb8HgQ+HKDYD8tSg2J87otTlZCpV6LqYQXY+U3EJ/pure35 +11H3a6UCAwEAAaOCASQwggEgMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFNOUikxiEyoZLsyv +cop9NteaHNxnMA4GA1UdDwEB/wQEAwIBBjCB3QYDVR0fBIHVMIHSMIGHoIGEoIGBhn9sZGFwOi8v +ZGlyZWN0b3J5LmQtdHJ1c3QubmV0L0NOPUQtVFJVU1QlMjBSb290JTIwQ2xhc3MlMjAzJTIwQ0El +MjAyJTIwRVYlMjAyMDA5LE89RC1UcnVzdCUyMEdtYkgsQz1ERT9jZXJ0aWZpY2F0ZXJldm9jYXRp +b25saXN0MEagRKBChkBodHRwOi8vd3d3LmQtdHJ1c3QubmV0L2NybC9kLXRydXN0X3Jvb3RfY2xh +c3NfM19jYV8yX2V2XzIwMDkuY3JsMA0GCSqGSIb3DQEBCwUAA4IBAQA07XtaPKSUiO8aEXUHL7P+ +PPoeUSbrh/Yp3uDx1MYkCenBz1UbtDDZzhr+BlGmFaQt77JLvyAoJUnRpjZ3NOhk31KxEcdzes05 +nsKtjHEh8lprr988TlWvsoRlFIm5d8sqMb7Po23Pb0iUMkZv53GMoKaEGTcH8gNFCSuGdXzfX2lX +ANtu2KZyIktQ1HWYVt+3GP9DQ1CuekR78HlR10M9p9OB0/DJT7naxpeG0ILD5EJt/rDiZE4OJudA +NCa1CInXCGNjOCd1HjPqbqjdn5lPdE2BiYBL3ZqXKVwvvoFBuYz/6n1gBp7N1z3TLqMVvKjmJuVv +w9y4AyHqnxbxLFS1 +-----END CERTIFICATE----- + +CA Disig Root R2 +================ +-----BEGIN CERTIFICATE----- +MIIFaTCCA1GgAwIBAgIJAJK4iNuwisFjMA0GCSqGSIb3DQEBCwUAMFIxCzAJBgNVBAYTAlNLMRMw +EQYDVQQHEwpCcmF0aXNsYXZhMRMwEQYDVQQKEwpEaXNpZyBhLnMuMRkwFwYDVQQDExBDQSBEaXNp +ZyBSb290IFIyMB4XDTEyMDcxOTA5MTUzMFoXDTQyMDcxOTA5MTUzMFowUjELMAkGA1UEBhMCU0sx +EzARBgNVBAcTCkJyYXRpc2xhdmExEzARBgNVBAoTCkRpc2lnIGEucy4xGTAXBgNVBAMTEENBIERp +c2lnIFJvb3QgUjIwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCio8QACdaFXS1tFPbC +w3OeNcJxVX6B+6tGUODBfEl45qt5WDza/3wcn9iXAng+a0EE6UG9vgMsRfYvZNSrXaNHPWSb6Wia +xswbP7q+sos0Ai6YVRn8jG+qX9pMzk0DIaPY0jSTVpbLTAwAFjxfGs3Ix2ymrdMxp7zo5eFm1tL7 +A7RBZckQrg4FY8aAamkw/dLukO8NJ9+flXP04SXabBbeQTg06ov80egEFGEtQX6sx3dOy1FU+16S +GBsEWmjGycT6txOgmLcRK7fWV8x8nhfRyyX+hk4kLlYMeE2eARKmK6cBZW58Yh2EhN/qwGu1pSqV +g8NTEQxzHQuyRpDRQjrOQG6Vrf/GlK1ul4SOfW+eioANSW1z4nuSHsPzwfPrLgVv2RvPN3YEyLRa +5Beny912H9AZdugsBbPWnDTYltxhh5EF5EQIM8HauQhl1K6yNg3ruji6DOWbnuuNZt2Zz9aJQfYE +koopKW1rOhzndX0CcQ7zwOe9yxndnWCywmZgtrEE7snmhrmaZkCo5xHtgUUDi/ZnWejBBhG93c+A +Ak9lQHhcR1DIm+YfgXvkRKhbhZri3lrVx/k6RGZL5DJUfORsnLMOPReisjQS1n6yqEm70XooQL6i +Fh/f5DcfEXP7kAplQ6INfPgGAVUzfbANuPT1rqVCV3w2EYx7XsQDnYx5nQIDAQABo0IwQDAPBgNV +HRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUtZn4r7CU9eMg1gqtzk5WpC5u +Qu0wDQYJKoZIhvcNAQELBQADggIBACYGXnDnZTPIgm7ZnBc6G3pmsgH2eDtpXi/q/075KMOYKmFM +tCQSin1tERT3nLXK5ryeJ45MGcipvXrA1zYObYVybqjGom32+nNjf7xueQgcnYqfGopTpti72TVV +sRHFqQOzVju5hJMiXn7B9hJSi+osZ7z+Nkz1uM/Rs0mSO9MpDpkblvdhuDvEK7Z4bLQjb/D907Je +dR+Zlais9trhxTF7+9FGs9K8Z7RiVLoJ92Owk6Ka+elSLotgEqv89WBW7xBci8QaQtyDW2QOy7W8 +1k/BfDxujRNt+3vrMNDcTa/F1balTFtxyegxvug4BkihGuLq0t4SOVga/4AOgnXmt8kHbA7v/zjx +mHHEt38OFdAlab0inSvtBfZGR6ztwPDUO+Ls7pZbkBNOHlY667DvlruWIxG68kOGdGSVyCh13x01 +utI3gzhTODY7z2zp+WsO0PsE6E9312UBeIYMej4hYvF/Y3EMyZ9E26gnonW+boE+18DrG5gPcFw0 +sorMwIUY6256s/daoQe/qUKS82Ail+QUoQebTnbAjn39pCXHR+3/H3OszMOl6W8KjptlwlCFtaOg +UxLMVYdh84GuEEZhvUQhuMI9dM9+JDX6HAcOmz0iyu8xL4ysEr3vQCj8KWefshNPZiTEUxnpHikV +7+ZtsH8tZ/3zbBt1RqPlShfppNcL +-----END CERTIFICATE----- + +ACCVRAIZ1 +========= +-----BEGIN CERTIFICATE----- +MIIH0zCCBbugAwIBAgIIXsO3pkN/pOAwDQYJKoZIhvcNAQEFBQAwQjESMBAGA1UEAwwJQUNDVlJB +SVoxMRAwDgYDVQQLDAdQS0lBQ0NWMQ0wCwYDVQQKDARBQ0NWMQswCQYDVQQGEwJFUzAeFw0xMTA1 +MDUwOTM3MzdaFw0zMDEyMzEwOTM3MzdaMEIxEjAQBgNVBAMMCUFDQ1ZSQUlaMTEQMA4GA1UECwwH +UEtJQUNDVjENMAsGA1UECgwEQUNDVjELMAkGA1UEBhMCRVMwggIiMA0GCSqGSIb3DQEBAQUAA4IC +DwAwggIKAoICAQCbqau/YUqXry+XZpp0X9DZlv3P4uRm7x8fRzPCRKPfmt4ftVTdFXxpNRFvu8gM +jmoYHtiP2Ra8EEg2XPBjs5BaXCQ316PWywlxufEBcoSwfdtNgM3802/J+Nq2DoLSRYWoG2ioPej0 +RGy9ocLLA76MPhMAhN9KSMDjIgro6TenGEyxCQ0jVn8ETdkXhBilyNpAlHPrzg5XPAOBOp0KoVdD +aaxXbXmQeOW1tDvYvEyNKKGno6e6Ak4l0Squ7a4DIrhrIA8wKFSVf+DuzgpmndFALW4ir50awQUZ +0m/A8p/4e7MCQvtQqR0tkw8jq8bBD5L/0KIV9VMJcRz/RROE5iZe+OCIHAr8Fraocwa48GOEAqDG +WuzndN9wrqODJerWx5eHk6fGioozl2A3ED6XPm4pFdahD9GILBKfb6qkxkLrQaLjlUPTAYVtjrs7 +8yM2x/474KElB0iryYl0/wiPgL/AlmXz7uxLaL2diMMxs0Dx6M/2OLuc5NF/1OVYm3z61PMOm3WR +5LpSLhl+0fXNWhn8ugb2+1KoS5kE3fj5tItQo05iifCHJPqDQsGH+tUtKSpacXpkatcnYGMN285J +9Y0fkIkyF/hzQ7jSWpOGYdbhdQrqeWZ2iE9x6wQl1gpaepPluUsXQA+xtrn13k/c4LOsOxFwYIRK +Q26ZIMApcQrAZQIDAQABo4ICyzCCAscwfQYIKwYBBQUHAQEEcTBvMEwGCCsGAQUFBzAChkBodHRw +Oi8vd3d3LmFjY3YuZXMvZmlsZWFkbWluL0FyY2hpdm9zL2NlcnRpZmljYWRvcy9yYWl6YWNjdjEu +Y3J0MB8GCCsGAQUFBzABhhNodHRwOi8vb2NzcC5hY2N2LmVzMB0GA1UdDgQWBBTSh7Tj3zcnk1X2 +VuqB5TbMjB4/vTAPBgNVHRMBAf8EBTADAQH/MB8GA1UdIwQYMBaAFNKHtOPfNyeTVfZW6oHlNsyM +Hj+9MIIBcwYDVR0gBIIBajCCAWYwggFiBgRVHSAAMIIBWDCCASIGCCsGAQUFBwICMIIBFB6CARAA +QQB1AHQAbwByAGkAZABhAGQAIABkAGUAIABDAGUAcgB0AGkAZgBpAGMAYQBjAGkA8wBuACAAUgBh +AO0AegAgAGQAZQAgAGwAYQAgAEEAQwBDAFYAIAAoAEEAZwBlAG4AYwBpAGEAIABkAGUAIABUAGUA +YwBuAG8AbABvAGcA7QBhACAAeQAgAEMAZQByAHQAaQBmAGkAYwBhAGMAaQDzAG4AIABFAGwAZQBj +AHQAcgDzAG4AaQBjAGEALAAgAEMASQBGACAAUQA0ADYAMAAxADEANQA2AEUAKQAuACAAQwBQAFMA +IABlAG4AIABoAHQAdABwADoALwAvAHcAdwB3AC4AYQBjAGMAdgAuAGUAczAwBggrBgEFBQcCARYk +aHR0cDovL3d3dy5hY2N2LmVzL2xlZ2lzbGFjaW9uX2MuaHRtMFUGA1UdHwROMEwwSqBIoEaGRGh0 +dHA6Ly93d3cuYWNjdi5lcy9maWxlYWRtaW4vQXJjaGl2b3MvY2VydGlmaWNhZG9zL3JhaXphY2N2 +MV9kZXIuY3JsMA4GA1UdDwEB/wQEAwIBBjAXBgNVHREEEDAOgQxhY2N2QGFjY3YuZXMwDQYJKoZI +hvcNAQEFBQADggIBAJcxAp/n/UNnSEQU5CmH7UwoZtCPNdpNYbdKl02125DgBS4OxnnQ8pdpD70E +R9m+27Up2pvZrqmZ1dM8MJP1jaGo/AaNRPTKFpV8M9xii6g3+CfYCS0b78gUJyCpZET/LtZ1qmxN +YEAZSUNUY9rizLpm5U9EelvZaoErQNV/+QEnWCzI7UiRfD+mAM/EKXMRNt6GGT6d7hmKG9Ww7Y49 +nCrADdg9ZuM8Db3VlFzi4qc1GwQA9j9ajepDvV+JHanBsMyZ4k0ACtrJJ1vnE5Bc5PUzolVt3OAJ +TS+xJlsndQAJxGJ3KQhfnlmstn6tn1QwIgPBHnFk/vk4CpYY3QIUrCPLBhwepH2NDd4nQeit2hW3 +sCPdK6jT2iWH7ehVRE2I9DZ+hJp4rPcOVkkO1jMl1oRQQmwgEh0q1b688nCBpHBgvgW1m54ERL5h +I6zppSSMEYCUWqKiuUnSwdzRp+0xESyeGabu4VXhwOrPDYTkF7eifKXeVSUG7szAh1xA2syVP1Xg +Nce4hL60Xc16gwFy7ofmXx2utYXGJt/mwZrpHgJHnyqobalbz+xFd3+YJ5oyXSrjhO7FmGYvliAd +3djDJ9ew+f7Zfc3Qn48LFFhRny+Lwzgt3uiP1o2HpPVWQxaZLPSkVrQ0uGE3ycJYgBugl6H8WY3p +EfbRD0tVNEYqi4Y7 +-----END CERTIFICATE----- + +TWCA Global Root CA +=================== +-----BEGIN CERTIFICATE----- +MIIFQTCCAymgAwIBAgICDL4wDQYJKoZIhvcNAQELBQAwUTELMAkGA1UEBhMCVFcxEjAQBgNVBAoT +CVRBSVdBTi1DQTEQMA4GA1UECxMHUm9vdCBDQTEcMBoGA1UEAxMTVFdDQSBHbG9iYWwgUm9vdCBD +QTAeFw0xMjA2MjcwNjI4MzNaFw0zMDEyMzExNTU5NTlaMFExCzAJBgNVBAYTAlRXMRIwEAYDVQQK +EwlUQUlXQU4tQ0ExEDAOBgNVBAsTB1Jvb3QgQ0ExHDAaBgNVBAMTE1RXQ0EgR2xvYmFsIFJvb3Qg +Q0EwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCwBdvI64zEbooh745NnHEKH1Jw7W2C +nJfF10xORUnLQEK1EjRsGcJ0pDFfhQKX7EMzClPSnIyOt7h52yvVavKOZsTuKwEHktSz0ALfUPZV +r2YOy+BHYC8rMjk1Ujoog/h7FsYYuGLWRyWRzvAZEk2tY/XTP3VfKfChMBwqoJimFb3u/Rk28OKR +Q4/6ytYQJ0lM793B8YVwm8rqqFpD/G2Gb3PpN0Wp8DbHzIh1HrtsBv+baz4X7GGqcXzGHaL3SekV +tTzWoWH1EfcFbx39Eb7QMAfCKbAJTibc46KokWofwpFFiFzlmLhxpRUZyXx1EcxwdE8tmx2RRP1W +KKD+u4ZqyPpcC1jcxkt2yKsi2XMPpfRaAok/T54igu6idFMqPVMnaR1sjjIsZAAmY2E2TqNGtz99 +sy2sbZCilaLOz9qC5wc0GZbpuCGqKX6mOL6OKUohZnkfs8O1CWfe1tQHRvMq2uYiN2DLgbYPoA/p +yJV/v1WRBXrPPRXAb94JlAGD1zQbzECl8LibZ9WYkTunhHiVJqRaCPgrdLQABDzfuBSO6N+pjWxn +kjMdwLfS7JLIvgm/LCkFbwJrnu+8vyq8W8BQj0FwcYeyTbcEqYSjMq+u7msXi7Kx/mzhkIyIqJdI +zshNy/MGz19qCkKxHh53L46g5pIOBvwFItIm4TFRfTLcDwIDAQABoyMwITAOBgNVHQ8BAf8EBAMC +AQYwDwYDVR0TAQH/BAUwAwEB/zANBgkqhkiG9w0BAQsFAAOCAgEAXzSBdu+WHdXltdkCY4QWwa6g +cFGn90xHNcgL1yg9iXHZqjNB6hQbbCEAwGxCGX6faVsgQt+i0trEfJdLjbDorMjupWkEmQqSpqsn +LhpNgb+E1HAerUf+/UqdM+DyucRFCCEK2mlpc3INvjT+lIutwx4116KD7+U4x6WFH6vPNOw/KP4M +8VeGTslV9xzU2KV9Bnpv1d8Q34FOIWWxtuEXeZVFBs5fzNxGiWNoRI2T9GRwoD2dKAXDOXC4Ynsg +/eTb6QihuJ49CcdP+yz4k3ZB3lLg4VfSnQO8d57+nile98FRYB/e2guyLXW3Q0iT5/Z5xoRdgFlg +lPx4mI88k1HtQJAH32RjJMtOcQWh15QaiDLxInQirqWm2BJpTGCjAu4r7NRjkgtevi92a6O2JryP +A9gK8kxkRr05YuWW6zRjESjMlfGt7+/cgFhI6Uu46mWs6fyAtbXIRfmswZ/ZuepiiI7E8UuDEq3m +i4TWnsLrgxifarsbJGAzcMzs9zLzXNl5fe+epP7JI8Mk7hWSsT2RTyaGvWZzJBPqpK5jwa19hAM8 +EHiGG3njxPPyBJUgriOCxLM6AGK/5jYk4Ve6xx6QddVfP5VhK8E7zeWzaGHQRiapIVJpLesux+t3 +zqY6tQMzT3bR51xUAV3LePTJDL/PEo4XLSNolOer/qmyKwbQBM0= +-----END CERTIFICATE----- + +TeliaSonera Root CA v1 +====================== +-----BEGIN CERTIFICATE----- +MIIFODCCAyCgAwIBAgIRAJW+FqD3LkbxezmCcvqLzZYwDQYJKoZIhvcNAQEFBQAwNzEUMBIGA1UE +CgwLVGVsaWFTb25lcmExHzAdBgNVBAMMFlRlbGlhU29uZXJhIFJvb3QgQ0EgdjEwHhcNMDcxMDE4 +MTIwMDUwWhcNMzIxMDE4MTIwMDUwWjA3MRQwEgYDVQQKDAtUZWxpYVNvbmVyYTEfMB0GA1UEAwwW +VGVsaWFTb25lcmEgUm9vdCBDQSB2MTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAMK+ +6yfwIaPzaSZVfp3FVRaRXP3vIb9TgHot0pGMYzHw7CTww6XScnwQbfQ3t+XmfHnqjLWCi65ItqwA +3GV17CpNX8GH9SBlK4GoRz6JI5UwFpB/6FcHSOcZrr9FZ7E3GwYq/t75rH2D+1665I+XZ75Ljo1k +B1c4VWk0Nj0TSO9P4tNmHqTPGrdeNjPUtAa9GAH9d4RQAEX1jF3oI7x+/jXh7VB7qTCNGdMJjmhn +Xb88lxhTuylixcpecsHHltTbLaC0H2kD7OriUPEMPPCs81Mt8Bz17Ww5OXOAFshSsCPN4D7c3TxH +oLs1iuKYaIu+5b9y7tL6pe0S7fyYGKkmdtwoSxAgHNN/Fnct7W+A90m7UwW7XWjH1Mh1Fj+JWov3 +F0fUTPHSiXk+TT2YqGHeOh7S+F4D4MHJHIzTjU3TlTazN19jY5szFPAtJmtTfImMMsJu7D0hADnJ +oWjiUIMusDor8zagrC/kb2HCUQk5PotTubtn2txTuXZZNp1D5SDgPTJghSJRt8czu90VL6R4pgd7 +gUY2BIbdeTXHlSw7sKMXNeVzH7RcWe/a6hBle3rQf5+ztCo3O3CLm1u5K7fsslESl1MpWtTwEhDc +TwK7EpIvYtQ/aUN8Ddb8WHUBiJ1YFkveupD/RwGJBmr2X7KQarMCpgKIv7NHfirZ1fpoeDVNAgMB +AAGjPzA9MA8GA1UdEwEB/wQFMAMBAf8wCwYDVR0PBAQDAgEGMB0GA1UdDgQWBBTwj1k4ALP1j5qW +DNXr+nuqF+gTEjANBgkqhkiG9w0BAQUFAAOCAgEAvuRcYk4k9AwI//DTDGjkk0kiP0Qnb7tt3oNm +zqjMDfz1mgbldxSR651Be5kqhOX//CHBXfDkH1e3damhXwIm/9fH907eT/j3HEbAek9ALCI18Bmx +0GtnLLCo4MBANzX2hFxc469CeP6nyQ1Q6g2EdvZR74NTxnr/DlZJLo961gzmJ1TjTQpgcmLNkQfW +pb/ImWvtxBnmq0wROMVvMeJuScg/doAmAyYp4Db29iBT4xdwNBedY2gea+zDTYa4EzAvXUYNR0PV +G6pZDrlcjQZIrXSHX8f8MVRBE+LHIQ6e4B4N4cB7Q4WQxYpYxmUKeFfyxiMPAdkgS94P+5KFdSpc +c41teyWRyu5FrgZLAMzTsVlQ2jqIOylDRl6XK1TOU2+NSueW+r9xDkKLfP0ooNBIytrEgUy7onOT +JsjrDNYmiLbAJM+7vVvrdX3pCI6GMyx5dwlppYn8s3CQh3aP0yK7Qs69cwsgJirQmz1wHiRszYd2 +qReWt88NkvuOGKmYSdGe/mBEciG5Ge3C9THxOUiIkCR1VBatzvT4aRRkOfujuLpwQMcnHL/EVlP6 +Y2XQ8xwOFvVrhlhNGNTkDY6lnVuR3HYkUD/GKvvZt5y11ubQ2egZixVxSK236thZiNSQvxaz2ems +WWFUyBy6ysHK4bkgTI86k4mloMy/0/Z1pHWWbVY= +-----END CERTIFICATE----- + +E-Tugra Certification Authority +=============================== +-----BEGIN CERTIFICATE----- +MIIGSzCCBDOgAwIBAgIIamg+nFGby1MwDQYJKoZIhvcNAQELBQAwgbIxCzAJBgNVBAYTAlRSMQ8w +DQYDVQQHDAZBbmthcmExQDA+BgNVBAoMN0UtVHXEn3JhIEVCRyBCaWxpxZ9pbSBUZWtub2xvamls +ZXJpIHZlIEhpem1ldGxlcmkgQS7Fni4xJjAkBgNVBAsMHUUtVHVncmEgU2VydGlmaWthc3lvbiBN +ZXJrZXppMSgwJgYDVQQDDB9FLVR1Z3JhIENlcnRpZmljYXRpb24gQXV0aG9yaXR5MB4XDTEzMDMw +NTEyMDk0OFoXDTIzMDMwMzEyMDk0OFowgbIxCzAJBgNVBAYTAlRSMQ8wDQYDVQQHDAZBbmthcmEx +QDA+BgNVBAoMN0UtVHXEn3JhIEVCRyBCaWxpxZ9pbSBUZWtub2xvamlsZXJpIHZlIEhpem1ldGxl +cmkgQS7Fni4xJjAkBgNVBAsMHUUtVHVncmEgU2VydGlmaWthc3lvbiBNZXJrZXppMSgwJgYDVQQD +DB9FLVR1Z3JhIENlcnRpZmljYXRpb24gQXV0aG9yaXR5MIICIjANBgkqhkiG9w0BAQEFAAOCAg8A +MIICCgKCAgEA4vU/kwVRHoViVF56C/UYB4Oufq9899SKa6VjQzm5S/fDxmSJPZQuVIBSOTkHS0vd +hQd2h8y/L5VMzH2nPbxHD5hw+IyFHnSOkm0bQNGZDbt1bsipa5rAhDGvykPL6ys06I+XawGb1Q5K +CKpbknSFQ9OArqGIW66z6l7LFpp3RMih9lRozt6Plyu6W0ACDGQXwLWTzeHxE2bODHnv0ZEoq1+g +ElIwcxmOj+GMB6LDu0rw6h8VqO4lzKRG+Bsi77MOQ7osJLjFLFzUHPhdZL3Dk14opz8n8Y4e0ypQ +BaNV2cvnOVPAmJ6MVGKLJrD3fY185MaeZkJVgkfnsliNZvcHfC425lAcP9tDJMW/hkd5s3kc91r0 +E+xs+D/iWR+V7kI+ua2oMoVJl0b+SzGPWsutdEcf6ZG33ygEIqDUD13ieU/qbIWGvaimzuT6w+Gz +rt48Ue7LE3wBf4QOXVGUnhMMti6lTPk5cDZvlsouDERVxcr6XQKj39ZkjFqzAQqptQpHF//vkUAq +jqFGOjGY5RH8zLtJVor8udBhmm9lbObDyz51Sf6Pp+KJxWfXnUYTTjF2OySznhFlhqt/7x3U+Lzn +rFpct1pHXFXOVbQicVtbC/DP3KBhZOqp12gKY6fgDT+gr9Oq0n7vUaDmUStVkhUXU8u3Zg5mTPj5 +dUyQ5xJwx0UCAwEAAaNjMGEwHQYDVR0OBBYEFC7j27JJ0JxUeVz6Jyr+zE7S6E5UMA8GA1UdEwEB +/wQFMAMBAf8wHwYDVR0jBBgwFoAULuPbsknQnFR5XPonKv7MTtLoTlQwDgYDVR0PAQH/BAQDAgEG +MA0GCSqGSIb3DQEBCwUAA4ICAQAFNzr0TbdF4kV1JI+2d1LoHNgQk2Xz8lkGpD4eKexd0dCrfOAK +kEh47U6YA5n+KGCRHTAduGN8qOY1tfrTYXbm1gdLymmasoR6d5NFFxWfJNCYExL/u6Au/U5Mh/jO +XKqYGwXgAEZKgoClM4so3O0409/lPun++1ndYYRP0lSWE2ETPo+Aab6TR7U1Q9Jauz1c77NCR807 +VRMGsAnb/WP2OogKmW9+4c4bU2pEZiNRCHu8W1Ki/QY3OEBhj0qWuJA3+GbHeJAAFS6LrVE1Uweo +a2iu+U48BybNCAVwzDk/dr2l02cmAYamU9JgO3xDf1WKvJUawSg5TB9D0pH0clmKuVb8P7Sd2nCc +dlqMQ1DujjByTd//SffGqWfZbawCEeI6FiWnWAjLb1NBnEg4R2gz0dfHj9R0IdTDBZB6/86WiLEV +KV0jq9BgoRJP3vQXzTLlyb/IQ639Lo7xr+L0mPoSHyDYwKcMhcWQ9DstliaxLL5Mq+ux0orJ23gT +Dx4JnW2PAJ8C2sH6H3p6CcRK5ogql5+Ji/03X186zjhZhkuvcQu02PJwT58yE+Owp1fl2tpDy4Q0 +8ijE6m30Ku/Ba3ba+367hTzSU8JNvnHhRdH9I2cNE3X7z2VnIp2usAnRCf8dNL/+I5c30jn6PQ0G +C7TbO6Orb1wdtn7os4I07QZcJA== +-----END CERTIFICATE----- + +T-TeleSec GlobalRoot Class 2 +============================ +-----BEGIN CERTIFICATE----- +MIIDwzCCAqugAwIBAgIBATANBgkqhkiG9w0BAQsFADCBgjELMAkGA1UEBhMCREUxKzApBgNVBAoM +IlQtU3lzdGVtcyBFbnRlcnByaXNlIFNlcnZpY2VzIEdtYkgxHzAdBgNVBAsMFlQtU3lzdGVtcyBU +cnVzdCBDZW50ZXIxJTAjBgNVBAMMHFQtVGVsZVNlYyBHbG9iYWxSb290IENsYXNzIDIwHhcNMDgx +MDAxMTA0MDE0WhcNMzMxMDAxMjM1OTU5WjCBgjELMAkGA1UEBhMCREUxKzApBgNVBAoMIlQtU3lz +dGVtcyBFbnRlcnByaXNlIFNlcnZpY2VzIEdtYkgxHzAdBgNVBAsMFlQtU3lzdGVtcyBUcnVzdCBD +ZW50ZXIxJTAjBgNVBAMMHFQtVGVsZVNlYyBHbG9iYWxSb290IENsYXNzIDIwggEiMA0GCSqGSIb3 +DQEBAQUAA4IBDwAwggEKAoIBAQCqX9obX+hzkeXaXPSi5kfl82hVYAUdAqSzm1nzHoqvNK38DcLZ +SBnuaY/JIPwhqgcZ7bBcrGXHX+0CfHt8LRvWurmAwhiCFoT6ZrAIxlQjgeTNuUk/9k9uN0goOA/F +vudocP05l03Sx5iRUKrERLMjfTlH6VJi1hKTXrcxlkIF+3anHqP1wvzpesVsqXFP6st4vGCvx970 +2cu+fjOlbpSD8DT6IavqjnKgP6TeMFvvhk1qlVtDRKgQFRzlAVfFmPHmBiiRqiDFt1MmUUOyCxGV +WOHAD3bZwI18gfNycJ5v/hqO2V81xrJvNHy+SE/iWjnX2J14np+GPgNeGYtEotXHAgMBAAGjQjBA +MA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBS/WSA2AHmgoCJrjNXy +YdK4LMuCSjANBgkqhkiG9w0BAQsFAAOCAQEAMQOiYQsfdOhyNsZt+U2e+iKo4YFWz827n+qrkRk4 +r6p8FU3ztqONpfSO9kSpp+ghla0+AGIWiPACuvxhI+YzmzB6azZie60EI4RYZeLbK4rnJVM3YlNf +vNoBYimipidx5joifsFvHZVwIEoHNN/q/xWA5brXethbdXwFeilHfkCoMRN3zUA7tFFHei4R40cR +3p1m0IvVVGb6g1XqfMIpiRvpb7PO4gWEyS8+eIVibslfwXhjdFjASBgMmTnrpMwatXlajRWc2BQN +9noHV8cigwUtPJslJj0Ys6lDfMjIq2SPDqO/nBudMNva0Bkuqjzx+zOAduTNrRlPBSeOE6Fuwg== +-----END CERTIFICATE----- + +Atos TrustedRoot 2011 +===================== +-----BEGIN CERTIFICATE----- +MIIDdzCCAl+gAwIBAgIIXDPLYixfszIwDQYJKoZIhvcNAQELBQAwPDEeMBwGA1UEAwwVQXRvcyBU +cnVzdGVkUm9vdCAyMDExMQ0wCwYDVQQKDARBdG9zMQswCQYDVQQGEwJERTAeFw0xMTA3MDcxNDU4 +MzBaFw0zMDEyMzEyMzU5NTlaMDwxHjAcBgNVBAMMFUF0b3MgVHJ1c3RlZFJvb3QgMjAxMTENMAsG +A1UECgwEQXRvczELMAkGA1UEBhMCREUwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQCV +hTuXbyo7LjvPpvMpNb7PGKw+qtn4TaA+Gke5vJrf8v7MPkfoepbCJI419KkM/IL9bcFyYie96mvr +54rMVD6QUM+A1JX76LWC1BTFtqlVJVfbsVD2sGBkWXppzwO3bw2+yj5vdHLqqjAqc2K+SZFhyBH+ +DgMq92og3AIVDV4VavzjgsG1xZ1kCWyjWZgHJ8cblithdHFsQ/H3NYkQ4J7sVaE3IqKHBAUsR320 +HLliKWYoyrfhk/WklAOZuXCFteZI6o1Q/NnezG8HDt0Lcp2AMBYHlT8oDv3FdU9T1nSatCQujgKR +z3bFmx5VdJx4IbHwLfELn8LVlhgf8FQieowHAgMBAAGjfTB7MB0GA1UdDgQWBBSnpQaxLKYJYO7R +l+lwrrw7GWzbITAPBgNVHRMBAf8EBTADAQH/MB8GA1UdIwQYMBaAFKelBrEspglg7tGX6XCuvDsZ +bNshMBgGA1UdIAQRMA8wDQYLKwYBBAGwLQMEAQEwDgYDVR0PAQH/BAQDAgGGMA0GCSqGSIb3DQEB +CwUAA4IBAQAmdzTblEiGKkGdLD4GkGDEjKwLVLgfuXvTBznk+j57sj1O7Z8jvZfza1zv7v1Apt+h +k6EKhqzvINB5Ab149xnYJDE0BAGmuhWawyfc2E8PzBhj/5kPDpFrdRbhIfzYJsdHt6bPWHJxfrrh +TZVHO8mvbaG0weyJ9rQPOLXiZNwlz6bb65pcmaHFCN795trV1lpFDMS3wrUU77QR/w4VtfX128a9 +61qn8FYiqTxlVMYVqL2Gns2Dlmh6cYGJ4Qvh6hEbaAjMaZ7snkGeRDImeuKHCnE96+RapNLbxc3G +3mB/ufNPRJLvKrcYPqcZ2Qt9sTdBQrC6YB3y/gkRsPCHe6ed +-----END CERTIFICATE----- + +QuoVadis Root CA 1 G3 +===================== +-----BEGIN CERTIFICATE----- +MIIFYDCCA0igAwIBAgIUeFhfLq0sGUvjNwc1NBMotZbUZZMwDQYJKoZIhvcNAQELBQAwSDELMAkG +A1UEBhMCQk0xGTAXBgNVBAoTEFF1b1ZhZGlzIExpbWl0ZWQxHjAcBgNVBAMTFVF1b1ZhZGlzIFJv +b3QgQ0EgMSBHMzAeFw0xMjAxMTIxNzI3NDRaFw00MjAxMTIxNzI3NDRaMEgxCzAJBgNVBAYTAkJN +MRkwFwYDVQQKExBRdW9WYWRpcyBMaW1pdGVkMR4wHAYDVQQDExVRdW9WYWRpcyBSb290IENBIDEg +RzMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCgvlAQjunybEC0BJyFuTHK3C3kEakE +PBtVwedYMB0ktMPvhd6MLOHBPd+C5k+tR4ds7FtJwUrVu4/sh6x/gpqG7D0DmVIB0jWerNrwU8lm +PNSsAgHaJNM7qAJGr6Qc4/hzWHa39g6QDbXwz8z6+cZM5cOGMAqNF34168Xfuw6cwI2H44g4hWf6 +Pser4BOcBRiYz5P1sZK0/CPTz9XEJ0ngnjybCKOLXSoh4Pw5qlPafX7PGglTvF0FBM+hSo+LdoIN +ofjSxxR3W5A2B4GbPgb6Ul5jxaYA/qXpUhtStZI5cgMJYr2wYBZupt0lwgNm3fME0UDiTouG9G/l +g6AnhF4EwfWQvTA9xO+oabw4m6SkltFi2mnAAZauy8RRNOoMqv8hjlmPSlzkYZqn0ukqeI1RPToV +7qJZjqlc3sX5kCLliEVx3ZGZbHqfPT2YfF72vhZooF6uCyP8Wg+qInYtyaEQHeTTRCOQiJ/GKubX +9ZqzWB4vMIkIG1SitZgj7Ah3HJVdYdHLiZxfokqRmu8hqkkWCKi9YSgxyXSthfbZxbGL0eUQMk1f +iyA6PEkfM4VZDdvLCXVDaXP7a3F98N/ETH3Goy7IlXnLc6KOTk0k+17kBL5yG6YnLUlamXrXXAkg +t3+UuU/xDRxeiEIbEbfnkduebPRq34wGmAOtzCjvpUfzUwIDAQABo0IwQDAPBgNVHRMBAf8EBTAD +AQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUo5fW816iEOGrRZ88F2Q87gFwnMwwDQYJKoZI +hvcNAQELBQADggIBABj6W3X8PnrHX3fHyt/PX8MSxEBd1DKquGrX1RUVRpgjpeaQWxiZTOOtQqOC +MTaIzen7xASWSIsBx40Bz1szBpZGZnQdT+3Btrm0DWHMY37XLneMlhwqI2hrhVd2cDMT/uFPpiN3 +GPoajOi9ZcnPP/TJF9zrx7zABC4tRi9pZsMbj/7sPtPKlL92CiUNqXsCHKnQO18LwIE6PWThv6ct +Tr1NxNgpxiIY0MWscgKCP6o6ojoilzHdCGPDdRS5YCgtW2jgFqlmgiNR9etT2DGbe+m3nUvriBbP ++V04ikkwj+3x6xn0dxoxGE1nVGwvb2X52z3sIexe9PSLymBlVNFxZPT5pqOBMzYzcfCkeF9OrYMh +3jRJjehZrJ3ydlo28hP0r+AJx2EqbPfgna67hkooby7utHnNkDPDs3b69fBsnQGQ+p6Q9pxyz0fa +wx/kNSBT8lTR32GDpgLiJTjehTItXnOQUl1CxM49S+H5GYQd1aJQzEH7QRTDvdbJWqNjZgKAvQU6 +O0ec7AAmTPWIUb+oI38YB7AL7YsmoWTTYUrrXJ/es69nA7Mf3W1daWhpq1467HxpvMc7hU6eFbm0 +FU/DlXpY18ls6Wy58yljXrQs8C097Vpl4KlbQMJImYFtnh8GKjwStIsPm6Ik8KaN1nrgS7ZklmOV +hMJKzRwuJIczYOXD +-----END CERTIFICATE----- + +QuoVadis Root CA 2 G3 +===================== +-----BEGIN CERTIFICATE----- +MIIFYDCCA0igAwIBAgIURFc0JFuBiZs18s64KztbpybwdSgwDQYJKoZIhvcNAQELBQAwSDELMAkG +A1UEBhMCQk0xGTAXBgNVBAoTEFF1b1ZhZGlzIExpbWl0ZWQxHjAcBgNVBAMTFVF1b1ZhZGlzIFJv +b3QgQ0EgMiBHMzAeFw0xMjAxMTIxODU5MzJaFw00MjAxMTIxODU5MzJaMEgxCzAJBgNVBAYTAkJN +MRkwFwYDVQQKExBRdW9WYWRpcyBMaW1pdGVkMR4wHAYDVQQDExVRdW9WYWRpcyBSb290IENBIDIg +RzMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQChriWyARjcV4g/Ruv5r+LrI3HimtFh +ZiFfqq8nUeVuGxbULX1QsFN3vXg6YOJkApt8hpvWGo6t/x8Vf9WVHhLL5hSEBMHfNrMWn4rjyduY +NM7YMxcoRvynyfDStNVNCXJJ+fKH46nafaF9a7I6JaltUkSs+L5u+9ymc5GQYaYDFCDy54ejiK2t +oIz/pgslUiXnFgHVy7g1gQyjO/Dh4fxaXc6AcW34Sas+O7q414AB+6XrW7PFXmAqMaCvN+ggOp+o +MiwMzAkd056OXbxMmO7FGmh77FOm6RQ1o9/NgJ8MSPsc9PG/Srj61YxxSscfrf5BmrODXfKEVu+l +V0POKa2Mq1W/xPtbAd0jIaFYAI7D0GoT7RPjEiuA3GfmlbLNHiJuKvhB1PLKFAeNilUSxmn1uIZo +L1NesNKqIcGY5jDjZ1XHm26sGahVpkUG0CM62+tlXSoREfA7T8pt9DTEceT/AFr2XK4jYIVz8eQQ +sSWu1ZK7E8EM4DnatDlXtas1qnIhO4M15zHfeiFuuDIIfR0ykRVKYnLP43ehvNURG3YBZwjgQQvD +6xVu+KQZ2aKrr+InUlYrAoosFCT5v0ICvybIxo/gbjh9Uy3l7ZizlWNof/k19N+IxWA1ksB8aRxh +lRbQ694Lrz4EEEVlWFA4r0jyWbYW8jwNkALGcC4BrTwV1wIDAQABo0IwQDAPBgNVHRMBAf8EBTAD +AQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQU7edvdlq/YOxJW8ald7tyFnGbxD0wDQYJKoZI +hvcNAQELBQADggIBAJHfgD9DCX5xwvfrs4iP4VGyvD11+ShdyLyZm3tdquXK4Qr36LLTn91nMX66 +AarHakE7kNQIXLJgapDwyM4DYvmL7ftuKtwGTTwpD4kWilhMSA/ohGHqPHKmd+RCroijQ1h5fq7K +pVMNqT1wvSAZYaRsOPxDMuHBR//47PERIjKWnML2W2mWeyAMQ0GaW/ZZGYjeVYg3UQt4XAoeo0L9 +x52ID8DyeAIkVJOviYeIyUqAHerQbj5hLja7NQ4nlv1mNDthcnPxFlxHBlRJAHpYErAK74X9sbgz +dWqTHBLmYF5vHX/JHyPLhGGfHoJE+V+tYlUkmlKY7VHnoX6XOuYvHxHaU4AshZ6rNRDbIl9qxV6X +U/IyAgkwo1jwDQHVcsaxfGl7w/U2Rcxhbl5MlMVerugOXou/983g7aEOGzPuVBj+D77vfoRrQ+Nw +mNtddbINWQeFFSM51vHfqSYP1kjHs6Yi9TM3WpVHn3u6GBVv/9YUZINJ0gpnIdsPNWNgKCLjsZWD +zYWm3S8P52dSbrsvhXz1SnPnxT7AvSESBT/8twNJAlvIJebiVDj1eYeMHVOyToV7BjjHLPj4sHKN +JeV3UvQDHEimUF+IIDBu8oJDqz2XhOdT+yHBTw8imoa4WSr2Rz0ZiC3oheGe7IUIarFsNMkd7Egr +O3jtZsSOeWmD3n+M +-----END CERTIFICATE----- + +QuoVadis Root CA 3 G3 +===================== +-----BEGIN CERTIFICATE----- +MIIFYDCCA0igAwIBAgIULvWbAiin23r/1aOp7r0DoM8Sah0wDQYJKoZIhvcNAQELBQAwSDELMAkG +A1UEBhMCQk0xGTAXBgNVBAoTEFF1b1ZhZGlzIExpbWl0ZWQxHjAcBgNVBAMTFVF1b1ZhZGlzIFJv +b3QgQ0EgMyBHMzAeFw0xMjAxMTIyMDI2MzJaFw00MjAxMTIyMDI2MzJaMEgxCzAJBgNVBAYTAkJN +MRkwFwYDVQQKExBRdW9WYWRpcyBMaW1pdGVkMR4wHAYDVQQDExVRdW9WYWRpcyBSb290IENBIDMg +RzMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCzyw4QZ47qFJenMioKVjZ/aEzHs286 +IxSR/xl/pcqs7rN2nXrpixurazHb+gtTTK/FpRp5PIpM/6zfJd5O2YIyC0TeytuMrKNuFoM7pmRL +Mon7FhY4futD4tN0SsJiCnMK3UmzV9KwCoWdcTzeo8vAMvMBOSBDGzXRU7Ox7sWTaYI+FrUoRqHe +6okJ7UO4BUaKhvVZR74bbwEhELn9qdIoyhA5CcoTNs+cra1AdHkrAj80//ogaX3T7mH1urPnMNA3 +I4ZyYUUpSFlob3emLoG+B01vr87ERRORFHAGjx+f+IdpsQ7vw4kZ6+ocYfx6bIrc1gMLnia6Et3U +VDmrJqMz6nWB2i3ND0/kA9HvFZcba5DFApCTZgIhsUfei5pKgLlVj7WiL8DWM2fafsSntARE60f7 +5li59wzweyuxwHApw0BiLTtIadwjPEjrewl5qW3aqDCYz4ByA4imW0aucnl8CAMhZa634RylsSqi +Md5mBPfAdOhx3v89WcyWJhKLhZVXGqtrdQtEPREoPHtht+KPZ0/l7DxMYIBpVzgeAVuNVejH38DM +dyM0SXV89pgR6y3e7UEuFAUCf+D+IOs15xGsIs5XPd7JMG0QA4XN8f+MFrXBsj6IbGB/kE+V9/Yt +rQE5BwT6dYB9v0lQ7e/JxHwc64B+27bQ3RP+ydOc17KXqQIDAQABo0IwQDAPBgNVHRMBAf8EBTAD +AQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUxhfQvKjqAkPyGwaZXSuQILnXnOQwDQYJKoZI +hvcNAQELBQADggIBADRh2Va1EodVTd2jNTFGu6QHcrxfYWLopfsLN7E8trP6KZ1/AvWkyaiTt3px +KGmPc+FSkNrVvjrlt3ZqVoAh313m6Tqe5T72omnHKgqwGEfcIHB9UqM+WXzBusnIFUBhynLWcKzS +t/Ac5IYp8M7vaGPQtSCKFWGafoaYtMnCdvvMujAWzKNhxnQT5WvvoxXqA/4Ti2Tk08HS6IT7SdEQ +TXlm66r99I0xHnAUrdzeZxNMgRVhvLfZkXdxGYFgu/BYpbWcC/ePIlUnwEsBbTuZDdQdm2NnL9Du +DcpmvJRPpq3t/O5jrFc/ZSXPsoaP0Aj/uHYUbt7lJ+yreLVTubY/6CD50qi+YUbKh4yE8/nxoGib +Ih6BJpsQBJFxwAYf3KDTuVan45gtf4Od34wrnDKOMpTwATwiKp9Dwi7DmDkHOHv8XgBCH/MyJnmD +hPbl8MFREsALHgQjDFSlTC9JxUrRtm5gDWv8a4uFJGS3iQ6rJUdbPM9+Sb3H6QrG2vd+DhcI00iX +0HGS8A85PjRqHH3Y8iKuu2n0M7SmSFXRDw4m6Oy2Cy2nhTXN/VnIn9HNPlopNLk9hM6xZdRZkZFW +dSHBd575euFgndOtBBj0fOtek49TSiIp+EgrPk2GrFt/ywaZWWDYWGWVjUTR939+J399roD1B0y2 +PpxxVJkES/1Y+Zj0 +-----END CERTIFICATE----- + +DigiCert Assured ID Root G2 +=========================== +-----BEGIN CERTIFICATE----- +MIIDljCCAn6gAwIBAgIQC5McOtY5Z+pnI7/Dr5r0SzANBgkqhkiG9w0BAQsFADBlMQswCQYDVQQG +EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSQw +IgYDVQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgRzIwHhcNMTMwODAxMTIwMDAwWhcNMzgw +MTE1MTIwMDAwWjBlMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQL +ExB3d3cuZGlnaWNlcnQuY29tMSQwIgYDVQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgRzIw +ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDZ5ygvUj82ckmIkzTz+GoeMVSAn61UQbVH +35ao1K+ALbkKz3X9iaV9JPrjIgwrvJUXCzO/GU1BBpAAvQxNEP4HteccbiJVMWWXvdMX0h5i89vq +bFCMP4QMls+3ywPgym2hFEwbid3tALBSfK+RbLE4E9HpEgjAALAcKxHad3A2m67OeYfcgnDmCXRw +VWmvo2ifv922ebPynXApVfSr/5Vh88lAbx3RvpO704gqu52/clpWcTs/1PPRCv4o76Pu2ZmvA9OP +YLfykqGxvYmJHzDNw6YuYjOuFgJ3RFrngQo8p0Quebg/BLxcoIfhG69Rjs3sLPr4/m3wOnyqi+Rn +lTGNAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMB0GA1UdDgQWBBTO +w0q5mVXyuNtgv6l+vVa1lzan1jANBgkqhkiG9w0BAQsFAAOCAQEAyqVVjOPIQW5pJ6d1Ee88hjZv +0p3GeDgdaZaikmkuOGybfQTUiaWxMTeKySHMq2zNixya1r9I0jJmwYrA8y8678Dj1JGG0VDjA9tz +d29KOVPt3ibHtX2vK0LRdWLjSisCx1BL4GnilmwORGYQRI+tBev4eaymG+g3NJ1TyWGqolKvSnAW +hsI6yLETcDbYz+70CjTVW0z9B5yiutkBclzzTcHdDrEcDcRjvq30FPuJ7KJBDkzMyFdA0G4Dqs0M +jomZmWzwPDCvON9vvKO+KSAnq3T/EyJ43pdSVR6DtVQgA+6uwE9W3jfMw3+qBCe703e4YtsXfJwo +IhNzbM8m9Yop5w== +-----END CERTIFICATE----- + +DigiCert Assured ID Root G3 +=========================== +-----BEGIN CERTIFICATE----- +MIICRjCCAc2gAwIBAgIQC6Fa+h3foLVJRK/NJKBs7DAKBggqhkjOPQQDAzBlMQswCQYDVQQGEwJV +UzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSQwIgYD +VQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgRzMwHhcNMTMwODAxMTIwMDAwWhcNMzgwMTE1 +MTIwMDAwWjBlMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3 +d3cuZGlnaWNlcnQuY29tMSQwIgYDVQQDExtEaWdpQ2VydCBBc3N1cmVkIElEIFJvb3QgRzMwdjAQ +BgcqhkjOPQIBBgUrgQQAIgNiAAQZ57ysRGXtzbg/WPuNsVepRC0FFfLvC/8QdJ+1YlJfZn4f5dwb +RXkLzMZTCp2NXQLZqVneAlr2lSoOjThKiknGvMYDOAdfVdp+CW7if17QRSAPWXYQ1qAk8C3eNvJs +KTmjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMB0GA1UdDgQWBBTL0L2p4ZgF +UaFNN6KDec6NHSrkhDAKBggqhkjOPQQDAwNnADBkAjAlpIFFAmsSS3V0T8gj43DydXLefInwz5Fy +YZ5eEJJZVrmDxxDnOOlYJjZ91eQ0hjkCMHw2U/Aw5WJjOpnitqM7mzT6HtoQknFekROn3aRukswy +1vUhZscv6pZjamVFkpUBtA== +-----END CERTIFICATE----- + +DigiCert Global Root G2 +======================= +-----BEGIN CERTIFICATE----- +MIIDjjCCAnagAwIBAgIQAzrx5qcRqaC7KGSxHQn65TANBgkqhkiG9w0BAQsFADBhMQswCQYDVQQG +EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSAw +HgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBHMjAeFw0xMzA4MDExMjAwMDBaFw0zODAxMTUx +MjAwMDBaMGExCzAJBgNVBAYTAlVTMRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3 +dy5kaWdpY2VydC5jb20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IEcyMIIBIjANBgkq +hkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuzfNNNx7a8myaJCtSnX/RrohCgiN9RlUyfuI2/Ou8jqJ +kTx65qsGGmvPrC3oXgkkRLpimn7Wo6h+4FR1IAWsULecYxpsMNzaHxmx1x7e/dfgy5SDN67sH0NO +3Xss0r0upS/kqbitOtSZpLYl6ZtrAGCSYP9PIUkY92eQq2EGnI/yuum06ZIya7XzV+hdG82MHauV +BJVJ8zUtluNJbd134/tJS7SsVQepj5WztCO7TG1F8PapspUwtP1MVYwnSlcUfIKdzXOS0xZKBgyM +UNGPHgm+F6HmIcr9g+UQvIOlCsRnKPZzFBQ9RnbDhxSJITRNrw9FDKZJobq7nMWxM4MphQIDAQAB +o0IwQDAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBhjAdBgNVHQ4EFgQUTiJUIBiV5uNu +5g/6+rkS7QYXjzkwDQYJKoZIhvcNAQELBQADggEBAGBnKJRvDkhj6zHd6mcY1Yl9PMWLSn/pvtsr +F9+wX3N3KjITOYFnQoQj8kVnNeyIv/iPsGEMNKSuIEyExtv4NeF22d+mQrvHRAiGfzZ0JFrabA0U +WTW98kndth/Jsw1HKj2ZL7tcu7XUIOGZX1NGFdtom/DzMNU+MeKNhJ7jitralj41E6Vf8PlwUHBH +QRFXGU7Aj64GxJUTFy8bJZ918rGOmaFvE7FBcf6IKshPECBV1/MUReXgRPTqh5Uykw7+U0b6LJ3/ +iyK5S9kJRaTepLiaWN0bfVKfjllDiIGknibVb63dDcY3fe0Dkhvld1927jyNxF1WW6LZZm6zNTfl +MrY= +-----END CERTIFICATE----- + +DigiCert Global Root G3 +======================= +-----BEGIN CERTIFICATE----- +MIICPzCCAcWgAwIBAgIQBVVWvPJepDU1w6QP1atFcjAKBggqhkjOPQQDAzBhMQswCQYDVQQGEwJV +UzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSAwHgYD +VQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBHMzAeFw0xMzA4MDExMjAwMDBaFw0zODAxMTUxMjAw +MDBaMGExCzAJBgNVBAYTAlVTMRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5k +aWdpY2VydC5jb20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IEczMHYwEAYHKoZIzj0C +AQYFK4EEACIDYgAE3afZu4q4C/sLfyHS8L6+c/MzXRq8NOrexpu80JX28MzQC7phW1FGfp4tn+6O +YwwX7Adw9c+ELkCDnOg/QW07rdOkFFk2eJ0DQ+4QE2xy3q6Ip6FrtUPOZ9wj/wMco+I+o0IwQDAP +BgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBhjAdBgNVHQ4EFgQUs9tIpPmhxdiuNkHMEWNp +Yim8S8YwCgYIKoZIzj0EAwMDaAAwZQIxAK288mw/EkrRLTnDCgmXc/SINoyIJ7vmiI1Qhadj+Z4y +3maTD/HMsQmP3Wyr+mt/oAIwOWZbwmSNuJ5Q3KjVSaLtx9zRSX8XAbjIho9OjIgrqJqpisXRAL34 +VOKa5Vt8sycX +-----END CERTIFICATE----- + +DigiCert Trusted Root G4 +======================== +-----BEGIN CERTIFICATE----- +MIIFkDCCA3igAwIBAgIQBZsbV56OITLiOQe9p3d1XDANBgkqhkiG9w0BAQwFADBiMQswCQYDVQQG +EwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQuY29tMSEw +HwYDVQQDExhEaWdpQ2VydCBUcnVzdGVkIFJvb3QgRzQwHhcNMTMwODAxMTIwMDAwWhcNMzgwMTE1 +MTIwMDAwWjBiMQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3 +d3cuZGlnaWNlcnQuY29tMSEwHwYDVQQDExhEaWdpQ2VydCBUcnVzdGVkIFJvb3QgRzQwggIiMA0G +CSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC/5pBzaN675F1KPDAiMGkz7MKnJS7JIT3yithZwuEp +pz1Yq3aaza57G4QNxDAf8xukOBbrVsaXbR2rsnnyyhHS5F/WBTxSD1Ifxp4VpX6+n6lXFllVcq9o +k3DCsrp1mWpzMpTREEQQLt+C8weE5nQ7bXHiLQwb7iDVySAdYyktzuxeTsiT+CFhmzTrBcZe7Fsa +vOvJz82sNEBfsXpm7nfISKhmV1efVFiODCu3T6cw2Vbuyntd463JT17lNecxy9qTXtyOj4DatpGY +QJB5w3jHtrHEtWoYOAMQjdjUN6QuBX2I9YI+EJFwq1WCQTLX2wRzKm6RAXwhTNS8rhsDdV14Ztk6 +MUSaM0C/CNdaSaTC5qmgZ92kJ7yhTzm1EVgX9yRcRo9k98FpiHaYdj1ZXUJ2h4mXaXpI8OCiEhtm +mnTK3kse5w5jrubU75KSOp493ADkRSWJtppEGSt+wJS00mFt6zPZxd9LBADMfRyVw4/3IbKyEbe7 +f/LVjHAsQWCqsWMYRJUadmJ+9oCw++hkpjPRiQfhvbfmQ6QYuKZ3AeEPlAwhHbJUKSWJbOUOUlFH +dL4mrLZBdd56rF+NP8m800ERElvlEFDrMcXKchYiCd98THU/Y+whX8QgUWtvsauGi0/C1kVfnSD8 +oR7FwI+isX4KJpn15GkvmB0t9dmpsh3lGwIDAQABo0IwQDAPBgNVHRMBAf8EBTADAQH/MA4GA1Ud +DwEB/wQEAwIBhjAdBgNVHQ4EFgQU7NfjgtJxXWRM3y5nP+e6mK4cD08wDQYJKoZIhvcNAQEMBQAD +ggIBALth2X2pbL4XxJEbw6GiAI3jZGgPVs93rnD5/ZpKmbnJeFwMDF/k5hQpVgs2SV1EY+CtnJYY +ZhsjDT156W1r1lT40jzBQ0CuHVD1UvyQO7uYmWlrx8GnqGikJ9yd+SeuMIW59mdNOj6PWTkiU0Tr +yF0Dyu1Qen1iIQqAyHNm0aAFYF/opbSnr6j3bTWcfFqK1qI4mfN4i/RN0iAL3gTujJtHgXINwBQy +7zBZLq7gcfJW5GqXb5JQbZaNaHqasjYUegbyJLkJEVDXCLG4iXqEI2FCKeWjzaIgQdfRnGTZ6iah +ixTXTBmyUEFxPT9NcCOGDErcgdLMMpSEDQgJlxxPwO5rIHQw0uA5NBCFIRUBCOhVMt5xSdkoF1BN +5r5N0XWs0Mr7QbhDparTwwVETyw2m+L64kW4I1NsBm9nVX9GtUw/bihaeSbSpKhil9Ie4u1Ki7wb +/UdKDd9nZn6yW0HQO+T0O/QEY+nvwlQAUaCKKsnOeMzV6ocEGLPOr0mIr/OSmbaz5mEP0oUA51Aa +5BuVnRmhuZyxm7EAHu/QD09CbMkKvO5D+jpxpchNJqU1/YldvIViHTLSoCtU7ZpXwdv6EM8Zt4tK +G48BtieVU+i2iW1bvGjUI+iLUaJW+fCmgKDWHrO8Dw9TdSmq6hN35N6MgSGtBxBHEa2HPQfRdbzP +82Z+ +-----END CERTIFICATE----- + +COMODO RSA Certification Authority +================================== +-----BEGIN CERTIFICATE----- +MIIF2DCCA8CgAwIBAgIQTKr5yttjb+Af907YWwOGnTANBgkqhkiG9w0BAQwFADCBhTELMAkGA1UE +BhMCR0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgG +A1UEChMRQ09NT0RPIENBIExpbWl0ZWQxKzApBgNVBAMTIkNPTU9ETyBSU0EgQ2VydGlmaWNhdGlv +biBBdXRob3JpdHkwHhcNMTAwMTE5MDAwMDAwWhcNMzgwMTE4MjM1OTU5WjCBhTELMAkGA1UEBhMC +R0IxGzAZBgNVBAgTEkdyZWF0ZXIgTWFuY2hlc3RlcjEQMA4GA1UEBxMHU2FsZm9yZDEaMBgGA1UE +ChMRQ09NT0RPIENBIExpbWl0ZWQxKzApBgNVBAMTIkNPTU9ETyBSU0EgQ2VydGlmaWNhdGlvbiBB +dXRob3JpdHkwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCR6FSS0gpWsawNJN3Fz0Rn +dJkrN6N9I3AAcbxT38T6KhKPS38QVr2fcHK3YX/JSw8Xpz3jsARh7v8Rl8f0hj4K+j5c+ZPmNHrZ +FGvnnLOFoIJ6dq9xkNfs/Q36nGz637CC9BR++b7Epi9Pf5l/tfxnQ3K9DADWietrLNPtj5gcFKt+ +5eNu/Nio5JIk2kNrYrhV/erBvGy2i/MOjZrkm2xpmfh4SDBF1a3hDTxFYPwyllEnvGfDyi62a+pG +x8cgoLEfZd5ICLqkTqnyg0Y3hOvozIFIQ2dOciqbXL1MGyiKXCJ7tKuY2e7gUYPDCUZObT6Z+pUX +2nwzV0E8jVHtC7ZcryxjGt9XyD+86V3Em69FmeKjWiS0uqlWPc9vqv9JWL7wqP/0uK3pN/u6uPQL +OvnoQ0IeidiEyxPx2bvhiWC4jChWrBQdnArncevPDt09qZahSL0896+1DSJMwBGB7FY79tOi4lu3 +sgQiUpWAk2nojkxl8ZEDLXB0AuqLZxUpaVICu9ffUGpVRr+goyhhf3DQw6KqLCGqR84onAZFdr+C +GCe01a60y1Dma/RMhnEw6abfFobg2P9A3fvQQoh/ozM6LlweQRGBY84YcWsr7KaKtzFcOmpH4MN5 +WdYgGq/yapiqcrxXStJLnbsQ/LBMQeXtHT1eKJ2czL+zUdqnR+WEUwIDAQABo0IwQDAdBgNVHQ4E +FgQUu69+Aj36pvE8hI6t7jiY7NkyMtQwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8w +DQYJKoZIhvcNAQEMBQADggIBAArx1UaEt65Ru2yyTUEUAJNMnMvlwFTPoCWOAvn9sKIN9SCYPBMt +rFaisNZ+EZLpLrqeLppysb0ZRGxhNaKatBYSaVqM4dc+pBroLwP0rmEdEBsqpIt6xf4FpuHA1sj+ +nq6PK7o9mfjYcwlYRm6mnPTXJ9OV2jeDchzTc+CiR5kDOF3VSXkAKRzH7JsgHAckaVd4sjn8OoSg +tZx8jb8uk2IntznaFxiuvTwJaP+EmzzV1gsD41eeFPfR60/IvYcjt7ZJQ3mFXLrrkguhxuhoqEwW +sRqZCuhTLJK7oQkYdQxlqHvLI7cawiiFwxv/0Cti76R7CZGYZ4wUAc1oBmpjIXUDgIiKboHGhfKp +pC3n9KUkEEeDys30jXlYsQab5xoq2Z0B15R97QNKyvDb6KkBPvVWmckejkk9u+UJueBPSZI9FoJA +zMxZxuY67RIuaTxslbH9qh17f4a+Hg4yRvv7E491f0yLS0Zj/gA0QHDBw7mh3aZw4gSzQbzpgJHq +ZJx64SIDqZxubw5lT2yHh17zbqD5daWbQOhTsiedSrnAdyGN/4fy3ryM7xfft0kL0fJuMAsaDk52 +7RH89elWsn2/x20Kk4yl0MC2Hb46TpSi125sC8KKfPog88Tk5c0NqMuRkrF8hey1FGlmDoLnzc7I +LaZRfyHBNVOFBkpdn627G190 +-----END CERTIFICATE----- + +USERTrust RSA Certification Authority +===================================== +-----BEGIN CERTIFICATE----- +MIIF3jCCA8agAwIBAgIQAf1tMPyjylGoG7xkDjUDLTANBgkqhkiG9w0BAQwFADCBiDELMAkGA1UE +BhMCVVMxEzARBgNVBAgTCk5ldyBKZXJzZXkxFDASBgNVBAcTC0plcnNleSBDaXR5MR4wHAYDVQQK +ExVUaGUgVVNFUlRSVVNUIE5ldHdvcmsxLjAsBgNVBAMTJVVTRVJUcnVzdCBSU0EgQ2VydGlmaWNh +dGlvbiBBdXRob3JpdHkwHhcNMTAwMjAxMDAwMDAwWhcNMzgwMTE4MjM1OTU5WjCBiDELMAkGA1UE +BhMCVVMxEzARBgNVBAgTCk5ldyBKZXJzZXkxFDASBgNVBAcTC0plcnNleSBDaXR5MR4wHAYDVQQK +ExVUaGUgVVNFUlRSVVNUIE5ldHdvcmsxLjAsBgNVBAMTJVVTRVJUcnVzdCBSU0EgQ2VydGlmaWNh +dGlvbiBBdXRob3JpdHkwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCAEmUXNg7D2wiz +0KxXDXbtzSfTTK1Qg2HiqiBNCS1kCdzOiZ/MPans9s/B3PHTsdZ7NygRK0faOca8Ohm0X6a9fZ2j +Y0K2dvKpOyuR+OJv0OwWIJAJPuLodMkYtJHUYmTbf6MG8YgYapAiPLz+E/CHFHv25B+O1ORRxhFn +RghRy4YUVD+8M/5+bJz/Fp0YvVGONaanZshyZ9shZrHUm3gDwFA66Mzw3LyeTP6vBZY1H1dat//O ++T23LLb2VN3I5xI6Ta5MirdcmrS3ID3KfyI0rn47aGYBROcBTkZTmzNg95S+UzeQc0PzMsNT79uq +/nROacdrjGCT3sTHDN/hMq7MkztReJVni+49Vv4M0GkPGw/zJSZrM233bkf6c0Plfg6lZrEpfDKE +Y1WJxA3Bk1QwGROs0303p+tdOmw1XNtB1xLaqUkL39iAigmTYo61Zs8liM2EuLE/pDkP2QKe6xJM +lXzzawWpXhaDzLhn4ugTncxbgtNMs+1b/97lc6wjOy0AvzVVdAlJ2ElYGn+SNuZRkg7zJn0cTRe8 +yexDJtC/QV9AqURE9JnnV4eeUB9XVKg+/XRjL7FQZQnmWEIuQxpMtPAlR1n6BB6T1CZGSlCBst6+ +eLf8ZxXhyVeEHg9j1uliutZfVS7qXMYoCAQlObgOK6nyTJccBz8NUvXt7y+CDwIDAQABo0IwQDAd +BgNVHQ4EFgQUU3m/WqorSs9UgOHYm8Cd8rIDZsswDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQF +MAMBAf8wDQYJKoZIhvcNAQEMBQADggIBAFzUfA3P9wF9QZllDHPFUp/L+M+ZBn8b2kMVn54CVVeW +FPFSPCeHlCjtHzoBN6J2/FNQwISbxmtOuowhT6KOVWKR82kV2LyI48SqC/3vqOlLVSoGIG1VeCkZ +7l8wXEskEVX/JJpuXior7gtNn3/3ATiUFJVDBwn7YKnuHKsSjKCaXqeYalltiz8I+8jRRa8YFWSQ +Eg9zKC7F4iRO/Fjs8PRF/iKz6y+O0tlFYQXBl2+odnKPi4w2r78NBc5xjeambx9spnFixdjQg3IM +8WcRiQycE0xyNN+81XHfqnHd4blsjDwSXWXavVcStkNr/+XeTWYRUc+ZruwXtuhxkYzeSf7dNXGi +FSeUHM9h4ya7b6NnJSFd5t0dCy5oGzuCr+yDZ4XUmFF0sbmZgIn/f3gZXHlKYC6SQK5MNyosycdi +yA5d9zZbyuAlJQG03RoHnHcAP9Dc1ew91Pq7P8yF1m9/qS3fuQL39ZeatTXaw2ewh0qpKJ4jjv9c +J2vhsE/zB+4ALtRZh8tSQZXq9EfX7mRBVXyNWQKV3WKdwrnuWih0hKWbt5DHDAff9Yk2dDLWKMGw +sAvgnEzDHNb842m1R0aBL6KCq9NjRHDEjf8tM7qtj3u1cIiuPhnPQCjY/MiQu12ZIvVS5ljFH4gx +Q+6IHdfGjjxDah2nGN59PRbxYvnKkKj9 +-----END CERTIFICATE----- + +USERTrust ECC Certification Authority +===================================== +-----BEGIN CERTIFICATE----- +MIICjzCCAhWgAwIBAgIQXIuZxVqUxdJxVt7NiYDMJjAKBggqhkjOPQQDAzCBiDELMAkGA1UEBhMC +VVMxEzARBgNVBAgTCk5ldyBKZXJzZXkxFDASBgNVBAcTC0plcnNleSBDaXR5MR4wHAYDVQQKExVU +aGUgVVNFUlRSVVNUIE5ldHdvcmsxLjAsBgNVBAMTJVVTRVJUcnVzdCBFQ0MgQ2VydGlmaWNhdGlv +biBBdXRob3JpdHkwHhcNMTAwMjAxMDAwMDAwWhcNMzgwMTE4MjM1OTU5WjCBiDELMAkGA1UEBhMC +VVMxEzARBgNVBAgTCk5ldyBKZXJzZXkxFDASBgNVBAcTC0plcnNleSBDaXR5MR4wHAYDVQQKExVU +aGUgVVNFUlRSVVNUIE5ldHdvcmsxLjAsBgNVBAMTJVVTRVJUcnVzdCBFQ0MgQ2VydGlmaWNhdGlv +biBBdXRob3JpdHkwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAAQarFRaqfloI+d61SRvU8Za2EurxtW2 +0eZzca7dnNYMYf3boIkDuAUU7FfO7l0/4iGzzvfUinngo4N+LZfQYcTxmdwlkWOrfzCjtHDix6Ez +nPO/LlxTsV+zfTJ/ijTjeXmjQjBAMB0GA1UdDgQWBBQ64QmG1M8ZwpZ2dEl23OA1xmNjmjAOBgNV +HQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAKBggqhkjOPQQDAwNoADBlAjA2Z6EWCNzklwBB +HU6+4WMBzzuqQhFkoJ2UOQIReVx7Hfpkue4WQrO/isIJxOzksU0CMQDpKmFHjFJKS04YcPbWRNZu +9YO6bVi9JNlWSOrvxKJGgYhqOkbRqZtNyWHa0V1Xahg= +-----END CERTIFICATE----- + +GlobalSign ECC Root CA - R4 +=========================== +-----BEGIN CERTIFICATE----- +MIIB4TCCAYegAwIBAgIRKjikHJYKBN5CsiilC+g0mAIwCgYIKoZIzj0EAwIwUDEkMCIGA1UECxMb +R2xvYmFsU2lnbiBFQ0MgUm9vdCBDQSAtIFI0MRMwEQYDVQQKEwpHbG9iYWxTaWduMRMwEQYDVQQD +EwpHbG9iYWxTaWduMB4XDTEyMTExMzAwMDAwMFoXDTM4MDExOTAzMTQwN1owUDEkMCIGA1UECxMb +R2xvYmFsU2lnbiBFQ0MgUm9vdCBDQSAtIFI0MRMwEQYDVQQKEwpHbG9iYWxTaWduMRMwEQYDVQQD +EwpHbG9iYWxTaWduMFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEuMZ5049sJQ6fLjkZHAOkrprl +OQcJFspjsbmG+IpXwVfOQvpzofdlQv8ewQCybnMO/8ch5RikqtlxP6jUuc6MHaNCMEAwDgYDVR0P +AQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYEFFSwe61FuOJAf/sKbvu+M8k8o4TV +MAoGCCqGSM49BAMCA0gAMEUCIQDckqGgE6bPA7DmxCGXkPoUVy0D7O48027KqGx2vKLeuwIgJ6iF +JzWbVsaj8kfSt24bAgAXqmemFZHe+pTsewv4n4Q= +-----END CERTIFICATE----- + +GlobalSign ECC Root CA - R5 +=========================== +-----BEGIN CERTIFICATE----- +MIICHjCCAaSgAwIBAgIRYFlJ4CYuu1X5CneKcflK2GwwCgYIKoZIzj0EAwMwUDEkMCIGA1UECxMb +R2xvYmFsU2lnbiBFQ0MgUm9vdCBDQSAtIFI1MRMwEQYDVQQKEwpHbG9iYWxTaWduMRMwEQYDVQQD +EwpHbG9iYWxTaWduMB4XDTEyMTExMzAwMDAwMFoXDTM4MDExOTAzMTQwN1owUDEkMCIGA1UECxMb +R2xvYmFsU2lnbiBFQ0MgUm9vdCBDQSAtIFI1MRMwEQYDVQQKEwpHbG9iYWxTaWduMRMwEQYDVQQD +EwpHbG9iYWxTaWduMHYwEAYHKoZIzj0CAQYFK4EEACIDYgAER0UOlvt9Xb/pOdEh+J8LttV7HpI6 +SFkc8GIxLcB6KP4ap1yztsyX50XUWPrRd21DosCHZTQKH3rd6zwzocWdTaRvQZU4f8kehOvRnkmS +h5SHDDqFSmafnVmTTZdhBoZKo0IwQDAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAd +BgNVHQ4EFgQUPeYpSJvqB8ohREom3m7e0oPQn1kwCgYIKoZIzj0EAwMDaAAwZQIxAOVpEslu28Yx +uglB4Zf4+/2a4n0Sye18ZNPLBSWLVtmg515dTguDnFt2KaAJJiFqYgIwcdK1j1zqO+F4CYWodZI7 +yFz9SO8NdCKoCOJuxUnOxwy8p2Fp8fc74SrL+SvzZpA3 +-----END CERTIFICATE----- + +Staat der Nederlanden Root CA - G3 +================================== +-----BEGIN CERTIFICATE----- +MIIFdDCCA1ygAwIBAgIEAJiiOTANBgkqhkiG9w0BAQsFADBaMQswCQYDVQQGEwJOTDEeMBwGA1UE +CgwVU3RhYXQgZGVyIE5lZGVybGFuZGVuMSswKQYDVQQDDCJTdGFhdCBkZXIgTmVkZXJsYW5kZW4g +Um9vdCBDQSAtIEczMB4XDTEzMTExNDExMjg0MloXDTI4MTExMzIzMDAwMFowWjELMAkGA1UEBhMC +TkwxHjAcBgNVBAoMFVN0YWF0IGRlciBOZWRlcmxhbmRlbjErMCkGA1UEAwwiU3RhYXQgZGVyIE5l +ZGVybGFuZGVuIFJvb3QgQ0EgLSBHMzCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAL4y +olQPcPssXFnrbMSkUeiFKrPMSjTysF/zDsccPVMeiAho2G89rcKezIJnByeHaHE6n3WWIkYFsO2t +x1ueKt6c/DrGlaf1F2cY5y9JCAxcz+bMNO14+1Cx3Gsy8KL+tjzk7FqXxz8ecAgwoNzFs21v0IJy +EavSgWhZghe3eJJg+szeP4TrjTgzkApyI/o1zCZxMdFyKJLZWyNtZrVtB0LrpjPOktvA9mxjeM3K +Tj215VKb8b475lRgsGYeCasH/lSJEULR9yS6YHgamPfJEf0WwTUaVHXvQ9Plrk7O53vDxk5hUUur +mkVLoR9BvUhTFXFkC4az5S6+zqQbwSmEorXLCCN2QyIkHxcE1G6cxvx/K2Ya7Irl1s9N9WMJtxU5 +1nus6+N86U78dULI7ViVDAZCopz35HCz33JvWjdAidiFpNfxC95DGdRKWCyMijmev4SH8RY7Ngzp +07TKbBlBUgmhHbBqv4LvcFEhMtwFdozL92TkA1CvjJFnq8Xy7ljY3r735zHPbMk7ccHViLVlvMDo +FxcHErVc0qsgk7TmgoNwNsXNo42ti+yjwUOH5kPiNL6VizXtBznaqB16nzaeErAMZRKQFWDZJkBE +41ZgpRDUajz9QdwOWke275dhdU/Z/seyHdTtXUmzqWrLZoQT1Vyg3N9udwbRcXXIV2+vD3dbAgMB +AAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgEGMB0GA1UdDgQWBBRUrfrHkleu +yjWcLhL75LpdINyUVzANBgkqhkiG9w0BAQsFAAOCAgEAMJmdBTLIXg47mAE6iqTnB/d6+Oea31BD +U5cqPco8R5gu4RV78ZLzYdqQJRZlwJ9UXQ4DO1t3ApyEtg2YXzTdO2PCwyiBwpwpLiniyMMB8jPq +KqrMCQj3ZWfGzd/TtiunvczRDnBfuCPRy5FOCvTIeuXZYzbB1N/8Ipf3YF3qKS9Ysr1YvY2WTxB1 +v0h7PVGHoTx0IsL8B3+A3MSs/mrBcDCw6Y5p4ixpgZQJut3+TcCDjJRYwEYgr5wfAvg1VUkvRtTA +8KCWAg8zxXHzniN9lLf9OtMJgwYh/WA9rjLA0u6NpvDntIJ8CsxwyXmA+P5M9zWEGYox+wrZ13+b +8KKaa8MFSu1BYBQw0aoRQm7TIwIEC8Zl3d1Sd9qBa7Ko+gE4uZbqKmxnl4mUnrzhVNXkanjvSr0r +mj1AfsbAddJu+2gw7OyLnflJNZoaLNmzlTnVHpL3prllL+U9bTpITAjc5CgSKL59NVzq4BZ+Extq +1z7XnvwtdbLBFNUjA9tbbws+eC8N3jONFrdI54OagQ97wUNNVQQXOEpR1VmiiXTTn74eS9fGbbeI +JG9gkaSChVtWQbzQRKtqE77RLFi3EjNYsjdj3BP1lB0/QFH1T/U67cjF68IeHRaVesd+QnGTbksV +tzDfqu1XhUisHWrdOWnk4Xl4vs4Fv6EM94B7IWcnMFk= +-----END CERTIFICATE----- + +Staat der Nederlanden EV Root CA +================================ +-----BEGIN CERTIFICATE----- +MIIFcDCCA1igAwIBAgIEAJiWjTANBgkqhkiG9w0BAQsFADBYMQswCQYDVQQGEwJOTDEeMBwGA1UE +CgwVU3RhYXQgZGVyIE5lZGVybGFuZGVuMSkwJwYDVQQDDCBTdGFhdCBkZXIgTmVkZXJsYW5kZW4g +RVYgUm9vdCBDQTAeFw0xMDEyMDgxMTE5MjlaFw0yMjEyMDgxMTEwMjhaMFgxCzAJBgNVBAYTAk5M +MR4wHAYDVQQKDBVTdGFhdCBkZXIgTmVkZXJsYW5kZW4xKTAnBgNVBAMMIFN0YWF0IGRlciBOZWRl +cmxhbmRlbiBFViBSb290IENBMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEA48d+ifkk +SzrSM4M1LGns3Amk41GoJSt5uAg94JG6hIXGhaTK5skuU6TJJB79VWZxXSzFYGgEt9nCUiY4iKTW +O0Cmws0/zZiTs1QUWJZV1VD+hq2kY39ch/aO5ieSZxeSAgMs3NZmdO3dZ//BYY1jTw+bbRcwJu+r +0h8QoPnFfxZpgQNH7R5ojXKhTbImxrpsX23Wr9GxE46prfNeaXUmGD5BKyF/7otdBwadQ8QpCiv8 +Kj6GyzyDOvnJDdrFmeK8eEEzduG/L13lpJhQDBXd4Pqcfzho0LKmeqfRMb1+ilgnQ7O6M5HTp5gV +XJrm0w912fxBmJc+qiXbj5IusHsMX/FjqTf5m3VpTCgmJdrV8hJwRVXj33NeN/UhbJCONVrJ0yPr +08C+eKxCKFhmpUZtcALXEPlLVPxdhkqHz3/KRawRWrUgUY0viEeXOcDPusBCAUCZSCELa6fS/ZbV +0b5GnUngC6agIk440ME8MLxwjyx1zNDFjFE7PZQIZCZhfbnDZY8UnCHQqv0XcgOPvZuM5l5Tnrmd +74K74bzickFbIZTTRTeU0d8JOV3nI6qaHcptqAqGhYqCvkIH1vI4gnPah1vlPNOePqc7nvQDs/nx +fRN0Av+7oeX6AHkcpmZBiFxgV6YuCcS6/ZrPpx9Aw7vMWgpVSzs4dlG4Y4uElBbmVvMCAwEAAaNC +MEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFP6rAJCYniT8qcwa +ivsnuL8wbqg7MA0GCSqGSIb3DQEBCwUAA4ICAQDPdyxuVr5Os7aEAJSrR8kN0nbHhp8dB9O2tLsI +eK9p0gtJ3jPFrK3CiAJ9Brc1AsFgyb/E6JTe1NOpEyVa/m6irn0F3H3zbPB+po3u2dfOWBfoqSmu +c0iH55vKbimhZF8ZE/euBhD/UcabTVUlT5OZEAFTdfETzsemQUHSv4ilf0X8rLiltTMMgsT7B/Zq +5SWEXwbKwYY5EdtYzXc7LMJMD16a4/CrPmEbUCTCwPTxGfARKbalGAKb12NMcIxHowNDXLldRqAN +b/9Zjr7dn3LDWyvfjFvO5QxGbJKyCqNMVEIYFRIYvdr8unRu/8G2oGTYqV9Vrp9canaW2HNnh/tN +f1zuacpzEPuKqf2evTY4SUmH9A4U8OmHuD+nT3pajnnUk+S7aFKErGzp85hwVXIy+TSrK0m1zSBi +5Dp6Z2Orltxtrpfs/J92VoguZs9btsmksNcFuuEnL5O7Jiqik7Ab846+HUCjuTaPPoIaGl6I6lD4 +WeKDRikL40Rc4ZW2aZCaFG+XroHPaO+Zmr615+F/+PoTRxZMzG0IQOeLeG9QgkRQP2YGiqtDhFZK +DyAthg710tvSeopLzaXoTvFeJiUBWSOgftL2fiFX1ye8FVdMpEbB4IMeDExNH08GGeL5qPQ6gqGy +eUN51q1veieQA6TqJIc/2b3Z6fJfUEkc7uzXLg== +-----END CERTIFICATE----- + +IdenTrust Commercial Root CA 1 +============================== +-----BEGIN CERTIFICATE----- +MIIFYDCCA0igAwIBAgIQCgFCgAAAAUUjyES1AAAAAjANBgkqhkiG9w0BAQsFADBKMQswCQYDVQQG +EwJVUzESMBAGA1UEChMJSWRlblRydXN0MScwJQYDVQQDEx5JZGVuVHJ1c3QgQ29tbWVyY2lhbCBS +b290IENBIDEwHhcNMTQwMTE2MTgxMjIzWhcNMzQwMTE2MTgxMjIzWjBKMQswCQYDVQQGEwJVUzES +MBAGA1UEChMJSWRlblRydXN0MScwJQYDVQQDEx5JZGVuVHJ1c3QgQ29tbWVyY2lhbCBSb290IENB +IDEwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCnUBneP5k91DNG8W9RYYKyqU+PZ4ld +hNlT3Qwo2dfw/66VQ3KZ+bVdfIrBQuExUHTRgQ18zZshq0PirK1ehm7zCYofWjK9ouuU+ehcCuz/ +mNKvcbO0U59Oh++SvL3sTzIwiEsXXlfEU8L2ApeN2WIrvyQfYo3fw7gpS0l4PJNgiCL8mdo2yMKi +1CxUAGc1bnO/AljwpN3lsKImesrgNqUZFvX9t++uP0D1bVoE/c40yiTcdCMbXTMTEl3EASX2MN0C +XZ/g1Ue9tOsbobtJSdifWwLziuQkkORiT0/Br4sOdBeo0XKIanoBScy0RnnGF7HamB4HWfp1IYVl +3ZBWzvurpWCdxJ35UrCLvYf5jysjCiN2O/cz4ckA82n5S6LgTrx+kzmEB/dEcH7+B1rlsazRGMzy +NeVJSQjKVsk9+w8YfYs7wRPCTY/JTw436R+hDmrfYi7LNQZReSzIJTj0+kuniVyc0uMNOYZKdHzV +WYfCP04MXFL0PfdSgvHqo6z9STQaKPNBiDoT7uje/5kdX7rL6B7yuVBgwDHTc+XvvqDtMwt0viAg +xGds8AgDelWAf0ZOlqf0Hj7h9tgJ4TNkK2PXMl6f+cB7D3hvl7yTmvmcEpB4eoCHFddydJxVdHix +uuFucAS6T6C6aMN7/zHwcz09lCqxC0EOoP5NiGVreTO01wIDAQABo0IwQDAOBgNVHQ8BAf8EBAMC +AQYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQU7UQZwNPwBovupHu+QucmVMiONnYwDQYJKoZI +hvcNAQELBQADggIBAA2ukDL2pkt8RHYZYR4nKM1eVO8lvOMIkPkp165oCOGUAFjvLi5+U1KMtlwH +6oi6mYtQlNeCgN9hCQCTrQ0U5s7B8jeUeLBfnLOic7iPBZM4zY0+sLj7wM+x8uwtLRvM7Kqas6pg +ghstO8OEPVeKlh6cdbjTMM1gCIOQ045U8U1mwF10A0Cj7oV+wh93nAbowacYXVKV7cndJZ5t+qnt +ozo00Fl72u1Q8zW/7esUTTHHYPTa8Yec4kjixsU3+wYQ+nVZZjFHKdp2mhzpgq7vmrlR94gjmmmV +YjzlVYA211QC//G5Xc7UI2/YRYRKW2XviQzdFKcgyxilJbQN+QHwotL0AMh0jqEqSI5l2xPE4iUX +feu+h1sXIFRRk0pTAwvsXcoz7WL9RccvW9xYoIA55vrX/hMUpu09lEpCdNTDd1lzzY9GvlU47/ro +kTLql1gEIt44w8y8bckzOmoKaT+gyOpyj4xjhiO9bTyWnpXgSUyqorkqG5w2gXjtw+hG4iZZRHUe +2XWJUc0QhJ1hYMtd+ZciTY6Y5uN/9lu7rs3KSoFrXgvzUeF0K+l+J6fZmUlO+KWA2yUPHGNiiskz +Z2s8EIPGrd6ozRaOjfAHN3Gf8qv8QfXBi+wAN10J5U6A7/qxXDgGpRtK4dw4LTzcqx+QGtVKnO7R +cGzM7vRX+Bi6hG6H +-----END CERTIFICATE----- + +IdenTrust Public Sector Root CA 1 +================================= +-----BEGIN CERTIFICATE----- +MIIFZjCCA06gAwIBAgIQCgFCgAAAAUUjz0Z8AAAAAjANBgkqhkiG9w0BAQsFADBNMQswCQYDVQQG +EwJVUzESMBAGA1UEChMJSWRlblRydXN0MSowKAYDVQQDEyFJZGVuVHJ1c3QgUHVibGljIFNlY3Rv +ciBSb290IENBIDEwHhcNMTQwMTE2MTc1MzMyWhcNMzQwMTE2MTc1MzMyWjBNMQswCQYDVQQGEwJV +UzESMBAGA1UEChMJSWRlblRydXN0MSowKAYDVQQDEyFJZGVuVHJ1c3QgUHVibGljIFNlY3RvciBS +b290IENBIDEwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC2IpT8pEiv6EdrCvsnduTy +P4o7ekosMSqMjbCpwzFrqHd2hCa2rIFCDQjrVVi7evi8ZX3yoG2LqEfpYnYeEe4IFNGyRBb06tD6 +Hi9e28tzQa68ALBKK0CyrOE7S8ItneShm+waOh7wCLPQ5CQ1B5+ctMlSbdsHyo+1W/CD80/HLaXI +rcuVIKQxKFdYWuSNG5qrng0M8gozOSI5Cpcu81N3uURF/YTLNiCBWS2ab21ISGHKTN9T0a9SvESf +qy9rg3LvdYDaBjMbXcjaY8ZNzaxmMc3R3j6HEDbhuaR672BQssvKplbgN6+rNBM5Jeg5ZuSYeqoS +mJxZZoY+rfGwyj4GD3vwEUs3oERte8uojHH01bWRNszwFcYr3lEXsZdMUD2xlVl8BX0tIdUAvwFn +ol57plzy9yLxkA2T26pEUWbMfXYD62qoKjgZl3YNa4ph+bz27nb9cCvdKTz4Ch5bQhyLVi9VGxyh +LrXHFub4qjySjmm2AcG1hp2JDws4lFTo6tyePSW8Uybt1as5qsVATFSrsrTZ2fjXctscvG29ZV/v +iDUqZi/u9rNl8DONfJhBaUYPQxxp+pu10GFqzcpL2UyQRqsVWaFHVCkugyhfHMKiq3IXAAaOReyL +4jM9f9oZRORicsPfIsbyVtTdX5Vy7W1f90gDW/3FKqD2cyOEEBsB5wIDAQABo0IwQDAOBgNVHQ8B +Af8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQU43HgntinQtnbcZFrlJPrw6PRFKMw +DQYJKoZIhvcNAQELBQADggIBAEf63QqwEZE4rU1d9+UOl1QZgkiHVIyqZJnYWv6IAcVYpZmxI1Qj +t2odIFflAWJBF9MJ23XLblSQdf4an4EKwt3X9wnQW3IV5B4Jaj0z8yGa5hV+rVHVDRDtfULAj+7A +mgjVQdZcDiFpboBhDhXAuM/FSRJSzL46zNQuOAXeNf0fb7iAaJg9TaDKQGXSc3z1i9kKlT/YPyNt +GtEqJBnZhbMX73huqVjRI9PHE+1yJX9dsXNw0H8GlwmEKYBhHfpe/3OsoOOJuBxxFcbeMX8S3OFt +m6/n6J91eEyrRjuazr8FGF1NFTwWmhlQBJqymm9li1JfPFgEKCXAZmExfrngdbkaqIHWchezxQMx +NRF4eKLg6TCMf4DfWN88uieW4oA0beOY02QnrEh+KHdcxiVhJfiFDGX6xDIvpZgF5PgLZxYWxoK4 +Mhn5+bl53B/N66+rDt0b20XkeucC4pVd/GnwU2lhlXV5C15V5jgclKlZM57IcXR5f1GJtshquDDI +ajjDbp7hNxbqBWJMWxJH7ae0s1hWx0nzfxJoCTFx8G34Tkf71oXuxVhAGaQdp/lLQzfcaFpPz+vC +ZHTetBXZ9FRUGi8c15dxVJCO2SCdUyt/q4/i6jC8UDfv8Ue1fXwsBOxonbRJRBD0ckscZOf85muQ +3Wl9af0AVqW3rLatt8o+Ae+c +-----END CERTIFICATE----- + +Entrust Root Certification Authority - G2 +========================================= +-----BEGIN CERTIFICATE----- +MIIEPjCCAyagAwIBAgIESlOMKDANBgkqhkiG9w0BAQsFADCBvjELMAkGA1UEBhMCVVMxFjAUBgNV +BAoTDUVudHJ1c3QsIEluYy4xKDAmBgNVBAsTH1NlZSB3d3cuZW50cnVzdC5uZXQvbGVnYWwtdGVy +bXMxOTA3BgNVBAsTMChjKSAyMDA5IEVudHJ1c3QsIEluYy4gLSBmb3IgYXV0aG9yaXplZCB1c2Ug +b25seTEyMDAGA1UEAxMpRW50cnVzdCBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IC0gRzIw +HhcNMDkwNzA3MTcyNTU0WhcNMzAxMjA3MTc1NTU0WjCBvjELMAkGA1UEBhMCVVMxFjAUBgNVBAoT +DUVudHJ1c3QsIEluYy4xKDAmBgNVBAsTH1NlZSB3d3cuZW50cnVzdC5uZXQvbGVnYWwtdGVybXMx +OTA3BgNVBAsTMChjKSAyMDA5IEVudHJ1c3QsIEluYy4gLSBmb3IgYXV0aG9yaXplZCB1c2Ugb25s +eTEyMDAGA1UEAxMpRW50cnVzdCBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IC0gRzIwggEi +MA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQC6hLZy254Ma+KZ6TABp3bqMriVQRrJ2mFOWHLP +/vaCeb9zYQYKpSfYs1/TRU4cctZOMvJyig/3gxnQaoCAAEUesMfnmr8SVycco2gvCoe9amsOXmXz +HHfV1IWNcCG0szLni6LVhjkCsbjSR87kyUnEO6fe+1R9V77w6G7CebI6C1XiUJgWMhNcL3hWwcKU +s/Ja5CeanyTXxuzQmyWC48zCxEXFjJd6BmsqEZ+pCm5IO2/b1BEZQvePB7/1U1+cPvQXLOZprE4y +TGJ36rfo5bs0vBmLrpxR57d+tVOxMyLlbc9wPBr64ptntoP0jaWvYkxN4FisZDQSA/i2jZRjJKRx +AgMBAAGjQjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBRqciZ6 +0B7vfec7aVHUbI2fkBJmqzANBgkqhkiG9w0BAQsFAAOCAQEAeZ8dlsa2eT8ijYfThwMEYGprmi5Z +iXMRrEPR9RP/jTkrwPK9T3CMqS/qF8QLVJ7UG5aYMzyorWKiAHarWWluBh1+xLlEjZivEtRh2woZ +Rkfz6/djwUAFQKXSt/S1mja/qYh2iARVBCuch38aNzx+LaUa2NSJXsq9rD1s2G2v1fN2D807iDgi +nWyTmsQ9v4IbZT+mD12q/OWyFcq1rca8PdCE6OoGcrBNOTJ4vz4RnAuknZoh8/CbCzB428Hch0P+ +vGOaysXCHMnHjf87ElgI5rY97HosTvuDls4MPGmHVHOkc8KT/1EQrBVUAdj8BbGJoX90g5pJ19xO +e4pIb4tF9g== +-----END CERTIFICATE----- + +Entrust Root Certification Authority - EC1 +========================================== +-----BEGIN CERTIFICATE----- +MIIC+TCCAoCgAwIBAgINAKaLeSkAAAAAUNCR+TAKBggqhkjOPQQDAzCBvzELMAkGA1UEBhMCVVMx +FjAUBgNVBAoTDUVudHJ1c3QsIEluYy4xKDAmBgNVBAsTH1NlZSB3d3cuZW50cnVzdC5uZXQvbGVn +YWwtdGVybXMxOTA3BgNVBAsTMChjKSAyMDEyIEVudHJ1c3QsIEluYy4gLSBmb3IgYXV0aG9yaXpl +ZCB1c2Ugb25seTEzMDEGA1UEAxMqRW50cnVzdCBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5 +IC0gRUMxMB4XDTEyMTIxODE1MjUzNloXDTM3MTIxODE1NTUzNlowgb8xCzAJBgNVBAYTAlVTMRYw +FAYDVQQKEw1FbnRydXN0LCBJbmMuMSgwJgYDVQQLEx9TZWUgd3d3LmVudHJ1c3QubmV0L2xlZ2Fs +LXRlcm1zMTkwNwYDVQQLEzAoYykgMjAxMiBFbnRydXN0LCBJbmMuIC0gZm9yIGF1dGhvcml6ZWQg +dXNlIG9ubHkxMzAxBgNVBAMTKkVudHJ1c3QgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSAt +IEVDMTB2MBAGByqGSM49AgEGBSuBBAAiA2IABIQTydC6bUF74mzQ61VfZgIaJPRbiWlH47jCffHy +AsWfoPZb1YsGGYZPUxBtByQnoaD41UcZYUx9ypMn6nQM72+WCf5j7HBdNq1nd67JnXxVRDqiY1Ef +9eNi1KlHBz7MIKNCMEAwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0OBBYE +FLdj5xrdjekIplWDpOBqUEFlEUJJMAoGCCqGSM49BAMDA2cAMGQCMGF52OVCR98crlOZF7ZvHH3h +vxGU0QOIdeSNiaSKd0bebWHvAvX7td/M/k7//qnmpwIwW5nXhTcGtXsI/esni0qU+eH6p44mCOh8 +kmhtc9hvJqwhAriZtyZBWyVgrtBIGu4G +-----END CERTIFICATE----- + +CFCA EV ROOT +============ +-----BEGIN CERTIFICATE----- +MIIFjTCCA3WgAwIBAgIEGErM1jANBgkqhkiG9w0BAQsFADBWMQswCQYDVQQGEwJDTjEwMC4GA1UE +CgwnQ2hpbmEgRmluYW5jaWFsIENlcnRpZmljYXRpb24gQXV0aG9yaXR5MRUwEwYDVQQDDAxDRkNB +IEVWIFJPT1QwHhcNMTIwODA4MDMwNzAxWhcNMjkxMjMxMDMwNzAxWjBWMQswCQYDVQQGEwJDTjEw +MC4GA1UECgwnQ2hpbmEgRmluYW5jaWFsIENlcnRpZmljYXRpb24gQXV0aG9yaXR5MRUwEwYDVQQD +DAxDRkNBIEVWIFJPT1QwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDXXWvNED8fBVnV +BU03sQ7smCuOFR36k0sXgiFxEFLXUWRwFsJVaU2OFW2fvwwbwuCjZ9YMrM8irq93VCpLTIpTUnrD +7i7es3ElweldPe6hL6P3KjzJIx1qqx2hp/Hz7KDVRM8Vz3IvHWOX6Jn5/ZOkVIBMUtRSqy5J35DN +uF++P96hyk0g1CXohClTt7GIH//62pCfCqktQT+x8Rgp7hZZLDRJGqgG16iI0gNyejLi6mhNbiyW +ZXvKWfry4t3uMCz7zEasxGPrb382KzRzEpR/38wmnvFyXVBlWY9ps4deMm/DGIq1lY+wejfeWkU7 +xzbh72fROdOXW3NiGUgthxwG+3SYIElz8AXSG7Ggo7cbcNOIabla1jj0Ytwli3i/+Oh+uFzJlU9f +py25IGvPa931DfSCt/SyZi4QKPaXWnuWFo8BGS1sbn85WAZkgwGDg8NNkt0yxoekN+kWzqotaK8K +gWU6cMGbrU1tVMoqLUuFG7OA5nBFDWteNfB/O7ic5ARwiRIlk9oKmSJgamNgTnYGmE69g60dWIol +hdLHZR4tjsbftsbhf4oEIRUpdPA+nJCdDC7xij5aqgwJHsfVPKPtl8MeNPo4+QgO48BdK4PRVmrJ +tqhUUy54Mmc9gn900PvhtgVguXDbjgv5E1hvcWAQUhC5wUEJ73IfZzF4/5YFjQIDAQABo2MwYTAf +BgNVHSMEGDAWgBTj/i39KNALtbq2osS/BqoFjJP7LzAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB +/wQEAwIBBjAdBgNVHQ4EFgQU4/4t/SjQC7W6tqLEvwaqBYyT+y8wDQYJKoZIhvcNAQELBQADggIB +ACXGumvrh8vegjmWPfBEp2uEcwPenStPuiB/vHiyz5ewG5zz13ku9Ui20vsXiObTej/tUxPQ4i9q +ecsAIyjmHjdXNYmEwnZPNDatZ8POQQaIxffu2Bq41gt/UP+TqhdLjOztUmCypAbqTuv0axn96/Ua +4CUqmtzHQTb3yHQFhDmVOdYLO6Qn+gjYXB74BGBSESgoA//vU2YApUo0FmZ8/Qmkrp5nGm9BC2sG +E5uPhnEFtC+NiWYzKXZUmhH4J/qyP5Hgzg0b8zAarb8iXRvTvyUFTeGSGn+ZnzxEk8rUQElsgIfX +BDrDMlI1Dlb4pd19xIsNER9Tyx6yF7Zod1rg1MvIB671Oi6ON7fQAUtDKXeMOZePglr4UeWJoBjn +aH9dCi77o0cOPaYjesYBx4/IXr9tgFa+iiS6M+qf4TIRnvHST4D2G0CvOJ4RUHlzEhLN5mydLIhy +PDCBBpEi6lmt2hkuIsKNuYyH4Ga8cyNfIWRjgEj1oDwYPZTISEEdQLpe/v5WOaHIz16eGWRGENoX +kbcFgKyLmZJ956LYBws2J+dIeWCKw9cTXPhyQN9Ky8+ZAAoACxGV2lZFA4gKn2fQ1XmxqI1AbQ3C +ekD6819kR5LLU7m7Wc5P/dAVUwHY3+vZ5nbv0CO7O6l5s9UCKc2Jo5YPSjXnTkLAdc0Hz+Ys63su +-----END CERTIFICATE----- + +OISTE WISeKey Global Root GB CA +=============================== +-----BEGIN CERTIFICATE----- +MIIDtTCCAp2gAwIBAgIQdrEgUnTwhYdGs/gjGvbCwDANBgkqhkiG9w0BAQsFADBtMQswCQYDVQQG +EwJDSDEQMA4GA1UEChMHV0lTZUtleTEiMCAGA1UECxMZT0lTVEUgRm91bmRhdGlvbiBFbmRvcnNl +ZDEoMCYGA1UEAxMfT0lTVEUgV0lTZUtleSBHbG9iYWwgUm9vdCBHQiBDQTAeFw0xNDEyMDExNTAw +MzJaFw0zOTEyMDExNTEwMzFaMG0xCzAJBgNVBAYTAkNIMRAwDgYDVQQKEwdXSVNlS2V5MSIwIAYD +VQQLExlPSVNURSBGb3VuZGF0aW9uIEVuZG9yc2VkMSgwJgYDVQQDEx9PSVNURSBXSVNlS2V5IEds +b2JhbCBSb290IEdCIENBMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA2Be3HEokKtaX +scriHvt9OO+Y9bI5mE4nuBFde9IllIiCFSZqGzG7qFshISvYD06fWvGxWuR51jIjK+FTzJlFXHtP +rby/h0oLS5daqPZI7H17Dc0hBt+eFf1Biki3IPShehtX1F1Q/7pn2COZH8g/497/b1t3sWtuuMlk +9+HKQUYOKXHQuSP8yYFfTvdv37+ErXNku7dCjmn21HYdfp2nuFeKUWdy19SouJVUQHMD9ur06/4o +Qnc/nSMbsrY9gBQHTC5P99UKFg29ZkM3fiNDecNAhvVMKdqOmq0NpQSHiB6F4+lT1ZvIiwNjeOvg +GUpuuy9rM2RYk61pv48b74JIxwIDAQABo1EwTzALBgNVHQ8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB +/zAdBgNVHQ4EFgQUNQ/INmNe4qPs+TtmFc5RUuORmj0wEAYJKwYBBAGCNxUBBAMCAQAwDQYJKoZI +hvcNAQELBQADggEBAEBM+4eymYGQfp3FsLAmzYh7KzKNbrghcViXfa43FK8+5/ea4n32cZiZBKpD +dHij40lhPnOMTZTg+XHEthYOU3gf1qKHLwI5gSk8rxWYITD+KJAAjNHhy/peyP34EEY7onhCkRd0 +VQreUGdNZtGn//3ZwLWoo4rOZvUPQ82nK1d7Y0Zqqi5S2PTt4W2tKZB4SLrhI6qjiey1q5bAtEui +HZeeevJuQHHfaPFlTc58Bd9TZaml8LGXBHAVRgOY1NK/VLSgWH1Sb9pWJmLU2NuJMW8c8CLC02Ic +Nc1MaRVUGpCY3useX8p3x8uOPUNpnJpY0CQ73xtAln41rYHHTnG6iBM= +-----END CERTIFICATE----- + +SZAFIR ROOT CA2 +=============== +-----BEGIN CERTIFICATE----- +MIIDcjCCAlqgAwIBAgIUPopdB+xV0jLVt+O2XwHrLdzk1uQwDQYJKoZIhvcNAQELBQAwUTELMAkG +A1UEBhMCUEwxKDAmBgNVBAoMH0tyYWpvd2EgSXpiYSBSb3psaWN6ZW5pb3dhIFMuQS4xGDAWBgNV +BAMMD1NaQUZJUiBST09UIENBMjAeFw0xNTEwMTkwNzQzMzBaFw0zNTEwMTkwNzQzMzBaMFExCzAJ +BgNVBAYTAlBMMSgwJgYDVQQKDB9LcmFqb3dhIEl6YmEgUm96bGljemVuaW93YSBTLkEuMRgwFgYD +VQQDDA9TWkFGSVIgUk9PVCBDQTIwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQC3vD5Q +qEvNQLXOYeeWyrSh2gwisPq1e3YAd4wLz32ohswmUeQgPYUM1ljj5/QqGJ3a0a4m7utT3PSQ1hNK +DJA8w/Ta0o4NkjrcsbH/ON7Dui1fgLkCvUqdGw+0w8LBZwPd3BucPbOw3gAeqDRHu5rr/gsUvTaE +2g0gv/pby6kWIK05YO4vdbbnl5z5Pv1+TW9NL++IDWr63fE9biCloBK0TXC5ztdyO4mTp4CEHCdJ +ckm1/zuVnsHMyAHs6A6KCpbns6aH5db5BSsNl0BwPLqsdVqc1U2dAgrSS5tmS0YHF2Wtn2yIANwi +ieDhZNRnvDF5YTy7ykHNXGoAyDw4jlivAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0P +AQH/BAQDAgEGMB0GA1UdDgQWBBQuFqlKGLXLzPVvUPMjX/hd56zwyDANBgkqhkiG9w0BAQsFAAOC +AQEAtXP4A9xZWx126aMqe5Aosk3AM0+qmrHUuOQn/6mWmc5G4G18TKI4pAZw8PRBEew/R40/cof5 +O/2kbytTAOD/OblqBw7rHRz2onKQy4I9EYKL0rufKq8h5mOGnXkZ7/e7DDWQw4rtTw/1zBLZpD67 +oPwglV9PJi8RI4NOdQcPv5vRtB3pEAT+ymCPoky4rc/hkA/NrgrHXXu3UNLUYfrVFdvXn4dRVOul +4+vJhaAlIDf7js4MNIThPIGyd05DpYhfhmehPea0XGG2Ptv+tyjFogeutcrKjSoS75ftwjCkySp6 ++/NNIxuZMzSgLvWpCz/UXeHPhJ/iGcJfitYgHuNztw== +-----END CERTIFICATE----- + +Certum Trusted Network CA 2 +=========================== +-----BEGIN CERTIFICATE----- +MIIF0jCCA7qgAwIBAgIQIdbQSk8lD8kyN/yqXhKN6TANBgkqhkiG9w0BAQ0FADCBgDELMAkGA1UE +BhMCUEwxIjAgBgNVBAoTGVVuaXpldG8gVGVjaG5vbG9naWVzIFMuQS4xJzAlBgNVBAsTHkNlcnR1 +bSBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eTEkMCIGA1UEAxMbQ2VydHVtIFRydXN0ZWQgTmV0d29y +ayBDQSAyMCIYDzIwMTExMDA2MDgzOTU2WhgPMjA0NjEwMDYwODM5NTZaMIGAMQswCQYDVQQGEwJQ +TDEiMCAGA1UEChMZVW5pemV0byBUZWNobm9sb2dpZXMgUy5BLjEnMCUGA1UECxMeQ2VydHVtIENl +cnRpZmljYXRpb24gQXV0aG9yaXR5MSQwIgYDVQQDExtDZXJ0dW0gVHJ1c3RlZCBOZXR3b3JrIENB +IDIwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC9+Xj45tWADGSdhhuWZGc/IjoedQF9 +7/tcZ4zJzFxrqZHmuULlIEub2pt7uZld2ZuAS9eEQCsn0+i6MLs+CRqnSZXvK0AkwpfHp+6bJe+o +CgCXhVqqndwpyeI1B+twTUrWwbNWuKFBOJvR+zF/j+Bf4bE/D44WSWDXBo0Y+aomEKsq09DRZ40b +Rr5HMNUuctHFY9rnY3lEfktjJImGLjQ/KUxSiyqnwOKRKIm5wFv5HdnnJ63/mgKXwcZQkpsCLL2p +uTRZCr+ESv/f/rOf69me4Jgj7KZrdxYq28ytOxykh9xGc14ZYmhFV+SQgkK7QtbwYeDBoz1mo130 +GO6IyY0XRSmZMnUCMe4pJshrAua1YkV/NxVaI2iJ1D7eTiew8EAMvE0Xy02isx7QBlrd9pPPV3WZ +9fqGGmd4s7+W/jTcvedSVuWz5XV710GRBdxdaeOVDUO5/IOWOZV7bIBaTxNyxtd9KXpEulKkKtVB +Rgkg/iKgtlswjbyJDNXXcPiHUv3a76xRLgezTv7QCdpw75j6VuZt27VXS9zlLCUVyJ4ueE742pye +hizKV/Ma5ciSixqClnrDvFASadgOWkaLOusm+iPJtrCBvkIApPjW/jAux9JG9uWOdf3yzLnQh1vM +BhBgu4M1t15n3kfsmUjxpKEV/q2MYo45VU85FrmxY53/twIDAQABo0IwQDAPBgNVHRMBAf8EBTAD +AQH/MB0GA1UdDgQWBBS2oVQ5AsOgP46KvPrU+Bym0ToO/TAOBgNVHQ8BAf8EBAMCAQYwDQYJKoZI +hvcNAQENBQADggIBAHGlDs7k6b8/ONWJWsQCYftMxRQXLYtPU2sQF/xlhMcQSZDe28cmk4gmb3DW +Al45oPePq5a1pRNcgRRtDoGCERuKTsZPpd1iHkTfCVn0W3cLN+mLIMb4Ck4uWBzrM9DPhmDJ2vuA +L55MYIR4PSFk1vtBHxgP58l1cb29XN40hz5BsA72udY/CROWFC/emh1auVbONTqwX3BNXuMp8SMo +clm2q8KMZiYcdywmdjWLKKdpoPk79SPdhRB0yZADVpHnr7pH1BKXESLjokmUbOe3lEu6LaTaM4tM +pkT/WjzGHWTYtTHkpjx6qFcL2+1hGsvxznN3Y6SHb0xRONbkX8eftoEq5IVIeVheO/jbAoJnwTnb +w3RLPTYe+SmTiGhbqEQZIfCn6IENLOiTNrQ3ssqwGyZ6miUfmpqAnksqP/ujmv5zMnHCnsZy4Ypo +J/HkD7TETKVhk/iXEAcqMCWpuchxuO9ozC1+9eB+D4Kob7a6bINDd82Kkhehnlt4Fj1F4jNy3eFm +ypnTycUm/Q1oBEauttmbjL4ZvrHG8hnjXALKLNhvSgfZyTXaQHXyxKcZb55CEJh15pWLYLztxRLX +is7VmFxWlgPF7ncGNf/P5O4/E2Hu29othfDNrp2yGAlFw5Khchf8R7agCyzxxN5DaAhqXzvwdmP7 +zAYspsbiDrW5viSP +-----END CERTIFICATE----- + +Hellenic Academic and Research Institutions RootCA 2015 +======================================================= +-----BEGIN CERTIFICATE----- +MIIGCzCCA/OgAwIBAgIBADANBgkqhkiG9w0BAQsFADCBpjELMAkGA1UEBhMCR1IxDzANBgNVBAcT +BkF0aGVuczFEMEIGA1UEChM7SGVsbGVuaWMgQWNhZGVtaWMgYW5kIFJlc2VhcmNoIEluc3RpdHV0 +aW9ucyBDZXJ0LiBBdXRob3JpdHkxQDA+BgNVBAMTN0hlbGxlbmljIEFjYWRlbWljIGFuZCBSZXNl +YXJjaCBJbnN0aXR1dGlvbnMgUm9vdENBIDIwMTUwHhcNMTUwNzA3MTAxMTIxWhcNNDAwNjMwMTAx +MTIxWjCBpjELMAkGA1UEBhMCR1IxDzANBgNVBAcTBkF0aGVuczFEMEIGA1UEChM7SGVsbGVuaWMg +QWNhZGVtaWMgYW5kIFJlc2VhcmNoIEluc3RpdHV0aW9ucyBDZXJ0LiBBdXRob3JpdHkxQDA+BgNV +BAMTN0hlbGxlbmljIEFjYWRlbWljIGFuZCBSZXNlYXJjaCBJbnN0aXR1dGlvbnMgUm9vdENBIDIw +MTUwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDC+Kk/G4n8PDwEXT2QNrCROnk8Zlrv +bTkBSRq0t89/TSNTt5AA4xMqKKYx8ZEA4yjsriFBzh/a/X0SWwGDD7mwX5nh8hKDgE0GPt+sr+eh +iGsxr/CL0BgzuNtFajT0AoAkKAoCFZVedioNmToUW/bLy1O8E00BiDeUJRtCvCLYjqOWXjrZMts+ +6PAQZe104S+nfK8nNLspfZu2zwnI5dMK/IhlZXQK3HMcXM1AsRzUtoSMTFDPaI6oWa7CJ06CojXd +FPQf/7J31Ycvqm59JCfnxssm5uX+Zwdj2EUN3TpZZTlYepKZcj2chF6IIbjV9Cz82XBST3i4vTwr +i5WY9bPRaM8gFH5MXF/ni+X1NYEZN9cRCLdmvtNKzoNXADrDgfgXy5I2XdGj2HUb4Ysn6npIQf1F +GQatJ5lOwXBH3bWfgVMS5bGMSF0xQxfjjMZ6Y5ZLKTBOhE5iGV48zpeQpX8B653g+IuJ3SWYPZK2 +fu/Z8VFRfS0myGlZYeCsargqNhEEelC9MoS+L9xy1dcdFkfkR2YgP/SWxa+OAXqlD3pk9Q0Yh9mu +iNX6hME6wGkoLfINaFGq46V3xqSQDqE3izEjR8EJCOtu93ib14L8hCCZSRm2Ekax+0VVFqmjZayc +Bw/qa9wfLgZy7IaIEuQt218FL+TwA9MmM+eAws1CoRc0CwIDAQABo0IwQDAPBgNVHRMBAf8EBTAD +AQH/MA4GA1UdDwEB/wQEAwIBBjAdBgNVHQ4EFgQUcRVnyMjJvXVdctA4GGqd83EkVAswDQYJKoZI +hvcNAQELBQADggIBAHW7bVRLqhBYRjTyYtcWNl0IXtVsyIe9tC5G8jH4fOpCtZMWVdyhDBKg2mF+ +D1hYc2Ryx+hFjtyp8iY/xnmMsVMIM4GwVhO+5lFc2JsKT0ucVlMC6U/2DWDqTUJV6HwbISHTGzrM +d/K4kPFox/la/vot9L/J9UUbzjgQKjeKeaO04wlshYaT/4mWJ3iBj2fjRnRUjtkNaeJK9E10A/+y +d+2VZ5fkscWrv2oj6NSU4kQoYsRL4vDY4ilrGnB+JGGTe08DMiUNRSQrlrRGar9KC/eaj8GsGsVn +82800vpzY4zvFrCopEYq+OsS7HK07/grfoxSwIuEVPkvPuNVqNxmsdnhX9izjFk0WaSrT2y7Hxjb +davYy5LNlDhhDgcGH0tGEPEVvo2FXDtKK4F5D7Rpn0lQl033DlZdwJVqwjbDG2jJ9SrcR5q+ss7F +Jej6A7na+RZukYT1HCjI/CbM1xyQVqdfbzoEvM14iQuODy+jqk+iGxI9FghAD/FGTNeqewjBCvVt +J94Cj8rDtSvK6evIIVM4pcw72Hc3MKJP2W/R8kCtQXoXxdZKNYm3QdV8hn9VTYNKpXMgwDqvkPGa +JI7ZjnHKe7iG2rKPmT4dEw0SEe7Uq/DpFXYC5ODfqiAeW2GFZECpkJcNrVPSWh2HagCXZWK0vm9q +p/UsQu0yrbYhnr68 +-----END CERTIFICATE----- + +Hellenic Academic and Research Institutions ECC RootCA 2015 +=========================================================== +-----BEGIN CERTIFICATE----- +MIICwzCCAkqgAwIBAgIBADAKBggqhkjOPQQDAjCBqjELMAkGA1UEBhMCR1IxDzANBgNVBAcTBkF0 +aGVuczFEMEIGA1UEChM7SGVsbGVuaWMgQWNhZGVtaWMgYW5kIFJlc2VhcmNoIEluc3RpdHV0aW9u +cyBDZXJ0LiBBdXRob3JpdHkxRDBCBgNVBAMTO0hlbGxlbmljIEFjYWRlbWljIGFuZCBSZXNlYXJj +aCBJbnN0aXR1dGlvbnMgRUNDIFJvb3RDQSAyMDE1MB4XDTE1MDcwNzEwMzcxMloXDTQwMDYzMDEw +MzcxMlowgaoxCzAJBgNVBAYTAkdSMQ8wDQYDVQQHEwZBdGhlbnMxRDBCBgNVBAoTO0hlbGxlbmlj +IEFjYWRlbWljIGFuZCBSZXNlYXJjaCBJbnN0aXR1dGlvbnMgQ2VydC4gQXV0aG9yaXR5MUQwQgYD +VQQDEztIZWxsZW5pYyBBY2FkZW1pYyBhbmQgUmVzZWFyY2ggSW5zdGl0dXRpb25zIEVDQyBSb290 +Q0EgMjAxNTB2MBAGByqGSM49AgEGBSuBBAAiA2IABJKgQehLgoRc4vgxEZmGZE4JJS+dQS8KrjVP +dJWyUWRrjWvmP3CV8AVER6ZyOFB2lQJajq4onvktTpnvLEhvTCUp6NFxW98dwXU3tNf6e3pCnGoK +Vlp8aQuqgAkkbH7BRqNCMEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0O +BBYEFLQiC4KZJAEOnLvkDv2/+5cgk5kqMAoGCCqGSM49BAMCA2cAMGQCMGfOFmI4oqxiRaeplSTA +GiecMjvAwNW6qef4BENThe5SId6d9SWDPp5YSy/XZxMOIQIwBeF1Ad5o7SofTUwJCA3sS61kFyjn +dc5FZXIhF8siQQ6ME5g4mlRtm8rifOoCWCKR +-----END CERTIFICATE----- + +ISRG Root X1 +============ +-----BEGIN CERTIFICATE----- +MIIFazCCA1OgAwIBAgIRAIIQz7DSQONZRGPgu2OCiwAwDQYJKoZIhvcNAQELBQAwTzELMAkGA1UE +BhMCVVMxKTAnBgNVBAoTIEludGVybmV0IFNlY3VyaXR5IFJlc2VhcmNoIEdyb3VwMRUwEwYDVQQD +EwxJU1JHIFJvb3QgWDEwHhcNMTUwNjA0MTEwNDM4WhcNMzUwNjA0MTEwNDM4WjBPMQswCQYDVQQG +EwJVUzEpMCcGA1UEChMgSW50ZXJuZXQgU2VjdXJpdHkgUmVzZWFyY2ggR3JvdXAxFTATBgNVBAMT +DElTUkcgUm9vdCBYMTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAK3oJHP0FDfzm54r +Vygch77ct984kIxuPOZXoHj3dcKi/vVqbvYATyjb3miGbESTtrFj/RQSa78f0uoxmyF+0TM8ukj1 +3Xnfs7j/EvEhmkvBioZxaUpmZmyPfjxwv60pIgbz5MDmgK7iS4+3mX6UA5/TR5d8mUgjU+g4rk8K +b4Mu0UlXjIB0ttov0DiNewNwIRt18jA8+o+u3dpjq+sWT8KOEUt+zwvo/7V3LvSye0rgTBIlDHCN +Aymg4VMk7BPZ7hm/ELNKjD+Jo2FR3qyHB5T0Y3HsLuJvW5iB4YlcNHlsdu87kGJ55tukmi8mxdAQ +4Q7e2RCOFvu396j3x+UCB5iPNgiV5+I3lg02dZ77DnKxHZu8A/lJBdiB3QW0KtZB6awBdpUKD9jf +1b0SHzUvKBds0pjBqAlkd25HN7rOrFleaJ1/ctaJxQZBKT5ZPt0m9STJEadao0xAH0ahmbWnOlFu +hjuefXKnEgV4We0+UXgVCwOPjdAvBbI+e0ocS3MFEvzG6uBQE3xDk3SzynTnjh8BCNAw1FtxNrQH +usEwMFxIt4I7mKZ9YIqioymCzLq9gwQbooMDQaHWBfEbwrbwqHyGO0aoSCqI3Haadr8faqU9GY/r +OPNk3sgrDQoo//fb4hVC1CLQJ13hef4Y53CIrU7m2Ys6xt0nUW7/vGT1M0NPAgMBAAGjQjBAMA4G +A1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBR5tFnme7bl5AFzgAiIyBpY +9umbbjANBgkqhkiG9w0BAQsFAAOCAgEAVR9YqbyyqFDQDLHYGmkgJykIrGF1XIpu+ILlaS/V9lZL +ubhzEFnTIZd+50xx+7LSYK05qAvqFyFWhfFQDlnrzuBZ6brJFe+GnY+EgPbk6ZGQ3BebYhtF8GaV +0nxvwuo77x/Py9auJ/GpsMiu/X1+mvoiBOv/2X/qkSsisRcOj/KKNFtY2PwByVS5uCbMiogziUwt +hDyC3+6WVwW6LLv3xLfHTjuCvjHIInNzktHCgKQ5ORAzI4JMPJ+GslWYHb4phowim57iaztXOoJw +TdwJx4nLCgdNbOhdjsnvzqvHu7UrTkXWStAmzOVyyghqpZXjFaH3pO3JLF+l+/+sKAIuvtd7u+Nx +e5AW0wdeRlN8NwdCjNPElpzVmbUq4JUagEiuTDkHzsxHpFKVK7q4+63SM1N95R1NbdWhscdCb+ZA +JzVcoyi3B43njTOQ5yOf+1CceWxG1bQVs5ZufpsMljq4Ui0/1lvh+wjChP4kqKOJ2qxq4RgqsahD +YVvTH9w7jXbyLeiNdd8XM2w9U/t7y0Ff/9yi0GE44Za4rF2LN9d11TPAmRGunUHBcnWEvgJBQl9n +JEiU0Zsnvgc/ubhPgXRR4Xq37Z0j4r7g1SgEEzwxA57demyPxgcYxn/eR44/KJ4EBs+lVDR3veyJ +m+kXQ99b21/+jh5Xos1AnX5iItreGCc= +-----END CERTIFICATE----- + +AC RAIZ FNMT-RCM +================ +-----BEGIN CERTIFICATE----- +MIIFgzCCA2ugAwIBAgIPXZONMGc2yAYdGsdUhGkHMA0GCSqGSIb3DQEBCwUAMDsxCzAJBgNVBAYT +AkVTMREwDwYDVQQKDAhGTk1ULVJDTTEZMBcGA1UECwwQQUMgUkFJWiBGTk1ULVJDTTAeFw0wODEw +MjkxNTU5NTZaFw0zMDAxMDEwMDAwMDBaMDsxCzAJBgNVBAYTAkVTMREwDwYDVQQKDAhGTk1ULVJD +TTEZMBcGA1UECwwQQUMgUkFJWiBGTk1ULVJDTTCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoC +ggIBALpxgHpMhm5/yBNtwMZ9HACXjywMI7sQmkCpGreHiPibVmr75nuOi5KOpyVdWRHbNi63URcf +qQgfBBckWKo3Shjf5TnUV/3XwSyRAZHiItQDwFj8d0fsjz50Q7qsNI1NOHZnjrDIbzAzWHFctPVr +btQBULgTfmxKo0nRIBnuvMApGGWn3v7v3QqQIecaZ5JCEJhfTzC8PhxFtBDXaEAUwED653cXeuYL +j2VbPNmaUtu1vZ5Gzz3rkQUCwJaydkxNEJY7kvqcfw+Z374jNUUeAlz+taibmSXaXvMiwzn15Cou +08YfxGyqxRxqAQVKL9LFwag0Jl1mpdICIfkYtwb1TplvqKtMUejPUBjFd8g5CSxJkjKZqLsXF3mw +WsXmo8RZZUc1g16p6DULmbvkzSDGm0oGObVo/CK67lWMK07q87Hj/LaZmtVC+nFNCM+HHmpxffnT +tOmlcYF7wk5HlqX2doWjKI/pgG6BU6VtX7hI+cL5NqYuSf+4lsKMB7ObiFj86xsc3i1w4peSMKGJ +47xVqCfWS+2QrYv6YyVZLag13cqXM7zlzced0ezvXg5KkAYmY6252TUtB7p2ZSysV4999AeU14EC +ll2jB0nVetBX+RvnU0Z1qrB5QstocQjpYL05ac70r8NWQMetUqIJ5G+GR4of6ygnXYMgrwTJbFaa +i0b1AgMBAAGjgYMwgYAwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYE +FPd9xf3E6Jobd2Sn9R2gzL+HYJptMD4GA1UdIAQ3MDUwMwYEVR0gADArMCkGCCsGAQUFBwIBFh1o +dHRwOi8vd3d3LmNlcnQuZm5tdC5lcy9kcGNzLzANBgkqhkiG9w0BAQsFAAOCAgEAB5BK3/MjTvDD +nFFlm5wioooMhfNzKWtN/gHiqQxjAb8EZ6WdmF/9ARP67Jpi6Yb+tmLSbkyU+8B1RXxlDPiyN8+s +D8+Nb/kZ94/sHvJwnvDKuO+3/3Y3dlv2bojzr2IyIpMNOmqOFGYMLVN0V2Ue1bLdI4E7pWYjJ2cJ +j+F3qkPNZVEI7VFY/uY5+ctHhKQV8Xa7pO6kO8Rf77IzlhEYt8llvhjho6Tc+hj507wTmzl6NLrT +Qfv6MooqtyuGC2mDOL7Nii4LcK2NJpLuHvUBKwrZ1pebbuCoGRw6IYsMHkCtA+fdZn71uSANA+iW ++YJF1DngoABd15jmfZ5nc8OaKveri6E6FO80vFIOiZiaBECEHX5FaZNXzuvO+FB8TxxuBEOb+dY7 +Ixjp6o7RTUaN8Tvkasq6+yO3m/qZASlaWFot4/nUbQ4mrcFuNLwy+AwF+mWj2zs3gyLp1txyM/1d +8iC9djwj2ij3+RvrWWTV3F9yfiD8zYm1kGdNYno/Tq0dwzn+evQoFt9B9kiABdcPUXmsEKvU7ANm +5mqwujGSQkBqvjrTcuFqN1W8rB2Vt2lh8kORdOag0wokRqEIr9baRRmW1FMdW4R58MD3R++Lj8UG +rp1MYp3/RgT408m2ECVAdf4WqslKYIYvuu8wd+RU4riEmViAqhOLUTpPSPaLtrM= +-----END CERTIFICATE----- + +Amazon Root CA 1 +================ +-----BEGIN CERTIFICATE----- +MIIDQTCCAimgAwIBAgITBmyfz5m/jAo54vB4ikPmljZbyjANBgkqhkiG9w0BAQsFADA5MQswCQYD +VQQGEwJVUzEPMA0GA1UEChMGQW1hem9uMRkwFwYDVQQDExBBbWF6b24gUm9vdCBDQSAxMB4XDTE1 +MDUyNjAwMDAwMFoXDTM4MDExNzAwMDAwMFowOTELMAkGA1UEBhMCVVMxDzANBgNVBAoTBkFtYXpv +bjEZMBcGA1UEAxMQQW1hem9uIFJvb3QgQ0EgMTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoC +ggEBALJ4gHHKeNXjca9HgFB0fW7Y14h29Jlo91ghYPl0hAEvrAIthtOgQ3pOsqTQNroBvo3bSMgH +FzZM9O6II8c+6zf1tRn4SWiw3te5djgdYZ6k/oI2peVKVuRF4fn9tBb6dNqcmzU5L/qwIFAGbHrQ +gLKm+a/sRxmPUDgH3KKHOVj4utWp+UhnMJbulHheb4mjUcAwhmahRWa6VOujw5H5SNz/0egwLX0t +dHA114gk957EWW67c4cX8jJGKLhD+rcdqsq08p8kDi1L93FcXmn/6pUCyziKrlA4b9v7LWIbxcce +VOF34GfID5yHI9Y/QCB/IIDEgEw+OyQmjgSubJrIqg0CAwEAAaNCMEAwDwYDVR0TAQH/BAUwAwEB +/zAOBgNVHQ8BAf8EBAMCAYYwHQYDVR0OBBYEFIQYzIU07LwMlJQuCFmcx7IQTgoIMA0GCSqGSIb3 +DQEBCwUAA4IBAQCY8jdaQZChGsV2USggNiMOruYou6r4lK5IpDB/G/wkjUu0yKGX9rbxenDIU5PM +CCjjmCXPI6T53iHTfIUJrU6adTrCC2qJeHZERxhlbI1Bjjt/msv0tadQ1wUsN+gDS63pYaACbvXy +8MWy7Vu33PqUXHeeE6V/Uq2V8viTO96LXFvKWlJbYK8U90vvo/ufQJVtMVT8QtPHRh8jrdkPSHCa +2XV4cdFyQzR1bldZwgJcJmApzyMZFo6IQ6XU5MsI+yMRQ+hDKXJioaldXgjUkK642M4UwtBV8ob2 +xJNDd2ZhwLnoQdeXeGADbkpyrqXRfboQnoZsG4q5WTP468SQvvG5 +-----END CERTIFICATE----- + +Amazon Root CA 2 +================ +-----BEGIN CERTIFICATE----- +MIIFQTCCAymgAwIBAgITBmyf0pY1hp8KD+WGePhbJruKNzANBgkqhkiG9w0BAQwFADA5MQswCQYD +VQQGEwJVUzEPMA0GA1UEChMGQW1hem9uMRkwFwYDVQQDExBBbWF6b24gUm9vdCBDQSAyMB4XDTE1 +MDUyNjAwMDAwMFoXDTQwMDUyNjAwMDAwMFowOTELMAkGA1UEBhMCVVMxDzANBgNVBAoTBkFtYXpv +bjEZMBcGA1UEAxMQQW1hem9uIFJvb3QgQ0EgMjCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoC +ggIBAK2Wny2cSkxKgXlRmeyKy2tgURO8TW0G/LAIjd0ZEGrHJgw12MBvIITplLGbhQPDW9tK6Mj4 +kHbZW0/jTOgGNk3Mmqw9DJArktQGGWCsN0R5hYGCrVo34A3MnaZMUnbqQ523BNFQ9lXg1dKmSYXp +N+nKfq5clU1Imj+uIFptiJXZNLhSGkOQsL9sBbm2eLfq0OQ6PBJTYv9K8nu+NQWpEjTj82R0Yiw9 +AElaKP4yRLuH3WUnAnE72kr3H9rN9yFVkE8P7K6C4Z9r2UXTu/Bfh+08LDmG2j/e7HJV63mjrdvd +fLC6HM783k81ds8P+HgfajZRRidhW+mez/CiVX18JYpvL7TFz4QuK/0NURBs+18bvBt+xa47mAEx +kv8LV/SasrlX6avvDXbR8O70zoan4G7ptGmh32n2M8ZpLpcTnqWHsFcQgTfJU7O7f/aS0ZzQGPSS +btqDT6ZjmUyl+17vIWR6IF9sZIUVyzfpYgwLKhbcAS4y2j5L9Z469hdAlO+ekQiG+r5jqFoz7Mt0 +Q5X5bGlSNscpb/xVA1wf+5+9R+vnSUeVC06JIglJ4PVhHvG/LopyboBZ/1c6+XUyo05f7O0oYtlN +c/LMgRdg7c3r3NunysV+Ar3yVAhU/bQtCSwXVEqY0VThUWcI0u1ufm8/0i2BWSlmy5A5lREedCf+ +3euvAgMBAAGjQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMB0GA1UdDgQWBBSw +DPBMMPQFWAJI/TPlUq9LhONmUjANBgkqhkiG9w0BAQwFAAOCAgEAqqiAjw54o+Ci1M3m9Zh6O+oA +A7CXDpO8Wqj2LIxyh6mx/H9z/WNxeKWHWc8w4Q0QshNabYL1auaAn6AFC2jkR2vHat+2/XcycuUY ++gn0oJMsXdKMdYV2ZZAMA3m3MSNjrXiDCYZohMr/+c8mmpJ5581LxedhpxfL86kSk5Nrp+gvU5LE +YFiwzAJRGFuFjWJZY7attN6a+yb3ACfAXVU3dJnJUH/jWS5E4ywl7uxMMne0nxrpS10gxdr9HIcW +xkPo1LsmmkVwXqkLN1PiRnsn/eBG8om3zEK2yygmbtmlyTrIQRNg91CMFa6ybRoVGld45pIq2WWQ +gj9sAq+uEjonljYE1x2igGOpm/HlurR8FLBOybEfdF849lHqm/osohHUqS0nGkWxr7JOcQ3AWEbW +aQbLU8uz/mtBzUF+fUwPfHJ5elnNXkoOrJupmHN5fLT0zLm4BwyydFy4x2+IoZCn9Kr5v2c69BoV +Yh63n749sSmvZ6ES8lgQGVMDMBu4Gon2nL2XA46jCfMdiyHxtN/kHNGfZQIG6lzWE7OE76KlXIx3 +KadowGuuQNKotOrN8I1LOJwZmhsoVLiJkO/KdYE+HvJkJMcYr07/R54H9jVlpNMKVv/1F2Rs76gi +JUmTtt8AF9pYfl3uxRuw0dFfIRDH+fO6AgonB8Xx1sfT4PsJYGw= +-----END CERTIFICATE----- + +Amazon Root CA 3 +================ +-----BEGIN CERTIFICATE----- +MIIBtjCCAVugAwIBAgITBmyf1XSXNmY/Owua2eiedgPySjAKBggqhkjOPQQDAjA5MQswCQYDVQQG +EwJVUzEPMA0GA1UEChMGQW1hem9uMRkwFwYDVQQDExBBbWF6b24gUm9vdCBDQSAzMB4XDTE1MDUy +NjAwMDAwMFoXDTQwMDUyNjAwMDAwMFowOTELMAkGA1UEBhMCVVMxDzANBgNVBAoTBkFtYXpvbjEZ +MBcGA1UEAxMQQW1hem9uIFJvb3QgQ0EgMzBZMBMGByqGSM49AgEGCCqGSM49AwEHA0IABCmXp8ZB +f8ANm+gBG1bG8lKlui2yEujSLtf6ycXYqm0fc4E7O5hrOXwzpcVOho6AF2hiRVd9RFgdszflZwjr +Zt6jQjBAMA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMB0GA1UdDgQWBBSrttvXBp43 +rDCGB5Fwx5zEGbF4wDAKBggqhkjOPQQDAgNJADBGAiEA4IWSoxe3jfkrBqWTrBqYaGFy+uGh0Psc +eGCmQ5nFuMQCIQCcAu/xlJyzlvnrxir4tiz+OpAUFteMYyRIHN8wfdVoOw== +-----END CERTIFICATE----- + +Amazon Root CA 4 +================ +-----BEGIN CERTIFICATE----- +MIIB8jCCAXigAwIBAgITBmyf18G7EEwpQ+Vxe3ssyBrBDjAKBggqhkjOPQQDAzA5MQswCQYDVQQG +EwJVUzEPMA0GA1UEChMGQW1hem9uMRkwFwYDVQQDExBBbWF6b24gUm9vdCBDQSA0MB4XDTE1MDUy +NjAwMDAwMFoXDTQwMDUyNjAwMDAwMFowOTELMAkGA1UEBhMCVVMxDzANBgNVBAoTBkFtYXpvbjEZ +MBcGA1UEAxMQQW1hem9uIFJvb3QgQ0EgNDB2MBAGByqGSM49AgEGBSuBBAAiA2IABNKrijdPo1MN +/sGKe0uoe0ZLY7Bi9i0b2whxIdIA6GO9mif78DluXeo9pcmBqqNbIJhFXRbb/egQbeOc4OO9X4Ri +83BkM6DLJC9wuoihKqB1+IGuYgbEgds5bimwHvouXKNCMEAwDwYDVR0TAQH/BAUwAwEB/zAOBgNV +HQ8BAf8EBAMCAYYwHQYDVR0OBBYEFNPsxzplbszh2naaVvuc84ZtV+WBMAoGCCqGSM49BAMDA2gA +MGUCMDqLIfG9fhGt0O9Yli/W651+kI0rz2ZVwyzjKKlwCkcO8DdZEv8tmZQoTipPNU0zWgIxAOp1 +AE47xDqUEpHJWEadIRNyp4iciuRMStuW1KyLa2tJElMzrdfkviT8tQp21KW8EA== +-----END CERTIFICATE----- + +LuxTrust Global Root 2 +====================== +-----BEGIN CERTIFICATE----- +MIIFwzCCA6ugAwIBAgIUCn6m30tEntpqJIWe5rgV0xZ/u7EwDQYJKoZIhvcNAQELBQAwRjELMAkG +A1UEBhMCTFUxFjAUBgNVBAoMDUx1eFRydXN0IFMuQS4xHzAdBgNVBAMMFkx1eFRydXN0IEdsb2Jh +bCBSb290IDIwHhcNMTUwMzA1MTMyMTU3WhcNMzUwMzA1MTMyMTU3WjBGMQswCQYDVQQGEwJMVTEW +MBQGA1UECgwNTHV4VHJ1c3QgUy5BLjEfMB0GA1UEAwwWTHV4VHJ1c3QgR2xvYmFsIFJvb3QgMjCC +AiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBANeFl78RmOnwYoNMPIf5U2o3C/IPPIfOb9wm +Kb3FibrJgz337spbxm1Jc7TJRqMbNBM/wYlFV/TZsfs2ZUv7COJIcRHIbjuend+JZTemhfY7RBi2 +xjcwYkSSl2l9QjAk5A0MiWtj3sXh306pFGxT4GHO9hcvHTy95iJMHZP1EMShduxq3sVs35a0VkBC +wGKSMKEtFZSg0iAGCW5qbeXrt77U8PEVfIvmTroTzEsnXpk8F12PgX8zPU/TPxvsXD/wPEx1bvKm +1Z3aLQdjAsZy6ZS8TEmVT4hSyNvoaYL4zDRbIvCGp4m9SAptZoFtyMhk+wHh9OHe2Z7d21vUKpkm +FRseTJIpgp7VkoGSQXAZ96Tlk0u8d2cx3Rz9MXANF5kM+Qw5GSoXtTBxVdUPrljhPS80m8+f9niF +wpN6cj5mj5wWEWCPnolvZ77gR1o7DJpni89Gxq44o/KnvObWhWszJHAiS8sIm7vI+AIpHb4gDEa/ +a4ebsypmQjVGbKq6rfmYe+lQVRQxv7HaLe2ArWgk+2mr2HETMOZns4dA/Yl+8kPREd8vZS9kzl8U +ubG/Mb2HeFpZZYiq/FkySIbWTLkpS5XTdvN3JW1CHDiDTf2jX5t/Lax5Gw5CMZdjpPuKadUiDTSQ +MC6otOBttpSsvItO13D8xTiOZCXhTTmQzsmHhFhxAgMBAAGjgagwgaUwDwYDVR0TAQH/BAUwAwEB +/zBCBgNVHSAEOzA5MDcGByuBKwEBAQowLDAqBggrBgEFBQcCARYeaHR0cHM6Ly9yZXBvc2l0b3J5 +Lmx1eHRydXN0Lmx1MA4GA1UdDwEB/wQEAwIBBjAfBgNVHSMEGDAWgBT/GCh2+UgFLKGu8SsbK7JT ++Et8szAdBgNVHQ4EFgQU/xgodvlIBSyhrvErGyuyU/hLfLMwDQYJKoZIhvcNAQELBQADggIBAGoZ +FO1uecEsh9QNcH7X9njJCwROxLHOk3D+sFTAMs2ZMGQXvw/l4jP9BzZAcg4atmpZ1gDlaCDdLnIN +H2pkMSCEfUmmWjfrRcmF9dTHF5kH5ptV5AzoqbTOjFu1EVzPig4N1qx3gf4ynCSecs5U89BvolbW +7MM3LGVYvlcAGvI1+ut7MV3CwRI9loGIlonBWVx65n9wNOeD4rHh4bhY79SV5GCc8JaXcozrhAIu +ZY+kt9J/Z93I055cqqmkoCUUBpvsT34tC38ddfEz2O3OuHVtPlu5mB0xDVbYQw8wkbIEa91WvpWA +VWe+2M2D2RjuLg+GLZKecBPs3lHJQ3gCpU3I+V/EkVhGFndadKpAvAefMLmx9xIX3eP/JEAdemrR +TxgKqpAd60Ae36EeRJIQmvKN4dFLRp7oRUKX6kWZ8+xm1QL68qZKJKrezrnK+T+Tb/mjuuqlPpmt +/f97mfVl7vBZKGfXkJWkE4SphMHozs51k2MavDzq1WQfLSoSOcbDWjLtR5EWDrw4wVDej8oqkDQc +7kGUnF4ZLvhFSZl0kbAEb+MEWrGrKqv+x9CWttrhSmQGbmBNvUJO/3jaJMobtNeWOWyu8Q6qp31I +iyBMz2TWuJdGsE7RKlY6oJO9r4Ak4Ap+58rVyuiFVdw2KuGUaJPHZnJED4AhMmwlxyOAgwrr +-----END CERTIFICATE----- + +TUBITAK Kamu SM SSL Kok Sertifikasi - Surum 1 +============================================= +-----BEGIN CERTIFICATE----- +MIIEYzCCA0ugAwIBAgIBATANBgkqhkiG9w0BAQsFADCB0jELMAkGA1UEBhMCVFIxGDAWBgNVBAcT +D0dlYnplIC0gS29jYWVsaTFCMEAGA1UEChM5VHVya2l5ZSBCaWxpbXNlbCB2ZSBUZWtub2xvamlr +IEFyYXN0aXJtYSBLdXJ1bXUgLSBUVUJJVEFLMS0wKwYDVQQLEyRLYW11IFNlcnRpZmlrYXN5b24g +TWVya2V6aSAtIEthbXUgU00xNjA0BgNVBAMTLVRVQklUQUsgS2FtdSBTTSBTU0wgS29rIFNlcnRp +ZmlrYXNpIC0gU3VydW0gMTAeFw0xMzExMjUwODI1NTVaFw00MzEwMjUwODI1NTVaMIHSMQswCQYD +VQQGEwJUUjEYMBYGA1UEBxMPR2ViemUgLSBLb2NhZWxpMUIwQAYDVQQKEzlUdXJraXllIEJpbGlt +c2VsIHZlIFRla25vbG9qaWsgQXJhc3Rpcm1hIEt1cnVtdSAtIFRVQklUQUsxLTArBgNVBAsTJEth +bXUgU2VydGlmaWthc3lvbiBNZXJrZXppIC0gS2FtdSBTTTE2MDQGA1UEAxMtVFVCSVRBSyBLYW11 +IFNNIFNTTCBLb2sgU2VydGlmaWthc2kgLSBTdXJ1bSAxMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8A +MIIBCgKCAQEAr3UwM6q7a9OZLBI3hNmNe5eA027n/5tQlT6QlVZC1xl8JoSNkvoBHToP4mQ4t4y8 +6Ij5iySrLqP1N+RAjhgleYN1Hzv/bKjFxlb4tO2KRKOrbEz8HdDc72i9z+SqzvBV96I01INrN3wc +wv61A+xXzry0tcXtAA9TNypN9E8Mg/uGz8v+jE69h/mniyFXnHrfA2eJLJ2XYacQuFWQfw4tJzh0 +3+f92k4S400VIgLI4OD8D62K18lUUMw7D8oWgITQUVbDjlZ/iSIzL+aFCr2lqBs23tPcLG07xxO9 +WSMs5uWk99gL7eqQQESolbuT1dCANLZGeA4fAJNG4e7p+exPFwIDAQABo0IwQDAdBgNVHQ4EFgQU +ZT/HiobGPN08VFw1+DrtUgxHV8gwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wDQYJ +KoZIhvcNAQELBQADggEBACo/4fEyjq7hmFxLXs9rHmoJ0iKpEsdeV31zVmSAhHqT5Am5EM2fKifh +AHe+SMg1qIGf5LgsyX8OsNJLN13qudULXjS99HMpw+0mFZx+CFOKWI3QSyjfwbPfIPP54+M638yc +lNhOT8NrF7f3cuitZjO1JVOr4PhMqZ398g26rrnZqsZr+ZO7rqu4lzwDGrpDxpa5RXI4s6ehlj2R +e37AIVNMh+3yC1SVUZPVIqUNivGTDj5UDrDYyU7c8jEyVupk+eq1nRZmQnLzf9OxMUP8pI4X8W0j +q5Rm+K37DwhuJi1/FwcJsoz7UMCflo3Ptv0AnVoUmr8CRPXBwp8iXqIPoeM= +-----END CERTIFICATE----- + +GDCA TrustAUTH R5 ROOT +====================== +-----BEGIN CERTIFICATE----- +MIIFiDCCA3CgAwIBAgIIfQmX/vBH6nowDQYJKoZIhvcNAQELBQAwYjELMAkGA1UEBhMCQ04xMjAw +BgNVBAoMKUdVQU5HIERPTkcgQ0VSVElGSUNBVEUgQVVUSE9SSVRZIENPLixMVEQuMR8wHQYDVQQD +DBZHRENBIFRydXN0QVVUSCBSNSBST09UMB4XDTE0MTEyNjA1MTMxNVoXDTQwMTIzMTE1NTk1OVow +YjELMAkGA1UEBhMCQ04xMjAwBgNVBAoMKUdVQU5HIERPTkcgQ0VSVElGSUNBVEUgQVVUSE9SSVRZ +IENPLixMVEQuMR8wHQYDVQQDDBZHRENBIFRydXN0QVVUSCBSNSBST09UMIICIjANBgkqhkiG9w0B +AQEFAAOCAg8AMIICCgKCAgEA2aMW8Mh0dHeb7zMNOwZ+Vfy1YI92hhJCfVZmPoiC7XJjDp6L3TQs +AlFRwxn9WVSEyfFrs0yw6ehGXTjGoqcuEVe6ghWinI9tsJlKCvLriXBjTnnEt1u9ol2x8kECK62p +OqPseQrsXzrj/e+APK00mxqriCZ7VqKChh/rNYmDf1+uKU49tm7srsHwJ5uu4/Ts765/94Y9cnrr +pftZTqfrlYwiOXnhLQiPzLyRuEH3FMEjqcOtmkVEs7LXLM3GKeJQEK5cy4KOFxg2fZfmiJqwTTQJ +9Cy5WmYqsBebnh52nUpmMUHfP/vFBu8btn4aRjb3ZGM74zkYI+dndRTVdVeSN72+ahsmUPI2JgaQ +xXABZG12ZuGR224HwGGALrIuL4xwp9E7PLOR5G62xDtw8mySlwnNR30YwPO7ng/Wi64HtloPzgsM +R6flPri9fcebNaBhlzpBdRfMK5Z3KpIhHtmVdiBnaM8Nvd/WHwlqmuLMc3GkL30SgLdTMEZeS1SZ +D2fJpcjyIMGC7J0R38IC+xo70e0gmu9lZJIQDSri3nDxGGeCjGHeuLzRL5z7D9Ar7Rt2ueQ5Vfj4 +oR24qoAATILnsn8JuLwwoC8N9VKejveSswoAHQBUlwbgsQfZxw9cZX08bVlX5O2ljelAU58VS6Bx +9hoh49pwBiFYFIeFd3mqgnkCAwEAAaNCMEAwHQYDVR0OBBYEFOLJQJ9NzuiaoXzPDj9lxSmIahlR +MA8GA1UdEwEB/wQFMAMBAf8wDgYDVR0PAQH/BAQDAgGGMA0GCSqGSIb3DQEBCwUAA4ICAQDRSVfg +p8xoWLoBDysZzY2wYUWsEe1jUGn4H3++Fo/9nesLqjJHdtJnJO29fDMylyrHBYZmDRd9FBUb1Ov9 +H5r2XpdptxolpAqzkT9fNqyL7FeoPueBihhXOYV0GkLH6VsTX4/5COmSdI31R9KrO9b7eGZONn35 +6ZLpBN79SWP8bfsUcZNnL0dKt7n/HipzcEYwv1ryL3ml4Y0M2fmyYzeMN2WFcGpcWwlyua1jPLHd ++PwyvzeG5LuOmCd+uh8W4XAR8gPfJWIyJyYYMoSf/wA6E7qaTfRPuBRwIrHKK5DOKcFw9C+df/KQ +HtZa37dG/OaG+svgIHZ6uqbL9XzeYqWxi+7egmaKTjowHz+Ay60nugxe19CxVsp3cbK1daFQqUBD +F8Io2c9Si1vIY9RCPqAzekYu9wogRlR+ak8x8YF+QnQ4ZXMn7sZ8uI7XpTrXmKGcjBBV09tL7ECQ +8s1uV9JiDnxXk7Gnbc2dg7sq5+W2O3FYrf3RRbxake5TFW/TRQl1brqQXR4EzzffHqhmsYzmIGrv +/EhOdJhCrylvLmrH+33RZjEizIYAfmaDDEL0vTSSwxrqT8p+ck0LcIymSLumoRT2+1hEmRSuqguT +aaApJUqlyyvdimYHFngVV3Eb7PVHhPOeMTd61X8kreS8/f3MboPoDKi3QWwH3b08hpcv0g== +-----END CERTIFICATE----- + +TrustCor RootCert CA-1 +====================== +-----BEGIN CERTIFICATE----- +MIIEMDCCAxigAwIBAgIJANqb7HHzA7AZMA0GCSqGSIb3DQEBCwUAMIGkMQswCQYDVQQGEwJQQTEP +MA0GA1UECAwGUGFuYW1hMRQwEgYDVQQHDAtQYW5hbWEgQ2l0eTEkMCIGA1UECgwbVHJ1c3RDb3Ig +U3lzdGVtcyBTLiBkZSBSLkwuMScwJQYDVQQLDB5UcnVzdENvciBDZXJ0aWZpY2F0ZSBBdXRob3Jp +dHkxHzAdBgNVBAMMFlRydXN0Q29yIFJvb3RDZXJ0IENBLTEwHhcNMTYwMjA0MTIzMjE2WhcNMjkx +MjMxMTcyMzE2WjCBpDELMAkGA1UEBhMCUEExDzANBgNVBAgMBlBhbmFtYTEUMBIGA1UEBwwLUGFu +YW1hIENpdHkxJDAiBgNVBAoMG1RydXN0Q29yIFN5c3RlbXMgUy4gZGUgUi5MLjEnMCUGA1UECwwe +VHJ1c3RDb3IgQ2VydGlmaWNhdGUgQXV0aG9yaXR5MR8wHQYDVQQDDBZUcnVzdENvciBSb290Q2Vy +dCBDQS0xMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAv463leLCJhJrMxnHQFgKq1mq +jQCj/IDHUHuO1CAmujIS2CNUSSUQIpidRtLByZ5OGy4sDjjzGiVoHKZaBeYei0i/mJZ0PmnK6bV4 +pQa81QBeCQryJ3pS/C3Vseq0iWEk8xoT26nPUu0MJLq5nux+AHT6k61sKZKuUbS701e/s/OojZz0 +JEsq1pme9J7+wH5COucLlVPat2gOkEz7cD+PSiyU8ybdY2mplNgQTsVHCJCZGxdNuWxu72CVEY4h +gLW9oHPY0LJ3xEXqWib7ZnZ2+AYfYW0PVcWDtxBWcgYHpfOxGgMFZA6dWorWhnAbJN7+KIor0Gqw +/Hqi3LJ5DotlDwIDAQABo2MwYTAdBgNVHQ4EFgQU7mtJPHo/DeOxCbeKyKsZn3MzUOcwHwYDVR0j +BBgwFoAU7mtJPHo/DeOxCbeKyKsZn3MzUOcwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMC +AYYwDQYJKoZIhvcNAQELBQADggEBACUY1JGPE+6PHh0RU9otRCkZoB5rMZ5NDp6tPVxBb5UrJKF5 +mDo4Nvu7Zp5I/5CQ7z3UuJu0h3U/IJvOcs+hVcFNZKIZBqEHMwwLKeXx6quj7LUKdJDHfXLy11yf +ke+Ri7fc7Waiz45mO7yfOgLgJ90WmMCV1Aqk5IGadZQ1nJBfiDcGrVmVCrDRZ9MZyonnMlo2HD6C +qFqTvsbQZJG2z9m2GM/bftJlo6bEjhcxwft+dtvTheNYsnd6djtsL1Ac59v2Z3kf9YKVmgenFK+P +3CghZwnS1k1aHBkcjndcw5QkPTJrS37UeJSDvjdNzl/HHk484IkzlQsPpTLWPFp5LBk= +-----END CERTIFICATE----- + +TrustCor RootCert CA-2 +====================== +-----BEGIN CERTIFICATE----- +MIIGLzCCBBegAwIBAgIIJaHfyjPLWQIwDQYJKoZIhvcNAQELBQAwgaQxCzAJBgNVBAYTAlBBMQ8w +DQYDVQQIDAZQYW5hbWExFDASBgNVBAcMC1BhbmFtYSBDaXR5MSQwIgYDVQQKDBtUcnVzdENvciBT +eXN0ZW1zIFMuIGRlIFIuTC4xJzAlBgNVBAsMHlRydXN0Q29yIENlcnRpZmljYXRlIEF1dGhvcml0 +eTEfMB0GA1UEAwwWVHJ1c3RDb3IgUm9vdENlcnQgQ0EtMjAeFw0xNjAyMDQxMjMyMjNaFw0zNDEy +MzExNzI2MzlaMIGkMQswCQYDVQQGEwJQQTEPMA0GA1UECAwGUGFuYW1hMRQwEgYDVQQHDAtQYW5h +bWEgQ2l0eTEkMCIGA1UECgwbVHJ1c3RDb3IgU3lzdGVtcyBTLiBkZSBSLkwuMScwJQYDVQQLDB5U +cnVzdENvciBDZXJ0aWZpY2F0ZSBBdXRob3JpdHkxHzAdBgNVBAMMFlRydXN0Q29yIFJvb3RDZXJ0 +IENBLTIwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCnIG7CKqJiJJWQdsg4foDSq8Gb +ZQWU9MEKENUCrO2fk8eHyLAnK0IMPQo+QVqedd2NyuCb7GgypGmSaIwLgQ5WoD4a3SwlFIIvl9Nk +RvRUqdw6VC0xK5mC8tkq1+9xALgxpL56JAfDQiDyitSSBBtlVkxs1Pu2YVpHI7TYabS3OtB0PAx1 +oYxOdqHp2yqlO/rOsP9+aij9JxzIsekp8VduZLTQwRVtDr4uDkbIXvRR/u8OYzo7cbrPb1nKDOOb +XUm4TOJXsZiKQlecdu/vvdFoqNL0Cbt3Nb4lggjEFixEIFapRBF37120Hapeaz6LMvYHL1cEksr1 +/p3C6eizjkxLAjHZ5DxIgif3GIJ2SDpxsROhOdUuxTTCHWKF3wP+TfSvPd9cW436cOGlfifHhi5q +jxLGhF5DUVCcGZt45vz27Ud+ez1m7xMTiF88oWP7+ayHNZ/zgp6kPwqcMWmLmaSISo5uZk3vFsQP +eSghYA2FFn3XVDjxklb9tTNMg9zXEJ9L/cb4Qr26fHMC4P99zVvh1Kxhe1fVSntb1IVYJ12/+Ctg +rKAmrhQhJ8Z3mjOAPF5GP/fDsaOGM8boXg25NSyqRsGFAnWAoOsk+xWq5Gd/bnc/9ASKL3x74xdh +8N0JqSDIvgmk0H5Ew7IwSjiqqewYmgeCK9u4nBit2uBGF6zPXQIDAQABo2MwYTAdBgNVHQ4EFgQU +2f4hQG6UnrybPZx9mCAZ5YwwYrIwHwYDVR0jBBgwFoAU2f4hQG6UnrybPZx9mCAZ5YwwYrIwDwYD +VR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAYYwDQYJKoZIhvcNAQELBQADggIBAJ5Fngw7tu/h +Osh80QA9z+LqBrWyOrsGS2h60COXdKcs8AjYeVrXWoSK2BKaG9l9XE1wxaX5q+WjiYndAfrs3fnp +kpfbsEZC89NiqpX+MWcUaViQCqoL7jcjx1BRtPV+nuN79+TMQjItSQzL/0kMmx40/W5ulop5A7Zv +2wnL/V9lFDfhOPXzYRZY5LVtDQsEGz9QLX+zx3oaFoBg+Iof6Rsqxvm6ARppv9JYx1RXCI/hOWB3 +S6xZhBqI8d3LT3jX5+EzLfzuQfogsL7L9ziUwOHQhQ+77Sxzq+3+knYaZH9bDTMJBzN7Bj8RpFxw +PIXAz+OQqIN3+tvmxYxoZxBnpVIt8MSZj3+/0WvitUfW2dCFmU2Umw9Lje4AWkcdEQOsQRivh7dv +DDqPys/cA8GiCcjl/YBeyGBCARsaU1q7N6a3vLqE6R5sGtRk2tRD/pOLS/IseRYQ1JMLiI+h2IYU +RpFHmygk71dSTlxCnKr3Sewn6EAes6aJInKc9Q0ztFijMDvd1GpUk74aTfOTlPf8hAs/hCBcNANE +xdqtvArBAs8e5ZTZ845b2EzwnexhF7sUMlQMAimTHpKG9n/v55IFDlndmQguLvqcAFLTxWYp5KeX +RKQOKIETNcX2b2TmQcTVL8w0RSXPQQCWPUouwpaYT05KnJe32x+SMsj/D1Fu1uwJ +-----END CERTIFICATE----- + +TrustCor ECA-1 +============== +-----BEGIN CERTIFICATE----- +MIIEIDCCAwigAwIBAgIJAISCLF8cYtBAMA0GCSqGSIb3DQEBCwUAMIGcMQswCQYDVQQGEwJQQTEP +MA0GA1UECAwGUGFuYW1hMRQwEgYDVQQHDAtQYW5hbWEgQ2l0eTEkMCIGA1UECgwbVHJ1c3RDb3Ig +U3lzdGVtcyBTLiBkZSBSLkwuMScwJQYDVQQLDB5UcnVzdENvciBDZXJ0aWZpY2F0ZSBBdXRob3Jp +dHkxFzAVBgNVBAMMDlRydXN0Q29yIEVDQS0xMB4XDTE2MDIwNDEyMzIzM1oXDTI5MTIzMTE3Mjgw +N1owgZwxCzAJBgNVBAYTAlBBMQ8wDQYDVQQIDAZQYW5hbWExFDASBgNVBAcMC1BhbmFtYSBDaXR5 +MSQwIgYDVQQKDBtUcnVzdENvciBTeXN0ZW1zIFMuIGRlIFIuTC4xJzAlBgNVBAsMHlRydXN0Q29y +IENlcnRpZmljYXRlIEF1dGhvcml0eTEXMBUGA1UEAwwOVHJ1c3RDb3IgRUNBLTEwggEiMA0GCSqG +SIb3DQEBAQUAA4IBDwAwggEKAoIBAQDPj+ARtZ+odnbb3w9U73NjKYKtR8aja+3+XzP4Q1HpGjOR +MRegdMTUpwHmspI+ap3tDvl0mEDTPwOABoJA6LHip1GnHYMma6ve+heRK9jGrB6xnhkB1Zem6g23 +xFUfJ3zSCNV2HykVh0A53ThFEXXQmqc04L/NyFIduUd+Dbi7xgz2c1cWWn5DkR9VOsZtRASqnKmc +p0yJF4OuowReUoCLHhIlERnXDH19MURB6tuvsBzvgdAsxZohmz3tQjtQJvLsznFhBmIhVE5/wZ0+ +fyCMgMsq2JdiyIMzkX2woloPV+g7zPIlstR8L+xNxqE6FXrntl019fZISjZFZtS6mFjBAgMBAAGj +YzBhMB0GA1UdDgQWBBREnkj1zG1I1KBLf/5ZJC+Dl5mahjAfBgNVHSMEGDAWgBREnkj1zG1I1KBL +f/5ZJC+Dl5mahjAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBhjANBgkqhkiG9w0BAQsF +AAOCAQEABT41XBVwm8nHc2FvcivUwo/yQ10CzsSUuZQRg2dd4mdsdXa/uwyqNsatR5Nj3B5+1t4u +/ukZMjgDfxT2AHMsWbEhBuH7rBiVDKP/mZb3Kyeb1STMHd3BOuCYRLDE5D53sXOpZCz2HAF8P11F +hcCF5yWPldwX8zyfGm6wyuMdKulMY/okYWLW2n62HGz1Ah3UKt1VkOsqEUc8Ll50soIipX1TH0Xs +J5F95yIW6MBoNtjG8U+ARDL54dHRHareqKucBK+tIA5kmE2la8BIWJZpTdwHjFGTot+fDz2LYLSC +jaoITmJF4PkL0uDgPFveXHEnJcLmA4GLEFPjx1WitJ/X5g== +-----END CERTIFICATE----- + +SSL.com Root Certification Authority RSA +======================================== +-----BEGIN CERTIFICATE----- +MIIF3TCCA8WgAwIBAgIIeyyb0xaAMpkwDQYJKoZIhvcNAQELBQAwfDELMAkGA1UEBhMCVVMxDjAM +BgNVBAgMBVRleGFzMRAwDgYDVQQHDAdIb3VzdG9uMRgwFgYDVQQKDA9TU0wgQ29ycG9yYXRpb24x +MTAvBgNVBAMMKFNTTC5jb20gUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSBSU0EwHhcNMTYw +MjEyMTczOTM5WhcNNDEwMjEyMTczOTM5WjB8MQswCQYDVQQGEwJVUzEOMAwGA1UECAwFVGV4YXMx +EDAOBgNVBAcMB0hvdXN0b24xGDAWBgNVBAoMD1NTTCBDb3Jwb3JhdGlvbjExMC8GA1UEAwwoU1NM +LmNvbSBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IFJTQTCCAiIwDQYJKoZIhvcNAQEBBQAD +ggIPADCCAgoCggIBAPkP3aMrfcvQKv7sZ4Wm5y4bunfh4/WvpOz6Sl2RxFdHaxh3a3by/ZPkPQ/C +Fp4LZsNWlJ4Xg4XOVu/yFv0AYvUiCVToZRdOQbngT0aXqhvIuG5iXmmxX9sqAn78bMrzQdjt0Oj8 +P2FI7bADFB0QDksZ4LtO7IZl/zbzXmcCC52GVWH9ejjt/uIZALdvoVBidXQ8oPrIJZK0bnoix/ge +oeOy3ZExqysdBP+lSgQ36YWkMyv94tZVNHwZpEpox7Ko07fKoZOI68GXvIz5HdkihCR0xwQ9aqkp +k8zruFvh/l8lqjRYyMEjVJ0bmBHDOJx+PYZspQ9AhnwC9FwCTyjLrnGfDzrIM/4RJTXq/LrFYD3Z +fBjVsqnTdXgDciLKOsMf7yzlLqn6niy2UUb9rwPW6mBo6oUWNmuF6R7As93EJNyAKoFBbZQ+yODJ +gUEAnl6/f8UImKIYLEJAs/lvOCdLToD0PYFH4Ih86hzOtXVcUS4cK38acijnALXRdMbX5J+tB5O2 +UzU1/Dfkw/ZdFr4hc96SCvigY2q8lpJqPvi8ZVWb3vUNiSYE/CUapiVpy8JtynziWV+XrOvvLsi8 +1xtZPCvM8hnIk2snYxnP/Okm+Mpxm3+T/jRnhE6Z6/yzeAkzcLpmpnbtG3PrGqUNxCITIJRWCk4s +bE6x/c+cCbqiM+2HAgMBAAGjYzBhMB0GA1UdDgQWBBTdBAkHovV6fVJTEpKV7jiAJQ2mWTAPBgNV +HRMBAf8EBTADAQH/MB8GA1UdIwQYMBaAFN0ECQei9Xp9UlMSkpXuOIAlDaZZMA4GA1UdDwEB/wQE +AwIBhjANBgkqhkiG9w0BAQsFAAOCAgEAIBgRlCn7Jp0cHh5wYfGVcpNxJK1ok1iOMq8bs3AD/CUr +dIWQPXhq9LmLpZc7tRiRux6n+UBbkflVma8eEdBcHadm47GUBwwyOabqG7B52B2ccETjit3E+ZUf +ijhDPwGFpUenPUayvOUiaPd7nNgsPgohyC0zrL/FgZkxdMF1ccW+sfAjRfSda/wZY52jvATGGAsl +u1OJD7OAUN5F7kR/q5R4ZJjT9ijdh9hwZXT7DrkT66cPYakylszeu+1jTBi7qUD3oFRuIIhxdRjq +erQ0cuAjJ3dctpDqhiVAq+8zD8ufgr6iIPv2tS0a5sKFsXQP+8hlAqRSAUfdSSLBv9jra6x+3uxj +MxW3IwiPxg+NQVrdjsW5j+VFP3jbutIbQLH+cU0/4IGiul607BXgk90IH37hVZkLId6Tngr75qNJ +vTYw/ud3sqB1l7UtgYgXZSD32pAAn8lSzDLKNXz1PQ/YK9f1JmzJBjSWFupwWRoyeXkLtoh/D1JI +Pb9s2KJELtFOt3JY04kTlf5Eq/jXixtunLwsoFvVagCvXzfh1foQC5ichucmj87w7G6KVwuA406y +wKBjYZC6VWg3dGq2ktufoYYitmUnDuy2n0Jg5GfCtdpBC8TTi2EbvPofkSvXRAdeuims2cXp71NI +WuuA8ShYIc2wBlX7Jz9TkHCpBB5XJ7k= +-----END CERTIFICATE----- + +SSL.com Root Certification Authority ECC +======================================== +-----BEGIN CERTIFICATE----- +MIICjTCCAhSgAwIBAgIIdebfy8FoW6gwCgYIKoZIzj0EAwIwfDELMAkGA1UEBhMCVVMxDjAMBgNV +BAgMBVRleGFzMRAwDgYDVQQHDAdIb3VzdG9uMRgwFgYDVQQKDA9TU0wgQ29ycG9yYXRpb24xMTAv +BgNVBAMMKFNTTC5jb20gUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSBFQ0MwHhcNMTYwMjEy +MTgxNDAzWhcNNDEwMjEyMTgxNDAzWjB8MQswCQYDVQQGEwJVUzEOMAwGA1UECAwFVGV4YXMxEDAO +BgNVBAcMB0hvdXN0b24xGDAWBgNVBAoMD1NTTCBDb3Jwb3JhdGlvbjExMC8GA1UEAwwoU1NMLmNv +bSBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IEVDQzB2MBAGByqGSM49AgEGBSuBBAAiA2IA +BEVuqVDEpiM2nl8ojRfLliJkP9x6jh3MCLOicSS6jkm5BBtHllirLZXI7Z4INcgn64mMU1jrYor+ +8FsPazFSY0E7ic3s7LaNGdM0B9y7xgZ/wkWV7Mt/qCPgCemB+vNH06NjMGEwHQYDVR0OBBYEFILR +hXMw5zUE044CkvvlpNHEIejNMA8GA1UdEwEB/wQFMAMBAf8wHwYDVR0jBBgwFoAUgtGFczDnNQTT +jgKS++Wk0cQh6M0wDgYDVR0PAQH/BAQDAgGGMAoGCCqGSM49BAMCA2cAMGQCMG/n61kRpGDPYbCW +e+0F+S8Tkdzt5fxQaxFGRrMcIQBiu77D5+jNB5n5DQtdcj7EqgIwH7y6C+IwJPt8bYBVCpk+gA0z +5Wajs6O7pdWLjwkspl1+4vAHCGht0nxpbl/f5Wpl +-----END CERTIFICATE----- + +SSL.com EV Root Certification Authority RSA R2 +============================================== +-----BEGIN CERTIFICATE----- +MIIF6zCCA9OgAwIBAgIIVrYpzTS8ePYwDQYJKoZIhvcNAQELBQAwgYIxCzAJBgNVBAYTAlVTMQ4w +DAYDVQQIDAVUZXhhczEQMA4GA1UEBwwHSG91c3RvbjEYMBYGA1UECgwPU1NMIENvcnBvcmF0aW9u +MTcwNQYDVQQDDC5TU0wuY29tIEVWIFJvb3QgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgUlNBIFIy +MB4XDTE3MDUzMTE4MTQzN1oXDTQyMDUzMDE4MTQzN1owgYIxCzAJBgNVBAYTAlVTMQ4wDAYDVQQI +DAVUZXhhczEQMA4GA1UEBwwHSG91c3RvbjEYMBYGA1UECgwPU1NMIENvcnBvcmF0aW9uMTcwNQYD +VQQDDC5TU0wuY29tIEVWIFJvb3QgQ2VydGlmaWNhdGlvbiBBdXRob3JpdHkgUlNBIFIyMIICIjAN +BgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAjzZlQOHWTcDXtOlG2mvqM0fNTPl9fb69LT3w23jh +hqXZuglXaO1XPqDQCEGD5yhBJB/jchXQARr7XnAjssufOePPxU7Gkm0mxnu7s9onnQqG6YE3Bf7w +cXHswxzpY6IXFJ3vG2fThVUCAtZJycxa4bH3bzKfydQ7iEGonL3Lq9ttewkfokxykNorCPzPPFTO +Zw+oz12WGQvE43LrrdF9HSfvkusQv1vrO6/PgN3B0pYEW3p+pKk8OHakYo6gOV7qd89dAFmPZiw+ +B6KjBSYRaZfqhbcPlgtLyEDhULouisv3D5oi53+aNxPN8k0TayHRwMwi8qFG9kRpnMphNQcAb9Zh +CBHqurj26bNg5U257J8UZslXWNvNh2n4ioYSA0e/ZhN2rHd9NCSFg83XqpyQGp8hLH94t2S42Oim +9HizVcuE0jLEeK6jj2HdzghTreyI/BXkmg3mnxp3zkyPuBQVPWKchjgGAGYS5Fl2WlPAApiiECto +RHuOec4zSnaqW4EWG7WK2NAAe15itAnWhmMOpgWVSbooi4iTsjQc2KRVbrcc0N6ZVTsj9CLg+Slm +JuwgUHfbSguPvuUCYHBBXtSuUDkiFCbLsjtzdFVHB3mBOagwE0TlBIqulhMlQg+5U8Sb/M3kHN48 ++qvWBkofZ6aYMBzdLNvcGJVXZsb/XItW9XcCAwEAAaNjMGEwDwYDVR0TAQH/BAUwAwEB/zAfBgNV +HSMEGDAWgBT5YLvU49U09rj1BoAlp3PbRmmonjAdBgNVHQ4EFgQU+WC71OPVNPa49QaAJadz20Zp +qJ4wDgYDVR0PAQH/BAQDAgGGMA0GCSqGSIb3DQEBCwUAA4ICAQBWs47LCp1Jjr+kxJG7ZhcFUZh1 +++VQLHqe8RT6q9OKPv+RKY9ji9i0qVQBDb6Thi/5Sm3HXvVX+cpVHBK+Rw82xd9qt9t1wkclf7nx +Y/hoLVUE0fKNsKTPvDxeH3jnpaAgcLAExbf3cqfeIg29MyVGjGSSJuM+LmOW2puMPfgYCdcDzH2G +guDKBAdRUNf/ktUM79qGn5nX67evaOI5JpS6aLe/g9Pqemc9YmeuJeVy6OLk7K4S9ksrPJ/psEDz +OFSz/bdoyNrGj1E8svuR3Bznm53htw1yj+KkxKl4+esUrMZDBcJlOSgYAsOCsp0FvmXtll9ldDz7 +CTUue5wT/RsPXcdtgTpWD8w74a8CLyKsRspGPKAcTNZEtF4uXBVmCeEmKf7GUmG6sXP/wwyc5Wxq +lD8UykAWlYTzWamsX0xhk23RO8yilQwipmdnRC652dKKQbNmC1r7fSOl8hqw/96bg5Qu0T/fkreR +rwU7ZcegbLHNYhLDkBvjJc40vG93drEQw/cFGsDWr3RiSBd3kmmQYRzelYB0VI8YHMPzA9C/pEN1 +hlMYegouCRw2n5H9gooiS9EOUCXdywMMF8mDAAhONU2Ki+3wApRmLER/y5UnlhetCTCstnEXbosX +9hwJ1C07mKVx01QT2WDz9UtmT/rx7iASjbSsV7FFY6GsdqnC+w== +-----END CERTIFICATE----- + +SSL.com EV Root Certification Authority ECC +=========================================== +-----BEGIN CERTIFICATE----- +MIIClDCCAhqgAwIBAgIILCmcWxbtBZUwCgYIKoZIzj0EAwIwfzELMAkGA1UEBhMCVVMxDjAMBgNV +BAgMBVRleGFzMRAwDgYDVQQHDAdIb3VzdG9uMRgwFgYDVQQKDA9TU0wgQ29ycG9yYXRpb24xNDAy +BgNVBAMMK1NTTC5jb20gRVYgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhvcml0eSBFQ0MwHhcNMTYw +MjEyMTgxNTIzWhcNNDEwMjEyMTgxNTIzWjB/MQswCQYDVQQGEwJVUzEOMAwGA1UECAwFVGV4YXMx +EDAOBgNVBAcMB0hvdXN0b24xGDAWBgNVBAoMD1NTTCBDb3Jwb3JhdGlvbjE0MDIGA1UEAwwrU1NM +LmNvbSBFViBSb290IENlcnRpZmljYXRpb24gQXV0aG9yaXR5IEVDQzB2MBAGByqGSM49AgEGBSuB +BAAiA2IABKoSR5CYG/vvw0AHgyBO8TCCogbR8pKGYfL2IWjKAMTH6kMAVIbc/R/fALhBYlzccBYy +3h+Z1MzFB8gIH2EWB1E9fVwHU+M1OIzfzZ/ZLg1KthkuWnBaBu2+8KGwytAJKaNjMGEwHQYDVR0O +BBYEFFvKXuXe0oGqzagtZFG22XKbl+ZPMA8GA1UdEwEB/wQFMAMBAf8wHwYDVR0jBBgwFoAUW8pe +5d7SgarNqC1kUbbZcpuX5k8wDgYDVR0PAQH/BAQDAgGGMAoGCCqGSM49BAMCA2gAMGUCMQCK5kCJ +N+vp1RPZytRrJPOwPYdGWBrssd9v+1a6cGvHOMzosYxPD/fxZ3YOg9AeUY8CMD32IygmTMZgh5Mm +m7I1HrrW9zzRHM76JTymGoEVW/MSD2zuZYrJh6j5B+BimoxcSg== +-----END CERTIFICATE----- + +GlobalSign Root CA - R6 +======================= +-----BEGIN CERTIFICATE----- +MIIFgzCCA2ugAwIBAgIORea7A4Mzw4VlSOb/RVEwDQYJKoZIhvcNAQEMBQAwTDEgMB4GA1UECxMX +R2xvYmFsU2lnbiBSb290IENBIC0gUjYxEzARBgNVBAoTCkdsb2JhbFNpZ24xEzARBgNVBAMTCkds +b2JhbFNpZ24wHhcNMTQxMjEwMDAwMDAwWhcNMzQxMjEwMDAwMDAwWjBMMSAwHgYDVQQLExdHbG9i +YWxTaWduIFJvb3QgQ0EgLSBSNjETMBEGA1UEChMKR2xvYmFsU2lnbjETMBEGA1UEAxMKR2xvYmFs +U2lnbjCCAiIwDQYJKoZIhvcNAQEBBQADggIPADCCAgoCggIBAJUH6HPKZvnsFMp7PPcNCPG0RQss +grRIxutbPK6DuEGSMxSkb3/pKszGsIhrxbaJ0cay/xTOURQh7ErdG1rG1ofuTToVBu1kZguSgMpE +3nOUTvOniX9PeGMIyBJQbUJmL025eShNUhqKGoC3GYEOfsSKvGRMIRxDaNc9PIrFsmbVkJq3MQbF +vuJtMgamHvm566qjuL++gmNQ0PAYid/kD3n16qIfKtJwLnvnvJO7bVPiSHyMEAc4/2ayd2F+4OqM +PKq0pPbzlUoSB239jLKJz9CgYXfIWHSw1CM69106yqLbnQneXUQtkPGBzVeS+n68UARjNN9rkxi+ +azayOeSsJDa38O+2HBNXk7besvjihbdzorg1qkXy4J02oW9UivFyVm4uiMVRQkQVlO6jxTiWm05O +WgtH8wY2SXcwvHE35absIQh1/OZhFj931dmRl4QKbNQCTXTAFO39OfuD8l4UoQSwC+n+7o/hbguy +CLNhZglqsQY6ZZZZwPA1/cnaKI0aEYdwgQqomnUdnjqGBQCe24DWJfncBZ4nWUx2OVvq+aWh2IMP +0f/fMBH5hc8zSPXKbWQULHpYT9NLCEnFlWQaYw55PfWzjMpYrZxCRXluDocZXFSxZba/jJvcE+kN +b7gu3GduyYsRtYQUigAZcIN5kZeR1BonvzceMgfYFGM8KEyvAgMBAAGjYzBhMA4GA1UdDwEB/wQE +AwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBSubAWjkxPioufi1xzWx/B/yGdToDAfBgNV +HSMEGDAWgBSubAWjkxPioufi1xzWx/B/yGdToDANBgkqhkiG9w0BAQwFAAOCAgEAgyXt6NH9lVLN +nsAEoJFp5lzQhN7craJP6Ed41mWYqVuoPId8AorRbrcWc+ZfwFSY1XS+wc3iEZGtIxg93eFyRJa0 +lV7Ae46ZeBZDE1ZXs6KzO7V33EByrKPrmzU+sQghoefEQzd5Mr6155wsTLxDKZmOMNOsIeDjHfrY +BzN2VAAiKrlNIC5waNrlU/yDXNOd8v9EDERm8tLjvUYAGm0CuiVdjaExUd1URhxN25mW7xocBFym +Fe944Hn+Xds+qkxV/ZoVqW/hpvvfcDDpw+5CRu3CkwWJ+n1jez/QcYF8AOiYrg54NMMl+68KnyBr +3TsTjxKM4kEaSHpzoHdpx7Zcf4LIHv5YGygrqGytXm3ABdJ7t+uA/iU3/gKbaKxCXcPu9czc8FB1 +0jZpnOZ7BN9uBmm23goJSFmH63sUYHpkqmlD75HHTOwY3WzvUy2MmeFe8nI+z1TIvWfspA9MRf/T +uTAjB0yPEL+GltmZWrSZVxykzLsViVO6LAUP5MSeGbEYNNVMnbrt9x+vJJUEeKgDu+6B5dpffItK +oZB0JaezPkvILFa9x8jvOOJckvB595yEunQtYQEgfn7R8k8HWV+LLUNS60YMlOH1Zkd5d9VUWx+t +JDfLRVpOoERIyNiwmcUVhAn21klJwGW45hpxbqCo8YLoRT5s1gLXCmeDBVrJpBA= +-----END CERTIFICATE----- + +OISTE WISeKey Global Root GC CA +=============================== +-----BEGIN CERTIFICATE----- +MIICaTCCAe+gAwIBAgIQISpWDK7aDKtARb8roi066jAKBggqhkjOPQQDAzBtMQswCQYDVQQGEwJD +SDEQMA4GA1UEChMHV0lTZUtleTEiMCAGA1UECxMZT0lTVEUgRm91bmRhdGlvbiBFbmRvcnNlZDEo +MCYGA1UEAxMfT0lTVEUgV0lTZUtleSBHbG9iYWwgUm9vdCBHQyBDQTAeFw0xNzA1MDkwOTQ4MzRa +Fw00MjA1MDkwOTU4MzNaMG0xCzAJBgNVBAYTAkNIMRAwDgYDVQQKEwdXSVNlS2V5MSIwIAYDVQQL +ExlPSVNURSBGb3VuZGF0aW9uIEVuZG9yc2VkMSgwJgYDVQQDEx9PSVNURSBXSVNlS2V5IEdsb2Jh +bCBSb290IEdDIENBMHYwEAYHKoZIzj0CAQYFK4EEACIDYgAETOlQwMYPchi82PG6s4nieUqjFqdr +VCTbUf/q9Akkwwsin8tqJ4KBDdLArzHkdIJuyiXZjHWd8dvQmqJLIX4Wp2OQ0jnUsYd4XxiWD1Ab +NTcPasbc2RNNpI6QN+a9WzGRo1QwUjAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAd +BgNVHQ4EFgQUSIcUrOPDnpBgOtfKie7TrYy0UGYwEAYJKwYBBAGCNxUBBAMCAQAwCgYIKoZIzj0E +AwMDaAAwZQIwJsdpW9zV57LnyAyMjMPdeYwbY9XJUpROTYJKcx6ygISpJcBMWm1JKWB4E+J+SOtk +AjEA2zQgMgj/mkkCtojeFK9dbJlxjRo/i9fgojaGHAeCOnZT/cKi7e97sIBPWA9LUzm9 +-----END CERTIFICATE----- + +GTS Root R1 +=========== +-----BEGIN CERTIFICATE----- +MIIFWjCCA0KgAwIBAgIQbkepxUtHDA3sM9CJuRz04TANBgkqhkiG9w0BAQwFADBHMQswCQYDVQQG +EwJVUzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJv +b3QgUjEwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAG +A1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjEwggIi +MA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC2EQKLHuOhd5s73L+UPreVp0A8of2C+X0yBoJx +9vaMf/vo27xqLpeXo4xL+Sv2sfnOhB2x+cWX3u+58qPpvBKJXqeqUqv4IyfLpLGcY9vXmX7wCl7r +aKb0xlpHDU0QM+NOsROjyBhsS+z8CZDfnWQpJSMHobTSPS5g4M/SCYe7zUjwTcLCeoiKu7rPWRnW +r4+wB7CeMfGCwcDfLqZtbBkOtdh+JhpFAz2weaSUKK0PfyblqAj+lug8aJRT7oM6iCsVlgmy4HqM +LnXWnOunVmSPlk9orj2XwoSPwLxAwAtcvfaHszVsrBhQf4TgTM2S0yDpM7xSma8ytSmzJSq0SPly +4cpk9+aCEI3oncKKiPo4Zor8Y/kB+Xj9e1x3+naH+uzfsQ55lVe0vSbv1gHR6xYKu44LtcXFilWr +06zqkUspzBmkMiVOKvFlRNACzqrOSbTqn3yDsEB750Orp2yjj32JgfpMpf/VjsPOS+C12LOORc92 +wO1AK/1TD7Cn1TsNsYqiA94xrcx36m97PtbfkSIS5r762DL8EGMUUXLeXdYWk70paDPvOmbsB4om +3xPXV2V4J95eSRQAogB/mqghtqmxlbCluQ0WEdrHbEg8QOB+DVrNVjzRlwW5y0vtOUucxD/SVRNu +JLDWcfr0wbrM7Rv1/oFB2ACYPTrIrnqYNxgFlQIDAQABo0IwQDAOBgNVHQ8BAf8EBAMCAQYwDwYD +VR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQU5K8rJnEaK0gnhS9SZizv8IkTcT4wDQYJKoZIhvcNAQEM +BQADggIBADiWCu49tJYeX++dnAsznyvgyv3SjgofQXSlfKqE1OXyHuY3UjKcC9FhHb8owbZEKTV1 +d5iyfNm9dKyKaOOpMQkpAWBz40d8U6iQSifvS9efk+eCNs6aaAyC58/UEBZvXw6ZXPYfcX3v73sv +fuo21pdwCxXu11xWajOl40k4DLh9+42FpLFZXvRq4d2h9mREruZRgyFmxhE+885H7pwoHyXa/6xm +ld01D1zvICxi/ZG6qcz8WpyTgYMpl0p8WnK0OdC3d8t5/Wk6kjftbjhlRn7pYL15iJdfOBL07q9b +gsiG1eGZbYwE8na6SfZu6W0eX6DvJ4J2QPim01hcDyxC2kLGe4g0x8HYRZvBPsVhHdljUEn2NIVq +4BjFbkerQUIpm/ZgDdIx02OYI5NaAIFItO/Nis3Jz5nu2Z6qNuFoS3FJFDYoOj0dzpqPJeaAcWEr +tXvM+SUWgeExX6GjfhaknBZqlxi9dnKlC54dNuYvoS++cJEPqOba+MSSQGwlfnuzCdyyF62ARPBo +pY+Udf90WuioAnwMCeKpSwughQtiue+hMZL77/ZRBIls6Kl0obsXs7X9SQ98POyDGCBDTtWTurQ0 +sR8WNh8M5mQ5Fkzc4P4dyKliPUDqysU0ArSuiYgzNdwsE3PYJ/HQcu51OyLemGhmW/HGY0dVHLql +CFF1pkgl +-----END CERTIFICATE----- + +GTS Root R2 +=========== +-----BEGIN CERTIFICATE----- +MIIFWjCCA0KgAwIBAgIQbkepxlqz5yDFMJo/aFLybzANBgkqhkiG9w0BAQwFADBHMQswCQYDVQQG +EwJVUzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJv +b3QgUjIwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAG +A1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjIwggIi +MA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQDO3v2m++zsFDQ8BwZabFn3GTXd98GdVarTzTuk +k3LvCvptnfbwhYBboUhSnznFt+4orO/LdmgUud+tAWyZH8QiHZ/+cnfgLFuv5AS/T3KgGjSY6Dlo +7JUle3ah5mm5hRm9iYz+re026nO8/4Piy33B0s5Ks40FnotJk9/BW9BuXvAuMC6C/Pq8tBcKSOWI +m8Wba96wyrQD8Nr0kLhlZPdcTK3ofmZemde4wj7I0BOdre7kRXuJVfeKH2JShBKzwkCX44ofR5Gm +dFrS+LFjKBC4swm4VndAoiaYecb+3yXuPuWgf9RhD1FLPD+M2uFwdNjCaKH5wQzpoeJ/u1U8dgbu +ak7MkogwTZq9TwtImoS1mKPV+3PBV2HdKFZ1E66HjucMUQkQdYhMvI35ezzUIkgfKtzra7tEscsz +cTJGr61K8YzodDqs5xoic4DSMPclQsciOzsSrZYuxsN2B6ogtzVJV+mSSeh2FnIxZyuWfoqjx5RW +Ir9qS34BIbIjMt/kmkRtWVtd9QCgHJvGeJeNkP+byKq0rxFROV7Z+2et1VsRnTKaG73Vululycsl +aVNVJ1zgyjbLiGH7HrfQy+4W+9OmTN6SpdTi3/UGVN4unUu0kzCqgc7dGtxRcw1PcOnlthYhGXmy +5okLdWTK1au8CcEYof/UVKGFPP0UJAOyh9OktwIDAQABo0IwQDAOBgNVHQ8BAf8EBAMCAQYwDwYD +VR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUu//KjiOfT5nK2+JopqUVJxce2Q4wDQYJKoZIhvcNAQEM +BQADggIBALZp8KZ3/p7uC4Gt4cCpx/k1HUCCq+YEtN/L9x0Pg/B+E02NjO7jMyLDOfxA325BS0JT +vhaI8dI4XsRomRyYUpOM52jtG2pzegVATX9lO9ZY8c6DR2Dj/5epnGB3GFW1fgiTz9D2PGcDFWEJ ++YF59exTpJ/JjwGLc8R3dtyDovUMSRqodt6Sm2T4syzFJ9MHwAiApJiS4wGWAqoC7o87xdFtCjMw +c3i5T1QWvwsHoaRc5svJXISPD+AVdyx+Jn7axEvbpxZ3B7DNdehyQtaVhJ2Gg/LkkM0JR9SLA3Da +WsYDQvTtN6LwG1BUSw7YhN4ZKJmBR64JGz9I0cNv4rBgF/XuIwKl2gBbbZCr7qLpGzvpx0QnRY5r +n/WkhLx3+WuXrD5RRaIRpsyF7gpo8j5QOHokYh4XIDdtak23CZvJ/KRY9bb7nE4Yu5UC56Gtmwfu +Nmsk0jmGwZODUNKBRqhfYlcsu2xkiAhu7xNUX90txGdj08+JN7+dIPT7eoOboB6BAFDC5AwiWVIQ +7UNWhwD4FFKnHYuTjKJNRn8nxnGbJN7k2oaLDX5rIMHAnuFl2GqjpuiFizoHCBy69Y9Vmhh1fuXs +gWbRIXOhNUQLgD1bnF5vKheW0YMjiGZt5obicDIvUiLnyOd/xCxgXS/Dr55FBcOEArf9LAhST4Ld +o/DUhgkC +-----END CERTIFICATE----- + +GTS Root R3 +=========== +-----BEGIN CERTIFICATE----- +MIICDDCCAZGgAwIBAgIQbkepx2ypcyRAiQ8DVd2NHTAKBggqhkjOPQQDAzBHMQswCQYDVQQGEwJV +UzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3Qg +UjMwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAGA1UE +ChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjMwdjAQBgcq +hkjOPQIBBgUrgQQAIgNiAAQfTzOHMymKoYTey8chWEGJ6ladK0uFxh1MJ7x/JlFyb+Kf1qPKzEUU +Rout736GjOyxfi//qXGdGIRFBEFVbivqJn+7kAHjSxm65FSWRQmx1WyRRK2EE46ajA2ADDL24Cej +QjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBTB8Sa6oC2uhYHP +0/EqEr24Cmf9vDAKBggqhkjOPQQDAwNpADBmAjEAgFukfCPAlaUs3L6JbyO5o91lAFJekazInXJ0 +glMLfalAvWhgxeG4VDvBNhcl2MG9AjEAnjWSdIUlUfUk7GRSJFClH9voy8l27OyCbvWFGFPouOOa +KaqW04MjyaR7YbPMAuhd +-----END CERTIFICATE----- + +GTS Root R4 +=========== +-----BEGIN CERTIFICATE----- +MIICCjCCAZGgAwIBAgIQbkepyIuUtui7OyrYorLBmTAKBggqhkjOPQQDAzBHMQswCQYDVQQGEwJV +UzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3Qg +UjQwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAGA1UE +ChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjQwdjAQBgcq +hkjOPQIBBgUrgQQAIgNiAATzdHOnaItgrkO4NcWBMHtLSZ37wWHO5t5GvWvVYRg1rkDdc/eJkTBa +6zzuhXyiQHY7qca4R9gq55KRanPpsXI5nymfopjTX15YhmUPoYRlBtHci8nHc8iMai/lxKvRHYqj +QjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MB0GA1UdDgQWBBSATNbrdP9JNqPV +2Py1PsVq8JQdjDAKBggqhkjOPQQDAwNnADBkAjBqUFJ0CMRw3J5QdCHojXohw0+WbhXRIjVhLfoI +N+4Zba3bssx9BzT1YBkstTTZbyACMANxsbqjYAuG7ZoIapVon+Kz4ZNkfF6Tpt95LY2F45TPI11x +zPKwTdb+mciUqXWi4w== +-----END CERTIFICATE----- + +UCA Global G2 Root +================== +-----BEGIN CERTIFICATE----- +MIIFRjCCAy6gAwIBAgIQXd+x2lqj7V2+WmUgZQOQ7zANBgkqhkiG9w0BAQsFADA9MQswCQYDVQQG +EwJDTjERMA8GA1UECgwIVW5pVHJ1c3QxGzAZBgNVBAMMElVDQSBHbG9iYWwgRzIgUm9vdDAeFw0x +NjAzMTEwMDAwMDBaFw00MDEyMzEwMDAwMDBaMD0xCzAJBgNVBAYTAkNOMREwDwYDVQQKDAhVbmlU +cnVzdDEbMBkGA1UEAwwSVUNBIEdsb2JhbCBHMiBSb290MIICIjANBgkqhkiG9w0BAQEFAAOCAg8A +MIICCgKCAgEAxeYrb3zvJgUno4Ek2m/LAfmZmqkywiKHYUGRO8vDaBsGxUypK8FnFyIdK+35KYmT +oni9kmugow2ifsqTs6bRjDXVdfkX9s9FxeV67HeToI8jrg4aA3++1NDtLnurRiNb/yzmVHqUwCoV +8MmNsHo7JOHXaOIxPAYzRrZUEaalLyJUKlgNAQLx+hVRZ2zA+te2G3/RVogvGjqNO7uCEeBHANBS +h6v7hn4PJGtAnTRnvI3HLYZveT6OqTwXS3+wmeOwcWDcC/Vkw85DvG1xudLeJ1uK6NjGruFZfc8o +LTW4lVYa8bJYS7cSN8h8s+1LgOGN+jIjtm+3SJUIsUROhYw6AlQgL9+/V087OpAh18EmNVQg7Mc/ +R+zvWr9LesGtOxdQXGLYD0tK3Cv6brxzks3sx1DoQZbXqX5t2Okdj4q1uViSukqSKwxW/YDrCPBe +KW4bHAyvj5OJrdu9o54hyokZ7N+1wxrrFv54NkzWbtA+FxyQF2smuvt6L78RHBgOLXMDj6DlNaBa +4kx1HXHhOThTeEDMg5PXCp6dW4+K5OXgSORIskfNTip1KnvyIvbJvgmRlld6iIis7nCs+dwp4wwc +OxJORNanTrAmyPPZGpeRaOrvjUYG0lZFWJo8DA+DuAUlwznPO6Q0ibd5Ei9Hxeepl2n8pndntd97 +8XplFeRhVmUCAwEAAaNCMEAwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wHQYDVR0O +BBYEFIHEjMz15DD/pQwIX4wVZyF0Ad/fMA0GCSqGSIb3DQEBCwUAA4ICAQATZSL1jiutROTL/7lo +5sOASD0Ee/ojL3rtNtqyzm325p7lX1iPyzcyochltq44PTUbPrw7tgTQvPlJ9Zv3hcU2tsu8+Mg5 +1eRfB70VVJd0ysrtT7q6ZHafgbiERUlMjW+i67HM0cOU2kTC5uLqGOiiHycFutfl1qnN3e92mI0A +Ds0b+gO3joBYDic/UvuUospeZcnWhNq5NXHzJsBPd+aBJ9J3O5oUb3n09tDh05S60FdRvScFDcH9 +yBIw7m+NESsIndTUv4BFFJqIRNow6rSn4+7vW4LVPtateJLbXDzz2K36uGt/xDYotgIVilQsnLAX +c47QN6MUPJiVAAwpBVueSUmxX8fjy88nZY41F7dXyDDZQVu5FLbowg+UMaeUmMxq67XhJ/UQqAHo +jhJi6IjMtX9Gl8CbEGY4GjZGXyJoPd/JxhMnq1MGrKI8hgZlb7F+sSlEmqO6SWkoaY/X5V+tBIZk +bxqgDMUIYs6Ao9Dz7GjevjPHF1t/gMRMTLGmhIrDO7gJzRSBuhjjVFc2/tsvfEehOjPI+Vg7RE+x +ygKJBJYoaMVLuCaJu9YzL1DV/pqJuhgyklTGW+Cd+V7lDSKb9triyCGyYiGqhkCyLmTTX8jjfhFn +RR8F/uOi77Oos/N9j/gMHyIfLXC0uAE0djAA5SN4p1bXUB+K+wb1whnw0A== +-----END CERTIFICATE----- + +UCA Extended Validation Root +============================ +-----BEGIN CERTIFICATE----- +MIIFWjCCA0KgAwIBAgIQT9Irj/VkyDOeTzRYZiNwYDANBgkqhkiG9w0BAQsFADBHMQswCQYDVQQG +EwJDTjERMA8GA1UECgwIVW5pVHJ1c3QxJTAjBgNVBAMMHFVDQSBFeHRlbmRlZCBWYWxpZGF0aW9u +IFJvb3QwHhcNMTUwMzEzMDAwMDAwWhcNMzgxMjMxMDAwMDAwWjBHMQswCQYDVQQGEwJDTjERMA8G +A1UECgwIVW5pVHJ1c3QxJTAjBgNVBAMMHFVDQSBFeHRlbmRlZCBWYWxpZGF0aW9uIFJvb3QwggIi +MA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCpCQcoEwKwmeBkqh5DFnpzsZGgdT6o+uM4AHrs +iWogD4vFsJszA1qGxliG1cGFu0/GnEBNyr7uaZa4rYEwmnySBesFK5pI0Lh2PpbIILvSsPGP2KxF +Rv+qZ2C0d35qHzwaUnoEPQc8hQ2E0B92CvdqFN9y4zR8V05WAT558aopO2z6+I9tTcg1367r3CTu +eUWnhbYFiN6IXSV8l2RnCdm/WhUFhvMJHuxYMjMR83dksHYf5BA1FxvyDrFspCqjc/wJHx4yGVMR +59mzLC52LqGj3n5qiAno8geK+LLNEOfic0CTuwjRP+H8C5SzJe98ptfRr5//lpr1kXuYC3fUfugH +0mK1lTnj8/FtDw5lhIpjVMWAtuCeS31HJqcBCF3RiJ7XwzJE+oJKCmhUfzhTA8ykADNkUVkLo4KR +el7sFsLzKuZi2irbWWIQJUoqgQtHB0MGcIfS+pMRKXpITeuUx3BNr2fVUbGAIAEBtHoIppB/TuDv +B0GHr2qlXov7z1CymlSvw4m6WC31MJixNnI5fkkE/SmnTHnkBVfblLkWU41Gsx2VYVdWf6/wFlth +WG82UBEL2KwrlRYaDh8IzTY0ZRBiZtWAXxQgXy0MoHgKaNYs1+lvK9JKBZP8nm9rZ/+I8U6laUpS +NwXqxhaN0sSZ0YIrO7o1dfdRUVjzyAfd5LQDfwIDAQABo0IwQDAdBgNVHQ4EFgQU2XQ65DA9DfcS +3H5aBZ8eNJr34RQwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAYYwDQYJKoZIhvcNAQEL +BQADggIBADaNl8xCFWQpN5smLNb7rhVpLGsaGvdftvkHTFnq88nIua7Mui563MD1sC3AO6+fcAUR +ap8lTwEpcOPlDOHqWnzcSbvBHiqB9RZLcpHIojG5qtr8nR/zXUACE/xOHAbKsxSQVBcZEhrxH9cM +aVr2cXj0lH2RC47skFSOvG+hTKv8dGT9cZr4QQehzZHkPJrgmzI5c6sq1WnIeJEmMX3ixzDx/BR4 +dxIOE/TdFpS/S2d7cFOFyrC78zhNLJA5wA3CXWvp4uXViI3WLL+rG761KIcSF3Ru/H38j9CHJrAb ++7lsq+KePRXBOy5nAliRn+/4Qh8st2j1da3Ptfb/EX3C8CSlrdP6oDyp+l3cpaDvRKS+1ujl5BOW +F3sGPjLtx7dCvHaj2GU4Kzg1USEODm8uNBNA4StnDG1KQTAYI1oyVZnJF+A83vbsea0rWBmirSwi +GpWOvpaQXUJXxPkUAzUrHC1RVwinOt4/5Mi0A3PCwSaAuwtCH60NryZy2sy+s6ODWA2CxR9GUeOc +GMyNm43sSet1UNWMKFnKdDTajAshqx7qG+XH/RU+wBeq+yNuJkbL+vmxcmtpzyKEC2IPrNkZAJSi +djzULZrtBJ4tBmIQN1IchXIbJ+XMxjHsN+xjWZsLHXbMfjKaiJUINlK73nZfdklJrX+9ZSCyycEr +dhh2n1ax +-----END CERTIFICATE----- + +Certigna Root CA +================ +-----BEGIN CERTIFICATE----- +MIIGWzCCBEOgAwIBAgIRAMrpG4nxVQMNo+ZBbcTjpuEwDQYJKoZIhvcNAQELBQAwWjELMAkGA1UE +BhMCRlIxEjAQBgNVBAoMCURoaW15b3RpczEcMBoGA1UECwwTMDAwMiA0ODE0NjMwODEwMDAzNjEZ +MBcGA1UEAwwQQ2VydGlnbmEgUm9vdCBDQTAeFw0xMzEwMDEwODMyMjdaFw0zMzEwMDEwODMyMjda +MFoxCzAJBgNVBAYTAkZSMRIwEAYDVQQKDAlEaGlteW90aXMxHDAaBgNVBAsMEzAwMDIgNDgxNDYz +MDgxMDAwMzYxGTAXBgNVBAMMEENlcnRpZ25hIFJvb3QgQ0EwggIiMA0GCSqGSIb3DQEBAQUAA4IC +DwAwggIKAoICAQDNGDllGlmx6mQWDoyUJJV8g9PFOSbcDO8WV43X2KyjQn+Cyu3NW9sOty3tRQgX +stmzy9YXUnIo245Onoq2C/mehJpNdt4iKVzSs9IGPjA5qXSjklYcoW9MCiBtnyN6tMbaLOQdLNyz +KNAT8kxOAkmhVECe5uUFoC2EyP+YbNDrihqECB63aCPuI9Vwzm1RaRDuoXrC0SIxwoKF0vJVdlB8 +JXrJhFwLrN1CTivngqIkicuQstDuI7pmTLtipPlTWmR7fJj6o0ieD5Wupxj0auwuA0Wv8HT4Ks16 +XdG+RCYyKfHx9WzMfgIhC59vpD++nVPiz32pLHxYGpfhPTc3GGYo0kDFUYqMwy3OU4gkWGQwFsWq +4NYKpkDfePb1BHxpE4S80dGnBs8B92jAqFe7OmGtBIyT46388NtEbVncSVmurJqZNjBBe3YzIoej +wpKGbvlw7q6Hh5UbxHq9MfPU0uWZ/75I7HX1eBYdpnDBfzwboZL7z8g81sWTCo/1VTp2lc5ZmIoJ +lXcymoO6LAQ6l73UL77XbJuiyn1tJslV1c/DeVIICZkHJC1kJWumIWmbat10TWuXekG9qxf5kBdI +jzb5LdXF2+6qhUVB+s06RbFo5jZMm5BX7CO5hwjCxAnxl4YqKE3idMDaxIzb3+KhF1nOJFl0Mdp/ +/TBt2dzhauH8XwIDAQABo4IBGjCCARYwDwYDVR0TAQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYw +HQYDVR0OBBYEFBiHVuBud+4kNTxOc5of1uHieX4rMB8GA1UdIwQYMBaAFBiHVuBud+4kNTxOc5of +1uHieX4rMEQGA1UdIAQ9MDswOQYEVR0gADAxMC8GCCsGAQUFBwIBFiNodHRwczovL3d3d3cuY2Vy +dGlnbmEuZnIvYXV0b3JpdGVzLzBtBgNVHR8EZjBkMC+gLaArhilodHRwOi8vY3JsLmNlcnRpZ25h +LmZyL2NlcnRpZ25hcm9vdGNhLmNybDAxoC+gLYYraHR0cDovL2NybC5kaGlteW90aXMuY29tL2Nl +cnRpZ25hcm9vdGNhLmNybDANBgkqhkiG9w0BAQsFAAOCAgEAlLieT/DjlQgi581oQfccVdV8AOIt +OoldaDgvUSILSo3L6btdPrtcPbEo/uRTVRPPoZAbAh1fZkYJMyjhDSSXcNMQH+pkV5a7XdrnxIxP +TGRGHVyH41neQtGbqH6mid2PHMkwgu07nM3A6RngatgCdTer9zQoKJHyBApPNeNgJgH60BGM+RFq +7q89w1DTj18zeTyGqHNFkIwgtnJzFyO+B2XleJINugHA64wcZr+shncBlA2c5uk5jR+mUYyZDDl3 +4bSb+hxnV29qao6pK0xXeXpXIs/NX2NGjVxZOob4Mkdio2cNGJHc+6Zr9UhhcyNZjgKnvETq9Emd +8VRY+WCv2hikLyhF3HqgiIZd8zvn/yk1gPxkQ5Tm4xxvvq0OKmOZK8l+hfZx6AYDlf7ej0gcWtSS +6Cvu5zHbugRqh5jnxV/vfaci9wHYTfmJ0A6aBVmknpjZbyvKcL5kwlWj9Omvw5Ip3IgWJJk8jSaY +tlu3zM63Nwf9JtmYhST/WSMDmu2dnajkXjjO11INb9I/bbEFa0nOipFGc/T2L/Coc3cOZayhjWZS +aX5LaAzHHjcng6WMxwLkFM1JAbBzs/3GkDpv0mztO+7skb6iQ12LAEpmJURw3kAP+HwV96LOPNde +E4yBFxgX0b3xdxA61GU5wSesVywlVP+i2k+KYTlerj1KjL0= +-----END CERTIFICATE----- + +emSign Root CA - G1 +=================== +-----BEGIN CERTIFICATE----- +MIIDlDCCAnygAwIBAgIKMfXkYgxsWO3W2DANBgkqhkiG9w0BAQsFADBnMQswCQYDVQQGEwJJTjET +MBEGA1UECxMKZW1TaWduIFBLSTElMCMGA1UEChMcZU11ZGhyYSBUZWNobm9sb2dpZXMgTGltaXRl +ZDEcMBoGA1UEAxMTZW1TaWduIFJvb3QgQ0EgLSBHMTAeFw0xODAyMTgxODMwMDBaFw00MzAyMTgx +ODMwMDBaMGcxCzAJBgNVBAYTAklOMRMwEQYDVQQLEwplbVNpZ24gUEtJMSUwIwYDVQQKExxlTXVk +aHJhIFRlY2hub2xvZ2llcyBMaW1pdGVkMRwwGgYDVQQDExNlbVNpZ24gUm9vdCBDQSAtIEcxMIIB +IjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAk0u76WaK7p1b1TST0Bsew+eeuGQzf2N4aLTN +LnF115sgxk0pvLZoYIr3IZpWNVrzdr3YzZr/k1ZLpVkGoZM0Kd0WNHVO8oG0x5ZOrRkVUkr+PHB1 +cM2vK6sVmjM8qrOLqs1D/fXqcP/tzxE7lM5OMhbTI0Aqd7OvPAEsbO2ZLIvZTmmYsvePQbAyeGHW +DV/D+qJAkh1cF+ZwPjXnorfCYuKrpDhMtTk1b+oDafo6VGiFbdbyL0NVHpENDtjVaqSW0RM8LHhQ +6DqS0hdW5TUaQBw+jSztOd9C4INBdN+jzcKGYEho42kLVACL5HZpIQ15TjQIXhTCzLG3rdd8cIrH +hQIDAQABo0IwQDAdBgNVHQ4EFgQU++8Nhp6w492pufEhF38+/PB3KxowDgYDVR0PAQH/BAQDAgEG +MA8GA1UdEwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQADggEBAFn/8oz1h31xPaOfG1vR2vjTnGs2 +vZupYeveFix0PZ7mddrXuqe8QhfnPZHr5X3dPpzxz5KsbEjMwiI/aTvFthUvozXGaCocV685743Q +NcMYDHsAVhzNixl03r4PEuDQqqE/AjSxcM6dGNYIAwlG7mDgfrbESQRRfXBgvKqy/3lyeqYdPV8q ++Mri/Tm3R7nrft8EI6/6nAYH6ftjk4BAtcZsCjEozgyfz7MjNYBBjWzEN3uBL4ChQEKF6dk4jeih +U80Bv2noWgbyRQuQ+q7hv53yrlc8pa6yVvSLZUDp/TGBLPQ5Cdjua6e0ph0VpZj3AYHYhX3zUVxx +iN66zB+Afko= +-----END CERTIFICATE----- + +emSign ECC Root CA - G3 +======================= +-----BEGIN CERTIFICATE----- +MIICTjCCAdOgAwIBAgIKPPYHqWhwDtqLhDAKBggqhkjOPQQDAzBrMQswCQYDVQQGEwJJTjETMBEG +A1UECxMKZW1TaWduIFBLSTElMCMGA1UEChMcZU11ZGhyYSBUZWNobm9sb2dpZXMgTGltaXRlZDEg +MB4GA1UEAxMXZW1TaWduIEVDQyBSb290IENBIC0gRzMwHhcNMTgwMjE4MTgzMDAwWhcNNDMwMjE4 +MTgzMDAwWjBrMQswCQYDVQQGEwJJTjETMBEGA1UECxMKZW1TaWduIFBLSTElMCMGA1UEChMcZU11 +ZGhyYSBUZWNobm9sb2dpZXMgTGltaXRlZDEgMB4GA1UEAxMXZW1TaWduIEVDQyBSb290IENBIC0g +RzMwdjAQBgcqhkjOPQIBBgUrgQQAIgNiAAQjpQy4LRL1KPOxst3iAhKAnjlfSU2fySU0WXTsuwYc +58Byr+iuL+FBVIcUqEqy6HyC5ltqtdyzdc6LBtCGI79G1Y4PPwT01xySfvalY8L1X44uT6EYGQIr +MgqCZH0Wk9GjQjBAMB0GA1UdDgQWBBR8XQKEE9TMipuBzhccLikenEhjQjAOBgNVHQ8BAf8EBAMC +AQYwDwYDVR0TAQH/BAUwAwEB/zAKBggqhkjOPQQDAwNpADBmAjEAvvNhzwIQHWSVB7gYboiFBS+D +CBeQyh+KTOgNG3qxrdWBCUfvO6wIBHxcmbHtRwfSAjEAnbpV/KlK6O3t5nYBQnvI+GDZjVGLVTv7 +jHvrZQnD+JbNR6iC8hZVdyR+EhCVBCyj +-----END CERTIFICATE----- + +emSign Root CA - C1 +=================== +-----BEGIN CERTIFICATE----- +MIIDczCCAlugAwIBAgILAK7PALrEzzL4Q7IwDQYJKoZIhvcNAQELBQAwVjELMAkGA1UEBhMCVVMx +EzARBgNVBAsTCmVtU2lnbiBQS0kxFDASBgNVBAoTC2VNdWRocmEgSW5jMRwwGgYDVQQDExNlbVNp +Z24gUm9vdCBDQSAtIEMxMB4XDTE4MDIxODE4MzAwMFoXDTQzMDIxODE4MzAwMFowVjELMAkGA1UE +BhMCVVMxEzARBgNVBAsTCmVtU2lnbiBQS0kxFDASBgNVBAoTC2VNdWRocmEgSW5jMRwwGgYDVQQD +ExNlbVNpZ24gUm9vdCBDQSAtIEMxMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAz+up +ufGZBczYKCFK83M0UYRWEPWgTywS4/oTmifQz/l5GnRfHXk5/Fv4cI7gklL35CX5VIPZHdPIWoU/ +Xse2B+4+wM6ar6xWQio5JXDWv7V7Nq2s9nPczdcdioOl+yuQFTdrHCZH3DspVpNqs8FqOp099cGX +OFgFixwR4+S0uF2FHYP+eF8LRWgYSKVGczQ7/g/IdrvHGPMF0Ybzhe3nudkyrVWIzqa2kbBPrH4V +I5b2P/AgNBbeCsbEBEV5f6f9vtKppa+cxSMq9zwhbL2vj07FOrLzNBL834AaSaTUqZX3noleooms +lMuoaJuvimUnzYnu3Yy1aylwQ6BpC+S5DwIDAQABo0IwQDAdBgNVHQ4EFgQU/qHgcB4qAzlSWkK+ +XJGFehiqTbUwDgYDVR0PAQH/BAQDAgEGMA8GA1UdEwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQAD +ggEBAMJKVvoVIXsoounlHfv4LcQ5lkFMOycsxGwYFYDGrK9HWS8mC+M2sO87/kOXSTKZEhVb3xEp +/6tT+LvBeA+snFOvV71ojD1pM/CjoCNjO2RnIkSt1XHLVip4kqNPEjE2NuLe/gDEo2APJ62gsIq1 +NnpSob0n9CAnYuhNlCQT5AoE6TyrLshDCUrGYQTlSTR+08TI9Q/Aqum6VF7zYytPT1DU/rl7mYw9 +wC68AivTxEDkigcxHpvOJpkT+xHqmiIMERnHXhuBUDDIlhJu58tBf5E7oke3VIAb3ADMmpDqw8NQ +BmIMMMAVSKeoWXzhriKi4gp6D/piq1JM4fHfyr6DDUI= +-----END CERTIFICATE----- + +emSign ECC Root CA - C3 +======================= +-----BEGIN CERTIFICATE----- +MIICKzCCAbGgAwIBAgIKe3G2gla4EnycqDAKBggqhkjOPQQDAzBaMQswCQYDVQQGEwJVUzETMBEG +A1UECxMKZW1TaWduIFBLSTEUMBIGA1UEChMLZU11ZGhyYSBJbmMxIDAeBgNVBAMTF2VtU2lnbiBF +Q0MgUm9vdCBDQSAtIEMzMB4XDTE4MDIxODE4MzAwMFoXDTQzMDIxODE4MzAwMFowWjELMAkGA1UE +BhMCVVMxEzARBgNVBAsTCmVtU2lnbiBQS0kxFDASBgNVBAoTC2VNdWRocmEgSW5jMSAwHgYDVQQD +ExdlbVNpZ24gRUNDIFJvb3QgQ0EgLSBDMzB2MBAGByqGSM49AgEGBSuBBAAiA2IABP2lYa57JhAd +6bciMK4G9IGzsUJxlTm801Ljr6/58pc1kjZGDoeVjbk5Wum739D+yAdBPLtVb4OjavtisIGJAnB9 +SMVK4+kiVCJNk7tCDK93nCOmfddhEc5lx/h//vXyqaNCMEAwHQYDVR0OBBYEFPtaSNCAIEDyqOkA +B2kZd6fmw/TPMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBAf8EBTADAQH/MAoGCCqGSM49BAMDA2gA +MGUCMQC02C8Cif22TGK6Q04ThHK1rt0c3ta13FaPWEBaLd4gTCKDypOofu4SQMfWh0/434UCMBwU +ZOR8loMRnLDRWmFLpg9J0wD8ofzkpf9/rdcw0Md3f76BB1UwUCAU9Vc4CqgxUQ== +-----END CERTIFICATE----- + +Hongkong Post Root CA 3 +======================= +-----BEGIN CERTIFICATE----- +MIIFzzCCA7egAwIBAgIUCBZfikyl7ADJk0DfxMauI7gcWqQwDQYJKoZIhvcNAQELBQAwbzELMAkG +A1UEBhMCSEsxEjAQBgNVBAgTCUhvbmcgS29uZzESMBAGA1UEBxMJSG9uZyBLb25nMRYwFAYDVQQK +Ew1Ib25na29uZyBQb3N0MSAwHgYDVQQDExdIb25na29uZyBQb3N0IFJvb3QgQ0EgMzAeFw0xNzA2 +MDMwMjI5NDZaFw00MjA2MDMwMjI5NDZaMG8xCzAJBgNVBAYTAkhLMRIwEAYDVQQIEwlIb25nIEtv +bmcxEjAQBgNVBAcTCUhvbmcgS29uZzEWMBQGA1UEChMNSG9uZ2tvbmcgUG9zdDEgMB4GA1UEAxMX +SG9uZ2tvbmcgUG9zdCBSb290IENBIDMwggIiMA0GCSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQCz +iNfqzg8gTr7m1gNt7ln8wlffKWihgw4+aMdoWJwcYEuJQwy51BWy7sFOdem1p+/l6TWZ5Mwc50tf +jTMwIDNT2aa71T4Tjukfh0mtUC1Qyhi+AViiE3CWu4mIVoBc+L0sPOFMV4i707mV78vH9toxdCim +5lSJ9UExyuUmGs2C4HDaOym71QP1mbpV9WTRYA6ziUm4ii8F0oRFKHyPaFASePwLtVPLwpgchKOe +sL4jpNrcyCse2m5FHomY2vkALgbpDDtw1VAliJnLzXNg99X/NWfFobxeq81KuEXryGgeDQ0URhLj +0mRiikKYvLTGCAj4/ahMZJx2Ab0vqWwzD9g/KLg8aQFChn5pwckGyuV6RmXpwtZQQS4/t+TtbNe/ +JgERohYpSms0BpDsE9K2+2p20jzt8NYt3eEV7KObLyzJPivkaTv/ciWxNoZbx39ri1UbSsUgYT2u +y1DhCDq+sI9jQVMwCFk8mB13umOResoQUGC/8Ne8lYePl8X+l2oBlKN8W4UdKjk60FSh0Tlxnf0h ++bV78OLgAo9uliQlLKAeLKjEiafv7ZkGL7YKTE/bosw3Gq9HhS2KX8Q0NEwA/RiTZxPRN+ZItIsG +xVd7GYYKecsAyVKvQv83j+GjHno9UKtjBucVtT+2RTeUN7F+8kjDf8V1/peNRY8apxpyKBpADwID +AQABo2MwYTAPBgNVHRMBAf8EBTADAQH/MA4GA1UdDwEB/wQEAwIBBjAfBgNVHSMEGDAWgBQXnc0e +i9Y5K3DTXNSguB+wAPzFYTAdBgNVHQ4EFgQUF53NHovWOStw01zUoLgfsAD8xWEwDQYJKoZIhvcN +AQELBQADggIBAFbVe27mIgHSQpsY1Q7XZiNc4/6gx5LS6ZStS6LG7BJ8dNVI0lkUmcDrudHr9Egw +W62nV3OZqdPlt9EuWSRY3GguLmLYauRwCy0gUCCkMpXRAJi70/33MvJJrsZ64Ee+bs7Lo3I6LWld +y8joRTnU+kLBEUx3XZL7av9YROXrgZ6voJmtvqkBZss4HTzfQx/0TW60uhdG/H39h4F5ag0zD/ov ++BS5gLNdTaqX4fnkGMX41TiMJjz98iji7lpJiCzfeT2OnpA8vUFKOt1b9pq0zj8lMH8yfaIDlNDc +eqFS3m6TjRgm/VWsvY+b0s+v54Ysyx8Jb6NvqYTUc79NoXQbTiNg8swOqn+knEwlqLJmOzj/2ZQw +9nKEvmhVEA/GcywWaZMH/rFF7buiVWqw2rVKAiUnhde3t4ZEFolsgCs+l6mc1X5VTMbeRRAc6uk7 +nwNT7u56AQIWeNTowr5GdogTPyK7SBIdUgC0An4hGh6cJfTzPV4e0hz5sy229zdcxsshTrD3mUcY +hcErulWuBurQB7Lcq9CClnXO0lD+mefPL5/ndtFhKvshuzHQqp9HpLIiyhY6UFfEW0NnxWViA0kB +60PZ2Pierc+xYw5F9KBaLJstxabArahH9CdMOA0uG0k7UvToiIMrVCjU8jVStDKDYmlkDJGcn5fq +dBb9HxEGmpv0 +-----END CERTIFICATE----- + +Entrust Root Certification Authority - G4 +========================================= +-----BEGIN CERTIFICATE----- +MIIGSzCCBDOgAwIBAgIRANm1Q3+vqTkPAAAAAFVlrVgwDQYJKoZIhvcNAQELBQAwgb4xCzAJBgNV +BAYTAlVTMRYwFAYDVQQKEw1FbnRydXN0LCBJbmMuMSgwJgYDVQQLEx9TZWUgd3d3LmVudHJ1c3Qu +bmV0L2xlZ2FsLXRlcm1zMTkwNwYDVQQLEzAoYykgMjAxNSBFbnRydXN0LCBJbmMuIC0gZm9yIGF1 +dGhvcml6ZWQgdXNlIG9ubHkxMjAwBgNVBAMTKUVudHJ1c3QgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1 +dGhvcml0eSAtIEc0MB4XDTE1MDUyNzExMTExNloXDTM3MTIyNzExNDExNlowgb4xCzAJBgNVBAYT +AlVTMRYwFAYDVQQKEw1FbnRydXN0LCBJbmMuMSgwJgYDVQQLEx9TZWUgd3d3LmVudHJ1c3QubmV0 +L2xlZ2FsLXRlcm1zMTkwNwYDVQQLEzAoYykgMjAxNSBFbnRydXN0LCBJbmMuIC0gZm9yIGF1dGhv +cml6ZWQgdXNlIG9ubHkxMjAwBgNVBAMTKUVudHJ1c3QgUm9vdCBDZXJ0aWZpY2F0aW9uIEF1dGhv +cml0eSAtIEc0MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAsewsQu7i0TD/pZJH4i3D +umSXbcr3DbVZwbPLqGgZ2K+EbTBwXX7zLtJTmeH+H17ZSK9dE43b/2MzTdMAArzE+NEGCJR5WIoV +3imz/f3ET+iq4qA7ec2/a0My3dl0ELn39GjUu9CH1apLiipvKgS1sqbHoHrmSKvS0VnM1n4j5pds +8ELl3FFLFUHtSUrJ3hCX1nbB76W1NhSXNdh4IjVS70O92yfbYVaCNNzLiGAMC1rlLAHGVK/XqsEQ +e9IFWrhAnoanw5CGAlZSCXqc0ieCU0plUmr1POeo8pyvi73TDtTUXm6Hnmo9RR3RXRv06QqsYJn7 +ibT/mCzPfB3pAqoEmh643IhuJbNsZvc8kPNXwbMv9W3y+8qh+CmdRouzavbmZwe+LGcKKh9asj5X +xNMhIWNlUpEbsZmOeX7m640A2Vqq6nPopIICR5b+W45UYaPrL0swsIsjdXJ8ITzI9vF01Bx7owVV +7rtNOzK+mndmnqxpkCIHH2E6lr7lmk/MBTwoWdPBDFSoWWG9yHJM6Nyfh3+9nEg2XpWjDrk4JFX8 +dWbrAuMINClKxuMrLzOg2qOGpRKX/YAr2hRC45K9PvJdXmd0LhyIRyk0X+IyqJwlN4y6mACXi0mW +Hv0liqzc2thddG5msP9E36EYxr5ILzeUePiVSj9/E15dWf10hkNjc0kCAwEAAaNCMEAwDwYDVR0T +AQH/BAUwAwEB/zAOBgNVHQ8BAf8EBAMCAQYwHQYDVR0OBBYEFJ84xFYjwznooHFs6FRM5Og6sb9n +MA0GCSqGSIb3DQEBCwUAA4ICAQAS5UKme4sPDORGpbZgQIeMJX6tuGguW8ZAdjwD+MlZ9POrYs4Q +jbRaZIxowLByQzTSGwv2LFPSypBLhmb8qoMi9IsabyZIrHZ3CL/FmFz0Jomee8O5ZDIBf9PD3Vht +7LGrhFV0d4QEJ1JrhkzO3bll/9bGXp+aEJlLdWr+aumXIOTkdnrG0CSqkM0gkLpHZPt/B7NTeLUK +YvJzQ85BK4FqLoUWlFPUa19yIqtRLULVAJyZv967lDtX/Zr1hstWO1uIAeV8KEsD+UmDfLJ/fOPt +jqF/YFOOVZ1QNBIPt5d7bIdKROf1beyAN/BYGW5KaHbwH5Lk6rWS02FREAutp9lfx1/cH6NcjKF+ +m7ee01ZvZl4HliDtC3T7Zk6LERXpgUl+b7DUUH8i119lAg2m9IUe2K4GS0qn0jFmwvjO5QimpAKW +RGhXxNUzzxkvFMSUHHuk2fCfDrGA4tGeEWSpiBE6doLlYsKA2KSD7ZPvfC+QsDJMlhVoSFLUmQjA +JOgc47OlIQ6SwJAfzyBfyjs4x7dtOvPmRLgOMWuIjnDrnBdSqEGULoe256YSxXXfW8AKbnuk5F6G ++TaU33fD6Q3AOfF5u0aOq0NZJ7cguyPpVkAh7DE9ZapD8j3fcEThuk0mEDuYn/PIjhs4ViFqUZPT +kcpG2om3PVODLAgfi49T3f+sHw== +-----END CERTIFICATE----- diff --git a/vendor/composer/ca-bundle/res/index.php b/vendor/composer/ca-bundle/res/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/composer/ca-bundle/res/index.php +++ b/vendor/composer/ca-bundle/res/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/composer/ca-bundle/src/CaBundle.php b/vendor/composer/ca-bundle/src/CaBundle.php index f86c6ea3f..b0e6948f7 100644 --- a/vendor/composer/ca-bundle/src/CaBundle.php +++ b/vendor/composer/ca-bundle/src/CaBundle.php @@ -1,271 +1,271 @@ - - * - * For the full copyright and license information, please view - * the LICENSE file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Composer\CaBundle; - -use _PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Process\PhpProcess; -/** - * @author Chris Smith - * @author Jordi Boggiano - */ -class CaBundle -{ - private static $caPath; - private static $caFileValidity = array(); - private static $useOpensslParse; - /** - * Returns the system CA bundle path, or a path to the bundled one - * - * This method was adapted from Sslurp. - * https://github.com/EvanDotPro/Sslurp - * - * (c) Evan Coury - * - * For the full copyright and license information, please see below: - * - * Copyright (c) 2013, Evan Coury - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, - * are permitted provided that the following conditions are met: - * - * * Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - * * Redistributions in binary form must reproduce the above copyright notice, - * this list of conditions and the following disclaimer in the documentation - * and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR - * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT - * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS - * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * @param LoggerInterface $logger optional logger for information about which CA files were loaded - * @return string path to a CA bundle file or directory - */ - public static function getSystemCaRootBundlePath(\_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger = null) - { - if (self::$caPath !== null) { - return self::$caPath; - } - $caBundlePaths = array(); - // If SSL_CERT_FILE env variable points to a valid certificate/bundle, use that. - // This mimics how OpenSSL uses the SSL_CERT_FILE env variable. - $caBundlePaths[] = self::getEnvVariable('SSL_CERT_FILE'); - // If SSL_CERT_DIR env variable points to a valid certificate/bundle, use that. - // This mimics how OpenSSL uses the SSL_CERT_FILE env variable. - $caBundlePaths[] = self::getEnvVariable('SSL_CERT_DIR'); - $caBundlePaths[] = \ini_get('openssl.cafile'); - $caBundlePaths[] = \ini_get('openssl.capath'); - $otherLocations = array( - '/etc/pki/tls/certs/ca-bundle.crt', - // Fedora, RHEL, CentOS (ca-certificates package) - '/etc/ssl/certs/ca-certificates.crt', - // Debian, Ubuntu, Gentoo, Arch Linux (ca-certificates package) - '/etc/ssl/ca-bundle.pem', - // SUSE, openSUSE (ca-certificates package) - '/usr/local/share/certs/ca-root-nss.crt', - // FreeBSD (ca_root_nss_package) - '/usr/ssl/certs/ca-bundle.crt', - // Cygwin - '/opt/local/share/curl/curl-ca-bundle.crt', - // OS X macports, curl-ca-bundle package - '/usr/local/share/curl/curl-ca-bundle.crt', - // Default cURL CA bunde path (without --with-ca-bundle option) - '/usr/share/ssl/certs/ca-bundle.crt', - // Really old RedHat? - '/etc/ssl/cert.pem', - // OpenBSD - '/usr/local/etc/ssl/cert.pem', - // FreeBSD 10.x - '/usr/local/etc/openssl/cert.pem', - // OS X homebrew, openssl package - '/usr/local/etc/openssl@1.1/cert.pem', - ); - foreach ($otherLocations as $location) { - $otherLocations[] = \dirname($location); - } - $caBundlePaths = \array_merge($caBundlePaths, $otherLocations); - foreach ($caBundlePaths as $caBundle) { - if (self::caFileUsable($caBundle, $logger)) { - return self::$caPath = $caBundle; - } - if (self::caDirUsable($caBundle)) { - return self::$caPath = $caBundle; - } - } - return self::$caPath = static::getBundledCaBundlePath(); - // Bundled CA file, last resort - } - /** - * Returns the path to the bundled CA file - * - * In case you don't want to trust the user or the system, you can use this directly - * - * @return string path to a CA bundle file - */ - public static function getBundledCaBundlePath() - { - $caBundleFile = __DIR__ . '/../res/cacert.pem'; - // cURL does not understand 'phar://' paths - // see https://github.com/composer/ca-bundle/issues/10 - if (0 === \strpos($caBundleFile, 'phar://')) { - \file_put_contents($tempCaBundleFile = \tempnam(\sys_get_temp_dir(), 'openssl-ca-bundle-'), \file_get_contents($caBundleFile)); - \register_shutdown_function(function () use($tempCaBundleFile) { - @\unlink($tempCaBundleFile); - }); - $caBundleFile = $tempCaBundleFile; - } - return $caBundleFile; - } - /** - * Validates a CA file using opensl_x509_parse only if it is safe to use - * - * @param string $filename - * @param LoggerInterface $logger optional logger for information about which CA files were loaded - * - * @return bool - */ - public static function validateCaFile($filename, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger = null) - { - static $warned = \false; - if (isset(self::$caFileValidity[$filename])) { - return self::$caFileValidity[$filename]; - } - $contents = \file_get_contents($filename); - // assume the CA is valid if php is vulnerable to - // https://www.sektioneins.de/advisories/advisory-012013-php-openssl_x509_parse-memory-corruption-vulnerability.html - if (!static::isOpensslParseSafe()) { - if (!$warned && $logger) { - $logger->warning(\sprintf('Your version of PHP, %s, is affected by CVE-2013-6420 and cannot safely perform certificate validation, we strongly suggest you upgrade.', \PHP_VERSION)); - $warned = \true; - } - $isValid = !empty($contents); - } else { - $contents = \preg_replace("/^(\\-+(?:BEGIN|END))\\s+TRUSTED\\s+(CERTIFICATE\\-+)\$/m", '$1 $2', $contents); - $isValid = (bool) \openssl_x509_parse($contents); - } - if ($logger) { - $logger->debug('Checked CA file ' . \realpath($filename) . ': ' . ($isValid ? 'valid' : 'invalid')); - } - return self::$caFileValidity[$filename] = $isValid; - } - /** - * Test if it is safe to use the PHP function openssl_x509_parse(). - * - * This checks if OpenSSL extensions is vulnerable to remote code execution - * via the exploit documented as CVE-2013-6420. - * - * @return bool - */ - public static function isOpensslParseSafe() - { - if (null !== self::$useOpensslParse) { - return self::$useOpensslParse; - } - if (\PHP_VERSION_ID >= 50600) { - return self::$useOpensslParse = \true; - } - // Vulnerable: - // PHP 5.3.0 - PHP 5.3.27 - // PHP 5.4.0 - PHP 5.4.22 - // PHP 5.5.0 - PHP 5.5.6 - if (\PHP_VERSION_ID < 50400 && \PHP_VERSION_ID >= 50328 || \PHP_VERSION_ID < 50500 && \PHP_VERSION_ID >= 50423 || \PHP_VERSION_ID < 50600 && \PHP_VERSION_ID >= 50507) { - // This version of PHP has the fix for CVE-2013-6420 applied. - return self::$useOpensslParse = \true; - } - if (\defined('PHP_WINDOWS_VERSION_BUILD')) { - // Windows is probably insecure in this case. - return self::$useOpensslParse = \false; - } - $compareDistroVersionPrefix = function ($prefix, $fixedVersion) { - $regex = '{^' . \preg_quote($prefix) . '([0-9]+)$}'; - if (\preg_match($regex, \PHP_VERSION, $m)) { - return (int) $m[1] >= $fixedVersion; - } - return \false; - }; - // Hard coded list of PHP distributions with the fix backported. - if ($compareDistroVersionPrefix('5.3.3-7+squeeze', 18) || $compareDistroVersionPrefix('5.4.4-14+deb7u', 7) || $compareDistroVersionPrefix('5.3.10-1ubuntu3.', 9)) { - return self::$useOpensslParse = \true; - } - // Symfony Process component is missing so we assume it is unsafe at this point - if (!\class_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Process\\PhpProcess')) { - return self::$useOpensslParse = \false; - } - // This is where things get crazy, because distros backport security - // fixes the chances are on NIX systems the fix has been applied but - // it's not possible to verify that from the PHP version. - // - // To verify exec a new PHP process and run the issue testcase with - // known safe input that replicates the bug. - // Based on testcase in https://github.com/php/php-src/commit/c1224573c773b6845e83505f717fbf820fc18415 - // changes in https://github.com/php/php-src/commit/76a7fd893b7d6101300cc656058704a73254d593 - $cert = 'LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUVwRENDQTR5Z0F3SUJBZ0lKQUp6dThyNnU2ZUJjTUEwR0NTcUdTSWIzRFFFQkJRVUFNSUhETVFzd0NRWUQKVlFRR0V3SkVSVEVjTUJvR0ExVUVDQXdUVG05eVpISm9aV2x1TFZkbGMzUm1ZV3hsYmpFUU1BNEdBMVVFQnd3SApTOE9Ed3Jac2JqRVVNQklHQTFVRUNnd0xVMlZyZEdsdmJrVnBibk14SHpBZEJnTlZCQXNNRmsxaGJHbGphVzkxCmN5QkRaWEowSUZObFkzUnBiMjR4SVRBZkJnTlZCQU1NR0cxaGJHbGphVzkxY3k1elpXdDBhVzl1WldsdWN5NWsKWlRFcU1DZ0dDU3FHU0liM0RRRUpBUlliYzNSbFptRnVMbVZ6YzJWeVFITmxhM1JwYjI1bGFXNXpMbVJsTUhVWQpaREU1TnpBd01UQXhNREF3TURBd1dnQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBCkFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUEKQUFBQUFBQVhEVEUwTVRFeU9ERXhNemt6TlZvd2djTXhDekFKQmdOVkJBWVRBa1JGTVJ3d0dnWURWUVFJREJOTwpiM0prY21obGFXNHRWMlZ6ZEdaaGJHVnVNUkF3RGdZRFZRUUhEQWRMdzRQQ3RteHVNUlF3RWdZRFZRUUtEQXRUClpXdDBhVzl1UldsdWN6RWZNQjBHQTFVRUN3d1dUV0ZzYVdOcGIzVnpJRU5sY25RZ1UyVmpkR2x2YmpFaE1COEcKQTFVRUF3d1liV0ZzYVdOcGIzVnpMbk5sYTNScGIyNWxhVzV6TG1SbE1Tb3dLQVlKS29aSWh2Y05BUWtCRmh0egpkR1ZtWVc0dVpYTnpaWEpBYzJWcmRHbHZibVZwYm5NdVpHVXdnZ0VpTUEwR0NTcUdTSWIzRFFFQkFRVUFBNElCCkR3QXdnZ0VLQW9JQkFRRERBZjNobDdKWTBYY0ZuaXlFSnBTU0RxbjBPcUJyNlFQNjV1c0pQUnQvOFBhRG9xQnUKd0VZVC9OYSs2ZnNnUGpDMHVLOURaZ1dnMnRIV1dvYW5TYmxBTW96NVBINlorUzRTSFJaN2UyZERJalBqZGhqaAowbUxnMlVNTzV5cDBWNzk3R2dzOWxOdDZKUmZIODFNTjJvYlhXczROdHp0TE11RDZlZ3FwcjhkRGJyMzRhT3M4CnBrZHVpNVVhd1Raa3N5NXBMUEhxNWNNaEZHbTA2djY1Q0xvMFYyUGQ5K0tBb2tQclBjTjVLTEtlYno3bUxwazYKU01lRVhPS1A0aWRFcXh5UTdPN2ZCdUhNZWRzUWh1K3ByWTNzaTNCVXlLZlF0UDVDWm5YMmJwMHdLSHhYMTJEWAoxbmZGSXQ5RGJHdkhUY3lPdU4rblpMUEJtM3ZXeG50eUlJdlZBZ01CQUFHalFqQkFNQWtHQTFVZEV3UUNNQUF3CkVRWUpZSVpJQVliNFFnRUJCQVFEQWdlQU1Bc0dBMVVkRHdRRUF3SUZvREFUQmdOVkhTVUVEREFLQmdnckJnRUYKQlFjREFqQU5CZ2txaGtpRzl3MEJBUVVGQUFPQ0FRRUFHMGZaWVlDVGJkajFYWWMrMVNub2FQUit2SThDOENhRAo4KzBVWWhkbnlVNGdnYTBCQWNEclk5ZTk0ZUVBdTZacXljRjZGakxxWFhkQWJvcHBXb2NyNlQ2R0QxeDMzQ2tsClZBcnpHL0t4UW9oR0QySmVxa2hJTWxEb214SE83a2EzOStPYThpMnZXTFZ5alU4QVp2V01BcnVIYTRFRU55RzcKbFcyQWFnYUZLRkNyOVRuWFRmcmR4R1ZFYnY3S1ZRNmJkaGc1cDVTanBXSDErTXEwM3VSM1pYUEJZZHlWODMxOQpvMGxWajFLRkkyRENML2xpV2lzSlJvb2YrMWNSMzVDdGQwd1lCY3BCNlRac2xNY09QbDc2ZHdLd0pnZUpvMlFnClpzZm1jMnZDMS9xT2xOdU5xLzBUenprVkd2OEVUVDNDZ2FVK1VYZTRYT1Z2a2NjZWJKbjJkZz09Ci0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0K'; - $script = <<<'EOT' - -error_reporting(-1); -$info = openssl_x509_parse(base64_decode('%s')); -var_dump(PHP_VERSION, $info['issuer']['emailAddress'], $info['validFrom_time_t']); - -EOT; - $script = '<' . "?php\n" . \sprintf($script, $cert); - try { - $process = new \_PhpScoper5ea00cc67502b\Symfony\Component\Process\PhpProcess($script); - $process->mustRun(); - } catch (\Exception $e) { - // In the case of any exceptions just accept it is not possible to - // determine the safety of openssl_x509_parse and bail out. - return self::$useOpensslParse = \false; - } - $output = \preg_split('{\\r?\\n}', \trim($process->getOutput())); - $errorOutput = \trim($process->getErrorOutput()); - if (\count($output) === 3 && $output[0] === \sprintf('string(%d) "%s"', \strlen(\PHP_VERSION), \PHP_VERSION) && $output[1] === 'string(27) "stefan.esser@sektioneins.de"' && $output[2] === 'int(-1)' && \preg_match('{openssl_x509_parse\\(\\): illegal (?:ASN1 data type for|length in) timestamp in - on line \\d+}', $errorOutput)) { - // This PHP has the fix backported probably by a distro security team. - return self::$useOpensslParse = \true; - } - return self::$useOpensslParse = \false; - } - /** - * Resets the static caches - */ - public static function reset() - { - self::$caFileValidity = array(); - self::$caPath = null; - self::$useOpensslParse = null; - } - private static function getEnvVariable($name) - { - if (isset($_SERVER[$name])) { - return (string) $_SERVER[$name]; - } - if (\PHP_SAPI === 'cli' && ($value = \getenv($name)) !== \false && $value !== null) { - return (string) $value; - } - return \false; - } - private static function caFileUsable($certFile, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger = null) - { - return $certFile && @\is_file($certFile) && @\is_readable($certFile) && static::validateCaFile($certFile, $logger); - } - private static function caDirUsable($certDir) - { - return $certDir && @\is_dir($certDir) && @\is_readable($certDir) && \glob($certDir . '/*'); - } -} + + * + * For the full copyright and license information, please view + * the LICENSE file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Composer\CaBundle; + +use _PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Process\PhpProcess; +/** + * @author Chris Smith + * @author Jordi Boggiano + */ +class CaBundle +{ + private static $caPath; + private static $caFileValidity = array(); + private static $useOpensslParse; + /** + * Returns the system CA bundle path, or a path to the bundled one + * + * This method was adapted from Sslurp. + * https://github.com/EvanDotPro/Sslurp + * + * (c) Evan Coury + * + * For the full copyright and license information, please see below: + * + * Copyright (c) 2013, Evan Coury + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, + * are permitted provided that the following conditions are met: + * + * * Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * * Redistributions in binary form must reproduce the above copyright notice, + * this list of conditions and the following disclaimer in the documentation + * and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR + * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * @param LoggerInterface $logger optional logger for information about which CA files were loaded + * @return string path to a CA bundle file or directory + */ + public static function getSystemCaRootBundlePath(\_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger = null) + { + if (self::$caPath !== null) { + return self::$caPath; + } + $caBundlePaths = array(); + // If SSL_CERT_FILE env variable points to a valid certificate/bundle, use that. + // This mimics how OpenSSL uses the SSL_CERT_FILE env variable. + $caBundlePaths[] = self::getEnvVariable('SSL_CERT_FILE'); + // If SSL_CERT_DIR env variable points to a valid certificate/bundle, use that. + // This mimics how OpenSSL uses the SSL_CERT_FILE env variable. + $caBundlePaths[] = self::getEnvVariable('SSL_CERT_DIR'); + $caBundlePaths[] = \ini_get('openssl.cafile'); + $caBundlePaths[] = \ini_get('openssl.capath'); + $otherLocations = array( + '/etc/pki/tls/certs/ca-bundle.crt', + // Fedora, RHEL, CentOS (ca-certificates package) + '/etc/ssl/certs/ca-certificates.crt', + // Debian, Ubuntu, Gentoo, Arch Linux (ca-certificates package) + '/etc/ssl/ca-bundle.pem', + // SUSE, openSUSE (ca-certificates package) + '/usr/local/share/certs/ca-root-nss.crt', + // FreeBSD (ca_root_nss_package) + '/usr/ssl/certs/ca-bundle.crt', + // Cygwin + '/opt/local/share/curl/curl-ca-bundle.crt', + // OS X macports, curl-ca-bundle package + '/usr/local/share/curl/curl-ca-bundle.crt', + // Default cURL CA bunde path (without --with-ca-bundle option) + '/usr/share/ssl/certs/ca-bundle.crt', + // Really old RedHat? + '/etc/ssl/cert.pem', + // OpenBSD + '/usr/local/etc/ssl/cert.pem', + // FreeBSD 10.x + '/usr/local/etc/openssl/cert.pem', + // OS X homebrew, openssl package + '/usr/local/etc/openssl@1.1/cert.pem', + ); + foreach ($otherLocations as $location) { + $otherLocations[] = \dirname($location); + } + $caBundlePaths = \array_merge($caBundlePaths, $otherLocations); + foreach ($caBundlePaths as $caBundle) { + if (self::caFileUsable($caBundle, $logger)) { + return self::$caPath = $caBundle; + } + if (self::caDirUsable($caBundle)) { + return self::$caPath = $caBundle; + } + } + return self::$caPath = static::getBundledCaBundlePath(); + // Bundled CA file, last resort + } + /** + * Returns the path to the bundled CA file + * + * In case you don't want to trust the user or the system, you can use this directly + * + * @return string path to a CA bundle file + */ + public static function getBundledCaBundlePath() + { + $caBundleFile = __DIR__ . '/../res/cacert.pem'; + // cURL does not understand 'phar://' paths + // see https://github.com/composer/ca-bundle/issues/10 + if (0 === \strpos($caBundleFile, 'phar://')) { + \file_put_contents($tempCaBundleFile = \tempnam(\sys_get_temp_dir(), 'openssl-ca-bundle-'), \file_get_contents($caBundleFile)); + \register_shutdown_function(function () use($tempCaBundleFile) { + @\unlink($tempCaBundleFile); + }); + $caBundleFile = $tempCaBundleFile; + } + return $caBundleFile; + } + /** + * Validates a CA file using opensl_x509_parse only if it is safe to use + * + * @param string $filename + * @param LoggerInterface $logger optional logger for information about which CA files were loaded + * + * @return bool + */ + public static function validateCaFile($filename, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger = null) + { + static $warned = \false; + if (isset(self::$caFileValidity[$filename])) { + return self::$caFileValidity[$filename]; + } + $contents = \file_get_contents($filename); + // assume the CA is valid if php is vulnerable to + // https://www.sektioneins.de/advisories/advisory-012013-php-openssl_x509_parse-memory-corruption-vulnerability.html + if (!static::isOpensslParseSafe()) { + if (!$warned && $logger) { + $logger->warning(\sprintf('Your version of PHP, %s, is affected by CVE-2013-6420 and cannot safely perform certificate validation, we strongly suggest you upgrade.', \PHP_VERSION)); + $warned = \true; + } + $isValid = !empty($contents); + } else { + $contents = \preg_replace("/^(\\-+(?:BEGIN|END))\\s+TRUSTED\\s+(CERTIFICATE\\-+)\$/m", '$1 $2', $contents); + $isValid = (bool) \openssl_x509_parse($contents); + } + if ($logger) { + $logger->debug('Checked CA file ' . \realpath($filename) . ': ' . ($isValid ? 'valid' : 'invalid')); + } + return self::$caFileValidity[$filename] = $isValid; + } + /** + * Test if it is safe to use the PHP function openssl_x509_parse(). + * + * This checks if OpenSSL extensions is vulnerable to remote code execution + * via the exploit documented as CVE-2013-6420. + * + * @return bool + */ + public static function isOpensslParseSafe() + { + if (null !== self::$useOpensslParse) { + return self::$useOpensslParse; + } + if (\PHP_VERSION_ID >= 50600) { + return self::$useOpensslParse = \true; + } + // Vulnerable: + // PHP 5.3.0 - PHP 5.3.27 + // PHP 5.4.0 - PHP 5.4.22 + // PHP 5.5.0 - PHP 5.5.6 + if (\PHP_VERSION_ID < 50400 && \PHP_VERSION_ID >= 50328 || \PHP_VERSION_ID < 50500 && \PHP_VERSION_ID >= 50423 || \PHP_VERSION_ID < 50600 && \PHP_VERSION_ID >= 50507) { + // This version of PHP has the fix for CVE-2013-6420 applied. + return self::$useOpensslParse = \true; + } + if (\defined('PHP_WINDOWS_VERSION_BUILD')) { + // Windows is probably insecure in this case. + return self::$useOpensslParse = \false; + } + $compareDistroVersionPrefix = function ($prefix, $fixedVersion) { + $regex = '{^' . \preg_quote($prefix) . '([0-9]+)$}'; + if (\preg_match($regex, \PHP_VERSION, $m)) { + return (int) $m[1] >= $fixedVersion; + } + return \false; + }; + // Hard coded list of PHP distributions with the fix backported. + if ($compareDistroVersionPrefix('5.3.3-7+squeeze', 18) || $compareDistroVersionPrefix('5.4.4-14+deb7u', 7) || $compareDistroVersionPrefix('5.3.10-1ubuntu3.', 9)) { + return self::$useOpensslParse = \true; + } + // Symfony Process component is missing so we assume it is unsafe at this point + if (!\class_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Process\\PhpProcess')) { + return self::$useOpensslParse = \false; + } + // This is where things get crazy, because distros backport security + // fixes the chances are on NIX systems the fix has been applied but + // it's not possible to verify that from the PHP version. + // + // To verify exec a new PHP process and run the issue testcase with + // known safe input that replicates the bug. + // Based on testcase in https://github.com/php/php-src/commit/c1224573c773b6845e83505f717fbf820fc18415 + // changes in https://github.com/php/php-src/commit/76a7fd893b7d6101300cc656058704a73254d593 + $cert = 'LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUVwRENDQTR5Z0F3SUJBZ0lKQUp6dThyNnU2ZUJjTUEwR0NTcUdTSWIzRFFFQkJRVUFNSUhETVFzd0NRWUQKVlFRR0V3SkVSVEVjTUJvR0ExVUVDQXdUVG05eVpISm9aV2x1TFZkbGMzUm1ZV3hsYmpFUU1BNEdBMVVFQnd3SApTOE9Ed3Jac2JqRVVNQklHQTFVRUNnd0xVMlZyZEdsdmJrVnBibk14SHpBZEJnTlZCQXNNRmsxaGJHbGphVzkxCmN5QkRaWEowSUZObFkzUnBiMjR4SVRBZkJnTlZCQU1NR0cxaGJHbGphVzkxY3k1elpXdDBhVzl1WldsdWN5NWsKWlRFcU1DZ0dDU3FHU0liM0RRRUpBUlliYzNSbFptRnVMbVZ6YzJWeVFITmxhM1JwYjI1bGFXNXpMbVJsTUhVWQpaREU1TnpBd01UQXhNREF3TURBd1dnQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBCkFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUEKQUFBQUFBQVhEVEUwTVRFeU9ERXhNemt6TlZvd2djTXhDekFKQmdOVkJBWVRBa1JGTVJ3d0dnWURWUVFJREJOTwpiM0prY21obGFXNHRWMlZ6ZEdaaGJHVnVNUkF3RGdZRFZRUUhEQWRMdzRQQ3RteHVNUlF3RWdZRFZRUUtEQXRUClpXdDBhVzl1UldsdWN6RWZNQjBHQTFVRUN3d1dUV0ZzYVdOcGIzVnpJRU5sY25RZ1UyVmpkR2x2YmpFaE1COEcKQTFVRUF3d1liV0ZzYVdOcGIzVnpMbk5sYTNScGIyNWxhVzV6TG1SbE1Tb3dLQVlKS29aSWh2Y05BUWtCRmh0egpkR1ZtWVc0dVpYTnpaWEpBYzJWcmRHbHZibVZwYm5NdVpHVXdnZ0VpTUEwR0NTcUdTSWIzRFFFQkFRVUFBNElCCkR3QXdnZ0VLQW9JQkFRRERBZjNobDdKWTBYY0ZuaXlFSnBTU0RxbjBPcUJyNlFQNjV1c0pQUnQvOFBhRG9xQnUKd0VZVC9OYSs2ZnNnUGpDMHVLOURaZ1dnMnRIV1dvYW5TYmxBTW96NVBINlorUzRTSFJaN2UyZERJalBqZGhqaAowbUxnMlVNTzV5cDBWNzk3R2dzOWxOdDZKUmZIODFNTjJvYlhXczROdHp0TE11RDZlZ3FwcjhkRGJyMzRhT3M4CnBrZHVpNVVhd1Raa3N5NXBMUEhxNWNNaEZHbTA2djY1Q0xvMFYyUGQ5K0tBb2tQclBjTjVLTEtlYno3bUxwazYKU01lRVhPS1A0aWRFcXh5UTdPN2ZCdUhNZWRzUWh1K3ByWTNzaTNCVXlLZlF0UDVDWm5YMmJwMHdLSHhYMTJEWAoxbmZGSXQ5RGJHdkhUY3lPdU4rblpMUEJtM3ZXeG50eUlJdlZBZ01CQUFHalFqQkFNQWtHQTFVZEV3UUNNQUF3CkVRWUpZSVpJQVliNFFnRUJCQVFEQWdlQU1Bc0dBMVVkRHdRRUF3SUZvREFUQmdOVkhTVUVEREFLQmdnckJnRUYKQlFjREFqQU5CZ2txaGtpRzl3MEJBUVVGQUFPQ0FRRUFHMGZaWVlDVGJkajFYWWMrMVNub2FQUit2SThDOENhRAo4KzBVWWhkbnlVNGdnYTBCQWNEclk5ZTk0ZUVBdTZacXljRjZGakxxWFhkQWJvcHBXb2NyNlQ2R0QxeDMzQ2tsClZBcnpHL0t4UW9oR0QySmVxa2hJTWxEb214SE83a2EzOStPYThpMnZXTFZ5alU4QVp2V01BcnVIYTRFRU55RzcKbFcyQWFnYUZLRkNyOVRuWFRmcmR4R1ZFYnY3S1ZRNmJkaGc1cDVTanBXSDErTXEwM3VSM1pYUEJZZHlWODMxOQpvMGxWajFLRkkyRENML2xpV2lzSlJvb2YrMWNSMzVDdGQwd1lCY3BCNlRac2xNY09QbDc2ZHdLd0pnZUpvMlFnClpzZm1jMnZDMS9xT2xOdU5xLzBUenprVkd2OEVUVDNDZ2FVK1VYZTRYT1Z2a2NjZWJKbjJkZz09Ci0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0K'; + $script = <<<'EOT' + +error_reporting(-1); +$info = openssl_x509_parse(base64_decode('%s')); +var_dump(PHP_VERSION, $info['issuer']['emailAddress'], $info['validFrom_time_t']); + +EOT; + $script = '<' . "?php\n" . \sprintf($script, $cert); + try { + $process = new \_PhpScoper5ea00cc67502b\Symfony\Component\Process\PhpProcess($script); + $process->mustRun(); + } catch (\Exception $e) { + // In the case of any exceptions just accept it is not possible to + // determine the safety of openssl_x509_parse and bail out. + return self::$useOpensslParse = \false; + } + $output = \preg_split('{\\r?\\n}', \trim($process->getOutput())); + $errorOutput = \trim($process->getErrorOutput()); + if (\count($output) === 3 && $output[0] === \sprintf('string(%d) "%s"', \strlen(\PHP_VERSION), \PHP_VERSION) && $output[1] === 'string(27) "stefan.esser@sektioneins.de"' && $output[2] === 'int(-1)' && \preg_match('{openssl_x509_parse\\(\\): illegal (?:ASN1 data type for|length in) timestamp in - on line \\d+}', $errorOutput)) { + // This PHP has the fix backported probably by a distro security team. + return self::$useOpensslParse = \true; + } + return self::$useOpensslParse = \false; + } + /** + * Resets the static caches + */ + public static function reset() + { + self::$caFileValidity = array(); + self::$caPath = null; + self::$useOpensslParse = null; + } + private static function getEnvVariable($name) + { + if (isset($_SERVER[$name])) { + return (string) $_SERVER[$name]; + } + if (\PHP_SAPI === 'cli' && ($value = \getenv($name)) !== \false && $value !== null) { + return (string) $value; + } + return \false; + } + private static function caFileUsable($certFile, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger = null) + { + return $certFile && @\is_file($certFile) && @\is_readable($certFile) && static::validateCaFile($certFile, $logger); + } + private static function caDirUsable($certDir) + { + return $certDir && @\is_dir($certDir) && @\is_readable($certDir) && \glob($certDir . '/*'); + } +} diff --git a/vendor/composer/ca-bundle/src/index.php b/vendor/composer/ca-bundle/src/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/composer/ca-bundle/src/index.php +++ b/vendor/composer/ca-bundle/src/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/composer/index.php b/vendor/composer/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/composer/index.php +++ b/vendor/composer/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index 6e0f444e1..3e5a7719b 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -1,1478 +1,1478 @@ -[ - { - "name": "composer\/ca-bundle", - "version": "1.2.7", - "version_normalized": "1.2.7.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/composer\/ca-bundle.git", - "reference": "95c63ab2117a72f48f5a55da9740a3273d45b7fd" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/composer\/ca-bundle\/zipball\/95c63ab2117a72f48f5a55da9740a3273d45b7fd", - "reference": "95c63ab2117a72f48f5a55da9740a3273d45b7fd", - "shasum": "" - }, - "require": { - "ext-openssl": "*", - "ext-pcre": "*", - "php": "^5.3.2 || ^7.0 || ^8.0" - }, - "require-dev": { - "phpunit\/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8", - "psr\/log": "^1.0", - "symfony\/process": "^2.5 || ^3.0 || ^4.0 || ^5.0" - }, - "time": "2020-04-08T08:27:21+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\": "src" - } - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http:\/\/seld.be" - } - ], - "description": "Lets you find a path to the system CA bundle, and includes a fallback to the Mozilla CA bundle.", - "keywords": [ - "cabundle", - "cacert", - "certificate", - "ssl", - "tls" - ] - }, - { - "name": "guzzlehttp\/guzzle", - "version": "6.5.3", - "version_normalized": "6.5.3.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/guzzle\/guzzle.git", - "reference": "aab4ebd862aa7d04f01a4b51849d657db56d882e" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/guzzle\/guzzle\/zipball\/aab4ebd862aa7d04f01a4b51849d657db56d882e", - "reference": "aab4ebd862aa7d04f01a4b51849d657db56d882e", - "shasum": "" - }, - "require": { - "ext-json": "*", - "guzzlehttp\/promises": "^1.0", - "guzzlehttp\/psr7": "^1.6.1", - "php": ">=5.5", - "symfony\/polyfill-intl-idn": "^1.11" - }, - "require-dev": { - "ext-curl": "*", - "phpunit\/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", - "psr\/log": "^1.1" - }, - "suggest": { - "psr\/log": "Required for using the Log middleware" - }, - "time": "2020-04-18T10:38:46+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "6.5-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\GuzzleHttp\\": "src\/" - }, - "files": [ - "src\/functions_include.php" - ] - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https:\/\/github.com\/mtdowling" - } - ], - "description": "Guzzle is a PHP HTTP client library", - "homepage": "http:\/\/guzzlephp.org\/", - "keywords": [ - "client", - "curl", - "framework", - "http", - "http client", - "rest", - "web service" - ] - }, - { - "name": "guzzlehttp\/promises", - "version": "v1.3.1", - "version_normalized": "1.3.1.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/guzzle\/promises.git", - "reference": "a59da6cf61d80060647ff4d3eb2c03a2bc694646" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/guzzle\/promises\/zipball\/a59da6cf61d80060647ff4d3eb2c03a2bc694646", - "reference": "a59da6cf61d80060647ff4d3eb2c03a2bc694646", - "shasum": "" - }, - "require": { - "php": ">=5.5.0" - }, - "require-dev": { - "phpunit\/phpunit": "^4.0" - }, - "time": "2016-12-20T10:07:11+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.4-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\": "src\/" - }, - "files": [ - "src\/functions_include.php" - ] - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https:\/\/github.com\/mtdowling" - } - ], - "description": "Guzzle promises library", - "keywords": [ - "promise" - ] - }, - { - "name": "guzzlehttp\/psr7", - "version": "1.6.1", - "version_normalized": "1.6.1.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/guzzle\/psr7.git", - "reference": "239400de7a173fe9901b9ac7c06497751f00727a" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/guzzle\/psr7\/zipball\/239400de7a173fe9901b9ac7c06497751f00727a", - "reference": "239400de7a173fe9901b9ac7c06497751f00727a", - "shasum": "" - }, - "require": { - "php": ">=5.4.0", - "psr\/http-message": "~1.0", - "ralouphie\/getallheaders": "^2.0.5 || ^3.0.0" - }, - "provide": { - "psr\/http-message-implementation": "1.0" - }, - "require-dev": { - "ext-zlib": "*", - "phpunit\/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8" - }, - "suggest": { - "zendframework\/zend-httphandlerrunner": "Emit PSR-7 responses" - }, - "time": "2019-07-01T23:21:34+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.6-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\": "src\/" - }, - "files": [ - "src\/functions_include.php" - ] - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https:\/\/github.com\/mtdowling" - }, - { - "name": "Tobias Schultze", - "homepage": "https:\/\/github.com\/Tobion" - } - ], - "description": "PSR-7 message implementation that also provides common utility methods", - "keywords": [ - "http", - "message", - "psr-7", - "request", - "response", - "stream", - "uri", - "url" - ] - }, - { - "name": "mollie\/mollie-api-php", - "version": "v2.17.0", - "version_normalized": "2.17.0.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/mollie\/mollie-api-php.git", - "reference": "ee22d0301aee55a41ef2e7d201ef29f86550d1f7" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/mollie\/mollie-api-php\/zipball\/ee22d0301aee55a41ef2e7d201ef29f86550d1f7", - "reference": "ee22d0301aee55a41ef2e7d201ef29f86550d1f7", - "shasum": "" - }, - "require": { - "composer\/ca-bundle": "^1.1", - "ext-curl": "*", - "ext-json": "*", - "ext-openssl": "*", - "guzzlehttp\/guzzle": "^6.3", - "php": ">=5.6" - }, - "require-dev": { - "eloquent\/liberator": "^2.0", - "phpunit\/phpunit": "^5.7 || ^6.5 || ^7.1" - }, - "suggest": { - "mollie\/oauth2-mollie-php": "Use OAuth to authenticate with the Mollie API. This is needed for some endpoints. Visit https:\/\/docs.mollie.com\/ for more information." - }, - "time": "2020-02-25T12:19:37+00:00", - "type": "library", - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Mollie\\Api\\": "src\/" - } - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "BSD-2-Clause" - ], - "authors": [ - { - "name": "Mollie B.V.", - "email": "info@mollie.com" - } - ], - "description": "Mollie API client library for PHP. Mollie is a European Payment Service provider and offers international payment methods such as Mastercard, VISA, American Express and PayPal, and local payment methods such as iDEAL, Bancontact, SOFORT Banking, SEPA direct debit, Belfius Direct Net, KBC Payment Button and various gift cards such as Podiumcadeaukaart and fashioncheque.", - "homepage": "https:\/\/www.mollie.com\/en\/developers", - "keywords": [ - "Apple Pay", - "CBC", - "Przelewy24", - "api", - "bancontact", - "banktransfer", - "belfius", - "belfius direct net", - "charges", - "creditcard", - "direct debit", - "fashioncheque", - "gateway", - "gift cards", - "ideal", - "inghomepay", - "intersolve", - "kbc", - "klarna", - "mistercash", - "mollie", - "paylater", - "payment", - "payments", - "paypal", - "paysafecard", - "podiumcadeaukaart", - "recurring", - "refunds", - "sepa", - "service", - "sliceit", - "sofort", - "sofortbanking", - "subscriptions" - ] - }, - { - "name": "paragonie\/random_compat", - "version": "v2.0.18", - "version_normalized": "2.0.18.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/paragonie\/random_compat.git", - "reference": "0a58ef6e3146256cc3dc7cc393927bcc7d1b72db" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/paragonie\/random_compat\/zipball\/0a58ef6e3146256cc3dc7cc393927bcc7d1b72db", - "reference": "0a58ef6e3146256cc3dc7cc393927bcc7d1b72db", - "shasum": "" - }, - "require": { - "php": ">=5.2.0" - }, - "require-dev": { - "phpunit\/phpunit": "4.*|5.*" - }, - "suggest": { - "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." - }, - "time": "2019-01-03T20:59:08+00:00", - "type": "library", - "installation-source": "dist", - "autoload": { - "files": [ - "lib\/random.php" - ] - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Paragon Initiative Enterprises", - "email": "security@paragonie.com", - "homepage": "https:\/\/paragonie.com" - } - ], - "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", - "keywords": [ - "csprng", - "polyfill", - "pseudorandom", - "random" - ] - }, - { - "name": "prestashop\/decimal", - "version": "1.3.0", - "version_normalized": "1.3.0.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/PrestaShop\/decimal.git", - "reference": "8b7f47671bb691bd463743d1cbab5b519fbd6849" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/PrestaShop\/decimal\/zipball\/8b7f47671bb691bd463743d1cbab5b519fbd6849", - "reference": "8b7f47671bb691bd463743d1cbab5b519fbd6849", - "shasum": "" - }, - "require": { - "php": ">=5.4" - }, - "require-dev": { - "codacy\/coverage": "dev-master", - "phpunit\/phpunit": "4.*" - }, - "time": "2020-04-15T07:39:20+00:00", - "type": "library", - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\": "src" - } - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PrestaShop SA", - "email": "contact@prestashop.com" - }, - { - "name": "Pablo Borowicz", - "email": "pablo.borowicz@prestashop.com" - } - ], - "description": "Object-oriented wrapper\/shim for BC Math PHP extension. Allows for arbitrary-precision math operations.", - "homepage": "https:\/\/github.com\/prestashop\/decimal", - "keywords": [ - "bcmath", - "decimal", - "math", - "precision", - "prestashop" - ] - }, - { - "name": "psr\/cache", - "version": "1.0.1", - "version_normalized": "1.0.1.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/php-fig\/cache.git", - "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/php-fig\/cache\/zipball\/d11b50ad223250cf17b86e38383413f5a6764bf8", - "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "time": "2016-08-06T20:24:11+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Psr\\Cache\\": "src\/" - } - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http:\/\/www.php-fig.org\/" - } - ], - "description": "Common interface for caching libraries", - "keywords": [ - "cache", - "psr", - "psr-6" - ] - }, - { - "name": "psr\/container", - "version": "1.0.0", - "version_normalized": "1.0.0.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/php-fig\/container.git", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/php-fig\/container\/zipball\/b7ce3b176482dbbc1245ebf52b181af44c2cf55f", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "time": "2017-02-14T16:28:37+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Psr\\Container\\": "src\/" - } - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http:\/\/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" - ] - }, - { - "name": "psr\/http-message", - "version": "1.0.1", - "version_normalized": "1.0.1.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/php-fig\/http-message.git", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/php-fig\/http-message\/zipball\/f6561bf28d520154e4b0ec72be95418abe6d9363", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "time": "2016-08-06T14:39:51+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\": "src\/" - } - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http:\/\/www.php-fig.org\/" - } - ], - "description": "Common interface for HTTP messages", - "homepage": "https:\/\/github.com\/php-fig\/http-message", - "keywords": [ - "http", - "http-message", - "psr", - "psr-7", - "request", - "response" - ] - }, - { - "name": "psr\/log", - "version": "1.1.3", - "version_normalized": "1.1.3.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/php-fig\/log.git", - "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/php-fig\/log\/zipball\/0f73288fd15629204f9d42b7055f72dacbe811fc", - "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "time": "2020-03-23T09:12:05+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Psr\\Log\\": "Psr\/Log\/" - } - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http:\/\/www.php-fig.org\/" - } - ], - "description": "Common interface for logging libraries", - "homepage": "https:\/\/github.com\/php-fig\/log", - "keywords": [ - "log", - "psr", - "psr-3" - ] - }, - { - "name": "psr\/simple-cache", - "version": "1.0.1", - "version_normalized": "1.0.1.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/php-fig\/simple-cache.git", - "reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/php-fig\/simple-cache\/zipball\/408d5eafb83c57f6365a3ca330ff23aa4a5fa39b", - "reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "time": "2017-10-23T01:57:42+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\": "src\/" - } - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http:\/\/www.php-fig.org\/" - } - ], - "description": "Common interfaces for simple caching", - "keywords": [ - "cache", - "caching", - "psr", - "psr-16", - "simple-cache" - ] - }, - { - "name": "ralouphie\/getallheaders", - "version": "3.0.3", - "version_normalized": "3.0.3.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/ralouphie\/getallheaders.git", - "reference": "120b605dfeb996808c31b6477290a714d356e822" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/ralouphie\/getallheaders\/zipball\/120b605dfeb996808c31b6477290a714d356e822", - "reference": "120b605dfeb996808c31b6477290a714d356e822", - "shasum": "" - }, - "require": { - "php": ">=5.6" - }, - "require-dev": { - "php-coveralls\/php-coveralls": "^2.1", - "phpunit\/phpunit": "^5 || ^6.5" - }, - "time": "2019-03-08T08:55:37+00:00", - "type": "library", - "installation-source": "dist", - "autoload": { - "files": [ - "src\/getallheaders.php" - ] - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Ralph Khattar", - "email": "ralph.khattar@gmail.com" - } - ], - "description": "A polyfill for getallheaders." - }, - { - "name": "symfony\/cache", - "version": "v3.4.39", - "version_normalized": "3.4.39.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/cache.git", - "reference": "04860ece0f3996781c2fb04811a6c160a4b910ee" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/cache\/zipball\/04860ece0f3996781c2fb04811a6c160a4b910ee", - "reference": "04860ece0f3996781c2fb04811a6c160a4b910ee", - "shasum": "" - }, - "require": { - "php": "^5.5.9|>=7.0.8", - "psr\/cache": "~1.0", - "psr\/log": "~1.0", - "psr\/simple-cache": "^1.0", - "symfony\/polyfill-apcu": "~1.1" - }, - "conflict": { - "symfony\/var-dumper": "<3.3" - }, - "provide": { - "psr\/cache-implementation": "1.0", - "psr\/simple-cache-implementation": "1.0" - }, - "require-dev": { - "cache\/integration-tests": "dev-master", - "doctrine\/cache": "~1.6", - "doctrine\/dbal": "~2.4", - "predis\/predis": "~1.0" - }, - "time": "2020-03-16T15:51:59+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\": "" - }, - "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": "Symfony Cache component with PSR-6, PSR-16, and tags", - "homepage": "https:\/\/symfony.com", - "keywords": [ - "caching", - "psr6" - ] - }, - { - "name": "symfony\/config", - "version": "v3.4.39", - "version_normalized": "3.4.39.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/config.git", - "reference": "fc5be36e0659ab6e58cc069e8845f0819e6d086e" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/config\/zipball\/fc5be36e0659ab6e58cc069e8845f0819e6d086e", - "reference": "fc5be36e0659ab6e58cc069e8845f0819e6d086e", - "shasum": "" - }, - "require": { - "php": "^5.5.9|>=7.0.8", - "symfony\/filesystem": "~2.8|~3.0|~4.0", - "symfony\/polyfill-ctype": "~1.8" - }, - "conflict": { - "symfony\/dependency-injection": "<3.3", - "symfony\/finder": "<3.3" - }, - "require-dev": { - "symfony\/dependency-injection": "~3.3|~4.0", - "symfony\/event-dispatcher": "~3.3|~4.0", - "symfony\/finder": "~3.3|~4.0", - "symfony\/yaml": "~3.0|~4.0" - }, - "suggest": { - "symfony\/yaml": "To use the yaml reference dumper" - }, - "time": "2020-03-16T08:31:04+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\": "" - }, - "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": "Symfony Config Component", - "homepage": "https:\/\/symfony.com" - }, - { - "name": "symfony\/dependency-injection", - "version": "v3.4.39", - "version_normalized": "3.4.39.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/dependency-injection.git", - "reference": "f516f2bd2f43c82124392fa0a846d8c3261b324b" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/dependency-injection\/zipball\/f516f2bd2f43c82124392fa0a846d8c3261b324b", - "reference": "f516f2bd2f43c82124392fa0a846d8c3261b324b", - "shasum": "" - }, - "require": { - "php": "^5.5.9|>=7.0.8", - "psr\/container": "^1.0" - }, - "conflict": { - "symfony\/config": "<3.3.7", - "symfony\/finder": "<3.3", - "symfony\/proxy-manager-bridge": "<3.4", - "symfony\/yaml": "<3.4" - }, - "provide": { - "psr\/container-implementation": "1.0" - }, - "require-dev": { - "symfony\/config": "~3.3|~4.0", - "symfony\/expression-language": "~2.8|~3.0|~4.0", - "symfony\/yaml": "~3.4|~4.0" - }, - "suggest": { - "symfony\/config": "", - "symfony\/expression-language": "For using expressions in service container configuration", - "symfony\/finder": "For using double-star glob patterns or when GLOB_BRACE portability is required", - "symfony\/proxy-manager-bridge": "Generate service proxies to lazy load them", - "symfony\/yaml": "" - }, - "time": "2020-03-16T08:31:04+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\": "" - }, - "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": "Symfony DependencyInjection Component", - "homepage": "https:\/\/symfony.com" - }, - { - "name": "symfony\/expression-language", - "version": "v3.4.39", - "version_normalized": "3.4.39.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/expression-language.git", - "reference": "206165f46c660f3231df0afbdeec6a62f81afc59" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/expression-language\/zipball\/206165f46c660f3231df0afbdeec6a62f81afc59", - "reference": "206165f46c660f3231df0afbdeec6a62f81afc59", - "shasum": "" - }, - "require": { - "php": "^5.5.9|>=7.0.8", - "symfony\/cache": "~3.1|~4.0", - "symfony\/polyfill-php70": "~1.6" - }, - "time": "2020-03-16T08:31:04+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\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": "Symfony ExpressionLanguage Component", - "homepage": "https:\/\/symfony.com" - }, - { - "name": "symfony\/filesystem", - "version": "v3.4.39", - "version_normalized": "3.4.39.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/filesystem.git", - "reference": "ec47520778d524b1736e768e0678cd1f01c03019" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/filesystem\/zipball\/ec47520778d524b1736e768e0678cd1f01c03019", - "reference": "ec47520778d524b1736e768e0678cd1f01c03019", - "shasum": "" - }, - "require": { - "php": "^5.5.9|>=7.0.8", - "symfony\/polyfill-ctype": "~1.8" - }, - "time": "2020-03-16T08:31:04+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\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": "Symfony Filesystem Component", - "homepage": "https:\/\/symfony.com" - }, - { - "name": "symfony\/polyfill-apcu", - "version": "v1.15.0", - "version_normalized": "1.15.0.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/polyfill-apcu.git", - "reference": "d6b5c4ac62cd4ed622e583d027ae684de2d3c4bd" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-apcu\/zipball\/d6b5c4ac62cd4ed622e583d027ae684de2d3c4bd", - "reference": "d6b5c4ac62cd4ed622e583d027ae684de2d3c4bd", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "time": "2020-02-27T09:26:54+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\": "" - }, - "files": [ - "bootstrap.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": "Symfony polyfill backporting apcu_* functions to lower PHP versions", - "homepage": "https:\/\/symfony.com", - "keywords": [ - "apcu", - "compatibility", - "polyfill", - "portable", - "shim" - ] - }, - { - "name": "symfony\/polyfill-ctype", - "version": "v1.15.0", - "version_normalized": "1.15.0.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/polyfill-ctype.git", - "reference": "4719fa9c18b0464d399f1a63bf624b42b6fa8d14" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-ctype\/zipball\/4719fa9c18b0464d399f1a63bf624b42b6fa8d14", - "reference": "4719fa9c18b0464d399f1a63bf624b42b6fa8d14", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "suggest": { - "ext-ctype": "For best performance" - }, - "time": "2020-02-27T09:26:54+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "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" - ] - }, - { - "name": "symfony\/polyfill-intl-idn", - "version": "v1.15.0", - "version_normalized": "1.15.0.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/polyfill-intl-idn.git", - "reference": "47bd6aa45beb1cd7c6a16b7d1810133b728bdfcf" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-intl-idn\/zipball\/47bd6aa45beb1cd7c6a16b7d1810133b728bdfcf", - "reference": "47bd6aa45beb1cd7c6a16b7d1810133b728bdfcf", - "shasum": "" - }, - "require": { - "php": ">=5.3.3", - "symfony\/polyfill-mbstring": "^1.3", - "symfony\/polyfill-php72": "^1.10" - }, - "suggest": { - "ext-intl": "For best performance" - }, - "time": "2020-03-09T19:04:49+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https:\/\/packagist.org\/downloads\/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Laurent Bassin", - "email": "laurent@bassin.info" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "description": "Symfony polyfill for intl's idn_to_ascii and idn_to_utf8 functions", - "homepage": "https:\/\/symfony.com", - "keywords": [ - "compatibility", - "idn", - "intl", - "polyfill", - "portable", - "shim" - ] - }, - { - "name": "symfony\/polyfill-mbstring", - "version": "v1.15.0", - "version_normalized": "1.15.0.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/polyfill-mbstring.git", - "reference": "81ffd3a9c6d707be22e3012b827de1c9775fc5ac" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-mbstring\/zipball\/81ffd3a9c6d707be22e3012b827de1c9775fc5ac", - "reference": "81ffd3a9c6d707be22e3012b827de1c9775fc5ac", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "suggest": { - "ext-mbstring": "For best performance" - }, - "time": "2020-03-09T19:04:49+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\": "" - }, - "files": [ - "bootstrap.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": "Symfony polyfill for the Mbstring extension", - "homepage": "https:\/\/symfony.com", - "keywords": [ - "compatibility", - "mbstring", - "polyfill", - "portable", - "shim" - ] - }, - { - "name": "symfony\/polyfill-php70", - "version": "v1.15.0", - "version_normalized": "1.15.0.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/polyfill-php70.git", - "reference": "2a18e37a489803559284416df58c71ccebe50bf0" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-php70\/zipball\/2a18e37a489803559284416df58c71ccebe50bf0", - "reference": "2a18e37a489803559284416df58c71ccebe50bf0", - "shasum": "" - }, - "require": { - "paragonie\/random_compat": "~1.0|~2.0|~9.99", - "php": ">=5.3.3" - }, - "time": "2020-02-27T09:26:54+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\": "" - }, - "files": [ - "bootstrap.php" - ], - "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 backporting some PHP 7.0+ features to lower PHP versions", - "homepage": "https:\/\/symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ] - }, - { - "name": "symfony\/polyfill-php72", - "version": "v1.15.0", - "version_normalized": "1.15.0.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/polyfill-php72.git", - "reference": "37b0976c78b94856543260ce09b460a7bc852747" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-php72\/zipball\/37b0976c78b94856543260ce09b460a7bc852747", - "reference": "37b0976c78b94856543260ce09b460a7bc852747", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "time": "2020-02-27T09:26:54+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\": "" - }, - "files": [ - "bootstrap.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": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", - "homepage": "https:\/\/symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ] - }, - { - "name": "symfony\/yaml", - "version": "v3.4.39", - "version_normalized": "3.4.39.0", - "source": { - "type": "git", - "url": "https:\/\/github.com\/symfony\/yaml.git", - "reference": "e701b47e11749970f63803879c4febb520f07b6c" - }, - "dist": { - "type": "zip", - "url": "https:\/\/api.github.com\/repos\/symfony\/yaml\/zipball\/e701b47e11749970f63803879c4febb520f07b6c", - "reference": "e701b47e11749970f63803879c4febb520f07b6c", - "shasum": "" - }, - "require": { - "php": "^5.5.9|>=7.0.8", - "symfony\/polyfill-ctype": "~1.8" - }, - "conflict": { - "symfony\/console": "<3.4" - }, - "require-dev": { - "symfony\/console": "~3.4|~4.0" - }, - "suggest": { - "symfony\/console": "For validating YAML files using the lint command" - }, - "time": "2020-03-25T12:02:26+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\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": "Symfony Yaml Component", - "homepage": "https:\/\/symfony.com" - } +[ + { + "name": "composer\/ca-bundle", + "version": "1.2.7", + "version_normalized": "1.2.7.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/composer\/ca-bundle.git", + "reference": "95c63ab2117a72f48f5a55da9740a3273d45b7fd" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/composer\/ca-bundle\/zipball\/95c63ab2117a72f48f5a55da9740a3273d45b7fd", + "reference": "95c63ab2117a72f48f5a55da9740a3273d45b7fd", + "shasum": "" + }, + "require": { + "ext-openssl": "*", + "ext-pcre": "*", + "php": "^5.3.2 || ^7.0 || ^8.0" + }, + "require-dev": { + "phpunit\/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8", + "psr\/log": "^1.0", + "symfony\/process": "^2.5 || ^3.0 || ^4.0 || ^5.0" + }, + "time": "2020-04-08T08:27:21+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Composer\\CaBundle\\": "src" + } + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http:\/\/seld.be" + } + ], + "description": "Lets you find a path to the system CA bundle, and includes a fallback to the Mozilla CA bundle.", + "keywords": [ + "cabundle", + "cacert", + "certificate", + "ssl", + "tls" + ] + }, + { + "name": "guzzlehttp\/guzzle", + "version": "6.5.3", + "version_normalized": "6.5.3.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/guzzle\/guzzle.git", + "reference": "aab4ebd862aa7d04f01a4b51849d657db56d882e" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/guzzle\/guzzle\/zipball\/aab4ebd862aa7d04f01a4b51849d657db56d882e", + "reference": "aab4ebd862aa7d04f01a4b51849d657db56d882e", + "shasum": "" + }, + "require": { + "ext-json": "*", + "guzzlehttp\/promises": "^1.0", + "guzzlehttp\/psr7": "^1.6.1", + "php": ">=5.5", + "symfony\/polyfill-intl-idn": "^1.11" + }, + "require-dev": { + "ext-curl": "*", + "phpunit\/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", + "psr\/log": "^1.1" + }, + "suggest": { + "psr\/log": "Required for using the Log middleware" + }, + "time": "2020-04-18T10:38:46+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "6.5-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\GuzzleHttp\\": "src\/" + }, + "files": [ + "src\/functions_include.php" + ] + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https:\/\/github.com\/mtdowling" + } + ], + "description": "Guzzle is a PHP HTTP client library", + "homepage": "http:\/\/guzzlephp.org\/", + "keywords": [ + "client", + "curl", + "framework", + "http", + "http client", + "rest", + "web service" + ] + }, + { + "name": "guzzlehttp\/promises", + "version": "v1.3.1", + "version_normalized": "1.3.1.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/guzzle\/promises.git", + "reference": "a59da6cf61d80060647ff4d3eb2c03a2bc694646" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/guzzle\/promises\/zipball\/a59da6cf61d80060647ff4d3eb2c03a2bc694646", + "reference": "a59da6cf61d80060647ff4d3eb2c03a2bc694646", + "shasum": "" + }, + "require": { + "php": ">=5.5.0" + }, + "require-dev": { + "phpunit\/phpunit": "^4.0" + }, + "time": "2016-12-20T10:07:11+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.4-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\": "src\/" + }, + "files": [ + "src\/functions_include.php" + ] + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https:\/\/github.com\/mtdowling" + } + ], + "description": "Guzzle promises library", + "keywords": [ + "promise" + ] + }, + { + "name": "guzzlehttp\/psr7", + "version": "1.6.1", + "version_normalized": "1.6.1.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/guzzle\/psr7.git", + "reference": "239400de7a173fe9901b9ac7c06497751f00727a" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/guzzle\/psr7\/zipball\/239400de7a173fe9901b9ac7c06497751f00727a", + "reference": "239400de7a173fe9901b9ac7c06497751f00727a", + "shasum": "" + }, + "require": { + "php": ">=5.4.0", + "psr\/http-message": "~1.0", + "ralouphie\/getallheaders": "^2.0.5 || ^3.0.0" + }, + "provide": { + "psr\/http-message-implementation": "1.0" + }, + "require-dev": { + "ext-zlib": "*", + "phpunit\/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8" + }, + "suggest": { + "zendframework\/zend-httphandlerrunner": "Emit PSR-7 responses" + }, + "time": "2019-07-01T23:21:34+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.6-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\": "src\/" + }, + "files": [ + "src\/functions_include.php" + ] + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https:\/\/github.com\/mtdowling" + }, + { + "name": "Tobias Schultze", + "homepage": "https:\/\/github.com\/Tobion" + } + ], + "description": "PSR-7 message implementation that also provides common utility methods", + "keywords": [ + "http", + "message", + "psr-7", + "request", + "response", + "stream", + "uri", + "url" + ] + }, + { + "name": "mollie\/mollie-api-php", + "version": "v2.17.0", + "version_normalized": "2.17.0.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/mollie\/mollie-api-php.git", + "reference": "ee22d0301aee55a41ef2e7d201ef29f86550d1f7" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/mollie\/mollie-api-php\/zipball\/ee22d0301aee55a41ef2e7d201ef29f86550d1f7", + "reference": "ee22d0301aee55a41ef2e7d201ef29f86550d1f7", + "shasum": "" + }, + "require": { + "composer\/ca-bundle": "^1.1", + "ext-curl": "*", + "ext-json": "*", + "ext-openssl": "*", + "guzzlehttp\/guzzle": "^6.3", + "php": ">=5.6" + }, + "require-dev": { + "eloquent\/liberator": "^2.0", + "phpunit\/phpunit": "^5.7 || ^6.5 || ^7.1" + }, + "suggest": { + "mollie\/oauth2-mollie-php": "Use OAuth to authenticate with the Mollie API. This is needed for some endpoints. Visit https:\/\/docs.mollie.com\/ for more information." + }, + "time": "2020-02-25T12:19:37+00:00", + "type": "library", + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Mollie\\Api\\": "src\/" + } + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "BSD-2-Clause" + ], + "authors": [ + { + "name": "Mollie B.V.", + "email": "info@mollie.com" + } + ], + "description": "Mollie API client library for PHP. Mollie is a European Payment Service provider and offers international payment methods such as Mastercard, VISA, American Express and PayPal, and local payment methods such as iDEAL, Bancontact, SOFORT Banking, SEPA direct debit, Belfius Direct Net, KBC Payment Button and various gift cards such as Podiumcadeaukaart and fashioncheque.", + "homepage": "https:\/\/www.mollie.com\/en\/developers", + "keywords": [ + "Apple Pay", + "CBC", + "Przelewy24", + "api", + "bancontact", + "banktransfer", + "belfius", + "belfius direct net", + "charges", + "creditcard", + "direct debit", + "fashioncheque", + "gateway", + "gift cards", + "ideal", + "inghomepay", + "intersolve", + "kbc", + "klarna", + "mistercash", + "mollie", + "paylater", + "payment", + "payments", + "paypal", + "paysafecard", + "podiumcadeaukaart", + "recurring", + "refunds", + "sepa", + "service", + "sliceit", + "sofort", + "sofortbanking", + "subscriptions" + ] + }, + { + "name": "paragonie\/random_compat", + "version": "v2.0.18", + "version_normalized": "2.0.18.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/paragonie\/random_compat.git", + "reference": "0a58ef6e3146256cc3dc7cc393927bcc7d1b72db" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/paragonie\/random_compat\/zipball\/0a58ef6e3146256cc3dc7cc393927bcc7d1b72db", + "reference": "0a58ef6e3146256cc3dc7cc393927bcc7d1b72db", + "shasum": "" + }, + "require": { + "php": ">=5.2.0" + }, + "require-dev": { + "phpunit\/phpunit": "4.*|5.*" + }, + "suggest": { + "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." + }, + "time": "2019-01-03T20:59:08+00:00", + "type": "library", + "installation-source": "dist", + "autoload": { + "files": [ + "lib\/random.php" + ] + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Paragon Initiative Enterprises", + "email": "security@paragonie.com", + "homepage": "https:\/\/paragonie.com" + } + ], + "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", + "keywords": [ + "csprng", + "polyfill", + "pseudorandom", + "random" + ] + }, + { + "name": "prestashop\/decimal", + "version": "1.3.0", + "version_normalized": "1.3.0.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/PrestaShop\/decimal.git", + "reference": "8b7f47671bb691bd463743d1cbab5b519fbd6849" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/PrestaShop\/decimal\/zipball\/8b7f47671bb691bd463743d1cbab5b519fbd6849", + "reference": "8b7f47671bb691bd463743d1cbab5b519fbd6849", + "shasum": "" + }, + "require": { + "php": ">=5.4" + }, + "require-dev": { + "codacy\/coverage": "dev-master", + "phpunit\/phpunit": "4.*" + }, + "time": "2020-04-15T07:39:20+00:00", + "type": "library", + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\": "src" + } + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PrestaShop SA", + "email": "contact@prestashop.com" + }, + { + "name": "Pablo Borowicz", + "email": "pablo.borowicz@prestashop.com" + } + ], + "description": "Object-oriented wrapper\/shim for BC Math PHP extension. Allows for arbitrary-precision math operations.", + "homepage": "https:\/\/github.com\/prestashop\/decimal", + "keywords": [ + "bcmath", + "decimal", + "math", + "precision", + "prestashop" + ] + }, + { + "name": "psr\/cache", + "version": "1.0.1", + "version_normalized": "1.0.1.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/php-fig\/cache.git", + "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/php-fig\/cache\/zipball\/d11b50ad223250cf17b86e38383413f5a6764bf8", + "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "time": "2016-08-06T20:24:11+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Psr\\Cache\\": "src\/" + } + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http:\/\/www.php-fig.org\/" + } + ], + "description": "Common interface for caching libraries", + "keywords": [ + "cache", + "psr", + "psr-6" + ] + }, + { + "name": "psr\/container", + "version": "1.0.0", + "version_normalized": "1.0.0.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/php-fig\/container.git", + "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/php-fig\/container\/zipball\/b7ce3b176482dbbc1245ebf52b181af44c2cf55f", + "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "time": "2017-02-14T16:28:37+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Psr\\Container\\": "src\/" + } + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http:\/\/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" + ] + }, + { + "name": "psr\/http-message", + "version": "1.0.1", + "version_normalized": "1.0.1.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/php-fig\/http-message.git", + "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/php-fig\/http-message\/zipball\/f6561bf28d520154e4b0ec72be95418abe6d9363", + "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "time": "2016-08-06T14:39:51+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\": "src\/" + } + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http:\/\/www.php-fig.org\/" + } + ], + "description": "Common interface for HTTP messages", + "homepage": "https:\/\/github.com\/php-fig\/http-message", + "keywords": [ + "http", + "http-message", + "psr", + "psr-7", + "request", + "response" + ] + }, + { + "name": "psr\/log", + "version": "1.1.3", + "version_normalized": "1.1.3.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/php-fig\/log.git", + "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/php-fig\/log\/zipball\/0f73288fd15629204f9d42b7055f72dacbe811fc", + "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "time": "2020-03-23T09:12:05+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.1.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Psr\\Log\\": "Psr\/Log\/" + } + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http:\/\/www.php-fig.org\/" + } + ], + "description": "Common interface for logging libraries", + "homepage": "https:\/\/github.com\/php-fig\/log", + "keywords": [ + "log", + "psr", + "psr-3" + ] + }, + { + "name": "psr\/simple-cache", + "version": "1.0.1", + "version_normalized": "1.0.1.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/php-fig\/simple-cache.git", + "reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/php-fig\/simple-cache\/zipball\/408d5eafb83c57f6365a3ca330ff23aa4a5fa39b", + "reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "time": "2017-10-23T01:57:42+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\": "src\/" + } + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http:\/\/www.php-fig.org\/" + } + ], + "description": "Common interfaces for simple caching", + "keywords": [ + "cache", + "caching", + "psr", + "psr-16", + "simple-cache" + ] + }, + { + "name": "ralouphie\/getallheaders", + "version": "3.0.3", + "version_normalized": "3.0.3.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/ralouphie\/getallheaders.git", + "reference": "120b605dfeb996808c31b6477290a714d356e822" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/ralouphie\/getallheaders\/zipball\/120b605dfeb996808c31b6477290a714d356e822", + "reference": "120b605dfeb996808c31b6477290a714d356e822", + "shasum": "" + }, + "require": { + "php": ">=5.6" + }, + "require-dev": { + "php-coveralls\/php-coveralls": "^2.1", + "phpunit\/phpunit": "^5 || ^6.5" + }, + "time": "2019-03-08T08:55:37+00:00", + "type": "library", + "installation-source": "dist", + "autoload": { + "files": [ + "src\/getallheaders.php" + ] + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ralph Khattar", + "email": "ralph.khattar@gmail.com" + } + ], + "description": "A polyfill for getallheaders." + }, + { + "name": "symfony\/cache", + "version": "v3.4.39", + "version_normalized": "3.4.39.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/cache.git", + "reference": "04860ece0f3996781c2fb04811a6c160a4b910ee" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/cache\/zipball\/04860ece0f3996781c2fb04811a6c160a4b910ee", + "reference": "04860ece0f3996781c2fb04811a6c160a4b910ee", + "shasum": "" + }, + "require": { + "php": "^5.5.9|>=7.0.8", + "psr\/cache": "~1.0", + "psr\/log": "~1.0", + "psr\/simple-cache": "^1.0", + "symfony\/polyfill-apcu": "~1.1" + }, + "conflict": { + "symfony\/var-dumper": "<3.3" + }, + "provide": { + "psr\/cache-implementation": "1.0", + "psr\/simple-cache-implementation": "1.0" + }, + "require-dev": { + "cache\/integration-tests": "dev-master", + "doctrine\/cache": "~1.6", + "doctrine\/dbal": "~2.4", + "predis\/predis": "~1.0" + }, + "time": "2020-03-16T15:51:59+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\": "" + }, + "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": "Symfony Cache component with PSR-6, PSR-16, and tags", + "homepage": "https:\/\/symfony.com", + "keywords": [ + "caching", + "psr6" + ] + }, + { + "name": "symfony\/config", + "version": "v3.4.39", + "version_normalized": "3.4.39.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/config.git", + "reference": "fc5be36e0659ab6e58cc069e8845f0819e6d086e" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/config\/zipball\/fc5be36e0659ab6e58cc069e8845f0819e6d086e", + "reference": "fc5be36e0659ab6e58cc069e8845f0819e6d086e", + "shasum": "" + }, + "require": { + "php": "^5.5.9|>=7.0.8", + "symfony\/filesystem": "~2.8|~3.0|~4.0", + "symfony\/polyfill-ctype": "~1.8" + }, + "conflict": { + "symfony\/dependency-injection": "<3.3", + "symfony\/finder": "<3.3" + }, + "require-dev": { + "symfony\/dependency-injection": "~3.3|~4.0", + "symfony\/event-dispatcher": "~3.3|~4.0", + "symfony\/finder": "~3.3|~4.0", + "symfony\/yaml": "~3.0|~4.0" + }, + "suggest": { + "symfony\/yaml": "To use the yaml reference dumper" + }, + "time": "2020-03-16T08:31:04+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\": "" + }, + "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": "Symfony Config Component", + "homepage": "https:\/\/symfony.com" + }, + { + "name": "symfony\/dependency-injection", + "version": "v3.4.39", + "version_normalized": "3.4.39.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/dependency-injection.git", + "reference": "f516f2bd2f43c82124392fa0a846d8c3261b324b" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/dependency-injection\/zipball\/f516f2bd2f43c82124392fa0a846d8c3261b324b", + "reference": "f516f2bd2f43c82124392fa0a846d8c3261b324b", + "shasum": "" + }, + "require": { + "php": "^5.5.9|>=7.0.8", + "psr\/container": "^1.0" + }, + "conflict": { + "symfony\/config": "<3.3.7", + "symfony\/finder": "<3.3", + "symfony\/proxy-manager-bridge": "<3.4", + "symfony\/yaml": "<3.4" + }, + "provide": { + "psr\/container-implementation": "1.0" + }, + "require-dev": { + "symfony\/config": "~3.3|~4.0", + "symfony\/expression-language": "~2.8|~3.0|~4.0", + "symfony\/yaml": "~3.4|~4.0" + }, + "suggest": { + "symfony\/config": "", + "symfony\/expression-language": "For using expressions in service container configuration", + "symfony\/finder": "For using double-star glob patterns or when GLOB_BRACE portability is required", + "symfony\/proxy-manager-bridge": "Generate service proxies to lazy load them", + "symfony\/yaml": "" + }, + "time": "2020-03-16T08:31:04+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\": "" + }, + "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": "Symfony DependencyInjection Component", + "homepage": "https:\/\/symfony.com" + }, + { + "name": "symfony\/expression-language", + "version": "v3.4.39", + "version_normalized": "3.4.39.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/expression-language.git", + "reference": "206165f46c660f3231df0afbdeec6a62f81afc59" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/expression-language\/zipball\/206165f46c660f3231df0afbdeec6a62f81afc59", + "reference": "206165f46c660f3231df0afbdeec6a62f81afc59", + "shasum": "" + }, + "require": { + "php": "^5.5.9|>=7.0.8", + "symfony\/cache": "~3.1|~4.0", + "symfony\/polyfill-php70": "~1.6" + }, + "time": "2020-03-16T08:31:04+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\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": "Symfony ExpressionLanguage Component", + "homepage": "https:\/\/symfony.com" + }, + { + "name": "symfony\/filesystem", + "version": "v3.4.39", + "version_normalized": "3.4.39.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/filesystem.git", + "reference": "ec47520778d524b1736e768e0678cd1f01c03019" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/filesystem\/zipball\/ec47520778d524b1736e768e0678cd1f01c03019", + "reference": "ec47520778d524b1736e768e0678cd1f01c03019", + "shasum": "" + }, + "require": { + "php": "^5.5.9|>=7.0.8", + "symfony\/polyfill-ctype": "~1.8" + }, + "time": "2020-03-16T08:31:04+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\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": "Symfony Filesystem Component", + "homepage": "https:\/\/symfony.com" + }, + { + "name": "symfony\/polyfill-apcu", + "version": "v1.15.0", + "version_normalized": "1.15.0.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/polyfill-apcu.git", + "reference": "d6b5c4ac62cd4ed622e583d027ae684de2d3c4bd" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-apcu\/zipball\/d6b5c4ac62cd4ed622e583d027ae684de2d3c4bd", + "reference": "d6b5c4ac62cd4ed622e583d027ae684de2d3c4bd", + "shasum": "" + }, + "require": { + "php": ">=5.3.3" + }, + "time": "2020-02-27T09:26:54+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\": "" + }, + "files": [ + "bootstrap.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": "Symfony polyfill backporting apcu_* functions to lower PHP versions", + "homepage": "https:\/\/symfony.com", + "keywords": [ + "apcu", + "compatibility", + "polyfill", + "portable", + "shim" + ] + }, + { + "name": "symfony\/polyfill-ctype", + "version": "v1.15.0", + "version_normalized": "1.15.0.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/polyfill-ctype.git", + "reference": "4719fa9c18b0464d399f1a63bf624b42b6fa8d14" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-ctype\/zipball\/4719fa9c18b0464d399f1a63bf624b42b6fa8d14", + "reference": "4719fa9c18b0464d399f1a63bf624b42b6fa8d14", + "shasum": "" + }, + "require": { + "php": ">=5.3.3" + }, + "suggest": { + "ext-ctype": "For best performance" + }, + "time": "2020-02-27T09:26:54+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "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" + ] + }, + { + "name": "symfony\/polyfill-intl-idn", + "version": "v1.15.0", + "version_normalized": "1.15.0.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/polyfill-intl-idn.git", + "reference": "47bd6aa45beb1cd7c6a16b7d1810133b728bdfcf" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-intl-idn\/zipball\/47bd6aa45beb1cd7c6a16b7d1810133b728bdfcf", + "reference": "47bd6aa45beb1cd7c6a16b7d1810133b728bdfcf", + "shasum": "" + }, + "require": { + "php": ">=5.3.3", + "symfony\/polyfill-mbstring": "^1.3", + "symfony\/polyfill-php72": "^1.10" + }, + "suggest": { + "ext-intl": "For best performance" + }, + "time": "2020-03-09T19:04:49+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https:\/\/packagist.org\/downloads\/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Laurent Bassin", + "email": "laurent@bassin.info" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "description": "Symfony polyfill for intl's idn_to_ascii and idn_to_utf8 functions", + "homepage": "https:\/\/symfony.com", + "keywords": [ + "compatibility", + "idn", + "intl", + "polyfill", + "portable", + "shim" + ] + }, + { + "name": "symfony\/polyfill-mbstring", + "version": "v1.15.0", + "version_normalized": "1.15.0.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/polyfill-mbstring.git", + "reference": "81ffd3a9c6d707be22e3012b827de1c9775fc5ac" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-mbstring\/zipball\/81ffd3a9c6d707be22e3012b827de1c9775fc5ac", + "reference": "81ffd3a9c6d707be22e3012b827de1c9775fc5ac", + "shasum": "" + }, + "require": { + "php": ">=5.3.3" + }, + "suggest": { + "ext-mbstring": "For best performance" + }, + "time": "2020-03-09T19:04:49+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\": "" + }, + "files": [ + "bootstrap.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": "Symfony polyfill for the Mbstring extension", + "homepage": "https:\/\/symfony.com", + "keywords": [ + "compatibility", + "mbstring", + "polyfill", + "portable", + "shim" + ] + }, + { + "name": "symfony\/polyfill-php70", + "version": "v1.15.0", + "version_normalized": "1.15.0.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/polyfill-php70.git", + "reference": "2a18e37a489803559284416df58c71ccebe50bf0" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-php70\/zipball\/2a18e37a489803559284416df58c71ccebe50bf0", + "reference": "2a18e37a489803559284416df58c71ccebe50bf0", + "shasum": "" + }, + "require": { + "paragonie\/random_compat": "~1.0|~2.0|~9.99", + "php": ">=5.3.3" + }, + "time": "2020-02-27T09:26:54+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\": "" + }, + "files": [ + "bootstrap.php" + ], + "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 backporting some PHP 7.0+ features to lower PHP versions", + "homepage": "https:\/\/symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ] + }, + { + "name": "symfony\/polyfill-php72", + "version": "v1.15.0", + "version_normalized": "1.15.0.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/polyfill-php72.git", + "reference": "37b0976c78b94856543260ce09b460a7bc852747" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/polyfill-php72\/zipball\/37b0976c78b94856543260ce09b460a7bc852747", + "reference": "37b0976c78b94856543260ce09b460a7bc852747", + "shasum": "" + }, + "require": { + "php": ">=5.3.3" + }, + "time": "2020-02-27T09:26:54+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\": "" + }, + "files": [ + "bootstrap.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": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", + "homepage": "https:\/\/symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ] + }, + { + "name": "symfony\/yaml", + "version": "v3.4.39", + "version_normalized": "3.4.39.0", + "source": { + "type": "git", + "url": "https:\/\/github.com\/symfony\/yaml.git", + "reference": "e701b47e11749970f63803879c4febb520f07b6c" + }, + "dist": { + "type": "zip", + "url": "https:\/\/api.github.com\/repos\/symfony\/yaml\/zipball\/e701b47e11749970f63803879c4febb520f07b6c", + "reference": "e701b47e11749970f63803879c4febb520f07b6c", + "shasum": "" + }, + "require": { + "php": "^5.5.9|>=7.0.8", + "symfony\/polyfill-ctype": "~1.8" + }, + "conflict": { + "symfony\/console": "<3.4" + }, + "require-dev": { + "symfony\/console": "~3.4|~4.0" + }, + "suggest": { + "symfony\/console": "For validating YAML files using the lint command" + }, + "time": "2020-03-25T12:02:26+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\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": "Symfony Yaml Component", + "homepage": "https:\/\/symfony.com" + } ] \ No newline at end of file diff --git a/vendor/guzzlehttp/guzzle/CHANGELOG.md b/vendor/guzzlehttp/guzzle/CHANGELOG.md index a5cb9c1a8..e29f71ad6 100644 --- a/vendor/guzzlehttp/guzzle/CHANGELOG.md +++ b/vendor/guzzlehttp/guzzle/CHANGELOG.md @@ -1,1327 +1,1327 @@ -# Change Log - -## 6.5.3 - 2020-04-18 - -* Use Symfony intl-idn polyfill [#2550](https://github.com/guzzle/guzzle/pull/2550) -* Remove use of internal functions [#2548](https://github.com/guzzle/guzzle/pull/2548) - -## 6.5.2 - 2019-12-23 - -* idn_to_ascii() fix for old PHP versions [#2489](https://github.com/guzzle/guzzle/pull/2489) - -## 6.5.1 - 2019-12-21 - -* Better defaults for PHP installations with old ICU lib [#2454](https://github.com/guzzle/guzzle/pull/2454) -* IDN support for redirects [#2424](https://github.com/guzzle/guzzle/pull/2424) - -## 6.5.0 - 2019-12-07 - -* Improvement: Added support for reset internal queue in MockHandler. [#2143](https://github.com/guzzle/guzzle/pull/2143) -* Improvement: Added support to pass arbitrary options to `curl_multi_init`. [#2287](https://github.com/guzzle/guzzle/pull/2287) -* Fix: Gracefully handle passing `null` to the `header` option. [#2132](https://github.com/guzzle/guzzle/pull/2132) -* Fix: `RetryMiddleware` did not do exponential delay between retires due unit mismatch. [#2132](https://github.com/guzzle/guzzle/pull/2132) -* Fix: Prevent undefined offset when using array for ssl_key options. [#2348](https://github.com/guzzle/guzzle/pull/2348) -* Deprecated `ClientInterface::VERSION` - -## 6.4.1 - 2019-10-23 - -* No `guzzle.phar` was created in 6.4.0 due expired API token. This release will fix that -* Added `parent::__construct()` to `FileCookieJar` and `SessionCookieJar` - -## 6.4.0 - 2019-10-23 - -* Improvement: Improved error messages when using curl < 7.21.2 [#2108](https://github.com/guzzle/guzzle/pull/2108) -* Fix: Test if response is readable before returning a summary in `RequestException::getResponseBodySummary()` [#2081](https://github.com/guzzle/guzzle/pull/2081) -* Fix: Add support for GUZZLE_CURL_SELECT_TIMEOUT environment variable [#2161](https://github.com/guzzle/guzzle/pull/2161) -* Improvement: Added `GuzzleHttp\Exception\InvalidArgumentException` [#2163](https://github.com/guzzle/guzzle/pull/2163) -* Improvement: Added `GuzzleHttp\_current_time()` to use `hrtime()` if that function exists. [#2242](https://github.com/guzzle/guzzle/pull/2242) -* Improvement: Added curl's `appconnect_time` in `TransferStats` [#2284](https://github.com/guzzle/guzzle/pull/2284) -* Improvement: Make GuzzleException extend Throwable wherever it's available [#2273](https://github.com/guzzle/guzzle/pull/2273) -* Fix: Prevent concurrent writes to file when saving `CookieJar` [#2335](https://github.com/guzzle/guzzle/pull/2335) -* Improvement: Update `MockHandler` so we can test transfer time [#2362](https://github.com/guzzle/guzzle/pull/2362) - -## 6.3.3 - 2018-04-22 - -* Fix: Default headers when decode_content is specified - - -## 6.3.2 - 2018-03-26 - -* Fix: Release process - - -## 6.3.1 - 2018-03-26 - -* Bug fix: Parsing 0 epoch expiry times in cookies [#2014](https://github.com/guzzle/guzzle/pull/2014) -* Improvement: Better ConnectException detection [#2012](https://github.com/guzzle/guzzle/pull/2012) -* Bug fix: Malformed domain that contains a "/" [#1999](https://github.com/guzzle/guzzle/pull/1999) -* Bug fix: Undefined offset when a cookie has no first key-value pair [#1998](https://github.com/guzzle/guzzle/pull/1998) -* Improvement: Support PHPUnit 6 [#1953](https://github.com/guzzle/guzzle/pull/1953) -* Bug fix: Support empty headers [#1915](https://github.com/guzzle/guzzle/pull/1915) -* Bug fix: Ignore case during header modifications [#1916](https://github.com/guzzle/guzzle/pull/1916) - -+ Minor code cleanups, documentation fixes and clarifications. - - -## 6.3.0 - 2017-06-22 - -* Feature: force IP resolution (ipv4 or ipv6) [#1608](https://github.com/guzzle/guzzle/pull/1608), [#1659](https://github.com/guzzle/guzzle/pull/1659) -* Improvement: Don't include summary in exception message when body is empty [#1621](https://github.com/guzzle/guzzle/pull/1621) -* Improvement: Handle `on_headers` option in MockHandler [#1580](https://github.com/guzzle/guzzle/pull/1580) -* Improvement: Added SUSE Linux CA path [#1609](https://github.com/guzzle/guzzle/issues/1609) -* Improvement: Use class reference for getting the name of the class instead of using hardcoded strings [#1641](https://github.com/guzzle/guzzle/pull/1641) -* Feature: Added `read_timeout` option [#1611](https://github.com/guzzle/guzzle/pull/1611) -* Bug fix: PHP 7.x fixes [#1685](https://github.com/guzzle/guzzle/pull/1685), [#1686](https://github.com/guzzle/guzzle/pull/1686), [#1811](https://github.com/guzzle/guzzle/pull/1811) -* Deprecation: BadResponseException instantiation without a response [#1642](https://github.com/guzzle/guzzle/pull/1642) -* Feature: Added NTLM auth [#1569](https://github.com/guzzle/guzzle/pull/1569) -* Feature: Track redirect HTTP status codes [#1711](https://github.com/guzzle/guzzle/pull/1711) -* Improvement: Check handler type during construction [#1745](https://github.com/guzzle/guzzle/pull/1745) -* Improvement: Always include the Content-Length if there's a body [#1721](https://github.com/guzzle/guzzle/pull/1721) -* Feature: Added convenience method to access a cookie by name [#1318](https://github.com/guzzle/guzzle/pull/1318) -* Bug fix: Fill `CURLOPT_CAPATH` and `CURLOPT_CAINFO` properly [#1684](https://github.com/guzzle/guzzle/pull/1684) -* Improvement: Use `\GuzzleHttp\Promise\rejection_for` function instead of object init [#1827](https://github.com/guzzle/guzzle/pull/1827) - - -+ Minor code cleanups, documentation fixes and clarifications. - -## 6.2.3 - 2017-02-28 - -* Fix deprecations with guzzle/psr7 version 1.4 - -## 6.2.2 - 2016-10-08 - -* Allow to pass nullable Response to delay callable -* Only add scheme when host is present -* Fix drain case where content-length is the literal string zero -* Obfuscate in-URL credentials in exceptions - -## 6.2.1 - 2016-07-18 - -* Address HTTP_PROXY security vulnerability, CVE-2016-5385: - https://httpoxy.org/ -* Fixing timeout bug with StreamHandler: - https://github.com/guzzle/guzzle/pull/1488 -* Only read up to `Content-Length` in PHP StreamHandler to avoid timeouts when - a server does not honor `Connection: close`. -* Ignore URI fragment when sending requests. - -## 6.2.0 - 2016-03-21 - -* Feature: added `GuzzleHttp\json_encode` and `GuzzleHttp\json_decode`. - https://github.com/guzzle/guzzle/pull/1389 -* Bug fix: Fix sleep calculation when waiting for delayed requests. - https://github.com/guzzle/guzzle/pull/1324 -* Feature: More flexible history containers. - https://github.com/guzzle/guzzle/pull/1373 -* Bug fix: defer sink stream opening in StreamHandler. - https://github.com/guzzle/guzzle/pull/1377 -* Bug fix: do not attempt to escape cookie values. - https://github.com/guzzle/guzzle/pull/1406 -* Feature: report original content encoding and length on decoded responses. - https://github.com/guzzle/guzzle/pull/1409 -* Bug fix: rewind seekable request bodies before dispatching to cURL. - https://github.com/guzzle/guzzle/pull/1422 -* Bug fix: provide an empty string to `http_build_query` for HHVM workaround. - https://github.com/guzzle/guzzle/pull/1367 - -## 6.1.1 - 2015-11-22 - -* Bug fix: Proxy::wrapSync() now correctly proxies to the appropriate handler - https://github.com/guzzle/guzzle/commit/911bcbc8b434adce64e223a6d1d14e9a8f63e4e4 -* Feature: HandlerStack is now more generic. - https://github.com/guzzle/guzzle/commit/f2102941331cda544745eedd97fc8fd46e1ee33e -* Bug fix: setting verify to false in the StreamHandler now disables peer - verification. https://github.com/guzzle/guzzle/issues/1256 -* Feature: Middleware now uses an exception factory, including more error - context. https://github.com/guzzle/guzzle/pull/1282 -* Feature: better support for disabled functions. - https://github.com/guzzle/guzzle/pull/1287 -* Bug fix: fixed regression where MockHandler was not using `sink`. - https://github.com/guzzle/guzzle/pull/1292 - -## 6.1.0 - 2015-09-08 - -* Feature: Added the `on_stats` request option to provide access to transfer - statistics for requests. https://github.com/guzzle/guzzle/pull/1202 -* Feature: Added the ability to persist session cookies in CookieJars. - https://github.com/guzzle/guzzle/pull/1195 -* Feature: Some compatibility updates for Google APP Engine - https://github.com/guzzle/guzzle/pull/1216 -* Feature: Added support for NO_PROXY to prevent the use of a proxy based on - a simple set of rules. https://github.com/guzzle/guzzle/pull/1197 -* Feature: Cookies can now contain square brackets. - https://github.com/guzzle/guzzle/pull/1237 -* Bug fix: Now correctly parsing `=` inside of quotes in Cookies. - https://github.com/guzzle/guzzle/pull/1232 -* Bug fix: Cusotm cURL options now correctly override curl options of the - same name. https://github.com/guzzle/guzzle/pull/1221 -* Bug fix: Content-Type header is now added when using an explicitly provided - multipart body. https://github.com/guzzle/guzzle/pull/1218 -* Bug fix: Now ignoring Set-Cookie headers that have no name. -* Bug fix: Reason phrase is no longer cast to an int in some cases in the - cURL handler. https://github.com/guzzle/guzzle/pull/1187 -* Bug fix: Remove the Authorization header when redirecting if the Host - header changes. https://github.com/guzzle/guzzle/pull/1207 -* Bug fix: Cookie path matching fixes - https://github.com/guzzle/guzzle/issues/1129 -* Bug fix: Fixing the cURL `body_as_string` setting - https://github.com/guzzle/guzzle/pull/1201 -* Bug fix: quotes are no longer stripped when parsing cookies. - https://github.com/guzzle/guzzle/issues/1172 -* Bug fix: `form_params` and `query` now always uses the `&` separator. - https://github.com/guzzle/guzzle/pull/1163 -* Bug fix: Adding a Content-Length to PHP stream wrapper requests if not set. - https://github.com/guzzle/guzzle/pull/1189 - -## 6.0.2 - 2015-07-04 - -* Fixed a memory leak in the curl handlers in which references to callbacks - were not being removed by `curl_reset`. -* Cookies are now extracted properly before redirects. -* Cookies now allow more character ranges. -* Decoded Content-Encoding responses are now modified to correctly reflect - their state if the encoding was automatically removed by a handler. This - means that the `Content-Encoding` header may be removed an the - `Content-Length` modified to reflect the message size after removing the - encoding. -* Added a more explicit error message when trying to use `form_params` and - `multipart` in the same request. -* Several fixes for HHVM support. -* Functions are now conditionally required using an additional level of - indirection to help with global Composer installations. - -## 6.0.1 - 2015-05-27 - -* Fixed a bug with serializing the `query` request option where the `&` - separator was missing. -* Added a better error message for when `body` is provided as an array. Please - use `form_params` or `multipart` instead. -* Various doc fixes. - -## 6.0.0 - 2015-05-26 - -* See the UPGRADING.md document for more information. -* Added `multipart` and `form_params` request options. -* Added `synchronous` request option. -* Added the `on_headers` request option. -* Fixed `expect` handling. -* No longer adding default middlewares in the client ctor. These need to be - present on the provided handler in order to work. -* Requests are no longer initiated when sending async requests with the - CurlMultiHandler. This prevents unexpected recursion from requests completing - while ticking the cURL loop. -* Removed the semantics of setting `default` to `true`. This is no longer - required now that the cURL loop is not ticked for async requests. -* Added request and response logging middleware. -* No longer allowing self signed certificates when using the StreamHandler. -* Ensuring that `sink` is valid if saving to a file. -* Request exceptions now include a "handler context" which provides handler - specific contextual information. -* Added `GuzzleHttp\RequestOptions` to allow request options to be applied - using constants. -* `$maxHandles` has been removed from CurlMultiHandler. -* `MultipartPostBody` is now part of the `guzzlehttp/psr7` package. - -## 5.3.0 - 2015-05-19 - -* Mock now supports `save_to` -* Marked `AbstractRequestEvent::getTransaction()` as public. -* Fixed a bug in which multiple headers using different casing would overwrite - previous headers in the associative array. -* Added `Utils::getDefaultHandler()` -* Marked `GuzzleHttp\Client::getDefaultUserAgent` as deprecated. -* URL scheme is now always lowercased. - -## 6.0.0-beta.1 - -* Requires PHP >= 5.5 -* Updated to use PSR-7 - * Requires immutable messages, which basically means an event based system - owned by a request instance is no longer possible. - * Utilizing the [Guzzle PSR-7 package](https://github.com/guzzle/psr7). - * Removed the dependency on `guzzlehttp/streams`. These stream abstractions - are available in the `guzzlehttp/psr7` package under the `GuzzleHttp\Psr7` - namespace. -* Added middleware and handler system - * Replaced the Guzzle event and subscriber system with a middleware system. - * No longer depends on RingPHP, but rather places the HTTP handlers directly - in Guzzle, operating on PSR-7 messages. - * Retry logic is now encapsulated in `GuzzleHttp\Middleware::retry`, which - means the `guzzlehttp/retry-subscriber` is now obsolete. - * Mocking responses is now handled using `GuzzleHttp\Handler\MockHandler`. -* Asynchronous responses - * No longer supports the `future` request option to send an async request. - Instead, use one of the `*Async` methods of a client (e.g., `requestAsync`, - `getAsync`, etc.). - * Utilizing `GuzzleHttp\Promise` instead of React's promise library to avoid - recursion required by chaining and forwarding react promises. See - https://github.com/guzzle/promises - * Added `requestAsync` and `sendAsync` to send request asynchronously. - * Added magic methods for `getAsync()`, `postAsync()`, etc. to send requests - asynchronously. -* Request options - * POST and form updates - * Added the `form_fields` and `form_files` request options. - * Removed the `GuzzleHttp\Post` namespace. - * The `body` request option no longer accepts an array for POST requests. - * The `exceptions` request option has been deprecated in favor of the - `http_errors` request options. - * The `save_to` request option has been deprecated in favor of `sink` request - option. -* Clients no longer accept an array of URI template string and variables for - URI variables. You will need to expand URI templates before passing them - into a client constructor or request method. -* Client methods `get()`, `post()`, `put()`, `patch()`, `options()`, etc. are - now magic methods that will send synchronous requests. -* Replaced `Utils.php` with plain functions in `functions.php`. -* Removed `GuzzleHttp\Collection`. -* Removed `GuzzleHttp\BatchResults`. Batched pool results are now returned as - an array. -* Removed `GuzzleHttp\Query`. Query string handling is now handled using an - associative array passed into the `query` request option. The query string - is serialized using PHP's `http_build_query`. If you need more control, you - can pass the query string in as a string. -* `GuzzleHttp\QueryParser` has been replaced with the - `GuzzleHttp\Psr7\parse_query`. - -## 5.2.0 - 2015-01-27 - -* Added `AppliesHeadersInterface` to make applying headers to a request based - on the body more generic and not specific to `PostBodyInterface`. -* Reduced the number of stack frames needed to send requests. -* Nested futures are now resolved in the client rather than the RequestFsm -* Finishing state transitions is now handled in the RequestFsm rather than the - RingBridge. -* Added a guard in the Pool class to not use recursion for request retries. - -## 5.1.0 - 2014-12-19 - -* Pool class no longer uses recursion when a request is intercepted. -* The size of a Pool can now be dynamically adjusted using a callback. - See https://github.com/guzzle/guzzle/pull/943. -* Setting a request option to `null` when creating a request with a client will - ensure that the option is not set. This allows you to overwrite default - request options on a per-request basis. - See https://github.com/guzzle/guzzle/pull/937. -* Added the ability to limit which protocols are allowed for redirects by - specifying a `protocols` array in the `allow_redirects` request option. -* Nested futures due to retries are now resolved when waiting for synchronous - responses. See https://github.com/guzzle/guzzle/pull/947. -* `"0"` is now an allowed URI path. See - https://github.com/guzzle/guzzle/pull/935. -* `Query` no longer typehints on the `$query` argument in the constructor, - allowing for strings and arrays. -* Exceptions thrown in the `end` event are now correctly wrapped with Guzzle - specific exceptions if necessary. - -## 5.0.3 - 2014-11-03 - -This change updates query strings so that they are treated as un-encoded values -by default where the value represents an un-encoded value to send over the -wire. A Query object then encodes the value before sending over the wire. This -means that even value query string values (e.g., ":") are url encoded. This -makes the Query class match PHP's http_build_query function. However, if you -want to send requests over the wire using valid query string characters that do -not need to be encoded, then you can provide a string to Url::setQuery() and -pass true as the second argument to specify that the query string is a raw -string that should not be parsed or encoded (unless a call to getQuery() is -subsequently made, forcing the query-string to be converted into a Query -object). - -## 5.0.2 - 2014-10-30 - -* Added a trailing `\r\n` to multipart/form-data payloads. See - https://github.com/guzzle/guzzle/pull/871 -* Added a `GuzzleHttp\Pool::send()` convenience method to match the docs. -* Status codes are now returned as integers. See - https://github.com/guzzle/guzzle/issues/881 -* No longer overwriting an existing `application/x-www-form-urlencoded` header - when sending POST requests, allowing for customized headers. See - https://github.com/guzzle/guzzle/issues/877 -* Improved path URL serialization. - - * No longer double percent-encoding characters in the path or query string if - they are already encoded. - * Now properly encoding the supplied path to a URL object, instead of only - encoding ' ' and '?'. - * Note: This has been changed in 5.0.3 to now encode query string values by - default unless the `rawString` argument is provided when setting the query - string on a URL: Now allowing many more characters to be present in the - query string without being percent encoded. See http://tools.ietf.org/html/rfc3986#appendix-A - -## 5.0.1 - 2014-10-16 - -Bugfix release. - -* Fixed an issue where connection errors still returned response object in - error and end events event though the response is unusable. This has been - corrected so that a response is not returned in the `getResponse` method of - these events if the response did not complete. https://github.com/guzzle/guzzle/issues/867 -* Fixed an issue where transfer statistics were not being populated in the - RingBridge. https://github.com/guzzle/guzzle/issues/866 - -## 5.0.0 - 2014-10-12 - -Adding support for non-blocking responses and some minor API cleanup. - -### New Features - -* Added support for non-blocking responses based on `guzzlehttp/guzzle-ring`. -* Added a public API for creating a default HTTP adapter. -* Updated the redirect plugin to be non-blocking so that redirects are sent - concurrently. Other plugins like this can now be updated to be non-blocking. -* Added a "progress" event so that you can get upload and download progress - events. -* Added `GuzzleHttp\Pool` which implements FutureInterface and transfers - requests concurrently using a capped pool size as efficiently as possible. -* Added `hasListeners()` to EmitterInterface. -* Removed `GuzzleHttp\ClientInterface::sendAll` and marked - `GuzzleHttp\Client::sendAll` as deprecated (it's still there, just not the - recommended way). - -### Breaking changes - -The breaking changes in this release are relatively minor. The biggest thing to -look out for is that request and response objects no longer implement fluent -interfaces. - -* Removed the fluent interfaces (i.e., `return $this`) from requests, - responses, `GuzzleHttp\Collection`, `GuzzleHttp\Url`, - `GuzzleHttp\Query`, `GuzzleHttp\Post\PostBody`, and - `GuzzleHttp\Cookie\SetCookie`. This blog post provides a good outline of - why I did this: http://ocramius.github.io/blog/fluent-interfaces-are-evil/. - This also makes the Guzzle message interfaces compatible with the current - PSR-7 message proposal. -* Removed "functions.php", so that Guzzle is truly PSR-4 compliant. Except - for the HTTP request functions from function.php, these functions are now - implemented in `GuzzleHttp\Utils` using camelCase. `GuzzleHttp\json_decode` - moved to `GuzzleHttp\Utils::jsonDecode`. `GuzzleHttp\get_path` moved to - `GuzzleHttp\Utils::getPath`. `GuzzleHttp\set_path` moved to - `GuzzleHttp\Utils::setPath`. `GuzzleHttp\batch` should now be - `GuzzleHttp\Pool::batch`, which returns an `objectStorage`. Using functions.php - caused problems for many users: they aren't PSR-4 compliant, require an - explicit include, and needed an if-guard to ensure that the functions are not - declared multiple times. -* Rewrote adapter layer. - * Removing all classes from `GuzzleHttp\Adapter`, these are now - implemented as callables that are stored in `GuzzleHttp\Ring\Client`. - * Removed the concept of "parallel adapters". Sending requests serially or - concurrently is now handled using a single adapter. - * Moved `GuzzleHttp\Adapter\Transaction` to `GuzzleHttp\Transaction`. The - Transaction object now exposes the request, response, and client as public - properties. The getters and setters have been removed. -* Removed the "headers" event. This event was only useful for changing the - body a response once the headers of the response were known. You can implement - a similar behavior in a number of ways. One example might be to use a - FnStream that has access to the transaction being sent. For example, when the - first byte is written, you could check if the response headers match your - expectations, and if so, change the actual stream body that is being - written to. -* Removed the `asArray` parameter from - `GuzzleHttp\Message\MessageInterface::getHeader`. If you want to get a header - value as an array, then use the newly added `getHeaderAsArray()` method of - `MessageInterface`. This change makes the Guzzle interfaces compatible with - the PSR-7 interfaces. -* `GuzzleHttp\Message\MessageFactory` no longer allows subclasses to add - custom request options using double-dispatch (this was an implementation - detail). Instead, you should now provide an associative array to the - constructor which is a mapping of the request option name mapping to a - function that applies the option value to a request. -* Removed the concept of "throwImmediately" from exceptions and error events. - This control mechanism was used to stop a transfer of concurrent requests - from completing. This can now be handled by throwing the exception or by - cancelling a pool of requests or each outstanding future request individually. -* Updated to "GuzzleHttp\Streams" 3.0. - * `GuzzleHttp\Stream\StreamInterface::getContents()` no longer accepts a - `maxLen` parameter. This update makes the Guzzle streams project - compatible with the current PSR-7 proposal. - * `GuzzleHttp\Stream\Stream::__construct`, - `GuzzleHttp\Stream\Stream::factory`, and - `GuzzleHttp\Stream\Utils::create` no longer accept a size in the second - argument. They now accept an associative array of options, including the - "size" key and "metadata" key which can be used to provide custom metadata. - -## 4.2.2 - 2014-09-08 - -* Fixed a memory leak in the CurlAdapter when reusing cURL handles. -* No longer using `request_fulluri` in stream adapter proxies. -* Relative redirects are now based on the last response, not the first response. - -## 4.2.1 - 2014-08-19 - -* Ensuring that the StreamAdapter does not always add a Content-Type header -* Adding automated github releases with a phar and zip - -## 4.2.0 - 2014-08-17 - -* Now merging in default options using a case-insensitive comparison. - Closes https://github.com/guzzle/guzzle/issues/767 -* Added the ability to automatically decode `Content-Encoding` response bodies - using the `decode_content` request option. This is set to `true` by default - to decode the response body if it comes over the wire with a - `Content-Encoding`. Set this value to `false` to disable decoding the - response content, and pass a string to provide a request `Accept-Encoding` - header and turn on automatic response decoding. This feature now allows you - to pass an `Accept-Encoding` header in the headers of a request but still - disable automatic response decoding. - Closes https://github.com/guzzle/guzzle/issues/764 -* Added the ability to throw an exception immediately when transferring - requests in parallel. Closes https://github.com/guzzle/guzzle/issues/760 -* Updating guzzlehttp/streams dependency to ~2.1 -* No longer utilizing the now deprecated namespaced methods from the stream - package. - -## 4.1.8 - 2014-08-14 - -* Fixed an issue in the CurlFactory that caused setting the `stream=false` - request option to throw an exception. - See: https://github.com/guzzle/guzzle/issues/769 -* TransactionIterator now calls rewind on the inner iterator. - See: https://github.com/guzzle/guzzle/pull/765 -* You can now set the `Content-Type` header to `multipart/form-data` - when creating POST requests to force multipart bodies. - See https://github.com/guzzle/guzzle/issues/768 - -## 4.1.7 - 2014-08-07 - -* Fixed an error in the HistoryPlugin that caused the same request and response - to be logged multiple times when an HTTP protocol error occurs. -* Ensuring that cURL does not add a default Content-Type when no Content-Type - has been supplied by the user. This prevents the adapter layer from modifying - the request that is sent over the wire after any listeners may have already - put the request in a desired state (e.g., signed the request). -* Throwing an exception when you attempt to send requests that have the - "stream" set to true in parallel using the MultiAdapter. -* Only calling curl_multi_select when there are active cURL handles. This was - previously changed and caused performance problems on some systems due to PHP - always selecting until the maximum select timeout. -* Fixed a bug where multipart/form-data POST fields were not correctly - aggregated (e.g., values with "&"). - -## 4.1.6 - 2014-08-03 - -* Added helper methods to make it easier to represent messages as strings, - including getting the start line and getting headers as a string. - -## 4.1.5 - 2014-08-02 - -* Automatically retrying cURL "Connection died, retrying a fresh connect" - errors when possible. -* cURL implementation cleanup -* Allowing multiple event subscriber listeners to be registered per event by - passing an array of arrays of listener configuration. - -## 4.1.4 - 2014-07-22 - -* Fixed a bug that caused multi-part POST requests with more than one field to - serialize incorrectly. -* Paths can now be set to "0" -* `ResponseInterface::xml` now accepts a `libxml_options` option and added a - missing default argument that was required when parsing XML response bodies. -* A `save_to` stream is now created lazily, which means that files are not - created on disk unless a request succeeds. - -## 4.1.3 - 2014-07-15 - -* Various fixes to multipart/form-data POST uploads -* Wrapping function.php in an if-statement to ensure Guzzle can be used - globally and in a Composer install -* Fixed an issue with generating and merging in events to an event array -* POST headers are only applied before sending a request to allow you to change - the query aggregator used before uploading -* Added much more robust query string parsing -* Fixed various parsing and normalization issues with URLs -* Fixing an issue where multi-valued headers were not being utilized correctly - in the StreamAdapter - -## 4.1.2 - 2014-06-18 - -* Added support for sending payloads with GET requests - -## 4.1.1 - 2014-06-08 - -* Fixed an issue related to using custom message factory options in subclasses -* Fixed an issue with nested form fields in a multi-part POST -* Fixed an issue with using the `json` request option for POST requests -* Added `ToArrayInterface` to `GuzzleHttp\Cookie\CookieJar` - -## 4.1.0 - 2014-05-27 - -* Added a `json` request option to easily serialize JSON payloads. -* Added a `GuzzleHttp\json_decode()` wrapper to safely parse JSON. -* Added `setPort()` and `getPort()` to `GuzzleHttp\Message\RequestInterface`. -* Added the ability to provide an emitter to a client in the client constructor. -* Added the ability to persist a cookie session using $_SESSION. -* Added a trait that can be used to add event listeners to an iterator. -* Removed request method constants from RequestInterface. -* Fixed warning when invalid request start-lines are received. -* Updated MessageFactory to work with custom request option methods. -* Updated cacert bundle to latest build. - -4.0.2 (2014-04-16) ------------------- - -* Proxy requests using the StreamAdapter now properly use request_fulluri (#632) -* Added the ability to set scalars as POST fields (#628) - -## 4.0.1 - 2014-04-04 - -* The HTTP status code of a response is now set as the exception code of - RequestException objects. -* 303 redirects will now correctly switch from POST to GET requests. -* The default parallel adapter of a client now correctly uses the MultiAdapter. -* HasDataTrait now initializes the internal data array as an empty array so - that the toArray() method always returns an array. - -## 4.0.0 - 2014-03-29 - -* For more information on the 4.0 transition, see: - http://mtdowling.com/blog/2014/03/15/guzzle-4-rc/ -* For information on changes and upgrading, see: - https://github.com/guzzle/guzzle/blob/master/UPGRADING.md#3x-to-40 -* Added `GuzzleHttp\batch()` as a convenience function for sending requests in - parallel without needing to write asynchronous code. -* Restructured how events are added to `GuzzleHttp\ClientInterface::sendAll()`. - You can now pass a callable or an array of associative arrays where each - associative array contains the "fn", "priority", and "once" keys. - -## 4.0.0.rc-2 - 2014-03-25 - -* Removed `getConfig()` and `setConfig()` from clients to avoid confusion - around whether things like base_url, message_factory, etc. should be able to - be retrieved or modified. -* Added `getDefaultOption()` and `setDefaultOption()` to ClientInterface -* functions.php functions were renamed using snake_case to match PHP idioms -* Added support for `HTTP_PROXY`, `HTTPS_PROXY`, and - `GUZZLE_CURL_SELECT_TIMEOUT` environment variables -* Added the ability to specify custom `sendAll()` event priorities -* Added the ability to specify custom stream context options to the stream - adapter. -* Added a functions.php function for `get_path()` and `set_path()` -* CurlAdapter and MultiAdapter now use a callable to generate curl resources -* MockAdapter now properly reads a body and emits a `headers` event -* Updated Url class to check if a scheme and host are set before adding ":" - and "//". This allows empty Url (e.g., "") to be serialized as "". -* Parsing invalid XML no longer emits warnings -* Curl classes now properly throw AdapterExceptions -* Various performance optimizations -* Streams are created with the faster `Stream\create()` function -* Marked deprecation_proxy() as internal -* Test server is now a collection of static methods on a class - -## 4.0.0-rc.1 - 2014-03-15 - -* See https://github.com/guzzle/guzzle/blob/master/UPGRADING.md#3x-to-40 - -## 3.8.1 - 2014-01-28 - -* Bug: Always using GET requests when redirecting from a 303 response -* Bug: CURLOPT_SSL_VERIFYHOST is now correctly set to false when setting `$certificateAuthority` to false in - `Guzzle\Http\ClientInterface::setSslVerification()` -* Bug: RedirectPlugin now uses strict RFC 3986 compliance when combining a base URL with a relative URL -* Bug: The body of a request can now be set to `"0"` -* Sending PHP stream requests no longer forces `HTTP/1.0` -* Adding more information to ExceptionCollection exceptions so that users have more context, including a stack trace of - each sub-exception -* Updated the `$ref` attribute in service descriptions to merge over any existing parameters of a schema (rather than - clobbering everything). -* Merging URLs will now use the query string object from the relative URL (thus allowing custom query aggregators) -* Query strings are now parsed in a way that they do no convert empty keys with no value to have a dangling `=`. - For example `foo&bar=baz` is now correctly parsed and recognized as `foo&bar=baz` rather than `foo=&bar=baz`. -* Now properly escaping the regular expression delimiter when matching Cookie domains. -* Network access is now disabled when loading XML documents - -## 3.8.0 - 2013-12-05 - -* Added the ability to define a POST name for a file -* JSON response parsing now properly walks additionalProperties -* cURL error code 18 is now retried automatically in the BackoffPlugin -* Fixed a cURL error when URLs contain fragments -* Fixed an issue in the BackoffPlugin retry event where it was trying to access all exceptions as if they were - CurlExceptions -* CURLOPT_PROGRESS function fix for PHP 5.5 (69fcc1e) -* Added the ability for Guzzle to work with older versions of cURL that do not support `CURLOPT_TIMEOUT_MS` -* Fixed a bug that was encountered when parsing empty header parameters -* UriTemplate now has a `setRegex()` method to match the docs -* The `debug` request parameter now checks if it is truthy rather than if it exists -* Setting the `debug` request parameter to true shows verbose cURL output instead of using the LogPlugin -* Added the ability to combine URLs using strict RFC 3986 compliance -* Command objects can now return the validation errors encountered by the command -* Various fixes to cache revalidation (#437 and 29797e5) -* Various fixes to the AsyncPlugin -* Cleaned up build scripts - -## 3.7.4 - 2013-10-02 - -* Bug fix: 0 is now an allowed value in a description parameter that has a default value (#430) -* Bug fix: SchemaFormatter now returns an integer when formatting to a Unix timestamp - (see https://github.com/aws/aws-sdk-php/issues/147) -* Bug fix: Cleaned up and fixed URL dot segment removal to properly resolve internal dots -* Minimum PHP version is now properly specified as 5.3.3 (up from 5.3.2) (#420) -* Updated the bundled cacert.pem (#419) -* OauthPlugin now supports adding authentication to headers or query string (#425) - -## 3.7.3 - 2013-09-08 - -* Added the ability to get the exception associated with a request/command when using `MultiTransferException` and - `CommandTransferException`. -* Setting `additionalParameters` of a response to false is now honored when parsing responses with a service description -* Schemas are only injected into response models when explicitly configured. -* No longer guessing Content-Type based on the path of a request. Content-Type is now only guessed based on the path of - an EntityBody. -* Bug fix: ChunkedIterator can now properly chunk a \Traversable as well as an \Iterator. -* Bug fix: FilterIterator now relies on `\Iterator` instead of `\Traversable`. -* Bug fix: Gracefully handling malformed responses in RequestMediator::writeResponseBody() -* Bug fix: Replaced call to canCache with canCacheRequest in the CallbackCanCacheStrategy of the CachePlugin -* Bug fix: Visiting XML attributes first before visiting XML children when serializing requests -* Bug fix: Properly parsing headers that contain commas contained in quotes -* Bug fix: mimetype guessing based on a filename is now case-insensitive - -## 3.7.2 - 2013-08-02 - -* Bug fix: Properly URL encoding paths when using the PHP-only version of the UriTemplate expander - See https://github.com/guzzle/guzzle/issues/371 -* Bug fix: Cookie domains are now matched correctly according to RFC 6265 - See https://github.com/guzzle/guzzle/issues/377 -* Bug fix: GET parameters are now used when calculating an OAuth signature -* Bug fix: Fixed an issue with cache revalidation where the If-None-Match header was being double quoted -* `Guzzle\Common\AbstractHasDispatcher::dispatch()` now returns the event that was dispatched -* `Guzzle\Http\QueryString::factory()` now guesses the most appropriate query aggregator to used based on the input. - See https://github.com/guzzle/guzzle/issues/379 -* Added a way to add custom domain objects to service description parsing using the `operation.parse_class` event. See - https://github.com/guzzle/guzzle/pull/380 -* cURL multi cleanup and optimizations - -## 3.7.1 - 2013-07-05 - -* Bug fix: Setting default options on a client now works -* Bug fix: Setting options on HEAD requests now works. See #352 -* Bug fix: Moving stream factory before send event to before building the stream. See #353 -* Bug fix: Cookies no longer match on IP addresses per RFC 6265 -* Bug fix: Correctly parsing header parameters that are in `<>` and quotes -* Added `cert` and `ssl_key` as request options -* `Host` header can now diverge from the host part of a URL if the header is set manually -* `Guzzle\Service\Command\LocationVisitor\Request\XmlVisitor` was rewritten to change from using SimpleXML to XMLWriter -* OAuth parameters are only added via the plugin if they aren't already set -* Exceptions are now thrown when a URL cannot be parsed -* Returning `false` if `Guzzle\Http\EntityBody::getContentMd5()` fails -* Not setting a `Content-MD5` on a command if calculating the Content-MD5 fails via the CommandContentMd5Plugin - -## 3.7.0 - 2013-06-10 - -* See UPGRADING.md for more information on how to upgrade. -* Requests now support the ability to specify an array of $options when creating a request to more easily modify a - request. You can pass a 'request.options' configuration setting to a client to apply default request options to - every request created by a client (e.g. default query string variables, headers, curl options, etc.). -* Added a static facade class that allows you to use Guzzle with static methods and mount the class to `\Guzzle`. - See `Guzzle\Http\StaticClient::mount`. -* Added `command.request_options` to `Guzzle\Service\Command\AbstractCommand` to pass request options to requests - created by a command (e.g. custom headers, query string variables, timeout settings, etc.). -* Stream size in `Guzzle\Stream\PhpStreamRequestFactory` will now be set if Content-Length is returned in the - headers of a response -* Added `Guzzle\Common\Collection::setPath($path, $value)` to set a value into an array using a nested key - (e.g. `$collection->setPath('foo/baz/bar', 'test'); echo $collection['foo']['bar']['bar'];`) -* ServiceBuilders now support storing and retrieving arbitrary data -* CachePlugin can now purge all resources for a given URI -* CachePlugin can automatically purge matching cached items when a non-idempotent request is sent to a resource -* CachePlugin now uses the Vary header to determine if a resource is a cache hit -* `Guzzle\Http\Message\Response` now implements `\Serializable` -* Added `Guzzle\Cache\CacheAdapterFactory::fromCache()` to more easily create cache adapters -* `Guzzle\Service\ClientInterface::execute()` now accepts an array, single command, or Traversable -* Fixed a bug in `Guzzle\Http\Message\Header\Link::addLink()` -* Better handling of calculating the size of a stream in `Guzzle\Stream\Stream` using fstat() and caching the size -* `Guzzle\Common\Exception\ExceptionCollection` now creates a more readable exception message -* Fixing BC break: Added back the MonologLogAdapter implementation rather than extending from PsrLog so that older - Symfony users can still use the old version of Monolog. -* Fixing BC break: Added the implementation back in for `Guzzle\Http\Message\AbstractMessage::getTokenizedHeader()`. - Now triggering an E_USER_DEPRECATED warning when used. Use `$message->getHeader()->parseParams()`. -* Several performance improvements to `Guzzle\Common\Collection` -* Added an `$options` argument to the end of the following methods of `Guzzle\Http\ClientInterface`: - createRequest, head, delete, put, patch, post, options, prepareRequest -* Added an `$options` argument to the end of `Guzzle\Http\Message\Request\RequestFactoryInterface::createRequest()` -* Added an `applyOptions()` method to `Guzzle\Http\Message\Request\RequestFactoryInterface` -* Changed `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $body = null)` to - `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $options = array())`. You can still pass in a - resource, string, or EntityBody into the $options parameter to specify the download location of the response. -* Changed `Guzzle\Common\Collection::__construct($data)` to no longer accepts a null value for `$data` but a - default `array()` -* Added `Guzzle\Stream\StreamInterface::isRepeatable` -* Removed `Guzzle\Http\ClientInterface::setDefaultHeaders(). Use - $client->getConfig()->setPath('request.options/headers/{header_name}', 'value')`. or - $client->getConfig()->setPath('request.options/headers', array('header_name' => 'value'))`. -* Removed `Guzzle\Http\ClientInterface::getDefaultHeaders(). Use $client->getConfig()->getPath('request.options/headers')`. -* Removed `Guzzle\Http\ClientInterface::expandTemplate()` -* Removed `Guzzle\Http\ClientInterface::setRequestFactory()` -* Removed `Guzzle\Http\ClientInterface::getCurlMulti()` -* Removed `Guzzle\Http\Message\RequestInterface::canCache` -* Removed `Guzzle\Http\Message\RequestInterface::setIsRedirect` -* Removed `Guzzle\Http\Message\RequestInterface::isRedirect` -* Made `Guzzle\Http\Client::expandTemplate` and `getUriTemplate` protected methods. -* You can now enable E_USER_DEPRECATED warnings to see if you are using a deprecated method by setting - `Guzzle\Common\Version::$emitWarnings` to true. -* Marked `Guzzle\Http\Message\Request::isResponseBodyRepeatable()` as deprecated. Use - `$request->getResponseBody()->isRepeatable()` instead. -* Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use - `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead. -* Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use - `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead. -* Marked `Guzzle\Http\Message\Request::setIsRedirect()` as deprecated. Use the HistoryPlugin instead. -* Marked `Guzzle\Http\Message\Request::isRedirect()` as deprecated. Use the HistoryPlugin instead. -* Marked `Guzzle\Cache\CacheAdapterFactory::factory()` as deprecated -* Marked 'command.headers', 'command.response_body' and 'command.on_complete' as deprecated for AbstractCommand. - These will work through Guzzle 4.0 -* Marked 'request.params' for `Guzzle\Http\Client` as deprecated. Use [request.options][params]. -* Marked `Guzzle\Service\Client::enableMagicMethods()` as deprecated. Magic methods can no longer be disabled on a Guzzle\Service\Client. -* Marked `Guzzle\Service\Client::getDefaultHeaders()` as deprecated. Use $client->getConfig()->getPath('request.options/headers')`. -* Marked `Guzzle\Service\Client::setDefaultHeaders()` as deprecated. Use $client->getConfig()->setPath('request.options/headers/{header_name}', 'value')`. -* Marked `Guzzle\Parser\Url\UrlParser` as deprecated. Just use PHP's `parse_url()` and percent encode your UTF-8. -* Marked `Guzzle\Common\Collection::inject()` as deprecated. -* Marked `Guzzle\Plugin\CurlAuth\CurlAuthPlugin` as deprecated. Use `$client->getConfig()->setPath('request.options/auth', array('user', 'pass', 'Basic|Digest');` -* CacheKeyProviderInterface and DefaultCacheKeyProvider are no longer used. All of this logic is handled in a - CacheStorageInterface. These two objects and interface will be removed in a future version. -* Always setting X-cache headers on cached responses -* Default cache TTLs are now handled by the CacheStorageInterface of a CachePlugin -* `CacheStorageInterface::cache($key, Response $response, $ttl = null)` has changed to `cache(RequestInterface - $request, Response $response);` -* `CacheStorageInterface::fetch($key)` has changed to `fetch(RequestInterface $request);` -* `CacheStorageInterface::delete($key)` has changed to `delete(RequestInterface $request);` -* Added `CacheStorageInterface::purge($url)` -* `DefaultRevalidation::__construct(CacheKeyProviderInterface $cacheKey, CacheStorageInterface $cache, CachePlugin - $plugin)` has changed to `DefaultRevalidation::__construct(CacheStorageInterface $cache, - CanCacheStrategyInterface $canCache = null)` -* Added `RevalidationInterface::shouldRevalidate(RequestInterface $request, Response $response)` - -## 3.6.0 - 2013-05-29 - -* ServiceDescription now implements ToArrayInterface -* Added command.hidden_params to blacklist certain headers from being treated as additionalParameters -* Guzzle can now correctly parse incomplete URLs -* Mixed casing of headers are now forced to be a single consistent casing across all values for that header. -* Messages internally use a HeaderCollection object to delegate handling case-insensitive header resolution -* Removed the whole changedHeader() function system of messages because all header changes now go through addHeader(). -* Specific header implementations can be created for complex headers. When a message creates a header, it uses a - HeaderFactory which can map specific headers to specific header classes. There is now a Link header and - CacheControl header implementation. -* Removed from interface: Guzzle\Http\ClientInterface::setUriTemplate -* Removed from interface: Guzzle\Http\ClientInterface::setCurlMulti() -* Removed Guzzle\Http\Message\Request::receivedRequestHeader() and implemented this functionality in - Guzzle\Http\Curl\RequestMediator -* Removed the optional $asString parameter from MessageInterface::getHeader(). Just cast the header to a string. -* Removed the optional $tryChunkedTransfer option from Guzzle\Http\Message\EntityEnclosingRequestInterface -* Removed the $asObjects argument from Guzzle\Http\Message\MessageInterface::getHeaders() -* Removed Guzzle\Parser\ParserRegister::get(). Use getParser() -* Removed Guzzle\Parser\ParserRegister::set(). Use registerParser(). -* All response header helper functions return a string rather than mixing Header objects and strings inconsistently -* Removed cURL blacklist support. This is no longer necessary now that Expect, Accept, etc. are managed by Guzzle - directly via interfaces -* Removed the injecting of a request object onto a response object. The methods to get and set a request still exist - but are a no-op until removed. -* Most classes that used to require a `Guzzle\Service\Command\CommandInterface` typehint now request a - `Guzzle\Service\Command\ArrayCommandInterface`. -* Added `Guzzle\Http\Message\RequestInterface::startResponse()` to the RequestInterface to handle injecting a response - on a request while the request is still being transferred -* The ability to case-insensitively search for header values -* Guzzle\Http\Message\Header::hasExactHeader -* Guzzle\Http\Message\Header::raw. Use getAll() -* Deprecated cache control specific methods on Guzzle\Http\Message\AbstractMessage. Use the CacheControl header object - instead. -* `Guzzle\Service\Command\CommandInterface` now extends from ToArrayInterface and ArrayAccess -* Added the ability to cast Model objects to a string to view debug information. - -## 3.5.0 - 2013-05-13 - -* Bug: Fixed a regression so that request responses are parsed only once per oncomplete event rather than multiple times -* Bug: Better cleanup of one-time events across the board (when an event is meant to fire once, it will now remove - itself from the EventDispatcher) -* Bug: `Guzzle\Log\MessageFormatter` now properly writes "total_time" and "connect_time" values -* Bug: Cloning an EntityEnclosingRequest now clones the EntityBody too -* Bug: Fixed an undefined index error when parsing nested JSON responses with a sentAs parameter that reference a - non-existent key -* Bug: All __call() method arguments are now required (helps with mocking frameworks) -* Deprecating Response::getRequest() and now using a shallow clone of a request object to remove a circular reference - to help with refcount based garbage collection of resources created by sending a request -* Deprecating ZF1 cache and log adapters. These will be removed in the next major version. -* Deprecating `Response::getPreviousResponse()` (method signature still exists, but it's deprecated). Use the - HistoryPlugin for a history. -* Added a `responseBody` alias for the `response_body` location -* Refactored internals to no longer rely on Response::getRequest() -* HistoryPlugin can now be cast to a string -* HistoryPlugin now logs transactions rather than requests and responses to more accurately keep track of the requests - and responses that are sent over the wire -* Added `getEffectiveUrl()` and `getRedirectCount()` to Response objects - -## 3.4.3 - 2013-04-30 - -* Bug fix: Fixing bug introduced in 3.4.2 where redirect responses are duplicated on the final redirected response -* Added a check to re-extract the temp cacert bundle from the phar before sending each request - -## 3.4.2 - 2013-04-29 - -* Bug fix: Stream objects now work correctly with "a" and "a+" modes -* Bug fix: Removing `Transfer-Encoding: chunked` header when a Content-Length is present -* Bug fix: AsyncPlugin no longer forces HEAD requests -* Bug fix: DateTime timezones are now properly handled when using the service description schema formatter -* Bug fix: CachePlugin now properly handles stale-if-error directives when a request to the origin server fails -* Setting a response on a request will write to the custom request body from the response body if one is specified -* LogPlugin now writes to php://output when STDERR is undefined -* Added the ability to set multiple POST files for the same key in a single call -* application/x-www-form-urlencoded POSTs now use the utf-8 charset by default -* Added the ability to queue CurlExceptions to the MockPlugin -* Cleaned up how manual responses are queued on requests (removed "queued_response" and now using request.before_send) -* Configuration loading now allows remote files - -## 3.4.1 - 2013-04-16 - -* Large refactoring to how CurlMulti handles work. There is now a proxy that sits in front of a pool of CurlMulti - handles. This greatly simplifies the implementation, fixes a couple bugs, and provides a small performance boost. -* Exceptions are now properly grouped when sending requests in parallel -* Redirects are now properly aggregated when a multi transaction fails -* Redirects now set the response on the original object even in the event of a failure -* Bug fix: Model names are now properly set even when using $refs -* Added support for PHP 5.5's CurlFile to prevent warnings with the deprecated @ syntax -* Added support for oauth_callback in OAuth signatures -* Added support for oauth_verifier in OAuth signatures -* Added support to attempt to retrieve a command first literally, then ucfirst, the with inflection - -## 3.4.0 - 2013-04-11 - -* Bug fix: URLs are now resolved correctly based on http://tools.ietf.org/html/rfc3986#section-5.2. #289 -* Bug fix: Absolute URLs with a path in a service description will now properly override the base URL. #289 -* Bug fix: Parsing a query string with a single PHP array value will now result in an array. #263 -* Bug fix: Better normalization of the User-Agent header to prevent duplicate headers. #264. -* Bug fix: Added `number` type to service descriptions. -* Bug fix: empty parameters are removed from an OAuth signature -* Bug fix: Revalidating a cache entry prefers the Last-Modified over the Date header -* Bug fix: Fixed "array to string" error when validating a union of types in a service description -* Bug fix: Removed code that attempted to determine the size of a stream when data is written to the stream -* Bug fix: Not including an `oauth_token` if the value is null in the OauthPlugin. -* Bug fix: Now correctly aggregating successful requests and failed requests in CurlMulti when a redirect occurs. -* The new default CURLOPT_TIMEOUT setting has been increased to 150 seconds so that Guzzle works on poor connections. -* Added a feature to EntityEnclosingRequest::setBody() that will automatically set the Content-Type of the request if - the Content-Type can be determined based on the entity body or the path of the request. -* Added the ability to overwrite configuration settings in a client when grabbing a throwaway client from a builder. -* Added support for a PSR-3 LogAdapter. -* Added a `command.after_prepare` event -* Added `oauth_callback` parameter to the OauthPlugin -* Added the ability to create a custom stream class when using a stream factory -* Added a CachingEntityBody decorator -* Added support for `additionalParameters` in service descriptions to define how custom parameters are serialized. -* The bundled SSL certificate is now provided in the phar file and extracted when running Guzzle from a phar. -* You can now send any EntityEnclosingRequest with POST fields or POST files and cURL will handle creating bodies -* POST requests using a custom entity body are now treated exactly like PUT requests but with a custom cURL method. This - means that the redirect behavior of POST requests with custom bodies will not be the same as POST requests that use - POST fields or files (the latter is only used when emulating a form POST in the browser). -* Lots of cleanup to CurlHandle::factory and RequestFactory::createRequest - -## 3.3.1 - 2013-03-10 - -* Added the ability to create PHP streaming responses from HTTP requests -* Bug fix: Running any filters when parsing response headers with service descriptions -* Bug fix: OauthPlugin fixes to allow for multi-dimensional array signing, and sorting parameters before signing -* Bug fix: Removed the adding of default empty arrays and false Booleans to responses in order to be consistent across - response location visitors. -* Bug fix: Removed the possibility of creating configuration files with circular dependencies -* RequestFactory::create() now uses the key of a POST file when setting the POST file name -* Added xmlAllowEmpty to serialize an XML body even if no XML specific parameters are set - -## 3.3.0 - 2013-03-03 - -* A large number of performance optimizations have been made -* Bug fix: Added 'wb' as a valid write mode for streams -* Bug fix: `Guzzle\Http\Message\Response::json()` now allows scalar values to be returned -* Bug fix: Fixed bug in `Guzzle\Http\Message\Response` where wrapping quotes were stripped from `getEtag()` -* BC: Removed `Guzzle\Http\Utils` class -* BC: Setting a service description on a client will no longer modify the client's command factories. -* BC: Emitting IO events from a RequestMediator is now a parameter that must be set in a request's curl options using - the 'emit_io' key. This was previously set under a request's parameters using 'curl.emit_io' -* BC: `Guzzle\Stream\Stream::getWrapper()` and `Guzzle\Stream\Stream::getSteamType()` are no longer converted to - lowercase -* Operation parameter objects are now lazy loaded internally -* Added ErrorResponsePlugin that can throw errors for responses defined in service description operations' errorResponses -* Added support for instantiating responseType=class responseClass classes. Classes must implement - `Guzzle\Service\Command\ResponseClassInterface` -* Added support for additionalProperties for top-level parameters in responseType=model responseClasses. These - additional properties also support locations and can be used to parse JSON responses where the outermost part of the - JSON is an array -* Added support for nested renaming of JSON models (rename sentAs to name) -* CachePlugin - * Added support for stale-if-error so that the CachePlugin can now serve stale content from the cache on error - * Debug headers can now added to cached response in the CachePlugin - -## 3.2.0 - 2013-02-14 - -* CurlMulti is no longer reused globally. A new multi object is created per-client. This helps to isolate clients. -* URLs with no path no longer contain a "/" by default -* Guzzle\Http\QueryString does no longer manages the leading "?". This is now handled in Guzzle\Http\Url. -* BadResponseException no longer includes the full request and response message -* Adding setData() to Guzzle\Service\Description\ServiceDescriptionInterface -* Adding getResponseBody() to Guzzle\Http\Message\RequestInterface -* Various updates to classes to use ServiceDescriptionInterface type hints rather than ServiceDescription -* Header values can now be normalized into distinct values when multiple headers are combined with a comma separated list -* xmlEncoding can now be customized for the XML declaration of a XML service description operation -* Guzzle\Http\QueryString now uses Guzzle\Http\QueryAggregator\QueryAggregatorInterface objects to add custom value - aggregation and no longer uses callbacks -* The URL encoding implementation of Guzzle\Http\QueryString can now be customized -* Bug fix: Filters were not always invoked for array service description parameters -* Bug fix: Redirects now use a target response body rather than a temporary response body -* Bug fix: The default exponential backoff BackoffPlugin was not giving when the request threshold was exceeded -* Bug fix: Guzzle now takes the first found value when grabbing Cache-Control directives - -## 3.1.2 - 2013-01-27 - -* Refactored how operation responses are parsed. Visitors now include a before() method responsible for parsing the - response body. For example, the XmlVisitor now parses the XML response into an array in the before() method. -* Fixed an issue where cURL would not automatically decompress responses when the Accept-Encoding header was sent -* CURLOPT_SSL_VERIFYHOST is never set to 1 because it is deprecated (see 5e0ff2ef20f839e19d1eeb298f90ba3598784444) -* Fixed a bug where redirect responses were not chained correctly using getPreviousResponse() -* Setting default headers on a client after setting the user-agent will not erase the user-agent setting - -## 3.1.1 - 2013-01-20 - -* Adding wildcard support to Guzzle\Common\Collection::getPath() -* Adding alias support to ServiceBuilder configs -* Adding Guzzle\Service\Resource\CompositeResourceIteratorFactory and cleaning up factory interface - -## 3.1.0 - 2013-01-12 - -* BC: CurlException now extends from RequestException rather than BadResponseException -* BC: Renamed Guzzle\Plugin\Cache\CanCacheStrategyInterface::canCache() to canCacheRequest() and added CanCacheResponse() -* Added getData to ServiceDescriptionInterface -* Added context array to RequestInterface::setState() -* Bug: Removing hard dependency on the BackoffPlugin from Guzzle\Http -* Bug: Adding required content-type when JSON request visitor adds JSON to a command -* Bug: Fixing the serialization of a service description with custom data -* Made it easier to deal with exceptions thrown when transferring commands or requests in parallel by providing - an array of successful and failed responses -* Moved getPath from Guzzle\Service\Resource\Model to Guzzle\Common\Collection -* Added Guzzle\Http\IoEmittingEntityBody -* Moved command filtration from validators to location visitors -* Added `extends` attributes to service description parameters -* Added getModels to ServiceDescriptionInterface - -## 3.0.7 - 2012-12-19 - -* Fixing phar detection when forcing a cacert to system if null or true -* Allowing filename to be passed to `Guzzle\Http\Message\Request::setResponseBody()` -* Cleaning up `Guzzle\Common\Collection::inject` method -* Adding a response_body location to service descriptions - -## 3.0.6 - 2012-12-09 - -* CurlMulti performance improvements -* Adding setErrorResponses() to Operation -* composer.json tweaks - -## 3.0.5 - 2012-11-18 - -* Bug: Fixing an infinite recursion bug caused from revalidating with the CachePlugin -* Bug: Response body can now be a string containing "0" -* Bug: Using Guzzle inside of a phar uses system by default but now allows for a custom cacert -* Bug: QueryString::fromString now properly parses query string parameters that contain equal signs -* Added support for XML attributes in service description responses -* DefaultRequestSerializer now supports array URI parameter values for URI template expansion -* Added better mimetype guessing to requests and post files - -## 3.0.4 - 2012-11-11 - -* Bug: Fixed a bug when adding multiple cookies to a request to use the correct glue value -* Bug: Cookies can now be added that have a name, domain, or value set to "0" -* Bug: Using the system cacert bundle when using the Phar -* Added json and xml methods to Response to make it easier to parse JSON and XML response data into data structures -* Enhanced cookie jar de-duplication -* Added the ability to enable strict cookie jars that throw exceptions when invalid cookies are added -* Added setStream to StreamInterface to actually make it possible to implement custom rewind behavior for entity bodies -* Added the ability to create any sort of hash for a stream rather than just an MD5 hash - -## 3.0.3 - 2012-11-04 - -* Implementing redirects in PHP rather than cURL -* Added PECL URI template extension and using as default parser if available -* Bug: Fixed Content-Length parsing of Response factory -* Adding rewind() method to entity bodies and streams. Allows for custom rewinding of non-repeatable streams. -* Adding ToArrayInterface throughout library -* Fixing OauthPlugin to create unique nonce values per request - -## 3.0.2 - 2012-10-25 - -* Magic methods are enabled by default on clients -* Magic methods return the result of a command -* Service clients no longer require a base_url option in the factory -* Bug: Fixed an issue with URI templates where null template variables were being expanded - -## 3.0.1 - 2012-10-22 - -* Models can now be used like regular collection objects by calling filter, map, etc. -* Models no longer require a Parameter structure or initial data in the constructor -* Added a custom AppendIterator to get around a PHP bug with the `\AppendIterator` - -## 3.0.0 - 2012-10-15 - -* Rewrote service description format to be based on Swagger - * Now based on JSON schema - * Added nested input structures and nested response models - * Support for JSON and XML input and output models - * Renamed `commands` to `operations` - * Removed dot class notation - * Removed custom types -* Broke the project into smaller top-level namespaces to be more component friendly -* Removed support for XML configs and descriptions. Use arrays or JSON files. -* Removed the Validation component and Inspector -* Moved all cookie code to Guzzle\Plugin\Cookie -* Magic methods on a Guzzle\Service\Client now return the command un-executed. -* Calling getResult() or getResponse() on a command will lazily execute the command if needed. -* Now shipping with cURL's CA certs and using it by default -* Added previousResponse() method to response objects -* No longer sending Accept and Accept-Encoding headers on every request -* Only sending an Expect header by default when a payload is greater than 1MB -* Added/moved client options: - * curl.blacklist to curl.option.blacklist - * Added ssl.certificate_authority -* Added a Guzzle\Iterator component -* Moved plugins from Guzzle\Http\Plugin to Guzzle\Plugin -* Added a more robust backoff retry strategy (replaced the ExponentialBackoffPlugin) -* Added a more robust caching plugin -* Added setBody to response objects -* Updating LogPlugin to use a more flexible MessageFormatter -* Added a completely revamped build process -* Cleaning up Collection class and removing default values from the get method -* Fixed ZF2 cache adapters - -## 2.8.8 - 2012-10-15 - -* Bug: Fixed a cookie issue that caused dot prefixed domains to not match where popular browsers did - -## 2.8.7 - 2012-09-30 - -* Bug: Fixed config file aliases for JSON includes -* Bug: Fixed cookie bug on a request object by using CookieParser to parse cookies on requests -* Bug: Removing the path to a file when sending a Content-Disposition header on a POST upload -* Bug: Hardening request and response parsing to account for missing parts -* Bug: Fixed PEAR packaging -* Bug: Fixed Request::getInfo -* Bug: Fixed cases where CURLM_CALL_MULTI_PERFORM return codes were causing curl transactions to fail -* Adding the ability for the namespace Iterator factory to look in multiple directories -* Added more getters/setters/removers from service descriptions -* Added the ability to remove POST fields from OAuth signatures -* OAuth plugin now supports 2-legged OAuth - -## 2.8.6 - 2012-09-05 - -* Added the ability to modify and build service descriptions -* Added the use of visitors to apply parameters to locations in service descriptions using the dynamic command -* Added a `json` parameter location -* Now allowing dot notation for classes in the CacheAdapterFactory -* Using the union of two arrays rather than an array_merge when extending service builder services and service params -* Ensuring that a service is a string before doing strpos() checks on it when substituting services for references - in service builder config files. -* Services defined in two different config files that include one another will by default replace the previously - defined service, but you can now create services that extend themselves and merge their settings over the previous -* The JsonLoader now supports aliasing filenames with different filenames. This allows you to alias something like - '_default' with a default JSON configuration file. - -## 2.8.5 - 2012-08-29 - -* Bug: Suppressed empty arrays from URI templates -* Bug: Added the missing $options argument from ServiceDescription::factory to enable caching -* Added support for HTTP responses that do not contain a reason phrase in the start-line -* AbstractCommand commands are now invokable -* Added a way to get the data used when signing an Oauth request before a request is sent - -## 2.8.4 - 2012-08-15 - -* Bug: Custom delay time calculations are no longer ignored in the ExponentialBackoffPlugin -* Added the ability to transfer entity bodies as a string rather than streamed. This gets around curl error 65. Set `body_as_string` in a request's curl options to enable. -* Added a StreamInterface, EntityBodyInterface, and added ftell() to Guzzle\Common\Stream -* Added an AbstractEntityBodyDecorator and a ReadLimitEntityBody decorator to transfer only a subset of a decorated stream -* Stream and EntityBody objects will now return the file position to the previous position after a read required operation (e.g. getContentMd5()) -* Added additional response status codes -* Removed SSL information from the default User-Agent header -* DELETE requests can now send an entity body -* Added an EventDispatcher to the ExponentialBackoffPlugin and added an ExponentialBackoffLogger to log backoff retries -* Added the ability of the MockPlugin to consume mocked request bodies -* LogPlugin now exposes request and response objects in the extras array - -## 2.8.3 - 2012-07-30 - -* Bug: Fixed a case where empty POST requests were sent as GET requests -* Bug: Fixed a bug in ExponentialBackoffPlugin that caused fatal errors when retrying an EntityEnclosingRequest that does not have a body -* Bug: Setting the response body of a request to null after completing a request, not when setting the state of a request to new -* Added multiple inheritance to service description commands -* Added an ApiCommandInterface and added `getParamNames()` and `hasParam()` -* Removed the default 2mb size cutoff from the Md5ValidatorPlugin so that it now defaults to validating everything -* Changed CurlMulti::perform to pass a smaller timeout to CurlMulti::executeHandles - -## 2.8.2 - 2012-07-24 - -* Bug: Query string values set to 0 are no longer dropped from the query string -* Bug: A Collection object is no longer created each time a call is made to `Guzzle\Service\Command\AbstractCommand::getRequestHeaders()` -* Bug: `+` is now treated as an encoded space when parsing query strings -* QueryString and Collection performance improvements -* Allowing dot notation for class paths in filters attribute of a service descriptions - -## 2.8.1 - 2012-07-16 - -* Loosening Event Dispatcher dependency -* POST redirects can now be customized using CURLOPT_POSTREDIR - -## 2.8.0 - 2012-07-15 - -* BC: Guzzle\Http\Query - * Query strings with empty variables will always show an equal sign unless the variable is set to QueryString::BLANK (e.g. ?acl= vs ?acl) - * Changed isEncodingValues() and isEncodingFields() to isUrlEncoding() - * Changed setEncodeValues(bool) and setEncodeFields(bool) to useUrlEncoding(bool) - * Changed the aggregation functions of QueryString to be static methods - * Can now use fromString() with querystrings that have a leading ? -* cURL configuration values can be specified in service descriptions using `curl.` prefixed parameters -* Content-Length is set to 0 before emitting the request.before_send event when sending an empty request body -* Cookies are no longer URL decoded by default -* Bug: URI template variables set to null are no longer expanded - -## 2.7.2 - 2012-07-02 - -* BC: Moving things to get ready for subtree splits. Moving Inflection into Common. Moving Guzzle\Http\Parser to Guzzle\Parser. -* BC: Removing Guzzle\Common\Batch\Batch::count() and replacing it with isEmpty() -* CachePlugin now allows for a custom request parameter function to check if a request can be cached -* Bug fix: CachePlugin now only caches GET and HEAD requests by default -* Bug fix: Using header glue when transferring headers over the wire -* Allowing deeply nested arrays for composite variables in URI templates -* Batch divisors can now return iterators or arrays - -## 2.7.1 - 2012-06-26 - -* Minor patch to update version number in UA string -* Updating build process - -## 2.7.0 - 2012-06-25 - -* BC: Inflection classes moved to Guzzle\Inflection. No longer static methods. Can now inject custom inflectors into classes. -* BC: Removed magic setX methods from commands -* BC: Magic methods mapped to service description commands are now inflected in the command factory rather than the client __call() method -* Verbose cURL options are no longer enabled by default. Set curl.debug to true on a client to enable. -* Bug: Now allowing colons in a response start-line (e.g. HTTP/1.1 503 Service Unavailable: Back-end server is at capacity) -* Guzzle\Service\Resource\ResourceIteratorApplyBatched now internally uses the Guzzle\Common\Batch namespace -* Added Guzzle\Service\Plugin namespace and a PluginCollectionPlugin -* Added the ability to set POST fields and files in a service description -* Guzzle\Http\EntityBody::factory() now accepts objects with a __toString() method -* Adding a command.before_prepare event to clients -* Added BatchClosureTransfer and BatchClosureDivisor -* BatchTransferException now includes references to the batch divisor and transfer strategies -* Fixed some tests so that they pass more reliably -* Added Guzzle\Common\Log\ArrayLogAdapter - -## 2.6.6 - 2012-06-10 - -* BC: Removing Guzzle\Http\Plugin\BatchQueuePlugin -* BC: Removing Guzzle\Service\Command\CommandSet -* Adding generic batching system (replaces the batch queue plugin and command set) -* Updating ZF cache and log adapters and now using ZF's composer repository -* Bug: Setting the name of each ApiParam when creating through an ApiCommand -* Adding result_type, result_doc, deprecated, and doc_url to service descriptions -* Bug: Changed the default cookie header casing back to 'Cookie' - -## 2.6.5 - 2012-06-03 - -* BC: Renaming Guzzle\Http\Message\RequestInterface::getResourceUri() to getResource() -* BC: Removing unused AUTH_BASIC and AUTH_DIGEST constants from -* BC: Guzzle\Http\Cookie is now used to manage Set-Cookie data, not Cookie data -* BC: Renaming methods in the CookieJarInterface -* Moving almost all cookie logic out of the CookiePlugin and into the Cookie or CookieJar implementations -* Making the default glue for HTTP headers ';' instead of ',' -* Adding a removeValue to Guzzle\Http\Message\Header -* Adding getCookies() to request interface. -* Making it easier to add event subscribers to HasDispatcherInterface classes. Can now directly call addSubscriber() - -## 2.6.4 - 2012-05-30 - -* BC: Cleaning up how POST files are stored in EntityEnclosingRequest objects. Adding PostFile class. -* BC: Moving ApiCommand specific functionality from the Inspector and on to the ApiCommand -* Bug: Fixing magic method command calls on clients -* Bug: Email constraint only validates strings -* Bug: Aggregate POST fields when POST files are present in curl handle -* Bug: Fixing default User-Agent header -* Bug: Only appending or prepending parameters in commands if they are specified -* Bug: Not requiring response reason phrases or status codes to match a predefined list of codes -* Allowing the use of dot notation for class namespaces when using instance_of constraint -* Added any_match validation constraint -* Added an AsyncPlugin -* Passing request object to the calculateWait method of the ExponentialBackoffPlugin -* Allowing the result of a command object to be changed -* Parsing location and type sub values when instantiating a service description rather than over and over at runtime - -## 2.6.3 - 2012-05-23 - -* [BC] Guzzle\Common\FromConfigInterface no longer requires any config options. -* [BC] Refactoring how POST files are stored on an EntityEnclosingRequest. They are now separate from POST fields. -* You can now use an array of data when creating PUT request bodies in the request factory. -* Removing the requirement that HTTPS requests needed a Cache-Control: public directive to be cacheable. -* [Http] Adding support for Content-Type in multipart POST uploads per upload -* [Http] Added support for uploading multiple files using the same name (foo[0], foo[1]) -* Adding more POST data operations for easier manipulation of POST data. -* You can now set empty POST fields. -* The body of a request is only shown on EntityEnclosingRequest objects that do not use POST files. -* Split the Guzzle\Service\Inspector::validateConfig method into two methods. One to initialize when a command is created, and one to validate. -* CS updates - -## 2.6.2 - 2012-05-19 - -* [Http] Better handling of nested scope requests in CurlMulti. Requests are now always prepares in the send() method rather than the addRequest() method. - -## 2.6.1 - 2012-05-19 - -* [BC] Removing 'path' support in service descriptions. Use 'uri'. -* [BC] Guzzle\Service\Inspector::parseDocBlock is now protected. Adding getApiParamsForClass() with cache. -* [BC] Removing Guzzle\Common\NullObject. Use https://github.com/mtdowling/NullObject if you need it. -* [BC] Removing Guzzle\Common\XmlElement. -* All commands, both dynamic and concrete, have ApiCommand objects. -* Adding a fix for CurlMulti so that if all of the connections encounter some sort of curl error, then the loop exits. -* Adding checks to EntityEnclosingRequest so that empty POST files and fields are ignored. -* Making the method signature of Guzzle\Service\Builder\ServiceBuilder::factory more flexible. - -## 2.6.0 - 2012-05-15 - -* [BC] Moving Guzzle\Service\Builder to Guzzle\Service\Builder\ServiceBuilder -* [BC] Executing a Command returns the result of the command rather than the command -* [BC] Moving all HTTP parsing logic to Guzzle\Http\Parsers. Allows for faster C implementations if needed. -* [BC] Changing the Guzzle\Http\Message\Response::setProtocol() method to accept a protocol and version in separate args. -* [BC] Moving ResourceIterator* to Guzzle\Service\Resource -* [BC] Completely refactored ResourceIterators to iterate over a cloned command object -* [BC] Moved Guzzle\Http\UriTemplate to Guzzle\Http\Parser\UriTemplate\UriTemplate -* [BC] Guzzle\Guzzle is now deprecated -* Moving Guzzle\Common\Guzzle::inject to Guzzle\Common\Collection::inject -* Adding Guzzle\Version class to give version information about Guzzle -* Adding Guzzle\Http\Utils class to provide getDefaultUserAgent() and getHttpDate() -* Adding Guzzle\Curl\CurlVersion to manage caching curl_version() data -* ServiceDescription and ServiceBuilder are now cacheable using similar configs -* Changing the format of XML and JSON service builder configs. Backwards compatible. -* Cleaned up Cookie parsing -* Trimming the default Guzzle User-Agent header -* Adding a setOnComplete() method to Commands that is called when a command completes -* Keeping track of requests that were mocked in the MockPlugin -* Fixed a caching bug in the CacheAdapterFactory -* Inspector objects can be injected into a Command object -* Refactoring a lot of code and tests to be case insensitive when dealing with headers -* Adding Guzzle\Http\Message\HeaderComparison for easy comparison of HTTP headers using a DSL -* Adding the ability to set global option overrides to service builder configs -* Adding the ability to include other service builder config files from within XML and JSON files -* Moving the parseQuery method out of Url and on to QueryString::fromString() as a static factory method. - -## 2.5.0 - 2012-05-08 - -* Major performance improvements -* [BC] Simplifying Guzzle\Common\Collection. Please check to see if you are using features that are now deprecated. -* [BC] Using a custom validation system that allows a flyweight implementation for much faster validation. No longer using Symfony2 Validation component. -* [BC] No longer supporting "{{ }}" for injecting into command or UriTemplates. Use "{}" -* Added the ability to passed parameters to all requests created by a client -* Added callback functionality to the ExponentialBackoffPlugin -* Using microtime in ExponentialBackoffPlugin to allow more granular backoff strategies. -* Rewinding request stream bodies when retrying requests -* Exception is thrown when JSON response body cannot be decoded -* Added configurable magic method calls to clients and commands. This is off by default. -* Fixed a defect that added a hash to every parsed URL part -* Fixed duplicate none generation for OauthPlugin. -* Emitting an event each time a client is generated by a ServiceBuilder -* Using an ApiParams object instead of a Collection for parameters of an ApiCommand -* cache.* request parameters should be renamed to params.cache.* -* Added the ability to set arbitrary curl options on requests (disable_wire, progress, etc.). See CurlHandle. -* Added the ability to disable type validation of service descriptions -* ServiceDescriptions and ServiceBuilders are now Serializable +# Change Log + +## 6.5.3 - 2020-04-18 + +* Use Symfony intl-idn polyfill [#2550](https://github.com/guzzle/guzzle/pull/2550) +* Remove use of internal functions [#2548](https://github.com/guzzle/guzzle/pull/2548) + +## 6.5.2 - 2019-12-23 + +* idn_to_ascii() fix for old PHP versions [#2489](https://github.com/guzzle/guzzle/pull/2489) + +## 6.5.1 - 2019-12-21 + +* Better defaults for PHP installations with old ICU lib [#2454](https://github.com/guzzle/guzzle/pull/2454) +* IDN support for redirects [#2424](https://github.com/guzzle/guzzle/pull/2424) + +## 6.5.0 - 2019-12-07 + +* Improvement: Added support for reset internal queue in MockHandler. [#2143](https://github.com/guzzle/guzzle/pull/2143) +* Improvement: Added support to pass arbitrary options to `curl_multi_init`. [#2287](https://github.com/guzzle/guzzle/pull/2287) +* Fix: Gracefully handle passing `null` to the `header` option. [#2132](https://github.com/guzzle/guzzle/pull/2132) +* Fix: `RetryMiddleware` did not do exponential delay between retires due unit mismatch. [#2132](https://github.com/guzzle/guzzle/pull/2132) +* Fix: Prevent undefined offset when using array for ssl_key options. [#2348](https://github.com/guzzle/guzzle/pull/2348) +* Deprecated `ClientInterface::VERSION` + +## 6.4.1 - 2019-10-23 + +* No `guzzle.phar` was created in 6.4.0 due expired API token. This release will fix that +* Added `parent::__construct()` to `FileCookieJar` and `SessionCookieJar` + +## 6.4.0 - 2019-10-23 + +* Improvement: Improved error messages when using curl < 7.21.2 [#2108](https://github.com/guzzle/guzzle/pull/2108) +* Fix: Test if response is readable before returning a summary in `RequestException::getResponseBodySummary()` [#2081](https://github.com/guzzle/guzzle/pull/2081) +* Fix: Add support for GUZZLE_CURL_SELECT_TIMEOUT environment variable [#2161](https://github.com/guzzle/guzzle/pull/2161) +* Improvement: Added `GuzzleHttp\Exception\InvalidArgumentException` [#2163](https://github.com/guzzle/guzzle/pull/2163) +* Improvement: Added `GuzzleHttp\_current_time()` to use `hrtime()` if that function exists. [#2242](https://github.com/guzzle/guzzle/pull/2242) +* Improvement: Added curl's `appconnect_time` in `TransferStats` [#2284](https://github.com/guzzle/guzzle/pull/2284) +* Improvement: Make GuzzleException extend Throwable wherever it's available [#2273](https://github.com/guzzle/guzzle/pull/2273) +* Fix: Prevent concurrent writes to file when saving `CookieJar` [#2335](https://github.com/guzzle/guzzle/pull/2335) +* Improvement: Update `MockHandler` so we can test transfer time [#2362](https://github.com/guzzle/guzzle/pull/2362) + +## 6.3.3 - 2018-04-22 + +* Fix: Default headers when decode_content is specified + + +## 6.3.2 - 2018-03-26 + +* Fix: Release process + + +## 6.3.1 - 2018-03-26 + +* Bug fix: Parsing 0 epoch expiry times in cookies [#2014](https://github.com/guzzle/guzzle/pull/2014) +* Improvement: Better ConnectException detection [#2012](https://github.com/guzzle/guzzle/pull/2012) +* Bug fix: Malformed domain that contains a "/" [#1999](https://github.com/guzzle/guzzle/pull/1999) +* Bug fix: Undefined offset when a cookie has no first key-value pair [#1998](https://github.com/guzzle/guzzle/pull/1998) +* Improvement: Support PHPUnit 6 [#1953](https://github.com/guzzle/guzzle/pull/1953) +* Bug fix: Support empty headers [#1915](https://github.com/guzzle/guzzle/pull/1915) +* Bug fix: Ignore case during header modifications [#1916](https://github.com/guzzle/guzzle/pull/1916) + ++ Minor code cleanups, documentation fixes and clarifications. + + +## 6.3.0 - 2017-06-22 + +* Feature: force IP resolution (ipv4 or ipv6) [#1608](https://github.com/guzzle/guzzle/pull/1608), [#1659](https://github.com/guzzle/guzzle/pull/1659) +* Improvement: Don't include summary in exception message when body is empty [#1621](https://github.com/guzzle/guzzle/pull/1621) +* Improvement: Handle `on_headers` option in MockHandler [#1580](https://github.com/guzzle/guzzle/pull/1580) +* Improvement: Added SUSE Linux CA path [#1609](https://github.com/guzzle/guzzle/issues/1609) +* Improvement: Use class reference for getting the name of the class instead of using hardcoded strings [#1641](https://github.com/guzzle/guzzle/pull/1641) +* Feature: Added `read_timeout` option [#1611](https://github.com/guzzle/guzzle/pull/1611) +* Bug fix: PHP 7.x fixes [#1685](https://github.com/guzzle/guzzle/pull/1685), [#1686](https://github.com/guzzle/guzzle/pull/1686), [#1811](https://github.com/guzzle/guzzle/pull/1811) +* Deprecation: BadResponseException instantiation without a response [#1642](https://github.com/guzzle/guzzle/pull/1642) +* Feature: Added NTLM auth [#1569](https://github.com/guzzle/guzzle/pull/1569) +* Feature: Track redirect HTTP status codes [#1711](https://github.com/guzzle/guzzle/pull/1711) +* Improvement: Check handler type during construction [#1745](https://github.com/guzzle/guzzle/pull/1745) +* Improvement: Always include the Content-Length if there's a body [#1721](https://github.com/guzzle/guzzle/pull/1721) +* Feature: Added convenience method to access a cookie by name [#1318](https://github.com/guzzle/guzzle/pull/1318) +* Bug fix: Fill `CURLOPT_CAPATH` and `CURLOPT_CAINFO` properly [#1684](https://github.com/guzzle/guzzle/pull/1684) +* Improvement: Use `\GuzzleHttp\Promise\rejection_for` function instead of object init [#1827](https://github.com/guzzle/guzzle/pull/1827) + + ++ Minor code cleanups, documentation fixes and clarifications. + +## 6.2.3 - 2017-02-28 + +* Fix deprecations with guzzle/psr7 version 1.4 + +## 6.2.2 - 2016-10-08 + +* Allow to pass nullable Response to delay callable +* Only add scheme when host is present +* Fix drain case where content-length is the literal string zero +* Obfuscate in-URL credentials in exceptions + +## 6.2.1 - 2016-07-18 + +* Address HTTP_PROXY security vulnerability, CVE-2016-5385: + https://httpoxy.org/ +* Fixing timeout bug with StreamHandler: + https://github.com/guzzle/guzzle/pull/1488 +* Only read up to `Content-Length` in PHP StreamHandler to avoid timeouts when + a server does not honor `Connection: close`. +* Ignore URI fragment when sending requests. + +## 6.2.0 - 2016-03-21 + +* Feature: added `GuzzleHttp\json_encode` and `GuzzleHttp\json_decode`. + https://github.com/guzzle/guzzle/pull/1389 +* Bug fix: Fix sleep calculation when waiting for delayed requests. + https://github.com/guzzle/guzzle/pull/1324 +* Feature: More flexible history containers. + https://github.com/guzzle/guzzle/pull/1373 +* Bug fix: defer sink stream opening in StreamHandler. + https://github.com/guzzle/guzzle/pull/1377 +* Bug fix: do not attempt to escape cookie values. + https://github.com/guzzle/guzzle/pull/1406 +* Feature: report original content encoding and length on decoded responses. + https://github.com/guzzle/guzzle/pull/1409 +* Bug fix: rewind seekable request bodies before dispatching to cURL. + https://github.com/guzzle/guzzle/pull/1422 +* Bug fix: provide an empty string to `http_build_query` for HHVM workaround. + https://github.com/guzzle/guzzle/pull/1367 + +## 6.1.1 - 2015-11-22 + +* Bug fix: Proxy::wrapSync() now correctly proxies to the appropriate handler + https://github.com/guzzle/guzzle/commit/911bcbc8b434adce64e223a6d1d14e9a8f63e4e4 +* Feature: HandlerStack is now more generic. + https://github.com/guzzle/guzzle/commit/f2102941331cda544745eedd97fc8fd46e1ee33e +* Bug fix: setting verify to false in the StreamHandler now disables peer + verification. https://github.com/guzzle/guzzle/issues/1256 +* Feature: Middleware now uses an exception factory, including more error + context. https://github.com/guzzle/guzzle/pull/1282 +* Feature: better support for disabled functions. + https://github.com/guzzle/guzzle/pull/1287 +* Bug fix: fixed regression where MockHandler was not using `sink`. + https://github.com/guzzle/guzzle/pull/1292 + +## 6.1.0 - 2015-09-08 + +* Feature: Added the `on_stats` request option to provide access to transfer + statistics for requests. https://github.com/guzzle/guzzle/pull/1202 +* Feature: Added the ability to persist session cookies in CookieJars. + https://github.com/guzzle/guzzle/pull/1195 +* Feature: Some compatibility updates for Google APP Engine + https://github.com/guzzle/guzzle/pull/1216 +* Feature: Added support for NO_PROXY to prevent the use of a proxy based on + a simple set of rules. https://github.com/guzzle/guzzle/pull/1197 +* Feature: Cookies can now contain square brackets. + https://github.com/guzzle/guzzle/pull/1237 +* Bug fix: Now correctly parsing `=` inside of quotes in Cookies. + https://github.com/guzzle/guzzle/pull/1232 +* Bug fix: Cusotm cURL options now correctly override curl options of the + same name. https://github.com/guzzle/guzzle/pull/1221 +* Bug fix: Content-Type header is now added when using an explicitly provided + multipart body. https://github.com/guzzle/guzzle/pull/1218 +* Bug fix: Now ignoring Set-Cookie headers that have no name. +* Bug fix: Reason phrase is no longer cast to an int in some cases in the + cURL handler. https://github.com/guzzle/guzzle/pull/1187 +* Bug fix: Remove the Authorization header when redirecting if the Host + header changes. https://github.com/guzzle/guzzle/pull/1207 +* Bug fix: Cookie path matching fixes + https://github.com/guzzle/guzzle/issues/1129 +* Bug fix: Fixing the cURL `body_as_string` setting + https://github.com/guzzle/guzzle/pull/1201 +* Bug fix: quotes are no longer stripped when parsing cookies. + https://github.com/guzzle/guzzle/issues/1172 +* Bug fix: `form_params` and `query` now always uses the `&` separator. + https://github.com/guzzle/guzzle/pull/1163 +* Bug fix: Adding a Content-Length to PHP stream wrapper requests if not set. + https://github.com/guzzle/guzzle/pull/1189 + +## 6.0.2 - 2015-07-04 + +* Fixed a memory leak in the curl handlers in which references to callbacks + were not being removed by `curl_reset`. +* Cookies are now extracted properly before redirects. +* Cookies now allow more character ranges. +* Decoded Content-Encoding responses are now modified to correctly reflect + their state if the encoding was automatically removed by a handler. This + means that the `Content-Encoding` header may be removed an the + `Content-Length` modified to reflect the message size after removing the + encoding. +* Added a more explicit error message when trying to use `form_params` and + `multipart` in the same request. +* Several fixes for HHVM support. +* Functions are now conditionally required using an additional level of + indirection to help with global Composer installations. + +## 6.0.1 - 2015-05-27 + +* Fixed a bug with serializing the `query` request option where the `&` + separator was missing. +* Added a better error message for when `body` is provided as an array. Please + use `form_params` or `multipart` instead. +* Various doc fixes. + +## 6.0.0 - 2015-05-26 + +* See the UPGRADING.md document for more information. +* Added `multipart` and `form_params` request options. +* Added `synchronous` request option. +* Added the `on_headers` request option. +* Fixed `expect` handling. +* No longer adding default middlewares in the client ctor. These need to be + present on the provided handler in order to work. +* Requests are no longer initiated when sending async requests with the + CurlMultiHandler. This prevents unexpected recursion from requests completing + while ticking the cURL loop. +* Removed the semantics of setting `default` to `true`. This is no longer + required now that the cURL loop is not ticked for async requests. +* Added request and response logging middleware. +* No longer allowing self signed certificates when using the StreamHandler. +* Ensuring that `sink` is valid if saving to a file. +* Request exceptions now include a "handler context" which provides handler + specific contextual information. +* Added `GuzzleHttp\RequestOptions` to allow request options to be applied + using constants. +* `$maxHandles` has been removed from CurlMultiHandler. +* `MultipartPostBody` is now part of the `guzzlehttp/psr7` package. + +## 5.3.0 - 2015-05-19 + +* Mock now supports `save_to` +* Marked `AbstractRequestEvent::getTransaction()` as public. +* Fixed a bug in which multiple headers using different casing would overwrite + previous headers in the associative array. +* Added `Utils::getDefaultHandler()` +* Marked `GuzzleHttp\Client::getDefaultUserAgent` as deprecated. +* URL scheme is now always lowercased. + +## 6.0.0-beta.1 + +* Requires PHP >= 5.5 +* Updated to use PSR-7 + * Requires immutable messages, which basically means an event based system + owned by a request instance is no longer possible. + * Utilizing the [Guzzle PSR-7 package](https://github.com/guzzle/psr7). + * Removed the dependency on `guzzlehttp/streams`. These stream abstractions + are available in the `guzzlehttp/psr7` package under the `GuzzleHttp\Psr7` + namespace. +* Added middleware and handler system + * Replaced the Guzzle event and subscriber system with a middleware system. + * No longer depends on RingPHP, but rather places the HTTP handlers directly + in Guzzle, operating on PSR-7 messages. + * Retry logic is now encapsulated in `GuzzleHttp\Middleware::retry`, which + means the `guzzlehttp/retry-subscriber` is now obsolete. + * Mocking responses is now handled using `GuzzleHttp\Handler\MockHandler`. +* Asynchronous responses + * No longer supports the `future` request option to send an async request. + Instead, use one of the `*Async` methods of a client (e.g., `requestAsync`, + `getAsync`, etc.). + * Utilizing `GuzzleHttp\Promise` instead of React's promise library to avoid + recursion required by chaining and forwarding react promises. See + https://github.com/guzzle/promises + * Added `requestAsync` and `sendAsync` to send request asynchronously. + * Added magic methods for `getAsync()`, `postAsync()`, etc. to send requests + asynchronously. +* Request options + * POST and form updates + * Added the `form_fields` and `form_files` request options. + * Removed the `GuzzleHttp\Post` namespace. + * The `body` request option no longer accepts an array for POST requests. + * The `exceptions` request option has been deprecated in favor of the + `http_errors` request options. + * The `save_to` request option has been deprecated in favor of `sink` request + option. +* Clients no longer accept an array of URI template string and variables for + URI variables. You will need to expand URI templates before passing them + into a client constructor or request method. +* Client methods `get()`, `post()`, `put()`, `patch()`, `options()`, etc. are + now magic methods that will send synchronous requests. +* Replaced `Utils.php` with plain functions in `functions.php`. +* Removed `GuzzleHttp\Collection`. +* Removed `GuzzleHttp\BatchResults`. Batched pool results are now returned as + an array. +* Removed `GuzzleHttp\Query`. Query string handling is now handled using an + associative array passed into the `query` request option. The query string + is serialized using PHP's `http_build_query`. If you need more control, you + can pass the query string in as a string. +* `GuzzleHttp\QueryParser` has been replaced with the + `GuzzleHttp\Psr7\parse_query`. + +## 5.2.0 - 2015-01-27 + +* Added `AppliesHeadersInterface` to make applying headers to a request based + on the body more generic and not specific to `PostBodyInterface`. +* Reduced the number of stack frames needed to send requests. +* Nested futures are now resolved in the client rather than the RequestFsm +* Finishing state transitions is now handled in the RequestFsm rather than the + RingBridge. +* Added a guard in the Pool class to not use recursion for request retries. + +## 5.1.0 - 2014-12-19 + +* Pool class no longer uses recursion when a request is intercepted. +* The size of a Pool can now be dynamically adjusted using a callback. + See https://github.com/guzzle/guzzle/pull/943. +* Setting a request option to `null` when creating a request with a client will + ensure that the option is not set. This allows you to overwrite default + request options on a per-request basis. + See https://github.com/guzzle/guzzle/pull/937. +* Added the ability to limit which protocols are allowed for redirects by + specifying a `protocols` array in the `allow_redirects` request option. +* Nested futures due to retries are now resolved when waiting for synchronous + responses. See https://github.com/guzzle/guzzle/pull/947. +* `"0"` is now an allowed URI path. See + https://github.com/guzzle/guzzle/pull/935. +* `Query` no longer typehints on the `$query` argument in the constructor, + allowing for strings and arrays. +* Exceptions thrown in the `end` event are now correctly wrapped with Guzzle + specific exceptions if necessary. + +## 5.0.3 - 2014-11-03 + +This change updates query strings so that they are treated as un-encoded values +by default where the value represents an un-encoded value to send over the +wire. A Query object then encodes the value before sending over the wire. This +means that even value query string values (e.g., ":") are url encoded. This +makes the Query class match PHP's http_build_query function. However, if you +want to send requests over the wire using valid query string characters that do +not need to be encoded, then you can provide a string to Url::setQuery() and +pass true as the second argument to specify that the query string is a raw +string that should not be parsed or encoded (unless a call to getQuery() is +subsequently made, forcing the query-string to be converted into a Query +object). + +## 5.0.2 - 2014-10-30 + +* Added a trailing `\r\n` to multipart/form-data payloads. See + https://github.com/guzzle/guzzle/pull/871 +* Added a `GuzzleHttp\Pool::send()` convenience method to match the docs. +* Status codes are now returned as integers. See + https://github.com/guzzle/guzzle/issues/881 +* No longer overwriting an existing `application/x-www-form-urlencoded` header + when sending POST requests, allowing for customized headers. See + https://github.com/guzzle/guzzle/issues/877 +* Improved path URL serialization. + + * No longer double percent-encoding characters in the path or query string if + they are already encoded. + * Now properly encoding the supplied path to a URL object, instead of only + encoding ' ' and '?'. + * Note: This has been changed in 5.0.3 to now encode query string values by + default unless the `rawString` argument is provided when setting the query + string on a URL: Now allowing many more characters to be present in the + query string without being percent encoded. See http://tools.ietf.org/html/rfc3986#appendix-A + +## 5.0.1 - 2014-10-16 + +Bugfix release. + +* Fixed an issue where connection errors still returned response object in + error and end events event though the response is unusable. This has been + corrected so that a response is not returned in the `getResponse` method of + these events if the response did not complete. https://github.com/guzzle/guzzle/issues/867 +* Fixed an issue where transfer statistics were not being populated in the + RingBridge. https://github.com/guzzle/guzzle/issues/866 + +## 5.0.0 - 2014-10-12 + +Adding support for non-blocking responses and some minor API cleanup. + +### New Features + +* Added support for non-blocking responses based on `guzzlehttp/guzzle-ring`. +* Added a public API for creating a default HTTP adapter. +* Updated the redirect plugin to be non-blocking so that redirects are sent + concurrently. Other plugins like this can now be updated to be non-blocking. +* Added a "progress" event so that you can get upload and download progress + events. +* Added `GuzzleHttp\Pool` which implements FutureInterface and transfers + requests concurrently using a capped pool size as efficiently as possible. +* Added `hasListeners()` to EmitterInterface. +* Removed `GuzzleHttp\ClientInterface::sendAll` and marked + `GuzzleHttp\Client::sendAll` as deprecated (it's still there, just not the + recommended way). + +### Breaking changes + +The breaking changes in this release are relatively minor. The biggest thing to +look out for is that request and response objects no longer implement fluent +interfaces. + +* Removed the fluent interfaces (i.e., `return $this`) from requests, + responses, `GuzzleHttp\Collection`, `GuzzleHttp\Url`, + `GuzzleHttp\Query`, `GuzzleHttp\Post\PostBody`, and + `GuzzleHttp\Cookie\SetCookie`. This blog post provides a good outline of + why I did this: http://ocramius.github.io/blog/fluent-interfaces-are-evil/. + This also makes the Guzzle message interfaces compatible with the current + PSR-7 message proposal. +* Removed "functions.php", so that Guzzle is truly PSR-4 compliant. Except + for the HTTP request functions from function.php, these functions are now + implemented in `GuzzleHttp\Utils` using camelCase. `GuzzleHttp\json_decode` + moved to `GuzzleHttp\Utils::jsonDecode`. `GuzzleHttp\get_path` moved to + `GuzzleHttp\Utils::getPath`. `GuzzleHttp\set_path` moved to + `GuzzleHttp\Utils::setPath`. `GuzzleHttp\batch` should now be + `GuzzleHttp\Pool::batch`, which returns an `objectStorage`. Using functions.php + caused problems for many users: they aren't PSR-4 compliant, require an + explicit include, and needed an if-guard to ensure that the functions are not + declared multiple times. +* Rewrote adapter layer. + * Removing all classes from `GuzzleHttp\Adapter`, these are now + implemented as callables that are stored in `GuzzleHttp\Ring\Client`. + * Removed the concept of "parallel adapters". Sending requests serially or + concurrently is now handled using a single adapter. + * Moved `GuzzleHttp\Adapter\Transaction` to `GuzzleHttp\Transaction`. The + Transaction object now exposes the request, response, and client as public + properties. The getters and setters have been removed. +* Removed the "headers" event. This event was only useful for changing the + body a response once the headers of the response were known. You can implement + a similar behavior in a number of ways. One example might be to use a + FnStream that has access to the transaction being sent. For example, when the + first byte is written, you could check if the response headers match your + expectations, and if so, change the actual stream body that is being + written to. +* Removed the `asArray` parameter from + `GuzzleHttp\Message\MessageInterface::getHeader`. If you want to get a header + value as an array, then use the newly added `getHeaderAsArray()` method of + `MessageInterface`. This change makes the Guzzle interfaces compatible with + the PSR-7 interfaces. +* `GuzzleHttp\Message\MessageFactory` no longer allows subclasses to add + custom request options using double-dispatch (this was an implementation + detail). Instead, you should now provide an associative array to the + constructor which is a mapping of the request option name mapping to a + function that applies the option value to a request. +* Removed the concept of "throwImmediately" from exceptions and error events. + This control mechanism was used to stop a transfer of concurrent requests + from completing. This can now be handled by throwing the exception or by + cancelling a pool of requests or each outstanding future request individually. +* Updated to "GuzzleHttp\Streams" 3.0. + * `GuzzleHttp\Stream\StreamInterface::getContents()` no longer accepts a + `maxLen` parameter. This update makes the Guzzle streams project + compatible with the current PSR-7 proposal. + * `GuzzleHttp\Stream\Stream::__construct`, + `GuzzleHttp\Stream\Stream::factory`, and + `GuzzleHttp\Stream\Utils::create` no longer accept a size in the second + argument. They now accept an associative array of options, including the + "size" key and "metadata" key which can be used to provide custom metadata. + +## 4.2.2 - 2014-09-08 + +* Fixed a memory leak in the CurlAdapter when reusing cURL handles. +* No longer using `request_fulluri` in stream adapter proxies. +* Relative redirects are now based on the last response, not the first response. + +## 4.2.1 - 2014-08-19 + +* Ensuring that the StreamAdapter does not always add a Content-Type header +* Adding automated github releases with a phar and zip + +## 4.2.0 - 2014-08-17 + +* Now merging in default options using a case-insensitive comparison. + Closes https://github.com/guzzle/guzzle/issues/767 +* Added the ability to automatically decode `Content-Encoding` response bodies + using the `decode_content` request option. This is set to `true` by default + to decode the response body if it comes over the wire with a + `Content-Encoding`. Set this value to `false` to disable decoding the + response content, and pass a string to provide a request `Accept-Encoding` + header and turn on automatic response decoding. This feature now allows you + to pass an `Accept-Encoding` header in the headers of a request but still + disable automatic response decoding. + Closes https://github.com/guzzle/guzzle/issues/764 +* Added the ability to throw an exception immediately when transferring + requests in parallel. Closes https://github.com/guzzle/guzzle/issues/760 +* Updating guzzlehttp/streams dependency to ~2.1 +* No longer utilizing the now deprecated namespaced methods from the stream + package. + +## 4.1.8 - 2014-08-14 + +* Fixed an issue in the CurlFactory that caused setting the `stream=false` + request option to throw an exception. + See: https://github.com/guzzle/guzzle/issues/769 +* TransactionIterator now calls rewind on the inner iterator. + See: https://github.com/guzzle/guzzle/pull/765 +* You can now set the `Content-Type` header to `multipart/form-data` + when creating POST requests to force multipart bodies. + See https://github.com/guzzle/guzzle/issues/768 + +## 4.1.7 - 2014-08-07 + +* Fixed an error in the HistoryPlugin that caused the same request and response + to be logged multiple times when an HTTP protocol error occurs. +* Ensuring that cURL does not add a default Content-Type when no Content-Type + has been supplied by the user. This prevents the adapter layer from modifying + the request that is sent over the wire after any listeners may have already + put the request in a desired state (e.g., signed the request). +* Throwing an exception when you attempt to send requests that have the + "stream" set to true in parallel using the MultiAdapter. +* Only calling curl_multi_select when there are active cURL handles. This was + previously changed and caused performance problems on some systems due to PHP + always selecting until the maximum select timeout. +* Fixed a bug where multipart/form-data POST fields were not correctly + aggregated (e.g., values with "&"). + +## 4.1.6 - 2014-08-03 + +* Added helper methods to make it easier to represent messages as strings, + including getting the start line and getting headers as a string. + +## 4.1.5 - 2014-08-02 + +* Automatically retrying cURL "Connection died, retrying a fresh connect" + errors when possible. +* cURL implementation cleanup +* Allowing multiple event subscriber listeners to be registered per event by + passing an array of arrays of listener configuration. + +## 4.1.4 - 2014-07-22 + +* Fixed a bug that caused multi-part POST requests with more than one field to + serialize incorrectly. +* Paths can now be set to "0" +* `ResponseInterface::xml` now accepts a `libxml_options` option and added a + missing default argument that was required when parsing XML response bodies. +* A `save_to` stream is now created lazily, which means that files are not + created on disk unless a request succeeds. + +## 4.1.3 - 2014-07-15 + +* Various fixes to multipart/form-data POST uploads +* Wrapping function.php in an if-statement to ensure Guzzle can be used + globally and in a Composer install +* Fixed an issue with generating and merging in events to an event array +* POST headers are only applied before sending a request to allow you to change + the query aggregator used before uploading +* Added much more robust query string parsing +* Fixed various parsing and normalization issues with URLs +* Fixing an issue where multi-valued headers were not being utilized correctly + in the StreamAdapter + +## 4.1.2 - 2014-06-18 + +* Added support for sending payloads with GET requests + +## 4.1.1 - 2014-06-08 + +* Fixed an issue related to using custom message factory options in subclasses +* Fixed an issue with nested form fields in a multi-part POST +* Fixed an issue with using the `json` request option for POST requests +* Added `ToArrayInterface` to `GuzzleHttp\Cookie\CookieJar` + +## 4.1.0 - 2014-05-27 + +* Added a `json` request option to easily serialize JSON payloads. +* Added a `GuzzleHttp\json_decode()` wrapper to safely parse JSON. +* Added `setPort()` and `getPort()` to `GuzzleHttp\Message\RequestInterface`. +* Added the ability to provide an emitter to a client in the client constructor. +* Added the ability to persist a cookie session using $_SESSION. +* Added a trait that can be used to add event listeners to an iterator. +* Removed request method constants from RequestInterface. +* Fixed warning when invalid request start-lines are received. +* Updated MessageFactory to work with custom request option methods. +* Updated cacert bundle to latest build. + +4.0.2 (2014-04-16) +------------------ + +* Proxy requests using the StreamAdapter now properly use request_fulluri (#632) +* Added the ability to set scalars as POST fields (#628) + +## 4.0.1 - 2014-04-04 + +* The HTTP status code of a response is now set as the exception code of + RequestException objects. +* 303 redirects will now correctly switch from POST to GET requests. +* The default parallel adapter of a client now correctly uses the MultiAdapter. +* HasDataTrait now initializes the internal data array as an empty array so + that the toArray() method always returns an array. + +## 4.0.0 - 2014-03-29 + +* For more information on the 4.0 transition, see: + http://mtdowling.com/blog/2014/03/15/guzzle-4-rc/ +* For information on changes and upgrading, see: + https://github.com/guzzle/guzzle/blob/master/UPGRADING.md#3x-to-40 +* Added `GuzzleHttp\batch()` as a convenience function for sending requests in + parallel without needing to write asynchronous code. +* Restructured how events are added to `GuzzleHttp\ClientInterface::sendAll()`. + You can now pass a callable or an array of associative arrays where each + associative array contains the "fn", "priority", and "once" keys. + +## 4.0.0.rc-2 - 2014-03-25 + +* Removed `getConfig()` and `setConfig()` from clients to avoid confusion + around whether things like base_url, message_factory, etc. should be able to + be retrieved or modified. +* Added `getDefaultOption()` and `setDefaultOption()` to ClientInterface +* functions.php functions were renamed using snake_case to match PHP idioms +* Added support for `HTTP_PROXY`, `HTTPS_PROXY`, and + `GUZZLE_CURL_SELECT_TIMEOUT` environment variables +* Added the ability to specify custom `sendAll()` event priorities +* Added the ability to specify custom stream context options to the stream + adapter. +* Added a functions.php function for `get_path()` and `set_path()` +* CurlAdapter and MultiAdapter now use a callable to generate curl resources +* MockAdapter now properly reads a body and emits a `headers` event +* Updated Url class to check if a scheme and host are set before adding ":" + and "//". This allows empty Url (e.g., "") to be serialized as "". +* Parsing invalid XML no longer emits warnings +* Curl classes now properly throw AdapterExceptions +* Various performance optimizations +* Streams are created with the faster `Stream\create()` function +* Marked deprecation_proxy() as internal +* Test server is now a collection of static methods on a class + +## 4.0.0-rc.1 - 2014-03-15 + +* See https://github.com/guzzle/guzzle/blob/master/UPGRADING.md#3x-to-40 + +## 3.8.1 - 2014-01-28 + +* Bug: Always using GET requests when redirecting from a 303 response +* Bug: CURLOPT_SSL_VERIFYHOST is now correctly set to false when setting `$certificateAuthority` to false in + `Guzzle\Http\ClientInterface::setSslVerification()` +* Bug: RedirectPlugin now uses strict RFC 3986 compliance when combining a base URL with a relative URL +* Bug: The body of a request can now be set to `"0"` +* Sending PHP stream requests no longer forces `HTTP/1.0` +* Adding more information to ExceptionCollection exceptions so that users have more context, including a stack trace of + each sub-exception +* Updated the `$ref` attribute in service descriptions to merge over any existing parameters of a schema (rather than + clobbering everything). +* Merging URLs will now use the query string object from the relative URL (thus allowing custom query aggregators) +* Query strings are now parsed in a way that they do no convert empty keys with no value to have a dangling `=`. + For example `foo&bar=baz` is now correctly parsed and recognized as `foo&bar=baz` rather than `foo=&bar=baz`. +* Now properly escaping the regular expression delimiter when matching Cookie domains. +* Network access is now disabled when loading XML documents + +## 3.8.0 - 2013-12-05 + +* Added the ability to define a POST name for a file +* JSON response parsing now properly walks additionalProperties +* cURL error code 18 is now retried automatically in the BackoffPlugin +* Fixed a cURL error when URLs contain fragments +* Fixed an issue in the BackoffPlugin retry event where it was trying to access all exceptions as if they were + CurlExceptions +* CURLOPT_PROGRESS function fix for PHP 5.5 (69fcc1e) +* Added the ability for Guzzle to work with older versions of cURL that do not support `CURLOPT_TIMEOUT_MS` +* Fixed a bug that was encountered when parsing empty header parameters +* UriTemplate now has a `setRegex()` method to match the docs +* The `debug` request parameter now checks if it is truthy rather than if it exists +* Setting the `debug` request parameter to true shows verbose cURL output instead of using the LogPlugin +* Added the ability to combine URLs using strict RFC 3986 compliance +* Command objects can now return the validation errors encountered by the command +* Various fixes to cache revalidation (#437 and 29797e5) +* Various fixes to the AsyncPlugin +* Cleaned up build scripts + +## 3.7.4 - 2013-10-02 + +* Bug fix: 0 is now an allowed value in a description parameter that has a default value (#430) +* Bug fix: SchemaFormatter now returns an integer when formatting to a Unix timestamp + (see https://github.com/aws/aws-sdk-php/issues/147) +* Bug fix: Cleaned up and fixed URL dot segment removal to properly resolve internal dots +* Minimum PHP version is now properly specified as 5.3.3 (up from 5.3.2) (#420) +* Updated the bundled cacert.pem (#419) +* OauthPlugin now supports adding authentication to headers or query string (#425) + +## 3.7.3 - 2013-09-08 + +* Added the ability to get the exception associated with a request/command when using `MultiTransferException` and + `CommandTransferException`. +* Setting `additionalParameters` of a response to false is now honored when parsing responses with a service description +* Schemas are only injected into response models when explicitly configured. +* No longer guessing Content-Type based on the path of a request. Content-Type is now only guessed based on the path of + an EntityBody. +* Bug fix: ChunkedIterator can now properly chunk a \Traversable as well as an \Iterator. +* Bug fix: FilterIterator now relies on `\Iterator` instead of `\Traversable`. +* Bug fix: Gracefully handling malformed responses in RequestMediator::writeResponseBody() +* Bug fix: Replaced call to canCache with canCacheRequest in the CallbackCanCacheStrategy of the CachePlugin +* Bug fix: Visiting XML attributes first before visiting XML children when serializing requests +* Bug fix: Properly parsing headers that contain commas contained in quotes +* Bug fix: mimetype guessing based on a filename is now case-insensitive + +## 3.7.2 - 2013-08-02 + +* Bug fix: Properly URL encoding paths when using the PHP-only version of the UriTemplate expander + See https://github.com/guzzle/guzzle/issues/371 +* Bug fix: Cookie domains are now matched correctly according to RFC 6265 + See https://github.com/guzzle/guzzle/issues/377 +* Bug fix: GET parameters are now used when calculating an OAuth signature +* Bug fix: Fixed an issue with cache revalidation where the If-None-Match header was being double quoted +* `Guzzle\Common\AbstractHasDispatcher::dispatch()` now returns the event that was dispatched +* `Guzzle\Http\QueryString::factory()` now guesses the most appropriate query aggregator to used based on the input. + See https://github.com/guzzle/guzzle/issues/379 +* Added a way to add custom domain objects to service description parsing using the `operation.parse_class` event. See + https://github.com/guzzle/guzzle/pull/380 +* cURL multi cleanup and optimizations + +## 3.7.1 - 2013-07-05 + +* Bug fix: Setting default options on a client now works +* Bug fix: Setting options on HEAD requests now works. See #352 +* Bug fix: Moving stream factory before send event to before building the stream. See #353 +* Bug fix: Cookies no longer match on IP addresses per RFC 6265 +* Bug fix: Correctly parsing header parameters that are in `<>` and quotes +* Added `cert` and `ssl_key` as request options +* `Host` header can now diverge from the host part of a URL if the header is set manually +* `Guzzle\Service\Command\LocationVisitor\Request\XmlVisitor` was rewritten to change from using SimpleXML to XMLWriter +* OAuth parameters are only added via the plugin if they aren't already set +* Exceptions are now thrown when a URL cannot be parsed +* Returning `false` if `Guzzle\Http\EntityBody::getContentMd5()` fails +* Not setting a `Content-MD5` on a command if calculating the Content-MD5 fails via the CommandContentMd5Plugin + +## 3.7.0 - 2013-06-10 + +* See UPGRADING.md for more information on how to upgrade. +* Requests now support the ability to specify an array of $options when creating a request to more easily modify a + request. You can pass a 'request.options' configuration setting to a client to apply default request options to + every request created by a client (e.g. default query string variables, headers, curl options, etc.). +* Added a static facade class that allows you to use Guzzle with static methods and mount the class to `\Guzzle`. + See `Guzzle\Http\StaticClient::mount`. +* Added `command.request_options` to `Guzzle\Service\Command\AbstractCommand` to pass request options to requests + created by a command (e.g. custom headers, query string variables, timeout settings, etc.). +* Stream size in `Guzzle\Stream\PhpStreamRequestFactory` will now be set if Content-Length is returned in the + headers of a response +* Added `Guzzle\Common\Collection::setPath($path, $value)` to set a value into an array using a nested key + (e.g. `$collection->setPath('foo/baz/bar', 'test'); echo $collection['foo']['bar']['bar'];`) +* ServiceBuilders now support storing and retrieving arbitrary data +* CachePlugin can now purge all resources for a given URI +* CachePlugin can automatically purge matching cached items when a non-idempotent request is sent to a resource +* CachePlugin now uses the Vary header to determine if a resource is a cache hit +* `Guzzle\Http\Message\Response` now implements `\Serializable` +* Added `Guzzle\Cache\CacheAdapterFactory::fromCache()` to more easily create cache adapters +* `Guzzle\Service\ClientInterface::execute()` now accepts an array, single command, or Traversable +* Fixed a bug in `Guzzle\Http\Message\Header\Link::addLink()` +* Better handling of calculating the size of a stream in `Guzzle\Stream\Stream` using fstat() and caching the size +* `Guzzle\Common\Exception\ExceptionCollection` now creates a more readable exception message +* Fixing BC break: Added back the MonologLogAdapter implementation rather than extending from PsrLog so that older + Symfony users can still use the old version of Monolog. +* Fixing BC break: Added the implementation back in for `Guzzle\Http\Message\AbstractMessage::getTokenizedHeader()`. + Now triggering an E_USER_DEPRECATED warning when used. Use `$message->getHeader()->parseParams()`. +* Several performance improvements to `Guzzle\Common\Collection` +* Added an `$options` argument to the end of the following methods of `Guzzle\Http\ClientInterface`: + createRequest, head, delete, put, patch, post, options, prepareRequest +* Added an `$options` argument to the end of `Guzzle\Http\Message\Request\RequestFactoryInterface::createRequest()` +* Added an `applyOptions()` method to `Guzzle\Http\Message\Request\RequestFactoryInterface` +* Changed `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $body = null)` to + `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $options = array())`. You can still pass in a + resource, string, or EntityBody into the $options parameter to specify the download location of the response. +* Changed `Guzzle\Common\Collection::__construct($data)` to no longer accepts a null value for `$data` but a + default `array()` +* Added `Guzzle\Stream\StreamInterface::isRepeatable` +* Removed `Guzzle\Http\ClientInterface::setDefaultHeaders(). Use + $client->getConfig()->setPath('request.options/headers/{header_name}', 'value')`. or + $client->getConfig()->setPath('request.options/headers', array('header_name' => 'value'))`. +* Removed `Guzzle\Http\ClientInterface::getDefaultHeaders(). Use $client->getConfig()->getPath('request.options/headers')`. +* Removed `Guzzle\Http\ClientInterface::expandTemplate()` +* Removed `Guzzle\Http\ClientInterface::setRequestFactory()` +* Removed `Guzzle\Http\ClientInterface::getCurlMulti()` +* Removed `Guzzle\Http\Message\RequestInterface::canCache` +* Removed `Guzzle\Http\Message\RequestInterface::setIsRedirect` +* Removed `Guzzle\Http\Message\RequestInterface::isRedirect` +* Made `Guzzle\Http\Client::expandTemplate` and `getUriTemplate` protected methods. +* You can now enable E_USER_DEPRECATED warnings to see if you are using a deprecated method by setting + `Guzzle\Common\Version::$emitWarnings` to true. +* Marked `Guzzle\Http\Message\Request::isResponseBodyRepeatable()` as deprecated. Use + `$request->getResponseBody()->isRepeatable()` instead. +* Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use + `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead. +* Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use + `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead. +* Marked `Guzzle\Http\Message\Request::setIsRedirect()` as deprecated. Use the HistoryPlugin instead. +* Marked `Guzzle\Http\Message\Request::isRedirect()` as deprecated. Use the HistoryPlugin instead. +* Marked `Guzzle\Cache\CacheAdapterFactory::factory()` as deprecated +* Marked 'command.headers', 'command.response_body' and 'command.on_complete' as deprecated for AbstractCommand. + These will work through Guzzle 4.0 +* Marked 'request.params' for `Guzzle\Http\Client` as deprecated. Use [request.options][params]. +* Marked `Guzzle\Service\Client::enableMagicMethods()` as deprecated. Magic methods can no longer be disabled on a Guzzle\Service\Client. +* Marked `Guzzle\Service\Client::getDefaultHeaders()` as deprecated. Use $client->getConfig()->getPath('request.options/headers')`. +* Marked `Guzzle\Service\Client::setDefaultHeaders()` as deprecated. Use $client->getConfig()->setPath('request.options/headers/{header_name}', 'value')`. +* Marked `Guzzle\Parser\Url\UrlParser` as deprecated. Just use PHP's `parse_url()` and percent encode your UTF-8. +* Marked `Guzzle\Common\Collection::inject()` as deprecated. +* Marked `Guzzle\Plugin\CurlAuth\CurlAuthPlugin` as deprecated. Use `$client->getConfig()->setPath('request.options/auth', array('user', 'pass', 'Basic|Digest');` +* CacheKeyProviderInterface and DefaultCacheKeyProvider are no longer used. All of this logic is handled in a + CacheStorageInterface. These two objects and interface will be removed in a future version. +* Always setting X-cache headers on cached responses +* Default cache TTLs are now handled by the CacheStorageInterface of a CachePlugin +* `CacheStorageInterface::cache($key, Response $response, $ttl = null)` has changed to `cache(RequestInterface + $request, Response $response);` +* `CacheStorageInterface::fetch($key)` has changed to `fetch(RequestInterface $request);` +* `CacheStorageInterface::delete($key)` has changed to `delete(RequestInterface $request);` +* Added `CacheStorageInterface::purge($url)` +* `DefaultRevalidation::__construct(CacheKeyProviderInterface $cacheKey, CacheStorageInterface $cache, CachePlugin + $plugin)` has changed to `DefaultRevalidation::__construct(CacheStorageInterface $cache, + CanCacheStrategyInterface $canCache = null)` +* Added `RevalidationInterface::shouldRevalidate(RequestInterface $request, Response $response)` + +## 3.6.0 - 2013-05-29 + +* ServiceDescription now implements ToArrayInterface +* Added command.hidden_params to blacklist certain headers from being treated as additionalParameters +* Guzzle can now correctly parse incomplete URLs +* Mixed casing of headers are now forced to be a single consistent casing across all values for that header. +* Messages internally use a HeaderCollection object to delegate handling case-insensitive header resolution +* Removed the whole changedHeader() function system of messages because all header changes now go through addHeader(). +* Specific header implementations can be created for complex headers. When a message creates a header, it uses a + HeaderFactory which can map specific headers to specific header classes. There is now a Link header and + CacheControl header implementation. +* Removed from interface: Guzzle\Http\ClientInterface::setUriTemplate +* Removed from interface: Guzzle\Http\ClientInterface::setCurlMulti() +* Removed Guzzle\Http\Message\Request::receivedRequestHeader() and implemented this functionality in + Guzzle\Http\Curl\RequestMediator +* Removed the optional $asString parameter from MessageInterface::getHeader(). Just cast the header to a string. +* Removed the optional $tryChunkedTransfer option from Guzzle\Http\Message\EntityEnclosingRequestInterface +* Removed the $asObjects argument from Guzzle\Http\Message\MessageInterface::getHeaders() +* Removed Guzzle\Parser\ParserRegister::get(). Use getParser() +* Removed Guzzle\Parser\ParserRegister::set(). Use registerParser(). +* All response header helper functions return a string rather than mixing Header objects and strings inconsistently +* Removed cURL blacklist support. This is no longer necessary now that Expect, Accept, etc. are managed by Guzzle + directly via interfaces +* Removed the injecting of a request object onto a response object. The methods to get and set a request still exist + but are a no-op until removed. +* Most classes that used to require a `Guzzle\Service\Command\CommandInterface` typehint now request a + `Guzzle\Service\Command\ArrayCommandInterface`. +* Added `Guzzle\Http\Message\RequestInterface::startResponse()` to the RequestInterface to handle injecting a response + on a request while the request is still being transferred +* The ability to case-insensitively search for header values +* Guzzle\Http\Message\Header::hasExactHeader +* Guzzle\Http\Message\Header::raw. Use getAll() +* Deprecated cache control specific methods on Guzzle\Http\Message\AbstractMessage. Use the CacheControl header object + instead. +* `Guzzle\Service\Command\CommandInterface` now extends from ToArrayInterface and ArrayAccess +* Added the ability to cast Model objects to a string to view debug information. + +## 3.5.0 - 2013-05-13 + +* Bug: Fixed a regression so that request responses are parsed only once per oncomplete event rather than multiple times +* Bug: Better cleanup of one-time events across the board (when an event is meant to fire once, it will now remove + itself from the EventDispatcher) +* Bug: `Guzzle\Log\MessageFormatter` now properly writes "total_time" and "connect_time" values +* Bug: Cloning an EntityEnclosingRequest now clones the EntityBody too +* Bug: Fixed an undefined index error when parsing nested JSON responses with a sentAs parameter that reference a + non-existent key +* Bug: All __call() method arguments are now required (helps with mocking frameworks) +* Deprecating Response::getRequest() and now using a shallow clone of a request object to remove a circular reference + to help with refcount based garbage collection of resources created by sending a request +* Deprecating ZF1 cache and log adapters. These will be removed in the next major version. +* Deprecating `Response::getPreviousResponse()` (method signature still exists, but it's deprecated). Use the + HistoryPlugin for a history. +* Added a `responseBody` alias for the `response_body` location +* Refactored internals to no longer rely on Response::getRequest() +* HistoryPlugin can now be cast to a string +* HistoryPlugin now logs transactions rather than requests and responses to more accurately keep track of the requests + and responses that are sent over the wire +* Added `getEffectiveUrl()` and `getRedirectCount()` to Response objects + +## 3.4.3 - 2013-04-30 + +* Bug fix: Fixing bug introduced in 3.4.2 where redirect responses are duplicated on the final redirected response +* Added a check to re-extract the temp cacert bundle from the phar before sending each request + +## 3.4.2 - 2013-04-29 + +* Bug fix: Stream objects now work correctly with "a" and "a+" modes +* Bug fix: Removing `Transfer-Encoding: chunked` header when a Content-Length is present +* Bug fix: AsyncPlugin no longer forces HEAD requests +* Bug fix: DateTime timezones are now properly handled when using the service description schema formatter +* Bug fix: CachePlugin now properly handles stale-if-error directives when a request to the origin server fails +* Setting a response on a request will write to the custom request body from the response body if one is specified +* LogPlugin now writes to php://output when STDERR is undefined +* Added the ability to set multiple POST files for the same key in a single call +* application/x-www-form-urlencoded POSTs now use the utf-8 charset by default +* Added the ability to queue CurlExceptions to the MockPlugin +* Cleaned up how manual responses are queued on requests (removed "queued_response" and now using request.before_send) +* Configuration loading now allows remote files + +## 3.4.1 - 2013-04-16 + +* Large refactoring to how CurlMulti handles work. There is now a proxy that sits in front of a pool of CurlMulti + handles. This greatly simplifies the implementation, fixes a couple bugs, and provides a small performance boost. +* Exceptions are now properly grouped when sending requests in parallel +* Redirects are now properly aggregated when a multi transaction fails +* Redirects now set the response on the original object even in the event of a failure +* Bug fix: Model names are now properly set even when using $refs +* Added support for PHP 5.5's CurlFile to prevent warnings with the deprecated @ syntax +* Added support for oauth_callback in OAuth signatures +* Added support for oauth_verifier in OAuth signatures +* Added support to attempt to retrieve a command first literally, then ucfirst, the with inflection + +## 3.4.0 - 2013-04-11 + +* Bug fix: URLs are now resolved correctly based on http://tools.ietf.org/html/rfc3986#section-5.2. #289 +* Bug fix: Absolute URLs with a path in a service description will now properly override the base URL. #289 +* Bug fix: Parsing a query string with a single PHP array value will now result in an array. #263 +* Bug fix: Better normalization of the User-Agent header to prevent duplicate headers. #264. +* Bug fix: Added `number` type to service descriptions. +* Bug fix: empty parameters are removed from an OAuth signature +* Bug fix: Revalidating a cache entry prefers the Last-Modified over the Date header +* Bug fix: Fixed "array to string" error when validating a union of types in a service description +* Bug fix: Removed code that attempted to determine the size of a stream when data is written to the stream +* Bug fix: Not including an `oauth_token` if the value is null in the OauthPlugin. +* Bug fix: Now correctly aggregating successful requests and failed requests in CurlMulti when a redirect occurs. +* The new default CURLOPT_TIMEOUT setting has been increased to 150 seconds so that Guzzle works on poor connections. +* Added a feature to EntityEnclosingRequest::setBody() that will automatically set the Content-Type of the request if + the Content-Type can be determined based on the entity body or the path of the request. +* Added the ability to overwrite configuration settings in a client when grabbing a throwaway client from a builder. +* Added support for a PSR-3 LogAdapter. +* Added a `command.after_prepare` event +* Added `oauth_callback` parameter to the OauthPlugin +* Added the ability to create a custom stream class when using a stream factory +* Added a CachingEntityBody decorator +* Added support for `additionalParameters` in service descriptions to define how custom parameters are serialized. +* The bundled SSL certificate is now provided in the phar file and extracted when running Guzzle from a phar. +* You can now send any EntityEnclosingRequest with POST fields or POST files and cURL will handle creating bodies +* POST requests using a custom entity body are now treated exactly like PUT requests but with a custom cURL method. This + means that the redirect behavior of POST requests with custom bodies will not be the same as POST requests that use + POST fields or files (the latter is only used when emulating a form POST in the browser). +* Lots of cleanup to CurlHandle::factory and RequestFactory::createRequest + +## 3.3.1 - 2013-03-10 + +* Added the ability to create PHP streaming responses from HTTP requests +* Bug fix: Running any filters when parsing response headers with service descriptions +* Bug fix: OauthPlugin fixes to allow for multi-dimensional array signing, and sorting parameters before signing +* Bug fix: Removed the adding of default empty arrays and false Booleans to responses in order to be consistent across + response location visitors. +* Bug fix: Removed the possibility of creating configuration files with circular dependencies +* RequestFactory::create() now uses the key of a POST file when setting the POST file name +* Added xmlAllowEmpty to serialize an XML body even if no XML specific parameters are set + +## 3.3.0 - 2013-03-03 + +* A large number of performance optimizations have been made +* Bug fix: Added 'wb' as a valid write mode for streams +* Bug fix: `Guzzle\Http\Message\Response::json()` now allows scalar values to be returned +* Bug fix: Fixed bug in `Guzzle\Http\Message\Response` where wrapping quotes were stripped from `getEtag()` +* BC: Removed `Guzzle\Http\Utils` class +* BC: Setting a service description on a client will no longer modify the client's command factories. +* BC: Emitting IO events from a RequestMediator is now a parameter that must be set in a request's curl options using + the 'emit_io' key. This was previously set under a request's parameters using 'curl.emit_io' +* BC: `Guzzle\Stream\Stream::getWrapper()` and `Guzzle\Stream\Stream::getSteamType()` are no longer converted to + lowercase +* Operation parameter objects are now lazy loaded internally +* Added ErrorResponsePlugin that can throw errors for responses defined in service description operations' errorResponses +* Added support for instantiating responseType=class responseClass classes. Classes must implement + `Guzzle\Service\Command\ResponseClassInterface` +* Added support for additionalProperties for top-level parameters in responseType=model responseClasses. These + additional properties also support locations and can be used to parse JSON responses where the outermost part of the + JSON is an array +* Added support for nested renaming of JSON models (rename sentAs to name) +* CachePlugin + * Added support for stale-if-error so that the CachePlugin can now serve stale content from the cache on error + * Debug headers can now added to cached response in the CachePlugin + +## 3.2.0 - 2013-02-14 + +* CurlMulti is no longer reused globally. A new multi object is created per-client. This helps to isolate clients. +* URLs with no path no longer contain a "/" by default +* Guzzle\Http\QueryString does no longer manages the leading "?". This is now handled in Guzzle\Http\Url. +* BadResponseException no longer includes the full request and response message +* Adding setData() to Guzzle\Service\Description\ServiceDescriptionInterface +* Adding getResponseBody() to Guzzle\Http\Message\RequestInterface +* Various updates to classes to use ServiceDescriptionInterface type hints rather than ServiceDescription +* Header values can now be normalized into distinct values when multiple headers are combined with a comma separated list +* xmlEncoding can now be customized for the XML declaration of a XML service description operation +* Guzzle\Http\QueryString now uses Guzzle\Http\QueryAggregator\QueryAggregatorInterface objects to add custom value + aggregation and no longer uses callbacks +* The URL encoding implementation of Guzzle\Http\QueryString can now be customized +* Bug fix: Filters were not always invoked for array service description parameters +* Bug fix: Redirects now use a target response body rather than a temporary response body +* Bug fix: The default exponential backoff BackoffPlugin was not giving when the request threshold was exceeded +* Bug fix: Guzzle now takes the first found value when grabbing Cache-Control directives + +## 3.1.2 - 2013-01-27 + +* Refactored how operation responses are parsed. Visitors now include a before() method responsible for parsing the + response body. For example, the XmlVisitor now parses the XML response into an array in the before() method. +* Fixed an issue where cURL would not automatically decompress responses when the Accept-Encoding header was sent +* CURLOPT_SSL_VERIFYHOST is never set to 1 because it is deprecated (see 5e0ff2ef20f839e19d1eeb298f90ba3598784444) +* Fixed a bug where redirect responses were not chained correctly using getPreviousResponse() +* Setting default headers on a client after setting the user-agent will not erase the user-agent setting + +## 3.1.1 - 2013-01-20 + +* Adding wildcard support to Guzzle\Common\Collection::getPath() +* Adding alias support to ServiceBuilder configs +* Adding Guzzle\Service\Resource\CompositeResourceIteratorFactory and cleaning up factory interface + +## 3.1.0 - 2013-01-12 + +* BC: CurlException now extends from RequestException rather than BadResponseException +* BC: Renamed Guzzle\Plugin\Cache\CanCacheStrategyInterface::canCache() to canCacheRequest() and added CanCacheResponse() +* Added getData to ServiceDescriptionInterface +* Added context array to RequestInterface::setState() +* Bug: Removing hard dependency on the BackoffPlugin from Guzzle\Http +* Bug: Adding required content-type when JSON request visitor adds JSON to a command +* Bug: Fixing the serialization of a service description with custom data +* Made it easier to deal with exceptions thrown when transferring commands or requests in parallel by providing + an array of successful and failed responses +* Moved getPath from Guzzle\Service\Resource\Model to Guzzle\Common\Collection +* Added Guzzle\Http\IoEmittingEntityBody +* Moved command filtration from validators to location visitors +* Added `extends` attributes to service description parameters +* Added getModels to ServiceDescriptionInterface + +## 3.0.7 - 2012-12-19 + +* Fixing phar detection when forcing a cacert to system if null or true +* Allowing filename to be passed to `Guzzle\Http\Message\Request::setResponseBody()` +* Cleaning up `Guzzle\Common\Collection::inject` method +* Adding a response_body location to service descriptions + +## 3.0.6 - 2012-12-09 + +* CurlMulti performance improvements +* Adding setErrorResponses() to Operation +* composer.json tweaks + +## 3.0.5 - 2012-11-18 + +* Bug: Fixing an infinite recursion bug caused from revalidating with the CachePlugin +* Bug: Response body can now be a string containing "0" +* Bug: Using Guzzle inside of a phar uses system by default but now allows for a custom cacert +* Bug: QueryString::fromString now properly parses query string parameters that contain equal signs +* Added support for XML attributes in service description responses +* DefaultRequestSerializer now supports array URI parameter values for URI template expansion +* Added better mimetype guessing to requests and post files + +## 3.0.4 - 2012-11-11 + +* Bug: Fixed a bug when adding multiple cookies to a request to use the correct glue value +* Bug: Cookies can now be added that have a name, domain, or value set to "0" +* Bug: Using the system cacert bundle when using the Phar +* Added json and xml methods to Response to make it easier to parse JSON and XML response data into data structures +* Enhanced cookie jar de-duplication +* Added the ability to enable strict cookie jars that throw exceptions when invalid cookies are added +* Added setStream to StreamInterface to actually make it possible to implement custom rewind behavior for entity bodies +* Added the ability to create any sort of hash for a stream rather than just an MD5 hash + +## 3.0.3 - 2012-11-04 + +* Implementing redirects in PHP rather than cURL +* Added PECL URI template extension and using as default parser if available +* Bug: Fixed Content-Length parsing of Response factory +* Adding rewind() method to entity bodies and streams. Allows for custom rewinding of non-repeatable streams. +* Adding ToArrayInterface throughout library +* Fixing OauthPlugin to create unique nonce values per request + +## 3.0.2 - 2012-10-25 + +* Magic methods are enabled by default on clients +* Magic methods return the result of a command +* Service clients no longer require a base_url option in the factory +* Bug: Fixed an issue with URI templates where null template variables were being expanded + +## 3.0.1 - 2012-10-22 + +* Models can now be used like regular collection objects by calling filter, map, etc. +* Models no longer require a Parameter structure or initial data in the constructor +* Added a custom AppendIterator to get around a PHP bug with the `\AppendIterator` + +## 3.0.0 - 2012-10-15 + +* Rewrote service description format to be based on Swagger + * Now based on JSON schema + * Added nested input structures and nested response models + * Support for JSON and XML input and output models + * Renamed `commands` to `operations` + * Removed dot class notation + * Removed custom types +* Broke the project into smaller top-level namespaces to be more component friendly +* Removed support for XML configs and descriptions. Use arrays or JSON files. +* Removed the Validation component and Inspector +* Moved all cookie code to Guzzle\Plugin\Cookie +* Magic methods on a Guzzle\Service\Client now return the command un-executed. +* Calling getResult() or getResponse() on a command will lazily execute the command if needed. +* Now shipping with cURL's CA certs and using it by default +* Added previousResponse() method to response objects +* No longer sending Accept and Accept-Encoding headers on every request +* Only sending an Expect header by default when a payload is greater than 1MB +* Added/moved client options: + * curl.blacklist to curl.option.blacklist + * Added ssl.certificate_authority +* Added a Guzzle\Iterator component +* Moved plugins from Guzzle\Http\Plugin to Guzzle\Plugin +* Added a more robust backoff retry strategy (replaced the ExponentialBackoffPlugin) +* Added a more robust caching plugin +* Added setBody to response objects +* Updating LogPlugin to use a more flexible MessageFormatter +* Added a completely revamped build process +* Cleaning up Collection class and removing default values from the get method +* Fixed ZF2 cache adapters + +## 2.8.8 - 2012-10-15 + +* Bug: Fixed a cookie issue that caused dot prefixed domains to not match where popular browsers did + +## 2.8.7 - 2012-09-30 + +* Bug: Fixed config file aliases for JSON includes +* Bug: Fixed cookie bug on a request object by using CookieParser to parse cookies on requests +* Bug: Removing the path to a file when sending a Content-Disposition header on a POST upload +* Bug: Hardening request and response parsing to account for missing parts +* Bug: Fixed PEAR packaging +* Bug: Fixed Request::getInfo +* Bug: Fixed cases where CURLM_CALL_MULTI_PERFORM return codes were causing curl transactions to fail +* Adding the ability for the namespace Iterator factory to look in multiple directories +* Added more getters/setters/removers from service descriptions +* Added the ability to remove POST fields from OAuth signatures +* OAuth plugin now supports 2-legged OAuth + +## 2.8.6 - 2012-09-05 + +* Added the ability to modify and build service descriptions +* Added the use of visitors to apply parameters to locations in service descriptions using the dynamic command +* Added a `json` parameter location +* Now allowing dot notation for classes in the CacheAdapterFactory +* Using the union of two arrays rather than an array_merge when extending service builder services and service params +* Ensuring that a service is a string before doing strpos() checks on it when substituting services for references + in service builder config files. +* Services defined in two different config files that include one another will by default replace the previously + defined service, but you can now create services that extend themselves and merge their settings over the previous +* The JsonLoader now supports aliasing filenames with different filenames. This allows you to alias something like + '_default' with a default JSON configuration file. + +## 2.8.5 - 2012-08-29 + +* Bug: Suppressed empty arrays from URI templates +* Bug: Added the missing $options argument from ServiceDescription::factory to enable caching +* Added support for HTTP responses that do not contain a reason phrase in the start-line +* AbstractCommand commands are now invokable +* Added a way to get the data used when signing an Oauth request before a request is sent + +## 2.8.4 - 2012-08-15 + +* Bug: Custom delay time calculations are no longer ignored in the ExponentialBackoffPlugin +* Added the ability to transfer entity bodies as a string rather than streamed. This gets around curl error 65. Set `body_as_string` in a request's curl options to enable. +* Added a StreamInterface, EntityBodyInterface, and added ftell() to Guzzle\Common\Stream +* Added an AbstractEntityBodyDecorator and a ReadLimitEntityBody decorator to transfer only a subset of a decorated stream +* Stream and EntityBody objects will now return the file position to the previous position after a read required operation (e.g. getContentMd5()) +* Added additional response status codes +* Removed SSL information from the default User-Agent header +* DELETE requests can now send an entity body +* Added an EventDispatcher to the ExponentialBackoffPlugin and added an ExponentialBackoffLogger to log backoff retries +* Added the ability of the MockPlugin to consume mocked request bodies +* LogPlugin now exposes request and response objects in the extras array + +## 2.8.3 - 2012-07-30 + +* Bug: Fixed a case where empty POST requests were sent as GET requests +* Bug: Fixed a bug in ExponentialBackoffPlugin that caused fatal errors when retrying an EntityEnclosingRequest that does not have a body +* Bug: Setting the response body of a request to null after completing a request, not when setting the state of a request to new +* Added multiple inheritance to service description commands +* Added an ApiCommandInterface and added `getParamNames()` and `hasParam()` +* Removed the default 2mb size cutoff from the Md5ValidatorPlugin so that it now defaults to validating everything +* Changed CurlMulti::perform to pass a smaller timeout to CurlMulti::executeHandles + +## 2.8.2 - 2012-07-24 + +* Bug: Query string values set to 0 are no longer dropped from the query string +* Bug: A Collection object is no longer created each time a call is made to `Guzzle\Service\Command\AbstractCommand::getRequestHeaders()` +* Bug: `+` is now treated as an encoded space when parsing query strings +* QueryString and Collection performance improvements +* Allowing dot notation for class paths in filters attribute of a service descriptions + +## 2.8.1 - 2012-07-16 + +* Loosening Event Dispatcher dependency +* POST redirects can now be customized using CURLOPT_POSTREDIR + +## 2.8.0 - 2012-07-15 + +* BC: Guzzle\Http\Query + * Query strings with empty variables will always show an equal sign unless the variable is set to QueryString::BLANK (e.g. ?acl= vs ?acl) + * Changed isEncodingValues() and isEncodingFields() to isUrlEncoding() + * Changed setEncodeValues(bool) and setEncodeFields(bool) to useUrlEncoding(bool) + * Changed the aggregation functions of QueryString to be static methods + * Can now use fromString() with querystrings that have a leading ? +* cURL configuration values can be specified in service descriptions using `curl.` prefixed parameters +* Content-Length is set to 0 before emitting the request.before_send event when sending an empty request body +* Cookies are no longer URL decoded by default +* Bug: URI template variables set to null are no longer expanded + +## 2.7.2 - 2012-07-02 + +* BC: Moving things to get ready for subtree splits. Moving Inflection into Common. Moving Guzzle\Http\Parser to Guzzle\Parser. +* BC: Removing Guzzle\Common\Batch\Batch::count() and replacing it with isEmpty() +* CachePlugin now allows for a custom request parameter function to check if a request can be cached +* Bug fix: CachePlugin now only caches GET and HEAD requests by default +* Bug fix: Using header glue when transferring headers over the wire +* Allowing deeply nested arrays for composite variables in URI templates +* Batch divisors can now return iterators or arrays + +## 2.7.1 - 2012-06-26 + +* Minor patch to update version number in UA string +* Updating build process + +## 2.7.0 - 2012-06-25 + +* BC: Inflection classes moved to Guzzle\Inflection. No longer static methods. Can now inject custom inflectors into classes. +* BC: Removed magic setX methods from commands +* BC: Magic methods mapped to service description commands are now inflected in the command factory rather than the client __call() method +* Verbose cURL options are no longer enabled by default. Set curl.debug to true on a client to enable. +* Bug: Now allowing colons in a response start-line (e.g. HTTP/1.1 503 Service Unavailable: Back-end server is at capacity) +* Guzzle\Service\Resource\ResourceIteratorApplyBatched now internally uses the Guzzle\Common\Batch namespace +* Added Guzzle\Service\Plugin namespace and a PluginCollectionPlugin +* Added the ability to set POST fields and files in a service description +* Guzzle\Http\EntityBody::factory() now accepts objects with a __toString() method +* Adding a command.before_prepare event to clients +* Added BatchClosureTransfer and BatchClosureDivisor +* BatchTransferException now includes references to the batch divisor and transfer strategies +* Fixed some tests so that they pass more reliably +* Added Guzzle\Common\Log\ArrayLogAdapter + +## 2.6.6 - 2012-06-10 + +* BC: Removing Guzzle\Http\Plugin\BatchQueuePlugin +* BC: Removing Guzzle\Service\Command\CommandSet +* Adding generic batching system (replaces the batch queue plugin and command set) +* Updating ZF cache and log adapters and now using ZF's composer repository +* Bug: Setting the name of each ApiParam when creating through an ApiCommand +* Adding result_type, result_doc, deprecated, and doc_url to service descriptions +* Bug: Changed the default cookie header casing back to 'Cookie' + +## 2.6.5 - 2012-06-03 + +* BC: Renaming Guzzle\Http\Message\RequestInterface::getResourceUri() to getResource() +* BC: Removing unused AUTH_BASIC and AUTH_DIGEST constants from +* BC: Guzzle\Http\Cookie is now used to manage Set-Cookie data, not Cookie data +* BC: Renaming methods in the CookieJarInterface +* Moving almost all cookie logic out of the CookiePlugin and into the Cookie or CookieJar implementations +* Making the default glue for HTTP headers ';' instead of ',' +* Adding a removeValue to Guzzle\Http\Message\Header +* Adding getCookies() to request interface. +* Making it easier to add event subscribers to HasDispatcherInterface classes. Can now directly call addSubscriber() + +## 2.6.4 - 2012-05-30 + +* BC: Cleaning up how POST files are stored in EntityEnclosingRequest objects. Adding PostFile class. +* BC: Moving ApiCommand specific functionality from the Inspector and on to the ApiCommand +* Bug: Fixing magic method command calls on clients +* Bug: Email constraint only validates strings +* Bug: Aggregate POST fields when POST files are present in curl handle +* Bug: Fixing default User-Agent header +* Bug: Only appending or prepending parameters in commands if they are specified +* Bug: Not requiring response reason phrases or status codes to match a predefined list of codes +* Allowing the use of dot notation for class namespaces when using instance_of constraint +* Added any_match validation constraint +* Added an AsyncPlugin +* Passing request object to the calculateWait method of the ExponentialBackoffPlugin +* Allowing the result of a command object to be changed +* Parsing location and type sub values when instantiating a service description rather than over and over at runtime + +## 2.6.3 - 2012-05-23 + +* [BC] Guzzle\Common\FromConfigInterface no longer requires any config options. +* [BC] Refactoring how POST files are stored on an EntityEnclosingRequest. They are now separate from POST fields. +* You can now use an array of data when creating PUT request bodies in the request factory. +* Removing the requirement that HTTPS requests needed a Cache-Control: public directive to be cacheable. +* [Http] Adding support for Content-Type in multipart POST uploads per upload +* [Http] Added support for uploading multiple files using the same name (foo[0], foo[1]) +* Adding more POST data operations for easier manipulation of POST data. +* You can now set empty POST fields. +* The body of a request is only shown on EntityEnclosingRequest objects that do not use POST files. +* Split the Guzzle\Service\Inspector::validateConfig method into two methods. One to initialize when a command is created, and one to validate. +* CS updates + +## 2.6.2 - 2012-05-19 + +* [Http] Better handling of nested scope requests in CurlMulti. Requests are now always prepares in the send() method rather than the addRequest() method. + +## 2.6.1 - 2012-05-19 + +* [BC] Removing 'path' support in service descriptions. Use 'uri'. +* [BC] Guzzle\Service\Inspector::parseDocBlock is now protected. Adding getApiParamsForClass() with cache. +* [BC] Removing Guzzle\Common\NullObject. Use https://github.com/mtdowling/NullObject if you need it. +* [BC] Removing Guzzle\Common\XmlElement. +* All commands, both dynamic and concrete, have ApiCommand objects. +* Adding a fix for CurlMulti so that if all of the connections encounter some sort of curl error, then the loop exits. +* Adding checks to EntityEnclosingRequest so that empty POST files and fields are ignored. +* Making the method signature of Guzzle\Service\Builder\ServiceBuilder::factory more flexible. + +## 2.6.0 - 2012-05-15 + +* [BC] Moving Guzzle\Service\Builder to Guzzle\Service\Builder\ServiceBuilder +* [BC] Executing a Command returns the result of the command rather than the command +* [BC] Moving all HTTP parsing logic to Guzzle\Http\Parsers. Allows for faster C implementations if needed. +* [BC] Changing the Guzzle\Http\Message\Response::setProtocol() method to accept a protocol and version in separate args. +* [BC] Moving ResourceIterator* to Guzzle\Service\Resource +* [BC] Completely refactored ResourceIterators to iterate over a cloned command object +* [BC] Moved Guzzle\Http\UriTemplate to Guzzle\Http\Parser\UriTemplate\UriTemplate +* [BC] Guzzle\Guzzle is now deprecated +* Moving Guzzle\Common\Guzzle::inject to Guzzle\Common\Collection::inject +* Adding Guzzle\Version class to give version information about Guzzle +* Adding Guzzle\Http\Utils class to provide getDefaultUserAgent() and getHttpDate() +* Adding Guzzle\Curl\CurlVersion to manage caching curl_version() data +* ServiceDescription and ServiceBuilder are now cacheable using similar configs +* Changing the format of XML and JSON service builder configs. Backwards compatible. +* Cleaned up Cookie parsing +* Trimming the default Guzzle User-Agent header +* Adding a setOnComplete() method to Commands that is called when a command completes +* Keeping track of requests that were mocked in the MockPlugin +* Fixed a caching bug in the CacheAdapterFactory +* Inspector objects can be injected into a Command object +* Refactoring a lot of code and tests to be case insensitive when dealing with headers +* Adding Guzzle\Http\Message\HeaderComparison for easy comparison of HTTP headers using a DSL +* Adding the ability to set global option overrides to service builder configs +* Adding the ability to include other service builder config files from within XML and JSON files +* Moving the parseQuery method out of Url and on to QueryString::fromString() as a static factory method. + +## 2.5.0 - 2012-05-08 + +* Major performance improvements +* [BC] Simplifying Guzzle\Common\Collection. Please check to see if you are using features that are now deprecated. +* [BC] Using a custom validation system that allows a flyweight implementation for much faster validation. No longer using Symfony2 Validation component. +* [BC] No longer supporting "{{ }}" for injecting into command or UriTemplates. Use "{}" +* Added the ability to passed parameters to all requests created by a client +* Added callback functionality to the ExponentialBackoffPlugin +* Using microtime in ExponentialBackoffPlugin to allow more granular backoff strategies. +* Rewinding request stream bodies when retrying requests +* Exception is thrown when JSON response body cannot be decoded +* Added configurable magic method calls to clients and commands. This is off by default. +* Fixed a defect that added a hash to every parsed URL part +* Fixed duplicate none generation for OauthPlugin. +* Emitting an event each time a client is generated by a ServiceBuilder +* Using an ApiParams object instead of a Collection for parameters of an ApiCommand +* cache.* request parameters should be renamed to params.cache.* +* Added the ability to set arbitrary curl options on requests (disable_wire, progress, etc.). See CurlHandle. +* Added the ability to disable type validation of service descriptions +* ServiceDescriptions and ServiceBuilders are now Serializable diff --git a/vendor/guzzlehttp/guzzle/Dockerfile b/vendor/guzzlehttp/guzzle/Dockerfile index f6a095230..75712faa4 100644 --- a/vendor/guzzlehttp/guzzle/Dockerfile +++ b/vendor/guzzlehttp/guzzle/Dockerfile @@ -1,18 +1,18 @@ -FROM composer:latest as setup - -RUN mkdir /guzzle - -WORKDIR /guzzle - -RUN set -xe \ - && composer init --name=guzzlehttp/test --description="Simple project for testing Guzzle scripts" --author="Márk Sági-Kazár " --no-interaction \ - && composer require guzzlehttp/guzzle - - -FROM php:7.3 - -RUN mkdir /guzzle - -WORKDIR /guzzle - -COPY --from=setup /guzzle /guzzle +FROM composer:latest as setup + +RUN mkdir /guzzle + +WORKDIR /guzzle + +RUN set -xe \ + && composer init --name=guzzlehttp/test --description="Simple project for testing Guzzle scripts" --author="Márk Sági-Kazár " --no-interaction \ + && composer require guzzlehttp/guzzle + + +FROM php:7.3 + +RUN mkdir /guzzle + +WORKDIR /guzzle + +COPY --from=setup /guzzle /guzzle diff --git a/vendor/guzzlehttp/guzzle/LICENSE b/vendor/guzzlehttp/guzzle/LICENSE index 50a177b03..2073a73a1 100644 --- a/vendor/guzzlehttp/guzzle/LICENSE +++ b/vendor/guzzlehttp/guzzle/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2011-2018 Michael Dowling, https://github.com/mtdowling - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2011-2018 Michael Dowling, https://github.com/mtdowling + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/guzzlehttp/guzzle/README.md b/vendor/guzzlehttp/guzzle/README.md index 5fdb6c5f4..b8e9f8ec5 100644 --- a/vendor/guzzlehttp/guzzle/README.md +++ b/vendor/guzzlehttp/guzzle/README.md @@ -1,90 +1,90 @@ -Guzzle, PHP HTTP client -======================= - -[![Latest Version](https://img.shields.io/github/release/guzzle/guzzle.svg?style=flat-square)](https://github.com/guzzle/guzzle/releases) -[![Build Status](https://img.shields.io/travis/guzzle/guzzle.svg?style=flat-square)](https://travis-ci.org/guzzle/guzzle) -[![Total Downloads](https://img.shields.io/packagist/dt/guzzlehttp/guzzle.svg?style=flat-square)](https://packagist.org/packages/guzzlehttp/guzzle) - -Guzzle is a PHP HTTP client that makes it easy to send HTTP requests and -trivial to integrate with web services. - -- Simple interface for building query strings, POST requests, streaming large - uploads, streaming large downloads, using HTTP cookies, uploading JSON data, - etc... -- Can send both synchronous and asynchronous requests using the same interface. -- Uses PSR-7 interfaces for requests, responses, and streams. This allows you - to utilize other PSR-7 compatible libraries with Guzzle. -- Abstracts away the underlying HTTP transport, allowing you to write - environment and transport agnostic code; i.e., no hard dependency on cURL, - PHP streams, sockets, or non-blocking event loops. -- Middleware system allows you to augment and compose client behavior. - -```php -$client = new \GuzzleHttp\Client(); -$response = $client->request('GET', 'https://api.github.com/repos/guzzle/guzzle'); - -echo $response->getStatusCode(); # 200 -echo $response->getHeaderLine('content-type'); # 'application/json; charset=utf8' -echo $response->getBody(); # '{"id": 1420053, "name": "guzzle", ...}' - -# Send an asynchronous request. -$request = new \GuzzleHttp\Psr7\Request('GET', 'http://httpbin.org'); -$promise = $client->sendAsync($request)->then(function ($response) { - echo 'I completed! ' . $response->getBody(); -}); - -$promise->wait(); -``` - -## Help and docs - -- [Documentation](http://guzzlephp.org/) -- [Stack Overflow](http://stackoverflow.com/questions/tagged/guzzle) -- [Gitter](https://gitter.im/guzzle/guzzle) - - -## Installing Guzzle - -The recommended way to install Guzzle is through -[Composer](http://getcomposer.org). - -```bash -# Install Composer -curl -sS https://getcomposer.org/installer | php -``` - -Next, run the Composer command to install the latest stable version of Guzzle: - -```bash -composer require guzzlehttp/guzzle -``` - -After installing, you need to require Composer's autoloader: - -```php -require 'vendor/autoload.php'; -``` - -You can then later update Guzzle using composer: - - ```bash -composer update - ``` - - -## Version Guidance - -| Version | Status | Packagist | Namespace | Repo | Docs | PSR-7 | PHP Version | -|---------|------------|---------------------|--------------|---------------------|---------------------|-------|-------------| -| 3.x | EOL | `guzzle/guzzle` | `Guzzle` | [v3][guzzle-3-repo] | [v3][guzzle-3-docs] | No | >= 5.3.3 | -| 4.x | EOL | `guzzlehttp/guzzle` | `GuzzleHttp` | [v4][guzzle-4-repo] | N/A | No | >= 5.4 | -| 5.x | EOL | `guzzlehttp/guzzle` | `GuzzleHttp` | [v5][guzzle-5-repo] | [v5][guzzle-5-docs] | No | >= 5.4 | -| 6.x | Latest | `guzzlehttp/guzzle` | `GuzzleHttp` | [v6][guzzle-6-repo] | [v6][guzzle-6-docs] | Yes | >= 5.5 | - -[guzzle-3-repo]: https://github.com/guzzle/guzzle3 -[guzzle-4-repo]: https://github.com/guzzle/guzzle/tree/4.x -[guzzle-5-repo]: https://github.com/guzzle/guzzle/tree/5.3 -[guzzle-6-repo]: https://github.com/guzzle/guzzle -[guzzle-3-docs]: http://guzzle3.readthedocs.org -[guzzle-5-docs]: http://guzzle.readthedocs.org/en/5.3/ -[guzzle-6-docs]: http://guzzle.readthedocs.org/en/latest/ +Guzzle, PHP HTTP client +======================= + +[![Latest Version](https://img.shields.io/github/release/guzzle/guzzle.svg?style=flat-square)](https://github.com/guzzle/guzzle/releases) +[![Build Status](https://img.shields.io/travis/guzzle/guzzle.svg?style=flat-square)](https://travis-ci.org/guzzle/guzzle) +[![Total Downloads](https://img.shields.io/packagist/dt/guzzlehttp/guzzle.svg?style=flat-square)](https://packagist.org/packages/guzzlehttp/guzzle) + +Guzzle is a PHP HTTP client that makes it easy to send HTTP requests and +trivial to integrate with web services. + +- Simple interface for building query strings, POST requests, streaming large + uploads, streaming large downloads, using HTTP cookies, uploading JSON data, + etc... +- Can send both synchronous and asynchronous requests using the same interface. +- Uses PSR-7 interfaces for requests, responses, and streams. This allows you + to utilize other PSR-7 compatible libraries with Guzzle. +- Abstracts away the underlying HTTP transport, allowing you to write + environment and transport agnostic code; i.e., no hard dependency on cURL, + PHP streams, sockets, or non-blocking event loops. +- Middleware system allows you to augment and compose client behavior. + +```php +$client = new \GuzzleHttp\Client(); +$response = $client->request('GET', 'https://api.github.com/repos/guzzle/guzzle'); + +echo $response->getStatusCode(); # 200 +echo $response->getHeaderLine('content-type'); # 'application/json; charset=utf8' +echo $response->getBody(); # '{"id": 1420053, "name": "guzzle", ...}' + +# Send an asynchronous request. +$request = new \GuzzleHttp\Psr7\Request('GET', 'http://httpbin.org'); +$promise = $client->sendAsync($request)->then(function ($response) { + echo 'I completed! ' . $response->getBody(); +}); + +$promise->wait(); +``` + +## Help and docs + +- [Documentation](http://guzzlephp.org/) +- [Stack Overflow](http://stackoverflow.com/questions/tagged/guzzle) +- [Gitter](https://gitter.im/guzzle/guzzle) + + +## Installing Guzzle + +The recommended way to install Guzzle is through +[Composer](http://getcomposer.org). + +```bash +# Install Composer +curl -sS https://getcomposer.org/installer | php +``` + +Next, run the Composer command to install the latest stable version of Guzzle: + +```bash +composer require guzzlehttp/guzzle +``` + +After installing, you need to require Composer's autoloader: + +```php +require 'vendor/autoload.php'; +``` + +You can then later update Guzzle using composer: + + ```bash +composer update + ``` + + +## Version Guidance + +| Version | Status | Packagist | Namespace | Repo | Docs | PSR-7 | PHP Version | +|---------|------------|---------------------|--------------|---------------------|---------------------|-------|-------------| +| 3.x | EOL | `guzzle/guzzle` | `Guzzle` | [v3][guzzle-3-repo] | [v3][guzzle-3-docs] | No | >= 5.3.3 | +| 4.x | EOL | `guzzlehttp/guzzle` | `GuzzleHttp` | [v4][guzzle-4-repo] | N/A | No | >= 5.4 | +| 5.x | EOL | `guzzlehttp/guzzle` | `GuzzleHttp` | [v5][guzzle-5-repo] | [v5][guzzle-5-docs] | No | >= 5.4 | +| 6.x | Latest | `guzzlehttp/guzzle` | `GuzzleHttp` | [v6][guzzle-6-repo] | [v6][guzzle-6-docs] | Yes | >= 5.5 | + +[guzzle-3-repo]: https://github.com/guzzle/guzzle3 +[guzzle-4-repo]: https://github.com/guzzle/guzzle/tree/4.x +[guzzle-5-repo]: https://github.com/guzzle/guzzle/tree/5.3 +[guzzle-6-repo]: https://github.com/guzzle/guzzle +[guzzle-3-docs]: http://guzzle3.readthedocs.org +[guzzle-5-docs]: http://guzzle.readthedocs.org/en/5.3/ +[guzzle-6-docs]: http://guzzle.readthedocs.org/en/latest/ diff --git a/vendor/guzzlehttp/guzzle/UPGRADING.md b/vendor/guzzlehttp/guzzle/UPGRADING.md index 91d1dcc99..3636fc691 100644 --- a/vendor/guzzlehttp/guzzle/UPGRADING.md +++ b/vendor/guzzlehttp/guzzle/UPGRADING.md @@ -1,1203 +1,1203 @@ -Guzzle Upgrade Guide -==================== - -5.0 to 6.0 ----------- - -Guzzle now uses [PSR-7](http://www.php-fig.org/psr/psr-7/) for HTTP messages. -Due to the fact that these messages are immutable, this prompted a refactoring -of Guzzle to use a middleware based system rather than an event system. Any -HTTP message interaction (e.g., `GuzzleHttp\Message\Request`) need to be -updated to work with the new immutable PSR-7 request and response objects. Any -event listeners or subscribers need to be updated to become middleware -functions that wrap handlers (or are injected into a -`GuzzleHttp\HandlerStack`). - -- Removed `GuzzleHttp\BatchResults` -- Removed `GuzzleHttp\Collection` -- Removed `GuzzleHttp\HasDataTrait` -- Removed `GuzzleHttp\ToArrayInterface` -- The `guzzlehttp/streams` dependency has been removed. Stream functionality - is now present in the `GuzzleHttp\Psr7` namespace provided by the - `guzzlehttp/psr7` package. -- Guzzle no longer uses ReactPHP promises and now uses the - `guzzlehttp/promises` library. We use a custom promise library for three - significant reasons: - 1. React promises (at the time of writing this) are recursive. Promise - chaining and promise resolution will eventually blow the stack. Guzzle - promises are not recursive as they use a sort of trampolining technique. - Note: there has been movement in the React project to modify promises to - no longer utilize recursion. - 2. Guzzle needs to have the ability to synchronously block on a promise to - wait for a result. Guzzle promises allows this functionality (and does - not require the use of recursion). - 3. Because we need to be able to wait on a result, doing so using React - promises requires wrapping react promises with RingPHP futures. This - overhead is no longer needed, reducing stack sizes, reducing complexity, - and improving performance. -- `GuzzleHttp\Mimetypes` has been moved to a function in - `GuzzleHttp\Psr7\mimetype_from_extension` and - `GuzzleHttp\Psr7\mimetype_from_filename`. -- `GuzzleHttp\Query` and `GuzzleHttp\QueryParser` have been removed. Query - strings must now be passed into request objects as strings, or provided to - the `query` request option when creating requests with clients. The `query` - option uses PHP's `http_build_query` to convert an array to a string. If you - need a different serialization technique, you will need to pass the query - string in as a string. There are a couple helper functions that will make - working with query strings easier: `GuzzleHttp\Psr7\parse_query` and - `GuzzleHttp\Psr7\build_query`. -- Guzzle no longer has a dependency on RingPHP. Due to the use of a middleware - system based on PSR-7, using RingPHP and it's middleware system as well adds - more complexity than the benefits it provides. All HTTP handlers that were - present in RingPHP have been modified to work directly with PSR-7 messages - and placed in the `GuzzleHttp\Handler` namespace. This significantly reduces - complexity in Guzzle, removes a dependency, and improves performance. RingPHP - will be maintained for Guzzle 5 support, but will no longer be a part of - Guzzle 6. -- As Guzzle now uses a middleware based systems the event system and RingPHP - integration has been removed. Note: while the event system has been removed, - it is possible to add your own type of event system that is powered by the - middleware system. - - Removed the `Event` namespace. - - Removed the `Subscriber` namespace. - - Removed `Transaction` class - - Removed `RequestFsm` - - Removed `RingBridge` - - `GuzzleHttp\Subscriber\Cookie` is now provided by - `GuzzleHttp\Middleware::cookies` - - `GuzzleHttp\Subscriber\HttpError` is now provided by - `GuzzleHttp\Middleware::httpError` - - `GuzzleHttp\Subscriber\History` is now provided by - `GuzzleHttp\Middleware::history` - - `GuzzleHttp\Subscriber\Mock` is now provided by - `GuzzleHttp\Handler\MockHandler` - - `GuzzleHttp\Subscriber\Prepare` is now provided by - `GuzzleHttp\PrepareBodyMiddleware` - - `GuzzleHttp\Subscriber\Redirect` is now provided by - `GuzzleHttp\RedirectMiddleware` -- Guzzle now uses `Psr\Http\Message\UriInterface` (implements in - `GuzzleHttp\Psr7\Uri`) for URI support. `GuzzleHttp\Url` is now gone. -- Static functions in `GuzzleHttp\Utils` have been moved to namespaced - functions under the `GuzzleHttp` namespace. This requires either a Composer - based autoloader or you to include functions.php. -- `GuzzleHttp\ClientInterface::getDefaultOption` has been renamed to - `GuzzleHttp\ClientInterface::getConfig`. -- `GuzzleHttp\ClientInterface::setDefaultOption` has been removed. -- The `json` and `xml` methods of response objects has been removed. With the - migration to strictly adhering to PSR-7 as the interface for Guzzle messages, - adding methods to message interfaces would actually require Guzzle messages - to extend from PSR-7 messages rather then work with them directly. - -## Migrating to middleware - -The change to PSR-7 unfortunately required significant refactoring to Guzzle -due to the fact that PSR-7 messages are immutable. Guzzle 5 relied on an event -system from plugins. The event system relied on mutability of HTTP messages and -side effects in order to work. With immutable messages, you have to change your -workflow to become more about either returning a value (e.g., functional -middlewares) or setting a value on an object. Guzzle v6 has chosen the -functional middleware approach. - -Instead of using the event system to listen for things like the `before` event, -you now create a stack based middleware function that intercepts a request on -the way in and the promise of the response on the way out. This is a much -simpler and more predictable approach than the event system and works nicely -with PSR-7 middleware. Due to the use of promises, the middleware system is -also asynchronous. - -v5: - -```php -use GuzzleHttp\Event\BeforeEvent; -$client = new GuzzleHttp\Client(); -// Get the emitter and listen to the before event. -$client->getEmitter()->on('before', function (BeforeEvent $e) { - // Guzzle v5 events relied on mutation - $e->getRequest()->setHeader('X-Foo', 'Bar'); -}); -``` - -v6: - -In v6, you can modify the request before it is sent using the `mapRequest` -middleware. The idiomatic way in v6 to modify the request/response lifecycle is -to setup a handler middleware stack up front and inject the handler into a -client. - -```php -use GuzzleHttp\Middleware; -// Create a handler stack that has all of the default middlewares attached -$handler = GuzzleHttp\HandlerStack::create(); -// Push the handler onto the handler stack -$handler->push(Middleware::mapRequest(function (RequestInterface $request) { - // Notice that we have to return a request object - return $request->withHeader('X-Foo', 'Bar'); -})); -// Inject the handler into the client -$client = new GuzzleHttp\Client(['handler' => $handler]); -``` - -## POST Requests - -This version added the [`form_params`](http://guzzle.readthedocs.org/en/latest/request-options.html#form_params) -and `multipart` request options. `form_params` is an associative array of -strings or array of strings and is used to serialize an -`application/x-www-form-urlencoded` POST request. The -[`multipart`](http://guzzle.readthedocs.org/en/latest/request-options.html#multipart) -option is now used to send a multipart/form-data POST request. - -`GuzzleHttp\Post\PostFile` has been removed. Use the `multipart` option to add -POST files to a multipart/form-data request. - -The `body` option no longer accepts an array to send POST requests. Please use -`multipart` or `form_params` instead. - -The `base_url` option has been renamed to `base_uri`. - -4.x to 5.0 ----------- - -## Rewritten Adapter Layer - -Guzzle now uses [RingPHP](http://ringphp.readthedocs.org/en/latest) to send -HTTP requests. The `adapter` option in a `GuzzleHttp\Client` constructor -is still supported, but it has now been renamed to `handler`. Instead of -passing a `GuzzleHttp\Adapter\AdapterInterface`, you must now pass a PHP -`callable` that follows the RingPHP specification. - -## Removed Fluent Interfaces - -[Fluent interfaces were removed](http://ocramius.github.io/blog/fluent-interfaces-are-evil) -from the following classes: - -- `GuzzleHttp\Collection` -- `GuzzleHttp\Url` -- `GuzzleHttp\Query` -- `GuzzleHttp\Post\PostBody` -- `GuzzleHttp\Cookie\SetCookie` - -## Removed functions.php - -Removed "functions.php", so that Guzzle is truly PSR-4 compliant. The following -functions can be used as replacements. - -- `GuzzleHttp\json_decode` -> `GuzzleHttp\Utils::jsonDecode` -- `GuzzleHttp\get_path` -> `GuzzleHttp\Utils::getPath` -- `GuzzleHttp\Utils::setPath` -> `GuzzleHttp\set_path` -- `GuzzleHttp\Pool::batch` -> `GuzzleHttp\batch`. This function is, however, - deprecated in favor of using `GuzzleHttp\Pool::batch()`. - -The "procedural" global client has been removed with no replacement (e.g., -`GuzzleHttp\get()`, `GuzzleHttp\post()`, etc.). Use a `GuzzleHttp\Client` -object as a replacement. - -## `throwImmediately` has been removed - -The concept of "throwImmediately" has been removed from exceptions and error -events. This control mechanism was used to stop a transfer of concurrent -requests from completing. This can now be handled by throwing the exception or -by cancelling a pool of requests or each outstanding future request -individually. - -## headers event has been removed - -Removed the "headers" event. This event was only useful for changing the -body a response once the headers of the response were known. You can implement -a similar behavior in a number of ways. One example might be to use a -FnStream that has access to the transaction being sent. For example, when the -first byte is written, you could check if the response headers match your -expectations, and if so, change the actual stream body that is being -written to. - -## Updates to HTTP Messages - -Removed the `asArray` parameter from -`GuzzleHttp\Message\MessageInterface::getHeader`. If you want to get a header -value as an array, then use the newly added `getHeaderAsArray()` method of -`MessageInterface`. This change makes the Guzzle interfaces compatible with -the PSR-7 interfaces. - -3.x to 4.0 ----------- - -## Overarching changes: - -- Now requires PHP 5.4 or greater. -- No longer requires cURL to send requests. -- Guzzle no longer wraps every exception it throws. Only exceptions that are - recoverable are now wrapped by Guzzle. -- Various namespaces have been removed or renamed. -- No longer requiring the Symfony EventDispatcher. A custom event dispatcher - based on the Symfony EventDispatcher is - now utilized in `GuzzleHttp\Event\EmitterInterface` (resulting in significant - speed and functionality improvements). - -Changes per Guzzle 3.x namespace are described below. - -## Batch - -The `Guzzle\Batch` namespace has been removed. This is best left to -third-parties to implement on top of Guzzle's core HTTP library. - -## Cache - -The `Guzzle\Cache` namespace has been removed. (Todo: No suitable replacement -has been implemented yet, but hoping to utilize a PSR cache interface). - -## Common - -- Removed all of the wrapped exceptions. It's better to use the standard PHP - library for unrecoverable exceptions. -- `FromConfigInterface` has been removed. -- `Guzzle\Common\Version` has been removed. The VERSION constant can be found - at `GuzzleHttp\ClientInterface::VERSION`. - -### Collection - -- `getAll` has been removed. Use `toArray` to convert a collection to an array. -- `inject` has been removed. -- `keySearch` has been removed. -- `getPath` no longer supports wildcard expressions. Use something better like - JMESPath for this. -- `setPath` now supports appending to an existing array via the `[]` notation. - -### Events - -Guzzle no longer requires Symfony's EventDispatcher component. Guzzle now uses -`GuzzleHttp\Event\Emitter`. - -- `Symfony\Component\EventDispatcher\EventDispatcherInterface` is replaced by - `GuzzleHttp\Event\EmitterInterface`. -- `Symfony\Component\EventDispatcher\EventDispatcher` is replaced by - `GuzzleHttp\Event\Emitter`. -- `Symfony\Component\EventDispatcher\Event` is replaced by - `GuzzleHttp\Event\Event`, and Guzzle now has an EventInterface in - `GuzzleHttp\Event\EventInterface`. -- `AbstractHasDispatcher` has moved to a trait, `HasEmitterTrait`, and - `HasDispatcherInterface` has moved to `HasEmitterInterface`. Retrieving the - event emitter of a request, client, etc. now uses the `getEmitter` method - rather than the `getDispatcher` method. - -#### Emitter - -- Use the `once()` method to add a listener that automatically removes itself - the first time it is invoked. -- Use the `listeners()` method to retrieve a list of event listeners rather than - the `getListeners()` method. -- Use `emit()` instead of `dispatch()` to emit an event from an emitter. -- Use `attach()` instead of `addSubscriber()` and `detach()` instead of - `removeSubscriber()`. - -```php -$mock = new Mock(); -// 3.x -$request->getEventDispatcher()->addSubscriber($mock); -$request->getEventDispatcher()->removeSubscriber($mock); -// 4.x -$request->getEmitter()->attach($mock); -$request->getEmitter()->detach($mock); -``` - -Use the `on()` method to add a listener rather than the `addListener()` method. - -```php -// 3.x -$request->getEventDispatcher()->addListener('foo', function (Event $event) { /* ... */ } ); -// 4.x -$request->getEmitter()->on('foo', function (Event $event, $name) { /* ... */ } ); -``` - -## Http - -### General changes - -- The cacert.pem certificate has been moved to `src/cacert.pem`. -- Added the concept of adapters that are used to transfer requests over the - wire. -- Simplified the event system. -- Sending requests in parallel is still possible, but batching is no longer a - concept of the HTTP layer. Instead, you must use the `complete` and `error` - events to asynchronously manage parallel request transfers. -- `Guzzle\Http\Url` has moved to `GuzzleHttp\Url`. -- `Guzzle\Http\QueryString` has moved to `GuzzleHttp\Query`. -- QueryAggregators have been rewritten so that they are simply callable - functions. -- `GuzzleHttp\StaticClient` has been removed. Use the functions provided in - `functions.php` for an easy to use static client instance. -- Exceptions in `GuzzleHttp\Exception` have been updated to all extend from - `GuzzleHttp\Exception\TransferException`. - -### Client - -Calling methods like `get()`, `post()`, `head()`, etc. no longer create and -return a request, but rather creates a request, sends the request, and returns -the response. - -```php -// 3.0 -$request = $client->get('/'); -$response = $request->send(); - -// 4.0 -$response = $client->get('/'); - -// or, to mirror the previous behavior -$request = $client->createRequest('GET', '/'); -$response = $client->send($request); -``` - -`GuzzleHttp\ClientInterface` has changed. - -- The `send` method no longer accepts more than one request. Use `sendAll` to - send multiple requests in parallel. -- `setUserAgent()` has been removed. Use a default request option instead. You - could, for example, do something like: - `$client->setConfig('defaults/headers/User-Agent', 'Foo/Bar ' . $client::getDefaultUserAgent())`. -- `setSslVerification()` has been removed. Use default request options instead, - like `$client->setConfig('defaults/verify', true)`. - -`GuzzleHttp\Client` has changed. - -- The constructor now accepts only an associative array. You can include a - `base_url` string or array to use a URI template as the base URL of a client. - You can also specify a `defaults` key that is an associative array of default - request options. You can pass an `adapter` to use a custom adapter, - `batch_adapter` to use a custom adapter for sending requests in parallel, or - a `message_factory` to change the factory used to create HTTP requests and - responses. -- The client no longer emits a `client.create_request` event. -- Creating requests with a client no longer automatically utilize a URI - template. You must pass an array into a creational method (e.g., - `createRequest`, `get`, `put`, etc.) in order to expand a URI template. - -### Messages - -Messages no longer have references to their counterparts (i.e., a request no -longer has a reference to it's response, and a response no loger has a -reference to its request). This association is now managed through a -`GuzzleHttp\Adapter\TransactionInterface` object. You can get references to -these transaction objects using request events that are emitted over the -lifecycle of a request. - -#### Requests with a body - -- `GuzzleHttp\Message\EntityEnclosingRequest` and - `GuzzleHttp\Message\EntityEnclosingRequestInterface` have been removed. The - separation between requests that contain a body and requests that do not - contain a body has been removed, and now `GuzzleHttp\Message\RequestInterface` - handles both use cases. -- Any method that previously accepts a `GuzzleHttp\Response` object now accept a - `GuzzleHttp\Message\ResponseInterface`. -- `GuzzleHttp\Message\RequestFactoryInterface` has been renamed to - `GuzzleHttp\Message\MessageFactoryInterface`. This interface is used to create - both requests and responses and is implemented in - `GuzzleHttp\Message\MessageFactory`. -- POST field and file methods have been removed from the request object. You - must now use the methods made available to `GuzzleHttp\Post\PostBodyInterface` - to control the format of a POST body. Requests that are created using a - standard `GuzzleHttp\Message\MessageFactoryInterface` will automatically use - a `GuzzleHttp\Post\PostBody` body if the body was passed as an array or if - the method is POST and no body is provided. - -```php -$request = $client->createRequest('POST', '/'); -$request->getBody()->setField('foo', 'bar'); -$request->getBody()->addFile(new PostFile('file_key', fopen('/path/to/content', 'r'))); -``` - -#### Headers - -- `GuzzleHttp\Message\Header` has been removed. Header values are now simply - represented by an array of values or as a string. Header values are returned - as a string by default when retrieving a header value from a message. You can - pass an optional argument of `true` to retrieve a header value as an array - of strings instead of a single concatenated string. -- `GuzzleHttp\PostFile` and `GuzzleHttp\PostFileInterface` have been moved to - `GuzzleHttp\Post`. This interface has been simplified and now allows the - addition of arbitrary headers. -- Custom headers like `GuzzleHttp\Message\Header\Link` have been removed. Most - of the custom headers are now handled separately in specific - subscribers/plugins, and `GuzzleHttp\Message\HeaderValues::parseParams()` has - been updated to properly handle headers that contain parameters (like the - `Link` header). - -#### Responses - -- `GuzzleHttp\Message\Response::getInfo()` and - `GuzzleHttp\Message\Response::setInfo()` have been removed. Use the event - system to retrieve this type of information. -- `GuzzleHttp\Message\Response::getRawHeaders()` has been removed. -- `GuzzleHttp\Message\Response::getMessage()` has been removed. -- `GuzzleHttp\Message\Response::calculateAge()` and other cache specific - methods have moved to the CacheSubscriber. -- Header specific helper functions like `getContentMd5()` have been removed. - Just use `getHeader('Content-MD5')` instead. -- `GuzzleHttp\Message\Response::setRequest()` and - `GuzzleHttp\Message\Response::getRequest()` have been removed. Use the event - system to work with request and response objects as a transaction. -- `GuzzleHttp\Message\Response::getRedirectCount()` has been removed. Use the - Redirect subscriber instead. -- `GuzzleHttp\Message\Response::isSuccessful()` and other related methods have - been removed. Use `getStatusCode()` instead. - -#### Streaming responses - -Streaming requests can now be created by a client directly, returning a -`GuzzleHttp\Message\ResponseInterface` object that contains a body stream -referencing an open PHP HTTP stream. - -```php -// 3.0 -use Guzzle\Stream\PhpStreamRequestFactory; -$request = $client->get('/'); -$factory = new PhpStreamRequestFactory(); -$stream = $factory->fromRequest($request); -$data = $stream->read(1024); - -// 4.0 -$response = $client->get('/', ['stream' => true]); -// Read some data off of the stream in the response body -$data = $response->getBody()->read(1024); -``` - -#### Redirects - -The `configureRedirects()` method has been removed in favor of a -`allow_redirects` request option. - -```php -// Standard redirects with a default of a max of 5 redirects -$request = $client->createRequest('GET', '/', ['allow_redirects' => true]); - -// Strict redirects with a custom number of redirects -$request = $client->createRequest('GET', '/', [ - 'allow_redirects' => ['max' => 5, 'strict' => true] -]); -``` - -#### EntityBody - -EntityBody interfaces and classes have been removed or moved to -`GuzzleHttp\Stream`. All classes and interfaces that once required -`GuzzleHttp\EntityBodyInterface` now require -`GuzzleHttp\Stream\StreamInterface`. Creating a new body for a request no -longer uses `GuzzleHttp\EntityBody::factory` but now uses -`GuzzleHttp\Stream\Stream::factory` or even better: -`GuzzleHttp\Stream\create()`. - -- `Guzzle\Http\EntityBodyInterface` is now `GuzzleHttp\Stream\StreamInterface` -- `Guzzle\Http\EntityBody` is now `GuzzleHttp\Stream\Stream` -- `Guzzle\Http\CachingEntityBody` is now `GuzzleHttp\Stream\CachingStream` -- `Guzzle\Http\ReadLimitEntityBody` is now `GuzzleHttp\Stream\LimitStream` -- `Guzzle\Http\IoEmittyinEntityBody` has been removed. - -#### Request lifecycle events - -Requests previously submitted a large number of requests. The number of events -emitted over the lifecycle of a request has been significantly reduced to make -it easier to understand how to extend the behavior of a request. All events -emitted during the lifecycle of a request now emit a custom -`GuzzleHttp\Event\EventInterface` object that contains context providing -methods and a way in which to modify the transaction at that specific point in -time (e.g., intercept the request and set a response on the transaction). - -- `request.before_send` has been renamed to `before` and now emits a - `GuzzleHttp\Event\BeforeEvent` -- `request.complete` has been renamed to `complete` and now emits a - `GuzzleHttp\Event\CompleteEvent`. -- `request.sent` has been removed. Use `complete`. -- `request.success` has been removed. Use `complete`. -- `error` is now an event that emits a `GuzzleHttp\Event\ErrorEvent`. -- `request.exception` has been removed. Use `error`. -- `request.receive.status_line` has been removed. -- `curl.callback.progress` has been removed. Use a custom `StreamInterface` to - maintain a status update. -- `curl.callback.write` has been removed. Use a custom `StreamInterface` to - intercept writes. -- `curl.callback.read` has been removed. Use a custom `StreamInterface` to - intercept reads. - -`headers` is a new event that is emitted after the response headers of a -request have been received before the body of the response is downloaded. This -event emits a `GuzzleHttp\Event\HeadersEvent`. - -You can intercept a request and inject a response using the `intercept()` event -of a `GuzzleHttp\Event\BeforeEvent`, `GuzzleHttp\Event\CompleteEvent`, and -`GuzzleHttp\Event\ErrorEvent` event. - -See: http://docs.guzzlephp.org/en/latest/events.html - -## Inflection - -The `Guzzle\Inflection` namespace has been removed. This is not a core concern -of Guzzle. - -## Iterator - -The `Guzzle\Iterator` namespace has been removed. - -- `Guzzle\Iterator\AppendIterator`, `Guzzle\Iterator\ChunkedIterator`, and - `Guzzle\Iterator\MethodProxyIterator` are nice, but not a core requirement of - Guzzle itself. -- `Guzzle\Iterator\FilterIterator` is no longer needed because an equivalent - class is shipped with PHP 5.4. -- `Guzzle\Iterator\MapIterator` is not really needed when using PHP 5.5 because - it's easier to just wrap an iterator in a generator that maps values. - -For a replacement of these iterators, see https://github.com/nikic/iter - -## Log - -The LogPlugin has moved to https://github.com/guzzle/log-subscriber. The -`Guzzle\Log` namespace has been removed. Guzzle now relies on -`Psr\Log\LoggerInterface` for all logging. The MessageFormatter class has been -moved to `GuzzleHttp\Subscriber\Log\Formatter`. - -## Parser - -The `Guzzle\Parser` namespace has been removed. This was previously used to -make it possible to plug in custom parsers for cookies, messages, URI -templates, and URLs; however, this level of complexity is not needed in Guzzle -so it has been removed. - -- Cookie: Cookie parsing logic has been moved to - `GuzzleHttp\Cookie\SetCookie::fromString`. -- Message: Message parsing logic for both requests and responses has been moved - to `GuzzleHttp\Message\MessageFactory::fromMessage`. Message parsing is only - used in debugging or deserializing messages, so it doesn't make sense for - Guzzle as a library to add this level of complexity to parsing messages. -- UriTemplate: URI template parsing has been moved to - `GuzzleHttp\UriTemplate`. The Guzzle library will automatically use the PECL - URI template library if it is installed. -- Url: URL parsing is now performed in `GuzzleHttp\Url::fromString` (previously - it was `Guzzle\Http\Url::factory()`). If custom URL parsing is necessary, - then developers are free to subclass `GuzzleHttp\Url`. - -## Plugin - -The `Guzzle\Plugin` namespace has been renamed to `GuzzleHttp\Subscriber`. -Several plugins are shipping with the core Guzzle library under this namespace. - -- `GuzzleHttp\Subscriber\Cookie`: Replaces the old CookiePlugin. Cookie jar - code has moved to `GuzzleHttp\Cookie`. -- `GuzzleHttp\Subscriber\History`: Replaces the old HistoryPlugin. -- `GuzzleHttp\Subscriber\HttpError`: Throws errors when a bad HTTP response is - received. -- `GuzzleHttp\Subscriber\Mock`: Replaces the old MockPlugin. -- `GuzzleHttp\Subscriber\Prepare`: Prepares the body of a request just before - sending. This subscriber is attached to all requests by default. -- `GuzzleHttp\Subscriber\Redirect`: Replaces the RedirectPlugin. - -The following plugins have been removed (third-parties are free to re-implement -these if needed): - -- `GuzzleHttp\Plugin\Async` has been removed. -- `GuzzleHttp\Plugin\CurlAuth` has been removed. -- `GuzzleHttp\Plugin\ErrorResponse\ErrorResponsePlugin` has been removed. This - functionality should instead be implemented with event listeners that occur - after normal response parsing occurs in the guzzle/command package. - -The following plugins are not part of the core Guzzle package, but are provided -in separate repositories: - -- `Guzzle\Http\Plugin\BackoffPlugin` has been rewritten to be much simpler - to build custom retry policies using simple functions rather than various - chained classes. See: https://github.com/guzzle/retry-subscriber -- `Guzzle\Http\Plugin\Cache\CachePlugin` has moved to - https://github.com/guzzle/cache-subscriber -- `Guzzle\Http\Plugin\Log\LogPlugin` has moved to - https://github.com/guzzle/log-subscriber -- `Guzzle\Http\Plugin\Md5\Md5Plugin` has moved to - https://github.com/guzzle/message-integrity-subscriber -- `Guzzle\Http\Plugin\Mock\MockPlugin` has moved to - `GuzzleHttp\Subscriber\MockSubscriber`. -- `Guzzle\Http\Plugin\Oauth\OauthPlugin` has moved to - https://github.com/guzzle/oauth-subscriber - -## Service - -The service description layer of Guzzle has moved into two separate packages: - -- http://github.com/guzzle/command Provides a high level abstraction over web - services by representing web service operations using commands. -- http://github.com/guzzle/guzzle-services Provides an implementation of - guzzle/command that provides request serialization and response parsing using - Guzzle service descriptions. - -## Stream - -Stream have moved to a separate package available at -https://github.com/guzzle/streams. - -`Guzzle\Stream\StreamInterface` has been given a large update to cleanly take -on the responsibilities of `Guzzle\Http\EntityBody` and -`Guzzle\Http\EntityBodyInterface` now that they have been removed. The number -of methods implemented by the `StreamInterface` has been drastically reduced to -allow developers to more easily extend and decorate stream behavior. - -## Removed methods from StreamInterface - -- `getStream` and `setStream` have been removed to better encapsulate streams. -- `getMetadata` and `setMetadata` have been removed in favor of - `GuzzleHttp\Stream\MetadataStreamInterface`. -- `getWrapper`, `getWrapperData`, `getStreamType`, and `getUri` have all been - removed. This data is accessible when - using streams that implement `GuzzleHttp\Stream\MetadataStreamInterface`. -- `rewind` has been removed. Use `seek(0)` for a similar behavior. - -## Renamed methods - -- `detachStream` has been renamed to `detach`. -- `feof` has been renamed to `eof`. -- `ftell` has been renamed to `tell`. -- `readLine` has moved from an instance method to a static class method of - `GuzzleHttp\Stream\Stream`. - -## Metadata streams - -`GuzzleHttp\Stream\MetadataStreamInterface` has been added to denote streams -that contain additional metadata accessible via `getMetadata()`. -`GuzzleHttp\Stream\StreamInterface::getMetadata` and -`GuzzleHttp\Stream\StreamInterface::setMetadata` have been removed. - -## StreamRequestFactory - -The entire concept of the StreamRequestFactory has been removed. The way this -was used in Guzzle 3 broke the actual interface of sending streaming requests -(instead of getting back a Response, you got a StreamInterface). Streaming -PHP requests are now implemented through the `GuzzleHttp\Adapter\StreamAdapter`. - -3.6 to 3.7 ----------- - -### Deprecations - -- You can now enable E_USER_DEPRECATED warnings to see if you are using any deprecated methods.: - -```php -\Guzzle\Common\Version::$emitWarnings = true; -``` - -The following APIs and options have been marked as deprecated: - -- Marked `Guzzle\Http\Message\Request::isResponseBodyRepeatable()` as deprecated. Use `$request->getResponseBody()->isRepeatable()` instead. -- Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead. -- Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead. -- Marked `Guzzle\Http\Message\Request::setIsRedirect()` as deprecated. Use the HistoryPlugin instead. -- Marked `Guzzle\Http\Message\Request::isRedirect()` as deprecated. Use the HistoryPlugin instead. -- Marked `Guzzle\Cache\CacheAdapterFactory::factory()` as deprecated -- Marked `Guzzle\Service\Client::enableMagicMethods()` as deprecated. Magic methods can no longer be disabled on a Guzzle\Service\Client. -- Marked `Guzzle\Parser\Url\UrlParser` as deprecated. Just use PHP's `parse_url()` and percent encode your UTF-8. -- Marked `Guzzle\Common\Collection::inject()` as deprecated. -- Marked `Guzzle\Plugin\CurlAuth\CurlAuthPlugin` as deprecated. Use - `$client->getConfig()->setPath('request.options/auth', array('user', 'pass', 'Basic|Digest|NTLM|Any'));` or - `$client->setDefaultOption('auth', array('user', 'pass', 'Basic|Digest|NTLM|Any'));` - -3.7 introduces `request.options` as a parameter for a client configuration and as an optional argument to all creational -request methods. When paired with a client's configuration settings, these options allow you to specify default settings -for various aspects of a request. Because these options make other previous configuration options redundant, several -configuration options and methods of a client and AbstractCommand have been deprecated. - -- Marked `Guzzle\Service\Client::getDefaultHeaders()` as deprecated. Use `$client->getDefaultOption('headers')`. -- Marked `Guzzle\Service\Client::setDefaultHeaders()` as deprecated. Use `$client->setDefaultOption('headers/{header_name}', 'value')`. -- Marked 'request.params' for `Guzzle\Http\Client` as deprecated. Use `$client->setDefaultOption('params/{param_name}', 'value')` -- Marked 'command.headers', 'command.response_body' and 'command.on_complete' as deprecated for AbstractCommand. These will work through Guzzle 4.0 - - $command = $client->getCommand('foo', array( - 'command.headers' => array('Test' => '123'), - 'command.response_body' => '/path/to/file' - )); - - // Should be changed to: - - $command = $client->getCommand('foo', array( - 'command.request_options' => array( - 'headers' => array('Test' => '123'), - 'save_as' => '/path/to/file' - ) - )); - -### Interface changes - -Additions and changes (you will need to update any implementations or subclasses you may have created): - -- Added an `$options` argument to the end of the following methods of `Guzzle\Http\ClientInterface`: - createRequest, head, delete, put, patch, post, options, prepareRequest -- Added an `$options` argument to the end of `Guzzle\Http\Message\Request\RequestFactoryInterface::createRequest()` -- Added an `applyOptions()` method to `Guzzle\Http\Message\Request\RequestFactoryInterface` -- Changed `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $body = null)` to - `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $options = array())`. You can still pass in a - resource, string, or EntityBody into the $options parameter to specify the download location of the response. -- Changed `Guzzle\Common\Collection::__construct($data)` to no longer accepts a null value for `$data` but a - default `array()` -- Added `Guzzle\Stream\StreamInterface::isRepeatable` -- Made `Guzzle\Http\Client::expandTemplate` and `getUriTemplate` protected methods. - -The following methods were removed from interfaces. All of these methods are still available in the concrete classes -that implement them, but you should update your code to use alternative methods: - -- Removed `Guzzle\Http\ClientInterface::setDefaultHeaders(). Use - `$client->getConfig()->setPath('request.options/headers/{header_name}', 'value')`. or - `$client->getConfig()->setPath('request.options/headers', array('header_name' => 'value'))` or - `$client->setDefaultOption('headers/{header_name}', 'value')`. or - `$client->setDefaultOption('headers', array('header_name' => 'value'))`. -- Removed `Guzzle\Http\ClientInterface::getDefaultHeaders(). Use `$client->getConfig()->getPath('request.options/headers')`. -- Removed `Guzzle\Http\ClientInterface::expandTemplate()`. This is an implementation detail. -- Removed `Guzzle\Http\ClientInterface::setRequestFactory()`. This is an implementation detail. -- Removed `Guzzle\Http\ClientInterface::getCurlMulti()`. This is a very specific implementation detail. -- Removed `Guzzle\Http\Message\RequestInterface::canCache`. Use the CachePlugin. -- Removed `Guzzle\Http\Message\RequestInterface::setIsRedirect`. Use the HistoryPlugin. -- Removed `Guzzle\Http\Message\RequestInterface::isRedirect`. Use the HistoryPlugin. - -### Cache plugin breaking changes - -- CacheKeyProviderInterface and DefaultCacheKeyProvider are no longer used. All of this logic is handled in a - CacheStorageInterface. These two objects and interface will be removed in a future version. -- Always setting X-cache headers on cached responses -- Default cache TTLs are now handled by the CacheStorageInterface of a CachePlugin -- `CacheStorageInterface::cache($key, Response $response, $ttl = null)` has changed to `cache(RequestInterface - $request, Response $response);` -- `CacheStorageInterface::fetch($key)` has changed to `fetch(RequestInterface $request);` -- `CacheStorageInterface::delete($key)` has changed to `delete(RequestInterface $request);` -- Added `CacheStorageInterface::purge($url)` -- `DefaultRevalidation::__construct(CacheKeyProviderInterface $cacheKey, CacheStorageInterface $cache, CachePlugin - $plugin)` has changed to `DefaultRevalidation::__construct(CacheStorageInterface $cache, - CanCacheStrategyInterface $canCache = null)` -- Added `RevalidationInterface::shouldRevalidate(RequestInterface $request, Response $response)` - -3.5 to 3.6 ----------- - -* Mixed casing of headers are now forced to be a single consistent casing across all values for that header. -* Messages internally use a HeaderCollection object to delegate handling case-insensitive header resolution -* Removed the whole changedHeader() function system of messages because all header changes now go through addHeader(). - For example, setHeader() first removes the header using unset on a HeaderCollection and then calls addHeader(). - Keeping the Host header and URL host in sync is now handled by overriding the addHeader method in Request. -* Specific header implementations can be created for complex headers. When a message creates a header, it uses a - HeaderFactory which can map specific headers to specific header classes. There is now a Link header and - CacheControl header implementation. -* Moved getLinks() from Response to just be used on a Link header object. - -If you previously relied on Guzzle\Http\Message\Header::raw(), then you will need to update your code to use the -HeaderInterface (e.g. toArray(), getAll(), etc.). - -### Interface changes - -* Removed from interface: Guzzle\Http\ClientInterface::setUriTemplate -* Removed from interface: Guzzle\Http\ClientInterface::setCurlMulti() -* Removed Guzzle\Http\Message\Request::receivedRequestHeader() and implemented this functionality in - Guzzle\Http\Curl\RequestMediator -* Removed the optional $asString parameter from MessageInterface::getHeader(). Just cast the header to a string. -* Removed the optional $tryChunkedTransfer option from Guzzle\Http\Message\EntityEnclosingRequestInterface -* Removed the $asObjects argument from Guzzle\Http\Message\MessageInterface::getHeaders() - -### Removed deprecated functions - -* Removed Guzzle\Parser\ParserRegister::get(). Use getParser() -* Removed Guzzle\Parser\ParserRegister::set(). Use registerParser(). - -### Deprecations - -* The ability to case-insensitively search for header values -* Guzzle\Http\Message\Header::hasExactHeader -* Guzzle\Http\Message\Header::raw. Use getAll() -* Deprecated cache control specific methods on Guzzle\Http\Message\AbstractMessage. Use the CacheControl header object - instead. - -### Other changes - -* All response header helper functions return a string rather than mixing Header objects and strings inconsistently -* Removed cURL blacklist support. This is no longer necessary now that Expect, Accept, etc. are managed by Guzzle - directly via interfaces -* Removed the injecting of a request object onto a response object. The methods to get and set a request still exist - but are a no-op until removed. -* Most classes that used to require a `Guzzle\Service\Command\CommandInterface` typehint now request a - `Guzzle\Service\Command\ArrayCommandInterface`. -* Added `Guzzle\Http\Message\RequestInterface::startResponse()` to the RequestInterface to handle injecting a response - on a request while the request is still being transferred -* `Guzzle\Service\Command\CommandInterface` now extends from ToArrayInterface and ArrayAccess - -3.3 to 3.4 ----------- - -Base URLs of a client now follow the rules of http://tools.ietf.org/html/rfc3986#section-5.2.2 when merging URLs. - -3.2 to 3.3 ----------- - -### Response::getEtag() quote stripping removed - -`Guzzle\Http\Message\Response::getEtag()` no longer strips quotes around the ETag response header - -### Removed `Guzzle\Http\Utils` - -The `Guzzle\Http\Utils` class was removed. This class was only used for testing. - -### Stream wrapper and type - -`Guzzle\Stream\Stream::getWrapper()` and `Guzzle\Stream\Stream::getStreamType()` are no longer converted to lowercase. - -### curl.emit_io became emit_io - -Emitting IO events from a RequestMediator is now a parameter that must be set in a request's curl options using the -'emit_io' key. This was previously set under a request's parameters using 'curl.emit_io' - -3.1 to 3.2 ----------- - -### CurlMulti is no longer reused globally - -Before 3.2, the same CurlMulti object was reused globally for each client. This can cause issue where plugins added -to a single client can pollute requests dispatched from other clients. - -If you still wish to reuse the same CurlMulti object with each client, then you can add a listener to the -ServiceBuilder's `service_builder.create_client` event to inject a custom CurlMulti object into each client as it is -created. - -```php -$multi = new Guzzle\Http\Curl\CurlMulti(); -$builder = Guzzle\Service\Builder\ServiceBuilder::factory('/path/to/config.json'); -$builder->addListener('service_builder.create_client', function ($event) use ($multi) { - $event['client']->setCurlMulti($multi); -} -}); -``` - -### No default path - -URLs no longer have a default path value of '/' if no path was specified. - -Before: - -```php -$request = $client->get('http://www.foo.com'); -echo $request->getUrl(); -// >> http://www.foo.com/ -``` - -After: - -```php -$request = $client->get('http://www.foo.com'); -echo $request->getUrl(); -// >> http://www.foo.com -``` - -### Less verbose BadResponseException - -The exception message for `Guzzle\Http\Exception\BadResponseException` no longer contains the full HTTP request and -response information. You can, however, get access to the request and response object by calling `getRequest()` or -`getResponse()` on the exception object. - -### Query parameter aggregation - -Multi-valued query parameters are no longer aggregated using a callback function. `Guzzle\Http\Query` now has a -setAggregator() method that accepts a `Guzzle\Http\QueryAggregator\QueryAggregatorInterface` object. This object is -responsible for handling the aggregation of multi-valued query string variables into a flattened hash. - -2.8 to 3.x ----------- - -### Guzzle\Service\Inspector - -Change `\Guzzle\Service\Inspector::fromConfig` to `\Guzzle\Common\Collection::fromConfig` - -**Before** - -```php -use Guzzle\Service\Inspector; - -class YourClient extends \Guzzle\Service\Client -{ - public static function factory($config = array()) - { - $default = array(); - $required = array('base_url', 'username', 'api_key'); - $config = Inspector::fromConfig($config, $default, $required); - - $client = new self( - $config->get('base_url'), - $config->get('username'), - $config->get('api_key') - ); - $client->setConfig($config); - - $client->setDescription(ServiceDescription::factory(__DIR__ . DIRECTORY_SEPARATOR . 'client.json')); - - return $client; - } -``` - -**After** - -```php -use Guzzle\Common\Collection; - -class YourClient extends \Guzzle\Service\Client -{ - public static function factory($config = array()) - { - $default = array(); - $required = array('base_url', 'username', 'api_key'); - $config = Collection::fromConfig($config, $default, $required); - - $client = new self( - $config->get('base_url'), - $config->get('username'), - $config->get('api_key') - ); - $client->setConfig($config); - - $client->setDescription(ServiceDescription::factory(__DIR__ . DIRECTORY_SEPARATOR . 'client.json')); - - return $client; - } -``` - -### Convert XML Service Descriptions to JSON - -**Before** - -```xml - - - - - - Get a list of groups - - - Uses a search query to get a list of groups - - - - Create a group - - - - - Delete a group by ID - - - - - - - Update a group - - - - - - -``` - -**After** - -```json -{ - "name": "Zendesk REST API v2", - "apiVersion": "2012-12-31", - "description":"Provides access to Zendesk views, groups, tickets, ticket fields, and users", - "operations": { - "list_groups": { - "httpMethod":"GET", - "uri": "groups.json", - "summary": "Get a list of groups" - }, - "search_groups":{ - "httpMethod":"GET", - "uri": "search.json?query=\"{query} type:group\"", - "summary": "Uses a search query to get a list of groups", - "parameters":{ - "query":{ - "location": "uri", - "description":"Zendesk Search Query", - "type": "string", - "required": true - } - } - }, - "create_group": { - "httpMethod":"POST", - "uri": "groups.json", - "summary": "Create a group", - "parameters":{ - "data": { - "type": "array", - "location": "body", - "description":"Group JSON", - "filters": "json_encode", - "required": true - }, - "Content-Type":{ - "type": "string", - "location":"header", - "static": "application/json" - } - } - }, - "delete_group": { - "httpMethod":"DELETE", - "uri": "groups/{id}.json", - "summary": "Delete a group", - "parameters":{ - "id":{ - "location": "uri", - "description":"Group to delete by ID", - "type": "integer", - "required": true - } - } - }, - "get_group": { - "httpMethod":"GET", - "uri": "groups/{id}.json", - "summary": "Get a ticket", - "parameters":{ - "id":{ - "location": "uri", - "description":"Group to get by ID", - "type": "integer", - "required": true - } - } - }, - "update_group": { - "httpMethod":"PUT", - "uri": "groups/{id}.json", - "summary": "Update a group", - "parameters":{ - "id": { - "location": "uri", - "description":"Group to update by ID", - "type": "integer", - "required": true - }, - "data": { - "type": "array", - "location": "body", - "description":"Group JSON", - "filters": "json_encode", - "required": true - }, - "Content-Type":{ - "type": "string", - "location":"header", - "static": "application/json" - } - } - } -} -``` - -### Guzzle\Service\Description\ServiceDescription - -Commands are now called Operations - -**Before** - -```php -use Guzzle\Service\Description\ServiceDescription; - -$sd = new ServiceDescription(); -$sd->getCommands(); // @returns ApiCommandInterface[] -$sd->hasCommand($name); -$sd->getCommand($name); // @returns ApiCommandInterface|null -$sd->addCommand($command); // @param ApiCommandInterface $command -``` - -**After** - -```php -use Guzzle\Service\Description\ServiceDescription; - -$sd = new ServiceDescription(); -$sd->getOperations(); // @returns OperationInterface[] -$sd->hasOperation($name); -$sd->getOperation($name); // @returns OperationInterface|null -$sd->addOperation($operation); // @param OperationInterface $operation -``` - -### Guzzle\Common\Inflection\Inflector - -Namespace is now `Guzzle\Inflection\Inflector` - -### Guzzle\Http\Plugin - -Namespace is now `Guzzle\Plugin`. Many other changes occur within this namespace and are detailed in their own sections below. - -### Guzzle\Http\Plugin\LogPlugin and Guzzle\Common\Log - -Now `Guzzle\Plugin\Log\LogPlugin` and `Guzzle\Log` respectively. - -**Before** - -```php -use Guzzle\Common\Log\ClosureLogAdapter; -use Guzzle\Http\Plugin\LogPlugin; - -/** @var \Guzzle\Http\Client */ -$client; - -// $verbosity is an integer indicating desired message verbosity level -$client->addSubscriber(new LogPlugin(new ClosureLogAdapter(function($m) { echo $m; }, $verbosity = LogPlugin::LOG_VERBOSE); -``` - -**After** - -```php -use Guzzle\Log\ClosureLogAdapter; -use Guzzle\Log\MessageFormatter; -use Guzzle\Plugin\Log\LogPlugin; - -/** @var \Guzzle\Http\Client */ -$client; - -// $format is a string indicating desired message format -- @see MessageFormatter -$client->addSubscriber(new LogPlugin(new ClosureLogAdapter(function($m) { echo $m; }, $format = MessageFormatter::DEBUG_FORMAT); -``` - -### Guzzle\Http\Plugin\CurlAuthPlugin - -Now `Guzzle\Plugin\CurlAuth\CurlAuthPlugin`. - -### Guzzle\Http\Plugin\ExponentialBackoffPlugin - -Now `Guzzle\Plugin\Backoff\BackoffPlugin`, and other changes. - -**Before** - -```php -use Guzzle\Http\Plugin\ExponentialBackoffPlugin; - -$backoffPlugin = new ExponentialBackoffPlugin($maxRetries, array_merge( - ExponentialBackoffPlugin::getDefaultFailureCodes(), array(429) - )); - -$client->addSubscriber($backoffPlugin); -``` - -**After** - -```php -use Guzzle\Plugin\Backoff\BackoffPlugin; -use Guzzle\Plugin\Backoff\HttpBackoffStrategy; - -// Use convenient factory method instead -- see implementation for ideas of what -// you can do with chaining backoff strategies -$backoffPlugin = BackoffPlugin::getExponentialBackoff($maxRetries, array_merge( - HttpBackoffStrategy::getDefaultFailureCodes(), array(429) - )); -$client->addSubscriber($backoffPlugin); -``` - -### Known Issues - -#### [BUG] Accept-Encoding header behavior changed unintentionally. - -(See #217) (Fixed in 09daeb8c666fb44499a0646d655a8ae36456575e) - -In version 2.8 setting the `Accept-Encoding` header would set the CURLOPT_ENCODING option, which permitted cURL to -properly handle gzip/deflate compressed responses from the server. In versions affected by this bug this does not happen. -See issue #217 for a workaround, or use a version containing the fix. +Guzzle Upgrade Guide +==================== + +5.0 to 6.0 +---------- + +Guzzle now uses [PSR-7](http://www.php-fig.org/psr/psr-7/) for HTTP messages. +Due to the fact that these messages are immutable, this prompted a refactoring +of Guzzle to use a middleware based system rather than an event system. Any +HTTP message interaction (e.g., `GuzzleHttp\Message\Request`) need to be +updated to work with the new immutable PSR-7 request and response objects. Any +event listeners or subscribers need to be updated to become middleware +functions that wrap handlers (or are injected into a +`GuzzleHttp\HandlerStack`). + +- Removed `GuzzleHttp\BatchResults` +- Removed `GuzzleHttp\Collection` +- Removed `GuzzleHttp\HasDataTrait` +- Removed `GuzzleHttp\ToArrayInterface` +- The `guzzlehttp/streams` dependency has been removed. Stream functionality + is now present in the `GuzzleHttp\Psr7` namespace provided by the + `guzzlehttp/psr7` package. +- Guzzle no longer uses ReactPHP promises and now uses the + `guzzlehttp/promises` library. We use a custom promise library for three + significant reasons: + 1. React promises (at the time of writing this) are recursive. Promise + chaining and promise resolution will eventually blow the stack. Guzzle + promises are not recursive as they use a sort of trampolining technique. + Note: there has been movement in the React project to modify promises to + no longer utilize recursion. + 2. Guzzle needs to have the ability to synchronously block on a promise to + wait for a result. Guzzle promises allows this functionality (and does + not require the use of recursion). + 3. Because we need to be able to wait on a result, doing so using React + promises requires wrapping react promises with RingPHP futures. This + overhead is no longer needed, reducing stack sizes, reducing complexity, + and improving performance. +- `GuzzleHttp\Mimetypes` has been moved to a function in + `GuzzleHttp\Psr7\mimetype_from_extension` and + `GuzzleHttp\Psr7\mimetype_from_filename`. +- `GuzzleHttp\Query` and `GuzzleHttp\QueryParser` have been removed. Query + strings must now be passed into request objects as strings, or provided to + the `query` request option when creating requests with clients. The `query` + option uses PHP's `http_build_query` to convert an array to a string. If you + need a different serialization technique, you will need to pass the query + string in as a string. There are a couple helper functions that will make + working with query strings easier: `GuzzleHttp\Psr7\parse_query` and + `GuzzleHttp\Psr7\build_query`. +- Guzzle no longer has a dependency on RingPHP. Due to the use of a middleware + system based on PSR-7, using RingPHP and it's middleware system as well adds + more complexity than the benefits it provides. All HTTP handlers that were + present in RingPHP have been modified to work directly with PSR-7 messages + and placed in the `GuzzleHttp\Handler` namespace. This significantly reduces + complexity in Guzzle, removes a dependency, and improves performance. RingPHP + will be maintained for Guzzle 5 support, but will no longer be a part of + Guzzle 6. +- As Guzzle now uses a middleware based systems the event system and RingPHP + integration has been removed. Note: while the event system has been removed, + it is possible to add your own type of event system that is powered by the + middleware system. + - Removed the `Event` namespace. + - Removed the `Subscriber` namespace. + - Removed `Transaction` class + - Removed `RequestFsm` + - Removed `RingBridge` + - `GuzzleHttp\Subscriber\Cookie` is now provided by + `GuzzleHttp\Middleware::cookies` + - `GuzzleHttp\Subscriber\HttpError` is now provided by + `GuzzleHttp\Middleware::httpError` + - `GuzzleHttp\Subscriber\History` is now provided by + `GuzzleHttp\Middleware::history` + - `GuzzleHttp\Subscriber\Mock` is now provided by + `GuzzleHttp\Handler\MockHandler` + - `GuzzleHttp\Subscriber\Prepare` is now provided by + `GuzzleHttp\PrepareBodyMiddleware` + - `GuzzleHttp\Subscriber\Redirect` is now provided by + `GuzzleHttp\RedirectMiddleware` +- Guzzle now uses `Psr\Http\Message\UriInterface` (implements in + `GuzzleHttp\Psr7\Uri`) for URI support. `GuzzleHttp\Url` is now gone. +- Static functions in `GuzzleHttp\Utils` have been moved to namespaced + functions under the `GuzzleHttp` namespace. This requires either a Composer + based autoloader or you to include functions.php. +- `GuzzleHttp\ClientInterface::getDefaultOption` has been renamed to + `GuzzleHttp\ClientInterface::getConfig`. +- `GuzzleHttp\ClientInterface::setDefaultOption` has been removed. +- The `json` and `xml` methods of response objects has been removed. With the + migration to strictly adhering to PSR-7 as the interface for Guzzle messages, + adding methods to message interfaces would actually require Guzzle messages + to extend from PSR-7 messages rather then work with them directly. + +## Migrating to middleware + +The change to PSR-7 unfortunately required significant refactoring to Guzzle +due to the fact that PSR-7 messages are immutable. Guzzle 5 relied on an event +system from plugins. The event system relied on mutability of HTTP messages and +side effects in order to work. With immutable messages, you have to change your +workflow to become more about either returning a value (e.g., functional +middlewares) or setting a value on an object. Guzzle v6 has chosen the +functional middleware approach. + +Instead of using the event system to listen for things like the `before` event, +you now create a stack based middleware function that intercepts a request on +the way in and the promise of the response on the way out. This is a much +simpler and more predictable approach than the event system and works nicely +with PSR-7 middleware. Due to the use of promises, the middleware system is +also asynchronous. + +v5: + +```php +use GuzzleHttp\Event\BeforeEvent; +$client = new GuzzleHttp\Client(); +// Get the emitter and listen to the before event. +$client->getEmitter()->on('before', function (BeforeEvent $e) { + // Guzzle v5 events relied on mutation + $e->getRequest()->setHeader('X-Foo', 'Bar'); +}); +``` + +v6: + +In v6, you can modify the request before it is sent using the `mapRequest` +middleware. The idiomatic way in v6 to modify the request/response lifecycle is +to setup a handler middleware stack up front and inject the handler into a +client. + +```php +use GuzzleHttp\Middleware; +// Create a handler stack that has all of the default middlewares attached +$handler = GuzzleHttp\HandlerStack::create(); +// Push the handler onto the handler stack +$handler->push(Middleware::mapRequest(function (RequestInterface $request) { + // Notice that we have to return a request object + return $request->withHeader('X-Foo', 'Bar'); +})); +// Inject the handler into the client +$client = new GuzzleHttp\Client(['handler' => $handler]); +``` + +## POST Requests + +This version added the [`form_params`](http://guzzle.readthedocs.org/en/latest/request-options.html#form_params) +and `multipart` request options. `form_params` is an associative array of +strings or array of strings and is used to serialize an +`application/x-www-form-urlencoded` POST request. The +[`multipart`](http://guzzle.readthedocs.org/en/latest/request-options.html#multipart) +option is now used to send a multipart/form-data POST request. + +`GuzzleHttp\Post\PostFile` has been removed. Use the `multipart` option to add +POST files to a multipart/form-data request. + +The `body` option no longer accepts an array to send POST requests. Please use +`multipart` or `form_params` instead. + +The `base_url` option has been renamed to `base_uri`. + +4.x to 5.0 +---------- + +## Rewritten Adapter Layer + +Guzzle now uses [RingPHP](http://ringphp.readthedocs.org/en/latest) to send +HTTP requests. The `adapter` option in a `GuzzleHttp\Client` constructor +is still supported, but it has now been renamed to `handler`. Instead of +passing a `GuzzleHttp\Adapter\AdapterInterface`, you must now pass a PHP +`callable` that follows the RingPHP specification. + +## Removed Fluent Interfaces + +[Fluent interfaces were removed](http://ocramius.github.io/blog/fluent-interfaces-are-evil) +from the following classes: + +- `GuzzleHttp\Collection` +- `GuzzleHttp\Url` +- `GuzzleHttp\Query` +- `GuzzleHttp\Post\PostBody` +- `GuzzleHttp\Cookie\SetCookie` + +## Removed functions.php + +Removed "functions.php", so that Guzzle is truly PSR-4 compliant. The following +functions can be used as replacements. + +- `GuzzleHttp\json_decode` -> `GuzzleHttp\Utils::jsonDecode` +- `GuzzleHttp\get_path` -> `GuzzleHttp\Utils::getPath` +- `GuzzleHttp\Utils::setPath` -> `GuzzleHttp\set_path` +- `GuzzleHttp\Pool::batch` -> `GuzzleHttp\batch`. This function is, however, + deprecated in favor of using `GuzzleHttp\Pool::batch()`. + +The "procedural" global client has been removed with no replacement (e.g., +`GuzzleHttp\get()`, `GuzzleHttp\post()`, etc.). Use a `GuzzleHttp\Client` +object as a replacement. + +## `throwImmediately` has been removed + +The concept of "throwImmediately" has been removed from exceptions and error +events. This control mechanism was used to stop a transfer of concurrent +requests from completing. This can now be handled by throwing the exception or +by cancelling a pool of requests or each outstanding future request +individually. + +## headers event has been removed + +Removed the "headers" event. This event was only useful for changing the +body a response once the headers of the response were known. You can implement +a similar behavior in a number of ways. One example might be to use a +FnStream that has access to the transaction being sent. For example, when the +first byte is written, you could check if the response headers match your +expectations, and if so, change the actual stream body that is being +written to. + +## Updates to HTTP Messages + +Removed the `asArray` parameter from +`GuzzleHttp\Message\MessageInterface::getHeader`. If you want to get a header +value as an array, then use the newly added `getHeaderAsArray()` method of +`MessageInterface`. This change makes the Guzzle interfaces compatible with +the PSR-7 interfaces. + +3.x to 4.0 +---------- + +## Overarching changes: + +- Now requires PHP 5.4 or greater. +- No longer requires cURL to send requests. +- Guzzle no longer wraps every exception it throws. Only exceptions that are + recoverable are now wrapped by Guzzle. +- Various namespaces have been removed or renamed. +- No longer requiring the Symfony EventDispatcher. A custom event dispatcher + based on the Symfony EventDispatcher is + now utilized in `GuzzleHttp\Event\EmitterInterface` (resulting in significant + speed and functionality improvements). + +Changes per Guzzle 3.x namespace are described below. + +## Batch + +The `Guzzle\Batch` namespace has been removed. This is best left to +third-parties to implement on top of Guzzle's core HTTP library. + +## Cache + +The `Guzzle\Cache` namespace has been removed. (Todo: No suitable replacement +has been implemented yet, but hoping to utilize a PSR cache interface). + +## Common + +- Removed all of the wrapped exceptions. It's better to use the standard PHP + library for unrecoverable exceptions. +- `FromConfigInterface` has been removed. +- `Guzzle\Common\Version` has been removed. The VERSION constant can be found + at `GuzzleHttp\ClientInterface::VERSION`. + +### Collection + +- `getAll` has been removed. Use `toArray` to convert a collection to an array. +- `inject` has been removed. +- `keySearch` has been removed. +- `getPath` no longer supports wildcard expressions. Use something better like + JMESPath for this. +- `setPath` now supports appending to an existing array via the `[]` notation. + +### Events + +Guzzle no longer requires Symfony's EventDispatcher component. Guzzle now uses +`GuzzleHttp\Event\Emitter`. + +- `Symfony\Component\EventDispatcher\EventDispatcherInterface` is replaced by + `GuzzleHttp\Event\EmitterInterface`. +- `Symfony\Component\EventDispatcher\EventDispatcher` is replaced by + `GuzzleHttp\Event\Emitter`. +- `Symfony\Component\EventDispatcher\Event` is replaced by + `GuzzleHttp\Event\Event`, and Guzzle now has an EventInterface in + `GuzzleHttp\Event\EventInterface`. +- `AbstractHasDispatcher` has moved to a trait, `HasEmitterTrait`, and + `HasDispatcherInterface` has moved to `HasEmitterInterface`. Retrieving the + event emitter of a request, client, etc. now uses the `getEmitter` method + rather than the `getDispatcher` method. + +#### Emitter + +- Use the `once()` method to add a listener that automatically removes itself + the first time it is invoked. +- Use the `listeners()` method to retrieve a list of event listeners rather than + the `getListeners()` method. +- Use `emit()` instead of `dispatch()` to emit an event from an emitter. +- Use `attach()` instead of `addSubscriber()` and `detach()` instead of + `removeSubscriber()`. + +```php +$mock = new Mock(); +// 3.x +$request->getEventDispatcher()->addSubscriber($mock); +$request->getEventDispatcher()->removeSubscriber($mock); +// 4.x +$request->getEmitter()->attach($mock); +$request->getEmitter()->detach($mock); +``` + +Use the `on()` method to add a listener rather than the `addListener()` method. + +```php +// 3.x +$request->getEventDispatcher()->addListener('foo', function (Event $event) { /* ... */ } ); +// 4.x +$request->getEmitter()->on('foo', function (Event $event, $name) { /* ... */ } ); +``` + +## Http + +### General changes + +- The cacert.pem certificate has been moved to `src/cacert.pem`. +- Added the concept of adapters that are used to transfer requests over the + wire. +- Simplified the event system. +- Sending requests in parallel is still possible, but batching is no longer a + concept of the HTTP layer. Instead, you must use the `complete` and `error` + events to asynchronously manage parallel request transfers. +- `Guzzle\Http\Url` has moved to `GuzzleHttp\Url`. +- `Guzzle\Http\QueryString` has moved to `GuzzleHttp\Query`. +- QueryAggregators have been rewritten so that they are simply callable + functions. +- `GuzzleHttp\StaticClient` has been removed. Use the functions provided in + `functions.php` for an easy to use static client instance. +- Exceptions in `GuzzleHttp\Exception` have been updated to all extend from + `GuzzleHttp\Exception\TransferException`. + +### Client + +Calling methods like `get()`, `post()`, `head()`, etc. no longer create and +return a request, but rather creates a request, sends the request, and returns +the response. + +```php +// 3.0 +$request = $client->get('/'); +$response = $request->send(); + +// 4.0 +$response = $client->get('/'); + +// or, to mirror the previous behavior +$request = $client->createRequest('GET', '/'); +$response = $client->send($request); +``` + +`GuzzleHttp\ClientInterface` has changed. + +- The `send` method no longer accepts more than one request. Use `sendAll` to + send multiple requests in parallel. +- `setUserAgent()` has been removed. Use a default request option instead. You + could, for example, do something like: + `$client->setConfig('defaults/headers/User-Agent', 'Foo/Bar ' . $client::getDefaultUserAgent())`. +- `setSslVerification()` has been removed. Use default request options instead, + like `$client->setConfig('defaults/verify', true)`. + +`GuzzleHttp\Client` has changed. + +- The constructor now accepts only an associative array. You can include a + `base_url` string or array to use a URI template as the base URL of a client. + You can also specify a `defaults` key that is an associative array of default + request options. You can pass an `adapter` to use a custom adapter, + `batch_adapter` to use a custom adapter for sending requests in parallel, or + a `message_factory` to change the factory used to create HTTP requests and + responses. +- The client no longer emits a `client.create_request` event. +- Creating requests with a client no longer automatically utilize a URI + template. You must pass an array into a creational method (e.g., + `createRequest`, `get`, `put`, etc.) in order to expand a URI template. + +### Messages + +Messages no longer have references to their counterparts (i.e., a request no +longer has a reference to it's response, and a response no loger has a +reference to its request). This association is now managed through a +`GuzzleHttp\Adapter\TransactionInterface` object. You can get references to +these transaction objects using request events that are emitted over the +lifecycle of a request. + +#### Requests with a body + +- `GuzzleHttp\Message\EntityEnclosingRequest` and + `GuzzleHttp\Message\EntityEnclosingRequestInterface` have been removed. The + separation between requests that contain a body and requests that do not + contain a body has been removed, and now `GuzzleHttp\Message\RequestInterface` + handles both use cases. +- Any method that previously accepts a `GuzzleHttp\Response` object now accept a + `GuzzleHttp\Message\ResponseInterface`. +- `GuzzleHttp\Message\RequestFactoryInterface` has been renamed to + `GuzzleHttp\Message\MessageFactoryInterface`. This interface is used to create + both requests and responses and is implemented in + `GuzzleHttp\Message\MessageFactory`. +- POST field and file methods have been removed from the request object. You + must now use the methods made available to `GuzzleHttp\Post\PostBodyInterface` + to control the format of a POST body. Requests that are created using a + standard `GuzzleHttp\Message\MessageFactoryInterface` will automatically use + a `GuzzleHttp\Post\PostBody` body if the body was passed as an array or if + the method is POST and no body is provided. + +```php +$request = $client->createRequest('POST', '/'); +$request->getBody()->setField('foo', 'bar'); +$request->getBody()->addFile(new PostFile('file_key', fopen('/path/to/content', 'r'))); +``` + +#### Headers + +- `GuzzleHttp\Message\Header` has been removed. Header values are now simply + represented by an array of values or as a string. Header values are returned + as a string by default when retrieving a header value from a message. You can + pass an optional argument of `true` to retrieve a header value as an array + of strings instead of a single concatenated string. +- `GuzzleHttp\PostFile` and `GuzzleHttp\PostFileInterface` have been moved to + `GuzzleHttp\Post`. This interface has been simplified and now allows the + addition of arbitrary headers. +- Custom headers like `GuzzleHttp\Message\Header\Link` have been removed. Most + of the custom headers are now handled separately in specific + subscribers/plugins, and `GuzzleHttp\Message\HeaderValues::parseParams()` has + been updated to properly handle headers that contain parameters (like the + `Link` header). + +#### Responses + +- `GuzzleHttp\Message\Response::getInfo()` and + `GuzzleHttp\Message\Response::setInfo()` have been removed. Use the event + system to retrieve this type of information. +- `GuzzleHttp\Message\Response::getRawHeaders()` has been removed. +- `GuzzleHttp\Message\Response::getMessage()` has been removed. +- `GuzzleHttp\Message\Response::calculateAge()` and other cache specific + methods have moved to the CacheSubscriber. +- Header specific helper functions like `getContentMd5()` have been removed. + Just use `getHeader('Content-MD5')` instead. +- `GuzzleHttp\Message\Response::setRequest()` and + `GuzzleHttp\Message\Response::getRequest()` have been removed. Use the event + system to work with request and response objects as a transaction. +- `GuzzleHttp\Message\Response::getRedirectCount()` has been removed. Use the + Redirect subscriber instead. +- `GuzzleHttp\Message\Response::isSuccessful()` and other related methods have + been removed. Use `getStatusCode()` instead. + +#### Streaming responses + +Streaming requests can now be created by a client directly, returning a +`GuzzleHttp\Message\ResponseInterface` object that contains a body stream +referencing an open PHP HTTP stream. + +```php +// 3.0 +use Guzzle\Stream\PhpStreamRequestFactory; +$request = $client->get('/'); +$factory = new PhpStreamRequestFactory(); +$stream = $factory->fromRequest($request); +$data = $stream->read(1024); + +// 4.0 +$response = $client->get('/', ['stream' => true]); +// Read some data off of the stream in the response body +$data = $response->getBody()->read(1024); +``` + +#### Redirects + +The `configureRedirects()` method has been removed in favor of a +`allow_redirects` request option. + +```php +// Standard redirects with a default of a max of 5 redirects +$request = $client->createRequest('GET', '/', ['allow_redirects' => true]); + +// Strict redirects with a custom number of redirects +$request = $client->createRequest('GET', '/', [ + 'allow_redirects' => ['max' => 5, 'strict' => true] +]); +``` + +#### EntityBody + +EntityBody interfaces and classes have been removed or moved to +`GuzzleHttp\Stream`. All classes and interfaces that once required +`GuzzleHttp\EntityBodyInterface` now require +`GuzzleHttp\Stream\StreamInterface`. Creating a new body for a request no +longer uses `GuzzleHttp\EntityBody::factory` but now uses +`GuzzleHttp\Stream\Stream::factory` or even better: +`GuzzleHttp\Stream\create()`. + +- `Guzzle\Http\EntityBodyInterface` is now `GuzzleHttp\Stream\StreamInterface` +- `Guzzle\Http\EntityBody` is now `GuzzleHttp\Stream\Stream` +- `Guzzle\Http\CachingEntityBody` is now `GuzzleHttp\Stream\CachingStream` +- `Guzzle\Http\ReadLimitEntityBody` is now `GuzzleHttp\Stream\LimitStream` +- `Guzzle\Http\IoEmittyinEntityBody` has been removed. + +#### Request lifecycle events + +Requests previously submitted a large number of requests. The number of events +emitted over the lifecycle of a request has been significantly reduced to make +it easier to understand how to extend the behavior of a request. All events +emitted during the lifecycle of a request now emit a custom +`GuzzleHttp\Event\EventInterface` object that contains context providing +methods and a way in which to modify the transaction at that specific point in +time (e.g., intercept the request and set a response on the transaction). + +- `request.before_send` has been renamed to `before` and now emits a + `GuzzleHttp\Event\BeforeEvent` +- `request.complete` has been renamed to `complete` and now emits a + `GuzzleHttp\Event\CompleteEvent`. +- `request.sent` has been removed. Use `complete`. +- `request.success` has been removed. Use `complete`. +- `error` is now an event that emits a `GuzzleHttp\Event\ErrorEvent`. +- `request.exception` has been removed. Use `error`. +- `request.receive.status_line` has been removed. +- `curl.callback.progress` has been removed. Use a custom `StreamInterface` to + maintain a status update. +- `curl.callback.write` has been removed. Use a custom `StreamInterface` to + intercept writes. +- `curl.callback.read` has been removed. Use a custom `StreamInterface` to + intercept reads. + +`headers` is a new event that is emitted after the response headers of a +request have been received before the body of the response is downloaded. This +event emits a `GuzzleHttp\Event\HeadersEvent`. + +You can intercept a request and inject a response using the `intercept()` event +of a `GuzzleHttp\Event\BeforeEvent`, `GuzzleHttp\Event\CompleteEvent`, and +`GuzzleHttp\Event\ErrorEvent` event. + +See: http://docs.guzzlephp.org/en/latest/events.html + +## Inflection + +The `Guzzle\Inflection` namespace has been removed. This is not a core concern +of Guzzle. + +## Iterator + +The `Guzzle\Iterator` namespace has been removed. + +- `Guzzle\Iterator\AppendIterator`, `Guzzle\Iterator\ChunkedIterator`, and + `Guzzle\Iterator\MethodProxyIterator` are nice, but not a core requirement of + Guzzle itself. +- `Guzzle\Iterator\FilterIterator` is no longer needed because an equivalent + class is shipped with PHP 5.4. +- `Guzzle\Iterator\MapIterator` is not really needed when using PHP 5.5 because + it's easier to just wrap an iterator in a generator that maps values. + +For a replacement of these iterators, see https://github.com/nikic/iter + +## Log + +The LogPlugin has moved to https://github.com/guzzle/log-subscriber. The +`Guzzle\Log` namespace has been removed. Guzzle now relies on +`Psr\Log\LoggerInterface` for all logging. The MessageFormatter class has been +moved to `GuzzleHttp\Subscriber\Log\Formatter`. + +## Parser + +The `Guzzle\Parser` namespace has been removed. This was previously used to +make it possible to plug in custom parsers for cookies, messages, URI +templates, and URLs; however, this level of complexity is not needed in Guzzle +so it has been removed. + +- Cookie: Cookie parsing logic has been moved to + `GuzzleHttp\Cookie\SetCookie::fromString`. +- Message: Message parsing logic for both requests and responses has been moved + to `GuzzleHttp\Message\MessageFactory::fromMessage`. Message parsing is only + used in debugging or deserializing messages, so it doesn't make sense for + Guzzle as a library to add this level of complexity to parsing messages. +- UriTemplate: URI template parsing has been moved to + `GuzzleHttp\UriTemplate`. The Guzzle library will automatically use the PECL + URI template library if it is installed. +- Url: URL parsing is now performed in `GuzzleHttp\Url::fromString` (previously + it was `Guzzle\Http\Url::factory()`). If custom URL parsing is necessary, + then developers are free to subclass `GuzzleHttp\Url`. + +## Plugin + +The `Guzzle\Plugin` namespace has been renamed to `GuzzleHttp\Subscriber`. +Several plugins are shipping with the core Guzzle library under this namespace. + +- `GuzzleHttp\Subscriber\Cookie`: Replaces the old CookiePlugin. Cookie jar + code has moved to `GuzzleHttp\Cookie`. +- `GuzzleHttp\Subscriber\History`: Replaces the old HistoryPlugin. +- `GuzzleHttp\Subscriber\HttpError`: Throws errors when a bad HTTP response is + received. +- `GuzzleHttp\Subscriber\Mock`: Replaces the old MockPlugin. +- `GuzzleHttp\Subscriber\Prepare`: Prepares the body of a request just before + sending. This subscriber is attached to all requests by default. +- `GuzzleHttp\Subscriber\Redirect`: Replaces the RedirectPlugin. + +The following plugins have been removed (third-parties are free to re-implement +these if needed): + +- `GuzzleHttp\Plugin\Async` has been removed. +- `GuzzleHttp\Plugin\CurlAuth` has been removed. +- `GuzzleHttp\Plugin\ErrorResponse\ErrorResponsePlugin` has been removed. This + functionality should instead be implemented with event listeners that occur + after normal response parsing occurs in the guzzle/command package. + +The following plugins are not part of the core Guzzle package, but are provided +in separate repositories: + +- `Guzzle\Http\Plugin\BackoffPlugin` has been rewritten to be much simpler + to build custom retry policies using simple functions rather than various + chained classes. See: https://github.com/guzzle/retry-subscriber +- `Guzzle\Http\Plugin\Cache\CachePlugin` has moved to + https://github.com/guzzle/cache-subscriber +- `Guzzle\Http\Plugin\Log\LogPlugin` has moved to + https://github.com/guzzle/log-subscriber +- `Guzzle\Http\Plugin\Md5\Md5Plugin` has moved to + https://github.com/guzzle/message-integrity-subscriber +- `Guzzle\Http\Plugin\Mock\MockPlugin` has moved to + `GuzzleHttp\Subscriber\MockSubscriber`. +- `Guzzle\Http\Plugin\Oauth\OauthPlugin` has moved to + https://github.com/guzzle/oauth-subscriber + +## Service + +The service description layer of Guzzle has moved into two separate packages: + +- http://github.com/guzzle/command Provides a high level abstraction over web + services by representing web service operations using commands. +- http://github.com/guzzle/guzzle-services Provides an implementation of + guzzle/command that provides request serialization and response parsing using + Guzzle service descriptions. + +## Stream + +Stream have moved to a separate package available at +https://github.com/guzzle/streams. + +`Guzzle\Stream\StreamInterface` has been given a large update to cleanly take +on the responsibilities of `Guzzle\Http\EntityBody` and +`Guzzle\Http\EntityBodyInterface` now that they have been removed. The number +of methods implemented by the `StreamInterface` has been drastically reduced to +allow developers to more easily extend and decorate stream behavior. + +## Removed methods from StreamInterface + +- `getStream` and `setStream` have been removed to better encapsulate streams. +- `getMetadata` and `setMetadata` have been removed in favor of + `GuzzleHttp\Stream\MetadataStreamInterface`. +- `getWrapper`, `getWrapperData`, `getStreamType`, and `getUri` have all been + removed. This data is accessible when + using streams that implement `GuzzleHttp\Stream\MetadataStreamInterface`. +- `rewind` has been removed. Use `seek(0)` for a similar behavior. + +## Renamed methods + +- `detachStream` has been renamed to `detach`. +- `feof` has been renamed to `eof`. +- `ftell` has been renamed to `tell`. +- `readLine` has moved from an instance method to a static class method of + `GuzzleHttp\Stream\Stream`. + +## Metadata streams + +`GuzzleHttp\Stream\MetadataStreamInterface` has been added to denote streams +that contain additional metadata accessible via `getMetadata()`. +`GuzzleHttp\Stream\StreamInterface::getMetadata` and +`GuzzleHttp\Stream\StreamInterface::setMetadata` have been removed. + +## StreamRequestFactory + +The entire concept of the StreamRequestFactory has been removed. The way this +was used in Guzzle 3 broke the actual interface of sending streaming requests +(instead of getting back a Response, you got a StreamInterface). Streaming +PHP requests are now implemented through the `GuzzleHttp\Adapter\StreamAdapter`. + +3.6 to 3.7 +---------- + +### Deprecations + +- You can now enable E_USER_DEPRECATED warnings to see if you are using any deprecated methods.: + +```php +\Guzzle\Common\Version::$emitWarnings = true; +``` + +The following APIs and options have been marked as deprecated: + +- Marked `Guzzle\Http\Message\Request::isResponseBodyRepeatable()` as deprecated. Use `$request->getResponseBody()->isRepeatable()` instead. +- Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead. +- Marked `Guzzle\Http\Message\Request::canCache()` as deprecated. Use `Guzzle\Plugin\Cache\DefaultCanCacheStrategy->canCacheRequest()` instead. +- Marked `Guzzle\Http\Message\Request::setIsRedirect()` as deprecated. Use the HistoryPlugin instead. +- Marked `Guzzle\Http\Message\Request::isRedirect()` as deprecated. Use the HistoryPlugin instead. +- Marked `Guzzle\Cache\CacheAdapterFactory::factory()` as deprecated +- Marked `Guzzle\Service\Client::enableMagicMethods()` as deprecated. Magic methods can no longer be disabled on a Guzzle\Service\Client. +- Marked `Guzzle\Parser\Url\UrlParser` as deprecated. Just use PHP's `parse_url()` and percent encode your UTF-8. +- Marked `Guzzle\Common\Collection::inject()` as deprecated. +- Marked `Guzzle\Plugin\CurlAuth\CurlAuthPlugin` as deprecated. Use + `$client->getConfig()->setPath('request.options/auth', array('user', 'pass', 'Basic|Digest|NTLM|Any'));` or + `$client->setDefaultOption('auth', array('user', 'pass', 'Basic|Digest|NTLM|Any'));` + +3.7 introduces `request.options` as a parameter for a client configuration and as an optional argument to all creational +request methods. When paired with a client's configuration settings, these options allow you to specify default settings +for various aspects of a request. Because these options make other previous configuration options redundant, several +configuration options and methods of a client and AbstractCommand have been deprecated. + +- Marked `Guzzle\Service\Client::getDefaultHeaders()` as deprecated. Use `$client->getDefaultOption('headers')`. +- Marked `Guzzle\Service\Client::setDefaultHeaders()` as deprecated. Use `$client->setDefaultOption('headers/{header_name}', 'value')`. +- Marked 'request.params' for `Guzzle\Http\Client` as deprecated. Use `$client->setDefaultOption('params/{param_name}', 'value')` +- Marked 'command.headers', 'command.response_body' and 'command.on_complete' as deprecated for AbstractCommand. These will work through Guzzle 4.0 + + $command = $client->getCommand('foo', array( + 'command.headers' => array('Test' => '123'), + 'command.response_body' => '/path/to/file' + )); + + // Should be changed to: + + $command = $client->getCommand('foo', array( + 'command.request_options' => array( + 'headers' => array('Test' => '123'), + 'save_as' => '/path/to/file' + ) + )); + +### Interface changes + +Additions and changes (you will need to update any implementations or subclasses you may have created): + +- Added an `$options` argument to the end of the following methods of `Guzzle\Http\ClientInterface`: + createRequest, head, delete, put, patch, post, options, prepareRequest +- Added an `$options` argument to the end of `Guzzle\Http\Message\Request\RequestFactoryInterface::createRequest()` +- Added an `applyOptions()` method to `Guzzle\Http\Message\Request\RequestFactoryInterface` +- Changed `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $body = null)` to + `Guzzle\Http\ClientInterface::get($uri = null, $headers = null, $options = array())`. You can still pass in a + resource, string, or EntityBody into the $options parameter to specify the download location of the response. +- Changed `Guzzle\Common\Collection::__construct($data)` to no longer accepts a null value for `$data` but a + default `array()` +- Added `Guzzle\Stream\StreamInterface::isRepeatable` +- Made `Guzzle\Http\Client::expandTemplate` and `getUriTemplate` protected methods. + +The following methods were removed from interfaces. All of these methods are still available in the concrete classes +that implement them, but you should update your code to use alternative methods: + +- Removed `Guzzle\Http\ClientInterface::setDefaultHeaders(). Use + `$client->getConfig()->setPath('request.options/headers/{header_name}', 'value')`. or + `$client->getConfig()->setPath('request.options/headers', array('header_name' => 'value'))` or + `$client->setDefaultOption('headers/{header_name}', 'value')`. or + `$client->setDefaultOption('headers', array('header_name' => 'value'))`. +- Removed `Guzzle\Http\ClientInterface::getDefaultHeaders(). Use `$client->getConfig()->getPath('request.options/headers')`. +- Removed `Guzzle\Http\ClientInterface::expandTemplate()`. This is an implementation detail. +- Removed `Guzzle\Http\ClientInterface::setRequestFactory()`. This is an implementation detail. +- Removed `Guzzle\Http\ClientInterface::getCurlMulti()`. This is a very specific implementation detail. +- Removed `Guzzle\Http\Message\RequestInterface::canCache`. Use the CachePlugin. +- Removed `Guzzle\Http\Message\RequestInterface::setIsRedirect`. Use the HistoryPlugin. +- Removed `Guzzle\Http\Message\RequestInterface::isRedirect`. Use the HistoryPlugin. + +### Cache plugin breaking changes + +- CacheKeyProviderInterface and DefaultCacheKeyProvider are no longer used. All of this logic is handled in a + CacheStorageInterface. These two objects and interface will be removed in a future version. +- Always setting X-cache headers on cached responses +- Default cache TTLs are now handled by the CacheStorageInterface of a CachePlugin +- `CacheStorageInterface::cache($key, Response $response, $ttl = null)` has changed to `cache(RequestInterface + $request, Response $response);` +- `CacheStorageInterface::fetch($key)` has changed to `fetch(RequestInterface $request);` +- `CacheStorageInterface::delete($key)` has changed to `delete(RequestInterface $request);` +- Added `CacheStorageInterface::purge($url)` +- `DefaultRevalidation::__construct(CacheKeyProviderInterface $cacheKey, CacheStorageInterface $cache, CachePlugin + $plugin)` has changed to `DefaultRevalidation::__construct(CacheStorageInterface $cache, + CanCacheStrategyInterface $canCache = null)` +- Added `RevalidationInterface::shouldRevalidate(RequestInterface $request, Response $response)` + +3.5 to 3.6 +---------- + +* Mixed casing of headers are now forced to be a single consistent casing across all values for that header. +* Messages internally use a HeaderCollection object to delegate handling case-insensitive header resolution +* Removed the whole changedHeader() function system of messages because all header changes now go through addHeader(). + For example, setHeader() first removes the header using unset on a HeaderCollection and then calls addHeader(). + Keeping the Host header and URL host in sync is now handled by overriding the addHeader method in Request. +* Specific header implementations can be created for complex headers. When a message creates a header, it uses a + HeaderFactory which can map specific headers to specific header classes. There is now a Link header and + CacheControl header implementation. +* Moved getLinks() from Response to just be used on a Link header object. + +If you previously relied on Guzzle\Http\Message\Header::raw(), then you will need to update your code to use the +HeaderInterface (e.g. toArray(), getAll(), etc.). + +### Interface changes + +* Removed from interface: Guzzle\Http\ClientInterface::setUriTemplate +* Removed from interface: Guzzle\Http\ClientInterface::setCurlMulti() +* Removed Guzzle\Http\Message\Request::receivedRequestHeader() and implemented this functionality in + Guzzle\Http\Curl\RequestMediator +* Removed the optional $asString parameter from MessageInterface::getHeader(). Just cast the header to a string. +* Removed the optional $tryChunkedTransfer option from Guzzle\Http\Message\EntityEnclosingRequestInterface +* Removed the $asObjects argument from Guzzle\Http\Message\MessageInterface::getHeaders() + +### Removed deprecated functions + +* Removed Guzzle\Parser\ParserRegister::get(). Use getParser() +* Removed Guzzle\Parser\ParserRegister::set(). Use registerParser(). + +### Deprecations + +* The ability to case-insensitively search for header values +* Guzzle\Http\Message\Header::hasExactHeader +* Guzzle\Http\Message\Header::raw. Use getAll() +* Deprecated cache control specific methods on Guzzle\Http\Message\AbstractMessage. Use the CacheControl header object + instead. + +### Other changes + +* All response header helper functions return a string rather than mixing Header objects and strings inconsistently +* Removed cURL blacklist support. This is no longer necessary now that Expect, Accept, etc. are managed by Guzzle + directly via interfaces +* Removed the injecting of a request object onto a response object. The methods to get and set a request still exist + but are a no-op until removed. +* Most classes that used to require a `Guzzle\Service\Command\CommandInterface` typehint now request a + `Guzzle\Service\Command\ArrayCommandInterface`. +* Added `Guzzle\Http\Message\RequestInterface::startResponse()` to the RequestInterface to handle injecting a response + on a request while the request is still being transferred +* `Guzzle\Service\Command\CommandInterface` now extends from ToArrayInterface and ArrayAccess + +3.3 to 3.4 +---------- + +Base URLs of a client now follow the rules of http://tools.ietf.org/html/rfc3986#section-5.2.2 when merging URLs. + +3.2 to 3.3 +---------- + +### Response::getEtag() quote stripping removed + +`Guzzle\Http\Message\Response::getEtag()` no longer strips quotes around the ETag response header + +### Removed `Guzzle\Http\Utils` + +The `Guzzle\Http\Utils` class was removed. This class was only used for testing. + +### Stream wrapper and type + +`Guzzle\Stream\Stream::getWrapper()` and `Guzzle\Stream\Stream::getStreamType()` are no longer converted to lowercase. + +### curl.emit_io became emit_io + +Emitting IO events from a RequestMediator is now a parameter that must be set in a request's curl options using the +'emit_io' key. This was previously set under a request's parameters using 'curl.emit_io' + +3.1 to 3.2 +---------- + +### CurlMulti is no longer reused globally + +Before 3.2, the same CurlMulti object was reused globally for each client. This can cause issue where plugins added +to a single client can pollute requests dispatched from other clients. + +If you still wish to reuse the same CurlMulti object with each client, then you can add a listener to the +ServiceBuilder's `service_builder.create_client` event to inject a custom CurlMulti object into each client as it is +created. + +```php +$multi = new Guzzle\Http\Curl\CurlMulti(); +$builder = Guzzle\Service\Builder\ServiceBuilder::factory('/path/to/config.json'); +$builder->addListener('service_builder.create_client', function ($event) use ($multi) { + $event['client']->setCurlMulti($multi); +} +}); +``` + +### No default path + +URLs no longer have a default path value of '/' if no path was specified. + +Before: + +```php +$request = $client->get('http://www.foo.com'); +echo $request->getUrl(); +// >> http://www.foo.com/ +``` + +After: + +```php +$request = $client->get('http://www.foo.com'); +echo $request->getUrl(); +// >> http://www.foo.com +``` + +### Less verbose BadResponseException + +The exception message for `Guzzle\Http\Exception\BadResponseException` no longer contains the full HTTP request and +response information. You can, however, get access to the request and response object by calling `getRequest()` or +`getResponse()` on the exception object. + +### Query parameter aggregation + +Multi-valued query parameters are no longer aggregated using a callback function. `Guzzle\Http\Query` now has a +setAggregator() method that accepts a `Guzzle\Http\QueryAggregator\QueryAggregatorInterface` object. This object is +responsible for handling the aggregation of multi-valued query string variables into a flattened hash. + +2.8 to 3.x +---------- + +### Guzzle\Service\Inspector + +Change `\Guzzle\Service\Inspector::fromConfig` to `\Guzzle\Common\Collection::fromConfig` + +**Before** + +```php +use Guzzle\Service\Inspector; + +class YourClient extends \Guzzle\Service\Client +{ + public static function factory($config = array()) + { + $default = array(); + $required = array('base_url', 'username', 'api_key'); + $config = Inspector::fromConfig($config, $default, $required); + + $client = new self( + $config->get('base_url'), + $config->get('username'), + $config->get('api_key') + ); + $client->setConfig($config); + + $client->setDescription(ServiceDescription::factory(__DIR__ . DIRECTORY_SEPARATOR . 'client.json')); + + return $client; + } +``` + +**After** + +```php +use Guzzle\Common\Collection; + +class YourClient extends \Guzzle\Service\Client +{ + public static function factory($config = array()) + { + $default = array(); + $required = array('base_url', 'username', 'api_key'); + $config = Collection::fromConfig($config, $default, $required); + + $client = new self( + $config->get('base_url'), + $config->get('username'), + $config->get('api_key') + ); + $client->setConfig($config); + + $client->setDescription(ServiceDescription::factory(__DIR__ . DIRECTORY_SEPARATOR . 'client.json')); + + return $client; + } +``` + +### Convert XML Service Descriptions to JSON + +**Before** + +```xml + + + + + + Get a list of groups + + + Uses a search query to get a list of groups + + + + Create a group + + + + + Delete a group by ID + + + + + + + Update a group + + + + + + +``` + +**After** + +```json +{ + "name": "Zendesk REST API v2", + "apiVersion": "2012-12-31", + "description":"Provides access to Zendesk views, groups, tickets, ticket fields, and users", + "operations": { + "list_groups": { + "httpMethod":"GET", + "uri": "groups.json", + "summary": "Get a list of groups" + }, + "search_groups":{ + "httpMethod":"GET", + "uri": "search.json?query=\"{query} type:group\"", + "summary": "Uses a search query to get a list of groups", + "parameters":{ + "query":{ + "location": "uri", + "description":"Zendesk Search Query", + "type": "string", + "required": true + } + } + }, + "create_group": { + "httpMethod":"POST", + "uri": "groups.json", + "summary": "Create a group", + "parameters":{ + "data": { + "type": "array", + "location": "body", + "description":"Group JSON", + "filters": "json_encode", + "required": true + }, + "Content-Type":{ + "type": "string", + "location":"header", + "static": "application/json" + } + } + }, + "delete_group": { + "httpMethod":"DELETE", + "uri": "groups/{id}.json", + "summary": "Delete a group", + "parameters":{ + "id":{ + "location": "uri", + "description":"Group to delete by ID", + "type": "integer", + "required": true + } + } + }, + "get_group": { + "httpMethod":"GET", + "uri": "groups/{id}.json", + "summary": "Get a ticket", + "parameters":{ + "id":{ + "location": "uri", + "description":"Group to get by ID", + "type": "integer", + "required": true + } + } + }, + "update_group": { + "httpMethod":"PUT", + "uri": "groups/{id}.json", + "summary": "Update a group", + "parameters":{ + "id": { + "location": "uri", + "description":"Group to update by ID", + "type": "integer", + "required": true + }, + "data": { + "type": "array", + "location": "body", + "description":"Group JSON", + "filters": "json_encode", + "required": true + }, + "Content-Type":{ + "type": "string", + "location":"header", + "static": "application/json" + } + } + } +} +``` + +### Guzzle\Service\Description\ServiceDescription + +Commands are now called Operations + +**Before** + +```php +use Guzzle\Service\Description\ServiceDescription; + +$sd = new ServiceDescription(); +$sd->getCommands(); // @returns ApiCommandInterface[] +$sd->hasCommand($name); +$sd->getCommand($name); // @returns ApiCommandInterface|null +$sd->addCommand($command); // @param ApiCommandInterface $command +``` + +**After** + +```php +use Guzzle\Service\Description\ServiceDescription; + +$sd = new ServiceDescription(); +$sd->getOperations(); // @returns OperationInterface[] +$sd->hasOperation($name); +$sd->getOperation($name); // @returns OperationInterface|null +$sd->addOperation($operation); // @param OperationInterface $operation +``` + +### Guzzle\Common\Inflection\Inflector + +Namespace is now `Guzzle\Inflection\Inflector` + +### Guzzle\Http\Plugin + +Namespace is now `Guzzle\Plugin`. Many other changes occur within this namespace and are detailed in their own sections below. + +### Guzzle\Http\Plugin\LogPlugin and Guzzle\Common\Log + +Now `Guzzle\Plugin\Log\LogPlugin` and `Guzzle\Log` respectively. + +**Before** + +```php +use Guzzle\Common\Log\ClosureLogAdapter; +use Guzzle\Http\Plugin\LogPlugin; + +/** @var \Guzzle\Http\Client */ +$client; + +// $verbosity is an integer indicating desired message verbosity level +$client->addSubscriber(new LogPlugin(new ClosureLogAdapter(function($m) { echo $m; }, $verbosity = LogPlugin::LOG_VERBOSE); +``` + +**After** + +```php +use Guzzle\Log\ClosureLogAdapter; +use Guzzle\Log\MessageFormatter; +use Guzzle\Plugin\Log\LogPlugin; + +/** @var \Guzzle\Http\Client */ +$client; + +// $format is a string indicating desired message format -- @see MessageFormatter +$client->addSubscriber(new LogPlugin(new ClosureLogAdapter(function($m) { echo $m; }, $format = MessageFormatter::DEBUG_FORMAT); +``` + +### Guzzle\Http\Plugin\CurlAuthPlugin + +Now `Guzzle\Plugin\CurlAuth\CurlAuthPlugin`. + +### Guzzle\Http\Plugin\ExponentialBackoffPlugin + +Now `Guzzle\Plugin\Backoff\BackoffPlugin`, and other changes. + +**Before** + +```php +use Guzzle\Http\Plugin\ExponentialBackoffPlugin; + +$backoffPlugin = new ExponentialBackoffPlugin($maxRetries, array_merge( + ExponentialBackoffPlugin::getDefaultFailureCodes(), array(429) + )); + +$client->addSubscriber($backoffPlugin); +``` + +**After** + +```php +use Guzzle\Plugin\Backoff\BackoffPlugin; +use Guzzle\Plugin\Backoff\HttpBackoffStrategy; + +// Use convenient factory method instead -- see implementation for ideas of what +// you can do with chaining backoff strategies +$backoffPlugin = BackoffPlugin::getExponentialBackoff($maxRetries, array_merge( + HttpBackoffStrategy::getDefaultFailureCodes(), array(429) + )); +$client->addSubscriber($backoffPlugin); +``` + +### Known Issues + +#### [BUG] Accept-Encoding header behavior changed unintentionally. + +(See #217) (Fixed in 09daeb8c666fb44499a0646d655a8ae36456575e) + +In version 2.8 setting the `Accept-Encoding` header would set the CURLOPT_ENCODING option, which permitted cURL to +properly handle gzip/deflate compressed responses from the server. In versions affected by this bug this does not happen. +See issue #217 for a workaround, or use a version containing the fix. diff --git a/vendor/guzzlehttp/guzzle/composer.json b/vendor/guzzlehttp/guzzle/composer.json index 372399481..d756acac3 100644 --- a/vendor/guzzlehttp/guzzle/composer.json +++ b/vendor/guzzlehttp/guzzle/composer.json @@ -1,59 +1,59 @@ -{ - "name": "guzzlehttp\/guzzle", - "type": "library", - "description": "Guzzle is a PHP HTTP client library", - "keywords": [ - "framework", - "http", - "rest", - "web service", - "curl", - "client", - "HTTP client" - ], - "homepage": "http:\/\/guzzlephp.org\/", - "license": "MIT", - "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https:\/\/github.com\/mtdowling" - } - ], - "require": { - "php": ">=5.5", - "ext-json": "*", - "symfony\/polyfill-intl-idn": "^1.11", - "guzzlehttp\/promises": "^1.0", - "guzzlehttp\/psr7": "^1.6.1" - }, - "require-dev": { - "ext-curl": "*", - "phpunit\/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", - "psr\/log": "^1.1" - }, - "suggest": { - "psr\/log": "Required for using the Log middleware" - }, - "config": { - "sort-packages": true - }, - "extra": { - "branch-alias": { - "dev-master": "6.5-dev" - } - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\GuzzleHttp\\": "src\/" - }, - "files": [ - "src\/functions_include.php" - ] - }, - "autoload-dev": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Tests\\": "tests\/" - } - } +{ + "name": "guzzlehttp\/guzzle", + "type": "library", + "description": "Guzzle is a PHP HTTP client library", + "keywords": [ + "framework", + "http", + "rest", + "web service", + "curl", + "client", + "HTTP client" + ], + "homepage": "http:\/\/guzzlephp.org\/", + "license": "MIT", + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https:\/\/github.com\/mtdowling" + } + ], + "require": { + "php": ">=5.5", + "ext-json": "*", + "symfony\/polyfill-intl-idn": "^1.11", + "guzzlehttp\/promises": "^1.0", + "guzzlehttp\/psr7": "^1.6.1" + }, + "require-dev": { + "ext-curl": "*", + "phpunit\/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", + "psr\/log": "^1.1" + }, + "suggest": { + "psr\/log": "Required for using the Log middleware" + }, + "config": { + "sort-packages": true + }, + "extra": { + "branch-alias": { + "dev-master": "6.5-dev" + } + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\GuzzleHttp\\": "src\/" + }, + "files": [ + "src\/functions_include.php" + ] + }, + "autoload-dev": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Tests\\": "tests\/" + } + } } \ No newline at end of file diff --git a/vendor/guzzlehttp/guzzle/index.php b/vendor/guzzlehttp/guzzle/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/guzzlehttp/guzzle/index.php +++ b/vendor/guzzlehttp/guzzle/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/guzzle/src/Client.php b/vendor/guzzlehttp/guzzle/src/Client.php index 615b52fb8..17e70402c 100644 --- a/vendor/guzzlehttp/guzzle/src/Client.php +++ b/vendor/guzzlehttp/guzzle/src/Client.php @@ -1,425 +1,425 @@ - 'http://www.foo.com/1.0/', - * 'timeout' => 0, - * 'allow_redirects' => false, - * 'proxy' => '192.168.16.1:10' - * ]); - * - * Client configuration settings include the following options: - * - * - handler: (callable) Function that transfers HTTP requests over the - * wire. The function is called with a Psr7\Http\Message\RequestInterface - * and array of transfer options, and must return a - * GuzzleHttp\Promise\PromiseInterface that is fulfilled with a - * Psr7\Http\Message\ResponseInterface on success. "handler" is a - * constructor only option that cannot be overridden in per/request - * options. If no handler is provided, a default handler will be created - * that enables all of the request options below by attaching all of the - * default middleware to the handler. - * - base_uri: (string|UriInterface) Base URI of the client that is merged - * into relative URIs. Can be a string or instance of UriInterface. - * - **: any request option - * - * @param array $config Client configuration settings. - * - * @see \GuzzleHttp\RequestOptions for a list of available request options. - */ - public function __construct(array $config = []) - { - if (!isset($config['handler'])) { - $config['handler'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\HandlerStack::create(); - } elseif (!\is_callable($config['handler'])) { - throw new \InvalidArgumentException('handler must be a callable'); - } - // Convert the base_uri to a UriInterface - if (isset($config['base_uri'])) { - $config['base_uri'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\uri_for($config['base_uri']); - } - $this->configureDefaults($config); - } - /** - * @param string $method - * @param array $args - * - * @return Promise\PromiseInterface - */ - public function __call($method, $args) - { - if (\count($args) < 1) { - throw new \InvalidArgumentException('Magic request methods require a URI and optional options array'); - } - $uri = $args[0]; - $opts = isset($args[1]) ? $args[1] : []; - return \substr($method, -5) === 'Async' ? $this->requestAsync(\substr($method, 0, -5), $uri, $opts) : $this->request($method, $uri, $opts); - } - /** - * Asynchronously send an HTTP request. - * - * @param array $options Request options to apply to the given - * request and to the transfer. See \GuzzleHttp\RequestOptions. - * - * @return Promise\PromiseInterface - */ - public function sendAsync(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options = []) - { - // Merge the base URI into the request URI if needed. - $options = $this->prepareDefaults($options); - return $this->transfer($request->withUri($this->buildUri($request->getUri(), $options), $request->hasHeader('Host')), $options); - } - /** - * Send an HTTP request. - * - * @param array $options Request options to apply to the given - * request and to the transfer. See \GuzzleHttp\RequestOptions. - * - * @return ResponseInterface - * @throws GuzzleException - */ - public function send(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options = []) - { - $options[\_PhpScoper5ea00cc67502b\GuzzleHttp\RequestOptions::SYNCHRONOUS] = \true; - return $this->sendAsync($request, $options)->wait(); - } - /** - * Create and send an asynchronous HTTP request. - * - * Use an absolute path to override the base path of the client, or a - * relative path to append to the base path of the client. The URL can - * contain the query string as well. Use an array to provide a URL - * template and additional variables to use in the URL template expansion. - * - * @param string $method HTTP method - * @param string|UriInterface $uri URI object or string. - * @param array $options Request options to apply. See \GuzzleHttp\RequestOptions. - * - * @return Promise\PromiseInterface - */ - public function requestAsync($method, $uri = '', array $options = []) - { - $options = $this->prepareDefaults($options); - // Remove request modifying parameter because it can be done up-front. - $headers = isset($options['headers']) ? $options['headers'] : []; - $body = isset($options['body']) ? $options['body'] : null; - $version = isset($options['version']) ? $options['version'] : '1.1'; - // Merge the URI into the base URI. - $uri = $this->buildUri($uri, $options); - if (\is_array($body)) { - $this->invalidBody(); - } - $request = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Request($method, $uri, $headers, $body, $version); - // Remove the option so that they are not doubly-applied. - unset($options['headers'], $options['body'], $options['version']); - return $this->transfer($request, $options); - } - /** - * Create and send an HTTP request. - * - * Use an absolute path to override the base path of the client, or a - * relative path to append to the base path of the client. The URL can - * contain the query string as well. - * - * @param string $method HTTP method. - * @param string|UriInterface $uri URI object or string. - * @param array $options Request options to apply. See \GuzzleHttp\RequestOptions. - * - * @return ResponseInterface - * @throws GuzzleException - */ - public function request($method, $uri = '', array $options = []) - { - $options[\_PhpScoper5ea00cc67502b\GuzzleHttp\RequestOptions::SYNCHRONOUS] = \true; - return $this->requestAsync($method, $uri, $options)->wait(); - } - /** - * Get a client configuration option. - * - * These options include default request options of the client, a "handler" - * (if utilized by the concrete client), and a "base_uri" if utilized by - * the concrete client. - * - * @param string|null $option The config option to retrieve. - * - * @return mixed - */ - public function getConfig($option = null) - { - return $option === null ? $this->config : (isset($this->config[$option]) ? $this->config[$option] : null); - } - /** - * @param string|null $uri - * - * @return UriInterface - */ - private function buildUri($uri, array $config) - { - // for BC we accept null which would otherwise fail in uri_for - $uri = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\uri_for($uri === null ? '' : $uri); - if (isset($config['base_uri'])) { - $uri = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::resolve(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\uri_for($config['base_uri']), $uri); - } - if (isset($config['idn_conversion']) && $config['idn_conversion'] !== \false) { - $idnOptions = $config['idn_conversion'] === \true ? \IDNA_DEFAULT : $config['idn_conversion']; - $uri = \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::idnUriConvert($uri, $idnOptions); - } - return $uri->getScheme() === '' && $uri->getHost() !== '' ? $uri->withScheme('http') : $uri; - } - /** - * Configures the default options for a client. - * - * @param array $config - * @return void - */ - private function configureDefaults(array $config) - { - $defaults = ['allow_redirects' => \_PhpScoper5ea00cc67502b\GuzzleHttp\RedirectMiddleware::$defaultSettings, 'http_errors' => \true, 'decode_content' => \true, 'verify' => \true, 'cookies' => \false, 'idn_conversion' => \true]; - // Use the standard Linux HTTP_PROXY and HTTPS_PROXY if set. - // We can only trust the HTTP_PROXY environment variable in a CLI - // process due to the fact that PHP has no reliable mechanism to - // get environment variables that start with "HTTP_". - if (\php_sapi_name() === 'cli' && \getenv('HTTP_PROXY')) { - $defaults['proxy']['http'] = \getenv('HTTP_PROXY'); - } - if ($proxy = \getenv('HTTPS_PROXY')) { - $defaults['proxy']['https'] = $proxy; - } - if ($noProxy = \getenv('NO_PROXY')) { - $cleanedNoProxy = \str_replace(' ', '', $noProxy); - $defaults['proxy']['no'] = \explode(',', $cleanedNoProxy); - } - $this->config = $config + $defaults; - if (!empty($config['cookies']) && $config['cookies'] === \true) { - $this->config['cookies'] = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\CookieJar(); - } - // Add the default user-agent header. - if (!isset($this->config['headers'])) { - $this->config['headers'] = ['User-Agent' => default_user_agent()]; - } else { - // Add the User-Agent header if one was not already set. - foreach (\array_keys($this->config['headers']) as $name) { - if (\strtolower($name) === 'user-agent') { - return; - } - } - $this->config['headers']['User-Agent'] = default_user_agent(); - } - } - /** - * Merges default options into the array. - * - * @param array $options Options to modify by reference - * - * @return array - */ - private function prepareDefaults(array $options) - { - $defaults = $this->config; - if (!empty($defaults['headers'])) { - // Default headers are only added if they are not present. - $defaults['_conditional'] = $defaults['headers']; - unset($defaults['headers']); - } - // Special handling for headers is required as they are added as - // conditional headers and as headers passed to a request ctor. - if (\array_key_exists('headers', $options)) { - // Allows default headers to be unset. - if ($options['headers'] === null) { - $defaults['_conditional'] = []; - unset($options['headers']); - } elseif (!\is_array($options['headers'])) { - throw new \InvalidArgumentException('headers must be an array'); - } - } - // Shallow merge defaults underneath options. - $result = $options + $defaults; - // Remove null values. - foreach ($result as $k => $v) { - if ($v === null) { - unset($result[$k]); - } - } - return $result; - } - /** - * Transfers the given request and applies request options. - * - * The URI of the request is not modified and the request options are used - * as-is without merging in default options. - * - * @param array $options See \GuzzleHttp\RequestOptions. - * - * @return Promise\PromiseInterface - */ - private function transfer(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - // save_to -> sink - if (isset($options['save_to'])) { - $options['sink'] = $options['save_to']; - unset($options['save_to']); - } - // exceptions -> http_errors - if (isset($options['exceptions'])) { - $options['http_errors'] = $options['exceptions']; - unset($options['exceptions']); - } - $request = $this->applyOptions($request, $options); - /** @var HandlerStack $handler */ - $handler = $options['handler']; - try { - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\promise_for($handler($request, $options)); - } catch (\Exception $e) { - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($e); - } - } - /** - * Applies the array of request options to a request. - * - * @param RequestInterface $request - * @param array $options - * - * @return RequestInterface - */ - private function applyOptions(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array &$options) - { - $modify = ['set_headers' => []]; - if (isset($options['headers'])) { - $modify['set_headers'] = $options['headers']; - unset($options['headers']); - } - if (isset($options['form_params'])) { - if (isset($options['multipart'])) { - throw new \InvalidArgumentException('You cannot use ' . 'form_params and multipart at the same time. Use the ' . 'form_params option if you want to send application/' . 'x-www-form-urlencoded requests, and the multipart ' . 'option to send multipart/form-data requests.'); - } - $options['body'] = \http_build_query($options['form_params'], '', '&'); - unset($options['form_params']); - // Ensure that we don't have the header in different case and set the new value. - $options['_conditional'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\_caseless_remove(['Content-Type'], $options['_conditional']); - $options['_conditional']['Content-Type'] = 'application/x-www-form-urlencoded'; - } - if (isset($options['multipart'])) { - $options['body'] = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\MultipartStream($options['multipart']); - unset($options['multipart']); - } - if (isset($options['json'])) { - $options['body'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\json_encode($options['json']); - unset($options['json']); - // Ensure that we don't have the header in different case and set the new value. - $options['_conditional'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\_caseless_remove(['Content-Type'], $options['_conditional']); - $options['_conditional']['Content-Type'] = 'application/json'; - } - if (!empty($options['decode_content']) && $options['decode_content'] !== \true) { - // Ensure that we don't have the header in different case and set the new value. - $options['_conditional'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\_caseless_remove(['Accept-Encoding'], $options['_conditional']); - $modify['set_headers']['Accept-Encoding'] = $options['decode_content']; - } - if (isset($options['body'])) { - if (\is_array($options['body'])) { - $this->invalidBody(); - } - $modify['body'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($options['body']); - unset($options['body']); - } - if (!empty($options['auth']) && \is_array($options['auth'])) { - $value = $options['auth']; - $type = isset($value[2]) ? \strtolower($value[2]) : 'basic'; - switch ($type) { - case 'basic': - // Ensure that we don't have the header in different case and set the new value. - $modify['set_headers'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\_caseless_remove(['Authorization'], $modify['set_headers']); - $modify['set_headers']['Authorization'] = 'Basic ' . \base64_encode("{$value[0]}:{$value[1]}"); - break; - case 'digest': - // @todo: Do not rely on curl - $options['curl'][\CURLOPT_HTTPAUTH] = \CURLAUTH_DIGEST; - $options['curl'][\CURLOPT_USERPWD] = "{$value[0]}:{$value[1]}"; - break; - case 'ntlm': - $options['curl'][\CURLOPT_HTTPAUTH] = \CURLAUTH_NTLM; - $options['curl'][\CURLOPT_USERPWD] = "{$value[0]}:{$value[1]}"; - break; - } - } - if (isset($options['query'])) { - $value = $options['query']; - if (\is_array($value)) { - $value = \http_build_query($value, null, '&', \PHP_QUERY_RFC3986); - } - if (!\is_string($value)) { - throw new \InvalidArgumentException('query must be a string or array'); - } - $modify['query'] = $value; - unset($options['query']); - } - // Ensure that sink is not an invalid value. - if (isset($options['sink'])) { - // TODO: Add more sink validation? - if (\is_bool($options['sink'])) { - throw new \InvalidArgumentException('sink must not be a boolean'); - } - } - $request = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\modify_request($request, $modify); - if ($request->getBody() instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\MultipartStream) { - // Use a multipart/form-data POST if a Content-Type is not set. - // Ensure that we don't have the header in different case and set the new value. - $options['_conditional'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\_caseless_remove(['Content-Type'], $options['_conditional']); - $options['_conditional']['Content-Type'] = 'multipart/form-data; boundary=' . $request->getBody()->getBoundary(); - } - // Merge in conditional headers if they are not present. - if (isset($options['_conditional'])) { - // Build up the changes so it's in a single clone of the message. - $modify = []; - foreach ($options['_conditional'] as $k => $v) { - if (!$request->hasHeader($k)) { - $modify['set_headers'][$k] = $v; - } - } - $request = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\modify_request($request, $modify); - // Don't pass this internal value along to middleware/handlers. - unset($options['_conditional']); - } - return $request; - } - /** - * Throw Exception with pre-set message. - * @return void - * @throws InvalidArgumentException Invalid body. - */ - private function invalidBody() - { - throw new \InvalidArgumentException('Passing in the "body" request ' . 'option as an array to send a POST request has been deprecated. ' . 'Please use the "form_params" request option to send a ' . 'application/x-www-form-urlencoded request, or the "multipart" ' . 'request option to send a multipart/form-data request.'); - } -} + 'http://www.foo.com/1.0/', + * 'timeout' => 0, + * 'allow_redirects' => false, + * 'proxy' => '192.168.16.1:10' + * ]); + * + * Client configuration settings include the following options: + * + * - handler: (callable) Function that transfers HTTP requests over the + * wire. The function is called with a Psr7\Http\Message\RequestInterface + * and array of transfer options, and must return a + * GuzzleHttp\Promise\PromiseInterface that is fulfilled with a + * Psr7\Http\Message\ResponseInterface on success. "handler" is a + * constructor only option that cannot be overridden in per/request + * options. If no handler is provided, a default handler will be created + * that enables all of the request options below by attaching all of the + * default middleware to the handler. + * - base_uri: (string|UriInterface) Base URI of the client that is merged + * into relative URIs. Can be a string or instance of UriInterface. + * - **: any request option + * + * @param array $config Client configuration settings. + * + * @see \GuzzleHttp\RequestOptions for a list of available request options. + */ + public function __construct(array $config = []) + { + if (!isset($config['handler'])) { + $config['handler'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\HandlerStack::create(); + } elseif (!\is_callable($config['handler'])) { + throw new \InvalidArgumentException('handler must be a callable'); + } + // Convert the base_uri to a UriInterface + if (isset($config['base_uri'])) { + $config['base_uri'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\uri_for($config['base_uri']); + } + $this->configureDefaults($config); + } + /** + * @param string $method + * @param array $args + * + * @return Promise\PromiseInterface + */ + public function __call($method, $args) + { + if (\count($args) < 1) { + throw new \InvalidArgumentException('Magic request methods require a URI and optional options array'); + } + $uri = $args[0]; + $opts = isset($args[1]) ? $args[1] : []; + return \substr($method, -5) === 'Async' ? $this->requestAsync(\substr($method, 0, -5), $uri, $opts) : $this->request($method, $uri, $opts); + } + /** + * Asynchronously send an HTTP request. + * + * @param array $options Request options to apply to the given + * request and to the transfer. See \GuzzleHttp\RequestOptions. + * + * @return Promise\PromiseInterface + */ + public function sendAsync(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options = []) + { + // Merge the base URI into the request URI if needed. + $options = $this->prepareDefaults($options); + return $this->transfer($request->withUri($this->buildUri($request->getUri(), $options), $request->hasHeader('Host')), $options); + } + /** + * Send an HTTP request. + * + * @param array $options Request options to apply to the given + * request and to the transfer. See \GuzzleHttp\RequestOptions. + * + * @return ResponseInterface + * @throws GuzzleException + */ + public function send(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options = []) + { + $options[\_PhpScoper5ea00cc67502b\GuzzleHttp\RequestOptions::SYNCHRONOUS] = \true; + return $this->sendAsync($request, $options)->wait(); + } + /** + * Create and send an asynchronous HTTP request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. Use an array to provide a URL + * template and additional variables to use in the URL template expansion. + * + * @param string $method HTTP method + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. See \GuzzleHttp\RequestOptions. + * + * @return Promise\PromiseInterface + */ + public function requestAsync($method, $uri = '', array $options = []) + { + $options = $this->prepareDefaults($options); + // Remove request modifying parameter because it can be done up-front. + $headers = isset($options['headers']) ? $options['headers'] : []; + $body = isset($options['body']) ? $options['body'] : null; + $version = isset($options['version']) ? $options['version'] : '1.1'; + // Merge the URI into the base URI. + $uri = $this->buildUri($uri, $options); + if (\is_array($body)) { + $this->invalidBody(); + } + $request = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Request($method, $uri, $headers, $body, $version); + // Remove the option so that they are not doubly-applied. + unset($options['headers'], $options['body'], $options['version']); + return $this->transfer($request, $options); + } + /** + * Create and send an HTTP request. + * + * Use an absolute path to override the base path of the client, or a + * relative path to append to the base path of the client. The URL can + * contain the query string as well. + * + * @param string $method HTTP method. + * @param string|UriInterface $uri URI object or string. + * @param array $options Request options to apply. See \GuzzleHttp\RequestOptions. + * + * @return ResponseInterface + * @throws GuzzleException + */ + public function request($method, $uri = '', array $options = []) + { + $options[\_PhpScoper5ea00cc67502b\GuzzleHttp\RequestOptions::SYNCHRONOUS] = \true; + return $this->requestAsync($method, $uri, $options)->wait(); + } + /** + * Get a client configuration option. + * + * These options include default request options of the client, a "handler" + * (if utilized by the concrete client), and a "base_uri" if utilized by + * the concrete client. + * + * @param string|null $option The config option to retrieve. + * + * @return mixed + */ + public function getConfig($option = null) + { + return $option === null ? $this->config : (isset($this->config[$option]) ? $this->config[$option] : null); + } + /** + * @param string|null $uri + * + * @return UriInterface + */ + private function buildUri($uri, array $config) + { + // for BC we accept null which would otherwise fail in uri_for + $uri = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\uri_for($uri === null ? '' : $uri); + if (isset($config['base_uri'])) { + $uri = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::resolve(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\uri_for($config['base_uri']), $uri); + } + if (isset($config['idn_conversion']) && $config['idn_conversion'] !== \false) { + $idnOptions = $config['idn_conversion'] === \true ? \IDNA_DEFAULT : $config['idn_conversion']; + $uri = \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::idnUriConvert($uri, $idnOptions); + } + return $uri->getScheme() === '' && $uri->getHost() !== '' ? $uri->withScheme('http') : $uri; + } + /** + * Configures the default options for a client. + * + * @param array $config + * @return void + */ + private function configureDefaults(array $config) + { + $defaults = ['allow_redirects' => \_PhpScoper5ea00cc67502b\GuzzleHttp\RedirectMiddleware::$defaultSettings, 'http_errors' => \true, 'decode_content' => \true, 'verify' => \true, 'cookies' => \false, 'idn_conversion' => \true]; + // Use the standard Linux HTTP_PROXY and HTTPS_PROXY if set. + // We can only trust the HTTP_PROXY environment variable in a CLI + // process due to the fact that PHP has no reliable mechanism to + // get environment variables that start with "HTTP_". + if (\php_sapi_name() === 'cli' && \getenv('HTTP_PROXY')) { + $defaults['proxy']['http'] = \getenv('HTTP_PROXY'); + } + if ($proxy = \getenv('HTTPS_PROXY')) { + $defaults['proxy']['https'] = $proxy; + } + if ($noProxy = \getenv('NO_PROXY')) { + $cleanedNoProxy = \str_replace(' ', '', $noProxy); + $defaults['proxy']['no'] = \explode(',', $cleanedNoProxy); + } + $this->config = $config + $defaults; + if (!empty($config['cookies']) && $config['cookies'] === \true) { + $this->config['cookies'] = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\CookieJar(); + } + // Add the default user-agent header. + if (!isset($this->config['headers'])) { + $this->config['headers'] = ['User-Agent' => default_user_agent()]; + } else { + // Add the User-Agent header if one was not already set. + foreach (\array_keys($this->config['headers']) as $name) { + if (\strtolower($name) === 'user-agent') { + return; + } + } + $this->config['headers']['User-Agent'] = default_user_agent(); + } + } + /** + * Merges default options into the array. + * + * @param array $options Options to modify by reference + * + * @return array + */ + private function prepareDefaults(array $options) + { + $defaults = $this->config; + if (!empty($defaults['headers'])) { + // Default headers are only added if they are not present. + $defaults['_conditional'] = $defaults['headers']; + unset($defaults['headers']); + } + // Special handling for headers is required as they are added as + // conditional headers and as headers passed to a request ctor. + if (\array_key_exists('headers', $options)) { + // Allows default headers to be unset. + if ($options['headers'] === null) { + $defaults['_conditional'] = []; + unset($options['headers']); + } elseif (!\is_array($options['headers'])) { + throw new \InvalidArgumentException('headers must be an array'); + } + } + // Shallow merge defaults underneath options. + $result = $options + $defaults; + // Remove null values. + foreach ($result as $k => $v) { + if ($v === null) { + unset($result[$k]); + } + } + return $result; + } + /** + * Transfers the given request and applies request options. + * + * The URI of the request is not modified and the request options are used + * as-is without merging in default options. + * + * @param array $options See \GuzzleHttp\RequestOptions. + * + * @return Promise\PromiseInterface + */ + private function transfer(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + // save_to -> sink + if (isset($options['save_to'])) { + $options['sink'] = $options['save_to']; + unset($options['save_to']); + } + // exceptions -> http_errors + if (isset($options['exceptions'])) { + $options['http_errors'] = $options['exceptions']; + unset($options['exceptions']); + } + $request = $this->applyOptions($request, $options); + /** @var HandlerStack $handler */ + $handler = $options['handler']; + try { + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\promise_for($handler($request, $options)); + } catch (\Exception $e) { + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($e); + } + } + /** + * Applies the array of request options to a request. + * + * @param RequestInterface $request + * @param array $options + * + * @return RequestInterface + */ + private function applyOptions(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array &$options) + { + $modify = ['set_headers' => []]; + if (isset($options['headers'])) { + $modify['set_headers'] = $options['headers']; + unset($options['headers']); + } + if (isset($options['form_params'])) { + if (isset($options['multipart'])) { + throw new \InvalidArgumentException('You cannot use ' . 'form_params and multipart at the same time. Use the ' . 'form_params option if you want to send application/' . 'x-www-form-urlencoded requests, and the multipart ' . 'option to send multipart/form-data requests.'); + } + $options['body'] = \http_build_query($options['form_params'], '', '&'); + unset($options['form_params']); + // Ensure that we don't have the header in different case and set the new value. + $options['_conditional'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\_caseless_remove(['Content-Type'], $options['_conditional']); + $options['_conditional']['Content-Type'] = 'application/x-www-form-urlencoded'; + } + if (isset($options['multipart'])) { + $options['body'] = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\MultipartStream($options['multipart']); + unset($options['multipart']); + } + if (isset($options['json'])) { + $options['body'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\json_encode($options['json']); + unset($options['json']); + // Ensure that we don't have the header in different case and set the new value. + $options['_conditional'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\_caseless_remove(['Content-Type'], $options['_conditional']); + $options['_conditional']['Content-Type'] = 'application/json'; + } + if (!empty($options['decode_content']) && $options['decode_content'] !== \true) { + // Ensure that we don't have the header in different case and set the new value. + $options['_conditional'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\_caseless_remove(['Accept-Encoding'], $options['_conditional']); + $modify['set_headers']['Accept-Encoding'] = $options['decode_content']; + } + if (isset($options['body'])) { + if (\is_array($options['body'])) { + $this->invalidBody(); + } + $modify['body'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($options['body']); + unset($options['body']); + } + if (!empty($options['auth']) && \is_array($options['auth'])) { + $value = $options['auth']; + $type = isset($value[2]) ? \strtolower($value[2]) : 'basic'; + switch ($type) { + case 'basic': + // Ensure that we don't have the header in different case and set the new value. + $modify['set_headers'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\_caseless_remove(['Authorization'], $modify['set_headers']); + $modify['set_headers']['Authorization'] = 'Basic ' . \base64_encode("{$value[0]}:{$value[1]}"); + break; + case 'digest': + // @todo: Do not rely on curl + $options['curl'][\CURLOPT_HTTPAUTH] = \CURLAUTH_DIGEST; + $options['curl'][\CURLOPT_USERPWD] = "{$value[0]}:{$value[1]}"; + break; + case 'ntlm': + $options['curl'][\CURLOPT_HTTPAUTH] = \CURLAUTH_NTLM; + $options['curl'][\CURLOPT_USERPWD] = "{$value[0]}:{$value[1]}"; + break; + } + } + if (isset($options['query'])) { + $value = $options['query']; + if (\is_array($value)) { + $value = \http_build_query($value, null, '&', \PHP_QUERY_RFC3986); + } + if (!\is_string($value)) { + throw new \InvalidArgumentException('query must be a string or array'); + } + $modify['query'] = $value; + unset($options['query']); + } + // Ensure that sink is not an invalid value. + if (isset($options['sink'])) { + // TODO: Add more sink validation? + if (\is_bool($options['sink'])) { + throw new \InvalidArgumentException('sink must not be a boolean'); + } + } + $request = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\modify_request($request, $modify); + if ($request->getBody() instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\MultipartStream) { + // Use a multipart/form-data POST if a Content-Type is not set. + // Ensure that we don't have the header in different case and set the new value. + $options['_conditional'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\_caseless_remove(['Content-Type'], $options['_conditional']); + $options['_conditional']['Content-Type'] = 'multipart/form-data; boundary=' . $request->getBody()->getBoundary(); + } + // Merge in conditional headers if they are not present. + if (isset($options['_conditional'])) { + // Build up the changes so it's in a single clone of the message. + $modify = []; + foreach ($options['_conditional'] as $k => $v) { + if (!$request->hasHeader($k)) { + $modify['set_headers'][$k] = $v; + } + } + $request = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\modify_request($request, $modify); + // Don't pass this internal value along to middleware/handlers. + unset($options['_conditional']); + } + return $request; + } + /** + * Throw Exception with pre-set message. + * @return void + * @throws InvalidArgumentException Invalid body. + */ + private function invalidBody() + { + throw new \InvalidArgumentException('Passing in the "body" request ' . 'option as an array to send a POST request has been deprecated. ' . 'Please use the "form_params" request option to send a ' . 'application/x-www-form-urlencoded request, or the "multipart" ' . 'request option to send a multipart/form-data request.'); + } +} diff --git a/vendor/guzzlehttp/guzzle/src/ClientInterface.php b/vendor/guzzlehttp/guzzle/src/ClientInterface.php index a92997ded..8d4542322 100644 --- a/vendor/guzzlehttp/guzzle/src/ClientInterface.php +++ b/vendor/guzzlehttp/guzzle/src/ClientInterface.php @@ -1,82 +1,82 @@ -strictMode = $strictMode; - foreach ($cookieArray as $cookie) { - if (!$cookie instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie) { - $cookie = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie($cookie); - } - $this->setCookie($cookie); - } - } - /** - * Create a new Cookie jar from an associative array and domain. - * - * @param array $cookies Cookies to create the jar from - * @param string $domain Domain to set the cookies to - * - * @return self - */ - public static function fromArray(array $cookies, $domain) - { - $cookieJar = new self(); - foreach ($cookies as $name => $value) { - $cookieJar->setCookie(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie(['Domain' => $domain, 'Name' => $name, 'Value' => $value, 'Discard' => \true])); - } - return $cookieJar; - } - /** - * @deprecated - */ - public static function getCookieValue($value) - { - return $value; - } - /** - * Evaluate if this cookie should be persisted to storage - * that survives between requests. - * - * @param SetCookie $cookie Being evaluated. - * @param bool $allowSessionCookies If we should persist session cookies - * @return bool - */ - public static function shouldPersist(\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie, $allowSessionCookies = \false) - { - if ($cookie->getExpires() || $allowSessionCookies) { - if (!$cookie->getDiscard()) { - return \true; - } - } - return \false; - } - /** - * Finds and returns the cookie based on the name - * - * @param string $name cookie name to search for - * @return SetCookie|null cookie that was found or null if not found - */ - public function getCookieByName($name) - { - // don't allow a non string name - if ($name === null || !\is_scalar($name)) { - return null; - } - foreach ($this->cookies as $cookie) { - if ($cookie->getName() !== null && \strcasecmp($cookie->getName(), $name) === 0) { - return $cookie; - } - } - return null; - } - public function toArray() - { - return \array_map(function (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) { - return $cookie->toArray(); - }, $this->getIterator()->getArrayCopy()); - } - public function clear($domain = null, $path = null, $name = null) - { - if (!$domain) { - $this->cookies = []; - return; - } elseif (!$path) { - $this->cookies = \array_filter($this->cookies, function (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) use($domain) { - return !$cookie->matchesDomain($domain); - }); - } elseif (!$name) { - $this->cookies = \array_filter($this->cookies, function (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) use($path, $domain) { - return !($cookie->matchesPath($path) && $cookie->matchesDomain($domain)); - }); - } else { - $this->cookies = \array_filter($this->cookies, function (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) use($path, $domain, $name) { - return !($cookie->getName() == $name && $cookie->matchesPath($path) && $cookie->matchesDomain($domain)); - }); - } - } - public function clearSessionCookies() - { - $this->cookies = \array_filter($this->cookies, function (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) { - return !$cookie->getDiscard() && $cookie->getExpires(); - }); - } - public function setCookie(\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) - { - // If the name string is empty (but not 0), ignore the set-cookie - // string entirely. - $name = $cookie->getName(); - if (!$name && $name !== '0') { - return \false; - } - // Only allow cookies with set and valid domain, name, value - $result = $cookie->validate(); - if ($result !== \true) { - if ($this->strictMode) { - throw new \RuntimeException('Invalid cookie: ' . $result); - } else { - $this->removeCookieIfEmpty($cookie); - return \false; - } - } - // Resolve conflicts with previously set cookies - foreach ($this->cookies as $i => $c) { - // Two cookies are identical, when their path, and domain are - // identical. - if ($c->getPath() != $cookie->getPath() || $c->getDomain() != $cookie->getDomain() || $c->getName() != $cookie->getName()) { - continue; - } - // The previously set cookie is a discard cookie and this one is - // not so allow the new cookie to be set - if (!$cookie->getDiscard() && $c->getDiscard()) { - unset($this->cookies[$i]); - continue; - } - // If the new cookie's expiration is further into the future, then - // replace the old cookie - if ($cookie->getExpires() > $c->getExpires()) { - unset($this->cookies[$i]); - continue; - } - // If the value has changed, we better change it - if ($cookie->getValue() !== $c->getValue()) { - unset($this->cookies[$i]); - continue; - } - // The cookie exists, so no need to continue - return \false; - } - $this->cookies[] = $cookie; - return \true; - } - public function count() - { - return \count($this->cookies); - } - public function getIterator() - { - return new \ArrayIterator(\array_values($this->cookies)); - } - public function extractCookies(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) - { - if ($cookieHeader = $response->getHeader('Set-Cookie')) { - foreach ($cookieHeader as $cookie) { - $sc = \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie::fromString($cookie); - if (!$sc->getDomain()) { - $sc->setDomain($request->getUri()->getHost()); - } - if (0 !== \strpos($sc->getPath(), '/')) { - $sc->setPath($this->getCookiePathFromRequest($request)); - } - $this->setCookie($sc); - } - } - } - /** - * Computes cookie path following RFC 6265 section 5.1.4 - * - * @link https://tools.ietf.org/html/rfc6265#section-5.1.4 - * - * @param RequestInterface $request - * @return string - */ - private function getCookiePathFromRequest(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request) - { - $uriPath = $request->getUri()->getPath(); - if ('' === $uriPath) { - return '/'; - } - if (0 !== \strpos($uriPath, '/')) { - return '/'; - } - if ('/' === $uriPath) { - return '/'; - } - if (0 === ($lastSlashPos = \strrpos($uriPath, '/'))) { - return '/'; - } - return \substr($uriPath, 0, $lastSlashPos); - } - public function withCookieHeader(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request) - { - $values = []; - $uri = $request->getUri(); - $scheme = $uri->getScheme(); - $host = $uri->getHost(); - $path = $uri->getPath() ?: '/'; - foreach ($this->cookies as $cookie) { - if ($cookie->matchesPath($path) && $cookie->matchesDomain($host) && !$cookie->isExpired() && (!$cookie->getSecure() || $scheme === 'https')) { - $values[] = $cookie->getName() . '=' . $cookie->getValue(); - } - } - return $values ? $request->withHeader('Cookie', \implode('; ', $values)) : $request; - } - /** - * If a cookie already exists and the server asks to set it again with a - * null value, the cookie must be deleted. - * - * @param SetCookie $cookie - */ - private function removeCookieIfEmpty(\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) - { - $cookieValue = $cookie->getValue(); - if ($cookieValue === null || $cookieValue === '') { - $this->clear($cookie->getDomain(), $cookie->getPath(), $cookie->getName()); - } - } -} +strictMode = $strictMode; + foreach ($cookieArray as $cookie) { + if (!$cookie instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie) { + $cookie = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie($cookie); + } + $this->setCookie($cookie); + } + } + /** + * Create a new Cookie jar from an associative array and domain. + * + * @param array $cookies Cookies to create the jar from + * @param string $domain Domain to set the cookies to + * + * @return self + */ + public static function fromArray(array $cookies, $domain) + { + $cookieJar = new self(); + foreach ($cookies as $name => $value) { + $cookieJar->setCookie(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie(['Domain' => $domain, 'Name' => $name, 'Value' => $value, 'Discard' => \true])); + } + return $cookieJar; + } + /** + * @deprecated + */ + public static function getCookieValue($value) + { + return $value; + } + /** + * Evaluate if this cookie should be persisted to storage + * that survives between requests. + * + * @param SetCookie $cookie Being evaluated. + * @param bool $allowSessionCookies If we should persist session cookies + * @return bool + */ + public static function shouldPersist(\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie, $allowSessionCookies = \false) + { + if ($cookie->getExpires() || $allowSessionCookies) { + if (!$cookie->getDiscard()) { + return \true; + } + } + return \false; + } + /** + * Finds and returns the cookie based on the name + * + * @param string $name cookie name to search for + * @return SetCookie|null cookie that was found or null if not found + */ + public function getCookieByName($name) + { + // don't allow a non string name + if ($name === null || !\is_scalar($name)) { + return null; + } + foreach ($this->cookies as $cookie) { + if ($cookie->getName() !== null && \strcasecmp($cookie->getName(), $name) === 0) { + return $cookie; + } + } + return null; + } + public function toArray() + { + return \array_map(function (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) { + return $cookie->toArray(); + }, $this->getIterator()->getArrayCopy()); + } + public function clear($domain = null, $path = null, $name = null) + { + if (!$domain) { + $this->cookies = []; + return; + } elseif (!$path) { + $this->cookies = \array_filter($this->cookies, function (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) use($domain) { + return !$cookie->matchesDomain($domain); + }); + } elseif (!$name) { + $this->cookies = \array_filter($this->cookies, function (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) use($path, $domain) { + return !($cookie->matchesPath($path) && $cookie->matchesDomain($domain)); + }); + } else { + $this->cookies = \array_filter($this->cookies, function (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) use($path, $domain, $name) { + return !($cookie->getName() == $name && $cookie->matchesPath($path) && $cookie->matchesDomain($domain)); + }); + } + } + public function clearSessionCookies() + { + $this->cookies = \array_filter($this->cookies, function (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) { + return !$cookie->getDiscard() && $cookie->getExpires(); + }); + } + public function setCookie(\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) + { + // If the name string is empty (but not 0), ignore the set-cookie + // string entirely. + $name = $cookie->getName(); + if (!$name && $name !== '0') { + return \false; + } + // Only allow cookies with set and valid domain, name, value + $result = $cookie->validate(); + if ($result !== \true) { + if ($this->strictMode) { + throw new \RuntimeException('Invalid cookie: ' . $result); + } else { + $this->removeCookieIfEmpty($cookie); + return \false; + } + } + // Resolve conflicts with previously set cookies + foreach ($this->cookies as $i => $c) { + // Two cookies are identical, when their path, and domain are + // identical. + if ($c->getPath() != $cookie->getPath() || $c->getDomain() != $cookie->getDomain() || $c->getName() != $cookie->getName()) { + continue; + } + // The previously set cookie is a discard cookie and this one is + // not so allow the new cookie to be set + if (!$cookie->getDiscard() && $c->getDiscard()) { + unset($this->cookies[$i]); + continue; + } + // If the new cookie's expiration is further into the future, then + // replace the old cookie + if ($cookie->getExpires() > $c->getExpires()) { + unset($this->cookies[$i]); + continue; + } + // If the value has changed, we better change it + if ($cookie->getValue() !== $c->getValue()) { + unset($this->cookies[$i]); + continue; + } + // The cookie exists, so no need to continue + return \false; + } + $this->cookies[] = $cookie; + return \true; + } + public function count() + { + return \count($this->cookies); + } + public function getIterator() + { + return new \ArrayIterator(\array_values($this->cookies)); + } + public function extractCookies(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) + { + if ($cookieHeader = $response->getHeader('Set-Cookie')) { + foreach ($cookieHeader as $cookie) { + $sc = \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie::fromString($cookie); + if (!$sc->getDomain()) { + $sc->setDomain($request->getUri()->getHost()); + } + if (0 !== \strpos($sc->getPath(), '/')) { + $sc->setPath($this->getCookiePathFromRequest($request)); + } + $this->setCookie($sc); + } + } + } + /** + * Computes cookie path following RFC 6265 section 5.1.4 + * + * @link https://tools.ietf.org/html/rfc6265#section-5.1.4 + * + * @param RequestInterface $request + * @return string + */ + private function getCookiePathFromRequest(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request) + { + $uriPath = $request->getUri()->getPath(); + if ('' === $uriPath) { + return '/'; + } + if (0 !== \strpos($uriPath, '/')) { + return '/'; + } + if ('/' === $uriPath) { + return '/'; + } + if (0 === ($lastSlashPos = \strrpos($uriPath, '/'))) { + return '/'; + } + return \substr($uriPath, 0, $lastSlashPos); + } + public function withCookieHeader(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request) + { + $values = []; + $uri = $request->getUri(); + $scheme = $uri->getScheme(); + $host = $uri->getHost(); + $path = $uri->getPath() ?: '/'; + foreach ($this->cookies as $cookie) { + if ($cookie->matchesPath($path) && $cookie->matchesDomain($host) && !$cookie->isExpired() && (!$cookie->getSecure() || $scheme === 'https')) { + $values[] = $cookie->getName() . '=' . $cookie->getValue(); + } + } + return $values ? $request->withHeader('Cookie', \implode('; ', $values)) : $request; + } + /** + * If a cookie already exists and the server asks to set it again with a + * null value, the cookie must be deleted. + * + * @param SetCookie $cookie + */ + private function removeCookieIfEmpty(\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie $cookie) + { + $cookieValue = $cookie->getValue(); + if ($cookieValue === null || $cookieValue === '') { + $this->clear($cookie->getDomain(), $cookie->getPath(), $cookie->getName()); + } + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php b/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php index 5070e6020..601130bdd 100644 --- a/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php +++ b/vendor/guzzlehttp/guzzle/src/Cookie/CookieJarInterface.php @@ -1,76 +1,76 @@ -filename = $cookieFile; - $this->storeSessionCookies = $storeSessionCookies; - if (\file_exists($cookieFile)) { - $this->load($cookieFile); - } - } - /** - * Saves the file when shutting down - */ - public function __destruct() - { - $this->save($this->filename); - } - /** - * Saves the cookies to a file. - * - * @param string $filename File to save - * @throws \RuntimeException if the file cannot be found or created - */ - public function save($filename) - { - $json = []; - foreach ($this as $cookie) { - /** @var SetCookie $cookie */ - if (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\CookieJar::shouldPersist($cookie, $this->storeSessionCookies)) { - $json[] = $cookie->toArray(); - } - } - $jsonStr = \_PhpScoper5ea00cc67502b\GuzzleHttp\json_encode($json); - if (\false === \file_put_contents($filename, $jsonStr, \LOCK_EX)) { - throw new \RuntimeException("Unable to save file {$filename}"); - } - } - /** - * Load cookies from a JSON formatted file. - * - * Old cookies are kept unless overwritten by newly loaded ones. - * - * @param string $filename Cookie file to load. - * @throws \RuntimeException if the file cannot be loaded. - */ - public function load($filename) - { - $json = \file_get_contents($filename); - if (\false === $json) { - throw new \RuntimeException("Unable to load file {$filename}"); - } elseif ($json === '') { - return; - } - $data = \_PhpScoper5ea00cc67502b\GuzzleHttp\json_decode($json, \true); - if (\is_array($data)) { - foreach (\json_decode($json, \true) as $cookie) { - $this->setCookie(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie($cookie)); - } - } elseif (\strlen($data)) { - throw new \RuntimeException("Invalid cookie file: {$filename}"); - } - } -} +filename = $cookieFile; + $this->storeSessionCookies = $storeSessionCookies; + if (\file_exists($cookieFile)) { + $this->load($cookieFile); + } + } + /** + * Saves the file when shutting down + */ + public function __destruct() + { + $this->save($this->filename); + } + /** + * Saves the cookies to a file. + * + * @param string $filename File to save + * @throws \RuntimeException if the file cannot be found or created + */ + public function save($filename) + { + $json = []; + foreach ($this as $cookie) { + /** @var SetCookie $cookie */ + if (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\CookieJar::shouldPersist($cookie, $this->storeSessionCookies)) { + $json[] = $cookie->toArray(); + } + } + $jsonStr = \_PhpScoper5ea00cc67502b\GuzzleHttp\json_encode($json); + if (\false === \file_put_contents($filename, $jsonStr, \LOCK_EX)) { + throw new \RuntimeException("Unable to save file {$filename}"); + } + } + /** + * Load cookies from a JSON formatted file. + * + * Old cookies are kept unless overwritten by newly loaded ones. + * + * @param string $filename Cookie file to load. + * @throws \RuntimeException if the file cannot be loaded. + */ + public function load($filename) + { + $json = \file_get_contents($filename); + if (\false === $json) { + throw new \RuntimeException("Unable to load file {$filename}"); + } elseif ($json === '') { + return; + } + $data = \_PhpScoper5ea00cc67502b\GuzzleHttp\json_decode($json, \true); + if (\is_array($data)) { + foreach (\json_decode($json, \true) as $cookie) { + $this->setCookie(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie($cookie)); + } + } elseif (\strlen($data)) { + throw new \RuntimeException("Invalid cookie file: {$filename}"); + } + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php b/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php index f47ae310b..caf0bd2bf 100644 --- a/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php +++ b/vendor/guzzlehttp/guzzle/src/Cookie/SessionCookieJar.php @@ -1,67 +1,67 @@ -sessionKey = $sessionKey; - $this->storeSessionCookies = $storeSessionCookies; - $this->load(); - } - /** - * Saves cookies to session when shutting down - */ - public function __destruct() - { - $this->save(); - } - /** - * Save cookies to the client session - */ - public function save() - { - $json = []; - foreach ($this as $cookie) { - /** @var SetCookie $cookie */ - if (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\CookieJar::shouldPersist($cookie, $this->storeSessionCookies)) { - $json[] = $cookie->toArray(); - } - } - $_SESSION[$this->sessionKey] = \json_encode($json); - } - /** - * Load the contents of the client session into the data array - */ - protected function load() - { - if (!isset($_SESSION[$this->sessionKey])) { - return; - } - $data = \json_decode($_SESSION[$this->sessionKey], \true); - if (\is_array($data)) { - foreach ($data as $cookie) { - $this->setCookie(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie($cookie)); - } - } elseif (\strlen($data)) { - throw new \RuntimeException("Invalid cookie data"); - } - } -} +sessionKey = $sessionKey; + $this->storeSessionCookies = $storeSessionCookies; + $this->load(); + } + /** + * Saves cookies to session when shutting down + */ + public function __destruct() + { + $this->save(); + } + /** + * Save cookies to the client session + */ + public function save() + { + $json = []; + foreach ($this as $cookie) { + /** @var SetCookie $cookie */ + if (\_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\CookieJar::shouldPersist($cookie, $this->storeSessionCookies)) { + $json[] = $cookie->toArray(); + } + } + $_SESSION[$this->sessionKey] = \json_encode($json); + } + /** + * Load the contents of the client session into the data array + */ + protected function load() + { + if (!isset($_SESSION[$this->sessionKey])) { + return; + } + $data = \json_decode($_SESSION[$this->sessionKey], \true); + if (\is_array($data)) { + foreach ($data as $cookie) { + $this->setCookie(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Cookie\SetCookie($cookie)); + } + } elseif (\strlen($data)) { + throw new \RuntimeException("Invalid cookie data"); + } + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php b/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php index 8f6ba8082..249400aa7 100644 --- a/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php +++ b/vendor/guzzlehttp/guzzle/src/Cookie/SetCookie.php @@ -1,343 +1,343 @@ - null, 'Value' => null, 'Domain' => null, 'Path' => '/', 'Max-Age' => null, 'Expires' => null, 'Secure' => \false, 'Discard' => \false, 'HttpOnly' => \false]; - /** @var array Cookie data */ - private $data; - /** - * Create a new SetCookie object from a string - * - * @param string $cookie Set-Cookie header string - * - * @return self - */ - public static function fromString($cookie) - { - // Create the default return array - $data = self::$defaults; - // Explode the cookie string using a series of semicolons - $pieces = \array_filter(\array_map('trim', \explode(';', $cookie))); - // The name of the cookie (first kvp) must exist and include an equal sign. - if (empty($pieces[0]) || !\strpos($pieces[0], '=')) { - return new self($data); - } - // Add the cookie pieces into the parsed data array - foreach ($pieces as $part) { - $cookieParts = \explode('=', $part, 2); - $key = \trim($cookieParts[0]); - $value = isset($cookieParts[1]) ? \trim($cookieParts[1], " \n\r\t\0\v") : \true; - // Only check for non-cookies when cookies have been found - if (empty($data['Name'])) { - $data['Name'] = $key; - $data['Value'] = $value; - } else { - foreach (\array_keys(self::$defaults) as $search) { - if (!\strcasecmp($search, $key)) { - $data[$search] = $value; - continue 2; - } - } - $data[$key] = $value; - } - } - return new self($data); - } - /** - * @param array $data Array of cookie data provided by a Cookie parser - */ - public function __construct(array $data = []) - { - $this->data = \array_replace(self::$defaults, $data); - // Extract the Expires value and turn it into a UNIX timestamp if needed - if (!$this->getExpires() && $this->getMaxAge()) { - // Calculate the Expires date - $this->setExpires(\time() + $this->getMaxAge()); - } elseif ($this->getExpires() && !\is_numeric($this->getExpires())) { - $this->setExpires($this->getExpires()); - } - } - public function __toString() - { - $str = $this->data['Name'] . '=' . $this->data['Value'] . '; '; - foreach ($this->data as $k => $v) { - if ($k !== 'Name' && $k !== 'Value' && $v !== null && $v !== \false) { - if ($k === 'Expires') { - $str .= 'Expires=' . \gmdate('_PhpScoper5ea00cc67502b\\D, d M Y H:i:s \\G\\M\\T', $v) . '; '; - } else { - $str .= ($v === \true ? $k : "{$k}={$v}") . '; '; - } - } - } - return \rtrim($str, '; '); - } - public function toArray() - { - return $this->data; - } - /** - * Get the cookie name - * - * @return string - */ - public function getName() - { - return $this->data['Name']; - } - /** - * Set the cookie name - * - * @param string $name Cookie name - */ - public function setName($name) - { - $this->data['Name'] = $name; - } - /** - * Get the cookie value - * - * @return string - */ - public function getValue() - { - return $this->data['Value']; - } - /** - * Set the cookie value - * - * @param string $value Cookie value - */ - public function setValue($value) - { - $this->data['Value'] = $value; - } - /** - * Get the domain - * - * @return string|null - */ - public function getDomain() - { - return $this->data['Domain']; - } - /** - * Set the domain of the cookie - * - * @param string $domain - */ - public function setDomain($domain) - { - $this->data['Domain'] = $domain; - } - /** - * Get the path - * - * @return string - */ - public function getPath() - { - return $this->data['Path']; - } - /** - * Set the path of the cookie - * - * @param string $path Path of the cookie - */ - public function setPath($path) - { - $this->data['Path'] = $path; - } - /** - * Maximum lifetime of the cookie in seconds - * - * @return int|null - */ - public function getMaxAge() - { - return $this->data['Max-Age']; - } - /** - * Set the max-age of the cookie - * - * @param int $maxAge Max age of the cookie in seconds - */ - public function setMaxAge($maxAge) - { - $this->data['Max-Age'] = $maxAge; - } - /** - * The UNIX timestamp when the cookie Expires - * - * @return mixed - */ - public function getExpires() - { - return $this->data['Expires']; - } - /** - * Set the unix timestamp for which the cookie will expire - * - * @param int $timestamp Unix timestamp - */ - public function setExpires($timestamp) - { - $this->data['Expires'] = \is_numeric($timestamp) ? (int) $timestamp : \strtotime($timestamp); - } - /** - * Get whether or not this is a secure cookie - * - * @return bool|null - */ - public function getSecure() - { - return $this->data['Secure']; - } - /** - * Set whether or not the cookie is secure - * - * @param bool $secure Set to true or false if secure - */ - public function setSecure($secure) - { - $this->data['Secure'] = $secure; - } - /** - * Get whether or not this is a session cookie - * - * @return bool|null - */ - public function getDiscard() - { - return $this->data['Discard']; - } - /** - * Set whether or not this is a session cookie - * - * @param bool $discard Set to true or false if this is a session cookie - */ - public function setDiscard($discard) - { - $this->data['Discard'] = $discard; - } - /** - * Get whether or not this is an HTTP only cookie - * - * @return bool - */ - public function getHttpOnly() - { - return $this->data['HttpOnly']; - } - /** - * Set whether or not this is an HTTP only cookie - * - * @param bool $httpOnly Set to true or false if this is HTTP only - */ - public function setHttpOnly($httpOnly) - { - $this->data['HttpOnly'] = $httpOnly; - } - /** - * Check if the cookie matches a path value. - * - * A request-path path-matches a given cookie-path if at least one of - * the following conditions holds: - * - * - The cookie-path and the request-path are identical. - * - The cookie-path is a prefix of the request-path, and the last - * character of the cookie-path is %x2F ("/"). - * - The cookie-path is a prefix of the request-path, and the first - * character of the request-path that is not included in the cookie- - * path is a %x2F ("/") character. - * - * @param string $requestPath Path to check against - * - * @return bool - */ - public function matchesPath($requestPath) - { - $cookiePath = $this->getPath(); - // Match on exact matches or when path is the default empty "/" - if ($cookiePath === '/' || $cookiePath == $requestPath) { - return \true; - } - // Ensure that the cookie-path is a prefix of the request path. - if (0 !== \strpos($requestPath, $cookiePath)) { - return \false; - } - // Match if the last character of the cookie-path is "/" - if (\substr($cookiePath, -1, 1) === '/') { - return \true; - } - // Match if the first character not included in cookie path is "/" - return \substr($requestPath, \strlen($cookiePath), 1) === '/'; - } - /** - * Check if the cookie matches a domain value - * - * @param string $domain Domain to check against - * - * @return bool - */ - public function matchesDomain($domain) - { - // Remove the leading '.' as per spec in RFC 6265. - // http://tools.ietf.org/html/rfc6265#section-5.2.3 - $cookieDomain = \ltrim($this->getDomain(), '.'); - // Domain not set or exact match. - if (!$cookieDomain || !\strcasecmp($domain, $cookieDomain)) { - return \true; - } - // Matching the subdomain according to RFC 6265. - // http://tools.ietf.org/html/rfc6265#section-5.1.3 - if (\filter_var($domain, \FILTER_VALIDATE_IP)) { - return \false; - } - return (bool) \preg_match('/\\.' . \preg_quote($cookieDomain, '/') . '$/', $domain); - } - /** - * Check if the cookie is expired - * - * @return bool - */ - public function isExpired() - { - return $this->getExpires() !== null && \time() > $this->getExpires(); - } - /** - * Check if the cookie is valid according to RFC 6265 - * - * @return bool|string Returns true if valid or an error message if invalid - */ - public function validate() - { - // Names must not be empty, but can be 0 - $name = $this->getName(); - if (empty($name) && !\is_numeric($name)) { - return 'The cookie name must not be empty'; - } - // Check if any of the invalid characters are present in the cookie name - if (\preg_match('/[\\x00-\\x20\\x22\\x28-\\x29\\x2c\\x2f\\x3a-\\x40\\x5c\\x7b\\x7d\\x7f]/', $name)) { - return 'Cookie name must not contain invalid characters: ASCII ' . 'Control characters (0-31;127), space, tab and the ' . 'following characters: ()<>@,;:\\"/?={}'; - } - // Value must not be empty, but can be 0 - $value = $this->getValue(); - if (empty($value) && !\is_numeric($value)) { - return 'The cookie value must not be empty'; - } - // Domains must not be empty, but can be 0 - // A "0" is not a valid internet domain, but may be used as server name - // in a private network. - $domain = $this->getDomain(); - if (empty($domain) && !\is_numeric($domain)) { - return 'The cookie domain must not be empty'; - } - return \true; - } -} + null, 'Value' => null, 'Domain' => null, 'Path' => '/', 'Max-Age' => null, 'Expires' => null, 'Secure' => \false, 'Discard' => \false, 'HttpOnly' => \false]; + /** @var array Cookie data */ + private $data; + /** + * Create a new SetCookie object from a string + * + * @param string $cookie Set-Cookie header string + * + * @return self + */ + public static function fromString($cookie) + { + // Create the default return array + $data = self::$defaults; + // Explode the cookie string using a series of semicolons + $pieces = \array_filter(\array_map('trim', \explode(';', $cookie))); + // The name of the cookie (first kvp) must exist and include an equal sign. + if (empty($pieces[0]) || !\strpos($pieces[0], '=')) { + return new self($data); + } + // Add the cookie pieces into the parsed data array + foreach ($pieces as $part) { + $cookieParts = \explode('=', $part, 2); + $key = \trim($cookieParts[0]); + $value = isset($cookieParts[1]) ? \trim($cookieParts[1], " \n\r\t\0\v") : \true; + // Only check for non-cookies when cookies have been found + if (empty($data['Name'])) { + $data['Name'] = $key; + $data['Value'] = $value; + } else { + foreach (\array_keys(self::$defaults) as $search) { + if (!\strcasecmp($search, $key)) { + $data[$search] = $value; + continue 2; + } + } + $data[$key] = $value; + } + } + return new self($data); + } + /** + * @param array $data Array of cookie data provided by a Cookie parser + */ + public function __construct(array $data = []) + { + $this->data = \array_replace(self::$defaults, $data); + // Extract the Expires value and turn it into a UNIX timestamp if needed + if (!$this->getExpires() && $this->getMaxAge()) { + // Calculate the Expires date + $this->setExpires(\time() + $this->getMaxAge()); + } elseif ($this->getExpires() && !\is_numeric($this->getExpires())) { + $this->setExpires($this->getExpires()); + } + } + public function __toString() + { + $str = $this->data['Name'] . '=' . $this->data['Value'] . '; '; + foreach ($this->data as $k => $v) { + if ($k !== 'Name' && $k !== 'Value' && $v !== null && $v !== \false) { + if ($k === 'Expires') { + $str .= 'Expires=' . \gmdate('_PhpScoper5ea00cc67502b\\D, d M Y H:i:s \\G\\M\\T', $v) . '; '; + } else { + $str .= ($v === \true ? $k : "{$k}={$v}") . '; '; + } + } + } + return \rtrim($str, '; '); + } + public function toArray() + { + return $this->data; + } + /** + * Get the cookie name + * + * @return string + */ + public function getName() + { + return $this->data['Name']; + } + /** + * Set the cookie name + * + * @param string $name Cookie name + */ + public function setName($name) + { + $this->data['Name'] = $name; + } + /** + * Get the cookie value + * + * @return string + */ + public function getValue() + { + return $this->data['Value']; + } + /** + * Set the cookie value + * + * @param string $value Cookie value + */ + public function setValue($value) + { + $this->data['Value'] = $value; + } + /** + * Get the domain + * + * @return string|null + */ + public function getDomain() + { + return $this->data['Domain']; + } + /** + * Set the domain of the cookie + * + * @param string $domain + */ + public function setDomain($domain) + { + $this->data['Domain'] = $domain; + } + /** + * Get the path + * + * @return string + */ + public function getPath() + { + return $this->data['Path']; + } + /** + * Set the path of the cookie + * + * @param string $path Path of the cookie + */ + public function setPath($path) + { + $this->data['Path'] = $path; + } + /** + * Maximum lifetime of the cookie in seconds + * + * @return int|null + */ + public function getMaxAge() + { + return $this->data['Max-Age']; + } + /** + * Set the max-age of the cookie + * + * @param int $maxAge Max age of the cookie in seconds + */ + public function setMaxAge($maxAge) + { + $this->data['Max-Age'] = $maxAge; + } + /** + * The UNIX timestamp when the cookie Expires + * + * @return mixed + */ + public function getExpires() + { + return $this->data['Expires']; + } + /** + * Set the unix timestamp for which the cookie will expire + * + * @param int $timestamp Unix timestamp + */ + public function setExpires($timestamp) + { + $this->data['Expires'] = \is_numeric($timestamp) ? (int) $timestamp : \strtotime($timestamp); + } + /** + * Get whether or not this is a secure cookie + * + * @return bool|null + */ + public function getSecure() + { + return $this->data['Secure']; + } + /** + * Set whether or not the cookie is secure + * + * @param bool $secure Set to true or false if secure + */ + public function setSecure($secure) + { + $this->data['Secure'] = $secure; + } + /** + * Get whether or not this is a session cookie + * + * @return bool|null + */ + public function getDiscard() + { + return $this->data['Discard']; + } + /** + * Set whether or not this is a session cookie + * + * @param bool $discard Set to true or false if this is a session cookie + */ + public function setDiscard($discard) + { + $this->data['Discard'] = $discard; + } + /** + * Get whether or not this is an HTTP only cookie + * + * @return bool + */ + public function getHttpOnly() + { + return $this->data['HttpOnly']; + } + /** + * Set whether or not this is an HTTP only cookie + * + * @param bool $httpOnly Set to true or false if this is HTTP only + */ + public function setHttpOnly($httpOnly) + { + $this->data['HttpOnly'] = $httpOnly; + } + /** + * Check if the cookie matches a path value. + * + * A request-path path-matches a given cookie-path if at least one of + * the following conditions holds: + * + * - The cookie-path and the request-path are identical. + * - The cookie-path is a prefix of the request-path, and the last + * character of the cookie-path is %x2F ("/"). + * - The cookie-path is a prefix of the request-path, and the first + * character of the request-path that is not included in the cookie- + * path is a %x2F ("/") character. + * + * @param string $requestPath Path to check against + * + * @return bool + */ + public function matchesPath($requestPath) + { + $cookiePath = $this->getPath(); + // Match on exact matches or when path is the default empty "/" + if ($cookiePath === '/' || $cookiePath == $requestPath) { + return \true; + } + // Ensure that the cookie-path is a prefix of the request path. + if (0 !== \strpos($requestPath, $cookiePath)) { + return \false; + } + // Match if the last character of the cookie-path is "/" + if (\substr($cookiePath, -1, 1) === '/') { + return \true; + } + // Match if the first character not included in cookie path is "/" + return \substr($requestPath, \strlen($cookiePath), 1) === '/'; + } + /** + * Check if the cookie matches a domain value + * + * @param string $domain Domain to check against + * + * @return bool + */ + public function matchesDomain($domain) + { + // Remove the leading '.' as per spec in RFC 6265. + // http://tools.ietf.org/html/rfc6265#section-5.2.3 + $cookieDomain = \ltrim($this->getDomain(), '.'); + // Domain not set or exact match. + if (!$cookieDomain || !\strcasecmp($domain, $cookieDomain)) { + return \true; + } + // Matching the subdomain according to RFC 6265. + // http://tools.ietf.org/html/rfc6265#section-5.1.3 + if (\filter_var($domain, \FILTER_VALIDATE_IP)) { + return \false; + } + return (bool) \preg_match('/\\.' . \preg_quote($cookieDomain, '/') . '$/', $domain); + } + /** + * Check if the cookie is expired + * + * @return bool + */ + public function isExpired() + { + return $this->getExpires() !== null && \time() > $this->getExpires(); + } + /** + * Check if the cookie is valid according to RFC 6265 + * + * @return bool|string Returns true if valid or an error message if invalid + */ + public function validate() + { + // Names must not be empty, but can be 0 + $name = $this->getName(); + if (empty($name) && !\is_numeric($name)) { + return 'The cookie name must not be empty'; + } + // Check if any of the invalid characters are present in the cookie name + if (\preg_match('/[\\x00-\\x20\\x22\\x28-\\x29\\x2c\\x2f\\x3a-\\x40\\x5c\\x7b\\x7d\\x7f]/', $name)) { + return 'Cookie name must not contain invalid characters: ASCII ' . 'Control characters (0-31;127), space, tab and the ' . 'following characters: ()<>@,;:\\"/?={}'; + } + // Value must not be empty, but can be 0 + $value = $this->getValue(); + if (empty($value) && !\is_numeric($value)) { + return 'The cookie value must not be empty'; + } + // Domains must not be empty, but can be 0 + // A "0" is not a valid internet domain, but may be used as server name + // in a private network. + $domain = $this->getDomain(); + if (empty($domain) && !\is_numeric($domain)) { + return 'The cookie domain must not be empty'; + } + return \true; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Cookie/index.php b/vendor/guzzlehttp/guzzle/src/Cookie/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/guzzlehttp/guzzle/src/Cookie/index.php +++ b/vendor/guzzlehttp/guzzle/src/Cookie/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php b/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php index 2bd979c39..eb818f303 100644 --- a/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php +++ b/vendor/guzzlehttp/guzzle/src/Exception/BadResponseException.php @@ -1,19 +1,19 @@ -getStatusCode() : 0; - parent::__construct($message, $code, $previous); - $this->request = $request; - $this->response = $response; - $this->handlerContext = $handlerContext; - } - /** - * Wrap non-RequestExceptions with a RequestException - * - * @param RequestInterface $request - * @param \Exception $e - * - * @return RequestException - */ - public static function wrapException(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, \Exception $e) - { - return $e instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException ? $e : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException($e->getMessage(), $request, null, $e); - } - /** - * Factory method to create a new exception with a normalized error message - * - * @param RequestInterface $request Request - * @param ResponseInterface $response Response received - * @param \Exception $previous Previous exception - * @param array $ctx Optional handler context. - * - * @return self - */ - public static function create(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response = null, \Exception $previous = null, array $ctx = []) - { - if (!$response) { - return new self('Error completing request', $request, null, $previous, $ctx); - } - $level = (int) \floor($response->getStatusCode() / 100); - if ($level === 4) { - $label = 'Client error'; - $className = \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ClientException::class; - } elseif ($level === 5) { - $label = 'Server error'; - $className = \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ServerException::class; - } else { - $label = 'Unsuccessful request'; - $className = __CLASS__; - } - $uri = $request->getUri(); - $uri = static::obfuscateUri($uri); - // Client Error: `GET /` resulted in a `404 Not Found` response: - // ... (truncated) - $message = \sprintf('%s: `%s %s` resulted in a `%s %s` response', $label, $request->getMethod(), $uri, $response->getStatusCode(), $response->getReasonPhrase()); - $summary = static::getResponseBodySummary($response); - if ($summary !== null) { - $message .= ":\n{$summary}\n"; - } - return new $className($message, $request, $response, $previous, $ctx); - } - /** - * Get a short summary of the response - * - * Will return `null` if the response is not printable. - * - * @param ResponseInterface $response - * - * @return string|null - */ - public static function getResponseBodySummary(\_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) - { - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\get_message_body_summary($response); - } - /** - * Obfuscates URI if there is a username and a password present - * - * @param UriInterface $uri - * - * @return UriInterface - */ - private static function obfuscateUri(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) - { - $userInfo = $uri->getUserInfo(); - if (\false !== ($pos = \strpos($userInfo, ':'))) { - return $uri->withUserInfo(\substr($userInfo, 0, $pos), '***'); - } - return $uri; - } - /** - * Get the request that caused the exception - * - * @return RequestInterface - */ - public function getRequest() - { - return $this->request; - } - /** - * Get the associated response - * - * @return ResponseInterface|null - */ - public function getResponse() - { - return $this->response; - } - /** - * Check if a response was received - * - * @return bool - */ - public function hasResponse() - { - return $this->response !== null; - } - /** - * Get contextual information about the error from the underlying handler. - * - * The contents of this array will vary depending on which handler you are - * using. It may also be just an empty array. Relying on this data will - * couple you to a specific handler, but can give more debug information - * when needed. - * - * @return array - */ - public function getHandlerContext() - { - return $this->handlerContext; - } -} +getStatusCode() : 0; + parent::__construct($message, $code, $previous); + $this->request = $request; + $this->response = $response; + $this->handlerContext = $handlerContext; + } + /** + * Wrap non-RequestExceptions with a RequestException + * + * @param RequestInterface $request + * @param \Exception $e + * + * @return RequestException + */ + public static function wrapException(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, \Exception $e) + { + return $e instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException ? $e : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException($e->getMessage(), $request, null, $e); + } + /** + * Factory method to create a new exception with a normalized error message + * + * @param RequestInterface $request Request + * @param ResponseInterface $response Response received + * @param \Exception $previous Previous exception + * @param array $ctx Optional handler context. + * + * @return self + */ + public static function create(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response = null, \Exception $previous = null, array $ctx = []) + { + if (!$response) { + return new self('Error completing request', $request, null, $previous, $ctx); + } + $level = (int) \floor($response->getStatusCode() / 100); + if ($level === 4) { + $label = 'Client error'; + $className = \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ClientException::class; + } elseif ($level === 5) { + $label = 'Server error'; + $className = \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ServerException::class; + } else { + $label = 'Unsuccessful request'; + $className = __CLASS__; + } + $uri = $request->getUri(); + $uri = static::obfuscateUri($uri); + // Client Error: `GET /` resulted in a `404 Not Found` response: + // ... (truncated) + $message = \sprintf('%s: `%s %s` resulted in a `%s %s` response', $label, $request->getMethod(), $uri, $response->getStatusCode(), $response->getReasonPhrase()); + $summary = static::getResponseBodySummary($response); + if ($summary !== null) { + $message .= ":\n{$summary}\n"; + } + return new $className($message, $request, $response, $previous, $ctx); + } + /** + * Get a short summary of the response + * + * Will return `null` if the response is not printable. + * + * @param ResponseInterface $response + * + * @return string|null + */ + public static function getResponseBodySummary(\_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) + { + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\get_message_body_summary($response); + } + /** + * Obfuscates URI if there is a username and a password present + * + * @param UriInterface $uri + * + * @return UriInterface + */ + private static function obfuscateUri(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) + { + $userInfo = $uri->getUserInfo(); + if (\false !== ($pos = \strpos($userInfo, ':'))) { + return $uri->withUserInfo(\substr($userInfo, 0, $pos), '***'); + } + return $uri; + } + /** + * Get the request that caused the exception + * + * @return RequestInterface + */ + public function getRequest() + { + return $this->request; + } + /** + * Get the associated response + * + * @return ResponseInterface|null + */ + public function getResponse() + { + return $this->response; + } + /** + * Check if a response was received + * + * @return bool + */ + public function hasResponse() + { + return $this->response !== null; + } + /** + * Get contextual information about the error from the underlying handler. + * + * The contents of this array will vary depending on which handler you are + * using. It may also be just an empty array. Relying on this data will + * couple you to a specific handler, but can give more debug information + * when needed. + * + * @return array + */ + public function getHandlerContext() + { + return $this->handlerContext; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Exception/SeekException.php b/vendor/guzzlehttp/guzzle/src/Exception/SeekException.php index 9f52550ab..bbbe5725a 100644 --- a/vendor/guzzlehttp/guzzle/src/Exception/SeekException.php +++ b/vendor/guzzlehttp/guzzle/src/Exception/SeekException.php @@ -1,25 +1,25 @@ -stream = $stream; - $msg = $msg ?: 'Could not seek the stream to position ' . $pos; - parent::__construct($msg); - } - /** - * @return StreamInterface - */ - public function getStream() - { - return $this->stream; - } -} +stream = $stream; + $msg = $msg ?: 'Could not seek the stream to position ' . $pos; + parent::__construct($msg); + } + /** + * @return StreamInterface + */ + public function getStream() + { + return $this->stream; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php b/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php index 49884fb35..787ae65cc 100644 --- a/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php +++ b/vendor/guzzlehttp/guzzle/src/Exception/ServerException.php @@ -1,10 +1,10 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php b/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php index 3f4117f60..98dc0dc3e 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php @@ -1,436 +1,436 @@ -maxHandles = $maxHandles; - } - public function create(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - if (isset($options['curl']['body_as_string'])) { - $options['_body_as_string'] = $options['curl']['body_as_string']; - unset($options['curl']['body_as_string']); - } - $easy = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle(); - $easy->request = $request; - $easy->options = $options; - $conf = $this->getDefaultConf($easy); - $this->applyMethod($easy, $conf); - $this->applyHandlerOptions($easy, $conf); - $this->applyHeaders($easy, $conf); - unset($conf['_headers']); - // Add handler options from the request configuration options - if (isset($options['curl'])) { - $conf = \array_replace($conf, $options['curl']); - } - $conf[\CURLOPT_HEADERFUNCTION] = $this->createHeaderFn($easy); - $easy->handle = $this->handles ? \array_pop($this->handles) : \curl_init(); - \curl_setopt_array($easy->handle, $conf); - return $easy; - } - public function release(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy) - { - $resource = $easy->handle; - unset($easy->handle); - if (\count($this->handles) >= $this->maxHandles) { - \curl_close($resource); - } else { - // Remove all callback functions as they can hold onto references - // and are not cleaned up by curl_reset. Using curl_setopt_array - // does not work for some reason, so removing each one - // individually. - \curl_setopt($resource, \CURLOPT_HEADERFUNCTION, null); - \curl_setopt($resource, \CURLOPT_READFUNCTION, null); - \curl_setopt($resource, \CURLOPT_WRITEFUNCTION, null); - \curl_setopt($resource, \CURLOPT_PROGRESSFUNCTION, null); - \curl_reset($resource); - $this->handles[] = $resource; - } - } - /** - * Completes a cURL transaction, either returning a response promise or a - * rejected promise. - * - * @param callable $handler - * @param EasyHandle $easy - * @param CurlFactoryInterface $factory Dictates how the handle is released - * - * @return \GuzzleHttp\Promise\PromiseInterface - */ - public static function finish(callable $handler, \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactoryInterface $factory) - { - if (isset($easy->options['on_stats'])) { - self::invokeStats($easy); - } - if (!$easy->response || $easy->errno) { - return self::finishError($handler, $easy, $factory); - } - // Return the response if it is present and there is no error. - $factory->release($easy); - // Rewind the body of the response if possible. - $body = $easy->response->getBody(); - if ($body->isSeekable()) { - $body->rewind(); - } - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\FulfilledPromise($easy->response); - } - private static function invokeStats(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy) - { - $curlStats = \curl_getinfo($easy->handle); - $curlStats['appconnect_time'] = \curl_getinfo($easy->handle, \CURLINFO_APPCONNECT_TIME); - $stats = new \_PhpScoper5ea00cc67502b\GuzzleHttp\TransferStats($easy->request, $easy->response, $curlStats['total_time'], $easy->errno, $curlStats); - \call_user_func($easy->options['on_stats'], $stats); - } - private static function finishError(callable $handler, \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactoryInterface $factory) - { - // Get error information and release the handle to the factory. - $ctx = ['errno' => $easy->errno, 'error' => \curl_error($easy->handle), 'appconnect_time' => \curl_getinfo($easy->handle, \CURLINFO_APPCONNECT_TIME)] + \curl_getinfo($easy->handle); - $ctx[self::CURL_VERSION_STR] = \curl_version()['version']; - $factory->release($easy); - // Retry when nothing is present or when curl failed to rewind. - if (empty($easy->options['_err_message']) && (!$easy->errno || $easy->errno == 65)) { - return self::retryFailedRewind($handler, $easy, $ctx); - } - return self::createRejection($easy, $ctx); - } - private static function createRejection(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, array $ctx) - { - static $connectionErrors = [\CURLE_OPERATION_TIMEOUTED => \true, \CURLE_COULDNT_RESOLVE_HOST => \true, \CURLE_COULDNT_CONNECT => \true, \CURLE_SSL_CONNECT_ERROR => \true, \CURLE_GOT_NOTHING => \true]; - // If an exception was encountered during the onHeaders event, then - // return a rejected promise that wraps that exception. - if ($easy->onHeadersException) { - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException('An error was encountered during the on_headers event', $easy->request, $easy->response, $easy->onHeadersException, $ctx)); - } - if (\version_compare($ctx[self::CURL_VERSION_STR], self::LOW_CURL_VERSION_NUMBER)) { - $message = \sprintf('cURL error %s: %s (%s)', $ctx['errno'], $ctx['error'], 'see https://curl.haxx.se/libcurl/c/libcurl-errors.html'); - } else { - $message = \sprintf('cURL error %s: %s (%s) for %s', $ctx['errno'], $ctx['error'], 'see https://curl.haxx.se/libcurl/c/libcurl-errors.html', $easy->request->getUri()); - } - // Create a connection exception if it was a specific error code. - $error = isset($connectionErrors[$easy->errno]) ? new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ConnectException($message, $easy->request, null, $ctx) : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException($message, $easy->request, $easy->response, null, $ctx); - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($error); - } - private function getDefaultConf(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy) - { - $conf = ['_headers' => $easy->request->getHeaders(), \CURLOPT_CUSTOMREQUEST => $easy->request->getMethod(), \CURLOPT_URL => (string) $easy->request->getUri()->withFragment(''), \CURLOPT_RETURNTRANSFER => \false, \CURLOPT_HEADER => \false, \CURLOPT_CONNECTTIMEOUT => 150]; - if (\defined('CURLOPT_PROTOCOLS')) { - $conf[\CURLOPT_PROTOCOLS] = \CURLPROTO_HTTP | \CURLPROTO_HTTPS; - } - $version = $easy->request->getProtocolVersion(); - if ($version == 1.1) { - $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_1_1; - } elseif ($version == 2.0) { - $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_2_0; - } else { - $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_1_0; - } - return $conf; - } - private function applyMethod(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, array &$conf) - { - $body = $easy->request->getBody(); - $size = $body->getSize(); - if ($size === null || $size > 0) { - $this->applyBody($easy->request, $easy->options, $conf); - return; - } - $method = $easy->request->getMethod(); - if ($method === 'PUT' || $method === 'POST') { - // See http://tools.ietf.org/html/rfc7230#section-3.3.2 - if (!$easy->request->hasHeader('Content-Length')) { - $conf[\CURLOPT_HTTPHEADER][] = 'Content-Length: 0'; - } - } elseif ($method === 'HEAD') { - $conf[\CURLOPT_NOBODY] = \true; - unset($conf[\CURLOPT_WRITEFUNCTION], $conf[\CURLOPT_READFUNCTION], $conf[\CURLOPT_FILE], $conf[\CURLOPT_INFILE]); - } - } - private function applyBody(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, array &$conf) - { - $size = $request->hasHeader('Content-Length') ? (int) $request->getHeaderLine('Content-Length') : null; - // Send the body as a string if the size is less than 1MB OR if the - // [curl][body_as_string] request value is set. - if ($size !== null && $size < 1000000 || !empty($options['_body_as_string'])) { - $conf[\CURLOPT_POSTFIELDS] = (string) $request->getBody(); - // Don't duplicate the Content-Length header - $this->removeHeader('Content-Length', $conf); - $this->removeHeader('Transfer-Encoding', $conf); - } else { - $conf[\CURLOPT_UPLOAD] = \true; - if ($size !== null) { - $conf[\CURLOPT_INFILESIZE] = $size; - $this->removeHeader('Content-Length', $conf); - } - $body = $request->getBody(); - if ($body->isSeekable()) { - $body->rewind(); - } - $conf[\CURLOPT_READFUNCTION] = function ($ch, $fd, $length) use($body) { - return $body->read($length); - }; - } - // If the Expect header is not present, prevent curl from adding it - if (!$request->hasHeader('Expect')) { - $conf[\CURLOPT_HTTPHEADER][] = 'Expect:'; - } - // cURL sometimes adds a content-type by default. Prevent this. - if (!$request->hasHeader('Content-Type')) { - $conf[\CURLOPT_HTTPHEADER][] = 'Content-Type:'; - } - } - private function applyHeaders(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, array &$conf) - { - foreach ($conf['_headers'] as $name => $values) { - foreach ($values as $value) { - $value = (string) $value; - if ($value === '') { - // cURL requires a special format for empty headers. - // See https://github.com/guzzle/guzzle/issues/1882 for more details. - $conf[\CURLOPT_HTTPHEADER][] = "{$name};"; - } else { - $conf[\CURLOPT_HTTPHEADER][] = "{$name}: {$value}"; - } - } - } - // Remove the Accept header if one was not set - if (!$easy->request->hasHeader('Accept')) { - $conf[\CURLOPT_HTTPHEADER][] = 'Accept:'; - } - } - /** - * Remove a header from the options array. - * - * @param string $name Case-insensitive header to remove - * @param array $options Array of options to modify - */ - private function removeHeader($name, array &$options) - { - foreach (\array_keys($options['_headers']) as $key) { - if (!\strcasecmp($key, $name)) { - unset($options['_headers'][$key]); - return; - } - } - } - private function applyHandlerOptions(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, array &$conf) - { - $options = $easy->options; - if (isset($options['verify'])) { - if ($options['verify'] === \false) { - unset($conf[\CURLOPT_CAINFO]); - $conf[\CURLOPT_SSL_VERIFYHOST] = 0; - $conf[\CURLOPT_SSL_VERIFYPEER] = \false; - } else { - $conf[\CURLOPT_SSL_VERIFYHOST] = 2; - $conf[\CURLOPT_SSL_VERIFYPEER] = \true; - if (\is_string($options['verify'])) { - // Throw an error if the file/folder/link path is not valid or doesn't exist. - if (!\file_exists($options['verify'])) { - throw new \InvalidArgumentException("SSL CA bundle not found: {$options['verify']}"); - } - // If it's a directory or a link to a directory use CURLOPT_CAPATH. - // If not, it's probably a file, or a link to a file, so use CURLOPT_CAINFO. - if (\is_dir($options['verify']) || \is_link($options['verify']) && \is_dir(\readlink($options['verify']))) { - $conf[\CURLOPT_CAPATH] = $options['verify']; - } else { - $conf[\CURLOPT_CAINFO] = $options['verify']; - } - } - } - } - if (!empty($options['decode_content'])) { - $accept = $easy->request->getHeaderLine('Accept-Encoding'); - if ($accept) { - $conf[\CURLOPT_ENCODING] = $accept; - } else { - $conf[\CURLOPT_ENCODING] = ''; - // Don't let curl send the header over the wire - $conf[\CURLOPT_HTTPHEADER][] = 'Accept-Encoding:'; - } - } - if (isset($options['sink'])) { - $sink = $options['sink']; - if (!\is_string($sink)) { - $sink = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($sink); - } elseif (!\is_dir(\dirname($sink))) { - // Ensure that the directory exists before failing in curl. - throw new \RuntimeException(\sprintf('Directory %s does not exist for sink value of %s', \dirname($sink), $sink)); - } else { - $sink = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LazyOpenStream($sink, 'w+'); - } - $easy->sink = $sink; - $conf[\CURLOPT_WRITEFUNCTION] = function ($ch, $write) use($sink) { - return $sink->write($write); - }; - } else { - // Use a default temp stream if no sink was set. - $conf[\CURLOPT_FILE] = \fopen('php://temp', 'w+'); - $easy->sink = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($conf[\CURLOPT_FILE]); - } - $timeoutRequiresNoSignal = \false; - if (isset($options['timeout'])) { - $timeoutRequiresNoSignal |= $options['timeout'] < 1; - $conf[\CURLOPT_TIMEOUT_MS] = $options['timeout'] * 1000; - } - // CURL default value is CURL_IPRESOLVE_WHATEVER - if (isset($options['force_ip_resolve'])) { - if ('v4' === $options['force_ip_resolve']) { - $conf[\CURLOPT_IPRESOLVE] = \CURL_IPRESOLVE_V4; - } elseif ('v6' === $options['force_ip_resolve']) { - $conf[\CURLOPT_IPRESOLVE] = \CURL_IPRESOLVE_V6; - } - } - if (isset($options['connect_timeout'])) { - $timeoutRequiresNoSignal |= $options['connect_timeout'] < 1; - $conf[\CURLOPT_CONNECTTIMEOUT_MS] = $options['connect_timeout'] * 1000; - } - if ($timeoutRequiresNoSignal && \strtoupper(\substr(\PHP_OS, 0, 3)) !== 'WIN') { - $conf[\CURLOPT_NOSIGNAL] = \true; - } - if (isset($options['proxy'])) { - if (!\is_array($options['proxy'])) { - $conf[\CURLOPT_PROXY] = $options['proxy']; - } else { - $scheme = $easy->request->getUri()->getScheme(); - if (isset($options['proxy'][$scheme])) { - $host = $easy->request->getUri()->getHost(); - if (!isset($options['proxy']['no']) || !\_PhpScoper5ea00cc67502b\GuzzleHttp\is_host_in_noproxy($host, $options['proxy']['no'])) { - $conf[\CURLOPT_PROXY] = $options['proxy'][$scheme]; - } - } - } - } - if (isset($options['cert'])) { - $cert = $options['cert']; - if (\is_array($cert)) { - $conf[\CURLOPT_SSLCERTPASSWD] = $cert[1]; - $cert = $cert[0]; - } - if (!\file_exists($cert)) { - throw new \InvalidArgumentException("SSL certificate not found: {$cert}"); - } - $conf[\CURLOPT_SSLCERT] = $cert; - } - if (isset($options['ssl_key'])) { - if (\is_array($options['ssl_key'])) { - if (\count($options['ssl_key']) === 2) { - list($sslKey, $conf[\CURLOPT_SSLKEYPASSWD]) = $options['ssl_key']; - } else { - list($sslKey) = $options['ssl_key']; - } - } - $sslKey = isset($sslKey) ? $sslKey : $options['ssl_key']; - if (!\file_exists($sslKey)) { - throw new \InvalidArgumentException("SSL private key not found: {$sslKey}"); - } - $conf[\CURLOPT_SSLKEY] = $sslKey; - } - if (isset($options['progress'])) { - $progress = $options['progress']; - if (!\is_callable($progress)) { - throw new \InvalidArgumentException('progress client option must be callable'); - } - $conf[\CURLOPT_NOPROGRESS] = \false; - $conf[\CURLOPT_PROGRESSFUNCTION] = function () use($progress) { - $args = \func_get_args(); - // PHP 5.5 pushed the handle onto the start of the args - if (\is_resource($args[0])) { - \array_shift($args); - } - \call_user_func_array($progress, $args); - }; - } - if (!empty($options['debug'])) { - $conf[\CURLOPT_STDERR] = \_PhpScoper5ea00cc67502b\GuzzleHttp\debug_resource($options['debug']); - $conf[\CURLOPT_VERBOSE] = \true; - } - } - /** - * This function ensures that a response was set on a transaction. If one - * was not set, then the request is retried if possible. This error - * typically means you are sending a payload, curl encountered a - * "Connection died, retrying a fresh connect" error, tried to rewind the - * stream, and then encountered a "necessary data rewind wasn't possible" - * error, causing the request to be sent through curl_multi_info_read() - * without an error status. - */ - private static function retryFailedRewind(callable $handler, \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, array $ctx) - { - try { - // Only rewind if the body has been read from. - $body = $easy->request->getBody(); - if ($body->tell() > 0) { - $body->rewind(); - } - } catch (\RuntimeException $e) { - $ctx['error'] = 'The connection unexpectedly failed without ' . 'providing an error. The request would have been retried, ' . 'but attempting to rewind the request body failed. ' . 'Exception: ' . $e; - return self::createRejection($easy, $ctx); - } - // Retry no more than 3 times before giving up. - if (!isset($easy->options['_curl_retries'])) { - $easy->options['_curl_retries'] = 1; - } elseif ($easy->options['_curl_retries'] == 2) { - $ctx['error'] = 'The cURL request was retried 3 times ' . 'and did not succeed. The most likely reason for the failure ' . 'is that cURL was unable to rewind the body of the request ' . 'and subsequent retries resulted in the same error. Turn on ' . 'the debug option to see what went wrong. See ' . 'https://bugs.php.net/bug.php?id=47204 for more information.'; - return self::createRejection($easy, $ctx); - } else { - $easy->options['_curl_retries']++; - } - return $handler($easy->request, $easy->options); - } - private function createHeaderFn(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy) - { - if (isset($easy->options['on_headers'])) { - $onHeaders = $easy->options['on_headers']; - if (!\is_callable($onHeaders)) { - throw new \InvalidArgumentException('on_headers must be callable'); - } - } else { - $onHeaders = null; - } - return function ($ch, $h) use($onHeaders, $easy, &$startingResponse) { - $value = \trim($h); - if ($value === '') { - $startingResponse = \true; - $easy->createResponse(); - if ($onHeaders !== null) { - try { - $onHeaders($easy->response); - } catch (\Exception $e) { - // Associate the exception with the handle and trigger - // a curl header write error by returning 0. - $easy->onHeadersException = $e; - return -1; - } - } - } elseif ($startingResponse) { - $startingResponse = \false; - $easy->headers = [$value]; - } else { - $easy->headers[] = $value; - } - return \strlen($h); - }; - } -} +maxHandles = $maxHandles; + } + public function create(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + if (isset($options['curl']['body_as_string'])) { + $options['_body_as_string'] = $options['curl']['body_as_string']; + unset($options['curl']['body_as_string']); + } + $easy = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle(); + $easy->request = $request; + $easy->options = $options; + $conf = $this->getDefaultConf($easy); + $this->applyMethod($easy, $conf); + $this->applyHandlerOptions($easy, $conf); + $this->applyHeaders($easy, $conf); + unset($conf['_headers']); + // Add handler options from the request configuration options + if (isset($options['curl'])) { + $conf = \array_replace($conf, $options['curl']); + } + $conf[\CURLOPT_HEADERFUNCTION] = $this->createHeaderFn($easy); + $easy->handle = $this->handles ? \array_pop($this->handles) : \curl_init(); + \curl_setopt_array($easy->handle, $conf); + return $easy; + } + public function release(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy) + { + $resource = $easy->handle; + unset($easy->handle); + if (\count($this->handles) >= $this->maxHandles) { + \curl_close($resource); + } else { + // Remove all callback functions as they can hold onto references + // and are not cleaned up by curl_reset. Using curl_setopt_array + // does not work for some reason, so removing each one + // individually. + \curl_setopt($resource, \CURLOPT_HEADERFUNCTION, null); + \curl_setopt($resource, \CURLOPT_READFUNCTION, null); + \curl_setopt($resource, \CURLOPT_WRITEFUNCTION, null); + \curl_setopt($resource, \CURLOPT_PROGRESSFUNCTION, null); + \curl_reset($resource); + $this->handles[] = $resource; + } + } + /** + * Completes a cURL transaction, either returning a response promise or a + * rejected promise. + * + * @param callable $handler + * @param EasyHandle $easy + * @param CurlFactoryInterface $factory Dictates how the handle is released + * + * @return \GuzzleHttp\Promise\PromiseInterface + */ + public static function finish(callable $handler, \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactoryInterface $factory) + { + if (isset($easy->options['on_stats'])) { + self::invokeStats($easy); + } + if (!$easy->response || $easy->errno) { + return self::finishError($handler, $easy, $factory); + } + // Return the response if it is present and there is no error. + $factory->release($easy); + // Rewind the body of the response if possible. + $body = $easy->response->getBody(); + if ($body->isSeekable()) { + $body->rewind(); + } + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\FulfilledPromise($easy->response); + } + private static function invokeStats(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy) + { + $curlStats = \curl_getinfo($easy->handle); + $curlStats['appconnect_time'] = \curl_getinfo($easy->handle, \CURLINFO_APPCONNECT_TIME); + $stats = new \_PhpScoper5ea00cc67502b\GuzzleHttp\TransferStats($easy->request, $easy->response, $curlStats['total_time'], $easy->errno, $curlStats); + \call_user_func($easy->options['on_stats'], $stats); + } + private static function finishError(callable $handler, \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactoryInterface $factory) + { + // Get error information and release the handle to the factory. + $ctx = ['errno' => $easy->errno, 'error' => \curl_error($easy->handle), 'appconnect_time' => \curl_getinfo($easy->handle, \CURLINFO_APPCONNECT_TIME)] + \curl_getinfo($easy->handle); + $ctx[self::CURL_VERSION_STR] = \curl_version()['version']; + $factory->release($easy); + // Retry when nothing is present or when curl failed to rewind. + if (empty($easy->options['_err_message']) && (!$easy->errno || $easy->errno == 65)) { + return self::retryFailedRewind($handler, $easy, $ctx); + } + return self::createRejection($easy, $ctx); + } + private static function createRejection(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, array $ctx) + { + static $connectionErrors = [\CURLE_OPERATION_TIMEOUTED => \true, \CURLE_COULDNT_RESOLVE_HOST => \true, \CURLE_COULDNT_CONNECT => \true, \CURLE_SSL_CONNECT_ERROR => \true, \CURLE_GOT_NOTHING => \true]; + // If an exception was encountered during the onHeaders event, then + // return a rejected promise that wraps that exception. + if ($easy->onHeadersException) { + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException('An error was encountered during the on_headers event', $easy->request, $easy->response, $easy->onHeadersException, $ctx)); + } + if (\version_compare($ctx[self::CURL_VERSION_STR], self::LOW_CURL_VERSION_NUMBER)) { + $message = \sprintf('cURL error %s: %s (%s)', $ctx['errno'], $ctx['error'], 'see https://curl.haxx.se/libcurl/c/libcurl-errors.html'); + } else { + $message = \sprintf('cURL error %s: %s (%s) for %s', $ctx['errno'], $ctx['error'], 'see https://curl.haxx.se/libcurl/c/libcurl-errors.html', $easy->request->getUri()); + } + // Create a connection exception if it was a specific error code. + $error = isset($connectionErrors[$easy->errno]) ? new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ConnectException($message, $easy->request, null, $ctx) : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException($message, $easy->request, $easy->response, null, $ctx); + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($error); + } + private function getDefaultConf(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy) + { + $conf = ['_headers' => $easy->request->getHeaders(), \CURLOPT_CUSTOMREQUEST => $easy->request->getMethod(), \CURLOPT_URL => (string) $easy->request->getUri()->withFragment(''), \CURLOPT_RETURNTRANSFER => \false, \CURLOPT_HEADER => \false, \CURLOPT_CONNECTTIMEOUT => 150]; + if (\defined('CURLOPT_PROTOCOLS')) { + $conf[\CURLOPT_PROTOCOLS] = \CURLPROTO_HTTP | \CURLPROTO_HTTPS; + } + $version = $easy->request->getProtocolVersion(); + if ($version == 1.1) { + $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_1_1; + } elseif ($version == 2.0) { + $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_2_0; + } else { + $conf[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_1_0; + } + return $conf; + } + private function applyMethod(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, array &$conf) + { + $body = $easy->request->getBody(); + $size = $body->getSize(); + if ($size === null || $size > 0) { + $this->applyBody($easy->request, $easy->options, $conf); + return; + } + $method = $easy->request->getMethod(); + if ($method === 'PUT' || $method === 'POST') { + // See http://tools.ietf.org/html/rfc7230#section-3.3.2 + if (!$easy->request->hasHeader('Content-Length')) { + $conf[\CURLOPT_HTTPHEADER][] = 'Content-Length: 0'; + } + } elseif ($method === 'HEAD') { + $conf[\CURLOPT_NOBODY] = \true; + unset($conf[\CURLOPT_WRITEFUNCTION], $conf[\CURLOPT_READFUNCTION], $conf[\CURLOPT_FILE], $conf[\CURLOPT_INFILE]); + } + } + private function applyBody(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, array &$conf) + { + $size = $request->hasHeader('Content-Length') ? (int) $request->getHeaderLine('Content-Length') : null; + // Send the body as a string if the size is less than 1MB OR if the + // [curl][body_as_string] request value is set. + if ($size !== null && $size < 1000000 || !empty($options['_body_as_string'])) { + $conf[\CURLOPT_POSTFIELDS] = (string) $request->getBody(); + // Don't duplicate the Content-Length header + $this->removeHeader('Content-Length', $conf); + $this->removeHeader('Transfer-Encoding', $conf); + } else { + $conf[\CURLOPT_UPLOAD] = \true; + if ($size !== null) { + $conf[\CURLOPT_INFILESIZE] = $size; + $this->removeHeader('Content-Length', $conf); + } + $body = $request->getBody(); + if ($body->isSeekable()) { + $body->rewind(); + } + $conf[\CURLOPT_READFUNCTION] = function ($ch, $fd, $length) use($body) { + return $body->read($length); + }; + } + // If the Expect header is not present, prevent curl from adding it + if (!$request->hasHeader('Expect')) { + $conf[\CURLOPT_HTTPHEADER][] = 'Expect:'; + } + // cURL sometimes adds a content-type by default. Prevent this. + if (!$request->hasHeader('Content-Type')) { + $conf[\CURLOPT_HTTPHEADER][] = 'Content-Type:'; + } + } + private function applyHeaders(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, array &$conf) + { + foreach ($conf['_headers'] as $name => $values) { + foreach ($values as $value) { + $value = (string) $value; + if ($value === '') { + // cURL requires a special format for empty headers. + // See https://github.com/guzzle/guzzle/issues/1882 for more details. + $conf[\CURLOPT_HTTPHEADER][] = "{$name};"; + } else { + $conf[\CURLOPT_HTTPHEADER][] = "{$name}: {$value}"; + } + } + } + // Remove the Accept header if one was not set + if (!$easy->request->hasHeader('Accept')) { + $conf[\CURLOPT_HTTPHEADER][] = 'Accept:'; + } + } + /** + * Remove a header from the options array. + * + * @param string $name Case-insensitive header to remove + * @param array $options Array of options to modify + */ + private function removeHeader($name, array &$options) + { + foreach (\array_keys($options['_headers']) as $key) { + if (!\strcasecmp($key, $name)) { + unset($options['_headers'][$key]); + return; + } + } + } + private function applyHandlerOptions(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, array &$conf) + { + $options = $easy->options; + if (isset($options['verify'])) { + if ($options['verify'] === \false) { + unset($conf[\CURLOPT_CAINFO]); + $conf[\CURLOPT_SSL_VERIFYHOST] = 0; + $conf[\CURLOPT_SSL_VERIFYPEER] = \false; + } else { + $conf[\CURLOPT_SSL_VERIFYHOST] = 2; + $conf[\CURLOPT_SSL_VERIFYPEER] = \true; + if (\is_string($options['verify'])) { + // Throw an error if the file/folder/link path is not valid or doesn't exist. + if (!\file_exists($options['verify'])) { + throw new \InvalidArgumentException("SSL CA bundle not found: {$options['verify']}"); + } + // If it's a directory or a link to a directory use CURLOPT_CAPATH. + // If not, it's probably a file, or a link to a file, so use CURLOPT_CAINFO. + if (\is_dir($options['verify']) || \is_link($options['verify']) && \is_dir(\readlink($options['verify']))) { + $conf[\CURLOPT_CAPATH] = $options['verify']; + } else { + $conf[\CURLOPT_CAINFO] = $options['verify']; + } + } + } + } + if (!empty($options['decode_content'])) { + $accept = $easy->request->getHeaderLine('Accept-Encoding'); + if ($accept) { + $conf[\CURLOPT_ENCODING] = $accept; + } else { + $conf[\CURLOPT_ENCODING] = ''; + // Don't let curl send the header over the wire + $conf[\CURLOPT_HTTPHEADER][] = 'Accept-Encoding:'; + } + } + if (isset($options['sink'])) { + $sink = $options['sink']; + if (!\is_string($sink)) { + $sink = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($sink); + } elseif (!\is_dir(\dirname($sink))) { + // Ensure that the directory exists before failing in curl. + throw new \RuntimeException(\sprintf('Directory %s does not exist for sink value of %s', \dirname($sink), $sink)); + } else { + $sink = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LazyOpenStream($sink, 'w+'); + } + $easy->sink = $sink; + $conf[\CURLOPT_WRITEFUNCTION] = function ($ch, $write) use($sink) { + return $sink->write($write); + }; + } else { + // Use a default temp stream if no sink was set. + $conf[\CURLOPT_FILE] = \fopen('php://temp', 'w+'); + $easy->sink = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($conf[\CURLOPT_FILE]); + } + $timeoutRequiresNoSignal = \false; + if (isset($options['timeout'])) { + $timeoutRequiresNoSignal |= $options['timeout'] < 1; + $conf[\CURLOPT_TIMEOUT_MS] = $options['timeout'] * 1000; + } + // CURL default value is CURL_IPRESOLVE_WHATEVER + if (isset($options['force_ip_resolve'])) { + if ('v4' === $options['force_ip_resolve']) { + $conf[\CURLOPT_IPRESOLVE] = \CURL_IPRESOLVE_V4; + } elseif ('v6' === $options['force_ip_resolve']) { + $conf[\CURLOPT_IPRESOLVE] = \CURL_IPRESOLVE_V6; + } + } + if (isset($options['connect_timeout'])) { + $timeoutRequiresNoSignal |= $options['connect_timeout'] < 1; + $conf[\CURLOPT_CONNECTTIMEOUT_MS] = $options['connect_timeout'] * 1000; + } + if ($timeoutRequiresNoSignal && \strtoupper(\substr(\PHP_OS, 0, 3)) !== 'WIN') { + $conf[\CURLOPT_NOSIGNAL] = \true; + } + if (isset($options['proxy'])) { + if (!\is_array($options['proxy'])) { + $conf[\CURLOPT_PROXY] = $options['proxy']; + } else { + $scheme = $easy->request->getUri()->getScheme(); + if (isset($options['proxy'][$scheme])) { + $host = $easy->request->getUri()->getHost(); + if (!isset($options['proxy']['no']) || !\_PhpScoper5ea00cc67502b\GuzzleHttp\is_host_in_noproxy($host, $options['proxy']['no'])) { + $conf[\CURLOPT_PROXY] = $options['proxy'][$scheme]; + } + } + } + } + if (isset($options['cert'])) { + $cert = $options['cert']; + if (\is_array($cert)) { + $conf[\CURLOPT_SSLCERTPASSWD] = $cert[1]; + $cert = $cert[0]; + } + if (!\file_exists($cert)) { + throw new \InvalidArgumentException("SSL certificate not found: {$cert}"); + } + $conf[\CURLOPT_SSLCERT] = $cert; + } + if (isset($options['ssl_key'])) { + if (\is_array($options['ssl_key'])) { + if (\count($options['ssl_key']) === 2) { + list($sslKey, $conf[\CURLOPT_SSLKEYPASSWD]) = $options['ssl_key']; + } else { + list($sslKey) = $options['ssl_key']; + } + } + $sslKey = isset($sslKey) ? $sslKey : $options['ssl_key']; + if (!\file_exists($sslKey)) { + throw new \InvalidArgumentException("SSL private key not found: {$sslKey}"); + } + $conf[\CURLOPT_SSLKEY] = $sslKey; + } + if (isset($options['progress'])) { + $progress = $options['progress']; + if (!\is_callable($progress)) { + throw new \InvalidArgumentException('progress client option must be callable'); + } + $conf[\CURLOPT_NOPROGRESS] = \false; + $conf[\CURLOPT_PROGRESSFUNCTION] = function () use($progress) { + $args = \func_get_args(); + // PHP 5.5 pushed the handle onto the start of the args + if (\is_resource($args[0])) { + \array_shift($args); + } + \call_user_func_array($progress, $args); + }; + } + if (!empty($options['debug'])) { + $conf[\CURLOPT_STDERR] = \_PhpScoper5ea00cc67502b\GuzzleHttp\debug_resource($options['debug']); + $conf[\CURLOPT_VERBOSE] = \true; + } + } + /** + * This function ensures that a response was set on a transaction. If one + * was not set, then the request is retried if possible. This error + * typically means you are sending a payload, curl encountered a + * "Connection died, retrying a fresh connect" error, tried to rewind the + * stream, and then encountered a "necessary data rewind wasn't possible" + * error, causing the request to be sent through curl_multi_info_read() + * without an error status. + */ + private static function retryFailedRewind(callable $handler, \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy, array $ctx) + { + try { + // Only rewind if the body has been read from. + $body = $easy->request->getBody(); + if ($body->tell() > 0) { + $body->rewind(); + } + } catch (\RuntimeException $e) { + $ctx['error'] = 'The connection unexpectedly failed without ' . 'providing an error. The request would have been retried, ' . 'but attempting to rewind the request body failed. ' . 'Exception: ' . $e; + return self::createRejection($easy, $ctx); + } + // Retry no more than 3 times before giving up. + if (!isset($easy->options['_curl_retries'])) { + $easy->options['_curl_retries'] = 1; + } elseif ($easy->options['_curl_retries'] == 2) { + $ctx['error'] = 'The cURL request was retried 3 times ' . 'and did not succeed. The most likely reason for the failure ' . 'is that cURL was unable to rewind the body of the request ' . 'and subsequent retries resulted in the same error. Turn on ' . 'the debug option to see what went wrong. See ' . 'https://bugs.php.net/bug.php?id=47204 for more information.'; + return self::createRejection($easy, $ctx); + } else { + $easy->options['_curl_retries']++; + } + return $handler($easy->request, $easy->options); + } + private function createHeaderFn(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\EasyHandle $easy) + { + if (isset($easy->options['on_headers'])) { + $onHeaders = $easy->options['on_headers']; + if (!\is_callable($onHeaders)) { + throw new \InvalidArgumentException('on_headers must be callable'); + } + } else { + $onHeaders = null; + } + return function ($ch, $h) use($onHeaders, $easy, &$startingResponse) { + $value = \trim($h); + if ($value === '') { + $startingResponse = \true; + $easy->createResponse(); + if ($onHeaders !== null) { + try { + $onHeaders($easy->response); + } catch (\Exception $e) { + // Associate the exception with the handle and trigger + // a curl header write error by returning 0. + $easy->onHeadersException = $e; + return -1; + } + } + } elseif ($startingResponse) { + $startingResponse = \false; + $easy->headers = [$value]; + } else { + $easy->headers[] = $value; + } + return \strlen($h); + }; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php b/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php index 3c8095298..08120fb17 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/CurlFactoryInterface.php @@ -1,26 +1,26 @@ -factory = isset($options['handle_factory']) ? $options['handle_factory'] : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactory(3); - } - public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - if (isset($options['delay'])) { - \usleep($options['delay'] * 1000); - } - $easy = $this->factory->create($request, $options); - \curl_exec($easy->handle); - $easy->errno = \curl_errno($easy->handle); - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactory::finish($this, $easy, $this->factory); - } -} +factory = isset($options['handle_factory']) ? $options['handle_factory'] : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactory(3); + } + public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + if (isset($options['delay'])) { + \usleep($options['delay'] * 1000); + } + $easy = $this->factory->create($request, $options); + \curl_exec($easy->handle); + $easy->errno = \curl_errno($easy->handle); + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactory::finish($this, $easy, $this->factory); + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php b/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php index e197c2716..666ebc85b 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php @@ -1,178 +1,178 @@ -factory = isset($options['handle_factory']) ? $options['handle_factory'] : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactory(50); - if (isset($options['select_timeout'])) { - $this->selectTimeout = $options['select_timeout']; - } elseif ($selectTimeout = \getenv('GUZZLE_CURL_SELECT_TIMEOUT')) { - $this->selectTimeout = $selectTimeout; - } else { - $this->selectTimeout = 1; - } - $this->options = isset($options['options']) ? $options['options'] : []; - } - public function __get($name) - { - if ($name === '_mh') { - $this->_mh = \curl_multi_init(); - foreach ($this->options as $option => $value) { - // A warning is raised in case of a wrong option. - \curl_multi_setopt($this->_mh, $option, $value); - } - // Further calls to _mh will return the value directly, without entering the - // __get() method at all. - return $this->_mh; - } - throw new \BadMethodCallException(); - } - public function __destruct() - { - if (isset($this->_mh)) { - \curl_multi_close($this->_mh); - unset($this->_mh); - } - } - public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - $easy = $this->factory->create($request, $options); - $id = (int) $easy->handle; - $promise = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise([$this, 'execute'], function () use($id) { - return $this->cancel($id); - }); - $this->addRequest(['easy' => $easy, 'deferred' => $promise]); - return $promise; - } - /** - * Ticks the curl event loop. - */ - public function tick() - { - // Add any delayed handles if needed. - if ($this->delays) { - $currentTime = \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::currentTime(); - foreach ($this->delays as $id => $delay) { - if ($currentTime >= $delay) { - unset($this->delays[$id]); - \curl_multi_add_handle($this->_mh, $this->handles[$id]['easy']->handle); - } - } - } - // Step through the task queue which may add additional requests. - \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\queue()->run(); - if ($this->active && \curl_multi_select($this->_mh, $this->selectTimeout) === -1) { - // Perform a usleep if a select returns -1. - // See: https://bugs.php.net/bug.php?id=61141 - \usleep(250); - } - while (\curl_multi_exec($this->_mh, $this->active) === \CURLM_CALL_MULTI_PERFORM) { - } - $this->processMessages(); - } - /** - * Runs until all outstanding connections have completed. - */ - public function execute() - { - $queue = \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\queue(); - while ($this->handles || !$queue->isEmpty()) { - // If there are no transfers, then sleep for the next delay - if (!$this->active && $this->delays) { - \usleep($this->timeToNext()); - } - $this->tick(); - } - } - private function addRequest(array $entry) - { - $easy = $entry['easy']; - $id = (int) $easy->handle; - $this->handles[$id] = $entry; - if (empty($easy->options['delay'])) { - \curl_multi_add_handle($this->_mh, $easy->handle); - } else { - $this->delays[$id] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::currentTime() + $easy->options['delay'] / 1000; - } - } - /** - * Cancels a handle from sending and removes references to it. - * - * @param int $id Handle ID to cancel and remove. - * - * @return bool True on success, false on failure. - */ - private function cancel($id) - { - // Cannot cancel if it has been processed. - if (!isset($this->handles[$id])) { - return \false; - } - $handle = $this->handles[$id]['easy']->handle; - unset($this->delays[$id], $this->handles[$id]); - \curl_multi_remove_handle($this->_mh, $handle); - \curl_close($handle); - return \true; - } - private function processMessages() - { - while ($done = \curl_multi_info_read($this->_mh)) { - $id = (int) $done['handle']; - \curl_multi_remove_handle($this->_mh, $done['handle']); - if (!isset($this->handles[$id])) { - // Probably was cancelled. - continue; - } - $entry = $this->handles[$id]; - unset($this->handles[$id], $this->delays[$id]); - $entry['easy']->errno = $done['result']; - $entry['deferred']->resolve(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactory::finish($this, $entry['easy'], $this->factory)); - } - } - private function timeToNext() - { - $currentTime = \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::currentTime(); - $nextTime = \PHP_INT_MAX; - foreach ($this->delays as $time) { - if ($time < $nextTime) { - $nextTime = $time; - } - } - return \max(0, $nextTime - $currentTime) * 1000000; - } -} +factory = isset($options['handle_factory']) ? $options['handle_factory'] : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactory(50); + if (isset($options['select_timeout'])) { + $this->selectTimeout = $options['select_timeout']; + } elseif ($selectTimeout = \getenv('GUZZLE_CURL_SELECT_TIMEOUT')) { + $this->selectTimeout = $selectTimeout; + } else { + $this->selectTimeout = 1; + } + $this->options = isset($options['options']) ? $options['options'] : []; + } + public function __get($name) + { + if ($name === '_mh') { + $this->_mh = \curl_multi_init(); + foreach ($this->options as $option => $value) { + // A warning is raised in case of a wrong option. + \curl_multi_setopt($this->_mh, $option, $value); + } + // Further calls to _mh will return the value directly, without entering the + // __get() method at all. + return $this->_mh; + } + throw new \BadMethodCallException(); + } + public function __destruct() + { + if (isset($this->_mh)) { + \curl_multi_close($this->_mh); + unset($this->_mh); + } + } + public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + $easy = $this->factory->create($request, $options); + $id = (int) $easy->handle; + $promise = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise([$this, 'execute'], function () use($id) { + return $this->cancel($id); + }); + $this->addRequest(['easy' => $easy, 'deferred' => $promise]); + return $promise; + } + /** + * Ticks the curl event loop. + */ + public function tick() + { + // Add any delayed handles if needed. + if ($this->delays) { + $currentTime = \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::currentTime(); + foreach ($this->delays as $id => $delay) { + if ($currentTime >= $delay) { + unset($this->delays[$id]); + \curl_multi_add_handle($this->_mh, $this->handles[$id]['easy']->handle); + } + } + } + // Step through the task queue which may add additional requests. + \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\queue()->run(); + if ($this->active && \curl_multi_select($this->_mh, $this->selectTimeout) === -1) { + // Perform a usleep if a select returns -1. + // See: https://bugs.php.net/bug.php?id=61141 + \usleep(250); + } + while (\curl_multi_exec($this->_mh, $this->active) === \CURLM_CALL_MULTI_PERFORM) { + } + $this->processMessages(); + } + /** + * Runs until all outstanding connections have completed. + */ + public function execute() + { + $queue = \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\queue(); + while ($this->handles || !$queue->isEmpty()) { + // If there are no transfers, then sleep for the next delay + if (!$this->active && $this->delays) { + \usleep($this->timeToNext()); + } + $this->tick(); + } + } + private function addRequest(array $entry) + { + $easy = $entry['easy']; + $id = (int) $easy->handle; + $this->handles[$id] = $entry; + if (empty($easy->options['delay'])) { + \curl_multi_add_handle($this->_mh, $easy->handle); + } else { + $this->delays[$id] = \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::currentTime() + $easy->options['delay'] / 1000; + } + } + /** + * Cancels a handle from sending and removes references to it. + * + * @param int $id Handle ID to cancel and remove. + * + * @return bool True on success, false on failure. + */ + private function cancel($id) + { + // Cannot cancel if it has been processed. + if (!isset($this->handles[$id])) { + return \false; + } + $handle = $this->handles[$id]['easy']->handle; + unset($this->delays[$id], $this->handles[$id]); + \curl_multi_remove_handle($this->_mh, $handle); + \curl_close($handle); + return \true; + } + private function processMessages() + { + while ($done = \curl_multi_info_read($this->_mh)) { + $id = (int) $done['handle']; + \curl_multi_remove_handle($this->_mh, $done['handle']); + if (!isset($this->handles[$id])) { + // Probably was cancelled. + continue; + } + $entry = $this->handles[$id]; + unset($this->handles[$id], $this->delays[$id]); + $entry['easy']->errno = $done['result']; + $entry['deferred']->resolve(\_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlFactory::finish($this, $entry['easy'], $this->factory)); + } + } + private function timeToNext() + { + $currentTime = \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::currentTime(); + $nextTime = \PHP_INT_MAX; + foreach ($this->delays as $time) { + if ($time < $nextTime) { + $nextTime = $time; + } + } + return \max(0, $nextTime - $currentTime) * 1000000; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php b/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php index 275b2c1d4..a95f7bc1e 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/EasyHandle.php @@ -1,67 +1,67 @@ -headers)) { - throw new \RuntimeException('No headers have been received'); - } - // HTTP-version SP status-code SP reason-phrase - $startLine = \explode(' ', \array_shift($this->headers), 3); - $headers = \_PhpScoper5ea00cc67502b\GuzzleHttp\headers_from_lines($this->headers); - $normalizedKeys = \_PhpScoper5ea00cc67502b\GuzzleHttp\normalize_header_keys($headers); - if (!empty($this->options['decode_content']) && isset($normalizedKeys['content-encoding'])) { - $headers['x-encoded-content-encoding'] = $headers[$normalizedKeys['content-encoding']]; - unset($headers[$normalizedKeys['content-encoding']]); - if (isset($normalizedKeys['content-length'])) { - $headers['x-encoded-content-length'] = $headers[$normalizedKeys['content-length']]; - $bodyLength = (int) $this->sink->getSize(); - if ($bodyLength) { - $headers[$normalizedKeys['content-length']] = $bodyLength; - } else { - unset($headers[$normalizedKeys['content-length']]); - } - } - } - // Attach a response to the easy handle with the parsed headers. - $this->response = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Response($startLine[1], $headers, $this->sink, \substr($startLine[0], 5), isset($startLine[2]) ? (string) $startLine[2] : null); - } - public function __get($name) - { - $msg = $name === 'handle' ? 'The EasyHandle has been released' : 'Invalid property: ' . $name; - throw new \BadMethodCallException($msg); - } -} +headers)) { + throw new \RuntimeException('No headers have been received'); + } + // HTTP-version SP status-code SP reason-phrase + $startLine = \explode(' ', \array_shift($this->headers), 3); + $headers = \_PhpScoper5ea00cc67502b\GuzzleHttp\headers_from_lines($this->headers); + $normalizedKeys = \_PhpScoper5ea00cc67502b\GuzzleHttp\normalize_header_keys($headers); + if (!empty($this->options['decode_content']) && isset($normalizedKeys['content-encoding'])) { + $headers['x-encoded-content-encoding'] = $headers[$normalizedKeys['content-encoding']]; + unset($headers[$normalizedKeys['content-encoding']]); + if (isset($normalizedKeys['content-length'])) { + $headers['x-encoded-content-length'] = $headers[$normalizedKeys['content-length']]; + $bodyLength = (int) $this->sink->getSize(); + if ($bodyLength) { + $headers[$normalizedKeys['content-length']] = $bodyLength; + } else { + unset($headers[$normalizedKeys['content-length']]); + } + } + } + // Attach a response to the easy handle with the parsed headers. + $this->response = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Response($startLine[1], $headers, $this->sink, \substr($startLine[0], 5), isset($startLine[2]) ? (string) $startLine[2] : null); + } + public function __get($name) + { + $msg = $name === 'handle' ? 'The EasyHandle has been released' : 'Invalid property: ' . $name; + throw new \BadMethodCallException($msg); + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Handler/MockHandler.php b/vendor/guzzlehttp/guzzle/src/Handler/MockHandler.php index a3f53ee1d..22d4f4640 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/MockHandler.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/MockHandler.php @@ -1,157 +1,157 @@ -onFulfilled = $onFulfilled; - $this->onRejected = $onRejected; - if ($queue) { - \call_user_func_array([$this, 'append'], $queue); - } - } - public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - if (!$this->queue) { - throw new \OutOfBoundsException('Mock queue is empty'); - } - if (isset($options['delay']) && \is_numeric($options['delay'])) { - \usleep($options['delay'] * 1000); - } - $this->lastRequest = $request; - $this->lastOptions = $options; - $response = \array_shift($this->queue); - if (isset($options['on_headers'])) { - if (!\is_callable($options['on_headers'])) { - throw new \InvalidArgumentException('on_headers must be callable'); - } - try { - $options['on_headers']($response); - } catch (\Exception $e) { - $msg = 'An error was encountered during the on_headers event'; - $response = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException($msg, $request, $response, $e); - } - } - if (\is_callable($response)) { - $response = \call_user_func($response, $request, $options); - } - $response = $response instanceof \Exception ? \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($response) : \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\promise_for($response); - return $response->then(function ($value) use($request, $options) { - $this->invokeStats($request, $options, $value); - if ($this->onFulfilled) { - \call_user_func($this->onFulfilled, $value); - } - if (isset($options['sink'])) { - $contents = (string) $value->getBody(); - $sink = $options['sink']; - if (\is_resource($sink)) { - \fwrite($sink, $contents); - } elseif (\is_string($sink)) { - \file_put_contents($sink, $contents); - } elseif ($sink instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface) { - $sink->write($contents); - } - } - return $value; - }, function ($reason) use($request, $options) { - $this->invokeStats($request, $options, null, $reason); - if ($this->onRejected) { - \call_user_func($this->onRejected, $reason); - } - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($reason); - }); - } - /** - * Adds one or more variadic requests, exceptions, callables, or promises - * to the queue. - */ - public function append() - { - foreach (\func_get_args() as $value) { - if ($value instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface || $value instanceof \Exception || $value instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface || \is_callable($value)) { - $this->queue[] = $value; - } else { - throw new \InvalidArgumentException('Expected a response or ' . 'exception. Found ' . \_PhpScoper5ea00cc67502b\GuzzleHttp\describe_type($value)); - } - } - } - /** - * Get the last received request. - * - * @return RequestInterface - */ - public function getLastRequest() - { - return $this->lastRequest; - } - /** - * Get the last received request options. - * - * @return array - */ - public function getLastOptions() - { - return $this->lastOptions; - } - /** - * Returns the number of remaining items in the queue. - * - * @return int - */ - public function count() - { - return \count($this->queue); - } - public function reset() - { - $this->queue = []; - } - private function invokeStats(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response = null, $reason = null) - { - if (isset($options['on_stats'])) { - $transferTime = isset($options['transfer_time']) ? $options['transfer_time'] : 0; - $stats = new \_PhpScoper5ea00cc67502b\GuzzleHttp\TransferStats($request, $response, $transferTime, $reason); - \call_user_func($options['on_stats'], $stats); - } - } -} +onFulfilled = $onFulfilled; + $this->onRejected = $onRejected; + if ($queue) { + \call_user_func_array([$this, 'append'], $queue); + } + } + public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + if (!$this->queue) { + throw new \OutOfBoundsException('Mock queue is empty'); + } + if (isset($options['delay']) && \is_numeric($options['delay'])) { + \usleep($options['delay'] * 1000); + } + $this->lastRequest = $request; + $this->lastOptions = $options; + $response = \array_shift($this->queue); + if (isset($options['on_headers'])) { + if (!\is_callable($options['on_headers'])) { + throw new \InvalidArgumentException('on_headers must be callable'); + } + try { + $options['on_headers']($response); + } catch (\Exception $e) { + $msg = 'An error was encountered during the on_headers event'; + $response = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException($msg, $request, $response, $e); + } + } + if (\is_callable($response)) { + $response = \call_user_func($response, $request, $options); + } + $response = $response instanceof \Exception ? \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($response) : \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\promise_for($response); + return $response->then(function ($value) use($request, $options) { + $this->invokeStats($request, $options, $value); + if ($this->onFulfilled) { + \call_user_func($this->onFulfilled, $value); + } + if (isset($options['sink'])) { + $contents = (string) $value->getBody(); + $sink = $options['sink']; + if (\is_resource($sink)) { + \fwrite($sink, $contents); + } elseif (\is_string($sink)) { + \file_put_contents($sink, $contents); + } elseif ($sink instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface) { + $sink->write($contents); + } + } + return $value; + }, function ($reason) use($request, $options) { + $this->invokeStats($request, $options, null, $reason); + if ($this->onRejected) { + \call_user_func($this->onRejected, $reason); + } + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($reason); + }); + } + /** + * Adds one or more variadic requests, exceptions, callables, or promises + * to the queue. + */ + public function append() + { + foreach (\func_get_args() as $value) { + if ($value instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface || $value instanceof \Exception || $value instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface || \is_callable($value)) { + $this->queue[] = $value; + } else { + throw new \InvalidArgumentException('Expected a response or ' . 'exception. Found ' . \_PhpScoper5ea00cc67502b\GuzzleHttp\describe_type($value)); + } + } + } + /** + * Get the last received request. + * + * @return RequestInterface + */ + public function getLastRequest() + { + return $this->lastRequest; + } + /** + * Get the last received request options. + * + * @return array + */ + public function getLastOptions() + { + return $this->lastOptions; + } + /** + * Returns the number of remaining items in the queue. + * + * @return int + */ + public function count() + { + return \count($this->queue); + } + public function reset() + { + $this->queue = []; + } + private function invokeStats(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response = null, $reason = null) + { + if (isset($options['on_stats'])) { + $transferTime = isset($options['transfer_time']) ? $options['transfer_time'] : 0; + $stats = new \_PhpScoper5ea00cc67502b\GuzzleHttp\TransferStats($request, $response, $transferTime, $reason); + \call_user_func($options['on_stats'], $stats); + } + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php b/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php index 99e0871aa..9ba476f0e 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php @@ -1,46 +1,46 @@ -withoutHeader('Expect'); - // Append a content-length header if body size is zero to match - // cURL's behavior. - if (0 === $request->getBody()->getSize()) { - $request = $request->withHeader('Content-Length', '0'); - } - return $this->createResponse($request, $options, $this->createStream($request, $options), $startTime); - } catch (\InvalidArgumentException $e) { - throw $e; - } catch (\Exception $e) { - // Determine if the error was a networking error. - $message = $e->getMessage(); - // This list can probably get more comprehensive. - if (\strpos($message, 'getaddrinfo') || \strpos($message, 'Connection refused') || \strpos($message, "couldn't connect to host") || \strpos($message, "connection attempt failed")) { - $e = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ConnectException($e->getMessage(), $request, $e); - } - $e = \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException::wrapException($request, $e); - $this->invokeStats($options, $request, $startTime, null, $e); - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($e); - } - } - private function invokeStats(array $options, \_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, $startTime, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response = null, $error = null) - { - if (isset($options['on_stats'])) { - $stats = new \_PhpScoper5ea00cc67502b\GuzzleHttp\TransferStats($request, $response, \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::currentTime() - $startTime, $error, []); - \call_user_func($options['on_stats'], $stats); - } - } - private function createResponse(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, $stream, $startTime) - { - $hdrs = $this->lastHeaders; - $this->lastHeaders = []; - $parts = \explode(' ', \array_shift($hdrs), 3); - $ver = \explode('/', $parts[0])[1]; - $status = $parts[1]; - $reason = isset($parts[2]) ? $parts[2] : null; - $headers = \_PhpScoper5ea00cc67502b\GuzzleHttp\headers_from_lines($hdrs); - list($stream, $headers) = $this->checkDecode($options, $headers, $stream); - $stream = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($stream); - $sink = $stream; - if (\strcasecmp('HEAD', $request->getMethod())) { - $sink = $this->createSink($stream, $options); - } - $response = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Response($status, $headers, $sink, $ver, $reason); - if (isset($options['on_headers'])) { - try { - $options['on_headers']($response); - } catch (\Exception $e) { - $msg = 'An error was encountered during the on_headers event'; - $ex = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException($msg, $request, $response, $e); - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($ex); - } - } - // Do not drain when the request is a HEAD request because they have - // no body. - if ($sink !== $stream) { - $this->drain($stream, $sink, $response->getHeaderLine('Content-Length')); - } - $this->invokeStats($options, $request, $startTime, $response, null); - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\FulfilledPromise($response); - } - private function createSink(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, array $options) - { - if (!empty($options['stream'])) { - return $stream; - } - $sink = isset($options['sink']) ? $options['sink'] : \fopen('php://temp', 'r+'); - return \is_string($sink) ? new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LazyOpenStream($sink, 'w+') : \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($sink); - } - private function checkDecode(array $options, array $headers, $stream) - { - // Automatically decode responses when instructed. - if (!empty($options['decode_content'])) { - $normalizedKeys = \_PhpScoper5ea00cc67502b\GuzzleHttp\normalize_header_keys($headers); - if (isset($normalizedKeys['content-encoding'])) { - $encoding = $headers[$normalizedKeys['content-encoding']]; - if ($encoding[0] === 'gzip' || $encoding[0] === 'deflate') { - $stream = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\InflateStream(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($stream)); - $headers['x-encoded-content-encoding'] = $headers[$normalizedKeys['content-encoding']]; - // Remove content-encoding header - unset($headers[$normalizedKeys['content-encoding']]); - // Fix content-length header - if (isset($normalizedKeys['content-length'])) { - $headers['x-encoded-content-length'] = $headers[$normalizedKeys['content-length']]; - $length = (int) $stream->getSize(); - if ($length === 0) { - unset($headers[$normalizedKeys['content-length']]); - } else { - $headers[$normalizedKeys['content-length']] = [$length]; - } - } - } - } - } - return [$stream, $headers]; - } - /** - * Drains the source stream into the "sink" client option. - * - * @param StreamInterface $source - * @param StreamInterface $sink - * @param string $contentLength Header specifying the amount of - * data to read. - * - * @return StreamInterface - * @throws \RuntimeException when the sink option is invalid. - */ - private function drain(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $source, \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $sink, $contentLength) - { - // If a content-length header is provided, then stop reading once - // that number of bytes has been read. This can prevent infinitely - // reading from a stream when dealing with servers that do not honor - // Connection: Close headers. - \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\copy_to_stream($source, $sink, \strlen($contentLength) > 0 && (int) $contentLength > 0 ? (int) $contentLength : -1); - $sink->seek(0); - $source->close(); - return $sink; - } - /** - * Create a resource and check to ensure it was created successfully - * - * @param callable $callback Callable that returns stream resource - * - * @return resource - * @throws \RuntimeException on error - */ - private function createResource(callable $callback) - { - $errors = null; - \set_error_handler(function ($_, $msg, $file, $line) use(&$errors) { - $errors[] = ['message' => $msg, 'file' => $file, 'line' => $line]; - return \true; - }); - $resource = $callback(); - \restore_error_handler(); - if (!$resource) { - $message = 'Error creating resource: '; - foreach ($errors as $err) { - foreach ($err as $key => $value) { - $message .= "[{$key}] {$value}" . \PHP_EOL; - } - } - throw new \RuntimeException(\trim($message)); - } - return $resource; - } - private function createStream(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - static $methods; - if (!$methods) { - $methods = \array_flip(\get_class_methods(__CLASS__)); - } - // HTTP/1.1 streams using the PHP stream wrapper require a - // Connection: close header - if ($request->getProtocolVersion() == '1.1' && !$request->hasHeader('Connection')) { - $request = $request->withHeader('Connection', 'close'); - } - // Ensure SSL is verified by default - if (!isset($options['verify'])) { - $options['verify'] = \true; - } - $params = []; - $context = $this->getDefaultContext($request); - if (isset($options['on_headers']) && !\is_callable($options['on_headers'])) { - throw new \InvalidArgumentException('on_headers must be callable'); - } - if (!empty($options)) { - foreach ($options as $key => $value) { - $method = "add_{$key}"; - if (isset($methods[$method])) { - $this->{$method}($request, $context, $value, $params); - } - } - } - if (isset($options['stream_context'])) { - if (!\is_array($options['stream_context'])) { - throw new \InvalidArgumentException('stream_context must be an array'); - } - $context = \array_replace_recursive($context, $options['stream_context']); - } - // Microsoft NTLM authentication only supported with curl handler - if (isset($options['auth']) && \is_array($options['auth']) && isset($options['auth'][2]) && 'ntlm' == $options['auth'][2]) { - throw new \InvalidArgumentException('Microsoft NTLM authentication only supported with curl handler'); - } - $uri = $this->resolveHost($request, $options); - $context = $this->createResource(function () use($context, $params) { - return \stream_context_create($context, $params); - }); - return $this->createResource(function () use($uri, &$http_response_header, $context, $options) { - $resource = \fopen((string) $uri, 'r', null, $context); - $this->lastHeaders = $http_response_header; - if (isset($options['read_timeout'])) { - $readTimeout = $options['read_timeout']; - $sec = (int) $readTimeout; - $usec = ($readTimeout - $sec) * 100000; - \stream_set_timeout($resource, $sec, $usec); - } - return $resource; - }); - } - private function resolveHost(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - $uri = $request->getUri(); - if (isset($options['force_ip_resolve']) && !\filter_var($uri->getHost(), \FILTER_VALIDATE_IP)) { - if ('v4' === $options['force_ip_resolve']) { - $records = \dns_get_record($uri->getHost(), \DNS_A); - if (!isset($records[0]['ip'])) { - throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ConnectException(\sprintf("Could not resolve IPv4 address for host '%s'", $uri->getHost()), $request); - } - $uri = $uri->withHost($records[0]['ip']); - } elseif ('v6' === $options['force_ip_resolve']) { - $records = \dns_get_record($uri->getHost(), \DNS_AAAA); - if (!isset($records[0]['ipv6'])) { - throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ConnectException(\sprintf("Could not resolve IPv6 address for host '%s'", $uri->getHost()), $request); - } - $uri = $uri->withHost('[' . $records[0]['ipv6'] . ']'); - } - } - return $uri; - } - private function getDefaultContext(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request) - { - $headers = ''; - foreach ($request->getHeaders() as $name => $value) { - foreach ($value as $val) { - $headers .= "{$name}: {$val}\r\n"; - } - } - $context = ['http' => ['method' => $request->getMethod(), 'header' => $headers, 'protocol_version' => $request->getProtocolVersion(), 'ignore_errors' => \true, 'follow_location' => 0]]; - $body = (string) $request->getBody(); - if (!empty($body)) { - $context['http']['content'] = $body; - // Prevent the HTTP handler from adding a Content-Type header. - if (!$request->hasHeader('Content-Type')) { - $context['http']['header'] .= "Content-Type:\r\n"; - } - } - $context['http']['header'] = \rtrim($context['http']['header']); - return $context; - } - private function add_proxy(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) - { - if (!\is_array($value)) { - $options['http']['proxy'] = $value; - } else { - $scheme = $request->getUri()->getScheme(); - if (isset($value[$scheme])) { - if (!isset($value['no']) || !\_PhpScoper5ea00cc67502b\GuzzleHttp\is_host_in_noproxy($request->getUri()->getHost(), $value['no'])) { - $options['http']['proxy'] = $value[$scheme]; - } - } - } - } - private function add_timeout(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) - { - if ($value > 0) { - $options['http']['timeout'] = $value; - } - } - private function add_verify(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) - { - if ($value === \true) { - // PHP 5.6 or greater will find the system cert by default. When - // < 5.6, use the Guzzle bundled cacert. - if (\PHP_VERSION_ID < 50600) { - $options['ssl']['cafile'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\default_ca_bundle(); - } - } elseif (\is_string($value)) { - $options['ssl']['cafile'] = $value; - if (!\file_exists($value)) { - throw new \RuntimeException("SSL CA bundle not found: {$value}"); - } - } elseif ($value === \false) { - $options['ssl']['verify_peer'] = \false; - $options['ssl']['verify_peer_name'] = \false; - return; - } else { - throw new \InvalidArgumentException('Invalid verify request option'); - } - $options['ssl']['verify_peer'] = \true; - $options['ssl']['verify_peer_name'] = \true; - $options['ssl']['allow_self_signed'] = \false; - } - private function add_cert(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) - { - if (\is_array($value)) { - $options['ssl']['passphrase'] = $value[1]; - $value = $value[0]; - } - if (!\file_exists($value)) { - throw new \RuntimeException("SSL certificate not found: {$value}"); - } - $options['ssl']['local_cert'] = $value; - } - private function add_progress(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) - { - $this->addNotification($params, function ($code, $a, $b, $c, $transferred, $total) use($value) { - if ($code == \STREAM_NOTIFY_PROGRESS) { - $value($total, $transferred, null, null); - } - }); - } - private function add_debug(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) - { - if ($value === \false) { - return; - } - static $map = [\STREAM_NOTIFY_CONNECT => 'CONNECT', \STREAM_NOTIFY_AUTH_REQUIRED => 'AUTH_REQUIRED', \STREAM_NOTIFY_AUTH_RESULT => 'AUTH_RESULT', \STREAM_NOTIFY_MIME_TYPE_IS => 'MIME_TYPE_IS', \STREAM_NOTIFY_FILE_SIZE_IS => 'FILE_SIZE_IS', \STREAM_NOTIFY_REDIRECTED => 'REDIRECTED', \STREAM_NOTIFY_PROGRESS => 'PROGRESS', \STREAM_NOTIFY_FAILURE => 'FAILURE', \STREAM_NOTIFY_COMPLETED => 'COMPLETED', \STREAM_NOTIFY_RESOLVE => 'RESOLVE']; - static $args = ['severity', 'message', 'message_code', 'bytes_transferred', 'bytes_max']; - $value = \_PhpScoper5ea00cc67502b\GuzzleHttp\debug_resource($value); - $ident = $request->getMethod() . ' ' . $request->getUri()->withFragment(''); - $this->addNotification($params, function () use($ident, $value, $map, $args) { - $passed = \func_get_args(); - $code = \array_shift($passed); - \fprintf($value, '<%s> [%s] ', $ident, $map[$code]); - foreach (\array_filter($passed) as $i => $v) { - \fwrite($value, $args[$i] . ': "' . $v . '" '); - } - \fwrite($value, "\n"); - }); - } - private function addNotification(array &$params, callable $notify) - { - // Wrap the existing function if needed. - if (!isset($params['notification'])) { - $params['notification'] = $notify; - } else { - $params['notification'] = $this->callArray([$params['notification'], $notify]); - } - } - private function callArray(array $functions) - { - return function () use($functions) { - $args = \func_get_args(); - foreach ($functions as $fn) { - \call_user_func_array($fn, $args); - } - }; - } -} +withoutHeader('Expect'); + // Append a content-length header if body size is zero to match + // cURL's behavior. + if (0 === $request->getBody()->getSize()) { + $request = $request->withHeader('Content-Length', '0'); + } + return $this->createResponse($request, $options, $this->createStream($request, $options), $startTime); + } catch (\InvalidArgumentException $e) { + throw $e; + } catch (\Exception $e) { + // Determine if the error was a networking error. + $message = $e->getMessage(); + // This list can probably get more comprehensive. + if (\strpos($message, 'getaddrinfo') || \strpos($message, 'Connection refused') || \strpos($message, "couldn't connect to host") || \strpos($message, "connection attempt failed")) { + $e = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ConnectException($e->getMessage(), $request, $e); + } + $e = \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException::wrapException($request, $e); + $this->invokeStats($options, $request, $startTime, null, $e); + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($e); + } + } + private function invokeStats(array $options, \_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, $startTime, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response = null, $error = null) + { + if (isset($options['on_stats'])) { + $stats = new \_PhpScoper5ea00cc67502b\GuzzleHttp\TransferStats($request, $response, \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::currentTime() - $startTime, $error, []); + \call_user_func($options['on_stats'], $stats); + } + } + private function createResponse(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, $stream, $startTime) + { + $hdrs = $this->lastHeaders; + $this->lastHeaders = []; + $parts = \explode(' ', \array_shift($hdrs), 3); + $ver = \explode('/', $parts[0])[1]; + $status = $parts[1]; + $reason = isset($parts[2]) ? $parts[2] : null; + $headers = \_PhpScoper5ea00cc67502b\GuzzleHttp\headers_from_lines($hdrs); + list($stream, $headers) = $this->checkDecode($options, $headers, $stream); + $stream = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($stream); + $sink = $stream; + if (\strcasecmp('HEAD', $request->getMethod())) { + $sink = $this->createSink($stream, $options); + } + $response = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Response($status, $headers, $sink, $ver, $reason); + if (isset($options['on_headers'])) { + try { + $options['on_headers']($response); + } catch (\Exception $e) { + $msg = 'An error was encountered during the on_headers event'; + $ex = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException($msg, $request, $response, $e); + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($ex); + } + } + // Do not drain when the request is a HEAD request because they have + // no body. + if ($sink !== $stream) { + $this->drain($stream, $sink, $response->getHeaderLine('Content-Length')); + } + $this->invokeStats($options, $request, $startTime, $response, null); + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\FulfilledPromise($response); + } + private function createSink(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, array $options) + { + if (!empty($options['stream'])) { + return $stream; + } + $sink = isset($options['sink']) ? $options['sink'] : \fopen('php://temp', 'r+'); + return \is_string($sink) ? new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LazyOpenStream($sink, 'w+') : \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($sink); + } + private function checkDecode(array $options, array $headers, $stream) + { + // Automatically decode responses when instructed. + if (!empty($options['decode_content'])) { + $normalizedKeys = \_PhpScoper5ea00cc67502b\GuzzleHttp\normalize_header_keys($headers); + if (isset($normalizedKeys['content-encoding'])) { + $encoding = $headers[$normalizedKeys['content-encoding']]; + if ($encoding[0] === 'gzip' || $encoding[0] === 'deflate') { + $stream = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\InflateStream(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\stream_for($stream)); + $headers['x-encoded-content-encoding'] = $headers[$normalizedKeys['content-encoding']]; + // Remove content-encoding header + unset($headers[$normalizedKeys['content-encoding']]); + // Fix content-length header + if (isset($normalizedKeys['content-length'])) { + $headers['x-encoded-content-length'] = $headers[$normalizedKeys['content-length']]; + $length = (int) $stream->getSize(); + if ($length === 0) { + unset($headers[$normalizedKeys['content-length']]); + } else { + $headers[$normalizedKeys['content-length']] = [$length]; + } + } + } + } + } + return [$stream, $headers]; + } + /** + * Drains the source stream into the "sink" client option. + * + * @param StreamInterface $source + * @param StreamInterface $sink + * @param string $contentLength Header specifying the amount of + * data to read. + * + * @return StreamInterface + * @throws \RuntimeException when the sink option is invalid. + */ + private function drain(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $source, \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $sink, $contentLength) + { + // If a content-length header is provided, then stop reading once + // that number of bytes has been read. This can prevent infinitely + // reading from a stream when dealing with servers that do not honor + // Connection: Close headers. + \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\copy_to_stream($source, $sink, \strlen($contentLength) > 0 && (int) $contentLength > 0 ? (int) $contentLength : -1); + $sink->seek(0); + $source->close(); + return $sink; + } + /** + * Create a resource and check to ensure it was created successfully + * + * @param callable $callback Callable that returns stream resource + * + * @return resource + * @throws \RuntimeException on error + */ + private function createResource(callable $callback) + { + $errors = null; + \set_error_handler(function ($_, $msg, $file, $line) use(&$errors) { + $errors[] = ['message' => $msg, 'file' => $file, 'line' => $line]; + return \true; + }); + $resource = $callback(); + \restore_error_handler(); + if (!$resource) { + $message = 'Error creating resource: '; + foreach ($errors as $err) { + foreach ($err as $key => $value) { + $message .= "[{$key}] {$value}" . \PHP_EOL; + } + } + throw new \RuntimeException(\trim($message)); + } + return $resource; + } + private function createStream(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + static $methods; + if (!$methods) { + $methods = \array_flip(\get_class_methods(__CLASS__)); + } + // HTTP/1.1 streams using the PHP stream wrapper require a + // Connection: close header + if ($request->getProtocolVersion() == '1.1' && !$request->hasHeader('Connection')) { + $request = $request->withHeader('Connection', 'close'); + } + // Ensure SSL is verified by default + if (!isset($options['verify'])) { + $options['verify'] = \true; + } + $params = []; + $context = $this->getDefaultContext($request); + if (isset($options['on_headers']) && !\is_callable($options['on_headers'])) { + throw new \InvalidArgumentException('on_headers must be callable'); + } + if (!empty($options)) { + foreach ($options as $key => $value) { + $method = "add_{$key}"; + if (isset($methods[$method])) { + $this->{$method}($request, $context, $value, $params); + } + } + } + if (isset($options['stream_context'])) { + if (!\is_array($options['stream_context'])) { + throw new \InvalidArgumentException('stream_context must be an array'); + } + $context = \array_replace_recursive($context, $options['stream_context']); + } + // Microsoft NTLM authentication only supported with curl handler + if (isset($options['auth']) && \is_array($options['auth']) && isset($options['auth'][2]) && 'ntlm' == $options['auth'][2]) { + throw new \InvalidArgumentException('Microsoft NTLM authentication only supported with curl handler'); + } + $uri = $this->resolveHost($request, $options); + $context = $this->createResource(function () use($context, $params) { + return \stream_context_create($context, $params); + }); + return $this->createResource(function () use($uri, &$http_response_header, $context, $options) { + $resource = \fopen((string) $uri, 'r', null, $context); + $this->lastHeaders = $http_response_header; + if (isset($options['read_timeout'])) { + $readTimeout = $options['read_timeout']; + $sec = (int) $readTimeout; + $usec = ($readTimeout - $sec) * 100000; + \stream_set_timeout($resource, $sec, $usec); + } + return $resource; + }); + } + private function resolveHost(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + $uri = $request->getUri(); + if (isset($options['force_ip_resolve']) && !\filter_var($uri->getHost(), \FILTER_VALIDATE_IP)) { + if ('v4' === $options['force_ip_resolve']) { + $records = \dns_get_record($uri->getHost(), \DNS_A); + if (!isset($records[0]['ip'])) { + throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ConnectException(\sprintf("Could not resolve IPv4 address for host '%s'", $uri->getHost()), $request); + } + $uri = $uri->withHost($records[0]['ip']); + } elseif ('v6' === $options['force_ip_resolve']) { + $records = \dns_get_record($uri->getHost(), \DNS_AAAA); + if (!isset($records[0]['ipv6'])) { + throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\ConnectException(\sprintf("Could not resolve IPv6 address for host '%s'", $uri->getHost()), $request); + } + $uri = $uri->withHost('[' . $records[0]['ipv6'] . ']'); + } + } + return $uri; + } + private function getDefaultContext(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request) + { + $headers = ''; + foreach ($request->getHeaders() as $name => $value) { + foreach ($value as $val) { + $headers .= "{$name}: {$val}\r\n"; + } + } + $context = ['http' => ['method' => $request->getMethod(), 'header' => $headers, 'protocol_version' => $request->getProtocolVersion(), 'ignore_errors' => \true, 'follow_location' => 0]]; + $body = (string) $request->getBody(); + if (!empty($body)) { + $context['http']['content'] = $body; + // Prevent the HTTP handler from adding a Content-Type header. + if (!$request->hasHeader('Content-Type')) { + $context['http']['header'] .= "Content-Type:\r\n"; + } + } + $context['http']['header'] = \rtrim($context['http']['header']); + return $context; + } + private function add_proxy(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) + { + if (!\is_array($value)) { + $options['http']['proxy'] = $value; + } else { + $scheme = $request->getUri()->getScheme(); + if (isset($value[$scheme])) { + if (!isset($value['no']) || !\_PhpScoper5ea00cc67502b\GuzzleHttp\is_host_in_noproxy($request->getUri()->getHost(), $value['no'])) { + $options['http']['proxy'] = $value[$scheme]; + } + } + } + } + private function add_timeout(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) + { + if ($value > 0) { + $options['http']['timeout'] = $value; + } + } + private function add_verify(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) + { + if ($value === \true) { + // PHP 5.6 or greater will find the system cert by default. When + // < 5.6, use the Guzzle bundled cacert. + if (\PHP_VERSION_ID < 50600) { + $options['ssl']['cafile'] = \_PhpScoper5ea00cc67502b\GuzzleHttp\default_ca_bundle(); + } + } elseif (\is_string($value)) { + $options['ssl']['cafile'] = $value; + if (!\file_exists($value)) { + throw new \RuntimeException("SSL CA bundle not found: {$value}"); + } + } elseif ($value === \false) { + $options['ssl']['verify_peer'] = \false; + $options['ssl']['verify_peer_name'] = \false; + return; + } else { + throw new \InvalidArgumentException('Invalid verify request option'); + } + $options['ssl']['verify_peer'] = \true; + $options['ssl']['verify_peer_name'] = \true; + $options['ssl']['allow_self_signed'] = \false; + } + private function add_cert(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) + { + if (\is_array($value)) { + $options['ssl']['passphrase'] = $value[1]; + $value = $value[0]; + } + if (!\file_exists($value)) { + throw new \RuntimeException("SSL certificate not found: {$value}"); + } + $options['ssl']['local_cert'] = $value; + } + private function add_progress(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) + { + $this->addNotification($params, function ($code, $a, $b, $c, $transferred, $total) use($value) { + if ($code == \STREAM_NOTIFY_PROGRESS) { + $value($total, $transferred, null, null); + } + }); + } + private function add_debug(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, &$options, $value, &$params) + { + if ($value === \false) { + return; + } + static $map = [\STREAM_NOTIFY_CONNECT => 'CONNECT', \STREAM_NOTIFY_AUTH_REQUIRED => 'AUTH_REQUIRED', \STREAM_NOTIFY_AUTH_RESULT => 'AUTH_RESULT', \STREAM_NOTIFY_MIME_TYPE_IS => 'MIME_TYPE_IS', \STREAM_NOTIFY_FILE_SIZE_IS => 'FILE_SIZE_IS', \STREAM_NOTIFY_REDIRECTED => 'REDIRECTED', \STREAM_NOTIFY_PROGRESS => 'PROGRESS', \STREAM_NOTIFY_FAILURE => 'FAILURE', \STREAM_NOTIFY_COMPLETED => 'COMPLETED', \STREAM_NOTIFY_RESOLVE => 'RESOLVE']; + static $args = ['severity', 'message', 'message_code', 'bytes_transferred', 'bytes_max']; + $value = \_PhpScoper5ea00cc67502b\GuzzleHttp\debug_resource($value); + $ident = $request->getMethod() . ' ' . $request->getUri()->withFragment(''); + $this->addNotification($params, function () use($ident, $value, $map, $args) { + $passed = \func_get_args(); + $code = \array_shift($passed); + \fprintf($value, '<%s> [%s] ', $ident, $map[$code]); + foreach (\array_filter($passed) as $i => $v) { + \fwrite($value, $args[$i] . ': "' . $v . '" '); + } + \fwrite($value, "\n"); + }); + } + private function addNotification(array &$params, callable $notify) + { + // Wrap the existing function if needed. + if (!isset($params['notification'])) { + $params['notification'] = $notify; + } else { + $params['notification'] = $this->callArray([$params['notification'], $notify]); + } + } + private function callArray(array $functions) + { + return function () use($functions) { + $args = \func_get_args(); + foreach ($functions as $fn) { + \call_user_func_array($fn, $args); + } + }; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Handler/index.php b/vendor/guzzlehttp/guzzle/src/Handler/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/guzzlehttp/guzzle/src/Handler/index.php +++ b/vendor/guzzlehttp/guzzle/src/Handler/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/guzzle/src/HandlerStack.php b/vendor/guzzlehttp/guzzle/src/HandlerStack.php index 8dfb7d650..c5481b649 100644 --- a/vendor/guzzlehttp/guzzle/src/HandlerStack.php +++ b/vendor/guzzlehttp/guzzle/src/HandlerStack.php @@ -1,243 +1,243 @@ -push(\_PhpScoper5ea00cc67502b\GuzzleHttp\Middleware::httpErrors(), 'http_errors'); - $stack->push(\_PhpScoper5ea00cc67502b\GuzzleHttp\Middleware::redirect(), 'allow_redirects'); - $stack->push(\_PhpScoper5ea00cc67502b\GuzzleHttp\Middleware::cookies(), 'cookies'); - $stack->push(\_PhpScoper5ea00cc67502b\GuzzleHttp\Middleware::prepareBody(), 'prepare_body'); - return $stack; - } - /** - * @param callable $handler Underlying HTTP handler. - */ - public function __construct(callable $handler = null) - { - $this->handler = $handler; - } - /** - * Invokes the handler stack as a composed handler - * - * @param RequestInterface $request - * @param array $options - * - * @return ResponseInterface|PromiseInterface - */ - public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - $handler = $this->resolve(); - return $handler($request, $options); - } - /** - * Dumps a string representation of the stack. - * - * @return string - */ - public function __toString() - { - $depth = 0; - $stack = []; - if ($this->handler) { - $stack[] = "0) Handler: " . $this->debugCallable($this->handler); - } - $result = ''; - foreach (\array_reverse($this->stack) as $tuple) { - $depth++; - $str = "{$depth}) Name: '{$tuple[1]}', "; - $str .= "Function: " . $this->debugCallable($tuple[0]); - $result = "> {$str}\n{$result}"; - $stack[] = $str; - } - foreach (\array_keys($stack) as $k) { - $result .= "< {$stack[$k]}\n"; - } - return $result; - } - /** - * Set the HTTP handler that actually returns a promise. - * - * @param callable $handler Accepts a request and array of options and - * returns a Promise. - */ - public function setHandler(callable $handler) - { - $this->handler = $handler; - $this->cached = null; - } - /** - * Returns true if the builder has a handler. - * - * @return bool - */ - public function hasHandler() - { - return (bool) $this->handler; - } - /** - * Unshift a middleware to the bottom of the stack. - * - * @param callable $middleware Middleware function - * @param string $name Name to register for this middleware. - */ - public function unshift(callable $middleware, $name = null) - { - \array_unshift($this->stack, [$middleware, $name]); - $this->cached = null; - } - /** - * Push a middleware to the top of the stack. - * - * @param callable $middleware Middleware function - * @param string $name Name to register for this middleware. - */ - public function push(callable $middleware, $name = '') - { - $this->stack[] = [$middleware, $name]; - $this->cached = null; - } - /** - * Add a middleware before another middleware by name. - * - * @param string $findName Middleware to find - * @param callable $middleware Middleware function - * @param string $withName Name to register for this middleware. - */ - public function before($findName, callable $middleware, $withName = '') - { - $this->splice($findName, $withName, $middleware, \true); - } - /** - * Add a middleware after another middleware by name. - * - * @param string $findName Middleware to find - * @param callable $middleware Middleware function - * @param string $withName Name to register for this middleware. - */ - public function after($findName, callable $middleware, $withName = '') - { - $this->splice($findName, $withName, $middleware, \false); - } - /** - * Remove a middleware by instance or name from the stack. - * - * @param callable|string $remove Middleware to remove by instance or name. - */ - public function remove($remove) - { - $this->cached = null; - $idx = \is_callable($remove) ? 0 : 1; - $this->stack = \array_values(\array_filter($this->stack, function ($tuple) use($idx, $remove) { - return $tuple[$idx] !== $remove; - })); - } - /** - * Compose the middleware and handler into a single callable function. - * - * @return callable - */ - public function resolve() - { - if (!$this->cached) { - if (!($prev = $this->handler)) { - throw new \LogicException('No handler has been specified'); - } - foreach (\array_reverse($this->stack) as $fn) { - $prev = $fn[0]($prev); - } - $this->cached = $prev; - } - return $this->cached; - } - /** - * @param string $name - * @return int - */ - private function findByName($name) - { - foreach ($this->stack as $k => $v) { - if ($v[1] === $name) { - return $k; - } - } - throw new \InvalidArgumentException("Middleware not found: {$name}"); - } - /** - * Splices a function into the middleware list at a specific position. - * - * @param string $findName - * @param string $withName - * @param callable $middleware - * @param bool $before - */ - private function splice($findName, $withName, callable $middleware, $before) - { - $this->cached = null; - $idx = $this->findByName($findName); - $tuple = [$middleware, $withName]; - if ($before) { - if ($idx === 0) { - \array_unshift($this->stack, $tuple); - } else { - $replacement = [$tuple, $this->stack[$idx]]; - \array_splice($this->stack, $idx, 1, $replacement); - } - } elseif ($idx === \count($this->stack) - 1) { - $this->stack[] = $tuple; - } else { - $replacement = [$this->stack[$idx], $tuple]; - \array_splice($this->stack, $idx, 1, $replacement); - } - } - /** - * Provides a debug string for a given callable. - * - * @param array|callable $fn Function to write as a string. - * - * @return string - */ - private function debugCallable($fn) - { - if (\is_string($fn)) { - return "callable({$fn})"; - } - if (\is_array($fn)) { - return \is_string($fn[0]) ? "callable({$fn[0]}::{$fn[1]})" : "callable(['" . \get_class($fn[0]) . "', '{$fn[1]}'])"; - } - return 'callable(' . \spl_object_hash($fn) . ')'; - } -} +push(\_PhpScoper5ea00cc67502b\GuzzleHttp\Middleware::httpErrors(), 'http_errors'); + $stack->push(\_PhpScoper5ea00cc67502b\GuzzleHttp\Middleware::redirect(), 'allow_redirects'); + $stack->push(\_PhpScoper5ea00cc67502b\GuzzleHttp\Middleware::cookies(), 'cookies'); + $stack->push(\_PhpScoper5ea00cc67502b\GuzzleHttp\Middleware::prepareBody(), 'prepare_body'); + return $stack; + } + /** + * @param callable $handler Underlying HTTP handler. + */ + public function __construct(callable $handler = null) + { + $this->handler = $handler; + } + /** + * Invokes the handler stack as a composed handler + * + * @param RequestInterface $request + * @param array $options + * + * @return ResponseInterface|PromiseInterface + */ + public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + $handler = $this->resolve(); + return $handler($request, $options); + } + /** + * Dumps a string representation of the stack. + * + * @return string + */ + public function __toString() + { + $depth = 0; + $stack = []; + if ($this->handler) { + $stack[] = "0) Handler: " . $this->debugCallable($this->handler); + } + $result = ''; + foreach (\array_reverse($this->stack) as $tuple) { + $depth++; + $str = "{$depth}) Name: '{$tuple[1]}', "; + $str .= "Function: " . $this->debugCallable($tuple[0]); + $result = "> {$str}\n{$result}"; + $stack[] = $str; + } + foreach (\array_keys($stack) as $k) { + $result .= "< {$stack[$k]}\n"; + } + return $result; + } + /** + * Set the HTTP handler that actually returns a promise. + * + * @param callable $handler Accepts a request and array of options and + * returns a Promise. + */ + public function setHandler(callable $handler) + { + $this->handler = $handler; + $this->cached = null; + } + /** + * Returns true if the builder has a handler. + * + * @return bool + */ + public function hasHandler() + { + return (bool) $this->handler; + } + /** + * Unshift a middleware to the bottom of the stack. + * + * @param callable $middleware Middleware function + * @param string $name Name to register for this middleware. + */ + public function unshift(callable $middleware, $name = null) + { + \array_unshift($this->stack, [$middleware, $name]); + $this->cached = null; + } + /** + * Push a middleware to the top of the stack. + * + * @param callable $middleware Middleware function + * @param string $name Name to register for this middleware. + */ + public function push(callable $middleware, $name = '') + { + $this->stack[] = [$middleware, $name]; + $this->cached = null; + } + /** + * Add a middleware before another middleware by name. + * + * @param string $findName Middleware to find + * @param callable $middleware Middleware function + * @param string $withName Name to register for this middleware. + */ + public function before($findName, callable $middleware, $withName = '') + { + $this->splice($findName, $withName, $middleware, \true); + } + /** + * Add a middleware after another middleware by name. + * + * @param string $findName Middleware to find + * @param callable $middleware Middleware function + * @param string $withName Name to register for this middleware. + */ + public function after($findName, callable $middleware, $withName = '') + { + $this->splice($findName, $withName, $middleware, \false); + } + /** + * Remove a middleware by instance or name from the stack. + * + * @param callable|string $remove Middleware to remove by instance or name. + */ + public function remove($remove) + { + $this->cached = null; + $idx = \is_callable($remove) ? 0 : 1; + $this->stack = \array_values(\array_filter($this->stack, function ($tuple) use($idx, $remove) { + return $tuple[$idx] !== $remove; + })); + } + /** + * Compose the middleware and handler into a single callable function. + * + * @return callable + */ + public function resolve() + { + if (!$this->cached) { + if (!($prev = $this->handler)) { + throw new \LogicException('No handler has been specified'); + } + foreach (\array_reverse($this->stack) as $fn) { + $prev = $fn[0]($prev); + } + $this->cached = $prev; + } + return $this->cached; + } + /** + * @param string $name + * @return int + */ + private function findByName($name) + { + foreach ($this->stack as $k => $v) { + if ($v[1] === $name) { + return $k; + } + } + throw new \InvalidArgumentException("Middleware not found: {$name}"); + } + /** + * Splices a function into the middleware list at a specific position. + * + * @param string $findName + * @param string $withName + * @param callable $middleware + * @param bool $before + */ + private function splice($findName, $withName, callable $middleware, $before) + { + $this->cached = null; + $idx = $this->findByName($findName); + $tuple = [$middleware, $withName]; + if ($before) { + if ($idx === 0) { + \array_unshift($this->stack, $tuple); + } else { + $replacement = [$tuple, $this->stack[$idx]]; + \array_splice($this->stack, $idx, 1, $replacement); + } + } elseif ($idx === \count($this->stack) - 1) { + $this->stack[] = $tuple; + } else { + $replacement = [$this->stack[$idx], $tuple]; + \array_splice($this->stack, $idx, 1, $replacement); + } + } + /** + * Provides a debug string for a given callable. + * + * @param array|callable $fn Function to write as a string. + * + * @return string + */ + private function debugCallable($fn) + { + if (\is_string($fn)) { + return "callable({$fn})"; + } + if (\is_array($fn)) { + return \is_string($fn[0]) ? "callable({$fn[0]}::{$fn[1]})" : "callable(['" . \get_class($fn[0]) . "', '{$fn[1]}'])"; + } + return 'callable(' . \spl_object_hash($fn) . ')'; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/MessageFormatter.php b/vendor/guzzlehttp/guzzle/src/MessageFormatter.php index f5ca563c6..874106760 100644 --- a/vendor/guzzlehttp/guzzle/src/MessageFormatter.php +++ b/vendor/guzzlehttp/guzzle/src/MessageFormatter.php @@ -1,156 +1,156 @@ ->>>>>>>\n{request}\n<<<<<<<<\n{response}\n--------\n{error}"; - const SHORT = '[{ts}] "{method} {target} HTTP/{version}" {code}'; - /** @var string Template used to format log messages */ - private $template; - /** - * @param string $template Log message template - */ - public function __construct($template = self::CLF) - { - $this->template = $template ?: self::CLF; - } - /** - * Returns a formatted message string. - * - * @param RequestInterface $request Request that was sent - * @param ResponseInterface $response Response that was received - * @param \Exception $error Exception that was received - * - * @return string - */ - public function format(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response = null, \Exception $error = null) - { - $cache = []; - return \preg_replace_callback('/{\\s*([A-Za-z_\\-\\.0-9]+)\\s*}/', function (array $matches) use($request, $response, $error, &$cache) { - if (isset($cache[$matches[1]])) { - return $cache[$matches[1]]; - } - $result = ''; - switch ($matches[1]) { - case 'request': - $result = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\str($request); - break; - case 'response': - $result = $response ? \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\str($response) : ''; - break; - case 'req_headers': - $result = \trim($request->getMethod() . ' ' . $request->getRequestTarget()) . ' HTTP/' . $request->getProtocolVersion() . "\r\n" . $this->headers($request); - break; - case 'res_headers': - $result = $response ? \sprintf('HTTP/%s %d %s', $response->getProtocolVersion(), $response->getStatusCode(), $response->getReasonPhrase()) . "\r\n" . $this->headers($response) : 'NULL'; - break; - case 'req_body': - $result = $request->getBody(); - break; - case 'res_body': - $result = $response ? $response->getBody() : 'NULL'; - break; - case 'ts': - case 'date_iso_8601': - $result = \gmdate('c'); - break; - case 'date_common_log': - $result = \date('d/M/Y:H:i:s O'); - break; - case 'method': - $result = $request->getMethod(); - break; - case 'version': - $result = $request->getProtocolVersion(); - break; - case 'uri': - case 'url': - $result = $request->getUri(); - break; - case 'target': - $result = $request->getRequestTarget(); - break; - case 'req_version': - $result = $request->getProtocolVersion(); - break; - case 'res_version': - $result = $response ? $response->getProtocolVersion() : 'NULL'; - break; - case 'host': - $result = $request->getHeaderLine('Host'); - break; - case 'hostname': - $result = \gethostname(); - break; - case 'code': - $result = $response ? $response->getStatusCode() : 'NULL'; - break; - case 'phrase': - $result = $response ? $response->getReasonPhrase() : 'NULL'; - break; - case 'error': - $result = $error ? $error->getMessage() : 'NULL'; - break; - default: - // handle prefixed dynamic headers - if (\strpos($matches[1], 'req_header_') === 0) { - $result = $request->getHeaderLine(\substr($matches[1], 11)); - } elseif (\strpos($matches[1], 'res_header_') === 0) { - $result = $response ? $response->getHeaderLine(\substr($matches[1], 11)) : 'NULL'; - } - } - $cache[$matches[1]] = $result; - return $result; - }, $this->template); - } - /** - * Get headers from message as string - * - * @return string - */ - private function headers(\_PhpScoper5ea00cc67502b\Psr\Http\Message\MessageInterface $message) - { - $result = ''; - foreach ($message->getHeaders() as $name => $values) { - $result .= $name . ': ' . \implode(', ', $values) . "\r\n"; - } - return \trim($result); - } -} +>>>>>>>\n{request}\n<<<<<<<<\n{response}\n--------\n{error}"; + const SHORT = '[{ts}] "{method} {target} HTTP/{version}" {code}'; + /** @var string Template used to format log messages */ + private $template; + /** + * @param string $template Log message template + */ + public function __construct($template = self::CLF) + { + $this->template = $template ?: self::CLF; + } + /** + * Returns a formatted message string. + * + * @param RequestInterface $request Request that was sent + * @param ResponseInterface $response Response that was received + * @param \Exception $error Exception that was received + * + * @return string + */ + public function format(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response = null, \Exception $error = null) + { + $cache = []; + return \preg_replace_callback('/{\\s*([A-Za-z_\\-\\.0-9]+)\\s*}/', function (array $matches) use($request, $response, $error, &$cache) { + if (isset($cache[$matches[1]])) { + return $cache[$matches[1]]; + } + $result = ''; + switch ($matches[1]) { + case 'request': + $result = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\str($request); + break; + case 'response': + $result = $response ? \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\str($response) : ''; + break; + case 'req_headers': + $result = \trim($request->getMethod() . ' ' . $request->getRequestTarget()) . ' HTTP/' . $request->getProtocolVersion() . "\r\n" . $this->headers($request); + break; + case 'res_headers': + $result = $response ? \sprintf('HTTP/%s %d %s', $response->getProtocolVersion(), $response->getStatusCode(), $response->getReasonPhrase()) . "\r\n" . $this->headers($response) : 'NULL'; + break; + case 'req_body': + $result = $request->getBody(); + break; + case 'res_body': + $result = $response ? $response->getBody() : 'NULL'; + break; + case 'ts': + case 'date_iso_8601': + $result = \gmdate('c'); + break; + case 'date_common_log': + $result = \date('d/M/Y:H:i:s O'); + break; + case 'method': + $result = $request->getMethod(); + break; + case 'version': + $result = $request->getProtocolVersion(); + break; + case 'uri': + case 'url': + $result = $request->getUri(); + break; + case 'target': + $result = $request->getRequestTarget(); + break; + case 'req_version': + $result = $request->getProtocolVersion(); + break; + case 'res_version': + $result = $response ? $response->getProtocolVersion() : 'NULL'; + break; + case 'host': + $result = $request->getHeaderLine('Host'); + break; + case 'hostname': + $result = \gethostname(); + break; + case 'code': + $result = $response ? $response->getStatusCode() : 'NULL'; + break; + case 'phrase': + $result = $response ? $response->getReasonPhrase() : 'NULL'; + break; + case 'error': + $result = $error ? $error->getMessage() : 'NULL'; + break; + default: + // handle prefixed dynamic headers + if (\strpos($matches[1], 'req_header_') === 0) { + $result = $request->getHeaderLine(\substr($matches[1], 11)); + } elseif (\strpos($matches[1], 'res_header_') === 0) { + $result = $response ? $response->getHeaderLine(\substr($matches[1], 11)) : 'NULL'; + } + } + $cache[$matches[1]] = $result; + return $result; + }, $this->template); + } + /** + * Get headers from message as string + * + * @return string + */ + private function headers(\_PhpScoper5ea00cc67502b\Psr\Http\Message\MessageInterface $message) + { + $result = ''; + foreach ($message->getHeaders() as $name => $values) { + $result .= $name . ': ' . \implode(', ', $values) . "\r\n"; + } + return \trim($result); + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Middleware.php b/vendor/guzzlehttp/guzzle/src/Middleware.php index 44f5ef25f..c856627bf 100644 --- a/vendor/guzzlehttp/guzzle/src/Middleware.php +++ b/vendor/guzzlehttp/guzzle/src/Middleware.php @@ -1,221 +1,221 @@ -withCookieHeader($request); - return $handler($request, $options)->then(function ($response) use($cookieJar, $request) { - $cookieJar->extractCookies($request, $response); - return $response; - }); - }; - }; - } - /** - * Middleware that throws exceptions for 4xx or 5xx responses when the - * "http_error" request option is set to true. - * - * @return callable Returns a function that accepts the next handler. - */ - public static function httpErrors() - { - return function (callable $handler) { - return function ($request, array $options) use($handler) { - if (empty($options['http_errors'])) { - return $handler($request, $options); - } - return $handler($request, $options)->then(function (\_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) use($request) { - $code = $response->getStatusCode(); - if ($code < 400) { - return $response; - } - throw \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException::create($request, $response); - }); - }; - }; - } - /** - * Middleware that pushes history data to an ArrayAccess container. - * - * @param array|\ArrayAccess $container Container to hold the history (by reference). - * - * @return callable Returns a function that accepts the next handler. - * @throws \InvalidArgumentException if container is not an array or ArrayAccess. - */ - public static function history(&$container) - { - if (!\is_array($container) && !$container instanceof \ArrayAccess) { - throw new \InvalidArgumentException('history container must be an array or object implementing ArrayAccess'); - } - return function (callable $handler) use(&$container) { - return function ($request, array $options) use($handler, &$container) { - return $handler($request, $options)->then(function ($value) use($request, &$container, $options) { - $container[] = ['request' => $request, 'response' => $value, 'error' => null, 'options' => $options]; - return $value; - }, function ($reason) use($request, &$container, $options) { - $container[] = ['request' => $request, 'response' => null, 'error' => $reason, 'options' => $options]; - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($reason); - }); - }; - }; - } - /** - * Middleware that invokes a callback before and after sending a request. - * - * The provided listener cannot modify or alter the response. It simply - * "taps" into the chain to be notified before returning the promise. The - * before listener accepts a request and options array, and the after - * listener accepts a request, options array, and response promise. - * - * @param callable $before Function to invoke before forwarding the request. - * @param callable $after Function invoked after forwarding. - * - * @return callable Returns a function that accepts the next handler. - */ - public static function tap(callable $before = null, callable $after = null) - { - return function (callable $handler) use($before, $after) { - return function ($request, array $options) use($handler, $before, $after) { - if ($before) { - $before($request, $options); - } - $response = $handler($request, $options); - if ($after) { - $after($request, $options, $response); - } - return $response; - }; - }; - } - /** - * Middleware that handles request redirects. - * - * @return callable Returns a function that accepts the next handler. - */ - public static function redirect() - { - return function (callable $handler) { - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\RedirectMiddleware($handler); - }; - } - /** - * Middleware that retries requests based on the boolean result of - * invoking the provided "decider" function. - * - * If no delay function is provided, a simple implementation of exponential - * backoff will be utilized. - * - * @param callable $decider Function that accepts the number of retries, - * a request, [response], and [exception] and - * returns true if the request is to be retried. - * @param callable $delay Function that accepts the number of retries and - * returns the number of milliseconds to delay. - * - * @return callable Returns a function that accepts the next handler. - */ - public static function retry(callable $decider, callable $delay = null) - { - return function (callable $handler) use($decider, $delay) { - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\RetryMiddleware($decider, $handler, $delay); - }; - } - /** - * Middleware that logs requests, responses, and errors using a message - * formatter. - * - * @param LoggerInterface $logger Logs messages. - * @param MessageFormatter $formatter Formatter used to create message strings. - * @param string $logLevel Level at which to log requests. - * - * @return callable Returns a function that accepts the next handler. - */ - public static function log(\_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger, \_PhpScoper5ea00cc67502b\GuzzleHttp\MessageFormatter $formatter, $logLevel = 'info') - { - return function (callable $handler) use($logger, $formatter, $logLevel) { - return function ($request, array $options) use($handler, $logger, $formatter, $logLevel) { - return $handler($request, $options)->then(function ($response) use($logger, $request, $formatter, $logLevel) { - $message = $formatter->format($request, $response); - $logger->log($logLevel, $message); - return $response; - }, function ($reason) use($logger, $request, $formatter) { - $response = $reason instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException ? $reason->getResponse() : null; - $message = $formatter->format($request, $response, $reason); - $logger->notice($message); - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($reason); - }); - }; - }; - } - /** - * This middleware adds a default content-type if possible, a default - * content-length or transfer-encoding header, and the expect header. - * - * @return callable - */ - public static function prepareBody() - { - return function (callable $handler) { - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\PrepareBodyMiddleware($handler); - }; - } - /** - * Middleware that applies a map function to the request before passing to - * the next handler. - * - * @param callable $fn Function that accepts a RequestInterface and returns - * a RequestInterface. - * @return callable - */ - public static function mapRequest(callable $fn) - { - return function (callable $handler) use($fn) { - return function ($request, array $options) use($handler, $fn) { - return $handler($fn($request), $options); - }; - }; - } - /** - * Middleware that applies a map function to the resolved promise's - * response. - * - * @param callable $fn Function that accepts a ResponseInterface and - * returns a ResponseInterface. - * @return callable - */ - public static function mapResponse(callable $fn) - { - return function (callable $handler) use($fn) { - return function ($request, array $options) use($handler, $fn) { - return $handler($request, $options)->then($fn); - }; - }; - } -} +withCookieHeader($request); + return $handler($request, $options)->then(function ($response) use($cookieJar, $request) { + $cookieJar->extractCookies($request, $response); + return $response; + }); + }; + }; + } + /** + * Middleware that throws exceptions for 4xx or 5xx responses when the + * "http_error" request option is set to true. + * + * @return callable Returns a function that accepts the next handler. + */ + public static function httpErrors() + { + return function (callable $handler) { + return function ($request, array $options) use($handler) { + if (empty($options['http_errors'])) { + return $handler($request, $options); + } + return $handler($request, $options)->then(function (\_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) use($request) { + $code = $response->getStatusCode(); + if ($code < 400) { + return $response; + } + throw \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException::create($request, $response); + }); + }; + }; + } + /** + * Middleware that pushes history data to an ArrayAccess container. + * + * @param array|\ArrayAccess $container Container to hold the history (by reference). + * + * @return callable Returns a function that accepts the next handler. + * @throws \InvalidArgumentException if container is not an array or ArrayAccess. + */ + public static function history(&$container) + { + if (!\is_array($container) && !$container instanceof \ArrayAccess) { + throw new \InvalidArgumentException('history container must be an array or object implementing ArrayAccess'); + } + return function (callable $handler) use(&$container) { + return function ($request, array $options) use($handler, &$container) { + return $handler($request, $options)->then(function ($value) use($request, &$container, $options) { + $container[] = ['request' => $request, 'response' => $value, 'error' => null, 'options' => $options]; + return $value; + }, function ($reason) use($request, &$container, $options) { + $container[] = ['request' => $request, 'response' => null, 'error' => $reason, 'options' => $options]; + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($reason); + }); + }; + }; + } + /** + * Middleware that invokes a callback before and after sending a request. + * + * The provided listener cannot modify or alter the response. It simply + * "taps" into the chain to be notified before returning the promise. The + * before listener accepts a request and options array, and the after + * listener accepts a request, options array, and response promise. + * + * @param callable $before Function to invoke before forwarding the request. + * @param callable $after Function invoked after forwarding. + * + * @return callable Returns a function that accepts the next handler. + */ + public static function tap(callable $before = null, callable $after = null) + { + return function (callable $handler) use($before, $after) { + return function ($request, array $options) use($handler, $before, $after) { + if ($before) { + $before($request, $options); + } + $response = $handler($request, $options); + if ($after) { + $after($request, $options, $response); + } + return $response; + }; + }; + } + /** + * Middleware that handles request redirects. + * + * @return callable Returns a function that accepts the next handler. + */ + public static function redirect() + { + return function (callable $handler) { + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\RedirectMiddleware($handler); + }; + } + /** + * Middleware that retries requests based on the boolean result of + * invoking the provided "decider" function. + * + * If no delay function is provided, a simple implementation of exponential + * backoff will be utilized. + * + * @param callable $decider Function that accepts the number of retries, + * a request, [response], and [exception] and + * returns true if the request is to be retried. + * @param callable $delay Function that accepts the number of retries and + * returns the number of milliseconds to delay. + * + * @return callable Returns a function that accepts the next handler. + */ + public static function retry(callable $decider, callable $delay = null) + { + return function (callable $handler) use($decider, $delay) { + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\RetryMiddleware($decider, $handler, $delay); + }; + } + /** + * Middleware that logs requests, responses, and errors using a message + * formatter. + * + * @param LoggerInterface $logger Logs messages. + * @param MessageFormatter $formatter Formatter used to create message strings. + * @param string $logLevel Level at which to log requests. + * + * @return callable Returns a function that accepts the next handler. + */ + public static function log(\_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger, \_PhpScoper5ea00cc67502b\GuzzleHttp\MessageFormatter $formatter, $logLevel = 'info') + { + return function (callable $handler) use($logger, $formatter, $logLevel) { + return function ($request, array $options) use($handler, $logger, $formatter, $logLevel) { + return $handler($request, $options)->then(function ($response) use($logger, $request, $formatter, $logLevel) { + $message = $formatter->format($request, $response); + $logger->log($logLevel, $message); + return $response; + }, function ($reason) use($logger, $request, $formatter) { + $response = $reason instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\RequestException ? $reason->getResponse() : null; + $message = $formatter->format($request, $response, $reason); + $logger->notice($message); + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($reason); + }); + }; + }; + } + /** + * This middleware adds a default content-type if possible, a default + * content-length or transfer-encoding header, and the expect header. + * + * @return callable + */ + public static function prepareBody() + { + return function (callable $handler) { + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\PrepareBodyMiddleware($handler); + }; + } + /** + * Middleware that applies a map function to the request before passing to + * the next handler. + * + * @param callable $fn Function that accepts a RequestInterface and returns + * a RequestInterface. + * @return callable + */ + public static function mapRequest(callable $fn) + { + return function (callable $handler) use($fn) { + return function ($request, array $options) use($handler, $fn) { + return $handler($fn($request), $options); + }; + }; + } + /** + * Middleware that applies a map function to the resolved promise's + * response. + * + * @param callable $fn Function that accepts a ResponseInterface and + * returns a ResponseInterface. + * @return callable + */ + public static function mapResponse(callable $fn) + { + return function (callable $handler) use($fn) { + return function ($request, array $options) use($handler, $fn) { + return $handler($request, $options)->then($fn); + }; + }; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Pool.php b/vendor/guzzlehttp/guzzle/src/Pool.php index c9c199bab..78d618a35 100644 --- a/vendor/guzzlehttp/guzzle/src/Pool.php +++ b/vendor/guzzlehttp/guzzle/src/Pool.php @@ -1,117 +1,117 @@ - $rfn) { - if ($rfn instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface) { - (yield $key => $client->sendAsync($rfn, $opts)); - } elseif (\is_callable($rfn)) { - (yield $key => $rfn($opts)); - } else { - throw new \InvalidArgumentException('Each value yielded by ' . 'the iterator must be a Psr7\\Http\\Message\\RequestInterface ' . 'or a callable that returns a promise that fulfills ' . 'with a Psr7\\Message\\Http\\ResponseInterface object.'); - } - } - }; - $this->each = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\EachPromise($requests(), $config); - } - /** - * Get promise - * - * @return PromiseInterface - */ - public function promise() - { - return $this->each->promise(); - } - /** - * Sends multiple requests concurrently and returns an array of responses - * and exceptions that uses the same ordering as the provided requests. - * - * IMPORTANT: This method keeps every request and response in memory, and - * as such, is NOT recommended when sending a large number or an - * indeterminate number of requests concurrently. - * - * @param ClientInterface $client Client used to send the requests - * @param array|\Iterator $requests Requests to send concurrently. - * @param array $options Passes through the options available in - * {@see GuzzleHttp\Pool::__construct} - * - * @return array Returns an array containing the response or an exception - * in the same order that the requests were sent. - * @throws \InvalidArgumentException if the event format is incorrect. - */ - public static function batch(\_PhpScoper5ea00cc67502b\GuzzleHttp\ClientInterface $client, $requests, array $options = []) - { - $res = []; - self::cmpCallback($options, 'fulfilled', $res); - self::cmpCallback($options, 'rejected', $res); - $pool = new static($client, $requests, $options); - $pool->promise()->wait(); - \ksort($res); - return $res; - } - /** - * Execute callback(s) - * - * @return void - */ - private static function cmpCallback(array &$options, $name, array &$results) - { - if (!isset($options[$name])) { - $options[$name] = function ($v, $k) use(&$results) { - $results[$k] = $v; - }; - } else { - $currentFn = $options[$name]; - $options[$name] = function ($v, $k) use(&$results, $currentFn) { - $currentFn($v, $k); - $results[$k] = $v; - }; - } - } -} + $rfn) { + if ($rfn instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface) { + (yield $key => $client->sendAsync($rfn, $opts)); + } elseif (\is_callable($rfn)) { + (yield $key => $rfn($opts)); + } else { + throw new \InvalidArgumentException('Each value yielded by ' . 'the iterator must be a Psr7\\Http\\Message\\RequestInterface ' . 'or a callable that returns a promise that fulfills ' . 'with a Psr7\\Message\\Http\\ResponseInterface object.'); + } + } + }; + $this->each = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\EachPromise($requests(), $config); + } + /** + * Get promise + * + * @return PromiseInterface + */ + public function promise() + { + return $this->each->promise(); + } + /** + * Sends multiple requests concurrently and returns an array of responses + * and exceptions that uses the same ordering as the provided requests. + * + * IMPORTANT: This method keeps every request and response in memory, and + * as such, is NOT recommended when sending a large number or an + * indeterminate number of requests concurrently. + * + * @param ClientInterface $client Client used to send the requests + * @param array|\Iterator $requests Requests to send concurrently. + * @param array $options Passes through the options available in + * {@see GuzzleHttp\Pool::__construct} + * + * @return array Returns an array containing the response or an exception + * in the same order that the requests were sent. + * @throws \InvalidArgumentException if the event format is incorrect. + */ + public static function batch(\_PhpScoper5ea00cc67502b\GuzzleHttp\ClientInterface $client, $requests, array $options = []) + { + $res = []; + self::cmpCallback($options, 'fulfilled', $res); + self::cmpCallback($options, 'rejected', $res); + $pool = new static($client, $requests, $options); + $pool->promise()->wait(); + \ksort($res); + return $res; + } + /** + * Execute callback(s) + * + * @return void + */ + private static function cmpCallback(array &$options, $name, array &$results) + { + if (!isset($options[$name])) { + $options[$name] = function ($v, $k) use(&$results) { + $results[$k] = $v; + }; + } else { + $currentFn = $options[$name]; + $options[$name] = function ($v, $k) use(&$results, $currentFn) { + $currentFn($v, $k); + $results[$k] = $v; + }; + } + } +} diff --git a/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php b/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php index 77b724f18..ad0068696 100644 --- a/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php +++ b/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php @@ -1,91 +1,91 @@ -nextHandler = $nextHandler; - } - /** - * @param RequestInterface $request - * @param array $options - * - * @return PromiseInterface - */ - public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - $fn = $this->nextHandler; - // Don't do anything if the request has no body. - if ($request->getBody()->getSize() === 0) { - return $fn($request, $options); - } - $modify = []; - // Add a default content-type if possible. - if (!$request->hasHeader('Content-Type')) { - if ($uri = $request->getBody()->getMetadata('uri')) { - if ($type = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\mimetype_from_filename($uri)) { - $modify['set_headers']['Content-Type'] = $type; - } - } - } - // Add a default content-length or transfer-encoding header. - if (!$request->hasHeader('Content-Length') && !$request->hasHeader('Transfer-Encoding')) { - $size = $request->getBody()->getSize(); - if ($size !== null) { - $modify['set_headers']['Content-Length'] = $size; - } else { - $modify['set_headers']['Transfer-Encoding'] = 'chunked'; - } - } - // Add the expect header if needed. - $this->addExpectHeader($request, $options, $modify); - return $fn(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\modify_request($request, $modify), $options); - } - /** - * Add expect header - * - * @return void - */ - private function addExpectHeader(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, array &$modify) - { - // Determine if the Expect header should be used - if ($request->hasHeader('Expect')) { - return; - } - $expect = isset($options['expect']) ? $options['expect'] : null; - // Return if disabled or if you're not using HTTP/1.1 or HTTP/2.0 - if ($expect === \false || $request->getProtocolVersion() < 1.1) { - return; - } - // The expect header is unconditionally enabled - if ($expect === \true) { - $modify['set_headers']['Expect'] = '100-Continue'; - return; - } - // By default, send the expect header when the payload is > 1mb - if ($expect === null) { - $expect = 1048576; - } - // Always add if the body cannot be rewound, the size cannot be - // determined, or the size is greater than the cutoff threshold - $body = $request->getBody(); - $size = $body->getSize(); - if ($size === null || $size >= (int) $expect || !$body->isSeekable()) { - $modify['set_headers']['Expect'] = '100-Continue'; - } - } -} +nextHandler = $nextHandler; + } + /** + * @param RequestInterface $request + * @param array $options + * + * @return PromiseInterface + */ + public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + $fn = $this->nextHandler; + // Don't do anything if the request has no body. + if ($request->getBody()->getSize() === 0) { + return $fn($request, $options); + } + $modify = []; + // Add a default content-type if possible. + if (!$request->hasHeader('Content-Type')) { + if ($uri = $request->getBody()->getMetadata('uri')) { + if ($type = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\mimetype_from_filename($uri)) { + $modify['set_headers']['Content-Type'] = $type; + } + } + } + // Add a default content-length or transfer-encoding header. + if (!$request->hasHeader('Content-Length') && !$request->hasHeader('Transfer-Encoding')) { + $size = $request->getBody()->getSize(); + if ($size !== null) { + $modify['set_headers']['Content-Length'] = $size; + } else { + $modify['set_headers']['Transfer-Encoding'] = 'chunked'; + } + } + // Add the expect header if needed. + $this->addExpectHeader($request, $options, $modify); + return $fn(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\modify_request($request, $modify), $options); + } + /** + * Add expect header + * + * @return void + */ + private function addExpectHeader(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, array &$modify) + { + // Determine if the Expect header should be used + if ($request->hasHeader('Expect')) { + return; + } + $expect = isset($options['expect']) ? $options['expect'] : null; + // Return if disabled or if you're not using HTTP/1.1 or HTTP/2.0 + if ($expect === \false || $request->getProtocolVersion() < 1.1) { + return; + } + // The expect header is unconditionally enabled + if ($expect === \true) { + $modify['set_headers']['Expect'] = '100-Continue'; + return; + } + // By default, send the expect header when the payload is > 1mb + if ($expect === null) { + $expect = 1048576; + } + // Always add if the body cannot be rewound, the size cannot be + // determined, or the size is greater than the cutoff threshold + $body = $request->getBody(); + $size = $body->getSize(); + if ($size === null || $size >= (int) $expect || !$body->isSeekable()) { + $modify['set_headers']['Expect'] = '100-Continue'; + } + } +} diff --git a/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php b/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php index 3810f2194..4cf4fa403 100644 --- a/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php +++ b/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php @@ -1,177 +1,177 @@ - 5, 'protocols' => ['http', 'https'], 'strict' => \false, 'referer' => \false, 'track_redirects' => \false]; - /** @var callable */ - private $nextHandler; - /** - * @param callable $nextHandler Next handler to invoke. - */ - public function __construct(callable $nextHandler) - { - $this->nextHandler = $nextHandler; - } - /** - * @param RequestInterface $request - * @param array $options - * - * @return PromiseInterface - */ - public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - $fn = $this->nextHandler; - if (empty($options['allow_redirects'])) { - return $fn($request, $options); - } - if ($options['allow_redirects'] === \true) { - $options['allow_redirects'] = self::$defaultSettings; - } elseif (!\is_array($options['allow_redirects'])) { - throw new \InvalidArgumentException('allow_redirects must be true, false, or array'); - } else { - // Merge the default settings with the provided settings - $options['allow_redirects'] += self::$defaultSettings; - } - if (empty($options['allow_redirects']['max'])) { - return $fn($request, $options); - } - return $fn($request, $options)->then(function (\_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) use($request, $options) { - return $this->checkRedirect($request, $options, $response); - }); - } - /** - * @param RequestInterface $request - * @param array $options - * @param ResponseInterface $response - * - * @return ResponseInterface|PromiseInterface - */ - public function checkRedirect(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) - { - if (\substr($response->getStatusCode(), 0, 1) != '3' || !$response->hasHeader('Location')) { - return $response; - } - $this->guardMax($request, $options); - $nextRequest = $this->modifyRequest($request, $options, $response); - if (isset($options['allow_redirects']['on_redirect'])) { - \call_user_func($options['allow_redirects']['on_redirect'], $request, $response, $nextRequest->getUri()); - } - /** @var PromiseInterface|ResponseInterface $promise */ - $promise = $this($nextRequest, $options); - // Add headers to be able to track history of redirects. - if (!empty($options['allow_redirects']['track_redirects'])) { - return $this->withTracking($promise, (string) $nextRequest->getUri(), $response->getStatusCode()); - } - return $promise; - } - /** - * Enable tracking on promise. - * - * @return PromiseInterface - */ - private function withTracking(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $promise, $uri, $statusCode) - { - return $promise->then(function (\_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) use($uri, $statusCode) { - // Note that we are pushing to the front of the list as this - // would be an earlier response than what is currently present - // in the history header. - $historyHeader = $response->getHeader(self::HISTORY_HEADER); - $statusHeader = $response->getHeader(self::STATUS_HISTORY_HEADER); - \array_unshift($historyHeader, $uri); - \array_unshift($statusHeader, $statusCode); - return $response->withHeader(self::HISTORY_HEADER, $historyHeader)->withHeader(self::STATUS_HISTORY_HEADER, $statusHeader); - }); - } - /** - * Check for too many redirects - * - * @return void - * - * @throws TooManyRedirectsException Too many redirects. - */ - private function guardMax(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array &$options) - { - $current = isset($options['__redirect_count']) ? $options['__redirect_count'] : 0; - $options['__redirect_count'] = $current + 1; - $max = $options['allow_redirects']['max']; - if ($options['__redirect_count'] > $max) { - throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\TooManyRedirectsException("Will not follow more than {$max} redirects", $request); - } - } - /** - * @param RequestInterface $request - * @param array $options - * @param ResponseInterface $response - * - * @return RequestInterface - */ - public function modifyRequest(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) - { - // Request modifications to apply. - $modify = []; - $protocols = $options['allow_redirects']['protocols']; - // Use a GET request if this is an entity enclosing request and we are - // not forcing RFC compliance, but rather emulating what all browsers - // would do. - $statusCode = $response->getStatusCode(); - if ($statusCode == 303 || $statusCode <= 302 && !$options['allow_redirects']['strict']) { - $modify['method'] = 'GET'; - $modify['body'] = ''; - } - $uri = $this->redirectUri($request, $response, $protocols); - if (isset($options['idn_conversion']) && $options['idn_conversion'] !== \false) { - $idnOptions = $options['idn_conversion'] === \true ? \IDNA_DEFAULT : $options['idn_conversion']; - $uri = \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::idnUriConvert($uri, $idnOptions); - } - $modify['uri'] = $uri; - \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\rewind_body($request); - // Add the Referer header if it is told to do so and only - // add the header if we are not redirecting from https to http. - if ($options['allow_redirects']['referer'] && $modify['uri']->getScheme() === $request->getUri()->getScheme()) { - $uri = $request->getUri()->withUserInfo(''); - $modify['set_headers']['Referer'] = (string) $uri; - } else { - $modify['remove_headers'][] = 'Referer'; - } - // Remove Authorization header if host is different. - if ($request->getUri()->getHost() !== $modify['uri']->getHost()) { - $modify['remove_headers'][] = 'Authorization'; - } - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\modify_request($request, $modify); - } - /** - * Set the appropriate URL on the request based on the location header - * - * @param RequestInterface $request - * @param ResponseInterface $response - * @param array $protocols - * - * @return UriInterface - */ - private function redirectUri(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response, array $protocols) - { - $location = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::resolve($request->getUri(), new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri($response->getHeaderLine('Location'))); - // Ensure that the redirect URI is allowed based on the protocols. - if (!\in_array($location->getScheme(), $protocols)) { - throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\BadResponseException(\sprintf('Redirect URI, %s, does not use one of the allowed redirect protocols: %s', $location, \implode(', ', $protocols)), $request, $response); - } - return $location; - } -} + 5, 'protocols' => ['http', 'https'], 'strict' => \false, 'referer' => \false, 'track_redirects' => \false]; + /** @var callable */ + private $nextHandler; + /** + * @param callable $nextHandler Next handler to invoke. + */ + public function __construct(callable $nextHandler) + { + $this->nextHandler = $nextHandler; + } + /** + * @param RequestInterface $request + * @param array $options + * + * @return PromiseInterface + */ + public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + $fn = $this->nextHandler; + if (empty($options['allow_redirects'])) { + return $fn($request, $options); + } + if ($options['allow_redirects'] === \true) { + $options['allow_redirects'] = self::$defaultSettings; + } elseif (!\is_array($options['allow_redirects'])) { + throw new \InvalidArgumentException('allow_redirects must be true, false, or array'); + } else { + // Merge the default settings with the provided settings + $options['allow_redirects'] += self::$defaultSettings; + } + if (empty($options['allow_redirects']['max'])) { + return $fn($request, $options); + } + return $fn($request, $options)->then(function (\_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) use($request, $options) { + return $this->checkRedirect($request, $options, $response); + }); + } + /** + * @param RequestInterface $request + * @param array $options + * @param ResponseInterface $response + * + * @return ResponseInterface|PromiseInterface + */ + public function checkRedirect(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) + { + if (\substr($response->getStatusCode(), 0, 1) != '3' || !$response->hasHeader('Location')) { + return $response; + } + $this->guardMax($request, $options); + $nextRequest = $this->modifyRequest($request, $options, $response); + if (isset($options['allow_redirects']['on_redirect'])) { + \call_user_func($options['allow_redirects']['on_redirect'], $request, $response, $nextRequest->getUri()); + } + /** @var PromiseInterface|ResponseInterface $promise */ + $promise = $this($nextRequest, $options); + // Add headers to be able to track history of redirects. + if (!empty($options['allow_redirects']['track_redirects'])) { + return $this->withTracking($promise, (string) $nextRequest->getUri(), $response->getStatusCode()); + } + return $promise; + } + /** + * Enable tracking on promise. + * + * @return PromiseInterface + */ + private function withTracking(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $promise, $uri, $statusCode) + { + return $promise->then(function (\_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) use($uri, $statusCode) { + // Note that we are pushing to the front of the list as this + // would be an earlier response than what is currently present + // in the history header. + $historyHeader = $response->getHeader(self::HISTORY_HEADER); + $statusHeader = $response->getHeader(self::STATUS_HISTORY_HEADER); + \array_unshift($historyHeader, $uri); + \array_unshift($statusHeader, $statusCode); + return $response->withHeader(self::HISTORY_HEADER, $historyHeader)->withHeader(self::STATUS_HISTORY_HEADER, $statusHeader); + }); + } + /** + * Check for too many redirects + * + * @return void + * + * @throws TooManyRedirectsException Too many redirects. + */ + private function guardMax(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array &$options) + { + $current = isset($options['__redirect_count']) ? $options['__redirect_count'] : 0; + $options['__redirect_count'] = $current + 1; + $max = $options['allow_redirects']['max']; + if ($options['__redirect_count'] > $max) { + throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\TooManyRedirectsException("Will not follow more than {$max} redirects", $request); + } + } + /** + * @param RequestInterface $request + * @param array $options + * @param ResponseInterface $response + * + * @return RequestInterface + */ + public function modifyRequest(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) + { + // Request modifications to apply. + $modify = []; + $protocols = $options['allow_redirects']['protocols']; + // Use a GET request if this is an entity enclosing request and we are + // not forcing RFC compliance, but rather emulating what all browsers + // would do. + $statusCode = $response->getStatusCode(); + if ($statusCode == 303 || $statusCode <= 302 && !$options['allow_redirects']['strict']) { + $modify['method'] = 'GET'; + $modify['body'] = ''; + } + $uri = $this->redirectUri($request, $response, $protocols); + if (isset($options['idn_conversion']) && $options['idn_conversion'] !== \false) { + $idnOptions = $options['idn_conversion'] === \true ? \IDNA_DEFAULT : $options['idn_conversion']; + $uri = \_PhpScoper5ea00cc67502b\GuzzleHttp\Utils::idnUriConvert($uri, $idnOptions); + } + $modify['uri'] = $uri; + \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\rewind_body($request); + // Add the Referer header if it is told to do so and only + // add the header if we are not redirecting from https to http. + if ($options['allow_redirects']['referer'] && $modify['uri']->getScheme() === $request->getUri()->getScheme()) { + $uri = $request->getUri()->withUserInfo(''); + $modify['set_headers']['Referer'] = (string) $uri; + } else { + $modify['remove_headers'][] = 'Referer'; + } + // Remove Authorization header if host is different. + if ($request->getUri()->getHost() !== $modify['uri']->getHost()) { + $modify['remove_headers'][] = 'Authorization'; + } + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\modify_request($request, $modify); + } + /** + * Set the appropriate URL on the request based on the location header + * + * @param RequestInterface $request + * @param ResponseInterface $response + * @param array $protocols + * + * @return UriInterface + */ + private function redirectUri(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response, array $protocols) + { + $location = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::resolve($request->getUri(), new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri($response->getHeaderLine('Location'))); + // Ensure that the redirect URI is allowed based on the protocols. + if (!\in_array($location->getScheme(), $protocols)) { + throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\BadResponseException(\sprintf('Redirect URI, %s, does not use one of the allowed redirect protocols: %s', $location, \implode(', ', $protocols)), $request, $response); + } + return $location; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/RequestOptions.php b/vendor/guzzlehttp/guzzle/src/RequestOptions.php index 27aca1d37..56c05c052 100644 --- a/vendor/guzzlehttp/guzzle/src/RequestOptions.php +++ b/vendor/guzzlehttp/guzzle/src/RequestOptions.php @@ -1,235 +1,235 @@ -decider = $decider; - $this->nextHandler = $nextHandler; - $this->delay = $delay ?: __CLASS__ . '::exponentialDelay'; - } - /** - * Default exponential backoff delay function. - * - * @param int $retries - * - * @return int milliseconds. - */ - public static function exponentialDelay($retries) - { - return (int) \pow(2, $retries - 1) * 1000; - } - /** - * @param RequestInterface $request - * @param array $options - * - * @return PromiseInterface - */ - public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) - { - if (!isset($options['retries'])) { - $options['retries'] = 0; - } - $fn = $this->nextHandler; - return $fn($request, $options)->then($this->onFulfilled($request, $options), $this->onRejected($request, $options)); - } - /** - * Execute fulfilled closure - * - * @return mixed - */ - private function onFulfilled(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $req, array $options) - { - return function ($value) use($req, $options) { - if (!\call_user_func($this->decider, $options['retries'], $req, $value, null)) { - return $value; - } - return $this->doRetry($req, $options, $value); - }; - } - /** - * Execute rejected closure - * - * @return callable - */ - private function onRejected(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $req, array $options) - { - return function ($reason) use($req, $options) { - if (!\call_user_func($this->decider, $options['retries'], $req, null, $reason)) { - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($reason); - } - return $this->doRetry($req, $options); - }; - } - /** - * @return self - */ - private function doRetry(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response = null) - { - $options['delay'] = \call_user_func($this->delay, ++$options['retries'], $response); - return $this($request, $options); - } -} +decider = $decider; + $this->nextHandler = $nextHandler; + $this->delay = $delay ?: __CLASS__ . '::exponentialDelay'; + } + /** + * Default exponential backoff delay function. + * + * @param int $retries + * + * @return int milliseconds. + */ + public static function exponentialDelay($retries) + { + return (int) \pow(2, $retries - 1) * 1000; + } + /** + * @param RequestInterface $request + * @param array $options + * + * @return PromiseInterface + */ + public function __invoke(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options) + { + if (!isset($options['retries'])) { + $options['retries'] = 0; + } + $fn = $this->nextHandler; + return $fn($request, $options)->then($this->onFulfilled($request, $options), $this->onRejected($request, $options)); + } + /** + * Execute fulfilled closure + * + * @return mixed + */ + private function onFulfilled(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $req, array $options) + { + return function ($value) use($req, $options) { + if (!\call_user_func($this->decider, $options['retries'], $req, $value, null)) { + return $value; + } + return $this->doRetry($req, $options, $value); + }; + } + /** + * Execute rejected closure + * + * @return callable + */ + private function onRejected(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $req, array $options) + { + return function ($reason) use($req, $options) { + if (!\call_user_func($this->decider, $options['retries'], $req, null, $reason)) { + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\rejection_for($reason); + } + return $this->doRetry($req, $options); + }; + } + /** + * @return self + */ + private function doRetry(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $options, \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response = null) + { + $options['delay'] = \call_user_func($this->delay, ++$options['retries'], $response); + return $this($request, $options); + } +} diff --git a/vendor/guzzlehttp/guzzle/src/TransferStats.php b/vendor/guzzlehttp/guzzle/src/TransferStats.php index 0ddfae30c..b80c84c74 100644 --- a/vendor/guzzlehttp/guzzle/src/TransferStats.php +++ b/vendor/guzzlehttp/guzzle/src/TransferStats.php @@ -1,110 +1,110 @@ -request = $request; - $this->response = $response; - $this->transferTime = $transferTime; - $this->handlerErrorData = $handlerErrorData; - $this->handlerStats = $handlerStats; - } - /** - * @return RequestInterface - */ - public function getRequest() - { - return $this->request; - } - /** - * Returns the response that was received (if any). - * - * @return ResponseInterface|null - */ - public function getResponse() - { - return $this->response; - } - /** - * Returns true if a response was received. - * - * @return bool - */ - public function hasResponse() - { - return $this->response !== null; - } - /** - * Gets handler specific error data. - * - * This might be an exception, a integer representing an error code, or - * anything else. Relying on this value assumes that you know what handler - * you are using. - * - * @return mixed - */ - public function getHandlerErrorData() - { - return $this->handlerErrorData; - } - /** - * Get the effective URI the request was sent to. - * - * @return UriInterface - */ - public function getEffectiveUri() - { - return $this->request->getUri(); - } - /** - * Get the estimated time the request was being transferred by the handler. - * - * @return float|null Time in seconds. - */ - public function getTransferTime() - { - return $this->transferTime; - } - /** - * Gets an array of all of the handler specific transfer data. - * - * @return array - */ - public function getHandlerStats() - { - return $this->handlerStats; - } - /** - * Get a specific handler statistic from the handler by name. - * - * @param string $stat Handler specific transfer stat to retrieve. - * - * @return mixed|null - */ - public function getHandlerStat($stat) - { - return isset($this->handlerStats[$stat]) ? $this->handlerStats[$stat] : null; - } -} +request = $request; + $this->response = $response; + $this->transferTime = $transferTime; + $this->handlerErrorData = $handlerErrorData; + $this->handlerStats = $handlerStats; + } + /** + * @return RequestInterface + */ + public function getRequest() + { + return $this->request; + } + /** + * Returns the response that was received (if any). + * + * @return ResponseInterface|null + */ + public function getResponse() + { + return $this->response; + } + /** + * Returns true if a response was received. + * + * @return bool + */ + public function hasResponse() + { + return $this->response !== null; + } + /** + * Gets handler specific error data. + * + * This might be an exception, a integer representing an error code, or + * anything else. Relying on this value assumes that you know what handler + * you are using. + * + * @return mixed + */ + public function getHandlerErrorData() + { + return $this->handlerErrorData; + } + /** + * Get the effective URI the request was sent to. + * + * @return UriInterface + */ + public function getEffectiveUri() + { + return $this->request->getUri(); + } + /** + * Get the estimated time the request was being transferred by the handler. + * + * @return float|null Time in seconds. + */ + public function getTransferTime() + { + return $this->transferTime; + } + /** + * Gets an array of all of the handler specific transfer data. + * + * @return array + */ + public function getHandlerStats() + { + return $this->handlerStats; + } + /** + * Get a specific handler statistic from the handler by name. + * + * @param string $stat Handler specific transfer stat to retrieve. + * + * @return mixed|null + */ + public function getHandlerStat($stat) + { + return isset($this->handlerStats[$stat]) ? $this->handlerStats[$stat] : null; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/UriTemplate.php b/vendor/guzzlehttp/guzzle/src/UriTemplate.php index 26db9396f..ea7247930 100644 --- a/vendor/guzzlehttp/guzzle/src/UriTemplate.php +++ b/vendor/guzzlehttp/guzzle/src/UriTemplate.php @@ -1,191 +1,191 @@ - ['prefix' => '', 'joiner' => ',', 'query' => \false], '+' => ['prefix' => '', 'joiner' => ',', 'query' => \false], '#' => ['prefix' => '#', 'joiner' => ',', 'query' => \false], '.' => ['prefix' => '.', 'joiner' => '.', 'query' => \false], '/' => ['prefix' => '/', 'joiner' => '/', 'query' => \false], ';' => ['prefix' => ';', 'joiner' => ';', 'query' => \true], '?' => ['prefix' => '?', 'joiner' => '&', 'query' => \true], '&' => ['prefix' => '&', 'joiner' => '&', 'query' => \true]]; - /** @var array Delimiters */ - private static $delims = [':', '/', '?', '#', '[', ']', '@', '!', '$', '&', '\'', '(', ')', '*', '+', ',', ';', '=']; - /** @var array Percent encoded delimiters */ - private static $delimsPct = ['%3A', '%2F', '%3F', '%23', '%5B', '%5D', '%40', '%21', '%24', '%26', '%27', '%28', '%29', '%2A', '%2B', '%2C', '%3B', '%3D']; - public function expand($template, array $variables) - { - if (\false === \strpos($template, '{')) { - return $template; - } - $this->template = $template; - $this->variables = $variables; - return \preg_replace_callback('/\\{([^\\}]+)\\}/', [$this, 'expandMatch'], $this->template); - } - /** - * Parse an expression into parts - * - * @param string $expression Expression to parse - * - * @return array Returns an associative array of parts - */ - private function parseExpression($expression) - { - $result = []; - if (isset(self::$operatorHash[$expression[0]])) { - $result['operator'] = $expression[0]; - $expression = \substr($expression, 1); - } else { - $result['operator'] = ''; - } - foreach (\explode(',', $expression) as $value) { - $value = \trim($value); - $varspec = []; - if ($colonPos = \strpos($value, ':')) { - $varspec['value'] = \substr($value, 0, $colonPos); - $varspec['modifier'] = ':'; - $varspec['position'] = (int) \substr($value, $colonPos + 1); - } elseif (\substr($value, -1) === '*') { - $varspec['modifier'] = '*'; - $varspec['value'] = \substr($value, 0, -1); - } else { - $varspec['value'] = (string) $value; - $varspec['modifier'] = ''; - } - $result['values'][] = $varspec; - } - return $result; - } - /** - * Process an expansion - * - * @param array $matches Matches met in the preg_replace_callback - * - * @return string Returns the replacement string - */ - private function expandMatch(array $matches) - { - static $rfc1738to3986 = ['+' => '%20', '%7e' => '~']; - $replacements = []; - $parsed = self::parseExpression($matches[1]); - $prefix = self::$operatorHash[$parsed['operator']]['prefix']; - $joiner = self::$operatorHash[$parsed['operator']]['joiner']; - $useQuery = self::$operatorHash[$parsed['operator']]['query']; - foreach ($parsed['values'] as $value) { - if (!isset($this->variables[$value['value']])) { - continue; - } - $variable = $this->variables[$value['value']]; - $actuallyUseQuery = $useQuery; - $expanded = ''; - if (\is_array($variable)) { - $isAssoc = $this->isAssoc($variable); - $kvp = []; - foreach ($variable as $key => $var) { - if ($isAssoc) { - $key = \rawurlencode($key); - $isNestedArray = \is_array($var); - } else { - $isNestedArray = \false; - } - if (!$isNestedArray) { - $var = \rawurlencode($var); - if ($parsed['operator'] === '+' || $parsed['operator'] === '#') { - $var = $this->decodeReserved($var); - } - } - if ($value['modifier'] === '*') { - if ($isAssoc) { - if ($isNestedArray) { - // Nested arrays must allow for deeply nested - // structures. - $var = \strtr(\http_build_query([$key => $var]), $rfc1738to3986); - } else { - $var = $key . '=' . $var; - } - } elseif ($key > 0 && $actuallyUseQuery) { - $var = $value['value'] . '=' . $var; - } - } - $kvp[$key] = $var; - } - if (empty($variable)) { - $actuallyUseQuery = \false; - } elseif ($value['modifier'] === '*') { - $expanded = \implode($joiner, $kvp); - if ($isAssoc) { - // Don't prepend the value name when using the explode - // modifier with an associative array. - $actuallyUseQuery = \false; - } - } else { - if ($isAssoc) { - // When an associative array is encountered and the - // explode modifier is not set, then the result must be - // a comma separated list of keys followed by their - // respective values. - foreach ($kvp as $k => &$v) { - $v = $k . ',' . $v; - } - } - $expanded = \implode(',', $kvp); - } - } else { - if ($value['modifier'] === ':') { - $variable = \substr($variable, 0, $value['position']); - } - $expanded = \rawurlencode($variable); - if ($parsed['operator'] === '+' || $parsed['operator'] === '#') { - $expanded = $this->decodeReserved($expanded); - } - } - if ($actuallyUseQuery) { - if (!$expanded && $joiner !== '&') { - $expanded = $value['value']; - } else { - $expanded = $value['value'] . '=' . $expanded; - } - } - $replacements[] = $expanded; - } - $ret = \implode($joiner, $replacements); - if ($ret && $prefix) { - return $prefix . $ret; - } - return $ret; - } - /** - * Determines if an array is associative. - * - * This makes the assumption that input arrays are sequences or hashes. - * This assumption is a tradeoff for accuracy in favor of speed, but it - * should work in almost every case where input is supplied for a URI - * template. - * - * @param array $array Array to check - * - * @return bool - */ - private function isAssoc(array $array) - { - return $array && \array_keys($array)[0] !== 0; - } - /** - * Removes percent encoding on reserved characters (used with + and # - * modifiers). - * - * @param string $string String to fix - * - * @return string - */ - private function decodeReserved($string) - { - return \str_replace(self::$delimsPct, self::$delims, $string); - } -} + ['prefix' => '', 'joiner' => ',', 'query' => \false], '+' => ['prefix' => '', 'joiner' => ',', 'query' => \false], '#' => ['prefix' => '#', 'joiner' => ',', 'query' => \false], '.' => ['prefix' => '.', 'joiner' => '.', 'query' => \false], '/' => ['prefix' => '/', 'joiner' => '/', 'query' => \false], ';' => ['prefix' => ';', 'joiner' => ';', 'query' => \true], '?' => ['prefix' => '?', 'joiner' => '&', 'query' => \true], '&' => ['prefix' => '&', 'joiner' => '&', 'query' => \true]]; + /** @var array Delimiters */ + private static $delims = [':', '/', '?', '#', '[', ']', '@', '!', '$', '&', '\'', '(', ')', '*', '+', ',', ';', '=']; + /** @var array Percent encoded delimiters */ + private static $delimsPct = ['%3A', '%2F', '%3F', '%23', '%5B', '%5D', '%40', '%21', '%24', '%26', '%27', '%28', '%29', '%2A', '%2B', '%2C', '%3B', '%3D']; + public function expand($template, array $variables) + { + if (\false === \strpos($template, '{')) { + return $template; + } + $this->template = $template; + $this->variables = $variables; + return \preg_replace_callback('/\\{([^\\}]+)\\}/', [$this, 'expandMatch'], $this->template); + } + /** + * Parse an expression into parts + * + * @param string $expression Expression to parse + * + * @return array Returns an associative array of parts + */ + private function parseExpression($expression) + { + $result = []; + if (isset(self::$operatorHash[$expression[0]])) { + $result['operator'] = $expression[0]; + $expression = \substr($expression, 1); + } else { + $result['operator'] = ''; + } + foreach (\explode(',', $expression) as $value) { + $value = \trim($value); + $varspec = []; + if ($colonPos = \strpos($value, ':')) { + $varspec['value'] = \substr($value, 0, $colonPos); + $varspec['modifier'] = ':'; + $varspec['position'] = (int) \substr($value, $colonPos + 1); + } elseif (\substr($value, -1) === '*') { + $varspec['modifier'] = '*'; + $varspec['value'] = \substr($value, 0, -1); + } else { + $varspec['value'] = (string) $value; + $varspec['modifier'] = ''; + } + $result['values'][] = $varspec; + } + return $result; + } + /** + * Process an expansion + * + * @param array $matches Matches met in the preg_replace_callback + * + * @return string Returns the replacement string + */ + private function expandMatch(array $matches) + { + static $rfc1738to3986 = ['+' => '%20', '%7e' => '~']; + $replacements = []; + $parsed = self::parseExpression($matches[1]); + $prefix = self::$operatorHash[$parsed['operator']]['prefix']; + $joiner = self::$operatorHash[$parsed['operator']]['joiner']; + $useQuery = self::$operatorHash[$parsed['operator']]['query']; + foreach ($parsed['values'] as $value) { + if (!isset($this->variables[$value['value']])) { + continue; + } + $variable = $this->variables[$value['value']]; + $actuallyUseQuery = $useQuery; + $expanded = ''; + if (\is_array($variable)) { + $isAssoc = $this->isAssoc($variable); + $kvp = []; + foreach ($variable as $key => $var) { + if ($isAssoc) { + $key = \rawurlencode($key); + $isNestedArray = \is_array($var); + } else { + $isNestedArray = \false; + } + if (!$isNestedArray) { + $var = \rawurlencode($var); + if ($parsed['operator'] === '+' || $parsed['operator'] === '#') { + $var = $this->decodeReserved($var); + } + } + if ($value['modifier'] === '*') { + if ($isAssoc) { + if ($isNestedArray) { + // Nested arrays must allow for deeply nested + // structures. + $var = \strtr(\http_build_query([$key => $var]), $rfc1738to3986); + } else { + $var = $key . '=' . $var; + } + } elseif ($key > 0 && $actuallyUseQuery) { + $var = $value['value'] . '=' . $var; + } + } + $kvp[$key] = $var; + } + if (empty($variable)) { + $actuallyUseQuery = \false; + } elseif ($value['modifier'] === '*') { + $expanded = \implode($joiner, $kvp); + if ($isAssoc) { + // Don't prepend the value name when using the explode + // modifier with an associative array. + $actuallyUseQuery = \false; + } + } else { + if ($isAssoc) { + // When an associative array is encountered and the + // explode modifier is not set, then the result must be + // a comma separated list of keys followed by their + // respective values. + foreach ($kvp as $k => &$v) { + $v = $k . ',' . $v; + } + } + $expanded = \implode(',', $kvp); + } + } else { + if ($value['modifier'] === ':') { + $variable = \substr($variable, 0, $value['position']); + } + $expanded = \rawurlencode($variable); + if ($parsed['operator'] === '+' || $parsed['operator'] === '#') { + $expanded = $this->decodeReserved($expanded); + } + } + if ($actuallyUseQuery) { + if (!$expanded && $joiner !== '&') { + $expanded = $value['value']; + } else { + $expanded = $value['value'] . '=' . $expanded; + } + } + $replacements[] = $expanded; + } + $ret = \implode($joiner, $replacements); + if ($ret && $prefix) { + return $prefix . $ret; + } + return $ret; + } + /** + * Determines if an array is associative. + * + * This makes the assumption that input arrays are sequences or hashes. + * This assumption is a tradeoff for accuracy in favor of speed, but it + * should work in almost every case where input is supplied for a URI + * template. + * + * @param array $array Array to check + * + * @return bool + */ + private function isAssoc(array $array) + { + return $array && \array_keys($array)[0] !== 0; + } + /** + * Removes percent encoding on reserved characters (used with + and # + * modifiers). + * + * @param string $string String to fix + * + * @return string + */ + private function decodeReserved($string) + { + return \str_replace(self::$delimsPct, self::$delims, $string); + } +} diff --git a/vendor/guzzlehttp/guzzle/src/Utils.php b/vendor/guzzlehttp/guzzle/src/Utils.php index fb8625fb6..0ed9331cc 100644 --- a/vendor/guzzlehttp/guzzle/src/Utils.php +++ b/vendor/guzzlehttp/guzzle/src/Utils.php @@ -1,59 +1,59 @@ -getHost()) { - $idnaVariant = \defined('INTL_IDNA_VARIANT_UTS46') ? \INTL_IDNA_VARIANT_UTS46 : 0; - $asciiHost = $idnaVariant === 0 ? \idn_to_ascii($uri->getHost(), $options) : \idn_to_ascii($uri->getHost(), $options, $idnaVariant, $info); - if ($asciiHost === \false) { - $errorBitSet = isset($info['errors']) ? $info['errors'] : 0; - $errorConstants = \array_filter(\array_keys(\get_defined_constants()), function ($name) { - return \substr($name, 0, 11) === 'IDNA_ERROR_'; - }); - $errors = []; - foreach ($errorConstants as $errorConstant) { - if ($errorBitSet & \constant($errorConstant)) { - $errors[] = $errorConstant; - } - } - $errorMessage = 'IDN conversion failed'; - if ($errors) { - $errorMessage .= ' (errors: ' . \implode(', ', $errors) . ')'; - } - throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\InvalidArgumentException($errorMessage); - } else { - if ($uri->getHost() !== $asciiHost) { - // Replace URI only if the ASCII version is different - $uri = $uri->withHost($asciiHost); - } - } - } - return $uri; - } -} +getHost()) { + $idnaVariant = \defined('INTL_IDNA_VARIANT_UTS46') ? \INTL_IDNA_VARIANT_UTS46 : 0; + $asciiHost = $idnaVariant === 0 ? \idn_to_ascii($uri->getHost(), $options) : \idn_to_ascii($uri->getHost(), $options, $idnaVariant, $info); + if ($asciiHost === \false) { + $errorBitSet = isset($info['errors']) ? $info['errors'] : 0; + $errorConstants = \array_filter(\array_keys(\get_defined_constants()), function ($name) { + return \substr($name, 0, 11) === 'IDNA_ERROR_'; + }); + $errors = []; + foreach ($errorConstants as $errorConstant) { + if ($errorBitSet & \constant($errorConstant)) { + $errors[] = $errorConstant; + } + } + $errorMessage = 'IDN conversion failed'; + if ($errors) { + $errorMessage .= ' (errors: ' . \implode(', ', $errors) . ')'; + } + throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\InvalidArgumentException($errorMessage); + } else { + if ($uri->getHost() !== $asciiHost) { + // Replace URI only if the ASCII version is different + $uri = $uri->withHost($asciiHost); + } + } + } + return $uri; + } +} diff --git a/vendor/guzzlehttp/guzzle/src/functions.php b/vendor/guzzlehttp/guzzle/src/functions.php index 11b72247a..078880732 100644 --- a/vendor/guzzlehttp/guzzle/src/functions.php +++ b/vendor/guzzlehttp/guzzle/src/functions.php @@ -1,294 +1,294 @@ -expand($template, $variables); -} -/** - * Debug function used to describe the provided value type and class. - * - * @param mixed $input - * - * @return string Returns a string containing the type of the variable and - * if a class is provided, the class name. - */ -function describe_type($input) -{ - switch (\gettype($input)) { - case 'object': - return 'object(' . \get_class($input) . ')'; - case 'array': - return 'array(' . \count($input) . ')'; - default: - \ob_start(); - \var_dump($input); - // normalize float vs double - return \str_replace('double(', 'float(', \rtrim(\ob_get_clean())); - } -} -/** - * Parses an array of header lines into an associative array of headers. - * - * @param iterable $lines Header lines array of strings in the following - * format: "Name: Value" - * @return array - */ -function headers_from_lines($lines) -{ - $headers = []; - foreach ($lines as $line) { - $parts = \explode(':', $line, 2); - $headers[\trim($parts[0])][] = isset($parts[1]) ? \trim($parts[1]) : null; - } - return $headers; -} -/** - * Returns a debug stream based on the provided variable. - * - * @param mixed $value Optional value - * - * @return resource - */ -function debug_resource($value = null) -{ - if (\is_resource($value)) { - return $value; - } elseif (\defined('STDOUT')) { - return \STDOUT; - } - return \fopen('php://output', 'w'); -} -/** - * Chooses and creates a default handler to use based on the environment. - * - * The returned handler is not wrapped by any default middlewares. - * - * @return callable Returns the best handler for the given system. - * @throws \RuntimeException if no viable Handler is available. - */ -function choose_handler() -{ - $handler = null; - if (\function_exists('curl_multi_exec') && \function_exists('curl_exec')) { - $handler = \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\Proxy::wrapSync(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlMultiHandler(), new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlHandler()); - } elseif (\function_exists('curl_exec')) { - $handler = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlHandler(); - } elseif (\function_exists('curl_multi_exec')) { - $handler = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlMultiHandler(); - } - if (\ini_get('allow_url_fopen')) { - $handler = $handler ? \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\Proxy::wrapStreaming($handler, new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\StreamHandler()) : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\StreamHandler(); - } elseif (!$handler) { - throw new \RuntimeException('GuzzleHttp requires cURL, the ' . 'allow_url_fopen ini setting, or a custom HTTP handler.'); - } - return $handler; -} -/** - * Get the default User-Agent string to use with Guzzle - * - * @return string - */ -function default_user_agent() -{ - static $defaultAgent = ''; - if (!$defaultAgent) { - $defaultAgent = 'GuzzleHttp/' . \_PhpScoper5ea00cc67502b\GuzzleHttp\Client::VERSION; - if (\extension_loaded('curl') && \function_exists('curl_version')) { - $defaultAgent .= ' curl/' . \curl_version()['version']; - } - $defaultAgent .= ' PHP/' . \PHP_VERSION; - } - return $defaultAgent; -} -/** - * Returns the default cacert bundle for the current system. - * - * First, the openssl.cafile and curl.cainfo php.ini settings are checked. - * If those settings are not configured, then the common locations for - * bundles found on Red Hat, CentOS, Fedora, Ubuntu, Debian, FreeBSD, OS X - * and Windows are checked. If any of these file locations are found on - * disk, they will be utilized. - * - * Note: the result of this function is cached for subsequent calls. - * - * @return string - * @throws \RuntimeException if no bundle can be found. - */ -function default_ca_bundle() -{ - static $cached = null; - static $cafiles = [ - // Red Hat, CentOS, Fedora (provided by the ca-certificates package) - '/etc/pki/tls/certs/ca-bundle.crt', - // Ubuntu, Debian (provided by the ca-certificates package) - '/etc/ssl/certs/ca-certificates.crt', - // FreeBSD (provided by the ca_root_nss package) - '/usr/local/share/certs/ca-root-nss.crt', - // SLES 12 (provided by the ca-certificates package) - '/var/lib/ca-certificates/ca-bundle.pem', - // OS X provided by homebrew (using the default path) - '/usr/local/etc/openssl/cert.pem', - // Google app engine - '/etc/ca-certificates.crt', - // Windows? - 'C:\\windows\\system32\\curl-ca-bundle.crt', - 'C:\\windows\\curl-ca-bundle.crt', - ]; - if ($cached) { - return $cached; - } - if ($ca = \ini_get('openssl.cafile')) { - return $cached = $ca; - } - if ($ca = \ini_get('curl.cainfo')) { - return $cached = $ca; - } - foreach ($cafiles as $filename) { - if (\file_exists($filename)) { - return $cached = $filename; - } - } - throw new \RuntimeException(<<expand($template, $variables); +} +/** + * Debug function used to describe the provided value type and class. + * + * @param mixed $input + * + * @return string Returns a string containing the type of the variable and + * if a class is provided, the class name. + */ +function describe_type($input) +{ + switch (\gettype($input)) { + case 'object': + return 'object(' . \get_class($input) . ')'; + case 'array': + return 'array(' . \count($input) . ')'; + default: + \ob_start(); + \var_dump($input); + // normalize float vs double + return \str_replace('double(', 'float(', \rtrim(\ob_get_clean())); + } +} +/** + * Parses an array of header lines into an associative array of headers. + * + * @param iterable $lines Header lines array of strings in the following + * format: "Name: Value" + * @return array + */ +function headers_from_lines($lines) +{ + $headers = []; + foreach ($lines as $line) { + $parts = \explode(':', $line, 2); + $headers[\trim($parts[0])][] = isset($parts[1]) ? \trim($parts[1]) : null; + } + return $headers; +} +/** + * Returns a debug stream based on the provided variable. + * + * @param mixed $value Optional value + * + * @return resource + */ +function debug_resource($value = null) +{ + if (\is_resource($value)) { + return $value; + } elseif (\defined('STDOUT')) { + return \STDOUT; + } + return \fopen('php://output', 'w'); +} +/** + * Chooses and creates a default handler to use based on the environment. + * + * The returned handler is not wrapped by any default middlewares. + * + * @return callable Returns the best handler for the given system. + * @throws \RuntimeException if no viable Handler is available. + */ +function choose_handler() +{ + $handler = null; + if (\function_exists('curl_multi_exec') && \function_exists('curl_exec')) { + $handler = \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\Proxy::wrapSync(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlMultiHandler(), new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlHandler()); + } elseif (\function_exists('curl_exec')) { + $handler = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlHandler(); + } elseif (\function_exists('curl_multi_exec')) { + $handler = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\CurlMultiHandler(); + } + if (\ini_get('allow_url_fopen')) { + $handler = $handler ? \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\Proxy::wrapStreaming($handler, new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\StreamHandler()) : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Handler\StreamHandler(); + } elseif (!$handler) { + throw new \RuntimeException('GuzzleHttp requires cURL, the ' . 'allow_url_fopen ini setting, or a custom HTTP handler.'); + } + return $handler; +} +/** + * Get the default User-Agent string to use with Guzzle + * + * @return string + */ +function default_user_agent() +{ + static $defaultAgent = ''; + if (!$defaultAgent) { + $defaultAgent = 'GuzzleHttp/' . \_PhpScoper5ea00cc67502b\GuzzleHttp\Client::VERSION; + if (\extension_loaded('curl') && \function_exists('curl_version')) { + $defaultAgent .= ' curl/' . \curl_version()['version']; + } + $defaultAgent .= ' PHP/' . \PHP_VERSION; + } + return $defaultAgent; +} +/** + * Returns the default cacert bundle for the current system. + * + * First, the openssl.cafile and curl.cainfo php.ini settings are checked. + * If those settings are not configured, then the common locations for + * bundles found on Red Hat, CentOS, Fedora, Ubuntu, Debian, FreeBSD, OS X + * and Windows are checked. If any of these file locations are found on + * disk, they will be utilized. + * + * Note: the result of this function is cached for subsequent calls. + * + * @return string + * @throws \RuntimeException if no bundle can be found. + */ +function default_ca_bundle() +{ + static $cached = null; + static $cafiles = [ + // Red Hat, CentOS, Fedora (provided by the ca-certificates package) + '/etc/pki/tls/certs/ca-bundle.crt', + // Ubuntu, Debian (provided by the ca-certificates package) + '/etc/ssl/certs/ca-certificates.crt', + // FreeBSD (provided by the ca_root_nss package) + '/usr/local/share/certs/ca-root-nss.crt', + // SLES 12 (provided by the ca-certificates package) + '/var/lib/ca-certificates/ca-bundle.pem', + // OS X provided by homebrew (using the default path) + '/usr/local/etc/openssl/cert.pem', + // Google app engine + '/etc/ca-certificates.crt', + // Windows? + 'C:\\windows\\system32\\curl-ca-bundle.crt', + 'C:\\windows\\curl-ca-bundle.crt', + ]; + if ($cached) { + return $cached; + } + if ($ca = \ini_get('openssl.cafile')) { + return $cached = $ca; + } + if ($ca = \ini_get('curl.cainfo')) { + return $cached = $ca; + } + foreach ($cafiles as $filename) { + if (\file_exists($filename)) { + return $cached = $filename; + } + } + throw new \RuntimeException(<< -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/index.php b/vendor/guzzlehttp/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/guzzlehttp/index.php +++ b/vendor/guzzlehttp/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/promises/CHANGELOG.md b/vendor/guzzlehttp/promises/CHANGELOG.md index 551929f6b..aed13859b 100644 --- a/vendor/guzzlehttp/promises/CHANGELOG.md +++ b/vendor/guzzlehttp/promises/CHANGELOG.md @@ -1,65 +1,65 @@ -# CHANGELOG - - -## 1.3.1 - 2016-12-20 - -### Fixed - -- `wait()` foreign promise compatibility - - -## 1.3.0 - 2016-11-18 - -### Added - -- Adds support for custom task queues. - -### Fixed - -- Fixed coroutine promise memory leak. - - -## 1.2.0 - 2016-05-18 - -### Changed - -- Update to now catch `\Throwable` on PHP 7+ - - -## 1.1.0 - 2016-03-07 - -### Changed - -- Update EachPromise to prevent recurring on a iterator when advancing, as this - could trigger fatal generator errors. -- Update Promise to allow recursive waiting without unwrapping exceptions. - - -## 1.0.3 - 2015-10-15 - -### Changed - -- Update EachPromise to immediately resolve when the underlying promise iterator - is empty. Previously, such a promise would throw an exception when its `wait` - function was called. - - -## 1.0.2 - 2015-05-15 - -### Changed - -- Conditionally require functions.php. - - -## 1.0.1 - 2015-06-24 - -### Changed - -- Updating EachPromise to call next on the underlying promise iterator as late - as possible to ensure that generators that generate new requests based on - callbacks are not iterated until after callbacks are invoked. - - -## 1.0.0 - 2015-05-12 - -- Initial release +# CHANGELOG + + +## 1.3.1 - 2016-12-20 + +### Fixed + +- `wait()` foreign promise compatibility + + +## 1.3.0 - 2016-11-18 + +### Added + +- Adds support for custom task queues. + +### Fixed + +- Fixed coroutine promise memory leak. + + +## 1.2.0 - 2016-05-18 + +### Changed + +- Update to now catch `\Throwable` on PHP 7+ + + +## 1.1.0 - 2016-03-07 + +### Changed + +- Update EachPromise to prevent recurring on a iterator when advancing, as this + could trigger fatal generator errors. +- Update Promise to allow recursive waiting without unwrapping exceptions. + + +## 1.0.3 - 2015-10-15 + +### Changed + +- Update EachPromise to immediately resolve when the underlying promise iterator + is empty. Previously, such a promise would throw an exception when its `wait` + function was called. + + +## 1.0.2 - 2015-05-15 + +### Changed + +- Conditionally require functions.php. + + +## 1.0.1 - 2015-06-24 + +### Changed + +- Updating EachPromise to call next on the underlying promise iterator as late + as possible to ensure that generators that generate new requests based on + callbacks are not iterated until after callbacks are invoked. + + +## 1.0.0 - 2015-05-12 + +- Initial release diff --git a/vendor/guzzlehttp/promises/LICENSE b/vendor/guzzlehttp/promises/LICENSE index 67f91a14c..7089a00dd 100644 --- a/vendor/guzzlehttp/promises/LICENSE +++ b/vendor/guzzlehttp/promises/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2015-2016 Michael Dowling, https://github.com/mtdowling - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2015-2016 Michael Dowling, https://github.com/mtdowling + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/guzzlehttp/promises/Makefile b/vendor/guzzlehttp/promises/Makefile index 8d5b3ef95..9e40e0340 100644 --- a/vendor/guzzlehttp/promises/Makefile +++ b/vendor/guzzlehttp/promises/Makefile @@ -1,13 +1,13 @@ -all: clean test - -test: - vendor/bin/phpunit - -coverage: - vendor/bin/phpunit --coverage-html=artifacts/coverage - -view-coverage: - open artifacts/coverage/index.html - -clean: - rm -rf artifacts/* +all: clean test + +test: + vendor/bin/phpunit + +coverage: + vendor/bin/phpunit --coverage-html=artifacts/coverage + +view-coverage: + open artifacts/coverage/index.html + +clean: + rm -rf artifacts/* diff --git a/vendor/guzzlehttp/promises/README.md b/vendor/guzzlehttp/promises/README.md index 7b607e28b..5481531d6 100644 --- a/vendor/guzzlehttp/promises/README.md +++ b/vendor/guzzlehttp/promises/README.md @@ -1,504 +1,504 @@ -# Guzzle Promises - -[Promises/A+](https://promisesaplus.com/) implementation that handles promise -chaining and resolution iteratively, allowing for "infinite" promise chaining -while keeping the stack size constant. Read [this blog post](https://blog.domenic.me/youre-missing-the-point-of-promises/) -for a general introduction to promises. - -- [Features](#features) -- [Quick start](#quick-start) -- [Synchronous wait](#synchronous-wait) -- [Cancellation](#cancellation) -- [API](#api) - - [Promise](#promise) - - [FulfilledPromise](#fulfilledpromise) - - [RejectedPromise](#rejectedpromise) -- [Promise interop](#promise-interop) -- [Implementation notes](#implementation-notes) - - -# Features - -- [Promises/A+](https://promisesaplus.com/) implementation. -- Promise resolution and chaining is handled iteratively, allowing for - "infinite" promise chaining. -- Promises have a synchronous `wait` method. -- Promises can be cancelled. -- Works with any object that has a `then` function. -- C# style async/await coroutine promises using - `GuzzleHttp\Promise\coroutine()`. - - -# Quick start - -A *promise* represents the eventual result of an asynchronous operation. The -primary way of interacting with a promise is through its `then` method, which -registers callbacks to receive either a promise's eventual value or the reason -why the promise cannot be fulfilled. - - -## Callbacks - -Callbacks are registered with the `then` method by providing an optional -`$onFulfilled` followed by an optional `$onRejected` function. - - -```php -use GuzzleHttp\Promise\Promise; - -$promise = new Promise(); -$promise->then( - // $onFulfilled - function ($value) { - echo 'The promise was fulfilled.'; - }, - // $onRejected - function ($reason) { - echo 'The promise was rejected.'; - } -); -``` - -*Resolving* a promise means that you either fulfill a promise with a *value* or -reject a promise with a *reason*. Resolving a promises triggers callbacks -registered with the promises's `then` method. These callbacks are triggered -only once and in the order in which they were added. - - -## Resolving a promise - -Promises are fulfilled using the `resolve($value)` method. Resolving a promise -with any value other than a `GuzzleHttp\Promise\RejectedPromise` will trigger -all of the onFulfilled callbacks (resolving a promise with a rejected promise -will reject the promise and trigger the `$onRejected` callbacks). - -```php -use GuzzleHttp\Promise\Promise; - -$promise = new Promise(); -$promise - ->then(function ($value) { - // Return a value and don't break the chain - return "Hello, " . $value; - }) - // This then is executed after the first then and receives the value - // returned from the first then. - ->then(function ($value) { - echo $value; - }); - -// Resolving the promise triggers the $onFulfilled callbacks and outputs -// "Hello, reader". -$promise->resolve('reader.'); -``` - - -## Promise forwarding - -Promises can be chained one after the other. Each then in the chain is a new -promise. The return value of a promise is what's forwarded to the next -promise in the chain. Returning a promise in a `then` callback will cause the -subsequent promises in the chain to only be fulfilled when the returned promise -has been fulfilled. The next promise in the chain will be invoked with the -resolved value of the promise. - -```php -use GuzzleHttp\Promise\Promise; - -$promise = new Promise(); -$nextPromise = new Promise(); - -$promise - ->then(function ($value) use ($nextPromise) { - echo $value; - return $nextPromise; - }) - ->then(function ($value) { - echo $value; - }); - -// Triggers the first callback and outputs "A" -$promise->resolve('A'); -// Triggers the second callback and outputs "B" -$nextPromise->resolve('B'); -``` - -## Promise rejection - -When a promise is rejected, the `$onRejected` callbacks are invoked with the -rejection reason. - -```php -use GuzzleHttp\Promise\Promise; - -$promise = new Promise(); -$promise->then(null, function ($reason) { - echo $reason; -}); - -$promise->reject('Error!'); -// Outputs "Error!" -``` - -## Rejection forwarding - -If an exception is thrown in an `$onRejected` callback, subsequent -`$onRejected` callbacks are invoked with the thrown exception as the reason. - -```php -use GuzzleHttp\Promise\Promise; - -$promise = new Promise(); -$promise->then(null, function ($reason) { - throw new \Exception($reason); -})->then(null, function ($reason) { - assert($reason->getMessage() === 'Error!'); -}); - -$promise->reject('Error!'); -``` - -You can also forward a rejection down the promise chain by returning a -`GuzzleHttp\Promise\RejectedPromise` in either an `$onFulfilled` or -`$onRejected` callback. - -```php -use GuzzleHttp\Promise\Promise; -use GuzzleHttp\Promise\RejectedPromise; - -$promise = new Promise(); -$promise->then(null, function ($reason) { - return new RejectedPromise($reason); -})->then(null, function ($reason) { - assert($reason === 'Error!'); -}); - -$promise->reject('Error!'); -``` - -If an exception is not thrown in a `$onRejected` callback and the callback -does not return a rejected promise, downstream `$onFulfilled` callbacks are -invoked using the value returned from the `$onRejected` callback. - -```php -use GuzzleHttp\Promise\Promise; -use GuzzleHttp\Promise\RejectedPromise; - -$promise = new Promise(); -$promise - ->then(null, function ($reason) { - return "It's ok"; - }) - ->then(function ($value) { - assert($value === "It's ok"); - }); - -$promise->reject('Error!'); -``` - -# Synchronous wait - -You can synchronously force promises to complete using a promise's `wait` -method. When creating a promise, you can provide a wait function that is used -to synchronously force a promise to complete. When a wait function is invoked -it is expected to deliver a value to the promise or reject the promise. If the -wait function does not deliver a value, then an exception is thrown. The wait -function provided to a promise constructor is invoked when the `wait` function -of the promise is called. - -```php -$promise = new Promise(function () use (&$promise) { - $promise->resolve('foo'); -}); - -// Calling wait will return the value of the promise. -echo $promise->wait(); // outputs "foo" -``` - -If an exception is encountered while invoking the wait function of a promise, -the promise is rejected with the exception and the exception is thrown. - -```php -$promise = new Promise(function () use (&$promise) { - throw new \Exception('foo'); -}); - -$promise->wait(); // throws the exception. -``` - -Calling `wait` on a promise that has been fulfilled will not trigger the wait -function. It will simply return the previously resolved value. - -```php -$promise = new Promise(function () { die('this is not called!'); }); -$promise->resolve('foo'); -echo $promise->wait(); // outputs "foo" -``` - -Calling `wait` on a promise that has been rejected will throw an exception. If -the rejection reason is an instance of `\Exception` the reason is thrown. -Otherwise, a `GuzzleHttp\Promise\RejectionException` is thrown and the reason -can be obtained by calling the `getReason` method of the exception. - -```php -$promise = new Promise(); -$promise->reject('foo'); -$promise->wait(); -``` - -> PHP Fatal error: Uncaught exception 'GuzzleHttp\Promise\RejectionException' with message 'The promise was rejected with value: foo' - - -## Unwrapping a promise - -When synchronously waiting on a promise, you are joining the state of the -promise into the current state of execution (i.e., return the value of the -promise if it was fulfilled or throw an exception if it was rejected). This is -called "unwrapping" the promise. Waiting on a promise will by default unwrap -the promise state. - -You can force a promise to resolve and *not* unwrap the state of the promise -by passing `false` to the first argument of the `wait` function: - -```php -$promise = new Promise(); -$promise->reject('foo'); -// This will not throw an exception. It simply ensures the promise has -// been resolved. -$promise->wait(false); -``` - -When unwrapping a promise, the resolved value of the promise will be waited -upon until the unwrapped value is not a promise. This means that if you resolve -promise A with a promise B and unwrap promise A, the value returned by the -wait function will be the value delivered to promise B. - -**Note**: when you do not unwrap the promise, no value is returned. - - -# Cancellation - -You can cancel a promise that has not yet been fulfilled using the `cancel()` -method of a promise. When creating a promise you can provide an optional -cancel function that when invoked cancels the action of computing a resolution -of the promise. - - -# API - - -## Promise - -When creating a promise object, you can provide an optional `$waitFn` and -`$cancelFn`. `$waitFn` is a function that is invoked with no arguments and is -expected to resolve the promise. `$cancelFn` is a function with no arguments -that is expected to cancel the computation of a promise. It is invoked when the -`cancel()` method of a promise is called. - -```php -use GuzzleHttp\Promise\Promise; - -$promise = new Promise( - function () use (&$promise) { - $promise->resolve('waited'); - }, - function () { - // do something that will cancel the promise computation (e.g., close - // a socket, cancel a database query, etc...) - } -); - -assert('waited' === $promise->wait()); -``` - -A promise has the following methods: - -- `then(callable $onFulfilled, callable $onRejected) : PromiseInterface` - - Appends fulfillment and rejection handlers to the promise, and returns a new promise resolving to the return value of the called handler. - -- `otherwise(callable $onRejected) : PromiseInterface` - - Appends a rejection handler callback to the promise, and returns a new promise resolving to the return value of the callback if it is called, or to its original fulfillment value if the promise is instead fulfilled. - -- `wait($unwrap = true) : mixed` - - Synchronously waits on the promise to complete. - - `$unwrap` controls whether or not the value of the promise is returned for a - fulfilled promise or if an exception is thrown if the promise is rejected. - This is set to `true` by default. - -- `cancel()` - - Attempts to cancel the promise if possible. The promise being cancelled and - the parent most ancestor that has not yet been resolved will also be - cancelled. Any promises waiting on the cancelled promise to resolve will also - be cancelled. - -- `getState() : string` - - Returns the state of the promise. One of `pending`, `fulfilled`, or - `rejected`. - -- `resolve($value)` - - Fulfills the promise with the given `$value`. - -- `reject($reason)` - - Rejects the promise with the given `$reason`. - - -## FulfilledPromise - -A fulfilled promise can be created to represent a promise that has been -fulfilled. - -```php -use GuzzleHttp\Promise\FulfilledPromise; - -$promise = new FulfilledPromise('value'); - -// Fulfilled callbacks are immediately invoked. -$promise->then(function ($value) { - echo $value; -}); -``` - - -## RejectedPromise - -A rejected promise can be created to represent a promise that has been -rejected. - -```php -use GuzzleHttp\Promise\RejectedPromise; - -$promise = new RejectedPromise('Error'); - -// Rejected callbacks are immediately invoked. -$promise->then(null, function ($reason) { - echo $reason; -}); -``` - - -# Promise interop - -This library works with foreign promises that have a `then` method. This means -you can use Guzzle promises with [React promises](https://github.com/reactphp/promise) -for example. When a foreign promise is returned inside of a then method -callback, promise resolution will occur recursively. - -```php -// Create a React promise -$deferred = new React\Promise\Deferred(); -$reactPromise = $deferred->promise(); - -// Create a Guzzle promise that is fulfilled with a React promise. -$guzzlePromise = new \GuzzleHttp\Promise\Promise(); -$guzzlePromise->then(function ($value) use ($reactPromise) { - // Do something something with the value... - // Return the React promise - return $reactPromise; -}); -``` - -Please note that wait and cancel chaining is no longer possible when forwarding -a foreign promise. You will need to wrap a third-party promise with a Guzzle -promise in order to utilize wait and cancel functions with foreign promises. - - -## Event Loop Integration - -In order to keep the stack size constant, Guzzle promises are resolved -asynchronously using a task queue. When waiting on promises synchronously, the -task queue will be automatically run to ensure that the blocking promise and -any forwarded promises are resolved. When using promises asynchronously in an -event loop, you will need to run the task queue on each tick of the loop. If -you do not run the task queue, then promises will not be resolved. - -You can run the task queue using the `run()` method of the global task queue -instance. - -```php -// Get the global task queue -$queue = \GuzzleHttp\Promise\queue(); -$queue->run(); -``` - -For example, you could use Guzzle promises with React using a periodic timer: - -```php -$loop = React\EventLoop\Factory::create(); -$loop->addPeriodicTimer(0, [$queue, 'run']); -``` - -*TODO*: Perhaps adding a `futureTick()` on each tick would be faster? - - -# Implementation notes - - -## Promise resolution and chaining is handled iteratively - -By shuffling pending handlers from one owner to another, promises are -resolved iteratively, allowing for "infinite" then chaining. - -```php -then(function ($v) { - // The stack size remains constant (a good thing) - echo xdebug_get_stack_depth() . ', '; - return $v + 1; - }); -} - -$parent->resolve(0); -var_dump($p->wait()); // int(1000) - -``` - -When a promise is fulfilled or rejected with a non-promise value, the promise -then takes ownership of the handlers of each child promise and delivers values -down the chain without using recursion. - -When a promise is resolved with another promise, the original promise transfers -all of its pending handlers to the new promise. When the new promise is -eventually resolved, all of the pending handlers are delivered the forwarded -value. - - -## A promise is the deferred. - -Some promise libraries implement promises using a deferred object to represent -a computation and a promise object to represent the delivery of the result of -the computation. This is a nice separation of computation and delivery because -consumers of the promise cannot modify the value that will be eventually -delivered. - -One side effect of being able to implement promise resolution and chaining -iteratively is that you need to be able for one promise to reach into the state -of another promise to shuffle around ownership of handlers. In order to achieve -this without making the handlers of a promise publicly mutable, a promise is -also the deferred value, allowing promises of the same parent class to reach -into and modify the private properties of promises of the same type. While this -does allow consumers of the value to modify the resolution or rejection of the -deferred, it is a small price to pay for keeping the stack size constant. - -```php -$promise = new Promise(); -$promise->then(function ($value) { echo $value; }); -// The promise is the deferred value, so you can deliver a value to it. -$promise->resolve('foo'); -// prints "foo" -``` +# Guzzle Promises + +[Promises/A+](https://promisesaplus.com/) implementation that handles promise +chaining and resolution iteratively, allowing for "infinite" promise chaining +while keeping the stack size constant. Read [this blog post](https://blog.domenic.me/youre-missing-the-point-of-promises/) +for a general introduction to promises. + +- [Features](#features) +- [Quick start](#quick-start) +- [Synchronous wait](#synchronous-wait) +- [Cancellation](#cancellation) +- [API](#api) + - [Promise](#promise) + - [FulfilledPromise](#fulfilledpromise) + - [RejectedPromise](#rejectedpromise) +- [Promise interop](#promise-interop) +- [Implementation notes](#implementation-notes) + + +# Features + +- [Promises/A+](https://promisesaplus.com/) implementation. +- Promise resolution and chaining is handled iteratively, allowing for + "infinite" promise chaining. +- Promises have a synchronous `wait` method. +- Promises can be cancelled. +- Works with any object that has a `then` function. +- C# style async/await coroutine promises using + `GuzzleHttp\Promise\coroutine()`. + + +# Quick start + +A *promise* represents the eventual result of an asynchronous operation. The +primary way of interacting with a promise is through its `then` method, which +registers callbacks to receive either a promise's eventual value or the reason +why the promise cannot be fulfilled. + + +## Callbacks + +Callbacks are registered with the `then` method by providing an optional +`$onFulfilled` followed by an optional `$onRejected` function. + + +```php +use GuzzleHttp\Promise\Promise; + +$promise = new Promise(); +$promise->then( + // $onFulfilled + function ($value) { + echo 'The promise was fulfilled.'; + }, + // $onRejected + function ($reason) { + echo 'The promise was rejected.'; + } +); +``` + +*Resolving* a promise means that you either fulfill a promise with a *value* or +reject a promise with a *reason*. Resolving a promises triggers callbacks +registered with the promises's `then` method. These callbacks are triggered +only once and in the order in which they were added. + + +## Resolving a promise + +Promises are fulfilled using the `resolve($value)` method. Resolving a promise +with any value other than a `GuzzleHttp\Promise\RejectedPromise` will trigger +all of the onFulfilled callbacks (resolving a promise with a rejected promise +will reject the promise and trigger the `$onRejected` callbacks). + +```php +use GuzzleHttp\Promise\Promise; + +$promise = new Promise(); +$promise + ->then(function ($value) { + // Return a value and don't break the chain + return "Hello, " . $value; + }) + // This then is executed after the first then and receives the value + // returned from the first then. + ->then(function ($value) { + echo $value; + }); + +// Resolving the promise triggers the $onFulfilled callbacks and outputs +// "Hello, reader". +$promise->resolve('reader.'); +``` + + +## Promise forwarding + +Promises can be chained one after the other. Each then in the chain is a new +promise. The return value of a promise is what's forwarded to the next +promise in the chain. Returning a promise in a `then` callback will cause the +subsequent promises in the chain to only be fulfilled when the returned promise +has been fulfilled. The next promise in the chain will be invoked with the +resolved value of the promise. + +```php +use GuzzleHttp\Promise\Promise; + +$promise = new Promise(); +$nextPromise = new Promise(); + +$promise + ->then(function ($value) use ($nextPromise) { + echo $value; + return $nextPromise; + }) + ->then(function ($value) { + echo $value; + }); + +// Triggers the first callback and outputs "A" +$promise->resolve('A'); +// Triggers the second callback and outputs "B" +$nextPromise->resolve('B'); +``` + +## Promise rejection + +When a promise is rejected, the `$onRejected` callbacks are invoked with the +rejection reason. + +```php +use GuzzleHttp\Promise\Promise; + +$promise = new Promise(); +$promise->then(null, function ($reason) { + echo $reason; +}); + +$promise->reject('Error!'); +// Outputs "Error!" +``` + +## Rejection forwarding + +If an exception is thrown in an `$onRejected` callback, subsequent +`$onRejected` callbacks are invoked with the thrown exception as the reason. + +```php +use GuzzleHttp\Promise\Promise; + +$promise = new Promise(); +$promise->then(null, function ($reason) { + throw new \Exception($reason); +})->then(null, function ($reason) { + assert($reason->getMessage() === 'Error!'); +}); + +$promise->reject('Error!'); +``` + +You can also forward a rejection down the promise chain by returning a +`GuzzleHttp\Promise\RejectedPromise` in either an `$onFulfilled` or +`$onRejected` callback. + +```php +use GuzzleHttp\Promise\Promise; +use GuzzleHttp\Promise\RejectedPromise; + +$promise = new Promise(); +$promise->then(null, function ($reason) { + return new RejectedPromise($reason); +})->then(null, function ($reason) { + assert($reason === 'Error!'); +}); + +$promise->reject('Error!'); +``` + +If an exception is not thrown in a `$onRejected` callback and the callback +does not return a rejected promise, downstream `$onFulfilled` callbacks are +invoked using the value returned from the `$onRejected` callback. + +```php +use GuzzleHttp\Promise\Promise; +use GuzzleHttp\Promise\RejectedPromise; + +$promise = new Promise(); +$promise + ->then(null, function ($reason) { + return "It's ok"; + }) + ->then(function ($value) { + assert($value === "It's ok"); + }); + +$promise->reject('Error!'); +``` + +# Synchronous wait + +You can synchronously force promises to complete using a promise's `wait` +method. When creating a promise, you can provide a wait function that is used +to synchronously force a promise to complete. When a wait function is invoked +it is expected to deliver a value to the promise or reject the promise. If the +wait function does not deliver a value, then an exception is thrown. The wait +function provided to a promise constructor is invoked when the `wait` function +of the promise is called. + +```php +$promise = new Promise(function () use (&$promise) { + $promise->resolve('foo'); +}); + +// Calling wait will return the value of the promise. +echo $promise->wait(); // outputs "foo" +``` + +If an exception is encountered while invoking the wait function of a promise, +the promise is rejected with the exception and the exception is thrown. + +```php +$promise = new Promise(function () use (&$promise) { + throw new \Exception('foo'); +}); + +$promise->wait(); // throws the exception. +``` + +Calling `wait` on a promise that has been fulfilled will not trigger the wait +function. It will simply return the previously resolved value. + +```php +$promise = new Promise(function () { die('this is not called!'); }); +$promise->resolve('foo'); +echo $promise->wait(); // outputs "foo" +``` + +Calling `wait` on a promise that has been rejected will throw an exception. If +the rejection reason is an instance of `\Exception` the reason is thrown. +Otherwise, a `GuzzleHttp\Promise\RejectionException` is thrown and the reason +can be obtained by calling the `getReason` method of the exception. + +```php +$promise = new Promise(); +$promise->reject('foo'); +$promise->wait(); +``` + +> PHP Fatal error: Uncaught exception 'GuzzleHttp\Promise\RejectionException' with message 'The promise was rejected with value: foo' + + +## Unwrapping a promise + +When synchronously waiting on a promise, you are joining the state of the +promise into the current state of execution (i.e., return the value of the +promise if it was fulfilled or throw an exception if it was rejected). This is +called "unwrapping" the promise. Waiting on a promise will by default unwrap +the promise state. + +You can force a promise to resolve and *not* unwrap the state of the promise +by passing `false` to the first argument of the `wait` function: + +```php +$promise = new Promise(); +$promise->reject('foo'); +// This will not throw an exception. It simply ensures the promise has +// been resolved. +$promise->wait(false); +``` + +When unwrapping a promise, the resolved value of the promise will be waited +upon until the unwrapped value is not a promise. This means that if you resolve +promise A with a promise B and unwrap promise A, the value returned by the +wait function will be the value delivered to promise B. + +**Note**: when you do not unwrap the promise, no value is returned. + + +# Cancellation + +You can cancel a promise that has not yet been fulfilled using the `cancel()` +method of a promise. When creating a promise you can provide an optional +cancel function that when invoked cancels the action of computing a resolution +of the promise. + + +# API + + +## Promise + +When creating a promise object, you can provide an optional `$waitFn` and +`$cancelFn`. `$waitFn` is a function that is invoked with no arguments and is +expected to resolve the promise. `$cancelFn` is a function with no arguments +that is expected to cancel the computation of a promise. It is invoked when the +`cancel()` method of a promise is called. + +```php +use GuzzleHttp\Promise\Promise; + +$promise = new Promise( + function () use (&$promise) { + $promise->resolve('waited'); + }, + function () { + // do something that will cancel the promise computation (e.g., close + // a socket, cancel a database query, etc...) + } +); + +assert('waited' === $promise->wait()); +``` + +A promise has the following methods: + +- `then(callable $onFulfilled, callable $onRejected) : PromiseInterface` + + Appends fulfillment and rejection handlers to the promise, and returns a new promise resolving to the return value of the called handler. + +- `otherwise(callable $onRejected) : PromiseInterface` + + Appends a rejection handler callback to the promise, and returns a new promise resolving to the return value of the callback if it is called, or to its original fulfillment value if the promise is instead fulfilled. + +- `wait($unwrap = true) : mixed` + + Synchronously waits on the promise to complete. + + `$unwrap` controls whether or not the value of the promise is returned for a + fulfilled promise or if an exception is thrown if the promise is rejected. + This is set to `true` by default. + +- `cancel()` + + Attempts to cancel the promise if possible. The promise being cancelled and + the parent most ancestor that has not yet been resolved will also be + cancelled. Any promises waiting on the cancelled promise to resolve will also + be cancelled. + +- `getState() : string` + + Returns the state of the promise. One of `pending`, `fulfilled`, or + `rejected`. + +- `resolve($value)` + + Fulfills the promise with the given `$value`. + +- `reject($reason)` + + Rejects the promise with the given `$reason`. + + +## FulfilledPromise + +A fulfilled promise can be created to represent a promise that has been +fulfilled. + +```php +use GuzzleHttp\Promise\FulfilledPromise; + +$promise = new FulfilledPromise('value'); + +// Fulfilled callbacks are immediately invoked. +$promise->then(function ($value) { + echo $value; +}); +``` + + +## RejectedPromise + +A rejected promise can be created to represent a promise that has been +rejected. + +```php +use GuzzleHttp\Promise\RejectedPromise; + +$promise = new RejectedPromise('Error'); + +// Rejected callbacks are immediately invoked. +$promise->then(null, function ($reason) { + echo $reason; +}); +``` + + +# Promise interop + +This library works with foreign promises that have a `then` method. This means +you can use Guzzle promises with [React promises](https://github.com/reactphp/promise) +for example. When a foreign promise is returned inside of a then method +callback, promise resolution will occur recursively. + +```php +// Create a React promise +$deferred = new React\Promise\Deferred(); +$reactPromise = $deferred->promise(); + +// Create a Guzzle promise that is fulfilled with a React promise. +$guzzlePromise = new \GuzzleHttp\Promise\Promise(); +$guzzlePromise->then(function ($value) use ($reactPromise) { + // Do something something with the value... + // Return the React promise + return $reactPromise; +}); +``` + +Please note that wait and cancel chaining is no longer possible when forwarding +a foreign promise. You will need to wrap a third-party promise with a Guzzle +promise in order to utilize wait and cancel functions with foreign promises. + + +## Event Loop Integration + +In order to keep the stack size constant, Guzzle promises are resolved +asynchronously using a task queue. When waiting on promises synchronously, the +task queue will be automatically run to ensure that the blocking promise and +any forwarded promises are resolved. When using promises asynchronously in an +event loop, you will need to run the task queue on each tick of the loop. If +you do not run the task queue, then promises will not be resolved. + +You can run the task queue using the `run()` method of the global task queue +instance. + +```php +// Get the global task queue +$queue = \GuzzleHttp\Promise\queue(); +$queue->run(); +``` + +For example, you could use Guzzle promises with React using a periodic timer: + +```php +$loop = React\EventLoop\Factory::create(); +$loop->addPeriodicTimer(0, [$queue, 'run']); +``` + +*TODO*: Perhaps adding a `futureTick()` on each tick would be faster? + + +# Implementation notes + + +## Promise resolution and chaining is handled iteratively + +By shuffling pending handlers from one owner to another, promises are +resolved iteratively, allowing for "infinite" then chaining. + +```php +then(function ($v) { + // The stack size remains constant (a good thing) + echo xdebug_get_stack_depth() . ', '; + return $v + 1; + }); +} + +$parent->resolve(0); +var_dump($p->wait()); // int(1000) + +``` + +When a promise is fulfilled or rejected with a non-promise value, the promise +then takes ownership of the handlers of each child promise and delivers values +down the chain without using recursion. + +When a promise is resolved with another promise, the original promise transfers +all of its pending handlers to the new promise. When the new promise is +eventually resolved, all of the pending handlers are delivered the forwarded +value. + + +## A promise is the deferred. + +Some promise libraries implement promises using a deferred object to represent +a computation and a promise object to represent the delivery of the result of +the computation. This is a nice separation of computation and delivery because +consumers of the promise cannot modify the value that will be eventually +delivered. + +One side effect of being able to implement promise resolution and chaining +iteratively is that you need to be able for one promise to reach into the state +of another promise to shuffle around ownership of handlers. In order to achieve +this without making the handlers of a promise publicly mutable, a promise is +also the deferred value, allowing promises of the same parent class to reach +into and modify the private properties of promises of the same type. While this +does allow consumers of the value to modify the resolution or rejection of the +deferred, it is a small price to pay for keeping the stack size constant. + +```php +$promise = new Promise(); +$promise->then(function ($value) { echo $value; }); +// The promise is the deferred value, so you can deliver a value to it. +$promise->resolve('foo'); +// prints "foo" +``` diff --git a/vendor/guzzlehttp/promises/composer.json b/vendor/guzzlehttp/promises/composer.json index 695f08063..ef08a327f 100644 --- a/vendor/guzzlehttp/promises/composer.json +++ b/vendor/guzzlehttp/promises/composer.json @@ -1,38 +1,38 @@ -{ - "name": "guzzlehttp\/promises", - "description": "Guzzle promises library", - "keywords": [ - "promise" - ], - "license": "MIT", - "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https:\/\/github.com\/mtdowling" - } - ], - "require": { - "php": ">=5.5.0" - }, - "require-dev": { - "phpunit\/phpunit": "^4.0" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\": "src\/" - }, - "files": [ - "src\/functions_include.php" - ] - }, - "scripts": { - "test": "vendor\/bin\/phpunit", - "test-ci": "vendor\/bin\/phpunit --coverage-text" - }, - "extra": { - "branch-alias": { - "dev-master": "1.4-dev" - } - } +{ + "name": "guzzlehttp\/promises", + "description": "Guzzle promises library", + "keywords": [ + "promise" + ], + "license": "MIT", + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https:\/\/github.com\/mtdowling" + } + ], + "require": { + "php": ">=5.5.0" + }, + "require-dev": { + "phpunit\/phpunit": "^4.0" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Promise\\": "src\/" + }, + "files": [ + "src\/functions_include.php" + ] + }, + "scripts": { + "test": "vendor\/bin\/phpunit", + "test-ci": "vendor\/bin\/phpunit --coverage-text" + }, + "extra": { + "branch-alias": { + "dev-master": "1.4-dev" + } + } } \ No newline at end of file diff --git a/vendor/guzzlehttp/promises/index.php b/vendor/guzzlehttp/promises/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/guzzlehttp/promises/index.php +++ b/vendor/guzzlehttp/promises/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/promises/src/AggregateException.php b/vendor/guzzlehttp/promises/src/AggregateException.php index b1c95676b..42cacfe13 100644 --- a/vendor/guzzlehttp/promises/src/AggregateException.php +++ b/vendor/guzzlehttp/promises/src/AggregateException.php @@ -1,14 +1,14 @@ -then(function ($v) { echo $v; }); - * - * @param callable $generatorFn Generator function to wrap into a promise. - * - * @return Promise - * @link https://github.com/petkaantonov/bluebird/blob/master/API.md#generators inspiration - */ -final class Coroutine implements \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface -{ - /** - * @var PromiseInterface|null - */ - private $currentPromise; - /** - * @var Generator - */ - private $generator; - /** - * @var Promise - */ - private $result; - public function __construct(callable $generatorFn) - { - $this->generator = $generatorFn(); - $this->result = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise(function () { - while (isset($this->currentPromise)) { - $this->currentPromise->wait(); - } - }); - $this->nextCoroutine($this->generator->current()); - } - public function then(callable $onFulfilled = null, callable $onRejected = null) - { - return $this->result->then($onFulfilled, $onRejected); - } - public function otherwise(callable $onRejected) - { - return $this->result->otherwise($onRejected); - } - public function wait($unwrap = \true) - { - return $this->result->wait($unwrap); - } - public function getState() - { - return $this->result->getState(); - } - public function resolve($value) - { - $this->result->resolve($value); - } - public function reject($reason) - { - $this->result->reject($reason); - } - public function cancel() - { - $this->currentPromise->cancel(); - $this->result->cancel(); - } - private function nextCoroutine($yielded) - { - $this->currentPromise = promise_for($yielded)->then([$this, '_handleSuccess'], [$this, '_handleFailure']); - } - /** - * @internal - */ - public function _handleSuccess($value) - { - unset($this->currentPromise); - try { - $next = $this->generator->send($value); - if ($this->generator->valid()) { - $this->nextCoroutine($next); - } else { - $this->result->resolve($value); - } - } catch (\Exception $exception) { - $this->result->reject($exception); - } catch (\Throwable $throwable) { - $this->result->reject($throwable); - } - } - /** - * @internal - */ - public function _handleFailure($reason) - { - unset($this->currentPromise); - try { - $nextYield = $this->generator->throw(exception_for($reason)); - // The throw was caught, so keep iterating on the coroutine - $this->nextCoroutine($nextYield); - } catch (\Exception $exception) { - $this->result->reject($exception); - } catch (\Throwable $throwable) { - $this->result->reject($throwable); - } - } -} +then(function ($v) { echo $v; }); + * + * @param callable $generatorFn Generator function to wrap into a promise. + * + * @return Promise + * @link https://github.com/petkaantonov/bluebird/blob/master/API.md#generators inspiration + */ +final class Coroutine implements \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface +{ + /** + * @var PromiseInterface|null + */ + private $currentPromise; + /** + * @var Generator + */ + private $generator; + /** + * @var Promise + */ + private $result; + public function __construct(callable $generatorFn) + { + $this->generator = $generatorFn(); + $this->result = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise(function () { + while (isset($this->currentPromise)) { + $this->currentPromise->wait(); + } + }); + $this->nextCoroutine($this->generator->current()); + } + public function then(callable $onFulfilled = null, callable $onRejected = null) + { + return $this->result->then($onFulfilled, $onRejected); + } + public function otherwise(callable $onRejected) + { + return $this->result->otherwise($onRejected); + } + public function wait($unwrap = \true) + { + return $this->result->wait($unwrap); + } + public function getState() + { + return $this->result->getState(); + } + public function resolve($value) + { + $this->result->resolve($value); + } + public function reject($reason) + { + $this->result->reject($reason); + } + public function cancel() + { + $this->currentPromise->cancel(); + $this->result->cancel(); + } + private function nextCoroutine($yielded) + { + $this->currentPromise = promise_for($yielded)->then([$this, '_handleSuccess'], [$this, '_handleFailure']); + } + /** + * @internal + */ + public function _handleSuccess($value) + { + unset($this->currentPromise); + try { + $next = $this->generator->send($value); + if ($this->generator->valid()) { + $this->nextCoroutine($next); + } else { + $this->result->resolve($value); + } + } catch (\Exception $exception) { + $this->result->reject($exception); + } catch (\Throwable $throwable) { + $this->result->reject($throwable); + } + } + /** + * @internal + */ + public function _handleFailure($reason) + { + unset($this->currentPromise); + try { + $nextYield = $this->generator->throw(exception_for($reason)); + // The throw was caught, so keep iterating on the coroutine + $this->nextCoroutine($nextYield); + } catch (\Exception $exception) { + $this->result->reject($exception); + } catch (\Throwable $throwable) { + $this->result->reject($throwable); + } + } +} diff --git a/vendor/guzzlehttp/promises/src/EachPromise.php b/vendor/guzzlehttp/promises/src/EachPromise.php index 578d8bf1d..56276cb19 100644 --- a/vendor/guzzlehttp/promises/src/EachPromise.php +++ b/vendor/guzzlehttp/promises/src/EachPromise.php @@ -1,190 +1,190 @@ -iterable = iter_for($iterable); - if (isset($config['concurrency'])) { - $this->concurrency = $config['concurrency']; - } - if (isset($config['fulfilled'])) { - $this->onFulfilled = $config['fulfilled']; - } - if (isset($config['rejected'])) { - $this->onRejected = $config['rejected']; - } - } - public function promise() - { - if ($this->aggregate) { - return $this->aggregate; - } - try { - $this->createPromise(); - $this->iterable->rewind(); - $this->refillPending(); - } catch (\Throwable $e) { - $this->aggregate->reject($e); - } catch (\Exception $e) { - $this->aggregate->reject($e); - } - return $this->aggregate; - } - private function createPromise() - { - $this->mutex = \false; - $this->aggregate = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise(function () { - \reset($this->pending); - if (empty($this->pending) && !$this->iterable->valid()) { - $this->aggregate->resolve(null); - return; - } - // Consume a potentially fluctuating list of promises while - // ensuring that indexes are maintained (precluding array_shift). - while ($promise = \current($this->pending)) { - \next($this->pending); - $promise->wait(); - if ($this->aggregate->getState() !== \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::PENDING) { - return; - } - } - }); - // Clear the references when the promise is resolved. - $clearFn = function () { - $this->iterable = $this->concurrency = $this->pending = null; - $this->onFulfilled = $this->onRejected = null; - }; - $this->aggregate->then($clearFn, $clearFn); - } - private function refillPending() - { - if (!$this->concurrency) { - // Add all pending promises. - while ($this->addPending() && $this->advanceIterator()) { - } - return; - } - // Add only up to N pending promises. - $concurrency = \is_callable($this->concurrency) ? \call_user_func($this->concurrency, \count($this->pending)) : $this->concurrency; - $concurrency = \max($concurrency - \count($this->pending), 0); - // Concurrency may be set to 0 to disallow new promises. - if (!$concurrency) { - return; - } - // Add the first pending promise. - $this->addPending(); - // Note this is special handling for concurrency=1 so that we do - // not advance the iterator after adding the first promise. This - // helps work around issues with generators that might not have the - // next value to yield until promise callbacks are called. - while (--$concurrency && $this->advanceIterator() && $this->addPending()) { - } - } - private function addPending() - { - if (!$this->iterable || !$this->iterable->valid()) { - return \false; - } - $promise = promise_for($this->iterable->current()); - $idx = $this->iterable->key(); - $this->pending[$idx] = $promise->then(function ($value) use($idx) { - if ($this->onFulfilled) { - \call_user_func($this->onFulfilled, $value, $idx, $this->aggregate); - } - $this->step($idx); - }, function ($reason) use($idx) { - if ($this->onRejected) { - \call_user_func($this->onRejected, $reason, $idx, $this->aggregate); - } - $this->step($idx); - }); - return \true; - } - private function advanceIterator() - { - // Place a lock on the iterator so that we ensure to not recurse, - // preventing fatal generator errors. - if ($this->mutex) { - return \false; - } - $this->mutex = \true; - try { - $this->iterable->next(); - $this->mutex = \false; - return \true; - } catch (\Throwable $e) { - $this->aggregate->reject($e); - $this->mutex = \false; - return \false; - } catch (\Exception $e) { - $this->aggregate->reject($e); - $this->mutex = \false; - return \false; - } - } - private function step($idx) - { - // If the promise was already resolved, then ignore this step. - if ($this->aggregate->getState() !== \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::PENDING) { - return; - } - unset($this->pending[$idx]); - // Only refill pending promises if we are not locked, preventing the - // EachPromise to recursively invoke the provided iterator, which - // cause a fatal error: "Cannot resume an already running generator" - if ($this->advanceIterator() && !$this->checkIfFinished()) { - // Add more pending promises if possible. - $this->refillPending(); - } - } - private function checkIfFinished() - { - if (!$this->pending && !$this->iterable->valid()) { - // Resolve the promise if there's nothing left to do. - $this->aggregate->resolve(null); - return \true; - } - return \false; - } -} +iterable = iter_for($iterable); + if (isset($config['concurrency'])) { + $this->concurrency = $config['concurrency']; + } + if (isset($config['fulfilled'])) { + $this->onFulfilled = $config['fulfilled']; + } + if (isset($config['rejected'])) { + $this->onRejected = $config['rejected']; + } + } + public function promise() + { + if ($this->aggregate) { + return $this->aggregate; + } + try { + $this->createPromise(); + $this->iterable->rewind(); + $this->refillPending(); + } catch (\Throwable $e) { + $this->aggregate->reject($e); + } catch (\Exception $e) { + $this->aggregate->reject($e); + } + return $this->aggregate; + } + private function createPromise() + { + $this->mutex = \false; + $this->aggregate = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise(function () { + \reset($this->pending); + if (empty($this->pending) && !$this->iterable->valid()) { + $this->aggregate->resolve(null); + return; + } + // Consume a potentially fluctuating list of promises while + // ensuring that indexes are maintained (precluding array_shift). + while ($promise = \current($this->pending)) { + \next($this->pending); + $promise->wait(); + if ($this->aggregate->getState() !== \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::PENDING) { + return; + } + } + }); + // Clear the references when the promise is resolved. + $clearFn = function () { + $this->iterable = $this->concurrency = $this->pending = null; + $this->onFulfilled = $this->onRejected = null; + }; + $this->aggregate->then($clearFn, $clearFn); + } + private function refillPending() + { + if (!$this->concurrency) { + // Add all pending promises. + while ($this->addPending() && $this->advanceIterator()) { + } + return; + } + // Add only up to N pending promises. + $concurrency = \is_callable($this->concurrency) ? \call_user_func($this->concurrency, \count($this->pending)) : $this->concurrency; + $concurrency = \max($concurrency - \count($this->pending), 0); + // Concurrency may be set to 0 to disallow new promises. + if (!$concurrency) { + return; + } + // Add the first pending promise. + $this->addPending(); + // Note this is special handling for concurrency=1 so that we do + // not advance the iterator after adding the first promise. This + // helps work around issues with generators that might not have the + // next value to yield until promise callbacks are called. + while (--$concurrency && $this->advanceIterator() && $this->addPending()) { + } + } + private function addPending() + { + if (!$this->iterable || !$this->iterable->valid()) { + return \false; + } + $promise = promise_for($this->iterable->current()); + $idx = $this->iterable->key(); + $this->pending[$idx] = $promise->then(function ($value) use($idx) { + if ($this->onFulfilled) { + \call_user_func($this->onFulfilled, $value, $idx, $this->aggregate); + } + $this->step($idx); + }, function ($reason) use($idx) { + if ($this->onRejected) { + \call_user_func($this->onRejected, $reason, $idx, $this->aggregate); + } + $this->step($idx); + }); + return \true; + } + private function advanceIterator() + { + // Place a lock on the iterator so that we ensure to not recurse, + // preventing fatal generator errors. + if ($this->mutex) { + return \false; + } + $this->mutex = \true; + try { + $this->iterable->next(); + $this->mutex = \false; + return \true; + } catch (\Throwable $e) { + $this->aggregate->reject($e); + $this->mutex = \false; + return \false; + } catch (\Exception $e) { + $this->aggregate->reject($e); + $this->mutex = \false; + return \false; + } + } + private function step($idx) + { + // If the promise was already resolved, then ignore this step. + if ($this->aggregate->getState() !== \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::PENDING) { + return; + } + unset($this->pending[$idx]); + // Only refill pending promises if we are not locked, preventing the + // EachPromise to recursively invoke the provided iterator, which + // cause a fatal error: "Cannot resume an already running generator" + if ($this->advanceIterator() && !$this->checkIfFinished()) { + // Add more pending promises if possible. + $this->refillPending(); + } + } + private function checkIfFinished() + { + if (!$this->pending && !$this->iterable->valid()) { + // Resolve the promise if there's nothing left to do. + $this->aggregate->resolve(null); + return \true; + } + return \false; + } +} diff --git a/vendor/guzzlehttp/promises/src/FulfilledPromise.php b/vendor/guzzlehttp/promises/src/FulfilledPromise.php index 4f4f145d3..ec1e71e0d 100644 --- a/vendor/guzzlehttp/promises/src/FulfilledPromise.php +++ b/vendor/guzzlehttp/promises/src/FulfilledPromise.php @@ -1,69 +1,69 @@ -value = $value; - } - public function then(callable $onFulfilled = null, callable $onRejected = null) - { - // Return itself if there is no onFulfilled function. - if (!$onFulfilled) { - return $this; - } - $queue = queue(); - $p = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise([$queue, 'run']); - $value = $this->value; - $queue->add(static function () use($p, $value, $onFulfilled) { - if ($p->getState() === self::PENDING) { - try { - $p->resolve($onFulfilled($value)); - } catch (\Throwable $e) { - $p->reject($e); - } catch (\Exception $e) { - $p->reject($e); - } - } - }); - return $p; - } - public function otherwise(callable $onRejected) - { - return $this->then(null, $onRejected); - } - public function wait($unwrap = \true, $defaultDelivery = null) - { - return $unwrap ? $this->value : null; - } - public function getState() - { - return self::FULFILLED; - } - public function resolve($value) - { - if ($value !== $this->value) { - throw new \LogicException("Cannot resolve a fulfilled promise"); - } - } - public function reject($reason) - { - throw new \LogicException("Cannot reject a fulfilled promise"); - } - public function cancel() - { - // pass - } -} +value = $value; + } + public function then(callable $onFulfilled = null, callable $onRejected = null) + { + // Return itself if there is no onFulfilled function. + if (!$onFulfilled) { + return $this; + } + $queue = queue(); + $p = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise([$queue, 'run']); + $value = $this->value; + $queue->add(static function () use($p, $value, $onFulfilled) { + if ($p->getState() === self::PENDING) { + try { + $p->resolve($onFulfilled($value)); + } catch (\Throwable $e) { + $p->reject($e); + } catch (\Exception $e) { + $p->reject($e); + } + } + }); + return $p; + } + public function otherwise(callable $onRejected) + { + return $this->then(null, $onRejected); + } + public function wait($unwrap = \true, $defaultDelivery = null) + { + return $unwrap ? $this->value : null; + } + public function getState() + { + return self::FULFILLED; + } + public function resolve($value) + { + if ($value !== $this->value) { + throw new \LogicException("Cannot resolve a fulfilled promise"); + } + } + public function reject($reason) + { + throw new \LogicException("Cannot reject a fulfilled promise"); + } + public function cancel() + { + // pass + } +} diff --git a/vendor/guzzlehttp/promises/src/Promise.php b/vendor/guzzlehttp/promises/src/Promise.php index 1528a0b14..5ccf7f5ac 100644 --- a/vendor/guzzlehttp/promises/src/Promise.php +++ b/vendor/guzzlehttp/promises/src/Promise.php @@ -1,231 +1,231 @@ -waitFn = $waitFn; - $this->cancelFn = $cancelFn; - } - public function then(callable $onFulfilled = null, callable $onRejected = null) - { - if ($this->state === self::PENDING) { - $p = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise(null, [$this, 'cancel']); - $this->handlers[] = [$p, $onFulfilled, $onRejected]; - $p->waitList = $this->waitList; - $p->waitList[] = $this; - return $p; - } - // Return a fulfilled promise and immediately invoke any callbacks. - if ($this->state === self::FULFILLED) { - return $onFulfilled ? promise_for($this->result)->then($onFulfilled) : promise_for($this->result); - } - // It's either cancelled or rejected, so return a rejected promise - // and immediately invoke any callbacks. - $rejection = rejection_for($this->result); - return $onRejected ? $rejection->then(null, $onRejected) : $rejection; - } - public function otherwise(callable $onRejected) - { - return $this->then(null, $onRejected); - } - public function wait($unwrap = \true) - { - $this->waitIfPending(); - $inner = $this->result instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface ? $this->result->wait($unwrap) : $this->result; - if ($unwrap) { - if ($this->result instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface || $this->state === self::FULFILLED) { - return $inner; - } else { - // It's rejected so "unwrap" and throw an exception. - throw exception_for($inner); - } - } - } - public function getState() - { - return $this->state; - } - public function cancel() - { - if ($this->state !== self::PENDING) { - return; - } - $this->waitFn = $this->waitList = null; - if ($this->cancelFn) { - $fn = $this->cancelFn; - $this->cancelFn = null; - try { - $fn(); - } catch (\Throwable $e) { - $this->reject($e); - } catch (\Exception $e) { - $this->reject($e); - } - } - // Reject the promise only if it wasn't rejected in a then callback. - if ($this->state === self::PENDING) { - $this->reject(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\CancellationException('Promise has been cancelled')); - } - } - public function resolve($value) - { - $this->settle(self::FULFILLED, $value); - } - public function reject($reason) - { - $this->settle(self::REJECTED, $reason); - } - private function settle($state, $value) - { - if ($this->state !== self::PENDING) { - // Ignore calls with the same resolution. - if ($state === $this->state && $value === $this->result) { - return; - } - throw $this->state === $state ? new \LogicException("The promise is already {$state}.") : new \LogicException("Cannot change a {$this->state} promise to {$state}"); - } - if ($value === $this) { - throw new \LogicException('Cannot fulfill or reject a promise with itself'); - } - // Clear out the state of the promise but stash the handlers. - $this->state = $state; - $this->result = $value; - $handlers = $this->handlers; - $this->handlers = null; - $this->waitList = $this->waitFn = null; - $this->cancelFn = null; - if (!$handlers) { - return; - } - // If the value was not a settled promise or a thenable, then resolve - // it in the task queue using the correct ID. - if (!\method_exists($value, 'then')) { - $id = $state === self::FULFILLED ? 1 : 2; - // It's a success, so resolve the handlers in the queue. - queue()->add(static function () use($id, $value, $handlers) { - foreach ($handlers as $handler) { - self::callHandler($id, $value, $handler); - } - }); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise && $value->getState() === self::PENDING) { - // We can just merge our handlers onto the next promise. - $value->handlers = \array_merge($value->handlers, $handlers); - } else { - // Resolve the handlers when the forwarded promise is resolved. - $value->then(static function ($value) use($handlers) { - foreach ($handlers as $handler) { - self::callHandler(1, $value, $handler); - } - }, static function ($reason) use($handlers) { - foreach ($handlers as $handler) { - self::callHandler(2, $reason, $handler); - } - }); - } - } - /** - * Call a stack of handlers using a specific callback index and value. - * - * @param int $index 1 (resolve) or 2 (reject). - * @param mixed $value Value to pass to the callback. - * @param array $handler Array of handler data (promise and callbacks). - * - * @return array Returns the next group to resolve. - */ - private static function callHandler($index, $value, array $handler) - { - /** @var PromiseInterface $promise */ - $promise = $handler[0]; - // The promise may have been cancelled or resolved before placing - // this thunk in the queue. - if ($promise->getState() !== self::PENDING) { - return; - } - try { - if (isset($handler[$index])) { - $promise->resolve($handler[$index]($value)); - } elseif ($index === 1) { - // Forward resolution values as-is. - $promise->resolve($value); - } else { - // Forward rejections down the chain. - $promise->reject($value); - } - } catch (\Throwable $reason) { - $promise->reject($reason); - } catch (\Exception $reason) { - $promise->reject($reason); - } - } - private function waitIfPending() - { - if ($this->state !== self::PENDING) { - return; - } elseif ($this->waitFn) { - $this->invokeWaitFn(); - } elseif ($this->waitList) { - $this->invokeWaitList(); - } else { - // If there's not wait function, then reject the promise. - $this->reject('Cannot wait on a promise that has ' . 'no internal wait function. You must provide a wait ' . 'function when constructing the promise to be able to ' . 'wait on a promise.'); - } - queue()->run(); - if ($this->state === self::PENDING) { - $this->reject('Invoking the wait callback did not resolve the promise'); - } - } - private function invokeWaitFn() - { - try { - $wfn = $this->waitFn; - $this->waitFn = null; - $wfn(\true); - } catch (\Exception $reason) { - if ($this->state === self::PENDING) { - // The promise has not been resolved yet, so reject the promise - // with the exception. - $this->reject($reason); - } else { - // The promise was already resolved, so there's a problem in - // the application. - throw $reason; - } - } - } - private function invokeWaitList() - { - $waitList = $this->waitList; - $this->waitList = null; - foreach ($waitList as $result) { - while (\true) { - $result->waitIfPending(); - if ($result->result instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise) { - $result = $result->result; - } else { - if ($result->result instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface) { - $result->result->wait(\false); - } - break; - } - } - } - } -} +waitFn = $waitFn; + $this->cancelFn = $cancelFn; + } + public function then(callable $onFulfilled = null, callable $onRejected = null) + { + if ($this->state === self::PENDING) { + $p = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise(null, [$this, 'cancel']); + $this->handlers[] = [$p, $onFulfilled, $onRejected]; + $p->waitList = $this->waitList; + $p->waitList[] = $this; + return $p; + } + // Return a fulfilled promise and immediately invoke any callbacks. + if ($this->state === self::FULFILLED) { + return $onFulfilled ? promise_for($this->result)->then($onFulfilled) : promise_for($this->result); + } + // It's either cancelled or rejected, so return a rejected promise + // and immediately invoke any callbacks. + $rejection = rejection_for($this->result); + return $onRejected ? $rejection->then(null, $onRejected) : $rejection; + } + public function otherwise(callable $onRejected) + { + return $this->then(null, $onRejected); + } + public function wait($unwrap = \true) + { + $this->waitIfPending(); + $inner = $this->result instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface ? $this->result->wait($unwrap) : $this->result; + if ($unwrap) { + if ($this->result instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface || $this->state === self::FULFILLED) { + return $inner; + } else { + // It's rejected so "unwrap" and throw an exception. + throw exception_for($inner); + } + } + } + public function getState() + { + return $this->state; + } + public function cancel() + { + if ($this->state !== self::PENDING) { + return; + } + $this->waitFn = $this->waitList = null; + if ($this->cancelFn) { + $fn = $this->cancelFn; + $this->cancelFn = null; + try { + $fn(); + } catch (\Throwable $e) { + $this->reject($e); + } catch (\Exception $e) { + $this->reject($e); + } + } + // Reject the promise only if it wasn't rejected in a then callback. + if ($this->state === self::PENDING) { + $this->reject(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\CancellationException('Promise has been cancelled')); + } + } + public function resolve($value) + { + $this->settle(self::FULFILLED, $value); + } + public function reject($reason) + { + $this->settle(self::REJECTED, $reason); + } + private function settle($state, $value) + { + if ($this->state !== self::PENDING) { + // Ignore calls with the same resolution. + if ($state === $this->state && $value === $this->result) { + return; + } + throw $this->state === $state ? new \LogicException("The promise is already {$state}.") : new \LogicException("Cannot change a {$this->state} promise to {$state}"); + } + if ($value === $this) { + throw new \LogicException('Cannot fulfill or reject a promise with itself'); + } + // Clear out the state of the promise but stash the handlers. + $this->state = $state; + $this->result = $value; + $handlers = $this->handlers; + $this->handlers = null; + $this->waitList = $this->waitFn = null; + $this->cancelFn = null; + if (!$handlers) { + return; + } + // If the value was not a settled promise or a thenable, then resolve + // it in the task queue using the correct ID. + if (!\method_exists($value, 'then')) { + $id = $state === self::FULFILLED ? 1 : 2; + // It's a success, so resolve the handlers in the queue. + queue()->add(static function () use($id, $value, $handlers) { + foreach ($handlers as $handler) { + self::callHandler($id, $value, $handler); + } + }); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise && $value->getState() === self::PENDING) { + // We can just merge our handlers onto the next promise. + $value->handlers = \array_merge($value->handlers, $handlers); + } else { + // Resolve the handlers when the forwarded promise is resolved. + $value->then(static function ($value) use($handlers) { + foreach ($handlers as $handler) { + self::callHandler(1, $value, $handler); + } + }, static function ($reason) use($handlers) { + foreach ($handlers as $handler) { + self::callHandler(2, $reason, $handler); + } + }); + } + } + /** + * Call a stack of handlers using a specific callback index and value. + * + * @param int $index 1 (resolve) or 2 (reject). + * @param mixed $value Value to pass to the callback. + * @param array $handler Array of handler data (promise and callbacks). + * + * @return array Returns the next group to resolve. + */ + private static function callHandler($index, $value, array $handler) + { + /** @var PromiseInterface $promise */ + $promise = $handler[0]; + // The promise may have been cancelled or resolved before placing + // this thunk in the queue. + if ($promise->getState() !== self::PENDING) { + return; + } + try { + if (isset($handler[$index])) { + $promise->resolve($handler[$index]($value)); + } elseif ($index === 1) { + // Forward resolution values as-is. + $promise->resolve($value); + } else { + // Forward rejections down the chain. + $promise->reject($value); + } + } catch (\Throwable $reason) { + $promise->reject($reason); + } catch (\Exception $reason) { + $promise->reject($reason); + } + } + private function waitIfPending() + { + if ($this->state !== self::PENDING) { + return; + } elseif ($this->waitFn) { + $this->invokeWaitFn(); + } elseif ($this->waitList) { + $this->invokeWaitList(); + } else { + // If there's not wait function, then reject the promise. + $this->reject('Cannot wait on a promise that has ' . 'no internal wait function. You must provide a wait ' . 'function when constructing the promise to be able to ' . 'wait on a promise.'); + } + queue()->run(); + if ($this->state === self::PENDING) { + $this->reject('Invoking the wait callback did not resolve the promise'); + } + } + private function invokeWaitFn() + { + try { + $wfn = $this->waitFn; + $this->waitFn = null; + $wfn(\true); + } catch (\Exception $reason) { + if ($this->state === self::PENDING) { + // The promise has not been resolved yet, so reject the promise + // with the exception. + $this->reject($reason); + } else { + // The promise was already resolved, so there's a problem in + // the application. + throw $reason; + } + } + } + private function invokeWaitList() + { + $waitList = $this->waitList; + $this->waitList = null; + foreach ($waitList as $result) { + while (\true) { + $result->waitIfPending(); + if ($result->result instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise) { + $result = $result->result; + } else { + if ($result->result instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface) { + $result->result->wait(\false); + } + break; + } + } + } + } +} diff --git a/vendor/guzzlehttp/promises/src/PromiseInterface.php b/vendor/guzzlehttp/promises/src/PromiseInterface.php index 4ae3e0841..7f8fbb713 100644 --- a/vendor/guzzlehttp/promises/src/PromiseInterface.php +++ b/vendor/guzzlehttp/promises/src/PromiseInterface.php @@ -1,84 +1,84 @@ -reason = $reason; - } - public function then(callable $onFulfilled = null, callable $onRejected = null) - { - // If there's no onRejected callback then just return self. - if (!$onRejected) { - return $this; - } - $queue = queue(); - $reason = $this->reason; - $p = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise([$queue, 'run']); - $queue->add(static function () use($p, $reason, $onRejected) { - if ($p->getState() === self::PENDING) { - try { - // Return a resolved promise if onRejected does not throw. - $p->resolve($onRejected($reason)); - } catch (\Throwable $e) { - // onRejected threw, so return a rejected promise. - $p->reject($e); - } catch (\Exception $e) { - // onRejected threw, so return a rejected promise. - $p->reject($e); - } - } - }); - return $p; - } - public function otherwise(callable $onRejected) - { - return $this->then(null, $onRejected); - } - public function wait($unwrap = \true, $defaultDelivery = null) - { - if ($unwrap) { - throw exception_for($this->reason); - } - } - public function getState() - { - return self::REJECTED; - } - public function resolve($value) - { - throw new \LogicException("Cannot resolve a rejected promise"); - } - public function reject($reason) - { - if ($reason !== $this->reason) { - throw new \LogicException("Cannot reject a rejected promise"); - } - } - public function cancel() - { - // pass - } -} +reason = $reason; + } + public function then(callable $onFulfilled = null, callable $onRejected = null) + { + // If there's no onRejected callback then just return self. + if (!$onRejected) { + return $this; + } + $queue = queue(); + $reason = $this->reason; + $p = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise([$queue, 'run']); + $queue->add(static function () use($p, $reason, $onRejected) { + if ($p->getState() === self::PENDING) { + try { + // Return a resolved promise if onRejected does not throw. + $p->resolve($onRejected($reason)); + } catch (\Throwable $e) { + // onRejected threw, so return a rejected promise. + $p->reject($e); + } catch (\Exception $e) { + // onRejected threw, so return a rejected promise. + $p->reject($e); + } + } + }); + return $p; + } + public function otherwise(callable $onRejected) + { + return $this->then(null, $onRejected); + } + public function wait($unwrap = \true, $defaultDelivery = null) + { + if ($unwrap) { + throw exception_for($this->reason); + } + } + public function getState() + { + return self::REJECTED; + } + public function resolve($value) + { + throw new \LogicException("Cannot resolve a rejected promise"); + } + public function reject($reason) + { + if ($reason !== $this->reason) { + throw new \LogicException("Cannot reject a rejected promise"); + } + } + public function cancel() + { + // pass + } +} diff --git a/vendor/guzzlehttp/promises/src/RejectionException.php b/vendor/guzzlehttp/promises/src/RejectionException.php index a13202996..48389eac3 100644 --- a/vendor/guzzlehttp/promises/src/RejectionException.php +++ b/vendor/guzzlehttp/promises/src/RejectionException.php @@ -1,40 +1,40 @@ -reason = $reason; - $message = 'The promise was rejected'; - if ($description) { - $message .= ' with reason: ' . $description; - } elseif (\is_string($reason) || \is_object($reason) && \method_exists($reason, '__toString')) { - $message .= ' with reason: ' . $this->reason; - } elseif ($reason instanceof \JsonSerializable) { - $message .= ' with reason: ' . \json_encode($this->reason, \JSON_PRETTY_PRINT); - } - parent::__construct($message); - } - /** - * Returns the rejection reason. - * - * @return mixed - */ - public function getReason() - { - return $this->reason; - } -} +reason = $reason; + $message = 'The promise was rejected'; + if ($description) { + $message .= ' with reason: ' . $description; + } elseif (\is_string($reason) || \is_object($reason) && \method_exists($reason, '__toString')) { + $message .= ' with reason: ' . $this->reason; + } elseif ($reason instanceof \JsonSerializable) { + $message .= ' with reason: ' . \json_encode($this->reason, \JSON_PRETTY_PRINT); + } + parent::__construct($message); + } + /** + * Returns the rejection reason. + * + * @return mixed + */ + public function getReason() + { + return $this->reason; + } +} diff --git a/vendor/guzzlehttp/promises/src/TaskQueue.php b/vendor/guzzlehttp/promises/src/TaskQueue.php index 8ff17c98c..f9fba34fb 100644 --- a/vendor/guzzlehttp/promises/src/TaskQueue.php +++ b/vendor/guzzlehttp/promises/src/TaskQueue.php @@ -1,62 +1,62 @@ -run(); - */ -class TaskQueue implements \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\TaskQueueInterface -{ - private $enableShutdown = \true; - private $queue = []; - public function __construct($withShutdown = \true) - { - if ($withShutdown) { - \register_shutdown_function(function () { - if ($this->enableShutdown) { - // Only run the tasks if an E_ERROR didn't occur. - $err = \error_get_last(); - if (!$err || $err['type'] ^ \E_ERROR) { - $this->run(); - } - } - }); - } - } - public function isEmpty() - { - return !$this->queue; - } - public function add(callable $task) - { - $this->queue[] = $task; - } - public function run() - { - /** @var callable $task */ - while ($task = \array_shift($this->queue)) { - $task(); - } - } - /** - * The task queue will be run and exhausted by default when the process - * exits IFF the exit is not the result of a PHP E_ERROR error. - * - * You can disable running the automatic shutdown of the queue by calling - * this function. If you disable the task queue shutdown process, then you - * MUST either run the task queue (as a result of running your event loop - * or manually using the run() method) or wait on each outstanding promise. - * - * Note: This shutdown will occur before any destructors are triggered. - */ - public function disableShutdown() - { - $this->enableShutdown = \false; - } -} +run(); + */ +class TaskQueue implements \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\TaskQueueInterface +{ + private $enableShutdown = \true; + private $queue = []; + public function __construct($withShutdown = \true) + { + if ($withShutdown) { + \register_shutdown_function(function () { + if ($this->enableShutdown) { + // Only run the tasks if an E_ERROR didn't occur. + $err = \error_get_last(); + if (!$err || $err['type'] ^ \E_ERROR) { + $this->run(); + } + } + }); + } + } + public function isEmpty() + { + return !$this->queue; + } + public function add(callable $task) + { + $this->queue[] = $task; + } + public function run() + { + /** @var callable $task */ + while ($task = \array_shift($this->queue)) { + $task(); + } + } + /** + * The task queue will be run and exhausted by default when the process + * exits IFF the exit is not the result of a PHP E_ERROR error. + * + * You can disable running the automatic shutdown of the queue by calling + * this function. If you disable the task queue shutdown process, then you + * MUST either run the task queue (as a result of running your event loop + * or manually using the run() method) or wait on each outstanding promise. + * + * Note: This shutdown will occur before any destructors are triggered. + */ + public function disableShutdown() + { + $this->enableShutdown = \false; + } +} diff --git a/vendor/guzzlehttp/promises/src/TaskQueueInterface.php b/vendor/guzzlehttp/promises/src/TaskQueueInterface.php index 692d08c69..fa9e3cee4 100644 --- a/vendor/guzzlehttp/promises/src/TaskQueueInterface.php +++ b/vendor/guzzlehttp/promises/src/TaskQueueInterface.php @@ -1,24 +1,24 @@ - - * while ($eventLoop->isRunning()) { - * GuzzleHttp\Promise\queue()->run(); - * } - * - * - * @param TaskQueueInterface $assign Optionally specify a new queue instance. - * - * @return TaskQueueInterface - */ -function queue(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\TaskQueueInterface $assign = null) -{ - static $queue; - if ($assign) { - $queue = $assign; - } elseif (!$queue) { - $queue = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\TaskQueue(); - } - return $queue; -} -/** - * Adds a function to run in the task queue when it is next `run()` and returns - * a promise that is fulfilled or rejected with the result. - * - * @param callable $task Task function to run. - * - * @return PromiseInterface - */ -function task(callable $task) -{ - $queue = queue(); - $promise = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise([$queue, 'run']); - $queue->add(function () use($task, $promise) { - try { - $promise->resolve($task()); - } catch (\Throwable $e) { - $promise->reject($e); - } catch (\Exception $e) { - $promise->reject($e); - } - }); - return $promise; -} -/** - * Creates a promise for a value if the value is not a promise. - * - * @param mixed $value Promise or value. - * - * @return PromiseInterface - */ -function promise_for($value) -{ - if ($value instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface) { - return $value; - } - // Return a Guzzle promise that shadows the given promise. - if (\method_exists($value, 'then')) { - $wfn = \method_exists($value, 'wait') ? [$value, 'wait'] : null; - $cfn = \method_exists($value, 'cancel') ? [$value, 'cancel'] : null; - $promise = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise($wfn, $cfn); - $value->then([$promise, 'resolve'], [$promise, 'reject']); - return $promise; - } - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\FulfilledPromise($value); -} -/** - * Creates a rejected promise for a reason if the reason is not a promise. If - * the provided reason is a promise, then it is returned as-is. - * - * @param mixed $reason Promise or reason. - * - * @return PromiseInterface - */ -function rejection_for($reason) -{ - if ($reason instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface) { - return $reason; - } - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\RejectedPromise($reason); -} -/** - * Create an exception for a rejected promise value. - * - * @param mixed $reason - * - * @return \Exception|\Throwable - */ -function exception_for($reason) -{ - return $reason instanceof \Exception || $reason instanceof \Throwable ? $reason : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\RejectionException($reason); -} -/** - * Returns an iterator for the given value. - * - * @param mixed $value - * - * @return \Iterator - */ -function iter_for($value) -{ - if ($value instanceof \Iterator) { - return $value; - } elseif (\is_array($value)) { - return new \ArrayIterator($value); - } else { - return new \ArrayIterator([$value]); - } -} -/** - * Synchronously waits on a promise to resolve and returns an inspection state - * array. - * - * Returns a state associative array containing a "state" key mapping to a - * valid promise state. If the state of the promise is "fulfilled", the array - * will contain a "value" key mapping to the fulfilled value of the promise. If - * the promise is rejected, the array will contain a "reason" key mapping to - * the rejection reason of the promise. - * - * @param PromiseInterface $promise Promise or value. - * - * @return array - */ -function inspect(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $promise) -{ - try { - return ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::FULFILLED, 'value' => $promise->wait()]; - } catch (\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\RejectionException $e) { - return ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $e->getReason()]; - } catch (\Throwable $e) { - return ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $e]; - } catch (\Exception $e) { - return ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $e]; - } -} -/** - * Waits on all of the provided promises, but does not unwrap rejected promises - * as thrown exception. - * - * Returns an array of inspection state arrays. - * - * @param PromiseInterface[] $promises Traversable of promises to wait upon. - * - * @return array - * @see GuzzleHttp\Promise\inspect for the inspection state array format. - */ -function inspect_all($promises) -{ - $results = []; - foreach ($promises as $key => $promise) { - $results[$key] = inspect($promise); - } - return $results; -} -/** - * Waits on all of the provided promises and returns the fulfilled values. - * - * Returns an array that contains the value of each promise (in the same order - * the promises were provided). An exception is thrown if any of the promises - * are rejected. - * - * @param mixed $promises Iterable of PromiseInterface objects to wait on. - * - * @return array - * @throws \Exception on error - * @throws \Throwable on error in PHP >=7 - */ -function unwrap($promises) -{ - $results = []; - foreach ($promises as $key => $promise) { - $results[$key] = $promise->wait(); - } - return $results; -} -/** - * Given an array of promises, return a promise that is fulfilled when all the - * items in the array are fulfilled. - * - * The promise's fulfillment value is an array with fulfillment values at - * respective positions to the original array. If any promise in the array - * rejects, the returned promise is rejected with the rejection reason. - * - * @param mixed $promises Promises or values. - * - * @return PromiseInterface - */ -function all($promises) -{ - $results = []; - return \each($promises, function ($value, $idx) use(&$results) { - $results[$idx] = $value; - }, function ($reason, $idx, \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise $aggregate) { - $aggregate->reject($reason); - })->then(function () use(&$results) { - \ksort($results); - return $results; - }); -} -/** - * Initiate a competitive race between multiple promises or values (values will - * become immediately fulfilled promises). - * - * When count amount of promises have been fulfilled, the returned promise is - * fulfilled with an array that contains the fulfillment values of the winners - * in order of resolution. - * - * This prommise is rejected with a {@see GuzzleHttp\Promise\AggregateException} - * if the number of fulfilled promises is less than the desired $count. - * - * @param int $count Total number of promises. - * @param mixed $promises Promises or values. - * - * @return PromiseInterface - */ -function some($count, $promises) -{ - $results = []; - $rejections = []; - return \each($promises, function ($value, $idx, \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $p) use(&$results, $count) { - if ($p->getState() !== \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::PENDING) { - return; - } - $results[$idx] = $value; - if (\count($results) >= $count) { - $p->resolve(null); - } - }, function ($reason) use(&$rejections) { - $rejections[] = $reason; - })->then(function () use(&$results, &$rejections, $count) { - if (\count($results) !== $count) { - throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\AggregateException('Not enough promises to fulfill count', $rejections); - } - \ksort($results); - return \array_values($results); - }); -} -/** - * Like some(), with 1 as count. However, if the promise fulfills, the - * fulfillment value is not an array of 1 but the value directly. - * - * @param mixed $promises Promises or values. - * - * @return PromiseInterface - */ -function any($promises) -{ - return some(1, $promises)->then(function ($values) { - return $values[0]; - }); -} -/** - * Returns a promise that is fulfilled when all of the provided promises have - * been fulfilled or rejected. - * - * The returned promise is fulfilled with an array of inspection state arrays. - * - * @param mixed $promises Promises or values. - * - * @return PromiseInterface - * @see GuzzleHttp\Promise\inspect for the inspection state array format. - */ -function settle($promises) -{ - $results = []; - return \each($promises, function ($value, $idx) use(&$results) { - $results[$idx] = ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::FULFILLED, 'value' => $value]; - }, function ($reason, $idx) use(&$results) { - $results[$idx] = ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $reason]; - })->then(function () use(&$results) { - \ksort($results); - return $results; - }); -} -/** - * Given an iterator that yields promises or values, returns a promise that is - * fulfilled with a null value when the iterator has been consumed or the - * aggregate promise has been fulfilled or rejected. - * - * $onFulfilled is a function that accepts the fulfilled value, iterator - * index, and the aggregate promise. The callback can invoke any necessary side - * effects and choose to resolve or reject the aggregate promise if needed. - * - * $onRejected is a function that accepts the rejection reason, iterator - * index, and the aggregate promise. The callback can invoke any necessary side - * effects and choose to resolve or reject the aggregate promise if needed. - * - * @param mixed $iterable Iterator or array to iterate over. - * @param callable $onFulfilled - * @param callable $onRejected - * - * @return PromiseInterface - */ -function each($iterable, callable $onFulfilled = null, callable $onRejected = null) -{ - return (new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\EachPromise($iterable, ['fulfilled' => $onFulfilled, 'rejected' => $onRejected]))->promise(); -} -/** - * Like each, but only allows a certain number of outstanding promises at any - * given time. - * - * $concurrency may be an integer or a function that accepts the number of - * pending promises and returns a numeric concurrency limit value to allow for - * dynamic a concurrency size. - * - * @param mixed $iterable - * @param int|callable $concurrency - * @param callable $onFulfilled - * @param callable $onRejected - * - * @return PromiseInterface - */ -function each_limit($iterable, $concurrency, callable $onFulfilled = null, callable $onRejected = null) -{ - return (new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\EachPromise($iterable, ['fulfilled' => $onFulfilled, 'rejected' => $onRejected, 'concurrency' => $concurrency]))->promise(); -} -/** - * Like each_limit, but ensures that no promise in the given $iterable argument - * is rejected. If any promise is rejected, then the aggregate promise is - * rejected with the encountered rejection. - * - * @param mixed $iterable - * @param int|callable $concurrency - * @param callable $onFulfilled - * - * @return PromiseInterface - */ -function each_limit_all($iterable, $concurrency, callable $onFulfilled = null) -{ - return each_limit($iterable, $concurrency, $onFulfilled, function ($reason, $idx, \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $aggregate) { - $aggregate->reject($reason); - }); -} -/** - * Returns true if a promise is fulfilled. - * - * @param PromiseInterface $promise - * - * @return bool - */ -function is_fulfilled(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $promise) -{ - return $promise->getState() === \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::FULFILLED; -} -/** - * Returns true if a promise is rejected. - * - * @param PromiseInterface $promise - * - * @return bool - */ -function is_rejected(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $promise) -{ - return $promise->getState() === \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::REJECTED; -} -/** - * Returns true if a promise is fulfilled or rejected. - * - * @param PromiseInterface $promise - * - * @return bool - */ -function is_settled(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $promise) -{ - return $promise->getState() !== \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::PENDING; -} -/** - * @see Coroutine - * - * @param callable $generatorFn - * - * @return PromiseInterface - */ -function coroutine(callable $generatorFn) -{ - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Coroutine($generatorFn); -} + + * while ($eventLoop->isRunning()) { + * GuzzleHttp\Promise\queue()->run(); + * } + * + * + * @param TaskQueueInterface $assign Optionally specify a new queue instance. + * + * @return TaskQueueInterface + */ +function queue(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\TaskQueueInterface $assign = null) +{ + static $queue; + if ($assign) { + $queue = $assign; + } elseif (!$queue) { + $queue = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\TaskQueue(); + } + return $queue; +} +/** + * Adds a function to run in the task queue when it is next `run()` and returns + * a promise that is fulfilled or rejected with the result. + * + * @param callable $task Task function to run. + * + * @return PromiseInterface + */ +function task(callable $task) +{ + $queue = queue(); + $promise = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise([$queue, 'run']); + $queue->add(function () use($task, $promise) { + try { + $promise->resolve($task()); + } catch (\Throwable $e) { + $promise->reject($e); + } catch (\Exception $e) { + $promise->reject($e); + } + }); + return $promise; +} +/** + * Creates a promise for a value if the value is not a promise. + * + * @param mixed $value Promise or value. + * + * @return PromiseInterface + */ +function promise_for($value) +{ + if ($value instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface) { + return $value; + } + // Return a Guzzle promise that shadows the given promise. + if (\method_exists($value, 'then')) { + $wfn = \method_exists($value, 'wait') ? [$value, 'wait'] : null; + $cfn = \method_exists($value, 'cancel') ? [$value, 'cancel'] : null; + $promise = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise($wfn, $cfn); + $value->then([$promise, 'resolve'], [$promise, 'reject']); + return $promise; + } + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\FulfilledPromise($value); +} +/** + * Creates a rejected promise for a reason if the reason is not a promise. If + * the provided reason is a promise, then it is returned as-is. + * + * @param mixed $reason Promise or reason. + * + * @return PromiseInterface + */ +function rejection_for($reason) +{ + if ($reason instanceof \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface) { + return $reason; + } + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\RejectedPromise($reason); +} +/** + * Create an exception for a rejected promise value. + * + * @param mixed $reason + * + * @return \Exception|\Throwable + */ +function exception_for($reason) +{ + return $reason instanceof \Exception || $reason instanceof \Throwable ? $reason : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\RejectionException($reason); +} +/** + * Returns an iterator for the given value. + * + * @param mixed $value + * + * @return \Iterator + */ +function iter_for($value) +{ + if ($value instanceof \Iterator) { + return $value; + } elseif (\is_array($value)) { + return new \ArrayIterator($value); + } else { + return new \ArrayIterator([$value]); + } +} +/** + * Synchronously waits on a promise to resolve and returns an inspection state + * array. + * + * Returns a state associative array containing a "state" key mapping to a + * valid promise state. If the state of the promise is "fulfilled", the array + * will contain a "value" key mapping to the fulfilled value of the promise. If + * the promise is rejected, the array will contain a "reason" key mapping to + * the rejection reason of the promise. + * + * @param PromiseInterface $promise Promise or value. + * + * @return array + */ +function inspect(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $promise) +{ + try { + return ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::FULFILLED, 'value' => $promise->wait()]; + } catch (\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\RejectionException $e) { + return ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $e->getReason()]; + } catch (\Throwable $e) { + return ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $e]; + } catch (\Exception $e) { + return ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $e]; + } +} +/** + * Waits on all of the provided promises, but does not unwrap rejected promises + * as thrown exception. + * + * Returns an array of inspection state arrays. + * + * @param PromiseInterface[] $promises Traversable of promises to wait upon. + * + * @return array + * @see GuzzleHttp\Promise\inspect for the inspection state array format. + */ +function inspect_all($promises) +{ + $results = []; + foreach ($promises as $key => $promise) { + $results[$key] = inspect($promise); + } + return $results; +} +/** + * Waits on all of the provided promises and returns the fulfilled values. + * + * Returns an array that contains the value of each promise (in the same order + * the promises were provided). An exception is thrown if any of the promises + * are rejected. + * + * @param mixed $promises Iterable of PromiseInterface objects to wait on. + * + * @return array + * @throws \Exception on error + * @throws \Throwable on error in PHP >=7 + */ +function unwrap($promises) +{ + $results = []; + foreach ($promises as $key => $promise) { + $results[$key] = $promise->wait(); + } + return $results; +} +/** + * Given an array of promises, return a promise that is fulfilled when all the + * items in the array are fulfilled. + * + * The promise's fulfillment value is an array with fulfillment values at + * respective positions to the original array. If any promise in the array + * rejects, the returned promise is rejected with the rejection reason. + * + * @param mixed $promises Promises or values. + * + * @return PromiseInterface + */ +function all($promises) +{ + $results = []; + return \each($promises, function ($value, $idx) use(&$results) { + $results[$idx] = $value; + }, function ($reason, $idx, \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Promise $aggregate) { + $aggregate->reject($reason); + })->then(function () use(&$results) { + \ksort($results); + return $results; + }); +} +/** + * Initiate a competitive race between multiple promises or values (values will + * become immediately fulfilled promises). + * + * When count amount of promises have been fulfilled, the returned promise is + * fulfilled with an array that contains the fulfillment values of the winners + * in order of resolution. + * + * This prommise is rejected with a {@see GuzzleHttp\Promise\AggregateException} + * if the number of fulfilled promises is less than the desired $count. + * + * @param int $count Total number of promises. + * @param mixed $promises Promises or values. + * + * @return PromiseInterface + */ +function some($count, $promises) +{ + $results = []; + $rejections = []; + return \each($promises, function ($value, $idx, \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $p) use(&$results, $count) { + if ($p->getState() !== \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::PENDING) { + return; + } + $results[$idx] = $value; + if (\count($results) >= $count) { + $p->resolve(null); + } + }, function ($reason) use(&$rejections) { + $rejections[] = $reason; + })->then(function () use(&$results, &$rejections, $count) { + if (\count($results) !== $count) { + throw new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\AggregateException('Not enough promises to fulfill count', $rejections); + } + \ksort($results); + return \array_values($results); + }); +} +/** + * Like some(), with 1 as count. However, if the promise fulfills, the + * fulfillment value is not an array of 1 but the value directly. + * + * @param mixed $promises Promises or values. + * + * @return PromiseInterface + */ +function any($promises) +{ + return some(1, $promises)->then(function ($values) { + return $values[0]; + }); +} +/** + * Returns a promise that is fulfilled when all of the provided promises have + * been fulfilled or rejected. + * + * The returned promise is fulfilled with an array of inspection state arrays. + * + * @param mixed $promises Promises or values. + * + * @return PromiseInterface + * @see GuzzleHttp\Promise\inspect for the inspection state array format. + */ +function settle($promises) +{ + $results = []; + return \each($promises, function ($value, $idx) use(&$results) { + $results[$idx] = ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::FULFILLED, 'value' => $value]; + }, function ($reason, $idx) use(&$results) { + $results[$idx] = ['state' => \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::REJECTED, 'reason' => $reason]; + })->then(function () use(&$results) { + \ksort($results); + return $results; + }); +} +/** + * Given an iterator that yields promises or values, returns a promise that is + * fulfilled with a null value when the iterator has been consumed or the + * aggregate promise has been fulfilled or rejected. + * + * $onFulfilled is a function that accepts the fulfilled value, iterator + * index, and the aggregate promise. The callback can invoke any necessary side + * effects and choose to resolve or reject the aggregate promise if needed. + * + * $onRejected is a function that accepts the rejection reason, iterator + * index, and the aggregate promise. The callback can invoke any necessary side + * effects and choose to resolve or reject the aggregate promise if needed. + * + * @param mixed $iterable Iterator or array to iterate over. + * @param callable $onFulfilled + * @param callable $onRejected + * + * @return PromiseInterface + */ +function each($iterable, callable $onFulfilled = null, callable $onRejected = null) +{ + return (new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\EachPromise($iterable, ['fulfilled' => $onFulfilled, 'rejected' => $onRejected]))->promise(); +} +/** + * Like each, but only allows a certain number of outstanding promises at any + * given time. + * + * $concurrency may be an integer or a function that accepts the number of + * pending promises and returns a numeric concurrency limit value to allow for + * dynamic a concurrency size. + * + * @param mixed $iterable + * @param int|callable $concurrency + * @param callable $onFulfilled + * @param callable $onRejected + * + * @return PromiseInterface + */ +function each_limit($iterable, $concurrency, callable $onFulfilled = null, callable $onRejected = null) +{ + return (new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\EachPromise($iterable, ['fulfilled' => $onFulfilled, 'rejected' => $onRejected, 'concurrency' => $concurrency]))->promise(); +} +/** + * Like each_limit, but ensures that no promise in the given $iterable argument + * is rejected. If any promise is rejected, then the aggregate promise is + * rejected with the encountered rejection. + * + * @param mixed $iterable + * @param int|callable $concurrency + * @param callable $onFulfilled + * + * @return PromiseInterface + */ +function each_limit_all($iterable, $concurrency, callable $onFulfilled = null) +{ + return each_limit($iterable, $concurrency, $onFulfilled, function ($reason, $idx, \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $aggregate) { + $aggregate->reject($reason); + }); +} +/** + * Returns true if a promise is fulfilled. + * + * @param PromiseInterface $promise + * + * @return bool + */ +function is_fulfilled(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $promise) +{ + return $promise->getState() === \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::FULFILLED; +} +/** + * Returns true if a promise is rejected. + * + * @param PromiseInterface $promise + * + * @return bool + */ +function is_rejected(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $promise) +{ + return $promise->getState() === \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::REJECTED; +} +/** + * Returns true if a promise is fulfilled or rejected. + * + * @param PromiseInterface $promise + * + * @return bool + */ +function is_settled(\_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface $promise) +{ + return $promise->getState() !== \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\PromiseInterface::PENDING; +} +/** + * @see Coroutine + * + * @param callable $generatorFn + * + * @return PromiseInterface + */ +function coroutine(callable $generatorFn) +{ + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Promise\Coroutine($generatorFn); +} diff --git a/vendor/guzzlehttp/promises/src/functions_include.php b/vendor/guzzlehttp/promises/src/functions_include.php index 7ec8d465b..07c071d4a 100644 --- a/vendor/guzzlehttp/promises/src/functions_include.php +++ b/vendor/guzzlehttp/promises/src/functions_include.php @@ -1,8 +1,8 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/psr7/CHANGELOG.md b/vendor/guzzlehttp/psr7/CHANGELOG.md index 8a3743dba..d8802026b 100644 --- a/vendor/guzzlehttp/psr7/CHANGELOG.md +++ b/vendor/guzzlehttp/psr7/CHANGELOG.md @@ -1,246 +1,246 @@ -# Change Log - - -All notable changes to this project will be documented in this file. - -The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) -and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). - - -## [Unreleased] - - -## [1.6.0] - -### Added - -- Allowed version `^3.0` of `ralouphie/getallheaders` dependency (#244) -- Added MIME type for WEBP image format (#246) -- Added more validation of values according to PSR-7 and RFC standards, e.g. status code range (#250, #272) - -### Changed - -- Tests don't pass with HHVM 4.0, so HHVM support got dropped. Other libraries like composer have done the same. (#262) -- Accept port number 0 to be valid (#270) - -### Fixed - -- Fixed subsequent reads from `php://input` in ServerRequest (#247) -- Fixed readable/writable detection for certain stream modes (#248) -- Fixed encoding of special characters in the `userInfo` component of an URI (#253) - - -## [1.5.2] - 2018-12-04 - -### Fixed - -- Check body size when getting the message summary - - -## [1.5.1] - 2018-12-04 - -### Fixed - -- Get the summary of a body only if it is readable - - -## [1.5.0] - 2018-12-03 - -### Added - -- Response first-line to response string exception (fixes #145) -- A test for #129 behavior -- `get_message_body_summary` function in order to get the message summary -- `3gp` and `mkv` mime types - -### Changed - -- Clarify exception message when stream is detached - -### Deprecated - -- Deprecated parsing folded header lines as per RFC 7230 - -### Fixed - -- Fix `AppendStream::detach` to not close streams -- `InflateStream` preserves `isSeekable` attribute of the underlying stream -- `ServerRequest::getUriFromGlobals` to support URLs in query parameters - - -Several other fixes and improvements. - - -## [1.4.2] - 2017-03-20 - -### Fixed - -- Reverted BC break to `Uri::resolve` and `Uri::removeDotSegments` by removing - calls to `trigger_error` when deprecated methods are invoked. - - -## [1.4.1] - 2017-02-27 - -### Added - -- Rriggering of silenced deprecation warnings. - -### Fixed - -- Reverted BC break by reintroducing behavior to automagically fix a URI with a - relative path and an authority by adding a leading slash to the path. It's only - deprecated now. - - -## [1.4.0] - 2017-02-21 - -### Added - -- Added common URI utility methods based on RFC 3986 (see documentation in the readme): - - `Uri::isDefaultPort` - - `Uri::isAbsolute` - - `Uri::isNetworkPathReference` - - `Uri::isAbsolutePathReference` - - `Uri::isRelativePathReference` - - `Uri::isSameDocumentReference` - - `Uri::composeComponents` - - `UriNormalizer::normalize` - - `UriNormalizer::isEquivalent` - - `UriResolver::relativize` - -### Changed - -- Ensure `ServerRequest::getUriFromGlobals` returns a URI in absolute form. -- Allow `parse_response` to parse a response without delimiting space and reason. -- Ensure each URI modification results in a valid URI according to PSR-7 discussions. - Invalid modifications will throw an exception instead of returning a wrong URI or - doing some magic. - - `(new Uri)->withPath('foo')->withHost('example.com')` will throw an exception - because the path of a URI with an authority must start with a slash "/" or be empty - - `(new Uri())->withScheme('http')` will return `'http://localhost'` - -### Deprecated - -- `Uri::resolve` in favor of `UriResolver::resolve` -- `Uri::removeDotSegments` in favor of `UriResolver::removeDotSegments` - -### Fixed - -- `Stream::read` when length parameter <= 0. -- `copy_to_stream` reads bytes in chunks instead of `maxLen` into memory. -- `ServerRequest::getUriFromGlobals` when `Host` header contains port. -- Compatibility of URIs with `file` scheme and empty host. - - -## [1.3.1] - 2016-06-25 - -### Fixed - -- `Uri::__toString` for network path references, e.g. `//example.org`. -- Missing lowercase normalization for host. -- Handling of URI components in case they are `'0'` in a lot of places, - e.g. as a user info password. -- `Uri::withAddedHeader` to correctly merge headers with different case. -- Trimming of header values in `Uri::withAddedHeader`. Header values may - be surrounded by whitespace which should be ignored according to RFC 7230 - Section 3.2.4. This does not apply to header names. -- `Uri::withAddedHeader` with an array of header values. -- `Uri::resolve` when base path has no slash and handling of fragment. -- Handling of encoding in `Uri::with(out)QueryValue` so one can pass the - key/value both in encoded as well as decoded form to those methods. This is - consistent with withPath, withQuery etc. -- `ServerRequest::withoutAttribute` when attribute value is null. - - -## [1.3.0] - 2016-04-13 - -### Added - -- Remaining interfaces needed for full PSR7 compatibility - (ServerRequestInterface, UploadedFileInterface, etc.). -- Support for stream_for from scalars. - -### Changed - -- Can now extend Uri. - -### Fixed -- A bug in validating request methods by making it more permissive. - - -## [1.2.3] - 2016-02-18 - -### Fixed - -- Support in `GuzzleHttp\Psr7\CachingStream` for seeking forward on remote - streams, which can sometimes return fewer bytes than requested with `fread`. -- Handling of gzipped responses with FNAME headers. - - -## [1.2.2] - 2016-01-22 - -### Added - -- Support for URIs without any authority. -- Support for HTTP 451 'Unavailable For Legal Reasons.' -- Support for using '0' as a filename. -- Support for including non-standard ports in Host headers. - - -## [1.2.1] - 2015-11-02 - -### Changes - -- Now supporting negative offsets when seeking to SEEK_END. - - -## [1.2.0] - 2015-08-15 - -### Changed - -- Body as `"0"` is now properly added to a response. -- Now allowing forward seeking in CachingStream. -- Now properly parsing HTTP requests that contain proxy targets in - `parse_request`. -- functions.php is now conditionally required. -- user-info is no longer dropped when resolving URIs. - - -## [1.1.0] - 2015-06-24 - -### Changed - -- URIs can now be relative. -- `multipart/form-data` headers are now overridden case-insensitively. -- URI paths no longer encode the following characters because they are allowed - in URIs: "(", ")", "*", "!", "'" -- A port is no longer added to a URI when the scheme is missing and no port is - present. - - -## 1.0.0 - 2015-05-19 - -Initial release. - -Currently unsupported: - -- `Psr\Http\Message\ServerRequestInterface` -- `Psr\Http\Message\UploadedFileInterface` - - - -[Unreleased]: https://github.com/guzzle/psr7/compare/1.6.0...HEAD -[1.6.0]: https://github.com/guzzle/psr7/compare/1.5.2...1.6.0 -[1.5.2]: https://github.com/guzzle/psr7/compare/1.5.1...1.5.2 -[1.5.1]: https://github.com/guzzle/psr7/compare/1.5.0...1.5.1 -[1.5.0]: https://github.com/guzzle/psr7/compare/1.4.2...1.5.0 -[1.4.2]: https://github.com/guzzle/psr7/compare/1.4.1...1.4.2 -[1.4.1]: https://github.com/guzzle/psr7/compare/1.4.0...1.4.1 -[1.4.0]: https://github.com/guzzle/psr7/compare/1.3.1...1.4.0 -[1.3.1]: https://github.com/guzzle/psr7/compare/1.3.0...1.3.1 -[1.3.0]: https://github.com/guzzle/psr7/compare/1.2.3...1.3.0 -[1.2.3]: https://github.com/guzzle/psr7/compare/1.2.2...1.2.3 -[1.2.2]: https://github.com/guzzle/psr7/compare/1.2.1...1.2.2 -[1.2.1]: https://github.com/guzzle/psr7/compare/1.2.0...1.2.1 -[1.2.0]: https://github.com/guzzle/psr7/compare/1.1.0...1.2.0 -[1.1.0]: https://github.com/guzzle/psr7/compare/1.0.0...1.1.0 +# Change Log + + +All notable changes to this project will be documented in this file. + +The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) +and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). + + +## [Unreleased] + + +## [1.6.0] + +### Added + +- Allowed version `^3.0` of `ralouphie/getallheaders` dependency (#244) +- Added MIME type for WEBP image format (#246) +- Added more validation of values according to PSR-7 and RFC standards, e.g. status code range (#250, #272) + +### Changed + +- Tests don't pass with HHVM 4.0, so HHVM support got dropped. Other libraries like composer have done the same. (#262) +- Accept port number 0 to be valid (#270) + +### Fixed + +- Fixed subsequent reads from `php://input` in ServerRequest (#247) +- Fixed readable/writable detection for certain stream modes (#248) +- Fixed encoding of special characters in the `userInfo` component of an URI (#253) + + +## [1.5.2] - 2018-12-04 + +### Fixed + +- Check body size when getting the message summary + + +## [1.5.1] - 2018-12-04 + +### Fixed + +- Get the summary of a body only if it is readable + + +## [1.5.0] - 2018-12-03 + +### Added + +- Response first-line to response string exception (fixes #145) +- A test for #129 behavior +- `get_message_body_summary` function in order to get the message summary +- `3gp` and `mkv` mime types + +### Changed + +- Clarify exception message when stream is detached + +### Deprecated + +- Deprecated parsing folded header lines as per RFC 7230 + +### Fixed + +- Fix `AppendStream::detach` to not close streams +- `InflateStream` preserves `isSeekable` attribute of the underlying stream +- `ServerRequest::getUriFromGlobals` to support URLs in query parameters + + +Several other fixes and improvements. + + +## [1.4.2] - 2017-03-20 + +### Fixed + +- Reverted BC break to `Uri::resolve` and `Uri::removeDotSegments` by removing + calls to `trigger_error` when deprecated methods are invoked. + + +## [1.4.1] - 2017-02-27 + +### Added + +- Rriggering of silenced deprecation warnings. + +### Fixed + +- Reverted BC break by reintroducing behavior to automagically fix a URI with a + relative path and an authority by adding a leading slash to the path. It's only + deprecated now. + + +## [1.4.0] - 2017-02-21 + +### Added + +- Added common URI utility methods based on RFC 3986 (see documentation in the readme): + - `Uri::isDefaultPort` + - `Uri::isAbsolute` + - `Uri::isNetworkPathReference` + - `Uri::isAbsolutePathReference` + - `Uri::isRelativePathReference` + - `Uri::isSameDocumentReference` + - `Uri::composeComponents` + - `UriNormalizer::normalize` + - `UriNormalizer::isEquivalent` + - `UriResolver::relativize` + +### Changed + +- Ensure `ServerRequest::getUriFromGlobals` returns a URI in absolute form. +- Allow `parse_response` to parse a response without delimiting space and reason. +- Ensure each URI modification results in a valid URI according to PSR-7 discussions. + Invalid modifications will throw an exception instead of returning a wrong URI or + doing some magic. + - `(new Uri)->withPath('foo')->withHost('example.com')` will throw an exception + because the path of a URI with an authority must start with a slash "/" or be empty + - `(new Uri())->withScheme('http')` will return `'http://localhost'` + +### Deprecated + +- `Uri::resolve` in favor of `UriResolver::resolve` +- `Uri::removeDotSegments` in favor of `UriResolver::removeDotSegments` + +### Fixed + +- `Stream::read` when length parameter <= 0. +- `copy_to_stream` reads bytes in chunks instead of `maxLen` into memory. +- `ServerRequest::getUriFromGlobals` when `Host` header contains port. +- Compatibility of URIs with `file` scheme and empty host. + + +## [1.3.1] - 2016-06-25 + +### Fixed + +- `Uri::__toString` for network path references, e.g. `//example.org`. +- Missing lowercase normalization for host. +- Handling of URI components in case they are `'0'` in a lot of places, + e.g. as a user info password. +- `Uri::withAddedHeader` to correctly merge headers with different case. +- Trimming of header values in `Uri::withAddedHeader`. Header values may + be surrounded by whitespace which should be ignored according to RFC 7230 + Section 3.2.4. This does not apply to header names. +- `Uri::withAddedHeader` with an array of header values. +- `Uri::resolve` when base path has no slash and handling of fragment. +- Handling of encoding in `Uri::with(out)QueryValue` so one can pass the + key/value both in encoded as well as decoded form to those methods. This is + consistent with withPath, withQuery etc. +- `ServerRequest::withoutAttribute` when attribute value is null. + + +## [1.3.0] - 2016-04-13 + +### Added + +- Remaining interfaces needed for full PSR7 compatibility + (ServerRequestInterface, UploadedFileInterface, etc.). +- Support for stream_for from scalars. + +### Changed + +- Can now extend Uri. + +### Fixed +- A bug in validating request methods by making it more permissive. + + +## [1.2.3] - 2016-02-18 + +### Fixed + +- Support in `GuzzleHttp\Psr7\CachingStream` for seeking forward on remote + streams, which can sometimes return fewer bytes than requested with `fread`. +- Handling of gzipped responses with FNAME headers. + + +## [1.2.2] - 2016-01-22 + +### Added + +- Support for URIs without any authority. +- Support for HTTP 451 'Unavailable For Legal Reasons.' +- Support for using '0' as a filename. +- Support for including non-standard ports in Host headers. + + +## [1.2.1] - 2015-11-02 + +### Changes + +- Now supporting negative offsets when seeking to SEEK_END. + + +## [1.2.0] - 2015-08-15 + +### Changed + +- Body as `"0"` is now properly added to a response. +- Now allowing forward seeking in CachingStream. +- Now properly parsing HTTP requests that contain proxy targets in + `parse_request`. +- functions.php is now conditionally required. +- user-info is no longer dropped when resolving URIs. + + +## [1.1.0] - 2015-06-24 + +### Changed + +- URIs can now be relative. +- `multipart/form-data` headers are now overridden case-insensitively. +- URI paths no longer encode the following characters because they are allowed + in URIs: "(", ")", "*", "!", "'" +- A port is no longer added to a URI when the scheme is missing and no port is + present. + + +## 1.0.0 - 2015-05-19 + +Initial release. + +Currently unsupported: + +- `Psr\Http\Message\ServerRequestInterface` +- `Psr\Http\Message\UploadedFileInterface` + + + +[Unreleased]: https://github.com/guzzle/psr7/compare/1.6.0...HEAD +[1.6.0]: https://github.com/guzzle/psr7/compare/1.5.2...1.6.0 +[1.5.2]: https://github.com/guzzle/psr7/compare/1.5.1...1.5.2 +[1.5.1]: https://github.com/guzzle/psr7/compare/1.5.0...1.5.1 +[1.5.0]: https://github.com/guzzle/psr7/compare/1.4.2...1.5.0 +[1.4.2]: https://github.com/guzzle/psr7/compare/1.4.1...1.4.2 +[1.4.1]: https://github.com/guzzle/psr7/compare/1.4.0...1.4.1 +[1.4.0]: https://github.com/guzzle/psr7/compare/1.3.1...1.4.0 +[1.3.1]: https://github.com/guzzle/psr7/compare/1.3.0...1.3.1 +[1.3.0]: https://github.com/guzzle/psr7/compare/1.2.3...1.3.0 +[1.2.3]: https://github.com/guzzle/psr7/compare/1.2.2...1.2.3 +[1.2.2]: https://github.com/guzzle/psr7/compare/1.2.1...1.2.2 +[1.2.1]: https://github.com/guzzle/psr7/compare/1.2.0...1.2.1 +[1.2.0]: https://github.com/guzzle/psr7/compare/1.1.0...1.2.0 +[1.1.0]: https://github.com/guzzle/psr7/compare/1.0.0...1.1.0 diff --git a/vendor/guzzlehttp/psr7/LICENSE b/vendor/guzzlehttp/psr7/LICENSE index 581d95f92..9d3d488dd 100644 --- a/vendor/guzzlehttp/psr7/LICENSE +++ b/vendor/guzzlehttp/psr7/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2015 Michael Dowling, https://github.com/mtdowling - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2015 Michael Dowling, https://github.com/mtdowling + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/guzzlehttp/psr7/README.md b/vendor/guzzlehttp/psr7/README.md index c60a6a38d..ec7cc30f0 100644 --- a/vendor/guzzlehttp/psr7/README.md +++ b/vendor/guzzlehttp/psr7/README.md @@ -1,745 +1,745 @@ -# PSR-7 Message Implementation - -This repository contains a full [PSR-7](http://www.php-fig.org/psr/psr-7/) -message implementation, several stream decorators, and some helpful -functionality like query string parsing. - - -[![Build Status](https://travis-ci.org/guzzle/psr7.svg?branch=master)](https://travis-ci.org/guzzle/psr7) - - -# Stream implementation - -This package comes with a number of stream implementations and stream -decorators. - - -## AppendStream - -`GuzzleHttp\Psr7\AppendStream` - -Reads from multiple streams, one after the other. - -```php -use GuzzleHttp\Psr7; - -$a = Psr7\stream_for('abc, '); -$b = Psr7\stream_for('123.'); -$composed = new Psr7\AppendStream([$a, $b]); - -$composed->addStream(Psr7\stream_for(' Above all listen to me')); - -echo $composed; // abc, 123. Above all listen to me. -``` - - -## BufferStream - -`GuzzleHttp\Psr7\BufferStream` - -Provides a buffer stream that can be written to fill a buffer, and read -from to remove bytes from the buffer. - -This stream returns a "hwm" metadata value that tells upstream consumers -what the configured high water mark of the stream is, or the maximum -preferred size of the buffer. - -```php -use GuzzleHttp\Psr7; - -// When more than 1024 bytes are in the buffer, it will begin returning -// false to writes. This is an indication that writers should slow down. -$buffer = new Psr7\BufferStream(1024); -``` - - -## CachingStream - -The CachingStream is used to allow seeking over previously read bytes on -non-seekable streams. This can be useful when transferring a non-seekable -entity body fails due to needing to rewind the stream (for example, resulting -from a redirect). Data that is read from the remote stream will be buffered in -a PHP temp stream so that previously read bytes are cached first in memory, -then on disk. - -```php -use GuzzleHttp\Psr7; - -$original = Psr7\stream_for(fopen('http://www.google.com', 'r')); -$stream = new Psr7\CachingStream($original); - -$stream->read(1024); -echo $stream->tell(); -// 1024 - -$stream->seek(0); -echo $stream->tell(); -// 0 -``` - - -## DroppingStream - -`GuzzleHttp\Psr7\DroppingStream` - -Stream decorator that begins dropping data once the size of the underlying -stream becomes too full. - -```php -use GuzzleHttp\Psr7; - -// Create an empty stream -$stream = Psr7\stream_for(); - -// Start dropping data when the stream has more than 10 bytes -$dropping = new Psr7\DroppingStream($stream, 10); - -$dropping->write('01234567890123456789'); -echo $stream; // 0123456789 -``` - - -## FnStream - -`GuzzleHttp\Psr7\FnStream` - -Compose stream implementations based on a hash of functions. - -Allows for easy testing and extension of a provided stream without needing -to create a concrete class for a simple extension point. - -```php - -use GuzzleHttp\Psr7; - -$stream = Psr7\stream_for('hi'); -$fnStream = Psr7\FnStream::decorate($stream, [ - 'rewind' => function () use ($stream) { - echo 'About to rewind - '; - $stream->rewind(); - echo 'rewound!'; - } -]); - -$fnStream->rewind(); -// Outputs: About to rewind - rewound! -``` - - -## InflateStream - -`GuzzleHttp\Psr7\InflateStream` - -Uses PHP's zlib.inflate filter to inflate deflate or gzipped content. - -This stream decorator skips the first 10 bytes of the given stream to remove -the gzip header, converts the provided stream to a PHP stream resource, -then appends the zlib.inflate filter. The stream is then converted back -to a Guzzle stream resource to be used as a Guzzle stream. - - -## LazyOpenStream - -`GuzzleHttp\Psr7\LazyOpenStream` - -Lazily reads or writes to a file that is opened only after an IO operation -take place on the stream. - -```php -use GuzzleHttp\Psr7; - -$stream = new Psr7\LazyOpenStream('/path/to/file', 'r'); -// The file has not yet been opened... - -echo $stream->read(10); -// The file is opened and read from only when needed. -``` - - -## LimitStream - -`GuzzleHttp\Psr7\LimitStream` - -LimitStream can be used to read a subset or slice of an existing stream object. -This can be useful for breaking a large file into smaller pieces to be sent in -chunks (e.g. Amazon S3's multipart upload API). - -```php -use GuzzleHttp\Psr7; - -$original = Psr7\stream_for(fopen('/tmp/test.txt', 'r+')); -echo $original->getSize(); -// >>> 1048576 - -// Limit the size of the body to 1024 bytes and start reading from byte 2048 -$stream = new Psr7\LimitStream($original, 1024, 2048); -echo $stream->getSize(); -// >>> 1024 -echo $stream->tell(); -// >>> 0 -``` - - -## MultipartStream - -`GuzzleHttp\Psr7\MultipartStream` - -Stream that when read returns bytes for a streaming multipart or -multipart/form-data stream. - - -## NoSeekStream - -`GuzzleHttp\Psr7\NoSeekStream` - -NoSeekStream wraps a stream and does not allow seeking. - -```php -use GuzzleHttp\Psr7; - -$original = Psr7\stream_for('foo'); -$noSeek = new Psr7\NoSeekStream($original); - -echo $noSeek->read(3); -// foo -var_export($noSeek->isSeekable()); -// false -$noSeek->seek(0); -var_export($noSeek->read(3)); -// NULL -``` - - -## PumpStream - -`GuzzleHttp\Psr7\PumpStream` - -Provides a read only stream that pumps data from a PHP callable. - -When invoking the provided callable, the PumpStream will pass the amount of -data requested to read to the callable. The callable can choose to ignore -this value and return fewer or more bytes than requested. Any extra data -returned by the provided callable is buffered internally until drained using -the read() function of the PumpStream. The provided callable MUST return -false when there is no more data to read. - - -## Implementing stream decorators - -Creating a stream decorator is very easy thanks to the -`GuzzleHttp\Psr7\StreamDecoratorTrait`. This trait provides methods that -implement `Psr\Http\Message\StreamInterface` by proxying to an underlying -stream. Just `use` the `StreamDecoratorTrait` and implement your custom -methods. - -For example, let's say we wanted to call a specific function each time the last -byte is read from a stream. This could be implemented by overriding the -`read()` method. - -```php -use Psr\Http\Message\StreamInterface; -use GuzzleHttp\Psr7\StreamDecoratorTrait; - -class EofCallbackStream implements StreamInterface -{ - use StreamDecoratorTrait; - - private $callback; - - public function __construct(StreamInterface $stream, callable $cb) - { - $this->stream = $stream; - $this->callback = $cb; - } - - public function read($length) - { - $result = $this->stream->read($length); - - // Invoke the callback when EOF is hit. - if ($this->eof()) { - call_user_func($this->callback); - } - - return $result; - } -} -``` - -This decorator could be added to any existing stream and used like so: - -```php -use GuzzleHttp\Psr7; - -$original = Psr7\stream_for('foo'); - -$eofStream = new EofCallbackStream($original, function () { - echo 'EOF!'; -}); - -$eofStream->read(2); -$eofStream->read(1); -// echoes "EOF!" -$eofStream->seek(0); -$eofStream->read(3); -// echoes "EOF!" -``` - - -## PHP StreamWrapper - -You can use the `GuzzleHttp\Psr7\StreamWrapper` class if you need to use a -PSR-7 stream as a PHP stream resource. - -Use the `GuzzleHttp\Psr7\StreamWrapper::getResource()` method to create a PHP -stream from a PSR-7 stream. - -```php -use GuzzleHttp\Psr7\StreamWrapper; - -$stream = GuzzleHttp\Psr7\stream_for('hello!'); -$resource = StreamWrapper::getResource($stream); -echo fread($resource, 6); // outputs hello! -``` - - -# Function API - -There are various functions available under the `GuzzleHttp\Psr7` namespace. - - -## `function str` - -`function str(MessageInterface $message)` - -Returns the string representation of an HTTP message. - -```php -$request = new GuzzleHttp\Psr7\Request('GET', 'http://example.com'); -echo GuzzleHttp\Psr7\str($request); -``` - - -## `function uri_for` - -`function uri_for($uri)` - -This function accepts a string or `Psr\Http\Message\UriInterface` and returns a -UriInterface for the given value. If the value is already a `UriInterface`, it -is returned as-is. - -```php -$uri = GuzzleHttp\Psr7\uri_for('http://example.com'); -assert($uri === GuzzleHttp\Psr7\uri_for($uri)); -``` - - -## `function stream_for` - -`function stream_for($resource = '', array $options = [])` - -Create a new stream based on the input type. - -Options is an associative array that can contain the following keys: - -* - metadata: Array of custom metadata. -* - size: Size of the stream. - -This method accepts the following `$resource` types: - -- `Psr\Http\Message\StreamInterface`: Returns the value as-is. -- `string`: Creates a stream object that uses the given string as the contents. -- `resource`: Creates a stream object that wraps the given PHP stream resource. -- `Iterator`: If the provided value implements `Iterator`, then a read-only - stream object will be created that wraps the given iterable. Each time the - stream is read from, data from the iterator will fill a buffer and will be - continuously called until the buffer is equal to the requested read size. - Subsequent read calls will first read from the buffer and then call `next` - on the underlying iterator until it is exhausted. -- `object` with `__toString()`: If the object has the `__toString()` method, - the object will be cast to a string and then a stream will be returned that - uses the string value. -- `NULL`: When `null` is passed, an empty stream object is returned. -- `callable` When a callable is passed, a read-only stream object will be - created that invokes the given callable. The callable is invoked with the - number of suggested bytes to read. The callable can return any number of - bytes, but MUST return `false` when there is no more data to return. The - stream object that wraps the callable will invoke the callable until the - number of requested bytes are available. Any additional bytes will be - buffered and used in subsequent reads. - -```php -$stream = GuzzleHttp\Psr7\stream_for('foo'); -$stream = GuzzleHttp\Psr7\stream_for(fopen('/path/to/file', 'r')); - -$generator = function ($bytes) { - for ($i = 0; $i < $bytes; $i++) { - yield ' '; - } -} - -$stream = GuzzleHttp\Psr7\stream_for($generator(100)); -``` - - -## `function parse_header` - -`function parse_header($header)` - -Parse an array of header values containing ";" separated data into an array of -associative arrays representing the header key value pair data of the header. -When a parameter does not contain a value, but just contains a key, this -function will inject a key with a '' string value. - - -## `function normalize_header` - -`function normalize_header($header)` - -Converts an array of header values that may contain comma separated headers -into an array of headers with no comma separated values. - - -## `function modify_request` - -`function modify_request(RequestInterface $request, array $changes)` - -Clone and modify a request with the given changes. This method is useful for -reducing the number of clones needed to mutate a message. - -The changes can be one of: - -- method: (string) Changes the HTTP method. -- set_headers: (array) Sets the given headers. -- remove_headers: (array) Remove the given headers. -- body: (mixed) Sets the given body. -- uri: (UriInterface) Set the URI. -- query: (string) Set the query string value of the URI. -- version: (string) Set the protocol version. - - -## `function rewind_body` - -`function rewind_body(MessageInterface $message)` - -Attempts to rewind a message body and throws an exception on failure. The body -of the message will only be rewound if a call to `tell()` returns a value other -than `0`. - - -## `function try_fopen` - -`function try_fopen($filename, $mode)` - -Safely opens a PHP stream resource using a filename. - -When fopen fails, PHP normally raises a warning. This function adds an error -handler that checks for errors and throws an exception instead. - - -## `function copy_to_string` - -`function copy_to_string(StreamInterface $stream, $maxLen = -1)` - -Copy the contents of a stream into a string until the given number of bytes -have been read. - - -## `function copy_to_stream` - -`function copy_to_stream(StreamInterface $source, StreamInterface $dest, $maxLen = -1)` - -Copy the contents of a stream into another stream until the given number of -bytes have been read. - - -## `function hash` - -`function hash(StreamInterface $stream, $algo, $rawOutput = false)` - -Calculate a hash of a Stream. This method reads the entire stream to calculate -a rolling hash (based on PHP's hash_init functions). - - -## `function readline` - -`function readline(StreamInterface $stream, $maxLength = null)` - -Read a line from the stream up to the maximum allowed buffer length. - - -## `function parse_request` - -`function parse_request($message)` - -Parses a request message string into a request object. - - -## `function parse_response` - -`function parse_response($message)` - -Parses a response message string into a response object. - - -## `function parse_query` - -`function parse_query($str, $urlEncoding = true)` - -Parse a query string into an associative array. - -If multiple values are found for the same key, the value of that key value pair -will become an array. This function does not parse nested PHP style arrays into -an associative array (e.g., `foo[a]=1&foo[b]=2` will be parsed into -`['foo[a]' => '1', 'foo[b]' => '2']`). - - -## `function build_query` - -`function build_query(array $params, $encoding = PHP_QUERY_RFC3986)` - -Build a query string from an array of key value pairs. - -This function can use the return value of parse_query() to build a query string. -This function does not modify the provided keys when an array is encountered -(like http_build_query would). - - -## `function mimetype_from_filename` - -`function mimetype_from_filename($filename)` - -Determines the mimetype of a file by looking at its extension. - - -## `function mimetype_from_extension` - -`function mimetype_from_extension($extension)` - -Maps a file extensions to a mimetype. - - -# Additional URI Methods - -Aside from the standard `Psr\Http\Message\UriInterface` implementation in form of the `GuzzleHttp\Psr7\Uri` class, -this library also provides additional functionality when working with URIs as static methods. - -## URI Types - -An instance of `Psr\Http\Message\UriInterface` can either be an absolute URI or a relative reference. -An absolute URI has a scheme. A relative reference is used to express a URI relative to another URI, -the base URI. Relative references can be divided into several forms according to -[RFC 3986 Section 4.2](https://tools.ietf.org/html/rfc3986#section-4.2): - -- network-path references, e.g. `//example.com/path` -- absolute-path references, e.g. `/path` -- relative-path references, e.g. `subpath` - -The following methods can be used to identify the type of the URI. - -### `GuzzleHttp\Psr7\Uri::isAbsolute` - -`public static function isAbsolute(UriInterface $uri): bool` - -Whether the URI is absolute, i.e. it has a scheme. - -### `GuzzleHttp\Psr7\Uri::isNetworkPathReference` - -`public static function isNetworkPathReference(UriInterface $uri): bool` - -Whether the URI is a network-path reference. A relative reference that begins with two slash characters is -termed an network-path reference. - -### `GuzzleHttp\Psr7\Uri::isAbsolutePathReference` - -`public static function isAbsolutePathReference(UriInterface $uri): bool` - -Whether the URI is a absolute-path reference. A relative reference that begins with a single slash character is -termed an absolute-path reference. - -### `GuzzleHttp\Psr7\Uri::isRelativePathReference` - -`public static function isRelativePathReference(UriInterface $uri): bool` - -Whether the URI is a relative-path reference. A relative reference that does not begin with a slash character is -termed a relative-path reference. - -### `GuzzleHttp\Psr7\Uri::isSameDocumentReference` - -`public static function isSameDocumentReference(UriInterface $uri, UriInterface $base = null): bool` - -Whether the URI is a same-document reference. A same-document reference refers to a URI that is, aside from its -fragment component, identical to the base URI. When no base URI is given, only an empty URI reference -(apart from its fragment) is considered a same-document reference. - -## URI Components - -Additional methods to work with URI components. - -### `GuzzleHttp\Psr7\Uri::isDefaultPort` - -`public static function isDefaultPort(UriInterface $uri): bool` - -Whether the URI has the default port of the current scheme. `Psr\Http\Message\UriInterface::getPort` may return null -or the standard port. This method can be used independently of the implementation. - -### `GuzzleHttp\Psr7\Uri::composeComponents` - -`public static function composeComponents($scheme, $authority, $path, $query, $fragment): string` - -Composes a URI reference string from its various components according to -[RFC 3986 Section 5.3](https://tools.ietf.org/html/rfc3986#section-5.3). Usually this method does not need to be called -manually but instead is used indirectly via `Psr\Http\Message\UriInterface::__toString`. - -### `GuzzleHttp\Psr7\Uri::fromParts` - -`public static function fromParts(array $parts): UriInterface` - -Creates a URI from a hash of [`parse_url`](http://php.net/manual/en/function.parse-url.php) components. - - -### `GuzzleHttp\Psr7\Uri::withQueryValue` - -`public static function withQueryValue(UriInterface $uri, $key, $value): UriInterface` - -Creates a new URI with a specific query string value. Any existing query string values that exactly match the -provided key are removed and replaced with the given key value pair. A value of null will set the query string -key without a value, e.g. "key" instead of "key=value". - -### `GuzzleHttp\Psr7\Uri::withQueryValues` - -`public static function withQueryValues(UriInterface $uri, array $keyValueArray): UriInterface` - -Creates a new URI with multiple query string values. It has the same behavior as `withQueryValue()` but for an -associative array of key => value. - -### `GuzzleHttp\Psr7\Uri::withoutQueryValue` - -`public static function withoutQueryValue(UriInterface $uri, $key): UriInterface` - -Creates a new URI with a specific query string value removed. Any existing query string values that exactly match the -provided key are removed. - -## Reference Resolution - -`GuzzleHttp\Psr7\UriResolver` provides methods to resolve a URI reference in the context of a base URI according -to [RFC 3986 Section 5](https://tools.ietf.org/html/rfc3986#section-5). This is for example also what web browsers -do when resolving a link in a website based on the current request URI. - -### `GuzzleHttp\Psr7\UriResolver::resolve` - -`public static function resolve(UriInterface $base, UriInterface $rel): UriInterface` - -Converts the relative URI into a new URI that is resolved against the base URI. - -### `GuzzleHttp\Psr7\UriResolver::removeDotSegments` - -`public static function removeDotSegments(string $path): string` - -Removes dot segments from a path and returns the new path according to -[RFC 3986 Section 5.2.4](https://tools.ietf.org/html/rfc3986#section-5.2.4). - -### `GuzzleHttp\Psr7\UriResolver::relativize` - -`public static function relativize(UriInterface $base, UriInterface $target): UriInterface` - -Returns the target URI as a relative reference from the base URI. This method is the counterpart to resolve(): - -```php -(string) $target === (string) UriResolver::resolve($base, UriResolver::relativize($base, $target)) -``` - -One use-case is to use the current request URI as base URI and then generate relative links in your documents -to reduce the document size or offer self-contained downloadable document archives. - -```php -$base = new Uri('http://example.com/a/b/'); -echo UriResolver::relativize($base, new Uri('http://example.com/a/b/c')); // prints 'c'. -echo UriResolver::relativize($base, new Uri('http://example.com/a/x/y')); // prints '../x/y'. -echo UriResolver::relativize($base, new Uri('http://example.com/a/b/?q')); // prints '?q'. -echo UriResolver::relativize($base, new Uri('http://example.org/a/b/')); // prints '//example.org/a/b/'. -``` - -## Normalization and Comparison - -`GuzzleHttp\Psr7\UriNormalizer` provides methods to normalize and compare URIs according to -[RFC 3986 Section 6](https://tools.ietf.org/html/rfc3986#section-6). - -### `GuzzleHttp\Psr7\UriNormalizer::normalize` - -`public static function normalize(UriInterface $uri, $flags = self::PRESERVING_NORMALIZATIONS): UriInterface` - -Returns a normalized URI. The scheme and host component are already normalized to lowercase per PSR-7 UriInterface. -This methods adds additional normalizations that can be configured with the `$flags` parameter which is a bitmask -of normalizations to apply. The following normalizations are available: - -- `UriNormalizer::PRESERVING_NORMALIZATIONS` - - Default normalizations which only include the ones that preserve semantics. - -- `UriNormalizer::CAPITALIZE_PERCENT_ENCODING` - - All letters within a percent-encoding triplet (e.g., "%3A") are case-insensitive, and should be capitalized. - - Example: `http://example.org/a%c2%b1b` → `http://example.org/a%C2%B1b` - -- `UriNormalizer::DECODE_UNRESERVED_CHARACTERS` - - Decodes percent-encoded octets of unreserved characters. For consistency, percent-encoded octets in the ranges of - ALPHA (%41–%5A and %61–%7A), DIGIT (%30–%39), hyphen (%2D), period (%2E), underscore (%5F), or tilde (%7E) should - not be created by URI producers and, when found in a URI, should be decoded to their corresponding unreserved - characters by URI normalizers. - - Example: `http://example.org/%7Eusern%61me/` → `http://example.org/~username/` - -- `UriNormalizer::CONVERT_EMPTY_PATH` - - Converts the empty path to "/" for http and https URIs. - - Example: `http://example.org` → `http://example.org/` - -- `UriNormalizer::REMOVE_DEFAULT_HOST` - - Removes the default host of the given URI scheme from the URI. Only the "file" scheme defines the default host - "localhost". All of `file:/myfile`, `file:///myfile`, and `file://localhost/myfile` are equivalent according to - RFC 3986. - - Example: `file://localhost/myfile` → `file:///myfile` - -- `UriNormalizer::REMOVE_DEFAULT_PORT` - - Removes the default port of the given URI scheme from the URI. - - Example: `http://example.org:80/` → `http://example.org/` - -- `UriNormalizer::REMOVE_DOT_SEGMENTS` - - Removes unnecessary dot-segments. Dot-segments in relative-path references are not removed as it would - change the semantics of the URI reference. - - Example: `http://example.org/../a/b/../c/./d.html` → `http://example.org/a/c/d.html` - -- `UriNormalizer::REMOVE_DUPLICATE_SLASHES` - - Paths which include two or more adjacent slashes are converted to one. Webservers usually ignore duplicate slashes - and treat those URIs equivalent. But in theory those URIs do not need to be equivalent. So this normalization - may change the semantics. Encoded slashes (%2F) are not removed. - - Example: `http://example.org//foo///bar.html` → `http://example.org/foo/bar.html` - -- `UriNormalizer::SORT_QUERY_PARAMETERS` - - Sort query parameters with their values in alphabetical order. However, the order of parameters in a URI may be - significant (this is not defined by the standard). So this normalization is not safe and may change the semantics - of the URI. - - Example: `?lang=en&article=fred` → `?article=fred&lang=en` - -### `GuzzleHttp\Psr7\UriNormalizer::isEquivalent` - -`public static function isEquivalent(UriInterface $uri1, UriInterface $uri2, $normalizations = self::PRESERVING_NORMALIZATIONS): bool` - -Whether two URIs can be considered equivalent. Both URIs are normalized automatically before comparison with the given -`$normalizations` bitmask. The method also accepts relative URI references and returns true when they are equivalent. -This of course assumes they will be resolved against the same base URI. If this is not the case, determination of -equivalence or difference of relative references does not mean anything. +# PSR-7 Message Implementation + +This repository contains a full [PSR-7](http://www.php-fig.org/psr/psr-7/) +message implementation, several stream decorators, and some helpful +functionality like query string parsing. + + +[![Build Status](https://travis-ci.org/guzzle/psr7.svg?branch=master)](https://travis-ci.org/guzzle/psr7) + + +# Stream implementation + +This package comes with a number of stream implementations and stream +decorators. + + +## AppendStream + +`GuzzleHttp\Psr7\AppendStream` + +Reads from multiple streams, one after the other. + +```php +use GuzzleHttp\Psr7; + +$a = Psr7\stream_for('abc, '); +$b = Psr7\stream_for('123.'); +$composed = new Psr7\AppendStream([$a, $b]); + +$composed->addStream(Psr7\stream_for(' Above all listen to me')); + +echo $composed; // abc, 123. Above all listen to me. +``` + + +## BufferStream + +`GuzzleHttp\Psr7\BufferStream` + +Provides a buffer stream that can be written to fill a buffer, and read +from to remove bytes from the buffer. + +This stream returns a "hwm" metadata value that tells upstream consumers +what the configured high water mark of the stream is, or the maximum +preferred size of the buffer. + +```php +use GuzzleHttp\Psr7; + +// When more than 1024 bytes are in the buffer, it will begin returning +// false to writes. This is an indication that writers should slow down. +$buffer = new Psr7\BufferStream(1024); +``` + + +## CachingStream + +The CachingStream is used to allow seeking over previously read bytes on +non-seekable streams. This can be useful when transferring a non-seekable +entity body fails due to needing to rewind the stream (for example, resulting +from a redirect). Data that is read from the remote stream will be buffered in +a PHP temp stream so that previously read bytes are cached first in memory, +then on disk. + +```php +use GuzzleHttp\Psr7; + +$original = Psr7\stream_for(fopen('http://www.google.com', 'r')); +$stream = new Psr7\CachingStream($original); + +$stream->read(1024); +echo $stream->tell(); +// 1024 + +$stream->seek(0); +echo $stream->tell(); +// 0 +``` + + +## DroppingStream + +`GuzzleHttp\Psr7\DroppingStream` + +Stream decorator that begins dropping data once the size of the underlying +stream becomes too full. + +```php +use GuzzleHttp\Psr7; + +// Create an empty stream +$stream = Psr7\stream_for(); + +// Start dropping data when the stream has more than 10 bytes +$dropping = new Psr7\DroppingStream($stream, 10); + +$dropping->write('01234567890123456789'); +echo $stream; // 0123456789 +``` + + +## FnStream + +`GuzzleHttp\Psr7\FnStream` + +Compose stream implementations based on a hash of functions. + +Allows for easy testing and extension of a provided stream without needing +to create a concrete class for a simple extension point. + +```php + +use GuzzleHttp\Psr7; + +$stream = Psr7\stream_for('hi'); +$fnStream = Psr7\FnStream::decorate($stream, [ + 'rewind' => function () use ($stream) { + echo 'About to rewind - '; + $stream->rewind(); + echo 'rewound!'; + } +]); + +$fnStream->rewind(); +// Outputs: About to rewind - rewound! +``` + + +## InflateStream + +`GuzzleHttp\Psr7\InflateStream` + +Uses PHP's zlib.inflate filter to inflate deflate or gzipped content. + +This stream decorator skips the first 10 bytes of the given stream to remove +the gzip header, converts the provided stream to a PHP stream resource, +then appends the zlib.inflate filter. The stream is then converted back +to a Guzzle stream resource to be used as a Guzzle stream. + + +## LazyOpenStream + +`GuzzleHttp\Psr7\LazyOpenStream` + +Lazily reads or writes to a file that is opened only after an IO operation +take place on the stream. + +```php +use GuzzleHttp\Psr7; + +$stream = new Psr7\LazyOpenStream('/path/to/file', 'r'); +// The file has not yet been opened... + +echo $stream->read(10); +// The file is opened and read from only when needed. +``` + + +## LimitStream + +`GuzzleHttp\Psr7\LimitStream` + +LimitStream can be used to read a subset or slice of an existing stream object. +This can be useful for breaking a large file into smaller pieces to be sent in +chunks (e.g. Amazon S3's multipart upload API). + +```php +use GuzzleHttp\Psr7; + +$original = Psr7\stream_for(fopen('/tmp/test.txt', 'r+')); +echo $original->getSize(); +// >>> 1048576 + +// Limit the size of the body to 1024 bytes and start reading from byte 2048 +$stream = new Psr7\LimitStream($original, 1024, 2048); +echo $stream->getSize(); +// >>> 1024 +echo $stream->tell(); +// >>> 0 +``` + + +## MultipartStream + +`GuzzleHttp\Psr7\MultipartStream` + +Stream that when read returns bytes for a streaming multipart or +multipart/form-data stream. + + +## NoSeekStream + +`GuzzleHttp\Psr7\NoSeekStream` + +NoSeekStream wraps a stream and does not allow seeking. + +```php +use GuzzleHttp\Psr7; + +$original = Psr7\stream_for('foo'); +$noSeek = new Psr7\NoSeekStream($original); + +echo $noSeek->read(3); +// foo +var_export($noSeek->isSeekable()); +// false +$noSeek->seek(0); +var_export($noSeek->read(3)); +// NULL +``` + + +## PumpStream + +`GuzzleHttp\Psr7\PumpStream` + +Provides a read only stream that pumps data from a PHP callable. + +When invoking the provided callable, the PumpStream will pass the amount of +data requested to read to the callable. The callable can choose to ignore +this value and return fewer or more bytes than requested. Any extra data +returned by the provided callable is buffered internally until drained using +the read() function of the PumpStream. The provided callable MUST return +false when there is no more data to read. + + +## Implementing stream decorators + +Creating a stream decorator is very easy thanks to the +`GuzzleHttp\Psr7\StreamDecoratorTrait`. This trait provides methods that +implement `Psr\Http\Message\StreamInterface` by proxying to an underlying +stream. Just `use` the `StreamDecoratorTrait` and implement your custom +methods. + +For example, let's say we wanted to call a specific function each time the last +byte is read from a stream. This could be implemented by overriding the +`read()` method. + +```php +use Psr\Http\Message\StreamInterface; +use GuzzleHttp\Psr7\StreamDecoratorTrait; + +class EofCallbackStream implements StreamInterface +{ + use StreamDecoratorTrait; + + private $callback; + + public function __construct(StreamInterface $stream, callable $cb) + { + $this->stream = $stream; + $this->callback = $cb; + } + + public function read($length) + { + $result = $this->stream->read($length); + + // Invoke the callback when EOF is hit. + if ($this->eof()) { + call_user_func($this->callback); + } + + return $result; + } +} +``` + +This decorator could be added to any existing stream and used like so: + +```php +use GuzzleHttp\Psr7; + +$original = Psr7\stream_for('foo'); + +$eofStream = new EofCallbackStream($original, function () { + echo 'EOF!'; +}); + +$eofStream->read(2); +$eofStream->read(1); +// echoes "EOF!" +$eofStream->seek(0); +$eofStream->read(3); +// echoes "EOF!" +``` + + +## PHP StreamWrapper + +You can use the `GuzzleHttp\Psr7\StreamWrapper` class if you need to use a +PSR-7 stream as a PHP stream resource. + +Use the `GuzzleHttp\Psr7\StreamWrapper::getResource()` method to create a PHP +stream from a PSR-7 stream. + +```php +use GuzzleHttp\Psr7\StreamWrapper; + +$stream = GuzzleHttp\Psr7\stream_for('hello!'); +$resource = StreamWrapper::getResource($stream); +echo fread($resource, 6); // outputs hello! +``` + + +# Function API + +There are various functions available under the `GuzzleHttp\Psr7` namespace. + + +## `function str` + +`function str(MessageInterface $message)` + +Returns the string representation of an HTTP message. + +```php +$request = new GuzzleHttp\Psr7\Request('GET', 'http://example.com'); +echo GuzzleHttp\Psr7\str($request); +``` + + +## `function uri_for` + +`function uri_for($uri)` + +This function accepts a string or `Psr\Http\Message\UriInterface` and returns a +UriInterface for the given value. If the value is already a `UriInterface`, it +is returned as-is. + +```php +$uri = GuzzleHttp\Psr7\uri_for('http://example.com'); +assert($uri === GuzzleHttp\Psr7\uri_for($uri)); +``` + + +## `function stream_for` + +`function stream_for($resource = '', array $options = [])` + +Create a new stream based on the input type. + +Options is an associative array that can contain the following keys: + +* - metadata: Array of custom metadata. +* - size: Size of the stream. + +This method accepts the following `$resource` types: + +- `Psr\Http\Message\StreamInterface`: Returns the value as-is. +- `string`: Creates a stream object that uses the given string as the contents. +- `resource`: Creates a stream object that wraps the given PHP stream resource. +- `Iterator`: If the provided value implements `Iterator`, then a read-only + stream object will be created that wraps the given iterable. Each time the + stream is read from, data from the iterator will fill a buffer and will be + continuously called until the buffer is equal to the requested read size. + Subsequent read calls will first read from the buffer and then call `next` + on the underlying iterator until it is exhausted. +- `object` with `__toString()`: If the object has the `__toString()` method, + the object will be cast to a string and then a stream will be returned that + uses the string value. +- `NULL`: When `null` is passed, an empty stream object is returned. +- `callable` When a callable is passed, a read-only stream object will be + created that invokes the given callable. The callable is invoked with the + number of suggested bytes to read. The callable can return any number of + bytes, but MUST return `false` when there is no more data to return. The + stream object that wraps the callable will invoke the callable until the + number of requested bytes are available. Any additional bytes will be + buffered and used in subsequent reads. + +```php +$stream = GuzzleHttp\Psr7\stream_for('foo'); +$stream = GuzzleHttp\Psr7\stream_for(fopen('/path/to/file', 'r')); + +$generator = function ($bytes) { + for ($i = 0; $i < $bytes; $i++) { + yield ' '; + } +} + +$stream = GuzzleHttp\Psr7\stream_for($generator(100)); +``` + + +## `function parse_header` + +`function parse_header($header)` + +Parse an array of header values containing ";" separated data into an array of +associative arrays representing the header key value pair data of the header. +When a parameter does not contain a value, but just contains a key, this +function will inject a key with a '' string value. + + +## `function normalize_header` + +`function normalize_header($header)` + +Converts an array of header values that may contain comma separated headers +into an array of headers with no comma separated values. + + +## `function modify_request` + +`function modify_request(RequestInterface $request, array $changes)` + +Clone and modify a request with the given changes. This method is useful for +reducing the number of clones needed to mutate a message. + +The changes can be one of: + +- method: (string) Changes the HTTP method. +- set_headers: (array) Sets the given headers. +- remove_headers: (array) Remove the given headers. +- body: (mixed) Sets the given body. +- uri: (UriInterface) Set the URI. +- query: (string) Set the query string value of the URI. +- version: (string) Set the protocol version. + + +## `function rewind_body` + +`function rewind_body(MessageInterface $message)` + +Attempts to rewind a message body and throws an exception on failure. The body +of the message will only be rewound if a call to `tell()` returns a value other +than `0`. + + +## `function try_fopen` + +`function try_fopen($filename, $mode)` + +Safely opens a PHP stream resource using a filename. + +When fopen fails, PHP normally raises a warning. This function adds an error +handler that checks for errors and throws an exception instead. + + +## `function copy_to_string` + +`function copy_to_string(StreamInterface $stream, $maxLen = -1)` + +Copy the contents of a stream into a string until the given number of bytes +have been read. + + +## `function copy_to_stream` + +`function copy_to_stream(StreamInterface $source, StreamInterface $dest, $maxLen = -1)` + +Copy the contents of a stream into another stream until the given number of +bytes have been read. + + +## `function hash` + +`function hash(StreamInterface $stream, $algo, $rawOutput = false)` + +Calculate a hash of a Stream. This method reads the entire stream to calculate +a rolling hash (based on PHP's hash_init functions). + + +## `function readline` + +`function readline(StreamInterface $stream, $maxLength = null)` + +Read a line from the stream up to the maximum allowed buffer length. + + +## `function parse_request` + +`function parse_request($message)` + +Parses a request message string into a request object. + + +## `function parse_response` + +`function parse_response($message)` + +Parses a response message string into a response object. + + +## `function parse_query` + +`function parse_query($str, $urlEncoding = true)` + +Parse a query string into an associative array. + +If multiple values are found for the same key, the value of that key value pair +will become an array. This function does not parse nested PHP style arrays into +an associative array (e.g., `foo[a]=1&foo[b]=2` will be parsed into +`['foo[a]' => '1', 'foo[b]' => '2']`). + + +## `function build_query` + +`function build_query(array $params, $encoding = PHP_QUERY_RFC3986)` + +Build a query string from an array of key value pairs. + +This function can use the return value of parse_query() to build a query string. +This function does not modify the provided keys when an array is encountered +(like http_build_query would). + + +## `function mimetype_from_filename` + +`function mimetype_from_filename($filename)` + +Determines the mimetype of a file by looking at its extension. + + +## `function mimetype_from_extension` + +`function mimetype_from_extension($extension)` + +Maps a file extensions to a mimetype. + + +# Additional URI Methods + +Aside from the standard `Psr\Http\Message\UriInterface` implementation in form of the `GuzzleHttp\Psr7\Uri` class, +this library also provides additional functionality when working with URIs as static methods. + +## URI Types + +An instance of `Psr\Http\Message\UriInterface` can either be an absolute URI or a relative reference. +An absolute URI has a scheme. A relative reference is used to express a URI relative to another URI, +the base URI. Relative references can be divided into several forms according to +[RFC 3986 Section 4.2](https://tools.ietf.org/html/rfc3986#section-4.2): + +- network-path references, e.g. `//example.com/path` +- absolute-path references, e.g. `/path` +- relative-path references, e.g. `subpath` + +The following methods can be used to identify the type of the URI. + +### `GuzzleHttp\Psr7\Uri::isAbsolute` + +`public static function isAbsolute(UriInterface $uri): bool` + +Whether the URI is absolute, i.e. it has a scheme. + +### `GuzzleHttp\Psr7\Uri::isNetworkPathReference` + +`public static function isNetworkPathReference(UriInterface $uri): bool` + +Whether the URI is a network-path reference. A relative reference that begins with two slash characters is +termed an network-path reference. + +### `GuzzleHttp\Psr7\Uri::isAbsolutePathReference` + +`public static function isAbsolutePathReference(UriInterface $uri): bool` + +Whether the URI is a absolute-path reference. A relative reference that begins with a single slash character is +termed an absolute-path reference. + +### `GuzzleHttp\Psr7\Uri::isRelativePathReference` + +`public static function isRelativePathReference(UriInterface $uri): bool` + +Whether the URI is a relative-path reference. A relative reference that does not begin with a slash character is +termed a relative-path reference. + +### `GuzzleHttp\Psr7\Uri::isSameDocumentReference` + +`public static function isSameDocumentReference(UriInterface $uri, UriInterface $base = null): bool` + +Whether the URI is a same-document reference. A same-document reference refers to a URI that is, aside from its +fragment component, identical to the base URI. When no base URI is given, only an empty URI reference +(apart from its fragment) is considered a same-document reference. + +## URI Components + +Additional methods to work with URI components. + +### `GuzzleHttp\Psr7\Uri::isDefaultPort` + +`public static function isDefaultPort(UriInterface $uri): bool` + +Whether the URI has the default port of the current scheme. `Psr\Http\Message\UriInterface::getPort` may return null +or the standard port. This method can be used independently of the implementation. + +### `GuzzleHttp\Psr7\Uri::composeComponents` + +`public static function composeComponents($scheme, $authority, $path, $query, $fragment): string` + +Composes a URI reference string from its various components according to +[RFC 3986 Section 5.3](https://tools.ietf.org/html/rfc3986#section-5.3). Usually this method does not need to be called +manually but instead is used indirectly via `Psr\Http\Message\UriInterface::__toString`. + +### `GuzzleHttp\Psr7\Uri::fromParts` + +`public static function fromParts(array $parts): UriInterface` + +Creates a URI from a hash of [`parse_url`](http://php.net/manual/en/function.parse-url.php) components. + + +### `GuzzleHttp\Psr7\Uri::withQueryValue` + +`public static function withQueryValue(UriInterface $uri, $key, $value): UriInterface` + +Creates a new URI with a specific query string value. Any existing query string values that exactly match the +provided key are removed and replaced with the given key value pair. A value of null will set the query string +key without a value, e.g. "key" instead of "key=value". + +### `GuzzleHttp\Psr7\Uri::withQueryValues` + +`public static function withQueryValues(UriInterface $uri, array $keyValueArray): UriInterface` + +Creates a new URI with multiple query string values. It has the same behavior as `withQueryValue()` but for an +associative array of key => value. + +### `GuzzleHttp\Psr7\Uri::withoutQueryValue` + +`public static function withoutQueryValue(UriInterface $uri, $key): UriInterface` + +Creates a new URI with a specific query string value removed. Any existing query string values that exactly match the +provided key are removed. + +## Reference Resolution + +`GuzzleHttp\Psr7\UriResolver` provides methods to resolve a URI reference in the context of a base URI according +to [RFC 3986 Section 5](https://tools.ietf.org/html/rfc3986#section-5). This is for example also what web browsers +do when resolving a link in a website based on the current request URI. + +### `GuzzleHttp\Psr7\UriResolver::resolve` + +`public static function resolve(UriInterface $base, UriInterface $rel): UriInterface` + +Converts the relative URI into a new URI that is resolved against the base URI. + +### `GuzzleHttp\Psr7\UriResolver::removeDotSegments` + +`public static function removeDotSegments(string $path): string` + +Removes dot segments from a path and returns the new path according to +[RFC 3986 Section 5.2.4](https://tools.ietf.org/html/rfc3986#section-5.2.4). + +### `GuzzleHttp\Psr7\UriResolver::relativize` + +`public static function relativize(UriInterface $base, UriInterface $target): UriInterface` + +Returns the target URI as a relative reference from the base URI. This method is the counterpart to resolve(): + +```php +(string) $target === (string) UriResolver::resolve($base, UriResolver::relativize($base, $target)) +``` + +One use-case is to use the current request URI as base URI and then generate relative links in your documents +to reduce the document size or offer self-contained downloadable document archives. + +```php +$base = new Uri('http://example.com/a/b/'); +echo UriResolver::relativize($base, new Uri('http://example.com/a/b/c')); // prints 'c'. +echo UriResolver::relativize($base, new Uri('http://example.com/a/x/y')); // prints '../x/y'. +echo UriResolver::relativize($base, new Uri('http://example.com/a/b/?q')); // prints '?q'. +echo UriResolver::relativize($base, new Uri('http://example.org/a/b/')); // prints '//example.org/a/b/'. +``` + +## Normalization and Comparison + +`GuzzleHttp\Psr7\UriNormalizer` provides methods to normalize and compare URIs according to +[RFC 3986 Section 6](https://tools.ietf.org/html/rfc3986#section-6). + +### `GuzzleHttp\Psr7\UriNormalizer::normalize` + +`public static function normalize(UriInterface $uri, $flags = self::PRESERVING_NORMALIZATIONS): UriInterface` + +Returns a normalized URI. The scheme and host component are already normalized to lowercase per PSR-7 UriInterface. +This methods adds additional normalizations that can be configured with the `$flags` parameter which is a bitmask +of normalizations to apply. The following normalizations are available: + +- `UriNormalizer::PRESERVING_NORMALIZATIONS` + + Default normalizations which only include the ones that preserve semantics. + +- `UriNormalizer::CAPITALIZE_PERCENT_ENCODING` + + All letters within a percent-encoding triplet (e.g., "%3A") are case-insensitive, and should be capitalized. + + Example: `http://example.org/a%c2%b1b` → `http://example.org/a%C2%B1b` + +- `UriNormalizer::DECODE_UNRESERVED_CHARACTERS` + + Decodes percent-encoded octets of unreserved characters. For consistency, percent-encoded octets in the ranges of + ALPHA (%41–%5A and %61–%7A), DIGIT (%30–%39), hyphen (%2D), period (%2E), underscore (%5F), or tilde (%7E) should + not be created by URI producers and, when found in a URI, should be decoded to their corresponding unreserved + characters by URI normalizers. + + Example: `http://example.org/%7Eusern%61me/` → `http://example.org/~username/` + +- `UriNormalizer::CONVERT_EMPTY_PATH` + + Converts the empty path to "/" for http and https URIs. + + Example: `http://example.org` → `http://example.org/` + +- `UriNormalizer::REMOVE_DEFAULT_HOST` + + Removes the default host of the given URI scheme from the URI. Only the "file" scheme defines the default host + "localhost". All of `file:/myfile`, `file:///myfile`, and `file://localhost/myfile` are equivalent according to + RFC 3986. + + Example: `file://localhost/myfile` → `file:///myfile` + +- `UriNormalizer::REMOVE_DEFAULT_PORT` + + Removes the default port of the given URI scheme from the URI. + + Example: `http://example.org:80/` → `http://example.org/` + +- `UriNormalizer::REMOVE_DOT_SEGMENTS` + + Removes unnecessary dot-segments. Dot-segments in relative-path references are not removed as it would + change the semantics of the URI reference. + + Example: `http://example.org/../a/b/../c/./d.html` → `http://example.org/a/c/d.html` + +- `UriNormalizer::REMOVE_DUPLICATE_SLASHES` + + Paths which include two or more adjacent slashes are converted to one. Webservers usually ignore duplicate slashes + and treat those URIs equivalent. But in theory those URIs do not need to be equivalent. So this normalization + may change the semantics. Encoded slashes (%2F) are not removed. + + Example: `http://example.org//foo///bar.html` → `http://example.org/foo/bar.html` + +- `UriNormalizer::SORT_QUERY_PARAMETERS` + + Sort query parameters with their values in alphabetical order. However, the order of parameters in a URI may be + significant (this is not defined by the standard). So this normalization is not safe and may change the semantics + of the URI. + + Example: `?lang=en&article=fred` → `?article=fred&lang=en` + +### `GuzzleHttp\Psr7\UriNormalizer::isEquivalent` + +`public static function isEquivalent(UriInterface $uri1, UriInterface $uri2, $normalizations = self::PRESERVING_NORMALIZATIONS): bool` + +Whether two URIs can be considered equivalent. Both URIs are normalized automatically before comparison with the given +`$normalizations` bitmask. The method also accepts relative URI references and returns true when they are equivalent. +This of course assumes they will be resolved against the same base URI. If this is not the case, determination of +equivalence or difference of relative references does not mean anything. diff --git a/vendor/guzzlehttp/psr7/composer.json b/vendor/guzzlehttp/psr7/composer.json index 9224fe68d..7306ba844 100644 --- a/vendor/guzzlehttp/psr7/composer.json +++ b/vendor/guzzlehttp/psr7/composer.json @@ -1,60 +1,60 @@ -{ - "name": "guzzlehttp\/psr7", - "type": "library", - "description": "PSR-7 message implementation that also provides common utility methods", - "keywords": [ - "request", - "response", - "message", - "stream", - "http", - "uri", - "url", - "psr-7" - ], - "license": "MIT", - "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https:\/\/github.com\/mtdowling" - }, - { - "name": "Tobias Schultze", - "homepage": "https:\/\/github.com\/Tobion" - } - ], - "require": { - "php": ">=5.4.0", - "psr\/http-message": "~1.0", - "ralouphie\/getallheaders": "^2.0.5 || ^3.0.0" - }, - "require-dev": { - "phpunit\/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8", - "ext-zlib": "*" - }, - "provide": { - "psr\/http-message-implementation": "1.0" - }, - "suggest": { - "zendframework\/zend-httphandlerrunner": "Emit PSR-7 responses" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\": "src\/" - }, - "files": [ - "src\/functions_include.php" - ] - }, - "autoload-dev": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Tests\\Psr7\\": "tests\/" - } - }, - "extra": { - "branch-alias": { - "dev-master": "1.6-dev" - } - } +{ + "name": "guzzlehttp\/psr7", + "type": "library", + "description": "PSR-7 message implementation that also provides common utility methods", + "keywords": [ + "request", + "response", + "message", + "stream", + "http", + "uri", + "url", + "psr-7" + ], + "license": "MIT", + "authors": [ + { + "name": "Michael Dowling", + "email": "mtdowling@gmail.com", + "homepage": "https:\/\/github.com\/mtdowling" + }, + { + "name": "Tobias Schultze", + "homepage": "https:\/\/github.com\/Tobion" + } + ], + "require": { + "php": ">=5.4.0", + "psr\/http-message": "~1.0", + "ralouphie\/getallheaders": "^2.0.5 || ^3.0.0" + }, + "require-dev": { + "phpunit\/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8", + "ext-zlib": "*" + }, + "provide": { + "psr\/http-message-implementation": "1.0" + }, + "suggest": { + "zendframework\/zend-httphandlerrunner": "Emit PSR-7 responses" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Psr7\\": "src\/" + }, + "files": [ + "src\/functions_include.php" + ] + }, + "autoload-dev": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\GuzzleHttp\\Tests\\Psr7\\": "tests\/" + } + }, + "extra": { + "branch-alias": { + "dev-master": "1.6-dev" + } + } } \ No newline at end of file diff --git a/vendor/guzzlehttp/psr7/index.php b/vendor/guzzlehttp/psr7/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/guzzlehttp/psr7/index.php +++ b/vendor/guzzlehttp/psr7/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/guzzlehttp/psr7/src/AppendStream.php b/vendor/guzzlehttp/psr7/src/AppendStream.php index 24261003d..a8892f48b 100644 --- a/vendor/guzzlehttp/psr7/src/AppendStream.php +++ b/vendor/guzzlehttp/psr7/src/AppendStream.php @@ -1,202 +1,202 @@ -addStream($stream); - } - } - public function __toString() - { - try { - $this->rewind(); - return $this->getContents(); - } catch (\Exception $e) { - return ''; - } - } - /** - * Add a stream to the AppendStream - * - * @param StreamInterface $stream Stream to append. Must be readable. - * - * @throws \InvalidArgumentException if the stream is not readable - */ - public function addStream(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream) - { - if (!$stream->isReadable()) { - throw new \InvalidArgumentException('Each stream must be readable'); - } - // The stream is only seekable if all streams are seekable - if (!$stream->isSeekable()) { - $this->seekable = \false; - } - $this->streams[] = $stream; - } - public function getContents() - { - return copy_to_string($this); - } - /** - * Closes each attached stream. - * - * {@inheritdoc} - */ - public function close() - { - $this->pos = $this->current = 0; - $this->seekable = \true; - foreach ($this->streams as $stream) { - $stream->close(); - } - $this->streams = []; - } - /** - * Detaches each attached stream. - * - * Returns null as it's not clear which underlying stream resource to return. - * - * {@inheritdoc} - */ - public function detach() - { - $this->pos = $this->current = 0; - $this->seekable = \true; - foreach ($this->streams as $stream) { - $stream->detach(); - } - $this->streams = []; - } - public function tell() - { - return $this->pos; - } - /** - * Tries to calculate the size by adding the size of each stream. - * - * If any of the streams do not return a valid number, then the size of the - * append stream cannot be determined and null is returned. - * - * {@inheritdoc} - */ - public function getSize() - { - $size = 0; - foreach ($this->streams as $stream) { - $s = $stream->getSize(); - if ($s === null) { - return null; - } - $size += $s; - } - return $size; - } - public function eof() - { - return !$this->streams || $this->current >= \count($this->streams) - 1 && $this->streams[$this->current]->eof(); - } - public function rewind() - { - $this->seek(0); - } - /** - * Attempts to seek to the given position. Only supports SEEK_SET. - * - * {@inheritdoc} - */ - public function seek($offset, $whence = \SEEK_SET) - { - if (!$this->seekable) { - throw new \RuntimeException('This AppendStream is not seekable'); - } elseif ($whence !== \SEEK_SET) { - throw new \RuntimeException('The AppendStream can only seek with SEEK_SET'); - } - $this->pos = $this->current = 0; - // Rewind each stream - foreach ($this->streams as $i => $stream) { - try { - $stream->rewind(); - } catch (\Exception $e) { - throw new \RuntimeException('Unable to seek stream ' . $i . ' of the AppendStream', 0, $e); - } - } - // Seek to the actual position by reading from each stream - while ($this->pos < $offset && !$this->eof()) { - $result = $this->read(\min(8096, $offset - $this->pos)); - if ($result === '') { - break; - } - } - } - /** - * Reads from all of the appended streams until the length is met or EOF. - * - * {@inheritdoc} - */ - public function read($length) - { - $buffer = ''; - $total = \count($this->streams) - 1; - $remaining = $length; - $progressToNext = \false; - while ($remaining > 0) { - // Progress to the next stream if needed. - if ($progressToNext || $this->streams[$this->current]->eof()) { - $progressToNext = \false; - if ($this->current === $total) { - break; - } - $this->current++; - } - $result = $this->streams[$this->current]->read($remaining); - // Using a loose comparison here to match on '', false, and null - if ($result == null) { - $progressToNext = \true; - continue; - } - $buffer .= $result; - $remaining = $length - \strlen($buffer); - } - $this->pos += \strlen($buffer); - return $buffer; - } - public function isReadable() - { - return \true; - } - public function isWritable() - { - return \false; - } - public function isSeekable() - { - return $this->seekable; - } - public function write($string) - { - throw new \RuntimeException('Cannot write to an AppendStream'); - } - public function getMetadata($key = null) - { - return $key ? null : []; - } -} +addStream($stream); + } + } + public function __toString() + { + try { + $this->rewind(); + return $this->getContents(); + } catch (\Exception $e) { + return ''; + } + } + /** + * Add a stream to the AppendStream + * + * @param StreamInterface $stream Stream to append. Must be readable. + * + * @throws \InvalidArgumentException if the stream is not readable + */ + public function addStream(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream) + { + if (!$stream->isReadable()) { + throw new \InvalidArgumentException('Each stream must be readable'); + } + // The stream is only seekable if all streams are seekable + if (!$stream->isSeekable()) { + $this->seekable = \false; + } + $this->streams[] = $stream; + } + public function getContents() + { + return copy_to_string($this); + } + /** + * Closes each attached stream. + * + * {@inheritdoc} + */ + public function close() + { + $this->pos = $this->current = 0; + $this->seekable = \true; + foreach ($this->streams as $stream) { + $stream->close(); + } + $this->streams = []; + } + /** + * Detaches each attached stream. + * + * Returns null as it's not clear which underlying stream resource to return. + * + * {@inheritdoc} + */ + public function detach() + { + $this->pos = $this->current = 0; + $this->seekable = \true; + foreach ($this->streams as $stream) { + $stream->detach(); + } + $this->streams = []; + } + public function tell() + { + return $this->pos; + } + /** + * Tries to calculate the size by adding the size of each stream. + * + * If any of the streams do not return a valid number, then the size of the + * append stream cannot be determined and null is returned. + * + * {@inheritdoc} + */ + public function getSize() + { + $size = 0; + foreach ($this->streams as $stream) { + $s = $stream->getSize(); + if ($s === null) { + return null; + } + $size += $s; + } + return $size; + } + public function eof() + { + return !$this->streams || $this->current >= \count($this->streams) - 1 && $this->streams[$this->current]->eof(); + } + public function rewind() + { + $this->seek(0); + } + /** + * Attempts to seek to the given position. Only supports SEEK_SET. + * + * {@inheritdoc} + */ + public function seek($offset, $whence = \SEEK_SET) + { + if (!$this->seekable) { + throw new \RuntimeException('This AppendStream is not seekable'); + } elseif ($whence !== \SEEK_SET) { + throw new \RuntimeException('The AppendStream can only seek with SEEK_SET'); + } + $this->pos = $this->current = 0; + // Rewind each stream + foreach ($this->streams as $i => $stream) { + try { + $stream->rewind(); + } catch (\Exception $e) { + throw new \RuntimeException('Unable to seek stream ' . $i . ' of the AppendStream', 0, $e); + } + } + // Seek to the actual position by reading from each stream + while ($this->pos < $offset && !$this->eof()) { + $result = $this->read(\min(8096, $offset - $this->pos)); + if ($result === '') { + break; + } + } + } + /** + * Reads from all of the appended streams until the length is met or EOF. + * + * {@inheritdoc} + */ + public function read($length) + { + $buffer = ''; + $total = \count($this->streams) - 1; + $remaining = $length; + $progressToNext = \false; + while ($remaining > 0) { + // Progress to the next stream if needed. + if ($progressToNext || $this->streams[$this->current]->eof()) { + $progressToNext = \false; + if ($this->current === $total) { + break; + } + $this->current++; + } + $result = $this->streams[$this->current]->read($remaining); + // Using a loose comparison here to match on '', false, and null + if ($result == null) { + $progressToNext = \true; + continue; + } + $buffer .= $result; + $remaining = $length - \strlen($buffer); + } + $this->pos += \strlen($buffer); + return $buffer; + } + public function isReadable() + { + return \true; + } + public function isWritable() + { + return \false; + } + public function isSeekable() + { + return $this->seekable; + } + public function write($string) + { + throw new \RuntimeException('Cannot write to an AppendStream'); + } + public function getMetadata($key = null) + { + return $key ? null : []; + } +} diff --git a/vendor/guzzlehttp/psr7/src/BufferStream.php b/vendor/guzzlehttp/psr7/src/BufferStream.php index ebe56e35c..d5f341eb8 100644 --- a/vendor/guzzlehttp/psr7/src/BufferStream.php +++ b/vendor/guzzlehttp/psr7/src/BufferStream.php @@ -1,115 +1,115 @@ -hwm = $hwm; - } - public function __toString() - { - return $this->getContents(); - } - public function getContents() - { - $buffer = $this->buffer; - $this->buffer = ''; - return $buffer; - } - public function close() - { - $this->buffer = ''; - } - public function detach() - { - $this->close(); - } - public function getSize() - { - return \strlen($this->buffer); - } - public function isReadable() - { - return \true; - } - public function isWritable() - { - return \true; - } - public function isSeekable() - { - return \false; - } - public function rewind() - { - $this->seek(0); - } - public function seek($offset, $whence = \SEEK_SET) - { - throw new \RuntimeException('Cannot seek a BufferStream'); - } - public function eof() - { - return \strlen($this->buffer) === 0; - } - public function tell() - { - throw new \RuntimeException('Cannot determine the position of a BufferStream'); - } - /** - * Reads data from the buffer. - */ - public function read($length) - { - $currentLength = \strlen($this->buffer); - if ($length >= $currentLength) { - // No need to slice the buffer because we don't have enough data. - $result = $this->buffer; - $this->buffer = ''; - } else { - // Slice up the result to provide a subset of the buffer. - $result = \substr($this->buffer, 0, $length); - $this->buffer = \substr($this->buffer, $length); - } - return $result; - } - /** - * Writes data to the buffer. - */ - public function write($string) - { - $this->buffer .= $string; - // TODO: What should happen here? - if (\strlen($this->buffer) >= $this->hwm) { - return \false; - } - return \strlen($string); - } - public function getMetadata($key = null) - { - if ($key == 'hwm') { - return $this->hwm; - } - return $key ? null : []; - } -} +hwm = $hwm; + } + public function __toString() + { + return $this->getContents(); + } + public function getContents() + { + $buffer = $this->buffer; + $this->buffer = ''; + return $buffer; + } + public function close() + { + $this->buffer = ''; + } + public function detach() + { + $this->close(); + } + public function getSize() + { + return \strlen($this->buffer); + } + public function isReadable() + { + return \true; + } + public function isWritable() + { + return \true; + } + public function isSeekable() + { + return \false; + } + public function rewind() + { + $this->seek(0); + } + public function seek($offset, $whence = \SEEK_SET) + { + throw new \RuntimeException('Cannot seek a BufferStream'); + } + public function eof() + { + return \strlen($this->buffer) === 0; + } + public function tell() + { + throw new \RuntimeException('Cannot determine the position of a BufferStream'); + } + /** + * Reads data from the buffer. + */ + public function read($length) + { + $currentLength = \strlen($this->buffer); + if ($length >= $currentLength) { + // No need to slice the buffer because we don't have enough data. + $result = $this->buffer; + $this->buffer = ''; + } else { + // Slice up the result to provide a subset of the buffer. + $result = \substr($this->buffer, 0, $length); + $this->buffer = \substr($this->buffer, $length); + } + return $result; + } + /** + * Writes data to the buffer. + */ + public function write($string) + { + $this->buffer .= $string; + // TODO: What should happen here? + if (\strlen($this->buffer) >= $this->hwm) { + return \false; + } + return \strlen($string); + } + public function getMetadata($key = null) + { + if ($key == 'hwm') { + return $this->hwm; + } + return $key ? null : []; + } +} diff --git a/vendor/guzzlehttp/psr7/src/CachingStream.php b/vendor/guzzlehttp/psr7/src/CachingStream.php index ed35ce50e..5c89cbdc2 100644 --- a/vendor/guzzlehttp/psr7/src/CachingStream.php +++ b/vendor/guzzlehttp/psr7/src/CachingStream.php @@ -1,115 +1,115 @@ -remoteStream = $stream; - $this->stream = $target ?: new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream(\fopen('php://temp', 'r+')); - } - public function getSize() - { - return \max($this->stream->getSize(), $this->remoteStream->getSize()); - } - public function rewind() - { - $this->seek(0); - } - public function seek($offset, $whence = \SEEK_SET) - { - if ($whence == \SEEK_SET) { - $byte = $offset; - } elseif ($whence == \SEEK_CUR) { - $byte = $offset + $this->tell(); - } elseif ($whence == \SEEK_END) { - $size = $this->remoteStream->getSize(); - if ($size === null) { - $size = $this->cacheEntireStream(); - } - $byte = $size + $offset; - } else { - throw new \InvalidArgumentException('Invalid whence'); - } - $diff = $byte - $this->stream->getSize(); - if ($diff > 0) { - // Read the remoteStream until we have read in at least the amount - // of bytes requested, or we reach the end of the file. - while ($diff > 0 && !$this->remoteStream->eof()) { - $this->read($diff); - $diff = $byte - $this->stream->getSize(); - } - } else { - // We can just do a normal seek since we've already seen this byte. - $this->stream->seek($byte); - } - } - public function read($length) - { - // Perform a regular read on any previously read data from the buffer - $data = $this->stream->read($length); - $remaining = $length - \strlen($data); - // More data was requested so read from the remote stream - if ($remaining) { - // If data was written to the buffer in a position that would have - // been filled from the remote stream, then we must skip bytes on - // the remote stream to emulate overwriting bytes from that - // position. This mimics the behavior of other PHP stream wrappers. - $remoteData = $this->remoteStream->read($remaining + $this->skipReadBytes); - if ($this->skipReadBytes) { - $len = \strlen($remoteData); - $remoteData = \substr($remoteData, $this->skipReadBytes); - $this->skipReadBytes = \max(0, $this->skipReadBytes - $len); - } - $data .= $remoteData; - $this->stream->write($remoteData); - } - return $data; - } - public function write($string) - { - // When appending to the end of the currently read stream, you'll want - // to skip bytes from being read from the remote stream to emulate - // other stream wrappers. Basically replacing bytes of data of a fixed - // length. - $overflow = \strlen($string) + $this->tell() - $this->remoteStream->tell(); - if ($overflow > 0) { - $this->skipReadBytes += $overflow; - } - return $this->stream->write($string); - } - public function eof() - { - return $this->stream->eof() && $this->remoteStream->eof(); - } - /** - * Close both the remote stream and buffer stream - */ - public function close() - { - $this->remoteStream->close() && $this->stream->close(); - } - private function cacheEntireStream() - { - $target = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\FnStream(['write' => 'strlen']); - copy_to_stream($this, $target); - return $this->tell(); - } -} +remoteStream = $stream; + $this->stream = $target ?: new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream(\fopen('php://temp', 'r+')); + } + public function getSize() + { + return \max($this->stream->getSize(), $this->remoteStream->getSize()); + } + public function rewind() + { + $this->seek(0); + } + public function seek($offset, $whence = \SEEK_SET) + { + if ($whence == \SEEK_SET) { + $byte = $offset; + } elseif ($whence == \SEEK_CUR) { + $byte = $offset + $this->tell(); + } elseif ($whence == \SEEK_END) { + $size = $this->remoteStream->getSize(); + if ($size === null) { + $size = $this->cacheEntireStream(); + } + $byte = $size + $offset; + } else { + throw new \InvalidArgumentException('Invalid whence'); + } + $diff = $byte - $this->stream->getSize(); + if ($diff > 0) { + // Read the remoteStream until we have read in at least the amount + // of bytes requested, or we reach the end of the file. + while ($diff > 0 && !$this->remoteStream->eof()) { + $this->read($diff); + $diff = $byte - $this->stream->getSize(); + } + } else { + // We can just do a normal seek since we've already seen this byte. + $this->stream->seek($byte); + } + } + public function read($length) + { + // Perform a regular read on any previously read data from the buffer + $data = $this->stream->read($length); + $remaining = $length - \strlen($data); + // More data was requested so read from the remote stream + if ($remaining) { + // If data was written to the buffer in a position that would have + // been filled from the remote stream, then we must skip bytes on + // the remote stream to emulate overwriting bytes from that + // position. This mimics the behavior of other PHP stream wrappers. + $remoteData = $this->remoteStream->read($remaining + $this->skipReadBytes); + if ($this->skipReadBytes) { + $len = \strlen($remoteData); + $remoteData = \substr($remoteData, $this->skipReadBytes); + $this->skipReadBytes = \max(0, $this->skipReadBytes - $len); + } + $data .= $remoteData; + $this->stream->write($remoteData); + } + return $data; + } + public function write($string) + { + // When appending to the end of the currently read stream, you'll want + // to skip bytes from being read from the remote stream to emulate + // other stream wrappers. Basically replacing bytes of data of a fixed + // length. + $overflow = \strlen($string) + $this->tell() - $this->remoteStream->tell(); + if ($overflow > 0) { + $this->skipReadBytes += $overflow; + } + return $this->stream->write($string); + } + public function eof() + { + return $this->stream->eof() && $this->remoteStream->eof(); + } + /** + * Close both the remote stream and buffer stream + */ + public function close() + { + $this->remoteStream->close() && $this->stream->close(); + } + private function cacheEntireStream() + { + $target = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\FnStream(['write' => 'strlen']); + copy_to_stream($this, $target); + return $this->tell(); + } +} diff --git a/vendor/guzzlehttp/psr7/src/DroppingStream.php b/vendor/guzzlehttp/psr7/src/DroppingStream.php index 00bbace60..6a8f1ef37 100644 --- a/vendor/guzzlehttp/psr7/src/DroppingStream.php +++ b/vendor/guzzlehttp/psr7/src/DroppingStream.php @@ -1,36 +1,36 @@ -stream = $stream; - $this->maxLength = $maxLength; - } - public function write($string) - { - $diff = $this->maxLength - $this->stream->getSize(); - // Begin returning 0 when the underlying stream is too large. - if ($diff <= 0) { - return 0; - } - // Write the stream or a subset of the stream if needed. - if (\strlen($string) < $diff) { - return $this->stream->write($string); - } - return $this->stream->write(\substr($string, 0, $diff)); - } -} +stream = $stream; + $this->maxLength = $maxLength; + } + public function write($string) + { + $diff = $this->maxLength - $this->stream->getSize(); + // Begin returning 0 when the underlying stream is too large. + if ($diff <= 0) { + return 0; + } + // Write the stream or a subset of the stream if needed. + if (\strlen($string) < $diff) { + return $this->stream->write($string); + } + return $this->stream->write(\substr($string, 0, $diff)); + } +} diff --git a/vendor/guzzlehttp/psr7/src/FnStream.php b/vendor/guzzlehttp/psr7/src/FnStream.php index 7d34d1e92..a02e77538 100644 --- a/vendor/guzzlehttp/psr7/src/FnStream.php +++ b/vendor/guzzlehttp/psr7/src/FnStream.php @@ -1,132 +1,132 @@ -methods = $methods; - // Create the functions on the class - foreach ($methods as $name => $fn) { - $this->{'_fn_' . $name} = $fn; - } - } - /** - * Lazily determine which methods are not implemented. - * @throws \BadMethodCallException - */ - public function __get($name) - { - throw new \BadMethodCallException(\str_replace('_fn_', '', $name) . '() is not implemented in the FnStream'); - } - /** - * The close method is called on the underlying stream only if possible. - */ - public function __destruct() - { - if (isset($this->_fn_close)) { - \call_user_func($this->_fn_close); - } - } - /** - * An unserialize would allow the __destruct to run when the unserialized value goes out of scope. - * @throws \LogicException - */ - public function __wakeup() - { - throw new \LogicException('FnStream should never be unserialized'); - } - /** - * Adds custom functionality to an underlying stream by intercepting - * specific method calls. - * - * @param StreamInterface $stream Stream to decorate - * @param array $methods Hash of method name to a closure - * - * @return FnStream - */ - public static function decorate(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, array $methods) - { - // If any of the required methods were not provided, then simply - // proxy to the decorated stream. - foreach (\array_diff(self::$slots, \array_keys($methods)) as $diff) { - $methods[$diff] = [$stream, $diff]; - } - return new self($methods); - } - public function __toString() - { - return \call_user_func($this->_fn___toString); - } - public function close() - { - return \call_user_func($this->_fn_close); - } - public function detach() - { - return \call_user_func($this->_fn_detach); - } - public function getSize() - { - return \call_user_func($this->_fn_getSize); - } - public function tell() - { - return \call_user_func($this->_fn_tell); - } - public function eof() - { - return \call_user_func($this->_fn_eof); - } - public function isSeekable() - { - return \call_user_func($this->_fn_isSeekable); - } - public function rewind() - { - \call_user_func($this->_fn_rewind); - } - public function seek($offset, $whence = \SEEK_SET) - { - \call_user_func($this->_fn_seek, $offset, $whence); - } - public function isWritable() - { - return \call_user_func($this->_fn_isWritable); - } - public function write($string) - { - return \call_user_func($this->_fn_write, $string); - } - public function isReadable() - { - return \call_user_func($this->_fn_isReadable); - } - public function read($length) - { - return \call_user_func($this->_fn_read, $length); - } - public function getContents() - { - return \call_user_func($this->_fn_getContents); - } - public function getMetadata($key = null) - { - return \call_user_func($this->_fn_getMetadata, $key); - } -} +methods = $methods; + // Create the functions on the class + foreach ($methods as $name => $fn) { + $this->{'_fn_' . $name} = $fn; + } + } + /** + * Lazily determine which methods are not implemented. + * @throws \BadMethodCallException + */ + public function __get($name) + { + throw new \BadMethodCallException(\str_replace('_fn_', '', $name) . '() is not implemented in the FnStream'); + } + /** + * The close method is called on the underlying stream only if possible. + */ + public function __destruct() + { + if (isset($this->_fn_close)) { + \call_user_func($this->_fn_close); + } + } + /** + * An unserialize would allow the __destruct to run when the unserialized value goes out of scope. + * @throws \LogicException + */ + public function __wakeup() + { + throw new \LogicException('FnStream should never be unserialized'); + } + /** + * Adds custom functionality to an underlying stream by intercepting + * specific method calls. + * + * @param StreamInterface $stream Stream to decorate + * @param array $methods Hash of method name to a closure + * + * @return FnStream + */ + public static function decorate(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, array $methods) + { + // If any of the required methods were not provided, then simply + // proxy to the decorated stream. + foreach (\array_diff(self::$slots, \array_keys($methods)) as $diff) { + $methods[$diff] = [$stream, $diff]; + } + return new self($methods); + } + public function __toString() + { + return \call_user_func($this->_fn___toString); + } + public function close() + { + return \call_user_func($this->_fn_close); + } + public function detach() + { + return \call_user_func($this->_fn_detach); + } + public function getSize() + { + return \call_user_func($this->_fn_getSize); + } + public function tell() + { + return \call_user_func($this->_fn_tell); + } + public function eof() + { + return \call_user_func($this->_fn_eof); + } + public function isSeekable() + { + return \call_user_func($this->_fn_isSeekable); + } + public function rewind() + { + \call_user_func($this->_fn_rewind); + } + public function seek($offset, $whence = \SEEK_SET) + { + \call_user_func($this->_fn_seek, $offset, $whence); + } + public function isWritable() + { + return \call_user_func($this->_fn_isWritable); + } + public function write($string) + { + return \call_user_func($this->_fn_write, $string); + } + public function isReadable() + { + return \call_user_func($this->_fn_isReadable); + } + public function read($length) + { + return \call_user_func($this->_fn_read, $length); + } + public function getContents() + { + return \call_user_func($this->_fn_getContents); + } + public function getMetadata($key = null) + { + return \call_user_func($this->_fn_getMetadata, $key); + } +} diff --git a/vendor/guzzlehttp/psr7/src/InflateStream.php b/vendor/guzzlehttp/psr7/src/InflateStream.php index 990e65958..dfa6a0b73 100644 --- a/vendor/guzzlehttp/psr7/src/InflateStream.php +++ b/vendor/guzzlehttp/psr7/src/InflateStream.php @@ -1,48 +1,48 @@ -read(10); - $filenameHeaderLength = $this->getLengthOfPossibleFilenameHeader($stream, $header); - // Skip the header, that is 10 + length of filename + 1 (nil) bytes - $stream = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LimitStream($stream, -1, 10 + $filenameHeaderLength); - $resource = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\StreamWrapper::getResource($stream); - \stream_filter_append($resource, 'zlib.inflate', \STREAM_FILTER_READ); - $this->stream = $stream->isSeekable() ? new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream($resource) : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\NoSeekStream(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream($resource)); - } - /** - * @param StreamInterface $stream - * @param $header - * @return int - */ - private function getLengthOfPossibleFilenameHeader(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, $header) - { - $filename_header_length = 0; - if (\substr(\bin2hex($header), 6, 2) === '08') { - // we have a filename, read until nil - $filename_header_length = 1; - while ($stream->read(1) !== \chr(0)) { - $filename_header_length++; - } - } - return $filename_header_length; - } -} +read(10); + $filenameHeaderLength = $this->getLengthOfPossibleFilenameHeader($stream, $header); + // Skip the header, that is 10 + length of filename + 1 (nil) bytes + $stream = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LimitStream($stream, -1, 10 + $filenameHeaderLength); + $resource = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\StreamWrapper::getResource($stream); + \stream_filter_append($resource, 'zlib.inflate', \STREAM_FILTER_READ); + $this->stream = $stream->isSeekable() ? new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream($resource) : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\NoSeekStream(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream($resource)); + } + /** + * @param StreamInterface $stream + * @param $header + * @return int + */ + private function getLengthOfPossibleFilenameHeader(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, $header) + { + $filename_header_length = 0; + if (\substr(\bin2hex($header), 6, 2) === '08') { + // we have a filename, read until nil + $filename_header_length = 1; + while ($stream->read(1) !== \chr(0)) { + $filename_header_length++; + } + } + return $filename_header_length; + } +} diff --git a/vendor/guzzlehttp/psr7/src/LazyOpenStream.php b/vendor/guzzlehttp/psr7/src/LazyOpenStream.php index cd2c1426f..f522fef7a 100644 --- a/vendor/guzzlehttp/psr7/src/LazyOpenStream.php +++ b/vendor/guzzlehttp/psr7/src/LazyOpenStream.php @@ -1,35 +1,35 @@ -filename = $filename; - $this->mode = $mode; - } - /** - * Creates the underlying stream lazily when required. - * - * @return StreamInterface - */ - protected function createStream() - { - return stream_for(try_fopen($this->filename, $this->mode)); - } -} +filename = $filename; + $this->mode = $mode; + } + /** + * Creates the underlying stream lazily when required. + * + * @return StreamInterface + */ + protected function createStream() + { + return stream_for(try_fopen($this->filename, $this->mode)); + } +} diff --git a/vendor/guzzlehttp/psr7/src/LimitStream.php b/vendor/guzzlehttp/psr7/src/LimitStream.php index 2447fa804..0559773ee 100644 --- a/vendor/guzzlehttp/psr7/src/LimitStream.php +++ b/vendor/guzzlehttp/psr7/src/LimitStream.php @@ -1,128 +1,128 @@ -stream = $stream; - $this->setLimit($limit); - $this->setOffset($offset); - } - public function eof() - { - // Always return true if the underlying stream is EOF - if ($this->stream->eof()) { - return \true; - } - // No limit and the underlying stream is not at EOF - if ($this->limit == -1) { - return \false; - } - return $this->stream->tell() >= $this->offset + $this->limit; - } - /** - * Returns the size of the limited subset of data - * {@inheritdoc} - */ - public function getSize() - { - if (null === ($length = $this->stream->getSize())) { - return null; - } elseif ($this->limit == -1) { - return $length - $this->offset; - } else { - return \min($this->limit, $length - $this->offset); - } - } - /** - * Allow for a bounded seek on the read limited stream - * {@inheritdoc} - */ - public function seek($offset, $whence = \SEEK_SET) - { - if ($whence !== \SEEK_SET || $offset < 0) { - throw new \RuntimeException(\sprintf('Cannot seek to offset %s with whence %s', $offset, $whence)); - } - $offset += $this->offset; - if ($this->limit !== -1) { - if ($offset > $this->offset + $this->limit) { - $offset = $this->offset + $this->limit; - } - } - $this->stream->seek($offset); - } - /** - * Give a relative tell() - * {@inheritdoc} - */ - public function tell() - { - return $this->stream->tell() - $this->offset; - } - /** - * Set the offset to start limiting from - * - * @param int $offset Offset to seek to and begin byte limiting from - * - * @throws \RuntimeException if the stream cannot be seeked. - */ - public function setOffset($offset) - { - $current = $this->stream->tell(); - if ($current !== $offset) { - // If the stream cannot seek to the offset position, then read to it - if ($this->stream->isSeekable()) { - $this->stream->seek($offset); - } elseif ($current > $offset) { - throw new \RuntimeException("Could not seek to stream offset {$offset}"); - } else { - $this->stream->read($offset - $current); - } - } - $this->offset = $offset; - } - /** - * Set the limit of bytes that the decorator allows to be read from the - * stream. - * - * @param int $limit Number of bytes to allow to be read from the stream. - * Use -1 for no limit. - */ - public function setLimit($limit) - { - $this->limit = $limit; - } - public function read($length) - { - if ($this->limit == -1) { - return $this->stream->read($length); - } - // Check if the current position is less than the total allowed - // bytes + original offset - $remaining = $this->offset + $this->limit - $this->stream->tell(); - if ($remaining > 0) { - // Only return the amount of requested data, ensuring that the byte - // limit is not exceeded - return $this->stream->read(\min($remaining, $length)); - } - return ''; - } -} +stream = $stream; + $this->setLimit($limit); + $this->setOffset($offset); + } + public function eof() + { + // Always return true if the underlying stream is EOF + if ($this->stream->eof()) { + return \true; + } + // No limit and the underlying stream is not at EOF + if ($this->limit == -1) { + return \false; + } + return $this->stream->tell() >= $this->offset + $this->limit; + } + /** + * Returns the size of the limited subset of data + * {@inheritdoc} + */ + public function getSize() + { + if (null === ($length = $this->stream->getSize())) { + return null; + } elseif ($this->limit == -1) { + return $length - $this->offset; + } else { + return \min($this->limit, $length - $this->offset); + } + } + /** + * Allow for a bounded seek on the read limited stream + * {@inheritdoc} + */ + public function seek($offset, $whence = \SEEK_SET) + { + if ($whence !== \SEEK_SET || $offset < 0) { + throw new \RuntimeException(\sprintf('Cannot seek to offset %s with whence %s', $offset, $whence)); + } + $offset += $this->offset; + if ($this->limit !== -1) { + if ($offset > $this->offset + $this->limit) { + $offset = $this->offset + $this->limit; + } + } + $this->stream->seek($offset); + } + /** + * Give a relative tell() + * {@inheritdoc} + */ + public function tell() + { + return $this->stream->tell() - $this->offset; + } + /** + * Set the offset to start limiting from + * + * @param int $offset Offset to seek to and begin byte limiting from + * + * @throws \RuntimeException if the stream cannot be seeked. + */ + public function setOffset($offset) + { + $current = $this->stream->tell(); + if ($current !== $offset) { + // If the stream cannot seek to the offset position, then read to it + if ($this->stream->isSeekable()) { + $this->stream->seek($offset); + } elseif ($current > $offset) { + throw new \RuntimeException("Could not seek to stream offset {$offset}"); + } else { + $this->stream->read($offset - $current); + } + } + $this->offset = $offset; + } + /** + * Set the limit of bytes that the decorator allows to be read from the + * stream. + * + * @param int $limit Number of bytes to allow to be read from the stream. + * Use -1 for no limit. + */ + public function setLimit($limit) + { + $this->limit = $limit; + } + public function read($length) + { + if ($this->limit == -1) { + return $this->stream->read($length); + } + // Check if the current position is less than the total allowed + // bytes + original offset + $remaining = $this->offset + $this->limit - $this->stream->tell(); + if ($remaining > 0) { + // Only return the amount of requested data, ensuring that the byte + // limit is not exceeded + return $this->stream->read(\min($remaining, $length)); + } + return ''; + } +} diff --git a/vendor/guzzlehttp/psr7/src/MessageTrait.php b/vendor/guzzlehttp/psr7/src/MessageTrait.php index cdf63fbce..f32e38cc7 100644 --- a/vendor/guzzlehttp/psr7/src/MessageTrait.php +++ b/vendor/guzzlehttp/psr7/src/MessageTrait.php @@ -1,171 +1,171 @@ - array of values */ - private $headers = []; - /** @var array Map of lowercase header name => original name at registration */ - private $headerNames = []; - /** @var string */ - private $protocol = '1.1'; - /** @var StreamInterface */ - private $stream; - public function getProtocolVersion() - { - return $this->protocol; - } - public function withProtocolVersion($version) - { - if ($this->protocol === $version) { - return $this; - } - $new = clone $this; - $new->protocol = $version; - return $new; - } - public function getHeaders() - { - return $this->headers; - } - public function hasHeader($header) - { - return isset($this->headerNames[\strtolower($header)]); - } - public function getHeader($header) - { - $header = \strtolower($header); - if (!isset($this->headerNames[$header])) { - return []; - } - $header = $this->headerNames[$header]; - return $this->headers[$header]; - } - public function getHeaderLine($header) - { - return \implode(', ', $this->getHeader($header)); - } - public function withHeader($header, $value) - { - $this->assertHeader($header); - $value = $this->normalizeHeaderValue($value); - $normalized = \strtolower($header); - $new = clone $this; - if (isset($new->headerNames[$normalized])) { - unset($new->headers[$new->headerNames[$normalized]]); - } - $new->headerNames[$normalized] = $header; - $new->headers[$header] = $value; - return $new; - } - public function withAddedHeader($header, $value) - { - $this->assertHeader($header); - $value = $this->normalizeHeaderValue($value); - $normalized = \strtolower($header); - $new = clone $this; - if (isset($new->headerNames[$normalized])) { - $header = $this->headerNames[$normalized]; - $new->headers[$header] = \array_merge($this->headers[$header], $value); - } else { - $new->headerNames[$normalized] = $header; - $new->headers[$header] = $value; - } - return $new; - } - public function withoutHeader($header) - { - $normalized = \strtolower($header); - if (!isset($this->headerNames[$normalized])) { - return $this; - } - $header = $this->headerNames[$normalized]; - $new = clone $this; - unset($new->headers[$header], $new->headerNames[$normalized]); - return $new; - } - public function getBody() - { - if (!$this->stream) { - $this->stream = stream_for(''); - } - return $this->stream; - } - public function withBody(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $body) - { - if ($body === $this->stream) { - return $this; - } - $new = clone $this; - $new->stream = $body; - return $new; - } - private function setHeaders(array $headers) - { - $this->headerNames = $this->headers = []; - foreach ($headers as $header => $value) { - if (\is_int($header)) { - // Numeric array keys are converted to int by PHP but having a header name '123' is not forbidden by the spec - // and also allowed in withHeader(). So we need to cast it to string again for the following assertion to pass. - $header = (string) $header; - } - $this->assertHeader($header); - $value = $this->normalizeHeaderValue($value); - $normalized = \strtolower($header); - if (isset($this->headerNames[$normalized])) { - $header = $this->headerNames[$normalized]; - $this->headers[$header] = \array_merge($this->headers[$header], $value); - } else { - $this->headerNames[$normalized] = $header; - $this->headers[$header] = $value; - } - } - } - private function normalizeHeaderValue($value) - { - if (!\is_array($value)) { - return $this->trimHeaderValues([$value]); - } - if (\count($value) === 0) { - throw new \InvalidArgumentException('Header value can not be an empty array.'); - } - return $this->trimHeaderValues($value); - } - /** - * Trims whitespace from the header values. - * - * Spaces and tabs ought to be excluded by parsers when extracting the field value from a header field. - * - * header-field = field-name ":" OWS field-value OWS - * OWS = *( SP / HTAB ) - * - * @param string[] $values Header values - * - * @return string[] Trimmed header values - * - * @see https://tools.ietf.org/html/rfc7230#section-3.2.4 - */ - private function trimHeaderValues(array $values) - { - return \array_map(function ($value) { - if (!\is_scalar($value) && null !== $value) { - throw new \InvalidArgumentException(\sprintf('Header value must be scalar or null but %s provided.', \is_object($value) ? \get_class($value) : \gettype($value))); - } - return \trim((string) $value, " \t"); - }, $values); - } - private function assertHeader($header) - { - if (!\is_string($header)) { - throw new \InvalidArgumentException(\sprintf('Header name must be a string but %s provided.', \is_object($header) ? \get_class($header) : \gettype($header))); - } - if ($header === '') { - throw new \InvalidArgumentException('Header name can not be empty.'); - } - } -} + array of values */ + private $headers = []; + /** @var array Map of lowercase header name => original name at registration */ + private $headerNames = []; + /** @var string */ + private $protocol = '1.1'; + /** @var StreamInterface */ + private $stream; + public function getProtocolVersion() + { + return $this->protocol; + } + public function withProtocolVersion($version) + { + if ($this->protocol === $version) { + return $this; + } + $new = clone $this; + $new->protocol = $version; + return $new; + } + public function getHeaders() + { + return $this->headers; + } + public function hasHeader($header) + { + return isset($this->headerNames[\strtolower($header)]); + } + public function getHeader($header) + { + $header = \strtolower($header); + if (!isset($this->headerNames[$header])) { + return []; + } + $header = $this->headerNames[$header]; + return $this->headers[$header]; + } + public function getHeaderLine($header) + { + return \implode(', ', $this->getHeader($header)); + } + public function withHeader($header, $value) + { + $this->assertHeader($header); + $value = $this->normalizeHeaderValue($value); + $normalized = \strtolower($header); + $new = clone $this; + if (isset($new->headerNames[$normalized])) { + unset($new->headers[$new->headerNames[$normalized]]); + } + $new->headerNames[$normalized] = $header; + $new->headers[$header] = $value; + return $new; + } + public function withAddedHeader($header, $value) + { + $this->assertHeader($header); + $value = $this->normalizeHeaderValue($value); + $normalized = \strtolower($header); + $new = clone $this; + if (isset($new->headerNames[$normalized])) { + $header = $this->headerNames[$normalized]; + $new->headers[$header] = \array_merge($this->headers[$header], $value); + } else { + $new->headerNames[$normalized] = $header; + $new->headers[$header] = $value; + } + return $new; + } + public function withoutHeader($header) + { + $normalized = \strtolower($header); + if (!isset($this->headerNames[$normalized])) { + return $this; + } + $header = $this->headerNames[$normalized]; + $new = clone $this; + unset($new->headers[$header], $new->headerNames[$normalized]); + return $new; + } + public function getBody() + { + if (!$this->stream) { + $this->stream = stream_for(''); + } + return $this->stream; + } + public function withBody(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $body) + { + if ($body === $this->stream) { + return $this; + } + $new = clone $this; + $new->stream = $body; + return $new; + } + private function setHeaders(array $headers) + { + $this->headerNames = $this->headers = []; + foreach ($headers as $header => $value) { + if (\is_int($header)) { + // Numeric array keys are converted to int by PHP but having a header name '123' is not forbidden by the spec + // and also allowed in withHeader(). So we need to cast it to string again for the following assertion to pass. + $header = (string) $header; + } + $this->assertHeader($header); + $value = $this->normalizeHeaderValue($value); + $normalized = \strtolower($header); + if (isset($this->headerNames[$normalized])) { + $header = $this->headerNames[$normalized]; + $this->headers[$header] = \array_merge($this->headers[$header], $value); + } else { + $this->headerNames[$normalized] = $header; + $this->headers[$header] = $value; + } + } + } + private function normalizeHeaderValue($value) + { + if (!\is_array($value)) { + return $this->trimHeaderValues([$value]); + } + if (\count($value) === 0) { + throw new \InvalidArgumentException('Header value can not be an empty array.'); + } + return $this->trimHeaderValues($value); + } + /** + * Trims whitespace from the header values. + * + * Spaces and tabs ought to be excluded by parsers when extracting the field value from a header field. + * + * header-field = field-name ":" OWS field-value OWS + * OWS = *( SP / HTAB ) + * + * @param string[] $values Header values + * + * @return string[] Trimmed header values + * + * @see https://tools.ietf.org/html/rfc7230#section-3.2.4 + */ + private function trimHeaderValues(array $values) + { + return \array_map(function ($value) { + if (!\is_scalar($value) && null !== $value) { + throw new \InvalidArgumentException(\sprintf('Header value must be scalar or null but %s provided.', \is_object($value) ? \get_class($value) : \gettype($value))); + } + return \trim((string) $value, " \t"); + }, $values); + } + private function assertHeader($header) + { + if (!\is_string($header)) { + throw new \InvalidArgumentException(\sprintf('Header name must be a string but %s provided.', \is_object($header) ? \get_class($header) : \gettype($header))); + } + if ($header === '') { + throw new \InvalidArgumentException('Header name can not be empty.'); + } + } +} diff --git a/vendor/guzzlehttp/psr7/src/MultipartStream.php b/vendor/guzzlehttp/psr7/src/MultipartStream.php index 2813d1345..55d7b9b03 100644 --- a/vendor/guzzlehttp/psr7/src/MultipartStream.php +++ b/vendor/guzzlehttp/psr7/src/MultipartStream.php @@ -1,123 +1,123 @@ -boundary = $boundary ?: \sha1(\uniqid('', \true)); - $this->stream = $this->createStream($elements); - } - /** - * Get the boundary - * - * @return string - */ - public function getBoundary() - { - return $this->boundary; - } - public function isWritable() - { - return \false; - } - /** - * Get the headers needed before transferring the content of a POST file - */ - private function getHeaders(array $headers) - { - $str = ''; - foreach ($headers as $key => $value) { - $str .= "{$key}: {$value}\r\n"; - } - return "--{$this->boundary}\r\n" . \trim($str) . "\r\n\r\n"; - } - /** - * Create the aggregate stream that will be used to upload the POST data - */ - protected function createStream(array $elements) - { - $stream = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\AppendStream(); - foreach ($elements as $element) { - $this->addElement($stream, $element); - } - // Add the trailing boundary with CRLF - $stream->addStream(stream_for("--{$this->boundary}--\r\n")); - return $stream; - } - private function addElement(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\AppendStream $stream, array $element) - { - foreach (['contents', 'name'] as $key) { - if (!\array_key_exists($key, $element)) { - throw new \InvalidArgumentException("A '{$key}' key is required"); - } - } - $element['contents'] = stream_for($element['contents']); - if (empty($element['filename'])) { - $uri = $element['contents']->getMetadata('uri'); - if (\substr($uri, 0, 6) !== 'php://') { - $element['filename'] = $uri; - } - } - list($body, $headers) = $this->createElement($element['name'], $element['contents'], isset($element['filename']) ? $element['filename'] : null, isset($element['headers']) ? $element['headers'] : []); - $stream->addStream(stream_for($this->getHeaders($headers))); - $stream->addStream($body); - $stream->addStream(stream_for("\r\n")); - } - /** - * @return array - */ - private function createElement($name, \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, $filename, array $headers) - { - // Set a default content-disposition header if one was no provided - $disposition = $this->getHeader($headers, 'content-disposition'); - if (!$disposition) { - $headers['Content-Disposition'] = $filename === '0' || $filename ? \sprintf('form-data; name="%s"; filename="%s"', $name, \basename($filename)) : "form-data; name=\"{$name}\""; - } - // Set a default content-length header if one was no provided - $length = $this->getHeader($headers, 'content-length'); - if (!$length) { - if ($length = $stream->getSize()) { - $headers['Content-Length'] = (string) $length; - } - } - // Set a default Content-Type if one was not supplied - $type = $this->getHeader($headers, 'content-type'); - if (!$type && ($filename === '0' || $filename)) { - if ($type = mimetype_from_filename($filename)) { - $headers['Content-Type'] = $type; - } - } - return [$stream, $headers]; - } - private function getHeader(array $headers, $key) - { - $lowercaseHeader = \strtolower($key); - foreach ($headers as $k => $v) { - if (\strtolower($k) === $lowercaseHeader) { - return $v; - } - } - return null; - } -} +boundary = $boundary ?: \sha1(\uniqid('', \true)); + $this->stream = $this->createStream($elements); + } + /** + * Get the boundary + * + * @return string + */ + public function getBoundary() + { + return $this->boundary; + } + public function isWritable() + { + return \false; + } + /** + * Get the headers needed before transferring the content of a POST file + */ + private function getHeaders(array $headers) + { + $str = ''; + foreach ($headers as $key => $value) { + $str .= "{$key}: {$value}\r\n"; + } + return "--{$this->boundary}\r\n" . \trim($str) . "\r\n\r\n"; + } + /** + * Create the aggregate stream that will be used to upload the POST data + */ + protected function createStream(array $elements) + { + $stream = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\AppendStream(); + foreach ($elements as $element) { + $this->addElement($stream, $element); + } + // Add the trailing boundary with CRLF + $stream->addStream(stream_for("--{$this->boundary}--\r\n")); + return $stream; + } + private function addElement(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\AppendStream $stream, array $element) + { + foreach (['contents', 'name'] as $key) { + if (!\array_key_exists($key, $element)) { + throw new \InvalidArgumentException("A '{$key}' key is required"); + } + } + $element['contents'] = stream_for($element['contents']); + if (empty($element['filename'])) { + $uri = $element['contents']->getMetadata('uri'); + if (\substr($uri, 0, 6) !== 'php://') { + $element['filename'] = $uri; + } + } + list($body, $headers) = $this->createElement($element['name'], $element['contents'], isset($element['filename']) ? $element['filename'] : null, isset($element['headers']) ? $element['headers'] : []); + $stream->addStream(stream_for($this->getHeaders($headers))); + $stream->addStream($body); + $stream->addStream(stream_for("\r\n")); + } + /** + * @return array + */ + private function createElement($name, \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, $filename, array $headers) + { + // Set a default content-disposition header if one was no provided + $disposition = $this->getHeader($headers, 'content-disposition'); + if (!$disposition) { + $headers['Content-Disposition'] = $filename === '0' || $filename ? \sprintf('form-data; name="%s"; filename="%s"', $name, \basename($filename)) : "form-data; name=\"{$name}\""; + } + // Set a default content-length header if one was no provided + $length = $this->getHeader($headers, 'content-length'); + if (!$length) { + if ($length = $stream->getSize()) { + $headers['Content-Length'] = (string) $length; + } + } + // Set a default Content-Type if one was not supplied + $type = $this->getHeader($headers, 'content-type'); + if (!$type && ($filename === '0' || $filename)) { + if ($type = mimetype_from_filename($filename)) { + $headers['Content-Type'] = $type; + } + } + return [$stream, $headers]; + } + private function getHeader(array $headers, $key) + { + $lowercaseHeader = \strtolower($key); + foreach ($headers as $k => $v) { + if (\strtolower($k) === $lowercaseHeader) { + return $v; + } + } + return null; + } +} diff --git a/vendor/guzzlehttp/psr7/src/NoSeekStream.php b/vendor/guzzlehttp/psr7/src/NoSeekStream.php index 070e7b6cd..c1fe05cbc 100644 --- a/vendor/guzzlehttp/psr7/src/NoSeekStream.php +++ b/vendor/guzzlehttp/psr7/src/NoSeekStream.php @@ -1,20 +1,20 @@ -source = $source; - $this->size = isset($options['size']) ? $options['size'] : null; - $this->metadata = isset($options['metadata']) ? $options['metadata'] : []; - $this->buffer = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\BufferStream(); - } - public function __toString() - { - try { - return copy_to_string($this); - } catch (\Exception $e) { - return ''; - } - } - public function close() - { - $this->detach(); - } - public function detach() - { - $this->tellPos = \false; - $this->source = null; - } - public function getSize() - { - return $this->size; - } - public function tell() - { - return $this->tellPos; - } - public function eof() - { - return !$this->source; - } - public function isSeekable() - { - return \false; - } - public function rewind() - { - $this->seek(0); - } - public function seek($offset, $whence = \SEEK_SET) - { - throw new \RuntimeException('Cannot seek a PumpStream'); - } - public function isWritable() - { - return \false; - } - public function write($string) - { - throw new \RuntimeException('Cannot write to a PumpStream'); - } - public function isReadable() - { - return \true; - } - public function read($length) - { - $data = $this->buffer->read($length); - $readLen = \strlen($data); - $this->tellPos += $readLen; - $remaining = $length - $readLen; - if ($remaining) { - $this->pump($remaining); - $data .= $this->buffer->read($remaining); - $this->tellPos += \strlen($data) - $readLen; - } - return $data; - } - public function getContents() - { - $result = ''; - while (!$this->eof()) { - $result .= $this->read(1000000); - } - return $result; - } - public function getMetadata($key = null) - { - if (!$key) { - return $this->metadata; - } - return isset($this->metadata[$key]) ? $this->metadata[$key] : null; - } - private function pump($length) - { - if ($this->source) { - do { - $data = \call_user_func($this->source, $length); - if ($data === \false || $data === null) { - $this->source = null; - return; - } - $this->buffer->write($data); - $length -= \strlen($data); - } while ($length > 0); - } - } -} +source = $source; + $this->size = isset($options['size']) ? $options['size'] : null; + $this->metadata = isset($options['metadata']) ? $options['metadata'] : []; + $this->buffer = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\BufferStream(); + } + public function __toString() + { + try { + return copy_to_string($this); + } catch (\Exception $e) { + return ''; + } + } + public function close() + { + $this->detach(); + } + public function detach() + { + $this->tellPos = \false; + $this->source = null; + } + public function getSize() + { + return $this->size; + } + public function tell() + { + return $this->tellPos; + } + public function eof() + { + return !$this->source; + } + public function isSeekable() + { + return \false; + } + public function rewind() + { + $this->seek(0); + } + public function seek($offset, $whence = \SEEK_SET) + { + throw new \RuntimeException('Cannot seek a PumpStream'); + } + public function isWritable() + { + return \false; + } + public function write($string) + { + throw new \RuntimeException('Cannot write to a PumpStream'); + } + public function isReadable() + { + return \true; + } + public function read($length) + { + $data = $this->buffer->read($length); + $readLen = \strlen($data); + $this->tellPos += $readLen; + $remaining = $length - $readLen; + if ($remaining) { + $this->pump($remaining); + $data .= $this->buffer->read($remaining); + $this->tellPos += \strlen($data) - $readLen; + } + return $data; + } + public function getContents() + { + $result = ''; + while (!$this->eof()) { + $result .= $this->read(1000000); + } + return $result; + } + public function getMetadata($key = null) + { + if (!$key) { + return $this->metadata; + } + return isset($this->metadata[$key]) ? $this->metadata[$key] : null; + } + private function pump($length) + { + if ($this->source) { + do { + $data = \call_user_func($this->source, $length); + if ($data === \false || $data === null) { + $this->source = null; + return; + } + $this->buffer->write($data); + $length -= \strlen($data); + } while ($length > 0); + } + } +} diff --git a/vendor/guzzlehttp/psr7/src/Request.php b/vendor/guzzlehttp/psr7/src/Request.php index 0889cb6a9..3190783e5 100644 --- a/vendor/guzzlehttp/psr7/src/Request.php +++ b/vendor/guzzlehttp/psr7/src/Request.php @@ -1,120 +1,120 @@ -assertMethod($method); - if (!$uri instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface) { - $uri = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri($uri); - } - $this->method = \strtoupper($method); - $this->uri = $uri; - $this->setHeaders($headers); - $this->protocol = $version; - if (!isset($this->headerNames['host'])) { - $this->updateHostFromUri(); - } - if ($body !== '' && $body !== null) { - $this->stream = stream_for($body); - } - } - public function getRequestTarget() - { - if ($this->requestTarget !== null) { - return $this->requestTarget; - } - $target = $this->uri->getPath(); - if ($target == '') { - $target = '/'; - } - if ($this->uri->getQuery() != '') { - $target .= '?' . $this->uri->getQuery(); - } - return $target; - } - public function withRequestTarget($requestTarget) - { - if (\preg_match('#\\s#', $requestTarget)) { - throw new \InvalidArgumentException('Invalid request target provided; cannot contain whitespace'); - } - $new = clone $this; - $new->requestTarget = $requestTarget; - return $new; - } - public function getMethod() - { - return $this->method; - } - public function withMethod($method) - { - $this->assertMethod($method); - $new = clone $this; - $new->method = \strtoupper($method); - return $new; - } - public function getUri() - { - return $this->uri; - } - public function withUri(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, $preserveHost = \false) - { - if ($uri === $this->uri) { - return $this; - } - $new = clone $this; - $new->uri = $uri; - if (!$preserveHost || !isset($this->headerNames['host'])) { - $new->updateHostFromUri(); - } - return $new; - } - private function updateHostFromUri() - { - $host = $this->uri->getHost(); - if ($host == '') { - return; - } - if (($port = $this->uri->getPort()) !== null) { - $host .= ':' . $port; - } - if (isset($this->headerNames['host'])) { - $header = $this->headerNames['host']; - } else { - $header = 'Host'; - $this->headerNames['host'] = 'Host'; - } - // Ensure Host is the first header. - // See: http://tools.ietf.org/html/rfc7230#section-5.4 - $this->headers = [$header => [$host]] + $this->headers; - } - private function assertMethod($method) - { - if (!\is_string($method) || $method === '') { - throw new \InvalidArgumentException('Method must be a non-empty string.'); - } - } -} +assertMethod($method); + if (!$uri instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface) { + $uri = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri($uri); + } + $this->method = \strtoupper($method); + $this->uri = $uri; + $this->setHeaders($headers); + $this->protocol = $version; + if (!isset($this->headerNames['host'])) { + $this->updateHostFromUri(); + } + if ($body !== '' && $body !== null) { + $this->stream = stream_for($body); + } + } + public function getRequestTarget() + { + if ($this->requestTarget !== null) { + return $this->requestTarget; + } + $target = $this->uri->getPath(); + if ($target == '') { + $target = '/'; + } + if ($this->uri->getQuery() != '') { + $target .= '?' . $this->uri->getQuery(); + } + return $target; + } + public function withRequestTarget($requestTarget) + { + if (\preg_match('#\\s#', $requestTarget)) { + throw new \InvalidArgumentException('Invalid request target provided; cannot contain whitespace'); + } + $new = clone $this; + $new->requestTarget = $requestTarget; + return $new; + } + public function getMethod() + { + return $this->method; + } + public function withMethod($method) + { + $this->assertMethod($method); + $new = clone $this; + $new->method = \strtoupper($method); + return $new; + } + public function getUri() + { + return $this->uri; + } + public function withUri(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, $preserveHost = \false) + { + if ($uri === $this->uri) { + return $this; + } + $new = clone $this; + $new->uri = $uri; + if (!$preserveHost || !isset($this->headerNames['host'])) { + $new->updateHostFromUri(); + } + return $new; + } + private function updateHostFromUri() + { + $host = $this->uri->getHost(); + if ($host == '') { + return; + } + if (($port = $this->uri->getPort()) !== null) { + $host .= ':' . $port; + } + if (isset($this->headerNames['host'])) { + $header = $this->headerNames['host']; + } else { + $header = 'Host'; + $this->headerNames['host'] = 'Host'; + } + // Ensure Host is the first header. + // See: http://tools.ietf.org/html/rfc7230#section-5.4 + $this->headers = [$header => [$host]] + $this->headers; + } + private function assertMethod($method) + { + if (!\is_string($method) || $method === '') { + throw new \InvalidArgumentException('Method must be a non-empty string.'); + } + } +} diff --git a/vendor/guzzlehttp/psr7/src/Response.php b/vendor/guzzlehttp/psr7/src/Response.php index c00d42ac6..55c6cb6b6 100644 --- a/vendor/guzzlehttp/psr7/src/Response.php +++ b/vendor/guzzlehttp/psr7/src/Response.php @@ -1,76 +1,76 @@ - 'Continue', 101 => 'Switching Protocols', 102 => 'Processing', 200 => 'OK', 201 => 'Created', 202 => 'Accepted', 203 => 'Non-Authoritative Information', 204 => 'No Content', 205 => 'Reset Content', 206 => 'Partial Content', 207 => 'Multi-status', 208 => 'Already Reported', 300 => 'Multiple Choices', 301 => 'Moved Permanently', 302 => 'Found', 303 => 'See Other', 304 => 'Not Modified', 305 => 'Use Proxy', 306 => 'Switch Proxy', 307 => 'Temporary Redirect', 400 => 'Bad Request', 401 => 'Unauthorized', 402 => 'Payment Required', 403 => 'Forbidden', 404 => 'Not Found', 405 => 'Method Not Allowed', 406 => 'Not Acceptable', 407 => 'Proxy Authentication Required', 408 => 'Request Time-out', 409 => 'Conflict', 410 => 'Gone', 411 => 'Length Required', 412 => 'Precondition Failed', 413 => 'Request Entity Too Large', 414 => 'Request-URI Too Large', 415 => 'Unsupported Media Type', 416 => 'Requested range not satisfiable', 417 => 'Expectation Failed', 418 => 'I\'m a teapot', 422 => 'Unprocessable Entity', 423 => 'Locked', 424 => 'Failed Dependency', 425 => 'Unordered Collection', 426 => 'Upgrade Required', 428 => 'Precondition Required', 429 => 'Too Many Requests', 431 => 'Request Header Fields Too Large', 451 => 'Unavailable For Legal Reasons', 500 => 'Internal Server Error', 501 => 'Not Implemented', 502 => 'Bad Gateway', 503 => 'Service Unavailable', 504 => 'Gateway Time-out', 505 => 'HTTP Version not supported', 506 => 'Variant Also Negotiates', 507 => 'Insufficient Storage', 508 => 'Loop Detected', 511 => 'Network Authentication Required']; - /** @var string */ - private $reasonPhrase = ''; - /** @var int */ - private $statusCode = 200; - /** - * @param int $status Status code - * @param array $headers Response headers - * @param string|null|resource|StreamInterface $body Response body - * @param string $version Protocol version - * @param string|null $reason Reason phrase (when empty a default will be used based on the status code) - */ - public function __construct($status = 200, array $headers = [], $body = null, $version = '1.1', $reason = null) - { - $this->assertStatusCodeIsInteger($status); - $status = (int) $status; - $this->assertStatusCodeRange($status); - $this->statusCode = $status; - if ($body !== '' && $body !== null) { - $this->stream = stream_for($body); - } - $this->setHeaders($headers); - if ($reason == '' && isset(self::$phrases[$this->statusCode])) { - $this->reasonPhrase = self::$phrases[$this->statusCode]; - } else { - $this->reasonPhrase = (string) $reason; - } - $this->protocol = $version; - } - public function getStatusCode() - { - return $this->statusCode; - } - public function getReasonPhrase() - { - return $this->reasonPhrase; - } - public function withStatus($code, $reasonPhrase = '') - { - $this->assertStatusCodeIsInteger($code); - $code = (int) $code; - $this->assertStatusCodeRange($code); - $new = clone $this; - $new->statusCode = $code; - if ($reasonPhrase == '' && isset(self::$phrases[$new->statusCode])) { - $reasonPhrase = self::$phrases[$new->statusCode]; - } - $new->reasonPhrase = $reasonPhrase; - return $new; - } - private function assertStatusCodeIsInteger($statusCode) - { - if (\filter_var($statusCode, \FILTER_VALIDATE_INT) === \false) { - throw new \InvalidArgumentException('Status code must be an integer value.'); - } - } - private function assertStatusCodeRange($statusCode) - { - if ($statusCode < 100 || $statusCode >= 600) { - throw new \InvalidArgumentException('Status code must be an integer value between 1xx and 5xx.'); - } - } -} + 'Continue', 101 => 'Switching Protocols', 102 => 'Processing', 200 => 'OK', 201 => 'Created', 202 => 'Accepted', 203 => 'Non-Authoritative Information', 204 => 'No Content', 205 => 'Reset Content', 206 => 'Partial Content', 207 => 'Multi-status', 208 => 'Already Reported', 300 => 'Multiple Choices', 301 => 'Moved Permanently', 302 => 'Found', 303 => 'See Other', 304 => 'Not Modified', 305 => 'Use Proxy', 306 => 'Switch Proxy', 307 => 'Temporary Redirect', 400 => 'Bad Request', 401 => 'Unauthorized', 402 => 'Payment Required', 403 => 'Forbidden', 404 => 'Not Found', 405 => 'Method Not Allowed', 406 => 'Not Acceptable', 407 => 'Proxy Authentication Required', 408 => 'Request Time-out', 409 => 'Conflict', 410 => 'Gone', 411 => 'Length Required', 412 => 'Precondition Failed', 413 => 'Request Entity Too Large', 414 => 'Request-URI Too Large', 415 => 'Unsupported Media Type', 416 => 'Requested range not satisfiable', 417 => 'Expectation Failed', 418 => 'I\'m a teapot', 422 => 'Unprocessable Entity', 423 => 'Locked', 424 => 'Failed Dependency', 425 => 'Unordered Collection', 426 => 'Upgrade Required', 428 => 'Precondition Required', 429 => 'Too Many Requests', 431 => 'Request Header Fields Too Large', 451 => 'Unavailable For Legal Reasons', 500 => 'Internal Server Error', 501 => 'Not Implemented', 502 => 'Bad Gateway', 503 => 'Service Unavailable', 504 => 'Gateway Time-out', 505 => 'HTTP Version not supported', 506 => 'Variant Also Negotiates', 507 => 'Insufficient Storage', 508 => 'Loop Detected', 511 => 'Network Authentication Required']; + /** @var string */ + private $reasonPhrase = ''; + /** @var int */ + private $statusCode = 200; + /** + * @param int $status Status code + * @param array $headers Response headers + * @param string|null|resource|StreamInterface $body Response body + * @param string $version Protocol version + * @param string|null $reason Reason phrase (when empty a default will be used based on the status code) + */ + public function __construct($status = 200, array $headers = [], $body = null, $version = '1.1', $reason = null) + { + $this->assertStatusCodeIsInteger($status); + $status = (int) $status; + $this->assertStatusCodeRange($status); + $this->statusCode = $status; + if ($body !== '' && $body !== null) { + $this->stream = stream_for($body); + } + $this->setHeaders($headers); + if ($reason == '' && isset(self::$phrases[$this->statusCode])) { + $this->reasonPhrase = self::$phrases[$this->statusCode]; + } else { + $this->reasonPhrase = (string) $reason; + } + $this->protocol = $version; + } + public function getStatusCode() + { + return $this->statusCode; + } + public function getReasonPhrase() + { + return $this->reasonPhrase; + } + public function withStatus($code, $reasonPhrase = '') + { + $this->assertStatusCodeIsInteger($code); + $code = (int) $code; + $this->assertStatusCodeRange($code); + $new = clone $this; + $new->statusCode = $code; + if ($reasonPhrase == '' && isset(self::$phrases[$new->statusCode])) { + $reasonPhrase = self::$phrases[$new->statusCode]; + } + $new->reasonPhrase = $reasonPhrase; + return $new; + } + private function assertStatusCodeIsInteger($statusCode) + { + if (\filter_var($statusCode, \FILTER_VALIDATE_INT) === \false) { + throw new \InvalidArgumentException('Status code must be an integer value.'); + } + } + private function assertStatusCodeRange($statusCode) + { + if ($statusCode < 100 || $statusCode >= 600) { + throw new \InvalidArgumentException('Status code must be an integer value between 1xx and 5xx.'); + } + } +} diff --git a/vendor/guzzlehttp/psr7/src/Rfc7230.php b/vendor/guzzlehttp/psr7/src/Rfc7230.php index af28bb696..dcb85eccb 100644 --- a/vendor/guzzlehttp/psr7/src/Rfc7230.php +++ b/vendor/guzzlehttp/psr7/src/Rfc7230.php @@ -1,18 +1,18 @@ -@,;:\\\"/[\\]?={}\1- ]++):[ \t]*+((?:[ \t]*+[!-~€-ÿ]++)*+)[ \t]*+\r?\n)m"; - const HEADER_FOLD_REGEX = "(\r?\n[ \t]++)"; -} +@,;:\\\"/[\\]?={}\1- ]++):[ \t]*+((?:[ \t]*+[!-~€-ÿ]++)*+)[ \t]*+\r?\n)m"; + const HEADER_FOLD_REGEX = "(\r?\n[ \t]++)"; +} diff --git a/vendor/guzzlehttp/psr7/src/ServerRequest.php b/vendor/guzzlehttp/psr7/src/ServerRequest.php index cf41f7cba..379a0c858 100644 --- a/vendor/guzzlehttp/psr7/src/ServerRequest.php +++ b/vendor/guzzlehttp/psr7/src/ServerRequest.php @@ -1,302 +1,302 @@ -serverParams = $serverParams; - parent::__construct($method, $uri, $headers, $body, $version); - } - /** - * Return an UploadedFile instance array. - * - * @param array $files A array which respect $_FILES structure - * @throws InvalidArgumentException for unrecognized values - * @return array - */ - public static function normalizeFiles(array $files) - { - $normalized = []; - foreach ($files as $key => $value) { - if ($value instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\UploadedFileInterface) { - $normalized[$key] = $value; - } elseif (\is_array($value) && isset($value['tmp_name'])) { - $normalized[$key] = self::createUploadedFileFromSpec($value); - } elseif (\is_array($value)) { - $normalized[$key] = self::normalizeFiles($value); - continue; - } else { - throw new \InvalidArgumentException('Invalid value in files specification'); - } - } - return $normalized; - } - /** - * Create and return an UploadedFile instance from a $_FILES specification. - * - * If the specification represents an array of values, this method will - * delegate to normalizeNestedFileSpec() and return that return value. - * - * @param array $value $_FILES struct - * @return array|UploadedFileInterface - */ - private static function createUploadedFileFromSpec(array $value) - { - if (\is_array($value['tmp_name'])) { - return self::normalizeNestedFileSpec($value); - } - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UploadedFile($value['tmp_name'], (int) $value['size'], (int) $value['error'], $value['name'], $value['type']); - } - /** - * Normalize an array of file specifications. - * - * Loops through all nested files and returns a normalized array of - * UploadedFileInterface instances. - * - * @param array $files - * @return UploadedFileInterface[] - */ - private static function normalizeNestedFileSpec(array $files = []) - { - $normalizedFiles = []; - foreach (\array_keys($files['tmp_name']) as $key) { - $spec = ['tmp_name' => $files['tmp_name'][$key], 'size' => $files['size'][$key], 'error' => $files['error'][$key], 'name' => $files['name'][$key], 'type' => $files['type'][$key]]; - $normalizedFiles[$key] = self::createUploadedFileFromSpec($spec); - } - return $normalizedFiles; - } - /** - * Return a ServerRequest populated with superglobals: - * $_GET - * $_POST - * $_COOKIE - * $_FILES - * $_SERVER - * - * @return ServerRequestInterface - */ - public static function fromGlobals() - { - $method = isset($_SERVER['REQUEST_METHOD']) ? $_SERVER['REQUEST_METHOD'] : 'GET'; - $headers = getallheaders(); - $uri = self::getUriFromGlobals(); - $body = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\CachingStream(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LazyOpenStream('php://input', 'r+')); - $protocol = isset($_SERVER['SERVER_PROTOCOL']) ? \str_replace('HTTP/', '', $_SERVER['SERVER_PROTOCOL']) : '1.1'; - $serverRequest = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\ServerRequest($method, $uri, $headers, $body, $protocol, $_SERVER); - return $serverRequest->withCookieParams($_COOKIE)->withQueryParams($_GET)->withParsedBody($_POST)->withUploadedFiles(self::normalizeFiles($_FILES)); - } - private static function extractHostAndPortFromAuthority($authority) - { - $uri = 'http://' . $authority; - $parts = \parse_url($uri); - if (\false === $parts) { - return [null, null]; - } - $host = isset($parts['host']) ? $parts['host'] : null; - $port = isset($parts['port']) ? $parts['port'] : null; - return [$host, $port]; - } - /** - * Get a Uri populated with values from $_SERVER. - * - * @return UriInterface - */ - public static function getUriFromGlobals() - { - $uri = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri(''); - $uri = $uri->withScheme(!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' ? 'https' : 'http'); - $hasPort = \false; - if (isset($_SERVER['HTTP_HOST'])) { - list($host, $port) = self::extractHostAndPortFromAuthority($_SERVER['HTTP_HOST']); - if ($host !== null) { - $uri = $uri->withHost($host); - } - if ($port !== null) { - $hasPort = \true; - $uri = $uri->withPort($port); - } - } elseif (isset($_SERVER['SERVER_NAME'])) { - $uri = $uri->withHost($_SERVER['SERVER_NAME']); - } elseif (isset($_SERVER['SERVER_ADDR'])) { - $uri = $uri->withHost($_SERVER['SERVER_ADDR']); - } - if (!$hasPort && isset($_SERVER['SERVER_PORT'])) { - $uri = $uri->withPort($_SERVER['SERVER_PORT']); - } - $hasQuery = \false; - if (isset($_SERVER['REQUEST_URI'])) { - $requestUriParts = \explode('?', $_SERVER['REQUEST_URI'], 2); - $uri = $uri->withPath($requestUriParts[0]); - if (isset($requestUriParts[1])) { - $hasQuery = \true; - $uri = $uri->withQuery($requestUriParts[1]); - } - } - if (!$hasQuery && isset($_SERVER['QUERY_STRING'])) { - $uri = $uri->withQuery($_SERVER['QUERY_STRING']); - } - return $uri; - } - /** - * {@inheritdoc} - */ - public function getServerParams() - { - return $this->serverParams; - } - /** - * {@inheritdoc} - */ - public function getUploadedFiles() - { - return $this->uploadedFiles; - } - /** - * {@inheritdoc} - */ - public function withUploadedFiles(array $uploadedFiles) - { - $new = clone $this; - $new->uploadedFiles = $uploadedFiles; - return $new; - } - /** - * {@inheritdoc} - */ - public function getCookieParams() - { - return $this->cookieParams; - } - /** - * {@inheritdoc} - */ - public function withCookieParams(array $cookies) - { - $new = clone $this; - $new->cookieParams = $cookies; - return $new; - } - /** - * {@inheritdoc} - */ - public function getQueryParams() - { - return $this->queryParams; - } - /** - * {@inheritdoc} - */ - public function withQueryParams(array $query) - { - $new = clone $this; - $new->queryParams = $query; - return $new; - } - /** - * {@inheritdoc} - */ - public function getParsedBody() - { - return $this->parsedBody; - } - /** - * {@inheritdoc} - */ - public function withParsedBody($data) - { - $new = clone $this; - $new->parsedBody = $data; - return $new; - } - /** - * {@inheritdoc} - */ - public function getAttributes() - { - return $this->attributes; - } - /** - * {@inheritdoc} - */ - public function getAttribute($attribute, $default = null) - { - if (\false === \array_key_exists($attribute, $this->attributes)) { - return $default; - } - return $this->attributes[$attribute]; - } - /** - * {@inheritdoc} - */ - public function withAttribute($attribute, $value) - { - $new = clone $this; - $new->attributes[$attribute] = $value; - return $new; - } - /** - * {@inheritdoc} - */ - public function withoutAttribute($attribute) - { - if (\false === \array_key_exists($attribute, $this->attributes)) { - return $this; - } - $new = clone $this; - unset($new->attributes[$attribute]); - return $new; - } -} +serverParams = $serverParams; + parent::__construct($method, $uri, $headers, $body, $version); + } + /** + * Return an UploadedFile instance array. + * + * @param array $files A array which respect $_FILES structure + * @throws InvalidArgumentException for unrecognized values + * @return array + */ + public static function normalizeFiles(array $files) + { + $normalized = []; + foreach ($files as $key => $value) { + if ($value instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\UploadedFileInterface) { + $normalized[$key] = $value; + } elseif (\is_array($value) && isset($value['tmp_name'])) { + $normalized[$key] = self::createUploadedFileFromSpec($value); + } elseif (\is_array($value)) { + $normalized[$key] = self::normalizeFiles($value); + continue; + } else { + throw new \InvalidArgumentException('Invalid value in files specification'); + } + } + return $normalized; + } + /** + * Create and return an UploadedFile instance from a $_FILES specification. + * + * If the specification represents an array of values, this method will + * delegate to normalizeNestedFileSpec() and return that return value. + * + * @param array $value $_FILES struct + * @return array|UploadedFileInterface + */ + private static function createUploadedFileFromSpec(array $value) + { + if (\is_array($value['tmp_name'])) { + return self::normalizeNestedFileSpec($value); + } + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UploadedFile($value['tmp_name'], (int) $value['size'], (int) $value['error'], $value['name'], $value['type']); + } + /** + * Normalize an array of file specifications. + * + * Loops through all nested files and returns a normalized array of + * UploadedFileInterface instances. + * + * @param array $files + * @return UploadedFileInterface[] + */ + private static function normalizeNestedFileSpec(array $files = []) + { + $normalizedFiles = []; + foreach (\array_keys($files['tmp_name']) as $key) { + $spec = ['tmp_name' => $files['tmp_name'][$key], 'size' => $files['size'][$key], 'error' => $files['error'][$key], 'name' => $files['name'][$key], 'type' => $files['type'][$key]]; + $normalizedFiles[$key] = self::createUploadedFileFromSpec($spec); + } + return $normalizedFiles; + } + /** + * Return a ServerRequest populated with superglobals: + * $_GET + * $_POST + * $_COOKIE + * $_FILES + * $_SERVER + * + * @return ServerRequestInterface + */ + public static function fromGlobals() + { + $method = isset($_SERVER['REQUEST_METHOD']) ? $_SERVER['REQUEST_METHOD'] : 'GET'; + $headers = getallheaders(); + $uri = self::getUriFromGlobals(); + $body = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\CachingStream(new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LazyOpenStream('php://input', 'r+')); + $protocol = isset($_SERVER['SERVER_PROTOCOL']) ? \str_replace('HTTP/', '', $_SERVER['SERVER_PROTOCOL']) : '1.1'; + $serverRequest = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\ServerRequest($method, $uri, $headers, $body, $protocol, $_SERVER); + return $serverRequest->withCookieParams($_COOKIE)->withQueryParams($_GET)->withParsedBody($_POST)->withUploadedFiles(self::normalizeFiles($_FILES)); + } + private static function extractHostAndPortFromAuthority($authority) + { + $uri = 'http://' . $authority; + $parts = \parse_url($uri); + if (\false === $parts) { + return [null, null]; + } + $host = isset($parts['host']) ? $parts['host'] : null; + $port = isset($parts['port']) ? $parts['port'] : null; + return [$host, $port]; + } + /** + * Get a Uri populated with values from $_SERVER. + * + * @return UriInterface + */ + public static function getUriFromGlobals() + { + $uri = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri(''); + $uri = $uri->withScheme(!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' ? 'https' : 'http'); + $hasPort = \false; + if (isset($_SERVER['HTTP_HOST'])) { + list($host, $port) = self::extractHostAndPortFromAuthority($_SERVER['HTTP_HOST']); + if ($host !== null) { + $uri = $uri->withHost($host); + } + if ($port !== null) { + $hasPort = \true; + $uri = $uri->withPort($port); + } + } elseif (isset($_SERVER['SERVER_NAME'])) { + $uri = $uri->withHost($_SERVER['SERVER_NAME']); + } elseif (isset($_SERVER['SERVER_ADDR'])) { + $uri = $uri->withHost($_SERVER['SERVER_ADDR']); + } + if (!$hasPort && isset($_SERVER['SERVER_PORT'])) { + $uri = $uri->withPort($_SERVER['SERVER_PORT']); + } + $hasQuery = \false; + if (isset($_SERVER['REQUEST_URI'])) { + $requestUriParts = \explode('?', $_SERVER['REQUEST_URI'], 2); + $uri = $uri->withPath($requestUriParts[0]); + if (isset($requestUriParts[1])) { + $hasQuery = \true; + $uri = $uri->withQuery($requestUriParts[1]); + } + } + if (!$hasQuery && isset($_SERVER['QUERY_STRING'])) { + $uri = $uri->withQuery($_SERVER['QUERY_STRING']); + } + return $uri; + } + /** + * {@inheritdoc} + */ + public function getServerParams() + { + return $this->serverParams; + } + /** + * {@inheritdoc} + */ + public function getUploadedFiles() + { + return $this->uploadedFiles; + } + /** + * {@inheritdoc} + */ + public function withUploadedFiles(array $uploadedFiles) + { + $new = clone $this; + $new->uploadedFiles = $uploadedFiles; + return $new; + } + /** + * {@inheritdoc} + */ + public function getCookieParams() + { + return $this->cookieParams; + } + /** + * {@inheritdoc} + */ + public function withCookieParams(array $cookies) + { + $new = clone $this; + $new->cookieParams = $cookies; + return $new; + } + /** + * {@inheritdoc} + */ + public function getQueryParams() + { + return $this->queryParams; + } + /** + * {@inheritdoc} + */ + public function withQueryParams(array $query) + { + $new = clone $this; + $new->queryParams = $query; + return $new; + } + /** + * {@inheritdoc} + */ + public function getParsedBody() + { + return $this->parsedBody; + } + /** + * {@inheritdoc} + */ + public function withParsedBody($data) + { + $new = clone $this; + $new->parsedBody = $data; + return $new; + } + /** + * {@inheritdoc} + */ + public function getAttributes() + { + return $this->attributes; + } + /** + * {@inheritdoc} + */ + public function getAttribute($attribute, $default = null) + { + if (\false === \array_key_exists($attribute, $this->attributes)) { + return $default; + } + return $this->attributes[$attribute]; + } + /** + * {@inheritdoc} + */ + public function withAttribute($attribute, $value) + { + $new = clone $this; + $new->attributes[$attribute] = $value; + return $new; + } + /** + * {@inheritdoc} + */ + public function withoutAttribute($attribute) + { + if (\false === \array_key_exists($attribute, $this->attributes)) { + return $this; + } + $new = clone $this; + unset($new->attributes[$attribute]); + return $new; + } +} diff --git a/vendor/guzzlehttp/psr7/src/Stream.php b/vendor/guzzlehttp/psr7/src/Stream.php index e86b31b17..e1e5184b5 100644 --- a/vendor/guzzlehttp/psr7/src/Stream.php +++ b/vendor/guzzlehttp/psr7/src/Stream.php @@ -1,221 +1,221 @@ -size = $options['size']; - } - $this->customMetadata = isset($options['metadata']) ? $options['metadata'] : []; - $this->stream = $stream; - $meta = \stream_get_meta_data($this->stream); - $this->seekable = $meta['seekable']; - $this->readable = (bool) \preg_match(self::READABLE_MODES, $meta['mode']); - $this->writable = (bool) \preg_match(self::WRITABLE_MODES, $meta['mode']); - $this->uri = $this->getMetadata('uri'); - } - /** - * Closes the stream when the destructed - */ - public function __destruct() - { - $this->close(); - } - public function __toString() - { - try { - $this->seek(0); - return (string) \stream_get_contents($this->stream); - } catch (\Exception $e) { - return ''; - } - } - public function getContents() - { - if (!isset($this->stream)) { - throw new \RuntimeException('Stream is detached'); - } - $contents = \stream_get_contents($this->stream); - if ($contents === \false) { - throw new \RuntimeException('Unable to read stream contents'); - } - return $contents; - } - public function close() - { - if (isset($this->stream)) { - if (\is_resource($this->stream)) { - \fclose($this->stream); - } - $this->detach(); - } - } - public function detach() - { - if (!isset($this->stream)) { - return null; - } - $result = $this->stream; - unset($this->stream); - $this->size = $this->uri = null; - $this->readable = $this->writable = $this->seekable = \false; - return $result; - } - public function getSize() - { - if ($this->size !== null) { - return $this->size; - } - if (!isset($this->stream)) { - return null; - } - // Clear the stat cache if the stream has a URI - if ($this->uri) { - \clearstatcache(\true, $this->uri); - } - $stats = \fstat($this->stream); - if (isset($stats['size'])) { - $this->size = $stats['size']; - return $this->size; - } - return null; - } - public function isReadable() - { - return $this->readable; - } - public function isWritable() - { - return $this->writable; - } - public function isSeekable() - { - return $this->seekable; - } - public function eof() - { - if (!isset($this->stream)) { - throw new \RuntimeException('Stream is detached'); - } - return \feof($this->stream); - } - public function tell() - { - if (!isset($this->stream)) { - throw new \RuntimeException('Stream is detached'); - } - $result = \ftell($this->stream); - if ($result === \false) { - throw new \RuntimeException('Unable to determine stream position'); - } - return $result; - } - public function rewind() - { - $this->seek(0); - } - public function seek($offset, $whence = \SEEK_SET) - { - $whence = (int) $whence; - if (!isset($this->stream)) { - throw new \RuntimeException('Stream is detached'); - } - if (!$this->seekable) { - throw new \RuntimeException('Stream is not seekable'); - } - if (\fseek($this->stream, $offset, $whence) === -1) { - throw new \RuntimeException('Unable to seek to stream position ' . $offset . ' with whence ' . \var_export($whence, \true)); - } - } - public function read($length) - { - if (!isset($this->stream)) { - throw new \RuntimeException('Stream is detached'); - } - if (!$this->readable) { - throw new \RuntimeException('Cannot read from non-readable stream'); - } - if ($length < 0) { - throw new \RuntimeException('Length parameter cannot be negative'); - } - if (0 === $length) { - return ''; - } - $string = \fread($this->stream, $length); - if (\false === $string) { - throw new \RuntimeException('Unable to read from stream'); - } - return $string; - } - public function write($string) - { - if (!isset($this->stream)) { - throw new \RuntimeException('Stream is detached'); - } - if (!$this->writable) { - throw new \RuntimeException('Cannot write to a non-writable stream'); - } - // We can't know the size after writing anything - $this->size = null; - $result = \fwrite($this->stream, $string); - if ($result === \false) { - throw new \RuntimeException('Unable to write to stream'); - } - return $result; - } - public function getMetadata($key = null) - { - if (!isset($this->stream)) { - return $key ? null : []; - } elseif (!$key) { - return $this->customMetadata + \stream_get_meta_data($this->stream); - } elseif (isset($this->customMetadata[$key])) { - return $this->customMetadata[$key]; - } - $meta = \stream_get_meta_data($this->stream); - return isset($meta[$key]) ? $meta[$key] : null; - } -} +size = $options['size']; + } + $this->customMetadata = isset($options['metadata']) ? $options['metadata'] : []; + $this->stream = $stream; + $meta = \stream_get_meta_data($this->stream); + $this->seekable = $meta['seekable']; + $this->readable = (bool) \preg_match(self::READABLE_MODES, $meta['mode']); + $this->writable = (bool) \preg_match(self::WRITABLE_MODES, $meta['mode']); + $this->uri = $this->getMetadata('uri'); + } + /** + * Closes the stream when the destructed + */ + public function __destruct() + { + $this->close(); + } + public function __toString() + { + try { + $this->seek(0); + return (string) \stream_get_contents($this->stream); + } catch (\Exception $e) { + return ''; + } + } + public function getContents() + { + if (!isset($this->stream)) { + throw new \RuntimeException('Stream is detached'); + } + $contents = \stream_get_contents($this->stream); + if ($contents === \false) { + throw new \RuntimeException('Unable to read stream contents'); + } + return $contents; + } + public function close() + { + if (isset($this->stream)) { + if (\is_resource($this->stream)) { + \fclose($this->stream); + } + $this->detach(); + } + } + public function detach() + { + if (!isset($this->stream)) { + return null; + } + $result = $this->stream; + unset($this->stream); + $this->size = $this->uri = null; + $this->readable = $this->writable = $this->seekable = \false; + return $result; + } + public function getSize() + { + if ($this->size !== null) { + return $this->size; + } + if (!isset($this->stream)) { + return null; + } + // Clear the stat cache if the stream has a URI + if ($this->uri) { + \clearstatcache(\true, $this->uri); + } + $stats = \fstat($this->stream); + if (isset($stats['size'])) { + $this->size = $stats['size']; + return $this->size; + } + return null; + } + public function isReadable() + { + return $this->readable; + } + public function isWritable() + { + return $this->writable; + } + public function isSeekable() + { + return $this->seekable; + } + public function eof() + { + if (!isset($this->stream)) { + throw new \RuntimeException('Stream is detached'); + } + return \feof($this->stream); + } + public function tell() + { + if (!isset($this->stream)) { + throw new \RuntimeException('Stream is detached'); + } + $result = \ftell($this->stream); + if ($result === \false) { + throw new \RuntimeException('Unable to determine stream position'); + } + return $result; + } + public function rewind() + { + $this->seek(0); + } + public function seek($offset, $whence = \SEEK_SET) + { + $whence = (int) $whence; + if (!isset($this->stream)) { + throw new \RuntimeException('Stream is detached'); + } + if (!$this->seekable) { + throw new \RuntimeException('Stream is not seekable'); + } + if (\fseek($this->stream, $offset, $whence) === -1) { + throw new \RuntimeException('Unable to seek to stream position ' . $offset . ' with whence ' . \var_export($whence, \true)); + } + } + public function read($length) + { + if (!isset($this->stream)) { + throw new \RuntimeException('Stream is detached'); + } + if (!$this->readable) { + throw new \RuntimeException('Cannot read from non-readable stream'); + } + if ($length < 0) { + throw new \RuntimeException('Length parameter cannot be negative'); + } + if (0 === $length) { + return ''; + } + $string = \fread($this->stream, $length); + if (\false === $string) { + throw new \RuntimeException('Unable to read from stream'); + } + return $string; + } + public function write($string) + { + if (!isset($this->stream)) { + throw new \RuntimeException('Stream is detached'); + } + if (!$this->writable) { + throw new \RuntimeException('Cannot write to a non-writable stream'); + } + // We can't know the size after writing anything + $this->size = null; + $result = \fwrite($this->stream, $string); + if ($result === \false) { + throw new \RuntimeException('Unable to write to stream'); + } + return $result; + } + public function getMetadata($key = null) + { + if (!isset($this->stream)) { + return $key ? null : []; + } elseif (!$key) { + return $this->customMetadata + \stream_get_meta_data($this->stream); + } elseif (isset($this->customMetadata[$key])) { + return $this->customMetadata[$key]; + } + $meta = \stream_get_meta_data($this->stream); + return isset($meta[$key]) ? $meta[$key] : null; + } +} diff --git a/vendor/guzzlehttp/psr7/src/StreamDecoratorTrait.php b/vendor/guzzlehttp/psr7/src/StreamDecoratorTrait.php index 461ed5c77..e2acd9114 100644 --- a/vendor/guzzlehttp/psr7/src/StreamDecoratorTrait.php +++ b/vendor/guzzlehttp/psr7/src/StreamDecoratorTrait.php @@ -1,128 +1,128 @@ -stream = $stream; - } - /** - * Magic method used to create a new stream if streams are not added in - * the constructor of a decorator (e.g., LazyOpenStream). - * - * @param string $name Name of the property (allows "stream" only). - * - * @return StreamInterface - */ - public function __get($name) - { - if ($name == 'stream') { - $this->stream = $this->createStream(); - return $this->stream; - } - throw new \UnexpectedValueException("{$name} not found on class"); - } - public function __toString() - { - try { - if ($this->isSeekable()) { - $this->seek(0); - } - return $this->getContents(); - } catch (\Exception $e) { - // Really, PHP? https://bugs.php.net/bug.php?id=53648 - \trigger_error('StreamDecorator::__toString exception: ' . (string) $e, \E_USER_ERROR); - return ''; - } - } - public function getContents() - { - return copy_to_string($this); - } - /** - * Allow decorators to implement custom methods - * - * @param string $method Missing method name - * @param array $args Method arguments - * - * @return mixed - */ - public function __call($method, array $args) - { - $result = \call_user_func_array([$this->stream, $method], $args); - // Always return the wrapped object if the result is a return $this - return $result === $this->stream ? $this : $result; - } - public function close() - { - $this->stream->close(); - } - public function getMetadata($key = null) - { - return $this->stream->getMetadata($key); - } - public function detach() - { - return $this->stream->detach(); - } - public function getSize() - { - return $this->stream->getSize(); - } - public function eof() - { - return $this->stream->eof(); - } - public function tell() - { - return $this->stream->tell(); - } - public function isReadable() - { - return $this->stream->isReadable(); - } - public function isWritable() - { - return $this->stream->isWritable(); - } - public function isSeekable() - { - return $this->stream->isSeekable(); - } - public function rewind() - { - $this->seek(0); - } - public function seek($offset, $whence = \SEEK_SET) - { - $this->stream->seek($offset, $whence); - } - public function read($length) - { - return $this->stream->read($length); - } - public function write($string) - { - return $this->stream->write($string); - } - /** - * Implement in subclasses to dynamically create streams when requested. - * - * @return StreamInterface - * @throws \BadMethodCallException - */ - protected function createStream() - { - throw new \BadMethodCallException('Not implemented'); - } -} +stream = $stream; + } + /** + * Magic method used to create a new stream if streams are not added in + * the constructor of a decorator (e.g., LazyOpenStream). + * + * @param string $name Name of the property (allows "stream" only). + * + * @return StreamInterface + */ + public function __get($name) + { + if ($name == 'stream') { + $this->stream = $this->createStream(); + return $this->stream; + } + throw new \UnexpectedValueException("{$name} not found on class"); + } + public function __toString() + { + try { + if ($this->isSeekable()) { + $this->seek(0); + } + return $this->getContents(); + } catch (\Exception $e) { + // Really, PHP? https://bugs.php.net/bug.php?id=53648 + \trigger_error('StreamDecorator::__toString exception: ' . (string) $e, \E_USER_ERROR); + return ''; + } + } + public function getContents() + { + return copy_to_string($this); + } + /** + * Allow decorators to implement custom methods + * + * @param string $method Missing method name + * @param array $args Method arguments + * + * @return mixed + */ + public function __call($method, array $args) + { + $result = \call_user_func_array([$this->stream, $method], $args); + // Always return the wrapped object if the result is a return $this + return $result === $this->stream ? $this : $result; + } + public function close() + { + $this->stream->close(); + } + public function getMetadata($key = null) + { + return $this->stream->getMetadata($key); + } + public function detach() + { + return $this->stream->detach(); + } + public function getSize() + { + return $this->stream->getSize(); + } + public function eof() + { + return $this->stream->eof(); + } + public function tell() + { + return $this->stream->tell(); + } + public function isReadable() + { + return $this->stream->isReadable(); + } + public function isWritable() + { + return $this->stream->isWritable(); + } + public function isSeekable() + { + return $this->stream->isSeekable(); + } + public function rewind() + { + $this->seek(0); + } + public function seek($offset, $whence = \SEEK_SET) + { + $this->stream->seek($offset, $whence); + } + public function read($length) + { + return $this->stream->read($length); + } + public function write($string) + { + return $this->stream->write($string); + } + /** + * Implement in subclasses to dynamically create streams when requested. + * + * @return StreamInterface + * @throws \BadMethodCallException + */ + protected function createStream() + { + throw new \BadMethodCallException('Not implemented'); + } +} diff --git a/vendor/guzzlehttp/psr7/src/StreamWrapper.php b/vendor/guzzlehttp/psr7/src/StreamWrapper.php index 1b3994db2..8d308e03b 100644 --- a/vendor/guzzlehttp/psr7/src/StreamWrapper.php +++ b/vendor/guzzlehttp/psr7/src/StreamWrapper.php @@ -1,102 +1,102 @@ -isReadable()) { - $mode = $stream->isWritable() ? 'r+' : 'r'; - } elseif ($stream->isWritable()) { - $mode = 'w'; - } else { - throw new \InvalidArgumentException('The stream must be readable, ' . 'writable, or both.'); - } - return \fopen('guzzle://stream', $mode, null, self::createStreamContext($stream)); - } - /** - * Creates a stream context that can be used to open a stream as a php stream resource. - * - * @param StreamInterface $stream - * - * @return resource - */ - public static function createStreamContext(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream) - { - return \stream_context_create(['guzzle' => ['stream' => $stream]]); - } - /** - * Registers the stream wrapper if needed - */ - public static function register() - { - if (!\in_array('guzzle', \stream_get_wrappers())) { - \stream_wrapper_register('guzzle', __CLASS__); - } - } - public function stream_open($path, $mode, $options, &$opened_path) - { - $options = \stream_context_get_options($this->context); - if (!isset($options['guzzle']['stream'])) { - return \false; - } - $this->mode = $mode; - $this->stream = $options['guzzle']['stream']; - return \true; - } - public function stream_read($count) - { - return $this->stream->read($count); - } - public function stream_write($data) - { - return (int) $this->stream->write($data); - } - public function stream_tell() - { - return $this->stream->tell(); - } - public function stream_eof() - { - return $this->stream->eof(); - } - public function stream_seek($offset, $whence) - { - $this->stream->seek($offset, $whence); - return \true; - } - public function stream_cast($cast_as) - { - $stream = clone $this->stream; - return $stream->detach(); - } - public function stream_stat() - { - static $modeMap = ['r' => 33060, 'rb' => 33060, 'r+' => 33206, 'w' => 33188, 'wb' => 33188]; - return ['dev' => 0, 'ino' => 0, 'mode' => $modeMap[$this->mode], 'nlink' => 0, 'uid' => 0, 'gid' => 0, 'rdev' => 0, 'size' => $this->stream->getSize() ?: 0, 'atime' => 0, 'mtime' => 0, 'ctime' => 0, 'blksize' => 0, 'blocks' => 0]; - } - public function url_stat($path, $flags) - { - return ['dev' => 0, 'ino' => 0, 'mode' => 0, 'nlink' => 0, 'uid' => 0, 'gid' => 0, 'rdev' => 0, 'size' => 0, 'atime' => 0, 'mtime' => 0, 'ctime' => 0, 'blksize' => 0, 'blocks' => 0]; - } -} +isReadable()) { + $mode = $stream->isWritable() ? 'r+' : 'r'; + } elseif ($stream->isWritable()) { + $mode = 'w'; + } else { + throw new \InvalidArgumentException('The stream must be readable, ' . 'writable, or both.'); + } + return \fopen('guzzle://stream', $mode, null, self::createStreamContext($stream)); + } + /** + * Creates a stream context that can be used to open a stream as a php stream resource. + * + * @param StreamInterface $stream + * + * @return resource + */ + public static function createStreamContext(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream) + { + return \stream_context_create(['guzzle' => ['stream' => $stream]]); + } + /** + * Registers the stream wrapper if needed + */ + public static function register() + { + if (!\in_array('guzzle', \stream_get_wrappers())) { + \stream_wrapper_register('guzzle', __CLASS__); + } + } + public function stream_open($path, $mode, $options, &$opened_path) + { + $options = \stream_context_get_options($this->context); + if (!isset($options['guzzle']['stream'])) { + return \false; + } + $this->mode = $mode; + $this->stream = $options['guzzle']['stream']; + return \true; + } + public function stream_read($count) + { + return $this->stream->read($count); + } + public function stream_write($data) + { + return (int) $this->stream->write($data); + } + public function stream_tell() + { + return $this->stream->tell(); + } + public function stream_eof() + { + return $this->stream->eof(); + } + public function stream_seek($offset, $whence) + { + $this->stream->seek($offset, $whence); + return \true; + } + public function stream_cast($cast_as) + { + $stream = clone $this->stream; + return $stream->detach(); + } + public function stream_stat() + { + static $modeMap = ['r' => 33060, 'rb' => 33060, 'r+' => 33206, 'w' => 33188, 'wb' => 33188]; + return ['dev' => 0, 'ino' => 0, 'mode' => $modeMap[$this->mode], 'nlink' => 0, 'uid' => 0, 'gid' => 0, 'rdev' => 0, 'size' => $this->stream->getSize() ?: 0, 'atime' => 0, 'mtime' => 0, 'ctime' => 0, 'blksize' => 0, 'blocks' => 0]; + } + public function url_stat($path, $flags) + { + return ['dev' => 0, 'ino' => 0, 'mode' => 0, 'nlink' => 0, 'uid' => 0, 'gid' => 0, 'rdev' => 0, 'size' => 0, 'atime' => 0, 'mtime' => 0, 'ctime' => 0, 'blksize' => 0, 'blocks' => 0]; + } +} diff --git a/vendor/guzzlehttp/psr7/src/UploadedFile.php b/vendor/guzzlehttp/psr7/src/UploadedFile.php index e143edd1c..80b5fb2cd 100644 --- a/vendor/guzzlehttp/psr7/src/UploadedFile.php +++ b/vendor/guzzlehttp/psr7/src/UploadedFile.php @@ -1,244 +1,244 @@ -setError($errorStatus); - $this->setSize($size); - $this->setClientFilename($clientFilename); - $this->setClientMediaType($clientMediaType); - if ($this->isOk()) { - $this->setStreamOrFile($streamOrFile); - } - } - /** - * Depending on the value set file or stream variable - * - * @param mixed $streamOrFile - * @throws InvalidArgumentException - */ - private function setStreamOrFile($streamOrFile) - { - if (\is_string($streamOrFile)) { - $this->file = $streamOrFile; - } elseif (\is_resource($streamOrFile)) { - $this->stream = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream($streamOrFile); - } elseif ($streamOrFile instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface) { - $this->stream = $streamOrFile; - } else { - throw new \InvalidArgumentException('Invalid stream or file provided for UploadedFile'); - } - } - /** - * @param int $error - * @throws InvalidArgumentException - */ - private function setError($error) - { - if (\false === \is_int($error)) { - throw new \InvalidArgumentException('Upload file error status must be an integer'); - } - if (\false === \in_array($error, \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UploadedFile::$errors)) { - throw new \InvalidArgumentException('Invalid error status for UploadedFile'); - } - $this->error = $error; - } - /** - * @param int $size - * @throws InvalidArgumentException - */ - private function setSize($size) - { - if (\false === \is_int($size)) { - throw new \InvalidArgumentException('Upload file size must be an integer'); - } - $this->size = $size; - } - /** - * @param mixed $param - * @return boolean - */ - private function isStringOrNull($param) - { - return \in_array(\gettype($param), ['string', 'NULL']); - } - /** - * @param mixed $param - * @return boolean - */ - private function isStringNotEmpty($param) - { - return \is_string($param) && \false === empty($param); - } - /** - * @param string|null $clientFilename - * @throws InvalidArgumentException - */ - private function setClientFilename($clientFilename) - { - if (\false === $this->isStringOrNull($clientFilename)) { - throw new \InvalidArgumentException('Upload file client filename must be a string or null'); - } - $this->clientFilename = $clientFilename; - } - /** - * @param string|null $clientMediaType - * @throws InvalidArgumentException - */ - private function setClientMediaType($clientMediaType) - { - if (\false === $this->isStringOrNull($clientMediaType)) { - throw new \InvalidArgumentException('Upload file client media type must be a string or null'); - } - $this->clientMediaType = $clientMediaType; - } - /** - * Return true if there is no upload error - * - * @return boolean - */ - private function isOk() - { - return $this->error === \UPLOAD_ERR_OK; - } - /** - * @return boolean - */ - public function isMoved() - { - return $this->moved; - } - /** - * @throws RuntimeException if is moved or not ok - */ - private function validateActive() - { - if (\false === $this->isOk()) { - throw new \RuntimeException('Cannot retrieve stream due to upload error'); - } - if ($this->isMoved()) { - throw new \RuntimeException('Cannot retrieve stream after it has already been moved'); - } - } - /** - * {@inheritdoc} - * @throws RuntimeException if the upload was not successful. - */ - public function getStream() - { - $this->validateActive(); - if ($this->stream instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface) { - return $this->stream; - } - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LazyOpenStream($this->file, 'r+'); - } - /** - * {@inheritdoc} - * - * @see http://php.net/is_uploaded_file - * @see http://php.net/move_uploaded_file - * @param string $targetPath Path to which to move the uploaded file. - * @throws RuntimeException if the upload was not successful. - * @throws InvalidArgumentException if the $path specified is invalid. - * @throws RuntimeException on any error during the move operation, or on - * the second or subsequent call to the method. - */ - public function moveTo($targetPath) - { - $this->validateActive(); - if (\false === $this->isStringNotEmpty($targetPath)) { - throw new \InvalidArgumentException('Invalid path provided for move operation; must be a non-empty string'); - } - if ($this->file) { - $this->moved = \php_sapi_name() == 'cli' ? \rename($this->file, $targetPath) : \move_uploaded_file($this->file, $targetPath); - } else { - copy_to_stream($this->getStream(), new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LazyOpenStream($targetPath, 'w')); - $this->moved = \true; - } - if (\false === $this->moved) { - throw new \RuntimeException(\sprintf('Uploaded file could not be moved to %s', $targetPath)); - } - } - /** - * {@inheritdoc} - * - * @return int|null The file size in bytes or null if unknown. - */ - public function getSize() - { - return $this->size; - } - /** - * {@inheritdoc} - * - * @see http://php.net/manual/en/features.file-upload.errors.php - * @return int One of PHP's UPLOAD_ERR_XXX constants. - */ - public function getError() - { - return $this->error; - } - /** - * {@inheritdoc} - * - * @return string|null The filename sent by the client or null if none - * was provided. - */ - public function getClientFilename() - { - return $this->clientFilename; - } - /** - * {@inheritdoc} - */ - public function getClientMediaType() - { - return $this->clientMediaType; - } -} +setError($errorStatus); + $this->setSize($size); + $this->setClientFilename($clientFilename); + $this->setClientMediaType($clientMediaType); + if ($this->isOk()) { + $this->setStreamOrFile($streamOrFile); + } + } + /** + * Depending on the value set file or stream variable + * + * @param mixed $streamOrFile + * @throws InvalidArgumentException + */ + private function setStreamOrFile($streamOrFile) + { + if (\is_string($streamOrFile)) { + $this->file = $streamOrFile; + } elseif (\is_resource($streamOrFile)) { + $this->stream = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream($streamOrFile); + } elseif ($streamOrFile instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface) { + $this->stream = $streamOrFile; + } else { + throw new \InvalidArgumentException('Invalid stream or file provided for UploadedFile'); + } + } + /** + * @param int $error + * @throws InvalidArgumentException + */ + private function setError($error) + { + if (\false === \is_int($error)) { + throw new \InvalidArgumentException('Upload file error status must be an integer'); + } + if (\false === \in_array($error, \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UploadedFile::$errors)) { + throw new \InvalidArgumentException('Invalid error status for UploadedFile'); + } + $this->error = $error; + } + /** + * @param int $size + * @throws InvalidArgumentException + */ + private function setSize($size) + { + if (\false === \is_int($size)) { + throw new \InvalidArgumentException('Upload file size must be an integer'); + } + $this->size = $size; + } + /** + * @param mixed $param + * @return boolean + */ + private function isStringOrNull($param) + { + return \in_array(\gettype($param), ['string', 'NULL']); + } + /** + * @param mixed $param + * @return boolean + */ + private function isStringNotEmpty($param) + { + return \is_string($param) && \false === empty($param); + } + /** + * @param string|null $clientFilename + * @throws InvalidArgumentException + */ + private function setClientFilename($clientFilename) + { + if (\false === $this->isStringOrNull($clientFilename)) { + throw new \InvalidArgumentException('Upload file client filename must be a string or null'); + } + $this->clientFilename = $clientFilename; + } + /** + * @param string|null $clientMediaType + * @throws InvalidArgumentException + */ + private function setClientMediaType($clientMediaType) + { + if (\false === $this->isStringOrNull($clientMediaType)) { + throw new \InvalidArgumentException('Upload file client media type must be a string or null'); + } + $this->clientMediaType = $clientMediaType; + } + /** + * Return true if there is no upload error + * + * @return boolean + */ + private function isOk() + { + return $this->error === \UPLOAD_ERR_OK; + } + /** + * @return boolean + */ + public function isMoved() + { + return $this->moved; + } + /** + * @throws RuntimeException if is moved or not ok + */ + private function validateActive() + { + if (\false === $this->isOk()) { + throw new \RuntimeException('Cannot retrieve stream due to upload error'); + } + if ($this->isMoved()) { + throw new \RuntimeException('Cannot retrieve stream after it has already been moved'); + } + } + /** + * {@inheritdoc} + * @throws RuntimeException if the upload was not successful. + */ + public function getStream() + { + $this->validateActive(); + if ($this->stream instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface) { + return $this->stream; + } + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LazyOpenStream($this->file, 'r+'); + } + /** + * {@inheritdoc} + * + * @see http://php.net/is_uploaded_file + * @see http://php.net/move_uploaded_file + * @param string $targetPath Path to which to move the uploaded file. + * @throws RuntimeException if the upload was not successful. + * @throws InvalidArgumentException if the $path specified is invalid. + * @throws RuntimeException on any error during the move operation, or on + * the second or subsequent call to the method. + */ + public function moveTo($targetPath) + { + $this->validateActive(); + if (\false === $this->isStringNotEmpty($targetPath)) { + throw new \InvalidArgumentException('Invalid path provided for move operation; must be a non-empty string'); + } + if ($this->file) { + $this->moved = \php_sapi_name() == 'cli' ? \rename($this->file, $targetPath) : \move_uploaded_file($this->file, $targetPath); + } else { + copy_to_stream($this->getStream(), new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\LazyOpenStream($targetPath, 'w')); + $this->moved = \true; + } + if (\false === $this->moved) { + throw new \RuntimeException(\sprintf('Uploaded file could not be moved to %s', $targetPath)); + } + } + /** + * {@inheritdoc} + * + * @return int|null The file size in bytes or null if unknown. + */ + public function getSize() + { + return $this->size; + } + /** + * {@inheritdoc} + * + * @see http://php.net/manual/en/features.file-upload.errors.php + * @return int One of PHP's UPLOAD_ERR_XXX constants. + */ + public function getError() + { + return $this->error; + } + /** + * {@inheritdoc} + * + * @return string|null The filename sent by the client or null if none + * was provided. + */ + public function getClientFilename() + { + return $this->clientFilename; + } + /** + * {@inheritdoc} + */ + public function getClientMediaType() + { + return $this->clientMediaType; + } +} diff --git a/vendor/guzzlehttp/psr7/src/Uri.php b/vendor/guzzlehttp/psr7/src/Uri.php index 3b3d6bab1..d22fae272 100644 --- a/vendor/guzzlehttp/psr7/src/Uri.php +++ b/vendor/guzzlehttp/psr7/src/Uri.php @@ -1,598 +1,598 @@ - 80, 'https' => 443, 'ftp' => 21, 'gopher' => 70, 'nntp' => 119, 'news' => 119, 'telnet' => 23, 'tn3270' => 23, 'imap' => 143, 'pop' => 110, 'ldap' => 389]; - private static $charUnreserved = 'a-zA-Z0-9_\\-\\.~'; - private static $charSubDelims = '!\\$&\'\\(\\)\\*\\+,;='; - private static $replaceQuery = ['=' => '%3D', '&' => '%26']; - /** @var string Uri scheme. */ - private $scheme = ''; - /** @var string Uri user info. */ - private $userInfo = ''; - /** @var string Uri host. */ - private $host = ''; - /** @var int|null Uri port. */ - private $port; - /** @var string Uri path. */ - private $path = ''; - /** @var string Uri query string. */ - private $query = ''; - /** @var string Uri fragment. */ - private $fragment = ''; - /** - * @param string $uri URI to parse - */ - public function __construct($uri = '') - { - // weak type check to also accept null until we can add scalar type hints - if ($uri != '') { - $parts = \parse_url($uri); - if ($parts === \false) { - throw new \InvalidArgumentException("Unable to parse URI: {$uri}"); - } - $this->applyParts($parts); - } - } - public function __toString() - { - return self::composeComponents($this->scheme, $this->getAuthority(), $this->path, $this->query, $this->fragment); - } - /** - * Composes a URI reference string from its various components. - * - * Usually this method does not need to be called manually but instead is used indirectly via - * `Psr\Http\Message\UriInterface::__toString`. - * - * PSR-7 UriInterface treats an empty component the same as a missing component as - * getQuery(), getFragment() etc. always return a string. This explains the slight - * difference to RFC 3986 Section 5.3. - * - * Another adjustment is that the authority separator is added even when the authority is missing/empty - * for the "file" scheme. This is because PHP stream functions like `file_get_contents` only work with - * `file:///myfile` but not with `file:/myfile` although they are equivalent according to RFC 3986. But - * `file:///` is the more common syntax for the file scheme anyway (Chrome for example redirects to - * that format). - * - * @param string $scheme - * @param string $authority - * @param string $path - * @param string $query - * @param string $fragment - * - * @return string - * - * @link https://tools.ietf.org/html/rfc3986#section-5.3 - */ - public static function composeComponents($scheme, $authority, $path, $query, $fragment) - { - $uri = ''; - // weak type checks to also accept null until we can add scalar type hints - if ($scheme != '') { - $uri .= $scheme . ':'; - } - if ($authority != '' || $scheme === 'file') { - $uri .= '//' . $authority; - } - $uri .= $path; - if ($query != '') { - $uri .= '?' . $query; - } - if ($fragment != '') { - $uri .= '#' . $fragment; - } - return $uri; - } - /** - * Whether the URI has the default port of the current scheme. - * - * `Psr\Http\Message\UriInterface::getPort` may return null or the standard port. This method can be used - * independently of the implementation. - * - * @param UriInterface $uri - * - * @return bool - */ - public static function isDefaultPort(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) - { - return $uri->getPort() === null || isset(self::$defaultPorts[$uri->getScheme()]) && $uri->getPort() === self::$defaultPorts[$uri->getScheme()]; - } - /** - * Whether the URI is absolute, i.e. it has a scheme. - * - * An instance of UriInterface can either be an absolute URI or a relative reference. This method returns true - * if it is the former. An absolute URI has a scheme. A relative reference is used to express a URI relative - * to another URI, the base URI. Relative references can be divided into several forms: - * - network-path references, e.g. '//example.com/path' - * - absolute-path references, e.g. '/path' - * - relative-path references, e.g. 'subpath' - * - * @param UriInterface $uri - * - * @return bool - * @see Uri::isNetworkPathReference - * @see Uri::isAbsolutePathReference - * @see Uri::isRelativePathReference - * @link https://tools.ietf.org/html/rfc3986#section-4 - */ - public static function isAbsolute(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) - { - return $uri->getScheme() !== ''; - } - /** - * Whether the URI is a network-path reference. - * - * A relative reference that begins with two slash characters is termed an network-path reference. - * - * @param UriInterface $uri - * - * @return bool - * @link https://tools.ietf.org/html/rfc3986#section-4.2 - */ - public static function isNetworkPathReference(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) - { - return $uri->getScheme() === '' && $uri->getAuthority() !== ''; - } - /** - * Whether the URI is a absolute-path reference. - * - * A relative reference that begins with a single slash character is termed an absolute-path reference. - * - * @param UriInterface $uri - * - * @return bool - * @link https://tools.ietf.org/html/rfc3986#section-4.2 - */ - public static function isAbsolutePathReference(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) - { - return $uri->getScheme() === '' && $uri->getAuthority() === '' && isset($uri->getPath()[0]) && $uri->getPath()[0] === '/'; - } - /** - * Whether the URI is a relative-path reference. - * - * A relative reference that does not begin with a slash character is termed a relative-path reference. - * - * @param UriInterface $uri - * - * @return bool - * @link https://tools.ietf.org/html/rfc3986#section-4.2 - */ - public static function isRelativePathReference(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) - { - return $uri->getScheme() === '' && $uri->getAuthority() === '' && (!isset($uri->getPath()[0]) || $uri->getPath()[0] !== '/'); - } - /** - * Whether the URI is a same-document reference. - * - * A same-document reference refers to a URI that is, aside from its fragment - * component, identical to the base URI. When no base URI is given, only an empty - * URI reference (apart from its fragment) is considered a same-document reference. - * - * @param UriInterface $uri The URI to check - * @param UriInterface|null $base An optional base URI to compare against - * - * @return bool - * @link https://tools.ietf.org/html/rfc3986#section-4.4 - */ - public static function isSameDocumentReference(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $base = null) - { - if ($base !== null) { - $uri = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::resolve($base, $uri); - return $uri->getScheme() === $base->getScheme() && $uri->getAuthority() === $base->getAuthority() && $uri->getPath() === $base->getPath() && $uri->getQuery() === $base->getQuery(); - } - return $uri->getScheme() === '' && $uri->getAuthority() === '' && $uri->getPath() === '' && $uri->getQuery() === ''; - } - /** - * Removes dot segments from a path and returns the new path. - * - * @param string $path - * - * @return string - * - * @deprecated since version 1.4. Use UriResolver::removeDotSegments instead. - * @see UriResolver::removeDotSegments - */ - public static function removeDotSegments($path) - { - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::removeDotSegments($path); - } - /** - * Converts the relative URI into a new URI that is resolved against the base URI. - * - * @param UriInterface $base Base URI - * @param string|UriInterface $rel Relative URI - * - * @return UriInterface - * - * @deprecated since version 1.4. Use UriResolver::resolve instead. - * @see UriResolver::resolve - */ - public static function resolve(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $base, $rel) - { - if (!$rel instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface) { - $rel = new self($rel); - } - return \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::resolve($base, $rel); - } - /** - * Creates a new URI with a specific query string value removed. - * - * Any existing query string values that exactly match the provided key are - * removed. - * - * @param UriInterface $uri URI to use as a base. - * @param string $key Query string key to remove. - * - * @return UriInterface - */ - public static function withoutQueryValue(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, $key) - { - $result = self::getFilteredQueryString($uri, [$key]); - return $uri->withQuery(\implode('&', $result)); - } - /** - * Creates a new URI with a specific query string value. - * - * Any existing query string values that exactly match the provided key are - * removed and replaced with the given key value pair. - * - * A value of null will set the query string key without a value, e.g. "key" - * instead of "key=value". - * - * @param UriInterface $uri URI to use as a base. - * @param string $key Key to set. - * @param string|null $value Value to set - * - * @return UriInterface - */ - public static function withQueryValue(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, $key, $value) - { - $result = self::getFilteredQueryString($uri, [$key]); - $result[] = self::generateQueryString($key, $value); - return $uri->withQuery(\implode('&', $result)); - } - /** - * Creates a new URI with multiple specific query string values. - * - * It has the same behavior as withQueryValue() but for an associative array of key => value. - * - * @param UriInterface $uri URI to use as a base. - * @param array $keyValueArray Associative array of key and values - * - * @return UriInterface - */ - public static function withQueryValues(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, array $keyValueArray) - { - $result = self::getFilteredQueryString($uri, \array_keys($keyValueArray)); - foreach ($keyValueArray as $key => $value) { - $result[] = self::generateQueryString($key, $value); - } - return $uri->withQuery(\implode('&', $result)); - } - /** - * Creates a URI from a hash of `parse_url` components. - * - * @param array $parts - * - * @return UriInterface - * @link http://php.net/manual/en/function.parse-url.php - * - * @throws \InvalidArgumentException If the components do not form a valid URI. - */ - public static function fromParts(array $parts) - { - $uri = new self(); - $uri->applyParts($parts); - $uri->validateState(); - return $uri; - } - public function getScheme() - { - return $this->scheme; - } - public function getAuthority() - { - $authority = $this->host; - if ($this->userInfo !== '') { - $authority = $this->userInfo . '@' . $authority; - } - if ($this->port !== null) { - $authority .= ':' . $this->port; - } - return $authority; - } - public function getUserInfo() - { - return $this->userInfo; - } - public function getHost() - { - return $this->host; - } - public function getPort() - { - return $this->port; - } - public function getPath() - { - return $this->path; - } - public function getQuery() - { - return $this->query; - } - public function getFragment() - { - return $this->fragment; - } - public function withScheme($scheme) - { - $scheme = $this->filterScheme($scheme); - if ($this->scheme === $scheme) { - return $this; - } - $new = clone $this; - $new->scheme = $scheme; - $new->removeDefaultPort(); - $new->validateState(); - return $new; - } - public function withUserInfo($user, $password = null) - { - $info = $this->filterUserInfoComponent($user); - if ($password !== null) { - $info .= ':' . $this->filterUserInfoComponent($password); - } - if ($this->userInfo === $info) { - return $this; - } - $new = clone $this; - $new->userInfo = $info; - $new->validateState(); - return $new; - } - public function withHost($host) - { - $host = $this->filterHost($host); - if ($this->host === $host) { - return $this; - } - $new = clone $this; - $new->host = $host; - $new->validateState(); - return $new; - } - public function withPort($port) - { - $port = $this->filterPort($port); - if ($this->port === $port) { - return $this; - } - $new = clone $this; - $new->port = $port; - $new->removeDefaultPort(); - $new->validateState(); - return $new; - } - public function withPath($path) - { - $path = $this->filterPath($path); - if ($this->path === $path) { - return $this; - } - $new = clone $this; - $new->path = $path; - $new->validateState(); - return $new; - } - public function withQuery($query) - { - $query = $this->filterQueryAndFragment($query); - if ($this->query === $query) { - return $this; - } - $new = clone $this; - $new->query = $query; - return $new; - } - public function withFragment($fragment) - { - $fragment = $this->filterQueryAndFragment($fragment); - if ($this->fragment === $fragment) { - return $this; - } - $new = clone $this; - $new->fragment = $fragment; - return $new; - } - /** - * Apply parse_url parts to a URI. - * - * @param array $parts Array of parse_url parts to apply. - */ - private function applyParts(array $parts) - { - $this->scheme = isset($parts['scheme']) ? $this->filterScheme($parts['scheme']) : ''; - $this->userInfo = isset($parts['user']) ? $this->filterUserInfoComponent($parts['user']) : ''; - $this->host = isset($parts['host']) ? $this->filterHost($parts['host']) : ''; - $this->port = isset($parts['port']) ? $this->filterPort($parts['port']) : null; - $this->path = isset($parts['path']) ? $this->filterPath($parts['path']) : ''; - $this->query = isset($parts['query']) ? $this->filterQueryAndFragment($parts['query']) : ''; - $this->fragment = isset($parts['fragment']) ? $this->filterQueryAndFragment($parts['fragment']) : ''; - if (isset($parts['pass'])) { - $this->userInfo .= ':' . $this->filterUserInfoComponent($parts['pass']); - } - $this->removeDefaultPort(); - } - /** - * @param string $scheme - * - * @return string - * - * @throws \InvalidArgumentException If the scheme is invalid. - */ - private function filterScheme($scheme) - { - if (!\is_string($scheme)) { - throw new \InvalidArgumentException('Scheme must be a string'); - } - return \strtolower($scheme); - } - /** - * @param string $component - * - * @return string - * - * @throws \InvalidArgumentException If the user info is invalid. - */ - private function filterUserInfoComponent($component) - { - if (!\is_string($component)) { - throw new \InvalidArgumentException('User info must be a string'); - } - return \preg_replace_callback('/(?:[^%' . self::$charUnreserved . self::$charSubDelims . ']+|%(?![A-Fa-f0-9]{2}))/', [$this, 'rawurlencodeMatchZero'], $component); - } - /** - * @param string $host - * - * @return string - * - * @throws \InvalidArgumentException If the host is invalid. - */ - private function filterHost($host) - { - if (!\is_string($host)) { - throw new \InvalidArgumentException('Host must be a string'); - } - return \strtolower($host); - } - /** - * @param int|null $port - * - * @return int|null - * - * @throws \InvalidArgumentException If the port is invalid. - */ - private function filterPort($port) - { - if ($port === null) { - return null; - } - $port = (int) $port; - if (0 > $port || 0xffff < $port) { - throw new \InvalidArgumentException(\sprintf('Invalid port: %d. Must be between 0 and 65535', $port)); - } - return $port; - } - /** - * @param UriInterface $uri - * @param array $keys - * - * @return array - */ - private static function getFilteredQueryString(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, array $keys) - { - $current = $uri->getQuery(); - if ($current === '') { - return []; - } - $decodedKeys = \array_map('rawurldecode', $keys); - return \array_filter(\explode('&', $current), function ($part) use($decodedKeys) { - return !\in_array(\rawurldecode(\explode('=', $part)[0]), $decodedKeys, \true); - }); - } - /** - * @param string $key - * @param string|null $value - * - * @return string - */ - private static function generateQueryString($key, $value) - { - // Query string separators ("=", "&") within the key or value need to be encoded - // (while preventing double-encoding) before setting the query string. All other - // chars that need percent-encoding will be encoded by withQuery(). - $queryString = \strtr($key, self::$replaceQuery); - if ($value !== null) { - $queryString .= '=' . \strtr($value, self::$replaceQuery); - } - return $queryString; - } - private function removeDefaultPort() - { - if ($this->port !== null && self::isDefaultPort($this)) { - $this->port = null; - } - } - /** - * Filters the path of a URI - * - * @param string $path - * - * @return string - * - * @throws \InvalidArgumentException If the path is invalid. - */ - private function filterPath($path) - { - if (!\is_string($path)) { - throw new \InvalidArgumentException('Path must be a string'); - } - return \preg_replace_callback('/(?:[^' . self::$charUnreserved . self::$charSubDelims . '%:@\\/]++|%(?![A-Fa-f0-9]{2}))/', [$this, 'rawurlencodeMatchZero'], $path); - } - /** - * Filters the query string or fragment of a URI. - * - * @param string $str - * - * @return string - * - * @throws \InvalidArgumentException If the query or fragment is invalid. - */ - private function filterQueryAndFragment($str) - { - if (!\is_string($str)) { - throw new \InvalidArgumentException('Query and fragment must be a string'); - } - return \preg_replace_callback('/(?:[^' . self::$charUnreserved . self::$charSubDelims . '%:@\\/\\?]++|%(?![A-Fa-f0-9]{2}))/', [$this, 'rawurlencodeMatchZero'], $str); - } - private function rawurlencodeMatchZero(array $match) - { - return \rawurlencode($match[0]); - } - private function validateState() - { - if ($this->host === '' && ($this->scheme === 'http' || $this->scheme === 'https')) { - $this->host = self::HTTP_DEFAULT_HOST; - } - if ($this->getAuthority() === '') { - if (0 === \strpos($this->path, '//')) { - throw new \InvalidArgumentException('The path of a URI without an authority must not start with two slashes "//"'); - } - if ($this->scheme === '' && \false !== \strpos(\explode('/', $this->path, 2)[0], ':')) { - throw new \InvalidArgumentException('A relative URI must not have a path beginning with a segment containing a colon'); - } - } elseif (isset($this->path[0]) && $this->path[0] !== '/') { - @\trigger_error('The path of a URI with an authority must start with a slash "/" or be empty. Automagically fixing the URI ' . 'by adding a leading slash to the path is deprecated since version 1.4 and will throw an exception instead.', \E_USER_DEPRECATED); - $this->path = '/' . $this->path; - //throw new \InvalidArgumentException('The path of a URI with an authority must start with a slash "/" or be empty'); - } - } -} + 80, 'https' => 443, 'ftp' => 21, 'gopher' => 70, 'nntp' => 119, 'news' => 119, 'telnet' => 23, 'tn3270' => 23, 'imap' => 143, 'pop' => 110, 'ldap' => 389]; + private static $charUnreserved = 'a-zA-Z0-9_\\-\\.~'; + private static $charSubDelims = '!\\$&\'\\(\\)\\*\\+,;='; + private static $replaceQuery = ['=' => '%3D', '&' => '%26']; + /** @var string Uri scheme. */ + private $scheme = ''; + /** @var string Uri user info. */ + private $userInfo = ''; + /** @var string Uri host. */ + private $host = ''; + /** @var int|null Uri port. */ + private $port; + /** @var string Uri path. */ + private $path = ''; + /** @var string Uri query string. */ + private $query = ''; + /** @var string Uri fragment. */ + private $fragment = ''; + /** + * @param string $uri URI to parse + */ + public function __construct($uri = '') + { + // weak type check to also accept null until we can add scalar type hints + if ($uri != '') { + $parts = \parse_url($uri); + if ($parts === \false) { + throw new \InvalidArgumentException("Unable to parse URI: {$uri}"); + } + $this->applyParts($parts); + } + } + public function __toString() + { + return self::composeComponents($this->scheme, $this->getAuthority(), $this->path, $this->query, $this->fragment); + } + /** + * Composes a URI reference string from its various components. + * + * Usually this method does not need to be called manually but instead is used indirectly via + * `Psr\Http\Message\UriInterface::__toString`. + * + * PSR-7 UriInterface treats an empty component the same as a missing component as + * getQuery(), getFragment() etc. always return a string. This explains the slight + * difference to RFC 3986 Section 5.3. + * + * Another adjustment is that the authority separator is added even when the authority is missing/empty + * for the "file" scheme. This is because PHP stream functions like `file_get_contents` only work with + * `file:///myfile` but not with `file:/myfile` although they are equivalent according to RFC 3986. But + * `file:///` is the more common syntax for the file scheme anyway (Chrome for example redirects to + * that format). + * + * @param string $scheme + * @param string $authority + * @param string $path + * @param string $query + * @param string $fragment + * + * @return string + * + * @link https://tools.ietf.org/html/rfc3986#section-5.3 + */ + public static function composeComponents($scheme, $authority, $path, $query, $fragment) + { + $uri = ''; + // weak type checks to also accept null until we can add scalar type hints + if ($scheme != '') { + $uri .= $scheme . ':'; + } + if ($authority != '' || $scheme === 'file') { + $uri .= '//' . $authority; + } + $uri .= $path; + if ($query != '') { + $uri .= '?' . $query; + } + if ($fragment != '') { + $uri .= '#' . $fragment; + } + return $uri; + } + /** + * Whether the URI has the default port of the current scheme. + * + * `Psr\Http\Message\UriInterface::getPort` may return null or the standard port. This method can be used + * independently of the implementation. + * + * @param UriInterface $uri + * + * @return bool + */ + public static function isDefaultPort(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) + { + return $uri->getPort() === null || isset(self::$defaultPorts[$uri->getScheme()]) && $uri->getPort() === self::$defaultPorts[$uri->getScheme()]; + } + /** + * Whether the URI is absolute, i.e. it has a scheme. + * + * An instance of UriInterface can either be an absolute URI or a relative reference. This method returns true + * if it is the former. An absolute URI has a scheme. A relative reference is used to express a URI relative + * to another URI, the base URI. Relative references can be divided into several forms: + * - network-path references, e.g. '//example.com/path' + * - absolute-path references, e.g. '/path' + * - relative-path references, e.g. 'subpath' + * + * @param UriInterface $uri + * + * @return bool + * @see Uri::isNetworkPathReference + * @see Uri::isAbsolutePathReference + * @see Uri::isRelativePathReference + * @link https://tools.ietf.org/html/rfc3986#section-4 + */ + public static function isAbsolute(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) + { + return $uri->getScheme() !== ''; + } + /** + * Whether the URI is a network-path reference. + * + * A relative reference that begins with two slash characters is termed an network-path reference. + * + * @param UriInterface $uri + * + * @return bool + * @link https://tools.ietf.org/html/rfc3986#section-4.2 + */ + public static function isNetworkPathReference(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) + { + return $uri->getScheme() === '' && $uri->getAuthority() !== ''; + } + /** + * Whether the URI is a absolute-path reference. + * + * A relative reference that begins with a single slash character is termed an absolute-path reference. + * + * @param UriInterface $uri + * + * @return bool + * @link https://tools.ietf.org/html/rfc3986#section-4.2 + */ + public static function isAbsolutePathReference(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) + { + return $uri->getScheme() === '' && $uri->getAuthority() === '' && isset($uri->getPath()[0]) && $uri->getPath()[0] === '/'; + } + /** + * Whether the URI is a relative-path reference. + * + * A relative reference that does not begin with a slash character is termed a relative-path reference. + * + * @param UriInterface $uri + * + * @return bool + * @link https://tools.ietf.org/html/rfc3986#section-4.2 + */ + public static function isRelativePathReference(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) + { + return $uri->getScheme() === '' && $uri->getAuthority() === '' && (!isset($uri->getPath()[0]) || $uri->getPath()[0] !== '/'); + } + /** + * Whether the URI is a same-document reference. + * + * A same-document reference refers to a URI that is, aside from its fragment + * component, identical to the base URI. When no base URI is given, only an empty + * URI reference (apart from its fragment) is considered a same-document reference. + * + * @param UriInterface $uri The URI to check + * @param UriInterface|null $base An optional base URI to compare against + * + * @return bool + * @link https://tools.ietf.org/html/rfc3986#section-4.4 + */ + public static function isSameDocumentReference(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $base = null) + { + if ($base !== null) { + $uri = \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::resolve($base, $uri); + return $uri->getScheme() === $base->getScheme() && $uri->getAuthority() === $base->getAuthority() && $uri->getPath() === $base->getPath() && $uri->getQuery() === $base->getQuery(); + } + return $uri->getScheme() === '' && $uri->getAuthority() === '' && $uri->getPath() === '' && $uri->getQuery() === ''; + } + /** + * Removes dot segments from a path and returns the new path. + * + * @param string $path + * + * @return string + * + * @deprecated since version 1.4. Use UriResolver::removeDotSegments instead. + * @see UriResolver::removeDotSegments + */ + public static function removeDotSegments($path) + { + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::removeDotSegments($path); + } + /** + * Converts the relative URI into a new URI that is resolved against the base URI. + * + * @param UriInterface $base Base URI + * @param string|UriInterface $rel Relative URI + * + * @return UriInterface + * + * @deprecated since version 1.4. Use UriResolver::resolve instead. + * @see UriResolver::resolve + */ + public static function resolve(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $base, $rel) + { + if (!$rel instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface) { + $rel = new self($rel); + } + return \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::resolve($base, $rel); + } + /** + * Creates a new URI with a specific query string value removed. + * + * Any existing query string values that exactly match the provided key are + * removed. + * + * @param UriInterface $uri URI to use as a base. + * @param string $key Query string key to remove. + * + * @return UriInterface + */ + public static function withoutQueryValue(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, $key) + { + $result = self::getFilteredQueryString($uri, [$key]); + return $uri->withQuery(\implode('&', $result)); + } + /** + * Creates a new URI with a specific query string value. + * + * Any existing query string values that exactly match the provided key are + * removed and replaced with the given key value pair. + * + * A value of null will set the query string key without a value, e.g. "key" + * instead of "key=value". + * + * @param UriInterface $uri URI to use as a base. + * @param string $key Key to set. + * @param string|null $value Value to set + * + * @return UriInterface + */ + public static function withQueryValue(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, $key, $value) + { + $result = self::getFilteredQueryString($uri, [$key]); + $result[] = self::generateQueryString($key, $value); + return $uri->withQuery(\implode('&', $result)); + } + /** + * Creates a new URI with multiple specific query string values. + * + * It has the same behavior as withQueryValue() but for an associative array of key => value. + * + * @param UriInterface $uri URI to use as a base. + * @param array $keyValueArray Associative array of key and values + * + * @return UriInterface + */ + public static function withQueryValues(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, array $keyValueArray) + { + $result = self::getFilteredQueryString($uri, \array_keys($keyValueArray)); + foreach ($keyValueArray as $key => $value) { + $result[] = self::generateQueryString($key, $value); + } + return $uri->withQuery(\implode('&', $result)); + } + /** + * Creates a URI from a hash of `parse_url` components. + * + * @param array $parts + * + * @return UriInterface + * @link http://php.net/manual/en/function.parse-url.php + * + * @throws \InvalidArgumentException If the components do not form a valid URI. + */ + public static function fromParts(array $parts) + { + $uri = new self(); + $uri->applyParts($parts); + $uri->validateState(); + return $uri; + } + public function getScheme() + { + return $this->scheme; + } + public function getAuthority() + { + $authority = $this->host; + if ($this->userInfo !== '') { + $authority = $this->userInfo . '@' . $authority; + } + if ($this->port !== null) { + $authority .= ':' . $this->port; + } + return $authority; + } + public function getUserInfo() + { + return $this->userInfo; + } + public function getHost() + { + return $this->host; + } + public function getPort() + { + return $this->port; + } + public function getPath() + { + return $this->path; + } + public function getQuery() + { + return $this->query; + } + public function getFragment() + { + return $this->fragment; + } + public function withScheme($scheme) + { + $scheme = $this->filterScheme($scheme); + if ($this->scheme === $scheme) { + return $this; + } + $new = clone $this; + $new->scheme = $scheme; + $new->removeDefaultPort(); + $new->validateState(); + return $new; + } + public function withUserInfo($user, $password = null) + { + $info = $this->filterUserInfoComponent($user); + if ($password !== null) { + $info .= ':' . $this->filterUserInfoComponent($password); + } + if ($this->userInfo === $info) { + return $this; + } + $new = clone $this; + $new->userInfo = $info; + $new->validateState(); + return $new; + } + public function withHost($host) + { + $host = $this->filterHost($host); + if ($this->host === $host) { + return $this; + } + $new = clone $this; + $new->host = $host; + $new->validateState(); + return $new; + } + public function withPort($port) + { + $port = $this->filterPort($port); + if ($this->port === $port) { + return $this; + } + $new = clone $this; + $new->port = $port; + $new->removeDefaultPort(); + $new->validateState(); + return $new; + } + public function withPath($path) + { + $path = $this->filterPath($path); + if ($this->path === $path) { + return $this; + } + $new = clone $this; + $new->path = $path; + $new->validateState(); + return $new; + } + public function withQuery($query) + { + $query = $this->filterQueryAndFragment($query); + if ($this->query === $query) { + return $this; + } + $new = clone $this; + $new->query = $query; + return $new; + } + public function withFragment($fragment) + { + $fragment = $this->filterQueryAndFragment($fragment); + if ($this->fragment === $fragment) { + return $this; + } + $new = clone $this; + $new->fragment = $fragment; + return $new; + } + /** + * Apply parse_url parts to a URI. + * + * @param array $parts Array of parse_url parts to apply. + */ + private function applyParts(array $parts) + { + $this->scheme = isset($parts['scheme']) ? $this->filterScheme($parts['scheme']) : ''; + $this->userInfo = isset($parts['user']) ? $this->filterUserInfoComponent($parts['user']) : ''; + $this->host = isset($parts['host']) ? $this->filterHost($parts['host']) : ''; + $this->port = isset($parts['port']) ? $this->filterPort($parts['port']) : null; + $this->path = isset($parts['path']) ? $this->filterPath($parts['path']) : ''; + $this->query = isset($parts['query']) ? $this->filterQueryAndFragment($parts['query']) : ''; + $this->fragment = isset($parts['fragment']) ? $this->filterQueryAndFragment($parts['fragment']) : ''; + if (isset($parts['pass'])) { + $this->userInfo .= ':' . $this->filterUserInfoComponent($parts['pass']); + } + $this->removeDefaultPort(); + } + /** + * @param string $scheme + * + * @return string + * + * @throws \InvalidArgumentException If the scheme is invalid. + */ + private function filterScheme($scheme) + { + if (!\is_string($scheme)) { + throw new \InvalidArgumentException('Scheme must be a string'); + } + return \strtolower($scheme); + } + /** + * @param string $component + * + * @return string + * + * @throws \InvalidArgumentException If the user info is invalid. + */ + private function filterUserInfoComponent($component) + { + if (!\is_string($component)) { + throw new \InvalidArgumentException('User info must be a string'); + } + return \preg_replace_callback('/(?:[^%' . self::$charUnreserved . self::$charSubDelims . ']+|%(?![A-Fa-f0-9]{2}))/', [$this, 'rawurlencodeMatchZero'], $component); + } + /** + * @param string $host + * + * @return string + * + * @throws \InvalidArgumentException If the host is invalid. + */ + private function filterHost($host) + { + if (!\is_string($host)) { + throw new \InvalidArgumentException('Host must be a string'); + } + return \strtolower($host); + } + /** + * @param int|null $port + * + * @return int|null + * + * @throws \InvalidArgumentException If the port is invalid. + */ + private function filterPort($port) + { + if ($port === null) { + return null; + } + $port = (int) $port; + if (0 > $port || 0xffff < $port) { + throw new \InvalidArgumentException(\sprintf('Invalid port: %d. Must be between 0 and 65535', $port)); + } + return $port; + } + /** + * @param UriInterface $uri + * @param array $keys + * + * @return array + */ + private static function getFilteredQueryString(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri, array $keys) + { + $current = $uri->getQuery(); + if ($current === '') { + return []; + } + $decodedKeys = \array_map('rawurldecode', $keys); + return \array_filter(\explode('&', $current), function ($part) use($decodedKeys) { + return !\in_array(\rawurldecode(\explode('=', $part)[0]), $decodedKeys, \true); + }); + } + /** + * @param string $key + * @param string|null $value + * + * @return string + */ + private static function generateQueryString($key, $value) + { + // Query string separators ("=", "&") within the key or value need to be encoded + // (while preventing double-encoding) before setting the query string. All other + // chars that need percent-encoding will be encoded by withQuery(). + $queryString = \strtr($key, self::$replaceQuery); + if ($value !== null) { + $queryString .= '=' . \strtr($value, self::$replaceQuery); + } + return $queryString; + } + private function removeDefaultPort() + { + if ($this->port !== null && self::isDefaultPort($this)) { + $this->port = null; + } + } + /** + * Filters the path of a URI + * + * @param string $path + * + * @return string + * + * @throws \InvalidArgumentException If the path is invalid. + */ + private function filterPath($path) + { + if (!\is_string($path)) { + throw new \InvalidArgumentException('Path must be a string'); + } + return \preg_replace_callback('/(?:[^' . self::$charUnreserved . self::$charSubDelims . '%:@\\/]++|%(?![A-Fa-f0-9]{2}))/', [$this, 'rawurlencodeMatchZero'], $path); + } + /** + * Filters the query string or fragment of a URI. + * + * @param string $str + * + * @return string + * + * @throws \InvalidArgumentException If the query or fragment is invalid. + */ + private function filterQueryAndFragment($str) + { + if (!\is_string($str)) { + throw new \InvalidArgumentException('Query and fragment must be a string'); + } + return \preg_replace_callback('/(?:[^' . self::$charUnreserved . self::$charSubDelims . '%:@\\/\\?]++|%(?![A-Fa-f0-9]{2}))/', [$this, 'rawurlencodeMatchZero'], $str); + } + private function rawurlencodeMatchZero(array $match) + { + return \rawurlencode($match[0]); + } + private function validateState() + { + if ($this->host === '' && ($this->scheme === 'http' || $this->scheme === 'https')) { + $this->host = self::HTTP_DEFAULT_HOST; + } + if ($this->getAuthority() === '') { + if (0 === \strpos($this->path, '//')) { + throw new \InvalidArgumentException('The path of a URI without an authority must not start with two slashes "//"'); + } + if ($this->scheme === '' && \false !== \strpos(\explode('/', $this->path, 2)[0], ':')) { + throw new \InvalidArgumentException('A relative URI must not have a path beginning with a segment containing a colon'); + } + } elseif (isset($this->path[0]) && $this->path[0] !== '/') { + @\trigger_error('The path of a URI with an authority must start with a slash "/" or be empty. Automagically fixing the URI ' . 'by adding a leading slash to the path is deprecated since version 1.4 and will throw an exception instead.', \E_USER_DEPRECATED); + $this->path = '/' . $this->path; + //throw new \InvalidArgumentException('The path of a URI with an authority must start with a slash "/" or be empty'); + } + } +} diff --git a/vendor/guzzlehttp/psr7/src/UriNormalizer.php b/vendor/guzzlehttp/psr7/src/UriNormalizer.php index 04946f619..abb8ea7e0 100644 --- a/vendor/guzzlehttp/psr7/src/UriNormalizer.php +++ b/vendor/guzzlehttp/psr7/src/UriNormalizer.php @@ -1,179 +1,179 @@ -getPath() === '' && ($uri->getScheme() === 'http' || $uri->getScheme() === 'https')) { - $uri = $uri->withPath('/'); - } - if ($flags & self::REMOVE_DEFAULT_HOST && $uri->getScheme() === 'file' && $uri->getHost() === 'localhost') { - $uri = $uri->withHost(''); - } - if ($flags & self::REMOVE_DEFAULT_PORT && $uri->getPort() !== null && \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri::isDefaultPort($uri)) { - $uri = $uri->withPort(null); - } - if ($flags & self::REMOVE_DOT_SEGMENTS && !\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri::isRelativePathReference($uri)) { - $uri = $uri->withPath(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::removeDotSegments($uri->getPath())); - } - if ($flags & self::REMOVE_DUPLICATE_SLASHES) { - $uri = $uri->withPath(\preg_replace('#//++#', '/', $uri->getPath())); - } - if ($flags & self::SORT_QUERY_PARAMETERS && $uri->getQuery() !== '') { - $queryKeyValues = \explode('&', $uri->getQuery()); - \sort($queryKeyValues); - $uri = $uri->withQuery(\implode('&', $queryKeyValues)); - } - return $uri; - } - /** - * Whether two URIs can be considered equivalent. - * - * Both URIs are normalized automatically before comparison with the given $normalizations bitmask. The method also - * accepts relative URI references and returns true when they are equivalent. This of course assumes they will be - * resolved against the same base URI. If this is not the case, determination of equivalence or difference of - * relative references does not mean anything. - * - * @param UriInterface $uri1 An URI to compare - * @param UriInterface $uri2 An URI to compare - * @param int $normalizations A bitmask of normalizations to apply, see constants - * - * @return bool - * @link https://tools.ietf.org/html/rfc3986#section-6.1 - */ - public static function isEquivalent(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri1, \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri2, $normalizations = self::PRESERVING_NORMALIZATIONS) - { - return (string) self::normalize($uri1, $normalizations) === (string) self::normalize($uri2, $normalizations); - } - private static function capitalizePercentEncoding(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) - { - $regex = '/(?:%[A-Fa-f0-9]{2})++/'; - $callback = function (array $match) { - return \strtoupper($match[0]); - }; - return $uri->withPath(\preg_replace_callback($regex, $callback, $uri->getPath()))->withQuery(\preg_replace_callback($regex, $callback, $uri->getQuery())); - } - private static function decodeUnreservedCharacters(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) - { - $regex = '/%(?:2D|2E|5F|7E|3[0-9]|[46][1-9A-F]|[57][0-9A])/i'; - $callback = function (array $match) { - return \rawurldecode($match[0]); - }; - return $uri->withPath(\preg_replace_callback($regex, $callback, $uri->getPath()))->withQuery(\preg_replace_callback($regex, $callback, $uri->getQuery())); - } - private function __construct() - { - // cannot be instantiated - } -} +getPath() === '' && ($uri->getScheme() === 'http' || $uri->getScheme() === 'https')) { + $uri = $uri->withPath('/'); + } + if ($flags & self::REMOVE_DEFAULT_HOST && $uri->getScheme() === 'file' && $uri->getHost() === 'localhost') { + $uri = $uri->withHost(''); + } + if ($flags & self::REMOVE_DEFAULT_PORT && $uri->getPort() !== null && \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri::isDefaultPort($uri)) { + $uri = $uri->withPort(null); + } + if ($flags & self::REMOVE_DOT_SEGMENTS && !\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri::isRelativePathReference($uri)) { + $uri = $uri->withPath(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\UriResolver::removeDotSegments($uri->getPath())); + } + if ($flags & self::REMOVE_DUPLICATE_SLASHES) { + $uri = $uri->withPath(\preg_replace('#//++#', '/', $uri->getPath())); + } + if ($flags & self::SORT_QUERY_PARAMETERS && $uri->getQuery() !== '') { + $queryKeyValues = \explode('&', $uri->getQuery()); + \sort($queryKeyValues); + $uri = $uri->withQuery(\implode('&', $queryKeyValues)); + } + return $uri; + } + /** + * Whether two URIs can be considered equivalent. + * + * Both URIs are normalized automatically before comparison with the given $normalizations bitmask. The method also + * accepts relative URI references and returns true when they are equivalent. This of course assumes they will be + * resolved against the same base URI. If this is not the case, determination of equivalence or difference of + * relative references does not mean anything. + * + * @param UriInterface $uri1 An URI to compare + * @param UriInterface $uri2 An URI to compare + * @param int $normalizations A bitmask of normalizations to apply, see constants + * + * @return bool + * @link https://tools.ietf.org/html/rfc3986#section-6.1 + */ + public static function isEquivalent(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri1, \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri2, $normalizations = self::PRESERVING_NORMALIZATIONS) + { + return (string) self::normalize($uri1, $normalizations) === (string) self::normalize($uri2, $normalizations); + } + private static function capitalizePercentEncoding(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) + { + $regex = '/(?:%[A-Fa-f0-9]{2})++/'; + $callback = function (array $match) { + return \strtoupper($match[0]); + }; + return $uri->withPath(\preg_replace_callback($regex, $callback, $uri->getPath()))->withQuery(\preg_replace_callback($regex, $callback, $uri->getQuery())); + } + private static function decodeUnreservedCharacters(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $uri) + { + $regex = '/%(?:2D|2E|5F|7E|3[0-9]|[46][1-9A-F]|[57][0-9A])/i'; + $callback = function (array $match) { + return \rawurldecode($match[0]); + }; + return $uri->withPath(\preg_replace_callback($regex, $callback, $uri->getPath()))->withQuery(\preg_replace_callback($regex, $callback, $uri->getQuery())); + } + private function __construct() + { + // cannot be instantiated + } +} diff --git a/vendor/guzzlehttp/psr7/src/UriResolver.php b/vendor/guzzlehttp/psr7/src/UriResolver.php index a5d50b508..a68ce00e6 100644 --- a/vendor/guzzlehttp/psr7/src/UriResolver.php +++ b/vendor/guzzlehttp/psr7/src/UriResolver.php @@ -1,190 +1,190 @@ -getScheme() != '') { - return $rel->withPath(self::removeDotSegments($rel->getPath())); - } - if ($rel->getAuthority() != '') { - $targetAuthority = $rel->getAuthority(); - $targetPath = self::removeDotSegments($rel->getPath()); - $targetQuery = $rel->getQuery(); - } else { - $targetAuthority = $base->getAuthority(); - if ($rel->getPath() === '') { - $targetPath = $base->getPath(); - $targetQuery = $rel->getQuery() != '' ? $rel->getQuery() : $base->getQuery(); - } else { - if ($rel->getPath()[0] === '/') { - $targetPath = $rel->getPath(); - } else { - if ($targetAuthority != '' && $base->getPath() === '') { - $targetPath = '/' . $rel->getPath(); - } else { - $lastSlashPos = \strrpos($base->getPath(), '/'); - if ($lastSlashPos === \false) { - $targetPath = $rel->getPath(); - } else { - $targetPath = \substr($base->getPath(), 0, $lastSlashPos + 1) . $rel->getPath(); - } - } - } - $targetPath = self::removeDotSegments($targetPath); - $targetQuery = $rel->getQuery(); - } - } - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri::composeComponents($base->getScheme(), $targetAuthority, $targetPath, $targetQuery, $rel->getFragment())); - } - /** - * Returns the target URI as a relative reference from the base URI. - * - * This method is the counterpart to resolve(): - * - * (string) $target === (string) UriResolver::resolve($base, UriResolver::relativize($base, $target)) - * - * One use-case is to use the current request URI as base URI and then generate relative links in your documents - * to reduce the document size or offer self-contained downloadable document archives. - * - * $base = new Uri('http://example.com/a/b/'); - * echo UriResolver::relativize($base, new Uri('http://example.com/a/b/c')); // prints 'c'. - * echo UriResolver::relativize($base, new Uri('http://example.com/a/x/y')); // prints '../x/y'. - * echo UriResolver::relativize($base, new Uri('http://example.com/a/b/?q')); // prints '?q'. - * echo UriResolver::relativize($base, new Uri('http://example.org/a/b/')); // prints '//example.org/a/b/'. - * - * This method also accepts a target that is already relative and will try to relativize it further. Only a - * relative-path reference will be returned as-is. - * - * echo UriResolver::relativize($base, new Uri('/a/b/c')); // prints 'c' as well - * - * @param UriInterface $base Base URI - * @param UriInterface $target Target URI - * - * @return UriInterface The relative URI reference - */ - public static function relativize(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $base, \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $target) - { - if ($target->getScheme() !== '' && ($base->getScheme() !== $target->getScheme() || $target->getAuthority() === '' && $base->getAuthority() !== '')) { - return $target; - } - if (\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri::isRelativePathReference($target)) { - // As the target is already highly relative we return it as-is. It would be possible to resolve - // the target with `$target = self::resolve($base, $target);` and then try make it more relative - // by removing a duplicate query. But let's not do that automatically. - return $target; - } - if ($target->getAuthority() !== '' && $base->getAuthority() !== $target->getAuthority()) { - return $target->withScheme(''); - } - // We must remove the path before removing the authority because if the path starts with two slashes, the URI - // would turn invalid. And we also cannot set a relative path before removing the authority, as that is also - // invalid. - $emptyPathUri = $target->withScheme('')->withPath('')->withUserInfo('')->withPort(null)->withHost(''); - if ($base->getPath() !== $target->getPath()) { - return $emptyPathUri->withPath(self::getRelativePath($base, $target)); - } - if ($base->getQuery() === $target->getQuery()) { - // Only the target fragment is left. And it must be returned even if base and target fragment are the same. - return $emptyPathUri->withQuery(''); - } - // If the base URI has a query but the target has none, we cannot return an empty path reference as it would - // inherit the base query component when resolving. - if ($target->getQuery() === '') { - $segments = \explode('/', $target->getPath()); - $lastSegment = \end($segments); - return $emptyPathUri->withPath($lastSegment === '' ? './' : $lastSegment); - } - return $emptyPathUri; - } - private static function getRelativePath(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $base, \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $target) - { - $sourceSegments = \explode('/', $base->getPath()); - $targetSegments = \explode('/', $target->getPath()); - \array_pop($sourceSegments); - $targetLastSegment = \array_pop($targetSegments); - foreach ($sourceSegments as $i => $segment) { - if (isset($targetSegments[$i]) && $segment === $targetSegments[$i]) { - unset($sourceSegments[$i], $targetSegments[$i]); - } else { - break; - } - } - $targetSegments[] = $targetLastSegment; - $relativePath = \str_repeat('../', \count($sourceSegments)) . \implode('/', $targetSegments); - // A reference to am empty last segment or an empty first sub-segment must be prefixed with "./". - // This also applies to a segment with a colon character (e.g., "file:colon") that cannot be used - // as the first segment of a relative-path reference, as it would be mistaken for a scheme name. - if ('' === $relativePath || \false !== \strpos(\explode('/', $relativePath, 2)[0], ':')) { - $relativePath = "./{$relativePath}"; - } elseif ('/' === $relativePath[0]) { - if ($base->getAuthority() != '' && $base->getPath() === '') { - // In this case an extra slash is added by resolve() automatically. So we must not add one here. - $relativePath = ".{$relativePath}"; - } else { - $relativePath = "./{$relativePath}"; - } - } - return $relativePath; - } - private function __construct() - { - // cannot be instantiated - } -} +getScheme() != '') { + return $rel->withPath(self::removeDotSegments($rel->getPath())); + } + if ($rel->getAuthority() != '') { + $targetAuthority = $rel->getAuthority(); + $targetPath = self::removeDotSegments($rel->getPath()); + $targetQuery = $rel->getQuery(); + } else { + $targetAuthority = $base->getAuthority(); + if ($rel->getPath() === '') { + $targetPath = $base->getPath(); + $targetQuery = $rel->getQuery() != '' ? $rel->getQuery() : $base->getQuery(); + } else { + if ($rel->getPath()[0] === '/') { + $targetPath = $rel->getPath(); + } else { + if ($targetAuthority != '' && $base->getPath() === '') { + $targetPath = '/' . $rel->getPath(); + } else { + $lastSlashPos = \strrpos($base->getPath(), '/'); + if ($lastSlashPos === \false) { + $targetPath = $rel->getPath(); + } else { + $targetPath = \substr($base->getPath(), 0, $lastSlashPos + 1) . $rel->getPath(); + } + } + } + $targetPath = self::removeDotSegments($targetPath); + $targetQuery = $rel->getQuery(); + } + } + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri::composeComponents($base->getScheme(), $targetAuthority, $targetPath, $targetQuery, $rel->getFragment())); + } + /** + * Returns the target URI as a relative reference from the base URI. + * + * This method is the counterpart to resolve(): + * + * (string) $target === (string) UriResolver::resolve($base, UriResolver::relativize($base, $target)) + * + * One use-case is to use the current request URI as base URI and then generate relative links in your documents + * to reduce the document size or offer self-contained downloadable document archives. + * + * $base = new Uri('http://example.com/a/b/'); + * echo UriResolver::relativize($base, new Uri('http://example.com/a/b/c')); // prints 'c'. + * echo UriResolver::relativize($base, new Uri('http://example.com/a/x/y')); // prints '../x/y'. + * echo UriResolver::relativize($base, new Uri('http://example.com/a/b/?q')); // prints '?q'. + * echo UriResolver::relativize($base, new Uri('http://example.org/a/b/')); // prints '//example.org/a/b/'. + * + * This method also accepts a target that is already relative and will try to relativize it further. Only a + * relative-path reference will be returned as-is. + * + * echo UriResolver::relativize($base, new Uri('/a/b/c')); // prints 'c' as well + * + * @param UriInterface $base Base URI + * @param UriInterface $target Target URI + * + * @return UriInterface The relative URI reference + */ + public static function relativize(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $base, \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $target) + { + if ($target->getScheme() !== '' && ($base->getScheme() !== $target->getScheme() || $target->getAuthority() === '' && $base->getAuthority() !== '')) { + return $target; + } + if (\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri::isRelativePathReference($target)) { + // As the target is already highly relative we return it as-is. It would be possible to resolve + // the target with `$target = self::resolve($base, $target);` and then try make it more relative + // by removing a duplicate query. But let's not do that automatically. + return $target; + } + if ($target->getAuthority() !== '' && $base->getAuthority() !== $target->getAuthority()) { + return $target->withScheme(''); + } + // We must remove the path before removing the authority because if the path starts with two slashes, the URI + // would turn invalid. And we also cannot set a relative path before removing the authority, as that is also + // invalid. + $emptyPathUri = $target->withScheme('')->withPath('')->withUserInfo('')->withPort(null)->withHost(''); + if ($base->getPath() !== $target->getPath()) { + return $emptyPathUri->withPath(self::getRelativePath($base, $target)); + } + if ($base->getQuery() === $target->getQuery()) { + // Only the target fragment is left. And it must be returned even if base and target fragment are the same. + return $emptyPathUri->withQuery(''); + } + // If the base URI has a query but the target has none, we cannot return an empty path reference as it would + // inherit the base query component when resolving. + if ($target->getQuery() === '') { + $segments = \explode('/', $target->getPath()); + $lastSegment = \end($segments); + return $emptyPathUri->withPath($lastSegment === '' ? './' : $lastSegment); + } + return $emptyPathUri; + } + private static function getRelativePath(\_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $base, \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface $target) + { + $sourceSegments = \explode('/', $base->getPath()); + $targetSegments = \explode('/', $target->getPath()); + \array_pop($sourceSegments); + $targetLastSegment = \array_pop($targetSegments); + foreach ($sourceSegments as $i => $segment) { + if (isset($targetSegments[$i]) && $segment === $targetSegments[$i]) { + unset($sourceSegments[$i], $targetSegments[$i]); + } else { + break; + } + } + $targetSegments[] = $targetLastSegment; + $relativePath = \str_repeat('../', \count($sourceSegments)) . \implode('/', $targetSegments); + // A reference to am empty last segment or an empty first sub-segment must be prefixed with "./". + // This also applies to a segment with a colon character (e.g., "file:colon") that cannot be used + // as the first segment of a relative-path reference, as it would be mistaken for a scheme name. + if ('' === $relativePath || \false !== \strpos(\explode('/', $relativePath, 2)[0], ':')) { + $relativePath = "./{$relativePath}"; + } elseif ('/' === $relativePath[0]) { + if ($base->getAuthority() != '' && $base->getPath() === '') { + // In this case an extra slash is added by resolve() automatically. So we must not add one here. + $relativePath = ".{$relativePath}"; + } else { + $relativePath = "./{$relativePath}"; + } + } + return $relativePath; + } + private function __construct() + { + // cannot be instantiated + } +} diff --git a/vendor/guzzlehttp/psr7/src/functions.php b/vendor/guzzlehttp/psr7/src/functions.php index 05649c73d..e9954f748 100644 --- a/vendor/guzzlehttp/psr7/src/functions.php +++ b/vendor/guzzlehttp/psr7/src/functions.php @@ -1,657 +1,657 @@ -getMethod() . ' ' . $message->getRequestTarget()) . ' HTTP/' . $message->getProtocolVersion(); - if (!$message->hasHeader('host')) { - $msg .= "\r\nHost: " . $message->getUri()->getHost(); - } - } elseif ($message instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface) { - $msg = 'HTTP/' . $message->getProtocolVersion() . ' ' . $message->getStatusCode() . ' ' . $message->getReasonPhrase(); - } else { - throw new \InvalidArgumentException('Unknown message type'); - } - foreach ($message->getHeaders() as $name => $values) { - $msg .= "\r\n{$name}: " . \implode(', ', $values); - } - return "{$msg}\r\n\r\n" . $message->getBody(); -} -/** - * Returns a UriInterface for the given value. - * - * This function accepts a string or {@see Psr\Http\Message\UriInterface} and - * returns a UriInterface for the given value. If the value is already a - * `UriInterface`, it is returned as-is. - * - * @param string|UriInterface $uri - * - * @return UriInterface - * @throws \InvalidArgumentException - */ -function uri_for($uri) -{ - if ($uri instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface) { - return $uri; - } elseif (\is_string($uri)) { - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri($uri); - } - throw new \InvalidArgumentException('URI must be a string or UriInterface'); -} -/** - * Create a new stream based on the input type. - * - * Options is an associative array that can contain the following keys: - * - metadata: Array of custom metadata. - * - size: Size of the stream. - * - * @param resource|string|null|int|float|bool|StreamInterface|callable|\Iterator $resource Entity body data - * @param array $options Additional options - * - * @return StreamInterface - * @throws \InvalidArgumentException if the $resource arg is not valid. - */ -function stream_for($resource = '', array $options = []) -{ - if (\is_scalar($resource)) { - $stream = \fopen('php://temp', 'r+'); - if ($resource !== '') { - \fwrite($stream, $resource); - \fseek($stream, 0); - } - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream($stream, $options); - } - switch (\gettype($resource)) { - case 'resource': - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream($resource, $options); - case 'object': - if ($resource instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface) { - return $resource; - } elseif ($resource instanceof \Iterator) { - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\PumpStream(function () use($resource) { - if (!$resource->valid()) { - return \false; - } - $result = $resource->current(); - $resource->next(); - return $result; - }, $options); - } elseif (\method_exists($resource, '__toString')) { - return stream_for((string) $resource, $options); - } - break; - case 'NULL': - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream(\fopen('php://temp', 'r+'), $options); - } - if (\is_callable($resource)) { - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\PumpStream($resource, $options); - } - throw new \InvalidArgumentException('Invalid resource type: ' . \gettype($resource)); -} -/** - * Parse an array of header values containing ";" separated data into an - * array of associative arrays representing the header key value pair - * data of the header. When a parameter does not contain a value, but just - * contains a key, this function will inject a key with a '' string value. - * - * @param string|array $header Header to parse into components. - * - * @return array Returns the parsed header values. - */ -function parse_header($header) -{ - static $trimmed = "\"' \n\t\r"; - $params = $matches = []; - foreach (normalize_header($header) as $val) { - $part = []; - foreach (\preg_split('/;(?=([^"]*"[^"]*")*[^"]*$)/', $val) as $kvp) { - if (\preg_match_all('/<[^>]+>|[^=]+/', $kvp, $matches)) { - $m = $matches[0]; - if (isset($m[1])) { - $part[\trim($m[0], $trimmed)] = \trim($m[1], $trimmed); - } else { - $part[] = \trim($m[0], $trimmed); - } - } - } - if ($part) { - $params[] = $part; - } - } - return $params; -} -/** - * Converts an array of header values that may contain comma separated - * headers into an array of headers with no comma separated values. - * - * @param string|array $header Header to normalize. - * - * @return array Returns the normalized header field values. - */ -function normalize_header($header) -{ - if (!\is_array($header)) { - return \array_map('trim', \explode(',', $header)); - } - $result = []; - foreach ($header as $value) { - foreach ((array) $value as $v) { - if (\strpos($v, ',') === \false) { - $result[] = $v; - continue; - } - foreach (\preg_split('/,(?=([^"]*"[^"]*")*[^"]*$)/', $v) as $vv) { - $result[] = \trim($vv); - } - } - } - return $result; -} -/** - * Clone and modify a request with the given changes. - * - * The changes can be one of: - * - method: (string) Changes the HTTP method. - * - set_headers: (array) Sets the given headers. - * - remove_headers: (array) Remove the given headers. - * - body: (mixed) Sets the given body. - * - uri: (UriInterface) Set the URI. - * - query: (string) Set the query string value of the URI. - * - version: (string) Set the protocol version. - * - * @param RequestInterface $request Request to clone and modify. - * @param array $changes Changes to apply. - * - * @return RequestInterface - */ -function modify_request(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $changes) -{ - if (!$changes) { - return $request; - } - $headers = $request->getHeaders(); - if (!isset($changes['uri'])) { - $uri = $request->getUri(); - } else { - // Remove the host header if one is on the URI - if ($host = $changes['uri']->getHost()) { - $changes['set_headers']['Host'] = $host; - if ($port = $changes['uri']->getPort()) { - $standardPorts = ['http' => 80, 'https' => 443]; - $scheme = $changes['uri']->getScheme(); - if (isset($standardPorts[$scheme]) && $port != $standardPorts[$scheme]) { - $changes['set_headers']['Host'] .= ':' . $port; - } - } - } - $uri = $changes['uri']; - } - if (!empty($changes['remove_headers'])) { - $headers = _caseless_remove($changes['remove_headers'], $headers); - } - if (!empty($changes['set_headers'])) { - $headers = _caseless_remove(\array_keys($changes['set_headers']), $headers); - $headers = $changes['set_headers'] + $headers; - } - if (isset($changes['query'])) { - $uri = $uri->withQuery($changes['query']); - } - if ($request instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\ServerRequestInterface) { - return (new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\ServerRequest(isset($changes['method']) ? $changes['method'] : $request->getMethod(), $uri, $headers, isset($changes['body']) ? $changes['body'] : $request->getBody(), isset($changes['version']) ? $changes['version'] : $request->getProtocolVersion(), $request->getServerParams()))->withParsedBody($request->getParsedBody())->withQueryParams($request->getQueryParams())->withCookieParams($request->getCookieParams())->withUploadedFiles($request->getUploadedFiles()); - } - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Request(isset($changes['method']) ? $changes['method'] : $request->getMethod(), $uri, $headers, isset($changes['body']) ? $changes['body'] : $request->getBody(), isset($changes['version']) ? $changes['version'] : $request->getProtocolVersion()); -} -/** - * Attempts to rewind a message body and throws an exception on failure. - * - * The body of the message will only be rewound if a call to `tell()` returns a - * value other than `0`. - * - * @param MessageInterface $message Message to rewind - * - * @throws \RuntimeException - */ -function rewind_body(\_PhpScoper5ea00cc67502b\Psr\Http\Message\MessageInterface $message) -{ - $body = $message->getBody(); - if ($body->tell()) { - $body->rewind(); - } -} -/** - * Safely opens a PHP stream resource using a filename. - * - * When fopen fails, PHP normally raises a warning. This function adds an - * error handler that checks for errors and throws an exception instead. - * - * @param string $filename File to open - * @param string $mode Mode used to open the file - * - * @return resource - * @throws \RuntimeException if the file cannot be opened - */ -function try_fopen($filename, $mode) -{ - $ex = null; - \set_error_handler(function () use($filename, $mode, &$ex) { - $ex = new \RuntimeException(\sprintf('Unable to open %s using mode %s: %s', $filename, $mode, \func_get_args()[1])); - }); - $handle = \fopen($filename, $mode); - \restore_error_handler(); - if ($ex) { - /** @var $ex \RuntimeException */ - throw $ex; - } - return $handle; -} -/** - * Copy the contents of a stream into a string until the given number of - * bytes have been read. - * - * @param StreamInterface $stream Stream to read - * @param int $maxLen Maximum number of bytes to read. Pass -1 - * to read the entire stream. - * @return string - * @throws \RuntimeException on error. - */ -function copy_to_string(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, $maxLen = -1) -{ - $buffer = ''; - if ($maxLen === -1) { - while (!$stream->eof()) { - $buf = $stream->read(1048576); - // Using a loose equality here to match on '' and false. - if ($buf == null) { - break; - } - $buffer .= $buf; - } - return $buffer; - } - $len = 0; - while (!$stream->eof() && $len < $maxLen) { - $buf = $stream->read($maxLen - $len); - // Using a loose equality here to match on '' and false. - if ($buf == null) { - break; - } - $buffer .= $buf; - $len = \strlen($buffer); - } - return $buffer; -} -/** - * Copy the contents of a stream into another stream until the given number - * of bytes have been read. - * - * @param StreamInterface $source Stream to read from - * @param StreamInterface $dest Stream to write to - * @param int $maxLen Maximum number of bytes to read. Pass -1 - * to read the entire stream. - * - * @throws \RuntimeException on error. - */ -function copy_to_stream(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $source, \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $dest, $maxLen = -1) -{ - $bufferSize = 8192; - if ($maxLen === -1) { - while (!$source->eof()) { - if (!$dest->write($source->read($bufferSize))) { - break; - } - } - } else { - $remaining = $maxLen; - while ($remaining > 0 && !$source->eof()) { - $buf = $source->read(\min($bufferSize, $remaining)); - $len = \strlen($buf); - if (!$len) { - break; - } - $remaining -= $len; - $dest->write($buf); - } - } -} -/** - * Calculate a hash of a Stream - * - * @param StreamInterface $stream Stream to calculate the hash for - * @param string $algo Hash algorithm (e.g. md5, crc32, etc) - * @param bool $rawOutput Whether or not to use raw output - * - * @return string Returns the hash of the stream - * @throws \RuntimeException on error. - */ -function hash(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, $algo, $rawOutput = \false) -{ - $pos = $stream->tell(); - if ($pos > 0) { - $stream->rewind(); - } - $ctx = \hash_init($algo); - while (!$stream->eof()) { - \hash_update($ctx, $stream->read(1048576)); - } - $out = \hash_final($ctx, (bool) $rawOutput); - $stream->seek($pos); - return $out; -} -/** - * Read a line from the stream up to the maximum allowed buffer length - * - * @param StreamInterface $stream Stream to read from - * @param int $maxLength Maximum buffer length - * - * @return string - */ -function readline(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, $maxLength = null) -{ - $buffer = ''; - $size = 0; - while (!$stream->eof()) { - // Using a loose equality here to match on '' and false. - if (null == ($byte = $stream->read(1))) { - return $buffer; - } - $buffer .= $byte; - // Break when a new line is found or the max length - 1 is reached - if ($byte === "\n" || ++$size === $maxLength - 1) { - break; - } - } - return $buffer; -} -/** - * Parses a request message string into a request object. - * - * @param string $message Request message string. - * - * @return Request - */ -function parse_request($message) -{ - $data = _parse_message($message); - $matches = []; - if (!\preg_match('/^[\\S]+\\s+([a-zA-Z]+:\\/\\/|\\/).*/', $data['start-line'], $matches)) { - throw new \InvalidArgumentException('Invalid request string'); - } - $parts = \explode(' ', $data['start-line'], 3); - $version = isset($parts[2]) ? \explode('/', $parts[2])[1] : '1.1'; - $request = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Request($parts[0], $matches[1] === '/' ? _parse_request_uri($parts[1], $data['headers']) : $parts[1], $data['headers'], $data['body'], $version); - return $matches[1] === '/' ? $request : $request->withRequestTarget($parts[1]); -} -/** - * Parses a response message string into a response object. - * - * @param string $message Response message string. - * - * @return Response - */ -function parse_response($message) -{ - $data = _parse_message($message); - // According to https://tools.ietf.org/html/rfc7230#section-3.1.2 the space - // between status-code and reason-phrase is required. But browsers accept - // responses without space and reason as well. - if (!\preg_match('/^HTTP\\/.* [0-9]{3}( .*|$)/', $data['start-line'])) { - throw new \InvalidArgumentException('Invalid response string: ' . $data['start-line']); - } - $parts = \explode(' ', $data['start-line'], 3); - return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Response($parts[1], $data['headers'], $data['body'], \explode('/', $parts[0])[1], isset($parts[2]) ? $parts[2] : null); -} -/** - * Parse a query string into an associative array. - * - * If multiple values are found for the same key, the value of that key - * value pair will become an array. This function does not parse nested - * PHP style arrays into an associative array (e.g., foo[a]=1&foo[b]=2 will - * be parsed into ['foo[a]' => '1', 'foo[b]' => '2']). - * - * @param string $str Query string to parse - * @param int|bool $urlEncoding How the query string is encoded - * - * @return array - */ -function parse_query($str, $urlEncoding = \true) -{ - $result = []; - if ($str === '') { - return $result; - } - if ($urlEncoding === \true) { - $decoder = function ($value) { - return \rawurldecode(\str_replace('+', ' ', $value)); - }; - } elseif ($urlEncoding === \PHP_QUERY_RFC3986) { - $decoder = 'rawurldecode'; - } elseif ($urlEncoding === \PHP_QUERY_RFC1738) { - $decoder = 'urldecode'; - } else { - $decoder = function ($str) { - return $str; - }; - } - foreach (\explode('&', $str) as $kvp) { - $parts = \explode('=', $kvp, 2); - $key = $decoder($parts[0]); - $value = isset($parts[1]) ? $decoder($parts[1]) : null; - if (!isset($result[$key])) { - $result[$key] = $value; - } else { - if (!\is_array($result[$key])) { - $result[$key] = [$result[$key]]; - } - $result[$key][] = $value; - } - } - return $result; -} -/** - * Build a query string from an array of key value pairs. - * - * This function can use the return value of parse_query() to build a query - * string. This function does not modify the provided keys when an array is - * encountered (like http_build_query would). - * - * @param array $params Query string parameters. - * @param int|false $encoding Set to false to not encode, PHP_QUERY_RFC3986 - * to encode using RFC3986, or PHP_QUERY_RFC1738 - * to encode using RFC1738. - * @return string - */ -function build_query(array $params, $encoding = \PHP_QUERY_RFC3986) -{ - if (!$params) { - return ''; - } - if ($encoding === \false) { - $encoder = function ($str) { - return $str; - }; - } elseif ($encoding === \PHP_QUERY_RFC3986) { - $encoder = 'rawurlencode'; - } elseif ($encoding === \PHP_QUERY_RFC1738) { - $encoder = 'urlencode'; - } else { - throw new \InvalidArgumentException('Invalid type'); - } - $qs = ''; - foreach ($params as $k => $v) { - $k = $encoder($k); - if (!\is_array($v)) { - $qs .= $k; - if ($v !== null) { - $qs .= '=' . $encoder($v); - } - $qs .= '&'; - } else { - foreach ($v as $vv) { - $qs .= $k; - if ($vv !== null) { - $qs .= '=' . $encoder($vv); - } - $qs .= '&'; - } - } - } - return $qs ? (string) \substr($qs, 0, -1) : ''; -} -/** - * Determines the mimetype of a file by looking at its extension. - * - * @param $filename - * - * @return null|string - */ -function mimetype_from_filename($filename) -{ - return mimetype_from_extension(\pathinfo($filename, \PATHINFO_EXTENSION)); -} -/** - * Maps a file extensions to a mimetype. - * - * @param $extension string The file extension. - * - * @return string|null - * @link http://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x/conf/mime.types - */ -function mimetype_from_extension($extension) -{ - static $mimetypes = ['3gp' => 'video/3gpp', '7z' => 'application/x-7z-compressed', 'aac' => 'audio/x-aac', 'ai' => 'application/postscript', 'aif' => 'audio/x-aiff', 'asc' => 'text/plain', 'asf' => 'video/x-ms-asf', 'atom' => 'application/atom+xml', 'avi' => 'video/x-msvideo', 'bmp' => 'image/bmp', 'bz2' => 'application/x-bzip2', 'cer' => 'application/pkix-cert', 'crl' => 'application/pkix-crl', 'crt' => 'application/x-x509-ca-cert', 'css' => 'text/css', 'csv' => 'text/csv', 'cu' => 'application/cu-seeme', 'deb' => 'application/x-debian-package', 'doc' => 'application/msword', 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'dvi' => 'application/x-dvi', 'eot' => 'application/vnd.ms-fontobject', 'eps' => 'application/postscript', 'epub' => 'application/epub+zip', 'etx' => 'text/x-setext', 'flac' => 'audio/flac', 'flv' => 'video/x-flv', 'gif' => 'image/gif', 'gz' => 'application/gzip', 'htm' => 'text/html', 'html' => 'text/html', 'ico' => 'image/x-icon', 'ics' => 'text/calendar', 'ini' => 'text/plain', 'iso' => 'application/x-iso9660-image', 'jar' => 'application/java-archive', 'jpe' => 'image/jpeg', 'jpeg' => 'image/jpeg', 'jpg' => 'image/jpeg', 'js' => 'text/javascript', 'json' => 'application/json', 'latex' => 'application/x-latex', 'log' => 'text/plain', 'm4a' => 'audio/mp4', 'm4v' => 'video/mp4', 'mid' => 'audio/midi', 'midi' => 'audio/midi', 'mov' => 'video/quicktime', 'mkv' => 'video/x-matroska', 'mp3' => 'audio/mpeg', 'mp4' => 'video/mp4', 'mp4a' => 'audio/mp4', 'mp4v' => 'video/mp4', 'mpe' => 'video/mpeg', 'mpeg' => 'video/mpeg', 'mpg' => 'video/mpeg', 'mpg4' => 'video/mp4', 'oga' => 'audio/ogg', 'ogg' => 'audio/ogg', 'ogv' => 'video/ogg', 'ogx' => 'application/ogg', 'pbm' => 'image/x-portable-bitmap', 'pdf' => 'application/pdf', 'pgm' => 'image/x-portable-graymap', 'png' => 'image/png', 'pnm' => 'image/x-portable-anymap', 'ppm' => 'image/x-portable-pixmap', 'ppt' => 'application/vnd.ms-powerpoint', 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation', 'ps' => 'application/postscript', 'qt' => 'video/quicktime', 'rar' => 'application/x-rar-compressed', 'ras' => 'image/x-cmu-raster', 'rss' => 'application/rss+xml', 'rtf' => 'application/rtf', 'sgm' => 'text/sgml', 'sgml' => 'text/sgml', 'svg' => 'image/svg+xml', 'swf' => 'application/x-shockwave-flash', 'tar' => 'application/x-tar', 'tif' => 'image/tiff', 'tiff' => 'image/tiff', 'torrent' => 'application/x-bittorrent', 'ttf' => 'application/x-font-ttf', 'txt' => 'text/plain', 'wav' => 'audio/x-wav', 'webm' => 'video/webm', 'webp' => 'image/webp', 'wma' => 'audio/x-ms-wma', 'wmv' => 'video/x-ms-wmv', 'woff' => 'application/x-font-woff', 'wsdl' => 'application/wsdl+xml', 'xbm' => 'image/x-xbitmap', 'xls' => 'application/vnd.ms-excel', 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'xml' => 'application/xml', 'xpm' => 'image/x-xpixmap', 'xwd' => 'image/x-xwindowdump', 'yaml' => 'text/yaml', 'yml' => 'text/yaml', 'zip' => 'application/zip']; - $extension = \strtolower($extension); - return isset($mimetypes[$extension]) ? $mimetypes[$extension] : null; -} -/** - * Parses an HTTP message into an associative array. - * - * The array contains the "start-line" key containing the start line of - * the message, "headers" key containing an associative array of header - * array values, and a "body" key containing the body of the message. - * - * @param string $message HTTP request or response to parse. - * - * @return array - * @internal - */ -function _parse_message($message) -{ - if (!$message) { - throw new \InvalidArgumentException('Invalid message'); - } - $message = \ltrim($message, "\r\n"); - $messageParts = \preg_split("/\r?\n\r?\n/", $message, 2); - if ($messageParts === \false || \count($messageParts) !== 2) { - throw new \InvalidArgumentException('Invalid message: Missing header delimiter'); - } - list($rawHeaders, $body) = $messageParts; - $rawHeaders .= "\r\n"; - // Put back the delimiter we split previously - $headerParts = \preg_split("/\r?\n/", $rawHeaders, 2); - if ($headerParts === \false || \count($headerParts) !== 2) { - throw new \InvalidArgumentException('Invalid message: Missing status line'); - } - list($startLine, $rawHeaders) = $headerParts; - if (\preg_match("/(?:^HTTP\\/|^[A-Z]+ \\S+ HTTP\\/)(\\d+(?:\\.\\d+)?)/i", $startLine, $matches) && $matches[1] === '1.0') { - // Header folding is deprecated for HTTP/1.1, but allowed in HTTP/1.0 - $rawHeaders = \preg_replace(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Rfc7230::HEADER_FOLD_REGEX, ' ', $rawHeaders); - } - /** @var array[] $headerLines */ - $count = \preg_match_all(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Rfc7230::HEADER_REGEX, $rawHeaders, $headerLines, \PREG_SET_ORDER); - // If these aren't the same, then one line didn't match and there's an invalid header. - if ($count !== \substr_count($rawHeaders, "\n")) { - // Folding is deprecated, see https://tools.ietf.org/html/rfc7230#section-3.2.4 - if (\preg_match(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Rfc7230::HEADER_FOLD_REGEX, $rawHeaders)) { - throw new \InvalidArgumentException('Invalid header syntax: Obsolete line folding'); - } - throw new \InvalidArgumentException('Invalid header syntax'); - } - $headers = []; - foreach ($headerLines as $headerLine) { - $headers[$headerLine[1]][] = $headerLine[2]; - } - return ['start-line' => $startLine, 'headers' => $headers, 'body' => $body]; -} -/** - * Constructs a URI for an HTTP request message. - * - * @param string $path Path from the start-line - * @param array $headers Array of headers (each value an array). - * - * @return string - * @internal - */ -function _parse_request_uri($path, array $headers) -{ - $hostKey = \array_filter(\array_keys($headers), function ($k) { - return \strtolower($k) === 'host'; - }); - // If no host is found, then a full URI cannot be constructed. - if (!$hostKey) { - return $path; - } - $host = $headers[\reset($hostKey)][0]; - $scheme = \substr($host, -4) === ':443' ? 'https' : 'http'; - return $scheme . '://' . $host . '/' . \ltrim($path, '/'); -} -/** - * Get a short summary of the message body - * - * Will return `null` if the response is not printable. - * - * @param MessageInterface $message The message to get the body summary - * @param int $truncateAt The maximum allowed size of the summary - * - * @return null|string - */ -function get_message_body_summary(\_PhpScoper5ea00cc67502b\Psr\Http\Message\MessageInterface $message, $truncateAt = 120) -{ - $body = $message->getBody(); - if (!$body->isSeekable() || !$body->isReadable()) { - return null; - } - $size = $body->getSize(); - if ($size === 0) { - return null; - } - $summary = $body->read($truncateAt); - $body->rewind(); - if ($size > $truncateAt) { - $summary .= ' (truncated...)'; - } - // Matches any printable character, including unicode characters: - // letters, marks, numbers, punctuation, spacing, and separators. - if (\preg_match('/[^\\pL\\pM\\pN\\pP\\pS\\pZ\\n\\r\\t]/', $summary)) { - return null; - } - return $summary; -} -/** @internal */ -function _caseless_remove($keys, array $data) -{ - $result = []; - foreach ($keys as &$key) { - $key = \strtolower($key); - } - foreach ($data as $k => $v) { - if (!\in_array(\strtolower($k), $keys)) { - $result[$k] = $v; - } - } - return $result; -} +getMethod() . ' ' . $message->getRequestTarget()) . ' HTTP/' . $message->getProtocolVersion(); + if (!$message->hasHeader('host')) { + $msg .= "\r\nHost: " . $message->getUri()->getHost(); + } + } elseif ($message instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface) { + $msg = 'HTTP/' . $message->getProtocolVersion() . ' ' . $message->getStatusCode() . ' ' . $message->getReasonPhrase(); + } else { + throw new \InvalidArgumentException('Unknown message type'); + } + foreach ($message->getHeaders() as $name => $values) { + $msg .= "\r\n{$name}: " . \implode(', ', $values); + } + return "{$msg}\r\n\r\n" . $message->getBody(); +} +/** + * Returns a UriInterface for the given value. + * + * This function accepts a string or {@see Psr\Http\Message\UriInterface} and + * returns a UriInterface for the given value. If the value is already a + * `UriInterface`, it is returned as-is. + * + * @param string|UriInterface $uri + * + * @return UriInterface + * @throws \InvalidArgumentException + */ +function uri_for($uri) +{ + if ($uri instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\UriInterface) { + return $uri; + } elseif (\is_string($uri)) { + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Uri($uri); + } + throw new \InvalidArgumentException('URI must be a string or UriInterface'); +} +/** + * Create a new stream based on the input type. + * + * Options is an associative array that can contain the following keys: + * - metadata: Array of custom metadata. + * - size: Size of the stream. + * + * @param resource|string|null|int|float|bool|StreamInterface|callable|\Iterator $resource Entity body data + * @param array $options Additional options + * + * @return StreamInterface + * @throws \InvalidArgumentException if the $resource arg is not valid. + */ +function stream_for($resource = '', array $options = []) +{ + if (\is_scalar($resource)) { + $stream = \fopen('php://temp', 'r+'); + if ($resource !== '') { + \fwrite($stream, $resource); + \fseek($stream, 0); + } + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream($stream, $options); + } + switch (\gettype($resource)) { + case 'resource': + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream($resource, $options); + case 'object': + if ($resource instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface) { + return $resource; + } elseif ($resource instanceof \Iterator) { + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\PumpStream(function () use($resource) { + if (!$resource->valid()) { + return \false; + } + $result = $resource->current(); + $resource->next(); + return $result; + }, $options); + } elseif (\method_exists($resource, '__toString')) { + return stream_for((string) $resource, $options); + } + break; + case 'NULL': + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Stream(\fopen('php://temp', 'r+'), $options); + } + if (\is_callable($resource)) { + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\PumpStream($resource, $options); + } + throw new \InvalidArgumentException('Invalid resource type: ' . \gettype($resource)); +} +/** + * Parse an array of header values containing ";" separated data into an + * array of associative arrays representing the header key value pair + * data of the header. When a parameter does not contain a value, but just + * contains a key, this function will inject a key with a '' string value. + * + * @param string|array $header Header to parse into components. + * + * @return array Returns the parsed header values. + */ +function parse_header($header) +{ + static $trimmed = "\"' \n\t\r"; + $params = $matches = []; + foreach (normalize_header($header) as $val) { + $part = []; + foreach (\preg_split('/;(?=([^"]*"[^"]*")*[^"]*$)/', $val) as $kvp) { + if (\preg_match_all('/<[^>]+>|[^=]+/', $kvp, $matches)) { + $m = $matches[0]; + if (isset($m[1])) { + $part[\trim($m[0], $trimmed)] = \trim($m[1], $trimmed); + } else { + $part[] = \trim($m[0], $trimmed); + } + } + } + if ($part) { + $params[] = $part; + } + } + return $params; +} +/** + * Converts an array of header values that may contain comma separated + * headers into an array of headers with no comma separated values. + * + * @param string|array $header Header to normalize. + * + * @return array Returns the normalized header field values. + */ +function normalize_header($header) +{ + if (!\is_array($header)) { + return \array_map('trim', \explode(',', $header)); + } + $result = []; + foreach ($header as $value) { + foreach ((array) $value as $v) { + if (\strpos($v, ',') === \false) { + $result[] = $v; + continue; + } + foreach (\preg_split('/,(?=([^"]*"[^"]*")*[^"]*$)/', $v) as $vv) { + $result[] = \trim($vv); + } + } + } + return $result; +} +/** + * Clone and modify a request with the given changes. + * + * The changes can be one of: + * - method: (string) Changes the HTTP method. + * - set_headers: (array) Sets the given headers. + * - remove_headers: (array) Remove the given headers. + * - body: (mixed) Sets the given body. + * - uri: (UriInterface) Set the URI. + * - query: (string) Set the query string value of the URI. + * - version: (string) Set the protocol version. + * + * @param RequestInterface $request Request to clone and modify. + * @param array $changes Changes to apply. + * + * @return RequestInterface + */ +function modify_request(\_PhpScoper5ea00cc67502b\Psr\Http\Message\RequestInterface $request, array $changes) +{ + if (!$changes) { + return $request; + } + $headers = $request->getHeaders(); + if (!isset($changes['uri'])) { + $uri = $request->getUri(); + } else { + // Remove the host header if one is on the URI + if ($host = $changes['uri']->getHost()) { + $changes['set_headers']['Host'] = $host; + if ($port = $changes['uri']->getPort()) { + $standardPorts = ['http' => 80, 'https' => 443]; + $scheme = $changes['uri']->getScheme(); + if (isset($standardPorts[$scheme]) && $port != $standardPorts[$scheme]) { + $changes['set_headers']['Host'] .= ':' . $port; + } + } + } + $uri = $changes['uri']; + } + if (!empty($changes['remove_headers'])) { + $headers = _caseless_remove($changes['remove_headers'], $headers); + } + if (!empty($changes['set_headers'])) { + $headers = _caseless_remove(\array_keys($changes['set_headers']), $headers); + $headers = $changes['set_headers'] + $headers; + } + if (isset($changes['query'])) { + $uri = $uri->withQuery($changes['query']); + } + if ($request instanceof \_PhpScoper5ea00cc67502b\Psr\Http\Message\ServerRequestInterface) { + return (new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\ServerRequest(isset($changes['method']) ? $changes['method'] : $request->getMethod(), $uri, $headers, isset($changes['body']) ? $changes['body'] : $request->getBody(), isset($changes['version']) ? $changes['version'] : $request->getProtocolVersion(), $request->getServerParams()))->withParsedBody($request->getParsedBody())->withQueryParams($request->getQueryParams())->withCookieParams($request->getCookieParams())->withUploadedFiles($request->getUploadedFiles()); + } + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Request(isset($changes['method']) ? $changes['method'] : $request->getMethod(), $uri, $headers, isset($changes['body']) ? $changes['body'] : $request->getBody(), isset($changes['version']) ? $changes['version'] : $request->getProtocolVersion()); +} +/** + * Attempts to rewind a message body and throws an exception on failure. + * + * The body of the message will only be rewound if a call to `tell()` returns a + * value other than `0`. + * + * @param MessageInterface $message Message to rewind + * + * @throws \RuntimeException + */ +function rewind_body(\_PhpScoper5ea00cc67502b\Psr\Http\Message\MessageInterface $message) +{ + $body = $message->getBody(); + if ($body->tell()) { + $body->rewind(); + } +} +/** + * Safely opens a PHP stream resource using a filename. + * + * When fopen fails, PHP normally raises a warning. This function adds an + * error handler that checks for errors and throws an exception instead. + * + * @param string $filename File to open + * @param string $mode Mode used to open the file + * + * @return resource + * @throws \RuntimeException if the file cannot be opened + */ +function try_fopen($filename, $mode) +{ + $ex = null; + \set_error_handler(function () use($filename, $mode, &$ex) { + $ex = new \RuntimeException(\sprintf('Unable to open %s using mode %s: %s', $filename, $mode, \func_get_args()[1])); + }); + $handle = \fopen($filename, $mode); + \restore_error_handler(); + if ($ex) { + /** @var $ex \RuntimeException */ + throw $ex; + } + return $handle; +} +/** + * Copy the contents of a stream into a string until the given number of + * bytes have been read. + * + * @param StreamInterface $stream Stream to read + * @param int $maxLen Maximum number of bytes to read. Pass -1 + * to read the entire stream. + * @return string + * @throws \RuntimeException on error. + */ +function copy_to_string(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, $maxLen = -1) +{ + $buffer = ''; + if ($maxLen === -1) { + while (!$stream->eof()) { + $buf = $stream->read(1048576); + // Using a loose equality here to match on '' and false. + if ($buf == null) { + break; + } + $buffer .= $buf; + } + return $buffer; + } + $len = 0; + while (!$stream->eof() && $len < $maxLen) { + $buf = $stream->read($maxLen - $len); + // Using a loose equality here to match on '' and false. + if ($buf == null) { + break; + } + $buffer .= $buf; + $len = \strlen($buffer); + } + return $buffer; +} +/** + * Copy the contents of a stream into another stream until the given number + * of bytes have been read. + * + * @param StreamInterface $source Stream to read from + * @param StreamInterface $dest Stream to write to + * @param int $maxLen Maximum number of bytes to read. Pass -1 + * to read the entire stream. + * + * @throws \RuntimeException on error. + */ +function copy_to_stream(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $source, \_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $dest, $maxLen = -1) +{ + $bufferSize = 8192; + if ($maxLen === -1) { + while (!$source->eof()) { + if (!$dest->write($source->read($bufferSize))) { + break; + } + } + } else { + $remaining = $maxLen; + while ($remaining > 0 && !$source->eof()) { + $buf = $source->read(\min($bufferSize, $remaining)); + $len = \strlen($buf); + if (!$len) { + break; + } + $remaining -= $len; + $dest->write($buf); + } + } +} +/** + * Calculate a hash of a Stream + * + * @param StreamInterface $stream Stream to calculate the hash for + * @param string $algo Hash algorithm (e.g. md5, crc32, etc) + * @param bool $rawOutput Whether or not to use raw output + * + * @return string Returns the hash of the stream + * @throws \RuntimeException on error. + */ +function hash(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, $algo, $rawOutput = \false) +{ + $pos = $stream->tell(); + if ($pos > 0) { + $stream->rewind(); + } + $ctx = \hash_init($algo); + while (!$stream->eof()) { + \hash_update($ctx, $stream->read(1048576)); + } + $out = \hash_final($ctx, (bool) $rawOutput); + $stream->seek($pos); + return $out; +} +/** + * Read a line from the stream up to the maximum allowed buffer length + * + * @param StreamInterface $stream Stream to read from + * @param int $maxLength Maximum buffer length + * + * @return string + */ +function readline(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $stream, $maxLength = null) +{ + $buffer = ''; + $size = 0; + while (!$stream->eof()) { + // Using a loose equality here to match on '' and false. + if (null == ($byte = $stream->read(1))) { + return $buffer; + } + $buffer .= $byte; + // Break when a new line is found or the max length - 1 is reached + if ($byte === "\n" || ++$size === $maxLength - 1) { + break; + } + } + return $buffer; +} +/** + * Parses a request message string into a request object. + * + * @param string $message Request message string. + * + * @return Request + */ +function parse_request($message) +{ + $data = _parse_message($message); + $matches = []; + if (!\preg_match('/^[\\S]+\\s+([a-zA-Z]+:\\/\\/|\\/).*/', $data['start-line'], $matches)) { + throw new \InvalidArgumentException('Invalid request string'); + } + $parts = \explode(' ', $data['start-line'], 3); + $version = isset($parts[2]) ? \explode('/', $parts[2])[1] : '1.1'; + $request = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Request($parts[0], $matches[1] === '/' ? _parse_request_uri($parts[1], $data['headers']) : $parts[1], $data['headers'], $data['body'], $version); + return $matches[1] === '/' ? $request : $request->withRequestTarget($parts[1]); +} +/** + * Parses a response message string into a response object. + * + * @param string $message Response message string. + * + * @return Response + */ +function parse_response($message) +{ + $data = _parse_message($message); + // According to https://tools.ietf.org/html/rfc7230#section-3.1.2 the space + // between status-code and reason-phrase is required. But browsers accept + // responses without space and reason as well. + if (!\preg_match('/^HTTP\\/.* [0-9]{3}( .*|$)/', $data['start-line'])) { + throw new \InvalidArgumentException('Invalid response string: ' . $data['start-line']); + } + $parts = \explode(' ', $data['start-line'], 3); + return new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Response($parts[1], $data['headers'], $data['body'], \explode('/', $parts[0])[1], isset($parts[2]) ? $parts[2] : null); +} +/** + * Parse a query string into an associative array. + * + * If multiple values are found for the same key, the value of that key + * value pair will become an array. This function does not parse nested + * PHP style arrays into an associative array (e.g., foo[a]=1&foo[b]=2 will + * be parsed into ['foo[a]' => '1', 'foo[b]' => '2']). + * + * @param string $str Query string to parse + * @param int|bool $urlEncoding How the query string is encoded + * + * @return array + */ +function parse_query($str, $urlEncoding = \true) +{ + $result = []; + if ($str === '') { + return $result; + } + if ($urlEncoding === \true) { + $decoder = function ($value) { + return \rawurldecode(\str_replace('+', ' ', $value)); + }; + } elseif ($urlEncoding === \PHP_QUERY_RFC3986) { + $decoder = 'rawurldecode'; + } elseif ($urlEncoding === \PHP_QUERY_RFC1738) { + $decoder = 'urldecode'; + } else { + $decoder = function ($str) { + return $str; + }; + } + foreach (\explode('&', $str) as $kvp) { + $parts = \explode('=', $kvp, 2); + $key = $decoder($parts[0]); + $value = isset($parts[1]) ? $decoder($parts[1]) : null; + if (!isset($result[$key])) { + $result[$key] = $value; + } else { + if (!\is_array($result[$key])) { + $result[$key] = [$result[$key]]; + } + $result[$key][] = $value; + } + } + return $result; +} +/** + * Build a query string from an array of key value pairs. + * + * This function can use the return value of parse_query() to build a query + * string. This function does not modify the provided keys when an array is + * encountered (like http_build_query would). + * + * @param array $params Query string parameters. + * @param int|false $encoding Set to false to not encode, PHP_QUERY_RFC3986 + * to encode using RFC3986, or PHP_QUERY_RFC1738 + * to encode using RFC1738. + * @return string + */ +function build_query(array $params, $encoding = \PHP_QUERY_RFC3986) +{ + if (!$params) { + return ''; + } + if ($encoding === \false) { + $encoder = function ($str) { + return $str; + }; + } elseif ($encoding === \PHP_QUERY_RFC3986) { + $encoder = 'rawurlencode'; + } elseif ($encoding === \PHP_QUERY_RFC1738) { + $encoder = 'urlencode'; + } else { + throw new \InvalidArgumentException('Invalid type'); + } + $qs = ''; + foreach ($params as $k => $v) { + $k = $encoder($k); + if (!\is_array($v)) { + $qs .= $k; + if ($v !== null) { + $qs .= '=' . $encoder($v); + } + $qs .= '&'; + } else { + foreach ($v as $vv) { + $qs .= $k; + if ($vv !== null) { + $qs .= '=' . $encoder($vv); + } + $qs .= '&'; + } + } + } + return $qs ? (string) \substr($qs, 0, -1) : ''; +} +/** + * Determines the mimetype of a file by looking at its extension. + * + * @param $filename + * + * @return null|string + */ +function mimetype_from_filename($filename) +{ + return mimetype_from_extension(\pathinfo($filename, \PATHINFO_EXTENSION)); +} +/** + * Maps a file extensions to a mimetype. + * + * @param $extension string The file extension. + * + * @return string|null + * @link http://svn.apache.org/repos/asf/httpd/httpd/branches/1.3.x/conf/mime.types + */ +function mimetype_from_extension($extension) +{ + static $mimetypes = ['3gp' => 'video/3gpp', '7z' => 'application/x-7z-compressed', 'aac' => 'audio/x-aac', 'ai' => 'application/postscript', 'aif' => 'audio/x-aiff', 'asc' => 'text/plain', 'asf' => 'video/x-ms-asf', 'atom' => 'application/atom+xml', 'avi' => 'video/x-msvideo', 'bmp' => 'image/bmp', 'bz2' => 'application/x-bzip2', 'cer' => 'application/pkix-cert', 'crl' => 'application/pkix-crl', 'crt' => 'application/x-x509-ca-cert', 'css' => 'text/css', 'csv' => 'text/csv', 'cu' => 'application/cu-seeme', 'deb' => 'application/x-debian-package', 'doc' => 'application/msword', 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'dvi' => 'application/x-dvi', 'eot' => 'application/vnd.ms-fontobject', 'eps' => 'application/postscript', 'epub' => 'application/epub+zip', 'etx' => 'text/x-setext', 'flac' => 'audio/flac', 'flv' => 'video/x-flv', 'gif' => 'image/gif', 'gz' => 'application/gzip', 'htm' => 'text/html', 'html' => 'text/html', 'ico' => 'image/x-icon', 'ics' => 'text/calendar', 'ini' => 'text/plain', 'iso' => 'application/x-iso9660-image', 'jar' => 'application/java-archive', 'jpe' => 'image/jpeg', 'jpeg' => 'image/jpeg', 'jpg' => 'image/jpeg', 'js' => 'text/javascript', 'json' => 'application/json', 'latex' => 'application/x-latex', 'log' => 'text/plain', 'm4a' => 'audio/mp4', 'm4v' => 'video/mp4', 'mid' => 'audio/midi', 'midi' => 'audio/midi', 'mov' => 'video/quicktime', 'mkv' => 'video/x-matroska', 'mp3' => 'audio/mpeg', 'mp4' => 'video/mp4', 'mp4a' => 'audio/mp4', 'mp4v' => 'video/mp4', 'mpe' => 'video/mpeg', 'mpeg' => 'video/mpeg', 'mpg' => 'video/mpeg', 'mpg4' => 'video/mp4', 'oga' => 'audio/ogg', 'ogg' => 'audio/ogg', 'ogv' => 'video/ogg', 'ogx' => 'application/ogg', 'pbm' => 'image/x-portable-bitmap', 'pdf' => 'application/pdf', 'pgm' => 'image/x-portable-graymap', 'png' => 'image/png', 'pnm' => 'image/x-portable-anymap', 'ppm' => 'image/x-portable-pixmap', 'ppt' => 'application/vnd.ms-powerpoint', 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation', 'ps' => 'application/postscript', 'qt' => 'video/quicktime', 'rar' => 'application/x-rar-compressed', 'ras' => 'image/x-cmu-raster', 'rss' => 'application/rss+xml', 'rtf' => 'application/rtf', 'sgm' => 'text/sgml', 'sgml' => 'text/sgml', 'svg' => 'image/svg+xml', 'swf' => 'application/x-shockwave-flash', 'tar' => 'application/x-tar', 'tif' => 'image/tiff', 'tiff' => 'image/tiff', 'torrent' => 'application/x-bittorrent', 'ttf' => 'application/x-font-ttf', 'txt' => 'text/plain', 'wav' => 'audio/x-wav', 'webm' => 'video/webm', 'webp' => 'image/webp', 'wma' => 'audio/x-ms-wma', 'wmv' => 'video/x-ms-wmv', 'woff' => 'application/x-font-woff', 'wsdl' => 'application/wsdl+xml', 'xbm' => 'image/x-xbitmap', 'xls' => 'application/vnd.ms-excel', 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'xml' => 'application/xml', 'xpm' => 'image/x-xpixmap', 'xwd' => 'image/x-xwindowdump', 'yaml' => 'text/yaml', 'yml' => 'text/yaml', 'zip' => 'application/zip']; + $extension = \strtolower($extension); + return isset($mimetypes[$extension]) ? $mimetypes[$extension] : null; +} +/** + * Parses an HTTP message into an associative array. + * + * The array contains the "start-line" key containing the start line of + * the message, "headers" key containing an associative array of header + * array values, and a "body" key containing the body of the message. + * + * @param string $message HTTP request or response to parse. + * + * @return array + * @internal + */ +function _parse_message($message) +{ + if (!$message) { + throw new \InvalidArgumentException('Invalid message'); + } + $message = \ltrim($message, "\r\n"); + $messageParts = \preg_split("/\r?\n\r?\n/", $message, 2); + if ($messageParts === \false || \count($messageParts) !== 2) { + throw new \InvalidArgumentException('Invalid message: Missing header delimiter'); + } + list($rawHeaders, $body) = $messageParts; + $rawHeaders .= "\r\n"; + // Put back the delimiter we split previously + $headerParts = \preg_split("/\r?\n/", $rawHeaders, 2); + if ($headerParts === \false || \count($headerParts) !== 2) { + throw new \InvalidArgumentException('Invalid message: Missing status line'); + } + list($startLine, $rawHeaders) = $headerParts; + if (\preg_match("/(?:^HTTP\\/|^[A-Z]+ \\S+ HTTP\\/)(\\d+(?:\\.\\d+)?)/i", $startLine, $matches) && $matches[1] === '1.0') { + // Header folding is deprecated for HTTP/1.1, but allowed in HTTP/1.0 + $rawHeaders = \preg_replace(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Rfc7230::HEADER_FOLD_REGEX, ' ', $rawHeaders); + } + /** @var array[] $headerLines */ + $count = \preg_match_all(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Rfc7230::HEADER_REGEX, $rawHeaders, $headerLines, \PREG_SET_ORDER); + // If these aren't the same, then one line didn't match and there's an invalid header. + if ($count !== \substr_count($rawHeaders, "\n")) { + // Folding is deprecated, see https://tools.ietf.org/html/rfc7230#section-3.2.4 + if (\preg_match(\_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Rfc7230::HEADER_FOLD_REGEX, $rawHeaders)) { + throw new \InvalidArgumentException('Invalid header syntax: Obsolete line folding'); + } + throw new \InvalidArgumentException('Invalid header syntax'); + } + $headers = []; + foreach ($headerLines as $headerLine) { + $headers[$headerLine[1]][] = $headerLine[2]; + } + return ['start-line' => $startLine, 'headers' => $headers, 'body' => $body]; +} +/** + * Constructs a URI for an HTTP request message. + * + * @param string $path Path from the start-line + * @param array $headers Array of headers (each value an array). + * + * @return string + * @internal + */ +function _parse_request_uri($path, array $headers) +{ + $hostKey = \array_filter(\array_keys($headers), function ($k) { + return \strtolower($k) === 'host'; + }); + // If no host is found, then a full URI cannot be constructed. + if (!$hostKey) { + return $path; + } + $host = $headers[\reset($hostKey)][0]; + $scheme = \substr($host, -4) === ':443' ? 'https' : 'http'; + return $scheme . '://' . $host . '/' . \ltrim($path, '/'); +} +/** + * Get a short summary of the message body + * + * Will return `null` if the response is not printable. + * + * @param MessageInterface $message The message to get the body summary + * @param int $truncateAt The maximum allowed size of the summary + * + * @return null|string + */ +function get_message_body_summary(\_PhpScoper5ea00cc67502b\Psr\Http\Message\MessageInterface $message, $truncateAt = 120) +{ + $body = $message->getBody(); + if (!$body->isSeekable() || !$body->isReadable()) { + return null; + } + $size = $body->getSize(); + if ($size === 0) { + return null; + } + $summary = $body->read($truncateAt); + $body->rewind(); + if ($size > $truncateAt) { + $summary .= ' (truncated...)'; + } + // Matches any printable character, including unicode characters: + // letters, marks, numbers, punctuation, spacing, and separators. + if (\preg_match('/[^\\pL\\pM\\pN\\pP\\pS\\pZ\\n\\r\\t]/', $summary)) { + return null; + } + return $summary; +} +/** @internal */ +function _caseless_remove($keys, array $data) +{ + $result = []; + foreach ($keys as &$key) { + $key = \strtolower($key); + } + foreach ($data as $k => $v) { + if (!\in_array(\strtolower($k), $keys)) { + $result[$k] = $v; + } + } + return $result; +} diff --git a/vendor/guzzlehttp/psr7/src/functions_include.php b/vendor/guzzlehttp/psr7/src/functions_include.php index ee4493e37..dbb45e010 100644 --- a/vendor/guzzlehttp/psr7/src/functions_include.php +++ b/vendor/guzzlehttp/psr7/src/functions_include.php @@ -1,8 +1,8 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/index.php b/vendor/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/index.php +++ b/vendor/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/index.php b/vendor/mollie/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/index.php +++ b/vendor/mollie/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/LICENSE b/vendor/mollie/mollie-api-php/LICENSE index 12c9d8d14..a5af9d2e8 100644 --- a/vendor/mollie/mollie-api-php/LICENSE +++ b/vendor/mollie/mollie-api-php/LICENSE @@ -1,8 +1,8 @@ -Copyright (c) 2013-2016, Mollie B.V. -All rights reserved. - -Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - -Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. -Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +Copyright (c) 2013-2016, Mollie B.V. +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + +Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. +Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/mollie/mollie-api-php/README.md b/vendor/mollie/mollie-api-php/README.md index 805d9a4de..dd44f0dd2 100644 --- a/vendor/mollie/mollie-api-php/README.md +++ b/vendor/mollie/mollie-api-php/README.md @@ -1,200 +1,200 @@ -

- -

-

Mollie API client for PHP

- - - -Accepting [iDEAL](https://www.mollie.com/payments/ideal/), [Apple Pay](https://www.mollie.com/payments/apple-pay), [Bancontact](https://www.mollie.com/payments/bancontact/), [SOFORT Banking](https://www.mollie.com/payments/sofort/), [Creditcard](https://www.mollie.com/payments/credit-card/), [SEPA Bank transfer](https://www.mollie.com/payments/bank-transfer/), [SEPA Direct debit](https://www.mollie.com/payments/direct-debit/), [PayPal](https://www.mollie.com/payments/paypal/), [Belfius Direct Net](https://www.mollie.com/payments/belfius/), [KBC/CBC](https://www.mollie.com/payments/kbc-cbc/), [paysafecard](https://www.mollie.com/payments/paysafecard/), [ING Home'Pay](https://www.mollie.com/payments/ing-homepay/), [Giftcards](https://www.mollie.com/payments/gift-cards/), [Giropay](https://www.mollie.com/payments/giropay/), [EPS](https://www.mollie.com/payments/eps/) and [Przelewy24](https://www.mollie.com/payments/przelewy24/) online payments without fixed monthly costs or any punishing registration procedures. Just use the Mollie API to receive payments directly on your website or easily refund transactions to your customers. - -[![Build Status](https://travis-ci.org/mollie/mollie-api-php.png)](https://travis-ci.org/mollie/mollie-api-php) -[![Latest Stable Version](https://poser.pugx.org/mollie/mollie-api-php/v/stable)](https://packagist.org/packages/mollie/mollie-api-php) -[![Total Downloads](https://poser.pugx.org/mollie/mollie-api-php/downloads)](https://packagist.org/packages/mollie/mollie-api-php) - -## Requirements ## -To use the Mollie API client, the following things are required: - -+ Get yourself a free [Mollie account](https://www.mollie.com/signup). No sign up costs. -+ Now you're ready to use the Mollie API client in test mode. -+ Follow [a few steps](https://www.mollie.com/dashboard/?modal=onboarding) to enable payment methods in live mode, and let us handle the rest. -+ PHP >= 5.6 -+ Up-to-date OpenSSL (or other SSL/TLS toolkit) - -For leveraging [Mollie Connect](https://docs.mollie.com/oauth/overview) (advanced use cases only), we recommend also installing our [OAuth2 client](https://github.com/mollie/oauth2-mollie-php). - -## Composer Installation ## - -By far the easiest way to install the Mollie API client is to require it with [Composer](http://getcomposer.org/doc/00-intro.md). - - $ composer require mollie/mollie-api-php:^2.0 - - { - "require": { - "mollie/mollie-api-php": "^2.0" - } - } - -The version of the API client corresponds to the version of the API it implements. Check the [notes on migration](https://docs.mollie.com/migrating-v1-to-v2) to see what changes you need to make if you want to start using a newer API version. - - -## Manual Installation ## -If you're not familiar with using composer we've added a ZIP file to the releases containing the API client and all the packages normally installed by composer. -Download the ``mollie-api-php.zip`` from the [releases page](https://github.com/mollie/mollie-api-php/releases). - -Include the ``vendor/autoload.php`` as shown in [Initialize example](https://github.com/mollie/mollie-api-php/blob/master/examples/initialize.php). - -## How to receive payments ## - -To successfully receive a payment, these steps should be implemented: - -1. Use the Mollie API client to create a payment with the requested amount, currency, description and optionally, a payment method. It is important to specify a unique redirect URL where the customer is supposed to return to after the payment is completed. - -2. Immediately after the payment is completed, our platform will send an asynchronous request to the configured webhook to allow the payment details to be retrieved, so you know when exactly to start processing the customer's order. - -3. The customer returns, and should be satisfied to see that the order was paid and is now being processed. - -Find our full documentation online on [docs.mollie.com](https://docs.mollie.com). - -## Getting started ## - -Initializing the Mollie API client, and setting your API key. - -```php -$mollie = new \Mollie\Api\MollieApiClient(); -$mollie->setApiKey("test_dHar4XY7LxsDOtmnkVtjNVWXLSlXsM"); -``` - -Creating a new payment. - -```php -$payment = $mollie->payments->create([ - "amount" => [ - "currency" => "EUR", - "value" => "10.00" - ], - "description" => "My first API payment", - "redirectUrl" => "https://webshop.example.org/order/12345/", - "webhookUrl" => "https://webshop.example.org/mollie-webhook/", -]); -``` -_After creation, the payment id is available in the `$payment->id` property. You should store this id with your order._ - -After storing the payment id you can send the customer to the checkout using the `$payment->getCheckoutUrl()`. - -```php -header("Location: " . $payment->getCheckoutUrl(), true, 303); -``` -_This header location should always be a GET, thus we enforce 303 http response code_ - -For a payment create example, see [Example - New Payment](https://github.com/mollie/mollie-api-php/blob/master/examples/payments/create-payment.php). - -## Retrieving payments ## -We can use the `$payment->id` to retrieve a payment and check if the payment `isPaid`. - -```php -$payment = $mollie->payments->get($payment->id); - -if ($payment->isPaid()) -{ - echo "Payment received."; -} -``` - -Or retrieve a collection of payments. - -```php -$payments = $mollie->payments->page(); -``` - -For an extensive example of listing payments with the details and status, see [Example - List Payments](https://github.com/mollie/mollie-api-php/blob/master/examples/payments/list-payments.php). - -## Payment webhook ## - -When the status of a payment changes the `webhookUrl` we specified in the creation of the payment will be called. -There we can use the `id` from our POST parameters to check te status and act upon that, see [Example - Webhook](https://github.com/mollie/mollie-api-php/blob/master/examples/payments/webhook.php). - - -## Multicurrency ## -Since 2.0 it is now possible to create non-EUR payments for your customers. -A full list of available currencies can be found [in our documentation](https://docs.mollie.com/guides/multicurrency). - -```php -$payment = $mollie->payments->create([ - "amount" => [ - "currency" => "USD", - "value" => "10.00" - ], - "description" => "Order #12345", - "redirectUrl" => "https://webshop.example.org/order/12345/", - "webhookUrl" => "https://webshop.example.org/mollie-webhook/", -]); -``` -_After creation, the `settlementAmount` will contain the EUR amount that will be settled on your account._ - - -### Fully integrated iDEAL payments ### - -If you want to fully integrate iDEAL payments in your web site, some additional steps are required. First, you need to -retrieve the list of issuers (banks) that support iDEAL and have your customer pick the issuer he/she wants to use for -the payment. - -Retrieve the iDEAL method and include the issuers - -```php -$method = $mollie->methods->get(\Mollie\Api\Types\PaymentMethod::IDEAL, ["include" => "issuers"]); -``` - -_`$method->issuers` will be a list of objects. Use the property `$id` of this object in the - API call, and the property `$name` for displaying the issuer to your customer. For a more in-depth example, see [Example - iDEAL payment](https://github.com/mollie/mollie-api-php/blob/master/examples/payments/create-ideal-payment.php)._ - -Create a payment with the selected issuer: - -```php -$payment = $mollie->payments->create([ - "amount" => [ - "currency" => "EUR", - "value" => "10.00" - ], - "description" => "My first API payment", - "redirectUrl" => "https://webshop.example.org/order/12345/", - "webhookUrl" => "https://webshop.example.org/mollie-webhook/", - "method" => \Mollie\Api\Types\PaymentMethod::IDEAL, - "issuer" => $selectedIssuerId, // e.g. "ideal_INGBNL2A" -]); -``` - -_The `_links` property of the `$payment` object will contain an object `checkout` with a `href` property, which is a URL that points directly to the online banking environment of the selected issuer. -A short way of retrieving this URL can be achieved by using the `$payment->getCheckoutUrl()`._ - -### Refunding payments ### - -The API also supports refunding payments. Note that there is no confirmation and that all refunds are immediate and -definitive. refunds are supported for all methods except for paysafecard and gift cards. - -```php -$payment = $mollie->payments->get($payment->id); - -// Refund € 2 of this payment -$refund = $payment->refund([ - "amount" => [ - "currency" => "EUR", - "value" => "2.00" - ] -]); -``` - -For a working example, see [Example - Refund payment](https://github.com/mollie/mollie-api-php/blob/master/examples/payments/refund-payment.php). - -## API documentation ## -If you wish to learn more about our API, please visit the [Mollie Developer Portal](https://www.mollie.com/developers). API Documentation is available in English. - -## Want to help us make our API client even better? ## - -Want to help us make our API client even better? We take [pull requests](https://github.com/mollie/mollie-api-php/pulls?utf8=%E2%9C%93&q=is%3Apr), sure. But how would you like to contribute to a technology oriented organization? Mollie is hiring developers and system engineers. [Check out our vacancies](https://jobs.mollie.com/) or [get in touch](mailto:personeel@mollie.com). - -## License ## -[BSD (Berkeley Software Distribution) License](https://opensource.org/licenses/bsd-license.php). -Copyright (c) 2013-2018, Mollie B.V. - -## Support ## -Contact: [www.mollie.com](https://www.mollie.com) — info@mollie.com — +31 20 820 20 70 +

+ +

+

Mollie API client for PHP

+ + + +Accepting [iDEAL](https://www.mollie.com/payments/ideal/), [Apple Pay](https://www.mollie.com/payments/apple-pay), [Bancontact](https://www.mollie.com/payments/bancontact/), [SOFORT Banking](https://www.mollie.com/payments/sofort/), [Creditcard](https://www.mollie.com/payments/credit-card/), [SEPA Bank transfer](https://www.mollie.com/payments/bank-transfer/), [SEPA Direct debit](https://www.mollie.com/payments/direct-debit/), [PayPal](https://www.mollie.com/payments/paypal/), [Belfius Direct Net](https://www.mollie.com/payments/belfius/), [KBC/CBC](https://www.mollie.com/payments/kbc-cbc/), [paysafecard](https://www.mollie.com/payments/paysafecard/), [ING Home'Pay](https://www.mollie.com/payments/ing-homepay/), [Giftcards](https://www.mollie.com/payments/gift-cards/), [Giropay](https://www.mollie.com/payments/giropay/), [EPS](https://www.mollie.com/payments/eps/) and [Przelewy24](https://www.mollie.com/payments/przelewy24/) online payments without fixed monthly costs or any punishing registration procedures. Just use the Mollie API to receive payments directly on your website or easily refund transactions to your customers. + +[![Build Status](https://travis-ci.org/mollie/mollie-api-php.png)](https://travis-ci.org/mollie/mollie-api-php) +[![Latest Stable Version](https://poser.pugx.org/mollie/mollie-api-php/v/stable)](https://packagist.org/packages/mollie/mollie-api-php) +[![Total Downloads](https://poser.pugx.org/mollie/mollie-api-php/downloads)](https://packagist.org/packages/mollie/mollie-api-php) + +## Requirements ## +To use the Mollie API client, the following things are required: + ++ Get yourself a free [Mollie account](https://www.mollie.com/signup). No sign up costs. ++ Now you're ready to use the Mollie API client in test mode. ++ Follow [a few steps](https://www.mollie.com/dashboard/?modal=onboarding) to enable payment methods in live mode, and let us handle the rest. ++ PHP >= 5.6 ++ Up-to-date OpenSSL (or other SSL/TLS toolkit) + +For leveraging [Mollie Connect](https://docs.mollie.com/oauth/overview) (advanced use cases only), we recommend also installing our [OAuth2 client](https://github.com/mollie/oauth2-mollie-php). + +## Composer Installation ## + +By far the easiest way to install the Mollie API client is to require it with [Composer](http://getcomposer.org/doc/00-intro.md). + + $ composer require mollie/mollie-api-php:^2.0 + + { + "require": { + "mollie/mollie-api-php": "^2.0" + } + } + +The version of the API client corresponds to the version of the API it implements. Check the [notes on migration](https://docs.mollie.com/migrating-v1-to-v2) to see what changes you need to make if you want to start using a newer API version. + + +## Manual Installation ## +If you're not familiar with using composer we've added a ZIP file to the releases containing the API client and all the packages normally installed by composer. +Download the ``mollie-api-php.zip`` from the [releases page](https://github.com/mollie/mollie-api-php/releases). + +Include the ``vendor/autoload.php`` as shown in [Initialize example](https://github.com/mollie/mollie-api-php/blob/master/examples/initialize.php). + +## How to receive payments ## + +To successfully receive a payment, these steps should be implemented: + +1. Use the Mollie API client to create a payment with the requested amount, currency, description and optionally, a payment method. It is important to specify a unique redirect URL where the customer is supposed to return to after the payment is completed. + +2. Immediately after the payment is completed, our platform will send an asynchronous request to the configured webhook to allow the payment details to be retrieved, so you know when exactly to start processing the customer's order. + +3. The customer returns, and should be satisfied to see that the order was paid and is now being processed. + +Find our full documentation online on [docs.mollie.com](https://docs.mollie.com). + +## Getting started ## + +Initializing the Mollie API client, and setting your API key. + +```php +$mollie = new \Mollie\Api\MollieApiClient(); +$mollie->setApiKey("test_dHar4XY7LxsDOtmnkVtjNVWXLSlXsM"); +``` + +Creating a new payment. + +```php +$payment = $mollie->payments->create([ + "amount" => [ + "currency" => "EUR", + "value" => "10.00" + ], + "description" => "My first API payment", + "redirectUrl" => "https://webshop.example.org/order/12345/", + "webhookUrl" => "https://webshop.example.org/mollie-webhook/", +]); +``` +_After creation, the payment id is available in the `$payment->id` property. You should store this id with your order._ + +After storing the payment id you can send the customer to the checkout using the `$payment->getCheckoutUrl()`. + +```php +header("Location: " . $payment->getCheckoutUrl(), true, 303); +``` +_This header location should always be a GET, thus we enforce 303 http response code_ + +For a payment create example, see [Example - New Payment](https://github.com/mollie/mollie-api-php/blob/master/examples/payments/create-payment.php). + +## Retrieving payments ## +We can use the `$payment->id` to retrieve a payment and check if the payment `isPaid`. + +```php +$payment = $mollie->payments->get($payment->id); + +if ($payment->isPaid()) +{ + echo "Payment received."; +} +``` + +Or retrieve a collection of payments. + +```php +$payments = $mollie->payments->page(); +``` + +For an extensive example of listing payments with the details and status, see [Example - List Payments](https://github.com/mollie/mollie-api-php/blob/master/examples/payments/list-payments.php). + +## Payment webhook ## + +When the status of a payment changes the `webhookUrl` we specified in the creation of the payment will be called. +There we can use the `id` from our POST parameters to check te status and act upon that, see [Example - Webhook](https://github.com/mollie/mollie-api-php/blob/master/examples/payments/webhook.php). + + +## Multicurrency ## +Since 2.0 it is now possible to create non-EUR payments for your customers. +A full list of available currencies can be found [in our documentation](https://docs.mollie.com/guides/multicurrency). + +```php +$payment = $mollie->payments->create([ + "amount" => [ + "currency" => "USD", + "value" => "10.00" + ], + "description" => "Order #12345", + "redirectUrl" => "https://webshop.example.org/order/12345/", + "webhookUrl" => "https://webshop.example.org/mollie-webhook/", +]); +``` +_After creation, the `settlementAmount` will contain the EUR amount that will be settled on your account._ + + +### Fully integrated iDEAL payments ### + +If you want to fully integrate iDEAL payments in your web site, some additional steps are required. First, you need to +retrieve the list of issuers (banks) that support iDEAL and have your customer pick the issuer he/she wants to use for +the payment. + +Retrieve the iDEAL method and include the issuers + +```php +$method = $mollie->methods->get(\Mollie\Api\Types\PaymentMethod::IDEAL, ["include" => "issuers"]); +``` + +_`$method->issuers` will be a list of objects. Use the property `$id` of this object in the + API call, and the property `$name` for displaying the issuer to your customer. For a more in-depth example, see [Example - iDEAL payment](https://github.com/mollie/mollie-api-php/blob/master/examples/payments/create-ideal-payment.php)._ + +Create a payment with the selected issuer: + +```php +$payment = $mollie->payments->create([ + "amount" => [ + "currency" => "EUR", + "value" => "10.00" + ], + "description" => "My first API payment", + "redirectUrl" => "https://webshop.example.org/order/12345/", + "webhookUrl" => "https://webshop.example.org/mollie-webhook/", + "method" => \Mollie\Api\Types\PaymentMethod::IDEAL, + "issuer" => $selectedIssuerId, // e.g. "ideal_INGBNL2A" +]); +``` + +_The `_links` property of the `$payment` object will contain an object `checkout` with a `href` property, which is a URL that points directly to the online banking environment of the selected issuer. +A short way of retrieving this URL can be achieved by using the `$payment->getCheckoutUrl()`._ + +### Refunding payments ### + +The API also supports refunding payments. Note that there is no confirmation and that all refunds are immediate and +definitive. refunds are supported for all methods except for paysafecard and gift cards. + +```php +$payment = $mollie->payments->get($payment->id); + +// Refund € 2 of this payment +$refund = $payment->refund([ + "amount" => [ + "currency" => "EUR", + "value" => "2.00" + ] +]); +``` + +For a working example, see [Example - Refund payment](https://github.com/mollie/mollie-api-php/blob/master/examples/payments/refund-payment.php). + +## API documentation ## +If you wish to learn more about our API, please visit the [Mollie Developer Portal](https://www.mollie.com/developers). API Documentation is available in English. + +## Want to help us make our API client even better? ## + +Want to help us make our API client even better? We take [pull requests](https://github.com/mollie/mollie-api-php/pulls?utf8=%E2%9C%93&q=is%3Apr), sure. But how would you like to contribute to a technology oriented organization? Mollie is hiring developers and system engineers. [Check out our vacancies](https://jobs.mollie.com/) or [get in touch](mailto:personeel@mollie.com). + +## License ## +[BSD (Berkeley Software Distribution) License](https://opensource.org/licenses/bsd-license.php). +Copyright (c) 2013-2018, Mollie B.V. + +## Support ## +Contact: [www.mollie.com](https://www.mollie.com) — info@mollie.com — +31 20 820 20 70 diff --git a/vendor/mollie/mollie-api-php/composer.json b/vendor/mollie/mollie-api-php/composer.json index 086ad4600..d0bfb96aa 100644 --- a/vendor/mollie/mollie-api-php/composer.json +++ b/vendor/mollie/mollie-api-php/composer.json @@ -1,81 +1,81 @@ -{ - "name": "mollie\/mollie-api-php", - "description": "Mollie API client library for PHP. Mollie is a European Payment Service provider and offers international payment methods such as Mastercard, VISA, American Express and PayPal, and local payment methods such as iDEAL, Bancontact, SOFORT Banking, SEPA direct debit, Belfius Direct Net, KBC Payment Button and various gift cards such as Podiumcadeaukaart and fashioncheque.", - "keywords": [ - "mollie", - "payment", - "service", - "ideal", - "creditcard", - "apple pay", - "mistercash", - "bancontact", - "sofort", - "sofortbanking", - "sepa", - "paypal", - "paysafecard", - "podiumcadeaukaart", - "przelewy24", - "banktransfer", - "direct debit", - "belfius", - "belfius direct net", - "refunds", - "api", - "payments", - "gateway", - "subscriptions", - "recurring", - "charges", - "kbc", - "cbc", - "gift cards", - "intersolve", - "fashioncheque", - "inghomepay", - "klarna", - "paylater", - "sliceit" - ], - "homepage": "https:\/\/www.mollie.com\/en\/developers", - "license": "BSD-2-Clause", - "authors": [ - { - "name": "Mollie B.V.", - "email": "info@mollie.com" - } - ], - "require": { - "php": ">=5.6", - "ext-curl": "*", - "ext-json": "*", - "ext-openssl": "*", - "composer\/ca-bundle": "^1.1", - "guzzlehttp\/guzzle": "^6.3" - }, - "require-dev": { - "eloquent\/liberator": "^2.0", - "phpunit\/phpunit": "^5.7 || ^6.5 || ^7.1" - }, - "suggest": { - "mollie\/oauth2-mollie-php": "Use OAuth to authenticate with the Mollie API. This is needed for some endpoints. Visit https:\/\/docs.mollie.com\/ for more information." - }, - "config": { - "sort-packages": true - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Mollie\\Api\\": "src\/" - } - }, - "autoload-dev": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Tests\\": "tests\/", - "_PhpScoper5ea00cc67502b\\Tests\\Mollie\\Api\\": "tests\/Mollie\/API\/" - } - }, - "scripts": { - "test": ".\/vendor\/bin\/phpunit tests" - } +{ + "name": "mollie\/mollie-api-php", + "description": "Mollie API client library for PHP. Mollie is a European Payment Service provider and offers international payment methods such as Mastercard, VISA, American Express and PayPal, and local payment methods such as iDEAL, Bancontact, SOFORT Banking, SEPA direct debit, Belfius Direct Net, KBC Payment Button and various gift cards such as Podiumcadeaukaart and fashioncheque.", + "keywords": [ + "mollie", + "payment", + "service", + "ideal", + "creditcard", + "apple pay", + "mistercash", + "bancontact", + "sofort", + "sofortbanking", + "sepa", + "paypal", + "paysafecard", + "podiumcadeaukaart", + "przelewy24", + "banktransfer", + "direct debit", + "belfius", + "belfius direct net", + "refunds", + "api", + "payments", + "gateway", + "subscriptions", + "recurring", + "charges", + "kbc", + "cbc", + "gift cards", + "intersolve", + "fashioncheque", + "inghomepay", + "klarna", + "paylater", + "sliceit" + ], + "homepage": "https:\/\/www.mollie.com\/en\/developers", + "license": "BSD-2-Clause", + "authors": [ + { + "name": "Mollie B.V.", + "email": "info@mollie.com" + } + ], + "require": { + "php": ">=5.6", + "ext-curl": "*", + "ext-json": "*", + "ext-openssl": "*", + "composer\/ca-bundle": "^1.1", + "guzzlehttp\/guzzle": "^6.3" + }, + "require-dev": { + "eloquent\/liberator": "^2.0", + "phpunit\/phpunit": "^5.7 || ^6.5 || ^7.1" + }, + "suggest": { + "mollie\/oauth2-mollie-php": "Use OAuth to authenticate with the Mollie API. This is needed for some endpoints. Visit https:\/\/docs.mollie.com\/ for more information." + }, + "config": { + "sort-packages": true + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Mollie\\Api\\": "src\/" + } + }, + "autoload-dev": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Tests\\": "tests\/", + "_PhpScoper5ea00cc67502b\\Tests\\Mollie\\Api\\": "tests\/Mollie\/API\/" + } + }, + "scripts": { + "test": ".\/vendor\/bin\/phpunit tests" + } } \ No newline at end of file diff --git a/vendor/mollie/mollie-api-php/examples/captures/get-capture.php b/vendor/mollie/mollie-api-php/examples/captures/get-capture.php index 191a02cf5..c41e425fc 100644 --- a/vendor/mollie/mollie-api-php/examples/captures/get-capture.php +++ b/vendor/mollie/mollie-api-php/examples/captures/get-capture.php @@ -1,25 +1,25 @@ -payments->get('tr_WDqYK6vllg'); - $capture = $payment->getCapture('cpt_4qqhO89gsT'); - $amount = $capture->amount->currency . ' ' . $capture->amount->value; - echo 'Captured ' . $amount; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +payments->get('tr_WDqYK6vllg'); + $capture = $payment->getCapture('cpt_4qqhO89gsT'); + $amount = $capture->amount->currency . ' ' . $capture->amount->value; + echo 'Captured ' . $amount; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/captures/index.php b/vendor/mollie/mollie-api-php/examples/captures/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/examples/captures/index.php +++ b/vendor/mollie/mollie-api-php/examples/captures/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/captures/list-captures.php b/vendor/mollie/mollie-api-php/examples/captures/list-captures.php index b96b582e8..785818513 100644 --- a/vendor/mollie/mollie-api-php/examples/captures/list-captures.php +++ b/vendor/mollie/mollie-api-php/examples/captures/list-captures.php @@ -1,26 +1,26 @@ -payments->get('tr_WDqYK6vllg'); - $captures = $payment->captures(); - foreach ($captures as $capture) { - $amount = $capture->amount->currency . ' ' . $capture->amount->value; - echo 'Captured ' . $amount . ' for payment ' . $payment->id; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +payments->get('tr_WDqYK6vllg'); + $captures = $payment->captures(); + foreach ($captures as $capture) { + $amount = $capture->amount->currency . ' ' . $capture->amount->value; + echo 'Captured ' . $amount . ' for payment ' . $payment->id; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/customers/create-customer-first-payment.php b/vendor/mollie/mollie-api-php/examples/customers/create-customer-first-payment.php index 924f1f592..1cc81470d 100644 --- a/vendor/mollie/mollie-api-php/examples/customers/create-customer-first-payment.php +++ b/vendor/mollie/mollie-api-php/examples/customers/create-customer-first-payment.php @@ -1,61 +1,61 @@ -customers->page(null, 1)[0]; - /* - * Generate a unique order id for this example. It is important to include this unique attribute - * in the redirectUrl (below) so a proper return page can be shown to the customer. - */ - $orderId = \time(); - /* - * Determine the url parts to these example files. - */ - $protocol = isset($_SERVER['HTTPS']) && \strcasecmp('off', $_SERVER['HTTPS']) !== 0 ? "https" : "http"; - $hostname = $_SERVER['HTTP_HOST']; - $path = \dirname(isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : $_SERVER['PHP_SELF']); - /** - * Customer Payment creation parameters. - * - * @See: https://docs.mollie.com/reference/v2/customers-api/create-customer-payment - */ - $payment = $customer->createPayment([ - "amount" => [ - "value" => "10.00", - // You must send the correct number of decimals, thus we enforce the use of strings - "currency" => "EUR", - ], - "description" => "First payment - Order #{$orderId}", - "redirectUrl" => "{$protocol}://{$hostname}{$path}/payments/return.php?order_id={$orderId}", - "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", - "metadata" => ["order_id" => $orderId], - // Flag this payment as a first payment to allow recurring payments later. - "sequenceType" => \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SequenceType::SEQUENCETYPE_FIRST, - ]); - /* - * In this example we store the order with its payment status in a database. - */ - \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); - /* - * Send the customer off to complete the payment. - * This request should always be a GET, thus we enforce 303 http response code - * - * After completion, the customer will have a pending or valid mandate that can be - * used for recurring payments and subscriptions. - */ - \header("Location: " . $payment->getCheckoutUrl(), \true, 303); -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->page(null, 1)[0]; + /* + * Generate a unique order id for this example. It is important to include this unique attribute + * in the redirectUrl (below) so a proper return page can be shown to the customer. + */ + $orderId = \time(); + /* + * Determine the url parts to these example files. + */ + $protocol = isset($_SERVER['HTTPS']) && \strcasecmp('off', $_SERVER['HTTPS']) !== 0 ? "https" : "http"; + $hostname = $_SERVER['HTTP_HOST']; + $path = \dirname(isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : $_SERVER['PHP_SELF']); + /** + * Customer Payment creation parameters. + * + * @See: https://docs.mollie.com/reference/v2/customers-api/create-customer-payment + */ + $payment = $customer->createPayment([ + "amount" => [ + "value" => "10.00", + // You must send the correct number of decimals, thus we enforce the use of strings + "currency" => "EUR", + ], + "description" => "First payment - Order #{$orderId}", + "redirectUrl" => "{$protocol}://{$hostname}{$path}/payments/return.php?order_id={$orderId}", + "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", + "metadata" => ["order_id" => $orderId], + // Flag this payment as a first payment to allow recurring payments later. + "sequenceType" => \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SequenceType::SEQUENCETYPE_FIRST, + ]); + /* + * In this example we store the order with its payment status in a database. + */ + \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); + /* + * Send the customer off to complete the payment. + * This request should always be a GET, thus we enforce 303 http response code + * + * After completion, the customer will have a pending or valid mandate that can be + * used for recurring payments and subscriptions. + */ + \header("Location: " . $payment->getCheckoutUrl(), \true, 303); +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/customers/create-customer-payment.php b/vendor/mollie/mollie-api-php/examples/customers/create-customer-payment.php index 2cb5a785e..329f8e298 100644 --- a/vendor/mollie/mollie-api-php/examples/customers/create-customer-payment.php +++ b/vendor/mollie/mollie-api-php/examples/customers/create-customer-payment.php @@ -1,50 +1,50 @@ -customers->page(null, 1)[0]; - /* - * Generate a unique order id for this example. It is important to include this unique attribute - * in the redirectUrl (below) so a proper return page can be shown to the customer. - */ - $orderId = \time(); - /* - * Determine the url parts to these example files. - */ - $protocol = isset($_SERVER['HTTPS']) && \strcasecmp('off', $_SERVER['HTTPS']) !== 0 ? "https" : "http"; - $hostname = $_SERVER['HTTP_HOST']; - $path = \dirname(isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : $_SERVER['PHP_SELF']); - /** - * Linking customers to payments has a few benefits - * - * @see https://docs.mollie.com/reference/v2/customers-api/create-customer-payment - */ - $payment = $customer->createPayment(["amount" => [ - "value" => "10.00", - // You must send the correct number of decimals, thus we enforce the use of strings - "currency" => "EUR", - ], "description" => "Order #{$orderId}", "redirectUrl" => "{$protocol}://{$hostname}{$path}/payments/return.php?order_id={$orderId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", "metadata" => ["order_id" => $orderId]]); - /* - * In this example we store the order with its payment status in a database. - */ - \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); - /* - * Send the customer off to complete the payment. - * This request should always be a GET, thus we enforce 303 http response code - */ - \header("Location: " . $payment->getCheckoutUrl(), \true, 303); -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->page(null, 1)[0]; + /* + * Generate a unique order id for this example. It is important to include this unique attribute + * in the redirectUrl (below) so a proper return page can be shown to the customer. + */ + $orderId = \time(); + /* + * Determine the url parts to these example files. + */ + $protocol = isset($_SERVER['HTTPS']) && \strcasecmp('off', $_SERVER['HTTPS']) !== 0 ? "https" : "http"; + $hostname = $_SERVER['HTTP_HOST']; + $path = \dirname(isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : $_SERVER['PHP_SELF']); + /** + * Linking customers to payments has a few benefits + * + * @see https://docs.mollie.com/reference/v2/customers-api/create-customer-payment + */ + $payment = $customer->createPayment(["amount" => [ + "value" => "10.00", + // You must send the correct number of decimals, thus we enforce the use of strings + "currency" => "EUR", + ], "description" => "Order #{$orderId}", "redirectUrl" => "{$protocol}://{$hostname}{$path}/payments/return.php?order_id={$orderId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", "metadata" => ["order_id" => $orderId]]); + /* + * In this example we store the order with its payment status in a database. + */ + \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); + /* + * Send the customer off to complete the payment. + * This request should always be a GET, thus we enforce 303 http response code + */ + \header("Location: " . $payment->getCheckoutUrl(), \true, 303); +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/customers/create-customer-recurring-payment.php b/vendor/mollie/mollie-api-php/examples/customers/create-customer-recurring-payment.php index 730186477..734d24a5d 100644 --- a/vendor/mollie/mollie-api-php/examples/customers/create-customer-recurring-payment.php +++ b/vendor/mollie/mollie-api-php/examples/customers/create-customer-recurring-payment.php @@ -1,57 +1,57 @@ -customers->page(null, 1)[0]; - /* - * Generate a unique order id for this example. - */ - $orderId = \time(); - /* - * Determine the url parts to these example files. - */ - $protocol = isset($_SERVER['HTTPS']) && \strcasecmp('off', $_SERVER['HTTPS']) !== 0 ? "https" : "http"; - $hostname = $_SERVER['HTTP_HOST']; - $path = \dirname(isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : $_SERVER['PHP_SELF']); - /** - * Customer Payment creation parameters. - * - * @See: https://docs.mollie.com/reference/v2/customers-api/create-customer-payment - */ - $payment = $customer->createPayment([ - "amount" => [ - "value" => "10.00", - // You must send the correct number of decimals, thus we enforce the use of strings - "currency" => "EUR", - ], - "description" => "On-demand payment - Order #{$orderId}", - "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", - "metadata" => ["order_id" => $orderId], - // Flag this payment as a recurring payment. - "sequenceType" => \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SequenceType::SEQUENCETYPE_RECURRING, - ]); - /* - * In this example we store the order with its payment status in a database. - */ - \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); - /* - * The payment will be either pending or paid immediately. The customer - * does not have to perform any payment steps. - */ - echo "

Selected mandate is '" . \htmlspecialchars($payment->mandateId) . "' (" . \htmlspecialchars($payment->method) . ").

\n"; - echo "

The payment status is '" . \htmlspecialchars($payment->status) . "'.

\n"; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->page(null, 1)[0]; + /* + * Generate a unique order id for this example. + */ + $orderId = \time(); + /* + * Determine the url parts to these example files. + */ + $protocol = isset($_SERVER['HTTPS']) && \strcasecmp('off', $_SERVER['HTTPS']) !== 0 ? "https" : "http"; + $hostname = $_SERVER['HTTP_HOST']; + $path = \dirname(isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : $_SERVER['PHP_SELF']); + /** + * Customer Payment creation parameters. + * + * @See: https://docs.mollie.com/reference/v2/customers-api/create-customer-payment + */ + $payment = $customer->createPayment([ + "amount" => [ + "value" => "10.00", + // You must send the correct number of decimals, thus we enforce the use of strings + "currency" => "EUR", + ], + "description" => "On-demand payment - Order #{$orderId}", + "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", + "metadata" => ["order_id" => $orderId], + // Flag this payment as a recurring payment. + "sequenceType" => \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SequenceType::SEQUENCETYPE_RECURRING, + ]); + /* + * In this example we store the order with its payment status in a database. + */ + \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); + /* + * The payment will be either pending or paid immediately. The customer + * does not have to perform any payment steps. + */ + echo "

Selected mandate is '" . \htmlspecialchars($payment->mandateId) . "' (" . \htmlspecialchars($payment->method) . ").

\n"; + echo "

The payment status is '" . \htmlspecialchars($payment->status) . "'.

\n"; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/customers/create-customer.php b/vendor/mollie/mollie-api-php/examples/customers/create-customer.php index 08c640f2d..47c36bba7 100644 --- a/vendor/mollie/mollie-api-php/examples/customers/create-customer.php +++ b/vendor/mollie/mollie-api-php/examples/customers/create-customer.php @@ -1,22 +1,22 @@ -customers->create(["name" => "Luke Skywalker", "email" => "luke@example.org", "metadata" => ["isJedi" => \TRUE]]); - echo "

New customer created " . \htmlspecialchars($customer->id) . " (" . \htmlspecialchars($customer->name) . ").

"; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->create(["name" => "Luke Skywalker", "email" => "luke@example.org", "metadata" => ["isJedi" => \TRUE]]); + echo "

New customer created " . \htmlspecialchars($customer->id) . " (" . \htmlspecialchars($customer->name) . ").

"; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/customers/delete-customer.php b/vendor/mollie/mollie-api-php/examples/customers/delete-customer.php index 77a6357a7..33612ae81 100644 --- a/vendor/mollie/mollie-api-php/examples/customers/delete-customer.php +++ b/vendor/mollie/mollie-api-php/examples/customers/delete-customer.php @@ -1,17 +1,17 @@ -customers->delete("cst_fE3F6nvX"); - echo "

Customer deleted!

"; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->delete("cst_fE3F6nvX"); + echo "

Customer deleted!

"; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/customers/index.php b/vendor/mollie/mollie-api-php/examples/customers/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/examples/customers/index.php +++ b/vendor/mollie/mollie-api-php/examples/customers/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/customers/list-customer-payments.php b/vendor/mollie/mollie-api-php/examples/customers/list-customer-payments.php index 71411ca3c..745608cc1 100644 --- a/vendor/mollie/mollie-api-php/examples/customers/list-customer-payments.php +++ b/vendor/mollie/mollie-api-php/examples/customers/list-customer-payments.php @@ -1,51 +1,51 @@ -customers->page(null, 1)[0]; - /* - * Get the all payments for this API key ordered by newest. - */ - $payments = $customer->payments(); - echo "
    "; - foreach ($payments as $payment) { - echo "
  • "; - echo "" . \htmlspecialchars($payment->id) . "
    "; - echo \htmlspecialchars($payment->description) . "
    "; - echo \htmlspecialchars($payment->amount->currency) . " " . \htmlspecialchars($payment->amount->value) . "
    "; - echo "Status: " . \htmlspecialchars($payment->status) . "
    "; - if ($payment->hasRefunds()) { - echo "Payment has been (partially) refunded.
    "; - } - if ($payment->hasChargebacks()) { - echo "Payment has been charged back.
    "; - } - if ($payment->canBeRefunded() && $payment->amountRemaining->currency === 'EUR' && $payment->amountRemaining->value >= '2.00') { - echo " (id) . "\">refund)"; - } - echo "
  • "; - } - echo "
"; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->page(null, 1)[0]; + /* + * Get the all payments for this API key ordered by newest. + */ + $payments = $customer->payments(); + echo "
    "; + foreach ($payments as $payment) { + echo "
  • "; + echo "" . \htmlspecialchars($payment->id) . "
    "; + echo \htmlspecialchars($payment->description) . "
    "; + echo \htmlspecialchars($payment->amount->currency) . " " . \htmlspecialchars($payment->amount->value) . "
    "; + echo "Status: " . \htmlspecialchars($payment->status) . "
    "; + if ($payment->hasRefunds()) { + echo "Payment has been (partially) refunded.
    "; + } + if ($payment->hasChargebacks()) { + echo "Payment has been charged back.
    "; + } + if ($payment->canBeRefunded() && $payment->amountRemaining->currency === 'EUR' && $payment->amountRemaining->value >= '2.00') { + echo " (id) . "\">refund)"; + } + echo "
  • "; + } + echo "
"; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/customers/update-customer.php b/vendor/mollie/mollie-api-php/examples/customers/update-customer.php index 0e9d0a100..7c2d89a89 100644 --- a/vendor/mollie/mollie-api-php/examples/customers/update-customer.php +++ b/vendor/mollie/mollie-api-php/examples/customers/update-customer.php @@ -1,30 +1,30 @@ -customers->get("cst_cUe8HjeBuz"); - /** - * Customer fields that can be updated. - * - * @See https://docs.mollie.com/reference/v2/customers-api/update-customer - */ - $customer->name = "Luke Sky"; - $customer->email = "luke@example.org"; - $customer->locale = "en_US"; - $customer->metadata->isJedi = \TRUE; - $customer->update(); - echo "

Customer updated: " . \htmlspecialchars($customer->name) . "

"; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->get("cst_cUe8HjeBuz"); + /** + * Customer fields that can be updated. + * + * @See https://docs.mollie.com/reference/v2/customers-api/update-customer + */ + $customer->name = "Luke Sky"; + $customer->email = "luke@example.org"; + $customer->locale = "en_US"; + $customer->metadata->isJedi = \TRUE; + $customer->update(); + echo "

Customer updated: " . \htmlspecialchars($customer->name) . "

"; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/functions.php b/vendor/mollie/mollie-api-php/examples/functions.php index b9cf85cb1..01ad6a5a4 100644 --- a/vendor/mollie/mollie-api-php/examples/functions.php +++ b/vendor/mollie/mollie-api-php/examples/functions.php @@ -1,21 +1,21 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/initialize.php b/vendor/mollie/mollie-api-php/examples/initialize.php index 6b1ec8589..f5a5eecb2 100644 --- a/vendor/mollie/mollie-api-php/examples/initialize.php +++ b/vendor/mollie/mollie-api-php/examples/initialize.php @@ -1,19 +1,19 @@ -setApiKey("test_dHar4XY7LxsDOtmnkVtjNVWXLSlXsM"); +setApiKey("test_dHar4XY7LxsDOtmnkVtjNVWXLSlXsM"); diff --git a/vendor/mollie/mollie-api-php/examples/initialize_with_oauth.php b/vendor/mollie/mollie-api-php/examples/initialize_with_oauth.php index da1fe6115..1b6faa40b 100644 --- a/vendor/mollie/mollie-api-php/examples/initialize_with_oauth.php +++ b/vendor/mollie/mollie-api-php/examples/initialize_with_oauth.php @@ -1,19 +1,19 @@ -setAccessToken("access_Wwvu7egPcJLLJ9Kb7J632x8wJ2zMeJ"); +setAccessToken("access_Wwvu7egPcJLLJ9Kb7J632x8wJ2zMeJ"); diff --git a/vendor/mollie/mollie-api-php/examples/invoices/index.php b/vendor/mollie/mollie-api-php/examples/invoices/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/examples/invoices/index.php +++ b/vendor/mollie/mollie-api-php/examples/invoices/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/invoices/list-invoices.php b/vendor/mollie/mollie-api-php/examples/invoices/list-invoices.php index 827931429..fb16c74a8 100644 --- a/vendor/mollie/mollie-api-php/examples/invoices/list-invoices.php +++ b/vendor/mollie/mollie-api-php/examples/invoices/list-invoices.php @@ -1,37 +1,37 @@ -invoices->all(); - foreach ($invoices as $invoice) { - echo '
  • Invoice ' . \htmlspecialchars($invoice->reference) . ': (' . \htmlspecialchars($invoice->issuedAt) . ')'; - echo '
    Status: ' . $invoice->status; - echo ''; - foreach ($invoice->lines as $line) { - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - } - echo ''; - echo '
    PeriodDescriptionCountVAT PercentageAmount
    ' . \htmlspecialchars($line->period) . '' . \htmlspecialchars($line->description) . '' . \htmlspecialchars($line->count) . '' . \htmlspecialchars($line->vatPercentage) . '' . \htmlspecialchars($line->amount->currency . " " . $line->amount->value) . '
    Gross Total' . \htmlspecialchars($invoice->grossAmount->value . " " . $invoice->grossAmount->currency) . '
    '; - echo 'Click here to open PDF'; - echo '
  • '; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +invoices->all(); + foreach ($invoices as $invoice) { + echo '
  • Invoice ' . \htmlspecialchars($invoice->reference) . ': (' . \htmlspecialchars($invoice->issuedAt) . ')'; + echo '
    Status: ' . $invoice->status; + echo ''; + foreach ($invoice->lines as $line) { + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + } + echo ''; + echo '
    PeriodDescriptionCountVAT PercentageAmount
    ' . \htmlspecialchars($line->period) . '' . \htmlspecialchars($line->description) . '' . \htmlspecialchars($line->count) . '' . \htmlspecialchars($line->vatPercentage) . '' . \htmlspecialchars($line->amount->currency . " " . $line->amount->value) . '
    Gross Total' . \htmlspecialchars($invoice->grossAmount->value . " " . $invoice->grossAmount->currency) . '
    '; + echo 'Click here to open PDF'; + echo '
  • '; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/mandates/create-mandate.php b/vendor/mollie/mollie-api-php/examples/mandates/create-mandate.php index 97146915b..382c1a58d 100644 --- a/vendor/mollie/mollie-api-php/examples/mandates/create-mandate.php +++ b/vendor/mollie/mollie-api-php/examples/mandates/create-mandate.php @@ -1,25 +1,25 @@ -customers->page(null, 1)[0]; - /* - * Create a SEPA Direct Debit mandate for the customer - */ - $mandate = $customer->createMandate(["method" => \_PhpScoper5ea00cc67502b\Mollie\Api\Types\MandateMethod::DIRECTDEBIT, "consumerAccount" => 'NL34ABNA0243341423', "consumerName" => 'B. A. Example']); - echo "

    Mandate created with id " . $mandate->id . " for customer " . $customer->name . "

    "; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->page(null, 1)[0]; + /* + * Create a SEPA Direct Debit mandate for the customer + */ + $mandate = $customer->createMandate(["method" => \_PhpScoper5ea00cc67502b\Mollie\Api\Types\MandateMethod::DIRECTDEBIT, "consumerAccount" => 'NL34ABNA0243341423', "consumerName" => 'B. A. Example']); + echo "

    Mandate created with id " . $mandate->id . " for customer " . $customer->name . "

    "; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/mandates/index.php b/vendor/mollie/mollie-api-php/examples/mandates/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/examples/mandates/index.php +++ b/vendor/mollie/mollie-api-php/examples/mandates/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/mandates/list-mandates.php b/vendor/mollie/mollie-api-php/examples/mandates/list-mandates.php index b88e2bf70..b8d3974da 100644 --- a/vendor/mollie/mollie-api-php/examples/mandates/list-mandates.php +++ b/vendor/mollie/mollie-api-php/examples/mandates/list-mandates.php @@ -1,27 +1,27 @@ -customers->get("cst_cUa8HjKBus"); - /* - * List the mandates of this customer - */ - echo "
      "; - foreach ($customer->mandates() as $mandate) { - echo "
    • " . \htmlspecialchars($mandate->id) . " - " . \htmlspecialchars($mandate->method) . ": " . \htmlspecialchars($mandate->status) . "
    • "; - } - echo "
    "; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->get("cst_cUa8HjKBus"); + /* + * List the mandates of this customer + */ + echo "
      "; + foreach ($customer->mandates() as $mandate) { + echo "
    • " . \htmlspecialchars($mandate->id) . " - " . \htmlspecialchars($mandate->method) . ": " . \htmlspecialchars($mandate->status) . "
    • "; + } + echo "
    "; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/mandates/revoke-mandate.php b/vendor/mollie/mollie-api-php/examples/mandates/revoke-mandate.php index 62f59e111..37d9993a1 100644 --- a/vendor/mollie/mollie-api-php/examples/mandates/revoke-mandate.php +++ b/vendor/mollie/mollie-api-php/examples/mandates/revoke-mandate.php @@ -1,28 +1,28 @@ -customers->get("cst_cUa8HjKBus"); - /* - * Retrieve an existing mandate by his mandateId - */ - $mandate = $customer->getMandate("mdt_pa3s7rGnrC"); - /* - * Revoke the mandate - */ - $mandate->revoke(); - echo "

    Mandate has been successfully revoked.

    "; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->get("cst_cUa8HjKBus"); + /* + * Retrieve an existing mandate by his mandateId + */ + $mandate = $customer->getMandate("mdt_pa3s7rGnrC"); + /* + * Revoke the mandate + */ + $mandate->revoke(); + echo "

    Mandate has been successfully revoked.

    "; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/orders/cancel-order-lines.php b/vendor/mollie/mollie-api-php/examples/orders/cancel-order-lines.php index a797ba06f..ffddb273d 100644 --- a/vendor/mollie/mollie-api-php/examples/orders/cancel-order-lines.php +++ b/vendor/mollie/mollie-api-php/examples/orders/cancel-order-lines.php @@ -1,34 +1,34 @@ -orders->get($orderId); - $line = $order->lines()->get($lineId); - if ($line && $line->isCancelable) { - $order->cancelLines(['lines' => [['id' => $lineId, 'quantity' => 1]]]); - $updatedOrder = $mollie->orders->get($orderId); - echo 'Your order ' . $order->id . ' was updated:'; - foreach ($order->lines as $line) { - echo $line->description . '. Status: ' . $line->status . '.'; - } - } else { - echo "Unable to cancel line " . $lineId . " for your order " . $orderId . "."; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->get($orderId); + $line = $order->lines()->get($lineId); + if ($line && $line->isCancelable) { + $order->cancelLines(['lines' => [['id' => $lineId, 'quantity' => 1]]]); + $updatedOrder = $mollie->orders->get($orderId); + echo 'Your order ' . $order->id . ' was updated:'; + foreach ($order->lines as $line) { + echo $line->description . '. Status: ' . $line->status . '.'; + } + } else { + echo "Unable to cancel line " . $lineId . " for your order " . $orderId . "."; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/orders/cancel-order.php b/vendor/mollie/mollie-api-php/examples/orders/cancel-order.php index eede6b83d..8534d783b 100644 --- a/vendor/mollie/mollie-api-php/examples/orders/cancel-order.php +++ b/vendor/mollie/mollie-api-php/examples/orders/cancel-order.php @@ -1,27 +1,27 @@ -orders->get("ord_pbjz8x"); - if ($order->isCancelable) { - $canceledOrder = $order->cancel(); - echo "Your order " . $order->id . " has been canceled."; - } else { - echo "Unable to cancel your order " . $order->id . "."; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->get("ord_pbjz8x"); + if ($order->isCancelable) { + $canceledOrder = $order->cancel(); + echo "Your order " . $order->id . " has been canceled."; + } else { + echo "Unable to cancel your order " . $order->id . "."; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/orders/create-order.php b/vendor/mollie/mollie-api-php/examples/orders/create-order.php index 7b610ed9a..69e33c5a4 100644 --- a/vendor/mollie/mollie-api-php/examples/orders/create-order.php +++ b/vendor/mollie/mollie-api-php/examples/orders/create-order.php @@ -1,37 +1,37 @@ -orders->create(["amount" => ["value" => "1027.99", "currency" => "EUR"], "billingAddress" => ["streetAndNumber" => "Keizersgracht 313", "postalCode" => "1016 EE", "city" => "Amsterdam", "country" => "nl", "givenName" => "Luke", "familyName" => "Skywalker", "email" => "luke@skywalker.com"], "shippingAddress" => ["streetAndNumber" => "Keizersgracht 313", "postalCode" => "1016 EE", "city" => "Amsterdam", "country" => "nl", "givenName" => "Luke", "familyName" => "Skywalker", "email" => "luke@skywalker.com"], "metadata" => ["order_id" => $orderId], "consumerDateOfBirth" => "1958-01-31", "locale" => "en_US", "orderNumber" => \strval($orderId), "redirectUrl" => "{$protocol}://{$hostname}{$path}/orders/return.php?order_id={$orderId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/orders/webhook.php", "method" => "ideal", "lines" => [["sku" => "5702016116977", "name" => "LEGO 42083 Bugatti Chiron", "productUrl" => "https://shop.lego.com/nl-NL/Bugatti-Chiron-42083", "imageUrl" => 'https://sh-s7-live-s.legocdn.com/is/image//LEGO/42083_alt1?$main$', "quantity" => 2, "vatRate" => "21.00", "unitPrice" => ["currency" => "EUR", "value" => "399.00"], "totalAmount" => ["currency" => "EUR", "value" => "698.00"], "discountAmount" => ["currency" => "EUR", "value" => "100.00"], "vatAmount" => ["currency" => "EUR", "value" => "121.14"]], ["type" => "digital", "sku" => "5702015594028", "name" => "LEGO 42056 Porsche 911 GT3 RS", "productUrl" => "https://shop.lego.com/nl-NL/Porsche-911-GT3-RS-42056", "imageUrl" => 'https://sh-s7-live-s.legocdn.com/is/image/LEGO/42056?$PDPDefault$', "quantity" => 1, "vatRate" => "21.00", "unitPrice" => ["currency" => "EUR", "value" => "329.99"], "totalAmount" => ["currency" => "EUR", "value" => "329.99"], "vatAmount" => ["currency" => "EUR", "value" => "57.27"]]]]); - /* - * Send the customer off to complete the order payment. - * This request should always be a GET, thus we enforce 303 http response code - */ - \header("Location: " . $order->getCheckoutUrl(), \true, 303); -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->create(["amount" => ["value" => "1027.99", "currency" => "EUR"], "billingAddress" => ["streetAndNumber" => "Keizersgracht 313", "postalCode" => "1016 EE", "city" => "Amsterdam", "country" => "nl", "givenName" => "Luke", "familyName" => "Skywalker", "email" => "luke@skywalker.com"], "shippingAddress" => ["streetAndNumber" => "Keizersgracht 313", "postalCode" => "1016 EE", "city" => "Amsterdam", "country" => "nl", "givenName" => "Luke", "familyName" => "Skywalker", "email" => "luke@skywalker.com"], "metadata" => ["order_id" => $orderId], "consumerDateOfBirth" => "1958-01-31", "locale" => "en_US", "orderNumber" => \strval($orderId), "redirectUrl" => "{$protocol}://{$hostname}{$path}/orders/return.php?order_id={$orderId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/orders/webhook.php", "method" => "ideal", "lines" => [["sku" => "5702016116977", "name" => "LEGO 42083 Bugatti Chiron", "productUrl" => "https://shop.lego.com/nl-NL/Bugatti-Chiron-42083", "imageUrl" => 'https://sh-s7-live-s.legocdn.com/is/image//LEGO/42083_alt1?$main$', "quantity" => 2, "vatRate" => "21.00", "unitPrice" => ["currency" => "EUR", "value" => "399.00"], "totalAmount" => ["currency" => "EUR", "value" => "698.00"], "discountAmount" => ["currency" => "EUR", "value" => "100.00"], "vatAmount" => ["currency" => "EUR", "value" => "121.14"]], ["type" => "digital", "sku" => "5702015594028", "name" => "LEGO 42056 Porsche 911 GT3 RS", "productUrl" => "https://shop.lego.com/nl-NL/Porsche-911-GT3-RS-42056", "imageUrl" => 'https://sh-s7-live-s.legocdn.com/is/image/LEGO/42056?$PDPDefault$', "quantity" => 1, "vatRate" => "21.00", "unitPrice" => ["currency" => "EUR", "value" => "329.99"], "totalAmount" => ["currency" => "EUR", "value" => "329.99"], "vatAmount" => ["currency" => "EUR", "value" => "57.27"]]]]); + /* + * Send the customer off to complete the order payment. + * This request should always be a GET, thus we enforce 303 http response code + */ + \header("Location: " . $order->getCheckoutUrl(), \true, 303); +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/orders/index.php b/vendor/mollie/mollie-api-php/examples/orders/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/examples/orders/index.php +++ b/vendor/mollie/mollie-api-php/examples/orders/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/orders/list-methods.php b/vendor/mollie/mollie-api-php/examples/orders/list-methods.php index 254220b74..15361da60 100644 --- a/vendor/mollie/mollie-api-php/examples/orders/list-methods.php +++ b/vendor/mollie/mollie-api-php/examples/orders/list-methods.php @@ -1,29 +1,29 @@ -methods->all(['resource' => 'orders']); - foreach ($methods as $method) { - echo '
    '; - echo ' '; - echo \htmlspecialchars($method->description) . ' (' . \htmlspecialchars($method->id) . ')'; - echo '
    '; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +methods->all(['resource' => 'orders']); + foreach ($methods as $method) { + echo '
    '; + echo ' '; + echo \htmlspecialchars($method->description) . ' (' . \htmlspecialchars($method->id) . ')'; + echo '
    '; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/orders/list-orders.php b/vendor/mollie/mollie-api-php/examples/orders/list-orders.php index 8722966b9..f50cdf901 100644 --- a/vendor/mollie/mollie-api-php/examples/orders/list-orders.php +++ b/vendor/mollie/mollie-api-php/examples/orders/list-orders.php @@ -1,46 +1,46 @@ -'; - $latestOrders = $mollie->orders->page(); - \_PhpScoper5ea00cc67502b\printOrders($latestOrders); - $previousOrders = $latestOrders->next(); - \_PhpScoper5ea00cc67502b\printOrders($previousOrders); - echo ''; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} -function printOrders($orders) -{ - if (empty($orders)) { - return; - } - foreach ($orders as $order) { - echo '
  • Order ' . \htmlspecialchars($order->id) . ': (' . \htmlspecialchars($order->createdAt) . ')'; - echo '
    Status: ' . \htmlspecialchars($order->status); - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo '
    Billed toShipped toTotal amount
    ' . \htmlspecialchars($order->shippingAddress->givenName) . ' ' . \htmlspecialchars($order->shippingAddress->familyName) . '' . \htmlspecialchars($order->billingAddress->givenName) . ' ' . \htmlspecialchars($order->billingAddress->familyName) . '' . \htmlspecialchars($order->amount->currency) . \str_replace('.', ',', \htmlspecialchars($order->amount->value)) . '
    '; - echo 'Click here to pay'; - echo '
  • '; - } -} +'; + $latestOrders = $mollie->orders->page(); + \_PhpScoper5ea00cc67502b\printOrders($latestOrders); + $previousOrders = $latestOrders->next(); + \_PhpScoper5ea00cc67502b\printOrders($previousOrders); + echo ''; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} +function printOrders($orders) +{ + if (empty($orders)) { + return; + } + foreach ($orders as $order) { + echo '
  • Order ' . \htmlspecialchars($order->id) . ': (' . \htmlspecialchars($order->createdAt) . ')'; + echo '
    Status: ' . \htmlspecialchars($order->status); + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo '
    Billed toShipped toTotal amount
    ' . \htmlspecialchars($order->shippingAddress->givenName) . ' ' . \htmlspecialchars($order->shippingAddress->familyName) . '' . \htmlspecialchars($order->billingAddress->givenName) . ' ' . \htmlspecialchars($order->billingAddress->familyName) . '' . \htmlspecialchars($order->amount->currency) . \str_replace('.', ',', \htmlspecialchars($order->amount->value)) . '
    '; + echo 'Click here to pay'; + echo '
  • '; + } +} diff --git a/vendor/mollie/mollie-api-php/examples/orders/refund-order-completely.php b/vendor/mollie/mollie-api-php/examples/orders/refund-order-completely.php index 3685f8348..a68995bde 100644 --- a/vendor/mollie/mollie-api-php/examples/orders/refund-order-completely.php +++ b/vendor/mollie/mollie-api-php/examples/orders/refund-order-completely.php @@ -1,24 +1,24 @@ -orders->get('ord_8wmqcHMN4U'); - $refund = $order->refundAll(); - echo 'Refund ' . $refund->id . ' was created for order ' . $order->id; - echo 'You will receive ' . $refund->amount->currency . $refund->amount->value; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->get('ord_8wmqcHMN4U'); + $refund = $order->refundAll(); + echo 'Refund ' . $refund->id . ' was created for order ' . $order->id; + echo 'You will receive ' . $refund->amount->currency . $refund->amount->value; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/orders/refund-order-partially.php b/vendor/mollie/mollie-api-php/examples/orders/refund-order-partially.php index e3f5131ee..2c853e4bb 100644 --- a/vendor/mollie/mollie-api-php/examples/orders/refund-order-partially.php +++ b/vendor/mollie/mollie-api-php/examples/orders/refund-order-partially.php @@ -1,24 +1,24 @@ -orders->get('ord_8wmqcHMN4U'); - $refund = $order->refund(['lines' => [['id' => 'odl_dgtxyl', 'quantity' => 1]], "description" => "Required quantity not in stock, refunding one photo book."]); - echo 'Refund ' . $refund->id . ' was created for part of your order ' . $order->id; - echo 'You will receive ' . $refund->amount->currency . $refund->amount->value; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->get('ord_8wmqcHMN4U'); + $refund = $order->refund(['lines' => [['id' => 'odl_dgtxyl', 'quantity' => 1]], "description" => "Required quantity not in stock, refunding one photo book."]); + echo 'Refund ' . $refund->id . ' was created for part of your order ' . $order->id; + echo 'You will receive ' . $refund->amount->currency . $refund->amount->value; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/orders/webhook.php b/vendor/mollie/mollie-api-php/examples/orders/webhook.php index 1230219fc..9661b1d13 100644 --- a/vendor/mollie/mollie-api-php/examples/orders/webhook.php +++ b/vendor/mollie/mollie-api-php/examples/orders/webhook.php @@ -1,49 +1,49 @@ -orders->get($_POST["id"]); - $orderId = $order->metadata->order_id; - /* - * Update the order in the database. - */ - \_PhpScoper5ea00cc67502b\database_write($orderId, $order->status); - if ($order->isPaid() || $order->isAuthorized()) { - /* - * The order is paid or authorized - * At this point you'd probably want to start the process of delivering the product to the customer. - */ - } elseif ($order->isCanceled()) { - /* - * The order is canceled. - */ - } elseif ($order->isExpired()) { - /* - * The order is expired. - */ - } elseif ($order->isCompleted()) { - /* - * The order is completed. - */ - } elseif ($order->isPending()) { - /* - * The order is pending. - */ - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->get($_POST["id"]); + $orderId = $order->metadata->order_id; + /* + * Update the order in the database. + */ + \_PhpScoper5ea00cc67502b\database_write($orderId, $order->status); + if ($order->isPaid() || $order->isAuthorized()) { + /* + * The order is paid or authorized + * At this point you'd probably want to start the process of delivering the product to the customer. + */ + } elseif ($order->isCanceled()) { + /* + * The order is canceled. + */ + } elseif ($order->isExpired()) { + /* + * The order is expired. + */ + } elseif ($order->isCompleted()) { + /* + * The order is completed. + */ + } elseif ($order->isPending()) { + /* + * The order is pending. + */ + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/payments/create-ideal-payment.php b/vendor/mollie/mollie-api-php/examples/payments/create-ideal-payment.php index f32dabd05..f5e4a6863 100644 --- a/vendor/mollie/mollie-api-php/examples/payments/create-ideal-payment.php +++ b/vendor/mollie/mollie-api-php/examples/payments/create-ideal-payment.php @@ -1,61 +1,61 @@ -methods->get(\_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL, ["include" => "issuers"]); - echo '
    Select your bank:
    '; - exit; - } - /* - * Generate a unique order id for this example. It is important to include this unique attribute - * in the redirectUrl (below) so a proper return page can be shown to the customer. - */ - $orderId = \time(); - /* - * Determine the url parts to these example files. - */ - $protocol = isset($_SERVER['HTTPS']) && \strcasecmp('off', $_SERVER['HTTPS']) !== 0 ? "https" : "http"; - $hostname = $_SERVER['HTTP_HOST']; - $path = \dirname(isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : $_SERVER['PHP_SELF']); - /* - * Payment parameters: - * amount Amount in EUROs. This example creates a € 27.50 payment. - * method Payment method "ideal". - * description Description of the payment. - * redirectUrl Redirect location. The customer will be redirected there after the payment. - * webhookUrl Webhook location, used to report when the payment changes state. - * metadata Custom metadata that is stored with the payment. - * issuer The customer's bank. If empty the customer can select it later. - */ - $payment = $mollie->payments->create(["amount" => ["currency" => "EUR", "value" => "27.50"], "method" => \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL, "description" => "Order #{$orderId}", "redirectUrl" => "{$protocol}://{$hostname}{$path}/payments/return.php?order_id={$orderId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", "metadata" => ["order_id" => $orderId], "issuer" => !empty($_POST["issuer"]) ? $_POST["issuer"] : null]); - /* - * In this example we store the order with its payment status in a database. - */ - \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); - /* - * Send the customer off to complete the payment. - * This request should always be a GET, thus we enforce 303 http response code - */ - \header("Location: " . $payment->getCheckoutUrl(), \true, 303); -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +methods->get(\_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL, ["include" => "issuers"]); + echo '
    Select your bank:
    '; + exit; + } + /* + * Generate a unique order id for this example. It is important to include this unique attribute + * in the redirectUrl (below) so a proper return page can be shown to the customer. + */ + $orderId = \time(); + /* + * Determine the url parts to these example files. + */ + $protocol = isset($_SERVER['HTTPS']) && \strcasecmp('off', $_SERVER['HTTPS']) !== 0 ? "https" : "http"; + $hostname = $_SERVER['HTTP_HOST']; + $path = \dirname(isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : $_SERVER['PHP_SELF']); + /* + * Payment parameters: + * amount Amount in EUROs. This example creates a € 27.50 payment. + * method Payment method "ideal". + * description Description of the payment. + * redirectUrl Redirect location. The customer will be redirected there after the payment. + * webhookUrl Webhook location, used to report when the payment changes state. + * metadata Custom metadata that is stored with the payment. + * issuer The customer's bank. If empty the customer can select it later. + */ + $payment = $mollie->payments->create(["amount" => ["currency" => "EUR", "value" => "27.50"], "method" => \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentMethod::IDEAL, "description" => "Order #{$orderId}", "redirectUrl" => "{$protocol}://{$hostname}{$path}/payments/return.php?order_id={$orderId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", "metadata" => ["order_id" => $orderId], "issuer" => !empty($_POST["issuer"]) ? $_POST["issuer"] : null]); + /* + * In this example we store the order with its payment status in a database. + */ + \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); + /* + * Send the customer off to complete the payment. + * This request should always be a GET, thus we enforce 303 http response code + */ + \header("Location: " . $payment->getCheckoutUrl(), \true, 303); +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/payments/create-payment-oauth.php b/vendor/mollie/mollie-api-php/examples/payments/create-payment-oauth.php index dfa01e293..4e19f88f8 100644 --- a/vendor/mollie/mollie-api-php/examples/payments/create-payment-oauth.php +++ b/vendor/mollie/mollie-api-php/examples/payments/create-payment-oauth.php @@ -1,51 +1,51 @@ -profiles->page(); - $profile = \reset($profiles); - /** - * Paramaters for creating a payment via oAuth - * - * @See https://docs.mollie.com/reference/v2/payments-api/create-payment - */ - $payment = $mollie->payments->create(["amount" => ["value" => "10.00", "currency" => "EUR"], "description" => "My first API payment", "redirectUrl" => "{$protocol}://{$hostname}{$path}/payments/return.php?order_id={$orderId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", "metadata" => ["order_id" => $orderId], "profileId" => $profile->id]); - /* - * In this example we store the order with its payment status in a database. - */ - \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); - /* - * Send the customer off to complete the payment. - * This request should always be a GET, thus we enforce 303 http response code - */ - if (\PHP_SAPI === "cli") { - echo "Redirect to: " . $payment->getCheckoutUrl() . \PHP_EOL; - return; - } - \header("Location: " . $payment->getCheckoutUrl(), \true, 303); -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +profiles->page(); + $profile = \reset($profiles); + /** + * Paramaters for creating a payment via oAuth + * + * @See https://docs.mollie.com/reference/v2/payments-api/create-payment + */ + $payment = $mollie->payments->create(["amount" => ["value" => "10.00", "currency" => "EUR"], "description" => "My first API payment", "redirectUrl" => "{$protocol}://{$hostname}{$path}/payments/return.php?order_id={$orderId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", "metadata" => ["order_id" => $orderId], "profileId" => $profile->id]); + /* + * In this example we store the order with its payment status in a database. + */ + \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); + /* + * Send the customer off to complete the payment. + * This request should always be a GET, thus we enforce 303 http response code + */ + if (\PHP_SAPI === "cli") { + echo "Redirect to: " . $payment->getCheckoutUrl() . \PHP_EOL; + return; + } + \header("Location: " . $payment->getCheckoutUrl(), \true, 303); +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/payments/create-payment.php b/vendor/mollie/mollie-api-php/examples/payments/create-payment.php index b361f4a90..692788059 100644 --- a/vendor/mollie/mollie-api-php/examples/payments/create-payment.php +++ b/vendor/mollie/mollie-api-php/examples/payments/create-payment.php @@ -1,46 +1,46 @@ -payments->create(["amount" => ["currency" => "EUR", "value" => "10.00"], "description" => "Order #{$orderId}", "redirectUrl" => "{$protocol}://{$hostname}{$path}/payments/return.php?order_id={$orderId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", "metadata" => ["order_id" => $orderId]]); - /* - * In this example we store the order with its payment status in a database. - */ - \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); - /* - * Send the customer off to complete the payment. - * This request should always be a GET, thus we enforce 303 http response code - */ - \header("Location: " . $payment->getCheckoutUrl(), \true, 303); -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +payments->create(["amount" => ["currency" => "EUR", "value" => "10.00"], "description" => "Order #{$orderId}", "redirectUrl" => "{$protocol}://{$hostname}{$path}/payments/return.php?order_id={$orderId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/payments/webhook.php", "metadata" => ["order_id" => $orderId]]); + /* + * In this example we store the order with its payment status in a database. + */ + \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); + /* + * Send the customer off to complete the payment. + * This request should always be a GET, thus we enforce 303 http response code + */ + \header("Location: " . $payment->getCheckoutUrl(), \true, 303); +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/payments/index.php b/vendor/mollie/mollie-api-php/examples/payments/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/examples/payments/index.php +++ b/vendor/mollie/mollie-api-php/examples/payments/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/payments/list-methods.php b/vendor/mollie/mollie-api-php/examples/payments/list-methods.php index 2df8fc65b..37b4bbee8 100644 --- a/vendor/mollie/mollie-api-php/examples/payments/list-methods.php +++ b/vendor/mollie/mollie-api-php/examples/payments/list-methods.php @@ -1,29 +1,29 @@ -methods->allActive(); - foreach ($methods as $method) { - echo '
    '; - echo ' '; - echo \htmlspecialchars($method->description) . ' (' . \htmlspecialchars($method->id) . ')'; - echo '
    '; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +methods->allActive(); + foreach ($methods as $method) { + echo '
    '; + echo ' '; + echo \htmlspecialchars($method->description) . ' (' . \htmlspecialchars($method->id) . ')'; + echo '
    '; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/payments/list-payments.php b/vendor/mollie/mollie-api-php/examples/payments/list-payments.php index 22f94fb44..449430d73 100644 --- a/vendor/mollie/mollie-api-php/examples/payments/list-payments.php +++ b/vendor/mollie/mollie-api-php/examples/payments/list-payments.php @@ -1,71 +1,71 @@ -payments->page(); - echo "
      "; - foreach ($payments as $payment) { - echo "
    • "; - echo "" . \htmlspecialchars($payment->id) . "
      "; - echo \htmlspecialchars($payment->description) . "
      "; - echo \htmlspecialchars($payment->amount->currency) . " " . \htmlspecialchars($payment->amount->value) . "
      "; - echo "Status: " . \htmlspecialchars($payment->status) . "
      "; - if ($payment->hasRefunds()) { - echo "Payment has been (partially) refunded.
      "; - } - if ($payment->hasChargebacks()) { - echo "Payment has been charged back.
      "; - } - if ($payment->canBeRefunded() && $payment->amountRemaining->currency === 'EUR' && $payment->amountRemaining->value >= '2.00') { - echo " (id) . "\">refund)"; - } - echo "
    • "; - } - echo "
    "; - /** - * Get the next set of Payments if applicable - */ - $nextPayments = $payments->next(); - if (!empty($nextPayments)) { - echo "
      "; - foreach ($nextPayments as $payment) { - echo "
    • "; - echo "" . \htmlspecialchars($payment->id) . "
      "; - echo \htmlspecialchars($payment->description) . "
      "; - echo \htmlspecialchars($payment->amount->currency) . " " . \htmlspecialchars($payment->amount->value) . "
      "; - echo "Status: " . \htmlspecialchars($payment->status) . "
      "; - if ($payment->hasRefunds()) { - echo "Payment has been (partially) refunded.
      "; - } - if ($payment->hasChargebacks()) { - echo "Payment has been charged back.
      "; - } - if ($payment->canBeRefunded() && $payment->amountRemaining->currency === 'EUR' && $payment->amountRemaining->value >= '2.00') { - echo " (id) . "\">refund)"; - } - echo "
    • "; - } - echo "
    "; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +payments->page(); + echo "
      "; + foreach ($payments as $payment) { + echo "
    • "; + echo "" . \htmlspecialchars($payment->id) . "
      "; + echo \htmlspecialchars($payment->description) . "
      "; + echo \htmlspecialchars($payment->amount->currency) . " " . \htmlspecialchars($payment->amount->value) . "
      "; + echo "Status: " . \htmlspecialchars($payment->status) . "
      "; + if ($payment->hasRefunds()) { + echo "Payment has been (partially) refunded.
      "; + } + if ($payment->hasChargebacks()) { + echo "Payment has been charged back.
      "; + } + if ($payment->canBeRefunded() && $payment->amountRemaining->currency === 'EUR' && $payment->amountRemaining->value >= '2.00') { + echo " (id) . "\">refund)"; + } + echo "
    • "; + } + echo "
    "; + /** + * Get the next set of Payments if applicable + */ + $nextPayments = $payments->next(); + if (!empty($nextPayments)) { + echo "
      "; + foreach ($nextPayments as $payment) { + echo "
    • "; + echo "" . \htmlspecialchars($payment->id) . "
      "; + echo \htmlspecialchars($payment->description) . "
      "; + echo \htmlspecialchars($payment->amount->currency) . " " . \htmlspecialchars($payment->amount->value) . "
      "; + echo "Status: " . \htmlspecialchars($payment->status) . "
      "; + if ($payment->hasRefunds()) { + echo "Payment has been (partially) refunded.
      "; + } + if ($payment->hasChargebacks()) { + echo "Payment has been charged back.
      "; + } + if ($payment->canBeRefunded() && $payment->amountRemaining->currency === 'EUR' && $payment->amountRemaining->value >= '2.00') { + echo " (id) . "\">refund)"; + } + echo "
    • "; + } + echo "
    "; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/payments/refund-payment.php b/vendor/mollie/mollie-api-php/examples/payments/refund-payment.php index 541b854ef..1c4a9bc4d 100644 --- a/vendor/mollie/mollie-api-php/examples/payments/refund-payment.php +++ b/vendor/mollie/mollie-api-php/examples/payments/refund-payment.php @@ -1,61 +1,61 @@ -payments->get($paymentId); - if ($payment->canBeRefunded() && $payment->amountRemaining->currency === 'EUR' && $payment->amountRemaining->value >= '2.00') { - /* - * Refund € 2,00 of the payment. - * - * https://docs.mollie.com/reference/v2/refunds-api/create-refund - */ - $refund = $payment->refund(["amount" => ["currency" => "EUR", "value" => "2.00"]]); - echo "{$refund->amount->currency} {$refund->amount->value} of payment {$paymentId} refunded.", \PHP_EOL; - } else { - echo "Payment {$paymentId} can not be refunded.", \PHP_EOL; - } - /* - * Retrieve all refunds on a payment. - */ - echo "
      "; - foreach ($payment->refunds() as $refund) { - echo "
    • "; - echo "" . \htmlspecialchars($refund->id) . "
      "; - echo \htmlspecialchars($refund->description) . "
      "; - echo \htmlspecialchars($refund->amount->currency) . " " . \htmlspecialchars($refund->amount->value) . "
      "; - echo "Status: " . \htmlspecialchars($refund->status); - echo "
    • "; - } - echo "
    "; - } - echo "Refund payment: "; - echo "
    "; - echo "

    "; - echo 'Create a payment
    '; - echo 'Create an iDEAL payment
    '; - echo 'List payments
    '; - echo "

    "; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +payments->get($paymentId); + if ($payment->canBeRefunded() && $payment->amountRemaining->currency === 'EUR' && $payment->amountRemaining->value >= '2.00') { + /* + * Refund € 2,00 of the payment. + * + * https://docs.mollie.com/reference/v2/refunds-api/create-refund + */ + $refund = $payment->refund(["amount" => ["currency" => "EUR", "value" => "2.00"]]); + echo "{$refund->amount->currency} {$refund->amount->value} of payment {$paymentId} refunded.", \PHP_EOL; + } else { + echo "Payment {$paymentId} can not be refunded.", \PHP_EOL; + } + /* + * Retrieve all refunds on a payment. + */ + echo "
      "; + foreach ($payment->refunds() as $refund) { + echo "
    • "; + echo "" . \htmlspecialchars($refund->id) . "
      "; + echo \htmlspecialchars($refund->description) . "
      "; + echo \htmlspecialchars($refund->amount->currency) . " " . \htmlspecialchars($refund->amount->value) . "
      "; + echo "Status: " . \htmlspecialchars($refund->status); + echo "
    • "; + } + echo "
    "; + } + echo "Refund payment: "; + echo "
    "; + echo "

    "; + echo 'Create a payment
    '; + echo 'Create an iDEAL payment
    '; + echo 'List payments
    '; + echo "

    "; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/payments/return.php b/vendor/mollie/mollie-api-php/examples/payments/return.php index c99d473cb..b7db5f6dd 100644 --- a/vendor/mollie/mollie-api-php/examples/payments/return.php +++ b/vendor/mollie/mollie-api-php/examples/payments/return.php @@ -1,28 +1,28 @@ -Your payment status is '" . \htmlspecialchars($status) . "'.

    "; -echo "

    "; -echo 'Create a payment
    '; -echo 'Create an iDEAL payment
    '; -echo 'List payments
    '; -echo "

    "; +Your payment status is '" . \htmlspecialchars($status) . "'.

    "; +echo "

    "; +echo 'Create a payment
    '; +echo 'Create an iDEAL payment
    '; +echo 'List payments
    '; +echo "

    "; diff --git a/vendor/mollie/mollie-api-php/examples/payments/webhook.php b/vendor/mollie/mollie-api-php/examples/payments/webhook.php index 196b1fc68..5705f0265 100644 --- a/vendor/mollie/mollie-api-php/examples/payments/webhook.php +++ b/vendor/mollie/mollie-api-php/examples/payments/webhook.php @@ -1,64 +1,64 @@ -payments->get($_POST["id"]); - $orderId = $payment->metadata->order_id; - /* - * Update the order in the database. - */ - \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); - if ($payment->isPaid() && !$payment->hasRefunds() && !$payment->hasChargebacks()) { - /* - * The payment is paid and isn't refunded or charged back. - * At this point you'd probably want to start the process of delivering the product to the customer. - */ - } elseif ($payment->isOpen()) { - /* - * The payment is open. - */ - } elseif ($payment->isPending()) { - /* - * The payment is pending. - */ - } elseif ($payment->isFailed()) { - /* - * The payment has failed. - */ - } elseif ($payment->isExpired()) { - /* - * The payment is expired. - */ - } elseif ($payment->isCanceled()) { - /* - * The payment has been canceled. - */ - } elseif ($payment->hasRefunds()) { - /* - * The payment has been (partially) refunded. - * The status of the payment is still "paid" - */ - } elseif ($payment->hasChargebacks()) { - /* - * The payment has been (partially) charged back. - * The status of the payment is still "paid" - */ - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +payments->get($_POST["id"]); + $orderId = $payment->metadata->order_id; + /* + * Update the order in the database. + */ + \_PhpScoper5ea00cc67502b\database_write($orderId, $payment->status); + if ($payment->isPaid() && !$payment->hasRefunds() && !$payment->hasChargebacks()) { + /* + * The payment is paid and isn't refunded or charged back. + * At this point you'd probably want to start the process of delivering the product to the customer. + */ + } elseif ($payment->isOpen()) { + /* + * The payment is open. + */ + } elseif ($payment->isPending()) { + /* + * The payment is pending. + */ + } elseif ($payment->isFailed()) { + /* + * The payment has failed. + */ + } elseif ($payment->isExpired()) { + /* + * The payment is expired. + */ + } elseif ($payment->isCanceled()) { + /* + * The payment has been canceled. + */ + } elseif ($payment->hasRefunds()) { + /* + * The payment has been (partially) refunded. + * The status of the payment is still "paid" + */ + } elseif ($payment->hasChargebacks()) { + /* + * The payment has been (partially) charged back. + * The status of the payment is still "paid" + */ + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/profiles/create-profile.php b/vendor/mollie/mollie-api-php/examples/profiles/create-profile.php index fbd4cad8f..f81b1dc01 100644 --- a/vendor/mollie/mollie-api-php/examples/profiles/create-profile.php +++ b/vendor/mollie/mollie-api-php/examples/profiles/create-profile.php @@ -1,22 +1,22 @@ -profiles->create(["name" => "My website name", "website" => "https://www.mywebsite.com", "email" => "info@mywebsite.com", "phone" => "+31208202070", "categoryCode" => 5399, "mode" => "live"]); - echo "

    Profile created: " . \htmlspecialchars($profile->name) . "

    "; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "

    API call failed: " . \htmlspecialchars($e->getMessage()) . "

    "; -} +profiles->create(["name" => "My website name", "website" => "https://www.mywebsite.com", "email" => "info@mywebsite.com", "phone" => "+31208202070", "categoryCode" => 5399, "mode" => "live"]); + echo "

    Profile created: " . \htmlspecialchars($profile->name) . "

    "; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "

    API call failed: " . \htmlspecialchars($e->getMessage()) . "

    "; +} diff --git a/vendor/mollie/mollie-api-php/examples/profiles/delete-profile.php b/vendor/mollie/mollie-api-php/examples/profiles/delete-profile.php index 75636c4ca..0118cd0b3 100644 --- a/vendor/mollie/mollie-api-php/examples/profiles/delete-profile.php +++ b/vendor/mollie/mollie-api-php/examples/profiles/delete-profile.php @@ -1,22 +1,22 @@ -profiles->delete("pfl_v9hTwCvYqw"); - echo "

    Profile deleted

    "; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "

    API call failed: " . \htmlspecialchars($e->getMessage()) . "

    "; -} +profiles->delete("pfl_v9hTwCvYqw"); + echo "

    Profile deleted

    "; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "

    API call failed: " . \htmlspecialchars($e->getMessage()) . "

    "; +} diff --git a/vendor/mollie/mollie-api-php/examples/profiles/index.php b/vendor/mollie/mollie-api-php/examples/profiles/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/examples/profiles/index.php +++ b/vendor/mollie/mollie-api-php/examples/profiles/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/profiles/list-profiles.php b/vendor/mollie/mollie-api-php/examples/profiles/list-profiles.php index 6c0be4184..017c08416 100644 --- a/vendor/mollie/mollie-api-php/examples/profiles/list-profiles.php +++ b/vendor/mollie/mollie-api-php/examples/profiles/list-profiles.php @@ -1,24 +1,24 @@ -profiles->page(); - foreach ($profiles as $profile) { - echo '
    '; - echo \htmlspecialchars($profile->name) . ' - ' . \htmlspecialchars($profile->website) . ' (' . \htmlspecialchars($profile->id) . ')'; - echo '
    '; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +profiles->page(); + foreach ($profiles as $profile) { + echo '
    '; + echo \htmlspecialchars($profile->name) . ' - ' . \htmlspecialchars($profile->website) . ' (' . \htmlspecialchars($profile->id) . ')'; + echo '
    '; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/profiles/update-profile.php b/vendor/mollie/mollie-api-php/examples/profiles/update-profile.php index 929fbf5cc..69e99d92f 100644 --- a/vendor/mollie/mollie-api-php/examples/profiles/update-profile.php +++ b/vendor/mollie/mollie-api-php/examples/profiles/update-profile.php @@ -1,31 +1,31 @@ -profiles->get("pfl_eA4MSz7Bvy"); - /** - * Profile fields that can be updated. - * - * @See https://docs.mollie.com/reference/v2/profiles-api/update-profile - */ - $profile->name = "Mollie B.V."; - $profile->website = 'www.mollie.com'; - $profile->email = 'info@mollie.com'; - $profile->phone = '0612345670'; - $profile->categoryCode = 5399; - $profile->update(); - echo "

    Profile updated: " . \htmlspecialchars($profile->name) . "

    "; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "

    API call failed: " . \htmlspecialchars($e->getMessage()) . "

    "; -} +profiles->get("pfl_eA4MSz7Bvy"); + /** + * Profile fields that can be updated. + * + * @See https://docs.mollie.com/reference/v2/profiles-api/update-profile + */ + $profile->name = "Mollie B.V."; + $profile->website = 'www.mollie.com'; + $profile->email = 'info@mollie.com'; + $profile->phone = '0612345670'; + $profile->categoryCode = 5399; + $profile->update(); + echo "

    Profile updated: " . \htmlspecialchars($profile->name) . "

    "; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "

    API call failed: " . \htmlspecialchars($e->getMessage()) . "

    "; +} diff --git a/vendor/mollie/mollie-api-php/examples/settlements/index.php b/vendor/mollie/mollie-api-php/examples/settlements/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/examples/settlements/index.php +++ b/vendor/mollie/mollie-api-php/examples/settlements/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/settlements/list-settlements.php b/vendor/mollie/mollie-api-php/examples/settlements/list-settlements.php index 7229a5fa9..74ed0fba3 100644 --- a/vendor/mollie/mollie-api-php/examples/settlements/list-settlements.php +++ b/vendor/mollie/mollie-api-php/examples/settlements/list-settlements.php @@ -1,54 +1,54 @@ -settlements->page(); - echo '
      '; - foreach ($settlements as $settlement) { - echo '
    • Settlement ' . \htmlspecialchars($settlement->reference) . ': (' . \htmlspecialchars($settlement->createdAt) . ')'; - echo ''; - // Convert from stdClass to array - $settlement_periods = \json_decode(\json_encode($settlement->periods), \TRUE); - foreach ($settlement_periods as $year => $months) { - foreach ($months as $month => $monthly_settlement) { - foreach ($monthly_settlement['revenue'] as $revenue) { - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - } - foreach ($monthly_settlement['costs'] as $revenue) { - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - echo ''; - } - } - } - echo ''; - echo '
      MonthDescriptionCountNetVATGross
      ' . \htmlspecialchars($year . '-' . $month) . '' . \htmlspecialchars($revenue['description']) . '' . \htmlspecialchars($revenue['count']) . ' x' . \htmlspecialchars($revenue['amountNet']['value'] ? $revenue['amountNet']['value'] . " " . $revenue['amountNet']['currency'] : '-') . '' . \htmlspecialchars($revenue['amountVat']['value'] ? $revenue['amountVat']['value'] . " " . $revenue['amountVat']['currency'] : '-') . '' . \htmlspecialchars($revenue['amountGross']['value'] ? $revenue['amountGross']['value'] . " " . $revenue['amountGross']['currency'] : '-') . '
      ' . \htmlspecialchars($year . '-' . $month) . '' . \htmlspecialchars($revenue['description']) . '' . \htmlspecialchars($revenue['count']) . ' x' . \htmlspecialchars($revenue['amountNet']['value'] ? $revenue['amountNet']['value'] . " " . $revenue['amountNet']['currency'] : '-') . '' . \htmlspecialchars($revenue['amountVat']['value'] ? $revenue['amountVat']['value'] . " " . $revenue['amountVat']['currency'] : '-') . '' . \htmlspecialchars($revenue['amountGross']['value'] ? $revenue['amountGross']['value'] . " " . $revenue['amountGross']['currency'] : '-') . '
      TOTAL' . \htmlspecialchars($settlement->amount->value . " " . $settlement->amount->currency) . '
      '; - echo '
    • '; - } - echo '
    '; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +settlements->page(); + echo '
      '; + foreach ($settlements as $settlement) { + echo '
    • Settlement ' . \htmlspecialchars($settlement->reference) . ': (' . \htmlspecialchars($settlement->createdAt) . ')'; + echo ''; + // Convert from stdClass to array + $settlement_periods = \json_decode(\json_encode($settlement->periods), \TRUE); + foreach ($settlement_periods as $year => $months) { + foreach ($months as $month => $monthly_settlement) { + foreach ($monthly_settlement['revenue'] as $revenue) { + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + } + foreach ($monthly_settlement['costs'] as $revenue) { + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + } + } + } + echo ''; + echo '
      MonthDescriptionCountNetVATGross
      ' . \htmlspecialchars($year . '-' . $month) . '' . \htmlspecialchars($revenue['description']) . '' . \htmlspecialchars($revenue['count']) . ' x' . \htmlspecialchars($revenue['amountNet']['value'] ? $revenue['amountNet']['value'] . " " . $revenue['amountNet']['currency'] : '-') . '' . \htmlspecialchars($revenue['amountVat']['value'] ? $revenue['amountVat']['value'] . " " . $revenue['amountVat']['currency'] : '-') . '' . \htmlspecialchars($revenue['amountGross']['value'] ? $revenue['amountGross']['value'] . " " . $revenue['amountGross']['currency'] : '-') . '
      ' . \htmlspecialchars($year . '-' . $month) . '' . \htmlspecialchars($revenue['description']) . '' . \htmlspecialchars($revenue['count']) . ' x' . \htmlspecialchars($revenue['amountNet']['value'] ? $revenue['amountNet']['value'] . " " . $revenue['amountNet']['currency'] : '-') . '' . \htmlspecialchars($revenue['amountVat']['value'] ? $revenue['amountVat']['value'] . " " . $revenue['amountVat']['currency'] : '-') . '' . \htmlspecialchars($revenue['amountGross']['value'] ? $revenue['amountGross']['value'] . " " . $revenue['amountGross']['currency'] : '-') . '
      TOTAL' . \htmlspecialchars($settlement->amount->value . " " . $settlement->amount->currency) . '
      '; + echo '
    • '; + } + echo '
    '; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/shipments/create-shipment-all.php b/vendor/mollie/mollie-api-php/examples/shipments/create-shipment-all.php index 5a71bb88f..792a7fa32 100644 --- a/vendor/mollie/mollie-api-php/examples/shipments/create-shipment-all.php +++ b/vendor/mollie/mollie-api-php/examples/shipments/create-shipment-all.php @@ -1,26 +1,26 @@ -orders->get('ord_8wmqcHMN4U'); - $shipment = $order->shipAll(); - echo 'A shipment with ID ' . $shipment->id . ' has been created for your order with ID ' . $order->id . '.'; - foreach ($shipment->lines as $line) { - echo $line->name . ' - status: ' . $line->status . '.'; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->get('ord_8wmqcHMN4U'); + $shipment = $order->shipAll(); + echo 'A shipment with ID ' . $shipment->id . ' has been created for your order with ID ' . $order->id . '.'; + foreach ($shipment->lines as $line) { + echo $line->name . ' - status: ' . $line->status . '.'; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/shipments/create-shipment-partial.php b/vendor/mollie/mollie-api-php/examples/shipments/create-shipment-partial.php index f4e939099..fdb1b38df 100644 --- a/vendor/mollie/mollie-api-php/examples/shipments/create-shipment-partial.php +++ b/vendor/mollie/mollie-api-php/examples/shipments/create-shipment-partial.php @@ -1,28 +1,28 @@ -orders->get('ord_8wmqcHMN4U'); - $lineId1 = $order->lines()[0]->id; - $lineId2 = $order->lines()[1]->id; - $shipment = $order->createShipment(['lines' => [['id' => $lineId1], ['id' => $lineId2, 'quantity' => 1]]]); - echo 'A shipment with ID ' . $shipment->id . ' has been created for your order with ID ' . $order->id . '.'; - foreach ($shipment->lines as $line) { - echo $line->name . '- status: ' . $line->status . '.'; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->get('ord_8wmqcHMN4U'); + $lineId1 = $order->lines()[0]->id; + $lineId2 = $order->lines()[1]->id; + $shipment = $order->createShipment(['lines' => [['id' => $lineId1], ['id' => $lineId2, 'quantity' => 1]]]); + echo 'A shipment with ID ' . $shipment->id . ' has been created for your order with ID ' . $order->id . '.'; + foreach ($shipment->lines as $line) { + echo $line->name . '- status: ' . $line->status . '.'; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/shipments/get-shipment.php b/vendor/mollie/mollie-api-php/examples/shipments/get-shipment.php index 2ee014456..20df411fd 100644 --- a/vendor/mollie/mollie-api-php/examples/shipments/get-shipment.php +++ b/vendor/mollie/mollie-api-php/examples/shipments/get-shipment.php @@ -1,26 +1,26 @@ -orders->get('ord_8wmqcHMN4U'); - $shipment = $order->getShipment("shp_3wmsgCJN4U"); - echo 'Shipment with ID ' . $shipment->id . ' for order with ID ' . $order->id . '.'; - foreach ($shipment->lines as $line) { - echo $line->name . ' - status: ' . $line->status . '.'; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->get('ord_8wmqcHMN4U'); + $shipment = $order->getShipment("shp_3wmsgCJN4U"); + echo 'Shipment with ID ' . $shipment->id . ' for order with ID ' . $order->id . '.'; + foreach ($shipment->lines as $line) { + echo $line->name . ' - status: ' . $line->status . '.'; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/shipments/index.php b/vendor/mollie/mollie-api-php/examples/shipments/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/examples/shipments/index.php +++ b/vendor/mollie/mollie-api-php/examples/shipments/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/shipments/list-shipments.php b/vendor/mollie/mollie-api-php/examples/shipments/list-shipments.php index 54fde07b2..90b610e23 100644 --- a/vendor/mollie/mollie-api-php/examples/shipments/list-shipments.php +++ b/vendor/mollie/mollie-api-php/examples/shipments/list-shipments.php @@ -1,29 +1,29 @@ -orders->get('ord_8wmqcHMN4U'); - $shipments = $order->shipments(); - echo 'Shipments for order with ID ' . $order->id . ':'; - foreach ($shipments as $shipment) { - echo 'Shipment ' . $shipment->id . '. Items:'; - foreach ($shipment->lines as $line) { - echo $line->name . ' - status: ' . $line->status . '.'; - } - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->get('ord_8wmqcHMN4U'); + $shipments = $order->shipments(); + echo 'Shipments for order with ID ' . $order->id . ':'; + foreach ($shipments as $shipment) { + echo 'Shipment ' . $shipment->id . '. Items:'; + foreach ($shipment->lines as $line) { + echo $line->name . ' - status: ' . $line->status . '.'; + } + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/shipments/update-shipment.php b/vendor/mollie/mollie-api-php/examples/shipments/update-shipment.php index ee77f8c20..182ccf991 100644 --- a/vendor/mollie/mollie-api-php/examples/shipments/update-shipment.php +++ b/vendor/mollie/mollie-api-php/examples/shipments/update-shipment.php @@ -1,33 +1,33 @@ -orders->get('ord_8wmqcHMN4U'); - $shipment = $order->getShipment("shp_3wmsgCJN4U"); - $shipment->tracking = ['carrier' => 'PostNL', 'code' => '3SKABA000000000', 'url' => 'http://postnl.nl/tracktrace/?B=3SKABA000000000&P=1016EE&D=NL&T=C']; - $shipment = $shipment->update(); - echo 'Shipment with ID ' . $shipment->id . ' for order with ID ' . $order->id . '.'; - echo 'Tracking information updated:'; - echo 'Carrier: ' . $shipment->tracking->carrier; - echo 'Code: ' . $shipment->tracking->code; - echo 'Url: ' . $shipment->tracking->url; - foreach ($shipment->lines as $line) { - echo $line->name . ' - status: ' . $line->status . '.'; - } -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +orders->get('ord_8wmqcHMN4U'); + $shipment = $order->getShipment("shp_3wmsgCJN4U"); + $shipment->tracking = ['carrier' => 'PostNL', 'code' => '3SKABA000000000', 'url' => 'http://postnl.nl/tracktrace/?B=3SKABA000000000&P=1016EE&D=NL&T=C']; + $shipment = $shipment->update(); + echo 'Shipment with ID ' . $shipment->id . ' for order with ID ' . $order->id . '.'; + echo 'Tracking information updated:'; + echo 'Carrier: ' . $shipment->tracking->carrier; + echo 'Code: ' . $shipment->tracking->code; + echo 'Url: ' . $shipment->tracking->url; + foreach ($shipment->lines as $line) { + echo $line->name . ' - status: ' . $line->status . '.'; + } +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/subscriptions/cancel-subscription.php b/vendor/mollie/mollie-api-php/examples/subscriptions/cancel-subscription.php index d67758be4..c1f06c183 100644 --- a/vendor/mollie/mollie-api-php/examples/subscriptions/cancel-subscription.php +++ b/vendor/mollie/mollie-api-php/examples/subscriptions/cancel-subscription.php @@ -1,34 +1,34 @@ -customers->page(null, 1)[0]; - /* - * The subscription ID, starting with sub_ - */ - $subscriptionId = isset($_GET['subscription_id']) ? $_GET['subscription_id'] : ''; - /* - * Customer Subscription deletion parameters. - * - * See: https://www.mollie.com/nl/docs/reference/subscriptions/delete - */ - $canceledSubscription = $customer->cancelSubscription($subscriptionId); - /* - * The subscription status should now be canceled - */ - echo "

    The subscription status is now: '" . \htmlspecialchars($canceledSubscription->status) . "'.

    \n"; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->page(null, 1)[0]; + /* + * The subscription ID, starting with sub_ + */ + $subscriptionId = isset($_GET['subscription_id']) ? $_GET['subscription_id'] : ''; + /* + * Customer Subscription deletion parameters. + * + * See: https://www.mollie.com/nl/docs/reference/subscriptions/delete + */ + $canceledSubscription = $customer->cancelSubscription($subscriptionId); + /* + * The subscription status should now be canceled + */ + echo "

    The subscription status is now: '" . \htmlspecialchars($canceledSubscription->status) . "'.

    \n"; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/subscriptions/create-subscription.php b/vendor/mollie/mollie-api-php/examples/subscriptions/create-subscription.php index 8a8ff8d3a..11c15c316 100644 --- a/vendor/mollie/mollie-api-php/examples/subscriptions/create-subscription.php +++ b/vendor/mollie/mollie-api-php/examples/subscriptions/create-subscription.php @@ -1,50 +1,50 @@ -customers->page(null, 1)[0]; - /* - * Generate a unique subscription id for this example. It is important to include this unique attribute - * in the webhookUrl (below) so new payments can be associated with this subscription. - */ - $subscriptionId = \time(); - /** - * Customer Subscription creation parameters. - * - * @See: https://docs.mollie.com/reference/v2/subscriptions-api/create-subscription - */ - $subscription = $customer->createSubscription(["amount" => [ - "value" => "10.00", - // You must send the correct number of decimals, thus we enforce the use of strings - "currency" => "EUR", - ], "times" => 12, "interval" => "1 month", "description" => "Subscription #{$subscriptionId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/subscriptions/webhook.php", "metadata" => ["subscription_id" => $subscriptionId]]); - /* - * The subscription will be either pending or active depending on whether the customer has - * a pending or valid mandate. If the customer has no mandates an error is returned. You - * should then set up a "first payment" for the customer. - */ - echo "

    The subscription status is '" . \htmlspecialchars($subscription->status) . "'.

    \n"; - echo "

    "; - echo '18-cancel-subscription
    '; - echo "

    "; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->page(null, 1)[0]; + /* + * Generate a unique subscription id for this example. It is important to include this unique attribute + * in the webhookUrl (below) so new payments can be associated with this subscription. + */ + $subscriptionId = \time(); + /** + * Customer Subscription creation parameters. + * + * @See: https://docs.mollie.com/reference/v2/subscriptions-api/create-subscription + */ + $subscription = $customer->createSubscription(["amount" => [ + "value" => "10.00", + // You must send the correct number of decimals, thus we enforce the use of strings + "currency" => "EUR", + ], "times" => 12, "interval" => "1 month", "description" => "Subscription #{$subscriptionId}", "webhookUrl" => "{$protocol}://{$hostname}{$path}/subscriptions/webhook.php", "metadata" => ["subscription_id" => $subscriptionId]]); + /* + * The subscription will be either pending or active depending on whether the customer has + * a pending or valid mandate. If the customer has no mandates an error is returned. You + * should then set up a "first payment" for the customer. + */ + echo "

    The subscription status is '" . \htmlspecialchars($subscription->status) . "'.

    \n"; + echo "

    "; + echo '18-cancel-subscription
    '; + echo "

    "; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/examples/subscriptions/index.php b/vendor/mollie/mollie-api-php/examples/subscriptions/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/examples/subscriptions/index.php +++ b/vendor/mollie/mollie-api-php/examples/subscriptions/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/examples/subscriptions/update-subscription.php b/vendor/mollie/mollie-api-php/examples/subscriptions/update-subscription.php index 31b83bbe7..3fe092a26 100644 --- a/vendor/mollie/mollie-api-php/examples/subscriptions/update-subscription.php +++ b/vendor/mollie/mollie-api-php/examples/subscriptions/update-subscription.php @@ -1,32 +1,32 @@ -customers->get("cst_cUe8HjeBuz"); - $subscription = $customer->getSubscription("sub_DRjwaT5qHx"); - /** - * Subscription fields that can be updated are described by the link: - * See https://docs.mollie.com/reference/v2/subscriptions-api/update-subscription - */ - $subscription->times = 10; - $subscription->startDate = '2018-12-02'; - // Year-month-day - $subscription->amount = (object) ['value' => '12.12', 'currency' => 'EUR']; - $subscription->webhookUrl = 'https://some-webhook-url.com/with/path'; - $subscription->description = 'Monthly subscription'; - $subscription->update(); - echo "

    Subscription updated: " . $subscription->id . "

    "; -} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { - echo "API call failed: " . \htmlspecialchars($e->getMessage()); -} +customers->get("cst_cUe8HjeBuz"); + $subscription = $customer->getSubscription("sub_DRjwaT5qHx"); + /** + * Subscription fields that can be updated are described by the link: + * See https://docs.mollie.com/reference/v2/subscriptions-api/update-subscription + */ + $subscription->times = 10; + $subscription->startDate = '2018-12-02'; + // Year-month-day + $subscription->amount = (object) ['value' => '12.12', 'currency' => 'EUR']; + $subscription->webhookUrl = 'https://some-webhook-url.com/with/path'; + $subscription->description = 'Monthly subscription'; + $subscription->update(); + echo "

    Subscription updated: " . $subscription->id . "

    "; +} catch (\_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException $e) { + echo "API call failed: " . \htmlspecialchars($e->getMessage()); +} diff --git a/vendor/mollie/mollie-api-php/index.php b/vendor/mollie/mollie-api-php/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/index.php +++ b/vendor/mollie/mollie-api-php/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/phpstan.neon b/vendor/mollie/mollie-api-php/phpstan.neon index 90b95f848..1e62f5d8e 100644 --- a/vendor/mollie/mollie-api-php/phpstan.neon +++ b/vendor/mollie/mollie-api-php/phpstan.neon @@ -1,10 +1,10 @@ -parameters: - level: 1 - paths: - - %currentWorkingDirectory%/src - - %currentWorkingDirectory%/tests - - %currentWorkingDirectory%/examples - excludes_analyse: - - %currentWorkingDirectory%/vendor -includes: +parameters: + level: 1 + paths: + - %currentWorkingDirectory%/src + - %currentWorkingDirectory%/tests + - %currentWorkingDirectory%/examples + excludes_analyse: + - %currentWorkingDirectory%/vendor +includes: - .phpstan.ignoreErrors.neon \ No newline at end of file diff --git a/vendor/mollie/mollie-api-php/src/CompatibilityChecker.php b/vendor/mollie/mollie-api-php/src/CompatibilityChecker.php index ad46f92a2..ee00938e4 100644 --- a/vendor/mollie/mollie-api-php/src/CompatibilityChecker.php +++ b/vendor/mollie/mollie-api-php/src/CompatibilityChecker.php @@ -1,47 +1,47 @@ -satisfiesPhpVersion()) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\IncompatiblePlatform("The client requires PHP version >= " . self::MIN_PHP_VERSION . ", you have " . \PHP_VERSION . ".", \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\IncompatiblePlatform::INCOMPATIBLE_PHP_VERSION); - } - if (!$this->satisfiesJsonExtension()) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\IncompatiblePlatform("PHP extension json is not enabled. Please make sure to enable 'json' in your PHP configuration.", \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\IncompatiblePlatform::INCOMPATIBLE_JSON_EXTENSION); - } - } - /** - * @return bool - * @codeCoverageIgnore - */ - public function satisfiesPhpVersion() - { - return (bool) \version_compare(\PHP_VERSION, self::MIN_PHP_VERSION, ">="); - } - /** - * @return bool - * @codeCoverageIgnore - */ - public function satisfiesJsonExtension() - { - // Check by extension_loaded - if (\function_exists('extension_loaded') && \extension_loaded('json')) { - return \true; - } elseif (\function_exists('json_encode')) { - return \true; - } - return \false; - } -} +satisfiesPhpVersion()) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\IncompatiblePlatform("The client requires PHP version >= " . self::MIN_PHP_VERSION . ", you have " . \PHP_VERSION . ".", \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\IncompatiblePlatform::INCOMPATIBLE_PHP_VERSION); + } + if (!$this->satisfiesJsonExtension()) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\IncompatiblePlatform("PHP extension json is not enabled. Please make sure to enable 'json' in your PHP configuration.", \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\IncompatiblePlatform::INCOMPATIBLE_JSON_EXTENSION); + } + } + /** + * @return bool + * @codeCoverageIgnore + */ + public function satisfiesPhpVersion() + { + return (bool) \version_compare(\PHP_VERSION, self::MIN_PHP_VERSION, ">="); + } + /** + * @return bool + * @codeCoverageIgnore + */ + public function satisfiesJsonExtension() + { + // Check by extension_loaded + if (\function_exists('extension_loaded') && \extension_loaded('json')) { + return \true; + } elseif (\function_exists('json_encode')) { + return \true; + } + return \false; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/ChargebackEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/ChargebackEndpoint.php index c6e960f51..2f03f4078 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/ChargebackEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/ChargebackEndpoint.php @@ -1,46 +1,46 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return ChargebackCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ChargebackCollection($this->client, $count, $_links); - } - /** - * Retrieves a collection of Chargebacks from Mollie. - * - * @param string $from The first chargeback ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return ChargebackCollection - * @throws ApiException - */ - public function page($from = null, $limit = null, array $parameters = []) - { - return $this->rest_list($from, $limit, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return ChargebackCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ChargebackCollection($this->client, $count, $_links); + } + /** + * Retrieves a collection of Chargebacks from Mollie. + * + * @param string $from The first chargeback ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return ChargebackCollection + * @throws ApiException + */ + public function page($from = null, $limit = null, array $parameters = []) + { + return $this->rest_list($from, $limit, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/CollectionEndpointAbstract.php b/vendor/mollie/mollie-api-php/src/Endpoints/CollectionEndpointAbstract.php index 0b679bf0f..17a671011 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/CollectionEndpointAbstract.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/CollectionEndpointAbstract.php @@ -1,17 +1,17 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return CustomerCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\CustomerCollection($this->client, $count, $_links); - } - /** - * Creates a customer in Mollie. - * - * @param array $data An array containing details on the customer. - * @param array $filters - * - * @return Customer - * @throws ApiException - */ - public function create(array $data = [], array $filters = []) - { - return $this->rest_create($data, $filters); - } - /** - * Retrieve a single customer from Mollie. - * - * Will throw a ApiException if the customer id is invalid or the resource cannot be found. - * - * @param string $customerId - * @param array $parameters - * @return Customer - * @throws ApiException - */ - public function get($customerId, array $parameters = []) - { - return $this->rest_read($customerId, $parameters); - } - /** - * Deletes the given Customer. - * - * Will throw a ApiException if the customer id is invalid or the resource cannot be found. - * Returns with HTTP status No Content (204) if successful. - * - * @param string $customerId - * - * @param array $data - * @return null - * @throws ApiException - */ - public function delete($customerId, array $data = []) - { - return $this->rest_delete($customerId, $data); - } - /** - * Retrieves a collection of Customers from Mollie. - * - * @param string $from The first customer ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return CustomerCollection - * @throws ApiException - */ - public function page($from = null, $limit = null, array $parameters = []) - { - return $this->rest_list($from, $limit, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return CustomerCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\CustomerCollection($this->client, $count, $_links); + } + /** + * Creates a customer in Mollie. + * + * @param array $data An array containing details on the customer. + * @param array $filters + * + * @return Customer + * @throws ApiException + */ + public function create(array $data = [], array $filters = []) + { + return $this->rest_create($data, $filters); + } + /** + * Retrieve a single customer from Mollie. + * + * Will throw a ApiException if the customer id is invalid or the resource cannot be found. + * + * @param string $customerId + * @param array $parameters + * @return Customer + * @throws ApiException + */ + public function get($customerId, array $parameters = []) + { + return $this->rest_read($customerId, $parameters); + } + /** + * Deletes the given Customer. + * + * Will throw a ApiException if the customer id is invalid or the resource cannot be found. + * Returns with HTTP status No Content (204) if successful. + * + * @param string $customerId + * + * @param array $data + * @return null + * @throws ApiException + */ + public function delete($customerId, array $data = []) + { + return $this->rest_delete($customerId, $data); + } + /** + * Retrieves a collection of Customers from Mollie. + * + * @param string $from The first customer ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return CustomerCollection + * @throws ApiException + */ + public function page($from = null, $limit = null, array $parameters = []) + { + return $this->rest_list($from, $limit, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/CustomerPaymentsEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/CustomerPaymentsEndpoint.php index 35e1fcd2f..d4dbee589 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/CustomerPaymentsEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/CustomerPaymentsEndpoint.php @@ -1,88 +1,88 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return PaymentCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, $count, $_links); - } - /** - * Create a subscription for a Customer - * - * @param Customer $customer - * @param array $options - * @param array $filters - * - * @return Payment - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, array $options = [], array $filters = []) - { - return $this->createForId($customer->id, $options, $filters); - } - /** - * Create a subscription for a Customer ID - * - * @param string $customerId - * @param array $options - * @param array $filters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Payment - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createForId($customerId, array $options = [], array $filters = []) - { - $this->parentId = $customerId; - return parent::rest_create($options, $filters); - } - /** - * @param Customer $customer - * @param string $from The first resource ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return PaymentCollection - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function listFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $from = null, $limit = null, array $parameters = []) - { - return $this->listForId($customer->id, $from, $limit, $parameters); - } - /** - * @param string $customerId - * @param string $from The first resource ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\PaymentCollection - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function listForId($customerId, $from = null, $limit = null, array $parameters = []) - { - $this->parentId = $customerId; - return parent::rest_list($from, $limit, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return PaymentCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, $count, $_links); + } + /** + * Create a subscription for a Customer + * + * @param Customer $customer + * @param array $options + * @param array $filters + * + * @return Payment + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, array $options = [], array $filters = []) + { + return $this->createForId($customer->id, $options, $filters); + } + /** + * Create a subscription for a Customer ID + * + * @param string $customerId + * @param array $options + * @param array $filters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Payment + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createForId($customerId, array $options = [], array $filters = []) + { + $this->parentId = $customerId; + return parent::rest_create($options, $filters); + } + /** + * @param Customer $customer + * @param string $from The first resource ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return PaymentCollection + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function listFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $from = null, $limit = null, array $parameters = []) + { + return $this->listForId($customer->id, $from, $limit, $parameters); + } + /** + * @param string $customerId + * @param string $from The first resource ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\PaymentCollection + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function listForId($customerId, $from = null, $limit = null, array $parameters = []) + { + $this->parentId = $customerId; + return parent::rest_list($from, $limit, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/EndpointAbstract.php b/vendor/mollie/mollie-api-php/src/Endpoints/EndpointAbstract.php index 45730ccfa..581b7624f 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/EndpointAbstract.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/EndpointAbstract.php @@ -1,171 +1,171 @@ -client = $api; - } - /** - * @param array $filters - * @return string - */ - protected function buildQueryString(array $filters) - { - if (empty($filters)) { - return ""; - } - foreach ($filters as $key => $value) { - if ($value === \true) { - $filters[$key] = "true"; - } - if ($value === \false) { - $filters[$key] = "false"; - } - } - return "?" . \http_build_query($filters, "", "&"); - } - /** - * @param array $body - * @param array $filters - * @return BaseResource - * @throws ApiException - */ - protected function rest_create(array $body, array $filters) - { - $result = $this->client->performHttpCall(self::REST_CREATE, $this->getResourcePath() . $this->buildQueryString($filters), $this->parseRequestBody($body)); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, $this->getResourceObject()); - } - /** - * Retrieves a single object from the REST API. - * - * @param string $id Id of the object to retrieve. - * @param array $filters - * @return BaseResource - * @throws ApiException - */ - protected function rest_read($id, array $filters) - { - if (empty($id)) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid resource id."); - } - $id = \urlencode($id); - $result = $this->client->performHttpCall(self::REST_READ, "{$this->getResourcePath()}/{$id}" . $this->buildQueryString($filters)); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, $this->getResourceObject()); - } - /** - * Sends a DELETE request to a single Molle API object. - * - * @param string $id - * @param array $body - * - * @return BaseResource - * @throws ApiException - */ - protected function rest_delete($id, array $body = []) - { - if (empty($id)) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid resource id."); - } - $id = \urlencode($id); - $result = $this->client->performHttpCall(self::REST_DELETE, "{$this->getResourcePath()}/{$id}", $this->parseRequestBody($body)); - if ($result === null) { - return null; - } - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, $this->getResourceObject()); - } - /** - * Get a collection of objects from the REST API. - * - * @param string $from The first resource ID you want to include in your list. - * @param int $limit - * @param array $filters - * - * @return BaseCollection - * @throws ApiException - */ - protected function rest_list($from = null, $limit = null, array $filters = []) - { - $filters = \array_merge(["from" => $from, "limit" => $limit], $filters); - $apiPath = $this->getResourcePath() . $this->buildQueryString($filters); - $result = $this->client->performHttpCall(self::REST_LIST, $apiPath); - /** @var BaseCollection $collection */ - $collection = $this->getResourceCollectionObject($result->count, $result->_links); - foreach ($result->_embedded->{$collection->getCollectionResourceName()} as $dataResult) { - $collection[] = \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($dataResult, $this->getResourceObject()); - } - return $collection; - } - /** - * Get the object that is used by this API endpoint. Every API endpoint uses one type of object. - * - * @return BaseResource - */ - protected abstract function getResourceObject(); - /** - * @param string $resourcePath - */ - public function setResourcePath($resourcePath) - { - $this->resourcePath = \strtolower($resourcePath); - } - /** - * @return string - * @throws ApiException - */ - public function getResourcePath() - { - if (\strpos($this->resourcePath, "_") !== \false) { - list($parentResource, $childResource) = \explode("_", $this->resourcePath, 2); - if (empty($this->parentId)) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Subresource '{$this->resourcePath}' used without parent '{$parentResource}' ID."); - } - return "{$parentResource}/{$this->parentId}/{$childResource}"; - } - return $this->resourcePath; - } - /** - * @param array $body - * @return null|string - * @throws ApiException - */ - protected function parseRequestBody(array $body) - { - if (empty($body)) { - return null; - } - try { - $encoded = \_PhpScoper5ea00cc67502b\GuzzleHttp\json_encode($body); - } catch (\InvalidArgumentException $e) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Error encoding parameters into JSON: '" . $e->getMessage() . "'."); - } - return $encoded; - } -} +client = $api; + } + /** + * @param array $filters + * @return string + */ + protected function buildQueryString(array $filters) + { + if (empty($filters)) { + return ""; + } + foreach ($filters as $key => $value) { + if ($value === \true) { + $filters[$key] = "true"; + } + if ($value === \false) { + $filters[$key] = "false"; + } + } + return "?" . \http_build_query($filters, "", "&"); + } + /** + * @param array $body + * @param array $filters + * @return BaseResource + * @throws ApiException + */ + protected function rest_create(array $body, array $filters) + { + $result = $this->client->performHttpCall(self::REST_CREATE, $this->getResourcePath() . $this->buildQueryString($filters), $this->parseRequestBody($body)); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, $this->getResourceObject()); + } + /** + * Retrieves a single object from the REST API. + * + * @param string $id Id of the object to retrieve. + * @param array $filters + * @return BaseResource + * @throws ApiException + */ + protected function rest_read($id, array $filters) + { + if (empty($id)) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid resource id."); + } + $id = \urlencode($id); + $result = $this->client->performHttpCall(self::REST_READ, "{$this->getResourcePath()}/{$id}" . $this->buildQueryString($filters)); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, $this->getResourceObject()); + } + /** + * Sends a DELETE request to a single Molle API object. + * + * @param string $id + * @param array $body + * + * @return BaseResource + * @throws ApiException + */ + protected function rest_delete($id, array $body = []) + { + if (empty($id)) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid resource id."); + } + $id = \urlencode($id); + $result = $this->client->performHttpCall(self::REST_DELETE, "{$this->getResourcePath()}/{$id}", $this->parseRequestBody($body)); + if ($result === null) { + return null; + } + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, $this->getResourceObject()); + } + /** + * Get a collection of objects from the REST API. + * + * @param string $from The first resource ID you want to include in your list. + * @param int $limit + * @param array $filters + * + * @return BaseCollection + * @throws ApiException + */ + protected function rest_list($from = null, $limit = null, array $filters = []) + { + $filters = \array_merge(["from" => $from, "limit" => $limit], $filters); + $apiPath = $this->getResourcePath() . $this->buildQueryString($filters); + $result = $this->client->performHttpCall(self::REST_LIST, $apiPath); + /** @var BaseCollection $collection */ + $collection = $this->getResourceCollectionObject($result->count, $result->_links); + foreach ($result->_embedded->{$collection->getCollectionResourceName()} as $dataResult) { + $collection[] = \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($dataResult, $this->getResourceObject()); + } + return $collection; + } + /** + * Get the object that is used by this API endpoint. Every API endpoint uses one type of object. + * + * @return BaseResource + */ + protected abstract function getResourceObject(); + /** + * @param string $resourcePath + */ + public function setResourcePath($resourcePath) + { + $this->resourcePath = \strtolower($resourcePath); + } + /** + * @return string + * @throws ApiException + */ + public function getResourcePath() + { + if (\strpos($this->resourcePath, "_") !== \false) { + list($parentResource, $childResource) = \explode("_", $this->resourcePath, 2); + if (empty($this->parentId)) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Subresource '{$this->resourcePath}' used without parent '{$parentResource}' ID."); + } + return "{$parentResource}/{$this->parentId}/{$childResource}"; + } + return $this->resourcePath; + } + /** + * @param array $body + * @return null|string + * @throws ApiException + */ + protected function parseRequestBody(array $body) + { + if (empty($body)) { + return null; + } + try { + $encoded = \_PhpScoper5ea00cc67502b\GuzzleHttp\json_encode($body); + } catch (\InvalidArgumentException $e) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Error encoding parameters into JSON: '" . $e->getMessage() . "'."); + } + return $encoded; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/InvoiceEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/InvoiceEndpoint.php index 4212e29c6..83602eca8 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/InvoiceEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/InvoiceEndpoint.php @@ -1,72 +1,72 @@ -client); - } - /** - * Get the collection object that is used by this API. Every API uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return \Mollie\Api\Resources\BaseCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\InvoiceCollection($this->client, $count, $_links); - } - /** - * Retrieve an Invoice from Mollie. - * - * Will throw a ApiException if the invoice id is invalid or the resource cannot be found. - * - * @param string $invoiceId - * @param array $parameters - * - * @return Invoice - * @throws ApiException - */ - public function get($invoiceId, array $parameters = []) - { - return $this->rest_read($invoiceId, $parameters); - } - /** - * Retrieves a collection of Invoices from Mollie. - * - * @param string $from The first invoice ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return InvoiceCollection - * @throws ApiException - */ - public function page($from = null, $limit = null, array $parameters = []) - { - return $this->rest_list($from, $limit, $parameters); - } - /** - * This is a wrapper method for page - * - * @param array|null $parameters - * - * @return \Mollie\Api\Resources\BaseCollection - */ - public function all(array $parameters = []) - { - return $this->page(null, null, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API. Every API uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return \Mollie\Api\Resources\BaseCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\InvoiceCollection($this->client, $count, $_links); + } + /** + * Retrieve an Invoice from Mollie. + * + * Will throw a ApiException if the invoice id is invalid or the resource cannot be found. + * + * @param string $invoiceId + * @param array $parameters + * + * @return Invoice + * @throws ApiException + */ + public function get($invoiceId, array $parameters = []) + { + return $this->rest_read($invoiceId, $parameters); + } + /** + * Retrieves a collection of Invoices from Mollie. + * + * @param string $from The first invoice ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return InvoiceCollection + * @throws ApiException + */ + public function page($from = null, $limit = null, array $parameters = []) + { + return $this->rest_list($from, $limit, $parameters); + } + /** + * This is a wrapper method for page + * + * @param array|null $parameters + * + * @return \Mollie\Api\Resources\BaseCollection + */ + public function all(array $parameters = []) + { + return $this->page(null, null, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/MandateEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/MandateEndpoint.php index 8866863ff..4d74cca4e 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/MandateEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/MandateEndpoint.php @@ -1,135 +1,135 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return MandateCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\MandateCollection($this->client, $count, $_links); - } - /** - * @param Customer $customer - * @param array $options - * @param array $filters - * - * @return \Mollie\Api\Resources\Mandate - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, array $options = [], array $filters = []) - { - return $this->createForId($customer->id, $options, $filters); - } - /** - * @param string $customerId - * @param array $options - * @param array $filters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Mandate - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createForId($customerId, array $options = [], array $filters = []) - { - $this->parentId = $customerId; - return parent::rest_create($options, $filters); - } - /** - * @param Customer $customer - * @param string $mandateId - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Mandate - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $mandateId, array $parameters = []) - { - return $this->getForId($customer->id, $mandateId, $parameters); - } - /** - * @param string $customerId - * @param string $mandateId - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseResource - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function getForId($customerId, $mandateId, array $parameters = []) - { - $this->parentId = $customerId; - return parent::rest_read($mandateId, $parameters); - } - /** - * @param Customer $customer - * @param string $from The first resource ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\MandateCollection - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function listFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $from = null, $limit = null, array $parameters = []) - { - return $this->listForId($customer->id, $from, $limit, $parameters); - } - /** - * @param string $customerId - * @param null $from - * @param null $limit - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\MandateCollection - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function listForId($customerId, $from = null, $limit = null, array $parameters = []) - { - $this->parentId = $customerId; - return parent::rest_list($from, $limit, $parameters); - } - /** - * @param Customer $customer - * @param string $mandateId - * @param array $data - * - * @return null - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function revokeFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $mandateId, $data = []) - { - return $this->revokeForId($customer->id, $mandateId, $data); - } - /** - * @param string $customerId - * @param string $mandateId - * @param array $data - * - * @return null - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function revokeForId($customerId, $mandateId, $data = []) - { - $this->parentId = $customerId; - return parent::rest_delete($mandateId, $data); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return MandateCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\MandateCollection($this->client, $count, $_links); + } + /** + * @param Customer $customer + * @param array $options + * @param array $filters + * + * @return \Mollie\Api\Resources\Mandate + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, array $options = [], array $filters = []) + { + return $this->createForId($customer->id, $options, $filters); + } + /** + * @param string $customerId + * @param array $options + * @param array $filters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Mandate + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createForId($customerId, array $options = [], array $filters = []) + { + $this->parentId = $customerId; + return parent::rest_create($options, $filters); + } + /** + * @param Customer $customer + * @param string $mandateId + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Mandate + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $mandateId, array $parameters = []) + { + return $this->getForId($customer->id, $mandateId, $parameters); + } + /** + * @param string $customerId + * @param string $mandateId + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseResource + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function getForId($customerId, $mandateId, array $parameters = []) + { + $this->parentId = $customerId; + return parent::rest_read($mandateId, $parameters); + } + /** + * @param Customer $customer + * @param string $from The first resource ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\MandateCollection + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function listFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $from = null, $limit = null, array $parameters = []) + { + return $this->listForId($customer->id, $from, $limit, $parameters); + } + /** + * @param string $customerId + * @param null $from + * @param null $limit + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\MandateCollection + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function listForId($customerId, $from = null, $limit = null, array $parameters = []) + { + $this->parentId = $customerId; + return parent::rest_list($from, $limit, $parameters); + } + /** + * @param Customer $customer + * @param string $mandateId + * @param array $data + * + * @return null + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function revokeFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $mandateId, $data = []) + { + return $this->revokeForId($customer->id, $mandateId, $data); + } + /** + * @param string $customerId + * @param string $mandateId + * @param array $data + * + * @return null + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function revokeForId($customerId, $mandateId, $data = []) + { + $this->parentId = $customerId; + return parent::rest_delete($mandateId, $data); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/MethodEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/MethodEndpoint.php index effdd68bd..369a36687 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/MethodEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/MethodEndpoint.php @@ -1,88 +1,88 @@ -client); - } - /** - * Retrieve all active methods. In test mode, this includes pending methods. The results are not paginated. - * - * @deprecated Use allActive() instead - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\MethodCollection - * @throws ApiException - */ - public function all(array $parameters = []) - { - return $this->allActive($parameters); - } - /** - * Retrieve all active methods for the organization. In test mode, this includes pending methods. - * The results are not paginated. - * - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\MethodCollection - * @throws ApiException - */ - public function allActive(array $parameters = []) - { - return parent::rest_list(null, null, $parameters); - } - /** - * Retrieve all available methods for the organization, including activated and not yet activated methods. The - * results are not paginated. Make sure to include the profileId parameter if using an OAuth Access Token. - * - * @param array $parameters Query string parameters. - * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\MethodCollection - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function allAvailable(array $parameters = []) - { - $url = 'methods/all' . $this->buildQueryString($parameters); - $result = $this->client->performHttpCall('GET', $url); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createBaseResourceCollection($this->client, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Method::class, $result->_embedded->methods, $result->_links); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return MethodCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\MethodCollection($count, $_links); - } - /** - * Retrieve a payment method from Mollie. - * - * Will throw a ApiException if the method id is invalid or the resource cannot be found. - * - * @param string $methodId - * @param array $parameters - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Method - * @throws ApiException - */ - public function get($methodId, array $parameters = []) - { - if (empty($methodId)) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Method ID is empty."); - } - return parent::rest_read($methodId, $parameters); - } -} +client); + } + /** + * Retrieve all active methods. In test mode, this includes pending methods. The results are not paginated. + * + * @deprecated Use allActive() instead + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\MethodCollection + * @throws ApiException + */ + public function all(array $parameters = []) + { + return $this->allActive($parameters); + } + /** + * Retrieve all active methods for the organization. In test mode, this includes pending methods. + * The results are not paginated. + * + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\MethodCollection + * @throws ApiException + */ + public function allActive(array $parameters = []) + { + return parent::rest_list(null, null, $parameters); + } + /** + * Retrieve all available methods for the organization, including activated and not yet activated methods. The + * results are not paginated. Make sure to include the profileId parameter if using an OAuth Access Token. + * + * @param array $parameters Query string parameters. + * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\MethodCollection + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function allAvailable(array $parameters = []) + { + $url = 'methods/all' . $this->buildQueryString($parameters); + $result = $this->client->performHttpCall('GET', $url); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createBaseResourceCollection($this->client, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Method::class, $result->_embedded->methods, $result->_links); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return MethodCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\MethodCollection($count, $_links); + } + /** + * Retrieve a payment method from Mollie. + * + * Will throw a ApiException if the method id is invalid or the resource cannot be found. + * + * @param string $methodId + * @param array $parameters + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Method + * @throws ApiException + */ + public function get($methodId, array $parameters = []) + { + if (empty($methodId)) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Method ID is empty."); + } + return parent::rest_read($methodId, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/OnboardingEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/OnboardingEndpoint.php index 7597189a7..326af732f 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/OnboardingEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/OnboardingEndpoint.php @@ -1,61 +1,61 @@ -client); - } - /** - * Retrieve the organization's onboarding status from Mollie. - * - * Will throw a ApiException if the resource cannot be found. - * - * @return Onboarding - * @throws ApiException - */ - public function get() - { - return $this->rest_read('', []); - } - /** - * Submit data that will be prefilled in the merchant’s onboarding. - * Please note that the data you submit will only be processed when the onboarding status is needs-data. - * - * Information that the merchant has entered in their dashboard will not be overwritten. - * - * Will throw a ApiException if the resource cannot be found. - * - * @return void - * @throws ApiException - */ - public function submit(array $parameters = []) - { - return $this->rest_create($parameters, []); - } - protected function rest_read($id, array $filters) - { - $result = $this->client->performHttpCall(self::REST_READ, $this->getResourcePath() . $this->buildQueryString($filters)); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, $this->getResourceObject()); - } - protected function rest_create(array $body, array $filters) - { - $this->client->performHttpCall(self::REST_CREATE, $this->getResourcePath() . $this->buildQueryString($filters), $this->parseRequestBody($body)); - } -} +client); + } + /** + * Retrieve the organization's onboarding status from Mollie. + * + * Will throw a ApiException if the resource cannot be found. + * + * @return Onboarding + * @throws ApiException + */ + public function get() + { + return $this->rest_read('', []); + } + /** + * Submit data that will be prefilled in the merchant’s onboarding. + * Please note that the data you submit will only be processed when the onboarding status is needs-data. + * + * Information that the merchant has entered in their dashboard will not be overwritten. + * + * Will throw a ApiException if the resource cannot be found. + * + * @return void + * @throws ApiException + */ + public function submit(array $parameters = []) + { + return $this->rest_create($parameters, []); + } + protected function rest_read($id, array $filters) + { + $result = $this->client->performHttpCall(self::REST_READ, $this->getResourcePath() . $this->buildQueryString($filters)); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, $this->getResourceObject()); + } + protected function rest_create(array $body, array $filters) + { + $this->client->performHttpCall(self::REST_CREATE, $this->getResourcePath() . $this->buildQueryString($filters), $this->parseRequestBody($body)); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/OrderEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/OrderEndpoint.php index ac722d80f..d1ab765bd 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/OrderEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/OrderEndpoint.php @@ -1,102 +1,102 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API - * endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return OrderCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\OrderCollection($this->client, $count, $_links); - } - /** - * Creates a order in Mollie. - * - * @param array $data An array containing details on the order. - * @param array $filters - * - * @return Order - * @throws ApiException - */ - public function create(array $data = [], array $filters = []) - { - return $this->rest_create($data, $filters); - } - /** - * Retrieve a single order from Mollie. - * - * Will throw a ApiException if the order id is invalid or the resource cannot - * be found. - * - * @param string $paymentId - * @param array $parameters - * @return Order - * @throws ApiException - */ - public function get($orderId, array $parameters = []) - { - if (empty($orderId) || \strpos($orderId, self::RESOURCE_ID_PREFIX) !== 0) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid order ID: '{$orderId}'. An order ID should start with '" . self::RESOURCE_ID_PREFIX . "'."); - } - return parent::rest_read($orderId, $parameters); - } - /** - * Cancel the given Order. - * - * If the order was partially shipped, the status will be "completed" instead of - * "canceled". - * Will throw a ApiException if the order id is invalid or the resource cannot - * be found. - * Returns the canceled order with HTTP status 200. - * - * @param string $orderId - * - * @param array $parameters - * @return Order - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function cancel($orderId, $parameters = []) - { - return $this->rest_delete($orderId, $parameters); - } - /** - * Retrieves a collection of Orders from Mollie. - * - * @param string $from The first order ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return OrderCollection - * @throws ApiException - */ - public function page($from = null, $limit = null, array $parameters = []) - { - return $this->rest_list($from, $limit, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API + * endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return OrderCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\OrderCollection($this->client, $count, $_links); + } + /** + * Creates a order in Mollie. + * + * @param array $data An array containing details on the order. + * @param array $filters + * + * @return Order + * @throws ApiException + */ + public function create(array $data = [], array $filters = []) + { + return $this->rest_create($data, $filters); + } + /** + * Retrieve a single order from Mollie. + * + * Will throw a ApiException if the order id is invalid or the resource cannot + * be found. + * + * @param string $paymentId + * @param array $parameters + * @return Order + * @throws ApiException + */ + public function get($orderId, array $parameters = []) + { + if (empty($orderId) || \strpos($orderId, self::RESOURCE_ID_PREFIX) !== 0) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid order ID: '{$orderId}'. An order ID should start with '" . self::RESOURCE_ID_PREFIX . "'."); + } + return parent::rest_read($orderId, $parameters); + } + /** + * Cancel the given Order. + * + * If the order was partially shipped, the status will be "completed" instead of + * "canceled". + * Will throw a ApiException if the order id is invalid or the resource cannot + * be found. + * Returns the canceled order with HTTP status 200. + * + * @param string $orderId + * + * @param array $parameters + * @return Order + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function cancel($orderId, $parameters = []) + { + return $this->rest_delete($orderId, $parameters); + } + /** + * Retrieves a collection of Orders from Mollie. + * + * @param string $from The first order ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return OrderCollection + * @throws ApiException + */ + public function page($from = null, $limit = null, array $parameters = []) + { + return $this->rest_list($from, $limit, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/OrderLineEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/OrderLineEndpoint.php index 5276cdfa1..d873f18d4 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/OrderLineEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/OrderLineEndpoint.php @@ -1,77 +1,77 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API - * endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return OrderLineCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\OrderLineCollection($count, $_links); - } - /** - * Cancel lines for the provided order. - * The data array must contain a lines array. - * You can pass an empty lines array if you want to cancel all eligible lines. - * Returns null if successful. - * - * @param Order $order - * @param array $data - * - * @return null - * @throws ApiException - */ - public function cancelFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, array $data) - { - return $this->cancelForId($order->id, $data); - } - /** - * Cancel lines for the provided order id. - * The data array must contain a lines array. - * You can pass an empty lines array if you want to cancel all eligible lines. - * Returns null if successful. - * - * @param string $orderId - * @param array $data - * - * @return null - * @throws ApiException - */ - public function cancelForId($orderId, array $data) - { - if (!isset($data['lines']) || !\is_array($data['lines'])) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("A lines array is required."); - } - $this->parentId = $orderId; - $this->client->performHttpCall(self::REST_DELETE, "{$this->getResourcePath()}", $this->parseRequestBody($data)); - return null; - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API + * endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return OrderLineCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\OrderLineCollection($count, $_links); + } + /** + * Cancel lines for the provided order. + * The data array must contain a lines array. + * You can pass an empty lines array if you want to cancel all eligible lines. + * Returns null if successful. + * + * @param Order $order + * @param array $data + * + * @return null + * @throws ApiException + */ + public function cancelFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, array $data) + { + return $this->cancelForId($order->id, $data); + } + /** + * Cancel lines for the provided order id. + * The data array must contain a lines array. + * You can pass an empty lines array if you want to cancel all eligible lines. + * Returns null if successful. + * + * @param string $orderId + * @param array $data + * + * @return null + * @throws ApiException + */ + public function cancelForId($orderId, array $data) + { + if (!isset($data['lines']) || !\is_array($data['lines'])) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("A lines array is required."); + } + $this->parentId = $orderId; + $this->client->performHttpCall(self::REST_DELETE, "{$this->getResourcePath()}", $this->parseRequestBody($data)); + return null; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/OrderPaymentEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/OrderPaymentEndpoint.php index 7da02b24d..2dbdc0ee7 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/OrderPaymentEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/OrderPaymentEndpoint.php @@ -1,67 +1,67 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API - * endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return \Mollie\Api\Resources\PaymentCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, $count, $_links); - } - /** - * Creates a payment in Mollie for a specific order. - * - * @param \Mollie\Api\Resources\Order $order - * @param array $data An array containing details on the order payment. - * @param array $filters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Payment - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, array $data, array $filters = []) - { - return $this->createForId($order->id, $data, $filters); - } - /** - * Creates a payment in Mollie for a specific order ID. - * - * @param string $orderId - * @param array $data An array containing details on the order payment. - * @param array $filters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Payment - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createForId($orderId, array $data, array $filters = []) - { - $this->parentId = $orderId; - return $this->rest_create($data, $filters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API + * endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return \Mollie\Api\Resources\PaymentCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, $count, $_links); + } + /** + * Creates a payment in Mollie for a specific order. + * + * @param \Mollie\Api\Resources\Order $order + * @param array $data An array containing details on the order payment. + * @param array $filters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Payment + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, array $data, array $filters = []) + { + return $this->createForId($order->id, $data, $filters); + } + /** + * Creates a payment in Mollie for a specific order ID. + * + * @param string $orderId + * @param array $data An array containing details on the order payment. + * @param array $filters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Payment + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createForId($orderId, array $data, array $filters = []) + { + $this->parentId = $orderId; + return $this->rest_create($data, $filters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/OrderRefundEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/OrderRefundEndpoint.php index 1e6d806e6..dd95f0e63 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/OrderRefundEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/OrderRefundEndpoint.php @@ -1,63 +1,63 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return RefundCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, $count, $_links); - } - /** - * Refund some order lines. You can provide an empty array for the - * "lines" data to refund all eligible lines for this order. - * - * @param Order $order - * @param array $data - * @param array $filters - * - * @return Refund - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, array $data, array $filters = []) - { - return $this->createForId($order->id, $data, $filters); - } - /** - * Refund some order lines. You can provide an empty array for the - * "lines" data to refund all eligible lines for this order. - * - * @param string $orderId - * @param array $data - * @param array $filters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Refund - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createForId($orderId, array $data, array $filters = []) - { - $this->parentId = $orderId; - return parent::rest_create($data, $filters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return RefundCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, $count, $_links); + } + /** + * Refund some order lines. You can provide an empty array for the + * "lines" data to refund all eligible lines for this order. + * + * @param Order $order + * @param array $data + * @param array $filters + * + * @return Refund + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, array $data, array $filters = []) + { + return $this->createForId($order->id, $data, $filters); + } + /** + * Refund some order lines. You can provide an empty array for the + * "lines" data to refund all eligible lines for this order. + * + * @param string $orderId + * @param array $data + * @param array $filters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Refund + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createForId($orderId, array $data, array $filters = []) + { + $this->parentId = $orderId; + return parent::rest_create($data, $filters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/OrganizationEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/OrganizationEndpoint.php index 0f842cb04..3b1eadef4 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/OrganizationEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/OrganizationEndpoint.php @@ -1,59 +1,59 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return OrganizationCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\OrganizationCollection($this->client, $count, $_links); - } - /** - * Retrieve an organization from Mollie. - * - * Will throw a ApiException if the organization id is invalid or the resource cannot be found. - * - * @param string $organizationId - * @param array $parameters - * @return Method - * @throws ApiException - */ - public function get($organizationId, array $parameters = []) - { - if (empty($organizationId)) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Organization ID is empty."); - } - return parent::rest_read($organizationId, $parameters); - } - /** - * Retrieve the current organization from Mollie. - * - * @param array $parameters - * @return Method - * @throws ApiException - */ - public function current(array $parameters = []) - { - return parent::rest_read('me', $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return OrganizationCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\OrganizationCollection($this->client, $count, $_links); + } + /** + * Retrieve an organization from Mollie. + * + * Will throw a ApiException if the organization id is invalid or the resource cannot be found. + * + * @param string $organizationId + * @param array $parameters + * @return Method + * @throws ApiException + */ + public function get($organizationId, array $parameters = []) + { + if (empty($organizationId)) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Organization ID is empty."); + } + return parent::rest_read($organizationId, $parameters); + } + /** + * Retrieve the current organization from Mollie. + * + * @param array $parameters + * @return Method + * @throws ApiException + */ + public function current(array $parameters = []) + { + return parent::rest_read('me', $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/PaymentCaptureEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/PaymentCaptureEndpoint.php index fdfc66c1e..6a188e930 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/PaymentCaptureEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/PaymentCaptureEndpoint.php @@ -1,57 +1,57 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return \Mollie\Api\Resources\CaptureCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\CaptureCollection($this->client, $count, $_links); - } - /** - * @param Payment $payment - * @param string $captureId - * @param array $parameters - * - * @return Capture - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment $payment, $captureId, array $parameters = []) - { - return $this->getForId($payment->id, $captureId, $parameters); - } - /** - * @param string $paymentId - * @param string $captureId - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Capture - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function getForId($paymentId, $captureId, array $parameters = []) - { - $this->parentId = $paymentId; - return parent::rest_read($captureId, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return \Mollie\Api\Resources\CaptureCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\CaptureCollection($this->client, $count, $_links); + } + /** + * @param Payment $payment + * @param string $captureId + * @param array $parameters + * + * @return Capture + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment $payment, $captureId, array $parameters = []) + { + return $this->getForId($payment->id, $captureId, $parameters); + } + /** + * @param string $paymentId + * @param string $captureId + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Capture + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function getForId($paymentId, $captureId, array $parameters = []) + { + $this->parentId = $paymentId; + return parent::rest_read($captureId, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/PaymentChargebackEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/PaymentChargebackEndpoint.php index a543b76f6..d6c48c569 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/PaymentChargebackEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/PaymentChargebackEndpoint.php @@ -1,57 +1,57 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return ChargebackCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ChargebackCollection($this->client, $count, $_links); - } - /** - * @param Payment $payment - * @param string $chargebackId - * @param array $parameters - * - * @return Chargeback - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment $payment, $chargebackId, array $parameters = []) - { - return $this->getForId($payment->id, $chargebackId, $parameters); - } - /** - * @param string $paymentId - * @param string $chargebackId - * @param array $parameters - * - * @return Chargeback - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function getForId($paymentId, $chargebackId, array $parameters = []) - { - $this->parentId = $paymentId; - return parent::rest_read($chargebackId, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return ChargebackCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ChargebackCollection($this->client, $count, $_links); + } + /** + * @param Payment $payment + * @param string $chargebackId + * @param array $parameters + * + * @return Chargeback + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment $payment, $chargebackId, array $parameters = []) + { + return $this->getForId($payment->id, $chargebackId, $parameters); + } + /** + * @param string $paymentId + * @param string $chargebackId + * @param array $parameters + * + * @return Chargeback + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function getForId($paymentId, $chargebackId, array $parameters = []) + { + $this->parentId = $paymentId; + return parent::rest_read($chargebackId, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/PaymentEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/PaymentEndpoint.php index 0e7b2ae69..d2ca8bd05 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/PaymentEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/PaymentEndpoint.php @@ -1,134 +1,134 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return PaymentCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, $count, $_links); - } - /** - * Creates a payment in Mollie. - * - * @param array $data An array containing details on the payment. - * @param array $filters - * - * @return Payment - * @throws ApiException - */ - public function create(array $data = [], array $filters = []) - { - return $this->rest_create($data, $filters); - } - /** - * Retrieve a single payment from Mollie. - * - * Will throw a ApiException if the payment id is invalid or the resource cannot be found. - * - * @param string $paymentId - * @param array $parameters - * @return Payment - * @throws ApiException - */ - public function get($paymentId, array $parameters = []) - { - if (empty($paymentId) || \strpos($paymentId, self::RESOURCE_ID_PREFIX) !== 0) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid payment ID: '{$paymentId}'. A payment ID should start with '" . self::RESOURCE_ID_PREFIX . "'."); - } - return parent::rest_read($paymentId, $parameters); - } - /** - * Deletes the given Payment. - * - * Will throw a ApiException if the payment id is invalid or the resource cannot be found. - * Returns with HTTP status No Content (204) if successful. - * - * @param string $paymentId - * - * @param array $data - * @return Payment - * @throws ApiException - */ - public function delete($paymentId, array $data = []) - { - return $this->rest_delete($paymentId, $data); - } - /** - * Cancel the given Payment. This is just an alias of the 'delete' method. - * - * Will throw a ApiException if the payment id is invalid or the resource cannot be found. - * Returns with HTTP status No Content (204) if successful. - * - * @param string $paymentId - * - * @param array $data - * @return Payment - * @throws ApiException - */ - public function cancel($paymentId, array $data = []) - { - return $this->rest_delete($paymentId, $data); - } - /** - * Retrieves a collection of Payments from Mollie. - * - * @param string $from The first payment ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return PaymentCollection - * @throws ApiException - */ - public function page($from = null, $limit = null, array $parameters = []) - { - return $this->rest_list($from, $limit, $parameters); - } - /** - * Issue a refund for the given payment. - * - * The $data parameter may either be an array of endpoint parameters, a float value to - * initiate a partial refund, or empty to do a full refund. - * - * @param Payment $payment - * @param array|float|null $data - * - * @return Refund - * @throws ApiException - */ - public function refund(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment $payment, $data = []) - { - $resource = "{$this->getResourcePath()}/" . \urlencode($payment->id) . "/refunds"; - $body = null; - if (\count($data) > 0) { - $body = \json_encode($data); - } - $result = $this->client->performHttpCall(self::REST_CREATE, $resource, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund($this->client)); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return PaymentCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, $count, $_links); + } + /** + * Creates a payment in Mollie. + * + * @param array $data An array containing details on the payment. + * @param array $filters + * + * @return Payment + * @throws ApiException + */ + public function create(array $data = [], array $filters = []) + { + return $this->rest_create($data, $filters); + } + /** + * Retrieve a single payment from Mollie. + * + * Will throw a ApiException if the payment id is invalid or the resource cannot be found. + * + * @param string $paymentId + * @param array $parameters + * @return Payment + * @throws ApiException + */ + public function get($paymentId, array $parameters = []) + { + if (empty($paymentId) || \strpos($paymentId, self::RESOURCE_ID_PREFIX) !== 0) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid payment ID: '{$paymentId}'. A payment ID should start with '" . self::RESOURCE_ID_PREFIX . "'."); + } + return parent::rest_read($paymentId, $parameters); + } + /** + * Deletes the given Payment. + * + * Will throw a ApiException if the payment id is invalid or the resource cannot be found. + * Returns with HTTP status No Content (204) if successful. + * + * @param string $paymentId + * + * @param array $data + * @return Payment + * @throws ApiException + */ + public function delete($paymentId, array $data = []) + { + return $this->rest_delete($paymentId, $data); + } + /** + * Cancel the given Payment. This is just an alias of the 'delete' method. + * + * Will throw a ApiException if the payment id is invalid or the resource cannot be found. + * Returns with HTTP status No Content (204) if successful. + * + * @param string $paymentId + * + * @param array $data + * @return Payment + * @throws ApiException + */ + public function cancel($paymentId, array $data = []) + { + return $this->rest_delete($paymentId, $data); + } + /** + * Retrieves a collection of Payments from Mollie. + * + * @param string $from The first payment ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return PaymentCollection + * @throws ApiException + */ + public function page($from = null, $limit = null, array $parameters = []) + { + return $this->rest_list($from, $limit, $parameters); + } + /** + * Issue a refund for the given payment. + * + * The $data parameter may either be an array of endpoint parameters, a float value to + * initiate a partial refund, or empty to do a full refund. + * + * @param Payment $payment + * @param array|float|null $data + * + * @return Refund + * @throws ApiException + */ + public function refund(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment $payment, $data = []) + { + $resource = "{$this->getResourcePath()}/" . \urlencode($payment->id) . "/refunds"; + $body = null; + if (\count($data) > 0) { + $body = \json_encode($data); + } + $result = $this->client->performHttpCall(self::REST_CREATE, $resource, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund($this->client)); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/PaymentRefundEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/PaymentRefundEndpoint.php index 1c4e982e6..33cae94d1 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/PaymentRefundEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/PaymentRefundEndpoint.php @@ -1,57 +1,57 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return RefundCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, $count, $_links); - } - /** - * @param Payment $payment - * @param string $refundId - * @param array $parameters - * - * @return Refund - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment $payment, $refundId, array $parameters = []) - { - return $this->getForId($payment->id, $refundId, $parameters); - } - /** - * @param string $paymentId - * @param string $refundId - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Refund - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function getForId($paymentId, $refundId, array $parameters = []) - { - $this->parentId = $paymentId; - return parent::rest_read($refundId, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return RefundCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, $count, $_links); + } + /** + * @param Payment $payment + * @param string $refundId + * @param array $parameters + * + * @return Refund + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment $payment, $refundId, array $parameters = []) + { + return $this->getForId($payment->id, $refundId, $parameters); + } + /** + * @param string $paymentId + * @param string $refundId + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Refund + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function getForId($paymentId, $refundId, array $parameters = []) + { + $this->parentId = $paymentId; + return parent::rest_read($refundId, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/PermissionEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/PermissionEndpoint.php index 12c17e327..e57aa5612 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/PermissionEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/PermissionEndpoint.php @@ -1,60 +1,60 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API - * endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return PermissionCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PermissionCollection($count, $_links); - } - /** - * Retrieve a single Permission from Mollie. - * - * Will throw an ApiException if the permission id is invalid. - * - * @param string $permissionId - * @param array $parameters - * @return Permission - * @throws ApiException - */ - public function get($permissionId, array $parameters = []) - { - return $this->rest_read($permissionId, $parameters); - } - /** - * Retrieve all permissions. - * - * @param array $parameters - * - * @return PermissionCollection - * @throws ApiException - */ - public function all(array $parameters = []) - { - return parent::rest_list(null, null, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API + * endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return PermissionCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PermissionCollection($count, $_links); + } + /** + * Retrieve a single Permission from Mollie. + * + * Will throw an ApiException if the permission id is invalid. + * + * @param string $permissionId + * @param array $parameters + * @return Permission + * @throws ApiException + */ + public function get($permissionId, array $parameters = []) + { + return $this->rest_read($permissionId, $parameters); + } + /** + * Retrieve all permissions. + * + * @param array $parameters + * + * @return PermissionCollection + * @throws ApiException + */ + public function all(array $parameters = []) + { + return parent::rest_list(null, null, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/ProfileEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/ProfileEndpoint.php index 6c6178e76..70be7ff2f 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/ProfileEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/ProfileEndpoint.php @@ -1,108 +1,108 @@ -resourceClass($this->client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return ProfileCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ProfileCollection($this->client, $count, $_links); - } - /** - * Creates a Profile in Mollie. - * - * @param array $data An array containing details on the profile. - * @param array $filters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Profile - * @throws ApiException - */ - public function create(array $data = [], array $filters = []) - { - return $this->rest_create($data, $filters); - } - /** - * Retrieve a Profile from Mollie. - * - * Will throw an ApiException if the profile id is invalid or the resource cannot be found. - * - * @param string $profileId - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Profile - * @throws ApiException - */ - public function get($profileId, array $parameters = []) - { - if ($profileId === 'me') { - return $this->getCurrent($parameters); - } - return $this->rest_read($profileId, $parameters); - } - /** - * Retrieve the current Profile from Mollie. - * - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\CurrentProfile - * @throws ApiException - */ - public function getCurrent(array $parameters = []) - { - $this->resourceClass = \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\CurrentProfile::class; - return $this->rest_read('me', $parameters); - } - /** - * Delete a Profile from Mollie. - * - * Will throw a ApiException if the profile id is invalid or the resource cannot be found. - * Returns with HTTP status No Content (204) if successful. - * - * @param string $profileId - * - * @param array $data - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Profile - * @throws ApiException - */ - public function delete($profileId, array $data = []) - { - return $this->rest_delete($profileId, $data); - } - /** - * Retrieves a collection of Profiles from Mollie. - * - * @param string $from The first profile ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\ProfileCollection - * @throws ApiException - */ - public function page($from = null, $limit = null, array $parameters = []) - { - return $this->rest_list($from, $limit, $parameters); - } -} +resourceClass($this->client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return ProfileCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ProfileCollection($this->client, $count, $_links); + } + /** + * Creates a Profile in Mollie. + * + * @param array $data An array containing details on the profile. + * @param array $filters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Profile + * @throws ApiException + */ + public function create(array $data = [], array $filters = []) + { + return $this->rest_create($data, $filters); + } + /** + * Retrieve a Profile from Mollie. + * + * Will throw an ApiException if the profile id is invalid or the resource cannot be found. + * + * @param string $profileId + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Profile + * @throws ApiException + */ + public function get($profileId, array $parameters = []) + { + if ($profileId === 'me') { + return $this->getCurrent($parameters); + } + return $this->rest_read($profileId, $parameters); + } + /** + * Retrieve the current Profile from Mollie. + * + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\CurrentProfile + * @throws ApiException + */ + public function getCurrent(array $parameters = []) + { + $this->resourceClass = \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\CurrentProfile::class; + return $this->rest_read('me', $parameters); + } + /** + * Delete a Profile from Mollie. + * + * Will throw a ApiException if the profile id is invalid or the resource cannot be found. + * Returns with HTTP status No Content (204) if successful. + * + * @param string $profileId + * + * @param array $data + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Profile + * @throws ApiException + */ + public function delete($profileId, array $data = []) + { + return $this->rest_delete($profileId, $data); + } + /** + * Retrieves a collection of Profiles from Mollie. + * + * @param string $from The first profile ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\ProfileCollection + * @throws ApiException + */ + public function page($from = null, $limit = null, array $parameters = []) + { + return $this->rest_list($from, $limit, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/ProfileMethodEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/ProfileMethodEndpoint.php index e599debde..026009623 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/ProfileMethodEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/ProfileMethodEndpoint.php @@ -1,117 +1,117 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return MethodCollection() - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\MethodCollection($count, $_links); - } - /** - * Enable a method for the provided Profile ID. - * - * @param $profileId - * @param $methodId - * @param array $data - * @return \Mollie\Api\Resources\BaseResource - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createForId($profileId, $methodId, array $data = []) - { - $this->parentId = $profileId; - $resource = $this->getResourcePath() . '/' . \urlencode($methodId); - $body = null; - if (\count($data) > 0) { - $body = \json_encode($data); - } - $result = $this->client->performHttpCall(self::REST_CREATE, $resource, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Method($this->client)); - } - /** - * Enable a method for the provided Profile object. - * - * @param Profile $profile - * @param string $methodId - * @param array $data - * @return Method - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createFor($profile, $methodId, array $data = []) - { - return $this->createForId($profile->id, $methodId, $data); - } - /** - * Enable a method for the current profile. - * - * @param $methodId - * @param array $data - * @return \Mollie\Api\Resources\BaseResource - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createForCurrentProfile($methodId, array $data = []) - { - return $this->createForId('me', $methodId, $data); - } - /** - * Disable a method for the provided Profile ID. - * - * @param $profileId - * @param $methodId - * @param array $data - * @return \Mollie\Api\Resources\BaseResource - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function deleteForId($profileId, $methodId, array $data = []) - { - $this->parentId = $profileId; - return $this->rest_delete($methodId, $data); - } - /** - * Disable a method for the provided Profile object. - * - * @param $profile - * @param $methodId - * @param array $data - * @return \Mollie\Api\Resources\BaseResource - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function deleteFor($profile, $methodId, array $data = []) - { - return $this->deleteForId($profile->id, $methodId, $data); - } - /** - * Disable a method for the current profile. - * - * @param $methodId - * @param array $data - * @return \Mollie\Api\Resources\BaseResource - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function deleteForCurrentProfile($methodId, array $data) - { - return $this->deleteForId('me', $methodId, $data); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return MethodCollection() + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\MethodCollection($count, $_links); + } + /** + * Enable a method for the provided Profile ID. + * + * @param $profileId + * @param $methodId + * @param array $data + * @return \Mollie\Api\Resources\BaseResource + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createForId($profileId, $methodId, array $data = []) + { + $this->parentId = $profileId; + $resource = $this->getResourcePath() . '/' . \urlencode($methodId); + $body = null; + if (\count($data) > 0) { + $body = \json_encode($data); + } + $result = $this->client->performHttpCall(self::REST_CREATE, $resource, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Method($this->client)); + } + /** + * Enable a method for the provided Profile object. + * + * @param Profile $profile + * @param string $methodId + * @param array $data + * @return Method + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createFor($profile, $methodId, array $data = []) + { + return $this->createForId($profile->id, $methodId, $data); + } + /** + * Enable a method for the current profile. + * + * @param $methodId + * @param array $data + * @return \Mollie\Api\Resources\BaseResource + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createForCurrentProfile($methodId, array $data = []) + { + return $this->createForId('me', $methodId, $data); + } + /** + * Disable a method for the provided Profile ID. + * + * @param $profileId + * @param $methodId + * @param array $data + * @return \Mollie\Api\Resources\BaseResource + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function deleteForId($profileId, $methodId, array $data = []) + { + $this->parentId = $profileId; + return $this->rest_delete($methodId, $data); + } + /** + * Disable a method for the provided Profile object. + * + * @param $profile + * @param $methodId + * @param array $data + * @return \Mollie\Api\Resources\BaseResource + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function deleteFor($profile, $methodId, array $data = []) + { + return $this->deleteForId($profile->id, $methodId, $data); + } + /** + * Disable a method for the current profile. + * + * @param $methodId + * @param array $data + * @return \Mollie\Api\Resources\BaseResource + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function deleteForCurrentProfile($methodId, array $data) + { + return $this->deleteForId('me', $methodId, $data); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/RefundEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/RefundEndpoint.php index ba2d14a49..645f89ba7 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/RefundEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/RefundEndpoint.php @@ -1,46 +1,46 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return RefundCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, $count, $_links); - } - /** - * Retrieves a collection of Refunds from Mollie. - * - * @param string $from The first refund ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return RefundCollection - * @throws ApiException - */ - public function page($from = null, $limit = null, array $parameters = []) - { - return $this->rest_list($from, $limit, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return RefundCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, $count, $_links); + } + /** + * Retrieves a collection of Refunds from Mollie. + * + * @param string $from The first refund ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return RefundCollection + * @throws ApiException + */ + public function page($from = null, $limit = null, array $parameters = []) + { + return $this->rest_list($from, $limit, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/SettlementsEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/SettlementsEndpoint.php index a0ab48de2..f9a72ee89 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/SettlementsEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/SettlementsEndpoint.php @@ -1,80 +1,80 @@ -client); - } - /** - * Get the collection object that is used by this API. Every API uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return \Mollie\Api\Resources\BaseCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\SettlementCollection($this->client, $count, $_links); - } - /** - * Retrieve a single settlement from Mollie. - * - * Will throw a ApiException if the settlement id is invalid or the resource cannot be found. - * - * @param string $settlementId - * @param array $parameters - * @return Settlement - * @throws ApiException - */ - public function get($settlementId, array $parameters = []) - { - return parent::rest_read($settlementId, $parameters); - } - /** - * Retrieve the details of the current settlement that has not yet been paid out. - * - * @return Settlement - * @throws ApiException - */ - public function next() - { - return parent::rest_read("next", []); - } - /** - * Retrieve the details of the open balance of the organization. - * - * @return Settlement - * @throws ApiException - */ - public function open() - { - return parent::rest_read("open", []); - } - /** - * Retrieves a collection of Settlements from Mollie. - * - * @param string $from The first settlement ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return SettlementCollection - * @throws ApiException - */ - public function page($from = null, $limit = null, array $parameters = []) - { - return $this->rest_list($from, $limit, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API. Every API uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return \Mollie\Api\Resources\BaseCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\SettlementCollection($this->client, $count, $_links); + } + /** + * Retrieve a single settlement from Mollie. + * + * Will throw a ApiException if the settlement id is invalid or the resource cannot be found. + * + * @param string $settlementId + * @param array $parameters + * @return Settlement + * @throws ApiException + */ + public function get($settlementId, array $parameters = []) + { + return parent::rest_read($settlementId, $parameters); + } + /** + * Retrieve the details of the current settlement that has not yet been paid out. + * + * @return Settlement + * @throws ApiException + */ + public function next() + { + return parent::rest_read("next", []); + } + /** + * Retrieve the details of the open balance of the organization. + * + * @return Settlement + * @throws ApiException + */ + public function open() + { + return parent::rest_read("open", []); + } + /** + * Retrieves a collection of Settlements from Mollie. + * + * @param string $from The first settlement ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return SettlementCollection + * @throws ApiException + */ + public function page($from = null, $limit = null, array $parameters = []) + { + return $this->rest_list($from, $limit, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/ShipmentEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/ShipmentEndpoint.php index 55d9a8b00..2f655db70 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/ShipmentEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/ShipmentEndpoint.php @@ -1,124 +1,124 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API - * endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return ShipmentCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ShipmentCollection($count, $_links); - } - /** - * Create a shipment for some order lines. You can provide an empty array for the - * "lines" option to include all unshipped lines for this order. - * - * @param Order $order - * @param array $options - * @param array $filters - * - * @return Shipment - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, array $options = [], array $filters = []) - { - return $this->createForId($order->id, $options, $filters); - } - /** - * Create a shipment for some order lines. You can provide an empty array for the - * "lines" option to include all unshipped lines for this order. - * - * @param string $orderId - * @param array $options - * @param array $filters - * - * @return Shipment - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createForId($orderId, array $options = [], array $filters = []) - { - $this->parentId = $orderId; - return parent::rest_create($options, $filters); - } - /** - * Retrieve a single shipment and the order lines shipped by a shipment’s ID. - * - * @param Order $order - * @param string $shipmentId - * @param array $parameters - * - * @return Shipment - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, $shipmentId, array $parameters = []) - { - return $this->getForId($order->id, $shipmentId, $parameters); - } - /** - * Retrieve a single shipment and the order lines shipped by a shipment’s ID. - * - * @param string $orderId - * @param string $shipmentId - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Shipment - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function getForId($orderId, $shipmentId, array $parameters = []) - { - $this->parentId = $orderId; - return parent::rest_read($shipmentId, $parameters); - } - /** - * Return all shipments for the Order provided. - * - * @param Order $order - * @param array $parameters - * - * @return ShipmentCollection - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function listFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, array $parameters = []) - { - return $this->listForId($order->id, $parameters); - } - /** - * Return all shipments for the provided Order id. - * - * @param string $orderId - * @param array $parameters - * - * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\ShipmentCollection - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function listForId($orderId, array $parameters = []) - { - $this->parentId = $orderId; - return parent::rest_list(null, null, $parameters); - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API + * endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return ShipmentCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ShipmentCollection($count, $_links); + } + /** + * Create a shipment for some order lines. You can provide an empty array for the + * "lines" option to include all unshipped lines for this order. + * + * @param Order $order + * @param array $options + * @param array $filters + * + * @return Shipment + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, array $options = [], array $filters = []) + { + return $this->createForId($order->id, $options, $filters); + } + /** + * Create a shipment for some order lines. You can provide an empty array for the + * "lines" option to include all unshipped lines for this order. + * + * @param string $orderId + * @param array $options + * @param array $filters + * + * @return Shipment + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createForId($orderId, array $options = [], array $filters = []) + { + $this->parentId = $orderId; + return parent::rest_create($options, $filters); + } + /** + * Retrieve a single shipment and the order lines shipped by a shipment’s ID. + * + * @param Order $order + * @param string $shipmentId + * @param array $parameters + * + * @return Shipment + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, $shipmentId, array $parameters = []) + { + return $this->getForId($order->id, $shipmentId, $parameters); + } + /** + * Retrieve a single shipment and the order lines shipped by a shipment’s ID. + * + * @param string $orderId + * @param string $shipmentId + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Shipment + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function getForId($orderId, $shipmentId, array $parameters = []) + { + $this->parentId = $orderId; + return parent::rest_read($shipmentId, $parameters); + } + /** + * Return all shipments for the Order provided. + * + * @param Order $order + * @param array $parameters + * + * @return ShipmentCollection + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function listFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order $order, array $parameters = []) + { + return $this->listForId($order->id, $parameters); + } + /** + * Return all shipments for the provided Order id. + * + * @param string $orderId + * @param array $parameters + * + * @return \Mollie\Api\Resources\BaseCollection|\Mollie\Api\Resources\ShipmentCollection + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function listForId($orderId, array $parameters = []) + { + $this->parentId = $orderId; + return parent::rest_list(null, null, $parameters); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/SubscriptionEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/SubscriptionEndpoint.php index d396b2f4c..9a8001bc6 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/SubscriptionEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/SubscriptionEndpoint.php @@ -1,107 +1,107 @@ -client); - } - /** - * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. - * - * @param int $count - * @param \stdClass $_links - * - * @return SubscriptionCollection - */ - protected function getResourceCollectionObject($count, $_links) - { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\SubscriptionCollection($this->client, $count, $_links); - } - /** - * Create a subscription for a Customer - * - * @param Customer $customer - * @param array $options - * @param array $filters - * - * @return Subscription - */ - public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, array $options = [], array $filters = []) - { - $this->parentId = $customer->id; - return parent::rest_create($options, $filters); - } - /** - * @param Customer $customer - * @param string $subscriptionId - * @param array $parameters - * - * @return Subscription - */ - public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $subscriptionId, array $parameters = []) - { - $this->parentId = $customer->id; - return parent::rest_read($subscriptionId, $parameters); - } - /** - * @param Customer $customer - * @param string $from The first resource ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return SubscriptionCollection - */ - public function listFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $from = null, $limit = null, array $parameters = []) - { - $this->parentId = $customer->id; - return parent::rest_list($from, $limit, $parameters); - } - /** - * @param Customer $customer - * @param string $subscriptionId - * - * @param array $data - * @return null - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function cancelFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $subscriptionId, array $data = []) - { - $this->parentId = $customer->id; - return parent::rest_delete($subscriptionId, $data); - } - /** - * Retrieves a collection of Subscriptions from Mollie. - * - * @param string $from The first payment ID you want to include in your list. - * @param int $limit - * @param array $parameters - * - * @return SubscriptionCollection - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function page($from = null, $limit = null, array $parameters = []) - { - $filters = \array_merge(["from" => $from, "limit" => $limit], $parameters); - $apiPath = 'subscriptions' . $this->buildQueryString($filters); - $result = $this->client->performHttpCall(self::REST_LIST, $apiPath); - /** @var SubscriptionCollection $collection */ - $collection = $this->getResourceCollectionObject($result->count, $result->_links); - foreach ($result->_embedded->{$collection->getCollectionResourceName()} as $dataResult) { - $collection[] = \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($dataResult, $this->getResourceObject()); - } - return $collection; - } -} +client); + } + /** + * Get the collection object that is used by this API endpoint. Every API endpoint uses one type of collection object. + * + * @param int $count + * @param \stdClass $_links + * + * @return SubscriptionCollection + */ + protected function getResourceCollectionObject($count, $_links) + { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\SubscriptionCollection($this->client, $count, $_links); + } + /** + * Create a subscription for a Customer + * + * @param Customer $customer + * @param array $options + * @param array $filters + * + * @return Subscription + */ + public function createFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, array $options = [], array $filters = []) + { + $this->parentId = $customer->id; + return parent::rest_create($options, $filters); + } + /** + * @param Customer $customer + * @param string $subscriptionId + * @param array $parameters + * + * @return Subscription + */ + public function getFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $subscriptionId, array $parameters = []) + { + $this->parentId = $customer->id; + return parent::rest_read($subscriptionId, $parameters); + } + /** + * @param Customer $customer + * @param string $from The first resource ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return SubscriptionCollection + */ + public function listFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $from = null, $limit = null, array $parameters = []) + { + $this->parentId = $customer->id; + return parent::rest_list($from, $limit, $parameters); + } + /** + * @param Customer $customer + * @param string $subscriptionId + * + * @param array $data + * @return null + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function cancelFor(\_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer $customer, $subscriptionId, array $data = []) + { + $this->parentId = $customer->id; + return parent::rest_delete($subscriptionId, $data); + } + /** + * Retrieves a collection of Subscriptions from Mollie. + * + * @param string $from The first payment ID you want to include in your list. + * @param int $limit + * @param array $parameters + * + * @return SubscriptionCollection + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function page($from = null, $limit = null, array $parameters = []) + { + $filters = \array_merge(["from" => $from, "limit" => $limit], $parameters); + $apiPath = 'subscriptions' . $this->buildQueryString($filters); + $result = $this->client->performHttpCall(self::REST_LIST, $apiPath); + /** @var SubscriptionCollection $collection */ + $collection = $this->getResourceCollectionObject($result->count, $result->_links); + foreach ($result->_embedded->{$collection->getCollectionResourceName()} as $dataResult) { + $collection[] = \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($dataResult, $this->getResourceObject()); + } + return $collection; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/WalletEndpoint.php b/vendor/mollie/mollie-api-php/src/Endpoints/WalletEndpoint.php index 8b5e9dafb..c98b34c05 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/WalletEndpoint.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/WalletEndpoint.php @@ -1,23 +1,23 @@ -parseRequestBody(['domain' => $domain, 'validationUrl' => $validationUrl]); - $response = $this->client->performHttpCall(self::REST_CREATE, 'wallets/applepay/sessions', $body); - return \json_encode($response); - } -} +parseRequestBody(['domain' => $domain, 'validationUrl' => $validationUrl]); + $response = $this->client->performHttpCall(self::REST_CREATE, 'wallets/applepay/sessions', $body); + return \json_encode($response); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Endpoints/index.php b/vendor/mollie/mollie-api-php/src/Endpoints/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/src/Endpoints/index.php +++ b/vendor/mollie/mollie-api-php/src/Endpoints/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/src/Exceptions/ApiException.php b/vendor/mollie/mollie-api-php/src/Exceptions/ApiException.php index 396e65263..b380d1ac9 100644 --- a/vendor/mollie/mollie-api-php/src/Exceptions/ApiException.php +++ b/vendor/mollie/mollie-api-php/src/Exceptions/ApiException.php @@ -1,159 +1,159 @@ -field = (string) $field; - $message .= ". Field: {$this->field}"; - } - if (!empty($response)) { - $this->response = $response; - $object = static::parseResponseBody($this->response); - if (isset($object->_links)) { - foreach ($object->_links as $key => $value) { - $this->links[$key] = $value; - } - } - } - if ($this->hasLink('documentation')) { - $message .= ". Documentation: {$this->getDocumentationUrl()}"; - } - parent::__construct($message, $code, $previous); - } - /** - * @param \GuzzleHttp\Exception\RequestException $guzzleException - * @param \Throwable $previous - * @return \Mollie\Api\Exceptions\ApiException - * @throws \Mollie\Api\Exceptions\ApiException - */ - public static function createFromGuzzleException($guzzleException, \Throwable $previous = null) - { - // Not all Guzzle Exceptions implement hasResponse() / getResponse() - if (\method_exists($guzzleException, 'hasResponse') && \method_exists($guzzleException, 'getResponse')) { - if ($guzzleException->hasResponse()) { - return static::createFromResponse($guzzleException->getResponse()); - } - } - return new static($guzzleException->getMessage(), $guzzleException->getCode(), null, $previous); - } - /** - * @param \Psr\Http\Message\ResponseInterface $response - * @param \Throwable|null $previous - * @return \Mollie\Api\Exceptions\ApiException - * @throws \Mollie\Api\Exceptions\ApiException - */ - public static function createFromResponse($response, \Throwable $previous = null) - { - $object = static::parseResponseBody($response); - $field = null; - if (!empty($object->field)) { - $field = $object->field; - } - return new static("Error executing API call ({$object->status}: {$object->title}): {$object->detail}", $response->getStatusCode(), $field, $response, $previous); - } - /** - * @return string|null - */ - public function getField() - { - return $this->field; - } - /** - * @return string|null - */ - public function getDocumentationUrl() - { - return $this->getUrl('documentation'); - } - /** - * @return string|null - */ - public function getDashboardUrl() - { - return $this->getUrl('dashboard'); - } - /** - * @return Response|null - */ - public function getResponse() - { - return $this->response; - } - /** - * @return bool - */ - public function hasResponse() - { - return $this->response !== null; - } - /** - * @param $key - * @return bool - */ - public function hasLink($key) - { - return \array_key_exists($key, $this->links); - } - /** - * @param $key - * @return mixed|null - */ - public function getLink($key) - { - if ($this->hasLink($key)) { - return $this->links[$key]; - } - return null; - } - /** - * @param $key - * @return null - */ - public function getUrl($key) - { - if ($this->hasLink($key)) { - return $this->getLink($key)->href; - } - return null; - } - /** - * @param $response - * @return mixed - * @throws \Mollie\Api\Exceptions\ApiException - */ - protected static function parseResponseBody($response) - { - $body = (string) $response->getBody(); - $object = @\json_decode($body); - if (\json_last_error() !== \JSON_ERROR_NONE) { - throw new static("Unable to decode Mollie response: '{$body}'."); - } - return $object; - } -} +field = (string) $field; + $message .= ". Field: {$this->field}"; + } + if (!empty($response)) { + $this->response = $response; + $object = static::parseResponseBody($this->response); + if (isset($object->_links)) { + foreach ($object->_links as $key => $value) { + $this->links[$key] = $value; + } + } + } + if ($this->hasLink('documentation')) { + $message .= ". Documentation: {$this->getDocumentationUrl()}"; + } + parent::__construct($message, $code, $previous); + } + /** + * @param \GuzzleHttp\Exception\RequestException $guzzleException + * @param \Throwable $previous + * @return \Mollie\Api\Exceptions\ApiException + * @throws \Mollie\Api\Exceptions\ApiException + */ + public static function createFromGuzzleException($guzzleException, \Throwable $previous = null) + { + // Not all Guzzle Exceptions implement hasResponse() / getResponse() + if (\method_exists($guzzleException, 'hasResponse') && \method_exists($guzzleException, 'getResponse')) { + if ($guzzleException->hasResponse()) { + return static::createFromResponse($guzzleException->getResponse()); + } + } + return new static($guzzleException->getMessage(), $guzzleException->getCode(), null, $previous); + } + /** + * @param \Psr\Http\Message\ResponseInterface $response + * @param \Throwable|null $previous + * @return \Mollie\Api\Exceptions\ApiException + * @throws \Mollie\Api\Exceptions\ApiException + */ + public static function createFromResponse($response, \Throwable $previous = null) + { + $object = static::parseResponseBody($response); + $field = null; + if (!empty($object->field)) { + $field = $object->field; + } + return new static("Error executing API call ({$object->status}: {$object->title}): {$object->detail}", $response->getStatusCode(), $field, $response, $previous); + } + /** + * @return string|null + */ + public function getField() + { + return $this->field; + } + /** + * @return string|null + */ + public function getDocumentationUrl() + { + return $this->getUrl('documentation'); + } + /** + * @return string|null + */ + public function getDashboardUrl() + { + return $this->getUrl('dashboard'); + } + /** + * @return Response|null + */ + public function getResponse() + { + return $this->response; + } + /** + * @return bool + */ + public function hasResponse() + { + return $this->response !== null; + } + /** + * @param $key + * @return bool + */ + public function hasLink($key) + { + return \array_key_exists($key, $this->links); + } + /** + * @param $key + * @return mixed|null + */ + public function getLink($key) + { + if ($this->hasLink($key)) { + return $this->links[$key]; + } + return null; + } + /** + * @param $key + * @return null + */ + public function getUrl($key) + { + if ($this->hasLink($key)) { + return $this->getLink($key)->href; + } + return null; + } + /** + * @param $response + * @return mixed + * @throws \Mollie\Api\Exceptions\ApiException + */ + protected static function parseResponseBody($response) + { + $body = (string) $response->getBody(); + $object = @\json_decode($body); + if (\json_last_error() !== \JSON_ERROR_NONE) { + throw new static("Unable to decode Mollie response: '{$body}'."); + } + return $object; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Exceptions/IncompatiblePlatform.php b/vendor/mollie/mollie-api-php/src/Exceptions/IncompatiblePlatform.php index 485e0e9a7..b9c7cb161 100644 --- a/vendor/mollie/mollie-api-php/src/Exceptions/IncompatiblePlatform.php +++ b/vendor/mollie/mollie-api-php/src/Exceptions/IncompatiblePlatform.php @@ -1,11 +1,11 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/src/MollieApiClient.php b/vendor/mollie/mollie-api-php/src/MollieApiClient.php index 4e1f86229..47d34ab98 100644 --- a/vendor/mollie/mollie-api-php/src/MollieApiClient.php +++ b/vendor/mollie/mollie-api-php/src/MollieApiClient.php @@ -1,451 +1,451 @@ -httpClient = $httpClient ? $httpClient : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Client([\_PhpScoper5ea00cc67502b\GuzzleHttp\RequestOptions::VERIFY => \_PhpScoper5ea00cc67502b\Composer\CaBundle\CaBundle::getBundledCaBundlePath(), \_PhpScoper5ea00cc67502b\GuzzleHttp\RequestOptions::TIMEOUT => self::TIMEOUT]); - $compatibilityChecker = new \_PhpScoper5ea00cc67502b\Mollie\Api\CompatibilityChecker(); - $compatibilityChecker->checkCompatibility(); - $this->initializeEndpoints(); - $this->addVersionString("Mollie/" . self::CLIENT_VERSION); - $this->addVersionString("PHP/" . \phpversion()); - $this->addVersionString("Guzzle/" . \_PhpScoper5ea00cc67502b\GuzzleHttp\ClientInterface::VERSION); - } - public function initializeEndpoints() - { - $this->payments = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\PaymentEndpoint($this); - $this->methods = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\MethodEndpoint($this); - $this->profileMethods = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\ProfileMethodEndpoint($this); - $this->customers = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\CustomerEndpoint($this); - $this->settlements = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\SettlementsEndpoint($this); - $this->subscriptions = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\SubscriptionEndpoint($this); - $this->customerPayments = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\CustomerPaymentsEndpoint($this); - $this->mandates = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\MandateEndpoint($this); - $this->invoices = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\InvoiceEndpoint($this); - $this->permissions = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\PermissionEndpoint($this); - $this->profiles = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\ProfileEndpoint($this); - $this->onboarding = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OnboardingEndpoint($this); - $this->organizations = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrganizationEndpoint($this); - $this->orders = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderEndpoint($this); - $this->orderLines = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderLineEndpoint($this); - $this->orderPayments = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderPaymentEndpoint($this); - $this->orderRefunds = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderRefundEndpoint($this); - $this->shipments = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\ShipmentEndpoint($this); - $this->refunds = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\RefundEndpoint($this); - $this->paymentRefunds = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\PaymentRefundEndpoint($this); - $this->paymentCaptures = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\PaymentCaptureEndpoint($this); - $this->chargebacks = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\ChargebackEndpoint($this); - $this->paymentChargebacks = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\PaymentChargebackEndpoint($this); - $this->wallets = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\WalletEndpoint($this); - } - /** - * @param string $url - * - * @return MollieApiClient - */ - public function setApiEndpoint($url) - { - $this->apiEndpoint = \rtrim(\trim($url), '/'); - return $this; - } - /** - * @return string - */ - public function getApiEndpoint() - { - return $this->apiEndpoint; - } - /** - * @param string $apiKey The Mollie API key, starting with 'test_' or 'live_' - * - * @return MollieApiClient - * @throws ApiException - */ - public function setApiKey($apiKey) - { - $apiKey = \trim($apiKey); - if (!\preg_match('/^(live|test)_\\w{30,}$/', $apiKey)) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid API key: '{$apiKey}'. An API key must start with 'test_' or 'live_' and must be at least 30 characters long."); - } - $this->apiKey = $apiKey; - $this->oauthAccess = \false; - return $this; - } - /** - * @param string $accessToken OAuth access token, starting with 'access_' - * - * @return MollieApiClient - * @throws ApiException - */ - public function setAccessToken($accessToken) - { - $accessToken = \trim($accessToken); - if (!\preg_match('/^access_\\w+$/', $accessToken)) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid OAuth access token: '{$accessToken}'. An access token must start with 'access_'."); - } - $this->apiKey = $accessToken; - $this->oauthAccess = \true; - return $this; - } - /** - * Returns null if no API key has been set yet. - * - * @return bool|null - */ - public function usesOAuth() - { - return $this->oauthAccess; - } - /** - * @param string $versionString - * - * @return MollieApiClient - */ - public function addVersionString($versionString) - { - $this->versionStrings[] = \str_replace([" ", "\t", "\n", "\r"], '-', $versionString); - return $this; - } - /** - * Perform an http call. This method is used by the resource specific classes. Please use the $payments property to - * perform operations on payments. - * - * @param string $httpMethod - * @param string $apiMethod - * @param string|null|resource|StreamInterface $httpBody - * - * @return \stdClass - * @throws ApiException - * - * @codeCoverageIgnore - */ - public function performHttpCall($httpMethod, $apiMethod, $httpBody = null) - { - $url = $this->apiEndpoint . "/" . self::API_VERSION . "/" . $apiMethod; - return $this->performHttpCallToFullUrl($httpMethod, $url, $httpBody); - } - /** - * Perform an http call to a full url. This method is used by the resource specific classes. - * - * @see $payments - * @see $isuers - * - * @param string $httpMethod - * @param string $url - * @param string|null|resource|StreamInterface $httpBody - * - * @return \stdClass|null - * @throws ApiException - * - * @codeCoverageIgnore - */ - public function performHttpCallToFullUrl($httpMethod, $url, $httpBody = null) - { - if (empty($this->apiKey)) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("You have not set an API key or OAuth access token. Please use setApiKey() to set the API key."); - } - $userAgent = \implode(' ', $this->versionStrings); - if ($this->usesOAuth()) { - $userAgent .= " OAuth/2.0"; - } - $headers = ['Accept' => "application/json", 'Authorization' => "Bearer {$this->apiKey}", 'User-Agent' => $userAgent]; - if (\function_exists("php_uname")) { - $headers['X-Mollie-Client-Info'] = \php_uname(); - } - $request = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Request($httpMethod, $url, $headers, $httpBody); - try { - $response = $this->httpClient->send($request, ['http_errors' => \false]); - } catch (\_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\GuzzleException $e) { - throw \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException::createFromGuzzleException($e); - } - if (!$response) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Did not receive API response."); - } - return $this->parseResponseBody($response); - } - /** - * Parse the PSR-7 Response body - * - * @param ResponseInterface $response - * @return \stdClass|null - * @throws ApiException - */ - private function parseResponseBody(\_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) - { - $body = (string) $response->getBody(); - if (empty($body)) { - if ($response->getStatusCode() === self::HTTP_NO_CONTENT) { - return null; - } - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("No response body found."); - } - $object = @\json_decode($body); - if (\json_last_error() !== \JSON_ERROR_NONE) { - throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Unable to decode Mollie response: '{$body}'."); - } - if ($response->getStatusCode() >= 400) { - throw \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException::createFromResponse($response); - } - return $object; - } - /** - * Serialization can be used for caching. Of course doing so can be dangerous but some like to live dangerously. - * - * \serialize() should be called on the collections or object you want to cache. - * - * We don't need any property that can be set by the constructor, only properties that are set by setters. - * - * Note that the API key is not serialized, so you need to set the key again after unserializing if you want to do - * more API calls. - * - * @deprecated - * @return string[] - */ - public function __sleep() - { - return ["apiEndpoint"]; - } - /** - * When unserializing a collection or a resource, this class should restore itself. - * - * Note that if you use a custom GuzzleClient, this client is lost. You can't re set the Client, so you should - * probably not use this feature. - * - * @throws IncompatiblePlatform If suddenly unserialized on an incompatible platform. - */ - public function __wakeup() - { - $this->__construct(); - } -} +httpClient = $httpClient ? $httpClient : new \_PhpScoper5ea00cc67502b\GuzzleHttp\Client([\_PhpScoper5ea00cc67502b\GuzzleHttp\RequestOptions::VERIFY => \_PhpScoper5ea00cc67502b\Composer\CaBundle\CaBundle::getBundledCaBundlePath(), \_PhpScoper5ea00cc67502b\GuzzleHttp\RequestOptions::TIMEOUT => self::TIMEOUT]); + $compatibilityChecker = new \_PhpScoper5ea00cc67502b\Mollie\Api\CompatibilityChecker(); + $compatibilityChecker->checkCompatibility(); + $this->initializeEndpoints(); + $this->addVersionString("Mollie/" . self::CLIENT_VERSION); + $this->addVersionString("PHP/" . \phpversion()); + $this->addVersionString("Guzzle/" . \_PhpScoper5ea00cc67502b\GuzzleHttp\ClientInterface::VERSION); + } + public function initializeEndpoints() + { + $this->payments = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\PaymentEndpoint($this); + $this->methods = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\MethodEndpoint($this); + $this->profileMethods = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\ProfileMethodEndpoint($this); + $this->customers = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\CustomerEndpoint($this); + $this->settlements = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\SettlementsEndpoint($this); + $this->subscriptions = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\SubscriptionEndpoint($this); + $this->customerPayments = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\CustomerPaymentsEndpoint($this); + $this->mandates = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\MandateEndpoint($this); + $this->invoices = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\InvoiceEndpoint($this); + $this->permissions = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\PermissionEndpoint($this); + $this->profiles = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\ProfileEndpoint($this); + $this->onboarding = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OnboardingEndpoint($this); + $this->organizations = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrganizationEndpoint($this); + $this->orders = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderEndpoint($this); + $this->orderLines = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderLineEndpoint($this); + $this->orderPayments = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderPaymentEndpoint($this); + $this->orderRefunds = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\OrderRefundEndpoint($this); + $this->shipments = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\ShipmentEndpoint($this); + $this->refunds = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\RefundEndpoint($this); + $this->paymentRefunds = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\PaymentRefundEndpoint($this); + $this->paymentCaptures = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\PaymentCaptureEndpoint($this); + $this->chargebacks = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\ChargebackEndpoint($this); + $this->paymentChargebacks = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\PaymentChargebackEndpoint($this); + $this->wallets = new \_PhpScoper5ea00cc67502b\Mollie\Api\Endpoints\WalletEndpoint($this); + } + /** + * @param string $url + * + * @return MollieApiClient + */ + public function setApiEndpoint($url) + { + $this->apiEndpoint = \rtrim(\trim($url), '/'); + return $this; + } + /** + * @return string + */ + public function getApiEndpoint() + { + return $this->apiEndpoint; + } + /** + * @param string $apiKey The Mollie API key, starting with 'test_' or 'live_' + * + * @return MollieApiClient + * @throws ApiException + */ + public function setApiKey($apiKey) + { + $apiKey = \trim($apiKey); + if (!\preg_match('/^(live|test)_\\w{30,}$/', $apiKey)) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid API key: '{$apiKey}'. An API key must start with 'test_' or 'live_' and must be at least 30 characters long."); + } + $this->apiKey = $apiKey; + $this->oauthAccess = \false; + return $this; + } + /** + * @param string $accessToken OAuth access token, starting with 'access_' + * + * @return MollieApiClient + * @throws ApiException + */ + public function setAccessToken($accessToken) + { + $accessToken = \trim($accessToken); + if (!\preg_match('/^access_\\w+$/', $accessToken)) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Invalid OAuth access token: '{$accessToken}'. An access token must start with 'access_'."); + } + $this->apiKey = $accessToken; + $this->oauthAccess = \true; + return $this; + } + /** + * Returns null if no API key has been set yet. + * + * @return bool|null + */ + public function usesOAuth() + { + return $this->oauthAccess; + } + /** + * @param string $versionString + * + * @return MollieApiClient + */ + public function addVersionString($versionString) + { + $this->versionStrings[] = \str_replace([" ", "\t", "\n", "\r"], '-', $versionString); + return $this; + } + /** + * Perform an http call. This method is used by the resource specific classes. Please use the $payments property to + * perform operations on payments. + * + * @param string $httpMethod + * @param string $apiMethod + * @param string|null|resource|StreamInterface $httpBody + * + * @return \stdClass + * @throws ApiException + * + * @codeCoverageIgnore + */ + public function performHttpCall($httpMethod, $apiMethod, $httpBody = null) + { + $url = $this->apiEndpoint . "/" . self::API_VERSION . "/" . $apiMethod; + return $this->performHttpCallToFullUrl($httpMethod, $url, $httpBody); + } + /** + * Perform an http call to a full url. This method is used by the resource specific classes. + * + * @see $payments + * @see $isuers + * + * @param string $httpMethod + * @param string $url + * @param string|null|resource|StreamInterface $httpBody + * + * @return \stdClass|null + * @throws ApiException + * + * @codeCoverageIgnore + */ + public function performHttpCallToFullUrl($httpMethod, $url, $httpBody = null) + { + if (empty($this->apiKey)) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("You have not set an API key or OAuth access token. Please use setApiKey() to set the API key."); + } + $userAgent = \implode(' ', $this->versionStrings); + if ($this->usesOAuth()) { + $userAgent .= " OAuth/2.0"; + } + $headers = ['Accept' => "application/json", 'Authorization' => "Bearer {$this->apiKey}", 'User-Agent' => $userAgent]; + if (\function_exists("php_uname")) { + $headers['X-Mollie-Client-Info'] = \php_uname(); + } + $request = new \_PhpScoper5ea00cc67502b\GuzzleHttp\Psr7\Request($httpMethod, $url, $headers, $httpBody); + try { + $response = $this->httpClient->send($request, ['http_errors' => \false]); + } catch (\_PhpScoper5ea00cc67502b\GuzzleHttp\Exception\GuzzleException $e) { + throw \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException::createFromGuzzleException($e); + } + if (!$response) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Did not receive API response."); + } + return $this->parseResponseBody($response); + } + /** + * Parse the PSR-7 Response body + * + * @param ResponseInterface $response + * @return \stdClass|null + * @throws ApiException + */ + private function parseResponseBody(\_PhpScoper5ea00cc67502b\Psr\Http\Message\ResponseInterface $response) + { + $body = (string) $response->getBody(); + if (empty($body)) { + if ($response->getStatusCode() === self::HTTP_NO_CONTENT) { + return null; + } + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("No response body found."); + } + $object = @\json_decode($body); + if (\json_last_error() !== \JSON_ERROR_NONE) { + throw new \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException("Unable to decode Mollie response: '{$body}'."); + } + if ($response->getStatusCode() >= 400) { + throw \_PhpScoper5ea00cc67502b\Mollie\Api\Exceptions\ApiException::createFromResponse($response); + } + return $object; + } + /** + * Serialization can be used for caching. Of course doing so can be dangerous but some like to live dangerously. + * + * \serialize() should be called on the collections or object you want to cache. + * + * We don't need any property that can be set by the constructor, only properties that are set by setters. + * + * Note that the API key is not serialized, so you need to set the key again after unserializing if you want to do + * more API calls. + * + * @deprecated + * @return string[] + */ + public function __sleep() + { + return ["apiEndpoint"]; + } + /** + * When unserializing a collection or a resource, this class should restore itself. + * + * Note that if you use a custom GuzzleClient, this client is lost. You can't re set the Client, so you should + * probably not use this feature. + * + * @throws IncompatiblePlatform If suddenly unserialized on an incompatible platform. + */ + public function __wakeup() + { + $this->__construct(); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/BaseCollection.php b/vendor/mollie/mollie-api-php/src/Resources/BaseCollection.php index c3b02382d..d1697a8f1 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/BaseCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/BaseCollection.php @@ -1,31 +1,31 @@ -count = $count; - $this->_links = $_links; - parent::__construct(); - } - /** - * @return string|null - */ - public abstract function getCollectionResourceName(); -} +count = $count; + $this->_links = $_links; + parent::__construct(); + } + /** + * @return string|null + */ + public abstract function getCollectionResourceName(); +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/BaseResource.php b/vendor/mollie/mollie-api-php/src/Resources/BaseResource.php index 90486d66c..b32782559 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/BaseResource.php +++ b/vendor/mollie/mollie-api-php/src/Resources/BaseResource.php @@ -1,19 +1,19 @@ -client = $client; - } -} +client = $client; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Capture.php b/vendor/mollie/mollie-api-php/src/Resources/Capture.php index a130859e3..bfe104eae 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Capture.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Capture.php @@ -1,61 +1,61 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Chargeback.php b/vendor/mollie/mollie-api-php/src/Resources/Chargeback.php index 466e78b80..393b07364 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Chargeback.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Chargeback.php @@ -1,48 +1,48 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/CurrentProfile.php b/vendor/mollie/mollie-api-php/src/Resources/CurrentProfile.php index 7119c2583..6ee32b612 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/CurrentProfile.php +++ b/vendor/mollie/mollie-api-php/src/Resources/CurrentProfile.php @@ -1,32 +1,32 @@ -client->profileMethods->createForCurrentProfile($methodId, $data); - } - /** - * Disable a payment method for this profile. - * - * @param string $methodId - * @param array $data - * @return Method - * @throws ApiException - */ - public function disableMethod($methodId, array $data = []) - { - return $this->client->profileMethods->deleteForCurrentProfile($methodId, $data); - } -} +client->profileMethods->createForCurrentProfile($methodId, $data); + } + /** + * Disable a payment method for this profile. + * + * @param string $methodId + * @param array $data + * @return Method + * @throws ApiException + */ + public function disableMethod($methodId, array $data = []) + { + return $this->client->profileMethods->deleteForCurrentProfile($methodId, $data); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/CursorCollection.php b/vendor/mollie/mollie-api-php/src/Resources/CursorCollection.php index d30700b3c..a0fbf5d0e 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/CursorCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/CursorCollection.php @@ -1,80 +1,80 @@ -client = $client; - } - /** - * @return BaseResource - */ - protected abstract function createResourceObject(); - /** - * Return the next set of resources when available - * - * @return CursorCollection|null - * @throws \Mollie\Api\Exceptions\ApiException - */ - public final function next() - { - if (!$this->hasNext()) { - return null; - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->next->href); - $collection = new static($this->client, $result->count, $result->_links); - foreach ($result->_embedded->{$collection->getCollectionResourceName()} as $dataResult) { - $collection[] = \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($dataResult, $this->createResourceObject()); - } - return $collection; - } - /** - * Return the previous set of resources when available - * - * @return CursorCollection|null - * @throws \Mollie\Api\Exceptions\ApiException - */ - public final function previous() - { - if (!$this->hasPrevious()) { - return null; - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->previous->href); - $collection = new static($this->client, $result->count, $result->_links); - foreach ($result->_embedded->{$collection->getCollectionResourceName()} as $dataResult) { - $collection[] = \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($dataResult, $this->createResourceObject()); - } - return $collection; - } - /** - * Determine whether the collection has a next page available. - * - * @return bool - */ - public function hasNext() - { - return isset($this->_links->next->href); - } - /** - * Determine whether the collection has a previous page available. - * - * @return bool - */ - public function hasPrevious() - { - return isset($this->_links->previous->href); - } -} +client = $client; + } + /** + * @return BaseResource + */ + protected abstract function createResourceObject(); + /** + * Return the next set of resources when available + * + * @return CursorCollection|null + * @throws \Mollie\Api\Exceptions\ApiException + */ + public final function next() + { + if (!$this->hasNext()) { + return null; + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->next->href); + $collection = new static($this->client, $result->count, $result->_links); + foreach ($result->_embedded->{$collection->getCollectionResourceName()} as $dataResult) { + $collection[] = \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($dataResult, $this->createResourceObject()); + } + return $collection; + } + /** + * Return the previous set of resources when available + * + * @return CursorCollection|null + * @throws \Mollie\Api\Exceptions\ApiException + */ + public final function previous() + { + if (!$this->hasPrevious()) { + return null; + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->previous->href); + $collection = new static($this->client, $result->count, $result->_links); + foreach ($result->_embedded->{$collection->getCollectionResourceName()} as $dataResult) { + $collection[] = \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($dataResult, $this->createResourceObject()); + } + return $collection; + } + /** + * Determine whether the collection has a next page available. + * + * @return bool + */ + public function hasNext() + { + return isset($this->_links->next->href); + } + /** + * Determine whether the collection has a previous page available. + * + * @return bool + */ + public function hasPrevious() + { + return isset($this->_links->previous->href); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Customer.php b/vendor/mollie/mollie-api-php/src/Resources/Customer.php index b0d465dc9..1438ba7fb 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Customer.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Customer.php @@ -1,212 +1,212 @@ -_links->self->href)) { - return $this; - } - $body = \json_encode(array("name" => $this->name, "email" => $this->email, "locale" => $this->locale, "metadata" => $this->metadata)); - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer($this->client)); - } - /** - * @param array $options - * @param array $filters - * - * @return Payment - */ - public function createPayment(array $options = [], array $filters = []) - { - return $this->client->customerPayments->createFor($this, $this->withPresetOptions($options), $filters); - } - /** - * Get all payments for this customer - * - * @return PaymentCollection - */ - public function payments() - { - return $this->client->customerPayments->listFor($this, null, null, $this->getPresetOptions()); - } - /** - * @param array $options - * @param array $filters - * - * @return Subscription - */ - public function createSubscription(array $options = [], array $filters = []) - { - return $this->client->subscriptions->createFor($this, $this->withPresetOptions($options), $filters); - } - /** - * @param string $subscriptionId - * @param array $parameters - * - * @return Subscription - */ - public function getSubscription($subscriptionId, array $parameters = []) - { - return $this->client->subscriptions->getFor($this, $subscriptionId, $this->withPresetOptions($parameters)); - } - /** - * @param string $subscriptionId - * - * @return null - */ - public function cancelSubscription($subscriptionId) - { - return $this->client->subscriptions->cancelFor($this, $subscriptionId, $this->getPresetOptions()); - } - /** - * Get all subscriptions for this customer - * - * @return SubscriptionCollection - */ - public function subscriptions() - { - return $this->client->subscriptions->listFor($this, null, null, $this->getPresetOptions()); - } - /** - * @param array $options - * @param array $filters - * - * @return Mandate - */ - public function createMandate(array $options = [], array $filters = []) - { - return $this->client->mandates->createFor($this, $this->withPresetOptions($options), $filters); - } - /** - * @param string $mandateId - * @param array $parameters - * - * @return Mandate - */ - public function getMandate($mandateId, array $parameters = []) - { - return $this->client->mandates->getFor($this, $mandateId, $parameters); - } - /** - * @param string $mandateId - * - * @return null - */ - public function revokeMandate($mandateId) - { - return $this->client->mandates->revokeFor($this, $mandateId, $this->getPresetOptions()); - } - /** - * Get all mandates for this customer - * - * @return MandateCollection - */ - public function mandates() - { - return $this->client->mandates->listFor($this, null, null, $this->getPresetOptions()); - } - /** - * Helper function to check for mandate with status valid - * - * @return bool - */ - public function hasValidMandate() - { - $mandates = $this->mandates(); - foreach ($mandates as $mandate) { - if ($mandate->isValid()) { - return \true; - } - } - return \false; - } - /** - * Helper function to check for specific payment method mandate with status valid - * - * @return bool - */ - public function hasValidMandateForMethod($method) - { - $mandates = $this->mandates(); - foreach ($mandates as $mandate) { - if ($mandate->method === $method && $mandate->isValid()) { - return \true; - } - } - return \false; - } - /** - * When accessed by oAuth we want to pass the testmode by default - * - * @return array - */ - private function getPresetOptions() - { - $options = []; - if ($this->client->usesOAuth()) { - $options["testmode"] = $this->mode === "test" ? \true : \false; - } - return $options; - } - /** - * Apply the preset options. - * - * @param array $options - * @return array - */ - private function withPresetOptions(array $options) - { - return \array_merge($this->getPresetOptions(), $options); - } -} +_links->self->href)) { + return $this; + } + $body = \json_encode(array("name" => $this->name, "email" => $this->email, "locale" => $this->locale, "metadata" => $this->metadata)); + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Customer($this->client)); + } + /** + * @param array $options + * @param array $filters + * + * @return Payment + */ + public function createPayment(array $options = [], array $filters = []) + { + return $this->client->customerPayments->createFor($this, $this->withPresetOptions($options), $filters); + } + /** + * Get all payments for this customer + * + * @return PaymentCollection + */ + public function payments() + { + return $this->client->customerPayments->listFor($this, null, null, $this->getPresetOptions()); + } + /** + * @param array $options + * @param array $filters + * + * @return Subscription + */ + public function createSubscription(array $options = [], array $filters = []) + { + return $this->client->subscriptions->createFor($this, $this->withPresetOptions($options), $filters); + } + /** + * @param string $subscriptionId + * @param array $parameters + * + * @return Subscription + */ + public function getSubscription($subscriptionId, array $parameters = []) + { + return $this->client->subscriptions->getFor($this, $subscriptionId, $this->withPresetOptions($parameters)); + } + /** + * @param string $subscriptionId + * + * @return null + */ + public function cancelSubscription($subscriptionId) + { + return $this->client->subscriptions->cancelFor($this, $subscriptionId, $this->getPresetOptions()); + } + /** + * Get all subscriptions for this customer + * + * @return SubscriptionCollection + */ + public function subscriptions() + { + return $this->client->subscriptions->listFor($this, null, null, $this->getPresetOptions()); + } + /** + * @param array $options + * @param array $filters + * + * @return Mandate + */ + public function createMandate(array $options = [], array $filters = []) + { + return $this->client->mandates->createFor($this, $this->withPresetOptions($options), $filters); + } + /** + * @param string $mandateId + * @param array $parameters + * + * @return Mandate + */ + public function getMandate($mandateId, array $parameters = []) + { + return $this->client->mandates->getFor($this, $mandateId, $parameters); + } + /** + * @param string $mandateId + * + * @return null + */ + public function revokeMandate($mandateId) + { + return $this->client->mandates->revokeFor($this, $mandateId, $this->getPresetOptions()); + } + /** + * Get all mandates for this customer + * + * @return MandateCollection + */ + public function mandates() + { + return $this->client->mandates->listFor($this, null, null, $this->getPresetOptions()); + } + /** + * Helper function to check for mandate with status valid + * + * @return bool + */ + public function hasValidMandate() + { + $mandates = $this->mandates(); + foreach ($mandates as $mandate) { + if ($mandate->isValid()) { + return \true; + } + } + return \false; + } + /** + * Helper function to check for specific payment method mandate with status valid + * + * @return bool + */ + public function hasValidMandateForMethod($method) + { + $mandates = $this->mandates(); + foreach ($mandates as $mandate) { + if ($mandate->method === $method && $mandate->isValid()) { + return \true; + } + } + return \false; + } + /** + * When accessed by oAuth we want to pass the testmode by default + * + * @return array + */ + private function getPresetOptions() + { + $options = []; + if ($this->client->usesOAuth()) { + $options["testmode"] = $this->mode === "test" ? \true : \false; + } + return $options; + } + /** + * Apply the preset options. + * + * @param array $options + * @return array + */ + private function withPresetOptions(array $options) + { + return \array_merge($this->getPresetOptions(), $options); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/CustomerCollection.php b/vendor/mollie/mollie-api-php/src/Resources/CustomerCollection.php index 9440c7a9f..f16bd57cd 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/CustomerCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/CustomerCollection.php @@ -1,21 +1,21 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Invoice.php b/vendor/mollie/mollie-api-php/src/Resources/Invoice.php index 845961ebb..a45558e15 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Invoice.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Invoice.php @@ -1,98 +1,98 @@ -status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\InvoiceStatus::STATUS_PAID; - } - /** - * @return bool - */ - public function isOpen() - { - return $this->status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\InvoiceStatus::STATUS_OPEN; - } - /** - * @return bool - */ - public function isOverdue() - { - return $this->status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\InvoiceStatus::STATUS_OVERDUE; - } -} +status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\InvoiceStatus::STATUS_PAID; + } + /** + * @return bool + */ + public function isOpen() + { + return $this->status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\InvoiceStatus::STATUS_OPEN; + } + /** + * @return bool + */ + public function isOverdue() + { + return $this->status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\InvoiceStatus::STATUS_OVERDUE; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/InvoiceCollection.php b/vendor/mollie/mollie-api-php/src/Resources/InvoiceCollection.php index 9ad6403e1..007173fdd 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/InvoiceCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/InvoiceCollection.php @@ -1,21 +1,21 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Issuer.php b/vendor/mollie/mollie-api-php/src/Resources/Issuer.php index 966bb4a36..58d867233 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Issuer.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Issuer.php @@ -1,32 +1,32 @@ -status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\MandateStatus::STATUS_VALID; - } - /** - * @return bool - */ - public function isPending() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\MandateStatus::STATUS_PENDING; - } - /** - * @return bool - */ - public function isInvalid() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\MandateStatus::STATUS_INVALID; - } - /** - * Revoke the mandate - * - * @return null - */ - public function revoke() - { - if (!isset($this->_links->self->href)) { - return $this; - } - $body = null; - if ($this->client->usesOAuth()) { - $body = \json_encode(["testmode" => $this->mode === "test" ? \true : \false]); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_DELETE, $this->_links->self->href, $body); - return $result; - } -} +status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\MandateStatus::STATUS_VALID; + } + /** + * @return bool + */ + public function isPending() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\MandateStatus::STATUS_PENDING; + } + /** + * @return bool + */ + public function isInvalid() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\MandateStatus::STATUS_INVALID; + } + /** + * Revoke the mandate + * + * @return null + */ + public function revoke() + { + if (!isset($this->_links->self->href)) { + return $this; + } + $body = null; + if ($this->client->usesOAuth()) { + $body = \json_encode(["testmode" => $this->mode === "test" ? \true : \false]); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_DELETE, $this->_links->self->href, $body); + return $result; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/MandateCollection.php b/vendor/mollie/mollie-api-php/src/Resources/MandateCollection.php index df6953a9d..2cffa0492 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/MandateCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/MandateCollection.php @@ -1,35 +1,35 @@ -client); - } - /** - * @param string $status - * @return array|\Mollie\Api\Resources\MandateCollection - */ - public function whereStatus($status) - { - $collection = new self($this->client, $this->count, $this->_links); - foreach ($this as $item) { - if ($item->status === $status) { - $collection[] = $item; - } - } - return $collection; - } -} +client); + } + /** + * @param string $status + * @return array|\Mollie\Api\Resources\MandateCollection + */ + public function whereStatus($status) + { + $collection = new self($this->client, $this->count, $this->_links); + foreach ($this as $item) { + if ($item->status === $status) { + $collection[] = $item; + } + } + return $collection; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Method.php b/vendor/mollie/mollie-api-php/src/Resources/Method.php index 319bd3982..b8630cb82 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Method.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Method.php @@ -1,75 +1,75 @@ -size1x and $image->size2x to display the payment method logo. - * - * @var \stdClass - */ - public $image; - /** - * The issuers available for this payment method. Only for the methods iDEAL, KBC/CBC and gift cards. - * Will only be filled when explicitly requested using the query string `include` parameter. - * - * @var array|object[] - */ - public $issuers; - /** - * The pricing for this payment method. Will only be filled when explicitly requested using the query string - * `include` parameter. - * - * @var array|object[] - */ - public $pricing; - /** - * @var \stdClass - */ - public $_links; - /** - * Get the issuer value objects - * - * @return IssuerCollection - */ - public function issuers() - { - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createBaseResourceCollection($this->client, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Issuer::class, $this->issuers); - } - /** - * Get the method price value objects. - * - * @return MethodPriceCollection - */ - public function pricing() - { - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createBaseResourceCollection($this->client, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\MethodPrice::class, $this->pricing); - } -} +size1x and $image->size2x to display the payment method logo. + * + * @var \stdClass + */ + public $image; + /** + * The issuers available for this payment method. Only for the methods iDEAL, KBC/CBC and gift cards. + * Will only be filled when explicitly requested using the query string `include` parameter. + * + * @var array|object[] + */ + public $issuers; + /** + * The pricing for this payment method. Will only be filled when explicitly requested using the query string + * `include` parameter. + * + * @var array|object[] + */ + public $pricing; + /** + * @var \stdClass + */ + public $_links; + /** + * Get the issuer value objects + * + * @return IssuerCollection + */ + public function issuers() + { + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createBaseResourceCollection($this->client, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Issuer::class, $this->issuers); + } + /** + * Get the method price value objects. + * + * @return MethodPriceCollection + */ + public function pricing() + { + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createBaseResourceCollection($this->client, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\MethodPrice::class, $this->pricing); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/MethodCollection.php b/vendor/mollie/mollie-api-php/src/Resources/MethodCollection.php index b34b6648e..8fa41ca39 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/MethodCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/MethodCollection.php @@ -1,14 +1,14 @@ -status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OnboardingStatus::NEEDS_DATA; - } - /** - * @return bool - */ - public function isInReview() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OnboardingStatus::IN_REVIEW; - } - /** - * @return bool - */ - public function isCompleted() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OnboardingStatus::COMPLETED; - } -} +status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OnboardingStatus::NEEDS_DATA; + } + /** + * @return bool + */ + public function isInReview() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OnboardingStatus::IN_REVIEW; + } + /** + * @return bool + */ + public function isCompleted() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OnboardingStatus::COMPLETED; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Order.php b/vendor/mollie/mollie-api-php/src/Resources/Order.php index c7f75f957..6ca4289e4 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Order.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Order.php @@ -1,431 +1,431 @@ -status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_CREATED; - } - /** - * Is this order paid for? - * - * @return bool - */ - public function isPaid() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_PAID; - } - /** - * Is this order authorized? - * - * @return bool - */ - public function isAuthorized() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_AUTHORIZED; - } - /** - * Is this order canceled? - * - * @return bool - */ - public function isCanceled() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_CANCELED; - } - /** - * (Deprecated) Is this order refunded? - * @deprecated 2018-11-27 - * - * @return bool - */ - public function isRefunded() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_REFUNDED; - } - /** - * Is this order shipping? - * - * @return bool - */ - public function isShipping() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_SHIPPING; - } - /** - * Is this order completed? - * - * @return bool - */ - public function isCompleted() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_COMPLETED; - } - /** - * Is this order expired? - * - * @return bool - */ - public function isExpired() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_EXPIRED; - } - /** - * Is this order completed? - * - * @return bool - */ - public function isPending() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_PENDING; - } - /** - * Cancels this order. - * If the order was partially shipped, the status will be "completed" instead of - * "canceled". - * Will throw a ApiException if the order id is invalid or the resource cannot - * be found. - * - * @return Order - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function cancel() - { - return $this->client->orders->cancel($this->id, $this->getPresetOptions()); - } - /** - * Cancel a line for this order. - * The data array must contain a lines array. - * You can pass an empty lines array if you want to cancel all eligible lines. - * Returns null if successful. - * - * @param array|null $data - * @return null - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function cancelLines(array $data) - { - return $this->client->orderLines->cancelFor($this, $data); - } - /** - * Cancels all eligible lines for this order. - * Returns null if successful. - * - * @param array|null $data - * @return null - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function cancelAllLines($data = []) - { - $data['lines'] = []; - return $this->client->orderLines->cancelFor($this, $data); - } - /** - * Get the line value objects - * - * @return OrderLineCollection - */ - public function lines() - { - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createBaseResourceCollection($this->client, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\OrderLine::class, $this->lines); - } - /** - * Create a shipment for some order lines. You can provide an empty array for the - * "lines" option to include all unshipped lines for this order. - * - * @param array $options - * - * @return Shipment - */ - public function createShipment(array $options = []) - { - return $this->client->shipments->createFor($this, $this->withPresetOptions($options)); - } - /** - * Create a shipment for all unshipped order lines. - * - * @param array $options - * - * @return Shipment - */ - public function shipAll(array $options = []) - { - $options['lines'] = []; - return $this->createShipment($options); - } - /** - * Retrieve a specific shipment for this order. - * - * @param string $shipmentId - * @param array $parameters - * - * @return Shipment - */ - public function getShipment($shipmentId, array $parameters = []) - { - return $this->client->shipments->getFor($this, $shipmentId, $this->withPresetOptions($parameters)); - } - /** - * Get all shipments for this order. - * - * @param array $parameters - * - * @return ShipmentCollection - */ - public function shipments(array $parameters = []) - { - return $this->client->shipments->listFor($this, $this->withPresetOptions($parameters)); - } - /** - * Get the checkout URL where the customer can complete the payment. - * - * @return string|null - */ - public function getCheckoutUrl() - { - if (empty($this->_links->checkout)) { - return null; - } - return $this->_links->checkout->href; - } - /** - * Refund specific order lines. - * - * @param array $data - * @return Refund - */ - public function refund(array $data) - { - return $this->client->orderRefunds->createFor($this, $this->withPresetOptions($data)); - } - /** - * Refund all eligible order lines. - * - * @param array $data - * @return Refund - */ - public function refundAll(array $data = []) - { - $data['lines'] = []; - return $this->refund($data); - } - /** - * Retrieves all refunds associated with this order - * - * @return RefundCollection - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function refunds() - { - if (!isset($this->_links->refunds->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->refunds->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->refunds, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund::class, $result->_links); - } - /** - * Saves the order's updated billingAddress and/or shippingAddress. - * - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Order - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function update() - { - if (!isset($this->_links->self->href)) { - return $this; - } - $body = \json_encode(array("billingAddress" => $this->billingAddress, "shippingAddress" => $this->shippingAddress, "orderNumber" => $this->orderNumber)); - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order($this->client)); - } - /** - * Create a new payment for this Order. - * - * @param $data - * @param array $filters - * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Payment - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function createPayment($data, $filters = []) - { - return $this->client->orderPayments->createFor($this, $data, $filters); - } - /** - * Retrieve the payments for this order. - * Requires the order to be retrieved using the embed payments parameter. - * - * @return null|\Mollie\Api\Resources\PaymentCollection - */ - public function payments() - { - if (!isset($this->_embedded, $this->_embedded->payments)) { - return null; - } - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $this->_embedded->payments, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment::class); - } - /** - * When accessed by oAuth we want to pass the testmode by default - * - * @return array - */ - private function getPresetOptions() - { - $options = []; - if ($this->client->usesOAuth()) { - $options["testmode"] = $this->mode === "test" ? \true : \false; - } - return $options; - } - /** - * Apply the preset options. - * - * @param array $options - * @return array - */ - private function withPresetOptions(array $options) - { - return \array_merge($this->getPresetOptions(), $options); - } -} +status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_CREATED; + } + /** + * Is this order paid for? + * + * @return bool + */ + public function isPaid() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_PAID; + } + /** + * Is this order authorized? + * + * @return bool + */ + public function isAuthorized() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_AUTHORIZED; + } + /** + * Is this order canceled? + * + * @return bool + */ + public function isCanceled() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_CANCELED; + } + /** + * (Deprecated) Is this order refunded? + * @deprecated 2018-11-27 + * + * @return bool + */ + public function isRefunded() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_REFUNDED; + } + /** + * Is this order shipping? + * + * @return bool + */ + public function isShipping() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_SHIPPING; + } + /** + * Is this order completed? + * + * @return bool + */ + public function isCompleted() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_COMPLETED; + } + /** + * Is this order expired? + * + * @return bool + */ + public function isExpired() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_EXPIRED; + } + /** + * Is this order completed? + * + * @return bool + */ + public function isPending() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderStatus::STATUS_PENDING; + } + /** + * Cancels this order. + * If the order was partially shipped, the status will be "completed" instead of + * "canceled". + * Will throw a ApiException if the order id is invalid or the resource cannot + * be found. + * + * @return Order + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function cancel() + { + return $this->client->orders->cancel($this->id, $this->getPresetOptions()); + } + /** + * Cancel a line for this order. + * The data array must contain a lines array. + * You can pass an empty lines array if you want to cancel all eligible lines. + * Returns null if successful. + * + * @param array|null $data + * @return null + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function cancelLines(array $data) + { + return $this->client->orderLines->cancelFor($this, $data); + } + /** + * Cancels all eligible lines for this order. + * Returns null if successful. + * + * @param array|null $data + * @return null + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function cancelAllLines($data = []) + { + $data['lines'] = []; + return $this->client->orderLines->cancelFor($this, $data); + } + /** + * Get the line value objects + * + * @return OrderLineCollection + */ + public function lines() + { + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createBaseResourceCollection($this->client, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\OrderLine::class, $this->lines); + } + /** + * Create a shipment for some order lines. You can provide an empty array for the + * "lines" option to include all unshipped lines for this order. + * + * @param array $options + * + * @return Shipment + */ + public function createShipment(array $options = []) + { + return $this->client->shipments->createFor($this, $this->withPresetOptions($options)); + } + /** + * Create a shipment for all unshipped order lines. + * + * @param array $options + * + * @return Shipment + */ + public function shipAll(array $options = []) + { + $options['lines'] = []; + return $this->createShipment($options); + } + /** + * Retrieve a specific shipment for this order. + * + * @param string $shipmentId + * @param array $parameters + * + * @return Shipment + */ + public function getShipment($shipmentId, array $parameters = []) + { + return $this->client->shipments->getFor($this, $shipmentId, $this->withPresetOptions($parameters)); + } + /** + * Get all shipments for this order. + * + * @param array $parameters + * + * @return ShipmentCollection + */ + public function shipments(array $parameters = []) + { + return $this->client->shipments->listFor($this, $this->withPresetOptions($parameters)); + } + /** + * Get the checkout URL where the customer can complete the payment. + * + * @return string|null + */ + public function getCheckoutUrl() + { + if (empty($this->_links->checkout)) { + return null; + } + return $this->_links->checkout->href; + } + /** + * Refund specific order lines. + * + * @param array $data + * @return Refund + */ + public function refund(array $data) + { + return $this->client->orderRefunds->createFor($this, $this->withPresetOptions($data)); + } + /** + * Refund all eligible order lines. + * + * @param array $data + * @return Refund + */ + public function refundAll(array $data = []) + { + $data['lines'] = []; + return $this->refund($data); + } + /** + * Retrieves all refunds associated with this order + * + * @return RefundCollection + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function refunds() + { + if (!isset($this->_links->refunds->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->refunds->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->refunds, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund::class, $result->_links); + } + /** + * Saves the order's updated billingAddress and/or shippingAddress. + * + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Order + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function update() + { + if (!isset($this->_links->self->href)) { + return $this; + } + $body = \json_encode(array("billingAddress" => $this->billingAddress, "shippingAddress" => $this->shippingAddress, "orderNumber" => $this->orderNumber)); + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order($this->client)); + } + /** + * Create a new payment for this Order. + * + * @param $data + * @param array $filters + * @return \Mollie\Api\Resources\BaseResource|\Mollie\Api\Resources\Payment + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function createPayment($data, $filters = []) + { + return $this->client->orderPayments->createFor($this, $data, $filters); + } + /** + * Retrieve the payments for this order. + * Requires the order to be retrieved using the embed payments parameter. + * + * @return null|\Mollie\Api\Resources\PaymentCollection + */ + public function payments() + { + if (!isset($this->_embedded, $this->_embedded->payments)) { + return null; + } + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $this->_embedded->payments, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment::class); + } + /** + * When accessed by oAuth we want to pass the testmode by default + * + * @return array + */ + private function getPresetOptions() + { + $options = []; + if ($this->client->usesOAuth()) { + $options["testmode"] = $this->mode === "test" ? \true : \false; + } + return $options; + } + /** + * Apply the preset options. + * + * @param array $options + * @return array + */ + private function withPresetOptions(array $options) + { + return \array_merge($this->getPresetOptions(), $options); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/OrderCollection.php b/vendor/mollie/mollie-api-php/src/Resources/OrderCollection.php index 5badebeef..f5da17f6e 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/OrderCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/OrderCollection.php @@ -1,21 +1,21 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/OrderLine.php b/vendor/mollie/mollie-api-php/src/Resources/OrderLine.php index 22db28744..3b304abcb 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/OrderLine.php +++ b/vendor/mollie/mollie-api-php/src/Resources/OrderLine.php @@ -1,257 +1,257 @@ -status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_CREATED; - } - /** - * Is this order line paid for? - * - * @return bool - */ - public function isPaid() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_PAID; - } - /** - * Is this order line authorized? - * - * @return bool - */ - public function isAuthorized() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_AUTHORIZED; - } - /** - * Is this order line canceled? - * - * @return bool - */ - public function isCanceled() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_CANCELED; - } - /** - * (Deprecated) Is this order line refunded? - * @deprecated 2018-11-27 - * - * @return bool - */ - public function isRefunded() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_REFUNDED; - } - /** - * Is this order line shipping? - * - * @return bool - */ - public function isShipping() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_SHIPPING; - } - /** - * Is this order line completed? - * - * @return bool - */ - public function isCompleted() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_COMPLETED; - } - /** - * Is this order line for a physical product? - * - * @return bool - */ - public function isPhysical() - { - return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_PHYSICAL; - } - /** - * Is this order line for applying a discount? - * - * @return bool - */ - public function isDiscount() - { - return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_DISCOUNT; - } - /** - * Is this order line for a digital product? - * - * @return bool - */ - public function isDigital() - { - return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_DIGITAL; - } - /** - * Is this order line for applying a shipping fee? - * - * @return bool - */ - public function isShippingFee() - { - return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_SHIPPING_FEE; - } - /** - * Is this order line for store credit? - * - * @return bool - */ - public function isStoreCredit() - { - return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_STORE_CREDIT; - } - /** - * Is this order line for a gift card? - * - * @return bool - */ - public function isGiftCard() - { - return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_GIFT_CARD; - } - /** - * Is this order line for a surcharge? - * - * @return bool - */ - public function isSurcharge() - { - return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_SURCHARGE; - } - public function update() - { - $body = \json_encode(array("name" => $this->name, 'imageUrl' => $this->imageUrl, 'productUrl' => $this->productUrl, 'quantity' => $this->quantity, 'unitPrice' => $this->unitPrice, 'discountAmount' => $this->discountAmount, 'totalAmount' => $this->totalAmount, 'vatAmount' => $this->vatAmount, 'vatRate' => $this->vatRate)); - $url = "orders/{$this->orderId}/lines/{$this->id}"; - $result = $this->client->performHttpCall(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $url, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order($this->client)); - } -} +status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_CREATED; + } + /** + * Is this order line paid for? + * + * @return bool + */ + public function isPaid() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_PAID; + } + /** + * Is this order line authorized? + * + * @return bool + */ + public function isAuthorized() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_AUTHORIZED; + } + /** + * Is this order line canceled? + * + * @return bool + */ + public function isCanceled() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_CANCELED; + } + /** + * (Deprecated) Is this order line refunded? + * @deprecated 2018-11-27 + * + * @return bool + */ + public function isRefunded() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_REFUNDED; + } + /** + * Is this order line shipping? + * + * @return bool + */ + public function isShipping() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_SHIPPING; + } + /** + * Is this order line completed? + * + * @return bool + */ + public function isCompleted() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineStatus::STATUS_COMPLETED; + } + /** + * Is this order line for a physical product? + * + * @return bool + */ + public function isPhysical() + { + return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_PHYSICAL; + } + /** + * Is this order line for applying a discount? + * + * @return bool + */ + public function isDiscount() + { + return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_DISCOUNT; + } + /** + * Is this order line for a digital product? + * + * @return bool + */ + public function isDigital() + { + return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_DIGITAL; + } + /** + * Is this order line for applying a shipping fee? + * + * @return bool + */ + public function isShippingFee() + { + return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_SHIPPING_FEE; + } + /** + * Is this order line for store credit? + * + * @return bool + */ + public function isStoreCredit() + { + return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_STORE_CREDIT; + } + /** + * Is this order line for a gift card? + * + * @return bool + */ + public function isGiftCard() + { + return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_GIFT_CARD; + } + /** + * Is this order line for a surcharge? + * + * @return bool + */ + public function isSurcharge() + { + return $this->type === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\OrderLineType::TYPE_SURCHARGE; + } + public function update() + { + $body = \json_encode(array("name" => $this->name, 'imageUrl' => $this->imageUrl, 'productUrl' => $this->productUrl, 'quantity' => $this->quantity, 'unitPrice' => $this->unitPrice, 'discountAmount' => $this->discountAmount, 'totalAmount' => $this->totalAmount, 'vatAmount' => $this->vatAmount, 'vatRate' => $this->vatRate)); + $url = "orders/{$this->orderId}/lines/{$this->id}"; + $result = $this->client->performHttpCall(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $url, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Order($this->client)); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/OrderLineCollection.php b/vendor/mollie/mollie-api-php/src/Resources/OrderLineCollection.php index 8491fa63d..4b580991a 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/OrderLineCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/OrderLineCollection.php @@ -1,30 +1,30 @@ -id === $lineId) { - return $line; - } - } - return null; - } -} +id === $lineId) { + return $line; + } + } + return null; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Organization.php b/vendor/mollie/mollie-api-php/src/Resources/Organization.php index 53f930571..312a4fb73 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Organization.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Organization.php @@ -1,55 +1,55 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Payment.php b/vendor/mollie/mollie-api-php/src/Resources/Payment.php index f99cda126..f081bb200 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Payment.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Payment.php @@ -1,569 +1,569 @@ -consumerName and $details->consumerAccount. - * - * @var \stdClass - */ - public $details; - /** - * Used to restrict the payment methods available to your customer to those from a single country. - * - * @var string|null; - */ - public $restrictPaymentMethodsToCountry; - /** - * @var \stdClass - */ - public $_links; - /** - * @var \stdClass[] - */ - public $_embedded; - /** - * Whether or not this payment can be canceled. - * - * @var bool|null - */ - public $isCancelable; - /** - * The total amount that is already captured for this payment. Only available - * when this payment supports captures. - * - * @var \stdClass|null - */ - public $amountCaptured; - /** - * The application fee, if the payment was created with one. Contains amount - * (the value and currency) and description. - * - * @var \stdClass|null - */ - public $applicationFeeAmount; - /** - * The date and time the payment became authorized, in ISO 8601 format. This - * parameter is omitted if the payment is not authorized (yet). - * - * @example "2013-12-25T10:30:54+00:00" - * @var string|null - */ - public $authorizedAt; - /** - * The date and time the payment was expired, in ISO 8601 format. This - * parameter is omitted if the payment did not expire (yet). - * - * @example "2013-12-25T10:30:54+00:00" - * @var string|null - */ - public $expiredAt; - /** - * If a customer was specified upon payment creation, the customer’s token will - * be available here as well. - * - * @example cst_XPn78q9CfT - * @var string|null - */ - public $customerId; - /** - * This optional field contains your customer’s ISO 3166-1 alpha-2 country code, - * detected by us during checkout. For example: BE. This field is omitted if the - * country code was not detected. - * - * @var string|null - */ - public $countryCode; - /** - * Is this payment canceled? - * - * @return bool - */ - public function isCanceled() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_CANCELED; - } - /** - * Is this payment expired? - * - * @return bool - */ - public function isExpired() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_EXPIRED; - } - /** - * Is this payment still open / ongoing? - * - * @return bool - */ - public function isOpen() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_OPEN; - } - /** - * Is this payment pending? - * - * @return bool - */ - public function isPending() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_PENDING; - } - /** - * Is this payment authorized? - * - * @return bool - */ - public function isAuthorized() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_AUTHORIZED; - } - /** - * Is this payment paid for? - * - * @return bool - */ - public function isPaid() - { - return !empty($this->paidAt); - } - /** - * Does the payment have refunds - * - * @return bool - */ - public function hasRefunds() - { - return !empty($this->_links->refunds); - } - /** - * Does this payment has chargebacks - * - * @return bool - */ - public function hasChargebacks() - { - return !empty($this->_links->chargebacks); - } - /** - * Is this payment failing? - * - * @return bool - */ - public function isFailed() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_FAILED; - } - /** - * Check whether 'sequenceType' is set to 'first'. If a 'first' payment has been - * completed successfully, the consumer's account may be charged automatically - * using recurring payments. - * - * @return bool - */ - public function hasSequenceTypeFirst() - { - return $this->sequenceType === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SequenceType::SEQUENCETYPE_FIRST; - } - /** - * Check whether 'sequenceType' is set to 'recurring'. This type of payment is - * processed without involving - * the consumer. - * - * @return bool - */ - public function hasSequenceTypeRecurring() - { - return $this->sequenceType === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SequenceType::SEQUENCETYPE_RECURRING; - } - /** - * Get the checkout URL where the customer can complete the payment. - * - * @return string|null - */ - public function getCheckoutUrl() - { - if (empty($this->_links->checkout)) { - return null; - } - return $this->_links->checkout->href; - } - /** - * @return bool - */ - public function canBeRefunded() - { - return $this->amountRemaining !== null; - } - /** - * @return bool - */ - public function canBePartiallyRefunded() - { - return $this->canBeRefunded(); - } - /** - * Get the amount that is already refunded - * - * @return float - */ - public function getAmountRefunded() - { - if ($this->amountRefunded) { - return (float) $this->amountRefunded->value; - } - return 0.0; - } - /** - * Get the remaining amount that can be refunded. For some payment methods this - * amount can be higher than the payment amount. This is possible to reimburse - * the costs for a return shipment to your customer for example. - * - * @return float - */ - public function getAmountRemaining() - { - if ($this->amountRemaining) { - return (float) $this->amountRemaining->value; - } - return 0.0; - } - /** - * Retrieves all refunds associated with this payment - * - * @return RefundCollection - * @throws ApiException - */ - public function refunds() - { - if (!isset($this->_links->refunds->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->refunds->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->refunds, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund::class, $result->_links); - } - /** - * @param string $refundId - * @param array $parameters - * - * @return Refund - */ - public function getRefund($refundId, array $parameters = []) - { - return $this->client->paymentRefunds->getFor($this, $refundId, $this->withPresetOptions($parameters)); - } - /** - * Retrieves all captures associated with this payment - * - * @return CaptureCollection - * @throws ApiException - */ - public function captures() - { - if (!isset($this->_links->captures->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\CaptureCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->captures->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->captures, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Capture::class, $result->_links); - } - /** - * @param string $captureId - * @param array $parameters - * - * @return Capture - */ - public function getCapture($captureId, array $parameters = []) - { - return $this->client->paymentCaptures->getFor($this, $captureId, $this->withPresetOptions($parameters)); - } - /** - * Retrieves all chargebacks associated with this payment - * - * @return ChargebackCollection - * @throws ApiException - */ - public function chargebacks() - { - if (!isset($this->_links->chargebacks->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ChargebackCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->chargebacks->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->chargebacks, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Chargeback::class, $result->_links); - } - /** - * Retrieves a specific chargeback for this payment. - * - * @param string $chargebackId - * @param array $parameters - * - * @return Chargeback - */ - public function getChargeback($chargebackId, array $parameters = []) - { - return $this->client->paymentChargebacks->getFor($this, $chargebackId, $this->withPresetOptions($parameters)); - } - /** - * Issue a refund for this payment. - * - * @param array $data - * - * @return BaseResource - * @throws ApiException - */ - public function refund($data) - { - $resource = "payments/" . \urlencode($this->id) . "/refunds"; - $data = $this->withPresetOptions($data); - $body = null; - if (\count($data) > 0) { - $body = \json_encode($data); - } - $result = $this->client->performHttpCall(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_POST, $resource, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund($this->client)); - } - public function update() - { - if (!isset($this->_links->self->href)) { - return $this; - } - $body = \json_encode(["description" => $this->description, "redirectUrl" => $this->redirectUrl, "webhookUrl" => $this->webhookUrl, "metadata" => $this->metadata, "restrictPaymentMethodsToCountry" => $this->restrictPaymentMethodsToCountry]); - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment($this->client)); - } - /** - * When accessed by oAuth we want to pass the testmode by default - * - * @return array - */ - private function getPresetOptions() - { - $options = []; - if ($this->client->usesOAuth()) { - $options["testmode"] = $this->mode === "test" ? \true : \false; - } - return $options; - } - /** - * Apply the preset options. - * - * @param array $options - * @return array - */ - private function withPresetOptions(array $options) - { - return \array_merge($this->getPresetOptions(), $options); - } - /** - * The total amount that is already captured for this payment. Only available - * when this payment supports captures. - * - * @return float - */ - public function getAmountCaptured() - { - if ($this->amountCaptured) { - return (float) $this->amountCaptured->value; - } - return 0.0; - } - /** - * The amount that has been settled. - * - * @return float - */ - public function getSettlementAmount() - { - if ($this->settlementAmount) { - return (float) $this->settlementAmount->value; - } - return 0.0; - } - /** - * The total amount that is already captured for this payment. Only available - * when this payment supports captures. - * - * @return float - */ - public function getApplicationFeeAmount() - { - if ($this->applicationFeeAmount) { - return (float) $this->applicationFeeAmount->value; - } - return 0.0; - } -} +consumerName and $details->consumerAccount. + * + * @var \stdClass + */ + public $details; + /** + * Used to restrict the payment methods available to your customer to those from a single country. + * + * @var string|null; + */ + public $restrictPaymentMethodsToCountry; + /** + * @var \stdClass + */ + public $_links; + /** + * @var \stdClass[] + */ + public $_embedded; + /** + * Whether or not this payment can be canceled. + * + * @var bool|null + */ + public $isCancelable; + /** + * The total amount that is already captured for this payment. Only available + * when this payment supports captures. + * + * @var \stdClass|null + */ + public $amountCaptured; + /** + * The application fee, if the payment was created with one. Contains amount + * (the value and currency) and description. + * + * @var \stdClass|null + */ + public $applicationFeeAmount; + /** + * The date and time the payment became authorized, in ISO 8601 format. This + * parameter is omitted if the payment is not authorized (yet). + * + * @example "2013-12-25T10:30:54+00:00" + * @var string|null + */ + public $authorizedAt; + /** + * The date and time the payment was expired, in ISO 8601 format. This + * parameter is omitted if the payment did not expire (yet). + * + * @example "2013-12-25T10:30:54+00:00" + * @var string|null + */ + public $expiredAt; + /** + * If a customer was specified upon payment creation, the customer’s token will + * be available here as well. + * + * @example cst_XPn78q9CfT + * @var string|null + */ + public $customerId; + /** + * This optional field contains your customer’s ISO 3166-1 alpha-2 country code, + * detected by us during checkout. For example: BE. This field is omitted if the + * country code was not detected. + * + * @var string|null + */ + public $countryCode; + /** + * Is this payment canceled? + * + * @return bool + */ + public function isCanceled() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_CANCELED; + } + /** + * Is this payment expired? + * + * @return bool + */ + public function isExpired() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_EXPIRED; + } + /** + * Is this payment still open / ongoing? + * + * @return bool + */ + public function isOpen() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_OPEN; + } + /** + * Is this payment pending? + * + * @return bool + */ + public function isPending() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_PENDING; + } + /** + * Is this payment authorized? + * + * @return bool + */ + public function isAuthorized() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_AUTHORIZED; + } + /** + * Is this payment paid for? + * + * @return bool + */ + public function isPaid() + { + return !empty($this->paidAt); + } + /** + * Does the payment have refunds + * + * @return bool + */ + public function hasRefunds() + { + return !empty($this->_links->refunds); + } + /** + * Does this payment has chargebacks + * + * @return bool + */ + public function hasChargebacks() + { + return !empty($this->_links->chargebacks); + } + /** + * Is this payment failing? + * + * @return bool + */ + public function isFailed() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\PaymentStatus::STATUS_FAILED; + } + /** + * Check whether 'sequenceType' is set to 'first'. If a 'first' payment has been + * completed successfully, the consumer's account may be charged automatically + * using recurring payments. + * + * @return bool + */ + public function hasSequenceTypeFirst() + { + return $this->sequenceType === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SequenceType::SEQUENCETYPE_FIRST; + } + /** + * Check whether 'sequenceType' is set to 'recurring'. This type of payment is + * processed without involving + * the consumer. + * + * @return bool + */ + public function hasSequenceTypeRecurring() + { + return $this->sequenceType === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SequenceType::SEQUENCETYPE_RECURRING; + } + /** + * Get the checkout URL where the customer can complete the payment. + * + * @return string|null + */ + public function getCheckoutUrl() + { + if (empty($this->_links->checkout)) { + return null; + } + return $this->_links->checkout->href; + } + /** + * @return bool + */ + public function canBeRefunded() + { + return $this->amountRemaining !== null; + } + /** + * @return bool + */ + public function canBePartiallyRefunded() + { + return $this->canBeRefunded(); + } + /** + * Get the amount that is already refunded + * + * @return float + */ + public function getAmountRefunded() + { + if ($this->amountRefunded) { + return (float) $this->amountRefunded->value; + } + return 0.0; + } + /** + * Get the remaining amount that can be refunded. For some payment methods this + * amount can be higher than the payment amount. This is possible to reimburse + * the costs for a return shipment to your customer for example. + * + * @return float + */ + public function getAmountRemaining() + { + if ($this->amountRemaining) { + return (float) $this->amountRemaining->value; + } + return 0.0; + } + /** + * Retrieves all refunds associated with this payment + * + * @return RefundCollection + * @throws ApiException + */ + public function refunds() + { + if (!isset($this->_links->refunds->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->refunds->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->refunds, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund::class, $result->_links); + } + /** + * @param string $refundId + * @param array $parameters + * + * @return Refund + */ + public function getRefund($refundId, array $parameters = []) + { + return $this->client->paymentRefunds->getFor($this, $refundId, $this->withPresetOptions($parameters)); + } + /** + * Retrieves all captures associated with this payment + * + * @return CaptureCollection + * @throws ApiException + */ + public function captures() + { + if (!isset($this->_links->captures->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\CaptureCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->captures->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->captures, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Capture::class, $result->_links); + } + /** + * @param string $captureId + * @param array $parameters + * + * @return Capture + */ + public function getCapture($captureId, array $parameters = []) + { + return $this->client->paymentCaptures->getFor($this, $captureId, $this->withPresetOptions($parameters)); + } + /** + * Retrieves all chargebacks associated with this payment + * + * @return ChargebackCollection + * @throws ApiException + */ + public function chargebacks() + { + if (!isset($this->_links->chargebacks->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ChargebackCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->chargebacks->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->chargebacks, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Chargeback::class, $result->_links); + } + /** + * Retrieves a specific chargeback for this payment. + * + * @param string $chargebackId + * @param array $parameters + * + * @return Chargeback + */ + public function getChargeback($chargebackId, array $parameters = []) + { + return $this->client->paymentChargebacks->getFor($this, $chargebackId, $this->withPresetOptions($parameters)); + } + /** + * Issue a refund for this payment. + * + * @param array $data + * + * @return BaseResource + * @throws ApiException + */ + public function refund($data) + { + $resource = "payments/" . \urlencode($this->id) . "/refunds"; + $data = $this->withPresetOptions($data); + $body = null; + if (\count($data) > 0) { + $body = \json_encode($data); + } + $result = $this->client->performHttpCall(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_POST, $resource, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund($this->client)); + } + public function update() + { + if (!isset($this->_links->self->href)) { + return $this; + } + $body = \json_encode(["description" => $this->description, "redirectUrl" => $this->redirectUrl, "webhookUrl" => $this->webhookUrl, "metadata" => $this->metadata, "restrictPaymentMethodsToCountry" => $this->restrictPaymentMethodsToCountry]); + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment($this->client)); + } + /** + * When accessed by oAuth we want to pass the testmode by default + * + * @return array + */ + private function getPresetOptions() + { + $options = []; + if ($this->client->usesOAuth()) { + $options["testmode"] = $this->mode === "test" ? \true : \false; + } + return $options; + } + /** + * Apply the preset options. + * + * @param array $options + * @return array + */ + private function withPresetOptions(array $options) + { + return \array_merge($this->getPresetOptions(), $options); + } + /** + * The total amount that is already captured for this payment. Only available + * when this payment supports captures. + * + * @return float + */ + public function getAmountCaptured() + { + if ($this->amountCaptured) { + return (float) $this->amountCaptured->value; + } + return 0.0; + } + /** + * The amount that has been settled. + * + * @return float + */ + public function getSettlementAmount() + { + if ($this->settlementAmount) { + return (float) $this->settlementAmount->value; + } + return 0.0; + } + /** + * The total amount that is already captured for this payment. Only available + * when this payment supports captures. + * + * @return float + */ + public function getApplicationFeeAmount() + { + if ($this->applicationFeeAmount) { + return (float) $this->applicationFeeAmount->value; + } + return 0.0; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/PaymentCollection.php b/vendor/mollie/mollie-api-php/src/Resources/PaymentCollection.php index a151c23de..2498c0e73 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/PaymentCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/PaymentCollection.php @@ -1,21 +1,21 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Permission.php b/vendor/mollie/mollie-api-php/src/Resources/Permission.php index 4caccba73..3019c631e 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Permission.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Permission.php @@ -1,28 +1,28 @@ -status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\ProfileStatus::STATUS_UNVERIFIED; - } - /** - * @return bool - */ - public function isVerified() - { - return $this->status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\ProfileStatus::STATUS_VERIFIED; - } - /** - * @return bool - */ - public function isBlocked() - { - return $this->status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\ProfileStatus::STATUS_BLOCKED; - } - /** - * @return Profile - * @throws ApiException - */ - public function update() - { - if (!isset($this->_links->self->href)) { - return $this; - } - $body = \json_encode(array("name" => $this->name, "website" => $this->website, "email" => $this->email, "phone" => $this->phone, "categoryCode" => $this->categoryCode, "mode" => $this->mode)); - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Profile($this->client)); - } - /** - * Retrieves all chargebacks associated with this profile - * - * @return ChargebackCollection - * @throws ApiException - */ - public function chargebacks() - { - if (!isset($this->_links->chargebacks->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ChargebackCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->chargebacks->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->chargebacks, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Chargeback::class, $result->_links); - } - /** - * Retrieves all methods activated on this profile - * - * @return MethodCollection - * @throws ApiException - */ - public function methods() - { - if (!isset($this->_links->methods->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\MethodCollection(0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->methods->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->methods, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Method::class, $result->_links); - } - /** - * Enable a payment method for this profile. - * - * @param string $methodId - * @param array $data - * @return Method - * @throws ApiException - */ - public function enableMethod($methodId, array $data = []) - { - return $this->client->profileMethods->createFor($this, $methodId, $data); - } - /** - * Disable a payment method for this profile. - * - * @param string $methodId - * @param array $data - * @return Method - * @throws ApiException - */ - public function disableMethod($methodId, array $data = []) - { - return $this->client->profileMethods->deleteFor($this, $methodId, $data); - } - /** - * Retrieves all payments associated with this profile - * - * @return PaymentCollection - * @throws ApiException - */ - public function payments() - { - if (!isset($this->_links->payments->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->payments->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->methods, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Method::class, $result->_links); - } - /** - * Retrieves all refunds associated with this profile - * - * @return RefundCollection - * @throws ApiException - */ - public function refunds() - { - if (!isset($this->_links->refunds->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->refunds->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->refunds, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund::class, $result->_links); - } -} +status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\ProfileStatus::STATUS_UNVERIFIED; + } + /** + * @return bool + */ + public function isVerified() + { + return $this->status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\ProfileStatus::STATUS_VERIFIED; + } + /** + * @return bool + */ + public function isBlocked() + { + return $this->status == \_PhpScoper5ea00cc67502b\Mollie\Api\Types\ProfileStatus::STATUS_BLOCKED; + } + /** + * @return Profile + * @throws ApiException + */ + public function update() + { + if (!isset($this->_links->self->href)) { + return $this; + } + $body = \json_encode(array("name" => $this->name, "website" => $this->website, "email" => $this->email, "phone" => $this->phone, "categoryCode" => $this->categoryCode, "mode" => $this->mode)); + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Profile($this->client)); + } + /** + * Retrieves all chargebacks associated with this profile + * + * @return ChargebackCollection + * @throws ApiException + */ + public function chargebacks() + { + if (!isset($this->_links->chargebacks->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ChargebackCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->chargebacks->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->chargebacks, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Chargeback::class, $result->_links); + } + /** + * Retrieves all methods activated on this profile + * + * @return MethodCollection + * @throws ApiException + */ + public function methods() + { + if (!isset($this->_links->methods->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\MethodCollection(0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->methods->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->methods, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Method::class, $result->_links); + } + /** + * Enable a payment method for this profile. + * + * @param string $methodId + * @param array $data + * @return Method + * @throws ApiException + */ + public function enableMethod($methodId, array $data = []) + { + return $this->client->profileMethods->createFor($this, $methodId, $data); + } + /** + * Disable a payment method for this profile. + * + * @param string $methodId + * @param array $data + * @return Method + * @throws ApiException + */ + public function disableMethod($methodId, array $data = []) + { + return $this->client->profileMethods->deleteFor($this, $methodId, $data); + } + /** + * Retrieves all payments associated with this profile + * + * @return PaymentCollection + * @throws ApiException + */ + public function payments() + { + if (!isset($this->_links->payments->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->payments->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->methods, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Method::class, $result->_links); + } + /** + * Retrieves all refunds associated with this profile + * + * @return RefundCollection + * @throws ApiException + */ + public function refunds() + { + if (!isset($this->_links->refunds->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->refunds->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->refunds, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund::class, $result->_links); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/ProfileCollection.php b/vendor/mollie/mollie-api-php/src/Resources/ProfileCollection.php index a8d6a4f78..5f17e8610 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/ProfileCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/ProfileCollection.php @@ -1,21 +1,21 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Refund.php b/vendor/mollie/mollie-api-php/src/Resources/Refund.php index c436b2899..3f79f353b 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Refund.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Refund.php @@ -1,122 +1,122 @@ -status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\RefundStatus::STATUS_QUEUED; - } - /** - * Is this refund pending? - * - * @return bool - */ - public function isPending() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\RefundStatus::STATUS_PENDING; - } - /** - * Is this refund processing? - * - * @return bool - */ - public function isProcessing() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\RefundStatus::STATUS_PROCESSING; - } - /** - * Is this refund transferred to consumer? - * - * @return bool - */ - public function isTransferred() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\RefundStatus::STATUS_REFUNDED; - } - /** - * Cancel the refund. - * Returns null if successful. - * - * @return null - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function cancel() - { - $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_DELETE, $this->_links->self->href); - return null; - } -} +status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\RefundStatus::STATUS_QUEUED; + } + /** + * Is this refund pending? + * + * @return bool + */ + public function isPending() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\RefundStatus::STATUS_PENDING; + } + /** + * Is this refund processing? + * + * @return bool + */ + public function isProcessing() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\RefundStatus::STATUS_PROCESSING; + } + /** + * Is this refund transferred to consumer? + * + * @return bool + */ + public function isTransferred() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\RefundStatus::STATUS_REFUNDED; + } + /** + * Cancel the refund. + * Returns null if successful. + * + * @return null + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function cancel() + { + $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_DELETE, $this->_links->self->href); + return null; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/RefundCollection.php b/vendor/mollie/mollie-api-php/src/Resources/RefundCollection.php index 7ea005f62..a5a45eabf 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/RefundCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/RefundCollection.php @@ -1,21 +1,21 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/ResourceFactory.php b/vendor/mollie/mollie-api-php/src/Resources/ResourceFactory.php index 13bf50400..a194b8c21 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/ResourceFactory.php +++ b/vendor/mollie/mollie-api-php/src/Resources/ResourceFactory.php @@ -1,60 +1,60 @@ - $value) { - $resource->{$property} = $value; - } - return $resource; - } - /** - * @param MollieApiClient $client - * @param string $resourceClass - * @param array $data - * @param null $_links - * @param null $resourceCollectionClass - * @return mixed - */ - public static function createBaseResourceCollection(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient $client, $resourceClass, $data, $_links = null, $resourceCollectionClass = null) - { - $resourceCollectionClass = $resourceCollectionClass ?: $resourceClass . 'Collection'; - $data = $data ?: []; - $result = new $resourceCollectionClass(\count($data), $_links); - foreach ($data as $item) { - $result[] = static::createFromApiResult($item, new $resourceClass($client)); - } - return $result; - } - /** - * @param MollieApiClient $client - * @param array $input - * @param string $resourceClass - * @param null $_links - * @param null $resourceCollectionClass - * @return mixed - */ - public static function createCursorResourceCollection($client, array $input, $resourceClass, $_links = null, $resourceCollectionClass = null) - { - if (null === $resourceCollectionClass) { - $resourceCollectionClass = $resourceClass . 'Collection'; - } - $data = new $resourceCollectionClass($client, \count($input), $_links); - foreach ($input as $item) { - $data[] = static::createFromApiResult($item, new $resourceClass($client)); - } - return $data; - } -} + $value) { + $resource->{$property} = $value; + } + return $resource; + } + /** + * @param MollieApiClient $client + * @param string $resourceClass + * @param array $data + * @param null $_links + * @param null $resourceCollectionClass + * @return mixed + */ + public static function createBaseResourceCollection(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient $client, $resourceClass, $data, $_links = null, $resourceCollectionClass = null) + { + $resourceCollectionClass = $resourceCollectionClass ?: $resourceClass . 'Collection'; + $data = $data ?: []; + $result = new $resourceCollectionClass(\count($data), $_links); + foreach ($data as $item) { + $result[] = static::createFromApiResult($item, new $resourceClass($client)); + } + return $result; + } + /** + * @param MollieApiClient $client + * @param array $input + * @param string $resourceClass + * @param null $_links + * @param null $resourceCollectionClass + * @return mixed + */ + public static function createCursorResourceCollection($client, array $input, $resourceClass, $_links = null, $resourceCollectionClass = null) + { + if (null === $resourceCollectionClass) { + $resourceCollectionClass = $resourceClass . 'Collection'; + } + $data = new $resourceCollectionClass($client, \count($input), $_links); + foreach ($input as $item) { + $data[] = static::createFromApiResult($item, new $resourceClass($client)); + } + return $data; + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Settlement.php b/vendor/mollie/mollie-api-php/src/Resources/Settlement.php index eae9f2b10..4c3a015b8 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Settlement.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Settlement.php @@ -1,160 +1,160 @@ -status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SettlementStatus::STATUS_OPEN; - } - /** - * Is this settlement pending? - * - * @return bool - */ - public function isPending() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SettlementStatus::STATUS_PENDING; - } - /** - * Is this settlement paidout? - * - * @return bool - */ - public function isPaidout() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SettlementStatus::STATUS_PAIDOUT; - } - /** - * Is this settlement failed? - * - * @return bool - */ - public function isFailed() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SettlementStatus::STATUS_FAILED; - } - /** - * Retrieves all payments associated with this settlement - * - * @return PaymentCollection - * @throws ApiException - */ - public function payments() - { - if (!isset($this->_links->payments->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->payments->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->payments, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment::class, $result->_links); - } - /** - * Retrieves all refunds associated with this settlement - * - * @return RefundCollection - * @throws ApiException - */ - public function refunds() - { - if (!isset($this->_links->refunds->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->refunds->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->refunds, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund::class, $result->_links); - } - /** - * Retrieves all chargebacks associated with this settlement - * - * @return ChargebackCollection - * @throws ApiException - */ - public function chargebacks() - { - if (!isset($this->_links->chargebacks->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ChargebackCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->chargebacks->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->chargebacks, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Chargeback::class, $result->_links); - } - /** - * Retrieves all captures associated with this settlement - * - * @return CaptureCollection - * @throws ApiException - */ - public function captures() - { - if (!isset($this->_links->captures->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\CaptureCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->captures->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->captures, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Capture::class, $result->_links); - } -} +status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SettlementStatus::STATUS_OPEN; + } + /** + * Is this settlement pending? + * + * @return bool + */ + public function isPending() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SettlementStatus::STATUS_PENDING; + } + /** + * Is this settlement paidout? + * + * @return bool + */ + public function isPaidout() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SettlementStatus::STATUS_PAIDOUT; + } + /** + * Is this settlement failed? + * + * @return bool + */ + public function isFailed() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SettlementStatus::STATUS_FAILED; + } + /** + * Retrieves all payments associated with this settlement + * + * @return PaymentCollection + * @throws ApiException + */ + public function payments() + { + if (!isset($this->_links->payments->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->payments->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->payments, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment::class, $result->_links); + } + /** + * Retrieves all refunds associated with this settlement + * + * @return RefundCollection + * @throws ApiException + */ + public function refunds() + { + if (!isset($this->_links->refunds->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\RefundCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->refunds->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->refunds, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Refund::class, $result->_links); + } + /** + * Retrieves all chargebacks associated with this settlement + * + * @return ChargebackCollection + * @throws ApiException + */ + public function chargebacks() + { + if (!isset($this->_links->chargebacks->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ChargebackCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->chargebacks->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->chargebacks, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Chargeback::class, $result->_links); + } + /** + * Retrieves all captures associated with this settlement + * + * @return CaptureCollection + * @throws ApiException + */ + public function captures() + { + if (!isset($this->_links->captures->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\CaptureCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->captures->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->captures, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Capture::class, $result->_links); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/SettlementCollection.php b/vendor/mollie/mollie-api-php/src/Resources/SettlementCollection.php index db6c91bd9..294ff1e1c 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/SettlementCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/SettlementCollection.php @@ -1,21 +1,21 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/Shipment.php b/vendor/mollie/mollie-api-php/src/Resources/Shipment.php index 03094d175..1b936b198 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/Shipment.php +++ b/vendor/mollie/mollie-api-php/src/Resources/Shipment.php @@ -1,112 +1,112 @@ -tracking !== null; - } - /** - * Does this shipment offer a track and trace code? - * - * @return bool - */ - public function hasTrackingUrl() - { - return $this->hasTracking() && !empty($this->tracking->url); - } - /** - * Retrieve the track and trace url. Returns null if there is no url available. - * - * @return string|null - */ - public function getTrackingUrl() - { - if (!$this->hasTrackingUrl()) { - return null; - } - return $this->tracking->url; - } - /** - * Get the line value objects - * - * @return OrderLineCollection - */ - public function lines() - { - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createBaseResourceCollection($this->client, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\OrderLine::class, $this->lines); - } - /** - * Get the Order object for this shipment - * - * @return Order - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function order() - { - return $this->client->orders->get($this->orderId); - } - /** - * Save changes made to this shipment. - * - * @return BaseResource|Shipment - * @throws \Mollie\Api\Exceptions\ApiException - */ - public function update() - { - if (!isset($this->_links->self->href)) { - return $this; - } - $body = \json_encode(["tracking" => $this->tracking]); - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Shipment($this->client)); - } -} +tracking !== null; + } + /** + * Does this shipment offer a track and trace code? + * + * @return bool + */ + public function hasTrackingUrl() + { + return $this->hasTracking() && !empty($this->tracking->url); + } + /** + * Retrieve the track and trace url. Returns null if there is no url available. + * + * @return string|null + */ + public function getTrackingUrl() + { + if (!$this->hasTrackingUrl()) { + return null; + } + return $this->tracking->url; + } + /** + * Get the line value objects + * + * @return OrderLineCollection + */ + public function lines() + { + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createBaseResourceCollection($this->client, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\OrderLine::class, $this->lines); + } + /** + * Get the Order object for this shipment + * + * @return Order + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function order() + { + return $this->client->orders->get($this->orderId); + } + /** + * Save changes made to this shipment. + * + * @return BaseResource|Shipment + * @throws \Mollie\Api\Exceptions\ApiException + */ + public function update() + { + if (!isset($this->_links->self->href)) { + return $this; + } + $body = \json_encode(["tracking" => $this->tracking]); + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Shipment($this->client)); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/ShipmentCollection.php b/vendor/mollie/mollie-api-php/src/Resources/ShipmentCollection.php index 9a8a62048..bea3caeab 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/ShipmentCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/ShipmentCollection.php @@ -1,14 +1,14 @@ -_links->self->href)) { - return $this; - } - $body = \json_encode(["amount" => $this->amount, "times" => $this->times, "startDate" => $this->startDate, "webhookUrl" => $this->webhookUrl, "description" => $this->description, "mandateId" => $this->mandateId, "metadata" => $this->metadata, "interval" => $this->interval]); - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Subscription($this->client)); - } - /** - * Returns whether the Subscription is active or not. - * - * @return bool - */ - public function isActive() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SubscriptionStatus::STATUS_ACTIVE; - } - /** - * Returns whether the Subscription is pending or not. - * - * @return bool - */ - public function isPending() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SubscriptionStatus::STATUS_PENDING; - } - /** - * Returns whether the Subscription is canceled or not. - * - * @return bool - */ - public function isCanceled() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SubscriptionStatus::STATUS_CANCELED; - } - /** - * Returns whether the Subscription is suspended or not. - * - * @return bool - */ - public function isSuspended() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SubscriptionStatus::STATUS_SUSPENDED; - } - /** - * Returns whether the Subscription is completed or not. - * - * @return bool - */ - public function isCompleted() - { - return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SubscriptionStatus::STATUS_COMPLETED; - } - /** - * Cancels this subscription - * - * @return Subscription - */ - public function cancel() - { - if (!isset($this->_links->self->href)) { - return $this; - } - $body = null; - if ($this->client->usesOAuth()) { - $body = \json_encode(["testmode" => $this->mode === "test" ? \true : \false]); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_DELETE, $this->_links->self->href, $body); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Subscription($this->client)); - } - public function payments() - { - if (!isset($this->_links->payments->href)) { - return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, 0, null); - } - $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->payments->href); - return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->payments, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment::class, $result->_links); - } -} +_links->self->href)) { + return $this; + } + $body = \json_encode(["amount" => $this->amount, "times" => $this->times, "startDate" => $this->startDate, "webhookUrl" => $this->webhookUrl, "description" => $this->description, "mandateId" => $this->mandateId, "metadata" => $this->metadata, "interval" => $this->interval]); + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_PATCH, $this->_links->self->href, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Subscription($this->client)); + } + /** + * Returns whether the Subscription is active or not. + * + * @return bool + */ + public function isActive() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SubscriptionStatus::STATUS_ACTIVE; + } + /** + * Returns whether the Subscription is pending or not. + * + * @return bool + */ + public function isPending() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SubscriptionStatus::STATUS_PENDING; + } + /** + * Returns whether the Subscription is canceled or not. + * + * @return bool + */ + public function isCanceled() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SubscriptionStatus::STATUS_CANCELED; + } + /** + * Returns whether the Subscription is suspended or not. + * + * @return bool + */ + public function isSuspended() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SubscriptionStatus::STATUS_SUSPENDED; + } + /** + * Returns whether the Subscription is completed or not. + * + * @return bool + */ + public function isCompleted() + { + return $this->status === \_PhpScoper5ea00cc67502b\Mollie\Api\Types\SubscriptionStatus::STATUS_COMPLETED; + } + /** + * Cancels this subscription + * + * @return Subscription + */ + public function cancel() + { + if (!isset($this->_links->self->href)) { + return $this; + } + $body = null; + if ($this->client->usesOAuth()) { + $body = \json_encode(["testmode" => $this->mode === "test" ? \true : \false]); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_DELETE, $this->_links->self->href, $body); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createFromApiResult($result, new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Subscription($this->client)); + } + public function payments() + { + if (!isset($this->_links->payments->href)) { + return new \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\PaymentCollection($this->client, 0, null); + } + $result = $this->client->performHttpCallToFullUrl(\_PhpScoper5ea00cc67502b\Mollie\Api\MollieApiClient::HTTP_GET, $this->_links->payments->href); + return \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\ResourceFactory::createCursorResourceCollection($this->client, $result->_embedded->payments, \_PhpScoper5ea00cc67502b\Mollie\Api\Resources\Payment::class, $result->_links); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/SubscriptionCollection.php b/vendor/mollie/mollie-api-php/src/Resources/SubscriptionCollection.php index ff0fccdfd..928a24114 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/SubscriptionCollection.php +++ b/vendor/mollie/mollie-api-php/src/Resources/SubscriptionCollection.php @@ -1,21 +1,21 @@ -client); - } -} +client); + } +} diff --git a/vendor/mollie/mollie-api-php/src/Resources/index.php b/vendor/mollie/mollie-api-php/src/Resources/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/src/Resources/index.php +++ b/vendor/mollie/mollie-api-php/src/Resources/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/src/Types/InvoiceStatus.php b/vendor/mollie/mollie-api-php/src/Types/InvoiceStatus.php index e4d7d423b..71b02d8bd 100644 --- a/vendor/mollie/mollie-api-php/src/Types/InvoiceStatus.php +++ b/vendor/mollie/mollie-api-php/src/Types/InvoiceStatus.php @@ -1,19 +1,19 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/mollie/mollie-api-php/src/index.php b/vendor/mollie/mollie-api-php/src/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/mollie/mollie-api-php/src/index.php +++ b/vendor/mollie/mollie-api-php/src/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/paragonie/index.php b/vendor/paragonie/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/paragonie/index.php +++ b/vendor/paragonie/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/paragonie/random_compat/LICENSE b/vendor/paragonie/random_compat/LICENSE index 45c7017df..2e2bf4881 100644 --- a/vendor/paragonie/random_compat/LICENSE +++ b/vendor/paragonie/random_compat/LICENSE @@ -1,22 +1,22 @@ -The MIT License (MIT) - -Copyright (c) 2015 Paragon Initiative Enterprises - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. - +The MIT License (MIT) + +Copyright (c) 2015 Paragon Initiative Enterprises + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + diff --git a/vendor/paragonie/random_compat/composer.json b/vendor/paragonie/random_compat/composer.json index 516a14363..e11022756 100644 --- a/vendor/paragonie/random_compat/composer.json +++ b/vendor/paragonie/random_compat/composer.json @@ -1,38 +1,38 @@ -{ - "name": "paragonie\/random_compat", - "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", - "keywords": [ - "csprng", - "random", - "polyfill", - "pseudorandom" - ], - "license": "MIT", - "type": "library", - "authors": [ - { - "name": "Paragon Initiative Enterprises", - "email": "security@paragonie.com", - "homepage": "https:\/\/paragonie.com" - } - ], - "support": { - "issues": "https:\/\/github.com\/paragonie\/random_compat\/issues", - "email": "info@paragonie.com", - "source": "https:\/\/github.com\/paragonie\/random_compat" - }, - "require": { - "php": ">=5.2.0" - }, - "require-dev": { - "phpunit\/phpunit": "4.*|5.*" - }, - "suggest": { - "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." - }, - "autoload": { - "files": [ - "lib\/random.php" - ] - } +{ + "name": "paragonie\/random_compat", + "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", + "keywords": [ + "csprng", + "random", + "polyfill", + "pseudorandom" + ], + "license": "MIT", + "type": "library", + "authors": [ + { + "name": "Paragon Initiative Enterprises", + "email": "security@paragonie.com", + "homepage": "https:\/\/paragonie.com" + } + ], + "support": { + "issues": "https:\/\/github.com\/paragonie\/random_compat\/issues", + "email": "info@paragonie.com", + "source": "https:\/\/github.com\/paragonie\/random_compat" + }, + "require": { + "php": ">=5.2.0" + }, + "require-dev": { + "phpunit\/phpunit": "4.*|5.*" + }, + "suggest": { + "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." + }, + "autoload": { + "files": [ + "lib\/random.php" + ] + } } \ No newline at end of file diff --git a/vendor/paragonie/random_compat/dist/index.php b/vendor/paragonie/random_compat/dist/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/paragonie/random_compat/dist/index.php +++ b/vendor/paragonie/random_compat/dist/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/paragonie/random_compat/dist/random_compat.phar.pubkey b/vendor/paragonie/random_compat/dist/random_compat.phar.pubkey index eb50ebfcd..faf8afc61 100644 --- a/vendor/paragonie/random_compat/dist/random_compat.phar.pubkey +++ b/vendor/paragonie/random_compat/dist/random_compat.phar.pubkey @@ -1,5 +1,5 @@ ------BEGIN PUBLIC KEY----- -MHYwEAYHKoZIzj0CAQYFK4EEACIDYgAEEd+wCqJDrx5B4OldM0dQE0ZMX+lx1ZWm -pui0SUqD4G29L3NGsz9UhJ/0HjBdbnkhIK5xviT0X5vtjacF6ajgcCArbTB+ds+p -+h7Q084NuSuIpNb6YPfoUFgC/CL9kAoc ------END PUBLIC KEY----- +-----BEGIN PUBLIC KEY----- +MHYwEAYHKoZIzj0CAQYFK4EEACIDYgAEEd+wCqJDrx5B4OldM0dQE0ZMX+lx1ZWm +pui0SUqD4G29L3NGsz9UhJ/0HjBdbnkhIK5xviT0X5vtjacF6ajgcCArbTB+ds+p ++h7Q084NuSuIpNb6YPfoUFgC/CL9kAoc +-----END PUBLIC KEY----- diff --git a/vendor/paragonie/random_compat/dist/random_compat.phar.pubkey.asc b/vendor/paragonie/random_compat/dist/random_compat.phar.pubkey.asc index 6a1d7f300..3b2a0379e 100644 --- a/vendor/paragonie/random_compat/dist/random_compat.phar.pubkey.asc +++ b/vendor/paragonie/random_compat/dist/random_compat.phar.pubkey.asc @@ -1,11 +1,11 @@ ------BEGIN PGP SIGNATURE----- -Version: GnuPG v2.0.22 (MingW32) - -iQEcBAABAgAGBQJWtW1hAAoJEGuXocKCZATaJf0H+wbZGgskK1dcRTsuVJl9IWip -QwGw/qIKI280SD6/ckoUMxKDCJiFuPR14zmqnS36k7N5UNPnpdTJTS8T11jttSpg -1LCmgpbEIpgaTah+cELDqFCav99fS+bEiAL5lWDAHBTE/XPjGVCqeehyPYref4IW -NDBIEsvnHPHPLsn6X5jq4+Yj5oUixgxaMPiR+bcO4Sh+RzOVB6i2D0upWfRXBFXA -NNnsg9/zjvoC7ZW73y9uSH+dPJTt/Vgfeiv52/v41XliyzbUyLalf02GNPY+9goV -JHG1ulEEBJOCiUD9cE1PUIJwHA/HqyhHIvV350YoEFiHl8iSwm7SiZu5kPjaq74= -=B6+8 ------END PGP SIGNATURE----- +-----BEGIN PGP SIGNATURE----- +Version: GnuPG v2.0.22 (MingW32) + +iQEcBAABAgAGBQJWtW1hAAoJEGuXocKCZATaJf0H+wbZGgskK1dcRTsuVJl9IWip +QwGw/qIKI280SD6/ckoUMxKDCJiFuPR14zmqnS36k7N5UNPnpdTJTS8T11jttSpg +1LCmgpbEIpgaTah+cELDqFCav99fS+bEiAL5lWDAHBTE/XPjGVCqeehyPYref4IW +NDBIEsvnHPHPLsn6X5jq4+Yj5oUixgxaMPiR+bcO4Sh+RzOVB6i2D0upWfRXBFXA +NNnsg9/zjvoC7ZW73y9uSH+dPJTt/Vgfeiv52/v41XliyzbUyLalf02GNPY+9goV +JHG1ulEEBJOCiUD9cE1PUIJwHA/HqyhHIvV350YoEFiHl8iSwm7SiZu5kPjaq74= +=B6+8 +-----END PGP SIGNATURE----- diff --git a/vendor/paragonie/random_compat/index.php b/vendor/paragonie/random_compat/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/paragonie/random_compat/index.php +++ b/vendor/paragonie/random_compat/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/paragonie/random_compat/lib/byte_safe_strings.php b/vendor/paragonie/random_compat/lib/byte_safe_strings.php index fd67de500..2bc8a36d8 100644 --- a/vendor/paragonie/random_compat/lib/byte_safe_strings.php +++ b/vendor/paragonie/random_compat/lib/byte_safe_strings.php @@ -1,147 +1,147 @@ - \_PhpScoper5ea00cc67502b\RandomCompat_strlen($binary_string)) { - return ''; - } - return (string) \mb_substr((string) $binary_string, (int) $start, (int) $length, '8bit'); - } - } else { - /** - * substr() implementation that isn't brittle to mbstring.func_overload - * - * This version just uses the default substr() - * - * @param string $binary_string - * @param int $start - * @param int|null $length (optional) - * - * @throws TypeError - * - * @return string - */ - function RandomCompat_substr($binary_string, $start, $length = null) - { - if (!\is_string($binary_string)) { - throw new \TypeError('RandomCompat_substr(): First argument should be a string'); - } - if (!\is_int($start)) { - throw new \TypeError('RandomCompat_substr(): Second argument should be an integer'); - } - if ($length !== null) { - if (!\is_int($length)) { - throw new \TypeError('RandomCompat_substr(): Third argument should be an integer, or omitted'); - } - return (string) \substr((string) $binary_string, (int) $start, (int) $length); - } - return (string) \substr((string) $binary_string, (int) $start); - } - } -} + \_PhpScoper5ea00cc67502b\RandomCompat_strlen($binary_string)) { + return ''; + } + return (string) \mb_substr((string) $binary_string, (int) $start, (int) $length, '8bit'); + } + } else { + /** + * substr() implementation that isn't brittle to mbstring.func_overload + * + * This version just uses the default substr() + * + * @param string $binary_string + * @param int $start + * @param int|null $length (optional) + * + * @throws TypeError + * + * @return string + */ + function RandomCompat_substr($binary_string, $start, $length = null) + { + if (!\is_string($binary_string)) { + throw new \TypeError('RandomCompat_substr(): First argument should be a string'); + } + if (!\is_int($start)) { + throw new \TypeError('RandomCompat_substr(): Second argument should be an integer'); + } + if ($length !== null) { + if (!\is_int($length)) { + throw new \TypeError('RandomCompat_substr(): Third argument should be an integer, or omitted'); + } + return (string) \substr((string) $binary_string, (int) $start, (int) $length); + } + return (string) \substr((string) $binary_string, (int) $start); + } + } +} diff --git a/vendor/paragonie/random_compat/lib/cast_to_int.php b/vendor/paragonie/random_compat/lib/cast_to_int.php index bbfc035fa..e49f2cc4f 100644 --- a/vendor/paragonie/random_compat/lib/cast_to_int.php +++ b/vendor/paragonie/random_compat/lib/cast_to_int.php @@ -1,68 +1,68 @@ - operators might accidentally let a float - * through. - * - * @param int|float $number The number we want to convert to an int - * @param bool $fail_open Set to true to not throw an exception - * - * @return float|int - * @psalm-suppress InvalidReturnType - * - * @throws TypeError - */ - function RandomCompat_intval($number, $fail_open = \false) - { - if (\is_int($number) || \is_float($number)) { - $number += 0; - } elseif (\is_numeric($number)) { - /** @psalm-suppress InvalidOperand */ - $number += 0; - } - /** @var int|float $number */ - if (\is_float($number) && $number > ~\PHP_INT_MAX && $number < \PHP_INT_MAX) { - $number = (int) $number; - } - if (\is_int($number)) { - return (int) $number; - } elseif (!$fail_open) { - throw new \TypeError('Expected an integer.'); - } - return $number; - } -} + operators might accidentally let a float + * through. + * + * @param int|float $number The number we want to convert to an int + * @param bool $fail_open Set to true to not throw an exception + * + * @return float|int + * @psalm-suppress InvalidReturnType + * + * @throws TypeError + */ + function RandomCompat_intval($number, $fail_open = \false) + { + if (\is_int($number) || \is_float($number)) { + $number += 0; + } elseif (\is_numeric($number)) { + /** @psalm-suppress InvalidOperand */ + $number += 0; + } + /** @var int|float $number */ + if (\is_float($number) && $number > ~\PHP_INT_MAX && $number < \PHP_INT_MAX) { + $number = (int) $number; + } + if (\is_int($number)) { + return (int) $number; + } elseif (!$fail_open) { + throw new \TypeError('Expected an integer.'); + } + return $number; + } +} diff --git a/vendor/paragonie/random_compat/lib/error_polyfill.php b/vendor/paragonie/random_compat/lib/error_polyfill.php index 79e7006c7..fbbbcea5c 100644 --- a/vendor/paragonie/random_compat/lib/error_polyfill.php +++ b/vendor/paragonie/random_compat/lib/error_polyfill.php @@ -1,47 +1,47 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/paragonie/random_compat/lib/random.php b/vendor/paragonie/random_compat/lib/random.php index 82aaf7509..2f307eb94 100644 --- a/vendor/paragonie/random_compat/lib/random.php +++ b/vendor/paragonie/random_compat/lib/random.php @@ -1,171 +1,171 @@ -= 70000) { - return; -} -if (!\defined('RANDOM_COMPAT_READ_BUFFER')) { - \define('RANDOM_COMPAT_READ_BUFFER', 8); -} -$RandomCompatDIR = \dirname(__FILE__); -require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'byte_safe_strings.php'; -require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'cast_to_int.php'; -require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'error_polyfill.php'; -if (!\is_callable('random_bytes')) { - /** - * PHP 5.2.0 - 5.6.x way to implement random_bytes() - * - * We use conditional statements here to define the function in accordance - * to the operating environment. It's a micro-optimization. - * - * In order of preference: - * 1. Use libsodium if available. - * 2. fread() /dev/urandom if available (never on Windows) - * 3. mcrypt_create_iv($bytes, MCRYPT_DEV_URANDOM) - * 4. COM('CAPICOM.Utilities.1')->GetRandom() - * - * See RATIONALE.md for our reasoning behind this particular order - */ - if (\extension_loaded('libsodium')) { - // See random_bytes_libsodium.php - if (\PHP_VERSION_ID >= 50300 && \is_callable('_PhpScoper5ea00cc67502b\\Sodium\\randombytes_buf')) { - require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_bytes_libsodium.php'; - } elseif (\method_exists('Sodium', 'randombytes_buf')) { - require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_bytes_libsodium_legacy.php'; - } - } - /** - * Reading directly from /dev/urandom: - */ - if (\DIRECTORY_SEPARATOR === '/') { - // DIRECTORY_SEPARATOR === '/' on Unix-like OSes -- this is a fast - // way to exclude Windows. - $RandomCompatUrandom = \true; - $RandomCompat_basedir = \ini_get('open_basedir'); - if (!empty($RandomCompat_basedir)) { - $RandomCompat_open_basedir = \explode(\PATH_SEPARATOR, \strtolower($RandomCompat_basedir)); - $RandomCompatUrandom = array() !== \array_intersect(array('/dev', '/dev/', '/dev/urandom'), $RandomCompat_open_basedir); - $RandomCompat_open_basedir = null; - } - if (!\is_callable('random_bytes') && $RandomCompatUrandom && @\is_readable('/dev/urandom')) { - // Error suppression on is_readable() in case of an open_basedir - // or safe_mode failure. All we care about is whether or not we - // can read it at this point. If the PHP environment is going to - // panic over trying to see if the file can be read in the first - // place, that is not helpful to us here. - // See random_bytes_dev_urandom.php - require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_bytes_dev_urandom.php'; - } - // Unset variables after use - $RandomCompat_basedir = null; - } else { - $RandomCompatUrandom = \false; - } - /** - * mcrypt_create_iv() - * - * We only want to use mcypt_create_iv() if: - * - * - random_bytes() hasn't already been defined - * - the mcrypt extensions is loaded - * - One of these two conditions is true: - * - We're on Windows (DIRECTORY_SEPARATOR !== '/') - * - We're not on Windows and /dev/urandom is readabale - * (i.e. we're not in a chroot jail) - * - Special case: - * - If we're not on Windows, but the PHP version is between - * 5.6.10 and 5.6.12, we don't want to use mcrypt. It will - * hang indefinitely. This is bad. - * - If we're on Windows, we want to use PHP >= 5.3.7 or else - * we get insufficient entropy errors. - */ - if (!\is_callable('random_bytes') && (\DIRECTORY_SEPARATOR === '/' || \PHP_VERSION_ID >= 50307) && (\DIRECTORY_SEPARATOR !== '/' || (\PHP_VERSION_ID <= 50609 || \PHP_VERSION_ID >= 50613)) && \extension_loaded('mcrypt')) { - // See random_bytes_mcrypt.php - require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_bytes_mcrypt.php'; - } - $RandomCompatUrandom = null; - /** - * This is a Windows-specific fallback, for when the mcrypt extension - * isn't loaded. - */ - if (!\is_callable('random_bytes') && \extension_loaded('com_dotnet') && \class_exists('_PhpScoper5ea00cc67502b\\COM')) { - $RandomCompat_disabled_classes = \preg_split('#\\s*,\\s*#', \strtolower(\ini_get('disable_classes'))); - if (!\in_array('com', $RandomCompat_disabled_classes)) { - try { - $RandomCompatCOMtest = new \_PhpScoper5ea00cc67502b\COM('CAPICOM.Utilities.1'); - if (\method_exists($RandomCompatCOMtest, 'GetRandom')) { - // See random_bytes_com_dotnet.php - require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_bytes_com_dotnet.php'; - } - } catch (\_PhpScoper5ea00cc67502b\com_exception $e) { - // Don't try to use it. - } - } - $RandomCompat_disabled_classes = null; - $RandomCompatCOMtest = null; - } - /** - * throw new Exception - */ - if (!\is_callable('random_bytes')) { - /** - * We don't have any more options, so let's throw an exception right now - * and hope the developer won't let it fail silently. - * - * @param mixed $length - * @psalm-suppress InvalidReturnType - * @throws Exception - * @return string - */ - function random_bytes($length) - { - unset($length); - // Suppress "variable not used" warnings. - throw new \Exception('There is no suitable CSPRNG installed on your system'); - return ''; - } - } -} -if (!\is_callable('random_int')) { - require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_int.php'; -} -$RandomCompatDIR = null; += 70000) { + return; +} +if (!\defined('RANDOM_COMPAT_READ_BUFFER')) { + \define('RANDOM_COMPAT_READ_BUFFER', 8); +} +$RandomCompatDIR = \dirname(__FILE__); +require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'byte_safe_strings.php'; +require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'cast_to_int.php'; +require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'error_polyfill.php'; +if (!\is_callable('random_bytes')) { + /** + * PHP 5.2.0 - 5.6.x way to implement random_bytes() + * + * We use conditional statements here to define the function in accordance + * to the operating environment. It's a micro-optimization. + * + * In order of preference: + * 1. Use libsodium if available. + * 2. fread() /dev/urandom if available (never on Windows) + * 3. mcrypt_create_iv($bytes, MCRYPT_DEV_URANDOM) + * 4. COM('CAPICOM.Utilities.1')->GetRandom() + * + * See RATIONALE.md for our reasoning behind this particular order + */ + if (\extension_loaded('libsodium')) { + // See random_bytes_libsodium.php + if (\PHP_VERSION_ID >= 50300 && \is_callable('_PhpScoper5ea00cc67502b\\Sodium\\randombytes_buf')) { + require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_bytes_libsodium.php'; + } elseif (\method_exists('Sodium', 'randombytes_buf')) { + require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_bytes_libsodium_legacy.php'; + } + } + /** + * Reading directly from /dev/urandom: + */ + if (\DIRECTORY_SEPARATOR === '/') { + // DIRECTORY_SEPARATOR === '/' on Unix-like OSes -- this is a fast + // way to exclude Windows. + $RandomCompatUrandom = \true; + $RandomCompat_basedir = \ini_get('open_basedir'); + if (!empty($RandomCompat_basedir)) { + $RandomCompat_open_basedir = \explode(\PATH_SEPARATOR, \strtolower($RandomCompat_basedir)); + $RandomCompatUrandom = array() !== \array_intersect(array('/dev', '/dev/', '/dev/urandom'), $RandomCompat_open_basedir); + $RandomCompat_open_basedir = null; + } + if (!\is_callable('random_bytes') && $RandomCompatUrandom && @\is_readable('/dev/urandom')) { + // Error suppression on is_readable() in case of an open_basedir + // or safe_mode failure. All we care about is whether or not we + // can read it at this point. If the PHP environment is going to + // panic over trying to see if the file can be read in the first + // place, that is not helpful to us here. + // See random_bytes_dev_urandom.php + require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_bytes_dev_urandom.php'; + } + // Unset variables after use + $RandomCompat_basedir = null; + } else { + $RandomCompatUrandom = \false; + } + /** + * mcrypt_create_iv() + * + * We only want to use mcypt_create_iv() if: + * + * - random_bytes() hasn't already been defined + * - the mcrypt extensions is loaded + * - One of these two conditions is true: + * - We're on Windows (DIRECTORY_SEPARATOR !== '/') + * - We're not on Windows and /dev/urandom is readabale + * (i.e. we're not in a chroot jail) + * - Special case: + * - If we're not on Windows, but the PHP version is between + * 5.6.10 and 5.6.12, we don't want to use mcrypt. It will + * hang indefinitely. This is bad. + * - If we're on Windows, we want to use PHP >= 5.3.7 or else + * we get insufficient entropy errors. + */ + if (!\is_callable('random_bytes') && (\DIRECTORY_SEPARATOR === '/' || \PHP_VERSION_ID >= 50307) && (\DIRECTORY_SEPARATOR !== '/' || (\PHP_VERSION_ID <= 50609 || \PHP_VERSION_ID >= 50613)) && \extension_loaded('mcrypt')) { + // See random_bytes_mcrypt.php + require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_bytes_mcrypt.php'; + } + $RandomCompatUrandom = null; + /** + * This is a Windows-specific fallback, for when the mcrypt extension + * isn't loaded. + */ + if (!\is_callable('random_bytes') && \extension_loaded('com_dotnet') && \class_exists('_PhpScoper5ea00cc67502b\\COM')) { + $RandomCompat_disabled_classes = \preg_split('#\\s*,\\s*#', \strtolower(\ini_get('disable_classes'))); + if (!\in_array('com', $RandomCompat_disabled_classes)) { + try { + $RandomCompatCOMtest = new \_PhpScoper5ea00cc67502b\COM('CAPICOM.Utilities.1'); + if (\method_exists($RandomCompatCOMtest, 'GetRandom')) { + // See random_bytes_com_dotnet.php + require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_bytes_com_dotnet.php'; + } + } catch (\_PhpScoper5ea00cc67502b\com_exception $e) { + // Don't try to use it. + } + } + $RandomCompat_disabled_classes = null; + $RandomCompatCOMtest = null; + } + /** + * throw new Exception + */ + if (!\is_callable('random_bytes')) { + /** + * We don't have any more options, so let's throw an exception right now + * and hope the developer won't let it fail silently. + * + * @param mixed $length + * @psalm-suppress InvalidReturnType + * @throws Exception + * @return string + */ + function random_bytes($length) + { + unset($length); + // Suppress "variable not used" warnings. + throw new \Exception('There is no suitable CSPRNG installed on your system'); + return ''; + } + } +} +if (!\is_callable('random_int')) { + require_once $RandomCompatDIR . \DIRECTORY_SEPARATOR . 'random_int.php'; +} +$RandomCompatDIR = null; diff --git a/vendor/paragonie/random_compat/lib/random_bytes_com_dotnet.php b/vendor/paragonie/random_compat/lib/random_bytes_com_dotnet.php index e7d50acad..eb829fc86 100644 --- a/vendor/paragonie/random_compat/lib/random_bytes_com_dotnet.php +++ b/vendor/paragonie/random_compat/lib/random_bytes_com_dotnet.php @@ -1,81 +1,81 @@ -GetRandom($bytes, 0)); - if (\_PhpScoper5ea00cc67502b\RandomCompat_strlen($buf) >= $bytes) { - /** - * Return our random entropy buffer here: - */ - return (string) \_PhpScoper5ea00cc67502b\RandomCompat_substr($buf, 0, $bytes); - } - ++$execCount; - } while ($execCount < $bytes); - /** - * If we reach here, PHP has failed us. - */ - throw new \Exception('Could not gather sufficient random data'); - } -} +GetRandom($bytes, 0)); + if (\_PhpScoper5ea00cc67502b\RandomCompat_strlen($buf) >= $bytes) { + /** + * Return our random entropy buffer here: + */ + return (string) \_PhpScoper5ea00cc67502b\RandomCompat_substr($buf, 0, $bytes); + } + ++$execCount; + } while ($execCount < $bytes); + /** + * If we reach here, PHP has failed us. + */ + throw new \Exception('Could not gather sufficient random data'); + } +} diff --git a/vendor/paragonie/random_compat/lib/random_bytes_dev_urandom.php b/vendor/paragonie/random_compat/lib/random_bytes_dev_urandom.php index 690c62f09..bbf2c5386 100644 --- a/vendor/paragonie/random_compat/lib/random_bytes_dev_urandom.php +++ b/vendor/paragonie/random_compat/lib/random_bytes_dev_urandom.php @@ -1,173 +1,173 @@ - $st */ -// $st = \fstat($fp); -// if (($st['mode'] & 0170000) !== 020000) { -// \fclose($fp); -// $fp = \false; -// } -// } -// } -// if (\is_resource($fp)) { -// /** -// * stream_set_read_buffer() does not exist in HHVM -// * -// * If we don't set the stream's read buffer to 0, PHP will -// * internally buffer 8192 bytes, which can waste entropy -// * -// * stream_set_read_buffer returns 0 on success -// */ -// if (\is_callable('stream_set_read_buffer')) { -// \stream_set_read_buffer($fp, \RANDOM_COMPAT_READ_BUFFER); -// } -// if (\is_callable('stream_set_chunk_size')) { -// \stream_set_chunk_size($fp, \RANDOM_COMPAT_READ_BUFFER); -// } -// } -// } -// try { -// /** @var int $bytes */ -// $bytes = \_PhpScoper5ea00cc67502b\RandomCompat_intval($bytes); -// } catch (\TypeError $ex) { -// throw new \TypeError('random_bytes(): $bytes must be an integer'); -// } -// if ($bytes < 1) { -// throw new \Error('Length must be greater than 0'); -// } -// /** -// * This if() block only runs if we managed to open a file handle -// * -// * It does not belong in an else {} block, because the above -// * if (empty($fp)) line is logic that should only be run once per -// * page load. -// */ -// if (\is_resource($fp)) { -// /** -// * @var int -// */ -// $remaining = $bytes; -// /** -// * @var string|bool -// */ -// $buf = ''; -// /** -// * We use fread() in a loop to protect against partial reads -// */ -// do { -// /** -// * @var string|bool -// */ -// $read = \fread($fp, $remaining); -// if (!\is_string($read)) { -// /** -// * We cannot safely read from the file. Exit the -// * do-while loop and trigger the exception condition -// * -// * @var string|bool -// */ -// $buf = \false; -// break; -// } -// /** -// * Decrease the number of bytes returned from remaining -// */ -// $remaining -= \_PhpScoper5ea00cc67502b\RandomCompat_strlen($read); -// /** -// * @var string $buf -// */ -// $buf .= $read; -// } while ($remaining > 0); -// /** -// * Is our result valid? -// * @var string|bool $buf -// */ -// if (\is_string($buf)) { -// if (\_PhpScoper5ea00cc67502b\RandomCompat_strlen($buf) === $bytes) { -// /** -// * Return our random entropy buffer here: -// */ -// return $buf; -// } -// } -// } -// /** -// * If we reach here, PHP has failed us. -// */ -// throw new \Exception('Error reading from source device'); -// } -//} + $st */ +// $st = \fstat($fp); +// if (($st['mode'] & 0170000) !== 020000) { +// \fclose($fp); +// $fp = \false; +// } +// } +// } +// if (\is_resource($fp)) { +// /** +// * stream_set_read_buffer() does not exist in HHVM +// * +// * If we don't set the stream's read buffer to 0, PHP will +// * internally buffer 8192 bytes, which can waste entropy +// * +// * stream_set_read_buffer returns 0 on success +// */ +// if (\is_callable('stream_set_read_buffer')) { +// \stream_set_read_buffer($fp, \RANDOM_COMPAT_READ_BUFFER); +// } +// if (\is_callable('stream_set_chunk_size')) { +// \stream_set_chunk_size($fp, \RANDOM_COMPAT_READ_BUFFER); +// } +// } +// } +// try { +// /** @var int $bytes */ +// $bytes = \_PhpScoper5ea00cc67502b\RandomCompat_intval($bytes); +// } catch (\TypeError $ex) { +// throw new \TypeError('random_bytes(): $bytes must be an integer'); +// } +// if ($bytes < 1) { +// throw new \Error('Length must be greater than 0'); +// } +// /** +// * This if() block only runs if we managed to open a file handle +// * +// * It does not belong in an else {} block, because the above +// * if (empty($fp)) line is logic that should only be run once per +// * page load. +// */ +// if (\is_resource($fp)) { +// /** +// * @var int +// */ +// $remaining = $bytes; +// /** +// * @var string|bool +// */ +// $buf = ''; +// /** +// * We use fread() in a loop to protect against partial reads +// */ +// do { +// /** +// * @var string|bool +// */ +// $read = \fread($fp, $remaining); +// if (!\is_string($read)) { +// /** +// * We cannot safely read from the file. Exit the +// * do-while loop and trigger the exception condition +// * +// * @var string|bool +// */ +// $buf = \false; +// break; +// } +// /** +// * Decrease the number of bytes returned from remaining +// */ +// $remaining -= \_PhpScoper5ea00cc67502b\RandomCompat_strlen($read); +// /** +// * @var string $buf +// */ +// $buf .= $read; +// } while ($remaining > 0); +// /** +// * Is our result valid? +// * @var string|bool $buf +// */ +// if (\is_string($buf)) { +// if (\_PhpScoper5ea00cc67502b\RandomCompat_strlen($buf) === $bytes) { +// /** +// * Return our random entropy buffer here: +// */ +// return $buf; +// } +// } +// } +// /** +// * If we reach here, PHP has failed us. +// */ +// throw new \Exception('Error reading from source device'); +// } +//} diff --git a/vendor/paragonie/random_compat/lib/random_bytes_libsodium.php b/vendor/paragonie/random_compat/lib/random_bytes_libsodium.php index b57fc1c87..c3cd77603 100644 --- a/vendor/paragonie/random_compat/lib/random_bytes_libsodium.php +++ b/vendor/paragonie/random_compat/lib/random_bytes_libsodium.php @@ -1,81 +1,81 @@ - 2147483647) { - $buf = ''; - for ($i = 0; $i < $bytes; $i += 1073741824) { - $n = $bytes - $i > 1073741824 ? 1073741824 : $bytes - $i; - $buf .= \_PhpScoper5ea00cc67502b\Sodium\randombytes_buf($n); - } - } else { - /** @var string|bool $buf */ - $buf = \_PhpScoper5ea00cc67502b\Sodium\randombytes_buf($bytes); - } - if (\is_string($buf)) { - if (\_PhpScoper5ea00cc67502b\RandomCompat_strlen($buf) === $bytes) { - return $buf; - } - } - /** - * If we reach here, PHP has failed us. - */ - throw new \Exception('Could not gather sufficient random data'); - } -} + 2147483647) { + $buf = ''; + for ($i = 0; $i < $bytes; $i += 1073741824) { + $n = $bytes - $i > 1073741824 ? 1073741824 : $bytes - $i; + $buf .= \_PhpScoper5ea00cc67502b\Sodium\randombytes_buf($n); + } + } else { + /** @var string|bool $buf */ + $buf = \_PhpScoper5ea00cc67502b\Sodium\randombytes_buf($bytes); + } + if (\is_string($buf)) { + if (\_PhpScoper5ea00cc67502b\RandomCompat_strlen($buf) === $bytes) { + return $buf; + } + } + /** + * If we reach here, PHP has failed us. + */ + throw new \Exception('Could not gather sufficient random data'); + } +} diff --git a/vendor/paragonie/random_compat/lib/random_bytes_libsodium_legacy.php b/vendor/paragonie/random_compat/lib/random_bytes_libsodium_legacy.php index 04e9ac737..165546d15 100644 --- a/vendor/paragonie/random_compat/lib/random_bytes_libsodium_legacy.php +++ b/vendor/paragonie/random_compat/lib/random_bytes_libsodium_legacy.php @@ -1,82 +1,82 @@ - 2147483647) { - for ($i = 0; $i < $bytes; $i += 1073741824) { - $n = $bytes - $i > 1073741824 ? 1073741824 : $bytes - $i; - $buf .= \_PhpScoper5ea00cc67502b\Sodium::randombytes_buf((int) $n); - } - } else { - $buf .= \_PhpScoper5ea00cc67502b\Sodium::randombytes_buf((int) $bytes); - } - if (\is_string($buf)) { - if (\_PhpScoper5ea00cc67502b\RandomCompat_strlen($buf) === $bytes) { - return $buf; - } - } - /** - * If we reach here, PHP has failed us. - */ - throw new \Exception('Could not gather sufficient random data'); - } -} + 2147483647) { + for ($i = 0; $i < $bytes; $i += 1073741824) { + $n = $bytes - $i > 1073741824 ? 1073741824 : $bytes - $i; + $buf .= \_PhpScoper5ea00cc67502b\Sodium::randombytes_buf((int) $n); + } + } else { + $buf .= \_PhpScoper5ea00cc67502b\Sodium::randombytes_buf((int) $bytes); + } + if (\is_string($buf)) { + if (\_PhpScoper5ea00cc67502b\RandomCompat_strlen($buf) === $bytes) { + return $buf; + } + } + /** + * If we reach here, PHP has failed us. + */ + throw new \Exception('Could not gather sufficient random data'); + } +} diff --git a/vendor/paragonie/random_compat/lib/random_bytes_mcrypt.php b/vendor/paragonie/random_compat/lib/random_bytes_mcrypt.php index 47e47b46a..049ff8327 100644 --- a/vendor/paragonie/random_compat/lib/random_bytes_mcrypt.php +++ b/vendor/paragonie/random_compat/lib/random_bytes_mcrypt.php @@ -1,68 +1,68 @@ - operators might accidentally let a float - * through. - */ - try { - /** @var int $min */ - $min = \_PhpScoper5ea00cc67502b\RandomCompat_intval($min); - } catch (\TypeError $ex) { - throw new \TypeError('random_int(): $min must be an integer'); - } - try { - /** @var int $max */ - $max = \_PhpScoper5ea00cc67502b\RandomCompat_intval($max); - } catch (\TypeError $ex) { - throw new \TypeError('random_int(): $max must be an integer'); - } - /** - * Now that we've verified our weak typing system has given us an integer, - * let's validate the logic then we can move forward with generating random - * integers along a given range. - */ - if ($min > $max) { - throw new \Error('Minimum value must be less than or equal to the maximum value'); - } - if ($max === $min) { - return (int) $min; - } - /** - * Initialize variables to 0 - * - * We want to store: - * $bytes => the number of random bytes we need - * $mask => an integer bitmask (for use with the &) operator - * so we can minimize the number of discards - */ - $attempts = $bits = $bytes = $mask = $valueShift = 0; - /** @var int $attempts */ - /** @var int $bits */ - /** @var int $bytes */ - /** @var int $mask */ - /** @var int $valueShift */ - /** - * At this point, $range is a positive number greater than 0. It might - * overflow, however, if $max - $min > PHP_INT_MAX. PHP will cast it to - * a float and we will lose some precision. - * - * @var int|float $range - */ - $range = $max - $min; - /** - * Test for integer overflow: - */ - if (!\is_int($range)) { - /** - * Still safely calculate wider ranges. - * Provided by @CodesInChaos, @oittaa - * - * @ref https://gist.github.com/CodesInChaos/03f9ea0b58e8b2b8d435 - * - * We use ~0 as a mask in this case because it generates all 1s - * - * @ref https://eval.in/400356 (32-bit) - * @ref http://3v4l.org/XX9r5 (64-bit) - */ - $bytes = \PHP_INT_SIZE; - /** @var int $mask */ - $mask = ~0; - } else { - /** - * $bits is effectively ceil(log($range, 2)) without dealing with - * type juggling - */ - while ($range > 0) { - if ($bits % 8 === 0) { - ++$bytes; - } - ++$bits; - $range >>= 1; - /** @var int $mask */ - $mask = $mask << 1 | 1; - } - $valueShift = $min; - } - /** @var int $val */ - $val = 0; - /** - * Now that we have our parameters set up, let's begin generating - * random integers until one falls between $min and $max - */ - /** @psalm-suppress RedundantCondition */ - do { - /** - * The rejection probability is at most 0.5, so this corresponds - * to a failure probability of 2^-128 for a working RNG - */ - if ($attempts > 128) { - throw new \Exception('random_int: RNG is broken - too many rejections'); - } - /** - * Let's grab the necessary number of random bytes - */ - $randomByteString = \random_bytes($bytes); - /** - * Let's turn $randomByteString into an integer - * - * This uses bitwise operators (<< and |) to build an integer - * out of the values extracted from ord() - * - * Example: [9F] | [6D] | [32] | [0C] => - * 159 + 27904 + 3276800 + 201326592 => - * 204631455 - */ - $val &= 0; - for ($i = 0; $i < $bytes; ++$i) { - $val |= \ord($randomByteString[$i]) << $i * 8; - } - /** @var int $val */ - /** - * Apply mask - */ - $val &= $mask; - $val += $valueShift; - ++$attempts; - /** - * If $val overflows to a floating point number, - * ... or is larger than $max, - * ... or smaller than $min, - * then try again. - */ - } while (!\is_int($val) || $val > $max || $val < $min); - return (int) $val; - } -} + operators might accidentally let a float + * through. + */ + try { + /** @var int $min */ + $min = \_PhpScoper5ea00cc67502b\RandomCompat_intval($min); + } catch (\TypeError $ex) { + throw new \TypeError('random_int(): $min must be an integer'); + } + try { + /** @var int $max */ + $max = \_PhpScoper5ea00cc67502b\RandomCompat_intval($max); + } catch (\TypeError $ex) { + throw new \TypeError('random_int(): $max must be an integer'); + } + /** + * Now that we've verified our weak typing system has given us an integer, + * let's validate the logic then we can move forward with generating random + * integers along a given range. + */ + if ($min > $max) { + throw new \Error('Minimum value must be less than or equal to the maximum value'); + } + if ($max === $min) { + return (int) $min; + } + /** + * Initialize variables to 0 + * + * We want to store: + * $bytes => the number of random bytes we need + * $mask => an integer bitmask (for use with the &) operator + * so we can minimize the number of discards + */ + $attempts = $bits = $bytes = $mask = $valueShift = 0; + /** @var int $attempts */ + /** @var int $bits */ + /** @var int $bytes */ + /** @var int $mask */ + /** @var int $valueShift */ + /** + * At this point, $range is a positive number greater than 0. It might + * overflow, however, if $max - $min > PHP_INT_MAX. PHP will cast it to + * a float and we will lose some precision. + * + * @var int|float $range + */ + $range = $max - $min; + /** + * Test for integer overflow: + */ + if (!\is_int($range)) { + /** + * Still safely calculate wider ranges. + * Provided by @CodesInChaos, @oittaa + * + * @ref https://gist.github.com/CodesInChaos/03f9ea0b58e8b2b8d435 + * + * We use ~0 as a mask in this case because it generates all 1s + * + * @ref https://eval.in/400356 (32-bit) + * @ref http://3v4l.org/XX9r5 (64-bit) + */ + $bytes = \PHP_INT_SIZE; + /** @var int $mask */ + $mask = ~0; + } else { + /** + * $bits is effectively ceil(log($range, 2)) without dealing with + * type juggling + */ + while ($range > 0) { + if ($bits % 8 === 0) { + ++$bytes; + } + ++$bits; + $range >>= 1; + /** @var int $mask */ + $mask = $mask << 1 | 1; + } + $valueShift = $min; + } + /** @var int $val */ + $val = 0; + /** + * Now that we have our parameters set up, let's begin generating + * random integers until one falls between $min and $max + */ + /** @psalm-suppress RedundantCondition */ + do { + /** + * The rejection probability is at most 0.5, so this corresponds + * to a failure probability of 2^-128 for a working RNG + */ + if ($attempts > 128) { + throw new \Exception('random_int: RNG is broken - too many rejections'); + } + /** + * Let's grab the necessary number of random bytes + */ + $randomByteString = \random_bytes($bytes); + /** + * Let's turn $randomByteString into an integer + * + * This uses bitwise operators (<< and |) to build an integer + * out of the values extracted from ord() + * + * Example: [9F] | [6D] | [32] | [0C] => + * 159 + 27904 + 3276800 + 201326592 => + * 204631455 + */ + $val &= 0; + for ($i = 0; $i < $bytes; ++$i) { + $val |= \ord($randomByteString[$i]) << $i * 8; + } + /** @var int $val */ + /** + * Apply mask + */ + $val &= $mask; + $val += $valueShift; + ++$attempts; + /** + * If $val overflows to a floating point number, + * ... or is larger than $max, + * ... or smaller than $min, + * then try again. + */ + } while (!\is_int($val) || $val > $max || $val < $min); + return (int) $val; + } +} diff --git a/vendor/prestashop/decimal/.gitignore b/vendor/prestashop/decimal/.gitignore index 859e49159..a70aed174 100644 --- a/vendor/prestashop/decimal/.gitignore +++ b/vendor/prestashop/decimal/.gitignore @@ -1,35 +1,35 @@ -# IntelliJ - PhpStorm and PyCharm -.idea -*.iml -*.ipr -*.iws - -# Netbeans -nbproject -.nbproject -.nbproject/* -nbproject/* -nbproject/private/ -build/ -nbbuild/ -dist/ -nbdist/ -nbactions.xml -nb-configuration.xml - -# Mac OSX -.DS_Store -# Thumbnails -._* -# Files that might appear on external disk -.Spotlight-V100 -.Trashes - -# SublimeText project files -/*.sublime-project -*.sublime-workspace - -build -composer.lock -docs +# IntelliJ - PhpStorm and PyCharm +.idea +*.iml +*.ipr +*.iws + +# Netbeans +nbproject +.nbproject +.nbproject/* +nbproject/* +nbproject/private/ +build/ +nbbuild/ +dist/ +nbdist/ +nbactions.xml +nb-configuration.xml + +# Mac OSX +.DS_Store +# Thumbnails +._* +# Files that might appear on external disk +.Spotlight-V100 +.Trashes + +# SublimeText project files +/*.sublime-project +*.sublime-workspace + +build +composer.lock +docs vendor \ No newline at end of file diff --git a/vendor/prestashop/decimal/.travis.yml b/vendor/prestashop/decimal/.travis.yml index b12708ed6..058d02177 100644 --- a/vendor/prestashop/decimal/.travis.yml +++ b/vendor/prestashop/decimal/.travis.yml @@ -1,21 +1,21 @@ -dist: trusty - -language: php - -php: - - 5.4 - - 5.5 - - 5.6 - - 7.0 - - 7.1 - - 7.2 - - 7.3 - -before_script: - - travis_retry composer install --no-interaction - -script: - - vendor/bin/phpunit --coverage-text - -after_script: - - php vendor/bin/codacycoverage clover build/clover.xml +dist: trusty + +language: php + +php: + - 5.4 + - 5.5 + - 5.6 + - 7.0 + - 7.1 + - 7.2 + - 7.3 + +before_script: + - travis_retry composer install --no-interaction + +script: + - vendor/bin/phpunit --coverage-text + +after_script: + - php vendor/bin/codacycoverage clover build/clover.xml diff --git a/vendor/prestashop/decimal/CONTRIBUTING.md b/vendor/prestashop/decimal/CONTRIBUTING.md index ba3452a67..ed58b049f 100644 --- a/vendor/prestashop/decimal/CONTRIBUTING.md +++ b/vendor/prestashop/decimal/CONTRIBUTING.md @@ -1,35 +1,35 @@ -# Contributing - -Contributions are **welcome** and will be fully **credited**. - -We accept contributions via Pull Requests on [Github](https://github.com/prestashop/decimal). - -## Compatibility - -Decimal is compatible with PHP >= 5.4. Please don't break backwards compatibility :) - -## Pull Requests - -- **[PSR-2 Coding Standard](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md)** - The easiest way to apply the conventions is to install [PHP Code Sniffer](http://pear.php.net/package/PHP_CodeSniffer). - -- **Add tests!** - Your patch won't be accepted if it doesn't have tests. - -- **Document any change in behaviour** - Make sure the `README.md` and any other relevant documentation are kept up-to-date. - -- **Consider our release cycle** - We try to follow [SemVer v2.0.0](http://semver.org/). Randomly breaking public APIs is not an option. - -- **Create feature branches** - Don't ask us to pull from your master branch. - -- **One pull request per feature** - If you want to do more than one thing, send multiple pull requests. - -- **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please squash them before submitting. - - -## Running Tests - -``` bash -$ vendor/bin/phpunit -``` - - -**Happy coding**! +# Contributing + +Contributions are **welcome** and will be fully **credited**. + +We accept contributions via Pull Requests on [Github](https://github.com/prestashop/decimal). + +## Compatibility + +Decimal is compatible with PHP >= 5.4. Please don't break backwards compatibility :) + +## Pull Requests + +- **[PSR-2 Coding Standard](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md)** - The easiest way to apply the conventions is to install [PHP Code Sniffer](http://pear.php.net/package/PHP_CodeSniffer). + +- **Add tests!** - Your patch won't be accepted if it doesn't have tests. + +- **Document any change in behaviour** - Make sure the `README.md` and any other relevant documentation are kept up-to-date. + +- **Consider our release cycle** - We try to follow [SemVer v2.0.0](http://semver.org/). Randomly breaking public APIs is not an option. + +- **Create feature branches** - Don't ask us to pull from your master branch. + +- **One pull request per feature** - If you want to do more than one thing, send multiple pull requests. + +- **Send coherent history** - Make sure each individual commit in your pull request is meaningful. If you had to make multiple intermediate commits while developing, please squash them before submitting. + + +## Running Tests + +``` bash +$ vendor/bin/phpunit +``` + + +**Happy coding**! diff --git a/vendor/prestashop/decimal/LICENSE.md b/vendor/prestashop/decimal/LICENSE.md index f0054ab30..35d779051 100644 --- a/vendor/prestashop/decimal/LICENSE.md +++ b/vendor/prestashop/decimal/LICENSE.md @@ -1,21 +1,21 @@ -# The MIT License (MIT) - -Copyright (c) 2017 PrestaShop - -> Permission is hereby granted, free of charge, to any person obtaining a copy -> of this software and associated documentation files (the "Software"), to deal -> in the Software without restriction, including without limitation the rights -> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -> copies of the Software, and to permit persons to whom the Software is -> furnished to do so, subject to the following conditions: -> -> The above copyright notice and this permission notice shall be included in -> all copies or substantial portions of the Software. -> -> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -> THE SOFTWARE. +# The MIT License (MIT) + +Copyright (c) 2017 PrestaShop + +> Permission is hereby granted, free of charge, to any person obtaining a copy +> of this software and associated documentation files (the "Software"), to deal +> in the Software without restriction, including without limitation the rights +> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +> copies of the Software, and to permit persons to whom the Software is +> furnished to do so, subject to the following conditions: +> +> The above copyright notice and this permission notice shall be included in +> all copies or substantial portions of the Software. +> +> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +> THE SOFTWARE. diff --git a/vendor/prestashop/decimal/README.md b/vendor/prestashop/decimal/README.md index 4b8ba7fe4..84702a09c 100644 --- a/vendor/prestashop/decimal/README.md +++ b/vendor/prestashop/decimal/README.md @@ -1,288 +1,288 @@ -# Decimal - -[![Build Status](https://api.travis-ci.org/PrestaShop/decimal.svg?branch=master)](https://travis-ci.org/PrestaShop/decimal) -[![Codacy Badge](https://api.codacy.com/project/badge/Grade/985899efeb83453babcc507def66c90e)](https://www.codacy.com/app/PrestaShop/decimal?utm_source=github.com&utm_medium=referral&utm_content=PrestaShop/decimal&utm_campaign=Badge_Grade) -[![Codacy Badge](https://api.codacy.com/project/badge/Coverage/985899efeb83453babcc507def66c90e)](https://www.codacy.com/app/PrestaShop/decimal?utm_source=github.com&utm_medium=referral&utm_content=PrestaShop/decimal&utm_campaign=Badge_Coverage) -[![Total Downloads](https://img.shields.io/packagist/dt/prestashop/decimal.svg?style=flat-square)](https://packagist.org/packages/prestashop/decimal) - -An object-oriented [BC Math extension](http://php.net/manual/en/book.bc.php) wrapper/shim. - -**Decimal** offers a stateless, fluent object-oriented implementation of basic arbitrary-precision arithmetic, using BC Math if available. - -You can find out more about floating point precision [here](http://php.net/float). - -Example: -```php -use PrestaShop\Decimal\Number; -use PrestaShop\Decimal\Operation\Rounding; - -echo (new Number('0.1')) - ->plus(new Number('0.7')) - ->times(new Number('10')) - ->round(0, Rounding::ROUND_FLOOR) - -// echoes '8' -``` - -## Install - -Via Composer - -``` bash -$ composer require prestashop/decimal -``` - -## Usage reference - -Quick links: -- [Instantiation](#instantiation) -- [Addition](#addition) -- [Subtraction](#subtraction) -- [Multiplication](#multiplication) -- [Division](#division) -- [Comparison](#comparison) -- [Fixed precision](#fixed-precision) -- [Rounding](#rounding) -- [Dot shifting](#dot-shifting) -- [Useful methods](#useful-methods) - -### Instantiation -Creates a new Decimal number. -```php -public Number Number::__construct ( string $number [, int $exponent = null ] ) -``` -There are two ways to instantiate a Decimal\Number: -``` php -// create a number from string -$number = new PrestaShop\Decimal\Number('123.456'); -echo $number; // echoes '123.456' -``` -``` php -// exponent notation -$number = new PrestaShop\Decimal\Number('123456', -3); -echo $number; // echoes '123.456' -``` - -### Addition -Returns the computed result of adding another number to the current one. -```php -public Number Number::plus ( Number $addend ) -``` -Examples: -```php -$a = new PrestaShop\Decimal\Number('123.456'); -$b = new PrestaShop\Decimal\Number('654.321'); - -echo $a->plus($b); // echoes '777.777' -``` - -### Subtraction -Returns the computed result of subtracting another number to the current one. -```php -public Number Number::minus ( Number $subtrahend ) -``` -Examples: -```php -$a = new PrestaShop\Decimal\Number('777.777'); -$b = new PrestaShop\Decimal\Number('654.321'); - -echo $a->minus($b); // echoes '123.456' -``` - -### Multiplication -Returns the computed result of multiplying the current number with another one. -```php -public Number Number::times ( Number $factor ) -``` -Examples: -```php -$a = new PrestaShop\Decimal\Number('777.777'); -$b = new PrestaShop\Decimal\Number('654.321'); - -echo $a->times($b); // echoes '508915.824417' -``` - -### Division -Returns the computed result of dividing the current number by another one, with up to a certain number of decimal positions (6 by default). -```php -public Number Number::dividedBy ( Number $divisor [, int $precision = Operation\Division::DEFAULT_PRECISION ] ) -``` -Examples: -```php -$a = new PrestaShop\Decimal\Number('777.777'); -$b = new PrestaShop\Decimal\Number('654.321'); - -echo $a->dividedBy($b, 0); // echoes '1' -echo $a->dividedBy($b, 5); // echoes '1.18867' -echo $a->dividedBy($b, 10); // echoes '1.1886780341' -echo $a->dividedBy($b, 15); // echoes '1.188678034175886' -``` - -### Comparison -Returns the result of the comparison assertion. -```php -$a = new PrestaShop\Decimal\Number('777.777'); -$b = new PrestaShop\Decimal\Number('654.321'); - -$a->equals($b); // returns false -$a->isLowerThan($b); // returns false -$a->isLowerOrEqualThan($b); // returns false -$a->isGreaterThan($b); // returns true -$a->isGreaterOrEqualThan($b); // returns true - -// shortcut methods -$a->equalsZero(); // returns false -$a->isLowerThanZero(); // returns false -$a->isLowerOrEqualThanZero(); // returns false -$a->isGreaterThanZero(); // returns true -$a->isGreaterOrEqualThanZero(); // returns true -``` - -### Fixed precision -Returns the number as a string, optionally rounded, with an exact number of decimal positions. -```php -public string Number::toPrecision ( int $precision [, string $roundingMode = Rounding::ROUND_TRUNCATE ] ) -``` -Examples: -```php -$a = new PrestaShop\Decimal\Number('123.456'); -$a = new PrestaShop\Decimal\Number('-123.456'); - -// truncate / pad -$a->toPrecision(0); // '123' -$a->toPrecision(1); // '123.4' -$a->toPrecision(2); // '123.45' -$a->toPrecision(3); // '123.456' -$a->toPrecision(4); // '123.4560' -$b->toPrecision(0); // '-123' -$b->toPrecision(1); // '-123.4' -$b->toPrecision(2); // '-123.45' -$b->toPrecision(3); // '-123.456' -$b->toPrecision(4); // '-123.4560' - -// ceil (round up) -$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '124' -$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '123.5' -$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '123.46' -$b->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '-122' -$b->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '-123.3' -$b->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '-123.44' - -// floor (round down) -$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '123' -$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '123.4' -$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '123.45' -$b->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '-124' -$b->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '-123.5' -$b->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '-123.46' - -// half-up (symmetric half-up) -$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '123' -$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '123.5' -$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '123.46' -$b->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '-123' -$b->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '-123.5' -$b->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '-123.46' - -// half-down (symmetric half-down) -$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '123' -$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '123.4' -$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '123.46' -$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '-123' -$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '-123.4' -$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '-123.46' - -// half-even -$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '123' -$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '123.4' -$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '123.46' -$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '-123' -$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '-123.4' -$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '-123.46' - -$a = new Decimal\Number('1.1525354556575859505'); -$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1' -$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.2' -$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.15' -$a->toPrecision(3, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.152' -$a->toPrecision(4, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.1525' -$a->toPrecision(5, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.15255' -$a->toPrecision(6, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.152535' -$a->toPrecision(7, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.1525354' -$a->toPrecision(8, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.15253546' -$a->toPrecision(9, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.152535456' -$a->toPrecision(10, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.1525354556' -``` - -### Rounding -Rounding behaves like `toPrecision`, but provides "up to" a certain number of decimal positions -(it does not add trailing zeroes). -```php -public string Number::round ( int $maxDecimals [, string $roundingMode = Rounding::ROUND_TRUNCATE ] ) -``` -Examples: -```php -$a = new PrestaShop\Decimal\Number('123.456'); -$a = new PrestaShop\Decimal\Number('-123.456'); - -// truncate / pad -$a->round(0); // '123' -$a->round(1); // '123.4' -$a->round(2); // '123.45' -$a->round(3); // '123.456' -$a->round(4); // '123.456' -$b->round(0); // '-123' -$b->round(1); // '-123.4' -$b->round(2); // '-123.45' -$b->round(3); // '-123.456' -$b->round(4); // '-123.456' -``` - -### Dot shifting -Creates a new copy of this number multiplied by 10^exponent -```php -public Number Number::toMagnitude ( int $exponent ) -``` -Examples: -```php -$a = new Decimal\Number('123.456789'); - -// shift 3 digits to the left -$a->toMagnitude(-3); // 0.123456789 - -// shift 3 digits to the right -$a->toMagnitude(3); // 123456.789 -``` - -### Useful methods -```php -$number = new PrestaShop\Decimal\Number('123.45'); -$number->getIntegerPart(); // '123' -$number->getFractionalPart(); // '45' -$number->getPrecision(); // '2' (number of decimals) -$number->getSign(); // '' ('-' if the number was negative) -$number->getExponent(); // '2' (always positive) -$number->getCoefficient(); // '123456' -$number->isPositive(); // true -$number->isNegative(); // false -$number->invert(); // new Decimal\Number('-123.45') -``` - -## Testing - -``` bash -$ composer install -$ vendor/bin/phpunit -``` - -## Contributing - -Please see [CONTRIBUTING](CONTRIBUTING.md) for details. - -## Credits - -- [All Contributors](https://github.com/prestashop/decimal/contributors) - -## License - -The MIT License (MIT). Please see [License File](LICENSE.md) for more information. +# Decimal + +[![Build Status](https://api.travis-ci.org/PrestaShop/decimal.svg?branch=master)](https://travis-ci.org/PrestaShop/decimal) +[![Codacy Badge](https://api.codacy.com/project/badge/Grade/985899efeb83453babcc507def66c90e)](https://www.codacy.com/app/PrestaShop/decimal?utm_source=github.com&utm_medium=referral&utm_content=PrestaShop/decimal&utm_campaign=Badge_Grade) +[![Codacy Badge](https://api.codacy.com/project/badge/Coverage/985899efeb83453babcc507def66c90e)](https://www.codacy.com/app/PrestaShop/decimal?utm_source=github.com&utm_medium=referral&utm_content=PrestaShop/decimal&utm_campaign=Badge_Coverage) +[![Total Downloads](https://img.shields.io/packagist/dt/prestashop/decimal.svg?style=flat-square)](https://packagist.org/packages/prestashop/decimal) + +An object-oriented [BC Math extension](http://php.net/manual/en/book.bc.php) wrapper/shim. + +**Decimal** offers a stateless, fluent object-oriented implementation of basic arbitrary-precision arithmetic, using BC Math if available. + +You can find out more about floating point precision [here](http://php.net/float). + +Example: +```php +use PrestaShop\Decimal\Number; +use PrestaShop\Decimal\Operation\Rounding; + +echo (new Number('0.1')) + ->plus(new Number('0.7')) + ->times(new Number('10')) + ->round(0, Rounding::ROUND_FLOOR) + +// echoes '8' +``` + +## Install + +Via Composer + +``` bash +$ composer require prestashop/decimal +``` + +## Usage reference + +Quick links: +- [Instantiation](#instantiation) +- [Addition](#addition) +- [Subtraction](#subtraction) +- [Multiplication](#multiplication) +- [Division](#division) +- [Comparison](#comparison) +- [Fixed precision](#fixed-precision) +- [Rounding](#rounding) +- [Dot shifting](#dot-shifting) +- [Useful methods](#useful-methods) + +### Instantiation +Creates a new Decimal number. +```php +public Number Number::__construct ( string $number [, int $exponent = null ] ) +``` +There are two ways to instantiate a Decimal\Number: +``` php +// create a number from string +$number = new PrestaShop\Decimal\Number('123.456'); +echo $number; // echoes '123.456' +``` +``` php +// exponent notation +$number = new PrestaShop\Decimal\Number('123456', -3); +echo $number; // echoes '123.456' +``` + +### Addition +Returns the computed result of adding another number to the current one. +```php +public Number Number::plus ( Number $addend ) +``` +Examples: +```php +$a = new PrestaShop\Decimal\Number('123.456'); +$b = new PrestaShop\Decimal\Number('654.321'); + +echo $a->plus($b); // echoes '777.777' +``` + +### Subtraction +Returns the computed result of subtracting another number to the current one. +```php +public Number Number::minus ( Number $subtrahend ) +``` +Examples: +```php +$a = new PrestaShop\Decimal\Number('777.777'); +$b = new PrestaShop\Decimal\Number('654.321'); + +echo $a->minus($b); // echoes '123.456' +``` + +### Multiplication +Returns the computed result of multiplying the current number with another one. +```php +public Number Number::times ( Number $factor ) +``` +Examples: +```php +$a = new PrestaShop\Decimal\Number('777.777'); +$b = new PrestaShop\Decimal\Number('654.321'); + +echo $a->times($b); // echoes '508915.824417' +``` + +### Division +Returns the computed result of dividing the current number by another one, with up to a certain number of decimal positions (6 by default). +```php +public Number Number::dividedBy ( Number $divisor [, int $precision = Operation\Division::DEFAULT_PRECISION ] ) +``` +Examples: +```php +$a = new PrestaShop\Decimal\Number('777.777'); +$b = new PrestaShop\Decimal\Number('654.321'); + +echo $a->dividedBy($b, 0); // echoes '1' +echo $a->dividedBy($b, 5); // echoes '1.18867' +echo $a->dividedBy($b, 10); // echoes '1.1886780341' +echo $a->dividedBy($b, 15); // echoes '1.188678034175886' +``` + +### Comparison +Returns the result of the comparison assertion. +```php +$a = new PrestaShop\Decimal\Number('777.777'); +$b = new PrestaShop\Decimal\Number('654.321'); + +$a->equals($b); // returns false +$a->isLowerThan($b); // returns false +$a->isLowerOrEqualThan($b); // returns false +$a->isGreaterThan($b); // returns true +$a->isGreaterOrEqualThan($b); // returns true + +// shortcut methods +$a->equalsZero(); // returns false +$a->isLowerThanZero(); // returns false +$a->isLowerOrEqualThanZero(); // returns false +$a->isGreaterThanZero(); // returns true +$a->isGreaterOrEqualThanZero(); // returns true +``` + +### Fixed precision +Returns the number as a string, optionally rounded, with an exact number of decimal positions. +```php +public string Number::toPrecision ( int $precision [, string $roundingMode = Rounding::ROUND_TRUNCATE ] ) +``` +Examples: +```php +$a = new PrestaShop\Decimal\Number('123.456'); +$a = new PrestaShop\Decimal\Number('-123.456'); + +// truncate / pad +$a->toPrecision(0); // '123' +$a->toPrecision(1); // '123.4' +$a->toPrecision(2); // '123.45' +$a->toPrecision(3); // '123.456' +$a->toPrecision(4); // '123.4560' +$b->toPrecision(0); // '-123' +$b->toPrecision(1); // '-123.4' +$b->toPrecision(2); // '-123.45' +$b->toPrecision(3); // '-123.456' +$b->toPrecision(4); // '-123.4560' + +// ceil (round up) +$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '124' +$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '123.5' +$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '123.46' +$b->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '-122' +$b->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '-123.3' +$b->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL); // '-123.44' + +// floor (round down) +$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '123' +$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '123.4' +$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '123.45' +$b->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '-124' +$b->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '-123.5' +$b->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); // '-123.46' + +// half-up (symmetric half-up) +$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '123' +$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '123.5' +$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '123.46' +$b->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '-123' +$b->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '-123.5' +$b->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP); // '-123.46' + +// half-down (symmetric half-down) +$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '123' +$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '123.4' +$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '123.46' +$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '-123' +$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '-123.4' +$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN); // '-123.46' + +// half-even +$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '123' +$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '123.4' +$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '123.46' +$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '-123' +$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '-123.4' +$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '-123.46' + +$a = new Decimal\Number('1.1525354556575859505'); +$a->toPrecision(0, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1' +$a->toPrecision(1, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.2' +$a->toPrecision(2, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.15' +$a->toPrecision(3, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.152' +$a->toPrecision(4, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.1525' +$a->toPrecision(5, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.15255' +$a->toPrecision(6, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.152535' +$a->toPrecision(7, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.1525354' +$a->toPrecision(8, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.15253546' +$a->toPrecision(9, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.152535456' +$a->toPrecision(10, PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN); // '1.1525354556' +``` + +### Rounding +Rounding behaves like `toPrecision`, but provides "up to" a certain number of decimal positions +(it does not add trailing zeroes). +```php +public string Number::round ( int $maxDecimals [, string $roundingMode = Rounding::ROUND_TRUNCATE ] ) +``` +Examples: +```php +$a = new PrestaShop\Decimal\Number('123.456'); +$a = new PrestaShop\Decimal\Number('-123.456'); + +// truncate / pad +$a->round(0); // '123' +$a->round(1); // '123.4' +$a->round(2); // '123.45' +$a->round(3); // '123.456' +$a->round(4); // '123.456' +$b->round(0); // '-123' +$b->round(1); // '-123.4' +$b->round(2); // '-123.45' +$b->round(3); // '-123.456' +$b->round(4); // '-123.456' +``` + +### Dot shifting +Creates a new copy of this number multiplied by 10^exponent +```php +public Number Number::toMagnitude ( int $exponent ) +``` +Examples: +```php +$a = new Decimal\Number('123.456789'); + +// shift 3 digits to the left +$a->toMagnitude(-3); // 0.123456789 + +// shift 3 digits to the right +$a->toMagnitude(3); // 123456.789 +``` + +### Useful methods +```php +$number = new PrestaShop\Decimal\Number('123.45'); +$number->getIntegerPart(); // '123' +$number->getFractionalPart(); // '45' +$number->getPrecision(); // '2' (number of decimals) +$number->getSign(); // '' ('-' if the number was negative) +$number->getExponent(); // '2' (always positive) +$number->getCoefficient(); // '123456' +$number->isPositive(); // true +$number->isNegative(); // false +$number->invert(); // new Decimal\Number('-123.45') +``` + +## Testing + +``` bash +$ composer install +$ vendor/bin/phpunit +``` + +## Contributing + +Please see [CONTRIBUTING](CONTRIBUTING.md) for details. + +## Credits + +- [All Contributors](https://github.com/prestashop/decimal/contributors) + +## License + +The MIT License (MIT). Please see [License File](LICENSE.md) for more information. diff --git a/vendor/prestashop/decimal/composer.json b/vendor/prestashop/decimal/composer.json index 3eab3eee9..97e245172 100644 --- a/vendor/prestashop/decimal/composer.json +++ b/vendor/prestashop/decimal/composer.json @@ -1,41 +1,41 @@ -{ - "name": "prestashop\/decimal", - "description": "Object-oriented wrapper\/shim for BC Math PHP extension. Allows for arbitrary-precision math operations.", - "type": "library", - "keywords": [ - "decimal", - "math", - "precision", - "bcmath", - "prestashop" - ], - "homepage": "https:\/\/github.com\/prestashop\/decimal", - "license": "MIT", - "authors": [ - { - "name": "PrestaShop SA", - "email": "contact@prestashop.com" - }, - { - "name": "Pablo Borowicz", - "email": "pablo.borowicz@prestashop.com" - } - ], - "require": { - "php": ">=5.4" - }, - "require-dev": { - "phpunit\/phpunit": "4.*", - "codacy\/coverage": "dev-master" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\": "src" - } - }, - "autoload-dev": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\": "tests" - } - } +{ + "name": "prestashop\/decimal", + "description": "Object-oriented wrapper\/shim for BC Math PHP extension. Allows for arbitrary-precision math operations.", + "type": "library", + "keywords": [ + "decimal", + "math", + "precision", + "bcmath", + "prestashop" + ], + "homepage": "https:\/\/github.com\/prestashop\/decimal", + "license": "MIT", + "authors": [ + { + "name": "PrestaShop SA", + "email": "contact@prestashop.com" + }, + { + "name": "Pablo Borowicz", + "email": "pablo.borowicz@prestashop.com" + } + ], + "require": { + "php": ">=5.4" + }, + "require-dev": { + "phpunit\/phpunit": "4.*", + "codacy\/coverage": "dev-master" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\": "src" + } + }, + "autoload-dev": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\PrestaShop\\Decimal\\Test\\": "tests" + } + } } \ No newline at end of file diff --git a/vendor/prestashop/decimal/phpunit.xml.dist b/vendor/prestashop/decimal/phpunit.xml.dist index 611ca7951..57971bf95 100644 --- a/vendor/prestashop/decimal/phpunit.xml.dist +++ b/vendor/prestashop/decimal/phpunit.xml.dist @@ -1,29 +1,29 @@ - - - - - tests - - - - - src/ - - - - - - - - - - + + + + + tests + + + + + src/ + + + + + + + + + + diff --git a/vendor/prestashop/decimal/src/Builder.php b/vendor/prestashop/decimal/src/Builder.php index 23c3949ac..a26ed769b 100644 --- a/vendor/prestashop/decimal/src/Builder.php +++ b/vendor/prestashop/decimal/src/Builder.php @@ -1,78 +1,78 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; -/** - * Builds Number instances - */ -class Builder -{ - /** - * Pattern for most numbers - */ - const NUMBER_PATTERN = "/^(?[-+])?(?\\d+)?(?:\\.(?\\d+)(?[eE](?[-+])(?\\d+))?)?\$/"; - /** - * Pattern for integer numbers in scientific notation (rare but supported by spec) - */ - const INT_EXPONENTIAL_PATTERN = "/^(?[-+])?(?\\d+)(?[eE](?[-+])(?\\d+))\$/"; - /** - * Builds a Number from a string - * - * @param string $number - * - * @return Number - */ - public static function parseNumber($number) - { - if (!self::itLooksLikeANumber($number, $numberParts)) { - throw new \InvalidArgumentException(\sprintf('"%s" cannot be interpreted as a number', \print_r($number, \true))); - } - $integerPart = ''; - if (\array_key_exists('integerPart', $numberParts)) { - // extract the integer part and remove leading zeroes - $integerPart = \ltrim($numberParts['integerPart'], '0'); - } - $fractionalPart = ''; - if (\array_key_exists('fractionalPart', $numberParts)) { - // extract the fractional part and remove trailing zeroes - $fractionalPart = \rtrim($numberParts['fractionalPart'], '0'); - } - $fractionalDigits = \strlen($fractionalPart); - $coefficient = $integerPart . $fractionalPart; - // when coefficient is '0' or a sequence of '0' - if ('' === $coefficient) { - $coefficient = '0'; - } - // when the number has been provided in scientific notation - if (\array_key_exists('exponentPart', $numberParts)) { - $givenExponent = (int) ($numberParts['exponentSign'] . $numberParts['exponent']); - // we simply add or subtract fractional digits from the given exponent (depending if it's positive or negative) - $fractionalDigits -= $givenExponent; - if ($fractionalDigits < 0) { - // if the resulting fractional digits is negative, it means there is no fractional part anymore - // we need to add trailing zeroes as needed - $coefficient = \str_pad($coefficient, \strlen($coefficient) - $fractionalDigits, '0'); - // there's no fractional part anymore - $fractionalDigits = 0; - } - } - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($numberParts['sign'] . $coefficient, $fractionalDigits); - } - /** - * @param string $number - * @param array $numberParts - * - * @return bool - */ - private static function itLooksLikeANumber($number, &$numberParts) - { - return \strlen((string) $number) > 0 && (\preg_match(self::NUMBER_PATTERN, $number, $numberParts) || \preg_match(self::INT_EXPONENTIAL_PATTERN, $number, $numberParts)); - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; +/** + * Builds Number instances + */ +class Builder +{ + /** + * Pattern for most numbers + */ + const NUMBER_PATTERN = "/^(?[-+])?(?\\d+)?(?:\\.(?\\d+)(?[eE](?[-+])(?\\d+))?)?\$/"; + /** + * Pattern for integer numbers in scientific notation (rare but supported by spec) + */ + const INT_EXPONENTIAL_PATTERN = "/^(?[-+])?(?\\d+)(?[eE](?[-+])(?\\d+))\$/"; + /** + * Builds a Number from a string + * + * @param string $number + * + * @return Number + */ + public static function parseNumber($number) + { + if (!self::itLooksLikeANumber($number, $numberParts)) { + throw new \InvalidArgumentException(\sprintf('"%s" cannot be interpreted as a number', \print_r($number, \true))); + } + $integerPart = ''; + if (\array_key_exists('integerPart', $numberParts)) { + // extract the integer part and remove leading zeroes + $integerPart = \ltrim($numberParts['integerPart'], '0'); + } + $fractionalPart = ''; + if (\array_key_exists('fractionalPart', $numberParts)) { + // extract the fractional part and remove trailing zeroes + $fractionalPart = \rtrim($numberParts['fractionalPart'], '0'); + } + $fractionalDigits = \strlen($fractionalPart); + $coefficient = $integerPart . $fractionalPart; + // when coefficient is '0' or a sequence of '0' + if ('' === $coefficient) { + $coefficient = '0'; + } + // when the number has been provided in scientific notation + if (\array_key_exists('exponentPart', $numberParts)) { + $givenExponent = (int) ($numberParts['exponentSign'] . $numberParts['exponent']); + // we simply add or subtract fractional digits from the given exponent (depending if it's positive or negative) + $fractionalDigits -= $givenExponent; + if ($fractionalDigits < 0) { + // if the resulting fractional digits is negative, it means there is no fractional part anymore + // we need to add trailing zeroes as needed + $coefficient = \str_pad($coefficient, \strlen($coefficient) - $fractionalDigits, '0'); + // there's no fractional part anymore + $fractionalDigits = 0; + } + } + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($numberParts['sign'] . $coefficient, $fractionalDigits); + } + /** + * @param string $number + * @param array $numberParts + * + * @return bool + */ + private static function itLooksLikeANumber($number, &$numberParts) + { + return \strlen((string) $number) > 0 && (\preg_match(self::NUMBER_PATTERN, $number, $numberParts) || \preg_match(self::INT_EXPONENTIAL_PATTERN, $number, $numberParts)); + } +} diff --git a/vendor/prestashop/decimal/src/Exception/DivisionByZeroException.php b/vendor/prestashop/decimal/src/Exception/DivisionByZeroException.php index 430d0703d..cde228257 100644 --- a/vendor/prestashop/decimal/src/Exception/DivisionByZeroException.php +++ b/vendor/prestashop/decimal/src/Exception/DivisionByZeroException.php @@ -1,16 +1,16 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Exception; - -/** - * Thrown when attempting to divide by zero - */ -class DivisionByZeroException extends \Exception -{ -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Exception; + +/** + * Thrown when attempting to divide by zero + */ +class DivisionByZeroException extends \Exception +{ +} diff --git a/vendor/prestashop/decimal/src/Number.php b/vendor/prestashop/decimal/src/Number.php index 3f6738a39..86848151e 100644 --- a/vendor/prestashop/decimal/src/Number.php +++ b/vendor/prestashop/decimal/src/Number.php @@ -1,496 +1,496 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal; - -use InvalidArgumentException; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding; -/** - * Decimal number. - * - * Allows for arbitrary precision math operations. - */ -class Number -{ - /** - * Indicates if the number is negative - * @var bool - */ - private $isNegative = \false; - /** - * Integer representation of this number - * @var string - */ - private $coefficient = ''; - /** - * Scientific notation exponent. For practical reasons, it's always stored as a positive value. - * @var int - */ - private $exponent = 0; - /** - * Number constructor. - * - * This constructor can be used in two ways: - * - * 1) With a number string: - * - * ```php - * (string) new Number('0.123456'); // -> '0.123456' - * ``` - * - * 2) With an integer string as coefficient and an exponent - * - * ```php - * // 123456 * 10^(-6) - * (string) new Number('123456', 6); // -> '0.123456' - * ``` - * - * Note: decimal positions must always be a positive number. - * - * @param string $number Number or coefficient - * @param int $exponent [default=null] If provided, the number can be considered as the negative - * exponent of the scientific notation, or the number of fractional digits. - */ - public function __construct($number, $exponent = null) - { - if (!\is_string($number)) { - throw new \InvalidArgumentException(\sprintf('Invalid type - expected string, but got (%s) "%s"', \gettype($number), \print_r($number, \true))); - } - if (null === $exponent) { - $decimalNumber = \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Builder::parseNumber($number); - $number = $decimalNumber->getSign() . $decimalNumber->getCoefficient(); - $exponent = $decimalNumber->getExponent(); - } - $this->initFromScientificNotation($number, $exponent); - if ('0' === $this->coefficient) { - // make sure the sign is always positive for zero - $this->isNegative = \false; - } - } - /** - * Returns the integer part of the number. - * Note that this does NOT include the sign. - * - * @return string - */ - public function getIntegerPart() - { - if ('0' === $this->coefficient) { - return $this->coefficient; - } - if (0 === $this->exponent) { - return $this->coefficient; - } - if ($this->exponent >= \strlen($this->coefficient)) { - return '0'; - } - return \substr($this->coefficient, 0, -$this->exponent); - } - /** - * Returns the fractional part of the number. - * Note that this does NOT include the sign. - * - * @return string - */ - public function getFractionalPart() - { - if (0 === $this->exponent || '0' === $this->coefficient) { - return '0'; - } - if ($this->exponent > \strlen($this->coefficient)) { - return \str_pad($this->coefficient, $this->exponent, '0', \STR_PAD_LEFT); - } - return \substr($this->coefficient, -$this->exponent); - } - /** - * Returns the number of digits in the fractional part. - * - * @see self::getExponent() This method is an alias of getExponent(). - * - * @return int - */ - public function getPrecision() - { - return $this->getExponent(); - } - /** - * Returns the number's sign. - * Note that this method will return an empty string if the number is positive! - * - * @return string '-' if negative, empty string if positive - */ - public function getSign() - { - return $this->isNegative ? '-' : ''; - } - /** - * Returns the exponent of this number. For practical reasons, this exponent is always >= 0. - * - * This value can also be interpreted as the number of significant digits on the fractional part. - * - * @return int - */ - public function getExponent() - { - return $this->exponent; - } - /** - * Returns the raw number as stored internally. This coefficient is always an integer. - * - * It can be transformed to float by computing: - * ``` - * getCoefficient() * 10^(-getExponent()) - * ``` - * - * @return string - */ - public function getCoefficient() - { - return $this->coefficient; - } - /** - * Returns a string representation of this object - * - * @return string - */ - public function __toString() - { - $output = $this->getSign() . $this->getIntegerPart(); - $fractionalPart = $this->getFractionalPart(); - if ('0' !== $fractionalPart) { - $output .= '.' . $fractionalPart; - } - return $output; - } - /** - * Returns the number as a string, with exactly $precision decimals - * - * Example: - * ``` - * $n = new Number('123.4560'); - * (string) $n->round(1); // '123.4' - * (string) $n->round(2); // '123.45' - * (string) $n->round(3); // '123.456' - * (string) $n->round(4); // '123.4560' (trailing zeroes are added) - * (string) $n->round(5); // '123.45600' (trailing zeroes are added) - * ``` - * - * @param int $precision Exact number of desired decimals - * @param string $roundingMode [default=Rounding::ROUND_TRUNCATE] Rounding algorithm - * - * @return string - */ - public function toPrecision($precision, $roundingMode = \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE) - { - $currentPrecision = $this->getPrecision(); - if ($precision === $currentPrecision) { - return (string) $this; - } - $return = $this; - if ($precision < $currentPrecision) { - $return = (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding())->compute($this, $precision, $roundingMode); - } - if ($precision > $return->getPrecision()) { - return $return->getSign() . $return->getIntegerPart() . '.' . \str_pad($return->getFractionalPart(), $precision, '0'); - } - return (string) $return; - } - /** - * Returns the number as a string, with up to $maxDecimals significant digits. - * - * Example: - * ``` - * $n = new Number('123.4560'); - * (string) $n->round(1); // '123.4' - * (string) $n->round(2); // '123.45' - * (string) $n->round(3); // '123.456' - * (string) $n->round(4); // '123.456' (does not add trailing zeroes) - * (string) $n->round(5); // '123.456' (does not add trailing zeroes) - * ``` - * - * @param int $maxDecimals Maximum number of decimals - * @param string $roundingMode [default=Rounding::ROUND_TRUNCATE] Rounding algorithm - * - * @return string - */ - public function round($maxDecimals, $roundingMode = \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE) - { - $currentPrecision = $this->getPrecision(); - if ($maxDecimals < $currentPrecision) { - return (string) (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding())->compute($this, $maxDecimals, $roundingMode); - } - return (string) $this; - } - /** - * Returns this number as a positive number - * - * @return self - */ - public function toPositive() - { - if (!$this->isNegative) { - return $this; - } - return $this->invert(); - } - /** - * Returns this number as a negative number - * - * @return self - */ - public function toNegative() - { - if ($this->isNegative) { - return $this; - } - return $this->invert(); - } - /** - * Returns the computed result of adding another number to this one - * - * @param self $addend Number to add - * - * @return self - */ - public function plus(self $addend) - { - return (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Addition())->compute($this, $addend); - } - /** - * Returns the computed result of subtracting another number to this one - * - * @param self $subtrahend Number to subtract - * - * @return self - */ - public function minus(self $subtrahend) - { - return (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Subtraction())->compute($this, $subtrahend); - } - /** - * Returns the computed result of multiplying this number with another one - * - * @param self $factor - * - * @return self - */ - public function times(self $factor) - { - return (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Multiplication())->compute($this, $factor); - } - /** - * Returns the computed result of dividing this number by another one, with up to $precision number of decimals. - * - * A target maximum precision is required in order to handle potential infinite number of decimals - * (e.g. 1/3 = 0.3333333...). - * - * If the division yields more decimal positions than the requested precision, - * the remaining decimals are truncated, with **no rounding**. - * - * @param self $divisor - * @param int $precision [optional] By default, up to Operation\Division::DEFAULT_PRECISION number of decimals. - * - * @return self - * - * @throws Exception\DivisionByZeroException - */ - public function dividedBy(self $divisor, $precision = \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division::DEFAULT_PRECISION) - { - return (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division())->compute($this, $divisor, $precision); - } - /** - * Indicates if this number equals zero - * - * @return bool - */ - public function equalsZero() - { - return '0' == $this->getCoefficient(); - } - /** - * Indicates if this number is greater than the provided one - * - * @param self $number - * - * @return bool - */ - public function isGreaterThan(self $number) - { - return 1 === (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison())->compare($this, $number); - } - /** - * Indicates if this number is greater than zero - * - * @return bool - */ - public function isGreaterThanZero() - { - return $this->isPositive() && !$this->equalsZero(); - } - /** - * Indicates if this number is greater or equal than zero - * - * @return bool - */ - public function isGreaterOrEqualThanZero() - { - return $this->isPositive(); - } - /** - * Indicates if this number is greater or equal compared to the provided one - * - * @param self $number - * - * @return bool - */ - public function isGreaterOrEqualThan(self $number) - { - return 0 <= (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison())->compare($this, $number); - } - /** - * Indicates if this number is lower than zero - * - * @return bool - */ - public function isLowerThanZero() - { - return $this->isNegative() && !$this->equalsZero(); - } - /** - * Indicates if this number is lower or equal than zero - * - * @return bool - */ - public function isLowerOrEqualThanZero() - { - return $this->isNegative() || $this->equalsZero(); - } - /** - * Indicates if this number is greater than the provided one - * - * @param self $number - * - * @return bool - */ - public function isLowerThan(self $number) - { - return -1 === (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison())->compare($this, $number); - } - /** - * Indicates if this number is lower or equal compared to the provided one - * - * @param self $number - * - * @return bool - */ - public function isLowerOrEqualThan(self $number) - { - return 0 >= (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison())->compare($this, $number); - } - /** - * Indicates if this number is positive - * - * @return bool - */ - public function isPositive() - { - return !$this->isNegative; - } - /** - * Indicates if this number is negative - * - * @return bool - */ - public function isNegative() - { - return $this->isNegative; - } - /** - * Indicates if this number equals another one - * - * @param self $number - * - * @return bool - */ - public function equals(self $number) - { - return $this->isNegative === $number->isNegative && $this->coefficient === $number->getCoefficient() && $this->exponent === $number->getExponent(); - } - /** - * Returns the additive inverse of this number (that is, N * -1). - * - * @return static - */ - public function invert() - { - // invert sign - $sign = $this->isNegative ? '' : '-'; - return new static($sign . $this->getCoefficient(), $this->getExponent()); - } - /** - * Creates a new copy of this number multiplied by 10^$exponent - * - * @param int $exponent - * - * @return static - */ - public function toMagnitude($exponent) - { - return (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\MagnitudeChange())->compute($this, $exponent); - } - /** - * Initializes the number using a coefficient and exponent - * - * @param string $coefficient - * @param int $exponent - */ - private function initFromScientificNotation($coefficient, $exponent) - { - if ($exponent < 0) { - throw new \InvalidArgumentException(\sprintf('Invalid value for exponent. Expected a positive integer or 0, but got "%s"', $coefficient)); - } - if (!\preg_match("/^(?[-+])?(?\\d+)\$/", $coefficient, $parts)) { - throw new \InvalidArgumentException(\sprintf('"%s" cannot be interpreted as a number', $coefficient)); - } - $this->isNegative = '-' === $parts['sign']; - $this->exponent = (int) $exponent; - // trim leading zeroes - $this->coefficient = \ltrim($parts['integerPart'], '0'); - // when coefficient is '0' or a sequence of '0' - if ('' === $this->coefficient) { - $this->exponent = 0; - $this->coefficient = '0'; - return; - } - $this->removeTrailingZeroesIfNeeded(); - } - /** - * Removes trailing zeroes from the fractional part and adjusts the exponent accordingly - */ - private function removeTrailingZeroesIfNeeded() - { - $exponent = $this->getExponent(); - $coefficient = $this->getCoefficient(); - // trim trailing zeroes from the fractional part - // for example 1000e-1 => 100.0 - if (0 < $exponent && '0' === \substr($coefficient, -1)) { - $fractionalPart = $this->getFractionalPart(); - $trailingZeroesToRemove = 0; - for ($i = $exponent - 1; $i >= 0; $i--) { - if ('0' !== $fractionalPart[$i]) { - break; - } - $trailingZeroesToRemove++; - } - if ($trailingZeroesToRemove > 0) { - $this->coefficient = \substr($coefficient, 0, -$trailingZeroesToRemove); - $this->exponent = $exponent - $trailingZeroesToRemove; - } - } - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal; + +use InvalidArgumentException; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding; +/** + * Decimal number. + * + * Allows for arbitrary precision math operations. + */ +class Number +{ + /** + * Indicates if the number is negative + * @var bool + */ + private $isNegative = \false; + /** + * Integer representation of this number + * @var string + */ + private $coefficient = ''; + /** + * Scientific notation exponent. For practical reasons, it's always stored as a positive value. + * @var int + */ + private $exponent = 0; + /** + * Number constructor. + * + * This constructor can be used in two ways: + * + * 1) With a number string: + * + * ```php + * (string) new Number('0.123456'); // -> '0.123456' + * ``` + * + * 2) With an integer string as coefficient and an exponent + * + * ```php + * // 123456 * 10^(-6) + * (string) new Number('123456', 6); // -> '0.123456' + * ``` + * + * Note: decimal positions must always be a positive number. + * + * @param string $number Number or coefficient + * @param int $exponent [default=null] If provided, the number can be considered as the negative + * exponent of the scientific notation, or the number of fractional digits. + */ + public function __construct($number, $exponent = null) + { + if (!\is_string($number)) { + throw new \InvalidArgumentException(\sprintf('Invalid type - expected string, but got (%s) "%s"', \gettype($number), \print_r($number, \true))); + } + if (null === $exponent) { + $decimalNumber = \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Builder::parseNumber($number); + $number = $decimalNumber->getSign() . $decimalNumber->getCoefficient(); + $exponent = $decimalNumber->getExponent(); + } + $this->initFromScientificNotation($number, $exponent); + if ('0' === $this->coefficient) { + // make sure the sign is always positive for zero + $this->isNegative = \false; + } + } + /** + * Returns the integer part of the number. + * Note that this does NOT include the sign. + * + * @return string + */ + public function getIntegerPart() + { + if ('0' === $this->coefficient) { + return $this->coefficient; + } + if (0 === $this->exponent) { + return $this->coefficient; + } + if ($this->exponent >= \strlen($this->coefficient)) { + return '0'; + } + return \substr($this->coefficient, 0, -$this->exponent); + } + /** + * Returns the fractional part of the number. + * Note that this does NOT include the sign. + * + * @return string + */ + public function getFractionalPart() + { + if (0 === $this->exponent || '0' === $this->coefficient) { + return '0'; + } + if ($this->exponent > \strlen($this->coefficient)) { + return \str_pad($this->coefficient, $this->exponent, '0', \STR_PAD_LEFT); + } + return \substr($this->coefficient, -$this->exponent); + } + /** + * Returns the number of digits in the fractional part. + * + * @see self::getExponent() This method is an alias of getExponent(). + * + * @return int + */ + public function getPrecision() + { + return $this->getExponent(); + } + /** + * Returns the number's sign. + * Note that this method will return an empty string if the number is positive! + * + * @return string '-' if negative, empty string if positive + */ + public function getSign() + { + return $this->isNegative ? '-' : ''; + } + /** + * Returns the exponent of this number. For practical reasons, this exponent is always >= 0. + * + * This value can also be interpreted as the number of significant digits on the fractional part. + * + * @return int + */ + public function getExponent() + { + return $this->exponent; + } + /** + * Returns the raw number as stored internally. This coefficient is always an integer. + * + * It can be transformed to float by computing: + * ``` + * getCoefficient() * 10^(-getExponent()) + * ``` + * + * @return string + */ + public function getCoefficient() + { + return $this->coefficient; + } + /** + * Returns a string representation of this object + * + * @return string + */ + public function __toString() + { + $output = $this->getSign() . $this->getIntegerPart(); + $fractionalPart = $this->getFractionalPart(); + if ('0' !== $fractionalPart) { + $output .= '.' . $fractionalPart; + } + return $output; + } + /** + * Returns the number as a string, with exactly $precision decimals + * + * Example: + * ``` + * $n = new Number('123.4560'); + * (string) $n->round(1); // '123.4' + * (string) $n->round(2); // '123.45' + * (string) $n->round(3); // '123.456' + * (string) $n->round(4); // '123.4560' (trailing zeroes are added) + * (string) $n->round(5); // '123.45600' (trailing zeroes are added) + * ``` + * + * @param int $precision Exact number of desired decimals + * @param string $roundingMode [default=Rounding::ROUND_TRUNCATE] Rounding algorithm + * + * @return string + */ + public function toPrecision($precision, $roundingMode = \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE) + { + $currentPrecision = $this->getPrecision(); + if ($precision === $currentPrecision) { + return (string) $this; + } + $return = $this; + if ($precision < $currentPrecision) { + $return = (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding())->compute($this, $precision, $roundingMode); + } + if ($precision > $return->getPrecision()) { + return $return->getSign() . $return->getIntegerPart() . '.' . \str_pad($return->getFractionalPart(), $precision, '0'); + } + return (string) $return; + } + /** + * Returns the number as a string, with up to $maxDecimals significant digits. + * + * Example: + * ``` + * $n = new Number('123.4560'); + * (string) $n->round(1); // '123.4' + * (string) $n->round(2); // '123.45' + * (string) $n->round(3); // '123.456' + * (string) $n->round(4); // '123.456' (does not add trailing zeroes) + * (string) $n->round(5); // '123.456' (does not add trailing zeroes) + * ``` + * + * @param int $maxDecimals Maximum number of decimals + * @param string $roundingMode [default=Rounding::ROUND_TRUNCATE] Rounding algorithm + * + * @return string + */ + public function round($maxDecimals, $roundingMode = \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE) + { + $currentPrecision = $this->getPrecision(); + if ($maxDecimals < $currentPrecision) { + return (string) (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding())->compute($this, $maxDecimals, $roundingMode); + } + return (string) $this; + } + /** + * Returns this number as a positive number + * + * @return self + */ + public function toPositive() + { + if (!$this->isNegative) { + return $this; + } + return $this->invert(); + } + /** + * Returns this number as a negative number + * + * @return self + */ + public function toNegative() + { + if ($this->isNegative) { + return $this; + } + return $this->invert(); + } + /** + * Returns the computed result of adding another number to this one + * + * @param self $addend Number to add + * + * @return self + */ + public function plus(self $addend) + { + return (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Addition())->compute($this, $addend); + } + /** + * Returns the computed result of subtracting another number to this one + * + * @param self $subtrahend Number to subtract + * + * @return self + */ + public function minus(self $subtrahend) + { + return (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Subtraction())->compute($this, $subtrahend); + } + /** + * Returns the computed result of multiplying this number with another one + * + * @param self $factor + * + * @return self + */ + public function times(self $factor) + { + return (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Multiplication())->compute($this, $factor); + } + /** + * Returns the computed result of dividing this number by another one, with up to $precision number of decimals. + * + * A target maximum precision is required in order to handle potential infinite number of decimals + * (e.g. 1/3 = 0.3333333...). + * + * If the division yields more decimal positions than the requested precision, + * the remaining decimals are truncated, with **no rounding**. + * + * @param self $divisor + * @param int $precision [optional] By default, up to Operation\Division::DEFAULT_PRECISION number of decimals. + * + * @return self + * + * @throws Exception\DivisionByZeroException + */ + public function dividedBy(self $divisor, $precision = \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division::DEFAULT_PRECISION) + { + return (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division())->compute($this, $divisor, $precision); + } + /** + * Indicates if this number equals zero + * + * @return bool + */ + public function equalsZero() + { + return '0' == $this->getCoefficient(); + } + /** + * Indicates if this number is greater than the provided one + * + * @param self $number + * + * @return bool + */ + public function isGreaterThan(self $number) + { + return 1 === (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison())->compare($this, $number); + } + /** + * Indicates if this number is greater than zero + * + * @return bool + */ + public function isGreaterThanZero() + { + return $this->isPositive() && !$this->equalsZero(); + } + /** + * Indicates if this number is greater or equal than zero + * + * @return bool + */ + public function isGreaterOrEqualThanZero() + { + return $this->isPositive(); + } + /** + * Indicates if this number is greater or equal compared to the provided one + * + * @param self $number + * + * @return bool + */ + public function isGreaterOrEqualThan(self $number) + { + return 0 <= (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison())->compare($this, $number); + } + /** + * Indicates if this number is lower than zero + * + * @return bool + */ + public function isLowerThanZero() + { + return $this->isNegative() && !$this->equalsZero(); + } + /** + * Indicates if this number is lower or equal than zero + * + * @return bool + */ + public function isLowerOrEqualThanZero() + { + return $this->isNegative() || $this->equalsZero(); + } + /** + * Indicates if this number is greater than the provided one + * + * @param self $number + * + * @return bool + */ + public function isLowerThan(self $number) + { + return -1 === (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison())->compare($this, $number); + } + /** + * Indicates if this number is lower or equal compared to the provided one + * + * @param self $number + * + * @return bool + */ + public function isLowerOrEqualThan(self $number) + { + return 0 >= (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison())->compare($this, $number); + } + /** + * Indicates if this number is positive + * + * @return bool + */ + public function isPositive() + { + return !$this->isNegative; + } + /** + * Indicates if this number is negative + * + * @return bool + */ + public function isNegative() + { + return $this->isNegative; + } + /** + * Indicates if this number equals another one + * + * @param self $number + * + * @return bool + */ + public function equals(self $number) + { + return $this->isNegative === $number->isNegative && $this->coefficient === $number->getCoefficient() && $this->exponent === $number->getExponent(); + } + /** + * Returns the additive inverse of this number (that is, N * -1). + * + * @return static + */ + public function invert() + { + // invert sign + $sign = $this->isNegative ? '' : '-'; + return new static($sign . $this->getCoefficient(), $this->getExponent()); + } + /** + * Creates a new copy of this number multiplied by 10^$exponent + * + * @param int $exponent + * + * @return static + */ + public function toMagnitude($exponent) + { + return (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\MagnitudeChange())->compute($this, $exponent); + } + /** + * Initializes the number using a coefficient and exponent + * + * @param string $coefficient + * @param int $exponent + */ + private function initFromScientificNotation($coefficient, $exponent) + { + if ($exponent < 0) { + throw new \InvalidArgumentException(\sprintf('Invalid value for exponent. Expected a positive integer or 0, but got "%s"', $coefficient)); + } + if (!\preg_match("/^(?[-+])?(?\\d+)\$/", $coefficient, $parts)) { + throw new \InvalidArgumentException(\sprintf('"%s" cannot be interpreted as a number', $coefficient)); + } + $this->isNegative = '-' === $parts['sign']; + $this->exponent = (int) $exponent; + // trim leading zeroes + $this->coefficient = \ltrim($parts['integerPart'], '0'); + // when coefficient is '0' or a sequence of '0' + if ('' === $this->coefficient) { + $this->exponent = 0; + $this->coefficient = '0'; + return; + } + $this->removeTrailingZeroesIfNeeded(); + } + /** + * Removes trailing zeroes from the fractional part and adjusts the exponent accordingly + */ + private function removeTrailingZeroesIfNeeded() + { + $exponent = $this->getExponent(); + $coefficient = $this->getCoefficient(); + // trim trailing zeroes from the fractional part + // for example 1000e-1 => 100.0 + if (0 < $exponent && '0' === \substr($coefficient, -1)) { + $fractionalPart = $this->getFractionalPart(); + $trailingZeroesToRemove = 0; + for ($i = $exponent - 1; $i >= 0; $i--) { + if ('0' !== $fractionalPart[$i]) { + break; + } + $trailingZeroesToRemove++; + } + if ($trailingZeroesToRemove > 0) { + $this->coefficient = \substr($coefficient, 0, -$trailingZeroesToRemove); + $this->exponent = $exponent - $trailingZeroesToRemove; + } + } + } +} diff --git a/vendor/prestashop/decimal/src/Operation/Addition.php b/vendor/prestashop/decimal/src/Operation/Addition.php index 1982d2c61..1444189d5 100644 --- a/vendor/prestashop/decimal/src/Operation/Addition.php +++ b/vendor/prestashop/decimal/src/Operation/Addition.php @@ -1,177 +1,177 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; -/** - * Computes the addition of two decimal numbers - */ -class Addition -{ - /** - * Maximum safe string size in order to be confident - * that it won't overflow the max int size when operating with it - * @var int - */ - private $maxSafeIntStringSize; - /** - * Constructor - */ - public function __construct() - { - $this->maxSafeIntStringSize = \strlen((string) \PHP_INT_MAX) - 1; - } - /** - * Performs the addition - * - * @param DecimalNumber $a Base number - * @param DecimalNumber $b Addend - * - * @return DecimalNumber Result of the addition - */ - public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - if (\function_exists('_PhpScoper5ea00cc67502b\\bcadd')) { - return $this->computeUsingBcMath($a, $b); - } - return $this->computeWithoutBcMath($a, $b); - } - /** - * Performs the addition using BC Math - * - * @param DecimalNumber $a Base number - * @param DecimalNumber $b Addend - * - * @return DecimalNumber Result of the addition - */ - public function computeUsingBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - $precision1 = $a->getPrecision(); - $precision2 = $b->getPrecision(); - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number((string) bcadd($a, $b, \max($precision1, $precision2))); - } - /** - * Performs the addition without BC Math - * - * @param DecimalNumber $a Base number - * @param DecimalNumber $b Addend - * - * @return DecimalNumber Result of the addition - */ - public function computeWithoutBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - if ($a->isNegative()) { - if ($b->isNegative()) { - // if both numbers are negative, - // we can just add them as positive numbers and then invert the sign - // f(x, y) = -(|x| + |y|) - // eg. f(-1, -2) = -(|-1| + |-2|) = -3 - // eg. f(-2, -1) = -(|-2| + |-1|) = -3 - return $this->computeWithoutBcMath($a->toPositive(), $b->toPositive())->invert(); - } - // if the number is negative and the addend positive, - // perform an inverse subtraction by inverting the terms - // f(x, y) = y - |x| - // eg. f(-2, 1) = 1 - |-2| = -1 - // eg. f(-1, 2) = 2 - |-1| = 1 - // eg. f(-1, 1) = 1 - |-1| = 0 - return $b->minus($a->toPositive()); - } - if ($b->isNegative()) { - // if the number is positive and the addend is negative - // perform subtraction instead: 2 - 1 - // f(x, y) = x - |y| - // f(2, -1) = 2 - |-1| = 1 - // f(1, -2) = 1 - |-2| = -1 - // f(1, -1) = 1 - |-1| = 0 - return $a->minus($b->toPositive()); - } - // optimization: 0 + x = x - if ('0' === (string) $a) { - return $b; - } - // optimization: x + 0 = x - if ('0' === (string) $b) { - return $a; - } - // pad coefficients with leading/trailing zeroes - list($coeff1, $coeff2) = $this->normalizeCoefficients($a, $b); - // compute the coefficient sum - $sum = $this->addStrings($coeff1, $coeff2); - // both signs are equal, so we can use either - $sign = $a->getSign(); - // keep the bigger exponent - $exponent = \max($a->getExponent(), $b->getExponent()); - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($sign . $sum, $exponent); - } - /** - * Normalizes coefficients by adding leading or trailing zeroes as needed so that both are the same length - * - * @param DecimalNumber $a - * @param DecimalNumber $b - * - * @return array An array containing the normalized coefficients - */ - private function normalizeCoefficients(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - $exp1 = $a->getExponent(); - $exp2 = $b->getExponent(); - $coeff1 = $a->getCoefficient(); - $coeff2 = $b->getCoefficient(); - // add trailing zeroes if needed - if ($exp1 > $exp2) { - $coeff2 = \str_pad($coeff2, \strlen($coeff2) + $exp1 - $exp2, '0', \STR_PAD_RIGHT); - } elseif ($exp1 < $exp2) { - $coeff1 = \str_pad($coeff1, \strlen($coeff1) + $exp2 - $exp1, '0', \STR_PAD_RIGHT); - } - $len1 = \strlen($coeff1); - $len2 = \strlen($coeff2); - // add leading zeroes if needed - if ($len1 > $len2) { - $coeff2 = \str_pad($coeff2, $len1, '0', \STR_PAD_LEFT); - } elseif ($len1 < $len2) { - $coeff1 = \str_pad($coeff1, $len2, '0', \STR_PAD_LEFT); - } - return [$coeff1, $coeff2]; - } - /** - * Adds two integer numbers as strings. - * - * @param string $number1 - * @param string $number2 - * @param bool $fractional [default=false] - * If true, the numbers will be treated as the fractional part of a number (padded with trailing zeroes). - * Otherwise, they will be treated as the integer part (padded with leading zeroes). - * - * @return string - */ - private function addStrings($number1, $number2, $fractional = \false) - { - // optimization - numbers can be treated as integers as long as they don't overflow the max int size - if ('0' !== $number1[0] && '0' !== $number2[0] && \strlen($number1) <= $this->maxSafeIntStringSize && \strlen($number2) <= $this->maxSafeIntStringSize) { - return (string) ((int) $number1 + (int) $number2); - } - // find out which of the strings is longest - $maxLength = \max(\strlen($number1), \strlen($number2)); - // add leading or trailing zeroes as needed - $number1 = \str_pad($number1, $maxLength, '0', $fractional ? \STR_PAD_RIGHT : \STR_PAD_LEFT); - $number2 = \str_pad($number2, $maxLength, '0', $fractional ? \STR_PAD_RIGHT : \STR_PAD_LEFT); - $result = ''; - $carryOver = 0; - for ($i = $maxLength - 1; 0 <= $i; $i--) { - $sum = $number1[$i] + $number2[$i] + $carryOver; - $result .= $sum % 10; - $carryOver = (int) ($sum >= 10); - } - if ($carryOver > 0) { - $result .= '1'; - } - return \strrev($result); - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; +/** + * Computes the addition of two decimal numbers + */ +class Addition +{ + /** + * Maximum safe string size in order to be confident + * that it won't overflow the max int size when operating with it + * @var int + */ + private $maxSafeIntStringSize; + /** + * Constructor + */ + public function __construct() + { + $this->maxSafeIntStringSize = \strlen((string) \PHP_INT_MAX) - 1; + } + /** + * Performs the addition + * + * @param DecimalNumber $a Base number + * @param DecimalNumber $b Addend + * + * @return DecimalNumber Result of the addition + */ + public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + if (\function_exists('_PhpScoper5ea00cc67502b\\bcadd')) { + return $this->computeUsingBcMath($a, $b); + } + return $this->computeWithoutBcMath($a, $b); + } + /** + * Performs the addition using BC Math + * + * @param DecimalNumber $a Base number + * @param DecimalNumber $b Addend + * + * @return DecimalNumber Result of the addition + */ + public function computeUsingBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + $precision1 = $a->getPrecision(); + $precision2 = $b->getPrecision(); + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number((string) bcadd($a, $b, \max($precision1, $precision2))); + } + /** + * Performs the addition without BC Math + * + * @param DecimalNumber $a Base number + * @param DecimalNumber $b Addend + * + * @return DecimalNumber Result of the addition + */ + public function computeWithoutBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + if ($a->isNegative()) { + if ($b->isNegative()) { + // if both numbers are negative, + // we can just add them as positive numbers and then invert the sign + // f(x, y) = -(|x| + |y|) + // eg. f(-1, -2) = -(|-1| + |-2|) = -3 + // eg. f(-2, -1) = -(|-2| + |-1|) = -3 + return $this->computeWithoutBcMath($a->toPositive(), $b->toPositive())->invert(); + } + // if the number is negative and the addend positive, + // perform an inverse subtraction by inverting the terms + // f(x, y) = y - |x| + // eg. f(-2, 1) = 1 - |-2| = -1 + // eg. f(-1, 2) = 2 - |-1| = 1 + // eg. f(-1, 1) = 1 - |-1| = 0 + return $b->minus($a->toPositive()); + } + if ($b->isNegative()) { + // if the number is positive and the addend is negative + // perform subtraction instead: 2 - 1 + // f(x, y) = x - |y| + // f(2, -1) = 2 - |-1| = 1 + // f(1, -2) = 1 - |-2| = -1 + // f(1, -1) = 1 - |-1| = 0 + return $a->minus($b->toPositive()); + } + // optimization: 0 + x = x + if ('0' === (string) $a) { + return $b; + } + // optimization: x + 0 = x + if ('0' === (string) $b) { + return $a; + } + // pad coefficients with leading/trailing zeroes + list($coeff1, $coeff2) = $this->normalizeCoefficients($a, $b); + // compute the coefficient sum + $sum = $this->addStrings($coeff1, $coeff2); + // both signs are equal, so we can use either + $sign = $a->getSign(); + // keep the bigger exponent + $exponent = \max($a->getExponent(), $b->getExponent()); + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($sign . $sum, $exponent); + } + /** + * Normalizes coefficients by adding leading or trailing zeroes as needed so that both are the same length + * + * @param DecimalNumber $a + * @param DecimalNumber $b + * + * @return array An array containing the normalized coefficients + */ + private function normalizeCoefficients(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + $exp1 = $a->getExponent(); + $exp2 = $b->getExponent(); + $coeff1 = $a->getCoefficient(); + $coeff2 = $b->getCoefficient(); + // add trailing zeroes if needed + if ($exp1 > $exp2) { + $coeff2 = \str_pad($coeff2, \strlen($coeff2) + $exp1 - $exp2, '0', \STR_PAD_RIGHT); + } elseif ($exp1 < $exp2) { + $coeff1 = \str_pad($coeff1, \strlen($coeff1) + $exp2 - $exp1, '0', \STR_PAD_RIGHT); + } + $len1 = \strlen($coeff1); + $len2 = \strlen($coeff2); + // add leading zeroes if needed + if ($len1 > $len2) { + $coeff2 = \str_pad($coeff2, $len1, '0', \STR_PAD_LEFT); + } elseif ($len1 < $len2) { + $coeff1 = \str_pad($coeff1, $len2, '0', \STR_PAD_LEFT); + } + return [$coeff1, $coeff2]; + } + /** + * Adds two integer numbers as strings. + * + * @param string $number1 + * @param string $number2 + * @param bool $fractional [default=false] + * If true, the numbers will be treated as the fractional part of a number (padded with trailing zeroes). + * Otherwise, they will be treated as the integer part (padded with leading zeroes). + * + * @return string + */ + private function addStrings($number1, $number2, $fractional = \false) + { + // optimization - numbers can be treated as integers as long as they don't overflow the max int size + if ('0' !== $number1[0] && '0' !== $number2[0] && \strlen($number1) <= $this->maxSafeIntStringSize && \strlen($number2) <= $this->maxSafeIntStringSize) { + return (string) ((int) $number1 + (int) $number2); + } + // find out which of the strings is longest + $maxLength = \max(\strlen($number1), \strlen($number2)); + // add leading or trailing zeroes as needed + $number1 = \str_pad($number1, $maxLength, '0', $fractional ? \STR_PAD_RIGHT : \STR_PAD_LEFT); + $number2 = \str_pad($number2, $maxLength, '0', $fractional ? \STR_PAD_RIGHT : \STR_PAD_LEFT); + $result = ''; + $carryOver = 0; + for ($i = $maxLength - 1; 0 <= $i; $i--) { + $sum = $number1[$i] + $number2[$i] + $carryOver; + $result .= $sum % 10; + $carryOver = (int) ($sum >= 10); + } + if ($carryOver > 0) { + $result .= '1'; + } + return \strrev($result); + } +} diff --git a/vendor/prestashop/decimal/src/Operation/Comparison.php b/vendor/prestashop/decimal/src/Operation/Comparison.php index 9189e00cd..40a559ad9 100644 --- a/vendor/prestashop/decimal/src/Operation/Comparison.php +++ b/vendor/prestashop/decimal/src/Operation/Comparison.php @@ -1,145 +1,145 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; -/** - * Compares two decimal numbers - */ -class Comparison -{ - /** - * Compares two decimal numbers. - * - * @param DecimalNumber $a - * @param DecimalNumber $b - * - * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. - */ - public function compare(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - if (\function_exists('_PhpScoper5ea00cc67502b\\bccomp')) { - return $this->compareUsingBcMath($a, $b); - } - return $this->compareWithoutBcMath($a, $b); - } - /** - * Compares two decimal numbers using BC Math - * - * @param DecimalNumber $a - * @param DecimalNumber $b - * - * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. - */ - public function compareUsingBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - return bccomp((string) $a, (string) $b, \max($a->getExponent(), $b->getExponent())); - } - /** - * Compares two decimal numbers without using BC Math - * - * @param DecimalNumber $a - * @param DecimalNumber $b - * - * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. - */ - public function compareWithoutBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - $signCompare = $this->compareSigns($a->getSign(), $b->getSign()); - if ($signCompare !== 0) { - return $signCompare; - } - // signs are equal, compare regardless of sign - $result = $this->positiveCompare($a, $b); - // inverse the result if the signs are negative - if ($a->isNegative()) { - return -$result; - } - return $result; - } - /** - * Compares two decimal numbers as positive regardless of sign. - * - * @param DecimalNumber $a - * @param DecimalNumber $b - * - * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. - */ - private function positiveCompare(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - // compare integer length - $intLengthCompare = $this->compareNumeric(\strlen($a->getIntegerPart()), \strlen($b->getIntegerPart())); - if ($intLengthCompare !== 0) { - return $intLengthCompare; - } - // integer parts are equal in length, compare integer part - $intPartCompare = $this->compareBinary($a->getIntegerPart(), $b->getIntegerPart()); - if ($intPartCompare !== 0) { - return $intPartCompare; - } - // integer parts are equal, compare fractional part - return $this->compareBinary($a->getFractionalPart(), $b->getFractionalPart()); - } - /** - * Compares positive/negative signs. - * - * @param string $a - * @param string $b - * - * @return int Returns 0 if both signs are equal, 1 if $a is positive, and -1 if $b is positive - */ - private function compareSigns($a, $b) - { - if ($a === $b) { - return 0; - } - // empty string means positive sign - if ($a === '') { - return 1; - } - return -1; - } - /** - * Compares two values numerically. - * - * @param mixed $a - * @param mixed $b - * - * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. - */ - private function compareNumeric($a, $b) - { - if ($a < $b) { - return -1; - } - if ($a > $b) { - return 1; - } - return 0; - } - /** - * Compares two strings binarily. - * - * @param string $a - * @param string $b - * - * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. - */ - private function compareBinary($a, $b) - { - $comparison = \strcmp($a, $b); - if ($comparison > 0) { - return 1; - } - if ($comparison < 0) { - return -1; - } - return 0; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; +/** + * Compares two decimal numbers + */ +class Comparison +{ + /** + * Compares two decimal numbers. + * + * @param DecimalNumber $a + * @param DecimalNumber $b + * + * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. + */ + public function compare(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + if (\function_exists('_PhpScoper5ea00cc67502b\\bccomp')) { + return $this->compareUsingBcMath($a, $b); + } + return $this->compareWithoutBcMath($a, $b); + } + /** + * Compares two decimal numbers using BC Math + * + * @param DecimalNumber $a + * @param DecimalNumber $b + * + * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. + */ + public function compareUsingBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + return bccomp((string) $a, (string) $b, \max($a->getExponent(), $b->getExponent())); + } + /** + * Compares two decimal numbers without using BC Math + * + * @param DecimalNumber $a + * @param DecimalNumber $b + * + * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. + */ + public function compareWithoutBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + $signCompare = $this->compareSigns($a->getSign(), $b->getSign()); + if ($signCompare !== 0) { + return $signCompare; + } + // signs are equal, compare regardless of sign + $result = $this->positiveCompare($a, $b); + // inverse the result if the signs are negative + if ($a->isNegative()) { + return -$result; + } + return $result; + } + /** + * Compares two decimal numbers as positive regardless of sign. + * + * @param DecimalNumber $a + * @param DecimalNumber $b + * + * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. + */ + private function positiveCompare(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + // compare integer length + $intLengthCompare = $this->compareNumeric(\strlen($a->getIntegerPart()), \strlen($b->getIntegerPart())); + if ($intLengthCompare !== 0) { + return $intLengthCompare; + } + // integer parts are equal in length, compare integer part + $intPartCompare = $this->compareBinary($a->getIntegerPart(), $b->getIntegerPart()); + if ($intPartCompare !== 0) { + return $intPartCompare; + } + // integer parts are equal, compare fractional part + return $this->compareBinary($a->getFractionalPart(), $b->getFractionalPart()); + } + /** + * Compares positive/negative signs. + * + * @param string $a + * @param string $b + * + * @return int Returns 0 if both signs are equal, 1 if $a is positive, and -1 if $b is positive + */ + private function compareSigns($a, $b) + { + if ($a === $b) { + return 0; + } + // empty string means positive sign + if ($a === '') { + return 1; + } + return -1; + } + /** + * Compares two values numerically. + * + * @param mixed $a + * @param mixed $b + * + * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. + */ + private function compareNumeric($a, $b) + { + if ($a < $b) { + return -1; + } + if ($a > $b) { + return 1; + } + return 0; + } + /** + * Compares two strings binarily. + * + * @param string $a + * @param string $b + * + * @return int Returns 1 if $a > $b, -1 if $a < $b, and 0 if they are equal. + */ + private function compareBinary($a, $b) + { + $comparison = \strcmp($a, $b); + if ($comparison > 0) { + return 1; + } + if ($comparison < 0) { + return -1; + } + return 0; + } +} diff --git a/vendor/prestashop/decimal/src/Operation/Division.php b/vendor/prestashop/decimal/src/Operation/Division.php index c96763503..f367a6ff0 100644 --- a/vendor/prestashop/decimal/src/Operation/Division.php +++ b/vendor/prestashop/decimal/src/Operation/Division.php @@ -1,151 +1,151 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Exception\DivisionByZeroException; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; -/** - * Computes the division between two decimal numbers. - */ -class Division -{ - const DEFAULT_PRECISION = 6; - /** - * Performs the division. - * - * A target maximum precision is required in order to handle potential infinite number of decimals - * (e.g. 1/3 = 0.3333333...). - * - * If the division yields more decimal positions than the requested precision, - * the remaining decimals are truncated, with **no rounding**. - * - * @param DecimalNumber $a Dividend - * @param DecimalNumber $b Divisor - * @param int $precision Maximum decimal precision - * - * @return DecimalNumber Result of the division - * @throws DivisionByZeroException - */ - public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b, $precision = self::DEFAULT_PRECISION) - { - if (\function_exists('_PhpScoper5ea00cc67502b\\bcdiv')) { - return $this->computeUsingBcMath($a, $b, $precision); - } - return $this->computeWithoutBcMath($a, $b, $precision); - } - /** - * Performs the division using BC Math - * - * @param DecimalNumber $a Dividend - * @param DecimalNumber $b Divisor - * @param int $precision Maximum decimal precision - * - * @return DecimalNumber Result of the division - * @throws DivisionByZeroException - */ - public function computeUsingBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b, $precision = self::DEFAULT_PRECISION) - { - if ((string) $b === '0') { - throw new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Exception\DivisionByZeroException(); - } - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number((string) bcdiv($a, $b, $precision)); - } - /** - * Performs the division without BC Math - * - * @param DecimalNumber $a Dividend - * @param DecimalNumber $b Divisor - * @param int $precision Maximum decimal precision - * - * @return DecimalNumber Result of the division - * @throws DivisionByZeroException - */ - public function computeWithoutBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b, $precision = self::DEFAULT_PRECISION) - { - $bString = (string) $b; - if ('0' === $bString) { - throw new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Exception\DivisionByZeroException(); - } - $aString = (string) $a; - // 0 as dividend always yields 0 - if ('0' === $aString) { - return $a; - } - // 1 as divisor always yields the dividend - if ('1' === $bString) { - return $a; - } - // -1 as divisor always yields the the inverted dividend - if ('-1' === $bString) { - return $a->invert(); - } - // if dividend and divisor are equal, the result is always 1 - if ($a->equals($b)) { - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1'); - } - $aPrecision = $a->getPrecision(); - $bPrecision = $b->getPrecision(); - $maxPrecision = \max($aPrecision, $bPrecision); - if ($maxPrecision > 0) { - // make $a and $b integers by multiplying both by 10^(maximum number of decimals) - $a = $a->toMagnitude($maxPrecision); - $b = $b->toMagnitude($maxPrecision); - } - $result = $this->integerDivision($a, $b, \max($precision, $aPrecision)); - return $result; - } - /** - * Computes the division between two integer DecimalNumbers - * - * @param DecimalNumber $a Dividend - * @param DecimalNumber $b Divisor - * @param int $precision Maximum number of decimals to try - * - * @return DecimalNumber - */ - private function integerDivision(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b, $precision) - { - $dividend = $a->getCoefficient(); - $divisor = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($b->getCoefficient()); - $dividendLength = \strlen($dividend); - $result = ''; - $exponent = 0; - $currentSequence = ''; - for ($i = 0; $i < $dividendLength; $i++) { - // append digits until we get a number big enough to divide - $currentSequence .= $dividend[$i]; - if ($currentSequence < $divisor) { - if (!empty($result)) { - $result .= '0'; - } - } else { - // subtract divisor as many times as we can - $remainder = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($currentSequence); - $multiple = 0; - do { - $multiple++; - $remainder = $remainder->minus($divisor); - } while ($remainder->isGreaterOrEqualThan($divisor)); - $result .= (string) $multiple; - // reset sequence to the reminder - $currentSequence = (string) $remainder; - } - // add up to $precision decimals - if ($currentSequence > 0 && $i === $dividendLength - 1 && $precision > 0) { - // "borrow" up to $precision digits - --$precision; - $dividend .= '0'; - $dividendLength++; - $exponent++; - } - } - $sign = ($a->isNegative() xor $b->isNegative()) ? '-' : ''; - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($sign . $result, $exponent); - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Exception\DivisionByZeroException; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; +/** + * Computes the division between two decimal numbers. + */ +class Division +{ + const DEFAULT_PRECISION = 6; + /** + * Performs the division. + * + * A target maximum precision is required in order to handle potential infinite number of decimals + * (e.g. 1/3 = 0.3333333...). + * + * If the division yields more decimal positions than the requested precision, + * the remaining decimals are truncated, with **no rounding**. + * + * @param DecimalNumber $a Dividend + * @param DecimalNumber $b Divisor + * @param int $precision Maximum decimal precision + * + * @return DecimalNumber Result of the division + * @throws DivisionByZeroException + */ + public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b, $precision = self::DEFAULT_PRECISION) + { + if (\function_exists('_PhpScoper5ea00cc67502b\\bcdiv')) { + return $this->computeUsingBcMath($a, $b, $precision); + } + return $this->computeWithoutBcMath($a, $b, $precision); + } + /** + * Performs the division using BC Math + * + * @param DecimalNumber $a Dividend + * @param DecimalNumber $b Divisor + * @param int $precision Maximum decimal precision + * + * @return DecimalNumber Result of the division + * @throws DivisionByZeroException + */ + public function computeUsingBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b, $precision = self::DEFAULT_PRECISION) + { + if ((string) $b === '0') { + throw new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Exception\DivisionByZeroException(); + } + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number((string) bcdiv($a, $b, $precision)); + } + /** + * Performs the division without BC Math + * + * @param DecimalNumber $a Dividend + * @param DecimalNumber $b Divisor + * @param int $precision Maximum decimal precision + * + * @return DecimalNumber Result of the division + * @throws DivisionByZeroException + */ + public function computeWithoutBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b, $precision = self::DEFAULT_PRECISION) + { + $bString = (string) $b; + if ('0' === $bString) { + throw new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Exception\DivisionByZeroException(); + } + $aString = (string) $a; + // 0 as dividend always yields 0 + if ('0' === $aString) { + return $a; + } + // 1 as divisor always yields the dividend + if ('1' === $bString) { + return $a; + } + // -1 as divisor always yields the the inverted dividend + if ('-1' === $bString) { + return $a->invert(); + } + // if dividend and divisor are equal, the result is always 1 + if ($a->equals($b)) { + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1'); + } + $aPrecision = $a->getPrecision(); + $bPrecision = $b->getPrecision(); + $maxPrecision = \max($aPrecision, $bPrecision); + if ($maxPrecision > 0) { + // make $a and $b integers by multiplying both by 10^(maximum number of decimals) + $a = $a->toMagnitude($maxPrecision); + $b = $b->toMagnitude($maxPrecision); + } + $result = $this->integerDivision($a, $b, \max($precision, $aPrecision)); + return $result; + } + /** + * Computes the division between two integer DecimalNumbers + * + * @param DecimalNumber $a Dividend + * @param DecimalNumber $b Divisor + * @param int $precision Maximum number of decimals to try + * + * @return DecimalNumber + */ + private function integerDivision(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b, $precision) + { + $dividend = $a->getCoefficient(); + $divisor = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($b->getCoefficient()); + $dividendLength = \strlen($dividend); + $result = ''; + $exponent = 0; + $currentSequence = ''; + for ($i = 0; $i < $dividendLength; $i++) { + // append digits until we get a number big enough to divide + $currentSequence .= $dividend[$i]; + if ($currentSequence < $divisor) { + if (!empty($result)) { + $result .= '0'; + } + } else { + // subtract divisor as many times as we can + $remainder = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($currentSequence); + $multiple = 0; + do { + $multiple++; + $remainder = $remainder->minus($divisor); + } while ($remainder->isGreaterOrEqualThan($divisor)); + $result .= (string) $multiple; + // reset sequence to the reminder + $currentSequence = (string) $remainder; + } + // add up to $precision decimals + if ($currentSequence > 0 && $i === $dividendLength - 1 && $precision > 0) { + // "borrow" up to $precision digits + --$precision; + $dividend .= '0'; + $dividendLength++; + $exponent++; + } + } + $sign = ($a->isNegative() xor $b->isNegative()) ? '-' : ''; + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($sign . $result, $exponent); + } +} diff --git a/vendor/prestashop/decimal/src/Operation/MagnitudeChange.php b/vendor/prestashop/decimal/src/Operation/MagnitudeChange.php index 685acf973..518f13aec 100644 --- a/vendor/prestashop/decimal/src/Operation/MagnitudeChange.php +++ b/vendor/prestashop/decimal/src/Operation/MagnitudeChange.php @@ -1,49 +1,49 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; -/** - * Computes relative magnitude changes on a decimal number - */ -class MagnitudeChange -{ - /** - * Multiplies a number by 10^$exponent. - * - * Examples: - * ```php - * $n = new Decimal\Number('123.45678'); - * $o = new Decimal\Operation\MagnitudeChange(); - * $o->compute($n, 2); // 12345.678 - * $o->compute($n, 6); // 123456780 - * $o->compute($n, -2); // 1.2345678 - * $o->compute($n, -6); // 0.00012345678 - * ``` - * - * @param DecimalNumber $number - * @param int $exponent - * - * @return DecimalNumber - */ - public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $exponent) - { - $exponent = (int) $exponent; - if ($exponent === 0) { - return $number; - } - $resultingExponent = $exponent - $number->getExponent(); - if ($resultingExponent <= 0) { - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number->getSign() . $number->getCoefficient(), \abs($resultingExponent)); - } - // add zeroes - $targetLength = \strlen($number->getCoefficient()) + $resultingExponent; - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number->getSign() . \str_pad($number->getCoefficient(), $targetLength, '0')); - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; +/** + * Computes relative magnitude changes on a decimal number + */ +class MagnitudeChange +{ + /** + * Multiplies a number by 10^$exponent. + * + * Examples: + * ```php + * $n = new Decimal\Number('123.45678'); + * $o = new Decimal\Operation\MagnitudeChange(); + * $o->compute($n, 2); // 12345.678 + * $o->compute($n, 6); // 123456780 + * $o->compute($n, -2); // 1.2345678 + * $o->compute($n, -6); // 0.00012345678 + * ``` + * + * @param DecimalNumber $number + * @param int $exponent + * + * @return DecimalNumber + */ + public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $exponent) + { + $exponent = (int) $exponent; + if ($exponent === 0) { + return $number; + } + $resultingExponent = $exponent - $number->getExponent(); + if ($resultingExponent <= 0) { + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number->getSign() . $number->getCoefficient(), \abs($resultingExponent)); + } + // add zeroes + $targetLength = \strlen($number->getCoefficient()) + $resultingExponent; + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number->getSign() . \str_pad($number->getCoefficient(), $targetLength, '0')); + } +} diff --git a/vendor/prestashop/decimal/src/Operation/Multiplication.php b/vendor/prestashop/decimal/src/Operation/Multiplication.php index 1848f4e24..5a22291b0 100644 --- a/vendor/prestashop/decimal/src/Operation/Multiplication.php +++ b/vendor/prestashop/decimal/src/Operation/Multiplication.php @@ -1,128 +1,128 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; -/** - * Computes the multiplication between two decimal numbers - */ -class Multiplication -{ - /** - * Performs the multiplication - * - * @param DecimalNumber $a Left operand - * @param DecimalNumber $b Right operand - * - * @return DecimalNumber Result of the multiplication - */ - public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - if (\function_exists('_PhpScoper5ea00cc67502b\\bcmul')) { - return $this->computeUsingBcMath($a, $b); - } - return $this->computeWithoutBcMath($a, $b); - } - /** - * Performs the multiplication using BC Math - * - * @param DecimalNumber $a Left operand - * @param DecimalNumber $b Right operand - * - * @return DecimalNumber Result of the multiplication - */ - public function computeUsingBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - $precision1 = $a->getPrecision(); - $precision2 = $b->getPrecision(); - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number((string) bcmul($a, $b, $precision1 + $precision2)); - } - /** - * Performs the multiplication without BC Math - * - * @param DecimalNumber $a Left operand - * @param DecimalNumber $b Right operand - * - * @return DecimalNumber Result of the multiplication - */ - public function computeWithoutBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - $aAsString = (string) $a; - $bAsString = (string) $b; - // optimization: if either one is zero, the result is zero - if ('0' === $aAsString || '0' === $bAsString) { - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0'); - } - // optimization: if either one is one, the result is the other one - if ('1' === $aAsString) { - return $b; - } - if ('1' === $bAsString) { - return $a; - } - $result = $this->multiplyStrings(\ltrim($a->getCoefficient(), '0'), \ltrim($b->getCoefficient(), '0')); - $sign = ($a->isNegative() xor $b->isNegative()) ? '-' : ''; - // a multiplication has at most as many decimal figures as the sum - // of the number of decimal figures the factors have - $exponent = $a->getExponent() + $b->getExponent(); - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($sign . $result, $exponent); - } - /** - * Multiplies two integer numbers as strings. - * - * This method implements a naive "long multiplication" algorithm. - * - * @param string $topNumber - * @param string $bottomNumber - * - * @return string - */ - private function multiplyStrings($topNumber, $bottomNumber) - { - $topNumberLength = \strlen($topNumber); - $bottomNumberLength = \strlen($bottomNumber); - if ($topNumberLength < $bottomNumberLength) { - // multiplication is commutative, and this algorithm - // performs better if the bottom number is shorter. - return $this->multiplyStrings($bottomNumber, $topNumber); - } - $stepNumber = 0; - $result = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0'); - for ($i = $bottomNumberLength - 1; $i >= 0; $i--) { - $carryOver = 0; - $partialResult = ''; - // optimization: we don't need to bother multiplying by zero - if ($bottomNumber[$i] === '0') { - $stepNumber++; - continue; - } - if ($bottomNumber[$i] === '1') { - // multiplying by one is the same as copying the top number - $partialResult = \strrev($topNumber); - } else { - // digit-by-digit multiplication using carry-over - for ($j = $topNumberLength - 1; $j >= 0; $j--) { - $multiplicationResult = $bottomNumber[$i] * $topNumber[$j] + $carryOver; - $carryOver = \floor($multiplicationResult / 10); - $partialResult .= $multiplicationResult % 10; - } - if ($carryOver > 0) { - $partialResult .= $carryOver; - } - } - // pad the partial result with as many zeros as performed steps - $padding = \str_pad('', $stepNumber, '0'); - $partialResult = $padding . $partialResult; - // add to the result - $result = $result->plus(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number(\strrev($partialResult))); - $stepNumber++; - } - return (string) $result; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; +/** + * Computes the multiplication between two decimal numbers + */ +class Multiplication +{ + /** + * Performs the multiplication + * + * @param DecimalNumber $a Left operand + * @param DecimalNumber $b Right operand + * + * @return DecimalNumber Result of the multiplication + */ + public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + if (\function_exists('_PhpScoper5ea00cc67502b\\bcmul')) { + return $this->computeUsingBcMath($a, $b); + } + return $this->computeWithoutBcMath($a, $b); + } + /** + * Performs the multiplication using BC Math + * + * @param DecimalNumber $a Left operand + * @param DecimalNumber $b Right operand + * + * @return DecimalNumber Result of the multiplication + */ + public function computeUsingBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + $precision1 = $a->getPrecision(); + $precision2 = $b->getPrecision(); + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number((string) bcmul($a, $b, $precision1 + $precision2)); + } + /** + * Performs the multiplication without BC Math + * + * @param DecimalNumber $a Left operand + * @param DecimalNumber $b Right operand + * + * @return DecimalNumber Result of the multiplication + */ + public function computeWithoutBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + $aAsString = (string) $a; + $bAsString = (string) $b; + // optimization: if either one is zero, the result is zero + if ('0' === $aAsString || '0' === $bAsString) { + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0'); + } + // optimization: if either one is one, the result is the other one + if ('1' === $aAsString) { + return $b; + } + if ('1' === $bAsString) { + return $a; + } + $result = $this->multiplyStrings(\ltrim($a->getCoefficient(), '0'), \ltrim($b->getCoefficient(), '0')); + $sign = ($a->isNegative() xor $b->isNegative()) ? '-' : ''; + // a multiplication has at most as many decimal figures as the sum + // of the number of decimal figures the factors have + $exponent = $a->getExponent() + $b->getExponent(); + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($sign . $result, $exponent); + } + /** + * Multiplies two integer numbers as strings. + * + * This method implements a naive "long multiplication" algorithm. + * + * @param string $topNumber + * @param string $bottomNumber + * + * @return string + */ + private function multiplyStrings($topNumber, $bottomNumber) + { + $topNumberLength = \strlen($topNumber); + $bottomNumberLength = \strlen($bottomNumber); + if ($topNumberLength < $bottomNumberLength) { + // multiplication is commutative, and this algorithm + // performs better if the bottom number is shorter. + return $this->multiplyStrings($bottomNumber, $topNumber); + } + $stepNumber = 0; + $result = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0'); + for ($i = $bottomNumberLength - 1; $i >= 0; $i--) { + $carryOver = 0; + $partialResult = ''; + // optimization: we don't need to bother multiplying by zero + if ($bottomNumber[$i] === '0') { + $stepNumber++; + continue; + } + if ($bottomNumber[$i] === '1') { + // multiplying by one is the same as copying the top number + $partialResult = \strrev($topNumber); + } else { + // digit-by-digit multiplication using carry-over + for ($j = $topNumberLength - 1; $j >= 0; $j--) { + $multiplicationResult = $bottomNumber[$i] * $topNumber[$j] + $carryOver; + $carryOver = \floor($multiplicationResult / 10); + $partialResult .= $multiplicationResult % 10; + } + if ($carryOver > 0) { + $partialResult .= $carryOver; + } + } + // pad the partial result with as many zeros as performed steps + $padding = \str_pad('', $stepNumber, '0'); + $partialResult = $padding . $partialResult; + // add to the result + $result = $result->plus(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number(\strrev($partialResult))); + $stepNumber++; + } + return (string) $result; + } +} diff --git a/vendor/prestashop/decimal/src/Operation/Rounding.php b/vendor/prestashop/decimal/src/Operation/Rounding.php index c0dd1404a..37c655b34 100644 --- a/vendor/prestashop/decimal/src/Operation/Rounding.php +++ b/vendor/prestashop/decimal/src/Operation/Rounding.php @@ -1,373 +1,373 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; -/** - * Allows transforming a decimal number's precision - */ -class Rounding -{ - const ROUND_TRUNCATE = 'truncate'; - const ROUND_CEIL = 'ceil'; - const ROUND_FLOOR = 'floor'; - const ROUND_HALF_UP = 'up'; - const ROUND_HALF_DOWN = 'down'; - const ROUND_HALF_EVEN = 'even'; - /** - * Rounds a decimal number to a specified precision - * - * @param DecimalNumber $number Number to round - * @param int $precision Maximum number of decimals - * @param string $roundingMode Rounding algorithm - * - * @return DecimalNumber - */ - public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision, $roundingMode) - { - switch ($roundingMode) { - case self::ROUND_HALF_UP: - return $this->roundHalfUp($number, $precision); - break; - case self::ROUND_CEIL: - return $this->ceil($number, $precision); - break; - case self::ROUND_FLOOR: - return $this->floor($number, $precision); - break; - case self::ROUND_HALF_DOWN: - return $this->roundHalfDown($number, $precision); - break; - case self::ROUND_TRUNCATE: - return $this->truncate($number, $precision); - break; - case self::ROUND_HALF_EVEN: - return $this->roundHalfEven($number, $precision); - break; - } - throw new \InvalidArgumentException(\sprintf("Invalid rounding mode: %s", \print_r($roundingMode, \true))); - } - /** - * Truncates a number to a target number of decimal digits. - * - * @param DecimalNumber $number Number to round - * @param int $precision Maximum number of decimals - * - * @return DecimalNumber - */ - public function truncate(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) - { - $precision = $this->sanitizePrecision($precision); - if ($number->getPrecision() <= $precision) { - return $number; - } - if (0 === $precision) { - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number->getSign() . $number->getIntegerPart()); - } - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number->getSign() . $number->getIntegerPart() . '.' . \substr($number->getFractionalPart(), 0, $precision)); - } - /** - * Rounds a number up if its precision is greater than the target one. - * - * Ceil always rounds towards positive infinity. - * - * Examples: - * - * ``` - * $n = new Decimal\Number('123.456'); - * $this->ceil($n, 0); // '124' - * $this->ceil($n, 1); // '123.5' - * $this->ceil($n, 2); // '123.46' - * - * $n = new Decimal\Number('-123.456'); - * $this->ceil($n, 0); // '-122' - * $this->ceil($n, 1); // '-123.3' - * $this->ceil($n, 2); // '-123.44' - * ``` - * - * @param DecimalNumber $number Number to round - * @param int $precision Maximum number of decimals - * - * @return DecimalNumber - */ - public function ceil(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) - { - $precision = $this->sanitizePrecision($precision); - if ($number->getPrecision() <= $precision) { - return $number; - } - if ($number->isNegative()) { - // ceil works exactly as truncate for negative numbers - return $this->truncate($number, $precision); - } - /** - * The principle for ceil is the following: - * - * let X = number to round - * P = number of decimal digits that we want - * D = digit from the fractional part at index P - * - * if D > 0, ceil(X, P) = truncate(X + 10^(-P), P) - * if D = 0, ceil(X, P) = truncate(X, P) - */ - if ($precision > 0) { - // we know that D > 0, because we have already checked that the number's precision - // is greater than the target precision - $numberToAdd = '0.' . \str_pad('1', $precision, '0', \STR_PAD_LEFT); - } else { - $numberToAdd = '1'; - } - return $this->truncate($number, $precision)->plus(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($numberToAdd)); - } - /** - * Rounds a number down if its precision is greater than the target one. - * - * Floor always rounds towards negative infinity. - * - * Examples: - * - * ``` - * $n = new Decimal\Number('123.456'); - * $this->floor($n, 0); // '123' - * $this->floor($n, 1); // '123.4' - * $this->floor($n, 2); // '123.45' - * - * $n = new Decimal\Number('-123.456'); - * $this->floor($n, 0); // '-124' - * $this->floor($n, 1); // '-123.5' - * $this->floor($n, 2); // '-123.46' - * ``` - * - * @param DecimalNumber $number Number to round - * @param int $precision Maximum number of decimals - * - * @return DecimalNumber - */ - public function floor(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) - { - $precision = $this->sanitizePrecision($precision); - if ($number->getPrecision() <= $precision) { - return $number; - } - if ($number->isPositive()) { - // floor works exactly as truncate for positive numbers - return $this->truncate($number, $precision); - } - /** - * The principle for ceil is the following: - * - * let X = number to round - * P = number of decimal digits that we want - * D = digit from the fractional part at index P - * - * if D < 0, ceil(X, P) = truncate(X - 10^(-P), P) - * if D = 0, ceil(X, P) = truncate(X, P) - */ - if ($precision > 0) { - // we know that D > 0, because we have already checked that the number's precision - // is greater than the target precision - $numberToSubtract = '0.' . \str_pad('1', $precision, '0', \STR_PAD_LEFT); - } else { - $numberToSubtract = '1'; - } - return $this->truncate($number, $precision)->minus(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($numberToSubtract)); - } - /** - * Rounds the number according to the digit D located at precision P. - * - It rounds away from zero if D >= 5 - * - It rounds towards zero if D < 5 - * - * Examples: - * - * ``` - * $n = new Decimal\Number('123.456'); - * $this->roundHalfUp($n, 0); // '123' - * $this->roundHalfUp($n, 1); // '123.5' - * $this->roundHalfUp($n, 2); // '123.46' - * - * $n = new Decimal\Number('-123.456'); - * $this->roundHalfUp($n, 0); // '-123' - * $this->roundHalfUp($n, 1); // '-123.5' - * $this->roundHalfUp($n, 2); // '-123.46' - * ``` - * - * @param DecimalNumber $number Number to round - * @param int $precision Maximum number of decimals - * - * @return DecimalNumber - */ - public function roundHalfUp(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) - { - return $this->roundHalf($number, $precision, 5); - } - /** - * Rounds the number according to the digit D located at precision P. - * - It rounds away from zero if D > 5 - * - It rounds towards zero if D <= 5 - * - * Examples: - * - * ``` - * $n = new Decimal\Number('123.456'); - * $this->roundHalfUp($n, 0); // '123' - * $this->roundHalfUp($n, 1); // '123.4' - * $this->roundHalfUp($n, 2); // '123.46' - * - * $n = new Decimal\Number('-123.456'); - * $this->roundHalfUp($n, 0); // '-123' - * $this->roundHalfUp($n, 1); // '-123.4' - * $this->roundHalfUp($n, 2); // '-123.46' - * ``` - * - * @param DecimalNumber $number Number to round - * @param int $precision Maximum number of decimals - * - * @return DecimalNumber - */ - public function roundHalfDown(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) - { - return $this->roundHalf($number, $precision, 6); - } - /** - * Rounds a number according to "banker's rounding". - * - * The number is rounded according to the digit D located at precision P. - * - Away from zero if D > 5 - * - Towards zero if D < 5 - * - if D = 5, then - * - If the last significant digit is even, the number is rounded away from zero - * - If the last significant digit is odd, the number is rounded towards zero. - * - * Examples: - * - * ``` - * $n = new Decimal\Number('123.456'); - * $this->roundHalfUp($n, 0); // '123' - * $this->roundHalfUp($n, 1); // '123.4' - * $this->roundHalfUp($n, 2); // '123.46' - * - * $n = new Decimal\Number('-123.456'); - * $this->roundHalfUp($n, 0); // '-123' - * $this->roundHalfUp($n, 1); // '-123.4' - * $this->roundHalfUp($n, 2); // '-123.46' - * - * $n = new Decimal\Number('1.1525354556575859505'); - * $this->roundHalfEven($n, 0); // '1' - * $this->roundHalfEven($n, 1); // '1.2' - * $this->roundHalfEven($n, 2); // '1.15' - * $this->roundHalfEven($n, 3); // '1.152' - * $this->roundHalfEven($n, 4); // '1.1525' - * $this->roundHalfEven($n, 5); // '1.15255' - * $this->roundHalfEven($n, 6); // '1.152535' - * $this->roundHalfEven($n, 7); // '1.1525354' - * $this->roundHalfEven($n, 8); // '1.15253546' - * $this->roundHalfEven($n, 9); // '1.152535456' - * $this->roundHalfEven($n, 10); // '1.1525354556' - * ``` - * - * @param DecimalNumber $number Number to round - * @param int $precision Maximum number of decimals - * - * @return DecimalNumber - */ - public function roundHalfEven(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) - { - $precision = $this->sanitizePrecision($precision); - if ($number->getPrecision() <= $precision) { - return $number; - } - /** - * The principle for roundHalfEven is the following: - * - * let X = number to round - * P = number of decimal digits that we want - * D = digit from the fractional part at index P - * E = digit to the left of D - * - * if D != 5, roundHalfEven(X, P) = roundHalfUp(X, P) - * if D = 5 and E is even, roundHalfEven(X, P) = truncate(X, P) - * if D = 5 and E is odd and X is positive, roundHalfUp(X, P) = ceil(X, P) - * if D = 5 and E is odd and X is negative, roundHalfUp(X, P) = floor(X, P) - */ - $fractionalPart = $number->getFractionalPart(); - $digit = (int) $fractionalPart[$precision]; - if ($digit !== 5) { - return $this->roundHalfUp($number, $precision); - } - // retrieve the digit to the left of it - if ($precision === 0) { - $referenceDigit = (int) \substr($number->getIntegerPart(), -1); - } else { - $referenceDigit = (int) $fractionalPart[$precision - 1]; - } - // truncate if even - $isEven = $referenceDigit % 2 === 0; - if ($isEven) { - return $this->truncate($number, $precision); - } - // round away from zero - $method = $number->isPositive() ? self::ROUND_CEIL : self::ROUND_FLOOR; - return $this->compute($number, $precision, $method); - } - /** - * Rounds the number according to the digit D located at precision P. - * - It rounds away from zero if D >= $halfwayValue - * - It rounds towards zero if D < $halfWayValue - * - * @param DecimalNumber $number Number to round - * @param int $precision Maximum number of decimals - * @param int $halfwayValue Threshold upon which the rounding will be performed - * away from zero instead of towards zero. - * - * @return DecimalNumber - */ - private function roundHalf(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision, $halfwayValue) - { - $precision = $this->sanitizePrecision($precision); - if ($number->getPrecision() <= $precision) { - return $number; - } - /** - * The principle for roundHalf is the following: - * - * let X = number to round - * P = number of decimal digits that we want - * D = digit from the fractional part at index P - * Y = digit considered as the half-way value on which we round up (usually 5 or 6) - * - * if D >= Y, roundHalf(X, P) = ceil(X, P) - * if D < Y, roundHalf(X, P) = truncate(X, P) - */ - $fractionalPart = $number->getFractionalPart(); - $digit = (int) $fractionalPart[$precision]; - if ($digit >= $halfwayValue) { - // round away from zero - $mode = $number->isPositive() ? self::ROUND_CEIL : self::ROUND_FLOOR; - return $this->compute($number, $precision, $mode); - } - // round towards zero - return $this->truncate($number, $precision); - } - /** - * Ensures that precision is a positive int - * - * @param mixed $precision - * - * @return int Precision - * - * @throws \InvalidArgumentException if precision is not a positive integer - */ - private function sanitizePrecision($precision) - { - if (!\is_numeric($precision) || $precision < 0) { - throw new \InvalidArgumentException(\sprintf('Invalid precision: %s', \print_r($precision, \true))); - } - return (int) $precision; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; +/** + * Allows transforming a decimal number's precision + */ +class Rounding +{ + const ROUND_TRUNCATE = 'truncate'; + const ROUND_CEIL = 'ceil'; + const ROUND_FLOOR = 'floor'; + const ROUND_HALF_UP = 'up'; + const ROUND_HALF_DOWN = 'down'; + const ROUND_HALF_EVEN = 'even'; + /** + * Rounds a decimal number to a specified precision + * + * @param DecimalNumber $number Number to round + * @param int $precision Maximum number of decimals + * @param string $roundingMode Rounding algorithm + * + * @return DecimalNumber + */ + public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision, $roundingMode) + { + switch ($roundingMode) { + case self::ROUND_HALF_UP: + return $this->roundHalfUp($number, $precision); + break; + case self::ROUND_CEIL: + return $this->ceil($number, $precision); + break; + case self::ROUND_FLOOR: + return $this->floor($number, $precision); + break; + case self::ROUND_HALF_DOWN: + return $this->roundHalfDown($number, $precision); + break; + case self::ROUND_TRUNCATE: + return $this->truncate($number, $precision); + break; + case self::ROUND_HALF_EVEN: + return $this->roundHalfEven($number, $precision); + break; + } + throw new \InvalidArgumentException(\sprintf("Invalid rounding mode: %s", \print_r($roundingMode, \true))); + } + /** + * Truncates a number to a target number of decimal digits. + * + * @param DecimalNumber $number Number to round + * @param int $precision Maximum number of decimals + * + * @return DecimalNumber + */ + public function truncate(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) + { + $precision = $this->sanitizePrecision($precision); + if ($number->getPrecision() <= $precision) { + return $number; + } + if (0 === $precision) { + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number->getSign() . $number->getIntegerPart()); + } + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number->getSign() . $number->getIntegerPart() . '.' . \substr($number->getFractionalPart(), 0, $precision)); + } + /** + * Rounds a number up if its precision is greater than the target one. + * + * Ceil always rounds towards positive infinity. + * + * Examples: + * + * ``` + * $n = new Decimal\Number('123.456'); + * $this->ceil($n, 0); // '124' + * $this->ceil($n, 1); // '123.5' + * $this->ceil($n, 2); // '123.46' + * + * $n = new Decimal\Number('-123.456'); + * $this->ceil($n, 0); // '-122' + * $this->ceil($n, 1); // '-123.3' + * $this->ceil($n, 2); // '-123.44' + * ``` + * + * @param DecimalNumber $number Number to round + * @param int $precision Maximum number of decimals + * + * @return DecimalNumber + */ + public function ceil(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) + { + $precision = $this->sanitizePrecision($precision); + if ($number->getPrecision() <= $precision) { + return $number; + } + if ($number->isNegative()) { + // ceil works exactly as truncate for negative numbers + return $this->truncate($number, $precision); + } + /** + * The principle for ceil is the following: + * + * let X = number to round + * P = number of decimal digits that we want + * D = digit from the fractional part at index P + * + * if D > 0, ceil(X, P) = truncate(X + 10^(-P), P) + * if D = 0, ceil(X, P) = truncate(X, P) + */ + if ($precision > 0) { + // we know that D > 0, because we have already checked that the number's precision + // is greater than the target precision + $numberToAdd = '0.' . \str_pad('1', $precision, '0', \STR_PAD_LEFT); + } else { + $numberToAdd = '1'; + } + return $this->truncate($number, $precision)->plus(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($numberToAdd)); + } + /** + * Rounds a number down if its precision is greater than the target one. + * + * Floor always rounds towards negative infinity. + * + * Examples: + * + * ``` + * $n = new Decimal\Number('123.456'); + * $this->floor($n, 0); // '123' + * $this->floor($n, 1); // '123.4' + * $this->floor($n, 2); // '123.45' + * + * $n = new Decimal\Number('-123.456'); + * $this->floor($n, 0); // '-124' + * $this->floor($n, 1); // '-123.5' + * $this->floor($n, 2); // '-123.46' + * ``` + * + * @param DecimalNumber $number Number to round + * @param int $precision Maximum number of decimals + * + * @return DecimalNumber + */ + public function floor(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) + { + $precision = $this->sanitizePrecision($precision); + if ($number->getPrecision() <= $precision) { + return $number; + } + if ($number->isPositive()) { + // floor works exactly as truncate for positive numbers + return $this->truncate($number, $precision); + } + /** + * The principle for ceil is the following: + * + * let X = number to round + * P = number of decimal digits that we want + * D = digit from the fractional part at index P + * + * if D < 0, ceil(X, P) = truncate(X - 10^(-P), P) + * if D = 0, ceil(X, P) = truncate(X, P) + */ + if ($precision > 0) { + // we know that D > 0, because we have already checked that the number's precision + // is greater than the target precision + $numberToSubtract = '0.' . \str_pad('1', $precision, '0', \STR_PAD_LEFT); + } else { + $numberToSubtract = '1'; + } + return $this->truncate($number, $precision)->minus(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($numberToSubtract)); + } + /** + * Rounds the number according to the digit D located at precision P. + * - It rounds away from zero if D >= 5 + * - It rounds towards zero if D < 5 + * + * Examples: + * + * ``` + * $n = new Decimal\Number('123.456'); + * $this->roundHalfUp($n, 0); // '123' + * $this->roundHalfUp($n, 1); // '123.5' + * $this->roundHalfUp($n, 2); // '123.46' + * + * $n = new Decimal\Number('-123.456'); + * $this->roundHalfUp($n, 0); // '-123' + * $this->roundHalfUp($n, 1); // '-123.5' + * $this->roundHalfUp($n, 2); // '-123.46' + * ``` + * + * @param DecimalNumber $number Number to round + * @param int $precision Maximum number of decimals + * + * @return DecimalNumber + */ + public function roundHalfUp(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) + { + return $this->roundHalf($number, $precision, 5); + } + /** + * Rounds the number according to the digit D located at precision P. + * - It rounds away from zero if D > 5 + * - It rounds towards zero if D <= 5 + * + * Examples: + * + * ``` + * $n = new Decimal\Number('123.456'); + * $this->roundHalfUp($n, 0); // '123' + * $this->roundHalfUp($n, 1); // '123.4' + * $this->roundHalfUp($n, 2); // '123.46' + * + * $n = new Decimal\Number('-123.456'); + * $this->roundHalfUp($n, 0); // '-123' + * $this->roundHalfUp($n, 1); // '-123.4' + * $this->roundHalfUp($n, 2); // '-123.46' + * ``` + * + * @param DecimalNumber $number Number to round + * @param int $precision Maximum number of decimals + * + * @return DecimalNumber + */ + public function roundHalfDown(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) + { + return $this->roundHalf($number, $precision, 6); + } + /** + * Rounds a number according to "banker's rounding". + * + * The number is rounded according to the digit D located at precision P. + * - Away from zero if D > 5 + * - Towards zero if D < 5 + * - if D = 5, then + * - If the last significant digit is even, the number is rounded away from zero + * - If the last significant digit is odd, the number is rounded towards zero. + * + * Examples: + * + * ``` + * $n = new Decimal\Number('123.456'); + * $this->roundHalfUp($n, 0); // '123' + * $this->roundHalfUp($n, 1); // '123.4' + * $this->roundHalfUp($n, 2); // '123.46' + * + * $n = new Decimal\Number('-123.456'); + * $this->roundHalfUp($n, 0); // '-123' + * $this->roundHalfUp($n, 1); // '-123.4' + * $this->roundHalfUp($n, 2); // '-123.46' + * + * $n = new Decimal\Number('1.1525354556575859505'); + * $this->roundHalfEven($n, 0); // '1' + * $this->roundHalfEven($n, 1); // '1.2' + * $this->roundHalfEven($n, 2); // '1.15' + * $this->roundHalfEven($n, 3); // '1.152' + * $this->roundHalfEven($n, 4); // '1.1525' + * $this->roundHalfEven($n, 5); // '1.15255' + * $this->roundHalfEven($n, 6); // '1.152535' + * $this->roundHalfEven($n, 7); // '1.1525354' + * $this->roundHalfEven($n, 8); // '1.15253546' + * $this->roundHalfEven($n, 9); // '1.152535456' + * $this->roundHalfEven($n, 10); // '1.1525354556' + * ``` + * + * @param DecimalNumber $number Number to round + * @param int $precision Maximum number of decimals + * + * @return DecimalNumber + */ + public function roundHalfEven(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision) + { + $precision = $this->sanitizePrecision($precision); + if ($number->getPrecision() <= $precision) { + return $number; + } + /** + * The principle for roundHalfEven is the following: + * + * let X = number to round + * P = number of decimal digits that we want + * D = digit from the fractional part at index P + * E = digit to the left of D + * + * if D != 5, roundHalfEven(X, P) = roundHalfUp(X, P) + * if D = 5 and E is even, roundHalfEven(X, P) = truncate(X, P) + * if D = 5 and E is odd and X is positive, roundHalfUp(X, P) = ceil(X, P) + * if D = 5 and E is odd and X is negative, roundHalfUp(X, P) = floor(X, P) + */ + $fractionalPart = $number->getFractionalPart(); + $digit = (int) $fractionalPart[$precision]; + if ($digit !== 5) { + return $this->roundHalfUp($number, $precision); + } + // retrieve the digit to the left of it + if ($precision === 0) { + $referenceDigit = (int) \substr($number->getIntegerPart(), -1); + } else { + $referenceDigit = (int) $fractionalPart[$precision - 1]; + } + // truncate if even + $isEven = $referenceDigit % 2 === 0; + if ($isEven) { + return $this->truncate($number, $precision); + } + // round away from zero + $method = $number->isPositive() ? self::ROUND_CEIL : self::ROUND_FLOOR; + return $this->compute($number, $precision, $method); + } + /** + * Rounds the number according to the digit D located at precision P. + * - It rounds away from zero if D >= $halfwayValue + * - It rounds towards zero if D < $halfWayValue + * + * @param DecimalNumber $number Number to round + * @param int $precision Maximum number of decimals + * @param int $halfwayValue Threshold upon which the rounding will be performed + * away from zero instead of towards zero. + * + * @return DecimalNumber + */ + private function roundHalf(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $number, $precision, $halfwayValue) + { + $precision = $this->sanitizePrecision($precision); + if ($number->getPrecision() <= $precision) { + return $number; + } + /** + * The principle for roundHalf is the following: + * + * let X = number to round + * P = number of decimal digits that we want + * D = digit from the fractional part at index P + * Y = digit considered as the half-way value on which we round up (usually 5 or 6) + * + * if D >= Y, roundHalf(X, P) = ceil(X, P) + * if D < Y, roundHalf(X, P) = truncate(X, P) + */ + $fractionalPart = $number->getFractionalPart(); + $digit = (int) $fractionalPart[$precision]; + if ($digit >= $halfwayValue) { + // round away from zero + $mode = $number->isPositive() ? self::ROUND_CEIL : self::ROUND_FLOOR; + return $this->compute($number, $precision, $mode); + } + // round towards zero + return $this->truncate($number, $precision); + } + /** + * Ensures that precision is a positive int + * + * @param mixed $precision + * + * @return int Precision + * + * @throws \InvalidArgumentException if precision is not a positive integer + */ + private function sanitizePrecision($precision) + { + if (!\is_numeric($precision) || $precision < 0) { + throw new \InvalidArgumentException(\sprintf('Invalid precision: %s', \print_r($precision, \true))); + } + return (int) $precision; + } +} diff --git a/vendor/prestashop/decimal/src/Operation/Subtraction.php b/vendor/prestashop/decimal/src/Operation/Subtraction.php index 054ea3a32..f2d879687 100644 --- a/vendor/prestashop/decimal/src/Operation/Subtraction.php +++ b/vendor/prestashop/decimal/src/Operation/Subtraction.php @@ -1,179 +1,179 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; -/** - * Computes the subtraction of two decimal numbers - */ -class Subtraction -{ - /** - * Maximum safe string size in order to be confident - * that it won't overflow the max int size when operating with it - * @var int - */ - private $maxSafeIntStringSize; - /** - * Constructor - */ - public function __construct() - { - $this->maxSafeIntStringSize = \strlen((string) \PHP_INT_MAX) - 1; - } - /** - * Performs the subtraction - * - * @param DecimalNumber $a Minuend - * @param DecimalNumber $b Subtrahend - * - * @return DecimalNumber Result of the subtraction - */ - public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - if (\function_exists('_PhpScoper5ea00cc67502b\\bcsub')) { - return $this->computeUsingBcMath($a, $b); - } - return $this->computeWithoutBcMath($a, $b); - } - /** - * Performs the subtraction using BC Math - * - * @param DecimalNumber $a Minuend - * @param DecimalNumber $b Subtrahend - * - * @return DecimalNumber Result of the subtraction - */ - public function computeUsingBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - $precision1 = $a->getPrecision(); - $precision2 = $b->getPrecision(); - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number((string) bcsub($a, $b, \max($precision1, $precision2))); - } - /** - * Performs the subtraction without using BC Math - * - * @param DecimalNumber $a Minuend - * @param DecimalNumber $b Subtrahend - * - * @return DecimalNumber Result of the subtraction - */ - public function computeWithoutBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - if ($a->isNegative()) { - if ($b->isNegative()) { - // if both minuend and subtrahend are negative - // perform the subtraction with inverted coefficients position and sign - // f(x, y) = |y| - |x| - // eg. f(-1, -2) = |-2| - |-1| = 2 - 1 = 1 - // e.g. f(-2, -1) = |-1| - |-2| = 1 - 2 = -1 - return $this->computeWithoutBcMath($b->toPositive(), $a->toPositive()); - } else { - // if the minuend is negative and the subtrahend is positive, - // we can just add them as positive numbers and then invert the sign - // f(x, y) = -(|x| + y) - // eg. f(1, 2) = -(|-1| + 2) = -3 - // eg. f(-2, 1) = -(|-2| + 1) = -3 - return $a->toPositive()->plus($b)->toNegative(); - } - } else { - if ($b->isNegative()) { - // if the minuend is positive subtrahend is negative, perform an addition - // f(x, y) = x + |y| - // eg. f(2, -1) = 2 + |-1| = 2 + 1 = 3 - return $a->plus($b->toPositive()); - } - } - // optimization: 0 - x = -x - if ('0' === (string) $a) { - return !$b->isNegative() ? $b->toNegative() : $b; - } - // optimization: x - 0 = x - if ('0' === (string) $b) { - return $a; - } - // pad coefficients with leading/trailing zeroes - list($coeff1, $coeff2) = $this->normalizeCoefficients($a, $b); - // compute the coefficient subtraction - if ($a->isGreaterThan($b)) { - $sub = $this->subtractStrings($coeff1, $coeff2); - $sign = ''; - } else { - $sub = $this->subtractStrings($coeff2, $coeff1); - $sign = '-'; - } - // keep the bigger exponent - $exponent = \max($a->getExponent(), $b->getExponent()); - return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($sign . $sub, $exponent); - } - /** - * Normalizes coefficients by adding leading or trailing zeroes as needed so that both are the same length - * - * @param DecimalNumber $a - * @param DecimalNumber $b - * - * @return array An array containing the normalized coefficients - */ - private function normalizeCoefficients(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) - { - $exp1 = $a->getExponent(); - $exp2 = $b->getExponent(); - $coeff1 = $a->getCoefficient(); - $coeff2 = $b->getCoefficient(); - // add trailing zeroes if needed - if ($exp1 > $exp2) { - $coeff2 = \str_pad($coeff2, \strlen($coeff2) + $exp1 - $exp2, '0', \STR_PAD_RIGHT); - } elseif ($exp1 < $exp2) { - $coeff1 = \str_pad($coeff1, \strlen($coeff1) + $exp2 - $exp1, '0', \STR_PAD_RIGHT); - } - $len1 = \strlen($coeff1); - $len2 = \strlen($coeff2); - // add leading zeroes if needed - if ($len1 > $len2) { - $coeff2 = \str_pad($coeff2, $len1, '0', \STR_PAD_LEFT); - } elseif ($len1 < $len2) { - $coeff1 = \str_pad($coeff1, $len2, '0', \STR_PAD_LEFT); - } - return [$coeff1, $coeff2]; - } - /** - * Subtracts $number2 to $number1. - * For this algorithm to work, $number1 has to be >= $number 2. - * - * @param string $number1 - * @param string $number2 - * @param bool $fractional [default=false] - * If true, the numbers will be treated as the fractional part of a number (padded with trailing zeroes). - * Otherwise, they will be treated as the integer part (padded with leading zeroes). - * - * @return string - */ - private function subtractStrings($number1, $number2, $fractional = \false) - { - // find out which of the strings is longest - $maxLength = \max(\strlen($number1), \strlen($number2)); - // add leading or trailing zeroes as needed - $number1 = \str_pad($number1, $maxLength, '0', $fractional ? \STR_PAD_RIGHT : \STR_PAD_LEFT); - $number2 = \str_pad($number2, $maxLength, '0', $fractional ? \STR_PAD_RIGHT : \STR_PAD_LEFT); - $result = ''; - $carryOver = 0; - for ($i = $maxLength - 1; 0 <= $i; $i--) { - $operand1 = $number1[$i] - $carryOver; - $operand2 = $number2[$i]; - if ($operand1 >= $operand2) { - $result .= $operand1 - $operand2; - $carryOver = 0; - } else { - $result .= 10 + $operand1 - $operand2; - $carryOver = 1; - } - } - return \strrev($result); - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number as DecimalNumber; +/** + * Computes the subtraction of two decimal numbers + */ +class Subtraction +{ + /** + * Maximum safe string size in order to be confident + * that it won't overflow the max int size when operating with it + * @var int + */ + private $maxSafeIntStringSize; + /** + * Constructor + */ + public function __construct() + { + $this->maxSafeIntStringSize = \strlen((string) \PHP_INT_MAX) - 1; + } + /** + * Performs the subtraction + * + * @param DecimalNumber $a Minuend + * @param DecimalNumber $b Subtrahend + * + * @return DecimalNumber Result of the subtraction + */ + public function compute(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + if (\function_exists('_PhpScoper5ea00cc67502b\\bcsub')) { + return $this->computeUsingBcMath($a, $b); + } + return $this->computeWithoutBcMath($a, $b); + } + /** + * Performs the subtraction using BC Math + * + * @param DecimalNumber $a Minuend + * @param DecimalNumber $b Subtrahend + * + * @return DecimalNumber Result of the subtraction + */ + public function computeUsingBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + $precision1 = $a->getPrecision(); + $precision2 = $b->getPrecision(); + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number((string) bcsub($a, $b, \max($precision1, $precision2))); + } + /** + * Performs the subtraction without using BC Math + * + * @param DecimalNumber $a Minuend + * @param DecimalNumber $b Subtrahend + * + * @return DecimalNumber Result of the subtraction + */ + public function computeWithoutBcMath(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + if ($a->isNegative()) { + if ($b->isNegative()) { + // if both minuend and subtrahend are negative + // perform the subtraction with inverted coefficients position and sign + // f(x, y) = |y| - |x| + // eg. f(-1, -2) = |-2| - |-1| = 2 - 1 = 1 + // e.g. f(-2, -1) = |-1| - |-2| = 1 - 2 = -1 + return $this->computeWithoutBcMath($b->toPositive(), $a->toPositive()); + } else { + // if the minuend is negative and the subtrahend is positive, + // we can just add them as positive numbers and then invert the sign + // f(x, y) = -(|x| + y) + // eg. f(1, 2) = -(|-1| + 2) = -3 + // eg. f(-2, 1) = -(|-2| + 1) = -3 + return $a->toPositive()->plus($b)->toNegative(); + } + } else { + if ($b->isNegative()) { + // if the minuend is positive subtrahend is negative, perform an addition + // f(x, y) = x + |y| + // eg. f(2, -1) = 2 + |-1| = 2 + 1 = 3 + return $a->plus($b->toPositive()); + } + } + // optimization: 0 - x = -x + if ('0' === (string) $a) { + return !$b->isNegative() ? $b->toNegative() : $b; + } + // optimization: x - 0 = x + if ('0' === (string) $b) { + return $a; + } + // pad coefficients with leading/trailing zeroes + list($coeff1, $coeff2) = $this->normalizeCoefficients($a, $b); + // compute the coefficient subtraction + if ($a->isGreaterThan($b)) { + $sub = $this->subtractStrings($coeff1, $coeff2); + $sign = ''; + } else { + $sub = $this->subtractStrings($coeff2, $coeff1); + $sign = '-'; + } + // keep the bigger exponent + $exponent = \max($a->getExponent(), $b->getExponent()); + return new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($sign . $sub, $exponent); + } + /** + * Normalizes coefficients by adding leading or trailing zeroes as needed so that both are the same length + * + * @param DecimalNumber $a + * @param DecimalNumber $b + * + * @return array An array containing the normalized coefficients + */ + private function normalizeCoefficients(\_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $a, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number $b) + { + $exp1 = $a->getExponent(); + $exp2 = $b->getExponent(); + $coeff1 = $a->getCoefficient(); + $coeff2 = $b->getCoefficient(); + // add trailing zeroes if needed + if ($exp1 > $exp2) { + $coeff2 = \str_pad($coeff2, \strlen($coeff2) + $exp1 - $exp2, '0', \STR_PAD_RIGHT); + } elseif ($exp1 < $exp2) { + $coeff1 = \str_pad($coeff1, \strlen($coeff1) + $exp2 - $exp1, '0', \STR_PAD_RIGHT); + } + $len1 = \strlen($coeff1); + $len2 = \strlen($coeff2); + // add leading zeroes if needed + if ($len1 > $len2) { + $coeff2 = \str_pad($coeff2, $len1, '0', \STR_PAD_LEFT); + } elseif ($len1 < $len2) { + $coeff1 = \str_pad($coeff1, $len2, '0', \STR_PAD_LEFT); + } + return [$coeff1, $coeff2]; + } + /** + * Subtracts $number2 to $number1. + * For this algorithm to work, $number1 has to be >= $number 2. + * + * @param string $number1 + * @param string $number2 + * @param bool $fractional [default=false] + * If true, the numbers will be treated as the fractional part of a number (padded with trailing zeroes). + * Otherwise, they will be treated as the integer part (padded with leading zeroes). + * + * @return string + */ + private function subtractStrings($number1, $number2, $fractional = \false) + { + // find out which of the strings is longest + $maxLength = \max(\strlen($number1), \strlen($number2)); + // add leading or trailing zeroes as needed + $number1 = \str_pad($number1, $maxLength, '0', $fractional ? \STR_PAD_RIGHT : \STR_PAD_LEFT); + $number2 = \str_pad($number2, $maxLength, '0', $fractional ? \STR_PAD_RIGHT : \STR_PAD_LEFT); + $result = ''; + $carryOver = 0; + for ($i = $maxLength - 1; 0 <= $i; $i--) { + $operand1 = $number1[$i] - $carryOver; + $operand2 = $number2[$i]; + if ($operand1 >= $operand2) { + $result .= $operand1 - $operand2; + $carryOver = 0; + } else { + $result .= 10 + $operand1 - $operand2; + $carryOver = 1; + } + } + return \strrev($result); + } +} diff --git a/vendor/prestashop/decimal/tests/NumberTest.php b/vendor/prestashop/decimal/tests/NumberTest.php index 9b452f80c..a99af3f23 100644 --- a/vendor/prestashop/decimal/tests/NumberTest.php +++ b/vendor/prestashop/decimal/tests/NumberTest.php @@ -1,410 +1,410 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\tests\Unit\Core\Decimal; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding; -class NumberTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase -{ - /** - * Given a valid number in a string - * When constructing a Number with it - * Then it should interpret the sign, decimal and fractional parts correctly - * - * @param string $number - * @param string $expectedSign - * @param string $expectedInteger - * @param string $expectedFraction - * @param string $expectedStr - * - * @dataProvider provideValidNumbers - */ - public function testItInterpretsNumbers($number, $expectedSign, $expectedInteger, $expectedFraction, $expectedStr) - { - $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $this->assertSame($expectedSign, $decimalNumber->getSign(), 'The sign is not as expected'); - $this->assertSame($expectedInteger, $decimalNumber->getIntegerPart(), 'The integer part is not as expected'); - $this->assertSame($expectedFraction, $decimalNumber->getFractionalPart(), 'The fraction part is not as expected'); - $this->assertSame($expectedStr, (string) $decimalNumber, 'The string representation is not as expected'); - } - /** - * Given a valid coefficient and exponent - * When constructing a Number with them - * Then it should convert them to the expected string - * - * @param string $coefficient - * @param int $exponent - * @param string $expectedStr - * - * @dataProvider provideValidExponents - */ - public function testItInterpretsExponents($coefficient, $exponent, $expectedStr) - { - $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($coefficient, $exponent); - $this->assertSame($expectedStr, (string) $decimalNumber); - } - /** - * Given an invalid number - * When constructing a Number with it - * Then an InvalidArgumentException should be thrown - * - * @param mixed $number - * - * @dataProvider provideInvalidNumbers - * @expectedException \InvalidArgumentException - */ - public function testItThrowsExceptionWhenGivenInvalidNumber($number) - { - new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - } - /** - * Given an invalid coefficient or exponent - * When constructing a Number with them - * Then an InvalidArgumentException should be thrown - * - * @param mixed $coefficient - * @param mixed $exponent - * - * @dataProvider provideInvalidCoefficients - * @expectedException \InvalidArgumentException - */ - public function testItThrowsExceptionWhenGivenInvalidCoefficientOrExponent($coefficient, $exponent) - { - new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($coefficient, $exponent); - } - /** - * Given a Number constructed with a valid number - * When casting the number to string - * The resulting string should not include leading nor trailing zeroes - * - * @param string $number - * @param string $expected - * - * @dataProvider provideNumbersWithNonSignificantCharacters - */ - public function testItDropsNonSignificantDigits($number, $expected) - { - $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $this->assertSame($expected, (string) $decimalNumber); - } - /** - * Given a Number constructed with a valid number - * When rounding it to a specific precision, using a specific rounding mode - * The returned string should match the expectation - * - * @param string $number - * @param int $precision Number of decimal characters - * @param string $mode Rounding mode - * @param string $expected Expected result - * - * @dataProvider providePrecisionTestCases - */ - public function testPrecision($number, $precision, $mode, $expected) - { - $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $this->assertSame($expected, (string) $decimalNumber->toPrecision($precision, $mode)); - } - /** - * Given a Number constructed with a valid number - * When rounding it to a specific precision, using a specific rounding mode - * The returned string should match the expectation - * - * @param string $number - * @param int $precision Number of decimal characters - * @param string $mode Rounding mode - * @param string $expected Expected result - * - * @dataProvider provideRoundingTestCases - */ - public function testRounding($number, $precision, $mode, $expected) - { - $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $this->assertSame($expected, (string) $decimalNumber->round($precision, $mode), "Failed to assert that round {$number} to {$precision} decimals = {$expected}"); - } - /** - * Given a Number constructed with a valid number - * When rounding it to a greater precision than its current one - * The returned string should have been padded with the proper number of trailing zeroes - * - * @param string $number - * @param int $precision Target precision - * @param string $expected Expected result - * - * @dataProvider provideExtendedPrecisionTestCases - */ - public function testItExtendsPrecisionAsNeeded($number, $precision, $expected) - { - $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $this->assertSame($expected, (string) $decimalNumber->toPrecision($precision), "Failed to assert that fixing {$number} to {$precision} decimals = {$expected}"); - } - /** - * Given two instances of Number - * When comparing the first one with the second one - * Then the result should be true if the instances are equal, and false otherwise - * - * @param Number $number1 - * @param Number $number2 - * @param string $expected - * - * @dataProvider provideEqualityTestCases - */ - public function testItIsAbleToTellIfEqual($number1, $number2, $expected) - { - $this->assertSame($expected, $number1->equals($number2), \sprintf('Failed to assert equality between "%s" and "%s"', $number1, $number2)); - } - /** - * Given two numbers - * When asked if one number is greater than the other - * Then result should be true if the A > B, and false otherwise - * - * @param string $number1 - * @param string $number2 - * @param int $expected - * - * @dataProvider provideComparisonTestCases - */ - public function testIsAbleToTellIfGreaterThan($number1, $number2, $expected) - { - $shouldBeGreater = 1 === $expected; - $number1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); - $number2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); - $this->assertSame($number1->isGreaterThan($number2), $shouldBeGreater); - } - /** - * Given two numbers - * When asked if one number is lower than the other - * Then result should be true if the A < B, and false otherwise - * - * @param string $number1 - * @param string $number2 - * @param int $expected - * - * @dataProvider provideComparisonTestCases - */ - public function testIsAbleToTellIfLowerThan($number1, $number2, $expected) - { - $shouldBeLower = -1 === $expected; - $number1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); - $number2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); - $this->assertSame($number1->isLowerThan($number2), $shouldBeLower); - } - /** - * Given a positive number - * When it's transformed to negative - * Then we should get the negative equivalent of the base number - * - * @param string $number - * @param string $expected - * - * @dataProvider provideToNegativeTransformationCases - */ - public function testItTransformsPositiveToNegative($number, $expected) - { - $number = (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number))->toNegative(); - $this->assertSame((string) $number, $expected); - } - /** - * Given a negative number - * When it's transformed to positive - * Then we should get the positive equivalent of the base number - * - * @param string $number - * @param string $expected - * - * @dataProvider provideToPositiveTransformationCases - */ - public function testItTransformsNegativeToPositive($number, $expected) - { - $number = (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number))->toPositive(); - $this->assertSame((string) $number, $expected); - } - public function provideValidNumbers() - { - return [['number' => '0.0', 'expectedSign' => '', 'expectedInteger' => '0', 'expectedFraction' => '0', 'expectedStr' => '0'], ['00000.0', '', '0', '0', '0'], ['0.00000', '', '0', '0', '0'], ['00000.00000', '', '0', '0', '0'], ['0.1', '', '0', '1', '0.1'], ['1.0', '', '1', '0', '1'], ['1.1', '', '1', '1', '1.1'], ['1.234', '', '1', '234', '1.234'], ['0.1245', '', '0', '1245', '0.1245'], ['1', '', '1', '0', '1'], ['01', '', '1', '0', '1'], ['01.0', '', '1', '0', '1'], ['01.01', '', '1', '01', '1.01'], ['10.2345', '', '10', '2345', '10.2345'], '123917549171231.12451028401824' => ['123917549171231.12451028401824', '', '123917549171231', '12451028401824', '123917549171231.12451028401824'], '+12351.49273592' => ['+12351.49273592', '', '12351', '49273592', '12351.49273592'], '-12351.49273592' => ['-12351.49273592', '-', '12351', '49273592', '-12351.49273592'], '-12351' => ['-12351', '-', '12351', '0', '-12351'], '-0' => ['-0', '', '0', '0', '0'], '-01' => ['-01', '-', '1', '0', '-1'], '-01.0' => ['-01.0', '-', '1', '0', '-1'], '-01.01' => ['-01.01', '-', '1', '01', '-1.01'], '0.1e-1' => ['0.1e-1', '', '0', '01', '0.01'], '0.1e-2' => ['0.1e-2', '', '0', '001', '0.001'], '0.1e-3' => ['0.1e-3', '', '0', '0001', '0.0001'], '0.1e-4' => ['0.1e-4', '', '0', '00001', '0.00001'], '0.1e-5' => ['0.1e-5', '', '0', '000001', '0.000001'], '0.01e-1' => ['0.01e-1', '', '0', '001', '0.001'], '123.01e-1' => ['123.01e-1', '', '12', '301', '12.301'], '12301e-4' => ['12301e-4', '', '1', '2301', '1.2301'], '12301e-5' => ['12301e-5', '', '0', '12301', '0.12301'], '12301e-6' => ['12301e-6', '', '0', '012301', '0.012301'], '12301e-7' => ['12301e-7', '', '0', '0012301', '0.0012301'], '12301e-10' => ['12301e-10', '', '0', '0000012301', '0.0000012301'], '12301e+3' => ['12301e+3', '', '12301000', '0', '12301000'], '0.1e+1' => ['0.1e+1', '', '1', '0', '1'], '0.1e+2' => ['0.1e+2', '', '10', '0', '10'], '0.1e+3' => ['0.1e+3', '', '100', '0', '100'], '0.1e+4' => ['0.1e+4', '', '1000', '0', '1000'], '0.1e+5' => ['0.1e+5', '', '10000', '0', '10000'], '123.01e+1' => ['123.01e+1', '', '1230', '1', '1230.1'], '123.01e+5' => ['123.01e+5', '', '12301000', '0', '12301000'], '1.0E+15' => ['1.0E+15', '', '1000000000000000', '0', '1000000000000000'], '-123.0456E+15' => ['-123.0456E+15', '-', '123045600000000000', '0', '-123045600000000000'], '-123.04560E+15' => ['-123.04560E+15', '-', '123045600000000000', '0', '-123045600000000000'], '.1e+2' => ['.1e+2', '', '10', '0', '10'], '-.1e+2' => ['-.1e+2', '-', '10', '0', '-10'], '+.1e+2' => ['+.1e+2', '', '10', '0', '10'], '.01' => ['.01', '', '0', '01', '0.01']]; - } - public function provideValidExponents() - { - return [ - 'exponent 0' => ['123456', 0, '123456'], - 'exponent 1' => ['123456', 1, '12345.6'], - 'exponent 2' => ['123456', 2, '1234.56'], - 'exponent 3' => ['123456', 3, '123.456'], - 'exponent 4' => ['123456', 4, '12.3456'], - 'exponent 5' => ['123456', 5, '1.23456'], - 'exponent 6' => ['123456', 6, '0.123456'], - 'exponent 7' => ['123456', 7, '0.0123456'], - 'exponent 8' => ['123456', 8, '0.00123456'], - 'exponent 8 with leading' => ['0123456', 8, '0.00123456'], - 'zero' => ['0', 8, '0'], - 'leading zeroes' => ['00000', 8, '0'], - 'plus leading zeroes' => ['+00000', 8, '0'], - 'minus exponent 0' => ['-123456', 0, '-123456'], - 'minus exponent 1' => ['-123456', 1, '-12345.6'], - 'minus exponent 2' => ['-123456', 2, '-1234.56'], - 'minus exponent 3' => ['-123456', 3, '-123.456'], - 'minus exponent 4' => ['-123456', 4, '-12.3456'], - 'minus exponent 5' => ['-123456', 5, '-1.23456'], - 'minus exponent 6' => ['-123456', 6, '-0.123456'], - 'minus exponent 7' => ['-123456', 7, '-0.0123456'], - 'minus exponent 8' => ['-123456', 8, '-0.00123456'], - 'minus exponent 8 with leading' => ['-0123456', 8, '-0.00123456'], - 'minus zero' => ['-0', 8, '0'], - 'minus leading zeroes' => ['-00000', 8, '0'], - // trailing zeroes should be dropped on the decimal part - 'trailing zeroes 1' => ['10000000', 4, '1000'], - 'trailing zeroes 2' => ['10002000', 4, '1000.2'], - ]; - } - public function provideInvalidNumbers() - { - return ['bool false' => [\false], 'bool true' => [\true], 'empty string' => [''], 'NaN' => ['asd'], 'NaN with dot' => ['asd.foo'], 'NaN with comma' => ['asd,foo'], 'array' => [array()], 'null' => [null], '1.' => ['1.']]; - } - public function provideInvalidCoefficients() - { - return ['bool false' => [\false, 0], 'bool true' => [\true, 0], 'empty string' => ['', 0], 'NaN' => ['asd', 0], 'NaN with dot' => ['asd.foo', 0], 'NaN with comma' => ['asd,foo', 0], 'array' => [array(), 0], 'null' => [null, 0], 'negative coefficient' => ['123', -5]]; - } - public function provideNumbersWithNonSignificantCharacters() - { - return [['01', '1'], ['010', '10'], ['000010', '10'], ['10.1', '10.1'], ['10.10', '10.1'], ['10.11230000', '10.1123'], ['0000010.11230000', '10.1123'], ['+0000010.11230000', '10.1123'], ['-01', '-1'], ['-010', '-10'], ['-000010', '-10'], ['-10.1', '-10.1'], ['-10.10', '-10.1'], ['-10.11230000', '-10.1123'], ['-0000010.11230000', '-10.1123']]; - } - public function provideExtendedPrecisionTestCases() - { - return [['1.23456789', 8, '1.23456789'], ['1.23456789', 9, '1.234567890'], ['1.23456789', 10, '1.2345678900']]; - } - public function provideRoundingTestCases() - { - return [ - 'truncate 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1'], - 'truncate 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2'], - 'truncate 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23'], - 'truncate 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.234'], - 'truncate 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2345'], - 'truncate 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456'], - 'truncate 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.234567'], - 'truncate 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2345678'], - 'truncate 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456789'], - // does not add trailing zeroes - 'truncate 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456789'], - 'truncate 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456789'], - 'truncate zeroes 1' => ['1.00000001', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1'], - 'truncate zeroes 2' => ['1.00000001', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.00000001'], - 'ceil 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '2'], - 'ceil 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.3'], - 'ceil 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.24'], - 'ceil 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.235'], - 'ceil 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.2346'], - 'ceil 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23457'], - 'ceil 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.234568'], - 'ceil 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.2345679'], - 'ceil 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23456789'], - // does not add trailing zeroes - 'ceil 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23456789'], - 'ceil 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23456789'], - 'round half up 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1'], - 'round half up 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2'], - 'round half up 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23'], - 'round half up 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.235'], - 'round half up 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2346'], - 'round half up 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23457'], - 'round half up 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.234568'], - 'round half up 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2345679'], - 'round half up 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23456789'], - // does not add trailing zeroes - 'round half up 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23456789'], - 'round half up 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23456789'], - ]; - } - public function providePrecisionTestCases() - { - return [ - 'truncate 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1'], - 'truncate 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2'], - 'truncate 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23'], - 'truncate 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.234'], - 'truncate 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2345'], - 'truncate 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456'], - 'truncate 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.234567'], - 'truncate 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2345678'], - 'truncate 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456789'], - // adds trailing zeroes - 'truncate 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.234567890'], - 'truncate 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2345678900'], - // keeps trailing zeroes - 'truncate zeroes 1' => ['1.00000001', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.000'], - 'truncate zeroes 2' => ['1.00000001', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.00000001'], - 'ceil 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '2'], - 'ceil 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.3'], - 'ceil 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.24'], - 'ceil 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.235'], - 'ceil 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.2346'], - 'ceil 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23457'], - 'ceil 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.234568'], - 'ceil 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.2345679'], - 'ceil 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23456789'], - 'ceil zeroes' => ['1.00000001', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.0000001'], - // adds trailing zeroes - 'ceil 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.234567890'], - 'ceil 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.2345678900'], - 'round half up 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1'], - 'round half up 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2'], - 'round half up 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23'], - 'round half up 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.235'], - 'round half up 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2346'], - 'round half up 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23457'], - 'round half up 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.234568'], - 'round half up 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2345679'], - 'round half up 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23456789'], - // adds trailing zeroes - 'round half up 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.234567890'], - 'round half up 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2345678900'], - ]; - } - public function provideEqualityTestCases() - { - return [[new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0', 5), \true], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0.1234'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1234', 4), \true], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1234.01'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('123401', 2), \true], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-0'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0'), \true], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-1234.01'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-123401', 2), \true], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-1234.01'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('123401', 2), \false], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1234.01'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-123401', 2), \false], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1234.01'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-1234.01'), \false]]; - } - public function provideComparisonTestCases() - { - return [ - // a is greater - 'greater 1' => ['1', '0', 1], - 'greater 2' => ['1.0', '0', 1], - 'greater 3' => ['1.01', '1.0', 1], - 'greater 4' => ['1.0000000000000000000000001', '1.0', 1], - 'greater 5' => ['10', '001', 1], - 'greater 6' => ['10', '-10', 1], - 'greater 7' => ['10', '-100', 1], - 'greater 8' => ['100', '10', 1], - 'greater 9' => ['-1', '-2', 1], - 'greater 10' => ['-1', '-0000002', 1], - 'greater 11' => ['-1', '-1.0000000001', 1], - // a is equal - 'equal 1' => ['1', '01', 0], - 'equal 2' => ['0.1', '0000.1000000000000', 0], - // a is lower - 'lower 1' => ['0', '1', -1], - 'lower 2' => ['-1', '0', -1], - 'lower 3' => ['-1', '0.0001', -1], - 'lower 4' => ['-2', '-1', -1], - 'lower 5' => ['-02', '-1', -1], - 'lower 6' => ['-2', '-01', -1], - 'lower 8' => ['10', '100', -1], - 'lower 9' => ['-1.000001', '-1', -1], - 'lower 10' => ['-1000.000001', '-10.0001', -1], - ]; - } - public function provideToNegativeTransformationCases() - { - return [['1.2345', '-1.2345'], ['-1.2345', '-1.2345'], ['0', '0'], ['-0', '0']]; - } - public function provideToPositiveTransformationCases() - { - return [['-1.2345', '1.2345'], ['1.2345', '1.2345'], ['0', '0'], ['-0', '0']]; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\tests\Unit\Core\Decimal; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding; +class NumberTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase +{ + /** + * Given a valid number in a string + * When constructing a Number with it + * Then it should interpret the sign, decimal and fractional parts correctly + * + * @param string $number + * @param string $expectedSign + * @param string $expectedInteger + * @param string $expectedFraction + * @param string $expectedStr + * + * @dataProvider provideValidNumbers + */ + public function testItInterpretsNumbers($number, $expectedSign, $expectedInteger, $expectedFraction, $expectedStr) + { + $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $this->assertSame($expectedSign, $decimalNumber->getSign(), 'The sign is not as expected'); + $this->assertSame($expectedInteger, $decimalNumber->getIntegerPart(), 'The integer part is not as expected'); + $this->assertSame($expectedFraction, $decimalNumber->getFractionalPart(), 'The fraction part is not as expected'); + $this->assertSame($expectedStr, (string) $decimalNumber, 'The string representation is not as expected'); + } + /** + * Given a valid coefficient and exponent + * When constructing a Number with them + * Then it should convert them to the expected string + * + * @param string $coefficient + * @param int $exponent + * @param string $expectedStr + * + * @dataProvider provideValidExponents + */ + public function testItInterpretsExponents($coefficient, $exponent, $expectedStr) + { + $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($coefficient, $exponent); + $this->assertSame($expectedStr, (string) $decimalNumber); + } + /** + * Given an invalid number + * When constructing a Number with it + * Then an InvalidArgumentException should be thrown + * + * @param mixed $number + * + * @dataProvider provideInvalidNumbers + * @expectedException \InvalidArgumentException + */ + public function testItThrowsExceptionWhenGivenInvalidNumber($number) + { + new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + } + /** + * Given an invalid coefficient or exponent + * When constructing a Number with them + * Then an InvalidArgumentException should be thrown + * + * @param mixed $coefficient + * @param mixed $exponent + * + * @dataProvider provideInvalidCoefficients + * @expectedException \InvalidArgumentException + */ + public function testItThrowsExceptionWhenGivenInvalidCoefficientOrExponent($coefficient, $exponent) + { + new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($coefficient, $exponent); + } + /** + * Given a Number constructed with a valid number + * When casting the number to string + * The resulting string should not include leading nor trailing zeroes + * + * @param string $number + * @param string $expected + * + * @dataProvider provideNumbersWithNonSignificantCharacters + */ + public function testItDropsNonSignificantDigits($number, $expected) + { + $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $this->assertSame($expected, (string) $decimalNumber); + } + /** + * Given a Number constructed with a valid number + * When rounding it to a specific precision, using a specific rounding mode + * The returned string should match the expectation + * + * @param string $number + * @param int $precision Number of decimal characters + * @param string $mode Rounding mode + * @param string $expected Expected result + * + * @dataProvider providePrecisionTestCases + */ + public function testPrecision($number, $precision, $mode, $expected) + { + $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $this->assertSame($expected, (string) $decimalNumber->toPrecision($precision, $mode)); + } + /** + * Given a Number constructed with a valid number + * When rounding it to a specific precision, using a specific rounding mode + * The returned string should match the expectation + * + * @param string $number + * @param int $precision Number of decimal characters + * @param string $mode Rounding mode + * @param string $expected Expected result + * + * @dataProvider provideRoundingTestCases + */ + public function testRounding($number, $precision, $mode, $expected) + { + $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $this->assertSame($expected, (string) $decimalNumber->round($precision, $mode), "Failed to assert that round {$number} to {$precision} decimals = {$expected}"); + } + /** + * Given a Number constructed with a valid number + * When rounding it to a greater precision than its current one + * The returned string should have been padded with the proper number of trailing zeroes + * + * @param string $number + * @param int $precision Target precision + * @param string $expected Expected result + * + * @dataProvider provideExtendedPrecisionTestCases + */ + public function testItExtendsPrecisionAsNeeded($number, $precision, $expected) + { + $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $this->assertSame($expected, (string) $decimalNumber->toPrecision($precision), "Failed to assert that fixing {$number} to {$precision} decimals = {$expected}"); + } + /** + * Given two instances of Number + * When comparing the first one with the second one + * Then the result should be true if the instances are equal, and false otherwise + * + * @param Number $number1 + * @param Number $number2 + * @param string $expected + * + * @dataProvider provideEqualityTestCases + */ + public function testItIsAbleToTellIfEqual($number1, $number2, $expected) + { + $this->assertSame($expected, $number1->equals($number2), \sprintf('Failed to assert equality between "%s" and "%s"', $number1, $number2)); + } + /** + * Given two numbers + * When asked if one number is greater than the other + * Then result should be true if the A > B, and false otherwise + * + * @param string $number1 + * @param string $number2 + * @param int $expected + * + * @dataProvider provideComparisonTestCases + */ + public function testIsAbleToTellIfGreaterThan($number1, $number2, $expected) + { + $shouldBeGreater = 1 === $expected; + $number1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); + $number2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); + $this->assertSame($number1->isGreaterThan($number2), $shouldBeGreater); + } + /** + * Given two numbers + * When asked if one number is lower than the other + * Then result should be true if the A < B, and false otherwise + * + * @param string $number1 + * @param string $number2 + * @param int $expected + * + * @dataProvider provideComparisonTestCases + */ + public function testIsAbleToTellIfLowerThan($number1, $number2, $expected) + { + $shouldBeLower = -1 === $expected; + $number1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); + $number2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); + $this->assertSame($number1->isLowerThan($number2), $shouldBeLower); + } + /** + * Given a positive number + * When it's transformed to negative + * Then we should get the negative equivalent of the base number + * + * @param string $number + * @param string $expected + * + * @dataProvider provideToNegativeTransformationCases + */ + public function testItTransformsPositiveToNegative($number, $expected) + { + $number = (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number))->toNegative(); + $this->assertSame((string) $number, $expected); + } + /** + * Given a negative number + * When it's transformed to positive + * Then we should get the positive equivalent of the base number + * + * @param string $number + * @param string $expected + * + * @dataProvider provideToPositiveTransformationCases + */ + public function testItTransformsNegativeToPositive($number, $expected) + { + $number = (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number))->toPositive(); + $this->assertSame((string) $number, $expected); + } + public function provideValidNumbers() + { + return [['number' => '0.0', 'expectedSign' => '', 'expectedInteger' => '0', 'expectedFraction' => '0', 'expectedStr' => '0'], ['00000.0', '', '0', '0', '0'], ['0.00000', '', '0', '0', '0'], ['00000.00000', '', '0', '0', '0'], ['0.1', '', '0', '1', '0.1'], ['1.0', '', '1', '0', '1'], ['1.1', '', '1', '1', '1.1'], ['1.234', '', '1', '234', '1.234'], ['0.1245', '', '0', '1245', '0.1245'], ['1', '', '1', '0', '1'], ['01', '', '1', '0', '1'], ['01.0', '', '1', '0', '1'], ['01.01', '', '1', '01', '1.01'], ['10.2345', '', '10', '2345', '10.2345'], '123917549171231.12451028401824' => ['123917549171231.12451028401824', '', '123917549171231', '12451028401824', '123917549171231.12451028401824'], '+12351.49273592' => ['+12351.49273592', '', '12351', '49273592', '12351.49273592'], '-12351.49273592' => ['-12351.49273592', '-', '12351', '49273592', '-12351.49273592'], '-12351' => ['-12351', '-', '12351', '0', '-12351'], '-0' => ['-0', '', '0', '0', '0'], '-01' => ['-01', '-', '1', '0', '-1'], '-01.0' => ['-01.0', '-', '1', '0', '-1'], '-01.01' => ['-01.01', '-', '1', '01', '-1.01'], '0.1e-1' => ['0.1e-1', '', '0', '01', '0.01'], '0.1e-2' => ['0.1e-2', '', '0', '001', '0.001'], '0.1e-3' => ['0.1e-3', '', '0', '0001', '0.0001'], '0.1e-4' => ['0.1e-4', '', '0', '00001', '0.00001'], '0.1e-5' => ['0.1e-5', '', '0', '000001', '0.000001'], '0.01e-1' => ['0.01e-1', '', '0', '001', '0.001'], '123.01e-1' => ['123.01e-1', '', '12', '301', '12.301'], '12301e-4' => ['12301e-4', '', '1', '2301', '1.2301'], '12301e-5' => ['12301e-5', '', '0', '12301', '0.12301'], '12301e-6' => ['12301e-6', '', '0', '012301', '0.012301'], '12301e-7' => ['12301e-7', '', '0', '0012301', '0.0012301'], '12301e-10' => ['12301e-10', '', '0', '0000012301', '0.0000012301'], '12301e+3' => ['12301e+3', '', '12301000', '0', '12301000'], '0.1e+1' => ['0.1e+1', '', '1', '0', '1'], '0.1e+2' => ['0.1e+2', '', '10', '0', '10'], '0.1e+3' => ['0.1e+3', '', '100', '0', '100'], '0.1e+4' => ['0.1e+4', '', '1000', '0', '1000'], '0.1e+5' => ['0.1e+5', '', '10000', '0', '10000'], '123.01e+1' => ['123.01e+1', '', '1230', '1', '1230.1'], '123.01e+5' => ['123.01e+5', '', '12301000', '0', '12301000'], '1.0E+15' => ['1.0E+15', '', '1000000000000000', '0', '1000000000000000'], '-123.0456E+15' => ['-123.0456E+15', '-', '123045600000000000', '0', '-123045600000000000'], '-123.04560E+15' => ['-123.04560E+15', '-', '123045600000000000', '0', '-123045600000000000'], '.1e+2' => ['.1e+2', '', '10', '0', '10'], '-.1e+2' => ['-.1e+2', '-', '10', '0', '-10'], '+.1e+2' => ['+.1e+2', '', '10', '0', '10'], '.01' => ['.01', '', '0', '01', '0.01']]; + } + public function provideValidExponents() + { + return [ + 'exponent 0' => ['123456', 0, '123456'], + 'exponent 1' => ['123456', 1, '12345.6'], + 'exponent 2' => ['123456', 2, '1234.56'], + 'exponent 3' => ['123456', 3, '123.456'], + 'exponent 4' => ['123456', 4, '12.3456'], + 'exponent 5' => ['123456', 5, '1.23456'], + 'exponent 6' => ['123456', 6, '0.123456'], + 'exponent 7' => ['123456', 7, '0.0123456'], + 'exponent 8' => ['123456', 8, '0.00123456'], + 'exponent 8 with leading' => ['0123456', 8, '0.00123456'], + 'zero' => ['0', 8, '0'], + 'leading zeroes' => ['00000', 8, '0'], + 'plus leading zeroes' => ['+00000', 8, '0'], + 'minus exponent 0' => ['-123456', 0, '-123456'], + 'minus exponent 1' => ['-123456', 1, '-12345.6'], + 'minus exponent 2' => ['-123456', 2, '-1234.56'], + 'minus exponent 3' => ['-123456', 3, '-123.456'], + 'minus exponent 4' => ['-123456', 4, '-12.3456'], + 'minus exponent 5' => ['-123456', 5, '-1.23456'], + 'minus exponent 6' => ['-123456', 6, '-0.123456'], + 'minus exponent 7' => ['-123456', 7, '-0.0123456'], + 'minus exponent 8' => ['-123456', 8, '-0.00123456'], + 'minus exponent 8 with leading' => ['-0123456', 8, '-0.00123456'], + 'minus zero' => ['-0', 8, '0'], + 'minus leading zeroes' => ['-00000', 8, '0'], + // trailing zeroes should be dropped on the decimal part + 'trailing zeroes 1' => ['10000000', 4, '1000'], + 'trailing zeroes 2' => ['10002000', 4, '1000.2'], + ]; + } + public function provideInvalidNumbers() + { + return ['bool false' => [\false], 'bool true' => [\true], 'empty string' => [''], 'NaN' => ['asd'], 'NaN with dot' => ['asd.foo'], 'NaN with comma' => ['asd,foo'], 'array' => [array()], 'null' => [null], '1.' => ['1.']]; + } + public function provideInvalidCoefficients() + { + return ['bool false' => [\false, 0], 'bool true' => [\true, 0], 'empty string' => ['', 0], 'NaN' => ['asd', 0], 'NaN with dot' => ['asd.foo', 0], 'NaN with comma' => ['asd,foo', 0], 'array' => [array(), 0], 'null' => [null, 0], 'negative coefficient' => ['123', -5]]; + } + public function provideNumbersWithNonSignificantCharacters() + { + return [['01', '1'], ['010', '10'], ['000010', '10'], ['10.1', '10.1'], ['10.10', '10.1'], ['10.11230000', '10.1123'], ['0000010.11230000', '10.1123'], ['+0000010.11230000', '10.1123'], ['-01', '-1'], ['-010', '-10'], ['-000010', '-10'], ['-10.1', '-10.1'], ['-10.10', '-10.1'], ['-10.11230000', '-10.1123'], ['-0000010.11230000', '-10.1123']]; + } + public function provideExtendedPrecisionTestCases() + { + return [['1.23456789', 8, '1.23456789'], ['1.23456789', 9, '1.234567890'], ['1.23456789', 10, '1.2345678900']]; + } + public function provideRoundingTestCases() + { + return [ + 'truncate 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1'], + 'truncate 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2'], + 'truncate 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23'], + 'truncate 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.234'], + 'truncate 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2345'], + 'truncate 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456'], + 'truncate 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.234567'], + 'truncate 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2345678'], + 'truncate 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456789'], + // does not add trailing zeroes + 'truncate 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456789'], + 'truncate 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456789'], + 'truncate zeroes 1' => ['1.00000001', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1'], + 'truncate zeroes 2' => ['1.00000001', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.00000001'], + 'ceil 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '2'], + 'ceil 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.3'], + 'ceil 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.24'], + 'ceil 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.235'], + 'ceil 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.2346'], + 'ceil 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23457'], + 'ceil 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.234568'], + 'ceil 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.2345679'], + 'ceil 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23456789'], + // does not add trailing zeroes + 'ceil 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23456789'], + 'ceil 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23456789'], + 'round half up 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1'], + 'round half up 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2'], + 'round half up 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23'], + 'round half up 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.235'], + 'round half up 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2346'], + 'round half up 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23457'], + 'round half up 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.234568'], + 'round half up 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2345679'], + 'round half up 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23456789'], + // does not add trailing zeroes + 'round half up 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23456789'], + 'round half up 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23456789'], + ]; + } + public function providePrecisionTestCases() + { + return [ + 'truncate 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1'], + 'truncate 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2'], + 'truncate 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23'], + 'truncate 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.234'], + 'truncate 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2345'], + 'truncate 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456'], + 'truncate 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.234567'], + 'truncate 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2345678'], + 'truncate 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.23456789'], + // adds trailing zeroes + 'truncate 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.234567890'], + 'truncate 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.2345678900'], + // keeps trailing zeroes + 'truncate zeroes 1' => ['1.00000001', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.000'], + 'truncate zeroes 2' => ['1.00000001', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, '1.00000001'], + 'ceil 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '2'], + 'ceil 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.3'], + 'ceil 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.24'], + 'ceil 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.235'], + 'ceil 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.2346'], + 'ceil 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23457'], + 'ceil 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.234568'], + 'ceil 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.2345679'], + 'ceil 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.23456789'], + 'ceil zeroes' => ['1.00000001', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.0000001'], + // adds trailing zeroes + 'ceil 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.234567890'], + 'ceil 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, '1.2345678900'], + 'round half up 0' => ['1.23456789', 0, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1'], + 'round half up 1' => ['1.23456789', 1, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2'], + 'round half up 2' => ['1.23456789', 2, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23'], + 'round half up 3' => ['1.23456789', 3, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.235'], + 'round half up 4' => ['1.23456789', 4, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2346'], + 'round half up 5' => ['1.23456789', 5, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23457'], + 'round half up 6' => ['1.23456789', 6, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.234568'], + 'round half up 7' => ['1.23456789', 7, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2345679'], + 'round half up 8' => ['1.23456789', 8, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.23456789'], + // adds trailing zeroes + 'round half up 9' => ['1.23456789', 9, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.234567890'], + 'round half up 10' => ['1.23456789', 10, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, '1.2345678900'], + ]; + } + public function provideEqualityTestCases() + { + return [[new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0', 5), \true], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0.1234'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1234', 4), \true], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1234.01'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('123401', 2), \true], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-0'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0'), \true], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-1234.01'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-123401', 2), \true], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-1234.01'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('123401', 2), \false], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1234.01'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-123401', 2), \false], [new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1234.01'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('-1234.01'), \false]]; + } + public function provideComparisonTestCases() + { + return [ + // a is greater + 'greater 1' => ['1', '0', 1], + 'greater 2' => ['1.0', '0', 1], + 'greater 3' => ['1.01', '1.0', 1], + 'greater 4' => ['1.0000000000000000000000001', '1.0', 1], + 'greater 5' => ['10', '001', 1], + 'greater 6' => ['10', '-10', 1], + 'greater 7' => ['10', '-100', 1], + 'greater 8' => ['100', '10', 1], + 'greater 9' => ['-1', '-2', 1], + 'greater 10' => ['-1', '-0000002', 1], + 'greater 11' => ['-1', '-1.0000000001', 1], + // a is equal + 'equal 1' => ['1', '01', 0], + 'equal 2' => ['0.1', '0000.1000000000000', 0], + // a is lower + 'lower 1' => ['0', '1', -1], + 'lower 2' => ['-1', '0', -1], + 'lower 3' => ['-1', '0.0001', -1], + 'lower 4' => ['-2', '-1', -1], + 'lower 5' => ['-02', '-1', -1], + 'lower 6' => ['-2', '-01', -1], + 'lower 8' => ['10', '100', -1], + 'lower 9' => ['-1.000001', '-1', -1], + 'lower 10' => ['-1000.000001', '-10.0001', -1], + ]; + } + public function provideToNegativeTransformationCases() + { + return [['1.2345', '-1.2345'], ['-1.2345', '-1.2345'], ['0', '0'], ['-0', '0']]; + } + public function provideToPositiveTransformationCases() + { + return [['-1.2345', '1.2345'], ['1.2345', '1.2345'], ['0', '0'], ['-0', '0']]; + } +} diff --git a/vendor/prestashop/decimal/tests/Operation/AdditionTest.php b/vendor/prestashop/decimal/tests/Operation/AdditionTest.php index 13b9bc02a..61788efb1 100644 --- a/vendor/prestashop/decimal/tests/Operation/AdditionTest.php +++ b/vendor/prestashop/decimal/tests/Operation/AdditionTest.php @@ -1,70 +1,70 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Addition; -class AdditionTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase -{ - /** - * Given two decimal numbers - * When computing the addition operation - * Then we should get the result of adding those numbers - * - * @param string $number1 - * @param string $number2 - * @param string $expectedResult - * - * @dataProvider provideNumbersToAdd - */ - public function testItAddsNumbers($number1, $number2, $expectedResult) - { - $n1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); - $n2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); - $operation = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Addition(); - $result1 = $operation->computeUsingBcMath($n1, $n2); - $result2 = $operation->computeWithoutBcMath($n1, $n2); - $this->assertSame($expectedResult, (string) $result1, "Failed asserting {$number1} + {$number2} = {$expectedResult} (BC Math)"); - $this->assertSame($expectedResult, (string) $result2, "Failed asserting {$number1} + {$number2} = {$expectedResult}"); - } - public function provideNumbersToAdd() - { - return [ - ['0', '0', '0'], - ['0', '5', '5'], - ['0', '5.1', '5.1'], - ['5', '0', '5'], - ['5.1', '0', '5.1'], - ['1.234', '5', '6.234'], - ['5', '1.234', '6.234'], - ['10', '0.0000000', '10'], - ['0.0000000', '10', '10'], - ['10.01', '0.0000000', '10.01'], - ['0.0000000', '10.01', '10.01'], - ['0.0000001', '10.01', '10.0100001'], - ['9.999999', '9.999999', '19.999998'], - ['9.999999999999999999', '9.999999999999999999', '19.999999999999999998'], - ['9223372036854775807.9223372036854775807', '1.01', '9223372036854775808.9323372036854775807'], - // test adding numbers to negative numbers - ['-2', '1', '-1'], - ['-2', '2', '0'], - ['-2', '3', '1'], - ['-2', '0.001', '-1.999'], - // test it delegates to subtraction - ['2', '-1', '1'], - ['2', '-2', '0'], - ['2', '-3', '-1'], - ['1', '-0.001', '0.999'], - ['0', '-0.001', '-0.001'], - ['0', '-1.001', '-1.001'], - ['-1', '-2', '-3'], - ['100.12345567433134123236345', '-1.1', '99.02345567433134123236345'], - ]; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Addition; +class AdditionTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase +{ + /** + * Given two decimal numbers + * When computing the addition operation + * Then we should get the result of adding those numbers + * + * @param string $number1 + * @param string $number2 + * @param string $expectedResult + * + * @dataProvider provideNumbersToAdd + */ + public function testItAddsNumbers($number1, $number2, $expectedResult) + { + $n1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); + $n2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); + $operation = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Addition(); + $result1 = $operation->computeUsingBcMath($n1, $n2); + $result2 = $operation->computeWithoutBcMath($n1, $n2); + $this->assertSame($expectedResult, (string) $result1, "Failed asserting {$number1} + {$number2} = {$expectedResult} (BC Math)"); + $this->assertSame($expectedResult, (string) $result2, "Failed asserting {$number1} + {$number2} = {$expectedResult}"); + } + public function provideNumbersToAdd() + { + return [ + ['0', '0', '0'], + ['0', '5', '5'], + ['0', '5.1', '5.1'], + ['5', '0', '5'], + ['5.1', '0', '5.1'], + ['1.234', '5', '6.234'], + ['5', '1.234', '6.234'], + ['10', '0.0000000', '10'], + ['0.0000000', '10', '10'], + ['10.01', '0.0000000', '10.01'], + ['0.0000000', '10.01', '10.01'], + ['0.0000001', '10.01', '10.0100001'], + ['9.999999', '9.999999', '19.999998'], + ['9.999999999999999999', '9.999999999999999999', '19.999999999999999998'], + ['9223372036854775807.9223372036854775807', '1.01', '9223372036854775808.9323372036854775807'], + // test adding numbers to negative numbers + ['-2', '1', '-1'], + ['-2', '2', '0'], + ['-2', '3', '1'], + ['-2', '0.001', '-1.999'], + // test it delegates to subtraction + ['2', '-1', '1'], + ['2', '-2', '0'], + ['2', '-3', '-1'], + ['1', '-0.001', '0.999'], + ['0', '-0.001', '-0.001'], + ['0', '-1.001', '-1.001'], + ['-1', '-2', '-3'], + ['100.12345567433134123236345', '-1.1', '99.02345567433134123236345'], + ]; + } +} diff --git a/vendor/prestashop/decimal/tests/Operation/ComparisonTest.php b/vendor/prestashop/decimal/tests/Operation/ComparisonTest.php index 31dd3eac0..5a4b4225f 100644 --- a/vendor/prestashop/decimal/tests/Operation/ComparisonTest.php +++ b/vendor/prestashop/decimal/tests/Operation/ComparisonTest.php @@ -1,185 +1,185 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; - -use _PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison; -class ComparisonTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase -{ - /** - * @var Number - */ - private static $zero; - public static function setUpBeforeClass() - { - static::$zero = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0'); - } - /** - * Given two numbers - * When comparing them - * Then we should get - * - 1 if a > b - * - -1 if b > a - * - 0 if a == b - * - * @param string $a - * @param string $b - * @param int $expected - * - * @dataProvider provideCompareTestCases - */ - public function testItComparesNumbers($a, $b, $expected) - { - $comparison = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison(); - $result1 = $comparison->compareUsingBcMath(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($a), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($b)); - $result2 = $comparison->compareWithoutBcMath(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($a), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($b)); - $this->assertSame($expected, $result1, "Failed assertion (BC Math)"); - $this->assertSame($expected, $result2, "Failed assertion"); - } - public function provideCompareTestCases() - { - return [ - // a is greater - 'greater 1' => ['1', '0', 1], - 'greater 2' => ['1.0', '0', 1], - 'greater 3' => ['1.01', '1.0', 1], - 'greater 4' => ['1.0000000000000000000000001', '1.0', 1], - 'greater 5' => ['10', '001', 1], - 'greater 6' => ['10', '-10', 1], - 'greater 7' => ['10', '-100', 1], - 'greater 8' => ['100', '10', 1], - 'greater 9' => ['-1', '-2', 1], - 'greater 10' => ['-1', '-0000002', 1], - 'greater 11' => ['-1', '-1.0000000001', 1], - // a is equal - 'equal 1' => ['1', '01', 0], - 'equal 2' => ['0.1', '0000.1000000000000', 0], - // a is lower - 'lower 1' => ['0', '1', -1], - 'lower 2' => ['-1', '0', -1], - 'lower 3' => ['-1', '0.0001', -1], - 'lower 4' => ['-2', '-1', -1], - 'lower 5' => ['-02', '-1', -1], - 'lower 6' => ['-2', '-01', -1], - 'lower 8' => ['10', '100', -1], - 'lower 9' => ['-1.000001', '-1', -1], - 'lower 10' => ['-1000.000001', '-10.0001', -1], - ]; - } - /** - * Given a number - * It should detect if it equals zero - * - * @param string $number - * @param bool $expected - * - * @dataProvider provideEqualsZeroTests - */ - public function testItDetectsEqualsZero($number, $expected) - { - $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $this->assertSame($expected, $n->equalsZero(), \sprintf("Failed to assert that %s %s equal to zero", $number, $this->getIsVerb($expected))); - // double check - $this->assertSame($expected, $n->equals(static::$zero), \sprintf("Failed to assert that %s %s equal to Number zero", $number, $this->getIsVerb($expected))); - } - public function provideEqualsZeroTests() - { - return [['0', \true], ['000000', \true], ['0.0000', \true], ['-0.0000', \true], ['0.0001', \false], ['-0.0001', \false], ['10', \false], ['10.0', \false], ['10.000001', \false], ['10.100001', \false], ['-10', \false], ['-10.0', \false], ['-10.000001', \false], ['-10.100001', \false]]; - } - /** - * Given a number - * It should detect if it's greater than zero - * - * @param string $number - * @param bool $expected - * - * @dataProvider provideGreaterThanZeroTests - */ - public function testItDetectsGreaterThanZero($number, $expected) - { - $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $this->assertSame($expected, $n->isGreaterThanZero(), \sprintf("Failed to assert that %s %s greater than zero", $number, $this->getIsVerb($expected))); - // double check - $this->assertSame($expected, $n->isGreaterThan(static::$zero), \sprintf("Failed to assert that %s %s grater to Number zero", $number, $this->getIsVerb($expected))); - } - public function provideGreaterThanZeroTests() - { - return [['0', \false], ['000000', \false], ['0.0000', \false], ['-0.0000', \false], ['0.0001', \true], ['-0.0001', \false], ['10', \true], ['10.0', \true], ['10.000001', \true], ['10.100001', \true], ['-10', \false], ['-10.0', \false], ['-10.000001', \false], ['-10.100001', \false]]; - } - /** - * Given a number - * It should detect if it's greater than zero - * - * @param string $number - * @param bool $expected - * - * @dataProvider provideGreaterOrEqualThanZeroTests - */ - public function testItDetectsGreaterOrEqualThanZero($number, $expected) - { - $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $this->assertSame($expected, $n->isGreaterOrEqualThanZero(), \sprintf("Failed to assert that %s %s greater or equal than zero", $number, $this->getIsVerb($expected))); - // double check - $this->assertSame($expected, $n->isGreaterOrEqualThan(static::$zero), \sprintf("Failed to assert that %s %s greater or equal to Number zero", $number, $this->getIsVerb($expected))); - } - public function provideGreaterOrEqualThanZeroTests() - { - return [['0', \true], ['000000', \true], ['0.0000', \true], ['-0.0000', \true], ['0.0001', \true], ['-0.0001', \false], ['10', \true], ['10.0', \true], ['10.000001', \true], ['10.100001', \true], ['-10', \false], ['-10.0', \false], ['-10.000001', \false], ['-10.100001', \false]]; - } - /** - * Given a number - * It should detect if it's lower than zero - * - * @param string $number - * @param bool $expected - * - * @dataProvider provideLowerThanZeroTests - */ - public function testItDetectsLowerThanZero($number, $expected) - { - $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $this->assertSame($expected, $n->isLowerThanZero(), \sprintf("Failed to assert that %s %s lower than zero", $number, $this->getIsVerb($expected))); - // double check - $this->assertSame($expected, $n->isLowerThan(static::$zero), \sprintf("Failed to assert that %s %s lower to Number zero", $number, $this->getIsVerb($expected))); - } - public function provideLowerThanZeroTests() - { - return [['0', \false], ['000000', \false], ['0.0000', \false], ['-0.0000', \false], ['0.0001', \false], ['-0.0001', \true], ['10', \false], ['10.0', \false], ['10.000001', \false], ['10.100001', \false], ['-10', \true], ['-10.0', \true], ['-10.000001', \true], ['-10.100001', \true]]; - } - /** - * Given a number - * It should detect if it's lower than zero - * - * @param string $number - * @param bool $expected - * - * @dataProvider provideLowerOrEqualThanZeroTests - */ - public function testItDetectsLowerOrEqualThanZero($number, $expected) - { - $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $this->assertSame($expected, $n->isLowerOrEqualThanZero(), \sprintf("Failed to assert that %s %s lower or equal than zero", $number, $this->getIsVerb($expected))); - // double check - $this->assertSame($expected, $n->isLowerOrEqualThan(static::$zero), \sprintf("Failed to assert that %s %s lower or equal to Number zero", $number, $this->getIsVerb($expected))); - } - public function provideLowerOrEqualThanZeroTests() - { - return [['0', \true], ['000000', \true], ['0.0000', \true], ['-0.0000', \true], ['0.0001', \false], ['-0.0001', \true], ['10', \false], ['10.0', \false], ['10.000001', \false], ['10.100001', \false], ['-10', \true], ['-10.0', \true], ['-10.000001', \true], ['-10.100001', \true]]; - } - /** - * @param bool $assertion - * - * @return string - */ - private function getIsVerb($assertion) - { - return $assertion ? 'is' : 'is NOT'; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; + +use _PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison; +class ComparisonTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase +{ + /** + * @var Number + */ + private static $zero; + public static function setUpBeforeClass() + { + static::$zero = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0'); + } + /** + * Given two numbers + * When comparing them + * Then we should get + * - 1 if a > b + * - -1 if b > a + * - 0 if a == b + * + * @param string $a + * @param string $b + * @param int $expected + * + * @dataProvider provideCompareTestCases + */ + public function testItComparesNumbers($a, $b, $expected) + { + $comparison = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Comparison(); + $result1 = $comparison->compareUsingBcMath(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($a), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($b)); + $result2 = $comparison->compareWithoutBcMath(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($a), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($b)); + $this->assertSame($expected, $result1, "Failed assertion (BC Math)"); + $this->assertSame($expected, $result2, "Failed assertion"); + } + public function provideCompareTestCases() + { + return [ + // a is greater + 'greater 1' => ['1', '0', 1], + 'greater 2' => ['1.0', '0', 1], + 'greater 3' => ['1.01', '1.0', 1], + 'greater 4' => ['1.0000000000000000000000001', '1.0', 1], + 'greater 5' => ['10', '001', 1], + 'greater 6' => ['10', '-10', 1], + 'greater 7' => ['10', '-100', 1], + 'greater 8' => ['100', '10', 1], + 'greater 9' => ['-1', '-2', 1], + 'greater 10' => ['-1', '-0000002', 1], + 'greater 11' => ['-1', '-1.0000000001', 1], + // a is equal + 'equal 1' => ['1', '01', 0], + 'equal 2' => ['0.1', '0000.1000000000000', 0], + // a is lower + 'lower 1' => ['0', '1', -1], + 'lower 2' => ['-1', '0', -1], + 'lower 3' => ['-1', '0.0001', -1], + 'lower 4' => ['-2', '-1', -1], + 'lower 5' => ['-02', '-1', -1], + 'lower 6' => ['-2', '-01', -1], + 'lower 8' => ['10', '100', -1], + 'lower 9' => ['-1.000001', '-1', -1], + 'lower 10' => ['-1000.000001', '-10.0001', -1], + ]; + } + /** + * Given a number + * It should detect if it equals zero + * + * @param string $number + * @param bool $expected + * + * @dataProvider provideEqualsZeroTests + */ + public function testItDetectsEqualsZero($number, $expected) + { + $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $this->assertSame($expected, $n->equalsZero(), \sprintf("Failed to assert that %s %s equal to zero", $number, $this->getIsVerb($expected))); + // double check + $this->assertSame($expected, $n->equals(static::$zero), \sprintf("Failed to assert that %s %s equal to Number zero", $number, $this->getIsVerb($expected))); + } + public function provideEqualsZeroTests() + { + return [['0', \true], ['000000', \true], ['0.0000', \true], ['-0.0000', \true], ['0.0001', \false], ['-0.0001', \false], ['10', \false], ['10.0', \false], ['10.000001', \false], ['10.100001', \false], ['-10', \false], ['-10.0', \false], ['-10.000001', \false], ['-10.100001', \false]]; + } + /** + * Given a number + * It should detect if it's greater than zero + * + * @param string $number + * @param bool $expected + * + * @dataProvider provideGreaterThanZeroTests + */ + public function testItDetectsGreaterThanZero($number, $expected) + { + $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $this->assertSame($expected, $n->isGreaterThanZero(), \sprintf("Failed to assert that %s %s greater than zero", $number, $this->getIsVerb($expected))); + // double check + $this->assertSame($expected, $n->isGreaterThan(static::$zero), \sprintf("Failed to assert that %s %s grater to Number zero", $number, $this->getIsVerb($expected))); + } + public function provideGreaterThanZeroTests() + { + return [['0', \false], ['000000', \false], ['0.0000', \false], ['-0.0000', \false], ['0.0001', \true], ['-0.0001', \false], ['10', \true], ['10.0', \true], ['10.000001', \true], ['10.100001', \true], ['-10', \false], ['-10.0', \false], ['-10.000001', \false], ['-10.100001', \false]]; + } + /** + * Given a number + * It should detect if it's greater than zero + * + * @param string $number + * @param bool $expected + * + * @dataProvider provideGreaterOrEqualThanZeroTests + */ + public function testItDetectsGreaterOrEqualThanZero($number, $expected) + { + $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $this->assertSame($expected, $n->isGreaterOrEqualThanZero(), \sprintf("Failed to assert that %s %s greater or equal than zero", $number, $this->getIsVerb($expected))); + // double check + $this->assertSame($expected, $n->isGreaterOrEqualThan(static::$zero), \sprintf("Failed to assert that %s %s greater or equal to Number zero", $number, $this->getIsVerb($expected))); + } + public function provideGreaterOrEqualThanZeroTests() + { + return [['0', \true], ['000000', \true], ['0.0000', \true], ['-0.0000', \true], ['0.0001', \true], ['-0.0001', \false], ['10', \true], ['10.0', \true], ['10.000001', \true], ['10.100001', \true], ['-10', \false], ['-10.0', \false], ['-10.000001', \false], ['-10.100001', \false]]; + } + /** + * Given a number + * It should detect if it's lower than zero + * + * @param string $number + * @param bool $expected + * + * @dataProvider provideLowerThanZeroTests + */ + public function testItDetectsLowerThanZero($number, $expected) + { + $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $this->assertSame($expected, $n->isLowerThanZero(), \sprintf("Failed to assert that %s %s lower than zero", $number, $this->getIsVerb($expected))); + // double check + $this->assertSame($expected, $n->isLowerThan(static::$zero), \sprintf("Failed to assert that %s %s lower to Number zero", $number, $this->getIsVerb($expected))); + } + public function provideLowerThanZeroTests() + { + return [['0', \false], ['000000', \false], ['0.0000', \false], ['-0.0000', \false], ['0.0001', \false], ['-0.0001', \true], ['10', \false], ['10.0', \false], ['10.000001', \false], ['10.100001', \false], ['-10', \true], ['-10.0', \true], ['-10.000001', \true], ['-10.100001', \true]]; + } + /** + * Given a number + * It should detect if it's lower than zero + * + * @param string $number + * @param bool $expected + * + * @dataProvider provideLowerOrEqualThanZeroTests + */ + public function testItDetectsLowerOrEqualThanZero($number, $expected) + { + $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $this->assertSame($expected, $n->isLowerOrEqualThanZero(), \sprintf("Failed to assert that %s %s lower or equal than zero", $number, $this->getIsVerb($expected))); + // double check + $this->assertSame($expected, $n->isLowerOrEqualThan(static::$zero), \sprintf("Failed to assert that %s %s lower or equal to Number zero", $number, $this->getIsVerb($expected))); + } + public function provideLowerOrEqualThanZeroTests() + { + return [['0', \true], ['000000', \true], ['0.0000', \true], ['-0.0000', \true], ['0.0001', \false], ['-0.0001', \true], ['10', \false], ['10.0', \false], ['10.000001', \false], ['10.100001', \false], ['-10', \true], ['-10.0', \true], ['-10.000001', \true], ['-10.100001', \true]]; + } + /** + * @param bool $assertion + * + * @return string + */ + private function getIsVerb($assertion) + { + return $assertion ? 'is' : 'is NOT'; + } +} diff --git a/vendor/prestashop/decimal/tests/Operation/DivisionTest.php b/vendor/prestashop/decimal/tests/Operation/DivisionTest.php index 2fc85e5aa..c33860878 100644 --- a/vendor/prestashop/decimal/tests/Operation/DivisionTest.php +++ b/vendor/prestashop/decimal/tests/Operation/DivisionTest.php @@ -1,105 +1,105 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division; -class DivisionTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase -{ - /** - * Given two decimal numbers - * When computing the division operation between them - * Then we should get the result of dividing number1 by number2 - * - * @param string $number1 - * @param string $number2 - * @param string $expectedResult - * - * @dataProvider provideNumbersToDivide - */ - public function testItDividesNumbers($number1, $number2, $expectedResult) - { - $n1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); - $n2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); - $operation = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division(); - $result1 = $operation->computeUsingBcMath($n1, $n2, 20); - $result2 = $operation->computeWithoutBcMath($n1, $n2, 20); - $this->assertSame($expectedResult, (string) $result1, "Failed asserting {$number1} / {$number2} = {$expectedResult} (BC Math)"); - $this->assertSame($expectedResult, (string) $result2, "Failed asserting {$number1} / {$number2} = {$expectedResult}"); - } - /** - * Given a decimal number which is not zero - * When trying to divide it by zero using BC Math - * Then we should get a DivisionByZeroException - * - * @expectedException PrestaShop\Decimal\Exception\DivisionByZeroException - */ - public function testDivisionByZeroUsingBcMathThrowsException() - { - (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division())->computeUsingBcMath(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0')); - } - /** - * Given a decimal number which is not zero - * When trying to divide it by zero without BC Math - * Then we should get a DivisionByZeroException - * - * @expectedException PrestaShop\Decimal\Exception\DivisionByZeroException - */ - public function testDivisionByZeroWithoutBcMathThrowsException() - { - (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division())->computeWithoutBcMath(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0')); - } - public function provideNumbersToDivide() - { - return [ - // 0 as dividend should always yield 0 - ['0', '1', '0'], - ['0', '1123234.4234234123', '0'], - ['0', '-1', '0'], - ['0', '-1123234.4234234123', '0'], - // 1 as divisor should always yield the dividend - ['1', '1', '1'], - ['13524.2342342347262', '1', '13524.2342342347262'], - // -1 should always yield the inverted dividend - ['1', '-1', '-1'], - ['13524.2342342347262', '-1', '-13524.2342342347262'], - // integer results - ['2', '1', '2'], - ['2', '2', '1'], - ['99', '99', '1'], - ['198', '99', '2'], - ['990', '99', '10'], - ['2', '-1', '-2'], - ['2', '-2', '-1'], - ['99', '-99', '-1'], - ['198', '-99', '-2'], - ['990', '-99', '-10'], - ['-2', '-1', '2'], - ['-2', '-2', '1'], - ['-99', '-99', '1'], - ['-198', '-99', '2'], - ['-990', '-99', '10'], - ['-2', '1', '-2'], - ['-2', '2', '-1'], - ['-99', '99', '-1'], - ['-198', '99', '-2'], - ['-990', '99', '-10'], - // decimal results - ['1', '100', '0.01'], - ['1', '3', '0.33333333333333333333'], - ['1231415', '77', '15992.4025974025974025974'], - // decimal dividend - ['12315.73452342341', '27', '456.13831568234851851851'], - ['0.73452342341', '27', '0.0272045712374074074'], - // decimal divisor - ['27', '12315.73452342341', '0.00219231747393129081'], - ['27', '0.00000012315', '219244823.38611449451887941534'], - ]; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division; +class DivisionTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase +{ + /** + * Given two decimal numbers + * When computing the division operation between them + * Then we should get the result of dividing number1 by number2 + * + * @param string $number1 + * @param string $number2 + * @param string $expectedResult + * + * @dataProvider provideNumbersToDivide + */ + public function testItDividesNumbers($number1, $number2, $expectedResult) + { + $n1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); + $n2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); + $operation = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division(); + $result1 = $operation->computeUsingBcMath($n1, $n2, 20); + $result2 = $operation->computeWithoutBcMath($n1, $n2, 20); + $this->assertSame($expectedResult, (string) $result1, "Failed asserting {$number1} / {$number2} = {$expectedResult} (BC Math)"); + $this->assertSame($expectedResult, (string) $result2, "Failed asserting {$number1} / {$number2} = {$expectedResult}"); + } + /** + * Given a decimal number which is not zero + * When trying to divide it by zero using BC Math + * Then we should get a DivisionByZeroException + * + * @expectedException PrestaShop\Decimal\Exception\DivisionByZeroException + */ + public function testDivisionByZeroUsingBcMathThrowsException() + { + (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division())->computeUsingBcMath(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0')); + } + /** + * Given a decimal number which is not zero + * When trying to divide it by zero without BC Math + * Then we should get a DivisionByZeroException + * + * @expectedException PrestaShop\Decimal\Exception\DivisionByZeroException + */ + public function testDivisionByZeroWithoutBcMathThrowsException() + { + (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Division())->computeWithoutBcMath(new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1'), new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('0')); + } + public function provideNumbersToDivide() + { + return [ + // 0 as dividend should always yield 0 + ['0', '1', '0'], + ['0', '1123234.4234234123', '0'], + ['0', '-1', '0'], + ['0', '-1123234.4234234123', '0'], + // 1 as divisor should always yield the dividend + ['1', '1', '1'], + ['13524.2342342347262', '1', '13524.2342342347262'], + // -1 should always yield the inverted dividend + ['1', '-1', '-1'], + ['13524.2342342347262', '-1', '-13524.2342342347262'], + // integer results + ['2', '1', '2'], + ['2', '2', '1'], + ['99', '99', '1'], + ['198', '99', '2'], + ['990', '99', '10'], + ['2', '-1', '-2'], + ['2', '-2', '-1'], + ['99', '-99', '-1'], + ['198', '-99', '-2'], + ['990', '-99', '-10'], + ['-2', '-1', '2'], + ['-2', '-2', '1'], + ['-99', '-99', '1'], + ['-198', '-99', '2'], + ['-990', '-99', '10'], + ['-2', '1', '-2'], + ['-2', '2', '-1'], + ['-99', '99', '-1'], + ['-198', '99', '-2'], + ['-990', '99', '-10'], + // decimal results + ['1', '100', '0.01'], + ['1', '3', '0.33333333333333333333'], + ['1231415', '77', '15992.4025974025974025974'], + // decimal dividend + ['12315.73452342341', '27', '456.13831568234851851851'], + ['0.73452342341', '27', '0.0272045712374074074'], + // decimal divisor + ['27', '12315.73452342341', '0.00219231747393129081'], + ['27', '0.00000012315', '219244823.38611449451887941534'], + ]; + } +} diff --git a/vendor/prestashop/decimal/tests/Operation/MagnitudeChangeTest.php b/vendor/prestashop/decimal/tests/Operation/MagnitudeChangeTest.php index 1c6b7e165..bbca92067 100644 --- a/vendor/prestashop/decimal/tests/Operation/MagnitudeChangeTest.php +++ b/vendor/prestashop/decimal/tests/Operation/MagnitudeChangeTest.php @@ -1,37 +1,37 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\MagnitudeChange; -class MagnitudeChangeTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase -{ - /** - * Given a decimal number - * When changing its magnitude to a specific exponent - * Then we should get the result of multiplying it by 10^exponent - * (Same as shifting the decimal dot to the left or to the right by "exponent" characters) - * - * @param string $number - * @param int $exponent - * @param string $expected - * - * @dataProvider provideTestCases - */ - public function testItChangesMagnitude($number, $exponent, $expected) - { - $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $result = (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\MagnitudeChange())->compute($n, $exponent); - $this->assertSame($expected, (string) $result); - } - public function provideTestCases() - { - return [['123.45678', 0, '123.45678'], ['123.45678', 1, '1234.5678'], ['123.45678', 2, '12345.678'], ['123.45678', 3, '123456.78'], ['123.45678', 6, '123456780'], ['123.45678', 8, '12345678000'], ['123.45678', -1, '12.345678'], ['123.45678', -2, '1.2345678'], ['123.45678', -3, '0.12345678'], ['123.45678', -6, '0.00012345678'], ['123.45678', -8, '0.0000012345678']]; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\MagnitudeChange; +class MagnitudeChangeTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase +{ + /** + * Given a decimal number + * When changing its magnitude to a specific exponent + * Then we should get the result of multiplying it by 10^exponent + * (Same as shifting the decimal dot to the left or to the right by "exponent" characters) + * + * @param string $number + * @param int $exponent + * @param string $expected + * + * @dataProvider provideTestCases + */ + public function testItChangesMagnitude($number, $exponent, $expected) + { + $n = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $result = (new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\MagnitudeChange())->compute($n, $exponent); + $this->assertSame($expected, (string) $result); + } + public function provideTestCases() + { + return [['123.45678', 0, '123.45678'], ['123.45678', 1, '1234.5678'], ['123.45678', 2, '12345.678'], ['123.45678', 3, '123456.78'], ['123.45678', 6, '123456780'], ['123.45678', 8, '12345678000'], ['123.45678', -1, '12.345678'], ['123.45678', -2, '1.2345678'], ['123.45678', -3, '0.12345678'], ['123.45678', -6, '0.00012345678'], ['123.45678', -8, '0.0000012345678']]; + } +} diff --git a/vendor/prestashop/decimal/tests/Operation/MultiplicationTest.php b/vendor/prestashop/decimal/tests/Operation/MultiplicationTest.php index d910cd6bf..cf00dec40 100644 --- a/vendor/prestashop/decimal/tests/Operation/MultiplicationTest.php +++ b/vendor/prestashop/decimal/tests/Operation/MultiplicationTest.php @@ -1,59 +1,59 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Multiplication; -class MultiplicationTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase -{ - /** - * Given two decimal numbers - * When computing the multiplication operation - * Then we should get the result of multiplying those numbers - * - * @param string $number1 - * @param string $number2 - * @param string $expectedResult - * - * @dataProvider provideNumbersToMultiply - */ - public function testItMultipliesNumbers($number1, $number2, $expectedResult) - { - $n1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); - $n2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); - $operation = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Multiplication(); - $result1 = $operation->computeUsingBcMath($n1, $n2); - $result2 = $operation->computeWithoutBcMath($n1, $n2); - $this->assertSame($expectedResult, (string) $result1, "Failed asserting {$number1} * {$number2} = {$expectedResult} (BC Math)"); - $this->assertSame($expectedResult, (string) $result2, "Failed asserting {$number1} * {$number2} = {$expectedResult}"); - } - public function provideNumbersToMultiply() - { - return [ - // integer - 'integer 1' => ['1', '1', '1'], - 'integer 2' => ['1', '0', '0'], - 'integer 3' => ['99999999990', '1', '99999999990'], - 'integer 4' => ['1', '99999999990', '99999999990'], - 'integer 5' => ['99999999990', '0', '0'], - 'integer 6' => ['99999999990', '2', '199999999980'], - 'integer 7' => ['99999999990', '10', '999999999900'], - 'integer 8' => ['123456789', '123456789', '15241578750190521'], - 'integer 9' => ['123456789', '-1', '-123456789'], - 'integer 10' => ['-123456789', '-1', '123456789'], - 'integer 11' => ['-123456789', '1', '-123456789'], - 'integer 12' => ['123', '11234667', '1381864041'], - // decimals - 'decimal 1' => ['99999999990', '0.1', '9999999999'], - 'decimal 2' => ['99999999990', '0.0001', '9999999.999'], - 'decimal 3' => ['99999999990', '0.0002', '19999999.998'], - 'decimal 4' => ['1234.56789', '1234.56789', '1524157.8750190521'], - ]; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Multiplication; +class MultiplicationTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase +{ + /** + * Given two decimal numbers + * When computing the multiplication operation + * Then we should get the result of multiplying those numbers + * + * @param string $number1 + * @param string $number2 + * @param string $expectedResult + * + * @dataProvider provideNumbersToMultiply + */ + public function testItMultipliesNumbers($number1, $number2, $expectedResult) + { + $n1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); + $n2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); + $operation = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Multiplication(); + $result1 = $operation->computeUsingBcMath($n1, $n2); + $result2 = $operation->computeWithoutBcMath($n1, $n2); + $this->assertSame($expectedResult, (string) $result1, "Failed asserting {$number1} * {$number2} = {$expectedResult} (BC Math)"); + $this->assertSame($expectedResult, (string) $result2, "Failed asserting {$number1} * {$number2} = {$expectedResult}"); + } + public function provideNumbersToMultiply() + { + return [ + // integer + 'integer 1' => ['1', '1', '1'], + 'integer 2' => ['1', '0', '0'], + 'integer 3' => ['99999999990', '1', '99999999990'], + 'integer 4' => ['1', '99999999990', '99999999990'], + 'integer 5' => ['99999999990', '0', '0'], + 'integer 6' => ['99999999990', '2', '199999999980'], + 'integer 7' => ['99999999990', '10', '999999999900'], + 'integer 8' => ['123456789', '123456789', '15241578750190521'], + 'integer 9' => ['123456789', '-1', '-123456789'], + 'integer 10' => ['-123456789', '-1', '123456789'], + 'integer 11' => ['-123456789', '1', '-123456789'], + 'integer 12' => ['123', '11234667', '1381864041'], + // decimals + 'decimal 1' => ['99999999990', '0.1', '9999999999'], + 'decimal 2' => ['99999999990', '0.0001', '9999999.999'], + 'decimal 3' => ['99999999990', '0.0002', '19999999.998'], + 'decimal 4' => ['1234.56789', '1234.56789', '1524157.8750190521'], + ]; + } +} diff --git a/vendor/prestashop/decimal/tests/Operation/RoundingTest.php b/vendor/prestashop/decimal/tests/Operation/RoundingTest.php index db37a3003..ee77073cc 100644 --- a/vendor/prestashop/decimal/tests/Operation/RoundingTest.php +++ b/vendor/prestashop/decimal/tests/Operation/RoundingTest.php @@ -1,383 +1,383 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; -class RoundingTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase -{ - /** - * Given decimal number - * When rounding it using an undefined rounding mode - * An InvalidArgumentException should be thrown - * - * @expectedException \InvalidArgumentException - */ - public function testItThrowsExceptionIfRoundingModeIsInvalid() - { - $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1.2345'); - $rounding = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding(); - $rounding->compute($decimalNumber, 2, 'foobar'); - } - /** - * Given decimal number - * When rounding to an invalid precision - * An InvalidArgumentException should be thrown - * - * @param mixed $precision - * - * @expectedException \InvalidArgumentException - * - * @dataProvider provideInvalidPrecision - */ - public function testItThrowsExceptionIfPrecisionIsInvalid($precision) - { - $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1.2345'); - $rounding = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding(); - $rounding->compute($decimalNumber, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); - } - /** - * Given a decimal number - * When truncating the number to a target precision - * Then the resulting number should have at most number of decimals - * - * @param string $number - * @param int $precision - * @param string $expected - * - * @dataProvider provideTruncateTestCases - */ - public function testItTruncatesNumbers($number, $precision, $expected) - { - $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, $expected); - } - /** - * Given a decimal number - * When rounding using ceiling to a target precision - * Then the number should have at most number of decimals - * And it should be rounded to positive infinity if its original precision was larger than the target one - * - * @param string $number - * @param int $precision - * @param string $expected - * - * @dataProvider provideCeilTestCases - */ - public function testItPerformsCeilRounding($number, $precision, $expected) - { - $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, $expected); - } - /** - * Given a decimal number - * When rounding using floor to a target precision - * Then the number should have at most number of decimals - * And it should be rounded to negative infinity if its original precision was larger than the target one - * - * @param string $number - * @param int $precision - * @param string $expected - * - * @dataProvider provideFloorTestCases - */ - public function testItPerformsFloorRounding($number, $precision, $expected) - { - $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR, $expected); - } - /** - * Given a decimal number - * When rounding using half-up to a target precision - * Then - * - the number should have at most number of decimals - * - and it should be rounded - * - away from zero if the digit to the right of its last significant digit was >= 5 - * - towards zero if the digit to the right of its last significant digit was < 5 - * - * @param string $number - * @param int $precision - * @param string $expected - * - * @dataProvider provideHalfUpTestCases - */ - public function testItPerformsHalfUpRounding($number, $precision, $expected) - { - $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, $expected); - } - /** - * Given a decimal number - * When rounding using half-down to a target precision - * Then - * - the number should have at most number of decimals - * - and it should be rounded - * - away from zero if the digit to the right of its last significant digit was > 5 - * - towards zero if the digit to the right of its last significant digit was <= 5 - * - * @param string $number - * @param int $precision - * @param string $expected - * - * @dataProvider provideHalfDownTestCases - */ - public function testItPerformsHalfDownRounding($number, $precision, $expected) - { - $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN, $expected); - } - /** - * Given a decimal number - * When rounding using half-even to a target precision - * Then - * - the number should have at most number of decimals - * - and it should be rounded - * - away from zero - * - if the digit to the right of its last significant digit was > 5 - * - or if the last significant digit is odd and the digit to the right of it is 5 - * - towards zero - * - if the digit to the right of its last significant digit was < 5 - * - or if the last significant digit is even and the digit to the right of it is 5 - * - * @param string $number - * @param int $precision - * @param string $expected - * - * @dataProvider provideHalfEvenTestCases - */ - public function testItPerformsHalfEvenRounding($number, $precision, $expected) - { - $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN, $expected); - } - /** - * Test rounding a number to a target precision using a specific rounding mode. - * - * Given - * - A Decimal\Number constructed with a valid number - * - A target precision - * - A rounding mode - * - And an expected result - * - * When rounding it to a specific precision, using a specific rounding mode - * Then the returned string should match the expected string - * - * @param $number - * @param $precision - * @param $mode - * @param $expected - */ - public function roundNumber($number, $precision, $mode, $expected) - { - $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); - $rounding = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding(); - $result = $rounding->compute($decimalNumber, $precision, $mode); - $this->assertSame($expected, (string) $result); - } - public function provideTruncateTestCases() - { - return [ - '0 digits' => ['1.23456789', 0, '1'], - '1 digit' => ['1.23456789', 1, '1.2'], - '2 digits' => ['1.23456789', 2, '1.23'], - '3 digits' => ['1.23456789', 3, '1.234'], - '4 digits' => ['1.23456789', 4, '1.2345'], - '5 digits' => ['1.23456789', 5, '1.23456'], - '6 digits' => ['1.23456789', 6, '1.234567'], - '7 digits' => ['1.23456789', 7, '1.2345678'], - '8 digits' => ['1.23456789', 8, '1.23456789'], - // should not add trailing zeroes - '9 digits' => ['1.23456789', 9, '1.23456789'], - '10 digits' => ['1.23456789', 10, '1.23456789'], - // negative numbers - '0 digits, negative' => ['-1.23456789', 0, '-1'], - '1 digit, negative' => ['-1.23456789', 1, '-1.2'], - '2 digits, negative' => ['-1.23456789', 2, '-1.23'], - '3 digits, negative' => ['-1.23456789', 3, '-1.234'], - '4 digits, negative' => ['-1.23456789', 4, '-1.2345'], - '5 digits, negative' => ['-1.23456789', 5, '-1.23456'], - '6 digits, negative' => ['-1.23456789', 6, '-1.234567'], - '7 digits, negative' => ['-1.23456789', 7, '-1.2345678'], - '8 digits, negative' => ['-1.23456789', 8, '-1.23456789'], - // should not add trailing zeroes - '9 digits, negative' => ['-1.23456789', 9, '-1.23456789'], - '10 digits, negative' => ['-1.23456789', 10, '-1.23456789'], - ]; - } - public function provideCeilTestCases() - { - return [ - '0 digits' => ['1.23456789', 0, '2'], - '1 digit' => ['1.23456789', 1, '1.3'], - '2 digits' => ['1.23456789', 2, '1.24'], - '3 digits' => ['1.23456789', 3, '1.235'], - '4 digits' => ['1.23456789', 4, '1.2346'], - '5 digits' => ['1.23456789', 5, '1.23457'], - '6 digits' => ['1.23456789', 6, '1.234568'], - '7 digits' => ['1.23456789', 7, '1.2345679'], - '8 digits' => ['1.23456789', 8, '1.23456789'], - // should not add trailing zeroes - '9 digits' => ['1.23456789', 9, '1.23456789'], - '10 digits' => ['1.23456789', 10, '1.23456789'], - // negative numbers - '0 digits, negative' => ['-1.23456789', 0, '-1'], - '1 digit, negative' => ['-1.23456789', 1, '-1.2'], - '2 digits, negative' => ['-1.23456789', 2, '-1.23'], - '3 digits, negative' => ['-1.23456789', 3, '-1.234'], - '4 digits, negative' => ['-1.23456789', 4, '-1.2345'], - '5 digits, negative' => ['-1.23456789', 5, '-1.23456'], - '6 digits, negative' => ['-1.23456789', 6, '-1.234567'], - '7 digits, negative' => ['-1.23456789', 7, '-1.2345678'], - '8 digits, negative' => ['-1.23456789', 8, '-1.23456789'], - // should not add trailing zeroes - '9 digits, negative' => ['-1.23456789', 9, '-1.23456789'], - '10 digits, negative' => ['-1.23456789', 10, '-1.23456789'], - ]; - } - public function provideFloorTestCases() - { - return [ - '0 digits' => ['1.23456789', 0, '1'], - '1 digit' => ['1.23456789', 1, '1.2'], - '2 digits' => ['1.23456789', 2, '1.23'], - '3 digits' => ['1.23456789', 3, '1.234'], - '4 digits' => ['1.23456789', 4, '1.2345'], - '5 digits' => ['1.23456789', 5, '1.23456'], - '6 digits' => ['1.23456789', 6, '1.234567'], - '7 digits' => ['1.23456789', 7, '1.2345678'], - '8 digits' => ['1.23456789', 8, '1.23456789'], - // should not add trailing zeroes - '9 digits' => ['1.23456789', 9, '1.23456789'], - '10 digits' => ['1.23456789', 10, '1.23456789'], - // negative numbers - '0 digits, negative' => ['-1.23456789', 0, '-2'], - '1 digit, negative' => ['-1.23456789', 1, '-1.3'], - '2 digits, negative' => ['-1.23456789', 2, '-1.24'], - '3 digits, negative' => ['-1.23456789', 3, '-1.235'], - '4 digits, negative' => ['-1.23456789', 4, '-1.2346'], - '5 digits, negative' => ['-1.23456789', 5, '-1.23457'], - '6 digits, negative' => ['-1.23456789', 6, '-1.234568'], - '7 digits, negative' => ['-1.23456789', 7, '-1.2345679'], - '8 digits, negative' => ['-1.23456789', 8, '-1.23456789'], - // should not add trailing zeroes - '9 digits, negative' => ['-1.23456789', 9, '-1.23456789'], - '10 digits, negative' => ['-1.23456789', 10, '-1.23456789'], - ]; - } - public function provideHalfUpTestCases() - { - return [ - '0 digits' => ['1.23456789', 0, '1'], - '1 digit' => ['1.23456789', 1, '1.2'], - '2 digits' => ['1.23456789', 2, '1.23'], - '3 digits' => ['1.23456789', 3, '1.235'], - '4 digits' => ['1.23456789', 4, '1.2346'], - '5 digits' => ['1.23456789', 5, '1.23457'], - '6 digits' => ['1.23456789', 6, '1.234568'], - '7 digits' => ['1.23456789', 7, '1.2345679'], - '8 digits' => ['1.23456789', 8, '1.23456789'], - // should not add trailing zeroes - '9 digits' => ['1.23456789', 9, '1.23456789'], - '10 digits' => ['1.23456789', 10, '1.23456789'], - // negative numbers - '0 digits, negative' => ['-1.23456789', 0, '-1'], - '1 digit, negative' => ['-1.23456789', 1, '-1.2'], - '2 digits, negative' => ['-1.23456789', 2, '-1.23'], - '3 digits, negative' => ['-1.23456789', 3, '-1.235'], - '4 digits, negative' => ['-1.23456789', 4, '-1.2346'], - '5 digits, negative' => ['-1.23456789', 5, '-1.23457'], - '6 digits, negative' => ['-1.23456789', 6, '-1.234568'], - '7 digits, negative' => ['-1.23456789', 7, '-1.2345679'], - '8 digits, negative' => ['-1.23456789', 8, '-1.23456789'], - // should not add trailing zeroes - '9 digits, negative' => ['-1.23456789', 9, '-1.23456789'], - '10 digits, negative' => ['-1.23456789', 10, '-1.23456789'], - ]; - } - public function provideHalfDownTestCases() - { - return [ - '0 digits' => ['1.23456789', 0, '1'], - '1 digit' => ['1.23456789', 1, '1.2'], - '2 digits' => ['1.23456789', 2, '1.23'], - '3 digits' => ['1.23456789', 3, '1.234'], - '4 digits' => ['1.23456789', 4, '1.2346'], - '5 digits' => ['1.23456789', 5, '1.23457'], - '6 digits' => ['1.23456789', 6, '1.234568'], - '7 digits' => ['1.23456789', 7, '1.2345679'], - '8 digits' => ['1.23456789', 8, '1.23456789'], - // should not add trailing zeroes - '9 digits' => ['1.23456789', 9, '1.23456789'], - '10 digits' => ['1.23456789', 10, '1.23456789'], - // negative numbers - '0 digits, negative' => ['-1.23456789', 0, '-1'], - '1 digit, negative' => ['-1.23456789', 1, '-1.2'], - '2 digits, negative' => ['-1.23456789', 2, '-1.23'], - '3 digits, negative' => ['-1.23456789', 3, '-1.234'], - '4 digits, negative' => ['-1.23456789', 4, '-1.2346'], - '5 digits, negative' => ['-1.23456789', 5, '-1.23457'], - '6 digits, negative' => ['-1.23456789', 6, '-1.234568'], - '7 digits, negative' => ['-1.23456789', 7, '-1.2345679'], - '8 digits, negative' => ['-1.23456789', 8, '-1.23456789'], - // should not add trailing zeroes - '9 digits, negative' => ['-1.23456789', 9, '-1.23456789'], - '10 digits, negative' => ['-1.23456789', 10, '-1.23456789'], - ]; - } - public function provideHalfEvenTestCases() - { - return [ - 'round even' => ['2.5', 0, '2'], - 'round odd' => ['1.5', 0, '2'], - '0 digits' => ['1.1525354556575859505', 0, '1'], - '1 digit' => ['1.1525354556575859505', 1, '1.2'], - '2 digits' => ['1.1525354556575859505', 2, '1.15'], - '3 digits' => ['1.1525354556575859505', 3, '1.152'], - '4 digits' => ['1.1525354556575859505', 4, '1.1525'], - '5 digits' => ['1.1525354556575859505', 5, '1.15254'], - '6 digits' => ['1.1525354556575859505', 6, '1.152535'], - '7 digits' => ['1.1525354556575859505', 7, '1.1525354'], - '8 digits' => ['1.1525354556575859505', 8, '1.15253546'], - '9 digits' => ['1.1525354556575859505', 9, '1.152535456'], - '10 digits' => ['1.1525354556575859505', 10, '1.1525354556'], - '11 digits' => ['1.1525354556575859505', 11, '1.15253545566'], - '12 digits' => ['1.1525354556575859505', 12, '1.152535455658'], - '13 digits' => ['1.1525354556575859505', 13, '1.1525354556576'], - '14 digits' => ['1.1525354556575859505', 14, '1.15253545565758'], - '15 digits' => ['1.1525354556575859505', 15, '1.152535455657586'], - '16 digits' => ['1.1525354556575859505', 16, '1.152535455657586'], - '17 digits' => ['1.1525354556575859505', 17, '1.15253545565758595'], - '18 digits' => ['1.1525354556575859505', 18, '1.15253545565758595'], - '19 digits' => ['1.1525354556575859505', 19, '1.1525354556575859505'], - // should not add trailing zeroes - '20 digits' => ['1.1525354556575859505', 20, '1.1525354556575859505'], - // negative numbers - 'round even, negative' => ['-2.5', 0, '-2'], - 'round odd, negative' => ['-1.5', 0, '-2'], - '0 digits, negative' => ['-1.1525354556575859505', 0, '-1'], - '1 digit, negative' => ['-1.1525354556575859505', 1, '-1.2'], - '2 digits, negative' => ['-1.1525354556575859505', 2, '-1.15'], - '3 digits, negative' => ['-1.1525354556575859505', 3, '-1.152'], - '4 digits, negative' => ['-1.1525354556575859505', 4, '-1.1525'], - '5 digits, negative' => ['-1.1525354556575859505', 5, '-1.15254'], - '6 digits, negative' => ['-1.1525354556575859505', 6, '-1.152535'], - '7 digits, negative' => ['-1.1525354556575859505', 7, '-1.1525354'], - '8 digits, negative' => ['-1.1525354556575859505', 8, '-1.15253546'], - '11 digits, negative' => ['-1.1525354556575859505', 11, '-1.15253545566'], - '12 digits, negative' => ['-1.1525354556575859505', 12, '-1.152535455658'], - '13 digits, negative' => ['-1.1525354556575859505', 13, '-1.1525354556576'], - '14 digits, negative' => ['-1.1525354556575859505', 14, '-1.15253545565758'], - '15 digits, negative' => ['-1.1525354556575859505', 15, '-1.152535455657586'], - '16 digits, negative' => ['-1.1525354556575859505', 16, '-1.152535455657586'], - '17 digits, negative' => ['-1.1525354556575859505', 17, '-1.15253545565758595'], - '18 digits, negative' => ['-1.1525354556575859505', 18, '-1.15253545565758595'], - '19 digits, negative' => ['-1.1525354556575859505', 19, '-1.1525354556575859505'], - // should not add trailing zeroes - '20 digits, negative' => ['-1.1525354556575859505', 20, '-1.1525354556575859505'], - ]; - } - public function provideInvalidPrecision() - { - return [[-1], ['foo'], [\true], [array()]]; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; +class RoundingTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase +{ + /** + * Given decimal number + * When rounding it using an undefined rounding mode + * An InvalidArgumentException should be thrown + * + * @expectedException \InvalidArgumentException + */ + public function testItThrowsExceptionIfRoundingModeIsInvalid() + { + $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1.2345'); + $rounding = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding(); + $rounding->compute($decimalNumber, 2, 'foobar'); + } + /** + * Given decimal number + * When rounding to an invalid precision + * An InvalidArgumentException should be thrown + * + * @param mixed $precision + * + * @expectedException \InvalidArgumentException + * + * @dataProvider provideInvalidPrecision + */ + public function testItThrowsExceptionIfPrecisionIsInvalid($precision) + { + $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number('1.2345'); + $rounding = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding(); + $rounding->compute($decimalNumber, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR); + } + /** + * Given a decimal number + * When truncating the number to a target precision + * Then the resulting number should have at most number of decimals + * + * @param string $number + * @param int $precision + * @param string $expected + * + * @dataProvider provideTruncateTestCases + */ + public function testItTruncatesNumbers($number, $precision, $expected) + { + $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_TRUNCATE, $expected); + } + /** + * Given a decimal number + * When rounding using ceiling to a target precision + * Then the number should have at most number of decimals + * And it should be rounded to positive infinity if its original precision was larger than the target one + * + * @param string $number + * @param int $precision + * @param string $expected + * + * @dataProvider provideCeilTestCases + */ + public function testItPerformsCeilRounding($number, $precision, $expected) + { + $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_CEIL, $expected); + } + /** + * Given a decimal number + * When rounding using floor to a target precision + * Then the number should have at most number of decimals + * And it should be rounded to negative infinity if its original precision was larger than the target one + * + * @param string $number + * @param int $precision + * @param string $expected + * + * @dataProvider provideFloorTestCases + */ + public function testItPerformsFloorRounding($number, $precision, $expected) + { + $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_FLOOR, $expected); + } + /** + * Given a decimal number + * When rounding using half-up to a target precision + * Then + * - the number should have at most number of decimals + * - and it should be rounded + * - away from zero if the digit to the right of its last significant digit was >= 5 + * - towards zero if the digit to the right of its last significant digit was < 5 + * + * @param string $number + * @param int $precision + * @param string $expected + * + * @dataProvider provideHalfUpTestCases + */ + public function testItPerformsHalfUpRounding($number, $precision, $expected) + { + $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_UP, $expected); + } + /** + * Given a decimal number + * When rounding using half-down to a target precision + * Then + * - the number should have at most number of decimals + * - and it should be rounded + * - away from zero if the digit to the right of its last significant digit was > 5 + * - towards zero if the digit to the right of its last significant digit was <= 5 + * + * @param string $number + * @param int $precision + * @param string $expected + * + * @dataProvider provideHalfDownTestCases + */ + public function testItPerformsHalfDownRounding($number, $precision, $expected) + { + $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_DOWN, $expected); + } + /** + * Given a decimal number + * When rounding using half-even to a target precision + * Then + * - the number should have at most number of decimals + * - and it should be rounded + * - away from zero + * - if the digit to the right of its last significant digit was > 5 + * - or if the last significant digit is odd and the digit to the right of it is 5 + * - towards zero + * - if the digit to the right of its last significant digit was < 5 + * - or if the last significant digit is even and the digit to the right of it is 5 + * + * @param string $number + * @param int $precision + * @param string $expected + * + * @dataProvider provideHalfEvenTestCases + */ + public function testItPerformsHalfEvenRounding($number, $precision, $expected) + { + $this->roundNumber($number, $precision, \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding::ROUND_HALF_EVEN, $expected); + } + /** + * Test rounding a number to a target precision using a specific rounding mode. + * + * Given + * - A Decimal\Number constructed with a valid number + * - A target precision + * - A rounding mode + * - And an expected result + * + * When rounding it to a specific precision, using a specific rounding mode + * Then the returned string should match the expected string + * + * @param $number + * @param $precision + * @param $mode + * @param $expected + */ + public function roundNumber($number, $precision, $mode, $expected) + { + $decimalNumber = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number); + $rounding = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Rounding(); + $result = $rounding->compute($decimalNumber, $precision, $mode); + $this->assertSame($expected, (string) $result); + } + public function provideTruncateTestCases() + { + return [ + '0 digits' => ['1.23456789', 0, '1'], + '1 digit' => ['1.23456789', 1, '1.2'], + '2 digits' => ['1.23456789', 2, '1.23'], + '3 digits' => ['1.23456789', 3, '1.234'], + '4 digits' => ['1.23456789', 4, '1.2345'], + '5 digits' => ['1.23456789', 5, '1.23456'], + '6 digits' => ['1.23456789', 6, '1.234567'], + '7 digits' => ['1.23456789', 7, '1.2345678'], + '8 digits' => ['1.23456789', 8, '1.23456789'], + // should not add trailing zeroes + '9 digits' => ['1.23456789', 9, '1.23456789'], + '10 digits' => ['1.23456789', 10, '1.23456789'], + // negative numbers + '0 digits, negative' => ['-1.23456789', 0, '-1'], + '1 digit, negative' => ['-1.23456789', 1, '-1.2'], + '2 digits, negative' => ['-1.23456789', 2, '-1.23'], + '3 digits, negative' => ['-1.23456789', 3, '-1.234'], + '4 digits, negative' => ['-1.23456789', 4, '-1.2345'], + '5 digits, negative' => ['-1.23456789', 5, '-1.23456'], + '6 digits, negative' => ['-1.23456789', 6, '-1.234567'], + '7 digits, negative' => ['-1.23456789', 7, '-1.2345678'], + '8 digits, negative' => ['-1.23456789', 8, '-1.23456789'], + // should not add trailing zeroes + '9 digits, negative' => ['-1.23456789', 9, '-1.23456789'], + '10 digits, negative' => ['-1.23456789', 10, '-1.23456789'], + ]; + } + public function provideCeilTestCases() + { + return [ + '0 digits' => ['1.23456789', 0, '2'], + '1 digit' => ['1.23456789', 1, '1.3'], + '2 digits' => ['1.23456789', 2, '1.24'], + '3 digits' => ['1.23456789', 3, '1.235'], + '4 digits' => ['1.23456789', 4, '1.2346'], + '5 digits' => ['1.23456789', 5, '1.23457'], + '6 digits' => ['1.23456789', 6, '1.234568'], + '7 digits' => ['1.23456789', 7, '1.2345679'], + '8 digits' => ['1.23456789', 8, '1.23456789'], + // should not add trailing zeroes + '9 digits' => ['1.23456789', 9, '1.23456789'], + '10 digits' => ['1.23456789', 10, '1.23456789'], + // negative numbers + '0 digits, negative' => ['-1.23456789', 0, '-1'], + '1 digit, negative' => ['-1.23456789', 1, '-1.2'], + '2 digits, negative' => ['-1.23456789', 2, '-1.23'], + '3 digits, negative' => ['-1.23456789', 3, '-1.234'], + '4 digits, negative' => ['-1.23456789', 4, '-1.2345'], + '5 digits, negative' => ['-1.23456789', 5, '-1.23456'], + '6 digits, negative' => ['-1.23456789', 6, '-1.234567'], + '7 digits, negative' => ['-1.23456789', 7, '-1.2345678'], + '8 digits, negative' => ['-1.23456789', 8, '-1.23456789'], + // should not add trailing zeroes + '9 digits, negative' => ['-1.23456789', 9, '-1.23456789'], + '10 digits, negative' => ['-1.23456789', 10, '-1.23456789'], + ]; + } + public function provideFloorTestCases() + { + return [ + '0 digits' => ['1.23456789', 0, '1'], + '1 digit' => ['1.23456789', 1, '1.2'], + '2 digits' => ['1.23456789', 2, '1.23'], + '3 digits' => ['1.23456789', 3, '1.234'], + '4 digits' => ['1.23456789', 4, '1.2345'], + '5 digits' => ['1.23456789', 5, '1.23456'], + '6 digits' => ['1.23456789', 6, '1.234567'], + '7 digits' => ['1.23456789', 7, '1.2345678'], + '8 digits' => ['1.23456789', 8, '1.23456789'], + // should not add trailing zeroes + '9 digits' => ['1.23456789', 9, '1.23456789'], + '10 digits' => ['1.23456789', 10, '1.23456789'], + // negative numbers + '0 digits, negative' => ['-1.23456789', 0, '-2'], + '1 digit, negative' => ['-1.23456789', 1, '-1.3'], + '2 digits, negative' => ['-1.23456789', 2, '-1.24'], + '3 digits, negative' => ['-1.23456789', 3, '-1.235'], + '4 digits, negative' => ['-1.23456789', 4, '-1.2346'], + '5 digits, negative' => ['-1.23456789', 5, '-1.23457'], + '6 digits, negative' => ['-1.23456789', 6, '-1.234568'], + '7 digits, negative' => ['-1.23456789', 7, '-1.2345679'], + '8 digits, negative' => ['-1.23456789', 8, '-1.23456789'], + // should not add trailing zeroes + '9 digits, negative' => ['-1.23456789', 9, '-1.23456789'], + '10 digits, negative' => ['-1.23456789', 10, '-1.23456789'], + ]; + } + public function provideHalfUpTestCases() + { + return [ + '0 digits' => ['1.23456789', 0, '1'], + '1 digit' => ['1.23456789', 1, '1.2'], + '2 digits' => ['1.23456789', 2, '1.23'], + '3 digits' => ['1.23456789', 3, '1.235'], + '4 digits' => ['1.23456789', 4, '1.2346'], + '5 digits' => ['1.23456789', 5, '1.23457'], + '6 digits' => ['1.23456789', 6, '1.234568'], + '7 digits' => ['1.23456789', 7, '1.2345679'], + '8 digits' => ['1.23456789', 8, '1.23456789'], + // should not add trailing zeroes + '9 digits' => ['1.23456789', 9, '1.23456789'], + '10 digits' => ['1.23456789', 10, '1.23456789'], + // negative numbers + '0 digits, negative' => ['-1.23456789', 0, '-1'], + '1 digit, negative' => ['-1.23456789', 1, '-1.2'], + '2 digits, negative' => ['-1.23456789', 2, '-1.23'], + '3 digits, negative' => ['-1.23456789', 3, '-1.235'], + '4 digits, negative' => ['-1.23456789', 4, '-1.2346'], + '5 digits, negative' => ['-1.23456789', 5, '-1.23457'], + '6 digits, negative' => ['-1.23456789', 6, '-1.234568'], + '7 digits, negative' => ['-1.23456789', 7, '-1.2345679'], + '8 digits, negative' => ['-1.23456789', 8, '-1.23456789'], + // should not add trailing zeroes + '9 digits, negative' => ['-1.23456789', 9, '-1.23456789'], + '10 digits, negative' => ['-1.23456789', 10, '-1.23456789'], + ]; + } + public function provideHalfDownTestCases() + { + return [ + '0 digits' => ['1.23456789', 0, '1'], + '1 digit' => ['1.23456789', 1, '1.2'], + '2 digits' => ['1.23456789', 2, '1.23'], + '3 digits' => ['1.23456789', 3, '1.234'], + '4 digits' => ['1.23456789', 4, '1.2346'], + '5 digits' => ['1.23456789', 5, '1.23457'], + '6 digits' => ['1.23456789', 6, '1.234568'], + '7 digits' => ['1.23456789', 7, '1.2345679'], + '8 digits' => ['1.23456789', 8, '1.23456789'], + // should not add trailing zeroes + '9 digits' => ['1.23456789', 9, '1.23456789'], + '10 digits' => ['1.23456789', 10, '1.23456789'], + // negative numbers + '0 digits, negative' => ['-1.23456789', 0, '-1'], + '1 digit, negative' => ['-1.23456789', 1, '-1.2'], + '2 digits, negative' => ['-1.23456789', 2, '-1.23'], + '3 digits, negative' => ['-1.23456789', 3, '-1.234'], + '4 digits, negative' => ['-1.23456789', 4, '-1.2346'], + '5 digits, negative' => ['-1.23456789', 5, '-1.23457'], + '6 digits, negative' => ['-1.23456789', 6, '-1.234568'], + '7 digits, negative' => ['-1.23456789', 7, '-1.2345679'], + '8 digits, negative' => ['-1.23456789', 8, '-1.23456789'], + // should not add trailing zeroes + '9 digits, negative' => ['-1.23456789', 9, '-1.23456789'], + '10 digits, negative' => ['-1.23456789', 10, '-1.23456789'], + ]; + } + public function provideHalfEvenTestCases() + { + return [ + 'round even' => ['2.5', 0, '2'], + 'round odd' => ['1.5', 0, '2'], + '0 digits' => ['1.1525354556575859505', 0, '1'], + '1 digit' => ['1.1525354556575859505', 1, '1.2'], + '2 digits' => ['1.1525354556575859505', 2, '1.15'], + '3 digits' => ['1.1525354556575859505', 3, '1.152'], + '4 digits' => ['1.1525354556575859505', 4, '1.1525'], + '5 digits' => ['1.1525354556575859505', 5, '1.15254'], + '6 digits' => ['1.1525354556575859505', 6, '1.152535'], + '7 digits' => ['1.1525354556575859505', 7, '1.1525354'], + '8 digits' => ['1.1525354556575859505', 8, '1.15253546'], + '9 digits' => ['1.1525354556575859505', 9, '1.152535456'], + '10 digits' => ['1.1525354556575859505', 10, '1.1525354556'], + '11 digits' => ['1.1525354556575859505', 11, '1.15253545566'], + '12 digits' => ['1.1525354556575859505', 12, '1.152535455658'], + '13 digits' => ['1.1525354556575859505', 13, '1.1525354556576'], + '14 digits' => ['1.1525354556575859505', 14, '1.15253545565758'], + '15 digits' => ['1.1525354556575859505', 15, '1.152535455657586'], + '16 digits' => ['1.1525354556575859505', 16, '1.152535455657586'], + '17 digits' => ['1.1525354556575859505', 17, '1.15253545565758595'], + '18 digits' => ['1.1525354556575859505', 18, '1.15253545565758595'], + '19 digits' => ['1.1525354556575859505', 19, '1.1525354556575859505'], + // should not add trailing zeroes + '20 digits' => ['1.1525354556575859505', 20, '1.1525354556575859505'], + // negative numbers + 'round even, negative' => ['-2.5', 0, '-2'], + 'round odd, negative' => ['-1.5', 0, '-2'], + '0 digits, negative' => ['-1.1525354556575859505', 0, '-1'], + '1 digit, negative' => ['-1.1525354556575859505', 1, '-1.2'], + '2 digits, negative' => ['-1.1525354556575859505', 2, '-1.15'], + '3 digits, negative' => ['-1.1525354556575859505', 3, '-1.152'], + '4 digits, negative' => ['-1.1525354556575859505', 4, '-1.1525'], + '5 digits, negative' => ['-1.1525354556575859505', 5, '-1.15254'], + '6 digits, negative' => ['-1.1525354556575859505', 6, '-1.152535'], + '7 digits, negative' => ['-1.1525354556575859505', 7, '-1.1525354'], + '8 digits, negative' => ['-1.1525354556575859505', 8, '-1.15253546'], + '11 digits, negative' => ['-1.1525354556575859505', 11, '-1.15253545566'], + '12 digits, negative' => ['-1.1525354556575859505', 12, '-1.152535455658'], + '13 digits, negative' => ['-1.1525354556575859505', 13, '-1.1525354556576'], + '14 digits, negative' => ['-1.1525354556575859505', 14, '-1.15253545565758'], + '15 digits, negative' => ['-1.1525354556575859505', 15, '-1.152535455657586'], + '16 digits, negative' => ['-1.1525354556575859505', 16, '-1.152535455657586'], + '17 digits, negative' => ['-1.1525354556575859505', 17, '-1.15253545565758595'], + '18 digits, negative' => ['-1.1525354556575859505', 18, '-1.15253545565758595'], + '19 digits, negative' => ['-1.1525354556575859505', 19, '-1.1525354556575859505'], + // should not add trailing zeroes + '20 digits, negative' => ['-1.1525354556575859505', 20, '-1.1525354556575859505'], + ]; + } + public function provideInvalidPrecision() + { + return [[-1], ['foo'], [\true], [array()]]; + } +} diff --git a/vendor/prestashop/decimal/tests/Operation/SubtractionTest.php b/vendor/prestashop/decimal/tests/Operation/SubtractionTest.php index 0b0e78aa3..e01388410 100644 --- a/vendor/prestashop/decimal/tests/Operation/SubtractionTest.php +++ b/vendor/prestashop/decimal/tests/Operation/SubtractionTest.php @@ -1,40 +1,40 @@ - - * @license https://opensource.org/licenses/MIT MIT License - */ -namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; - -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; -use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Subtraction; -class SubtractionTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase -{ - /** - * Given two decimal numbers - * When computing the subtraction operation - * Then we should get the result of subtracting those numbers - * - * @param string $number1 - * @param string $number2 - * @param string $expectedResult - * - * @dataProvider provideNumbersToSubtract - */ - public function testItSubtractsNumbers($number1, $number2, $expectedResult) - { - $n1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); - $n2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); - $operation = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Subtraction(); - $result1 = $operation->computeUsingBcMath($n1, $n2); - $result2 = $operation->computeWithoutBcMath($n1, $n2); - $this->assertSame($expectedResult, (string) $result1, "Failed asserting {$number1} - {$number2} = {$expectedResult} (BC Math)"); - $this->assertSame($expectedResult, (string) $result2, "Failed asserting {$number1} - {$number2} = {$expectedResult}"); - } - public function provideNumbersToSubtract() - { - return [['0', '0', '0'], ['0', '5', '-5'], ['0', '5.1', '-5.1'], ['2', '1', '1'], ['1', '2', '-1'], ['-1', '2', '-3'], ['1', '-2', '3'], ['-1', '-2', '1'], ['5', '0', '5'], ['5.1', '0', '5.1'], ['1.234', '5', '-3.766'], ['5', '1.234', '3.766'], ['10', '0.0000000', '10'], ['0.0000000', '10', '-10'], ['10.01', '0.0000000', '10.01'], ['1', '0.0000001', '0.9999999'], ['1', '0.0000001', '0.9999999'], ['0', '0.0000001', '-0.0000001'], ['0.0000001', '0.0000001', '0'], ['0.0000001', '0.0000002', '-0.0000001'], ['0.0000000', '10.01', '-10.01'], ['0.0000001', '10.01', '-10.0099999'], ['9.999999', '9.999999', '0'], ['9.999999999999999999', '9.999999999999999999', '0'], ['9.999999999999999999', '9.999999999999999998', '0.000000000000000001'], ['9223372036854775807.9223372036854775807', '1.01', '9223372036854775806.9123372036854775807']]; - } -} + + * @license https://opensource.org/licenses/MIT MIT License + */ +namespace _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Test\Operation; + +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number; +use _PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Subtraction; +class SubtractionTest extends \_PhpScoper5ea00cc67502b\PHPUnit_Framework_TestCase +{ + /** + * Given two decimal numbers + * When computing the subtraction operation + * Then we should get the result of subtracting those numbers + * + * @param string $number1 + * @param string $number2 + * @param string $expectedResult + * + * @dataProvider provideNumbersToSubtract + */ + public function testItSubtractsNumbers($number1, $number2, $expectedResult) + { + $n1 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number1); + $n2 = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Number($number2); + $operation = new \_PhpScoper5ea00cc67502b\PrestaShop\Decimal\Operation\Subtraction(); + $result1 = $operation->computeUsingBcMath($n1, $n2); + $result2 = $operation->computeWithoutBcMath($n1, $n2); + $this->assertSame($expectedResult, (string) $result1, "Failed asserting {$number1} - {$number2} = {$expectedResult} (BC Math)"); + $this->assertSame($expectedResult, (string) $result2, "Failed asserting {$number1} - {$number2} = {$expectedResult}"); + } + public function provideNumbersToSubtract() + { + return [['0', '0', '0'], ['0', '5', '-5'], ['0', '5.1', '-5.1'], ['2', '1', '1'], ['1', '2', '-1'], ['-1', '2', '-3'], ['1', '-2', '3'], ['-1', '-2', '1'], ['5', '0', '5'], ['5.1', '0', '5.1'], ['1.234', '5', '-3.766'], ['5', '1.234', '3.766'], ['10', '0.0000000', '10'], ['0.0000000', '10', '-10'], ['10.01', '0.0000000', '10.01'], ['1', '0.0000001', '0.9999999'], ['1', '0.0000001', '0.9999999'], ['0', '0.0000001', '-0.0000001'], ['0.0000001', '0.0000001', '0'], ['0.0000001', '0.0000002', '-0.0000001'], ['0.0000000', '10.01', '-10.01'], ['0.0000001', '10.01', '-10.0099999'], ['9.999999', '9.999999', '0'], ['9.999999999999999999', '9.999999999999999999', '0'], ['9.999999999999999999', '9.999999999999999998', '0.000000000000000001'], ['9223372036854775807.9223372036854775807', '1.01', '9223372036854775806.9123372036854775807']]; + } +} diff --git a/vendor/psr/cache/CHANGELOG.md b/vendor/psr/cache/CHANGELOG.md index 58ddab05a..26ba50732 100644 --- a/vendor/psr/cache/CHANGELOG.md +++ b/vendor/psr/cache/CHANGELOG.md @@ -1,16 +1,16 @@ -# Changelog - -All notable changes to this project will be documented in this file, in reverse chronological order by release. - -## 1.0.1 - 2016-08-06 - -### Fixed - -- Make spacing consistent in phpdoc annotations php-fig/cache#9 - chalasr -- Fix grammar in phpdoc annotations php-fig/cache#10 - chalasr -- Be more specific in docblocks that `getItems()` and `deleteItems()` take an array of strings (`string[]`) compared to just `array` php-fig/cache#8 - GrahamCampbell -- For `expiresAt()` and `expiresAfter()` in CacheItemInterface fix docblock to specify null as a valid parameters as well as an implementation of DateTimeInterface php-fig/cache#7 - GrahamCampbell - -## 1.0.0 - 2015-12-11 - -Initial stable release; reflects accepted PSR-6 specification +# Changelog + +All notable changes to this project will be documented in this file, in reverse chronological order by release. + +## 1.0.1 - 2016-08-06 + +### Fixed + +- Make spacing consistent in phpdoc annotations php-fig/cache#9 - chalasr +- Fix grammar in phpdoc annotations php-fig/cache#10 - chalasr +- Be more specific in docblocks that `getItems()` and `deleteItems()` take an array of strings (`string[]`) compared to just `array` php-fig/cache#8 - GrahamCampbell +- For `expiresAt()` and `expiresAfter()` in CacheItemInterface fix docblock to specify null as a valid parameters as well as an implementation of DateTimeInterface php-fig/cache#7 - GrahamCampbell + +## 1.0.0 - 2015-12-11 + +Initial stable release; reflects accepted PSR-6 specification diff --git a/vendor/psr/cache/LICENSE.txt b/vendor/psr/cache/LICENSE.txt index b1c2c97b9..fa880fd3f 100644 --- a/vendor/psr/cache/LICENSE.txt +++ b/vendor/psr/cache/LICENSE.txt @@ -1,19 +1,19 @@ -Copyright (c) 2015 PHP Framework Interoperability Group - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2015 PHP Framework Interoperability Group + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/psr/cache/README.md b/vendor/psr/cache/README.md index c8706ceea..e4daa2eab 100644 --- a/vendor/psr/cache/README.md +++ b/vendor/psr/cache/README.md @@ -1,9 +1,9 @@ -PSR Cache -========= - -This repository holds all interfaces defined by -[PSR-6](http://www.php-fig.org/psr/psr-6/). - -Note that this is not a Cache implementation of its own. It is merely an -interface that describes a Cache implementation. See the specification for more -details. +PSR Cache +========= + +This repository holds all interfaces defined by +[PSR-6](http://www.php-fig.org/psr/psr-6/). + +Note that this is not a Cache implementation of its own. It is merely an +interface that describes a Cache implementation. See the specification for more +details. diff --git a/vendor/psr/cache/composer.json b/vendor/psr/cache/composer.json index 905322ac1..3607fc9ff 100644 --- a/vendor/psr/cache/composer.json +++ b/vendor/psr/cache/composer.json @@ -1,29 +1,29 @@ -{ - "name": "psr\/cache", - "description": "Common interface for caching libraries", - "keywords": [ - "psr", - "psr-6", - "cache" - ], - "license": "MIT", - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http:\/\/www.php-fig.org\/" - } - ], - "require": { - "php": ">=5.3.0" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Psr\\Cache\\": "src\/" - } - }, - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - } +{ + "name": "psr\/cache", + "description": "Common interface for caching libraries", + "keywords": [ + "psr", + "psr-6", + "cache" + ], + "license": "MIT", + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http:\/\/www.php-fig.org\/" + } + ], + "require": { + "php": ">=5.3.0" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Psr\\Cache\\": "src\/" + } + }, + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + } } \ No newline at end of file diff --git a/vendor/psr/cache/index.php b/vendor/psr/cache/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/psr/cache/index.php +++ b/vendor/psr/cache/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/cache/src/CacheException.php b/vendor/psr/cache/src/CacheException.php index 1daa2048b..a077f92b2 100644 --- a/vendor/psr/cache/src/CacheException.php +++ b/vendor/psr/cache/src/CacheException.php @@ -1,10 +1,10 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/container/.gitignore b/vendor/psr/container/.gitignore index b2395aa05..a40d6f586 100644 --- a/vendor/psr/container/.gitignore +++ b/vendor/psr/container/.gitignore @@ -1,3 +1,3 @@ -composer.lock -composer.phar -/vendor/ +composer.lock +composer.phar +/vendor/ diff --git a/vendor/psr/container/LICENSE b/vendor/psr/container/LICENSE index 2877a4894..9fbca1766 100644 --- a/vendor/psr/container/LICENSE +++ b/vendor/psr/container/LICENSE @@ -1,21 +1,21 @@ -The MIT License (MIT) - -Copyright (c) 2013-2016 container-interop -Copyright (c) 2016 PHP Framework Interoperability Group - -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal in -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of -the Software, and to permit persons to whom the Software is furnished to do so, -subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS -FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR -COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER -IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +The MIT License (MIT) + +Copyright (c) 2013-2016 container-interop +Copyright (c) 2016 PHP Framework Interoperability Group + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/vendor/psr/container/README.md b/vendor/psr/container/README.md index 084f6df51..bbecc31d2 100644 --- a/vendor/psr/container/README.md +++ b/vendor/psr/container/README.md @@ -1,5 +1,5 @@ -# PSR Container - -This repository holds all interfaces/classes/traits related to [PSR-11](https://github.com/container-interop/fig-standards/blob/master/proposed/container.md). - -Note that this is not a container implementation of its own. See the specification for more details. +# PSR Container + +This repository holds all interfaces/classes/traits related to [PSR-11](https://github.com/container-interop/fig-standards/blob/master/proposed/container.md). + +Note that this is not a container implementation of its own. See the specification for more details. diff --git a/vendor/psr/container/composer.json b/vendor/psr/container/composer.json index 7f451bdbe..83d3f9767 100644 --- a/vendor/psr/container/composer.json +++ b/vendor/psr/container/composer.json @@ -1,33 +1,33 @@ -{ - "name": "psr\/container", - "type": "library", - "description": "Common Container Interface (PHP FIG PSR-11)", - "keywords": [ - "psr", - "psr-11", - "container", - "container-interop", - "container-interface" - ], - "homepage": "https:\/\/github.com\/php-fig\/container", - "license": "MIT", - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http:\/\/www.php-fig.org\/" - } - ], - "require": { - "php": ">=5.3.0" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Psr\\Container\\": "src\/" - } - }, - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - } +{ + "name": "psr\/container", + "type": "library", + "description": "Common Container Interface (PHP FIG PSR-11)", + "keywords": [ + "psr", + "psr-11", + "container", + "container-interop", + "container-interface" + ], + "homepage": "https:\/\/github.com\/php-fig\/container", + "license": "MIT", + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http:\/\/www.php-fig.org\/" + } + ], + "require": { + "php": ">=5.3.0" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Psr\\Container\\": "src\/" + } + }, + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + } } \ No newline at end of file diff --git a/vendor/psr/container/index.php b/vendor/psr/container/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/psr/container/index.php +++ b/vendor/psr/container/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/container/src/ContainerExceptionInterface.php b/vendor/psr/container/src/ContainerExceptionInterface.php index 8331de31f..8c2e75483 100644 --- a/vendor/psr/container/src/ContainerExceptionInterface.php +++ b/vendor/psr/container/src/ContainerExceptionInterface.php @@ -1,13 +1,13 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/http-message/CHANGELOG.md b/vendor/psr/http-message/CHANGELOG.md index 74b1ef923..4e7cf83db 100644 --- a/vendor/psr/http-message/CHANGELOG.md +++ b/vendor/psr/http-message/CHANGELOG.md @@ -1,36 +1,36 @@ -# Changelog - -All notable changes to this project will be documented in this file, in reverse chronological order by release. - -## 1.0.1 - 2016-08-06 - -### Added - -- Nothing. - -### Deprecated - -- Nothing. - -### Removed - -- Nothing. - -### Fixed - -- Updated all `@return self` annotation references in interfaces to use - `@return static`, which more closelly follows the semantics of the - specification. -- Updated the `MessageInterface::getHeaders()` return annotation to use the - value `string[][]`, indicating the format is a nested array of strings. -- Updated the `@link` annotation for `RequestInterface::withRequestTarget()` - to point to the correct section of RFC 7230. -- Updated the `ServerRequestInterface::withUploadedFiles()` parameter annotation - to add the parameter name (`$uploadedFiles`). -- Updated a `@throws` annotation for the `UploadedFileInterface::moveTo()` - method to correctly reference the method parameter (it was referencing an - incorrect parameter name previously). - -## 1.0.0 - 2016-05-18 - -Initial stable release; reflects accepted PSR-7 specification. +# Changelog + +All notable changes to this project will be documented in this file, in reverse chronological order by release. + +## 1.0.1 - 2016-08-06 + +### Added + +- Nothing. + +### Deprecated + +- Nothing. + +### Removed + +- Nothing. + +### Fixed + +- Updated all `@return self` annotation references in interfaces to use + `@return static`, which more closelly follows the semantics of the + specification. +- Updated the `MessageInterface::getHeaders()` return annotation to use the + value `string[][]`, indicating the format is a nested array of strings. +- Updated the `@link` annotation for `RequestInterface::withRequestTarget()` + to point to the correct section of RFC 7230. +- Updated the `ServerRequestInterface::withUploadedFiles()` parameter annotation + to add the parameter name (`$uploadedFiles`). +- Updated a `@throws` annotation for the `UploadedFileInterface::moveTo()` + method to correctly reference the method parameter (it was referencing an + incorrect parameter name previously). + +## 1.0.0 - 2016-05-18 + +Initial stable release; reflects accepted PSR-7 specification. diff --git a/vendor/psr/http-message/LICENSE b/vendor/psr/http-message/LICENSE index c2d8e452d..4492a27bf 100644 --- a/vendor/psr/http-message/LICENSE +++ b/vendor/psr/http-message/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2014 PHP Framework Interoperability Group - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2014 PHP Framework Interoperability Group + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/psr/http-message/README.md b/vendor/psr/http-message/README.md index 28185338f..696267098 100644 --- a/vendor/psr/http-message/README.md +++ b/vendor/psr/http-message/README.md @@ -1,13 +1,13 @@ -PSR Http Message -================ - -This repository holds all interfaces/classes/traits related to -[PSR-7](http://www.php-fig.org/psr/psr-7/). - -Note that this is not a HTTP message implementation of its own. It is merely an -interface that describes a HTTP message. See the specification for more details. - -Usage ------ - +PSR Http Message +================ + +This repository holds all interfaces/classes/traits related to +[PSR-7](http://www.php-fig.org/psr/psr-7/). + +Note that this is not a HTTP message implementation of its own. It is merely an +interface that describes a HTTP message. See the specification for more details. + +Usage +----- + We'll certainly need some stuff in here. \ No newline at end of file diff --git a/vendor/psr/http-message/composer.json b/vendor/psr/http-message/composer.json index c68ac0a0c..0393bf045 100644 --- a/vendor/psr/http-message/composer.json +++ b/vendor/psr/http-message/composer.json @@ -1,33 +1,33 @@ -{ - "name": "psr\/http-message", - "description": "Common interface for HTTP messages", - "keywords": [ - "psr", - "psr-7", - "http", - "http-message", - "request", - "response" - ], - "homepage": "https:\/\/github.com\/php-fig\/http-message", - "license": "MIT", - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http:\/\/www.php-fig.org\/" - } - ], - "require": { - "php": ">=5.3.0" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\": "src\/" - } - }, - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - } +{ + "name": "psr\/http-message", + "description": "Common interface for HTTP messages", + "keywords": [ + "psr", + "psr-7", + "http", + "http-message", + "request", + "response" + ], + "homepage": "https:\/\/github.com\/php-fig\/http-message", + "license": "MIT", + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http:\/\/www.php-fig.org\/" + } + ], + "require": { + "php": ">=5.3.0" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Psr\\Http\\Message\\": "src\/" + } + }, + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + } } \ No newline at end of file diff --git a/vendor/psr/http-message/index.php b/vendor/psr/http-message/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/psr/http-message/index.php +++ b/vendor/psr/http-message/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/http-message/src/MessageInterface.php b/vendor/psr/http-message/src/MessageInterface.php index f3aecc897..d2a8efc90 100644 --- a/vendor/psr/http-message/src/MessageInterface.php +++ b/vendor/psr/http-message/src/MessageInterface.php @@ -1,177 +1,177 @@ -getHeaders() as $name => $values) { - * echo $name . ": " . implode(", ", $values); - * } - * - * // Emit headers iteratively: - * foreach ($message->getHeaders() as $name => $values) { - * foreach ($values as $value) { - * header(sprintf('%s: %s', $name, $value), false); - * } - * } - * - * While header names are not case-sensitive, getHeaders() will preserve the - * exact case in which headers were originally specified. - * - * @return string[][] Returns an associative array of the message's headers. Each - * key MUST be a header name, and each value MUST be an array of strings - * for that header. - */ - public function getHeaders(); - /** - * Checks if a header exists by the given case-insensitive name. - * - * @param string $name Case-insensitive header field name. - * @return bool Returns true if any header names match the given header - * name using a case-insensitive string comparison. Returns false if - * no matching header name is found in the message. - */ - public function hasHeader($name); - /** - * Retrieves a message header value by the given case-insensitive name. - * - * This method returns an array of all the header values of the given - * case-insensitive header name. - * - * If the header does not appear in the message, this method MUST return an - * empty array. - * - * @param string $name Case-insensitive header field name. - * @return string[] An array of string values as provided for the given - * header. If the header does not appear in the message, this method MUST - * return an empty array. - */ - public function getHeader($name); - /** - * Retrieves a comma-separated string of the values for a single header. - * - * This method returns all of the header values of the given - * case-insensitive header name as a string concatenated together using - * a comma. - * - * NOTE: Not all header values may be appropriately represented using - * comma concatenation. For such headers, use getHeader() instead - * and supply your own delimiter when concatenating. - * - * If the header does not appear in the message, this method MUST return - * an empty string. - * - * @param string $name Case-insensitive header field name. - * @return string A string of values as provided for the given header - * concatenated together using a comma. If the header does not appear in - * the message, this method MUST return an empty string. - */ - public function getHeaderLine($name); - /** - * Return an instance with the provided value replacing the specified header. - * - * While header names are case-insensitive, the casing of the header will - * be preserved by this function, and returned from getHeaders(). - * - * This method MUST be implemented in such a way as to retain the - * immutability of the message, and MUST return an instance that has the - * new and/or updated header and value. - * - * @param string $name Case-insensitive header field name. - * @param string|string[] $value Header value(s). - * @return static - * @throws \InvalidArgumentException for invalid header names or values. - */ - public function withHeader($name, $value); - /** - * Return an instance with the specified header appended with the given value. - * - * Existing values for the specified header will be maintained. The new - * value(s) will be appended to the existing list. If the header did not - * exist previously, it will be added. - * - * This method MUST be implemented in such a way as to retain the - * immutability of the message, and MUST return an instance that has the - * new header and/or value. - * - * @param string $name Case-insensitive header field name to add. - * @param string|string[] $value Header value(s). - * @return static - * @throws \InvalidArgumentException for invalid header names or values. - */ - public function withAddedHeader($name, $value); - /** - * Return an instance without the specified header. - * - * Header resolution MUST be done without case-sensitivity. - * - * This method MUST be implemented in such a way as to retain the - * immutability of the message, and MUST return an instance that removes - * the named header. - * - * @param string $name Case-insensitive header field name to remove. - * @return static - */ - public function withoutHeader($name); - /** - * Gets the body of the message. - * - * @return StreamInterface Returns the body as a stream. - */ - public function getBody(); - /** - * Return an instance with the specified message body. - * - * The body MUST be a StreamInterface object. - * - * This method MUST be implemented in such a way as to retain the - * immutability of the message, and MUST return a new instance that has the - * new body stream. - * - * @param StreamInterface $body Body. - * @return static - * @throws \InvalidArgumentException When the body is not valid. - */ - public function withBody(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $body); -} +getHeaders() as $name => $values) { + * echo $name . ": " . implode(", ", $values); + * } + * + * // Emit headers iteratively: + * foreach ($message->getHeaders() as $name => $values) { + * foreach ($values as $value) { + * header(sprintf('%s: %s', $name, $value), false); + * } + * } + * + * While header names are not case-sensitive, getHeaders() will preserve the + * exact case in which headers were originally specified. + * + * @return string[][] Returns an associative array of the message's headers. Each + * key MUST be a header name, and each value MUST be an array of strings + * for that header. + */ + public function getHeaders(); + /** + * Checks if a header exists by the given case-insensitive name. + * + * @param string $name Case-insensitive header field name. + * @return bool Returns true if any header names match the given header + * name using a case-insensitive string comparison. Returns false if + * no matching header name is found in the message. + */ + public function hasHeader($name); + /** + * Retrieves a message header value by the given case-insensitive name. + * + * This method returns an array of all the header values of the given + * case-insensitive header name. + * + * If the header does not appear in the message, this method MUST return an + * empty array. + * + * @param string $name Case-insensitive header field name. + * @return string[] An array of string values as provided for the given + * header. If the header does not appear in the message, this method MUST + * return an empty array. + */ + public function getHeader($name); + /** + * Retrieves a comma-separated string of the values for a single header. + * + * This method returns all of the header values of the given + * case-insensitive header name as a string concatenated together using + * a comma. + * + * NOTE: Not all header values may be appropriately represented using + * comma concatenation. For such headers, use getHeader() instead + * and supply your own delimiter when concatenating. + * + * If the header does not appear in the message, this method MUST return + * an empty string. + * + * @param string $name Case-insensitive header field name. + * @return string A string of values as provided for the given header + * concatenated together using a comma. If the header does not appear in + * the message, this method MUST return an empty string. + */ + public function getHeaderLine($name); + /** + * Return an instance with the provided value replacing the specified header. + * + * While header names are case-insensitive, the casing of the header will + * be preserved by this function, and returned from getHeaders(). + * + * This method MUST be implemented in such a way as to retain the + * immutability of the message, and MUST return an instance that has the + * new and/or updated header and value. + * + * @param string $name Case-insensitive header field name. + * @param string|string[] $value Header value(s). + * @return static + * @throws \InvalidArgumentException for invalid header names or values. + */ + public function withHeader($name, $value); + /** + * Return an instance with the specified header appended with the given value. + * + * Existing values for the specified header will be maintained. The new + * value(s) will be appended to the existing list. If the header did not + * exist previously, it will be added. + * + * This method MUST be implemented in such a way as to retain the + * immutability of the message, and MUST return an instance that has the + * new header and/or value. + * + * @param string $name Case-insensitive header field name to add. + * @param string|string[] $value Header value(s). + * @return static + * @throws \InvalidArgumentException for invalid header names or values. + */ + public function withAddedHeader($name, $value); + /** + * Return an instance without the specified header. + * + * Header resolution MUST be done without case-sensitivity. + * + * This method MUST be implemented in such a way as to retain the + * immutability of the message, and MUST return an instance that removes + * the named header. + * + * @param string $name Case-insensitive header field name to remove. + * @return static + */ + public function withoutHeader($name); + /** + * Gets the body of the message. + * + * @return StreamInterface Returns the body as a stream. + */ + public function getBody(); + /** + * Return an instance with the specified message body. + * + * The body MUST be a StreamInterface object. + * + * This method MUST be implemented in such a way as to retain the + * immutability of the message, and MUST return a new instance that has the + * new body stream. + * + * @param StreamInterface $body Body. + * @return static + * @throws \InvalidArgumentException When the body is not valid. + */ + public function withBody(\_PhpScoper5ea00cc67502b\Psr\Http\Message\StreamInterface $body); +} diff --git a/vendor/psr/http-message/src/RequestInterface.php b/vendor/psr/http-message/src/RequestInterface.php index b33ba6140..270879357 100644 --- a/vendor/psr/http-message/src/RequestInterface.php +++ b/vendor/psr/http-message/src/RequestInterface.php @@ -1,124 +1,124 @@ -getQuery()` - * or from the `QUERY_STRING` server param. - * - * @return array - */ - public function getQueryParams(); - /** - * Return an instance with the specified query string arguments. - * - * These values SHOULD remain immutable over the course of the incoming - * request. They MAY be injected during instantiation, such as from PHP's - * $_GET superglobal, or MAY be derived from some other value such as the - * URI. In cases where the arguments are parsed from the URI, the data - * MUST be compatible with what PHP's parse_str() would return for - * purposes of how duplicate query parameters are handled, and how nested - * sets are handled. - * - * Setting query string arguments MUST NOT change the URI stored by the - * request, nor the values in the server params. - * - * This method MUST be implemented in such a way as to retain the - * immutability of the message, and MUST return an instance that has the - * updated query string arguments. - * - * @param array $query Array of query string arguments, typically from - * $_GET. - * @return static - */ - public function withQueryParams(array $query); - /** - * Retrieve normalized file upload data. - * - * This method returns upload metadata in a normalized tree, with each leaf - * an instance of Psr\Http\Message\UploadedFileInterface. - * - * These values MAY be prepared from $_FILES or the message body during - * instantiation, or MAY be injected via withUploadedFiles(). - * - * @return array An array tree of UploadedFileInterface instances; an empty - * array MUST be returned if no data is present. - */ - public function getUploadedFiles(); - /** - * Create a new instance with the specified uploaded files. - * - * This method MUST be implemented in such a way as to retain the - * immutability of the message, and MUST return an instance that has the - * updated body parameters. - * - * @param array $uploadedFiles An array tree of UploadedFileInterface instances. - * @return static - * @throws \InvalidArgumentException if an invalid structure is provided. - */ - public function withUploadedFiles(array $uploadedFiles); - /** - * Retrieve any parameters provided in the request body. - * - * If the request Content-Type is either application/x-www-form-urlencoded - * or multipart/form-data, and the request method is POST, this method MUST - * return the contents of $_POST. - * - * Otherwise, this method may return any results of deserializing - * the request body content; as parsing returns structured content, the - * potential types MUST be arrays or objects only. A null value indicates - * the absence of body content. - * - * @return null|array|object The deserialized body parameters, if any. - * These will typically be an array or object. - */ - public function getParsedBody(); - /** - * Return an instance with the specified body parameters. - * - * These MAY be injected during instantiation. - * - * If the request Content-Type is either application/x-www-form-urlencoded - * or multipart/form-data, and the request method is POST, use this method - * ONLY to inject the contents of $_POST. - * - * The data IS NOT REQUIRED to come from $_POST, but MUST be the results of - * deserializing the request body content. Deserialization/parsing returns - * structured data, and, as such, this method ONLY accepts arrays or objects, - * or a null value if nothing was available to parse. - * - * As an example, if content negotiation determines that the request data - * is a JSON payload, this method could be used to create a request - * instance with the deserialized parameters. - * - * This method MUST be implemented in such a way as to retain the - * immutability of the message, and MUST return an instance that has the - * updated body parameters. - * - * @param null|array|object $data The deserialized body data. This will - * typically be in an array or object. - * @return static - * @throws \InvalidArgumentException if an unsupported argument type is - * provided. - */ - public function withParsedBody($data); - /** - * Retrieve attributes derived from the request. - * - * The request "attributes" may be used to allow injection of any - * parameters derived from the request: e.g., the results of path - * match operations; the results of decrypting cookies; the results of - * deserializing non-form-encoded message bodies; etc. Attributes - * will be application and request specific, and CAN be mutable. - * - * @return array Attributes derived from the request. - */ - public function getAttributes(); - /** - * Retrieve a single derived request attribute. - * - * Retrieves a single derived request attribute as described in - * getAttributes(). If the attribute has not been previously set, returns - * the default value as provided. - * - * This method obviates the need for a hasAttribute() method, as it allows - * specifying a default value to return if the attribute is not found. - * - * @see getAttributes() - * @param string $name The attribute name. - * @param mixed $default Default value to return if the attribute does not exist. - * @return mixed - */ - public function getAttribute($name, $default = null); - /** - * Return an instance with the specified derived request attribute. - * - * This method allows setting a single derived request attribute as - * described in getAttributes(). - * - * This method MUST be implemented in such a way as to retain the - * immutability of the message, and MUST return an instance that has the - * updated attribute. - * - * @see getAttributes() - * @param string $name The attribute name. - * @param mixed $value The value of the attribute. - * @return static - */ - public function withAttribute($name, $value); - /** - * Return an instance that removes the specified derived request attribute. - * - * This method allows removing a single derived request attribute as - * described in getAttributes(). - * - * This method MUST be implemented in such a way as to retain the - * immutability of the message, and MUST return an instance that removes - * the attribute. - * - * @see getAttributes() - * @param string $name The attribute name. - * @return static - */ - public function withoutAttribute($name); -} +getQuery()` + * or from the `QUERY_STRING` server param. + * + * @return array + */ + public function getQueryParams(); + /** + * Return an instance with the specified query string arguments. + * + * These values SHOULD remain immutable over the course of the incoming + * request. They MAY be injected during instantiation, such as from PHP's + * $_GET superglobal, or MAY be derived from some other value such as the + * URI. In cases where the arguments are parsed from the URI, the data + * MUST be compatible with what PHP's parse_str() would return for + * purposes of how duplicate query parameters are handled, and how nested + * sets are handled. + * + * Setting query string arguments MUST NOT change the URI stored by the + * request, nor the values in the server params. + * + * This method MUST be implemented in such a way as to retain the + * immutability of the message, and MUST return an instance that has the + * updated query string arguments. + * + * @param array $query Array of query string arguments, typically from + * $_GET. + * @return static + */ + public function withQueryParams(array $query); + /** + * Retrieve normalized file upload data. + * + * This method returns upload metadata in a normalized tree, with each leaf + * an instance of Psr\Http\Message\UploadedFileInterface. + * + * These values MAY be prepared from $_FILES or the message body during + * instantiation, or MAY be injected via withUploadedFiles(). + * + * @return array An array tree of UploadedFileInterface instances; an empty + * array MUST be returned if no data is present. + */ + public function getUploadedFiles(); + /** + * Create a new instance with the specified uploaded files. + * + * This method MUST be implemented in such a way as to retain the + * immutability of the message, and MUST return an instance that has the + * updated body parameters. + * + * @param array $uploadedFiles An array tree of UploadedFileInterface instances. + * @return static + * @throws \InvalidArgumentException if an invalid structure is provided. + */ + public function withUploadedFiles(array $uploadedFiles); + /** + * Retrieve any parameters provided in the request body. + * + * If the request Content-Type is either application/x-www-form-urlencoded + * or multipart/form-data, and the request method is POST, this method MUST + * return the contents of $_POST. + * + * Otherwise, this method may return any results of deserializing + * the request body content; as parsing returns structured content, the + * potential types MUST be arrays or objects only. A null value indicates + * the absence of body content. + * + * @return null|array|object The deserialized body parameters, if any. + * These will typically be an array or object. + */ + public function getParsedBody(); + /** + * Return an instance with the specified body parameters. + * + * These MAY be injected during instantiation. + * + * If the request Content-Type is either application/x-www-form-urlencoded + * or multipart/form-data, and the request method is POST, use this method + * ONLY to inject the contents of $_POST. + * + * The data IS NOT REQUIRED to come from $_POST, but MUST be the results of + * deserializing the request body content. Deserialization/parsing returns + * structured data, and, as such, this method ONLY accepts arrays or objects, + * or a null value if nothing was available to parse. + * + * As an example, if content negotiation determines that the request data + * is a JSON payload, this method could be used to create a request + * instance with the deserialized parameters. + * + * This method MUST be implemented in such a way as to retain the + * immutability of the message, and MUST return an instance that has the + * updated body parameters. + * + * @param null|array|object $data The deserialized body data. This will + * typically be in an array or object. + * @return static + * @throws \InvalidArgumentException if an unsupported argument type is + * provided. + */ + public function withParsedBody($data); + /** + * Retrieve attributes derived from the request. + * + * The request "attributes" may be used to allow injection of any + * parameters derived from the request: e.g., the results of path + * match operations; the results of decrypting cookies; the results of + * deserializing non-form-encoded message bodies; etc. Attributes + * will be application and request specific, and CAN be mutable. + * + * @return array Attributes derived from the request. + */ + public function getAttributes(); + /** + * Retrieve a single derived request attribute. + * + * Retrieves a single derived request attribute as described in + * getAttributes(). If the attribute has not been previously set, returns + * the default value as provided. + * + * This method obviates the need for a hasAttribute() method, as it allows + * specifying a default value to return if the attribute is not found. + * + * @see getAttributes() + * @param string $name The attribute name. + * @param mixed $default Default value to return if the attribute does not exist. + * @return mixed + */ + public function getAttribute($name, $default = null); + /** + * Return an instance with the specified derived request attribute. + * + * This method allows setting a single derived request attribute as + * described in getAttributes(). + * + * This method MUST be implemented in such a way as to retain the + * immutability of the message, and MUST return an instance that has the + * updated attribute. + * + * @see getAttributes() + * @param string $name The attribute name. + * @param mixed $value The value of the attribute. + * @return static + */ + public function withAttribute($name, $value); + /** + * Return an instance that removes the specified derived request attribute. + * + * This method allows removing a single derived request attribute as + * described in getAttributes(). + * + * This method MUST be implemented in such a way as to retain the + * immutability of the message, and MUST return an instance that removes + * the attribute. + * + * @see getAttributes() + * @param string $name The attribute name. + * @return static + */ + public function withoutAttribute($name); +} diff --git a/vendor/psr/http-message/src/StreamInterface.php b/vendor/psr/http-message/src/StreamInterface.php index 28a5034d9..a3d369886 100644 --- a/vendor/psr/http-message/src/StreamInterface.php +++ b/vendor/psr/http-message/src/StreamInterface.php @@ -1,144 +1,144 @@ - - * [user-info@]host[:port] - * - * - * If the port component is not set or is the standard port for the current - * scheme, it SHOULD NOT be included. - * - * @see https://tools.ietf.org/html/rfc3986#section-3.2 - * @return string The URI authority, in "[user-info@]host[:port]" format. - */ - public function getAuthority(); - /** - * Retrieve the user information component of the URI. - * - * If no user information is present, this method MUST return an empty - * string. - * - * If a user is present in the URI, this will return that value; - * additionally, if the password is also present, it will be appended to the - * user value, with a colon (":") separating the values. - * - * The trailing "@" character is not part of the user information and MUST - * NOT be added. - * - * @return string The URI user information, in "username[:password]" format. - */ - public function getUserInfo(); - /** - * Retrieve the host component of the URI. - * - * If no host is present, this method MUST return an empty string. - * - * The value returned MUST be normalized to lowercase, per RFC 3986 - * Section 3.2.2. - * - * @see http://tools.ietf.org/html/rfc3986#section-3.2.2 - * @return string The URI host. - */ - public function getHost(); - /** - * Retrieve the port component of the URI. - * - * If a port is present, and it is non-standard for the current scheme, - * this method MUST return it as an integer. If the port is the standard port - * used with the current scheme, this method SHOULD return null. - * - * If no port is present, and no scheme is present, this method MUST return - * a null value. - * - * If no port is present, but a scheme is present, this method MAY return - * the standard port for that scheme, but SHOULD return null. - * - * @return null|int The URI port. - */ - public function getPort(); - /** - * Retrieve the path component of the URI. - * - * The path can either be empty or absolute (starting with a slash) or - * rootless (not starting with a slash). Implementations MUST support all - * three syntaxes. - * - * Normally, the empty path "" and absolute path "/" are considered equal as - * defined in RFC 7230 Section 2.7.3. But this method MUST NOT automatically - * do this normalization because in contexts with a trimmed base path, e.g. - * the front controller, this difference becomes significant. It's the task - * of the user to handle both "" and "/". - * - * The value returned MUST be percent-encoded, but MUST NOT double-encode - * any characters. To determine what characters to encode, please refer to - * RFC 3986, Sections 2 and 3.3. - * - * As an example, if the value should include a slash ("/") not intended as - * delimiter between path segments, that value MUST be passed in encoded - * form (e.g., "%2F") to the instance. - * - * @see https://tools.ietf.org/html/rfc3986#section-2 - * @see https://tools.ietf.org/html/rfc3986#section-3.3 - * @return string The URI path. - */ - public function getPath(); - /** - * Retrieve the query string of the URI. - * - * If no query string is present, this method MUST return an empty string. - * - * The leading "?" character is not part of the query and MUST NOT be - * added. - * - * The value returned MUST be percent-encoded, but MUST NOT double-encode - * any characters. To determine what characters to encode, please refer to - * RFC 3986, Sections 2 and 3.4. - * - * As an example, if a value in a key/value pair of the query string should - * include an ampersand ("&") not intended as a delimiter between values, - * that value MUST be passed in encoded form (e.g., "%26") to the instance. - * - * @see https://tools.ietf.org/html/rfc3986#section-2 - * @see https://tools.ietf.org/html/rfc3986#section-3.4 - * @return string The URI query string. - */ - public function getQuery(); - /** - * Retrieve the fragment component of the URI. - * - * If no fragment is present, this method MUST return an empty string. - * - * The leading "#" character is not part of the fragment and MUST NOT be - * added. - * - * The value returned MUST be percent-encoded, but MUST NOT double-encode - * any characters. To determine what characters to encode, please refer to - * RFC 3986, Sections 2 and 3.5. - * - * @see https://tools.ietf.org/html/rfc3986#section-2 - * @see https://tools.ietf.org/html/rfc3986#section-3.5 - * @return string The URI fragment. - */ - public function getFragment(); - /** - * Return an instance with the specified scheme. - * - * This method MUST retain the state of the current instance, and return - * an instance that contains the specified scheme. - * - * Implementations MUST support the schemes "http" and "https" case - * insensitively, and MAY accommodate other schemes if required. - * - * An empty scheme is equivalent to removing the scheme. - * - * @param string $scheme The scheme to use with the new instance. - * @return static A new instance with the specified scheme. - * @throws \InvalidArgumentException for invalid or unsupported schemes. - */ - public function withScheme($scheme); - /** - * Return an instance with the specified user information. - * - * This method MUST retain the state of the current instance, and return - * an instance that contains the specified user information. - * - * Password is optional, but the user information MUST include the - * user; an empty string for the user is equivalent to removing user - * information. - * - * @param string $user The user name to use for authority. - * @param null|string $password The password associated with $user. - * @return static A new instance with the specified user information. - */ - public function withUserInfo($user, $password = null); - /** - * Return an instance with the specified host. - * - * This method MUST retain the state of the current instance, and return - * an instance that contains the specified host. - * - * An empty host value is equivalent to removing the host. - * - * @param string $host The hostname to use with the new instance. - * @return static A new instance with the specified host. - * @throws \InvalidArgumentException for invalid hostnames. - */ - public function withHost($host); - /** - * Return an instance with the specified port. - * - * This method MUST retain the state of the current instance, and return - * an instance that contains the specified port. - * - * Implementations MUST raise an exception for ports outside the - * established TCP and UDP port ranges. - * - * A null value provided for the port is equivalent to removing the port - * information. - * - * @param null|int $port The port to use with the new instance; a null value - * removes the port information. - * @return static A new instance with the specified port. - * @throws \InvalidArgumentException for invalid ports. - */ - public function withPort($port); - /** - * Return an instance with the specified path. - * - * This method MUST retain the state of the current instance, and return - * an instance that contains the specified path. - * - * The path can either be empty or absolute (starting with a slash) or - * rootless (not starting with a slash). Implementations MUST support all - * three syntaxes. - * - * If the path is intended to be domain-relative rather than path relative then - * it must begin with a slash ("/"). Paths not starting with a slash ("/") - * are assumed to be relative to some base path known to the application or - * consumer. - * - * Users can provide both encoded and decoded path characters. - * Implementations ensure the correct encoding as outlined in getPath(). - * - * @param string $path The path to use with the new instance. - * @return static A new instance with the specified path. - * @throws \InvalidArgumentException for invalid paths. - */ - public function withPath($path); - /** - * Return an instance with the specified query string. - * - * This method MUST retain the state of the current instance, and return - * an instance that contains the specified query string. - * - * Users can provide both encoded and decoded query characters. - * Implementations ensure the correct encoding as outlined in getQuery(). - * - * An empty query string value is equivalent to removing the query string. - * - * @param string $query The query string to use with the new instance. - * @return static A new instance with the specified query string. - * @throws \InvalidArgumentException for invalid query strings. - */ - public function withQuery($query); - /** - * Return an instance with the specified URI fragment. - * - * This method MUST retain the state of the current instance, and return - * an instance that contains the specified URI fragment. - * - * Users can provide both encoded and decoded fragment characters. - * Implementations ensure the correct encoding as outlined in getFragment(). - * - * An empty fragment value is equivalent to removing the fragment. - * - * @param string $fragment The fragment to use with the new instance. - * @return static A new instance with the specified fragment. - */ - public function withFragment($fragment); - /** - * Return the string representation as a URI reference. - * - * Depending on which components of the URI are present, the resulting - * string is either a full URI or relative reference according to RFC 3986, - * Section 4.1. The method concatenates the various components of the URI, - * using the appropriate delimiters: - * - * - If a scheme is present, it MUST be suffixed by ":". - * - If an authority is present, it MUST be prefixed by "//". - * - The path can be concatenated without delimiters. But there are two - * cases where the path has to be adjusted to make the URI reference - * valid as PHP does not allow to throw an exception in __toString(): - * - If the path is rootless and an authority is present, the path MUST - * be prefixed by "/". - * - If the path is starting with more than one "/" and no authority is - * present, the starting slashes MUST be reduced to one. - * - If a query is present, it MUST be prefixed by "?". - * - If a fragment is present, it MUST be prefixed by "#". - * - * @see http://tools.ietf.org/html/rfc3986#section-4.1 - * @return string - */ - public function __toString(); -} + + * [user-info@]host[:port] + * + * + * If the port component is not set or is the standard port for the current + * scheme, it SHOULD NOT be included. + * + * @see https://tools.ietf.org/html/rfc3986#section-3.2 + * @return string The URI authority, in "[user-info@]host[:port]" format. + */ + public function getAuthority(); + /** + * Retrieve the user information component of the URI. + * + * If no user information is present, this method MUST return an empty + * string. + * + * If a user is present in the URI, this will return that value; + * additionally, if the password is also present, it will be appended to the + * user value, with a colon (":") separating the values. + * + * The trailing "@" character is not part of the user information and MUST + * NOT be added. + * + * @return string The URI user information, in "username[:password]" format. + */ + public function getUserInfo(); + /** + * Retrieve the host component of the URI. + * + * If no host is present, this method MUST return an empty string. + * + * The value returned MUST be normalized to lowercase, per RFC 3986 + * Section 3.2.2. + * + * @see http://tools.ietf.org/html/rfc3986#section-3.2.2 + * @return string The URI host. + */ + public function getHost(); + /** + * Retrieve the port component of the URI. + * + * If a port is present, and it is non-standard for the current scheme, + * this method MUST return it as an integer. If the port is the standard port + * used with the current scheme, this method SHOULD return null. + * + * If no port is present, and no scheme is present, this method MUST return + * a null value. + * + * If no port is present, but a scheme is present, this method MAY return + * the standard port for that scheme, but SHOULD return null. + * + * @return null|int The URI port. + */ + public function getPort(); + /** + * Retrieve the path component of the URI. + * + * The path can either be empty or absolute (starting with a slash) or + * rootless (not starting with a slash). Implementations MUST support all + * three syntaxes. + * + * Normally, the empty path "" and absolute path "/" are considered equal as + * defined in RFC 7230 Section 2.7.3. But this method MUST NOT automatically + * do this normalization because in contexts with a trimmed base path, e.g. + * the front controller, this difference becomes significant. It's the task + * of the user to handle both "" and "/". + * + * The value returned MUST be percent-encoded, but MUST NOT double-encode + * any characters. To determine what characters to encode, please refer to + * RFC 3986, Sections 2 and 3.3. + * + * As an example, if the value should include a slash ("/") not intended as + * delimiter between path segments, that value MUST be passed in encoded + * form (e.g., "%2F") to the instance. + * + * @see https://tools.ietf.org/html/rfc3986#section-2 + * @see https://tools.ietf.org/html/rfc3986#section-3.3 + * @return string The URI path. + */ + public function getPath(); + /** + * Retrieve the query string of the URI. + * + * If no query string is present, this method MUST return an empty string. + * + * The leading "?" character is not part of the query and MUST NOT be + * added. + * + * The value returned MUST be percent-encoded, but MUST NOT double-encode + * any characters. To determine what characters to encode, please refer to + * RFC 3986, Sections 2 and 3.4. + * + * As an example, if a value in a key/value pair of the query string should + * include an ampersand ("&") not intended as a delimiter between values, + * that value MUST be passed in encoded form (e.g., "%26") to the instance. + * + * @see https://tools.ietf.org/html/rfc3986#section-2 + * @see https://tools.ietf.org/html/rfc3986#section-3.4 + * @return string The URI query string. + */ + public function getQuery(); + /** + * Retrieve the fragment component of the URI. + * + * If no fragment is present, this method MUST return an empty string. + * + * The leading "#" character is not part of the fragment and MUST NOT be + * added. + * + * The value returned MUST be percent-encoded, but MUST NOT double-encode + * any characters. To determine what characters to encode, please refer to + * RFC 3986, Sections 2 and 3.5. + * + * @see https://tools.ietf.org/html/rfc3986#section-2 + * @see https://tools.ietf.org/html/rfc3986#section-3.5 + * @return string The URI fragment. + */ + public function getFragment(); + /** + * Return an instance with the specified scheme. + * + * This method MUST retain the state of the current instance, and return + * an instance that contains the specified scheme. + * + * Implementations MUST support the schemes "http" and "https" case + * insensitively, and MAY accommodate other schemes if required. + * + * An empty scheme is equivalent to removing the scheme. + * + * @param string $scheme The scheme to use with the new instance. + * @return static A new instance with the specified scheme. + * @throws \InvalidArgumentException for invalid or unsupported schemes. + */ + public function withScheme($scheme); + /** + * Return an instance with the specified user information. + * + * This method MUST retain the state of the current instance, and return + * an instance that contains the specified user information. + * + * Password is optional, but the user information MUST include the + * user; an empty string for the user is equivalent to removing user + * information. + * + * @param string $user The user name to use for authority. + * @param null|string $password The password associated with $user. + * @return static A new instance with the specified user information. + */ + public function withUserInfo($user, $password = null); + /** + * Return an instance with the specified host. + * + * This method MUST retain the state of the current instance, and return + * an instance that contains the specified host. + * + * An empty host value is equivalent to removing the host. + * + * @param string $host The hostname to use with the new instance. + * @return static A new instance with the specified host. + * @throws \InvalidArgumentException for invalid hostnames. + */ + public function withHost($host); + /** + * Return an instance with the specified port. + * + * This method MUST retain the state of the current instance, and return + * an instance that contains the specified port. + * + * Implementations MUST raise an exception for ports outside the + * established TCP and UDP port ranges. + * + * A null value provided for the port is equivalent to removing the port + * information. + * + * @param null|int $port The port to use with the new instance; a null value + * removes the port information. + * @return static A new instance with the specified port. + * @throws \InvalidArgumentException for invalid ports. + */ + public function withPort($port); + /** + * Return an instance with the specified path. + * + * This method MUST retain the state of the current instance, and return + * an instance that contains the specified path. + * + * The path can either be empty or absolute (starting with a slash) or + * rootless (not starting with a slash). Implementations MUST support all + * three syntaxes. + * + * If the path is intended to be domain-relative rather than path relative then + * it must begin with a slash ("/"). Paths not starting with a slash ("/") + * are assumed to be relative to some base path known to the application or + * consumer. + * + * Users can provide both encoded and decoded path characters. + * Implementations ensure the correct encoding as outlined in getPath(). + * + * @param string $path The path to use with the new instance. + * @return static A new instance with the specified path. + * @throws \InvalidArgumentException for invalid paths. + */ + public function withPath($path); + /** + * Return an instance with the specified query string. + * + * This method MUST retain the state of the current instance, and return + * an instance that contains the specified query string. + * + * Users can provide both encoded and decoded query characters. + * Implementations ensure the correct encoding as outlined in getQuery(). + * + * An empty query string value is equivalent to removing the query string. + * + * @param string $query The query string to use with the new instance. + * @return static A new instance with the specified query string. + * @throws \InvalidArgumentException for invalid query strings. + */ + public function withQuery($query); + /** + * Return an instance with the specified URI fragment. + * + * This method MUST retain the state of the current instance, and return + * an instance that contains the specified URI fragment. + * + * Users can provide both encoded and decoded fragment characters. + * Implementations ensure the correct encoding as outlined in getFragment(). + * + * An empty fragment value is equivalent to removing the fragment. + * + * @param string $fragment The fragment to use with the new instance. + * @return static A new instance with the specified fragment. + */ + public function withFragment($fragment); + /** + * Return the string representation as a URI reference. + * + * Depending on which components of the URI are present, the resulting + * string is either a full URI or relative reference according to RFC 3986, + * Section 4.1. The method concatenates the various components of the URI, + * using the appropriate delimiters: + * + * - If a scheme is present, it MUST be suffixed by ":". + * - If an authority is present, it MUST be prefixed by "//". + * - The path can be concatenated without delimiters. But there are two + * cases where the path has to be adjusted to make the URI reference + * valid as PHP does not allow to throw an exception in __toString(): + * - If the path is rootless and an authority is present, the path MUST + * be prefixed by "/". + * - If the path is starting with more than one "/" and no authority is + * present, the starting slashes MUST be reduced to one. + * - If a query is present, it MUST be prefixed by "?". + * - If a fragment is present, it MUST be prefixed by "#". + * + * @see http://tools.ietf.org/html/rfc3986#section-4.1 + * @return string + */ + public function __toString(); +} diff --git a/vendor/psr/http-message/src/index.php b/vendor/psr/http-message/src/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/psr/http-message/src/index.php +++ b/vendor/psr/http-message/src/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/index.php b/vendor/psr/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/psr/index.php +++ b/vendor/psr/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/log/LICENSE b/vendor/psr/log/LICENSE index 474c952b4..8a71cf7ba 100644 --- a/vendor/psr/log/LICENSE +++ b/vendor/psr/log/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2012 PHP Framework Interoperability Group - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2012 PHP Framework Interoperability Group + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/psr/log/Psr/Log/AbstractLogger.php b/vendor/psr/log/Psr/Log/AbstractLogger.php index 7337524ac..0cb4c6722 100644 --- a/vendor/psr/log/Psr/Log/AbstractLogger.php +++ b/vendor/psr/log/Psr/Log/AbstractLogger.php @@ -1,121 +1,121 @@ -log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::EMERGENCY, $message, $context); - } - /** - * Action must be taken immediately. - * - * Example: Entire website down, database unavailable, etc. This should - * trigger the SMS alerts and wake you up. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function alert($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ALERT, $message, $context); - } - /** - * Critical conditions. - * - * Example: Application component unavailable, unexpected exception. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function critical($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::CRITICAL, $message, $context); - } - /** - * Runtime errors that do not require immediate action but should typically - * be logged and monitored. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function error($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ERROR, $message, $context); - } - /** - * Exceptional occurrences that are not errors. - * - * Example: Use of deprecated APIs, poor use of an API, undesirable things - * that are not necessarily wrong. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function warning($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::WARNING, $message, $context); - } - /** - * Normal but significant events. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function notice($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::NOTICE, $message, $context); - } - /** - * Interesting events. - * - * Example: User logs in, SQL logs. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function info($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::INFO, $message, $context); - } - /** - * Detailed debug information. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function debug($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::DEBUG, $message, $context); - } -} +log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::EMERGENCY, $message, $context); + } + /** + * Action must be taken immediately. + * + * Example: Entire website down, database unavailable, etc. This should + * trigger the SMS alerts and wake you up. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function alert($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ALERT, $message, $context); + } + /** + * Critical conditions. + * + * Example: Application component unavailable, unexpected exception. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function critical($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::CRITICAL, $message, $context); + } + /** + * Runtime errors that do not require immediate action but should typically + * be logged and monitored. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function error($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ERROR, $message, $context); + } + /** + * Exceptional occurrences that are not errors. + * + * Example: Use of deprecated APIs, poor use of an API, undesirable things + * that are not necessarily wrong. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function warning($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::WARNING, $message, $context); + } + /** + * Normal but significant events. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function notice($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::NOTICE, $message, $context); + } + /** + * Interesting events. + * + * Example: User logs in, SQL logs. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function info($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::INFO, $message, $context); + } + /** + * Detailed debug information. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function debug($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::DEBUG, $message, $context); + } +} diff --git a/vendor/psr/log/Psr/Log/InvalidArgumentException.php b/vendor/psr/log/Psr/Log/InvalidArgumentException.php index 8becf7b77..5db6cce10 100644 --- a/vendor/psr/log/Psr/Log/InvalidArgumentException.php +++ b/vendor/psr/log/Psr/Log/InvalidArgumentException.php @@ -1,7 +1,7 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -namespace _PhpScoper5ea00cc67502b\Psr\Log; - -/** - * Describes a logger-aware instance. - */ -interface LoggerAwareInterface -{ - /** - * Sets a logger instance on the object. - * - * @param LoggerInterface $logger - * - * @return void - */ - public function setLogger(\_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger); -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +namespace _PhpScoper5ea00cc67502b\Psr\Log; + +/** + * Describes a logger-aware instance. + */ +interface LoggerAwareInterface +{ + /** + * Sets a logger instance on the object. + * + * @param LoggerInterface $logger + * + * @return void + */ + public function setLogger(\_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger); +} diff --git a/vendor/psr/log/Psr/Log/LoggerAwareTrait.php b/vendor/psr/log/Psr/Log/LoggerAwareTrait.php index 9443cab7b..a24f18a86 100644 --- a/vendor/psr/log/Psr/Log/LoggerAwareTrait.php +++ b/vendor/psr/log/Psr/Log/LoggerAwareTrait.php @@ -1,58 +1,58 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -namespace _PhpScoper5ea00cc67502b\Psr\Log; - -/** - * Basic Implementation of LoggerAwareInterface. - */ -trait LoggerAwareTrait -{ - /** - * The logger instance. - * - * @var LoggerInterface - */ - protected $logger; - /** - * Sets a logger. - * - * @param LoggerInterface $logger - */ - public function setLogger(\_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger) - { - $this->logger = $logger; - } -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +namespace _PhpScoper5ea00cc67502b\Psr\Log; + +/** + * Basic Implementation of LoggerAwareInterface. + */ +trait LoggerAwareTrait +{ + /** + * The logger instance. + * + * @var LoggerInterface + */ + protected $logger; + /** + * Sets a logger. + * + * @param LoggerInterface $logger + */ + public function setLogger(\_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger) + { + $this->logger = $logger; + } +} diff --git a/vendor/psr/log/Psr/Log/LoggerInterface.php b/vendor/psr/log/Psr/Log/LoggerInterface.php index a2ba8bd59..faaceeda0 100644 --- a/vendor/psr/log/Psr/Log/LoggerInterface.php +++ b/vendor/psr/log/Psr/Log/LoggerInterface.php @@ -1,117 +1,117 @@ -log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::EMERGENCY, $message, $context); - } - /** - * Action must be taken immediately. - * - * Example: Entire website down, database unavailable, etc. This should - * trigger the SMS alerts and wake you up. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function alert($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ALERT, $message, $context); - } - /** - * Critical conditions. - * - * Example: Application component unavailable, unexpected exception. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function critical($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::CRITICAL, $message, $context); - } - /** - * Runtime errors that do not require immediate action but should typically - * be logged and monitored. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function error($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ERROR, $message, $context); - } - /** - * Exceptional occurrences that are not errors. - * - * Example: Use of deprecated APIs, poor use of an API, undesirable things - * that are not necessarily wrong. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function warning($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::WARNING, $message, $context); - } - /** - * Normal but significant events. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function notice($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::NOTICE, $message, $context); - } - /** - * Interesting events. - * - * Example: User logs in, SQL logs. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function info($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::INFO, $message, $context); - } - /** - * Detailed debug information. - * - * @param string $message - * @param array $context - * - * @return void - */ - public function debug($message, array $context = array()) - { - $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::DEBUG, $message, $context); - } - /** - * Logs with an arbitrary level. - * - * @param mixed $level - * @param string $message - * @param array $context - * - * @return void - * - * @throws \Psr\Log\InvalidArgumentException - */ - public abstract function log($level, $message, array $context = array()); -} +log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::EMERGENCY, $message, $context); + } + /** + * Action must be taken immediately. + * + * Example: Entire website down, database unavailable, etc. This should + * trigger the SMS alerts and wake you up. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function alert($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ALERT, $message, $context); + } + /** + * Critical conditions. + * + * Example: Application component unavailable, unexpected exception. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function critical($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::CRITICAL, $message, $context); + } + /** + * Runtime errors that do not require immediate action but should typically + * be logged and monitored. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function error($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ERROR, $message, $context); + } + /** + * Exceptional occurrences that are not errors. + * + * Example: Use of deprecated APIs, poor use of an API, undesirable things + * that are not necessarily wrong. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function warning($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::WARNING, $message, $context); + } + /** + * Normal but significant events. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function notice($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::NOTICE, $message, $context); + } + /** + * Interesting events. + * + * Example: User logs in, SQL logs. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function info($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::INFO, $message, $context); + } + /** + * Detailed debug information. + * + * @param string $message + * @param array $context + * + * @return void + */ + public function debug($message, array $context = array()) + { + $this->log(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::DEBUG, $message, $context); + } + /** + * Logs with an arbitrary level. + * + * @param mixed $level + * @param string $message + * @param array $context + * + * @return void + * + * @throws \Psr\Log\InvalidArgumentException + */ + public abstract function log($level, $message, array $context = array()); +} diff --git a/vendor/psr/log/Psr/Log/NullLogger.php b/vendor/psr/log/Psr/Log/NullLogger.php index 5dc395cd4..eba4d20dc 100644 --- a/vendor/psr/log/Psr/Log/NullLogger.php +++ b/vendor/psr/log/Psr/Log/NullLogger.php @@ -1,30 +1,30 @@ -logger) { }` - * blocks. - */ -class NullLogger extends \_PhpScoper5ea00cc67502b\Psr\Log\AbstractLogger -{ - /** - * Logs with an arbitrary level. - * - * @param mixed $level - * @param string $message - * @param array $context - * - * @return void - * - * @throws \Psr\Log\InvalidArgumentException - */ - public function log($level, $message, array $context = array()) - { - // noop - } -} +logger) { }` + * blocks. + */ +class NullLogger extends \_PhpScoper5ea00cc67502b\Psr\Log\AbstractLogger +{ + /** + * Logs with an arbitrary level. + * + * @param mixed $level + * @param string $message + * @param array $context + * + * @return void + * + * @throws \Psr\Log\InvalidArgumentException + */ + public function log($level, $message, array $context = array()) + { + // noop + } +} diff --git a/vendor/psr/log/Psr/Log/Test/DummyTest.php b/vendor/psr/log/Psr/Log/Test/DummyTest.php index 9e24c26ad..a29496d2b 100644 --- a/vendor/psr/log/Psr/Log/Test/DummyTest.php +++ b/vendor/psr/log/Psr/Log/Test/DummyTest.php @@ -1,18 +1,18 @@ - ". - * - * Example ->error('Foo') would yield "error Foo". - * - * @return string[] - */ - public abstract function getLogs(); - public function testImplements() - { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerInterface', $this->getLogger()); - } - /** - * @dataProvider provideLevelsAndMessages - */ - public function testLogsAtAllLevels($level, $message) - { - $logger = $this->getLogger(); - $logger->{$level}($message, array('user' => 'Bob')); - $logger->log($level, $message, array('user' => 'Bob')); - $expected = array($level . ' message of level ' . $level . ' with context: Bob', $level . ' message of level ' . $level . ' with context: Bob'); - $this->assertEquals($expected, $this->getLogs()); - } - public function provideLevelsAndMessages() - { - return array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::EMERGENCY => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::EMERGENCY, 'message of level emergency with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ALERT => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ALERT, 'message of level alert with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::CRITICAL => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::CRITICAL, 'message of level critical with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ERROR => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ERROR, 'message of level error with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::WARNING => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::WARNING, 'message of level warning with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::NOTICE => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::NOTICE, 'message of level notice with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::INFO => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::INFO, 'message of level info with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::DEBUG => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::DEBUG, 'message of level debug with context: {user}')); - } - /** - * @expectedException \Psr\Log\InvalidArgumentException - */ - public function testThrowsOnInvalidLevel() - { - $logger = $this->getLogger(); - $logger->log('invalid level', 'Foo'); - } - public function testContextReplacement() - { - $logger = $this->getLogger(); - $logger->info('{Message {nothing} {user} {foo.bar} a}', array('user' => 'Bob', 'foo.bar' => 'Bar')); - $expected = array('info {Message {nothing} Bob Bar a}'); - $this->assertEquals($expected, $this->getLogs()); - } - public function testObjectCastToString() - { - if (\method_exists($this, 'createPartialMock')) { - $dummy = $this->createPartialMock('_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\DummyTest', array('__toString')); - } else { - $dummy = $this->getMock('_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\DummyTest', array('__toString')); - } - $dummy->expects($this->once())->method('__toString')->will($this->returnValue('DUMMY')); - $this->getLogger()->warning($dummy); - $expected = array('warning DUMMY'); - $this->assertEquals($expected, $this->getLogs()); - } - public function testContextCanContainAnything() - { - $closed = \fopen('php://memory', 'r'); - \fclose($closed); - $context = array('bool' => \true, 'null' => null, 'string' => 'Foo', 'int' => 0, 'float' => 0.5, 'nested' => array('with object' => new \_PhpScoper5ea00cc67502b\Psr\Log\Test\DummyTest()), 'object' => new \DateTime(), 'resource' => \fopen('php://memory', 'r'), 'closed' => $closed); - $this->getLogger()->warning('Crazy context data', $context); - $expected = array('warning Crazy context data'); - $this->assertEquals($expected, $this->getLogs()); - } - public function testContextExceptionKeyCanBeExceptionOrOtherValues() - { - $logger = $this->getLogger(); - $logger->warning('Random message', array('exception' => 'oops')); - $logger->critical('Uncaught Exception!', array('exception' => new \LogicException('Fail'))); - $expected = array('warning Random message', 'critical Uncaught Exception!'); - $this->assertEquals($expected, $this->getLogs()); - } -} + ". + * + * Example ->error('Foo') would yield "error Foo". + * + * @return string[] + */ + public abstract function getLogs(); + public function testImplements() + { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Psr\\Log\\LoggerInterface', $this->getLogger()); + } + /** + * @dataProvider provideLevelsAndMessages + */ + public function testLogsAtAllLevels($level, $message) + { + $logger = $this->getLogger(); + $logger->{$level}($message, array('user' => 'Bob')); + $logger->log($level, $message, array('user' => 'Bob')); + $expected = array($level . ' message of level ' . $level . ' with context: Bob', $level . ' message of level ' . $level . ' with context: Bob'); + $this->assertEquals($expected, $this->getLogs()); + } + public function provideLevelsAndMessages() + { + return array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::EMERGENCY => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::EMERGENCY, 'message of level emergency with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ALERT => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ALERT, 'message of level alert with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::CRITICAL => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::CRITICAL, 'message of level critical with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ERROR => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::ERROR, 'message of level error with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::WARNING => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::WARNING, 'message of level warning with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::NOTICE => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::NOTICE, 'message of level notice with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::INFO => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::INFO, 'message of level info with context: {user}'), \_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::DEBUG => array(\_PhpScoper5ea00cc67502b\Psr\Log\LogLevel::DEBUG, 'message of level debug with context: {user}')); + } + /** + * @expectedException \Psr\Log\InvalidArgumentException + */ + public function testThrowsOnInvalidLevel() + { + $logger = $this->getLogger(); + $logger->log('invalid level', 'Foo'); + } + public function testContextReplacement() + { + $logger = $this->getLogger(); + $logger->info('{Message {nothing} {user} {foo.bar} a}', array('user' => 'Bob', 'foo.bar' => 'Bar')); + $expected = array('info {Message {nothing} Bob Bar a}'); + $this->assertEquals($expected, $this->getLogs()); + } + public function testObjectCastToString() + { + if (\method_exists($this, 'createPartialMock')) { + $dummy = $this->createPartialMock('_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\DummyTest', array('__toString')); + } else { + $dummy = $this->getMock('_PhpScoper5ea00cc67502b\\Psr\\Log\\Test\\DummyTest', array('__toString')); + } + $dummy->expects($this->once())->method('__toString')->will($this->returnValue('DUMMY')); + $this->getLogger()->warning($dummy); + $expected = array('warning DUMMY'); + $this->assertEquals($expected, $this->getLogs()); + } + public function testContextCanContainAnything() + { + $closed = \fopen('php://memory', 'r'); + \fclose($closed); + $context = array('bool' => \true, 'null' => null, 'string' => 'Foo', 'int' => 0, 'float' => 0.5, 'nested' => array('with object' => new \_PhpScoper5ea00cc67502b\Psr\Log\Test\DummyTest()), 'object' => new \DateTime(), 'resource' => \fopen('php://memory', 'r'), 'closed' => $closed); + $this->getLogger()->warning('Crazy context data', $context); + $expected = array('warning Crazy context data'); + $this->assertEquals($expected, $this->getLogs()); + } + public function testContextExceptionKeyCanBeExceptionOrOtherValues() + { + $logger = $this->getLogger(); + $logger->warning('Random message', array('exception' => 'oops')); + $logger->critical('Uncaught Exception!', array('exception' => new \LogicException('Fail'))); + $expected = array('warning Random message', 'critical Uncaught Exception!'); + $this->assertEquals($expected, $this->getLogs()); + } +} diff --git a/vendor/psr/log/Psr/Log/Test/TestLogger.php b/vendor/psr/log/Psr/Log/Test/TestLogger.php index 839007c19..273ebc357 100644 --- a/vendor/psr/log/Psr/Log/Test/TestLogger.php +++ b/vendor/psr/log/Psr/Log/Test/TestLogger.php @@ -1,132 +1,132 @@ - $level, 'message' => $message, 'context' => $context]; - $this->recordsByLevel[$record['level']][] = $record; - $this->records[] = $record; - } - public function hasRecords($level) - { - return isset($this->recordsByLevel[$level]); - } - public function hasRecord($record, $level) - { - if (\is_string($record)) { - $record = ['message' => $record]; - } - return $this->hasRecordThatPasses(function ($rec) use($record) { - if ($rec['message'] !== $record['message']) { - return \false; - } - if (isset($record['context']) && $rec['context'] !== $record['context']) { - return \false; - } - return \true; - }, $level); - } - public function hasRecordThatContains($message, $level) - { - return $this->hasRecordThatPasses(function ($rec) use($message) { - return \strpos($rec['message'], $message) !== \false; - }, $level); - } - public function hasRecordThatMatches($regex, $level) - { - return $this->hasRecordThatPasses(function ($rec) use($regex) { - return \preg_match($regex, $rec['message']) > 0; - }, $level); - } - public function hasRecordThatPasses(callable $predicate, $level) - { - if (!isset($this->recordsByLevel[$level])) { - return \false; - } - foreach ($this->recordsByLevel[$level] as $i => $rec) { - if (\call_user_func($predicate, $rec, $i)) { - return \true; - } - } - return \false; - } - public function __call($method, $args) - { - if (\preg_match('/(.*)(Debug|Info|Notice|Warning|Error|Critical|Alert|Emergency)(.*)/', $method, $matches) > 0) { - $genericMethod = $matches[1] . ('Records' !== $matches[3] ? 'Record' : '') . $matches[3]; - $level = \strtolower($matches[2]); - if (\method_exists($this, $genericMethod)) { - $args[] = $level; - return \call_user_func_array([$this, $genericMethod], $args); - } - } - throw new \BadMethodCallException('Call to undefined method ' . \get_class($this) . '::' . $method . '()'); - } - public function reset() - { - $this->records = []; - $this->recordsByLevel = []; - } -} + $level, 'message' => $message, 'context' => $context]; + $this->recordsByLevel[$record['level']][] = $record; + $this->records[] = $record; + } + public function hasRecords($level) + { + return isset($this->recordsByLevel[$level]); + } + public function hasRecord($record, $level) + { + if (\is_string($record)) { + $record = ['message' => $record]; + } + return $this->hasRecordThatPasses(function ($rec) use($record) { + if ($rec['message'] !== $record['message']) { + return \false; + } + if (isset($record['context']) && $rec['context'] !== $record['context']) { + return \false; + } + return \true; + }, $level); + } + public function hasRecordThatContains($message, $level) + { + return $this->hasRecordThatPasses(function ($rec) use($message) { + return \strpos($rec['message'], $message) !== \false; + }, $level); + } + public function hasRecordThatMatches($regex, $level) + { + return $this->hasRecordThatPasses(function ($rec) use($regex) { + return \preg_match($regex, $rec['message']) > 0; + }, $level); + } + public function hasRecordThatPasses(callable $predicate, $level) + { + if (!isset($this->recordsByLevel[$level])) { + return \false; + } + foreach ($this->recordsByLevel[$level] as $i => $rec) { + if (\call_user_func($predicate, $rec, $i)) { + return \true; + } + } + return \false; + } + public function __call($method, $args) + { + if (\preg_match('/(.*)(Debug|Info|Notice|Warning|Error|Critical|Alert|Emergency)(.*)/', $method, $matches) > 0) { + $genericMethod = $matches[1] . ('Records' !== $matches[3] ? 'Record' : '') . $matches[3]; + $level = \strtolower($matches[2]); + if (\method_exists($this, $genericMethod)) { + $args[] = $level; + return \call_user_func_array([$this, $genericMethod], $args); + } + } + throw new \BadMethodCallException('Call to undefined method ' . \get_class($this) . '::' . $method . '()'); + } + public function reset() + { + $this->records = []; + $this->recordsByLevel = []; + } +} diff --git a/vendor/psr/log/Psr/Log/Test/index.php b/vendor/psr/log/Psr/Log/Test/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/psr/log/Psr/Log/Test/index.php +++ b/vendor/psr/log/Psr/Log/Test/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/log/Psr/Log/index.php b/vendor/psr/log/Psr/Log/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/psr/log/Psr/Log/index.php +++ b/vendor/psr/log/Psr/Log/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/log/Psr/index.php b/vendor/psr/log/Psr/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/psr/log/Psr/index.php +++ b/vendor/psr/log/Psr/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/log/README.md b/vendor/psr/log/README.md index a9f20c437..edbc91761 100644 --- a/vendor/psr/log/README.md +++ b/vendor/psr/log/README.md @@ -1,58 +1,58 @@ -PSR Log -======= - -This repository holds all interfaces/classes/traits related to -[PSR-3](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-3-logger-interface.md). - -Note that this is not a logger of its own. It is merely an interface that -describes a logger. See the specification for more details. - -Installation ------------- - -```bash -composer require psr/log -``` - -Usage ------ - -If you need a logger, you can use the interface like this: - -```php -logger = $logger; - } - - public function doSomething() - { - if ($this->logger) { - $this->logger->info('Doing work'); - } - - try { - $this->doSomethingElse(); - } catch (Exception $exception) { - $this->logger->error('Oh no!', array('exception' => $exception)); - } - - // do something useful - } -} -``` - -You can then pick one of the implementations of the interface to get a logger. - -If you want to implement the interface, you can require this package and -implement `Psr\Log\LoggerInterface` in your code. Please read the -[specification text](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-3-logger-interface.md) -for details. +PSR Log +======= + +This repository holds all interfaces/classes/traits related to +[PSR-3](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-3-logger-interface.md). + +Note that this is not a logger of its own. It is merely an interface that +describes a logger. See the specification for more details. + +Installation +------------ + +```bash +composer require psr/log +``` + +Usage +----- + +If you need a logger, you can use the interface like this: + +```php +logger = $logger; + } + + public function doSomething() + { + if ($this->logger) { + $this->logger->info('Doing work'); + } + + try { + $this->doSomethingElse(); + } catch (Exception $exception) { + $this->logger->error('Oh no!', array('exception' => $exception)); + } + + // do something useful + } +} +``` + +You can then pick one of the implementations of the interface to get a logger. + +If you want to implement the interface, you can require this package and +implement `Psr\Log\LoggerInterface` in your code. Please read the +[specification text](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-3-logger-interface.md) +for details. diff --git a/vendor/psr/log/composer.json b/vendor/psr/log/composer.json index 909e0c7d6..e8416dc4d 100644 --- a/vendor/psr/log/composer.json +++ b/vendor/psr/log/composer.json @@ -1,30 +1,30 @@ -{ - "name": "psr\/log", - "description": "Common interface for logging libraries", - "keywords": [ - "psr", - "psr-3", - "log" - ], - "homepage": "https:\/\/github.com\/php-fig\/log", - "license": "MIT", - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http:\/\/www.php-fig.org\/" - } - ], - "require": { - "php": ">=5.3.0" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Psr\\Log\\": "Psr\/Log\/" - } - }, - "extra": { - "branch-alias": { - "dev-master": "1.1.x-dev" - } - } +{ + "name": "psr\/log", + "description": "Common interface for logging libraries", + "keywords": [ + "psr", + "psr-3", + "log" + ], + "homepage": "https:\/\/github.com\/php-fig\/log", + "license": "MIT", + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http:\/\/www.php-fig.org\/" + } + ], + "require": { + "php": ">=5.3.0" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Psr\\Log\\": "Psr\/Log\/" + } + }, + "extra": { + "branch-alias": { + "dev-master": "1.1.x-dev" + } + } } \ No newline at end of file diff --git a/vendor/psr/log/index.php b/vendor/psr/log/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/psr/log/index.php +++ b/vendor/psr/log/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/simple-cache/.editorconfig b/vendor/psr/simple-cache/.editorconfig index 48542cbb4..308d493a0 100644 --- a/vendor/psr/simple-cache/.editorconfig +++ b/vendor/psr/simple-cache/.editorconfig @@ -1,12 +1,12 @@ -; This file is for unifying the coding style for different editors and IDEs. -; More information at http://editorconfig.org - -root = true - -[*] -charset = utf-8 -indent_size = 4 -indent_style = space -end_of_line = lf -insert_final_newline = true -trim_trailing_whitespace = true +; This file is for unifying the coding style for different editors and IDEs. +; More information at http://editorconfig.org + +root = true + +[*] +charset = utf-8 +indent_size = 4 +indent_style = space +end_of_line = lf +insert_final_newline = true +trim_trailing_whitespace = true diff --git a/vendor/psr/simple-cache/LICENSE.md b/vendor/psr/simple-cache/LICENSE.md index e49a7c85a..6d9da8c9a 100644 --- a/vendor/psr/simple-cache/LICENSE.md +++ b/vendor/psr/simple-cache/LICENSE.md @@ -1,21 +1,21 @@ -# The MIT License (MIT) - -Copyright (c) 2016 PHP Framework Interoperability Group - -> Permission is hereby granted, free of charge, to any person obtaining a copy -> of this software and associated documentation files (the "Software"), to deal -> in the Software without restriction, including without limitation the rights -> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -> copies of the Software, and to permit persons to whom the Software is -> furnished to do so, subject to the following conditions: -> -> The above copyright notice and this permission notice shall be included in -> all copies or substantial portions of the Software. -> -> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -> THE SOFTWARE. +# The MIT License (MIT) + +Copyright (c) 2016 PHP Framework Interoperability Group + +> Permission is hereby granted, free of charge, to any person obtaining a copy +> of this software and associated documentation files (the "Software"), to deal +> in the Software without restriction, including without limitation the rights +> to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +> copies of the Software, and to permit persons to whom the Software is +> furnished to do so, subject to the following conditions: +> +> The above copyright notice and this permission notice shall be included in +> all copies or substantial portions of the Software. +> +> THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +> IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +> FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +> AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +> LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +> OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +> THE SOFTWARE. diff --git a/vendor/psr/simple-cache/README.md b/vendor/psr/simple-cache/README.md index 43641d175..1c9f71f90 100644 --- a/vendor/psr/simple-cache/README.md +++ b/vendor/psr/simple-cache/README.md @@ -1,8 +1,8 @@ -PHP FIG Simple Cache PSR -======================== - -This repository holds all interfaces related to PSR-16. - -Note that this is not a cache implementation of its own. It is merely an interface that describes a cache implementation. See [the specification](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-16-simple-cache.md) for more details. - -You can find implementations of the specification by looking for packages providing the [psr/simple-cache-implementation](https://packagist.org/providers/psr/simple-cache-implementation) virtual package. +PHP FIG Simple Cache PSR +======================== + +This repository holds all interfaces related to PSR-16. + +Note that this is not a cache implementation of its own. It is merely an interface that describes a cache implementation. See [the specification](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-16-simple-cache.md) for more details. + +You can find implementations of the specification by looking for packages providing the [psr/simple-cache-implementation](https://packagist.org/providers/psr/simple-cache-implementation) virtual package. diff --git a/vendor/psr/simple-cache/composer.json b/vendor/psr/simple-cache/composer.json index e7cfff61d..2a0fcd364 100644 --- a/vendor/psr/simple-cache/composer.json +++ b/vendor/psr/simple-cache/composer.json @@ -1,31 +1,31 @@ -{ - "name": "psr\/simple-cache", - "description": "Common interfaces for simple caching", - "keywords": [ - "psr", - "psr-16", - "cache", - "simple-cache", - "caching" - ], - "license": "MIT", - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http:\/\/www.php-fig.org\/" - } - ], - "require": { - "php": ">=5.3.0" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\": "src\/" - } - }, - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - } +{ + "name": "psr\/simple-cache", + "description": "Common interfaces for simple caching", + "keywords": [ + "psr", + "psr-16", + "cache", + "simple-cache", + "caching" + ], + "license": "MIT", + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http:\/\/www.php-fig.org\/" + } + ], + "require": { + "php": ">=5.3.0" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Psr\\SimpleCache\\": "src\/" + } + }, + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + } } \ No newline at end of file diff --git a/vendor/psr/simple-cache/index.php b/vendor/psr/simple-cache/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/psr/simple-cache/index.php +++ b/vendor/psr/simple-cache/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/psr/simple-cache/src/CacheException.php b/vendor/psr/simple-cache/src/CacheException.php index c621789f6..527e6ba99 100644 --- a/vendor/psr/simple-cache/src/CacheException.php +++ b/vendor/psr/simple-cache/src/CacheException.php @@ -1,10 +1,10 @@ - value pairs. Cache keys that do not exist or are stale will have $default as value. - * - * @throws \Psr\SimpleCache\InvalidArgumentException - * MUST be thrown if $keys is neither an array nor a Traversable, - * or if any of the $keys are not a legal value. - */ - public function getMultiple($keys, $default = null); - /** - * Persists a set of key => value pairs in the cache, with an optional TTL. - * - * @param iterable $values A list of key => value pairs for a multiple-set operation. - * @param null|int|\DateInterval $ttl Optional. The TTL value of this item. If no value is sent and - * the driver supports TTL then the library may set a default value - * for it or let the driver take care of that. - * - * @return bool True on success and false on failure. - * - * @throws \Psr\SimpleCache\InvalidArgumentException - * MUST be thrown if $values is neither an array nor a Traversable, - * or if any of the $values are not a legal value. - */ - public function setMultiple($values, $ttl = null); - /** - * Deletes multiple cache items in a single operation. - * - * @param iterable $keys A list of string-based keys to be deleted. - * - * @return bool True if the items were successfully removed. False if there was an error. - * - * @throws \Psr\SimpleCache\InvalidArgumentException - * MUST be thrown if $keys is neither an array nor a Traversable, - * or if any of the $keys are not a legal value. - */ - public function deleteMultiple($keys); - /** - * Determines whether an item is present in the cache. - * - * NOTE: It is recommended that has() is only to be used for cache warming type purposes - * and not to be used within your live applications operations for get/set, as this method - * is subject to a race condition where your has() will return true and immediately after, - * another script can remove it making the state of your app out of date. - * - * @param string $key The cache item key. - * - * @return bool - * - * @throws \Psr\SimpleCache\InvalidArgumentException - * MUST be thrown if the $key string is not a legal value. - */ - public function has($key); -} + value pairs. Cache keys that do not exist or are stale will have $default as value. + * + * @throws \Psr\SimpleCache\InvalidArgumentException + * MUST be thrown if $keys is neither an array nor a Traversable, + * or if any of the $keys are not a legal value. + */ + public function getMultiple($keys, $default = null); + /** + * Persists a set of key => value pairs in the cache, with an optional TTL. + * + * @param iterable $values A list of key => value pairs for a multiple-set operation. + * @param null|int|\DateInterval $ttl Optional. The TTL value of this item. If no value is sent and + * the driver supports TTL then the library may set a default value + * for it or let the driver take care of that. + * + * @return bool True on success and false on failure. + * + * @throws \Psr\SimpleCache\InvalidArgumentException + * MUST be thrown if $values is neither an array nor a Traversable, + * or if any of the $values are not a legal value. + */ + public function setMultiple($values, $ttl = null); + /** + * Deletes multiple cache items in a single operation. + * + * @param iterable $keys A list of string-based keys to be deleted. + * + * @return bool True if the items were successfully removed. False if there was an error. + * + * @throws \Psr\SimpleCache\InvalidArgumentException + * MUST be thrown if $keys is neither an array nor a Traversable, + * or if any of the $keys are not a legal value. + */ + public function deleteMultiple($keys); + /** + * Determines whether an item is present in the cache. + * + * NOTE: It is recommended that has() is only to be used for cache warming type purposes + * and not to be used within your live applications operations for get/set, as this method + * is subject to a race condition where your has() will return true and immediately after, + * another script can remove it making the state of your app out of date. + * + * @param string $key The cache item key. + * + * @return bool + * + * @throws \Psr\SimpleCache\InvalidArgumentException + * MUST be thrown if the $key string is not a legal value. + */ + public function has($key); +} diff --git a/vendor/psr/simple-cache/src/InvalidArgumentException.php b/vendor/psr/simple-cache/src/InvalidArgumentException.php index c84eaa0a1..3e5509594 100644 --- a/vendor/psr/simple-cache/src/InvalidArgumentException.php +++ b/vendor/psr/simple-cache/src/InvalidArgumentException.php @@ -1,13 +1,13 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/ralouphie/getallheaders/LICENSE b/vendor/ralouphie/getallheaders/LICENSE index be5540c2a..634d3738e 100644 --- a/vendor/ralouphie/getallheaders/LICENSE +++ b/vendor/ralouphie/getallheaders/LICENSE @@ -1,21 +1,21 @@ -The MIT License (MIT) - -Copyright (c) 2014 Ralph Khattar - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +The MIT License (MIT) + +Copyright (c) 2014 Ralph Khattar + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/vendor/ralouphie/getallheaders/README.md b/vendor/ralouphie/getallheaders/README.md index 9430d76bb..1501cf788 100644 --- a/vendor/ralouphie/getallheaders/README.md +++ b/vendor/ralouphie/getallheaders/README.md @@ -1,27 +1,27 @@ -getallheaders -============= - -PHP `getallheaders()` polyfill. Compatible with PHP >= 5.3. - -[![Build Status](https://travis-ci.org/ralouphie/getallheaders.svg?branch=master)](https://travis-ci.org/ralouphie/getallheaders) -[![Coverage Status](https://coveralls.io/repos/ralouphie/getallheaders/badge.png?branch=master)](https://coveralls.io/r/ralouphie/getallheaders?branch=master) -[![Latest Stable Version](https://poser.pugx.org/ralouphie/getallheaders/v/stable.png)](https://packagist.org/packages/ralouphie/getallheaders) -[![Latest Unstable Version](https://poser.pugx.org/ralouphie/getallheaders/v/unstable.png)](https://packagist.org/packages/ralouphie/getallheaders) -[![License](https://poser.pugx.org/ralouphie/getallheaders/license.png)](https://packagist.org/packages/ralouphie/getallheaders) - - -This is a simple polyfill for [`getallheaders()`](http://www.php.net/manual/en/function.getallheaders.php). - -## Install - -For PHP version **`>= 5.6`**: - -``` -composer require ralouphie/getallheaders -``` - -For PHP version **`< 5.6`**: - -``` -composer require ralouphie/getallheaders "^2" -``` +getallheaders +============= + +PHP `getallheaders()` polyfill. Compatible with PHP >= 5.3. + +[![Build Status](https://travis-ci.org/ralouphie/getallheaders.svg?branch=master)](https://travis-ci.org/ralouphie/getallheaders) +[![Coverage Status](https://coveralls.io/repos/ralouphie/getallheaders/badge.png?branch=master)](https://coveralls.io/r/ralouphie/getallheaders?branch=master) +[![Latest Stable Version](https://poser.pugx.org/ralouphie/getallheaders/v/stable.png)](https://packagist.org/packages/ralouphie/getallheaders) +[![Latest Unstable Version](https://poser.pugx.org/ralouphie/getallheaders/v/unstable.png)](https://packagist.org/packages/ralouphie/getallheaders) +[![License](https://poser.pugx.org/ralouphie/getallheaders/license.png)](https://packagist.org/packages/ralouphie/getallheaders) + + +This is a simple polyfill for [`getallheaders()`](http://www.php.net/manual/en/function.getallheaders.php). + +## Install + +For PHP version **`>= 5.6`**: + +``` +composer require ralouphie/getallheaders +``` + +For PHP version **`< 5.6`**: + +``` +composer require ralouphie/getallheaders "^2" +``` diff --git a/vendor/ralouphie/getallheaders/composer.json b/vendor/ralouphie/getallheaders/composer.json index 7efaf836e..72b78c4c3 100644 --- a/vendor/ralouphie/getallheaders/composer.json +++ b/vendor/ralouphie/getallheaders/composer.json @@ -1,28 +1,28 @@ -{ - "name": "ralouphie\/getallheaders", - "description": "A polyfill for getallheaders.", - "license": "MIT", - "authors": [ - { - "name": "Ralph Khattar", - "email": "ralph.khattar@gmail.com" - } - ], - "require": { - "php": ">=5.6" - }, - "require-dev": { - "phpunit\/phpunit": "^5 || ^6.5", - "php-coveralls\/php-coveralls": "^2.1" - }, - "autoload": { - "files": [ - "src\/getallheaders.php" - ] - }, - "autoload-dev": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\getallheaders\\Tests\\": "tests\/" - } - } +{ + "name": "ralouphie\/getallheaders", + "description": "A polyfill for getallheaders.", + "license": "MIT", + "authors": [ + { + "name": "Ralph Khattar", + "email": "ralph.khattar@gmail.com" + } + ], + "require": { + "php": ">=5.6" + }, + "require-dev": { + "phpunit\/phpunit": "^5 || ^6.5", + "php-coveralls\/php-coveralls": "^2.1" + }, + "autoload": { + "files": [ + "src\/getallheaders.php" + ] + }, + "autoload-dev": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\getallheaders\\Tests\\": "tests\/" + } + } } \ No newline at end of file diff --git a/vendor/ralouphie/getallheaders/index.php b/vendor/ralouphie/getallheaders/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/ralouphie/getallheaders/index.php +++ b/vendor/ralouphie/getallheaders/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/ralouphie/getallheaders/src/getallheaders.php b/vendor/ralouphie/getallheaders/src/getallheaders.php index bd1d7e482..40429d8e6 100644 --- a/vendor/ralouphie/getallheaders/src/getallheaders.php +++ b/vendor/ralouphie/getallheaders/src/getallheaders.php @@ -1,38 +1,38 @@ - 'Content-Type', 'CONTENT_LENGTH' => 'Content-Length', 'CONTENT_MD5' => 'Content-Md5'); - foreach ($_SERVER as $key => $value) { - if (\substr($key, 0, 5) === 'HTTP_') { - $key = \substr($key, 5); - if (!isset($copy_server[$key]) || !isset($_SERVER[$key])) { - $key = \str_replace(' ', '-', \ucwords(\strtolower(\str_replace('_', ' ', $key)))); - $headers[$key] = $value; - } - } elseif (isset($copy_server[$key])) { - $headers[$copy_server[$key]] = $value; - } - } - if (!isset($headers['Authorization'])) { - if (isset($_SERVER['REDIRECT_HTTP_AUTHORIZATION'])) { - $headers['Authorization'] = $_SERVER['REDIRECT_HTTP_AUTHORIZATION']; - } elseif (isset($_SERVER['PHP_AUTH_USER'])) { - $basic_pass = isset($_SERVER['PHP_AUTH_PW']) ? $_SERVER['PHP_AUTH_PW'] : ''; - $headers['Authorization'] = 'Basic ' . \base64_encode($_SERVER['PHP_AUTH_USER'] . ':' . $basic_pass); - } elseif (isset($_SERVER['PHP_AUTH_DIGEST'])) { - $headers['Authorization'] = $_SERVER['PHP_AUTH_DIGEST']; - } - } - return $headers; - } -} + 'Content-Type', 'CONTENT_LENGTH' => 'Content-Length', 'CONTENT_MD5' => 'Content-Md5'); + foreach ($_SERVER as $key => $value) { + if (\substr($key, 0, 5) === 'HTTP_') { + $key = \substr($key, 5); + if (!isset($copy_server[$key]) || !isset($_SERVER[$key])) { + $key = \str_replace(' ', '-', \ucwords(\strtolower(\str_replace('_', ' ', $key)))); + $headers[$key] = $value; + } + } elseif (isset($copy_server[$key])) { + $headers[$copy_server[$key]] = $value; + } + } + if (!isset($headers['Authorization'])) { + if (isset($_SERVER['REDIRECT_HTTP_AUTHORIZATION'])) { + $headers['Authorization'] = $_SERVER['REDIRECT_HTTP_AUTHORIZATION']; + } elseif (isset($_SERVER['PHP_AUTH_USER'])) { + $basic_pass = isset($_SERVER['PHP_AUTH_PW']) ? $_SERVER['PHP_AUTH_PW'] : ''; + $headers['Authorization'] = 'Basic ' . \base64_encode($_SERVER['PHP_AUTH_USER'] . ':' . $basic_pass); + } elseif (isset($_SERVER['PHP_AUTH_DIGEST'])) { + $headers['Authorization'] = $_SERVER['PHP_AUTH_DIGEST']; + } + } + return $headers; + } +} diff --git a/vendor/ralouphie/getallheaders/src/index.php b/vendor/ralouphie/getallheaders/src/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/ralouphie/getallheaders/src/index.php +++ b/vendor/ralouphie/getallheaders/src/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/ralouphie/index.php b/vendor/ralouphie/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/ralouphie/index.php +++ b/vendor/ralouphie/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/.gitignore b/vendor/symfony/cache/.gitignore index 5414c2c65..0d0f9f6fa 100644 --- a/vendor/symfony/cache/.gitignore +++ b/vendor/symfony/cache/.gitignore @@ -1,3 +1,3 @@ -composer.lock -phpunit.xml -vendor/ +composer.lock +phpunit.xml +vendor/ diff --git a/vendor/symfony/cache/Adapter/AbstractAdapter.php b/vendor/symfony/cache/Adapter/AbstractAdapter.php index 7d7200fec..a3dc55626 100644 --- a/vendor/symfony/cache/Adapter/AbstractAdapter.php +++ b/vendor/symfony/cache/Adapter/AbstractAdapter.php @@ -1,271 +1,271 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface; -use _PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface; -use _PhpScoper5ea00cc67502b\Psr\Log\NullLogger; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\AbstractTrait; -/** - * @author Nicolas Grekas - */ -abstract class AbstractAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - /** - * @internal - */ - const NS_SEPARATOR = ':'; - use AbstractTrait; - private static $apcuSupported; - private static $phpFilesSupported; - private $createCacheItem; - private $mergeByLifetime; - /** - * @param string $namespace - * @param int $defaultLifetime - */ - protected function __construct($namespace = '', $defaultLifetime = 0) - { - $this->namespace = '' === $namespace ? '' : \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($namespace) . static::NS_SEPARATOR; - if (null !== $this->maxIdLength && \strlen($namespace) > $this->maxIdLength - 24) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Namespace must be %d chars max, %d given ("%s").', $this->maxIdLength - 24, \strlen($namespace), $namespace)); - } - $this->createCacheItem = \Closure::bind(static function ($key, $value, $isHit) use($defaultLifetime) { - $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); - $item->key = $key; - $item->value = $value; - $item->isHit = $isHit; - $item->defaultLifetime = $defaultLifetime; - return $item; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - $getId = function ($key) { - return $this->getId((string) $key); - }; - $this->mergeByLifetime = \Closure::bind(static function ($deferred, $namespace, &$expiredIds) use($getId) { - $byLifetime = []; - $now = \time(); - $expiredIds = []; - foreach ($deferred as $key => $item) { - if (null === $item->expiry) { - $byLifetime[0 < $item->defaultLifetime ? $item->defaultLifetime : 0][$getId($key)] = $item->value; - } elseif ($item->expiry > $now) { - $byLifetime[$item->expiry - $now][$getId($key)] = $item->value; - } else { - $expiredIds[] = $getId($key); - } - } - return $byLifetime; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - } - /** - * @param string $namespace - * @param int $defaultLifetime - * @param string $version - * @param string $directory - * - * @return AdapterInterface - */ - public static function createSystemCache($namespace, $defaultLifetime, $version, $directory, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger = null) - { - if (null === self::$apcuSupported) { - self::$apcuSupported = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter::isSupported(); - } - if (!self::$apcuSupported && null === self::$phpFilesSupported) { - self::$phpFilesSupported = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpFilesAdapter::isSupported(); - } - if (self::$phpFilesSupported) { - $opcache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpFilesAdapter($namespace, $defaultLifetime, $directory); - if (null !== $logger) { - $opcache->setLogger($logger); - } - return $opcache; - } - $fs = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter($namespace, $defaultLifetime, $directory); - if (null !== $logger) { - $fs->setLogger($logger); - } - if (!self::$apcuSupported) { - return $fs; - } - $apcu = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter($namespace, (int) $defaultLifetime / 5, $version); - if ('cli' === \PHP_SAPI && !\filter_var(\ini_get('apc.enable_cli'), \FILTER_VALIDATE_BOOLEAN)) { - $apcu->setLogger(new \_PhpScoper5ea00cc67502b\Psr\Log\NullLogger()); - } elseif (null !== $logger) { - $apcu->setLogger($logger); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([$apcu, $fs]); - } - public static function createConnection($dsn, array $options = []) - { - if (!\is_string($dsn)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('The "%s()" method expect argument #1 to be string, "%s" given.', __METHOD__, \gettype($dsn))); - } - if (0 === \strpos($dsn, 'redis://')) { - return \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection($dsn, $options); - } - if (0 === \strpos($dsn, 'memcached://')) { - return \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection($dsn, $options); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Unsupported DSN: "%s".', $dsn)); - } - /** - * {@inheritdoc} - */ - public function getItem($key) - { - if ($this->deferred) { - $this->commit(); - } - $id = $this->getId($key); - $f = $this->createCacheItem; - $isHit = \false; - $value = null; - try { - foreach ($this->doFetch([$id]) as $value) { - $isHit = \true; - } - } catch (\Exception $e) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch key "{key}"', ['key' => $key, 'exception' => $e]); - } - return $f($key, $value, $isHit); - } - /** - * {@inheritdoc} - */ - public function getItems(array $keys = []) - { - if ($this->deferred) { - $this->commit(); - } - $ids = []; - foreach ($keys as $key) { - $ids[] = $this->getId($key); - } - try { - $items = $this->doFetch($ids); - } catch (\Exception $e) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch requested items', ['keys' => $keys, 'exception' => $e]); - $items = []; - } - $ids = \array_combine($ids, $keys); - return $this->generateItems($items, $ids); - } - /** - * {@inheritdoc} - */ - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { - return \false; - } - $this->deferred[$item->getKey()] = $item; - return $this->commit(); - } - /** - * {@inheritdoc} - */ - public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { - return \false; - } - $this->deferred[$item->getKey()] = $item; - return \true; - } - /** - * {@inheritdoc} - */ - public function commit() - { - $ok = \true; - $byLifetime = $this->mergeByLifetime; - $byLifetime = $byLifetime($this->deferred, $this->namespace, $expiredIds); - $retry = $this->deferred = []; - if ($expiredIds) { - $this->doDelete($expiredIds); - } - foreach ($byLifetime as $lifetime => $values) { - try { - $e = $this->doSave($values, $lifetime); - } catch (\Exception $e) { - } - if (\true === $e || [] === $e) { - continue; - } - if (\is_array($e) || 1 === \count($values)) { - foreach (\is_array($e) ? $e : \array_keys($values) as $id) { - $ok = \false; - $v = $values[$id]; - $type = \is_object($v) ? \get_class($v) : \gettype($v); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to save key "{key}" ({type})', ['key' => \substr($id, \strlen($this->namespace)), 'type' => $type, 'exception' => $e instanceof \Exception ? $e : null]); - } - } else { - foreach ($values as $id => $v) { - $retry[$lifetime][] = $id; - } - } - } - // When bulk-save failed, retry each item individually - foreach ($retry as $lifetime => $ids) { - foreach ($ids as $id) { - try { - $v = $byLifetime[$lifetime][$id]; - $e = $this->doSave([$id => $v], $lifetime); - } catch (\Exception $e) { - } - if (\true === $e || [] === $e) { - continue; - } - $ok = \false; - $type = \is_object($v) ? \get_class($v) : \gettype($v); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to save key "{key}" ({type})', ['key' => \substr($id, \strlen($this->namespace)), 'type' => $type, 'exception' => $e instanceof \Exception ? $e : null]); - } - } - return $ok; - } - public function __sleep() - { - throw new \BadMethodCallException('Cannot serialize ' . __CLASS__); - } - public function __wakeup() - { - throw new \BadMethodCallException('Cannot unserialize ' . __CLASS__); - } - public function __destruct() - { - if ($this->deferred) { - $this->commit(); - } - } - private function generateItems($items, &$keys) - { - $f = $this->createCacheItem; - try { - foreach ($items as $id => $value) { - if (!isset($keys[$id])) { - $id = \key($keys); - } - $key = $keys[$id]; - unset($keys[$id]); - (yield $key => $f($key, $value, \true)); - } - } catch (\Exception $e) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch requested items', ['keys' => \array_values($keys), 'exception' => $e]); - } - foreach ($keys as $key) { - (yield $key => $f($key, null, \false)); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface; +use _PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface; +use _PhpScoper5ea00cc67502b\Psr\Log\NullLogger; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\AbstractTrait; +/** + * @author Nicolas Grekas + */ +abstract class AbstractAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + /** + * @internal + */ + const NS_SEPARATOR = ':'; + use AbstractTrait; + private static $apcuSupported; + private static $phpFilesSupported; + private $createCacheItem; + private $mergeByLifetime; + /** + * @param string $namespace + * @param int $defaultLifetime + */ + protected function __construct($namespace = '', $defaultLifetime = 0) + { + $this->namespace = '' === $namespace ? '' : \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($namespace) . static::NS_SEPARATOR; + if (null !== $this->maxIdLength && \strlen($namespace) > $this->maxIdLength - 24) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Namespace must be %d chars max, %d given ("%s").', $this->maxIdLength - 24, \strlen($namespace), $namespace)); + } + $this->createCacheItem = \Closure::bind(static function ($key, $value, $isHit) use($defaultLifetime) { + $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); + $item->key = $key; + $item->value = $value; + $item->isHit = $isHit; + $item->defaultLifetime = $defaultLifetime; + return $item; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + $getId = function ($key) { + return $this->getId((string) $key); + }; + $this->mergeByLifetime = \Closure::bind(static function ($deferred, $namespace, &$expiredIds) use($getId) { + $byLifetime = []; + $now = \time(); + $expiredIds = []; + foreach ($deferred as $key => $item) { + if (null === $item->expiry) { + $byLifetime[0 < $item->defaultLifetime ? $item->defaultLifetime : 0][$getId($key)] = $item->value; + } elseif ($item->expiry > $now) { + $byLifetime[$item->expiry - $now][$getId($key)] = $item->value; + } else { + $expiredIds[] = $getId($key); + } + } + return $byLifetime; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + } + /** + * @param string $namespace + * @param int $defaultLifetime + * @param string $version + * @param string $directory + * + * @return AdapterInterface + */ + public static function createSystemCache($namespace, $defaultLifetime, $version, $directory, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger = null) + { + if (null === self::$apcuSupported) { + self::$apcuSupported = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter::isSupported(); + } + if (!self::$apcuSupported && null === self::$phpFilesSupported) { + self::$phpFilesSupported = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpFilesAdapter::isSupported(); + } + if (self::$phpFilesSupported) { + $opcache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpFilesAdapter($namespace, $defaultLifetime, $directory); + if (null !== $logger) { + $opcache->setLogger($logger); + } + return $opcache; + } + $fs = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter($namespace, $defaultLifetime, $directory); + if (null !== $logger) { + $fs->setLogger($logger); + } + if (!self::$apcuSupported) { + return $fs; + } + $apcu = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter($namespace, (int) $defaultLifetime / 5, $version); + if ('cli' === \PHP_SAPI && !\filter_var(\ini_get('apc.enable_cli'), \FILTER_VALIDATE_BOOLEAN)) { + $apcu->setLogger(new \_PhpScoper5ea00cc67502b\Psr\Log\NullLogger()); + } elseif (null !== $logger) { + $apcu->setLogger($logger); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([$apcu, $fs]); + } + public static function createConnection($dsn, array $options = []) + { + if (!\is_string($dsn)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('The "%s()" method expect argument #1 to be string, "%s" given.', __METHOD__, \gettype($dsn))); + } + if (0 === \strpos($dsn, 'redis://')) { + return \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection($dsn, $options); + } + if (0 === \strpos($dsn, 'memcached://')) { + return \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection($dsn, $options); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Unsupported DSN: "%s".', $dsn)); + } + /** + * {@inheritdoc} + */ + public function getItem($key) + { + if ($this->deferred) { + $this->commit(); + } + $id = $this->getId($key); + $f = $this->createCacheItem; + $isHit = \false; + $value = null; + try { + foreach ($this->doFetch([$id]) as $value) { + $isHit = \true; + } + } catch (\Exception $e) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch key "{key}"', ['key' => $key, 'exception' => $e]); + } + return $f($key, $value, $isHit); + } + /** + * {@inheritdoc} + */ + public function getItems(array $keys = []) + { + if ($this->deferred) { + $this->commit(); + } + $ids = []; + foreach ($keys as $key) { + $ids[] = $this->getId($key); + } + try { + $items = $this->doFetch($ids); + } catch (\Exception $e) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch requested items', ['keys' => $keys, 'exception' => $e]); + $items = []; + } + $ids = \array_combine($ids, $keys); + return $this->generateItems($items, $ids); + } + /** + * {@inheritdoc} + */ + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { + return \false; + } + $this->deferred[$item->getKey()] = $item; + return $this->commit(); + } + /** + * {@inheritdoc} + */ + public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { + return \false; + } + $this->deferred[$item->getKey()] = $item; + return \true; + } + /** + * {@inheritdoc} + */ + public function commit() + { + $ok = \true; + $byLifetime = $this->mergeByLifetime; + $byLifetime = $byLifetime($this->deferred, $this->namespace, $expiredIds); + $retry = $this->deferred = []; + if ($expiredIds) { + $this->doDelete($expiredIds); + } + foreach ($byLifetime as $lifetime => $values) { + try { + $e = $this->doSave($values, $lifetime); + } catch (\Exception $e) { + } + if (\true === $e || [] === $e) { + continue; + } + if (\is_array($e) || 1 === \count($values)) { + foreach (\is_array($e) ? $e : \array_keys($values) as $id) { + $ok = \false; + $v = $values[$id]; + $type = \is_object($v) ? \get_class($v) : \gettype($v); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to save key "{key}" ({type})', ['key' => \substr($id, \strlen($this->namespace)), 'type' => $type, 'exception' => $e instanceof \Exception ? $e : null]); + } + } else { + foreach ($values as $id => $v) { + $retry[$lifetime][] = $id; + } + } + } + // When bulk-save failed, retry each item individually + foreach ($retry as $lifetime => $ids) { + foreach ($ids as $id) { + try { + $v = $byLifetime[$lifetime][$id]; + $e = $this->doSave([$id => $v], $lifetime); + } catch (\Exception $e) { + } + if (\true === $e || [] === $e) { + continue; + } + $ok = \false; + $type = \is_object($v) ? \get_class($v) : \gettype($v); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to save key "{key}" ({type})', ['key' => \substr($id, \strlen($this->namespace)), 'type' => $type, 'exception' => $e instanceof \Exception ? $e : null]); + } + } + return $ok; + } + public function __sleep() + { + throw new \BadMethodCallException('Cannot serialize ' . __CLASS__); + } + public function __wakeup() + { + throw new \BadMethodCallException('Cannot unserialize ' . __CLASS__); + } + public function __destruct() + { + if ($this->deferred) { + $this->commit(); + } + } + private function generateItems($items, &$keys) + { + $f = $this->createCacheItem; + try { + foreach ($items as $id => $value) { + if (!isset($keys[$id])) { + $id = \key($keys); + } + $key = $keys[$id]; + unset($keys[$id]); + (yield $key => $f($key, $value, \true)); + } + } catch (\Exception $e) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch requested items', ['keys' => \array_values($keys), 'exception' => $e]); + } + foreach ($keys as $key) { + (yield $key => $f($key, null, \false)); + } + } +} diff --git a/vendor/symfony/cache/Adapter/AdapterInterface.php b/vendor/symfony/cache/Adapter/AdapterInterface.php index 5870450f0..63cb16f7d 100644 --- a/vendor/symfony/cache/Adapter/AdapterInterface.php +++ b/vendor/symfony/cache/Adapter/AdapterInterface.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -/** - * Interface for adapters managing instances of Symfony's CacheItem. - * - * @author Kévin Dunglas - */ -interface AdapterInterface extends \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface -{ - /** - * {@inheritdoc} - * - * @return CacheItem - */ - public function getItem($key); - /** - * {@inheritdoc} - * - * @return \Traversable|CacheItem[] - */ - public function getItems(array $keys = []); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +/** + * Interface for adapters managing instances of Symfony's CacheItem. + * + * @author Kévin Dunglas + */ +interface AdapterInterface extends \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface +{ + /** + * {@inheritdoc} + * + * @return CacheItem + */ + public function getItem($key); + /** + * {@inheritdoc} + * + * @return \Traversable|CacheItem[] + */ + public function getItems(array $keys = []); +} diff --git a/vendor/symfony/cache/Adapter/ApcuAdapter.php b/vendor/symfony/cache/Adapter/ApcuAdapter.php index 7b19c74f7..422e57e70 100644 --- a/vendor/symfony/cache/Adapter/ApcuAdapter.php +++ b/vendor/symfony/cache/Adapter/ApcuAdapter.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ApcuTrait; -class ApcuAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter -{ - use ApcuTrait; - /** - * @param string $namespace - * @param int $defaultLifetime - * @param string|null $version - * - * @throws CacheException if APCu is not enabled - */ - public function __construct($namespace = '', $defaultLifetime = 0, $version = null) - { - $this->init($namespace, $defaultLifetime, $version); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ApcuTrait; +class ApcuAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter +{ + use ApcuTrait; + /** + * @param string $namespace + * @param int $defaultLifetime + * @param string|null $version + * + * @throws CacheException if APCu is not enabled + */ + public function __construct($namespace = '', $defaultLifetime = 0, $version = null) + { + $this->init($namespace, $defaultLifetime, $version); + } +} diff --git a/vendor/symfony/cache/Adapter/ArrayAdapter.php b/vendor/symfony/cache/Adapter/ArrayAdapter.php index 5c7ba26fb..133fda43f 100644 --- a/vendor/symfony/cache/Adapter/ArrayAdapter.php +++ b/vendor/symfony/cache/Adapter/ArrayAdapter.php @@ -1,132 +1,132 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ArrayTrait; -/** - * @author Nicolas Grekas - */ -class ArrayAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - use ArrayTrait; - private $createCacheItem; - /** - * @param int $defaultLifetime - * @param bool $storeSerialized Disabling serialization can lead to cache corruptions when storing mutable values but increases performance otherwise - */ - public function __construct($defaultLifetime = 0, $storeSerialized = \true) - { - $this->storeSerialized = $storeSerialized; - $this->createCacheItem = \Closure::bind(static function ($key, $value, $isHit) use($defaultLifetime) { - $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); - $item->key = $key; - $item->value = $value; - $item->isHit = $isHit; - $item->defaultLifetime = $defaultLifetime; - return $item; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - } - /** - * {@inheritdoc} - */ - public function getItem($key) - { - $isHit = $this->hasItem($key); - try { - if (!$isHit) { - $this->values[$key] = $value = null; - } elseif (!$this->storeSerialized) { - $value = $this->values[$key]; - } elseif ('b:0;' === ($value = $this->values[$key])) { - $value = \false; - } elseif (\false === ($value = \unserialize($value))) { - $this->values[$key] = $value = null; - $isHit = \false; - } - } catch (\Exception $e) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to unserialize key "{key}"', ['key' => $key, 'exception' => $e]); - $this->values[$key] = $value = null; - $isHit = \false; - } - $f = $this->createCacheItem; - return $f($key, $value, $isHit); - } - /** - * {@inheritdoc} - */ - public function getItems(array $keys = []) - { - foreach ($keys as $key) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - } - return $this->generateItems($keys, \time(), $this->createCacheItem); - } - /** - * {@inheritdoc} - */ - public function deleteItems(array $keys) - { - foreach ($keys as $key) { - $this->deleteItem($key); - } - return \true; - } - /** - * {@inheritdoc} - */ - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { - return \false; - } - $item = (array) $item; - $key = $item["\0*\0key"]; - $value = $item["\0*\0value"]; - $expiry = $item["\0*\0expiry"]; - if (null !== $expiry && $expiry <= \time()) { - $this->deleteItem($key); - return \true; - } - if ($this->storeSerialized) { - try { - $value = \serialize($value); - } catch (\Exception $e) { - $type = \is_object($value) ? \get_class($value) : \gettype($value); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to save key "{key}" ({type})', ['key' => $key, 'type' => $type, 'exception' => $e]); - return \false; - } - } - if (null === $expiry && 0 < $item["\0*\0defaultLifetime"]) { - $expiry = \time() + $item["\0*\0defaultLifetime"]; - } - $this->values[$key] = $value; - $this->expiries[$key] = null !== $expiry ? $expiry : \PHP_INT_MAX; - return \true; - } - /** - * {@inheritdoc} - */ - public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - return $this->save($item); - } - /** - * {@inheritdoc} - */ - public function commit() - { - return \true; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ArrayTrait; +/** + * @author Nicolas Grekas + */ +class ArrayAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + use ArrayTrait; + private $createCacheItem; + /** + * @param int $defaultLifetime + * @param bool $storeSerialized Disabling serialization can lead to cache corruptions when storing mutable values but increases performance otherwise + */ + public function __construct($defaultLifetime = 0, $storeSerialized = \true) + { + $this->storeSerialized = $storeSerialized; + $this->createCacheItem = \Closure::bind(static function ($key, $value, $isHit) use($defaultLifetime) { + $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); + $item->key = $key; + $item->value = $value; + $item->isHit = $isHit; + $item->defaultLifetime = $defaultLifetime; + return $item; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + } + /** + * {@inheritdoc} + */ + public function getItem($key) + { + $isHit = $this->hasItem($key); + try { + if (!$isHit) { + $this->values[$key] = $value = null; + } elseif (!$this->storeSerialized) { + $value = $this->values[$key]; + } elseif ('b:0;' === ($value = $this->values[$key])) { + $value = \false; + } elseif (\false === ($value = \unserialize($value))) { + $this->values[$key] = $value = null; + $isHit = \false; + } + } catch (\Exception $e) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to unserialize key "{key}"', ['key' => $key, 'exception' => $e]); + $this->values[$key] = $value = null; + $isHit = \false; + } + $f = $this->createCacheItem; + return $f($key, $value, $isHit); + } + /** + * {@inheritdoc} + */ + public function getItems(array $keys = []) + { + foreach ($keys as $key) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + } + return $this->generateItems($keys, \time(), $this->createCacheItem); + } + /** + * {@inheritdoc} + */ + public function deleteItems(array $keys) + { + foreach ($keys as $key) { + $this->deleteItem($key); + } + return \true; + } + /** + * {@inheritdoc} + */ + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { + return \false; + } + $item = (array) $item; + $key = $item["\0*\0key"]; + $value = $item["\0*\0value"]; + $expiry = $item["\0*\0expiry"]; + if (null !== $expiry && $expiry <= \time()) { + $this->deleteItem($key); + return \true; + } + if ($this->storeSerialized) { + try { + $value = \serialize($value); + } catch (\Exception $e) { + $type = \is_object($value) ? \get_class($value) : \gettype($value); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to save key "{key}" ({type})', ['key' => $key, 'type' => $type, 'exception' => $e]); + return \false; + } + } + if (null === $expiry && 0 < $item["\0*\0defaultLifetime"]) { + $expiry = \time() + $item["\0*\0defaultLifetime"]; + } + $this->values[$key] = $value; + $this->expiries[$key] = null !== $expiry ? $expiry : \PHP_INT_MAX; + return \true; + } + /** + * {@inheritdoc} + */ + public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + return $this->save($item); + } + /** + * {@inheritdoc} + */ + public function commit() + { + return \true; + } +} diff --git a/vendor/symfony/cache/Adapter/ChainAdapter.php b/vendor/symfony/cache/Adapter/ChainAdapter.php index 38b747426..e1fba358e 100644 --- a/vendor/symfony/cache/Adapter/ChainAdapter.php +++ b/vendor/symfony/cache/Adapter/ChainAdapter.php @@ -1,225 +1,225 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -/** - * Chains several adapters together. - * - * Cached items are fetched from the first adapter having them in its data store. - * They are saved and deleted in all adapters at once. - * - * @author Kévin Dunglas - */ -class ChainAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - private $adapters = []; - private $adapterCount; - private $syncItem; - /** - * @param CacheItemPoolInterface[] $adapters The ordered list of adapters used to fetch cached items - * @param int $defaultLifetime The default lifetime of items propagated from lower adapters to upper ones - */ - public function __construct(array $adapters, $defaultLifetime = 0) - { - if (!$adapters) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException('At least one adapter must be specified.'); - } - foreach ($adapters as $adapter) { - if (!$adapter instanceof \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('The class "%s" does not implement the "%s" interface.', \get_class($adapter), \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface::class)); - } - if ($adapter instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface) { - $this->adapters[] = $adapter; - } else { - $this->adapters[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter($adapter); - } - } - $this->adapterCount = \count($this->adapters); - $this->syncItem = \Closure::bind(static function ($sourceItem, $item) use($defaultLifetime) { - $item->value = $sourceItem->value; - $item->expiry = $sourceItem->expiry; - $item->isHit = $sourceItem->isHit; - if (0 < $sourceItem->defaultLifetime && $sourceItem->defaultLifetime < $defaultLifetime) { - $defaultLifetime = $sourceItem->defaultLifetime; - } - if (0 < $defaultLifetime && ($item->defaultLifetime <= 0 || $defaultLifetime < $item->defaultLifetime)) { - $item->defaultLifetime = $defaultLifetime; - } - return $item; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - } - /** - * {@inheritdoc} - */ - public function getItem($key) - { - $syncItem = $this->syncItem; - $misses = []; - foreach ($this->adapters as $i => $adapter) { - $item = $adapter->getItem($key); - if ($item->isHit()) { - while (0 <= --$i) { - $this->adapters[$i]->save($syncItem($item, $misses[$i])); - } - return $item; - } - $misses[$i] = $item; - } - return $item; - } - /** - * {@inheritdoc} - */ - public function getItems(array $keys = []) - { - return $this->generateItems($this->adapters[0]->getItems($keys), 0); - } - private function generateItems($items, $adapterIndex) - { - $missing = []; - $misses = []; - $nextAdapterIndex = $adapterIndex + 1; - $nextAdapter = isset($this->adapters[$nextAdapterIndex]) ? $this->adapters[$nextAdapterIndex] : null; - foreach ($items as $k => $item) { - if (!$nextAdapter || $item->isHit()) { - (yield $k => $item); - } else { - $missing[] = $k; - $misses[$k] = $item; - } - } - if ($missing) { - $syncItem = $this->syncItem; - $adapter = $this->adapters[$adapterIndex]; - $items = $this->generateItems($nextAdapter->getItems($missing), $nextAdapterIndex); - foreach ($items as $k => $item) { - if ($item->isHit()) { - $adapter->save($syncItem($item, $misses[$k])); - } - (yield $k => $item); - } - } - } - /** - * {@inheritdoc} - */ - public function hasItem($key) - { - foreach ($this->adapters as $adapter) { - if ($adapter->hasItem($key)) { - return \true; - } - } - return \false; - } - /** - * {@inheritdoc} - */ - public function clear() - { - $cleared = \true; - $i = $this->adapterCount; - while ($i--) { - $cleared = $this->adapters[$i]->clear() && $cleared; - } - return $cleared; - } - /** - * {@inheritdoc} - */ - public function deleteItem($key) - { - $deleted = \true; - $i = $this->adapterCount; - while ($i--) { - $deleted = $this->adapters[$i]->deleteItem($key) && $deleted; - } - return $deleted; - } - /** - * {@inheritdoc} - */ - public function deleteItems(array $keys) - { - $deleted = \true; - $i = $this->adapterCount; - while ($i--) { - $deleted = $this->adapters[$i]->deleteItems($keys) && $deleted; - } - return $deleted; - } - /** - * {@inheritdoc} - */ - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - $saved = \true; - $i = $this->adapterCount; - while ($i--) { - $saved = $this->adapters[$i]->save($item) && $saved; - } - return $saved; - } - /** - * {@inheritdoc} - */ - public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - $saved = \true; - $i = $this->adapterCount; - while ($i--) { - $saved = $this->adapters[$i]->saveDeferred($item) && $saved; - } - return $saved; - } - /** - * {@inheritdoc} - */ - public function commit() - { - $committed = \true; - $i = $this->adapterCount; - while ($i--) { - $committed = $this->adapters[$i]->commit() && $committed; - } - return $committed; - } - /** - * {@inheritdoc} - */ - public function prune() - { - $pruned = \true; - foreach ($this->adapters as $adapter) { - if ($adapter instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { - $pruned = $adapter->prune() && $pruned; - } - } - return $pruned; - } - /** - * {@inheritdoc} - */ - public function reset() - { - foreach ($this->adapters as $adapter) { - if ($adapter instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { - $adapter->reset(); - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +/** + * Chains several adapters together. + * + * Cached items are fetched from the first adapter having them in its data store. + * They are saved and deleted in all adapters at once. + * + * @author Kévin Dunglas + */ +class ChainAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + private $adapters = []; + private $adapterCount; + private $syncItem; + /** + * @param CacheItemPoolInterface[] $adapters The ordered list of adapters used to fetch cached items + * @param int $defaultLifetime The default lifetime of items propagated from lower adapters to upper ones + */ + public function __construct(array $adapters, $defaultLifetime = 0) + { + if (!$adapters) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException('At least one adapter must be specified.'); + } + foreach ($adapters as $adapter) { + if (!$adapter instanceof \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('The class "%s" does not implement the "%s" interface.', \get_class($adapter), \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface::class)); + } + if ($adapter instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface) { + $this->adapters[] = $adapter; + } else { + $this->adapters[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter($adapter); + } + } + $this->adapterCount = \count($this->adapters); + $this->syncItem = \Closure::bind(static function ($sourceItem, $item) use($defaultLifetime) { + $item->value = $sourceItem->value; + $item->expiry = $sourceItem->expiry; + $item->isHit = $sourceItem->isHit; + if (0 < $sourceItem->defaultLifetime && $sourceItem->defaultLifetime < $defaultLifetime) { + $defaultLifetime = $sourceItem->defaultLifetime; + } + if (0 < $defaultLifetime && ($item->defaultLifetime <= 0 || $defaultLifetime < $item->defaultLifetime)) { + $item->defaultLifetime = $defaultLifetime; + } + return $item; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + } + /** + * {@inheritdoc} + */ + public function getItem($key) + { + $syncItem = $this->syncItem; + $misses = []; + foreach ($this->adapters as $i => $adapter) { + $item = $adapter->getItem($key); + if ($item->isHit()) { + while (0 <= --$i) { + $this->adapters[$i]->save($syncItem($item, $misses[$i])); + } + return $item; + } + $misses[$i] = $item; + } + return $item; + } + /** + * {@inheritdoc} + */ + public function getItems(array $keys = []) + { + return $this->generateItems($this->adapters[0]->getItems($keys), 0); + } + private function generateItems($items, $adapterIndex) + { + $missing = []; + $misses = []; + $nextAdapterIndex = $adapterIndex + 1; + $nextAdapter = isset($this->adapters[$nextAdapterIndex]) ? $this->adapters[$nextAdapterIndex] : null; + foreach ($items as $k => $item) { + if (!$nextAdapter || $item->isHit()) { + (yield $k => $item); + } else { + $missing[] = $k; + $misses[$k] = $item; + } + } + if ($missing) { + $syncItem = $this->syncItem; + $adapter = $this->adapters[$adapterIndex]; + $items = $this->generateItems($nextAdapter->getItems($missing), $nextAdapterIndex); + foreach ($items as $k => $item) { + if ($item->isHit()) { + $adapter->save($syncItem($item, $misses[$k])); + } + (yield $k => $item); + } + } + } + /** + * {@inheritdoc} + */ + public function hasItem($key) + { + foreach ($this->adapters as $adapter) { + if ($adapter->hasItem($key)) { + return \true; + } + } + return \false; + } + /** + * {@inheritdoc} + */ + public function clear() + { + $cleared = \true; + $i = $this->adapterCount; + while ($i--) { + $cleared = $this->adapters[$i]->clear() && $cleared; + } + return $cleared; + } + /** + * {@inheritdoc} + */ + public function deleteItem($key) + { + $deleted = \true; + $i = $this->adapterCount; + while ($i--) { + $deleted = $this->adapters[$i]->deleteItem($key) && $deleted; + } + return $deleted; + } + /** + * {@inheritdoc} + */ + public function deleteItems(array $keys) + { + $deleted = \true; + $i = $this->adapterCount; + while ($i--) { + $deleted = $this->adapters[$i]->deleteItems($keys) && $deleted; + } + return $deleted; + } + /** + * {@inheritdoc} + */ + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + $saved = \true; + $i = $this->adapterCount; + while ($i--) { + $saved = $this->adapters[$i]->save($item) && $saved; + } + return $saved; + } + /** + * {@inheritdoc} + */ + public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + $saved = \true; + $i = $this->adapterCount; + while ($i--) { + $saved = $this->adapters[$i]->saveDeferred($item) && $saved; + } + return $saved; + } + /** + * {@inheritdoc} + */ + public function commit() + { + $committed = \true; + $i = $this->adapterCount; + while ($i--) { + $committed = $this->adapters[$i]->commit() && $committed; + } + return $committed; + } + /** + * {@inheritdoc} + */ + public function prune() + { + $pruned = \true; + foreach ($this->adapters as $adapter) { + if ($adapter instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { + $pruned = $adapter->prune() && $pruned; + } + } + return $pruned; + } + /** + * {@inheritdoc} + */ + public function reset() + { + foreach ($this->adapters as $adapter) { + if ($adapter instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { + $adapter->reset(); + } + } + } +} diff --git a/vendor/symfony/cache/Adapter/DoctrineAdapter.php b/vendor/symfony/cache/Adapter/DoctrineAdapter.php index 170ae20f8..129beedc4 100644 --- a/vendor/symfony/cache/Adapter/DoctrineAdapter.php +++ b/vendor/symfony/cache/Adapter/DoctrineAdapter.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\DoctrineTrait; -class DoctrineAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter -{ - use DoctrineTrait; - /** - * @param string $namespace - * @param int $defaultLifetime - */ - public function __construct(\_PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider $provider, $namespace = '', $defaultLifetime = 0) - { - parent::__construct('', $defaultLifetime); - $this->provider = $provider; - $provider->setNamespace($namespace); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\DoctrineTrait; +class DoctrineAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter +{ + use DoctrineTrait; + /** + * @param string $namespace + * @param int $defaultLifetime + */ + public function __construct(\_PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider $provider, $namespace = '', $defaultLifetime = 0) + { + parent::__construct('', $defaultLifetime); + $this->provider = $provider; + $provider->setNamespace($namespace); + } +} diff --git a/vendor/symfony/cache/Adapter/FilesystemAdapter.php b/vendor/symfony/cache/Adapter/FilesystemAdapter.php index dba482e91..d67247eec 100644 --- a/vendor/symfony/cache/Adapter/FilesystemAdapter.php +++ b/vendor/symfony/cache/Adapter/FilesystemAdapter.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\FilesystemTrait; -class FilesystemAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface -{ - use FilesystemTrait; - /** - * @param string $namespace - * @param int $defaultLifetime - * @param string|null $directory - */ - public function __construct($namespace = '', $defaultLifetime = 0, $directory = null) - { - parent::__construct('', $defaultLifetime); - $this->init($namespace, $directory); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\FilesystemTrait; +class FilesystemAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface +{ + use FilesystemTrait; + /** + * @param string $namespace + * @param int $defaultLifetime + * @param string|null $directory + */ + public function __construct($namespace = '', $defaultLifetime = 0, $directory = null) + { + parent::__construct('', $defaultLifetime); + $this->init($namespace, $directory); + } +} diff --git a/vendor/symfony/cache/Adapter/MemcachedAdapter.php b/vendor/symfony/cache/Adapter/MemcachedAdapter.php index 1f5c969f3..50075f2f8 100644 --- a/vendor/symfony/cache/Adapter/MemcachedAdapter.php +++ b/vendor/symfony/cache/Adapter/MemcachedAdapter.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\MemcachedTrait; -class MemcachedAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter -{ - use MemcachedTrait; - protected $maxIdLength = 250; - /** - * Using a MemcachedAdapter with a TagAwareAdapter for storing tags is discouraged. - * Using a RedisAdapter is recommended instead. If you cannot do otherwise, be aware that: - * - the Memcached::OPT_BINARY_PROTOCOL must be enabled - * (that's the default when using MemcachedAdapter::createConnection()); - * - tags eviction by Memcached's LRU algorithm will break by-tags invalidation; - * your Memcached memory should be large enough to never trigger LRU. - * - * Using a MemcachedAdapter as a pure items store is fine. - */ - public function __construct(\_PhpScoper5ea00cc67502b\Memcached $client, $namespace = '', $defaultLifetime = 0) - { - $this->init($client, $namespace, $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\MemcachedTrait; +class MemcachedAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter +{ + use MemcachedTrait; + protected $maxIdLength = 250; + /** + * Using a MemcachedAdapter with a TagAwareAdapter for storing tags is discouraged. + * Using a RedisAdapter is recommended instead. If you cannot do otherwise, be aware that: + * - the Memcached::OPT_BINARY_PROTOCOL must be enabled + * (that's the default when using MemcachedAdapter::createConnection()); + * - tags eviction by Memcached's LRU algorithm will break by-tags invalidation; + * your Memcached memory should be large enough to never trigger LRU. + * + * Using a MemcachedAdapter as a pure items store is fine. + */ + public function __construct(\_PhpScoper5ea00cc67502b\Memcached $client, $namespace = '', $defaultLifetime = 0) + { + $this->init($client, $namespace, $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Adapter/NullAdapter.php b/vendor/symfony/cache/Adapter/NullAdapter.php index 3f07146d4..5a3e134d8 100644 --- a/vendor/symfony/cache/Adapter/NullAdapter.php +++ b/vendor/symfony/cache/Adapter/NullAdapter.php @@ -1,101 +1,101 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -/** - * @author Titouan Galopin - */ -class NullAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface -{ - private $createCacheItem; - public function __construct() - { - $this->createCacheItem = \Closure::bind(function ($key) { - $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); - $item->key = $key; - $item->isHit = \false; - return $item; - }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - } - /** - * {@inheritdoc} - */ - public function getItem($key) - { - $f = $this->createCacheItem; - return $f($key); - } - /** - * {@inheritdoc} - */ - public function getItems(array $keys = []) - { - return $this->generateItems($keys); - } - /** - * {@inheritdoc} - */ - public function hasItem($key) - { - return \false; - } - /** - * {@inheritdoc} - */ - public function clear() - { - return \true; - } - /** - * {@inheritdoc} - */ - public function deleteItem($key) - { - return \true; - } - /** - * {@inheritdoc} - */ - public function deleteItems(array $keys) - { - return \true; - } - /** - * {@inheritdoc} - */ - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - return \false; - } - /** - * {@inheritdoc} - */ - public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - return \false; - } - /** - * {@inheritdoc} - */ - public function commit() - { - return \false; - } - private function generateItems(array $keys) - { - $f = $this->createCacheItem; - foreach ($keys as $key) { - (yield $key => $f($key)); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +/** + * @author Titouan Galopin + */ +class NullAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface +{ + private $createCacheItem; + public function __construct() + { + $this->createCacheItem = \Closure::bind(function ($key) { + $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); + $item->key = $key; + $item->isHit = \false; + return $item; + }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + } + /** + * {@inheritdoc} + */ + public function getItem($key) + { + $f = $this->createCacheItem; + return $f($key); + } + /** + * {@inheritdoc} + */ + public function getItems(array $keys = []) + { + return $this->generateItems($keys); + } + /** + * {@inheritdoc} + */ + public function hasItem($key) + { + return \false; + } + /** + * {@inheritdoc} + */ + public function clear() + { + return \true; + } + /** + * {@inheritdoc} + */ + public function deleteItem($key) + { + return \true; + } + /** + * {@inheritdoc} + */ + public function deleteItems(array $keys) + { + return \true; + } + /** + * {@inheritdoc} + */ + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + return \false; + } + /** + * {@inheritdoc} + */ + public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + return \false; + } + /** + * {@inheritdoc} + */ + public function commit() + { + return \false; + } + private function generateItems(array $keys) + { + $f = $this->createCacheItem; + foreach ($keys as $key) { + (yield $key => $f($key)); + } + } +} diff --git a/vendor/symfony/cache/Adapter/PdoAdapter.php b/vendor/symfony/cache/Adapter/PdoAdapter.php index e976dae89..63d31b651 100644 --- a/vendor/symfony/cache/Adapter/PdoAdapter.php +++ b/vendor/symfony/cache/Adapter/PdoAdapter.php @@ -1,49 +1,49 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Doctrine\DBAL\Connection; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PdoTrait; -class PdoAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface -{ - use PdoTrait; - protected $maxIdLength = 255; - /** - * You can either pass an existing database connection as PDO instance or - * a Doctrine DBAL Connection or a DSN string that will be used to - * lazy-connect to the database when the cache is actually used. - * - * List of available options: - * * db_table: The name of the table [default: cache_items] - * * db_id_col: The column where to store the cache id [default: item_id] - * * db_data_col: The column where to store the cache data [default: item_data] - * * db_lifetime_col: The column where to store the lifetime [default: item_lifetime] - * * db_time_col: The column where to store the timestamp [default: item_time] - * * db_username: The username when lazy-connect [default: ''] - * * db_password: The password when lazy-connect [default: ''] - * * db_connection_options: An array of driver-specific connection options [default: []] - * - * @param \PDO|Connection|string $connOrDsn A \PDO or Connection instance or DSN string or null - * @param string $namespace - * @param int $defaultLifetime - * @param array $options An associative array of options - * - * @throws InvalidArgumentException When first argument is not PDO nor Connection nor string - * @throws InvalidArgumentException When PDO error mode is not PDO::ERRMODE_EXCEPTION - * @throws InvalidArgumentException When namespace contains invalid characters - */ - public function __construct($connOrDsn, $namespace = '', $defaultLifetime = 0, array $options = []) - { - $this->init($connOrDsn, $namespace, $defaultLifetime, $options); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Doctrine\DBAL\Connection; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PdoTrait; +class PdoAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface +{ + use PdoTrait; + protected $maxIdLength = 255; + /** + * You can either pass an existing database connection as PDO instance or + * a Doctrine DBAL Connection or a DSN string that will be used to + * lazy-connect to the database when the cache is actually used. + * + * List of available options: + * * db_table: The name of the table [default: cache_items] + * * db_id_col: The column where to store the cache id [default: item_id] + * * db_data_col: The column where to store the cache data [default: item_data] + * * db_lifetime_col: The column where to store the lifetime [default: item_lifetime] + * * db_time_col: The column where to store the timestamp [default: item_time] + * * db_username: The username when lazy-connect [default: ''] + * * db_password: The password when lazy-connect [default: ''] + * * db_connection_options: An array of driver-specific connection options [default: []] + * + * @param \PDO|Connection|string $connOrDsn A \PDO or Connection instance or DSN string or null + * @param string $namespace + * @param int $defaultLifetime + * @param array $options An associative array of options + * + * @throws InvalidArgumentException When first argument is not PDO nor Connection nor string + * @throws InvalidArgumentException When PDO error mode is not PDO::ERRMODE_EXCEPTION + * @throws InvalidArgumentException When namespace contains invalid characters + */ + public function __construct($connOrDsn, $namespace = '', $defaultLifetime = 0, array $options = []) + { + $this->init($connOrDsn, $namespace, $defaultLifetime, $options); + } +} diff --git a/vendor/symfony/cache/Adapter/PhpArrayAdapter.php b/vendor/symfony/cache/Adapter/PhpArrayAdapter.php index 5547a0919..d7aaa7fc7 100644 --- a/vendor/symfony/cache/Adapter/PhpArrayAdapter.php +++ b/vendor/symfony/cache/Adapter/PhpArrayAdapter.php @@ -1,259 +1,259 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PhpArrayTrait; -/** - * Caches items at warm up time using a PHP array that is stored in shared memory by OPCache since PHP 7.0. - * Warmed up items are read-only and run-time discovered items are cached using a fallback adapter. - * - * @author Titouan Galopin - * @author Nicolas Grekas - */ -class PhpArrayAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - use PhpArrayTrait; - private $createCacheItem; - /** - * @param string $file The PHP file were values are cached - * @param AdapterInterface $fallbackPool A pool to fallback on when an item is not hit - */ - public function __construct($file, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface $fallbackPool) - { - $this->file = $file; - $this->pool = $fallbackPool; - $this->zendDetectUnicode = \filter_var(\ini_get('zend.detect_unicode'), \FILTER_VALIDATE_BOOLEAN); - $this->createCacheItem = \Closure::bind(static function ($key, $value, $isHit) { - $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); - $item->key = $key; - $item->value = $value; - $item->isHit = $isHit; - return $item; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - } - /** - * This adapter should only be used on PHP 7.0+ to take advantage of how PHP - * stores arrays in its latest versions. This factory method decorates the given - * fallback pool with this adapter only if the current PHP version is supported. - * - * @param string $file The PHP file were values are cached - * @param CacheItemPoolInterface $fallbackPool A pool to fallback on when an item is not hit - * - * @return CacheItemPoolInterface - */ - public static function create($file, \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $fallbackPool) - { - if (\PHP_VERSION_ID >= 70000) { - if (!$fallbackPool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface) { - $fallbackPool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter($fallbackPool); - } - return new static($file, $fallbackPool); - } - return $fallbackPool; - } - /** - * {@inheritdoc} - */ - public function getItem($key) - { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if (null === $this->values) { - $this->initialize(); - } - if (!isset($this->values[$key])) { - return $this->pool->getItem($key); - } - $value = $this->values[$key]; - $isHit = \true; - if ('N;' === $value) { - $value = null; - } elseif (\is_string($value) && isset($value[2]) && ':' === $value[1]) { - try { - $e = null; - $value = \unserialize($value); - } catch (\Error $e) { - } catch (\Exception $e) { - } - if (null !== $e) { - $value = null; - $isHit = \false; - } - } - $f = $this->createCacheItem; - return $f($key, $value, $isHit); - } - /** - * {@inheritdoc} - */ - public function getItems(array $keys = []) - { - foreach ($keys as $key) { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - } - if (null === $this->values) { - $this->initialize(); - } - return $this->generateItems($keys); - } - /** - * {@inheritdoc} - */ - public function hasItem($key) - { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if (null === $this->values) { - $this->initialize(); - } - return isset($this->values[$key]) || $this->pool->hasItem($key); - } - /** - * {@inheritdoc} - */ - public function deleteItem($key) - { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if (null === $this->values) { - $this->initialize(); - } - return !isset($this->values[$key]) && $this->pool->deleteItem($key); - } - /** - * {@inheritdoc} - */ - public function deleteItems(array $keys) - { - $deleted = \true; - $fallbackKeys = []; - foreach ($keys as $key) { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if (isset($this->values[$key])) { - $deleted = \false; - } else { - $fallbackKeys[] = $key; - } - } - if (null === $this->values) { - $this->initialize(); - } - if ($fallbackKeys) { - $deleted = $this->pool->deleteItems($fallbackKeys) && $deleted; - } - return $deleted; - } - /** - * {@inheritdoc} - */ - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - if (null === $this->values) { - $this->initialize(); - } - return !isset($this->values[$item->getKey()]) && $this->pool->save($item); - } - /** - * {@inheritdoc} - */ - public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - if (null === $this->values) { - $this->initialize(); - } - return !isset($this->values[$item->getKey()]) && $this->pool->saveDeferred($item); - } - /** - * {@inheritdoc} - */ - public function commit() - { - return $this->pool->commit(); - } - /** - * @return \Generator - */ - private function generateItems(array $keys) - { - $f = $this->createCacheItem; - $fallbackKeys = []; - foreach ($keys as $key) { - if (isset($this->values[$key])) { - $value = $this->values[$key]; - if ('N;' === $value) { - (yield $key => $f($key, null, \true)); - } elseif (\is_string($value) && isset($value[2]) && ':' === $value[1]) { - try { - (yield $key => $f($key, \unserialize($value), \true)); - } catch (\Error $e) { - (yield $key => $f($key, null, \false)); - } catch (\Exception $e) { - (yield $key => $f($key, null, \false)); - } - } else { - (yield $key => $f($key, $value, \true)); - } - } else { - $fallbackKeys[] = $key; - } - } - if ($fallbackKeys) { - foreach ($this->pool->getItems($fallbackKeys) as $key => $item) { - (yield $key => $item); - } - } - } - /** - * @throws \ReflectionException When $class is not found and is required - * - * @internal to be removed in Symfony 5.0 - */ - public static function throwOnRequiredClass($class) - { - $e = new \ReflectionException("Class {$class} does not exist"); - $trace = \debug_backtrace(); - $autoloadFrame = ['function' => 'spl_autoload_call', 'args' => [$class]]; - $i = 1 + \array_search($autoloadFrame, $trace, \true); - if (isset($trace[$i]['function']) && !isset($trace[$i]['class'])) { - switch ($trace[$i]['function']) { - case 'get_class_methods': - case 'get_class_vars': - case 'get_parent_class': - case 'is_a': - case 'is_subclass_of': - case 'class_exists': - case 'class_implements': - case 'class_parents': - case 'trait_exists': - case 'defined': - case 'interface_exists': - case 'method_exists': - case 'property_exists': - case 'is_callable': - return; - } - } - throw $e; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PhpArrayTrait; +/** + * Caches items at warm up time using a PHP array that is stored in shared memory by OPCache since PHP 7.0. + * Warmed up items are read-only and run-time discovered items are cached using a fallback adapter. + * + * @author Titouan Galopin + * @author Nicolas Grekas + */ +class PhpArrayAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + use PhpArrayTrait; + private $createCacheItem; + /** + * @param string $file The PHP file were values are cached + * @param AdapterInterface $fallbackPool A pool to fallback on when an item is not hit + */ + public function __construct($file, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface $fallbackPool) + { + $this->file = $file; + $this->pool = $fallbackPool; + $this->zendDetectUnicode = \filter_var(\ini_get('zend.detect_unicode'), \FILTER_VALIDATE_BOOLEAN); + $this->createCacheItem = \Closure::bind(static function ($key, $value, $isHit) { + $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); + $item->key = $key; + $item->value = $value; + $item->isHit = $isHit; + return $item; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + } + /** + * This adapter should only be used on PHP 7.0+ to take advantage of how PHP + * stores arrays in its latest versions. This factory method decorates the given + * fallback pool with this adapter only if the current PHP version is supported. + * + * @param string $file The PHP file were values are cached + * @param CacheItemPoolInterface $fallbackPool A pool to fallback on when an item is not hit + * + * @return CacheItemPoolInterface + */ + public static function create($file, \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $fallbackPool) + { + if (\PHP_VERSION_ID >= 70000) { + if (!$fallbackPool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface) { + $fallbackPool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter($fallbackPool); + } + return new static($file, $fallbackPool); + } + return $fallbackPool; + } + /** + * {@inheritdoc} + */ + public function getItem($key) + { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if (null === $this->values) { + $this->initialize(); + } + if (!isset($this->values[$key])) { + return $this->pool->getItem($key); + } + $value = $this->values[$key]; + $isHit = \true; + if ('N;' === $value) { + $value = null; + } elseif (\is_string($value) && isset($value[2]) && ':' === $value[1]) { + try { + $e = null; + $value = \unserialize($value); + } catch (\Error $e) { + } catch (\Exception $e) { + } + if (null !== $e) { + $value = null; + $isHit = \false; + } + } + $f = $this->createCacheItem; + return $f($key, $value, $isHit); + } + /** + * {@inheritdoc} + */ + public function getItems(array $keys = []) + { + foreach ($keys as $key) { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + } + if (null === $this->values) { + $this->initialize(); + } + return $this->generateItems($keys); + } + /** + * {@inheritdoc} + */ + public function hasItem($key) + { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if (null === $this->values) { + $this->initialize(); + } + return isset($this->values[$key]) || $this->pool->hasItem($key); + } + /** + * {@inheritdoc} + */ + public function deleteItem($key) + { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if (null === $this->values) { + $this->initialize(); + } + return !isset($this->values[$key]) && $this->pool->deleteItem($key); + } + /** + * {@inheritdoc} + */ + public function deleteItems(array $keys) + { + $deleted = \true; + $fallbackKeys = []; + foreach ($keys as $key) { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if (isset($this->values[$key])) { + $deleted = \false; + } else { + $fallbackKeys[] = $key; + } + } + if (null === $this->values) { + $this->initialize(); + } + if ($fallbackKeys) { + $deleted = $this->pool->deleteItems($fallbackKeys) && $deleted; + } + return $deleted; + } + /** + * {@inheritdoc} + */ + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + if (null === $this->values) { + $this->initialize(); + } + return !isset($this->values[$item->getKey()]) && $this->pool->save($item); + } + /** + * {@inheritdoc} + */ + public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + if (null === $this->values) { + $this->initialize(); + } + return !isset($this->values[$item->getKey()]) && $this->pool->saveDeferred($item); + } + /** + * {@inheritdoc} + */ + public function commit() + { + return $this->pool->commit(); + } + /** + * @return \Generator + */ + private function generateItems(array $keys) + { + $f = $this->createCacheItem; + $fallbackKeys = []; + foreach ($keys as $key) { + if (isset($this->values[$key])) { + $value = $this->values[$key]; + if ('N;' === $value) { + (yield $key => $f($key, null, \true)); + } elseif (\is_string($value) && isset($value[2]) && ':' === $value[1]) { + try { + (yield $key => $f($key, \unserialize($value), \true)); + } catch (\Error $e) { + (yield $key => $f($key, null, \false)); + } catch (\Exception $e) { + (yield $key => $f($key, null, \false)); + } + } else { + (yield $key => $f($key, $value, \true)); + } + } else { + $fallbackKeys[] = $key; + } + } + if ($fallbackKeys) { + foreach ($this->pool->getItems($fallbackKeys) as $key => $item) { + (yield $key => $item); + } + } + } + /** + * @throws \ReflectionException When $class is not found and is required + * + * @internal to be removed in Symfony 5.0 + */ + public static function throwOnRequiredClass($class) + { + $e = new \ReflectionException("Class {$class} does not exist"); + $trace = \debug_backtrace(); + $autoloadFrame = ['function' => 'spl_autoload_call', 'args' => [$class]]; + $i = 1 + \array_search($autoloadFrame, $trace, \true); + if (isset($trace[$i]['function']) && !isset($trace[$i]['class'])) { + switch ($trace[$i]['function']) { + case 'get_class_methods': + case 'get_class_vars': + case 'get_parent_class': + case 'is_a': + case 'is_subclass_of': + case 'class_exists': + case 'class_implements': + case 'class_parents': + case 'trait_exists': + case 'defined': + case 'interface_exists': + case 'method_exists': + case 'property_exists': + case 'is_callable': + return; + } + } + throw $e; + } +} diff --git a/vendor/symfony/cache/Adapter/PhpFilesAdapter.php b/vendor/symfony/cache/Adapter/PhpFilesAdapter.php index 12ecac92c..f8b9d26e6 100644 --- a/vendor/symfony/cache/Adapter/PhpFilesAdapter.php +++ b/vendor/symfony/cache/Adapter/PhpFilesAdapter.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PhpFilesTrait; -class PhpFilesAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface -{ - use PhpFilesTrait; - /** - * @param string $namespace - * @param int $defaultLifetime - * @param string|null $directory - * - * @throws CacheException if OPcache is not enabled - */ - public function __construct($namespace = '', $defaultLifetime = 0, $directory = null) - { - if (!static::isSupported()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('OPcache is not enabled.'); - } - parent::__construct('', $defaultLifetime); - $this->init($namespace, $directory); - $e = new \Exception(); - $this->includeHandler = function () use($e) { - throw $e; - }; - $this->zendDetectUnicode = \filter_var(\ini_get('zend.detect_unicode'), \FILTER_VALIDATE_BOOLEAN); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PhpFilesTrait; +class PhpFilesAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface +{ + use PhpFilesTrait; + /** + * @param string $namespace + * @param int $defaultLifetime + * @param string|null $directory + * + * @throws CacheException if OPcache is not enabled + */ + public function __construct($namespace = '', $defaultLifetime = 0, $directory = null) + { + if (!static::isSupported()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('OPcache is not enabled.'); + } + parent::__construct('', $defaultLifetime); + $this->init($namespace, $directory); + $e = new \Exception(); + $this->includeHandler = function () use($e) { + throw $e; + }; + $this->zendDetectUnicode = \filter_var(\ini_get('zend.detect_unicode'), \FILTER_VALIDATE_BOOLEAN); + } +} diff --git a/vendor/symfony/cache/Adapter/ProxyAdapter.php b/vendor/symfony/cache/Adapter/ProxyAdapter.php index 960ea70ef..b84651998 100644 --- a/vendor/symfony/cache/Adapter/ProxyAdapter.php +++ b/vendor/symfony/cache/Adapter/ProxyAdapter.php @@ -1,167 +1,167 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ProxyTrait; -/** - * @author Nicolas Grekas - */ -class ProxyAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - use ProxyTrait; - private $namespace; - private $namespaceLen; - private $createCacheItem; - private $poolHash; - /** - * @param string $namespace - * @param int $defaultLifetime - */ - public function __construct(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $pool, $namespace = '', $defaultLifetime = 0) - { - $this->pool = $pool; - $this->poolHash = $poolHash = \spl_object_hash($pool); - $this->namespace = '' === $namespace ? '' : \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($namespace); - $this->namespaceLen = \strlen($namespace); - $this->createCacheItem = \Closure::bind(static function ($key, $innerItem) use($defaultLifetime, $poolHash) { - $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); - $item->key = $key; - $item->defaultLifetime = $defaultLifetime; - $item->poolHash = $poolHash; - if (null !== $innerItem) { - $item->value = $innerItem->get(); - $item->isHit = $innerItem->isHit(); - $item->innerItem = $innerItem; - $innerItem->set(null); - } - return $item; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - } - /** - * {@inheritdoc} - */ - public function getItem($key) - { - $f = $this->createCacheItem; - $item = $this->pool->getItem($this->getId($key)); - return $f($key, $item); - } - /** - * {@inheritdoc} - */ - public function getItems(array $keys = []) - { - if ($this->namespaceLen) { - foreach ($keys as $i => $key) { - $keys[$i] = $this->getId($key); - } - } - return $this->generateItems($this->pool->getItems($keys)); - } - /** - * {@inheritdoc} - */ - public function hasItem($key) - { - return $this->pool->hasItem($this->getId($key)); - } - /** - * {@inheritdoc} - */ - public function clear() - { - return $this->pool->clear(); - } - /** - * {@inheritdoc} - */ - public function deleteItem($key) - { - return $this->pool->deleteItem($this->getId($key)); - } - /** - * {@inheritdoc} - */ - public function deleteItems(array $keys) - { - if ($this->namespaceLen) { - foreach ($keys as $i => $key) { - $keys[$i] = $this->getId($key); - } - } - return $this->pool->deleteItems($keys); - } - /** - * {@inheritdoc} - */ - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - return $this->doSave($item, __FUNCTION__); - } - /** - * {@inheritdoc} - */ - public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - return $this->doSave($item, __FUNCTION__); - } - /** - * {@inheritdoc} - */ - public function commit() - { - return $this->pool->commit(); - } - private function doSave(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item, $method) - { - if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { - return \false; - } - $item = (array) $item; - $expiry = $item["\0*\0expiry"]; - if (null === $expiry && 0 < $item["\0*\0defaultLifetime"]) { - $expiry = \time() + $item["\0*\0defaultLifetime"]; - } - if ($item["\0*\0poolHash"] === $this->poolHash && $item["\0*\0innerItem"]) { - $innerItem = $item["\0*\0innerItem"]; - } elseif ($this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface) { - // this is an optimization specific for AdapterInterface implementations - // so we can save a round-trip to the backend by just creating a new item - $f = $this->createCacheItem; - $innerItem = $f($this->namespace . $item["\0*\0key"], null); - } else { - $innerItem = $this->pool->getItem($this->namespace . $item["\0*\0key"]); - } - $innerItem->set($item["\0*\0value"]); - $innerItem->expiresAt(null !== $expiry ? \DateTime::createFromFormat('U', $expiry) : null); - return $this->pool->{$method}($innerItem); - } - private function generateItems($items) - { - $f = $this->createCacheItem; - foreach ($items as $key => $item) { - if ($this->namespaceLen) { - $key = \substr($key, $this->namespaceLen); - } - (yield $key => $f($key, $item)); - } - } - private function getId($key) - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - return $this->namespace . $key; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ProxyTrait; +/** + * @author Nicolas Grekas + */ +class ProxyAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + use ProxyTrait; + private $namespace; + private $namespaceLen; + private $createCacheItem; + private $poolHash; + /** + * @param string $namespace + * @param int $defaultLifetime + */ + public function __construct(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $pool, $namespace = '', $defaultLifetime = 0) + { + $this->pool = $pool; + $this->poolHash = $poolHash = \spl_object_hash($pool); + $this->namespace = '' === $namespace ? '' : \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($namespace); + $this->namespaceLen = \strlen($namespace); + $this->createCacheItem = \Closure::bind(static function ($key, $innerItem) use($defaultLifetime, $poolHash) { + $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); + $item->key = $key; + $item->defaultLifetime = $defaultLifetime; + $item->poolHash = $poolHash; + if (null !== $innerItem) { + $item->value = $innerItem->get(); + $item->isHit = $innerItem->isHit(); + $item->innerItem = $innerItem; + $innerItem->set(null); + } + return $item; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + } + /** + * {@inheritdoc} + */ + public function getItem($key) + { + $f = $this->createCacheItem; + $item = $this->pool->getItem($this->getId($key)); + return $f($key, $item); + } + /** + * {@inheritdoc} + */ + public function getItems(array $keys = []) + { + if ($this->namespaceLen) { + foreach ($keys as $i => $key) { + $keys[$i] = $this->getId($key); + } + } + return $this->generateItems($this->pool->getItems($keys)); + } + /** + * {@inheritdoc} + */ + public function hasItem($key) + { + return $this->pool->hasItem($this->getId($key)); + } + /** + * {@inheritdoc} + */ + public function clear() + { + return $this->pool->clear(); + } + /** + * {@inheritdoc} + */ + public function deleteItem($key) + { + return $this->pool->deleteItem($this->getId($key)); + } + /** + * {@inheritdoc} + */ + public function deleteItems(array $keys) + { + if ($this->namespaceLen) { + foreach ($keys as $i => $key) { + $keys[$i] = $this->getId($key); + } + } + return $this->pool->deleteItems($keys); + } + /** + * {@inheritdoc} + */ + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + return $this->doSave($item, __FUNCTION__); + } + /** + * {@inheritdoc} + */ + public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + return $this->doSave($item, __FUNCTION__); + } + /** + * {@inheritdoc} + */ + public function commit() + { + return $this->pool->commit(); + } + private function doSave(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item, $method) + { + if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { + return \false; + } + $item = (array) $item; + $expiry = $item["\0*\0expiry"]; + if (null === $expiry && 0 < $item["\0*\0defaultLifetime"]) { + $expiry = \time() + $item["\0*\0defaultLifetime"]; + } + if ($item["\0*\0poolHash"] === $this->poolHash && $item["\0*\0innerItem"]) { + $innerItem = $item["\0*\0innerItem"]; + } elseif ($this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface) { + // this is an optimization specific for AdapterInterface implementations + // so we can save a round-trip to the backend by just creating a new item + $f = $this->createCacheItem; + $innerItem = $f($this->namespace . $item["\0*\0key"], null); + } else { + $innerItem = $this->pool->getItem($this->namespace . $item["\0*\0key"]); + } + $innerItem->set($item["\0*\0value"]); + $innerItem->expiresAt(null !== $expiry ? \DateTime::createFromFormat('U', $expiry) : null); + return $this->pool->{$method}($innerItem); + } + private function generateItems($items) + { + $f = $this->createCacheItem; + foreach ($items as $key => $item) { + if ($this->namespaceLen) { + $key = \substr($key, $this->namespaceLen); + } + (yield $key => $f($key, $item)); + } + } + private function getId($key) + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + return $this->namespace . $key; + } +} diff --git a/vendor/symfony/cache/Adapter/RedisAdapter.php b/vendor/symfony/cache/Adapter/RedisAdapter.php index 83eb8f625..224445f66 100644 --- a/vendor/symfony/cache/Adapter/RedisAdapter.php +++ b/vendor/symfony/cache/Adapter/RedisAdapter.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisTrait; -class RedisAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter -{ - use RedisTrait; - /** - * @param \Redis|\RedisArray|\RedisCluster|\Predis\Client $redisClient The redis client - * @param string $namespace The default namespace - * @param int $defaultLifetime The default lifetime - */ - public function __construct($redisClient, $namespace = '', $defaultLifetime = 0) - { - $this->init($redisClient, $namespace, $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisTrait; +class RedisAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter +{ + use RedisTrait; + /** + * @param \Redis|\RedisArray|\RedisCluster|\Predis\Client $redisClient The redis client + * @param string $namespace The default namespace + * @param int $defaultLifetime The default lifetime + */ + public function __construct($redisClient, $namespace = '', $defaultLifetime = 0) + { + $this->init($redisClient, $namespace, $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Adapter/SimpleCacheAdapter.php b/vendor/symfony/cache/Adapter/SimpleCacheAdapter.php index e4156ca8d..93b4bee48 100644 --- a/vendor/symfony/cache/Adapter/SimpleCacheAdapter.php +++ b/vendor/symfony/cache/Adapter/SimpleCacheAdapter.php @@ -1,72 +1,72 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ProxyTrait; -/** - * @author Nicolas Grekas - */ -class SimpleCacheAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface -{ - /** - * @internal - */ - const NS_SEPARATOR = '_'; - use ProxyTrait; - private $miss; - public function __construct(\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $pool, $namespace = '', $defaultLifetime = 0) - { - parent::__construct($namespace, $defaultLifetime); - $this->pool = $pool; - $this->miss = new \stdClass(); - } - /** - * {@inheritdoc} - */ - protected function doFetch(array $ids) - { - foreach ($this->pool->getMultiple($ids, $this->miss) as $key => $value) { - if ($this->miss !== $value) { - (yield $key => $value); - } - } - } - /** - * {@inheritdoc} - */ - protected function doHave($id) - { - return $this->pool->has($id); - } - /** - * {@inheritdoc} - */ - protected function doClear($namespace) - { - return $this->pool->clear(); - } - /** - * {@inheritdoc} - */ - protected function doDelete(array $ids) - { - return $this->pool->deleteMultiple($ids); - } - /** - * {@inheritdoc} - */ - protected function doSave(array $values, $lifetime) - { - return $this->pool->setMultiple($values, 0 === $lifetime ? null : $lifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ProxyTrait; +/** + * @author Nicolas Grekas + */ +class SimpleCacheAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface +{ + /** + * @internal + */ + const NS_SEPARATOR = '_'; + use ProxyTrait; + private $miss; + public function __construct(\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $pool, $namespace = '', $defaultLifetime = 0) + { + parent::__construct($namespace, $defaultLifetime); + $this->pool = $pool; + $this->miss = new \stdClass(); + } + /** + * {@inheritdoc} + */ + protected function doFetch(array $ids) + { + foreach ($this->pool->getMultiple($ids, $this->miss) as $key => $value) { + if ($this->miss !== $value) { + (yield $key => $value); + } + } + } + /** + * {@inheritdoc} + */ + protected function doHave($id) + { + return $this->pool->has($id); + } + /** + * {@inheritdoc} + */ + protected function doClear($namespace) + { + return $this->pool->clear(); + } + /** + * {@inheritdoc} + */ + protected function doDelete(array $ids) + { + return $this->pool->deleteMultiple($ids); + } + /** + * {@inheritdoc} + */ + protected function doSave(array $values, $lifetime) + { + return $this->pool->setMultiple($values, 0 === $lifetime ? null : $lifetime); + } +} diff --git a/vendor/symfony/cache/Adapter/TagAwareAdapter.php b/vendor/symfony/cache/Adapter/TagAwareAdapter.php index a277d5c9a..dfb7b38d3 100644 --- a/vendor/symfony/cache/Adapter/TagAwareAdapter.php +++ b/vendor/symfony/cache/Adapter/TagAwareAdapter.php @@ -1,323 +1,323 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Psr\Cache\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ProxyTrait; -/** - * @author Nicolas Grekas - */ -class TagAwareAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapterInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - const TAGS_PREFIX = "\0tags\0"; - use ProxyTrait; - private $deferred = []; - private $createCacheItem; - private $setCacheItemTags; - private $getTagsByKey; - private $invalidateTags; - private $tags; - private $knownTagVersions = []; - private $knownTagVersionsTtl; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface $itemsPool, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface $tagsPool = null, $knownTagVersionsTtl = 0.15) - { - $this->pool = $itemsPool; - $this->tags = $tagsPool ?: $itemsPool; - $this->knownTagVersionsTtl = $knownTagVersionsTtl; - $this->createCacheItem = \Closure::bind(static function ($key, $value, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem $protoItem) { - $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); - $item->key = $key; - $item->value = $value; - $item->defaultLifetime = $protoItem->defaultLifetime; - $item->expiry = $protoItem->expiry; - $item->poolHash = $protoItem->poolHash; - return $item; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - $this->setCacheItemTags = \Closure::bind(static function (\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem $item, $key, array &$itemTags) { - if (!$item->isHit) { - return $item; - } - if (isset($itemTags[$key])) { - foreach ($itemTags[$key] as $tag => $version) { - $item->prevTags[$tag] = $tag; - } - unset($itemTags[$key]); - } else { - $item->value = null; - $item->isHit = \false; - } - return $item; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - $this->getTagsByKey = \Closure::bind(static function ($deferred) { - $tagsByKey = []; - foreach ($deferred as $key => $item) { - $tagsByKey[$key] = $item->tags; - } - return $tagsByKey; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - $this->invalidateTags = \Closure::bind(static function (\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface $tagsAdapter, array $tags) { - foreach ($tags as $v) { - $v->defaultLifetime = 0; - $v->expiry = null; - $tagsAdapter->saveDeferred($v); - } - return $tagsAdapter->commit(); - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - } - /** - * {@inheritdoc} - */ - public function invalidateTags(array $tags) - { - $ok = \true; - $tagsByKey = []; - $invalidatedTags = []; - foreach ($tags as $tag) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($tag); - $invalidatedTags[$tag] = 0; - } - if ($this->deferred) { - $items = $this->deferred; - foreach ($items as $key => $item) { - if (!$this->pool->saveDeferred($item)) { - unset($this->deferred[$key]); - $ok = \false; - } - } - $f = $this->getTagsByKey; - $tagsByKey = $f($items); - $this->deferred = []; - } - $tagVersions = $this->getTagVersions($tagsByKey, $invalidatedTags); - $f = $this->createCacheItem; - foreach ($tagsByKey as $key => $tags) { - $this->pool->saveDeferred($f(static::TAGS_PREFIX . $key, \array_intersect_key($tagVersions, $tags), $items[$key])); - } - $ok = $this->pool->commit() && $ok; - if ($invalidatedTags) { - $f = $this->invalidateTags; - $ok = $f($this->tags, $invalidatedTags) && $ok; - } - return $ok; - } - /** - * {@inheritdoc} - */ - public function hasItem($key) - { - if ($this->deferred) { - $this->commit(); - } - if (!$this->pool->hasItem($key)) { - return \false; - } - $itemTags = $this->pool->getItem(static::TAGS_PREFIX . $key); - if (!$itemTags->isHit()) { - return \false; - } - if (!($itemTags = $itemTags->get())) { - return \true; - } - foreach ($this->getTagVersions([$itemTags]) as $tag => $version) { - if ($itemTags[$tag] !== $version && 1 !== $itemTags[$tag] - $version) { - return \false; - } - } - return \true; - } - /** - * {@inheritdoc} - */ - public function getItem($key) - { - foreach ($this->getItems([$key]) as $item) { - return $item; - } - return null; - } - /** - * {@inheritdoc} - */ - public function getItems(array $keys = []) - { - if ($this->deferred) { - $this->commit(); - } - $tagKeys = []; - foreach ($keys as $key) { - if ('' !== $key && \is_string($key)) { - $key = static::TAGS_PREFIX . $key; - $tagKeys[$key] = $key; - } - } - try { - $items = $this->pool->getItems($tagKeys + $keys); - } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\InvalidArgumentException $e) { - $this->pool->getItems($keys); - // Should throw an exception - throw $e; - } - return $this->generateItems($items, $tagKeys); - } - /** - * {@inheritdoc} - */ - public function clear() - { - $this->deferred = []; - return $this->pool->clear(); - } - /** - * {@inheritdoc} - */ - public function deleteItem($key) - { - return $this->deleteItems([$key]); - } - /** - * {@inheritdoc} - */ - public function deleteItems(array $keys) - { - foreach ($keys as $key) { - if ('' !== $key && \is_string($key)) { - $keys[] = static::TAGS_PREFIX . $key; - } - } - return $this->pool->deleteItems($keys); - } - /** - * {@inheritdoc} - */ - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { - return \false; - } - $this->deferred[$item->getKey()] = $item; - return $this->commit(); - } - /** - * {@inheritdoc} - */ - public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { - return \false; - } - $this->deferred[$item->getKey()] = $item; - return \true; - } - /** - * {@inheritdoc} - */ - public function commit() - { - return $this->invalidateTags([]); - } - public function __sleep() - { - throw new \BadMethodCallException('Cannot serialize ' . __CLASS__); - } - public function __wakeup() - { - throw new \BadMethodCallException('Cannot unserialize ' . __CLASS__); - } - public function __destruct() - { - $this->commit(); - } - private function generateItems($items, array $tagKeys) - { - $bufferedItems = $itemTags = []; - $f = $this->setCacheItemTags; - foreach ($items as $key => $item) { - if (!$tagKeys) { - (yield $key => $f($item, static::TAGS_PREFIX . $key, $itemTags)); - continue; - } - if (!isset($tagKeys[$key])) { - $bufferedItems[$key] = $item; - continue; - } - unset($tagKeys[$key]); - if ($item->isHit()) { - $itemTags[$key] = $item->get() ?: []; - } - if (!$tagKeys) { - $tagVersions = $this->getTagVersions($itemTags); - foreach ($itemTags as $key => $tags) { - foreach ($tags as $tag => $version) { - if ($tagVersions[$tag] !== $version && 1 !== $version - $tagVersions[$tag]) { - unset($itemTags[$key]); - continue 2; - } - } - } - $tagVersions = $tagKeys = null; - foreach ($bufferedItems as $key => $item) { - (yield $key => $f($item, static::TAGS_PREFIX . $key, $itemTags)); - } - $bufferedItems = null; - } - } - } - private function getTagVersions(array $tagsByKey, array &$invalidatedTags = []) - { - $tagVersions = $invalidatedTags; - foreach ($tagsByKey as $tags) { - $tagVersions += $tags; - } - if (!$tagVersions) { - return []; - } - if (!($fetchTagVersions = 1 !== \func_num_args())) { - foreach ($tagsByKey as $tags) { - foreach ($tags as $tag => $version) { - if ($tagVersions[$tag] > $version) { - $tagVersions[$tag] = $version; - } - } - } - } - $now = \microtime(\true); - $tags = []; - foreach ($tagVersions as $tag => $version) { - $tags[$tag . static::TAGS_PREFIX] = $tag; - if ($fetchTagVersions || !isset($this->knownTagVersions[$tag])) { - $fetchTagVersions = \true; - continue; - } - $version -= $this->knownTagVersions[$tag][1]; - if (0 !== $version && 1 !== $version || $now - $this->knownTagVersions[$tag][0] >= $this->knownTagVersionsTtl) { - // reuse previously fetched tag versions up to the ttl, unless we are storing items or a potential miss arises - $fetchTagVersions = \true; - } else { - $this->knownTagVersions[$tag][1] += $version; - } - } - if (!$fetchTagVersions) { - return $tagVersions; - } - foreach ($this->tags->getItems(\array_keys($tags)) as $tag => $version) { - $tagVersions[$tag = $tags[$tag]] = $version->get() ?: 0; - if (isset($invalidatedTags[$tag])) { - $invalidatedTags[$tag] = $version->set(++$tagVersions[$tag]); - } - $this->knownTagVersions[$tag] = [$now, $tagVersions[$tag]]; - } - return $tagVersions; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Psr\Cache\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ProxyTrait; +/** + * @author Nicolas Grekas + */ +class TagAwareAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapterInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + const TAGS_PREFIX = "\0tags\0"; + use ProxyTrait; + private $deferred = []; + private $createCacheItem; + private $setCacheItemTags; + private $getTagsByKey; + private $invalidateTags; + private $tags; + private $knownTagVersions = []; + private $knownTagVersionsTtl; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface $itemsPool, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface $tagsPool = null, $knownTagVersionsTtl = 0.15) + { + $this->pool = $itemsPool; + $this->tags = $tagsPool ?: $itemsPool; + $this->knownTagVersionsTtl = $knownTagVersionsTtl; + $this->createCacheItem = \Closure::bind(static function ($key, $value, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem $protoItem) { + $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); + $item->key = $key; + $item->value = $value; + $item->defaultLifetime = $protoItem->defaultLifetime; + $item->expiry = $protoItem->expiry; + $item->poolHash = $protoItem->poolHash; + return $item; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + $this->setCacheItemTags = \Closure::bind(static function (\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem $item, $key, array &$itemTags) { + if (!$item->isHit) { + return $item; + } + if (isset($itemTags[$key])) { + foreach ($itemTags[$key] as $tag => $version) { + $item->prevTags[$tag] = $tag; + } + unset($itemTags[$key]); + } else { + $item->value = null; + $item->isHit = \false; + } + return $item; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + $this->getTagsByKey = \Closure::bind(static function ($deferred) { + $tagsByKey = []; + foreach ($deferred as $key => $item) { + $tagsByKey[$key] = $item->tags; + } + return $tagsByKey; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + $this->invalidateTags = \Closure::bind(static function (\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface $tagsAdapter, array $tags) { + foreach ($tags as $v) { + $v->defaultLifetime = 0; + $v->expiry = null; + $tagsAdapter->saveDeferred($v); + } + return $tagsAdapter->commit(); + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + } + /** + * {@inheritdoc} + */ + public function invalidateTags(array $tags) + { + $ok = \true; + $tagsByKey = []; + $invalidatedTags = []; + foreach ($tags as $tag) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($tag); + $invalidatedTags[$tag] = 0; + } + if ($this->deferred) { + $items = $this->deferred; + foreach ($items as $key => $item) { + if (!$this->pool->saveDeferred($item)) { + unset($this->deferred[$key]); + $ok = \false; + } + } + $f = $this->getTagsByKey; + $tagsByKey = $f($items); + $this->deferred = []; + } + $tagVersions = $this->getTagVersions($tagsByKey, $invalidatedTags); + $f = $this->createCacheItem; + foreach ($tagsByKey as $key => $tags) { + $this->pool->saveDeferred($f(static::TAGS_PREFIX . $key, \array_intersect_key($tagVersions, $tags), $items[$key])); + } + $ok = $this->pool->commit() && $ok; + if ($invalidatedTags) { + $f = $this->invalidateTags; + $ok = $f($this->tags, $invalidatedTags) && $ok; + } + return $ok; + } + /** + * {@inheritdoc} + */ + public function hasItem($key) + { + if ($this->deferred) { + $this->commit(); + } + if (!$this->pool->hasItem($key)) { + return \false; + } + $itemTags = $this->pool->getItem(static::TAGS_PREFIX . $key); + if (!$itemTags->isHit()) { + return \false; + } + if (!($itemTags = $itemTags->get())) { + return \true; + } + foreach ($this->getTagVersions([$itemTags]) as $tag => $version) { + if ($itemTags[$tag] !== $version && 1 !== $itemTags[$tag] - $version) { + return \false; + } + } + return \true; + } + /** + * {@inheritdoc} + */ + public function getItem($key) + { + foreach ($this->getItems([$key]) as $item) { + return $item; + } + return null; + } + /** + * {@inheritdoc} + */ + public function getItems(array $keys = []) + { + if ($this->deferred) { + $this->commit(); + } + $tagKeys = []; + foreach ($keys as $key) { + if ('' !== $key && \is_string($key)) { + $key = static::TAGS_PREFIX . $key; + $tagKeys[$key] = $key; + } + } + try { + $items = $this->pool->getItems($tagKeys + $keys); + } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\InvalidArgumentException $e) { + $this->pool->getItems($keys); + // Should throw an exception + throw $e; + } + return $this->generateItems($items, $tagKeys); + } + /** + * {@inheritdoc} + */ + public function clear() + { + $this->deferred = []; + return $this->pool->clear(); + } + /** + * {@inheritdoc} + */ + public function deleteItem($key) + { + return $this->deleteItems([$key]); + } + /** + * {@inheritdoc} + */ + public function deleteItems(array $keys) + { + foreach ($keys as $key) { + if ('' !== $key && \is_string($key)) { + $keys[] = static::TAGS_PREFIX . $key; + } + } + return $this->pool->deleteItems($keys); + } + /** + * {@inheritdoc} + */ + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { + return \false; + } + $this->deferred[$item->getKey()] = $item; + return $this->commit(); + } + /** + * {@inheritdoc} + */ + public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + if (!$item instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem) { + return \false; + } + $this->deferred[$item->getKey()] = $item; + return \true; + } + /** + * {@inheritdoc} + */ + public function commit() + { + return $this->invalidateTags([]); + } + public function __sleep() + { + throw new \BadMethodCallException('Cannot serialize ' . __CLASS__); + } + public function __wakeup() + { + throw new \BadMethodCallException('Cannot unserialize ' . __CLASS__); + } + public function __destruct() + { + $this->commit(); + } + private function generateItems($items, array $tagKeys) + { + $bufferedItems = $itemTags = []; + $f = $this->setCacheItemTags; + foreach ($items as $key => $item) { + if (!$tagKeys) { + (yield $key => $f($item, static::TAGS_PREFIX . $key, $itemTags)); + continue; + } + if (!isset($tagKeys[$key])) { + $bufferedItems[$key] = $item; + continue; + } + unset($tagKeys[$key]); + if ($item->isHit()) { + $itemTags[$key] = $item->get() ?: []; + } + if (!$tagKeys) { + $tagVersions = $this->getTagVersions($itemTags); + foreach ($itemTags as $key => $tags) { + foreach ($tags as $tag => $version) { + if ($tagVersions[$tag] !== $version && 1 !== $version - $tagVersions[$tag]) { + unset($itemTags[$key]); + continue 2; + } + } + } + $tagVersions = $tagKeys = null; + foreach ($bufferedItems as $key => $item) { + (yield $key => $f($item, static::TAGS_PREFIX . $key, $itemTags)); + } + $bufferedItems = null; + } + } + } + private function getTagVersions(array $tagsByKey, array &$invalidatedTags = []) + { + $tagVersions = $invalidatedTags; + foreach ($tagsByKey as $tags) { + $tagVersions += $tags; + } + if (!$tagVersions) { + return []; + } + if (!($fetchTagVersions = 1 !== \func_num_args())) { + foreach ($tagsByKey as $tags) { + foreach ($tags as $tag => $version) { + if ($tagVersions[$tag] > $version) { + $tagVersions[$tag] = $version; + } + } + } + } + $now = \microtime(\true); + $tags = []; + foreach ($tagVersions as $tag => $version) { + $tags[$tag . static::TAGS_PREFIX] = $tag; + if ($fetchTagVersions || !isset($this->knownTagVersions[$tag])) { + $fetchTagVersions = \true; + continue; + } + $version -= $this->knownTagVersions[$tag][1]; + if (0 !== $version && 1 !== $version || $now - $this->knownTagVersions[$tag][0] >= $this->knownTagVersionsTtl) { + // reuse previously fetched tag versions up to the ttl, unless we are storing items or a potential miss arises + $fetchTagVersions = \true; + } else { + $this->knownTagVersions[$tag][1] += $version; + } + } + if (!$fetchTagVersions) { + return $tagVersions; + } + foreach ($this->tags->getItems(\array_keys($tags)) as $tag => $version) { + $tagVersions[$tag = $tags[$tag]] = $version->get() ?: 0; + if (isset($invalidatedTags[$tag])) { + $invalidatedTags[$tag] = $version->set(++$tagVersions[$tag]); + } + $this->knownTagVersions[$tag] = [$now, $tagVersions[$tag]]; + } + return $tagVersions; + } +} diff --git a/vendor/symfony/cache/Adapter/TagAwareAdapterInterface.php b/vendor/symfony/cache/Adapter/TagAwareAdapterInterface.php index c3ca04fa4..de7342314 100644 --- a/vendor/symfony/cache/Adapter/TagAwareAdapterInterface.php +++ b/vendor/symfony/cache/Adapter/TagAwareAdapterInterface.php @@ -1,31 +1,31 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\InvalidArgumentException; -/** - * Interface for invalidating cached items using tags. - * - * @author Nicolas Grekas - */ -interface TagAwareAdapterInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface -{ - /** - * Invalidates cached items using tags. - * - * @param string[] $tags An array of tags to invalidate - * - * @return bool True on success - * - * @throws InvalidArgumentException When $tags is not valid - */ - public function invalidateTags(array $tags); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\InvalidArgumentException; +/** + * Interface for invalidating cached items using tags. + * + * @author Nicolas Grekas + */ +interface TagAwareAdapterInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface +{ + /** + * Invalidates cached items using tags. + * + * @param string[] $tags An array of tags to invalidate + * + * @return bool True on success + * + * @throws InvalidArgumentException When $tags is not valid + */ + public function invalidateTags(array $tags); +} diff --git a/vendor/symfony/cache/Adapter/TraceableAdapter.php b/vendor/symfony/cache/Adapter/TraceableAdapter.php index 45ddbb9ac..01881dc84 100644 --- a/vendor/symfony/cache/Adapter/TraceableAdapter.php +++ b/vendor/symfony/cache/Adapter/TraceableAdapter.php @@ -1,212 +1,212 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -/** - * An adapter that collects data about all cache calls. - * - * @author Aaron Scherer - * @author Tobias Nyholm - * @author Nicolas Grekas - */ -class TraceableAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - protected $pool; - private $calls = []; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface $pool) - { - $this->pool = $pool; - } - /** - * {@inheritdoc} - */ - public function getItem($key) - { - $event = $this->start(__FUNCTION__); - try { - $item = $this->pool->getItem($key); - } finally { - $event->end = \microtime(\true); - } - if ($event->result[$key] = $item->isHit()) { - ++$event->hits; - } else { - ++$event->misses; - } - return $item; - } - /** - * {@inheritdoc} - */ - public function hasItem($key) - { - $event = $this->start(__FUNCTION__); - try { - return $event->result[$key] = $this->pool->hasItem($key); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function deleteItem($key) - { - $event = $this->start(__FUNCTION__); - try { - return $event->result[$key] = $this->pool->deleteItem($key); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - $event = $this->start(__FUNCTION__); - try { - return $event->result[$item->getKey()] = $this->pool->save($item); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - $event = $this->start(__FUNCTION__); - try { - return $event->result[$item->getKey()] = $this->pool->saveDeferred($item); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function getItems(array $keys = []) - { - $event = $this->start(__FUNCTION__); - try { - $result = $this->pool->getItems($keys); - } finally { - $event->end = \microtime(\true); - } - $f = function () use($result, $event) { - $event->result = []; - foreach ($result as $key => $item) { - if ($event->result[$key] = $item->isHit()) { - ++$event->hits; - } else { - ++$event->misses; - } - (yield $key => $item); - } - }; - return $f(); - } - /** - * {@inheritdoc} - */ - public function clear() - { - $event = $this->start(__FUNCTION__); - try { - return $event->result = $this->pool->clear(); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function deleteItems(array $keys) - { - $event = $this->start(__FUNCTION__); - $event->result['keys'] = $keys; - try { - return $event->result['result'] = $this->pool->deleteItems($keys); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function commit() - { - $event = $this->start(__FUNCTION__); - try { - return $event->result = $this->pool->commit(); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function prune() - { - if (!$this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { - return \false; - } - $event = $this->start(__FUNCTION__); - try { - return $event->result = $this->pool->prune(); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function reset() - { - if (!$this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { - return; - } - $event = $this->start(__FUNCTION__); - try { - $this->pool->reset(); - } finally { - $event->end = \microtime(\true); - } - } - public function getCalls() - { - return $this->calls; - } - public function clearCalls() - { - $this->calls = []; - } - protected function start($name) - { - $this->calls[] = $event = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapterEvent(); - $event->name = $name; - $event->start = \microtime(\true); - return $event; - } -} -class TraceableAdapterEvent -{ - public $name; - public $start; - public $end; - public $result; - public $hits = 0; - public $misses = 0; -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +/** + * An adapter that collects data about all cache calls. + * + * @author Aaron Scherer + * @author Tobias Nyholm + * @author Nicolas Grekas + */ +class TraceableAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + protected $pool; + private $calls = []; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface $pool) + { + $this->pool = $pool; + } + /** + * {@inheritdoc} + */ + public function getItem($key) + { + $event = $this->start(__FUNCTION__); + try { + $item = $this->pool->getItem($key); + } finally { + $event->end = \microtime(\true); + } + if ($event->result[$key] = $item->isHit()) { + ++$event->hits; + } else { + ++$event->misses; + } + return $item; + } + /** + * {@inheritdoc} + */ + public function hasItem($key) + { + $event = $this->start(__FUNCTION__); + try { + return $event->result[$key] = $this->pool->hasItem($key); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function deleteItem($key) + { + $event = $this->start(__FUNCTION__); + try { + return $event->result[$key] = $this->pool->deleteItem($key); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + $event = $this->start(__FUNCTION__); + try { + return $event->result[$item->getKey()] = $this->pool->save($item); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + $event = $this->start(__FUNCTION__); + try { + return $event->result[$item->getKey()] = $this->pool->saveDeferred($item); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function getItems(array $keys = []) + { + $event = $this->start(__FUNCTION__); + try { + $result = $this->pool->getItems($keys); + } finally { + $event->end = \microtime(\true); + } + $f = function () use($result, $event) { + $event->result = []; + foreach ($result as $key => $item) { + if ($event->result[$key] = $item->isHit()) { + ++$event->hits; + } else { + ++$event->misses; + } + (yield $key => $item); + } + }; + return $f(); + } + /** + * {@inheritdoc} + */ + public function clear() + { + $event = $this->start(__FUNCTION__); + try { + return $event->result = $this->pool->clear(); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function deleteItems(array $keys) + { + $event = $this->start(__FUNCTION__); + $event->result['keys'] = $keys; + try { + return $event->result['result'] = $this->pool->deleteItems($keys); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function commit() + { + $event = $this->start(__FUNCTION__); + try { + return $event->result = $this->pool->commit(); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function prune() + { + if (!$this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { + return \false; + } + $event = $this->start(__FUNCTION__); + try { + return $event->result = $this->pool->prune(); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function reset() + { + if (!$this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { + return; + } + $event = $this->start(__FUNCTION__); + try { + $this->pool->reset(); + } finally { + $event->end = \microtime(\true); + } + } + public function getCalls() + { + return $this->calls; + } + public function clearCalls() + { + $this->calls = []; + } + protected function start($name) + { + $this->calls[] = $event = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapterEvent(); + $event->name = $name; + $event->start = \microtime(\true); + return $event; + } +} +class TraceableAdapterEvent +{ + public $name; + public $start; + public $end; + public $result; + public $hits = 0; + public $misses = 0; +} diff --git a/vendor/symfony/cache/Adapter/TraceableTagAwareAdapter.php b/vendor/symfony/cache/Adapter/TraceableTagAwareAdapter.php index f0a2e4d4e..f1ea4a751 100644 --- a/vendor/symfony/cache/Adapter/TraceableTagAwareAdapter.php +++ b/vendor/symfony/cache/Adapter/TraceableTagAwareAdapter.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; - -/** - * @author Robin Chalas - */ -class TraceableTagAwareAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapterInterface -{ - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapterInterface $pool) - { - parent::__construct($pool); - } - /** - * {@inheritdoc} - */ - public function invalidateTags(array $tags) - { - $event = $this->start(__FUNCTION__); - try { - return $event->result = $this->pool->invalidateTags($tags); - } finally { - $event->end = \microtime(\true); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter; + +/** + * @author Robin Chalas + */ +class TraceableTagAwareAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapter implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapterInterface +{ + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapterInterface $pool) + { + parent::__construct($pool); + } + /** + * {@inheritdoc} + */ + public function invalidateTags(array $tags) + { + $event = $this->start(__FUNCTION__); + try { + return $event->result = $this->pool->invalidateTags($tags); + } finally { + $event->end = \microtime(\true); + } + } +} diff --git a/vendor/symfony/cache/Adapter/index.php b/vendor/symfony/cache/Adapter/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/Adapter/index.php +++ b/vendor/symfony/cache/Adapter/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/CHANGELOG.md b/vendor/symfony/cache/CHANGELOG.md index 11c1b9364..9e25309e0 100644 --- a/vendor/symfony/cache/CHANGELOG.md +++ b/vendor/symfony/cache/CHANGELOG.md @@ -1,36 +1,36 @@ -CHANGELOG -========= - -3.4.0 ------ - - * added using options from Memcached DSN - * added PruneableInterface so PSR-6 or PSR-16 cache implementations can declare support for manual stale cache pruning - * added prune logic to FilesystemTrait, PhpFilesTrait, PdoTrait, TagAwareAdapter and ChainTrait - * now FilesystemAdapter, PhpFilesAdapter, FilesystemCache, PhpFilesCache, PdoAdapter, PdoCache, ChainAdapter, and - ChainCache implement PruneableInterface and support manual stale cache pruning - -3.3.0 ------ - - * [EXPERIMENTAL] added CacheItem::getPreviousTags() to get bound tags coming from the pool storage if any - * added PSR-16 "Simple Cache" implementations for all existing PSR-6 adapters - * added Psr6Cache and SimpleCacheAdapter for bidirectional interoperability between PSR-6 and PSR-16 - * added MemcachedAdapter (PSR-6) and MemcachedCache (PSR-16) - * added TraceableAdapter (PSR-6) and TraceableCache (PSR-16) - -3.2.0 ------ - - * added TagAwareAdapter for tags-based invalidation - * added PdoAdapter with PDO and Doctrine DBAL support - * added PhpArrayAdapter and PhpFilesAdapter for OPcache-backed shared memory storage (PHP 7+ only) - * added NullAdapter - -3.1.0 ------ - - * added the component with strict PSR-6 implementations - * added ApcuAdapter, ArrayAdapter, FilesystemAdapter and RedisAdapter - * added AbstractAdapter, ChainAdapter and ProxyAdapter - * added DoctrineAdapter and DoctrineProvider for bidirectional interoperability with Doctrine Cache +CHANGELOG +========= + +3.4.0 +----- + + * added using options from Memcached DSN + * added PruneableInterface so PSR-6 or PSR-16 cache implementations can declare support for manual stale cache pruning + * added prune logic to FilesystemTrait, PhpFilesTrait, PdoTrait, TagAwareAdapter and ChainTrait + * now FilesystemAdapter, PhpFilesAdapter, FilesystemCache, PhpFilesCache, PdoAdapter, PdoCache, ChainAdapter, and + ChainCache implement PruneableInterface and support manual stale cache pruning + +3.3.0 +----- + + * [EXPERIMENTAL] added CacheItem::getPreviousTags() to get bound tags coming from the pool storage if any + * added PSR-16 "Simple Cache" implementations for all existing PSR-6 adapters + * added Psr6Cache and SimpleCacheAdapter for bidirectional interoperability between PSR-6 and PSR-16 + * added MemcachedAdapter (PSR-6) and MemcachedCache (PSR-16) + * added TraceableAdapter (PSR-6) and TraceableCache (PSR-16) + +3.2.0 +----- + + * added TagAwareAdapter for tags-based invalidation + * added PdoAdapter with PDO and Doctrine DBAL support + * added PhpArrayAdapter and PhpFilesAdapter for OPcache-backed shared memory storage (PHP 7+ only) + * added NullAdapter + +3.1.0 +----- + + * added the component with strict PSR-6 implementations + * added ApcuAdapter, ArrayAdapter, FilesystemAdapter and RedisAdapter + * added AbstractAdapter, ChainAdapter and ProxyAdapter + * added DoctrineAdapter and DoctrineProvider for bidirectional interoperability with Doctrine Cache diff --git a/vendor/symfony/cache/CacheItem.php b/vendor/symfony/cache/CacheItem.php index 29df83358..19c8c970a 100644 --- a/vendor/symfony/cache/CacheItem.php +++ b/vendor/symfony/cache/CacheItem.php @@ -1,176 +1,176 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -/** - * @author Nicolas Grekas - */ -final class CacheItem implements \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface -{ - protected $key; - protected $value; - protected $isHit = \false; - protected $expiry; - protected $defaultLifetime; - protected $tags = []; - protected $prevTags = []; - protected $innerItem; - protected $poolHash; - /** - * {@inheritdoc} - */ - public function getKey() - { - return $this->key; - } - /** - * {@inheritdoc} - */ - public function get() - { - return $this->value; - } - /** - * {@inheritdoc} - */ - public function isHit() - { - return $this->isHit; - } - /** - * {@inheritdoc} - * - * @return $this - */ - public function set($value) - { - $this->value = $value; - return $this; - } - /** - * {@inheritdoc} - * - * @return $this - */ - public function expiresAt($expiration) - { - if (null === $expiration) { - $this->expiry = $this->defaultLifetime > 0 ? \time() + $this->defaultLifetime : null; - } elseif ($expiration instanceof \DateTimeInterface) { - $this->expiry = (int) $expiration->format('U'); - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Expiration date must implement DateTimeInterface or be null, "%s" given.', \is_object($expiration) ? \get_class($expiration) : \gettype($expiration))); - } - return $this; - } - /** - * {@inheritdoc} - * - * @return $this - */ - public function expiresAfter($time) - { - if (null === $time) { - $this->expiry = $this->defaultLifetime > 0 ? \time() + $this->defaultLifetime : null; - } elseif ($time instanceof \DateInterval) { - $this->expiry = (int) \DateTime::createFromFormat('U', \time())->add($time)->format('U'); - } elseif (\is_int($time)) { - $this->expiry = $time + \time(); - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Expiration date must be an integer, a DateInterval or null, "%s" given.', \is_object($time) ? \get_class($time) : \gettype($time))); - } - return $this; - } - /** - * Adds a tag to a cache item. - * - * @param string|string[] $tags A tag or array of tags - * - * @return $this - * - * @throws InvalidArgumentException When $tag is not valid - */ - public function tag($tags) - { - if (!\is_array($tags)) { - $tags = [$tags]; - } - foreach ($tags as $tag) { - if (!\is_string($tag)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache tag must be string, "%s" given.', \is_object($tag) ? \get_class($tag) : \gettype($tag))); - } - if (isset($this->tags[$tag])) { - continue; - } - if ('' === $tag) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException('Cache tag length must be greater than zero.'); - } - if (\false !== \strpbrk($tag, '{}()/\\@:')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache tag "%s" contains reserved characters {}()/\\@:.', $tag)); - } - $this->tags[$tag] = $tag; - } - return $this; - } - /** - * Returns the list of tags bound to the value coming from the pool storage if any. - * - * @return array - */ - public function getPreviousTags() - { - return $this->prevTags; - } - /** - * Validates a cache key according to PSR-6. - * - * @param string $key The key to validate - * - * @return string - * - * @throws InvalidArgumentException When $key is not valid - */ - public static function validateKey($key) - { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if ('' === $key) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException('Cache key length must be greater than zero.'); - } - if (\false !== \strpbrk($key, '{}()/\\@:')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key "%s" contains reserved characters {}()/\\@:.', $key)); - } - return $key; - } - /** - * Internal logging helper. - * - * @internal - */ - public static function log(\_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger = null, $message, $context = []) - { - if ($logger) { - $logger->warning($message, $context); - } else { - $replace = []; - foreach ($context as $k => $v) { - if (\is_scalar($v)) { - $replace['{' . $k . '}'] = $v; - } - } - @\trigger_error(\strtr($message, $replace), \E_USER_WARNING); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +/** + * @author Nicolas Grekas + */ +final class CacheItem implements \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface +{ + protected $key; + protected $value; + protected $isHit = \false; + protected $expiry; + protected $defaultLifetime; + protected $tags = []; + protected $prevTags = []; + protected $innerItem; + protected $poolHash; + /** + * {@inheritdoc} + */ + public function getKey() + { + return $this->key; + } + /** + * {@inheritdoc} + */ + public function get() + { + return $this->value; + } + /** + * {@inheritdoc} + */ + public function isHit() + { + return $this->isHit; + } + /** + * {@inheritdoc} + * + * @return $this + */ + public function set($value) + { + $this->value = $value; + return $this; + } + /** + * {@inheritdoc} + * + * @return $this + */ + public function expiresAt($expiration) + { + if (null === $expiration) { + $this->expiry = $this->defaultLifetime > 0 ? \time() + $this->defaultLifetime : null; + } elseif ($expiration instanceof \DateTimeInterface) { + $this->expiry = (int) $expiration->format('U'); + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Expiration date must implement DateTimeInterface or be null, "%s" given.', \is_object($expiration) ? \get_class($expiration) : \gettype($expiration))); + } + return $this; + } + /** + * {@inheritdoc} + * + * @return $this + */ + public function expiresAfter($time) + { + if (null === $time) { + $this->expiry = $this->defaultLifetime > 0 ? \time() + $this->defaultLifetime : null; + } elseif ($time instanceof \DateInterval) { + $this->expiry = (int) \DateTime::createFromFormat('U', \time())->add($time)->format('U'); + } elseif (\is_int($time)) { + $this->expiry = $time + \time(); + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Expiration date must be an integer, a DateInterval or null, "%s" given.', \is_object($time) ? \get_class($time) : \gettype($time))); + } + return $this; + } + /** + * Adds a tag to a cache item. + * + * @param string|string[] $tags A tag or array of tags + * + * @return $this + * + * @throws InvalidArgumentException When $tag is not valid + */ + public function tag($tags) + { + if (!\is_array($tags)) { + $tags = [$tags]; + } + foreach ($tags as $tag) { + if (!\is_string($tag)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache tag must be string, "%s" given.', \is_object($tag) ? \get_class($tag) : \gettype($tag))); + } + if (isset($this->tags[$tag])) { + continue; + } + if ('' === $tag) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException('Cache tag length must be greater than zero.'); + } + if (\false !== \strpbrk($tag, '{}()/\\@:')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache tag "%s" contains reserved characters {}()/\\@:.', $tag)); + } + $this->tags[$tag] = $tag; + } + return $this; + } + /** + * Returns the list of tags bound to the value coming from the pool storage if any. + * + * @return array + */ + public function getPreviousTags() + { + return $this->prevTags; + } + /** + * Validates a cache key according to PSR-6. + * + * @param string $key The key to validate + * + * @return string + * + * @throws InvalidArgumentException When $key is not valid + */ + public static function validateKey($key) + { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if ('' === $key) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException('Cache key length must be greater than zero.'); + } + if (\false !== \strpbrk($key, '{}()/\\@:')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key "%s" contains reserved characters {}()/\\@:.', $key)); + } + return $key; + } + /** + * Internal logging helper. + * + * @internal + */ + public static function log(\_PhpScoper5ea00cc67502b\Psr\Log\LoggerInterface $logger = null, $message, $context = []) + { + if ($logger) { + $logger->warning($message, $context); + } else { + $replace = []; + foreach ($context as $k => $v) { + if (\is_scalar($v)) { + $replace['{' . $k . '}'] = $v; + } + } + @\trigger_error(\strtr($message, $replace), \E_USER_WARNING); + } + } +} diff --git a/vendor/symfony/cache/DataCollector/CacheDataCollector.php b/vendor/symfony/cache/DataCollector/CacheDataCollector.php index 3f555d87f..fa7dc75c3 100644 --- a/vendor/symfony/cache/DataCollector/CacheDataCollector.php +++ b/vendor/symfony/cache/DataCollector/CacheDataCollector.php @@ -1,157 +1,157 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\DataCollector; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapterEvent; -use _PhpScoper5ea00cc67502b\Symfony\Component\HttpFoundation\Request; -use _PhpScoper5ea00cc67502b\Symfony\Component\HttpFoundation\Response; -use _PhpScoper5ea00cc67502b\Symfony\Component\HttpKernel\DataCollector\DataCollector; -use _PhpScoper5ea00cc67502b\Symfony\Component\HttpKernel\DataCollector\LateDataCollectorInterface; -/** - * @author Aaron Scherer - * @author Tobias Nyholm - */ -class CacheDataCollector extends \_PhpScoper5ea00cc67502b\Symfony\Component\HttpKernel\DataCollector\DataCollector implements \_PhpScoper5ea00cc67502b\Symfony\Component\HttpKernel\DataCollector\LateDataCollectorInterface -{ - /** - * @var TraceableAdapter[] - */ - private $instances = []; - /** - * @param string $name - */ - public function addInstance($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapter $instance) - { - $this->instances[$name] = $instance; - } - /** - * {@inheritdoc} - */ - public function collect(\_PhpScoper5ea00cc67502b\Symfony\Component\HttpFoundation\Request $request, \_PhpScoper5ea00cc67502b\Symfony\Component\HttpFoundation\Response $response, \Exception $exception = null) - { - $empty = ['calls' => [], 'config' => [], 'options' => [], 'statistics' => []]; - $this->data = ['instances' => $empty, 'total' => $empty]; - foreach ($this->instances as $name => $instance) { - $this->data['instances']['calls'][$name] = $instance->getCalls(); - } - $this->data['instances']['statistics'] = $this->calculateStatistics(); - $this->data['total']['statistics'] = $this->calculateTotalStatistics(); - } - public function reset() - { - $this->data = []; - foreach ($this->instances as $instance) { - $instance->clearCalls(); - } - } - public function lateCollect() - { - $this->data = $this->cloneVar($this->data); - } - /** - * {@inheritdoc} - */ - public function getName() - { - return 'cache'; - } - /** - * Method returns amount of logged Cache reads: "get" calls. - * - * @return array - */ - public function getStatistics() - { - return $this->data['instances']['statistics']; - } - /** - * Method returns the statistic totals. - * - * @return array - */ - public function getTotals() - { - return $this->data['total']['statistics']; - } - /** - * Method returns all logged Cache call objects. - * - * @return mixed - */ - public function getCalls() - { - return $this->data['instances']['calls']; - } - /** - * @return array - */ - private function calculateStatistics() - { - $statistics = []; - foreach ($this->data['instances']['calls'] as $name => $calls) { - $statistics[$name] = ['calls' => 0, 'time' => 0, 'reads' => 0, 'writes' => 0, 'deletes' => 0, 'hits' => 0, 'misses' => 0]; - /** @var TraceableAdapterEvent $call */ - foreach ($calls as $call) { - ++$statistics[$name]['calls']; - $statistics[$name]['time'] += $call->end - $call->start; - if ('getItem' === $call->name) { - ++$statistics[$name]['reads']; - if ($call->hits) { - ++$statistics[$name]['hits']; - } else { - ++$statistics[$name]['misses']; - } - } elseif ('getItems' === $call->name) { - $statistics[$name]['reads'] += $call->hits + $call->misses; - $statistics[$name]['hits'] += $call->hits; - $statistics[$name]['misses'] += $call->misses; - } elseif ('hasItem' === $call->name) { - ++$statistics[$name]['reads']; - if (\false === $call->result) { - ++$statistics[$name]['misses']; - } else { - ++$statistics[$name]['hits']; - } - } elseif ('save' === $call->name) { - ++$statistics[$name]['writes']; - } elseif ('deleteItem' === $call->name) { - ++$statistics[$name]['deletes']; - } - } - if ($statistics[$name]['reads']) { - $statistics[$name]['hit_read_ratio'] = \round(100 * $statistics[$name]['hits'] / $statistics[$name]['reads'], 2); - } else { - $statistics[$name]['hit_read_ratio'] = null; - } - } - return $statistics; - } - /** - * @return array - */ - private function calculateTotalStatistics() - { - $statistics = $this->getStatistics(); - $totals = ['calls' => 0, 'time' => 0, 'reads' => 0, 'writes' => 0, 'deletes' => 0, 'hits' => 0, 'misses' => 0]; - foreach ($statistics as $name => $values) { - foreach ($totals as $key => $value) { - $totals[$key] += $statistics[$name][$key]; - } - } - if ($totals['reads']) { - $totals['hit_read_ratio'] = \round(100 * $totals['hits'] / $totals['reads'], 2); - } else { - $totals['hit_read_ratio'] = null; - } - return $totals; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\DataCollector; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapterEvent; +use _PhpScoper5ea00cc67502b\Symfony\Component\HttpFoundation\Request; +use _PhpScoper5ea00cc67502b\Symfony\Component\HttpFoundation\Response; +use _PhpScoper5ea00cc67502b\Symfony\Component\HttpKernel\DataCollector\DataCollector; +use _PhpScoper5ea00cc67502b\Symfony\Component\HttpKernel\DataCollector\LateDataCollectorInterface; +/** + * @author Aaron Scherer + * @author Tobias Nyholm + */ +class CacheDataCollector extends \_PhpScoper5ea00cc67502b\Symfony\Component\HttpKernel\DataCollector\DataCollector implements \_PhpScoper5ea00cc67502b\Symfony\Component\HttpKernel\DataCollector\LateDataCollectorInterface +{ + /** + * @var TraceableAdapter[] + */ + private $instances = []; + /** + * @param string $name + */ + public function addInstance($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapter $instance) + { + $this->instances[$name] = $instance; + } + /** + * {@inheritdoc} + */ + public function collect(\_PhpScoper5ea00cc67502b\Symfony\Component\HttpFoundation\Request $request, \_PhpScoper5ea00cc67502b\Symfony\Component\HttpFoundation\Response $response, \Exception $exception = null) + { + $empty = ['calls' => [], 'config' => [], 'options' => [], 'statistics' => []]; + $this->data = ['instances' => $empty, 'total' => $empty]; + foreach ($this->instances as $name => $instance) { + $this->data['instances']['calls'][$name] = $instance->getCalls(); + } + $this->data['instances']['statistics'] = $this->calculateStatistics(); + $this->data['total']['statistics'] = $this->calculateTotalStatistics(); + } + public function reset() + { + $this->data = []; + foreach ($this->instances as $instance) { + $instance->clearCalls(); + } + } + public function lateCollect() + { + $this->data = $this->cloneVar($this->data); + } + /** + * {@inheritdoc} + */ + public function getName() + { + return 'cache'; + } + /** + * Method returns amount of logged Cache reads: "get" calls. + * + * @return array + */ + public function getStatistics() + { + return $this->data['instances']['statistics']; + } + /** + * Method returns the statistic totals. + * + * @return array + */ + public function getTotals() + { + return $this->data['total']['statistics']; + } + /** + * Method returns all logged Cache call objects. + * + * @return mixed + */ + public function getCalls() + { + return $this->data['instances']['calls']; + } + /** + * @return array + */ + private function calculateStatistics() + { + $statistics = []; + foreach ($this->data['instances']['calls'] as $name => $calls) { + $statistics[$name] = ['calls' => 0, 'time' => 0, 'reads' => 0, 'writes' => 0, 'deletes' => 0, 'hits' => 0, 'misses' => 0]; + /** @var TraceableAdapterEvent $call */ + foreach ($calls as $call) { + ++$statistics[$name]['calls']; + $statistics[$name]['time'] += $call->end - $call->start; + if ('getItem' === $call->name) { + ++$statistics[$name]['reads']; + if ($call->hits) { + ++$statistics[$name]['hits']; + } else { + ++$statistics[$name]['misses']; + } + } elseif ('getItems' === $call->name) { + $statistics[$name]['reads'] += $call->hits + $call->misses; + $statistics[$name]['hits'] += $call->hits; + $statistics[$name]['misses'] += $call->misses; + } elseif ('hasItem' === $call->name) { + ++$statistics[$name]['reads']; + if (\false === $call->result) { + ++$statistics[$name]['misses']; + } else { + ++$statistics[$name]['hits']; + } + } elseif ('save' === $call->name) { + ++$statistics[$name]['writes']; + } elseif ('deleteItem' === $call->name) { + ++$statistics[$name]['deletes']; + } + } + if ($statistics[$name]['reads']) { + $statistics[$name]['hit_read_ratio'] = \round(100 * $statistics[$name]['hits'] / $statistics[$name]['reads'], 2); + } else { + $statistics[$name]['hit_read_ratio'] = null; + } + } + return $statistics; + } + /** + * @return array + */ + private function calculateTotalStatistics() + { + $statistics = $this->getStatistics(); + $totals = ['calls' => 0, 'time' => 0, 'reads' => 0, 'writes' => 0, 'deletes' => 0, 'hits' => 0, 'misses' => 0]; + foreach ($statistics as $name => $values) { + foreach ($totals as $key => $value) { + $totals[$key] += $statistics[$name][$key]; + } + } + if ($totals['reads']) { + $totals['hit_read_ratio'] = \round(100 * $totals['hits'] / $totals['reads'], 2); + } else { + $totals['hit_read_ratio'] = null; + } + return $totals; + } +} diff --git a/vendor/symfony/cache/DataCollector/index.php b/vendor/symfony/cache/DataCollector/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/DataCollector/index.php +++ b/vendor/symfony/cache/DataCollector/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/DoctrineProvider.php b/vendor/symfony/cache/DoctrineProvider.php index 0cc1782c6..36bd9c253 100644 --- a/vendor/symfony/cache/DoctrineProvider.php +++ b/vendor/symfony/cache/DoctrineProvider.php @@ -1,89 +1,89 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache; - -use _PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider; -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -/** - * @author Nicolas Grekas - */ -class DoctrineProvider extends \_PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - private $pool; - public function __construct(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $pool) - { - $this->pool = $pool; - } - /** - * {@inheritdoc} - */ - public function prune() - { - return $this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface && $this->pool->prune(); - } - /** - * {@inheritdoc} - */ - public function reset() - { - if ($this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { - $this->pool->reset(); - } - $this->setNamespace($this->getNamespace()); - } - /** - * {@inheritdoc} - */ - protected function doFetch($id) - { - $item = $this->pool->getItem(\rawurlencode($id)); - return $item->isHit() ? $item->get() : \false; - } - /** - * {@inheritdoc} - */ - protected function doContains($id) - { - return $this->pool->hasItem(\rawurlencode($id)); - } - /** - * {@inheritdoc} - */ - protected function doSave($id, $data, $lifeTime = 0) - { - $item = $this->pool->getItem(\rawurlencode($id)); - if (0 < $lifeTime) { - $item->expiresAfter($lifeTime); - } - return $this->pool->save($item->set($data)); - } - /** - * {@inheritdoc} - */ - protected function doDelete($id) - { - return $this->pool->deleteItem(\rawurlencode($id)); - } - /** - * {@inheritdoc} - */ - protected function doFlush() - { - return $this->pool->clear(); - } - /** - * {@inheritdoc} - */ - protected function doGetStats() - { - return null; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache; + +use _PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider; +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +/** + * @author Nicolas Grekas + */ +class DoctrineProvider extends \_PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + private $pool; + public function __construct(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $pool) + { + $this->pool = $pool; + } + /** + * {@inheritdoc} + */ + public function prune() + { + return $this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface && $this->pool->prune(); + } + /** + * {@inheritdoc} + */ + public function reset() + { + if ($this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { + $this->pool->reset(); + } + $this->setNamespace($this->getNamespace()); + } + /** + * {@inheritdoc} + */ + protected function doFetch($id) + { + $item = $this->pool->getItem(\rawurlencode($id)); + return $item->isHit() ? $item->get() : \false; + } + /** + * {@inheritdoc} + */ + protected function doContains($id) + { + return $this->pool->hasItem(\rawurlencode($id)); + } + /** + * {@inheritdoc} + */ + protected function doSave($id, $data, $lifeTime = 0) + { + $item = $this->pool->getItem(\rawurlencode($id)); + if (0 < $lifeTime) { + $item->expiresAfter($lifeTime); + } + return $this->pool->save($item->set($data)); + } + /** + * {@inheritdoc} + */ + protected function doDelete($id) + { + return $this->pool->deleteItem(\rawurlencode($id)); + } + /** + * {@inheritdoc} + */ + protected function doFlush() + { + return $this->pool->clear(); + } + /** + * {@inheritdoc} + */ + protected function doGetStats() + { + return null; + } +} diff --git a/vendor/symfony/cache/Exception/CacheException.php b/vendor/symfony/cache/Exception/CacheException.php index 79facebe4..d8fa8381b 100644 --- a/vendor/symfony/cache/Exception/CacheException.php +++ b/vendor/symfony/cache/Exception/CacheException.php @@ -1,17 +1,17 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheException as Psr6CacheInterface; -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException as SimpleCacheInterface; -class CacheException extends \Exception implements \_PhpScoper5ea00cc67502b\Psr\Cache\CacheException, \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheException as Psr6CacheInterface; +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException as SimpleCacheInterface; +class CacheException extends \Exception implements \_PhpScoper5ea00cc67502b\Psr\Cache\CacheException, \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException +{ +} diff --git a/vendor/symfony/cache/Exception/InvalidArgumentException.php b/vendor/symfony/cache/Exception/InvalidArgumentException.php index c22260291..4892712e6 100644 --- a/vendor/symfony/cache/Exception/InvalidArgumentException.php +++ b/vendor/symfony/cache/Exception/InvalidArgumentException.php @@ -1,17 +1,17 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception; - -use _PhpScoper5ea00cc67502b\Psr\Cache\InvalidArgumentException as Psr6CacheInterface; -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\InvalidArgumentException as SimpleCacheInterface; -class InvalidArgumentException extends \InvalidArgumentException implements \_PhpScoper5ea00cc67502b\Psr\Cache\InvalidArgumentException, \_PhpScoper5ea00cc67502b\Psr\SimpleCache\InvalidArgumentException -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception; + +use _PhpScoper5ea00cc67502b\Psr\Cache\InvalidArgumentException as Psr6CacheInterface; +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\InvalidArgumentException as SimpleCacheInterface; +class InvalidArgumentException extends \InvalidArgumentException implements \_PhpScoper5ea00cc67502b\Psr\Cache\InvalidArgumentException, \_PhpScoper5ea00cc67502b\Psr\SimpleCache\InvalidArgumentException +{ +} diff --git a/vendor/symfony/cache/Exception/index.php b/vendor/symfony/cache/Exception/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/Exception/index.php +++ b/vendor/symfony/cache/Exception/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/LICENSE b/vendor/symfony/cache/LICENSE index a7ec70801..ef505071a 100644 --- a/vendor/symfony/cache/LICENSE +++ b/vendor/symfony/cache/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2016-2020 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2016-2020 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/cache/PruneableInterface.php b/vendor/symfony/cache/PruneableInterface.php index 51fad5a1e..45f14e0c4 100644 --- a/vendor/symfony/cache/PruneableInterface.php +++ b/vendor/symfony/cache/PruneableInterface.php @@ -1,22 +1,22 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache; - -/** - * Interface extends psr-6 and psr-16 caches to allow for pruning (deletion) of all expired cache items. - */ -interface PruneableInterface -{ - /** - * @return bool - */ - public function prune(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache; + +/** + * Interface extends psr-6 and psr-16 caches to allow for pruning (deletion) of all expired cache items. + */ +interface PruneableInterface +{ + /** + * @return bool + */ + public function prune(); +} diff --git a/vendor/symfony/cache/README.md b/vendor/symfony/cache/README.md index c4ab7520f..390b4d320 100644 --- a/vendor/symfony/cache/README.md +++ b/vendor/symfony/cache/README.md @@ -1,18 +1,18 @@ -Symfony PSR-6 implementation for caching -======================================== - -This component provides an extended [PSR-6](http://www.php-fig.org/psr/psr-6/) -implementation for adding cache to your applications. It is designed to have a -low overhead so that caching is fastest. It ships with a few caching adapters -for the most widespread and suited to caching backends. It also provides a -`doctrine/cache` proxy adapter to cover more advanced caching needs and a proxy -adapter for greater interoperability between PSR-6 implementations. - -Resources ---------- - - * [Documentation](https://symfony.com/doc/current/components/cache.html) - * [Contributing](https://symfony.com/doc/current/contributing/index.html) - * [Report issues](https://github.com/symfony/symfony/issues) and - [send Pull Requests](https://github.com/symfony/symfony/pulls) - in the [main Symfony repository](https://github.com/symfony/symfony) +Symfony PSR-6 implementation for caching +======================================== + +This component provides an extended [PSR-6](http://www.php-fig.org/psr/psr-6/) +implementation for adding cache to your applications. It is designed to have a +low overhead so that caching is fastest. It ships with a few caching adapters +for the most widespread and suited to caching backends. It also provides a +`doctrine/cache` proxy adapter to cover more advanced caching needs and a proxy +adapter for greater interoperability between PSR-6 implementations. + +Resources +--------- + + * [Documentation](https://symfony.com/doc/current/components/cache.html) + * [Contributing](https://symfony.com/doc/current/contributing/index.html) + * [Report issues](https://github.com/symfony/symfony/issues) and + [send Pull Requests](https://github.com/symfony/symfony/pulls) + in the [main Symfony repository](https://github.com/symfony/symfony) diff --git a/vendor/symfony/cache/ResettableInterface.php b/vendor/symfony/cache/ResettableInterface.php index ac4af738b..eec31bd1c 100644 --- a/vendor/symfony/cache/ResettableInterface.php +++ b/vendor/symfony/cache/ResettableInterface.php @@ -1,19 +1,19 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache; - -/** - * Resets a pool's local state. - */ -interface ResettableInterface -{ - public function reset(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache; + +/** + * Resets a pool's local state. + */ +interface ResettableInterface +{ + public function reset(); +} diff --git a/vendor/symfony/cache/Simple/AbstractCache.php b/vendor/symfony/cache/Simple/AbstractCache.php index a57e02dcc..112af0b83 100644 --- a/vendor/symfony/cache/Simple/AbstractCache.php +++ b/vendor/symfony/cache/Simple/AbstractCache.php @@ -1,167 +1,167 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface; -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\AbstractTrait; -/** - * @author Nicolas Grekas - */ -abstract class AbstractCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - /** - * @internal - */ - const NS_SEPARATOR = ':'; - use AbstractTrait { - deleteItems as private; - AbstractTrait::deleteItem as delete; - AbstractTrait::hasItem as has; - } - private $defaultLifetime; - /** - * @param string $namespace - * @param int $defaultLifetime - */ - protected function __construct($namespace = '', $defaultLifetime = 0) - { - $this->defaultLifetime = \max(0, (int) $defaultLifetime); - $this->namespace = '' === $namespace ? '' : \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($namespace) . ':'; - if (null !== $this->maxIdLength && \strlen($namespace) > $this->maxIdLength - 24) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Namespace must be %d chars max, %d given ("%s").', $this->maxIdLength - 24, \strlen($namespace), $namespace)); - } - } - /** - * {@inheritdoc} - */ - public function get($key, $default = null) - { - $id = $this->getId($key); - try { - foreach ($this->doFetch([$id]) as $value) { - return $value; - } - } catch (\Exception $e) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch key "{key}"', ['key' => $key, 'exception' => $e]); - } - return $default; - } - /** - * {@inheritdoc} - */ - public function set($key, $value, $ttl = null) - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - return $this->setMultiple([$key => $value], $ttl); - } - /** - * {@inheritdoc} - */ - public function getMultiple($keys, $default = null) - { - if ($keys instanceof \Traversable) { - $keys = \iterator_to_array($keys, \false); - } elseif (!\is_array($keys)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); - } - $ids = []; - foreach ($keys as $key) { - $ids[] = $this->getId($key); - } - try { - $values = $this->doFetch($ids); - } catch (\Exception $e) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch requested values', ['keys' => $keys, 'exception' => $e]); - $values = []; - } - $ids = \array_combine($ids, $keys); - return $this->generateValues($values, $ids, $default); - } - /** - * {@inheritdoc} - */ - public function setMultiple($values, $ttl = null) - { - if (!\is_array($values) && !$values instanceof \Traversable) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache values must be array or Traversable, "%s" given.', \is_object($values) ? \get_class($values) : \gettype($values))); - } - $valuesById = []; - foreach ($values as $key => $value) { - if (\is_int($key)) { - $key = (string) $key; - } - $valuesById[$this->getId($key)] = $value; - } - if (\false === ($ttl = $this->normalizeTtl($ttl))) { - return $this->doDelete(\array_keys($valuesById)); - } - try { - $e = $this->doSave($valuesById, $ttl); - } catch (\Exception $e) { - } - if (\true === $e || [] === $e) { - return \true; - } - $keys = []; - foreach (\is_array($e) ? $e : \array_keys($valuesById) as $id) { - $keys[] = \substr($id, \strlen($this->namespace)); - } - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to save values', ['keys' => $keys, 'exception' => $e instanceof \Exception ? $e : null]); - return \false; - } - /** - * {@inheritdoc} - */ - public function deleteMultiple($keys) - { - if ($keys instanceof \Traversable) { - $keys = \iterator_to_array($keys, \false); - } elseif (!\is_array($keys)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); - } - return $this->deleteItems($keys); - } - private function normalizeTtl($ttl) - { - if (null === $ttl) { - return $this->defaultLifetime; - } - if ($ttl instanceof \DateInterval) { - $ttl = (int) \DateTime::createFromFormat('U', 0)->add($ttl)->format('U'); - } - if (\is_int($ttl)) { - return 0 < $ttl ? $ttl : \false; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Expiration date must be an integer, a DateInterval or null, "%s" given.', \is_object($ttl) ? \get_class($ttl) : \gettype($ttl))); - } - private function generateValues($values, &$keys, $default) - { - try { - foreach ($values as $id => $value) { - if (!isset($keys[$id])) { - $id = \key($keys); - } - $key = $keys[$id]; - unset($keys[$id]); - (yield $key => $value); - } - } catch (\Exception $e) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch requested values', ['keys' => \array_values($keys), 'exception' => $e]); - } - foreach ($keys as $key) { - (yield $key => $default); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface; +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\AbstractTrait; +/** + * @author Nicolas Grekas + */ +abstract class AbstractCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + /** + * @internal + */ + const NS_SEPARATOR = ':'; + use AbstractTrait { + deleteItems as private; + AbstractTrait::deleteItem as delete; + AbstractTrait::hasItem as has; + } + private $defaultLifetime; + /** + * @param string $namespace + * @param int $defaultLifetime + */ + protected function __construct($namespace = '', $defaultLifetime = 0) + { + $this->defaultLifetime = \max(0, (int) $defaultLifetime); + $this->namespace = '' === $namespace ? '' : \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($namespace) . ':'; + if (null !== $this->maxIdLength && \strlen($namespace) > $this->maxIdLength - 24) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Namespace must be %d chars max, %d given ("%s").', $this->maxIdLength - 24, \strlen($namespace), $namespace)); + } + } + /** + * {@inheritdoc} + */ + public function get($key, $default = null) + { + $id = $this->getId($key); + try { + foreach ($this->doFetch([$id]) as $value) { + return $value; + } + } catch (\Exception $e) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch key "{key}"', ['key' => $key, 'exception' => $e]); + } + return $default; + } + /** + * {@inheritdoc} + */ + public function set($key, $value, $ttl = null) + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + return $this->setMultiple([$key => $value], $ttl); + } + /** + * {@inheritdoc} + */ + public function getMultiple($keys, $default = null) + { + if ($keys instanceof \Traversable) { + $keys = \iterator_to_array($keys, \false); + } elseif (!\is_array($keys)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); + } + $ids = []; + foreach ($keys as $key) { + $ids[] = $this->getId($key); + } + try { + $values = $this->doFetch($ids); + } catch (\Exception $e) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch requested values', ['keys' => $keys, 'exception' => $e]); + $values = []; + } + $ids = \array_combine($ids, $keys); + return $this->generateValues($values, $ids, $default); + } + /** + * {@inheritdoc} + */ + public function setMultiple($values, $ttl = null) + { + if (!\is_array($values) && !$values instanceof \Traversable) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache values must be array or Traversable, "%s" given.', \is_object($values) ? \get_class($values) : \gettype($values))); + } + $valuesById = []; + foreach ($values as $key => $value) { + if (\is_int($key)) { + $key = (string) $key; + } + $valuesById[$this->getId($key)] = $value; + } + if (\false === ($ttl = $this->normalizeTtl($ttl))) { + return $this->doDelete(\array_keys($valuesById)); + } + try { + $e = $this->doSave($valuesById, $ttl); + } catch (\Exception $e) { + } + if (\true === $e || [] === $e) { + return \true; + } + $keys = []; + foreach (\is_array($e) ? $e : \array_keys($valuesById) as $id) { + $keys[] = \substr($id, \strlen($this->namespace)); + } + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to save values', ['keys' => $keys, 'exception' => $e instanceof \Exception ? $e : null]); + return \false; + } + /** + * {@inheritdoc} + */ + public function deleteMultiple($keys) + { + if ($keys instanceof \Traversable) { + $keys = \iterator_to_array($keys, \false); + } elseif (!\is_array($keys)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); + } + return $this->deleteItems($keys); + } + private function normalizeTtl($ttl) + { + if (null === $ttl) { + return $this->defaultLifetime; + } + if ($ttl instanceof \DateInterval) { + $ttl = (int) \DateTime::createFromFormat('U', 0)->add($ttl)->format('U'); + } + if (\is_int($ttl)) { + return 0 < $ttl ? $ttl : \false; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Expiration date must be an integer, a DateInterval or null, "%s" given.', \is_object($ttl) ? \get_class($ttl) : \gettype($ttl))); + } + private function generateValues($values, &$keys, $default) + { + try { + foreach ($values as $id => $value) { + if (!isset($keys[$id])) { + $id = \key($keys); + } + $key = $keys[$id]; + unset($keys[$id]); + (yield $key => $value); + } + } catch (\Exception $e) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to fetch requested values', ['keys' => \array_values($keys), 'exception' => $e]); + } + foreach ($keys as $key) { + (yield $key => $default); + } + } +} diff --git a/vendor/symfony/cache/Simple/ApcuCache.php b/vendor/symfony/cache/Simple/ApcuCache.php index a2861362b..cc14f69c4 100644 --- a/vendor/symfony/cache/Simple/ApcuCache.php +++ b/vendor/symfony/cache/Simple/ApcuCache.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ApcuTrait; -class ApcuCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache -{ - use ApcuTrait; - /** - * @param string $namespace - * @param int $defaultLifetime - * @param string|null $version - */ - public function __construct($namespace = '', $defaultLifetime = 0, $version = null) - { - $this->init($namespace, $defaultLifetime, $version); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ApcuTrait; +class ApcuCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache +{ + use ApcuTrait; + /** + * @param string $namespace + * @param int $defaultLifetime + * @param string|null $version + */ + public function __construct($namespace = '', $defaultLifetime = 0, $version = null) + { + $this->init($namespace, $defaultLifetime, $version); + } +} diff --git a/vendor/symfony/cache/Simple/ArrayCache.php b/vendor/symfony/cache/Simple/ArrayCache.php index 9e633f1a6..c57212aa6 100644 --- a/vendor/symfony/cache/Simple/ArrayCache.php +++ b/vendor/symfony/cache/Simple/ArrayCache.php @@ -1,132 +1,132 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface; -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ArrayTrait; -/** - * @author Nicolas Grekas - */ -class ArrayCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - use ArrayTrait { - ArrayTrait::deleteItem as delete; - ArrayTrait::hasItem as has; - } - private $defaultLifetime; - /** - * @param int $defaultLifetime - * @param bool $storeSerialized Disabling serialization can lead to cache corruptions when storing mutable values but increases performance otherwise - */ - public function __construct($defaultLifetime = 0, $storeSerialized = \true) - { - $this->defaultLifetime = (int) $defaultLifetime; - $this->storeSerialized = $storeSerialized; - } - /** - * {@inheritdoc} - */ - public function get($key, $default = null) - { - foreach ($this->getMultiple([$key], $default) as $v) { - return $v; - } - } - /** - * {@inheritdoc} - */ - public function getMultiple($keys, $default = null) - { - if ($keys instanceof \Traversable) { - $keys = \iterator_to_array($keys, \false); - } elseif (!\is_array($keys)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); - } - foreach ($keys as $key) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - } - return $this->generateItems($keys, \time(), function ($k, $v, $hit) use($default) { - return $hit ? $v : $default; - }); - } - /** - * {@inheritdoc} - */ - public function deleteMultiple($keys) - { - if (!\is_array($keys) && !$keys instanceof \Traversable) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); - } - foreach ($keys as $key) { - $this->delete($key); - } - return \true; - } - /** - * {@inheritdoc} - */ - public function set($key, $value, $ttl = null) - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - return $this->setMultiple([$key => $value], $ttl); - } - /** - * {@inheritdoc} - */ - public function setMultiple($values, $ttl = null) - { - if (!\is_array($values) && !$values instanceof \Traversable) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache values must be array or Traversable, "%s" given.', \is_object($values) ? \get_class($values) : \gettype($values))); - } - $valuesArray = []; - foreach ($values as $key => $value) { - \is_int($key) || \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - $valuesArray[$key] = $value; - } - if (\false === ($ttl = $this->normalizeTtl($ttl))) { - return $this->deleteMultiple(\array_keys($valuesArray)); - } - if ($this->storeSerialized) { - foreach ($valuesArray as $key => $value) { - try { - $valuesArray[$key] = \serialize($value); - } catch (\Exception $e) { - $type = \is_object($value) ? \get_class($value) : \gettype($value); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to save key "{key}" ({type})', ['key' => $key, 'type' => $type, 'exception' => $e]); - return \false; - } - } - } - $expiry = 0 < $ttl ? \time() + $ttl : \PHP_INT_MAX; - foreach ($valuesArray as $key => $value) { - $this->values[$key] = $value; - $this->expiries[$key] = $expiry; - } - return \true; - } - private function normalizeTtl($ttl) - { - if (null === $ttl) { - return $this->defaultLifetime; - } - if ($ttl instanceof \DateInterval) { - $ttl = (int) \DateTime::createFromFormat('U', 0)->add($ttl)->format('U'); - } - if (\is_int($ttl)) { - return 0 < $ttl ? $ttl : \false; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Expiration date must be an integer, a DateInterval or null, "%s" given.', \is_object($ttl) ? \get_class($ttl) : \gettype($ttl))); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface; +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ArrayTrait; +/** + * @author Nicolas Grekas + */ +class ArrayCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + use ArrayTrait { + ArrayTrait::deleteItem as delete; + ArrayTrait::hasItem as has; + } + private $defaultLifetime; + /** + * @param int $defaultLifetime + * @param bool $storeSerialized Disabling serialization can lead to cache corruptions when storing mutable values but increases performance otherwise + */ + public function __construct($defaultLifetime = 0, $storeSerialized = \true) + { + $this->defaultLifetime = (int) $defaultLifetime; + $this->storeSerialized = $storeSerialized; + } + /** + * {@inheritdoc} + */ + public function get($key, $default = null) + { + foreach ($this->getMultiple([$key], $default) as $v) { + return $v; + } + } + /** + * {@inheritdoc} + */ + public function getMultiple($keys, $default = null) + { + if ($keys instanceof \Traversable) { + $keys = \iterator_to_array($keys, \false); + } elseif (!\is_array($keys)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); + } + foreach ($keys as $key) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + } + return $this->generateItems($keys, \time(), function ($k, $v, $hit) use($default) { + return $hit ? $v : $default; + }); + } + /** + * {@inheritdoc} + */ + public function deleteMultiple($keys) + { + if (!\is_array($keys) && !$keys instanceof \Traversable) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); + } + foreach ($keys as $key) { + $this->delete($key); + } + return \true; + } + /** + * {@inheritdoc} + */ + public function set($key, $value, $ttl = null) + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + return $this->setMultiple([$key => $value], $ttl); + } + /** + * {@inheritdoc} + */ + public function setMultiple($values, $ttl = null) + { + if (!\is_array($values) && !$values instanceof \Traversable) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache values must be array or Traversable, "%s" given.', \is_object($values) ? \get_class($values) : \gettype($values))); + } + $valuesArray = []; + foreach ($values as $key => $value) { + \is_int($key) || \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + $valuesArray[$key] = $value; + } + if (\false === ($ttl = $this->normalizeTtl($ttl))) { + return $this->deleteMultiple(\array_keys($valuesArray)); + } + if ($this->storeSerialized) { + foreach ($valuesArray as $key => $value) { + try { + $valuesArray[$key] = \serialize($value); + } catch (\Exception $e) { + $type = \is_object($value) ? \get_class($value) : \gettype($value); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to save key "{key}" ({type})', ['key' => $key, 'type' => $type, 'exception' => $e]); + return \false; + } + } + } + $expiry = 0 < $ttl ? \time() + $ttl : \PHP_INT_MAX; + foreach ($valuesArray as $key => $value) { + $this->values[$key] = $value; + $this->expiries[$key] = $expiry; + } + return \true; + } + private function normalizeTtl($ttl) + { + if (null === $ttl) { + return $this->defaultLifetime; + } + if ($ttl instanceof \DateInterval) { + $ttl = (int) \DateTime::createFromFormat('U', 0)->add($ttl)->format('U'); + } + if (\is_int($ttl)) { + return 0 < $ttl ? $ttl : \false; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Expiration date must be an integer, a DateInterval or null, "%s" given.', \is_object($ttl) ? \get_class($ttl) : \gettype($ttl))); + } +} diff --git a/vendor/symfony/cache/Simple/ChainCache.php b/vendor/symfony/cache/Simple/ChainCache.php index e44dc13a1..fd02ca9d3 100644 --- a/vendor/symfony/cache/Simple/ChainCache.php +++ b/vendor/symfony/cache/Simple/ChainCache.php @@ -1,213 +1,213 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -/** - * Chains several caches together. - * - * Cached items are fetched from the first cache having them in its data store. - * They are saved and deleted in all caches at once. - * - * @author Nicolas Grekas - */ -class ChainCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - private $miss; - private $caches = []; - private $defaultLifetime; - private $cacheCount; - /** - * @param CacheInterface[] $caches The ordered list of caches used to fetch cached items - * @param int $defaultLifetime The lifetime of items propagated from lower caches to upper ones - */ - public function __construct(array $caches, $defaultLifetime = 0) - { - if (!$caches) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException('At least one cache must be specified.'); - } - foreach ($caches as $cache) { - if (!$cache instanceof \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('The class "%s" does not implement the "%s" interface.', \get_class($cache), \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface::class)); - } - } - $this->miss = new \stdClass(); - $this->caches = \array_values($caches); - $this->cacheCount = \count($this->caches); - $this->defaultLifetime = 0 < $defaultLifetime ? (int) $defaultLifetime : null; - } - /** - * {@inheritdoc} - */ - public function get($key, $default = null) - { - $miss = null !== $default && \is_object($default) ? $default : $this->miss; - foreach ($this->caches as $i => $cache) { - $value = $cache->get($key, $miss); - if ($miss !== $value) { - while (0 <= --$i) { - $this->caches[$i]->set($key, $value, $this->defaultLifetime); - } - return $value; - } - } - return $default; - } - /** - * {@inheritdoc} - */ - public function getMultiple($keys, $default = null) - { - $miss = null !== $default && \is_object($default) ? $default : $this->miss; - return $this->generateItems($this->caches[0]->getMultiple($keys, $miss), 0, $miss, $default); - } - private function generateItems($values, $cacheIndex, $miss, $default) - { - $missing = []; - $nextCacheIndex = $cacheIndex + 1; - $nextCache = isset($this->caches[$nextCacheIndex]) ? $this->caches[$nextCacheIndex] : null; - foreach ($values as $k => $value) { - if ($miss !== $value) { - (yield $k => $value); - } elseif (!$nextCache) { - (yield $k => $default); - } else { - $missing[] = $k; - } - } - if ($missing) { - $cache = $this->caches[$cacheIndex]; - $values = $this->generateItems($nextCache->getMultiple($missing, $miss), $nextCacheIndex, $miss, $default); - foreach ($values as $k => $value) { - if ($miss !== $value) { - $cache->set($k, $value, $this->defaultLifetime); - (yield $k => $value); - } else { - (yield $k => $default); - } - } - } - } - /** - * {@inheritdoc} - */ - public function has($key) - { - foreach ($this->caches as $cache) { - if ($cache->has($key)) { - return \true; - } - } - return \false; - } - /** - * {@inheritdoc} - */ - public function clear() - { - $cleared = \true; - $i = $this->cacheCount; - while ($i--) { - $cleared = $this->caches[$i]->clear() && $cleared; - } - return $cleared; - } - /** - * {@inheritdoc} - */ - public function delete($key) - { - $deleted = \true; - $i = $this->cacheCount; - while ($i--) { - $deleted = $this->caches[$i]->delete($key) && $deleted; - } - return $deleted; - } - /** - * {@inheritdoc} - */ - public function deleteMultiple($keys) - { - if ($keys instanceof \Traversable) { - $keys = \iterator_to_array($keys, \false); - } - $deleted = \true; - $i = $this->cacheCount; - while ($i--) { - $deleted = $this->caches[$i]->deleteMultiple($keys) && $deleted; - } - return $deleted; - } - /** - * {@inheritdoc} - */ - public function set($key, $value, $ttl = null) - { - $saved = \true; - $i = $this->cacheCount; - while ($i--) { - $saved = $this->caches[$i]->set($key, $value, $ttl) && $saved; - } - return $saved; - } - /** - * {@inheritdoc} - */ - public function setMultiple($values, $ttl = null) - { - if ($values instanceof \Traversable) { - $valuesIterator = $values; - $values = function () use($valuesIterator, &$values) { - $generatedValues = []; - foreach ($valuesIterator as $key => $value) { - (yield $key => $value); - $generatedValues[$key] = $value; - } - $values = $generatedValues; - }; - $values = $values(); - } - $saved = \true; - $i = $this->cacheCount; - while ($i--) { - $saved = $this->caches[$i]->setMultiple($values, $ttl) && $saved; - } - return $saved; - } - /** - * {@inheritdoc} - */ - public function prune() - { - $pruned = \true; - foreach ($this->caches as $cache) { - if ($cache instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { - $pruned = $cache->prune() && $pruned; - } - } - return $pruned; - } - /** - * {@inheritdoc} - */ - public function reset() - { - foreach ($this->caches as $cache) { - if ($cache instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { - $cache->reset(); - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +/** + * Chains several caches together. + * + * Cached items are fetched from the first cache having them in its data store. + * They are saved and deleted in all caches at once. + * + * @author Nicolas Grekas + */ +class ChainCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + private $miss; + private $caches = []; + private $defaultLifetime; + private $cacheCount; + /** + * @param CacheInterface[] $caches The ordered list of caches used to fetch cached items + * @param int $defaultLifetime The lifetime of items propagated from lower caches to upper ones + */ + public function __construct(array $caches, $defaultLifetime = 0) + { + if (!$caches) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException('At least one cache must be specified.'); + } + foreach ($caches as $cache) { + if (!$cache instanceof \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('The class "%s" does not implement the "%s" interface.', \get_class($cache), \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface::class)); + } + } + $this->miss = new \stdClass(); + $this->caches = \array_values($caches); + $this->cacheCount = \count($this->caches); + $this->defaultLifetime = 0 < $defaultLifetime ? (int) $defaultLifetime : null; + } + /** + * {@inheritdoc} + */ + public function get($key, $default = null) + { + $miss = null !== $default && \is_object($default) ? $default : $this->miss; + foreach ($this->caches as $i => $cache) { + $value = $cache->get($key, $miss); + if ($miss !== $value) { + while (0 <= --$i) { + $this->caches[$i]->set($key, $value, $this->defaultLifetime); + } + return $value; + } + } + return $default; + } + /** + * {@inheritdoc} + */ + public function getMultiple($keys, $default = null) + { + $miss = null !== $default && \is_object($default) ? $default : $this->miss; + return $this->generateItems($this->caches[0]->getMultiple($keys, $miss), 0, $miss, $default); + } + private function generateItems($values, $cacheIndex, $miss, $default) + { + $missing = []; + $nextCacheIndex = $cacheIndex + 1; + $nextCache = isset($this->caches[$nextCacheIndex]) ? $this->caches[$nextCacheIndex] : null; + foreach ($values as $k => $value) { + if ($miss !== $value) { + (yield $k => $value); + } elseif (!$nextCache) { + (yield $k => $default); + } else { + $missing[] = $k; + } + } + if ($missing) { + $cache = $this->caches[$cacheIndex]; + $values = $this->generateItems($nextCache->getMultiple($missing, $miss), $nextCacheIndex, $miss, $default); + foreach ($values as $k => $value) { + if ($miss !== $value) { + $cache->set($k, $value, $this->defaultLifetime); + (yield $k => $value); + } else { + (yield $k => $default); + } + } + } + } + /** + * {@inheritdoc} + */ + public function has($key) + { + foreach ($this->caches as $cache) { + if ($cache->has($key)) { + return \true; + } + } + return \false; + } + /** + * {@inheritdoc} + */ + public function clear() + { + $cleared = \true; + $i = $this->cacheCount; + while ($i--) { + $cleared = $this->caches[$i]->clear() && $cleared; + } + return $cleared; + } + /** + * {@inheritdoc} + */ + public function delete($key) + { + $deleted = \true; + $i = $this->cacheCount; + while ($i--) { + $deleted = $this->caches[$i]->delete($key) && $deleted; + } + return $deleted; + } + /** + * {@inheritdoc} + */ + public function deleteMultiple($keys) + { + if ($keys instanceof \Traversable) { + $keys = \iterator_to_array($keys, \false); + } + $deleted = \true; + $i = $this->cacheCount; + while ($i--) { + $deleted = $this->caches[$i]->deleteMultiple($keys) && $deleted; + } + return $deleted; + } + /** + * {@inheritdoc} + */ + public function set($key, $value, $ttl = null) + { + $saved = \true; + $i = $this->cacheCount; + while ($i--) { + $saved = $this->caches[$i]->set($key, $value, $ttl) && $saved; + } + return $saved; + } + /** + * {@inheritdoc} + */ + public function setMultiple($values, $ttl = null) + { + if ($values instanceof \Traversable) { + $valuesIterator = $values; + $values = function () use($valuesIterator, &$values) { + $generatedValues = []; + foreach ($valuesIterator as $key => $value) { + (yield $key => $value); + $generatedValues[$key] = $value; + } + $values = $generatedValues; + }; + $values = $values(); + } + $saved = \true; + $i = $this->cacheCount; + while ($i--) { + $saved = $this->caches[$i]->setMultiple($values, $ttl) && $saved; + } + return $saved; + } + /** + * {@inheritdoc} + */ + public function prune() + { + $pruned = \true; + foreach ($this->caches as $cache) { + if ($cache instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { + $pruned = $cache->prune() && $pruned; + } + } + return $pruned; + } + /** + * {@inheritdoc} + */ + public function reset() + { + foreach ($this->caches as $cache) { + if ($cache instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { + $cache->reset(); + } + } + } +} diff --git a/vendor/symfony/cache/Simple/DoctrineCache.php b/vendor/symfony/cache/Simple/DoctrineCache.php index 92da9b53a..63b80b314 100644 --- a/vendor/symfony/cache/Simple/DoctrineCache.php +++ b/vendor/symfony/cache/Simple/DoctrineCache.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\DoctrineTrait; -class DoctrineCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache -{ - use DoctrineTrait; - /** - * @param string $namespace - * @param int $defaultLifetime - */ - public function __construct(\_PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider $provider, $namespace = '', $defaultLifetime = 0) - { - parent::__construct('', $defaultLifetime); - $this->provider = $provider; - $provider->setNamespace($namespace); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\DoctrineTrait; +class DoctrineCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache +{ + use DoctrineTrait; + /** + * @param string $namespace + * @param int $defaultLifetime + */ + public function __construct(\_PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider $provider, $namespace = '', $defaultLifetime = 0) + { + parent::__construct('', $defaultLifetime); + $this->provider = $provider; + $provider->setNamespace($namespace); + } +} diff --git a/vendor/symfony/cache/Simple/FilesystemCache.php b/vendor/symfony/cache/Simple/FilesystemCache.php index 1c1a5e5b0..a1817f1ec 100644 --- a/vendor/symfony/cache/Simple/FilesystemCache.php +++ b/vendor/symfony/cache/Simple/FilesystemCache.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\FilesystemTrait; -class FilesystemCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface -{ - use FilesystemTrait; - /** - * @param string $namespace - * @param int $defaultLifetime - * @param string|null $directory - */ - public function __construct($namespace = '', $defaultLifetime = 0, $directory = null) - { - parent::__construct('', $defaultLifetime); - $this->init($namespace, $directory); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\FilesystemTrait; +class FilesystemCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface +{ + use FilesystemTrait; + /** + * @param string $namespace + * @param int $defaultLifetime + * @param string|null $directory + */ + public function __construct($namespace = '', $defaultLifetime = 0, $directory = null) + { + parent::__construct('', $defaultLifetime); + $this->init($namespace, $directory); + } +} diff --git a/vendor/symfony/cache/Simple/MemcachedCache.php b/vendor/symfony/cache/Simple/MemcachedCache.php index a63840a24..50bd9dd60 100644 --- a/vendor/symfony/cache/Simple/MemcachedCache.php +++ b/vendor/symfony/cache/Simple/MemcachedCache.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\MemcachedTrait; -class MemcachedCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache -{ - use MemcachedTrait; - protected $maxIdLength = 250; - /** - * @param string $namespace - * @param int $defaultLifetime - */ - public function __construct(\_PhpScoper5ea00cc67502b\Memcached $client, $namespace = '', $defaultLifetime = 0) - { - $this->init($client, $namespace, $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\MemcachedTrait; +class MemcachedCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache +{ + use MemcachedTrait; + protected $maxIdLength = 250; + /** + * @param string $namespace + * @param int $defaultLifetime + */ + public function __construct(\_PhpScoper5ea00cc67502b\Memcached $client, $namespace = '', $defaultLifetime = 0) + { + $this->init($client, $namespace, $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Simple/NullCache.php b/vendor/symfony/cache/Simple/NullCache.php index b637721fb..e8bcb921c 100644 --- a/vendor/symfony/cache/Simple/NullCache.php +++ b/vendor/symfony/cache/Simple/NullCache.php @@ -1,77 +1,77 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -/** - * @author Nicolas Grekas - */ -class NullCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface -{ - /** - * {@inheritdoc} - */ - public function get($key, $default = null) - { - return $default; - } - /** - * {@inheritdoc} - */ - public function getMultiple($keys, $default = null) - { - foreach ($keys as $key) { - (yield $key => $default); - } - } - /** - * {@inheritdoc} - */ - public function has($key) - { - return \false; - } - /** - * {@inheritdoc} - */ - public function clear() - { - return \true; - } - /** - * {@inheritdoc} - */ - public function delete($key) - { - return \true; - } - /** - * {@inheritdoc} - */ - public function deleteMultiple($keys) - { - return \true; - } - /** - * {@inheritdoc} - */ - public function set($key, $value, $ttl = null) - { - return \false; - } - /** - * {@inheritdoc} - */ - public function setMultiple($values, $ttl = null) - { - return \false; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +/** + * @author Nicolas Grekas + */ +class NullCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface +{ + /** + * {@inheritdoc} + */ + public function get($key, $default = null) + { + return $default; + } + /** + * {@inheritdoc} + */ + public function getMultiple($keys, $default = null) + { + foreach ($keys as $key) { + (yield $key => $default); + } + } + /** + * {@inheritdoc} + */ + public function has($key) + { + return \false; + } + /** + * {@inheritdoc} + */ + public function clear() + { + return \true; + } + /** + * {@inheritdoc} + */ + public function delete($key) + { + return \true; + } + /** + * {@inheritdoc} + */ + public function deleteMultiple($keys) + { + return \true; + } + /** + * {@inheritdoc} + */ + public function set($key, $value, $ttl = null) + { + return \false; + } + /** + * {@inheritdoc} + */ + public function setMultiple($values, $ttl = null) + { + return \false; + } +} diff --git a/vendor/symfony/cache/Simple/PdoCache.php b/vendor/symfony/cache/Simple/PdoCache.php index 6737e288a..f30f36ccc 100644 --- a/vendor/symfony/cache/Simple/PdoCache.php +++ b/vendor/symfony/cache/Simple/PdoCache.php @@ -1,47 +1,47 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PdoTrait; -class PdoCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface -{ - use PdoTrait; - protected $maxIdLength = 255; - /** - * You can either pass an existing database connection as PDO instance or - * a Doctrine DBAL Connection or a DSN string that will be used to - * lazy-connect to the database when the cache is actually used. - * - * List of available options: - * * db_table: The name of the table [default: cache_items] - * * db_id_col: The column where to store the cache id [default: item_id] - * * db_data_col: The column where to store the cache data [default: item_data] - * * db_lifetime_col: The column where to store the lifetime [default: item_lifetime] - * * db_time_col: The column where to store the timestamp [default: item_time] - * * db_username: The username when lazy-connect [default: ''] - * * db_password: The password when lazy-connect [default: ''] - * * db_connection_options: An array of driver-specific connection options [default: []] - * - * @param \PDO|Connection|string $connOrDsn A \PDO or Connection instance or DSN string or null - * @param string $namespace - * @param int $defaultLifetime - * @param array $options An associative array of options - * - * @throws InvalidArgumentException When first argument is not PDO nor Connection nor string - * @throws InvalidArgumentException When PDO error mode is not PDO::ERRMODE_EXCEPTION - * @throws InvalidArgumentException When namespace contains invalid characters - */ - public function __construct($connOrDsn, $namespace = '', $defaultLifetime = 0, array $options = []) - { - $this->init($connOrDsn, $namespace, $defaultLifetime, $options); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PdoTrait; +class PdoCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface +{ + use PdoTrait; + protected $maxIdLength = 255; + /** + * You can either pass an existing database connection as PDO instance or + * a Doctrine DBAL Connection or a DSN string that will be used to + * lazy-connect to the database when the cache is actually used. + * + * List of available options: + * * db_table: The name of the table [default: cache_items] + * * db_id_col: The column where to store the cache id [default: item_id] + * * db_data_col: The column where to store the cache data [default: item_data] + * * db_lifetime_col: The column where to store the lifetime [default: item_lifetime] + * * db_time_col: The column where to store the timestamp [default: item_time] + * * db_username: The username when lazy-connect [default: ''] + * * db_password: The password when lazy-connect [default: ''] + * * db_connection_options: An array of driver-specific connection options [default: []] + * + * @param \PDO|Connection|string $connOrDsn A \PDO or Connection instance or DSN string or null + * @param string $namespace + * @param int $defaultLifetime + * @param array $options An associative array of options + * + * @throws InvalidArgumentException When first argument is not PDO nor Connection nor string + * @throws InvalidArgumentException When PDO error mode is not PDO::ERRMODE_EXCEPTION + * @throws InvalidArgumentException When namespace contains invalid characters + */ + public function __construct($connOrDsn, $namespace = '', $defaultLifetime = 0, array $options = []) + { + $this->init($connOrDsn, $namespace, $defaultLifetime, $options); + } +} diff --git a/vendor/symfony/cache/Simple/PhpArrayCache.php b/vendor/symfony/cache/Simple/PhpArrayCache.php index 829721b9c..426439d93 100644 --- a/vendor/symfony/cache/Simple/PhpArrayCache.php +++ b/vendor/symfony/cache/Simple/PhpArrayCache.php @@ -1,226 +1,226 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PhpArrayTrait; -/** - * Caches items at warm up time using a PHP array that is stored in shared memory by OPCache since PHP 7.0. - * Warmed up items are read-only and run-time discovered items are cached using a fallback adapter. - * - * @author Titouan Galopin - * @author Nicolas Grekas - */ -class PhpArrayCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - use PhpArrayTrait; - /** - * @param string $file The PHP file were values are cached - * @param CacheInterface $fallbackPool A pool to fallback on when an item is not hit - */ - public function __construct($file, \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $fallbackPool) - { - $this->file = $file; - $this->pool = $fallbackPool; - $this->zendDetectUnicode = \filter_var(\ini_get('zend.detect_unicode'), \FILTER_VALIDATE_BOOLEAN); - } - /** - * This adapter should only be used on PHP 7.0+ to take advantage of how PHP - * stores arrays in its latest versions. This factory method decorates the given - * fallback pool with this adapter only if the current PHP version is supported. - * - * @param string $file The PHP file were values are cached - * @param CacheInterface $fallbackPool A pool to fallback on when an item is not hit - * - * @return CacheInterface - */ - public static function create($file, \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $fallbackPool) - { - if (\PHP_VERSION_ID >= 70000) { - return new static($file, $fallbackPool); - } - return $fallbackPool; - } - /** - * {@inheritdoc} - */ - public function get($key, $default = null) - { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if (null === $this->values) { - $this->initialize(); - } - if (!isset($this->values[$key])) { - return $this->pool->get($key, $default); - } - $value = $this->values[$key]; - if ('N;' === $value) { - $value = null; - } elseif (\is_string($value) && isset($value[2]) && ':' === $value[1]) { - try { - $e = null; - $value = \unserialize($value); - } catch (\Error $e) { - } catch (\Exception $e) { - } - if (null !== $e) { - return $default; - } - } - return $value; - } - /** - * {@inheritdoc} - */ - public function getMultiple($keys, $default = null) - { - if ($keys instanceof \Traversable) { - $keys = \iterator_to_array($keys, \false); - } elseif (!\is_array($keys)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); - } - foreach ($keys as $key) { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - } - if (null === $this->values) { - $this->initialize(); - } - return $this->generateItems($keys, $default); - } - /** - * {@inheritdoc} - */ - public function has($key) - { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if (null === $this->values) { - $this->initialize(); - } - return isset($this->values[$key]) || $this->pool->has($key); - } - /** - * {@inheritdoc} - */ - public function delete($key) - { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if (null === $this->values) { - $this->initialize(); - } - return !isset($this->values[$key]) && $this->pool->delete($key); - } - /** - * {@inheritdoc} - */ - public function deleteMultiple($keys) - { - if (!\is_array($keys) && !$keys instanceof \Traversable) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); - } - $deleted = \true; - $fallbackKeys = []; - foreach ($keys as $key) { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if (isset($this->values[$key])) { - $deleted = \false; - } else { - $fallbackKeys[] = $key; - } - } - if (null === $this->values) { - $this->initialize(); - } - if ($fallbackKeys) { - $deleted = $this->pool->deleteMultiple($fallbackKeys) && $deleted; - } - return $deleted; - } - /** - * {@inheritdoc} - */ - public function set($key, $value, $ttl = null) - { - if (!\is_string($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if (null === $this->values) { - $this->initialize(); - } - return !isset($this->values[$key]) && $this->pool->set($key, $value, $ttl); - } - /** - * {@inheritdoc} - */ - public function setMultiple($values, $ttl = null) - { - if (!\is_array($values) && !$values instanceof \Traversable) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache values must be array or Traversable, "%s" given.', \is_object($values) ? \get_class($values) : \gettype($values))); - } - $saved = \true; - $fallbackValues = []; - foreach ($values as $key => $value) { - if (!\is_string($key) && !\is_int($key)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); - } - if (isset($this->values[$key])) { - $saved = \false; - } else { - $fallbackValues[$key] = $value; - } - } - if ($fallbackValues) { - $saved = $this->pool->setMultiple($fallbackValues, $ttl) && $saved; - } - return $saved; - } - private function generateItems(array $keys, $default) - { - $fallbackKeys = []; - foreach ($keys as $key) { - if (isset($this->values[$key])) { - $value = $this->values[$key]; - if ('N;' === $value) { - (yield $key => null); - } elseif (\is_string($value) && isset($value[2]) && ':' === $value[1]) { - try { - (yield $key => \unserialize($value)); - } catch (\Error $e) { - (yield $key => $default); - } catch (\Exception $e) { - (yield $key => $default); - } - } else { - (yield $key => $value); - } - } else { - $fallbackKeys[] = $key; - } - } - if ($fallbackKeys) { - foreach ($this->pool->getMultiple($fallbackKeys, $default) as $key => $item) { - (yield $key => $item); - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PhpArrayTrait; +/** + * Caches items at warm up time using a PHP array that is stored in shared memory by OPCache since PHP 7.0. + * Warmed up items are read-only and run-time discovered items are cached using a fallback adapter. + * + * @author Titouan Galopin + * @author Nicolas Grekas + */ +class PhpArrayCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + use PhpArrayTrait; + /** + * @param string $file The PHP file were values are cached + * @param CacheInterface $fallbackPool A pool to fallback on when an item is not hit + */ + public function __construct($file, \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $fallbackPool) + { + $this->file = $file; + $this->pool = $fallbackPool; + $this->zendDetectUnicode = \filter_var(\ini_get('zend.detect_unicode'), \FILTER_VALIDATE_BOOLEAN); + } + /** + * This adapter should only be used on PHP 7.0+ to take advantage of how PHP + * stores arrays in its latest versions. This factory method decorates the given + * fallback pool with this adapter only if the current PHP version is supported. + * + * @param string $file The PHP file were values are cached + * @param CacheInterface $fallbackPool A pool to fallback on when an item is not hit + * + * @return CacheInterface + */ + public static function create($file, \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $fallbackPool) + { + if (\PHP_VERSION_ID >= 70000) { + return new static($file, $fallbackPool); + } + return $fallbackPool; + } + /** + * {@inheritdoc} + */ + public function get($key, $default = null) + { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if (null === $this->values) { + $this->initialize(); + } + if (!isset($this->values[$key])) { + return $this->pool->get($key, $default); + } + $value = $this->values[$key]; + if ('N;' === $value) { + $value = null; + } elseif (\is_string($value) && isset($value[2]) && ':' === $value[1]) { + try { + $e = null; + $value = \unserialize($value); + } catch (\Error $e) { + } catch (\Exception $e) { + } + if (null !== $e) { + return $default; + } + } + return $value; + } + /** + * {@inheritdoc} + */ + public function getMultiple($keys, $default = null) + { + if ($keys instanceof \Traversable) { + $keys = \iterator_to_array($keys, \false); + } elseif (!\is_array($keys)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); + } + foreach ($keys as $key) { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + } + if (null === $this->values) { + $this->initialize(); + } + return $this->generateItems($keys, $default); + } + /** + * {@inheritdoc} + */ + public function has($key) + { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if (null === $this->values) { + $this->initialize(); + } + return isset($this->values[$key]) || $this->pool->has($key); + } + /** + * {@inheritdoc} + */ + public function delete($key) + { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if (null === $this->values) { + $this->initialize(); + } + return !isset($this->values[$key]) && $this->pool->delete($key); + } + /** + * {@inheritdoc} + */ + public function deleteMultiple($keys) + { + if (!\is_array($keys) && !$keys instanceof \Traversable) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); + } + $deleted = \true; + $fallbackKeys = []; + foreach ($keys as $key) { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if (isset($this->values[$key])) { + $deleted = \false; + } else { + $fallbackKeys[] = $key; + } + } + if (null === $this->values) { + $this->initialize(); + } + if ($fallbackKeys) { + $deleted = $this->pool->deleteMultiple($fallbackKeys) && $deleted; + } + return $deleted; + } + /** + * {@inheritdoc} + */ + public function set($key, $value, $ttl = null) + { + if (!\is_string($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if (null === $this->values) { + $this->initialize(); + } + return !isset($this->values[$key]) && $this->pool->set($key, $value, $ttl); + } + /** + * {@inheritdoc} + */ + public function setMultiple($values, $ttl = null) + { + if (!\is_array($values) && !$values instanceof \Traversable) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache values must be array or Traversable, "%s" given.', \is_object($values) ? \get_class($values) : \gettype($values))); + } + $saved = \true; + $fallbackValues = []; + foreach ($values as $key => $value) { + if (!\is_string($key) && !\is_int($key)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key must be string, "%s" given.', \is_object($key) ? \get_class($key) : \gettype($key))); + } + if (isset($this->values[$key])) { + $saved = \false; + } else { + $fallbackValues[$key] = $value; + } + } + if ($fallbackValues) { + $saved = $this->pool->setMultiple($fallbackValues, $ttl) && $saved; + } + return $saved; + } + private function generateItems(array $keys, $default) + { + $fallbackKeys = []; + foreach ($keys as $key) { + if (isset($this->values[$key])) { + $value = $this->values[$key]; + if ('N;' === $value) { + (yield $key => null); + } elseif (\is_string($value) && isset($value[2]) && ':' === $value[1]) { + try { + (yield $key => \unserialize($value)); + } catch (\Error $e) { + (yield $key => $default); + } catch (\Exception $e) { + (yield $key => $default); + } + } else { + (yield $key => $value); + } + } else { + $fallbackKeys[] = $key; + } + } + if ($fallbackKeys) { + foreach ($this->pool->getMultiple($fallbackKeys, $default) as $key => $item) { + (yield $key => $item); + } + } + } +} diff --git a/vendor/symfony/cache/Simple/PhpFilesCache.php b/vendor/symfony/cache/Simple/PhpFilesCache.php index 20b93fae1..05bca81ed 100644 --- a/vendor/symfony/cache/Simple/PhpFilesCache.php +++ b/vendor/symfony/cache/Simple/PhpFilesCache.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PhpFilesTrait; -class PhpFilesCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface -{ - use PhpFilesTrait; - /** - * @param string $namespace - * @param int $defaultLifetime - * @param string|null $directory - * - * @throws CacheException if OPcache is not enabled - */ - public function __construct($namespace = '', $defaultLifetime = 0, $directory = null) - { - if (!static::isSupported()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('OPcache is not enabled.'); - } - parent::__construct('', $defaultLifetime); - $this->init($namespace, $directory); - $e = new \Exception(); - $this->includeHandler = function () use($e) { - throw $e; - }; - $this->zendDetectUnicode = \filter_var(\ini_get('zend.detect_unicode'), \FILTER_VALIDATE_BOOLEAN); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\PhpFilesTrait; +class PhpFilesCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache implements \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface +{ + use PhpFilesTrait; + /** + * @param string $namespace + * @param int $defaultLifetime + * @param string|null $directory + * + * @throws CacheException if OPcache is not enabled + */ + public function __construct($namespace = '', $defaultLifetime = 0, $directory = null) + { + if (!static::isSupported()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('OPcache is not enabled.'); + } + parent::__construct('', $defaultLifetime); + $this->init($namespace, $directory); + $e = new \Exception(); + $this->includeHandler = function () use($e) { + throw $e; + }; + $this->zendDetectUnicode = \filter_var(\ini_get('zend.detect_unicode'), \FILTER_VALIDATE_BOOLEAN); + } +} diff --git a/vendor/symfony/cache/Simple/Psr6Cache.php b/vendor/symfony/cache/Simple/Psr6Cache.php index ad01125b1..9ae6af88b 100644 --- a/vendor/symfony/cache/Simple/Psr6Cache.php +++ b/vendor/symfony/cache/Simple/Psr6Cache.php @@ -1,213 +1,213 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheException as Psr6CacheException; -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException as SimpleCacheException; -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ProxyTrait; -/** - * @author Nicolas Grekas - */ -class Psr6Cache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - use ProxyTrait; - private $createCacheItem; - private $cacheItemPrototype; - public function __construct(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $pool) - { - $this->pool = $pool; - if (!$pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface) { - return; - } - $cacheItemPrototype =& $this->cacheItemPrototype; - $createCacheItem = \Closure::bind(static function ($key, $value, $allowInt = \false) use(&$cacheItemPrototype) { - $item = clone $cacheItemPrototype; - $item->key = $allowInt && \is_int($key) ? (string) $key : \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - $item->value = $value; - $item->isHit = \false; - return $item; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - $this->createCacheItem = function ($key, $value, $allowInt = \false) use($createCacheItem) { - if (null === $this->cacheItemPrototype) { - $this->get($allowInt && \is_int($key) ? (string) $key : $key); - } - $this->createCacheItem = $createCacheItem; - return $createCacheItem($key, $value, $allowInt); - }; - } - /** - * {@inheritdoc} - */ - public function get($key, $default = null) - { - try { - $item = $this->pool->getItem($key); - } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { - throw $e; - } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); - } - if (null === $this->cacheItemPrototype) { - $this->cacheItemPrototype = clone $item; - $this->cacheItemPrototype->set(null); - } - return $item->isHit() ? $item->get() : $default; - } - /** - * {@inheritdoc} - */ - public function set($key, $value, $ttl = null) - { - try { - if (null !== ($f = $this->createCacheItem)) { - $item = $f($key, $value); - } else { - $item = $this->pool->getItem($key)->set($value); - } - } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { - throw $e; - } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); - } - if (null !== $ttl) { - $item->expiresAfter($ttl); - } - return $this->pool->save($item); - } - /** - * {@inheritdoc} - */ - public function delete($key) - { - try { - return $this->pool->deleteItem($key); - } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { - throw $e; - } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); - } - } - /** - * {@inheritdoc} - */ - public function clear() - { - return $this->pool->clear(); - } - /** - * {@inheritdoc} - */ - public function getMultiple($keys, $default = null) - { - if ($keys instanceof \Traversable) { - $keys = \iterator_to_array($keys, \false); - } elseif (!\is_array($keys)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); - } - try { - $items = $this->pool->getItems($keys); - } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { - throw $e; - } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); - } - $values = []; - foreach ($items as $key => $item) { - $values[$key] = $item->isHit() ? $item->get() : $default; - } - return $values; - } - /** - * {@inheritdoc} - */ - public function setMultiple($values, $ttl = null) - { - $valuesIsArray = \is_array($values); - if (!$valuesIsArray && !$values instanceof \Traversable) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache values must be array or Traversable, "%s" given.', \is_object($values) ? \get_class($values) : \gettype($values))); - } - $items = []; - try { - if (null !== ($f = $this->createCacheItem)) { - $valuesIsArray = \false; - foreach ($values as $key => $value) { - $items[$key] = $f($key, $value, \true); - } - } elseif ($valuesIsArray) { - $items = []; - foreach ($values as $key => $value) { - $items[] = (string) $key; - } - $items = $this->pool->getItems($items); - } else { - foreach ($values as $key => $value) { - if (\is_int($key)) { - $key = (string) $key; - } - $items[$key] = $this->pool->getItem($key)->set($value); - } - } - } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { - throw $e; - } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); - } - $ok = \true; - foreach ($items as $key => $item) { - if ($valuesIsArray) { - $item->set($values[$key]); - } - if (null !== $ttl) { - $item->expiresAfter($ttl); - } - $ok = $this->pool->saveDeferred($item) && $ok; - } - return $this->pool->commit() && $ok; - } - /** - * {@inheritdoc} - */ - public function deleteMultiple($keys) - { - if ($keys instanceof \Traversable) { - $keys = \iterator_to_array($keys, \false); - } elseif (!\is_array($keys)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); - } - try { - return $this->pool->deleteItems($keys); - } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { - throw $e; - } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); - } - } - /** - * {@inheritdoc} - */ - public function has($key) - { - try { - return $this->pool->hasItem($key); - } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { - throw $e; - } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheException as Psr6CacheException; +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException as SimpleCacheException; +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\ProxyTrait; +/** + * @author Nicolas Grekas + */ +class Psr6Cache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + use ProxyTrait; + private $createCacheItem; + private $cacheItemPrototype; + public function __construct(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $pool) + { + $this->pool = $pool; + if (!$pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface) { + return; + } + $cacheItemPrototype =& $this->cacheItemPrototype; + $createCacheItem = \Closure::bind(static function ($key, $value, $allowInt = \false) use(&$cacheItemPrototype) { + $item = clone $cacheItemPrototype; + $item->key = $allowInt && \is_int($key) ? (string) $key : \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + $item->value = $value; + $item->isHit = \false; + return $item; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + $this->createCacheItem = function ($key, $value, $allowInt = \false) use($createCacheItem) { + if (null === $this->cacheItemPrototype) { + $this->get($allowInt && \is_int($key) ? (string) $key : $key); + } + $this->createCacheItem = $createCacheItem; + return $createCacheItem($key, $value, $allowInt); + }; + } + /** + * {@inheritdoc} + */ + public function get($key, $default = null) + { + try { + $item = $this->pool->getItem($key); + } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { + throw $e; + } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); + } + if (null === $this->cacheItemPrototype) { + $this->cacheItemPrototype = clone $item; + $this->cacheItemPrototype->set(null); + } + return $item->isHit() ? $item->get() : $default; + } + /** + * {@inheritdoc} + */ + public function set($key, $value, $ttl = null) + { + try { + if (null !== ($f = $this->createCacheItem)) { + $item = $f($key, $value); + } else { + $item = $this->pool->getItem($key)->set($value); + } + } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { + throw $e; + } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); + } + if (null !== $ttl) { + $item->expiresAfter($ttl); + } + return $this->pool->save($item); + } + /** + * {@inheritdoc} + */ + public function delete($key) + { + try { + return $this->pool->deleteItem($key); + } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { + throw $e; + } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); + } + } + /** + * {@inheritdoc} + */ + public function clear() + { + return $this->pool->clear(); + } + /** + * {@inheritdoc} + */ + public function getMultiple($keys, $default = null) + { + if ($keys instanceof \Traversable) { + $keys = \iterator_to_array($keys, \false); + } elseif (!\is_array($keys)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); + } + try { + $items = $this->pool->getItems($keys); + } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { + throw $e; + } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); + } + $values = []; + foreach ($items as $key => $item) { + $values[$key] = $item->isHit() ? $item->get() : $default; + } + return $values; + } + /** + * {@inheritdoc} + */ + public function setMultiple($values, $ttl = null) + { + $valuesIsArray = \is_array($values); + if (!$valuesIsArray && !$values instanceof \Traversable) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache values must be array or Traversable, "%s" given.', \is_object($values) ? \get_class($values) : \gettype($values))); + } + $items = []; + try { + if (null !== ($f = $this->createCacheItem)) { + $valuesIsArray = \false; + foreach ($values as $key => $value) { + $items[$key] = $f($key, $value, \true); + } + } elseif ($valuesIsArray) { + $items = []; + foreach ($values as $key => $value) { + $items[] = (string) $key; + } + $items = $this->pool->getItems($items); + } else { + foreach ($values as $key => $value) { + if (\is_int($key)) { + $key = (string) $key; + } + $items[$key] = $this->pool->getItem($key)->set($value); + } + } + } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { + throw $e; + } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); + } + $ok = \true; + foreach ($items as $key => $item) { + if ($valuesIsArray) { + $item->set($values[$key]); + } + if (null !== $ttl) { + $item->expiresAfter($ttl); + } + $ok = $this->pool->saveDeferred($item) && $ok; + } + return $this->pool->commit() && $ok; + } + /** + * {@inheritdoc} + */ + public function deleteMultiple($keys) + { + if ($keys instanceof \Traversable) { + $keys = \iterator_to_array($keys, \false); + } elseif (!\is_array($keys)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache keys must be array or Traversable, "%s" given.', \is_object($keys) ? \get_class($keys) : \gettype($keys))); + } + try { + return $this->pool->deleteItems($keys); + } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { + throw $e; + } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); + } + } + /** + * {@inheritdoc} + */ + public function has($key) + { + try { + return $this->pool->hasItem($key); + } catch (\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheException $e) { + throw $e; + } catch (\_PhpScoper5ea00cc67502b\Psr\Cache\CacheException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException($e->getMessage(), $e->getCode(), $e); + } + } +} diff --git a/vendor/symfony/cache/Simple/RedisCache.php b/vendor/symfony/cache/Simple/RedisCache.php index 7f8610069..cf950a255 100644 --- a/vendor/symfony/cache/Simple/RedisCache.php +++ b/vendor/symfony/cache/Simple/RedisCache.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisTrait; -class RedisCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache -{ - use RedisTrait; - /** - * @param \Redis|\RedisArray|\RedisCluster|\Predis\Client $redisClient - * @param string $namespace - * @param int $defaultLifetime - */ - public function __construct($redisClient, $namespace = '', $defaultLifetime = 0) - { - $this->init($redisClient, $namespace, $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisTrait; +class RedisCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\AbstractCache +{ + use RedisTrait; + /** + * @param \Redis|\RedisArray|\RedisCluster|\Predis\Client $redisClient + * @param string $namespace + * @param int $defaultLifetime + */ + public function __construct($redisClient, $namespace = '', $defaultLifetime = 0) + { + $this->init($redisClient, $namespace, $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Simple/TraceableCache.php b/vendor/symfony/cache/Simple/TraceableCache.php index f1e9a53ce..95d6162fa 100644 --- a/vendor/symfony/cache/Simple/TraceableCache.php +++ b/vendor/symfony/cache/Simple/TraceableCache.php @@ -1,220 +1,220 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; - -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -/** - * An adapter that collects data about all cache calls. - * - * @author Nicolas Grekas - */ -class TraceableCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface -{ - private $pool; - private $miss; - private $calls = []; - public function __construct(\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $pool) - { - $this->pool = $pool; - $this->miss = new \stdClass(); - } - /** - * {@inheritdoc} - */ - public function get($key, $default = null) - { - $miss = null !== $default && \is_object($default) ? $default : $this->miss; - $event = $this->start(__FUNCTION__); - try { - $value = $this->pool->get($key, $miss); - } finally { - $event->end = \microtime(\true); - } - if ($event->result[$key] = $miss !== $value) { - ++$event->hits; - } else { - ++$event->misses; - $value = $default; - } - return $value; - } - /** - * {@inheritdoc} - */ - public function has($key) - { - $event = $this->start(__FUNCTION__); - try { - return $event->result[$key] = $this->pool->has($key); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function delete($key) - { - $event = $this->start(__FUNCTION__); - try { - return $event->result[$key] = $this->pool->delete($key); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function set($key, $value, $ttl = null) - { - $event = $this->start(__FUNCTION__); - try { - return $event->result[$key] = $this->pool->set($key, $value, $ttl); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function setMultiple($values, $ttl = null) - { - $event = $this->start(__FUNCTION__); - $event->result['keys'] = []; - if ($values instanceof \Traversable) { - $values = function () use($values, $event) { - foreach ($values as $k => $v) { - $event->result['keys'][] = $k; - (yield $k => $v); - } - }; - $values = $values(); - } elseif (\is_array($values)) { - $event->result['keys'] = \array_keys($values); - } - try { - return $event->result['result'] = $this->pool->setMultiple($values, $ttl); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function getMultiple($keys, $default = null) - { - $miss = null !== $default && \is_object($default) ? $default : $this->miss; - $event = $this->start(__FUNCTION__); - try { - $result = $this->pool->getMultiple($keys, $miss); - } finally { - $event->end = \microtime(\true); - } - $f = function () use($result, $event, $miss, $default) { - $event->result = []; - foreach ($result as $key => $value) { - if ($event->result[$key] = $miss !== $value) { - ++$event->hits; - } else { - ++$event->misses; - $value = $default; - } - (yield $key => $value); - } - }; - return $f(); - } - /** - * {@inheritdoc} - */ - public function clear() - { - $event = $this->start(__FUNCTION__); - try { - return $event->result = $this->pool->clear(); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function deleteMultiple($keys) - { - $event = $this->start(__FUNCTION__); - if ($keys instanceof \Traversable) { - $keys = $event->result['keys'] = \iterator_to_array($keys, \false); - } else { - $event->result['keys'] = $keys; - } - try { - return $event->result['result'] = $this->pool->deleteMultiple($keys); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function prune() - { - if (!$this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { - return \false; - } - $event = $this->start(__FUNCTION__); - try { - return $event->result = $this->pool->prune(); - } finally { - $event->end = \microtime(\true); - } - } - /** - * {@inheritdoc} - */ - public function reset() - { - if (!$this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { - return; - } - $event = $this->start(__FUNCTION__); - try { - $this->pool->reset(); - } finally { - $event->end = \microtime(\true); - } - } - public function getCalls() - { - try { - return $this->calls; - } finally { - $this->calls = []; - } - } - private function start($name) - { - $this->calls[] = $event = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\TraceableCacheEvent(); - $event->name = $name; - $event->start = \microtime(\true); - return $event; - } -} -class TraceableCacheEvent -{ - public $name; - public $start; - public $end; - public $result; - public $hits = 0; - public $misses = 0; -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple; + +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +/** + * An adapter that collects data about all cache calls. + * + * @author Nicolas Grekas + */ +class TraceableCache implements \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface +{ + private $pool; + private $miss; + private $calls = []; + public function __construct(\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $pool) + { + $this->pool = $pool; + $this->miss = new \stdClass(); + } + /** + * {@inheritdoc} + */ + public function get($key, $default = null) + { + $miss = null !== $default && \is_object($default) ? $default : $this->miss; + $event = $this->start(__FUNCTION__); + try { + $value = $this->pool->get($key, $miss); + } finally { + $event->end = \microtime(\true); + } + if ($event->result[$key] = $miss !== $value) { + ++$event->hits; + } else { + ++$event->misses; + $value = $default; + } + return $value; + } + /** + * {@inheritdoc} + */ + public function has($key) + { + $event = $this->start(__FUNCTION__); + try { + return $event->result[$key] = $this->pool->has($key); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function delete($key) + { + $event = $this->start(__FUNCTION__); + try { + return $event->result[$key] = $this->pool->delete($key); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function set($key, $value, $ttl = null) + { + $event = $this->start(__FUNCTION__); + try { + return $event->result[$key] = $this->pool->set($key, $value, $ttl); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function setMultiple($values, $ttl = null) + { + $event = $this->start(__FUNCTION__); + $event->result['keys'] = []; + if ($values instanceof \Traversable) { + $values = function () use($values, $event) { + foreach ($values as $k => $v) { + $event->result['keys'][] = $k; + (yield $k => $v); + } + }; + $values = $values(); + } elseif (\is_array($values)) { + $event->result['keys'] = \array_keys($values); + } + try { + return $event->result['result'] = $this->pool->setMultiple($values, $ttl); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function getMultiple($keys, $default = null) + { + $miss = null !== $default && \is_object($default) ? $default : $this->miss; + $event = $this->start(__FUNCTION__); + try { + $result = $this->pool->getMultiple($keys, $miss); + } finally { + $event->end = \microtime(\true); + } + $f = function () use($result, $event, $miss, $default) { + $event->result = []; + foreach ($result as $key => $value) { + if ($event->result[$key] = $miss !== $value) { + ++$event->hits; + } else { + ++$event->misses; + $value = $default; + } + (yield $key => $value); + } + }; + return $f(); + } + /** + * {@inheritdoc} + */ + public function clear() + { + $event = $this->start(__FUNCTION__); + try { + return $event->result = $this->pool->clear(); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function deleteMultiple($keys) + { + $event = $this->start(__FUNCTION__); + if ($keys instanceof \Traversable) { + $keys = $event->result['keys'] = \iterator_to_array($keys, \false); + } else { + $event->result['keys'] = $keys; + } + try { + return $event->result['result'] = $this->pool->deleteMultiple($keys); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function prune() + { + if (!$this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { + return \false; + } + $event = $this->start(__FUNCTION__); + try { + return $event->result = $this->pool->prune(); + } finally { + $event->end = \microtime(\true); + } + } + /** + * {@inheritdoc} + */ + public function reset() + { + if (!$this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { + return; + } + $event = $this->start(__FUNCTION__); + try { + $this->pool->reset(); + } finally { + $event->end = \microtime(\true); + } + } + public function getCalls() + { + try { + return $this->calls; + } finally { + $this->calls = []; + } + } + private function start($name) + { + $this->calls[] = $event = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\TraceableCacheEvent(); + $event->name = $name; + $event->start = \microtime(\true); + return $event; + } +} +class TraceableCacheEvent +{ + public $name; + public $start; + public $end; + public $result; + public $hits = 0; + public $misses = 0; +} diff --git a/vendor/symfony/cache/Simple/index.php b/vendor/symfony/cache/Simple/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/Simple/index.php +++ b/vendor/symfony/cache/Simple/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Tests/Adapter/AbstractRedisAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/AbstractRedisAdapterTest.php index dadc0ee20..2f34e1b9d 100644 --- a/vendor/symfony/cache/Tests/Adapter/AbstractRedisAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/AbstractRedisAdapterTest.php @@ -1,36 +1,36 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter; -abstract class AbstractRedisAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testExpiration' => 'Testing expiration slows down the test suite', 'testHasItemReturnsFalseWhenDeferredItemIsExpired' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; - protected static $redis; - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter(self::$redis, \str_replace('\\', '.', __CLASS__), $defaultLifetime); - } - public static function setUpBeforeClass() - { - if (!\extension_loaded('redis')) { - self::markTestSkipped('Extension redis required.'); - } - if (!@(new \_PhpScoper5ea00cc67502b\Redis())->connect(\getenv('REDIS_HOST'))) { - $e = \error_get_last(); - self::markTestSkipped($e['message']); - } - } - public static function tearDownAfterClass() - { - self::$redis = null; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter; +abstract class AbstractRedisAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testExpiration' => 'Testing expiration slows down the test suite', 'testHasItemReturnsFalseWhenDeferredItemIsExpired' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; + protected static $redis; + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter(self::$redis, \str_replace('\\', '.', __CLASS__), $defaultLifetime); + } + public static function setUpBeforeClass() + { + if (!\extension_loaded('redis')) { + self::markTestSkipped('Extension redis required.'); + } + if (!@(new \_PhpScoper5ea00cc67502b\Redis())->connect(\getenv('REDIS_HOST'))) { + $e = \error_get_last(); + self::markTestSkipped($e['message']); + } + } + public static function tearDownAfterClass() + { + self::$redis = null; + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/AdapterTestCase.php b/vendor/symfony/cache/Tests/Adapter/AdapterTestCase.php index 17255e0c8..1f650a6d5 100644 --- a/vendor/symfony/cache/Tests/Adapter/AdapterTestCase.php +++ b/vendor/symfony/cache/Tests/Adapter/AdapterTestCase.php @@ -1,141 +1,141 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Cache\IntegrationTests\CachePoolTest; -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -abstract class AdapterTestCase extends \_PhpScoper5ea00cc67502b\Cache\IntegrationTests\CachePoolTest -{ - protected function setUp() - { - parent::setUp(); - if (!\array_key_exists('testDeferredSaveWithoutCommit', $this->skippedTests) && \defined('HHVM_VERSION')) { - $this->skippedTests['testDeferredSaveWithoutCommit'] = 'Destructors are called late on HHVM.'; - } - if (!\array_key_exists('testPrune', $this->skippedTests) && !$this->createCachePool() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { - $this->skippedTests['testPrune'] = 'Not a pruneable cache pool.'; - } - } - public function testDefaultLifeTime() - { - if (isset($this->skippedTests[__FUNCTION__])) { - $this->markTestSkipped($this->skippedTests[__FUNCTION__]); - } - $cache = $this->createCachePool(2); - $item = $cache->getItem('key.dlt'); - $item->set('value'); - $cache->save($item); - \sleep(1); - $item = $cache->getItem('key.dlt'); - $this->assertTrue($item->isHit()); - \sleep(2); - $item = $cache->getItem('key.dlt'); - $this->assertFalse($item->isHit()); - } - public function testExpiration() - { - if (isset($this->skippedTests[__FUNCTION__])) { - $this->markTestSkipped($this->skippedTests[__FUNCTION__]); - } - $cache = $this->createCachePool(); - $cache->save($cache->getItem('k1')->set('v1')->expiresAfter(2)); - $cache->save($cache->getItem('k2')->set('v2')->expiresAfter(366 * 86400)); - \sleep(3); - $item = $cache->getItem('k1'); - $this->assertFalse($item->isHit()); - $this->assertNull($item->get(), "Item's value must be null when isHit() is false."); - $item = $cache->getItem('k2'); - $this->assertTrue($item->isHit()); - $this->assertSame('v2', $item->get()); - } - public function testNotUnserializable() - { - if (isset($this->skippedTests[__FUNCTION__])) { - $this->markTestSkipped($this->skippedTests[__FUNCTION__]); - } - $cache = $this->createCachePool(); - $item = $cache->getItem('foo'); - $cache->save($item->set(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\NotUnserializable())); - $item = $cache->getItem('foo'); - $this->assertFalse($item->isHit()); - foreach ($cache->getItems(['foo']) as $item) { - } - $cache->save($item->set(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\NotUnserializable())); - foreach ($cache->getItems(['foo']) as $item) { - } - $this->assertFalse($item->isHit()); - } - public function testPrune() - { - if (isset($this->skippedTests[__FUNCTION__])) { - $this->markTestSkipped($this->skippedTests[__FUNCTION__]); - } - if (!\method_exists($this, 'isPruned')) { - $this->fail('Test classes for pruneable caches must implement `isPruned($cache, $name)` method.'); - } - /** @var PruneableInterface|CacheItemPoolInterface $cache */ - $cache = $this->createCachePool(); - $doSet = function ($name, $value, \DateInterval $expiresAfter = null) use($cache) { - $item = $cache->getItem($name); - $item->set($value); - if ($expiresAfter) { - $item->expiresAfter($expiresAfter); - } - $cache->save($item); - }; - $doSet('foo', 'foo-val', new \DateInterval('PT05S')); - $doSet('bar', 'bar-val', new \DateInterval('PT10S')); - $doSet('baz', 'baz-val', new \DateInterval('PT15S')); - $doSet('qux', 'qux-val', new \DateInterval('PT20S')); - \sleep(30); - $cache->prune(); - $this->assertTrue($this->isPruned($cache, 'foo')); - $this->assertTrue($this->isPruned($cache, 'bar')); - $this->assertTrue($this->isPruned($cache, 'baz')); - $this->assertTrue($this->isPruned($cache, 'qux')); - $doSet('foo', 'foo-val'); - $doSet('bar', 'bar-val', new \DateInterval('PT20S')); - $doSet('baz', 'baz-val', new \DateInterval('PT40S')); - $doSet('qux', 'qux-val', new \DateInterval('PT80S')); - $cache->prune(); - $this->assertFalse($this->isPruned($cache, 'foo')); - $this->assertFalse($this->isPruned($cache, 'bar')); - $this->assertFalse($this->isPruned($cache, 'baz')); - $this->assertFalse($this->isPruned($cache, 'qux')); - \sleep(30); - $cache->prune(); - $this->assertFalse($this->isPruned($cache, 'foo')); - $this->assertTrue($this->isPruned($cache, 'bar')); - $this->assertFalse($this->isPruned($cache, 'baz')); - $this->assertFalse($this->isPruned($cache, 'qux')); - \sleep(30); - $cache->prune(); - $this->assertFalse($this->isPruned($cache, 'foo')); - $this->assertTrue($this->isPruned($cache, 'baz')); - $this->assertFalse($this->isPruned($cache, 'qux')); - \sleep(30); - $cache->prune(); - $this->assertFalse($this->isPruned($cache, 'foo')); - $this->assertTrue($this->isPruned($cache, 'qux')); - } -} -class NotUnserializable implements \Serializable -{ - public function serialize() - { - return \serialize(123); - } - public function unserialize($ser) - { - throw new \Exception(__CLASS__); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Cache\IntegrationTests\CachePoolTest; +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +abstract class AdapterTestCase extends \_PhpScoper5ea00cc67502b\Cache\IntegrationTests\CachePoolTest +{ + protected function setUp() + { + parent::setUp(); + if (!\array_key_exists('testDeferredSaveWithoutCommit', $this->skippedTests) && \defined('HHVM_VERSION')) { + $this->skippedTests['testDeferredSaveWithoutCommit'] = 'Destructors are called late on HHVM.'; + } + if (!\array_key_exists('testPrune', $this->skippedTests) && !$this->createCachePool() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { + $this->skippedTests['testPrune'] = 'Not a pruneable cache pool.'; + } + } + public function testDefaultLifeTime() + { + if (isset($this->skippedTests[__FUNCTION__])) { + $this->markTestSkipped($this->skippedTests[__FUNCTION__]); + } + $cache = $this->createCachePool(2); + $item = $cache->getItem('key.dlt'); + $item->set('value'); + $cache->save($item); + \sleep(1); + $item = $cache->getItem('key.dlt'); + $this->assertTrue($item->isHit()); + \sleep(2); + $item = $cache->getItem('key.dlt'); + $this->assertFalse($item->isHit()); + } + public function testExpiration() + { + if (isset($this->skippedTests[__FUNCTION__])) { + $this->markTestSkipped($this->skippedTests[__FUNCTION__]); + } + $cache = $this->createCachePool(); + $cache->save($cache->getItem('k1')->set('v1')->expiresAfter(2)); + $cache->save($cache->getItem('k2')->set('v2')->expiresAfter(366 * 86400)); + \sleep(3); + $item = $cache->getItem('k1'); + $this->assertFalse($item->isHit()); + $this->assertNull($item->get(), "Item's value must be null when isHit() is false."); + $item = $cache->getItem('k2'); + $this->assertTrue($item->isHit()); + $this->assertSame('v2', $item->get()); + } + public function testNotUnserializable() + { + if (isset($this->skippedTests[__FUNCTION__])) { + $this->markTestSkipped($this->skippedTests[__FUNCTION__]); + } + $cache = $this->createCachePool(); + $item = $cache->getItem('foo'); + $cache->save($item->set(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\NotUnserializable())); + $item = $cache->getItem('foo'); + $this->assertFalse($item->isHit()); + foreach ($cache->getItems(['foo']) as $item) { + } + $cache->save($item->set(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\NotUnserializable())); + foreach ($cache->getItems(['foo']) as $item) { + } + $this->assertFalse($item->isHit()); + } + public function testPrune() + { + if (isset($this->skippedTests[__FUNCTION__])) { + $this->markTestSkipped($this->skippedTests[__FUNCTION__]); + } + if (!\method_exists($this, 'isPruned')) { + $this->fail('Test classes for pruneable caches must implement `isPruned($cache, $name)` method.'); + } + /** @var PruneableInterface|CacheItemPoolInterface $cache */ + $cache = $this->createCachePool(); + $doSet = function ($name, $value, \DateInterval $expiresAfter = null) use($cache) { + $item = $cache->getItem($name); + $item->set($value); + if ($expiresAfter) { + $item->expiresAfter($expiresAfter); + } + $cache->save($item); + }; + $doSet('foo', 'foo-val', new \DateInterval('PT05S')); + $doSet('bar', 'bar-val', new \DateInterval('PT10S')); + $doSet('baz', 'baz-val', new \DateInterval('PT15S')); + $doSet('qux', 'qux-val', new \DateInterval('PT20S')); + \sleep(30); + $cache->prune(); + $this->assertTrue($this->isPruned($cache, 'foo')); + $this->assertTrue($this->isPruned($cache, 'bar')); + $this->assertTrue($this->isPruned($cache, 'baz')); + $this->assertTrue($this->isPruned($cache, 'qux')); + $doSet('foo', 'foo-val'); + $doSet('bar', 'bar-val', new \DateInterval('PT20S')); + $doSet('baz', 'baz-val', new \DateInterval('PT40S')); + $doSet('qux', 'qux-val', new \DateInterval('PT80S')); + $cache->prune(); + $this->assertFalse($this->isPruned($cache, 'foo')); + $this->assertFalse($this->isPruned($cache, 'bar')); + $this->assertFalse($this->isPruned($cache, 'baz')); + $this->assertFalse($this->isPruned($cache, 'qux')); + \sleep(30); + $cache->prune(); + $this->assertFalse($this->isPruned($cache, 'foo')); + $this->assertTrue($this->isPruned($cache, 'bar')); + $this->assertFalse($this->isPruned($cache, 'baz')); + $this->assertFalse($this->isPruned($cache, 'qux')); + \sleep(30); + $cache->prune(); + $this->assertFalse($this->isPruned($cache, 'foo')); + $this->assertTrue($this->isPruned($cache, 'baz')); + $this->assertFalse($this->isPruned($cache, 'qux')); + \sleep(30); + $cache->prune(); + $this->assertFalse($this->isPruned($cache, 'foo')); + $this->assertTrue($this->isPruned($cache, 'qux')); + } +} +class NotUnserializable implements \Serializable +{ + public function serialize() + { + return \serialize(123); + } + public function unserialize($ser) + { + throw new \Exception(__CLASS__); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/ApcuAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/ApcuAdapterTest.php index 459211bfc..e67f0547c 100644 --- a/vendor/symfony/cache/Tests/Adapter/ApcuAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/ApcuAdapterTest.php @@ -1,97 +1,97 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Log\NullLogger; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter; -class ApcuAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testExpiration' => 'Testing expiration slows down the test suite', 'testHasItemReturnsFalseWhenDeferredItemIsExpired' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; - public function createCachePool($defaultLifetime = 0) - { - if (!\function_exists('_PhpScoper5ea00cc67502b\\apcu_fetch') || !\filter_var(\ini_get('apc.enabled'), \FILTER_VALIDATE_BOOLEAN)) { - $this->markTestSkipped('APCu extension is required.'); - } - if ('cli' === \PHP_SAPI && !\filter_var(\ini_get('apc.enable_cli'), \FILTER_VALIDATE_BOOLEAN)) { - if ('testWithCliSapi' !== $this->getName()) { - $this->markTestSkipped('apc.enable_cli=1 is required.'); - } - } - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('Fails transiently on Windows.'); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter(\str_replace('\\', '.', __CLASS__), $defaultLifetime); - } - public function testUnserializable() - { - $pool = $this->createCachePool(); - $item = $pool->getItem('foo'); - $item->set(function () { - }); - $this->assertFalse($pool->save($item)); - $item = $pool->getItem('foo'); - $this->assertFalse($item->isHit()); - } - public function testVersion() - { - $namespace = \str_replace('\\', '.', static::class); - $pool1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter($namespace, 0, 'p1'); - $item = $pool1->getItem('foo'); - $this->assertFalse($item->isHit()); - $this->assertTrue($pool1->save($item->set('bar'))); - $item = $pool1->getItem('foo'); - $this->assertTrue($item->isHit()); - $this->assertSame('bar', $item->get()); - $pool2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter($namespace, 0, 'p2'); - $item = $pool2->getItem('foo'); - $this->assertFalse($item->isHit()); - $this->assertNull($item->get()); - $item = $pool1->getItem('foo'); - $this->assertFalse($item->isHit()); - $this->assertNull($item->get()); - } - public function testNamespace() - { - $namespace = \str_replace('\\', '.', static::class); - $pool1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter($namespace . '_1', 0, 'p1'); - $item = $pool1->getItem('foo'); - $this->assertFalse($item->isHit()); - $this->assertTrue($pool1->save($item->set('bar'))); - $item = $pool1->getItem('foo'); - $this->assertTrue($item->isHit()); - $this->assertSame('bar', $item->get()); - $pool2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter($namespace . '_2', 0, 'p1'); - $item = $pool2->getItem('foo'); - $this->assertFalse($item->isHit()); - $this->assertNull($item->get()); - $item = $pool1->getItem('foo'); - $this->assertTrue($item->isHit()); - $this->assertSame('bar', $item->get()); - } - public function testWithCliSapi() - { - try { - // disable PHPUnit error handler to mimic a production environment - $isCalled = \false; - \set_error_handler(function () use(&$isCalled) { - $isCalled = \true; - }); - $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter(\str_replace('\\', '.', __CLASS__)); - $pool->setLogger(new \_PhpScoper5ea00cc67502b\Psr\Log\NullLogger()); - $item = $pool->getItem('foo'); - $item->isHit(); - $pool->save($item->set('bar')); - $this->assertFalse($isCalled); - } finally { - \restore_error_handler(); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Log\NullLogger; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter; +class ApcuAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testExpiration' => 'Testing expiration slows down the test suite', 'testHasItemReturnsFalseWhenDeferredItemIsExpired' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; + public function createCachePool($defaultLifetime = 0) + { + if (!\function_exists('_PhpScoper5ea00cc67502b\\apcu_fetch') || !\filter_var(\ini_get('apc.enabled'), \FILTER_VALIDATE_BOOLEAN)) { + $this->markTestSkipped('APCu extension is required.'); + } + if ('cli' === \PHP_SAPI && !\filter_var(\ini_get('apc.enable_cli'), \FILTER_VALIDATE_BOOLEAN)) { + if ('testWithCliSapi' !== $this->getName()) { + $this->markTestSkipped('apc.enable_cli=1 is required.'); + } + } + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('Fails transiently on Windows.'); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter(\str_replace('\\', '.', __CLASS__), $defaultLifetime); + } + public function testUnserializable() + { + $pool = $this->createCachePool(); + $item = $pool->getItem('foo'); + $item->set(function () { + }); + $this->assertFalse($pool->save($item)); + $item = $pool->getItem('foo'); + $this->assertFalse($item->isHit()); + } + public function testVersion() + { + $namespace = \str_replace('\\', '.', static::class); + $pool1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter($namespace, 0, 'p1'); + $item = $pool1->getItem('foo'); + $this->assertFalse($item->isHit()); + $this->assertTrue($pool1->save($item->set('bar'))); + $item = $pool1->getItem('foo'); + $this->assertTrue($item->isHit()); + $this->assertSame('bar', $item->get()); + $pool2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter($namespace, 0, 'p2'); + $item = $pool2->getItem('foo'); + $this->assertFalse($item->isHit()); + $this->assertNull($item->get()); + $item = $pool1->getItem('foo'); + $this->assertFalse($item->isHit()); + $this->assertNull($item->get()); + } + public function testNamespace() + { + $namespace = \str_replace('\\', '.', static::class); + $pool1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter($namespace . '_1', 0, 'p1'); + $item = $pool1->getItem('foo'); + $this->assertFalse($item->isHit()); + $this->assertTrue($pool1->save($item->set('bar'))); + $item = $pool1->getItem('foo'); + $this->assertTrue($item->isHit()); + $this->assertSame('bar', $item->get()); + $pool2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter($namespace . '_2', 0, 'p1'); + $item = $pool2->getItem('foo'); + $this->assertFalse($item->isHit()); + $this->assertNull($item->get()); + $item = $pool1->getItem('foo'); + $this->assertTrue($item->isHit()); + $this->assertSame('bar', $item->get()); + } + public function testWithCliSapi() + { + try { + // disable PHPUnit error handler to mimic a production environment + $isCalled = \false; + \set_error_handler(function () use(&$isCalled) { + $isCalled = \true; + }); + $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ApcuAdapter(\str_replace('\\', '.', __CLASS__)); + $pool->setLogger(new \_PhpScoper5ea00cc67502b\Psr\Log\NullLogger()); + $item = $pool->getItem('foo'); + $item->isHit(); + $pool->save($item->set('bar')); + $this->assertFalse($isCalled); + } finally { + \restore_error_handler(); + } + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/ArrayAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/ArrayAdapterTest.php index 7eb9c9bbb..3f9ec61e7 100644 --- a/vendor/symfony/cache/Tests/Adapter/ArrayAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/ArrayAdapterTest.php @@ -1,44 +1,44 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; -/** - * @group time-sensitive - */ -class ArrayAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testDeferredSaveWithoutCommit' => 'Assumes a shared cache which ArrayAdapter is not.', 'testSaveWithoutExpire' => 'Assumes a shared cache which ArrayAdapter is not.']; - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter($defaultLifetime); - } - public function testGetValuesHitAndMiss() - { - /** @var ArrayAdapter $cache */ - $cache = $this->createCachePool(); - // Hit - $item = $cache->getItem('foo'); - $item->set('4711'); - $cache->save($item); - $fooItem = $cache->getItem('foo'); - $this->assertTrue($fooItem->isHit()); - $this->assertEquals('4711', $fooItem->get()); - // Miss (should be present as NULL in $values) - $cache->getItem('bar'); - $values = $cache->getValues(); - $this->assertCount(2, $values); - $this->assertArrayHasKey('foo', $values); - $this->assertSame(\serialize('4711'), $values['foo']); - $this->assertArrayHasKey('bar', $values); - $this->assertNull($values['bar']); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; +/** + * @group time-sensitive + */ +class ArrayAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testDeferredSaveWithoutCommit' => 'Assumes a shared cache which ArrayAdapter is not.', 'testSaveWithoutExpire' => 'Assumes a shared cache which ArrayAdapter is not.']; + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter($defaultLifetime); + } + public function testGetValuesHitAndMiss() + { + /** @var ArrayAdapter $cache */ + $cache = $this->createCachePool(); + // Hit + $item = $cache->getItem('foo'); + $item->set('4711'); + $cache->save($item); + $fooItem = $cache->getItem('foo'); + $this->assertTrue($fooItem->isHit()); + $this->assertEquals('4711', $fooItem->get()); + // Miss (should be present as NULL in $values) + $cache->getItem('bar'); + $values = $cache->getValues(); + $this->assertCount(2, $values); + $this->assertArrayHasKey('foo', $values); + $this->assertSame(\serialize('4711'), $values['foo']); + $this->assertArrayHasKey('bar', $values); + $this->assertNull($values['bar']); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/ChainAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/ChainAdapterTest.php index 8ece80d1a..513415db5 100644 --- a/vendor/symfony/cache/Tests/Adapter/ChainAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/ChainAdapterTest.php @@ -1,80 +1,80 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ExternalAdapter; -/** - * @author Kévin Dunglas - * @group time-sensitive - */ -class ChainAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter($defaultLifetime), new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ExternalAdapter(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', $defaultLifetime)], $defaultLifetime); - } - public function testEmptyAdaptersException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('At least one adapter must be specified.'); - new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([]); - } - public function testInvalidAdapterException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The class "stdClass" does not implement'); - new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([new \stdClass()]); - } - public function testPrune() - { - if (isset($this->skippedTests[__FUNCTION__])) { - $this->markTestSkipped($this->skippedTests[__FUNCTION__]); - } - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([$this->getPruneableMock(), $this->getNonPruneableMock(), $this->getPruneableMock()]); - $this->assertTrue($cache->prune()); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([$this->getPruneableMock(), $this->getFailingPruneableMock(), $this->getPruneableMock()]); - $this->assertFalse($cache->prune()); - } - /** - * @return MockObject|PruneableCacheInterface - */ - private function getPruneableMock() - { - $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\PruneableCacheInterface::class)->getMock(); - $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\true); - return $pruneable; - } - /** - * @return MockObject|PruneableCacheInterface - */ - private function getFailingPruneableMock() - { - $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\PruneableCacheInterface::class)->getMock(); - $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\false); - return $pruneable; - } - /** - * @return MockObject|AdapterInterface - */ - private function getNonPruneableMock() - { - return $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface::class)->getMock(); - } -} -interface PruneableCacheInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ExternalAdapter; +/** + * @author Kévin Dunglas + * @group time-sensitive + */ +class ChainAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter($defaultLifetime), new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ExternalAdapter(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', $defaultLifetime)], $defaultLifetime); + } + public function testEmptyAdaptersException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('At least one adapter must be specified.'); + new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([]); + } + public function testInvalidAdapterException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The class "stdClass" does not implement'); + new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([new \stdClass()]); + } + public function testPrune() + { + if (isset($this->skippedTests[__FUNCTION__])) { + $this->markTestSkipped($this->skippedTests[__FUNCTION__]); + } + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([$this->getPruneableMock(), $this->getNonPruneableMock(), $this->getPruneableMock()]); + $this->assertTrue($cache->prune()); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ChainAdapter([$this->getPruneableMock(), $this->getFailingPruneableMock(), $this->getPruneableMock()]); + $this->assertFalse($cache->prune()); + } + /** + * @return MockObject|PruneableCacheInterface + */ + private function getPruneableMock() + { + $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\PruneableCacheInterface::class)->getMock(); + $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\true); + return $pruneable; + } + /** + * @return MockObject|PruneableCacheInterface + */ + private function getFailingPruneableMock() + { + $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\PruneableCacheInterface::class)->getMock(); + $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\false); + return $pruneable; + } + /** + * @return MockObject|AdapterInterface + */ + private function getNonPruneableMock() + { + return $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface::class)->getMock(); + } +} +interface PruneableCacheInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface +{ +} diff --git a/vendor/symfony/cache/Tests/Adapter/DoctrineAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/DoctrineAdapterTest.php index 1f1a4f044..444989e43 100644 --- a/vendor/symfony/cache/Tests/Adapter/DoctrineAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/DoctrineAdapterTest.php @@ -1,25 +1,25 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\DoctrineAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ArrayCache; -/** - * @group time-sensitive - */ -class DoctrineAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testDeferredSaveWithoutCommit' => 'Assumes a shared cache which ArrayCache is not.', 'testSaveWithoutExpire' => 'Assumes a shared cache which ArrayCache is not.', 'testNotUnserializable' => 'ArrayCache does not use serialize/unserialize']; - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\DoctrineAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ArrayCache($defaultLifetime), '', $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\DoctrineAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ArrayCache; +/** + * @group time-sensitive + */ +class DoctrineAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testDeferredSaveWithoutCommit' => 'Assumes a shared cache which ArrayCache is not.', 'testSaveWithoutExpire' => 'Assumes a shared cache which ArrayCache is not.', 'testNotUnserializable' => 'ArrayCache does not use serialize/unserialize']; + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\DoctrineAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ArrayCache($defaultLifetime), '', $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/FilesystemAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/FilesystemAdapterTest.php index b2459daf1..81dc47885 100644 --- a/vendor/symfony/cache/Tests/Adapter/FilesystemAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/FilesystemAdapterTest.php @@ -1,52 +1,52 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; -/** - * @group time-sensitive - */ -class FilesystemAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', $defaultLifetime); - } - public static function tearDownAfterClass() - { - self::rmdir(\sys_get_temp_dir() . '/symfony-cache'); - } - public static function rmdir($dir) - { - if (!\file_exists($dir)) { - return; - } - if (!$dir || 0 !== \strpos(\dirname($dir), \sys_get_temp_dir())) { - throw new \Exception(__METHOD__ . "() operates only on subdirs of system's temp dir"); - } - $children = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($dir, \RecursiveDirectoryIterator::SKIP_DOTS), \RecursiveIteratorIterator::CHILD_FIRST); - foreach ($children as $child) { - if ($child->isDir()) { - \rmdir($child); - } else { - \unlink($child); - } - } - \rmdir($dir); - } - protected function isPruned(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $cache, $name) - { - $getFileMethod = (new \ReflectionObject($cache))->getMethod('getFile'); - $getFileMethod->setAccessible(\true); - return !\file_exists($getFileMethod->invoke($cache, $name)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; +/** + * @group time-sensitive + */ +class FilesystemAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', $defaultLifetime); + } + public static function tearDownAfterClass() + { + self::rmdir(\sys_get_temp_dir() . '/symfony-cache'); + } + public static function rmdir($dir) + { + if (!\file_exists($dir)) { + return; + } + if (!$dir || 0 !== \strpos(\dirname($dir), \sys_get_temp_dir())) { + throw new \Exception(__METHOD__ . "() operates only on subdirs of system's temp dir"); + } + $children = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($dir, \RecursiveDirectoryIterator::SKIP_DOTS), \RecursiveIteratorIterator::CHILD_FIRST); + foreach ($children as $child) { + if ($child->isDir()) { + \rmdir($child); + } else { + \unlink($child); + } + } + \rmdir($dir); + } + protected function isPruned(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $cache, $name) + { + $getFileMethod = (new \ReflectionObject($cache))->getMethod('getFile'); + $getFileMethod->setAccessible(\true); + return !\file_exists($getFileMethod->invoke($cache, $name)); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/MaxIdLengthAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/MaxIdLengthAdapterTest.php index 82e2a4b18..81b02fe50 100644 --- a/vendor/symfony/cache/Tests/Adapter/MaxIdLengthAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/MaxIdLengthAdapterTest.php @@ -1,59 +1,59 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter; -class MaxIdLengthAdapterTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testLongKey() - { - $cache = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\MaxIdLengthAdapter::class)->setConstructorArgs([\str_repeat('-', 10)])->setMethods(['doHave', 'doFetch', 'doDelete', 'doSave', 'doClear'])->getMock(); - $cache->expects($this->exactly(2))->method('doHave')->withConsecutive([$this->equalTo('----------:0GTYWa9n4ed8vqNlOT2iEr:')], [$this->equalTo('----------:---------------------------------------')]); - $cache->hasItem(\str_repeat('-', 40)); - $cache->hasItem(\str_repeat('-', 39)); - } - public function testLongKeyVersioning() - { - $cache = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\MaxIdLengthAdapter::class)->setConstructorArgs([\str_repeat('-', 26)])->getMock(); - $cache->method('doFetch')->willReturn(['2:']); - $reflectionClass = new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::class); - $reflectionMethod = $reflectionClass->getMethod('getId'); - $reflectionMethod->setAccessible(\true); - // No versioning enabled - $this->assertEquals('--------------------------:------------', $reflectionMethod->invokeArgs($cache, [\str_repeat('-', 12)])); - $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 12)]))); - $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 23)]))); - $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 40)]))); - $reflectionProperty = $reflectionClass->getProperty('versioningIsEnabled'); - $reflectionProperty->setAccessible(\true); - $reflectionProperty->setValue($cache, \true); - // Versioning enabled - $this->assertEquals('--------------------------:2:------------', $reflectionMethod->invokeArgs($cache, [\str_repeat('-', 12)])); - $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 12)]))); - $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 23)]))); - $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 40)]))); - } - public function testTooLongNamespace() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Namespace must be 26 chars max, 40 given ("----------------------------------------")'); - $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\MaxIdLengthAdapter::class)->setConstructorArgs([\str_repeat('-', 40)])->getMock(); - } -} -abstract class MaxIdLengthAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter -{ - protected $maxIdLength = 50; - public function __construct($ns) - { - parent::__construct($ns); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter; +class MaxIdLengthAdapterTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testLongKey() + { + $cache = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\MaxIdLengthAdapter::class)->setConstructorArgs([\str_repeat('-', 10)])->setMethods(['doHave', 'doFetch', 'doDelete', 'doSave', 'doClear'])->getMock(); + $cache->expects($this->exactly(2))->method('doHave')->withConsecutive([$this->equalTo('----------:0GTYWa9n4ed8vqNlOT2iEr:')], [$this->equalTo('----------:---------------------------------------')]); + $cache->hasItem(\str_repeat('-', 40)); + $cache->hasItem(\str_repeat('-', 39)); + } + public function testLongKeyVersioning() + { + $cache = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\MaxIdLengthAdapter::class)->setConstructorArgs([\str_repeat('-', 26)])->getMock(); + $cache->method('doFetch')->willReturn(['2:']); + $reflectionClass = new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::class); + $reflectionMethod = $reflectionClass->getMethod('getId'); + $reflectionMethod->setAccessible(\true); + // No versioning enabled + $this->assertEquals('--------------------------:------------', $reflectionMethod->invokeArgs($cache, [\str_repeat('-', 12)])); + $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 12)]))); + $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 23)]))); + $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 40)]))); + $reflectionProperty = $reflectionClass->getProperty('versioningIsEnabled'); + $reflectionProperty->setAccessible(\true); + $reflectionProperty->setValue($cache, \true); + // Versioning enabled + $this->assertEquals('--------------------------:2:------------', $reflectionMethod->invokeArgs($cache, [\str_repeat('-', 12)])); + $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 12)]))); + $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 23)]))); + $this->assertLessThanOrEqual(50, \strlen($reflectionMethod->invokeArgs($cache, [\str_repeat('-', 40)]))); + } + public function testTooLongNamespace() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Namespace must be 26 chars max, 40 given ("----------------------------------------")'); + $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\MaxIdLengthAdapter::class)->setConstructorArgs([\str_repeat('-', 40)])->getMock(); + } +} +abstract class MaxIdLengthAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter +{ + protected $maxIdLength = 50; + public function __construct($ns) + { + parent::__construct($ns); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/MemcachedAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/MemcachedAdapterTest.php index 51766a477..f7d6485cd 100644 --- a/vendor/symfony/cache/Tests/Adapter/MemcachedAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/MemcachedAdapterTest.php @@ -1,127 +1,127 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter; -class MemcachedAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testHasItemReturnsFalseWhenDeferredItemIsExpired' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; - protected static $client; - public static function setUpBeforeClass() - { - if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::isSupported()) { - self::markTestSkipped('Extension memcached >=2.2.0 required.'); - } - self::$client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('memcached://' . \getenv('MEMCACHED_HOST'), ['binary_protocol' => \false]); - self::$client->get('foo'); - $code = self::$client->getResultCode(); - if (\_PhpScoper5ea00cc67502b\Memcached::RES_SUCCESS !== $code && \_PhpScoper5ea00cc67502b\Memcached::RES_NOTFOUND !== $code) { - self::markTestSkipped('Memcached error: ' . \strtolower(self::$client->getResultMessage())); - } - } - public function createCachePool($defaultLifetime = 0) - { - $client = $defaultLifetime ? \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('memcached://' . \getenv('MEMCACHED_HOST')) : self::$client; - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter($client, \str_replace('\\', '.', __CLASS__), $defaultLifetime); - } - public function testOptions() - { - $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([], ['libketama_compatible' => \false, 'distribution' => 'modula', 'compression' => \true, 'serializer' => 'php', 'hash' => 'md5']); - $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_PHP, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_SERIALIZER)); - $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::HASH_MD5, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_HASH)); - $this->assertTrue($client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_COMPRESSION)); - $this->assertSame(0, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE)); - $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::DISTRIBUTION_MODULA, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_DISTRIBUTION)); - } - /** - * @dataProvider provideBadOptions - */ - public function testBadOptions($name, $value) - { - $this->expectException('ErrorException'); - $this->expectExceptionMessage('constant(): Couldn\'t find constant Memcached::'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([], [$name => $value]); - } - public function provideBadOptions() - { - return [['foo', 'bar'], ['hash', 'zyx'], ['serializer', 'zyx'], ['distribution', 'zyx']]; - } - public function testDefaultOptions() - { - $this->assertTrue(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::isSupported()); - $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([]); - $this->assertTrue($client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_COMPRESSION)); - $this->assertSame(1, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_BINARY_PROTOCOL)); - $this->assertSame(1, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_TCP_NODELAY)); - $this->assertSame(1, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE)); - } - public function testOptionSerializer() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\CacheException'); - $this->expectExceptionMessage('MemcachedAdapter: "serializer" option must be "php" or "igbinary".'); - if (!\_PhpScoper5ea00cc67502b\Memcached::HAVE_JSON) { - $this->markTestSkipped('Memcached::HAVE_JSON required'); - } - new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([], ['serializer' => 'json'])); - } - /** - * @dataProvider provideServersSetting - */ - public function testServersSetting($dsn, $host, $port) - { - $client1 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection($dsn); - $client2 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([$dsn]); - $client3 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([[$host, $port]]); - $expect = ['host' => $host, 'port' => $port]; - $f = function ($s) { - return ['host' => $s['host'], 'port' => $s['port']]; - }; - $this->assertSame([$expect], \array_map($f, $client1->getServerList())); - $this->assertSame([$expect], \array_map($f, $client2->getServerList())); - $this->assertSame([$expect], \array_map($f, $client3->getServerList())); - } - public function provideServersSetting() - { - (yield ['memcached://127.0.0.1/50', '127.0.0.1', 11211]); - (yield ['memcached://localhost:11222?weight=25', 'localhost', 11222]); - if (\filter_var(\ini_get('memcached.use_sasl'), \FILTER_VALIDATE_BOOLEAN)) { - (yield ['memcached://user:password@127.0.0.1?weight=50', '127.0.0.1', 11211]); - } - (yield ['memcached:///var/run/memcached.sock?weight=25', '/var/run/memcached.sock', 0]); - (yield ['memcached:///var/local/run/memcached.socket?weight=25', '/var/local/run/memcached.socket', 0]); - if (\filter_var(\ini_get('memcached.use_sasl'), \FILTER_VALIDATE_BOOLEAN)) { - (yield ['memcached://user:password@/var/local/run/memcached.socket?weight=25', '/var/local/run/memcached.socket', 0]); - } - } - /** - * @dataProvider provideDsnWithOptions - */ - public function testDsnWithOptions($dsn, array $options, array $expectedOptions) - { - $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection($dsn, $options); - foreach ($expectedOptions as $option => $expect) { - $this->assertSame($expect, $client->getOption($option)); - } - } - public function provideDsnWithOptions() - { - if (!\class_exists('_PhpScoper5ea00cc67502b\\Memcached')) { - self::markTestSkipped('Extension memcached required.'); - } - (yield ['memcached://localhost:11222?retry_timeout=10', [\_PhpScoper5ea00cc67502b\Memcached::OPT_RETRY_TIMEOUT => 8], [\_PhpScoper5ea00cc67502b\Memcached::OPT_RETRY_TIMEOUT => 10]]); - (yield ['memcached://localhost:11222?socket_recv_size=1&socket_send_size=2', [\_PhpScoper5ea00cc67502b\Memcached::OPT_RETRY_TIMEOUT => 8], [\_PhpScoper5ea00cc67502b\Memcached::OPT_SOCKET_RECV_SIZE => 1, \_PhpScoper5ea00cc67502b\Memcached::OPT_SOCKET_SEND_SIZE => 2, \_PhpScoper5ea00cc67502b\Memcached::OPT_RETRY_TIMEOUT => 8]]); - } - public function testClear() - { - $this->assertTrue($this->createCachePool()->clear()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter; +class MemcachedAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testHasItemReturnsFalseWhenDeferredItemIsExpired' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; + protected static $client; + public static function setUpBeforeClass() + { + if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::isSupported()) { + self::markTestSkipped('Extension memcached >=2.2.0 required.'); + } + self::$client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('memcached://' . \getenv('MEMCACHED_HOST'), ['binary_protocol' => \false]); + self::$client->get('foo'); + $code = self::$client->getResultCode(); + if (\_PhpScoper5ea00cc67502b\Memcached::RES_SUCCESS !== $code && \_PhpScoper5ea00cc67502b\Memcached::RES_NOTFOUND !== $code) { + self::markTestSkipped('Memcached error: ' . \strtolower(self::$client->getResultMessage())); + } + } + public function createCachePool($defaultLifetime = 0) + { + $client = $defaultLifetime ? \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('memcached://' . \getenv('MEMCACHED_HOST')) : self::$client; + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter($client, \str_replace('\\', '.', __CLASS__), $defaultLifetime); + } + public function testOptions() + { + $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([], ['libketama_compatible' => \false, 'distribution' => 'modula', 'compression' => \true, 'serializer' => 'php', 'hash' => 'md5']); + $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_PHP, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_SERIALIZER)); + $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::HASH_MD5, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_HASH)); + $this->assertTrue($client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_COMPRESSION)); + $this->assertSame(0, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE)); + $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::DISTRIBUTION_MODULA, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_DISTRIBUTION)); + } + /** + * @dataProvider provideBadOptions + */ + public function testBadOptions($name, $value) + { + $this->expectException('ErrorException'); + $this->expectExceptionMessage('constant(): Couldn\'t find constant Memcached::'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([], [$name => $value]); + } + public function provideBadOptions() + { + return [['foo', 'bar'], ['hash', 'zyx'], ['serializer', 'zyx'], ['distribution', 'zyx']]; + } + public function testDefaultOptions() + { + $this->assertTrue(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::isSupported()); + $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([]); + $this->assertTrue($client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_COMPRESSION)); + $this->assertSame(1, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_BINARY_PROTOCOL)); + $this->assertSame(1, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_TCP_NODELAY)); + $this->assertSame(1, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE)); + } + public function testOptionSerializer() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\CacheException'); + $this->expectExceptionMessage('MemcachedAdapter: "serializer" option must be "php" or "igbinary".'); + if (!\_PhpScoper5ea00cc67502b\Memcached::HAVE_JSON) { + $this->markTestSkipped('Memcached::HAVE_JSON required'); + } + new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([], ['serializer' => 'json'])); + } + /** + * @dataProvider provideServersSetting + */ + public function testServersSetting($dsn, $host, $port) + { + $client1 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection($dsn); + $client2 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([$dsn]); + $client3 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection([[$host, $port]]); + $expect = ['host' => $host, 'port' => $port]; + $f = function ($s) { + return ['host' => $s['host'], 'port' => $s['port']]; + }; + $this->assertSame([$expect], \array_map($f, $client1->getServerList())); + $this->assertSame([$expect], \array_map($f, $client2->getServerList())); + $this->assertSame([$expect], \array_map($f, $client3->getServerList())); + } + public function provideServersSetting() + { + (yield ['memcached://127.0.0.1/50', '127.0.0.1', 11211]); + (yield ['memcached://localhost:11222?weight=25', 'localhost', 11222]); + if (\filter_var(\ini_get('memcached.use_sasl'), \FILTER_VALIDATE_BOOLEAN)) { + (yield ['memcached://user:password@127.0.0.1?weight=50', '127.0.0.1', 11211]); + } + (yield ['memcached:///var/run/memcached.sock?weight=25', '/var/run/memcached.sock', 0]); + (yield ['memcached:///var/local/run/memcached.socket?weight=25', '/var/local/run/memcached.socket', 0]); + if (\filter_var(\ini_get('memcached.use_sasl'), \FILTER_VALIDATE_BOOLEAN)) { + (yield ['memcached://user:password@/var/local/run/memcached.socket?weight=25', '/var/local/run/memcached.socket', 0]); + } + } + /** + * @dataProvider provideDsnWithOptions + */ + public function testDsnWithOptions($dsn, array $options, array $expectedOptions) + { + $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\MemcachedAdapter::createConnection($dsn, $options); + foreach ($expectedOptions as $option => $expect) { + $this->assertSame($expect, $client->getOption($option)); + } + } + public function provideDsnWithOptions() + { + if (!\class_exists('_PhpScoper5ea00cc67502b\\Memcached')) { + self::markTestSkipped('Extension memcached required.'); + } + (yield ['memcached://localhost:11222?retry_timeout=10', [\_PhpScoper5ea00cc67502b\Memcached::OPT_RETRY_TIMEOUT => 8], [\_PhpScoper5ea00cc67502b\Memcached::OPT_RETRY_TIMEOUT => 10]]); + (yield ['memcached://localhost:11222?socket_recv_size=1&socket_send_size=2', [\_PhpScoper5ea00cc67502b\Memcached::OPT_RETRY_TIMEOUT => 8], [\_PhpScoper5ea00cc67502b\Memcached::OPT_SOCKET_RECV_SIZE => 1, \_PhpScoper5ea00cc67502b\Memcached::OPT_SOCKET_SEND_SIZE => 2, \_PhpScoper5ea00cc67502b\Memcached::OPT_RETRY_TIMEOUT => 8]]); + } + public function testClear() + { + $this->assertTrue($this->createCachePool()->clear()); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/NamespacedProxyAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/NamespacedProxyAdapterTest.php index 05cf919a6..8ac3a335e 100644 --- a/vendor/symfony/cache/Tests/Adapter/NamespacedProxyAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/NamespacedProxyAdapterTest.php @@ -1,24 +1,24 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter; -/** - * @group time-sensitive - */ -class NamespacedProxyAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\ProxyAdapterTest -{ - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter($defaultLifetime), 'foo', $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter; +/** + * @group time-sensitive + */ +class NamespacedProxyAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\ProxyAdapterTest +{ + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter($defaultLifetime), 'foo', $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/NullAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/NullAdapterTest.php index 4807a99db..9de34bf2e 100644 --- a/vendor/symfony/cache/Tests/Adapter/NullAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/NullAdapterTest.php @@ -1,101 +1,101 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\NullAdapter; -/** - * @group time-sensitive - */ -class NullAdapterTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function createCachePool() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\NullAdapter(); - } - public function testGetItem() - { - $adapter = $this->createCachePool(); - $item = $adapter->getItem('key'); - $this->assertFalse($item->isHit()); - $this->assertNull($item->get(), "Item's value must be null when isHit is false."); - } - public function testHasItem() - { - $this->assertFalse($this->createCachePool()->hasItem('key')); - } - public function testGetItems() - { - $adapter = $this->createCachePool(); - $keys = ['foo', 'bar', 'baz', 'biz']; - /** @var CacheItemInterface[] $items */ - $items = $adapter->getItems($keys); - $count = 0; - foreach ($items as $key => $item) { - $itemKey = $item->getKey(); - $this->assertEquals($itemKey, $key, 'Keys must be preserved when fetching multiple items'); - $this->assertContains($key, $keys, 'Cache key can not change.'); - $this->assertFalse($item->isHit()); - // Remove $key for $keys - foreach ($keys as $k => $v) { - if ($v === $key) { - unset($keys[$k]); - } - } - ++$count; - } - $this->assertSame(4, $count); - } - public function testIsHit() - { - $adapter = $this->createCachePool(); - $item = $adapter->getItem('key'); - $this->assertFalse($item->isHit()); - } - public function testClear() - { - $this->assertTrue($this->createCachePool()->clear()); - } - public function testDeleteItem() - { - $this->assertTrue($this->createCachePool()->deleteItem('key')); - } - public function testDeleteItems() - { - $this->assertTrue($this->createCachePool()->deleteItems(['key', 'foo', 'bar'])); - } - public function testSave() - { - $adapter = $this->createCachePool(); - $item = $adapter->getItem('key'); - $this->assertFalse($item->isHit()); - $this->assertNull($item->get(), "Item's value must be null when isHit is false."); - $this->assertFalse($adapter->save($item)); - } - public function testDeferredSave() - { - $adapter = $this->createCachePool(); - $item = $adapter->getItem('key'); - $this->assertFalse($item->isHit()); - $this->assertNull($item->get(), "Item's value must be null when isHit is false."); - $this->assertFalse($adapter->saveDeferred($item)); - } - public function testCommit() - { - $adapter = $this->createCachePool(); - $item = $adapter->getItem('key'); - $this->assertFalse($item->isHit()); - $this->assertNull($item->get(), "Item's value must be null when isHit is false."); - $this->assertFalse($adapter->saveDeferred($item)); - $this->assertFalse($this->createCachePool()->commit()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\NullAdapter; +/** + * @group time-sensitive + */ +class NullAdapterTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function createCachePool() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\NullAdapter(); + } + public function testGetItem() + { + $adapter = $this->createCachePool(); + $item = $adapter->getItem('key'); + $this->assertFalse($item->isHit()); + $this->assertNull($item->get(), "Item's value must be null when isHit is false."); + } + public function testHasItem() + { + $this->assertFalse($this->createCachePool()->hasItem('key')); + } + public function testGetItems() + { + $adapter = $this->createCachePool(); + $keys = ['foo', 'bar', 'baz', 'biz']; + /** @var CacheItemInterface[] $items */ + $items = $adapter->getItems($keys); + $count = 0; + foreach ($items as $key => $item) { + $itemKey = $item->getKey(); + $this->assertEquals($itemKey, $key, 'Keys must be preserved when fetching multiple items'); + $this->assertContains($key, $keys, 'Cache key can not change.'); + $this->assertFalse($item->isHit()); + // Remove $key for $keys + foreach ($keys as $k => $v) { + if ($v === $key) { + unset($keys[$k]); + } + } + ++$count; + } + $this->assertSame(4, $count); + } + public function testIsHit() + { + $adapter = $this->createCachePool(); + $item = $adapter->getItem('key'); + $this->assertFalse($item->isHit()); + } + public function testClear() + { + $this->assertTrue($this->createCachePool()->clear()); + } + public function testDeleteItem() + { + $this->assertTrue($this->createCachePool()->deleteItem('key')); + } + public function testDeleteItems() + { + $this->assertTrue($this->createCachePool()->deleteItems(['key', 'foo', 'bar'])); + } + public function testSave() + { + $adapter = $this->createCachePool(); + $item = $adapter->getItem('key'); + $this->assertFalse($item->isHit()); + $this->assertNull($item->get(), "Item's value must be null when isHit is false."); + $this->assertFalse($adapter->save($item)); + } + public function testDeferredSave() + { + $adapter = $this->createCachePool(); + $item = $adapter->getItem('key'); + $this->assertFalse($item->isHit()); + $this->assertNull($item->get(), "Item's value must be null when isHit is false."); + $this->assertFalse($adapter->saveDeferred($item)); + } + public function testCommit() + { + $adapter = $this->createCachePool(); + $item = $adapter->getItem('key'); + $this->assertFalse($item->isHit()); + $this->assertNull($item->get(), "Item's value must be null when isHit is false."); + $this->assertFalse($adapter->saveDeferred($item)); + $this->assertFalse($this->createCachePool()->commit()); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/PdoAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/PdoAdapterTest.php index ec7c9cc94..b4d809052 100644 --- a/vendor/symfony/cache/Tests/Adapter/PdoAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/PdoAdapterTest.php @@ -1,57 +1,57 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Traits\PdoPruneableTrait; -/** - * @group time-sensitive - */ -class PdoAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - use PdoPruneableTrait; - protected static $dbFile; - public static function setUpBeforeClass() - { - if (!\extension_loaded('pdo_sqlite')) { - self::markTestSkipped('Extension pdo_sqlite required.'); - } - self::$dbFile = \tempnam(\sys_get_temp_dir(), 'sf_sqlite_cache'); - $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter('sqlite:' . self::$dbFile); - $pool->createTable(); - } - public static function tearDownAfterClass() - { - @\unlink(self::$dbFile); - } - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter('sqlite:' . self::$dbFile, 'ns', $defaultLifetime); - } - public function testCleanupExpiredItems() - { - $pdo = new \PDO('sqlite:' . self::$dbFile); - $getCacheItemCount = function () use($pdo) { - return (int) $pdo->query('SELECT COUNT(*) FROM cache_items')->fetch(\PDO::FETCH_COLUMN); - }; - $this->assertSame(0, $getCacheItemCount()); - $cache = $this->createCachePool(); - $item = $cache->getItem('some_nice_key'); - $item->expiresAfter(1); - $item->set(1); - $cache->save($item); - $this->assertSame(1, $getCacheItemCount()); - \sleep(2); - $newItem = $cache->getItem($item->getKey()); - $this->assertFalse($newItem->isHit()); - $this->assertSame(0, $getCacheItemCount(), 'PDOAdapter must clean up expired items'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Traits\PdoPruneableTrait; +/** + * @group time-sensitive + */ +class PdoAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + use PdoPruneableTrait; + protected static $dbFile; + public static function setUpBeforeClass() + { + if (!\extension_loaded('pdo_sqlite')) { + self::markTestSkipped('Extension pdo_sqlite required.'); + } + self::$dbFile = \tempnam(\sys_get_temp_dir(), 'sf_sqlite_cache'); + $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter('sqlite:' . self::$dbFile); + $pool->createTable(); + } + public static function tearDownAfterClass() + { + @\unlink(self::$dbFile); + } + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter('sqlite:' . self::$dbFile, 'ns', $defaultLifetime); + } + public function testCleanupExpiredItems() + { + $pdo = new \PDO('sqlite:' . self::$dbFile); + $getCacheItemCount = function () use($pdo) { + return (int) $pdo->query('SELECT COUNT(*) FROM cache_items')->fetch(\PDO::FETCH_COLUMN); + }; + $this->assertSame(0, $getCacheItemCount()); + $cache = $this->createCachePool(); + $item = $cache->getItem('some_nice_key'); + $item->expiresAfter(1); + $item->set(1); + $cache->save($item); + $this->assertSame(1, $getCacheItemCount()); + \sleep(2); + $newItem = $cache->getItem($item->getKey()); + $this->assertFalse($newItem->isHit()); + $this->assertSame(0, $getCacheItemCount(), 'PDOAdapter must clean up expired items'); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/PdoDbalAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/PdoDbalAdapterTest.php index f1888c17f..845abd187 100644 --- a/vendor/symfony/cache/Tests/Adapter/PdoDbalAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/PdoDbalAdapterTest.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Traits\PdoPruneableTrait; -/** - * @group time-sensitive - */ -class PdoDbalAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - use PdoPruneableTrait; - protected static $dbFile; - public static function setUpBeforeClass() - { - if (!\extension_loaded('pdo_sqlite')) { - self::markTestSkipped('Extension pdo_sqlite required.'); - } - self::$dbFile = \tempnam(\sys_get_temp_dir(), 'sf_sqlite_cache'); - $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter(\_PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager::getConnection(['driver' => 'pdo_sqlite', 'path' => self::$dbFile])); - $pool->createTable(); - } - public static function tearDownAfterClass() - { - @\unlink(self::$dbFile); - } - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter(\_PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager::getConnection(['driver' => 'pdo_sqlite', 'path' => self::$dbFile]), '', $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Traits\PdoPruneableTrait; +/** + * @group time-sensitive + */ +class PdoDbalAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + use PdoPruneableTrait; + protected static $dbFile; + public static function setUpBeforeClass() + { + if (!\extension_loaded('pdo_sqlite')) { + self::markTestSkipped('Extension pdo_sqlite required.'); + } + self::$dbFile = \tempnam(\sys_get_temp_dir(), 'sf_sqlite_cache'); + $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter(\_PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager::getConnection(['driver' => 'pdo_sqlite', 'path' => self::$dbFile])); + $pool->createTable(); + } + public static function tearDownAfterClass() + { + @\unlink(self::$dbFile); + } + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PdoAdapter(\_PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager::getConnection(['driver' => 'pdo_sqlite', 'path' => self::$dbFile]), '', $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/PhpArrayAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/PhpArrayAdapterTest.php index 5da874100..8e14b798f 100644 --- a/vendor/symfony/cache/Tests/Adapter/PhpArrayAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/PhpArrayAdapterTest.php @@ -1,71 +1,71 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\NullAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpArrayAdapter; -/** - * @group time-sensitive - */ -class PhpArrayAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testBasicUsage' => 'PhpArrayAdapter is read-only.', 'testBasicUsageWithLongKey' => 'PhpArrayAdapter is read-only.', 'testClear' => 'PhpArrayAdapter is read-only.', 'testClearWithDeferredItems' => 'PhpArrayAdapter is read-only.', 'testDeleteItem' => 'PhpArrayAdapter is read-only.', 'testSaveExpired' => 'PhpArrayAdapter is read-only.', 'testSaveWithoutExpire' => 'PhpArrayAdapter is read-only.', 'testDeferredSave' => 'PhpArrayAdapter is read-only.', 'testDeferredSaveWithoutCommit' => 'PhpArrayAdapter is read-only.', 'testDeleteItems' => 'PhpArrayAdapter is read-only.', 'testDeleteDeferredItem' => 'PhpArrayAdapter is read-only.', 'testCommit' => 'PhpArrayAdapter is read-only.', 'testSaveDeferredWhenChangingValues' => 'PhpArrayAdapter is read-only.', 'testSaveDeferredOverwrite' => 'PhpArrayAdapter is read-only.', 'testIsHitDeferred' => 'PhpArrayAdapter is read-only.', 'testExpiresAt' => 'PhpArrayAdapter does not support expiration.', 'testExpiresAtWithNull' => 'PhpArrayAdapter does not support expiration.', 'testExpiresAfterWithNull' => 'PhpArrayAdapter does not support expiration.', 'testDeferredExpired' => 'PhpArrayAdapter does not support expiration.', 'testExpiration' => 'PhpArrayAdapter does not support expiration.', 'testGetItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testGetItemsInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testHasItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testDeleteItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testDeleteItemsInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testDefaultLifeTime' => 'PhpArrayAdapter does not allow configuring a default lifetime.', 'testPrune' => 'PhpArrayAdapter just proxies']; - protected static $file; - public static function setUpBeforeClass() - { - self::$file = \sys_get_temp_dir() . '/symfony-cache/php-array-adapter-test.php'; - } - protected function tearDown() - { - $this->createCachePool()->clear(); - if (\file_exists(\sys_get_temp_dir() . '/symfony-cache')) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); - } - } - public function createCachePool() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\PhpArrayAdapterWrapper(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\NullAdapter()); - } - public function testStore() - { - $arrayWithRefs = []; - $arrayWithRefs[0] = 123; - $arrayWithRefs[1] =& $arrayWithRefs[0]; - $object = (object) ['foo' => 'bar', 'foo2' => 'bar2']; - $expected = ['null' => null, 'serializedString' => \serialize($object), 'arrayWithRefs' => $arrayWithRefs, 'object' => $object, 'arrayWithObject' => ['bar' => $object]]; - $adapter = $this->createCachePool(); - $adapter->warmUp($expected); - foreach ($expected as $key => $value) { - $this->assertSame(\serialize($value), \serialize($adapter->getItem($key)->get()), 'Warm up should create a PHP file that OPCache can load in memory'); - } - } - public function testStoredFile() - { - $expected = ['integer' => 42, 'float' => 42.42, 'boolean' => \true, 'array_simple' => ['foo', 'bar'], 'array_associative' => ['foo' => 'bar', 'foo2' => 'bar2']]; - $adapter = $this->createCachePool(); - $adapter->warmUp($expected); - $values = eval(\substr(\file_get_contents(self::$file), 6)); - $this->assertSame($expected, $values, 'Warm up should create a PHP file that OPCache can load in memory'); - } -} -class PhpArrayAdapterWrapper extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpArrayAdapter -{ - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - \call_user_func(\Closure::bind(function () use($item) { - $this->values[$item->getKey()] = $item->get(); - $this->warmUp($this->values); - $this->values = eval(\substr(\file_get_contents($this->file), 6)); - }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpArrayAdapter::class)); - return \true; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\NullAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpArrayAdapter; +/** + * @group time-sensitive + */ +class PhpArrayAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testBasicUsage' => 'PhpArrayAdapter is read-only.', 'testBasicUsageWithLongKey' => 'PhpArrayAdapter is read-only.', 'testClear' => 'PhpArrayAdapter is read-only.', 'testClearWithDeferredItems' => 'PhpArrayAdapter is read-only.', 'testDeleteItem' => 'PhpArrayAdapter is read-only.', 'testSaveExpired' => 'PhpArrayAdapter is read-only.', 'testSaveWithoutExpire' => 'PhpArrayAdapter is read-only.', 'testDeferredSave' => 'PhpArrayAdapter is read-only.', 'testDeferredSaveWithoutCommit' => 'PhpArrayAdapter is read-only.', 'testDeleteItems' => 'PhpArrayAdapter is read-only.', 'testDeleteDeferredItem' => 'PhpArrayAdapter is read-only.', 'testCommit' => 'PhpArrayAdapter is read-only.', 'testSaveDeferredWhenChangingValues' => 'PhpArrayAdapter is read-only.', 'testSaveDeferredOverwrite' => 'PhpArrayAdapter is read-only.', 'testIsHitDeferred' => 'PhpArrayAdapter is read-only.', 'testExpiresAt' => 'PhpArrayAdapter does not support expiration.', 'testExpiresAtWithNull' => 'PhpArrayAdapter does not support expiration.', 'testExpiresAfterWithNull' => 'PhpArrayAdapter does not support expiration.', 'testDeferredExpired' => 'PhpArrayAdapter does not support expiration.', 'testExpiration' => 'PhpArrayAdapter does not support expiration.', 'testGetItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testGetItemsInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testHasItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testDeleteItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testDeleteItemsInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testDefaultLifeTime' => 'PhpArrayAdapter does not allow configuring a default lifetime.', 'testPrune' => 'PhpArrayAdapter just proxies']; + protected static $file; + public static function setUpBeforeClass() + { + self::$file = \sys_get_temp_dir() . '/symfony-cache/php-array-adapter-test.php'; + } + protected function tearDown() + { + $this->createCachePool()->clear(); + if (\file_exists(\sys_get_temp_dir() . '/symfony-cache')) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); + } + } + public function createCachePool() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\PhpArrayAdapterWrapper(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\NullAdapter()); + } + public function testStore() + { + $arrayWithRefs = []; + $arrayWithRefs[0] = 123; + $arrayWithRefs[1] =& $arrayWithRefs[0]; + $object = (object) ['foo' => 'bar', 'foo2' => 'bar2']; + $expected = ['null' => null, 'serializedString' => \serialize($object), 'arrayWithRefs' => $arrayWithRefs, 'object' => $object, 'arrayWithObject' => ['bar' => $object]]; + $adapter = $this->createCachePool(); + $adapter->warmUp($expected); + foreach ($expected as $key => $value) { + $this->assertSame(\serialize($value), \serialize($adapter->getItem($key)->get()), 'Warm up should create a PHP file that OPCache can load in memory'); + } + } + public function testStoredFile() + { + $expected = ['integer' => 42, 'float' => 42.42, 'boolean' => \true, 'array_simple' => ['foo', 'bar'], 'array_associative' => ['foo' => 'bar', 'foo2' => 'bar2']]; + $adapter = $this->createCachePool(); + $adapter->warmUp($expected); + $values = eval(\substr(\file_get_contents(self::$file), 6)); + $this->assertSame($expected, $values, 'Warm up should create a PHP file that OPCache can load in memory'); + } +} +class PhpArrayAdapterWrapper extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpArrayAdapter +{ + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + \call_user_func(\Closure::bind(function () use($item) { + $this->values[$item->getKey()] = $item->get(); + $this->warmUp($this->values); + $this->values = eval(\substr(\file_get_contents($this->file), 6)); + }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpArrayAdapter::class)); + return \true; + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/PhpArrayAdapterWithFallbackTest.php b/vendor/symfony/cache/Tests/Adapter/PhpArrayAdapterWithFallbackTest.php index 2fcf7b6b7..010be24e6 100644 --- a/vendor/symfony/cache/Tests/Adapter/PhpArrayAdapterWithFallbackTest.php +++ b/vendor/symfony/cache/Tests/Adapter/PhpArrayAdapterWithFallbackTest.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpArrayAdapter; -/** - * @group time-sensitive - */ -class PhpArrayAdapterWithFallbackTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testGetItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testGetItemsInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testHasItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testDeleteItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testDeleteItemsInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testPrune' => 'PhpArrayAdapter just proxies']; - protected static $file; - public static function setUpBeforeClass() - { - self::$file = \sys_get_temp_dir() . '/symfony-cache/php-array-adapter-test.php'; - } - protected function tearDown() - { - $this->createCachePool()->clear(); - if (\file_exists(\sys_get_temp_dir() . '/symfony-cache')) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); - } - } - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpArrayAdapter(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('php-array-fallback', $defaultLifetime)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpArrayAdapter; +/** + * @group time-sensitive + */ +class PhpArrayAdapterWithFallbackTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testGetItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testGetItemsInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testHasItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testDeleteItemInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testDeleteItemsInvalidKeys' => 'PhpArrayAdapter does not throw exceptions on invalid key.', 'testPrune' => 'PhpArrayAdapter just proxies']; + protected static $file; + public static function setUpBeforeClass() + { + self::$file = \sys_get_temp_dir() . '/symfony-cache/php-array-adapter-test.php'; + } + protected function tearDown() + { + $this->createCachePool()->clear(); + if (\file_exists(\sys_get_temp_dir() . '/symfony-cache')) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); + } + } + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpArrayAdapter(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('php-array-fallback', $defaultLifetime)); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/PhpFilesAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/PhpFilesAdapterTest.php index 273b3a9ac..a4f465aec 100644 --- a/vendor/symfony/cache/Tests/Adapter/PhpFilesAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/PhpFilesAdapterTest.php @@ -1,38 +1,38 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpFilesAdapter; -/** - * @group time-sensitive - */ -class PhpFilesAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testDefaultLifeTime' => 'PhpFilesAdapter does not allow configuring a default lifetime.']; - public function createCachePool() - { - if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpFilesAdapter::isSupported()) { - $this->markTestSkipped('OPcache extension is not enabled.'); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpFilesAdapter('sf-cache'); - } - public static function tearDownAfterClass() - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); - } - protected function isPruned(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $cache, $name) - { - $getFileMethod = (new \ReflectionObject($cache))->getMethod('getFile'); - $getFileMethod->setAccessible(\true); - return !\file_exists($getFileMethod->invoke($cache, $name)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpFilesAdapter; +/** + * @group time-sensitive + */ +class PhpFilesAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testDefaultLifeTime' => 'PhpFilesAdapter does not allow configuring a default lifetime.']; + public function createCachePool() + { + if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpFilesAdapter::isSupported()) { + $this->markTestSkipped('OPcache extension is not enabled.'); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\PhpFilesAdapter('sf-cache'); + } + public static function tearDownAfterClass() + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); + } + protected function isPruned(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface $cache, $name) + { + $getFileMethod = (new \ReflectionObject($cache))->getMethod('getFile'); + $getFileMethod->setAccessible(\true); + return !\file_exists($getFileMethod->invoke($cache, $name)); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/PredisAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/PredisAdapterTest.php index 32978ce13..3811c61f1 100644 --- a/vendor/symfony/cache/Tests/Adapter/PredisAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/PredisAdapterTest.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Predis\Connection\StreamConnection; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter; -class PredisAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest -{ - public static function setUpBeforeClass() - { - parent::setUpBeforeClass(); - self::$redis = new \_PhpScoper5ea00cc67502b\Predis\Client(['host' => \getenv('REDIS_HOST')]); - } - public function testCreateConnection() - { - $redisHost = \getenv('REDIS_HOST'); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost . '/1', ['class' => \_PhpScoper5ea00cc67502b\Predis\Client::class, 'timeout' => 3]); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Predis\Client::class, $redis); - $connection = $redis->getConnection(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Predis\Connection\StreamConnection::class, $connection); - $params = ['scheme' => 'tcp', 'host' => $redisHost, 'path' => '', 'dbindex' => '1', 'port' => 6379, 'class' => '_PhpScoper5ea00cc67502b\\Predis\\Client', 'timeout' => 3, 'persistent' => 0, 'persistent_id' => null, 'read_timeout' => 0, 'retry_interval' => 0, 'lazy' => \false, 'database' => '1', 'password' => null]; - $this->assertSame($params, $connection->getParameters()->toArray()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Predis\Connection\StreamConnection; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter; +class PredisAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest +{ + public static function setUpBeforeClass() + { + parent::setUpBeforeClass(); + self::$redis = new \_PhpScoper5ea00cc67502b\Predis\Client(['host' => \getenv('REDIS_HOST')]); + } + public function testCreateConnection() + { + $redisHost = \getenv('REDIS_HOST'); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost . '/1', ['class' => \_PhpScoper5ea00cc67502b\Predis\Client::class, 'timeout' => 3]); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Predis\Client::class, $redis); + $connection = $redis->getConnection(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Predis\Connection\StreamConnection::class, $connection); + $params = ['scheme' => 'tcp', 'host' => $redisHost, 'path' => '', 'dbindex' => '1', 'port' => 6379, 'class' => '_PhpScoper5ea00cc67502b\\Predis\\Client', 'timeout' => 3, 'persistent' => 0, 'persistent_id' => null, 'read_timeout' => 0, 'retry_interval' => 0, 'lazy' => \false, 'database' => '1', 'password' => null]; + $this->assertSame($params, $connection->getParameters()->toArray()); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/PredisClusterAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/PredisClusterAdapterTest.php index ab67b4d3d..67c516e79 100644 --- a/vendor/symfony/cache/Tests/Adapter/PredisClusterAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/PredisClusterAdapterTest.php @@ -1,24 +1,24 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -class PredisClusterAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest -{ - public static function setUpBeforeClass() - { - parent::setUpBeforeClass(); - self::$redis = new \_PhpScoper5ea00cc67502b\Predis\Client([['host' => \getenv('REDIS_HOST')]]); - } - public static function tearDownAfterClass() - { - self::$redis = null; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +class PredisClusterAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest +{ + public static function setUpBeforeClass() + { + parent::setUpBeforeClass(); + self::$redis = new \_PhpScoper5ea00cc67502b\Predis\Client([['host' => \getenv('REDIS_HOST')]]); + } + public static function tearDownAfterClass() + { + self::$redis = null; + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/PredisRedisClusterAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/PredisRedisClusterAdapterTest.php index 058409378..3c886b88f 100644 --- a/vendor/symfony/cache/Tests/Adapter/PredisRedisClusterAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/PredisRedisClusterAdapterTest.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -class PredisRedisClusterAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest -{ - public static function setUpBeforeClass() - { - if (!($hosts = \getenv('REDIS_CLUSTER_HOSTS'))) { - self::markTestSkipped('REDIS_CLUSTER_HOSTS env var is not defined.'); - } - self::$redis = new \_PhpScoper5ea00cc67502b\Predis\Client(\explode(' ', $hosts), ['cluster' => 'redis']); - } - public static function tearDownAfterClass() - { - self::$redis = null; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +class PredisRedisClusterAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest +{ + public static function setUpBeforeClass() + { + if (!($hosts = \getenv('REDIS_CLUSTER_HOSTS'))) { + self::markTestSkipped('REDIS_CLUSTER_HOSTS env var is not defined.'); + } + self::$redis = new \_PhpScoper5ea00cc67502b\Predis\Client(\explode(' ', $hosts), ['cluster' => 'redis']); + } + public static function tearDownAfterClass() + { + self::$redis = null; + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/ProxyAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/ProxyAdapterTest.php index 622e0b47c..1424c824b 100644 --- a/vendor/symfony/cache/Tests/Adapter/ProxyAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/ProxyAdapterTest.php @@ -1,55 +1,55 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -/** - * @group time-sensitive - */ -class ProxyAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testDeferredSaveWithoutCommit' => 'Assumes a shared cache which ArrayAdapter is not.', 'testSaveWithoutExpire' => 'Assumes a shared cache which ArrayAdapter is not.', 'testPrune' => 'ProxyAdapter just proxies']; - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter(), '', $defaultLifetime); - } - public function testProxyfiedItem() - { - $this->expectException('Exception'); - $this->expectExceptionMessage('OK bar'); - $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); - $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\TestingArrayAdapter($item)); - $proxyItem = $pool->getItem('foo'); - $this->assertNotSame($item, $proxyItem); - $pool->save($proxyItem->set('bar')); - } -} -class TestingArrayAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter -{ - private $item; - public function __construct(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - $this->item = $item; - } - public function getItem($key) - { - return $this->item; - } - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - if ($item === $this->item) { - throw new \Exception('OK ' . $item->get()); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +/** + * @group time-sensitive + */ +class ProxyAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testDeferredSaveWithoutCommit' => 'Assumes a shared cache which ArrayAdapter is not.', 'testSaveWithoutExpire' => 'Assumes a shared cache which ArrayAdapter is not.', 'testPrune' => 'ProxyAdapter just proxies']; + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter(), '', $defaultLifetime); + } + public function testProxyfiedItem() + { + $this->expectException('Exception'); + $this->expectExceptionMessage('OK bar'); + $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); + $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ProxyAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\TestingArrayAdapter($item)); + $proxyItem = $pool->getItem('foo'); + $this->assertNotSame($item, $proxyItem); + $pool->save($proxyItem->set('bar')); + } +} +class TestingArrayAdapter extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter +{ + private $item; + public function __construct(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + $this->item = $item; + } + public function getItem($key) + { + return $this->item; + } + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + if ($item === $this->item) { + throw new \Exception('OK ' . $item->get()); + } + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/RedisAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/RedisAdapterTest.php index b3586068a..eb0072ab4 100644 --- a/vendor/symfony/cache/Tests/Adapter/RedisAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/RedisAdapterTest.php @@ -1,71 +1,71 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisProxy; -class RedisAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest -{ - public static function setUpBeforeClass() - { - parent::setUpBeforeClass(); - self::$redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('redis://' . \getenv('REDIS_HOST'), ['lazy' => \true]); - } - public function createCachePool($defaultLifetime = 0) - { - $adapter = parent::createCachePool($defaultLifetime); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisProxy::class, self::$redis); - return $adapter; - } - public function testCreateConnection() - { - $redisHost = \getenv('REDIS_HOST'); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Redis::class, $redis); - $this->assertTrue($redis->isConnected()); - $this->assertSame(0, $redis->getDbNum()); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost . '/2'); - $this->assertSame(2, $redis->getDbNum()); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost, ['timeout' => 3]); - $this->assertEquals(3, $redis->getTimeout()); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost . '?timeout=4'); - $this->assertEquals(4, $redis->getTimeout()); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost, ['read_timeout' => 5]); - $this->assertEquals(5, $redis->getReadTimeout()); - } - /** - * @dataProvider provideFailedCreateConnection - */ - public function testFailedCreateConnection($dsn) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Redis connection failed'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection($dsn); - } - public function provideFailedCreateConnection() - { - return [['redis://localhost:1234'], ['redis://foo@localhost'], ['redis://localhost/123']]; - } - /** - * @dataProvider provideInvalidCreateConnection - */ - public function testInvalidCreateConnection($dsn) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Invalid Redis DSN'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection($dsn); - } - public function provideInvalidCreateConnection() - { - return [['foo://localhost'], ['redis://']]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisProxy; +class RedisAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest +{ + public static function setUpBeforeClass() + { + parent::setUpBeforeClass(); + self::$redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('redis://' . \getenv('REDIS_HOST'), ['lazy' => \true]); + } + public function createCachePool($defaultLifetime = 0) + { + $adapter = parent::createCachePool($defaultLifetime); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisProxy::class, self::$redis); + return $adapter; + } + public function testCreateConnection() + { + $redisHost = \getenv('REDIS_HOST'); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Redis::class, $redis); + $this->assertTrue($redis->isConnected()); + $this->assertSame(0, $redis->getDbNum()); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost . '/2'); + $this->assertSame(2, $redis->getDbNum()); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost, ['timeout' => 3]); + $this->assertEquals(3, $redis->getTimeout()); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost . '?timeout=4'); + $this->assertEquals(4, $redis->getTimeout()); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection('redis://' . $redisHost, ['read_timeout' => 5]); + $this->assertEquals(5, $redis->getReadTimeout()); + } + /** + * @dataProvider provideFailedCreateConnection + */ + public function testFailedCreateConnection($dsn) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Redis connection failed'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection($dsn); + } + public function provideFailedCreateConnection() + { + return [['redis://localhost:1234'], ['redis://foo@localhost'], ['redis://localhost/123']]; + } + /** + * @dataProvider provideInvalidCreateConnection + */ + public function testInvalidCreateConnection($dsn) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Invalid Redis DSN'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\RedisAdapter::createConnection($dsn); + } + public function provideInvalidCreateConnection() + { + return [['foo://localhost'], ['redis://']]; + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/RedisArrayAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/RedisArrayAdapterTest.php index b55b465e3..074bfc092 100644 --- a/vendor/symfony/cache/Tests/Adapter/RedisArrayAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/RedisArrayAdapterTest.php @@ -1,23 +1,23 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -class RedisArrayAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest -{ - public static function setUpBeforeClass() - { - parent::setupBeforeClass(); - if (!\class_exists('_PhpScoper5ea00cc67502b\\RedisArray')) { - self::markTestSkipped('The RedisArray class is required.'); - } - self::$redis = new \_PhpScoper5ea00cc67502b\RedisArray([\getenv('REDIS_HOST')], ['lazy_connect' => \true]); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +class RedisArrayAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest +{ + public static function setUpBeforeClass() + { + parent::setupBeforeClass(); + if (!\class_exists('_PhpScoper5ea00cc67502b\\RedisArray')) { + self::markTestSkipped('The RedisArray class is required.'); + } + self::$redis = new \_PhpScoper5ea00cc67502b\RedisArray([\getenv('REDIS_HOST')], ['lazy_connect' => \true]); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/RedisClusterAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/RedisClusterAdapterTest.php index d593a80c5..6f2e1e6ff 100644 --- a/vendor/symfony/cache/Tests/Adapter/RedisClusterAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/RedisClusterAdapterTest.php @@ -1,25 +1,25 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -class RedisClusterAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest -{ - public static function setUpBeforeClass() - { - if (!\class_exists('_PhpScoper5ea00cc67502b\\RedisCluster')) { - self::markTestSkipped('The RedisCluster class is required.'); - } - if (!($hosts = \getenv('REDIS_CLUSTER_HOSTS'))) { - self::markTestSkipped('REDIS_CLUSTER_HOSTS env var is not defined.'); - } - self::$redis = new \_PhpScoper5ea00cc67502b\RedisCluster(null, \explode(' ', $hosts)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +class RedisClusterAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AbstractRedisAdapterTest +{ + public static function setUpBeforeClass() + { + if (!\class_exists('_PhpScoper5ea00cc67502b\\RedisCluster')) { + self::markTestSkipped('The RedisCluster class is required.'); + } + if (!($hosts = \getenv('REDIS_CLUSTER_HOSTS'))) { + self::markTestSkipped('REDIS_CLUSTER_HOSTS env var is not defined.'); + } + self::$redis = new \_PhpScoper5ea00cc67502b\RedisCluster(null, \explode(' ', $hosts)); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/SimpleCacheAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/SimpleCacheAdapterTest.php index b21de58a6..b1a9b446c 100644 --- a/vendor/symfony/cache/Tests/Adapter/SimpleCacheAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/SimpleCacheAdapterTest.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\SimpleCacheAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache; -/** - * @group time-sensitive - */ -class SimpleCacheAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testPrune' => 'SimpleCache just proxies']; - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\SimpleCacheAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache(), '', $defaultLifetime); - } - public function testValidCacheKeyWithNamespace() - { - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\SimpleCacheAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache(), 'some_namespace', 0); - $item = $cache->getItem('my_key'); - $item->set('someValue'); - $cache->save($item); - $this->assertTrue($cache->getItem('my_key')->isHit(), 'Stored item is successfully retrieved.'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\SimpleCacheAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache; +/** + * @group time-sensitive + */ +class SimpleCacheAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testPrune' => 'SimpleCache just proxies']; + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\SimpleCacheAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache(), '', $defaultLifetime); + } + public function testValidCacheKeyWithNamespace() + { + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\SimpleCacheAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache(), 'some_namespace', 0); + $item = $cache->getItem('my_key'); + $item->set('someValue'); + $cache->save($item); + $this->assertTrue($cache->getItem('my_key')->isHit(), 'Stored item is successfully retrieved.'); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/TagAwareAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/TagAwareAdapterTest.php index c837fce1c..d87a780b6 100644 --- a/vendor/symfony/cache/Tests/Adapter/TagAwareAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/TagAwareAdapterTest.php @@ -1,229 +1,229 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject; -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter; -/** - * @group time-sensitive - */ -class TagAwareAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', $defaultLifetime)); - } - public static function tearDownAfterClass() - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); - } - public function testInvalidTag() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Psr\\Cache\\InvalidArgumentException'); - $pool = $this->createCachePool(); - $item = $pool->getItem('foo'); - $item->tag(':'); - } - public function testInvalidateTags() - { - $pool = $this->createCachePool(); - $i0 = $pool->getItem('i0'); - $i1 = $pool->getItem('i1'); - $i2 = $pool->getItem('i2'); - $i3 = $pool->getItem('i3'); - $foo = $pool->getItem('foo'); - $pool->save($i0->tag('bar')); - $pool->save($i1->tag('foo')); - $pool->save($i2->tag('foo')->tag('bar')); - $pool->save($i3->tag('foo')->tag('baz')); - $pool->save($foo); - $pool->invalidateTags(['bar']); - $this->assertFalse($pool->getItem('i0')->isHit()); - $this->assertTrue($pool->getItem('i1')->isHit()); - $this->assertFalse($pool->getItem('i2')->isHit()); - $this->assertTrue($pool->getItem('i3')->isHit()); - $this->assertTrue($pool->getItem('foo')->isHit()); - $pool->invalidateTags(['foo']); - $this->assertFalse($pool->getItem('i1')->isHit()); - $this->assertFalse($pool->getItem('i3')->isHit()); - $this->assertTrue($pool->getItem('foo')->isHit()); - $anotherPoolInstance = $this->createCachePool(); - $this->assertFalse($anotherPoolInstance->getItem('i1')->isHit()); - $this->assertFalse($anotherPoolInstance->getItem('i3')->isHit()); - $this->assertTrue($anotherPoolInstance->getItem('foo')->isHit()); - } - public function testInvalidateCommits() - { - $pool1 = $this->createCachePool(); - $foo = $pool1->getItem('foo'); - $foo->tag('tag'); - $pool1->saveDeferred($foo->set('foo')); - $pool1->invalidateTags(['tag']); - $pool2 = $this->createCachePool(); - $foo = $pool2->getItem('foo'); - $this->assertTrue($foo->isHit()); - } - public function testTagsAreCleanedOnSave() - { - $pool = $this->createCachePool(); - $i = $pool->getItem('k'); - $pool->save($i->tag('foo')); - $i = $pool->getItem('k'); - $pool->save($i->tag('bar')); - $pool->invalidateTags(['foo']); - $this->assertTrue($pool->getItem('k')->isHit()); - } - public function testTagsAreCleanedOnDelete() - { - $pool = $this->createCachePool(); - $i = $pool->getItem('k'); - $pool->save($i->tag('foo')); - $pool->deleteItem('k'); - $pool->save($pool->getItem('k')); - $pool->invalidateTags(['foo']); - $this->assertTrue($pool->getItem('k')->isHit()); - } - public function testTagItemExpiry() - { - $pool = $this->createCachePool(10); - $item = $pool->getItem('foo'); - $item->tag(['baz']); - $item->expiresAfter(100); - $pool->save($item); - $pool->invalidateTags(['baz']); - $this->assertFalse($pool->getItem('foo')->isHit()); - \sleep(20); - $this->assertFalse($pool->getItem('foo')->isHit()); - } - public function testGetPreviousTags() - { - $pool = $this->createCachePool(); - $i = $pool->getItem('k'); - $pool->save($i->tag('foo')); - $i = $pool->getItem('k'); - $this->assertSame(['foo' => 'foo'], $i->getPreviousTags()); - } - public function testPrune() - { - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter($this->getPruneableMock()); - $this->assertTrue($cache->prune()); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter($this->getNonPruneableMock()); - $this->assertFalse($cache->prune()); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter($this->getFailingPruneableMock()); - $this->assertFalse($cache->prune()); - } - public function testKnownTagVersionsTtl() - { - $itemsPool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', 10); - $tagsPool = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface::class)->getMock(); - $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter($itemsPool, $tagsPool, 10); - $item = $pool->getItem('foo'); - $item->tag(['baz']); - $item->expiresAfter(100); - $tag = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface::class)->getMock(); - $tag->expects(self::exactly(2))->method('get')->willReturn(10); - $tagsPool->expects(self::exactly(2))->method('getItems')->willReturn(['baz' . \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter::TAGS_PREFIX => $tag]); - $pool->save($item); - $this->assertTrue($pool->getItem('foo')->isHit()); - $this->assertTrue($pool->getItem('foo')->isHit()); - \sleep(20); - $this->assertTrue($pool->getItem('foo')->isHit()); - \sleep(5); - $this->assertTrue($pool->getItem('foo')->isHit()); - } - public function testTagEntryIsCreatedForItemWithoutTags() - { - $pool = $this->createCachePool(); - $itemKey = 'foo'; - $item = $pool->getItem($itemKey); - $pool->save($item); - $adapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter(); - $this->assertTrue($adapter->hasItem(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter::TAGS_PREFIX . $itemKey)); - } - public function testHasItemReturnsFalseWhenPoolDoesNotHaveItemTags() - { - $pool = $this->createCachePool(); - $itemKey = 'foo'; - $item = $pool->getItem($itemKey); - $pool->save($item); - $anotherPool = $this->createCachePool(); - $adapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter(); - $adapter->deleteItem(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter::TAGS_PREFIX . $itemKey); - //simulate item losing tags pair - $this->assertFalse($anotherPool->hasItem($itemKey)); - } - public function testGetItemReturnsCacheMissWhenPoolDoesNotHaveItemTags() - { - $pool = $this->createCachePool(); - $itemKey = 'foo'; - $item = $pool->getItem($itemKey); - $pool->save($item); - $anotherPool = $this->createCachePool(); - $adapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter(); - $adapter->deleteItem(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter::TAGS_PREFIX . $itemKey); - //simulate item losing tags pair - $item = $anotherPool->getItem($itemKey); - $this->assertFalse($item->isHit()); - } - public function testHasItemReturnsFalseWhenPoolDoesNotHaveItemAndOnlyHasTags() - { - $pool = $this->createCachePool(); - $itemKey = 'foo'; - $item = $pool->getItem($itemKey); - $pool->save($item); - $anotherPool = $this->createCachePool(); - $adapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter(); - $adapter->deleteItem($itemKey); - //simulate losing item but keeping tags - $this->assertFalse($anotherPool->hasItem($itemKey)); - } - public function testGetItemReturnsCacheMissWhenPoolDoesNotHaveItemAndOnlyHasTags() - { - $pool = $this->createCachePool(); - $itemKey = 'foo'; - $item = $pool->getItem($itemKey); - $pool->save($item); - $anotherPool = $this->createCachePool(); - $adapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter(); - $adapter->deleteItem($itemKey); - //simulate losing item but keeping tags - $item = $anotherPool->getItem($itemKey); - $this->assertFalse($item->isHit()); - } - /** - * @return MockObject|PruneableCacheInterface - */ - private function getPruneableMock() - { - $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\PruneableCacheInterface::class)->getMock(); - $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\true); - return $pruneable; - } - /** - * @return MockObject|PruneableCacheInterface - */ - private function getFailingPruneableMock() - { - $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\PruneableCacheInterface::class)->getMock(); - $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\false); - return $pruneable; - } - /** - * @return MockObject|AdapterInterface - */ - private function getNonPruneableMock() - { - return $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface::class)->getMock(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject; +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter; +/** + * @group time-sensitive + */ +class TagAwareAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', $defaultLifetime)); + } + public static function tearDownAfterClass() + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); + } + public function testInvalidTag() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Psr\\Cache\\InvalidArgumentException'); + $pool = $this->createCachePool(); + $item = $pool->getItem('foo'); + $item->tag(':'); + } + public function testInvalidateTags() + { + $pool = $this->createCachePool(); + $i0 = $pool->getItem('i0'); + $i1 = $pool->getItem('i1'); + $i2 = $pool->getItem('i2'); + $i3 = $pool->getItem('i3'); + $foo = $pool->getItem('foo'); + $pool->save($i0->tag('bar')); + $pool->save($i1->tag('foo')); + $pool->save($i2->tag('foo')->tag('bar')); + $pool->save($i3->tag('foo')->tag('baz')); + $pool->save($foo); + $pool->invalidateTags(['bar']); + $this->assertFalse($pool->getItem('i0')->isHit()); + $this->assertTrue($pool->getItem('i1')->isHit()); + $this->assertFalse($pool->getItem('i2')->isHit()); + $this->assertTrue($pool->getItem('i3')->isHit()); + $this->assertTrue($pool->getItem('foo')->isHit()); + $pool->invalidateTags(['foo']); + $this->assertFalse($pool->getItem('i1')->isHit()); + $this->assertFalse($pool->getItem('i3')->isHit()); + $this->assertTrue($pool->getItem('foo')->isHit()); + $anotherPoolInstance = $this->createCachePool(); + $this->assertFalse($anotherPoolInstance->getItem('i1')->isHit()); + $this->assertFalse($anotherPoolInstance->getItem('i3')->isHit()); + $this->assertTrue($anotherPoolInstance->getItem('foo')->isHit()); + } + public function testInvalidateCommits() + { + $pool1 = $this->createCachePool(); + $foo = $pool1->getItem('foo'); + $foo->tag('tag'); + $pool1->saveDeferred($foo->set('foo')); + $pool1->invalidateTags(['tag']); + $pool2 = $this->createCachePool(); + $foo = $pool2->getItem('foo'); + $this->assertTrue($foo->isHit()); + } + public function testTagsAreCleanedOnSave() + { + $pool = $this->createCachePool(); + $i = $pool->getItem('k'); + $pool->save($i->tag('foo')); + $i = $pool->getItem('k'); + $pool->save($i->tag('bar')); + $pool->invalidateTags(['foo']); + $this->assertTrue($pool->getItem('k')->isHit()); + } + public function testTagsAreCleanedOnDelete() + { + $pool = $this->createCachePool(); + $i = $pool->getItem('k'); + $pool->save($i->tag('foo')); + $pool->deleteItem('k'); + $pool->save($pool->getItem('k')); + $pool->invalidateTags(['foo']); + $this->assertTrue($pool->getItem('k')->isHit()); + } + public function testTagItemExpiry() + { + $pool = $this->createCachePool(10); + $item = $pool->getItem('foo'); + $item->tag(['baz']); + $item->expiresAfter(100); + $pool->save($item); + $pool->invalidateTags(['baz']); + $this->assertFalse($pool->getItem('foo')->isHit()); + \sleep(20); + $this->assertFalse($pool->getItem('foo')->isHit()); + } + public function testGetPreviousTags() + { + $pool = $this->createCachePool(); + $i = $pool->getItem('k'); + $pool->save($i->tag('foo')); + $i = $pool->getItem('k'); + $this->assertSame(['foo' => 'foo'], $i->getPreviousTags()); + } + public function testPrune() + { + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter($this->getPruneableMock()); + $this->assertTrue($cache->prune()); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter($this->getNonPruneableMock()); + $this->assertFalse($cache->prune()); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter($this->getFailingPruneableMock()); + $this->assertFalse($cache->prune()); + } + public function testKnownTagVersionsTtl() + { + $itemsPool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', 10); + $tagsPool = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface::class)->getMock(); + $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter($itemsPool, $tagsPool, 10); + $item = $pool->getItem('foo'); + $item->tag(['baz']); + $item->expiresAfter(100); + $tag = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface::class)->getMock(); + $tag->expects(self::exactly(2))->method('get')->willReturn(10); + $tagsPool->expects(self::exactly(2))->method('getItems')->willReturn(['baz' . \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter::TAGS_PREFIX => $tag]); + $pool->save($item); + $this->assertTrue($pool->getItem('foo')->isHit()); + $this->assertTrue($pool->getItem('foo')->isHit()); + \sleep(20); + $this->assertTrue($pool->getItem('foo')->isHit()); + \sleep(5); + $this->assertTrue($pool->getItem('foo')->isHit()); + } + public function testTagEntryIsCreatedForItemWithoutTags() + { + $pool = $this->createCachePool(); + $itemKey = 'foo'; + $item = $pool->getItem($itemKey); + $pool->save($item); + $adapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter(); + $this->assertTrue($adapter->hasItem(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter::TAGS_PREFIX . $itemKey)); + } + public function testHasItemReturnsFalseWhenPoolDoesNotHaveItemTags() + { + $pool = $this->createCachePool(); + $itemKey = 'foo'; + $item = $pool->getItem($itemKey); + $pool->save($item); + $anotherPool = $this->createCachePool(); + $adapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter(); + $adapter->deleteItem(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter::TAGS_PREFIX . $itemKey); + //simulate item losing tags pair + $this->assertFalse($anotherPool->hasItem($itemKey)); + } + public function testGetItemReturnsCacheMissWhenPoolDoesNotHaveItemTags() + { + $pool = $this->createCachePool(); + $itemKey = 'foo'; + $item = $pool->getItem($itemKey); + $pool->save($item); + $anotherPool = $this->createCachePool(); + $adapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter(); + $adapter->deleteItem(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter::TAGS_PREFIX . $itemKey); + //simulate item losing tags pair + $item = $anotherPool->getItem($itemKey); + $this->assertFalse($item->isHit()); + } + public function testHasItemReturnsFalseWhenPoolDoesNotHaveItemAndOnlyHasTags() + { + $pool = $this->createCachePool(); + $itemKey = 'foo'; + $item = $pool->getItem($itemKey); + $pool->save($item); + $anotherPool = $this->createCachePool(); + $adapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter(); + $adapter->deleteItem($itemKey); + //simulate losing item but keeping tags + $this->assertFalse($anotherPool->hasItem($itemKey)); + } + public function testGetItemReturnsCacheMissWhenPoolDoesNotHaveItemAndOnlyHasTags() + { + $pool = $this->createCachePool(); + $itemKey = 'foo'; + $item = $pool->getItem($itemKey); + $pool->save($item); + $anotherPool = $this->createCachePool(); + $adapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter(); + $adapter->deleteItem($itemKey); + //simulate losing item but keeping tags + $item = $anotherPool->getItem($itemKey); + $this->assertFalse($item->isHit()); + } + /** + * @return MockObject|PruneableCacheInterface + */ + private function getPruneableMock() + { + $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\PruneableCacheInterface::class)->getMock(); + $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\true); + return $pruneable; + } + /** + * @return MockObject|PruneableCacheInterface + */ + private function getFailingPruneableMock() + { + $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\PruneableCacheInterface::class)->getMock(); + $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\false); + return $pruneable; + } + /** + * @return MockObject|AdapterInterface + */ + private function getNonPruneableMock() + { + return $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AdapterInterface::class)->getMock(); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/TagAwareAndProxyAdapterIntegrationTest.php b/vendor/symfony/cache/Tests/Adapter/TagAwareAndProxyAdapterIntegrationTest.php index 550f59da9..1237a984a 100644 --- a/vendor/symfony/cache/Tests/Adapter/TagAwareAndProxyAdapterIntegrationTest.php +++ b/vendor/symfony/cache/Tests/Adapter/TagAwareAndProxyAdapterIntegrationTest.php @@ -1,34 +1,34 @@ -getItem('foo'); - $item->tag(['tag1', 'tag2']); - $item->set('bar'); - $cache->save($item); - $this->assertSame('bar', $cache->getItem('foo')->get()); - } - public function dataProvider() - { - return [ - [new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter()], - // also testing with a non-AdapterInterface implementation - // because the ProxyAdapter behaves slightly different for those - [new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ExternalAdapter()], - ]; - } -} +getItem('foo'); + $item->tag(['tag1', 'tag2']); + $item->set('bar'); + $cache->save($item); + $this->assertSame('bar', $cache->getItem('foo')->get()); + } + public function dataProvider() + { + return [ + [new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter()], + // also testing with a non-AdapterInterface implementation + // because the ProxyAdapter behaves slightly different for those + [new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ExternalAdapter()], + ]; + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/TraceableAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/TraceableAdapterTest.php index 51fe1fe83..0d06f8e85 100644 --- a/vendor/symfony/cache/Tests/Adapter/TraceableAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/TraceableAdapterTest.php @@ -1,166 +1,166 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapter; -/** - * @group time-sensitive - */ -class TraceableAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase -{ - protected $skippedTests = ['testPrune' => 'TraceableAdapter just proxies']; - public function createCachePool($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', $defaultLifetime)); - } - public function testGetItemMissTrace() - { - $pool = $this->createCachePool(); - $pool->getItem('k'); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('getItem', $call->name); - $this->assertSame(['k' => \false], $call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(1, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testGetItemHitTrace() - { - $pool = $this->createCachePool(); - $item = $pool->getItem('k')->set('foo'); - $pool->save($item); - $pool->getItem('k'); - $calls = $pool->getCalls(); - $this->assertCount(3, $calls); - $call = $calls[2]; - $this->assertSame(1, $call->hits); - $this->assertSame(0, $call->misses); - } - public function testGetItemsMissTrace() - { - $pool = $this->createCachePool(); - $arg = ['k0', 'k1']; - $items = $pool->getItems($arg); - foreach ($items as $item) { - } - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('getItems', $call->name); - $this->assertSame(['k0' => \false, 'k1' => \false], $call->result); - $this->assertSame(2, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testHasItemMissTrace() - { - $pool = $this->createCachePool(); - $pool->hasItem('k'); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('hasItem', $call->name); - $this->assertSame(['k' => \false], $call->result); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testHasItemHitTrace() - { - $pool = $this->createCachePool(); - $item = $pool->getItem('k')->set('foo'); - $pool->save($item); - $pool->hasItem('k'); - $calls = $pool->getCalls(); - $this->assertCount(3, $calls); - $call = $calls[2]; - $this->assertSame('hasItem', $call->name); - $this->assertSame(['k' => \true], $call->result); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testDeleteItemTrace() - { - $pool = $this->createCachePool(); - $pool->deleteItem('k'); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('deleteItem', $call->name); - $this->assertSame(['k' => \true], $call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(0, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testDeleteItemsTrace() - { - $pool = $this->createCachePool(); - $arg = ['k0', 'k1']; - $pool->deleteItems($arg); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('deleteItems', $call->name); - $this->assertSame(['keys' => $arg, 'result' => \true], $call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(0, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testSaveTrace() - { - $pool = $this->createCachePool(); - $item = $pool->getItem('k')->set('foo'); - $pool->save($item); - $calls = $pool->getCalls(); - $this->assertCount(2, $calls); - $call = $calls[1]; - $this->assertSame('save', $call->name); - $this->assertSame(['k' => \true], $call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(0, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testSaveDeferredTrace() - { - $pool = $this->createCachePool(); - $item = $pool->getItem('k')->set('foo'); - $pool->saveDeferred($item); - $calls = $pool->getCalls(); - $this->assertCount(2, $calls); - $call = $calls[1]; - $this->assertSame('saveDeferred', $call->name); - $this->assertSame(['k' => \true], $call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(0, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testCommitTrace() - { - $pool = $this->createCachePool(); - $pool->commit(); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('commit', $call->name); - $this->assertTrue($call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(0, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapter; +/** + * @group time-sensitive + */ +class TraceableAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\AdapterTestCase +{ + protected $skippedTests = ['testPrune' => 'TraceableAdapter just proxies']; + public function createCachePool($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', $defaultLifetime)); + } + public function testGetItemMissTrace() + { + $pool = $this->createCachePool(); + $pool->getItem('k'); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('getItem', $call->name); + $this->assertSame(['k' => \false], $call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(1, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testGetItemHitTrace() + { + $pool = $this->createCachePool(); + $item = $pool->getItem('k')->set('foo'); + $pool->save($item); + $pool->getItem('k'); + $calls = $pool->getCalls(); + $this->assertCount(3, $calls); + $call = $calls[2]; + $this->assertSame(1, $call->hits); + $this->assertSame(0, $call->misses); + } + public function testGetItemsMissTrace() + { + $pool = $this->createCachePool(); + $arg = ['k0', 'k1']; + $items = $pool->getItems($arg); + foreach ($items as $item) { + } + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('getItems', $call->name); + $this->assertSame(['k0' => \false, 'k1' => \false], $call->result); + $this->assertSame(2, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testHasItemMissTrace() + { + $pool = $this->createCachePool(); + $pool->hasItem('k'); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('hasItem', $call->name); + $this->assertSame(['k' => \false], $call->result); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testHasItemHitTrace() + { + $pool = $this->createCachePool(); + $item = $pool->getItem('k')->set('foo'); + $pool->save($item); + $pool->hasItem('k'); + $calls = $pool->getCalls(); + $this->assertCount(3, $calls); + $call = $calls[2]; + $this->assertSame('hasItem', $call->name); + $this->assertSame(['k' => \true], $call->result); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testDeleteItemTrace() + { + $pool = $this->createCachePool(); + $pool->deleteItem('k'); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('deleteItem', $call->name); + $this->assertSame(['k' => \true], $call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(0, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testDeleteItemsTrace() + { + $pool = $this->createCachePool(); + $arg = ['k0', 'k1']; + $pool->deleteItems($arg); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('deleteItems', $call->name); + $this->assertSame(['keys' => $arg, 'result' => \true], $call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(0, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testSaveTrace() + { + $pool = $this->createCachePool(); + $item = $pool->getItem('k')->set('foo'); + $pool->save($item); + $calls = $pool->getCalls(); + $this->assertCount(2, $calls); + $call = $calls[1]; + $this->assertSame('save', $call->name); + $this->assertSame(['k' => \true], $call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(0, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testSaveDeferredTrace() + { + $pool = $this->createCachePool(); + $item = $pool->getItem('k')->set('foo'); + $pool->saveDeferred($item); + $calls = $pool->getCalls(); + $this->assertCount(2, $calls); + $call = $calls[1]; + $this->assertSame('saveDeferred', $call->name); + $this->assertSame(['k' => \true], $call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(0, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testCommitTrace() + { + $pool = $this->createCachePool(); + $pool->commit(); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('commit', $call->name); + $this->assertTrue($call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(0, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/TraceableTagAwareAdapterTest.php b/vendor/symfony/cache/Tests/Adapter/TraceableTagAwareAdapterTest.php index 703366d00..f4f2adad8 100644 --- a/vendor/symfony/cache/Tests/Adapter/TraceableTagAwareAdapterTest.php +++ b/vendor/symfony/cache/Tests/Adapter/TraceableTagAwareAdapterTest.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableTagAwareAdapter; -/** - * @group time-sensitive - */ -class TraceableTagAwareAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\TraceableAdapterTest -{ - public function testInvalidateTags() - { - $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableTagAwareAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter())); - $pool->invalidateTags(['foo']); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('invalidateTags', $call->name); - $this->assertSame(0, $call->hits); - $this->assertSame(0, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableTagAwareAdapter; +/** + * @group time-sensitive + */ +class TraceableTagAwareAdapterTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\TraceableAdapterTest +{ + public function testInvalidateTags() + { + $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TraceableTagAwareAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\TagAwareAdapter(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter())); + $pool->invalidateTags(['foo']); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('invalidateTags', $call->name); + $this->assertSame(0, $call->hits); + $this->assertSame(0, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } +} diff --git a/vendor/symfony/cache/Tests/Adapter/index.php b/vendor/symfony/cache/Tests/Adapter/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/Tests/Adapter/index.php +++ b/vendor/symfony/cache/Tests/Adapter/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Tests/CacheItemTest.php b/vendor/symfony/cache/Tests/CacheItemTest.php index ed89ab6b5..5c5a0da0e 100644 --- a/vendor/symfony/cache/Tests/CacheItemTest.php +++ b/vendor/symfony/cache/Tests/CacheItemTest.php @@ -1,53 +1,53 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -class CacheItemTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testValidKey() - { - $this->assertSame('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey('foo')); - } - /** - * @dataProvider provideInvalidKey - */ - public function testInvalidKey($key) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Cache key'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - } - public function provideInvalidKey() - { - return [[''], ['{'], ['}'], ['('], [')'], ['/'], ['\\'], ['@'], [':'], [\true], [null], [1], [1.1], [[[]]], [new \Exception('foo')]]; - } - public function testTag() - { - $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); - $this->assertSame($item, $item->tag('foo')); - $this->assertSame($item, $item->tag(['bar', 'baz'])); - \call_user_func(\Closure::bind(function () use($item) { - $this->assertSame(['foo' => 'foo', 'bar' => 'bar', 'baz' => 'baz'], $item->tags); - }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class)); - } - /** - * @dataProvider provideInvalidKey - */ - public function testInvalidTag($tag) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Cache tag'); - $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); - $item->tag($tag); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +class CacheItemTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testValidKey() + { + $this->assertSame('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey('foo')); + } + /** + * @dataProvider provideInvalidKey + */ + public function testInvalidKey($key) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Cache key'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + } + public function provideInvalidKey() + { + return [[''], ['{'], ['}'], ['('], [')'], ['/'], ['\\'], ['@'], [':'], [\true], [null], [1], [1.1], [[[]]], [new \Exception('foo')]]; + } + public function testTag() + { + $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); + $this->assertSame($item, $item->tag('foo')); + $this->assertSame($item, $item->tag(['bar', 'baz'])); + \call_user_func(\Closure::bind(function () use($item) { + $this->assertSame(['foo' => 'foo', 'bar' => 'bar', 'baz' => 'baz'], $item->tags); + }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class)); + } + /** + * @dataProvider provideInvalidKey + */ + public function testInvalidTag($tag) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Cache tag'); + $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); + $item->tag($tag); + } +} diff --git a/vendor/symfony/cache/Tests/DoctrineProviderTest.php b/vendor/symfony/cache/Tests/DoctrineProviderTest.php index 139449516..63baa461e 100644 --- a/vendor/symfony/cache/Tests/DoctrineProviderTest.php +++ b/vendor/symfony/cache/Tests/DoctrineProviderTest.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests; - -use _PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider; -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\DoctrineProvider; -class DoctrineProviderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProvider() - { - $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter(); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\DoctrineProvider($pool); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider::class, $cache); - $key = '{}()/\\@:'; - $this->assertTrue($cache->delete($key)); - $this->assertFalse($cache->contains($key)); - $this->assertTrue($cache->save($key, 'bar')); - $this->assertTrue($cache->contains($key)); - $this->assertSame('bar', $cache->fetch($key)); - $this->assertTrue($cache->delete($key)); - $this->assertFalse($cache->fetch($key)); - $this->assertTrue($cache->save($key, 'bar')); - $cache->flushAll(); - $this->assertFalse($cache->fetch($key)); - $this->assertFalse($cache->contains($key)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests; + +use _PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider; +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\DoctrineProvider; +class DoctrineProviderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProvider() + { + $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter(); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\DoctrineProvider($pool); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Doctrine\Common\Cache\CacheProvider::class, $cache); + $key = '{}()/\\@:'; + $this->assertTrue($cache->delete($key)); + $this->assertFalse($cache->contains($key)); + $this->assertTrue($cache->save($key, 'bar')); + $this->assertTrue($cache->contains($key)); + $this->assertSame('bar', $cache->fetch($key)); + $this->assertTrue($cache->delete($key)); + $this->assertFalse($cache->fetch($key)); + $this->assertTrue($cache->save($key, 'bar')); + $cache->flushAll(); + $this->assertFalse($cache->fetch($key)); + $this->assertFalse($cache->contains($key)); + } +} diff --git a/vendor/symfony/cache/Tests/Fixtures/ArrayCache.php b/vendor/symfony/cache/Tests/Fixtures/ArrayCache.php index 788f18c41..6a2b11404 100644 --- a/vendor/symfony/cache/Tests/Fixtures/ArrayCache.php +++ b/vendor/symfony/cache/Tests/Fixtures/ArrayCache.php @@ -1,40 +1,40 @@ -doContains($id) ? $this->data[$id][0] : \false; - } - protected function doContains($id) - { - if (!isset($this->data[$id])) { - return \false; - } - $expiry = $this->data[$id][1]; - return !$expiry || \time() < $expiry || !$this->doDelete($id); - } - protected function doSave($id, $data, $lifeTime = 0) - { - $this->data[$id] = [$data, $lifeTime ? \time() + $lifeTime : \false]; - return \true; - } - protected function doDelete($id) - { - unset($this->data[$id]); - return \true; - } - protected function doFlush() - { - $this->data = []; - return \true; - } - protected function doGetStats() - { - return null; - } -} +doContains($id) ? $this->data[$id][0] : \false; + } + protected function doContains($id) + { + if (!isset($this->data[$id])) { + return \false; + } + $expiry = $this->data[$id][1]; + return !$expiry || \time() < $expiry || !$this->doDelete($id); + } + protected function doSave($id, $data, $lifeTime = 0) + { + $this->data[$id] = [$data, $lifeTime ? \time() + $lifeTime : \false]; + return \true; + } + protected function doDelete($id) + { + unset($this->data[$id]); + return \true; + } + protected function doFlush() + { + $this->data = []; + return \true; + } + protected function doGetStats() + { + return null; + } +} diff --git a/vendor/symfony/cache/Tests/Fixtures/ExternalAdapter.php b/vendor/symfony/cache/Tests/Fixtures/ExternalAdapter.php index 9985de77f..e9228bfd9 100644 --- a/vendor/symfony/cache/Tests/Fixtures/ExternalAdapter.php +++ b/vendor/symfony/cache/Tests/Fixtures/ExternalAdapter.php @@ -1,64 +1,64 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; -/** - * Adapter not implementing the {@see \Symfony\Component\Cache\Adapter\AdapterInterface}. - * - * @author Kévin Dunglas - */ -class ExternalAdapter implements \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface -{ - private $cache; - public function __construct() - { - $this->cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter(); - } - public function getItem($key) - { - return $this->cache->getItem($key); - } - public function getItems(array $keys = []) - { - return $this->cache->getItems($keys); - } - public function hasItem($key) - { - return $this->cache->hasItem($key); - } - public function clear() - { - return $this->cache->clear(); - } - public function deleteItem($key) - { - return $this->cache->deleteItem($key); - } - public function deleteItems(array $keys) - { - return $this->cache->deleteItems($keys); - } - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - return $this->cache->save($item); - } - public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - return $this->cache->saveDeferred($item); - } - public function commit() - { - return $this->cache->commit(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; +/** + * Adapter not implementing the {@see \Symfony\Component\Cache\Adapter\AdapterInterface}. + * + * @author Kévin Dunglas + */ +class ExternalAdapter implements \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface +{ + private $cache; + public function __construct() + { + $this->cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter(); + } + public function getItem($key) + { + return $this->cache->getItem($key); + } + public function getItems(array $keys = []) + { + return $this->cache->getItems($keys); + } + public function hasItem($key) + { + return $this->cache->hasItem($key); + } + public function clear() + { + return $this->cache->clear(); + } + public function deleteItem($key) + { + return $this->cache->deleteItem($key); + } + public function deleteItems(array $keys) + { + return $this->cache->deleteItems($keys); + } + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + return $this->cache->save($item); + } + public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + return $this->cache->saveDeferred($item); + } + public function commit() + { + return $this->cache->commit(); + } +} diff --git a/vendor/symfony/cache/Tests/Fixtures/index.php b/vendor/symfony/cache/Tests/Fixtures/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/Tests/Fixtures/index.php +++ b/vendor/symfony/cache/Tests/Fixtures/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Tests/Simple/AbstractRedisCacheTest.php b/vendor/symfony/cache/Tests/Simple/AbstractRedisCacheTest.php index 0dc78c2dc..851af0406 100644 --- a/vendor/symfony/cache/Tests/Simple/AbstractRedisCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/AbstractRedisCacheTest.php @@ -1,36 +1,36 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache; -abstract class AbstractRedisCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - protected $skippedTests = ['testSetTtl' => 'Testing expiration slows down the test suite', 'testSetMultipleTtl' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; - protected static $redis; - public function createSimpleCache($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache(self::$redis, \str_replace('\\', '.', __CLASS__), $defaultLifetime); - } - public static function setUpBeforeClass() - { - if (!\extension_loaded('redis')) { - self::markTestSkipped('Extension redis required.'); - } - if (!@(new \_PhpScoper5ea00cc67502b\Redis())->connect(\getenv('REDIS_HOST'))) { - $e = \error_get_last(); - self::markTestSkipped($e['message']); - } - } - public static function tearDownAfterClass() - { - self::$redis = null; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache; +abstract class AbstractRedisCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + protected $skippedTests = ['testSetTtl' => 'Testing expiration slows down the test suite', 'testSetMultipleTtl' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; + protected static $redis; + public function createSimpleCache($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache(self::$redis, \str_replace('\\', '.', __CLASS__), $defaultLifetime); + } + public static function setUpBeforeClass() + { + if (!\extension_loaded('redis')) { + self::markTestSkipped('Extension redis required.'); + } + if (!@(new \_PhpScoper5ea00cc67502b\Redis())->connect(\getenv('REDIS_HOST'))) { + $e = \error_get_last(); + self::markTestSkipped($e['message']); + } + } + public static function tearDownAfterClass() + { + self::$redis = null; + } +} diff --git a/vendor/symfony/cache/Tests/Simple/ApcuCacheTest.php b/vendor/symfony/cache/Tests/Simple/ApcuCacheTest.php index 86a2654e4..e83643206 100644 --- a/vendor/symfony/cache/Tests/Simple/ApcuCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/ApcuCacheTest.php @@ -1,27 +1,27 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ApcuCache; -class ApcuCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - protected $skippedTests = ['testSetTtl' => 'Testing expiration slows down the test suite', 'testSetMultipleTtl' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; - public function createSimpleCache($defaultLifetime = 0) - { - if (!\function_exists('_PhpScoper5ea00cc67502b\\apcu_fetch') || !\filter_var(\ini_get('apc.enabled'), \FILTER_VALIDATE_BOOLEAN) || 'cli' === \PHP_SAPI && !\filter_var(\ini_get('apc.enable_cli'), \FILTER_VALIDATE_BOOLEAN)) { - $this->markTestSkipped('APCu extension is required.'); - } - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('Fails transiently on Windows.'); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ApcuCache(\str_replace('\\', '.', __CLASS__), $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ApcuCache; +class ApcuCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + protected $skippedTests = ['testSetTtl' => 'Testing expiration slows down the test suite', 'testSetMultipleTtl' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; + public function createSimpleCache($defaultLifetime = 0) + { + if (!\function_exists('_PhpScoper5ea00cc67502b\\apcu_fetch') || !\filter_var(\ini_get('apc.enabled'), \FILTER_VALIDATE_BOOLEAN) || 'cli' === \PHP_SAPI && !\filter_var(\ini_get('apc.enable_cli'), \FILTER_VALIDATE_BOOLEAN)) { + $this->markTestSkipped('APCu extension is required.'); + } + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('Fails transiently on Windows.'); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ApcuCache(\str_replace('\\', '.', __CLASS__), $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/ArrayCacheTest.php b/vendor/symfony/cache/Tests/Simple/ArrayCacheTest.php index acd91a81a..8ded5a541 100644 --- a/vendor/symfony/cache/Tests/Simple/ArrayCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/ArrayCacheTest.php @@ -1,23 +1,23 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache; -/** - * @group time-sensitive - */ -class ArrayCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - public function createSimpleCache($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache($defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache; +/** + * @group time-sensitive + */ +class ArrayCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + public function createSimpleCache($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache($defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/CacheTestCase.php b/vendor/symfony/cache/Tests/Simple/CacheTestCase.php index 87e201254..4ff608546 100644 --- a/vendor/symfony/cache/Tests/Simple/CacheTestCase.php +++ b/vendor/symfony/cache/Tests/Simple/CacheTestCase.php @@ -1,119 +1,119 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Cache\IntegrationTests\SimpleCacheTest; -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -abstract class CacheTestCase extends \_PhpScoper5ea00cc67502b\Cache\IntegrationTests\SimpleCacheTest -{ - protected function setUp() - { - parent::setUp(); - if (!\array_key_exists('testPrune', $this->skippedTests) && !$this->createSimpleCache() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { - $this->skippedTests['testPrune'] = 'Not a pruneable cache pool.'; - } - } - public static function validKeys() - { - if (\defined('HHVM_VERSION')) { - return parent::validKeys(); - } - return \array_merge(parent::validKeys(), [["a\0b"]]); - } - public function testDefaultLifeTime() - { - if (isset($this->skippedTests[__FUNCTION__])) { - $this->markTestSkipped($this->skippedTests[__FUNCTION__]); - } - $cache = $this->createSimpleCache(2); - $cache->clear(); - $cache->set('key.dlt', 'value'); - \sleep(1); - $this->assertSame('value', $cache->get('key.dlt')); - \sleep(2); - $this->assertNull($cache->get('key.dlt')); - $cache->clear(); - } - public function testNotUnserializable() - { - if (isset($this->skippedTests[__FUNCTION__])) { - $this->markTestSkipped($this->skippedTests[__FUNCTION__]); - } - $cache = $this->createSimpleCache(); - $cache->clear(); - $cache->set('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\NotUnserializable()); - $this->assertNull($cache->get('foo')); - $cache->setMultiple(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\NotUnserializable()]); - foreach ($cache->getMultiple(['foo']) as $value) { - } - $this->assertNull($value); - $cache->clear(); - } - public function testPrune() - { - if (isset($this->skippedTests[__FUNCTION__])) { - $this->markTestSkipped($this->skippedTests[__FUNCTION__]); - } - if (!\method_exists($this, 'isPruned')) { - $this->fail('Test classes for pruneable caches must implement `isPruned($cache, $name)` method.'); - } - /** @var PruneableInterface|CacheInterface $cache */ - $cache = $this->createSimpleCache(); - $cache->clear(); - $cache->set('foo', 'foo-val', new \DateInterval('PT05S')); - $cache->set('bar', 'bar-val', new \DateInterval('PT10S')); - $cache->set('baz', 'baz-val', new \DateInterval('PT15S')); - $cache->set('qux', 'qux-val', new \DateInterval('PT20S')); - \sleep(30); - $cache->prune(); - $this->assertTrue($this->isPruned($cache, 'foo')); - $this->assertTrue($this->isPruned($cache, 'bar')); - $this->assertTrue($this->isPruned($cache, 'baz')); - $this->assertTrue($this->isPruned($cache, 'qux')); - $cache->set('foo', 'foo-val'); - $cache->set('bar', 'bar-val', new \DateInterval('PT20S')); - $cache->set('baz', 'baz-val', new \DateInterval('PT40S')); - $cache->set('qux', 'qux-val', new \DateInterval('PT80S')); - $cache->prune(); - $this->assertFalse($this->isPruned($cache, 'foo')); - $this->assertFalse($this->isPruned($cache, 'bar')); - $this->assertFalse($this->isPruned($cache, 'baz')); - $this->assertFalse($this->isPruned($cache, 'qux')); - \sleep(30); - $cache->prune(); - $this->assertFalse($this->isPruned($cache, 'foo')); - $this->assertTrue($this->isPruned($cache, 'bar')); - $this->assertFalse($this->isPruned($cache, 'baz')); - $this->assertFalse($this->isPruned($cache, 'qux')); - \sleep(30); - $cache->prune(); - $this->assertFalse($this->isPruned($cache, 'foo')); - $this->assertTrue($this->isPruned($cache, 'baz')); - $this->assertFalse($this->isPruned($cache, 'qux')); - \sleep(30); - $cache->prune(); - $this->assertFalse($this->isPruned($cache, 'foo')); - $this->assertTrue($this->isPruned($cache, 'qux')); - $cache->clear(); - } -} -class NotUnserializable implements \Serializable -{ - public function serialize() - { - return \serialize(123); - } - public function unserialize($ser) - { - throw new \Exception(__CLASS__); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Cache\IntegrationTests\SimpleCacheTest; +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +abstract class CacheTestCase extends \_PhpScoper5ea00cc67502b\Cache\IntegrationTests\SimpleCacheTest +{ + protected function setUp() + { + parent::setUp(); + if (!\array_key_exists('testPrune', $this->skippedTests) && !$this->createSimpleCache() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface) { + $this->skippedTests['testPrune'] = 'Not a pruneable cache pool.'; + } + } + public static function validKeys() + { + if (\defined('HHVM_VERSION')) { + return parent::validKeys(); + } + return \array_merge(parent::validKeys(), [["a\0b"]]); + } + public function testDefaultLifeTime() + { + if (isset($this->skippedTests[__FUNCTION__])) { + $this->markTestSkipped($this->skippedTests[__FUNCTION__]); + } + $cache = $this->createSimpleCache(2); + $cache->clear(); + $cache->set('key.dlt', 'value'); + \sleep(1); + $this->assertSame('value', $cache->get('key.dlt')); + \sleep(2); + $this->assertNull($cache->get('key.dlt')); + $cache->clear(); + } + public function testNotUnserializable() + { + if (isset($this->skippedTests[__FUNCTION__])) { + $this->markTestSkipped($this->skippedTests[__FUNCTION__]); + } + $cache = $this->createSimpleCache(); + $cache->clear(); + $cache->set('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\NotUnserializable()); + $this->assertNull($cache->get('foo')); + $cache->setMultiple(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\NotUnserializable()]); + foreach ($cache->getMultiple(['foo']) as $value) { + } + $this->assertNull($value); + $cache->clear(); + } + public function testPrune() + { + if (isset($this->skippedTests[__FUNCTION__])) { + $this->markTestSkipped($this->skippedTests[__FUNCTION__]); + } + if (!\method_exists($this, 'isPruned')) { + $this->fail('Test classes for pruneable caches must implement `isPruned($cache, $name)` method.'); + } + /** @var PruneableInterface|CacheInterface $cache */ + $cache = $this->createSimpleCache(); + $cache->clear(); + $cache->set('foo', 'foo-val', new \DateInterval('PT05S')); + $cache->set('bar', 'bar-val', new \DateInterval('PT10S')); + $cache->set('baz', 'baz-val', new \DateInterval('PT15S')); + $cache->set('qux', 'qux-val', new \DateInterval('PT20S')); + \sleep(30); + $cache->prune(); + $this->assertTrue($this->isPruned($cache, 'foo')); + $this->assertTrue($this->isPruned($cache, 'bar')); + $this->assertTrue($this->isPruned($cache, 'baz')); + $this->assertTrue($this->isPruned($cache, 'qux')); + $cache->set('foo', 'foo-val'); + $cache->set('bar', 'bar-val', new \DateInterval('PT20S')); + $cache->set('baz', 'baz-val', new \DateInterval('PT40S')); + $cache->set('qux', 'qux-val', new \DateInterval('PT80S')); + $cache->prune(); + $this->assertFalse($this->isPruned($cache, 'foo')); + $this->assertFalse($this->isPruned($cache, 'bar')); + $this->assertFalse($this->isPruned($cache, 'baz')); + $this->assertFalse($this->isPruned($cache, 'qux')); + \sleep(30); + $cache->prune(); + $this->assertFalse($this->isPruned($cache, 'foo')); + $this->assertTrue($this->isPruned($cache, 'bar')); + $this->assertFalse($this->isPruned($cache, 'baz')); + $this->assertFalse($this->isPruned($cache, 'qux')); + \sleep(30); + $cache->prune(); + $this->assertFalse($this->isPruned($cache, 'foo')); + $this->assertTrue($this->isPruned($cache, 'baz')); + $this->assertFalse($this->isPruned($cache, 'qux')); + \sleep(30); + $cache->prune(); + $this->assertFalse($this->isPruned($cache, 'foo')); + $this->assertTrue($this->isPruned($cache, 'qux')); + $cache->clear(); + } +} +class NotUnserializable implements \Serializable +{ + public function serialize() + { + return \serialize(123); + } + public function unserialize($ser) + { + throw new \Exception(__CLASS__); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/ChainCacheTest.php b/vendor/symfony/cache/Tests/Simple/ChainCacheTest.php index 701cc29ee..7ede2a286 100644 --- a/vendor/symfony/cache/Tests/Simple/ChainCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/ChainCacheTest.php @@ -1,78 +1,78 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject; -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache; -/** - * @group time-sensitive - */ -class ChainCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - public function createSimpleCache($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache([new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache($defaultLifetime), new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache('', $defaultLifetime)], $defaultLifetime); - } - public function testEmptyCachesException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('At least one cache must be specified.'); - new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache([]); - } - public function testInvalidCacheException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The class "stdClass" does not implement'); - new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache([new \stdClass()]); - } - public function testPrune() - { - if (isset($this->skippedTests[__FUNCTION__])) { - $this->markTestSkipped($this->skippedTests[__FUNCTION__]); - } - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache([$this->getPruneableMock(), $this->getNonPruneableMock(), $this->getPruneableMock()]); - $this->assertTrue($cache->prune()); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache([$this->getPruneableMock(), $this->getFailingPruneableMock(), $this->getPruneableMock()]); - $this->assertFalse($cache->prune()); - } - /** - * @return MockObject|PruneableCacheInterface - */ - private function getPruneableMock() - { - $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\PruneableCacheInterface::class)->getMock(); - $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\true); - return $pruneable; - } - /** - * @return MockObject|PruneableCacheInterface - */ - private function getFailingPruneableMock() - { - $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\PruneableCacheInterface::class)->getMock(); - $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\false); - return $pruneable; - } - /** - * @return MockObject|CacheInterface - */ - private function getNonPruneableMock() - { - return $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface::class)->getMock(); - } -} -interface PruneableCacheInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject; +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache; +/** + * @group time-sensitive + */ +class ChainCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + public function createSimpleCache($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache([new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ArrayCache($defaultLifetime), new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache('', $defaultLifetime)], $defaultLifetime); + } + public function testEmptyCachesException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('At least one cache must be specified.'); + new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache([]); + } + public function testInvalidCacheException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The class "stdClass" does not implement'); + new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache([new \stdClass()]); + } + public function testPrune() + { + if (isset($this->skippedTests[__FUNCTION__])) { + $this->markTestSkipped($this->skippedTests[__FUNCTION__]); + } + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache([$this->getPruneableMock(), $this->getNonPruneableMock(), $this->getPruneableMock()]); + $this->assertTrue($cache->prune()); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\ChainCache([$this->getPruneableMock(), $this->getFailingPruneableMock(), $this->getPruneableMock()]); + $this->assertFalse($cache->prune()); + } + /** + * @return MockObject|PruneableCacheInterface + */ + private function getPruneableMock() + { + $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\PruneableCacheInterface::class)->getMock(); + $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\true); + return $pruneable; + } + /** + * @return MockObject|PruneableCacheInterface + */ + private function getFailingPruneableMock() + { + $pruneable = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\PruneableCacheInterface::class)->getMock(); + $pruneable->expects($this->atLeastOnce())->method('prune')->willReturn(\false); + return $pruneable; + } + /** + * @return MockObject|CacheInterface + */ + private function getNonPruneableMock() + { + return $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface::class)->getMock(); + } +} +interface PruneableCacheInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface, \_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface +{ +} diff --git a/vendor/symfony/cache/Tests/Simple/DoctrineCacheTest.php b/vendor/symfony/cache/Tests/Simple/DoctrineCacheTest.php index 515c84ec7..7b64df3f5 100644 --- a/vendor/symfony/cache/Tests/Simple/DoctrineCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/DoctrineCacheTest.php @@ -1,25 +1,25 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\DoctrineCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ArrayCache; -/** - * @group time-sensitive - */ -class DoctrineCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - protected $skippedTests = ['testObjectDoesNotChangeInCache' => 'ArrayCache does not use serialize/unserialize', 'testNotUnserializable' => 'ArrayCache does not use serialize/unserialize']; - public function createSimpleCache($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\DoctrineCache(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ArrayCache($defaultLifetime), '', $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\DoctrineCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ArrayCache; +/** + * @group time-sensitive + */ +class DoctrineCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + protected $skippedTests = ['testObjectDoesNotChangeInCache' => 'ArrayCache does not use serialize/unserialize', 'testNotUnserializable' => 'ArrayCache does not use serialize/unserialize']; + public function createSimpleCache($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\DoctrineCache(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Fixtures\ArrayCache($defaultLifetime), '', $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/FilesystemCacheTest.php b/vendor/symfony/cache/Tests/Simple/FilesystemCacheTest.php index 7eb4d3c4d..a4947767b 100644 --- a/vendor/symfony/cache/Tests/Simple/FilesystemCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/FilesystemCacheTest.php @@ -1,30 +1,30 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache; -/** - * @group time-sensitive - */ -class FilesystemCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - public function createSimpleCache($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache('', $defaultLifetime); - } - protected function isPruned(\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $cache, $name) - { - $getFileMethod = (new \ReflectionObject($cache))->getMethod('getFile'); - $getFileMethod->setAccessible(\true); - return !\file_exists($getFileMethod->invoke($cache, $name)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache; +/** + * @group time-sensitive + */ +class FilesystemCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + public function createSimpleCache($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache('', $defaultLifetime); + } + protected function isPruned(\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $cache, $name) + { + $getFileMethod = (new \ReflectionObject($cache))->getMethod('getFile'); + $getFileMethod->setAccessible(\true); + return !\file_exists($getFileMethod->invoke($cache, $name)); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/MemcachedCacheTest.php b/vendor/symfony/cache/Tests/Simple/MemcachedCacheTest.php index f72bd7a6d..e5fc40fcb 100644 --- a/vendor/symfony/cache/Tests/Simple/MemcachedCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/MemcachedCacheTest.php @@ -1,111 +1,111 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache; -class MemcachedCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - protected $skippedTests = ['testSetTtl' => 'Testing expiration slows down the test suite', 'testSetMultipleTtl' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; - protected static $client; - public static function setUpBeforeClass() - { - if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::isSupported()) { - self::markTestSkipped('Extension memcached >=2.2.0 required.'); - } - self::$client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('memcached://' . \getenv('MEMCACHED_HOST')); - self::$client->get('foo'); - $code = self::$client->getResultCode(); - if (\_PhpScoper5ea00cc67502b\Memcached::RES_SUCCESS !== $code && \_PhpScoper5ea00cc67502b\Memcached::RES_NOTFOUND !== $code) { - self::markTestSkipped('Memcached error: ' . \strtolower(self::$client->getResultMessage())); - } - } - public function createSimpleCache($defaultLifetime = 0) - { - $client = $defaultLifetime ? \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('memcached://' . \getenv('MEMCACHED_HOST'), ['binary_protocol' => \false]) : self::$client; - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache($client, \str_replace('\\', '.', __CLASS__), $defaultLifetime); - } - public function testCreatePersistentConnectionShouldNotDupServerList() - { - $instance = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection('memcached://' . \getenv('MEMCACHED_HOST'), ['persistent_id' => 'persistent']); - $this->assertCount(1, $instance->getServerList()); - $instance = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection('memcached://' . \getenv('MEMCACHED_HOST'), ['persistent_id' => 'persistent']); - $this->assertCount(1, $instance->getServerList()); - } - public function testOptions() - { - $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([], ['libketama_compatible' => \false, 'distribution' => 'modula', 'compression' => \true, 'serializer' => 'php', 'hash' => 'md5']); - $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_PHP, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_SERIALIZER)); - $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::HASH_MD5, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_HASH)); - $this->assertTrue($client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_COMPRESSION)); - $this->assertSame(0, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE)); - $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::DISTRIBUTION_MODULA, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_DISTRIBUTION)); - } - /** - * @dataProvider provideBadOptions - */ - public function testBadOptions($name, $value) - { - $this->expectException('ErrorException'); - $this->expectExceptionMessage('constant(): Couldn\'t find constant Memcached::'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([], [$name => $value]); - } - public function provideBadOptions() - { - return [['foo', 'bar'], ['hash', 'zyx'], ['serializer', 'zyx'], ['distribution', 'zyx']]; - } - public function testDefaultOptions() - { - $this->assertTrue(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::isSupported()); - $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([]); - $this->assertTrue($client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_COMPRESSION)); - $this->assertSame(1, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_BINARY_PROTOCOL)); - $this->assertSame(1, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE)); - } - public function testOptionSerializer() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\CacheException'); - $this->expectExceptionMessage('MemcachedAdapter: "serializer" option must be "php" or "igbinary".'); - if (!\_PhpScoper5ea00cc67502b\Memcached::HAVE_JSON) { - $this->markTestSkipped('Memcached::HAVE_JSON required'); - } - new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([], ['serializer' => 'json'])); - } - /** - * @dataProvider provideServersSetting - */ - public function testServersSetting($dsn, $host, $port) - { - $client1 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection($dsn); - $client2 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([$dsn]); - $client3 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([[$host, $port]]); - $expect = ['host' => $host, 'port' => $port]; - $f = function ($s) { - return ['host' => $s['host'], 'port' => $s['port']]; - }; - $this->assertSame([$expect], \array_map($f, $client1->getServerList())); - $this->assertSame([$expect], \array_map($f, $client2->getServerList())); - $this->assertSame([$expect], \array_map($f, $client3->getServerList())); - } - public function provideServersSetting() - { - (yield ['memcached://127.0.0.1/50', '127.0.0.1', 11211]); - (yield ['memcached://localhost:11222?weight=25', 'localhost', 11222]); - if (\filter_var(\ini_get('memcached.use_sasl'), \FILTER_VALIDATE_BOOLEAN)) { - (yield ['memcached://user:password@127.0.0.1?weight=50', '127.0.0.1', 11211]); - } - (yield ['memcached:///var/run/memcached.sock?weight=25', '/var/run/memcached.sock', 0]); - (yield ['memcached:///var/local/run/memcached.socket?weight=25', '/var/local/run/memcached.socket', 0]); - if (\filter_var(\ini_get('memcached.use_sasl'), \FILTER_VALIDATE_BOOLEAN)) { - (yield ['memcached://user:password@/var/local/run/memcached.socket?weight=25', '/var/local/run/memcached.socket', 0]); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache; +class MemcachedCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + protected $skippedTests = ['testSetTtl' => 'Testing expiration slows down the test suite', 'testSetMultipleTtl' => 'Testing expiration slows down the test suite', 'testDefaultLifeTime' => 'Testing expiration slows down the test suite']; + protected static $client; + public static function setUpBeforeClass() + { + if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::isSupported()) { + self::markTestSkipped('Extension memcached >=2.2.0 required.'); + } + self::$client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('memcached://' . \getenv('MEMCACHED_HOST')); + self::$client->get('foo'); + $code = self::$client->getResultCode(); + if (\_PhpScoper5ea00cc67502b\Memcached::RES_SUCCESS !== $code && \_PhpScoper5ea00cc67502b\Memcached::RES_NOTFOUND !== $code) { + self::markTestSkipped('Memcached error: ' . \strtolower(self::$client->getResultMessage())); + } + } + public function createSimpleCache($defaultLifetime = 0) + { + $client = $defaultLifetime ? \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('memcached://' . \getenv('MEMCACHED_HOST'), ['binary_protocol' => \false]) : self::$client; + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache($client, \str_replace('\\', '.', __CLASS__), $defaultLifetime); + } + public function testCreatePersistentConnectionShouldNotDupServerList() + { + $instance = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection('memcached://' . \getenv('MEMCACHED_HOST'), ['persistent_id' => 'persistent']); + $this->assertCount(1, $instance->getServerList()); + $instance = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection('memcached://' . \getenv('MEMCACHED_HOST'), ['persistent_id' => 'persistent']); + $this->assertCount(1, $instance->getServerList()); + } + public function testOptions() + { + $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([], ['libketama_compatible' => \false, 'distribution' => 'modula', 'compression' => \true, 'serializer' => 'php', 'hash' => 'md5']); + $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_PHP, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_SERIALIZER)); + $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::HASH_MD5, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_HASH)); + $this->assertTrue($client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_COMPRESSION)); + $this->assertSame(0, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE)); + $this->assertSame(\_PhpScoper5ea00cc67502b\Memcached::DISTRIBUTION_MODULA, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_DISTRIBUTION)); + } + /** + * @dataProvider provideBadOptions + */ + public function testBadOptions($name, $value) + { + $this->expectException('ErrorException'); + $this->expectExceptionMessage('constant(): Couldn\'t find constant Memcached::'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([], [$name => $value]); + } + public function provideBadOptions() + { + return [['foo', 'bar'], ['hash', 'zyx'], ['serializer', 'zyx'], ['distribution', 'zyx']]; + } + public function testDefaultOptions() + { + $this->assertTrue(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::isSupported()); + $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([]); + $this->assertTrue($client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_COMPRESSION)); + $this->assertSame(1, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_BINARY_PROTOCOL)); + $this->assertSame(1, $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE)); + } + public function testOptionSerializer() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\CacheException'); + $this->expectExceptionMessage('MemcachedAdapter: "serializer" option must be "php" or "igbinary".'); + if (!\_PhpScoper5ea00cc67502b\Memcached::HAVE_JSON) { + $this->markTestSkipped('Memcached::HAVE_JSON required'); + } + new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache(\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([], ['serializer' => 'json'])); + } + /** + * @dataProvider provideServersSetting + */ + public function testServersSetting($dsn, $host, $port) + { + $client1 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection($dsn); + $client2 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([$dsn]); + $client3 = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache::createConnection([[$host, $port]]); + $expect = ['host' => $host, 'port' => $port]; + $f = function ($s) { + return ['host' => $s['host'], 'port' => $s['port']]; + }; + $this->assertSame([$expect], \array_map($f, $client1->getServerList())); + $this->assertSame([$expect], \array_map($f, $client2->getServerList())); + $this->assertSame([$expect], \array_map($f, $client3->getServerList())); + } + public function provideServersSetting() + { + (yield ['memcached://127.0.0.1/50', '127.0.0.1', 11211]); + (yield ['memcached://localhost:11222?weight=25', 'localhost', 11222]); + if (\filter_var(\ini_get('memcached.use_sasl'), \FILTER_VALIDATE_BOOLEAN)) { + (yield ['memcached://user:password@127.0.0.1?weight=50', '127.0.0.1', 11211]); + } + (yield ['memcached:///var/run/memcached.sock?weight=25', '/var/run/memcached.sock', 0]); + (yield ['memcached:///var/local/run/memcached.socket?weight=25', '/var/local/run/memcached.socket', 0]); + if (\filter_var(\ini_get('memcached.use_sasl'), \FILTER_VALIDATE_BOOLEAN)) { + (yield ['memcached://user:password@/var/local/run/memcached.socket?weight=25', '/var/local/run/memcached.socket', 0]); + } + } +} diff --git a/vendor/symfony/cache/Tests/Simple/MemcachedCacheTextModeTest.php b/vendor/symfony/cache/Tests/Simple/MemcachedCacheTextModeTest.php index 3305e4e32..d5eb7f735 100644 --- a/vendor/symfony/cache/Tests/Simple/MemcachedCacheTextModeTest.php +++ b/vendor/symfony/cache/Tests/Simple/MemcachedCacheTextModeTest.php @@ -1,22 +1,22 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache; -class MemcachedCacheTextModeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\MemcachedCacheTest -{ - public function createSimpleCache($defaultLifetime = 0) - { - $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('memcached://' . \getenv('MEMCACHED_HOST'), ['binary_protocol' => \false]); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache($client, \str_replace('\\', '.', __CLASS__), $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache; +class MemcachedCacheTextModeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\MemcachedCacheTest +{ + public function createSimpleCache($defaultLifetime = 0) + { + $client = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\AbstractAdapter::createConnection('memcached://' . \getenv('MEMCACHED_HOST'), ['binary_protocol' => \false]); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\MemcachedCache($client, \str_replace('\\', '.', __CLASS__), $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/NullCacheTest.php b/vendor/symfony/cache/Tests/Simple/NullCacheTest.php index 22365de83..8b41d82e2 100644 --- a/vendor/symfony/cache/Tests/Simple/NullCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/NullCacheTest.php @@ -1,77 +1,77 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache; -/** - * @group time-sensitive - */ -class NullCacheTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function createCachePool() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache(); - } - public function testGetItem() - { - $cache = $this->createCachePool(); - $this->assertNull($cache->get('key')); - } - public function testHas() - { - $this->assertFalse($this->createCachePool()->has('key')); - } - public function testGetMultiple() - { - $cache = $this->createCachePool(); - $keys = ['foo', 'bar', 'baz', 'biz']; - $default = new \stdClass(); - $items = $cache->getMultiple($keys, $default); - $count = 0; - foreach ($items as $key => $item) { - $this->assertContains($key, $keys, 'Cache key can not change.'); - $this->assertSame($default, $item); - // Remove $key for $keys - foreach ($keys as $k => $v) { - if ($v === $key) { - unset($keys[$k]); - } - } - ++$count; - } - $this->assertSame(4, $count); - } - public function testClear() - { - $this->assertTrue($this->createCachePool()->clear()); - } - public function testDelete() - { - $this->assertTrue($this->createCachePool()->delete('key')); - } - public function testDeleteMultiple() - { - $this->assertTrue($this->createCachePool()->deleteMultiple(['key', 'foo', 'bar'])); - } - public function testSet() - { - $cache = $this->createCachePool(); - $this->assertFalse($cache->set('key', 'val')); - $this->assertNull($cache->get('key')); - } - public function testSetMultiple() - { - $cache = $this->createCachePool(); - $this->assertFalse($cache->setMultiple(['key' => 'val'])); - $this->assertNull($cache->get('key')); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache; +/** + * @group time-sensitive + */ +class NullCacheTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function createCachePool() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache(); + } + public function testGetItem() + { + $cache = $this->createCachePool(); + $this->assertNull($cache->get('key')); + } + public function testHas() + { + $this->assertFalse($this->createCachePool()->has('key')); + } + public function testGetMultiple() + { + $cache = $this->createCachePool(); + $keys = ['foo', 'bar', 'baz', 'biz']; + $default = new \stdClass(); + $items = $cache->getMultiple($keys, $default); + $count = 0; + foreach ($items as $key => $item) { + $this->assertContains($key, $keys, 'Cache key can not change.'); + $this->assertSame($default, $item); + // Remove $key for $keys + foreach ($keys as $k => $v) { + if ($v === $key) { + unset($keys[$k]); + } + } + ++$count; + } + $this->assertSame(4, $count); + } + public function testClear() + { + $this->assertTrue($this->createCachePool()->clear()); + } + public function testDelete() + { + $this->assertTrue($this->createCachePool()->delete('key')); + } + public function testDeleteMultiple() + { + $this->assertTrue($this->createCachePool()->deleteMultiple(['key', 'foo', 'bar'])); + } + public function testSet() + { + $cache = $this->createCachePool(); + $this->assertFalse($cache->set('key', 'val')); + $this->assertNull($cache->get('key')); + } + public function testSetMultiple() + { + $cache = $this->createCachePool(); + $this->assertFalse($cache->setMultiple(['key' => 'val'])); + $this->assertNull($cache->get('key')); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/PdoCacheTest.php b/vendor/symfony/cache/Tests/Simple/PdoCacheTest.php index 1bebfd10c..3beba6fc1 100644 --- a/vendor/symfony/cache/Tests/Simple/PdoCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/PdoCacheTest.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Traits\PdoPruneableTrait; -/** - * @group time-sensitive - */ -class PdoCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - use PdoPruneableTrait; - protected static $dbFile; - public static function setUpBeforeClass() - { - if (!\extension_loaded('pdo_sqlite')) { - self::markTestSkipped('Extension pdo_sqlite required.'); - } - self::$dbFile = \tempnam(\sys_get_temp_dir(), 'sf_sqlite_cache'); - $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache('sqlite:' . self::$dbFile); - $pool->createTable(); - } - public static function tearDownAfterClass() - { - @\unlink(self::$dbFile); - } - public function createSimpleCache($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache('sqlite:' . self::$dbFile, 'ns', $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Traits\PdoPruneableTrait; +/** + * @group time-sensitive + */ +class PdoCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + use PdoPruneableTrait; + protected static $dbFile; + public static function setUpBeforeClass() + { + if (!\extension_loaded('pdo_sqlite')) { + self::markTestSkipped('Extension pdo_sqlite required.'); + } + self::$dbFile = \tempnam(\sys_get_temp_dir(), 'sf_sqlite_cache'); + $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache('sqlite:' . self::$dbFile); + $pool->createTable(); + } + public static function tearDownAfterClass() + { + @\unlink(self::$dbFile); + } + public function createSimpleCache($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache('sqlite:' . self::$dbFile, 'ns', $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/PdoDbalCacheTest.php b/vendor/symfony/cache/Tests/Simple/PdoDbalCacheTest.php index b80bb6d4b..e15e68d56 100644 --- a/vendor/symfony/cache/Tests/Simple/PdoDbalCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/PdoDbalCacheTest.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Traits\PdoPruneableTrait; -/** - * @group time-sensitive - */ -class PdoDbalCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - use PdoPruneableTrait; - protected static $dbFile; - public static function setUpBeforeClass() - { - if (!\extension_loaded('pdo_sqlite')) { - self::markTestSkipped('Extension pdo_sqlite required.'); - } - self::$dbFile = \tempnam(\sys_get_temp_dir(), 'sf_sqlite_cache'); - $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache(\_PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager::getConnection(['driver' => 'pdo_sqlite', 'path' => self::$dbFile])); - $pool->createTable(); - } - public static function tearDownAfterClass() - { - @\unlink(self::$dbFile); - } - public function createSimpleCache($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache(\_PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager::getConnection(['driver' => 'pdo_sqlite', 'path' => self::$dbFile]), '', $defaultLifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Traits\PdoPruneableTrait; +/** + * @group time-sensitive + */ +class PdoDbalCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + use PdoPruneableTrait; + protected static $dbFile; + public static function setUpBeforeClass() + { + if (!\extension_loaded('pdo_sqlite')) { + self::markTestSkipped('Extension pdo_sqlite required.'); + } + self::$dbFile = \tempnam(\sys_get_temp_dir(), 'sf_sqlite_cache'); + $pool = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache(\_PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager::getConnection(['driver' => 'pdo_sqlite', 'path' => self::$dbFile])); + $pool->createTable(); + } + public static function tearDownAfterClass() + { + @\unlink(self::$dbFile); + } + public function createSimpleCache($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PdoCache(\_PhpScoper5ea00cc67502b\Doctrine\DBAL\DriverManager::getConnection(['driver' => 'pdo_sqlite', 'path' => self::$dbFile]), '', $defaultLifetime); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/PhpArrayCacheTest.php b/vendor/symfony/cache/Tests/Simple/PhpArrayCacheTest.php index 4cecea6d5..92ed3b41e 100644 --- a/vendor/symfony/cache/Tests/Simple/PhpArrayCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/PhpArrayCacheTest.php @@ -1,85 +1,85 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest; -/** - * @group time-sensitive - */ -class PhpArrayCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - protected $skippedTests = ['testBasicUsageWithLongKey' => 'PhpArrayCache does no writes', 'testDelete' => 'PhpArrayCache does no writes', 'testDeleteMultiple' => 'PhpArrayCache does no writes', 'testDeleteMultipleGenerator' => 'PhpArrayCache does no writes', 'testSetTtl' => 'PhpArrayCache does no expiration', 'testSetMultipleTtl' => 'PhpArrayCache does no expiration', 'testSetExpiredTtl' => 'PhpArrayCache does no expiration', 'testSetMultipleExpiredTtl' => 'PhpArrayCache does no expiration', 'testGetInvalidKeys' => 'PhpArrayCache does no validation', 'testGetMultipleInvalidKeys' => 'PhpArrayCache does no validation', 'testSetInvalidKeys' => 'PhpArrayCache does no validation', 'testDeleteInvalidKeys' => 'PhpArrayCache does no validation', 'testDeleteMultipleInvalidKeys' => 'PhpArrayCache does no validation', 'testSetInvalidTtl' => 'PhpArrayCache does no validation', 'testSetMultipleInvalidKeys' => 'PhpArrayCache does no validation', 'testSetMultipleInvalidTtl' => 'PhpArrayCache does no validation', 'testHasInvalidKeys' => 'PhpArrayCache does no validation', 'testSetValidData' => 'PhpArrayCache does no validation', 'testDefaultLifeTime' => 'PhpArrayCache does not allow configuring a default lifetime.', 'testPrune' => 'PhpArrayCache just proxies']; - protected static $file; - public static function setUpBeforeClass() - { - self::$file = \sys_get_temp_dir() . '/symfony-cache/php-array-adapter-test.php'; - } - protected function tearDown() - { - $this->createSimpleCache()->clear(); - if (\file_exists(\sys_get_temp_dir() . '/symfony-cache')) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); - } - } - public function createSimpleCache() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\PhpArrayCacheWrapper(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache()); - } - public function testStore() - { - $arrayWithRefs = []; - $arrayWithRefs[0] = 123; - $arrayWithRefs[1] =& $arrayWithRefs[0]; - $object = (object) ['foo' => 'bar', 'foo2' => 'bar2']; - $expected = ['null' => null, 'serializedString' => \serialize($object), 'arrayWithRefs' => $arrayWithRefs, 'object' => $object, 'arrayWithObject' => ['bar' => $object]]; - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache()); - $cache->warmUp($expected); - foreach ($expected as $key => $value) { - $this->assertSame(\serialize($value), \serialize($cache->get($key)), 'Warm up should create a PHP file that OPCache can load in memory'); - } - } - public function testStoredFile() - { - $expected = ['integer' => 42, 'float' => 42.42, 'boolean' => \true, 'array_simple' => ['foo', 'bar'], 'array_associative' => ['foo' => 'bar', 'foo2' => 'bar2']]; - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache()); - $cache->warmUp($expected); - $values = eval(\substr(\file_get_contents(self::$file), 6)); - $this->assertSame($expected, $values, 'Warm up should create a PHP file that OPCache can load in memory'); - } -} -class PhpArrayCacheWrapper extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache -{ - public function set($key, $value, $ttl = null) - { - \call_user_func(\Closure::bind(function () use($key, $value) { - $this->values[$key] = $value; - $this->warmUp($this->values); - $this->values = eval(\substr(\file_get_contents($this->file), 6)); - }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache::class)); - return \true; - } - public function setMultiple($values, $ttl = null) - { - if (!\is_array($values) && !$values instanceof \Traversable) { - return parent::setMultiple($values, $ttl); - } - \call_user_func(\Closure::bind(function () use($values) { - foreach ($values as $key => $value) { - $this->values[$key] = $value; - } - $this->warmUp($this->values); - $this->values = eval(\substr(\file_get_contents($this->file), 6)); - }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache::class)); - return \true; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest; +/** + * @group time-sensitive + */ +class PhpArrayCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + protected $skippedTests = ['testBasicUsageWithLongKey' => 'PhpArrayCache does no writes', 'testDelete' => 'PhpArrayCache does no writes', 'testDeleteMultiple' => 'PhpArrayCache does no writes', 'testDeleteMultipleGenerator' => 'PhpArrayCache does no writes', 'testSetTtl' => 'PhpArrayCache does no expiration', 'testSetMultipleTtl' => 'PhpArrayCache does no expiration', 'testSetExpiredTtl' => 'PhpArrayCache does no expiration', 'testSetMultipleExpiredTtl' => 'PhpArrayCache does no expiration', 'testGetInvalidKeys' => 'PhpArrayCache does no validation', 'testGetMultipleInvalidKeys' => 'PhpArrayCache does no validation', 'testSetInvalidKeys' => 'PhpArrayCache does no validation', 'testDeleteInvalidKeys' => 'PhpArrayCache does no validation', 'testDeleteMultipleInvalidKeys' => 'PhpArrayCache does no validation', 'testSetInvalidTtl' => 'PhpArrayCache does no validation', 'testSetMultipleInvalidKeys' => 'PhpArrayCache does no validation', 'testSetMultipleInvalidTtl' => 'PhpArrayCache does no validation', 'testHasInvalidKeys' => 'PhpArrayCache does no validation', 'testSetValidData' => 'PhpArrayCache does no validation', 'testDefaultLifeTime' => 'PhpArrayCache does not allow configuring a default lifetime.', 'testPrune' => 'PhpArrayCache just proxies']; + protected static $file; + public static function setUpBeforeClass() + { + self::$file = \sys_get_temp_dir() . '/symfony-cache/php-array-adapter-test.php'; + } + protected function tearDown() + { + $this->createSimpleCache()->clear(); + if (\file_exists(\sys_get_temp_dir() . '/symfony-cache')) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); + } + } + public function createSimpleCache() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\PhpArrayCacheWrapper(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache()); + } + public function testStore() + { + $arrayWithRefs = []; + $arrayWithRefs[0] = 123; + $arrayWithRefs[1] =& $arrayWithRefs[0]; + $object = (object) ['foo' => 'bar', 'foo2' => 'bar2']; + $expected = ['null' => null, 'serializedString' => \serialize($object), 'arrayWithRefs' => $arrayWithRefs, 'object' => $object, 'arrayWithObject' => ['bar' => $object]]; + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache()); + $cache->warmUp($expected); + foreach ($expected as $key => $value) { + $this->assertSame(\serialize($value), \serialize($cache->get($key)), 'Warm up should create a PHP file that OPCache can load in memory'); + } + } + public function testStoredFile() + { + $expected = ['integer' => 42, 'float' => 42.42, 'boolean' => \true, 'array_simple' => ['foo', 'bar'], 'array_associative' => ['foo' => 'bar', 'foo2' => 'bar2']]; + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\NullCache()); + $cache->warmUp($expected); + $values = eval(\substr(\file_get_contents(self::$file), 6)); + $this->assertSame($expected, $values, 'Warm up should create a PHP file that OPCache can load in memory'); + } +} +class PhpArrayCacheWrapper extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache +{ + public function set($key, $value, $ttl = null) + { + \call_user_func(\Closure::bind(function () use($key, $value) { + $this->values[$key] = $value; + $this->warmUp($this->values); + $this->values = eval(\substr(\file_get_contents($this->file), 6)); + }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache::class)); + return \true; + } + public function setMultiple($values, $ttl = null) + { + if (!\is_array($values) && !$values instanceof \Traversable) { + return parent::setMultiple($values, $ttl); + } + \call_user_func(\Closure::bind(function () use($values) { + foreach ($values as $key => $value) { + $this->values[$key] = $value; + } + $this->warmUp($this->values); + $this->values = eval(\substr(\file_get_contents($this->file), 6)); + }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache::class)); + return \true; + } +} diff --git a/vendor/symfony/cache/Tests/Simple/PhpArrayCacheWithFallbackTest.php b/vendor/symfony/cache/Tests/Simple/PhpArrayCacheWithFallbackTest.php index 487c6b9b4..289d2f636 100644 --- a/vendor/symfony/cache/Tests/Simple/PhpArrayCacheWithFallbackTest.php +++ b/vendor/symfony/cache/Tests/Simple/PhpArrayCacheWithFallbackTest.php @@ -1,50 +1,50 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest; -/** - * @group time-sensitive - */ -class PhpArrayCacheWithFallbackTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - protected $skippedTests = [ - 'testGetInvalidKeys' => 'PhpArrayCache does no validation', - 'testGetMultipleInvalidKeys' => 'PhpArrayCache does no validation', - 'testDeleteInvalidKeys' => 'PhpArrayCache does no validation', - 'testDeleteMultipleInvalidKeys' => 'PhpArrayCache does no validation', - //'testSetValidData' => 'PhpArrayCache does no validation', - 'testSetInvalidKeys' => 'PhpArrayCache does no validation', - 'testSetInvalidTtl' => 'PhpArrayCache does no validation', - 'testSetMultipleInvalidKeys' => 'PhpArrayCache does no validation', - 'testSetMultipleInvalidTtl' => 'PhpArrayCache does no validation', - 'testHasInvalidKeys' => 'PhpArrayCache does no validation', - 'testPrune' => 'PhpArrayCache just proxies', - ]; - protected static $file; - public static function setUpBeforeClass() - { - self::$file = \sys_get_temp_dir() . '/symfony-cache/php-array-adapter-test.php'; - } - protected function tearDown() - { - $this->createSimpleCache()->clear(); - if (\file_exists(\sys_get_temp_dir() . '/symfony-cache')) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); - } - } - public function createSimpleCache($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache('php-array-fallback', $defaultLifetime)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest; +/** + * @group time-sensitive + */ +class PhpArrayCacheWithFallbackTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + protected $skippedTests = [ + 'testGetInvalidKeys' => 'PhpArrayCache does no validation', + 'testGetMultipleInvalidKeys' => 'PhpArrayCache does no validation', + 'testDeleteInvalidKeys' => 'PhpArrayCache does no validation', + 'testDeleteMultipleInvalidKeys' => 'PhpArrayCache does no validation', + //'testSetValidData' => 'PhpArrayCache does no validation', + 'testSetInvalidKeys' => 'PhpArrayCache does no validation', + 'testSetInvalidTtl' => 'PhpArrayCache does no validation', + 'testSetMultipleInvalidKeys' => 'PhpArrayCache does no validation', + 'testSetMultipleInvalidTtl' => 'PhpArrayCache does no validation', + 'testHasInvalidKeys' => 'PhpArrayCache does no validation', + 'testPrune' => 'PhpArrayCache just proxies', + ]; + protected static $file; + public static function setUpBeforeClass() + { + self::$file = \sys_get_temp_dir() . '/symfony-cache/php-array-adapter-test.php'; + } + protected function tearDown() + { + $this->createSimpleCache()->clear(); + if (\file_exists(\sys_get_temp_dir() . '/symfony-cache')) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Adapter\FilesystemAdapterTest::rmdir(\sys_get_temp_dir() . '/symfony-cache'); + } + } + public function createSimpleCache($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpArrayCache(self::$file, new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache('php-array-fallback', $defaultLifetime)); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/PhpFilesCacheTest.php b/vendor/symfony/cache/Tests/Simple/PhpFilesCacheTest.php index 5d5ca4afd..fd0212799 100644 --- a/vendor/symfony/cache/Tests/Simple/PhpFilesCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/PhpFilesCacheTest.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpFilesCache; -/** - * @group time-sensitive - */ -class PhpFilesCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - protected $skippedTests = ['testDefaultLifeTime' => 'PhpFilesCache does not allow configuring a default lifetime.']; - public function createSimpleCache() - { - if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpFilesCache::isSupported()) { - $this->markTestSkipped('OPcache extension is not enabled.'); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpFilesCache('sf-cache'); - } - protected function isPruned(\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $cache, $name) - { - $getFileMethod = (new \ReflectionObject($cache))->getMethod('getFile'); - $getFileMethod->setAccessible(\true); - return !\file_exists($getFileMethod->invoke($cache, $name)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpFilesCache; +/** + * @group time-sensitive + */ +class PhpFilesCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + protected $skippedTests = ['testDefaultLifeTime' => 'PhpFilesCache does not allow configuring a default lifetime.']; + public function createSimpleCache() + { + if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpFilesCache::isSupported()) { + $this->markTestSkipped('OPcache extension is not enabled.'); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\PhpFilesCache('sf-cache'); + } + protected function isPruned(\_PhpScoper5ea00cc67502b\Psr\SimpleCache\CacheInterface $cache, $name) + { + $getFileMethod = (new \ReflectionObject($cache))->getMethod('getFile'); + $getFileMethod->setAccessible(\true); + return !\file_exists($getFileMethod->invoke($cache, $name)); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/Psr6CacheTest.php b/vendor/symfony/cache/Tests/Simple/Psr6CacheTest.php index 981331201..72d63494a 100644 --- a/vendor/symfony/cache/Tests/Simple/Psr6CacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/Psr6CacheTest.php @@ -1,25 +1,25 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\Psr6Cache; -/** - * @group time-sensitive - */ -class Psr6CacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - protected $skippedTests = ['testPrune' => 'Psr6Cache just proxies']; - public function createSimpleCache($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\Psr6Cache(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', $defaultLifetime)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\Psr6Cache; +/** + * @group time-sensitive + */ +class Psr6CacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + protected $skippedTests = ['testPrune' => 'Psr6Cache just proxies']; + public function createSimpleCache($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\Psr6Cache(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\FilesystemAdapter('', $defaultLifetime)); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/RedisArrayCacheTest.php b/vendor/symfony/cache/Tests/Simple/RedisArrayCacheTest.php index e77b592a9..4c0544bef 100644 --- a/vendor/symfony/cache/Tests/Simple/RedisArrayCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/RedisArrayCacheTest.php @@ -1,23 +1,23 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -class RedisArrayCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\AbstractRedisCacheTest -{ - public static function setUpBeforeClass() - { - parent::setupBeforeClass(); - if (!\class_exists('_PhpScoper5ea00cc67502b\\RedisArray')) { - self::markTestSkipped('The RedisArray class is required.'); - } - self::$redis = new \_PhpScoper5ea00cc67502b\RedisArray([\getenv('REDIS_HOST')], ['lazy_connect' => \true]); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +class RedisArrayCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\AbstractRedisCacheTest +{ + public static function setUpBeforeClass() + { + parent::setupBeforeClass(); + if (!\class_exists('_PhpScoper5ea00cc67502b\\RedisArray')) { + self::markTestSkipped('The RedisArray class is required.'); + } + self::$redis = new \_PhpScoper5ea00cc67502b\RedisArray([\getenv('REDIS_HOST')], ['lazy_connect' => \true]); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/RedisCacheTest.php b/vendor/symfony/cache/Tests/Simple/RedisCacheTest.php index bdb18d0d3..27ccc7f3d 100644 --- a/vendor/symfony/cache/Tests/Simple/RedisCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/RedisCacheTest.php @@ -1,63 +1,63 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache; -class RedisCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\AbstractRedisCacheTest -{ - public static function setUpBeforeClass() - { - parent::setupBeforeClass(); - self::$redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . \getenv('REDIS_HOST')); - } - public function testCreateConnection() - { - $redisHost = \getenv('REDIS_HOST'); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . $redisHost); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Redis::class, $redis); - $this->assertTrue($redis->isConnected()); - $this->assertSame(0, $redis->getDbNum()); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . $redisHost . '/2'); - $this->assertSame(2, $redis->getDbNum()); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . $redisHost, ['timeout' => 3]); - $this->assertEquals(3, $redis->getTimeout()); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . $redisHost . '?timeout=4'); - $this->assertEquals(4, $redis->getTimeout()); - $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . $redisHost, ['read_timeout' => 5]); - $this->assertEquals(5, $redis->getReadTimeout()); - } - /** - * @dataProvider provideFailedCreateConnection - */ - public function testFailedCreateConnection($dsn) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Redis connection failed'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection($dsn); - } - public function provideFailedCreateConnection() - { - return [['redis://localhost:1234'], ['redis://foo@localhost'], ['redis://localhost/123']]; - } - /** - * @dataProvider provideInvalidCreateConnection - */ - public function testInvalidCreateConnection($dsn) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Invalid Redis DSN'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection($dsn); - } - public function provideInvalidCreateConnection() - { - return [['foo://localhost'], ['redis://']]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache; +class RedisCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\AbstractRedisCacheTest +{ + public static function setUpBeforeClass() + { + parent::setupBeforeClass(); + self::$redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . \getenv('REDIS_HOST')); + } + public function testCreateConnection() + { + $redisHost = \getenv('REDIS_HOST'); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . $redisHost); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Redis::class, $redis); + $this->assertTrue($redis->isConnected()); + $this->assertSame(0, $redis->getDbNum()); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . $redisHost . '/2'); + $this->assertSame(2, $redis->getDbNum()); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . $redisHost, ['timeout' => 3]); + $this->assertEquals(3, $redis->getTimeout()); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . $redisHost . '?timeout=4'); + $this->assertEquals(4, $redis->getTimeout()); + $redis = \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection('redis://' . $redisHost, ['read_timeout' => 5]); + $this->assertEquals(5, $redis->getReadTimeout()); + } + /** + * @dataProvider provideFailedCreateConnection + */ + public function testFailedCreateConnection($dsn) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Redis connection failed'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection($dsn); + } + public function provideFailedCreateConnection() + { + return [['redis://localhost:1234'], ['redis://foo@localhost'], ['redis://localhost/123']]; + } + /** + * @dataProvider provideInvalidCreateConnection + */ + public function testInvalidCreateConnection($dsn) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Invalid Redis DSN'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\RedisCache::createConnection($dsn); + } + public function provideInvalidCreateConnection() + { + return [['foo://localhost'], ['redis://']]; + } +} diff --git a/vendor/symfony/cache/Tests/Simple/RedisClusterCacheTest.php b/vendor/symfony/cache/Tests/Simple/RedisClusterCacheTest.php index d1ed14f41..8638ed7bd 100644 --- a/vendor/symfony/cache/Tests/Simple/RedisClusterCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/RedisClusterCacheTest.php @@ -1,25 +1,25 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -class RedisClusterCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\AbstractRedisCacheTest -{ - public static function setUpBeforeClass() - { - if (!\class_exists('_PhpScoper5ea00cc67502b\\RedisCluster')) { - self::markTestSkipped('The RedisCluster class is required.'); - } - if (!($hosts = \getenv('REDIS_CLUSTER_HOSTS'))) { - self::markTestSkipped('REDIS_CLUSTER_HOSTS env var is not defined.'); - } - self::$redis = new \_PhpScoper5ea00cc67502b\RedisCluster(null, \explode(' ', $hosts)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +class RedisClusterCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\AbstractRedisCacheTest +{ + public static function setUpBeforeClass() + { + if (!\class_exists('_PhpScoper5ea00cc67502b\\RedisCluster')) { + self::markTestSkipped('The RedisCluster class is required.'); + } + if (!($hosts = \getenv('REDIS_CLUSTER_HOSTS'))) { + self::markTestSkipped('REDIS_CLUSTER_HOSTS env var is not defined.'); + } + self::$redis = new \_PhpScoper5ea00cc67502b\RedisCluster(null, \explode(' ', $hosts)); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/TraceableCacheTest.php b/vendor/symfony/cache/Tests/Simple/TraceableCacheTest.php index ba6afe009..bb27f739f 100644 --- a/vendor/symfony/cache/Tests/Simple/TraceableCacheTest.php +++ b/vendor/symfony/cache/Tests/Simple/TraceableCacheTest.php @@ -1,148 +1,148 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\TraceableCache; -/** - * @group time-sensitive - */ -class TraceableCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase -{ - protected $skippedTests = ['testPrune' => 'TraceableCache just proxies']; - public function createSimpleCache($defaultLifetime = 0) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\TraceableCache(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache('', $defaultLifetime)); - } - public function testGetMissTrace() - { - $pool = $this->createSimpleCache(); - $pool->get('k'); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('get', $call->name); - $this->assertSame(['k' => \false], $call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(1, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testGetHitTrace() - { - $pool = $this->createSimpleCache(); - $pool->set('k', 'foo'); - $pool->get('k'); - $calls = $pool->getCalls(); - $this->assertCount(2, $calls); - $call = $calls[1]; - $this->assertSame(1, $call->hits); - $this->assertSame(0, $call->misses); - } - public function testGetMultipleMissTrace() - { - $pool = $this->createSimpleCache(); - $pool->set('k1', 123); - $values = $pool->getMultiple(['k0', 'k1']); - foreach ($values as $value) { - } - $calls = $pool->getCalls(); - $this->assertCount(2, $calls); - $call = $calls[1]; - $this->assertSame('getMultiple', $call->name); - $this->assertSame(['k1' => \true, 'k0' => \false], $call->result); - $this->assertSame(1, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testHasMissTrace() - { - $pool = $this->createSimpleCache(); - $pool->has('k'); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('has', $call->name); - $this->assertSame(['k' => \false], $call->result); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testHasHitTrace() - { - $pool = $this->createSimpleCache(); - $pool->set('k', 'foo'); - $pool->has('k'); - $calls = $pool->getCalls(); - $this->assertCount(2, $calls); - $call = $calls[1]; - $this->assertSame('has', $call->name); - $this->assertSame(['k' => \true], $call->result); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testDeleteTrace() - { - $pool = $this->createSimpleCache(); - $pool->delete('k'); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('delete', $call->name); - $this->assertSame(['k' => \true], $call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(0, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testDeleteMultipleTrace() - { - $pool = $this->createSimpleCache(); - $arg = ['k0', 'k1']; - $pool->deleteMultiple($arg); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('deleteMultiple', $call->name); - $this->assertSame(['keys' => $arg, 'result' => \true], $call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(0, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testTraceSetTrace() - { - $pool = $this->createSimpleCache(); - $pool->set('k', 'foo'); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('set', $call->name); - $this->assertSame(['k' => \true], $call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(0, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } - public function testSetMultipleTrace() - { - $pool = $this->createSimpleCache(); - $pool->setMultiple(['k' => 'foo']); - $calls = $pool->getCalls(); - $this->assertCount(1, $calls); - $call = $calls[0]; - $this->assertSame('setMultiple', $call->name); - $this->assertSame(['keys' => ['k'], 'result' => \true], $call->result); - $this->assertSame(0, $call->hits); - $this->assertSame(0, $call->misses); - $this->assertNotEmpty($call->start); - $this->assertNotEmpty($call->end); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\TraceableCache; +/** + * @group time-sensitive + */ +class TraceableCacheTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Simple\CacheTestCase +{ + protected $skippedTests = ['testPrune' => 'TraceableCache just proxies']; + public function createSimpleCache($defaultLifetime = 0) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\TraceableCache(new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Simple\FilesystemCache('', $defaultLifetime)); + } + public function testGetMissTrace() + { + $pool = $this->createSimpleCache(); + $pool->get('k'); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('get', $call->name); + $this->assertSame(['k' => \false], $call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(1, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testGetHitTrace() + { + $pool = $this->createSimpleCache(); + $pool->set('k', 'foo'); + $pool->get('k'); + $calls = $pool->getCalls(); + $this->assertCount(2, $calls); + $call = $calls[1]; + $this->assertSame(1, $call->hits); + $this->assertSame(0, $call->misses); + } + public function testGetMultipleMissTrace() + { + $pool = $this->createSimpleCache(); + $pool->set('k1', 123); + $values = $pool->getMultiple(['k0', 'k1']); + foreach ($values as $value) { + } + $calls = $pool->getCalls(); + $this->assertCount(2, $calls); + $call = $calls[1]; + $this->assertSame('getMultiple', $call->name); + $this->assertSame(['k1' => \true, 'k0' => \false], $call->result); + $this->assertSame(1, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testHasMissTrace() + { + $pool = $this->createSimpleCache(); + $pool->has('k'); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('has', $call->name); + $this->assertSame(['k' => \false], $call->result); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testHasHitTrace() + { + $pool = $this->createSimpleCache(); + $pool->set('k', 'foo'); + $pool->has('k'); + $calls = $pool->getCalls(); + $this->assertCount(2, $calls); + $call = $calls[1]; + $this->assertSame('has', $call->name); + $this->assertSame(['k' => \true], $call->result); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testDeleteTrace() + { + $pool = $this->createSimpleCache(); + $pool->delete('k'); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('delete', $call->name); + $this->assertSame(['k' => \true], $call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(0, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testDeleteMultipleTrace() + { + $pool = $this->createSimpleCache(); + $arg = ['k0', 'k1']; + $pool->deleteMultiple($arg); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('deleteMultiple', $call->name); + $this->assertSame(['keys' => $arg, 'result' => \true], $call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(0, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testTraceSetTrace() + { + $pool = $this->createSimpleCache(); + $pool->set('k', 'foo'); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('set', $call->name); + $this->assertSame(['k' => \true], $call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(0, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } + public function testSetMultipleTrace() + { + $pool = $this->createSimpleCache(); + $pool->setMultiple(['k' => 'foo']); + $calls = $pool->getCalls(); + $this->assertCount(1, $calls); + $call = $calls[0]; + $this->assertSame('setMultiple', $call->name); + $this->assertSame(['keys' => ['k'], 'result' => \true], $call->result); + $this->assertSame(0, $call->hits); + $this->assertSame(0, $call->misses); + $this->assertNotEmpty($call->start); + $this->assertNotEmpty($call->end); + } +} diff --git a/vendor/symfony/cache/Tests/Simple/index.php b/vendor/symfony/cache/Tests/Simple/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/Tests/Simple/index.php +++ b/vendor/symfony/cache/Tests/Simple/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Tests/Traits/PdoPruneableTrait.php b/vendor/symfony/cache/Tests/Traits/PdoPruneableTrait.php index 064f352b2..958e3866f 100644 --- a/vendor/symfony/cache/Tests/Traits/PdoPruneableTrait.php +++ b/vendor/symfony/cache/Tests/Traits/PdoPruneableTrait.php @@ -1,29 +1,29 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Traits; - -trait PdoPruneableTrait -{ - protected function isPruned($cache, $name) - { - $o = new \ReflectionObject($cache); - if (!$o->hasMethod('getConnection')) { - self::fail('Cache does not have "getConnection()" method.'); - } - $getPdoConn = $o->getMethod('getConnection'); - $getPdoConn->setAccessible(\true); - /** @var \Doctrine\DBAL\Statement $select */ - $select = $getPdoConn->invoke($cache)->prepare('SELECT 1 FROM cache_items WHERE item_id LIKE :id'); - $select->bindValue(':id', \sprintf('%%%s', $name)); - $select->execute(); - return 0 === \count($select->fetchAll(\PDO::FETCH_COLUMN)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Tests\Traits; + +trait PdoPruneableTrait +{ + protected function isPruned($cache, $name) + { + $o = new \ReflectionObject($cache); + if (!$o->hasMethod('getConnection')) { + self::fail('Cache does not have "getConnection()" method.'); + } + $getPdoConn = $o->getMethod('getConnection'); + $getPdoConn->setAccessible(\true); + /** @var \Doctrine\DBAL\Statement $select */ + $select = $getPdoConn->invoke($cache)->prepare('SELECT 1 FROM cache_items WHERE item_id LIKE :id'); + $select->bindValue(':id', \sprintf('%%%s', $name)); + $select->execute(); + return 0 === \count($select->fetchAll(\PDO::FETCH_COLUMN)); + } +} diff --git a/vendor/symfony/cache/Tests/Traits/index.php b/vendor/symfony/cache/Tests/Traits/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/Tests/Traits/index.php +++ b/vendor/symfony/cache/Tests/Traits/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Tests/index.php b/vendor/symfony/cache/Tests/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/Tests/index.php +++ b/vendor/symfony/cache/Tests/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/Traits/AbstractTrait.php b/vendor/symfony/cache/Traits/AbstractTrait.php index 2adb1f16c..5a37b1470 100644 --- a/vendor/symfony/cache/Traits/AbstractTrait.php +++ b/vendor/symfony/cache/Traits/AbstractTrait.php @@ -1,236 +1,236 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareTrait; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -/** - * @author Nicolas Grekas - * - * @internal - */ -trait AbstractTrait -{ - use LoggerAwareTrait; - private $namespace; - private $namespaceVersion = ''; - private $versioningIsEnabled = \false; - private $deferred = []; - /** - * @var int|null The maximum length to enforce for identifiers or null when no limit applies - */ - protected $maxIdLength; - /** - * Fetches several cache items. - * - * @param array $ids The cache identifiers to fetch - * - * @return array|\Traversable The corresponding values found in the cache - */ - protected abstract function doFetch(array $ids); - /** - * Confirms if the cache contains specified cache item. - * - * @param string $id The identifier for which to check existence - * - * @return bool True if item exists in the cache, false otherwise - */ - protected abstract function doHave($id); - /** - * Deletes all items in the pool. - * - * @param string $namespace The prefix used for all identifiers managed by this pool - * - * @return bool True if the pool was successfully cleared, false otherwise - */ - protected abstract function doClear($namespace); - /** - * Removes multiple items from the pool. - * - * @param array $ids An array of identifiers that should be removed from the pool - * - * @return bool True if the items were successfully removed, false otherwise - */ - protected abstract function doDelete(array $ids); - /** - * Persists several cache items immediately. - * - * @param array $values The values to cache, indexed by their cache identifier - * @param int $lifetime The lifetime of the cached values, 0 for persisting until manual cleaning - * - * @return array|bool The identifiers that failed to be cached or a boolean stating if caching succeeded or not - */ - protected abstract function doSave(array $values, $lifetime); - /** - * {@inheritdoc} - */ - public function hasItem($key) - { - $id = $this->getId($key); - if (isset($this->deferred[$key])) { - $this->commit(); - } - try { - return $this->doHave($id); - } catch (\Exception $e) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to check if key "{key}" is cached', ['key' => $key, 'exception' => $e]); - return \false; - } - } - /** - * {@inheritdoc} - */ - public function clear() - { - $this->deferred = []; - if ($cleared = $this->versioningIsEnabled) { - $namespaceVersion = \substr_replace(\base64_encode(\pack('V', \mt_rand())), static::NS_SEPARATOR, 5); - try { - $cleared = $this->doSave([static::NS_SEPARATOR . $this->namespace => $namespaceVersion], 0); - } catch (\Exception $e) { - $cleared = \false; - } - if ($cleared = \true === $cleared || [] === $cleared) { - $this->namespaceVersion = $namespaceVersion; - } - } - try { - return $this->doClear($this->namespace) || $cleared; - } catch (\Exception $e) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to clear the cache', ['exception' => $e]); - return \false; - } - } - /** - * {@inheritdoc} - */ - public function deleteItem($key) - { - return $this->deleteItems([$key]); - } - /** - * {@inheritdoc} - */ - public function deleteItems(array $keys) - { - $ids = []; - foreach ($keys as $key) { - $ids[$key] = $this->getId($key); - unset($this->deferred[$key]); - } - try { - if ($this->doDelete($ids)) { - return \true; - } - } catch (\Exception $e) { - } - $ok = \true; - // When bulk-delete failed, retry each item individually - foreach ($ids as $key => $id) { - try { - $e = null; - if ($this->doDelete([$id])) { - continue; - } - } catch (\Exception $e) { - } - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to delete key "{key}"', ['key' => $key, 'exception' => $e]); - $ok = \false; - } - return $ok; - } - /** - * Enables/disables versioning of items. - * - * When versioning is enabled, clearing the cache is atomic and doesn't require listing existing keys to proceed, - * but old keys may need garbage collection and extra round-trips to the back-end are required. - * - * Calling this method also clears the memoized namespace version and thus forces a resynchonization of it. - * - * @param bool $enable - * - * @return bool the previous state of versioning - */ - public function enableVersioning($enable = \true) - { - $wasEnabled = $this->versioningIsEnabled; - $this->versioningIsEnabled = (bool) $enable; - $this->namespaceVersion = ''; - return $wasEnabled; - } - /** - * {@inheritdoc} - */ - public function reset() - { - if ($this->deferred) { - $this->commit(); - } - $this->namespaceVersion = ''; - } - /** - * Like the native unserialize() function but throws an exception if anything goes wrong. - * - * @param string $value - * - * @return mixed - * - * @throws \Exception - */ - protected static function unserialize($value) - { - if ('b:0;' === $value) { - return \false; - } - $unserializeCallbackHandler = \ini_set('unserialize_callback_func', __CLASS__ . '::handleUnserializeCallback'); - try { - if (\false !== ($value = \unserialize($value))) { - return $value; - } - throw new \DomainException('Failed to unserialize cached value.'); - } catch (\Error $e) { - throw new \ErrorException($e->getMessage(), $e->getCode(), \E_ERROR, $e->getFile(), $e->getLine()); - } finally { - \ini_set('unserialize_callback_func', $unserializeCallbackHandler); - } - } - private function getId($key) - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - if ($this->versioningIsEnabled && '' === $this->namespaceVersion) { - $this->namespaceVersion = '1' . static::NS_SEPARATOR; - try { - foreach ($this->doFetch([static::NS_SEPARATOR . $this->namespace]) as $v) { - $this->namespaceVersion = $v; - } - if ('1' . static::NS_SEPARATOR === $this->namespaceVersion) { - $this->namespaceVersion = \substr_replace(\base64_encode(\pack('V', \time())), static::NS_SEPARATOR, 5); - $this->doSave([static::NS_SEPARATOR . $this->namespace => $this->namespaceVersion], 0); - } - } catch (\Exception $e) { - } - } - if (null === $this->maxIdLength) { - return $this->namespace . $this->namespaceVersion . $key; - } - if (\strlen($id = $this->namespace . $this->namespaceVersion . $key) > $this->maxIdLength) { - $id = $this->namespace . $this->namespaceVersion . \substr_replace(\base64_encode(\hash('sha256', $key, \true)), static::NS_SEPARATOR, -(\strlen($this->namespaceVersion) + 22)); - } - return $id; - } - /** - * @internal - */ - public static function handleUnserializeCallback($class) - { - throw new \DomainException('Class not found: ' . $class); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareTrait; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +/** + * @author Nicolas Grekas + * + * @internal + */ +trait AbstractTrait +{ + use LoggerAwareTrait; + private $namespace; + private $namespaceVersion = ''; + private $versioningIsEnabled = \false; + private $deferred = []; + /** + * @var int|null The maximum length to enforce for identifiers or null when no limit applies + */ + protected $maxIdLength; + /** + * Fetches several cache items. + * + * @param array $ids The cache identifiers to fetch + * + * @return array|\Traversable The corresponding values found in the cache + */ + protected abstract function doFetch(array $ids); + /** + * Confirms if the cache contains specified cache item. + * + * @param string $id The identifier for which to check existence + * + * @return bool True if item exists in the cache, false otherwise + */ + protected abstract function doHave($id); + /** + * Deletes all items in the pool. + * + * @param string $namespace The prefix used for all identifiers managed by this pool + * + * @return bool True if the pool was successfully cleared, false otherwise + */ + protected abstract function doClear($namespace); + /** + * Removes multiple items from the pool. + * + * @param array $ids An array of identifiers that should be removed from the pool + * + * @return bool True if the items were successfully removed, false otherwise + */ + protected abstract function doDelete(array $ids); + /** + * Persists several cache items immediately. + * + * @param array $values The values to cache, indexed by their cache identifier + * @param int $lifetime The lifetime of the cached values, 0 for persisting until manual cleaning + * + * @return array|bool The identifiers that failed to be cached or a boolean stating if caching succeeded or not + */ + protected abstract function doSave(array $values, $lifetime); + /** + * {@inheritdoc} + */ + public function hasItem($key) + { + $id = $this->getId($key); + if (isset($this->deferred[$key])) { + $this->commit(); + } + try { + return $this->doHave($id); + } catch (\Exception $e) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to check if key "{key}" is cached', ['key' => $key, 'exception' => $e]); + return \false; + } + } + /** + * {@inheritdoc} + */ + public function clear() + { + $this->deferred = []; + if ($cleared = $this->versioningIsEnabled) { + $namespaceVersion = \substr_replace(\base64_encode(\pack('V', \mt_rand())), static::NS_SEPARATOR, 5); + try { + $cleared = $this->doSave([static::NS_SEPARATOR . $this->namespace => $namespaceVersion], 0); + } catch (\Exception $e) { + $cleared = \false; + } + if ($cleared = \true === $cleared || [] === $cleared) { + $this->namespaceVersion = $namespaceVersion; + } + } + try { + return $this->doClear($this->namespace) || $cleared; + } catch (\Exception $e) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to clear the cache', ['exception' => $e]); + return \false; + } + } + /** + * {@inheritdoc} + */ + public function deleteItem($key) + { + return $this->deleteItems([$key]); + } + /** + * {@inheritdoc} + */ + public function deleteItems(array $keys) + { + $ids = []; + foreach ($keys as $key) { + $ids[$key] = $this->getId($key); + unset($this->deferred[$key]); + } + try { + if ($this->doDelete($ids)) { + return \true; + } + } catch (\Exception $e) { + } + $ok = \true; + // When bulk-delete failed, retry each item individually + foreach ($ids as $key => $id) { + try { + $e = null; + if ($this->doDelete([$id])) { + continue; + } + } catch (\Exception $e) { + } + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to delete key "{key}"', ['key' => $key, 'exception' => $e]); + $ok = \false; + } + return $ok; + } + /** + * Enables/disables versioning of items. + * + * When versioning is enabled, clearing the cache is atomic and doesn't require listing existing keys to proceed, + * but old keys may need garbage collection and extra round-trips to the back-end are required. + * + * Calling this method also clears the memoized namespace version and thus forces a resynchonization of it. + * + * @param bool $enable + * + * @return bool the previous state of versioning + */ + public function enableVersioning($enable = \true) + { + $wasEnabled = $this->versioningIsEnabled; + $this->versioningIsEnabled = (bool) $enable; + $this->namespaceVersion = ''; + return $wasEnabled; + } + /** + * {@inheritdoc} + */ + public function reset() + { + if ($this->deferred) { + $this->commit(); + } + $this->namespaceVersion = ''; + } + /** + * Like the native unserialize() function but throws an exception if anything goes wrong. + * + * @param string $value + * + * @return mixed + * + * @throws \Exception + */ + protected static function unserialize($value) + { + if ('b:0;' === $value) { + return \false; + } + $unserializeCallbackHandler = \ini_set('unserialize_callback_func', __CLASS__ . '::handleUnserializeCallback'); + try { + if (\false !== ($value = \unserialize($value))) { + return $value; + } + throw new \DomainException('Failed to unserialize cached value.'); + } catch (\Error $e) { + throw new \ErrorException($e->getMessage(), $e->getCode(), \E_ERROR, $e->getFile(), $e->getLine()); + } finally { + \ini_set('unserialize_callback_func', $unserializeCallbackHandler); + } + } + private function getId($key) + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + if ($this->versioningIsEnabled && '' === $this->namespaceVersion) { + $this->namespaceVersion = '1' . static::NS_SEPARATOR; + try { + foreach ($this->doFetch([static::NS_SEPARATOR . $this->namespace]) as $v) { + $this->namespaceVersion = $v; + } + if ('1' . static::NS_SEPARATOR === $this->namespaceVersion) { + $this->namespaceVersion = \substr_replace(\base64_encode(\pack('V', \time())), static::NS_SEPARATOR, 5); + $this->doSave([static::NS_SEPARATOR . $this->namespace => $this->namespaceVersion], 0); + } + } catch (\Exception $e) { + } + } + if (null === $this->maxIdLength) { + return $this->namespace . $this->namespaceVersion . $key; + } + if (\strlen($id = $this->namespace . $this->namespaceVersion . $key) > $this->maxIdLength) { + $id = $this->namespace . $this->namespaceVersion . \substr_replace(\base64_encode(\hash('sha256', $key, \true)), static::NS_SEPARATOR, -(\strlen($this->namespaceVersion) + 22)); + } + return $id; + } + /** + * @internal + */ + public static function handleUnserializeCallback($class) + { + throw new \DomainException('Class not found: ' . $class); + } +} diff --git a/vendor/symfony/cache/Traits/ApcuTrait.php b/vendor/symfony/cache/Traits/ApcuTrait.php index 14eef1487..18b722503 100644 --- a/vendor/symfony/cache/Traits/ApcuTrait.php +++ b/vendor/symfony/cache/Traits/ApcuTrait.php @@ -1,134 +1,134 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -/* - * This file is part of the Symfony package. - * - * (c) Fabien Potencier - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; -/** - * @author Nicolas Grekas - * - * @internal - */ -trait ApcuTrait -{ - public static function isSupported() - { - return \function_exists('_PhpScoper5ea00cc67502b\\apcu_fetch') && \filter_var(\ini_get('apc.enabled'), \FILTER_VALIDATE_BOOLEAN); - } - private function init($namespace, $defaultLifetime, $version) - { - if (!static::isSupported()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('APCu is not enabled.'); - } - if ('cli' === \PHP_SAPI) { - \ini_set('apc.use_request_time', 0); - } - parent::__construct($namespace, $defaultLifetime); - if (null !== $version) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($version); - if (!apcu_exists($version . '@' . $namespace)) { - $this->doClear($namespace); - apcu_add($version . '@' . $namespace, null); - } - } - } - /** - * {@inheritdoc} - */ - protected function doFetch(array $ids) - { - try { - foreach (apcu_fetch($ids, $ok) ?: [] as $k => $v) { - if (null !== $v || $ok) { - (yield $k => $v); - } - } - } catch (\Error $e) { - throw new \ErrorException($e->getMessage(), $e->getCode(), \E_ERROR, $e->getFile(), $e->getLine()); - } - } - /** - * {@inheritdoc} - */ - protected function doHave($id) - { - return apcu_exists($id); - } - /** - * {@inheritdoc} - */ - protected function doClear($namespace) - { - return isset($namespace[0]) && \class_exists('_PhpScoper5ea00cc67502b\\APCuIterator', \false) && ('cli' !== \PHP_SAPI || \filter_var(\ini_get('apc.enable_cli'), \FILTER_VALIDATE_BOOLEAN)) ? apcu_delete(new \_PhpScoper5ea00cc67502b\APCuIterator(\sprintf('/^%s/', \preg_quote($namespace, '/')), APC_ITER_KEY)) : apcu_clear_cache(); - } - /** - * {@inheritdoc} - */ - protected function doDelete(array $ids) - { - foreach ($ids as $id) { - apcu_delete($id); - } - return \true; - } - /** - * {@inheritdoc} - */ - protected function doSave(array $values, $lifetime) - { - try { - if (\false === ($failures = apcu_store($values, null, $lifetime))) { - $failures = $values; - } - return \array_keys($failures); - } catch (\Error $e) { - } catch (\Exception $e) { - } - if (1 === \count($values)) { - // Workaround https://github.com/krakjoe/apcu/issues/170 - apcu_delete(\key($values)); - } - throw $e; - } -} + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +/* + * This file is part of the Symfony package. + * + * (c) Fabien Potencier + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; +/** + * @author Nicolas Grekas + * + * @internal + */ +trait ApcuTrait +{ + public static function isSupported() + { + return \function_exists('_PhpScoper5ea00cc67502b\\apcu_fetch') && \filter_var(\ini_get('apc.enabled'), \FILTER_VALIDATE_BOOLEAN); + } + private function init($namespace, $defaultLifetime, $version) + { + if (!static::isSupported()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('APCu is not enabled.'); + } + if ('cli' === \PHP_SAPI) { + \ini_set('apc.use_request_time', 0); + } + parent::__construct($namespace, $defaultLifetime); + if (null !== $version) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($version); + if (!apcu_exists($version . '@' . $namespace)) { + $this->doClear($namespace); + apcu_add($version . '@' . $namespace, null); + } + } + } + /** + * {@inheritdoc} + */ + protected function doFetch(array $ids) + { + try { + foreach (apcu_fetch($ids, $ok) ?: [] as $k => $v) { + if (null !== $v || $ok) { + (yield $k => $v); + } + } + } catch (\Error $e) { + throw new \ErrorException($e->getMessage(), $e->getCode(), \E_ERROR, $e->getFile(), $e->getLine()); + } + } + /** + * {@inheritdoc} + */ + protected function doHave($id) + { + return apcu_exists($id); + } + /** + * {@inheritdoc} + */ + protected function doClear($namespace) + { + return isset($namespace[0]) && \class_exists('_PhpScoper5ea00cc67502b\\APCuIterator', \false) && ('cli' !== \PHP_SAPI || \filter_var(\ini_get('apc.enable_cli'), \FILTER_VALIDATE_BOOLEAN)) ? apcu_delete(new \_PhpScoper5ea00cc67502b\APCuIterator(\sprintf('/^%s/', \preg_quote($namespace, '/')), APC_ITER_KEY)) : apcu_clear_cache(); + } + /** + * {@inheritdoc} + */ + protected function doDelete(array $ids) + { + foreach ($ids as $id) { + apcu_delete($id); + } + return \true; + } + /** + * {@inheritdoc} + */ + protected function doSave(array $values, $lifetime) + { + try { + if (\false === ($failures = apcu_store($values, null, $lifetime))) { + $failures = $values; + } + return \array_keys($failures); + } catch (\Error $e) { + } catch (\Exception $e) { + } + if (1 === \count($values)) { + // Workaround https://github.com/krakjoe/apcu/issues/170 + apcu_delete(\key($values)); + } + throw $e; + } +} diff --git a/vendor/symfony/cache/Traits/ArrayTrait.php b/vendor/symfony/cache/Traits/ArrayTrait.php index 7abec1cd0..add56c668 100644 --- a/vendor/symfony/cache/Traits/ArrayTrait.php +++ b/vendor/symfony/cache/Traits/ArrayTrait.php @@ -1,93 +1,93 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareTrait; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -/** - * @author Nicolas Grekas - * - * @internal - */ -trait ArrayTrait -{ - use LoggerAwareTrait; - private $storeSerialized; - private $values = []; - private $expiries = []; - /** - * Returns all cached values, with cache miss as null. - * - * @return array - */ - public function getValues() - { - return $this->values; - } - /** - * {@inheritdoc} - */ - public function hasItem($key) - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - return isset($this->expiries[$key]) && ($this->expiries[$key] > \time() || !$this->deleteItem($key)); - } - /** - * {@inheritdoc} - */ - public function clear() - { - $this->values = $this->expiries = []; - return \true; - } - /** - * {@inheritdoc} - */ - public function deleteItem($key) - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); - unset($this->values[$key], $this->expiries[$key]); - return \true; - } - /** - * {@inheritdoc} - */ - public function reset() - { - $this->clear(); - } - private function generateItems(array $keys, $now, $f) - { - foreach ($keys as $i => $key) { - try { - if (!($isHit = isset($this->expiries[$key]) && ($this->expiries[$key] > $now || !$this->deleteItem($key)))) { - $this->values[$key] = $value = null; - } elseif (!$this->storeSerialized) { - $value = $this->values[$key]; - } elseif ('b:0;' === ($value = $this->values[$key])) { - $value = \false; - } elseif (\false === ($value = \unserialize($value))) { - $this->values[$key] = $value = null; - $isHit = \false; - } - } catch (\Exception $e) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to unserialize key "{key}"', ['key' => $key, 'exception' => $e]); - $this->values[$key] = $value = null; - $isHit = \false; - } - unset($keys[$i]); - (yield $key => $f($key, $value, $isHit)); - } - foreach ($keys as $key) { - (yield $key => $f($key, null, \false)); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Psr\Log\LoggerAwareTrait; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +/** + * @author Nicolas Grekas + * + * @internal + */ +trait ArrayTrait +{ + use LoggerAwareTrait; + private $storeSerialized; + private $values = []; + private $expiries = []; + /** + * Returns all cached values, with cache miss as null. + * + * @return array + */ + public function getValues() + { + return $this->values; + } + /** + * {@inheritdoc} + */ + public function hasItem($key) + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + return isset($this->expiries[$key]) && ($this->expiries[$key] > \time() || !$this->deleteItem($key)); + } + /** + * {@inheritdoc} + */ + public function clear() + { + $this->values = $this->expiries = []; + return \true; + } + /** + * {@inheritdoc} + */ + public function deleteItem($key) + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey($key); + unset($this->values[$key], $this->expiries[$key]); + return \true; + } + /** + * {@inheritdoc} + */ + public function reset() + { + $this->clear(); + } + private function generateItems(array $keys, $now, $f) + { + foreach ($keys as $i => $key) { + try { + if (!($isHit = isset($this->expiries[$key]) && ($this->expiries[$key] > $now || !$this->deleteItem($key)))) { + $this->values[$key] = $value = null; + } elseif (!$this->storeSerialized) { + $value = $this->values[$key]; + } elseif ('b:0;' === ($value = $this->values[$key])) { + $value = \false; + } elseif (\false === ($value = \unserialize($value))) { + $this->values[$key] = $value = null; + $isHit = \false; + } + } catch (\Exception $e) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::log($this->logger, 'Failed to unserialize key "{key}"', ['key' => $key, 'exception' => $e]); + $this->values[$key] = $value = null; + $isHit = \false; + } + unset($keys[$i]); + (yield $key => $f($key, $value, $isHit)); + } + foreach ($keys as $key) { + (yield $key => $f($key, null, \false)); + } + } +} diff --git a/vendor/symfony/cache/Traits/DoctrineTrait.php b/vendor/symfony/cache/Traits/DoctrineTrait.php index 49a445891..1937196dc 100644 --- a/vendor/symfony/cache/Traits/DoctrineTrait.php +++ b/vendor/symfony/cache/Traits/DoctrineTrait.php @@ -1,85 +1,85 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -/** - * @author Nicolas Grekas - * - * @internal - */ -trait DoctrineTrait -{ - private $provider; - /** - * {@inheritdoc} - */ - public function reset() - { - parent::reset(); - $this->provider->setNamespace($this->provider->getNamespace()); - } - /** - * {@inheritdoc} - */ - protected function doFetch(array $ids) - { - $unserializeCallbackHandler = \ini_set('unserialize_callback_func', parent::class . '::handleUnserializeCallback'); - try { - return $this->provider->fetchMultiple($ids); - } catch (\Error $e) { - $trace = $e->getTrace(); - if (isset($trace[0]['function']) && !isset($trace[0]['class'])) { - switch ($trace[0]['function']) { - case 'unserialize': - case 'apcu_fetch': - case 'apc_fetch': - throw new \ErrorException($e->getMessage(), $e->getCode(), \E_ERROR, $e->getFile(), $e->getLine()); - } - } - throw $e; - } finally { - \ini_set('unserialize_callback_func', $unserializeCallbackHandler); - } - } - /** - * {@inheritdoc} - */ - protected function doHave($id) - { - return $this->provider->contains($id); - } - /** - * {@inheritdoc} - */ - protected function doClear($namespace) - { - $namespace = $this->provider->getNamespace(); - return isset($namespace[0]) ? $this->provider->deleteAll() : $this->provider->flushAll(); - } - /** - * {@inheritdoc} - */ - protected function doDelete(array $ids) - { - $ok = \true; - foreach ($ids as $id) { - $ok = $this->provider->delete($id) && $ok; - } - return $ok; - } - /** - * {@inheritdoc} - */ - protected function doSave(array $values, $lifetime) - { - return $this->provider->saveMultiple($values, $lifetime); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +/** + * @author Nicolas Grekas + * + * @internal + */ +trait DoctrineTrait +{ + private $provider; + /** + * {@inheritdoc} + */ + public function reset() + { + parent::reset(); + $this->provider->setNamespace($this->provider->getNamespace()); + } + /** + * {@inheritdoc} + */ + protected function doFetch(array $ids) + { + $unserializeCallbackHandler = \ini_set('unserialize_callback_func', parent::class . '::handleUnserializeCallback'); + try { + return $this->provider->fetchMultiple($ids); + } catch (\Error $e) { + $trace = $e->getTrace(); + if (isset($trace[0]['function']) && !isset($trace[0]['class'])) { + switch ($trace[0]['function']) { + case 'unserialize': + case 'apcu_fetch': + case 'apc_fetch': + throw new \ErrorException($e->getMessage(), $e->getCode(), \E_ERROR, $e->getFile(), $e->getLine()); + } + } + throw $e; + } finally { + \ini_set('unserialize_callback_func', $unserializeCallbackHandler); + } + } + /** + * {@inheritdoc} + */ + protected function doHave($id) + { + return $this->provider->contains($id); + } + /** + * {@inheritdoc} + */ + protected function doClear($namespace) + { + $namespace = $this->provider->getNamespace(); + return isset($namespace[0]) ? $this->provider->deleteAll() : $this->provider->flushAll(); + } + /** + * {@inheritdoc} + */ + protected function doDelete(array $ids) + { + $ok = \true; + foreach ($ids as $id) { + $ok = $this->provider->delete($id) && $ok; + } + return $ok; + } + /** + * {@inheritdoc} + */ + protected function doSave(array $values, $lifetime) + { + return $this->provider->saveMultiple($values, $lifetime); + } +} diff --git a/vendor/symfony/cache/Traits/FilesystemCommonTrait.php b/vendor/symfony/cache/Traits/FilesystemCommonTrait.php index f68752942..2345472b7 100644 --- a/vendor/symfony/cache/Traits/FilesystemCommonTrait.php +++ b/vendor/symfony/cache/Traits/FilesystemCommonTrait.php @@ -1,118 +1,118 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -/** - * @author Nicolas Grekas - * - * @internal - */ -trait FilesystemCommonTrait -{ - private $directory; - private $tmp; - private function init($namespace, $directory) - { - if (!isset($directory[0])) { - $directory = \sys_get_temp_dir() . '/symfony-cache'; - } else { - $directory = \realpath($directory) ?: $directory; - } - if (isset($namespace[0])) { - if (\preg_match('#[^-+_.A-Za-z0-9]#', $namespace, $match)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Namespace contains "%s" but only characters in [-+_.A-Za-z0-9] are allowed.', $match[0])); - } - $directory .= \DIRECTORY_SEPARATOR . $namespace; - } - if (!\file_exists($directory)) { - @\mkdir($directory, 0777, \true); - } - $directory .= \DIRECTORY_SEPARATOR; - // On Windows the whole path is limited to 258 chars - if ('\\' === \DIRECTORY_SEPARATOR && \strlen($directory) > 234) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache directory too long (%s).', $directory)); - } - $this->directory = $directory; - } - /** - * {@inheritdoc} - */ - protected function doClear($namespace) - { - $ok = \true; - foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($this->directory, \FilesystemIterator::SKIP_DOTS)) as $file) { - $ok = ($file->isDir() || @\unlink($file) || !\file_exists($file)) && $ok; - } - return $ok; - } - /** - * {@inheritdoc} - */ - protected function doDelete(array $ids) - { - $ok = \true; - foreach ($ids as $id) { - $file = $this->getFile($id); - $ok = (!\file_exists($file) || @\unlink($file) || !\file_exists($file)) && $ok; - } - return $ok; - } - private function write($file, $data, $expiresAt = null) - { - \set_error_handler(__CLASS__ . '::throwError'); - try { - if (null === $this->tmp) { - $this->tmp = $this->directory . \uniqid('', \true); - } - \file_put_contents($this->tmp, $data); - if (null !== $expiresAt) { - \touch($this->tmp, $expiresAt); - } - return \rename($this->tmp, $file); - } finally { - \restore_error_handler(); - } - } - private function getFile($id, $mkdir = \false) - { - $hash = \str_replace('/', '-', \base64_encode(\hash('sha256', static::class . $id, \true))); - $dir = $this->directory . \strtoupper($hash[0] . \DIRECTORY_SEPARATOR . $hash[1] . \DIRECTORY_SEPARATOR); - if ($mkdir && !\file_exists($dir)) { - @\mkdir($dir, 0777, \true); - } - return $dir . \substr($hash, 2, 20); - } - /** - * @internal - */ - public static function throwError($type, $message, $file, $line) - { - throw new \ErrorException($message, 0, $type, $file, $line); - } - public function __sleep() - { - throw new \BadMethodCallException('Cannot serialize ' . __CLASS__); - } - public function __wakeup() - { - throw new \BadMethodCallException('Cannot unserialize ' . __CLASS__); - } - public function __destruct() - { - if (\method_exists(parent::class, '__destruct')) { - parent::__destruct(); - } - if (null !== $this->tmp && \file_exists($this->tmp)) { - \unlink($this->tmp); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +/** + * @author Nicolas Grekas + * + * @internal + */ +trait FilesystemCommonTrait +{ + private $directory; + private $tmp; + private function init($namespace, $directory) + { + if (!isset($directory[0])) { + $directory = \sys_get_temp_dir() . '/symfony-cache'; + } else { + $directory = \realpath($directory) ?: $directory; + } + if (isset($namespace[0])) { + if (\preg_match('#[^-+_.A-Za-z0-9]#', $namespace, $match)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Namespace contains "%s" but only characters in [-+_.A-Za-z0-9] are allowed.', $match[0])); + } + $directory .= \DIRECTORY_SEPARATOR . $namespace; + } + if (!\file_exists($directory)) { + @\mkdir($directory, 0777, \true); + } + $directory .= \DIRECTORY_SEPARATOR; + // On Windows the whole path is limited to 258 chars + if ('\\' === \DIRECTORY_SEPARATOR && \strlen($directory) > 234) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache directory too long (%s).', $directory)); + } + $this->directory = $directory; + } + /** + * {@inheritdoc} + */ + protected function doClear($namespace) + { + $ok = \true; + foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($this->directory, \FilesystemIterator::SKIP_DOTS)) as $file) { + $ok = ($file->isDir() || @\unlink($file) || !\file_exists($file)) && $ok; + } + return $ok; + } + /** + * {@inheritdoc} + */ + protected function doDelete(array $ids) + { + $ok = \true; + foreach ($ids as $id) { + $file = $this->getFile($id); + $ok = (!\file_exists($file) || @\unlink($file) || !\file_exists($file)) && $ok; + } + return $ok; + } + private function write($file, $data, $expiresAt = null) + { + \set_error_handler(__CLASS__ . '::throwError'); + try { + if (null === $this->tmp) { + $this->tmp = $this->directory . \uniqid('', \true); + } + \file_put_contents($this->tmp, $data); + if (null !== $expiresAt) { + \touch($this->tmp, $expiresAt); + } + return \rename($this->tmp, $file); + } finally { + \restore_error_handler(); + } + } + private function getFile($id, $mkdir = \false) + { + $hash = \str_replace('/', '-', \base64_encode(\hash('sha256', static::class . $id, \true))); + $dir = $this->directory . \strtoupper($hash[0] . \DIRECTORY_SEPARATOR . $hash[1] . \DIRECTORY_SEPARATOR); + if ($mkdir && !\file_exists($dir)) { + @\mkdir($dir, 0777, \true); + } + return $dir . \substr($hash, 2, 20); + } + /** + * @internal + */ + public static function throwError($type, $message, $file, $line) + { + throw new \ErrorException($message, 0, $type, $file, $line); + } + public function __sleep() + { + throw new \BadMethodCallException('Cannot serialize ' . __CLASS__); + } + public function __wakeup() + { + throw new \BadMethodCallException('Cannot unserialize ' . __CLASS__); + } + public function __destruct() + { + if (\method_exists(parent::class, '__destruct')) { + parent::__destruct(); + } + if (null !== $this->tmp && \file_exists($this->tmp)) { + \unlink($this->tmp); + } + } +} diff --git a/vendor/symfony/cache/Traits/FilesystemTrait.php b/vendor/symfony/cache/Traits/FilesystemTrait.php index 3afc5ea16..5882c1e11 100644 --- a/vendor/symfony/cache/Traits/FilesystemTrait.php +++ b/vendor/symfony/cache/Traits/FilesystemTrait.php @@ -1,92 +1,92 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; -/** - * @author Nicolas Grekas - * @author Rob Frawley 2nd - * - * @internal - */ -trait FilesystemTrait -{ - use FilesystemCommonTrait; - /** - * @return bool - */ - public function prune() - { - $time = \time(); - $pruned = \true; - foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($this->directory, \FilesystemIterator::SKIP_DOTS), \RecursiveIteratorIterator::LEAVES_ONLY) as $file) { - if (!($h = @\fopen($file, 'rb'))) { - continue; - } - if (($expiresAt = (int) \fgets($h)) && $time >= $expiresAt) { - \fclose($h); - $pruned = @\unlink($file) && !\file_exists($file) && $pruned; - } else { - \fclose($h); - } - } - return $pruned; - } - /** - * {@inheritdoc} - */ - protected function doFetch(array $ids) - { - $values = []; - $now = \time(); - foreach ($ids as $id) { - $file = $this->getFile($id); - if (!\file_exists($file) || !($h = @\fopen($file, 'rb'))) { - continue; - } - if (($expiresAt = (int) \fgets($h)) && $now >= $expiresAt) { - \fclose($h); - @\unlink($file); - } else { - $i = \rawurldecode(\rtrim(\fgets($h))); - $value = \stream_get_contents($h); - \fclose($h); - if ($i === $id) { - $values[$id] = parent::unserialize($value); - } - } - } - return $values; - } - /** - * {@inheritdoc} - */ - protected function doHave($id) - { - $file = $this->getFile($id); - return \file_exists($file) && (@\filemtime($file) > \time() || $this->doFetch([$id])); - } - /** - * {@inheritdoc} - */ - protected function doSave(array $values, $lifetime) - { - $ok = \true; - $expiresAt = $lifetime ? \time() + $lifetime : 0; - foreach ($values as $id => $value) { - $ok = $this->write($this->getFile($id, \true), $expiresAt . "\n" . \rawurlencode($id) . "\n" . \serialize($value), $expiresAt) && $ok; - } - if (!$ok && !\is_writable($this->directory)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException(\sprintf('Cache directory is not writable (%s).', $this->directory)); - } - return $ok; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; +/** + * @author Nicolas Grekas + * @author Rob Frawley 2nd + * + * @internal + */ +trait FilesystemTrait +{ + use FilesystemCommonTrait; + /** + * @return bool + */ + public function prune() + { + $time = \time(); + $pruned = \true; + foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($this->directory, \FilesystemIterator::SKIP_DOTS), \RecursiveIteratorIterator::LEAVES_ONLY) as $file) { + if (!($h = @\fopen($file, 'rb'))) { + continue; + } + if (($expiresAt = (int) \fgets($h)) && $time >= $expiresAt) { + \fclose($h); + $pruned = @\unlink($file) && !\file_exists($file) && $pruned; + } else { + \fclose($h); + } + } + return $pruned; + } + /** + * {@inheritdoc} + */ + protected function doFetch(array $ids) + { + $values = []; + $now = \time(); + foreach ($ids as $id) { + $file = $this->getFile($id); + if (!\file_exists($file) || !($h = @\fopen($file, 'rb'))) { + continue; + } + if (($expiresAt = (int) \fgets($h)) && $now >= $expiresAt) { + \fclose($h); + @\unlink($file); + } else { + $i = \rawurldecode(\rtrim(\fgets($h))); + $value = \stream_get_contents($h); + \fclose($h); + if ($i === $id) { + $values[$id] = parent::unserialize($value); + } + } + } + return $values; + } + /** + * {@inheritdoc} + */ + protected function doHave($id) + { + $file = $this->getFile($id); + return \file_exists($file) && (@\filemtime($file) > \time() || $this->doFetch([$id])); + } + /** + * {@inheritdoc} + */ + protected function doSave(array $values, $lifetime) + { + $ok = \true; + $expiresAt = $lifetime ? \time() + $lifetime : 0; + foreach ($values as $id => $value) { + $ok = $this->write($this->getFile($id, \true), $expiresAt . "\n" . \rawurlencode($id) . "\n" . \serialize($value), $expiresAt) && $ok; + } + if (!$ok && !\is_writable($this->directory)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException(\sprintf('Cache directory is not writable (%s).', $this->directory)); + } + return $ok; + } +} diff --git a/vendor/symfony/cache/Traits/MemcachedTrait.php b/vendor/symfony/cache/Traits/MemcachedTrait.php index e0d6ee0e5..6843ea37b 100644 --- a/vendor/symfony/cache/Traits/MemcachedTrait.php +++ b/vendor/symfony/cache/Traits/MemcachedTrait.php @@ -1,256 +1,256 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -/** - * @author Rob Frawley 2nd - * @author Nicolas Grekas - * - * @internal - */ -trait MemcachedTrait -{ - private static $defaultClientOptions = ['persistent_id' => null, 'username' => null, 'password' => null, \_PhpScoper5ea00cc67502b\Memcached::OPT_SERIALIZER => \_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_PHP]; - private $client; - private $lazyClient; - public static function isSupported() - { - return \extension_loaded('memcached') && \version_compare(\phpversion('memcached'), '2.2.0', '>='); - } - private function init(\_PhpScoper5ea00cc67502b\Memcached $client, $namespace, $defaultLifetime) - { - if (!static::isSupported()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('Memcached >= 2.2.0 is required.'); - } - if ('Memcached' === \get_class($client)) { - $opt = $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_SERIALIZER); - if (\_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_PHP !== $opt && \_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_IGBINARY !== $opt) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('MemcachedAdapter: "serializer" option must be "php" or "igbinary".'); - } - $this->maxIdLength -= \strlen($client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_PREFIX_KEY)); - $this->client = $client; - } else { - $this->lazyClient = $client; - } - parent::__construct($namespace, $defaultLifetime); - $this->enableVersioning(); - } - /** - * Creates a Memcached instance. - * - * By default, the binary protocol, no block, and libketama compatible options are enabled. - * - * Examples for servers: - * - 'memcached://user:pass@localhost?weight=33' - * - [['localhost', 11211, 33]] - * - * @param array[]|string|string[] $servers An array of servers, a DSN, or an array of DSNs - * @param array $options An array of options - * - * @return \Memcached - * - * @throws \ErrorException When invalid options or servers are provided - */ - public static function createConnection($servers, array $options = []) - { - if (\is_string($servers)) { - $servers = [$servers]; - } elseif (!\is_array($servers)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('MemcachedAdapter::createClient() expects array or string as first argument, "%s" given.', \gettype($servers))); - } - if (!static::isSupported()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('Memcached >= 2.2.0 is required.'); - } - \set_error_handler(function ($type, $msg, $file, $line) { - throw new \ErrorException($msg, 0, $type, $file, $line); - }); - try { - $options += static::$defaultClientOptions; - $client = new \_PhpScoper5ea00cc67502b\Memcached($options['persistent_id']); - $username = $options['username']; - $password = $options['password']; - // parse any DSN in $servers - foreach ($servers as $i => $dsn) { - if (\is_array($dsn)) { - continue; - } - if (0 !== \strpos($dsn, 'memcached://')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Memcached DSN: "%s" does not start with "memcached://".', $dsn)); - } - $params = \preg_replace_callback('#^memcached://(?:([^@]*+)@)?#', function ($m) use(&$username, &$password) { - if (!empty($m[1])) { - list($username, $password) = \explode(':', $m[1], 2) + [1 => null]; - } - return 'file://'; - }, $dsn); - if (\false === ($params = \parse_url($params))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Memcached DSN: "%s".', $dsn)); - } - if (!isset($params['host']) && !isset($params['path'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Memcached DSN: "%s".', $dsn)); - } - if (isset($params['path']) && \preg_match('#/(\\d+)$#', $params['path'], $m)) { - $params['weight'] = $m[1]; - $params['path'] = \substr($params['path'], 0, -\strlen($m[0])); - } - $params += ['host' => isset($params['host']) ? $params['host'] : $params['path'], 'port' => isset($params['host']) ? 11211 : null, 'weight' => 0]; - if (isset($params['query'])) { - \parse_str($params['query'], $query); - $params += $query; - $options = $query + $options; - } - $servers[$i] = [$params['host'], $params['port'], $params['weight']]; - } - // set client's options - unset($options['persistent_id'], $options['username'], $options['password'], $options['weight'], $options['lazy']); - $options = \array_change_key_case($options, \CASE_UPPER); - $client->setOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_BINARY_PROTOCOL, \true); - $client->setOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_NO_BLOCK, \true); - $client->setOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_TCP_NODELAY, \true); - if (!\array_key_exists('LIBKETAMA_COMPATIBLE', $options) && !\array_key_exists(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE, $options)) { - $client->setOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE, \true); - } - foreach ($options as $name => $value) { - if (\is_int($name)) { - continue; - } - if ('HASH' === $name || 'SERIALIZER' === $name || 'DISTRIBUTION' === $name) { - $value = \constant('Memcached::' . $name . '_' . \strtoupper($value)); - } - $opt = \constant('Memcached::OPT_' . $name); - unset($options[$name]); - $options[$opt] = $value; - } - $client->setOptions($options); - // set client's servers, taking care of persistent connections - if (!$client->isPristine()) { - $oldServers = []; - foreach ($client->getServerList() as $server) { - $oldServers[] = [$server['host'], $server['port']]; - } - $newServers = []; - foreach ($servers as $server) { - if (1 < \count($server)) { - $server = \array_values($server); - unset($server[2]); - $server[1] = (int) $server[1]; - } - $newServers[] = $server; - } - if ($oldServers !== $newServers) { - $client->resetServerList(); - $client->addServers($servers); - } - } else { - $client->addServers($servers); - } - if (null !== $username || null !== $password) { - if (!\method_exists($client, 'setSaslAuthData')) { - \trigger_error('Missing SASL support: the memcached extension must be compiled with --enable-memcached-sasl.'); - } - $client->setSaslAuthData($username, $password); - } - return $client; - } finally { - \restore_error_handler(); - } - } - /** - * {@inheritdoc} - */ - protected function doSave(array $values, $lifetime) - { - if ($lifetime && $lifetime > 30 * 86400) { - $lifetime += \time(); - } - $encodedValues = []; - foreach ($values as $key => $value) { - $encodedValues[\rawurlencode($key)] = $value; - } - return $this->checkResultCode($this->getClient()->setMulti($encodedValues, $lifetime)); - } - /** - * {@inheritdoc} - */ - protected function doFetch(array $ids) - { - $unserializeCallbackHandler = \ini_set('unserialize_callback_func', __CLASS__ . '::handleUnserializeCallback'); - try { - $encodedIds = \array_map('rawurlencode', $ids); - $encodedResult = $this->checkResultCode($this->getClient()->getMulti($encodedIds)); - $result = []; - foreach ($encodedResult as $key => $value) { - $result[\rawurldecode($key)] = $value; - } - return $result; - } catch (\Error $e) { - throw new \ErrorException($e->getMessage(), $e->getCode(), \E_ERROR, $e->getFile(), $e->getLine()); - } finally { - \ini_set('unserialize_callback_func', $unserializeCallbackHandler); - } - } - /** - * {@inheritdoc} - */ - protected function doHave($id) - { - return \false !== $this->getClient()->get(\rawurlencode($id)) || $this->checkResultCode(\_PhpScoper5ea00cc67502b\Memcached::RES_SUCCESS === $this->client->getResultCode()); - } - /** - * {@inheritdoc} - */ - protected function doDelete(array $ids) - { - $ok = \true; - $encodedIds = \array_map('rawurlencode', $ids); - foreach ($this->checkResultCode($this->getClient()->deleteMulti($encodedIds)) as $result) { - if (\_PhpScoper5ea00cc67502b\Memcached::RES_SUCCESS !== $result && \_PhpScoper5ea00cc67502b\Memcached::RES_NOTFOUND !== $result) { - $ok = \false; - break; - } - } - return $ok; - } - /** - * {@inheritdoc} - */ - protected function doClear($namespace) - { - return '' === $namespace && $this->getClient()->flush(); - } - private function checkResultCode($result) - { - $code = $this->client->getResultCode(); - if (\_PhpScoper5ea00cc67502b\Memcached::RES_SUCCESS === $code || \_PhpScoper5ea00cc67502b\Memcached::RES_NOTFOUND === $code) { - return $result; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException(\sprintf('MemcachedAdapter client error: %s.', \strtolower($this->client->getResultMessage()))); - } - /** - * @return \Memcached - */ - private function getClient() - { - if ($this->client) { - return $this->client; - } - $opt = $this->lazyClient->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_SERIALIZER); - if (\_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_PHP !== $opt && \_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_IGBINARY !== $opt) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('MemcachedAdapter: "serializer" option must be "php" or "igbinary".'); - } - if ('' !== ($prefix = (string) $this->lazyClient->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_PREFIX_KEY))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException(\sprintf('MemcachedAdapter: "prefix_key" option must be empty when using proxified connections, "%s" given.', $prefix)); - } - return $this->client = $this->lazyClient; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +/** + * @author Rob Frawley 2nd + * @author Nicolas Grekas + * + * @internal + */ +trait MemcachedTrait +{ + private static $defaultClientOptions = ['persistent_id' => null, 'username' => null, 'password' => null, \_PhpScoper5ea00cc67502b\Memcached::OPT_SERIALIZER => \_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_PHP]; + private $client; + private $lazyClient; + public static function isSupported() + { + return \extension_loaded('memcached') && \version_compare(\phpversion('memcached'), '2.2.0', '>='); + } + private function init(\_PhpScoper5ea00cc67502b\Memcached $client, $namespace, $defaultLifetime) + { + if (!static::isSupported()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('Memcached >= 2.2.0 is required.'); + } + if ('Memcached' === \get_class($client)) { + $opt = $client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_SERIALIZER); + if (\_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_PHP !== $opt && \_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_IGBINARY !== $opt) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('MemcachedAdapter: "serializer" option must be "php" or "igbinary".'); + } + $this->maxIdLength -= \strlen($client->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_PREFIX_KEY)); + $this->client = $client; + } else { + $this->lazyClient = $client; + } + parent::__construct($namespace, $defaultLifetime); + $this->enableVersioning(); + } + /** + * Creates a Memcached instance. + * + * By default, the binary protocol, no block, and libketama compatible options are enabled. + * + * Examples for servers: + * - 'memcached://user:pass@localhost?weight=33' + * - [['localhost', 11211, 33]] + * + * @param array[]|string|string[] $servers An array of servers, a DSN, or an array of DSNs + * @param array $options An array of options + * + * @return \Memcached + * + * @throws \ErrorException When invalid options or servers are provided + */ + public static function createConnection($servers, array $options = []) + { + if (\is_string($servers)) { + $servers = [$servers]; + } elseif (!\is_array($servers)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('MemcachedAdapter::createClient() expects array or string as first argument, "%s" given.', \gettype($servers))); + } + if (!static::isSupported()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('Memcached >= 2.2.0 is required.'); + } + \set_error_handler(function ($type, $msg, $file, $line) { + throw new \ErrorException($msg, 0, $type, $file, $line); + }); + try { + $options += static::$defaultClientOptions; + $client = new \_PhpScoper5ea00cc67502b\Memcached($options['persistent_id']); + $username = $options['username']; + $password = $options['password']; + // parse any DSN in $servers + foreach ($servers as $i => $dsn) { + if (\is_array($dsn)) { + continue; + } + if (0 !== \strpos($dsn, 'memcached://')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Memcached DSN: "%s" does not start with "memcached://".', $dsn)); + } + $params = \preg_replace_callback('#^memcached://(?:([^@]*+)@)?#', function ($m) use(&$username, &$password) { + if (!empty($m[1])) { + list($username, $password) = \explode(':', $m[1], 2) + [1 => null]; + } + return 'file://'; + }, $dsn); + if (\false === ($params = \parse_url($params))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Memcached DSN: "%s".', $dsn)); + } + if (!isset($params['host']) && !isset($params['path'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Memcached DSN: "%s".', $dsn)); + } + if (isset($params['path']) && \preg_match('#/(\\d+)$#', $params['path'], $m)) { + $params['weight'] = $m[1]; + $params['path'] = \substr($params['path'], 0, -\strlen($m[0])); + } + $params += ['host' => isset($params['host']) ? $params['host'] : $params['path'], 'port' => isset($params['host']) ? 11211 : null, 'weight' => 0]; + if (isset($params['query'])) { + \parse_str($params['query'], $query); + $params += $query; + $options = $query + $options; + } + $servers[$i] = [$params['host'], $params['port'], $params['weight']]; + } + // set client's options + unset($options['persistent_id'], $options['username'], $options['password'], $options['weight'], $options['lazy']); + $options = \array_change_key_case($options, \CASE_UPPER); + $client->setOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_BINARY_PROTOCOL, \true); + $client->setOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_NO_BLOCK, \true); + $client->setOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_TCP_NODELAY, \true); + if (!\array_key_exists('LIBKETAMA_COMPATIBLE', $options) && !\array_key_exists(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE, $options)) { + $client->setOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_LIBKETAMA_COMPATIBLE, \true); + } + foreach ($options as $name => $value) { + if (\is_int($name)) { + continue; + } + if ('HASH' === $name || 'SERIALIZER' === $name || 'DISTRIBUTION' === $name) { + $value = \constant('Memcached::' . $name . '_' . \strtoupper($value)); + } + $opt = \constant('Memcached::OPT_' . $name); + unset($options[$name]); + $options[$opt] = $value; + } + $client->setOptions($options); + // set client's servers, taking care of persistent connections + if (!$client->isPristine()) { + $oldServers = []; + foreach ($client->getServerList() as $server) { + $oldServers[] = [$server['host'], $server['port']]; + } + $newServers = []; + foreach ($servers as $server) { + if (1 < \count($server)) { + $server = \array_values($server); + unset($server[2]); + $server[1] = (int) $server[1]; + } + $newServers[] = $server; + } + if ($oldServers !== $newServers) { + $client->resetServerList(); + $client->addServers($servers); + } + } else { + $client->addServers($servers); + } + if (null !== $username || null !== $password) { + if (!\method_exists($client, 'setSaslAuthData')) { + \trigger_error('Missing SASL support: the memcached extension must be compiled with --enable-memcached-sasl.'); + } + $client->setSaslAuthData($username, $password); + } + return $client; + } finally { + \restore_error_handler(); + } + } + /** + * {@inheritdoc} + */ + protected function doSave(array $values, $lifetime) + { + if ($lifetime && $lifetime > 30 * 86400) { + $lifetime += \time(); + } + $encodedValues = []; + foreach ($values as $key => $value) { + $encodedValues[\rawurlencode($key)] = $value; + } + return $this->checkResultCode($this->getClient()->setMulti($encodedValues, $lifetime)); + } + /** + * {@inheritdoc} + */ + protected function doFetch(array $ids) + { + $unserializeCallbackHandler = \ini_set('unserialize_callback_func', __CLASS__ . '::handleUnserializeCallback'); + try { + $encodedIds = \array_map('rawurlencode', $ids); + $encodedResult = $this->checkResultCode($this->getClient()->getMulti($encodedIds)); + $result = []; + foreach ($encodedResult as $key => $value) { + $result[\rawurldecode($key)] = $value; + } + return $result; + } catch (\Error $e) { + throw new \ErrorException($e->getMessage(), $e->getCode(), \E_ERROR, $e->getFile(), $e->getLine()); + } finally { + \ini_set('unserialize_callback_func', $unserializeCallbackHandler); + } + } + /** + * {@inheritdoc} + */ + protected function doHave($id) + { + return \false !== $this->getClient()->get(\rawurlencode($id)) || $this->checkResultCode(\_PhpScoper5ea00cc67502b\Memcached::RES_SUCCESS === $this->client->getResultCode()); + } + /** + * {@inheritdoc} + */ + protected function doDelete(array $ids) + { + $ok = \true; + $encodedIds = \array_map('rawurlencode', $ids); + foreach ($this->checkResultCode($this->getClient()->deleteMulti($encodedIds)) as $result) { + if (\_PhpScoper5ea00cc67502b\Memcached::RES_SUCCESS !== $result && \_PhpScoper5ea00cc67502b\Memcached::RES_NOTFOUND !== $result) { + $ok = \false; + break; + } + } + return $ok; + } + /** + * {@inheritdoc} + */ + protected function doClear($namespace) + { + return '' === $namespace && $this->getClient()->flush(); + } + private function checkResultCode($result) + { + $code = $this->client->getResultCode(); + if (\_PhpScoper5ea00cc67502b\Memcached::RES_SUCCESS === $code || \_PhpScoper5ea00cc67502b\Memcached::RES_NOTFOUND === $code) { + return $result; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException(\sprintf('MemcachedAdapter client error: %s.', \strtolower($this->client->getResultMessage()))); + } + /** + * @return \Memcached + */ + private function getClient() + { + if ($this->client) { + return $this->client; + } + $opt = $this->lazyClient->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_SERIALIZER); + if (\_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_PHP !== $opt && \_PhpScoper5ea00cc67502b\Memcached::SERIALIZER_IGBINARY !== $opt) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException('MemcachedAdapter: "serializer" option must be "php" or "igbinary".'); + } + if ('' !== ($prefix = (string) $this->lazyClient->getOption(\_PhpScoper5ea00cc67502b\Memcached::OPT_PREFIX_KEY))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException(\sprintf('MemcachedAdapter: "prefix_key" option must be empty when using proxified connections, "%s" given.', $prefix)); + } + return $this->client = $this->lazyClient; + } +} diff --git a/vendor/symfony/cache/Traits/PdoTrait.php b/vendor/symfony/cache/Traits/PdoTrait.php index 89c98afce..ce917343b 100644 --- a/vendor/symfony/cache/Traits/PdoTrait.php +++ b/vendor/symfony/cache/Traits/PdoTrait.php @@ -1,347 +1,347 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Doctrine\DBAL\Connection; -use _PhpScoper5ea00cc67502b\Doctrine\DBAL\DBALException; -use _PhpScoper5ea00cc67502b\Doctrine\DBAL\Driver\ServerInfoAwareConnection; -use _PhpScoper5ea00cc67502b\Doctrine\DBAL\Schema\Schema; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -/** - * @internal - */ -trait PdoTrait -{ - private $conn; - private $dsn; - private $driver; - private $serverVersion; - private $table = 'cache_items'; - private $idCol = 'item_id'; - private $dataCol = 'item_data'; - private $lifetimeCol = 'item_lifetime'; - private $timeCol = 'item_time'; - private $username = ''; - private $password = ''; - private $connectionOptions = []; - private $namespace; - private function init($connOrDsn, $namespace, $defaultLifetime, array $options) - { - if (isset($namespace[0]) && \preg_match('#[^-+.A-Za-z0-9]#', $namespace, $match)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Namespace contains "%s" but only characters in [-+.A-Za-z0-9] are allowed.', $match[0])); - } - if ($connOrDsn instanceof \PDO) { - if (\PDO::ERRMODE_EXCEPTION !== $connOrDsn->getAttribute(\PDO::ATTR_ERRMODE)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('"%s" requires PDO error mode attribute be set to throw Exceptions (i.e. $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION)).', __CLASS__)); - } - $this->conn = $connOrDsn; - } elseif ($connOrDsn instanceof \_PhpScoper5ea00cc67502b\Doctrine\DBAL\Connection) { - $this->conn = $connOrDsn; - } elseif (\is_string($connOrDsn)) { - $this->dsn = $connOrDsn; - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('"%s" requires PDO or Doctrine\\DBAL\\Connection instance or DSN string as first argument, "%s" given.', __CLASS__, \is_object($connOrDsn) ? \get_class($connOrDsn) : \gettype($connOrDsn))); - } - $this->table = isset($options['db_table']) ? $options['db_table'] : $this->table; - $this->idCol = isset($options['db_id_col']) ? $options['db_id_col'] : $this->idCol; - $this->dataCol = isset($options['db_data_col']) ? $options['db_data_col'] : $this->dataCol; - $this->lifetimeCol = isset($options['db_lifetime_col']) ? $options['db_lifetime_col'] : $this->lifetimeCol; - $this->timeCol = isset($options['db_time_col']) ? $options['db_time_col'] : $this->timeCol; - $this->username = isset($options['db_username']) ? $options['db_username'] : $this->username; - $this->password = isset($options['db_password']) ? $options['db_password'] : $this->password; - $this->connectionOptions = isset($options['db_connection_options']) ? $options['db_connection_options'] : $this->connectionOptions; - $this->namespace = $namespace; - parent::__construct($namespace, $defaultLifetime); - } - /** - * Creates the table to store cache items which can be called once for setup. - * - * Cache ID are saved in a column of maximum length 255. Cache data is - * saved in a BLOB. - * - * @throws \PDOException When the table already exists - * @throws DBALException When the table already exists - * @throws \DomainException When an unsupported PDO driver is used - */ - public function createTable() - { - // connect if we are not yet - $conn = $this->getConnection(); - if ($conn instanceof \_PhpScoper5ea00cc67502b\Doctrine\DBAL\Connection) { - $types = ['mysql' => 'binary', 'sqlite' => 'text', 'pgsql' => 'string', 'oci' => 'string', 'sqlsrv' => 'string']; - if (!isset($types[$this->driver])) { - throw new \DomainException(\sprintf('Creating the cache table is currently not implemented for PDO driver "%s".', $this->driver)); - } - $schema = new \_PhpScoper5ea00cc67502b\Doctrine\DBAL\Schema\Schema(); - $table = $schema->createTable($this->table); - $table->addColumn($this->idCol, $types[$this->driver], ['length' => 255]); - $table->addColumn($this->dataCol, 'blob', ['length' => 16777215]); - $table->addColumn($this->lifetimeCol, 'integer', ['unsigned' => \true, 'notnull' => \false]); - $table->addColumn($this->timeCol, 'integer', ['unsigned' => \true]); - $table->setPrimaryKey([$this->idCol]); - foreach ($schema->toSql($conn->getDatabasePlatform()) as $sql) { - $conn->exec($sql); - } - return; - } - switch ($this->driver) { - case 'mysql': - // We use varbinary for the ID column because it prevents unwanted conversions: - // - character set conversions between server and client - // - trailing space removal - // - case-insensitivity - // - language processing like é == e - $sql = "CREATE TABLE {$this->table} ({$this->idCol} VARBINARY(255) NOT NULL PRIMARY KEY, {$this->dataCol} MEDIUMBLOB NOT NULL, {$this->lifetimeCol} INTEGER UNSIGNED, {$this->timeCol} INTEGER UNSIGNED NOT NULL) COLLATE utf8_bin, ENGINE = InnoDB"; - break; - case 'sqlite': - $sql = "CREATE TABLE {$this->table} ({$this->idCol} TEXT NOT NULL PRIMARY KEY, {$this->dataCol} BLOB NOT NULL, {$this->lifetimeCol} INTEGER, {$this->timeCol} INTEGER NOT NULL)"; - break; - case 'pgsql': - $sql = "CREATE TABLE {$this->table} ({$this->idCol} VARCHAR(255) NOT NULL PRIMARY KEY, {$this->dataCol} BYTEA NOT NULL, {$this->lifetimeCol} INTEGER, {$this->timeCol} INTEGER NOT NULL)"; - break; - case 'oci': - $sql = "CREATE TABLE {$this->table} ({$this->idCol} VARCHAR2(255) NOT NULL PRIMARY KEY, {$this->dataCol} BLOB NOT NULL, {$this->lifetimeCol} INTEGER, {$this->timeCol} INTEGER NOT NULL)"; - break; - case 'sqlsrv': - $sql = "CREATE TABLE {$this->table} ({$this->idCol} VARCHAR(255) NOT NULL PRIMARY KEY, {$this->dataCol} VARBINARY(MAX) NOT NULL, {$this->lifetimeCol} INTEGER, {$this->timeCol} INTEGER NOT NULL)"; - break; - default: - throw new \DomainException(\sprintf('Creating the cache table is currently not implemented for PDO driver "%s".', $this->driver)); - } - $conn->exec($sql); - } - /** - * {@inheritdoc} - */ - public function prune() - { - $deleteSql = "DELETE FROM {$this->table} WHERE {$this->lifetimeCol} + {$this->timeCol} <= :time"; - if ('' !== $this->namespace) { - $deleteSql .= " AND {$this->idCol} LIKE :namespace"; - } - $delete = $this->getConnection()->prepare($deleteSql); - $delete->bindValue(':time', \time(), \PDO::PARAM_INT); - if ('' !== $this->namespace) { - $delete->bindValue(':namespace', \sprintf('%s%%', $this->namespace), \PDO::PARAM_STR); - } - return $delete->execute(); - } - /** - * {@inheritdoc} - */ - protected function doFetch(array $ids) - { - $now = \time(); - $expired = []; - $sql = \str_pad('', (\count($ids) << 1) - 1, '?,'); - $sql = "SELECT {$this->idCol}, CASE WHEN {$this->lifetimeCol} IS NULL OR {$this->lifetimeCol} + {$this->timeCol} > ? THEN {$this->dataCol} ELSE NULL END FROM {$this->table} WHERE {$this->idCol} IN ({$sql})"; - $stmt = $this->getConnection()->prepare($sql); - $stmt->bindValue($i = 1, $now, \PDO::PARAM_INT); - foreach ($ids as $id) { - $stmt->bindValue(++$i, $id); - } - $stmt->execute(); - while ($row = $stmt->fetch(\PDO::FETCH_NUM)) { - if (null === $row[1]) { - $expired[] = $row[0]; - } else { - (yield $row[0] => parent::unserialize(\is_resource($row[1]) ? \stream_get_contents($row[1]) : $row[1])); - } - } - if ($expired) { - $sql = \str_pad('', (\count($expired) << 1) - 1, '?,'); - $sql = "DELETE FROM {$this->table} WHERE {$this->lifetimeCol} + {$this->timeCol} <= ? AND {$this->idCol} IN ({$sql})"; - $stmt = $this->getConnection()->prepare($sql); - $stmt->bindValue($i = 1, $now, \PDO::PARAM_INT); - foreach ($expired as $id) { - $stmt->bindValue(++$i, $id); - } - $stmt->execute(); - } - } - /** - * {@inheritdoc} - */ - protected function doHave($id) - { - $sql = "SELECT 1 FROM {$this->table} WHERE {$this->idCol} = :id AND ({$this->lifetimeCol} IS NULL OR {$this->lifetimeCol} + {$this->timeCol} > :time)"; - $stmt = $this->getConnection()->prepare($sql); - $stmt->bindValue(':id', $id); - $stmt->bindValue(':time', \time(), \PDO::PARAM_INT); - $stmt->execute(); - return (bool) $stmt->fetchColumn(); - } - /** - * {@inheritdoc} - */ - protected function doClear($namespace) - { - $conn = $this->getConnection(); - if ('' === $namespace) { - if ('sqlite' === $this->driver) { - $sql = "DELETE FROM {$this->table}"; - } else { - $sql = "TRUNCATE TABLE {$this->table}"; - } - } else { - $sql = "DELETE FROM {$this->table} WHERE {$this->idCol} LIKE '{$namespace}%'"; - } - $conn->exec($sql); - return \true; - } - /** - * {@inheritdoc} - */ - protected function doDelete(array $ids) - { - $sql = \str_pad('', (\count($ids) << 1) - 1, '?,'); - $sql = "DELETE FROM {$this->table} WHERE {$this->idCol} IN ({$sql})"; - $stmt = $this->getConnection()->prepare($sql); - $stmt->execute(\array_values($ids)); - return \true; - } - /** - * {@inheritdoc} - */ - protected function doSave(array $values, $lifetime) - { - $serialized = []; - $failed = []; - foreach ($values as $id => $value) { - try { - $serialized[$id] = \serialize($value); - } catch (\Exception $e) { - $failed[] = $id; - } - } - if (!$serialized) { - return $failed; - } - $conn = $this->getConnection(); - $driver = $this->driver; - $insertSql = "INSERT INTO {$this->table} ({$this->idCol}, {$this->dataCol}, {$this->lifetimeCol}, {$this->timeCol}) VALUES (:id, :data, :lifetime, :time)"; - switch (\true) { - case 'mysql' === $driver: - $sql = $insertSql . " ON DUPLICATE KEY UPDATE {$this->dataCol} = VALUES({$this->dataCol}), {$this->lifetimeCol} = VALUES({$this->lifetimeCol}), {$this->timeCol} = VALUES({$this->timeCol})"; - break; - case 'oci' === $driver: - // DUAL is Oracle specific dummy table - $sql = "MERGE INTO {$this->table} USING DUAL ON ({$this->idCol} = ?) " . "WHEN NOT MATCHED THEN INSERT ({$this->idCol}, {$this->dataCol}, {$this->lifetimeCol}, {$this->timeCol}) VALUES (?, ?, ?, ?) " . "WHEN MATCHED THEN UPDATE SET {$this->dataCol} = ?, {$this->lifetimeCol} = ?, {$this->timeCol} = ?"; - break; - case 'sqlsrv' === $driver && \version_compare($this->getServerVersion(), '10', '>='): - // MERGE is only available since SQL Server 2008 and must be terminated by semicolon - // It also requires HOLDLOCK according to http://weblogs.sqlteam.com/dang/archive/2009/01/31/UPSERT-Race-Condition-With-MERGE.aspx - $sql = "MERGE INTO {$this->table} WITH (HOLDLOCK) USING (SELECT 1 AS dummy) AS src ON ({$this->idCol} = ?) " . "WHEN NOT MATCHED THEN INSERT ({$this->idCol}, {$this->dataCol}, {$this->lifetimeCol}, {$this->timeCol}) VALUES (?, ?, ?, ?) " . "WHEN MATCHED THEN UPDATE SET {$this->dataCol} = ?, {$this->lifetimeCol} = ?, {$this->timeCol} = ?;"; - break; - case 'sqlite' === $driver: - $sql = 'INSERT OR REPLACE' . \substr($insertSql, 6); - break; - case 'pgsql' === $driver && \version_compare($this->getServerVersion(), '9.5', '>='): - $sql = $insertSql . " ON CONFLICT ({$this->idCol}) DO UPDATE SET ({$this->dataCol}, {$this->lifetimeCol}, {$this->timeCol}) = (EXCLUDED.{$this->dataCol}, EXCLUDED.{$this->lifetimeCol}, EXCLUDED.{$this->timeCol})"; - break; - default: - $driver = null; - $sql = "UPDATE {$this->table} SET {$this->dataCol} = :data, {$this->lifetimeCol} = :lifetime, {$this->timeCol} = :time WHERE {$this->idCol} = :id"; - break; - } - $now = \time(); - $lifetime = $lifetime ?: null; - $stmt = $conn->prepare($sql); - if ('sqlsrv' === $driver || 'oci' === $driver) { - $stmt->bindParam(1, $id); - $stmt->bindParam(2, $id); - $stmt->bindParam(3, $data, \PDO::PARAM_LOB); - $stmt->bindValue(4, $lifetime, \PDO::PARAM_INT); - $stmt->bindValue(5, $now, \PDO::PARAM_INT); - $stmt->bindParam(6, $data, \PDO::PARAM_LOB); - $stmt->bindValue(7, $lifetime, \PDO::PARAM_INT); - $stmt->bindValue(8, $now, \PDO::PARAM_INT); - } else { - $stmt->bindParam(':id', $id); - $stmt->bindParam(':data', $data, \PDO::PARAM_LOB); - $stmt->bindValue(':lifetime', $lifetime, \PDO::PARAM_INT); - $stmt->bindValue(':time', $now, \PDO::PARAM_INT); - } - if (null === $driver) { - $insertStmt = $conn->prepare($insertSql); - $insertStmt->bindParam(':id', $id); - $insertStmt->bindParam(':data', $data, \PDO::PARAM_LOB); - $insertStmt->bindValue(':lifetime', $lifetime, \PDO::PARAM_INT); - $insertStmt->bindValue(':time', $now, \PDO::PARAM_INT); - } - foreach ($serialized as $id => $data) { - $stmt->execute(); - if (null === $driver && !$stmt->rowCount()) { - try { - $insertStmt->execute(); - } catch (\_PhpScoper5ea00cc67502b\Doctrine\DBAL\DBALException $e) { - } catch (\PDOException $e) { - // A concurrent write won, let it be - } - } - } - return $failed; - } - /** - * @return \PDO|Connection - */ - private function getConnection() - { - if (null === $this->conn) { - $this->conn = new \PDO($this->dsn, $this->username, $this->password, $this->connectionOptions); - $this->conn->setAttribute(\PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION); - } - if (null === $this->driver) { - if ($this->conn instanceof \PDO) { - $this->driver = $this->conn->getAttribute(\PDO::ATTR_DRIVER_NAME); - } else { - switch ($this->driver = $this->conn->getDriver()->getName()) { - case 'mysqli': - case 'pdo_mysql': - case 'drizzle_pdo_mysql': - $this->driver = 'mysql'; - break; - case 'pdo_sqlite': - $this->driver = 'sqlite'; - break; - case 'pdo_pgsql': - $this->driver = 'pgsql'; - break; - case 'oci8': - case 'pdo_oracle': - $this->driver = 'oci'; - break; - case 'pdo_sqlsrv': - $this->driver = 'sqlsrv'; - break; - } - } - } - return $this->conn; - } - /** - * @return string - */ - private function getServerVersion() - { - if (null === $this->serverVersion) { - $conn = $this->conn instanceof \PDO ? $this->conn : $this->conn->getWrappedConnection(); - if ($conn instanceof \PDO) { - $this->serverVersion = $conn->getAttribute(\PDO::ATTR_SERVER_VERSION); - } elseif ($conn instanceof \_PhpScoper5ea00cc67502b\Doctrine\DBAL\Driver\ServerInfoAwareConnection) { - $this->serverVersion = $conn->getServerVersion(); - } else { - $this->serverVersion = '0'; - } - } - return $this->serverVersion; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Doctrine\DBAL\Connection; +use _PhpScoper5ea00cc67502b\Doctrine\DBAL\DBALException; +use _PhpScoper5ea00cc67502b\Doctrine\DBAL\Driver\ServerInfoAwareConnection; +use _PhpScoper5ea00cc67502b\Doctrine\DBAL\Schema\Schema; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +/** + * @internal + */ +trait PdoTrait +{ + private $conn; + private $dsn; + private $driver; + private $serverVersion; + private $table = 'cache_items'; + private $idCol = 'item_id'; + private $dataCol = 'item_data'; + private $lifetimeCol = 'item_lifetime'; + private $timeCol = 'item_time'; + private $username = ''; + private $password = ''; + private $connectionOptions = []; + private $namespace; + private function init($connOrDsn, $namespace, $defaultLifetime, array $options) + { + if (isset($namespace[0]) && \preg_match('#[^-+.A-Za-z0-9]#', $namespace, $match)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Namespace contains "%s" but only characters in [-+.A-Za-z0-9] are allowed.', $match[0])); + } + if ($connOrDsn instanceof \PDO) { + if (\PDO::ERRMODE_EXCEPTION !== $connOrDsn->getAttribute(\PDO::ATTR_ERRMODE)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('"%s" requires PDO error mode attribute be set to throw Exceptions (i.e. $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION)).', __CLASS__)); + } + $this->conn = $connOrDsn; + } elseif ($connOrDsn instanceof \_PhpScoper5ea00cc67502b\Doctrine\DBAL\Connection) { + $this->conn = $connOrDsn; + } elseif (\is_string($connOrDsn)) { + $this->dsn = $connOrDsn; + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('"%s" requires PDO or Doctrine\\DBAL\\Connection instance or DSN string as first argument, "%s" given.', __CLASS__, \is_object($connOrDsn) ? \get_class($connOrDsn) : \gettype($connOrDsn))); + } + $this->table = isset($options['db_table']) ? $options['db_table'] : $this->table; + $this->idCol = isset($options['db_id_col']) ? $options['db_id_col'] : $this->idCol; + $this->dataCol = isset($options['db_data_col']) ? $options['db_data_col'] : $this->dataCol; + $this->lifetimeCol = isset($options['db_lifetime_col']) ? $options['db_lifetime_col'] : $this->lifetimeCol; + $this->timeCol = isset($options['db_time_col']) ? $options['db_time_col'] : $this->timeCol; + $this->username = isset($options['db_username']) ? $options['db_username'] : $this->username; + $this->password = isset($options['db_password']) ? $options['db_password'] : $this->password; + $this->connectionOptions = isset($options['db_connection_options']) ? $options['db_connection_options'] : $this->connectionOptions; + $this->namespace = $namespace; + parent::__construct($namespace, $defaultLifetime); + } + /** + * Creates the table to store cache items which can be called once for setup. + * + * Cache ID are saved in a column of maximum length 255. Cache data is + * saved in a BLOB. + * + * @throws \PDOException When the table already exists + * @throws DBALException When the table already exists + * @throws \DomainException When an unsupported PDO driver is used + */ + public function createTable() + { + // connect if we are not yet + $conn = $this->getConnection(); + if ($conn instanceof \_PhpScoper5ea00cc67502b\Doctrine\DBAL\Connection) { + $types = ['mysql' => 'binary', 'sqlite' => 'text', 'pgsql' => 'string', 'oci' => 'string', 'sqlsrv' => 'string']; + if (!isset($types[$this->driver])) { + throw new \DomainException(\sprintf('Creating the cache table is currently not implemented for PDO driver "%s".', $this->driver)); + } + $schema = new \_PhpScoper5ea00cc67502b\Doctrine\DBAL\Schema\Schema(); + $table = $schema->createTable($this->table); + $table->addColumn($this->idCol, $types[$this->driver], ['length' => 255]); + $table->addColumn($this->dataCol, 'blob', ['length' => 16777215]); + $table->addColumn($this->lifetimeCol, 'integer', ['unsigned' => \true, 'notnull' => \false]); + $table->addColumn($this->timeCol, 'integer', ['unsigned' => \true]); + $table->setPrimaryKey([$this->idCol]); + foreach ($schema->toSql($conn->getDatabasePlatform()) as $sql) { + $conn->exec($sql); + } + return; + } + switch ($this->driver) { + case 'mysql': + // We use varbinary for the ID column because it prevents unwanted conversions: + // - character set conversions between server and client + // - trailing space removal + // - case-insensitivity + // - language processing like é == e + $sql = "CREATE TABLE {$this->table} ({$this->idCol} VARBINARY(255) NOT NULL PRIMARY KEY, {$this->dataCol} MEDIUMBLOB NOT NULL, {$this->lifetimeCol} INTEGER UNSIGNED, {$this->timeCol} INTEGER UNSIGNED NOT NULL) COLLATE utf8_bin, ENGINE = InnoDB"; + break; + case 'sqlite': + $sql = "CREATE TABLE {$this->table} ({$this->idCol} TEXT NOT NULL PRIMARY KEY, {$this->dataCol} BLOB NOT NULL, {$this->lifetimeCol} INTEGER, {$this->timeCol} INTEGER NOT NULL)"; + break; + case 'pgsql': + $sql = "CREATE TABLE {$this->table} ({$this->idCol} VARCHAR(255) NOT NULL PRIMARY KEY, {$this->dataCol} BYTEA NOT NULL, {$this->lifetimeCol} INTEGER, {$this->timeCol} INTEGER NOT NULL)"; + break; + case 'oci': + $sql = "CREATE TABLE {$this->table} ({$this->idCol} VARCHAR2(255) NOT NULL PRIMARY KEY, {$this->dataCol} BLOB NOT NULL, {$this->lifetimeCol} INTEGER, {$this->timeCol} INTEGER NOT NULL)"; + break; + case 'sqlsrv': + $sql = "CREATE TABLE {$this->table} ({$this->idCol} VARCHAR(255) NOT NULL PRIMARY KEY, {$this->dataCol} VARBINARY(MAX) NOT NULL, {$this->lifetimeCol} INTEGER, {$this->timeCol} INTEGER NOT NULL)"; + break; + default: + throw new \DomainException(\sprintf('Creating the cache table is currently not implemented for PDO driver "%s".', $this->driver)); + } + $conn->exec($sql); + } + /** + * {@inheritdoc} + */ + public function prune() + { + $deleteSql = "DELETE FROM {$this->table} WHERE {$this->lifetimeCol} + {$this->timeCol} <= :time"; + if ('' !== $this->namespace) { + $deleteSql .= " AND {$this->idCol} LIKE :namespace"; + } + $delete = $this->getConnection()->prepare($deleteSql); + $delete->bindValue(':time', \time(), \PDO::PARAM_INT); + if ('' !== $this->namespace) { + $delete->bindValue(':namespace', \sprintf('%s%%', $this->namespace), \PDO::PARAM_STR); + } + return $delete->execute(); + } + /** + * {@inheritdoc} + */ + protected function doFetch(array $ids) + { + $now = \time(); + $expired = []; + $sql = \str_pad('', (\count($ids) << 1) - 1, '?,'); + $sql = "SELECT {$this->idCol}, CASE WHEN {$this->lifetimeCol} IS NULL OR {$this->lifetimeCol} + {$this->timeCol} > ? THEN {$this->dataCol} ELSE NULL END FROM {$this->table} WHERE {$this->idCol} IN ({$sql})"; + $stmt = $this->getConnection()->prepare($sql); + $stmt->bindValue($i = 1, $now, \PDO::PARAM_INT); + foreach ($ids as $id) { + $stmt->bindValue(++$i, $id); + } + $stmt->execute(); + while ($row = $stmt->fetch(\PDO::FETCH_NUM)) { + if (null === $row[1]) { + $expired[] = $row[0]; + } else { + (yield $row[0] => parent::unserialize(\is_resource($row[1]) ? \stream_get_contents($row[1]) : $row[1])); + } + } + if ($expired) { + $sql = \str_pad('', (\count($expired) << 1) - 1, '?,'); + $sql = "DELETE FROM {$this->table} WHERE {$this->lifetimeCol} + {$this->timeCol} <= ? AND {$this->idCol} IN ({$sql})"; + $stmt = $this->getConnection()->prepare($sql); + $stmt->bindValue($i = 1, $now, \PDO::PARAM_INT); + foreach ($expired as $id) { + $stmt->bindValue(++$i, $id); + } + $stmt->execute(); + } + } + /** + * {@inheritdoc} + */ + protected function doHave($id) + { + $sql = "SELECT 1 FROM {$this->table} WHERE {$this->idCol} = :id AND ({$this->lifetimeCol} IS NULL OR {$this->lifetimeCol} + {$this->timeCol} > :time)"; + $stmt = $this->getConnection()->prepare($sql); + $stmt->bindValue(':id', $id); + $stmt->bindValue(':time', \time(), \PDO::PARAM_INT); + $stmt->execute(); + return (bool) $stmt->fetchColumn(); + } + /** + * {@inheritdoc} + */ + protected function doClear($namespace) + { + $conn = $this->getConnection(); + if ('' === $namespace) { + if ('sqlite' === $this->driver) { + $sql = "DELETE FROM {$this->table}"; + } else { + $sql = "TRUNCATE TABLE {$this->table}"; + } + } else { + $sql = "DELETE FROM {$this->table} WHERE {$this->idCol} LIKE '{$namespace}%'"; + } + $conn->exec($sql); + return \true; + } + /** + * {@inheritdoc} + */ + protected function doDelete(array $ids) + { + $sql = \str_pad('', (\count($ids) << 1) - 1, '?,'); + $sql = "DELETE FROM {$this->table} WHERE {$this->idCol} IN ({$sql})"; + $stmt = $this->getConnection()->prepare($sql); + $stmt->execute(\array_values($ids)); + return \true; + } + /** + * {@inheritdoc} + */ + protected function doSave(array $values, $lifetime) + { + $serialized = []; + $failed = []; + foreach ($values as $id => $value) { + try { + $serialized[$id] = \serialize($value); + } catch (\Exception $e) { + $failed[] = $id; + } + } + if (!$serialized) { + return $failed; + } + $conn = $this->getConnection(); + $driver = $this->driver; + $insertSql = "INSERT INTO {$this->table} ({$this->idCol}, {$this->dataCol}, {$this->lifetimeCol}, {$this->timeCol}) VALUES (:id, :data, :lifetime, :time)"; + switch (\true) { + case 'mysql' === $driver: + $sql = $insertSql . " ON DUPLICATE KEY UPDATE {$this->dataCol} = VALUES({$this->dataCol}), {$this->lifetimeCol} = VALUES({$this->lifetimeCol}), {$this->timeCol} = VALUES({$this->timeCol})"; + break; + case 'oci' === $driver: + // DUAL is Oracle specific dummy table + $sql = "MERGE INTO {$this->table} USING DUAL ON ({$this->idCol} = ?) " . "WHEN NOT MATCHED THEN INSERT ({$this->idCol}, {$this->dataCol}, {$this->lifetimeCol}, {$this->timeCol}) VALUES (?, ?, ?, ?) " . "WHEN MATCHED THEN UPDATE SET {$this->dataCol} = ?, {$this->lifetimeCol} = ?, {$this->timeCol} = ?"; + break; + case 'sqlsrv' === $driver && \version_compare($this->getServerVersion(), '10', '>='): + // MERGE is only available since SQL Server 2008 and must be terminated by semicolon + // It also requires HOLDLOCK according to http://weblogs.sqlteam.com/dang/archive/2009/01/31/UPSERT-Race-Condition-With-MERGE.aspx + $sql = "MERGE INTO {$this->table} WITH (HOLDLOCK) USING (SELECT 1 AS dummy) AS src ON ({$this->idCol} = ?) " . "WHEN NOT MATCHED THEN INSERT ({$this->idCol}, {$this->dataCol}, {$this->lifetimeCol}, {$this->timeCol}) VALUES (?, ?, ?, ?) " . "WHEN MATCHED THEN UPDATE SET {$this->dataCol} = ?, {$this->lifetimeCol} = ?, {$this->timeCol} = ?;"; + break; + case 'sqlite' === $driver: + $sql = 'INSERT OR REPLACE' . \substr($insertSql, 6); + break; + case 'pgsql' === $driver && \version_compare($this->getServerVersion(), '9.5', '>='): + $sql = $insertSql . " ON CONFLICT ({$this->idCol}) DO UPDATE SET ({$this->dataCol}, {$this->lifetimeCol}, {$this->timeCol}) = (EXCLUDED.{$this->dataCol}, EXCLUDED.{$this->lifetimeCol}, EXCLUDED.{$this->timeCol})"; + break; + default: + $driver = null; + $sql = "UPDATE {$this->table} SET {$this->dataCol} = :data, {$this->lifetimeCol} = :lifetime, {$this->timeCol} = :time WHERE {$this->idCol} = :id"; + break; + } + $now = \time(); + $lifetime = $lifetime ?: null; + $stmt = $conn->prepare($sql); + if ('sqlsrv' === $driver || 'oci' === $driver) { + $stmt->bindParam(1, $id); + $stmt->bindParam(2, $id); + $stmt->bindParam(3, $data, \PDO::PARAM_LOB); + $stmt->bindValue(4, $lifetime, \PDO::PARAM_INT); + $stmt->bindValue(5, $now, \PDO::PARAM_INT); + $stmt->bindParam(6, $data, \PDO::PARAM_LOB); + $stmt->bindValue(7, $lifetime, \PDO::PARAM_INT); + $stmt->bindValue(8, $now, \PDO::PARAM_INT); + } else { + $stmt->bindParam(':id', $id); + $stmt->bindParam(':data', $data, \PDO::PARAM_LOB); + $stmt->bindValue(':lifetime', $lifetime, \PDO::PARAM_INT); + $stmt->bindValue(':time', $now, \PDO::PARAM_INT); + } + if (null === $driver) { + $insertStmt = $conn->prepare($insertSql); + $insertStmt->bindParam(':id', $id); + $insertStmt->bindParam(':data', $data, \PDO::PARAM_LOB); + $insertStmt->bindValue(':lifetime', $lifetime, \PDO::PARAM_INT); + $insertStmt->bindValue(':time', $now, \PDO::PARAM_INT); + } + foreach ($serialized as $id => $data) { + $stmt->execute(); + if (null === $driver && !$stmt->rowCount()) { + try { + $insertStmt->execute(); + } catch (\_PhpScoper5ea00cc67502b\Doctrine\DBAL\DBALException $e) { + } catch (\PDOException $e) { + // A concurrent write won, let it be + } + } + } + return $failed; + } + /** + * @return \PDO|Connection + */ + private function getConnection() + { + if (null === $this->conn) { + $this->conn = new \PDO($this->dsn, $this->username, $this->password, $this->connectionOptions); + $this->conn->setAttribute(\PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION); + } + if (null === $this->driver) { + if ($this->conn instanceof \PDO) { + $this->driver = $this->conn->getAttribute(\PDO::ATTR_DRIVER_NAME); + } else { + switch ($this->driver = $this->conn->getDriver()->getName()) { + case 'mysqli': + case 'pdo_mysql': + case 'drizzle_pdo_mysql': + $this->driver = 'mysql'; + break; + case 'pdo_sqlite': + $this->driver = 'sqlite'; + break; + case 'pdo_pgsql': + $this->driver = 'pgsql'; + break; + case 'oci8': + case 'pdo_oracle': + $this->driver = 'oci'; + break; + case 'pdo_sqlsrv': + $this->driver = 'sqlsrv'; + break; + } + } + } + return $this->conn; + } + /** + * @return string + */ + private function getServerVersion() + { + if (null === $this->serverVersion) { + $conn = $this->conn instanceof \PDO ? $this->conn : $this->conn->getWrappedConnection(); + if ($conn instanceof \PDO) { + $this->serverVersion = $conn->getAttribute(\PDO::ATTR_SERVER_VERSION); + } elseif ($conn instanceof \_PhpScoper5ea00cc67502b\Doctrine\DBAL\Driver\ServerInfoAwareConnection) { + $this->serverVersion = $conn->getServerVersion(); + } else { + $this->serverVersion = '0'; + } + } + return $this->serverVersion; + } +} diff --git a/vendor/symfony/cache/Traits/PhpArrayTrait.php b/vendor/symfony/cache/Traits/PhpArrayTrait.php index 314392b5b..060339c9e 100644 --- a/vendor/symfony/cache/Traits/PhpArrayTrait.php +++ b/vendor/symfony/cache/Traits/PhpArrayTrait.php @@ -1,129 +1,129 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -/** - * @author Titouan Galopin - * @author Nicolas Grekas - * - * @internal - */ -trait PhpArrayTrait -{ - use ProxyTrait; - private $file; - private $values; - private $zendDetectUnicode; - private static $valuesCache = []; - /** - * Store an array of cached values. - * - * @param array $values The cached values - */ - public function warmUp(array $values) - { - if (\file_exists($this->file)) { - if (!\is_file($this->file)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache path exists and is not a file: "%s".', $this->file)); - } - if (!\is_writable($this->file)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache file is not writable: "%s".', $this->file)); - } - } else { - $directory = \dirname($this->file); - if (!\is_dir($directory) && !@\mkdir($directory, 0777, \true)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache directory does not exist and cannot be created: "%s".', $directory)); - } - if (!\is_writable($directory)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache directory is not writable: "%s".', $directory)); - } - } - $dump = <<<'EOF' - $value) { - \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey(\is_int($key) ? (string) $key : $key); - if (null === $value || \is_object($value)) { - try { - $value = \serialize($value); - } catch (\Exception $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key "%s" has non-serializable "%s" value.', $key, \get_class($value)), 0, $e); - } - } elseif (\is_array($value)) { - try { - $serialized = \serialize($value); - $unserialized = \unserialize($serialized); - } catch (\Exception $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key "%s" has non-serializable array value.', $key), 0, $e); - } - // Store arrays serialized if they contain any objects or references - if ($unserialized !== $value || \false !== \strpos($serialized, ';R:') && \preg_match('/;R:[1-9]/', $serialized)) { - $value = $serialized; - } - } elseif (\is_string($value)) { - // Serialize strings if they could be confused with serialized objects or arrays - if ('N;' === $value || isset($value[2]) && ':' === $value[1]) { - $value = \serialize($value); - } - } elseif (!\is_scalar($value)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key "%s" has non-serializable "%s" value.', $key, \gettype($value))); - } - $dump .= \var_export($key, \true) . ' => ' . \var_export($value, \true) . ",\n"; - } - $dump .= "\n];\n"; - $dump = \str_replace("' . \"\\0\" . '", "\0", $dump); - $tmpFile = \uniqid($this->file, \true); - \file_put_contents($tmpFile, $dump); - @\chmod($tmpFile, 0666 & ~\umask()); - unset($serialized, $unserialized, $value, $dump); - @\rename($tmpFile, $this->file); - unset(self::$valuesCache[$this->file]); - $this->initialize(); - } - /** - * {@inheritdoc} - */ - public function clear() - { - $this->values = []; - $cleared = @\unlink($this->file) || !\file_exists($this->file); - unset(self::$valuesCache[$this->file]); - return $this->pool->clear() && $cleared; - } - /** - * Load the cache file. - */ - private function initialize() - { - if (isset(self::$valuesCache[$this->file])) { - $this->values = self::$valuesCache[$this->file]; - return; - } - if ($this->zendDetectUnicode) { - $zmb = \ini_set('zend.detect_unicode', 0); - } - try { - $this->values = self::$valuesCache[$this->file] = \file_exists($this->file) ? include $this->file ?: [] : []; - } finally { - if ($this->zendDetectUnicode) { - \ini_set('zend.detect_unicode', $zmb); - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +/** + * @author Titouan Galopin + * @author Nicolas Grekas + * + * @internal + */ +trait PhpArrayTrait +{ + use ProxyTrait; + private $file; + private $values; + private $zendDetectUnicode; + private static $valuesCache = []; + /** + * Store an array of cached values. + * + * @param array $values The cached values + */ + public function warmUp(array $values) + { + if (\file_exists($this->file)) { + if (!\is_file($this->file)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache path exists and is not a file: "%s".', $this->file)); + } + if (!\is_writable($this->file)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache file is not writable: "%s".', $this->file)); + } + } else { + $directory = \dirname($this->file); + if (!\is_dir($directory) && !@\mkdir($directory, 0777, \true)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache directory does not exist and cannot be created: "%s".', $directory)); + } + if (!\is_writable($directory)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache directory is not writable: "%s".', $directory)); + } + } + $dump = <<<'EOF' + $value) { + \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::validateKey(\is_int($key) ? (string) $key : $key); + if (null === $value || \is_object($value)) { + try { + $value = \serialize($value); + } catch (\Exception $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key "%s" has non-serializable "%s" value.', $key, \get_class($value)), 0, $e); + } + } elseif (\is_array($value)) { + try { + $serialized = \serialize($value); + $unserialized = \unserialize($serialized); + } catch (\Exception $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key "%s" has non-serializable array value.', $key), 0, $e); + } + // Store arrays serialized if they contain any objects or references + if ($unserialized !== $value || \false !== \strpos($serialized, ';R:') && \preg_match('/;R:[1-9]/', $serialized)) { + $value = $serialized; + } + } elseif (\is_string($value)) { + // Serialize strings if they could be confused with serialized objects or arrays + if ('N;' === $value || isset($value[2]) && ':' === $value[1]) { + $value = \serialize($value); + } + } elseif (!\is_scalar($value)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key "%s" has non-serializable "%s" value.', $key, \gettype($value))); + } + $dump .= \var_export($key, \true) . ' => ' . \var_export($value, \true) . ",\n"; + } + $dump .= "\n];\n"; + $dump = \str_replace("' . \"\\0\" . '", "\0", $dump); + $tmpFile = \uniqid($this->file, \true); + \file_put_contents($tmpFile, $dump); + @\chmod($tmpFile, 0666 & ~\umask()); + unset($serialized, $unserialized, $value, $dump); + @\rename($tmpFile, $this->file); + unset(self::$valuesCache[$this->file]); + $this->initialize(); + } + /** + * {@inheritdoc} + */ + public function clear() + { + $this->values = []; + $cleared = @\unlink($this->file) || !\file_exists($this->file); + unset(self::$valuesCache[$this->file]); + return $this->pool->clear() && $cleared; + } + /** + * Load the cache file. + */ + private function initialize() + { + if (isset(self::$valuesCache[$this->file])) { + $this->values = self::$valuesCache[$this->file]; + return; + } + if ($this->zendDetectUnicode) { + $zmb = \ini_set('zend.detect_unicode', 0); + } + try { + $this->values = self::$valuesCache[$this->file] = \file_exists($this->file) ? include $this->file ?: [] : []; + } finally { + if ($this->zendDetectUnicode) { + \ini_set('zend.detect_unicode', $zmb); + } + } + } +} diff --git a/vendor/symfony/cache/Traits/PhpFilesTrait.php b/vendor/symfony/cache/Traits/PhpFilesTrait.php index bbd2276a5..a0e4918a7 100644 --- a/vendor/symfony/cache/Traits/PhpFilesTrait.php +++ b/vendor/symfony/cache/Traits/PhpFilesTrait.php @@ -1,138 +1,138 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -/** - * @author Piotr Stankowski - * @author Nicolas Grekas - * @author Rob Frawley 2nd - * - * @internal - */ -trait PhpFilesTrait -{ - use FilesystemCommonTrait; - private $includeHandler; - private $zendDetectUnicode; - public static function isSupported() - { - return \function_exists('opcache_invalidate') && \filter_var(\ini_get('opcache.enable'), \FILTER_VALIDATE_BOOLEAN); - } - /** - * @return bool - */ - public function prune() - { - $time = \time(); - $pruned = \true; - $allowCompile = 'cli' !== \PHP_SAPI || \filter_var(\ini_get('opcache.enable_cli'), \FILTER_VALIDATE_BOOLEAN); - \set_error_handler($this->includeHandler); - try { - foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($this->directory, \FilesystemIterator::SKIP_DOTS), \RecursiveIteratorIterator::LEAVES_ONLY) as $file) { - list($expiresAt) = (include $file); - if ($time >= $expiresAt) { - $pruned = @\unlink($file) && !\file_exists($file) && $pruned; - if ($allowCompile) { - @\opcache_invalidate($file, \true); - } - } - } - } finally { - \restore_error_handler(); - } - return $pruned; - } - /** - * {@inheritdoc} - */ - protected function doFetch(array $ids) - { - $values = []; - $now = \time(); - if ($this->zendDetectUnicode) { - $zmb = \ini_set('zend.detect_unicode', 0); - } - \set_error_handler($this->includeHandler); - try { - foreach ($ids as $id) { - try { - $file = $this->getFile($id); - list($expiresAt, $values[$id]) = (include $file); - if ($now >= $expiresAt) { - unset($values[$id]); - } - } catch (\Exception $e) { - continue; - } - } - } finally { - \restore_error_handler(); - if ($this->zendDetectUnicode) { - \ini_set('zend.detect_unicode', $zmb); - } - } - foreach ($values as $id => $value) { - if ('N;' === $value) { - $values[$id] = null; - } elseif (\is_string($value) && isset($value[2]) && ':' === $value[1]) { - $values[$id] = parent::unserialize($value); - } - } - return $values; - } - /** - * {@inheritdoc} - */ - protected function doHave($id) - { - return (bool) $this->doFetch([$id]); - } - /** - * {@inheritdoc} - */ - protected function doSave(array $values, $lifetime) - { - $ok = \true; - $data = [$lifetime ? \time() + $lifetime : \PHP_INT_MAX, '']; - $allowCompile = 'cli' !== \PHP_SAPI || \filter_var(\ini_get('opcache.enable_cli'), \FILTER_VALIDATE_BOOLEAN); - foreach ($values as $key => $value) { - if (null === $value || \is_object($value)) { - $value = \serialize($value); - } elseif (\is_array($value)) { - $serialized = \serialize($value); - $unserialized = parent::unserialize($serialized); - // Store arrays serialized if they contain any objects or references - if ($unserialized !== $value || \false !== \strpos($serialized, ';R:') && \preg_match('/;R:[1-9]/', $serialized)) { - $value = $serialized; - } - } elseif (\is_string($value)) { - // Serialize strings if they could be confused with serialized objects or arrays - if ('N;' === $value || isset($value[2]) && ':' === $value[1]) { - $value = \serialize($value); - } - } elseif (!\is_scalar($value)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key "%s" has non-serializable "%s" value.', $key, \gettype($value))); - } - $data[1] = $value; - $file = $this->getFile($key, \true); - $ok = $this->write($file, 'directory)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException(\sprintf('Cache directory is not writable (%s).', $this->directory)); - } - return $ok; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +/** + * @author Piotr Stankowski + * @author Nicolas Grekas + * @author Rob Frawley 2nd + * + * @internal + */ +trait PhpFilesTrait +{ + use FilesystemCommonTrait; + private $includeHandler; + private $zendDetectUnicode; + public static function isSupported() + { + return \function_exists('opcache_invalidate') && \filter_var(\ini_get('opcache.enable'), \FILTER_VALIDATE_BOOLEAN); + } + /** + * @return bool + */ + public function prune() + { + $time = \time(); + $pruned = \true; + $allowCompile = 'cli' !== \PHP_SAPI || \filter_var(\ini_get('opcache.enable_cli'), \FILTER_VALIDATE_BOOLEAN); + \set_error_handler($this->includeHandler); + try { + foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($this->directory, \FilesystemIterator::SKIP_DOTS), \RecursiveIteratorIterator::LEAVES_ONLY) as $file) { + list($expiresAt) = (include $file); + if ($time >= $expiresAt) { + $pruned = @\unlink($file) && !\file_exists($file) && $pruned; + if ($allowCompile) { + @\opcache_invalidate($file, \true); + } + } + } + } finally { + \restore_error_handler(); + } + return $pruned; + } + /** + * {@inheritdoc} + */ + protected function doFetch(array $ids) + { + $values = []; + $now = \time(); + if ($this->zendDetectUnicode) { + $zmb = \ini_set('zend.detect_unicode', 0); + } + \set_error_handler($this->includeHandler); + try { + foreach ($ids as $id) { + try { + $file = $this->getFile($id); + list($expiresAt, $values[$id]) = (include $file); + if ($now >= $expiresAt) { + unset($values[$id]); + } + } catch (\Exception $e) { + continue; + } + } + } finally { + \restore_error_handler(); + if ($this->zendDetectUnicode) { + \ini_set('zend.detect_unicode', $zmb); + } + } + foreach ($values as $id => $value) { + if ('N;' === $value) { + $values[$id] = null; + } elseif (\is_string($value) && isset($value[2]) && ':' === $value[1]) { + $values[$id] = parent::unserialize($value); + } + } + return $values; + } + /** + * {@inheritdoc} + */ + protected function doHave($id) + { + return (bool) $this->doFetch([$id]); + } + /** + * {@inheritdoc} + */ + protected function doSave(array $values, $lifetime) + { + $ok = \true; + $data = [$lifetime ? \time() + $lifetime : \PHP_INT_MAX, '']; + $allowCompile = 'cli' !== \PHP_SAPI || \filter_var(\ini_get('opcache.enable_cli'), \FILTER_VALIDATE_BOOLEAN); + foreach ($values as $key => $value) { + if (null === $value || \is_object($value)) { + $value = \serialize($value); + } elseif (\is_array($value)) { + $serialized = \serialize($value); + $unserialized = parent::unserialize($serialized); + // Store arrays serialized if they contain any objects or references + if ($unserialized !== $value || \false !== \strpos($serialized, ';R:') && \preg_match('/;R:[1-9]/', $serialized)) { + $value = $serialized; + } + } elseif (\is_string($value)) { + // Serialize strings if they could be confused with serialized objects or arrays + if ('N;' === $value || isset($value[2]) && ':' === $value[1]) { + $value = \serialize($value); + } + } elseif (!\is_scalar($value)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Cache key "%s" has non-serializable "%s" value.', $key, \gettype($value))); + } + $data[1] = $value; + $file = $this->getFile($key, \true); + $ok = $this->write($file, 'directory)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException(\sprintf('Cache directory is not writable (%s).', $this->directory)); + } + return $ok; + } +} diff --git a/vendor/symfony/cache/Traits/ProxyTrait.php b/vendor/symfony/cache/Traits/ProxyTrait.php index d11047857..00289d8fd 100644 --- a/vendor/symfony/cache/Traits/ProxyTrait.php +++ b/vendor/symfony/cache/Traits/ProxyTrait.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; -/** - * @author Nicolas Grekas - * - * @internal - */ -trait ProxyTrait -{ - private $pool; - /** - * {@inheritdoc} - */ - public function prune() - { - return $this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface && $this->pool->prune(); - } - /** - * {@inheritdoc} - */ - public function reset() - { - if ($this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { - $this->pool->reset(); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface; +/** + * @author Nicolas Grekas + * + * @internal + */ +trait ProxyTrait +{ + private $pool; + /** + * {@inheritdoc} + */ + public function prune() + { + return $this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\PruneableInterface && $this->pool->prune(); + } + /** + * {@inheritdoc} + */ + public function reset() + { + if ($this->pool instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\ResettableInterface) { + $this->pool->reset(); + } + } +} diff --git a/vendor/symfony/cache/Traits/RedisProxy.php b/vendor/symfony/cache/Traits/RedisProxy.php index 045e018bb..ebca929e7 100644 --- a/vendor/symfony/cache/Traits/RedisProxy.php +++ b/vendor/symfony/cache/Traits/RedisProxy.php @@ -1,53 +1,53 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -/** - * @author Nicolas Grekas - * - * @internal - */ -class RedisProxy -{ - private $redis; - private $initializer; - private $ready = \false; - public function __construct(\_PhpScoper5ea00cc67502b\Redis $redis, \Closure $initializer) - { - $this->redis = $redis; - $this->initializer = $initializer; - } - public function __call($method, array $args) - { - $this->ready ?: ($this->ready = $this->initializer->__invoke($this->redis)); - return \call_user_func_array([$this->redis, $method], $args); - } - public function hscan($strKey, &$iIterator, $strPattern = null, $iCount = null) - { - $this->ready ?: ($this->ready = $this->initializer->__invoke($this->redis)); - return $this->redis->hscan($strKey, $iIterator, $strPattern, $iCount); - } - public function scan(&$iIterator, $strPattern = null, $iCount = null) - { - $this->ready ?: ($this->ready = $this->initializer->__invoke($this->redis)); - return $this->redis->scan($iIterator, $strPattern, $iCount); - } - public function sscan($strKey, &$iIterator, $strPattern = null, $iCount = null) - { - $this->ready ?: ($this->ready = $this->initializer->__invoke($this->redis)); - return $this->redis->sscan($strKey, $iIterator, $strPattern, $iCount); - } - public function zscan($strKey, &$iIterator, $strPattern = null, $iCount = null) - { - $this->ready ?: ($this->ready = $this->initializer->__invoke($this->redis)); - return $this->redis->zscan($strKey, $iIterator, $strPattern, $iCount); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +/** + * @author Nicolas Grekas + * + * @internal + */ +class RedisProxy +{ + private $redis; + private $initializer; + private $ready = \false; + public function __construct(\_PhpScoper5ea00cc67502b\Redis $redis, \Closure $initializer) + { + $this->redis = $redis; + $this->initializer = $initializer; + } + public function __call($method, array $args) + { + $this->ready ?: ($this->ready = $this->initializer->__invoke($this->redis)); + return \call_user_func_array([$this->redis, $method], $args); + } + public function hscan($strKey, &$iIterator, $strPattern = null, $iCount = null) + { + $this->ready ?: ($this->ready = $this->initializer->__invoke($this->redis)); + return $this->redis->hscan($strKey, $iIterator, $strPattern, $iCount); + } + public function scan(&$iIterator, $strPattern = null, $iCount = null) + { + $this->ready ?: ($this->ready = $this->initializer->__invoke($this->redis)); + return $this->redis->scan($iIterator, $strPattern, $iCount); + } + public function sscan($strKey, &$iIterator, $strPattern = null, $iCount = null) + { + $this->ready ?: ($this->ready = $this->initializer->__invoke($this->redis)); + return $this->redis->sscan($strKey, $iIterator, $strPattern, $iCount); + } + public function zscan($strKey, &$iIterator, $strPattern = null, $iCount = null) + { + $this->ready ?: ($this->ready = $this->initializer->__invoke($this->redis)); + return $this->redis->zscan($strKey, $iIterator, $strPattern, $iCount); + } +} diff --git a/vendor/symfony/cache/Traits/RedisTrait.php b/vendor/symfony/cache/Traits/RedisTrait.php index 812929b34..8cd98cd86 100644 --- a/vendor/symfony/cache/Traits/RedisTrait.php +++ b/vendor/symfony/cache/Traits/RedisTrait.php @@ -1,330 +1,330 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; - -use _PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\ClusterInterface; -use _PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\RedisCluster; -use _PhpScoper5ea00cc67502b\Predis\Connection\Factory; -use _PhpScoper5ea00cc67502b\Predis\Response\Status; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; -/** - * @author Aurimas Niekis - * @author Nicolas Grekas - * - * @internal - */ -trait RedisTrait -{ - private static $defaultConnectionOptions = ['class' => null, 'persistent' => 0, 'persistent_id' => null, 'timeout' => 30, 'read_timeout' => 0, 'retry_interval' => 0, 'lazy' => \false]; - private $redis; - /** - * @param \Redis|\RedisArray|\RedisCluster|\Predis\Client $redisClient - */ - private function init($redisClient, $namespace = '', $defaultLifetime = 0) - { - parent::__construct($namespace, $defaultLifetime); - if (\preg_match('#[^-+_.A-Za-z0-9]#', $namespace, $match)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('RedisAdapter namespace contains "%s" but only characters in [-+_.A-Za-z0-9] are allowed.', $match[0])); - } - if (!$redisClient instanceof \_PhpScoper5ea00cc67502b\Redis && !$redisClient instanceof \_PhpScoper5ea00cc67502b\RedisArray && !$redisClient instanceof \_PhpScoper5ea00cc67502b\RedisCluster && !$redisClient instanceof \_PhpScoper5ea00cc67502b\Predis\Client && !$redisClient instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisProxy) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('"%s()" expects parameter 1 to be Redis, RedisArray, RedisCluster or Predis\\Client, "%s" given.', __METHOD__, \is_object($redisClient) ? \get_class($redisClient) : \gettype($redisClient))); - } - $this->redis = $redisClient; - } - /** - * Creates a Redis connection using a DSN configuration. - * - * Example DSN: - * - redis://localhost - * - redis://example.com:1234 - * - redis://secret@example.com/13 - * - redis:///var/run/redis.sock - * - redis://secret@/var/run/redis.sock/13 - * - * @param string $dsn - * @param array $options See self::$defaultConnectionOptions - * - * @throws InvalidArgumentException when the DSN is invalid - * - * @return \Redis|\Predis\Client According to the "class" option - */ - public static function createConnection($dsn, array $options = []) - { - if (0 !== \strpos($dsn, 'redis://')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Redis DSN: "%s" does not start with "redis://".', $dsn)); - } - $params = \preg_replace_callback('#^redis://(?:(?:[^:@]*+:)?([^@]*+)@)?#', function ($m) use(&$auth) { - if (isset($m[1])) { - $auth = $m[1]; - } - return 'file://'; - }, $dsn); - if (\false === ($params = \parse_url($params))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Redis DSN: "%s".', $dsn)); - } - if (!isset($params['host']) && !isset($params['path'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Redis DSN: "%s".', $dsn)); - } - if (isset($params['path']) && \preg_match('#/(\\d+)$#', $params['path'], $m)) { - $params['dbindex'] = $m[1]; - $params['path'] = \substr($params['path'], 0, -\strlen($m[0])); - } - if (isset($params['host'])) { - $scheme = 'tcp'; - } else { - $scheme = 'unix'; - } - $params += ['host' => isset($params['host']) ? $params['host'] : $params['path'], 'port' => isset($params['host']) ? 6379 : null, 'dbindex' => 0]; - if (isset($params['query'])) { - \parse_str($params['query'], $query); - $params += $query; - } - $params += $options + self::$defaultConnectionOptions; - if (null === $params['class'] && !\extension_loaded('redis') && !\class_exists(\_PhpScoper5ea00cc67502b\Predis\Client::class)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException(\sprintf('Cannot find the "redis" extension, and "predis/predis" is not installed: "%s".', $dsn)); - } - $class = null === $params['class'] ? \extension_loaded('redis') ? \_PhpScoper5ea00cc67502b\Redis::class : \_PhpScoper5ea00cc67502b\Predis\Client::class : $params['class']; - if (\is_a($class, \_PhpScoper5ea00cc67502b\Redis::class, \true)) { - $connect = $params['persistent'] || $params['persistent_id'] ? 'pconnect' : 'connect'; - $redis = new $class(); - $initializer = function ($redis) use($connect, $params, $dsn, $auth) { - try { - @$redis->{$connect}($params['host'], $params['port'], $params['timeout'], $params['persistent_id'], $params['retry_interval']); - } catch (\_PhpScoper5ea00cc67502b\RedisException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Redis connection failed (%s): "%s".', $e->getMessage(), $dsn)); - } - \set_error_handler(function ($type, $msg) use(&$error) { - $error = $msg; - }); - $isConnected = $redis->isConnected(); - \restore_error_handler(); - if (!$isConnected) { - $error = \preg_match('/^Redis::p?connect\\(\\): (.*)/', $error, $error) ? \sprintf(' (%s)', $error[1]) : ''; - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Redis connection failed%s: "%s".', $error, $dsn)); - } - if (null !== $auth && !$redis->auth($auth) || $params['dbindex'] && !$redis->select($params['dbindex']) || $params['read_timeout'] && !$redis->setOption(\_PhpScoper5ea00cc67502b\Redis::OPT_READ_TIMEOUT, $params['read_timeout'])) { - $e = \preg_replace('/^ERR /', '', $redis->getLastError()); - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Redis connection failed (%s): "%s".', $e, $dsn)); - } - return \true; - }; - if ($params['lazy']) { - $redis = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisProxy($redis, $initializer); - } else { - $initializer($redis); - } - } elseif (\is_a($class, \_PhpScoper5ea00cc67502b\Predis\Client::class, \true)) { - $params['scheme'] = $scheme; - $params['database'] = $params['dbindex'] ?: null; - $params['password'] = $auth; - $redis = new $class((new \_PhpScoper5ea00cc67502b\Predis\Connection\Factory())->create($params)); - } elseif (\class_exists($class, \false)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('"%s" is not a subclass of "Redis" or "Predis\\Client".', $class)); - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Class "%s" does not exist.', $class)); - } - return $redis; - } - /** - * {@inheritdoc} - */ - protected function doFetch(array $ids) - { - if (!$ids) { - return []; - } - $result = []; - if ($this->redis instanceof \_PhpScoper5ea00cc67502b\Predis\Client && $this->redis->getConnection() instanceof \_PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\ClusterInterface) { - $values = $this->pipeline(function () use($ids) { - foreach ($ids as $id) { - (yield 'get' => [$id]); - } - }); - } else { - $values = $this->redis->mget($ids); - if (!\is_array($values) || \count($values) !== \count($ids)) { - return []; - } - $values = \array_combine($ids, $values); - } - foreach ($values as $id => $v) { - if ($v) { - $result[$id] = parent::unserialize($v); - } - } - return $result; - } - /** - * {@inheritdoc} - */ - protected function doHave($id) - { - return (bool) $this->redis->exists($id); - } - /** - * {@inheritdoc} - */ - protected function doClear($namespace) - { - $cleared = \true; - $hosts = [$this->redis]; - $evalArgs = [[$namespace], 0]; - if ($this->redis instanceof \_PhpScoper5ea00cc67502b\Predis\Client) { - $evalArgs = [0, $namespace]; - $connection = $this->redis->getConnection(); - if ($connection instanceof \_PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\ClusterInterface && $connection instanceof \Traversable) { - $hosts = []; - foreach ($connection as $c) { - $hosts[] = new \_PhpScoper5ea00cc67502b\Predis\Client($c); - } - } - } elseif ($this->redis instanceof \_PhpScoper5ea00cc67502b\RedisArray) { - $hosts = []; - foreach ($this->redis->_hosts() as $host) { - $hosts[] = $this->redis->_instance($host); - } - } elseif ($this->redis instanceof \_PhpScoper5ea00cc67502b\RedisCluster) { - $hosts = []; - foreach ($this->redis->_masters() as $host) { - $hosts[] = $h = new \_PhpScoper5ea00cc67502b\Redis(); - $h->connect($host[0], $host[1]); - } - } - foreach ($hosts as $host) { - if (!isset($namespace[0])) { - $cleared = $host->flushDb() && $cleared; - continue; - } - $info = $host->info('Server'); - $info = isset($info['Server']) ? $info['Server'] : $info; - if (!\version_compare($info['redis_version'], '2.8', '>=')) { - // As documented in Redis documentation (http://redis.io/commands/keys) using KEYS - // can hang your server when it is executed against large databases (millions of items). - // Whenever you hit this scale, you should really consider upgrading to Redis 2.8 or above. - $cleared = $host->eval("local keys=redis.call('KEYS',ARGV[1]..'*') for i=1,#keys,5000 do redis.call('DEL',unpack(keys,i,math.min(i+4999,#keys))) end return 1", $evalArgs[0], $evalArgs[1]) && $cleared; - continue; - } - $cursor = null; - do { - $keys = $host instanceof \_PhpScoper5ea00cc67502b\Predis\Client ? $host->scan($cursor, 'MATCH', $namespace . '*', 'COUNT', 1000) : $host->scan($cursor, $namespace . '*', 1000); - if (isset($keys[1]) && \is_array($keys[1])) { - $cursor = $keys[0]; - $keys = $keys[1]; - } - if ($keys) { - $this->doDelete($keys); - } - } while ($cursor = (int) $cursor); - } - return $cleared; - } - /** - * {@inheritdoc} - */ - protected function doDelete(array $ids) - { - if (!$ids) { - return \true; - } - if ($this->redis instanceof \_PhpScoper5ea00cc67502b\Predis\Client && $this->redis->getConnection() instanceof \_PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\ClusterInterface) { - $this->pipeline(function () use($ids) { - foreach ($ids as $id) { - (yield 'del' => [$id]); - } - })->rewind(); - } else { - $this->redis->del($ids); - } - return \true; - } - /** - * {@inheritdoc} - */ - protected function doSave(array $values, $lifetime) - { - $serialized = []; - $failed = []; - foreach ($values as $id => $value) { - try { - $serialized[$id] = \serialize($value); - } catch (\Exception $e) { - $failed[] = $id; - } - } - if (!$serialized) { - return $failed; - } - $results = $this->pipeline(function () use($serialized, $lifetime) { - foreach ($serialized as $id => $value) { - if (0 >= $lifetime) { - (yield 'set' => [$id, $value]); - } else { - (yield 'setEx' => [$id, $lifetime, $value]); - } - } - }); - foreach ($results as $id => $result) { - if (\true !== $result && (!$result instanceof \_PhpScoper5ea00cc67502b\Predis\Response\Status || $result !== \_PhpScoper5ea00cc67502b\Predis\Response\Status::get('OK'))) { - $failed[] = $id; - } - } - return $failed; - } - private function pipeline(\Closure $generator) - { - $ids = []; - if ($this->redis instanceof \_PhpScoper5ea00cc67502b\RedisCluster || $this->redis instanceof \_PhpScoper5ea00cc67502b\Predis\Client && $this->redis->getConnection() instanceof \_PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\RedisCluster) { - // phpredis & predis don't support pipelining with RedisCluster - // see https://github.com/phpredis/phpredis/blob/develop/cluster.markdown#pipelining - // see https://github.com/nrk/predis/issues/267#issuecomment-123781423 - $results = []; - foreach ($generator() as $command => $args) { - $results[] = \call_user_func_array([$this->redis, $command], $args); - $ids[] = $args[0]; - } - } elseif ($this->redis instanceof \_PhpScoper5ea00cc67502b\Predis\Client) { - $results = $this->redis->pipeline(function ($redis) use($generator, &$ids) { - foreach ($generator() as $command => $args) { - \call_user_func_array([$redis, $command], $args); - $ids[] = $args[0]; - } - }); - } elseif ($this->redis instanceof \_PhpScoper5ea00cc67502b\RedisArray) { - $connections = $results = $ids = []; - foreach ($generator() as $command => $args) { - if (!isset($connections[$h = $this->redis->_target($args[0])])) { - $connections[$h] = [$this->redis->_instance($h), -1]; - $connections[$h][0]->multi(\_PhpScoper5ea00cc67502b\Redis::PIPELINE); - } - \call_user_func_array([$connections[$h][0], $command], $args); - $results[] = [$h, ++$connections[$h][1]]; - $ids[] = $args[0]; - } - foreach ($connections as $h => $c) { - $connections[$h] = $c[0]->exec(); - } - foreach ($results as $k => list($h, $c)) { - $results[$k] = $connections[$h][$c]; - } - } else { - $this->redis->multi(\_PhpScoper5ea00cc67502b\Redis::PIPELINE); - foreach ($generator() as $command => $args) { - \call_user_func_array([$this->redis, $command], $args); - $ids[] = $args[0]; - } - $results = $this->redis->exec(); - } - foreach ($ids as $k => $id) { - (yield $id => $results[$k]); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits; + +use _PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\ClusterInterface; +use _PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\RedisCluster; +use _PhpScoper5ea00cc67502b\Predis\Connection\Factory; +use _PhpScoper5ea00cc67502b\Predis\Response\Status; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException; +/** + * @author Aurimas Niekis + * @author Nicolas Grekas + * + * @internal + */ +trait RedisTrait +{ + private static $defaultConnectionOptions = ['class' => null, 'persistent' => 0, 'persistent_id' => null, 'timeout' => 30, 'read_timeout' => 0, 'retry_interval' => 0, 'lazy' => \false]; + private $redis; + /** + * @param \Redis|\RedisArray|\RedisCluster|\Predis\Client $redisClient + */ + private function init($redisClient, $namespace = '', $defaultLifetime = 0) + { + parent::__construct($namespace, $defaultLifetime); + if (\preg_match('#[^-+_.A-Za-z0-9]#', $namespace, $match)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('RedisAdapter namespace contains "%s" but only characters in [-+_.A-Za-z0-9] are allowed.', $match[0])); + } + if (!$redisClient instanceof \_PhpScoper5ea00cc67502b\Redis && !$redisClient instanceof \_PhpScoper5ea00cc67502b\RedisArray && !$redisClient instanceof \_PhpScoper5ea00cc67502b\RedisCluster && !$redisClient instanceof \_PhpScoper5ea00cc67502b\Predis\Client && !$redisClient instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisProxy) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('"%s()" expects parameter 1 to be Redis, RedisArray, RedisCluster or Predis\\Client, "%s" given.', __METHOD__, \is_object($redisClient) ? \get_class($redisClient) : \gettype($redisClient))); + } + $this->redis = $redisClient; + } + /** + * Creates a Redis connection using a DSN configuration. + * + * Example DSN: + * - redis://localhost + * - redis://example.com:1234 + * - redis://secret@example.com/13 + * - redis:///var/run/redis.sock + * - redis://secret@/var/run/redis.sock/13 + * + * @param string $dsn + * @param array $options See self::$defaultConnectionOptions + * + * @throws InvalidArgumentException when the DSN is invalid + * + * @return \Redis|\Predis\Client According to the "class" option + */ + public static function createConnection($dsn, array $options = []) + { + if (0 !== \strpos($dsn, 'redis://')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Redis DSN: "%s" does not start with "redis://".', $dsn)); + } + $params = \preg_replace_callback('#^redis://(?:(?:[^:@]*+:)?([^@]*+)@)?#', function ($m) use(&$auth) { + if (isset($m[1])) { + $auth = $m[1]; + } + return 'file://'; + }, $dsn); + if (\false === ($params = \parse_url($params))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Redis DSN: "%s".', $dsn)); + } + if (!isset($params['host']) && !isset($params['path'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Invalid Redis DSN: "%s".', $dsn)); + } + if (isset($params['path']) && \preg_match('#/(\\d+)$#', $params['path'], $m)) { + $params['dbindex'] = $m[1]; + $params['path'] = \substr($params['path'], 0, -\strlen($m[0])); + } + if (isset($params['host'])) { + $scheme = 'tcp'; + } else { + $scheme = 'unix'; + } + $params += ['host' => isset($params['host']) ? $params['host'] : $params['path'], 'port' => isset($params['host']) ? 6379 : null, 'dbindex' => 0]; + if (isset($params['query'])) { + \parse_str($params['query'], $query); + $params += $query; + } + $params += $options + self::$defaultConnectionOptions; + if (null === $params['class'] && !\extension_loaded('redis') && !\class_exists(\_PhpScoper5ea00cc67502b\Predis\Client::class)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\CacheException(\sprintf('Cannot find the "redis" extension, and "predis/predis" is not installed: "%s".', $dsn)); + } + $class = null === $params['class'] ? \extension_loaded('redis') ? \_PhpScoper5ea00cc67502b\Redis::class : \_PhpScoper5ea00cc67502b\Predis\Client::class : $params['class']; + if (\is_a($class, \_PhpScoper5ea00cc67502b\Redis::class, \true)) { + $connect = $params['persistent'] || $params['persistent_id'] ? 'pconnect' : 'connect'; + $redis = new $class(); + $initializer = function ($redis) use($connect, $params, $dsn, $auth) { + try { + @$redis->{$connect}($params['host'], $params['port'], $params['timeout'], $params['persistent_id'], $params['retry_interval']); + } catch (\_PhpScoper5ea00cc67502b\RedisException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Redis connection failed (%s): "%s".', $e->getMessage(), $dsn)); + } + \set_error_handler(function ($type, $msg) use(&$error) { + $error = $msg; + }); + $isConnected = $redis->isConnected(); + \restore_error_handler(); + if (!$isConnected) { + $error = \preg_match('/^Redis::p?connect\\(\\): (.*)/', $error, $error) ? \sprintf(' (%s)', $error[1]) : ''; + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Redis connection failed%s: "%s".', $error, $dsn)); + } + if (null !== $auth && !$redis->auth($auth) || $params['dbindex'] && !$redis->select($params['dbindex']) || $params['read_timeout'] && !$redis->setOption(\_PhpScoper5ea00cc67502b\Redis::OPT_READ_TIMEOUT, $params['read_timeout'])) { + $e = \preg_replace('/^ERR /', '', $redis->getLastError()); + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Redis connection failed (%s): "%s".', $e, $dsn)); + } + return \true; + }; + if ($params['lazy']) { + $redis = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Traits\RedisProxy($redis, $initializer); + } else { + $initializer($redis); + } + } elseif (\is_a($class, \_PhpScoper5ea00cc67502b\Predis\Client::class, \true)) { + $params['scheme'] = $scheme; + $params['database'] = $params['dbindex'] ?: null; + $params['password'] = $auth; + $redis = new $class((new \_PhpScoper5ea00cc67502b\Predis\Connection\Factory())->create($params)); + } elseif (\class_exists($class, \false)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('"%s" is not a subclass of "Redis" or "Predis\\Client".', $class)); + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Exception\InvalidArgumentException(\sprintf('Class "%s" does not exist.', $class)); + } + return $redis; + } + /** + * {@inheritdoc} + */ + protected function doFetch(array $ids) + { + if (!$ids) { + return []; + } + $result = []; + if ($this->redis instanceof \_PhpScoper5ea00cc67502b\Predis\Client && $this->redis->getConnection() instanceof \_PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\ClusterInterface) { + $values = $this->pipeline(function () use($ids) { + foreach ($ids as $id) { + (yield 'get' => [$id]); + } + }); + } else { + $values = $this->redis->mget($ids); + if (!\is_array($values) || \count($values) !== \count($ids)) { + return []; + } + $values = \array_combine($ids, $values); + } + foreach ($values as $id => $v) { + if ($v) { + $result[$id] = parent::unserialize($v); + } + } + return $result; + } + /** + * {@inheritdoc} + */ + protected function doHave($id) + { + return (bool) $this->redis->exists($id); + } + /** + * {@inheritdoc} + */ + protected function doClear($namespace) + { + $cleared = \true; + $hosts = [$this->redis]; + $evalArgs = [[$namespace], 0]; + if ($this->redis instanceof \_PhpScoper5ea00cc67502b\Predis\Client) { + $evalArgs = [0, $namespace]; + $connection = $this->redis->getConnection(); + if ($connection instanceof \_PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\ClusterInterface && $connection instanceof \Traversable) { + $hosts = []; + foreach ($connection as $c) { + $hosts[] = new \_PhpScoper5ea00cc67502b\Predis\Client($c); + } + } + } elseif ($this->redis instanceof \_PhpScoper5ea00cc67502b\RedisArray) { + $hosts = []; + foreach ($this->redis->_hosts() as $host) { + $hosts[] = $this->redis->_instance($host); + } + } elseif ($this->redis instanceof \_PhpScoper5ea00cc67502b\RedisCluster) { + $hosts = []; + foreach ($this->redis->_masters() as $host) { + $hosts[] = $h = new \_PhpScoper5ea00cc67502b\Redis(); + $h->connect($host[0], $host[1]); + } + } + foreach ($hosts as $host) { + if (!isset($namespace[0])) { + $cleared = $host->flushDb() && $cleared; + continue; + } + $info = $host->info('Server'); + $info = isset($info['Server']) ? $info['Server'] : $info; + if (!\version_compare($info['redis_version'], '2.8', '>=')) { + // As documented in Redis documentation (http://redis.io/commands/keys) using KEYS + // can hang your server when it is executed against large databases (millions of items). + // Whenever you hit this scale, you should really consider upgrading to Redis 2.8 or above. + $cleared = $host->eval("local keys=redis.call('KEYS',ARGV[1]..'*') for i=1,#keys,5000 do redis.call('DEL',unpack(keys,i,math.min(i+4999,#keys))) end return 1", $evalArgs[0], $evalArgs[1]) && $cleared; + continue; + } + $cursor = null; + do { + $keys = $host instanceof \_PhpScoper5ea00cc67502b\Predis\Client ? $host->scan($cursor, 'MATCH', $namespace . '*', 'COUNT', 1000) : $host->scan($cursor, $namespace . '*', 1000); + if (isset($keys[1]) && \is_array($keys[1])) { + $cursor = $keys[0]; + $keys = $keys[1]; + } + if ($keys) { + $this->doDelete($keys); + } + } while ($cursor = (int) $cursor); + } + return $cleared; + } + /** + * {@inheritdoc} + */ + protected function doDelete(array $ids) + { + if (!$ids) { + return \true; + } + if ($this->redis instanceof \_PhpScoper5ea00cc67502b\Predis\Client && $this->redis->getConnection() instanceof \_PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\ClusterInterface) { + $this->pipeline(function () use($ids) { + foreach ($ids as $id) { + (yield 'del' => [$id]); + } + })->rewind(); + } else { + $this->redis->del($ids); + } + return \true; + } + /** + * {@inheritdoc} + */ + protected function doSave(array $values, $lifetime) + { + $serialized = []; + $failed = []; + foreach ($values as $id => $value) { + try { + $serialized[$id] = \serialize($value); + } catch (\Exception $e) { + $failed[] = $id; + } + } + if (!$serialized) { + return $failed; + } + $results = $this->pipeline(function () use($serialized, $lifetime) { + foreach ($serialized as $id => $value) { + if (0 >= $lifetime) { + (yield 'set' => [$id, $value]); + } else { + (yield 'setEx' => [$id, $lifetime, $value]); + } + } + }); + foreach ($results as $id => $result) { + if (\true !== $result && (!$result instanceof \_PhpScoper5ea00cc67502b\Predis\Response\Status || $result !== \_PhpScoper5ea00cc67502b\Predis\Response\Status::get('OK'))) { + $failed[] = $id; + } + } + return $failed; + } + private function pipeline(\Closure $generator) + { + $ids = []; + if ($this->redis instanceof \_PhpScoper5ea00cc67502b\RedisCluster || $this->redis instanceof \_PhpScoper5ea00cc67502b\Predis\Client && $this->redis->getConnection() instanceof \_PhpScoper5ea00cc67502b\Predis\Connection\Aggregate\RedisCluster) { + // phpredis & predis don't support pipelining with RedisCluster + // see https://github.com/phpredis/phpredis/blob/develop/cluster.markdown#pipelining + // see https://github.com/nrk/predis/issues/267#issuecomment-123781423 + $results = []; + foreach ($generator() as $command => $args) { + $results[] = \call_user_func_array([$this->redis, $command], $args); + $ids[] = $args[0]; + } + } elseif ($this->redis instanceof \_PhpScoper5ea00cc67502b\Predis\Client) { + $results = $this->redis->pipeline(function ($redis) use($generator, &$ids) { + foreach ($generator() as $command => $args) { + \call_user_func_array([$redis, $command], $args); + $ids[] = $args[0]; + } + }); + } elseif ($this->redis instanceof \_PhpScoper5ea00cc67502b\RedisArray) { + $connections = $results = $ids = []; + foreach ($generator() as $command => $args) { + if (!isset($connections[$h = $this->redis->_target($args[0])])) { + $connections[$h] = [$this->redis->_instance($h), -1]; + $connections[$h][0]->multi(\_PhpScoper5ea00cc67502b\Redis::PIPELINE); + } + \call_user_func_array([$connections[$h][0], $command], $args); + $results[] = [$h, ++$connections[$h][1]]; + $ids[] = $args[0]; + } + foreach ($connections as $h => $c) { + $connections[$h] = $c[0]->exec(); + } + foreach ($results as $k => list($h, $c)) { + $results[$k] = $connections[$h][$c]; + } + } else { + $this->redis->multi(\_PhpScoper5ea00cc67502b\Redis::PIPELINE); + foreach ($generator() as $command => $args) { + \call_user_func_array([$this->redis, $command], $args); + $ids[] = $args[0]; + } + $results = $this->redis->exec(); + } + foreach ($ids as $k => $id) { + (yield $id => $results[$k]); + } + } +} diff --git a/vendor/symfony/cache/Traits/index.php b/vendor/symfony/cache/Traits/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/Traits/index.php +++ b/vendor/symfony/cache/Traits/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/composer.json b/vendor/symfony/cache/composer.json index 4b8a1a17c..e27a4f5dc 100644 --- a/vendor/symfony/cache/composer.json +++ b/vendor/symfony/cache/composer.json @@ -1,55 +1,55 @@ -{ - "name": "symfony\/cache", - "type": "library", - "description": "Symfony Cache component with PSR-6, PSR-16, and tags", - "keywords": [ - "caching", - "psr6" - ], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "provide": { - "psr\/cache-implementation": "1.0", - "psr\/simple-cache-implementation": "1.0" - }, - "require": { - "php": "^5.5.9|>=7.0.8", - "psr\/cache": "~1.0", - "psr\/log": "~1.0", - "psr\/simple-cache": "^1.0", - "symfony\/polyfill-apcu": "~1.1" - }, - "require-dev": { - "cache\/integration-tests": "dev-master", - "doctrine\/cache": "~1.6", - "doctrine\/dbal": "~2.4", - "predis\/predis": "~1.0" - }, - "conflict": { - "symfony\/var-dumper": "<3.3" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\": "" - }, - "exclude-from-classmap": [ - "\/Tests\/" - ] - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - } +{ + "name": "symfony\/cache", + "type": "library", + "description": "Symfony Cache component with PSR-6, PSR-16, and tags", + "keywords": [ + "caching", + "psr6" + ], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "provide": { + "psr\/cache-implementation": "1.0", + "psr\/simple-cache-implementation": "1.0" + }, + "require": { + "php": "^5.5.9|>=7.0.8", + "psr\/cache": "~1.0", + "psr\/log": "~1.0", + "psr\/simple-cache": "^1.0", + "symfony\/polyfill-apcu": "~1.1" + }, + "require-dev": { + "cache\/integration-tests": "dev-master", + "doctrine\/cache": "~1.6", + "doctrine\/dbal": "~2.4", + "predis\/predis": "~1.0" + }, + "conflict": { + "symfony\/var-dumper": "<3.3" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Cache\\": "" + }, + "exclude-from-classmap": [ + "\/Tests\/" + ] + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/cache/index.php b/vendor/symfony/cache/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/cache/index.php +++ b/vendor/symfony/cache/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/cache/phpunit.xml.dist b/vendor/symfony/cache/phpunit.xml.dist index c35458ca4..e00520c33 100644 --- a/vendor/symfony/cache/phpunit.xml.dist +++ b/vendor/symfony/cache/phpunit.xml.dist @@ -1,50 +1,50 @@ - - - - - - - - - - - - ./Tests/ - - - - - - ./ - - ./Tests - ./vendor - - - - - - - - - - - Cache\IntegrationTests - Doctrine\Common\Cache - Symfony\Component\Cache - Symfony\Component\Cache\Tests\Fixtures - Symfony\Component\Cache\Traits - - - - - - - + + + + + + + + + + + + ./Tests/ + + + + + + ./ + + ./Tests + ./vendor + + + + + + + + + + + Cache\IntegrationTests + Doctrine\Common\Cache + Symfony\Component\Cache + Symfony\Component\Cache\Tests\Fixtures + Symfony\Component\Cache\Traits + + + + + + + diff --git a/vendor/symfony/config/.gitignore b/vendor/symfony/config/.gitignore index c49a5d8df..e31d97a46 100644 --- a/vendor/symfony/config/.gitignore +++ b/vendor/symfony/config/.gitignore @@ -1,3 +1,3 @@ -vendor/ -composer.lock -phpunit.xml +vendor/ +composer.lock +phpunit.xml diff --git a/vendor/symfony/config/CHANGELOG.md b/vendor/symfony/config/CHANGELOG.md index 6cb610c47..336fa7cb0 100644 --- a/vendor/symfony/config/CHANGELOG.md +++ b/vendor/symfony/config/CHANGELOG.md @@ -1,78 +1,78 @@ -CHANGELOG -========= - -3.4.0 ------ - - * added `setDeprecated()` method to indicate a deprecated node - * added `XmlUtils::parse()` method to parse an XML string - * deprecated `ConfigCachePass` - -3.3.0 ------ - - * added `ReflectionClassResource` class - * added second `$exists` constructor argument to `ClassExistenceResource` - * made `ClassExistenceResource` work with interfaces and traits - * added `ConfigCachePass` (originally in FrameworkBundle) - * added `castToArray()` helper to turn any config value into an array - -3.0.0 ------ - - * removed `ReferenceDumper` class - * removed the `ResourceInterface::isFresh()` method - * removed `BCResourceInterfaceChecker` class - * removed `ResourceInterface::getResource()` method - -2.8.0 ------ - -The edge case of defining just one value for nodes of type Enum is now allowed: - -```php -$rootNode - ->children() - ->enumNode('variable') - ->values(['value']) - ->end() - ->end() -; -``` - -Before: `InvalidArgumentException` (variable must contain at least two -distinct elements). -After: the code will work as expected and it will restrict the values of the -`variable` option to just `value`. - - * deprecated the `ResourceInterface::isFresh()` method. If you implement custom resource types and they - can be validated that way, make them implement the new `SelfCheckingResourceInterface`. - * deprecated the getResource() method in ResourceInterface. You can still call this method - on concrete classes implementing the interface, but it does not make sense at the interface - level as you need to know about the particular type of resource at hand to understand the - semantics of the returned value. - -2.7.0 ------ - - * added `ConfigCacheInterface`, `ConfigCacheFactoryInterface` and a basic `ConfigCacheFactory` - implementation to delegate creation of ConfigCache instances - -2.2.0 ------ - - * added `ArrayNodeDefinition::canBeEnabled()` and `ArrayNodeDefinition::canBeDisabled()` - to ease configuration when some sections are respectively disabled / enabled - by default. - * added a `normalizeKeys()` method for array nodes (to avoid key normalization) - * added numerical type handling for config definitions - * added convenience methods for optional configuration sections to `ArrayNodeDefinition` - * added a utils class for XML manipulations - -2.1.0 ------ - - * added a way to add documentation on configuration - * implemented `Serializable` on resources - * `LoaderResolverInterface` is now used instead of `LoaderResolver` for type - hinting +CHANGELOG +========= + +3.4.0 +----- + + * added `setDeprecated()` method to indicate a deprecated node + * added `XmlUtils::parse()` method to parse an XML string + * deprecated `ConfigCachePass` + +3.3.0 +----- + + * added `ReflectionClassResource` class + * added second `$exists` constructor argument to `ClassExistenceResource` + * made `ClassExistenceResource` work with interfaces and traits + * added `ConfigCachePass` (originally in FrameworkBundle) + * added `castToArray()` helper to turn any config value into an array + +3.0.0 +----- + + * removed `ReferenceDumper` class + * removed the `ResourceInterface::isFresh()` method + * removed `BCResourceInterfaceChecker` class + * removed `ResourceInterface::getResource()` method + +2.8.0 +----- + +The edge case of defining just one value for nodes of type Enum is now allowed: + +```php +$rootNode + ->children() + ->enumNode('variable') + ->values(['value']) + ->end() + ->end() +; +``` + +Before: `InvalidArgumentException` (variable must contain at least two +distinct elements). +After: the code will work as expected and it will restrict the values of the +`variable` option to just `value`. + + * deprecated the `ResourceInterface::isFresh()` method. If you implement custom resource types and they + can be validated that way, make them implement the new `SelfCheckingResourceInterface`. + * deprecated the getResource() method in ResourceInterface. You can still call this method + on concrete classes implementing the interface, but it does not make sense at the interface + level as you need to know about the particular type of resource at hand to understand the + semantics of the returned value. + +2.7.0 +----- + + * added `ConfigCacheInterface`, `ConfigCacheFactoryInterface` and a basic `ConfigCacheFactory` + implementation to delegate creation of ConfigCache instances + +2.2.0 +----- + + * added `ArrayNodeDefinition::canBeEnabled()` and `ArrayNodeDefinition::canBeDisabled()` + to ease configuration when some sections are respectively disabled / enabled + by default. + * added a `normalizeKeys()` method for array nodes (to avoid key normalization) + * added numerical type handling for config definitions + * added convenience methods for optional configuration sections to `ArrayNodeDefinition` + * added a utils class for XML manipulations + +2.1.0 +----- + + * added a way to add documentation on configuration + * implemented `Serializable` on resources + * `LoaderResolverInterface` is now used instead of `LoaderResolver` for type + hinting diff --git a/vendor/symfony/config/ConfigCache.php b/vendor/symfony/config/ConfigCache.php index b02f637bc..c69569e52 100644 --- a/vendor/symfony/config/ConfigCache.php +++ b/vendor/symfony/config/ConfigCache.php @@ -1,55 +1,55 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceChecker; -/** - * ConfigCache caches arbitrary content in files on disk. - * - * When in debug mode, those metadata resources that implement - * \Symfony\Component\Config\Resource\SelfCheckingResourceInterface will - * be used to check cache freshness. - * - * @author Fabien Potencier - * @author Matthias Pigulla - */ -class ConfigCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache -{ - private $debug; - /** - * @param string $file The absolute cache path - * @param bool $debug Whether debugging is enabled or not - */ - public function __construct($file, $debug) - { - $this->debug = (bool) $debug; - $checkers = []; - if (\true === $this->debug) { - $checkers = [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceChecker()]; - } - parent::__construct($file, $checkers); - } - /** - * Checks if the cache is still fresh. - * - * This implementation always returns true when debug is off and the - * cache file exists. - * - * @return bool true if the cache is fresh, false otherwise - */ - public function isFresh() - { - if (!$this->debug && \is_file($this->getPath())) { - return \true; - } - return parent::isFresh(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceChecker; +/** + * ConfigCache caches arbitrary content in files on disk. + * + * When in debug mode, those metadata resources that implement + * \Symfony\Component\Config\Resource\SelfCheckingResourceInterface will + * be used to check cache freshness. + * + * @author Fabien Potencier + * @author Matthias Pigulla + */ +class ConfigCache extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache +{ + private $debug; + /** + * @param string $file The absolute cache path + * @param bool $debug Whether debugging is enabled or not + */ + public function __construct($file, $debug) + { + $this->debug = (bool) $debug; + $checkers = []; + if (\true === $this->debug) { + $checkers = [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceChecker()]; + } + parent::__construct($file, $checkers); + } + /** + * Checks if the cache is still fresh. + * + * This implementation always returns true when debug is off and the + * cache file exists. + * + * @return bool true if the cache is fresh, false otherwise + */ + public function isFresh() + { + if (!$this->debug && \is_file($this->getPath())) { + return \true; + } + return parent::isFresh(); + } +} diff --git a/vendor/symfony/config/ConfigCacheFactory.php b/vendor/symfony/config/ConfigCacheFactory.php index fed309378..dbc08484a 100644 --- a/vendor/symfony/config/ConfigCacheFactory.php +++ b/vendor/symfony/config/ConfigCacheFactory.php @@ -1,46 +1,46 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; - -/** - * Basic implementation of ConfigCacheFactoryInterface that - * creates an instance of the default ConfigCache. - * - * This factory and/or cache do not support cache validation - * by means of ResourceChecker instances (that is, service-based). - * - * @author Matthias Pigulla - */ -class ConfigCacheFactory implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCacheFactoryInterface -{ - private $debug; - /** - * @param bool $debug The debug flag to pass to ConfigCache - */ - public function __construct($debug) - { - $this->debug = $debug; - } - /** - * {@inheritdoc} - */ - public function cache($file, $callback) - { - if (!\is_callable($callback)) { - throw new \InvalidArgumentException(\sprintf('Invalid type for callback argument. Expected callable, but got "%s".', \gettype($callback))); - } - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($file, $this->debug); - if (!$cache->isFresh()) { - \call_user_func($callback, $cache); - } - return $cache; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; + +/** + * Basic implementation of ConfigCacheFactoryInterface that + * creates an instance of the default ConfigCache. + * + * This factory and/or cache do not support cache validation + * by means of ResourceChecker instances (that is, service-based). + * + * @author Matthias Pigulla + */ +class ConfigCacheFactory implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCacheFactoryInterface +{ + private $debug; + /** + * @param bool $debug The debug flag to pass to ConfigCache + */ + public function __construct($debug) + { + $this->debug = $debug; + } + /** + * {@inheritdoc} + */ + public function cache($file, $callback) + { + if (!\is_callable($callback)) { + throw new \InvalidArgumentException(\sprintf('Invalid type for callback argument. Expected callable, but got "%s".', \gettype($callback))); + } + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($file, $this->debug); + if (!$cache->isFresh()) { + \call_user_func($callback, $cache); + } + return $cache; + } +} diff --git a/vendor/symfony/config/ConfigCacheFactoryInterface.php b/vendor/symfony/config/ConfigCacheFactoryInterface.php index e758cb6a0..c1182b239 100644 --- a/vendor/symfony/config/ConfigCacheFactoryInterface.php +++ b/vendor/symfony/config/ConfigCacheFactoryInterface.php @@ -1,31 +1,31 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; - -/** - * Interface for a ConfigCache factory. This factory creates - * an instance of ConfigCacheInterface and initializes the - * cache if necessary. - * - * @author Matthias Pigulla - */ -interface ConfigCacheFactoryInterface -{ - /** - * Creates a cache instance and (re-)initializes it if necessary. - * - * @param string $file The absolute cache file path - * @param callable $callable The callable to be executed when the cache needs to be filled (i. e. is not fresh). The cache will be passed as the only parameter to this callback - * - * @return ConfigCacheInterface The cache instance - */ - public function cache($file, $callable); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; + +/** + * Interface for a ConfigCache factory. This factory creates + * an instance of ConfigCacheInterface and initializes the + * cache if necessary. + * + * @author Matthias Pigulla + */ +interface ConfigCacheFactoryInterface +{ + /** + * Creates a cache instance and (re-)initializes it if necessary. + * + * @param string $file The absolute cache file path + * @param callable $callable The callable to be executed when the cache needs to be filled (i. e. is not fresh). The cache will be passed as the only parameter to this callback + * + * @return ConfigCacheInterface The cache instance + */ + public function cache($file, $callable); +} diff --git a/vendor/symfony/config/ConfigCacheInterface.php b/vendor/symfony/config/ConfigCacheInterface.php index 61d5388b8..b79888ce6 100644 --- a/vendor/symfony/config/ConfigCacheInterface.php +++ b/vendor/symfony/config/ConfigCacheInterface.php @@ -1,45 +1,45 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; -/** - * Interface for ConfigCache. - * - * @author Matthias Pigulla - */ -interface ConfigCacheInterface -{ - /** - * Gets the cache file path. - * - * @return string The cache file path - */ - public function getPath(); - /** - * Checks if the cache is still fresh. - * - * This check should take the metadata passed to the write() method into consideration. - * - * @return bool Whether the cache is still fresh - */ - public function isFresh(); - /** - * Writes the given content into the cache file. Metadata will be stored - * independently and can be used to check cache freshness at a later time. - * - * @param string $content The content to write into the cache - * @param ResourceInterface[]|null $metadata An array of ResourceInterface instances - * - * @throws \RuntimeException When the cache file cannot be written - */ - public function write($content, array $metadata = null); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; +/** + * Interface for ConfigCache. + * + * @author Matthias Pigulla + */ +interface ConfigCacheInterface +{ + /** + * Gets the cache file path. + * + * @return string The cache file path + */ + public function getPath(); + /** + * Checks if the cache is still fresh. + * + * This check should take the metadata passed to the write() method into consideration. + * + * @return bool Whether the cache is still fresh + */ + public function isFresh(); + /** + * Writes the given content into the cache file. Metadata will be stored + * independently and can be used to check cache freshness at a later time. + * + * @param string $content The content to write into the cache + * @param ResourceInterface[]|null $metadata An array of ResourceInterface instances + * + * @throws \RuntimeException When the cache file cannot be written + */ + public function write($content, array $metadata = null); +} diff --git a/vendor/symfony/config/Definition/ArrayNode.php b/vendor/symfony/config/Definition/ArrayNode.php index 2bfe789c3..deb5154b3 100644 --- a/vendor/symfony/config/Definition/ArrayNode.php +++ b/vendor/symfony/config/Definition/ArrayNode.php @@ -1,330 +1,330 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException; -/** - * Represents an Array node in the config tree. - * - * @author Johannes M. Schmitt - */ -class ArrayNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BaseNode implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypeNodeInterface -{ - protected $xmlRemappings = []; - protected $children = []; - protected $allowFalse = \false; - protected $allowNewKeys = \true; - protected $addIfNotSet = \false; - protected $performDeepMerging = \true; - protected $ignoreExtraKeys = \false; - protected $removeExtraKeys = \true; - protected $normalizeKeys = \true; - public function setNormalizeKeys($normalizeKeys) - { - $this->normalizeKeys = (bool) $normalizeKeys; - } - /** - * {@inheritdoc} - * - * Namely, you mostly have foo_bar in YAML while you have foo-bar in XML. - * After running this method, all keys are normalized to foo_bar. - * - * If you have a mixed key like foo-bar_moo, it will not be altered. - * The key will also not be altered if the target key already exists. - */ - protected function preNormalize($value) - { - if (!$this->normalizeKeys || !\is_array($value)) { - return $value; - } - $normalized = []; - foreach ($value as $k => $v) { - if (\false !== \strpos($k, '-') && \false === \strpos($k, '_') && !\array_key_exists($normalizedKey = \str_replace('-', '_', $k), $value)) { - $normalized[$normalizedKey] = $v; - } else { - $normalized[$k] = $v; - } - } - return $normalized; - } - /** - * Retrieves the children of this node. - * - * @return array The children - */ - public function getChildren() - { - return $this->children; - } - /** - * Sets the xml remappings that should be performed. - * - * @param array $remappings An array of the form [[string, string]] - */ - public function setXmlRemappings(array $remappings) - { - $this->xmlRemappings = $remappings; - } - /** - * Gets the xml remappings that should be performed. - * - * @return array an array of the form [[string, string]] - */ - public function getXmlRemappings() - { - return $this->xmlRemappings; - } - /** - * Sets whether to add default values for this array if it has not been - * defined in any of the configuration files. - * - * @param bool $boolean - */ - public function setAddIfNotSet($boolean) - { - $this->addIfNotSet = (bool) $boolean; - } - /** - * Sets whether false is allowed as value indicating that the array should be unset. - * - * @param bool $allow - */ - public function setAllowFalse($allow) - { - $this->allowFalse = (bool) $allow; - } - /** - * Sets whether new keys can be defined in subsequent configurations. - * - * @param bool $allow - */ - public function setAllowNewKeys($allow) - { - $this->allowNewKeys = (bool) $allow; - } - /** - * Sets if deep merging should occur. - * - * @param bool $boolean - */ - public function setPerformDeepMerging($boolean) - { - $this->performDeepMerging = (bool) $boolean; - } - /** - * Whether extra keys should just be ignored without an exception. - * - * @param bool $boolean To allow extra keys - * @param bool $remove To remove extra keys - */ - public function setIgnoreExtraKeys($boolean, $remove = \true) - { - $this->ignoreExtraKeys = (bool) $boolean; - $this->removeExtraKeys = $this->ignoreExtraKeys && $remove; - } - /** - * {@inheritdoc} - */ - public function setName($name) - { - $this->name = $name; - } - /** - * {@inheritdoc} - */ - public function hasDefaultValue() - { - return $this->addIfNotSet; - } - /** - * {@inheritdoc} - */ - public function getDefaultValue() - { - if (!$this->hasDefaultValue()) { - throw new \RuntimeException(\sprintf('The node at path "%s" has no default value.', $this->getPath())); - } - $defaults = []; - foreach ($this->children as $name => $child) { - if ($child->hasDefaultValue()) { - $defaults[$name] = $child->getDefaultValue(); - } - } - return $defaults; - } - /** - * Adds a child node. - * - * @throws \InvalidArgumentException when the child node has no name - * @throws \InvalidArgumentException when the child node's name is not unique - */ - public function addChild(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node) - { - $name = $node->getName(); - if (!\strlen($name)) { - throw new \InvalidArgumentException('Child nodes must be named.'); - } - if (isset($this->children[$name])) { - throw new \InvalidArgumentException(\sprintf('A child node named "%s" already exists.', $name)); - } - $this->children[$name] = $node; - } - /** - * Finalizes the value of this node. - * - * @param mixed $value - * - * @return mixed The finalised value - * - * @throws UnsetKeyException - * @throws InvalidConfigurationException if the node doesn't have enough children - */ - protected function finalizeValue($value) - { - if (\false === $value) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException(\sprintf('Unsetting key for path "%s", value: "%s".', $this->getPath(), \json_encode($value))); - } - foreach ($this->children as $name => $child) { - if (!\array_key_exists($name, $value)) { - if ($child->isRequired()) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('The child node "%s" at path "%s" must be configured.', $name, $this->getPath())); - $ex->setPath($this->getPath()); - throw $ex; - } - if ($child->hasDefaultValue()) { - $value[$name] = $child->getDefaultValue(); - } - continue; - } - if ($child->isDeprecated()) { - @\trigger_error($child->getDeprecationMessage($name, $this->getPath()), \E_USER_DEPRECATED); - } - try { - $value[$name] = $child->finalize($value[$name]); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException $e) { - unset($value[$name]); - } - } - return $value; - } - /** - * Validates the type of the value. - * - * @param mixed $value - * - * @throws InvalidTypeException - */ - protected function validateType($value) - { - if (!\is_array($value) && (!$this->allowFalse || \false !== $value)) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException(\sprintf('Invalid type for path "%s". Expected array, but got %s', $this->getPath(), \gettype($value))); - if ($hint = $this->getInfo()) { - $ex->addHint($hint); - } - $ex->setPath($this->getPath()); - throw $ex; - } - } - /** - * Normalizes the value. - * - * @param mixed $value The value to normalize - * - * @return mixed The normalized value - * - * @throws InvalidConfigurationException - */ - protected function normalizeValue($value) - { - if (\false === $value) { - return $value; - } - $value = $this->remapXml($value); - $normalized = []; - foreach ($value as $name => $val) { - if (isset($this->children[$name])) { - try { - $normalized[$name] = $this->children[$name]->normalize($val); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException $e) { - } - unset($value[$name]); - } elseif (!$this->removeExtraKeys) { - $normalized[$name] = $val; - } - } - // if extra fields are present, throw exception - if (\count($value) && !$this->ignoreExtraKeys) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('Unrecognized option%s "%s" under "%s"', 1 === \count($value) ? '' : 's', \implode(', ', \array_keys($value)), $this->getPath())); - $ex->setPath($this->getPath()); - throw $ex; - } - return $normalized; - } - /** - * Remaps multiple singular values to a single plural value. - * - * @param array $value The source values - * - * @return array The remapped values - */ - protected function remapXml($value) - { - foreach ($this->xmlRemappings as list($singular, $plural)) { - if (!isset($value[$singular])) { - continue; - } - $value[$plural] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor::normalizeConfig($value, $singular, $plural); - unset($value[$singular]); - } - return $value; - } - /** - * Merges values together. - * - * @param mixed $leftSide The left side to merge - * @param mixed $rightSide The right side to merge - * - * @return mixed The merged values - * - * @throws InvalidConfigurationException - * @throws \RuntimeException - */ - protected function mergeValues($leftSide, $rightSide) - { - if (\false === $rightSide) { - // if this is still false after the last config has been merged the - // finalization pass will take care of removing this key entirely - return \false; - } - if (\false === $leftSide || !$this->performDeepMerging) { - return $rightSide; - } - foreach ($rightSide as $k => $v) { - // no conflict - if (!\array_key_exists($k, $leftSide)) { - if (!$this->allowNewKeys) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('You are not allowed to define new elements for path "%s". Please define all elements for this path in one config file. If you are trying to overwrite an element, make sure you redefine it with the same name.', $this->getPath())); - $ex->setPath($this->getPath()); - throw $ex; - } - $leftSide[$k] = $v; - continue; - } - if (!isset($this->children[$k])) { - throw new \RuntimeException('merge() expects a normalized config array.'); - } - $leftSide[$k] = $this->children[$k]->merge($leftSide[$k], $v); - } - return $leftSide; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException; +/** + * Represents an Array node in the config tree. + * + * @author Johannes M. Schmitt + */ +class ArrayNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BaseNode implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypeNodeInterface +{ + protected $xmlRemappings = []; + protected $children = []; + protected $allowFalse = \false; + protected $allowNewKeys = \true; + protected $addIfNotSet = \false; + protected $performDeepMerging = \true; + protected $ignoreExtraKeys = \false; + protected $removeExtraKeys = \true; + protected $normalizeKeys = \true; + public function setNormalizeKeys($normalizeKeys) + { + $this->normalizeKeys = (bool) $normalizeKeys; + } + /** + * {@inheritdoc} + * + * Namely, you mostly have foo_bar in YAML while you have foo-bar in XML. + * After running this method, all keys are normalized to foo_bar. + * + * If you have a mixed key like foo-bar_moo, it will not be altered. + * The key will also not be altered if the target key already exists. + */ + protected function preNormalize($value) + { + if (!$this->normalizeKeys || !\is_array($value)) { + return $value; + } + $normalized = []; + foreach ($value as $k => $v) { + if (\false !== \strpos($k, '-') && \false === \strpos($k, '_') && !\array_key_exists($normalizedKey = \str_replace('-', '_', $k), $value)) { + $normalized[$normalizedKey] = $v; + } else { + $normalized[$k] = $v; + } + } + return $normalized; + } + /** + * Retrieves the children of this node. + * + * @return array The children + */ + public function getChildren() + { + return $this->children; + } + /** + * Sets the xml remappings that should be performed. + * + * @param array $remappings An array of the form [[string, string]] + */ + public function setXmlRemappings(array $remappings) + { + $this->xmlRemappings = $remappings; + } + /** + * Gets the xml remappings that should be performed. + * + * @return array an array of the form [[string, string]] + */ + public function getXmlRemappings() + { + return $this->xmlRemappings; + } + /** + * Sets whether to add default values for this array if it has not been + * defined in any of the configuration files. + * + * @param bool $boolean + */ + public function setAddIfNotSet($boolean) + { + $this->addIfNotSet = (bool) $boolean; + } + /** + * Sets whether false is allowed as value indicating that the array should be unset. + * + * @param bool $allow + */ + public function setAllowFalse($allow) + { + $this->allowFalse = (bool) $allow; + } + /** + * Sets whether new keys can be defined in subsequent configurations. + * + * @param bool $allow + */ + public function setAllowNewKeys($allow) + { + $this->allowNewKeys = (bool) $allow; + } + /** + * Sets if deep merging should occur. + * + * @param bool $boolean + */ + public function setPerformDeepMerging($boolean) + { + $this->performDeepMerging = (bool) $boolean; + } + /** + * Whether extra keys should just be ignored without an exception. + * + * @param bool $boolean To allow extra keys + * @param bool $remove To remove extra keys + */ + public function setIgnoreExtraKeys($boolean, $remove = \true) + { + $this->ignoreExtraKeys = (bool) $boolean; + $this->removeExtraKeys = $this->ignoreExtraKeys && $remove; + } + /** + * {@inheritdoc} + */ + public function setName($name) + { + $this->name = $name; + } + /** + * {@inheritdoc} + */ + public function hasDefaultValue() + { + return $this->addIfNotSet; + } + /** + * {@inheritdoc} + */ + public function getDefaultValue() + { + if (!$this->hasDefaultValue()) { + throw new \RuntimeException(\sprintf('The node at path "%s" has no default value.', $this->getPath())); + } + $defaults = []; + foreach ($this->children as $name => $child) { + if ($child->hasDefaultValue()) { + $defaults[$name] = $child->getDefaultValue(); + } + } + return $defaults; + } + /** + * Adds a child node. + * + * @throws \InvalidArgumentException when the child node has no name + * @throws \InvalidArgumentException when the child node's name is not unique + */ + public function addChild(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node) + { + $name = $node->getName(); + if (!\strlen($name)) { + throw new \InvalidArgumentException('Child nodes must be named.'); + } + if (isset($this->children[$name])) { + throw new \InvalidArgumentException(\sprintf('A child node named "%s" already exists.', $name)); + } + $this->children[$name] = $node; + } + /** + * Finalizes the value of this node. + * + * @param mixed $value + * + * @return mixed The finalised value + * + * @throws UnsetKeyException + * @throws InvalidConfigurationException if the node doesn't have enough children + */ + protected function finalizeValue($value) + { + if (\false === $value) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException(\sprintf('Unsetting key for path "%s", value: "%s".', $this->getPath(), \json_encode($value))); + } + foreach ($this->children as $name => $child) { + if (!\array_key_exists($name, $value)) { + if ($child->isRequired()) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('The child node "%s" at path "%s" must be configured.', $name, $this->getPath())); + $ex->setPath($this->getPath()); + throw $ex; + } + if ($child->hasDefaultValue()) { + $value[$name] = $child->getDefaultValue(); + } + continue; + } + if ($child->isDeprecated()) { + @\trigger_error($child->getDeprecationMessage($name, $this->getPath()), \E_USER_DEPRECATED); + } + try { + $value[$name] = $child->finalize($value[$name]); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException $e) { + unset($value[$name]); + } + } + return $value; + } + /** + * Validates the type of the value. + * + * @param mixed $value + * + * @throws InvalidTypeException + */ + protected function validateType($value) + { + if (!\is_array($value) && (!$this->allowFalse || \false !== $value)) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException(\sprintf('Invalid type for path "%s". Expected array, but got %s', $this->getPath(), \gettype($value))); + if ($hint = $this->getInfo()) { + $ex->addHint($hint); + } + $ex->setPath($this->getPath()); + throw $ex; + } + } + /** + * Normalizes the value. + * + * @param mixed $value The value to normalize + * + * @return mixed The normalized value + * + * @throws InvalidConfigurationException + */ + protected function normalizeValue($value) + { + if (\false === $value) { + return $value; + } + $value = $this->remapXml($value); + $normalized = []; + foreach ($value as $name => $val) { + if (isset($this->children[$name])) { + try { + $normalized[$name] = $this->children[$name]->normalize($val); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException $e) { + } + unset($value[$name]); + } elseif (!$this->removeExtraKeys) { + $normalized[$name] = $val; + } + } + // if extra fields are present, throw exception + if (\count($value) && !$this->ignoreExtraKeys) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('Unrecognized option%s "%s" under "%s"', 1 === \count($value) ? '' : 's', \implode(', ', \array_keys($value)), $this->getPath())); + $ex->setPath($this->getPath()); + throw $ex; + } + return $normalized; + } + /** + * Remaps multiple singular values to a single plural value. + * + * @param array $value The source values + * + * @return array The remapped values + */ + protected function remapXml($value) + { + foreach ($this->xmlRemappings as list($singular, $plural)) { + if (!isset($value[$singular])) { + continue; + } + $value[$plural] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor::normalizeConfig($value, $singular, $plural); + unset($value[$singular]); + } + return $value; + } + /** + * Merges values together. + * + * @param mixed $leftSide The left side to merge + * @param mixed $rightSide The right side to merge + * + * @return mixed The merged values + * + * @throws InvalidConfigurationException + * @throws \RuntimeException + */ + protected function mergeValues($leftSide, $rightSide) + { + if (\false === $rightSide) { + // if this is still false after the last config has been merged the + // finalization pass will take care of removing this key entirely + return \false; + } + if (\false === $leftSide || !$this->performDeepMerging) { + return $rightSide; + } + foreach ($rightSide as $k => $v) { + // no conflict + if (!\array_key_exists($k, $leftSide)) { + if (!$this->allowNewKeys) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('You are not allowed to define new elements for path "%s". Please define all elements for this path in one config file. If you are trying to overwrite an element, make sure you redefine it with the same name.', $this->getPath())); + $ex->setPath($this->getPath()); + throw $ex; + } + $leftSide[$k] = $v; + continue; + } + if (!isset($this->children[$k])) { + throw new \RuntimeException('merge() expects a normalized config array.'); + } + $leftSide[$k] = $this->children[$k]->merge($leftSide[$k], $v); + } + return $leftSide; + } +} diff --git a/vendor/symfony/config/Definition/BaseNode.php b/vendor/symfony/config/Definition/BaseNode.php index fd662692e..2e1c86073 100644 --- a/vendor/symfony/config/Definition/BaseNode.php +++ b/vendor/symfony/config/Definition/BaseNode.php @@ -1,336 +1,336 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\ForbiddenOverwriteException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; -/** - * The base node class. - * - * @author Johannes M. Schmitt - */ -abstract class BaseNode implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface -{ - protected $name; - protected $parent; - protected $normalizationClosures = []; - protected $finalValidationClosures = []; - protected $allowOverwrite = \true; - protected $required = \false; - protected $deprecationMessage = null; - protected $equivalentValues = []; - protected $attributes = []; - /** - * @param string|null $name The name of the node - * @param NodeInterface|null $parent The parent of this node - * - * @throws \InvalidArgumentException if the name contains a period - */ - public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $parent = null) - { - if (\false !== \strpos($name = (string) $name, '.')) { - throw new \InvalidArgumentException('The name must not contain ".".'); - } - $this->name = $name; - $this->parent = $parent; - } - /** - * @param string $key - */ - public function setAttribute($key, $value) - { - $this->attributes[$key] = $value; - } - /** - * @param string $key - * - * @return mixed - */ - public function getAttribute($key, $default = null) - { - return isset($this->attributes[$key]) ? $this->attributes[$key] : $default; - } - /** - * @param string $key - * - * @return bool - */ - public function hasAttribute($key) - { - return isset($this->attributes[$key]); - } - /** - * @return array - */ - public function getAttributes() - { - return $this->attributes; - } - public function setAttributes(array $attributes) - { - $this->attributes = $attributes; - } - /** - * @param string $key - */ - public function removeAttribute($key) - { - unset($this->attributes[$key]); - } - /** - * Sets an info message. - * - * @param string $info - */ - public function setInfo($info) - { - $this->setAttribute('info', $info); - } - /** - * Returns info message. - * - * @return string|null The info text - */ - public function getInfo() - { - return $this->getAttribute('info'); - } - /** - * Sets the example configuration for this node. - * - * @param string|array $example - */ - public function setExample($example) - { - $this->setAttribute('example', $example); - } - /** - * Retrieves the example configuration for this node. - * - * @return string|array|null The example - */ - public function getExample() - { - return $this->getAttribute('example'); - } - /** - * Adds an equivalent value. - * - * @param mixed $originalValue - * @param mixed $equivalentValue - */ - public function addEquivalentValue($originalValue, $equivalentValue) - { - $this->equivalentValues[] = [$originalValue, $equivalentValue]; - } - /** - * Set this node as required. - * - * @param bool $boolean Required node - */ - public function setRequired($boolean) - { - $this->required = (bool) $boolean; - } - /** - * Sets this node as deprecated. - * - * You can use %node% and %path% placeholders in your message to display, - * respectively, the node name and its complete path. - * - * @param string|null $message Deprecated message - */ - public function setDeprecated($message) - { - $this->deprecationMessage = $message; - } - /** - * Sets if this node can be overridden. - * - * @param bool $allow - */ - public function setAllowOverwrite($allow) - { - $this->allowOverwrite = (bool) $allow; - } - /** - * Sets the closures used for normalization. - * - * @param \Closure[] $closures An array of Closures used for normalization - */ - public function setNormalizationClosures(array $closures) - { - $this->normalizationClosures = $closures; - } - /** - * Sets the closures used for final validation. - * - * @param \Closure[] $closures An array of Closures used for final validation - */ - public function setFinalValidationClosures(array $closures) - { - $this->finalValidationClosures = $closures; - } - /** - * {@inheritdoc} - */ - public function isRequired() - { - return $this->required; - } - /** - * Checks if this node is deprecated. - * - * @return bool - */ - public function isDeprecated() - { - return null !== $this->deprecationMessage; - } - /** - * Returns the deprecated message. - * - * @param string $node the configuration node name - * @param string $path the path of the node - * - * @return string - */ - public function getDeprecationMessage($node, $path) - { - return \strtr($this->deprecationMessage, ['%node%' => $node, '%path%' => $path]); - } - /** - * {@inheritdoc} - */ - public function getName() - { - return $this->name; - } - /** - * {@inheritdoc} - */ - public function getPath() - { - $path = $this->name; - if (null !== $this->parent) { - $path = $this->parent->getPath() . '.' . $path; - } - return $path; - } - /** - * {@inheritdoc} - */ - public final function merge($leftSide, $rightSide) - { - if (!$this->allowOverwrite) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\ForbiddenOverwriteException(\sprintf('Configuration path "%s" cannot be overwritten. You have to define all options for this path, and any of its sub-paths in one configuration section.', $this->getPath())); - } - $this->validateType($leftSide); - $this->validateType($rightSide); - return $this->mergeValues($leftSide, $rightSide); - } - /** - * {@inheritdoc} - */ - public final function normalize($value) - { - $value = $this->preNormalize($value); - // run custom normalization closures - foreach ($this->normalizationClosures as $closure) { - $value = $closure($value); - } - // replace value with their equivalent - foreach ($this->equivalentValues as $data) { - if ($data[0] === $value) { - $value = $data[1]; - } - } - // validate type - $this->validateType($value); - // normalize value - return $this->normalizeValue($value); - } - /** - * Normalizes the value before any other normalization is applied. - * - * @param mixed $value - * - * @return mixed The normalized array value - */ - protected function preNormalize($value) - { - return $value; - } - /** - * Returns parent node for this node. - * - * @return NodeInterface|null - */ - public function getParent() - { - return $this->parent; - } - /** - * {@inheritdoc} - */ - public final function finalize($value) - { - $this->validateType($value); - $value = $this->finalizeValue($value); - // Perform validation on the final value if a closure has been set. - // The closure is also allowed to return another value. - foreach ($this->finalValidationClosures as $closure) { - try { - $value = $closure($value); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception $e) { - throw $e; - } catch (\Exception $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('Invalid configuration for path "%s": %s.', $this->getPath(), $e->getMessage()), $e->getCode(), $e); - } - } - return $value; - } - /** - * Validates the type of a Node. - * - * @param mixed $value The value to validate - * - * @throws InvalidTypeException when the value is invalid - */ - protected abstract function validateType($value); - /** - * Normalizes the value. - * - * @param mixed $value The value to normalize - * - * @return mixed The normalized value - */ - protected abstract function normalizeValue($value); - /** - * Merges two values together. - * - * @param mixed $leftSide - * @param mixed $rightSide - * - * @return mixed The merged value - */ - protected abstract function mergeValues($leftSide, $rightSide); - /** - * Finalizes a value. - * - * @param mixed $value The value to finalize - * - * @return mixed The finalized value - */ - protected abstract function finalizeValue($value); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\ForbiddenOverwriteException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; +/** + * The base node class. + * + * @author Johannes M. Schmitt + */ +abstract class BaseNode implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface +{ + protected $name; + protected $parent; + protected $normalizationClosures = []; + protected $finalValidationClosures = []; + protected $allowOverwrite = \true; + protected $required = \false; + protected $deprecationMessage = null; + protected $equivalentValues = []; + protected $attributes = []; + /** + * @param string|null $name The name of the node + * @param NodeInterface|null $parent The parent of this node + * + * @throws \InvalidArgumentException if the name contains a period + */ + public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $parent = null) + { + if (\false !== \strpos($name = (string) $name, '.')) { + throw new \InvalidArgumentException('The name must not contain ".".'); + } + $this->name = $name; + $this->parent = $parent; + } + /** + * @param string $key + */ + public function setAttribute($key, $value) + { + $this->attributes[$key] = $value; + } + /** + * @param string $key + * + * @return mixed + */ + public function getAttribute($key, $default = null) + { + return isset($this->attributes[$key]) ? $this->attributes[$key] : $default; + } + /** + * @param string $key + * + * @return bool + */ + public function hasAttribute($key) + { + return isset($this->attributes[$key]); + } + /** + * @return array + */ + public function getAttributes() + { + return $this->attributes; + } + public function setAttributes(array $attributes) + { + $this->attributes = $attributes; + } + /** + * @param string $key + */ + public function removeAttribute($key) + { + unset($this->attributes[$key]); + } + /** + * Sets an info message. + * + * @param string $info + */ + public function setInfo($info) + { + $this->setAttribute('info', $info); + } + /** + * Returns info message. + * + * @return string|null The info text + */ + public function getInfo() + { + return $this->getAttribute('info'); + } + /** + * Sets the example configuration for this node. + * + * @param string|array $example + */ + public function setExample($example) + { + $this->setAttribute('example', $example); + } + /** + * Retrieves the example configuration for this node. + * + * @return string|array|null The example + */ + public function getExample() + { + return $this->getAttribute('example'); + } + /** + * Adds an equivalent value. + * + * @param mixed $originalValue + * @param mixed $equivalentValue + */ + public function addEquivalentValue($originalValue, $equivalentValue) + { + $this->equivalentValues[] = [$originalValue, $equivalentValue]; + } + /** + * Set this node as required. + * + * @param bool $boolean Required node + */ + public function setRequired($boolean) + { + $this->required = (bool) $boolean; + } + /** + * Sets this node as deprecated. + * + * You can use %node% and %path% placeholders in your message to display, + * respectively, the node name and its complete path. + * + * @param string|null $message Deprecated message + */ + public function setDeprecated($message) + { + $this->deprecationMessage = $message; + } + /** + * Sets if this node can be overridden. + * + * @param bool $allow + */ + public function setAllowOverwrite($allow) + { + $this->allowOverwrite = (bool) $allow; + } + /** + * Sets the closures used for normalization. + * + * @param \Closure[] $closures An array of Closures used for normalization + */ + public function setNormalizationClosures(array $closures) + { + $this->normalizationClosures = $closures; + } + /** + * Sets the closures used for final validation. + * + * @param \Closure[] $closures An array of Closures used for final validation + */ + public function setFinalValidationClosures(array $closures) + { + $this->finalValidationClosures = $closures; + } + /** + * {@inheritdoc} + */ + public function isRequired() + { + return $this->required; + } + /** + * Checks if this node is deprecated. + * + * @return bool + */ + public function isDeprecated() + { + return null !== $this->deprecationMessage; + } + /** + * Returns the deprecated message. + * + * @param string $node the configuration node name + * @param string $path the path of the node + * + * @return string + */ + public function getDeprecationMessage($node, $path) + { + return \strtr($this->deprecationMessage, ['%node%' => $node, '%path%' => $path]); + } + /** + * {@inheritdoc} + */ + public function getName() + { + return $this->name; + } + /** + * {@inheritdoc} + */ + public function getPath() + { + $path = $this->name; + if (null !== $this->parent) { + $path = $this->parent->getPath() . '.' . $path; + } + return $path; + } + /** + * {@inheritdoc} + */ + public final function merge($leftSide, $rightSide) + { + if (!$this->allowOverwrite) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\ForbiddenOverwriteException(\sprintf('Configuration path "%s" cannot be overwritten. You have to define all options for this path, and any of its sub-paths in one configuration section.', $this->getPath())); + } + $this->validateType($leftSide); + $this->validateType($rightSide); + return $this->mergeValues($leftSide, $rightSide); + } + /** + * {@inheritdoc} + */ + public final function normalize($value) + { + $value = $this->preNormalize($value); + // run custom normalization closures + foreach ($this->normalizationClosures as $closure) { + $value = $closure($value); + } + // replace value with their equivalent + foreach ($this->equivalentValues as $data) { + if ($data[0] === $value) { + $value = $data[1]; + } + } + // validate type + $this->validateType($value); + // normalize value + return $this->normalizeValue($value); + } + /** + * Normalizes the value before any other normalization is applied. + * + * @param mixed $value + * + * @return mixed The normalized array value + */ + protected function preNormalize($value) + { + return $value; + } + /** + * Returns parent node for this node. + * + * @return NodeInterface|null + */ + public function getParent() + { + return $this->parent; + } + /** + * {@inheritdoc} + */ + public final function finalize($value) + { + $this->validateType($value); + $value = $this->finalizeValue($value); + // Perform validation on the final value if a closure has been set. + // The closure is also allowed to return another value. + foreach ($this->finalValidationClosures as $closure) { + try { + $value = $closure($value); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception $e) { + throw $e; + } catch (\Exception $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('Invalid configuration for path "%s": %s.', $this->getPath(), $e->getMessage()), $e->getCode(), $e); + } + } + return $value; + } + /** + * Validates the type of a Node. + * + * @param mixed $value The value to validate + * + * @throws InvalidTypeException when the value is invalid + */ + protected abstract function validateType($value); + /** + * Normalizes the value. + * + * @param mixed $value The value to normalize + * + * @return mixed The normalized value + */ + protected abstract function normalizeValue($value); + /** + * Merges two values together. + * + * @param mixed $leftSide + * @param mixed $rightSide + * + * @return mixed The merged value + */ + protected abstract function mergeValues($leftSide, $rightSide); + /** + * Finalizes a value. + * + * @param mixed $value The value to finalize + * + * @return mixed The finalized value + */ + protected abstract function finalizeValue($value); +} diff --git a/vendor/symfony/config/Definition/BooleanNode.php b/vendor/symfony/config/Definition/BooleanNode.php index 151a338ed..74b226d6e 100644 --- a/vendor/symfony/config/Definition/BooleanNode.php +++ b/vendor/symfony/config/Definition/BooleanNode.php @@ -1,43 +1,43 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; -/** - * This node represents a Boolean value in the config tree. - * - * @author Johannes M. Schmitt - */ -class BooleanNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode -{ - /** - * {@inheritdoc} - */ - protected function validateType($value) - { - if (!\is_bool($value)) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException(\sprintf('Invalid type for path "%s". Expected boolean, but got %s.', $this->getPath(), \gettype($value))); - if ($hint = $this->getInfo()) { - $ex->addHint($hint); - } - $ex->setPath($this->getPath()); - throw $ex; - } - } - /** - * {@inheritdoc} - */ - protected function isValueEmpty($value) - { - // a boolean value cannot be empty - return \false; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; +/** + * This node represents a Boolean value in the config tree. + * + * @author Johannes M. Schmitt + */ +class BooleanNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode +{ + /** + * {@inheritdoc} + */ + protected function validateType($value) + { + if (!\is_bool($value)) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException(\sprintf('Invalid type for path "%s". Expected boolean, but got %s.', $this->getPath(), \gettype($value))); + if ($hint = $this->getInfo()) { + $ex->addHint($hint); + } + $ex->setPath($this->getPath()); + throw $ex; + } + } + /** + * {@inheritdoc} + */ + protected function isValueEmpty($value) + { + // a boolean value cannot be empty + return \false; + } +} diff --git a/vendor/symfony/config/Definition/Builder/ArrayNodeDefinition.php b/vendor/symfony/config/Definition/Builder/ArrayNodeDefinition.php index 145d615b2..709f790d1 100644 --- a/vendor/symfony/config/Definition/Builder/ArrayNodeDefinition.php +++ b/vendor/symfony/config/Definition/Builder/ArrayNodeDefinition.php @@ -1,432 +1,432 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode; -/** - * This class provides a fluent interface for defining an array node. - * - * @author Johannes M. Schmitt - */ -class ArrayNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ParentNodeDefinitionInterface -{ - protected $performDeepMerging = \true; - protected $ignoreExtraKeys = \false; - protected $removeExtraKeys = \true; - protected $children = []; - protected $prototype; - protected $atLeastOne = \false; - protected $allowNewKeys = \true; - protected $key; - protected $removeKeyItem; - protected $addDefaults = \false; - protected $addDefaultChildren = \false; - protected $nodeBuilder; - protected $normalizeKeys = \true; - /** - * {@inheritdoc} - */ - public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface $parent = null) - { - parent::__construct($name, $parent); - $this->nullEquivalent = []; - $this->trueEquivalent = []; - } - /** - * {@inheritdoc} - */ - public function setBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder $builder) - { - $this->nodeBuilder = $builder; - } - /** - * {@inheritdoc} - */ - public function children() - { - return $this->getNodeBuilder(); - } - /** - * Sets a prototype for child nodes. - * - * @param string $type The type of node - * - * @return NodeDefinition - */ - public function prototype($type) - { - return $this->prototype = $this->getNodeBuilder()->node(null, $type)->setParent($this); - } - /** - * @return VariableNodeDefinition - */ - public function variablePrototype() - { - return $this->prototype('variable'); - } - /** - * @return ScalarNodeDefinition - */ - public function scalarPrototype() - { - return $this->prototype('scalar'); - } - /** - * @return BooleanNodeDefinition - */ - public function booleanPrototype() - { - return $this->prototype('boolean'); - } - /** - * @return IntegerNodeDefinition - */ - public function integerPrototype() - { - return $this->prototype('integer'); - } - /** - * @return FloatNodeDefinition - */ - public function floatPrototype() - { - return $this->prototype('float'); - } - /** - * @return ArrayNodeDefinition - */ - public function arrayPrototype() - { - return $this->prototype('array'); - } - /** - * @return EnumNodeDefinition - */ - public function enumPrototype() - { - return $this->prototype('enum'); - } - /** - * Adds the default value if the node is not set in the configuration. - * - * This method is applicable to concrete nodes only (not to prototype nodes). - * If this function has been called and the node is not set during the finalization - * phase, it's default value will be derived from its children default values. - * - * @return $this - */ - public function addDefaultsIfNotSet() - { - $this->addDefaults = \true; - return $this; - } - /** - * Adds children with a default value when none are defined. - * - * This method is applicable to prototype nodes only. - * - * @param int|string|array|null $children The number of children|The child name|The children names to be added - * - * @return $this - */ - public function addDefaultChildrenIfNoneSet($children = null) - { - $this->addDefaultChildren = $children; - return $this; - } - /** - * Requires the node to have at least one element. - * - * This method is applicable to prototype nodes only. - * - * @return $this - */ - public function requiresAtLeastOneElement() - { - $this->atLeastOne = \true; - return $this; - } - /** - * Disallows adding news keys in a subsequent configuration. - * - * If used all keys have to be defined in the same configuration file. - * - * @return $this - */ - public function disallowNewKeysInSubsequentConfigs() - { - $this->allowNewKeys = \false; - return $this; - } - /** - * Sets a normalization rule for XML configurations. - * - * @param string $singular The key to remap - * @param string $plural The plural of the key for irregular plurals - * - * @return $this - */ - public function fixXmlConfig($singular, $plural = null) - { - $this->normalization()->remap($singular, $plural); - return $this; - } - /** - * Sets the attribute which value is to be used as key. - * - * This is useful when you have an indexed array that should be an - * associative array. You can select an item from within the array - * to be the key of the particular item. For example, if "id" is the - * "key", then: - * - * [ - * ['id' => 'my_name', 'foo' => 'bar'], - * ]; - * - * becomes - * - * [ - * 'my_name' => ['foo' => 'bar'], - * ]; - * - * If you'd like "'id' => 'my_name'" to still be present in the resulting - * array, then you can set the second argument of this method to false. - * - * This method is applicable to prototype nodes only. - * - * @param string $name The name of the key - * @param bool $removeKeyItem Whether or not the key item should be removed - * - * @return $this - */ - public function useAttributeAsKey($name, $removeKeyItem = \true) - { - $this->key = $name; - $this->removeKeyItem = $removeKeyItem; - return $this; - } - /** - * Sets whether the node can be unset. - * - * @param bool $allow - * - * @return $this - */ - public function canBeUnset($allow = \true) - { - $this->merge()->allowUnset($allow); - return $this; - } - /** - * Adds an "enabled" boolean to enable the current section. - * - * By default, the section is disabled. If any configuration is specified then - * the node will be automatically enabled: - * - * enableableArrayNode: {enabled: true, ...} # The config is enabled & default values get overridden - * enableableArrayNode: ~ # The config is enabled & use the default values - * enableableArrayNode: true # The config is enabled & use the default values - * enableableArrayNode: {other: value, ...} # The config is enabled & default values get overridden - * enableableArrayNode: {enabled: false, ...} # The config is disabled - * enableableArrayNode: false # The config is disabled - * - * @return $this - */ - public function canBeEnabled() - { - $this->addDefaultsIfNotSet()->treatFalseLike(['enabled' => \false])->treatTrueLike(['enabled' => \true])->treatNullLike(['enabled' => \true])->beforeNormalization()->ifArray()->then(function ($v) { - $v['enabled'] = isset($v['enabled']) ? $v['enabled'] : \true; - return $v; - })->end()->children()->booleanNode('enabled')->defaultFalse(); - return $this; - } - /** - * Adds an "enabled" boolean to enable the current section. - * - * By default, the section is enabled. - * - * @return $this - */ - public function canBeDisabled() - { - $this->addDefaultsIfNotSet()->treatFalseLike(['enabled' => \false])->treatTrueLike(['enabled' => \true])->treatNullLike(['enabled' => \true])->children()->booleanNode('enabled')->defaultTrue(); - return $this; - } - /** - * Disables the deep merging of the node. - * - * @return $this - */ - public function performNoDeepMerging() - { - $this->performDeepMerging = \false; - return $this; - } - /** - * Allows extra config keys to be specified under an array without - * throwing an exception. - * - * Those config values are ignored and removed from the resulting - * array. This should be used only in special cases where you want - * to send an entire configuration array through a special tree that - * processes only part of the array. - * - * @param bool $remove Whether to remove the extra keys - * - * @return $this - */ - public function ignoreExtraKeys($remove = \true) - { - $this->ignoreExtraKeys = \true; - $this->removeExtraKeys = $remove; - return $this; - } - /** - * Sets key normalization. - * - * @param bool $bool Whether to enable key normalization - * - * @return $this - */ - public function normalizeKeys($bool) - { - $this->normalizeKeys = (bool) $bool; - return $this; - } - /** - * {@inheritdoc} - */ - public function append(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) - { - $this->children[$node->name] = $node->setParent($this); - return $this; - } - /** - * Returns a node builder to be used to add children and prototype. - * - * @return NodeBuilder The node builder - */ - protected function getNodeBuilder() - { - if (null === $this->nodeBuilder) { - $this->nodeBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); - } - return $this->nodeBuilder->setParent($this); - } - /** - * {@inheritdoc} - */ - protected function createNode() - { - if (null === $this->prototype) { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode($this->name, $this->parent); - $this->validateConcreteNode($node); - $node->setAddIfNotSet($this->addDefaults); - foreach ($this->children as $child) { - $child->parent = $node; - $node->addChild($child->getNode()); - } - } else { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode($this->name, $this->parent); - $this->validatePrototypeNode($node); - if (null !== $this->key) { - $node->setKeyAttribute($this->key, $this->removeKeyItem); - } - if (\false === $this->allowEmptyValue) { - @\trigger_error(\sprintf('Using %s::cannotBeEmpty() at path "%s" has no effect, consider requiresAtLeastOneElement() instead. In 4.0 both methods will behave the same.', __CLASS__, $node->getPath()), \E_USER_DEPRECATED); - } - if (\true === $this->atLeastOne) { - $node->setMinNumberOfElements(1); - } - if ($this->default) { - $node->setDefaultValue($this->defaultValue); - } - if (\false !== $this->addDefaultChildren) { - $node->setAddChildrenIfNoneSet($this->addDefaultChildren); - if ($this->prototype instanceof static && null === $this->prototype->prototype) { - $this->prototype->addDefaultsIfNotSet(); - } - } - $this->prototype->parent = $node; - $node->setPrototype($this->prototype->getNode()); - } - $node->setAllowNewKeys($this->allowNewKeys); - $node->addEquivalentValue(null, $this->nullEquivalent); - $node->addEquivalentValue(\true, $this->trueEquivalent); - $node->addEquivalentValue(\false, $this->falseEquivalent); - $node->setPerformDeepMerging($this->performDeepMerging); - $node->setRequired($this->required); - $node->setDeprecated($this->deprecationMessage); - $node->setIgnoreExtraKeys($this->ignoreExtraKeys, $this->removeExtraKeys); - $node->setNormalizeKeys($this->normalizeKeys); - if (null !== $this->normalization) { - $node->setNormalizationClosures($this->normalization->before); - $node->setXmlRemappings($this->normalization->remappings); - } - if (null !== $this->merge) { - $node->setAllowOverwrite($this->merge->allowOverwrite); - $node->setAllowFalse($this->merge->allowFalse); - } - if (null !== $this->validation) { - $node->setFinalValidationClosures($this->validation->rules); - } - return $node; - } - /** - * Validate the configuration of a concrete node. - * - * @throws InvalidDefinitionException - */ - protected function validateConcreteNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode $node) - { - $path = $node->getPath(); - if (null !== $this->key) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->useAttributeAsKey() is not applicable to concrete nodes at path "%s".', $path)); - } - if (\false === $this->allowEmptyValue) { - @\trigger_error(\sprintf('->cannotBeEmpty() is not applicable to concrete nodes at path "%s". In 4.0 it will throw an exception.', $path), \E_USER_DEPRECATED); - } - if (\true === $this->atLeastOne) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->requiresAtLeastOneElement() is not applicable to concrete nodes at path "%s".', $path)); - } - if ($this->default) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->defaultValue() is not applicable to concrete nodes at path "%s".', $path)); - } - if (\false !== $this->addDefaultChildren) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->addDefaultChildrenIfNoneSet() is not applicable to concrete nodes at path "%s".', $path)); - } - } - /** - * Validate the configuration of a prototype node. - * - * @throws InvalidDefinitionException - */ - protected function validatePrototypeNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode $node) - { - $path = $node->getPath(); - if ($this->addDefaults) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->addDefaultsIfNotSet() is not applicable to prototype nodes at path "%s".', $path)); - } - if (\false !== $this->addDefaultChildren) { - if ($this->default) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('A default value and default children might not be used together at path "%s".', $path)); - } - if (null !== $this->key && (null === $this->addDefaultChildren || \is_int($this->addDefaultChildren) && $this->addDefaultChildren > 0)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->addDefaultChildrenIfNoneSet() should set default children names as ->useAttributeAsKey() is used at path "%s".', $path)); - } - if (null === $this->key && (\is_string($this->addDefaultChildren) || \is_array($this->addDefaultChildren))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->addDefaultChildrenIfNoneSet() might not set default children names as ->useAttributeAsKey() is not used at path "%s".', $path)); - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode; +/** + * This class provides a fluent interface for defining an array node. + * + * @author Johannes M. Schmitt + */ +class ArrayNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ParentNodeDefinitionInterface +{ + protected $performDeepMerging = \true; + protected $ignoreExtraKeys = \false; + protected $removeExtraKeys = \true; + protected $children = []; + protected $prototype; + protected $atLeastOne = \false; + protected $allowNewKeys = \true; + protected $key; + protected $removeKeyItem; + protected $addDefaults = \false; + protected $addDefaultChildren = \false; + protected $nodeBuilder; + protected $normalizeKeys = \true; + /** + * {@inheritdoc} + */ + public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface $parent = null) + { + parent::__construct($name, $parent); + $this->nullEquivalent = []; + $this->trueEquivalent = []; + } + /** + * {@inheritdoc} + */ + public function setBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder $builder) + { + $this->nodeBuilder = $builder; + } + /** + * {@inheritdoc} + */ + public function children() + { + return $this->getNodeBuilder(); + } + /** + * Sets a prototype for child nodes. + * + * @param string $type The type of node + * + * @return NodeDefinition + */ + public function prototype($type) + { + return $this->prototype = $this->getNodeBuilder()->node(null, $type)->setParent($this); + } + /** + * @return VariableNodeDefinition + */ + public function variablePrototype() + { + return $this->prototype('variable'); + } + /** + * @return ScalarNodeDefinition + */ + public function scalarPrototype() + { + return $this->prototype('scalar'); + } + /** + * @return BooleanNodeDefinition + */ + public function booleanPrototype() + { + return $this->prototype('boolean'); + } + /** + * @return IntegerNodeDefinition + */ + public function integerPrototype() + { + return $this->prototype('integer'); + } + /** + * @return FloatNodeDefinition + */ + public function floatPrototype() + { + return $this->prototype('float'); + } + /** + * @return ArrayNodeDefinition + */ + public function arrayPrototype() + { + return $this->prototype('array'); + } + /** + * @return EnumNodeDefinition + */ + public function enumPrototype() + { + return $this->prototype('enum'); + } + /** + * Adds the default value if the node is not set in the configuration. + * + * This method is applicable to concrete nodes only (not to prototype nodes). + * If this function has been called and the node is not set during the finalization + * phase, it's default value will be derived from its children default values. + * + * @return $this + */ + public function addDefaultsIfNotSet() + { + $this->addDefaults = \true; + return $this; + } + /** + * Adds children with a default value when none are defined. + * + * This method is applicable to prototype nodes only. + * + * @param int|string|array|null $children The number of children|The child name|The children names to be added + * + * @return $this + */ + public function addDefaultChildrenIfNoneSet($children = null) + { + $this->addDefaultChildren = $children; + return $this; + } + /** + * Requires the node to have at least one element. + * + * This method is applicable to prototype nodes only. + * + * @return $this + */ + public function requiresAtLeastOneElement() + { + $this->atLeastOne = \true; + return $this; + } + /** + * Disallows adding news keys in a subsequent configuration. + * + * If used all keys have to be defined in the same configuration file. + * + * @return $this + */ + public function disallowNewKeysInSubsequentConfigs() + { + $this->allowNewKeys = \false; + return $this; + } + /** + * Sets a normalization rule for XML configurations. + * + * @param string $singular The key to remap + * @param string $plural The plural of the key for irregular plurals + * + * @return $this + */ + public function fixXmlConfig($singular, $plural = null) + { + $this->normalization()->remap($singular, $plural); + return $this; + } + /** + * Sets the attribute which value is to be used as key. + * + * This is useful when you have an indexed array that should be an + * associative array. You can select an item from within the array + * to be the key of the particular item. For example, if "id" is the + * "key", then: + * + * [ + * ['id' => 'my_name', 'foo' => 'bar'], + * ]; + * + * becomes + * + * [ + * 'my_name' => ['foo' => 'bar'], + * ]; + * + * If you'd like "'id' => 'my_name'" to still be present in the resulting + * array, then you can set the second argument of this method to false. + * + * This method is applicable to prototype nodes only. + * + * @param string $name The name of the key + * @param bool $removeKeyItem Whether or not the key item should be removed + * + * @return $this + */ + public function useAttributeAsKey($name, $removeKeyItem = \true) + { + $this->key = $name; + $this->removeKeyItem = $removeKeyItem; + return $this; + } + /** + * Sets whether the node can be unset. + * + * @param bool $allow + * + * @return $this + */ + public function canBeUnset($allow = \true) + { + $this->merge()->allowUnset($allow); + return $this; + } + /** + * Adds an "enabled" boolean to enable the current section. + * + * By default, the section is disabled. If any configuration is specified then + * the node will be automatically enabled: + * + * enableableArrayNode: {enabled: true, ...} # The config is enabled & default values get overridden + * enableableArrayNode: ~ # The config is enabled & use the default values + * enableableArrayNode: true # The config is enabled & use the default values + * enableableArrayNode: {other: value, ...} # The config is enabled & default values get overridden + * enableableArrayNode: {enabled: false, ...} # The config is disabled + * enableableArrayNode: false # The config is disabled + * + * @return $this + */ + public function canBeEnabled() + { + $this->addDefaultsIfNotSet()->treatFalseLike(['enabled' => \false])->treatTrueLike(['enabled' => \true])->treatNullLike(['enabled' => \true])->beforeNormalization()->ifArray()->then(function ($v) { + $v['enabled'] = isset($v['enabled']) ? $v['enabled'] : \true; + return $v; + })->end()->children()->booleanNode('enabled')->defaultFalse(); + return $this; + } + /** + * Adds an "enabled" boolean to enable the current section. + * + * By default, the section is enabled. + * + * @return $this + */ + public function canBeDisabled() + { + $this->addDefaultsIfNotSet()->treatFalseLike(['enabled' => \false])->treatTrueLike(['enabled' => \true])->treatNullLike(['enabled' => \true])->children()->booleanNode('enabled')->defaultTrue(); + return $this; + } + /** + * Disables the deep merging of the node. + * + * @return $this + */ + public function performNoDeepMerging() + { + $this->performDeepMerging = \false; + return $this; + } + /** + * Allows extra config keys to be specified under an array without + * throwing an exception. + * + * Those config values are ignored and removed from the resulting + * array. This should be used only in special cases where you want + * to send an entire configuration array through a special tree that + * processes only part of the array. + * + * @param bool $remove Whether to remove the extra keys + * + * @return $this + */ + public function ignoreExtraKeys($remove = \true) + { + $this->ignoreExtraKeys = \true; + $this->removeExtraKeys = $remove; + return $this; + } + /** + * Sets key normalization. + * + * @param bool $bool Whether to enable key normalization + * + * @return $this + */ + public function normalizeKeys($bool) + { + $this->normalizeKeys = (bool) $bool; + return $this; + } + /** + * {@inheritdoc} + */ + public function append(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) + { + $this->children[$node->name] = $node->setParent($this); + return $this; + } + /** + * Returns a node builder to be used to add children and prototype. + * + * @return NodeBuilder The node builder + */ + protected function getNodeBuilder() + { + if (null === $this->nodeBuilder) { + $this->nodeBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); + } + return $this->nodeBuilder->setParent($this); + } + /** + * {@inheritdoc} + */ + protected function createNode() + { + if (null === $this->prototype) { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode($this->name, $this->parent); + $this->validateConcreteNode($node); + $node->setAddIfNotSet($this->addDefaults); + foreach ($this->children as $child) { + $child->parent = $node; + $node->addChild($child->getNode()); + } + } else { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode($this->name, $this->parent); + $this->validatePrototypeNode($node); + if (null !== $this->key) { + $node->setKeyAttribute($this->key, $this->removeKeyItem); + } + if (\false === $this->allowEmptyValue) { + @\trigger_error(\sprintf('Using %s::cannotBeEmpty() at path "%s" has no effect, consider requiresAtLeastOneElement() instead. In 4.0 both methods will behave the same.', __CLASS__, $node->getPath()), \E_USER_DEPRECATED); + } + if (\true === $this->atLeastOne) { + $node->setMinNumberOfElements(1); + } + if ($this->default) { + $node->setDefaultValue($this->defaultValue); + } + if (\false !== $this->addDefaultChildren) { + $node->setAddChildrenIfNoneSet($this->addDefaultChildren); + if ($this->prototype instanceof static && null === $this->prototype->prototype) { + $this->prototype->addDefaultsIfNotSet(); + } + } + $this->prototype->parent = $node; + $node->setPrototype($this->prototype->getNode()); + } + $node->setAllowNewKeys($this->allowNewKeys); + $node->addEquivalentValue(null, $this->nullEquivalent); + $node->addEquivalentValue(\true, $this->trueEquivalent); + $node->addEquivalentValue(\false, $this->falseEquivalent); + $node->setPerformDeepMerging($this->performDeepMerging); + $node->setRequired($this->required); + $node->setDeprecated($this->deprecationMessage); + $node->setIgnoreExtraKeys($this->ignoreExtraKeys, $this->removeExtraKeys); + $node->setNormalizeKeys($this->normalizeKeys); + if (null !== $this->normalization) { + $node->setNormalizationClosures($this->normalization->before); + $node->setXmlRemappings($this->normalization->remappings); + } + if (null !== $this->merge) { + $node->setAllowOverwrite($this->merge->allowOverwrite); + $node->setAllowFalse($this->merge->allowFalse); + } + if (null !== $this->validation) { + $node->setFinalValidationClosures($this->validation->rules); + } + return $node; + } + /** + * Validate the configuration of a concrete node. + * + * @throws InvalidDefinitionException + */ + protected function validateConcreteNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode $node) + { + $path = $node->getPath(); + if (null !== $this->key) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->useAttributeAsKey() is not applicable to concrete nodes at path "%s".', $path)); + } + if (\false === $this->allowEmptyValue) { + @\trigger_error(\sprintf('->cannotBeEmpty() is not applicable to concrete nodes at path "%s". In 4.0 it will throw an exception.', $path), \E_USER_DEPRECATED); + } + if (\true === $this->atLeastOne) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->requiresAtLeastOneElement() is not applicable to concrete nodes at path "%s".', $path)); + } + if ($this->default) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->defaultValue() is not applicable to concrete nodes at path "%s".', $path)); + } + if (\false !== $this->addDefaultChildren) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->addDefaultChildrenIfNoneSet() is not applicable to concrete nodes at path "%s".', $path)); + } + } + /** + * Validate the configuration of a prototype node. + * + * @throws InvalidDefinitionException + */ + protected function validatePrototypeNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode $node) + { + $path = $node->getPath(); + if ($this->addDefaults) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->addDefaultsIfNotSet() is not applicable to prototype nodes at path "%s".', $path)); + } + if (\false !== $this->addDefaultChildren) { + if ($this->default) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('A default value and default children might not be used together at path "%s".', $path)); + } + if (null !== $this->key && (null === $this->addDefaultChildren || \is_int($this->addDefaultChildren) && $this->addDefaultChildren > 0)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->addDefaultChildrenIfNoneSet() should set default children names as ->useAttributeAsKey() is used at path "%s".', $path)); + } + if (null === $this->key && (\is_string($this->addDefaultChildren) || \is_array($this->addDefaultChildren))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException(\sprintf('->addDefaultChildrenIfNoneSet() might not set default children names as ->useAttributeAsKey() is not used at path "%s".', $path)); + } + } + } +} diff --git a/vendor/symfony/config/Definition/Builder/BooleanNodeDefinition.php b/vendor/symfony/config/Definition/Builder/BooleanNodeDefinition.php index 0ff95f86f..7d917f94e 100644 --- a/vendor/symfony/config/Definition/Builder/BooleanNodeDefinition.php +++ b/vendor/symfony/config/Definition/Builder/BooleanNodeDefinition.php @@ -1,48 +1,48 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException; -/** - * This class provides a fluent interface for defining a node. - * - * @author Johannes M. Schmitt - */ -class BooleanNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition -{ - /** - * {@inheritdoc} - */ - public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface $parent = null) - { - parent::__construct($name, $parent); - $this->nullEquivalent = \true; - } - /** - * Instantiate a Node. - * - * @return BooleanNode The node - */ - protected function instantiateNode() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode($this->name, $this->parent); - } - /** - * {@inheritdoc} - * - * @throws InvalidDefinitionException - */ - public function cannotBeEmpty() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException('->cannotBeEmpty() is not applicable to BooleanNodeDefinition.'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException; +/** + * This class provides a fluent interface for defining a node. + * + * @author Johannes M. Schmitt + */ +class BooleanNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition +{ + /** + * {@inheritdoc} + */ + public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface $parent = null) + { + parent::__construct($name, $parent); + $this->nullEquivalent = \true; + } + /** + * Instantiate a Node. + * + * @return BooleanNode The node + */ + protected function instantiateNode() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode($this->name, $this->parent); + } + /** + * {@inheritdoc} + * + * @throws InvalidDefinitionException + */ + public function cannotBeEmpty() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException('->cannotBeEmpty() is not applicable to BooleanNodeDefinition.'); + } +} diff --git a/vendor/symfony/config/Definition/Builder/EnumNodeDefinition.php b/vendor/symfony/config/Definition/Builder/EnumNodeDefinition.php index eda74aeef..fd71ef94f 100644 --- a/vendor/symfony/config/Definition/Builder/EnumNodeDefinition.php +++ b/vendor/symfony/config/Definition/Builder/EnumNodeDefinition.php @@ -1,48 +1,48 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode; -/** - * Enum Node Definition. - * - * @author Johannes M. Schmitt - */ -class EnumNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition -{ - private $values; - /** - * @return $this - */ - public function values(array $values) - { - $values = \array_unique($values); - if (empty($values)) { - throw new \InvalidArgumentException('->values() must be called with at least one value.'); - } - $this->values = $values; - return $this; - } - /** - * Instantiate a Node. - * - * @return EnumNode The node - * - * @throws \RuntimeException - */ - protected function instantiateNode() - { - if (null === $this->values) { - throw new \RuntimeException('You must call ->values() on enum nodes.'); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode($this->name, $this->parent, $this->values); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode; +/** + * Enum Node Definition. + * + * @author Johannes M. Schmitt + */ +class EnumNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition +{ + private $values; + /** + * @return $this + */ + public function values(array $values) + { + $values = \array_unique($values); + if (empty($values)) { + throw new \InvalidArgumentException('->values() must be called with at least one value.'); + } + $this->values = $values; + return $this; + } + /** + * Instantiate a Node. + * + * @return EnumNode The node + * + * @throws \RuntimeException + */ + protected function instantiateNode() + { + if (null === $this->values) { + throw new \RuntimeException('You must call ->values() on enum nodes.'); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode($this->name, $this->parent, $this->values); + } +} diff --git a/vendor/symfony/config/Definition/Builder/ExprBuilder.php b/vendor/symfony/config/Definition/Builder/ExprBuilder.php index 5805e193a..38849fb75 100644 --- a/vendor/symfony/config/Definition/Builder/ExprBuilder.php +++ b/vendor/symfony/config/Definition/Builder/ExprBuilder.php @@ -1,239 +1,239 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException; -/** - * This class builds an if expression. - * - * @author Johannes M. Schmitt - * @author Christophe Coevoet - */ -class ExprBuilder -{ - protected $node; - public $ifPart; - public $thenPart; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) - { - $this->node = $node; - } - /** - * Marks the expression as being always used. - * - * @return $this - */ - public function always(\Closure $then = null) - { - $this->ifPart = function ($v) { - return \true; - }; - if (null !== $then) { - $this->thenPart = $then; - } - return $this; - } - /** - * Sets a closure to use as tests. - * - * The default one tests if the value is true. - * - * @return $this - */ - public function ifTrue(\Closure $closure = null) - { - if (null === $closure) { - $closure = function ($v) { - return \true === $v; - }; - } - $this->ifPart = $closure; - return $this; - } - /** - * Tests if the value is a string. - * - * @return $this - */ - public function ifString() - { - $this->ifPart = function ($v) { - return \is_string($v); - }; - return $this; - } - /** - * Tests if the value is null. - * - * @return $this - */ - public function ifNull() - { - $this->ifPart = function ($v) { - return null === $v; - }; - return $this; - } - /** - * Tests if the value is empty. - * - * @return ExprBuilder - */ - public function ifEmpty() - { - $this->ifPart = function ($v) { - return empty($v); - }; - return $this; - } - /** - * Tests if the value is an array. - * - * @return $this - */ - public function ifArray() - { - $this->ifPart = function ($v) { - return \is_array($v); - }; - return $this; - } - /** - * Tests if the value is in an array. - * - * @return $this - */ - public function ifInArray(array $array) - { - $this->ifPart = function ($v) use($array) { - return \in_array($v, $array, \true); - }; - return $this; - } - /** - * Tests if the value is not in an array. - * - * @return $this - */ - public function ifNotInArray(array $array) - { - $this->ifPart = function ($v) use($array) { - return !\in_array($v, $array, \true); - }; - return $this; - } - /** - * Transforms variables of any type into an array. - * - * @return $this - */ - public function castToArray() - { - $this->ifPart = function ($v) { - return !\is_array($v); - }; - $this->thenPart = function ($v) { - return [$v]; - }; - return $this; - } - /** - * Sets the closure to run if the test pass. - * - * @return $this - */ - public function then(\Closure $closure) - { - $this->thenPart = $closure; - return $this; - } - /** - * Sets a closure returning an empty array. - * - * @return $this - */ - public function thenEmptyArray() - { - $this->thenPart = function ($v) { - return []; - }; - return $this; - } - /** - * Sets a closure marking the value as invalid at processing time. - * - * if you want to add the value of the node in your message just use a %s placeholder. - * - * @param string $message - * - * @return $this - * - * @throws \InvalidArgumentException - */ - public function thenInvalid($message) - { - $this->thenPart = function ($v) use($message) { - throw new \InvalidArgumentException(\sprintf($message, \json_encode($v))); - }; - return $this; - } - /** - * Sets a closure unsetting this key of the array at processing time. - * - * @return $this - * - * @throws UnsetKeyException - */ - public function thenUnset() - { - $this->thenPart = function ($v) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException('Unsetting key.'); - }; - return $this; - } - /** - * Returns the related node. - * - * @return NodeDefinition|ArrayNodeDefinition|VariableNodeDefinition - * - * @throws \RuntimeException - */ - public function end() - { - if (null === $this->ifPart) { - throw new \RuntimeException('You must specify an if part.'); - } - if (null === $this->thenPart) { - throw new \RuntimeException('You must specify a then part.'); - } - return $this->node; - } - /** - * Builds the expressions. - * - * @param ExprBuilder[] $expressions An array of ExprBuilder instances to build - * - * @return array - */ - public static function buildExpressions(array $expressions) - { - foreach ($expressions as $k => $expr) { - if ($expr instanceof self) { - $if = $expr->ifPart; - $then = $expr->thenPart; - $expressions[$k] = function ($v) use($if, $then) { - return $if($v) ? $then($v) : $v; - }; - } - } - return $expressions; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException; +/** + * This class builds an if expression. + * + * @author Johannes M. Schmitt + * @author Christophe Coevoet + */ +class ExprBuilder +{ + protected $node; + public $ifPart; + public $thenPart; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) + { + $this->node = $node; + } + /** + * Marks the expression as being always used. + * + * @return $this + */ + public function always(\Closure $then = null) + { + $this->ifPart = function ($v) { + return \true; + }; + if (null !== $then) { + $this->thenPart = $then; + } + return $this; + } + /** + * Sets a closure to use as tests. + * + * The default one tests if the value is true. + * + * @return $this + */ + public function ifTrue(\Closure $closure = null) + { + if (null === $closure) { + $closure = function ($v) { + return \true === $v; + }; + } + $this->ifPart = $closure; + return $this; + } + /** + * Tests if the value is a string. + * + * @return $this + */ + public function ifString() + { + $this->ifPart = function ($v) { + return \is_string($v); + }; + return $this; + } + /** + * Tests if the value is null. + * + * @return $this + */ + public function ifNull() + { + $this->ifPart = function ($v) { + return null === $v; + }; + return $this; + } + /** + * Tests if the value is empty. + * + * @return ExprBuilder + */ + public function ifEmpty() + { + $this->ifPart = function ($v) { + return empty($v); + }; + return $this; + } + /** + * Tests if the value is an array. + * + * @return $this + */ + public function ifArray() + { + $this->ifPart = function ($v) { + return \is_array($v); + }; + return $this; + } + /** + * Tests if the value is in an array. + * + * @return $this + */ + public function ifInArray(array $array) + { + $this->ifPart = function ($v) use($array) { + return \in_array($v, $array, \true); + }; + return $this; + } + /** + * Tests if the value is not in an array. + * + * @return $this + */ + public function ifNotInArray(array $array) + { + $this->ifPart = function ($v) use($array) { + return !\in_array($v, $array, \true); + }; + return $this; + } + /** + * Transforms variables of any type into an array. + * + * @return $this + */ + public function castToArray() + { + $this->ifPart = function ($v) { + return !\is_array($v); + }; + $this->thenPart = function ($v) { + return [$v]; + }; + return $this; + } + /** + * Sets the closure to run if the test pass. + * + * @return $this + */ + public function then(\Closure $closure) + { + $this->thenPart = $closure; + return $this; + } + /** + * Sets a closure returning an empty array. + * + * @return $this + */ + public function thenEmptyArray() + { + $this->thenPart = function ($v) { + return []; + }; + return $this; + } + /** + * Sets a closure marking the value as invalid at processing time. + * + * if you want to add the value of the node in your message just use a %s placeholder. + * + * @param string $message + * + * @return $this + * + * @throws \InvalidArgumentException + */ + public function thenInvalid($message) + { + $this->thenPart = function ($v) use($message) { + throw new \InvalidArgumentException(\sprintf($message, \json_encode($v))); + }; + return $this; + } + /** + * Sets a closure unsetting this key of the array at processing time. + * + * @return $this + * + * @throws UnsetKeyException + */ + public function thenUnset() + { + $this->thenPart = function ($v) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException('Unsetting key.'); + }; + return $this; + } + /** + * Returns the related node. + * + * @return NodeDefinition|ArrayNodeDefinition|VariableNodeDefinition + * + * @throws \RuntimeException + */ + public function end() + { + if (null === $this->ifPart) { + throw new \RuntimeException('You must specify an if part.'); + } + if (null === $this->thenPart) { + throw new \RuntimeException('You must specify a then part.'); + } + return $this->node; + } + /** + * Builds the expressions. + * + * @param ExprBuilder[] $expressions An array of ExprBuilder instances to build + * + * @return array + */ + public static function buildExpressions(array $expressions) + { + foreach ($expressions as $k => $expr) { + if ($expr instanceof self) { + $if = $expr->ifPart; + $then = $expr->thenPart; + $expressions[$k] = function ($v) use($if, $then) { + return $if($v) ? $then($v) : $v; + }; + } + } + return $expressions; + } +} diff --git a/vendor/symfony/config/Definition/Builder/FloatNodeDefinition.php b/vendor/symfony/config/Definition/Builder/FloatNodeDefinition.php index cddf14843..96a6640e6 100644 --- a/vendor/symfony/config/Definition/Builder/FloatNodeDefinition.php +++ b/vendor/symfony/config/Definition/Builder/FloatNodeDefinition.php @@ -1,30 +1,30 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode; -/** - * This class provides a fluent interface for defining a float node. - * - * @author Jeanmonod David - */ -class FloatNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NumericNodeDefinition -{ - /** - * Instantiates a Node. - * - * @return FloatNode The node - */ - protected function instantiateNode() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode($this->name, $this->parent, $this->min, $this->max); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode; +/** + * This class provides a fluent interface for defining a float node. + * + * @author Jeanmonod David + */ +class FloatNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NumericNodeDefinition +{ + /** + * Instantiates a Node. + * + * @return FloatNode The node + */ + protected function instantiateNode() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode($this->name, $this->parent, $this->min, $this->max); + } +} diff --git a/vendor/symfony/config/Definition/Builder/IntegerNodeDefinition.php b/vendor/symfony/config/Definition/Builder/IntegerNodeDefinition.php index 06591249d..19e75d84a 100644 --- a/vendor/symfony/config/Definition/Builder/IntegerNodeDefinition.php +++ b/vendor/symfony/config/Definition/Builder/IntegerNodeDefinition.php @@ -1,30 +1,30 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode; -/** - * This class provides a fluent interface for defining an integer node. - * - * @author Jeanmonod David - */ -class IntegerNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NumericNodeDefinition -{ - /** - * Instantiates a Node. - * - * @return IntegerNode The node - */ - protected function instantiateNode() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode($this->name, $this->parent, $this->min, $this->max); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode; +/** + * This class provides a fluent interface for defining an integer node. + * + * @author Jeanmonod David + */ +class IntegerNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NumericNodeDefinition +{ + /** + * Instantiates a Node. + * + * @return IntegerNode The node + */ + protected function instantiateNode() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode($this->name, $this->parent, $this->min, $this->max); + } +} diff --git a/vendor/symfony/config/Definition/Builder/MergeBuilder.php b/vendor/symfony/config/Definition/Builder/MergeBuilder.php index 6c2623163..f317d4e22 100644 --- a/vendor/symfony/config/Definition/Builder/MergeBuilder.php +++ b/vendor/symfony/config/Definition/Builder/MergeBuilder.php @@ -1,60 +1,60 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -/** - * This class builds merge conditions. - * - * @author Johannes M. Schmitt - */ -class MergeBuilder -{ - protected $node; - public $allowFalse = \false; - public $allowOverwrite = \true; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) - { - $this->node = $node; - } - /** - * Sets whether the node can be unset. - * - * @param bool $allow - * - * @return $this - */ - public function allowUnset($allow = \true) - { - $this->allowFalse = $allow; - return $this; - } - /** - * Sets whether the node can be overwritten. - * - * @param bool $deny Whether the overwriting is forbidden or not - * - * @return $this - */ - public function denyOverwrite($deny = \true) - { - $this->allowOverwrite = !$deny; - return $this; - } - /** - * Returns the related node. - * - * @return NodeDefinition|ArrayNodeDefinition|VariableNodeDefinition - */ - public function end() - { - return $this->node; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +/** + * This class builds merge conditions. + * + * @author Johannes M. Schmitt + */ +class MergeBuilder +{ + protected $node; + public $allowFalse = \false; + public $allowOverwrite = \true; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) + { + $this->node = $node; + } + /** + * Sets whether the node can be unset. + * + * @param bool $allow + * + * @return $this + */ + public function allowUnset($allow = \true) + { + $this->allowFalse = $allow; + return $this; + } + /** + * Sets whether the node can be overwritten. + * + * @param bool $deny Whether the overwriting is forbidden or not + * + * @return $this + */ + public function denyOverwrite($deny = \true) + { + $this->allowOverwrite = !$deny; + return $this; + } + /** + * Returns the related node. + * + * @return NodeDefinition|ArrayNodeDefinition|VariableNodeDefinition + */ + public function end() + { + return $this->node; + } +} diff --git a/vendor/symfony/config/Definition/Builder/NodeBuilder.php b/vendor/symfony/config/Definition/Builder/NodeBuilder.php index c5cfa11c1..aa5f1d574 100644 --- a/vendor/symfony/config/Definition/Builder/NodeBuilder.php +++ b/vendor/symfony/config/Definition/Builder/NodeBuilder.php @@ -1,204 +1,204 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -/** - * This class provides a fluent interface for building a node. - * - * @author Johannes M. Schmitt - */ -class NodeBuilder implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface -{ - protected $parent; - protected $nodeMapping; - public function __construct() - { - $this->nodeMapping = ['variable' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition::class, 'scalar' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition::class, 'boolean' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\BooleanNodeDefinition::class, 'integer' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition::class, 'float' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\FloatNodeDefinition::class, 'array' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition::class, 'enum' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition::class]; - } - /** - * Set the parent node. - * - * @return $this - */ - public function setParent(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ParentNodeDefinitionInterface $parent = null) - { - $this->parent = $parent; - return $this; - } - /** - * Creates a child array node. - * - * @param string $name The name of the node - * - * @return ArrayNodeDefinition The child node - */ - public function arrayNode($name) - { - return $this->node($name, 'array'); - } - /** - * Creates a child scalar node. - * - * @param string $name The name of the node - * - * @return ScalarNodeDefinition The child node - */ - public function scalarNode($name) - { - return $this->node($name, 'scalar'); - } - /** - * Creates a child Boolean node. - * - * @param string $name The name of the node - * - * @return BooleanNodeDefinition The child node - */ - public function booleanNode($name) - { - return $this->node($name, 'boolean'); - } - /** - * Creates a child integer node. - * - * @param string $name The name of the node - * - * @return IntegerNodeDefinition The child node - */ - public function integerNode($name) - { - return $this->node($name, 'integer'); - } - /** - * Creates a child float node. - * - * @param string $name The name of the node - * - * @return FloatNodeDefinition The child node - */ - public function floatNode($name) - { - return $this->node($name, 'float'); - } - /** - * Creates a child EnumNode. - * - * @param string $name - * - * @return EnumNodeDefinition - */ - public function enumNode($name) - { - return $this->node($name, 'enum'); - } - /** - * Creates a child variable node. - * - * @param string $name The name of the node - * - * @return VariableNodeDefinition The builder of the child node - */ - public function variableNode($name) - { - return $this->node($name, 'variable'); - } - /** - * Returns the parent node. - * - * @return NodeDefinition&ParentNodeDefinitionInterface The parent node - */ - public function end() - { - return $this->parent; - } - /** - * Creates a child node. - * - * @param string|null $name The name of the node - * @param string $type The type of the node - * - * @return NodeDefinition The child node - * - * @throws \RuntimeException When the node type is not registered - * @throws \RuntimeException When the node class is not found - */ - public function node($name, $type) - { - $class = $this->getNodeClass($type); - $node = new $class($name); - $this->append($node); - return $node; - } - /** - * Appends a node definition. - * - * Usage: - * - * $node = new ArrayNodeDefinition('name') - * ->children() - * ->scalarNode('foo')->end() - * ->scalarNode('baz')->end() - * ->append($this->getBarNodeDefinition()) - * ->end() - * ; - * - * @return $this - */ - public function append(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) - { - if ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ParentNodeDefinitionInterface) { - $builder = clone $this; - $builder->setParent(null); - $node->setBuilder($builder); - } - if (null !== $this->parent) { - $this->parent->append($node); - // Make this builder the node parent to allow for a fluid interface - $node->setParent($this); - } - return $this; - } - /** - * Adds or overrides a node Type. - * - * @param string $type The name of the type - * @param string $class The fully qualified name the node definition class - * - * @return $this - */ - public function setNodeClass($type, $class) - { - $this->nodeMapping[\strtolower($type)] = $class; - return $this; - } - /** - * Returns the class name of the node definition. - * - * @param string $type The node type - * - * @return string The node definition class name - * - * @throws \RuntimeException When the node type is not registered - * @throws \RuntimeException When the node class is not found - */ - protected function getNodeClass($type) - { - $type = \strtolower($type); - if (!isset($this->nodeMapping[$type])) { - throw new \RuntimeException(\sprintf('The node type "%s" is not registered.', $type)); - } - $class = $this->nodeMapping[$type]; - if (!\class_exists($class)) { - throw new \RuntimeException(\sprintf('The node class "%s" does not exist.', $class)); - } - return $class; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +/** + * This class provides a fluent interface for building a node. + * + * @author Johannes M. Schmitt + */ +class NodeBuilder implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface +{ + protected $parent; + protected $nodeMapping; + public function __construct() + { + $this->nodeMapping = ['variable' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition::class, 'scalar' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition::class, 'boolean' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\BooleanNodeDefinition::class, 'integer' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition::class, 'float' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\FloatNodeDefinition::class, 'array' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition::class, 'enum' => \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition::class]; + } + /** + * Set the parent node. + * + * @return $this + */ + public function setParent(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ParentNodeDefinitionInterface $parent = null) + { + $this->parent = $parent; + return $this; + } + /** + * Creates a child array node. + * + * @param string $name The name of the node + * + * @return ArrayNodeDefinition The child node + */ + public function arrayNode($name) + { + return $this->node($name, 'array'); + } + /** + * Creates a child scalar node. + * + * @param string $name The name of the node + * + * @return ScalarNodeDefinition The child node + */ + public function scalarNode($name) + { + return $this->node($name, 'scalar'); + } + /** + * Creates a child Boolean node. + * + * @param string $name The name of the node + * + * @return BooleanNodeDefinition The child node + */ + public function booleanNode($name) + { + return $this->node($name, 'boolean'); + } + /** + * Creates a child integer node. + * + * @param string $name The name of the node + * + * @return IntegerNodeDefinition The child node + */ + public function integerNode($name) + { + return $this->node($name, 'integer'); + } + /** + * Creates a child float node. + * + * @param string $name The name of the node + * + * @return FloatNodeDefinition The child node + */ + public function floatNode($name) + { + return $this->node($name, 'float'); + } + /** + * Creates a child EnumNode. + * + * @param string $name + * + * @return EnumNodeDefinition + */ + public function enumNode($name) + { + return $this->node($name, 'enum'); + } + /** + * Creates a child variable node. + * + * @param string $name The name of the node + * + * @return VariableNodeDefinition The builder of the child node + */ + public function variableNode($name) + { + return $this->node($name, 'variable'); + } + /** + * Returns the parent node. + * + * @return NodeDefinition&ParentNodeDefinitionInterface The parent node + */ + public function end() + { + return $this->parent; + } + /** + * Creates a child node. + * + * @param string|null $name The name of the node + * @param string $type The type of the node + * + * @return NodeDefinition The child node + * + * @throws \RuntimeException When the node type is not registered + * @throws \RuntimeException When the node class is not found + */ + public function node($name, $type) + { + $class = $this->getNodeClass($type); + $node = new $class($name); + $this->append($node); + return $node; + } + /** + * Appends a node definition. + * + * Usage: + * + * $node = new ArrayNodeDefinition('name') + * ->children() + * ->scalarNode('foo')->end() + * ->scalarNode('baz')->end() + * ->append($this->getBarNodeDefinition()) + * ->end() + * ; + * + * @return $this + */ + public function append(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) + { + if ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ParentNodeDefinitionInterface) { + $builder = clone $this; + $builder->setParent(null); + $node->setBuilder($builder); + } + if (null !== $this->parent) { + $this->parent->append($node); + // Make this builder the node parent to allow for a fluid interface + $node->setParent($this); + } + return $this; + } + /** + * Adds or overrides a node Type. + * + * @param string $type The name of the type + * @param string $class The fully qualified name the node definition class + * + * @return $this + */ + public function setNodeClass($type, $class) + { + $this->nodeMapping[\strtolower($type)] = $class; + return $this; + } + /** + * Returns the class name of the node definition. + * + * @param string $type The node type + * + * @return string The node definition class name + * + * @throws \RuntimeException When the node type is not registered + * @throws \RuntimeException When the node class is not found + */ + protected function getNodeClass($type) + { + $type = \strtolower($type); + if (!isset($this->nodeMapping[$type])) { + throw new \RuntimeException(\sprintf('The node type "%s" is not registered.', $type)); + } + $class = $this->nodeMapping[$type]; + if (!\class_exists($class)) { + throw new \RuntimeException(\sprintf('The node class "%s" does not exist.', $class)); + } + return $class; + } +} diff --git a/vendor/symfony/config/Definition/Builder/NodeDefinition.php b/vendor/symfony/config/Definition/Builder/NodeDefinition.php index 44ee3faa6..b0012d216 100644 --- a/vendor/symfony/config/Definition/Builder/NodeDefinition.php +++ b/vendor/symfony/config/Definition/Builder/NodeDefinition.php @@ -1,310 +1,310 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; -/** - * This class provides a fluent interface for defining a node. - * - * @author Johannes M. Schmitt - */ -abstract class NodeDefinition implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface -{ - protected $name; - protected $normalization; - protected $validation; - protected $defaultValue; - protected $default = \false; - protected $required = \false; - protected $deprecationMessage = null; - protected $merge; - protected $allowEmptyValue = \true; - protected $nullEquivalent; - protected $trueEquivalent = \true; - protected $falseEquivalent = \false; - protected $parent; - protected $attributes = []; - /** - * @param string|null $name The name of the node - * @param NodeParentInterface|null $parent The parent - */ - public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface $parent = null) - { - $this->parent = $parent; - $this->name = $name; - } - /** - * Sets the parent node. - * - * @return $this - */ - public function setParent(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface $parent) - { - $this->parent = $parent; - return $this; - } - /** - * Sets info message. - * - * @param string $info The info text - * - * @return $this - */ - public function info($info) - { - return $this->attribute('info', $info); - } - /** - * Sets example configuration. - * - * @param string|array $example - * - * @return $this - */ - public function example($example) - { - return $this->attribute('example', $example); - } - /** - * Sets an attribute on the node. - * - * @param string $key - * @param mixed $value - * - * @return $this - */ - public function attribute($key, $value) - { - $this->attributes[$key] = $value; - return $this; - } - /** - * Returns the parent node. - * - * @return NodeParentInterface|NodeBuilder|NodeDefinition|ArrayNodeDefinition|VariableNodeDefinition|null The builder of the parent node - */ - public function end() - { - return $this->parent; - } - /** - * Creates the node. - * - * @param bool $forceRootNode Whether to force this node as the root node - * - * @return NodeInterface - */ - public function getNode($forceRootNode = \false) - { - if ($forceRootNode) { - $this->parent = null; - } - if (null !== $this->normalization) { - $this->normalization->before = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ExprBuilder::buildExpressions($this->normalization->before); - } - if (null !== $this->validation) { - $this->validation->rules = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ExprBuilder::buildExpressions($this->validation->rules); - } - $node = $this->createNode(); - $node->setAttributes($this->attributes); - return $node; - } - /** - * Sets the default value. - * - * @param mixed $value The default value - * - * @return $this - */ - public function defaultValue($value) - { - $this->default = \true; - $this->defaultValue = $value; - return $this; - } - /** - * Sets the node as required. - * - * @return $this - */ - public function isRequired() - { - $this->required = \true; - return $this; - } - /** - * Sets the node as deprecated. - * - * You can use %node% and %path% placeholders in your message to display, - * respectively, the node name and its complete path. - * - * @param string $message Deprecation message - * - * @return $this - */ - public function setDeprecated($message = 'The child node "%node%" at path "%path%" is deprecated.') - { - $this->deprecationMessage = $message; - return $this; - } - /** - * Sets the equivalent value used when the node contains null. - * - * @param mixed $value - * - * @return $this - */ - public function treatNullLike($value) - { - $this->nullEquivalent = $value; - return $this; - } - /** - * Sets the equivalent value used when the node contains true. - * - * @param mixed $value - * - * @return $this - */ - public function treatTrueLike($value) - { - $this->trueEquivalent = $value; - return $this; - } - /** - * Sets the equivalent value used when the node contains false. - * - * @param mixed $value - * - * @return $this - */ - public function treatFalseLike($value) - { - $this->falseEquivalent = $value; - return $this; - } - /** - * Sets null as the default value. - * - * @return $this - */ - public function defaultNull() - { - return $this->defaultValue(null); - } - /** - * Sets true as the default value. - * - * @return $this - */ - public function defaultTrue() - { - return $this->defaultValue(\true); - } - /** - * Sets false as the default value. - * - * @return $this - */ - public function defaultFalse() - { - return $this->defaultValue(\false); - } - /** - * Sets an expression to run before the normalization. - * - * @return ExprBuilder - */ - public function beforeNormalization() - { - return $this->normalization()->before(); - } - /** - * Denies the node value being empty. - * - * @return $this - */ - public function cannotBeEmpty() - { - $this->allowEmptyValue = \false; - return $this; - } - /** - * Sets an expression to run for the validation. - * - * The expression receives the value of the node and must return it. It can - * modify it. - * An exception should be thrown when the node is not valid. - * - * @return ExprBuilder - */ - public function validate() - { - return $this->validation()->rule(); - } - /** - * Sets whether the node can be overwritten. - * - * @param bool $deny Whether the overwriting is forbidden or not - * - * @return $this - */ - public function cannotBeOverwritten($deny = \true) - { - $this->merge()->denyOverwrite($deny); - return $this; - } - /** - * Gets the builder for validation rules. - * - * @return ValidationBuilder - */ - protected function validation() - { - if (null === $this->validation) { - $this->validation = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ValidationBuilder($this); - } - return $this->validation; - } - /** - * Gets the builder for merging rules. - * - * @return MergeBuilder - */ - protected function merge() - { - if (null === $this->merge) { - $this->merge = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\MergeBuilder($this); - } - return $this->merge; - } - /** - * Gets the builder for normalization rules. - * - * @return NormalizationBuilder - */ - protected function normalization() - { - if (null === $this->normalization) { - $this->normalization = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NormalizationBuilder($this); - } - return $this->normalization; - } - /** - * Instantiate and configure the node according to this definition. - * - * @return NodeInterface The node instance - * - * @throws InvalidDefinitionException When the definition is invalid - */ - protected abstract function createNode(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; +/** + * This class provides a fluent interface for defining a node. + * + * @author Johannes M. Schmitt + */ +abstract class NodeDefinition implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface +{ + protected $name; + protected $normalization; + protected $validation; + protected $defaultValue; + protected $default = \false; + protected $required = \false; + protected $deprecationMessage = null; + protected $merge; + protected $allowEmptyValue = \true; + protected $nullEquivalent; + protected $trueEquivalent = \true; + protected $falseEquivalent = \false; + protected $parent; + protected $attributes = []; + /** + * @param string|null $name The name of the node + * @param NodeParentInterface|null $parent The parent + */ + public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface $parent = null) + { + $this->parent = $parent; + $this->name = $name; + } + /** + * Sets the parent node. + * + * @return $this + */ + public function setParent(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface $parent) + { + $this->parent = $parent; + return $this; + } + /** + * Sets info message. + * + * @param string $info The info text + * + * @return $this + */ + public function info($info) + { + return $this->attribute('info', $info); + } + /** + * Sets example configuration. + * + * @param string|array $example + * + * @return $this + */ + public function example($example) + { + return $this->attribute('example', $example); + } + /** + * Sets an attribute on the node. + * + * @param string $key + * @param mixed $value + * + * @return $this + */ + public function attribute($key, $value) + { + $this->attributes[$key] = $value; + return $this; + } + /** + * Returns the parent node. + * + * @return NodeParentInterface|NodeBuilder|NodeDefinition|ArrayNodeDefinition|VariableNodeDefinition|null The builder of the parent node + */ + public function end() + { + return $this->parent; + } + /** + * Creates the node. + * + * @param bool $forceRootNode Whether to force this node as the root node + * + * @return NodeInterface + */ + public function getNode($forceRootNode = \false) + { + if ($forceRootNode) { + $this->parent = null; + } + if (null !== $this->normalization) { + $this->normalization->before = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ExprBuilder::buildExpressions($this->normalization->before); + } + if (null !== $this->validation) { + $this->validation->rules = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ExprBuilder::buildExpressions($this->validation->rules); + } + $node = $this->createNode(); + $node->setAttributes($this->attributes); + return $node; + } + /** + * Sets the default value. + * + * @param mixed $value The default value + * + * @return $this + */ + public function defaultValue($value) + { + $this->default = \true; + $this->defaultValue = $value; + return $this; + } + /** + * Sets the node as required. + * + * @return $this + */ + public function isRequired() + { + $this->required = \true; + return $this; + } + /** + * Sets the node as deprecated. + * + * You can use %node% and %path% placeholders in your message to display, + * respectively, the node name and its complete path. + * + * @param string $message Deprecation message + * + * @return $this + */ + public function setDeprecated($message = 'The child node "%node%" at path "%path%" is deprecated.') + { + $this->deprecationMessage = $message; + return $this; + } + /** + * Sets the equivalent value used when the node contains null. + * + * @param mixed $value + * + * @return $this + */ + public function treatNullLike($value) + { + $this->nullEquivalent = $value; + return $this; + } + /** + * Sets the equivalent value used when the node contains true. + * + * @param mixed $value + * + * @return $this + */ + public function treatTrueLike($value) + { + $this->trueEquivalent = $value; + return $this; + } + /** + * Sets the equivalent value used when the node contains false. + * + * @param mixed $value + * + * @return $this + */ + public function treatFalseLike($value) + { + $this->falseEquivalent = $value; + return $this; + } + /** + * Sets null as the default value. + * + * @return $this + */ + public function defaultNull() + { + return $this->defaultValue(null); + } + /** + * Sets true as the default value. + * + * @return $this + */ + public function defaultTrue() + { + return $this->defaultValue(\true); + } + /** + * Sets false as the default value. + * + * @return $this + */ + public function defaultFalse() + { + return $this->defaultValue(\false); + } + /** + * Sets an expression to run before the normalization. + * + * @return ExprBuilder + */ + public function beforeNormalization() + { + return $this->normalization()->before(); + } + /** + * Denies the node value being empty. + * + * @return $this + */ + public function cannotBeEmpty() + { + $this->allowEmptyValue = \false; + return $this; + } + /** + * Sets an expression to run for the validation. + * + * The expression receives the value of the node and must return it. It can + * modify it. + * An exception should be thrown when the node is not valid. + * + * @return ExprBuilder + */ + public function validate() + { + return $this->validation()->rule(); + } + /** + * Sets whether the node can be overwritten. + * + * @param bool $deny Whether the overwriting is forbidden or not + * + * @return $this + */ + public function cannotBeOverwritten($deny = \true) + { + $this->merge()->denyOverwrite($deny); + return $this; + } + /** + * Gets the builder for validation rules. + * + * @return ValidationBuilder + */ + protected function validation() + { + if (null === $this->validation) { + $this->validation = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ValidationBuilder($this); + } + return $this->validation; + } + /** + * Gets the builder for merging rules. + * + * @return MergeBuilder + */ + protected function merge() + { + if (null === $this->merge) { + $this->merge = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\MergeBuilder($this); + } + return $this->merge; + } + /** + * Gets the builder for normalization rules. + * + * @return NormalizationBuilder + */ + protected function normalization() + { + if (null === $this->normalization) { + $this->normalization = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NormalizationBuilder($this); + } + return $this->normalization; + } + /** + * Instantiate and configure the node according to this definition. + * + * @return NodeInterface The node instance + * + * @throws InvalidDefinitionException When the definition is invalid + */ + protected abstract function createNode(); +} diff --git a/vendor/symfony/config/Definition/Builder/NodeParentInterface.php b/vendor/symfony/config/Definition/Builder/NodeParentInterface.php index 18366db8f..1914204ae 100644 --- a/vendor/symfony/config/Definition/Builder/NodeParentInterface.php +++ b/vendor/symfony/config/Definition/Builder/NodeParentInterface.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -/** - * An interface that must be implemented by all node parents. - * - * @author Victor Berchet - */ -interface NodeParentInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +/** + * An interface that must be implemented by all node parents. + * + * @author Victor Berchet + */ +interface NodeParentInterface +{ +} diff --git a/vendor/symfony/config/Definition/Builder/NormalizationBuilder.php b/vendor/symfony/config/Definition/Builder/NormalizationBuilder.php index ee7ca162d..9fa02170b 100644 --- a/vendor/symfony/config/Definition/Builder/NormalizationBuilder.php +++ b/vendor/symfony/config/Definition/Builder/NormalizationBuilder.php @@ -1,53 +1,53 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -/** - * This class builds normalization conditions. - * - * @author Johannes M. Schmitt - */ -class NormalizationBuilder -{ - protected $node; - public $before = []; - public $remappings = []; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) - { - $this->node = $node; - } - /** - * Registers a key to remap to its plural form. - * - * @param string $key The key to remap - * @param string $plural The plural of the key in case of irregular plural - * - * @return $this - */ - public function remap($key, $plural = null) - { - $this->remappings[] = [$key, null === $plural ? $key . 's' : $plural]; - return $this; - } - /** - * Registers a closure to run before the normalization or an expression builder to build it if null is provided. - * - * @return ExprBuilder|$this - */ - public function before(\Closure $closure = null) - { - if (null !== $closure) { - $this->before[] = $closure; - return $this; - } - return $this->before[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ExprBuilder($this->node); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +/** + * This class builds normalization conditions. + * + * @author Johannes M. Schmitt + */ +class NormalizationBuilder +{ + protected $node; + public $before = []; + public $remappings = []; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) + { + $this->node = $node; + } + /** + * Registers a key to remap to its plural form. + * + * @param string $key The key to remap + * @param string $plural The plural of the key in case of irregular plural + * + * @return $this + */ + public function remap($key, $plural = null) + { + $this->remappings[] = [$key, null === $plural ? $key . 's' : $plural]; + return $this; + } + /** + * Registers a closure to run before the normalization or an expression builder to build it if null is provided. + * + * @return ExprBuilder|$this + */ + public function before(\Closure $closure = null) + { + if (null !== $closure) { + $this->before[] = $closure; + return $this; + } + return $this->before[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ExprBuilder($this->node); + } +} diff --git a/vendor/symfony/config/Definition/Builder/NumericNodeDefinition.php b/vendor/symfony/config/Definition/Builder/NumericNodeDefinition.php index 430aa522e..d3ba17aea 100644 --- a/vendor/symfony/config/Definition/Builder/NumericNodeDefinition.php +++ b/vendor/symfony/config/Definition/Builder/NumericNodeDefinition.php @@ -1,66 +1,66 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException; -/** - * Abstract class that contains common code of integer and float node definitions. - * - * @author David Jeanmonod - */ -abstract class NumericNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition -{ - protected $min; - protected $max; - /** - * Ensures that the value is smaller than the given reference. - * - * @param mixed $max - * - * @return $this - * - * @throws \InvalidArgumentException when the constraint is inconsistent - */ - public function max($max) - { - if (isset($this->min) && $this->min > $max) { - throw new \InvalidArgumentException(\sprintf('You cannot define a max(%s) as you already have a min(%s).', $max, $this->min)); - } - $this->max = $max; - return $this; - } - /** - * Ensures that the value is bigger than the given reference. - * - * @param mixed $min - * - * @return $this - * - * @throws \InvalidArgumentException when the constraint is inconsistent - */ - public function min($min) - { - if (isset($this->max) && $this->max < $min) { - throw new \InvalidArgumentException(\sprintf('You cannot define a min(%s) as you already have a max(%s).', $min, $this->max)); - } - $this->min = $min; - return $this; - } - /** - * {@inheritdoc} - * - * @throws InvalidDefinitionException - */ - public function cannotBeEmpty() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException('->cannotBeEmpty() is not applicable to NumericNodeDefinition.'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException; +/** + * Abstract class that contains common code of integer and float node definitions. + * + * @author David Jeanmonod + */ +abstract class NumericNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition +{ + protected $min; + protected $max; + /** + * Ensures that the value is smaller than the given reference. + * + * @param mixed $max + * + * @return $this + * + * @throws \InvalidArgumentException when the constraint is inconsistent + */ + public function max($max) + { + if (isset($this->min) && $this->min > $max) { + throw new \InvalidArgumentException(\sprintf('You cannot define a max(%s) as you already have a min(%s).', $max, $this->min)); + } + $this->max = $max; + return $this; + } + /** + * Ensures that the value is bigger than the given reference. + * + * @param mixed $min + * + * @return $this + * + * @throws \InvalidArgumentException when the constraint is inconsistent + */ + public function min($min) + { + if (isset($this->max) && $this->max < $min) { + throw new \InvalidArgumentException(\sprintf('You cannot define a min(%s) as you already have a max(%s).', $min, $this->max)); + } + $this->min = $min; + return $this; + } + /** + * {@inheritdoc} + * + * @throws InvalidDefinitionException + */ + public function cannotBeEmpty() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException('->cannotBeEmpty() is not applicable to NumericNodeDefinition.'); + } +} diff --git a/vendor/symfony/config/Definition/Builder/ParentNodeDefinitionInterface.php b/vendor/symfony/config/Definition/Builder/ParentNodeDefinitionInterface.php index c508114bb..deadeedbf 100644 --- a/vendor/symfony/config/Definition/Builder/ParentNodeDefinitionInterface.php +++ b/vendor/symfony/config/Definition/Builder/ParentNodeDefinitionInterface.php @@ -1,46 +1,46 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -/** - * An interface that must be implemented by nodes which can have children. - * - * @author Victor Berchet - */ -interface ParentNodeDefinitionInterface -{ - /** - * Returns a builder to add children nodes. - * - * @return NodeBuilder - */ - public function children(); - /** - * Appends a node definition. - * - * Usage: - * - * $node = $parentNode - * ->children() - * ->scalarNode('foo')->end() - * ->scalarNode('baz')->end() - * ->append($this->getBarNodeDefinition()) - * ->end() - * ; - * - * @return $this - */ - public function append(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node); - /** - * Sets a custom children builder. - */ - public function setBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder $builder); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +/** + * An interface that must be implemented by nodes which can have children. + * + * @author Victor Berchet + */ +interface ParentNodeDefinitionInterface +{ + /** + * Returns a builder to add children nodes. + * + * @return NodeBuilder + */ + public function children(); + /** + * Appends a node definition. + * + * Usage: + * + * $node = $parentNode + * ->children() + * ->scalarNode('foo')->end() + * ->scalarNode('baz')->end() + * ->append($this->getBarNodeDefinition()) + * ->end() + * ; + * + * @return $this + */ + public function append(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node); + /** + * Sets a custom children builder. + */ + public function setBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder $builder); +} diff --git a/vendor/symfony/config/Definition/Builder/ScalarNodeDefinition.php b/vendor/symfony/config/Definition/Builder/ScalarNodeDefinition.php index 5384358c7..0cdc3971d 100644 --- a/vendor/symfony/config/Definition/Builder/ScalarNodeDefinition.php +++ b/vendor/symfony/config/Definition/Builder/ScalarNodeDefinition.php @@ -1,30 +1,30 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode; -/** - * This class provides a fluent interface for defining a node. - * - * @author Johannes M. Schmitt - */ -class ScalarNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition -{ - /** - * Instantiate a Node. - * - * @return ScalarNode The node - */ - protected function instantiateNode() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode($this->name, $this->parent); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode; +/** + * This class provides a fluent interface for defining a node. + * + * @author Johannes M. Schmitt + */ +class ScalarNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition +{ + /** + * Instantiate a Node. + * + * @return ScalarNode The node + */ + protected function instantiateNode() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode($this->name, $this->parent); + } +} diff --git a/vendor/symfony/config/Definition/Builder/TreeBuilder.php b/vendor/symfony/config/Definition/Builder/TreeBuilder.php index b0c17d844..5209b00c1 100644 --- a/vendor/symfony/config/Definition/Builder/TreeBuilder.php +++ b/vendor/symfony/config/Definition/Builder/TreeBuilder.php @@ -1,60 +1,60 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; -/** - * This is the entry class for building a config tree. - * - * @author Johannes M. Schmitt - */ -class TreeBuilder implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface -{ - protected $tree; - protected $root; - /** - * @deprecated since 3.4. To be removed in 4.0 - */ - protected $builder; - /** - * Creates the root node. - * - * @param string $name The name of the root node - * @param string $type The type of the root node - * @param NodeBuilder $builder A custom node builder instance - * - * @return ArrayNodeDefinition|NodeDefinition The root node (as an ArrayNodeDefinition when the type is 'array') - * - * @throws \RuntimeException When the node type is not supported - */ - public function root($name, $type = 'array', \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder $builder = null) - { - $builder = $builder ?: new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); - return $this->root = $builder->node($name, $type)->setParent($this); - } - /** - * Builds the tree. - * - * @return NodeInterface - * - * @throws \RuntimeException - */ - public function buildTree() - { - if (null === $this->root) { - throw new \RuntimeException('The configuration tree has no root node.'); - } - if (null !== $this->tree) { - return $this->tree; - } - return $this->tree = $this->root->getNode(\true); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; +/** + * This is the entry class for building a config tree. + * + * @author Johannes M. Schmitt + */ +class TreeBuilder implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeParentInterface +{ + protected $tree; + protected $root; + /** + * @deprecated since 3.4. To be removed in 4.0 + */ + protected $builder; + /** + * Creates the root node. + * + * @param string $name The name of the root node + * @param string $type The type of the root node + * @param NodeBuilder $builder A custom node builder instance + * + * @return ArrayNodeDefinition|NodeDefinition The root node (as an ArrayNodeDefinition when the type is 'array') + * + * @throws \RuntimeException When the node type is not supported + */ + public function root($name, $type = 'array', \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder $builder = null) + { + $builder = $builder ?: new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); + return $this->root = $builder->node($name, $type)->setParent($this); + } + /** + * Builds the tree. + * + * @return NodeInterface + * + * @throws \RuntimeException + */ + public function buildTree() + { + if (null === $this->root) { + throw new \RuntimeException('The configuration tree has no root node.'); + } + if (null !== $this->tree) { + return $this->tree; + } + return $this->tree = $this->root->getNode(\true); + } +} diff --git a/vendor/symfony/config/Definition/Builder/ValidationBuilder.php b/vendor/symfony/config/Definition/Builder/ValidationBuilder.php index c9b69948c..ec20b7424 100644 --- a/vendor/symfony/config/Definition/Builder/ValidationBuilder.php +++ b/vendor/symfony/config/Definition/Builder/ValidationBuilder.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -/** - * This class builds validation conditions. - * - * @author Christophe Coevoet - */ -class ValidationBuilder -{ - protected $node; - public $rules = []; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) - { - $this->node = $node; - } - /** - * Registers a closure to run as normalization or an expression builder to build it if null is provided. - * - * @return ExprBuilder|$this - */ - public function rule(\Closure $closure = null) - { - if (null !== $closure) { - $this->rules[] = $closure; - return $this; - } - return $this->rules[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ExprBuilder($this->node); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +/** + * This class builds validation conditions. + * + * @author Christophe Coevoet + */ +class ValidationBuilder +{ + protected $node; + public $rules = []; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition $node) + { + $this->node = $node; + } + /** + * Registers a closure to run as normalization or an expression builder to build it if null is provided. + * + * @return ExprBuilder|$this + */ + public function rule(\Closure $closure = null) + { + if (null !== $closure) { + $this->rules[] = $closure; + return $this; + } + return $this->rules[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ExprBuilder($this->node); + } +} diff --git a/vendor/symfony/config/Definition/Builder/VariableNodeDefinition.php b/vendor/symfony/config/Definition/Builder/VariableNodeDefinition.php index c00028d90..4ab6d2db1 100644 --- a/vendor/symfony/config/Definition/Builder/VariableNodeDefinition.php +++ b/vendor/symfony/config/Definition/Builder/VariableNodeDefinition.php @@ -1,56 +1,56 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\VariableNode; -/** - * This class provides a fluent interface for defining a node. - * - * @author Johannes M. Schmitt - */ -class VariableNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition -{ - /** - * Instantiate a Node. - * - * @return VariableNode The node - */ - protected function instantiateNode() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\VariableNode($this->name, $this->parent); - } - /** - * {@inheritdoc} - */ - protected function createNode() - { - $node = $this->instantiateNode(); - if (null !== $this->normalization) { - $node->setNormalizationClosures($this->normalization->before); - } - if (null !== $this->merge) { - $node->setAllowOverwrite($this->merge->allowOverwrite); - } - if (\true === $this->default) { - $node->setDefaultValue($this->defaultValue); - } - $node->setAllowEmptyValue($this->allowEmptyValue); - $node->addEquivalentValue(null, $this->nullEquivalent); - $node->addEquivalentValue(\true, $this->trueEquivalent); - $node->addEquivalentValue(\false, $this->falseEquivalent); - $node->setRequired($this->required); - $node->setDeprecated($this->deprecationMessage); - if (null !== $this->validation) { - $node->setFinalValidationClosures($this->validation->rules); - } - return $node; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\VariableNode; +/** + * This class provides a fluent interface for defining a node. + * + * @author Johannes M. Schmitt + */ +class VariableNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition +{ + /** + * Instantiate a Node. + * + * @return VariableNode The node + */ + protected function instantiateNode() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\VariableNode($this->name, $this->parent); + } + /** + * {@inheritdoc} + */ + protected function createNode() + { + $node = $this->instantiateNode(); + if (null !== $this->normalization) { + $node->setNormalizationClosures($this->normalization->before); + } + if (null !== $this->merge) { + $node->setAllowOverwrite($this->merge->allowOverwrite); + } + if (\true === $this->default) { + $node->setDefaultValue($this->defaultValue); + } + $node->setAllowEmptyValue($this->allowEmptyValue); + $node->addEquivalentValue(null, $this->nullEquivalent); + $node->addEquivalentValue(\true, $this->trueEquivalent); + $node->addEquivalentValue(\false, $this->falseEquivalent); + $node->setRequired($this->required); + $node->setDeprecated($this->deprecationMessage); + if (null !== $this->validation) { + $node->setFinalValidationClosures($this->validation->rules); + } + return $node; + } +} diff --git a/vendor/symfony/config/Definition/Builder/index.php b/vendor/symfony/config/Definition/Builder/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Definition/Builder/index.php +++ b/vendor/symfony/config/Definition/Builder/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Definition/ConfigurationInterface.php b/vendor/symfony/config/Definition/ConfigurationInterface.php index 7eb7956fe..9daa68d80 100644 --- a/vendor/symfony/config/Definition/ConfigurationInterface.php +++ b/vendor/symfony/config/Definition/ConfigurationInterface.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -/** - * Configuration interface. - * - * @author Victor Berchet - */ -interface ConfigurationInterface -{ - /** - * Generates the configuration tree builder. - * - * @return \Symfony\Component\Config\Definition\Builder\TreeBuilder The tree builder - */ - public function getConfigTreeBuilder(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +/** + * Configuration interface. + * + * @author Victor Berchet + */ +interface ConfigurationInterface +{ + /** + * Generates the configuration tree builder. + * + * @return \Symfony\Component\Config\Definition\Builder\TreeBuilder The tree builder + */ + public function getConfigTreeBuilder(); +} diff --git a/vendor/symfony/config/Definition/Dumper/XmlReferenceDumper.php b/vendor/symfony/config/Definition/Dumper/XmlReferenceDumper.php index d6f4f90e8..cc4474719 100644 --- a/vendor/symfony/config/Definition/Dumper/XmlReferenceDumper.php +++ b/vendor/symfony/config/Definition/Dumper/XmlReferenceDumper.php @@ -1,257 +1,257 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode; -/** - * Dumps a XML reference configuration for the given configuration/node instance. - * - * @author Wouter J - */ -class XmlReferenceDumper -{ - private $reference; - public function dump(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface $configuration, $namespace = null) - { - return $this->dumpNode($configuration->getConfigTreeBuilder()->buildTree(), $namespace); - } - public function dumpNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node, $namespace = null) - { - $this->reference = ''; - $this->writeNode($node, 0, \true, $namespace); - $ref = $this->reference; - $this->reference = null; - return $ref; - } - /** - * @param int $depth - * @param bool $root If the node is the root node - * @param string $namespace The namespace of the node - */ - private function writeNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node, $depth = 0, $root = \false, $namespace = null) - { - $rootName = $root ? 'config' : $node->getName(); - $rootNamespace = $namespace ?: ($root ? 'http://example.org/schema/dic/' . $node->getName() : null); - // xml remapping - if ($node->getParent()) { - $remapping = \array_filter($node->getParent()->getXmlRemappings(), function ($mapping) use($rootName) { - return $rootName === $mapping[1]; - }); - if (\count($remapping)) { - list($singular) = \current($remapping); - $rootName = $singular; - } - } - $rootName = \str_replace('_', '-', $rootName); - $rootAttributes = []; - $rootAttributeComments = []; - $rootChildren = []; - $rootComments = []; - if ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { - $children = $node->getChildren(); - // comments about the root node - if ($rootInfo = $node->getInfo()) { - $rootComments[] = $rootInfo; - } - if ($rootNamespace) { - $rootComments[] = 'Namespace: ' . $rootNamespace; - } - // render prototyped nodes - if ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode) { - $prototype = $node->getPrototype(); - $info = 'prototype'; - if (null !== $prototype->getInfo()) { - $info .= ': ' . $prototype->getInfo(); - } - \array_unshift($rootComments, $info); - if ($key = $node->getKeyAttribute()) { - $rootAttributes[$key] = \str_replace('-', ' ', $rootName) . ' ' . $key; - } - if ($prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode) { - $prototype->setName($key); - $children = [$key => $prototype]; - } elseif ($prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { - $children = $prototype->getChildren(); - } else { - if ($prototype->hasDefaultValue()) { - $prototypeValue = $prototype->getDefaultValue(); - } else { - switch (\get_class($prototype)) { - case 'Symfony\\Component\\Config\\Definition\\ScalarNode': - $prototypeValue = 'scalar value'; - break; - case 'Symfony\\Component\\Config\\Definition\\FloatNode': - case 'Symfony\\Component\\Config\\Definition\\IntegerNode': - $prototypeValue = 'numeric value'; - break; - case 'Symfony\\Component\\Config\\Definition\\BooleanNode': - $prototypeValue = 'true|false'; - break; - case 'Symfony\\Component\\Config\\Definition\\EnumNode': - $prototypeValue = \implode('|', \array_map('json_encode', $prototype->getValues())); - break; - default: - $prototypeValue = 'value'; - } - } - } - } - // get attributes and elements - foreach ($children as $child) { - if (!$child instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { - // get attributes - // metadata - $name = \str_replace('_', '-', $child->getName()); - $value = '%%%%not_defined%%%%'; - // use a string which isn't used in the normal world - // comments - $comments = []; - if ($info = $child->getInfo()) { - $comments[] = $info; - } - if ($example = $child->getExample()) { - $comments[] = 'Example: ' . $example; - } - if ($child->isRequired()) { - $comments[] = 'Required'; - } - if ($child->isDeprecated()) { - $comments[] = \sprintf('Deprecated (%s)', $child->getDeprecationMessage($child->getName(), $node->getPath())); - } - if ($child instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode) { - $comments[] = 'One of ' . \implode('; ', \array_map('json_encode', $child->getValues())); - } - if (\count($comments)) { - $rootAttributeComments[$name] = \implode(";\n", $comments); - } - // default values - if ($child->hasDefaultValue()) { - $value = $child->getDefaultValue(); - } - // append attribute - $rootAttributes[$name] = $value; - } else { - // get elements - $rootChildren[] = $child; - } - } - } - // render comments - // root node comment - if (\count($rootComments)) { - foreach ($rootComments as $comment) { - $this->writeLine('', $depth); - } - } - // attribute comments - if (\count($rootAttributeComments)) { - foreach ($rootAttributeComments as $attrName => $comment) { - $commentDepth = $depth + 4 + \strlen($attrName) + 2; - $commentLines = \explode("\n", $comment); - $multiline = \count($commentLines) > 1; - $comment = \implode(\PHP_EOL . \str_repeat(' ', $commentDepth), $commentLines); - if ($multiline) { - $this->writeLine('', $depth); - } else { - $this->writeLine('', $depth); - } - } - } - // render start tag + attributes - $rootIsVariablePrototype = isset($prototypeValue); - $rootIsEmptyTag = 0 === \count($rootChildren) && !$rootIsVariablePrototype; - $rootOpenTag = '<' . $rootName; - if (1 >= ($attributesCount = \count($rootAttributes))) { - if (1 === $attributesCount) { - $rootOpenTag .= \sprintf(' %s="%s"', \current(\array_keys($rootAttributes)), $this->writeValue(\current($rootAttributes))); - } - $rootOpenTag .= $rootIsEmptyTag ? ' />' : '>'; - if ($rootIsVariablePrototype) { - $rootOpenTag .= $prototypeValue . ''; - } - $this->writeLine($rootOpenTag, $depth); - } else { - $this->writeLine($rootOpenTag, $depth); - $i = 1; - foreach ($rootAttributes as $attrName => $attrValue) { - $attr = \sprintf('%s="%s"', $attrName, $this->writeValue($attrValue)); - $this->writeLine($attr, $depth + 4); - if ($attributesCount === $i++) { - $this->writeLine($rootIsEmptyTag ? '/>' : '>', $depth); - if ($rootIsVariablePrototype) { - $rootOpenTag .= $prototypeValue . ''; - } - } - } - } - // render children tags - foreach ($rootChildren as $child) { - $this->writeLine(''); - $this->writeNode($child, $depth + 4); - } - // render end tag - if (!$rootIsEmptyTag && !$rootIsVariablePrototype) { - $this->writeLine(''); - $rootEndTag = ''; - $this->writeLine($rootEndTag, $depth); - } - } - /** - * Outputs a single config reference line. - * - * @param string $text - * @param int $indent - */ - private function writeLine($text, $indent = 0) - { - $indent = \strlen($text) + $indent; - $format = '%' . $indent . 's'; - $this->reference .= \sprintf($format, $text) . \PHP_EOL; - } - /** - * Renders the string conversion of the value. - * - * @param mixed $value - * - * @return string - */ - private function writeValue($value) - { - if ('%%%%not_defined%%%%' === $value) { - return ''; - } - if (\is_string($value) || \is_numeric($value)) { - return $value; - } - if (\false === $value) { - return 'false'; - } - if (\true === $value) { - return 'true'; - } - if (null === $value) { - return 'null'; - } - if (empty($value)) { - return ''; - } - if (\is_array($value)) { - return \implode(',', $value); - } - return ''; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode; +/** + * Dumps a XML reference configuration for the given configuration/node instance. + * + * @author Wouter J + */ +class XmlReferenceDumper +{ + private $reference; + public function dump(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface $configuration, $namespace = null) + { + return $this->dumpNode($configuration->getConfigTreeBuilder()->buildTree(), $namespace); + } + public function dumpNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node, $namespace = null) + { + $this->reference = ''; + $this->writeNode($node, 0, \true, $namespace); + $ref = $this->reference; + $this->reference = null; + return $ref; + } + /** + * @param int $depth + * @param bool $root If the node is the root node + * @param string $namespace The namespace of the node + */ + private function writeNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node, $depth = 0, $root = \false, $namespace = null) + { + $rootName = $root ? 'config' : $node->getName(); + $rootNamespace = $namespace ?: ($root ? 'http://example.org/schema/dic/' . $node->getName() : null); + // xml remapping + if ($node->getParent()) { + $remapping = \array_filter($node->getParent()->getXmlRemappings(), function ($mapping) use($rootName) { + return $rootName === $mapping[1]; + }); + if (\count($remapping)) { + list($singular) = \current($remapping); + $rootName = $singular; + } + } + $rootName = \str_replace('_', '-', $rootName); + $rootAttributes = []; + $rootAttributeComments = []; + $rootChildren = []; + $rootComments = []; + if ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { + $children = $node->getChildren(); + // comments about the root node + if ($rootInfo = $node->getInfo()) { + $rootComments[] = $rootInfo; + } + if ($rootNamespace) { + $rootComments[] = 'Namespace: ' . $rootNamespace; + } + // render prototyped nodes + if ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode) { + $prototype = $node->getPrototype(); + $info = 'prototype'; + if (null !== $prototype->getInfo()) { + $info .= ': ' . $prototype->getInfo(); + } + \array_unshift($rootComments, $info); + if ($key = $node->getKeyAttribute()) { + $rootAttributes[$key] = \str_replace('-', ' ', $rootName) . ' ' . $key; + } + if ($prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode) { + $prototype->setName($key); + $children = [$key => $prototype]; + } elseif ($prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { + $children = $prototype->getChildren(); + } else { + if ($prototype->hasDefaultValue()) { + $prototypeValue = $prototype->getDefaultValue(); + } else { + switch (\get_class($prototype)) { + case 'Symfony\\Component\\Config\\Definition\\ScalarNode': + $prototypeValue = 'scalar value'; + break; + case 'Symfony\\Component\\Config\\Definition\\FloatNode': + case 'Symfony\\Component\\Config\\Definition\\IntegerNode': + $prototypeValue = 'numeric value'; + break; + case 'Symfony\\Component\\Config\\Definition\\BooleanNode': + $prototypeValue = 'true|false'; + break; + case 'Symfony\\Component\\Config\\Definition\\EnumNode': + $prototypeValue = \implode('|', \array_map('json_encode', $prototype->getValues())); + break; + default: + $prototypeValue = 'value'; + } + } + } + } + // get attributes and elements + foreach ($children as $child) { + if (!$child instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { + // get attributes + // metadata + $name = \str_replace('_', '-', $child->getName()); + $value = '%%%%not_defined%%%%'; + // use a string which isn't used in the normal world + // comments + $comments = []; + if ($info = $child->getInfo()) { + $comments[] = $info; + } + if ($example = $child->getExample()) { + $comments[] = 'Example: ' . $example; + } + if ($child->isRequired()) { + $comments[] = 'Required'; + } + if ($child->isDeprecated()) { + $comments[] = \sprintf('Deprecated (%s)', $child->getDeprecationMessage($child->getName(), $node->getPath())); + } + if ($child instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode) { + $comments[] = 'One of ' . \implode('; ', \array_map('json_encode', $child->getValues())); + } + if (\count($comments)) { + $rootAttributeComments[$name] = \implode(";\n", $comments); + } + // default values + if ($child->hasDefaultValue()) { + $value = $child->getDefaultValue(); + } + // append attribute + $rootAttributes[$name] = $value; + } else { + // get elements + $rootChildren[] = $child; + } + } + } + // render comments + // root node comment + if (\count($rootComments)) { + foreach ($rootComments as $comment) { + $this->writeLine('', $depth); + } + } + // attribute comments + if (\count($rootAttributeComments)) { + foreach ($rootAttributeComments as $attrName => $comment) { + $commentDepth = $depth + 4 + \strlen($attrName) + 2; + $commentLines = \explode("\n", $comment); + $multiline = \count($commentLines) > 1; + $comment = \implode(\PHP_EOL . \str_repeat(' ', $commentDepth), $commentLines); + if ($multiline) { + $this->writeLine('', $depth); + } else { + $this->writeLine('', $depth); + } + } + } + // render start tag + attributes + $rootIsVariablePrototype = isset($prototypeValue); + $rootIsEmptyTag = 0 === \count($rootChildren) && !$rootIsVariablePrototype; + $rootOpenTag = '<' . $rootName; + if (1 >= ($attributesCount = \count($rootAttributes))) { + if (1 === $attributesCount) { + $rootOpenTag .= \sprintf(' %s="%s"', \current(\array_keys($rootAttributes)), $this->writeValue(\current($rootAttributes))); + } + $rootOpenTag .= $rootIsEmptyTag ? ' />' : '>'; + if ($rootIsVariablePrototype) { + $rootOpenTag .= $prototypeValue . ''; + } + $this->writeLine($rootOpenTag, $depth); + } else { + $this->writeLine($rootOpenTag, $depth); + $i = 1; + foreach ($rootAttributes as $attrName => $attrValue) { + $attr = \sprintf('%s="%s"', $attrName, $this->writeValue($attrValue)); + $this->writeLine($attr, $depth + 4); + if ($attributesCount === $i++) { + $this->writeLine($rootIsEmptyTag ? '/>' : '>', $depth); + if ($rootIsVariablePrototype) { + $rootOpenTag .= $prototypeValue . ''; + } + } + } + } + // render children tags + foreach ($rootChildren as $child) { + $this->writeLine(''); + $this->writeNode($child, $depth + 4); + } + // render end tag + if (!$rootIsEmptyTag && !$rootIsVariablePrototype) { + $this->writeLine(''); + $rootEndTag = ''; + $this->writeLine($rootEndTag, $depth); + } + } + /** + * Outputs a single config reference line. + * + * @param string $text + * @param int $indent + */ + private function writeLine($text, $indent = 0) + { + $indent = \strlen($text) + $indent; + $format = '%' . $indent . 's'; + $this->reference .= \sprintf($format, $text) . \PHP_EOL; + } + /** + * Renders the string conversion of the value. + * + * @param mixed $value + * + * @return string + */ + private function writeValue($value) + { + if ('%%%%not_defined%%%%' === $value) { + return ''; + } + if (\is_string($value) || \is_numeric($value)) { + return $value; + } + if (\false === $value) { + return 'false'; + } + if (\true === $value) { + return 'true'; + } + if (null === $value) { + return 'null'; + } + if (empty($value)) { + return ''; + } + if (\is_array($value)) { + return \implode(',', $value); + } + return ''; + } +} diff --git a/vendor/symfony/config/Definition/Dumper/YamlReferenceDumper.php b/vendor/symfony/config/Definition/Dumper/YamlReferenceDumper.php index 2a8aa55d4..903c096f9 100644 --- a/vendor/symfony/config/Definition/Dumper/YamlReferenceDumper.php +++ b/vendor/symfony/config/Definition/Dumper/YamlReferenceDumper.php @@ -1,205 +1,205 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline; -/** - * Dumps a Yaml reference configuration for the given configuration/node instance. - * - * @author Kevin Bond - */ -class YamlReferenceDumper -{ - private $reference; - public function dump(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface $configuration) - { - return $this->dumpNode($configuration->getConfigTreeBuilder()->buildTree()); - } - public function dumpAtPath(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface $configuration, $path) - { - $rootNode = $node = $configuration->getConfigTreeBuilder()->buildTree(); - foreach (\explode('.', $path) as $step) { - if (!$node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { - throw new \UnexpectedValueException(\sprintf('Unable to find node at path "%s.%s".', $rootNode->getName(), $path)); - } - /** @var NodeInterface[] $children */ - $children = $node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode ? $this->getPrototypeChildren($node) : $node->getChildren(); - foreach ($children as $child) { - if ($child->getName() === $step) { - $node = $child; - continue 2; - } - } - throw new \UnexpectedValueException(\sprintf('Unable to find node at path "%s.%s".', $rootNode->getName(), $path)); - } - return $this->dumpNode($node); - } - public function dumpNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node) - { - $this->reference = ''; - $this->writeNode($node); - $ref = $this->reference; - $this->reference = null; - return $ref; - } - /** - * @param int $depth - * @param bool $prototypedArray - */ - private function writeNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $parentNode = null, $depth = 0, $prototypedArray = \false) - { - $comments = []; - $default = ''; - $defaultArray = null; - $children = null; - $example = $node->getExample(); - // defaults - if ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { - $children = $node->getChildren(); - if ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode) { - $children = $this->getPrototypeChildren($node); - } - if (!$children) { - if ($node->hasDefaultValue() && \count($defaultArray = $node->getDefaultValue())) { - $default = ''; - } elseif (!\is_array($example)) { - $default = '[]'; - } - } - } elseif ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode) { - $comments[] = 'One of ' . \implode('; ', \array_map('json_encode', $node->getValues())); - $default = $node->hasDefaultValue() ? \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($node->getDefaultValue()) : '~'; - } else { - $default = '~'; - if ($node->hasDefaultValue()) { - $default = $node->getDefaultValue(); - if (\is_array($default)) { - if (\count($defaultArray = $node->getDefaultValue())) { - $default = ''; - } elseif (!\is_array($example)) { - $default = '[]'; - } - } else { - $default = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($default); - } - } - } - // required? - if ($node->isRequired()) { - $comments[] = 'Required'; - } - // deprecated? - if ($node->isDeprecated()) { - $comments[] = \sprintf('Deprecated (%s)', $node->getDeprecationMessage($node->getName(), $parentNode ? $parentNode->getPath() : $node->getPath())); - } - // example - if ($example && !\is_array($example)) { - $comments[] = 'Example: ' . $example; - } - $default = '' != (string) $default ? ' ' . $default : ''; - $comments = \count($comments) ? '# ' . \implode(', ', $comments) : ''; - $key = $prototypedArray ? '-' : $node->getName() . ':'; - $text = \rtrim(\sprintf('%-21s%s %s', $key, $default, $comments), ' '); - if ($info = $node->getInfo()) { - $this->writeLine(''); - // indenting multi-line info - $info = \str_replace("\n", \sprintf("\n%" . $depth * 4 . 's# ', ' '), $info); - $this->writeLine('# ' . $info, $depth * 4); - } - $this->writeLine($text, $depth * 4); - // output defaults - if ($defaultArray) { - $this->writeLine(''); - $message = \count($defaultArray) > 1 ? 'Defaults' : 'Default'; - $this->writeLine('# ' . $message . ':', $depth * 4 + 4); - $this->writeArray($defaultArray, $depth + 1); - } - if (\is_array($example)) { - $this->writeLine(''); - $message = \count($example) > 1 ? 'Examples' : 'Example'; - $this->writeLine('# ' . $message . ':', $depth * 4 + 4); - $this->writeArray($example, $depth + 1); - } - if ($children) { - foreach ($children as $childNode) { - $this->writeNode($childNode, $node, $depth + 1, $node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode && !$node->getKeyAttribute()); - } - } - } - /** - * Outputs a single config reference line. - * - * @param string $text - * @param int $indent - */ - private function writeLine($text, $indent = 0) - { - $indent = \strlen($text) + $indent; - $format = '%' . $indent . 's'; - $this->reference .= \sprintf($format, $text) . "\n"; - } - private function writeArray(array $array, $depth) - { - $isIndexed = \array_values($array) === $array; - foreach ($array as $key => $value) { - if (\is_array($value)) { - $val = ''; - } else { - $val = $value; - } - if ($isIndexed) { - $this->writeLine('- ' . $val, $depth * 4); - } else { - $this->writeLine(\sprintf('%-20s %s', $key . ':', $val), $depth * 4); - } - if (\is_array($value)) { - $this->writeArray($value, $depth + 1); - } - } - } - /** - * @return array - */ - private function getPrototypeChildren(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode $node) - { - $prototype = $node->getPrototype(); - $key = $node->getKeyAttribute(); - // Do not expand prototype if it isn't an array node nor uses attribute as key - if (!$key && !$prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { - return $node->getChildren(); - } - if ($prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { - $keyNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode($key, $node); - $children = $prototype->getChildren(); - if ($prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode && $prototype->getKeyAttribute()) { - $children = $this->getPrototypeChildren($prototype); - } - // add children - foreach ($children as $childNode) { - $keyNode->addChild($childNode); - } - } else { - $keyNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode($key, $node); - } - $info = 'Prototype'; - if (null !== $prototype->getInfo()) { - $info .= ': ' . $prototype->getInfo(); - } - $keyNode->setInfo($info); - return [$key => $keyNode]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline; +/** + * Dumps a Yaml reference configuration for the given configuration/node instance. + * + * @author Kevin Bond + */ +class YamlReferenceDumper +{ + private $reference; + public function dump(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface $configuration) + { + return $this->dumpNode($configuration->getConfigTreeBuilder()->buildTree()); + } + public function dumpAtPath(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface $configuration, $path) + { + $rootNode = $node = $configuration->getConfigTreeBuilder()->buildTree(); + foreach (\explode('.', $path) as $step) { + if (!$node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { + throw new \UnexpectedValueException(\sprintf('Unable to find node at path "%s.%s".', $rootNode->getName(), $path)); + } + /** @var NodeInterface[] $children */ + $children = $node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode ? $this->getPrototypeChildren($node) : $node->getChildren(); + foreach ($children as $child) { + if ($child->getName() === $step) { + $node = $child; + continue 2; + } + } + throw new \UnexpectedValueException(\sprintf('Unable to find node at path "%s.%s".', $rootNode->getName(), $path)); + } + return $this->dumpNode($node); + } + public function dumpNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node) + { + $this->reference = ''; + $this->writeNode($node); + $ref = $this->reference; + $this->reference = null; + return $ref; + } + /** + * @param int $depth + * @param bool $prototypedArray + */ + private function writeNode(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $parentNode = null, $depth = 0, $prototypedArray = \false) + { + $comments = []; + $default = ''; + $defaultArray = null; + $children = null; + $example = $node->getExample(); + // defaults + if ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { + $children = $node->getChildren(); + if ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode) { + $children = $this->getPrototypeChildren($node); + } + if (!$children) { + if ($node->hasDefaultValue() && \count($defaultArray = $node->getDefaultValue())) { + $default = ''; + } elseif (!\is_array($example)) { + $default = '[]'; + } + } + } elseif ($node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode) { + $comments[] = 'One of ' . \implode('; ', \array_map('json_encode', $node->getValues())); + $default = $node->hasDefaultValue() ? \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($node->getDefaultValue()) : '~'; + } else { + $default = '~'; + if ($node->hasDefaultValue()) { + $default = $node->getDefaultValue(); + if (\is_array($default)) { + if (\count($defaultArray = $node->getDefaultValue())) { + $default = ''; + } elseif (!\is_array($example)) { + $default = '[]'; + } + } else { + $default = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($default); + } + } + } + // required? + if ($node->isRequired()) { + $comments[] = 'Required'; + } + // deprecated? + if ($node->isDeprecated()) { + $comments[] = \sprintf('Deprecated (%s)', $node->getDeprecationMessage($node->getName(), $parentNode ? $parentNode->getPath() : $node->getPath())); + } + // example + if ($example && !\is_array($example)) { + $comments[] = 'Example: ' . $example; + } + $default = '' != (string) $default ? ' ' . $default : ''; + $comments = \count($comments) ? '# ' . \implode(', ', $comments) : ''; + $key = $prototypedArray ? '-' : $node->getName() . ':'; + $text = \rtrim(\sprintf('%-21s%s %s', $key, $default, $comments), ' '); + if ($info = $node->getInfo()) { + $this->writeLine(''); + // indenting multi-line info + $info = \str_replace("\n", \sprintf("\n%" . $depth * 4 . 's# ', ' '), $info); + $this->writeLine('# ' . $info, $depth * 4); + } + $this->writeLine($text, $depth * 4); + // output defaults + if ($defaultArray) { + $this->writeLine(''); + $message = \count($defaultArray) > 1 ? 'Defaults' : 'Default'; + $this->writeLine('# ' . $message . ':', $depth * 4 + 4); + $this->writeArray($defaultArray, $depth + 1); + } + if (\is_array($example)) { + $this->writeLine(''); + $message = \count($example) > 1 ? 'Examples' : 'Example'; + $this->writeLine('# ' . $message . ':', $depth * 4 + 4); + $this->writeArray($example, $depth + 1); + } + if ($children) { + foreach ($children as $childNode) { + $this->writeNode($childNode, $node, $depth + 1, $node instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode && !$node->getKeyAttribute()); + } + } + } + /** + * Outputs a single config reference line. + * + * @param string $text + * @param int $indent + */ + private function writeLine($text, $indent = 0) + { + $indent = \strlen($text) + $indent; + $format = '%' . $indent . 's'; + $this->reference .= \sprintf($format, $text) . "\n"; + } + private function writeArray(array $array, $depth) + { + $isIndexed = \array_values($array) === $array; + foreach ($array as $key => $value) { + if (\is_array($value)) { + $val = ''; + } else { + $val = $value; + } + if ($isIndexed) { + $this->writeLine('- ' . $val, $depth * 4); + } else { + $this->writeLine(\sprintf('%-20s %s', $key . ':', $val), $depth * 4); + } + if (\is_array($value)) { + $this->writeArray($value, $depth + 1); + } + } + } + /** + * @return array + */ + private function getPrototypeChildren(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode $node) + { + $prototype = $node->getPrototype(); + $key = $node->getKeyAttribute(); + // Do not expand prototype if it isn't an array node nor uses attribute as key + if (!$key && !$prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { + return $node->getChildren(); + } + if ($prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode) { + $keyNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode($key, $node); + $children = $prototype->getChildren(); + if ($prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode && $prototype->getKeyAttribute()) { + $children = $this->getPrototypeChildren($prototype); + } + // add children + foreach ($children as $childNode) { + $keyNode->addChild($childNode); + } + } else { + $keyNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode($key, $node); + } + $info = 'Prototype'; + if (null !== $prototype->getInfo()) { + $info .= ': ' . $prototype->getInfo(); + } + $keyNode->setInfo($info); + return [$key => $keyNode]; + } +} diff --git a/vendor/symfony/config/Definition/Dumper/index.php b/vendor/symfony/config/Definition/Dumper/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Definition/Dumper/index.php +++ b/vendor/symfony/config/Definition/Dumper/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Definition/EnumNode.php b/vendor/symfony/config/Definition/EnumNode.php index 9325e3405..ce6980058 100644 --- a/vendor/symfony/config/Definition/EnumNode.php +++ b/vendor/symfony/config/Definition/EnumNode.php @@ -1,45 +1,45 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; -/** - * Node which only allows a finite set of values. - * - * @author Johannes M. Schmitt - */ -class EnumNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode -{ - private $values; - public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $parent = null, array $values = []) - { - $values = \array_unique($values); - if (empty($values)) { - throw new \InvalidArgumentException('$values must contain at least one element.'); - } - parent::__construct($name, $parent); - $this->values = $values; - } - public function getValues() - { - return $this->values; - } - protected function finalizeValue($value) - { - $value = parent::finalizeValue($value); - if (!\in_array($value, $this->values, \true)) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('The value %s is not allowed for path "%s". Permissible values: %s', \json_encode($value), $this->getPath(), \implode(', ', \array_map('json_encode', $this->values)))); - $ex->setPath($this->getPath()); - throw $ex; - } - return $value; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; +/** + * Node which only allows a finite set of values. + * + * @author Johannes M. Schmitt + */ +class EnumNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode +{ + private $values; + public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $parent = null, array $values = []) + { + $values = \array_unique($values); + if (empty($values)) { + throw new \InvalidArgumentException('$values must contain at least one element.'); + } + parent::__construct($name, $parent); + $this->values = $values; + } + public function getValues() + { + return $this->values; + } + protected function finalizeValue($value) + { + $value = parent::finalizeValue($value); + if (!\in_array($value, $this->values, \true)) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('The value %s is not allowed for path "%s". Permissible values: %s', \json_encode($value), $this->getPath(), \implode(', ', \array_map('json_encode', $this->values)))); + $ex->setPath($this->getPath()); + throw $ex; + } + return $value; + } +} diff --git a/vendor/symfony/config/Definition/Exception/DuplicateKeyException.php b/vendor/symfony/config/Definition/Exception/DuplicateKeyException.php index 1195c09c7..f312d5605 100644 --- a/vendor/symfony/config/Definition/Exception/DuplicateKeyException.php +++ b/vendor/symfony/config/Definition/Exception/DuplicateKeyException.php @@ -1,21 +1,21 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; - -/** - * This exception is thrown whenever the key of an array is not unique. This can - * only be the case if the configuration is coming from an XML file. - * - * @author Johannes M. Schmitt - */ -class DuplicateKeyException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; + +/** + * This exception is thrown whenever the key of an array is not unique. This can + * only be the case if the configuration is coming from an XML file. + * + * @author Johannes M. Schmitt + */ +class DuplicateKeyException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException +{ +} diff --git a/vendor/symfony/config/Definition/Exception/Exception.php b/vendor/symfony/config/Definition/Exception/Exception.php index e3bd6c83a..9b46c90da 100644 --- a/vendor/symfony/config/Definition/Exception/Exception.php +++ b/vendor/symfony/config/Definition/Exception/Exception.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; - -/** - * Base exception for all configuration exceptions. - * - * @author Johannes M. Schmitt - */ -class Exception extends \RuntimeException -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; + +/** + * Base exception for all configuration exceptions. + * + * @author Johannes M. Schmitt + */ +class Exception extends \RuntimeException +{ +} diff --git a/vendor/symfony/config/Definition/Exception/ForbiddenOverwriteException.php b/vendor/symfony/config/Definition/Exception/ForbiddenOverwriteException.php index 858efd592..9ce7f6619 100644 --- a/vendor/symfony/config/Definition/Exception/ForbiddenOverwriteException.php +++ b/vendor/symfony/config/Definition/Exception/ForbiddenOverwriteException.php @@ -1,21 +1,21 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; - -/** - * This exception is thrown when a configuration path is overwritten from a - * subsequent configuration file, but the entry node specifically forbids this. - * - * @author Johannes M. Schmitt - */ -class ForbiddenOverwriteException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; + +/** + * This exception is thrown when a configuration path is overwritten from a + * subsequent configuration file, but the entry node specifically forbids this. + * + * @author Johannes M. Schmitt + */ +class ForbiddenOverwriteException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException +{ +} diff --git a/vendor/symfony/config/Definition/Exception/InvalidConfigurationException.php b/vendor/symfony/config/Definition/Exception/InvalidConfigurationException.php index ee5735285..5cac2dda4 100644 --- a/vendor/symfony/config/Definition/Exception/InvalidConfigurationException.php +++ b/vendor/symfony/config/Definition/Exception/InvalidConfigurationException.php @@ -1,45 +1,45 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; - -/** - * A very general exception which can be thrown whenever non of the more specific - * exceptions is suitable. - * - * @author Johannes M. Schmitt - */ -class InvalidConfigurationException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception -{ - private $path; - private $containsHints = \false; - public function setPath($path) - { - $this->path = $path; - } - public function getPath() - { - return $this->path; - } - /** - * Adds extra information that is suffixed to the original exception message. - * - * @param string $hint - */ - public function addHint($hint) - { - if (!$this->containsHints) { - $this->message .= "\nHint: " . $hint; - $this->containsHints = \true; - } else { - $this->message .= ', ' . $hint; - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; + +/** + * A very general exception which can be thrown whenever non of the more specific + * exceptions is suitable. + * + * @author Johannes M. Schmitt + */ +class InvalidConfigurationException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception +{ + private $path; + private $containsHints = \false; + public function setPath($path) + { + $this->path = $path; + } + public function getPath() + { + return $this->path; + } + /** + * Adds extra information that is suffixed to the original exception message. + * + * @param string $hint + */ + public function addHint($hint) + { + if (!$this->containsHints) { + $this->message .= "\nHint: " . $hint; + $this->containsHints = \true; + } else { + $this->message .= ', ' . $hint; + } + } +} diff --git a/vendor/symfony/config/Definition/Exception/InvalidDefinitionException.php b/vendor/symfony/config/Definition/Exception/InvalidDefinitionException.php index 22f818f2a..eecdd4397 100644 --- a/vendor/symfony/config/Definition/Exception/InvalidDefinitionException.php +++ b/vendor/symfony/config/Definition/Exception/InvalidDefinitionException.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; - -/** - * Thrown when an error is detected in a node Definition. - * - * @author Victor Berchet - */ -class InvalidDefinitionException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; + +/** + * Thrown when an error is detected in a node Definition. + * + * @author Victor Berchet + */ +class InvalidDefinitionException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception +{ +} diff --git a/vendor/symfony/config/Definition/Exception/InvalidTypeException.php b/vendor/symfony/config/Definition/Exception/InvalidTypeException.php index 2618abf96..340d7a770 100644 --- a/vendor/symfony/config/Definition/Exception/InvalidTypeException.php +++ b/vendor/symfony/config/Definition/Exception/InvalidTypeException.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; - -/** - * This exception is thrown if an invalid type is encountered. - * - * @author Johannes M. Schmitt - */ -class InvalidTypeException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; + +/** + * This exception is thrown if an invalid type is encountered. + * + * @author Johannes M. Schmitt + */ +class InvalidTypeException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException +{ +} diff --git a/vendor/symfony/config/Definition/Exception/UnsetKeyException.php b/vendor/symfony/config/Definition/Exception/UnsetKeyException.php index cbe92cadb..0958a9d54 100644 --- a/vendor/symfony/config/Definition/Exception/UnsetKeyException.php +++ b/vendor/symfony/config/Definition/Exception/UnsetKeyException.php @@ -1,21 +1,21 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; - -/** - * This exception is usually not encountered by the end-user, but only used - * internally to signal the parent scope to unset a key. - * - * @author Johannes M. Schmitt - */ -class UnsetKeyException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception; + +/** + * This exception is usually not encountered by the end-user, but only used + * internally to signal the parent scope to unset a key. + * + * @author Johannes M. Schmitt + */ +class UnsetKeyException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception +{ +} diff --git a/vendor/symfony/config/Definition/Exception/index.php b/vendor/symfony/config/Definition/Exception/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Definition/Exception/index.php +++ b/vendor/symfony/config/Definition/Exception/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Definition/FloatNode.php b/vendor/symfony/config/Definition/FloatNode.php index 1dfeb341a..fc549501b 100644 --- a/vendor/symfony/config/Definition/FloatNode.php +++ b/vendor/symfony/config/Definition/FloatNode.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; -/** - * This node represents a float value in the config tree. - * - * @author Jeanmonod David - */ -class FloatNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NumericNode -{ - /** - * {@inheritdoc} - */ - protected function validateType($value) - { - // Integers are also accepted, we just cast them - if (\is_int($value)) { - $value = (float) $value; - } - if (!\is_float($value)) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException(\sprintf('Invalid type for path "%s". Expected float, but got %s.', $this->getPath(), \gettype($value))); - if ($hint = $this->getInfo()) { - $ex->addHint($hint); - } - $ex->setPath($this->getPath()); - throw $ex; - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; +/** + * This node represents a float value in the config tree. + * + * @author Jeanmonod David + */ +class FloatNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NumericNode +{ + /** + * {@inheritdoc} + */ + protected function validateType($value) + { + // Integers are also accepted, we just cast them + if (\is_int($value)) { + $value = (float) $value; + } + if (!\is_float($value)) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException(\sprintf('Invalid type for path "%s". Expected float, but got %s.', $this->getPath(), \gettype($value))); + if ($hint = $this->getInfo()) { + $ex->addHint($hint); + } + $ex->setPath($this->getPath()); + throw $ex; + } + } +} diff --git a/vendor/symfony/config/Definition/IntegerNode.php b/vendor/symfony/config/Definition/IntegerNode.php index 72134fe81..b5c07f522 100644 --- a/vendor/symfony/config/Definition/IntegerNode.php +++ b/vendor/symfony/config/Definition/IntegerNode.php @@ -1,35 +1,35 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; -/** - * This node represents an integer value in the config tree. - * - * @author Jeanmonod David - */ -class IntegerNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NumericNode -{ - /** - * {@inheritdoc} - */ - protected function validateType($value) - { - if (!\is_int($value)) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException(\sprintf('Invalid type for path "%s". Expected int, but got %s.', $this->getPath(), \gettype($value))); - if ($hint = $this->getInfo()) { - $ex->addHint($hint); - } - $ex->setPath($this->getPath()); - throw $ex; - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; +/** + * This node represents an integer value in the config tree. + * + * @author Jeanmonod David + */ +class IntegerNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NumericNode +{ + /** + * {@inheritdoc} + */ + protected function validateType($value) + { + if (!\is_int($value)) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException(\sprintf('Invalid type for path "%s". Expected int, but got %s.', $this->getPath(), \gettype($value))); + if ($hint = $this->getInfo()) { + $ex->addHint($hint); + } + $ex->setPath($this->getPath()); + throw $ex; + } + } +} diff --git a/vendor/symfony/config/Definition/NodeInterface.php b/vendor/symfony/config/Definition/NodeInterface.php index 995a0fecc..2a99e968e 100644 --- a/vendor/symfony/config/Definition/NodeInterface.php +++ b/vendor/symfony/config/Definition/NodeInterface.php @@ -1,91 +1,91 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\ForbiddenOverwriteException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; -/** - * Common Interface among all nodes. - * - * In most cases, it is better to inherit from BaseNode instead of implementing - * this interface yourself. - * - * @author Johannes M. Schmitt - */ -interface NodeInterface -{ - /** - * Returns the name of the node. - * - * @return string The name of the node - */ - public function getName(); - /** - * Returns the path of the node. - * - * @return string The node path - */ - public function getPath(); - /** - * Returns true when the node is required. - * - * @return bool If the node is required - */ - public function isRequired(); - /** - * Returns true when the node has a default value. - * - * @return bool If the node has a default value - */ - public function hasDefaultValue(); - /** - * Returns the default value of the node. - * - * @return mixed The default value - * - * @throws \RuntimeException if the node has no default value - */ - public function getDefaultValue(); - /** - * Normalizes a value. - * - * @param mixed $value The value to normalize - * - * @return mixed The normalized value - * - * @throws InvalidTypeException if the value type is invalid - */ - public function normalize($value); - /** - * Merges two values together. - * - * @param mixed $leftSide - * @param mixed $rightSide - * - * @return mixed The merged value - * - * @throws ForbiddenOverwriteException if the configuration path cannot be overwritten - * @throws InvalidTypeException if the value type is invalid - */ - public function merge($leftSide, $rightSide); - /** - * Finalizes a value. - * - * @param mixed $value The value to finalize - * - * @return mixed The finalized value - * - * @throws InvalidTypeException if the value type is invalid - * @throws InvalidConfigurationException if the value is invalid configuration - */ - public function finalize($value); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\ForbiddenOverwriteException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; +/** + * Common Interface among all nodes. + * + * In most cases, it is better to inherit from BaseNode instead of implementing + * this interface yourself. + * + * @author Johannes M. Schmitt + */ +interface NodeInterface +{ + /** + * Returns the name of the node. + * + * @return string The name of the node + */ + public function getName(); + /** + * Returns the path of the node. + * + * @return string The node path + */ + public function getPath(); + /** + * Returns true when the node is required. + * + * @return bool If the node is required + */ + public function isRequired(); + /** + * Returns true when the node has a default value. + * + * @return bool If the node has a default value + */ + public function hasDefaultValue(); + /** + * Returns the default value of the node. + * + * @return mixed The default value + * + * @throws \RuntimeException if the node has no default value + */ + public function getDefaultValue(); + /** + * Normalizes a value. + * + * @param mixed $value The value to normalize + * + * @return mixed The normalized value + * + * @throws InvalidTypeException if the value type is invalid + */ + public function normalize($value); + /** + * Merges two values together. + * + * @param mixed $leftSide + * @param mixed $rightSide + * + * @return mixed The merged value + * + * @throws ForbiddenOverwriteException if the configuration path cannot be overwritten + * @throws InvalidTypeException if the value type is invalid + */ + public function merge($leftSide, $rightSide); + /** + * Finalizes a value. + * + * @param mixed $value The value to finalize + * + * @return mixed The finalized value + * + * @throws InvalidTypeException if the value type is invalid + * @throws InvalidConfigurationException if the value is invalid configuration + */ + public function finalize($value); +} diff --git a/vendor/symfony/config/Definition/NumericNode.php b/vendor/symfony/config/Definition/NumericNode.php index 8ca170f80..ecee2f9c3 100644 --- a/vendor/symfony/config/Definition/NumericNode.php +++ b/vendor/symfony/config/Definition/NumericNode.php @@ -1,57 +1,57 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; -/** - * This node represents a numeric value in the config tree. - * - * @author David Jeanmonod - */ -class NumericNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode -{ - protected $min; - protected $max; - public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $parent = null, $min = null, $max = null) - { - parent::__construct($name, $parent); - $this->min = $min; - $this->max = $max; - } - /** - * {@inheritdoc} - */ - protected function finalizeValue($value) - { - $value = parent::finalizeValue($value); - $errorMsg = null; - if (isset($this->min) && $value < $this->min) { - $errorMsg = \sprintf('The value %s is too small for path "%s". Should be greater than or equal to %s', $value, $this->getPath(), $this->min); - } - if (isset($this->max) && $value > $this->max) { - $errorMsg = \sprintf('The value %s is too big for path "%s". Should be less than or equal to %s', $value, $this->getPath(), $this->max); - } - if (isset($errorMsg)) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException($errorMsg); - $ex->setPath($this->getPath()); - throw $ex; - } - return $value; - } - /** - * {@inheritdoc} - */ - protected function isValueEmpty($value) - { - // a numeric value cannot be empty - return \false; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; +/** + * This node represents a numeric value in the config tree. + * + * @author David Jeanmonod + */ +class NumericNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode +{ + protected $min; + protected $max; + public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $parent = null, $min = null, $max = null) + { + parent::__construct($name, $parent); + $this->min = $min; + $this->max = $max; + } + /** + * {@inheritdoc} + */ + protected function finalizeValue($value) + { + $value = parent::finalizeValue($value); + $errorMsg = null; + if (isset($this->min) && $value < $this->min) { + $errorMsg = \sprintf('The value %s is too small for path "%s". Should be greater than or equal to %s', $value, $this->getPath(), $this->min); + } + if (isset($this->max) && $value > $this->max) { + $errorMsg = \sprintf('The value %s is too big for path "%s". Should be less than or equal to %s', $value, $this->getPath(), $this->max); + } + if (isset($errorMsg)) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException($errorMsg); + $ex->setPath($this->getPath()); + throw $ex; + } + return $value; + } + /** + * {@inheritdoc} + */ + protected function isValueEmpty($value) + { + // a numeric value cannot be empty + return \false; + } +} diff --git a/vendor/symfony/config/Definition/Processor.php b/vendor/symfony/config/Definition/Processor.php index 09e9b4b0b..67b3b4fac 100644 --- a/vendor/symfony/config/Definition/Processor.php +++ b/vendor/symfony/config/Definition/Processor.php @@ -1,89 +1,89 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -/** - * This class is the entry point for config normalization/merging/finalization. - * - * @author Johannes M. Schmitt - */ -class Processor -{ - /** - * Processes an array of configurations. - * - * @param NodeInterface $configTree The node tree describing the configuration - * @param array $configs An array of configuration items to process - * - * @return array The processed configuration - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $configTree, array $configs) - { - $currentConfig = []; - foreach ($configs as $config) { - $config = $configTree->normalize($config); - $currentConfig = $configTree->merge($currentConfig, $config); - } - return $configTree->finalize($currentConfig); - } - /** - * Processes an array of configurations. - * - * @param ConfigurationInterface $configuration The configuration class - * @param array $configs An array of configuration items to process - * - * @return array The processed configuration - */ - public function processConfiguration(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface $configuration, array $configs) - { - return $this->process($configuration->getConfigTreeBuilder()->buildTree(), $configs); - } - /** - * Normalizes a configuration entry. - * - * This method returns a normalize configuration array for a given key - * to remove the differences due to the original format (YAML and XML mainly). - * - * Here is an example. - * - * The configuration in XML: - * - * twig.extension.foo - * twig.extension.bar - * - * And the same configuration in YAML: - * - * extensions: ['twig.extension.foo', 'twig.extension.bar'] - * - * @param array $config A config array - * @param string $key The key to normalize - * @param string $plural The plural form of the key if it is irregular - * - * @return array - */ - public static function normalizeConfig($config, $key, $plural = null) - { - if (null === $plural) { - $plural = $key . 's'; - } - if (isset($config[$plural])) { - return $config[$plural]; - } - if (isset($config[$key])) { - if (\is_string($config[$key]) || !\is_int(\key($config[$key]))) { - // only one - return [$config[$key]]; - } - return $config[$key]; - } - return []; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +/** + * This class is the entry point for config normalization/merging/finalization. + * + * @author Johannes M. Schmitt + */ +class Processor +{ + /** + * Processes an array of configurations. + * + * @param NodeInterface $configTree The node tree describing the configuration + * @param array $configs An array of configuration items to process + * + * @return array The processed configuration + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $configTree, array $configs) + { + $currentConfig = []; + foreach ($configs as $config) { + $config = $configTree->normalize($config); + $currentConfig = $configTree->merge($currentConfig, $config); + } + return $configTree->finalize($currentConfig); + } + /** + * Processes an array of configurations. + * + * @param ConfigurationInterface $configuration The configuration class + * @param array $configs An array of configuration items to process + * + * @return array The processed configuration + */ + public function processConfiguration(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface $configuration, array $configs) + { + return $this->process($configuration->getConfigTreeBuilder()->buildTree(), $configs); + } + /** + * Normalizes a configuration entry. + * + * This method returns a normalize configuration array for a given key + * to remove the differences due to the original format (YAML and XML mainly). + * + * Here is an example. + * + * The configuration in XML: + * + * twig.extension.foo + * twig.extension.bar + * + * And the same configuration in YAML: + * + * extensions: ['twig.extension.foo', 'twig.extension.bar'] + * + * @param array $config A config array + * @param string $key The key to normalize + * @param string $plural The plural form of the key if it is irregular + * + * @return array + */ + public static function normalizeConfig($config, $key, $plural = null) + { + if (null === $plural) { + $plural = $key . 's'; + } + if (isset($config[$plural])) { + return $config[$plural]; + } + if (isset($config[$key])) { + if (\is_string($config[$key]) || !\is_int(\key($config[$key]))) { + // only one + return [$config[$key]]; + } + return $config[$key]; + } + return []; + } +} diff --git a/vendor/symfony/config/Definition/PrototypeNodeInterface.php b/vendor/symfony/config/Definition/PrototypeNodeInterface.php index 07ef03f93..1de4095c3 100644 --- a/vendor/symfony/config/Definition/PrototypeNodeInterface.php +++ b/vendor/symfony/config/Definition/PrototypeNodeInterface.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -/** - * This interface must be implemented by nodes which can be used as prototypes. - * - * @author Johannes M. Schmitt - */ -interface PrototypeNodeInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface -{ - /** - * Sets the name of the node. - * - * @param string $name The name of the node - */ - public function setName($name); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +/** + * This interface must be implemented by nodes which can be used as prototypes. + * + * @author Johannes M. Schmitt + */ +interface PrototypeNodeInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface +{ + /** + * Sets the name of the node. + * + * @param string $name The name of the node + */ + public function setName($name); +} diff --git a/vendor/symfony/config/Definition/PrototypedArrayNode.php b/vendor/symfony/config/Definition/PrototypedArrayNode.php index 728591764..5fc17d7fe 100644 --- a/vendor/symfony/config/Definition/PrototypedArrayNode.php +++ b/vendor/symfony/config/Definition/PrototypedArrayNode.php @@ -1,337 +1,337 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\DuplicateKeyException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException; -/** - * Represents a prototyped Array node in the config tree. - * - * @author Johannes M. Schmitt - */ -class PrototypedArrayNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode -{ - protected $prototype; - protected $keyAttribute; - protected $removeKeyAttribute = \false; - protected $minNumberOfElements = 0; - protected $defaultValue = []; - protected $defaultChildren; - /** - * @var NodeInterface[] An array of the prototypes of the simplified value children - */ - private $valuePrototypes = []; - /** - * Sets the minimum number of elements that a prototype based node must - * contain. By default this is zero, meaning no elements. - * - * @param int $number - */ - public function setMinNumberOfElements($number) - { - $this->minNumberOfElements = $number; - } - /** - * Sets the attribute which value is to be used as key. - * - * This is useful when you have an indexed array that should be an - * associative array. You can select an item from within the array - * to be the key of the particular item. For example, if "id" is the - * "key", then: - * - * [ - * ['id' => 'my_name', 'foo' => 'bar'], - * ]; - * - * becomes - * - * [ - * 'my_name' => ['foo' => 'bar'], - * ]; - * - * If you'd like "'id' => 'my_name'" to still be present in the resulting - * array, then you can set the second argument of this method to false. - * - * @param string $attribute The name of the attribute which value is to be used as a key - * @param bool $remove Whether or not to remove the key - */ - public function setKeyAttribute($attribute, $remove = \true) - { - $this->keyAttribute = $attribute; - $this->removeKeyAttribute = $remove; - } - /** - * Retrieves the name of the attribute which value should be used as key. - * - * @return string|null The name of the attribute - */ - public function getKeyAttribute() - { - return $this->keyAttribute; - } - /** - * Sets the default value of this node. - * - * @param string $value - * - * @throws \InvalidArgumentException if the default value is not an array - */ - public function setDefaultValue($value) - { - if (!\is_array($value)) { - throw new \InvalidArgumentException($this->getPath() . ': the default value of an array node has to be an array.'); - } - $this->defaultValue = $value; - } - /** - * {@inheritdoc} - */ - public function hasDefaultValue() - { - return \true; - } - /** - * Adds default children when none are set. - * - * @param int|string|array|null $children The number of children|The child name|The children names to be added - */ - public function setAddChildrenIfNoneSet($children = ['defaults']) - { - if (null === $children) { - $this->defaultChildren = ['defaults']; - } else { - $this->defaultChildren = \is_int($children) && $children > 0 ? \range(1, $children) : (array) $children; - } - } - /** - * {@inheritdoc} - * - * The default value could be either explicited or derived from the prototype - * default value. - */ - public function getDefaultValue() - { - if (null !== $this->defaultChildren) { - $default = $this->prototype->hasDefaultValue() ? $this->prototype->getDefaultValue() : []; - $defaults = []; - foreach (\array_values($this->defaultChildren) as $i => $name) { - $defaults[null === $this->keyAttribute ? $i : $name] = $default; - } - return $defaults; - } - return $this->defaultValue; - } - /** - * Sets the node prototype. - */ - public function setPrototype(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypeNodeInterface $node) - { - $this->prototype = $node; - } - /** - * Retrieves the prototype. - * - * @return PrototypeNodeInterface The prototype - */ - public function getPrototype() - { - return $this->prototype; - } - /** - * Disable adding concrete children for prototyped nodes. - * - * @throws Exception - */ - public function addChild(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception('A prototyped array node can not have concrete children.'); - } - /** - * Finalizes the value of this node. - * - * @param mixed $value - * - * @return mixed The finalized value - * - * @throws UnsetKeyException - * @throws InvalidConfigurationException if the node doesn't have enough children - */ - protected function finalizeValue($value) - { - if (\false === $value) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException(\sprintf('Unsetting key for path "%s", value: "%s".', $this->getPath(), \json_encode($value))); - } - foreach ($value as $k => $v) { - $prototype = $this->getPrototypeForChild($k); - try { - $value[$k] = $prototype->finalize($v); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException $e) { - unset($value[$k]); - } - } - if (\count($value) < $this->minNumberOfElements) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('The path "%s" should have at least %d element(s) defined.', $this->getPath(), $this->minNumberOfElements)); - $ex->setPath($this->getPath()); - throw $ex; - } - return $value; - } - /** - * Normalizes the value. - * - * @param mixed $value The value to normalize - * - * @return mixed The normalized value - * - * @throws InvalidConfigurationException - * @throws DuplicateKeyException - */ - protected function normalizeValue($value) - { - if (\false === $value) { - return $value; - } - $value = $this->remapXml($value); - $isAssoc = \array_keys($value) !== \range(0, \count($value) - 1); - $normalized = []; - foreach ($value as $k => $v) { - if (null !== $this->keyAttribute && \is_array($v)) { - if (!isset($v[$this->keyAttribute]) && \is_int($k) && !$isAssoc) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('The attribute "%s" must be set for path "%s".', $this->keyAttribute, $this->getPath())); - $ex->setPath($this->getPath()); - throw $ex; - } elseif (isset($v[$this->keyAttribute])) { - $k = $v[$this->keyAttribute]; - // remove the key attribute when required - if ($this->removeKeyAttribute) { - unset($v[$this->keyAttribute]); - } - // if only "value" is left - if (\array_keys($v) === ['value']) { - $v = $v['value']; - if ($this->prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode && ($children = $this->prototype->getChildren()) && \array_key_exists('value', $children)) { - $valuePrototype = \current($this->valuePrototypes) ?: clone $children['value']; - $valuePrototype->parent = $this; - $originalClosures = $this->prototype->normalizationClosures; - if (\is_array($originalClosures)) { - $valuePrototypeClosures = $valuePrototype->normalizationClosures; - $valuePrototype->normalizationClosures = \is_array($valuePrototypeClosures) ? \array_merge($originalClosures, $valuePrototypeClosures) : $originalClosures; - } - $this->valuePrototypes[$k] = $valuePrototype; - } - } - } - if (\array_key_exists($k, $normalized)) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\DuplicateKeyException(\sprintf('Duplicate key "%s" for path "%s".', $k, $this->getPath())); - $ex->setPath($this->getPath()); - throw $ex; - } - } - $prototype = $this->getPrototypeForChild($k); - if (null !== $this->keyAttribute || $isAssoc) { - $normalized[$k] = $prototype->normalize($v); - } else { - $normalized[] = $prototype->normalize($v); - } - } - return $normalized; - } - /** - * Merges values together. - * - * @param mixed $leftSide The left side to merge - * @param mixed $rightSide The right side to merge - * - * @return mixed The merged values - * - * @throws InvalidConfigurationException - * @throws \RuntimeException - */ - protected function mergeValues($leftSide, $rightSide) - { - if (\false === $rightSide) { - // if this is still false after the last config has been merged the - // finalization pass will take care of removing this key entirely - return \false; - } - if (\false === $leftSide || !$this->performDeepMerging) { - return $rightSide; - } - foreach ($rightSide as $k => $v) { - // prototype, and key is irrelevant, append the element - if (null === $this->keyAttribute) { - $leftSide[] = $v; - continue; - } - // no conflict - if (!\array_key_exists($k, $leftSide)) { - if (!$this->allowNewKeys) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('You are not allowed to define new elements for path "%s". Please define all elements for this path in one config file.', $this->getPath())); - $ex->setPath($this->getPath()); - throw $ex; - } - $leftSide[$k] = $v; - continue; - } - $prototype = $this->getPrototypeForChild($k); - $leftSide[$k] = $prototype->merge($leftSide[$k], $v); - } - return $leftSide; - } - /** - * Returns a prototype for the child node that is associated to $key in the value array. - * For general child nodes, this will be $this->prototype. - * But if $this->removeKeyAttribute is true and there are only two keys in the child node: - * one is same as this->keyAttribute and the other is 'value', then the prototype will be different. - * - * For example, assume $this->keyAttribute is 'name' and the value array is as follows: - * - * [ - * [ - * 'name' => 'name001', - * 'value' => 'value001' - * ] - * ] - * - * Now, the key is 0 and the child node is: - * - * [ - * 'name' => 'name001', - * 'value' => 'value001' - * ] - * - * When normalizing the value array, the 'name' element will removed from the child node - * and its value becomes the new key of the child node: - * - * [ - * 'name001' => ['value' => 'value001'] - * ] - * - * Now only 'value' element is left in the child node which can be further simplified into a string: - * - * ['name001' => 'value001'] - * - * Now, the key becomes 'name001' and the child node becomes 'value001' and - * the prototype of child node 'name001' should be a ScalarNode instead of an ArrayNode instance. - * - * @param string $key The key of the child node - * - * @return mixed The prototype instance - */ - private function getPrototypeForChild($key) - { - $prototype = isset($this->valuePrototypes[$key]) ? $this->valuePrototypes[$key] : $this->prototype; - $prototype->setName($key); - return $prototype; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\DuplicateKeyException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException; +/** + * Represents a prototyped Array node in the config tree. + * + * @author Johannes M. Schmitt + */ +class PrototypedArrayNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode +{ + protected $prototype; + protected $keyAttribute; + protected $removeKeyAttribute = \false; + protected $minNumberOfElements = 0; + protected $defaultValue = []; + protected $defaultChildren; + /** + * @var NodeInterface[] An array of the prototypes of the simplified value children + */ + private $valuePrototypes = []; + /** + * Sets the minimum number of elements that a prototype based node must + * contain. By default this is zero, meaning no elements. + * + * @param int $number + */ + public function setMinNumberOfElements($number) + { + $this->minNumberOfElements = $number; + } + /** + * Sets the attribute which value is to be used as key. + * + * This is useful when you have an indexed array that should be an + * associative array. You can select an item from within the array + * to be the key of the particular item. For example, if "id" is the + * "key", then: + * + * [ + * ['id' => 'my_name', 'foo' => 'bar'], + * ]; + * + * becomes + * + * [ + * 'my_name' => ['foo' => 'bar'], + * ]; + * + * If you'd like "'id' => 'my_name'" to still be present in the resulting + * array, then you can set the second argument of this method to false. + * + * @param string $attribute The name of the attribute which value is to be used as a key + * @param bool $remove Whether or not to remove the key + */ + public function setKeyAttribute($attribute, $remove = \true) + { + $this->keyAttribute = $attribute; + $this->removeKeyAttribute = $remove; + } + /** + * Retrieves the name of the attribute which value should be used as key. + * + * @return string|null The name of the attribute + */ + public function getKeyAttribute() + { + return $this->keyAttribute; + } + /** + * Sets the default value of this node. + * + * @param string $value + * + * @throws \InvalidArgumentException if the default value is not an array + */ + public function setDefaultValue($value) + { + if (!\is_array($value)) { + throw new \InvalidArgumentException($this->getPath() . ': the default value of an array node has to be an array.'); + } + $this->defaultValue = $value; + } + /** + * {@inheritdoc} + */ + public function hasDefaultValue() + { + return \true; + } + /** + * Adds default children when none are set. + * + * @param int|string|array|null $children The number of children|The child name|The children names to be added + */ + public function setAddChildrenIfNoneSet($children = ['defaults']) + { + if (null === $children) { + $this->defaultChildren = ['defaults']; + } else { + $this->defaultChildren = \is_int($children) && $children > 0 ? \range(1, $children) : (array) $children; + } + } + /** + * {@inheritdoc} + * + * The default value could be either explicited or derived from the prototype + * default value. + */ + public function getDefaultValue() + { + if (null !== $this->defaultChildren) { + $default = $this->prototype->hasDefaultValue() ? $this->prototype->getDefaultValue() : []; + $defaults = []; + foreach (\array_values($this->defaultChildren) as $i => $name) { + $defaults[null === $this->keyAttribute ? $i : $name] = $default; + } + return $defaults; + } + return $this->defaultValue; + } + /** + * Sets the node prototype. + */ + public function setPrototype(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypeNodeInterface $node) + { + $this->prototype = $node; + } + /** + * Retrieves the prototype. + * + * @return PrototypeNodeInterface The prototype + */ + public function getPrototype() + { + return $this->prototype; + } + /** + * Disable adding concrete children for prototyped nodes. + * + * @throws Exception + */ + public function addChild(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $node) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\Exception('A prototyped array node can not have concrete children.'); + } + /** + * Finalizes the value of this node. + * + * @param mixed $value + * + * @return mixed The finalized value + * + * @throws UnsetKeyException + * @throws InvalidConfigurationException if the node doesn't have enough children + */ + protected function finalizeValue($value) + { + if (\false === $value) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException(\sprintf('Unsetting key for path "%s", value: "%s".', $this->getPath(), \json_encode($value))); + } + foreach ($value as $k => $v) { + $prototype = $this->getPrototypeForChild($k); + try { + $value[$k] = $prototype->finalize($v); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\UnsetKeyException $e) { + unset($value[$k]); + } + } + if (\count($value) < $this->minNumberOfElements) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('The path "%s" should have at least %d element(s) defined.', $this->getPath(), $this->minNumberOfElements)); + $ex->setPath($this->getPath()); + throw $ex; + } + return $value; + } + /** + * Normalizes the value. + * + * @param mixed $value The value to normalize + * + * @return mixed The normalized value + * + * @throws InvalidConfigurationException + * @throws DuplicateKeyException + */ + protected function normalizeValue($value) + { + if (\false === $value) { + return $value; + } + $value = $this->remapXml($value); + $isAssoc = \array_keys($value) !== \range(0, \count($value) - 1); + $normalized = []; + foreach ($value as $k => $v) { + if (null !== $this->keyAttribute && \is_array($v)) { + if (!isset($v[$this->keyAttribute]) && \is_int($k) && !$isAssoc) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('The attribute "%s" must be set for path "%s".', $this->keyAttribute, $this->getPath())); + $ex->setPath($this->getPath()); + throw $ex; + } elseif (isset($v[$this->keyAttribute])) { + $k = $v[$this->keyAttribute]; + // remove the key attribute when required + if ($this->removeKeyAttribute) { + unset($v[$this->keyAttribute]); + } + // if only "value" is left + if (\array_keys($v) === ['value']) { + $v = $v['value']; + if ($this->prototype instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode && ($children = $this->prototype->getChildren()) && \array_key_exists('value', $children)) { + $valuePrototype = \current($this->valuePrototypes) ?: clone $children['value']; + $valuePrototype->parent = $this; + $originalClosures = $this->prototype->normalizationClosures; + if (\is_array($originalClosures)) { + $valuePrototypeClosures = $valuePrototype->normalizationClosures; + $valuePrototype->normalizationClosures = \is_array($valuePrototypeClosures) ? \array_merge($originalClosures, $valuePrototypeClosures) : $originalClosures; + } + $this->valuePrototypes[$k] = $valuePrototype; + } + } + } + if (\array_key_exists($k, $normalized)) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\DuplicateKeyException(\sprintf('Duplicate key "%s" for path "%s".', $k, $this->getPath())); + $ex->setPath($this->getPath()); + throw $ex; + } + } + $prototype = $this->getPrototypeForChild($k); + if (null !== $this->keyAttribute || $isAssoc) { + $normalized[$k] = $prototype->normalize($v); + } else { + $normalized[] = $prototype->normalize($v); + } + } + return $normalized; + } + /** + * Merges values together. + * + * @param mixed $leftSide The left side to merge + * @param mixed $rightSide The right side to merge + * + * @return mixed The merged values + * + * @throws InvalidConfigurationException + * @throws \RuntimeException + */ + protected function mergeValues($leftSide, $rightSide) + { + if (\false === $rightSide) { + // if this is still false after the last config has been merged the + // finalization pass will take care of removing this key entirely + return \false; + } + if (\false === $leftSide || !$this->performDeepMerging) { + return $rightSide; + } + foreach ($rightSide as $k => $v) { + // prototype, and key is irrelevant, append the element + if (null === $this->keyAttribute) { + $leftSide[] = $v; + continue; + } + // no conflict + if (!\array_key_exists($k, $leftSide)) { + if (!$this->allowNewKeys) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('You are not allowed to define new elements for path "%s". Please define all elements for this path in one config file.', $this->getPath())); + $ex->setPath($this->getPath()); + throw $ex; + } + $leftSide[$k] = $v; + continue; + } + $prototype = $this->getPrototypeForChild($k); + $leftSide[$k] = $prototype->merge($leftSide[$k], $v); + } + return $leftSide; + } + /** + * Returns a prototype for the child node that is associated to $key in the value array. + * For general child nodes, this will be $this->prototype. + * But if $this->removeKeyAttribute is true and there are only two keys in the child node: + * one is same as this->keyAttribute and the other is 'value', then the prototype will be different. + * + * For example, assume $this->keyAttribute is 'name' and the value array is as follows: + * + * [ + * [ + * 'name' => 'name001', + * 'value' => 'value001' + * ] + * ] + * + * Now, the key is 0 and the child node is: + * + * [ + * 'name' => 'name001', + * 'value' => 'value001' + * ] + * + * When normalizing the value array, the 'name' element will removed from the child node + * and its value becomes the new key of the child node: + * + * [ + * 'name001' => ['value' => 'value001'] + * ] + * + * Now only 'value' element is left in the child node which can be further simplified into a string: + * + * ['name001' => 'value001'] + * + * Now, the key becomes 'name001' and the child node becomes 'value001' and + * the prototype of child node 'name001' should be a ScalarNode instead of an ArrayNode instance. + * + * @param string $key The key of the child node + * + * @return mixed The prototype instance + */ + private function getPrototypeForChild($key) + { + $prototype = isset($this->valuePrototypes[$key]) ? $this->valuePrototypes[$key] : $this->prototype; + $prototype->setName($key); + return $prototype; + } +} diff --git a/vendor/symfony/config/Definition/ScalarNode.php b/vendor/symfony/config/Definition/ScalarNode.php index edf700977..f722419bf 100644 --- a/vendor/symfony/config/Definition/ScalarNode.php +++ b/vendor/symfony/config/Definition/ScalarNode.php @@ -1,49 +1,49 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; -/** - * This node represents a scalar value in the config tree. - * - * The following values are considered scalars: - * * booleans - * * strings - * * null - * * integers - * * floats - * - * @author Johannes M. Schmitt - */ -class ScalarNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\VariableNode -{ - /** - * {@inheritdoc} - */ - protected function validateType($value) - { - if (!\is_scalar($value) && null !== $value) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException(\sprintf('Invalid type for path "%s". Expected scalar, but got %s.', $this->getPath(), \gettype($value))); - if ($hint = $this->getInfo()) { - $ex->addHint($hint); - } - $ex->setPath($this->getPath()); - throw $ex; - } - } - /** - * {@inheritdoc} - */ - protected function isValueEmpty($value) - { - return null === $value || '' === $value; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException; +/** + * This node represents a scalar value in the config tree. + * + * The following values are considered scalars: + * * booleans + * * strings + * * null + * * integers + * * floats + * + * @author Johannes M. Schmitt + */ +class ScalarNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\VariableNode +{ + /** + * {@inheritdoc} + */ + protected function validateType($value) + { + if (!\is_scalar($value) && null !== $value) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidTypeException(\sprintf('Invalid type for path "%s". Expected scalar, but got %s.', $this->getPath(), \gettype($value))); + if ($hint = $this->getInfo()) { + $ex->addHint($hint); + } + $ex->setPath($this->getPath()); + throw $ex; + } + } + /** + * {@inheritdoc} + */ + protected function isValueEmpty($value) + { + return null === $value || '' === $value; + } +} diff --git a/vendor/symfony/config/Definition/VariableNode.php b/vendor/symfony/config/Definition/VariableNode.php index b59d55155..7daed2b2c 100644 --- a/vendor/symfony/config/Definition/VariableNode.php +++ b/vendor/symfony/config/Definition/VariableNode.php @@ -1,113 +1,113 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; -/** - * This node represents a value of variable type in the config tree. - * - * This node is intended for values of arbitrary type. - * Any PHP type is accepted as a value. - * - * @author Jeremy Mikola - */ -class VariableNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BaseNode implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypeNodeInterface -{ - protected $defaultValueSet = \false; - protected $defaultValue; - protected $allowEmptyValue = \true; - public function setDefaultValue($value) - { - $this->defaultValueSet = \true; - $this->defaultValue = $value; - } - /** - * {@inheritdoc} - */ - public function hasDefaultValue() - { - return $this->defaultValueSet; - } - /** - * {@inheritdoc} - */ - public function getDefaultValue() - { - $v = $this->defaultValue; - return $v instanceof \Closure ? $v() : $v; - } - /** - * Sets if this node is allowed to have an empty value. - * - * @param bool $boolean True if this entity will accept empty values - */ - public function setAllowEmptyValue($boolean) - { - $this->allowEmptyValue = (bool) $boolean; - } - /** - * {@inheritdoc} - */ - public function setName($name) - { - $this->name = $name; - } - /** - * {@inheritdoc} - */ - protected function validateType($value) - { - } - /** - * {@inheritdoc} - */ - protected function finalizeValue($value) - { - if (!$this->allowEmptyValue && $this->isValueEmpty($value)) { - $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('The path "%s" cannot contain an empty value, but got %s.', $this->getPath(), \json_encode($value))); - if ($hint = $this->getInfo()) { - $ex->addHint($hint); - } - $ex->setPath($this->getPath()); - throw $ex; - } - return $value; - } - /** - * {@inheritdoc} - */ - protected function normalizeValue($value) - { - return $value; - } - /** - * {@inheritdoc} - */ - protected function mergeValues($leftSide, $rightSide) - { - return $rightSide; - } - /** - * Evaluates if the given value is to be treated as empty. - * - * By default, PHP's empty() function is used to test for emptiness. This - * method may be overridden by subtypes to better match their understanding - * of empty data. - * - * @param mixed $value - * - * @return bool - */ - protected function isValueEmpty($value) - { - return empty($value); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; +/** + * This node represents a value of variable type in the config tree. + * + * This node is intended for values of arbitrary type. + * Any PHP type is accepted as a value. + * + * @author Jeremy Mikola + */ +class VariableNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BaseNode implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypeNodeInterface +{ + protected $defaultValueSet = \false; + protected $defaultValue; + protected $allowEmptyValue = \true; + public function setDefaultValue($value) + { + $this->defaultValueSet = \true; + $this->defaultValue = $value; + } + /** + * {@inheritdoc} + */ + public function hasDefaultValue() + { + return $this->defaultValueSet; + } + /** + * {@inheritdoc} + */ + public function getDefaultValue() + { + $v = $this->defaultValue; + return $v instanceof \Closure ? $v() : $v; + } + /** + * Sets if this node is allowed to have an empty value. + * + * @param bool $boolean True if this entity will accept empty values + */ + public function setAllowEmptyValue($boolean) + { + $this->allowEmptyValue = (bool) $boolean; + } + /** + * {@inheritdoc} + */ + public function setName($name) + { + $this->name = $name; + } + /** + * {@inheritdoc} + */ + protected function validateType($value) + { + } + /** + * {@inheritdoc} + */ + protected function finalizeValue($value) + { + if (!$this->allowEmptyValue && $this->isValueEmpty($value)) { + $ex = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException(\sprintf('The path "%s" cannot contain an empty value, but got %s.', $this->getPath(), \json_encode($value))); + if ($hint = $this->getInfo()) { + $ex->addHint($hint); + } + $ex->setPath($this->getPath()); + throw $ex; + } + return $value; + } + /** + * {@inheritdoc} + */ + protected function normalizeValue($value) + { + return $value; + } + /** + * {@inheritdoc} + */ + protected function mergeValues($leftSide, $rightSide) + { + return $rightSide; + } + /** + * Evaluates if the given value is to be treated as empty. + * + * By default, PHP's empty() function is used to test for emptiness. This + * method may be overridden by subtypes to better match their understanding + * of empty data. + * + * @param mixed $value + * + * @return bool + */ + protected function isValueEmpty($value) + { + return empty($value); + } +} diff --git a/vendor/symfony/config/Definition/index.php b/vendor/symfony/config/Definition/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Definition/index.php +++ b/vendor/symfony/config/Definition/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/DependencyInjection/ConfigCachePass.php b/vendor/symfony/config/DependencyInjection/ConfigCachePass.php index 58043e8a2..305590789 100644 --- a/vendor/symfony/config/DependencyInjection/ConfigCachePass.php +++ b/vendor/symfony/config/DependencyInjection/ConfigCachePass.php @@ -1,44 +1,44 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\DependencyInjection; - -@\trigger_error(\sprintf('The %s class is deprecated since Symfony 3.4 and will be removed in 4.0. Use tagged iterator arguments instead.', \_PhpScoper5ea00cc67502b\Symfony\Component\Config\DependencyInjection\ConfigCachePass::class), \E_USER_DEPRECATED); -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PriorityTaggedServiceTrait; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * Adds services tagged config_cache.resource_checker to the config_cache_factory service, ordering them by priority. - * - * @author Matthias Pigulla - * @author Benjamin Klotz - * - * @deprecated since version 3.4, to be removed in 4.0. Use tagged iterator arguments instead. - */ -class ConfigCachePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - use PriorityTaggedServiceTrait; - private $factoryServiceId; - private $resourceCheckerTag; - public function __construct($factoryServiceId = 'config_cache_factory', $resourceCheckerTag = 'config_cache.resource_checker') - { - $this->factoryServiceId = $factoryServiceId; - $this->resourceCheckerTag = $resourceCheckerTag; - } - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $resourceCheckers = $this->findAndSortTaggedServices($this->resourceCheckerTag, $container); - if (empty($resourceCheckers)) { - return; - } - $container->getDefinition($this->factoryServiceId)->replaceArgument(0, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument($resourceCheckers)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\DependencyInjection; + +@\trigger_error(\sprintf('The %s class is deprecated since Symfony 3.4 and will be removed in 4.0. Use tagged iterator arguments instead.', \_PhpScoper5ea00cc67502b\Symfony\Component\Config\DependencyInjection\ConfigCachePass::class), \E_USER_DEPRECATED); +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PriorityTaggedServiceTrait; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * Adds services tagged config_cache.resource_checker to the config_cache_factory service, ordering them by priority. + * + * @author Matthias Pigulla + * @author Benjamin Klotz + * + * @deprecated since version 3.4, to be removed in 4.0. Use tagged iterator arguments instead. + */ +class ConfigCachePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + use PriorityTaggedServiceTrait; + private $factoryServiceId; + private $resourceCheckerTag; + public function __construct($factoryServiceId = 'config_cache_factory', $resourceCheckerTag = 'config_cache.resource_checker') + { + $this->factoryServiceId = $factoryServiceId; + $this->resourceCheckerTag = $resourceCheckerTag; + } + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $resourceCheckers = $this->findAndSortTaggedServices($this->resourceCheckerTag, $container); + if (empty($resourceCheckers)) { + return; + } + $container->getDefinition($this->factoryServiceId)->replaceArgument(0, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument($resourceCheckers)); + } +} diff --git a/vendor/symfony/config/DependencyInjection/index.php b/vendor/symfony/config/DependencyInjection/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/DependencyInjection/index.php +++ b/vendor/symfony/config/DependencyInjection/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Exception/FileLoaderImportCircularReferenceException.php b/vendor/symfony/config/Exception/FileLoaderImportCircularReferenceException.php index 7b5a71fc2..51a206962 100644 --- a/vendor/symfony/config/Exception/FileLoaderImportCircularReferenceException.php +++ b/vendor/symfony/config/Exception/FileLoaderImportCircularReferenceException.php @@ -1,25 +1,25 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception; - -/** - * Exception class for when a circular reference is detected when importing resources. - * - * @author Fabien Potencier - */ -class FileLoaderImportCircularReferenceException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException -{ - public function __construct(array $resources, $code = null, $previous = null) - { - $message = \sprintf('Circular reference detected in "%s" ("%s" > "%s").', $this->varToString($resources[0]), \implode('" > "', $resources), $resources[0]); - \Exception::__construct($message, $code, $previous); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception; + +/** + * Exception class for when a circular reference is detected when importing resources. + * + * @author Fabien Potencier + */ +class FileLoaderImportCircularReferenceException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException +{ + public function __construct(array $resources, $code = null, $previous = null) + { + $message = \sprintf('Circular reference detected in "%s" ("%s" > "%s").', $this->varToString($resources[0]), \implode('" > "', $resources), $resources[0]); + \Exception::__construct($message, $code, $previous); + } +} diff --git a/vendor/symfony/config/Exception/FileLoaderLoadException.php b/vendor/symfony/config/Exception/FileLoaderLoadException.php index 02cba2118..413b218f8 100644 --- a/vendor/symfony/config/Exception/FileLoaderLoadException.php +++ b/vendor/symfony/config/Exception/FileLoaderLoadException.php @@ -1,95 +1,95 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception; - -/** - * Exception class for when a resource cannot be loaded or imported. - * - * @author Ryan Weaver - */ -class FileLoaderLoadException extends \Exception -{ - /** - * @param string $resource The resource that could not be imported - * @param string $sourceResource The original resource importing the new resource - * @param int $code The error code - * @param \Exception $previous A previous exception - * @param string $type The type of resource - */ - public function __construct($resource, $sourceResource = null, $code = null, $previous = null, $type = null) - { - $message = ''; - if ($previous) { - // Include the previous exception, to help the user see what might be the underlying cause - // Trim the trailing period of the previous message. We only want 1 period remove so no rtrim... - if ('.' === \substr($previous->getMessage(), -1)) { - $trimmedMessage = \substr($previous->getMessage(), 0, -1); - $message .= \sprintf('%s', $trimmedMessage) . ' in '; - } else { - $message .= \sprintf('%s', $previous->getMessage()) . ' in '; - } - $message .= $resource . ' '; - // show tweaked trace to complete the human readable sentence - if (null === $sourceResource) { - $message .= \sprintf('(which is loaded in resource "%s")', $this->varToString($resource)); - } else { - $message .= \sprintf('(which is being imported from "%s")', $this->varToString($sourceResource)); - } - $message .= '.'; - // if there's no previous message, present it the default way - } elseif (null === $sourceResource) { - $message .= \sprintf('Cannot load resource "%s".', $this->varToString($resource)); - } else { - $message .= \sprintf('Cannot import resource "%s" from "%s".', $this->varToString($resource), $this->varToString($sourceResource)); - } - // Is the resource located inside a bundle? - if ('@' === $resource[0]) { - $parts = \explode(\DIRECTORY_SEPARATOR, $resource); - $bundle = \substr($parts[0], 1); - $message .= \sprintf(' Make sure the "%s" bundle is correctly registered and loaded in the application kernel class.', $bundle); - $message .= \sprintf(' If the bundle is registered, make sure the bundle path "%s" is not empty.', $resource); - } elseif (null !== $type) { - // maybe there is no loader for this specific type - if ('annotation' === $type) { - $message .= ' Make sure annotations are installed and enabled.'; - } else { - $message .= \sprintf(' Make sure there is a loader supporting the "%s" type.', $type); - } - } - parent::__construct($message, $code, $previous); - } - protected function varToString($var) - { - if (\is_object($var)) { - return \sprintf('Object(%s)', \get_class($var)); - } - if (\is_array($var)) { - $a = []; - foreach ($var as $k => $v) { - $a[] = \sprintf('%s => %s', $k, $this->varToString($v)); - } - return \sprintf('Array(%s)', \implode(', ', $a)); - } - if (\is_resource($var)) { - return \sprintf('Resource(%s)', \get_resource_type($var)); - } - if (null === $var) { - return 'null'; - } - if (\false === $var) { - return 'false'; - } - if (\true === $var) { - return 'true'; - } - return (string) $var; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception; + +/** + * Exception class for when a resource cannot be loaded or imported. + * + * @author Ryan Weaver + */ +class FileLoaderLoadException extends \Exception +{ + /** + * @param string $resource The resource that could not be imported + * @param string $sourceResource The original resource importing the new resource + * @param int $code The error code + * @param \Exception $previous A previous exception + * @param string $type The type of resource + */ + public function __construct($resource, $sourceResource = null, $code = null, $previous = null, $type = null) + { + $message = ''; + if ($previous) { + // Include the previous exception, to help the user see what might be the underlying cause + // Trim the trailing period of the previous message. We only want 1 period remove so no rtrim... + if ('.' === \substr($previous->getMessage(), -1)) { + $trimmedMessage = \substr($previous->getMessage(), 0, -1); + $message .= \sprintf('%s', $trimmedMessage) . ' in '; + } else { + $message .= \sprintf('%s', $previous->getMessage()) . ' in '; + } + $message .= $resource . ' '; + // show tweaked trace to complete the human readable sentence + if (null === $sourceResource) { + $message .= \sprintf('(which is loaded in resource "%s")', $this->varToString($resource)); + } else { + $message .= \sprintf('(which is being imported from "%s")', $this->varToString($sourceResource)); + } + $message .= '.'; + // if there's no previous message, present it the default way + } elseif (null === $sourceResource) { + $message .= \sprintf('Cannot load resource "%s".', $this->varToString($resource)); + } else { + $message .= \sprintf('Cannot import resource "%s" from "%s".', $this->varToString($resource), $this->varToString($sourceResource)); + } + // Is the resource located inside a bundle? + if ('@' === $resource[0]) { + $parts = \explode(\DIRECTORY_SEPARATOR, $resource); + $bundle = \substr($parts[0], 1); + $message .= \sprintf(' Make sure the "%s" bundle is correctly registered and loaded in the application kernel class.', $bundle); + $message .= \sprintf(' If the bundle is registered, make sure the bundle path "%s" is not empty.', $resource); + } elseif (null !== $type) { + // maybe there is no loader for this specific type + if ('annotation' === $type) { + $message .= ' Make sure annotations are installed and enabled.'; + } else { + $message .= \sprintf(' Make sure there is a loader supporting the "%s" type.', $type); + } + } + parent::__construct($message, $code, $previous); + } + protected function varToString($var) + { + if (\is_object($var)) { + return \sprintf('Object(%s)', \get_class($var)); + } + if (\is_array($var)) { + $a = []; + foreach ($var as $k => $v) { + $a[] = \sprintf('%s => %s', $k, $this->varToString($v)); + } + return \sprintf('Array(%s)', \implode(', ', $a)); + } + if (\is_resource($var)) { + return \sprintf('Resource(%s)', \get_resource_type($var)); + } + if (null === $var) { + return 'null'; + } + if (\false === $var) { + return 'false'; + } + if (\true === $var) { + return 'true'; + } + return (string) $var; + } +} diff --git a/vendor/symfony/config/Exception/FileLocatorFileNotFoundException.php b/vendor/symfony/config/Exception/FileLocatorFileNotFoundException.php index 632b6c014..4c2cf9ea1 100644 --- a/vendor/symfony/config/Exception/FileLocatorFileNotFoundException.php +++ b/vendor/symfony/config/Exception/FileLocatorFileNotFoundException.php @@ -1,30 +1,30 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception; - -/** - * File locator exception if a file does not exist. - * - * @author Leo Feyer - */ -class FileLocatorFileNotFoundException extends \InvalidArgumentException -{ - private $paths; - public function __construct($message = '', $code = 0, $previous = null, array $paths = []) - { - parent::__construct($message, $code, $previous); - $this->paths = $paths; - } - public function getPaths() - { - return $this->paths; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception; + +/** + * File locator exception if a file does not exist. + * + * @author Leo Feyer + */ +class FileLocatorFileNotFoundException extends \InvalidArgumentException +{ + private $paths; + public function __construct($message = '', $code = 0, $previous = null, array $paths = []) + { + parent::__construct($message, $code, $previous); + $this->paths = $paths; + } + public function getPaths() + { + return $this->paths; + } +} diff --git a/vendor/symfony/config/Exception/index.php b/vendor/symfony/config/Exception/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Exception/index.php +++ b/vendor/symfony/config/Exception/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/FileLocator.php b/vendor/symfony/config/FileLocator.php index 2c1e6156c..64f3598d5 100644 --- a/vendor/symfony/config/FileLocator.php +++ b/vendor/symfony/config/FileLocator.php @@ -1,78 +1,78 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException; -/** - * FileLocator uses an array of pre-defined paths to find files. - * - * @author Fabien Potencier - */ -class FileLocator implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocatorInterface -{ - protected $paths; - /** - * @param string|array $paths A path or an array of paths where to look for resources - */ - public function __construct($paths = []) - { - $this->paths = (array) $paths; - } - /** - * {@inheritdoc} - */ - public function locate($name, $currentPath = null, $first = \true) - { - if ('' == $name) { - throw new \InvalidArgumentException('An empty file name is not valid to be located.'); - } - if ($this->isAbsolutePath($name)) { - if (!\file_exists($name)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException(\sprintf('The file "%s" does not exist.', $name), 0, null, [$name]); - } - return $name; - } - $paths = $this->paths; - if (null !== $currentPath) { - \array_unshift($paths, $currentPath); - } - $paths = \array_unique($paths); - $filepaths = $notfound = []; - foreach ($paths as $path) { - if (@\file_exists($file = $path . \DIRECTORY_SEPARATOR . $name)) { - if (\true === $first) { - return $file; - } - $filepaths[] = $file; - } else { - $notfound[] = $file; - } - } - if (!$filepaths) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException(\sprintf('The file "%s" does not exist (in: "%s").', $name, \implode('", "', $paths)), 0, null, $notfound); - } - return $filepaths; - } - /** - * Returns whether the file path is an absolute path. - * - * @param string $file A file path - * - * @return bool - */ - private function isAbsolutePath($file) - { - if ('/' === $file[0] || '\\' === $file[0] || \strlen($file) > 3 && \ctype_alpha($file[0]) && ':' === $file[1] && ('\\' === $file[2] || '/' === $file[2]) || null !== \parse_url($file, \PHP_URL_SCHEME)) { - return \true; - } - return \false; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException; +/** + * FileLocator uses an array of pre-defined paths to find files. + * + * @author Fabien Potencier + */ +class FileLocator implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocatorInterface +{ + protected $paths; + /** + * @param string|array $paths A path or an array of paths where to look for resources + */ + public function __construct($paths = []) + { + $this->paths = (array) $paths; + } + /** + * {@inheritdoc} + */ + public function locate($name, $currentPath = null, $first = \true) + { + if ('' == $name) { + throw new \InvalidArgumentException('An empty file name is not valid to be located.'); + } + if ($this->isAbsolutePath($name)) { + if (!\file_exists($name)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException(\sprintf('The file "%s" does not exist.', $name), 0, null, [$name]); + } + return $name; + } + $paths = $this->paths; + if (null !== $currentPath) { + \array_unshift($paths, $currentPath); + } + $paths = \array_unique($paths); + $filepaths = $notfound = []; + foreach ($paths as $path) { + if (@\file_exists($file = $path . \DIRECTORY_SEPARATOR . $name)) { + if (\true === $first) { + return $file; + } + $filepaths[] = $file; + } else { + $notfound[] = $file; + } + } + if (!$filepaths) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException(\sprintf('The file "%s" does not exist (in: "%s").', $name, \implode('", "', $paths)), 0, null, $notfound); + } + return $filepaths; + } + /** + * Returns whether the file path is an absolute path. + * + * @param string $file A file path + * + * @return bool + */ + private function isAbsolutePath($file) + { + if ('/' === $file[0] || '\\' === $file[0] || \strlen($file) > 3 && \ctype_alpha($file[0]) && ':' === $file[1] && ('\\' === $file[2] || '/' === $file[2]) || null !== \parse_url($file, \PHP_URL_SCHEME)) { + return \true; + } + return \false; + } +} diff --git a/vendor/symfony/config/FileLocatorInterface.php b/vendor/symfony/config/FileLocatorInterface.php index f0ddb5be9..1293074f4 100644 --- a/vendor/symfony/config/FileLocatorInterface.php +++ b/vendor/symfony/config/FileLocatorInterface.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException; -/** - * @author Fabien Potencier - */ -interface FileLocatorInterface -{ - /** - * Returns a full path for a given file name. - * - * @param string $name The file name to locate - * @param string|null $currentPath The current path - * @param bool $first Whether to return the first occurrence or an array of filenames - * - * @return string|array The full path to the file or an array of file paths - * - * @throws \InvalidArgumentException If $name is empty - * @throws FileLocatorFileNotFoundException If a file is not found - */ - public function locate($name, $currentPath = null, $first = \true); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException; +/** + * @author Fabien Potencier + */ +interface FileLocatorInterface +{ + /** + * Returns a full path for a given file name. + * + * @param string $name The file name to locate + * @param string|null $currentPath The current path + * @param bool $first Whether to return the first occurrence or an array of filenames + * + * @return string|array The full path to the file or an array of file paths + * + * @throws \InvalidArgumentException If $name is empty + * @throws FileLocatorFileNotFoundException If a file is not found + */ + public function locate($name, $currentPath = null, $first = \true); +} diff --git a/vendor/symfony/config/LICENSE b/vendor/symfony/config/LICENSE index 9e936ec04..2bb330476 100644 --- a/vendor/symfony/config/LICENSE +++ b/vendor/symfony/config/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2004-2020 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2004-2020 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/config/Loader/DelegatingLoader.php b/vendor/symfony/config/Loader/DelegatingLoader.php index 6991c41d9..7cec5eec6 100644 --- a/vendor/symfony/config/Loader/DelegatingLoader.php +++ b/vendor/symfony/config/Loader/DelegatingLoader.php @@ -1,45 +1,45 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException; -/** - * DelegatingLoader delegates loading to other loaders using a loader resolver. - * - * This loader acts as an array of LoaderInterface objects - each having - * a chance to load a given resource (handled by the resolver) - * - * @author Fabien Potencier - */ -class DelegatingLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader -{ - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolverInterface $resolver) - { - $this->resolver = $resolver; - } - /** - * {@inheritdoc} - */ - public function load($resource, $type = null) - { - if (\false === ($loader = $this->resolver->resolve($resource, $type))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException($resource, null, null, null, $type); - } - return $loader->load($resource, $type); - } - /** - * {@inheritdoc} - */ - public function supports($resource, $type = null) - { - return \false !== $this->resolver->resolve($resource, $type); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException; +/** + * DelegatingLoader delegates loading to other loaders using a loader resolver. + * + * This loader acts as an array of LoaderInterface objects - each having + * a chance to load a given resource (handled by the resolver) + * + * @author Fabien Potencier + */ +class DelegatingLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader +{ + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolverInterface $resolver) + { + $this->resolver = $resolver; + } + /** + * {@inheritdoc} + */ + public function load($resource, $type = null) + { + if (\false === ($loader = $this->resolver->resolve($resource, $type))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException($resource, null, null, null, $type); + } + return $loader->load($resource, $type); + } + /** + * {@inheritdoc} + */ + public function supports($resource, $type = null) + { + return \false !== $this->resolver->resolve($resource, $type); + } +} diff --git a/vendor/symfony/config/Loader/FileLoader.php b/vendor/symfony/config/Loader/FileLoader.php index 57ee2426f..ec2647783 100644 --- a/vendor/symfony/config/Loader/FileLoader.php +++ b/vendor/symfony/config/Loader/FileLoader.php @@ -1,152 +1,152 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderImportCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocatorInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; -/** - * FileLoader is the abstract class used by all built-in loaders that are file based. - * - * @author Fabien Potencier - */ -abstract class FileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader -{ - protected static $loading = []; - protected $locator; - private $currentDir; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocatorInterface $locator) - { - $this->locator = $locator; - } - /** - * Sets the current directory. - * - * @param string $dir - */ - public function setCurrentDir($dir) - { - $this->currentDir = $dir; - } - /** - * Returns the file locator used by this loader. - * - * @return FileLocatorInterface - */ - public function getLocator() - { - return $this->locator; - } - /** - * Imports a resource. - * - * @param mixed $resource A Resource - * @param string|null $type The resource type or null if unknown - * @param bool $ignoreErrors Whether to ignore import errors or not - * @param string|null $sourceResource The original resource importing the new resource - * - * @return mixed - * - * @throws FileLoaderLoadException - * @throws FileLoaderImportCircularReferenceException - * @throws FileLocatorFileNotFoundException - */ - public function import($resource, $type = null, $ignoreErrors = \false, $sourceResource = null) - { - if (\is_string($resource) && \strlen($resource) !== ($i = \strcspn($resource, '*?{['))) { - $ret = []; - $isSubpath = 0 !== $i && \false !== \strpos(\substr($resource, 0, $i), '/'); - foreach ($this->glob($resource, \false, $_, $ignoreErrors || !$isSubpath) as $path => $info) { - if (null !== ($res = $this->doImport($path, 'glob' === $type ? null : $type, $ignoreErrors, $sourceResource))) { - $ret[] = $res; - } - $isSubpath = \true; - } - if ($isSubpath) { - return isset($ret[1]) ? $ret : (isset($ret[0]) ? $ret[0] : null); - } - } - return $this->doImport($resource, $type, $ignoreErrors, $sourceResource); - } - /** - * @internal - */ - protected function glob($pattern, $recursive, &$resource = null, $ignoreErrors = \false) - { - if (\strlen($pattern) === ($i = \strcspn($pattern, '*?{['))) { - $prefix = $pattern; - $pattern = ''; - } elseif (0 === $i || \false === \strpos(\substr($pattern, 0, $i), '/')) { - $prefix = '.'; - $pattern = '/' . $pattern; - } else { - $prefix = \dirname(\substr($pattern, 0, 1 + $i)); - $pattern = \substr($pattern, \strlen($prefix)); - } - try { - $prefix = $this->locator->locate($prefix, $this->currentDir, \true); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException $e) { - if (!$ignoreErrors) { - throw $e; - } - $resource = []; - foreach ($e->getPaths() as $path) { - $resource[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource($path); - } - return; - } - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($prefix, $pattern, $recursive); - foreach ($resource as $path => $info) { - (yield $path => $info); - } - } - private function doImport($resource, $type = null, $ignoreErrors = \false, $sourceResource = null) - { - try { - $loader = $this->resolve($resource, $type); - if ($loader instanceof self && null !== $this->currentDir) { - $resource = $loader->getLocator()->locate($resource, $this->currentDir, \false); - } - $resources = \is_array($resource) ? $resource : [$resource]; - for ($i = 0; $i < ($resourcesCount = \count($resources)); ++$i) { - if (isset(self::$loading[$resources[$i]])) { - if ($i == $resourcesCount - 1) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderImportCircularReferenceException(\array_keys(self::$loading)); - } - } else { - $resource = $resources[$i]; - break; - } - } - self::$loading[$resource] = \true; - try { - $ret = $loader->load($resource, $type); - } finally { - unset(self::$loading[$resource]); - } - return $ret; - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderImportCircularReferenceException $e) { - throw $e; - } catch (\Exception $e) { - if (!$ignoreErrors) { - // prevent embedded imports from nesting multiple exceptions - if ($e instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException) { - throw $e; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException($resource, $sourceResource, null, $e, $type); - } - } - return null; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderImportCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocatorInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; +/** + * FileLoader is the abstract class used by all built-in loaders that are file based. + * + * @author Fabien Potencier + */ +abstract class FileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader +{ + protected static $loading = []; + protected $locator; + private $currentDir; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocatorInterface $locator) + { + $this->locator = $locator; + } + /** + * Sets the current directory. + * + * @param string $dir + */ + public function setCurrentDir($dir) + { + $this->currentDir = $dir; + } + /** + * Returns the file locator used by this loader. + * + * @return FileLocatorInterface + */ + public function getLocator() + { + return $this->locator; + } + /** + * Imports a resource. + * + * @param mixed $resource A Resource + * @param string|null $type The resource type or null if unknown + * @param bool $ignoreErrors Whether to ignore import errors or not + * @param string|null $sourceResource The original resource importing the new resource + * + * @return mixed + * + * @throws FileLoaderLoadException + * @throws FileLoaderImportCircularReferenceException + * @throws FileLocatorFileNotFoundException + */ + public function import($resource, $type = null, $ignoreErrors = \false, $sourceResource = null) + { + if (\is_string($resource) && \strlen($resource) !== ($i = \strcspn($resource, '*?{['))) { + $ret = []; + $isSubpath = 0 !== $i && \false !== \strpos(\substr($resource, 0, $i), '/'); + foreach ($this->glob($resource, \false, $_, $ignoreErrors || !$isSubpath) as $path => $info) { + if (null !== ($res = $this->doImport($path, 'glob' === $type ? null : $type, $ignoreErrors, $sourceResource))) { + $ret[] = $res; + } + $isSubpath = \true; + } + if ($isSubpath) { + return isset($ret[1]) ? $ret : (isset($ret[0]) ? $ret[0] : null); + } + } + return $this->doImport($resource, $type, $ignoreErrors, $sourceResource); + } + /** + * @internal + */ + protected function glob($pattern, $recursive, &$resource = null, $ignoreErrors = \false) + { + if (\strlen($pattern) === ($i = \strcspn($pattern, '*?{['))) { + $prefix = $pattern; + $pattern = ''; + } elseif (0 === $i || \false === \strpos(\substr($pattern, 0, $i), '/')) { + $prefix = '.'; + $pattern = '/' . $pattern; + } else { + $prefix = \dirname(\substr($pattern, 0, 1 + $i)); + $pattern = \substr($pattern, \strlen($prefix)); + } + try { + $prefix = $this->locator->locate($prefix, $this->currentDir, \true); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLocatorFileNotFoundException $e) { + if (!$ignoreErrors) { + throw $e; + } + $resource = []; + foreach ($e->getPaths() as $path) { + $resource[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource($path); + } + return; + } + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($prefix, $pattern, $recursive); + foreach ($resource as $path => $info) { + (yield $path => $info); + } + } + private function doImport($resource, $type = null, $ignoreErrors = \false, $sourceResource = null) + { + try { + $loader = $this->resolve($resource, $type); + if ($loader instanceof self && null !== $this->currentDir) { + $resource = $loader->getLocator()->locate($resource, $this->currentDir, \false); + } + $resources = \is_array($resource) ? $resource : [$resource]; + for ($i = 0; $i < ($resourcesCount = \count($resources)); ++$i) { + if (isset(self::$loading[$resources[$i]])) { + if ($i == $resourcesCount - 1) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderImportCircularReferenceException(\array_keys(self::$loading)); + } + } else { + $resource = $resources[$i]; + break; + } + } + self::$loading[$resource] = \true; + try { + $ret = $loader->load($resource, $type); + } finally { + unset(self::$loading[$resource]); + } + return $ret; + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderImportCircularReferenceException $e) { + throw $e; + } catch (\Exception $e) { + if (!$ignoreErrors) { + // prevent embedded imports from nesting multiple exceptions + if ($e instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException) { + throw $e; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException($resource, $sourceResource, null, $e, $type); + } + } + return null; + } +} diff --git a/vendor/symfony/config/Loader/GlobFileLoader.php b/vendor/symfony/config/Loader/GlobFileLoader.php index ad1bea3d0..4654bac3f 100644 --- a/vendor/symfony/config/Loader/GlobFileLoader.php +++ b/vendor/symfony/config/Loader/GlobFileLoader.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; - -/** - * GlobFileLoader loads files from a glob pattern. - * - * @author Fabien Potencier - */ -class GlobFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\FileLoader -{ - /** - * {@inheritdoc} - */ - public function load($resource, $type = null) - { - return $this->import($resource); - } - /** - * {@inheritdoc} - */ - public function supports($resource, $type = null) - { - return 'glob' === $type; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; + +/** + * GlobFileLoader loads files from a glob pattern. + * + * @author Fabien Potencier + */ +class GlobFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\FileLoader +{ + /** + * {@inheritdoc} + */ + public function load($resource, $type = null) + { + return $this->import($resource); + } + /** + * {@inheritdoc} + */ + public function supports($resource, $type = null) + { + return 'glob' === $type; + } +} diff --git a/vendor/symfony/config/Loader/Loader.php b/vendor/symfony/config/Loader/Loader.php index b49d411fd..10cc6e9e1 100644 --- a/vendor/symfony/config/Loader/Loader.php +++ b/vendor/symfony/config/Loader/Loader.php @@ -1,69 +1,69 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException; -/** - * Loader is the abstract class used by all built-in loaders. - * - * @author Fabien Potencier - */ -abstract class Loader implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderInterface -{ - protected $resolver; - /** - * {@inheritdoc} - */ - public function getResolver() - { - return $this->resolver; - } - /** - * {@inheritdoc} - */ - public function setResolver(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolverInterface $resolver) - { - $this->resolver = $resolver; - } - /** - * Imports a resource. - * - * @param mixed $resource A resource - * @param string|null $type The resource type or null if unknown - * - * @return mixed - */ - public function import($resource, $type = null) - { - return $this->resolve($resource, $type)->load($resource, $type); - } - /** - * Finds a loader able to load an imported resource. - * - * @param mixed $resource A resource - * @param string|null $type The resource type or null if unknown - * - * @return $this|LoaderInterface - * - * @throws FileLoaderLoadException If no loader is found - */ - public function resolve($resource, $type = null) - { - if ($this->supports($resource, $type)) { - return $this; - } - $loader = null === $this->resolver ? \false : $this->resolver->resolve($resource, $type); - if (\false === $loader) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException($resource, null, null, null, $type); - } - return $loader; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException; +/** + * Loader is the abstract class used by all built-in loaders. + * + * @author Fabien Potencier + */ +abstract class Loader implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderInterface +{ + protected $resolver; + /** + * {@inheritdoc} + */ + public function getResolver() + { + return $this->resolver; + } + /** + * {@inheritdoc} + */ + public function setResolver(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolverInterface $resolver) + { + $this->resolver = $resolver; + } + /** + * Imports a resource. + * + * @param mixed $resource A resource + * @param string|null $type The resource type or null if unknown + * + * @return mixed + */ + public function import($resource, $type = null) + { + return $this->resolve($resource, $type)->load($resource, $type); + } + /** + * Finds a loader able to load an imported resource. + * + * @param mixed $resource A resource + * @param string|null $type The resource type or null if unknown + * + * @return $this|LoaderInterface + * + * @throws FileLoaderLoadException If no loader is found + */ + public function resolve($resource, $type = null) + { + if ($this->supports($resource, $type)) { + return $this; + } + $loader = null === $this->resolver ? \false : $this->resolver->resolve($resource, $type); + if (\false === $loader) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException($resource, null, null, null, $type); + } + return $loader; + } +} diff --git a/vendor/symfony/config/Loader/LoaderInterface.php b/vendor/symfony/config/Loader/LoaderInterface.php index d02f90f8c..75edc485a 100644 --- a/vendor/symfony/config/Loader/LoaderInterface.php +++ b/vendor/symfony/config/Loader/LoaderInterface.php @@ -1,48 +1,48 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; - -/** - * LoaderInterface is the interface implemented by all loader classes. - * - * @author Fabien Potencier - */ -interface LoaderInterface -{ - /** - * Loads a resource. - * - * @param mixed $resource The resource - * @param string|null $type The resource type or null if unknown - * - * @throws \Exception If something went wrong - */ - public function load($resource, $type = null); - /** - * Returns whether this class supports the given resource. - * - * @param mixed $resource A resource - * @param string|null $type The resource type or null if unknown - * - * @return bool True if this class supports the given resource, false otherwise - */ - public function supports($resource, $type = null); - /** - * Gets the loader resolver. - * - * @return LoaderResolverInterface A LoaderResolverInterface instance - */ - public function getResolver(); - /** - * Sets the loader resolver. - */ - public function setResolver(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolverInterface $resolver); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; + +/** + * LoaderInterface is the interface implemented by all loader classes. + * + * @author Fabien Potencier + */ +interface LoaderInterface +{ + /** + * Loads a resource. + * + * @param mixed $resource The resource + * @param string|null $type The resource type or null if unknown + * + * @throws \Exception If something went wrong + */ + public function load($resource, $type = null); + /** + * Returns whether this class supports the given resource. + * + * @param mixed $resource A resource + * @param string|null $type The resource type or null if unknown + * + * @return bool True if this class supports the given resource, false otherwise + */ + public function supports($resource, $type = null); + /** + * Gets the loader resolver. + * + * @return LoaderResolverInterface A LoaderResolverInterface instance + */ + public function getResolver(); + /** + * Sets the loader resolver. + */ + public function setResolver(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolverInterface $resolver); +} diff --git a/vendor/symfony/config/Loader/LoaderResolver.php b/vendor/symfony/config/Loader/LoaderResolver.php index c0c925ea3..c2445f8d6 100644 --- a/vendor/symfony/config/Loader/LoaderResolver.php +++ b/vendor/symfony/config/Loader/LoaderResolver.php @@ -1,62 +1,62 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; - -/** - * LoaderResolver selects a loader for a given resource. - * - * A resource can be anything (e.g. a full path to a config file or a Closure). - * Each loader determines whether it can load a resource and how. - * - * @author Fabien Potencier - */ -class LoaderResolver implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolverInterface -{ - /** - * @var LoaderInterface[] An array of LoaderInterface objects - */ - private $loaders = []; - /** - * @param LoaderInterface[] $loaders An array of loaders - */ - public function __construct(array $loaders = []) - { - foreach ($loaders as $loader) { - $this->addLoader($loader); - } - } - /** - * {@inheritdoc} - */ - public function resolve($resource, $type = null) - { - foreach ($this->loaders as $loader) { - if ($loader->supports($resource, $type)) { - return $loader; - } - } - return \false; - } - public function addLoader(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderInterface $loader) - { - $this->loaders[] = $loader; - $loader->setResolver($this); - } - /** - * Returns the registered loaders. - * - * @return LoaderInterface[] An array of LoaderInterface instances - */ - public function getLoaders() - { - return $this->loaders; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; + +/** + * LoaderResolver selects a loader for a given resource. + * + * A resource can be anything (e.g. a full path to a config file or a Closure). + * Each loader determines whether it can load a resource and how. + * + * @author Fabien Potencier + */ +class LoaderResolver implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolverInterface +{ + /** + * @var LoaderInterface[] An array of LoaderInterface objects + */ + private $loaders = []; + /** + * @param LoaderInterface[] $loaders An array of loaders + */ + public function __construct(array $loaders = []) + { + foreach ($loaders as $loader) { + $this->addLoader($loader); + } + } + /** + * {@inheritdoc} + */ + public function resolve($resource, $type = null) + { + foreach ($this->loaders as $loader) { + if ($loader->supports($resource, $type)) { + return $loader; + } + } + return \false; + } + public function addLoader(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderInterface $loader) + { + $this->loaders[] = $loader; + $loader->setResolver($this); + } + /** + * Returns the registered loaders. + * + * @return LoaderInterface[] An array of LoaderInterface instances + */ + public function getLoaders() + { + return $this->loaders; + } +} diff --git a/vendor/symfony/config/Loader/LoaderResolverInterface.php b/vendor/symfony/config/Loader/LoaderResolverInterface.php index a21f4f00f..d7e6d4da6 100644 --- a/vendor/symfony/config/Loader/LoaderResolverInterface.php +++ b/vendor/symfony/config/Loader/LoaderResolverInterface.php @@ -1,29 +1,29 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; - -/** - * LoaderResolverInterface selects a loader for a given resource. - * - * @author Fabien Potencier - */ -interface LoaderResolverInterface -{ - /** - * Returns a loader able to load the resource. - * - * @param mixed $resource A resource - * @param string|null $type The resource type or null if unknown - * - * @return LoaderInterface|false The loader or false if none is able to load the resource - */ - public function resolve($resource, $type = null); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader; + +/** + * LoaderResolverInterface selects a loader for a given resource. + * + * @author Fabien Potencier + */ +interface LoaderResolverInterface +{ + /** + * Returns a loader able to load the resource. + * + * @param mixed $resource A resource + * @param string|null $type The resource type or null if unknown + * + * @return LoaderInterface|false The loader or false if none is able to load the resource + */ + public function resolve($resource, $type = null); +} diff --git a/vendor/symfony/config/Loader/index.php b/vendor/symfony/config/Loader/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Loader/index.php +++ b/vendor/symfony/config/Loader/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/README.md b/vendor/symfony/config/README.md index 0bbde5523..d09bfcba2 100644 --- a/vendor/symfony/config/README.md +++ b/vendor/symfony/config/README.md @@ -1,15 +1,15 @@ -Config Component -================ - -The Config component provides several classes to help you find, load, combine, -autofill and validate configuration values of any kind, whatever their source -may be (YAML, XML, INI files, or for instance a database). - -Resources ---------- - - * [Documentation](https://symfony.com/doc/current/components/config.html) - * [Contributing](https://symfony.com/doc/current/contributing/index.html) - * [Report issues](https://github.com/symfony/symfony/issues) and - [send Pull Requests](https://github.com/symfony/symfony/pulls) - in the [main Symfony repository](https://github.com/symfony/symfony) +Config Component +================ + +The Config component provides several classes to help you find, load, combine, +autofill and validate configuration values of any kind, whatever their source +may be (YAML, XML, INI files, or for instance a database). + +Resources +--------- + + * [Documentation](https://symfony.com/doc/current/components/config.html) + * [Contributing](https://symfony.com/doc/current/contributing/index.html) + * [Report issues](https://github.com/symfony/symfony/issues) and + [send Pull Requests](https://github.com/symfony/symfony/pulls) + in the [main Symfony repository](https://github.com/symfony/symfony) diff --git a/vendor/symfony/config/Resource/ClassExistenceResource.php b/vendor/symfony/config/Resource/ClassExistenceResource.php index e34ae271d..2979c7f2e 100644 --- a/vendor/symfony/config/Resource/ClassExistenceResource.php +++ b/vendor/symfony/config/Resource/ClassExistenceResource.php @@ -1,195 +1,195 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; - -/** - * ClassExistenceResource represents a class existence. - * Freshness is only evaluated against resource existence. - * - * The resource must be a fully-qualified class name. - * - * @author Fabien Potencier - */ -class ClassExistenceResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable -{ - private $resource; - private $exists; - private static $autoloadLevel = 0; - private static $autoloadedClass; - private static $existsCache = []; - /** - * @param string $resource The fully-qualified class name - * @param bool|null $exists Boolean when the existency check has already been done - */ - public function __construct($resource, $exists = null) - { - $this->resource = $resource; - if (null !== $exists) { - $this->exists = [(bool) $exists, null]; - } - } - /** - * {@inheritdoc} - */ - public function __toString() - { - return $this->resource; - } - /** - * @return string The file path to the resource - */ - public function getResource() - { - return $this->resource; - } - /** - * {@inheritdoc} - * - * @throws \ReflectionException when a parent class/interface/trait is not found - */ - public function isFresh($timestamp) - { - $loaded = \class_exists($this->resource, \false) || \interface_exists($this->resource, \false) || \trait_exists($this->resource, \false); - if (null !== ($exists =& self::$existsCache[$this->resource])) { - if ($loaded) { - $exists = [\true, null]; - } elseif (0 >= $timestamp && !$exists[0] && null !== $exists[1]) { - throw new \ReflectionException($exists[1]); - } - } elseif ([\false, null] === ($exists = [$loaded, null])) { - if (!self::$autoloadLevel++) { - \spl_autoload_register(__CLASS__ . '::throwOnRequiredClass'); - } - $autoloadedClass = self::$autoloadedClass; - self::$autoloadedClass = \ltrim($this->resource, '\\'); - try { - $exists[0] = \class_exists($this->resource) || \interface_exists($this->resource, \false) || \trait_exists($this->resource, \false); - } catch (\Exception $e) { - $exists[1] = $e->getMessage(); - try { - self::throwOnRequiredClass($this->resource, $e); - } catch (\ReflectionException $e) { - if (0 >= $timestamp) { - throw $e; - } - } - } catch (\Throwable $e) { - $exists[1] = $e->getMessage(); - throw $e; - } finally { - self::$autoloadedClass = $autoloadedClass; - if (!--self::$autoloadLevel) { - \spl_autoload_unregister(__CLASS__ . '::throwOnRequiredClass'); - } - } - } - if (null === $this->exists) { - $this->exists = $exists; - } - return $this->exists[0] xor !$exists[0]; - } - /** - * @internal - */ - public function serialize() - { - if (null === $this->exists) { - $this->isFresh(0); - } - return \serialize([$this->resource, $this->exists]); - } - /** - * @internal - */ - public function unserialize($serialized) - { - list($this->resource, $this->exists) = \unserialize($serialized); - if (\is_bool($this->exists)) { - $this->exists = [$this->exists, null]; - } - } - /** - * Throws a reflection exception when the passed class does not exist but is required. - * - * A class is considered "not required" when it's loaded as part of a "class_exists" or similar check. - * - * This function can be used as an autoload function to throw a reflection - * exception if the class was not found by previous autoload functions. - * - * A previous exception can be passed. In this case, the class is considered as being - * required totally, so if it doesn't exist, a reflection exception is always thrown. - * If it exists, the previous exception is rethrown. - * - * @throws \ReflectionException - * - * @internal - */ - public static function throwOnRequiredClass($class, \Exception $previous = null) - { - // If the passed class is the resource being checked, we shouldn't throw. - if (null === $previous && self::$autoloadedClass === $class) { - return; - } - if (\class_exists($class, \false) || \interface_exists($class, \false) || \trait_exists($class, \false)) { - if (null !== $previous) { - throw $previous; - } - return; - } - if ($previous instanceof \ReflectionException) { - throw $previous; - } - $message = \sprintf('Class "%s" not found.', $class); - if (self::$autoloadedClass !== $class) { - $message = \substr_replace($message, \sprintf(' while loading "%s"', self::$autoloadedClass), -1, 0); - } - if (null !== $previous) { - $message = $previous->getMessage(); - } - $e = new \ReflectionException($message, 0, $previous); - if (null !== $previous) { - throw $e; - } - $trace = \debug_backtrace(); - $autoloadFrame = ['function' => 'spl_autoload_call', 'args' => [$class]]; - if (\false === ($i = \array_search($autoloadFrame, $trace, \true))) { - throw $e; - } - if (isset($trace[++$i]['function']) && !isset($trace[$i]['class'])) { - switch ($trace[$i]['function']) { - case 'get_class_methods': - case 'get_class_vars': - case 'get_parent_class': - case 'is_a': - case 'is_subclass_of': - case 'class_exists': - case 'class_implements': - case 'class_parents': - case 'trait_exists': - case 'defined': - case 'interface_exists': - case 'method_exists': - case 'property_exists': - case 'is_callable': - return; - } - $props = ['file' => isset($trace[$i]['file']) ? $trace[$i]['file'] : null, 'line' => isset($trace[$i]['line']) ? $trace[$i]['line'] : null, 'trace' => \array_slice($trace, 1 + $i)]; - foreach ($props as $p => $v) { - if (null !== $v) { - $r = new \ReflectionProperty('Exception', $p); - $r->setAccessible(\true); - $r->setValue($e, $v); - } - } - } - throw $e; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; + +/** + * ClassExistenceResource represents a class existence. + * Freshness is only evaluated against resource existence. + * + * The resource must be a fully-qualified class name. + * + * @author Fabien Potencier + */ +class ClassExistenceResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable +{ + private $resource; + private $exists; + private static $autoloadLevel = 0; + private static $autoloadedClass; + private static $existsCache = []; + /** + * @param string $resource The fully-qualified class name + * @param bool|null $exists Boolean when the existency check has already been done + */ + public function __construct($resource, $exists = null) + { + $this->resource = $resource; + if (null !== $exists) { + $this->exists = [(bool) $exists, null]; + } + } + /** + * {@inheritdoc} + */ + public function __toString() + { + return $this->resource; + } + /** + * @return string The file path to the resource + */ + public function getResource() + { + return $this->resource; + } + /** + * {@inheritdoc} + * + * @throws \ReflectionException when a parent class/interface/trait is not found + */ + public function isFresh($timestamp) + { + $loaded = \class_exists($this->resource, \false) || \interface_exists($this->resource, \false) || \trait_exists($this->resource, \false); + if (null !== ($exists =& self::$existsCache[$this->resource])) { + if ($loaded) { + $exists = [\true, null]; + } elseif (0 >= $timestamp && !$exists[0] && null !== $exists[1]) { + throw new \ReflectionException($exists[1]); + } + } elseif ([\false, null] === ($exists = [$loaded, null])) { + if (!self::$autoloadLevel++) { + \spl_autoload_register(__CLASS__ . '::throwOnRequiredClass'); + } + $autoloadedClass = self::$autoloadedClass; + self::$autoloadedClass = \ltrim($this->resource, '\\'); + try { + $exists[0] = \class_exists($this->resource) || \interface_exists($this->resource, \false) || \trait_exists($this->resource, \false); + } catch (\Exception $e) { + $exists[1] = $e->getMessage(); + try { + self::throwOnRequiredClass($this->resource, $e); + } catch (\ReflectionException $e) { + if (0 >= $timestamp) { + throw $e; + } + } + } catch (\Throwable $e) { + $exists[1] = $e->getMessage(); + throw $e; + } finally { + self::$autoloadedClass = $autoloadedClass; + if (!--self::$autoloadLevel) { + \spl_autoload_unregister(__CLASS__ . '::throwOnRequiredClass'); + } + } + } + if (null === $this->exists) { + $this->exists = $exists; + } + return $this->exists[0] xor !$exists[0]; + } + /** + * @internal + */ + public function serialize() + { + if (null === $this->exists) { + $this->isFresh(0); + } + return \serialize([$this->resource, $this->exists]); + } + /** + * @internal + */ + public function unserialize($serialized) + { + list($this->resource, $this->exists) = \unserialize($serialized); + if (\is_bool($this->exists)) { + $this->exists = [$this->exists, null]; + } + } + /** + * Throws a reflection exception when the passed class does not exist but is required. + * + * A class is considered "not required" when it's loaded as part of a "class_exists" or similar check. + * + * This function can be used as an autoload function to throw a reflection + * exception if the class was not found by previous autoload functions. + * + * A previous exception can be passed. In this case, the class is considered as being + * required totally, so if it doesn't exist, a reflection exception is always thrown. + * If it exists, the previous exception is rethrown. + * + * @throws \ReflectionException + * + * @internal + */ + public static function throwOnRequiredClass($class, \Exception $previous = null) + { + // If the passed class is the resource being checked, we shouldn't throw. + if (null === $previous && self::$autoloadedClass === $class) { + return; + } + if (\class_exists($class, \false) || \interface_exists($class, \false) || \trait_exists($class, \false)) { + if (null !== $previous) { + throw $previous; + } + return; + } + if ($previous instanceof \ReflectionException) { + throw $previous; + } + $message = \sprintf('Class "%s" not found.', $class); + if (self::$autoloadedClass !== $class) { + $message = \substr_replace($message, \sprintf(' while loading "%s"', self::$autoloadedClass), -1, 0); + } + if (null !== $previous) { + $message = $previous->getMessage(); + } + $e = new \ReflectionException($message, 0, $previous); + if (null !== $previous) { + throw $e; + } + $trace = \debug_backtrace(); + $autoloadFrame = ['function' => 'spl_autoload_call', 'args' => [$class]]; + if (\false === ($i = \array_search($autoloadFrame, $trace, \true))) { + throw $e; + } + if (isset($trace[++$i]['function']) && !isset($trace[$i]['class'])) { + switch ($trace[$i]['function']) { + case 'get_class_methods': + case 'get_class_vars': + case 'get_parent_class': + case 'is_a': + case 'is_subclass_of': + case 'class_exists': + case 'class_implements': + case 'class_parents': + case 'trait_exists': + case 'defined': + case 'interface_exists': + case 'method_exists': + case 'property_exists': + case 'is_callable': + return; + } + $props = ['file' => isset($trace[$i]['file']) ? $trace[$i]['file'] : null, 'line' => isset($trace[$i]['line']) ? $trace[$i]['line'] : null, 'trace' => \array_slice($trace, 1 + $i)]; + foreach ($props as $p => $v) { + if (null !== $v) { + $r = new \ReflectionProperty('Exception', $p); + $r->setAccessible(\true); + $r->setValue($e, $v); + } + } + } + throw $e; + } +} diff --git a/vendor/symfony/config/Resource/ComposerResource.php b/vendor/symfony/config/Resource/ComposerResource.php index f29827dd4..3182432b8 100644 --- a/vendor/symfony/config/Resource/ComposerResource.php +++ b/vendor/symfony/config/Resource/ComposerResource.php @@ -1,73 +1,73 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; - -/** - * ComposerResource tracks the PHP version and Composer dependencies. - * - * @author Nicolas Grekas - */ -class ComposerResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable -{ - private $vendors; - private static $runtimeVendors; - public function __construct() - { - self::refresh(); - $this->vendors = self::$runtimeVendors; - } - public function getVendors() - { - return \array_keys($this->vendors); - } - /** - * {@inheritdoc} - */ - public function __toString() - { - return __CLASS__; - } - /** - * {@inheritdoc} - */ - public function isFresh($timestamp) - { - self::refresh(); - return \array_values(self::$runtimeVendors) === \array_values($this->vendors); - } - /** - * @internal - */ - public function serialize() - { - return \serialize($this->vendors); - } - /** - * @internal - */ - public function unserialize($serialized) - { - $this->vendors = \unserialize($serialized); - } - private static function refresh() - { - self::$runtimeVendors = []; - foreach (\get_declared_classes() as $class) { - if ('C' === $class[0] && 0 === \strpos($class, 'ComposerAutoloaderInit')) { - $r = new \ReflectionClass($class); - $v = \dirname(\dirname($r->getFileName())); - if (\file_exists($v . '/composer/installed.json')) { - self::$runtimeVendors[$v] = @\filemtime($v . '/composer/installed.json'); - } - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; + +/** + * ComposerResource tracks the PHP version and Composer dependencies. + * + * @author Nicolas Grekas + */ +class ComposerResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable +{ + private $vendors; + private static $runtimeVendors; + public function __construct() + { + self::refresh(); + $this->vendors = self::$runtimeVendors; + } + public function getVendors() + { + return \array_keys($this->vendors); + } + /** + * {@inheritdoc} + */ + public function __toString() + { + return __CLASS__; + } + /** + * {@inheritdoc} + */ + public function isFresh($timestamp) + { + self::refresh(); + return \array_values(self::$runtimeVendors) === \array_values($this->vendors); + } + /** + * @internal + */ + public function serialize() + { + return \serialize($this->vendors); + } + /** + * @internal + */ + public function unserialize($serialized) + { + $this->vendors = \unserialize($serialized); + } + private static function refresh() + { + self::$runtimeVendors = []; + foreach (\get_declared_classes() as $class) { + if ('C' === $class[0] && 0 === \strpos($class, 'ComposerAutoloaderInit')) { + $r = new \ReflectionClass($class); + $v = \dirname(\dirname($r->getFileName())); + if (\file_exists($v . '/composer/installed.json')) { + self::$runtimeVendors[$v] = @\filemtime($v . '/composer/installed.json'); + } + } + } + } +} diff --git a/vendor/symfony/config/Resource/DirectoryResource.php b/vendor/symfony/config/Resource/DirectoryResource.php index dbd179338..390ca30dc 100644 --- a/vendor/symfony/config/Resource/DirectoryResource.php +++ b/vendor/symfony/config/Resource/DirectoryResource.php @@ -1,107 +1,107 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; - -/** - * DirectoryResource represents a resources stored in a subdirectory tree. - * - * @author Fabien Potencier - */ -class DirectoryResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable -{ - private $resource; - private $pattern; - /** - * @param string $resource The file path to the resource - * @param string|null $pattern A pattern to restrict monitored files - * - * @throws \InvalidArgumentException - */ - public function __construct($resource, $pattern = null) - { - $this->resource = \realpath($resource) ?: (\file_exists($resource) ? $resource : \false); - $this->pattern = $pattern; - if (\false === $this->resource || !\is_dir($this->resource)) { - throw new \InvalidArgumentException(\sprintf('The directory "%s" does not exist.', $resource)); - } - } - /** - * {@inheritdoc} - */ - public function __toString() - { - return \md5(\serialize([$this->resource, $this->pattern])); - } - /** - * @return string The file path to the resource - */ - public function getResource() - { - return $this->resource; - } - /** - * Returns the pattern to restrict monitored files. - * - * @return string|null - */ - public function getPattern() - { - return $this->pattern; - } - /** - * {@inheritdoc} - */ - public function isFresh($timestamp) - { - if (!\is_dir($this->resource)) { - return \false; - } - if ($timestamp < \filemtime($this->resource)) { - return \false; - } - foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($this->resource), \RecursiveIteratorIterator::SELF_FIRST) as $file) { - // if regex filtering is enabled only check matching files - if ($this->pattern && $file->isFile() && !\preg_match($this->pattern, $file->getBasename())) { - continue; - } - // always monitor directories for changes, except the .. entries - // (otherwise deleted files wouldn't get detected) - if ($file->isDir() && '/..' === \substr($file, -3)) { - continue; - } - // for broken links - try { - $fileMTime = $file->getMTime(); - } catch (\RuntimeException $e) { - continue; - } - // early return if a file's mtime exceeds the passed timestamp - if ($timestamp < $fileMTime) { - return \false; - } - } - return \true; - } - /** - * @internal - */ - public function serialize() - { - return \serialize([$this->resource, $this->pattern]); - } - /** - * @internal - */ - public function unserialize($serialized) - { - list($this->resource, $this->pattern) = \unserialize($serialized); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; + +/** + * DirectoryResource represents a resources stored in a subdirectory tree. + * + * @author Fabien Potencier + */ +class DirectoryResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable +{ + private $resource; + private $pattern; + /** + * @param string $resource The file path to the resource + * @param string|null $pattern A pattern to restrict monitored files + * + * @throws \InvalidArgumentException + */ + public function __construct($resource, $pattern = null) + { + $this->resource = \realpath($resource) ?: (\file_exists($resource) ? $resource : \false); + $this->pattern = $pattern; + if (\false === $this->resource || !\is_dir($this->resource)) { + throw new \InvalidArgumentException(\sprintf('The directory "%s" does not exist.', $resource)); + } + } + /** + * {@inheritdoc} + */ + public function __toString() + { + return \md5(\serialize([$this->resource, $this->pattern])); + } + /** + * @return string The file path to the resource + */ + public function getResource() + { + return $this->resource; + } + /** + * Returns the pattern to restrict monitored files. + * + * @return string|null + */ + public function getPattern() + { + return $this->pattern; + } + /** + * {@inheritdoc} + */ + public function isFresh($timestamp) + { + if (!\is_dir($this->resource)) { + return \false; + } + if ($timestamp < \filemtime($this->resource)) { + return \false; + } + foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($this->resource), \RecursiveIteratorIterator::SELF_FIRST) as $file) { + // if regex filtering is enabled only check matching files + if ($this->pattern && $file->isFile() && !\preg_match($this->pattern, $file->getBasename())) { + continue; + } + // always monitor directories for changes, except the .. entries + // (otherwise deleted files wouldn't get detected) + if ($file->isDir() && '/..' === \substr($file, -3)) { + continue; + } + // for broken links + try { + $fileMTime = $file->getMTime(); + } catch (\RuntimeException $e) { + continue; + } + // early return if a file's mtime exceeds the passed timestamp + if ($timestamp < $fileMTime) { + return \false; + } + } + return \true; + } + /** + * @internal + */ + public function serialize() + { + return \serialize([$this->resource, $this->pattern]); + } + /** + * @internal + */ + public function unserialize($serialized) + { + list($this->resource, $this->pattern) = \unserialize($serialized); + } +} diff --git a/vendor/symfony/config/Resource/FileExistenceResource.php b/vendor/symfony/config/Resource/FileExistenceResource.php index dc05973ec..d16c92137 100644 --- a/vendor/symfony/config/Resource/FileExistenceResource.php +++ b/vendor/symfony/config/Resource/FileExistenceResource.php @@ -1,68 +1,68 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; - -/** - * FileExistenceResource represents a resource stored on the filesystem. - * Freshness is only evaluated against resource creation or deletion. - * - * The resource can be a file or a directory. - * - * @author Charles-Henri Bruyand - */ -class FileExistenceResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable -{ - private $resource; - private $exists; - /** - * @param string $resource The file path to the resource - */ - public function __construct($resource) - { - $this->resource = (string) $resource; - $this->exists = \file_exists($resource); - } - /** - * {@inheritdoc} - */ - public function __toString() - { - return $this->resource; - } - /** - * @return string The file path to the resource - */ - public function getResource() - { - return $this->resource; - } - /** - * {@inheritdoc} - */ - public function isFresh($timestamp) - { - return \file_exists($this->resource) === $this->exists; - } - /** - * @internal - */ - public function serialize() - { - return \serialize([$this->resource, $this->exists]); - } - /** - * @internal - */ - public function unserialize($serialized) - { - list($this->resource, $this->exists) = \unserialize($serialized); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; + +/** + * FileExistenceResource represents a resource stored on the filesystem. + * Freshness is only evaluated against resource creation or deletion. + * + * The resource can be a file or a directory. + * + * @author Charles-Henri Bruyand + */ +class FileExistenceResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable +{ + private $resource; + private $exists; + /** + * @param string $resource The file path to the resource + */ + public function __construct($resource) + { + $this->resource = (string) $resource; + $this->exists = \file_exists($resource); + } + /** + * {@inheritdoc} + */ + public function __toString() + { + return $this->resource; + } + /** + * @return string The file path to the resource + */ + public function getResource() + { + return $this->resource; + } + /** + * {@inheritdoc} + */ + public function isFresh($timestamp) + { + return \file_exists($this->resource) === $this->exists; + } + /** + * @internal + */ + public function serialize() + { + return \serialize([$this->resource, $this->exists]); + } + /** + * @internal + */ + public function unserialize($serialized) + { + list($this->resource, $this->exists) = \unserialize($serialized); + } +} diff --git a/vendor/symfony/config/Resource/FileResource.php b/vendor/symfony/config/Resource/FileResource.php index fbf04f52a..af4b903df 100644 --- a/vendor/symfony/config/Resource/FileResource.php +++ b/vendor/symfony/config/Resource/FileResource.php @@ -1,73 +1,73 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; - -/** - * FileResource represents a resource stored on the filesystem. - * - * The resource can be a file or a directory. - * - * @author Fabien Potencier - */ -class FileResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable -{ - /** - * @var string|false - */ - private $resource; - /** - * @param string $resource The file path to the resource - * - * @throws \InvalidArgumentException - */ - public function __construct($resource) - { - $this->resource = \realpath($resource) ?: (\file_exists($resource) ? $resource : \false); - if (\false === $this->resource) { - throw new \InvalidArgumentException(\sprintf('The file "%s" does not exist.', $resource)); - } - } - /** - * {@inheritdoc} - */ - public function __toString() - { - return $this->resource; - } - /** - * @return string The canonicalized, absolute path to the resource - */ - public function getResource() - { - return $this->resource; - } - /** - * {@inheritdoc} - */ - public function isFresh($timestamp) - { - return \false !== ($filemtime = @\filemtime($this->resource)) && $filemtime <= $timestamp; - } - /** - * @internal - */ - public function serialize() - { - return \serialize($this->resource); - } - /** - * @internal - */ - public function unserialize($serialized) - { - $this->resource = \unserialize($serialized); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; + +/** + * FileResource represents a resource stored on the filesystem. + * + * The resource can be a file or a directory. + * + * @author Fabien Potencier + */ +class FileResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable +{ + /** + * @var string|false + */ + private $resource; + /** + * @param string $resource The file path to the resource + * + * @throws \InvalidArgumentException + */ + public function __construct($resource) + { + $this->resource = \realpath($resource) ?: (\file_exists($resource) ? $resource : \false); + if (\false === $this->resource) { + throw new \InvalidArgumentException(\sprintf('The file "%s" does not exist.', $resource)); + } + } + /** + * {@inheritdoc} + */ + public function __toString() + { + return $this->resource; + } + /** + * @return string The canonicalized, absolute path to the resource + */ + public function getResource() + { + return $this->resource; + } + /** + * {@inheritdoc} + */ + public function isFresh($timestamp) + { + return \false !== ($filemtime = @\filemtime($this->resource)) && $filemtime <= $timestamp; + } + /** + * @internal + */ + public function serialize() + { + return \serialize($this->resource); + } + /** + * @internal + */ + public function unserialize($serialized) + { + $this->resource = \unserialize($serialized); + } +} diff --git a/vendor/symfony/config/Resource/GlobResource.php b/vendor/symfony/config/Resource/GlobResource.php index 6ba8966dc..6a7eee9a5 100644 --- a/vendor/symfony/config/Resource/GlobResource.php +++ b/vendor/symfony/config/Resource/GlobResource.php @@ -1,133 +1,133 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Finder\Finder; -use _PhpScoper5ea00cc67502b\Symfony\Component\Finder\Glob; -/** - * GlobResource represents a set of resources stored on the filesystem. - * - * Only existence/removal is tracked (not mtimes.) - * - * @author Nicolas Grekas - */ -class GlobResource implements \IteratorAggregate, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable -{ - private $prefix; - private $pattern; - private $recursive; - private $hash; - /** - * @param string $prefix A directory prefix - * @param string $pattern A glob pattern - * @param bool $recursive Whether directories should be scanned recursively or not - * - * @throws \InvalidArgumentException - */ - public function __construct($prefix, $pattern, $recursive) - { - $this->prefix = \realpath($prefix) ?: (\file_exists($prefix) ? $prefix : \false); - $this->pattern = $pattern; - $this->recursive = $recursive; - if (\false === $this->prefix) { - throw new \InvalidArgumentException(\sprintf('The path "%s" does not exist.', $prefix)); - } - } - public function getPrefix() - { - return $this->prefix; - } - /** - * {@inheritdoc} - */ - public function __toString() - { - return 'glob.' . $this->prefix . $this->pattern . (int) $this->recursive; - } - /** - * {@inheritdoc} - */ - public function isFresh($timestamp) - { - $hash = $this->computeHash(); - if (null === $this->hash) { - $this->hash = $hash; - } - return $this->hash === $hash; - } - /** - * @internal - */ - public function serialize() - { - if (null === $this->hash) { - $this->hash = $this->computeHash(); - } - return \serialize([$this->prefix, $this->pattern, $this->recursive, $this->hash]); - } - /** - * @internal - */ - public function unserialize($serialized) - { - list($this->prefix, $this->pattern, $this->recursive, $this->hash) = \unserialize($serialized); - } - public function getIterator() - { - if (!\file_exists($this->prefix) || !$this->recursive && '' === $this->pattern) { - return; - } - if (0 !== \strpos($this->prefix, 'phar://') && \false === \strpos($this->pattern, '/**/') && (\defined('GLOB_BRACE') || \false === \strpos($this->pattern, '{'))) { - $paths = \glob($this->prefix . $this->pattern, \GLOB_NOSORT | (\defined('GLOB_BRACE') ? \GLOB_BRACE : 0)); - \sort($paths); - foreach ($paths as $path) { - if ($this->recursive && \is_dir($path)) { - $files = \iterator_to_array(new \RecursiveIteratorIterator(new \RecursiveCallbackFilterIterator(new \RecursiveDirectoryIterator($path, \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::FOLLOW_SYMLINKS), function (\SplFileInfo $file) { - return '.' !== $file->getBasename()[0]; - }), \RecursiveIteratorIterator::LEAVES_ONLY)); - \uasort($files, function (\SplFileInfo $a, \SplFileInfo $b) { - return (string) $a > (string) $b ? 1 : -1; - }); - foreach ($files as $path => $info) { - if ($info->isFile()) { - (yield $path => $info); - } - } - } elseif (\is_file($path)) { - (yield $path => new \SplFileInfo($path)); - } - } - return; - } - if (!\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\Finder\Finder::class)) { - throw new \LogicException(\sprintf('Extended glob pattern "%s" cannot be used as the Finder component is not installed.', $this->pattern)); - } - $finder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Finder\Finder(); - $regex = \_PhpScoper5ea00cc67502b\Symfony\Component\Finder\Glob::toRegex($this->pattern); - if ($this->recursive) { - $regex = \substr_replace($regex, '(/|$)', -2, 1); - } - $prefixLen = \strlen($this->prefix); - foreach ($finder->followLinks()->sortByName()->in($this->prefix) as $path => $info) { - if (\preg_match($regex, \substr('\\' === \DIRECTORY_SEPARATOR ? \str_replace('\\', '/', $path) : $path, $prefixLen)) && $info->isFile()) { - (yield $path => $info); - } - } - } - private function computeHash() - { - $hash = \hash_init('md5'); - foreach ($this->getIterator() as $path => $info) { - \hash_update($hash, $path . "\n"); - } - return \hash_final($hash); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Finder\Finder; +use _PhpScoper5ea00cc67502b\Symfony\Component\Finder\Glob; +/** + * GlobResource represents a set of resources stored on the filesystem. + * + * Only existence/removal is tracked (not mtimes.) + * + * @author Nicolas Grekas + */ +class GlobResource implements \IteratorAggregate, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable +{ + private $prefix; + private $pattern; + private $recursive; + private $hash; + /** + * @param string $prefix A directory prefix + * @param string $pattern A glob pattern + * @param bool $recursive Whether directories should be scanned recursively or not + * + * @throws \InvalidArgumentException + */ + public function __construct($prefix, $pattern, $recursive) + { + $this->prefix = \realpath($prefix) ?: (\file_exists($prefix) ? $prefix : \false); + $this->pattern = $pattern; + $this->recursive = $recursive; + if (\false === $this->prefix) { + throw new \InvalidArgumentException(\sprintf('The path "%s" does not exist.', $prefix)); + } + } + public function getPrefix() + { + return $this->prefix; + } + /** + * {@inheritdoc} + */ + public function __toString() + { + return 'glob.' . $this->prefix . $this->pattern . (int) $this->recursive; + } + /** + * {@inheritdoc} + */ + public function isFresh($timestamp) + { + $hash = $this->computeHash(); + if (null === $this->hash) { + $this->hash = $hash; + } + return $this->hash === $hash; + } + /** + * @internal + */ + public function serialize() + { + if (null === $this->hash) { + $this->hash = $this->computeHash(); + } + return \serialize([$this->prefix, $this->pattern, $this->recursive, $this->hash]); + } + /** + * @internal + */ + public function unserialize($serialized) + { + list($this->prefix, $this->pattern, $this->recursive, $this->hash) = \unserialize($serialized); + } + public function getIterator() + { + if (!\file_exists($this->prefix) || !$this->recursive && '' === $this->pattern) { + return; + } + if (0 !== \strpos($this->prefix, 'phar://') && \false === \strpos($this->pattern, '/**/') && (\defined('GLOB_BRACE') || \false === \strpos($this->pattern, '{'))) { + $paths = \glob($this->prefix . $this->pattern, \GLOB_NOSORT | (\defined('GLOB_BRACE') ? \GLOB_BRACE : 0)); + \sort($paths); + foreach ($paths as $path) { + if ($this->recursive && \is_dir($path)) { + $files = \iterator_to_array(new \RecursiveIteratorIterator(new \RecursiveCallbackFilterIterator(new \RecursiveDirectoryIterator($path, \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::FOLLOW_SYMLINKS), function (\SplFileInfo $file) { + return '.' !== $file->getBasename()[0]; + }), \RecursiveIteratorIterator::LEAVES_ONLY)); + \uasort($files, function (\SplFileInfo $a, \SplFileInfo $b) { + return (string) $a > (string) $b ? 1 : -1; + }); + foreach ($files as $path => $info) { + if ($info->isFile()) { + (yield $path => $info); + } + } + } elseif (\is_file($path)) { + (yield $path => new \SplFileInfo($path)); + } + } + return; + } + if (!\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\Finder\Finder::class)) { + throw new \LogicException(\sprintf('Extended glob pattern "%s" cannot be used as the Finder component is not installed.', $this->pattern)); + } + $finder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Finder\Finder(); + $regex = \_PhpScoper5ea00cc67502b\Symfony\Component\Finder\Glob::toRegex($this->pattern); + if ($this->recursive) { + $regex = \substr_replace($regex, '(/|$)', -2, 1); + } + $prefixLen = \strlen($this->prefix); + foreach ($finder->followLinks()->sortByName()->in($this->prefix) as $path => $info) { + if (\preg_match($regex, \substr('\\' === \DIRECTORY_SEPARATOR ? \str_replace('\\', '/', $path) : $path, $prefixLen)) && $info->isFile()) { + (yield $path => $info); + } + } + } + private function computeHash() + { + $hash = \hash_init('md5'); + foreach ($this->getIterator() as $path => $info) { + \hash_update($hash, $path . "\n"); + } + return \hash_final($hash); + } +} diff --git a/vendor/symfony/config/Resource/ReflectionClassResource.php b/vendor/symfony/config/Resource/ReflectionClassResource.php index a5feb57f1..1a4e49429 100644 --- a/vendor/symfony/config/Resource/ReflectionClassResource.php +++ b/vendor/symfony/config/Resource/ReflectionClassResource.php @@ -1,204 +1,204 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface; -/** - * @author Nicolas Grekas - */ -class ReflectionClassResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable -{ - private $files = []; - private $className; - private $classReflector; - private $excludedVendors = []; - private $hash; - public function __construct(\ReflectionClass $classReflector, $excludedVendors = []) - { - $this->className = $classReflector->name; - $this->classReflector = $classReflector; - $this->excludedVendors = $excludedVendors; - } - public function isFresh($timestamp) - { - if (null === $this->hash) { - $this->hash = $this->computeHash(); - $this->loadFiles($this->classReflector); - } - foreach ($this->files as $file => $v) { - if (\false === ($filemtime = @\filemtime($file))) { - return \false; - } - if ($filemtime > $timestamp) { - return $this->hash === $this->computeHash(); - } - } - return \true; - } - public function __toString() - { - return 'reflection.' . $this->className; - } - /** - * @internal - */ - public function serialize() - { - if (null === $this->hash) { - $this->hash = $this->computeHash(); - $this->loadFiles($this->classReflector); - } - return \serialize([$this->files, $this->className, $this->hash]); - } - /** - * @internal - */ - public function unserialize($serialized) - { - list($this->files, $this->className, $this->hash) = \unserialize($serialized); - } - private function loadFiles(\ReflectionClass $class) - { - foreach ($class->getInterfaces() as $v) { - $this->loadFiles($v); - } - do { - $file = $class->getFileName(); - if (\false !== $file && \file_exists($file)) { - foreach ($this->excludedVendors as $vendor) { - if (0 === \strpos($file, $vendor) && \false !== \strpbrk(\substr($file, \strlen($vendor), 1), '/' . \DIRECTORY_SEPARATOR)) { - $file = \false; - break; - } - } - if ($file) { - $this->files[$file] = null; - } - } - foreach ($class->getTraits() as $v) { - $this->loadFiles($v); - } - } while ($class = $class->getParentClass()); - } - private function computeHash() - { - if (null === $this->classReflector) { - try { - $this->classReflector = new \ReflectionClass($this->className); - } catch (\ReflectionException $e) { - // the class does not exist anymore - return \false; - } - } - $hash = \hash_init('md5'); - foreach ($this->generateSignature($this->classReflector) as $info) { - \hash_update($hash, $info); - } - return \hash_final($hash); - } - private function generateSignature(\ReflectionClass $class) - { - (yield $class->getDocComment()); - (yield (int) $class->isFinal()); - (yield (int) $class->isAbstract()); - if ($class->isTrait()) { - (yield \print_r(\class_uses($class->name), \true)); - } else { - (yield \print_r(\class_parents($class->name), \true)); - (yield \print_r(\class_implements($class->name), \true)); - (yield \print_r($class->getConstants(), \true)); - } - if (!$class->isInterface()) { - $defaults = $class->getDefaultProperties(); - foreach ($class->getProperties(\ReflectionProperty::IS_PUBLIC | \ReflectionProperty::IS_PROTECTED) as $p) { - (yield $p->getDocComment() . $p); - (yield \print_r(isset($defaults[$p->name]) && !\is_object($defaults[$p->name]) ? $defaults[$p->name] : null, \true)); - } - } - if (\defined('HHVM_VERSION')) { - foreach ($class->getMethods(\ReflectionMethod::IS_PUBLIC | \ReflectionMethod::IS_PROTECTED) as $m) { - // workaround HHVM bug with variadics, see https://github.com/facebook/hhvm/issues/5762 - (yield \preg_replace('/^ @@.*/m', '', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionMethodHhvmWrapper($m->class, $m->name))); - } - } else { - foreach ($class->getMethods(\ReflectionMethod::IS_PUBLIC | \ReflectionMethod::IS_PROTECTED) as $m) { - $defaults = []; - $parametersWithUndefinedConstants = []; - foreach ($m->getParameters() as $p) { - if (!$p->isDefaultValueAvailable()) { - $defaults[$p->name] = null; - continue; - } - if (!$p->isDefaultValueConstant() || \defined($p->getDefaultValueConstantName())) { - $defaults[$p->name] = $p->getDefaultValue(); - continue; - } - $defaults[$p->name] = $p->getDefaultValueConstantName(); - $parametersWithUndefinedConstants[$p->name] = \true; - } - if (!$parametersWithUndefinedConstants) { - (yield \preg_replace('/^ @@.*/m', '', $m)); - } else { - $stack = [$m->getDocComment(), $m->getName(), $m->isAbstract(), $m->isFinal(), $m->isStatic(), $m->isPublic(), $m->isPrivate(), $m->isProtected(), $m->returnsReference(), \PHP_VERSION_ID >= 70000 && $m->hasReturnType() ? \PHP_VERSION_ID >= 70100 ? $m->getReturnType()->getName() : (string) $m->getReturnType() : '']; - foreach ($m->getParameters() as $p) { - if (!isset($parametersWithUndefinedConstants[$p->name])) { - $stack[] = (string) $p; - } else { - $stack[] = $p->isOptional(); - $stack[] = \PHP_VERSION_ID >= 70000 && $p->hasType() ? \PHP_VERSION_ID >= 70100 ? $p->getType()->getName() : (string) $p->getType() : ''; - $stack[] = $p->isPassedByReference(); - $stack[] = \PHP_VERSION_ID >= 50600 ? $p->isVariadic() : ''; - $stack[] = $p->getName(); - } - } - (yield \implode(',', $stack)); - } - (yield \print_r($defaults, \true)); - } - } - if ($class->isAbstract() || $class->isInterface() || $class->isTrait()) { - return; - } - if (\interface_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface::class, \false) && $class->isSubclassOf(\_PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface::class)) { - (yield \_PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface::class); - (yield \print_r(\call_user_func([$class->name, 'getSubscribedEvents']), \true)); - } - if (\interface_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class, \false) && $class->isSubclassOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class)) { - (yield \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class); - (yield \print_r(\call_user_func([$class->name, 'getSubscribedServices']), \true)); - } - } -} -/** - * @internal - */ -class ReflectionMethodHhvmWrapper extends \ReflectionMethod -{ - public function getParameters() - { - $params = []; - foreach (parent::getParameters() as $i => $p) { - $params[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionParameterHhvmWrapper([$this->class, $this->name], $i); - } - return $params; - } -} -/** - * @internal - */ -class ReflectionParameterHhvmWrapper extends \ReflectionParameter -{ - public function getDefaultValue() - { - return [$this->isVariadic(), $this->isDefaultValueAvailable() ? parent::getDefaultValue() : null]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface; +/** + * @author Nicolas Grekas + */ +class ReflectionClassResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable +{ + private $files = []; + private $className; + private $classReflector; + private $excludedVendors = []; + private $hash; + public function __construct(\ReflectionClass $classReflector, $excludedVendors = []) + { + $this->className = $classReflector->name; + $this->classReflector = $classReflector; + $this->excludedVendors = $excludedVendors; + } + public function isFresh($timestamp) + { + if (null === $this->hash) { + $this->hash = $this->computeHash(); + $this->loadFiles($this->classReflector); + } + foreach ($this->files as $file => $v) { + if (\false === ($filemtime = @\filemtime($file))) { + return \false; + } + if ($filemtime > $timestamp) { + return $this->hash === $this->computeHash(); + } + } + return \true; + } + public function __toString() + { + return 'reflection.' . $this->className; + } + /** + * @internal + */ + public function serialize() + { + if (null === $this->hash) { + $this->hash = $this->computeHash(); + $this->loadFiles($this->classReflector); + } + return \serialize([$this->files, $this->className, $this->hash]); + } + /** + * @internal + */ + public function unserialize($serialized) + { + list($this->files, $this->className, $this->hash) = \unserialize($serialized); + } + private function loadFiles(\ReflectionClass $class) + { + foreach ($class->getInterfaces() as $v) { + $this->loadFiles($v); + } + do { + $file = $class->getFileName(); + if (\false !== $file && \file_exists($file)) { + foreach ($this->excludedVendors as $vendor) { + if (0 === \strpos($file, $vendor) && \false !== \strpbrk(\substr($file, \strlen($vendor), 1), '/' . \DIRECTORY_SEPARATOR)) { + $file = \false; + break; + } + } + if ($file) { + $this->files[$file] = null; + } + } + foreach ($class->getTraits() as $v) { + $this->loadFiles($v); + } + } while ($class = $class->getParentClass()); + } + private function computeHash() + { + if (null === $this->classReflector) { + try { + $this->classReflector = new \ReflectionClass($this->className); + } catch (\ReflectionException $e) { + // the class does not exist anymore + return \false; + } + } + $hash = \hash_init('md5'); + foreach ($this->generateSignature($this->classReflector) as $info) { + \hash_update($hash, $info); + } + return \hash_final($hash); + } + private function generateSignature(\ReflectionClass $class) + { + (yield $class->getDocComment()); + (yield (int) $class->isFinal()); + (yield (int) $class->isAbstract()); + if ($class->isTrait()) { + (yield \print_r(\class_uses($class->name), \true)); + } else { + (yield \print_r(\class_parents($class->name), \true)); + (yield \print_r(\class_implements($class->name), \true)); + (yield \print_r($class->getConstants(), \true)); + } + if (!$class->isInterface()) { + $defaults = $class->getDefaultProperties(); + foreach ($class->getProperties(\ReflectionProperty::IS_PUBLIC | \ReflectionProperty::IS_PROTECTED) as $p) { + (yield $p->getDocComment() . $p); + (yield \print_r(isset($defaults[$p->name]) && !\is_object($defaults[$p->name]) ? $defaults[$p->name] : null, \true)); + } + } + if (\defined('HHVM_VERSION')) { + foreach ($class->getMethods(\ReflectionMethod::IS_PUBLIC | \ReflectionMethod::IS_PROTECTED) as $m) { + // workaround HHVM bug with variadics, see https://github.com/facebook/hhvm/issues/5762 + (yield \preg_replace('/^ @@.*/m', '', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionMethodHhvmWrapper($m->class, $m->name))); + } + } else { + foreach ($class->getMethods(\ReflectionMethod::IS_PUBLIC | \ReflectionMethod::IS_PROTECTED) as $m) { + $defaults = []; + $parametersWithUndefinedConstants = []; + foreach ($m->getParameters() as $p) { + if (!$p->isDefaultValueAvailable()) { + $defaults[$p->name] = null; + continue; + } + if (!$p->isDefaultValueConstant() || \defined($p->getDefaultValueConstantName())) { + $defaults[$p->name] = $p->getDefaultValue(); + continue; + } + $defaults[$p->name] = $p->getDefaultValueConstantName(); + $parametersWithUndefinedConstants[$p->name] = \true; + } + if (!$parametersWithUndefinedConstants) { + (yield \preg_replace('/^ @@.*/m', '', $m)); + } else { + $stack = [$m->getDocComment(), $m->getName(), $m->isAbstract(), $m->isFinal(), $m->isStatic(), $m->isPublic(), $m->isPrivate(), $m->isProtected(), $m->returnsReference(), \PHP_VERSION_ID >= 70000 && $m->hasReturnType() ? \PHP_VERSION_ID >= 70100 ? $m->getReturnType()->getName() : (string) $m->getReturnType() : '']; + foreach ($m->getParameters() as $p) { + if (!isset($parametersWithUndefinedConstants[$p->name])) { + $stack[] = (string) $p; + } else { + $stack[] = $p->isOptional(); + $stack[] = \PHP_VERSION_ID >= 70000 && $p->hasType() ? \PHP_VERSION_ID >= 70100 ? $p->getType()->getName() : (string) $p->getType() : ''; + $stack[] = $p->isPassedByReference(); + $stack[] = \PHP_VERSION_ID >= 50600 ? $p->isVariadic() : ''; + $stack[] = $p->getName(); + } + } + (yield \implode(',', $stack)); + } + (yield \print_r($defaults, \true)); + } + } + if ($class->isAbstract() || $class->isInterface() || $class->isTrait()) { + return; + } + if (\interface_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface::class, \false) && $class->isSubclassOf(\_PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface::class)) { + (yield \_PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface::class); + (yield \print_r(\call_user_func([$class->name, 'getSubscribedEvents']), \true)); + } + if (\interface_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class, \false) && $class->isSubclassOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class)) { + (yield \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class); + (yield \print_r(\call_user_func([$class->name, 'getSubscribedServices']), \true)); + } + } +} +/** + * @internal + */ +class ReflectionMethodHhvmWrapper extends \ReflectionMethod +{ + public function getParameters() + { + $params = []; + foreach (parent::getParameters() as $i => $p) { + $params[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionParameterHhvmWrapper([$this->class, $this->name], $i); + } + return $params; + } +} +/** + * @internal + */ +class ReflectionParameterHhvmWrapper extends \ReflectionParameter +{ + public function getDefaultValue() + { + return [$this->isVariadic(), $this->isDefaultValueAvailable() ? parent::getDefaultValue() : null]; + } +} diff --git a/vendor/symfony/config/Resource/ResourceInterface.php b/vendor/symfony/config/Resource/ResourceInterface.php index 079333c3e..f24b2622c 100644 --- a/vendor/symfony/config/Resource/ResourceInterface.php +++ b/vendor/symfony/config/Resource/ResourceInterface.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; - -/** - * ResourceInterface is the interface that must be implemented by all Resource classes. - * - * @author Fabien Potencier - */ -interface ResourceInterface -{ - /** - * Returns a string representation of the Resource. - * - * This method is necessary to allow for resource de-duplication, for example by means - * of array_unique(). The string returned need not have a particular meaning, but has - * to be identical for different ResourceInterface instances referring to the same - * resource; and it should be unlikely to collide with that of other, unrelated - * resource instances. - * - * @return string A string representation unique to the underlying Resource - */ - public function __toString(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; + +/** + * ResourceInterface is the interface that must be implemented by all Resource classes. + * + * @author Fabien Potencier + */ +interface ResourceInterface +{ + /** + * Returns a string representation of the Resource. + * + * This method is necessary to allow for resource de-duplication, for example by means + * of array_unique(). The string returned need not have a particular meaning, but has + * to be identical for different ResourceInterface instances referring to the same + * resource; and it should be unlikely to collide with that of other, unrelated + * resource instances. + * + * @return string A string representation unique to the underlying Resource + */ + public function __toString(); +} diff --git a/vendor/symfony/config/Resource/SelfCheckingResourceChecker.php b/vendor/symfony/config/Resource/SelfCheckingResourceChecker.php index 11c6b0c57..6006404ab 100644 --- a/vendor/symfony/config/Resource/SelfCheckingResourceChecker.php +++ b/vendor/symfony/config/Resource/SelfCheckingResourceChecker.php @@ -1,33 +1,33 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerInterface; -/** - * Resource checker for instances of SelfCheckingResourceInterface. - * - * As these resources perform the actual check themselves, we can provide - * this class as a standard way of validating them. - * - * @author Matthias Pigulla - */ -class SelfCheckingResourceChecker implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerInterface -{ - public function supports(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $metadata) - { - return $metadata instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface; - } - public function isFresh(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $resource, $timestamp) - { - /* @var SelfCheckingResourceInterface $resource */ - return $resource->isFresh($timestamp); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerInterface; +/** + * Resource checker for instances of SelfCheckingResourceInterface. + * + * As these resources perform the actual check themselves, we can provide + * this class as a standard way of validating them. + * + * @author Matthias Pigulla + */ +class SelfCheckingResourceChecker implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerInterface +{ + public function supports(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $metadata) + { + return $metadata instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface; + } + public function isFresh(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $resource, $timestamp) + { + /* @var SelfCheckingResourceInterface $resource */ + return $resource->isFresh($timestamp); + } +} diff --git a/vendor/symfony/config/Resource/SelfCheckingResourceInterface.php b/vendor/symfony/config/Resource/SelfCheckingResourceInterface.php index 488e1d268..2cbe29626 100644 --- a/vendor/symfony/config/Resource/SelfCheckingResourceInterface.php +++ b/vendor/symfony/config/Resource/SelfCheckingResourceInterface.php @@ -1,29 +1,29 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; - -/** - * Interface for Resources that can check for freshness autonomously, - * without special support from external services. - * - * @author Matthias Pigulla - */ -interface SelfCheckingResourceInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface -{ - /** - * Returns true if the resource has not been updated since the given timestamp. - * - * @param int $timestamp The last time the resource was loaded - * - * @return bool True if the resource has not been updated, false otherwise - */ - public function isFresh($timestamp); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource; + +/** + * Interface for Resources that can check for freshness autonomously, + * without special support from external services. + * + * @author Matthias Pigulla + */ +interface SelfCheckingResourceInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface +{ + /** + * Returns true if the resource has not been updated since the given timestamp. + * + * @param int $timestamp The last time the resource was loaded + * + * @return bool True if the resource has not been updated, false otherwise + */ + public function isFresh($timestamp); +} diff --git a/vendor/symfony/config/Resource/index.php b/vendor/symfony/config/Resource/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Resource/index.php +++ b/vendor/symfony/config/Resource/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/ResourceCheckerConfigCache.php b/vendor/symfony/config/ResourceCheckerConfigCache.php index 76a3124a8..94d0f3c93 100644 --- a/vendor/symfony/config/ResourceCheckerConfigCache.php +++ b/vendor/symfony/config/ResourceCheckerConfigCache.php @@ -1,163 +1,163 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem; -/** - * ResourceCheckerConfigCache uses instances of ResourceCheckerInterface - * to check whether cached data is still fresh. - * - * @author Matthias Pigulla - */ -class ResourceCheckerConfigCache implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCacheInterface -{ - /** - * @var string - */ - private $file; - /** - * @var iterable|ResourceCheckerInterface[] - */ - private $resourceCheckers; - /** - * @param string $file The absolute cache path - * @param iterable|ResourceCheckerInterface[] $resourceCheckers The ResourceCheckers to use for the freshness check - */ - public function __construct($file, $resourceCheckers = []) - { - $this->file = $file; - $this->resourceCheckers = $resourceCheckers; - } - /** - * {@inheritdoc} - */ - public function getPath() - { - return $this->file; - } - /** - * Checks if the cache is still fresh. - * - * This implementation will make a decision solely based on the ResourceCheckers - * passed in the constructor. - * - * The first ResourceChecker that supports a given resource is considered authoritative. - * Resources with no matching ResourceChecker will silently be ignored and considered fresh. - * - * @return bool true if the cache is fresh, false otherwise - */ - public function isFresh() - { - if (!\is_file($this->file)) { - return \false; - } - if ($this->resourceCheckers instanceof \Traversable && !$this->resourceCheckers instanceof \Countable) { - $this->resourceCheckers = \iterator_to_array($this->resourceCheckers); - } - if (!\count($this->resourceCheckers)) { - return \true; - // shortcut - if we don't have any checkers we don't need to bother with the meta file at all - } - $metadata = $this->getMetaFile(); - if (!\is_file($metadata)) { - return \false; - } - $meta = $this->safelyUnserialize($metadata); - if (\false === $meta) { - return \false; - } - $time = \filemtime($this->file); - foreach ($meta as $resource) { - /* @var ResourceInterface $resource */ - foreach ($this->resourceCheckers as $checker) { - if (!$checker->supports($resource)) { - continue; - // next checker - } - if ($checker->isFresh($resource, $time)) { - break; - // no need to further check this resource - } - return \false; - // cache is stale - } - // no suitable checker found, ignore this resource - } - return \true; - } - /** - * Writes cache. - * - * @param string $content The content to write in the cache - * @param ResourceInterface[] $metadata An array of metadata - * - * @throws \RuntimeException When cache file can't be written - */ - public function write($content, array $metadata = null) - { - $mode = 0666; - $umask = \umask(); - $filesystem = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem(); - $filesystem->dumpFile($this->file, $content); - try { - $filesystem->chmod($this->file, $mode, $umask); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException $e) { - // discard chmod failure (some filesystem may not support it) - } - if (null !== $metadata) { - $filesystem->dumpFile($this->getMetaFile(), \serialize($metadata)); - try { - $filesystem->chmod($this->getMetaFile(), $mode, $umask); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException $e) { - // discard chmod failure (some filesystem may not support it) - } - } - if (\function_exists('opcache_invalidate') && \filter_var(\ini_get('opcache.enable'), \FILTER_VALIDATE_BOOLEAN)) { - @\opcache_invalidate($this->file, \true); - } - } - /** - * Gets the meta file path. - * - * @return string The meta file path - */ - private function getMetaFile() - { - return $this->file . '.meta'; - } - private function safelyUnserialize($file) - { - $e = null; - $meta = \false; - $content = \file_get_contents($file); - $signalingException = new \UnexpectedValueException(); - $prevUnserializeHandler = \ini_set('unserialize_callback_func', ''); - $prevErrorHandler = \set_error_handler(function ($type, $msg, $file, $line, $context = []) use(&$prevErrorHandler, $signalingException) { - if (__FILE__ === $file) { - throw $signalingException; - } - return $prevErrorHandler ? $prevErrorHandler($type, $msg, $file, $line, $context) : \false; - }); - try { - $meta = \unserialize($content); - } catch (\Error $e) { - } catch (\Exception $e) { - } - \restore_error_handler(); - \ini_set('unserialize_callback_func', $prevUnserializeHandler); - if (null !== $e && $e !== $signalingException) { - throw $e; - } - return $meta; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem; +/** + * ResourceCheckerConfigCache uses instances of ResourceCheckerInterface + * to check whether cached data is still fresh. + * + * @author Matthias Pigulla + */ +class ResourceCheckerConfigCache implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCacheInterface +{ + /** + * @var string + */ + private $file; + /** + * @var iterable|ResourceCheckerInterface[] + */ + private $resourceCheckers; + /** + * @param string $file The absolute cache path + * @param iterable|ResourceCheckerInterface[] $resourceCheckers The ResourceCheckers to use for the freshness check + */ + public function __construct($file, $resourceCheckers = []) + { + $this->file = $file; + $this->resourceCheckers = $resourceCheckers; + } + /** + * {@inheritdoc} + */ + public function getPath() + { + return $this->file; + } + /** + * Checks if the cache is still fresh. + * + * This implementation will make a decision solely based on the ResourceCheckers + * passed in the constructor. + * + * The first ResourceChecker that supports a given resource is considered authoritative. + * Resources with no matching ResourceChecker will silently be ignored and considered fresh. + * + * @return bool true if the cache is fresh, false otherwise + */ + public function isFresh() + { + if (!\is_file($this->file)) { + return \false; + } + if ($this->resourceCheckers instanceof \Traversable && !$this->resourceCheckers instanceof \Countable) { + $this->resourceCheckers = \iterator_to_array($this->resourceCheckers); + } + if (!\count($this->resourceCheckers)) { + return \true; + // shortcut - if we don't have any checkers we don't need to bother with the meta file at all + } + $metadata = $this->getMetaFile(); + if (!\is_file($metadata)) { + return \false; + } + $meta = $this->safelyUnserialize($metadata); + if (\false === $meta) { + return \false; + } + $time = \filemtime($this->file); + foreach ($meta as $resource) { + /* @var ResourceInterface $resource */ + foreach ($this->resourceCheckers as $checker) { + if (!$checker->supports($resource)) { + continue; + // next checker + } + if ($checker->isFresh($resource, $time)) { + break; + // no need to further check this resource + } + return \false; + // cache is stale + } + // no suitable checker found, ignore this resource + } + return \true; + } + /** + * Writes cache. + * + * @param string $content The content to write in the cache + * @param ResourceInterface[] $metadata An array of metadata + * + * @throws \RuntimeException When cache file can't be written + */ + public function write($content, array $metadata = null) + { + $mode = 0666; + $umask = \umask(); + $filesystem = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem(); + $filesystem->dumpFile($this->file, $content); + try { + $filesystem->chmod($this->file, $mode, $umask); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException $e) { + // discard chmod failure (some filesystem may not support it) + } + if (null !== $metadata) { + $filesystem->dumpFile($this->getMetaFile(), \serialize($metadata)); + try { + $filesystem->chmod($this->getMetaFile(), $mode, $umask); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException $e) { + // discard chmod failure (some filesystem may not support it) + } + } + if (\function_exists('opcache_invalidate') && \filter_var(\ini_get('opcache.enable'), \FILTER_VALIDATE_BOOLEAN)) { + @\opcache_invalidate($this->file, \true); + } + } + /** + * Gets the meta file path. + * + * @return string The meta file path + */ + private function getMetaFile() + { + return $this->file . '.meta'; + } + private function safelyUnserialize($file) + { + $e = null; + $meta = \false; + $content = \file_get_contents($file); + $signalingException = new \UnexpectedValueException(); + $prevUnserializeHandler = \ini_set('unserialize_callback_func', ''); + $prevErrorHandler = \set_error_handler(function ($type, $msg, $file, $line, $context = []) use(&$prevErrorHandler, $signalingException) { + if (__FILE__ === $file) { + throw $signalingException; + } + return $prevErrorHandler ? $prevErrorHandler($type, $msg, $file, $line, $context) : \false; + }); + try { + $meta = \unserialize($content); + } catch (\Error $e) { + } catch (\Exception $e) { + } + \restore_error_handler(); + \ini_set('unserialize_callback_func', $prevUnserializeHandler); + if (null !== $e && $e !== $signalingException) { + throw $e; + } + return $meta; + } +} diff --git a/vendor/symfony/config/ResourceCheckerConfigCacheFactory.php b/vendor/symfony/config/ResourceCheckerConfigCacheFactory.php index 9c4bfb1e2..d1c4f5e49 100644 --- a/vendor/symfony/config/ResourceCheckerConfigCacheFactory.php +++ b/vendor/symfony/config/ResourceCheckerConfigCacheFactory.php @@ -1,43 +1,43 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; - -/** - * A ConfigCacheFactory implementation that validates the - * cache with an arbitrary set of ResourceCheckers. - * - * @author Matthias Pigulla - */ -class ResourceCheckerConfigCacheFactory implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCacheFactoryInterface -{ - private $resourceCheckers = []; - /** - * @param iterable|ResourceCheckerInterface[] $resourceCheckers - */ - public function __construct($resourceCheckers = []) - { - $this->resourceCheckers = $resourceCheckers; - } - /** - * {@inheritdoc} - */ - public function cache($file, $callback) - { - if (!\is_callable($callback)) { - throw new \InvalidArgumentException(\sprintf('Invalid type for callback argument. Expected callable, but got "%s".', \gettype($callback))); - } - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($file, $this->resourceCheckers); - if (!$cache->isFresh()) { - \call_user_func($callback, $cache); - } - return $cache; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; + +/** + * A ConfigCacheFactory implementation that validates the + * cache with an arbitrary set of ResourceCheckers. + * + * @author Matthias Pigulla + */ +class ResourceCheckerConfigCacheFactory implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCacheFactoryInterface +{ + private $resourceCheckers = []; + /** + * @param iterable|ResourceCheckerInterface[] $resourceCheckers + */ + public function __construct($resourceCheckers = []) + { + $this->resourceCheckers = $resourceCheckers; + } + /** + * {@inheritdoc} + */ + public function cache($file, $callback) + { + if (!\is_callable($callback)) { + throw new \InvalidArgumentException(\sprintf('Invalid type for callback argument. Expected callable, but got "%s".', \gettype($callback))); + } + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($file, $this->resourceCheckers); + if (!$cache->isFresh()) { + \call_user_func($callback, $cache); + } + return $cache; + } +} diff --git a/vendor/symfony/config/ResourceCheckerInterface.php b/vendor/symfony/config/ResourceCheckerInterface.php index 2d31a6ebf..bd9c6e389 100644 --- a/vendor/symfony/config/ResourceCheckerInterface.php +++ b/vendor/symfony/config/ResourceCheckerInterface.php @@ -1,45 +1,45 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; -/** - * Interface for ResourceCheckers. - * - * When a ResourceCheckerConfigCache instance is checked for freshness, all its associated - * metadata resources are passed to ResourceCheckers. The ResourceCheckers - * can then inspect the resources and decide whether the cache can be considered - * fresh or not. - * - * @author Matthias Pigulla - * @author Benjamin Klotz - */ -interface ResourceCheckerInterface -{ - /** - * Queries the ResourceChecker whether it can validate a given - * resource or not. - * - * @param ResourceInterface $metadata The resource to be checked for freshness - * - * @return bool True if the ResourceChecker can handle this resource type, false if not - */ - public function supports(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $metadata); - /** - * Validates the resource. - * - * @param ResourceInterface $resource The resource to be validated - * @param int $timestamp The timestamp at which the cache associated with this resource was created - * - * @return bool True if the resource has not changed since the given timestamp, false otherwise - */ - public function isFresh(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $resource, $timestamp); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; +/** + * Interface for ResourceCheckers. + * + * When a ResourceCheckerConfigCache instance is checked for freshness, all its associated + * metadata resources are passed to ResourceCheckers. The ResourceCheckers + * can then inspect the resources and decide whether the cache can be considered + * fresh or not. + * + * @author Matthias Pigulla + * @author Benjamin Klotz + */ +interface ResourceCheckerInterface +{ + /** + * Queries the ResourceChecker whether it can validate a given + * resource or not. + * + * @param ResourceInterface $metadata The resource to be checked for freshness + * + * @return bool True if the ResourceChecker can handle this resource type, false if not + */ + public function supports(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $metadata); + /** + * Validates the resource. + * + * @param ResourceInterface $resource The resource to be validated + * @param int $timestamp The timestamp at which the cache associated with this resource was created + * + * @return bool True if the resource has not changed since the given timestamp, false otherwise + */ + public function isFresh(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $resource, $timestamp); +} diff --git a/vendor/symfony/config/Tests/ConfigCacheFactoryTest.php b/vendor/symfony/config/Tests/ConfigCacheFactoryTest.php index d64b27ed0..d5861d415 100644 --- a/vendor/symfony/config/Tests/ConfigCacheFactoryTest.php +++ b/vendor/symfony/config/Tests/ConfigCacheFactoryTest.php @@ -1,24 +1,24 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCacheFactory; -class ConfigCacheFactoryTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testCacheWithInvalidCallback() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('Invalid type for callback argument. Expected callable, but got "object".'); - $cacheFactory = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCacheFactory(\true); - $cacheFactory->cache('file', new \stdClass()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCacheFactory; +class ConfigCacheFactoryTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testCacheWithInvalidCallback() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('Invalid type for callback argument. Expected callable, but got "object".'); + $cacheFactory = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCacheFactory(\true); + $cacheFactory->cache('file', new \stdClass()); + } +} diff --git a/vendor/symfony/config/Tests/ConfigCacheTest.php b/vendor/symfony/config/Tests/ConfigCacheTest.php index b51526bf3..905b4bf88 100644 --- a/vendor/symfony/config/Tests/ConfigCacheTest.php +++ b/vendor/symfony/config/Tests/ConfigCacheTest.php @@ -1,79 +1,79 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub; -class ConfigCacheTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - private $cacheFile = null; - protected function setUp() - { - $this->cacheFile = \tempnam(\sys_get_temp_dir(), 'config_'); - } - protected function tearDown() - { - $files = [$this->cacheFile, $this->cacheFile . '.meta']; - foreach ($files as $file) { - if (\file_exists($file)) { - \unlink($file); - } - } - } - /** - * @dataProvider debugModes - */ - public function testCacheIsNotValidIfNothingHasBeenCached($debug) - { - \unlink($this->cacheFile); - // remove tempnam() side effect - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($this->cacheFile, $debug); - $this->assertFalse($cache->isFresh()); - } - public function testIsAlwaysFreshInProduction() - { - $staleResource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub(); - $staleResource->setFresh(\false); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($this->cacheFile, \false); - $cache->write('', [$staleResource]); - $this->assertTrue($cache->isFresh()); - } - /** - * @dataProvider debugModes - */ - public function testIsFreshWhenNoResourceProvided($debug) - { - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($this->cacheFile, $debug); - $cache->write('', []); - $this->assertTrue($cache->isFresh()); - } - public function testFreshResourceInDebug() - { - $freshResource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub(); - $freshResource->setFresh(\true); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($this->cacheFile, \true); - $cache->write('', [$freshResource]); - $this->assertTrue($cache->isFresh()); - } - public function testStaleResourceInDebug() - { - $staleResource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub(); - $staleResource->setFresh(\false); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($this->cacheFile, \true); - $cache->write('', [$staleResource]); - $this->assertFalse($cache->isFresh()); - } - public function debugModes() - { - return [[\true], [\false]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub; +class ConfigCacheTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + private $cacheFile = null; + protected function setUp() + { + $this->cacheFile = \tempnam(\sys_get_temp_dir(), 'config_'); + } + protected function tearDown() + { + $files = [$this->cacheFile, $this->cacheFile . '.meta']; + foreach ($files as $file) { + if (\file_exists($file)) { + \unlink($file); + } + } + } + /** + * @dataProvider debugModes + */ + public function testCacheIsNotValidIfNothingHasBeenCached($debug) + { + \unlink($this->cacheFile); + // remove tempnam() side effect + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($this->cacheFile, $debug); + $this->assertFalse($cache->isFresh()); + } + public function testIsAlwaysFreshInProduction() + { + $staleResource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub(); + $staleResource->setFresh(\false); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($this->cacheFile, \false); + $cache->write('', [$staleResource]); + $this->assertTrue($cache->isFresh()); + } + /** + * @dataProvider debugModes + */ + public function testIsFreshWhenNoResourceProvided($debug) + { + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($this->cacheFile, $debug); + $cache->write('', []); + $this->assertTrue($cache->isFresh()); + } + public function testFreshResourceInDebug() + { + $freshResource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub(); + $freshResource->setFresh(\true); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($this->cacheFile, \true); + $cache->write('', [$freshResource]); + $this->assertTrue($cache->isFresh()); + } + public function testStaleResourceInDebug() + { + $staleResource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub(); + $staleResource->setFresh(\false); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ConfigCache($this->cacheFile, \true); + $cache->write('', [$staleResource]); + $this->assertFalse($cache->isFresh()); + } + public function debugModes() + { + return [[\true], [\false]]; + } +} diff --git a/vendor/symfony/config/Tests/Definition/ArrayNodeTest.php b/vendor/symfony/config/Tests/Definition/ArrayNodeTest.php index aba5d853e..563629397 100644 --- a/vendor/symfony/config/Tests/Definition/ArrayNodeTest.php +++ b/vendor/symfony/config/Tests/Definition/ArrayNodeTest.php @@ -1,156 +1,156 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode; -class ArrayNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testNormalizeThrowsExceptionWhenFalseIsNotAllowed() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); - $node->normalize(\false); - } - public function testExceptionThrownOnUnrecognizedChild() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); - $this->expectExceptionMessage('Unrecognized option "foo" under "root"'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); - $node->normalize(['foo' => 'bar']); - } - public function ignoreAndRemoveMatrixProvider() - { - $unrecognizedOptionException = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException('Unrecognized option "foo" under "root"'); - return [[\true, \true, [], 'no exception is thrown for an unrecognized child if the ignoreExtraKeys option is set to true'], [\true, \false, ['foo' => 'bar'], 'extra keys are not removed when ignoreExtraKeys second option is set to false'], [\false, \true, $unrecognizedOptionException], [\false, \false, $unrecognizedOptionException]]; - } - /** - * @dataProvider ignoreAndRemoveMatrixProvider - */ - public function testIgnoreAndRemoveBehaviors($ignore, $remove, $expected, $message = '') - { - if ($expected instanceof \Exception) { - $this->expectException(\get_class($expected)); - $this->expectExceptionMessage($expected->getMessage()); - } - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); - $node->setIgnoreExtraKeys($ignore, $remove); - $result = $node->normalize(['foo' => 'bar']); - $this->assertSame($expected, $result, $message); - } - /** - * @dataProvider getPreNormalizationTests - */ - public function testPreNormalize($denormalized, $normalized) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); - $r = new \ReflectionMethod($node, 'preNormalize'); - $r->setAccessible(\true); - $this->assertSame($normalized, $r->invoke($node, $denormalized)); - } - public function getPreNormalizationTests() - { - return [[['foo-bar' => 'foo'], ['foo_bar' => 'foo']], [['foo-bar_moo' => 'foo'], ['foo-bar_moo' => 'foo']], [['anything-with-dash-and-no-underscore' => 'first', 'no_dash' => 'second'], ['anything_with_dash_and_no_underscore' => 'first', 'no_dash' => 'second']], [['foo-bar' => null, 'foo_bar' => 'foo'], ['foo-bar' => null, 'foo_bar' => 'foo']]]; - } - /** - * @dataProvider getZeroNamedNodeExamplesData - */ - public function testNodeNameCanBeZero($denormalized, $normalized) - { - $zeroNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(0); - $zeroNode->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('name')); - $fiveNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(5); - $fiveNode->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode(0)); - $fiveNode->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('new_key')); - $rootNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); - $rootNode->addChild($zeroNode); - $rootNode->addChild($fiveNode); - $rootNode->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('string_key')); - $r = new \ReflectionMethod($rootNode, 'normalizeValue'); - $r->setAccessible(\true); - $this->assertSame($normalized, $r->invoke($rootNode, $denormalized)); - } - public function getZeroNamedNodeExamplesData() - { - return [[[0 => ['name' => 'something'], 5 => [0 => 'this won\'t work too', 'new_key' => 'some other value'], 'string_key' => 'just value'], [0 => ['name' => 'something'], 5 => [0 => 'this won\'t work too', 'new_key' => 'some other value'], 'string_key' => 'just value']]]; - } - /** - * @dataProvider getPreNormalizedNormalizedOrderedData - */ - public function testChildrenOrderIsMaintainedOnNormalizeValue($prenormalized, $normalized) - { - $scalar1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('1'); - $scalar2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('2'); - $scalar3 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('3'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); - $node->addChild($scalar1); - $node->addChild($scalar3); - $node->addChild($scalar2); - $r = new \ReflectionMethod($node, 'normalizeValue'); - $r->setAccessible(\true); - $this->assertSame($normalized, $r->invoke($node, $prenormalized)); - } - public function getPreNormalizedNormalizedOrderedData() - { - return [[['2' => 'two', '1' => 'one', '3' => 'three'], ['2' => 'two', '1' => 'one', '3' => 'three']]]; - } - public function testAddChildEmptyName() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('Child nodes must be named.'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); - $childNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(''); - $node->addChild($childNode); - } - public function testAddChildNameAlreadyExists() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('A child node named "foo" already exists.'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); - $childNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); - $node->addChild($childNode); - $childNodeWithSameName = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); - $node->addChild($childNodeWithSameName); - } - public function testGetDefaultValueWithoutDefaultValue() - { - $this->expectException('RuntimeException'); - $this->expectExceptionMessage('The node at path "foo" has no default value.'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); - $node->getDefaultValue(); - } - public function testSetDeprecated() - { - $childNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); - $childNode->setDeprecated('"%node%" is deprecated'); - $this->assertTrue($childNode->isDeprecated()); - $this->assertSame('"foo" is deprecated', $childNode->getDeprecationMessage($childNode->getName(), $childNode->getPath())); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); - $node->addChild($childNode); - $deprecationTriggered = \false; - $deprecationHandler = function ($level, $message, $file, $line) use(&$prevErrorHandler, &$deprecationTriggered) { - if (\E_USER_DEPRECATED === $level) { - return $deprecationTriggered = \true; - } - return $prevErrorHandler ? $prevErrorHandler($level, $message, $file, $line) : \false; - }; - $prevErrorHandler = \set_error_handler($deprecationHandler); - $node->finalize([]); - \restore_error_handler(); - $this->assertFalse($deprecationTriggered, '->finalize() should not trigger if the deprecated node is not set'); - $prevErrorHandler = \set_error_handler($deprecationHandler); - $node->finalize(['foo' => []]); - \restore_error_handler(); - $this->assertTrue($deprecationTriggered, '->finalize() should trigger if the deprecated node is set'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode; +class ArrayNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testNormalizeThrowsExceptionWhenFalseIsNotAllowed() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); + $node->normalize(\false); + } + public function testExceptionThrownOnUnrecognizedChild() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); + $this->expectExceptionMessage('Unrecognized option "foo" under "root"'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); + $node->normalize(['foo' => 'bar']); + } + public function ignoreAndRemoveMatrixProvider() + { + $unrecognizedOptionException = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidConfigurationException('Unrecognized option "foo" under "root"'); + return [[\true, \true, [], 'no exception is thrown for an unrecognized child if the ignoreExtraKeys option is set to true'], [\true, \false, ['foo' => 'bar'], 'extra keys are not removed when ignoreExtraKeys second option is set to false'], [\false, \true, $unrecognizedOptionException], [\false, \false, $unrecognizedOptionException]]; + } + /** + * @dataProvider ignoreAndRemoveMatrixProvider + */ + public function testIgnoreAndRemoveBehaviors($ignore, $remove, $expected, $message = '') + { + if ($expected instanceof \Exception) { + $this->expectException(\get_class($expected)); + $this->expectExceptionMessage($expected->getMessage()); + } + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); + $node->setIgnoreExtraKeys($ignore, $remove); + $result = $node->normalize(['foo' => 'bar']); + $this->assertSame($expected, $result, $message); + } + /** + * @dataProvider getPreNormalizationTests + */ + public function testPreNormalize($denormalized, $normalized) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); + $r = new \ReflectionMethod($node, 'preNormalize'); + $r->setAccessible(\true); + $this->assertSame($normalized, $r->invoke($node, $denormalized)); + } + public function getPreNormalizationTests() + { + return [[['foo-bar' => 'foo'], ['foo_bar' => 'foo']], [['foo-bar_moo' => 'foo'], ['foo-bar_moo' => 'foo']], [['anything-with-dash-and-no-underscore' => 'first', 'no_dash' => 'second'], ['anything_with_dash_and_no_underscore' => 'first', 'no_dash' => 'second']], [['foo-bar' => null, 'foo_bar' => 'foo'], ['foo-bar' => null, 'foo_bar' => 'foo']]]; + } + /** + * @dataProvider getZeroNamedNodeExamplesData + */ + public function testNodeNameCanBeZero($denormalized, $normalized) + { + $zeroNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(0); + $zeroNode->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('name')); + $fiveNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(5); + $fiveNode->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode(0)); + $fiveNode->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('new_key')); + $rootNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); + $rootNode->addChild($zeroNode); + $rootNode->addChild($fiveNode); + $rootNode->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('string_key')); + $r = new \ReflectionMethod($rootNode, 'normalizeValue'); + $r->setAccessible(\true); + $this->assertSame($normalized, $r->invoke($rootNode, $denormalized)); + } + public function getZeroNamedNodeExamplesData() + { + return [[[0 => ['name' => 'something'], 5 => [0 => 'this won\'t work too', 'new_key' => 'some other value'], 'string_key' => 'just value'], [0 => ['name' => 'something'], 5 => [0 => 'this won\'t work too', 'new_key' => 'some other value'], 'string_key' => 'just value']]]; + } + /** + * @dataProvider getPreNormalizedNormalizedOrderedData + */ + public function testChildrenOrderIsMaintainedOnNormalizeValue($prenormalized, $normalized) + { + $scalar1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('1'); + $scalar2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('2'); + $scalar3 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('3'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); + $node->addChild($scalar1); + $node->addChild($scalar3); + $node->addChild($scalar2); + $r = new \ReflectionMethod($node, 'normalizeValue'); + $r->setAccessible(\true); + $this->assertSame($normalized, $r->invoke($node, $prenormalized)); + } + public function getPreNormalizedNormalizedOrderedData() + { + return [[['2' => 'two', '1' => 'one', '3' => 'three'], ['2' => 'two', '1' => 'one', '3' => 'three']]]; + } + public function testAddChildEmptyName() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('Child nodes must be named.'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); + $childNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(''); + $node->addChild($childNode); + } + public function testAddChildNameAlreadyExists() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('A child node named "foo" already exists.'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); + $childNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); + $node->addChild($childNode); + $childNodeWithSameName = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); + $node->addChild($childNodeWithSameName); + } + public function testGetDefaultValueWithoutDefaultValue() + { + $this->expectException('RuntimeException'); + $this->expectExceptionMessage('The node at path "foo" has no default value.'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); + $node->getDefaultValue(); + } + public function testSetDeprecated() + { + $childNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('foo'); + $childNode->setDeprecated('"%node%" is deprecated'); + $this->assertTrue($childNode->isDeprecated()); + $this->assertSame('"foo" is deprecated', $childNode->getDeprecationMessage($childNode->getName(), $childNode->getPath())); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); + $node->addChild($childNode); + $deprecationTriggered = \false; + $deprecationHandler = function ($level, $message, $file, $line) use(&$prevErrorHandler, &$deprecationTriggered) { + if (\E_USER_DEPRECATED === $level) { + return $deprecationTriggered = \true; + } + return $prevErrorHandler ? $prevErrorHandler($level, $message, $file, $line) : \false; + }; + $prevErrorHandler = \set_error_handler($deprecationHandler); + $node->finalize([]); + \restore_error_handler(); + $this->assertFalse($deprecationTriggered, '->finalize() should not trigger if the deprecated node is not set'); + $prevErrorHandler = \set_error_handler($deprecationHandler); + $node->finalize(['foo' => []]); + \restore_error_handler(); + $this->assertTrue($deprecationTriggered, '->finalize() should trigger if the deprecated node is set'); + } +} diff --git a/vendor/symfony/config/Tests/Definition/BooleanNodeTest.php b/vendor/symfony/config/Tests/Definition/BooleanNodeTest.php index c25fc1d06..48e2863f7 100644 --- a/vendor/symfony/config/Tests/Definition/BooleanNodeTest.php +++ b/vendor/symfony/config/Tests/Definition/BooleanNodeTest.php @@ -1,53 +1,53 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode; -class BooleanNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @dataProvider getValidValues - */ - public function testNormalize($value) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode('test'); - $this->assertSame($value, $node->normalize($value)); - } - /** - * @dataProvider getValidValues - * - * @param bool $value - */ - public function testValidNonEmptyValues($value) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode('test'); - $node->setAllowEmptyValue(\false); - $this->assertSame($value, $node->finalize($value)); - } - public function getValidValues() - { - return [[\false], [\true]]; - } - /** - * @dataProvider getInvalidValues - */ - public function testNormalizeThrowsExceptionOnInvalidValues($value) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode('test'); - $node->normalize($value); - } - public function getInvalidValues() - { - return [[null], [''], ['foo'], [0], [1], [0.0], [0.1], [[]], [['foo' => 'bar']], [new \stdClass()]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode; +class BooleanNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @dataProvider getValidValues + */ + public function testNormalize($value) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode('test'); + $this->assertSame($value, $node->normalize($value)); + } + /** + * @dataProvider getValidValues + * + * @param bool $value + */ + public function testValidNonEmptyValues($value) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode('test'); + $node->setAllowEmptyValue(\false); + $this->assertSame($value, $node->finalize($value)); + } + public function getValidValues() + { + return [[\false], [\true]]; + } + /** + * @dataProvider getInvalidValues + */ + public function testNormalizeThrowsExceptionOnInvalidValues($value) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\BooleanNode('test'); + $node->normalize($value); + } + public function getInvalidValues() + { + return [[null], [''], ['foo'], [0], [1], [0.0], [0.1], [[]], [['foo' => 'bar']], [new \stdClass()]]; + } +} diff --git a/vendor/symfony/config/Tests/Definition/Builder/ArrayNodeDefinitionTest.php b/vendor/symfony/config/Tests/Definition/Builder/ArrayNodeDefinitionTest.php index 4252d71e8..7ffcd8f46 100644 --- a/vendor/symfony/config/Tests/Definition/Builder/ArrayNodeDefinitionTest.php +++ b/vendor/symfony/config/Tests/Definition/Builder/ArrayNodeDefinitionTest.php @@ -1,233 +1,233 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor; -class ArrayNodeDefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testAppendingSomeNode() - { - $parent = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $child = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition('child'); - $parent->children()->scalarNode('foo')->end()->scalarNode('bar')->end()->end()->append($child); - $this->assertCount(3, $this->getField($parent, 'children')); - $this->assertContains($child, $this->getField($parent, 'children')); - } - /** - * @dataProvider providePrototypeNodeSpecificCalls - */ - public function testPrototypeNodeSpecificOption($method, $args) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - \call_user_func_array([$node, $method], $args); - $node->getNode(); - } - public function providePrototypeNodeSpecificCalls() - { - return [['defaultValue', [[]]], ['addDefaultChildrenIfNoneSet', []], ['requiresAtLeastOneElement', []], ['useAttributeAsKey', ['foo']]]; - } - public function testConcreteNodeSpecificOption() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->addDefaultsIfNotSet()->prototype('array'); - $node->getNode(); - } - public function testPrototypeNodesCantHaveADefaultValueWhenUsingDefaultChildren() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->defaultValue([])->addDefaultChildrenIfNoneSet('foo')->prototype('array'); - $node->getNode(); - } - public function testPrototypedArrayNodeDefaultWhenUsingDefaultChildren() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->addDefaultChildrenIfNoneSet()->prototype('array'); - $tree = $node->getNode(); - $this->assertEquals([[]], $tree->getDefaultValue()); - } - /** - * @dataProvider providePrototypedArrayNodeDefaults - */ - public function testPrototypedArrayNodeDefault($args, $shouldThrowWhenUsingAttrAsKey, $shouldThrowWhenNotUsingAttrAsKey, $defaults) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->addDefaultChildrenIfNoneSet($args)->prototype('array'); - try { - $tree = $node->getNode(); - $this->assertFalse($shouldThrowWhenNotUsingAttrAsKey); - $this->assertEquals($defaults, $tree->getDefaultValue()); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException $e) { - $this->assertTrue($shouldThrowWhenNotUsingAttrAsKey); - } - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->useAttributeAsKey('attr')->addDefaultChildrenIfNoneSet($args)->prototype('array'); - try { - $tree = $node->getNode(); - $this->assertFalse($shouldThrowWhenUsingAttrAsKey); - $this->assertEquals($defaults, $tree->getDefaultValue()); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException $e) { - $this->assertTrue($shouldThrowWhenUsingAttrAsKey); - } - } - public function providePrototypedArrayNodeDefaults() - { - return [[null, \true, \false, [[]]], [2, \true, \false, [[], []]], ['2', \false, \true, ['2' => []]], ['foo', \false, \true, ['foo' => []]], [['foo'], \false, \true, ['foo' => []]], [['foo', 'bar'], \false, \true, ['foo' => [], 'bar' => []]]]; - } - public function testNestedPrototypedArrayNodes() - { - $nodeDefinition = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $nodeDefinition->addDefaultChildrenIfNoneSet()->prototype('array')->prototype('array'); - $node = $nodeDefinition->getNode(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypedArrayNode', $node); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypedArrayNode', $node->getPrototype()); - } - public function testEnabledNodeDefaults() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->canBeEnabled()->children()->scalarNode('foo')->defaultValue('bar')->end(); - $this->assertEquals(['enabled' => \false, 'foo' => 'bar'], $node->getNode()->getDefaultValue()); - } - /** - * @dataProvider getEnableableNodeFixtures - */ - public function testTrueEnableEnabledNode($expected, $config, $message) - { - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor(); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->canBeEnabled()->children()->scalarNode('foo')->defaultValue('bar')->end(); - $this->assertEquals($expected, $processor->process($node->getNode(), $config), $message); - } - public function testCanBeDisabled() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->canBeDisabled(); - $this->assertTrue($this->getField($node, 'addDefaults')); - $this->assertEquals(['enabled' => \false], $this->getField($node, 'falseEquivalent')); - $this->assertEquals(['enabled' => \true], $this->getField($node, 'trueEquivalent')); - $this->assertEquals(['enabled' => \true], $this->getField($node, 'nullEquivalent')); - $nodeChildren = $this->getField($node, 'children'); - $this->assertArrayHasKey('enabled', $nodeChildren); - $enabledNode = $nodeChildren['enabled']; - $this->assertTrue($this->getField($enabledNode, 'default')); - $this->assertTrue($this->getField($enabledNode, 'defaultValue')); - } - public function testIgnoreExtraKeys() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $this->assertFalse($this->getField($node, 'ignoreExtraKeys')); - $result = $node->ignoreExtraKeys(); - $this->assertEquals($node, $result); - $this->assertTrue($this->getField($node, 'ignoreExtraKeys')); - } - public function testNormalizeKeys() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $this->assertTrue($this->getField($node, 'normalizeKeys')); - $result = $node->normalizeKeys(\false); - $this->assertEquals($node, $result); - $this->assertFalse($this->getField($node, 'normalizeKeys')); - } - public function testUnsetChild() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->children()->scalarNode('value')->beforeNormalization()->ifTrue(function ($value) { - return empty($value); - })->thenUnset()->end()->end()->end(); - $this->assertSame([], $node->getNode()->normalize(['value' => null])); - } - public function testPrototypeVariable() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $this->assertEquals($node->prototype('variable'), $node->variablePrototype()); - } - public function testPrototypeScalar() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $this->assertEquals($node->prototype('scalar'), $node->scalarPrototype()); - } - public function testPrototypeBoolean() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $this->assertEquals($node->prototype('boolean'), $node->booleanPrototype()); - } - public function testPrototypeInteger() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $this->assertEquals($node->prototype('integer'), $node->integerPrototype()); - } - public function testPrototypeFloat() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $this->assertEquals($node->prototype('float'), $node->floatPrototype()); - } - public function testPrototypeArray() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $this->assertEquals($node->prototype('array'), $node->arrayPrototype()); - } - public function testPrototypeEnum() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $this->assertEquals($node->prototype('enum'), $node->enumPrototype()); - } - public function getEnableableNodeFixtures() - { - return [[['enabled' => \true, 'foo' => 'bar'], [\true], 'true enables an enableable node'], [['enabled' => \true, 'foo' => 'bar'], [null], 'null enables an enableable node'], [['enabled' => \true, 'foo' => 'bar'], [['enabled' => \true]], 'An enableable node can be enabled'], [['enabled' => \true, 'foo' => 'baz'], [['foo' => 'baz']], 'any configuration enables an enableable node'], [['enabled' => \false, 'foo' => 'baz'], [['foo' => 'baz', 'enabled' => \false]], 'An enableable node can be disabled'], [['enabled' => \false, 'foo' => 'bar'], [\false], 'false disables an enableable node']]; - } - public function testRequiresAtLeastOneElement() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->requiresAtLeastOneElement()->integerPrototype(); - $node->getNode()->finalize([1]); - $this->addToAssertionCount(1); - } - /** - * @group legacy - * @expectedDeprecation Using Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition::cannotBeEmpty() at path "root" has no effect, consider requiresAtLeastOneElement() instead. In 4.0 both methods will behave the same. - */ - public function testCannotBeEmpty() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->cannotBeEmpty()->integerPrototype(); - $node->getNode()->finalize([]); - } - public function testSetDeprecated() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->children()->arrayNode('foo')->setDeprecated('The "%path%" node is deprecated.')->end()->end(); - $deprecatedNode = $node->getNode()->getChildren()['foo']; - $this->assertTrue($deprecatedNode->isDeprecated()); - $this->assertSame('The "root.foo" node is deprecated.', $deprecatedNode->getDeprecationMessage($deprecatedNode->getName(), $deprecatedNode->getPath())); - } - /** - * @group legacy - * @expectedDeprecation ->cannotBeEmpty() is not applicable to concrete nodes at path "root". In 4.0 it will throw an exception. - */ - public function testCannotBeEmptyOnConcreteNode() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); - $node->cannotBeEmpty(); - $node->getNode()->finalize([]); - } - protected function getField($object, $field) - { - $reflection = new \ReflectionProperty($object, $field); - $reflection->setAccessible(\true); - return $reflection->getValue($object); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor; +class ArrayNodeDefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testAppendingSomeNode() + { + $parent = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $child = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ScalarNodeDefinition('child'); + $parent->children()->scalarNode('foo')->end()->scalarNode('bar')->end()->end()->append($child); + $this->assertCount(3, $this->getField($parent, 'children')); + $this->assertContains($child, $this->getField($parent, 'children')); + } + /** + * @dataProvider providePrototypeNodeSpecificCalls + */ + public function testPrototypeNodeSpecificOption($method, $args) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + \call_user_func_array([$node, $method], $args); + $node->getNode(); + } + public function providePrototypeNodeSpecificCalls() + { + return [['defaultValue', [[]]], ['addDefaultChildrenIfNoneSet', []], ['requiresAtLeastOneElement', []], ['useAttributeAsKey', ['foo']]]; + } + public function testConcreteNodeSpecificOption() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->addDefaultsIfNotSet()->prototype('array'); + $node->getNode(); + } + public function testPrototypeNodesCantHaveADefaultValueWhenUsingDefaultChildren() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->defaultValue([])->addDefaultChildrenIfNoneSet('foo')->prototype('array'); + $node->getNode(); + } + public function testPrototypedArrayNodeDefaultWhenUsingDefaultChildren() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->addDefaultChildrenIfNoneSet()->prototype('array'); + $tree = $node->getNode(); + $this->assertEquals([[]], $tree->getDefaultValue()); + } + /** + * @dataProvider providePrototypedArrayNodeDefaults + */ + public function testPrototypedArrayNodeDefault($args, $shouldThrowWhenUsingAttrAsKey, $shouldThrowWhenNotUsingAttrAsKey, $defaults) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->addDefaultChildrenIfNoneSet($args)->prototype('array'); + try { + $tree = $node->getNode(); + $this->assertFalse($shouldThrowWhenNotUsingAttrAsKey); + $this->assertEquals($defaults, $tree->getDefaultValue()); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException $e) { + $this->assertTrue($shouldThrowWhenNotUsingAttrAsKey); + } + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->useAttributeAsKey('attr')->addDefaultChildrenIfNoneSet($args)->prototype('array'); + try { + $tree = $node->getNode(); + $this->assertFalse($shouldThrowWhenUsingAttrAsKey); + $this->assertEquals($defaults, $tree->getDefaultValue()); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Exception\InvalidDefinitionException $e) { + $this->assertTrue($shouldThrowWhenUsingAttrAsKey); + } + } + public function providePrototypedArrayNodeDefaults() + { + return [[null, \true, \false, [[]]], [2, \true, \false, [[], []]], ['2', \false, \true, ['2' => []]], ['foo', \false, \true, ['foo' => []]], [['foo'], \false, \true, ['foo' => []]], [['foo', 'bar'], \false, \true, ['foo' => [], 'bar' => []]]]; + } + public function testNestedPrototypedArrayNodes() + { + $nodeDefinition = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $nodeDefinition->addDefaultChildrenIfNoneSet()->prototype('array')->prototype('array'); + $node = $nodeDefinition->getNode(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypedArrayNode', $node); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\PrototypedArrayNode', $node->getPrototype()); + } + public function testEnabledNodeDefaults() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->canBeEnabled()->children()->scalarNode('foo')->defaultValue('bar')->end(); + $this->assertEquals(['enabled' => \false, 'foo' => 'bar'], $node->getNode()->getDefaultValue()); + } + /** + * @dataProvider getEnableableNodeFixtures + */ + public function testTrueEnableEnabledNode($expected, $config, $message) + { + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor(); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->canBeEnabled()->children()->scalarNode('foo')->defaultValue('bar')->end(); + $this->assertEquals($expected, $processor->process($node->getNode(), $config), $message); + } + public function testCanBeDisabled() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->canBeDisabled(); + $this->assertTrue($this->getField($node, 'addDefaults')); + $this->assertEquals(['enabled' => \false], $this->getField($node, 'falseEquivalent')); + $this->assertEquals(['enabled' => \true], $this->getField($node, 'trueEquivalent')); + $this->assertEquals(['enabled' => \true], $this->getField($node, 'nullEquivalent')); + $nodeChildren = $this->getField($node, 'children'); + $this->assertArrayHasKey('enabled', $nodeChildren); + $enabledNode = $nodeChildren['enabled']; + $this->assertTrue($this->getField($enabledNode, 'default')); + $this->assertTrue($this->getField($enabledNode, 'defaultValue')); + } + public function testIgnoreExtraKeys() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $this->assertFalse($this->getField($node, 'ignoreExtraKeys')); + $result = $node->ignoreExtraKeys(); + $this->assertEquals($node, $result); + $this->assertTrue($this->getField($node, 'ignoreExtraKeys')); + } + public function testNormalizeKeys() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $this->assertTrue($this->getField($node, 'normalizeKeys')); + $result = $node->normalizeKeys(\false); + $this->assertEquals($node, $result); + $this->assertFalse($this->getField($node, 'normalizeKeys')); + } + public function testUnsetChild() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->children()->scalarNode('value')->beforeNormalization()->ifTrue(function ($value) { + return empty($value); + })->thenUnset()->end()->end()->end(); + $this->assertSame([], $node->getNode()->normalize(['value' => null])); + } + public function testPrototypeVariable() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $this->assertEquals($node->prototype('variable'), $node->variablePrototype()); + } + public function testPrototypeScalar() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $this->assertEquals($node->prototype('scalar'), $node->scalarPrototype()); + } + public function testPrototypeBoolean() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $this->assertEquals($node->prototype('boolean'), $node->booleanPrototype()); + } + public function testPrototypeInteger() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $this->assertEquals($node->prototype('integer'), $node->integerPrototype()); + } + public function testPrototypeFloat() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $this->assertEquals($node->prototype('float'), $node->floatPrototype()); + } + public function testPrototypeArray() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $this->assertEquals($node->prototype('array'), $node->arrayPrototype()); + } + public function testPrototypeEnum() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $this->assertEquals($node->prototype('enum'), $node->enumPrototype()); + } + public function getEnableableNodeFixtures() + { + return [[['enabled' => \true, 'foo' => 'bar'], [\true], 'true enables an enableable node'], [['enabled' => \true, 'foo' => 'bar'], [null], 'null enables an enableable node'], [['enabled' => \true, 'foo' => 'bar'], [['enabled' => \true]], 'An enableable node can be enabled'], [['enabled' => \true, 'foo' => 'baz'], [['foo' => 'baz']], 'any configuration enables an enableable node'], [['enabled' => \false, 'foo' => 'baz'], [['foo' => 'baz', 'enabled' => \false]], 'An enableable node can be disabled'], [['enabled' => \false, 'foo' => 'bar'], [\false], 'false disables an enableable node']]; + } + public function testRequiresAtLeastOneElement() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->requiresAtLeastOneElement()->integerPrototype(); + $node->getNode()->finalize([1]); + $this->addToAssertionCount(1); + } + /** + * @group legacy + * @expectedDeprecation Using Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition::cannotBeEmpty() at path "root" has no effect, consider requiresAtLeastOneElement() instead. In 4.0 both methods will behave the same. + */ + public function testCannotBeEmpty() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->cannotBeEmpty()->integerPrototype(); + $node->getNode()->finalize([]); + } + public function testSetDeprecated() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->children()->arrayNode('foo')->setDeprecated('The "%path%" node is deprecated.')->end()->end(); + $deprecatedNode = $node->getNode()->getChildren()['foo']; + $this->assertTrue($deprecatedNode->isDeprecated()); + $this->assertSame('The "root.foo" node is deprecated.', $deprecatedNode->getDeprecationMessage($deprecatedNode->getName(), $deprecatedNode->getPath())); + } + /** + * @group legacy + * @expectedDeprecation ->cannotBeEmpty() is not applicable to concrete nodes at path "root". In 4.0 it will throw an exception. + */ + public function testCannotBeEmptyOnConcreteNode() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\ArrayNodeDefinition('root'); + $node->cannotBeEmpty(); + $node->getNode()->finalize([]); + } + protected function getField($object, $field) + { + $reflection = new \ReflectionProperty($object, $field); + $reflection->setAccessible(\true); + return $reflection->getValue($object); + } +} diff --git a/vendor/symfony/config/Tests/Definition/Builder/BooleanNodeDefinitionTest.php b/vendor/symfony/config/Tests/Definition/Builder/BooleanNodeDefinitionTest.php index 24fecfc6e..0ac9592aa 100644 --- a/vendor/symfony/config/Tests/Definition/Builder/BooleanNodeDefinitionTest.php +++ b/vendor/symfony/config/Tests/Definition/Builder/BooleanNodeDefinitionTest.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\BooleanNodeDefinition; -class BooleanNodeDefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testCannotBeEmptyThrowsAnException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException'); - $this->expectExceptionMessage('->cannotBeEmpty() is not applicable to BooleanNodeDefinition.'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\BooleanNodeDefinition('foo'); - $def->cannotBeEmpty(); - } - public function testSetDeprecated() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\BooleanNodeDefinition('foo'); - $def->setDeprecated('The "%path%" node is deprecated.'); - $node = $def->getNode(); - $this->assertTrue($node->isDeprecated()); - $this->assertSame('The "foo" node is deprecated.', $node->getDeprecationMessage($node->getName(), $node->getPath())); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\BooleanNodeDefinition; +class BooleanNodeDefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testCannotBeEmptyThrowsAnException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException'); + $this->expectExceptionMessage('->cannotBeEmpty() is not applicable to BooleanNodeDefinition.'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\BooleanNodeDefinition('foo'); + $def->cannotBeEmpty(); + } + public function testSetDeprecated() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\BooleanNodeDefinition('foo'); + $def->setDeprecated('The "%path%" node is deprecated.'); + $node = $def->getNode(); + $this->assertTrue($node->isDeprecated()); + $this->assertSame('The "foo" node is deprecated.', $node->getDeprecationMessage($node->getName(), $node->getPath())); + } +} diff --git a/vendor/symfony/config/Tests/Definition/Builder/EnumNodeDefinitionTest.php b/vendor/symfony/config/Tests/Definition/Builder/EnumNodeDefinitionTest.php index 8747c3f46..f1ddb997e 100644 --- a/vendor/symfony/config/Tests/Definition/Builder/EnumNodeDefinitionTest.php +++ b/vendor/symfony/config/Tests/Definition/Builder/EnumNodeDefinitionTest.php @@ -1,61 +1,61 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition; -class EnumNodeDefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testWithOneValue() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); - $def->values(['foo']); - $node = $def->getNode(); - $this->assertEquals(['foo'], $node->getValues()); - } - public function testWithOneDistinctValue() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); - $def->values(['foo', 'foo']); - $node = $def->getNode(); - $this->assertEquals(['foo'], $node->getValues()); - } - public function testNoValuesPassed() - { - $this->expectException('RuntimeException'); - $this->expectExceptionMessage('You must call ->values() on enum nodes.'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); - $def->getNode(); - } - public function testWithNoValues() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('->values() must be called with at least one value.'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); - $def->values([]); - } - public function testGetNode() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); - $def->values(['foo', 'bar']); - $node = $def->getNode(); - $this->assertEquals(['foo', 'bar'], $node->getValues()); - } - public function testSetDeprecated() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); - $def->values(['foo', 'bar']); - $def->setDeprecated('The "%path%" node is deprecated.'); - $node = $def->getNode(); - $this->assertTrue($node->isDeprecated()); - $this->assertSame('The "foo" node is deprecated.', $def->getNode()->getDeprecationMessage($node->getName(), $node->getPath())); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition; +class EnumNodeDefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testWithOneValue() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); + $def->values(['foo']); + $node = $def->getNode(); + $this->assertEquals(['foo'], $node->getValues()); + } + public function testWithOneDistinctValue() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); + $def->values(['foo', 'foo']); + $node = $def->getNode(); + $this->assertEquals(['foo'], $node->getValues()); + } + public function testNoValuesPassed() + { + $this->expectException('RuntimeException'); + $this->expectExceptionMessage('You must call ->values() on enum nodes.'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); + $def->getNode(); + } + public function testWithNoValues() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('->values() must be called with at least one value.'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); + $def->values([]); + } + public function testGetNode() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); + $def->values(['foo', 'bar']); + $node = $def->getNode(); + $this->assertEquals(['foo', 'bar'], $node->getValues()); + } + public function testSetDeprecated() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\EnumNodeDefinition('foo'); + $def->values(['foo', 'bar']); + $def->setDeprecated('The "%path%" node is deprecated.'); + $node = $def->getNode(); + $this->assertTrue($node->isDeprecated()); + $this->assertSame('The "foo" node is deprecated.', $def->getNode()->getDeprecationMessage($node->getName(), $node->getPath())); + } +} diff --git a/vendor/symfony/config/Tests/Definition/Builder/ExprBuilderTest.php b/vendor/symfony/config/Tests/Definition/Builder/ExprBuilderTest.php index ddfd2b48e..6f352b00a 100644 --- a/vendor/symfony/config/Tests/Definition/Builder/ExprBuilderTest.php +++ b/vendor/symfony/config/Tests/Definition/Builder/ExprBuilderTest.php @@ -1,169 +1,169 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; -class ExprBuilderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testAlwaysExpression() - { - $test = $this->getTestBuilder()->always($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('new_value', $test); - } - public function testIfTrueExpression() - { - $test = $this->getTestBuilder()->ifTrue()->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('new_value', $test, ['key' => \true]); - $test = $this->getTestBuilder()->ifTrue(function ($v) { - return \true; - })->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('new_value', $test); - $test = $this->getTestBuilder()->ifTrue(function ($v) { - return \false; - })->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('value', $test); - } - public function testIfStringExpression() - { - $test = $this->getTestBuilder()->ifString()->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('new_value', $test); - $test = $this->getTestBuilder()->ifString()->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs(45, $test, ['key' => 45]); - } - public function testIfNullExpression() - { - $test = $this->getTestBuilder()->ifNull()->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('new_value', $test, ['key' => null]); - $test = $this->getTestBuilder()->ifNull()->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('value', $test); - } - public function testIfEmptyExpression() - { - $test = $this->getTestBuilder()->ifEmpty()->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('new_value', $test, ['key' => []]); - $test = $this->getTestBuilder()->ifEmpty()->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('value', $test); - } - public function testIfArrayExpression() - { - $test = $this->getTestBuilder()->ifArray()->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('new_value', $test, ['key' => []]); - $test = $this->getTestBuilder()->ifArray()->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('value', $test); - } - public function testIfInArrayExpression() - { - $test = $this->getTestBuilder()->ifInArray(['foo', 'bar', 'value'])->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('new_value', $test); - $test = $this->getTestBuilder()->ifInArray(['foo', 'bar'])->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('value', $test); - } - public function testIfNotInArrayExpression() - { - $test = $this->getTestBuilder()->ifNotInArray(['foo', 'bar'])->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('new_value', $test); - $test = $this->getTestBuilder()->ifNotInArray(['foo', 'bar', 'value_from_config'])->then($this->returnClosure('new_value'))->end(); - $this->assertFinalizedValueIs('new_value', $test); - } - public function testThenEmptyArrayExpression() - { - $test = $this->getTestBuilder()->ifString()->thenEmptyArray()->end(); - $this->assertFinalizedValueIs([], $test); - } - /** - * @dataProvider castToArrayValues - */ - public function testcastToArrayExpression($configValue, $expectedValue) - { - $test = $this->getTestBuilder()->castToArray()->end(); - $this->assertFinalizedValueIs($expectedValue, $test, ['key' => $configValue]); - } - public function castToArrayValues() - { - (yield ['value', ['value']]); - (yield [-3.14, [-3.14]]); - (yield [null, [null]]); - (yield [['value'], ['value']]); - } - public function testThenInvalid() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); - $test = $this->getTestBuilder()->ifString()->thenInvalid('Invalid value')->end(); - $this->finalizeTestBuilder($test); - } - public function testThenUnsetExpression() - { - $test = $this->getTestBuilder()->ifString()->thenUnset()->end(); - $this->assertEquals([], $this->finalizeTestBuilder($test)); - } - public function testEndIfPartNotSpecified() - { - $this->expectException('RuntimeException'); - $this->expectExceptionMessage('You must specify an if part.'); - $this->getTestBuilder()->end(); - } - public function testEndThenPartNotSpecified() - { - $this->expectException('RuntimeException'); - $this->expectExceptionMessage('You must specify a then part.'); - $builder = $this->getTestBuilder(); - $builder->ifPart = 'test'; - $builder->end(); - } - /** - * Create a test treebuilder with a variable node, and init the validation. - * - * @return TreeBuilder - */ - protected function getTestBuilder() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - return $builder->root('test')->children()->variableNode('key')->validate(); - } - /** - * Close the validation process and finalize with the given config. - * - * @param TreeBuilder $testBuilder The tree builder to finalize - * @param array $config The config you want to use for the finalization, if nothing provided - * a simple ['key'=>'value'] will be used - * - * @return array The finalized config values - */ - protected function finalizeTestBuilder($testBuilder, $config = null) - { - return $testBuilder->end()->end()->end()->buildTree()->finalize(null === $config ? ['key' => 'value'] : $config); - } - /** - * Return a closure that will return the given value. - * - * @param mixed $val The value that the closure must return - * - * @return \Closure - */ - protected function returnClosure($val) - { - return function ($v) use($val) { - return $val; - }; - } - /** - * Assert that the given test builder, will return the given value. - * - * @param mixed $value The value to test - * @param TreeBuilder $treeBuilder The tree builder to finalize - * @param mixed $config The config values that new to be finalized - */ - protected function assertFinalizedValueIs($value, $treeBuilder, $config = null) - { - $this->assertEquals(['key' => $value], $this->finalizeTestBuilder($treeBuilder, $config)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; +class ExprBuilderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testAlwaysExpression() + { + $test = $this->getTestBuilder()->always($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('new_value', $test); + } + public function testIfTrueExpression() + { + $test = $this->getTestBuilder()->ifTrue()->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('new_value', $test, ['key' => \true]); + $test = $this->getTestBuilder()->ifTrue(function ($v) { + return \true; + })->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('new_value', $test); + $test = $this->getTestBuilder()->ifTrue(function ($v) { + return \false; + })->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('value', $test); + } + public function testIfStringExpression() + { + $test = $this->getTestBuilder()->ifString()->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('new_value', $test); + $test = $this->getTestBuilder()->ifString()->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs(45, $test, ['key' => 45]); + } + public function testIfNullExpression() + { + $test = $this->getTestBuilder()->ifNull()->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('new_value', $test, ['key' => null]); + $test = $this->getTestBuilder()->ifNull()->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('value', $test); + } + public function testIfEmptyExpression() + { + $test = $this->getTestBuilder()->ifEmpty()->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('new_value', $test, ['key' => []]); + $test = $this->getTestBuilder()->ifEmpty()->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('value', $test); + } + public function testIfArrayExpression() + { + $test = $this->getTestBuilder()->ifArray()->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('new_value', $test, ['key' => []]); + $test = $this->getTestBuilder()->ifArray()->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('value', $test); + } + public function testIfInArrayExpression() + { + $test = $this->getTestBuilder()->ifInArray(['foo', 'bar', 'value'])->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('new_value', $test); + $test = $this->getTestBuilder()->ifInArray(['foo', 'bar'])->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('value', $test); + } + public function testIfNotInArrayExpression() + { + $test = $this->getTestBuilder()->ifNotInArray(['foo', 'bar'])->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('new_value', $test); + $test = $this->getTestBuilder()->ifNotInArray(['foo', 'bar', 'value_from_config'])->then($this->returnClosure('new_value'))->end(); + $this->assertFinalizedValueIs('new_value', $test); + } + public function testThenEmptyArrayExpression() + { + $test = $this->getTestBuilder()->ifString()->thenEmptyArray()->end(); + $this->assertFinalizedValueIs([], $test); + } + /** + * @dataProvider castToArrayValues + */ + public function testcastToArrayExpression($configValue, $expectedValue) + { + $test = $this->getTestBuilder()->castToArray()->end(); + $this->assertFinalizedValueIs($expectedValue, $test, ['key' => $configValue]); + } + public function castToArrayValues() + { + (yield ['value', ['value']]); + (yield [-3.14, [-3.14]]); + (yield [null, [null]]); + (yield [['value'], ['value']]); + } + public function testThenInvalid() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); + $test = $this->getTestBuilder()->ifString()->thenInvalid('Invalid value')->end(); + $this->finalizeTestBuilder($test); + } + public function testThenUnsetExpression() + { + $test = $this->getTestBuilder()->ifString()->thenUnset()->end(); + $this->assertEquals([], $this->finalizeTestBuilder($test)); + } + public function testEndIfPartNotSpecified() + { + $this->expectException('RuntimeException'); + $this->expectExceptionMessage('You must specify an if part.'); + $this->getTestBuilder()->end(); + } + public function testEndThenPartNotSpecified() + { + $this->expectException('RuntimeException'); + $this->expectExceptionMessage('You must specify a then part.'); + $builder = $this->getTestBuilder(); + $builder->ifPart = 'test'; + $builder->end(); + } + /** + * Create a test treebuilder with a variable node, and init the validation. + * + * @return TreeBuilder + */ + protected function getTestBuilder() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + return $builder->root('test')->children()->variableNode('key')->validate(); + } + /** + * Close the validation process and finalize with the given config. + * + * @param TreeBuilder $testBuilder The tree builder to finalize + * @param array $config The config you want to use for the finalization, if nothing provided + * a simple ['key'=>'value'] will be used + * + * @return array The finalized config values + */ + protected function finalizeTestBuilder($testBuilder, $config = null) + { + return $testBuilder->end()->end()->end()->buildTree()->finalize(null === $config ? ['key' => 'value'] : $config); + } + /** + * Return a closure that will return the given value. + * + * @param mixed $val The value that the closure must return + * + * @return \Closure + */ + protected function returnClosure($val) + { + return function ($v) use($val) { + return $val; + }; + } + /** + * Assert that the given test builder, will return the given value. + * + * @param mixed $value The value to test + * @param TreeBuilder $treeBuilder The tree builder to finalize + * @param mixed $config The config values that new to be finalized + */ + protected function assertFinalizedValueIs($value, $treeBuilder, $config = null) + { + $this->assertEquals(['key' => $value], $this->finalizeTestBuilder($treeBuilder, $config)); + } +} diff --git a/vendor/symfony/config/Tests/Definition/Builder/NodeBuilderTest.php b/vendor/symfony/config/Tests/Definition/Builder/NodeBuilderTest.php index 40b39ec47..271fe866f 100644 --- a/vendor/symfony/config/Tests/Definition/Builder/NodeBuilderTest.php +++ b/vendor/symfony/config/Tests/Definition/Builder/NodeBuilderTest.php @@ -1,66 +1,66 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder as BaseNodeBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition as BaseVariableNodeDefinition; -class NodeBuilderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testThrowsAnExceptionWhenTryingToCreateANonRegisteredNodeType() - { - $this->expectException('RuntimeException'); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); - $builder->node('', 'foobar'); - } - public function testThrowsAnExceptionWhenTheNodeClassIsNotFound() - { - $this->expectException('RuntimeException'); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); - $builder->setNodeClass('noclasstype', '_PhpScoper5ea00cc67502b\\foo\\bar\\noclass')->node('', 'noclasstype'); - } - public function testAddingANewNodeType() - { - $class = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder\SomeNodeDefinition::class; - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); - $node = $builder->setNodeClass('newtype', $class)->node('', 'newtype'); - $this->assertInstanceOf($class, $node); - } - public function testOverridingAnExistingNodeType() - { - $class = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder\SomeNodeDefinition::class; - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); - $node = $builder->setNodeClass('variable', $class)->node('', 'variable'); - $this->assertInstanceOf($class, $node); - } - public function testNodeTypesAreNotCaseSensitive() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); - $node1 = $builder->node('', 'VaRiAbLe'); - $node2 = $builder->node('', 'variable'); - $this->assertInstanceOf(\get_class($node1), $node2); - $builder->setNodeClass('CuStOm', \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder\SomeNodeDefinition::class); - $node1 = $builder->node('', 'CUSTOM'); - $node2 = $builder->node('', 'custom'); - $this->assertInstanceOf(\get_class($node1), $node2); - } - public function testNumericNodeCreation() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); - $node = $builder->integerNode('foo')->min(3)->max(5); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\IntegerNodeDefinition', $node); - $node = $builder->floatNode('bar')->min(3.0)->max(5.0); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\FloatNodeDefinition', $node); - } -} -class SomeNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder as BaseNodeBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition as BaseVariableNodeDefinition; +class NodeBuilderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testThrowsAnExceptionWhenTryingToCreateANonRegisteredNodeType() + { + $this->expectException('RuntimeException'); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); + $builder->node('', 'foobar'); + } + public function testThrowsAnExceptionWhenTheNodeClassIsNotFound() + { + $this->expectException('RuntimeException'); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); + $builder->setNodeClass('noclasstype', '_PhpScoper5ea00cc67502b\\foo\\bar\\noclass')->node('', 'noclasstype'); + } + public function testAddingANewNodeType() + { + $class = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder\SomeNodeDefinition::class; + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); + $node = $builder->setNodeClass('newtype', $class)->node('', 'newtype'); + $this->assertInstanceOf($class, $node); + } + public function testOverridingAnExistingNodeType() + { + $class = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder\SomeNodeDefinition::class; + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); + $node = $builder->setNodeClass('variable', $class)->node('', 'variable'); + $this->assertInstanceOf($class, $node); + } + public function testNodeTypesAreNotCaseSensitive() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); + $node1 = $builder->node('', 'VaRiAbLe'); + $node2 = $builder->node('', 'variable'); + $this->assertInstanceOf(\get_class($node1), $node2); + $builder->setNodeClass('CuStOm', \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder\SomeNodeDefinition::class); + $node1 = $builder->node('', 'CUSTOM'); + $node2 = $builder->node('', 'custom'); + $this->assertInstanceOf(\get_class($node1), $node2); + } + public function testNumericNodeCreation() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder(); + $node = $builder->integerNode('foo')->min(3)->max(5); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\IntegerNodeDefinition', $node); + $node = $builder->floatNode('bar')->min(3.0)->max(5.0); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\FloatNodeDefinition', $node); + } +} +class SomeNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition +{ +} diff --git a/vendor/symfony/config/Tests/Definition/Builder/NumericNodeDefinitionTest.php b/vendor/symfony/config/Tests/Definition/Builder/NumericNodeDefinitionTest.php index 27283b64b..88cdff002 100644 --- a/vendor/symfony/config/Tests/Definition/Builder/NumericNodeDefinitionTest.php +++ b/vendor/symfony/config/Tests/Definition/Builder/NumericNodeDefinitionTest.php @@ -1,79 +1,79 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\FloatNodeDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition; -class NumericNodeDefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testIncoherentMinAssertion() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('You cannot define a min(4) as you already have a max(3)'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); - $def->max(3)->min(4); - } - public function testIncoherentMaxAssertion() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('You cannot define a max(2) as you already have a min(3)'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); - $node->min(3)->max(2); - } - public function testIntegerMinAssertion() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); - $this->expectExceptionMessage('The value 4 is too small for path "foo". Should be greater than or equal to 5'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); - $def->min(5)->getNode()->finalize(4); - } - public function testIntegerMaxAssertion() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); - $this->expectExceptionMessage('The value 4 is too big for path "foo". Should be less than or equal to 3'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); - $def->max(3)->getNode()->finalize(4); - } - public function testIntegerValidMinMaxAssertion() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); - $node = $def->min(3)->max(7)->getNode(); - $this->assertEquals(4, $node->finalize(4)); - } - public function testFloatMinAssertion() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); - $this->expectExceptionMessage('The value 400 is too small for path "foo". Should be greater than or equal to 500'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\FloatNodeDefinition('foo'); - $def->min(500.0)->getNode()->finalize(400.0); - } - public function testFloatMaxAssertion() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); - $this->expectExceptionMessage('The value 4.3 is too big for path "foo". Should be less than or equal to 0.3'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\FloatNodeDefinition('foo'); - $def->max(0.3)->getNode()->finalize(4.3); - } - public function testFloatValidMinMaxAssertion() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\FloatNodeDefinition('foo'); - $node = $def->min(3.0)->max(700.0)->getNode(); - $this->assertEquals(4.5, $node->finalize(4.5)); - } - public function testCannotBeEmptyThrowsAnException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException'); - $this->expectExceptionMessage('->cannotBeEmpty() is not applicable to NumericNodeDefinition.'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); - $def->cannotBeEmpty(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\FloatNodeDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition; +class NumericNodeDefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testIncoherentMinAssertion() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('You cannot define a min(4) as you already have a max(3)'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); + $def->max(3)->min(4); + } + public function testIncoherentMaxAssertion() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('You cannot define a max(2) as you already have a min(3)'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); + $node->min(3)->max(2); + } + public function testIntegerMinAssertion() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); + $this->expectExceptionMessage('The value 4 is too small for path "foo". Should be greater than or equal to 5'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); + $def->min(5)->getNode()->finalize(4); + } + public function testIntegerMaxAssertion() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); + $this->expectExceptionMessage('The value 4 is too big for path "foo". Should be less than or equal to 3'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); + $def->max(3)->getNode()->finalize(4); + } + public function testIntegerValidMinMaxAssertion() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); + $node = $def->min(3)->max(7)->getNode(); + $this->assertEquals(4, $node->finalize(4)); + } + public function testFloatMinAssertion() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); + $this->expectExceptionMessage('The value 400 is too small for path "foo". Should be greater than or equal to 500'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\FloatNodeDefinition('foo'); + $def->min(500.0)->getNode()->finalize(400.0); + } + public function testFloatMaxAssertion() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); + $this->expectExceptionMessage('The value 4.3 is too big for path "foo". Should be less than or equal to 0.3'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\FloatNodeDefinition('foo'); + $def->max(0.3)->getNode()->finalize(4.3); + } + public function testFloatValidMinMaxAssertion() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\FloatNodeDefinition('foo'); + $node = $def->min(3.0)->max(700.0)->getNode(); + $this->assertEquals(4.5, $node->finalize(4.5)); + } + public function testCannotBeEmptyThrowsAnException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidDefinitionException'); + $this->expectExceptionMessage('->cannotBeEmpty() is not applicable to NumericNodeDefinition.'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\IntegerNodeDefinition('foo'); + $def->cannotBeEmpty(); + } +} diff --git a/vendor/symfony/config/Tests/Definition/Builder/TreeBuilderTest.php b/vendor/symfony/config/Tests/Definition/Builder/TreeBuilderTest.php index 83e302c3e..5b426636a 100644 --- a/vendor/symfony/config/Tests/Definition/Builder/TreeBuilderTest.php +++ b/vendor/symfony/config/Tests/Definition/Builder/TreeBuilderTest.php @@ -1,83 +1,83 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder as CustomNodeBuilder; -class TreeBuilderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testUsingACustomNodeBuilder() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $root = $builder->root('custom', 'array', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder()); - $nodeBuilder = $root->children(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\Builder\\NodeBuilder', $nodeBuilder); - $nodeBuilder = $nodeBuilder->arrayNode('deeper')->children(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\Builder\\NodeBuilder', $nodeBuilder); - } - public function testOverrideABuiltInNodeType() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $root = $builder->root('override', 'array', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder()); - $definition = $root->children()->variableNode('variable'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\Builder\\VariableNodeDefinition', $definition); - } - public function testAddANodeType() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $root = $builder->root('override', 'array', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder()); - $definition = $root->children()->barNode('variable'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\Builder\\BarNodeDefinition', $definition); - } - public function testCreateABuiltInNodeTypeWithACustomNodeBuilder() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $root = $builder->root('builtin', 'array', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder()); - $definition = $root->children()->booleanNode('boolean'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\BooleanNodeDefinition', $definition); - } - public function testPrototypedArrayNodeUseTheCustomNodeBuilder() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $root = $builder->root('override', 'array', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder()); - $root->prototype('bar')->end(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\BarNode', $root->getNode(\true)->getPrototype()); - } - public function testAnExtendedNodeBuilderGetsPropagatedToTheChildren() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $builder->root('propagation')->children()->setNodeClass('extended', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\BooleanNodeDefinition')->node('foo', 'extended')->end()->arrayNode('child')->children()->node('foo', 'extended')->end()->end()->end()->end(); - $node = $builder->buildTree(); - $children = $node->getChildren(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BooleanNode', $children['foo']); - $childChildren = $children['child']->getChildren(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BooleanNode', $childChildren['foo']); - } - public function testDefinitionInfoGetsTransferredToNode() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $builder->root('test')->info('root info')->children()->node('child', 'variable')->info('child info')->defaultValue('default')->end()->end(); - $tree = $builder->buildTree(); - $children = $tree->getChildren(); - $this->assertEquals('root info', $tree->getInfo()); - $this->assertEquals('child info', $children['child']->getInfo()); - } - public function testDefinitionExampleGetsTransferredToNode() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $builder->root('test')->example(['key' => 'value'])->children()->node('child', 'variable')->info('child info')->defaultValue('default')->example('example')->end()->end(); - $tree = $builder->buildTree(); - $children = $tree->getChildren(); - $this->assertIsArray($tree->getExample()); - $this->assertEquals('example', $children['child']->getExample()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Builder; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder as CustomNodeBuilder; +class TreeBuilderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testUsingACustomNodeBuilder() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $root = $builder->root('custom', 'array', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder()); + $nodeBuilder = $root->children(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\Builder\\NodeBuilder', $nodeBuilder); + $nodeBuilder = $nodeBuilder->arrayNode('deeper')->children(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\Builder\\NodeBuilder', $nodeBuilder); + } + public function testOverrideABuiltInNodeType() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $root = $builder->root('override', 'array', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder()); + $definition = $root->children()->variableNode('variable'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\Builder\\VariableNodeDefinition', $definition); + } + public function testAddANodeType() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $root = $builder->root('override', 'array', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder()); + $definition = $root->children()->barNode('variable'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\Builder\\BarNodeDefinition', $definition); + } + public function testCreateABuiltInNodeTypeWithACustomNodeBuilder() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $root = $builder->root('builtin', 'array', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder()); + $definition = $root->children()->booleanNode('boolean'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\BooleanNodeDefinition', $definition); + } + public function testPrototypedArrayNodeUseTheCustomNodeBuilder() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $root = $builder->root('override', 'array', new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder\NodeBuilder()); + $root->prototype('bar')->end(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\BarNode', $root->getNode(\true)->getPrototype()); + } + public function testAnExtendedNodeBuilderGetsPropagatedToTheChildren() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $builder->root('propagation')->children()->setNodeClass('extended', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Builder\\BooleanNodeDefinition')->node('foo', 'extended')->end()->arrayNode('child')->children()->node('foo', 'extended')->end()->end()->end()->end(); + $node = $builder->buildTree(); + $children = $node->getChildren(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BooleanNode', $children['foo']); + $childChildren = $children['child']->getChildren(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\BooleanNode', $childChildren['foo']); + } + public function testDefinitionInfoGetsTransferredToNode() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $builder->root('test')->info('root info')->children()->node('child', 'variable')->info('child info')->defaultValue('default')->end()->end(); + $tree = $builder->buildTree(); + $children = $tree->getChildren(); + $this->assertEquals('root info', $tree->getInfo()); + $this->assertEquals('child info', $children['child']->getInfo()); + } + public function testDefinitionExampleGetsTransferredToNode() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $builder->root('test')->example(['key' => 'value'])->children()->node('child', 'variable')->info('child info')->defaultValue('default')->example('example')->end()->end(); + $tree = $builder->buildTree(); + $children = $tree->getChildren(); + $this->assertIsArray($tree->getExample()); + $this->assertEquals('example', $children['child']->getExample()); + } +} diff --git a/vendor/symfony/config/Tests/Definition/Builder/index.php b/vendor/symfony/config/Tests/Definition/Builder/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Definition/Builder/index.php +++ b/vendor/symfony/config/Tests/Definition/Builder/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Definition/Dumper/XmlReferenceDumperTest.php b/vendor/symfony/config/Tests/Definition/Dumper/XmlReferenceDumperTest.php index 4cfa7e8b2..fc1bce0bf 100644 --- a/vendor/symfony/config/Tests/Definition/Dumper/XmlReferenceDumperTest.php +++ b/vendor/symfony/config/Tests/Definition/Dumper/XmlReferenceDumperTest.php @@ -1,108 +1,108 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Dumper; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper\XmlReferenceDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Configuration\ExampleConfiguration; -class XmlReferenceDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testDumper() - { - $configuration = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Configuration\ExampleConfiguration(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper\XmlReferenceDumper(); - $this->assertEquals($this->getConfigurationAsString(), $dumper->dump($configuration)); - } - public function testNamespaceDumper() - { - $configuration = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Configuration\ExampleConfiguration(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper\XmlReferenceDumper(); - $this->assertEquals(\str_replace('http://example.org/schema/dic/acme_root', 'http://symfony.com/schema/dic/symfony', $this->getConfigurationAsString()), $dumper->dump($configuration, 'http://symfony.com/schema/dic/symfony')); - } - private function getConfigurationAsString() - { - return \str_replace("\n", \PHP_EOL, <<<'EOL' - - - - - - - - - - - - - - scalar value - - - scalar value - - - - - - - - - - - - - - - - - - - - - - - - -EOL -); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Dumper; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper\XmlReferenceDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Configuration\ExampleConfiguration; +class XmlReferenceDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testDumper() + { + $configuration = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Configuration\ExampleConfiguration(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper\XmlReferenceDumper(); + $this->assertEquals($this->getConfigurationAsString(), $dumper->dump($configuration)); + } + public function testNamespaceDumper() + { + $configuration = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Configuration\ExampleConfiguration(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper\XmlReferenceDumper(); + $this->assertEquals(\str_replace('http://example.org/schema/dic/acme_root', 'http://symfony.com/schema/dic/symfony', $this->getConfigurationAsString()), $dumper->dump($configuration, 'http://symfony.com/schema/dic/symfony')); + } + private function getConfigurationAsString() + { + return \str_replace("\n", \PHP_EOL, <<<'EOL' + + + + + + + + + + + + + + scalar value + + + scalar value + + + + + + + + + + + + + + + + + + + + + + + + +EOL +); + } +} diff --git a/vendor/symfony/config/Tests/Definition/Dumper/YamlReferenceDumperTest.php b/vendor/symfony/config/Tests/Definition/Dumper/YamlReferenceDumperTest.php index d94c376b0..c33c0814e 100644 --- a/vendor/symfony/config/Tests/Definition/Dumper/YamlReferenceDumperTest.php +++ b/vendor/symfony/config/Tests/Definition/Dumper/YamlReferenceDumperTest.php @@ -1,128 +1,128 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Dumper; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper\YamlReferenceDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Configuration\ExampleConfiguration; -class YamlReferenceDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testDumper() - { - $configuration = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Configuration\ExampleConfiguration(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper\YamlReferenceDumper(); - $this->assertEquals($this->getConfigurationAsString(), $dumper->dump($configuration)); - } - public function provideDumpAtPath() - { - return ['Regular node' => ['scalar_true', << ['array', << ['array.child2', << ['cms_pages.page', << ['cms_pages.page.locale', <<assertSame(\trim($expected), \trim($dumper->dumpAtPath($configuration, $path))); - } - private function getConfigurationAsString() - { - return <<<'EOL' -acme_root: - boolean: true - scalar_empty: ~ - scalar_null: null - scalar_true: true - scalar_false: false - scalar_default: default - scalar_array_empty: [] - scalar_array_defaults: - - # Defaults: - - elem1 - - elem2 - scalar_required: ~ # Required - scalar_deprecated: ~ # Deprecated (The child node "scalar_deprecated" at path "acme_root" is deprecated.) - scalar_deprecated_with_message: ~ # Deprecated (Deprecation custom message for "scalar_deprecated_with_message" at "acme_root") - node_with_a_looong_name: ~ - enum_with_default: this # One of "this"; "that" - enum: ~ # One of "this"; "that" - - # some info - array: - child1: ~ - child2: ~ - - # this is a long - # multi-line info text - # which should be indented - child3: ~ # Example: example setting - scalar_prototyped: [] - parameters: - - # Prototype: Parameter name - name: ~ - connections: - - # Prototype - - - user: ~ - pass: ~ - cms_pages: - - # Prototype - page: - - # Prototype - locale: - title: ~ # Required - path: ~ # Required - pipou: - - # Prototype - name: [] - -EOL; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition\Dumper; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper\YamlReferenceDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Configuration\ExampleConfiguration; +class YamlReferenceDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testDumper() + { + $configuration = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Configuration\ExampleConfiguration(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Dumper\YamlReferenceDumper(); + $this->assertEquals($this->getConfigurationAsString(), $dumper->dump($configuration)); + } + public function provideDumpAtPath() + { + return ['Regular node' => ['scalar_true', << ['array', << ['array.child2', << ['cms_pages.page', << ['cms_pages.page.locale', <<assertSame(\trim($expected), \trim($dumper->dumpAtPath($configuration, $path))); + } + private function getConfigurationAsString() + { + return <<<'EOL' +acme_root: + boolean: true + scalar_empty: ~ + scalar_null: null + scalar_true: true + scalar_false: false + scalar_default: default + scalar_array_empty: [] + scalar_array_defaults: + + # Defaults: + - elem1 + - elem2 + scalar_required: ~ # Required + scalar_deprecated: ~ # Deprecated (The child node "scalar_deprecated" at path "acme_root" is deprecated.) + scalar_deprecated_with_message: ~ # Deprecated (Deprecation custom message for "scalar_deprecated_with_message" at "acme_root") + node_with_a_looong_name: ~ + enum_with_default: this # One of "this"; "that" + enum: ~ # One of "this"; "that" + + # some info + array: + child1: ~ + child2: ~ + + # this is a long + # multi-line info text + # which should be indented + child3: ~ # Example: example setting + scalar_prototyped: [] + parameters: + + # Prototype: Parameter name + name: ~ + connections: + + # Prototype + - + user: ~ + pass: ~ + cms_pages: + + # Prototype + page: + + # Prototype + locale: + title: ~ # Required + path: ~ # Required + pipou: + + # Prototype + name: [] + +EOL; + } +} diff --git a/vendor/symfony/config/Tests/Definition/Dumper/index.php b/vendor/symfony/config/Tests/Definition/Dumper/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Definition/Dumper/index.php +++ b/vendor/symfony/config/Tests/Definition/Dumper/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Definition/EnumNodeTest.php b/vendor/symfony/config/Tests/Definition/EnumNodeTest.php index 91dc149fe..8184c26d6 100644 --- a/vendor/symfony/config/Tests/Definition/EnumNodeTest.php +++ b/vendor/symfony/config/Tests/Definition/EnumNodeTest.php @@ -1,45 +1,45 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode; -class EnumNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testFinalizeValue() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode('foo', null, ['foo', 'bar']); - $this->assertSame('foo', $node->finalize('foo')); - } - public function testConstructionWithNoValues() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('$values must contain at least one element.'); - new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode('foo', null, []); - } - public function testConstructionWithOneValue() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode('foo', null, ['foo']); - $this->assertSame('foo', $node->finalize('foo')); - } - public function testConstructionWithOneDistinctValue() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode('foo', null, ['foo', 'foo']); - $this->assertSame('foo', $node->finalize('foo')); - } - public function testFinalizeWithInvalidValue() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); - $this->expectExceptionMessage('The value "foobar" is not allowed for path "foo". Permissible values: "foo", "bar"'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode('foo', null, ['foo', 'bar']); - $node->finalize('foobar'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode; +class EnumNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testFinalizeValue() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode('foo', null, ['foo', 'bar']); + $this->assertSame('foo', $node->finalize('foo')); + } + public function testConstructionWithNoValues() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('$values must contain at least one element.'); + new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode('foo', null, []); + } + public function testConstructionWithOneValue() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode('foo', null, ['foo']); + $this->assertSame('foo', $node->finalize('foo')); + } + public function testConstructionWithOneDistinctValue() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode('foo', null, ['foo', 'foo']); + $this->assertSame('foo', $node->finalize('foo')); + } + public function testFinalizeWithInvalidValue() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); + $this->expectExceptionMessage('The value "foobar" is not allowed for path "foo". Permissible values: "foo", "bar"'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\EnumNode('foo', null, ['foo', 'bar']); + $node->finalize('foobar'); + } +} diff --git a/vendor/symfony/config/Tests/Definition/FinalizationTest.php b/vendor/symfony/config/Tests/Definition/FinalizationTest.php index d177abcc9..b95d9cb95 100644 --- a/vendor/symfony/config/Tests/Definition/FinalizationTest.php +++ b/vendor/symfony/config/Tests/Definition/FinalizationTest.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor; -class FinalizationTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testUnsetKeyWithDeepHierarchy() - { - $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $tree = $tb->root('config', 'array')->children()->node('level1', 'array')->canBeUnset()->children()->node('level2', 'array')->canBeUnset()->children()->node('somevalue', 'scalar')->end()->node('anothervalue', 'scalar')->end()->end()->end()->node('level1_scalar', 'scalar')->end()->end()->end()->end()->end()->buildTree(); - $a = ['level1' => ['level2' => ['somevalue' => 'foo', 'anothervalue' => 'bar'], 'level1_scalar' => 'foo']]; - $b = ['level1' => ['level2' => \false]]; - $this->assertEquals(['level1' => ['level1_scalar' => 'foo']], $this->process($tree, [$a, $b])); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $tree, array $configs) - { - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor(); - return $processor->process($tree, $configs); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor; +class FinalizationTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testUnsetKeyWithDeepHierarchy() + { + $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $tree = $tb->root('config', 'array')->children()->node('level1', 'array')->canBeUnset()->children()->node('level2', 'array')->canBeUnset()->children()->node('somevalue', 'scalar')->end()->node('anothervalue', 'scalar')->end()->end()->end()->node('level1_scalar', 'scalar')->end()->end()->end()->end()->end()->buildTree(); + $a = ['level1' => ['level2' => ['somevalue' => 'foo', 'anothervalue' => 'bar'], 'level1_scalar' => 'foo']]; + $b = ['level1' => ['level2' => \false]]; + $this->assertEquals(['level1' => ['level1_scalar' => 'foo']], $this->process($tree, [$a, $b])); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $tree, array $configs) + { + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor(); + return $processor->process($tree, $configs); + } +} diff --git a/vendor/symfony/config/Tests/Definition/FloatNodeTest.php b/vendor/symfony/config/Tests/Definition/FloatNodeTest.php index 31050e15f..75518d407 100644 --- a/vendor/symfony/config/Tests/Definition/FloatNodeTest.php +++ b/vendor/symfony/config/Tests/Definition/FloatNodeTest.php @@ -1,62 +1,62 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode; -class FloatNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @dataProvider getValidValues - */ - public function testNormalize($value) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode('test'); - $this->assertSame($value, $node->normalize($value)); - } - /** - * @dataProvider getValidValues - * - * @param int $value - */ - public function testValidNonEmptyValues($value) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode('test'); - $node->setAllowEmptyValue(\false); - $this->assertSame($value, $node->finalize($value)); - } - public function getValidValues() - { - return [ - [1798.0], - [-678.987], - [1.256E+46], - [0.0], - // Integer are accepted too, they will be cast - [17], - [-10], - [0], - ]; - } - /** - * @dataProvider getInvalidValues - */ - public function testNormalizeThrowsExceptionOnInvalidValues($value) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode('test'); - $node->normalize($value); - } - public function getInvalidValues() - { - return [[null], [''], ['foo'], [\true], [\false], [[]], [['foo' => 'bar']], [new \stdClass()]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode; +class FloatNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @dataProvider getValidValues + */ + public function testNormalize($value) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode('test'); + $this->assertSame($value, $node->normalize($value)); + } + /** + * @dataProvider getValidValues + * + * @param int $value + */ + public function testValidNonEmptyValues($value) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode('test'); + $node->setAllowEmptyValue(\false); + $this->assertSame($value, $node->finalize($value)); + } + public function getValidValues() + { + return [ + [1798.0], + [-678.987], + [1.256E+46], + [0.0], + // Integer are accepted too, they will be cast + [17], + [-10], + [0], + ]; + } + /** + * @dataProvider getInvalidValues + */ + public function testNormalizeThrowsExceptionOnInvalidValues($value) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\FloatNode('test'); + $node->normalize($value); + } + public function getInvalidValues() + { + return [[null], [''], ['foo'], [\true], [\false], [[]], [['foo' => 'bar']], [new \stdClass()]]; + } +} diff --git a/vendor/symfony/config/Tests/Definition/IntegerNodeTest.php b/vendor/symfony/config/Tests/Definition/IntegerNodeTest.php index 433d39936..2e9d19efb 100644 --- a/vendor/symfony/config/Tests/Definition/IntegerNodeTest.php +++ b/vendor/symfony/config/Tests/Definition/IntegerNodeTest.php @@ -1,53 +1,53 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode; -class IntegerNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @dataProvider getValidValues - */ - public function testNormalize($value) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode('test'); - $this->assertSame($value, $node->normalize($value)); - } - /** - * @dataProvider getValidValues - * - * @param int $value - */ - public function testValidNonEmptyValues($value) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode('test'); - $node->setAllowEmptyValue(\false); - $this->assertSame($value, $node->finalize($value)); - } - public function getValidValues() - { - return [[1798], [-678], [0]]; - } - /** - * @dataProvider getInvalidValues - */ - public function testNormalizeThrowsExceptionOnInvalidValues($value) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode('test'); - $node->normalize($value); - } - public function getInvalidValues() - { - return [[null], [''], ['foo'], [\true], [\false], [0.0], [0.1], [[]], [['foo' => 'bar']], [new \stdClass()]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode; +class IntegerNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @dataProvider getValidValues + */ + public function testNormalize($value) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode('test'); + $this->assertSame($value, $node->normalize($value)); + } + /** + * @dataProvider getValidValues + * + * @param int $value + */ + public function testValidNonEmptyValues($value) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode('test'); + $node->setAllowEmptyValue(\false); + $this->assertSame($value, $node->finalize($value)); + } + public function getValidValues() + { + return [[1798], [-678], [0]]; + } + /** + * @dataProvider getInvalidValues + */ + public function testNormalizeThrowsExceptionOnInvalidValues($value) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\IntegerNode('test'); + $node->normalize($value); + } + public function getInvalidValues() + { + return [[null], [''], ['foo'], [\true], [\false], [0.0], [0.1], [[]], [['foo' => 'bar']], [new \stdClass()]]; + } +} diff --git a/vendor/symfony/config/Tests/Definition/MergeTest.php b/vendor/symfony/config/Tests/Definition/MergeTest.php index 8476c407a..f8959ffa7 100644 --- a/vendor/symfony/config/Tests/Definition/MergeTest.php +++ b/vendor/symfony/config/Tests/Definition/MergeTest.php @@ -1,59 +1,59 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; -class MergeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testForbiddenOverwrite() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\ForbiddenOverwriteException'); - $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $tree = $tb->root('root', 'array')->children()->node('foo', 'scalar')->cannotBeOverwritten()->end()->end()->end()->buildTree(); - $a = ['foo' => 'bar']; - $b = ['foo' => 'moo']; - $tree->merge($a, $b); - } - public function testUnsetKey() - { - $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $tree = $tb->root('root', 'array')->children()->node('foo', 'scalar')->end()->node('bar', 'scalar')->end()->node('unsettable', 'array')->canBeUnset()->children()->node('foo', 'scalar')->end()->node('bar', 'scalar')->end()->end()->end()->node('unsetted', 'array')->canBeUnset()->prototype('scalar')->end()->end()->end()->end()->buildTree(); - $a = ['foo' => 'bar', 'unsettable' => ['foo' => 'a', 'bar' => 'b'], 'unsetted' => \false]; - $b = ['foo' => 'moo', 'bar' => 'b', 'unsettable' => \false, 'unsetted' => ['a', 'b']]; - $this->assertEquals(['foo' => 'moo', 'bar' => 'b', 'unsettable' => \false, 'unsetted' => ['a', 'b']], $tree->merge($a, $b)); - } - public function testDoesNotAllowNewKeysInSubsequentConfigs() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); - $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $tree = $tb->root('config', 'array')->children()->node('test', 'array')->disallowNewKeysInSubsequentConfigs()->useAttributeAsKey('key')->prototype('array')->children()->node('value', 'scalar')->end()->end()->end()->end()->end()->end()->buildTree(); - $a = ['test' => ['a' => ['value' => 'foo']]]; - $b = ['test' => ['b' => ['value' => 'foo']]]; - $tree->merge($a, $b); - } - public function testPerformsNoDeepMerging() - { - $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $tree = $tb->root('config', 'array')->children()->node('no_deep_merging', 'array')->performNoDeepMerging()->children()->node('foo', 'scalar')->end()->node('bar', 'scalar')->end()->end()->end()->end()->end()->buildTree(); - $a = ['no_deep_merging' => ['foo' => 'a', 'bar' => 'b']]; - $b = ['no_deep_merging' => ['c' => 'd']]; - $this->assertEquals(['no_deep_merging' => ['c' => 'd']], $tree->merge($a, $b)); - } - public function testPrototypeWithoutAKeyAttribute() - { - $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $tree = $tb->root('config', 'array')->children()->arrayNode('append_elements')->prototype('scalar')->end()->end()->end()->end()->buildTree(); - $a = ['append_elements' => ['a', 'b']]; - $b = ['append_elements' => ['c', 'd']]; - $this->assertEquals(['append_elements' => ['a', 'b', 'c', 'd']], $tree->merge($a, $b)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; +class MergeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testForbiddenOverwrite() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\ForbiddenOverwriteException'); + $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $tree = $tb->root('root', 'array')->children()->node('foo', 'scalar')->cannotBeOverwritten()->end()->end()->end()->buildTree(); + $a = ['foo' => 'bar']; + $b = ['foo' => 'moo']; + $tree->merge($a, $b); + } + public function testUnsetKey() + { + $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $tree = $tb->root('root', 'array')->children()->node('foo', 'scalar')->end()->node('bar', 'scalar')->end()->node('unsettable', 'array')->canBeUnset()->children()->node('foo', 'scalar')->end()->node('bar', 'scalar')->end()->end()->end()->node('unsetted', 'array')->canBeUnset()->prototype('scalar')->end()->end()->end()->end()->buildTree(); + $a = ['foo' => 'bar', 'unsettable' => ['foo' => 'a', 'bar' => 'b'], 'unsetted' => \false]; + $b = ['foo' => 'moo', 'bar' => 'b', 'unsettable' => \false, 'unsetted' => ['a', 'b']]; + $this->assertEquals(['foo' => 'moo', 'bar' => 'b', 'unsettable' => \false, 'unsetted' => ['a', 'b']], $tree->merge($a, $b)); + } + public function testDoesNotAllowNewKeysInSubsequentConfigs() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); + $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $tree = $tb->root('config', 'array')->children()->node('test', 'array')->disallowNewKeysInSubsequentConfigs()->useAttributeAsKey('key')->prototype('array')->children()->node('value', 'scalar')->end()->end()->end()->end()->end()->end()->buildTree(); + $a = ['test' => ['a' => ['value' => 'foo']]]; + $b = ['test' => ['b' => ['value' => 'foo']]]; + $tree->merge($a, $b); + } + public function testPerformsNoDeepMerging() + { + $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $tree = $tb->root('config', 'array')->children()->node('no_deep_merging', 'array')->performNoDeepMerging()->children()->node('foo', 'scalar')->end()->node('bar', 'scalar')->end()->end()->end()->end()->end()->buildTree(); + $a = ['no_deep_merging' => ['foo' => 'a', 'bar' => 'b']]; + $b = ['no_deep_merging' => ['c' => 'd']]; + $this->assertEquals(['no_deep_merging' => ['c' => 'd']], $tree->merge($a, $b)); + } + public function testPrototypeWithoutAKeyAttribute() + { + $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $tree = $tb->root('config', 'array')->children()->arrayNode('append_elements')->prototype('scalar')->end()->end()->end()->end()->buildTree(); + $a = ['append_elements' => ['a', 'b']]; + $b = ['append_elements' => ['c', 'd']]; + $this->assertEquals(['append_elements' => ['a', 'b', 'c', 'd']], $tree->merge($a, $b)); + } +} diff --git a/vendor/symfony/config/Tests/Definition/NormalizationTest.php b/vendor/symfony/config/Tests/Definition/NormalizationTest.php index 725d9a052..2e1b77add 100644 --- a/vendor/symfony/config/Tests/Definition/NormalizationTest.php +++ b/vendor/symfony/config/Tests/Definition/NormalizationTest.php @@ -1,107 +1,107 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; -class NormalizationTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @dataProvider getEncoderTests - */ - public function testNormalizeEncoders($denormalized) - { - $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $tree = $tb->root('root_name', 'array')->fixXmlConfig('encoder')->children()->node('encoders', 'array')->useAttributeAsKey('class')->prototype('array')->beforeNormalization()->ifString()->then(function ($v) { - return ['algorithm' => $v]; - })->end()->children()->node('algorithm', 'scalar')->end()->end()->end()->end()->end()->end()->buildTree(); - $normalized = ['encoders' => ['foo' => ['algorithm' => 'plaintext']]]; - $this->assertNormalized($tree, $denormalized, $normalized); - } - public function getEncoderTests() - { - $configs = []; - // XML - $configs[] = ['encoder' => [['class' => 'foo', 'algorithm' => 'plaintext']]]; - // XML when only one element of this type - $configs[] = ['encoder' => ['class' => 'foo', 'algorithm' => 'plaintext']]; - // YAML/PHP - $configs[] = ['encoders' => [['class' => 'foo', 'algorithm' => 'plaintext']]]; - // YAML/PHP - $configs[] = ['encoders' => ['foo' => 'plaintext']]; - // YAML/PHP - $configs[] = ['encoders' => ['foo' => ['algorithm' => 'plaintext']]]; - return \array_map(function ($v) { - return [$v]; - }, $configs); - } - /** - * @dataProvider getAnonymousKeysTests - */ - public function testAnonymousKeysArray($denormalized) - { - $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $tree = $tb->root('root', 'array')->children()->node('logout', 'array')->fixXmlConfig('handler')->children()->node('handlers', 'array')->prototype('scalar')->end()->end()->end()->end()->end()->end()->buildTree(); - $normalized = ['logout' => ['handlers' => ['a', 'b', 'c']]]; - $this->assertNormalized($tree, $denormalized, $normalized); - } - public function getAnonymousKeysTests() - { - $configs = []; - $configs[] = ['logout' => ['handlers' => ['a', 'b', 'c']]]; - $configs[] = ['logout' => ['handler' => ['a', 'b', 'c']]]; - return \array_map(function ($v) { - return [$v]; - }, $configs); - } - /** - * @dataProvider getNumericKeysTests - */ - public function testNumericKeysAsAttributes($denormalized) - { - $normalized = ['thing' => [42 => ['foo', 'bar'], 1337 => ['baz', 'qux']]]; - $this->assertNormalized($this->getNumericKeysTestTree(), $denormalized, $normalized); - } - public function getNumericKeysTests() - { - $configs = []; - $configs[] = ['thing' => [42 => ['foo', 'bar'], 1337 => ['baz', 'qux']]]; - $configs[] = ['thing' => [['foo', 'bar', 'id' => 42], ['baz', 'qux', 'id' => 1337]]]; - return \array_map(function ($v) { - return [$v]; - }, $configs); - } - public function testNonAssociativeArrayThrowsExceptionIfAttributeNotSet() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); - $this->expectExceptionMessage('The attribute "id" must be set for path "root.thing".'); - $denormalized = ['thing' => [['foo', 'bar'], ['baz', 'qux']]]; - $this->assertNormalized($this->getNumericKeysTestTree(), $denormalized, []); - } - public function testAssociativeArrayPreserveKeys() - { - $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $tree = $tb->root('root', 'array')->prototype('array')->children()->node('foo', 'scalar')->end()->end()->end()->end()->buildTree(); - $data = ['first' => ['foo' => 'bar']]; - $this->assertNormalized($tree, $data, $data); - } - public static function assertNormalized(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $tree, $denormalized, $normalized) - { - self::assertSame($normalized, $tree->normalize($denormalized)); - } - private function getNumericKeysTestTree() - { - $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $tree = $tb->root('root', 'array')->children()->node('thing', 'array')->useAttributeAsKey('id')->prototype('array')->prototype('scalar')->end()->end()->end()->end()->end()->buildTree(); - return $tree; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface; +class NormalizationTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @dataProvider getEncoderTests + */ + public function testNormalizeEncoders($denormalized) + { + $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $tree = $tb->root('root_name', 'array')->fixXmlConfig('encoder')->children()->node('encoders', 'array')->useAttributeAsKey('class')->prototype('array')->beforeNormalization()->ifString()->then(function ($v) { + return ['algorithm' => $v]; + })->end()->children()->node('algorithm', 'scalar')->end()->end()->end()->end()->end()->end()->buildTree(); + $normalized = ['encoders' => ['foo' => ['algorithm' => 'plaintext']]]; + $this->assertNormalized($tree, $denormalized, $normalized); + } + public function getEncoderTests() + { + $configs = []; + // XML + $configs[] = ['encoder' => [['class' => 'foo', 'algorithm' => 'plaintext']]]; + // XML when only one element of this type + $configs[] = ['encoder' => ['class' => 'foo', 'algorithm' => 'plaintext']]; + // YAML/PHP + $configs[] = ['encoders' => [['class' => 'foo', 'algorithm' => 'plaintext']]]; + // YAML/PHP + $configs[] = ['encoders' => ['foo' => 'plaintext']]; + // YAML/PHP + $configs[] = ['encoders' => ['foo' => ['algorithm' => 'plaintext']]]; + return \array_map(function ($v) { + return [$v]; + }, $configs); + } + /** + * @dataProvider getAnonymousKeysTests + */ + public function testAnonymousKeysArray($denormalized) + { + $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $tree = $tb->root('root', 'array')->children()->node('logout', 'array')->fixXmlConfig('handler')->children()->node('handlers', 'array')->prototype('scalar')->end()->end()->end()->end()->end()->end()->buildTree(); + $normalized = ['logout' => ['handlers' => ['a', 'b', 'c']]]; + $this->assertNormalized($tree, $denormalized, $normalized); + } + public function getAnonymousKeysTests() + { + $configs = []; + $configs[] = ['logout' => ['handlers' => ['a', 'b', 'c']]]; + $configs[] = ['logout' => ['handler' => ['a', 'b', 'c']]]; + return \array_map(function ($v) { + return [$v]; + }, $configs); + } + /** + * @dataProvider getNumericKeysTests + */ + public function testNumericKeysAsAttributes($denormalized) + { + $normalized = ['thing' => [42 => ['foo', 'bar'], 1337 => ['baz', 'qux']]]; + $this->assertNormalized($this->getNumericKeysTestTree(), $denormalized, $normalized); + } + public function getNumericKeysTests() + { + $configs = []; + $configs[] = ['thing' => [42 => ['foo', 'bar'], 1337 => ['baz', 'qux']]]; + $configs[] = ['thing' => [['foo', 'bar', 'id' => 42], ['baz', 'qux', 'id' => 1337]]]; + return \array_map(function ($v) { + return [$v]; + }, $configs); + } + public function testNonAssociativeArrayThrowsExceptionIfAttributeNotSet() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); + $this->expectExceptionMessage('The attribute "id" must be set for path "root.thing".'); + $denormalized = ['thing' => [['foo', 'bar'], ['baz', 'qux']]]; + $this->assertNormalized($this->getNumericKeysTestTree(), $denormalized, []); + } + public function testAssociativeArrayPreserveKeys() + { + $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $tree = $tb->root('root', 'array')->prototype('array')->children()->node('foo', 'scalar')->end()->end()->end()->end()->buildTree(); + $data = ['first' => ['foo' => 'bar']]; + $this->assertNormalized($tree, $data, $data); + } + public static function assertNormalized(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\NodeInterface $tree, $denormalized, $normalized) + { + self::assertSame($normalized, $tree->normalize($denormalized)); + } + private function getNumericKeysTestTree() + { + $tb = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $tree = $tb->root('root', 'array')->children()->node('thing', 'array')->useAttributeAsKey('id')->prototype('array')->prototype('scalar')->end()->end()->end()->end()->end()->buildTree(); + return $tree; + } +} diff --git a/vendor/symfony/config/Tests/Definition/PrototypedArrayNodeTest.php b/vendor/symfony/config/Tests/Definition/PrototypedArrayNodeTest.php index aaa300d2e..cbdc4594f 100644 --- a/vendor/symfony/config/Tests/Definition/PrototypedArrayNodeTest.php +++ b/vendor/symfony/config/Tests/Definition/PrototypedArrayNodeTest.php @@ -1,264 +1,264 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\VariableNode; -class PrototypedArrayNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testGetDefaultValueReturnsAnEmptyArrayForPrototypes() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); - $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); - $node->setPrototype($prototype); - $this->assertEmpty($node->getDefaultValue()); - } - public function testGetDefaultValueReturnsDefaultValueForPrototypes() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); - $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); - $node->setPrototype($prototype); - $node->setDefaultValue(['test']); - $this->assertEquals(['test'], $node->getDefaultValue()); - } - // a remapped key (e.g. "mapping" -> "mappings") should be unset after being used - public function testRemappedKeysAreUnset() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); - $mappingsNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('mappings'); - $node->addChild($mappingsNode); - // each item under mappings is just a scalar - $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode(null, $mappingsNode); - $mappingsNode->setPrototype($prototype); - $remappings = []; - $remappings[] = ['mapping', 'mappings']; - $node->setXmlRemappings($remappings); - $normalized = $node->normalize(['mapping' => ['foo', 'bar']]); - $this->assertEquals(['mappings' => ['foo', 'bar']], $normalized); - } - /** - * Tests that when a key attribute is mapped, that key is removed from the array. - * - * - * - * - * The above should finally be mapped to an array that looks like this - * (because "id" is the key attribute). - * - * [ - * 'things' => [ - * 'option1' => 'foo', - * 'option2' => 'bar', - * ] - * ] - */ - public function testMappedAttributeKeyIsRemoved() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); - $node->setKeyAttribute('id', \true); - // each item under the root is an array, with one scalar item - $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); - $prototype->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo')); - $node->setPrototype($prototype); - $children = []; - $children[] = ['id' => 'item_name', 'foo' => 'bar']; - $normalized = $node->normalize($children); - $expected = []; - $expected['item_name'] = ['foo' => 'bar']; - $this->assertEquals($expected, $normalized); - } - /** - * Tests the opposite of the testMappedAttributeKeyIsRemoved because - * the removal can be toggled with an option. - */ - public function testMappedAttributeKeyNotRemoved() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); - $node->setKeyAttribute('id', \false); - // each item under the root is an array, with two scalar items - $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); - $prototype->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo')); - $prototype->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('id')); - // the key attribute will remain - $node->setPrototype($prototype); - $children = []; - $children[] = ['id' => 'item_name', 'foo' => 'bar']; - $normalized = $node->normalize($children); - $expected = []; - $expected['item_name'] = ['id' => 'item_name', 'foo' => 'bar']; - $this->assertEquals($expected, $normalized); - } - public function testAddDefaultChildren() - { - $node = $this->getPrototypeNodeWithDefaultChildren(); - $node->setAddChildrenIfNoneSet(); - $this->assertTrue($node->hasDefaultValue()); - $this->assertEquals([['foo' => 'bar']], $node->getDefaultValue()); - $node = $this->getPrototypeNodeWithDefaultChildren(); - $node->setKeyAttribute('foobar'); - $node->setAddChildrenIfNoneSet(); - $this->assertTrue($node->hasDefaultValue()); - $this->assertEquals(['defaults' => ['foo' => 'bar']], $node->getDefaultValue()); - $node = $this->getPrototypeNodeWithDefaultChildren(); - $node->setKeyAttribute('foobar'); - $node->setAddChildrenIfNoneSet('defaultkey'); - $this->assertTrue($node->hasDefaultValue()); - $this->assertEquals(['defaultkey' => ['foo' => 'bar']], $node->getDefaultValue()); - $node = $this->getPrototypeNodeWithDefaultChildren(); - $node->setKeyAttribute('foobar'); - $node->setAddChildrenIfNoneSet(['defaultkey']); - $this->assertTrue($node->hasDefaultValue()); - $this->assertEquals(['defaultkey' => ['foo' => 'bar']], $node->getDefaultValue()); - $node = $this->getPrototypeNodeWithDefaultChildren(); - $node->setKeyAttribute('foobar'); - $node->setAddChildrenIfNoneSet(['dk1', 'dk2']); - $this->assertTrue($node->hasDefaultValue()); - $this->assertEquals(['dk1' => ['foo' => 'bar'], 'dk2' => ['foo' => 'bar']], $node->getDefaultValue()); - $node = $this->getPrototypeNodeWithDefaultChildren(); - $node->setAddChildrenIfNoneSet([5, 6]); - $this->assertTrue($node->hasDefaultValue()); - $this->assertEquals([0 => ['foo' => 'bar'], 1 => ['foo' => 'bar']], $node->getDefaultValue()); - $node = $this->getPrototypeNodeWithDefaultChildren(); - $node->setAddChildrenIfNoneSet(2); - $this->assertTrue($node->hasDefaultValue()); - $this->assertEquals([['foo' => 'bar'], ['foo' => 'bar']], $node->getDefaultValue()); - } - public function testDefaultChildrenWinsOverDefaultValue() - { - $node = $this->getPrototypeNodeWithDefaultChildren(); - $node->setAddChildrenIfNoneSet(); - $node->setDefaultValue(['bar' => 'foo']); - $this->assertTrue($node->hasDefaultValue()); - $this->assertEquals([['foo' => 'bar']], $node->getDefaultValue()); - } - protected function getPrototypeNodeWithDefaultChildren() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); - $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); - $child = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo'); - $child->setDefaultValue('bar'); - $prototype->addChild($child); - $prototype->setAddIfNotSet(\true); - $node->setPrototype($prototype); - return $node; - } - /** - * Tests that when a key attribute is mapped, that key is removed from the array. - * And if only 'value' element is left in the array, it will replace its wrapper array. - * - * - * - * - * The above should finally be mapped to an array that looks like this - * (because "id" is the key attribute). - * - * [ - * 'things' => [ - * 'option1' => 'value1' - * ] - * ] - * - * It's also possible to mix 'value-only' and 'non-value-only' elements in the array. - * - * - * - * - * The above should finally be mapped to an array as follows - * - * [ - * 'things' => [ - * 'option1' => 'value1', - * 'option2' => [ - * 'value' => 'value2', - * 'foo' => 'foo2' - * ] - * ] - * ] - * - * The 'value' element can also be ArrayNode: - * - * - * - * - * - * The above should be finally be mapped to an array as follows - * - * [ - * 'things' => [ - * 'option1' => [ - * 'foo' => 'foo1', - * 'bar' => 'bar1' - * ] - * ] - * ] - * - * If using VariableNode for value node, it's also possible to mix different types of value nodes: - * - * - * - * - * - * The above should be finally mapped to an array as follows - * - * [ - * 'things' => [ - * 'option1' => [ - * 'foo' => 'foo1', - * 'bar' => 'bar1' - * ], - * 'option2' => 'value2' - * ] - * ] - * - * @dataProvider getDataForKeyRemovedLeftValueOnly - */ - public function testMappedAttributeKeyIsRemovedLeftValueOnly($value, $children, $expected) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); - $node->setKeyAttribute('id', \true); - // each item under the root is an array, with one scalar item - $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); - $prototype->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('id')); - $prototype->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo')); - $prototype->addChild($value); - $node->setPrototype($prototype); - $normalized = $node->normalize($children); - $this->assertEquals($expected, $normalized); - } - public function getDataForKeyRemovedLeftValueOnly() - { - $scalarValue = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('value'); - $arrayValue = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('value'); - $arrayValue->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo')); - $arrayValue->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('bar')); - $variableValue = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\VariableNode('value'); - return [[$scalarValue, [['id' => 'option1', 'value' => 'value1']], ['option1' => 'value1']], [$scalarValue, [['id' => 'option1', 'value' => 'value1'], ['id' => 'option2', 'value' => 'value2', 'foo' => 'foo2']], ['option1' => 'value1', 'option2' => ['value' => 'value2', 'foo' => 'foo2']]], [$arrayValue, [['id' => 'option1', 'value' => ['foo' => 'foo1', 'bar' => 'bar1']]], ['option1' => ['foo' => 'foo1', 'bar' => 'bar1']]], [$variableValue, [['id' => 'option1', 'value' => ['foo' => 'foo1', 'bar' => 'bar1']], ['id' => 'option2', 'value' => 'value2']], ['option1' => ['foo' => 'foo1', 'bar' => 'bar1'], 'option2' => 'value2']]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\VariableNode; +class PrototypedArrayNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testGetDefaultValueReturnsAnEmptyArrayForPrototypes() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); + $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); + $node->setPrototype($prototype); + $this->assertEmpty($node->getDefaultValue()); + } + public function testGetDefaultValueReturnsDefaultValueForPrototypes() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); + $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); + $node->setPrototype($prototype); + $node->setDefaultValue(['test']); + $this->assertEquals(['test'], $node->getDefaultValue()); + } + // a remapped key (e.g. "mapping" -> "mappings") should be unset after being used + public function testRemappedKeysAreUnset() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); + $mappingsNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('mappings'); + $node->addChild($mappingsNode); + // each item under mappings is just a scalar + $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode(null, $mappingsNode); + $mappingsNode->setPrototype($prototype); + $remappings = []; + $remappings[] = ['mapping', 'mappings']; + $node->setXmlRemappings($remappings); + $normalized = $node->normalize(['mapping' => ['foo', 'bar']]); + $this->assertEquals(['mappings' => ['foo', 'bar']], $normalized); + } + /** + * Tests that when a key attribute is mapped, that key is removed from the array. + * + * + * + * + * The above should finally be mapped to an array that looks like this + * (because "id" is the key attribute). + * + * [ + * 'things' => [ + * 'option1' => 'foo', + * 'option2' => 'bar', + * ] + * ] + */ + public function testMappedAttributeKeyIsRemoved() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); + $node->setKeyAttribute('id', \true); + // each item under the root is an array, with one scalar item + $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); + $prototype->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo')); + $node->setPrototype($prototype); + $children = []; + $children[] = ['id' => 'item_name', 'foo' => 'bar']; + $normalized = $node->normalize($children); + $expected = []; + $expected['item_name'] = ['foo' => 'bar']; + $this->assertEquals($expected, $normalized); + } + /** + * Tests the opposite of the testMappedAttributeKeyIsRemoved because + * the removal can be toggled with an option. + */ + public function testMappedAttributeKeyNotRemoved() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); + $node->setKeyAttribute('id', \false); + // each item under the root is an array, with two scalar items + $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); + $prototype->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo')); + $prototype->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('id')); + // the key attribute will remain + $node->setPrototype($prototype); + $children = []; + $children[] = ['id' => 'item_name', 'foo' => 'bar']; + $normalized = $node->normalize($children); + $expected = []; + $expected['item_name'] = ['id' => 'item_name', 'foo' => 'bar']; + $this->assertEquals($expected, $normalized); + } + public function testAddDefaultChildren() + { + $node = $this->getPrototypeNodeWithDefaultChildren(); + $node->setAddChildrenIfNoneSet(); + $this->assertTrue($node->hasDefaultValue()); + $this->assertEquals([['foo' => 'bar']], $node->getDefaultValue()); + $node = $this->getPrototypeNodeWithDefaultChildren(); + $node->setKeyAttribute('foobar'); + $node->setAddChildrenIfNoneSet(); + $this->assertTrue($node->hasDefaultValue()); + $this->assertEquals(['defaults' => ['foo' => 'bar']], $node->getDefaultValue()); + $node = $this->getPrototypeNodeWithDefaultChildren(); + $node->setKeyAttribute('foobar'); + $node->setAddChildrenIfNoneSet('defaultkey'); + $this->assertTrue($node->hasDefaultValue()); + $this->assertEquals(['defaultkey' => ['foo' => 'bar']], $node->getDefaultValue()); + $node = $this->getPrototypeNodeWithDefaultChildren(); + $node->setKeyAttribute('foobar'); + $node->setAddChildrenIfNoneSet(['defaultkey']); + $this->assertTrue($node->hasDefaultValue()); + $this->assertEquals(['defaultkey' => ['foo' => 'bar']], $node->getDefaultValue()); + $node = $this->getPrototypeNodeWithDefaultChildren(); + $node->setKeyAttribute('foobar'); + $node->setAddChildrenIfNoneSet(['dk1', 'dk2']); + $this->assertTrue($node->hasDefaultValue()); + $this->assertEquals(['dk1' => ['foo' => 'bar'], 'dk2' => ['foo' => 'bar']], $node->getDefaultValue()); + $node = $this->getPrototypeNodeWithDefaultChildren(); + $node->setAddChildrenIfNoneSet([5, 6]); + $this->assertTrue($node->hasDefaultValue()); + $this->assertEquals([0 => ['foo' => 'bar'], 1 => ['foo' => 'bar']], $node->getDefaultValue()); + $node = $this->getPrototypeNodeWithDefaultChildren(); + $node->setAddChildrenIfNoneSet(2); + $this->assertTrue($node->hasDefaultValue()); + $this->assertEquals([['foo' => 'bar'], ['foo' => 'bar']], $node->getDefaultValue()); + } + public function testDefaultChildrenWinsOverDefaultValue() + { + $node = $this->getPrototypeNodeWithDefaultChildren(); + $node->setAddChildrenIfNoneSet(); + $node->setDefaultValue(['bar' => 'foo']); + $this->assertTrue($node->hasDefaultValue()); + $this->assertEquals([['foo' => 'bar']], $node->getDefaultValue()); + } + protected function getPrototypeNodeWithDefaultChildren() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); + $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); + $child = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo'); + $child->setDefaultValue('bar'); + $prototype->addChild($child); + $prototype->setAddIfNotSet(\true); + $node->setPrototype($prototype); + return $node; + } + /** + * Tests that when a key attribute is mapped, that key is removed from the array. + * And if only 'value' element is left in the array, it will replace its wrapper array. + * + * + * + * + * The above should finally be mapped to an array that looks like this + * (because "id" is the key attribute). + * + * [ + * 'things' => [ + * 'option1' => 'value1' + * ] + * ] + * + * It's also possible to mix 'value-only' and 'non-value-only' elements in the array. + * + * + * + * + * The above should finally be mapped to an array as follows + * + * [ + * 'things' => [ + * 'option1' => 'value1', + * 'option2' => [ + * 'value' => 'value2', + * 'foo' => 'foo2' + * ] + * ] + * ] + * + * The 'value' element can also be ArrayNode: + * + * + * + * + * + * The above should be finally be mapped to an array as follows + * + * [ + * 'things' => [ + * 'option1' => [ + * 'foo' => 'foo1', + * 'bar' => 'bar1' + * ] + * ] + * ] + * + * If using VariableNode for value node, it's also possible to mix different types of value nodes: + * + * + * + * + * + * The above should be finally mapped to an array as follows + * + * [ + * 'things' => [ + * 'option1' => [ + * 'foo' => 'foo1', + * 'bar' => 'bar1' + * ], + * 'option2' => 'value2' + * ] + * ] + * + * @dataProvider getDataForKeyRemovedLeftValueOnly + */ + public function testMappedAttributeKeyIsRemovedLeftValueOnly($value, $children, $expected) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\PrototypedArrayNode('root'); + $node->setKeyAttribute('id', \true); + // each item under the root is an array, with one scalar item + $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode(null, $node); + $prototype->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('id')); + $prototype->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo')); + $prototype->addChild($value); + $node->setPrototype($prototype); + $normalized = $node->normalize($children); + $this->assertEquals($expected, $normalized); + } + public function getDataForKeyRemovedLeftValueOnly() + { + $scalarValue = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('value'); + $arrayValue = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('value'); + $arrayValue->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo')); + $arrayValue->addChild(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('bar')); + $variableValue = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\VariableNode('value'); + return [[$scalarValue, [['id' => 'option1', 'value' => 'value1']], ['option1' => 'value1']], [$scalarValue, [['id' => 'option1', 'value' => 'value1'], ['id' => 'option2', 'value' => 'value2', 'foo' => 'foo2']], ['option1' => 'value1', 'option2' => ['value' => 'value2', 'foo' => 'foo2']]], [$arrayValue, [['id' => 'option1', 'value' => ['foo' => 'foo1', 'bar' => 'bar1']]], ['option1' => ['foo' => 'foo1', 'bar' => 'bar1']]], [$variableValue, [['id' => 'option1', 'value' => ['foo' => 'foo1', 'bar' => 'bar1']], ['id' => 'option2', 'value' => 'value2']], ['option1' => ['foo' => 'foo1', 'bar' => 'bar1'], 'option2' => 'value2']]]; + } +} diff --git a/vendor/symfony/config/Tests/Definition/ScalarNodeTest.php b/vendor/symfony/config/Tests/Definition/ScalarNodeTest.php index 00c576a65..f04a09cdb 100644 --- a/vendor/symfony/config/Tests/Definition/ScalarNodeTest.php +++ b/vendor/symfony/config/Tests/Definition/ScalarNodeTest.php @@ -1,113 +1,113 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode; -class ScalarNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @dataProvider getValidValues - */ - public function testNormalize($value) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); - $this->assertSame($value, $node->normalize($value)); - } - public function getValidValues() - { - return [[\false], [\true], [null], [''], ['foo'], [0], [1], [0.0], [0.1]]; - } - public function testSetDeprecated() - { - $childNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo'); - $childNode->setDeprecated('"%node%" is deprecated'); - $this->assertTrue($childNode->isDeprecated()); - $this->assertSame('"foo" is deprecated', $childNode->getDeprecationMessage($childNode->getName(), $childNode->getPath())); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); - $node->addChild($childNode); - $deprecationTriggered = 0; - $deprecationHandler = function ($level, $message, $file, $line) use(&$prevErrorHandler, &$deprecationTriggered) { - if (\E_USER_DEPRECATED === $level) { - return ++$deprecationTriggered; - } - return $prevErrorHandler ? $prevErrorHandler($level, $message, $file, $line) : \false; - }; - $prevErrorHandler = \set_error_handler($deprecationHandler); - $node->finalize([]); - \restore_error_handler(); - $this->assertSame(0, $deprecationTriggered, '->finalize() should not trigger if the deprecated node is not set'); - $prevErrorHandler = \set_error_handler($deprecationHandler); - $node->finalize(['foo' => '']); - \restore_error_handler(); - $this->assertSame(1, $deprecationTriggered, '->finalize() should trigger if the deprecated node is set'); - } - /** - * @dataProvider getInvalidValues - */ - public function testNormalizeThrowsExceptionOnInvalidValues($value) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); - $node->normalize($value); - } - public function getInvalidValues() - { - return [[[]], [['foo' => 'bar']], [new \stdClass()]]; - } - public function testNormalizeThrowsExceptionWithoutHint() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); - $this->expectExceptionMessage('Invalid type for path "test". Expected scalar, but got array.'); - $node->normalize([]); - } - public function testNormalizeThrowsExceptionWithErrorMessage() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); - $node->setInfo('"the test value"'); - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); - $this->expectExceptionMessage("Invalid type for path \"test\". Expected scalar, but got array.\nHint: \"the test value\""); - $node->normalize([]); - } - /** - * @dataProvider getValidNonEmptyValues - * - * @param mixed $value - */ - public function testValidNonEmptyValues($value) - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); - $node->setAllowEmptyValue(\false); - $this->assertSame($value, $node->finalize($value)); - } - public function getValidNonEmptyValues() - { - return [[\false], [\true], ['foo'], [0], [1], [0.0], [0.1]]; - } - /** - * @dataProvider getEmptyValues - * - * @param mixed $value - */ - public function testNotAllowedEmptyValuesThrowException($value) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); - $node->setAllowEmptyValue(\false); - $node->finalize($value); - } - public function getEmptyValues() - { - return [[null], ['']]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Definition; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode; +class ScalarNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @dataProvider getValidValues + */ + public function testNormalize($value) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); + $this->assertSame($value, $node->normalize($value)); + } + public function getValidValues() + { + return [[\false], [\true], [null], [''], ['foo'], [0], [1], [0.0], [0.1]]; + } + public function testSetDeprecated() + { + $childNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('foo'); + $childNode->setDeprecated('"%node%" is deprecated'); + $this->assertTrue($childNode->isDeprecated()); + $this->assertSame('"foo" is deprecated', $childNode->getDeprecationMessage($childNode->getName(), $childNode->getPath())); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode('root'); + $node->addChild($childNode); + $deprecationTriggered = 0; + $deprecationHandler = function ($level, $message, $file, $line) use(&$prevErrorHandler, &$deprecationTriggered) { + if (\E_USER_DEPRECATED === $level) { + return ++$deprecationTriggered; + } + return $prevErrorHandler ? $prevErrorHandler($level, $message, $file, $line) : \false; + }; + $prevErrorHandler = \set_error_handler($deprecationHandler); + $node->finalize([]); + \restore_error_handler(); + $this->assertSame(0, $deprecationTriggered, '->finalize() should not trigger if the deprecated node is not set'); + $prevErrorHandler = \set_error_handler($deprecationHandler); + $node->finalize(['foo' => '']); + \restore_error_handler(); + $this->assertSame(1, $deprecationTriggered, '->finalize() should trigger if the deprecated node is set'); + } + /** + * @dataProvider getInvalidValues + */ + public function testNormalizeThrowsExceptionOnInvalidValues($value) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); + $node->normalize($value); + } + public function getInvalidValues() + { + return [[[]], [['foo' => 'bar']], [new \stdClass()]]; + } + public function testNormalizeThrowsExceptionWithoutHint() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); + $this->expectExceptionMessage('Invalid type for path "test". Expected scalar, but got array.'); + $node->normalize([]); + } + public function testNormalizeThrowsExceptionWithErrorMessage() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); + $node->setInfo('"the test value"'); + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidTypeException'); + $this->expectExceptionMessage("Invalid type for path \"test\". Expected scalar, but got array.\nHint: \"the test value\""); + $node->normalize([]); + } + /** + * @dataProvider getValidNonEmptyValues + * + * @param mixed $value + */ + public function testValidNonEmptyValues($value) + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); + $node->setAllowEmptyValue(\false); + $this->assertSame($value, $node->finalize($value)); + } + public function getValidNonEmptyValues() + { + return [[\false], [\true], ['foo'], [0], [1], [0.0], [0.1]]; + } + /** + * @dataProvider getEmptyValues + * + * @param mixed $value + */ + public function testNotAllowedEmptyValuesThrowException($value) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Definition\\Exception\\InvalidConfigurationException'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ScalarNode('test'); + $node->setAllowEmptyValue(\false); + $node->finalize($value); + } + public function getEmptyValues() + { + return [[null], ['']]; + } +} diff --git a/vendor/symfony/config/Tests/Definition/index.php b/vendor/symfony/config/Tests/Definition/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Definition/index.php +++ b/vendor/symfony/config/Tests/Definition/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/DependencyInjection/ConfigCachePassTest.php b/vendor/symfony/config/Tests/DependencyInjection/ConfigCachePassTest.php index e56307330..5400bb596 100644 --- a/vendor/symfony/config/Tests/DependencyInjection/ConfigCachePassTest.php +++ b/vendor/symfony/config/Tests/DependencyInjection/ConfigCachePassTest.php @@ -1,46 +1,46 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\DependencyInjection; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\DependencyInjection\ConfigCachePass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * @group legacy - */ -class ConfigCachePassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testThatCheckersAreProcessedInPriorityOrder() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register('config_cache_factory')->addArgument(null); - $container->register('checker_2')->addTag('config_cache.resource_checker', ['priority' => 100]); - $container->register('checker_1')->addTag('config_cache.resource_checker', ['priority' => 200]); - $container->register('checker_3')->addTag('config_cache.resource_checker'); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\DependencyInjection\ConfigCachePass(); - $pass->process($container); - $expected = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('checker_1'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('checker_2'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('checker_3')]); - $this->assertEquals($expected, $definition->getArgument(0)); - } - public function testThatCheckersCanBeMissing() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definitionsBefore = \count($container->getDefinitions()); - $aliasesBefore = \count($container->getAliases()); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\DependencyInjection\ConfigCachePass(); - $pass->process($container); - // the container is untouched (i.e. no new definitions or aliases) - $this->assertCount($definitionsBefore, $container->getDefinitions()); - $this->assertCount($aliasesBefore, $container->getAliases()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\DependencyInjection; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\DependencyInjection\ConfigCachePass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * @group legacy + */ +class ConfigCachePassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testThatCheckersAreProcessedInPriorityOrder() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register('config_cache_factory')->addArgument(null); + $container->register('checker_2')->addTag('config_cache.resource_checker', ['priority' => 100]); + $container->register('checker_1')->addTag('config_cache.resource_checker', ['priority' => 200]); + $container->register('checker_3')->addTag('config_cache.resource_checker'); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\DependencyInjection\ConfigCachePass(); + $pass->process($container); + $expected = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('checker_1'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('checker_2'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('checker_3')]); + $this->assertEquals($expected, $definition->getArgument(0)); + } + public function testThatCheckersCanBeMissing() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definitionsBefore = \count($container->getDefinitions()); + $aliasesBefore = \count($container->getAliases()); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\DependencyInjection\ConfigCachePass(); + $pass->process($container); + // the container is untouched (i.e. no new definitions or aliases) + $this->assertCount($definitionsBefore, $container->getDefinitions()); + $this->assertCount($aliasesBefore, $container->getAliases()); + } +} diff --git a/vendor/symfony/config/Tests/DependencyInjection/index.php b/vendor/symfony/config/Tests/DependencyInjection/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/DependencyInjection/index.php +++ b/vendor/symfony/config/Tests/DependencyInjection/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Exception/FileLoaderLoadExceptionTest.php b/vendor/symfony/config/Tests/Exception/FileLoaderLoadExceptionTest.php index a0234d528..d52c7b828 100644 --- a/vendor/symfony/config/Tests/Exception/FileLoaderLoadExceptionTest.php +++ b/vendor/symfony/config/Tests/Exception/FileLoaderLoadExceptionTest.php @@ -1,57 +1,57 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Exception; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException; -class FileLoaderLoadExceptionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testMessageCannotLoadResource() - { - $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', null); - $this->assertEquals('Cannot load resource "resource".', $exception->getMessage()); - } - public function testMessageCannotLoadResourceWithType() - { - $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', null, null, null, 'foobar'); - $this->assertEquals('Cannot load resource "resource". Make sure there is a loader supporting the "foobar" type.', $exception->getMessage()); - } - public function testMessageCannotLoadResourceWithAnnotationType() - { - $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', null, null, null, 'annotation'); - $this->assertEquals('Cannot load resource "resource". Make sure annotations are installed and enabled.', $exception->getMessage()); - } - public function testMessageCannotImportResourceFromSource() - { - $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', 'sourceResource'); - $this->assertEquals('Cannot import resource "resource" from "sourceResource".', $exception->getMessage()); - } - public function testMessageCannotImportBundleResource() - { - $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('@resource', 'sourceResource'); - $this->assertEquals('Cannot import resource "@resource" from "sourceResource". ' . 'Make sure the "resource" bundle is correctly registered and loaded in the application kernel class. ' . 'If the bundle is registered, make sure the bundle path "@resource" is not empty.', $exception->getMessage()); - } - public function testMessageHasPreviousErrorWithDotAndUnableToLoad() - { - $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', null, null, new \Exception('There was a previous error with an ending dot.')); - $this->assertEquals('There was a previous error with an ending dot in resource (which is loaded in resource "resource").', $exception->getMessage()); - } - public function testMessageHasPreviousErrorWithoutDotAndUnableToLoad() - { - $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', null, null, new \Exception('There was a previous error with no ending dot')); - $this->assertEquals('There was a previous error with no ending dot in resource (which is loaded in resource "resource").', $exception->getMessage()); - } - public function testMessageHasPreviousErrorAndUnableToLoadBundle() - { - $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('@resource', null, null, new \Exception('There was a previous error with an ending dot.')); - $this->assertEquals('There was a previous error with an ending dot in @resource ' . '(which is loaded in resource "@resource"). ' . 'Make sure the "resource" bundle is correctly registered and loaded in the application kernel class. ' . 'If the bundle is registered, make sure the bundle path "@resource" is not empty.', $exception->getMessage()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Exception; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException; +class FileLoaderLoadExceptionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testMessageCannotLoadResource() + { + $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', null); + $this->assertEquals('Cannot load resource "resource".', $exception->getMessage()); + } + public function testMessageCannotLoadResourceWithType() + { + $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', null, null, null, 'foobar'); + $this->assertEquals('Cannot load resource "resource". Make sure there is a loader supporting the "foobar" type.', $exception->getMessage()); + } + public function testMessageCannotLoadResourceWithAnnotationType() + { + $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', null, null, null, 'annotation'); + $this->assertEquals('Cannot load resource "resource". Make sure annotations are installed and enabled.', $exception->getMessage()); + } + public function testMessageCannotImportResourceFromSource() + { + $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', 'sourceResource'); + $this->assertEquals('Cannot import resource "resource" from "sourceResource".', $exception->getMessage()); + } + public function testMessageCannotImportBundleResource() + { + $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('@resource', 'sourceResource'); + $this->assertEquals('Cannot import resource "@resource" from "sourceResource". ' . 'Make sure the "resource" bundle is correctly registered and loaded in the application kernel class. ' . 'If the bundle is registered, make sure the bundle path "@resource" is not empty.', $exception->getMessage()); + } + public function testMessageHasPreviousErrorWithDotAndUnableToLoad() + { + $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', null, null, new \Exception('There was a previous error with an ending dot.')); + $this->assertEquals('There was a previous error with an ending dot in resource (which is loaded in resource "resource").', $exception->getMessage()); + } + public function testMessageHasPreviousErrorWithoutDotAndUnableToLoad() + { + $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('resource', null, null, new \Exception('There was a previous error with no ending dot')); + $this->assertEquals('There was a previous error with no ending dot in resource (which is loaded in resource "resource").', $exception->getMessage()); + } + public function testMessageHasPreviousErrorAndUnableToLoadBundle() + { + $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Exception\FileLoaderLoadException('@resource', null, null, new \Exception('There was a previous error with an ending dot.')); + $this->assertEquals('There was a previous error with an ending dot in @resource ' . '(which is loaded in resource "@resource"). ' . 'Make sure the "resource" bundle is correctly registered and loaded in the application kernel class. ' . 'If the bundle is registered, make sure the bundle path "@resource" is not empty.', $exception->getMessage()); + } +} diff --git a/vendor/symfony/config/Tests/Exception/index.php b/vendor/symfony/config/Tests/Exception/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Exception/index.php +++ b/vendor/symfony/config/Tests/Exception/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/FileLocatorTest.php b/vendor/symfony/config/Tests/FileLocatorTest.php index a1f8fcae8..7d39d0943 100644 --- a/vendor/symfony/config/Tests/FileLocatorTest.php +++ b/vendor/symfony/config/Tests/FileLocatorTest.php @@ -1,64 +1,64 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -class FileLocatorTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @dataProvider getIsAbsolutePathTests - */ - public function testIsAbsolutePath($path) - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator([]); - $r = new \ReflectionObject($loader); - $m = $r->getMethod('isAbsolutePath'); - $m->setAccessible(\true); - $this->assertTrue($m->invoke($loader, $path), '->isAbsolutePath() returns true for an absolute path'); - } - public function getIsAbsolutePathTests() - { - return [['/foo.xml'], ['c:\\\\foo.xml'], ['c:/foo.xml'], ['\\server\\foo.xml'], ['https://server/foo.xml'], ['phar://server/foo.xml']]; - } - public function testLocate() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(__DIR__ . '/Fixtures'); - $this->assertEquals(__DIR__ . \DIRECTORY_SEPARATOR . 'FileLocatorTest.php', $loader->locate('FileLocatorTest.php', __DIR__), '->locate() returns the absolute filename if the file exists in the given path'); - $this->assertEquals(__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', $loader->locate('foo.xml', __DIR__), '->locate() returns the absolute filename if the file exists in one of the paths given in the constructor'); - $this->assertEquals(__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', $loader->locate(__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', __DIR__), '->locate() returns the absolute filename if the file exists in one of the paths given in the constructor'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator([__DIR__ . '/Fixtures', __DIR__ . '/Fixtures/Again']); - $this->assertEquals([__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', __DIR__ . '/Fixtures/Again' . \DIRECTORY_SEPARATOR . 'foo.xml'], $loader->locate('foo.xml', __DIR__, \false), '->locate() returns an array of absolute filenames'); - $this->assertEquals([__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', __DIR__ . '/Fixtures/Again' . \DIRECTORY_SEPARATOR . 'foo.xml'], $loader->locate('foo.xml', __DIR__ . '/Fixtures', \false), '->locate() returns an array of absolute filenames'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(__DIR__ . '/Fixtures/Again'); - $this->assertEquals([__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', __DIR__ . '/Fixtures/Again' . \DIRECTORY_SEPARATOR . 'foo.xml'], $loader->locate('foo.xml', __DIR__ . '/Fixtures', \false), '->locate() returns an array of absolute filenames'); - } - public function testLocateThrowsAnExceptionIfTheFileDoesNotExists() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLocatorFileNotFoundException'); - $this->expectExceptionMessage('The file "foobar.xml" does not exist'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator([__DIR__ . '/Fixtures']); - $loader->locate('foobar.xml', __DIR__); - } - public function testLocateThrowsAnExceptionIfTheFileDoesNotExistsInAbsolutePath() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLocatorFileNotFoundException'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator([__DIR__ . '/Fixtures']); - $loader->locate(__DIR__ . '/Fixtures/foobar.xml', __DIR__); - } - public function testLocateEmpty() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('An empty file name is not valid to be located.'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator([__DIR__ . '/Fixtures']); - $loader->locate(null, __DIR__); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +class FileLocatorTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @dataProvider getIsAbsolutePathTests + */ + public function testIsAbsolutePath($path) + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator([]); + $r = new \ReflectionObject($loader); + $m = $r->getMethod('isAbsolutePath'); + $m->setAccessible(\true); + $this->assertTrue($m->invoke($loader, $path), '->isAbsolutePath() returns true for an absolute path'); + } + public function getIsAbsolutePathTests() + { + return [['/foo.xml'], ['c:\\\\foo.xml'], ['c:/foo.xml'], ['\\server\\foo.xml'], ['https://server/foo.xml'], ['phar://server/foo.xml']]; + } + public function testLocate() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(__DIR__ . '/Fixtures'); + $this->assertEquals(__DIR__ . \DIRECTORY_SEPARATOR . 'FileLocatorTest.php', $loader->locate('FileLocatorTest.php', __DIR__), '->locate() returns the absolute filename if the file exists in the given path'); + $this->assertEquals(__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', $loader->locate('foo.xml', __DIR__), '->locate() returns the absolute filename if the file exists in one of the paths given in the constructor'); + $this->assertEquals(__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', $loader->locate(__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', __DIR__), '->locate() returns the absolute filename if the file exists in one of the paths given in the constructor'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator([__DIR__ . '/Fixtures', __DIR__ . '/Fixtures/Again']); + $this->assertEquals([__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', __DIR__ . '/Fixtures/Again' . \DIRECTORY_SEPARATOR . 'foo.xml'], $loader->locate('foo.xml', __DIR__, \false), '->locate() returns an array of absolute filenames'); + $this->assertEquals([__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', __DIR__ . '/Fixtures/Again' . \DIRECTORY_SEPARATOR . 'foo.xml'], $loader->locate('foo.xml', __DIR__ . '/Fixtures', \false), '->locate() returns an array of absolute filenames'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(__DIR__ . '/Fixtures/Again'); + $this->assertEquals([__DIR__ . '/Fixtures' . \DIRECTORY_SEPARATOR . 'foo.xml', __DIR__ . '/Fixtures/Again' . \DIRECTORY_SEPARATOR . 'foo.xml'], $loader->locate('foo.xml', __DIR__ . '/Fixtures', \false), '->locate() returns an array of absolute filenames'); + } + public function testLocateThrowsAnExceptionIfTheFileDoesNotExists() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLocatorFileNotFoundException'); + $this->expectExceptionMessage('The file "foobar.xml" does not exist'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator([__DIR__ . '/Fixtures']); + $loader->locate('foobar.xml', __DIR__); + } + public function testLocateThrowsAnExceptionIfTheFileDoesNotExistsInAbsolutePath() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLocatorFileNotFoundException'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator([__DIR__ . '/Fixtures']); + $loader->locate(__DIR__ . '/Fixtures/foobar.xml', __DIR__); + } + public function testLocateEmpty() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('An empty file name is not valid to be located.'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator([__DIR__ . '/Fixtures']); + $loader->locate(null, __DIR__); + } +} diff --git a/vendor/symfony/config/Tests/Fixtures/Again/index.php b/vendor/symfony/config/Tests/Fixtures/Again/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Fixtures/Again/index.php +++ b/vendor/symfony/config/Tests/Fixtures/Again/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/BadFileName.php b/vendor/symfony/config/Tests/Fixtures/BadFileName.php index 9f4184551..56fad03e3 100644 --- a/vendor/symfony/config/Tests/Fixtures/BadFileName.php +++ b/vendor/symfony/config/Tests/Fixtures/BadFileName.php @@ -1,8 +1,8 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; -class BarNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode; +class BarNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ArrayNode +{ +} diff --git a/vendor/symfony/config/Tests/Fixtures/Builder/BarNodeDefinition.php b/vendor/symfony/config/Tests/Fixtures/Builder/BarNodeDefinition.php index 289113083..1754c7c7c 100644 --- a/vendor/symfony/config/Tests/Fixtures/Builder/BarNodeDefinition.php +++ b/vendor/symfony/config/Tests/Fixtures/Builder/BarNodeDefinition.php @@ -1,21 +1,21 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BarNode; -class BarNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition -{ - protected function createNode() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BarNode($this->name); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BarNode; +class BarNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeDefinition +{ + protected function createNode() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BarNode($this->name); + } +} diff --git a/vendor/symfony/config/Tests/Fixtures/Builder/NodeBuilder.php b/vendor/symfony/config/Tests/Fixtures/Builder/NodeBuilder.php index ca83abb3f..d75c80d0c 100644 --- a/vendor/symfony/config/Tests/Fixtures/Builder/NodeBuilder.php +++ b/vendor/symfony/config/Tests/Fixtures/Builder/NodeBuilder.php @@ -1,31 +1,31 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder as BaseNodeBuilder; -class NodeBuilder extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder -{ - public function barNode($name) - { - return $this->node($name, 'bar'); - } - protected function getNodeClass($type) - { - switch ($type) { - case 'variable': - return __NAMESPACE__ . '\\' . \ucfirst($type) . 'NodeDefinition'; - case 'bar': - return __NAMESPACE__ . '\\' . \ucfirst($type) . 'NodeDefinition'; - default: - return parent::getNodeClass($type); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder as BaseNodeBuilder; +class NodeBuilder extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\NodeBuilder +{ + public function barNode($name) + { + return $this->node($name, 'bar'); + } + protected function getNodeClass($type) + { + switch ($type) { + case 'variable': + return __NAMESPACE__ . '\\' . \ucfirst($type) . 'NodeDefinition'; + case 'bar': + return __NAMESPACE__ . '\\' . \ucfirst($type) . 'NodeDefinition'; + default: + return parent::getNodeClass($type); + } + } +} diff --git a/vendor/symfony/config/Tests/Fixtures/Builder/VariableNodeDefinition.php b/vendor/symfony/config/Tests/Fixtures/Builder/VariableNodeDefinition.php index 7429d15a0..354b9be5e 100644 --- a/vendor/symfony/config/Tests/Fixtures/Builder/VariableNodeDefinition.php +++ b/vendor/symfony/config/Tests/Fixtures/Builder/VariableNodeDefinition.php @@ -1,16 +1,16 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition as BaseVariableNodeDefinition; -class VariableNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Builder; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition as BaseVariableNodeDefinition; +class VariableNodeDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\VariableNodeDefinition +{ +} diff --git a/vendor/symfony/config/Tests/Fixtures/Builder/index.php b/vendor/symfony/config/Tests/Fixtures/Builder/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Fixtures/Builder/index.php +++ b/vendor/symfony/config/Tests/Fixtures/Builder/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/Configuration/ExampleConfiguration.php b/vendor/symfony/config/Tests/Fixtures/Configuration/ExampleConfiguration.php index 3f02700a1..c5b3f2e90 100644 --- a/vendor/symfony/config/Tests/Fixtures/Configuration/ExampleConfiguration.php +++ b/vendor/symfony/config/Tests/Fixtures/Configuration/ExampleConfiguration.php @@ -1,102 +1,102 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Symfony\Component\Config\Tests\Fixtures\Configuration; - -use Symfony\Component\Config\Definition\Builder\TreeBuilder; -use Symfony\Component\Config\Definition\ConfigurationInterface; - -class ExampleConfiguration implements ConfigurationInterface -{ - public function getConfigTreeBuilder() - { - $treeBuilder = new TreeBuilder(); - $rootNode = $treeBuilder->root('acme_root'); - - $rootNode - ->fixXmlConfig('parameter') - ->fixXmlConfig('connection') - ->fixXmlConfig('cms_page') - ->children() - ->booleanNode('boolean')->defaultTrue()->end() - ->scalarNode('scalar_empty')->end() - ->scalarNode('scalar_null')->defaultNull()->end() - ->scalarNode('scalar_true')->defaultTrue()->end() - ->scalarNode('scalar_false')->defaultFalse()->end() - ->scalarNode('scalar_default')->defaultValue('default')->end() - ->scalarNode('scalar_array_empty')->defaultValue([])->end() - ->scalarNode('scalar_array_defaults')->defaultValue(['elem1', 'elem2'])->end() - ->scalarNode('scalar_required')->isRequired()->end() - ->scalarNode('scalar_deprecated')->setDeprecated()->end() - ->scalarNode('scalar_deprecated_with_message')->setDeprecated('Deprecation custom message for "%node%" at "%path%"')->end() - ->scalarNode('node_with_a_looong_name')->end() - ->enumNode('enum_with_default')->values(['this', 'that'])->defaultValue('this')->end() - ->enumNode('enum')->values(['this', 'that'])->end() - ->arrayNode('array') - ->info('some info') - ->canBeUnset() - ->children() - ->scalarNode('child1')->end() - ->scalarNode('child2')->end() - ->scalarNode('child3') - ->info( - "this is a long\n". - "multi-line info text\n". - 'which should be indented' - ) - ->example('example setting') - ->end() - ->end() - ->end() - ->arrayNode('scalar_prototyped') - ->prototype('scalar')->end() - ->end() - ->arrayNode('parameters') - ->useAttributeAsKey('name') - ->prototype('scalar')->info('Parameter name')->end() - ->end() - ->arrayNode('connections') - ->prototype('array') - ->children() - ->scalarNode('user')->end() - ->scalarNode('pass')->end() - ->end() - ->end() - ->end() - ->arrayNode('cms_pages') - ->useAttributeAsKey('page') - ->prototype('array') - ->useAttributeAsKey('locale') - ->prototype('array') - ->children() - ->scalarNode('title')->isRequired()->end() - ->scalarNode('path')->isRequired()->end() - ->end() - ->end() - ->end() - ->end() - ->arrayNode('pipou') - ->useAttributeAsKey('name') - ->prototype('array') - ->prototype('array') - ->children() - ->scalarNode('didou') - ->end() - ->end() - ->end() - ->end() - ->end() - ->end() - ; - - return $treeBuilder; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Symfony\Component\Config\Tests\Fixtures\Configuration; + +use Symfony\Component\Config\Definition\Builder\TreeBuilder; +use Symfony\Component\Config\Definition\ConfigurationInterface; + +class ExampleConfiguration implements ConfigurationInterface +{ + public function getConfigTreeBuilder() + { + $treeBuilder = new TreeBuilder(); + $rootNode = $treeBuilder->root('acme_root'); + + $rootNode + ->fixXmlConfig('parameter') + ->fixXmlConfig('connection') + ->fixXmlConfig('cms_page') + ->children() + ->booleanNode('boolean')->defaultTrue()->end() + ->scalarNode('scalar_empty')->end() + ->scalarNode('scalar_null')->defaultNull()->end() + ->scalarNode('scalar_true')->defaultTrue()->end() + ->scalarNode('scalar_false')->defaultFalse()->end() + ->scalarNode('scalar_default')->defaultValue('default')->end() + ->scalarNode('scalar_array_empty')->defaultValue([])->end() + ->scalarNode('scalar_array_defaults')->defaultValue(['elem1', 'elem2'])->end() + ->scalarNode('scalar_required')->isRequired()->end() + ->scalarNode('scalar_deprecated')->setDeprecated()->end() + ->scalarNode('scalar_deprecated_with_message')->setDeprecated('Deprecation custom message for "%node%" at "%path%"')->end() + ->scalarNode('node_with_a_looong_name')->end() + ->enumNode('enum_with_default')->values(['this', 'that'])->defaultValue('this')->end() + ->enumNode('enum')->values(['this', 'that'])->end() + ->arrayNode('array') + ->info('some info') + ->canBeUnset() + ->children() + ->scalarNode('child1')->end() + ->scalarNode('child2')->end() + ->scalarNode('child3') + ->info( + "this is a long\n". + "multi-line info text\n". + 'which should be indented' + ) + ->example('example setting') + ->end() + ->end() + ->end() + ->arrayNode('scalar_prototyped') + ->prototype('scalar')->end() + ->end() + ->arrayNode('parameters') + ->useAttributeAsKey('name') + ->prototype('scalar')->info('Parameter name')->end() + ->end() + ->arrayNode('connections') + ->prototype('array') + ->children() + ->scalarNode('user')->end() + ->scalarNode('pass')->end() + ->end() + ->end() + ->end() + ->arrayNode('cms_pages') + ->useAttributeAsKey('page') + ->prototype('array') + ->useAttributeAsKey('locale') + ->prototype('array') + ->children() + ->scalarNode('title')->isRequired()->end() + ->scalarNode('path')->isRequired()->end() + ->end() + ->end() + ->end() + ->end() + ->arrayNode('pipou') + ->useAttributeAsKey('name') + ->prototype('array') + ->prototype('array') + ->children() + ->scalarNode('didou') + ->end() + ->end() + ->end() + ->end() + ->end() + ->end() + ; + + return $treeBuilder; + } +} diff --git a/vendor/symfony/config/Tests/Fixtures/Configuration/index.php b/vendor/symfony/config/Tests/Fixtures/Configuration/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Fixtures/Configuration/index.php +++ b/vendor/symfony/config/Tests/Fixtures/Configuration/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/ParseError.php b/vendor/symfony/config/Tests/Fixtures/ParseError.php index cb066448c..0f710d7d9 100644 --- a/vendor/symfony/config/Tests/Fixtures/ParseError.php +++ b/vendor/symfony/config/Tests/Fixtures/ParseError.php @@ -1,8 +1,8 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/Util/document_type.xml b/vendor/symfony/config/Tests/Fixtures/Util/document_type.xml index 4c2522826..10cce8358 100644 --- a/vendor/symfony/config/Tests/Fixtures/Util/document_type.xml +++ b/vendor/symfony/config/Tests/Fixtures/Util/document_type.xml @@ -1,3 +1,3 @@ - -]> - + +]> + diff --git a/vendor/symfony/config/Tests/Fixtures/Util/index.php b/vendor/symfony/config/Tests/Fixtures/Util/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Fixtures/Util/index.php +++ b/vendor/symfony/config/Tests/Fixtures/Util/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Fixtures/Util/invalid.xml b/vendor/symfony/config/Tests/Fixtures/Util/invalid.xml index a07af9fd8..0fecfc127 100644 --- a/vendor/symfony/config/Tests/Fixtures/Util/invalid.xml +++ b/vendor/symfony/config/Tests/Fixtures/Util/invalid.xml @@ -1,2 +1,2 @@ - - + + diff --git a/vendor/symfony/config/Tests/Fixtures/Util/invalid_schema.xml b/vendor/symfony/config/Tests/Fixtures/Util/invalid_schema.xml index e2725a2c2..57b4ee9b8 100644 --- a/vendor/symfony/config/Tests/Fixtures/Util/invalid_schema.xml +++ b/vendor/symfony/config/Tests/Fixtures/Util/invalid_schema.xml @@ -1,2 +1,2 @@ - - + + diff --git a/vendor/symfony/config/Tests/Fixtures/Util/schema.xsd b/vendor/symfony/config/Tests/Fixtures/Util/schema.xsd index e56820f69..8f3bc6157 100644 --- a/vendor/symfony/config/Tests/Fixtures/Util/schema.xsd +++ b/vendor/symfony/config/Tests/Fixtures/Util/schema.xsd @@ -1,9 +1,9 @@ - - - - - - + + + + + + diff --git a/vendor/symfony/config/Tests/Fixtures/Util/valid.xml b/vendor/symfony/config/Tests/Fixtures/Util/valid.xml index a96bb3826..5f474f9fd 100644 --- a/vendor/symfony/config/Tests/Fixtures/Util/valid.xml +++ b/vendor/symfony/config/Tests/Fixtures/Util/valid.xml @@ -1,3 +1,3 @@ - - - + + + diff --git a/vendor/symfony/config/Tests/Fixtures/index.php b/vendor/symfony/config/Tests/Fixtures/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Fixtures/index.php +++ b/vendor/symfony/config/Tests/Fixtures/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Loader/DelegatingLoaderTest.php b/vendor/symfony/config/Tests/Loader/DelegatingLoaderTest.php index d91fa9929..f405e86ba 100644 --- a/vendor/symfony/config/Tests/Loader/DelegatingLoaderTest.php +++ b/vendor/symfony/config/Tests/Loader/DelegatingLoaderTest.php @@ -1,60 +1,60 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; -class DelegatingLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructor() - { - new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader($resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver()); - $this->assertTrue(\true, '__construct() takes a loader resolver as its first argument'); - } - public function testGetSetResolver() - { - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader($resolver); - $this->assertSame($resolver, $loader->getResolver(), '->getResolver() gets the resolver loader'); - $loader->setResolver($resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver()); - $this->assertSame($resolver, $loader->getResolver(), '->setResolver() sets the resolver loader'); - } - public function testSupports() - { - $loader1 = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); - $loader1->expects($this->once())->method('supports')->willReturn(\true); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader1])); - $this->assertTrue($loader->supports('foo.xml'), '->supports() returns true if the resource is loadable'); - $loader1 = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); - $loader1->expects($this->once())->method('supports')->willReturn(\false); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader1])); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns false if the resource is not loadable'); - } - public function testLoad() - { - $loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); - $loader->expects($this->once())->method('supports')->willReturn(\true); - $loader->expects($this->once())->method('load'); - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader]); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader($resolver); - $loader->load('foo'); - } - public function testLoadThrowsAnExceptionIfTheResourceCannotBeLoaded() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderLoadException'); - $loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); - $loader->expects($this->once())->method('supports')->willReturn(\false); - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader]); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader($resolver); - $loader->load('foo'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; +class DelegatingLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructor() + { + new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader($resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver()); + $this->assertTrue(\true, '__construct() takes a loader resolver as its first argument'); + } + public function testGetSetResolver() + { + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader($resolver); + $this->assertSame($resolver, $loader->getResolver(), '->getResolver() gets the resolver loader'); + $loader->setResolver($resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver()); + $this->assertSame($resolver, $loader->getResolver(), '->setResolver() sets the resolver loader'); + } + public function testSupports() + { + $loader1 = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); + $loader1->expects($this->once())->method('supports')->willReturn(\true); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader1])); + $this->assertTrue($loader->supports('foo.xml'), '->supports() returns true if the resource is loadable'); + $loader1 = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); + $loader1->expects($this->once())->method('supports')->willReturn(\false); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader1])); + $this->assertFalse($loader->supports('foo.foo'), '->supports() returns false if the resource is not loadable'); + } + public function testLoad() + { + $loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); + $loader->expects($this->once())->method('supports')->willReturn(\true); + $loader->expects($this->once())->method('load'); + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader]); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader($resolver); + $loader->load('foo'); + } + public function testLoadThrowsAnExceptionIfTheResourceCannotBeLoaded() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderLoadException'); + $loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); + $loader->expects($this->once())->method('supports')->willReturn(\false); + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader]); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\DelegatingLoader($resolver); + $loader->load('foo'); + } +} diff --git a/vendor/symfony/config/Tests/Loader/FileLoaderTest.php b/vendor/symfony/config/Tests/Loader/FileLoaderTest.php index cd22287e1..76ef5e1f3 100644 --- a/vendor/symfony/config/Tests/Loader/FileLoaderTest.php +++ b/vendor/symfony/config/Tests/Loader/FileLoaderTest.php @@ -1,108 +1,108 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\FileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; -class FileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testImportWithFileLocatorDelegation() - { - $locatorMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface')->getMock(); - $locatorMockForAdditionalLoader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface')->getMock(); - $locatorMockForAdditionalLoader->expects($this->any())->method('locate')->will($this->onConsecutiveCalls( - ['path/to/file1'], - // Default - ['path/to/file1', 'path/to/file2'], - // First is imported - ['path/to/file1', 'path/to/file2'], - // Second is imported - ['path/to/file1'], - // Exception - ['path/to/file1', 'path/to/file2'] - )); - $fileLoader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\TestFileLoader($locatorMock); - $fileLoader->setSupports(\false); - $fileLoader->setCurrentDir('.'); - $additionalLoader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\TestFileLoader($locatorMockForAdditionalLoader); - $additionalLoader->setCurrentDir('.'); - $fileLoader->setResolver($loaderResolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$fileLoader, $additionalLoader])); - // Default case - $this->assertSame('path/to/file1', $fileLoader->import('my_resource')); - // Check first file is imported if not already loading - $this->assertSame('path/to/file1', $fileLoader->import('my_resource')); - // Check second file is imported if first is already loading - $fileLoader->addLoading('path/to/file1'); - $this->assertSame('path/to/file2', $fileLoader->import('my_resource')); - // Check exception throws if first (and only available) file is already loading - try { - $fileLoader->import('my_resource'); - $this->fail('->import() throws a FileLoaderImportCircularReferenceException if the resource is already loading'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderImportCircularReferenceException', $e, '->import() throws a FileLoaderImportCircularReferenceException if the resource is already loading'); - } - // Check exception throws if all files are already loading - try { - $fileLoader->addLoading('path/to/file2'); - $fileLoader->import('my_resource'); - $this->fail('->import() throws a FileLoaderImportCircularReferenceException if the resource is already loading'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderImportCircularReferenceException', $e, '->import() throws a FileLoaderImportCircularReferenceException if the resource is already loading'); - } - } - public function testImportWithGlobLikeResource() - { - $locatorMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface')->getMock(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\TestFileLoader($locatorMock); - $this->assertSame('[foo]', $loader->import('[foo]')); - } - public function testImportWithNoGlobMatch() - { - $locatorMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface')->getMock(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\TestFileLoader($locatorMock); - $this->assertNull($loader->import('./*.abc')); - } - public function testImportWithSimpleGlob() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\TestFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(__DIR__)); - $this->assertSame(__FILE__, \strtr($loader->import('FileLoaderTest.*'), '/', \DIRECTORY_SEPARATOR)); - } -} -class TestFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\FileLoader -{ - private $supports = \true; - public function load($resource, $type = null) - { - return $resource; - } - public function supports($resource, $type = null) - { - return $this->supports; - } - public function addLoading($resource) - { - self::$loading[$resource] = \true; - } - public function removeLoading($resource) - { - unset(self::$loading[$resource]); - } - public function clearLoading() - { - self::$loading = []; - } - public function setSupports($supports) - { - $this->supports = $supports; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\FileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; +class FileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testImportWithFileLocatorDelegation() + { + $locatorMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface')->getMock(); + $locatorMockForAdditionalLoader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface')->getMock(); + $locatorMockForAdditionalLoader->expects($this->any())->method('locate')->will($this->onConsecutiveCalls( + ['path/to/file1'], + // Default + ['path/to/file1', 'path/to/file2'], + // First is imported + ['path/to/file1', 'path/to/file2'], + // Second is imported + ['path/to/file1'], + // Exception + ['path/to/file1', 'path/to/file2'] + )); + $fileLoader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\TestFileLoader($locatorMock); + $fileLoader->setSupports(\false); + $fileLoader->setCurrentDir('.'); + $additionalLoader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\TestFileLoader($locatorMockForAdditionalLoader); + $additionalLoader->setCurrentDir('.'); + $fileLoader->setResolver($loaderResolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$fileLoader, $additionalLoader])); + // Default case + $this->assertSame('path/to/file1', $fileLoader->import('my_resource')); + // Check first file is imported if not already loading + $this->assertSame('path/to/file1', $fileLoader->import('my_resource')); + // Check second file is imported if first is already loading + $fileLoader->addLoading('path/to/file1'); + $this->assertSame('path/to/file2', $fileLoader->import('my_resource')); + // Check exception throws if first (and only available) file is already loading + try { + $fileLoader->import('my_resource'); + $this->fail('->import() throws a FileLoaderImportCircularReferenceException if the resource is already loading'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderImportCircularReferenceException', $e, '->import() throws a FileLoaderImportCircularReferenceException if the resource is already loading'); + } + // Check exception throws if all files are already loading + try { + $fileLoader->addLoading('path/to/file2'); + $fileLoader->import('my_resource'); + $this->fail('->import() throws a FileLoaderImportCircularReferenceException if the resource is already loading'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderImportCircularReferenceException', $e, '->import() throws a FileLoaderImportCircularReferenceException if the resource is already loading'); + } + } + public function testImportWithGlobLikeResource() + { + $locatorMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface')->getMock(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\TestFileLoader($locatorMock); + $this->assertSame('[foo]', $loader->import('[foo]')); + } + public function testImportWithNoGlobMatch() + { + $locatorMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\FileLocatorInterface')->getMock(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\TestFileLoader($locatorMock); + $this->assertNull($loader->import('./*.abc')); + } + public function testImportWithSimpleGlob() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\TestFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(__DIR__)); + $this->assertSame(__FILE__, \strtr($loader->import('FileLoaderTest.*'), '/', \DIRECTORY_SEPARATOR)); + } +} +class TestFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\FileLoader +{ + private $supports = \true; + public function load($resource, $type = null) + { + return $resource; + } + public function supports($resource, $type = null) + { + return $this->supports; + } + public function addLoading($resource) + { + self::$loading[$resource] = \true; + } + public function removeLoading($resource) + { + unset(self::$loading[$resource]); + } + public function clearLoading() + { + self::$loading = []; + } + public function setSupports($supports) + { + $this->supports = $supports; + } +} diff --git a/vendor/symfony/config/Tests/Loader/LoaderResolverTest.php b/vendor/symfony/config/Tests/Loader/LoaderResolverTest.php index 52c5e3a1d..60d44a1fb 100644 --- a/vendor/symfony/config/Tests/Loader/LoaderResolverTest.php +++ b/vendor/symfony/config/Tests/Loader/LoaderResolverTest.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; -class LoaderResolverTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructor() - { - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock()]); - $this->assertEquals([$loader], $resolver->getLoaders(), '__construct() takes an array of loaders as its first argument'); - } - public function testResolve() - { - $loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader]); - $this->assertFalse($resolver->resolve('foo.foo'), '->resolve() returns false if no loader is able to load the resource'); - $loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); - $loader->expects($this->once())->method('supports')->willReturn(\true); - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader]); - $this->assertEquals($loader, $resolver->resolve(function () { - }), '->resolve() returns the loader for the given resource'); - } - public function testLoaders() - { - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver(); - $resolver->addLoader($loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock()); - $this->assertEquals([$loader], $resolver->getLoaders(), 'addLoader() adds a loader'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; +class LoaderResolverTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructor() + { + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock()]); + $this->assertEquals([$loader], $resolver->getLoaders(), '__construct() takes an array of loaders as its first argument'); + } + public function testResolve() + { + $loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader]); + $this->assertFalse($resolver->resolve('foo.foo'), '->resolve() returns false if no loader is able to load the resource'); + $loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); + $loader->expects($this->once())->method('supports')->willReturn(\true); + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([$loader]); + $this->assertEquals($loader, $resolver->resolve(function () { + }), '->resolve() returns the loader for the given resource'); + } + public function testLoaders() + { + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver(); + $resolver->addLoader($loader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock()); + $this->assertEquals([$loader], $resolver->getLoaders(), 'addLoader() adds a loader'); + } +} diff --git a/vendor/symfony/config/Tests/Loader/LoaderTest.php b/vendor/symfony/config/Tests/Loader/LoaderTest.php index f0b613c04..faaaeebc0 100644 --- a/vendor/symfony/config/Tests/Loader/LoaderTest.php +++ b/vendor/symfony/config/Tests/Loader/LoaderTest.php @@ -1,76 +1,76 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader; -class LoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testGetSetResolver() - { - $resolver = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface')->getMock(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\ProjectLoader1(); - $loader->setResolver($resolver); - $this->assertSame($resolver, $loader->getResolver(), '->setResolver() sets the resolver loader'); - } - public function testResolve() - { - $resolvedLoader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); - $resolver = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface')->getMock(); - $resolver->expects($this->once())->method('resolve')->with('foo.xml')->willReturn($resolvedLoader); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\ProjectLoader1(); - $loader->setResolver($resolver); - $this->assertSame($loader, $loader->resolve('foo.foo'), '->resolve() finds a loader'); - $this->assertSame($resolvedLoader, $loader->resolve('foo.xml'), '->resolve() finds a loader'); - } - public function testResolveWhenResolverCannotFindLoader() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderLoadException'); - $resolver = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface')->getMock(); - $resolver->expects($this->once())->method('resolve')->with('FOOBAR')->willReturn(\false); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\ProjectLoader1(); - $loader->setResolver($resolver); - $loader->resolve('FOOBAR'); - } - public function testImport() - { - $resolvedLoader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); - $resolvedLoader->expects($this->once())->method('load')->with('foo')->willReturn('yes'); - $resolver = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface')->getMock(); - $resolver->expects($this->once())->method('resolve')->with('foo')->willReturn($resolvedLoader); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\ProjectLoader1(); - $loader->setResolver($resolver); - $this->assertEquals('yes', $loader->import('foo')); - } - public function testImportWithType() - { - $resolvedLoader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); - $resolvedLoader->expects($this->once())->method('load')->with('foo', 'bar')->willReturn('yes'); - $resolver = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface')->getMock(); - $resolver->expects($this->once())->method('resolve')->with('foo', 'bar')->willReturn($resolvedLoader); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\ProjectLoader1(); - $loader->setResolver($resolver); - $this->assertEquals('yes', $loader->import('foo', 'bar')); - } -} -class ProjectLoader1 extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader -{ - public function load($resource, $type = null) - { - } - public function supports($resource, $type = null) - { - return \is_string($resource) && 'foo' === \pathinfo($resource, \PATHINFO_EXTENSION); - } - public function getType() - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader; +class LoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testGetSetResolver() + { + $resolver = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface')->getMock(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\ProjectLoader1(); + $loader->setResolver($resolver); + $this->assertSame($resolver, $loader->getResolver(), '->setResolver() sets the resolver loader'); + } + public function testResolve() + { + $resolvedLoader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); + $resolver = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface')->getMock(); + $resolver->expects($this->once())->method('resolve')->with('foo.xml')->willReturn($resolvedLoader); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\ProjectLoader1(); + $loader->setResolver($resolver); + $this->assertSame($loader, $loader->resolve('foo.foo'), '->resolve() finds a loader'); + $this->assertSame($resolvedLoader, $loader->resolve('foo.xml'), '->resolve() finds a loader'); + } + public function testResolveWhenResolverCannotFindLoader() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Exception\\FileLoaderLoadException'); + $resolver = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface')->getMock(); + $resolver->expects($this->once())->method('resolve')->with('FOOBAR')->willReturn(\false); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\ProjectLoader1(); + $loader->setResolver($resolver); + $loader->resolve('FOOBAR'); + } + public function testImport() + { + $resolvedLoader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); + $resolvedLoader->expects($this->once())->method('load')->with('foo')->willReturn('yes'); + $resolver = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface')->getMock(); + $resolver->expects($this->once())->method('resolve')->with('foo')->willReturn($resolvedLoader); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\ProjectLoader1(); + $loader->setResolver($resolver); + $this->assertEquals('yes', $loader->import('foo')); + } + public function testImportWithType() + { + $resolvedLoader = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderInterface')->getMock(); + $resolvedLoader->expects($this->once())->method('load')->with('foo', 'bar')->willReturn('yes'); + $resolver = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Loader\\LoaderResolverInterface')->getMock(); + $resolver->expects($this->once())->method('resolve')->with('foo', 'bar')->willReturn($resolvedLoader); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Loader\ProjectLoader1(); + $loader->setResolver($resolver); + $this->assertEquals('yes', $loader->import('foo', 'bar')); + } +} +class ProjectLoader1 extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader +{ + public function load($resource, $type = null) + { + } + public function supports($resource, $type = null) + { + return \is_string($resource) && 'foo' === \pathinfo($resource, \PATHINFO_EXTENSION); + } + public function getType() + { + } +} diff --git a/vendor/symfony/config/Tests/Loader/index.php b/vendor/symfony/config/Tests/Loader/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Loader/index.php +++ b/vendor/symfony/config/Tests/Loader/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/Resource/ClassExistenceResourceTest.php b/vendor/symfony/config/Tests/Resource/ClassExistenceResourceTest.php index 07f5157b3..6f7c7207c 100644 --- a/vendor/symfony/config/Tests/Resource/ClassExistenceResourceTest.php +++ b/vendor/symfony/config/Tests/Resource/ClassExistenceResourceTest.php @@ -1,106 +1,106 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadFileName; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadParent; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\ParseError; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Resource\ConditionalClass; -class ClassExistenceResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testToString() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('BarClass'); - $this->assertSame('BarClass', (string) $res); - } - public function testGetResource() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('BarClass'); - $this->assertSame('BarClass', $res->getResource()); - } - public function testIsFreshWhenClassDoesNotExist() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\BarClass'); - $this->assertTrue($res->isFresh(\time())); - eval(<<assertFalse($res->isFresh(\time())); - } - public function testIsFreshWhenClassExists() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Resource\\ClassExistenceResourceTest'); - $this->assertTrue($res->isFresh(\time())); - } - public function testExistsKo() - { - \spl_autoload_register($autoloader = function ($class) use(&$loadedClass) { - $loadedClass = $class; - }); - try { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('MissingFooClass'); - $this->assertTrue($res->isFresh(0)); - $this->assertSame('MissingFooClass', $loadedClass); - $loadedClass = 123; - new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('MissingFooClass', \false); - $this->assertSame(123, $loadedClass); - } finally { - \spl_autoload_unregister($autoloader); - } - } - public function testBadParentWithTimestamp() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadParent::class, \false); - $this->assertTrue($res->isFresh(\time())); - } - public function testBadParentWithNoTimestamp() - { - $this->expectException('ReflectionException'); - $this->expectExceptionMessage('Class "Symfony\\Component\\Config\\Tests\\Fixtures\\MissingParent" not found while loading "Symfony\\Component\\Config\\Tests\\Fixtures\\BadParent".'); - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadParent::class, \false); - $res->isFresh(0); - } - public function testBadFileName() - { - $this->expectException('ReflectionException'); - $this->expectExceptionMessage('Mismatch between file name and class name.'); - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadFileName::class, \false); - $res->isFresh(0); - } - public function testBadFileNameBis() - { - $this->expectException('ReflectionException'); - $this->expectExceptionMessage('Mismatch between file name and class name.'); - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadFileName::class, \false); - $res->isFresh(0); - } - public function testConditionalClass() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Resource\ConditionalClass::class, \false); - $this->assertFalse($res->isFresh(0)); - } - /** - * @requires PHP 7 - */ - public function testParseError() - { - $this->expectException('ParseError'); - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\ParseError::class, \false); - $res->isFresh(0); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadFileName; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadParent; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\ParseError; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Resource\ConditionalClass; +class ClassExistenceResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testToString() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('BarClass'); + $this->assertSame('BarClass', (string) $res); + } + public function testGetResource() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('BarClass'); + $this->assertSame('BarClass', $res->getResource()); + } + public function testIsFreshWhenClassDoesNotExist() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Fixtures\\BarClass'); + $this->assertTrue($res->isFresh(\time())); + eval(<<assertFalse($res->isFresh(\time())); + } + public function testIsFreshWhenClassExists() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Tests\\Resource\\ClassExistenceResourceTest'); + $this->assertTrue($res->isFresh(\time())); + } + public function testExistsKo() + { + \spl_autoload_register($autoloader = function ($class) use(&$loadedClass) { + $loadedClass = $class; + }); + try { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('MissingFooClass'); + $this->assertTrue($res->isFresh(0)); + $this->assertSame('MissingFooClass', $loadedClass); + $loadedClass = 123; + new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource('MissingFooClass', \false); + $this->assertSame(123, $loadedClass); + } finally { + \spl_autoload_unregister($autoloader); + } + } + public function testBadParentWithTimestamp() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadParent::class, \false); + $this->assertTrue($res->isFresh(\time())); + } + public function testBadParentWithNoTimestamp() + { + $this->expectException('ReflectionException'); + $this->expectExceptionMessage('Class "Symfony\\Component\\Config\\Tests\\Fixtures\\MissingParent" not found while loading "Symfony\\Component\\Config\\Tests\\Fixtures\\BadParent".'); + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadParent::class, \false); + $res->isFresh(0); + } + public function testBadFileName() + { + $this->expectException('ReflectionException'); + $this->expectExceptionMessage('Mismatch between file name and class name.'); + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadFileName::class, \false); + $res->isFresh(0); + } + public function testBadFileNameBis() + { + $this->expectException('ReflectionException'); + $this->expectExceptionMessage('Mismatch between file name and class name.'); + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\BadFileName::class, \false); + $res->isFresh(0); + } + public function testConditionalClass() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\Resource\ConditionalClass::class, \false); + $this->assertFalse($res->isFresh(0)); + } + /** + * @requires PHP 7 + */ + public function testParseError() + { + $this->expectException('ParseError'); + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Fixtures\ParseError::class, \false); + $res->isFresh(0); + } +} diff --git a/vendor/symfony/config/Tests/Resource/ComposerResourceTest.php b/vendor/symfony/config/Tests/Resource/ComposerResourceTest.php index a44794944..12f3f88aa 100644 --- a/vendor/symfony/config/Tests/Resource/ComposerResourceTest.php +++ b/vendor/symfony/config/Tests/Resource/ComposerResourceTest.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; - -use _PhpScoper5ea00cc67502b\Composer\Autoload\ClassLoader; -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource; -class ComposerResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testGetVendor() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource(); - $r = new \ReflectionClass(\_PhpScoper5ea00cc67502b\Composer\Autoload\ClassLoader::class); - $found = \false; - foreach ($res->getVendors() as $vendor) { - if ($vendor && 0 === \strpos($r->getFileName(), $vendor)) { - $found = \true; - break; - } - } - $this->assertTrue($found); - } - public function testSerializeUnserialize() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource(); - $ser = \unserialize(\serialize($res)); - $this->assertTrue($res->isFresh(0)); - $this->assertTrue($ser->isFresh(0)); - $this->assertEquals($res, $ser); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; + +use _PhpScoper5ea00cc67502b\Composer\Autoload\ClassLoader; +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource; +class ComposerResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testGetVendor() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource(); + $r = new \ReflectionClass(\_PhpScoper5ea00cc67502b\Composer\Autoload\ClassLoader::class); + $found = \false; + foreach ($res->getVendors() as $vendor) { + if ($vendor && 0 === \strpos($r->getFileName(), $vendor)) { + $found = \true; + break; + } + } + $this->assertTrue($found); + } + public function testSerializeUnserialize() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource(); + $ser = \unserialize(\serialize($res)); + $this->assertTrue($res->isFresh(0)); + $this->assertTrue($ser->isFresh(0)); + $this->assertEquals($res, $ser); + } +} diff --git a/vendor/symfony/config/Tests/Resource/DirectoryResourceTest.php b/vendor/symfony/config/Tests/Resource/DirectoryResourceTest.php index e5ad97d4f..e336fd80f 100644 --- a/vendor/symfony/config/Tests/Resource/DirectoryResourceTest.php +++ b/vendor/symfony/config/Tests/Resource/DirectoryResourceTest.php @@ -1,150 +1,150 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource; -class DirectoryResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected $directory; - protected function setUp() - { - $this->directory = \sys_get_temp_dir() . \DIRECTORY_SEPARATOR . 'symfonyDirectoryIterator'; - if (!\file_exists($this->directory)) { - \mkdir($this->directory); - } - \touch($this->directory . '/tmp.xml'); - } - protected function tearDown() - { - if (!\is_dir($this->directory)) { - return; - } - $this->removeDirectory($this->directory); - } - protected function removeDirectory($directory) - { - $iterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($directory), \RecursiveIteratorIterator::CHILD_FIRST); - foreach ($iterator as $path) { - if (\preg_match('#[/\\\\]\\.\\.?$#', $path->__toString())) { - continue; - } - if ($path->isDir()) { - \rmdir($path->__toString()); - } else { - \unlink($path->__toString()); - } - } - \rmdir($directory); - } - public function testGetResource() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); - $this->assertSame(\realpath($this->directory), $resource->getResource(), '->getResource() returns the path to the resource'); - } - public function testGetPattern() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, 'bar'); - $this->assertEquals('bar', $resource->getPattern()); - } - public function testResourceDoesNotExist() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/The directory ".*" does not exist./'); - new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource('/____foo/foobar' . \mt_rand(1, 999999)); - } - public function testIsFresh() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); - $this->assertTrue($resource->isFresh(\time() + 10), '->isFresh() returns true if the resource has not changed'); - $this->assertFalse($resource->isFresh(\time() - 86400), '->isFresh() returns false if the resource has been updated'); - } - public function testIsFreshForDeletedResources() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); - $this->removeDirectory($this->directory); - $this->assertFalse($resource->isFresh(\time()), '->isFresh() returns false if the resource does not exist'); - } - public function testIsFreshUpdateFile() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); - \touch($this->directory . '/tmp.xml', \time() + 20); - $this->assertFalse($resource->isFresh(\time() + 10), '->isFresh() returns false if an existing file is modified'); - } - public function testIsFreshNewFile() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); - \touch($this->directory . '/new.xml', \time() + 20); - $this->assertFalse($resource->isFresh(\time() + 10), '->isFresh() returns false if a new file is added'); - } - public function testIsFreshNewFileWithDifferentPattern() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/.xml$/'); - \touch($this->directory . '/new.yaml', \time() + 20); - $this->assertTrue($resource->isFresh(\time() + 10), '->isFresh() returns true if a new file with a non-matching pattern is added'); - } - public function testIsFreshDeleteFile() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); - $time = \time(); - \sleep(1); - \unlink($this->directory . '/tmp.xml'); - $this->assertFalse($resource->isFresh($time), '->isFresh() returns false if an existing file is removed'); - } - public function testIsFreshDeleteDirectory() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); - $this->removeDirectory($this->directory); - $this->assertFalse($resource->isFresh(\time()), '->isFresh() returns false if the whole resource is removed'); - } - public function testIsFreshCreateFileInSubdirectory() - { - $subdirectory = $this->directory . '/subdirectory'; - \mkdir($subdirectory); - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); - $this->assertTrue($resource->isFresh(\time() + 10), '->isFresh() returns true if an unmodified subdirectory exists'); - \touch($subdirectory . '/newfile.xml', \time() + 20); - $this->assertFalse($resource->isFresh(\time() + 10), '->isFresh() returns false if a new file in a subdirectory is added'); - } - public function testIsFreshModifySubdirectory() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); - $subdirectory = $this->directory . '/subdirectory'; - \mkdir($subdirectory); - \touch($subdirectory, \time() + 20); - $this->assertFalse($resource->isFresh(\time() + 10), '->isFresh() returns false if a subdirectory is modified (e.g. a file gets deleted)'); - } - public function testFilterRegexListNoMatch() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/\\.(foo|xml)$/'); - \touch($this->directory . '/new.bar', \time() + 20); - $this->assertTrue($resource->isFresh(\time() + 10), '->isFresh() returns true if a new file not matching the filter regex is created'); - } - public function testFilterRegexListMatch() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/\\.(foo|xml)$/'); - \touch($this->directory . '/new.xml', \time() + 20); - $this->assertFalse($resource->isFresh(\time() + 10), '->isFresh() returns false if an new file matching the filter regex is created '); - } - public function testSerializeUnserialize() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/\\.(foo|xml)$/'); - \unserialize(\serialize($resource)); - $this->assertSame(\realpath($this->directory), $resource->getResource()); - $this->assertSame('/\\.(foo|xml)$/', $resource->getPattern()); - } - public function testResourcesWithDifferentPatternsAreDifferent() - { - $resourceA = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/.xml$/'); - $resourceB = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/.yaml$/'); - $this->assertCount(2, \array_unique([$resourceA, $resourceB])); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource; +class DirectoryResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected $directory; + protected function setUp() + { + $this->directory = \sys_get_temp_dir() . \DIRECTORY_SEPARATOR . 'symfonyDirectoryIterator'; + if (!\file_exists($this->directory)) { + \mkdir($this->directory); + } + \touch($this->directory . '/tmp.xml'); + } + protected function tearDown() + { + if (!\is_dir($this->directory)) { + return; + } + $this->removeDirectory($this->directory); + } + protected function removeDirectory($directory) + { + $iterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($directory), \RecursiveIteratorIterator::CHILD_FIRST); + foreach ($iterator as $path) { + if (\preg_match('#[/\\\\]\\.\\.?$#', $path->__toString())) { + continue; + } + if ($path->isDir()) { + \rmdir($path->__toString()); + } else { + \unlink($path->__toString()); + } + } + \rmdir($directory); + } + public function testGetResource() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); + $this->assertSame(\realpath($this->directory), $resource->getResource(), '->getResource() returns the path to the resource'); + } + public function testGetPattern() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, 'bar'); + $this->assertEquals('bar', $resource->getPattern()); + } + public function testResourceDoesNotExist() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/The directory ".*" does not exist./'); + new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource('/____foo/foobar' . \mt_rand(1, 999999)); + } + public function testIsFresh() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); + $this->assertTrue($resource->isFresh(\time() + 10), '->isFresh() returns true if the resource has not changed'); + $this->assertFalse($resource->isFresh(\time() - 86400), '->isFresh() returns false if the resource has been updated'); + } + public function testIsFreshForDeletedResources() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); + $this->removeDirectory($this->directory); + $this->assertFalse($resource->isFresh(\time()), '->isFresh() returns false if the resource does not exist'); + } + public function testIsFreshUpdateFile() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); + \touch($this->directory . '/tmp.xml', \time() + 20); + $this->assertFalse($resource->isFresh(\time() + 10), '->isFresh() returns false if an existing file is modified'); + } + public function testIsFreshNewFile() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); + \touch($this->directory . '/new.xml', \time() + 20); + $this->assertFalse($resource->isFresh(\time() + 10), '->isFresh() returns false if a new file is added'); + } + public function testIsFreshNewFileWithDifferentPattern() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/.xml$/'); + \touch($this->directory . '/new.yaml', \time() + 20); + $this->assertTrue($resource->isFresh(\time() + 10), '->isFresh() returns true if a new file with a non-matching pattern is added'); + } + public function testIsFreshDeleteFile() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); + $time = \time(); + \sleep(1); + \unlink($this->directory . '/tmp.xml'); + $this->assertFalse($resource->isFresh($time), '->isFresh() returns false if an existing file is removed'); + } + public function testIsFreshDeleteDirectory() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); + $this->removeDirectory($this->directory); + $this->assertFalse($resource->isFresh(\time()), '->isFresh() returns false if the whole resource is removed'); + } + public function testIsFreshCreateFileInSubdirectory() + { + $subdirectory = $this->directory . '/subdirectory'; + \mkdir($subdirectory); + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); + $this->assertTrue($resource->isFresh(\time() + 10), '->isFresh() returns true if an unmodified subdirectory exists'); + \touch($subdirectory . '/newfile.xml', \time() + 20); + $this->assertFalse($resource->isFresh(\time() + 10), '->isFresh() returns false if a new file in a subdirectory is added'); + } + public function testIsFreshModifySubdirectory() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory); + $subdirectory = $this->directory . '/subdirectory'; + \mkdir($subdirectory); + \touch($subdirectory, \time() + 20); + $this->assertFalse($resource->isFresh(\time() + 10), '->isFresh() returns false if a subdirectory is modified (e.g. a file gets deleted)'); + } + public function testFilterRegexListNoMatch() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/\\.(foo|xml)$/'); + \touch($this->directory . '/new.bar', \time() + 20); + $this->assertTrue($resource->isFresh(\time() + 10), '->isFresh() returns true if a new file not matching the filter regex is created'); + } + public function testFilterRegexListMatch() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/\\.(foo|xml)$/'); + \touch($this->directory . '/new.xml', \time() + 20); + $this->assertFalse($resource->isFresh(\time() + 10), '->isFresh() returns false if an new file matching the filter regex is created '); + } + public function testSerializeUnserialize() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/\\.(foo|xml)$/'); + \unserialize(\serialize($resource)); + $this->assertSame(\realpath($this->directory), $resource->getResource()); + $this->assertSame('/\\.(foo|xml)$/', $resource->getPattern()); + } + public function testResourcesWithDifferentPatternsAreDifferent() + { + $resourceA = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/.xml$/'); + $resourceB = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($this->directory, '/.yaml$/'); + $this->assertCount(2, \array_unique([$resourceA, $resourceB])); + } +} diff --git a/vendor/symfony/config/Tests/Resource/FileExistenceResourceTest.php b/vendor/symfony/config/Tests/Resource/FileExistenceResourceTest.php index e2a3a72ad..1c9a3c399 100644 --- a/vendor/symfony/config/Tests/Resource/FileExistenceResourceTest.php +++ b/vendor/symfony/config/Tests/Resource/FileExistenceResourceTest.php @@ -1,59 +1,59 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource; -class FileExistenceResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected $resource; - protected $file; - protected $time; - protected function setUp() - { - $this->file = \realpath(\sys_get_temp_dir()) . '/tmp.xml'; - $this->time = \time(); - $this->resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource($this->file); - } - protected function tearDown() - { - if (\file_exists($this->file)) { - \unlink($this->file); - } - } - public function testToString() - { - $this->assertSame($this->file, (string) $this->resource); - } - public function testGetResource() - { - $this->assertSame($this->file, $this->resource->getResource(), '->getResource() returns the path to the resource'); - } - public function testIsFreshWithExistingResource() - { - \touch($this->file, $this->time); - $serialized = \serialize(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource($this->file)); - $resource = \unserialize($serialized); - $this->assertTrue($resource->isFresh($this->time), '->isFresh() returns true if the resource is still present'); - \unlink($this->file); - $resource = \unserialize($serialized); - $this->assertFalse($resource->isFresh($this->time), '->isFresh() returns false if the resource has been deleted'); - } - public function testIsFreshWithAbsentResource() - { - $serialized = \serialize(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource($this->file)); - $resource = \unserialize($serialized); - $this->assertTrue($resource->isFresh($this->time), '->isFresh() returns true if the resource is still absent'); - \touch($this->file, $this->time); - $resource = \unserialize($serialized); - $this->assertFalse($resource->isFresh($this->time), '->isFresh() returns false if the resource has been created'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource; +class FileExistenceResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected $resource; + protected $file; + protected $time; + protected function setUp() + { + $this->file = \realpath(\sys_get_temp_dir()) . '/tmp.xml'; + $this->time = \time(); + $this->resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource($this->file); + } + protected function tearDown() + { + if (\file_exists($this->file)) { + \unlink($this->file); + } + } + public function testToString() + { + $this->assertSame($this->file, (string) $this->resource); + } + public function testGetResource() + { + $this->assertSame($this->file, $this->resource->getResource(), '->getResource() returns the path to the resource'); + } + public function testIsFreshWithExistingResource() + { + \touch($this->file, $this->time); + $serialized = \serialize(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource($this->file)); + $resource = \unserialize($serialized); + $this->assertTrue($resource->isFresh($this->time), '->isFresh() returns true if the resource is still present'); + \unlink($this->file); + $resource = \unserialize($serialized); + $this->assertFalse($resource->isFresh($this->time), '->isFresh() returns false if the resource has been deleted'); + } + public function testIsFreshWithAbsentResource() + { + $serialized = \serialize(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource($this->file)); + $resource = \unserialize($serialized); + $this->assertTrue($resource->isFresh($this->time), '->isFresh() returns true if the resource is still absent'); + \touch($this->file, $this->time); + $resource = \unserialize($serialized); + $this->assertFalse($resource->isFresh($this->time), '->isFresh() returns false if the resource has been created'); + } +} diff --git a/vendor/symfony/config/Tests/Resource/FileResourceTest.php b/vendor/symfony/config/Tests/Resource/FileResourceTest.php index 844fd36e7..da07e387b 100644 --- a/vendor/symfony/config/Tests/Resource/FileResourceTest.php +++ b/vendor/symfony/config/Tests/Resource/FileResourceTest.php @@ -1,69 +1,69 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; -class FileResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected $resource; - protected $file; - protected $time; - protected function setUp() - { - $this->file = \sys_get_temp_dir() . '/tmp.xml'; - $this->time = \time(); - \touch($this->file, $this->time); - $this->resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource($this->file); - } - protected function tearDown() - { - if (!\file_exists($this->file)) { - return; - } - \unlink($this->file); - } - public function testGetResource() - { - $this->assertSame(\realpath($this->file), $this->resource->getResource(), '->getResource() returns the path to the resource'); - } - public function testGetResourceWithScheme() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource('file://' . $this->file); - $this->assertSame('file://' . $this->file, $resource->getResource(), '->getResource() returns the path to the schemed resource'); - } - public function testToString() - { - $this->assertSame(\realpath($this->file), (string) $this->resource); - } - public function testResourceDoesNotExist() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/The file ".*" does not exist./'); - new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource('/____foo/foobar' . \mt_rand(1, 999999)); - } - public function testIsFresh() - { - $this->assertTrue($this->resource->isFresh($this->time), '->isFresh() returns true if the resource has not changed in same second'); - $this->assertTrue($this->resource->isFresh($this->time + 10), '->isFresh() returns true if the resource has not changed'); - $this->assertFalse($this->resource->isFresh($this->time - 86400), '->isFresh() returns false if the resource has been updated'); - } - public function testIsFreshForDeletedResources() - { - \unlink($this->file); - $this->assertFalse($this->resource->isFresh($this->time), '->isFresh() returns false if the resource does not exist'); - } - public function testSerializeUnserialize() - { - \unserialize(\serialize($this->resource)); - $this->assertSame(\realpath($this->file), $this->resource->getResource()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; +class FileResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected $resource; + protected $file; + protected $time; + protected function setUp() + { + $this->file = \sys_get_temp_dir() . '/tmp.xml'; + $this->time = \time(); + \touch($this->file, $this->time); + $this->resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource($this->file); + } + protected function tearDown() + { + if (!\file_exists($this->file)) { + return; + } + \unlink($this->file); + } + public function testGetResource() + { + $this->assertSame(\realpath($this->file), $this->resource->getResource(), '->getResource() returns the path to the resource'); + } + public function testGetResourceWithScheme() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource('file://' . $this->file); + $this->assertSame('file://' . $this->file, $resource->getResource(), '->getResource() returns the path to the schemed resource'); + } + public function testToString() + { + $this->assertSame(\realpath($this->file), (string) $this->resource); + } + public function testResourceDoesNotExist() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/The file ".*" does not exist./'); + new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource('/____foo/foobar' . \mt_rand(1, 999999)); + } + public function testIsFresh() + { + $this->assertTrue($this->resource->isFresh($this->time), '->isFresh() returns true if the resource has not changed in same second'); + $this->assertTrue($this->resource->isFresh($this->time + 10), '->isFresh() returns true if the resource has not changed'); + $this->assertFalse($this->resource->isFresh($this->time - 86400), '->isFresh() returns false if the resource has been updated'); + } + public function testIsFreshForDeletedResources() + { + \unlink($this->file); + $this->assertFalse($this->resource->isFresh($this->time), '->isFresh() returns false if the resource does not exist'); + } + public function testSerializeUnserialize() + { + \unserialize(\serialize($this->resource)); + $this->assertSame(\realpath($this->file), $this->resource->getResource()); + } +} diff --git a/vendor/symfony/config/Tests/Resource/GlobResourceTest.php b/vendor/symfony/config/Tests/Resource/GlobResourceTest.php index a9765775a..983f19f66 100644 --- a/vendor/symfony/config/Tests/Resource/GlobResourceTest.php +++ b/vendor/symfony/config/Tests/Resource/GlobResourceTest.php @@ -1,88 +1,88 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; -class GlobResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected function tearDown() - { - $dir = \dirname(__DIR__) . '/Fixtures'; - @\rmdir($dir . '/TmpGlob'); - @\unlink($dir . '/TmpGlob'); - @\unlink($dir . '/Resource/TmpGlob'); - \touch($dir . '/Resource/.hiddenFile'); - } - public function testIterator() - { - $dir = \dirname(__DIR__) . \DIRECTORY_SEPARATOR . 'Fixtures'; - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/Resource', \true); - $paths = \iterator_to_array($resource); - $file = $dir . '/Resource' . \DIRECTORY_SEPARATOR . 'ConditionalClass.php'; - $this->assertEquals([$file => new \SplFileInfo($file)], $paths); - $this->assertInstanceOf('SplFileInfo', \current($paths)); - $this->assertSame($dir, $resource->getPrefix()); - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/**/Resource', \true); - $paths = \iterator_to_array($resource); - $file = $dir . \DIRECTORY_SEPARATOR . 'Resource' . \DIRECTORY_SEPARATOR . 'ConditionalClass.php'; - $this->assertEquals([$file => $file], $paths); - $this->assertInstanceOf('SplFileInfo', \current($paths)); - $this->assertSame($dir, $resource->getPrefix()); - } - public function testIsFreshNonRecursiveDetectsNewFile() - { - $dir = \dirname(__DIR__) . '/Fixtures'; - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/*', \false); - $this->assertTrue($resource->isFresh(0)); - \mkdir($dir . '/TmpGlob'); - $this->assertTrue($resource->isFresh(0)); - \rmdir($dir . '/TmpGlob'); - $this->assertTrue($resource->isFresh(0)); - \touch($dir . '/TmpGlob'); - $this->assertFalse($resource->isFresh(0)); - \unlink($dir . '/TmpGlob'); - $this->assertTrue($resource->isFresh(0)); - } - public function testIsFreshNonRecursiveDetectsRemovedFile() - { - $dir = \dirname(__DIR__) . '/Fixtures'; - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/*', \false); - \touch($dir . '/TmpGlob'); - \touch($dir . '/.TmpGlob'); - $this->assertTrue($resource->isFresh(0)); - \unlink($dir . '/.TmpGlob'); - $this->assertTrue($resource->isFresh(0)); - \unlink($dir . '/TmpGlob'); - $this->assertFalse($resource->isFresh(0)); - } - public function testIsFreshRecursiveDetectsRemovedFile() - { - $dir = \dirname(__DIR__) . '/Fixtures'; - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/*', \true); - \touch($dir . '/Resource/TmpGlob'); - $this->assertTrue($resource->isFresh(0)); - \unlink($dir . '/Resource/TmpGlob'); - $this->assertFalse($resource->isFresh(0)); - \touch($dir . '/Resource/TmpGlob'); - $this->assertTrue($resource->isFresh(0)); - \unlink($dir . '/Resource/.hiddenFile'); - $this->assertTrue($resource->isFresh(0)); - } - public function testIsFreshRecursiveDetectsNewFile() - { - $dir = \dirname(__DIR__) . '/Fixtures'; - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/*', \true); - $this->assertTrue($resource->isFresh(0)); - \touch($dir . '/Resource/TmpGlob'); - $this->assertFalse($resource->isFresh(0)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; +class GlobResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected function tearDown() + { + $dir = \dirname(__DIR__) . '/Fixtures'; + @\rmdir($dir . '/TmpGlob'); + @\unlink($dir . '/TmpGlob'); + @\unlink($dir . '/Resource/TmpGlob'); + \touch($dir . '/Resource/.hiddenFile'); + } + public function testIterator() + { + $dir = \dirname(__DIR__) . \DIRECTORY_SEPARATOR . 'Fixtures'; + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/Resource', \true); + $paths = \iterator_to_array($resource); + $file = $dir . '/Resource' . \DIRECTORY_SEPARATOR . 'ConditionalClass.php'; + $this->assertEquals([$file => new \SplFileInfo($file)], $paths); + $this->assertInstanceOf('SplFileInfo', \current($paths)); + $this->assertSame($dir, $resource->getPrefix()); + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/**/Resource', \true); + $paths = \iterator_to_array($resource); + $file = $dir . \DIRECTORY_SEPARATOR . 'Resource' . \DIRECTORY_SEPARATOR . 'ConditionalClass.php'; + $this->assertEquals([$file => $file], $paths); + $this->assertInstanceOf('SplFileInfo', \current($paths)); + $this->assertSame($dir, $resource->getPrefix()); + } + public function testIsFreshNonRecursiveDetectsNewFile() + { + $dir = \dirname(__DIR__) . '/Fixtures'; + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/*', \false); + $this->assertTrue($resource->isFresh(0)); + \mkdir($dir . '/TmpGlob'); + $this->assertTrue($resource->isFresh(0)); + \rmdir($dir . '/TmpGlob'); + $this->assertTrue($resource->isFresh(0)); + \touch($dir . '/TmpGlob'); + $this->assertFalse($resource->isFresh(0)); + \unlink($dir . '/TmpGlob'); + $this->assertTrue($resource->isFresh(0)); + } + public function testIsFreshNonRecursiveDetectsRemovedFile() + { + $dir = \dirname(__DIR__) . '/Fixtures'; + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/*', \false); + \touch($dir . '/TmpGlob'); + \touch($dir . '/.TmpGlob'); + $this->assertTrue($resource->isFresh(0)); + \unlink($dir . '/.TmpGlob'); + $this->assertTrue($resource->isFresh(0)); + \unlink($dir . '/TmpGlob'); + $this->assertFalse($resource->isFresh(0)); + } + public function testIsFreshRecursiveDetectsRemovedFile() + { + $dir = \dirname(__DIR__) . '/Fixtures'; + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/*', \true); + \touch($dir . '/Resource/TmpGlob'); + $this->assertTrue($resource->isFresh(0)); + \unlink($dir . '/Resource/TmpGlob'); + $this->assertFalse($resource->isFresh(0)); + \touch($dir . '/Resource/TmpGlob'); + $this->assertTrue($resource->isFresh(0)); + \unlink($dir . '/Resource/.hiddenFile'); + $this->assertTrue($resource->isFresh(0)); + } + public function testIsFreshRecursiveDetectsNewFile() + { + $dir = \dirname(__DIR__) . '/Fixtures'; + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($dir, '/*', \true); + $this->assertTrue($resource->isFresh(0)); + \touch($dir . '/Resource/TmpGlob'); + $this->assertFalse($resource->isFresh(0)); + } +} diff --git a/vendor/symfony/config/Tests/Resource/ReflectionClassResourceTest.php b/vendor/symfony/config/Tests/Resource/ReflectionClassResourceTest.php index ab738f0b0..e4bfc267d 100644 --- a/vendor/symfony/config/Tests/Resource/ReflectionClassResourceTest.php +++ b/vendor/symfony/config/Tests/Resource/ReflectionClassResourceTest.php @@ -1,191 +1,191 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface; -class ReflectionClassResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testToString() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass('ErrorException')); - $this->assertSame('reflection.ErrorException', (string) $res); - } - public function testSerializeUnserialize() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\DummyInterface::class)); - $ser = \unserialize(\serialize($res)); - $this->assertTrue($res->isFresh(0)); - $this->assertTrue($ser->isFresh(0)); - $this->assertSame((string) $res, (string) $ser); - } - public function testIsFresh() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(__CLASS__)); - $mtime = \filemtime(__FILE__); - $this->assertTrue($res->isFresh($mtime), '->isFresh() returns true if the resource has not changed in same second'); - $this->assertTrue($res->isFresh($mtime + 10), '->isFresh() returns true if the resource has not changed'); - $this->assertTrue($res->isFresh($mtime - 86400), '->isFresh() returns true if the resource has not changed'); - } - public function testIsFreshForDeletedResources() - { - $now = \time(); - $tmp = \sys_get_temp_dir() . '/tmp.php'; - \file_put_contents($tmp, 'assertTrue($res->isFresh($now)); - \unlink($tmp); - $this->assertFalse($res->isFresh($now), '->isFresh() returns false if the resource does not exist'); - } - /** - * @dataProvider provideHashedSignature - */ - public function testHashedSignature($changeExpected, $changedLine, $changedCode, $setContext = null) - { - if ($setContext) { - $setContext(); - } - $code = <<<'EOPHP' -/* 0*/ -/* 1*/ class %s extends ErrorException -/* 2*/ { -/* 3*/ const FOO = 123; -/* 4*/ -/* 5*/ public $pub = []; -/* 6*/ -/* 7*/ protected $prot; -/* 8*/ -/* 9*/ private $priv; -/*10*/ -/*11*/ public function pub($arg = null) {} -/*12*/ -/*13*/ protected function prot($a = []) {} -/*14*/ -/*15*/ private function priv() {} -/*16*/ -/*17*/ public function ccc($bar = A_CONSTANT_THAT_FOR_SURE_WILL_NEVER_BE_DEFINED_CCCCCC) {} -/*18*/ } -EOPHP; - static $expectedSignature, $generateSignature; - if (null === $expectedSignature) { - eval(\sprintf($code, $class = 'Foo' . \str_replace('.', '_', \uniqid('', \true)))); - $r = new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource::class); - $generateSignature = $r->getMethod('generateSignature'); - $generateSignature->setAccessible(\true); - $generateSignature = $generateSignature->getClosure($r->newInstanceWithoutConstructor()); - $expectedSignature = \implode("\n", \iterator_to_array($generateSignature(new \ReflectionClass($class)))); - } - $code = \explode("\n", $code); - if (null !== $changedCode) { - $code[$changedLine] = $changedCode; - } - eval(\sprintf(\implode("\n", $code), $class = 'Foo' . \str_replace('.', '_', \uniqid('', \true)))); - $signature = \implode("\n", \iterator_to_array($generateSignature(new \ReflectionClass($class)))); - if ($changeExpected) { - $this->assertNotSame($expectedSignature, $signature); - } else { - $this->assertSame($expectedSignature, $signature); - } - } - public function provideHashedSignature() - { - (yield [0, 0, "// line change\n\n"]); - (yield [1, 0, '/** class docblock */']); - (yield [1, 1, 'abstract class %s']); - (yield [1, 1, 'final class %s']); - (yield [1, 1, 'class %s extends Exception']); - (yield [1, 1, 'class %s implements ' . \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\DummyInterface::class]); - (yield [1, 3, 'const FOO = 456;']); - (yield [1, 3, 'const BAR = 123;']); - (yield [1, 4, '/** pub docblock */']); - (yield [1, 5, 'protected $pub = [];']); - (yield [1, 5, 'public $pub = [123];']); - (yield [1, 6, '/** prot docblock */']); - (yield [1, 7, 'private $prot;']); - (yield [0, 8, '/** priv docblock */']); - (yield [0, 9, 'private $priv = 123;']); - (yield [1, 10, '/** pub docblock */']); - if (\PHP_VERSION_ID >= 50600) { - (yield [1, 11, 'public function pub(...$arg) {}']); - } - if (\PHP_VERSION_ID >= 70000) { - (yield [1, 11, 'public function pub($arg = null): Foo {}']); - } - (yield [0, 11, "public function pub(\$arg = null) {\nreturn 123;\n}"]); - (yield [1, 12, '/** prot docblock */']); - (yield [1, 13, 'protected function prot($a = [123]) {}']); - (yield [0, 14, '/** priv docblock */']); - (yield [0, 15, '']); - if (\PHP_VERSION_ID >= 70400) { - // PHP7.4 typed properties without default value are - // undefined, make sure this doesn't throw an error - (yield [1, 5, 'public array $pub;']); - (yield [0, 7, 'protected int $prot;']); - (yield [0, 9, 'private string $priv;']); - } - (yield [1, 17, 'public function ccc($bar = 187) {}']); - (yield [1, 17, 'public function ccc($bar = ANOTHER_ONE_THAT_WILL_NEVER_BE_DEFINED_CCCCCCCCC) {}']); - (yield [1, 17, null, static function () { - \define('A_CONSTANT_THAT_FOR_SURE_WILL_NEVER_BE_DEFINED_CCCCCC', 'foo'); - }]); - } - public function testEventSubscriber() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestEventSubscriber::class)); - $this->assertTrue($res->isFresh(0)); - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestEventSubscriber::$subscribedEvents = [123]; - $this->assertFalse($res->isFresh(0)); - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestEventSubscriber::class)); - $this->assertTrue($res->isFresh(0)); - } - public function testServiceSubscriber() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceSubscriber::class)); - $this->assertTrue($res->isFresh(0)); - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceSubscriber::$subscribedServices = [123]; - $this->assertFalse($res->isFresh(0)); - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceSubscriber::class)); - $this->assertTrue($res->isFresh(0)); - } - public function testIgnoresObjectsInSignature() - { - $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceWithStaticProperty::class)); - $this->assertTrue($res->isFresh(0)); - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceWithStaticProperty::$initializedObject = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceWithStaticProperty(); - $this->assertTrue($res->isFresh(0)); - } -} -interface DummyInterface -{ -} -class TestEventSubscriber implements \_PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface -{ - public static $subscribedEvents = []; - public static function getSubscribedEvents() - { - return self::$subscribedEvents; - } -} -class TestServiceSubscriber implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface -{ - public static $subscribedServices = []; - public static function getSubscribedServices() - { - return self::$subscribedServices; - } -} -class TestServiceWithStaticProperty -{ - public static $initializedObject; -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface; +class ReflectionClassResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testToString() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass('ErrorException')); + $this->assertSame('reflection.ErrorException', (string) $res); + } + public function testSerializeUnserialize() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\DummyInterface::class)); + $ser = \unserialize(\serialize($res)); + $this->assertTrue($res->isFresh(0)); + $this->assertTrue($ser->isFresh(0)); + $this->assertSame((string) $res, (string) $ser); + } + public function testIsFresh() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(__CLASS__)); + $mtime = \filemtime(__FILE__); + $this->assertTrue($res->isFresh($mtime), '->isFresh() returns true if the resource has not changed in same second'); + $this->assertTrue($res->isFresh($mtime + 10), '->isFresh() returns true if the resource has not changed'); + $this->assertTrue($res->isFresh($mtime - 86400), '->isFresh() returns true if the resource has not changed'); + } + public function testIsFreshForDeletedResources() + { + $now = \time(); + $tmp = \sys_get_temp_dir() . '/tmp.php'; + \file_put_contents($tmp, 'assertTrue($res->isFresh($now)); + \unlink($tmp); + $this->assertFalse($res->isFresh($now), '->isFresh() returns false if the resource does not exist'); + } + /** + * @dataProvider provideHashedSignature + */ + public function testHashedSignature($changeExpected, $changedLine, $changedCode, $setContext = null) + { + if ($setContext) { + $setContext(); + } + $code = <<<'EOPHP' +/* 0*/ +/* 1*/ class %s extends ErrorException +/* 2*/ { +/* 3*/ const FOO = 123; +/* 4*/ +/* 5*/ public $pub = []; +/* 6*/ +/* 7*/ protected $prot; +/* 8*/ +/* 9*/ private $priv; +/*10*/ +/*11*/ public function pub($arg = null) {} +/*12*/ +/*13*/ protected function prot($a = []) {} +/*14*/ +/*15*/ private function priv() {} +/*16*/ +/*17*/ public function ccc($bar = A_CONSTANT_THAT_FOR_SURE_WILL_NEVER_BE_DEFINED_CCCCCC) {} +/*18*/ } +EOPHP; + static $expectedSignature, $generateSignature; + if (null === $expectedSignature) { + eval(\sprintf($code, $class = 'Foo' . \str_replace('.', '_', \uniqid('', \true)))); + $r = new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource::class); + $generateSignature = $r->getMethod('generateSignature'); + $generateSignature->setAccessible(\true); + $generateSignature = $generateSignature->getClosure($r->newInstanceWithoutConstructor()); + $expectedSignature = \implode("\n", \iterator_to_array($generateSignature(new \ReflectionClass($class)))); + } + $code = \explode("\n", $code); + if (null !== $changedCode) { + $code[$changedLine] = $changedCode; + } + eval(\sprintf(\implode("\n", $code), $class = 'Foo' . \str_replace('.', '_', \uniqid('', \true)))); + $signature = \implode("\n", \iterator_to_array($generateSignature(new \ReflectionClass($class)))); + if ($changeExpected) { + $this->assertNotSame($expectedSignature, $signature); + } else { + $this->assertSame($expectedSignature, $signature); + } + } + public function provideHashedSignature() + { + (yield [0, 0, "// line change\n\n"]); + (yield [1, 0, '/** class docblock */']); + (yield [1, 1, 'abstract class %s']); + (yield [1, 1, 'final class %s']); + (yield [1, 1, 'class %s extends Exception']); + (yield [1, 1, 'class %s implements ' . \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\DummyInterface::class]); + (yield [1, 3, 'const FOO = 456;']); + (yield [1, 3, 'const BAR = 123;']); + (yield [1, 4, '/** pub docblock */']); + (yield [1, 5, 'protected $pub = [];']); + (yield [1, 5, 'public $pub = [123];']); + (yield [1, 6, '/** prot docblock */']); + (yield [1, 7, 'private $prot;']); + (yield [0, 8, '/** priv docblock */']); + (yield [0, 9, 'private $priv = 123;']); + (yield [1, 10, '/** pub docblock */']); + if (\PHP_VERSION_ID >= 50600) { + (yield [1, 11, 'public function pub(...$arg) {}']); + } + if (\PHP_VERSION_ID >= 70000) { + (yield [1, 11, 'public function pub($arg = null): Foo {}']); + } + (yield [0, 11, "public function pub(\$arg = null) {\nreturn 123;\n}"]); + (yield [1, 12, '/** prot docblock */']); + (yield [1, 13, 'protected function prot($a = [123]) {}']); + (yield [0, 14, '/** priv docblock */']); + (yield [0, 15, '']); + if (\PHP_VERSION_ID >= 70400) { + // PHP7.4 typed properties without default value are + // undefined, make sure this doesn't throw an error + (yield [1, 5, 'public array $pub;']); + (yield [0, 7, 'protected int $prot;']); + (yield [0, 9, 'private string $priv;']); + } + (yield [1, 17, 'public function ccc($bar = 187) {}']); + (yield [1, 17, 'public function ccc($bar = ANOTHER_ONE_THAT_WILL_NEVER_BE_DEFINED_CCCCCCCCC) {}']); + (yield [1, 17, null, static function () { + \define('A_CONSTANT_THAT_FOR_SURE_WILL_NEVER_BE_DEFINED_CCCCCC', 'foo'); + }]); + } + public function testEventSubscriber() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestEventSubscriber::class)); + $this->assertTrue($res->isFresh(0)); + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestEventSubscriber::$subscribedEvents = [123]; + $this->assertFalse($res->isFresh(0)); + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestEventSubscriber::class)); + $this->assertTrue($res->isFresh(0)); + } + public function testServiceSubscriber() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceSubscriber::class)); + $this->assertTrue($res->isFresh(0)); + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceSubscriber::$subscribedServices = [123]; + $this->assertFalse($res->isFresh(0)); + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceSubscriber::class)); + $this->assertTrue($res->isFresh(0)); + } + public function testIgnoresObjectsInSignature() + { + $res = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceWithStaticProperty::class)); + $this->assertTrue($res->isFresh(0)); + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceWithStaticProperty::$initializedObject = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\TestServiceWithStaticProperty(); + $this->assertTrue($res->isFresh(0)); + } +} +interface DummyInterface +{ +} +class TestEventSubscriber implements \_PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\EventSubscriberInterface +{ + public static $subscribedEvents = []; + public static function getSubscribedEvents() + { + return self::$subscribedEvents; + } +} +class TestServiceSubscriber implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface +{ + public static $subscribedServices = []; + public static function getSubscribedServices() + { + return self::$subscribedServices; + } +} +class TestServiceWithStaticProperty +{ + public static $initializedObject; +} diff --git a/vendor/symfony/config/Tests/Resource/ResourceStub.php b/vendor/symfony/config/Tests/Resource/ResourceStub.php index a39abc45b..58ba4f1c1 100644 --- a/vendor/symfony/config/Tests/Resource/ResourceStub.php +++ b/vendor/symfony/config/Tests/Resource/ResourceStub.php @@ -1,29 +1,29 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface; -class ResourceStub implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface -{ - private $fresh = \true; - public function setFresh($isFresh) - { - $this->fresh = $isFresh; - } - public function __toString() - { - return 'stub'; - } - public function isFresh($timestamp) - { - return $this->fresh; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface; +class ResourceStub implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface +{ + private $fresh = \true; + public function setFresh($isFresh) + { + $this->fresh = $isFresh; + } + public function __toString() + { + return 'stub'; + } + public function isFresh($timestamp) + { + return $this->fresh; + } +} diff --git a/vendor/symfony/config/Tests/Resource/index.php b/vendor/symfony/config/Tests/Resource/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Resource/index.php +++ b/vendor/symfony/config/Tests/Resource/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/ResourceCheckerConfigCacheTest.php b/vendor/symfony/config/Tests/ResourceCheckerConfigCacheTest.php index 8753de768..13e8f3b19 100644 --- a/vendor/symfony/config/Tests/ResourceCheckerConfigCacheTest.php +++ b/vendor/symfony/config/Tests/ResourceCheckerConfigCacheTest.php @@ -1,110 +1,110 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub; -class ResourceCheckerConfigCacheTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - private $cacheFile = null; - protected function setUp() - { - $this->cacheFile = \tempnam(\sys_get_temp_dir(), 'config_'); - } - protected function tearDown() - { - $files = [$this->cacheFile, "{$this->cacheFile}.meta"]; - foreach ($files as $file) { - if (\file_exists($file)) { - \unlink($file); - } - } - } - public function testGetPath() - { - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile); - $this->assertSame($this->cacheFile, $cache->getPath()); - } - public function testCacheIsNotFreshIfEmpty() - { - $checker = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface')->getMock()->expects($this->never())->method('supports'); - /* If there is nothing in the cache, it needs to be filled (and thus it's not fresh). - It does not matter if you provide checkers or not. */ - \unlink($this->cacheFile); - // remove tempnam() side effect - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, [$checker]); - $this->assertFalse($cache->isFresh()); - } - public function testCacheIsFreshIfNoCheckerProvided() - { - /* For example in prod mode, you may choose not to run any checkers - at all. In that case, the cache should always be considered fresh. */ - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile); - $this->assertTrue($cache->isFresh()); - } - public function testCacheIsFreshIfEmptyCheckerIteratorProvided() - { - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, new \ArrayIterator([])); - $this->assertTrue($cache->isFresh()); - } - public function testResourcesWithoutcheckersAreIgnoredAndConsideredFresh() - { - /* As in the previous test, but this time we have a resource. */ - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile); - $cache->write('', [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub()]); - $this->assertTrue($cache->isFresh()); - // no (matching) ResourceChecker passed - } - public function testIsFreshWithchecker() - { - $checker = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface')->getMock(); - $checker->expects($this->once())->method('supports')->willReturn(\true); - $checker->expects($this->once())->method('isFresh')->willReturn(\true); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, [$checker]); - $cache->write('', [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub()]); - $this->assertTrue($cache->isFresh()); - } - public function testIsNotFreshWithchecker() - { - $checker = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface')->getMock(); - $checker->expects($this->once())->method('supports')->willReturn(\true); - $checker->expects($this->once())->method('isFresh')->willReturn(\false); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, [$checker]); - $cache->write('', [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub()]); - $this->assertFalse($cache->isFresh()); - } - public function testCacheIsNotFreshWhenUnserializeFails() - { - $checker = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface')->getMock(); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, [$checker]); - $cache->write('foo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__FILE__)]); - $metaFile = "{$this->cacheFile}.meta"; - \file_put_contents($metaFile, \str_replace('FileResource', 'ClassNotHere', \file_get_contents($metaFile))); - $this->assertFalse($cache->isFresh()); - } - public function testCacheKeepsContent() - { - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile); - $cache->write('FOOBAR'); - $this->assertSame('FOOBAR', \file_get_contents($cache->getPath())); - } - public function testCacheIsNotFreshIfNotExistsMetaFile() - { - $checker = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface')->getMock(); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, [$checker]); - $cache->write('foo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__FILE__)]); - $metaFile = "{$this->cacheFile}.meta"; - \unlink($metaFile); - $this->assertFalse($cache->isFresh()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub; +class ResourceCheckerConfigCacheTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + private $cacheFile = null; + protected function setUp() + { + $this->cacheFile = \tempnam(\sys_get_temp_dir(), 'config_'); + } + protected function tearDown() + { + $files = [$this->cacheFile, "{$this->cacheFile}.meta"]; + foreach ($files as $file) { + if (\file_exists($file)) { + \unlink($file); + } + } + } + public function testGetPath() + { + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile); + $this->assertSame($this->cacheFile, $cache->getPath()); + } + public function testCacheIsNotFreshIfEmpty() + { + $checker = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface')->getMock()->expects($this->never())->method('supports'); + /* If there is nothing in the cache, it needs to be filled (and thus it's not fresh). + It does not matter if you provide checkers or not. */ + \unlink($this->cacheFile); + // remove tempnam() side effect + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, [$checker]); + $this->assertFalse($cache->isFresh()); + } + public function testCacheIsFreshIfNoCheckerProvided() + { + /* For example in prod mode, you may choose not to run any checkers + at all. In that case, the cache should always be considered fresh. */ + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile); + $this->assertTrue($cache->isFresh()); + } + public function testCacheIsFreshIfEmptyCheckerIteratorProvided() + { + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, new \ArrayIterator([])); + $this->assertTrue($cache->isFresh()); + } + public function testResourcesWithoutcheckersAreIgnoredAndConsideredFresh() + { + /* As in the previous test, but this time we have a resource. */ + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile); + $cache->write('', [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub()]); + $this->assertTrue($cache->isFresh()); + // no (matching) ResourceChecker passed + } + public function testIsFreshWithchecker() + { + $checker = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface')->getMock(); + $checker->expects($this->once())->method('supports')->willReturn(\true); + $checker->expects($this->once())->method('isFresh')->willReturn(\true); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, [$checker]); + $cache->write('', [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub()]); + $this->assertTrue($cache->isFresh()); + } + public function testIsNotFreshWithchecker() + { + $checker = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface')->getMock(); + $checker->expects($this->once())->method('supports')->willReturn(\true); + $checker->expects($this->once())->method('isFresh')->willReturn(\false); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, [$checker]); + $cache->write('', [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Resource\ResourceStub()]); + $this->assertFalse($cache->isFresh()); + } + public function testCacheIsNotFreshWhenUnserializeFails() + { + $checker = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface')->getMock(); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, [$checker]); + $cache->write('foo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__FILE__)]); + $metaFile = "{$this->cacheFile}.meta"; + \file_put_contents($metaFile, \str_replace('FileResource', 'ClassNotHere', \file_get_contents($metaFile))); + $this->assertFalse($cache->isFresh()); + } + public function testCacheKeepsContent() + { + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile); + $cache->write('FOOBAR'); + $this->assertSame('FOOBAR', \file_get_contents($cache->getPath())); + } + public function testCacheIsNotFreshIfNotExistsMetaFile() + { + $checker = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\ResourceCheckerInterface')->getMock(); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerConfigCache($this->cacheFile, [$checker]); + $cache->write('foo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__FILE__)]); + $metaFile = "{$this->cacheFile}.meta"; + \unlink($metaFile); + $this->assertFalse($cache->isFresh()); + } +} diff --git a/vendor/symfony/config/Tests/Util/XmlUtilsTest.php b/vendor/symfony/config/Tests/Util/XmlUtilsTest.php index dede1d13d..bf2b4555f 100644 --- a/vendor/symfony/config/Tests/Util/XmlUtilsTest.php +++ b/vendor/symfony/config/Tests/Util/XmlUtilsTest.php @@ -1,158 +1,158 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Util; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils; -class XmlUtilsTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testLoadFile() - { - $fixtures = __DIR__ . '/../Fixtures/Util/'; - try { - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertStringContainsString('is not a file', $e->getMessage()); - } - try { - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'non_existing.xml'); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertStringContainsString('is not a file', $e->getMessage()); - } - try { - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('chmod is not supported on Windows'); - } - \chmod($fixtures . 'not_readable.xml', 00); - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'not_readable.xml'); - $this->fail(); - } catch (\InvalidArgumentException $e) { - \chmod($fixtures . 'not_readable.xml', 0644); - $this->assertStringContainsString('is not readable', $e->getMessage()); - } - try { - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'invalid.xml'); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertStringContainsString('ERROR ', $e->getMessage()); - } - try { - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'document_type.xml'); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertStringContainsString('Document types are not allowed', $e->getMessage()); - } - try { - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'invalid_schema.xml', $fixtures . 'schema.xsd'); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertStringContainsString('ERROR 1845', $e->getMessage()); - } - try { - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'invalid_schema.xml', 'invalid_callback_or_file'); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertStringContainsString('XSD file or callable', $e->getMessage()); - } - $mock = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Util\Validator::class)->getMock(); - $mock->expects($this->exactly(2))->method('validate')->will($this->onConsecutiveCalls(\false, \true)); - try { - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'valid.xml', [$mock, 'validate']); - $this->fail(); - } catch (\InvalidArgumentException $e) { - $this->assertRegExp('/The XML file ".+" is not valid\\./', $e->getMessage()); - } - $this->assertInstanceOf('DOMDocument', \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'valid.xml', [$mock, 'validate'])); - $this->assertSame([], \libxml_get_errors()); - } - public function testParseWithInvalidValidatorCallable() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\Exception\\InvalidXmlException'); - $this->expectExceptionMessage('The XML is not valid'); - $fixtures = __DIR__ . '/../Fixtures/Util/'; - $mock = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Util\Validator::class)->getMock(); - $mock->expects($this->once())->method('validate')->willReturn(\false); - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::parse(\file_get_contents($fixtures . 'valid.xml'), [$mock, 'validate']); - } - public function testLoadFileWithInternalErrorsEnabled() - { - $internalErrors = \libxml_use_internal_errors(\true); - $this->assertSame([], \libxml_get_errors()); - $this->assertInstanceOf('DOMDocument', \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile(__DIR__ . '/../Fixtures/Util/invalid_schema.xml')); - $this->assertSame([], \libxml_get_errors()); - \libxml_clear_errors(); - \libxml_use_internal_errors($internalErrors); - } - /** - * @dataProvider getDataForConvertDomToArray - */ - public function testConvertDomToArray($expected, $xml, $root = \false, $checkPrefix = \true) - { - $dom = new \DOMDocument(); - $dom->loadXML($root ? $xml : '' . $xml . ''); - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::convertDomElementToArray($dom->documentElement, $checkPrefix)); - } - public function getDataForConvertDomToArray() - { - return [[null, ''], ['bar', 'bar'], [['bar' => 'foobar'], '', \true], [['foo' => null], ''], [['foo' => 'bar'], 'bar'], [['foo' => ['foo' => 'bar']], ''], [['foo' => ['foo' => 0]], '0'], [['foo' => ['foo' => 'bar']], 'bar'], [['foo' => ['foo' => 'bar', 'value' => 'text']], 'text'], [['foo' => ['attr' => 'bar', 'foo' => 'text']], 'text'], [['foo' => ['bar', 'text']], 'bartext'], [['foo' => [['foo' => 'bar'], ['foo' => 'text']]], ''], [['foo' => ['foo' => ['bar', 'text']]], 'text'], [['foo' => 'bar'], 'bar'], [['foo' => 'text'], 'text'], [['foo' => ['bar' => 'bar', 'value' => 'text']], 'text', \false, \false], [['attr' => 1, 'b' => 'hello'], 'hello2', \true]]; - } - /** - * @dataProvider getDataForPhpize - */ - public function testPhpize($expected, $value) - { - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value)); - } - public function getDataForPhpize() - { - return [['', ''], [null, 'null'], [\true, 'true'], [\false, 'false'], [null, 'Null'], [\true, 'True'], [\false, 'False'], [0, '0'], [1, '1'], [-1, '-1'], [0777, '0777'], [255, '0xFF'], [100.0, '1e2'], [-120.0, '-1.2E2'], [-10100.1, '-10100.1'], ['-10,100.1', '-10,100.1'], ['1234 5678 9101 1121 3141', '1234 5678 9101 1121 3141'], ['1,2,3,4', '1,2,3,4'], ['11,22,33,44', '11,22,33,44'], ['11,222,333,4', '11,222,333,4'], ['1,222,333,444', '1,222,333,444'], ['11,222,333,444', '11,222,333,444'], ['111,222,333,444', '111,222,333,444'], ['1111,2222,3333,4444,5555', '1111,2222,3333,4444,5555'], ['foo', 'foo'], [6, '0b0110']]; - } - public function testLoadEmptyXmlFile() - { - $file = __DIR__ . '/../Fixtures/foo.xml'; - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage(\sprintf('File "%s" does not contain valid XML, it is empty.', $file)); - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($file); - } - // test for issue https://github.com/symfony/symfony/issues/9731 - public function testLoadWrongEmptyXMLWithErrorHandler() - { - $originalDisableEntities = \libxml_disable_entity_loader(\false); - $errorReporting = \error_reporting(-1); - \set_error_handler(function ($errno, $errstr) { - throw new \Exception($errstr, $errno); - }); - $file = __DIR__ . '/../Fixtures/foo.xml'; - try { - try { - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($file); - $this->fail('An exception should have been raised'); - } catch (\InvalidArgumentException $e) { - $this->assertEquals(\sprintf('File "%s" does not contain valid XML, it is empty.', $file), $e->getMessage()); - } - } finally { - \restore_error_handler(); - \error_reporting($errorReporting); - } - $disableEntities = \libxml_disable_entity_loader(\true); - \libxml_disable_entity_loader($disableEntities); - \libxml_disable_entity_loader($originalDisableEntities); - $this->assertFalse($disableEntities); - // should not throw an exception - \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile(__DIR__ . '/../Fixtures/Util/valid.xml', __DIR__ . '/../Fixtures/Util/schema.xsd'); - } -} -interface Validator -{ - public function validate(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Util; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils; +class XmlUtilsTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testLoadFile() + { + $fixtures = __DIR__ . '/../Fixtures/Util/'; + try { + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures); + $this->fail(); + } catch (\InvalidArgumentException $e) { + $this->assertStringContainsString('is not a file', $e->getMessage()); + } + try { + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'non_existing.xml'); + $this->fail(); + } catch (\InvalidArgumentException $e) { + $this->assertStringContainsString('is not a file', $e->getMessage()); + } + try { + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('chmod is not supported on Windows'); + } + \chmod($fixtures . 'not_readable.xml', 00); + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'not_readable.xml'); + $this->fail(); + } catch (\InvalidArgumentException $e) { + \chmod($fixtures . 'not_readable.xml', 0644); + $this->assertStringContainsString('is not readable', $e->getMessage()); + } + try { + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'invalid.xml'); + $this->fail(); + } catch (\InvalidArgumentException $e) { + $this->assertStringContainsString('ERROR ', $e->getMessage()); + } + try { + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'document_type.xml'); + $this->fail(); + } catch (\InvalidArgumentException $e) { + $this->assertStringContainsString('Document types are not allowed', $e->getMessage()); + } + try { + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'invalid_schema.xml', $fixtures . 'schema.xsd'); + $this->fail(); + } catch (\InvalidArgumentException $e) { + $this->assertStringContainsString('ERROR 1845', $e->getMessage()); + } + try { + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'invalid_schema.xml', 'invalid_callback_or_file'); + $this->fail(); + } catch (\InvalidArgumentException $e) { + $this->assertStringContainsString('XSD file or callable', $e->getMessage()); + } + $mock = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Util\Validator::class)->getMock(); + $mock->expects($this->exactly(2))->method('validate')->will($this->onConsecutiveCalls(\false, \true)); + try { + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'valid.xml', [$mock, 'validate']); + $this->fail(); + } catch (\InvalidArgumentException $e) { + $this->assertRegExp('/The XML file ".+" is not valid\\./', $e->getMessage()); + } + $this->assertInstanceOf('DOMDocument', \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($fixtures . 'valid.xml', [$mock, 'validate'])); + $this->assertSame([], \libxml_get_errors()); + } + public function testParseWithInvalidValidatorCallable() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Util\\Exception\\InvalidXmlException'); + $this->expectExceptionMessage('The XML is not valid'); + $fixtures = __DIR__ . '/../Fixtures/Util/'; + $mock = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Tests\Util\Validator::class)->getMock(); + $mock->expects($this->once())->method('validate')->willReturn(\false); + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::parse(\file_get_contents($fixtures . 'valid.xml'), [$mock, 'validate']); + } + public function testLoadFileWithInternalErrorsEnabled() + { + $internalErrors = \libxml_use_internal_errors(\true); + $this->assertSame([], \libxml_get_errors()); + $this->assertInstanceOf('DOMDocument', \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile(__DIR__ . '/../Fixtures/Util/invalid_schema.xml')); + $this->assertSame([], \libxml_get_errors()); + \libxml_clear_errors(); + \libxml_use_internal_errors($internalErrors); + } + /** + * @dataProvider getDataForConvertDomToArray + */ + public function testConvertDomToArray($expected, $xml, $root = \false, $checkPrefix = \true) + { + $dom = new \DOMDocument(); + $dom->loadXML($root ? $xml : '' . $xml . ''); + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::convertDomElementToArray($dom->documentElement, $checkPrefix)); + } + public function getDataForConvertDomToArray() + { + return [[null, ''], ['bar', 'bar'], [['bar' => 'foobar'], '', \true], [['foo' => null], ''], [['foo' => 'bar'], 'bar'], [['foo' => ['foo' => 'bar']], ''], [['foo' => ['foo' => 0]], '0'], [['foo' => ['foo' => 'bar']], 'bar'], [['foo' => ['foo' => 'bar', 'value' => 'text']], 'text'], [['foo' => ['attr' => 'bar', 'foo' => 'text']], 'text'], [['foo' => ['bar', 'text']], 'bartext'], [['foo' => [['foo' => 'bar'], ['foo' => 'text']]], ''], [['foo' => ['foo' => ['bar', 'text']]], 'text'], [['foo' => 'bar'], 'bar'], [['foo' => 'text'], 'text'], [['foo' => ['bar' => 'bar', 'value' => 'text']], 'text', \false, \false], [['attr' => 1, 'b' => 'hello'], 'hello2', \true]]; + } + /** + * @dataProvider getDataForPhpize + */ + public function testPhpize($expected, $value) + { + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value)); + } + public function getDataForPhpize() + { + return [['', ''], [null, 'null'], [\true, 'true'], [\false, 'false'], [null, 'Null'], [\true, 'True'], [\false, 'False'], [0, '0'], [1, '1'], [-1, '-1'], [0777, '0777'], [255, '0xFF'], [100.0, '1e2'], [-120.0, '-1.2E2'], [-10100.1, '-10100.1'], ['-10,100.1', '-10,100.1'], ['1234 5678 9101 1121 3141', '1234 5678 9101 1121 3141'], ['1,2,3,4', '1,2,3,4'], ['11,22,33,44', '11,22,33,44'], ['11,222,333,4', '11,222,333,4'], ['1,222,333,444', '1,222,333,444'], ['11,222,333,444', '11,222,333,444'], ['111,222,333,444', '111,222,333,444'], ['1111,2222,3333,4444,5555', '1111,2222,3333,4444,5555'], ['foo', 'foo'], [6, '0b0110']]; + } + public function testLoadEmptyXmlFile() + { + $file = __DIR__ . '/../Fixtures/foo.xml'; + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage(\sprintf('File "%s" does not contain valid XML, it is empty.', $file)); + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($file); + } + // test for issue https://github.com/symfony/symfony/issues/9731 + public function testLoadWrongEmptyXMLWithErrorHandler() + { + $originalDisableEntities = \libxml_disable_entity_loader(\false); + $errorReporting = \error_reporting(-1); + \set_error_handler(function ($errno, $errstr) { + throw new \Exception($errstr, $errno); + }); + $file = __DIR__ . '/../Fixtures/foo.xml'; + try { + try { + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($file); + $this->fail('An exception should have been raised'); + } catch (\InvalidArgumentException $e) { + $this->assertEquals(\sprintf('File "%s" does not contain valid XML, it is empty.', $file), $e->getMessage()); + } + } finally { + \restore_error_handler(); + \error_reporting($errorReporting); + } + $disableEntities = \libxml_disable_entity_loader(\true); + \libxml_disable_entity_loader($disableEntities); + \libxml_disable_entity_loader($originalDisableEntities); + $this->assertFalse($disableEntities); + // should not throw an exception + \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile(__DIR__ . '/../Fixtures/Util/valid.xml', __DIR__ . '/../Fixtures/Util/schema.xsd'); + } +} +interface Validator +{ + public function validate(); +} diff --git a/vendor/symfony/config/Tests/Util/index.php b/vendor/symfony/config/Tests/Util/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/Util/index.php +++ b/vendor/symfony/config/Tests/Util/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Tests/index.php b/vendor/symfony/config/Tests/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Tests/index.php +++ b/vendor/symfony/config/Tests/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Util/Exception/InvalidXmlException.php b/vendor/symfony/config/Util/Exception/InvalidXmlException.php index e2bc9a0f4..4f8e11c81 100644 --- a/vendor/symfony/config/Util/Exception/InvalidXmlException.php +++ b/vendor/symfony/config/Util/Exception/InvalidXmlException.php @@ -1,21 +1,21 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception; - -/** - * Exception class for when XML parsing with an XSD schema file path or a callable validator produces errors unrelated - * to the actual XML parsing. - * - * @author Ole Rößner - */ -class InvalidXmlException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception; + +/** + * Exception class for when XML parsing with an XSD schema file path or a callable validator produces errors unrelated + * to the actual XML parsing. + * + * @author Ole Rößner + */ +class InvalidXmlException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException +{ +} diff --git a/vendor/symfony/config/Util/Exception/XmlParsingException.php b/vendor/symfony/config/Util/Exception/XmlParsingException.php index d8e427020..4266c0a0c 100644 --- a/vendor/symfony/config/Util/Exception/XmlParsingException.php +++ b/vendor/symfony/config/Util/Exception/XmlParsingException.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception; - -/** - * Exception class for when XML cannot be parsed properly. - * - * @author Ole Rößner - */ -class XmlParsingException extends \InvalidArgumentException -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception; + +/** + * Exception class for when XML cannot be parsed properly. + * + * @author Ole Rößner + */ +class XmlParsingException extends \InvalidArgumentException +{ +} diff --git a/vendor/symfony/config/Util/Exception/index.php b/vendor/symfony/config/Util/Exception/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Util/Exception/index.php +++ b/vendor/symfony/config/Util/Exception/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/Util/XmlUtils.php b/vendor/symfony/config/Util/XmlUtils.php index 0f18189bc..31e524ae3 100644 --- a/vendor/symfony/config/Util/XmlUtils.php +++ b/vendor/symfony/config/Util/XmlUtils.php @@ -1,238 +1,238 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\InvalidXmlException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException; -/** - * XMLUtils is a bunch of utility methods to XML operations. - * - * This class contains static methods only and is not meant to be instantiated. - * - * @author Fabien Potencier - * @author Martin Hasoň - * @author Ole Rößner - */ -class XmlUtils -{ - /** - * This class should not be instantiated. - */ - private function __construct() - { - } - /** - * Parses an XML string. - * - * @param string $content An XML string - * @param string|callable|null $schemaOrCallable An XSD schema file path, a callable, or null to disable validation - * - * @return \DOMDocument - * - * @throws XmlParsingException When parsing of XML file returns error - * @throws InvalidXmlException When parsing of XML with schema or callable produces any errors unrelated to the XML parsing itself - * @throws \RuntimeException When DOM extension is missing - */ - public static function parse($content, $schemaOrCallable = null) - { - if (!\extension_loaded('dom')) { - throw new \RuntimeException('Extension DOM is required.'); - } - $internalErrors = \libxml_use_internal_errors(\true); - $disableEntities = \libxml_disable_entity_loader(\true); - \libxml_clear_errors(); - $dom = new \DOMDocument(); - $dom->validateOnParse = \true; - if (!$dom->loadXML($content, \LIBXML_NONET | (\defined('LIBXML_COMPACT') ? \LIBXML_COMPACT : 0))) { - \libxml_disable_entity_loader($disableEntities); - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException(\implode("\n", static::getXmlErrors($internalErrors))); - } - $dom->normalizeDocument(); - \libxml_use_internal_errors($internalErrors); - \libxml_disable_entity_loader($disableEntities); - foreach ($dom->childNodes as $child) { - if (\XML_DOCUMENT_TYPE_NODE === $child->nodeType) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException('Document types are not allowed.'); - } - } - if (null !== $schemaOrCallable) { - $internalErrors = \libxml_use_internal_errors(\true); - \libxml_clear_errors(); - $e = null; - if (\is_callable($schemaOrCallable)) { - try { - $valid = \call_user_func($schemaOrCallable, $dom, $internalErrors); - } catch (\Exception $e) { - $valid = \false; - } - } elseif (!\is_array($schemaOrCallable) && \is_file((string) $schemaOrCallable)) { - $schemaSource = \file_get_contents((string) $schemaOrCallable); - $valid = @$dom->schemaValidateSource($schemaSource); - } else { - \libxml_use_internal_errors($internalErrors); - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException('The schemaOrCallable argument has to be a valid path to XSD file or callable.'); - } - if (!$valid) { - $messages = static::getXmlErrors($internalErrors); - if (empty($messages)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\InvalidXmlException('The XML is not valid.', 0, $e); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException(\implode("\n", $messages), 0, $e); - } - } - \libxml_clear_errors(); - \libxml_use_internal_errors($internalErrors); - return $dom; - } - /** - * Loads an XML file. - * - * @param string $file An XML file path - * @param string|callable|null $schemaOrCallable An XSD schema file path, a callable, or null to disable validation - * - * @return \DOMDocument - * - * @throws \InvalidArgumentException When loading of XML file returns error - * @throws XmlParsingException When XML parsing returns any errors - * @throws \RuntimeException When DOM extension is missing - */ - public static function loadFile($file, $schemaOrCallable = null) - { - if (!\is_file($file)) { - throw new \InvalidArgumentException(\sprintf('Resource "%s" is not a file.', $file)); - } - if (!\is_readable($file)) { - throw new \InvalidArgumentException(\sprintf('File "%s" is not readable.', $file)); - } - $content = @\file_get_contents($file); - if ('' === \trim($content)) { - throw new \InvalidArgumentException(\sprintf('File "%s" does not contain valid XML, it is empty.', $file)); - } - try { - return static::parse($content, $schemaOrCallable); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\InvalidXmlException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException(\sprintf('The XML file "%s" is not valid.', $file), 0, $e->getPrevious()); - } - } - /** - * Converts a \DOMElement object to a PHP array. - * - * The following rules applies during the conversion: - * - * * Each tag is converted to a key value or an array - * if there is more than one "value" - * - * * The content of a tag is set under a "value" key (bar) - * if the tag also has some nested tags - * - * * The attributes are converted to keys () - * - * * The nested-tags are converted to keys (bar) - * - * @param \DOMElement $element A \DOMElement instance - * @param bool $checkPrefix Check prefix in an element or an attribute name - * - * @return mixed - */ - public static function convertDomElementToArray(\DOMElement $element, $checkPrefix = \true) - { - $prefix = (string) $element->prefix; - $empty = \true; - $config = []; - foreach ($element->attributes as $name => $node) { - if ($checkPrefix && !\in_array((string) $node->prefix, ['', $prefix], \true)) { - continue; - } - $config[$name] = static::phpize($node->value); - $empty = \false; - } - $nodeValue = \false; - foreach ($element->childNodes as $node) { - if ($node instanceof \DOMText) { - if ('' !== \trim($node->nodeValue)) { - $nodeValue = \trim($node->nodeValue); - $empty = \false; - } - } elseif ($checkPrefix && $prefix != (string) $node->prefix) { - continue; - } elseif (!$node instanceof \DOMComment) { - $value = static::convertDomElementToArray($node, $checkPrefix); - $key = $node->localName; - if (isset($config[$key])) { - if (!\is_array($config[$key]) || !\is_int(\key($config[$key]))) { - $config[$key] = [$config[$key]]; - } - $config[$key][] = $value; - } else { - $config[$key] = $value; - } - $empty = \false; - } - } - if (\false !== $nodeValue) { - $value = static::phpize($nodeValue); - if (\count($config)) { - $config['value'] = $value; - } else { - $config = $value; - } - } - return !$empty ? $config : null; - } - /** - * Converts an xml value to a PHP type. - * - * @param mixed $value - * - * @return mixed - */ - public static function phpize($value) - { - $value = (string) $value; - $lowercaseValue = \strtolower($value); - switch (\true) { - case 'null' === $lowercaseValue: - return null; - case \ctype_digit($value): - $raw = $value; - $cast = (int) $value; - return '0' == $value[0] ? \octdec($value) : ((string) $raw === (string) $cast ? $cast : $raw); - case isset($value[1]) && '-' === $value[0] && \ctype_digit(\substr($value, 1)): - $raw = $value; - $cast = (int) $value; - return '0' == $value[1] ? \octdec($value) : ((string) $raw === (string) $cast ? $cast : $raw); - case 'true' === $lowercaseValue: - return \true; - case 'false' === $lowercaseValue: - return \false; - case isset($value[1]) && '0b' == $value[0] . $value[1] && \preg_match('/^0b[01]*$/', $value): - return \bindec($value); - case \is_numeric($value): - return '0x' === $value[0] . $value[1] ? \hexdec($value) : (float) $value; - case \preg_match('/^0x[0-9a-f]++$/i', $value): - return \hexdec($value); - case \preg_match('/^[+-]?[0-9]+(\\.[0-9]+)?$/', $value): - return (float) $value; - default: - return $value; - } - } - protected static function getXmlErrors($internalErrors) - { - $errors = []; - foreach (\libxml_get_errors() as $error) { - $errors[] = \sprintf('[%s %s] %s (in %s - line %d, column %d)', \LIBXML_ERR_WARNING == $error->level ? 'WARNING' : 'ERROR', $error->code, \trim($error->message), $error->file ?: 'n/a', $error->line, $error->column); - } - \libxml_clear_errors(); - \libxml_use_internal_errors($internalErrors); - return $errors; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\InvalidXmlException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException; +/** + * XMLUtils is a bunch of utility methods to XML operations. + * + * This class contains static methods only and is not meant to be instantiated. + * + * @author Fabien Potencier + * @author Martin Hasoň + * @author Ole Rößner + */ +class XmlUtils +{ + /** + * This class should not be instantiated. + */ + private function __construct() + { + } + /** + * Parses an XML string. + * + * @param string $content An XML string + * @param string|callable|null $schemaOrCallable An XSD schema file path, a callable, or null to disable validation + * + * @return \DOMDocument + * + * @throws XmlParsingException When parsing of XML file returns error + * @throws InvalidXmlException When parsing of XML with schema or callable produces any errors unrelated to the XML parsing itself + * @throws \RuntimeException When DOM extension is missing + */ + public static function parse($content, $schemaOrCallable = null) + { + if (!\extension_loaded('dom')) { + throw new \RuntimeException('Extension DOM is required.'); + } + $internalErrors = \libxml_use_internal_errors(\true); + $disableEntities = \libxml_disable_entity_loader(\true); + \libxml_clear_errors(); + $dom = new \DOMDocument(); + $dom->validateOnParse = \true; + if (!$dom->loadXML($content, \LIBXML_NONET | (\defined('LIBXML_COMPACT') ? \LIBXML_COMPACT : 0))) { + \libxml_disable_entity_loader($disableEntities); + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException(\implode("\n", static::getXmlErrors($internalErrors))); + } + $dom->normalizeDocument(); + \libxml_use_internal_errors($internalErrors); + \libxml_disable_entity_loader($disableEntities); + foreach ($dom->childNodes as $child) { + if (\XML_DOCUMENT_TYPE_NODE === $child->nodeType) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException('Document types are not allowed.'); + } + } + if (null !== $schemaOrCallable) { + $internalErrors = \libxml_use_internal_errors(\true); + \libxml_clear_errors(); + $e = null; + if (\is_callable($schemaOrCallable)) { + try { + $valid = \call_user_func($schemaOrCallable, $dom, $internalErrors); + } catch (\Exception $e) { + $valid = \false; + } + } elseif (!\is_array($schemaOrCallable) && \is_file((string) $schemaOrCallable)) { + $schemaSource = \file_get_contents((string) $schemaOrCallable); + $valid = @$dom->schemaValidateSource($schemaSource); + } else { + \libxml_use_internal_errors($internalErrors); + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException('The schemaOrCallable argument has to be a valid path to XSD file or callable.'); + } + if (!$valid) { + $messages = static::getXmlErrors($internalErrors); + if (empty($messages)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\InvalidXmlException('The XML is not valid.', 0, $e); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException(\implode("\n", $messages), 0, $e); + } + } + \libxml_clear_errors(); + \libxml_use_internal_errors($internalErrors); + return $dom; + } + /** + * Loads an XML file. + * + * @param string $file An XML file path + * @param string|callable|null $schemaOrCallable An XSD schema file path, a callable, or null to disable validation + * + * @return \DOMDocument + * + * @throws \InvalidArgumentException When loading of XML file returns error + * @throws XmlParsingException When XML parsing returns any errors + * @throws \RuntimeException When DOM extension is missing + */ + public static function loadFile($file, $schemaOrCallable = null) + { + if (!\is_file($file)) { + throw new \InvalidArgumentException(\sprintf('Resource "%s" is not a file.', $file)); + } + if (!\is_readable($file)) { + throw new \InvalidArgumentException(\sprintf('File "%s" is not readable.', $file)); + } + $content = @\file_get_contents($file); + if ('' === \trim($content)) { + throw new \InvalidArgumentException(\sprintf('File "%s" does not contain valid XML, it is empty.', $file)); + } + try { + return static::parse($content, $schemaOrCallable); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\InvalidXmlException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\Exception\XmlParsingException(\sprintf('The XML file "%s" is not valid.', $file), 0, $e->getPrevious()); + } + } + /** + * Converts a \DOMElement object to a PHP array. + * + * The following rules applies during the conversion: + * + * * Each tag is converted to a key value or an array + * if there is more than one "value" + * + * * The content of a tag is set under a "value" key (bar) + * if the tag also has some nested tags + * + * * The attributes are converted to keys () + * + * * The nested-tags are converted to keys (bar) + * + * @param \DOMElement $element A \DOMElement instance + * @param bool $checkPrefix Check prefix in an element or an attribute name + * + * @return mixed + */ + public static function convertDomElementToArray(\DOMElement $element, $checkPrefix = \true) + { + $prefix = (string) $element->prefix; + $empty = \true; + $config = []; + foreach ($element->attributes as $name => $node) { + if ($checkPrefix && !\in_array((string) $node->prefix, ['', $prefix], \true)) { + continue; + } + $config[$name] = static::phpize($node->value); + $empty = \false; + } + $nodeValue = \false; + foreach ($element->childNodes as $node) { + if ($node instanceof \DOMText) { + if ('' !== \trim($node->nodeValue)) { + $nodeValue = \trim($node->nodeValue); + $empty = \false; + } + } elseif ($checkPrefix && $prefix != (string) $node->prefix) { + continue; + } elseif (!$node instanceof \DOMComment) { + $value = static::convertDomElementToArray($node, $checkPrefix); + $key = $node->localName; + if (isset($config[$key])) { + if (!\is_array($config[$key]) || !\is_int(\key($config[$key]))) { + $config[$key] = [$config[$key]]; + } + $config[$key][] = $value; + } else { + $config[$key] = $value; + } + $empty = \false; + } + } + if (\false !== $nodeValue) { + $value = static::phpize($nodeValue); + if (\count($config)) { + $config['value'] = $value; + } else { + $config = $value; + } + } + return !$empty ? $config : null; + } + /** + * Converts an xml value to a PHP type. + * + * @param mixed $value + * + * @return mixed + */ + public static function phpize($value) + { + $value = (string) $value; + $lowercaseValue = \strtolower($value); + switch (\true) { + case 'null' === $lowercaseValue: + return null; + case \ctype_digit($value): + $raw = $value; + $cast = (int) $value; + return '0' == $value[0] ? \octdec($value) : ((string) $raw === (string) $cast ? $cast : $raw); + case isset($value[1]) && '-' === $value[0] && \ctype_digit(\substr($value, 1)): + $raw = $value; + $cast = (int) $value; + return '0' == $value[1] ? \octdec($value) : ((string) $raw === (string) $cast ? $cast : $raw); + case 'true' === $lowercaseValue: + return \true; + case 'false' === $lowercaseValue: + return \false; + case isset($value[1]) && '0b' == $value[0] . $value[1] && \preg_match('/^0b[01]*$/', $value): + return \bindec($value); + case \is_numeric($value): + return '0x' === $value[0] . $value[1] ? \hexdec($value) : (float) $value; + case \preg_match('/^0x[0-9a-f]++$/i', $value): + return \hexdec($value); + case \preg_match('/^[+-]?[0-9]+(\\.[0-9]+)?$/', $value): + return (float) $value; + default: + return $value; + } + } + protected static function getXmlErrors($internalErrors) + { + $errors = []; + foreach (\libxml_get_errors() as $error) { + $errors[] = \sprintf('[%s %s] %s (in %s - line %d, column %d)', \LIBXML_ERR_WARNING == $error->level ? 'WARNING' : 'ERROR', $error->code, \trim($error->message), $error->file ?: 'n/a', $error->line, $error->column); + } + \libxml_clear_errors(); + \libxml_use_internal_errors($internalErrors); + return $errors; + } +} diff --git a/vendor/symfony/config/Util/index.php b/vendor/symfony/config/Util/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/Util/index.php +++ b/vendor/symfony/config/Util/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/composer.json b/vendor/symfony/config/composer.json index ebae79560..76a4102bc 100644 --- a/vendor/symfony/config/composer.json +++ b/vendor/symfony/config/composer.json @@ -1,50 +1,50 @@ -{ - "name": "symfony\/config", - "type": "library", - "description": "Symfony Config Component", - "keywords": [], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": "^5.5.9|>=7.0.8", - "symfony\/filesystem": "~2.8|~3.0|~4.0", - "symfony\/polyfill-ctype": "~1.8" - }, - "require-dev": { - "symfony\/finder": "~3.3|~4.0", - "symfony\/yaml": "~3.0|~4.0", - "symfony\/dependency-injection": "~3.3|~4.0", - "symfony\/event-dispatcher": "~3.3|~4.0" - }, - "conflict": { - "symfony\/finder": "<3.3", - "symfony\/dependency-injection": "<3.3" - }, - "suggest": { - "symfony\/yaml": "To use the yaml reference dumper" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\": "" - }, - "exclude-from-classmap": [ - "\/Tests\/" - ] - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - } +{ + "name": "symfony\/config", + "type": "library", + "description": "Symfony Config Component", + "keywords": [], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": "^5.5.9|>=7.0.8", + "symfony\/filesystem": "~2.8|~3.0|~4.0", + "symfony\/polyfill-ctype": "~1.8" + }, + "require-dev": { + "symfony\/finder": "~3.3|~4.0", + "symfony\/yaml": "~3.0|~4.0", + "symfony\/dependency-injection": "~3.3|~4.0", + "symfony\/event-dispatcher": "~3.3|~4.0" + }, + "conflict": { + "symfony\/finder": "<3.3", + "symfony\/dependency-injection": "<3.3" + }, + "suggest": { + "symfony\/yaml": "To use the yaml reference dumper" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\": "" + }, + "exclude-from-classmap": [ + "\/Tests\/" + ] + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/config/index.php b/vendor/symfony/config/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/config/index.php +++ b/vendor/symfony/config/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/config/phpunit.xml.dist b/vendor/symfony/config/phpunit.xml.dist index 1cfdb3cdc..e3fe2a1b2 100644 --- a/vendor/symfony/config/phpunit.xml.dist +++ b/vendor/symfony/config/phpunit.xml.dist @@ -1,31 +1,31 @@ - - - - - - - - - - ./Tests/ - - - - - - ./ - - ./Resources - ./Tests - ./vendor - - - - + + + + + + + + + + ./Tests/ + + + + + + ./ + + ./Resources + ./Tests + ./vendor + + + + diff --git a/vendor/symfony/dependency-injection/.gitignore b/vendor/symfony/dependency-injection/.gitignore index c49a5d8df..e31d97a46 100644 --- a/vendor/symfony/dependency-injection/.gitignore +++ b/vendor/symfony/dependency-injection/.gitignore @@ -1,3 +1,3 @@ -vendor/ -composer.lock -phpunit.xml +vendor/ +composer.lock +phpunit.xml diff --git a/vendor/symfony/dependency-injection/Alias.php b/vendor/symfony/dependency-injection/Alias.php index c82c214fe..bc6e3c057 100644 --- a/vendor/symfony/dependency-injection/Alias.php +++ b/vendor/symfony/dependency-injection/Alias.php @@ -1,85 +1,85 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -class Alias -{ - private $id; - private $public; - private $private; - /** - * @param string $id Alias identifier - * @param bool $public If this alias is public - */ - public function __construct($id, $public = \true) - { - $this->id = (string) $id; - $this->public = $public; - $this->private = 2 > \func_num_args(); - } - /** - * Checks if this DI Alias should be public or not. - * - * @return bool - */ - public function isPublic() - { - return $this->public; - } - /** - * Sets if this Alias is public. - * - * @param bool $boolean If this Alias should be public - * - * @return $this - */ - public function setPublic($boolean) - { - $this->public = (bool) $boolean; - $this->private = \false; - return $this; - } - /** - * Sets if this Alias is private. - * - * When set, the "private" state has a higher precedence than "public". - * In version 3.4, a "private" alias always remains publicly accessible, - * but triggers a deprecation notice when accessed from the container, - * so that the alias can be made really private in 4.0. - * - * @param bool $boolean - * - * @return $this - */ - public function setPrivate($boolean) - { - $this->private = (bool) $boolean; - return $this; - } - /** - * Whether this alias is private. - * - * @return bool - */ - public function isPrivate() - { - return $this->private; - } - /** - * Returns the Id of this alias. - * - * @return string The alias id - */ - public function __toString() - { - return $this->id; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +class Alias +{ + private $id; + private $public; + private $private; + /** + * @param string $id Alias identifier + * @param bool $public If this alias is public + */ + public function __construct($id, $public = \true) + { + $this->id = (string) $id; + $this->public = $public; + $this->private = 2 > \func_num_args(); + } + /** + * Checks if this DI Alias should be public or not. + * + * @return bool + */ + public function isPublic() + { + return $this->public; + } + /** + * Sets if this Alias is public. + * + * @param bool $boolean If this Alias should be public + * + * @return $this + */ + public function setPublic($boolean) + { + $this->public = (bool) $boolean; + $this->private = \false; + return $this; + } + /** + * Sets if this Alias is private. + * + * When set, the "private" state has a higher precedence than "public". + * In version 3.4, a "private" alias always remains publicly accessible, + * but triggers a deprecation notice when accessed from the container, + * so that the alias can be made really private in 4.0. + * + * @param bool $boolean + * + * @return $this + */ + public function setPrivate($boolean) + { + $this->private = (bool) $boolean; + return $this; + } + /** + * Whether this alias is private. + * + * @return bool + */ + public function isPrivate() + { + return $this->private; + } + /** + * Returns the Id of this alias. + * + * @return string The alias id + */ + public function __toString() + { + return $this->id; + } +} diff --git a/vendor/symfony/dependency-injection/Argument/ArgumentInterface.php b/vendor/symfony/dependency-injection/Argument/ArgumentInterface.php index b0594924d..240f6c39d 100644 --- a/vendor/symfony/dependency-injection/Argument/ArgumentInterface.php +++ b/vendor/symfony/dependency-injection/Argument/ArgumentInterface.php @@ -1,25 +1,25 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; - -/** - * Represents a complex argument containing nested values. - * - * @author Titouan Galopin - */ -interface ArgumentInterface -{ - /** - * @return array - */ - public function getValues(); - public function setValues(array $values); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; + +/** + * Represents a complex argument containing nested values. + * + * @author Titouan Galopin + */ +interface ArgumentInterface +{ + /** + * @return array + */ + public function getValues(); + public function setValues(array $values); +} diff --git a/vendor/symfony/dependency-injection/Argument/BoundArgument.php b/vendor/symfony/dependency-injection/Argument/BoundArgument.php index 41fea5b5e..a1eace069 100644 --- a/vendor/symfony/dependency-injection/Argument/BoundArgument.php +++ b/vendor/symfony/dependency-injection/Argument/BoundArgument.php @@ -1,41 +1,41 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; - -/** - * @author Guilhem Niot - */ -final class BoundArgument implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface -{ - private static $sequence = 0; - private $value; - private $identifier; - private $used; - public function __construct($value) - { - $this->value = $value; - $this->identifier = ++self::$sequence; - } - /** - * {@inheritdoc} - */ - public function getValues() - { - return [$this->value, $this->identifier, $this->used]; - } - /** - * {@inheritdoc} - */ - public function setValues(array $values) - { - list($this->value, $this->identifier, $this->used) = $values; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; + +/** + * @author Guilhem Niot + */ +final class BoundArgument implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface +{ + private static $sequence = 0; + private $value; + private $identifier; + private $used; + public function __construct($value) + { + $this->value = $value; + $this->identifier = ++self::$sequence; + } + /** + * {@inheritdoc} + */ + public function getValues() + { + return [$this->value, $this->identifier, $this->used]; + } + /** + * {@inheritdoc} + */ + public function setValues(array $values) + { + list($this->value, $this->identifier, $this->used) = $values; + } +} diff --git a/vendor/symfony/dependency-injection/Argument/IteratorArgument.php b/vendor/symfony/dependency-injection/Argument/IteratorArgument.php index 8a95f3866..55080edac 100644 --- a/vendor/symfony/dependency-injection/Argument/IteratorArgument.php +++ b/vendor/symfony/dependency-injection/Argument/IteratorArgument.php @@ -1,49 +1,49 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Represents a collection of values to lazily iterate over. - * - * @author Titouan Galopin - */ -class IteratorArgument implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface -{ - private $values; - /** - * @param Reference[] $values - */ - public function __construct(array $values) - { - $this->setValues($values); - } - /** - * @return array The values to lazily iterate over - */ - public function getValues() - { - return $this->values; - } - /** - * @param Reference[] $values The service references to lazily iterate over - */ - public function setValues(array $values) - { - foreach ($values as $k => $v) { - if (null !== $v && !$v instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('An IteratorArgument must hold only Reference instances, "%s" given.', \is_object($v) ? \get_class($v) : \gettype($v))); - } - } - $this->values = $values; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Represents a collection of values to lazily iterate over. + * + * @author Titouan Galopin + */ +class IteratorArgument implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface +{ + private $values; + /** + * @param Reference[] $values + */ + public function __construct(array $values) + { + $this->setValues($values); + } + /** + * @return array The values to lazily iterate over + */ + public function getValues() + { + return $this->values; + } + /** + * @param Reference[] $values The service references to lazily iterate over + */ + public function setValues(array $values) + { + foreach ($values as $k => $v) { + if (null !== $v && !$v instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('An IteratorArgument must hold only Reference instances, "%s" given.', \is_object($v) ? \get_class($v) : \gettype($v))); + } + } + $this->values = $values; + } +} diff --git a/vendor/symfony/dependency-injection/Argument/RewindableGenerator.php b/vendor/symfony/dependency-injection/Argument/RewindableGenerator.php index 1b92f074e..65c51f757 100644 --- a/vendor/symfony/dependency-injection/Argument/RewindableGenerator.php +++ b/vendor/symfony/dependency-injection/Argument/RewindableGenerator.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; - -/** - * @internal - */ -class RewindableGenerator implements \IteratorAggregate, \Countable -{ - private $generator; - private $count; - /** - * @param int|callable $count - */ - public function __construct(callable $generator, $count) - { - $this->generator = $generator; - $this->count = $count; - } - public function getIterator() - { - $g = $this->generator; - return $g(); - } - public function count() - { - if (\is_callable($count = $this->count)) { - $this->count = $count(); - } - return $this->count; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; + +/** + * @internal + */ +class RewindableGenerator implements \IteratorAggregate, \Countable +{ + private $generator; + private $count; + /** + * @param int|callable $count + */ + public function __construct(callable $generator, $count) + { + $this->generator = $generator; + $this->count = $count; + } + public function getIterator() + { + $g = $this->generator; + return $g(); + } + public function count() + { + if (\is_callable($count = $this->count)) { + $this->count = $count(); + } + return $this->count; + } +} diff --git a/vendor/symfony/dependency-injection/Argument/ServiceClosureArgument.php b/vendor/symfony/dependency-injection/Argument/ServiceClosureArgument.php index 820ade829..cabcfbb1b 100644 --- a/vendor/symfony/dependency-injection/Argument/ServiceClosureArgument.php +++ b/vendor/symfony/dependency-injection/Argument/ServiceClosureArgument.php @@ -1,44 +1,44 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Represents a service wrapped in a memoizing closure. - * - * @author Nicolas Grekas - */ -class ServiceClosureArgument implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface -{ - private $values; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference $reference) - { - $this->values = [$reference]; - } - /** - * {@inheritdoc} - */ - public function getValues() - { - return $this->values; - } - /** - * {@inheritdoc} - */ - public function setValues(array $values) - { - if ([0] !== \array_keys($values) || !($values[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || null === $values[0])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('A ServiceClosureArgument must hold one and only one Reference.'); - } - $this->values = $values; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Represents a service wrapped in a memoizing closure. + * + * @author Nicolas Grekas + */ +class ServiceClosureArgument implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface +{ + private $values; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference $reference) + { + $this->values = [$reference]; + } + /** + * {@inheritdoc} + */ + public function getValues() + { + return $this->values; + } + /** + * {@inheritdoc} + */ + public function setValues(array $values) + { + if ([0] !== \array_keys($values) || !($values[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || null === $values[0])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('A ServiceClosureArgument must hold one and only one Reference.'); + } + $this->values = $values; + } +} diff --git a/vendor/symfony/dependency-injection/Argument/TaggedIteratorArgument.php b/vendor/symfony/dependency-injection/Argument/TaggedIteratorArgument.php index b2cc963b5..6c3dc839d 100644 --- a/vendor/symfony/dependency-injection/Argument/TaggedIteratorArgument.php +++ b/vendor/symfony/dependency-injection/Argument/TaggedIteratorArgument.php @@ -1,33 +1,33 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; - -/** - * Represents a collection of services found by tag name to lazily iterate over. - * - * @author Roland Franssen - */ -class TaggedIteratorArgument extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument -{ - private $tag; - /** - * @param string $tag - */ - public function __construct($tag) - { - parent::__construct([]); - $this->tag = (string) $tag; - } - public function getTag() - { - return $this->tag; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument; + +/** + * Represents a collection of services found by tag name to lazily iterate over. + * + * @author Roland Franssen + */ +class TaggedIteratorArgument extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument +{ + private $tag; + /** + * @param string $tag + */ + public function __construct($tag) + { + parent::__construct([]); + $this->tag = (string) $tag; + } + public function getTag() + { + return $this->tag; + } +} diff --git a/vendor/symfony/dependency-injection/Argument/index.php b/vendor/symfony/dependency-injection/Argument/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Argument/index.php +++ b/vendor/symfony/dependency-injection/Argument/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/CHANGELOG.md b/vendor/symfony/dependency-injection/CHANGELOG.md index a004161b9..0b0806b37 100644 --- a/vendor/symfony/dependency-injection/CHANGELOG.md +++ b/vendor/symfony/dependency-injection/CHANGELOG.md @@ -1,116 +1,116 @@ -CHANGELOG -========= - -3.4.0 ------ - - * moved the `ExtensionCompilerPass` to before-optimization passes with priority -1000 - * deprecated "public-by-default" definitions and aliases, the new default will be "private" in 4.0 - * added `EnvVarProcessorInterface` and corresponding "container.env_var_processor" tag for processing env vars - * added support for ignore-on-uninitialized references - * deprecated service auto-registration while autowiring - * deprecated the ability to check for the initialization of a private service with the `Container::initialized()` method - * deprecated support for top-level anonymous services in XML - * deprecated case insensitivity of parameter names - * deprecated the `ResolveDefinitionTemplatesPass` class in favor of `ResolveChildDefinitionsPass` - * added `TaggedIteratorArgument` with YAML (`!tagged foo`) and XML (``) support - * deprecated `AutowireExceptionPass` and `AutowirePass::getAutowiringExceptions()`, use `Definition::addError()` and the `DefinitionErrorExceptionPass` instead - - -3.3.0 ------ - - * deprecated autowiring services based on the types they implement; - rename (or alias) your services to their FQCN id to make them autowirable - * added "ServiceSubscriberInterface" - to allow for per-class explicit service-locator definitions - * added "container.service_locator" tag for defining service-locator services - * added anonymous services support in YAML configuration files using the `!service` tag. - * added "TypedReference" and "ServiceClosureArgument" for creating service-locator services - * added `ServiceLocator` - a PSR-11 container holding a set of services to be lazily loaded - * added "instanceof" section for local interface-defined configs - * added prototype services for PSR4-based discovery and registration - * added `ContainerBuilder::getReflectionClass()` for retrieving and tracking reflection class info - * deprecated `ContainerBuilder::getClassResource()`, use `ContainerBuilder::getReflectionClass()` or `ContainerBuilder::addObjectResource()` instead - * added `ContainerBuilder::fileExists()` for checking and tracking file or directory existence - * deprecated autowiring-types, use aliases instead - * added support for omitting the factory class name in a service definition if the definition class is set - * deprecated case insensitivity of service identifiers - * added "iterator" argument type for lazy iteration over a set of values and services - * added file-wide configurable defaults for service attributes "public", "tags", - "autowire" and "autoconfigure" - * made the "class" attribute optional, using the "id" as fallback - * using the `PhpDumper` with an uncompiled `ContainerBuilder` is deprecated and - will not be supported anymore in 4.0 - * deprecated the `DefinitionDecorator` class in favor of `ChildDefinition` - * allow config files to be loaded using a glob pattern - * [BC BREAK] the `NullDumper` class is now final - -3.2.0 ------ - - * allowed to prioritize compiler passes by introducing a third argument to `PassConfig::addPass()`, to `Compiler::addPass` and to `ContainerBuilder::addCompilerPass()` - * added support for PHP constants in YAML configuration files - * deprecated the ability to set or unset a private service with the `Container::set()` method - * deprecated the ability to check for the existence of a private service with the `Container::has()` method - * deprecated the ability to request a private service with the `Container::get()` method - * deprecated support for generating a dumped `Container` without populating the method map - -3.0.0 ------ - - * removed all deprecated codes from 2.x versions - -2.8.0 ------ - - * deprecated the abstract ContainerAware class in favor of ContainerAwareTrait - * deprecated IntrospectableContainerInterface, to be merged with ContainerInterface in 3.0 - * allowed specifying a directory to recursively load all configuration files it contains - * deprecated the concept of scopes - * added `Definition::setShared()` and `Definition::isShared()` - * added ResettableContainerInterface to be able to reset the container to release memory on shutdown - * added a way to define the priority of service decoration - * added support for service autowiring - -2.7.0 ------ - - * deprecated synchronized services - -2.6.0 ------ - - * added new factory syntax and deprecated the old one - -2.5.0 ------ - -* added DecoratorServicePass and a way to override a service definition (Definition::setDecoratedService()) -* deprecated SimpleXMLElement class. - -2.4.0 ------ - - * added support for expressions in service definitions - * added ContainerAwareTrait to add default container aware behavior to a class - -2.2.0 ------ - - * added Extension::isConfigEnabled() to ease working with enableable configurations - * added an Extension base class with sensible defaults to be used in conjunction - with the Config component. - * added PrependExtensionInterface (to be able to allow extensions to prepend - application configuration settings for any Bundle) - -2.1.0 ------ - - * added IntrospectableContainerInterface (to be able to check if a service - has been initialized or not) - * added ConfigurationExtensionInterface - * added Definition::clearTag() - * component exceptions that inherit base SPL classes are now used exclusively - (this includes dumped containers) - * [BC BREAK] fixed unescaping of class arguments, method - ParameterBag::unescapeValue() was made public +CHANGELOG +========= + +3.4.0 +----- + + * moved the `ExtensionCompilerPass` to before-optimization passes with priority -1000 + * deprecated "public-by-default" definitions and aliases, the new default will be "private" in 4.0 + * added `EnvVarProcessorInterface` and corresponding "container.env_var_processor" tag for processing env vars + * added support for ignore-on-uninitialized references + * deprecated service auto-registration while autowiring + * deprecated the ability to check for the initialization of a private service with the `Container::initialized()` method + * deprecated support for top-level anonymous services in XML + * deprecated case insensitivity of parameter names + * deprecated the `ResolveDefinitionTemplatesPass` class in favor of `ResolveChildDefinitionsPass` + * added `TaggedIteratorArgument` with YAML (`!tagged foo`) and XML (``) support + * deprecated `AutowireExceptionPass` and `AutowirePass::getAutowiringExceptions()`, use `Definition::addError()` and the `DefinitionErrorExceptionPass` instead + + +3.3.0 +----- + + * deprecated autowiring services based on the types they implement; + rename (or alias) your services to their FQCN id to make them autowirable + * added "ServiceSubscriberInterface" - to allow for per-class explicit service-locator definitions + * added "container.service_locator" tag for defining service-locator services + * added anonymous services support in YAML configuration files using the `!service` tag. + * added "TypedReference" and "ServiceClosureArgument" for creating service-locator services + * added `ServiceLocator` - a PSR-11 container holding a set of services to be lazily loaded + * added "instanceof" section for local interface-defined configs + * added prototype services for PSR4-based discovery and registration + * added `ContainerBuilder::getReflectionClass()` for retrieving and tracking reflection class info + * deprecated `ContainerBuilder::getClassResource()`, use `ContainerBuilder::getReflectionClass()` or `ContainerBuilder::addObjectResource()` instead + * added `ContainerBuilder::fileExists()` for checking and tracking file or directory existence + * deprecated autowiring-types, use aliases instead + * added support for omitting the factory class name in a service definition if the definition class is set + * deprecated case insensitivity of service identifiers + * added "iterator" argument type for lazy iteration over a set of values and services + * added file-wide configurable defaults for service attributes "public", "tags", + "autowire" and "autoconfigure" + * made the "class" attribute optional, using the "id" as fallback + * using the `PhpDumper` with an uncompiled `ContainerBuilder` is deprecated and + will not be supported anymore in 4.0 + * deprecated the `DefinitionDecorator` class in favor of `ChildDefinition` + * allow config files to be loaded using a glob pattern + * [BC BREAK] the `NullDumper` class is now final + +3.2.0 +----- + + * allowed to prioritize compiler passes by introducing a third argument to `PassConfig::addPass()`, to `Compiler::addPass` and to `ContainerBuilder::addCompilerPass()` + * added support for PHP constants in YAML configuration files + * deprecated the ability to set or unset a private service with the `Container::set()` method + * deprecated the ability to check for the existence of a private service with the `Container::has()` method + * deprecated the ability to request a private service with the `Container::get()` method + * deprecated support for generating a dumped `Container` without populating the method map + +3.0.0 +----- + + * removed all deprecated codes from 2.x versions + +2.8.0 +----- + + * deprecated the abstract ContainerAware class in favor of ContainerAwareTrait + * deprecated IntrospectableContainerInterface, to be merged with ContainerInterface in 3.0 + * allowed specifying a directory to recursively load all configuration files it contains + * deprecated the concept of scopes + * added `Definition::setShared()` and `Definition::isShared()` + * added ResettableContainerInterface to be able to reset the container to release memory on shutdown + * added a way to define the priority of service decoration + * added support for service autowiring + +2.7.0 +----- + + * deprecated synchronized services + +2.6.0 +----- + + * added new factory syntax and deprecated the old one + +2.5.0 +----- + +* added DecoratorServicePass and a way to override a service definition (Definition::setDecoratedService()) +* deprecated SimpleXMLElement class. + +2.4.0 +----- + + * added support for expressions in service definitions + * added ContainerAwareTrait to add default container aware behavior to a class + +2.2.0 +----- + + * added Extension::isConfigEnabled() to ease working with enableable configurations + * added an Extension base class with sensible defaults to be used in conjunction + with the Config component. + * added PrependExtensionInterface (to be able to allow extensions to prepend + application configuration settings for any Bundle) + +2.1.0 +----- + + * added IntrospectableContainerInterface (to be able to check if a service + has been initialized or not) + * added ConfigurationExtensionInterface + * added Definition::clearTag() + * component exceptions that inherit base SPL classes are now used exclusively + (this includes dumped containers) + * [BC BREAK] fixed unescaping of class arguments, method + ParameterBag::unescapeValue() was made public diff --git a/vendor/symfony/dependency-injection/ChildDefinition.php b/vendor/symfony/dependency-injection/ChildDefinition.php index 70b6dc1ed..461d921cf 100644 --- a/vendor/symfony/dependency-injection/ChildDefinition.php +++ b/vendor/symfony/dependency-injection/ChildDefinition.php @@ -1,113 +1,113 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException; -/** - * This definition extends another definition. - * - * @author Johannes M. Schmitt - */ -class ChildDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition -{ - private $parent; - /** - * @param string $parent The id of Definition instance to decorate - */ - public function __construct($parent) - { - $this->parent = $parent; - $this->setPrivate(\false); - } - /** - * Returns the Definition to inherit from. - * - * @return string - */ - public function getParent() - { - return $this->parent; - } - /** - * Sets the Definition to inherit from. - * - * @param string $parent - * - * @return $this - */ - public function setParent($parent) - { - $this->parent = $parent; - return $this; - } - /** - * Gets an argument to pass to the service constructor/factory method. - * - * If replaceArgument() has been used to replace an argument, this method - * will return the replacement value. - * - * @param int|string $index - * - * @return mixed The argument value - * - * @throws OutOfBoundsException When the argument does not exist - */ - public function getArgument($index) - { - if (\array_key_exists('index_' . $index, $this->arguments)) { - return $this->arguments['index_' . $index]; - } - return parent::getArgument($index); - } - /** - * You should always use this method when overwriting existing arguments - * of the parent definition. - * - * If you directly call setArguments() keep in mind that you must follow - * certain conventions when you want to overwrite the arguments of the - * parent definition, otherwise your arguments will only be appended. - * - * @param int|string $index - * @param mixed $value - * - * @return $this - * - * @throws InvalidArgumentException when $index isn't an integer - */ - public function replaceArgument($index, $value) - { - if (\is_int($index)) { - $this->arguments['index_' . $index] = $value; - } elseif (0 === \strpos($index, '$')) { - $this->arguments[$index] = $value; - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('The argument must be an existing index or the name of a constructor\'s parameter.'); - } - return $this; - } - /** - * @internal - */ - public function setAutoconfigured($autoconfigured) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('A ChildDefinition cannot be autoconfigured.'); - } - /** - * @internal - */ - public function setInstanceofConditionals(array $instanceof) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('A ChildDefinition cannot have instanceof conditionals set on it.'); - } -} -\class_alias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator::class); + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException; +/** + * This definition extends another definition. + * + * @author Johannes M. Schmitt + */ +class ChildDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition +{ + private $parent; + /** + * @param string $parent The id of Definition instance to decorate + */ + public function __construct($parent) + { + $this->parent = $parent; + $this->setPrivate(\false); + } + /** + * Returns the Definition to inherit from. + * + * @return string + */ + public function getParent() + { + return $this->parent; + } + /** + * Sets the Definition to inherit from. + * + * @param string $parent + * + * @return $this + */ + public function setParent($parent) + { + $this->parent = $parent; + return $this; + } + /** + * Gets an argument to pass to the service constructor/factory method. + * + * If replaceArgument() has been used to replace an argument, this method + * will return the replacement value. + * + * @param int|string $index + * + * @return mixed The argument value + * + * @throws OutOfBoundsException When the argument does not exist + */ + public function getArgument($index) + { + if (\array_key_exists('index_' . $index, $this->arguments)) { + return $this->arguments['index_' . $index]; + } + return parent::getArgument($index); + } + /** + * You should always use this method when overwriting existing arguments + * of the parent definition. + * + * If you directly call setArguments() keep in mind that you must follow + * certain conventions when you want to overwrite the arguments of the + * parent definition, otherwise your arguments will only be appended. + * + * @param int|string $index + * @param mixed $value + * + * @return $this + * + * @throws InvalidArgumentException when $index isn't an integer + */ + public function replaceArgument($index, $value) + { + if (\is_int($index)) { + $this->arguments['index_' . $index] = $value; + } elseif (0 === \strpos($index, '$')) { + $this->arguments[$index] = $value; + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('The argument must be an existing index or the name of a constructor\'s parameter.'); + } + return $this; + } + /** + * @internal + */ + public function setAutoconfigured($autoconfigured) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('A ChildDefinition cannot be autoconfigured.'); + } + /** + * @internal + */ + public function setInstanceofConditionals(array $instanceof) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('A ChildDefinition cannot have instanceof conditionals set on it.'); + } +} +\class_alias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator::class); diff --git a/vendor/symfony/dependency-injection/Compiler/AbstractRecursivePass.php b/vendor/symfony/dependency-injection/Compiler/AbstractRecursivePass.php index acd0283fd..c889978bb 100644 --- a/vendor/symfony/dependency-injection/Compiler/AbstractRecursivePass.php +++ b/vendor/symfony/dependency-injection/Compiler/AbstractRecursivePass.php @@ -1,153 +1,153 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * @author Nicolas Grekas - */ -abstract class AbstractRecursivePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - /** - * @var ContainerBuilder - */ - protected $container; - protected $currentId; - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $this->container = $container; - try { - $this->processValue($container->getDefinitions(), \true); - } finally { - $this->container = null; - } - } - /** - * Processes a value found in a definition tree. - * - * @param mixed $value - * @param bool $isRoot - * - * @return mixed The processed value - */ - protected function processValue($value, $isRoot = \false) - { - if (\is_array($value)) { - foreach ($value as $k => $v) { - if ($isRoot) { - $this->currentId = $k; - } - if ($v !== ($processedValue = $this->processValue($v, $isRoot))) { - $value[$k] = $processedValue; - } - } - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { - $value->setValues($this->processValue($value->getValues())); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - $value->setArguments($this->processValue($value->getArguments())); - $value->setProperties($this->processValue($value->getProperties())); - $value->setMethodCalls($this->processValue($value->getMethodCalls())); - $changes = $value->getChanges(); - if (isset($changes['factory'])) { - $value->setFactory($this->processValue($value->getFactory())); - } - if (isset($changes['configurator'])) { - $value->setConfigurator($this->processValue($value->getConfigurator())); - } - } - return $value; - } - /** - * @param bool $required - * - * @return \ReflectionFunctionAbstract|null - * - * @throws RuntimeException - */ - protected function getConstructor(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $required) - { - if ($definition->isSynthetic()) { - return null; - } - if (\is_string($factory = $definition->getFactory())) { - if (!\function_exists($factory)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": function "%s" does not exist.', $this->currentId, $factory)); - } - $r = new \ReflectionFunction($factory); - if (\false !== $r->getFileName() && \file_exists($r->getFileName())) { - $this->container->fileExists($r->getFileName()); - } - return $r; - } - if ($factory) { - list($class, $method) = $factory; - if ($class instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $class = $this->container->findDefinition((string) $class)->getClass(); - } elseif (null === $class) { - $class = $definition->getClass(); - } - if ('__construct' === $method) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": "__construct()" cannot be used as a factory method.', $this->currentId)); - } - return $this->getReflectionMethod(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($class), $method); - } - $class = $definition->getClass(); - try { - if (!($r = $this->container->getReflectionClass($class))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": class "%s" does not exist.', $this->currentId, $class)); - } - } catch (\ReflectionException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": %s.', $this->currentId, \lcfirst(\rtrim($e->getMessage(), '.')))); - } - if (!($r = $r->getConstructor())) { - if ($required) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": class%s has no constructor.', $this->currentId, \sprintf($class !== $this->currentId ? ' "%s"' : '', $class))); - } - } elseif (!$r->isPublic()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": %s must be public.', $this->currentId, \sprintf($class !== $this->currentId ? 'constructor of class "%s"' : 'its constructor', $class))); - } - return $r; - } - /** - * @param string $method - * - * @throws RuntimeException - * - * @return \ReflectionFunctionAbstract - */ - protected function getReflectionMethod(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $method) - { - if ('__construct' === $method) { - return $this->getConstructor($definition, \true); - } - if (!($class = $definition->getClass())) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": the class is not set.', $this->currentId)); - } - if (!($r = $this->container->getReflectionClass($class))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": class "%s" does not exist.', $this->currentId, $class)); - } - if (!$r->hasMethod($method)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": method "%s()" does not exist.', $this->currentId, $class !== $this->currentId ? $class . '::' . $method : $method)); - } - $r = $r->getMethod($method); - if (!$r->isPublic()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": method "%s()" must be public.', $this->currentId, $class !== $this->currentId ? $class . '::' . $method : $method)); - } - return $r; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * @author Nicolas Grekas + */ +abstract class AbstractRecursivePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + /** + * @var ContainerBuilder + */ + protected $container; + protected $currentId; + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $this->container = $container; + try { + $this->processValue($container->getDefinitions(), \true); + } finally { + $this->container = null; + } + } + /** + * Processes a value found in a definition tree. + * + * @param mixed $value + * @param bool $isRoot + * + * @return mixed The processed value + */ + protected function processValue($value, $isRoot = \false) + { + if (\is_array($value)) { + foreach ($value as $k => $v) { + if ($isRoot) { + $this->currentId = $k; + } + if ($v !== ($processedValue = $this->processValue($v, $isRoot))) { + $value[$k] = $processedValue; + } + } + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { + $value->setValues($this->processValue($value->getValues())); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + $value->setArguments($this->processValue($value->getArguments())); + $value->setProperties($this->processValue($value->getProperties())); + $value->setMethodCalls($this->processValue($value->getMethodCalls())); + $changes = $value->getChanges(); + if (isset($changes['factory'])) { + $value->setFactory($this->processValue($value->getFactory())); + } + if (isset($changes['configurator'])) { + $value->setConfigurator($this->processValue($value->getConfigurator())); + } + } + return $value; + } + /** + * @param bool $required + * + * @return \ReflectionFunctionAbstract|null + * + * @throws RuntimeException + */ + protected function getConstructor(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $required) + { + if ($definition->isSynthetic()) { + return null; + } + if (\is_string($factory = $definition->getFactory())) { + if (!\function_exists($factory)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": function "%s" does not exist.', $this->currentId, $factory)); + } + $r = new \ReflectionFunction($factory); + if (\false !== $r->getFileName() && \file_exists($r->getFileName())) { + $this->container->fileExists($r->getFileName()); + } + return $r; + } + if ($factory) { + list($class, $method) = $factory; + if ($class instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $class = $this->container->findDefinition((string) $class)->getClass(); + } elseif (null === $class) { + $class = $definition->getClass(); + } + if ('__construct' === $method) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": "__construct()" cannot be used as a factory method.', $this->currentId)); + } + return $this->getReflectionMethod(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($class), $method); + } + $class = $definition->getClass(); + try { + if (!($r = $this->container->getReflectionClass($class))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": class "%s" does not exist.', $this->currentId, $class)); + } + } catch (\ReflectionException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": %s.', $this->currentId, \lcfirst(\rtrim($e->getMessage(), '.')))); + } + if (!($r = $r->getConstructor())) { + if ($required) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": class%s has no constructor.', $this->currentId, \sprintf($class !== $this->currentId ? ' "%s"' : '', $class))); + } + } elseif (!$r->isPublic()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": %s must be public.', $this->currentId, \sprintf($class !== $this->currentId ? 'constructor of class "%s"' : 'its constructor', $class))); + } + return $r; + } + /** + * @param string $method + * + * @throws RuntimeException + * + * @return \ReflectionFunctionAbstract + */ + protected function getReflectionMethod(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $method) + { + if ('__construct' === $method) { + return $this->getConstructor($definition, \true); + } + if (!($class = $definition->getClass())) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": the class is not set.', $this->currentId)); + } + if (!($r = $this->container->getReflectionClass($class))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": class "%s" does not exist.', $this->currentId, $class)); + } + if (!$r->hasMethod($method)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": method "%s()" does not exist.', $this->currentId, $class !== $this->currentId ? $class . '::' . $method : $method)); + } + $r = $r->getMethod($method); + if (!$r->isPublic()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid service "%s": method "%s()" must be public.', $this->currentId, $class !== $this->currentId ? $class . '::' . $method : $method)); + } + return $r; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/AnalyzeServiceReferencesPass.php b/vendor/symfony/dependency-injection/Compiler/AnalyzeServiceReferencesPass.php index 24bfb25e1..e917bece9 100644 --- a/vendor/symfony/dependency-injection/Compiler/AnalyzeServiceReferencesPass.php +++ b/vendor/symfony/dependency-injection/Compiler/AnalyzeServiceReferencesPass.php @@ -1,153 +1,153 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -/** - * Run this pass before passes that need to know more about the relation of - * your services. - * - * This class will populate the ServiceReferenceGraph with information. You can - * retrieve the graph in other passes from the compiler. - * - * @author Johannes M. Schmitt - */ -class AnalyzeServiceReferencesPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatablePassInterface -{ - private $graph; - private $currentDefinition; - private $onlyConstructorArguments; - private $hasProxyDumper; - private $lazy; - private $expressionLanguage; - private $byConstructor; - /** - * @param bool $onlyConstructorArguments Sets this Service Reference pass to ignore method calls - */ - public function __construct($onlyConstructorArguments = \false, $hasProxyDumper = \true) - { - $this->onlyConstructorArguments = (bool) $onlyConstructorArguments; - $this->hasProxyDumper = (bool) $hasProxyDumper; - } - /** - * {@inheritdoc} - */ - public function setRepeatedPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass $repeatedPass) - { - // no-op for BC - } - /** - * Processes a ContainerBuilder object to populate the service reference graph. - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $this->container = $container; - $this->graph = $container->getCompiler()->getServiceReferenceGraph(); - $this->graph->clear(); - $this->lazy = \false; - $this->byConstructor = \false; - foreach ($container->getAliases() as $id => $alias) { - $targetId = $this->getDefinitionId((string) $alias); - $this->graph->connect($id, $alias, $targetId, $this->getDefinition($targetId), null); - } - parent::process($container); - } - protected function processValue($value, $isRoot = \false) - { - $lazy = $this->lazy; - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { - $this->lazy = \true; - parent::processValue($value->getValues()); - $this->lazy = $lazy; - return $value; - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { - $this->getExpressionLanguage()->compile((string) $value, ['this' => 'container']); - return $value; - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $targetId = $this->getDefinitionId((string) $value); - $targetDefinition = $this->getDefinition($targetId); - $this->graph->connect($this->currentId, $this->currentDefinition, $targetId, $targetDefinition, $value, $this->lazy || $this->hasProxyDumper && $targetDefinition && $targetDefinition->isLazy(), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE === $value->getInvalidBehavior(), $this->byConstructor); - return $value; - } - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - return parent::processValue($value, $isRoot); - } - if ($isRoot) { - if ($value->isSynthetic() || $value->isAbstract()) { - return $value; - } - $this->currentDefinition = $value; - } elseif ($this->currentDefinition === $value) { - return $value; - } - $this->lazy = \false; - $byConstructor = $this->byConstructor; - $this->byConstructor = $isRoot || $byConstructor; - $this->processValue($value->getFactory()); - $this->processValue($value->getArguments()); - $this->byConstructor = $byConstructor; - if (!$this->onlyConstructorArguments) { - $this->processValue($value->getProperties()); - $this->processValue($value->getMethodCalls()); - $this->processValue($value->getConfigurator()); - } - $this->lazy = $lazy; - return $value; - } - /** - * Returns a service definition given the full name or an alias. - * - * @param string $id A full id or alias for a service definition - * - * @return Definition|null The definition related to the supplied id - */ - private function getDefinition($id) - { - return null === $id ? null : $this->container->getDefinition($id); - } - private function getDefinitionId($id) - { - while ($this->container->hasAlias($id)) { - $id = (string) $this->container->getAlias($id); - } - if (!$this->container->hasDefinition($id)) { - return null; - } - return $this->container->normalizeId($id); - } - private function getExpressionLanguage() - { - if (null === $this->expressionLanguage) { - if (!\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage::class)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to use expressions as the Symfony ExpressionLanguage component is not installed.'); - } - $providers = $this->container->getExpressionLanguageProviders(); - $this->expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage(null, $providers, function ($arg) { - if ('""' === \substr_replace($arg, '', 1, -1)) { - $id = \stripcslashes(\substr($arg, 1, -1)); - $id = $this->getDefinitionId($id); - $this->graph->connect($this->currentId, $this->currentDefinition, $id, $this->getDefinition($id)); - } - return \sprintf('$this->get(%s)', $arg); - }); - } - return $this->expressionLanguage; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +/** + * Run this pass before passes that need to know more about the relation of + * your services. + * + * This class will populate the ServiceReferenceGraph with information. You can + * retrieve the graph in other passes from the compiler. + * + * @author Johannes M. Schmitt + */ +class AnalyzeServiceReferencesPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatablePassInterface +{ + private $graph; + private $currentDefinition; + private $onlyConstructorArguments; + private $hasProxyDumper; + private $lazy; + private $expressionLanguage; + private $byConstructor; + /** + * @param bool $onlyConstructorArguments Sets this Service Reference pass to ignore method calls + */ + public function __construct($onlyConstructorArguments = \false, $hasProxyDumper = \true) + { + $this->onlyConstructorArguments = (bool) $onlyConstructorArguments; + $this->hasProxyDumper = (bool) $hasProxyDumper; + } + /** + * {@inheritdoc} + */ + public function setRepeatedPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass $repeatedPass) + { + // no-op for BC + } + /** + * Processes a ContainerBuilder object to populate the service reference graph. + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $this->container = $container; + $this->graph = $container->getCompiler()->getServiceReferenceGraph(); + $this->graph->clear(); + $this->lazy = \false; + $this->byConstructor = \false; + foreach ($container->getAliases() as $id => $alias) { + $targetId = $this->getDefinitionId((string) $alias); + $this->graph->connect($id, $alias, $targetId, $this->getDefinition($targetId), null); + } + parent::process($container); + } + protected function processValue($value, $isRoot = \false) + { + $lazy = $this->lazy; + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { + $this->lazy = \true; + parent::processValue($value->getValues()); + $this->lazy = $lazy; + return $value; + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { + $this->getExpressionLanguage()->compile((string) $value, ['this' => 'container']); + return $value; + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $targetId = $this->getDefinitionId((string) $value); + $targetDefinition = $this->getDefinition($targetId); + $this->graph->connect($this->currentId, $this->currentDefinition, $targetId, $targetDefinition, $value, $this->lazy || $this->hasProxyDumper && $targetDefinition && $targetDefinition->isLazy(), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE === $value->getInvalidBehavior(), $this->byConstructor); + return $value; + } + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + return parent::processValue($value, $isRoot); + } + if ($isRoot) { + if ($value->isSynthetic() || $value->isAbstract()) { + return $value; + } + $this->currentDefinition = $value; + } elseif ($this->currentDefinition === $value) { + return $value; + } + $this->lazy = \false; + $byConstructor = $this->byConstructor; + $this->byConstructor = $isRoot || $byConstructor; + $this->processValue($value->getFactory()); + $this->processValue($value->getArguments()); + $this->byConstructor = $byConstructor; + if (!$this->onlyConstructorArguments) { + $this->processValue($value->getProperties()); + $this->processValue($value->getMethodCalls()); + $this->processValue($value->getConfigurator()); + } + $this->lazy = $lazy; + return $value; + } + /** + * Returns a service definition given the full name or an alias. + * + * @param string $id A full id or alias for a service definition + * + * @return Definition|null The definition related to the supplied id + */ + private function getDefinition($id) + { + return null === $id ? null : $this->container->getDefinition($id); + } + private function getDefinitionId($id) + { + while ($this->container->hasAlias($id)) { + $id = (string) $this->container->getAlias($id); + } + if (!$this->container->hasDefinition($id)) { + return null; + } + return $this->container->normalizeId($id); + } + private function getExpressionLanguage() + { + if (null === $this->expressionLanguage) { + if (!\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage::class)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to use expressions as the Symfony ExpressionLanguage component is not installed.'); + } + $providers = $this->container->getExpressionLanguageProviders(); + $this->expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage(null, $providers, function ($arg) { + if ('""' === \substr_replace($arg, '', 1, -1)) { + $id = \stripcslashes(\substr($arg, 1, -1)); + $id = $this->getDefinitionId($id); + $this->graph->connect($this->currentId, $this->currentDefinition, $id, $this->getDefinition($id)); + } + return \sprintf('$this->get(%s)', $arg); + }); + } + return $this->expressionLanguage; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/AutoAliasServicePass.php b/vendor/symfony/dependency-injection/Compiler/AutoAliasServicePass.php index 0523b4f53..b3225e3a5 100644 --- a/vendor/symfony/dependency-injection/Compiler/AutoAliasServicePass.php +++ b/vendor/symfony/dependency-injection/Compiler/AutoAliasServicePass.php @@ -1,38 +1,38 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -/** - * Sets a service to be an alias of another one, given a format pattern. - */ -class AutoAliasServicePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - foreach ($container->findTaggedServiceIds('auto_alias') as $serviceId => $tags) { - foreach ($tags as $tag) { - if (!isset($tag['format'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Missing tag information "format" on auto_alias service "%s".', $serviceId)); - } - $aliasId = $container->getParameterBag()->resolveValue($tag['format']); - if ($container->hasDefinition($aliasId) || $container->hasAlias($aliasId)) { - $container->setAlias($serviceId, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($aliasId, \true)); - } - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +/** + * Sets a service to be an alias of another one, given a format pattern. + */ +class AutoAliasServicePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + foreach ($container->findTaggedServiceIds('auto_alias') as $serviceId => $tags) { + foreach ($tags as $tag) { + if (!isset($tag['format'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Missing tag information "format" on auto_alias service "%s".', $serviceId)); + } + $aliasId = $container->getParameterBag()->resolveValue($tag['format']); + if ($container->hasDefinition($aliasId) || $container->hasAlias($aliasId)) { + $container->setAlias($serviceId, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($aliasId, \true)); + } + } + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/AutowireExceptionPass.php b/vendor/symfony/dependency-injection/Compiler/AutowireExceptionPass.php index 64d7aba97..4c486afc7 100644 --- a/vendor/symfony/dependency-injection/Compiler/AutowireExceptionPass.php +++ b/vendor/symfony/dependency-injection/Compiler/AutowireExceptionPass.php @@ -1,63 +1,63 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -@\trigger_error('The ' . __NAMESPACE__ . '\\AutowireExceptionPass class is deprecated since Symfony 3.4 and will be removed in 4.0. Use the DefinitionErrorExceptionPass class instead.', \E_USER_DEPRECATED); -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * Throws autowire exceptions from AutowirePass for definitions that still exist. - * - * @deprecated since version 3.4, will be removed in 4.0. - * - * @author Ryan Weaver - */ -class AutowireExceptionPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - private $autowirePass; - private $inlineServicePass; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass $autowirePass, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass $inlineServicePass) - { - $this->autowirePass = $autowirePass; - $this->inlineServicePass = $inlineServicePass; - } - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - // the pass should only be run once - if (null === $this->autowirePass || null === $this->inlineServicePass) { - return; - } - $inlinedIds = $this->inlineServicePass->getInlinedServiceIds(); - $exceptions = $this->autowirePass->getAutowiringExceptions(); - // free up references - $this->autowirePass = null; - $this->inlineServicePass = null; - foreach ($exceptions as $exception) { - if ($this->doesServiceExistInTheContainer($exception->getServiceId(), $container, $inlinedIds)) { - throw $exception; - } - } - } - private function doesServiceExistInTheContainer($serviceId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, array $inlinedIds) - { - if ($container->hasDefinition($serviceId)) { - return \true; - } - // was the service inlined? Of so, does its parent service exist? - if (isset($inlinedIds[$serviceId])) { - foreach ($inlinedIds[$serviceId] as $parentId) { - if ($this->doesServiceExistInTheContainer($parentId, $container, $inlinedIds)) { - return \true; - } - } - } - return \false; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +@\trigger_error('The ' . __NAMESPACE__ . '\\AutowireExceptionPass class is deprecated since Symfony 3.4 and will be removed in 4.0. Use the DefinitionErrorExceptionPass class instead.', \E_USER_DEPRECATED); +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * Throws autowire exceptions from AutowirePass for definitions that still exist. + * + * @deprecated since version 3.4, will be removed in 4.0. + * + * @author Ryan Weaver + */ +class AutowireExceptionPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + private $autowirePass; + private $inlineServicePass; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass $autowirePass, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass $inlineServicePass) + { + $this->autowirePass = $autowirePass; + $this->inlineServicePass = $inlineServicePass; + } + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + // the pass should only be run once + if (null === $this->autowirePass || null === $this->inlineServicePass) { + return; + } + $inlinedIds = $this->inlineServicePass->getInlinedServiceIds(); + $exceptions = $this->autowirePass->getAutowiringExceptions(); + // free up references + $this->autowirePass = null; + $this->inlineServicePass = null; + foreach ($exceptions as $exception) { + if ($this->doesServiceExistInTheContainer($exception->getServiceId(), $container, $inlinedIds)) { + throw $exception; + } + } + } + private function doesServiceExistInTheContainer($serviceId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, array $inlinedIds) + { + if ($container->hasDefinition($serviceId)) { + return \true; + } + // was the service inlined? Of so, does its parent service exist? + if (isset($inlinedIds[$serviceId])) { + foreach ($inlinedIds[$serviceId] as $parentId) { + if ($this->doesServiceExistInTheContainer($parentId, $container, $inlinedIds)) { + return \true; + } + } + } + return \false; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/AutowirePass.php b/vendor/symfony/dependency-injection/Compiler/AutowirePass.php index e900a8eea..7613ec620 100644 --- a/vendor/symfony/dependency-injection/Compiler/AutowirePass.php +++ b/vendor/symfony/dependency-injection/Compiler/AutowirePass.php @@ -1,473 +1,473 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; -/** - * Inspects existing service definitions and wires the autowired ones using the type hints of their classes. - * - * @author Kévin Dunglas - * @author Nicolas Grekas - */ -class AutowirePass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - private $definedTypes = []; - private $types; - private $ambiguousServiceTypes; - private $autowired = []; - private $lastFailure; - private $throwOnAutowiringException; - private $autowiringExceptions = []; - private $strictMode; - /** - * @param bool $throwOnAutowireException Errors can be retrieved via Definition::getErrors() - */ - public function __construct($throwOnAutowireException = \true) - { - $this->throwOnAutowiringException = $throwOnAutowireException; - } - /** - * @deprecated since version 3.4, to be removed in 4.0. - * - * @return AutowiringFailedException[] - */ - public function getAutowiringExceptions() - { - @\trigger_error('Calling AutowirePass::getAutowiringExceptions() is deprecated since Symfony 3.4 and will be removed in 4.0. Use Definition::getErrors() instead.', \E_USER_DEPRECATED); - return $this->autowiringExceptions; - } - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - // clear out any possibly stored exceptions from before - $this->autowiringExceptions = []; - $this->strictMode = $container->hasParameter('container.autowiring.strict_mode') && $container->getParameter('container.autowiring.strict_mode'); - try { - parent::process($container); - } finally { - $this->definedTypes = []; - $this->types = null; - $this->ambiguousServiceTypes = null; - $this->autowired = []; - } - } - /** - * Creates a resource to help know if this service has changed. - * - * @return AutowireServiceResource - * - * @deprecated since version 3.3, to be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead. - */ - public static function createResourceForClass(\ReflectionClass $reflectionClass) - { - @\trigger_error('The ' . __METHOD__ . '() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead.', \E_USER_DEPRECATED); - $metadata = []; - foreach ($reflectionClass->getMethods(\ReflectionMethod::IS_PUBLIC) as $reflectionMethod) { - if (!$reflectionMethod->isStatic()) { - $metadata[$reflectionMethod->name] = self::getResourceMetadataForMethod($reflectionMethod); - } - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource($reflectionClass->name, $reflectionClass->getFileName(), $metadata); - } - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - try { - return $this->doProcessValue($value, $isRoot); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException $e) { - if ($this->throwOnAutowiringException) { - throw $e; - } - $this->autowiringExceptions[] = $e; - $this->container->getDefinition($this->currentId)->addError($e->getMessage()); - return parent::processValue($value, $isRoot); - } - } - private function doProcessValue($value, $isRoot = \false) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference) { - if ($ref = $this->getAutowiredReference($value, $value->getRequiringClass() ? \sprintf('for "%s" in "%s"', $value->getType(), $value->getRequiringClass()) : '')) { - return $ref; - } - $this->container->log($this, $this->createTypeNotFoundMessage($value, 'it')); - } - $value = parent::processValue($value, $isRoot); - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || !$value->isAutowired() || $value->isAbstract() || !$value->getClass()) { - return $value; - } - if (!($reflectionClass = $this->container->getReflectionClass($value->getClass(), \false))) { - $this->container->log($this, \sprintf('Skipping service "%s": Class or interface "%s" cannot be loaded.', $this->currentId, $value->getClass())); - return $value; - } - $methodCalls = $value->getMethodCalls(); - try { - $constructor = $this->getConstructor($value, \false); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException($this->currentId, $e->getMessage(), 0, $e); - } - if ($constructor) { - \array_unshift($methodCalls, [$constructor, $value->getArguments()]); - } - $methodCalls = $this->autowireCalls($reflectionClass, $methodCalls); - if ($constructor) { - list(, $arguments) = \array_shift($methodCalls); - if ($arguments !== $value->getArguments()) { - $value->setArguments($arguments); - } - } - if ($methodCalls !== $value->getMethodCalls()) { - $value->setMethodCalls($methodCalls); - } - return $value; - } - /** - * @return array - */ - private function autowireCalls(\ReflectionClass $reflectionClass, array $methodCalls) - { - foreach ($methodCalls as $i => $call) { - list($method, $arguments) = $call; - if ($method instanceof \ReflectionFunctionAbstract) { - $reflectionMethod = $method; - } else { - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($reflectionClass->name); - try { - $reflectionMethod = $this->getReflectionMethod($definition, $method); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { - if ($definition->getFactory()) { - continue; - } - throw $e; - } - } - $arguments = $this->autowireMethod($reflectionMethod, $arguments); - if ($arguments !== $call[1]) { - $methodCalls[$i][1] = $arguments; - } - } - return $methodCalls; - } - /** - * Autowires the constructor or a method. - * - * @return array The autowired arguments - * - * @throws AutowiringFailedException - */ - private function autowireMethod(\ReflectionFunctionAbstract $reflectionMethod, array $arguments) - { - $class = $reflectionMethod instanceof \ReflectionMethod ? $reflectionMethod->class : $this->currentId; - $method = $reflectionMethod->name; - $parameters = $reflectionMethod->getParameters(); - if (\method_exists('ReflectionMethod', 'isVariadic') && $reflectionMethod->isVariadic()) { - \array_pop($parameters); - } - foreach ($parameters as $index => $parameter) { - if (\array_key_exists($index, $arguments) && '' !== $arguments[$index]) { - continue; - } - $type = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper::getTypeHint($reflectionMethod, $parameter, \true); - if (!$type) { - if (isset($arguments[$index])) { - continue; - } - // no default value? Then fail - if (!$parameter->isDefaultValueAvailable()) { - // For core classes, isDefaultValueAvailable() can - // be false when isOptional() returns true. If the - // argument *is* optional, allow it to be missing - if ($parameter->isOptional()) { - continue; - } - $type = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper::getTypeHint($reflectionMethod, $parameter, \false); - $type = $type ? \sprintf('is type-hinted "%s"', $type) : 'has no type-hint'; - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException($this->currentId, \sprintf('Cannot autowire service "%s": argument "$%s" of method "%s()" %s, you should configure its value explicitly.', $this->currentId, $parameter->name, $class !== $this->currentId ? $class . '::' . $method : $method, $type)); - } - // specifically pass the default value - $arguments[$index] = $parameter->getDefaultValue(); - continue; - } - if (!($value = $this->getAutowiredReference($ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($type, $type, !$parameter->isOptional() ? $class : ''), 'for ' . \sprintf('argument "$%s" of method "%s()"', $parameter->name, $class . '::' . $method)))) { - $failureMessage = $this->createTypeNotFoundMessage($ref, \sprintf('argument "$%s" of method "%s()"', $parameter->name, $class !== $this->currentId ? $class . '::' . $method : $method)); - if ($parameter->isDefaultValueAvailable()) { - $value = $parameter->getDefaultValue(); - } elseif (!$parameter->allowsNull()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException($this->currentId, $failureMessage); - } - $this->container->log($this, $failureMessage); - } - $arguments[$index] = $value; - } - if ($parameters && !isset($arguments[++$index])) { - while (0 <= --$index) { - $parameter = $parameters[$index]; - if (!$parameter->isDefaultValueAvailable() || $parameter->getDefaultValue() !== $arguments[$index]) { - break; - } - unset($arguments[$index]); - } - } - // it's possible index 1 was set, then index 0, then 2, etc - // make sure that we re-order so they're injected as expected - \ksort($arguments); - return $arguments; - } - /** - * @return TypedReference|null A reference to the service matching the given type, if any - */ - private function getAutowiredReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference $reference, $deprecationMessage) - { - $this->lastFailure = null; - $type = $reference->getType(); - if ($type !== $this->container->normalizeId($reference) || $this->container->has($type) && !$this->container->findDefinition($type)->isAbstract()) { - return $reference; - } - if (null === $this->types) { - $this->populateAvailableTypes($this->strictMode); - } - if (isset($this->definedTypes[$type])) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($this->types[$type], $type); - } - if (!$this->strictMode && isset($this->types[$type])) { - $message = 'Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won\'t be supported in version 4.0.'; - if ($aliasSuggestion = $this->getAliasesSuggestionForType($type = $reference->getType(), $deprecationMessage)) { - $message .= ' ' . $aliasSuggestion; - } else { - $message .= \sprintf(' You should %s the "%s" service to "%s" instead.', isset($this->types[$this->types[$type]]) ? 'alias' : 'rename (or alias)', $this->types[$type], $type); - } - @\trigger_error($message, \E_USER_DEPRECATED); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($this->types[$type], $type); - } - if (!$reference->canBeAutoregistered() || isset($this->types[$type]) || isset($this->ambiguousServiceTypes[$type])) { - return null; - } - if (isset($this->autowired[$type])) { - return $this->autowired[$type] ? new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($this->autowired[$type], $type) : null; - } - if (!$this->strictMode) { - return $this->createAutowiredDefinition($type); - } - return null; - } - /** - * Populates the list of available types. - */ - private function populateAvailableTypes($onlyAutowiringTypes = \false) - { - $this->types = []; - if (!$onlyAutowiringTypes) { - $this->ambiguousServiceTypes = []; - } - foreach ($this->container->getDefinitions() as $id => $definition) { - $this->populateAvailableType($id, $definition, $onlyAutowiringTypes); - } - } - /** - * Populates the list of available types for a given definition. - * - * @param string $id - */ - private function populateAvailableType($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $onlyAutowiringTypes) - { - // Never use abstract services - if ($definition->isAbstract()) { - return; - } - foreach ($definition->getAutowiringTypes(\false) as $type) { - $this->definedTypes[$type] = \true; - $this->types[$type] = $id; - unset($this->ambiguousServiceTypes[$type]); - } - if ($onlyAutowiringTypes) { - return; - } - if (\preg_match('/^\\d+_[^~]++~[._a-zA-Z\\d]{7}$/', $id) || $definition->isDeprecated() || !($reflectionClass = $this->container->getReflectionClass($definition->getClass(), \false))) { - return; - } - foreach ($reflectionClass->getInterfaces() as $reflectionInterface) { - $this->set($reflectionInterface->name, $id); - } - do { - $this->set($reflectionClass->name, $id); - } while ($reflectionClass = $reflectionClass->getParentClass()); - } - /** - * Associates a type and a service id if applicable. - * - * @param string $type - * @param string $id - */ - private function set($type, $id) - { - if (isset($this->definedTypes[$type])) { - return; - } - // is this already a type/class that is known to match multiple services? - if (isset($this->ambiguousServiceTypes[$type])) { - $this->ambiguousServiceTypes[$type][] = $id; - return; - } - // check to make sure the type doesn't match multiple services - if (!isset($this->types[$type]) || $this->types[$type] === $id) { - $this->types[$type] = $id; - return; - } - // keep an array of all services matching this type - if (!isset($this->ambiguousServiceTypes[$type])) { - $this->ambiguousServiceTypes[$type] = [$this->types[$type]]; - unset($this->types[$type]); - } - $this->ambiguousServiceTypes[$type][] = $id; - } - /** - * Registers a definition for the type if possible or throws an exception. - * - * @param string $type - * - * @return TypedReference|null A reference to the registered definition - */ - private function createAutowiredDefinition($type) - { - if (!($typeHint = $this->container->getReflectionClass($type, \false)) || !$typeHint->isInstantiable()) { - return null; - } - $currentId = $this->currentId; - $this->currentId = $type; - $this->autowired[$type] = $argumentId = \sprintf('autowired.%s', $type); - $argumentDefinition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($type); - $argumentDefinition->setPublic(\false); - $argumentDefinition->setAutowired(\true); - try { - $originalThrowSetting = $this->throwOnAutowiringException; - $this->throwOnAutowiringException = \true; - $this->processValue($argumentDefinition, \true); - $this->container->setDefinition($argumentId, $argumentDefinition); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException $e) { - $this->autowired[$type] = \false; - $this->lastFailure = $e->getMessage(); - $this->container->log($this, $this->lastFailure); - return null; - } finally { - $this->throwOnAutowiringException = $originalThrowSetting; - $this->currentId = $currentId; - } - @\trigger_error(\sprintf('Relying on service auto-registration for type "%s" is deprecated since Symfony 3.4 and won\'t be supported in 4.0. Create a service named "%s" instead.', $type, $type), \E_USER_DEPRECATED); - $this->container->log($this, \sprintf('Type "%s" has been auto-registered for service "%s".', $type, $this->currentId)); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($argumentId, $type); - } - private function createTypeNotFoundMessage(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference $reference, $label) - { - $trackResources = $this->container->isTrackingResources(); - $this->container->setResourceTracking(\false); - try { - if ($r = $this->container->getReflectionClass($type = $reference->getType(), \false)) { - $alternatives = $this->createTypeAlternatives($reference); - } - } finally { - $this->container->setResourceTracking($trackResources); - } - if (!$r) { - // either $type does not exist or a parent class does not exist - try { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource($type, \false); - // isFresh() will explode ONLY if a parent class/trait does not exist - $resource->isFresh(0); - $parentMsg = \false; - } catch (\ReflectionException $e) { - $parentMsg = $e->getMessage(); - } - $message = \sprintf('has type "%s" but this class %s.', $type, $parentMsg ? \sprintf('is missing a parent class (%s)', $parentMsg) : 'was not found'); - } else { - $message = $this->container->has($type) ? 'this service is abstract' : 'no such service exists'; - $message = \sprintf('references %s "%s" but %s.%s', $r->isInterface() ? 'interface' : 'class', $type, $message, $alternatives); - if ($r->isInterface() && !$alternatives) { - $message .= ' Did you create a class that implements this interface?'; - } - } - $message = \sprintf('Cannot autowire service "%s": %s %s', $this->currentId, $label, $message); - if (null !== $this->lastFailure) { - $message = $this->lastFailure . "\n" . $message; - $this->lastFailure = null; - } - return $message; - } - private function createTypeAlternatives(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference $reference) - { - // try suggesting available aliases first - if ($message = $this->getAliasesSuggestionForType($type = $reference->getType())) { - return ' ' . $message; - } - if (null === $this->ambiguousServiceTypes) { - $this->populateAvailableTypes(); - } - if (isset($this->ambiguousServiceTypes[$type])) { - $message = \sprintf('one of these existing services: "%s"', \implode('", "', $this->ambiguousServiceTypes[$type])); - } elseif (isset($this->types[$type])) { - $message = \sprintf('the existing "%s" service', $this->types[$type]); - } elseif ($reference->getRequiringClass() && !$reference->canBeAutoregistered() && !$this->strictMode) { - return ' It cannot be auto-registered because it is from a different root namespace.'; - } else { - return ''; - } - return \sprintf(' You should maybe alias this %s to %s.', \class_exists($type, \false) ? 'class' : 'interface', $message); - } - /** - * @deprecated since version 3.3, to be removed in 4.0. - */ - private static function getResourceMetadataForMethod(\ReflectionMethod $method) - { - $methodArgumentsMetadata = []; - foreach ($method->getParameters() as $parameter) { - try { - $class = $parameter->getClass(); - } catch (\ReflectionException $e) { - // type-hint is against a non-existent class - $class = \false; - } - $isVariadic = \method_exists($parameter, 'isVariadic') && $parameter->isVariadic(); - $methodArgumentsMetadata[] = ['class' => $class, 'isOptional' => $parameter->isOptional(), 'defaultValue' => $parameter->isOptional() && !$isVariadic ? $parameter->getDefaultValue() : null]; - } - return $methodArgumentsMetadata; - } - private function getAliasesSuggestionForType($type, $extraContext = null) - { - $aliases = []; - foreach (\class_parents($type) + \class_implements($type) as $parent) { - if ($this->container->has($parent) && !$this->container->findDefinition($parent)->isAbstract()) { - $aliases[] = $parent; - } - } - $extraContext = $extraContext ? ' ' . $extraContext : ''; - if (1 < ($len = \count($aliases))) { - $message = \sprintf('Try changing the type-hint%s to one of its parents: ', $extraContext); - for ($i = 0, --$len; $i < $len; ++$i) { - $message .= \sprintf('%s "%s", ', \class_exists($aliases[$i], \false) ? 'class' : 'interface', $aliases[$i]); - } - $message .= \sprintf('or %s "%s".', \class_exists($aliases[$i], \false) ? 'class' : 'interface', $aliases[$i]); - return $message; - } - if ($aliases) { - return \sprintf('Try changing the type-hint%s to "%s" instead.', $extraContext, $aliases[0]); - } - return null; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; +/** + * Inspects existing service definitions and wires the autowired ones using the type hints of their classes. + * + * @author Kévin Dunglas + * @author Nicolas Grekas + */ +class AutowirePass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + private $definedTypes = []; + private $types; + private $ambiguousServiceTypes; + private $autowired = []; + private $lastFailure; + private $throwOnAutowiringException; + private $autowiringExceptions = []; + private $strictMode; + /** + * @param bool $throwOnAutowireException Errors can be retrieved via Definition::getErrors() + */ + public function __construct($throwOnAutowireException = \true) + { + $this->throwOnAutowiringException = $throwOnAutowireException; + } + /** + * @deprecated since version 3.4, to be removed in 4.0. + * + * @return AutowiringFailedException[] + */ + public function getAutowiringExceptions() + { + @\trigger_error('Calling AutowirePass::getAutowiringExceptions() is deprecated since Symfony 3.4 and will be removed in 4.0. Use Definition::getErrors() instead.', \E_USER_DEPRECATED); + return $this->autowiringExceptions; + } + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + // clear out any possibly stored exceptions from before + $this->autowiringExceptions = []; + $this->strictMode = $container->hasParameter('container.autowiring.strict_mode') && $container->getParameter('container.autowiring.strict_mode'); + try { + parent::process($container); + } finally { + $this->definedTypes = []; + $this->types = null; + $this->ambiguousServiceTypes = null; + $this->autowired = []; + } + } + /** + * Creates a resource to help know if this service has changed. + * + * @return AutowireServiceResource + * + * @deprecated since version 3.3, to be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead. + */ + public static function createResourceForClass(\ReflectionClass $reflectionClass) + { + @\trigger_error('The ' . __METHOD__ . '() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead.', \E_USER_DEPRECATED); + $metadata = []; + foreach ($reflectionClass->getMethods(\ReflectionMethod::IS_PUBLIC) as $reflectionMethod) { + if (!$reflectionMethod->isStatic()) { + $metadata[$reflectionMethod->name] = self::getResourceMetadataForMethod($reflectionMethod); + } + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource($reflectionClass->name, $reflectionClass->getFileName(), $metadata); + } + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + try { + return $this->doProcessValue($value, $isRoot); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException $e) { + if ($this->throwOnAutowiringException) { + throw $e; + } + $this->autowiringExceptions[] = $e; + $this->container->getDefinition($this->currentId)->addError($e->getMessage()); + return parent::processValue($value, $isRoot); + } + } + private function doProcessValue($value, $isRoot = \false) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference) { + if ($ref = $this->getAutowiredReference($value, $value->getRequiringClass() ? \sprintf('for "%s" in "%s"', $value->getType(), $value->getRequiringClass()) : '')) { + return $ref; + } + $this->container->log($this, $this->createTypeNotFoundMessage($value, 'it')); + } + $value = parent::processValue($value, $isRoot); + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || !$value->isAutowired() || $value->isAbstract() || !$value->getClass()) { + return $value; + } + if (!($reflectionClass = $this->container->getReflectionClass($value->getClass(), \false))) { + $this->container->log($this, \sprintf('Skipping service "%s": Class or interface "%s" cannot be loaded.', $this->currentId, $value->getClass())); + return $value; + } + $methodCalls = $value->getMethodCalls(); + try { + $constructor = $this->getConstructor($value, \false); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException($this->currentId, $e->getMessage(), 0, $e); + } + if ($constructor) { + \array_unshift($methodCalls, [$constructor, $value->getArguments()]); + } + $methodCalls = $this->autowireCalls($reflectionClass, $methodCalls); + if ($constructor) { + list(, $arguments) = \array_shift($methodCalls); + if ($arguments !== $value->getArguments()) { + $value->setArguments($arguments); + } + } + if ($methodCalls !== $value->getMethodCalls()) { + $value->setMethodCalls($methodCalls); + } + return $value; + } + /** + * @return array + */ + private function autowireCalls(\ReflectionClass $reflectionClass, array $methodCalls) + { + foreach ($methodCalls as $i => $call) { + list($method, $arguments) = $call; + if ($method instanceof \ReflectionFunctionAbstract) { + $reflectionMethod = $method; + } else { + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($reflectionClass->name); + try { + $reflectionMethod = $this->getReflectionMethod($definition, $method); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { + if ($definition->getFactory()) { + continue; + } + throw $e; + } + } + $arguments = $this->autowireMethod($reflectionMethod, $arguments); + if ($arguments !== $call[1]) { + $methodCalls[$i][1] = $arguments; + } + } + return $methodCalls; + } + /** + * Autowires the constructor or a method. + * + * @return array The autowired arguments + * + * @throws AutowiringFailedException + */ + private function autowireMethod(\ReflectionFunctionAbstract $reflectionMethod, array $arguments) + { + $class = $reflectionMethod instanceof \ReflectionMethod ? $reflectionMethod->class : $this->currentId; + $method = $reflectionMethod->name; + $parameters = $reflectionMethod->getParameters(); + if (\method_exists('ReflectionMethod', 'isVariadic') && $reflectionMethod->isVariadic()) { + \array_pop($parameters); + } + foreach ($parameters as $index => $parameter) { + if (\array_key_exists($index, $arguments) && '' !== $arguments[$index]) { + continue; + } + $type = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper::getTypeHint($reflectionMethod, $parameter, \true); + if (!$type) { + if (isset($arguments[$index])) { + continue; + } + // no default value? Then fail + if (!$parameter->isDefaultValueAvailable()) { + // For core classes, isDefaultValueAvailable() can + // be false when isOptional() returns true. If the + // argument *is* optional, allow it to be missing + if ($parameter->isOptional()) { + continue; + } + $type = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper::getTypeHint($reflectionMethod, $parameter, \false); + $type = $type ? \sprintf('is type-hinted "%s"', $type) : 'has no type-hint'; + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException($this->currentId, \sprintf('Cannot autowire service "%s": argument "$%s" of method "%s()" %s, you should configure its value explicitly.', $this->currentId, $parameter->name, $class !== $this->currentId ? $class . '::' . $method : $method, $type)); + } + // specifically pass the default value + $arguments[$index] = $parameter->getDefaultValue(); + continue; + } + if (!($value = $this->getAutowiredReference($ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($type, $type, !$parameter->isOptional() ? $class : ''), 'for ' . \sprintf('argument "$%s" of method "%s()"', $parameter->name, $class . '::' . $method)))) { + $failureMessage = $this->createTypeNotFoundMessage($ref, \sprintf('argument "$%s" of method "%s()"', $parameter->name, $class !== $this->currentId ? $class . '::' . $method : $method)); + if ($parameter->isDefaultValueAvailable()) { + $value = $parameter->getDefaultValue(); + } elseif (!$parameter->allowsNull()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException($this->currentId, $failureMessage); + } + $this->container->log($this, $failureMessage); + } + $arguments[$index] = $value; + } + if ($parameters && !isset($arguments[++$index])) { + while (0 <= --$index) { + $parameter = $parameters[$index]; + if (!$parameter->isDefaultValueAvailable() || $parameter->getDefaultValue() !== $arguments[$index]) { + break; + } + unset($arguments[$index]); + } + } + // it's possible index 1 was set, then index 0, then 2, etc + // make sure that we re-order so they're injected as expected + \ksort($arguments); + return $arguments; + } + /** + * @return TypedReference|null A reference to the service matching the given type, if any + */ + private function getAutowiredReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference $reference, $deprecationMessage) + { + $this->lastFailure = null; + $type = $reference->getType(); + if ($type !== $this->container->normalizeId($reference) || $this->container->has($type) && !$this->container->findDefinition($type)->isAbstract()) { + return $reference; + } + if (null === $this->types) { + $this->populateAvailableTypes($this->strictMode); + } + if (isset($this->definedTypes[$type])) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($this->types[$type], $type); + } + if (!$this->strictMode && isset($this->types[$type])) { + $message = 'Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won\'t be supported in version 4.0.'; + if ($aliasSuggestion = $this->getAliasesSuggestionForType($type = $reference->getType(), $deprecationMessage)) { + $message .= ' ' . $aliasSuggestion; + } else { + $message .= \sprintf(' You should %s the "%s" service to "%s" instead.', isset($this->types[$this->types[$type]]) ? 'alias' : 'rename (or alias)', $this->types[$type], $type); + } + @\trigger_error($message, \E_USER_DEPRECATED); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($this->types[$type], $type); + } + if (!$reference->canBeAutoregistered() || isset($this->types[$type]) || isset($this->ambiguousServiceTypes[$type])) { + return null; + } + if (isset($this->autowired[$type])) { + return $this->autowired[$type] ? new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($this->autowired[$type], $type) : null; + } + if (!$this->strictMode) { + return $this->createAutowiredDefinition($type); + } + return null; + } + /** + * Populates the list of available types. + */ + private function populateAvailableTypes($onlyAutowiringTypes = \false) + { + $this->types = []; + if (!$onlyAutowiringTypes) { + $this->ambiguousServiceTypes = []; + } + foreach ($this->container->getDefinitions() as $id => $definition) { + $this->populateAvailableType($id, $definition, $onlyAutowiringTypes); + } + } + /** + * Populates the list of available types for a given definition. + * + * @param string $id + */ + private function populateAvailableType($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $onlyAutowiringTypes) + { + // Never use abstract services + if ($definition->isAbstract()) { + return; + } + foreach ($definition->getAutowiringTypes(\false) as $type) { + $this->definedTypes[$type] = \true; + $this->types[$type] = $id; + unset($this->ambiguousServiceTypes[$type]); + } + if ($onlyAutowiringTypes) { + return; + } + if (\preg_match('/^\\d+_[^~]++~[._a-zA-Z\\d]{7}$/', $id) || $definition->isDeprecated() || !($reflectionClass = $this->container->getReflectionClass($definition->getClass(), \false))) { + return; + } + foreach ($reflectionClass->getInterfaces() as $reflectionInterface) { + $this->set($reflectionInterface->name, $id); + } + do { + $this->set($reflectionClass->name, $id); + } while ($reflectionClass = $reflectionClass->getParentClass()); + } + /** + * Associates a type and a service id if applicable. + * + * @param string $type + * @param string $id + */ + private function set($type, $id) + { + if (isset($this->definedTypes[$type])) { + return; + } + // is this already a type/class that is known to match multiple services? + if (isset($this->ambiguousServiceTypes[$type])) { + $this->ambiguousServiceTypes[$type][] = $id; + return; + } + // check to make sure the type doesn't match multiple services + if (!isset($this->types[$type]) || $this->types[$type] === $id) { + $this->types[$type] = $id; + return; + } + // keep an array of all services matching this type + if (!isset($this->ambiguousServiceTypes[$type])) { + $this->ambiguousServiceTypes[$type] = [$this->types[$type]]; + unset($this->types[$type]); + } + $this->ambiguousServiceTypes[$type][] = $id; + } + /** + * Registers a definition for the type if possible or throws an exception. + * + * @param string $type + * + * @return TypedReference|null A reference to the registered definition + */ + private function createAutowiredDefinition($type) + { + if (!($typeHint = $this->container->getReflectionClass($type, \false)) || !$typeHint->isInstantiable()) { + return null; + } + $currentId = $this->currentId; + $this->currentId = $type; + $this->autowired[$type] = $argumentId = \sprintf('autowired.%s', $type); + $argumentDefinition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($type); + $argumentDefinition->setPublic(\false); + $argumentDefinition->setAutowired(\true); + try { + $originalThrowSetting = $this->throwOnAutowiringException; + $this->throwOnAutowiringException = \true; + $this->processValue($argumentDefinition, \true); + $this->container->setDefinition($argumentId, $argumentDefinition); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException $e) { + $this->autowired[$type] = \false; + $this->lastFailure = $e->getMessage(); + $this->container->log($this, $this->lastFailure); + return null; + } finally { + $this->throwOnAutowiringException = $originalThrowSetting; + $this->currentId = $currentId; + } + @\trigger_error(\sprintf('Relying on service auto-registration for type "%s" is deprecated since Symfony 3.4 and won\'t be supported in 4.0. Create a service named "%s" instead.', $type, $type), \E_USER_DEPRECATED); + $this->container->log($this, \sprintf('Type "%s" has been auto-registered for service "%s".', $type, $this->currentId)); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($argumentId, $type); + } + private function createTypeNotFoundMessage(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference $reference, $label) + { + $trackResources = $this->container->isTrackingResources(); + $this->container->setResourceTracking(\false); + try { + if ($r = $this->container->getReflectionClass($type = $reference->getType(), \false)) { + $alternatives = $this->createTypeAlternatives($reference); + } + } finally { + $this->container->setResourceTracking($trackResources); + } + if (!$r) { + // either $type does not exist or a parent class does not exist + try { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource($type, \false); + // isFresh() will explode ONLY if a parent class/trait does not exist + $resource->isFresh(0); + $parentMsg = \false; + } catch (\ReflectionException $e) { + $parentMsg = $e->getMessage(); + } + $message = \sprintf('has type "%s" but this class %s.', $type, $parentMsg ? \sprintf('is missing a parent class (%s)', $parentMsg) : 'was not found'); + } else { + $message = $this->container->has($type) ? 'this service is abstract' : 'no such service exists'; + $message = \sprintf('references %s "%s" but %s.%s', $r->isInterface() ? 'interface' : 'class', $type, $message, $alternatives); + if ($r->isInterface() && !$alternatives) { + $message .= ' Did you create a class that implements this interface?'; + } + } + $message = \sprintf('Cannot autowire service "%s": %s %s', $this->currentId, $label, $message); + if (null !== $this->lastFailure) { + $message = $this->lastFailure . "\n" . $message; + $this->lastFailure = null; + } + return $message; + } + private function createTypeAlternatives(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference $reference) + { + // try suggesting available aliases first + if ($message = $this->getAliasesSuggestionForType($type = $reference->getType())) { + return ' ' . $message; + } + if (null === $this->ambiguousServiceTypes) { + $this->populateAvailableTypes(); + } + if (isset($this->ambiguousServiceTypes[$type])) { + $message = \sprintf('one of these existing services: "%s"', \implode('", "', $this->ambiguousServiceTypes[$type])); + } elseif (isset($this->types[$type])) { + $message = \sprintf('the existing "%s" service', $this->types[$type]); + } elseif ($reference->getRequiringClass() && !$reference->canBeAutoregistered() && !$this->strictMode) { + return ' It cannot be auto-registered because it is from a different root namespace.'; + } else { + return ''; + } + return \sprintf(' You should maybe alias this %s to %s.', \class_exists($type, \false) ? 'class' : 'interface', $message); + } + /** + * @deprecated since version 3.3, to be removed in 4.0. + */ + private static function getResourceMetadataForMethod(\ReflectionMethod $method) + { + $methodArgumentsMetadata = []; + foreach ($method->getParameters() as $parameter) { + try { + $class = $parameter->getClass(); + } catch (\ReflectionException $e) { + // type-hint is against a non-existent class + $class = \false; + } + $isVariadic = \method_exists($parameter, 'isVariadic') && $parameter->isVariadic(); + $methodArgumentsMetadata[] = ['class' => $class, 'isOptional' => $parameter->isOptional(), 'defaultValue' => $parameter->isOptional() && !$isVariadic ? $parameter->getDefaultValue() : null]; + } + return $methodArgumentsMetadata; + } + private function getAliasesSuggestionForType($type, $extraContext = null) + { + $aliases = []; + foreach (\class_parents($type) + \class_implements($type) as $parent) { + if ($this->container->has($parent) && !$this->container->findDefinition($parent)->isAbstract()) { + $aliases[] = $parent; + } + } + $extraContext = $extraContext ? ' ' . $extraContext : ''; + if (1 < ($len = \count($aliases))) { + $message = \sprintf('Try changing the type-hint%s to one of its parents: ', $extraContext); + for ($i = 0, --$len; $i < $len; ++$i) { + $message .= \sprintf('%s "%s", ', \class_exists($aliases[$i], \false) ? 'class' : 'interface', $aliases[$i]); + } + $message .= \sprintf('or %s "%s".', \class_exists($aliases[$i], \false) ? 'class' : 'interface', $aliases[$i]); + return $message; + } + if ($aliases) { + return \sprintf('Try changing the type-hint%s to "%s" instead.', $extraContext, $aliases[0]); + } + return null; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/AutowireRequiredMethodsPass.php b/vendor/symfony/dependency-injection/Compiler/AutowireRequiredMethodsPass.php index 46bf22046..f119c1d03 100644 --- a/vendor/symfony/dependency-injection/Compiler/AutowireRequiredMethodsPass.php +++ b/vendor/symfony/dependency-injection/Compiler/AutowireRequiredMethodsPass.php @@ -1,62 +1,62 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -/** - * Looks for definitions with autowiring enabled and registers their corresponding "@required" methods as setters. - * - * @author Nicolas Grekas - */ -class AutowireRequiredMethodsPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - $value = parent::processValue($value, $isRoot); - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || !$value->isAutowired() || $value->isAbstract() || !$value->getClass()) { - return $value; - } - if (!($reflectionClass = $this->container->getReflectionClass($value->getClass(), \false))) { - return $value; - } - $alreadyCalledMethods = []; - foreach ($value->getMethodCalls() as list($method)) { - $alreadyCalledMethods[\strtolower($method)] = \true; - } - foreach ($reflectionClass->getMethods() as $reflectionMethod) { - $r = $reflectionMethod; - if ($r->isConstructor() || isset($alreadyCalledMethods[\strtolower($r->name)])) { - continue; - } - while (\true) { - if (\false !== ($doc = $r->getDocComment())) { - if (\false !== \stripos($doc, '@required') && \preg_match('#(?:^/\\*\\*|\\n\\s*+\\*)\\s*+@required(?:\\s|\\*/$)#i', $doc)) { - $value->addMethodCall($reflectionMethod->name); - break; - } - if (\false === \stripos($doc, '@inheritdoc') || !\preg_match('#(?:^/\\*\\*|\\n\\s*+\\*)\\s*+(?:\\{@inheritdoc\\}|@inheritdoc)(?:\\s|\\*/$)#i', $doc)) { - break; - } - } - try { - $r = $r->getPrototype(); - } catch (\ReflectionException $e) { - break; - // method has no prototype - } - } - } - return $value; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +/** + * Looks for definitions with autowiring enabled and registers their corresponding "@required" methods as setters. + * + * @author Nicolas Grekas + */ +class AutowireRequiredMethodsPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + $value = parent::processValue($value, $isRoot); + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || !$value->isAutowired() || $value->isAbstract() || !$value->getClass()) { + return $value; + } + if (!($reflectionClass = $this->container->getReflectionClass($value->getClass(), \false))) { + return $value; + } + $alreadyCalledMethods = []; + foreach ($value->getMethodCalls() as list($method)) { + $alreadyCalledMethods[\strtolower($method)] = \true; + } + foreach ($reflectionClass->getMethods() as $reflectionMethod) { + $r = $reflectionMethod; + if ($r->isConstructor() || isset($alreadyCalledMethods[\strtolower($r->name)])) { + continue; + } + while (\true) { + if (\false !== ($doc = $r->getDocComment())) { + if (\false !== \stripos($doc, '@required') && \preg_match('#(?:^/\\*\\*|\\n\\s*+\\*)\\s*+@required(?:\\s|\\*/$)#i', $doc)) { + $value->addMethodCall($reflectionMethod->name); + break; + } + if (\false === \stripos($doc, '@inheritdoc') || !\preg_match('#(?:^/\\*\\*|\\n\\s*+\\*)\\s*+(?:\\{@inheritdoc\\}|@inheritdoc)(?:\\s|\\*/$)#i', $doc)) { + break; + } + } + try { + $r = $r->getPrototype(); + } catch (\ReflectionException $e) { + break; + // method has no prototype + } + } + } + return $value; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/CheckArgumentsValidityPass.php b/vendor/symfony/dependency-injection/Compiler/CheckArgumentsValidityPass.php index 1715e355a..2686038bd 100644 --- a/vendor/symfony/dependency-injection/Compiler/CheckArgumentsValidityPass.php +++ b/vendor/symfony/dependency-injection/Compiler/CheckArgumentsValidityPass.php @@ -1,76 +1,76 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -/** - * Checks if arguments of methods are properly configured. - * - * @author Kévin Dunglas - * @author Nicolas Grekas - */ -class CheckArgumentsValidityPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - private $throwExceptions; - public function __construct($throwExceptions = \true) - { - $this->throwExceptions = $throwExceptions; - } - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - return parent::processValue($value, $isRoot); - } - $i = 0; - foreach ($value->getArguments() as $k => $v) { - if ($k !== $i++) { - if (!\is_int($k)) { - $msg = \sprintf('Invalid constructor argument for service "%s": integer expected but found string "%s". Check your service definition.', $this->currentId, $k); - $value->addError($msg); - if ($this->throwExceptions) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException($msg); - } - break; - } - $msg = \sprintf('Invalid constructor argument %d for service "%s": argument %d must be defined before. Check your service definition.', 1 + $k, $this->currentId, $i); - $value->addError($msg); - if ($this->throwExceptions) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException($msg); - } - } - } - foreach ($value->getMethodCalls() as $methodCall) { - $i = 0; - foreach ($methodCall[1] as $k => $v) { - if ($k !== $i++) { - if (!\is_int($k)) { - $msg = \sprintf('Invalid argument for method call "%s" of service "%s": integer expected but found string "%s". Check your service definition.', $methodCall[0], $this->currentId, $k); - $value->addError($msg); - if ($this->throwExceptions) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException($msg); - } - break; - } - $msg = \sprintf('Invalid argument %d for method call "%s" of service "%s": argument %d must be defined before. Check your service definition.', 1 + $k, $methodCall[0], $this->currentId, $i); - $value->addError($msg); - if ($this->throwExceptions) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException($msg); - } - } - } - } - return null; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +/** + * Checks if arguments of methods are properly configured. + * + * @author Kévin Dunglas + * @author Nicolas Grekas + */ +class CheckArgumentsValidityPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + private $throwExceptions; + public function __construct($throwExceptions = \true) + { + $this->throwExceptions = $throwExceptions; + } + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + return parent::processValue($value, $isRoot); + } + $i = 0; + foreach ($value->getArguments() as $k => $v) { + if ($k !== $i++) { + if (!\is_int($k)) { + $msg = \sprintf('Invalid constructor argument for service "%s": integer expected but found string "%s". Check your service definition.', $this->currentId, $k); + $value->addError($msg); + if ($this->throwExceptions) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException($msg); + } + break; + } + $msg = \sprintf('Invalid constructor argument %d for service "%s": argument %d must be defined before. Check your service definition.', 1 + $k, $this->currentId, $i); + $value->addError($msg); + if ($this->throwExceptions) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException($msg); + } + } + } + foreach ($value->getMethodCalls() as $methodCall) { + $i = 0; + foreach ($methodCall[1] as $k => $v) { + if ($k !== $i++) { + if (!\is_int($k)) { + $msg = \sprintf('Invalid argument for method call "%s" of service "%s": integer expected but found string "%s". Check your service definition.', $methodCall[0], $this->currentId, $k); + $value->addError($msg); + if ($this->throwExceptions) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException($msg); + } + break; + } + $msg = \sprintf('Invalid argument %d for method call "%s" of service "%s": argument %d must be defined before. Check your service definition.', 1 + $k, $methodCall[0], $this->currentId, $i); + $value->addError($msg); + if ($this->throwExceptions) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException($msg); + } + } + } + } + return null; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/CheckCircularReferencesPass.php b/vendor/symfony/dependency-injection/Compiler/CheckCircularReferencesPass.php index 4cdcac6f3..793383c48 100644 --- a/vendor/symfony/dependency-injection/Compiler/CheckCircularReferencesPass.php +++ b/vendor/symfony/dependency-injection/Compiler/CheckCircularReferencesPass.php @@ -1,68 +1,68 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; -/** - * Checks your services for circular references. - * - * References from method calls are ignored since we might be able to resolve - * these references depending on the order in which services are called. - * - * Circular reference from method calls will only be detected at run-time. - * - * @author Johannes M. Schmitt - */ -class CheckCircularReferencesPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - private $currentPath; - private $checkedNodes; - /** - * Checks the ContainerBuilder object for circular references. - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $graph = $container->getCompiler()->getServiceReferenceGraph(); - $this->checkedNodes = []; - foreach ($graph->getNodes() as $id => $node) { - $this->currentPath = [$id]; - $this->checkOutEdges($node->getOutEdges()); - } - } - /** - * Checks for circular references. - * - * @param ServiceReferenceGraphEdge[] $edges An array of Edges - * - * @throws ServiceCircularReferenceException when a circular reference is found - */ - private function checkOutEdges(array $edges) - { - foreach ($edges as $edge) { - $node = $edge->getDestNode(); - $id = $node->getId(); - if (empty($this->checkedNodes[$id])) { - // Don't check circular references for lazy edges - if (!$node->getValue() || !$edge->isLazy() && !$edge->isWeak()) { - $searchKey = \array_search($id, $this->currentPath); - $this->currentPath[] = $id; - if (\false !== $searchKey) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, \array_slice($this->currentPath, $searchKey)); - } - $this->checkOutEdges($node->getOutEdges()); - } - $this->checkedNodes[$id] = \true; - \array_pop($this->currentPath); - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; +/** + * Checks your services for circular references. + * + * References from method calls are ignored since we might be able to resolve + * these references depending on the order in which services are called. + * + * Circular reference from method calls will only be detected at run-time. + * + * @author Johannes M. Schmitt + */ +class CheckCircularReferencesPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + private $currentPath; + private $checkedNodes; + /** + * Checks the ContainerBuilder object for circular references. + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $graph = $container->getCompiler()->getServiceReferenceGraph(); + $this->checkedNodes = []; + foreach ($graph->getNodes() as $id => $node) { + $this->currentPath = [$id]; + $this->checkOutEdges($node->getOutEdges()); + } + } + /** + * Checks for circular references. + * + * @param ServiceReferenceGraphEdge[] $edges An array of Edges + * + * @throws ServiceCircularReferenceException when a circular reference is found + */ + private function checkOutEdges(array $edges) + { + foreach ($edges as $edge) { + $node = $edge->getDestNode(); + $id = $node->getId(); + if (empty($this->checkedNodes[$id])) { + // Don't check circular references for lazy edges + if (!$node->getValue() || !$edge->isLazy() && !$edge->isWeak()) { + $searchKey = \array_search($id, $this->currentPath); + $this->currentPath[] = $id; + if (\false !== $searchKey) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, \array_slice($this->currentPath, $searchKey)); + } + $this->checkOutEdges($node->getOutEdges()); + } + $this->checkedNodes[$id] = \true; + \array_pop($this->currentPath); + } + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/CheckDefinitionValidityPass.php b/vendor/symfony/dependency-injection/Compiler/CheckDefinitionValidityPass.php index 36eddeded..afb3403f8 100644 --- a/vendor/symfony/dependency-injection/Compiler/CheckDefinitionValidityPass.php +++ b/vendor/symfony/dependency-injection/Compiler/CheckDefinitionValidityPass.php @@ -1,81 +1,81 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -/** - * This pass validates each definition individually only taking the information - * into account which is contained in the definition itself. - * - * Later passes can rely on the following, and specifically do not need to - * perform these checks themselves: - * - * - non synthetic, non abstract services always have a class set - * - synthetic services are always public - * - * @author Johannes M. Schmitt - */ -class CheckDefinitionValidityPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - /** - * Processes the ContainerBuilder to validate the Definition. - * - * @throws RuntimeException When the Definition is invalid - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - foreach ($container->getDefinitions() as $id => $definition) { - // synthetic service is public - if ($definition->isSynthetic() && !($definition->isPublic() || $definition->isPrivate())) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('A synthetic service ("%s") must be public.', $id)); - } - // non-synthetic, non-abstract service has class - if (!$definition->isAbstract() && !$definition->isSynthetic() && !$definition->getClass()) { - if ($definition->getFactory()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Please add the class to service "%s" even if it is constructed by a factory since we might need to add method calls based on compile-time checks.', $id)); - } - if (\class_exists($id) || \interface_exists($id, \false)) { - if (0 === \strpos($id, '\\') && 1 < \substr_count($id, '\\')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The definition for "%s" has no class attribute, and appears to reference a class or interface. Please specify the class attribute explicitly or remove the leading backslash by renaming the service to "%s" to get rid of this error.', $id, \substr($id, 1))); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The definition for "%s" has no class attribute, and appears to reference a class or interface in the global namespace. Leaving out the "class" attribute is only allowed for namespaced classes. Please specify the class attribute explicitly to get rid of this error.', $id)); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The definition for "%s" has no class. If you intend to inject this service dynamically at runtime, please mark it as synthetic=true. If this is an abstract definition solely used by child definitions, please add abstract=true, otherwise specify a class to get rid of this error.', $id)); - } - // tag attribute values must be scalars - foreach ($definition->getTags() as $name => $tags) { - foreach ($tags as $attributes) { - foreach ($attributes as $attribute => $value) { - if (!\is_scalar($value) && null !== $value) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('A "tags" attribute must be of a scalar-type for service "%s", tag "%s", attribute "%s".', $id, $name, $attribute)); - } - } - } - } - if ($definition->isPublic() && !$definition->isPrivate()) { - $resolvedId = $container->resolveEnvPlaceholders($id, null, $usedEnvs); - if (null !== $usedEnvs) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException([$resolvedId], null, 'A service name ("%s") cannot contain dynamic values.'); - } - } - } - foreach ($container->getAliases() as $id => $alias) { - if ($alias->isPublic() && !$alias->isPrivate()) { - $resolvedId = $container->resolveEnvPlaceholders($id, null, $usedEnvs); - if (null !== $usedEnvs) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException([$resolvedId], null, 'An alias name ("%s") cannot contain dynamic values.'); - } - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +/** + * This pass validates each definition individually only taking the information + * into account which is contained in the definition itself. + * + * Later passes can rely on the following, and specifically do not need to + * perform these checks themselves: + * + * - non synthetic, non abstract services always have a class set + * - synthetic services are always public + * + * @author Johannes M. Schmitt + */ +class CheckDefinitionValidityPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + /** + * Processes the ContainerBuilder to validate the Definition. + * + * @throws RuntimeException When the Definition is invalid + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + foreach ($container->getDefinitions() as $id => $definition) { + // synthetic service is public + if ($definition->isSynthetic() && !($definition->isPublic() || $definition->isPrivate())) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('A synthetic service ("%s") must be public.', $id)); + } + // non-synthetic, non-abstract service has class + if (!$definition->isAbstract() && !$definition->isSynthetic() && !$definition->getClass()) { + if ($definition->getFactory()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Please add the class to service "%s" even if it is constructed by a factory since we might need to add method calls based on compile-time checks.', $id)); + } + if (\class_exists($id) || \interface_exists($id, \false)) { + if (0 === \strpos($id, '\\') && 1 < \substr_count($id, '\\')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The definition for "%s" has no class attribute, and appears to reference a class or interface. Please specify the class attribute explicitly or remove the leading backslash by renaming the service to "%s" to get rid of this error.', $id, \substr($id, 1))); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The definition for "%s" has no class attribute, and appears to reference a class or interface in the global namespace. Leaving out the "class" attribute is only allowed for namespaced classes. Please specify the class attribute explicitly to get rid of this error.', $id)); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The definition for "%s" has no class. If you intend to inject this service dynamically at runtime, please mark it as synthetic=true. If this is an abstract definition solely used by child definitions, please add abstract=true, otherwise specify a class to get rid of this error.', $id)); + } + // tag attribute values must be scalars + foreach ($definition->getTags() as $name => $tags) { + foreach ($tags as $attributes) { + foreach ($attributes as $attribute => $value) { + if (!\is_scalar($value) && null !== $value) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('A "tags" attribute must be of a scalar-type for service "%s", tag "%s", attribute "%s".', $id, $name, $attribute)); + } + } + } + } + if ($definition->isPublic() && !$definition->isPrivate()) { + $resolvedId = $container->resolveEnvPlaceholders($id, null, $usedEnvs); + if (null !== $usedEnvs) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException([$resolvedId], null, 'A service name ("%s") cannot contain dynamic values.'); + } + } + } + foreach ($container->getAliases() as $id => $alias) { + if ($alias->isPublic() && !$alias->isPrivate()) { + $resolvedId = $container->resolveEnvPlaceholders($id, null, $usedEnvs); + if (null !== $usedEnvs) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException([$resolvedId], null, 'An alias name ("%s") cannot contain dynamic values.'); + } + } + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php b/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php index 550dd1c0a..611ae9c0d 100644 --- a/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php +++ b/vendor/symfony/dependency-injection/Compiler/CheckExceptionOnInvalidReferenceBehaviorPass.php @@ -1,33 +1,33 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Checks that all references are pointing to a valid service. - * - * @author Johannes M. Schmitt - */ -class CheckExceptionOnInvalidReferenceBehaviorPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - protected function processValue($value, $isRoot = \false) - { - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - return parent::processValue($value, $isRoot); - } - if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE === $value->getInvalidBehavior() && !$this->container->has($id = (string) $value)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id, $this->currentId); - } - return $value; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Checks that all references are pointing to a valid service. + * + * @author Johannes M. Schmitt + */ +class CheckExceptionOnInvalidReferenceBehaviorPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + protected function processValue($value, $isRoot = \false) + { + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + return parent::processValue($value, $isRoot); + } + if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE === $value->getInvalidBehavior() && !$this->container->has($id = (string) $value)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id, $this->currentId); + } + return $value; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/CheckReferenceValidityPass.php b/vendor/symfony/dependency-injection/Compiler/CheckReferenceValidityPass.php index d3d9dfe5d..240006379 100644 --- a/vendor/symfony/dependency-injection/Compiler/CheckReferenceValidityPass.php +++ b/vendor/symfony/dependency-injection/Compiler/CheckReferenceValidityPass.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Checks the validity of references. - * - * The following checks are performed by this pass: - * - target definitions are not abstract - * - * @author Johannes M. Schmitt - */ -class CheckReferenceValidityPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - protected function processValue($value, $isRoot = \false) - { - if ($isRoot && $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && ($value->isSynthetic() || $value->isAbstract())) { - return $value; - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && $this->container->hasDefinition((string) $value)) { - $targetDefinition = $this->container->getDefinition((string) $value); - if ($targetDefinition->isAbstract()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The definition "%s" has a reference to an abstract definition "%s". Abstract definitions cannot be the target of references.', $this->currentId, $value)); - } - } - return parent::processValue($value, $isRoot); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Checks the validity of references. + * + * The following checks are performed by this pass: + * - target definitions are not abstract + * + * @author Johannes M. Schmitt + */ +class CheckReferenceValidityPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + protected function processValue($value, $isRoot = \false) + { + if ($isRoot && $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && ($value->isSynthetic() || $value->isAbstract())) { + return $value; + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && $this->container->hasDefinition((string) $value)) { + $targetDefinition = $this->container->getDefinition((string) $value); + if ($targetDefinition->isAbstract()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The definition "%s" has a reference to an abstract definition "%s". Abstract definitions cannot be the target of references.', $this->currentId, $value)); + } + } + return parent::processValue($value, $isRoot); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/Compiler.php b/vendor/symfony/dependency-injection/Compiler/Compiler.php index c9905a579..5709b6458 100644 --- a/vendor/symfony/dependency-injection/Compiler/Compiler.php +++ b/vendor/symfony/dependency-injection/Compiler/Compiler.php @@ -1,144 +1,144 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException; -/** - * This class is used to remove circular dependencies between individual passes. - * - * @author Johannes M. Schmitt - */ -class Compiler -{ - private $passConfig; - private $log = []; - private $loggingFormatter; - private $serviceReferenceGraph; - public function __construct() - { - $this->passConfig = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig(); - $this->serviceReferenceGraph = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraph(); - } - /** - * Returns the PassConfig. - * - * @return PassConfig The PassConfig instance - */ - public function getPassConfig() - { - return $this->passConfig; - } - /** - * Returns the ServiceReferenceGraph. - * - * @return ServiceReferenceGraph The ServiceReferenceGraph instance - */ - public function getServiceReferenceGraph() - { - return $this->serviceReferenceGraph; - } - /** - * Returns the logging formatter which can be used by compilation passes. - * - * @return LoggingFormatter - * - * @deprecated since version 3.3, to be removed in 4.0. Use the ContainerBuilder::log() method instead. - */ - public function getLoggingFormatter() - { - if (null === $this->loggingFormatter) { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', __METHOD__), \E_USER_DEPRECATED); - $this->loggingFormatter = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\LoggingFormatter(); - } - return $this->loggingFormatter; - } - /** - * Adds a pass to the PassConfig. - * - * @param CompilerPassInterface $pass A compiler pass - * @param string $type The type of the pass - */ - public function addPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $type = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION) - { - if (\func_num_args() >= 3) { - $priority = \func_get_arg(2); - } else { - if (__CLASS__ !== static::class) { - $r = new \ReflectionMethod($this, __FUNCTION__); - if (__CLASS__ !== $r->getDeclaringClass()->getName()) { - @\trigger_error(\sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since Symfony 3.2.', __METHOD__), \E_USER_DEPRECATED); - } - } - $priority = 0; - } - $this->passConfig->addPass($pass, $type, $priority); - } - /** - * Adds a log message. - * - * @param string $string The log message - * - * @deprecated since version 3.3, to be removed in 4.0. Use the ContainerBuilder::log() method instead. - */ - public function addLogMessage($string) - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', __METHOD__), \E_USER_DEPRECATED); - $this->log[] = $string; - } - /** - * @final - */ - public function log(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $message) - { - if (\false !== \strpos($message, "\n")) { - $message = \str_replace("\n", "\n" . \get_class($pass) . ': ', \trim($message)); - } - $this->log[] = \get_class($pass) . ': ' . $message; - } - /** - * Returns the log. - * - * @return array Log array - */ - public function getLog() - { - return $this->log; - } - /** - * Run the Compiler and process all Passes. - */ - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - try { - foreach ($this->passConfig->getPasses() as $pass) { - $pass->process($container); - } - } catch (\Exception $e) { - $usedEnvs = []; - $prev = $e; - do { - $msg = $prev->getMessage(); - if ($msg !== ($resolvedMsg = $container->resolveEnvPlaceholders($msg, null, $usedEnvs))) { - $r = new \ReflectionProperty($prev, 'message'); - $r->setAccessible(\true); - $r->setValue($prev, $resolvedMsg); - } - } while ($prev = $prev->getPrevious()); - if ($usedEnvs) { - $e = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException($usedEnvs, $e); - } - throw $e; - } finally { - $this->getServiceReferenceGraph()->clear(); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException; +/** + * This class is used to remove circular dependencies between individual passes. + * + * @author Johannes M. Schmitt + */ +class Compiler +{ + private $passConfig; + private $log = []; + private $loggingFormatter; + private $serviceReferenceGraph; + public function __construct() + { + $this->passConfig = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig(); + $this->serviceReferenceGraph = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraph(); + } + /** + * Returns the PassConfig. + * + * @return PassConfig The PassConfig instance + */ + public function getPassConfig() + { + return $this->passConfig; + } + /** + * Returns the ServiceReferenceGraph. + * + * @return ServiceReferenceGraph The ServiceReferenceGraph instance + */ + public function getServiceReferenceGraph() + { + return $this->serviceReferenceGraph; + } + /** + * Returns the logging formatter which can be used by compilation passes. + * + * @return LoggingFormatter + * + * @deprecated since version 3.3, to be removed in 4.0. Use the ContainerBuilder::log() method instead. + */ + public function getLoggingFormatter() + { + if (null === $this->loggingFormatter) { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', __METHOD__), \E_USER_DEPRECATED); + $this->loggingFormatter = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\LoggingFormatter(); + } + return $this->loggingFormatter; + } + /** + * Adds a pass to the PassConfig. + * + * @param CompilerPassInterface $pass A compiler pass + * @param string $type The type of the pass + */ + public function addPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $type = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION) + { + if (\func_num_args() >= 3) { + $priority = \func_get_arg(2); + } else { + if (__CLASS__ !== static::class) { + $r = new \ReflectionMethod($this, __FUNCTION__); + if (__CLASS__ !== $r->getDeclaringClass()->getName()) { + @\trigger_error(\sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since Symfony 3.2.', __METHOD__), \E_USER_DEPRECATED); + } + } + $priority = 0; + } + $this->passConfig->addPass($pass, $type, $priority); + } + /** + * Adds a log message. + * + * @param string $string The log message + * + * @deprecated since version 3.3, to be removed in 4.0. Use the ContainerBuilder::log() method instead. + */ + public function addLogMessage($string) + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', __METHOD__), \E_USER_DEPRECATED); + $this->log[] = $string; + } + /** + * @final + */ + public function log(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $message) + { + if (\false !== \strpos($message, "\n")) { + $message = \str_replace("\n", "\n" . \get_class($pass) . ': ', \trim($message)); + } + $this->log[] = \get_class($pass) . ': ' . $message; + } + /** + * Returns the log. + * + * @return array Log array + */ + public function getLog() + { + return $this->log; + } + /** + * Run the Compiler and process all Passes. + */ + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + try { + foreach ($this->passConfig->getPasses() as $pass) { + $pass->process($container); + } + } catch (\Exception $e) { + $usedEnvs = []; + $prev = $e; + do { + $msg = $prev->getMessage(); + if ($msg !== ($resolvedMsg = $container->resolveEnvPlaceholders($msg, null, $usedEnvs))) { + $r = new \ReflectionProperty($prev, 'message'); + $r->setAccessible(\true); + $r->setValue($prev, $resolvedMsg); + } + } while ($prev = $prev->getPrevious()); + if ($usedEnvs) { + $e = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException($usedEnvs, $e); + } + throw $e; + } finally { + $this->getServiceReferenceGraph()->clear(); + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/CompilerPassInterface.php b/vendor/symfony/dependency-injection/Compiler/CompilerPassInterface.php index 2db1600b4..b559c775b 100644 --- a/vendor/symfony/dependency-injection/Compiler/CompilerPassInterface.php +++ b/vendor/symfony/dependency-injection/Compiler/CompilerPassInterface.php @@ -1,25 +1,25 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * Interface that must be implemented by compilation passes. - * - * @author Johannes M. Schmitt - */ -interface CompilerPassInterface -{ - /** - * You can modify the container here before it is dumped to PHP code. - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * Interface that must be implemented by compilation passes. + * + * @author Johannes M. Schmitt + */ +interface CompilerPassInterface +{ + /** + * You can modify the container here before it is dumped to PHP code. + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container); +} diff --git a/vendor/symfony/dependency-injection/Compiler/DecoratorServicePass.php b/vendor/symfony/dependency-injection/Compiler/DecoratorServicePass.php index 654726fa9..f6eabd326 100644 --- a/vendor/symfony/dependency-injection/Compiler/DecoratorServicePass.php +++ b/vendor/symfony/dependency-injection/Compiler/DecoratorServicePass.php @@ -1,72 +1,72 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * Overwrites a service but keeps the overridden one. - * - * @author Christophe Coevoet - * @author Fabien Potencier - * @author Diego Saint Esteben - */ -class DecoratorServicePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $definitions = new \SplPriorityQueue(); - $order = \PHP_INT_MAX; - foreach ($container->getDefinitions() as $id => $definition) { - if (!($decorated = $definition->getDecoratedService())) { - continue; - } - $definitions->insert([$id, $definition], [$decorated[2], --$order]); - } - $decoratingDefinitions = []; - foreach ($definitions as list($id, $definition)) { - list($inner, $renamedId) = $definition->getDecoratedService(); - $definition->setDecoratedService(null); - if (!$renamedId) { - $renamedId = $id . '.inner'; - } - // we create a new alias/service for the service we are replacing - // to be able to reference it in the new one - if ($container->hasAlias($inner)) { - $alias = $container->getAlias($inner); - $public = $alias->isPublic(); - $private = $alias->isPrivate(); - $container->setAlias($renamedId, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($container->normalizeId($alias), \false)); - } else { - $decoratedDefinition = $container->getDefinition($inner); - $public = $decoratedDefinition->isPublic(); - $private = $decoratedDefinition->isPrivate(); - $decoratedDefinition->setPublic(\false); - $container->setDefinition($renamedId, $decoratedDefinition); - $decoratingDefinitions[$inner] = $decoratedDefinition; - } - if (isset($decoratingDefinitions[$inner])) { - $decoratingDefinition = $decoratingDefinitions[$inner]; - $definition->setTags(\array_merge($decoratingDefinition->getTags(), $definition->getTags())); - $autowiringTypes = $decoratingDefinition->getAutowiringTypes(\false); - if ($types = \array_merge($autowiringTypes, $definition->getAutowiringTypes(\false))) { - $definition->setAutowiringTypes($types); - } - $decoratingDefinition->setTags([]); - if ($autowiringTypes) { - $decoratingDefinition->setAutowiringTypes([]); - } - $decoratingDefinitions[$inner] = $definition; - } - $container->setAlias($inner, $id)->setPublic($public)->setPrivate($private); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * Overwrites a service but keeps the overridden one. + * + * @author Christophe Coevoet + * @author Fabien Potencier + * @author Diego Saint Esteben + */ +class DecoratorServicePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $definitions = new \SplPriorityQueue(); + $order = \PHP_INT_MAX; + foreach ($container->getDefinitions() as $id => $definition) { + if (!($decorated = $definition->getDecoratedService())) { + continue; + } + $definitions->insert([$id, $definition], [$decorated[2], --$order]); + } + $decoratingDefinitions = []; + foreach ($definitions as list($id, $definition)) { + list($inner, $renamedId) = $definition->getDecoratedService(); + $definition->setDecoratedService(null); + if (!$renamedId) { + $renamedId = $id . '.inner'; + } + // we create a new alias/service for the service we are replacing + // to be able to reference it in the new one + if ($container->hasAlias($inner)) { + $alias = $container->getAlias($inner); + $public = $alias->isPublic(); + $private = $alias->isPrivate(); + $container->setAlias($renamedId, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($container->normalizeId($alias), \false)); + } else { + $decoratedDefinition = $container->getDefinition($inner); + $public = $decoratedDefinition->isPublic(); + $private = $decoratedDefinition->isPrivate(); + $decoratedDefinition->setPublic(\false); + $container->setDefinition($renamedId, $decoratedDefinition); + $decoratingDefinitions[$inner] = $decoratedDefinition; + } + if (isset($decoratingDefinitions[$inner])) { + $decoratingDefinition = $decoratingDefinitions[$inner]; + $definition->setTags(\array_merge($decoratingDefinition->getTags(), $definition->getTags())); + $autowiringTypes = $decoratingDefinition->getAutowiringTypes(\false); + if ($types = \array_merge($autowiringTypes, $definition->getAutowiringTypes(\false))) { + $definition->setAutowiringTypes($types); + } + $decoratingDefinition->setTags([]); + if ($autowiringTypes) { + $decoratingDefinition->setAutowiringTypes([]); + } + $decoratingDefinitions[$inner] = $definition; + } + $container->setAlias($inner, $id)->setPublic($public)->setPrivate($private); + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/DefinitionErrorExceptionPass.php b/vendor/symfony/dependency-injection/Compiler/DefinitionErrorExceptionPass.php index a48b7b0ac..16e6db128 100644 --- a/vendor/symfony/dependency-injection/Compiler/DefinitionErrorExceptionPass.php +++ b/vendor/symfony/dependency-injection/Compiler/DefinitionErrorExceptionPass.php @@ -1,35 +1,35 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -/** - * Throws an exception for any Definitions that have errors and still exist. - * - * @author Ryan Weaver - */ -class DefinitionErrorExceptionPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || empty($value->getErrors())) { - return parent::processValue($value, $isRoot); - } - // only show the first error so the user can focus on it - $errors = $value->getErrors(); - $message = \reset($errors); - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException($message); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +/** + * Throws an exception for any Definitions that have errors and still exist. + * + * @author Ryan Weaver + */ +class DefinitionErrorExceptionPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || empty($value->getErrors())) { + return parent::processValue($value, $isRoot); + } + // only show the first error so the user can focus on it + $errors = $value->getErrors(); + $message = \reset($errors); + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException($message); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ExtensionCompilerPass.php b/vendor/symfony/dependency-injection/Compiler/ExtensionCompilerPass.php index 16bcea4a6..e1ddbbdcb 100644 --- a/vendor/symfony/dependency-injection/Compiler/ExtensionCompilerPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ExtensionCompilerPass.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * A pass to automatically process extensions if they implement - * CompilerPassInterface. - * - * @author Wouter J - */ -class ExtensionCompilerPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - foreach ($container->getExtensions() as $extension) { - if (!$extension instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface) { - continue; - } - $extension->process($container); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * A pass to automatically process extensions if they implement + * CompilerPassInterface. + * + * @author Wouter J + */ +class ExtensionCompilerPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + foreach ($container->getExtensions() as $extension) { + if (!$extension instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface) { + continue; + } + $extension->process($container); + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/FactoryReturnTypePass.php b/vendor/symfony/dependency-injection/Compiler/FactoryReturnTypePass.php index 209ad6fb3..6bab15255 100644 --- a/vendor/symfony/dependency-injection/Compiler/FactoryReturnTypePass.php +++ b/vendor/symfony/dependency-injection/Compiler/FactoryReturnTypePass.php @@ -1,101 +1,101 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * @author Guilhem N. - * - * @deprecated since version 3.3, to be removed in 4.0. - */ -class FactoryReturnTypePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - private $resolveClassPass; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass $resolveClassPass = null) - { - if (null === $resolveClassPass) { - @\trigger_error('The ' . __CLASS__ . ' class is deprecated since Symfony 3.3 and will be removed in 4.0.', \E_USER_DEPRECATED); - } - $this->resolveClassPass = $resolveClassPass; - } - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - // works only since php 7.0 and hhvm 3.11 - if (!\method_exists(\ReflectionMethod::class, 'getReturnType')) { - return; - } - $resolveClassPassChanges = null !== $this->resolveClassPass ? $this->resolveClassPass->getChanges() : []; - foreach ($container->getDefinitions() as $id => $definition) { - $this->updateDefinition($container, $id, $definition, $resolveClassPassChanges); - } - } - private function updateDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, $id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, array $resolveClassPassChanges, array $previous = []) - { - // circular reference - if (isset($previous[$id])) { - return; - } - $factory = $definition->getFactory(); - if (null === $factory || !isset($resolveClassPassChanges[$id]) && null !== $definition->getClass()) { - return; - } - $class = null; - if (\is_string($factory)) { - try { - $m = new \ReflectionFunction($factory); - if (\false !== $m->getFileName() && \file_exists($m->getFileName())) { - $container->fileExists($m->getFileName()); - } - } catch (\ReflectionException $e) { - return; - } - } else { - if ($factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $previous[$id] = \true; - $factoryId = $container->normalizeId($factory[0]); - $factoryDefinition = $container->findDefinition($factoryId); - $this->updateDefinition($container, $factoryId, $factoryDefinition, $resolveClassPassChanges, $previous); - $class = $factoryDefinition->getClass(); - } else { - $class = $factory[0]; - } - if (!($m = $container->getReflectionClass($class, \false))) { - return; - } - try { - $m = $m->getMethod($factory[1]); - } catch (\ReflectionException $e) { - return; - } - } - $returnType = $m->getReturnType(); - if (null !== $returnType && !$returnType->isBuiltin()) { - $returnType = $returnType instanceof \ReflectionNamedType ? $returnType->getName() : $returnType->__toString(); - if (null !== $class) { - $declaringClass = $m->getDeclaringClass()->getName(); - if ('self' === \strtolower($returnType)) { - $returnType = $declaringClass; - } elseif ('parent' === \strtolower($returnType)) { - $returnType = \get_parent_class($declaringClass) ?: null; - } - } - if (null !== $returnType && (!isset($resolveClassPassChanges[$id]) || $returnType !== $resolveClassPassChanges[$id])) { - @\trigger_error(\sprintf('Relying on its factory\'s return-type to define the class of service "%s" is deprecated since Symfony 3.3 and won\'t work in 4.0. Set the "class" attribute to "%s" on the service definition instead.', $id, $returnType), \E_USER_DEPRECATED); - } - $definition->setClass($returnType); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * @author Guilhem N. + * + * @deprecated since version 3.3, to be removed in 4.0. + */ +class FactoryReturnTypePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + private $resolveClassPass; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass $resolveClassPass = null) + { + if (null === $resolveClassPass) { + @\trigger_error('The ' . __CLASS__ . ' class is deprecated since Symfony 3.3 and will be removed in 4.0.', \E_USER_DEPRECATED); + } + $this->resolveClassPass = $resolveClassPass; + } + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + // works only since php 7.0 and hhvm 3.11 + if (!\method_exists(\ReflectionMethod::class, 'getReturnType')) { + return; + } + $resolveClassPassChanges = null !== $this->resolveClassPass ? $this->resolveClassPass->getChanges() : []; + foreach ($container->getDefinitions() as $id => $definition) { + $this->updateDefinition($container, $id, $definition, $resolveClassPassChanges); + } + } + private function updateDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, $id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, array $resolveClassPassChanges, array $previous = []) + { + // circular reference + if (isset($previous[$id])) { + return; + } + $factory = $definition->getFactory(); + if (null === $factory || !isset($resolveClassPassChanges[$id]) && null !== $definition->getClass()) { + return; + } + $class = null; + if (\is_string($factory)) { + try { + $m = new \ReflectionFunction($factory); + if (\false !== $m->getFileName() && \file_exists($m->getFileName())) { + $container->fileExists($m->getFileName()); + } + } catch (\ReflectionException $e) { + return; + } + } else { + if ($factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $previous[$id] = \true; + $factoryId = $container->normalizeId($factory[0]); + $factoryDefinition = $container->findDefinition($factoryId); + $this->updateDefinition($container, $factoryId, $factoryDefinition, $resolveClassPassChanges, $previous); + $class = $factoryDefinition->getClass(); + } else { + $class = $factory[0]; + } + if (!($m = $container->getReflectionClass($class, \false))) { + return; + } + try { + $m = $m->getMethod($factory[1]); + } catch (\ReflectionException $e) { + return; + } + } + $returnType = $m->getReturnType(); + if (null !== $returnType && !$returnType->isBuiltin()) { + $returnType = $returnType instanceof \ReflectionNamedType ? $returnType->getName() : $returnType->__toString(); + if (null !== $class) { + $declaringClass = $m->getDeclaringClass()->getName(); + if ('self' === \strtolower($returnType)) { + $returnType = $declaringClass; + } elseif ('parent' === \strtolower($returnType)) { + $returnType = \get_parent_class($declaringClass) ?: null; + } + } + if (null !== $returnType && (!isset($resolveClassPassChanges[$id]) || $returnType !== $resolveClassPassChanges[$id])) { + @\trigger_error(\sprintf('Relying on its factory\'s return-type to define the class of service "%s" is deprecated since Symfony 3.3 and won\'t work in 4.0. Set the "class" attribute to "%s" on the service definition instead.', $id, $returnType), \E_USER_DEPRECATED); + } + $definition->setClass($returnType); + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/InlineServiceDefinitionsPass.php b/vendor/symfony/dependency-injection/Compiler/InlineServiceDefinitionsPass.php index f822d3893..c03008293 100644 --- a/vendor/symfony/dependency-injection/Compiler/InlineServiceDefinitionsPass.php +++ b/vendor/symfony/dependency-injection/Compiler/InlineServiceDefinitionsPass.php @@ -1,128 +1,128 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Inline service definitions where this is possible. - * - * @author Johannes M. Schmitt - */ -class InlineServiceDefinitionsPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatablePassInterface -{ - private $cloningIds = []; - private $inlinedServiceIds = []; - /** - * {@inheritdoc} - */ - public function setRepeatedPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass $repeatedPass) - { - // no-op for BC - } - /** - * Returns an array of all services inlined by this pass. - * - * The key is the inlined service id and its value is the list of services it was inlined into. - * - * @deprecated since version 3.4, to be removed in 4.0. - * - * @return array - */ - public function getInlinedServiceIds() - { - @\trigger_error('Calling InlineServiceDefinitionsPass::getInlinedServiceIds() is deprecated since Symfony 3.4 and will be removed in 4.0.', \E_USER_DEPRECATED); - return $this->inlinedServiceIds; - } - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { - // Reference found in ArgumentInterface::getValues() are not inlineable - return $value; - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && $this->cloningIds) { - if ($value->isShared()) { - return $value; - } - $value = clone $value; - } - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || !$this->container->hasDefinition($id = $this->container->normalizeId($value))) { - return parent::processValue($value, $isRoot); - } - $definition = $this->container->getDefinition($id); - if (!$this->isInlineableDefinition($id, $definition, $this->container->getCompiler()->getServiceReferenceGraph())) { - return $value; - } - $this->container->log($this, \sprintf('Inlined service "%s" to "%s".', $id, $this->currentId)); - $this->inlinedServiceIds[$id][] = $this->currentId; - if ($definition->isShared()) { - return $definition; - } - if (isset($this->cloningIds[$id])) { - $ids = \array_keys($this->cloningIds); - $ids[] = $id; - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, \array_slice($ids, \array_search($id, $ids))); - } - $this->cloningIds[$id] = \true; - try { - return $this->processValue($definition); - } finally { - unset($this->cloningIds[$id]); - } - } - /** - * Checks if the definition is inlineable. - * - * @return bool If the definition is inlineable - */ - private function isInlineableDefinition($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraph $graph) - { - if ($definition->getErrors() || $definition->isDeprecated() || $definition->isLazy() || $definition->isSynthetic()) { - return \false; - } - if (!$definition->isShared()) { - return \true; - } - if ($definition->isPublic() || $definition->isPrivate()) { - return \false; - } - if (!$graph->hasNode($id)) { - return \true; - } - if ($this->currentId == $id) { - return \false; - } - $ids = []; - $isReferencedByConstructor = \false; - foreach ($graph->getNode($id)->getInEdges() as $edge) { - $isReferencedByConstructor = $isReferencedByConstructor || $edge->isReferencedByConstructor(); - if ($edge->isWeak() || $edge->isLazy()) { - return \false; - } - $ids[] = $edge->getSourceNode()->getId(); - } - if (!$ids) { - return \true; - } - if (\count(\array_unique($ids)) > 1) { - return \false; - } - if (\count($ids) > 1 && \is_array($factory = $definition->getFactory()) && ($factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || $factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition)) { - return \false; - } - return $this->container->getDefinition($ids[0])->isShared(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Inline service definitions where this is possible. + * + * @author Johannes M. Schmitt + */ +class InlineServiceDefinitionsPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatablePassInterface +{ + private $cloningIds = []; + private $inlinedServiceIds = []; + /** + * {@inheritdoc} + */ + public function setRepeatedPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass $repeatedPass) + { + // no-op for BC + } + /** + * Returns an array of all services inlined by this pass. + * + * The key is the inlined service id and its value is the list of services it was inlined into. + * + * @deprecated since version 3.4, to be removed in 4.0. + * + * @return array + */ + public function getInlinedServiceIds() + { + @\trigger_error('Calling InlineServiceDefinitionsPass::getInlinedServiceIds() is deprecated since Symfony 3.4 and will be removed in 4.0.', \E_USER_DEPRECATED); + return $this->inlinedServiceIds; + } + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { + // Reference found in ArgumentInterface::getValues() are not inlineable + return $value; + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && $this->cloningIds) { + if ($value->isShared()) { + return $value; + } + $value = clone $value; + } + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || !$this->container->hasDefinition($id = $this->container->normalizeId($value))) { + return parent::processValue($value, $isRoot); + } + $definition = $this->container->getDefinition($id); + if (!$this->isInlineableDefinition($id, $definition, $this->container->getCompiler()->getServiceReferenceGraph())) { + return $value; + } + $this->container->log($this, \sprintf('Inlined service "%s" to "%s".', $id, $this->currentId)); + $this->inlinedServiceIds[$id][] = $this->currentId; + if ($definition->isShared()) { + return $definition; + } + if (isset($this->cloningIds[$id])) { + $ids = \array_keys($this->cloningIds); + $ids[] = $id; + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, \array_slice($ids, \array_search($id, $ids))); + } + $this->cloningIds[$id] = \true; + try { + return $this->processValue($definition); + } finally { + unset($this->cloningIds[$id]); + } + } + /** + * Checks if the definition is inlineable. + * + * @return bool If the definition is inlineable + */ + private function isInlineableDefinition($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraph $graph) + { + if ($definition->getErrors() || $definition->isDeprecated() || $definition->isLazy() || $definition->isSynthetic()) { + return \false; + } + if (!$definition->isShared()) { + return \true; + } + if ($definition->isPublic() || $definition->isPrivate()) { + return \false; + } + if (!$graph->hasNode($id)) { + return \true; + } + if ($this->currentId == $id) { + return \false; + } + $ids = []; + $isReferencedByConstructor = \false; + foreach ($graph->getNode($id)->getInEdges() as $edge) { + $isReferencedByConstructor = $isReferencedByConstructor || $edge->isReferencedByConstructor(); + if ($edge->isWeak() || $edge->isLazy()) { + return \false; + } + $ids[] = $edge->getSourceNode()->getId(); + } + if (!$ids) { + return \true; + } + if (\count(\array_unique($ids)) > 1) { + return \false; + } + if (\count($ids) > 1 && \is_array($factory = $definition->getFactory()) && ($factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || $factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition)) { + return \false; + } + return $this->container->getDefinition($ids[0])->isShared(); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/LoggingFormatter.php b/vendor/symfony/dependency-injection/Compiler/LoggingFormatter.php index 5a011d9fa..0e75624e6 100644 --- a/vendor/symfony/dependency-injection/Compiler/LoggingFormatter.php +++ b/vendor/symfony/dependency-injection/Compiler/LoggingFormatter.php @@ -1,47 +1,47 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -@\trigger_error('The ' . __NAMESPACE__ . '\\LoggingFormatter class is deprecated since Symfony 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', \E_USER_DEPRECATED); -/** - * Used to format logging messages during the compilation. - * - * @author Johannes M. Schmitt - * - * @deprecated since version 3.3, to be removed in 4.0. Use the ContainerBuilder::log() method instead. - */ -class LoggingFormatter -{ - public function formatRemoveService(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $id, $reason) - { - return $this->format($pass, \sprintf('Removed service "%s"; reason: %s.', $id, $reason)); - } - public function formatInlineService(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $id, $target) - { - return $this->format($pass, \sprintf('Inlined service "%s" to "%s".', $id, $target)); - } - public function formatUpdateReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $serviceId, $oldDestId, $newDestId) - { - return $this->format($pass, \sprintf('Changed reference of service "%s" previously pointing to "%s" to "%s".', $serviceId, $oldDestId, $newDestId)); - } - public function formatResolveInheritance(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $childId, $parentId) - { - return $this->format($pass, \sprintf('Resolving inheritance for "%s" (parent: %s).', $childId, $parentId)); - } - public function formatUnusedAutowiringPatterns(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $id, array $patterns) - { - return $this->format($pass, \sprintf('Autowiring\'s patterns "%s" for service "%s" don\'t match any method.', \implode('", "', $patterns), $id)); - } - public function format(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $message) - { - return \sprintf('%s: %s', \get_class($pass), $message); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +@\trigger_error('The ' . __NAMESPACE__ . '\\LoggingFormatter class is deprecated since Symfony 3.3 and will be removed in 4.0. Use the ContainerBuilder::log() method instead.', \E_USER_DEPRECATED); +/** + * Used to format logging messages during the compilation. + * + * @author Johannes M. Schmitt + * + * @deprecated since version 3.3, to be removed in 4.0. Use the ContainerBuilder::log() method instead. + */ +class LoggingFormatter +{ + public function formatRemoveService(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $id, $reason) + { + return $this->format($pass, \sprintf('Removed service "%s"; reason: %s.', $id, $reason)); + } + public function formatInlineService(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $id, $target) + { + return $this->format($pass, \sprintf('Inlined service "%s" to "%s".', $id, $target)); + } + public function formatUpdateReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $serviceId, $oldDestId, $newDestId) + { + return $this->format($pass, \sprintf('Changed reference of service "%s" previously pointing to "%s" to "%s".', $serviceId, $oldDestId, $newDestId)); + } + public function formatResolveInheritance(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $childId, $parentId) + { + return $this->format($pass, \sprintf('Resolving inheritance for "%s" (parent: %s).', $childId, $parentId)); + } + public function formatUnusedAutowiringPatterns(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $id, array $patterns) + { + return $this->format($pass, \sprintf('Autowiring\'s patterns "%s" for service "%s" don\'t match any method.', \implode('", "', $patterns), $id)); + } + public function format(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $message) + { + return \sprintf('%s: %s', \get_class($pass), $message); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php b/vendor/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php index a21ac582d..3e287e466 100644 --- a/vendor/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php +++ b/vendor/symfony/dependency-injection/Compiler/MergeExtensionConfigurationPass.php @@ -1,178 +1,178 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ConfigurationExtensionInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\PrependExtensionInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface; -/** - * Merges extension configs into the container builder. - * - * @author Fabien Potencier - */ -class MergeExtensionConfigurationPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $parameters = $container->getParameterBag()->all(); - $definitions = $container->getDefinitions(); - $aliases = $container->getAliases(); - $exprLangProviders = $container->getExpressionLanguageProviders(); - foreach ($container->getExtensions() as $extension) { - if ($extension instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\PrependExtensionInterface) { - $extension->prepend($container); - } - } - foreach ($container->getExtensions() as $name => $extension) { - if (!($config = $container->getExtensionConfig($name))) { - // this extension was not called - continue; - } - $resolvingBag = $container->getParameterBag(); - if ($resolvingBag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag && $extension instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension) { - // create a dedicated bag so that we can track env vars per-extension - $resolvingBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationParameterBag($resolvingBag); - } - $config = $resolvingBag->resolveValue($config); - try { - $tmpContainer = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationContainerBuilder($extension, $resolvingBag); - $tmpContainer->setResourceTracking($container->isTrackingResources()); - $tmpContainer->addObjectResource($extension); - if ($extension instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ConfigurationExtensionInterface && null !== ($configuration = $extension->getConfiguration($config, $tmpContainer))) { - $tmpContainer->addObjectResource($configuration); - } - foreach ($exprLangProviders as $provider) { - $tmpContainer->addExpressionLanguageProvider($provider); - } - $extension->load($config, $tmpContainer); - } catch (\Exception $e) { - if ($resolvingBag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationParameterBag) { - $container->getParameterBag()->mergeEnvPlaceholders($resolvingBag); - } - throw $e; - } - if ($resolvingBag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationParameterBag) { - // don't keep track of env vars that are *overridden* when configs are merged - $resolvingBag->freezeAfterProcessing($extension, $tmpContainer); - } - $container->merge($tmpContainer); - $container->getParameterBag()->add($parameters); - } - $container->addDefinitions($definitions); - $container->addAliases($aliases); - } -} -/** - * @internal - */ -class MergeExtensionConfigurationParameterBag extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag -{ - private $processedEnvPlaceholders; - public function __construct(parent $parameterBag) - { - parent::__construct($parameterBag->all()); - $this->mergeEnvPlaceholders($parameterBag); - } - public function freezeAfterProcessing(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension $extension, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - if (!($config = $extension->getProcessedConfigs())) { - // Extension::processConfiguration() wasn't called, we cannot know how configs were merged - return; - } - $this->processedEnvPlaceholders = []; - // serialize config and container to catch env vars nested in object graphs - $config = \serialize($config) . \serialize($container->getDefinitions()) . \serialize($container->getAliases()) . \serialize($container->getParameterBag()->all()); - foreach (parent::getEnvPlaceholders() as $env => $placeholders) { - foreach ($placeholders as $placeholder) { - if (\false !== \stripos($config, $placeholder)) { - $this->processedEnvPlaceholders[$env] = $placeholders; - break; - } - } - } - } - /** - * {@inheritdoc} - */ - public function getEnvPlaceholders() - { - return null !== $this->processedEnvPlaceholders ? $this->processedEnvPlaceholders : parent::getEnvPlaceholders(); - } -} -/** - * A container builder preventing using methods that wouldn't have any effect from extensions. - * - * @internal - */ -class MergeExtensionConfigurationContainerBuilder extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder -{ - private $extensionClass; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface $extension, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface $parameterBag = null) - { - parent::__construct($parameterBag); - $this->extensionClass = \get_class($extension); - } - /** - * {@inheritdoc} - */ - public function addCompilerPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $type = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException(\sprintf('You cannot add compiler pass "%s" from extension "%s". Compiler passes must be registered before the container is compiled.', \get_class($pass), $this->extensionClass)); - } - /** - * {@inheritdoc} - */ - public function registerExtension(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface $extension) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException(\sprintf('You cannot register extension "%s" from "%s". Extensions must be registered before the container is compiled.', \get_class($extension), $this->extensionClass)); - } - /** - * {@inheritdoc} - */ - public function compile($resolveEnvPlaceholders = \false) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException(\sprintf('Cannot compile the container in extension "%s".', $this->extensionClass)); - } - /** - * {@inheritdoc} - */ - public function resolveEnvPlaceholders($value, $format = null, array &$usedEnvs = null) - { - if (\true !== $format || !\is_string($value)) { - return parent::resolveEnvPlaceholders($value, $format, $usedEnvs); - } - $bag = $this->getParameterBag(); - $value = $bag->resolveValue($value); - if (!$bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { - return parent::resolveEnvPlaceholders($value, $format, $usedEnvs); - } - foreach ($bag->getEnvPlaceholders() as $env => $placeholders) { - if (\false === \strpos($env, ':')) { - continue; - } - foreach ($placeholders as $placeholder) { - if (\false !== \stripos($value, $placeholder)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Using a cast in "env(%s)" is incompatible with resolution at compile time in "%s". The logic in the extension should be moved to a compiler pass, or an env parameter with no cast should be used instead.', $env, $this->extensionClass)); - } - } - } - return parent::resolveEnvPlaceholders($value, $format, $usedEnvs); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ConfigurationExtensionInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\PrependExtensionInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface; +/** + * Merges extension configs into the container builder. + * + * @author Fabien Potencier + */ +class MergeExtensionConfigurationPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $parameters = $container->getParameterBag()->all(); + $definitions = $container->getDefinitions(); + $aliases = $container->getAliases(); + $exprLangProviders = $container->getExpressionLanguageProviders(); + foreach ($container->getExtensions() as $extension) { + if ($extension instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\PrependExtensionInterface) { + $extension->prepend($container); + } + } + foreach ($container->getExtensions() as $name => $extension) { + if (!($config = $container->getExtensionConfig($name))) { + // this extension was not called + continue; + } + $resolvingBag = $container->getParameterBag(); + if ($resolvingBag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag && $extension instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension) { + // create a dedicated bag so that we can track env vars per-extension + $resolvingBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationParameterBag($resolvingBag); + } + $config = $resolvingBag->resolveValue($config); + try { + $tmpContainer = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationContainerBuilder($extension, $resolvingBag); + $tmpContainer->setResourceTracking($container->isTrackingResources()); + $tmpContainer->addObjectResource($extension); + if ($extension instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ConfigurationExtensionInterface && null !== ($configuration = $extension->getConfiguration($config, $tmpContainer))) { + $tmpContainer->addObjectResource($configuration); + } + foreach ($exprLangProviders as $provider) { + $tmpContainer->addExpressionLanguageProvider($provider); + } + $extension->load($config, $tmpContainer); + } catch (\Exception $e) { + if ($resolvingBag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationParameterBag) { + $container->getParameterBag()->mergeEnvPlaceholders($resolvingBag); + } + throw $e; + } + if ($resolvingBag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationParameterBag) { + // don't keep track of env vars that are *overridden* when configs are merged + $resolvingBag->freezeAfterProcessing($extension, $tmpContainer); + } + $container->merge($tmpContainer); + $container->getParameterBag()->add($parameters); + } + $container->addDefinitions($definitions); + $container->addAliases($aliases); + } +} +/** + * @internal + */ +class MergeExtensionConfigurationParameterBag extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag +{ + private $processedEnvPlaceholders; + public function __construct(parent $parameterBag) + { + parent::__construct($parameterBag->all()); + $this->mergeEnvPlaceholders($parameterBag); + } + public function freezeAfterProcessing(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension $extension, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + if (!($config = $extension->getProcessedConfigs())) { + // Extension::processConfiguration() wasn't called, we cannot know how configs were merged + return; + } + $this->processedEnvPlaceholders = []; + // serialize config and container to catch env vars nested in object graphs + $config = \serialize($config) . \serialize($container->getDefinitions()) . \serialize($container->getAliases()) . \serialize($container->getParameterBag()->all()); + foreach (parent::getEnvPlaceholders() as $env => $placeholders) { + foreach ($placeholders as $placeholder) { + if (\false !== \stripos($config, $placeholder)) { + $this->processedEnvPlaceholders[$env] = $placeholders; + break; + } + } + } + } + /** + * {@inheritdoc} + */ + public function getEnvPlaceholders() + { + return null !== $this->processedEnvPlaceholders ? $this->processedEnvPlaceholders : parent::getEnvPlaceholders(); + } +} +/** + * A container builder preventing using methods that wouldn't have any effect from extensions. + * + * @internal + */ +class MergeExtensionConfigurationContainerBuilder extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder +{ + private $extensionClass; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface $extension, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface $parameterBag = null) + { + parent::__construct($parameterBag); + $this->extensionClass = \get_class($extension); + } + /** + * {@inheritdoc} + */ + public function addCompilerPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $type = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException(\sprintf('You cannot add compiler pass "%s" from extension "%s". Compiler passes must be registered before the container is compiled.', \get_class($pass), $this->extensionClass)); + } + /** + * {@inheritdoc} + */ + public function registerExtension(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface $extension) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException(\sprintf('You cannot register extension "%s" from "%s". Extensions must be registered before the container is compiled.', \get_class($extension), $this->extensionClass)); + } + /** + * {@inheritdoc} + */ + public function compile($resolveEnvPlaceholders = \false) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException(\sprintf('Cannot compile the container in extension "%s".', $this->extensionClass)); + } + /** + * {@inheritdoc} + */ + public function resolveEnvPlaceholders($value, $format = null, array &$usedEnvs = null) + { + if (\true !== $format || !\is_string($value)) { + return parent::resolveEnvPlaceholders($value, $format, $usedEnvs); + } + $bag = $this->getParameterBag(); + $value = $bag->resolveValue($value); + if (!$bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { + return parent::resolveEnvPlaceholders($value, $format, $usedEnvs); + } + foreach ($bag->getEnvPlaceholders() as $env => $placeholders) { + if (\false === \strpos($env, ':')) { + continue; + } + foreach ($placeholders as $placeholder) { + if (\false !== \stripos($value, $placeholder)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Using a cast in "env(%s)" is incompatible with resolution at compile time in "%s". The logic in the extension should be moved to a compiler pass, or an env parameter with no cast should be used instead.', $env, $this->extensionClass)); + } + } + } + return parent::resolveEnvPlaceholders($value, $format, $usedEnvs); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/PassConfig.php b/vendor/symfony/dependency-injection/Compiler/PassConfig.php index 1b8b3210b..756356f19 100644 --- a/vendor/symfony/dependency-injection/Compiler/PassConfig.php +++ b/vendor/symfony/dependency-injection/Compiler/PassConfig.php @@ -1,201 +1,201 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -/** - * Compiler Pass Configuration. - * - * This class has a default configuration embedded. - * - * @author Johannes M. Schmitt - */ -class PassConfig -{ - const TYPE_AFTER_REMOVING = 'afterRemoving'; - const TYPE_BEFORE_OPTIMIZATION = 'beforeOptimization'; - const TYPE_BEFORE_REMOVING = 'beforeRemoving'; - const TYPE_OPTIMIZE = 'optimization'; - const TYPE_REMOVE = 'removing'; - private $mergePass; - private $afterRemovingPasses = []; - private $beforeOptimizationPasses = []; - private $beforeRemovingPasses = []; - private $optimizationPasses; - private $removingPasses; - public function __construct() - { - $this->mergePass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); - $this->beforeOptimizationPasses = [100 => [$resolveClassPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterEnvVarProcessorsPass()], -1000 => [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ExtensionCompilerPass()]]; - $this->optimizationPasses = [[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DecoratorServicePass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass(\false, \false), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\FactoryReturnTypePass($resolveClassPass), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckDefinitionValidityPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(\false), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveTaggedIteratorArgumentPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveReferencesToAliasesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInvalidReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckReferenceValidityPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckArgumentsValidityPass(\false)]]; - $this->beforeRemovingPasses = [-100 => [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolvePrivatesPass()]]; - $this->removingPasses = [[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RemovePrivateAliasesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ReplaceAliasByActualDefinitionPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RemoveAbstractDefinitionsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RemoveUnusedDefinitionsPass()]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveHotPathPass()]]; - } - /** - * Returns all passes in order to be processed. - * - * @return CompilerPassInterface[] - */ - public function getPasses() - { - return \array_merge([$this->mergePass], $this->getBeforeOptimizationPasses(), $this->getOptimizationPasses(), $this->getBeforeRemovingPasses(), $this->getRemovingPasses(), $this->getAfterRemovingPasses()); - } - /** - * Adds a pass. - * - * @param CompilerPassInterface $pass A Compiler pass - * @param string $type The pass type - * - * @throws InvalidArgumentException when a pass type doesn't exist - */ - public function addPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $type = self::TYPE_BEFORE_OPTIMIZATION) - { - if (\func_num_args() >= 3) { - $priority = \func_get_arg(2); - } else { - if (__CLASS__ !== static::class) { - $r = new \ReflectionMethod($this, __FUNCTION__); - if (__CLASS__ !== $r->getDeclaringClass()->getName()) { - @\trigger_error(\sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since Symfony 3.2.', __METHOD__), \E_USER_DEPRECATED); - } - } - $priority = 0; - } - $property = $type . 'Passes'; - if (!isset($this->{$property})) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid type "%s".', $type)); - } - $passes =& $this->{$property}; - if (!isset($passes[$priority])) { - $passes[$priority] = []; - } - $passes[$priority][] = $pass; - } - /** - * Gets all passes for the AfterRemoving pass. - * - * @return CompilerPassInterface[] - */ - public function getAfterRemovingPasses() - { - return $this->sortPasses($this->afterRemovingPasses); - } - /** - * Gets all passes for the BeforeOptimization pass. - * - * @return CompilerPassInterface[] - */ - public function getBeforeOptimizationPasses() - { - return $this->sortPasses($this->beforeOptimizationPasses); - } - /** - * Gets all passes for the BeforeRemoving pass. - * - * @return CompilerPassInterface[] - */ - public function getBeforeRemovingPasses() - { - return $this->sortPasses($this->beforeRemovingPasses); - } - /** - * Gets all passes for the Optimization pass. - * - * @return CompilerPassInterface[] - */ - public function getOptimizationPasses() - { - return $this->sortPasses($this->optimizationPasses); - } - /** - * Gets all passes for the Removing pass. - * - * @return CompilerPassInterface[] - */ - public function getRemovingPasses() - { - return $this->sortPasses($this->removingPasses); - } - /** - * Gets the Merge pass. - * - * @return CompilerPassInterface - */ - public function getMergePass() - { - return $this->mergePass; - } - public function setMergePass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass) - { - $this->mergePass = $pass; - } - /** - * Sets the AfterRemoving passes. - * - * @param CompilerPassInterface[] $passes - */ - public function setAfterRemovingPasses(array $passes) - { - $this->afterRemovingPasses = [$passes]; - } - /** - * Sets the BeforeOptimization passes. - * - * @param CompilerPassInterface[] $passes - */ - public function setBeforeOptimizationPasses(array $passes) - { - $this->beforeOptimizationPasses = [$passes]; - } - /** - * Sets the BeforeRemoving passes. - * - * @param CompilerPassInterface[] $passes - */ - public function setBeforeRemovingPasses(array $passes) - { - $this->beforeRemovingPasses = [$passes]; - } - /** - * Sets the Optimization passes. - * - * @param CompilerPassInterface[] $passes - */ - public function setOptimizationPasses(array $passes) - { - $this->optimizationPasses = [$passes]; - } - /** - * Sets the Removing passes. - * - * @param CompilerPassInterface[] $passes - */ - public function setRemovingPasses(array $passes) - { - $this->removingPasses = [$passes]; - } - /** - * Sort passes by priority. - * - * @param array $passes CompilerPassInterface instances with their priority as key - * - * @return CompilerPassInterface[] - */ - private function sortPasses(array $passes) - { - if (0 === \count($passes)) { - return []; - } - \krsort($passes); - // Flatten the array - return \call_user_func_array('array_merge', $passes); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +/** + * Compiler Pass Configuration. + * + * This class has a default configuration embedded. + * + * @author Johannes M. Schmitt + */ +class PassConfig +{ + const TYPE_AFTER_REMOVING = 'afterRemoving'; + const TYPE_BEFORE_OPTIMIZATION = 'beforeOptimization'; + const TYPE_BEFORE_REMOVING = 'beforeRemoving'; + const TYPE_OPTIMIZE = 'optimization'; + const TYPE_REMOVE = 'removing'; + private $mergePass; + private $afterRemovingPasses = []; + private $beforeOptimizationPasses = []; + private $beforeRemovingPasses = []; + private $optimizationPasses; + private $removingPasses; + public function __construct() + { + $this->mergePass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); + $this->beforeOptimizationPasses = [100 => [$resolveClassPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterEnvVarProcessorsPass()], -1000 => [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ExtensionCompilerPass()]]; + $this->optimizationPasses = [[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DecoratorServicePass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass(\false, \false), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\FactoryReturnTypePass($resolveClassPass), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckDefinitionValidityPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(\false), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveTaggedIteratorArgumentPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveReferencesToAliasesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInvalidReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckReferenceValidityPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckArgumentsValidityPass(\false)]]; + $this->beforeRemovingPasses = [-100 => [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolvePrivatesPass()]]; + $this->removingPasses = [[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RemovePrivateAliasesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ReplaceAliasByActualDefinitionPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RemoveAbstractDefinitionsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RemoveUnusedDefinitionsPass()]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveHotPathPass()]]; + } + /** + * Returns all passes in order to be processed. + * + * @return CompilerPassInterface[] + */ + public function getPasses() + { + return \array_merge([$this->mergePass], $this->getBeforeOptimizationPasses(), $this->getOptimizationPasses(), $this->getBeforeRemovingPasses(), $this->getRemovingPasses(), $this->getAfterRemovingPasses()); + } + /** + * Adds a pass. + * + * @param CompilerPassInterface $pass A Compiler pass + * @param string $type The pass type + * + * @throws InvalidArgumentException when a pass type doesn't exist + */ + public function addPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $type = self::TYPE_BEFORE_OPTIMIZATION) + { + if (\func_num_args() >= 3) { + $priority = \func_get_arg(2); + } else { + if (__CLASS__ !== static::class) { + $r = new \ReflectionMethod($this, __FUNCTION__); + if (__CLASS__ !== $r->getDeclaringClass()->getName()) { + @\trigger_error(\sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since Symfony 3.2.', __METHOD__), \E_USER_DEPRECATED); + } + } + $priority = 0; + } + $property = $type . 'Passes'; + if (!isset($this->{$property})) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid type "%s".', $type)); + } + $passes =& $this->{$property}; + if (!isset($passes[$priority])) { + $passes[$priority] = []; + } + $passes[$priority][] = $pass; + } + /** + * Gets all passes for the AfterRemoving pass. + * + * @return CompilerPassInterface[] + */ + public function getAfterRemovingPasses() + { + return $this->sortPasses($this->afterRemovingPasses); + } + /** + * Gets all passes for the BeforeOptimization pass. + * + * @return CompilerPassInterface[] + */ + public function getBeforeOptimizationPasses() + { + return $this->sortPasses($this->beforeOptimizationPasses); + } + /** + * Gets all passes for the BeforeRemoving pass. + * + * @return CompilerPassInterface[] + */ + public function getBeforeRemovingPasses() + { + return $this->sortPasses($this->beforeRemovingPasses); + } + /** + * Gets all passes for the Optimization pass. + * + * @return CompilerPassInterface[] + */ + public function getOptimizationPasses() + { + return $this->sortPasses($this->optimizationPasses); + } + /** + * Gets all passes for the Removing pass. + * + * @return CompilerPassInterface[] + */ + public function getRemovingPasses() + { + return $this->sortPasses($this->removingPasses); + } + /** + * Gets the Merge pass. + * + * @return CompilerPassInterface + */ + public function getMergePass() + { + return $this->mergePass; + } + public function setMergePass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass) + { + $this->mergePass = $pass; + } + /** + * Sets the AfterRemoving passes. + * + * @param CompilerPassInterface[] $passes + */ + public function setAfterRemovingPasses(array $passes) + { + $this->afterRemovingPasses = [$passes]; + } + /** + * Sets the BeforeOptimization passes. + * + * @param CompilerPassInterface[] $passes + */ + public function setBeforeOptimizationPasses(array $passes) + { + $this->beforeOptimizationPasses = [$passes]; + } + /** + * Sets the BeforeRemoving passes. + * + * @param CompilerPassInterface[] $passes + */ + public function setBeforeRemovingPasses(array $passes) + { + $this->beforeRemovingPasses = [$passes]; + } + /** + * Sets the Optimization passes. + * + * @param CompilerPassInterface[] $passes + */ + public function setOptimizationPasses(array $passes) + { + $this->optimizationPasses = [$passes]; + } + /** + * Sets the Removing passes. + * + * @param CompilerPassInterface[] $passes + */ + public function setRemovingPasses(array $passes) + { + $this->removingPasses = [$passes]; + } + /** + * Sort passes by priority. + * + * @param array $passes CompilerPassInterface instances with their priority as key + * + * @return CompilerPassInterface[] + */ + private function sortPasses(array $passes) + { + if (0 === \count($passes)) { + return []; + } + \krsort($passes); + // Flatten the array + return \call_user_func_array('array_merge', $passes); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/PriorityTaggedServiceTrait.php b/vendor/symfony/dependency-injection/Compiler/PriorityTaggedServiceTrait.php index 6b54d37c0..9ec8bce02 100644 --- a/vendor/symfony/dependency-injection/Compiler/PriorityTaggedServiceTrait.php +++ b/vendor/symfony/dependency-injection/Compiler/PriorityTaggedServiceTrait.php @@ -1,49 +1,49 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Trait that allows a generic method to find and sort service by priority option in the tag. - * - * @author Iltar van der Berg - */ -trait PriorityTaggedServiceTrait -{ - /** - * Finds all services with the given tag name and order them by their priority. - * - * The order of additions must be respected for services having the same priority, - * and knowing that the \SplPriorityQueue class does not respect the FIFO method, - * we should not use that class. - * - * @see https://bugs.php.net/53710 - * @see https://bugs.php.net/60926 - * - * @param string $tagName - * - * @return Reference[] - */ - private function findAndSortTaggedServices($tagName, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $services = []; - foreach ($container->findTaggedServiceIds($tagName, \true) as $serviceId => $attributes) { - $priority = isset($attributes[0]['priority']) ? $attributes[0]['priority'] : 0; - $services[$priority][] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($serviceId); - } - if ($services) { - \krsort($services); - $services = \call_user_func_array('array_merge', $services); - } - return $services; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Trait that allows a generic method to find and sort service by priority option in the tag. + * + * @author Iltar van der Berg + */ +trait PriorityTaggedServiceTrait +{ + /** + * Finds all services with the given tag name and order them by their priority. + * + * The order of additions must be respected for services having the same priority, + * and knowing that the \SplPriorityQueue class does not respect the FIFO method, + * we should not use that class. + * + * @see https://bugs.php.net/53710 + * @see https://bugs.php.net/60926 + * + * @param string $tagName + * + * @return Reference[] + */ + private function findAndSortTaggedServices($tagName, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $services = []; + foreach ($container->findTaggedServiceIds($tagName, \true) as $serviceId => $attributes) { + $priority = isset($attributes[0]['priority']) ? $attributes[0]['priority'] : 0; + $services[$priority][] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($serviceId); + } + if ($services) { + \krsort($services); + $services = \call_user_func_array('array_merge', $services); + } + return $services; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/RegisterEnvVarProcessorsPass.php b/vendor/symfony/dependency-injection/Compiler/RegisterEnvVarProcessorsPass.php index c2cedb424..e7546f855 100644 --- a/vendor/symfony/dependency-injection/Compiler/RegisterEnvVarProcessorsPass.php +++ b/vendor/symfony/dependency-injection/Compiler/RegisterEnvVarProcessorsPass.php @@ -1,67 +1,67 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; -/** - * Creates the container.env_var_processors_locator service. - * - * @author Nicolas Grekas - */ -class RegisterEnvVarProcessorsPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - private static $allowedTypes = ['array', 'bool', 'float', 'int', 'string']; - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $bag = $container->getParameterBag(); - $types = []; - $processors = []; - foreach ($container->findTaggedServiceIds('container.env_var_processor') as $id => $tags) { - if (!($r = $container->getReflectionClass($class = $container->getDefinition($id)->getClass()))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Class "%s" used for service "%s" cannot be found.', $class, $id)); - } elseif (!$r->isSubclassOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface::class)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service "%s" must implement interface "%s".', $id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface::class)); - } - foreach ($class::getProvidedTypes() as $prefix => $type) { - $processors[$prefix] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($id)); - $types[$prefix] = self::validateProvidedTypes($type, $class); - } - } - if ($bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { - foreach (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor::getProvidedTypes() as $prefix => $type) { - if (!isset($types[$prefix])) { - $types[$prefix] = self::validateProvidedTypes($type, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor::class); - } - } - $bag->setProvidedTypes($types); - } - if ($processors) { - $container->register('container.env_var_processors_locator', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\true)->setArguments([$processors]); - } - } - private static function validateProvidedTypes($types, $class) - { - $types = \explode('|', $types); - foreach ($types as $type) { - if (!\in_array($type, self::$allowedTypes)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid type "%s" returned by "%s::getProvidedTypes()", expected one of "%s".', $type, $class, \implode('", "', self::$allowedTypes))); - } - } - return $types; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; +/** + * Creates the container.env_var_processors_locator service. + * + * @author Nicolas Grekas + */ +class RegisterEnvVarProcessorsPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + private static $allowedTypes = ['array', 'bool', 'float', 'int', 'string']; + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $bag = $container->getParameterBag(); + $types = []; + $processors = []; + foreach ($container->findTaggedServiceIds('container.env_var_processor') as $id => $tags) { + if (!($r = $container->getReflectionClass($class = $container->getDefinition($id)->getClass()))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Class "%s" used for service "%s" cannot be found.', $class, $id)); + } elseif (!$r->isSubclassOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface::class)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service "%s" must implement interface "%s".', $id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface::class)); + } + foreach ($class::getProvidedTypes() as $prefix => $type) { + $processors[$prefix] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($id)); + $types[$prefix] = self::validateProvidedTypes($type, $class); + } + } + if ($bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { + foreach (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor::getProvidedTypes() as $prefix => $type) { + if (!isset($types[$prefix])) { + $types[$prefix] = self::validateProvidedTypes($type, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor::class); + } + } + $bag->setProvidedTypes($types); + } + if ($processors) { + $container->register('container.env_var_processors_locator', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\true)->setArguments([$processors]); + } + } + private static function validateProvidedTypes($types, $class) + { + $types = \explode('|', $types); + foreach ($types as $type) { + if (!\in_array($type, self::$allowedTypes)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid type "%s" returned by "%s::getProvidedTypes()", expected one of "%s".', $type, $class, \implode('", "', self::$allowedTypes))); + } + } + return $types; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/RegisterServiceSubscribersPass.php b/vendor/symfony/dependency-injection/Compiler/RegisterServiceSubscribersPass.php index b8f49baeb..7e4186e73 100644 --- a/vendor/symfony/dependency-injection/Compiler/RegisterServiceSubscribersPass.php +++ b/vendor/symfony/dependency-injection/Compiler/RegisterServiceSubscribersPass.php @@ -1,90 +1,90 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; -/** - * Compiler pass to register tagged services that require a service locator. - * - * @author Nicolas Grekas - */ -class RegisterServiceSubscribersPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - protected function processValue($value, $isRoot = \false) - { - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || $value->isAbstract() || $value->isSynthetic() || !$value->hasTag('container.service_subscriber')) { - return parent::processValue($value, $isRoot); - } - $serviceMap = []; - $autowire = $value->isAutowired(); - foreach ($value->getTag('container.service_subscriber') as $attributes) { - if (!$attributes) { - $autowire = \true; - continue; - } - \ksort($attributes); - if ([] !== \array_diff(\array_keys($attributes), ['id', 'key'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The "container.service_subscriber" tag accepts only the "key" and "id" attributes, "%s" given for service "%s".', \implode('", "', \array_keys($attributes)), $this->currentId)); - } - if (!\array_key_exists('id', $attributes)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Missing "id" attribute on "container.service_subscriber" tag with key="%s" for service "%s".', $attributes['key'], $this->currentId)); - } - if (!\array_key_exists('key', $attributes)) { - $attributes['key'] = $attributes['id']; - } - if (isset($serviceMap[$attributes['key']])) { - continue; - } - $serviceMap[$attributes['key']] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($attributes['id']); - } - $class = $value->getClass(); - if (!($r = $this->container->getReflectionClass($class))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Class "%s" used for service "%s" cannot be found.', $class, $this->currentId)); - } - if (!$r->isSubclassOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service "%s" must implement interface "%s".', $this->currentId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class)); - } - $class = $r->name; - $subscriberMap = []; - $declaringClass = (new \ReflectionMethod($class, 'getSubscribedServices'))->class; - foreach ($class::getSubscribedServices() as $key => $type) { - if (!\is_string($type) || !\preg_match('/^\\??[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+(?:\\\\[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+)*+$/', $type)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"%s::getSubscribedServices()" must return valid PHP types for service "%s" key "%s", "%s" returned.', $class, $this->currentId, $key, \is_string($type) ? $type : \gettype($type))); - } - if ($optionalBehavior = '?' === $type[0]) { - $type = \substr($type, 1); - $optionalBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE; - } - if (\is_int($key)) { - $key = $type; - } - if (!isset($serviceMap[$key])) { - if (!$autowire) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service "%s" misses a "container.service_subscriber" tag with "key"/"id" attributes corresponding to entry "%s" as returned by "%s::getSubscribedServices()".', $this->currentId, $key, $class)); - } - $serviceMap[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($type); - } - $subscriberMap[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($this->container->normalizeId($serviceMap[$key]), $type, $declaringClass, $optionalBehavior ?: \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE); - unset($serviceMap[$key]); - } - if ($serviceMap = \array_keys($serviceMap)) { - $message = \sprintf(1 < \count($serviceMap) ? 'keys "%s" do' : 'key "%s" does', \str_replace('%', '%%', \implode('", "', $serviceMap))); - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service %s not exist in the map returned by "%s::getSubscribedServices()" for service "%s".', $message, $class, $this->currentId)); - } - $value->addTag('container.service_subscriber.locator', ['id' => (string) \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass::register($this->container, $subscriberMap, $this->currentId)]); - return parent::processValue($value); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; +/** + * Compiler pass to register tagged services that require a service locator. + * + * @author Nicolas Grekas + */ +class RegisterServiceSubscribersPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + protected function processValue($value, $isRoot = \false) + { + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || $value->isAbstract() || $value->isSynthetic() || !$value->hasTag('container.service_subscriber')) { + return parent::processValue($value, $isRoot); + } + $serviceMap = []; + $autowire = $value->isAutowired(); + foreach ($value->getTag('container.service_subscriber') as $attributes) { + if (!$attributes) { + $autowire = \true; + continue; + } + \ksort($attributes); + if ([] !== \array_diff(\array_keys($attributes), ['id', 'key'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The "container.service_subscriber" tag accepts only the "key" and "id" attributes, "%s" given for service "%s".', \implode('", "', \array_keys($attributes)), $this->currentId)); + } + if (!\array_key_exists('id', $attributes)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Missing "id" attribute on "container.service_subscriber" tag with key="%s" for service "%s".', $attributes['key'], $this->currentId)); + } + if (!\array_key_exists('key', $attributes)) { + $attributes['key'] = $attributes['id']; + } + if (isset($serviceMap[$attributes['key']])) { + continue; + } + $serviceMap[$attributes['key']] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($attributes['id']); + } + $class = $value->getClass(); + if (!($r = $this->container->getReflectionClass($class))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Class "%s" used for service "%s" cannot be found.', $class, $this->currentId)); + } + if (!$r->isSubclassOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service "%s" must implement interface "%s".', $this->currentId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class)); + } + $class = $r->name; + $subscriberMap = []; + $declaringClass = (new \ReflectionMethod($class, 'getSubscribedServices'))->class; + foreach ($class::getSubscribedServices() as $key => $type) { + if (!\is_string($type) || !\preg_match('/^\\??[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+(?:\\\\[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+)*+$/', $type)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"%s::getSubscribedServices()" must return valid PHP types for service "%s" key "%s", "%s" returned.', $class, $this->currentId, $key, \is_string($type) ? $type : \gettype($type))); + } + if ($optionalBehavior = '?' === $type[0]) { + $type = \substr($type, 1); + $optionalBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE; + } + if (\is_int($key)) { + $key = $type; + } + if (!isset($serviceMap[$key])) { + if (!$autowire) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service "%s" misses a "container.service_subscriber" tag with "key"/"id" attributes corresponding to entry "%s" as returned by "%s::getSubscribedServices()".', $this->currentId, $key, $class)); + } + $serviceMap[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($type); + } + $subscriberMap[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference($this->container->normalizeId($serviceMap[$key]), $type, $declaringClass, $optionalBehavior ?: \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE); + unset($serviceMap[$key]); + } + if ($serviceMap = \array_keys($serviceMap)) { + $message = \sprintf(1 < \count($serviceMap) ? 'keys "%s" do' : 'key "%s" does', \str_replace('%', '%%', \implode('", "', $serviceMap))); + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service %s not exist in the map returned by "%s::getSubscribedServices()" for service "%s".', $message, $class, $this->currentId)); + } + $value->addTag('container.service_subscriber.locator', ['id' => (string) \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass::register($this->container, $subscriberMap, $this->currentId)]); + return parent::processValue($value); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/RemoveAbstractDefinitionsPass.php b/vendor/symfony/dependency-injection/Compiler/RemoveAbstractDefinitionsPass.php index ff8f85db2..22915970c 100644 --- a/vendor/symfony/dependency-injection/Compiler/RemoveAbstractDefinitionsPass.php +++ b/vendor/symfony/dependency-injection/Compiler/RemoveAbstractDefinitionsPass.php @@ -1,31 +1,31 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * Removes abstract Definitions. - */ -class RemoveAbstractDefinitionsPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - /** - * Removes abstract definitions from the ContainerBuilder. - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - foreach ($container->getDefinitions() as $id => $definition) { - if ($definition->isAbstract()) { - $container->removeDefinition($id); - $container->log($this, \sprintf('Removed service "%s"; reason: abstract.', $id)); - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * Removes abstract Definitions. + */ +class RemoveAbstractDefinitionsPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + /** + * Removes abstract definitions from the ContainerBuilder. + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + foreach ($container->getDefinitions() as $id => $definition) { + if ($definition->isAbstract()) { + $container->removeDefinition($id); + $container->log($this, \sprintf('Removed service "%s"; reason: abstract.', $id)); + } + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/RemovePrivateAliasesPass.php b/vendor/symfony/dependency-injection/Compiler/RemovePrivateAliasesPass.php index 0c6295a8a..8aeb8b19c 100644 --- a/vendor/symfony/dependency-injection/Compiler/RemovePrivateAliasesPass.php +++ b/vendor/symfony/dependency-injection/Compiler/RemovePrivateAliasesPass.php @@ -1,36 +1,36 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * Remove private aliases from the container. They were only used to establish - * dependencies between services, and these dependencies have been resolved in - * one of the previous passes. - * - * @author Johannes M. Schmitt - */ -class RemovePrivateAliasesPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - /** - * Removes private aliases from the ContainerBuilder. - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - foreach ($container->getAliases() as $id => $alias) { - if ($alias->isPublic() || $alias->isPrivate()) { - continue; - } - $container->removeAlias($id); - $container->log($this, \sprintf('Removed service "%s"; reason: private alias.', $id)); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * Remove private aliases from the container. They were only used to establish + * dependencies between services, and these dependencies have been resolved in + * one of the previous passes. + * + * @author Johannes M. Schmitt + */ +class RemovePrivateAliasesPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + /** + * Removes private aliases from the ContainerBuilder. + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + foreach ($container->getAliases() as $id => $alias) { + if ($alias->isPublic() || $alias->isPrivate()) { + continue; + } + $container->removeAlias($id); + $container->log($this, \sprintf('Removed service "%s"; reason: private alias.', $id)); + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/RemoveUnusedDefinitionsPass.php b/vendor/symfony/dependency-injection/Compiler/RemoveUnusedDefinitionsPass.php index 827c553f6..b17143009 100644 --- a/vendor/symfony/dependency-injection/Compiler/RemoveUnusedDefinitionsPass.php +++ b/vendor/symfony/dependency-injection/Compiler/RemoveUnusedDefinitionsPass.php @@ -1,76 +1,76 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * Removes unused service definitions from the container. - * - * @author Johannes M. Schmitt - */ -class RemoveUnusedDefinitionsPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatablePassInterface -{ - private $repeatedPass; - /** - * {@inheritdoc} - */ - public function setRepeatedPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass $repeatedPass) - { - $this->repeatedPass = $repeatedPass; - } - /** - * Processes the ContainerBuilder to remove unused definitions. - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $graph = $container->getCompiler()->getServiceReferenceGraph(); - $hasChanged = \false; - foreach ($container->getDefinitions() as $id => $definition) { - if ($definition->isPublic() || $definition->isPrivate()) { - continue; - } - if ($graph->hasNode($id)) { - $edges = $graph->getNode($id)->getInEdges(); - $referencingAliases = []; - $sourceIds = []; - foreach ($edges as $edge) { - if ($edge->isWeak()) { - continue; - } - $node = $edge->getSourceNode(); - $sourceIds[] = $node->getId(); - if ($node->isAlias()) { - $referencingAliases[] = $node->getValue(); - } - } - $isReferenced = \count(\array_unique($sourceIds)) - \count($referencingAliases) > 0; - } else { - $referencingAliases = []; - $isReferenced = \false; - } - if (1 === \count($referencingAliases) && \false === $isReferenced) { - $container->setDefinition((string) \reset($referencingAliases), $definition); - $definition->setPublic(!$definition->isPrivate()); - $definition->setPrivate(\reset($referencingAliases)->isPrivate()); - $container->removeDefinition($id); - $container->log($this, \sprintf('Removed service "%s"; reason: replaces alias %s.', $id, \reset($referencingAliases))); - } elseif (0 === \count($referencingAliases) && \false === $isReferenced) { - $container->removeDefinition($id); - $container->resolveEnvPlaceholders(\serialize($definition)); - $container->log($this, \sprintf('Removed service "%s"; reason: unused.', $id)); - $hasChanged = \true; - } - } - if ($hasChanged) { - $this->repeatedPass->setRepeat(); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * Removes unused service definitions from the container. + * + * @author Johannes M. Schmitt + */ +class RemoveUnusedDefinitionsPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatablePassInterface +{ + private $repeatedPass; + /** + * {@inheritdoc} + */ + public function setRepeatedPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass $repeatedPass) + { + $this->repeatedPass = $repeatedPass; + } + /** + * Processes the ContainerBuilder to remove unused definitions. + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $graph = $container->getCompiler()->getServiceReferenceGraph(); + $hasChanged = \false; + foreach ($container->getDefinitions() as $id => $definition) { + if ($definition->isPublic() || $definition->isPrivate()) { + continue; + } + if ($graph->hasNode($id)) { + $edges = $graph->getNode($id)->getInEdges(); + $referencingAliases = []; + $sourceIds = []; + foreach ($edges as $edge) { + if ($edge->isWeak()) { + continue; + } + $node = $edge->getSourceNode(); + $sourceIds[] = $node->getId(); + if ($node->isAlias()) { + $referencingAliases[] = $node->getValue(); + } + } + $isReferenced = \count(\array_unique($sourceIds)) - \count($referencingAliases) > 0; + } else { + $referencingAliases = []; + $isReferenced = \false; + } + if (1 === \count($referencingAliases) && \false === $isReferenced) { + $container->setDefinition((string) \reset($referencingAliases), $definition); + $definition->setPublic(!$definition->isPrivate()); + $definition->setPrivate(\reset($referencingAliases)->isPrivate()); + $container->removeDefinition($id); + $container->log($this, \sprintf('Removed service "%s"; reason: replaces alias %s.', $id, \reset($referencingAliases))); + } elseif (0 === \count($referencingAliases) && \false === $isReferenced) { + $container->removeDefinition($id); + $container->resolveEnvPlaceholders(\serialize($definition)); + $container->log($this, \sprintf('Removed service "%s"; reason: unused.', $id)); + $hasChanged = \true; + } + } + if ($hasChanged) { + $this->repeatedPass->setRepeat(); + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/RepeatablePassInterface.php b/vendor/symfony/dependency-injection/Compiler/RepeatablePassInterface.php index ed09d059d..90187dc64 100644 --- a/vendor/symfony/dependency-injection/Compiler/RepeatablePassInterface.php +++ b/vendor/symfony/dependency-injection/Compiler/RepeatablePassInterface.php @@ -1,22 +1,22 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -/** - * Interface that must be implemented by passes that are run as part of an - * RepeatedPass. - * - * @author Johannes M. Schmitt - */ -interface RepeatablePassInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - public function setRepeatedPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass $repeatedPass); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +/** + * Interface that must be implemented by passes that are run as part of an + * RepeatedPass. + * + * @author Johannes M. Schmitt + */ +interface RepeatablePassInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + public function setRepeatedPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass $repeatedPass); +} diff --git a/vendor/symfony/dependency-injection/Compiler/RepeatedPass.php b/vendor/symfony/dependency-injection/Compiler/RepeatedPass.php index 8968bccce..d6d4cb434 100644 --- a/vendor/symfony/dependency-injection/Compiler/RepeatedPass.php +++ b/vendor/symfony/dependency-injection/Compiler/RepeatedPass.php @@ -1,70 +1,70 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -/** - * A pass that might be run repeatedly. - * - * @author Johannes M. Schmitt - */ -class RepeatedPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - /** - * @var bool - */ - private $repeat = \false; - private $passes; - /** - * @param RepeatablePassInterface[] $passes An array of RepeatablePassInterface objects - * - * @throws InvalidArgumentException when the passes don't implement RepeatablePassInterface - */ - public function __construct(array $passes) - { - foreach ($passes as $pass) { - if (!$pass instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatablePassInterface) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('$passes must be an array of RepeatablePassInterface.'); - } - $pass->setRepeatedPass($this); - } - $this->passes = $passes; - } - /** - * Process the repeatable passes that run more than once. - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - do { - $this->repeat = \false; - foreach ($this->passes as $pass) { - $pass->process($container); - } - } while ($this->repeat); - } - /** - * Sets if the pass should repeat. - */ - public function setRepeat() - { - $this->repeat = \true; - } - /** - * Returns the passes. - * - * @return RepeatablePassInterface[] An array of RepeatablePassInterface objects - */ - public function getPasses() - { - return $this->passes; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +/** + * A pass that might be run repeatedly. + * + * @author Johannes M. Schmitt + */ +class RepeatedPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + /** + * @var bool + */ + private $repeat = \false; + private $passes; + /** + * @param RepeatablePassInterface[] $passes An array of RepeatablePassInterface objects + * + * @throws InvalidArgumentException when the passes don't implement RepeatablePassInterface + */ + public function __construct(array $passes) + { + foreach ($passes as $pass) { + if (!$pass instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatablePassInterface) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('$passes must be an array of RepeatablePassInterface.'); + } + $pass->setRepeatedPass($this); + } + $this->passes = $passes; + } + /** + * Process the repeatable passes that run more than once. + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + do { + $this->repeat = \false; + foreach ($this->passes as $pass) { + $pass->process($container); + } + } while ($this->repeat); + } + /** + * Sets if the pass should repeat. + */ + public function setRepeat() + { + $this->repeat = \true; + } + /** + * Returns the passes. + * + * @return RepeatablePassInterface[] An array of RepeatablePassInterface objects + */ + public function getPasses() + { + return $this->passes; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ReplaceAliasByActualDefinitionPass.php b/vendor/symfony/dependency-injection/Compiler/ReplaceAliasByActualDefinitionPass.php index fe89f5c42..3ac0ba13c 100644 --- a/vendor/symfony/dependency-injection/Compiler/ReplaceAliasByActualDefinitionPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ReplaceAliasByActualDefinitionPass.php @@ -1,83 +1,83 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Replaces aliases with actual service definitions, effectively removing these - * aliases. - * - * @author Johannes M. Schmitt - */ -class ReplaceAliasByActualDefinitionPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - private $replacements; - /** - * Process the Container to replace aliases with service definitions. - * - * @throws InvalidArgumentException if the service definition does not exist - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - // First collect all alias targets that need to be replaced - $seenAliasTargets = []; - $replacements = []; - foreach ($container->getAliases() as $definitionId => $target) { - $targetId = $container->normalizeId($target); - // Special case: leave this target alone - if ('service_container' === $targetId) { - continue; - } - // Check if target needs to be replaces - if (isset($replacements[$targetId])) { - $container->setAlias($definitionId, $replacements[$targetId])->setPublic($target->isPublic())->setPrivate($target->isPrivate()); - } - // No need to process the same target twice - if (isset($seenAliasTargets[$targetId])) { - continue; - } - // Process new target - $seenAliasTargets[$targetId] = \true; - try { - $definition = $container->getDefinition($targetId); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Unable to replace alias "%s" with actual definition "%s".', $definitionId, $targetId), null, $e); - } - if ($definition->isPublic() || $definition->isPrivate()) { - continue; - } - // Remove private definition and schedule for replacement - $definition->setPublic(!$target->isPrivate()); - $definition->setPrivate($target->isPrivate()); - $container->setDefinition($definitionId, $definition); - $container->removeDefinition($targetId); - $replacements[$targetId] = $definitionId; - } - $this->replacements = $replacements; - parent::process($container); - $this->replacements = []; - } - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && isset($this->replacements[$referenceId = $this->container->normalizeId($value)])) { - // Perform the replacement - $newId = $this->replacements[$referenceId]; - $value = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($newId, $value->getInvalidBehavior()); - $this->container->log($this, \sprintf('Changed reference of service "%s" previously pointing to "%s" to "%s".', $this->currentId, $referenceId, $newId)); - } - return parent::processValue($value, $isRoot); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Replaces aliases with actual service definitions, effectively removing these + * aliases. + * + * @author Johannes M. Schmitt + */ +class ReplaceAliasByActualDefinitionPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + private $replacements; + /** + * Process the Container to replace aliases with service definitions. + * + * @throws InvalidArgumentException if the service definition does not exist + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + // First collect all alias targets that need to be replaced + $seenAliasTargets = []; + $replacements = []; + foreach ($container->getAliases() as $definitionId => $target) { + $targetId = $container->normalizeId($target); + // Special case: leave this target alone + if ('service_container' === $targetId) { + continue; + } + // Check if target needs to be replaces + if (isset($replacements[$targetId])) { + $container->setAlias($definitionId, $replacements[$targetId])->setPublic($target->isPublic())->setPrivate($target->isPrivate()); + } + // No need to process the same target twice + if (isset($seenAliasTargets[$targetId])) { + continue; + } + // Process new target + $seenAliasTargets[$targetId] = \true; + try { + $definition = $container->getDefinition($targetId); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Unable to replace alias "%s" with actual definition "%s".', $definitionId, $targetId), null, $e); + } + if ($definition->isPublic() || $definition->isPrivate()) { + continue; + } + // Remove private definition and schedule for replacement + $definition->setPublic(!$target->isPrivate()); + $definition->setPrivate($target->isPrivate()); + $container->setDefinition($definitionId, $definition); + $container->removeDefinition($targetId); + $replacements[$targetId] = $definitionId; + } + $this->replacements = $replacements; + parent::process($container); + $this->replacements = []; + } + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && isset($this->replacements[$referenceId = $this->container->normalizeId($value)])) { + // Perform the replacement + $newId = $this->replacements[$referenceId]; + $value = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($newId, $value->getInvalidBehavior()); + $this->container->log($this, \sprintf('Changed reference of service "%s" previously pointing to "%s" to "%s".', $this->currentId, $referenceId, $newId)); + } + return parent::processValue($value, $isRoot); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveBindingsPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveBindingsPass.php index 025d082cb..c6aee00b0 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveBindingsPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveBindingsPass.php @@ -1,148 +1,148 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; -/** - * @author Guilhem Niot - */ -class ResolveBindingsPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - private $usedBindings = []; - private $unusedBindings = []; - private $errorMessages = []; - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $this->usedBindings = $container->getRemovedBindingIds(); - try { - parent::process($container); - foreach ($this->unusedBindings as list($key, $serviceId)) { - $message = \sprintf('Unused binding "%s" in service "%s".', $key, $serviceId); - if ($this->errorMessages) { - $message .= \sprintf("\nCould be related to%s:", 1 < \count($this->errorMessages) ? ' one of' : ''); - } - foreach ($this->errorMessages as $m) { - $message .= "\n - " . $m; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException($message); - } - } finally { - $this->usedBindings = []; - $this->unusedBindings = []; - $this->errorMessages = []; - } - } - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference && $value->getType() === $this->container->normalizeId($value)) { - // Already checked - $bindings = $this->container->getDefinition($this->currentId)->getBindings(); - if (isset($bindings[$value->getType()])) { - return $this->getBindingValue($bindings[$value->getType()]); - } - return parent::processValue($value, $isRoot); - } - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || !($bindings = $value->getBindings())) { - return parent::processValue($value, $isRoot); - } - foreach ($bindings as $key => $binding) { - list($bindingValue, $bindingId, $used) = $binding->getValues(); - if ($used) { - $this->usedBindings[$bindingId] = \true; - unset($this->unusedBindings[$bindingId]); - } elseif (!isset($this->usedBindings[$bindingId])) { - $this->unusedBindings[$bindingId] = [$key, $this->currentId]; - } - if (isset($key[0]) && '$' === $key[0]) { - continue; - } - if (null !== $bindingValue && !$bindingValue instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && !$bindingValue instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid value for binding key "%s" for service "%s": expected null, an instance of "%s" or an instance of "%s", "%s" given.', $key, $this->currentId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition::class, \gettype($bindingValue))); - } - } - if ($value->isAbstract()) { - return parent::processValue($value, $isRoot); - } - $calls = $value->getMethodCalls(); - try { - if ($constructor = $this->getConstructor($value, \false)) { - $calls[] = [$constructor, $value->getArguments()]; - } - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { - $this->errorMessages[] = $e->getMessage(); - $this->container->getDefinition($this->currentId)->addError($e->getMessage()); - return parent::processValue($value, $isRoot); - } - foreach ($calls as $i => $call) { - list($method, $arguments) = $call; - if ($method instanceof \ReflectionFunctionAbstract) { - $reflectionMethod = $method; - } else { - try { - $reflectionMethod = $this->getReflectionMethod($value, $method); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { - if ($value->getFactory()) { - continue; - } - throw $e; - } - } - foreach ($reflectionMethod->getParameters() as $key => $parameter) { - if (\array_key_exists($key, $arguments) && '' !== $arguments[$key]) { - continue; - } - if (\array_key_exists('$' . $parameter->name, $bindings)) { - $arguments[$key] = $this->getBindingValue($bindings['$' . $parameter->name]); - continue; - } - $typeHint = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper::getTypeHint($reflectionMethod, $parameter, \true); - if (!isset($bindings[$typeHint])) { - continue; - } - $arguments[$key] = $this->getBindingValue($bindings[$typeHint]); - } - if ($arguments !== $call[1]) { - \ksort($arguments); - $calls[$i][1] = $arguments; - } - } - if ($constructor) { - list(, $arguments) = \array_pop($calls); - if ($arguments !== $value->getArguments()) { - $value->setArguments($arguments); - } - } - if ($calls !== $value->getMethodCalls()) { - $value->setMethodCalls($calls); - } - return parent::processValue($value, $isRoot); - } - private function getBindingValue(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument $binding) - { - list($bindingValue, $bindingId) = $binding->getValues(); - $this->usedBindings[$bindingId] = \true; - unset($this->unusedBindings[$bindingId]); - return $bindingValue; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; +/** + * @author Guilhem Niot + */ +class ResolveBindingsPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + private $usedBindings = []; + private $unusedBindings = []; + private $errorMessages = []; + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $this->usedBindings = $container->getRemovedBindingIds(); + try { + parent::process($container); + foreach ($this->unusedBindings as list($key, $serviceId)) { + $message = \sprintf('Unused binding "%s" in service "%s".', $key, $serviceId); + if ($this->errorMessages) { + $message .= \sprintf("\nCould be related to%s:", 1 < \count($this->errorMessages) ? ' one of' : ''); + } + foreach ($this->errorMessages as $m) { + $message .= "\n - " . $m; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException($message); + } + } finally { + $this->usedBindings = []; + $this->unusedBindings = []; + $this->errorMessages = []; + } + } + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference && $value->getType() === $this->container->normalizeId($value)) { + // Already checked + $bindings = $this->container->getDefinition($this->currentId)->getBindings(); + if (isset($bindings[$value->getType()])) { + return $this->getBindingValue($bindings[$value->getType()]); + } + return parent::processValue($value, $isRoot); + } + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || !($bindings = $value->getBindings())) { + return parent::processValue($value, $isRoot); + } + foreach ($bindings as $key => $binding) { + list($bindingValue, $bindingId, $used) = $binding->getValues(); + if ($used) { + $this->usedBindings[$bindingId] = \true; + unset($this->unusedBindings[$bindingId]); + } elseif (!isset($this->usedBindings[$bindingId])) { + $this->unusedBindings[$bindingId] = [$key, $this->currentId]; + } + if (isset($key[0]) && '$' === $key[0]) { + continue; + } + if (null !== $bindingValue && !$bindingValue instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && !$bindingValue instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid value for binding key "%s" for service "%s": expected null, an instance of "%s" or an instance of "%s", "%s" given.', $key, $this->currentId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition::class, \gettype($bindingValue))); + } + } + if ($value->isAbstract()) { + return parent::processValue($value, $isRoot); + } + $calls = $value->getMethodCalls(); + try { + if ($constructor = $this->getConstructor($value, \false)) { + $calls[] = [$constructor, $value->getArguments()]; + } + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { + $this->errorMessages[] = $e->getMessage(); + $this->container->getDefinition($this->currentId)->addError($e->getMessage()); + return parent::processValue($value, $isRoot); + } + foreach ($calls as $i => $call) { + list($method, $arguments) = $call; + if ($method instanceof \ReflectionFunctionAbstract) { + $reflectionMethod = $method; + } else { + try { + $reflectionMethod = $this->getReflectionMethod($value, $method); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { + if ($value->getFactory()) { + continue; + } + throw $e; + } + } + foreach ($reflectionMethod->getParameters() as $key => $parameter) { + if (\array_key_exists($key, $arguments) && '' !== $arguments[$key]) { + continue; + } + if (\array_key_exists('$' . $parameter->name, $bindings)) { + $arguments[$key] = $this->getBindingValue($bindings['$' . $parameter->name]); + continue; + } + $typeHint = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper::getTypeHint($reflectionMethod, $parameter, \true); + if (!isset($bindings[$typeHint])) { + continue; + } + $arguments[$key] = $this->getBindingValue($bindings[$typeHint]); + } + if ($arguments !== $call[1]) { + \ksort($arguments); + $calls[$i][1] = $arguments; + } + } + if ($constructor) { + list(, $arguments) = \array_pop($calls); + if ($arguments !== $value->getArguments()) { + $value->setArguments($arguments); + } + } + if ($calls !== $value->getMethodCalls()) { + $value->setMethodCalls($calls); + } + return parent::processValue($value, $isRoot); + } + private function getBindingValue(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument $binding) + { + list($bindingValue, $bindingId) = $binding->getValues(); + $this->usedBindings[$bindingId] = \true; + unset($this->unusedBindings[$bindingId]); + return $bindingValue; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveChildDefinitionsPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveChildDefinitionsPass.php index 298d25af7..a17c7d7a5 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveChildDefinitionsPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveChildDefinitionsPass.php @@ -1,177 +1,177 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; -/** - * This replaces all ChildDefinition instances with their equivalent fully - * merged Definition instance. - * - * @author Johannes M. Schmitt - * @author Nicolas Grekas - */ -class ResolveChildDefinitionsPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - private $currentPath; - protected function processValue($value, $isRoot = \false) - { - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - return parent::processValue($value, $isRoot); - } - if ($isRoot) { - // yes, we are specifically fetching the definition from the - // container to ensure we are not operating on stale data - $value = $this->container->getDefinition($this->currentId); - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { - $this->currentPath = []; - $value = $this->resolveDefinition($value); - if ($isRoot) { - $this->container->setDefinition($this->currentId, $value); - } - } - return parent::processValue($value, $isRoot); - } - /** - * Resolves the definition. - * - * @return Definition - * - * @throws RuntimeException When the definition is invalid - */ - private function resolveDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition $definition) - { - try { - return $this->doResolveDefinition($definition); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException $e) { - throw $e; - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface $e) { - $r = new \ReflectionProperty($e, 'message'); - $r->setAccessible(\true); - $r->setValue($e, \sprintf('Service "%s": %s', $this->currentId, $e->getMessage())); - throw $e; - } - } - private function doResolveDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition $definition) - { - if (!$this->container->has($parent = $definition->getParent())) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Parent definition "%s" does not exist.', $parent)); - } - $searchKey = \array_search($parent, $this->currentPath); - $this->currentPath[] = $parent; - if (\false !== $searchKey) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($parent, \array_slice($this->currentPath, $searchKey)); - } - $parentDef = $this->container->findDefinition($parent); - if ($parentDef instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { - $id = $this->currentId; - $this->currentId = $parent; - $parentDef = $this->resolveDefinition($parentDef); - $this->container->setDefinition($parent, $parentDef); - $this->currentId = $id; - } - $this->container->log($this, \sprintf('Resolving inheritance for "%s" (parent: %s).', $this->currentId, $parent)); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - // merge in parent definition - // purposely ignored attributes: abstract, shared, tags, autoconfigured - $def->setClass($parentDef->getClass()); - $def->setArguments($parentDef->getArguments()); - $def->setMethodCalls($parentDef->getMethodCalls()); - $def->setProperties($parentDef->getProperties()); - if ($parentDef->getAutowiringTypes(\false)) { - $def->setAutowiringTypes($parentDef->getAutowiringTypes(\false)); - } - if ($parentDef->isDeprecated()) { - $def->setDeprecated(\true, $parentDef->getDeprecationMessage('%service_id%')); - } - $def->setFactory($parentDef->getFactory()); - $def->setConfigurator($parentDef->getConfigurator()); - $def->setFile($parentDef->getFile()); - $def->setPublic($parentDef->isPublic()); - $def->setLazy($parentDef->isLazy()); - $def->setAutowired($parentDef->isAutowired()); - $def->setChanges($parentDef->getChanges()); - $def->setBindings($definition->getBindings() + $parentDef->getBindings()); - // overwrite with values specified in the decorator - $changes = $definition->getChanges(); - if (isset($changes['class'])) { - $def->setClass($definition->getClass()); - } - if (isset($changes['factory'])) { - $def->setFactory($definition->getFactory()); - } - if (isset($changes['configurator'])) { - $def->setConfigurator($definition->getConfigurator()); - } - if (isset($changes['file'])) { - $def->setFile($definition->getFile()); - } - if (isset($changes['public'])) { - $def->setPublic($definition->isPublic()); - } else { - $def->setPrivate($definition->isPrivate() || $parentDef->isPrivate()); - } - if (isset($changes['lazy'])) { - $def->setLazy($definition->isLazy()); - } - if (isset($changes['deprecated'])) { - $def->setDeprecated($definition->isDeprecated(), $definition->getDeprecationMessage('%service_id%')); - } - if (isset($changes['autowired'])) { - $def->setAutowired($definition->isAutowired()); - } - if (isset($changes['shared'])) { - $def->setShared($definition->isShared()); - } - if (isset($changes['decorated_service'])) { - $decoratedService = $definition->getDecoratedService(); - if (null === $decoratedService) { - $def->setDecoratedService($decoratedService); - } else { - $def->setDecoratedService($decoratedService[0], $decoratedService[1], $decoratedService[2]); - } - } - // merge arguments - foreach ($definition->getArguments() as $k => $v) { - if (\is_numeric($k)) { - $def->addArgument($v); - } elseif (0 === \strpos($k, 'index_')) { - $def->replaceArgument((int) \substr($k, \strlen('index_')), $v); - } else { - $def->setArgument($k, $v); - } - } - // merge properties - foreach ($definition->getProperties() as $k => $v) { - $def->setProperty($k, $v); - } - // append method calls - if ($calls = $definition->getMethodCalls()) { - $def->setMethodCalls(\array_merge($def->getMethodCalls(), $calls)); - } - // merge autowiring types - foreach ($definition->getAutowiringTypes(\false) as $autowiringType) { - $def->addAutowiringType($autowiringType); - } - // these attributes are always taken from the child - $def->setAbstract($definition->isAbstract()); - $def->setTags($definition->getTags()); - // autoconfigure is never taken from parent (on purpose) - // and it's not legal on an instanceof - $def->setAutoconfigured($definition->isAutoconfigured()); - return $def; - } -} -\class_alias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass::class); + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; +/** + * This replaces all ChildDefinition instances with their equivalent fully + * merged Definition instance. + * + * @author Johannes M. Schmitt + * @author Nicolas Grekas + */ +class ResolveChildDefinitionsPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + private $currentPath; + protected function processValue($value, $isRoot = \false) + { + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + return parent::processValue($value, $isRoot); + } + if ($isRoot) { + // yes, we are specifically fetching the definition from the + // container to ensure we are not operating on stale data + $value = $this->container->getDefinition($this->currentId); + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { + $this->currentPath = []; + $value = $this->resolveDefinition($value); + if ($isRoot) { + $this->container->setDefinition($this->currentId, $value); + } + } + return parent::processValue($value, $isRoot); + } + /** + * Resolves the definition. + * + * @return Definition + * + * @throws RuntimeException When the definition is invalid + */ + private function resolveDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition $definition) + { + try { + return $this->doResolveDefinition($definition); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException $e) { + throw $e; + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface $e) { + $r = new \ReflectionProperty($e, 'message'); + $r->setAccessible(\true); + $r->setValue($e, \sprintf('Service "%s": %s', $this->currentId, $e->getMessage())); + throw $e; + } + } + private function doResolveDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition $definition) + { + if (!$this->container->has($parent = $definition->getParent())) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Parent definition "%s" does not exist.', $parent)); + } + $searchKey = \array_search($parent, $this->currentPath); + $this->currentPath[] = $parent; + if (\false !== $searchKey) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($parent, \array_slice($this->currentPath, $searchKey)); + } + $parentDef = $this->container->findDefinition($parent); + if ($parentDef instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { + $id = $this->currentId; + $this->currentId = $parent; + $parentDef = $this->resolveDefinition($parentDef); + $this->container->setDefinition($parent, $parentDef); + $this->currentId = $id; + } + $this->container->log($this, \sprintf('Resolving inheritance for "%s" (parent: %s).', $this->currentId, $parent)); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + // merge in parent definition + // purposely ignored attributes: abstract, shared, tags, autoconfigured + $def->setClass($parentDef->getClass()); + $def->setArguments($parentDef->getArguments()); + $def->setMethodCalls($parentDef->getMethodCalls()); + $def->setProperties($parentDef->getProperties()); + if ($parentDef->getAutowiringTypes(\false)) { + $def->setAutowiringTypes($parentDef->getAutowiringTypes(\false)); + } + if ($parentDef->isDeprecated()) { + $def->setDeprecated(\true, $parentDef->getDeprecationMessage('%service_id%')); + } + $def->setFactory($parentDef->getFactory()); + $def->setConfigurator($parentDef->getConfigurator()); + $def->setFile($parentDef->getFile()); + $def->setPublic($parentDef->isPublic()); + $def->setLazy($parentDef->isLazy()); + $def->setAutowired($parentDef->isAutowired()); + $def->setChanges($parentDef->getChanges()); + $def->setBindings($definition->getBindings() + $parentDef->getBindings()); + // overwrite with values specified in the decorator + $changes = $definition->getChanges(); + if (isset($changes['class'])) { + $def->setClass($definition->getClass()); + } + if (isset($changes['factory'])) { + $def->setFactory($definition->getFactory()); + } + if (isset($changes['configurator'])) { + $def->setConfigurator($definition->getConfigurator()); + } + if (isset($changes['file'])) { + $def->setFile($definition->getFile()); + } + if (isset($changes['public'])) { + $def->setPublic($definition->isPublic()); + } else { + $def->setPrivate($definition->isPrivate() || $parentDef->isPrivate()); + } + if (isset($changes['lazy'])) { + $def->setLazy($definition->isLazy()); + } + if (isset($changes['deprecated'])) { + $def->setDeprecated($definition->isDeprecated(), $definition->getDeprecationMessage('%service_id%')); + } + if (isset($changes['autowired'])) { + $def->setAutowired($definition->isAutowired()); + } + if (isset($changes['shared'])) { + $def->setShared($definition->isShared()); + } + if (isset($changes['decorated_service'])) { + $decoratedService = $definition->getDecoratedService(); + if (null === $decoratedService) { + $def->setDecoratedService($decoratedService); + } else { + $def->setDecoratedService($decoratedService[0], $decoratedService[1], $decoratedService[2]); + } + } + // merge arguments + foreach ($definition->getArguments() as $k => $v) { + if (\is_numeric($k)) { + $def->addArgument($v); + } elseif (0 === \strpos($k, 'index_')) { + $def->replaceArgument((int) \substr($k, \strlen('index_')), $v); + } else { + $def->setArgument($k, $v); + } + } + // merge properties + foreach ($definition->getProperties() as $k => $v) { + $def->setProperty($k, $v); + } + // append method calls + if ($calls = $definition->getMethodCalls()) { + $def->setMethodCalls(\array_merge($def->getMethodCalls(), $calls)); + } + // merge autowiring types + foreach ($definition->getAutowiringTypes(\false) as $autowiringType) { + $def->addAutowiringType($autowiringType); + } + // these attributes are always taken from the child + $def->setAbstract($definition->isAbstract()); + $def->setTags($definition->getTags()); + // autoconfigure is never taken from parent (on purpose) + // and it's not legal on an instanceof + $def->setAutoconfigured($definition->isAutoconfigured()); + return $def; + } +} +\class_alias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass::class); diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveClassPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveClassPass.php index e437ab9b8..46d17afee 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveClassPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveClassPass.php @@ -1,51 +1,51 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -/** - * @author Nicolas Grekas - */ -class ResolveClassPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - private $changes = []; - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - foreach ($container->getDefinitions() as $id => $definition) { - if ($definition->isSynthetic() || null !== $definition->getClass()) { - continue; - } - if (\preg_match('/^[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+(?:\\\\[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+)++$/', $id)) { - if ($definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition && !\class_exists($id)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service definition "%s" has a parent but no class, and its name looks like a FQCN. Either the class is missing or you want to inherit it from the parent service. To resolve this ambiguity, please rename this service to a non-FQCN (e.g. using dots), or create the missing class.', $id)); - } - $this->changes[\strtolower($id)] = $id; - $definition->setClass($id); - } - } - } - /** - * @internal - * - * @deprecated since 3.3, to be removed in 4.0. - */ - public function getChanges() - { - $changes = $this->changes; - $this->changes = []; - return $changes; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +/** + * @author Nicolas Grekas + */ +class ResolveClassPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + private $changes = []; + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + foreach ($container->getDefinitions() as $id => $definition) { + if ($definition->isSynthetic() || null !== $definition->getClass()) { + continue; + } + if (\preg_match('/^[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+(?:\\\\[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+)++$/', $id)) { + if ($definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition && !\class_exists($id)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service definition "%s" has a parent but no class, and its name looks like a FQCN. Either the class is missing or you want to inherit it from the parent service. To resolve this ambiguity, please rename this service to a non-FQCN (e.g. using dots), or create the missing class.', $id)); + } + $this->changes[\strtolower($id)] = $id; + $definition->setClass($id); + } + } + } + /** + * @internal + * + * @deprecated since 3.3, to be removed in 4.0. + */ + public function getChanges() + { + $changes = $this->changes; + $this->changes = []; + return $changes; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveDefinitionTemplatesPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveDefinitionTemplatesPass.php index ebdf38d8a..c113320b7 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveDefinitionTemplatesPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveDefinitionTemplatesPass.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -@\trigger_error('The ' . __NAMESPACE__ . '\\ResolveDefinitionTemplatesPass class is deprecated since Symfony 3.4 and will be removed in 4.0. Use the ResolveChildDefinitionsPass class instead.', \E_USER_DEPRECATED); -\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass::class); -if (\false) { - /** - * This definition decorates another definition. - * - * @author Johannes M. Schmitt - * - * @deprecated The ResolveDefinitionTemplatesPass class is deprecated since version 3.4 and will be removed in 4.0. Use the ResolveChildDefinitionsPass class instead. - */ - class ResolveDefinitionTemplatesPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +@\trigger_error('The ' . __NAMESPACE__ . '\\ResolveDefinitionTemplatesPass class is deprecated since Symfony 3.4 and will be removed in 4.0. Use the ResolveChildDefinitionsPass class instead.', \E_USER_DEPRECATED); +\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass::class); +if (\false) { + /** + * This definition decorates another definition. + * + * @author Johannes M. Schmitt + * + * @deprecated The ResolveDefinitionTemplatesPass class is deprecated since version 3.4 and will be removed in 4.0. Use the ResolveChildDefinitionsPass class instead. + */ + class ResolveDefinitionTemplatesPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass + { + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveEnvPlaceholdersPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveEnvPlaceholdersPass.php index c7e39477f..8ddf1683a 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveEnvPlaceholdersPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveEnvPlaceholdersPass.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -/** - * Replaces env var placeholders by their current values. - */ -class ResolveEnvPlaceholdersPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - protected function processValue($value, $isRoot = \false) - { - if (\is_string($value)) { - return $this->container->resolveEnvPlaceholders($value, \true); - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - $changes = $value->getChanges(); - if (isset($changes['class'])) { - $value->setClass($this->container->resolveEnvPlaceholders($value->getClass(), \true)); - } - if (isset($changes['file'])) { - $value->setFile($this->container->resolveEnvPlaceholders($value->getFile(), \true)); - } - } - $value = parent::processValue($value, $isRoot); - if ($value && \is_array($value) && !$isRoot) { - $value = \array_combine($this->container->resolveEnvPlaceholders(\array_keys($value), \true), $value); - } - return $value; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +/** + * Replaces env var placeholders by their current values. + */ +class ResolveEnvPlaceholdersPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + protected function processValue($value, $isRoot = \false) + { + if (\is_string($value)) { + return $this->container->resolveEnvPlaceholders($value, \true); + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + $changes = $value->getChanges(); + if (isset($changes['class'])) { + $value->setClass($this->container->resolveEnvPlaceholders($value->getClass(), \true)); + } + if (isset($changes['file'])) { + $value->setFile($this->container->resolveEnvPlaceholders($value->getFile(), \true)); + } + } + $value = parent::processValue($value, $isRoot); + if ($value && \is_array($value) && !$isRoot) { + $value = \array_combine($this->container->resolveEnvPlaceholders(\array_keys($value), \true), $value); + } + return $value; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveFactoryClassPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveFactoryClassPass.php index bca98ab45..19c5af510 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveFactoryClassPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveFactoryClassPass.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -/** - * @author Maxime Steinhausser - */ -class ResolveFactoryClassPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && \is_array($factory = $value->getFactory()) && null === $factory[0]) { - if (null === ($class = $value->getClass())) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The "%s" service is defined to be created by a factory, but is missing the factory class. Did you forget to define the factory or service class?', $this->currentId)); - } - $factory[0] = $class; - $value->setFactory($factory); - } - return parent::processValue($value, $isRoot); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +/** + * @author Maxime Steinhausser + */ +class ResolveFactoryClassPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && \is_array($factory = $value->getFactory()) && null === $factory[0]) { + if (null === ($class = $value->getClass())) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The "%s" service is defined to be created by a factory, but is missing the factory class. Did you forget to define the factory or service class?', $this->currentId)); + } + $factory[0] = $class; + $value->setFactory($factory); + } + return parent::processValue($value, $isRoot); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveHotPathPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveHotPathPass.php index c63046f42..dbd5977e9 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveHotPathPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveHotPathPass.php @@ -1,64 +1,64 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Propagate "container.hot_path" tags to referenced services. - * - * @author Nicolas Grekas - */ -class ResolveHotPathPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - private $tagName; - private $resolvedIds = []; - public function __construct($tagName = 'container.hot_path') - { - $this->tagName = $tagName; - } - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - try { - parent::process($container); - $container->getDefinition('service_container')->clearTag($this->tagName); - } finally { - $this->resolvedIds = []; - } - } - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { - return $value; - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && $isRoot && (isset($this->resolvedIds[$this->currentId]) || !$value->hasTag($this->tagName) || $value->isDeprecated())) { - return $value->isDeprecated() ? $value->clearTag($this->tagName) : $value; - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::IGNORE_ON_UNINITIALIZED_REFERENCE !== $value->getInvalidBehavior() && $this->container->has($id = $this->container->normalizeId($value))) { - $definition = $this->container->findDefinition($id); - if (!$definition->hasTag($this->tagName) && !$definition->isDeprecated()) { - $this->resolvedIds[$id] = \true; - $definition->addTag($this->tagName); - parent::processValue($definition, \false); - } - return $value; - } - return parent::processValue($value, $isRoot); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Propagate "container.hot_path" tags to referenced services. + * + * @author Nicolas Grekas + */ +class ResolveHotPathPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + private $tagName; + private $resolvedIds = []; + public function __construct($tagName = 'container.hot_path') + { + $this->tagName = $tagName; + } + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + try { + parent::process($container); + $container->getDefinition('service_container')->clearTag($this->tagName); + } finally { + $this->resolvedIds = []; + } + } + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { + return $value; + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && $isRoot && (isset($this->resolvedIds[$this->currentId]) || !$value->hasTag($this->tagName) || $value->isDeprecated())) { + return $value->isDeprecated() ? $value->clearTag($this->tagName) : $value; + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::IGNORE_ON_UNINITIALIZED_REFERENCE !== $value->getInvalidBehavior() && $this->container->has($id = $this->container->normalizeId($value))) { + $definition = $this->container->findDefinition($id); + if (!$definition->hasTag($this->tagName) && !$definition->isDeprecated()) { + $this->resolvedIds[$id] = \true; + $definition->addTag($this->tagName); + parent::processValue($definition, \false); + } + return $value; + } + return parent::processValue($value, $isRoot); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveInstanceofConditionalsPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveInstanceofConditionalsPass.php index 712672630..b29b56839 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveInstanceofConditionalsPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveInstanceofConditionalsPass.php @@ -1,129 +1,129 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -/** - * Applies instanceof conditionals to definitions. - * - * @author Nicolas Grekas - */ -class ResolveInstanceofConditionalsPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - foreach ($container->getAutoconfiguredInstanceof() as $interface => $definition) { - if ($definition->getArguments()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Autoconfigured instanceof for type "%s" defines arguments but these are not supported and should be removed.', $interface)); - } - if ($definition->getMethodCalls()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Autoconfigured instanceof for type "%s" defines method calls but these are not supported and should be removed.', $interface)); - } - } - foreach ($container->getDefinitions() as $id => $definition) { - if ($definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { - // don't apply "instanceof" to children: it will be applied to their parent - continue; - } - $container->setDefinition($id, $this->processDefinition($container, $id, $definition)); - } - } - private function processDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, $id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - $instanceofConditionals = $definition->getInstanceofConditionals(); - $autoconfiguredInstanceof = $definition->isAutoconfigured() ? $container->getAutoconfiguredInstanceof() : []; - if (!$instanceofConditionals && !$autoconfiguredInstanceof) { - return $definition; - } - if (!($class = $container->getParameterBag()->resolveValue($definition->getClass()))) { - return $definition; - } - $conditionals = $this->mergeConditionals($autoconfiguredInstanceof, $instanceofConditionals, $container); - $definition->setInstanceofConditionals([]); - $parent = $shared = null; - $instanceofTags = []; - $reflectionClass = null; - foreach ($conditionals as $interface => $instanceofDefs) { - if ($interface !== $class && !(null === $reflectionClass ? $reflectionClass = $container->getReflectionClass($class, \false) ?: \false : $reflectionClass)) { - continue; - } - if ($interface !== $class && !\is_subclass_of($class, $interface)) { - continue; - } - foreach ($instanceofDefs as $key => $instanceofDef) { - /** @var ChildDefinition $instanceofDef */ - $instanceofDef = clone $instanceofDef; - $instanceofDef->setAbstract(\true)->setParent($parent ?: 'abstract.instanceof.' . $id); - $parent = 'instanceof.' . $interface . '.' . $key . '.' . $id; - $container->setDefinition($parent, $instanceofDef); - $instanceofTags[] = $instanceofDef->getTags(); - $instanceofDef->setTags([]); - if (isset($instanceofDef->getChanges()['shared'])) { - $shared = $instanceofDef->isShared(); - } - } - } - if ($parent) { - $bindings = $definition->getBindings(); - $abstract = $container->setDefinition('abstract.instanceof.' . $id, $definition); - // cast Definition to ChildDefinition - $definition->setBindings([]); - $definition = \serialize($definition); - $definition = \substr_replace($definition, '53', 2, 2); - $definition = \substr_replace($definition, 'Child', 44, 0); - $definition = \unserialize($definition); - $definition->setParent($parent); - if (null !== $shared && !isset($definition->getChanges()['shared'])) { - $definition->setShared($shared); - } - $i = \count($instanceofTags); - while (0 <= --$i) { - foreach ($instanceofTags[$i] as $k => $v) { - foreach ($v as $v) { - if ($definition->hasTag($k) && \in_array($v, $definition->getTag($k))) { - continue; - } - $definition->addTag($k, $v); - } - } - } - $definition->setBindings($bindings); - // reset fields with "merge" behavior - $abstract->setBindings([])->setArguments([])->setMethodCalls([])->setDecoratedService(null)->setTags([])->setAbstract(\true); - } - return $definition; - } - private function mergeConditionals(array $autoconfiguredInstanceof, array $instanceofConditionals, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - // make each value an array of ChildDefinition - $conditionals = \array_map(function ($childDef) { - return [$childDef]; - }, $autoconfiguredInstanceof); - foreach ($instanceofConditionals as $interface => $instanceofDef) { - // make sure the interface/class exists (but don't validate automaticInstanceofConditionals) - if (!$container->getReflectionClass($interface)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('"%s" is set as an "instanceof" conditional, but it does not exist.', $interface)); - } - if (!isset($autoconfiguredInstanceof[$interface])) { - $conditionals[$interface] = []; - } - $conditionals[$interface][] = $instanceofDef; - } - return $conditionals; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +/** + * Applies instanceof conditionals to definitions. + * + * @author Nicolas Grekas + */ +class ResolveInstanceofConditionalsPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + foreach ($container->getAutoconfiguredInstanceof() as $interface => $definition) { + if ($definition->getArguments()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Autoconfigured instanceof for type "%s" defines arguments but these are not supported and should be removed.', $interface)); + } + if ($definition->getMethodCalls()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Autoconfigured instanceof for type "%s" defines method calls but these are not supported and should be removed.', $interface)); + } + } + foreach ($container->getDefinitions() as $id => $definition) { + if ($definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { + // don't apply "instanceof" to children: it will be applied to their parent + continue; + } + $container->setDefinition($id, $this->processDefinition($container, $id, $definition)); + } + } + private function processDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, $id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + $instanceofConditionals = $definition->getInstanceofConditionals(); + $autoconfiguredInstanceof = $definition->isAutoconfigured() ? $container->getAutoconfiguredInstanceof() : []; + if (!$instanceofConditionals && !$autoconfiguredInstanceof) { + return $definition; + } + if (!($class = $container->getParameterBag()->resolveValue($definition->getClass()))) { + return $definition; + } + $conditionals = $this->mergeConditionals($autoconfiguredInstanceof, $instanceofConditionals, $container); + $definition->setInstanceofConditionals([]); + $parent = $shared = null; + $instanceofTags = []; + $reflectionClass = null; + foreach ($conditionals as $interface => $instanceofDefs) { + if ($interface !== $class && !(null === $reflectionClass ? $reflectionClass = $container->getReflectionClass($class, \false) ?: \false : $reflectionClass)) { + continue; + } + if ($interface !== $class && !\is_subclass_of($class, $interface)) { + continue; + } + foreach ($instanceofDefs as $key => $instanceofDef) { + /** @var ChildDefinition $instanceofDef */ + $instanceofDef = clone $instanceofDef; + $instanceofDef->setAbstract(\true)->setParent($parent ?: 'abstract.instanceof.' . $id); + $parent = 'instanceof.' . $interface . '.' . $key . '.' . $id; + $container->setDefinition($parent, $instanceofDef); + $instanceofTags[] = $instanceofDef->getTags(); + $instanceofDef->setTags([]); + if (isset($instanceofDef->getChanges()['shared'])) { + $shared = $instanceofDef->isShared(); + } + } + } + if ($parent) { + $bindings = $definition->getBindings(); + $abstract = $container->setDefinition('abstract.instanceof.' . $id, $definition); + // cast Definition to ChildDefinition + $definition->setBindings([]); + $definition = \serialize($definition); + $definition = \substr_replace($definition, '53', 2, 2); + $definition = \substr_replace($definition, 'Child', 44, 0); + $definition = \unserialize($definition); + $definition->setParent($parent); + if (null !== $shared && !isset($definition->getChanges()['shared'])) { + $definition->setShared($shared); + } + $i = \count($instanceofTags); + while (0 <= --$i) { + foreach ($instanceofTags[$i] as $k => $v) { + foreach ($v as $v) { + if ($definition->hasTag($k) && \in_array($v, $definition->getTag($k))) { + continue; + } + $definition->addTag($k, $v); + } + } + } + $definition->setBindings($bindings); + // reset fields with "merge" behavior + $abstract->setBindings([])->setArguments([])->setMethodCalls([])->setDecoratedService(null)->setTags([])->setAbstract(\true); + } + return $definition; + } + private function mergeConditionals(array $autoconfiguredInstanceof, array $instanceofConditionals, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + // make each value an array of ChildDefinition + $conditionals = \array_map(function ($childDef) { + return [$childDef]; + }, $autoconfiguredInstanceof); + foreach ($instanceofConditionals as $interface => $instanceofDef) { + // make sure the interface/class exists (but don't validate automaticInstanceofConditionals) + if (!$container->getReflectionClass($interface)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('"%s" is set as an "instanceof" conditional, but it does not exist.', $interface)); + } + if (!isset($autoconfiguredInstanceof[$interface])) { + $conditionals[$interface] = []; + } + $conditionals[$interface][] = $instanceofDef; + } + return $conditionals; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveInvalidReferencesPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveInvalidReferencesPass.php index 28167e166..c42fe32a3 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveInvalidReferencesPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveInvalidReferencesPass.php @@ -1,102 +1,102 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Emulates the invalid behavior if the reference is not found within the - * container. - * - * @author Johannes M. Schmitt - */ -class ResolveInvalidReferencesPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - private $container; - private $signalingException; - /** - * Process the ContainerBuilder to resolve invalid references. - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $this->container = $container; - $this->signalingException = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Invalid reference.'); - try { - $this->processValue($container->getDefinitions(), 1); - } finally { - $this->container = $this->signalingException = null; - } - } - /** - * Processes arguments to determine invalid references. - * - * @throws RuntimeException When an invalid reference is found - */ - private function processValue($value, $rootLevel = 0, $level = 0) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { - $value->setValues($this->processValue($value->getValues(), 1, 1)); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { - $value->setValues($this->processValue($value->getValues(), $rootLevel, 1 + $level)); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - if ($value->isSynthetic() || $value->isAbstract()) { - return $value; - } - $value->setArguments($this->processValue($value->getArguments(), 0)); - $value->setProperties($this->processValue($value->getProperties(), 1)); - $value->setMethodCalls($this->processValue($value->getMethodCalls(), 2)); - } elseif (\is_array($value)) { - $i = 0; - foreach ($value as $k => $v) { - try { - if (\false !== $i && $k !== $i++) { - $i = \false; - } - if ($v !== ($processedValue = $this->processValue($v, $rootLevel, 1 + $level))) { - $value[$k] = $processedValue; - } - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { - if ($rootLevel < $level || $rootLevel && !$level) { - unset($value[$k]); - } elseif ($rootLevel) { - throw $e; - } else { - $value[$k] = null; - } - } - } - // Ensure numerically indexed arguments have sequential numeric keys. - if (\false !== $i) { - $value = \array_values($value); - } - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - if ($this->container->has($value)) { - return $value; - } - $invalidBehavior = $value->getInvalidBehavior(); - // resolve invalid behavior - if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE === $invalidBehavior) { - $value = null; - } elseif (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE === $invalidBehavior) { - if (0 < $level || $rootLevel) { - throw $this->signalingException; - } - $value = null; - } - } - return $value; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Emulates the invalid behavior if the reference is not found within the + * container. + * + * @author Johannes M. Schmitt + */ +class ResolveInvalidReferencesPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + private $container; + private $signalingException; + /** + * Process the ContainerBuilder to resolve invalid references. + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $this->container = $container; + $this->signalingException = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Invalid reference.'); + try { + $this->processValue($container->getDefinitions(), 1); + } finally { + $this->container = $this->signalingException = null; + } + } + /** + * Processes arguments to determine invalid references. + * + * @throws RuntimeException When an invalid reference is found + */ + private function processValue($value, $rootLevel = 0, $level = 0) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { + $value->setValues($this->processValue($value->getValues(), 1, 1)); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { + $value->setValues($this->processValue($value->getValues(), $rootLevel, 1 + $level)); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + if ($value->isSynthetic() || $value->isAbstract()) { + return $value; + } + $value->setArguments($this->processValue($value->getArguments(), 0)); + $value->setProperties($this->processValue($value->getProperties(), 1)); + $value->setMethodCalls($this->processValue($value->getMethodCalls(), 2)); + } elseif (\is_array($value)) { + $i = 0; + foreach ($value as $k => $v) { + try { + if (\false !== $i && $k !== $i++) { + $i = \false; + } + if ($v !== ($processedValue = $this->processValue($v, $rootLevel, 1 + $level))) { + $value[$k] = $processedValue; + } + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { + if ($rootLevel < $level || $rootLevel && !$level) { + unset($value[$k]); + } elseif ($rootLevel) { + throw $e; + } else { + $value[$k] = null; + } + } + } + // Ensure numerically indexed arguments have sequential numeric keys. + if (\false !== $i) { + $value = \array_values($value); + } + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + if ($this->container->has($value)) { + return $value; + } + $invalidBehavior = $value->getInvalidBehavior(); + // resolve invalid behavior + if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE === $invalidBehavior) { + $value = null; + } elseif (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE === $invalidBehavior) { + if (0 < $level || $rootLevel) { + throw $this->signalingException; + } + $value = null; + } + } + return $value; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveNamedArgumentsPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveNamedArgumentsPass.php index 3dc0f3503..733b6b388 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveNamedArgumentsPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveNamedArgumentsPass.php @@ -1,86 +1,86 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Resolves named arguments to their corresponding numeric index. - * - * @author Kévin Dunglas - */ -class ResolveNamedArgumentsPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - return parent::processValue($value, $isRoot); - } - $calls = $value->getMethodCalls(); - $calls[] = ['__construct', $value->getArguments()]; - foreach ($calls as $i => $call) { - list($method, $arguments) = $call; - $parameters = null; - $resolvedArguments = []; - foreach ($arguments as $key => $argument) { - if (\is_int($key)) { - $resolvedArguments[$key] = $argument; - continue; - } - if (null === $parameters) { - $r = $this->getReflectionMethod($value, $method); - $class = $r instanceof \ReflectionMethod ? $r->class : $this->currentId; - $method = $r->getName(); - $parameters = $r->getParameters(); - } - if (isset($key[0]) && '$' === $key[0]) { - foreach ($parameters as $j => $p) { - if ($key === '$' . $p->name) { - $resolvedArguments[$j] = $argument; - continue 2; - } - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid service "%s": method "%s()" has no argument named "%s". Check your service definition.', $this->currentId, $class !== $this->currentId ? $class . '::' . $method : $method, $key)); - } - if (null !== $argument && !$argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && !$argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid service "%s": the value of argument "%s" of method "%s()" must be null, an instance of "%s" or an instance of "%s", "%s" given.', $this->currentId, $key, $class !== $this->currentId ? $class . '::' . $method : $method, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition::class, \gettype($argument))); - } - $typeFound = \false; - foreach ($parameters as $j => $p) { - if (!\array_key_exists($j, $resolvedArguments) && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper::getTypeHint($r, $p, \true) === $key) { - $resolvedArguments[$j] = $argument; - $typeFound = \true; - } - } - if (!$typeFound) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid service "%s": method "%s()" has no argument type-hinted as "%s". Check your service definition.', $this->currentId, $class !== $this->currentId ? $class . '::' . $method : $method, $key)); - } - } - if ($resolvedArguments !== $call[1]) { - \ksort($resolvedArguments); - $calls[$i][1] = $resolvedArguments; - } - } - list(, $arguments) = \array_pop($calls); - if ($arguments !== $value->getArguments()) { - $value->setArguments($arguments); - } - if ($calls !== $value->getMethodCalls()) { - $value->setMethodCalls($calls); - } - return parent::processValue($value, $isRoot); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Resolves named arguments to their corresponding numeric index. + * + * @author Kévin Dunglas + */ +class ResolveNamedArgumentsPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + return parent::processValue($value, $isRoot); + } + $calls = $value->getMethodCalls(); + $calls[] = ['__construct', $value->getArguments()]; + foreach ($calls as $i => $call) { + list($method, $arguments) = $call; + $parameters = null; + $resolvedArguments = []; + foreach ($arguments as $key => $argument) { + if (\is_int($key)) { + $resolvedArguments[$key] = $argument; + continue; + } + if (null === $parameters) { + $r = $this->getReflectionMethod($value, $method); + $class = $r instanceof \ReflectionMethod ? $r->class : $this->currentId; + $method = $r->getName(); + $parameters = $r->getParameters(); + } + if (isset($key[0]) && '$' === $key[0]) { + foreach ($parameters as $j => $p) { + if ($key === '$' . $p->name) { + $resolvedArguments[$j] = $argument; + continue 2; + } + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid service "%s": method "%s()" has no argument named "%s". Check your service definition.', $this->currentId, $class !== $this->currentId ? $class . '::' . $method : $method, $key)); + } + if (null !== $argument && !$argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && !$argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid service "%s": the value of argument "%s" of method "%s()" must be null, an instance of "%s" or an instance of "%s", "%s" given.', $this->currentId, $key, $class !== $this->currentId ? $class . '::' . $method : $method, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition::class, \gettype($argument))); + } + $typeFound = \false; + foreach ($parameters as $j => $p) { + if (!\array_key_exists($j, $resolvedArguments) && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\ProxyHelper::getTypeHint($r, $p, \true) === $key) { + $resolvedArguments[$j] = $argument; + $typeFound = \true; + } + } + if (!$typeFound) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid service "%s": method "%s()" has no argument type-hinted as "%s". Check your service definition.', $this->currentId, $class !== $this->currentId ? $class . '::' . $method : $method, $key)); + } + } + if ($resolvedArguments !== $call[1]) { + \ksort($resolvedArguments); + $calls[$i][1] = $resolvedArguments; + } + } + list(, $arguments) = \array_pop($calls); + if ($arguments !== $value->getArguments()) { + $value->setArguments($arguments); + } + if ($calls !== $value->getMethodCalls()) { + $value->setMethodCalls($calls); + } + return parent::processValue($value, $isRoot); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveParameterPlaceHoldersPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveParameterPlaceHoldersPass.php index 17fb2620b..1bcbd709c 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveParameterPlaceHoldersPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveParameterPlaceHoldersPass.php @@ -1,84 +1,84 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; -/** - * Resolves all parameter placeholders "%somevalue%" to their real values. - * - * @author Johannes M. Schmitt - */ -class ResolveParameterPlaceHoldersPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - private $bag; - private $resolveArrays; - private $throwOnResolveException; - public function __construct($resolveArrays = \true, $throwOnResolveException = \true) - { - $this->resolveArrays = $resolveArrays; - $this->throwOnResolveException = $throwOnResolveException; - } - /** - * {@inheritdoc} - * - * @throws ParameterNotFoundException - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $this->bag = $container->getParameterBag(); - try { - parent::process($container); - $aliases = []; - foreach ($container->getAliases() as $name => $target) { - $this->currentId = $name; - $aliases[$this->bag->resolveValue($name)] = $target; - } - $container->setAliases($aliases); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { - $e->setSourceId($this->currentId); - throw $e; - } - $this->bag->resolve(); - $this->bag = null; - } - protected function processValue($value, $isRoot = \false) - { - if (\is_string($value)) { - try { - $v = $this->bag->resolveValue($value); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { - if ($this->throwOnResolveException) { - throw $e; - } - $v = null; - $this->container->getDefinition($this->currentId)->addError($e->getMessage()); - } - return $this->resolveArrays || !$v || !\is_array($v) ? $v : $value; - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - $value->setBindings($this->processValue($value->getBindings())); - $changes = $value->getChanges(); - if (isset($changes['class'])) { - $value->setClass($this->bag->resolveValue($value->getClass())); - } - if (isset($changes['file'])) { - $value->setFile($this->bag->resolveValue($value->getFile())); - } - } - $value = parent::processValue($value, $isRoot); - if ($value && \is_array($value)) { - $value = \array_combine($this->bag->resolveValue(\array_keys($value)), $value); - } - return $value; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; +/** + * Resolves all parameter placeholders "%somevalue%" to their real values. + * + * @author Johannes M. Schmitt + */ +class ResolveParameterPlaceHoldersPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + private $bag; + private $resolveArrays; + private $throwOnResolveException; + public function __construct($resolveArrays = \true, $throwOnResolveException = \true) + { + $this->resolveArrays = $resolveArrays; + $this->throwOnResolveException = $throwOnResolveException; + } + /** + * {@inheritdoc} + * + * @throws ParameterNotFoundException + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $this->bag = $container->getParameterBag(); + try { + parent::process($container); + $aliases = []; + foreach ($container->getAliases() as $name => $target) { + $this->currentId = $name; + $aliases[$this->bag->resolveValue($name)] = $target; + } + $container->setAliases($aliases); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { + $e->setSourceId($this->currentId); + throw $e; + } + $this->bag->resolve(); + $this->bag = null; + } + protected function processValue($value, $isRoot = \false) + { + if (\is_string($value)) { + try { + $v = $this->bag->resolveValue($value); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { + if ($this->throwOnResolveException) { + throw $e; + } + $v = null; + $this->container->getDefinition($this->currentId)->addError($e->getMessage()); + } + return $this->resolveArrays || !$v || !\is_array($v) ? $v : $value; + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + $value->setBindings($this->processValue($value->getBindings())); + $changes = $value->getChanges(); + if (isset($changes['class'])) { + $value->setClass($this->bag->resolveValue($value->getClass())); + } + if (isset($changes['file'])) { + $value->setFile($this->bag->resolveValue($value->getFile())); + } + } + $value = parent::processValue($value, $isRoot); + if ($value && \is_array($value)) { + $value = \array_combine($this->bag->resolveValue(\array_keys($value)), $value); + } + return $value; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolvePrivatesPass.php b/vendor/symfony/dependency-injection/Compiler/ResolvePrivatesPass.php index dd87a2811..ac26fd9ba 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolvePrivatesPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolvePrivatesPass.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * @author Nicolas Grekas - */ -class ResolvePrivatesPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - foreach ($container->getDefinitions() as $id => $definition) { - if ($definition->isPrivate()) { - $definition->setPublic(\false); - $definition->setPrivate(\true); - } - } - foreach ($container->getAliases() as $id => $alias) { - if ($alias->isPrivate()) { - $alias->setPublic(\false); - $alias->setPrivate(\true); - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * @author Nicolas Grekas + */ +class ResolvePrivatesPass implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + foreach ($container->getDefinitions() as $id => $definition) { + if ($definition->isPrivate()) { + $definition->setPublic(\false); + $definition->setPrivate(\true); + } + } + foreach ($container->getAliases() as $id => $alias) { + if ($alias->isPrivate()) { + $alias->setPublic(\false); + $alias->setPrivate(\true); + } + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveReferencesToAliasesPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveReferencesToAliasesPass.php index 4b7faed6d..77812bf38 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveReferencesToAliasesPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveReferencesToAliasesPass.php @@ -1,68 +1,68 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Replaces all references to aliases with references to the actual service. - * - * @author Johannes M. Schmitt - */ -class ResolveReferencesToAliasesPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - /** - * {@inheritdoc} - */ - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - parent::process($container); - foreach ($container->getAliases() as $id => $alias) { - $aliasId = $container->normalizeId($alias); - if ($aliasId !== ($defId = $this->getDefinitionId($aliasId, $container))) { - $container->setAlias($id, $defId)->setPublic($alias->isPublic())->setPrivate($alias->isPrivate()); - } - } - } - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $defId = $this->getDefinitionId($id = $this->container->normalizeId($value), $this->container); - if ($defId !== $id) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($defId, $value->getInvalidBehavior()); - } - } - return parent::processValue($value); - } - /** - * Resolves an alias into a definition id. - * - * @param string $id The definition or alias id to resolve - * - * @return string The definition id with aliases resolved - */ - private function getDefinitionId($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $seen = []; - while ($container->hasAlias($id)) { - if (isset($seen[$id])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, \array_merge(\array_keys($seen), [$id])); - } - $seen[$id] = \true; - $id = $container->normalizeId($container->getAlias($id)); - } - return $id; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Replaces all references to aliases with references to the actual service. + * + * @author Johannes M. Schmitt + */ +class ResolveReferencesToAliasesPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + /** + * {@inheritdoc} + */ + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + parent::process($container); + foreach ($container->getAliases() as $id => $alias) { + $aliasId = $container->normalizeId($alias); + if ($aliasId !== ($defId = $this->getDefinitionId($aliasId, $container))) { + $container->setAlias($id, $defId)->setPublic($alias->isPublic())->setPrivate($alias->isPrivate()); + } + } + } + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $defId = $this->getDefinitionId($id = $this->container->normalizeId($value), $this->container); + if ($defId !== $id) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($defId, $value->getInvalidBehavior()); + } + } + return parent::processValue($value); + } + /** + * Resolves an alias into a definition id. + * + * @param string $id The definition or alias id to resolve + * + * @return string The definition id with aliases resolved + */ + private function getDefinitionId($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $seen = []; + while ($container->hasAlias($id)) { + if (isset($seen[$id])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, \array_merge(\array_keys($seen), [$id])); + } + $seen[$id] = \true; + $id = $container->normalizeId($container->getAlias($id)); + } + return $id; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveServiceSubscribersPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveServiceSubscribersPass.php index ded28fc2d..27f41fd56 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveServiceSubscribersPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveServiceSubscribersPass.php @@ -1,44 +1,44 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * Compiler pass to inject their service locator to service subscribers. - * - * @author Nicolas Grekas - */ -class ResolveServiceSubscribersPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - private $serviceLocator; - protected function processValue($value, $isRoot = \false) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && $this->serviceLocator && \_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class === $this->container->normalizeId($value)) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($this->serviceLocator); - } - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - return parent::processValue($value, $isRoot); - } - $serviceLocator = $this->serviceLocator; - $this->serviceLocator = null; - if ($value->hasTag('container.service_subscriber.locator')) { - $this->serviceLocator = $value->getTag('container.service_subscriber.locator')[0]['id']; - $value->clearTag('container.service_subscriber.locator'); - } - try { - return parent::processValue($value); - } finally { - $this->serviceLocator = $serviceLocator; - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * Compiler pass to inject their service locator to service subscribers. + * + * @author Nicolas Grekas + */ +class ResolveServiceSubscribersPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + private $serviceLocator; + protected function processValue($value, $isRoot = \false) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && $this->serviceLocator && \_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class === $this->container->normalizeId($value)) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($this->serviceLocator); + } + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + return parent::processValue($value, $isRoot); + } + $serviceLocator = $this->serviceLocator; + $this->serviceLocator = null; + if ($value->hasTag('container.service_subscriber.locator')) { + $this->serviceLocator = $value->getTag('container.service_subscriber.locator')[0]['id']; + $value->clearTag('container.service_subscriber.locator'); + } + try { + return parent::processValue($value); + } finally { + $this->serviceLocator = $serviceLocator; + } + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ResolveTaggedIteratorArgumentPass.php b/vendor/symfony/dependency-injection/Compiler/ResolveTaggedIteratorArgumentPass.php index 69338cf0a..0299e3ecd 100644 --- a/vendor/symfony/dependency-injection/Compiler/ResolveTaggedIteratorArgumentPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ResolveTaggedIteratorArgumentPass.php @@ -1,33 +1,33 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; -/** - * Resolves all TaggedIteratorArgument arguments. - * - * @author Roland Franssen - */ -class ResolveTaggedIteratorArgumentPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - use PriorityTaggedServiceTrait; - /** - * {@inheritdoc} - */ - protected function processValue($value, $isRoot = \false) - { - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument) { - return parent::processValue($value, $isRoot); - } - $value->setValues($this->findAndSortTaggedServices($value->getTag(), $this->container)); - return $value; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; +/** + * Resolves all TaggedIteratorArgument arguments. + * + * @author Roland Franssen + */ +class ResolveTaggedIteratorArgumentPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + use PriorityTaggedServiceTrait; + /** + * {@inheritdoc} + */ + protected function processValue($value, $isRoot = \false) + { + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument) { + return parent::processValue($value, $isRoot); + } + $value->setValues($this->findAndSortTaggedServices($value->getTag(), $this->container)); + return $value; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ServiceLocatorTagPass.php b/vendor/symfony/dependency-injection/Compiler/ServiceLocatorTagPass.php index f680e4d28..6f7a18da8 100644 --- a/vendor/symfony/dependency-injection/Compiler/ServiceLocatorTagPass.php +++ b/vendor/symfony/dependency-injection/Compiler/ServiceLocatorTagPass.php @@ -1,99 +1,99 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; -/** - * Applies the "container.service_locator" tag by wrapping references into ServiceClosureArgument instances. - * - * @author Nicolas Grekas - */ -final class ServiceLocatorTagPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass -{ - protected function processValue($value, $isRoot = \false) - { - if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || !$value->hasTag('container.service_locator')) { - return parent::processValue($value, $isRoot); - } - if (!$value->getClass()) { - $value->setClass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class); - } - $arguments = $value->getArguments(); - if (!isset($arguments[0]) || !\is_array($arguments[0])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid definition for service "%s": an array of references is expected as first argument when the "container.service_locator" tag is set.', $this->currentId)); - } - $i = 0; - foreach ($arguments[0] as $k => $v) { - if ($v instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { - continue; - } - if (!$v instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid definition for service "%s": an array of references is expected as first argument when the "container.service_locator" tag is set, "%s" found for key "%s".', $this->currentId, \is_object($v) ? \get_class($v) : \gettype($v), $k)); - } - if ($i === $k) { - unset($arguments[0][$k]); - $k = (string) $v; - ++$i; - } elseif (\is_int($k)) { - $i = null; - } - $arguments[0][$k] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument($v); - } - \ksort($arguments[0]); - $value->setArguments($arguments); - $id = 'service_locator.' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::hash($value); - if ($isRoot) { - if ($id !== $this->currentId) { - $this->container->setAlias($id, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($this->currentId, \false)); - } - return $value; - } - $this->container->setDefinition($id, $value->setPublic(\false)); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($id); - } - /** - * @param Reference[] $refMap - * @param string|null $callerId - * - * @return Reference - */ - public static function register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, array $refMap, $callerId = null) - { - foreach ($refMap as $id => $ref) { - if (!$ref instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid service locator definition: only services can be referenced, "%s" found for key "%s". Inject parameter values using constructors instead.', \is_object($ref) ? \get_class($ref) : \gettype($ref), $id)); - } - $refMap[$id] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument($ref); - } - \ksort($refMap); - $locator = (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class))->addArgument($refMap)->setPublic(\false)->addTag('container.service_locator'); - if (null !== $callerId && $container->hasDefinition($callerId)) { - $locator->setBindings($container->getDefinition($callerId)->getBindings()); - } - if (!$container->hasDefinition($id = 'service_locator.' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::hash($locator))) { - $container->setDefinition($id, $locator); - } - if (null !== $callerId) { - $locatorId = $id; - // Locators are shared when they hold the exact same list of factories; - // to have them specialized per consumer service, we use a cloning factory - // to derivate customized instances from the prototype one. - $container->register($id .= '.' . $callerId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\false)->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($locatorId), 'withContext'])->addArgument($callerId)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($id); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; +/** + * Applies the "container.service_locator" tag by wrapping references into ServiceClosureArgument instances. + * + * @author Nicolas Grekas + */ +final class ServiceLocatorTagPass extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AbstractRecursivePass +{ + protected function processValue($value, $isRoot = \false) + { + if (!$value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || !$value->hasTag('container.service_locator')) { + return parent::processValue($value, $isRoot); + } + if (!$value->getClass()) { + $value->setClass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class); + } + $arguments = $value->getArguments(); + if (!isset($arguments[0]) || !\is_array($arguments[0])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid definition for service "%s": an array of references is expected as first argument when the "container.service_locator" tag is set.', $this->currentId)); + } + $i = 0; + foreach ($arguments[0] as $k => $v) { + if ($v instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { + continue; + } + if (!$v instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid definition for service "%s": an array of references is expected as first argument when the "container.service_locator" tag is set, "%s" found for key "%s".', $this->currentId, \is_object($v) ? \get_class($v) : \gettype($v), $k)); + } + if ($i === $k) { + unset($arguments[0][$k]); + $k = (string) $v; + ++$i; + } elseif (\is_int($k)) { + $i = null; + } + $arguments[0][$k] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument($v); + } + \ksort($arguments[0]); + $value->setArguments($arguments); + $id = 'service_locator.' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::hash($value); + if ($isRoot) { + if ($id !== $this->currentId) { + $this->container->setAlias($id, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($this->currentId, \false)); + } + return $value; + } + $this->container->setDefinition($id, $value->setPublic(\false)); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($id); + } + /** + * @param Reference[] $refMap + * @param string|null $callerId + * + * @return Reference + */ + public static function register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, array $refMap, $callerId = null) + { + foreach ($refMap as $id => $ref) { + if (!$ref instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid service locator definition: only services can be referenced, "%s" found for key "%s". Inject parameter values using constructors instead.', \is_object($ref) ? \get_class($ref) : \gettype($ref), $id)); + } + $refMap[$id] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument($ref); + } + \ksort($refMap); + $locator = (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class))->addArgument($refMap)->setPublic(\false)->addTag('container.service_locator'); + if (null !== $callerId && $container->hasDefinition($callerId)) { + $locator->setBindings($container->getDefinition($callerId)->getBindings()); + } + if (!$container->hasDefinition($id = 'service_locator.' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::hash($locator))) { + $container->setDefinition($id, $locator); + } + if (null !== $callerId) { + $locatorId = $id; + // Locators are shared when they hold the exact same list of factories; + // to have them specialized per consumer service, we use a cloning factory + // to derivate customized instances from the prototype one. + $container->register($id .= '.' . $callerId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\false)->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($locatorId), 'withContext'])->addArgument($callerId)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($id); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraph.php b/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraph.php index af7515faa..26a69bcc7 100644 --- a/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraph.php +++ b/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraph.php @@ -1,114 +1,114 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -/** - * This is a directed graph of your services. - * - * This information can be used by your compiler passes instead of collecting - * it themselves which improves performance quite a lot. - * - * @author Johannes M. Schmitt - * - * @final since version 3.4 - */ -class ServiceReferenceGraph -{ - /** - * @var ServiceReferenceGraphNode[] - */ - private $nodes = []; - /** - * Checks if the graph has a specific node. - * - * @param string $id Id to check - * - * @return bool - */ - public function hasNode($id) - { - return isset($this->nodes[$id]); - } - /** - * Gets a node by identifier. - * - * @param string $id The id to retrieve - * - * @return ServiceReferenceGraphNode - * - * @throws InvalidArgumentException if no node matches the supplied identifier - */ - public function getNode($id) - { - if (!isset($this->nodes[$id])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('There is no node with id "%s".', $id)); - } - return $this->nodes[$id]; - } - /** - * Returns all nodes. - * - * @return ServiceReferenceGraphNode[] - */ - public function getNodes() - { - return $this->nodes; - } - /** - * Clears all nodes. - */ - public function clear() - { - foreach ($this->nodes as $node) { - $node->clear(); - } - $this->nodes = []; - } - /** - * Connects 2 nodes together in the Graph. - * - * @param string $sourceId - * @param mixed $sourceValue - * @param string $destId - * @param mixed $destValue - * @param string $reference - */ - public function connect($sourceId, $sourceValue, $destId, $destValue = null, $reference = null) - { - $lazy = \func_num_args() >= 6 ? \func_get_arg(5) : \false; - $weak = \func_num_args() >= 7 ? \func_get_arg(6) : \false; - $byConstructor = \func_num_args() >= 8 ? \func_get_arg(7) : \false; - if (null === $sourceId || null === $destId) { - return; - } - $sourceNode = $this->createNode($sourceId, $sourceValue); - $destNode = $this->createNode($destId, $destValue); - $edge = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphEdge($sourceNode, $destNode, $reference, $lazy, $weak, $byConstructor); - $sourceNode->addOutEdge($edge); - $destNode->addInEdge($edge); - } - /** - * Creates a graph node. - * - * @param string $id - * @param mixed $value - * - * @return ServiceReferenceGraphNode - */ - private function createNode($id, $value) - { - if (isset($this->nodes[$id]) && $this->nodes[$id]->getValue() === $value) { - return $this->nodes[$id]; - } - return $this->nodes[$id] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphNode($id, $value); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +/** + * This is a directed graph of your services. + * + * This information can be used by your compiler passes instead of collecting + * it themselves which improves performance quite a lot. + * + * @author Johannes M. Schmitt + * + * @final since version 3.4 + */ +class ServiceReferenceGraph +{ + /** + * @var ServiceReferenceGraphNode[] + */ + private $nodes = []; + /** + * Checks if the graph has a specific node. + * + * @param string $id Id to check + * + * @return bool + */ + public function hasNode($id) + { + return isset($this->nodes[$id]); + } + /** + * Gets a node by identifier. + * + * @param string $id The id to retrieve + * + * @return ServiceReferenceGraphNode + * + * @throws InvalidArgumentException if no node matches the supplied identifier + */ + public function getNode($id) + { + if (!isset($this->nodes[$id])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('There is no node with id "%s".', $id)); + } + return $this->nodes[$id]; + } + /** + * Returns all nodes. + * + * @return ServiceReferenceGraphNode[] + */ + public function getNodes() + { + return $this->nodes; + } + /** + * Clears all nodes. + */ + public function clear() + { + foreach ($this->nodes as $node) { + $node->clear(); + } + $this->nodes = []; + } + /** + * Connects 2 nodes together in the Graph. + * + * @param string $sourceId + * @param mixed $sourceValue + * @param string $destId + * @param mixed $destValue + * @param string $reference + */ + public function connect($sourceId, $sourceValue, $destId, $destValue = null, $reference = null) + { + $lazy = \func_num_args() >= 6 ? \func_get_arg(5) : \false; + $weak = \func_num_args() >= 7 ? \func_get_arg(6) : \false; + $byConstructor = \func_num_args() >= 8 ? \func_get_arg(7) : \false; + if (null === $sourceId || null === $destId) { + return; + } + $sourceNode = $this->createNode($sourceId, $sourceValue); + $destNode = $this->createNode($destId, $destValue); + $edge = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphEdge($sourceNode, $destNode, $reference, $lazy, $weak, $byConstructor); + $sourceNode->addOutEdge($edge); + $destNode->addInEdge($edge); + } + /** + * Creates a graph node. + * + * @param string $id + * @param mixed $value + * + * @return ServiceReferenceGraphNode + */ + private function createNode($id, $value) + { + if (isset($this->nodes[$id]) && $this->nodes[$id]->getValue() === $value) { + return $this->nodes[$id]; + } + return $this->nodes[$id] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphNode($id, $value); + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraphEdge.php b/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraphEdge.php index 0993c236d..9e806ce54 100644 --- a/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraphEdge.php +++ b/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraphEdge.php @@ -1,97 +1,97 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -/** - * Represents an edge in your service graph. - * - * Value is typically a reference. - * - * @author Johannes M. Schmitt - */ -class ServiceReferenceGraphEdge -{ - private $sourceNode; - private $destNode; - private $value; - private $lazy; - private $weak; - private $byConstructor; - /** - * @param mixed $value - * @param bool $lazy - * @param bool $weak - * @param bool $byConstructor - */ - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphNode $sourceNode, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphNode $destNode, $value = null, $lazy = \false, $weak = \false, $byConstructor = \false) - { - $this->sourceNode = $sourceNode; - $this->destNode = $destNode; - $this->value = $value; - $this->lazy = $lazy; - $this->weak = $weak; - $this->byConstructor = $byConstructor; - } - /** - * Returns the value of the edge. - * - * @return string - */ - public function getValue() - { - return $this->value; - } - /** - * Returns the source node. - * - * @return ServiceReferenceGraphNode - */ - public function getSourceNode() - { - return $this->sourceNode; - } - /** - * Returns the destination node. - * - * @return ServiceReferenceGraphNode - */ - public function getDestNode() - { - return $this->destNode; - } - /** - * Returns true if the edge is lazy, meaning it's a dependency not requiring direct instantiation. - * - * @return bool - */ - public function isLazy() - { - return $this->lazy; - } - /** - * Returns true if the edge is weak, meaning it shouldn't prevent removing the target service. - * - * @return bool - */ - public function isWeak() - { - return $this->weak; - } - /** - * Returns true if the edge links with a constructor argument. - * - * @return bool - */ - public function isReferencedByConstructor() - { - return $this->byConstructor; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +/** + * Represents an edge in your service graph. + * + * Value is typically a reference. + * + * @author Johannes M. Schmitt + */ +class ServiceReferenceGraphEdge +{ + private $sourceNode; + private $destNode; + private $value; + private $lazy; + private $weak; + private $byConstructor; + /** + * @param mixed $value + * @param bool $lazy + * @param bool $weak + * @param bool $byConstructor + */ + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphNode $sourceNode, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphNode $destNode, $value = null, $lazy = \false, $weak = \false, $byConstructor = \false) + { + $this->sourceNode = $sourceNode; + $this->destNode = $destNode; + $this->value = $value; + $this->lazy = $lazy; + $this->weak = $weak; + $this->byConstructor = $byConstructor; + } + /** + * Returns the value of the edge. + * + * @return string + */ + public function getValue() + { + return $this->value; + } + /** + * Returns the source node. + * + * @return ServiceReferenceGraphNode + */ + public function getSourceNode() + { + return $this->sourceNode; + } + /** + * Returns the destination node. + * + * @return ServiceReferenceGraphNode + */ + public function getDestNode() + { + return $this->destNode; + } + /** + * Returns true if the edge is lazy, meaning it's a dependency not requiring direct instantiation. + * + * @return bool + */ + public function isLazy() + { + return $this->lazy; + } + /** + * Returns true if the edge is weak, meaning it shouldn't prevent removing the target service. + * + * @return bool + */ + public function isWeak() + { + return $this->weak; + } + /** + * Returns true if the edge links with a constructor argument. + * + * @return bool + */ + public function isReferencedByConstructor() + { + return $this->byConstructor; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraphNode.php b/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraphNode.php index 9573eeccc..d7dd53b1b 100644 --- a/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraphNode.php +++ b/vendor/symfony/dependency-injection/Compiler/ServiceReferenceGraphNode.php @@ -1,106 +1,106 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -/** - * Represents a node in your service graph. - * - * Value is typically a definition, or an alias. - * - * @author Johannes M. Schmitt - */ -class ServiceReferenceGraphNode -{ - private $id; - private $inEdges = []; - private $outEdges = []; - private $value; - /** - * @param string $id The node identifier - * @param mixed $value The node value - */ - public function __construct($id, $value) - { - $this->id = $id; - $this->value = $value; - } - public function addInEdge(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphEdge $edge) - { - $this->inEdges[] = $edge; - } - public function addOutEdge(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphEdge $edge) - { - $this->outEdges[] = $edge; - } - /** - * Checks if the value of this node is an Alias. - * - * @return bool True if the value is an Alias instance - */ - public function isAlias() - { - return $this->value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; - } - /** - * Checks if the value of this node is a Definition. - * - * @return bool True if the value is a Definition instance - */ - public function isDefinition() - { - return $this->value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; - } - /** - * Returns the identifier. - * - * @return string - */ - public function getId() - { - return $this->id; - } - /** - * Returns the in edges. - * - * @return ServiceReferenceGraphEdge[] - */ - public function getInEdges() - { - return $this->inEdges; - } - /** - * Returns the out edges. - * - * @return ServiceReferenceGraphEdge[] - */ - public function getOutEdges() - { - return $this->outEdges; - } - /** - * Returns the value of this Node. - * - * @return mixed The value - */ - public function getValue() - { - return $this->value; - } - /** - * Clears all edges. - */ - public function clear() - { - $this->inEdges = $this->outEdges = []; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +/** + * Represents a node in your service graph. + * + * Value is typically a definition, or an alias. + * + * @author Johannes M. Schmitt + */ +class ServiceReferenceGraphNode +{ + private $id; + private $inEdges = []; + private $outEdges = []; + private $value; + /** + * @param string $id The node identifier + * @param mixed $value The node value + */ + public function __construct($id, $value) + { + $this->id = $id; + $this->value = $value; + } + public function addInEdge(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphEdge $edge) + { + $this->inEdges[] = $edge; + } + public function addOutEdge(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceReferenceGraphEdge $edge) + { + $this->outEdges[] = $edge; + } + /** + * Checks if the value of this node is an Alias. + * + * @return bool True if the value is an Alias instance + */ + public function isAlias() + { + return $this->value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; + } + /** + * Checks if the value of this node is a Definition. + * + * @return bool True if the value is a Definition instance + */ + public function isDefinition() + { + return $this->value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; + } + /** + * Returns the identifier. + * + * @return string + */ + public function getId() + { + return $this->id; + } + /** + * Returns the in edges. + * + * @return ServiceReferenceGraphEdge[] + */ + public function getInEdges() + { + return $this->inEdges; + } + /** + * Returns the out edges. + * + * @return ServiceReferenceGraphEdge[] + */ + public function getOutEdges() + { + return $this->outEdges; + } + /** + * Returns the value of this Node. + * + * @return mixed The value + */ + public function getValue() + { + return $this->value; + } + /** + * Clears all edges. + */ + public function clear() + { + $this->inEdges = $this->outEdges = []; + } +} diff --git a/vendor/symfony/dependency-injection/Compiler/index.php b/vendor/symfony/dependency-injection/Compiler/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Compiler/index.php +++ b/vendor/symfony/dependency-injection/Compiler/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Config/AutowireServiceResource.php b/vendor/symfony/dependency-injection/Config/AutowireServiceResource.php index 92ded018b..ff74d632e 100644 --- a/vendor/symfony/dependency-injection/Config/AutowireServiceResource.php +++ b/vendor/symfony/dependency-injection/Config/AutowireServiceResource.php @@ -1,76 +1,76 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config; - -@\trigger_error('The ' . __NAMESPACE__ . '\\AutowireServiceResource class is deprecated since Symfony 3.3 and will be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead.', \E_USER_DEPRECATED); -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass; -/** - * @deprecated since version 3.3, to be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead. - */ -class AutowireServiceResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable -{ - private $class; - private $filePath; - private $autowiringMetadata = []; - public function __construct($class, $path, array $autowiringMetadata) - { - $this->class = $class; - $this->filePath = $path; - $this->autowiringMetadata = $autowiringMetadata; - } - public function isFresh($timestamp) - { - if (!\file_exists($this->filePath)) { - return \false; - } - // has the file *not* been modified? Definitely fresh - if (@\filemtime($this->filePath) <= $timestamp) { - return \true; - } - try { - $reflectionClass = new \ReflectionClass($this->class); - } catch (\ReflectionException $e) { - // the class does not exist anymore! - return \false; - } - return (array) $this === (array) \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::createResourceForClass($reflectionClass); - } - public function __toString() - { - return 'service.autowire.' . $this->class; - } - /** - * @internal - */ - public function serialize() - { - return \serialize([$this->class, $this->filePath, $this->autowiringMetadata]); - } - /** - * @internal - */ - public function unserialize($serialized) - { - if (\PHP_VERSION_ID >= 70000) { - list($this->class, $this->filePath, $this->autowiringMetadata) = \unserialize($serialized, ['allowed_classes' => \false]); - } else { - list($this->class, $this->filePath, $this->autowiringMetadata) = \unserialize($serialized); - } - } - /** - * @deprecated Implemented for compatibility with Symfony 2.8 - */ - public function getResource() - { - return $this->filePath; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config; + +@\trigger_error('The ' . __NAMESPACE__ . '\\AutowireServiceResource class is deprecated since Symfony 3.3 and will be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead.', \E_USER_DEPRECATED); +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass; +/** + * @deprecated since version 3.3, to be removed in 4.0. Use ContainerBuilder::getReflectionClass() instead. + */ +class AutowireServiceResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\SelfCheckingResourceInterface, \Serializable +{ + private $class; + private $filePath; + private $autowiringMetadata = []; + public function __construct($class, $path, array $autowiringMetadata) + { + $this->class = $class; + $this->filePath = $path; + $this->autowiringMetadata = $autowiringMetadata; + } + public function isFresh($timestamp) + { + if (!\file_exists($this->filePath)) { + return \false; + } + // has the file *not* been modified? Definitely fresh + if (@\filemtime($this->filePath) <= $timestamp) { + return \true; + } + try { + $reflectionClass = new \ReflectionClass($this->class); + } catch (\ReflectionException $e) { + // the class does not exist anymore! + return \false; + } + return (array) $this === (array) \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::createResourceForClass($reflectionClass); + } + public function __toString() + { + return 'service.autowire.' . $this->class; + } + /** + * @internal + */ + public function serialize() + { + return \serialize([$this->class, $this->filePath, $this->autowiringMetadata]); + } + /** + * @internal + */ + public function unserialize($serialized) + { + if (\PHP_VERSION_ID >= 70000) { + list($this->class, $this->filePath, $this->autowiringMetadata) = \unserialize($serialized, ['allowed_classes' => \false]); + } else { + list($this->class, $this->filePath, $this->autowiringMetadata) = \unserialize($serialized); + } + } + /** + * @deprecated Implemented for compatibility with Symfony 2.8 + */ + public function getResource() + { + return $this->filePath; + } +} diff --git a/vendor/symfony/dependency-injection/Config/ContainerParametersResource.php b/vendor/symfony/dependency-injection/Config/ContainerParametersResource.php index 27c35109a..7f283723f 100644 --- a/vendor/symfony/dependency-injection/Config/ContainerParametersResource.php +++ b/vendor/symfony/dependency-injection/Config/ContainerParametersResource.php @@ -1,57 +1,57 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; -/** - * Tracks container parameters. - * - * @author Maxime Steinhausser - */ -class ContainerParametersResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface, \Serializable -{ - private $parameters; - /** - * @param array $parameters The container parameters to track - */ - public function __construct(array $parameters) - { - $this->parameters = $parameters; - } - /** - * {@inheritdoc} - */ - public function __toString() - { - return 'container_parameters_' . \md5(\serialize($this->parameters)); - } - /** - * @internal - */ - public function serialize() - { - return \serialize($this->parameters); - } - /** - * @internal - */ - public function unserialize($serialized) - { - $this->parameters = \unserialize($serialized); - } - /** - * @return array Tracked parameters - */ - public function getParameters() - { - return $this->parameters; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; +/** + * Tracks container parameters. + * + * @author Maxime Steinhausser + */ +class ContainerParametersResource implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface, \Serializable +{ + private $parameters; + /** + * @param array $parameters The container parameters to track + */ + public function __construct(array $parameters) + { + $this->parameters = $parameters; + } + /** + * {@inheritdoc} + */ + public function __toString() + { + return 'container_parameters_' . \md5(\serialize($this->parameters)); + } + /** + * @internal + */ + public function serialize() + { + return \serialize($this->parameters); + } + /** + * @internal + */ + public function unserialize($serialized) + { + $this->parameters = \unserialize($serialized); + } + /** + * @return array Tracked parameters + */ + public function getParameters() + { + return $this->parameters; + } +} diff --git a/vendor/symfony/dependency-injection/Config/ContainerParametersResourceChecker.php b/vendor/symfony/dependency-injection/Config/ContainerParametersResourceChecker.php index c4bbf5138..35a9ef48f 100644 --- a/vendor/symfony/dependency-injection/Config/ContainerParametersResourceChecker.php +++ b/vendor/symfony/dependency-injection/Config/ContainerParametersResourceChecker.php @@ -1,46 +1,46 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -/** - * @author Maxime Steinhausser - */ -class ContainerParametersResourceChecker implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerInterface -{ - /** @var ContainerInterface */ - private $container; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container) - { - $this->container = $container; - } - /** - * {@inheritdoc} - */ - public function supports(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $metadata) - { - return $metadata instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResource; - } - /** - * {@inheritdoc} - */ - public function isFresh(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $resource, $timestamp) - { - foreach ($resource->getParameters() as $key => $value) { - if (!$this->container->hasParameter($key) || $this->container->getParameter($key) !== $value) { - return \false; - } - } - return \true; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +/** + * @author Maxime Steinhausser + */ +class ContainerParametersResourceChecker implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerInterface +{ + /** @var ContainerInterface */ + private $container; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container) + { + $this->container = $container; + } + /** + * {@inheritdoc} + */ + public function supports(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $metadata) + { + return $metadata instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResource; + } + /** + * {@inheritdoc} + */ + public function isFresh(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $resource, $timestamp) + { + foreach ($resource->getParameters() as $key => $value) { + if (!$this->container->hasParameter($key) || $this->container->getParameter($key) !== $value) { + return \false; + } + } + return \true; + } +} diff --git a/vendor/symfony/dependency-injection/Config/index.php b/vendor/symfony/dependency-injection/Config/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Config/index.php +++ b/vendor/symfony/dependency-injection/Config/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Container.php b/vendor/symfony/dependency-injection/Container.php index a734beb93..0c542165b 100644 --- a/vendor/symfony/dependency-injection/Container.php +++ b/vendor/symfony/dependency-injection/Container.php @@ -1,465 +1,465 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface; -/** - * Container is a dependency injection container. - * - * It gives access to object instances (services). - * Services and parameters are simple key/pair stores. - * The container can have four possible behaviors when a service - * does not exist (or is not initialized for the last case): - * - * * EXCEPTION_ON_INVALID_REFERENCE: Throws an exception (the default) - * * NULL_ON_INVALID_REFERENCE: Returns null - * * IGNORE_ON_INVALID_REFERENCE: Ignores the wrapping command asking for the reference - * (for instance, ignore a setter if the service does not exist) - * * IGNORE_ON_UNINITIALIZED_REFERENCE: Ignores/returns null for uninitialized services or invalid references - * - * @author Fabien Potencier - * @author Johannes M. Schmitt - */ -class Container implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ResettableContainerInterface -{ - protected $parameterBag; - protected $services = []; - protected $fileMap = []; - protected $methodMap = []; - protected $aliases = []; - protected $loading = []; - protected $resolving = []; - protected $syntheticIds = []; - /** - * @internal - */ - protected $privates = []; - /** - * @internal - */ - protected $normalizedIds = []; - private $underscoreMap = ['_' => '', '.' => '_', '\\' => '_']; - private $envCache = []; - private $compiled = \false; - private $getEnv; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface $parameterBag = null) - { - $this->parameterBag = $parameterBag ?: new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - } - /** - * Compiles the container. - * - * This method does two things: - * - * * Parameter values are resolved; - * * The parameter bag is frozen. - */ - public function compile() - { - $this->parameterBag->resolve(); - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($this->parameterBag->all()); - $this->compiled = \true; - } - /** - * Returns true if the container is compiled. - * - * @return bool - */ - public function isCompiled() - { - return $this->compiled; - } - /** - * Returns true if the container parameter bag are frozen. - * - * @deprecated since version 3.3, to be removed in 4.0. - * - * @return bool true if the container parameter bag are frozen, false otherwise - */ - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return $this->parameterBag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag; - } - /** - * Gets the service container parameter bag. - * - * @return ParameterBagInterface A ParameterBagInterface instance - */ - public function getParameterBag() - { - return $this->parameterBag; - } - /** - * Gets a parameter. - * - * @param string $name The parameter name - * - * @return mixed The parameter value - * - * @throws InvalidArgumentException if the parameter is not defined - */ - public function getParameter($name) - { - return $this->parameterBag->get($name); - } - /** - * Checks if a parameter exists. - * - * @param string $name The parameter name - * - * @return bool The presence of parameter in container - */ - public function hasParameter($name) - { - return $this->parameterBag->has($name); - } - /** - * Sets a parameter. - * - * @param string $name The parameter name - * @param mixed $value The parameter value - */ - public function setParameter($name, $value) - { - $this->parameterBag->set($name, $value); - } - /** - * Sets a service. - * - * Setting a synthetic service to null resets it: has() returns false and get() - * behaves in the same way as if the service was never created. - * - * @param string $id The service identifier - * @param object|null $service The service instance - */ - public function set($id, $service) - { - // Runs the internal initializer; used by the dumped container to include always-needed files - if (isset($this->privates['service_container']) && $this->privates['service_container'] instanceof \Closure) { - $initialize = $this->privates['service_container']; - unset($this->privates['service_container']); - $initialize(); - } - $id = $this->normalizeId($id); - if ('service_container' === $id) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('You cannot set service "service_container".'); - } - if (isset($this->privates[$id]) || !(isset($this->fileMap[$id]) || isset($this->methodMap[$id]))) { - if (!isset($this->privates[$id]) && !isset($this->getRemovedIds()[$id])) { - // no-op - } elseif (null === $service) { - @\trigger_error(\sprintf('The "%s" service is private, unsetting it is deprecated since Symfony 3.2 and will fail in 4.0.', $id), \E_USER_DEPRECATED); - unset($this->privates[$id]); - } else { - @\trigger_error(\sprintf('The "%s" service is private, replacing it is deprecated since Symfony 3.2 and will fail in 4.0.', $id), \E_USER_DEPRECATED); - } - } elseif (isset($this->services[$id])) { - if (null === $service) { - @\trigger_error(\sprintf('The "%s" service is already initialized, unsetting it is deprecated since Symfony 3.3 and will fail in 4.0.', $id), \E_USER_DEPRECATED); - } else { - @\trigger_error(\sprintf('The "%s" service is already initialized, replacing it is deprecated since Symfony 3.3 and will fail in 4.0.', $id), \E_USER_DEPRECATED); - } - } - if (isset($this->aliases[$id])) { - unset($this->aliases[$id]); - } - if (null === $service) { - unset($this->services[$id]); - return; - } - $this->services[$id] = $service; - } - /** - * Returns true if the given service is defined. - * - * @param string $id The service identifier - * - * @return bool true if the service is defined, false otherwise - */ - public function has($id) - { - for ($i = 2;;) { - if (isset($this->privates[$id])) { - @\trigger_error(\sprintf('The "%s" service is private, checking for its existence is deprecated since Symfony 3.2 and will fail in 4.0.', $id), \E_USER_DEPRECATED); - } - if (isset($this->aliases[$id])) { - $id = $this->aliases[$id]; - } - if (isset($this->services[$id])) { - return \true; - } - if ('service_container' === $id) { - return \true; - } - if (isset($this->fileMap[$id]) || isset($this->methodMap[$id])) { - return \true; - } - if (--$i && $id !== ($normalizedId = $this->normalizeId($id))) { - $id = $normalizedId; - continue; - } - // We only check the convention-based factory in a compiled container (i.e. a child class other than a ContainerBuilder, - // and only when the dumper has not generated the method map (otherwise the method map is considered to be fully populated by the dumper) - if (!$this->methodMap && !$this instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder && __CLASS__ !== static::class && \method_exists($this, 'get' . \strtr($id, $this->underscoreMap) . 'Service')) { - @\trigger_error('Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', \E_USER_DEPRECATED); - return \true; - } - return \false; - } - } - /** - * Gets a service. - * - * If a service is defined both through a set() method and - * with a get{$id}Service() method, the former has always precedence. - * - * @param string $id The service identifier - * @param int $invalidBehavior The behavior when the service does not exist - * - * @return object|null The associated service - * - * @throws ServiceCircularReferenceException When a circular reference is detected - * @throws ServiceNotFoundException When the service is not defined - * @throws \Exception if an exception has been thrown when the service has been resolved - * - * @see Reference - */ - public function get($id, $invalidBehavior = 1) - { - // Attempt to retrieve the service by checking first aliases then - // available services. Service IDs are case insensitive, however since - // this method can be called thousands of times during a request, avoid - // calling $this->normalizeId($id) unless necessary. - for ($i = 2;;) { - if (isset($this->privates[$id])) { - @\trigger_error(\sprintf('The "%s" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead.', $id), \E_USER_DEPRECATED); - } - if (isset($this->aliases[$id])) { - $id = $this->aliases[$id]; - } - // Re-use shared service instance if it exists. - if (isset($this->services[$id])) { - return $this->services[$id]; - } - if ('service_container' === $id) { - return $this; - } - if (isset($this->loading[$id])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, \array_merge(\array_keys($this->loading), [$id])); - } - $this->loading[$id] = \true; - try { - if (isset($this->fileMap[$id])) { - return 4 === $invalidBehavior ? null : $this->load($this->fileMap[$id]); - } elseif (isset($this->methodMap[$id])) { - return 4 === $invalidBehavior ? null : $this->{$this->methodMap[$id]}(); - } elseif (--$i && $id !== ($normalizedId = $this->normalizeId($id))) { - unset($this->loading[$id]); - $id = $normalizedId; - continue; - } elseif (!$this->methodMap && !$this instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder && __CLASS__ !== static::class && \method_exists($this, $method = 'get' . \strtr($id, $this->underscoreMap) . 'Service')) { - // We only check the convention-based factory in a compiled container (i.e. a child class other than a ContainerBuilder, - // and only when the dumper has not generated the method map (otherwise the method map is considered to be fully populated by the dumper) - @\trigger_error('Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', \E_USER_DEPRECATED); - return 4 === $invalidBehavior ? null : $this->{$method}(); - } - break; - } catch (\Exception $e) { - unset($this->services[$id]); - throw $e; - } finally { - unset($this->loading[$id]); - } - } - if (1 === $invalidBehavior) { - if (!$id) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id); - } - if (isset($this->syntheticIds[$id])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id, null, null, [], \sprintf('The "%s" service is synthetic, it needs to be set at boot time before it can be used.', $id)); - } - if (isset($this->getRemovedIds()[$id])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id, null, null, [], \sprintf('The "%s" service or alias has been removed or inlined when the container was compiled. You should either make it public, or stop using the container directly and use dependency injection instead.', $id)); - } - $alternatives = []; - foreach ($this->getServiceIds() as $knownId) { - $lev = \levenshtein($id, $knownId); - if ($lev <= \strlen($id) / 3 || \false !== \strpos($knownId, $id)) { - $alternatives[] = $knownId; - } - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id, null, null, $alternatives); - } - } - /** - * Returns true if the given service has actually been initialized. - * - * @param string $id The service identifier - * - * @return bool true if service has already been initialized, false otherwise - */ - public function initialized($id) - { - $id = $this->normalizeId($id); - if (isset($this->privates[$id])) { - @\trigger_error(\sprintf('Checking for the initialization of the "%s" private service is deprecated since Symfony 3.4 and won\'t be supported anymore in Symfony 4.0.', $id), \E_USER_DEPRECATED); - } - if (isset($this->aliases[$id])) { - $id = $this->aliases[$id]; - } - if ('service_container' === $id) { - return \false; - } - return isset($this->services[$id]); - } - /** - * {@inheritdoc} - */ - public function reset() - { - $this->services = []; - } - /** - * Gets all service ids. - * - * @return string[] An array of all defined service ids - */ - public function getServiceIds() - { - $ids = []; - if (!$this->methodMap && !$this instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder && __CLASS__ !== static::class) { - // We only check the convention-based factory in a compiled container (i.e. a child class other than a ContainerBuilder, - // and only when the dumper has not generated the method map (otherwise the method map is considered to be fully populated by the dumper) - @\trigger_error('Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', \E_USER_DEPRECATED); - foreach (\get_class_methods($this) as $method) { - if (\preg_match('/^get(.+)Service$/', $method, $match)) { - $ids[] = self::underscore($match[1]); - } - } - } - $ids[] = 'service_container'; - return \array_map('strval', \array_unique(\array_merge($ids, \array_keys($this->methodMap), \array_keys($this->fileMap), \array_keys($this->aliases), \array_keys($this->services)))); - } - /** - * Gets service ids that existed at compile time. - * - * @return array - */ - public function getRemovedIds() - { - return []; - } - /** - * Camelizes a string. - * - * @param string $id A string to camelize - * - * @return string The camelized string - */ - public static function camelize($id) - { - return \strtr(\ucwords(\strtr($id, ['_' => ' ', '.' => '_ ', '\\' => '_ '])), [' ' => '']); - } - /** - * A string to underscore. - * - * @param string $id The string to underscore - * - * @return string The underscored string - */ - public static function underscore($id) - { - return \strtolower(\preg_replace(['/([A-Z]+)([A-Z][a-z])/', '/([a-z\\d])([A-Z])/'], ['\\1_\\2', '\\1_\\2'], \str_replace('_', '.', $id))); - } - /** - * Creates a service by requiring its factory file. - */ - protected function load($file) - { - return require $file; - } - /** - * Fetches a variable from the environment. - * - * @param string $name The name of the environment variable - * - * @return mixed The value to use for the provided environment variable name - * - * @throws EnvNotFoundException When the environment variable is not found and has no default value - */ - protected function getEnv($name) - { - if (isset($this->resolving[$envName = "env({$name})"])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException(\array_keys($this->resolving)); - } - if (isset($this->envCache[$name]) || \array_key_exists($name, $this->envCache)) { - return $this->envCache[$name]; - } - if (!$this->has($id = 'container.env_var_processors_locator')) { - $this->set($id, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator([])); - } - if (!$this->getEnv) { - $this->getEnv = new \ReflectionMethod($this, __FUNCTION__); - $this->getEnv->setAccessible(\true); - $this->getEnv = $this->getEnv->getClosure($this); - } - $processors = $this->get($id); - if (\false !== ($i = \strpos($name, ':'))) { - $prefix = \substr($name, 0, $i); - $localName = \substr($name, 1 + $i); - } else { - $prefix = 'string'; - $localName = $name; - } - $processor = $processors->has($prefix) ? $processors->get($prefix) : new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor($this); - $this->resolving[$envName] = \true; - try { - return $this->envCache[$name] = $processor->getEnv($prefix, $localName, $this->getEnv); - } finally { - unset($this->resolving[$envName]); - } - } - /** - * Returns the case sensitive id used at registration time. - * - * @param string $id - * - * @return string - * - * @internal - */ - public function normalizeId($id) - { - if (!\is_string($id)) { - $id = (string) $id; - } - if (isset($this->normalizedIds[$normalizedId = \strtolower($id)])) { - $normalizedId = $this->normalizedIds[$normalizedId]; - if ($id !== $normalizedId) { - @\trigger_error(\sprintf('Service identifiers will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.3.', $id, $normalizedId), \E_USER_DEPRECATED); - } - } else { - $normalizedId = $this->normalizedIds[$normalizedId] = $id; - } - return $normalizedId; - } - private function __clone() - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface; +/** + * Container is a dependency injection container. + * + * It gives access to object instances (services). + * Services and parameters are simple key/pair stores. + * The container can have four possible behaviors when a service + * does not exist (or is not initialized for the last case): + * + * * EXCEPTION_ON_INVALID_REFERENCE: Throws an exception (the default) + * * NULL_ON_INVALID_REFERENCE: Returns null + * * IGNORE_ON_INVALID_REFERENCE: Ignores the wrapping command asking for the reference + * (for instance, ignore a setter if the service does not exist) + * * IGNORE_ON_UNINITIALIZED_REFERENCE: Ignores/returns null for uninitialized services or invalid references + * + * @author Fabien Potencier + * @author Johannes M. Schmitt + */ +class Container implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ResettableContainerInterface +{ + protected $parameterBag; + protected $services = []; + protected $fileMap = []; + protected $methodMap = []; + protected $aliases = []; + protected $loading = []; + protected $resolving = []; + protected $syntheticIds = []; + /** + * @internal + */ + protected $privates = []; + /** + * @internal + */ + protected $normalizedIds = []; + private $underscoreMap = ['_' => '', '.' => '_', '\\' => '_']; + private $envCache = []; + private $compiled = \false; + private $getEnv; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface $parameterBag = null) + { + $this->parameterBag = $parameterBag ?: new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + } + /** + * Compiles the container. + * + * This method does two things: + * + * * Parameter values are resolved; + * * The parameter bag is frozen. + */ + public function compile() + { + $this->parameterBag->resolve(); + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($this->parameterBag->all()); + $this->compiled = \true; + } + /** + * Returns true if the container is compiled. + * + * @return bool + */ + public function isCompiled() + { + return $this->compiled; + } + /** + * Returns true if the container parameter bag are frozen. + * + * @deprecated since version 3.3, to be removed in 4.0. + * + * @return bool true if the container parameter bag are frozen, false otherwise + */ + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return $this->parameterBag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag; + } + /** + * Gets the service container parameter bag. + * + * @return ParameterBagInterface A ParameterBagInterface instance + */ + public function getParameterBag() + { + return $this->parameterBag; + } + /** + * Gets a parameter. + * + * @param string $name The parameter name + * + * @return mixed The parameter value + * + * @throws InvalidArgumentException if the parameter is not defined + */ + public function getParameter($name) + { + return $this->parameterBag->get($name); + } + /** + * Checks if a parameter exists. + * + * @param string $name The parameter name + * + * @return bool The presence of parameter in container + */ + public function hasParameter($name) + { + return $this->parameterBag->has($name); + } + /** + * Sets a parameter. + * + * @param string $name The parameter name + * @param mixed $value The parameter value + */ + public function setParameter($name, $value) + { + $this->parameterBag->set($name, $value); + } + /** + * Sets a service. + * + * Setting a synthetic service to null resets it: has() returns false and get() + * behaves in the same way as if the service was never created. + * + * @param string $id The service identifier + * @param object|null $service The service instance + */ + public function set($id, $service) + { + // Runs the internal initializer; used by the dumped container to include always-needed files + if (isset($this->privates['service_container']) && $this->privates['service_container'] instanceof \Closure) { + $initialize = $this->privates['service_container']; + unset($this->privates['service_container']); + $initialize(); + } + $id = $this->normalizeId($id); + if ('service_container' === $id) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('You cannot set service "service_container".'); + } + if (isset($this->privates[$id]) || !(isset($this->fileMap[$id]) || isset($this->methodMap[$id]))) { + if (!isset($this->privates[$id]) && !isset($this->getRemovedIds()[$id])) { + // no-op + } elseif (null === $service) { + @\trigger_error(\sprintf('The "%s" service is private, unsetting it is deprecated since Symfony 3.2 and will fail in 4.0.', $id), \E_USER_DEPRECATED); + unset($this->privates[$id]); + } else { + @\trigger_error(\sprintf('The "%s" service is private, replacing it is deprecated since Symfony 3.2 and will fail in 4.0.', $id), \E_USER_DEPRECATED); + } + } elseif (isset($this->services[$id])) { + if (null === $service) { + @\trigger_error(\sprintf('The "%s" service is already initialized, unsetting it is deprecated since Symfony 3.3 and will fail in 4.0.', $id), \E_USER_DEPRECATED); + } else { + @\trigger_error(\sprintf('The "%s" service is already initialized, replacing it is deprecated since Symfony 3.3 and will fail in 4.0.', $id), \E_USER_DEPRECATED); + } + } + if (isset($this->aliases[$id])) { + unset($this->aliases[$id]); + } + if (null === $service) { + unset($this->services[$id]); + return; + } + $this->services[$id] = $service; + } + /** + * Returns true if the given service is defined. + * + * @param string $id The service identifier + * + * @return bool true if the service is defined, false otherwise + */ + public function has($id) + { + for ($i = 2;;) { + if (isset($this->privates[$id])) { + @\trigger_error(\sprintf('The "%s" service is private, checking for its existence is deprecated since Symfony 3.2 and will fail in 4.0.', $id), \E_USER_DEPRECATED); + } + if (isset($this->aliases[$id])) { + $id = $this->aliases[$id]; + } + if (isset($this->services[$id])) { + return \true; + } + if ('service_container' === $id) { + return \true; + } + if (isset($this->fileMap[$id]) || isset($this->methodMap[$id])) { + return \true; + } + if (--$i && $id !== ($normalizedId = $this->normalizeId($id))) { + $id = $normalizedId; + continue; + } + // We only check the convention-based factory in a compiled container (i.e. a child class other than a ContainerBuilder, + // and only when the dumper has not generated the method map (otherwise the method map is considered to be fully populated by the dumper) + if (!$this->methodMap && !$this instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder && __CLASS__ !== static::class && \method_exists($this, 'get' . \strtr($id, $this->underscoreMap) . 'Service')) { + @\trigger_error('Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', \E_USER_DEPRECATED); + return \true; + } + return \false; + } + } + /** + * Gets a service. + * + * If a service is defined both through a set() method and + * with a get{$id}Service() method, the former has always precedence. + * + * @param string $id The service identifier + * @param int $invalidBehavior The behavior when the service does not exist + * + * @return object|null The associated service + * + * @throws ServiceCircularReferenceException When a circular reference is detected + * @throws ServiceNotFoundException When the service is not defined + * @throws \Exception if an exception has been thrown when the service has been resolved + * + * @see Reference + */ + public function get($id, $invalidBehavior = 1) + { + // Attempt to retrieve the service by checking first aliases then + // available services. Service IDs are case insensitive, however since + // this method can be called thousands of times during a request, avoid + // calling $this->normalizeId($id) unless necessary. + for ($i = 2;;) { + if (isset($this->privates[$id])) { + @\trigger_error(\sprintf('The "%s" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead.', $id), \E_USER_DEPRECATED); + } + if (isset($this->aliases[$id])) { + $id = $this->aliases[$id]; + } + // Re-use shared service instance if it exists. + if (isset($this->services[$id])) { + return $this->services[$id]; + } + if ('service_container' === $id) { + return $this; + } + if (isset($this->loading[$id])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, \array_merge(\array_keys($this->loading), [$id])); + } + $this->loading[$id] = \true; + try { + if (isset($this->fileMap[$id])) { + return 4 === $invalidBehavior ? null : $this->load($this->fileMap[$id]); + } elseif (isset($this->methodMap[$id])) { + return 4 === $invalidBehavior ? null : $this->{$this->methodMap[$id]}(); + } elseif (--$i && $id !== ($normalizedId = $this->normalizeId($id))) { + unset($this->loading[$id]); + $id = $normalizedId; + continue; + } elseif (!$this->methodMap && !$this instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder && __CLASS__ !== static::class && \method_exists($this, $method = 'get' . \strtr($id, $this->underscoreMap) . 'Service')) { + // We only check the convention-based factory in a compiled container (i.e. a child class other than a ContainerBuilder, + // and only when the dumper has not generated the method map (otherwise the method map is considered to be fully populated by the dumper) + @\trigger_error('Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', \E_USER_DEPRECATED); + return 4 === $invalidBehavior ? null : $this->{$method}(); + } + break; + } catch (\Exception $e) { + unset($this->services[$id]); + throw $e; + } finally { + unset($this->loading[$id]); + } + } + if (1 === $invalidBehavior) { + if (!$id) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id); + } + if (isset($this->syntheticIds[$id])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id, null, null, [], \sprintf('The "%s" service is synthetic, it needs to be set at boot time before it can be used.', $id)); + } + if (isset($this->getRemovedIds()[$id])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id, null, null, [], \sprintf('The "%s" service or alias has been removed or inlined when the container was compiled. You should either make it public, or stop using the container directly and use dependency injection instead.', $id)); + } + $alternatives = []; + foreach ($this->getServiceIds() as $knownId) { + $lev = \levenshtein($id, $knownId); + if ($lev <= \strlen($id) / 3 || \false !== \strpos($knownId, $id)) { + $alternatives[] = $knownId; + } + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id, null, null, $alternatives); + } + } + /** + * Returns true if the given service has actually been initialized. + * + * @param string $id The service identifier + * + * @return bool true if service has already been initialized, false otherwise + */ + public function initialized($id) + { + $id = $this->normalizeId($id); + if (isset($this->privates[$id])) { + @\trigger_error(\sprintf('Checking for the initialization of the "%s" private service is deprecated since Symfony 3.4 and won\'t be supported anymore in Symfony 4.0.', $id), \E_USER_DEPRECATED); + } + if (isset($this->aliases[$id])) { + $id = $this->aliases[$id]; + } + if ('service_container' === $id) { + return \false; + } + return isset($this->services[$id]); + } + /** + * {@inheritdoc} + */ + public function reset() + { + $this->services = []; + } + /** + * Gets all service ids. + * + * @return string[] An array of all defined service ids + */ + public function getServiceIds() + { + $ids = []; + if (!$this->methodMap && !$this instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder && __CLASS__ !== static::class) { + // We only check the convention-based factory in a compiled container (i.e. a child class other than a ContainerBuilder, + // and only when the dumper has not generated the method map (otherwise the method map is considered to be fully populated by the dumper) + @\trigger_error('Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map.', \E_USER_DEPRECATED); + foreach (\get_class_methods($this) as $method) { + if (\preg_match('/^get(.+)Service$/', $method, $match)) { + $ids[] = self::underscore($match[1]); + } + } + } + $ids[] = 'service_container'; + return \array_map('strval', \array_unique(\array_merge($ids, \array_keys($this->methodMap), \array_keys($this->fileMap), \array_keys($this->aliases), \array_keys($this->services)))); + } + /** + * Gets service ids that existed at compile time. + * + * @return array + */ + public function getRemovedIds() + { + return []; + } + /** + * Camelizes a string. + * + * @param string $id A string to camelize + * + * @return string The camelized string + */ + public static function camelize($id) + { + return \strtr(\ucwords(\strtr($id, ['_' => ' ', '.' => '_ ', '\\' => '_ '])), [' ' => '']); + } + /** + * A string to underscore. + * + * @param string $id The string to underscore + * + * @return string The underscored string + */ + public static function underscore($id) + { + return \strtolower(\preg_replace(['/([A-Z]+)([A-Z][a-z])/', '/([a-z\\d])([A-Z])/'], ['\\1_\\2', '\\1_\\2'], \str_replace('_', '.', $id))); + } + /** + * Creates a service by requiring its factory file. + */ + protected function load($file) + { + return require $file; + } + /** + * Fetches a variable from the environment. + * + * @param string $name The name of the environment variable + * + * @return mixed The value to use for the provided environment variable name + * + * @throws EnvNotFoundException When the environment variable is not found and has no default value + */ + protected function getEnv($name) + { + if (isset($this->resolving[$envName = "env({$name})"])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException(\array_keys($this->resolving)); + } + if (isset($this->envCache[$name]) || \array_key_exists($name, $this->envCache)) { + return $this->envCache[$name]; + } + if (!$this->has($id = 'container.env_var_processors_locator')) { + $this->set($id, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator([])); + } + if (!$this->getEnv) { + $this->getEnv = new \ReflectionMethod($this, __FUNCTION__); + $this->getEnv->setAccessible(\true); + $this->getEnv = $this->getEnv->getClosure($this); + } + $processors = $this->get($id); + if (\false !== ($i = \strpos($name, ':'))) { + $prefix = \substr($name, 0, $i); + $localName = \substr($name, 1 + $i); + } else { + $prefix = 'string'; + $localName = $name; + } + $processor = $processors->has($prefix) ? $processors->get($prefix) : new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor($this); + $this->resolving[$envName] = \true; + try { + return $this->envCache[$name] = $processor->getEnv($prefix, $localName, $this->getEnv); + } finally { + unset($this->resolving[$envName]); + } + } + /** + * Returns the case sensitive id used at registration time. + * + * @param string $id + * + * @return string + * + * @internal + */ + public function normalizeId($id) + { + if (!\is_string($id)) { + $id = (string) $id; + } + if (isset($this->normalizedIds[$normalizedId = \strtolower($id)])) { + $normalizedId = $this->normalizedIds[$normalizedId]; + if ($id !== $normalizedId) { + @\trigger_error(\sprintf('Service identifiers will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.3.', $id, $normalizedId), \E_USER_DEPRECATED); + } + } else { + $normalizedId = $this->normalizedIds[$normalizedId] = $id; + } + return $normalizedId; + } + private function __clone() + { + } +} diff --git a/vendor/symfony/dependency-injection/ContainerAwareInterface.php b/vendor/symfony/dependency-injection/ContainerAwareInterface.php index 32c27344e..565846dd6 100644 --- a/vendor/symfony/dependency-injection/ContainerAwareInterface.php +++ b/vendor/symfony/dependency-injection/ContainerAwareInterface.php @@ -1,24 +1,24 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -/** - * ContainerAwareInterface should be implemented by classes that depends on a Container. - * - * @author Fabien Potencier - */ -interface ContainerAwareInterface -{ - /** - * Sets the container. - */ - public function setContainer(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container = null); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +/** + * ContainerAwareInterface should be implemented by classes that depends on a Container. + * + * @author Fabien Potencier + */ +interface ContainerAwareInterface +{ + /** + * Sets the container. + */ + public function setContainer(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container = null); +} diff --git a/vendor/symfony/dependency-injection/ContainerAwareTrait.php b/vendor/symfony/dependency-injection/ContainerAwareTrait.php index 2c3ba4f4e..a648a70fd 100644 --- a/vendor/symfony/dependency-injection/ContainerAwareTrait.php +++ b/vendor/symfony/dependency-injection/ContainerAwareTrait.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -/** - * ContainerAware trait. - * - * @author Fabien Potencier - */ -trait ContainerAwareTrait -{ - /** - * @var ContainerInterface - */ - protected $container; - public function setContainer(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container = null) - { - $this->container = $container; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +/** + * ContainerAware trait. + * + * @author Fabien Potencier + */ +trait ContainerAwareTrait +{ + /** + * @var ContainerInterface + */ + protected $container; + public function setContainer(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container = null) + { + $this->container = $container; + } +} diff --git a/vendor/symfony/dependency-injection/ContainerBuilder.php b/vendor/symfony/dependency-injection/ContainerBuilder.php index 0829e33f3..76f2fab18 100644 --- a/vendor/symfony/dependency-injection/ContainerBuilder.php +++ b/vendor/symfony/dependency-injection/ContainerBuilder.php @@ -1,1450 +1,1450 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\Compiler; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveEnvPlaceholdersPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\InstantiatorInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\ContainerAwareEventDispatcher; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface; -/** - * ContainerBuilder is a DI container that provides an API to easily describe services. - * - * @author Fabien Potencier - */ -class ContainerBuilder extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TaggedContainerInterface -{ - /** - * @var ExtensionInterface[] - */ - private $extensions = []; - /** - * @var ExtensionInterface[] - */ - private $extensionsByNs = []; - /** - * @var Definition[] - */ - private $definitions = []; - /** - * @var Alias[] - */ - private $aliasDefinitions = []; - /** - * @var ResourceInterface[] - */ - private $resources = []; - private $extensionConfigs = []; - /** - * @var Compiler - */ - private $compiler; - private $trackResources; - /** - * @var InstantiatorInterface|null - */ - private $proxyInstantiator; - /** - * @var ExpressionLanguage|null - */ - private $expressionLanguage; - /** - * @var ExpressionFunctionProviderInterface[] - */ - private $expressionLanguageProviders = []; - /** - * @var string[] with tag names used by findTaggedServiceIds - */ - private $usedTags = []; - /** - * @var string[][] a map of env var names to their placeholders - */ - private $envPlaceholders = []; - /** - * @var int[] a map of env vars to their resolution counter - */ - private $envCounters = []; - /** - * @var string[] the list of vendor directories - */ - private $vendors; - private $autoconfiguredInstanceof = []; - private $removedIds = []; - private $removedBindingIds = []; - private static $internalTypes = ['int' => \true, 'float' => \true, 'string' => \true, 'bool' => \true, 'resource' => \true, 'object' => \true, 'array' => \true, 'null' => \true, 'callable' => \true, 'iterable' => \true, 'mixed' => \true]; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface $parameterBag = null) - { - parent::__construct($parameterBag); - $this->trackResources = \interface_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ResourceInterface'); - $this->setDefinition('service_container', (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class))->setSynthetic(\true)->setPublic(\true)); - $this->setAlias(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('service_container', \false)); - $this->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('service_container', \false)); - } - /** - * @var \ReflectionClass[] a list of class reflectors - */ - private $classReflectors; - /** - * Sets the track resources flag. - * - * If you are not using the loaders and therefore don't want - * to depend on the Config component, set this flag to false. - * - * @param bool $track True if you want to track resources, false otherwise - */ - public function setResourceTracking($track) - { - $this->trackResources = (bool) $track; - } - /** - * Checks if resources are tracked. - * - * @return bool true If resources are tracked, false otherwise - */ - public function isTrackingResources() - { - return $this->trackResources; - } - /** - * Sets the instantiator to be used when fetching proxies. - */ - public function setProxyInstantiator(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\InstantiatorInterface $proxyInstantiator) - { - $this->proxyInstantiator = $proxyInstantiator; - } - public function registerExtension(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface $extension) - { - $this->extensions[$extension->getAlias()] = $extension; - if (\false !== $extension->getNamespace()) { - $this->extensionsByNs[$extension->getNamespace()] = $extension; - } - } - /** - * Returns an extension by alias or namespace. - * - * @param string $name An alias or a namespace - * - * @return ExtensionInterface An extension instance - * - * @throws LogicException if the extension is not registered - */ - public function getExtension($name) - { - if (isset($this->extensions[$name])) { - return $this->extensions[$name]; - } - if (isset($this->extensionsByNs[$name])) { - return $this->extensionsByNs[$name]; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException(\sprintf('Container extension "%s" is not registered.', $name)); - } - /** - * Returns all registered extensions. - * - * @return ExtensionInterface[] An array of ExtensionInterface - */ - public function getExtensions() - { - return $this->extensions; - } - /** - * Checks if we have an extension. - * - * @param string $name The name of the extension - * - * @return bool If the extension exists - */ - public function hasExtension($name) - { - return isset($this->extensions[$name]) || isset($this->extensionsByNs[$name]); - } - /** - * Returns an array of resources loaded to build this configuration. - * - * @return ResourceInterface[] An array of resources - */ - public function getResources() - { - return \array_values($this->resources); - } - /** - * @return $this - */ - public function addResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $resource) - { - if (!$this->trackResources) { - return $this; - } - if ($resource instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource && $this->inVendors($resource->getPrefix())) { - return $this; - } - $this->resources[(string) $resource] = $resource; - return $this; - } - /** - * Sets the resources for this configuration. - * - * @param ResourceInterface[] $resources An array of resources - * - * @return $this - */ - public function setResources(array $resources) - { - if (!$this->trackResources) { - return $this; - } - $this->resources = $resources; - return $this; - } - /** - * Adds the object class hierarchy as resources. - * - * @param object|string $object An object instance or class name - * - * @return $this - */ - public function addObjectResource($object) - { - if ($this->trackResources) { - if (\is_object($object)) { - $object = \get_class($object); - } - if (!isset($this->classReflectors[$object])) { - $this->classReflectors[$object] = new \ReflectionClass($object); - } - $class = $this->classReflectors[$object]; - foreach ($class->getInterfaceNames() as $name) { - if (null === ($interface =& $this->classReflectors[$name])) { - $interface = new \ReflectionClass($name); - } - $file = $interface->getFileName(); - if (\false !== $file && \file_exists($file)) { - $this->fileExists($file); - } - } - do { - $file = $class->getFileName(); - if (\false !== $file && \file_exists($file)) { - $this->fileExists($file); - } - foreach ($class->getTraitNames() as $name) { - $this->addObjectResource($name); - } - } while ($class = $class->getParentClass()); - } - return $this; - } - /** - * Adds the given class hierarchy as resources. - * - * @return $this - * - * @deprecated since version 3.3, to be removed in 4.0. Use addObjectResource() or getReflectionClass() instead. - */ - public function addClassResource(\ReflectionClass $class) - { - @\trigger_error('The ' . __METHOD__ . '() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the addObjectResource() or the getReflectionClass() method instead.', \E_USER_DEPRECATED); - return $this->addObjectResource($class->name); - } - /** - * Retrieves the requested reflection class and registers it for resource tracking. - * - * @param string $class - * @param bool $throw - * - * @return \ReflectionClass|null - * - * @throws \ReflectionException when a parent class/interface/trait is not found and $throw is true - * - * @final - */ - public function getReflectionClass($class, $throw = \true) - { - if (!($class = $this->getParameterBag()->resolveValue($class))) { - return null; - } - if (isset(self::$internalTypes[$class])) { - return null; - } - $resource = $classReflector = null; - try { - if (isset($this->classReflectors[$class])) { - $classReflector = $this->classReflectors[$class]; - } elseif (\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource::class)) { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource($class, \false); - $classReflector = $resource->isFresh(0) ? \false : new \ReflectionClass($class); - } else { - $classReflector = \class_exists($class) ? new \ReflectionClass($class) : \false; - } - } catch (\ReflectionException $e) { - if ($throw) { - throw $e; - } - } - if ($this->trackResources) { - if (!$classReflector) { - $this->addResource($resource ?: new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource($class, \false)); - } elseif (!$classReflector->isInternal()) { - $path = $classReflector->getFileName(); - if (!$this->inVendors($path)) { - $this->addResource(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource($classReflector, $this->vendors)); - } - } - $this->classReflectors[$class] = $classReflector; - } - return $classReflector ?: null; - } - /** - * Checks whether the requested file or directory exists and registers the result for resource tracking. - * - * @param string $path The file or directory path for which to check the existence - * @param bool|string $trackContents Whether to track contents of the given resource. If a string is passed, - * it will be used as pattern for tracking contents of the requested directory - * - * @return bool - * - * @final - */ - public function fileExists($path, $trackContents = \true) - { - $exists = \file_exists($path); - if (!$this->trackResources || $this->inVendors($path)) { - return $exists; - } - if (!$exists) { - $this->addResource(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource($path)); - return $exists; - } - if (\is_dir($path)) { - if ($trackContents) { - $this->addResource(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($path, \is_string($trackContents) ? $trackContents : null)); - } else { - $this->addResource(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($path, '/*', \false)); - } - } elseif ($trackContents) { - $this->addResource(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource($path)); - } - return $exists; - } - /** - * Loads the configuration for an extension. - * - * @param string $extension The extension alias or namespace - * @param array $values An array of values that customizes the extension - * - * @return $this - * - * @throws BadMethodCallException When this ContainerBuilder is compiled - * @throws \LogicException if the extension is not registered - */ - public function loadFromExtension($extension, array $values = null) - { - if ($this->isCompiled()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('Cannot load from an extension on a compiled container.'); - } - if (\func_num_args() < 2) { - $values = []; - } - $namespace = $this->getExtension($extension)->getAlias(); - $this->extensionConfigs[$namespace][] = $values; - return $this; - } - /** - * Adds a compiler pass. - * - * @param CompilerPassInterface $pass A compiler pass - * @param string $type The type of compiler pass - * @param int $priority Used to sort the passes - * - * @return $this - */ - public function addCompilerPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $type = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION) - { - if (\func_num_args() >= 3) { - $priority = \func_get_arg(2); - } else { - if (__CLASS__ !== static::class) { - $r = new \ReflectionMethod($this, __FUNCTION__); - if (__CLASS__ !== $r->getDeclaringClass()->getName()) { - @\trigger_error(\sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since Symfony 3.2.', __METHOD__), \E_USER_DEPRECATED); - } - } - $priority = 0; - } - $this->getCompiler()->addPass($pass, $type, $priority); - $this->addObjectResource($pass); - return $this; - } - /** - * Returns the compiler pass config which can then be modified. - * - * @return PassConfig The compiler pass config - */ - public function getCompilerPassConfig() - { - return $this->getCompiler()->getPassConfig(); - } - /** - * Returns the compiler. - * - * @return Compiler The compiler - */ - public function getCompiler() - { - if (null === $this->compiler) { - $this->compiler = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\Compiler(); - } - return $this->compiler; - } - /** - * Sets a service. - * - * @param string $id The service identifier - * @param object|null $service The service instance - * - * @throws BadMethodCallException When this ContainerBuilder is compiled - */ - public function set($id, $service) - { - $id = $this->normalizeId($id); - if ($this->isCompiled() && (isset($this->definitions[$id]) && !$this->definitions[$id]->isSynthetic())) { - // setting a synthetic service on a compiled container is alright - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException(\sprintf('Setting service "%s" for an unknown or non-synthetic service definition on a compiled container is not allowed.', $id)); - } - unset($this->definitions[$id], $this->aliasDefinitions[$id], $this->removedIds[$id]); - parent::set($id, $service); - } - /** - * Removes a service definition. - * - * @param string $id The service identifier - */ - public function removeDefinition($id) - { - if (isset($this->definitions[$id = $this->normalizeId($id)])) { - unset($this->definitions[$id]); - $this->removedIds[$id] = \true; - } - } - /** - * Returns true if the given service is defined. - * - * @param string $id The service identifier - * - * @return bool true if the service is defined, false otherwise - */ - public function has($id) - { - $id = $this->normalizeId($id); - return isset($this->definitions[$id]) || isset($this->aliasDefinitions[$id]) || parent::has($id); - } - /** - * Gets a service. - * - * @param string $id The service identifier - * @param int $invalidBehavior The behavior when the service does not exist - * - * @return object|null The associated service - * - * @throws InvalidArgumentException when no definitions are available - * @throws ServiceCircularReferenceException When a circular reference is detected - * @throws ServiceNotFoundException When the service is not defined - * @throws \Exception - * - * @see Reference - */ - public function get($id, $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE) - { - if ($this->isCompiled() && isset($this->removedIds[$id = $this->normalizeId($id)])) { - @\trigger_error(\sprintf('Fetching the "%s" private service or alias is deprecated since Symfony 3.4 and will fail in 4.0. Make it public instead.', $id), \E_USER_DEPRECATED); - } - return $this->doGet($id, $invalidBehavior); - } - private function doGet($id, $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE, array &$inlineServices = null, $isConstructorArgument = \false) - { - $id = $this->normalizeId($id); - if (isset($inlineServices[$id])) { - return $inlineServices[$id]; - } - if (null === $inlineServices) { - $isConstructorArgument = \true; - $inlineServices = []; - } - try { - if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE === $invalidBehavior) { - return parent::get($id, $invalidBehavior); - } - if ($service = parent::get($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE)) { - return $service; - } - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException $e) { - if ($isConstructorArgument) { - throw $e; - } - } - if (!isset($this->definitions[$id]) && isset($this->aliasDefinitions[$id])) { - return $this->doGet((string) $this->aliasDefinitions[$id], $invalidBehavior, $inlineServices, $isConstructorArgument); - } - try { - $definition = $this->getDefinition($id); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException $e) { - if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE !== $invalidBehavior) { - return null; - } - throw $e; - } - if ($isConstructorArgument) { - $this->loading[$id] = \true; - } - try { - return $this->createService($definition, $inlineServices, $isConstructorArgument, $id); - } finally { - if ($isConstructorArgument) { - unset($this->loading[$id]); - } - } - } - /** - * Merges a ContainerBuilder with the current ContainerBuilder configuration. - * - * Service definitions overrides the current defined ones. - * - * But for parameters, they are overridden by the current ones. It allows - * the parameters passed to the container constructor to have precedence - * over the loaded ones. - * - * $container = new ContainerBuilder(new ParameterBag(['foo' => 'bar'])); - * $loader = new LoaderXXX($container); - * $loader->load('resource_name'); - * $container->register('foo', 'stdClass'); - * - * In the above example, even if the loaded resource defines a foo - * parameter, the value will still be 'bar' as defined in the ContainerBuilder - * constructor. - * - * @throws BadMethodCallException When this ContainerBuilder is compiled - */ - public function merge(self $container) - { - if ($this->isCompiled()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('Cannot merge on a compiled container.'); - } - $this->addDefinitions($container->getDefinitions()); - $this->addAliases($container->getAliases()); - $this->getParameterBag()->add($container->getParameterBag()->all()); - if ($this->trackResources) { - foreach ($container->getResources() as $resource) { - $this->addResource($resource); - } - } - foreach ($this->extensions as $name => $extension) { - if (!isset($this->extensionConfigs[$name])) { - $this->extensionConfigs[$name] = []; - } - $this->extensionConfigs[$name] = \array_merge($this->extensionConfigs[$name], $container->getExtensionConfig($name)); - } - if ($this->getParameterBag() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag && $container->getParameterBag() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { - $envPlaceholders = $container->getParameterBag()->getEnvPlaceholders(); - $this->getParameterBag()->mergeEnvPlaceholders($container->getParameterBag()); - } else { - $envPlaceholders = []; - } - foreach ($container->envCounters as $env => $count) { - if (!$count && !isset($envPlaceholders[$env])) { - continue; - } - if (!isset($this->envCounters[$env])) { - $this->envCounters[$env] = $count; - } else { - $this->envCounters[$env] += $count; - } - } - foreach ($container->getAutoconfiguredInstanceof() as $interface => $childDefinition) { - if (isset($this->autoconfiguredInstanceof[$interface])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"%s" has already been autoconfigured and merge() does not support merging autoconfiguration for the same class/interface.', $interface)); - } - $this->autoconfiguredInstanceof[$interface] = $childDefinition; - } - } - /** - * Returns the configuration array for the given extension. - * - * @param string $name The name of the extension - * - * @return array An array of configuration - */ - public function getExtensionConfig($name) - { - if (!isset($this->extensionConfigs[$name])) { - $this->extensionConfigs[$name] = []; - } - return $this->extensionConfigs[$name]; - } - /** - * Prepends a config array to the configs of the given extension. - * - * @param string $name The name of the extension - * @param array $config The config to set - */ - public function prependExtensionConfig($name, array $config) - { - if (!isset($this->extensionConfigs[$name])) { - $this->extensionConfigs[$name] = []; - } - \array_unshift($this->extensionConfigs[$name], $config); - } - /** - * Compiles the container. - * - * This method passes the container to compiler - * passes whose job is to manipulate and optimize - * the container. - * - * The main compiler passes roughly do four things: - * - * * The extension configurations are merged; - * * Parameter values are resolved; - * * The parameter bag is frozen; - * * Extension loading is disabled. - * - * @param bool $resolveEnvPlaceholders Whether %env()% parameters should be resolved using the current - * env vars or be replaced by uniquely identifiable placeholders. - * Set to "true" when you want to use the current ContainerBuilder - * directly, keep to "false" when the container is dumped instead. - */ - public function compile() - { - if (1 <= \func_num_args()) { - $resolveEnvPlaceholders = \func_get_arg(0); - } else { - if (__CLASS__ !== static::class) { - $r = new \ReflectionMethod($this, __FUNCTION__); - if (__CLASS__ !== $r->getDeclaringClass()->getName() && (1 > $r->getNumberOfParameters() || 'resolveEnvPlaceholders' !== $r->getParameters()[0]->name)) { - @\trigger_error(\sprintf('The %s::compile() method expects a first "$resolveEnvPlaceholders" argument since Symfony 3.3. It will be made mandatory in 4.0.', static::class), \E_USER_DEPRECATED); - } - } - $resolveEnvPlaceholders = \false; - } - $compiler = $this->getCompiler(); - if ($this->trackResources) { - foreach ($compiler->getPassConfig()->getPasses() as $pass) { - $this->addObjectResource($pass); - } - } - $bag = $this->getParameterBag(); - if ($resolveEnvPlaceholders && $bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { - $compiler->addPass(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveEnvPlaceholdersPass(), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_AFTER_REMOVING, -1000); - } - $compiler->compile($this); - foreach ($this->definitions as $id => $definition) { - if ($this->trackResources && $definition->isLazy()) { - $this->getReflectionClass($definition->getClass()); - } - } - $this->extensionConfigs = []; - if ($bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { - if ($resolveEnvPlaceholders) { - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($this->resolveEnvPlaceholders($bag->all(), \true)); - } - $this->envPlaceholders = $bag->getEnvPlaceholders(); - } - parent::compile(); - foreach ($this->definitions + $this->aliasDefinitions as $id => $definition) { - if (!$definition->isPublic() || $definition->isPrivate()) { - $this->removedIds[$id] = \true; - } - } - } - /** - * {@inheritdoc} - */ - public function getServiceIds() - { - return \array_map('strval', \array_unique(\array_merge(\array_keys($this->getDefinitions()), \array_keys($this->aliasDefinitions), parent::getServiceIds()))); - } - /** - * Gets removed service or alias ids. - * - * @return array - */ - public function getRemovedIds() - { - return $this->removedIds; - } - /** - * Adds the service aliases. - */ - public function addAliases(array $aliases) - { - foreach ($aliases as $alias => $id) { - $this->setAlias($alias, $id); - } - } - /** - * Sets the service aliases. - */ - public function setAliases(array $aliases) - { - $this->aliasDefinitions = []; - $this->addAliases($aliases); - } - /** - * Sets an alias for an existing service. - * - * @param string $alias The alias to create - * @param string|Alias $id The service to alias - * - * @return Alias - * - * @throws InvalidArgumentException if the id is not a string or an Alias - * @throws InvalidArgumentException if the alias is for itself - */ - public function setAlias($alias, $id) - { - $alias = $this->normalizeId($alias); - if ('' === $alias || '\\' === \substr($alias, -1) || \strlen($alias) !== \strcspn($alias, "\0\r\n'")) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid alias id: "%s".', $alias)); - } - if (\is_string($id)) { - $id = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($this->normalizeId($id)); - } elseif (!$id instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('$id must be a string, or an Alias object.'); - } - if ($alias === (string) $id) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('An alias can not reference itself, got a circular reference on "%s".', $alias)); - } - unset($this->definitions[$alias], $this->removedIds[$alias]); - return $this->aliasDefinitions[$alias] = $id; - } - /** - * Removes an alias. - * - * @param string $alias The alias to remove - */ - public function removeAlias($alias) - { - if (isset($this->aliasDefinitions[$alias = $this->normalizeId($alias)])) { - unset($this->aliasDefinitions[$alias]); - $this->removedIds[$alias] = \true; - } - } - /** - * Returns true if an alias exists under the given identifier. - * - * @param string $id The service identifier - * - * @return bool true if the alias exists, false otherwise - */ - public function hasAlias($id) - { - return isset($this->aliasDefinitions[$this->normalizeId($id)]); - } - /** - * Gets all defined aliases. - * - * @return Alias[] An array of aliases - */ - public function getAliases() - { - return $this->aliasDefinitions; - } - /** - * Gets an alias. - * - * @param string $id The service identifier - * - * @return Alias An Alias instance - * - * @throws InvalidArgumentException if the alias does not exist - */ - public function getAlias($id) - { - $id = $this->normalizeId($id); - if (!isset($this->aliasDefinitions[$id])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service alias "%s" does not exist.', $id)); - } - return $this->aliasDefinitions[$id]; - } - /** - * Registers a service definition. - * - * This methods allows for simple registration of service definition - * with a fluid interface. - * - * @param string $id The service identifier - * @param string|null $class The service class - * - * @return Definition A Definition instance - */ - public function register($id, $class = null) - { - return $this->setDefinition($id, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($class)); - } - /** - * Registers an autowired service definition. - * - * This method implements a shortcut for using setDefinition() with - * an autowired definition. - * - * @param string $id The service identifier - * @param string|null $class The service class - * - * @return Definition The created definition - */ - public function autowire($id, $class = null) - { - return $this->setDefinition($id, (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($class))->setAutowired(\true)); - } - /** - * Adds the service definitions. - * - * @param Definition[] $definitions An array of service definitions - */ - public function addDefinitions(array $definitions) - { - foreach ($definitions as $id => $definition) { - $this->setDefinition($id, $definition); - } - } - /** - * Sets the service definitions. - * - * @param Definition[] $definitions An array of service definitions - */ - public function setDefinitions(array $definitions) - { - $this->definitions = []; - $this->addDefinitions($definitions); - } - /** - * Gets all service definitions. - * - * @return Definition[] An array of Definition instances - */ - public function getDefinitions() - { - return $this->definitions; - } - /** - * Sets a service definition. - * - * @param string $id The service identifier - * @param Definition $definition A Definition instance - * - * @return Definition the service definition - * - * @throws BadMethodCallException When this ContainerBuilder is compiled - */ - public function setDefinition($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - if ($this->isCompiled()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('Adding definition to a compiled container is not allowed.'); - } - $id = $this->normalizeId($id); - if ('' === $id || '\\' === \substr($id, -1) || \strlen($id) !== \strcspn($id, "\0\r\n'")) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid service id: "%s".', $id)); - } - unset($this->aliasDefinitions[$id], $this->removedIds[$id]); - return $this->definitions[$id] = $definition; - } - /** - * Returns true if a service definition exists under the given identifier. - * - * @param string $id The service identifier - * - * @return bool true if the service definition exists, false otherwise - */ - public function hasDefinition($id) - { - return isset($this->definitions[$this->normalizeId($id)]); - } - /** - * Gets a service definition. - * - * @param string $id The service identifier - * - * @return Definition A Definition instance - * - * @throws ServiceNotFoundException if the service definition does not exist - */ - public function getDefinition($id) - { - $id = $this->normalizeId($id); - if (!isset($this->definitions[$id])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id); - } - return $this->definitions[$id]; - } - /** - * Gets a service definition by id or alias. - * - * The method "unaliases" recursively to return a Definition instance. - * - * @param string $id The service identifier or alias - * - * @return Definition A Definition instance - * - * @throws ServiceNotFoundException if the service definition does not exist - */ - public function findDefinition($id) - { - $id = $this->normalizeId($id); - $seen = []; - while (isset($this->aliasDefinitions[$id])) { - $id = (string) $this->aliasDefinitions[$id]; - if (isset($seen[$id])) { - $seen = \array_values($seen); - $seen = \array_slice($seen, \array_search($id, $seen)); - $seen[] = $id; - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, $seen); - } - $seen[$id] = $id; - } - return $this->getDefinition($id); - } - /** - * Creates a service for a service definition. - * - * @param Definition $definition A service definition instance - * @param string $id The service identifier - * @param bool $tryProxy Whether to try proxying the service with a lazy proxy - * - * @return mixed The service described by the service definition - * - * @throws RuntimeException When the factory definition is incomplete - * @throws RuntimeException When the service is a synthetic service - * @throws InvalidArgumentException When configure callable is not callable - */ - private function createService(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, array &$inlineServices, $isConstructorArgument = \false, $id = null, $tryProxy = \true) - { - if (null === $id && isset($inlineServices[$h = \spl_object_hash($definition)])) { - return $inlineServices[$h]; - } - if ($definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Constructing service "%s" from a parent definition is not supported at build time.', $id)); - } - if ($definition->isSynthetic()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('You have requested a synthetic service ("%s"). The DIC does not know how to construct this service.', $id)); - } - if ($definition->isDeprecated()) { - @\trigger_error($definition->getDeprecationMessage($id), \E_USER_DEPRECATED); - } - if ($tryProxy && $definition->isLazy() && !($tryProxy = !($proxy = $this->proxyInstantiator) || $proxy instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator)) { - $proxy = $proxy->instantiateProxy($this, $definition, $id, function () use($definition, &$inlineServices, $id) { - return $this->createService($definition, $inlineServices, \true, $id, \false); - }); - $this->shareService($definition, $proxy, $id, $inlineServices); - return $proxy; - } - $parameterBag = $this->getParameterBag(); - if (null !== $definition->getFile()) { - require_once $parameterBag->resolveValue($definition->getFile()); - } - $arguments = $this->doResolveServices($parameterBag->unescapeValue($parameterBag->resolveValue($definition->getArguments())), $inlineServices, $isConstructorArgument); - if (null !== ($factory = $definition->getFactory())) { - if (\is_array($factory)) { - $factory = [$this->doResolveServices($parameterBag->resolveValue($factory[0]), $inlineServices, $isConstructorArgument), $factory[1]]; - } elseif (!\is_string($factory)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Cannot create service "%s" because of invalid factory.', $id)); - } - } - if (null !== $id && $definition->isShared() && isset($this->services[$id]) && ($tryProxy || !$definition->isLazy())) { - return $this->services[$id]; - } - if (null !== $factory) { - $service = \call_user_func_array($factory, $arguments); - if (!$definition->isDeprecated() && \is_array($factory) && \is_string($factory[0])) { - $r = new \ReflectionClass($factory[0]); - if (0 < \strpos($r->getDocComment(), "\n * @deprecated ")) { - @\trigger_error(\sprintf('The "%s" service relies on the deprecated "%s" factory class. It should either be deprecated or its factory upgraded.', $id, $r->name), \E_USER_DEPRECATED); - } - } - } else { - $r = new \ReflectionClass($class = $parameterBag->resolveValue($definition->getClass())); - $service = null === $r->getConstructor() ? $r->newInstance() : $r->newInstanceArgs($arguments); - // don't trigger deprecations for internal uses - // @deprecated since version 3.3, to be removed in 4.0 along with the deprecated class - $deprecationWhitelist = ['event_dispatcher' => \_PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\ContainerAwareEventDispatcher::class]; - if (!$definition->isDeprecated() && 0 < \strpos($r->getDocComment(), "\n * @deprecated ") && (!isset($deprecationWhitelist[$id]) || $deprecationWhitelist[$id] !== $class)) { - @\trigger_error(\sprintf('The "%s" service relies on the deprecated "%s" class. It should either be deprecated or its implementation upgraded.', $id, $r->name), \E_USER_DEPRECATED); - } - } - if ($tryProxy || !$definition->isLazy()) { - // share only if proxying failed, or if not a proxy - $this->shareService($definition, $service, $id, $inlineServices); - } - $properties = $this->doResolveServices($parameterBag->unescapeValue($parameterBag->resolveValue($definition->getProperties())), $inlineServices); - foreach ($properties as $name => $value) { - $service->{$name} = $value; - } - foreach ($definition->getMethodCalls() as $call) { - $this->callMethod($service, $call, $inlineServices); - } - if ($callable = $definition->getConfigurator()) { - if (\is_array($callable)) { - $callable[0] = $parameterBag->resolveValue($callable[0]); - if ($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $callable[0] = $this->doGet((string) $callable[0], $callable[0]->getInvalidBehavior(), $inlineServices); - } elseif ($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - $callable[0] = $this->createService($callable[0], $inlineServices); - } - } - if (!\is_callable($callable)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The configure callable for class "%s" is not a callable.', \get_class($service))); - } - \call_user_func($callable, $service); - } - return $service; - } - /** - * Replaces service references by the real service instance and evaluates expressions. - * - * @param mixed $value A value - * - * @return mixed The same value with all service references replaced by - * the real service instances and all expressions evaluated - */ - public function resolveServices($value) - { - return $this->doResolveServices($value); - } - private function doResolveServices($value, array &$inlineServices = [], $isConstructorArgument = \false) - { - if (\is_array($value)) { - foreach ($value as $k => $v) { - $value[$k] = $this->doResolveServices($v, $inlineServices, $isConstructorArgument); - } - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { - $reference = $value->getValues()[0]; - $value = function () use($reference) { - return $this->resolveServices($reference); - }; - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument) { - $value = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () use($value) { - foreach ($value->getValues() as $k => $v) { - foreach (self::getServiceConditionals($v) as $s) { - if (!$this->has($s)) { - continue 2; - } - } - foreach (self::getInitializedConditionals($v) as $s) { - if (!$this->doGet($s, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE)) { - continue 2; - } - } - (yield $k => $this->resolveServices($v)); - } - }, function () use($value) { - $count = 0; - foreach ($value->getValues() as $v) { - foreach (self::getServiceConditionals($v) as $s) { - if (!$this->has($s)) { - continue 2; - } - } - foreach (self::getInitializedConditionals($v) as $s) { - if (!$this->doGet($s, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE)) { - continue 2; - } - } - ++$count; - } - return $count; - }); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $value = $this->doGet((string) $value, $value->getInvalidBehavior(), $inlineServices, $isConstructorArgument); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - $value = $this->createService($value, $inlineServices, $isConstructorArgument); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { - $value = $this->getParameter((string) $value); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { - $value = $this->getExpressionLanguage()->evaluate($value, ['container' => $this]); - } - return $value; - } - /** - * Returns service ids for a given tag. - * - * Example: - * - * $container->register('foo')->addTag('my.tag', ['hello' => 'world']); - * - * $serviceIds = $container->findTaggedServiceIds('my.tag'); - * foreach ($serviceIds as $serviceId => $tags) { - * foreach ($tags as $tag) { - * echo $tag['hello']; - * } - * } - * - * @param string $name - * @param bool $throwOnAbstract - * - * @return array An array of tags with the tagged service as key, holding a list of attribute arrays - */ - public function findTaggedServiceIds($name, $throwOnAbstract = \false) - { - $this->usedTags[] = $name; - $tags = []; - foreach ($this->getDefinitions() as $id => $definition) { - if ($definition->hasTag($name)) { - if ($throwOnAbstract && $definition->isAbstract()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" tagged "%s" must not be abstract.', $id, $name)); - } - $tags[$id] = $definition->getTag($name); - } - } - return $tags; - } - /** - * Returns all tags the defined services use. - * - * @return array An array of tags - */ - public function findTags() - { - $tags = []; - foreach ($this->getDefinitions() as $id => $definition) { - $tags = \array_merge(\array_keys($definition->getTags()), $tags); - } - return \array_unique($tags); - } - /** - * Returns all tags not queried by findTaggedServiceIds. - * - * @return string[] An array of tags - */ - public function findUnusedTags() - { - return \array_values(\array_diff($this->findTags(), $this->usedTags)); - } - public function addExpressionLanguageProvider(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface $provider) - { - $this->expressionLanguageProviders[] = $provider; - } - /** - * @return ExpressionFunctionProviderInterface[] - */ - public function getExpressionLanguageProviders() - { - return $this->expressionLanguageProviders; - } - /** - * Returns a ChildDefinition that will be used for autoconfiguring the interface/class. - * - * @param string $interface The class or interface to match - * - * @return ChildDefinition - */ - public function registerForAutoconfiguration($interface) - { - if (!isset($this->autoconfiguredInstanceof[$interface])) { - $this->autoconfiguredInstanceof[$interface] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''); - } - return $this->autoconfiguredInstanceof[$interface]; - } - /** - * Returns an array of ChildDefinition[] keyed by interface. - * - * @return ChildDefinition[] - */ - public function getAutoconfiguredInstanceof() - { - return $this->autoconfiguredInstanceof; - } - /** - * Resolves env parameter placeholders in a string or an array. - * - * @param mixed $value The value to resolve - * @param string|true|null $format A sprintf() format returning the replacement for each env var name or - * null to resolve back to the original "%env(VAR)%" format or - * true to resolve to the actual values of the referenced env vars - * @param array &$usedEnvs Env vars found while resolving are added to this array - * - * @return mixed The value with env parameters resolved if a string or an array is passed - */ - public function resolveEnvPlaceholders($value, $format = null, array &$usedEnvs = null) - { - if (null === $format) { - $format = '%%env(%s)%%'; - } - $bag = $this->getParameterBag(); - if (\true === $format) { - $value = $bag->resolveValue($value); - } - if (\is_array($value)) { - $result = []; - foreach ($value as $k => $v) { - $result[\is_string($k) ? $this->resolveEnvPlaceholders($k, $format, $usedEnvs) : $k] = $this->resolveEnvPlaceholders($v, $format, $usedEnvs); - } - return $result; - } - if (!\is_string($value) || 38 > \strlen($value)) { - return $value; - } - $envPlaceholders = $bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag ? $bag->getEnvPlaceholders() : $this->envPlaceholders; - $completed = \false; - foreach ($envPlaceholders as $env => $placeholders) { - foreach ($placeholders as $placeholder) { - if (\false !== \stripos($value, $placeholder)) { - if (\true === $format) { - $resolved = $bag->escapeValue($this->getEnv($env)); - } else { - $resolved = \sprintf($format, $env); - } - if ($placeholder === $value) { - $value = $resolved; - $completed = \true; - } else { - if (!\is_string($resolved) && !\is_numeric($resolved)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('A string value must be composed of strings and/or numbers, but found parameter "env(%s)" of type "%s" inside string value "%s".', $env, \gettype($resolved), $this->resolveEnvPlaceholders($value))); - } - $value = \str_ireplace($placeholder, $resolved, $value); - } - $usedEnvs[$env] = $env; - $this->envCounters[$env] = isset($this->envCounters[$env]) ? 1 + $this->envCounters[$env] : 1; - if ($completed) { - break 2; - } - } - } - } - return $value; - } - /** - * Get statistics about env usage. - * - * @return int[] The number of time each env vars has been resolved - */ - public function getEnvCounters() - { - $bag = $this->getParameterBag(); - $envPlaceholders = $bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag ? $bag->getEnvPlaceholders() : $this->envPlaceholders; - foreach ($envPlaceholders as $env => $placeholders) { - if (!isset($this->envCounters[$env])) { - $this->envCounters[$env] = 0; - } - } - return $this->envCounters; - } - /** - * @internal - */ - public function getNormalizedIds() - { - $normalizedIds = []; - foreach ($this->normalizedIds as $k => $v) { - if ($v !== (string) $k) { - $normalizedIds[$k] = $v; - } - } - return $normalizedIds; - } - /** - * @final - */ - public function log(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $message) - { - $this->getCompiler()->log($pass, $this->resolveEnvPlaceholders($message)); - } - /** - * {@inheritdoc} - */ - public function normalizeId($id) - { - if (!\is_string($id)) { - $id = (string) $id; - } - return isset($this->definitions[$id]) || isset($this->aliasDefinitions[$id]) || isset($this->removedIds[$id]) ? $id : parent::normalizeId($id); - } - /** - * Gets removed binding ids. - * - * @return array - * - * @internal - */ - public function getRemovedBindingIds() - { - return $this->removedBindingIds; - } - /** - * Removes bindings for a service. - * - * @param string $id The service identifier - * - * @internal - */ - public function removeBindings($id) - { - if ($this->hasDefinition($id)) { - foreach ($this->getDefinition($id)->getBindings() as $key => $binding) { - list(, $bindingId) = $binding->getValues(); - $this->removedBindingIds[(int) $bindingId] = \true; - } - } - } - /** - * Returns the Service Conditionals. - * - * @param mixed $value An array of conditionals to return - * - * @return array An array of Service conditionals - * - * @internal since version 3.4 - */ - public static function getServiceConditionals($value) - { - $services = []; - if (\is_array($value)) { - foreach ($value as $v) { - $services = \array_unique(\array_merge($services, self::getServiceConditionals($v))); - } - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE === $value->getInvalidBehavior()) { - $services[] = (string) $value; - } - return $services; - } - /** - * Returns the initialized conditionals. - * - * @param mixed $value An array of conditionals to return - * - * @return array An array of uninitialized conditionals - * - * @internal - */ - public static function getInitializedConditionals($value) - { - $services = []; - if (\is_array($value)) { - foreach ($value as $v) { - $services = \array_unique(\array_merge($services, self::getInitializedConditionals($v))); - } - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE === $value->getInvalidBehavior()) { - $services[] = (string) $value; - } - return $services; - } - /** - * Computes a reasonably unique hash of a value. - * - * @param mixed $value A serializable value - * - * @return string - */ - public static function hash($value) - { - $hash = \substr(\base64_encode(\hash('sha256', \serialize($value), \true)), 0, 7); - return \str_replace(['/', '+'], ['.', '_'], \strtolower($hash)); - } - /** - * {@inheritdoc} - */ - protected function getEnv($name) - { - $value = parent::getEnv($name); - $bag = $this->getParameterBag(); - if (!\is_string($value) || !$bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { - return $value; - } - foreach ($bag->getEnvPlaceholders() as $env => $placeholders) { - if (isset($placeholders[$value])) { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($bag->all()); - return $bag->unescapeValue($bag->get("env({$name})")); - } - } - $this->resolving["env({$name})"] = \true; - try { - return $bag->unescapeValue($this->resolveEnvPlaceholders($bag->escapeValue($value), \true)); - } finally { - unset($this->resolving["env({$name})"]); - } - } - private function callMethod($service, $call, array &$inlineServices) - { - foreach (self::getServiceConditionals($call[1]) as $s) { - if (!$this->has($s)) { - return; - } - } - foreach (self::getInitializedConditionals($call[1]) as $s) { - if (!$this->doGet($s, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE, $inlineServices)) { - return; - } - } - \call_user_func_array([$service, $call[0]], $this->doResolveServices($this->getParameterBag()->unescapeValue($this->getParameterBag()->resolveValue($call[1])), $inlineServices)); - } - /** - * Shares a given service in the container. - * - * @param mixed $service - * @param string|null $id - */ - private function shareService(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $service, $id, array &$inlineServices) - { - $inlineServices[null !== $id ? $id : \spl_object_hash($definition)] = $service; - if (null !== $id && $definition->isShared()) { - $this->services[$id] = $service; - unset($this->loading[$id]); - } - } - private function getExpressionLanguage() - { - if (null === $this->expressionLanguage) { - if (!\class_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to use expressions as the Symfony ExpressionLanguage component is not installed.'); - } - $this->expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage(null, $this->expressionLanguageProviders); - } - return $this->expressionLanguage; - } - private function inVendors($path) - { - if (null === $this->vendors) { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource(); - $this->vendors = $resource->getVendors(); - $this->addResource($resource); - } - $path = \realpath($path) ?: $path; - foreach ($this->vendors as $vendor) { - if (0 === \strpos($path, $vendor) && \false !== \strpbrk(\substr($path, \strlen($vendor), 1), '/' . \DIRECTORY_SEPARATOR)) { - return \true; - } - } - return \false; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\Compiler; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveEnvPlaceholdersPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\InstantiatorInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\ContainerAwareEventDispatcher; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface; +/** + * ContainerBuilder is a DI container that provides an API to easily describe services. + * + * @author Fabien Potencier + */ +class ContainerBuilder extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TaggedContainerInterface +{ + /** + * @var ExtensionInterface[] + */ + private $extensions = []; + /** + * @var ExtensionInterface[] + */ + private $extensionsByNs = []; + /** + * @var Definition[] + */ + private $definitions = []; + /** + * @var Alias[] + */ + private $aliasDefinitions = []; + /** + * @var ResourceInterface[] + */ + private $resources = []; + private $extensionConfigs = []; + /** + * @var Compiler + */ + private $compiler; + private $trackResources; + /** + * @var InstantiatorInterface|null + */ + private $proxyInstantiator; + /** + * @var ExpressionLanguage|null + */ + private $expressionLanguage; + /** + * @var ExpressionFunctionProviderInterface[] + */ + private $expressionLanguageProviders = []; + /** + * @var string[] with tag names used by findTaggedServiceIds + */ + private $usedTags = []; + /** + * @var string[][] a map of env var names to their placeholders + */ + private $envPlaceholders = []; + /** + * @var int[] a map of env vars to their resolution counter + */ + private $envCounters = []; + /** + * @var string[] the list of vendor directories + */ + private $vendors; + private $autoconfiguredInstanceof = []; + private $removedIds = []; + private $removedBindingIds = []; + private static $internalTypes = ['int' => \true, 'float' => \true, 'string' => \true, 'bool' => \true, 'resource' => \true, 'object' => \true, 'array' => \true, 'null' => \true, 'callable' => \true, 'iterable' => \true, 'mixed' => \true]; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface $parameterBag = null) + { + parent::__construct($parameterBag); + $this->trackResources = \interface_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\ResourceInterface'); + $this->setDefinition('service_container', (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class))->setSynthetic(\true)->setPublic(\true)); + $this->setAlias(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('service_container', \false)); + $this->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('service_container', \false)); + } + /** + * @var \ReflectionClass[] a list of class reflectors + */ + private $classReflectors; + /** + * Sets the track resources flag. + * + * If you are not using the loaders and therefore don't want + * to depend on the Config component, set this flag to false. + * + * @param bool $track True if you want to track resources, false otherwise + */ + public function setResourceTracking($track) + { + $this->trackResources = (bool) $track; + } + /** + * Checks if resources are tracked. + * + * @return bool true If resources are tracked, false otherwise + */ + public function isTrackingResources() + { + return $this->trackResources; + } + /** + * Sets the instantiator to be used when fetching proxies. + */ + public function setProxyInstantiator(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\InstantiatorInterface $proxyInstantiator) + { + $this->proxyInstantiator = $proxyInstantiator; + } + public function registerExtension(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface $extension) + { + $this->extensions[$extension->getAlias()] = $extension; + if (\false !== $extension->getNamespace()) { + $this->extensionsByNs[$extension->getNamespace()] = $extension; + } + } + /** + * Returns an extension by alias or namespace. + * + * @param string $name An alias or a namespace + * + * @return ExtensionInterface An extension instance + * + * @throws LogicException if the extension is not registered + */ + public function getExtension($name) + { + if (isset($this->extensions[$name])) { + return $this->extensions[$name]; + } + if (isset($this->extensionsByNs[$name])) { + return $this->extensionsByNs[$name]; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException(\sprintf('Container extension "%s" is not registered.', $name)); + } + /** + * Returns all registered extensions. + * + * @return ExtensionInterface[] An array of ExtensionInterface + */ + public function getExtensions() + { + return $this->extensions; + } + /** + * Checks if we have an extension. + * + * @param string $name The name of the extension + * + * @return bool If the extension exists + */ + public function hasExtension($name) + { + return isset($this->extensions[$name]) || isset($this->extensionsByNs[$name]); + } + /** + * Returns an array of resources loaded to build this configuration. + * + * @return ResourceInterface[] An array of resources + */ + public function getResources() + { + return \array_values($this->resources); + } + /** + * @return $this + */ + public function addResource(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $resource) + { + if (!$this->trackResources) { + return $this; + } + if ($resource instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource && $this->inVendors($resource->getPrefix())) { + return $this; + } + $this->resources[(string) $resource] = $resource; + return $this; + } + /** + * Sets the resources for this configuration. + * + * @param ResourceInterface[] $resources An array of resources + * + * @return $this + */ + public function setResources(array $resources) + { + if (!$this->trackResources) { + return $this; + } + $this->resources = $resources; + return $this; + } + /** + * Adds the object class hierarchy as resources. + * + * @param object|string $object An object instance or class name + * + * @return $this + */ + public function addObjectResource($object) + { + if ($this->trackResources) { + if (\is_object($object)) { + $object = \get_class($object); + } + if (!isset($this->classReflectors[$object])) { + $this->classReflectors[$object] = new \ReflectionClass($object); + } + $class = $this->classReflectors[$object]; + foreach ($class->getInterfaceNames() as $name) { + if (null === ($interface =& $this->classReflectors[$name])) { + $interface = new \ReflectionClass($name); + } + $file = $interface->getFileName(); + if (\false !== $file && \file_exists($file)) { + $this->fileExists($file); + } + } + do { + $file = $class->getFileName(); + if (\false !== $file && \file_exists($file)) { + $this->fileExists($file); + } + foreach ($class->getTraitNames() as $name) { + $this->addObjectResource($name); + } + } while ($class = $class->getParentClass()); + } + return $this; + } + /** + * Adds the given class hierarchy as resources. + * + * @return $this + * + * @deprecated since version 3.3, to be removed in 4.0. Use addObjectResource() or getReflectionClass() instead. + */ + public function addClassResource(\ReflectionClass $class) + { + @\trigger_error('The ' . __METHOD__ . '() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the addObjectResource() or the getReflectionClass() method instead.', \E_USER_DEPRECATED); + return $this->addObjectResource($class->name); + } + /** + * Retrieves the requested reflection class and registers it for resource tracking. + * + * @param string $class + * @param bool $throw + * + * @return \ReflectionClass|null + * + * @throws \ReflectionException when a parent class/interface/trait is not found and $throw is true + * + * @final + */ + public function getReflectionClass($class, $throw = \true) + { + if (!($class = $this->getParameterBag()->resolveValue($class))) { + return null; + } + if (isset(self::$internalTypes[$class])) { + return null; + } + $resource = $classReflector = null; + try { + if (isset($this->classReflectors[$class])) { + $classReflector = $this->classReflectors[$class]; + } elseif (\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource::class)) { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource($class, \false); + $classReflector = $resource->isFresh(0) ? \false : new \ReflectionClass($class); + } else { + $classReflector = \class_exists($class) ? new \ReflectionClass($class) : \false; + } + } catch (\ReflectionException $e) { + if ($throw) { + throw $e; + } + } + if ($this->trackResources) { + if (!$classReflector) { + $this->addResource($resource ?: new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ClassExistenceResource($class, \false)); + } elseif (!$classReflector->isInternal()) { + $path = $classReflector->getFileName(); + if (!$this->inVendors($path)) { + $this->addResource(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ReflectionClassResource($classReflector, $this->vendors)); + } + } + $this->classReflectors[$class] = $classReflector; + } + return $classReflector ?: null; + } + /** + * Checks whether the requested file or directory exists and registers the result for resource tracking. + * + * @param string $path The file or directory path for which to check the existence + * @param bool|string $trackContents Whether to track contents of the given resource. If a string is passed, + * it will be used as pattern for tracking contents of the requested directory + * + * @return bool + * + * @final + */ + public function fileExists($path, $trackContents = \true) + { + $exists = \file_exists($path); + if (!$this->trackResources || $this->inVendors($path)) { + return $exists; + } + if (!$exists) { + $this->addResource(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileExistenceResource($path)); + return $exists; + } + if (\is_dir($path)) { + if ($trackContents) { + $this->addResource(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($path, \is_string($trackContents) ? $trackContents : null)); + } else { + $this->addResource(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($path, '/*', \false)); + } + } elseif ($trackContents) { + $this->addResource(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource($path)); + } + return $exists; + } + /** + * Loads the configuration for an extension. + * + * @param string $extension The extension alias or namespace + * @param array $values An array of values that customizes the extension + * + * @return $this + * + * @throws BadMethodCallException When this ContainerBuilder is compiled + * @throws \LogicException if the extension is not registered + */ + public function loadFromExtension($extension, array $values = null) + { + if ($this->isCompiled()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('Cannot load from an extension on a compiled container.'); + } + if (\func_num_args() < 2) { + $values = []; + } + $namespace = $this->getExtension($extension)->getAlias(); + $this->extensionConfigs[$namespace][] = $values; + return $this; + } + /** + * Adds a compiler pass. + * + * @param CompilerPassInterface $pass A compiler pass + * @param string $type The type of compiler pass + * @param int $priority Used to sort the passes + * + * @return $this + */ + public function addCompilerPass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $type = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION) + { + if (\func_num_args() >= 3) { + $priority = \func_get_arg(2); + } else { + if (__CLASS__ !== static::class) { + $r = new \ReflectionMethod($this, __FUNCTION__); + if (__CLASS__ !== $r->getDeclaringClass()->getName()) { + @\trigger_error(\sprintf('Method %s() will have a third `int $priority = 0` argument in version 4.0. Not defining it is deprecated since Symfony 3.2.', __METHOD__), \E_USER_DEPRECATED); + } + } + $priority = 0; + } + $this->getCompiler()->addPass($pass, $type, $priority); + $this->addObjectResource($pass); + return $this; + } + /** + * Returns the compiler pass config which can then be modified. + * + * @return PassConfig The compiler pass config + */ + public function getCompilerPassConfig() + { + return $this->getCompiler()->getPassConfig(); + } + /** + * Returns the compiler. + * + * @return Compiler The compiler + */ + public function getCompiler() + { + if (null === $this->compiler) { + $this->compiler = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\Compiler(); + } + return $this->compiler; + } + /** + * Sets a service. + * + * @param string $id The service identifier + * @param object|null $service The service instance + * + * @throws BadMethodCallException When this ContainerBuilder is compiled + */ + public function set($id, $service) + { + $id = $this->normalizeId($id); + if ($this->isCompiled() && (isset($this->definitions[$id]) && !$this->definitions[$id]->isSynthetic())) { + // setting a synthetic service on a compiled container is alright + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException(\sprintf('Setting service "%s" for an unknown or non-synthetic service definition on a compiled container is not allowed.', $id)); + } + unset($this->definitions[$id], $this->aliasDefinitions[$id], $this->removedIds[$id]); + parent::set($id, $service); + } + /** + * Removes a service definition. + * + * @param string $id The service identifier + */ + public function removeDefinition($id) + { + if (isset($this->definitions[$id = $this->normalizeId($id)])) { + unset($this->definitions[$id]); + $this->removedIds[$id] = \true; + } + } + /** + * Returns true if the given service is defined. + * + * @param string $id The service identifier + * + * @return bool true if the service is defined, false otherwise + */ + public function has($id) + { + $id = $this->normalizeId($id); + return isset($this->definitions[$id]) || isset($this->aliasDefinitions[$id]) || parent::has($id); + } + /** + * Gets a service. + * + * @param string $id The service identifier + * @param int $invalidBehavior The behavior when the service does not exist + * + * @return object|null The associated service + * + * @throws InvalidArgumentException when no definitions are available + * @throws ServiceCircularReferenceException When a circular reference is detected + * @throws ServiceNotFoundException When the service is not defined + * @throws \Exception + * + * @see Reference + */ + public function get($id, $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE) + { + if ($this->isCompiled() && isset($this->removedIds[$id = $this->normalizeId($id)])) { + @\trigger_error(\sprintf('Fetching the "%s" private service or alias is deprecated since Symfony 3.4 and will fail in 4.0. Make it public instead.', $id), \E_USER_DEPRECATED); + } + return $this->doGet($id, $invalidBehavior); + } + private function doGet($id, $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE, array &$inlineServices = null, $isConstructorArgument = \false) + { + $id = $this->normalizeId($id); + if (isset($inlineServices[$id])) { + return $inlineServices[$id]; + } + if (null === $inlineServices) { + $isConstructorArgument = \true; + $inlineServices = []; + } + try { + if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE === $invalidBehavior) { + return parent::get($id, $invalidBehavior); + } + if ($service = parent::get($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE)) { + return $service; + } + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException $e) { + if ($isConstructorArgument) { + throw $e; + } + } + if (!isset($this->definitions[$id]) && isset($this->aliasDefinitions[$id])) { + return $this->doGet((string) $this->aliasDefinitions[$id], $invalidBehavior, $inlineServices, $isConstructorArgument); + } + try { + $definition = $this->getDefinition($id); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException $e) { + if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE !== $invalidBehavior) { + return null; + } + throw $e; + } + if ($isConstructorArgument) { + $this->loading[$id] = \true; + } + try { + return $this->createService($definition, $inlineServices, $isConstructorArgument, $id); + } finally { + if ($isConstructorArgument) { + unset($this->loading[$id]); + } + } + } + /** + * Merges a ContainerBuilder with the current ContainerBuilder configuration. + * + * Service definitions overrides the current defined ones. + * + * But for parameters, they are overridden by the current ones. It allows + * the parameters passed to the container constructor to have precedence + * over the loaded ones. + * + * $container = new ContainerBuilder(new ParameterBag(['foo' => 'bar'])); + * $loader = new LoaderXXX($container); + * $loader->load('resource_name'); + * $container->register('foo', 'stdClass'); + * + * In the above example, even if the loaded resource defines a foo + * parameter, the value will still be 'bar' as defined in the ContainerBuilder + * constructor. + * + * @throws BadMethodCallException When this ContainerBuilder is compiled + */ + public function merge(self $container) + { + if ($this->isCompiled()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('Cannot merge on a compiled container.'); + } + $this->addDefinitions($container->getDefinitions()); + $this->addAliases($container->getAliases()); + $this->getParameterBag()->add($container->getParameterBag()->all()); + if ($this->trackResources) { + foreach ($container->getResources() as $resource) { + $this->addResource($resource); + } + } + foreach ($this->extensions as $name => $extension) { + if (!isset($this->extensionConfigs[$name])) { + $this->extensionConfigs[$name] = []; + } + $this->extensionConfigs[$name] = \array_merge($this->extensionConfigs[$name], $container->getExtensionConfig($name)); + } + if ($this->getParameterBag() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag && $container->getParameterBag() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { + $envPlaceholders = $container->getParameterBag()->getEnvPlaceholders(); + $this->getParameterBag()->mergeEnvPlaceholders($container->getParameterBag()); + } else { + $envPlaceholders = []; + } + foreach ($container->envCounters as $env => $count) { + if (!$count && !isset($envPlaceholders[$env])) { + continue; + } + if (!isset($this->envCounters[$env])) { + $this->envCounters[$env] = $count; + } else { + $this->envCounters[$env] += $count; + } + } + foreach ($container->getAutoconfiguredInstanceof() as $interface => $childDefinition) { + if (isset($this->autoconfiguredInstanceof[$interface])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"%s" has already been autoconfigured and merge() does not support merging autoconfiguration for the same class/interface.', $interface)); + } + $this->autoconfiguredInstanceof[$interface] = $childDefinition; + } + } + /** + * Returns the configuration array for the given extension. + * + * @param string $name The name of the extension + * + * @return array An array of configuration + */ + public function getExtensionConfig($name) + { + if (!isset($this->extensionConfigs[$name])) { + $this->extensionConfigs[$name] = []; + } + return $this->extensionConfigs[$name]; + } + /** + * Prepends a config array to the configs of the given extension. + * + * @param string $name The name of the extension + * @param array $config The config to set + */ + public function prependExtensionConfig($name, array $config) + { + if (!isset($this->extensionConfigs[$name])) { + $this->extensionConfigs[$name] = []; + } + \array_unshift($this->extensionConfigs[$name], $config); + } + /** + * Compiles the container. + * + * This method passes the container to compiler + * passes whose job is to manipulate and optimize + * the container. + * + * The main compiler passes roughly do four things: + * + * * The extension configurations are merged; + * * Parameter values are resolved; + * * The parameter bag is frozen; + * * Extension loading is disabled. + * + * @param bool $resolveEnvPlaceholders Whether %env()% parameters should be resolved using the current + * env vars or be replaced by uniquely identifiable placeholders. + * Set to "true" when you want to use the current ContainerBuilder + * directly, keep to "false" when the container is dumped instead. + */ + public function compile() + { + if (1 <= \func_num_args()) { + $resolveEnvPlaceholders = \func_get_arg(0); + } else { + if (__CLASS__ !== static::class) { + $r = new \ReflectionMethod($this, __FUNCTION__); + if (__CLASS__ !== $r->getDeclaringClass()->getName() && (1 > $r->getNumberOfParameters() || 'resolveEnvPlaceholders' !== $r->getParameters()[0]->name)) { + @\trigger_error(\sprintf('The %s::compile() method expects a first "$resolveEnvPlaceholders" argument since Symfony 3.3. It will be made mandatory in 4.0.', static::class), \E_USER_DEPRECATED); + } + } + $resolveEnvPlaceholders = \false; + } + $compiler = $this->getCompiler(); + if ($this->trackResources) { + foreach ($compiler->getPassConfig()->getPasses() as $pass) { + $this->addObjectResource($pass); + } + } + $bag = $this->getParameterBag(); + if ($resolveEnvPlaceholders && $bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { + $compiler->addPass(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveEnvPlaceholdersPass(), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_AFTER_REMOVING, -1000); + } + $compiler->compile($this); + foreach ($this->definitions as $id => $definition) { + if ($this->trackResources && $definition->isLazy()) { + $this->getReflectionClass($definition->getClass()); + } + } + $this->extensionConfigs = []; + if ($bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { + if ($resolveEnvPlaceholders) { + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($this->resolveEnvPlaceholders($bag->all(), \true)); + } + $this->envPlaceholders = $bag->getEnvPlaceholders(); + } + parent::compile(); + foreach ($this->definitions + $this->aliasDefinitions as $id => $definition) { + if (!$definition->isPublic() || $definition->isPrivate()) { + $this->removedIds[$id] = \true; + } + } + } + /** + * {@inheritdoc} + */ + public function getServiceIds() + { + return \array_map('strval', \array_unique(\array_merge(\array_keys($this->getDefinitions()), \array_keys($this->aliasDefinitions), parent::getServiceIds()))); + } + /** + * Gets removed service or alias ids. + * + * @return array + */ + public function getRemovedIds() + { + return $this->removedIds; + } + /** + * Adds the service aliases. + */ + public function addAliases(array $aliases) + { + foreach ($aliases as $alias => $id) { + $this->setAlias($alias, $id); + } + } + /** + * Sets the service aliases. + */ + public function setAliases(array $aliases) + { + $this->aliasDefinitions = []; + $this->addAliases($aliases); + } + /** + * Sets an alias for an existing service. + * + * @param string $alias The alias to create + * @param string|Alias $id The service to alias + * + * @return Alias + * + * @throws InvalidArgumentException if the id is not a string or an Alias + * @throws InvalidArgumentException if the alias is for itself + */ + public function setAlias($alias, $id) + { + $alias = $this->normalizeId($alias); + if ('' === $alias || '\\' === \substr($alias, -1) || \strlen($alias) !== \strcspn($alias, "\0\r\n'")) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid alias id: "%s".', $alias)); + } + if (\is_string($id)) { + $id = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($this->normalizeId($id)); + } elseif (!$id instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('$id must be a string, or an Alias object.'); + } + if ($alias === (string) $id) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('An alias can not reference itself, got a circular reference on "%s".', $alias)); + } + unset($this->definitions[$alias], $this->removedIds[$alias]); + return $this->aliasDefinitions[$alias] = $id; + } + /** + * Removes an alias. + * + * @param string $alias The alias to remove + */ + public function removeAlias($alias) + { + if (isset($this->aliasDefinitions[$alias = $this->normalizeId($alias)])) { + unset($this->aliasDefinitions[$alias]); + $this->removedIds[$alias] = \true; + } + } + /** + * Returns true if an alias exists under the given identifier. + * + * @param string $id The service identifier + * + * @return bool true if the alias exists, false otherwise + */ + public function hasAlias($id) + { + return isset($this->aliasDefinitions[$this->normalizeId($id)]); + } + /** + * Gets all defined aliases. + * + * @return Alias[] An array of aliases + */ + public function getAliases() + { + return $this->aliasDefinitions; + } + /** + * Gets an alias. + * + * @param string $id The service identifier + * + * @return Alias An Alias instance + * + * @throws InvalidArgumentException if the alias does not exist + */ + public function getAlias($id) + { + $id = $this->normalizeId($id); + if (!isset($this->aliasDefinitions[$id])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service alias "%s" does not exist.', $id)); + } + return $this->aliasDefinitions[$id]; + } + /** + * Registers a service definition. + * + * This methods allows for simple registration of service definition + * with a fluid interface. + * + * @param string $id The service identifier + * @param string|null $class The service class + * + * @return Definition A Definition instance + */ + public function register($id, $class = null) + { + return $this->setDefinition($id, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($class)); + } + /** + * Registers an autowired service definition. + * + * This method implements a shortcut for using setDefinition() with + * an autowired definition. + * + * @param string $id The service identifier + * @param string|null $class The service class + * + * @return Definition The created definition + */ + public function autowire($id, $class = null) + { + return $this->setDefinition($id, (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($class))->setAutowired(\true)); + } + /** + * Adds the service definitions. + * + * @param Definition[] $definitions An array of service definitions + */ + public function addDefinitions(array $definitions) + { + foreach ($definitions as $id => $definition) { + $this->setDefinition($id, $definition); + } + } + /** + * Sets the service definitions. + * + * @param Definition[] $definitions An array of service definitions + */ + public function setDefinitions(array $definitions) + { + $this->definitions = []; + $this->addDefinitions($definitions); + } + /** + * Gets all service definitions. + * + * @return Definition[] An array of Definition instances + */ + public function getDefinitions() + { + return $this->definitions; + } + /** + * Sets a service definition. + * + * @param string $id The service identifier + * @param Definition $definition A Definition instance + * + * @return Definition the service definition + * + * @throws BadMethodCallException When this ContainerBuilder is compiled + */ + public function setDefinition($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + if ($this->isCompiled()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('Adding definition to a compiled container is not allowed.'); + } + $id = $this->normalizeId($id); + if ('' === $id || '\\' === \substr($id, -1) || \strlen($id) !== \strcspn($id, "\0\r\n'")) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid service id: "%s".', $id)); + } + unset($this->aliasDefinitions[$id], $this->removedIds[$id]); + return $this->definitions[$id] = $definition; + } + /** + * Returns true if a service definition exists under the given identifier. + * + * @param string $id The service identifier + * + * @return bool true if the service definition exists, false otherwise + */ + public function hasDefinition($id) + { + return isset($this->definitions[$this->normalizeId($id)]); + } + /** + * Gets a service definition. + * + * @param string $id The service identifier + * + * @return Definition A Definition instance + * + * @throws ServiceNotFoundException if the service definition does not exist + */ + public function getDefinition($id) + { + $id = $this->normalizeId($id); + if (!isset($this->definitions[$id])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id); + } + return $this->definitions[$id]; + } + /** + * Gets a service definition by id or alias. + * + * The method "unaliases" recursively to return a Definition instance. + * + * @param string $id The service identifier or alias + * + * @return Definition A Definition instance + * + * @throws ServiceNotFoundException if the service definition does not exist + */ + public function findDefinition($id) + { + $id = $this->normalizeId($id); + $seen = []; + while (isset($this->aliasDefinitions[$id])) { + $id = (string) $this->aliasDefinitions[$id]; + if (isset($seen[$id])) { + $seen = \array_values($seen); + $seen = \array_slice($seen, \array_search($id, $seen)); + $seen[] = $id; + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, $seen); + } + $seen[$id] = $id; + } + return $this->getDefinition($id); + } + /** + * Creates a service for a service definition. + * + * @param Definition $definition A service definition instance + * @param string $id The service identifier + * @param bool $tryProxy Whether to try proxying the service with a lazy proxy + * + * @return mixed The service described by the service definition + * + * @throws RuntimeException When the factory definition is incomplete + * @throws RuntimeException When the service is a synthetic service + * @throws InvalidArgumentException When configure callable is not callable + */ + private function createService(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, array &$inlineServices, $isConstructorArgument = \false, $id = null, $tryProxy = \true) + { + if (null === $id && isset($inlineServices[$h = \spl_object_hash($definition)])) { + return $inlineServices[$h]; + } + if ($definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Constructing service "%s" from a parent definition is not supported at build time.', $id)); + } + if ($definition->isSynthetic()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('You have requested a synthetic service ("%s"). The DIC does not know how to construct this service.', $id)); + } + if ($definition->isDeprecated()) { + @\trigger_error($definition->getDeprecationMessage($id), \E_USER_DEPRECATED); + } + if ($tryProxy && $definition->isLazy() && !($tryProxy = !($proxy = $this->proxyInstantiator) || $proxy instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator)) { + $proxy = $proxy->instantiateProxy($this, $definition, $id, function () use($definition, &$inlineServices, $id) { + return $this->createService($definition, $inlineServices, \true, $id, \false); + }); + $this->shareService($definition, $proxy, $id, $inlineServices); + return $proxy; + } + $parameterBag = $this->getParameterBag(); + if (null !== $definition->getFile()) { + require_once $parameterBag->resolveValue($definition->getFile()); + } + $arguments = $this->doResolveServices($parameterBag->unescapeValue($parameterBag->resolveValue($definition->getArguments())), $inlineServices, $isConstructorArgument); + if (null !== ($factory = $definition->getFactory())) { + if (\is_array($factory)) { + $factory = [$this->doResolveServices($parameterBag->resolveValue($factory[0]), $inlineServices, $isConstructorArgument), $factory[1]]; + } elseif (!\is_string($factory)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Cannot create service "%s" because of invalid factory.', $id)); + } + } + if (null !== $id && $definition->isShared() && isset($this->services[$id]) && ($tryProxy || !$definition->isLazy())) { + return $this->services[$id]; + } + if (null !== $factory) { + $service = \call_user_func_array($factory, $arguments); + if (!$definition->isDeprecated() && \is_array($factory) && \is_string($factory[0])) { + $r = new \ReflectionClass($factory[0]); + if (0 < \strpos($r->getDocComment(), "\n * @deprecated ")) { + @\trigger_error(\sprintf('The "%s" service relies on the deprecated "%s" factory class. It should either be deprecated or its factory upgraded.', $id, $r->name), \E_USER_DEPRECATED); + } + } + } else { + $r = new \ReflectionClass($class = $parameterBag->resolveValue($definition->getClass())); + $service = null === $r->getConstructor() ? $r->newInstance() : $r->newInstanceArgs($arguments); + // don't trigger deprecations for internal uses + // @deprecated since version 3.3, to be removed in 4.0 along with the deprecated class + $deprecationWhitelist = ['event_dispatcher' => \_PhpScoper5ea00cc67502b\Symfony\Component\EventDispatcher\ContainerAwareEventDispatcher::class]; + if (!$definition->isDeprecated() && 0 < \strpos($r->getDocComment(), "\n * @deprecated ") && (!isset($deprecationWhitelist[$id]) || $deprecationWhitelist[$id] !== $class)) { + @\trigger_error(\sprintf('The "%s" service relies on the deprecated "%s" class. It should either be deprecated or its implementation upgraded.', $id, $r->name), \E_USER_DEPRECATED); + } + } + if ($tryProxy || !$definition->isLazy()) { + // share only if proxying failed, or if not a proxy + $this->shareService($definition, $service, $id, $inlineServices); + } + $properties = $this->doResolveServices($parameterBag->unescapeValue($parameterBag->resolveValue($definition->getProperties())), $inlineServices); + foreach ($properties as $name => $value) { + $service->{$name} = $value; + } + foreach ($definition->getMethodCalls() as $call) { + $this->callMethod($service, $call, $inlineServices); + } + if ($callable = $definition->getConfigurator()) { + if (\is_array($callable)) { + $callable[0] = $parameterBag->resolveValue($callable[0]); + if ($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $callable[0] = $this->doGet((string) $callable[0], $callable[0]->getInvalidBehavior(), $inlineServices); + } elseif ($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + $callable[0] = $this->createService($callable[0], $inlineServices); + } + } + if (!\is_callable($callable)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The configure callable for class "%s" is not a callable.', \get_class($service))); + } + \call_user_func($callable, $service); + } + return $service; + } + /** + * Replaces service references by the real service instance and evaluates expressions. + * + * @param mixed $value A value + * + * @return mixed The same value with all service references replaced by + * the real service instances and all expressions evaluated + */ + public function resolveServices($value) + { + return $this->doResolveServices($value); + } + private function doResolveServices($value, array &$inlineServices = [], $isConstructorArgument = \false) + { + if (\is_array($value)) { + foreach ($value as $k => $v) { + $value[$k] = $this->doResolveServices($v, $inlineServices, $isConstructorArgument); + } + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { + $reference = $value->getValues()[0]; + $value = function () use($reference) { + return $this->resolveServices($reference); + }; + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument) { + $value = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () use($value) { + foreach ($value->getValues() as $k => $v) { + foreach (self::getServiceConditionals($v) as $s) { + if (!$this->has($s)) { + continue 2; + } + } + foreach (self::getInitializedConditionals($v) as $s) { + if (!$this->doGet($s, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE)) { + continue 2; + } + } + (yield $k => $this->resolveServices($v)); + } + }, function () use($value) { + $count = 0; + foreach ($value->getValues() as $v) { + foreach (self::getServiceConditionals($v) as $s) { + if (!$this->has($s)) { + continue 2; + } + } + foreach (self::getInitializedConditionals($v) as $s) { + if (!$this->doGet($s, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE)) { + continue 2; + } + } + ++$count; + } + return $count; + }); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $value = $this->doGet((string) $value, $value->getInvalidBehavior(), $inlineServices, $isConstructorArgument); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + $value = $this->createService($value, $inlineServices, $isConstructorArgument); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { + $value = $this->getParameter((string) $value); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { + $value = $this->getExpressionLanguage()->evaluate($value, ['container' => $this]); + } + return $value; + } + /** + * Returns service ids for a given tag. + * + * Example: + * + * $container->register('foo')->addTag('my.tag', ['hello' => 'world']); + * + * $serviceIds = $container->findTaggedServiceIds('my.tag'); + * foreach ($serviceIds as $serviceId => $tags) { + * foreach ($tags as $tag) { + * echo $tag['hello']; + * } + * } + * + * @param string $name + * @param bool $throwOnAbstract + * + * @return array An array of tags with the tagged service as key, holding a list of attribute arrays + */ + public function findTaggedServiceIds($name, $throwOnAbstract = \false) + { + $this->usedTags[] = $name; + $tags = []; + foreach ($this->getDefinitions() as $id => $definition) { + if ($definition->hasTag($name)) { + if ($throwOnAbstract && $definition->isAbstract()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" tagged "%s" must not be abstract.', $id, $name)); + } + $tags[$id] = $definition->getTag($name); + } + } + return $tags; + } + /** + * Returns all tags the defined services use. + * + * @return array An array of tags + */ + public function findTags() + { + $tags = []; + foreach ($this->getDefinitions() as $id => $definition) { + $tags = \array_merge(\array_keys($definition->getTags()), $tags); + } + return \array_unique($tags); + } + /** + * Returns all tags not queried by findTaggedServiceIds. + * + * @return string[] An array of tags + */ + public function findUnusedTags() + { + return \array_values(\array_diff($this->findTags(), $this->usedTags)); + } + public function addExpressionLanguageProvider(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface $provider) + { + $this->expressionLanguageProviders[] = $provider; + } + /** + * @return ExpressionFunctionProviderInterface[] + */ + public function getExpressionLanguageProviders() + { + return $this->expressionLanguageProviders; + } + /** + * Returns a ChildDefinition that will be used for autoconfiguring the interface/class. + * + * @param string $interface The class or interface to match + * + * @return ChildDefinition + */ + public function registerForAutoconfiguration($interface) + { + if (!isset($this->autoconfiguredInstanceof[$interface])) { + $this->autoconfiguredInstanceof[$interface] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''); + } + return $this->autoconfiguredInstanceof[$interface]; + } + /** + * Returns an array of ChildDefinition[] keyed by interface. + * + * @return ChildDefinition[] + */ + public function getAutoconfiguredInstanceof() + { + return $this->autoconfiguredInstanceof; + } + /** + * Resolves env parameter placeholders in a string or an array. + * + * @param mixed $value The value to resolve + * @param string|true|null $format A sprintf() format returning the replacement for each env var name or + * null to resolve back to the original "%env(VAR)%" format or + * true to resolve to the actual values of the referenced env vars + * @param array &$usedEnvs Env vars found while resolving are added to this array + * + * @return mixed The value with env parameters resolved if a string or an array is passed + */ + public function resolveEnvPlaceholders($value, $format = null, array &$usedEnvs = null) + { + if (null === $format) { + $format = '%%env(%s)%%'; + } + $bag = $this->getParameterBag(); + if (\true === $format) { + $value = $bag->resolveValue($value); + } + if (\is_array($value)) { + $result = []; + foreach ($value as $k => $v) { + $result[\is_string($k) ? $this->resolveEnvPlaceholders($k, $format, $usedEnvs) : $k] = $this->resolveEnvPlaceholders($v, $format, $usedEnvs); + } + return $result; + } + if (!\is_string($value) || 38 > \strlen($value)) { + return $value; + } + $envPlaceholders = $bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag ? $bag->getEnvPlaceholders() : $this->envPlaceholders; + $completed = \false; + foreach ($envPlaceholders as $env => $placeholders) { + foreach ($placeholders as $placeholder) { + if (\false !== \stripos($value, $placeholder)) { + if (\true === $format) { + $resolved = $bag->escapeValue($this->getEnv($env)); + } else { + $resolved = \sprintf($format, $env); + } + if ($placeholder === $value) { + $value = $resolved; + $completed = \true; + } else { + if (!\is_string($resolved) && !\is_numeric($resolved)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('A string value must be composed of strings and/or numbers, but found parameter "env(%s)" of type "%s" inside string value "%s".', $env, \gettype($resolved), $this->resolveEnvPlaceholders($value))); + } + $value = \str_ireplace($placeholder, $resolved, $value); + } + $usedEnvs[$env] = $env; + $this->envCounters[$env] = isset($this->envCounters[$env]) ? 1 + $this->envCounters[$env] : 1; + if ($completed) { + break 2; + } + } + } + } + return $value; + } + /** + * Get statistics about env usage. + * + * @return int[] The number of time each env vars has been resolved + */ + public function getEnvCounters() + { + $bag = $this->getParameterBag(); + $envPlaceholders = $bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag ? $bag->getEnvPlaceholders() : $this->envPlaceholders; + foreach ($envPlaceholders as $env => $placeholders) { + if (!isset($this->envCounters[$env])) { + $this->envCounters[$env] = 0; + } + } + return $this->envCounters; + } + /** + * @internal + */ + public function getNormalizedIds() + { + $normalizedIds = []; + foreach ($this->normalizedIds as $k => $v) { + if ($v !== (string) $k) { + $normalizedIds[$k] = $v; + } + } + return $normalizedIds; + } + /** + * @final + */ + public function log(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface $pass, $message) + { + $this->getCompiler()->log($pass, $this->resolveEnvPlaceholders($message)); + } + /** + * {@inheritdoc} + */ + public function normalizeId($id) + { + if (!\is_string($id)) { + $id = (string) $id; + } + return isset($this->definitions[$id]) || isset($this->aliasDefinitions[$id]) || isset($this->removedIds[$id]) ? $id : parent::normalizeId($id); + } + /** + * Gets removed binding ids. + * + * @return array + * + * @internal + */ + public function getRemovedBindingIds() + { + return $this->removedBindingIds; + } + /** + * Removes bindings for a service. + * + * @param string $id The service identifier + * + * @internal + */ + public function removeBindings($id) + { + if ($this->hasDefinition($id)) { + foreach ($this->getDefinition($id)->getBindings() as $key => $binding) { + list(, $bindingId) = $binding->getValues(); + $this->removedBindingIds[(int) $bindingId] = \true; + } + } + } + /** + * Returns the Service Conditionals. + * + * @param mixed $value An array of conditionals to return + * + * @return array An array of Service conditionals + * + * @internal since version 3.4 + */ + public static function getServiceConditionals($value) + { + $services = []; + if (\is_array($value)) { + foreach ($value as $v) { + $services = \array_unique(\array_merge($services, self::getServiceConditionals($v))); + } + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE === $value->getInvalidBehavior()) { + $services[] = (string) $value; + } + return $services; + } + /** + * Returns the initialized conditionals. + * + * @param mixed $value An array of conditionals to return + * + * @return array An array of uninitialized conditionals + * + * @internal + */ + public static function getInitializedConditionals($value) + { + $services = []; + if (\is_array($value)) { + foreach ($value as $v) { + $services = \array_unique(\array_merge($services, self::getInitializedConditionals($v))); + } + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE === $value->getInvalidBehavior()) { + $services[] = (string) $value; + } + return $services; + } + /** + * Computes a reasonably unique hash of a value. + * + * @param mixed $value A serializable value + * + * @return string + */ + public static function hash($value) + { + $hash = \substr(\base64_encode(\hash('sha256', \serialize($value), \true)), 0, 7); + return \str_replace(['/', '+'], ['.', '_'], \strtolower($hash)); + } + /** + * {@inheritdoc} + */ + protected function getEnv($name) + { + $value = parent::getEnv($name); + $bag = $this->getParameterBag(); + if (!\is_string($value) || !$bag instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag) { + return $value; + } + foreach ($bag->getEnvPlaceholders() as $env => $placeholders) { + if (isset($placeholders[$value])) { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($bag->all()); + return $bag->unescapeValue($bag->get("env({$name})")); + } + } + $this->resolving["env({$name})"] = \true; + try { + return $bag->unescapeValue($this->resolveEnvPlaceholders($bag->escapeValue($value), \true)); + } finally { + unset($this->resolving["env({$name})"]); + } + } + private function callMethod($service, $call, array &$inlineServices) + { + foreach (self::getServiceConditionals($call[1]) as $s) { + if (!$this->has($s)) { + return; + } + } + foreach (self::getInitializedConditionals($call[1]) as $s) { + if (!$this->doGet($s, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE, $inlineServices)) { + return; + } + } + \call_user_func_array([$service, $call[0]], $this->doResolveServices($this->getParameterBag()->unescapeValue($this->getParameterBag()->resolveValue($call[1])), $inlineServices)); + } + /** + * Shares a given service in the container. + * + * @param mixed $service + * @param string|null $id + */ + private function shareService(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $service, $id, array &$inlineServices) + { + $inlineServices[null !== $id ? $id : \spl_object_hash($definition)] = $service; + if (null !== $id && $definition->isShared()) { + $this->services[$id] = $service; + unset($this->loading[$id]); + } + } + private function getExpressionLanguage() + { + if (null === $this->expressionLanguage) { + if (!\class_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to use expressions as the Symfony ExpressionLanguage component is not installed.'); + } + $this->expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage(null, $this->expressionLanguageProviders); + } + return $this->expressionLanguage; + } + private function inVendors($path) + { + if (null === $this->vendors) { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource(); + $this->vendors = $resource->getVendors(); + $this->addResource($resource); + } + $path = \realpath($path) ?: $path; + foreach ($this->vendors as $vendor) { + if (0 === \strpos($path, $vendor) && \false !== \strpbrk(\substr($path, \strlen($vendor), 1), '/' . \DIRECTORY_SEPARATOR)) { + return \true; + } + } + return \false; + } +} diff --git a/vendor/symfony/dependency-injection/ContainerInterface.php b/vendor/symfony/dependency-injection/ContainerInterface.php index ce8ca9aad..df09f6c9e 100644 --- a/vendor/symfony/dependency-injection/ContainerInterface.php +++ b/vendor/symfony/dependency-injection/ContainerInterface.php @@ -1,91 +1,91 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; -/** - * ContainerInterface is the interface implemented by service container classes. - * - * @author Fabien Potencier - * @author Johannes M. Schmitt - */ -interface ContainerInterface extends \_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface -{ - const EXCEPTION_ON_INVALID_REFERENCE = 1; - const NULL_ON_INVALID_REFERENCE = 2; - const IGNORE_ON_INVALID_REFERENCE = 3; - const IGNORE_ON_UNINITIALIZED_REFERENCE = 4; - /** - * Sets a service. - * - * @param string $id The service identifier - * @param object|null $service The service instance - */ - public function set($id, $service); - /** - * Gets a service. - * - * @param string $id The service identifier - * @param int $invalidBehavior The behavior when the service does not exist - * - * @return object|null The associated service - * - * @throws ServiceCircularReferenceException When a circular reference is detected - * @throws ServiceNotFoundException When the service is not defined - * - * @see Reference - */ - public function get($id, $invalidBehavior = self::EXCEPTION_ON_INVALID_REFERENCE); - /** - * Returns true if the given service is defined. - * - * @param string $id The service identifier - * - * @return bool true if the service is defined, false otherwise - */ - public function has($id); - /** - * Check for whether or not a service has been initialized. - * - * @param string $id - * - * @return bool true if the service has been initialized, false otherwise - */ - public function initialized($id); - /** - * Gets a parameter. - * - * @param string $name The parameter name - * - * @return mixed The parameter value - * - * @throws InvalidArgumentException if the parameter is not defined - */ - public function getParameter($name); - /** - * Checks if a parameter exists. - * - * @param string $name The parameter name - * - * @return bool The presence of parameter in container - */ - public function hasParameter($name); - /** - * Sets a parameter. - * - * @param string $name The parameter name - * @param mixed $value The parameter value - */ - public function setParameter($name, $value); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; +/** + * ContainerInterface is the interface implemented by service container classes. + * + * @author Fabien Potencier + * @author Johannes M. Schmitt + */ +interface ContainerInterface extends \_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface +{ + const EXCEPTION_ON_INVALID_REFERENCE = 1; + const NULL_ON_INVALID_REFERENCE = 2; + const IGNORE_ON_INVALID_REFERENCE = 3; + const IGNORE_ON_UNINITIALIZED_REFERENCE = 4; + /** + * Sets a service. + * + * @param string $id The service identifier + * @param object|null $service The service instance + */ + public function set($id, $service); + /** + * Gets a service. + * + * @param string $id The service identifier + * @param int $invalidBehavior The behavior when the service does not exist + * + * @return object|null The associated service + * + * @throws ServiceCircularReferenceException When a circular reference is detected + * @throws ServiceNotFoundException When the service is not defined + * + * @see Reference + */ + public function get($id, $invalidBehavior = self::EXCEPTION_ON_INVALID_REFERENCE); + /** + * Returns true if the given service is defined. + * + * @param string $id The service identifier + * + * @return bool true if the service is defined, false otherwise + */ + public function has($id); + /** + * Check for whether or not a service has been initialized. + * + * @param string $id + * + * @return bool true if the service has been initialized, false otherwise + */ + public function initialized($id); + /** + * Gets a parameter. + * + * @param string $name The parameter name + * + * @return mixed The parameter value + * + * @throws InvalidArgumentException if the parameter is not defined + */ + public function getParameter($name); + /** + * Checks if a parameter exists. + * + * @param string $name The parameter name + * + * @return bool The presence of parameter in container + */ + public function hasParameter($name); + /** + * Sets a parameter. + * + * @param string $name The parameter name + * @param mixed $value The parameter value + */ + public function setParameter($name, $value); +} diff --git a/vendor/symfony/dependency-injection/Definition.php b/vendor/symfony/dependency-injection/Definition.php index 818c2d4e3..3fb0d4426 100644 --- a/vendor/symfony/dependency-injection/Definition.php +++ b/vendor/symfony/dependency-injection/Definition.php @@ -1,843 +1,843 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException; -/** - * Definition represents a service definition. - * - * @author Fabien Potencier - */ -class Definition -{ - private $class; - private $file; - private $factory; - private $shared = \true; - private $deprecated = \false; - private $deprecationTemplate; - private $properties = []; - private $calls = []; - private $instanceof = []; - private $autoconfigured = \false; - private $configurator; - private $tags = []; - private $public = \true; - private $private = \true; - private $synthetic = \false; - private $abstract = \false; - private $lazy = \false; - private $decoratedService; - private $autowired = \false; - private $autowiringTypes = []; - private $changes = []; - private $bindings = []; - private $errors = []; - protected $arguments = []; - private static $defaultDeprecationTemplate = 'The "%service_id%" service is deprecated. You should stop using it, as it will soon be removed.'; - /** - * @param string|null $class The service class - * @param array $arguments An array of arguments to pass to the service constructor - */ - public function __construct($class = null, array $arguments = []) - { - if (null !== $class) { - $this->setClass($class); - } - $this->arguments = $arguments; - } - /** - * Returns all changes tracked for the Definition object. - * - * @return array An array of changes for this Definition - */ - public function getChanges() - { - return $this->changes; - } - /** - * Sets the tracked changes for the Definition object. - * - * @param array $changes An array of changes for this Definition - * - * @return $this - */ - public function setChanges(array $changes) - { - $this->changes = $changes; - return $this; - } - /** - * Sets a factory. - * - * @param string|array $factory A PHP function or an array containing a class/Reference and a method to call - * - * @return $this - */ - public function setFactory($factory) - { - $this->changes['factory'] = \true; - if (\is_string($factory) && \false !== \strpos($factory, '::')) { - $factory = \explode('::', $factory, 2); - } - $this->factory = $factory; - return $this; - } - /** - * Gets the factory. - * - * @return string|array|null The PHP function or an array containing a class/Reference and a method to call - */ - public function getFactory() - { - return $this->factory; - } - /** - * Sets the service that this service is decorating. - * - * @param string|null $id The decorated service id, use null to remove decoration - * @param string|null $renamedId The new decorated service id - * @param int $priority The priority of decoration - * - * @return $this - * - * @throws InvalidArgumentException in case the decorated service id and the new decorated service id are equals - */ - public function setDecoratedService($id, $renamedId = null, $priority = 0) - { - if ($renamedId && $id === $renamedId) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The decorated service inner name for "%s" must be different than the service name itself.', $id)); - } - $this->changes['decorated_service'] = \true; - if (null === $id) { - $this->decoratedService = null; - } else { - $this->decoratedService = [$id, $renamedId, (int) $priority]; - } - return $this; - } - /** - * Gets the service that this service is decorating. - * - * @return array|null An array composed of the decorated service id, the new id for it and the priority of decoration, null if no service is decorated - */ - public function getDecoratedService() - { - return $this->decoratedService; - } - /** - * Sets the service class. - * - * @param string $class The service class - * - * @return $this - */ - public function setClass($class) - { - $this->changes['class'] = \true; - $this->class = $class; - return $this; - } - /** - * Gets the service class. - * - * @return string|null The service class - */ - public function getClass() - { - return $this->class; - } - /** - * Sets the arguments to pass to the service constructor/factory method. - * - * @return $this - */ - public function setArguments(array $arguments) - { - $this->arguments = $arguments; - return $this; - } - /** - * Sets the properties to define when creating the service. - * - * @return $this - */ - public function setProperties(array $properties) - { - $this->properties = $properties; - return $this; - } - /** - * Gets the properties to define when creating the service. - * - * @return array - */ - public function getProperties() - { - return $this->properties; - } - /** - * Sets a specific property. - * - * @param string $name - * @param mixed $value - * - * @return $this - */ - public function setProperty($name, $value) - { - $this->properties[$name] = $value; - return $this; - } - /** - * Adds an argument to pass to the service constructor/factory method. - * - * @param mixed $argument An argument - * - * @return $this - */ - public function addArgument($argument) - { - $this->arguments[] = $argument; - return $this; - } - /** - * Replaces a specific argument. - * - * @param int|string $index - * @param mixed $argument - * - * @return $this - * - * @throws OutOfBoundsException When the replaced argument does not exist - */ - public function replaceArgument($index, $argument) - { - if (0 === \count($this->arguments)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException('Cannot replace arguments if none have been configured yet.'); - } - if (\is_int($index) && ($index < 0 || $index > \count($this->arguments) - 1)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException(\sprintf('The index "%d" is not in the range [0, %d].', $index, \count($this->arguments) - 1)); - } - if (!\array_key_exists($index, $this->arguments)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException(\sprintf('The argument "%s" doesn\'t exist.', $index)); - } - $this->arguments[$index] = $argument; - return $this; - } - /** - * Sets a specific argument. - * - * @param int|string $key - * @param mixed $value - * - * @return $this - */ - public function setArgument($key, $value) - { - $this->arguments[$key] = $value; - return $this; - } - /** - * Gets the arguments to pass to the service constructor/factory method. - * - * @return array The array of arguments - */ - public function getArguments() - { - return $this->arguments; - } - /** - * Gets an argument to pass to the service constructor/factory method. - * - * @param int|string $index - * - * @return mixed The argument value - * - * @throws OutOfBoundsException When the argument does not exist - */ - public function getArgument($index) - { - if (!\array_key_exists($index, $this->arguments)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException(\sprintf('The argument "%s" doesn\'t exist.', $index)); - } - return $this->arguments[$index]; - } - /** - * Sets the methods to call after service initialization. - * - * @return $this - */ - public function setMethodCalls(array $calls = []) - { - $this->calls = []; - foreach ($calls as $call) { - $this->addMethodCall($call[0], $call[1]); - } - return $this; - } - /** - * Adds a method to call after service initialization. - * - * @param string $method The method name to call - * @param array $arguments An array of arguments to pass to the method call - * - * @return $this - * - * @throws InvalidArgumentException on empty $method param - */ - public function addMethodCall($method, array $arguments = []) - { - if (empty($method)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('Method name cannot be empty.'); - } - $this->calls[] = [$method, $arguments]; - return $this; - } - /** - * Removes a method to call after service initialization. - * - * @param string $method The method name to remove - * - * @return $this - */ - public function removeMethodCall($method) - { - foreach ($this->calls as $i => $call) { - if ($call[0] === $method) { - unset($this->calls[$i]); - break; - } - } - return $this; - } - /** - * Check if the current definition has a given method to call after service initialization. - * - * @param string $method The method name to search for - * - * @return bool - */ - public function hasMethodCall($method) - { - foreach ($this->calls as $call) { - if ($call[0] === $method) { - return \true; - } - } - return \false; - } - /** - * Gets the methods to call after service initialization. - * - * @return array An array of method calls - */ - public function getMethodCalls() - { - return $this->calls; - } - /** - * Sets the definition templates to conditionally apply on the current definition, keyed by parent interface/class. - * - * @param ChildDefinition[] $instanceof - * - * @return $this - */ - public function setInstanceofConditionals(array $instanceof) - { - $this->instanceof = $instanceof; - return $this; - } - /** - * Gets the definition templates to conditionally apply on the current definition, keyed by parent interface/class. - * - * @return ChildDefinition[] - */ - public function getInstanceofConditionals() - { - return $this->instanceof; - } - /** - * Sets whether or not instanceof conditionals should be prepended with a global set. - * - * @param bool $autoconfigured - * - * @return $this - */ - public function setAutoconfigured($autoconfigured) - { - $this->changes['autoconfigured'] = \true; - $this->autoconfigured = $autoconfigured; - return $this; - } - /** - * @return bool - */ - public function isAutoconfigured() - { - return $this->autoconfigured; - } - /** - * Sets tags for this definition. - * - * @return $this - */ - public function setTags(array $tags) - { - $this->tags = $tags; - return $this; - } - /** - * Returns all tags. - * - * @return array An array of tags - */ - public function getTags() - { - return $this->tags; - } - /** - * Gets a tag by name. - * - * @param string $name The tag name - * - * @return array An array of attributes - */ - public function getTag($name) - { - return isset($this->tags[$name]) ? $this->tags[$name] : []; - } - /** - * Adds a tag for this definition. - * - * @param string $name The tag name - * @param array $attributes An array of attributes - * - * @return $this - */ - public function addTag($name, array $attributes = []) - { - $this->tags[$name][] = $attributes; - return $this; - } - /** - * Whether this definition has a tag with the given name. - * - * @param string $name - * - * @return bool - */ - public function hasTag($name) - { - return isset($this->tags[$name]); - } - /** - * Clears all tags for a given name. - * - * @param string $name The tag name - * - * @return $this - */ - public function clearTag($name) - { - unset($this->tags[$name]); - return $this; - } - /** - * Clears the tags for this definition. - * - * @return $this - */ - public function clearTags() - { - $this->tags = []; - return $this; - } - /** - * Sets a file to require before creating the service. - * - * @param string $file A full pathname to include - * - * @return $this - */ - public function setFile($file) - { - $this->changes['file'] = \true; - $this->file = $file; - return $this; - } - /** - * Gets the file to require before creating the service. - * - * @return string|null The full pathname to include - */ - public function getFile() - { - return $this->file; - } - /** - * Sets if the service must be shared or not. - * - * @param bool $shared Whether the service must be shared or not - * - * @return $this - */ - public function setShared($shared) - { - $this->changes['shared'] = \true; - $this->shared = (bool) $shared; - return $this; - } - /** - * Whether this service is shared. - * - * @return bool - */ - public function isShared() - { - return $this->shared; - } - /** - * Sets the visibility of this service. - * - * @param bool $boolean - * - * @return $this - */ - public function setPublic($boolean) - { - $this->changes['public'] = \true; - $this->public = (bool) $boolean; - $this->private = \false; - return $this; - } - /** - * Whether this service is public facing. - * - * @return bool - */ - public function isPublic() - { - return $this->public; - } - /** - * Sets if this service is private. - * - * When set, the "private" state has a higher precedence than "public". - * In version 3.4, a "private" service always remains publicly accessible, - * but triggers a deprecation notice when accessed from the container, - * so that the service can be made really private in 4.0. - * - * @param bool $boolean - * - * @return $this - */ - public function setPrivate($boolean) - { - $this->private = (bool) $boolean; - return $this; - } - /** - * Whether this service is private. - * - * @return bool - */ - public function isPrivate() - { - return $this->private; - } - /** - * Sets the lazy flag of this service. - * - * @param bool $lazy - * - * @return $this - */ - public function setLazy($lazy) - { - $this->changes['lazy'] = \true; - $this->lazy = (bool) $lazy; - return $this; - } - /** - * Whether this service is lazy. - * - * @return bool - */ - public function isLazy() - { - return $this->lazy; - } - /** - * Sets whether this definition is synthetic, that is not constructed by the - * container, but dynamically injected. - * - * @param bool $boolean - * - * @return $this - */ - public function setSynthetic($boolean) - { - $this->synthetic = (bool) $boolean; - return $this; - } - /** - * Whether this definition is synthetic, that is not constructed by the - * container, but dynamically injected. - * - * @return bool - */ - public function isSynthetic() - { - return $this->synthetic; - } - /** - * Whether this definition is abstract, that means it merely serves as a - * template for other definitions. - * - * @param bool $boolean - * - * @return $this - */ - public function setAbstract($boolean) - { - $this->abstract = (bool) $boolean; - return $this; - } - /** - * Whether this definition is abstract, that means it merely serves as a - * template for other definitions. - * - * @return bool - */ - public function isAbstract() - { - return $this->abstract; - } - /** - * Whether this definition is deprecated, that means it should not be called - * anymore. - * - * @param bool $status - * @param string $template Template message to use if the definition is deprecated - * - * @return $this - * - * @throws InvalidArgumentException when the message template is invalid - */ - public function setDeprecated($status = \true, $template = null) - { - if (null !== $template) { - if (\preg_match('#[\\r\\n]|\\*/#', $template)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('Invalid characters found in deprecation template.'); - } - if (\false === \strpos($template, '%service_id%')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('The deprecation template must contain the "%service_id%" placeholder.'); - } - $this->deprecationTemplate = $template; - } - $this->changes['deprecated'] = \true; - $this->deprecated = (bool) $status; - return $this; - } - /** - * Whether this definition is deprecated, that means it should not be called - * anymore. - * - * @return bool - */ - public function isDeprecated() - { - return $this->deprecated; - } - /** - * Message to use if this definition is deprecated. - * - * @param string $id Service id relying on this definition - * - * @return string - */ - public function getDeprecationMessage($id) - { - return \str_replace('%service_id%', $id, $this->deprecationTemplate ?: self::$defaultDeprecationTemplate); - } - /** - * Sets a configurator to call after the service is fully initialized. - * - * @param string|array $configurator A PHP callable - * - * @return $this - */ - public function setConfigurator($configurator) - { - $this->changes['configurator'] = \true; - if (\is_string($configurator) && \false !== \strpos($configurator, '::')) { - $configurator = \explode('::', $configurator, 2); - } - $this->configurator = $configurator; - return $this; - } - /** - * Gets the configurator to call after the service is fully initialized. - * - * @return callable|array|null - */ - public function getConfigurator() - { - return $this->configurator; - } - /** - * Sets types that will default to this definition. - * - * @param string[] $types - * - * @return $this - * - * @deprecated since version 3.3, to be removed in 4.0. - */ - public function setAutowiringTypes(array $types) - { - @\trigger_error('Autowiring-types are deprecated since Symfony 3.3 and will be removed in 4.0. Use aliases instead.', \E_USER_DEPRECATED); - $this->autowiringTypes = []; - foreach ($types as $type) { - $this->autowiringTypes[$type] = \true; - } - return $this; - } - /** - * Is the definition autowired? - * - * @return bool - */ - public function isAutowired() - { - return $this->autowired; - } - /** - * Enables/disables autowiring. - * - * @param bool $autowired - * - * @return $this - */ - public function setAutowired($autowired) - { - $this->changes['autowired'] = \true; - $this->autowired = (bool) $autowired; - return $this; - } - /** - * Gets autowiring types that will default to this definition. - * - * @return string[] - * - * @deprecated since version 3.3, to be removed in 4.0. - */ - public function getAutowiringTypes() - { - if (1 > \func_num_args() || \func_get_arg(0)) { - @\trigger_error('Autowiring-types are deprecated since Symfony 3.3 and will be removed in 4.0. Use aliases instead.', \E_USER_DEPRECATED); - } - return \array_keys($this->autowiringTypes); - } - /** - * Adds a type that will default to this definition. - * - * @param string $type - * - * @return $this - * - * @deprecated since version 3.3, to be removed in 4.0. - */ - public function addAutowiringType($type) - { - @\trigger_error(\sprintf('Autowiring-types are deprecated since Symfony 3.3 and will be removed in 4.0. Use aliases instead for "%s".', $type), \E_USER_DEPRECATED); - $this->autowiringTypes[$type] = \true; - return $this; - } - /** - * Removes a type. - * - * @param string $type - * - * @return $this - * - * @deprecated since version 3.3, to be removed in 4.0. - */ - public function removeAutowiringType($type) - { - @\trigger_error(\sprintf('Autowiring-types are deprecated since Symfony 3.3 and will be removed in 4.0. Use aliases instead for "%s".', $type), \E_USER_DEPRECATED); - unset($this->autowiringTypes[$type]); - return $this; - } - /** - * Will this definition default for the given type? - * - * @param string $type - * - * @return bool - * - * @deprecated since version 3.3, to be removed in 4.0. - */ - public function hasAutowiringType($type) - { - @\trigger_error(\sprintf('Autowiring-types are deprecated since Symfony 3.3 and will be removed in 4.0. Use aliases instead for "%s".', $type), \E_USER_DEPRECATED); - return isset($this->autowiringTypes[$type]); - } - /** - * Gets bindings. - * - * @return array - */ - public function getBindings() - { - return $this->bindings; - } - /** - * Sets bindings. - * - * Bindings map $named or FQCN arguments to values that should be - * injected in the matching parameters (of the constructor, of methods - * called and of controller actions). - * - * @return $this - */ - public function setBindings(array $bindings) - { - foreach ($bindings as $key => $binding) { - if (!$binding instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument) { - $bindings[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument($binding); - } - } - $this->bindings = $bindings; - return $this; - } - /** - * Add an error that occurred when building this Definition. - * - * @param string $error - */ - public function addError($error) - { - $this->errors[] = $error; - } - /** - * Returns any errors that occurred while building this Definition. - * - * @return array - */ - public function getErrors() - { - return $this->errors; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException; +/** + * Definition represents a service definition. + * + * @author Fabien Potencier + */ +class Definition +{ + private $class; + private $file; + private $factory; + private $shared = \true; + private $deprecated = \false; + private $deprecationTemplate; + private $properties = []; + private $calls = []; + private $instanceof = []; + private $autoconfigured = \false; + private $configurator; + private $tags = []; + private $public = \true; + private $private = \true; + private $synthetic = \false; + private $abstract = \false; + private $lazy = \false; + private $decoratedService; + private $autowired = \false; + private $autowiringTypes = []; + private $changes = []; + private $bindings = []; + private $errors = []; + protected $arguments = []; + private static $defaultDeprecationTemplate = 'The "%service_id%" service is deprecated. You should stop using it, as it will soon be removed.'; + /** + * @param string|null $class The service class + * @param array $arguments An array of arguments to pass to the service constructor + */ + public function __construct($class = null, array $arguments = []) + { + if (null !== $class) { + $this->setClass($class); + } + $this->arguments = $arguments; + } + /** + * Returns all changes tracked for the Definition object. + * + * @return array An array of changes for this Definition + */ + public function getChanges() + { + return $this->changes; + } + /** + * Sets the tracked changes for the Definition object. + * + * @param array $changes An array of changes for this Definition + * + * @return $this + */ + public function setChanges(array $changes) + { + $this->changes = $changes; + return $this; + } + /** + * Sets a factory. + * + * @param string|array $factory A PHP function or an array containing a class/Reference and a method to call + * + * @return $this + */ + public function setFactory($factory) + { + $this->changes['factory'] = \true; + if (\is_string($factory) && \false !== \strpos($factory, '::')) { + $factory = \explode('::', $factory, 2); + } + $this->factory = $factory; + return $this; + } + /** + * Gets the factory. + * + * @return string|array|null The PHP function or an array containing a class/Reference and a method to call + */ + public function getFactory() + { + return $this->factory; + } + /** + * Sets the service that this service is decorating. + * + * @param string|null $id The decorated service id, use null to remove decoration + * @param string|null $renamedId The new decorated service id + * @param int $priority The priority of decoration + * + * @return $this + * + * @throws InvalidArgumentException in case the decorated service id and the new decorated service id are equals + */ + public function setDecoratedService($id, $renamedId = null, $priority = 0) + { + if ($renamedId && $id === $renamedId) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The decorated service inner name for "%s" must be different than the service name itself.', $id)); + } + $this->changes['decorated_service'] = \true; + if (null === $id) { + $this->decoratedService = null; + } else { + $this->decoratedService = [$id, $renamedId, (int) $priority]; + } + return $this; + } + /** + * Gets the service that this service is decorating. + * + * @return array|null An array composed of the decorated service id, the new id for it and the priority of decoration, null if no service is decorated + */ + public function getDecoratedService() + { + return $this->decoratedService; + } + /** + * Sets the service class. + * + * @param string $class The service class + * + * @return $this + */ + public function setClass($class) + { + $this->changes['class'] = \true; + $this->class = $class; + return $this; + } + /** + * Gets the service class. + * + * @return string|null The service class + */ + public function getClass() + { + return $this->class; + } + /** + * Sets the arguments to pass to the service constructor/factory method. + * + * @return $this + */ + public function setArguments(array $arguments) + { + $this->arguments = $arguments; + return $this; + } + /** + * Sets the properties to define when creating the service. + * + * @return $this + */ + public function setProperties(array $properties) + { + $this->properties = $properties; + return $this; + } + /** + * Gets the properties to define when creating the service. + * + * @return array + */ + public function getProperties() + { + return $this->properties; + } + /** + * Sets a specific property. + * + * @param string $name + * @param mixed $value + * + * @return $this + */ + public function setProperty($name, $value) + { + $this->properties[$name] = $value; + return $this; + } + /** + * Adds an argument to pass to the service constructor/factory method. + * + * @param mixed $argument An argument + * + * @return $this + */ + public function addArgument($argument) + { + $this->arguments[] = $argument; + return $this; + } + /** + * Replaces a specific argument. + * + * @param int|string $index + * @param mixed $argument + * + * @return $this + * + * @throws OutOfBoundsException When the replaced argument does not exist + */ + public function replaceArgument($index, $argument) + { + if (0 === \count($this->arguments)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException('Cannot replace arguments if none have been configured yet.'); + } + if (\is_int($index) && ($index < 0 || $index > \count($this->arguments) - 1)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException(\sprintf('The index "%d" is not in the range [0, %d].', $index, \count($this->arguments) - 1)); + } + if (!\array_key_exists($index, $this->arguments)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException(\sprintf('The argument "%s" doesn\'t exist.', $index)); + } + $this->arguments[$index] = $argument; + return $this; + } + /** + * Sets a specific argument. + * + * @param int|string $key + * @param mixed $value + * + * @return $this + */ + public function setArgument($key, $value) + { + $this->arguments[$key] = $value; + return $this; + } + /** + * Gets the arguments to pass to the service constructor/factory method. + * + * @return array The array of arguments + */ + public function getArguments() + { + return $this->arguments; + } + /** + * Gets an argument to pass to the service constructor/factory method. + * + * @param int|string $index + * + * @return mixed The argument value + * + * @throws OutOfBoundsException When the argument does not exist + */ + public function getArgument($index) + { + if (!\array_key_exists($index, $this->arguments)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\OutOfBoundsException(\sprintf('The argument "%s" doesn\'t exist.', $index)); + } + return $this->arguments[$index]; + } + /** + * Sets the methods to call after service initialization. + * + * @return $this + */ + public function setMethodCalls(array $calls = []) + { + $this->calls = []; + foreach ($calls as $call) { + $this->addMethodCall($call[0], $call[1]); + } + return $this; + } + /** + * Adds a method to call after service initialization. + * + * @param string $method The method name to call + * @param array $arguments An array of arguments to pass to the method call + * + * @return $this + * + * @throws InvalidArgumentException on empty $method param + */ + public function addMethodCall($method, array $arguments = []) + { + if (empty($method)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('Method name cannot be empty.'); + } + $this->calls[] = [$method, $arguments]; + return $this; + } + /** + * Removes a method to call after service initialization. + * + * @param string $method The method name to remove + * + * @return $this + */ + public function removeMethodCall($method) + { + foreach ($this->calls as $i => $call) { + if ($call[0] === $method) { + unset($this->calls[$i]); + break; + } + } + return $this; + } + /** + * Check if the current definition has a given method to call after service initialization. + * + * @param string $method The method name to search for + * + * @return bool + */ + public function hasMethodCall($method) + { + foreach ($this->calls as $call) { + if ($call[0] === $method) { + return \true; + } + } + return \false; + } + /** + * Gets the methods to call after service initialization. + * + * @return array An array of method calls + */ + public function getMethodCalls() + { + return $this->calls; + } + /** + * Sets the definition templates to conditionally apply on the current definition, keyed by parent interface/class. + * + * @param ChildDefinition[] $instanceof + * + * @return $this + */ + public function setInstanceofConditionals(array $instanceof) + { + $this->instanceof = $instanceof; + return $this; + } + /** + * Gets the definition templates to conditionally apply on the current definition, keyed by parent interface/class. + * + * @return ChildDefinition[] + */ + public function getInstanceofConditionals() + { + return $this->instanceof; + } + /** + * Sets whether or not instanceof conditionals should be prepended with a global set. + * + * @param bool $autoconfigured + * + * @return $this + */ + public function setAutoconfigured($autoconfigured) + { + $this->changes['autoconfigured'] = \true; + $this->autoconfigured = $autoconfigured; + return $this; + } + /** + * @return bool + */ + public function isAutoconfigured() + { + return $this->autoconfigured; + } + /** + * Sets tags for this definition. + * + * @return $this + */ + public function setTags(array $tags) + { + $this->tags = $tags; + return $this; + } + /** + * Returns all tags. + * + * @return array An array of tags + */ + public function getTags() + { + return $this->tags; + } + /** + * Gets a tag by name. + * + * @param string $name The tag name + * + * @return array An array of attributes + */ + public function getTag($name) + { + return isset($this->tags[$name]) ? $this->tags[$name] : []; + } + /** + * Adds a tag for this definition. + * + * @param string $name The tag name + * @param array $attributes An array of attributes + * + * @return $this + */ + public function addTag($name, array $attributes = []) + { + $this->tags[$name][] = $attributes; + return $this; + } + /** + * Whether this definition has a tag with the given name. + * + * @param string $name + * + * @return bool + */ + public function hasTag($name) + { + return isset($this->tags[$name]); + } + /** + * Clears all tags for a given name. + * + * @param string $name The tag name + * + * @return $this + */ + public function clearTag($name) + { + unset($this->tags[$name]); + return $this; + } + /** + * Clears the tags for this definition. + * + * @return $this + */ + public function clearTags() + { + $this->tags = []; + return $this; + } + /** + * Sets a file to require before creating the service. + * + * @param string $file A full pathname to include + * + * @return $this + */ + public function setFile($file) + { + $this->changes['file'] = \true; + $this->file = $file; + return $this; + } + /** + * Gets the file to require before creating the service. + * + * @return string|null The full pathname to include + */ + public function getFile() + { + return $this->file; + } + /** + * Sets if the service must be shared or not. + * + * @param bool $shared Whether the service must be shared or not + * + * @return $this + */ + public function setShared($shared) + { + $this->changes['shared'] = \true; + $this->shared = (bool) $shared; + return $this; + } + /** + * Whether this service is shared. + * + * @return bool + */ + public function isShared() + { + return $this->shared; + } + /** + * Sets the visibility of this service. + * + * @param bool $boolean + * + * @return $this + */ + public function setPublic($boolean) + { + $this->changes['public'] = \true; + $this->public = (bool) $boolean; + $this->private = \false; + return $this; + } + /** + * Whether this service is public facing. + * + * @return bool + */ + public function isPublic() + { + return $this->public; + } + /** + * Sets if this service is private. + * + * When set, the "private" state has a higher precedence than "public". + * In version 3.4, a "private" service always remains publicly accessible, + * but triggers a deprecation notice when accessed from the container, + * so that the service can be made really private in 4.0. + * + * @param bool $boolean + * + * @return $this + */ + public function setPrivate($boolean) + { + $this->private = (bool) $boolean; + return $this; + } + /** + * Whether this service is private. + * + * @return bool + */ + public function isPrivate() + { + return $this->private; + } + /** + * Sets the lazy flag of this service. + * + * @param bool $lazy + * + * @return $this + */ + public function setLazy($lazy) + { + $this->changes['lazy'] = \true; + $this->lazy = (bool) $lazy; + return $this; + } + /** + * Whether this service is lazy. + * + * @return bool + */ + public function isLazy() + { + return $this->lazy; + } + /** + * Sets whether this definition is synthetic, that is not constructed by the + * container, but dynamically injected. + * + * @param bool $boolean + * + * @return $this + */ + public function setSynthetic($boolean) + { + $this->synthetic = (bool) $boolean; + return $this; + } + /** + * Whether this definition is synthetic, that is not constructed by the + * container, but dynamically injected. + * + * @return bool + */ + public function isSynthetic() + { + return $this->synthetic; + } + /** + * Whether this definition is abstract, that means it merely serves as a + * template for other definitions. + * + * @param bool $boolean + * + * @return $this + */ + public function setAbstract($boolean) + { + $this->abstract = (bool) $boolean; + return $this; + } + /** + * Whether this definition is abstract, that means it merely serves as a + * template for other definitions. + * + * @return bool + */ + public function isAbstract() + { + return $this->abstract; + } + /** + * Whether this definition is deprecated, that means it should not be called + * anymore. + * + * @param bool $status + * @param string $template Template message to use if the definition is deprecated + * + * @return $this + * + * @throws InvalidArgumentException when the message template is invalid + */ + public function setDeprecated($status = \true, $template = null) + { + if (null !== $template) { + if (\preg_match('#[\\r\\n]|\\*/#', $template)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('Invalid characters found in deprecation template.'); + } + if (\false === \strpos($template, '%service_id%')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('The deprecation template must contain the "%service_id%" placeholder.'); + } + $this->deprecationTemplate = $template; + } + $this->changes['deprecated'] = \true; + $this->deprecated = (bool) $status; + return $this; + } + /** + * Whether this definition is deprecated, that means it should not be called + * anymore. + * + * @return bool + */ + public function isDeprecated() + { + return $this->deprecated; + } + /** + * Message to use if this definition is deprecated. + * + * @param string $id Service id relying on this definition + * + * @return string + */ + public function getDeprecationMessage($id) + { + return \str_replace('%service_id%', $id, $this->deprecationTemplate ?: self::$defaultDeprecationTemplate); + } + /** + * Sets a configurator to call after the service is fully initialized. + * + * @param string|array $configurator A PHP callable + * + * @return $this + */ + public function setConfigurator($configurator) + { + $this->changes['configurator'] = \true; + if (\is_string($configurator) && \false !== \strpos($configurator, '::')) { + $configurator = \explode('::', $configurator, 2); + } + $this->configurator = $configurator; + return $this; + } + /** + * Gets the configurator to call after the service is fully initialized. + * + * @return callable|array|null + */ + public function getConfigurator() + { + return $this->configurator; + } + /** + * Sets types that will default to this definition. + * + * @param string[] $types + * + * @return $this + * + * @deprecated since version 3.3, to be removed in 4.0. + */ + public function setAutowiringTypes(array $types) + { + @\trigger_error('Autowiring-types are deprecated since Symfony 3.3 and will be removed in 4.0. Use aliases instead.', \E_USER_DEPRECATED); + $this->autowiringTypes = []; + foreach ($types as $type) { + $this->autowiringTypes[$type] = \true; + } + return $this; + } + /** + * Is the definition autowired? + * + * @return bool + */ + public function isAutowired() + { + return $this->autowired; + } + /** + * Enables/disables autowiring. + * + * @param bool $autowired + * + * @return $this + */ + public function setAutowired($autowired) + { + $this->changes['autowired'] = \true; + $this->autowired = (bool) $autowired; + return $this; + } + /** + * Gets autowiring types that will default to this definition. + * + * @return string[] + * + * @deprecated since version 3.3, to be removed in 4.0. + */ + public function getAutowiringTypes() + { + if (1 > \func_num_args() || \func_get_arg(0)) { + @\trigger_error('Autowiring-types are deprecated since Symfony 3.3 and will be removed in 4.0. Use aliases instead.', \E_USER_DEPRECATED); + } + return \array_keys($this->autowiringTypes); + } + /** + * Adds a type that will default to this definition. + * + * @param string $type + * + * @return $this + * + * @deprecated since version 3.3, to be removed in 4.0. + */ + public function addAutowiringType($type) + { + @\trigger_error(\sprintf('Autowiring-types are deprecated since Symfony 3.3 and will be removed in 4.0. Use aliases instead for "%s".', $type), \E_USER_DEPRECATED); + $this->autowiringTypes[$type] = \true; + return $this; + } + /** + * Removes a type. + * + * @param string $type + * + * @return $this + * + * @deprecated since version 3.3, to be removed in 4.0. + */ + public function removeAutowiringType($type) + { + @\trigger_error(\sprintf('Autowiring-types are deprecated since Symfony 3.3 and will be removed in 4.0. Use aliases instead for "%s".', $type), \E_USER_DEPRECATED); + unset($this->autowiringTypes[$type]); + return $this; + } + /** + * Will this definition default for the given type? + * + * @param string $type + * + * @return bool + * + * @deprecated since version 3.3, to be removed in 4.0. + */ + public function hasAutowiringType($type) + { + @\trigger_error(\sprintf('Autowiring-types are deprecated since Symfony 3.3 and will be removed in 4.0. Use aliases instead for "%s".', $type), \E_USER_DEPRECATED); + return isset($this->autowiringTypes[$type]); + } + /** + * Gets bindings. + * + * @return array + */ + public function getBindings() + { + return $this->bindings; + } + /** + * Sets bindings. + * + * Bindings map $named or FQCN arguments to values that should be + * injected in the matching parameters (of the constructor, of methods + * called and of controller actions). + * + * @return $this + */ + public function setBindings(array $bindings) + { + foreach ($bindings as $key => $binding) { + if (!$binding instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument) { + $bindings[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument($binding); + } + } + $this->bindings = $bindings; + return $this; + } + /** + * Add an error that occurred when building this Definition. + * + * @param string $error + */ + public function addError($error) + { + $this->errors[] = $error; + } + /** + * Returns any errors that occurred while building this Definition. + * + * @return array + */ + public function getErrors() + { + return $this->errors; + } +} diff --git a/vendor/symfony/dependency-injection/DefinitionDecorator.php b/vendor/symfony/dependency-injection/DefinitionDecorator.php index 4bd94620a..066768123 100644 --- a/vendor/symfony/dependency-injection/DefinitionDecorator.php +++ b/vendor/symfony/dependency-injection/DefinitionDecorator.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -@\trigger_error('The ' . __NAMESPACE__ . '\\DefinitionDecorator class is deprecated since Symfony 3.3 and will be removed in 4.0. Use the Symfony\\Component\\DependencyInjection\\ChildDefinition class instead.', \E_USER_DEPRECATED); -\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class); -if (\false) { - /** - * This definition decorates another definition. - * - * @author Johannes M. Schmitt - * - * @deprecated The DefinitionDecorator class is deprecated since version 3.3 and will be removed in 4.0. Use the Symfony\Component\DependencyInjection\ChildDefinition class instead. - */ - class DefinitionDecorator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +@\trigger_error('The ' . __NAMESPACE__ . '\\DefinitionDecorator class is deprecated since Symfony 3.3 and will be removed in 4.0. Use the Symfony\\Component\\DependencyInjection\\ChildDefinition class instead.', \E_USER_DEPRECATED); +\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class); +if (\false) { + /** + * This definition decorates another definition. + * + * @author Johannes M. Schmitt + * + * @deprecated The DefinitionDecorator class is deprecated since version 3.3 and will be removed in 4.0. Use the Symfony\Component\DependencyInjection\ChildDefinition class instead. + */ + class DefinitionDecorator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition + { + } +} diff --git a/vendor/symfony/dependency-injection/Dumper/Dumper.php b/vendor/symfony/dependency-injection/Dumper/Dumper.php index 038f69eb0..f8b5639ac 100644 --- a/vendor/symfony/dependency-injection/Dumper/Dumper.php +++ b/vendor/symfony/dependency-injection/Dumper/Dumper.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * Dumper is the abstract class for all built-in dumpers. - * - * @author Fabien Potencier - */ -abstract class Dumper implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\DumperInterface -{ - protected $container; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $this->container = $container; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * Dumper is the abstract class for all built-in dumpers. + * + * @author Fabien Potencier + */ +abstract class Dumper implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\DumperInterface +{ + protected $container; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $this->container = $container; + } +} diff --git a/vendor/symfony/dependency-injection/Dumper/DumperInterface.php b/vendor/symfony/dependency-injection/Dumper/DumperInterface.php index d0a6ecfd7..d53ab39ad 100644 --- a/vendor/symfony/dependency-injection/Dumper/DumperInterface.php +++ b/vendor/symfony/dependency-injection/Dumper/DumperInterface.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; - -/** - * DumperInterface is the interface implemented by service container dumper classes. - * - * @author Fabien Potencier - */ -interface DumperInterface -{ - /** - * Dumps the service container. - * - * @return string|array The representation of the service container - */ - public function dump(array $options = []); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; + +/** + * DumperInterface is the interface implemented by service container dumper classes. + * + * @author Fabien Potencier + */ +interface DumperInterface +{ + /** + * Dumps the service container. + * + * @return string|array The representation of the service container + */ + public function dump(array $options = []); +} diff --git a/vendor/symfony/dependency-injection/Dumper/GraphvizDumper.php b/vendor/symfony/dependency-injection/Dumper/GraphvizDumper.php index cad585f96..cca4e54cd 100644 --- a/vendor/symfony/dependency-injection/Dumper/GraphvizDumper.php +++ b/vendor/symfony/dependency-injection/Dumper/GraphvizDumper.php @@ -1,254 +1,254 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * GraphvizDumper dumps a service container as a graphviz file. - * - * You can convert the generated dot file with the dot utility (http://www.graphviz.org/): - * - * dot -Tpng container.dot > foo.png - * - * @author Fabien Potencier - */ -class GraphvizDumper extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\Dumper -{ - private $nodes; - private $edges; - // All values should be strings - private $options = ['graph' => ['ratio' => 'compress'], 'node' => ['fontsize' => '11', 'fontname' => 'Arial', 'shape' => 'record'], 'edge' => ['fontsize' => '9', 'fontname' => 'Arial', 'color' => 'grey', 'arrowhead' => 'open', 'arrowsize' => '0.5'], 'node.instance' => ['fillcolor' => '#9999ff', 'style' => 'filled'], 'node.definition' => ['fillcolor' => '#eeeeee'], 'node.missing' => ['fillcolor' => '#ff9999', 'style' => 'filled']]; - /** - * Dumps the service container as a graphviz graph. - * - * Available options: - * - * * graph: The default options for the whole graph - * * node: The default options for nodes - * * edge: The default options for edges - * * node.instance: The default options for services that are defined directly by object instances - * * node.definition: The default options for services that are defined via service definition instances - * * node.missing: The default options for missing services - * - * @return string The dot representation of the service container - */ - public function dump(array $options = []) - { - foreach (['graph', 'node', 'edge', 'node.instance', 'node.definition', 'node.missing'] as $key) { - if (isset($options[$key])) { - $this->options[$key] = \array_merge($this->options[$key], $options[$key]); - } - } - $this->nodes = $this->findNodes(); - $this->edges = []; - foreach ($this->container->getDefinitions() as $id => $definition) { - $this->edges[$id] = \array_merge($this->findEdges($id, $definition->getArguments(), \true, ''), $this->findEdges($id, $definition->getProperties(), \false, '')); - foreach ($definition->getMethodCalls() as $call) { - $this->edges[$id] = \array_merge($this->edges[$id], $this->findEdges($id, $call[1], \false, $call[0] . '()')); - } - } - return $this->container->resolveEnvPlaceholders($this->startDot() . $this->addNodes() . $this->addEdges() . $this->endDot(), '__ENV_%s__'); - } - /** - * Returns all nodes. - * - * @return string A string representation of all nodes - */ - private function addNodes() - { - $code = ''; - foreach ($this->nodes as $id => $node) { - $aliases = $this->getAliases($id); - $code .= \sprintf(" node_%s [label=\"%s\\n%s\\n\", shape=%s%s];\n", $this->dotize($id), $id . ($aliases ? ' (' . \implode(', ', $aliases) . ')' : ''), $node['class'], $this->options['node']['shape'], $this->addAttributes($node['attributes'])); - } - return $code; - } - /** - * Returns all edges. - * - * @return string A string representation of all edges - */ - private function addEdges() - { - $code = ''; - foreach ($this->edges as $id => $edges) { - foreach ($edges as $edge) { - $code .= \sprintf(" node_%s -> node_%s [label=\"%s\" style=\"%s\"%s];\n", $this->dotize($id), $this->dotize($edge['to']), $edge['name'], $edge['required'] ? 'filled' : 'dashed', $edge['lazy'] ? ' color="#9999ff"' : ''); - } - } - return $code; - } - /** - * Finds all edges belonging to a specific service id. - * - * @param string $id The service id used to find edges - * @param array $arguments An array of arguments - * @param bool $required - * @param string $name - * - * @return array An array of edges - */ - private function findEdges($id, array $arguments, $required, $name, $lazy = \false) - { - $edges = []; - foreach ($arguments as $argument) { - if ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { - $argument = $this->container->hasParameter($argument) ? $this->container->getParameter($argument) : null; - } elseif (\is_string($argument) && \preg_match('/^%([^%]+)%$/', $argument, $match)) { - $argument = $this->container->hasParameter($match[1]) ? $this->container->getParameter($match[1]) : null; - } - if ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $lazyEdge = $lazy; - if (!$this->container->has((string) $argument)) { - $this->nodes[(string) $argument] = ['name' => $name, 'required' => $required, 'class' => '', 'attributes' => $this->options['node.missing']]; - } elseif ('service_container' !== (string) $argument) { - $lazyEdge = $lazy || $this->container->getDefinition((string) $argument)->isLazy(); - } - $edges[] = ['name' => $name, 'required' => $required, 'to' => $argument, 'lazy' => $lazyEdge]; - } elseif ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { - $edges = \array_merge($edges, $this->findEdges($id, $argument->getValues(), $required, $name, \true)); - } elseif ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - $edges = \array_merge($edges, $this->findEdges($id, $argument->getArguments(), $required, ''), $this->findEdges($id, $argument->getProperties(), \false, '')); - foreach ($argument->getMethodCalls() as $call) { - $edges = \array_merge($edges, $this->findEdges($id, $call[1], \false, $call[0] . '()')); - } - } elseif (\is_array($argument)) { - $edges = \array_merge($edges, $this->findEdges($id, $argument, $required, $name, $lazy)); - } - } - return $edges; - } - /** - * Finds all nodes. - * - * @return array An array of all nodes - */ - private function findNodes() - { - $nodes = []; - $container = $this->cloneContainer(); - foreach ($container->getDefinitions() as $id => $definition) { - $class = $definition->getClass(); - if ('\\' === \substr($class, 0, 1)) { - $class = \substr($class, 1); - } - try { - $class = $this->container->getParameterBag()->resolveValue($class); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { - } - $nodes[$id] = ['class' => \str_replace('\\', '\\\\', $class), 'attributes' => \array_merge($this->options['node.definition'], ['style' => $definition->isShared() ? 'filled' : 'dotted'])]; - $container->setDefinition($id, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass')); - } - foreach ($container->getServiceIds() as $id) { - if (\array_key_exists($id, $container->getAliases())) { - continue; - } - if (!$container->hasDefinition($id)) { - $nodes[$id] = ['class' => \str_replace('\\', '\\\\', \get_class($container->get($id))), 'attributes' => $this->options['node.instance']]; - } - } - return $nodes; - } - private function cloneContainer() - { - $parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($this->container->getParameterBag()->all()); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder($parameterBag); - $container->setDefinitions($this->container->getDefinitions()); - $container->setAliases($this->container->getAliases()); - $container->setResources($this->container->getResources()); - foreach ($this->container->getExtensions() as $extension) { - $container->registerExtension($extension); - } - return $container; - } - /** - * Returns the start dot. - * - * @return string The string representation of a start dot - */ - private function startDot() - { - return \sprintf("digraph sc {\n %s\n node [%s];\n edge [%s];\n\n", $this->addOptions($this->options['graph']), $this->addOptions($this->options['node']), $this->addOptions($this->options['edge'])); - } - /** - * Returns the end dot. - * - * @return string - */ - private function endDot() - { - return "}\n"; - } - /** - * Adds attributes. - * - * @param array $attributes An array of attributes - * - * @return string A comma separated list of attributes - */ - private function addAttributes(array $attributes) - { - $code = []; - foreach ($attributes as $k => $v) { - $code[] = \sprintf('%s="%s"', $k, $v); - } - return $code ? ', ' . \implode(', ', $code) : ''; - } - /** - * Adds options. - * - * @param array $options An array of options - * - * @return string A space separated list of options - */ - private function addOptions(array $options) - { - $code = []; - foreach ($options as $k => $v) { - $code[] = \sprintf('%s="%s"', $k, $v); - } - return \implode(' ', $code); - } - /** - * Dotizes an identifier. - * - * @param string $id The identifier to dotize - * - * @return string A dotized string - */ - private function dotize($id) - { - return \strtolower(\preg_replace('/\\W/i', '_', $id)); - } - /** - * Compiles an array of aliases for a specified service id. - * - * @param string $id A service id - * - * @return array An array of aliases - */ - private function getAliases($id) - { - $aliases = []; - foreach ($this->container->getAliases() as $alias => $origin) { - if ($id == $origin) { - $aliases[] = $alias; - } - } - return $aliases; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * GraphvizDumper dumps a service container as a graphviz file. + * + * You can convert the generated dot file with the dot utility (http://www.graphviz.org/): + * + * dot -Tpng container.dot > foo.png + * + * @author Fabien Potencier + */ +class GraphvizDumper extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\Dumper +{ + private $nodes; + private $edges; + // All values should be strings + private $options = ['graph' => ['ratio' => 'compress'], 'node' => ['fontsize' => '11', 'fontname' => 'Arial', 'shape' => 'record'], 'edge' => ['fontsize' => '9', 'fontname' => 'Arial', 'color' => 'grey', 'arrowhead' => 'open', 'arrowsize' => '0.5'], 'node.instance' => ['fillcolor' => '#9999ff', 'style' => 'filled'], 'node.definition' => ['fillcolor' => '#eeeeee'], 'node.missing' => ['fillcolor' => '#ff9999', 'style' => 'filled']]; + /** + * Dumps the service container as a graphviz graph. + * + * Available options: + * + * * graph: The default options for the whole graph + * * node: The default options for nodes + * * edge: The default options for edges + * * node.instance: The default options for services that are defined directly by object instances + * * node.definition: The default options for services that are defined via service definition instances + * * node.missing: The default options for missing services + * + * @return string The dot representation of the service container + */ + public function dump(array $options = []) + { + foreach (['graph', 'node', 'edge', 'node.instance', 'node.definition', 'node.missing'] as $key) { + if (isset($options[$key])) { + $this->options[$key] = \array_merge($this->options[$key], $options[$key]); + } + } + $this->nodes = $this->findNodes(); + $this->edges = []; + foreach ($this->container->getDefinitions() as $id => $definition) { + $this->edges[$id] = \array_merge($this->findEdges($id, $definition->getArguments(), \true, ''), $this->findEdges($id, $definition->getProperties(), \false, '')); + foreach ($definition->getMethodCalls() as $call) { + $this->edges[$id] = \array_merge($this->edges[$id], $this->findEdges($id, $call[1], \false, $call[0] . '()')); + } + } + return $this->container->resolveEnvPlaceholders($this->startDot() . $this->addNodes() . $this->addEdges() . $this->endDot(), '__ENV_%s__'); + } + /** + * Returns all nodes. + * + * @return string A string representation of all nodes + */ + private function addNodes() + { + $code = ''; + foreach ($this->nodes as $id => $node) { + $aliases = $this->getAliases($id); + $code .= \sprintf(" node_%s [label=\"%s\\n%s\\n\", shape=%s%s];\n", $this->dotize($id), $id . ($aliases ? ' (' . \implode(', ', $aliases) . ')' : ''), $node['class'], $this->options['node']['shape'], $this->addAttributes($node['attributes'])); + } + return $code; + } + /** + * Returns all edges. + * + * @return string A string representation of all edges + */ + private function addEdges() + { + $code = ''; + foreach ($this->edges as $id => $edges) { + foreach ($edges as $edge) { + $code .= \sprintf(" node_%s -> node_%s [label=\"%s\" style=\"%s\"%s];\n", $this->dotize($id), $this->dotize($edge['to']), $edge['name'], $edge['required'] ? 'filled' : 'dashed', $edge['lazy'] ? ' color="#9999ff"' : ''); + } + } + return $code; + } + /** + * Finds all edges belonging to a specific service id. + * + * @param string $id The service id used to find edges + * @param array $arguments An array of arguments + * @param bool $required + * @param string $name + * + * @return array An array of edges + */ + private function findEdges($id, array $arguments, $required, $name, $lazy = \false) + { + $edges = []; + foreach ($arguments as $argument) { + if ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { + $argument = $this->container->hasParameter($argument) ? $this->container->getParameter($argument) : null; + } elseif (\is_string($argument) && \preg_match('/^%([^%]+)%$/', $argument, $match)) { + $argument = $this->container->hasParameter($match[1]) ? $this->container->getParameter($match[1]) : null; + } + if ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $lazyEdge = $lazy; + if (!$this->container->has((string) $argument)) { + $this->nodes[(string) $argument] = ['name' => $name, 'required' => $required, 'class' => '', 'attributes' => $this->options['node.missing']]; + } elseif ('service_container' !== (string) $argument) { + $lazyEdge = $lazy || $this->container->getDefinition((string) $argument)->isLazy(); + } + $edges[] = ['name' => $name, 'required' => $required, 'to' => $argument, 'lazy' => $lazyEdge]; + } elseif ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { + $edges = \array_merge($edges, $this->findEdges($id, $argument->getValues(), $required, $name, \true)); + } elseif ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + $edges = \array_merge($edges, $this->findEdges($id, $argument->getArguments(), $required, ''), $this->findEdges($id, $argument->getProperties(), \false, '')); + foreach ($argument->getMethodCalls() as $call) { + $edges = \array_merge($edges, $this->findEdges($id, $call[1], \false, $call[0] . '()')); + } + } elseif (\is_array($argument)) { + $edges = \array_merge($edges, $this->findEdges($id, $argument, $required, $name, $lazy)); + } + } + return $edges; + } + /** + * Finds all nodes. + * + * @return array An array of all nodes + */ + private function findNodes() + { + $nodes = []; + $container = $this->cloneContainer(); + foreach ($container->getDefinitions() as $id => $definition) { + $class = $definition->getClass(); + if ('\\' === \substr($class, 0, 1)) { + $class = \substr($class, 1); + } + try { + $class = $this->container->getParameterBag()->resolveValue($class); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { + } + $nodes[$id] = ['class' => \str_replace('\\', '\\\\', $class), 'attributes' => \array_merge($this->options['node.definition'], ['style' => $definition->isShared() ? 'filled' : 'dotted'])]; + $container->setDefinition($id, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass')); + } + foreach ($container->getServiceIds() as $id) { + if (\array_key_exists($id, $container->getAliases())) { + continue; + } + if (!$container->hasDefinition($id)) { + $nodes[$id] = ['class' => \str_replace('\\', '\\\\', \get_class($container->get($id))), 'attributes' => $this->options['node.instance']]; + } + } + return $nodes; + } + private function cloneContainer() + { + $parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($this->container->getParameterBag()->all()); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder($parameterBag); + $container->setDefinitions($this->container->getDefinitions()); + $container->setAliases($this->container->getAliases()); + $container->setResources($this->container->getResources()); + foreach ($this->container->getExtensions() as $extension) { + $container->registerExtension($extension); + } + return $container; + } + /** + * Returns the start dot. + * + * @return string The string representation of a start dot + */ + private function startDot() + { + return \sprintf("digraph sc {\n %s\n node [%s];\n edge [%s];\n\n", $this->addOptions($this->options['graph']), $this->addOptions($this->options['node']), $this->addOptions($this->options['edge'])); + } + /** + * Returns the end dot. + * + * @return string + */ + private function endDot() + { + return "}\n"; + } + /** + * Adds attributes. + * + * @param array $attributes An array of attributes + * + * @return string A comma separated list of attributes + */ + private function addAttributes(array $attributes) + { + $code = []; + foreach ($attributes as $k => $v) { + $code[] = \sprintf('%s="%s"', $k, $v); + } + return $code ? ', ' . \implode(', ', $code) : ''; + } + /** + * Adds options. + * + * @param array $options An array of options + * + * @return string A space separated list of options + */ + private function addOptions(array $options) + { + $code = []; + foreach ($options as $k => $v) { + $code[] = \sprintf('%s="%s"', $k, $v); + } + return \implode(' ', $code); + } + /** + * Dotizes an identifier. + * + * @param string $id The identifier to dotize + * + * @return string A dotized string + */ + private function dotize($id) + { + return \strtolower(\preg_replace('/\\W/i', '_', $id)); + } + /** + * Compiles an array of aliases for a specified service id. + * + * @param string $id A service id + * + * @return array An array of aliases + */ + private function getAliases($id) + { + $aliases = []; + foreach ($this->container->getAliases() as $alias => $origin) { + if ($id == $origin) { + $aliases[] = $alias; + } + } + return $aliases; + } +} diff --git a/vendor/symfony/dependency-injection/Dumper/PhpDumper.php b/vendor/symfony/dependency-injection/Dumper/PhpDumper.php index da5f392e3..e34a734fc 100644 --- a/vendor/symfony/dependency-injection/Dumper/PhpDumper.php +++ b/vendor/symfony/dependency-injection/Dumper/PhpDumper.php @@ -1,1750 +1,1750 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface as ProxyDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -use _PhpScoper5ea00cc67502b\Symfony\Component\HttpKernel\Kernel; -/** - * PhpDumper dumps a service container as a PHP class. - * - * @author Fabien Potencier - * @author Johannes M. Schmitt - */ -class PhpDumper extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\Dumper -{ - /** - * Characters that might appear in the generated variable name as first character. - */ - const FIRST_CHARS = 'abcdefghijklmnopqrstuvwxyz'; - /** - * Characters that might appear in the generated variable name as any but the first character. - */ - const NON_FIRST_CHARS = 'abcdefghijklmnopqrstuvwxyz0123456789_'; - private $definitionVariables; - private $referenceVariables; - private $variableCount; - private $inlinedDefinitions; - private $serviceCalls; - private $reservedVariables = ['instance', 'class', 'this']; - private $expressionLanguage; - private $targetDirRegex; - private $targetDirMaxMatches; - private $docStar; - private $serviceIdToMethodNameMap; - private $usedMethodNames; - private $namespace; - private $asFiles; - private $hotPathTag; - private $inlineRequires; - private $inlinedRequires = []; - private $circularReferences = []; - /** - * @var ProxyDumper - */ - private $proxyDumper; - /** - * {@inheritdoc} - */ - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - if (!$container->isCompiled()) { - @\trigger_error('Dumping an uncompiled ContainerBuilder is deprecated since Symfony 3.3 and will not be supported anymore in 4.0. Compile the container beforehand.', \E_USER_DEPRECATED); - } - parent::__construct($container); - } - /** - * Sets the dumper to be used when dumping proxies in the generated container. - */ - public function setProxyDumper(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface $proxyDumper) - { - $this->proxyDumper = $proxyDumper; - } - /** - * Dumps the service container as a PHP class. - * - * Available options: - * - * * class: The class name - * * base_class: The base class name - * * namespace: The class namespace - * * as_files: To split the container in several files - * - * @return string|array A PHP class representing the service container or an array of PHP files if the "as_files" option is set - * - * @throws EnvParameterException When an env var exists but has not been dumped - */ - public function dump(array $options = []) - { - $this->targetDirRegex = null; - $this->inlinedRequires = []; - $options = \array_merge(['class' => 'ProjectServiceContainer', 'base_class' => 'Container', 'namespace' => '', 'as_files' => \false, 'debug' => \true, 'hot_path_tag' => 'container.hot_path', 'inline_class_loader_parameter' => 'container.dumper.inline_class_loader', 'build_time' => \time()], $options); - $this->namespace = $options['namespace']; - $this->asFiles = $options['as_files']; - $this->hotPathTag = $options['hot_path_tag']; - $this->inlineRequires = $options['inline_class_loader_parameter'] && $this->container->hasParameter($options['inline_class_loader_parameter']) && $this->container->getParameter($options['inline_class_loader_parameter']); - if (0 !== \strpos($baseClass = $options['base_class'], '\\') && 'Container' !== $baseClass) { - $baseClass = \sprintf('%s\\%s', $options['namespace'] ? '\\' . $options['namespace'] : '', $baseClass); - $baseClassWithNamespace = $baseClass; - } elseif ('Container' === $baseClass) { - $baseClassWithNamespace = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::class; - } else { - $baseClassWithNamespace = $baseClass; - } - $this->initializeMethodNamesMap('Container' === $baseClass ? \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::class : $baseClass); - if ($this->getProxyDumper() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper) { - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(\true, \false))->process($this->container); - try { - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass())->process($this->container); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException $e) { - $path = $e->getPath(); - \end($path); - $path[\key($path)] .= '". Try running "composer require symfony/proxy-manager-bridge'; - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($e->getServiceId(), $path); - } - } - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(\false, !$this->getProxyDumper() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper))->process($this->container); - $checkedNodes = []; - $this->circularReferences = []; - foreach ($this->container->getCompiler()->getServiceReferenceGraph()->getNodes() as $id => $node) { - if (!$node->getValue() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - continue; - } - if (!isset($checkedNodes[$id])) { - $this->analyzeCircularReferences($id, $node->getOutEdges(), $checkedNodes); - } - } - $this->container->getCompiler()->getServiceReferenceGraph()->clear(); - $checkedNodes = []; - $this->docStar = $options['debug'] ? '*' : ''; - if (!empty($options['file']) && \is_dir($dir = \dirname($options['file']))) { - // Build a regexp where the first root dirs are mandatory, - // but every other sub-dir is optional up to the full path in $dir - // Mandate at least 1 root dir and not more than 5 optional dirs. - $dir = \explode(\DIRECTORY_SEPARATOR, \realpath($dir)); - $i = \count($dir); - if (2 + (int) ('\\' === \DIRECTORY_SEPARATOR) <= $i) { - $regex = ''; - $lastOptionalDir = $i > 8 ? $i - 5 : 2 + (int) ('\\' === \DIRECTORY_SEPARATOR); - $this->targetDirMaxMatches = $i - $lastOptionalDir; - while (--$i >= $lastOptionalDir) { - $regex = \sprintf('(%s%s)?', \preg_quote(\DIRECTORY_SEPARATOR . $dir[$i], '#'), $regex); - } - do { - $regex = \preg_quote(\DIRECTORY_SEPARATOR . $dir[$i], '#') . $regex; - } while (0 < --$i); - $this->targetDirRegex = '#' . \preg_quote($dir[0], '#') . $regex . '#'; - } - } - $code = $this->startClass($options['class'], $baseClass, $baseClassWithNamespace) . $this->addServices() . $this->addDefaultParametersMethod() . $this->endClass(); - if ($this->asFiles) { - $fileStart = <<container->getRemovedIds())) { - \sort($ids); - $c = "doExport($id) . " => true,\n"; - } - $files['removed-ids.php'] = $c . "];\n"; - } - foreach ($this->generateServiceFiles() as $file => $c) { - $files[$file] = $fileStart . $c; - } - foreach ($this->generateProxyClasses() as $file => $c) { - $files[$file] = " $c) { - $code["Container{$hash}/{$file}"] = $c; - } - \array_pop($code); - $code["Container{$hash}/{$options['class']}.php"] = \substr_replace($files[$options['class'] . '.php'], "namespace ? "\nnamespace {$this->namespace};\n" : ''; - $time = $options['build_time']; - $id = \hash('crc32', $hash . $time); - $code[$options['class'] . '.php'] = << '{$hash}', - 'container.build_id' => '{$id}', - 'container.build_time' => {$time}, -], __DIR__.\\DIRECTORY_SEPARATOR.'Container{$hash}'); - -EOF; - } else { - foreach ($this->generateProxyClasses() as $c) { - $code .= $c; - } - } - $this->targetDirRegex = null; - $this->inlinedRequires = []; - $this->circularReferences = []; - $unusedEnvs = []; - foreach ($this->container->getEnvCounters() as $env => $use) { - if (!$use) { - $unusedEnvs[] = $env; - } - } - if ($unusedEnvs) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException($unusedEnvs, null, 'Environment variables "%s" are never used. Please, check your container\'s configuration.'); - } - return $code; - } - /** - * Retrieves the currently set proxy dumper or instantiates one. - * - * @return ProxyDumper - */ - private function getProxyDumper() - { - if (!$this->proxyDumper) { - $this->proxyDumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper(); - } - return $this->proxyDumper; - } - private function analyzeCircularReferences($sourceId, array $edges, &$checkedNodes, &$currentPath = [], $byConstructor = \true) - { - $checkedNodes[$sourceId] = \true; - $currentPath[$sourceId] = $byConstructor; - foreach ($edges as $edge) { - $node = $edge->getDestNode(); - $id = $node->getId(); - if (!$node->getValue() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || $sourceId === $id || $edge->isLazy() || $edge->isWeak()) { - // no-op - } elseif (isset($currentPath[$id])) { - $this->addCircularReferences($id, $currentPath, $edge->isReferencedByConstructor()); - } elseif (!isset($checkedNodes[$id])) { - $this->analyzeCircularReferences($id, $node->getOutEdges(), $checkedNodes, $currentPath, $edge->isReferencedByConstructor()); - } elseif (isset($this->circularReferences[$id])) { - $this->connectCircularReferences($id, $currentPath, $edge->isReferencedByConstructor()); - } - } - unset($currentPath[$sourceId]); - } - private function connectCircularReferences($sourceId, &$currentPath, $byConstructor, &$subPath = []) - { - $currentPath[$sourceId] = $subPath[$sourceId] = $byConstructor; - foreach ($this->circularReferences[$sourceId] as $id => $byConstructor) { - if (isset($currentPath[$id])) { - $this->addCircularReferences($id, $currentPath, $byConstructor); - } elseif (!isset($subPath[$id]) && isset($this->circularReferences[$id])) { - $this->connectCircularReferences($id, $currentPath, $byConstructor, $subPath); - } - } - unset($currentPath[$sourceId], $subPath[$sourceId]); - } - private function addCircularReferences($id, $currentPath, $byConstructor) - { - $currentPath[$id] = $byConstructor; - $circularRefs = []; - foreach (\array_reverse($currentPath) as $parentId => $v) { - $byConstructor = $byConstructor && $v; - $circularRefs[] = $parentId; - if ($parentId === $id) { - break; - } - } - $currentId = $id; - foreach ($circularRefs as $parentId) { - if (empty($this->circularReferences[$parentId][$currentId])) { - $this->circularReferences[$parentId][$currentId] = $byConstructor; - } - $currentId = $parentId; - } - } - private function collectLineage($class, array &$lineage) - { - if (isset($lineage[$class])) { - return; - } - if (!($r = $this->container->getReflectionClass($class, \false))) { - return; - } - if ($this->container instanceof $class) { - return; - } - $file = $r->getFileName(); - if (!$file || $this->doExport($file) === ($exportedFile = $this->export($file))) { - return; - } - if ($parent = $r->getParentClass()) { - $this->collectLineage($parent->name, $lineage); - } - foreach ($r->getInterfaces() as $parent) { - $this->collectLineage($parent->name, $lineage); - } - foreach ($r->getTraits() as $parent) { - $this->collectLineage($parent->name, $lineage); - } - $lineage[$class] = \substr($exportedFile, 1, -1); - } - private function generateProxyClasses() - { - $alreadyGenerated = []; - $definitions = $this->container->getDefinitions(); - $strip = '' === $this->docStar && \method_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\HttpKernel\\Kernel', 'stripComments'); - $proxyDumper = $this->getProxyDumper(); - \ksort($definitions); - foreach ($definitions as $definition) { - if (!$proxyDumper->isProxyCandidate($definition)) { - continue; - } - if (isset($alreadyGenerated[$class = $definition->getClass()])) { - continue; - } - $alreadyGenerated[$class] = \true; - // register class' reflector for resource tracking - $this->container->getReflectionClass($class); - if ("\n" === ($proxyCode = "\n" . $proxyDumper->getProxyCode($definition))) { - continue; - } - if ($strip) { - $proxyCode = " $proxyCode); - } - } - /** - * Generates the require_once statement for service includes. - * - * @return string - */ - private function addServiceInclude($cId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - $code = ''; - if ($this->inlineRequires && !$this->isHotPath($definition)) { - $lineage = []; - foreach ($this->inlinedDefinitions as $def) { - if (!$def->isDeprecated() && \is_string($class = \is_array($factory = $def->getFactory()) && \is_string($factory[0]) ? $factory[0] : $def->getClass())) { - $this->collectLineage($class, $lineage); - } - } - foreach ($this->serviceCalls as $id => list($callCount, $behavior)) { - if ('service_container' !== $id && $id !== $cId && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE !== $behavior && $this->container->has($id) && $this->isTrivialInstance($def = $this->container->findDefinition($id)) && \is_string($class = \is_array($factory = $def->getFactory()) && \is_string($factory[0]) ? $factory[0] : $def->getClass())) { - $this->collectLineage($class, $lineage); - } - } - foreach (\array_diff_key(\array_flip($lineage), $this->inlinedRequires) as $file => $class) { - $code .= \sprintf(" include_once %s;\n", $file); - } - } - foreach ($this->inlinedDefinitions as $def) { - if ($file = $def->getFile()) { - $code .= \sprintf(" include_once %s;\n", $this->dumpValue($file)); - } - } - if ('' !== $code) { - $code .= "\n"; - } - return $code; - } - /** - * Generates the service instance. - * - * @param string $id - * @param bool $isSimpleInstance - * - * @return string - * - * @throws InvalidArgumentException - * @throws RuntimeException - */ - private function addServiceInstance($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $isSimpleInstance) - { - $class = $this->dumpValue($definition->getClass()); - if (0 === \strpos($class, "'") && \false === \strpos($class, '$') && !\preg_match('/^\'(?:\\\\{2})?[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*(?:\\\\{2}[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*)*\'$/', $class)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"%s" is not a valid class name for the "%s" service.', $class, $id)); - } - $isProxyCandidate = $this->getProxyDumper()->isProxyCandidate($definition); - $instantiation = ''; - if (!$isProxyCandidate && $definition->isShared()) { - $instantiation = \sprintf('$this->services[%s] = %s', $this->doExport($id), $isSimpleInstance ? '' : '$instance'); - } elseif (!$isSimpleInstance) { - $instantiation = '$instance'; - } - $return = ''; - if ($isSimpleInstance) { - $return = 'return '; - } else { - $instantiation .= ' = '; - } - return $this->addNewInstance($definition, $return, $instantiation, $id); - } - /** - * Checks if the definition is a trivial instance. - * - * @return bool - */ - private function isTrivialInstance(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - if ($definition->isSynthetic() || $definition->getFile() || $definition->getMethodCalls() || $definition->getProperties() || $definition->getConfigurator()) { - return \false; - } - if ($definition->isDeprecated() || $definition->isLazy() || $definition->getFactory() || 3 < \count($definition->getArguments())) { - return \false; - } - foreach ($definition->getArguments() as $arg) { - if (!$arg || $arg instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { - continue; - } - if (\is_array($arg) && 3 >= \count($arg)) { - foreach ($arg as $k => $v) { - if ($this->dumpValue($k) !== $this->dumpValue($k, \false)) { - return \false; - } - if (!$v || $v instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { - continue; - } - if ($v instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && $this->container->has($id = (string) $v) && $this->container->findDefinition($id)->isSynthetic()) { - continue; - } - if (!\is_scalar($v) || $this->dumpValue($v) !== $this->dumpValue($v, \false)) { - return \false; - } - } - } elseif ($arg instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && $this->container->has($id = (string) $arg) && $this->container->findDefinition($id)->isSynthetic()) { - continue; - } elseif (!\is_scalar($arg) || $this->dumpValue($arg) !== $this->dumpValue($arg, \false)) { - return \false; - } - } - return \true; - } - /** - * Adds method calls to a service definition. - * - * @param string $variableName - * - * @return string - */ - private function addServiceMethodCalls(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $variableName = 'instance') - { - $calls = ''; - foreach ($definition->getMethodCalls() as $call) { - $arguments = []; - foreach ($call[1] as $value) { - $arguments[] = $this->dumpValue($value); - } - $calls .= $this->wrapServiceConditionals($call[1], \sprintf(" \$%s->%s(%s);\n", $variableName, $call[0], \implode(', ', $arguments))); - } - return $calls; - } - private function addServiceProperties(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $variableName = 'instance') - { - $code = ''; - foreach ($definition->getProperties() as $name => $value) { - $code .= \sprintf(" \$%s->%s = %s;\n", $variableName, $name, $this->dumpValue($value)); - } - return $code; - } - /** - * Adds configurator definition. - * - * @param string $variableName - * - * @return string - */ - private function addServiceConfigurator(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $variableName = 'instance') - { - if (!($callable = $definition->getConfigurator())) { - return ''; - } - if (\is_array($callable)) { - if ($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || $callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && $this->definitionVariables->contains($callable[0])) { - return \sprintf(" %s->%s(\$%s);\n", $this->dumpValue($callable[0]), $callable[1], $variableName); - } - $class = $this->dumpValue($callable[0]); - // If the class is a string we can optimize call_user_func away - if (0 === \strpos($class, "'") && \false === \strpos($class, '$')) { - return \sprintf(" %s::%s(\$%s);\n", $this->dumpLiteralClass($class), $callable[1], $variableName); - } - if (0 === \strpos($class, 'new ')) { - return \sprintf(" (%s)->%s(\$%s);\n", $this->dumpValue($callable[0]), $callable[1], $variableName); - } - return \sprintf(" \\call_user_func([%s, '%s'], \$%s);\n", $this->dumpValue($callable[0]), $callable[1], $variableName); - } - return \sprintf(" %s(\$%s);\n", $callable, $variableName); - } - /** - * Adds a service. - * - * @param string $id - * @param string &$file - * - * @return string - */ - private function addService($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, &$file = null) - { - $this->definitionVariables = new \SplObjectStorage(); - $this->referenceVariables = []; - $this->variableCount = 0; - $this->referenceVariables[$id] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable('instance'); - $return = []; - if ($class = $definition->getClass()) { - $class = $class instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter ? '%' . $class . '%' : $this->container->resolveEnvPlaceholders($class); - $return[] = \sprintf(0 === \strpos($class, '%') ? '@return object A %1$s instance' : '@return \\%s', \ltrim($class, '\\')); - } elseif ($definition->getFactory()) { - $factory = $definition->getFactory(); - if (\is_string($factory)) { - $return[] = \sprintf('@return object An instance returned by %s()', $factory); - } elseif (\is_array($factory) && (\is_string($factory[0]) || $factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || $factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference)) { - $class = $factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition ? $factory[0]->getClass() : (string) $factory[0]; - $class = $class instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter ? '%' . $class . '%' : $this->container->resolveEnvPlaceholders($class); - $return[] = \sprintf('@return object An instance returned by %s::%s()', $class, $factory[1]); - } - } - if ($definition->isDeprecated()) { - if ($return && 0 === \strpos($return[\count($return) - 1], '@return')) { - $return[] = ''; - } - $return[] = \sprintf('@deprecated %s', $definition->getDeprecationMessage($id)); - } - $return = \str_replace("\n * \n", "\n *\n", \implode("\n * ", $return)); - $return = $this->container->resolveEnvPlaceholders($return); - $shared = $definition->isShared() ? ' shared' : ''; - $public = $definition->isPublic() ? 'public' : 'private'; - $autowired = $definition->isAutowired() ? ' autowired' : ''; - if ($definition->isLazy()) { - $lazyInitialization = '$lazyLoad = true'; - } else { - $lazyInitialization = ''; - } - $asFile = $this->asFiles && $definition->isShared() && !$this->isHotPath($definition); - $methodName = $this->generateMethodName($id); - if ($asFile) { - $file = $methodName . '.php'; - $code = " // Returns the {$public} '{$id}'{$shared}{$autowired} service.\n\n"; - } else { - $code = <<docStar} - * Gets the {$public} '{$id}'{$shared}{$autowired} service. - * - * {$return} -EOF; - $code = \str_replace('*/', ' ', $code) . <<serviceCalls = []; - $this->inlinedDefinitions = $this->getDefinitionsFromArguments([$definition], null, $this->serviceCalls); - $code .= $this->addServiceInclude($id, $definition); - if ($this->getProxyDumper()->isProxyCandidate($definition)) { - $factoryCode = $asFile ? "\$this->load('%s.php', false)" : '$this->%s(false)'; - $code .= $this->getProxyDumper()->getProxyFactoryCode($definition, $id, \sprintf($factoryCode, $methodName, $this->doExport($id))); - } - if ($definition->isDeprecated()) { - $code .= \sprintf(" @trigger_error(%s, E_USER_DEPRECATED);\n\n", $this->export($definition->getDeprecationMessage($id))); - } - $code .= $this->addInlineService($id, $definition); - if ($asFile) { - $code = \implode("\n", \array_map(function ($line) { - return $line ? \substr($line, 8) : $line; - }, \explode("\n", $code))); - } else { - $code .= " }\n"; - } - $this->definitionVariables = $this->inlinedDefinitions = null; - $this->referenceVariables = $this->serviceCalls = null; - return $code; - } - private function addInlineVariables($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, array $arguments, $forConstructor) - { - $code = ''; - foreach ($arguments as $argument) { - if (\is_array($argument)) { - $code .= $this->addInlineVariables($id, $definition, $argument, $forConstructor); - } elseif ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $code .= $this->addInlineReference($id, $definition, $this->container->normalizeId($argument), $forConstructor); - } elseif ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - $code .= $this->addInlineService($id, $definition, $argument, $forConstructor); - } - } - return $code; - } - private function addInlineReference($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $targetId, $forConstructor) - { - while ($this->container->hasAlias($targetId)) { - $targetId = (string) $this->container->getAlias($targetId); - } - list($callCount, $behavior) = $this->serviceCalls[$targetId]; - if ($id === $targetId) { - return $this->addInlineService($id, $definition, $definition); - } - if ('service_container' === $targetId || isset($this->referenceVariables[$targetId])) { - return ''; - } - $hasSelfRef = isset($this->circularReferences[$id][$targetId]) && !isset($this->definitionVariables[$definition]); - if ($hasSelfRef && !$forConstructor && !($forConstructor = !$this->circularReferences[$id][$targetId])) { - $code = $this->addInlineService($id, $definition, $definition); - } else { - $code = ''; - } - if (isset($this->referenceVariables[$targetId]) || 2 > $callCount && (!$hasSelfRef || !$forConstructor)) { - return $code; - } - $name = $this->getNextVariableName(); - $this->referenceVariables[$targetId] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable($name); - $reference = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE >= $behavior ? new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($targetId, $behavior) : null; - $code .= \sprintf(" \$%s = %s;\n", $name, $this->getServiceCall($targetId, $reference)); - if (!$hasSelfRef || !$forConstructor) { - return $code; - } - $code .= \sprintf(<<<'EOTXT' - - if (isset($this->%s[%s])) { - return $this->%1$s[%2$s]; - } - -EOTXT -, 'services', $this->doExport($id)); - return $code; - } - private function addInlineService($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $inlineDef = null, $forConstructor = \true) - { - $code = ''; - if ($isSimpleInstance = $isRootInstance = null === $inlineDef) { - foreach ($this->serviceCalls as $targetId => list($callCount, $behavior, $byConstructor)) { - if ($byConstructor && isset($this->circularReferences[$id][$targetId]) && !$this->circularReferences[$id][$targetId]) { - $code .= $this->addInlineReference($id, $definition, $targetId, $forConstructor); - } - } - } - if (isset($this->definitionVariables[$inlineDef = $inlineDef ?: $definition])) { - return $code; - } - $arguments = [$inlineDef->getArguments(), $inlineDef->getFactory()]; - $code .= $this->addInlineVariables($id, $definition, $arguments, $forConstructor); - if ($arguments = \array_filter([$inlineDef->getProperties(), $inlineDef->getMethodCalls(), $inlineDef->getConfigurator()])) { - $isSimpleInstance = \false; - } elseif ($definition !== $inlineDef && 2 > $this->inlinedDefinitions[$inlineDef]) { - return $code; - } - if (isset($this->definitionVariables[$inlineDef])) { - $isSimpleInstance = \false; - } else { - $name = $definition === $inlineDef ? 'instance' : $this->getNextVariableName(); - $this->definitionVariables[$inlineDef] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable($name); - $code .= '' !== $code ? "\n" : ''; - if ('instance' === $name) { - $code .= $this->addServiceInstance($id, $definition, $isSimpleInstance); - } else { - $code .= $this->addNewInstance($inlineDef, '$' . $name, ' = ', $id); - } - if ('' !== ($inline = $this->addInlineVariables($id, $definition, $arguments, \false))) { - $code .= "\n" . $inline . "\n"; - } elseif ($arguments && 'instance' === $name) { - $code .= "\n"; - } - $code .= $this->addServiceProperties($inlineDef, $name); - $code .= $this->addServiceMethodCalls($inlineDef, $name); - $code .= $this->addServiceConfigurator($inlineDef, $name); - } - if ($isRootInstance && !$isSimpleInstance) { - $code .= "\n return \$instance;\n"; - } - return $code; - } - /** - * Adds multiple services. - * - * @return string - */ - private function addServices() - { - $publicServices = $privateServices = ''; - $definitions = $this->container->getDefinitions(); - \ksort($definitions); - foreach ($definitions as $id => $definition) { - if ($definition->isSynthetic() || $this->asFiles && $definition->isShared() && !$this->isHotPath($definition)) { - continue; - } - if ($definition->isPublic()) { - $publicServices .= $this->addService($id, $definition); - } else { - $privateServices .= $this->addService($id, $definition); - } - } - return $publicServices . $privateServices; - } - private function generateServiceFiles() - { - $definitions = $this->container->getDefinitions(); - \ksort($definitions); - foreach ($definitions as $id => $definition) { - if (!$definition->isSynthetic() && $definition->isShared() && !$this->isHotPath($definition)) { - $code = $this->addService($id, $definition, $file); - (yield $file => $code); - } - } - } - private function addNewInstance(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $return, $instantiation, $id) - { - $class = $this->dumpValue($definition->getClass()); - $return = ' ' . $return . $instantiation; - $arguments = []; - foreach ($definition->getArguments() as $value) { - $arguments[] = $this->dumpValue($value); - } - if (null !== $definition->getFactory()) { - $callable = $definition->getFactory(); - if (\is_array($callable)) { - if (!\preg_match('/^[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*$/', $callable[1])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Cannot dump definition because of invalid factory method (%s).', $callable[1] ?: 'n/a')); - } - if ($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || $callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && $this->definitionVariables->contains($callable[0])) { - return $return . \sprintf("%s->%s(%s);\n", $this->dumpValue($callable[0]), $callable[1], $arguments ? \implode(', ', $arguments) : ''); - } - $class = $this->dumpValue($callable[0]); - // If the class is a string we can optimize call_user_func away - if (0 === \strpos($class, "'") && \false === \strpos($class, '$')) { - if ("''" === $class) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Cannot dump definition: The "%s" service is defined to be created by a factory but is missing the service reference, did you forget to define the factory service id or class?', $id)); - } - return $return . \sprintf("%s::%s(%s);\n", $this->dumpLiteralClass($class), $callable[1], $arguments ? \implode(', ', $arguments) : ''); - } - if (0 === \strpos($class, 'new ')) { - return $return . \sprintf("(%s)->%s(%s);\n", $class, $callable[1], $arguments ? \implode(', ', $arguments) : ''); - } - return $return . \sprintf("\\call_user_func([%s, '%s']%s);\n", $class, $callable[1], $arguments ? ', ' . \implode(', ', $arguments) : ''); - } - return $return . \sprintf("%s(%s);\n", $this->dumpLiteralClass($this->dumpValue($callable)), $arguments ? \implode(', ', $arguments) : ''); - } - if (\false !== \strpos($class, '$')) { - return \sprintf(" \$class = %s;\n\n%snew \$class(%s);\n", $class, $return, \implode(', ', $arguments)); - } - return $return . \sprintf("new %s(%s);\n", $this->dumpLiteralClass($class), \implode(', ', $arguments)); - } - /** - * Adds the class headers. - * - * @param string $class Class name - * @param string $baseClass The name of the base class - * @param string $baseClassWithNamespace Fully qualified base class name - * - * @return string - */ - private function startClass($class, $baseClass, $baseClassWithNamespace) - { - $bagClass = $this->container->isCompiled() ? 'use _PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\FrozenParameterBag;' : 'use _PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\ParameterBag;'; - $namespaceLine = !$this->asFiles && $this->namespace ? "\nnamespace {$this->namespace};\n" : ''; - $code = <<docStar} - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -class {$class} extends {$baseClass} -{ - private \$parameters = []; - private \$targetDirs = []; - - public function __construct() - { - -EOF; - if (null !== $this->targetDirRegex) { - $dir = $this->asFiles ? '$this->targetDirs[0] = \\dirname($containerDir)' : '__DIR__'; - $code .= <<targetDirMaxMatches}; ++\$i) { - \$this->targetDirs[\$i] = \$dir = \\dirname(\$dir); - } - -EOF; - } - if ($this->asFiles) { - $code = \str_replace('$parameters', "\$buildParameters;\n private \$containerDir;\n private \$parameters", $code); - $code = \str_replace('__construct()', '__construct(array $buildParameters = [], $containerDir = __DIR__)', $code); - $code .= " \$this->buildParameters = \$buildParameters;\n"; - $code .= " \$this->containerDir = \$containerDir;\n"; - } - if ($this->container->isCompiled()) { - if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::class !== $baseClassWithNamespace) { - $r = $this->container->getReflectionClass($baseClassWithNamespace, \false); - if (null !== $r && null !== ($constructor = $r->getConstructor()) && 0 === $constructor->getNumberOfRequiredParameters() && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::class !== $constructor->getDeclaringClass()->name) { - $code .= " parent::__construct();\n"; - $code .= " \$this->parameterBag = null;\n\n"; - } - } - if ($this->container->getParameterBag()->all()) { - $code .= " \$this->parameters = \$this->getDefaultParameters();\n\n"; - } - $code .= " \$this->services = [];\n"; - } else { - $arguments = $this->container->getParameterBag()->all() ? 'new ParameterBag($this->getDefaultParameters())' : null; - $code .= " parent::__construct({$arguments});\n"; - } - $code .= $this->addNormalizedIds(); - $code .= $this->addSyntheticIds(); - $code .= $this->addMethodMap(); - $code .= $this->asFiles ? $this->addFileMap() : ''; - $code .= $this->addPrivateServices(); - $code .= $this->addAliases(); - $code .= $this->addInlineRequires(); - $code .= <<<'EOF' - } - -EOF; - $code .= $this->addRemovedIds(); - if ($this->container->isCompiled()) { - $code .= <<asFiles) { - $code .= <<containerDir.\\DIRECTORY_SEPARATOR.\$file; - } - -EOF; - } - $proxyDumper = $this->getProxyDumper(); - foreach ($this->container->getDefinitions() as $definition) { - if (!$proxyDumper->isProxyCandidate($definition)) { - continue; - } - if ($this->asFiles) { - $proxyLoader = '$this->load("{$class}.php")'; - } elseif ($this->namespace) { - $proxyLoader = 'class_alias("' . $this->namespace . '\\\\{$class}", $class, false)'; - } else { - $proxyLoader = ''; - } - if ($proxyLoader) { - $proxyLoader = "class_exists(\$class, false) || {$proxyLoader};\n\n "; - } - $code .= <<container->getNormalizedIds(); - \ksort($normalizedIds); - foreach ($normalizedIds as $id => $normalizedId) { - if ($this->container->has($normalizedId)) { - $code .= ' ' . $this->doExport($id) . ' => ' . $this->doExport($normalizedId) . ",\n"; - } - } - return $code ? " \$this->normalizedIds = [\n" . $code . " ];\n" : ''; - } - /** - * Adds the syntheticIds definition. - * - * @return string - */ - private function addSyntheticIds() - { - $code = ''; - $definitions = $this->container->getDefinitions(); - \ksort($definitions); - foreach ($definitions as $id => $definition) { - if ($definition->isSynthetic() && 'service_container' !== $id) { - $code .= ' ' . $this->doExport($id) . " => true,\n"; - } - } - return $code ? " \$this->syntheticIds = [\n{$code} ];\n" : ''; - } - /** - * Adds the removedIds definition. - * - * @return string - */ - private function addRemovedIds() - { - if (!($ids = $this->container->getRemovedIds())) { - return ''; - } - if ($this->asFiles) { - $code = "require \$this->containerDir.\\DIRECTORY_SEPARATOR.'removed-ids.php'"; - } else { - $code = ''; - $ids = \array_keys($ids); - \sort($ids); - foreach ($ids as $id) { - if (\preg_match('/^\\d+_[^~]++~[._a-zA-Z\\d]{7}$/', $id)) { - continue; - } - $code .= ' ' . $this->doExport($id) . " => true,\n"; - } - $code = "[\n{$code} ]"; - } - return <<container->getDefinitions(); - \ksort($definitions); - foreach ($definitions as $id => $definition) { - if (!$definition->isSynthetic() && (!$this->asFiles || !$definition->isShared() || $this->isHotPath($definition))) { - $code .= ' ' . $this->doExport($id) . ' => ' . $this->doExport($this->generateMethodName($id)) . ",\n"; - } - } - return $code ? " \$this->methodMap = [\n{$code} ];\n" : ''; - } - /** - * Adds the fileMap property definition. - * - * @return string - */ - private function addFileMap() - { - $code = ''; - $definitions = $this->container->getDefinitions(); - \ksort($definitions); - foreach ($definitions as $id => $definition) { - if (!$definition->isSynthetic() && $definition->isShared() && !$this->isHotPath($definition)) { - $code .= \sprintf(" %s => '%s.php',\n", $this->doExport($id), $this->generateMethodName($id)); - } - } - return $code ? " \$this->fileMap = [\n{$code} ];\n" : ''; - } - /** - * Adds the privates property definition. - * - * @return string - */ - private function addPrivateServices() - { - $code = ''; - $aliases = $this->container->getAliases(); - \ksort($aliases); - foreach ($aliases as $id => $alias) { - if ($alias->isPrivate()) { - $code .= ' ' . $this->doExport($id) . " => true,\n"; - } - } - $definitions = $this->container->getDefinitions(); - \ksort($definitions); - foreach ($definitions as $id => $definition) { - if (!$definition->isPublic()) { - $code .= ' ' . $this->doExport($id) . " => true,\n"; - } - } - if (empty($code)) { - return ''; - } - $out = " \$this->privates = [\n"; - $out .= $code; - $out .= " ];\n"; - return $out; - } - /** - * Adds the aliases property definition. - * - * @return string - */ - private function addAliases() - { - if (!($aliases = $this->container->getAliases())) { - return $this->container->isCompiled() ? "\n \$this->aliases = [];\n" : ''; - } - $code = " \$this->aliases = [\n"; - \ksort($aliases); - foreach ($aliases as $alias => $id) { - $id = $this->container->normalizeId($id); - while (isset($aliases[$id])) { - $id = $this->container->normalizeId($aliases[$id]); - } - $code .= ' ' . $this->doExport($alias) . ' => ' . $this->doExport($id) . ",\n"; - } - return $code . " ];\n"; - } - private function addInlineRequires() - { - if (!$this->hotPathTag || !$this->inlineRequires) { - return ''; - } - $lineage = []; - foreach ($this->container->findTaggedServiceIds($this->hotPathTag) as $id => $tags) { - $definition = $this->container->getDefinition($id); - $inlinedDefinitions = $this->getDefinitionsFromArguments([$definition]); - foreach ($inlinedDefinitions as $def) { - if (\is_string($class = \is_array($factory = $def->getFactory()) && \is_string($factory[0]) ? $factory[0] : $def->getClass())) { - $this->collectLineage($class, $lineage); - } - } - } - $code = ''; - foreach ($lineage as $file) { - if (!isset($this->inlinedRequires[$file])) { - $this->inlinedRequires[$file] = \true; - $code .= \sprintf("\n include_once %s;", $file); - } - } - return $code ? \sprintf("\n \$this->privates['service_container'] = function () {%s\n };\n", $code) : ''; - } - /** - * Adds default parameters method. - * - * @return string - */ - private function addDefaultParametersMethod() - { - if (!$this->container->getParameterBag()->all()) { - return ''; - } - $php = []; - $dynamicPhp = []; - $normalizedParams = []; - foreach ($this->container->getParameterBag()->all() as $key => $value) { - if ($key !== ($resolvedKey = $this->container->resolveEnvPlaceholders($key))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter name cannot use env parameters: "%s".', $resolvedKey)); - } - if ($key !== ($lcKey = \strtolower($key))) { - $normalizedParams[] = \sprintf(' %s => %s,', $this->export($lcKey), $this->export($key)); - } - $export = $this->exportParameters([$value]); - $export = \explode('0 => ', \substr(\rtrim($export, " ]\n"), 2, -1), 2); - if (\preg_match("/\\\$this->(?:getEnv\\('(?:\\w++:)*+\\w++'\\)|targetDirs\\[\\d++\\])/", $export[1])) { - $dynamicPhp[$key] = \sprintf('%scase %s: $value = %s; break;', $export[0], $this->export($key), $export[1]); - } else { - $php[] = \sprintf('%s%s => %s,', $export[0], $this->export($key), $export[1]); - } - } - $parameters = \sprintf("[\n%s\n%s]", \implode("\n", $php), \str_repeat(' ', 8)); - $code = ''; - if ($this->container->isCompiled()) { - $code .= <<<'EOF' - - public function getParameter($name) - { - $name = (string) $name; - if (isset($this->buildParameters[$name])) { - return $this->buildParameters[$name]; - } - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters))) { - throw new InvalidArgumentException(sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - - return $this->parameters[$name]; - } - - public function hasParameter($name) - { - $name = (string) $name; - if (isset($this->buildParameters[$name])) { - return true; - } - $name = $this->normalizeParameterName($name); - - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters); - } - - public function setParameter($name, $value) - { - throw new LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - foreach ($this->buildParameters as $name => $value) { - $parameters[$name] = $value; - } - $this->parameterBag = new FrozenParameterBag($parameters); - } - - return $this->parameterBag; - } - -EOF; - if (!$this->asFiles) { - $code = \preg_replace('/^.*buildParameters.*\\n.*\\n.*\\n/m', '', $code); - } - if ($dynamicPhp) { - $loadedDynamicParameters = $this->exportParameters(\array_combine(\array_keys($dynamicPhp), \array_fill(0, \count($dynamicPhp), \false)), '', 8); - $getDynamicParameter = <<<'EOF' - switch ($name) { -%s - default: throw new InvalidArgumentException(sprintf('The dynamic parameter "%%s" must be defined.', $name)); - } - $this->loadedDynamicParameters[$name] = true; - - return $this->dynamicParameters[$name] = $value; -EOF; - $getDynamicParameter = \sprintf($getDynamicParameter, \implode("\n", $dynamicPhp)); - } else { - $loadedDynamicParameters = '[]'; - $getDynamicParameter = \str_repeat(' ', 8) . 'throw new InvalidArgumentException(sprintf(\'The dynamic parameter "%s" must be defined.\', $name));'; - } - $code .= <<docStar} - * Computes a dynamic parameter. - * - * @param string \$name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter(\$name) - { -{$getDynamicParameter} - } - - -EOF; - $code .= ' private $normalizedParameterNames = ' . ($normalizedParams ? \sprintf("[\n%s\n ];", \implode("\n", $normalizedParams)) : '[];') . "\n"; - $code .= <<<'EOF' - - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = strtolower($name)]) || isset($this->parameters[$normalizedName]) || array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @trigger_error(sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - - return $normalizedName; - } - -EOF; - } elseif ($dynamicPhp) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('You cannot dump a not-frozen container with dynamic parameters.'); - } - $code .= <<docStar} - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return {$parameters}; - } - -EOF; - return $code; - } - /** - * Exports parameters. - * - * @param string $path - * @param int $indent - * - * @return string - * - * @throws InvalidArgumentException - */ - private function exportParameters(array $parameters, $path = '', $indent = 12) - { - $php = []; - foreach ($parameters as $key => $value) { - if (\is_array($value)) { - $value = $this->exportParameters($value, $path . '/' . $key, $indent + 4); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('You cannot dump a container with parameters that contain special arguments. "%s" found in "%s".', \get_class($value), $path . '/' . $key)); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('You cannot dump a container with parameters that contain variable references. Variable "%s" found in "%s".', $value, $path . '/' . $key)); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('You cannot dump a container with parameters that contain service definitions. Definition for "%s" found in "%s".', $value->getClass(), $path . '/' . $key)); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('You cannot dump a container with parameters that contain references to other services (reference to service "%s" found in "%s").', $value, $path . '/' . $key)); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('You cannot dump a container with parameters that contain expressions. Expression "%s" found in "%s".', $value, $path . '/' . $key)); - } else { - $value = $this->export($value); - } - $php[] = \sprintf('%s%s => %s,', \str_repeat(' ', $indent), $this->export($key), $value); - } - return \sprintf("[\n%s\n%s]", \implode("\n", $php), \str_repeat(' ', $indent - 4)); - } - /** - * Ends the class definition. - * - * @return string - */ - private function endClass() - { - return <<<'EOF' -} - -EOF; - } - /** - * Wraps the service conditionals. - * - * @param string $value - * @param string $code - * - * @return string - */ - private function wrapServiceConditionals($value, $code) - { - if (!($condition = $this->getServiceConditionals($value))) { - return $code; - } - // re-indent the wrapped code - $code = \implode("\n", \array_map(function ($line) { - return $line ? ' ' . $line : $line; - }, \explode("\n", $code))); - return \sprintf(" if (%s) {\n%s }\n", $condition, $code); - } - /** - * Get the conditions to execute for conditional services. - * - * @param string $value - * - * @return string|null - */ - private function getServiceConditionals($value) - { - $conditions = []; - foreach (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::getInitializedConditionals($value) as $service) { - if (!$this->container->hasDefinition($service)) { - return 'false'; - } - $conditions[] = \sprintf('isset($this->services[%s])', $this->doExport($service)); - } - foreach (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::getServiceConditionals($value) as $service) { - if ($this->container->hasDefinition($service) && !$this->container->getDefinition($service)->isPublic()) { - continue; - } - $conditions[] = \sprintf('$this->has(%s)', $this->doExport($service)); - } - if (!$conditions) { - return ''; - } - return \implode(' && ', $conditions); - } - private function getDefinitionsFromArguments(array $arguments, \SplObjectStorage $definitions = null, array &$calls = [], $byConstructor = null) - { - if (null === $definitions) { - $definitions = new \SplObjectStorage(); - } - foreach ($arguments as $argument) { - if (\is_array($argument)) { - $this->getDefinitionsFromArguments($argument, $definitions, $calls, $byConstructor); - } elseif ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $id = $this->container->normalizeId($argument); - while ($this->container->hasAlias($id)) { - $id = (string) $this->container->getAlias($id); - } - if (!isset($calls[$id])) { - $calls[$id] = [0, $argument->getInvalidBehavior(), $byConstructor]; - } else { - $calls[$id][1] = \min($calls[$id][1], $argument->getInvalidBehavior()); - } - ++$calls[$id][0]; - } elseif (!$argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - // no-op - } elseif (isset($definitions[$argument])) { - $definitions[$argument] = 1 + $definitions[$argument]; - } else { - $definitions[$argument] = 1; - $arguments = [$argument->getArguments(), $argument->getFactory()]; - $this->getDefinitionsFromArguments($arguments, $definitions, $calls, null === $byConstructor || $byConstructor); - $arguments = [$argument->getProperties(), $argument->getMethodCalls(), $argument->getConfigurator()]; - $this->getDefinitionsFromArguments($arguments, $definitions, $calls, null !== $byConstructor && $byConstructor); - } - } - return $definitions; - } - /** - * Dumps values. - * - * @param mixed $value - * @param bool $interpolate - * - * @return string - * - * @throws RuntimeException - */ - private function dumpValue($value, $interpolate = \true) - { - if (\is_array($value)) { - if ($value && $interpolate && \false !== ($param = \array_search($value, $this->container->getParameterBag()->all(), \true))) { - return $this->dumpValue("%{$param}%"); - } - $code = []; - foreach ($value as $k => $v) { - $code[] = \sprintf('%s => %s', $this->dumpValue($k, $interpolate), $this->dumpValue($v, $interpolate)); - } - return \sprintf('[%s]', \implode(', ', $code)); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { - $scope = [$this->definitionVariables, $this->referenceVariables]; - $this->definitionVariables = $this->referenceVariables = null; - try { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { - $value = $value->getValues()[0]; - $code = $this->dumpValue($value, $interpolate); - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference) { - $code = \sprintf('$f = function (\\%s $v%s) { return $v; }; return $f(%s);', $value->getType(), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE !== $value->getInvalidBehavior() ? ' = null' : '', $code); - } else { - $code = \sprintf('return %s;', $code); - } - return \sprintf("function () {\n %s\n }", $code); - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument) { - $operands = [0]; - $code = []; - $code[] = 'new RewindableGenerator(function () {'; - if (!($values = $value->getValues())) { - $code[] = ' return new \\EmptyIterator();'; - } else { - $countCode = []; - $countCode[] = 'function () {'; - foreach ($values as $k => $v) { - ($c = $this->getServiceConditionals($v)) ? $operands[] = "(int) ({$c})" : ++$operands[0]; - $v = $this->wrapServiceConditionals($v, \sprintf(" yield %s => %s;\n", $this->dumpValue($k, $interpolate), $this->dumpValue($v, $interpolate))); - foreach (\explode("\n", $v) as $v) { - if ($v) { - $code[] = ' ' . $v; - } - } - } - $countCode[] = \sprintf(' return %s;', \implode(' + ', $operands)); - $countCode[] = ' }'; - } - $code[] = \sprintf(' }, %s)', \count($operands) > 1 ? \implode("\n", $countCode) : $operands[0]); - return \implode("\n", $code); - } - } finally { - list($this->definitionVariables, $this->referenceVariables) = $scope; - } - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - if (null !== $this->definitionVariables && $this->definitionVariables->contains($value)) { - return $this->dumpValue($this->definitionVariables[$value], $interpolate); - } - if ($value->getMethodCalls()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Cannot dump definitions which have method calls.'); - } - if ($value->getProperties()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Cannot dump definitions which have properties.'); - } - if (null !== $value->getConfigurator()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Cannot dump definitions which have a configurator.'); - } - $arguments = []; - foreach ($value->getArguments() as $argument) { - $arguments[] = $this->dumpValue($argument); - } - if (null !== $value->getFactory()) { - $factory = $value->getFactory(); - if (\is_string($factory)) { - return \sprintf('%s(%s)', $this->dumpLiteralClass($this->dumpValue($factory)), \implode(', ', $arguments)); - } - if (\is_array($factory)) { - if (!\preg_match('/^[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*$/', $factory[1])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Cannot dump definition because of invalid factory method (%s).', $factory[1] ?: 'n/a')); - } - $class = $this->dumpValue($factory[0]); - if (\is_string($factory[0])) { - return \sprintf('%s::%s(%s)', $this->dumpLiteralClass($class), $factory[1], \implode(', ', $arguments)); - } - if ($factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - if (0 === \strpos($class, 'new ')) { - return \sprintf('(%s)->%s(%s)', $class, $factory[1], \implode(', ', $arguments)); - } - return \sprintf("\\call_user_func([%s, '%s']%s)", $class, $factory[1], \count($arguments) > 0 ? ', ' . \implode(', ', $arguments) : ''); - } - if ($factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - return \sprintf('%s->%s(%s)', $class, $factory[1], \implode(', ', $arguments)); - } - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Cannot dump definition because of invalid factory.'); - } - $class = $value->getClass(); - if (null === $class) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Cannot dump definitions which have no class nor factory.'); - } - return \sprintf('new %s(%s)', $this->dumpLiteralClass($this->dumpValue($class)), \implode(', ', $arguments)); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable) { - return '$' . $value; - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $id = $this->container->normalizeId($value); - while ($this->container->hasAlias($id)) { - $id = (string) $this->container->getAlias($id); - } - if (null !== $this->referenceVariables && isset($this->referenceVariables[$id])) { - return $this->dumpValue($this->referenceVariables[$id], $interpolate); - } - return $this->getServiceCall($id, $value); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { - return $this->getExpressionLanguage()->compile((string) $value, ['this' => 'container']); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { - return $this->dumpParameter($value); - } elseif (\true === $interpolate && \is_string($value)) { - if (\preg_match('/^%([^%]+)%$/', $value, $match)) { - // we do this to deal with non string values (Boolean, integer, ...) - // the preg_replace_callback converts them to strings - return $this->dumpParameter($match[1]); - } else { - $replaceParameters = function ($match) { - return "'." . $this->dumpParameter($match[2]) . ".'"; - }; - $code = \str_replace('%%', '%', \preg_replace_callback('/(?export($value))); - return $code; - } - } elseif (\is_object($value) || \is_resource($value)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to dump a service container if a parameter is an object or a resource.'); - } - return $this->export($value); - } - /** - * Dumps a string to a literal (aka PHP Code) class value. - * - * @param string $class - * - * @return string - * - * @throws RuntimeException - */ - private function dumpLiteralClass($class) - { - if (\false !== \strpos($class, '$')) { - return \sprintf('${($_ = %s) && false ?: "_"}', $class); - } - if (0 !== \strpos($class, "'") || !\preg_match('/^\'(?:\\\\{2})?[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*(?:\\\\{2}[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*)*\'$/', $class)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Cannot dump definition because of invalid class name (%s).', $class ?: 'n/a')); - } - $class = \substr(\str_replace('\\\\', '\\', $class), 1, -1); - return 0 === \strpos($class, '\\') ? $class : '\\' . $class; - } - /** - * Dumps a parameter. - * - * @param string $name - * - * @return string - */ - private function dumpParameter($name) - { - $name = (string) $name; - if ($this->container->isCompiled() && $this->container->hasParameter($name)) { - $value = $this->container->getParameter($name); - $dumpedValue = $this->dumpValue($value, \false); - if (!$value || !\is_array($value)) { - return $dumpedValue; - } - if (!\preg_match("/\\\$this->(?:getEnv\\('(?:\\w++:)*+\\w++'\\)|targetDirs\\[\\d++\\])/", $dumpedValue)) { - return \sprintf('$this->parameters[%s]', $this->doExport($name)); - } - } - return \sprintf('$this->getParameter(%s)', $this->doExport($name)); - } - /** - * Gets a service call. - * - * @param string $id - * @param Reference $reference - * - * @return string - */ - private function getServiceCall($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference $reference = null) - { - while ($this->container->hasAlias($id)) { - $id = (string) $this->container->getAlias($id); - } - $id = $this->container->normalizeId($id); - if ('service_container' === $id) { - return '$this'; - } - if ($this->container->hasDefinition($id) && ($definition = $this->container->getDefinition($id))) { - if ($definition->isSynthetic()) { - $code = \sprintf('$this->get(%s%s)', $this->doExport($id), null !== $reference ? ', ' . $reference->getInvalidBehavior() : ''); - } elseif (null !== $reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE === $reference->getInvalidBehavior()) { - $code = 'null'; - if (!$definition->isShared()) { - return $code; - } - } elseif ($this->isTrivialInstance($definition)) { - $code = \substr($this->addNewInstance($definition, '', '', $id), 8, -2); - if ($definition->isShared()) { - $code = \sprintf('$this->services[%s] = %s', $this->doExport($id), $code); - } - $code = "({$code})"; - } elseif ($this->asFiles && $definition->isShared() && !$this->isHotPath($definition)) { - $code = \sprintf("\$this->load('%s.php')", $this->generateMethodName($id)); - } else { - $code = \sprintf('$this->%s()', $this->generateMethodName($id)); - } - } elseif (null !== $reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE === $reference->getInvalidBehavior()) { - return 'null'; - } elseif (null !== $reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE !== $reference->getInvalidBehavior()) { - $code = \sprintf('$this->get(%s, /* ContainerInterface::NULL_ON_INVALID_REFERENCE */ %d)', $this->doExport($id), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE); - } else { - $code = \sprintf('$this->get(%s)', $this->doExport($id)); - } - // The following is PHP 5.5 syntax for what could be written as "(\$this->services['$id'] ?? $code)" on PHP>=7.0 - return \sprintf("\${(\$_ = isset(\$this->services[%s]) ? \$this->services[%1\$s] : %s) && false ?: '_'}", $this->doExport($id), $code); - } - /** - * Initializes the method names map to avoid conflicts with the Container methods. - * - * @param string $class the container base class - */ - private function initializeMethodNamesMap($class) - { - $this->serviceIdToMethodNameMap = []; - $this->usedMethodNames = []; - if ($reflectionClass = $this->container->getReflectionClass($class)) { - foreach ($reflectionClass->getMethods() as $method) { - $this->usedMethodNames[\strtolower($method->getName())] = \true; - } - } - } - /** - * Convert a service id to a valid PHP method name. - * - * @param string $id - * - * @return string - * - * @throws InvalidArgumentException - */ - private function generateMethodName($id) - { - if (isset($this->serviceIdToMethodNameMap[$id])) { - return $this->serviceIdToMethodNameMap[$id]; - } - $i = \strrpos($id, '\\'); - $name = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::camelize(\false !== $i && isset($id[1 + $i]) ? \substr($id, 1 + $i) : $id); - $name = \preg_replace('/[^a-zA-Z0-9_\\x7f-\\xff]/', '', $name); - $methodName = 'get' . $name . 'Service'; - $suffix = 1; - while (isset($this->usedMethodNames[\strtolower($methodName)])) { - ++$suffix; - $methodName = 'get' . $name . $suffix . 'Service'; - } - $this->serviceIdToMethodNameMap[$id] = $methodName; - $this->usedMethodNames[\strtolower($methodName)] = \true; - return $methodName; - } - /** - * Returns the next name to use. - * - * @return string - */ - private function getNextVariableName() - { - $firstChars = self::FIRST_CHARS; - $firstCharsLength = \strlen($firstChars); - $nonFirstChars = self::NON_FIRST_CHARS; - $nonFirstCharsLength = \strlen($nonFirstChars); - while (\true) { - $name = ''; - $i = $this->variableCount; - if ('' === $name) { - $name .= $firstChars[$i % $firstCharsLength]; - $i = (int) ($i / $firstCharsLength); - } - while ($i > 0) { - --$i; - $name .= $nonFirstChars[$i % $nonFirstCharsLength]; - $i = (int) ($i / $nonFirstCharsLength); - } - ++$this->variableCount; - // check that the name is not reserved - if (\in_array($name, $this->reservedVariables, \true)) { - continue; - } - return $name; - } - } - private function getExpressionLanguage() - { - if (null === $this->expressionLanguage) { - if (!\class_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to use expressions as the Symfony ExpressionLanguage component is not installed.'); - } - $providers = $this->container->getExpressionLanguageProviders(); - $this->expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage(null, $providers, function ($arg) { - $id = '""' === \substr_replace($arg, '', 1, -1) ? \stripcslashes(\substr($arg, 1, -1)) : null; - if (null !== $id && ($this->container->hasAlias($id) || $this->container->hasDefinition($id))) { - return $this->getServiceCall($id); - } - return \sprintf('$this->get(%s)', $arg); - }); - if ($this->container->isTrackingResources()) { - foreach ($providers as $provider) { - $this->container->addObjectResource($provider); - } - } - } - return $this->expressionLanguage; - } - private function isHotPath(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - return $this->hotPathTag && $definition->hasTag($this->hotPathTag) && !$definition->isDeprecated(); - } - private function export($value) - { - if (null !== $this->targetDirRegex && \is_string($value) && \preg_match($this->targetDirRegex, $value, $matches, \PREG_OFFSET_CAPTURE)) { - $prefix = $matches[0][1] ? $this->doExport(\substr($value, 0, $matches[0][1]), \true) . '.' : ''; - $suffix = $matches[0][1] + \strlen($matches[0][0]); - $suffix = isset($value[$suffix]) ? '.' . $this->doExport(\substr($value, $suffix), \true) : ''; - $dirname = $this->asFiles ? '$this->containerDir' : '__DIR__'; - $offset = 1 + $this->targetDirMaxMatches - \count($matches); - if ($this->asFiles || 0 < $offset) { - $dirname = \sprintf('$this->targetDirs[%d]', $offset); - } - if ($prefix || $suffix) { - return \sprintf('(%s%s%s)', $prefix, $dirname, $suffix); - } - return $dirname; - } - return $this->doExport($value, \true); - } - private function doExport($value, $resolveEnv = \false) - { - if (\is_string($value) && \false !== \strpos($value, "\n")) { - $cleanParts = \explode("\n", $value); - $cleanParts = \array_map(function ($part) { - return \var_export($part, \true); - }, $cleanParts); - $export = \implode('."\\n".', $cleanParts); - } else { - $export = \var_export($value, \true); - } - if ($resolveEnv && "'" === $export[0] && $export !== ($resolvedExport = $this->container->resolveEnvPlaceholders($export, "'.\$this->getEnv('string:%s').'"))) { - $export = $resolvedExport; - if (".''" === \substr($export, -3)) { - $export = \substr($export, 0, -3); - if ("'" === $export[1]) { - $export = \substr_replace($export, '', 18, 7); - } - } - if ("'" === $export[1]) { - $export = \substr($export, 3); - } - } - return $export; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface as ProxyDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +use _PhpScoper5ea00cc67502b\Symfony\Component\HttpKernel\Kernel; +/** + * PhpDumper dumps a service container as a PHP class. + * + * @author Fabien Potencier + * @author Johannes M. Schmitt + */ +class PhpDumper extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\Dumper +{ + /** + * Characters that might appear in the generated variable name as first character. + */ + const FIRST_CHARS = 'abcdefghijklmnopqrstuvwxyz'; + /** + * Characters that might appear in the generated variable name as any but the first character. + */ + const NON_FIRST_CHARS = 'abcdefghijklmnopqrstuvwxyz0123456789_'; + private $definitionVariables; + private $referenceVariables; + private $variableCount; + private $inlinedDefinitions; + private $serviceCalls; + private $reservedVariables = ['instance', 'class', 'this']; + private $expressionLanguage; + private $targetDirRegex; + private $targetDirMaxMatches; + private $docStar; + private $serviceIdToMethodNameMap; + private $usedMethodNames; + private $namespace; + private $asFiles; + private $hotPathTag; + private $inlineRequires; + private $inlinedRequires = []; + private $circularReferences = []; + /** + * @var ProxyDumper + */ + private $proxyDumper; + /** + * {@inheritdoc} + */ + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + if (!$container->isCompiled()) { + @\trigger_error('Dumping an uncompiled ContainerBuilder is deprecated since Symfony 3.3 and will not be supported anymore in 4.0. Compile the container beforehand.', \E_USER_DEPRECATED); + } + parent::__construct($container); + } + /** + * Sets the dumper to be used when dumping proxies in the generated container. + */ + public function setProxyDumper(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface $proxyDumper) + { + $this->proxyDumper = $proxyDumper; + } + /** + * Dumps the service container as a PHP class. + * + * Available options: + * + * * class: The class name + * * base_class: The base class name + * * namespace: The class namespace + * * as_files: To split the container in several files + * + * @return string|array A PHP class representing the service container or an array of PHP files if the "as_files" option is set + * + * @throws EnvParameterException When an env var exists but has not been dumped + */ + public function dump(array $options = []) + { + $this->targetDirRegex = null; + $this->inlinedRequires = []; + $options = \array_merge(['class' => 'ProjectServiceContainer', 'base_class' => 'Container', 'namespace' => '', 'as_files' => \false, 'debug' => \true, 'hot_path_tag' => 'container.hot_path', 'inline_class_loader_parameter' => 'container.dumper.inline_class_loader', 'build_time' => \time()], $options); + $this->namespace = $options['namespace']; + $this->asFiles = $options['as_files']; + $this->hotPathTag = $options['hot_path_tag']; + $this->inlineRequires = $options['inline_class_loader_parameter'] && $this->container->hasParameter($options['inline_class_loader_parameter']) && $this->container->getParameter($options['inline_class_loader_parameter']); + if (0 !== \strpos($baseClass = $options['base_class'], '\\') && 'Container' !== $baseClass) { + $baseClass = \sprintf('%s\\%s', $options['namespace'] ? '\\' . $options['namespace'] : '', $baseClass); + $baseClassWithNamespace = $baseClass; + } elseif ('Container' === $baseClass) { + $baseClassWithNamespace = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::class; + } else { + $baseClassWithNamespace = $baseClass; + } + $this->initializeMethodNamesMap('Container' === $baseClass ? \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::class : $baseClass); + if ($this->getProxyDumper() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper) { + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(\true, \false))->process($this->container); + try { + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass())->process($this->container); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException $e) { + $path = $e->getPath(); + \end($path); + $path[\key($path)] .= '". Try running "composer require symfony/proxy-manager-bridge'; + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($e->getServiceId(), $path); + } + } + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(\false, !$this->getProxyDumper() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper))->process($this->container); + $checkedNodes = []; + $this->circularReferences = []; + foreach ($this->container->getCompiler()->getServiceReferenceGraph()->getNodes() as $id => $node) { + if (!$node->getValue() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + continue; + } + if (!isset($checkedNodes[$id])) { + $this->analyzeCircularReferences($id, $node->getOutEdges(), $checkedNodes); + } + } + $this->container->getCompiler()->getServiceReferenceGraph()->clear(); + $checkedNodes = []; + $this->docStar = $options['debug'] ? '*' : ''; + if (!empty($options['file']) && \is_dir($dir = \dirname($options['file']))) { + // Build a regexp where the first root dirs are mandatory, + // but every other sub-dir is optional up to the full path in $dir + // Mandate at least 1 root dir and not more than 5 optional dirs. + $dir = \explode(\DIRECTORY_SEPARATOR, \realpath($dir)); + $i = \count($dir); + if (2 + (int) ('\\' === \DIRECTORY_SEPARATOR) <= $i) { + $regex = ''; + $lastOptionalDir = $i > 8 ? $i - 5 : 2 + (int) ('\\' === \DIRECTORY_SEPARATOR); + $this->targetDirMaxMatches = $i - $lastOptionalDir; + while (--$i >= $lastOptionalDir) { + $regex = \sprintf('(%s%s)?', \preg_quote(\DIRECTORY_SEPARATOR . $dir[$i], '#'), $regex); + } + do { + $regex = \preg_quote(\DIRECTORY_SEPARATOR . $dir[$i], '#') . $regex; + } while (0 < --$i); + $this->targetDirRegex = '#' . \preg_quote($dir[0], '#') . $regex . '#'; + } + } + $code = $this->startClass($options['class'], $baseClass, $baseClassWithNamespace) . $this->addServices() . $this->addDefaultParametersMethod() . $this->endClass(); + if ($this->asFiles) { + $fileStart = <<container->getRemovedIds())) { + \sort($ids); + $c = "doExport($id) . " => true,\n"; + } + $files['removed-ids.php'] = $c . "];\n"; + } + foreach ($this->generateServiceFiles() as $file => $c) { + $files[$file] = $fileStart . $c; + } + foreach ($this->generateProxyClasses() as $file => $c) { + $files[$file] = " $c) { + $code["Container{$hash}/{$file}"] = $c; + } + \array_pop($code); + $code["Container{$hash}/{$options['class']}.php"] = \substr_replace($files[$options['class'] . '.php'], "namespace ? "\nnamespace {$this->namespace};\n" : ''; + $time = $options['build_time']; + $id = \hash('crc32', $hash . $time); + $code[$options['class'] . '.php'] = << '{$hash}', + 'container.build_id' => '{$id}', + 'container.build_time' => {$time}, +], __DIR__.\\DIRECTORY_SEPARATOR.'Container{$hash}'); + +EOF; + } else { + foreach ($this->generateProxyClasses() as $c) { + $code .= $c; + } + } + $this->targetDirRegex = null; + $this->inlinedRequires = []; + $this->circularReferences = []; + $unusedEnvs = []; + foreach ($this->container->getEnvCounters() as $env => $use) { + if (!$use) { + $unusedEnvs[] = $env; + } + } + if ($unusedEnvs) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvParameterException($unusedEnvs, null, 'Environment variables "%s" are never used. Please, check your container\'s configuration.'); + } + return $code; + } + /** + * Retrieves the currently set proxy dumper or instantiates one. + * + * @return ProxyDumper + */ + private function getProxyDumper() + { + if (!$this->proxyDumper) { + $this->proxyDumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper(); + } + return $this->proxyDumper; + } + private function analyzeCircularReferences($sourceId, array $edges, &$checkedNodes, &$currentPath = [], $byConstructor = \true) + { + $checkedNodes[$sourceId] = \true; + $currentPath[$sourceId] = $byConstructor; + foreach ($edges as $edge) { + $node = $edge->getDestNode(); + $id = $node->getId(); + if (!$node->getValue() instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || $sourceId === $id || $edge->isLazy() || $edge->isWeak()) { + // no-op + } elseif (isset($currentPath[$id])) { + $this->addCircularReferences($id, $currentPath, $edge->isReferencedByConstructor()); + } elseif (!isset($checkedNodes[$id])) { + $this->analyzeCircularReferences($id, $node->getOutEdges(), $checkedNodes, $currentPath, $edge->isReferencedByConstructor()); + } elseif (isset($this->circularReferences[$id])) { + $this->connectCircularReferences($id, $currentPath, $edge->isReferencedByConstructor()); + } + } + unset($currentPath[$sourceId]); + } + private function connectCircularReferences($sourceId, &$currentPath, $byConstructor, &$subPath = []) + { + $currentPath[$sourceId] = $subPath[$sourceId] = $byConstructor; + foreach ($this->circularReferences[$sourceId] as $id => $byConstructor) { + if (isset($currentPath[$id])) { + $this->addCircularReferences($id, $currentPath, $byConstructor); + } elseif (!isset($subPath[$id]) && isset($this->circularReferences[$id])) { + $this->connectCircularReferences($id, $currentPath, $byConstructor, $subPath); + } + } + unset($currentPath[$sourceId], $subPath[$sourceId]); + } + private function addCircularReferences($id, $currentPath, $byConstructor) + { + $currentPath[$id] = $byConstructor; + $circularRefs = []; + foreach (\array_reverse($currentPath) as $parentId => $v) { + $byConstructor = $byConstructor && $v; + $circularRefs[] = $parentId; + if ($parentId === $id) { + break; + } + } + $currentId = $id; + foreach ($circularRefs as $parentId) { + if (empty($this->circularReferences[$parentId][$currentId])) { + $this->circularReferences[$parentId][$currentId] = $byConstructor; + } + $currentId = $parentId; + } + } + private function collectLineage($class, array &$lineage) + { + if (isset($lineage[$class])) { + return; + } + if (!($r = $this->container->getReflectionClass($class, \false))) { + return; + } + if ($this->container instanceof $class) { + return; + } + $file = $r->getFileName(); + if (!$file || $this->doExport($file) === ($exportedFile = $this->export($file))) { + return; + } + if ($parent = $r->getParentClass()) { + $this->collectLineage($parent->name, $lineage); + } + foreach ($r->getInterfaces() as $parent) { + $this->collectLineage($parent->name, $lineage); + } + foreach ($r->getTraits() as $parent) { + $this->collectLineage($parent->name, $lineage); + } + $lineage[$class] = \substr($exportedFile, 1, -1); + } + private function generateProxyClasses() + { + $alreadyGenerated = []; + $definitions = $this->container->getDefinitions(); + $strip = '' === $this->docStar && \method_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\HttpKernel\\Kernel', 'stripComments'); + $proxyDumper = $this->getProxyDumper(); + \ksort($definitions); + foreach ($definitions as $definition) { + if (!$proxyDumper->isProxyCandidate($definition)) { + continue; + } + if (isset($alreadyGenerated[$class = $definition->getClass()])) { + continue; + } + $alreadyGenerated[$class] = \true; + // register class' reflector for resource tracking + $this->container->getReflectionClass($class); + if ("\n" === ($proxyCode = "\n" . $proxyDumper->getProxyCode($definition))) { + continue; + } + if ($strip) { + $proxyCode = " $proxyCode); + } + } + /** + * Generates the require_once statement for service includes. + * + * @return string + */ + private function addServiceInclude($cId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + $code = ''; + if ($this->inlineRequires && !$this->isHotPath($definition)) { + $lineage = []; + foreach ($this->inlinedDefinitions as $def) { + if (!$def->isDeprecated() && \is_string($class = \is_array($factory = $def->getFactory()) && \is_string($factory[0]) ? $factory[0] : $def->getClass())) { + $this->collectLineage($class, $lineage); + } + } + foreach ($this->serviceCalls as $id => list($callCount, $behavior)) { + if ('service_container' !== $id && $id !== $cId && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE !== $behavior && $this->container->has($id) && $this->isTrivialInstance($def = $this->container->findDefinition($id)) && \is_string($class = \is_array($factory = $def->getFactory()) && \is_string($factory[0]) ? $factory[0] : $def->getClass())) { + $this->collectLineage($class, $lineage); + } + } + foreach (\array_diff_key(\array_flip($lineage), $this->inlinedRequires) as $file => $class) { + $code .= \sprintf(" include_once %s;\n", $file); + } + } + foreach ($this->inlinedDefinitions as $def) { + if ($file = $def->getFile()) { + $code .= \sprintf(" include_once %s;\n", $this->dumpValue($file)); + } + } + if ('' !== $code) { + $code .= "\n"; + } + return $code; + } + /** + * Generates the service instance. + * + * @param string $id + * @param bool $isSimpleInstance + * + * @return string + * + * @throws InvalidArgumentException + * @throws RuntimeException + */ + private function addServiceInstance($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $isSimpleInstance) + { + $class = $this->dumpValue($definition->getClass()); + if (0 === \strpos($class, "'") && \false === \strpos($class, '$') && !\preg_match('/^\'(?:\\\\{2})?[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*(?:\\\\{2}[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*)*\'$/', $class)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"%s" is not a valid class name for the "%s" service.', $class, $id)); + } + $isProxyCandidate = $this->getProxyDumper()->isProxyCandidate($definition); + $instantiation = ''; + if (!$isProxyCandidate && $definition->isShared()) { + $instantiation = \sprintf('$this->services[%s] = %s', $this->doExport($id), $isSimpleInstance ? '' : '$instance'); + } elseif (!$isSimpleInstance) { + $instantiation = '$instance'; + } + $return = ''; + if ($isSimpleInstance) { + $return = 'return '; + } else { + $instantiation .= ' = '; + } + return $this->addNewInstance($definition, $return, $instantiation, $id); + } + /** + * Checks if the definition is a trivial instance. + * + * @return bool + */ + private function isTrivialInstance(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + if ($definition->isSynthetic() || $definition->getFile() || $definition->getMethodCalls() || $definition->getProperties() || $definition->getConfigurator()) { + return \false; + } + if ($definition->isDeprecated() || $definition->isLazy() || $definition->getFactory() || 3 < \count($definition->getArguments())) { + return \false; + } + foreach ($definition->getArguments() as $arg) { + if (!$arg || $arg instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { + continue; + } + if (\is_array($arg) && 3 >= \count($arg)) { + foreach ($arg as $k => $v) { + if ($this->dumpValue($k) !== $this->dumpValue($k, \false)) { + return \false; + } + if (!$v || $v instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { + continue; + } + if ($v instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && $this->container->has($id = (string) $v) && $this->container->findDefinition($id)->isSynthetic()) { + continue; + } + if (!\is_scalar($v) || $this->dumpValue($v) !== $this->dumpValue($v, \false)) { + return \false; + } + } + } elseif ($arg instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference && $this->container->has($id = (string) $arg) && $this->container->findDefinition($id)->isSynthetic()) { + continue; + } elseif (!\is_scalar($arg) || $this->dumpValue($arg) !== $this->dumpValue($arg, \false)) { + return \false; + } + } + return \true; + } + /** + * Adds method calls to a service definition. + * + * @param string $variableName + * + * @return string + */ + private function addServiceMethodCalls(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $variableName = 'instance') + { + $calls = ''; + foreach ($definition->getMethodCalls() as $call) { + $arguments = []; + foreach ($call[1] as $value) { + $arguments[] = $this->dumpValue($value); + } + $calls .= $this->wrapServiceConditionals($call[1], \sprintf(" \$%s->%s(%s);\n", $variableName, $call[0], \implode(', ', $arguments))); + } + return $calls; + } + private function addServiceProperties(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $variableName = 'instance') + { + $code = ''; + foreach ($definition->getProperties() as $name => $value) { + $code .= \sprintf(" \$%s->%s = %s;\n", $variableName, $name, $this->dumpValue($value)); + } + return $code; + } + /** + * Adds configurator definition. + * + * @param string $variableName + * + * @return string + */ + private function addServiceConfigurator(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $variableName = 'instance') + { + if (!($callable = $definition->getConfigurator())) { + return ''; + } + if (\is_array($callable)) { + if ($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || $callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && $this->definitionVariables->contains($callable[0])) { + return \sprintf(" %s->%s(\$%s);\n", $this->dumpValue($callable[0]), $callable[1], $variableName); + } + $class = $this->dumpValue($callable[0]); + // If the class is a string we can optimize call_user_func away + if (0 === \strpos($class, "'") && \false === \strpos($class, '$')) { + return \sprintf(" %s::%s(\$%s);\n", $this->dumpLiteralClass($class), $callable[1], $variableName); + } + if (0 === \strpos($class, 'new ')) { + return \sprintf(" (%s)->%s(\$%s);\n", $this->dumpValue($callable[0]), $callable[1], $variableName); + } + return \sprintf(" \\call_user_func([%s, '%s'], \$%s);\n", $this->dumpValue($callable[0]), $callable[1], $variableName); + } + return \sprintf(" %s(\$%s);\n", $callable, $variableName); + } + /** + * Adds a service. + * + * @param string $id + * @param string &$file + * + * @return string + */ + private function addService($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, &$file = null) + { + $this->definitionVariables = new \SplObjectStorage(); + $this->referenceVariables = []; + $this->variableCount = 0; + $this->referenceVariables[$id] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable('instance'); + $return = []; + if ($class = $definition->getClass()) { + $class = $class instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter ? '%' . $class . '%' : $this->container->resolveEnvPlaceholders($class); + $return[] = \sprintf(0 === \strpos($class, '%') ? '@return object A %1$s instance' : '@return \\%s', \ltrim($class, '\\')); + } elseif ($definition->getFactory()) { + $factory = $definition->getFactory(); + if (\is_string($factory)) { + $return[] = \sprintf('@return object An instance returned by %s()', $factory); + } elseif (\is_array($factory) && (\is_string($factory[0]) || $factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition || $factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference)) { + $class = $factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition ? $factory[0]->getClass() : (string) $factory[0]; + $class = $class instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter ? '%' . $class . '%' : $this->container->resolveEnvPlaceholders($class); + $return[] = \sprintf('@return object An instance returned by %s::%s()', $class, $factory[1]); + } + } + if ($definition->isDeprecated()) { + if ($return && 0 === \strpos($return[\count($return) - 1], '@return')) { + $return[] = ''; + } + $return[] = \sprintf('@deprecated %s', $definition->getDeprecationMessage($id)); + } + $return = \str_replace("\n * \n", "\n *\n", \implode("\n * ", $return)); + $return = $this->container->resolveEnvPlaceholders($return); + $shared = $definition->isShared() ? ' shared' : ''; + $public = $definition->isPublic() ? 'public' : 'private'; + $autowired = $definition->isAutowired() ? ' autowired' : ''; + if ($definition->isLazy()) { + $lazyInitialization = '$lazyLoad = true'; + } else { + $lazyInitialization = ''; + } + $asFile = $this->asFiles && $definition->isShared() && !$this->isHotPath($definition); + $methodName = $this->generateMethodName($id); + if ($asFile) { + $file = $methodName . '.php'; + $code = " // Returns the {$public} '{$id}'{$shared}{$autowired} service.\n\n"; + } else { + $code = <<docStar} + * Gets the {$public} '{$id}'{$shared}{$autowired} service. + * + * {$return} +EOF; + $code = \str_replace('*/', ' ', $code) . <<serviceCalls = []; + $this->inlinedDefinitions = $this->getDefinitionsFromArguments([$definition], null, $this->serviceCalls); + $code .= $this->addServiceInclude($id, $definition); + if ($this->getProxyDumper()->isProxyCandidate($definition)) { + $factoryCode = $asFile ? "\$this->load('%s.php', false)" : '$this->%s(false)'; + $code .= $this->getProxyDumper()->getProxyFactoryCode($definition, $id, \sprintf($factoryCode, $methodName, $this->doExport($id))); + } + if ($definition->isDeprecated()) { + $code .= \sprintf(" @trigger_error(%s, E_USER_DEPRECATED);\n\n", $this->export($definition->getDeprecationMessage($id))); + } + $code .= $this->addInlineService($id, $definition); + if ($asFile) { + $code = \implode("\n", \array_map(function ($line) { + return $line ? \substr($line, 8) : $line; + }, \explode("\n", $code))); + } else { + $code .= " }\n"; + } + $this->definitionVariables = $this->inlinedDefinitions = null; + $this->referenceVariables = $this->serviceCalls = null; + return $code; + } + private function addInlineVariables($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, array $arguments, $forConstructor) + { + $code = ''; + foreach ($arguments as $argument) { + if (\is_array($argument)) { + $code .= $this->addInlineVariables($id, $definition, $argument, $forConstructor); + } elseif ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $code .= $this->addInlineReference($id, $definition, $this->container->normalizeId($argument), $forConstructor); + } elseif ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + $code .= $this->addInlineService($id, $definition, $argument, $forConstructor); + } + } + return $code; + } + private function addInlineReference($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $targetId, $forConstructor) + { + while ($this->container->hasAlias($targetId)) { + $targetId = (string) $this->container->getAlias($targetId); + } + list($callCount, $behavior) = $this->serviceCalls[$targetId]; + if ($id === $targetId) { + return $this->addInlineService($id, $definition, $definition); + } + if ('service_container' === $targetId || isset($this->referenceVariables[$targetId])) { + return ''; + } + $hasSelfRef = isset($this->circularReferences[$id][$targetId]) && !isset($this->definitionVariables[$definition]); + if ($hasSelfRef && !$forConstructor && !($forConstructor = !$this->circularReferences[$id][$targetId])) { + $code = $this->addInlineService($id, $definition, $definition); + } else { + $code = ''; + } + if (isset($this->referenceVariables[$targetId]) || 2 > $callCount && (!$hasSelfRef || !$forConstructor)) { + return $code; + } + $name = $this->getNextVariableName(); + $this->referenceVariables[$targetId] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable($name); + $reference = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE >= $behavior ? new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($targetId, $behavior) : null; + $code .= \sprintf(" \$%s = %s;\n", $name, $this->getServiceCall($targetId, $reference)); + if (!$hasSelfRef || !$forConstructor) { + return $code; + } + $code .= \sprintf(<<<'EOTXT' + + if (isset($this->%s[%s])) { + return $this->%1$s[%2$s]; + } + +EOTXT +, 'services', $this->doExport($id)); + return $code; + } + private function addInlineService($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $inlineDef = null, $forConstructor = \true) + { + $code = ''; + if ($isSimpleInstance = $isRootInstance = null === $inlineDef) { + foreach ($this->serviceCalls as $targetId => list($callCount, $behavior, $byConstructor)) { + if ($byConstructor && isset($this->circularReferences[$id][$targetId]) && !$this->circularReferences[$id][$targetId]) { + $code .= $this->addInlineReference($id, $definition, $targetId, $forConstructor); + } + } + } + if (isset($this->definitionVariables[$inlineDef = $inlineDef ?: $definition])) { + return $code; + } + $arguments = [$inlineDef->getArguments(), $inlineDef->getFactory()]; + $code .= $this->addInlineVariables($id, $definition, $arguments, $forConstructor); + if ($arguments = \array_filter([$inlineDef->getProperties(), $inlineDef->getMethodCalls(), $inlineDef->getConfigurator()])) { + $isSimpleInstance = \false; + } elseif ($definition !== $inlineDef && 2 > $this->inlinedDefinitions[$inlineDef]) { + return $code; + } + if (isset($this->definitionVariables[$inlineDef])) { + $isSimpleInstance = \false; + } else { + $name = $definition === $inlineDef ? 'instance' : $this->getNextVariableName(); + $this->definitionVariables[$inlineDef] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable($name); + $code .= '' !== $code ? "\n" : ''; + if ('instance' === $name) { + $code .= $this->addServiceInstance($id, $definition, $isSimpleInstance); + } else { + $code .= $this->addNewInstance($inlineDef, '$' . $name, ' = ', $id); + } + if ('' !== ($inline = $this->addInlineVariables($id, $definition, $arguments, \false))) { + $code .= "\n" . $inline . "\n"; + } elseif ($arguments && 'instance' === $name) { + $code .= "\n"; + } + $code .= $this->addServiceProperties($inlineDef, $name); + $code .= $this->addServiceMethodCalls($inlineDef, $name); + $code .= $this->addServiceConfigurator($inlineDef, $name); + } + if ($isRootInstance && !$isSimpleInstance) { + $code .= "\n return \$instance;\n"; + } + return $code; + } + /** + * Adds multiple services. + * + * @return string + */ + private function addServices() + { + $publicServices = $privateServices = ''; + $definitions = $this->container->getDefinitions(); + \ksort($definitions); + foreach ($definitions as $id => $definition) { + if ($definition->isSynthetic() || $this->asFiles && $definition->isShared() && !$this->isHotPath($definition)) { + continue; + } + if ($definition->isPublic()) { + $publicServices .= $this->addService($id, $definition); + } else { + $privateServices .= $this->addService($id, $definition); + } + } + return $publicServices . $privateServices; + } + private function generateServiceFiles() + { + $definitions = $this->container->getDefinitions(); + \ksort($definitions); + foreach ($definitions as $id => $definition) { + if (!$definition->isSynthetic() && $definition->isShared() && !$this->isHotPath($definition)) { + $code = $this->addService($id, $definition, $file); + (yield $file => $code); + } + } + } + private function addNewInstance(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $return, $instantiation, $id) + { + $class = $this->dumpValue($definition->getClass()); + $return = ' ' . $return . $instantiation; + $arguments = []; + foreach ($definition->getArguments() as $value) { + $arguments[] = $this->dumpValue($value); + } + if (null !== $definition->getFactory()) { + $callable = $definition->getFactory(); + if (\is_array($callable)) { + if (!\preg_match('/^[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*$/', $callable[1])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Cannot dump definition because of invalid factory method (%s).', $callable[1] ?: 'n/a')); + } + if ($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || $callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition && $this->definitionVariables->contains($callable[0])) { + return $return . \sprintf("%s->%s(%s);\n", $this->dumpValue($callable[0]), $callable[1], $arguments ? \implode(', ', $arguments) : ''); + } + $class = $this->dumpValue($callable[0]); + // If the class is a string we can optimize call_user_func away + if (0 === \strpos($class, "'") && \false === \strpos($class, '$')) { + if ("''" === $class) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Cannot dump definition: The "%s" service is defined to be created by a factory but is missing the service reference, did you forget to define the factory service id or class?', $id)); + } + return $return . \sprintf("%s::%s(%s);\n", $this->dumpLiteralClass($class), $callable[1], $arguments ? \implode(', ', $arguments) : ''); + } + if (0 === \strpos($class, 'new ')) { + return $return . \sprintf("(%s)->%s(%s);\n", $class, $callable[1], $arguments ? \implode(', ', $arguments) : ''); + } + return $return . \sprintf("\\call_user_func([%s, '%s']%s);\n", $class, $callable[1], $arguments ? ', ' . \implode(', ', $arguments) : ''); + } + return $return . \sprintf("%s(%s);\n", $this->dumpLiteralClass($this->dumpValue($callable)), $arguments ? \implode(', ', $arguments) : ''); + } + if (\false !== \strpos($class, '$')) { + return \sprintf(" \$class = %s;\n\n%snew \$class(%s);\n", $class, $return, \implode(', ', $arguments)); + } + return $return . \sprintf("new %s(%s);\n", $this->dumpLiteralClass($class), \implode(', ', $arguments)); + } + /** + * Adds the class headers. + * + * @param string $class Class name + * @param string $baseClass The name of the base class + * @param string $baseClassWithNamespace Fully qualified base class name + * + * @return string + */ + private function startClass($class, $baseClass, $baseClassWithNamespace) + { + $bagClass = $this->container->isCompiled() ? 'use _PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\FrozenParameterBag;' : 'use _PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\ParameterBag;'; + $namespaceLine = !$this->asFiles && $this->namespace ? "\nnamespace {$this->namespace};\n" : ''; + $code = <<docStar} + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +class {$class} extends {$baseClass} +{ + private \$parameters = []; + private \$targetDirs = []; + + public function __construct() + { + +EOF; + if (null !== $this->targetDirRegex) { + $dir = $this->asFiles ? '$this->targetDirs[0] = \\dirname($containerDir)' : '__DIR__'; + $code .= <<targetDirMaxMatches}; ++\$i) { + \$this->targetDirs[\$i] = \$dir = \\dirname(\$dir); + } + +EOF; + } + if ($this->asFiles) { + $code = \str_replace('$parameters', "\$buildParameters;\n private \$containerDir;\n private \$parameters", $code); + $code = \str_replace('__construct()', '__construct(array $buildParameters = [], $containerDir = __DIR__)', $code); + $code .= " \$this->buildParameters = \$buildParameters;\n"; + $code .= " \$this->containerDir = \$containerDir;\n"; + } + if ($this->container->isCompiled()) { + if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::class !== $baseClassWithNamespace) { + $r = $this->container->getReflectionClass($baseClassWithNamespace, \false); + if (null !== $r && null !== ($constructor = $r->getConstructor()) && 0 === $constructor->getNumberOfRequiredParameters() && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::class !== $constructor->getDeclaringClass()->name) { + $code .= " parent::__construct();\n"; + $code .= " \$this->parameterBag = null;\n\n"; + } + } + if ($this->container->getParameterBag()->all()) { + $code .= " \$this->parameters = \$this->getDefaultParameters();\n\n"; + } + $code .= " \$this->services = [];\n"; + } else { + $arguments = $this->container->getParameterBag()->all() ? 'new ParameterBag($this->getDefaultParameters())' : null; + $code .= " parent::__construct({$arguments});\n"; + } + $code .= $this->addNormalizedIds(); + $code .= $this->addSyntheticIds(); + $code .= $this->addMethodMap(); + $code .= $this->asFiles ? $this->addFileMap() : ''; + $code .= $this->addPrivateServices(); + $code .= $this->addAliases(); + $code .= $this->addInlineRequires(); + $code .= <<<'EOF' + } + +EOF; + $code .= $this->addRemovedIds(); + if ($this->container->isCompiled()) { + $code .= <<asFiles) { + $code .= <<containerDir.\\DIRECTORY_SEPARATOR.\$file; + } + +EOF; + } + $proxyDumper = $this->getProxyDumper(); + foreach ($this->container->getDefinitions() as $definition) { + if (!$proxyDumper->isProxyCandidate($definition)) { + continue; + } + if ($this->asFiles) { + $proxyLoader = '$this->load("{$class}.php")'; + } elseif ($this->namespace) { + $proxyLoader = 'class_alias("' . $this->namespace . '\\\\{$class}", $class, false)'; + } else { + $proxyLoader = ''; + } + if ($proxyLoader) { + $proxyLoader = "class_exists(\$class, false) || {$proxyLoader};\n\n "; + } + $code .= <<container->getNormalizedIds(); + \ksort($normalizedIds); + foreach ($normalizedIds as $id => $normalizedId) { + if ($this->container->has($normalizedId)) { + $code .= ' ' . $this->doExport($id) . ' => ' . $this->doExport($normalizedId) . ",\n"; + } + } + return $code ? " \$this->normalizedIds = [\n" . $code . " ];\n" : ''; + } + /** + * Adds the syntheticIds definition. + * + * @return string + */ + private function addSyntheticIds() + { + $code = ''; + $definitions = $this->container->getDefinitions(); + \ksort($definitions); + foreach ($definitions as $id => $definition) { + if ($definition->isSynthetic() && 'service_container' !== $id) { + $code .= ' ' . $this->doExport($id) . " => true,\n"; + } + } + return $code ? " \$this->syntheticIds = [\n{$code} ];\n" : ''; + } + /** + * Adds the removedIds definition. + * + * @return string + */ + private function addRemovedIds() + { + if (!($ids = $this->container->getRemovedIds())) { + return ''; + } + if ($this->asFiles) { + $code = "require \$this->containerDir.\\DIRECTORY_SEPARATOR.'removed-ids.php'"; + } else { + $code = ''; + $ids = \array_keys($ids); + \sort($ids); + foreach ($ids as $id) { + if (\preg_match('/^\\d+_[^~]++~[._a-zA-Z\\d]{7}$/', $id)) { + continue; + } + $code .= ' ' . $this->doExport($id) . " => true,\n"; + } + $code = "[\n{$code} ]"; + } + return <<container->getDefinitions(); + \ksort($definitions); + foreach ($definitions as $id => $definition) { + if (!$definition->isSynthetic() && (!$this->asFiles || !$definition->isShared() || $this->isHotPath($definition))) { + $code .= ' ' . $this->doExport($id) . ' => ' . $this->doExport($this->generateMethodName($id)) . ",\n"; + } + } + return $code ? " \$this->methodMap = [\n{$code} ];\n" : ''; + } + /** + * Adds the fileMap property definition. + * + * @return string + */ + private function addFileMap() + { + $code = ''; + $definitions = $this->container->getDefinitions(); + \ksort($definitions); + foreach ($definitions as $id => $definition) { + if (!$definition->isSynthetic() && $definition->isShared() && !$this->isHotPath($definition)) { + $code .= \sprintf(" %s => '%s.php',\n", $this->doExport($id), $this->generateMethodName($id)); + } + } + return $code ? " \$this->fileMap = [\n{$code} ];\n" : ''; + } + /** + * Adds the privates property definition. + * + * @return string + */ + private function addPrivateServices() + { + $code = ''; + $aliases = $this->container->getAliases(); + \ksort($aliases); + foreach ($aliases as $id => $alias) { + if ($alias->isPrivate()) { + $code .= ' ' . $this->doExport($id) . " => true,\n"; + } + } + $definitions = $this->container->getDefinitions(); + \ksort($definitions); + foreach ($definitions as $id => $definition) { + if (!$definition->isPublic()) { + $code .= ' ' . $this->doExport($id) . " => true,\n"; + } + } + if (empty($code)) { + return ''; + } + $out = " \$this->privates = [\n"; + $out .= $code; + $out .= " ];\n"; + return $out; + } + /** + * Adds the aliases property definition. + * + * @return string + */ + private function addAliases() + { + if (!($aliases = $this->container->getAliases())) { + return $this->container->isCompiled() ? "\n \$this->aliases = [];\n" : ''; + } + $code = " \$this->aliases = [\n"; + \ksort($aliases); + foreach ($aliases as $alias => $id) { + $id = $this->container->normalizeId($id); + while (isset($aliases[$id])) { + $id = $this->container->normalizeId($aliases[$id]); + } + $code .= ' ' . $this->doExport($alias) . ' => ' . $this->doExport($id) . ",\n"; + } + return $code . " ];\n"; + } + private function addInlineRequires() + { + if (!$this->hotPathTag || !$this->inlineRequires) { + return ''; + } + $lineage = []; + foreach ($this->container->findTaggedServiceIds($this->hotPathTag) as $id => $tags) { + $definition = $this->container->getDefinition($id); + $inlinedDefinitions = $this->getDefinitionsFromArguments([$definition]); + foreach ($inlinedDefinitions as $def) { + if (\is_string($class = \is_array($factory = $def->getFactory()) && \is_string($factory[0]) ? $factory[0] : $def->getClass())) { + $this->collectLineage($class, $lineage); + } + } + } + $code = ''; + foreach ($lineage as $file) { + if (!isset($this->inlinedRequires[$file])) { + $this->inlinedRequires[$file] = \true; + $code .= \sprintf("\n include_once %s;", $file); + } + } + return $code ? \sprintf("\n \$this->privates['service_container'] = function () {%s\n };\n", $code) : ''; + } + /** + * Adds default parameters method. + * + * @return string + */ + private function addDefaultParametersMethod() + { + if (!$this->container->getParameterBag()->all()) { + return ''; + } + $php = []; + $dynamicPhp = []; + $normalizedParams = []; + foreach ($this->container->getParameterBag()->all() as $key => $value) { + if ($key !== ($resolvedKey = $this->container->resolveEnvPlaceholders($key))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter name cannot use env parameters: "%s".', $resolvedKey)); + } + if ($key !== ($lcKey = \strtolower($key))) { + $normalizedParams[] = \sprintf(' %s => %s,', $this->export($lcKey), $this->export($key)); + } + $export = $this->exportParameters([$value]); + $export = \explode('0 => ', \substr(\rtrim($export, " ]\n"), 2, -1), 2); + if (\preg_match("/\\\$this->(?:getEnv\\('(?:\\w++:)*+\\w++'\\)|targetDirs\\[\\d++\\])/", $export[1])) { + $dynamicPhp[$key] = \sprintf('%scase %s: $value = %s; break;', $export[0], $this->export($key), $export[1]); + } else { + $php[] = \sprintf('%s%s => %s,', $export[0], $this->export($key), $export[1]); + } + } + $parameters = \sprintf("[\n%s\n%s]", \implode("\n", $php), \str_repeat(' ', 8)); + $code = ''; + if ($this->container->isCompiled()) { + $code .= <<<'EOF' + + public function getParameter($name) + { + $name = (string) $name; + if (isset($this->buildParameters[$name])) { + return $this->buildParameters[$name]; + } + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters))) { + throw new InvalidArgumentException(sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + + return $this->parameters[$name]; + } + + public function hasParameter($name) + { + $name = (string) $name; + if (isset($this->buildParameters[$name])) { + return true; + } + $name = $this->normalizeParameterName($name); + + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters); + } + + public function setParameter($name, $value) + { + throw new LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + foreach ($this->buildParameters as $name => $value) { + $parameters[$name] = $value; + } + $this->parameterBag = new FrozenParameterBag($parameters); + } + + return $this->parameterBag; + } + +EOF; + if (!$this->asFiles) { + $code = \preg_replace('/^.*buildParameters.*\\n.*\\n.*\\n/m', '', $code); + } + if ($dynamicPhp) { + $loadedDynamicParameters = $this->exportParameters(\array_combine(\array_keys($dynamicPhp), \array_fill(0, \count($dynamicPhp), \false)), '', 8); + $getDynamicParameter = <<<'EOF' + switch ($name) { +%s + default: throw new InvalidArgumentException(sprintf('The dynamic parameter "%%s" must be defined.', $name)); + } + $this->loadedDynamicParameters[$name] = true; + + return $this->dynamicParameters[$name] = $value; +EOF; + $getDynamicParameter = \sprintf($getDynamicParameter, \implode("\n", $dynamicPhp)); + } else { + $loadedDynamicParameters = '[]'; + $getDynamicParameter = \str_repeat(' ', 8) . 'throw new InvalidArgumentException(sprintf(\'The dynamic parameter "%s" must be defined.\', $name));'; + } + $code .= <<docStar} + * Computes a dynamic parameter. + * + * @param string \$name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter(\$name) + { +{$getDynamicParameter} + } + + +EOF; + $code .= ' private $normalizedParameterNames = ' . ($normalizedParams ? \sprintf("[\n%s\n ];", \implode("\n", $normalizedParams)) : '[];') . "\n"; + $code .= <<<'EOF' + + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = strtolower($name)]) || isset($this->parameters[$normalizedName]) || array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @trigger_error(sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + + return $normalizedName; + } + +EOF; + } elseif ($dynamicPhp) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('You cannot dump a not-frozen container with dynamic parameters.'); + } + $code .= <<docStar} + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return {$parameters}; + } + +EOF; + return $code; + } + /** + * Exports parameters. + * + * @param string $path + * @param int $indent + * + * @return string + * + * @throws InvalidArgumentException + */ + private function exportParameters(array $parameters, $path = '', $indent = 12) + { + $php = []; + foreach ($parameters as $key => $value) { + if (\is_array($value)) { + $value = $this->exportParameters($value, $path . '/' . $key, $indent + 4); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('You cannot dump a container with parameters that contain special arguments. "%s" found in "%s".', \get_class($value), $path . '/' . $key)); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('You cannot dump a container with parameters that contain variable references. Variable "%s" found in "%s".', $value, $path . '/' . $key)); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('You cannot dump a container with parameters that contain service definitions. Definition for "%s" found in "%s".', $value->getClass(), $path . '/' . $key)); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('You cannot dump a container with parameters that contain references to other services (reference to service "%s" found in "%s").', $value, $path . '/' . $key)); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('You cannot dump a container with parameters that contain expressions. Expression "%s" found in "%s".', $value, $path . '/' . $key)); + } else { + $value = $this->export($value); + } + $php[] = \sprintf('%s%s => %s,', \str_repeat(' ', $indent), $this->export($key), $value); + } + return \sprintf("[\n%s\n%s]", \implode("\n", $php), \str_repeat(' ', $indent - 4)); + } + /** + * Ends the class definition. + * + * @return string + */ + private function endClass() + { + return <<<'EOF' +} + +EOF; + } + /** + * Wraps the service conditionals. + * + * @param string $value + * @param string $code + * + * @return string + */ + private function wrapServiceConditionals($value, $code) + { + if (!($condition = $this->getServiceConditionals($value))) { + return $code; + } + // re-indent the wrapped code + $code = \implode("\n", \array_map(function ($line) { + return $line ? ' ' . $line : $line; + }, \explode("\n", $code))); + return \sprintf(" if (%s) {\n%s }\n", $condition, $code); + } + /** + * Get the conditions to execute for conditional services. + * + * @param string $value + * + * @return string|null + */ + private function getServiceConditionals($value) + { + $conditions = []; + foreach (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::getInitializedConditionals($value) as $service) { + if (!$this->container->hasDefinition($service)) { + return 'false'; + } + $conditions[] = \sprintf('isset($this->services[%s])', $this->doExport($service)); + } + foreach (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::getServiceConditionals($value) as $service) { + if ($this->container->hasDefinition($service) && !$this->container->getDefinition($service)->isPublic()) { + continue; + } + $conditions[] = \sprintf('$this->has(%s)', $this->doExport($service)); + } + if (!$conditions) { + return ''; + } + return \implode(' && ', $conditions); + } + private function getDefinitionsFromArguments(array $arguments, \SplObjectStorage $definitions = null, array &$calls = [], $byConstructor = null) + { + if (null === $definitions) { + $definitions = new \SplObjectStorage(); + } + foreach ($arguments as $argument) { + if (\is_array($argument)) { + $this->getDefinitionsFromArguments($argument, $definitions, $calls, $byConstructor); + } elseif ($argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $id = $this->container->normalizeId($argument); + while ($this->container->hasAlias($id)) { + $id = (string) $this->container->getAlias($id); + } + if (!isset($calls[$id])) { + $calls[$id] = [0, $argument->getInvalidBehavior(), $byConstructor]; + } else { + $calls[$id][1] = \min($calls[$id][1], $argument->getInvalidBehavior()); + } + ++$calls[$id][0]; + } elseif (!$argument instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + // no-op + } elseif (isset($definitions[$argument])) { + $definitions[$argument] = 1 + $definitions[$argument]; + } else { + $definitions[$argument] = 1; + $arguments = [$argument->getArguments(), $argument->getFactory()]; + $this->getDefinitionsFromArguments($arguments, $definitions, $calls, null === $byConstructor || $byConstructor); + $arguments = [$argument->getProperties(), $argument->getMethodCalls(), $argument->getConfigurator()]; + $this->getDefinitionsFromArguments($arguments, $definitions, $calls, null !== $byConstructor && $byConstructor); + } + } + return $definitions; + } + /** + * Dumps values. + * + * @param mixed $value + * @param bool $interpolate + * + * @return string + * + * @throws RuntimeException + */ + private function dumpValue($value, $interpolate = \true) + { + if (\is_array($value)) { + if ($value && $interpolate && \false !== ($param = \array_search($value, $this->container->getParameterBag()->all(), \true))) { + return $this->dumpValue("%{$param}%"); + } + $code = []; + foreach ($value as $k => $v) { + $code[] = \sprintf('%s => %s', $this->dumpValue($k, $interpolate), $this->dumpValue($v, $interpolate)); + } + return \sprintf('[%s]', \implode(', ', $code)); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { + $scope = [$this->definitionVariables, $this->referenceVariables]; + $this->definitionVariables = $this->referenceVariables = null; + try { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { + $value = $value->getValues()[0]; + $code = $this->dumpValue($value, $interpolate); + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference) { + $code = \sprintf('$f = function (\\%s $v%s) { return $v; }; return $f(%s);', $value->getType(), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE !== $value->getInvalidBehavior() ? ' = null' : '', $code); + } else { + $code = \sprintf('return %s;', $code); + } + return \sprintf("function () {\n %s\n }", $code); + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument) { + $operands = [0]; + $code = []; + $code[] = 'new RewindableGenerator(function () {'; + if (!($values = $value->getValues())) { + $code[] = ' return new \\EmptyIterator();'; + } else { + $countCode = []; + $countCode[] = 'function () {'; + foreach ($values as $k => $v) { + ($c = $this->getServiceConditionals($v)) ? $operands[] = "(int) ({$c})" : ++$operands[0]; + $v = $this->wrapServiceConditionals($v, \sprintf(" yield %s => %s;\n", $this->dumpValue($k, $interpolate), $this->dumpValue($v, $interpolate))); + foreach (\explode("\n", $v) as $v) { + if ($v) { + $code[] = ' ' . $v; + } + } + } + $countCode[] = \sprintf(' return %s;', \implode(' + ', $operands)); + $countCode[] = ' }'; + } + $code[] = \sprintf(' }, %s)', \count($operands) > 1 ? \implode("\n", $countCode) : $operands[0]); + return \implode("\n", $code); + } + } finally { + list($this->definitionVariables, $this->referenceVariables) = $scope; + } + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + if (null !== $this->definitionVariables && $this->definitionVariables->contains($value)) { + return $this->dumpValue($this->definitionVariables[$value], $interpolate); + } + if ($value->getMethodCalls()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Cannot dump definitions which have method calls.'); + } + if ($value->getProperties()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Cannot dump definitions which have properties.'); + } + if (null !== $value->getConfigurator()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Cannot dump definitions which have a configurator.'); + } + $arguments = []; + foreach ($value->getArguments() as $argument) { + $arguments[] = $this->dumpValue($argument); + } + if (null !== $value->getFactory()) { + $factory = $value->getFactory(); + if (\is_string($factory)) { + return \sprintf('%s(%s)', $this->dumpLiteralClass($this->dumpValue($factory)), \implode(', ', $arguments)); + } + if (\is_array($factory)) { + if (!\preg_match('/^[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*$/', $factory[1])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Cannot dump definition because of invalid factory method (%s).', $factory[1] ?: 'n/a')); + } + $class = $this->dumpValue($factory[0]); + if (\is_string($factory[0])) { + return \sprintf('%s::%s(%s)', $this->dumpLiteralClass($class), $factory[1], \implode(', ', $arguments)); + } + if ($factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + if (0 === \strpos($class, 'new ')) { + return \sprintf('(%s)->%s(%s)', $class, $factory[1], \implode(', ', $arguments)); + } + return \sprintf("\\call_user_func([%s, '%s']%s)", $class, $factory[1], \count($arguments) > 0 ? ', ' . \implode(', ', $arguments) : ''); + } + if ($factory[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + return \sprintf('%s->%s(%s)', $class, $factory[1], \implode(', ', $arguments)); + } + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Cannot dump definition because of invalid factory.'); + } + $class = $value->getClass(); + if (null === $class) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Cannot dump definitions which have no class nor factory.'); + } + return \sprintf('new %s(%s)', $this->dumpLiteralClass($this->dumpValue($class)), \implode(', ', $arguments)); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable) { + return '$' . $value; + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $id = $this->container->normalizeId($value); + while ($this->container->hasAlias($id)) { + $id = (string) $this->container->getAlias($id); + } + if (null !== $this->referenceVariables && isset($this->referenceVariables[$id])) { + return $this->dumpValue($this->referenceVariables[$id], $interpolate); + } + return $this->getServiceCall($id, $value); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { + return $this->getExpressionLanguage()->compile((string) $value, ['this' => 'container']); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { + return $this->dumpParameter($value); + } elseif (\true === $interpolate && \is_string($value)) { + if (\preg_match('/^%([^%]+)%$/', $value, $match)) { + // we do this to deal with non string values (Boolean, integer, ...) + // the preg_replace_callback converts them to strings + return $this->dumpParameter($match[1]); + } else { + $replaceParameters = function ($match) { + return "'." . $this->dumpParameter($match[2]) . ".'"; + }; + $code = \str_replace('%%', '%', \preg_replace_callback('/(?export($value))); + return $code; + } + } elseif (\is_object($value) || \is_resource($value)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to dump a service container if a parameter is an object or a resource.'); + } + return $this->export($value); + } + /** + * Dumps a string to a literal (aka PHP Code) class value. + * + * @param string $class + * + * @return string + * + * @throws RuntimeException + */ + private function dumpLiteralClass($class) + { + if (\false !== \strpos($class, '$')) { + return \sprintf('${($_ = %s) && false ?: "_"}', $class); + } + if (0 !== \strpos($class, "'") || !\preg_match('/^\'(?:\\\\{2})?[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*(?:\\\\{2}[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*)*\'$/', $class)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Cannot dump definition because of invalid class name (%s).', $class ?: 'n/a')); + } + $class = \substr(\str_replace('\\\\', '\\', $class), 1, -1); + return 0 === \strpos($class, '\\') ? $class : '\\' . $class; + } + /** + * Dumps a parameter. + * + * @param string $name + * + * @return string + */ + private function dumpParameter($name) + { + $name = (string) $name; + if ($this->container->isCompiled() && $this->container->hasParameter($name)) { + $value = $this->container->getParameter($name); + $dumpedValue = $this->dumpValue($value, \false); + if (!$value || !\is_array($value)) { + return $dumpedValue; + } + if (!\preg_match("/\\\$this->(?:getEnv\\('(?:\\w++:)*+\\w++'\\)|targetDirs\\[\\d++\\])/", $dumpedValue)) { + return \sprintf('$this->parameters[%s]', $this->doExport($name)); + } + } + return \sprintf('$this->getParameter(%s)', $this->doExport($name)); + } + /** + * Gets a service call. + * + * @param string $id + * @param Reference $reference + * + * @return string + */ + private function getServiceCall($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference $reference = null) + { + while ($this->container->hasAlias($id)) { + $id = (string) $this->container->getAlias($id); + } + $id = $this->container->normalizeId($id); + if ('service_container' === $id) { + return '$this'; + } + if ($this->container->hasDefinition($id) && ($definition = $this->container->getDefinition($id))) { + if ($definition->isSynthetic()) { + $code = \sprintf('$this->get(%s%s)', $this->doExport($id), null !== $reference ? ', ' . $reference->getInvalidBehavior() : ''); + } elseif (null !== $reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE === $reference->getInvalidBehavior()) { + $code = 'null'; + if (!$definition->isShared()) { + return $code; + } + } elseif ($this->isTrivialInstance($definition)) { + $code = \substr($this->addNewInstance($definition, '', '', $id), 8, -2); + if ($definition->isShared()) { + $code = \sprintf('$this->services[%s] = %s', $this->doExport($id), $code); + } + $code = "({$code})"; + } elseif ($this->asFiles && $definition->isShared() && !$this->isHotPath($definition)) { + $code = \sprintf("\$this->load('%s.php')", $this->generateMethodName($id)); + } else { + $code = \sprintf('$this->%s()', $this->generateMethodName($id)); + } + } elseif (null !== $reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE === $reference->getInvalidBehavior()) { + return 'null'; + } elseif (null !== $reference && \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE !== $reference->getInvalidBehavior()) { + $code = \sprintf('$this->get(%s, /* ContainerInterface::NULL_ON_INVALID_REFERENCE */ %d)', $this->doExport($id), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE); + } else { + $code = \sprintf('$this->get(%s)', $this->doExport($id)); + } + // The following is PHP 5.5 syntax for what could be written as "(\$this->services['$id'] ?? $code)" on PHP>=7.0 + return \sprintf("\${(\$_ = isset(\$this->services[%s]) ? \$this->services[%1\$s] : %s) && false ?: '_'}", $this->doExport($id), $code); + } + /** + * Initializes the method names map to avoid conflicts with the Container methods. + * + * @param string $class the container base class + */ + private function initializeMethodNamesMap($class) + { + $this->serviceIdToMethodNameMap = []; + $this->usedMethodNames = []; + if ($reflectionClass = $this->container->getReflectionClass($class)) { + foreach ($reflectionClass->getMethods() as $method) { + $this->usedMethodNames[\strtolower($method->getName())] = \true; + } + } + } + /** + * Convert a service id to a valid PHP method name. + * + * @param string $id + * + * @return string + * + * @throws InvalidArgumentException + */ + private function generateMethodName($id) + { + if (isset($this->serviceIdToMethodNameMap[$id])) { + return $this->serviceIdToMethodNameMap[$id]; + } + $i = \strrpos($id, '\\'); + $name = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::camelize(\false !== $i && isset($id[1 + $i]) ? \substr($id, 1 + $i) : $id); + $name = \preg_replace('/[^a-zA-Z0-9_\\x7f-\\xff]/', '', $name); + $methodName = 'get' . $name . 'Service'; + $suffix = 1; + while (isset($this->usedMethodNames[\strtolower($methodName)])) { + ++$suffix; + $methodName = 'get' . $name . $suffix . 'Service'; + } + $this->serviceIdToMethodNameMap[$id] = $methodName; + $this->usedMethodNames[\strtolower($methodName)] = \true; + return $methodName; + } + /** + * Returns the next name to use. + * + * @return string + */ + private function getNextVariableName() + { + $firstChars = self::FIRST_CHARS; + $firstCharsLength = \strlen($firstChars); + $nonFirstChars = self::NON_FIRST_CHARS; + $nonFirstCharsLength = \strlen($nonFirstChars); + while (\true) { + $name = ''; + $i = $this->variableCount; + if ('' === $name) { + $name .= $firstChars[$i % $firstCharsLength]; + $i = (int) ($i / $firstCharsLength); + } + while ($i > 0) { + --$i; + $name .= $nonFirstChars[$i % $nonFirstCharsLength]; + $i = (int) ($i / $nonFirstCharsLength); + } + ++$this->variableCount; + // check that the name is not reserved + if (\in_array($name, $this->reservedVariables, \true)) { + continue; + } + return $name; + } + } + private function getExpressionLanguage() + { + if (null === $this->expressionLanguage) { + if (!\class_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionLanguage')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to use expressions as the Symfony ExpressionLanguage component is not installed.'); + } + $providers = $this->container->getExpressionLanguageProviders(); + $this->expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguage(null, $providers, function ($arg) { + $id = '""' === \substr_replace($arg, '', 1, -1) ? \stripcslashes(\substr($arg, 1, -1)) : null; + if (null !== $id && ($this->container->hasAlias($id) || $this->container->hasDefinition($id))) { + return $this->getServiceCall($id); + } + return \sprintf('$this->get(%s)', $arg); + }); + if ($this->container->isTrackingResources()) { + foreach ($providers as $provider) { + $this->container->addObjectResource($provider); + } + } + } + return $this->expressionLanguage; + } + private function isHotPath(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + return $this->hotPathTag && $definition->hasTag($this->hotPathTag) && !$definition->isDeprecated(); + } + private function export($value) + { + if (null !== $this->targetDirRegex && \is_string($value) && \preg_match($this->targetDirRegex, $value, $matches, \PREG_OFFSET_CAPTURE)) { + $prefix = $matches[0][1] ? $this->doExport(\substr($value, 0, $matches[0][1]), \true) . '.' : ''; + $suffix = $matches[0][1] + \strlen($matches[0][0]); + $suffix = isset($value[$suffix]) ? '.' . $this->doExport(\substr($value, $suffix), \true) : ''; + $dirname = $this->asFiles ? '$this->containerDir' : '__DIR__'; + $offset = 1 + $this->targetDirMaxMatches - \count($matches); + if ($this->asFiles || 0 < $offset) { + $dirname = \sprintf('$this->targetDirs[%d]', $offset); + } + if ($prefix || $suffix) { + return \sprintf('(%s%s%s)', $prefix, $dirname, $suffix); + } + return $dirname; + } + return $this->doExport($value, \true); + } + private function doExport($value, $resolveEnv = \false) + { + if (\is_string($value) && \false !== \strpos($value, "\n")) { + $cleanParts = \explode("\n", $value); + $cleanParts = \array_map(function ($part) { + return \var_export($part, \true); + }, $cleanParts); + $export = \implode('."\\n".', $cleanParts); + } else { + $export = \var_export($value, \true); + } + if ($resolveEnv && "'" === $export[0] && $export !== ($resolvedExport = $this->container->resolveEnvPlaceholders($export, "'.\$this->getEnv('string:%s').'"))) { + $export = $resolvedExport; + if (".''" === \substr($export, -3)) { + $export = \substr($export, 0, -3); + if ("'" === $export[1]) { + $export = \substr_replace($export, '', 18, 7); + } + } + if ("'" === $export[1]) { + $export = \substr($export, 3); + } + } + return $export; + } +} diff --git a/vendor/symfony/dependency-injection/Dumper/XmlDumper.php b/vendor/symfony/dependency-injection/Dumper/XmlDumper.php index f378d978e..f263abef8 100644 --- a/vendor/symfony/dependency-injection/Dumper/XmlDumper.php +++ b/vendor/symfony/dependency-injection/Dumper/XmlDumper.php @@ -1,325 +1,325 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -/** - * XmlDumper dumps a service container as an XML string. - * - * @author Fabien Potencier - * @author Martin Hasoň - */ -class XmlDumper extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\Dumper -{ - /** - * @var \DOMDocument - */ - private $document; - /** - * Dumps the service container as an XML string. - * - * @return string An xml string representing of the service container - */ - public function dump(array $options = []) - { - $this->document = new \DOMDocument('1.0', 'utf-8'); - $this->document->formatOutput = \true; - $container = $this->document->createElementNS('http://symfony.com/schema/dic/services', 'container'); - $container->setAttribute('xmlns:xsi', 'http://www.w3.org/2001/XMLSchema-instance'); - $container->setAttribute('xsi:schemaLocation', 'http://symfony.com/schema/dic/services https://symfony.com/schema/dic/services/services-1.0.xsd'); - $this->addParameters($container); - $this->addServices($container); - $this->document->appendChild($container); - $xml = $this->document->saveXML(); - $this->document = null; - return $this->container->resolveEnvPlaceholders($xml); - } - private function addParameters(\DOMElement $parent) - { - $data = $this->container->getParameterBag()->all(); - if (!$data) { - return; - } - if ($this->container->isCompiled()) { - $data = $this->escape($data); - } - $parameters = $this->document->createElement('parameters'); - $parent->appendChild($parameters); - $this->convertParameters($data, 'parameter', $parameters); - } - private function addMethodCalls(array $methodcalls, \DOMElement $parent) - { - foreach ($methodcalls as $methodcall) { - $call = $this->document->createElement('call'); - $call->setAttribute('method', $methodcall[0]); - if (\count($methodcall[1])) { - $this->convertParameters($methodcall[1], 'argument', $call); - } - $parent->appendChild($call); - } - } - /** - * Adds a service. - * - * @param Definition $definition - * @param string $id - */ - private function addService($definition, $id, \DOMElement $parent) - { - $service = $this->document->createElement('service'); - if (null !== $id) { - $service->setAttribute('id', $id); - } - if ($class = $definition->getClass()) { - if ('\\' === \substr($class, 0, 1)) { - $class = \substr($class, 1); - } - $service->setAttribute('class', $class); - } - if (!$definition->isShared()) { - $service->setAttribute('shared', 'false'); - } - if (!$definition->isPrivate()) { - $service->setAttribute('public', $definition->isPublic() ? 'true' : 'false'); - } - if ($definition->isSynthetic()) { - $service->setAttribute('synthetic', 'true'); - } - if ($definition->isLazy()) { - $service->setAttribute('lazy', 'true'); - } - if (null !== ($decorated = $definition->getDecoratedService())) { - list($decorated, $renamedId, $priority) = $decorated; - $service->setAttribute('decorates', $decorated); - if (null !== $renamedId) { - $service->setAttribute('decoration-inner-name', $renamedId); - } - if (0 !== $priority) { - $service->setAttribute('decoration-priority', $priority); - } - } - foreach ($definition->getTags() as $name => $tags) { - foreach ($tags as $attributes) { - $tag = $this->document->createElement('tag'); - $tag->setAttribute('name', $name); - foreach ($attributes as $key => $value) { - $tag->setAttribute($key, $value); - } - $service->appendChild($tag); - } - } - if ($definition->getFile()) { - $file = $this->document->createElement('file'); - $file->appendChild($this->document->createTextNode($definition->getFile())); - $service->appendChild($file); - } - if ($parameters = $definition->getArguments()) { - $this->convertParameters($parameters, 'argument', $service); - } - if ($parameters = $definition->getProperties()) { - $this->convertParameters($parameters, 'property', $service, 'name'); - } - $this->addMethodCalls($definition->getMethodCalls(), $service); - if ($callable = $definition->getFactory()) { - $factory = $this->document->createElement('factory'); - if (\is_array($callable) && $callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - $this->addService($callable[0], null, $factory); - $factory->setAttribute('method', $callable[1]); - } elseif (\is_array($callable)) { - if (null !== $callable[0]) { - $factory->setAttribute($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference ? 'service' : 'class', $callable[0]); - } - $factory->setAttribute('method', $callable[1]); - } else { - $factory->setAttribute('function', $callable); - } - $service->appendChild($factory); - } - if ($definition->isDeprecated()) { - $deprecated = $this->document->createElement('deprecated'); - $deprecated->appendChild($this->document->createTextNode($definition->getDeprecationMessage('%service_id%'))); - $service->appendChild($deprecated); - } - if ($definition->isAutowired()) { - $service->setAttribute('autowire', 'true'); - } - foreach ($definition->getAutowiringTypes(\false) as $autowiringTypeValue) { - $autowiringType = $this->document->createElement('autowiring-type'); - $autowiringType->appendChild($this->document->createTextNode($autowiringTypeValue)); - $service->appendChild($autowiringType); - } - if ($definition->isAutoconfigured()) { - $service->setAttribute('autoconfigure', 'true'); - } - if ($definition->isAbstract()) { - $service->setAttribute('abstract', 'true'); - } - if ($callable = $definition->getConfigurator()) { - $configurator = $this->document->createElement('configurator'); - if (\is_array($callable) && $callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - $this->addService($callable[0], null, $configurator); - $configurator->setAttribute('method', $callable[1]); - } elseif (\is_array($callable)) { - $configurator->setAttribute($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference ? 'service' : 'class', $callable[0]); - $configurator->setAttribute('method', $callable[1]); - } else { - $configurator->setAttribute('function', $callable); - } - $service->appendChild($configurator); - } - $parent->appendChild($service); - } - /** - * Adds a service alias. - * - * @param string $alias - */ - private function addServiceAlias($alias, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias $id, \DOMElement $parent) - { - $service = $this->document->createElement('service'); - $service->setAttribute('id', $alias); - $service->setAttribute('alias', $id); - if (!$id->isPrivate()) { - $service->setAttribute('public', $id->isPublic() ? 'true' : 'false'); - } - $parent->appendChild($service); - } - private function addServices(\DOMElement $parent) - { - $definitions = $this->container->getDefinitions(); - if (!$definitions) { - return; - } - $services = $this->document->createElement('services'); - foreach ($definitions as $id => $definition) { - $this->addService($definition, $id, $services); - } - $aliases = $this->container->getAliases(); - foreach ($aliases as $alias => $id) { - while (isset($aliases[(string) $id])) { - $id = $aliases[(string) $id]; - } - $this->addServiceAlias($alias, $id, $services); - } - $parent->appendChild($services); - } - /** - * Converts parameters. - * - * @param string $type - * @param string $keyAttribute - */ - private function convertParameters(array $parameters, $type, \DOMElement $parent, $keyAttribute = 'key') - { - $withKeys = \array_keys($parameters) !== \range(0, \count($parameters) - 1); - foreach ($parameters as $key => $value) { - $element = $this->document->createElement($type); - if ($withKeys) { - $element->setAttribute($keyAttribute, $key); - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { - $value = $value->getValues()[0]; - } - if (\is_array($value)) { - $element->setAttribute('type', 'collection'); - $this->convertParameters($value, $type, $element, 'key'); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument) { - $element->setAttribute('type', 'tagged'); - $element->setAttribute('tag', $value->getTag()); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument) { - $element->setAttribute('type', 'iterator'); - $this->convertParameters($value->getValues(), $type, $element, 'key'); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $element->setAttribute('type', 'service'); - $element->setAttribute('id', (string) $value); - $behavior = $value->getInvalidBehavior(); - if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE == $behavior) { - $element->setAttribute('on-invalid', 'null'); - } elseif (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE == $behavior) { - $element->setAttribute('on-invalid', 'ignore'); - } elseif (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE == $behavior) { - $element->setAttribute('on-invalid', 'ignore_uninitialized'); - } - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - $element->setAttribute('type', 'service'); - $this->addService($value, null, $element); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { - $element->setAttribute('type', 'expression'); - $text = $this->document->createTextNode(self::phpToXml((string) $value)); - $element->appendChild($text); - } else { - if (\in_array($value, ['null', 'true', 'false'], \true)) { - $element->setAttribute('type', 'string'); - } - if (\is_string($value) && (\is_numeric($value) || \preg_match('/^0b[01]*$/', $value) || \preg_match('/^0x[0-9a-f]++$/i', $value))) { - $element->setAttribute('type', 'string'); - } - $text = $this->document->createTextNode(self::phpToXml($value)); - $element->appendChild($text); - } - $parent->appendChild($element); - } - } - /** - * Escapes arguments. - * - * @return array - */ - private function escape(array $arguments) - { - $args = []; - foreach ($arguments as $k => $v) { - if (\is_array($v)) { - $args[$k] = $this->escape($v); - } elseif (\is_string($v)) { - $args[$k] = \str_replace('%', '%%', $v); - } else { - $args[$k] = $v; - } - } - return $args; - } - /** - * Converts php types to xml types. - * - * @param mixed $value Value to convert - * - * @return string - * - * @throws RuntimeException When trying to dump object or resource - */ - public static function phpToXml($value) - { - switch (\true) { - case null === $value: - return 'null'; - case \true === $value: - return 'true'; - case \false === $value: - return 'false'; - case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter: - return '%' . $value . '%'; - case \is_object($value) || \is_resource($value): - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to dump a service container if a parameter is an object or a resource.'); - default: - return (string) $value; - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +/** + * XmlDumper dumps a service container as an XML string. + * + * @author Fabien Potencier + * @author Martin Hasoň + */ +class XmlDumper extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\Dumper +{ + /** + * @var \DOMDocument + */ + private $document; + /** + * Dumps the service container as an XML string. + * + * @return string An xml string representing of the service container + */ + public function dump(array $options = []) + { + $this->document = new \DOMDocument('1.0', 'utf-8'); + $this->document->formatOutput = \true; + $container = $this->document->createElementNS('http://symfony.com/schema/dic/services', 'container'); + $container->setAttribute('xmlns:xsi', 'http://www.w3.org/2001/XMLSchema-instance'); + $container->setAttribute('xsi:schemaLocation', 'http://symfony.com/schema/dic/services https://symfony.com/schema/dic/services/services-1.0.xsd'); + $this->addParameters($container); + $this->addServices($container); + $this->document->appendChild($container); + $xml = $this->document->saveXML(); + $this->document = null; + return $this->container->resolveEnvPlaceholders($xml); + } + private function addParameters(\DOMElement $parent) + { + $data = $this->container->getParameterBag()->all(); + if (!$data) { + return; + } + if ($this->container->isCompiled()) { + $data = $this->escape($data); + } + $parameters = $this->document->createElement('parameters'); + $parent->appendChild($parameters); + $this->convertParameters($data, 'parameter', $parameters); + } + private function addMethodCalls(array $methodcalls, \DOMElement $parent) + { + foreach ($methodcalls as $methodcall) { + $call = $this->document->createElement('call'); + $call->setAttribute('method', $methodcall[0]); + if (\count($methodcall[1])) { + $this->convertParameters($methodcall[1], 'argument', $call); + } + $parent->appendChild($call); + } + } + /** + * Adds a service. + * + * @param Definition $definition + * @param string $id + */ + private function addService($definition, $id, \DOMElement $parent) + { + $service = $this->document->createElement('service'); + if (null !== $id) { + $service->setAttribute('id', $id); + } + if ($class = $definition->getClass()) { + if ('\\' === \substr($class, 0, 1)) { + $class = \substr($class, 1); + } + $service->setAttribute('class', $class); + } + if (!$definition->isShared()) { + $service->setAttribute('shared', 'false'); + } + if (!$definition->isPrivate()) { + $service->setAttribute('public', $definition->isPublic() ? 'true' : 'false'); + } + if ($definition->isSynthetic()) { + $service->setAttribute('synthetic', 'true'); + } + if ($definition->isLazy()) { + $service->setAttribute('lazy', 'true'); + } + if (null !== ($decorated = $definition->getDecoratedService())) { + list($decorated, $renamedId, $priority) = $decorated; + $service->setAttribute('decorates', $decorated); + if (null !== $renamedId) { + $service->setAttribute('decoration-inner-name', $renamedId); + } + if (0 !== $priority) { + $service->setAttribute('decoration-priority', $priority); + } + } + foreach ($definition->getTags() as $name => $tags) { + foreach ($tags as $attributes) { + $tag = $this->document->createElement('tag'); + $tag->setAttribute('name', $name); + foreach ($attributes as $key => $value) { + $tag->setAttribute($key, $value); + } + $service->appendChild($tag); + } + } + if ($definition->getFile()) { + $file = $this->document->createElement('file'); + $file->appendChild($this->document->createTextNode($definition->getFile())); + $service->appendChild($file); + } + if ($parameters = $definition->getArguments()) { + $this->convertParameters($parameters, 'argument', $service); + } + if ($parameters = $definition->getProperties()) { + $this->convertParameters($parameters, 'property', $service, 'name'); + } + $this->addMethodCalls($definition->getMethodCalls(), $service); + if ($callable = $definition->getFactory()) { + $factory = $this->document->createElement('factory'); + if (\is_array($callable) && $callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + $this->addService($callable[0], null, $factory); + $factory->setAttribute('method', $callable[1]); + } elseif (\is_array($callable)) { + if (null !== $callable[0]) { + $factory->setAttribute($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference ? 'service' : 'class', $callable[0]); + } + $factory->setAttribute('method', $callable[1]); + } else { + $factory->setAttribute('function', $callable); + } + $service->appendChild($factory); + } + if ($definition->isDeprecated()) { + $deprecated = $this->document->createElement('deprecated'); + $deprecated->appendChild($this->document->createTextNode($definition->getDeprecationMessage('%service_id%'))); + $service->appendChild($deprecated); + } + if ($definition->isAutowired()) { + $service->setAttribute('autowire', 'true'); + } + foreach ($definition->getAutowiringTypes(\false) as $autowiringTypeValue) { + $autowiringType = $this->document->createElement('autowiring-type'); + $autowiringType->appendChild($this->document->createTextNode($autowiringTypeValue)); + $service->appendChild($autowiringType); + } + if ($definition->isAutoconfigured()) { + $service->setAttribute('autoconfigure', 'true'); + } + if ($definition->isAbstract()) { + $service->setAttribute('abstract', 'true'); + } + if ($callable = $definition->getConfigurator()) { + $configurator = $this->document->createElement('configurator'); + if (\is_array($callable) && $callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + $this->addService($callable[0], null, $configurator); + $configurator->setAttribute('method', $callable[1]); + } elseif (\is_array($callable)) { + $configurator->setAttribute($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference ? 'service' : 'class', $callable[0]); + $configurator->setAttribute('method', $callable[1]); + } else { + $configurator->setAttribute('function', $callable); + } + $service->appendChild($configurator); + } + $parent->appendChild($service); + } + /** + * Adds a service alias. + * + * @param string $alias + */ + private function addServiceAlias($alias, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias $id, \DOMElement $parent) + { + $service = $this->document->createElement('service'); + $service->setAttribute('id', $alias); + $service->setAttribute('alias', $id); + if (!$id->isPrivate()) { + $service->setAttribute('public', $id->isPublic() ? 'true' : 'false'); + } + $parent->appendChild($service); + } + private function addServices(\DOMElement $parent) + { + $definitions = $this->container->getDefinitions(); + if (!$definitions) { + return; + } + $services = $this->document->createElement('services'); + foreach ($definitions as $id => $definition) { + $this->addService($definition, $id, $services); + } + $aliases = $this->container->getAliases(); + foreach ($aliases as $alias => $id) { + while (isset($aliases[(string) $id])) { + $id = $aliases[(string) $id]; + } + $this->addServiceAlias($alias, $id, $services); + } + $parent->appendChild($services); + } + /** + * Converts parameters. + * + * @param string $type + * @param string $keyAttribute + */ + private function convertParameters(array $parameters, $type, \DOMElement $parent, $keyAttribute = 'key') + { + $withKeys = \array_keys($parameters) !== \range(0, \count($parameters) - 1); + foreach ($parameters as $key => $value) { + $element = $this->document->createElement($type); + if ($withKeys) { + $element->setAttribute($keyAttribute, $key); + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { + $value = $value->getValues()[0]; + } + if (\is_array($value)) { + $element->setAttribute('type', 'collection'); + $this->convertParameters($value, $type, $element, 'key'); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument) { + $element->setAttribute('type', 'tagged'); + $element->setAttribute('tag', $value->getTag()); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument) { + $element->setAttribute('type', 'iterator'); + $this->convertParameters($value->getValues(), $type, $element, 'key'); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $element->setAttribute('type', 'service'); + $element->setAttribute('id', (string) $value); + $behavior = $value->getInvalidBehavior(); + if (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE == $behavior) { + $element->setAttribute('on-invalid', 'null'); + } elseif (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE == $behavior) { + $element->setAttribute('on-invalid', 'ignore'); + } elseif (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE == $behavior) { + $element->setAttribute('on-invalid', 'ignore_uninitialized'); + } + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + $element->setAttribute('type', 'service'); + $this->addService($value, null, $element); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { + $element->setAttribute('type', 'expression'); + $text = $this->document->createTextNode(self::phpToXml((string) $value)); + $element->appendChild($text); + } else { + if (\in_array($value, ['null', 'true', 'false'], \true)) { + $element->setAttribute('type', 'string'); + } + if (\is_string($value) && (\is_numeric($value) || \preg_match('/^0b[01]*$/', $value) || \preg_match('/^0x[0-9a-f]++$/i', $value))) { + $element->setAttribute('type', 'string'); + } + $text = $this->document->createTextNode(self::phpToXml($value)); + $element->appendChild($text); + } + $parent->appendChild($element); + } + } + /** + * Escapes arguments. + * + * @return array + */ + private function escape(array $arguments) + { + $args = []; + foreach ($arguments as $k => $v) { + if (\is_array($v)) { + $args[$k] = $this->escape($v); + } elseif (\is_string($v)) { + $args[$k] = \str_replace('%', '%%', $v); + } else { + $args[$k] = $v; + } + } + return $args; + } + /** + * Converts php types to xml types. + * + * @param mixed $value Value to convert + * + * @return string + * + * @throws RuntimeException When trying to dump object or resource + */ + public static function phpToXml($value) + { + switch (\true) { + case null === $value: + return 'null'; + case \true === $value: + return 'true'; + case \false === $value: + return 'false'; + case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter: + return '%' . $value . '%'; + case \is_object($value) || \is_resource($value): + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to dump a service container if a parameter is an object or a resource.'); + default: + return (string) $value; + } + } +} diff --git a/vendor/symfony/dependency-injection/Dumper/YamlDumper.php b/vendor/symfony/dependency-injection/Dumper/YamlDumper.php index c3e5f9393..ecbc9b682 100644 --- a/vendor/symfony/dependency-injection/Dumper/YamlDumper.php +++ b/vendor/symfony/dependency-injection/Dumper/YamlDumper.php @@ -1,328 +1,328 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper as YmlDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; -/** - * YamlDumper dumps a service container as a YAML string. - * - * @author Fabien Potencier - */ -class YamlDumper extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\Dumper -{ - private $dumper; - /** - * Dumps the service container as an YAML string. - * - * @return string A YAML string representing of the service container - */ - public function dump(array $options = []) - { - if (!\class_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Dumper')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to dump the container as the Symfony Yaml Component is not installed.'); - } - if (null === $this->dumper) { - $this->dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper(); - } - return $this->container->resolveEnvPlaceholders($this->addParameters() . "\n" . $this->addServices()); - } - /** - * Adds a service. - * - * @param string $id - * - * @return string - */ - private function addService($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - $code = " {$id}:\n"; - if ($class = $definition->getClass()) { - if ('\\' === \substr($class, 0, 1)) { - $class = \substr($class, 1); - } - $code .= \sprintf(" class: %s\n", $this->dumper->dump($class)); - } - if (!$definition->isPrivate()) { - $code .= \sprintf(" public: %s\n", $definition->isPublic() ? 'true' : 'false'); - } - $tagsCode = ''; - foreach ($definition->getTags() as $name => $tags) { - foreach ($tags as $attributes) { - $att = []; - foreach ($attributes as $key => $value) { - $att[] = \sprintf('%s: %s', $this->dumper->dump($key), $this->dumper->dump($value)); - } - $att = $att ? ', ' . \implode(', ', $att) : ''; - $tagsCode .= \sprintf(" - { name: %s%s }\n", $this->dumper->dump($name), $att); - } - } - if ($tagsCode) { - $code .= " tags:\n" . $tagsCode; - } - if ($definition->getFile()) { - $code .= \sprintf(" file: %s\n", $this->dumper->dump($definition->getFile())); - } - if ($definition->isSynthetic()) { - $code .= " synthetic: true\n"; - } - if ($definition->isDeprecated()) { - $code .= \sprintf(" deprecated: %s\n", $this->dumper->dump($definition->getDeprecationMessage('%service_id%'))); - } - if ($definition->isAutowired()) { - $code .= " autowire: true\n"; - } - $autowiringTypesCode = ''; - foreach ($definition->getAutowiringTypes(\false) as $autowiringType) { - $autowiringTypesCode .= \sprintf(" - %s\n", $this->dumper->dump($autowiringType)); - } - if ($autowiringTypesCode) { - $code .= \sprintf(" autowiring_types:\n%s", $autowiringTypesCode); - } - if ($definition->isAutoconfigured()) { - $code .= " autoconfigure: true\n"; - } - if ($definition->isAbstract()) { - $code .= " abstract: true\n"; - } - if ($definition->isLazy()) { - $code .= " lazy: true\n"; - } - if ($definition->getArguments()) { - $code .= \sprintf(" arguments: %s\n", $this->dumper->dump($this->dumpValue($definition->getArguments()), 0)); - } - if ($definition->getProperties()) { - $code .= \sprintf(" properties: %s\n", $this->dumper->dump($this->dumpValue($definition->getProperties()), 0)); - } - if ($definition->getMethodCalls()) { - $code .= \sprintf(" calls:\n%s\n", $this->dumper->dump($this->dumpValue($definition->getMethodCalls()), 1, 12)); - } - if (!$definition->isShared()) { - $code .= " shared: false\n"; - } - if (null !== ($decorated = $definition->getDecoratedService())) { - list($decorated, $renamedId, $priority) = $decorated; - $code .= \sprintf(" decorates: %s\n", $decorated); - if (null !== $renamedId) { - $code .= \sprintf(" decoration_inner_name: %s\n", $renamedId); - } - if (0 !== $priority) { - $code .= \sprintf(" decoration_priority: %s\n", $priority); - } - } - if ($callable = $definition->getFactory()) { - $code .= \sprintf(" factory: %s\n", $this->dumper->dump($this->dumpCallable($callable), 0)); - } - if ($callable = $definition->getConfigurator()) { - $code .= \sprintf(" configurator: %s\n", $this->dumper->dump($this->dumpCallable($callable), 0)); - } - return $code; - } - /** - * Adds a service alias. - * - * @param string $alias - * - * @return string - */ - private function addServiceAlias($alias, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias $id) - { - if ($id->isPrivate()) { - return \sprintf(" %s: '@%s'\n", $alias, $id); - } - return \sprintf(" %s:\n alias: %s\n public: %s\n", $alias, $id, $id->isPublic() ? 'true' : 'false'); - } - /** - * Adds services. - * - * @return string - */ - private function addServices() - { - if (!$this->container->getDefinitions()) { - return ''; - } - $code = "services:\n"; - foreach ($this->container->getDefinitions() as $id => $definition) { - $code .= $this->addService($id, $definition); - } - $aliases = $this->container->getAliases(); - foreach ($aliases as $alias => $id) { - while (isset($aliases[(string) $id])) { - $id = $aliases[(string) $id]; - } - $code .= $this->addServiceAlias($alias, $id); - } - return $code; - } - /** - * Adds parameters. - * - * @return string - */ - private function addParameters() - { - if (!$this->container->getParameterBag()->all()) { - return ''; - } - $parameters = $this->prepareParameters($this->container->getParameterBag()->all(), $this->container->isCompiled()); - return $this->dumper->dump(['parameters' => $parameters], 2); - } - /** - * Dumps callable to YAML format. - * - * @param mixed $callable - */ - private function dumpCallable($callable) - { - if (\is_array($callable)) { - if ($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - $callable = [$this->getServiceCall((string) $callable[0], $callable[0]), $callable[1]]; - } else { - $callable = [$callable[0], $callable[1]]; - } - } - return $callable; - } - /** - * Dumps the value to YAML format. - * - * @param mixed $value - * - * @return mixed - * - * @throws RuntimeException When trying to dump object or resource - */ - private function dumpValue($value) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { - $value = $value->getValues()[0]; - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('tagged', $value->getTag()); - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument) { - $tag = 'iterator'; - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Unspecified Yaml tag for type "%s".', \get_class($value))); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $this->dumpValue($value->getValues())); - } - if (\is_array($value)) { - $code = []; - foreach ($value as $k => $v) { - $code[$k] = $this->dumpValue($v); - } - return $code; - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - return $this->getServiceCall((string) $value, $value); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { - return $this->getParameterCall((string) $value); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { - return $this->getExpressionCall((string) $value); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('service', (new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser())->parse("_:\n" . $this->addService('_', $value), \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS)['_']['_']); - } elseif (\is_object($value) || \is_resource($value)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to dump a service container if a parameter is an object or a resource.'); - } - return $value; - } - /** - * Gets the service call. - * - * @param string $id - * @param Reference $reference - * - * @return string - */ - private function getServiceCall($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference $reference = null) - { - if (null !== $reference) { - switch ($reference->getInvalidBehavior()) { - case \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE: - break; - case \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE: - return \sprintf('@!%s', $id); - default: - return \sprintf('@?%s', $id); - } - } - return \sprintf('@%s', $id); - } - /** - * Gets parameter call. - * - * @param string $id - * - * @return string - */ - private function getParameterCall($id) - { - return \sprintf('%%%s%%', $id); - } - private function getExpressionCall($expression) - { - return \sprintf('@=%s', $expression); - } - /** - * Prepares parameters. - * - * @param bool $escape - * - * @return array - */ - private function prepareParameters(array $parameters, $escape = \true) - { - $filtered = []; - foreach ($parameters as $key => $value) { - if (\is_array($value)) { - $value = $this->prepareParameters($value, $escape); - } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || \is_string($value) && 0 === \strpos($value, '@')) { - $value = '@' . $value; - } - $filtered[$key] = $value; - } - return $escape ? $this->escape($filtered) : $filtered; - } - /** - * Escapes arguments. - * - * @return array - */ - private function escape(array $arguments) - { - $args = []; - foreach ($arguments as $k => $v) { - if (\is_array($v)) { - $args[$k] = $this->escape($v); - } elseif (\is_string($v)) { - $args[$k] = \str_replace('%', '%%', $v); - } else { - $args[$k] = $v; - } - } - return $args; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper as YmlDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; +/** + * YamlDumper dumps a service container as a YAML string. + * + * @author Fabien Potencier + */ +class YamlDumper extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\Dumper +{ + private $dumper; + /** + * Dumps the service container as an YAML string. + * + * @return string A YAML string representing of the service container + */ + public function dump(array $options = []) + { + if (!\class_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Dumper')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to dump the container as the Symfony Yaml Component is not installed.'); + } + if (null === $this->dumper) { + $this->dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper(); + } + return $this->container->resolveEnvPlaceholders($this->addParameters() . "\n" . $this->addServices()); + } + /** + * Adds a service. + * + * @param string $id + * + * @return string + */ + private function addService($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + $code = " {$id}:\n"; + if ($class = $definition->getClass()) { + if ('\\' === \substr($class, 0, 1)) { + $class = \substr($class, 1); + } + $code .= \sprintf(" class: %s\n", $this->dumper->dump($class)); + } + if (!$definition->isPrivate()) { + $code .= \sprintf(" public: %s\n", $definition->isPublic() ? 'true' : 'false'); + } + $tagsCode = ''; + foreach ($definition->getTags() as $name => $tags) { + foreach ($tags as $attributes) { + $att = []; + foreach ($attributes as $key => $value) { + $att[] = \sprintf('%s: %s', $this->dumper->dump($key), $this->dumper->dump($value)); + } + $att = $att ? ', ' . \implode(', ', $att) : ''; + $tagsCode .= \sprintf(" - { name: %s%s }\n", $this->dumper->dump($name), $att); + } + } + if ($tagsCode) { + $code .= " tags:\n" . $tagsCode; + } + if ($definition->getFile()) { + $code .= \sprintf(" file: %s\n", $this->dumper->dump($definition->getFile())); + } + if ($definition->isSynthetic()) { + $code .= " synthetic: true\n"; + } + if ($definition->isDeprecated()) { + $code .= \sprintf(" deprecated: %s\n", $this->dumper->dump($definition->getDeprecationMessage('%service_id%'))); + } + if ($definition->isAutowired()) { + $code .= " autowire: true\n"; + } + $autowiringTypesCode = ''; + foreach ($definition->getAutowiringTypes(\false) as $autowiringType) { + $autowiringTypesCode .= \sprintf(" - %s\n", $this->dumper->dump($autowiringType)); + } + if ($autowiringTypesCode) { + $code .= \sprintf(" autowiring_types:\n%s", $autowiringTypesCode); + } + if ($definition->isAutoconfigured()) { + $code .= " autoconfigure: true\n"; + } + if ($definition->isAbstract()) { + $code .= " abstract: true\n"; + } + if ($definition->isLazy()) { + $code .= " lazy: true\n"; + } + if ($definition->getArguments()) { + $code .= \sprintf(" arguments: %s\n", $this->dumper->dump($this->dumpValue($definition->getArguments()), 0)); + } + if ($definition->getProperties()) { + $code .= \sprintf(" properties: %s\n", $this->dumper->dump($this->dumpValue($definition->getProperties()), 0)); + } + if ($definition->getMethodCalls()) { + $code .= \sprintf(" calls:\n%s\n", $this->dumper->dump($this->dumpValue($definition->getMethodCalls()), 1, 12)); + } + if (!$definition->isShared()) { + $code .= " shared: false\n"; + } + if (null !== ($decorated = $definition->getDecoratedService())) { + list($decorated, $renamedId, $priority) = $decorated; + $code .= \sprintf(" decorates: %s\n", $decorated); + if (null !== $renamedId) { + $code .= \sprintf(" decoration_inner_name: %s\n", $renamedId); + } + if (0 !== $priority) { + $code .= \sprintf(" decoration_priority: %s\n", $priority); + } + } + if ($callable = $definition->getFactory()) { + $code .= \sprintf(" factory: %s\n", $this->dumper->dump($this->dumpCallable($callable), 0)); + } + if ($callable = $definition->getConfigurator()) { + $code .= \sprintf(" configurator: %s\n", $this->dumper->dump($this->dumpCallable($callable), 0)); + } + return $code; + } + /** + * Adds a service alias. + * + * @param string $alias + * + * @return string + */ + private function addServiceAlias($alias, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias $id) + { + if ($id->isPrivate()) { + return \sprintf(" %s: '@%s'\n", $alias, $id); + } + return \sprintf(" %s:\n alias: %s\n public: %s\n", $alias, $id, $id->isPublic() ? 'true' : 'false'); + } + /** + * Adds services. + * + * @return string + */ + private function addServices() + { + if (!$this->container->getDefinitions()) { + return ''; + } + $code = "services:\n"; + foreach ($this->container->getDefinitions() as $id => $definition) { + $code .= $this->addService($id, $definition); + } + $aliases = $this->container->getAliases(); + foreach ($aliases as $alias => $id) { + while (isset($aliases[(string) $id])) { + $id = $aliases[(string) $id]; + } + $code .= $this->addServiceAlias($alias, $id); + } + return $code; + } + /** + * Adds parameters. + * + * @return string + */ + private function addParameters() + { + if (!$this->container->getParameterBag()->all()) { + return ''; + } + $parameters = $this->prepareParameters($this->container->getParameterBag()->all(), $this->container->isCompiled()); + return $this->dumper->dump(['parameters' => $parameters], 2); + } + /** + * Dumps callable to YAML format. + * + * @param mixed $callable + */ + private function dumpCallable($callable) + { + if (\is_array($callable)) { + if ($callable[0] instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + $callable = [$this->getServiceCall((string) $callable[0], $callable[0]), $callable[1]]; + } else { + $callable = [$callable[0], $callable[1]]; + } + } + return $callable; + } + /** + * Dumps the value to YAML format. + * + * @param mixed $value + * + * @return mixed + * + * @throws RuntimeException When trying to dump object or resource + */ + private function dumpValue($value) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument) { + $value = $value->getValues()[0]; + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface) { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('tagged', $value->getTag()); + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument) { + $tag = 'iterator'; + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Unspecified Yaml tag for type "%s".', \get_class($value))); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $this->dumpValue($value->getValues())); + } + if (\is_array($value)) { + $code = []; + foreach ($value as $k => $v) { + $code[$k] = $this->dumpValue($v); + } + return $code; + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + return $this->getServiceCall((string) $value, $value); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter) { + return $this->getParameterCall((string) $value); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression) { + return $this->getExpressionCall((string) $value); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('service', (new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser())->parse("_:\n" . $this->addService('_', $value), \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS)['_']['_']); + } elseif (\is_object($value) || \is_resource($value)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to dump a service container if a parameter is an object or a resource.'); + } + return $value; + } + /** + * Gets the service call. + * + * @param string $id + * @param Reference $reference + * + * @return string + */ + private function getServiceCall($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference $reference = null) + { + if (null !== $reference) { + switch ($reference->getInvalidBehavior()) { + case \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE: + break; + case \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE: + return \sprintf('@!%s', $id); + default: + return \sprintf('@?%s', $id); + } + } + return \sprintf('@%s', $id); + } + /** + * Gets parameter call. + * + * @param string $id + * + * @return string + */ + private function getParameterCall($id) + { + return \sprintf('%%%s%%', $id); + } + private function getExpressionCall($expression) + { + return \sprintf('@=%s', $expression); + } + /** + * Prepares parameters. + * + * @param bool $escape + * + * @return array + */ + private function prepareParameters(array $parameters, $escape = \true) + { + $filtered = []; + foreach ($parameters as $key => $value) { + if (\is_array($value)) { + $value = $this->prepareParameters($value, $escape); + } elseif ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference || \is_string($value) && 0 === \strpos($value, '@')) { + $value = '@' . $value; + } + $filtered[$key] = $value; + } + return $escape ? $this->escape($filtered) : $filtered; + } + /** + * Escapes arguments. + * + * @return array + */ + private function escape(array $arguments) + { + $args = []; + foreach ($arguments as $k => $v) { + if (\is_array($v)) { + $args[$k] = $this->escape($v); + } elseif (\is_string($v)) { + $args[$k] = \str_replace('%', '%%', $v); + } else { + $args[$k] = $v; + } + } + return $args; + } +} diff --git a/vendor/symfony/dependency-injection/Dumper/index.php b/vendor/symfony/dependency-injection/Dumper/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Dumper/index.php +++ b/vendor/symfony/dependency-injection/Dumper/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/EnvVarProcessor.php b/vendor/symfony/dependency-injection/EnvVarProcessor.php index d6ea2e186..3dd1e8b6d 100644 --- a/vendor/symfony/dependency-injection/EnvVarProcessor.php +++ b/vendor/symfony/dependency-injection/EnvVarProcessor.php @@ -1,126 +1,126 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -/** - * @author Nicolas Grekas - */ -class EnvVarProcessor implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface -{ - private $container; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container) - { - $this->container = $container; - } - /** - * {@inheritdoc} - */ - public static function getProvidedTypes() - { - return ['base64' => 'string', 'bool' => 'bool', 'const' => 'bool|int|float|string|array', 'file' => 'string', 'float' => 'float', 'int' => 'int', 'json' => 'array', 'resolve' => 'string', 'string' => 'string']; - } - /** - * {@inheritdoc} - */ - public function getEnv($prefix, $name, \Closure $getEnv) - { - $i = \strpos($name, ':'); - if ('file' === $prefix) { - if (!\is_scalar($file = $getEnv($name))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid file name: env var "%s" is non-scalar.', $name)); - } - if (!\file_exists($file)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Env "file:%s" not found: "%s" does not exist.', $name, $file)); - } - return \file_get_contents($file); - } - if (\false !== $i || 'string' !== $prefix) { - if (null === ($env = $getEnv($name))) { - return null; - } - } elseif (isset($_ENV[$name])) { - $env = $_ENV[$name]; - } elseif (isset($_SERVER[$name]) && 0 !== \strpos($name, 'HTTP_')) { - $env = $_SERVER[$name]; - } elseif (\false === ($env = \getenv($name)) || null === $env) { - // null is a possible value because of thread safety issues - if (!$this->container->hasParameter("env({$name})")) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvNotFoundException($name); - } - if (null === ($env = $this->container->getParameter("env({$name})"))) { - return null; - } - } - if (!\is_scalar($env)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Non-scalar env var "%s" cannot be cast to "%s".', $name, $prefix)); - } - if ('string' === $prefix) { - return (string) $env; - } - if ('bool' === $prefix) { - return (bool) self::phpize($env); - } - if ('int' === $prefix) { - if (!\is_numeric($env = self::phpize($env))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Non-numeric env var "%s" cannot be cast to int.', $name)); - } - return (int) $env; - } - if ('float' === $prefix) { - if (!\is_numeric($env = self::phpize($env))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Non-numeric env var "%s" cannot be cast to float.', $name)); - } - return (float) $env; - } - if ('const' === $prefix) { - if (!\defined($env)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Env var "%s" maps to undefined constant "%s".', $name, $env)); - } - return \constant($env); - } - if ('base64' === $prefix) { - return \base64_decode($env); - } - if ('json' === $prefix) { - $env = \json_decode($env, \true); - if (\JSON_ERROR_NONE !== \json_last_error()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid JSON in env var "%s": ' . \json_last_error_msg(), $name)); - } - if (!\is_array($env)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid JSON env var "%s": array expected, "%s" given.', $name, \gettype($env))); - } - return $env; - } - if ('resolve' === $prefix) { - return \preg_replace_callback('/%%|%([^%\\s]+)%/', function ($match) use($name) { - if (!isset($match[1])) { - return '%'; - } - $value = $this->container->getParameter($match[1]); - if (!\is_scalar($value)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Parameter "%s" found when resolving env var "%s" must be scalar, "%s" given.', $match[1], $name, \gettype($value))); - } - return $value; - }, $env); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Unsupported env var prefix "%s".', $prefix)); - } - private static function phpize($value) - { - if (!\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::class)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('The Symfony Config component is required to cast env vars to "bool", "int" or "float".'); - } - return \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +/** + * @author Nicolas Grekas + */ +class EnvVarProcessor implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface +{ + private $container; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container) + { + $this->container = $container; + } + /** + * {@inheritdoc} + */ + public static function getProvidedTypes() + { + return ['base64' => 'string', 'bool' => 'bool', 'const' => 'bool|int|float|string|array', 'file' => 'string', 'float' => 'float', 'int' => 'int', 'json' => 'array', 'resolve' => 'string', 'string' => 'string']; + } + /** + * {@inheritdoc} + */ + public function getEnv($prefix, $name, \Closure $getEnv) + { + $i = \strpos($name, ':'); + if ('file' === $prefix) { + if (!\is_scalar($file = $getEnv($name))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid file name: env var "%s" is non-scalar.', $name)); + } + if (!\file_exists($file)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Env "file:%s" not found: "%s" does not exist.', $name, $file)); + } + return \file_get_contents($file); + } + if (\false !== $i || 'string' !== $prefix) { + if (null === ($env = $getEnv($name))) { + return null; + } + } elseif (isset($_ENV[$name])) { + $env = $_ENV[$name]; + } elseif (isset($_SERVER[$name]) && 0 !== \strpos($name, 'HTTP_')) { + $env = $_SERVER[$name]; + } elseif (\false === ($env = \getenv($name)) || null === $env) { + // null is a possible value because of thread safety issues + if (!$this->container->hasParameter("env({$name})")) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\EnvNotFoundException($name); + } + if (null === ($env = $this->container->getParameter("env({$name})"))) { + return null; + } + } + if (!\is_scalar($env)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Non-scalar env var "%s" cannot be cast to "%s".', $name, $prefix)); + } + if ('string' === $prefix) { + return (string) $env; + } + if ('bool' === $prefix) { + return (bool) self::phpize($env); + } + if ('int' === $prefix) { + if (!\is_numeric($env = self::phpize($env))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Non-numeric env var "%s" cannot be cast to int.', $name)); + } + return (int) $env; + } + if ('float' === $prefix) { + if (!\is_numeric($env = self::phpize($env))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Non-numeric env var "%s" cannot be cast to float.', $name)); + } + return (float) $env; + } + if ('const' === $prefix) { + if (!\defined($env)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Env var "%s" maps to undefined constant "%s".', $name, $env)); + } + return \constant($env); + } + if ('base64' === $prefix) { + return \base64_decode($env); + } + if ('json' === $prefix) { + $env = \json_decode($env, \true); + if (\JSON_ERROR_NONE !== \json_last_error()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid JSON in env var "%s": ' . \json_last_error_msg(), $name)); + } + if (!\is_array($env)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Invalid JSON env var "%s": array expected, "%s" given.', $name, \gettype($env))); + } + return $env; + } + if ('resolve' === $prefix) { + return \preg_replace_callback('/%%|%([^%\\s]+)%/', function ($match) use($name) { + if (!isset($match[1])) { + return '%'; + } + $value = $this->container->getParameter($match[1]); + if (!\is_scalar($value)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Parameter "%s" found when resolving env var "%s" must be scalar, "%s" given.', $match[1], $name, \gettype($value))); + } + return $value; + }, $env); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Unsupported env var prefix "%s".', $prefix)); + } + private static function phpize($value) + { + if (!\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::class)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('The Symfony Config component is required to cast env vars to "bool", "int" or "float".'); + } + return \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value); + } +} diff --git a/vendor/symfony/dependency-injection/EnvVarProcessorInterface.php b/vendor/symfony/dependency-injection/EnvVarProcessorInterface.php index 4504638af..ad147c840 100644 --- a/vendor/symfony/dependency-injection/EnvVarProcessorInterface.php +++ b/vendor/symfony/dependency-injection/EnvVarProcessorInterface.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -/** - * The EnvVarProcessorInterface is implemented by objects that manage environment-like variables. - * - * @author Nicolas Grekas - */ -interface EnvVarProcessorInterface -{ - /** - * Returns the value of the given variable as managed by the current instance. - * - * @param string $prefix The namespace of the variable - * @param string $name The name of the variable within the namespace - * @param \Closure $getEnv A closure that allows fetching more env vars - * - * @return mixed - * - * @throws RuntimeException on error - */ - public function getEnv($prefix, $name, \Closure $getEnv); - /** - * @return string[] The PHP-types managed by getEnv(), keyed by prefixes - */ - public static function getProvidedTypes(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +/** + * The EnvVarProcessorInterface is implemented by objects that manage environment-like variables. + * + * @author Nicolas Grekas + */ +interface EnvVarProcessorInterface +{ + /** + * Returns the value of the given variable as managed by the current instance. + * + * @param string $prefix The namespace of the variable + * @param string $name The name of the variable within the namespace + * @param \Closure $getEnv A closure that allows fetching more env vars + * + * @return mixed + * + * @throws RuntimeException on error + */ + public function getEnv($prefix, $name, \Closure $getEnv); + /** + * @return string[] The PHP-types managed by getEnv(), keyed by prefixes + */ + public static function getProvidedTypes(); +} diff --git a/vendor/symfony/dependency-injection/Exception/AutowiringFailedException.php b/vendor/symfony/dependency-injection/Exception/AutowiringFailedException.php index c8004102a..f9f5e70e9 100644 --- a/vendor/symfony/dependency-injection/Exception/AutowiringFailedException.php +++ b/vendor/symfony/dependency-injection/Exception/AutowiringFailedException.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * Thrown when a definition cannot be autowired. - */ -class AutowiringFailedException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException -{ - private $serviceId; - public function __construct($serviceId, $message = '', $code = 0, \Exception $previous = null) - { - $this->serviceId = $serviceId; - parent::__construct($message, $code, $previous); - } - public function getServiceId() - { - return $this->serviceId; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * Thrown when a definition cannot be autowired. + */ +class AutowiringFailedException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException +{ + private $serviceId; + public function __construct($serviceId, $message = '', $code = 0, \Exception $previous = null) + { + $this->serviceId = $serviceId; + parent::__construct($message, $code, $previous); + } + public function getServiceId() + { + return $this->serviceId; + } +} diff --git a/vendor/symfony/dependency-injection/Exception/BadMethodCallException.php b/vendor/symfony/dependency-injection/Exception/BadMethodCallException.php index eac16e3b5..9d4214b51 100644 --- a/vendor/symfony/dependency-injection/Exception/BadMethodCallException.php +++ b/vendor/symfony/dependency-injection/Exception/BadMethodCallException.php @@ -1,18 +1,18 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * Base BadMethodCallException for Dependency Injection component. - */ -class BadMethodCallException extends \BadMethodCallException implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * Base BadMethodCallException for Dependency Injection component. + */ +class BadMethodCallException extends \BadMethodCallException implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface +{ +} diff --git a/vendor/symfony/dependency-injection/Exception/EnvNotFoundException.php b/vendor/symfony/dependency-injection/Exception/EnvNotFoundException.php index f71795ee6..e15565788 100644 --- a/vendor/symfony/dependency-injection/Exception/EnvNotFoundException.php +++ b/vendor/symfony/dependency-injection/Exception/EnvNotFoundException.php @@ -1,24 +1,24 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * This exception is thrown when an environment variable is not found. - * - * @author Nicolas Grekas - */ -class EnvNotFoundException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException -{ - public function __construct($name) - { - parent::__construct(\sprintf('Environment variable not found: "%s".', $name)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * This exception is thrown when an environment variable is not found. + * + * @author Nicolas Grekas + */ +class EnvNotFoundException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException +{ + public function __construct($name) + { + parent::__construct(\sprintf('Environment variable not found: "%s".', $name)); + } +} diff --git a/vendor/symfony/dependency-injection/Exception/EnvParameterException.php b/vendor/symfony/dependency-injection/Exception/EnvParameterException.php index 66630c304..1fda47305 100644 --- a/vendor/symfony/dependency-injection/Exception/EnvParameterException.php +++ b/vendor/symfony/dependency-injection/Exception/EnvParameterException.php @@ -1,24 +1,24 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * This exception wraps exceptions whose messages contain a reference to an env parameter. - * - * @author Nicolas Grekas - */ -class EnvParameterException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException -{ - public function __construct(array $envs, \Exception $previous = null, $message = 'Incompatible use of dynamic environment variables "%s" found in parameters.') - { - parent::__construct(\sprintf($message, \implode('", "', $envs)), 0, $previous); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * This exception wraps exceptions whose messages contain a reference to an env parameter. + * + * @author Nicolas Grekas + */ +class EnvParameterException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException +{ + public function __construct(array $envs, \Exception $previous = null, $message = 'Incompatible use of dynamic environment variables "%s" found in parameters.') + { + parent::__construct(\sprintf($message, \implode('", "', $envs)), 0, $previous); + } +} diff --git a/vendor/symfony/dependency-injection/Exception/ExceptionInterface.php b/vendor/symfony/dependency-injection/Exception/ExceptionInterface.php index f6c31e185..d304231de 100644 --- a/vendor/symfony/dependency-injection/Exception/ExceptionInterface.php +++ b/vendor/symfony/dependency-injection/Exception/ExceptionInterface.php @@ -1,22 +1,22 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -use _PhpScoper5ea00cc67502b\Psr\Container\ContainerExceptionInterface; -/** - * Base ExceptionInterface for Dependency Injection component. - * - * @author Fabien Potencier - * @author Bulat Shakirzyanov - */ -interface ExceptionInterface extends \_PhpScoper5ea00cc67502b\Psr\Container\ContainerExceptionInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +use _PhpScoper5ea00cc67502b\Psr\Container\ContainerExceptionInterface; +/** + * Base ExceptionInterface for Dependency Injection component. + * + * @author Fabien Potencier + * @author Bulat Shakirzyanov + */ +interface ExceptionInterface extends \_PhpScoper5ea00cc67502b\Psr\Container\ContainerExceptionInterface +{ +} diff --git a/vendor/symfony/dependency-injection/Exception/InvalidArgumentException.php b/vendor/symfony/dependency-injection/Exception/InvalidArgumentException.php index 52cc05305..d7583d1b3 100644 --- a/vendor/symfony/dependency-injection/Exception/InvalidArgumentException.php +++ b/vendor/symfony/dependency-injection/Exception/InvalidArgumentException.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * Base InvalidArgumentException for Dependency Injection component. - * - * @author Bulat Shakirzyanov - */ -class InvalidArgumentException extends \InvalidArgumentException implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * Base InvalidArgumentException for Dependency Injection component. + * + * @author Bulat Shakirzyanov + */ +class InvalidArgumentException extends \InvalidArgumentException implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface +{ +} diff --git a/vendor/symfony/dependency-injection/Exception/LogicException.php b/vendor/symfony/dependency-injection/Exception/LogicException.php index 7ab622485..45af5df51 100644 --- a/vendor/symfony/dependency-injection/Exception/LogicException.php +++ b/vendor/symfony/dependency-injection/Exception/LogicException.php @@ -1,18 +1,18 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * Base LogicException for Dependency Injection component. - */ -class LogicException extends \LogicException implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * Base LogicException for Dependency Injection component. + */ +class LogicException extends \LogicException implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface +{ +} diff --git a/vendor/symfony/dependency-injection/Exception/OutOfBoundsException.php b/vendor/symfony/dependency-injection/Exception/OutOfBoundsException.php index 77aa6199b..76ddd5e5a 100644 --- a/vendor/symfony/dependency-injection/Exception/OutOfBoundsException.php +++ b/vendor/symfony/dependency-injection/Exception/OutOfBoundsException.php @@ -1,18 +1,18 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * Base OutOfBoundsException for Dependency Injection component. - */ -class OutOfBoundsException extends \OutOfBoundsException implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * Base OutOfBoundsException for Dependency Injection component. + */ +class OutOfBoundsException extends \OutOfBoundsException implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface +{ +} diff --git a/vendor/symfony/dependency-injection/Exception/ParameterCircularReferenceException.php b/vendor/symfony/dependency-injection/Exception/ParameterCircularReferenceException.php index dfd3eca9f..ef7f1a020 100644 --- a/vendor/symfony/dependency-injection/Exception/ParameterCircularReferenceException.php +++ b/vendor/symfony/dependency-injection/Exception/ParameterCircularReferenceException.php @@ -1,30 +1,30 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * This exception is thrown when a circular reference in a parameter is detected. - * - * @author Fabien Potencier - */ -class ParameterCircularReferenceException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException -{ - private $parameters; - public function __construct($parameters, \Exception $previous = null) - { - parent::__construct(\sprintf('Circular reference detected for parameter "%s" ("%s" > "%s").', $parameters[0], \implode('" > "', $parameters), $parameters[0]), 0, $previous); - $this->parameters = $parameters; - } - public function getParameters() - { - return $this->parameters; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * This exception is thrown when a circular reference in a parameter is detected. + * + * @author Fabien Potencier + */ +class ParameterCircularReferenceException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException +{ + private $parameters; + public function __construct($parameters, \Exception $previous = null) + { + parent::__construct(\sprintf('Circular reference detected for parameter "%s" ("%s" > "%s").', $parameters[0], \implode('" > "', $parameters), $parameters[0]), 0, $previous); + $this->parameters = $parameters; + } + public function getParameters() + { + return $this->parameters; + } +} diff --git a/vendor/symfony/dependency-injection/Exception/ParameterNotFoundException.php b/vendor/symfony/dependency-injection/Exception/ParameterNotFoundException.php index 7c209df11..46f74f4bc 100644 --- a/vendor/symfony/dependency-injection/Exception/ParameterNotFoundException.php +++ b/vendor/symfony/dependency-injection/Exception/ParameterNotFoundException.php @@ -1,85 +1,85 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * This exception is thrown when a non-existent parameter is used. - * - * @author Fabien Potencier - */ -class ParameterNotFoundException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException -{ - private $key; - private $sourceId; - private $sourceKey; - private $alternatives; - private $nonNestedAlternative; - /** - * @param string $key The requested parameter key - * @param string $sourceId The service id that references the non-existent parameter - * @param string $sourceKey The parameter key that references the non-existent parameter - * @param \Exception $previous The previous exception - * @param string[] $alternatives Some parameter name alternatives - * @param string|null $nonNestedAlternative The alternative parameter name when the user expected dot notation for nested parameters - */ - public function __construct($key, $sourceId = null, $sourceKey = null, \Exception $previous = null, array $alternatives = [], $nonNestedAlternative = null) - { - $this->key = $key; - $this->sourceId = $sourceId; - $this->sourceKey = $sourceKey; - $this->alternatives = $alternatives; - $this->nonNestedAlternative = $nonNestedAlternative; - parent::__construct('', 0, $previous); - $this->updateRepr(); - } - public function updateRepr() - { - if (null !== $this->sourceId) { - $this->message = \sprintf('The service "%s" has a dependency on a non-existent parameter "%s".', $this->sourceId, $this->key); - } elseif (null !== $this->sourceKey) { - $this->message = \sprintf('The parameter "%s" has a dependency on a non-existent parameter "%s".', $this->sourceKey, $this->key); - } else { - $this->message = \sprintf('You have requested a non-existent parameter "%s".', $this->key); - } - if ($this->alternatives) { - if (1 == \count($this->alternatives)) { - $this->message .= ' Did you mean this: "'; - } else { - $this->message .= ' Did you mean one of these: "'; - } - $this->message .= \implode('", "', $this->alternatives) . '"?'; - } elseif (null !== $this->nonNestedAlternative) { - $this->message .= ' You cannot access nested array items, do you want to inject "' . $this->nonNestedAlternative . '" instead?'; - } - } - public function getKey() - { - return $this->key; - } - public function getSourceId() - { - return $this->sourceId; - } - public function getSourceKey() - { - return $this->sourceKey; - } - public function setSourceId($sourceId) - { - $this->sourceId = $sourceId; - $this->updateRepr(); - } - public function setSourceKey($sourceKey) - { - $this->sourceKey = $sourceKey; - $this->updateRepr(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * This exception is thrown when a non-existent parameter is used. + * + * @author Fabien Potencier + */ +class ParameterNotFoundException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException +{ + private $key; + private $sourceId; + private $sourceKey; + private $alternatives; + private $nonNestedAlternative; + /** + * @param string $key The requested parameter key + * @param string $sourceId The service id that references the non-existent parameter + * @param string $sourceKey The parameter key that references the non-existent parameter + * @param \Exception $previous The previous exception + * @param string[] $alternatives Some parameter name alternatives + * @param string|null $nonNestedAlternative The alternative parameter name when the user expected dot notation for nested parameters + */ + public function __construct($key, $sourceId = null, $sourceKey = null, \Exception $previous = null, array $alternatives = [], $nonNestedAlternative = null) + { + $this->key = $key; + $this->sourceId = $sourceId; + $this->sourceKey = $sourceKey; + $this->alternatives = $alternatives; + $this->nonNestedAlternative = $nonNestedAlternative; + parent::__construct('', 0, $previous); + $this->updateRepr(); + } + public function updateRepr() + { + if (null !== $this->sourceId) { + $this->message = \sprintf('The service "%s" has a dependency on a non-existent parameter "%s".', $this->sourceId, $this->key); + } elseif (null !== $this->sourceKey) { + $this->message = \sprintf('The parameter "%s" has a dependency on a non-existent parameter "%s".', $this->sourceKey, $this->key); + } else { + $this->message = \sprintf('You have requested a non-existent parameter "%s".', $this->key); + } + if ($this->alternatives) { + if (1 == \count($this->alternatives)) { + $this->message .= ' Did you mean this: "'; + } else { + $this->message .= ' Did you mean one of these: "'; + } + $this->message .= \implode('", "', $this->alternatives) . '"?'; + } elseif (null !== $this->nonNestedAlternative) { + $this->message .= ' You cannot access nested array items, do you want to inject "' . $this->nonNestedAlternative . '" instead?'; + } + } + public function getKey() + { + return $this->key; + } + public function getSourceId() + { + return $this->sourceId; + } + public function getSourceKey() + { + return $this->sourceKey; + } + public function setSourceId($sourceId) + { + $this->sourceId = $sourceId; + $this->updateRepr(); + } + public function setSourceKey($sourceKey) + { + $this->sourceKey = $sourceKey; + $this->updateRepr(); + } +} diff --git a/vendor/symfony/dependency-injection/Exception/RuntimeException.php b/vendor/symfony/dependency-injection/Exception/RuntimeException.php index d50d51485..b8ee1ed19 100644 --- a/vendor/symfony/dependency-injection/Exception/RuntimeException.php +++ b/vendor/symfony/dependency-injection/Exception/RuntimeException.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * Base RuntimeException for Dependency Injection component. - * - * @author Johannes M. Schmitt - */ -class RuntimeException extends \RuntimeException implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * Base RuntimeException for Dependency Injection component. + * + * @author Johannes M. Schmitt + */ +class RuntimeException extends \RuntimeException implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ExceptionInterface +{ +} diff --git a/vendor/symfony/dependency-injection/Exception/ServiceCircularReferenceException.php b/vendor/symfony/dependency-injection/Exception/ServiceCircularReferenceException.php index a9043bd01..10cb914b5 100644 --- a/vendor/symfony/dependency-injection/Exception/ServiceCircularReferenceException.php +++ b/vendor/symfony/dependency-injection/Exception/ServiceCircularReferenceException.php @@ -1,36 +1,36 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -/** - * This exception is thrown when a circular reference is detected. - * - * @author Johannes M. Schmitt - */ -class ServiceCircularReferenceException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException -{ - private $serviceId; - private $path; - public function __construct($serviceId, array $path, \Exception $previous = null) - { - parent::__construct(\sprintf('Circular reference detected for service "%s", path: "%s".', $serviceId, \implode(' -> ', $path)), 0, $previous); - $this->serviceId = $serviceId; - $this->path = $path; - } - public function getServiceId() - { - return $this->serviceId; - } - public function getPath() - { - return $this->path; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +/** + * This exception is thrown when a circular reference is detected. + * + * @author Johannes M. Schmitt + */ +class ServiceCircularReferenceException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException +{ + private $serviceId; + private $path; + public function __construct($serviceId, array $path, \Exception $previous = null) + { + parent::__construct(\sprintf('Circular reference detected for service "%s", path: "%s".', $serviceId, \implode(' -> ', $path)), 0, $previous); + $this->serviceId = $serviceId; + $this->path = $path; + } + public function getServiceId() + { + return $this->serviceId; + } + public function getPath() + { + return $this->path; + } +} diff --git a/vendor/symfony/dependency-injection/Exception/ServiceNotFoundException.php b/vendor/symfony/dependency-injection/Exception/ServiceNotFoundException.php index 166c4921b..120286be6 100644 --- a/vendor/symfony/dependency-injection/Exception/ServiceNotFoundException.php +++ b/vendor/symfony/dependency-injection/Exception/ServiceNotFoundException.php @@ -1,58 +1,58 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; - -use _PhpScoper5ea00cc67502b\Psr\Container\NotFoundExceptionInterface; -/** - * This exception is thrown when a non-existent service is requested. - * - * @author Johannes M. Schmitt - */ -class ServiceNotFoundException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException implements \_PhpScoper5ea00cc67502b\Psr\Container\NotFoundExceptionInterface -{ - private $id; - private $sourceId; - private $alternatives; - public function __construct($id, $sourceId = null, \Exception $previous = null, array $alternatives = [], $msg = null) - { - if (null !== $msg) { - // no-op - } elseif (null === $sourceId) { - $msg = \sprintf('You have requested a non-existent service "%s".', $id); - } else { - $msg = \sprintf('The service "%s" has a dependency on a non-existent service "%s".', $sourceId, $id); - } - if ($alternatives) { - if (1 == \count($alternatives)) { - $msg .= ' Did you mean this: "'; - } else { - $msg .= ' Did you mean one of these: "'; - } - $msg .= \implode('", "', $alternatives) . '"?'; - } - parent::__construct($msg, 0, $previous); - $this->id = $id; - $this->sourceId = $sourceId; - $this->alternatives = $alternatives; - } - public function getId() - { - return $this->id; - } - public function getSourceId() - { - return $this->sourceId; - } - public function getAlternatives() - { - return $this->alternatives; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception; + +use _PhpScoper5ea00cc67502b\Psr\Container\NotFoundExceptionInterface; +/** + * This exception is thrown when a non-existent service is requested. + * + * @author Johannes M. Schmitt + */ +class ServiceNotFoundException extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException implements \_PhpScoper5ea00cc67502b\Psr\Container\NotFoundExceptionInterface +{ + private $id; + private $sourceId; + private $alternatives; + public function __construct($id, $sourceId = null, \Exception $previous = null, array $alternatives = [], $msg = null) + { + if (null !== $msg) { + // no-op + } elseif (null === $sourceId) { + $msg = \sprintf('You have requested a non-existent service "%s".', $id); + } else { + $msg = \sprintf('The service "%s" has a dependency on a non-existent service "%s".', $sourceId, $id); + } + if ($alternatives) { + if (1 == \count($alternatives)) { + $msg .= ' Did you mean this: "'; + } else { + $msg .= ' Did you mean one of these: "'; + } + $msg .= \implode('", "', $alternatives) . '"?'; + } + parent::__construct($msg, 0, $previous); + $this->id = $id; + $this->sourceId = $sourceId; + $this->alternatives = $alternatives; + } + public function getId() + { + return $this->id; + } + public function getSourceId() + { + return $this->sourceId; + } + public function getAlternatives() + { + return $this->alternatives; + } +} diff --git a/vendor/symfony/dependency-injection/Exception/index.php b/vendor/symfony/dependency-injection/Exception/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Exception/index.php +++ b/vendor/symfony/dependency-injection/Exception/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/ExpressionLanguage.php b/vendor/symfony/dependency-injection/ExpressionLanguage.php index fe9239ca6..a23de7414 100644 --- a/vendor/symfony/dependency-injection/ExpressionLanguage.php +++ b/vendor/symfony/dependency-injection/ExpressionLanguage.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage as BaseExpressionLanguage; -/** - * Adds some function to the default ExpressionLanguage. - * - * @author Fabien Potencier - * - * @see ExpressionLanguageProvider - */ -class ExpressionLanguage extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage -{ - /** - * {@inheritdoc} - */ - public function __construct($cache = null, array $providers = [], callable $serviceCompiler = null) - { - // prepend the default provider to let users override it easily - \array_unshift($providers, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguageProvider($serviceCompiler)); - parent::__construct($cache, $providers); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage as BaseExpressionLanguage; +/** + * Adds some function to the default ExpressionLanguage. + * + * @author Fabien Potencier + * + * @see ExpressionLanguageProvider + */ +class ExpressionLanguage extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage +{ + /** + * {@inheritdoc} + */ + public function __construct($cache = null, array $providers = [], callable $serviceCompiler = null) + { + // prepend the default provider to let users override it easily + \array_unshift($providers, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ExpressionLanguageProvider($serviceCompiler)); + parent::__construct($cache, $providers); + } +} diff --git a/vendor/symfony/dependency-injection/ExpressionLanguageProvider.php b/vendor/symfony/dependency-injection/ExpressionLanguageProvider.php index 2b486c92d..26d2bdeca 100644 --- a/vendor/symfony/dependency-injection/ExpressionLanguageProvider.php +++ b/vendor/symfony/dependency-injection/ExpressionLanguageProvider.php @@ -1,42 +1,42 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface; -/** - * Define some ExpressionLanguage functions. - * - * To get a service, use service('request'). - * To get a parameter, use parameter('kernel.debug'). - * - * @author Fabien Potencier - */ -class ExpressionLanguageProvider implements \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface -{ - private $serviceCompiler; - public function __construct(callable $serviceCompiler = null) - { - $this->serviceCompiler = $serviceCompiler; - } - public function getFunctions() - { - return [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction('service', $this->serviceCompiler ?: function ($arg) { - return \sprintf('$this->get(%s)', $arg); - }, function (array $variables, $value) { - return $variables['container']->get($value); - }), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction('parameter', function ($arg) { - return \sprintf('$this->getParameter(%s)', $arg); - }, function (array $variables, $value) { - return $variables['container']->getParameter($value); - })]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface; +/** + * Define some ExpressionLanguage functions. + * + * To get a service, use service('request'). + * To get a parameter, use parameter('kernel.debug'). + * + * @author Fabien Potencier + */ +class ExpressionLanguageProvider implements \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface +{ + private $serviceCompiler; + public function __construct(callable $serviceCompiler = null) + { + $this->serviceCompiler = $serviceCompiler; + } + public function getFunctions() + { + return [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction('service', $this->serviceCompiler ?: function ($arg) { + return \sprintf('$this->get(%s)', $arg); + }, function (array $variables, $value) { + return $variables['container']->get($value); + }), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction('parameter', function ($arg) { + return \sprintf('$this->getParameter(%s)', $arg); + }, function (array $variables, $value) { + return $variables['container']->getParameter($value); + })]; + } +} diff --git a/vendor/symfony/dependency-injection/Extension/ConfigurationExtensionInterface.php b/vendor/symfony/dependency-injection/Extension/ConfigurationExtensionInterface.php index d2b7b45ad..6880069a6 100644 --- a/vendor/symfony/dependency-injection/Extension/ConfigurationExtensionInterface.php +++ b/vendor/symfony/dependency-injection/Extension/ConfigurationExtensionInterface.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * ConfigurationExtensionInterface is the interface implemented by container extension classes. - * - * @author Kevin Bond - */ -interface ConfigurationExtensionInterface -{ - /** - * Returns extension configuration. - * - * @return ConfigurationInterface|null The configuration or null - */ - public function getConfiguration(array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * ConfigurationExtensionInterface is the interface implemented by container extension classes. + * + * @author Kevin Bond + */ +interface ConfigurationExtensionInterface +{ + /** + * Returns extension configuration. + * + * @return ConfigurationInterface|null The configuration or null + */ + public function getConfiguration(array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container); +} diff --git a/vendor/symfony/dependency-injection/Extension/Extension.php b/vendor/symfony/dependency-injection/Extension/Extension.php index 5d5a92496..b538d56ac 100644 --- a/vendor/symfony/dependency-injection/Extension/Extension.php +++ b/vendor/symfony/dependency-injection/Extension/Extension.php @@ -1,116 +1,116 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -/** - * Provides useful features shared by many extensions. - * - * @author Fabien Potencier - */ -abstract class Extension implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ConfigurationExtensionInterface -{ - private $processedConfigs = []; - /** - * {@inheritdoc} - */ - public function getXsdValidationBasePath() - { - return \false; - } - /** - * {@inheritdoc} - */ - public function getNamespace() - { - return 'http://example.org/schema/dic/' . $this->getAlias(); - } - /** - * Returns the recommended alias to use in XML. - * - * This alias is also the mandatory prefix to use when using YAML. - * - * This convention is to remove the "Extension" postfix from the class - * name and then lowercase and underscore the result. So: - * - * AcmeHelloExtension - * - * becomes - * - * acme_hello - * - * This can be overridden in a sub-class to specify the alias manually. - * - * @return string The alias - * - * @throws BadMethodCallException When the extension name does not follow conventions - */ - public function getAlias() - { - $className = static::class; - if ('Extension' != \substr($className, -9)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('This extension does not follow the naming convention; you must overwrite the getAlias() method.'); - } - $classBaseName = \substr(\strrchr($className, '\\'), 1, -9); - return \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::underscore($classBaseName); - } - /** - * {@inheritdoc} - */ - public function getConfiguration(array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $class = static::class; - if (\false !== \strpos($class, "\0")) { - return null; - // ignore anonymous classes - } - $class = \substr_replace($class, '\\Configuration', \strrpos($class, '\\')); - $class = $container->getReflectionClass($class); - $constructor = $class ? $class->getConstructor() : null; - return $class && (!$constructor || !$constructor->getNumberOfRequiredParameters()) ? $class->newInstance() : null; - } - /** - * @return array - */ - protected final function processConfiguration(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface $configuration, array $configs) - { - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor(); - return $this->processedConfigs[] = $processor->processConfiguration($configuration, $configs); - } - /** - * @internal - */ - public final function getProcessedConfigs() - { - try { - return $this->processedConfigs; - } finally { - $this->processedConfigs = []; - } - } - /** - * @return bool Whether the configuration is enabled - * - * @throws InvalidArgumentException When the config is not enableable - */ - protected function isConfigEnabled(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, array $config) - { - if (!\array_key_exists('enabled', $config)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException("The config array has no 'enabled' key."); - } - return (bool) $container->getParameterBag()->resolveValue($config['enabled']); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +/** + * Provides useful features shared by many extensions. + * + * @author Fabien Potencier + */ +abstract class Extension implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ExtensionInterface, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\ConfigurationExtensionInterface +{ + private $processedConfigs = []; + /** + * {@inheritdoc} + */ + public function getXsdValidationBasePath() + { + return \false; + } + /** + * {@inheritdoc} + */ + public function getNamespace() + { + return 'http://example.org/schema/dic/' . $this->getAlias(); + } + /** + * Returns the recommended alias to use in XML. + * + * This alias is also the mandatory prefix to use when using YAML. + * + * This convention is to remove the "Extension" postfix from the class + * name and then lowercase and underscore the result. So: + * + * AcmeHelloExtension + * + * becomes + * + * acme_hello + * + * This can be overridden in a sub-class to specify the alias manually. + * + * @return string The alias + * + * @throws BadMethodCallException When the extension name does not follow conventions + */ + public function getAlias() + { + $className = static::class; + if ('Extension' != \substr($className, -9)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\BadMethodCallException('This extension does not follow the naming convention; you must overwrite the getAlias() method.'); + } + $classBaseName = \substr(\strrchr($className, '\\'), 1, -9); + return \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::underscore($classBaseName); + } + /** + * {@inheritdoc} + */ + public function getConfiguration(array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $class = static::class; + if (\false !== \strpos($class, "\0")) { + return null; + // ignore anonymous classes + } + $class = \substr_replace($class, '\\Configuration', \strrpos($class, '\\')); + $class = $container->getReflectionClass($class); + $constructor = $class ? $class->getConstructor() : null; + return $class && (!$constructor || !$constructor->getNumberOfRequiredParameters()) ? $class->newInstance() : null; + } + /** + * @return array + */ + protected final function processConfiguration(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface $configuration, array $configs) + { + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Processor(); + return $this->processedConfigs[] = $processor->processConfiguration($configuration, $configs); + } + /** + * @internal + */ + public final function getProcessedConfigs() + { + try { + return $this->processedConfigs; + } finally { + $this->processedConfigs = []; + } + } + /** + * @return bool Whether the configuration is enabled + * + * @throws InvalidArgumentException When the config is not enableable + */ + protected function isConfigEnabled(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, array $config) + { + if (!\array_key_exists('enabled', $config)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException("The config array has no 'enabled' key."); + } + return (bool) $container->getParameterBag()->resolveValue($config['enabled']); + } +} diff --git a/vendor/symfony/dependency-injection/Extension/ExtensionInterface.php b/vendor/symfony/dependency-injection/Extension/ExtensionInterface.php index a4131ab05..d1bf2989c 100644 --- a/vendor/symfony/dependency-injection/Extension/ExtensionInterface.php +++ b/vendor/symfony/dependency-injection/Extension/ExtensionInterface.php @@ -1,47 +1,47 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * ExtensionInterface is the interface implemented by container extension classes. - * - * @author Fabien Potencier - */ -interface ExtensionInterface -{ - /** - * Loads a specific configuration. - * - * @throws \InvalidArgumentException When provided tag is not defined in this extension - */ - public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container); - /** - * Returns the namespace to be used for this extension (XML namespace). - * - * @return string The XML namespace - */ - public function getNamespace(); - /** - * Returns the base path for the XSD files. - * - * @return string|false - */ - public function getXsdValidationBasePath(); - /** - * Returns the recommended alias to use in XML. - * - * This alias is also the mandatory prefix to use when using YAML. - * - * @return string The alias - */ - public function getAlias(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * ExtensionInterface is the interface implemented by container extension classes. + * + * @author Fabien Potencier + */ +interface ExtensionInterface +{ + /** + * Loads a specific configuration. + * + * @throws \InvalidArgumentException When provided tag is not defined in this extension + */ + public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container); + /** + * Returns the namespace to be used for this extension (XML namespace). + * + * @return string The XML namespace + */ + public function getNamespace(); + /** + * Returns the base path for the XSD files. + * + * @return string|false + */ + public function getXsdValidationBasePath(); + /** + * Returns the recommended alias to use in XML. + * + * This alias is also the mandatory prefix to use when using YAML. + * + * @return string The alias + */ + public function getAlias(); +} diff --git a/vendor/symfony/dependency-injection/Extension/PrependExtensionInterface.php b/vendor/symfony/dependency-injection/Extension/PrependExtensionInterface.php index bbc231d10..fc0af0ea3 100644 --- a/vendor/symfony/dependency-injection/Extension/PrependExtensionInterface.php +++ b/vendor/symfony/dependency-injection/Extension/PrependExtensionInterface.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -interface PrependExtensionInterface -{ - /** - * Allow an extension to prepend the extension configurations. - */ - public function prepend(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +interface PrependExtensionInterface +{ + /** + * Allow an extension to prepend the extension configurations. + */ + public function prepend(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container); +} diff --git a/vendor/symfony/dependency-injection/Extension/index.php b/vendor/symfony/dependency-injection/Extension/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Extension/index.php +++ b/vendor/symfony/dependency-injection/Extension/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/LICENSE b/vendor/symfony/dependency-injection/LICENSE index 9e936ec04..2bb330476 100644 --- a/vendor/symfony/dependency-injection/LICENSE +++ b/vendor/symfony/dependency-injection/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2004-2020 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2004-2020 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/dependency-injection/LazyProxy/Instantiator/InstantiatorInterface.php b/vendor/symfony/dependency-injection/LazyProxy/Instantiator/InstantiatorInterface.php index 2633b6f5e..4cd058afd 100644 --- a/vendor/symfony/dependency-injection/LazyProxy/Instantiator/InstantiatorInterface.php +++ b/vendor/symfony/dependency-injection/LazyProxy/Instantiator/InstantiatorInterface.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -/** - * Lazy proxy instantiator, capable of instantiating a proxy given a container, the - * service definitions and a callback that produces the real service instance. - * - * @author Marco Pivetta - */ -interface InstantiatorInterface -{ - /** - * Instantiates a proxy object. - * - * @param ContainerInterface $container The container from which the service is being requested - * @param Definition $definition The definition of the requested service - * @param string $id Identifier of the requested service - * @param callable $realInstantiator Zero-argument callback that is capable of producing the real service instance - * - * @return object - */ - public function instantiateProxy(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id, $realInstantiator); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +/** + * Lazy proxy instantiator, capable of instantiating a proxy given a container, the + * service definitions and a callback that produces the real service instance. + * + * @author Marco Pivetta + */ +interface InstantiatorInterface +{ + /** + * Instantiates a proxy object. + * + * @param ContainerInterface $container The container from which the service is being requested + * @param Definition $definition The definition of the requested service + * @param string $id Identifier of the requested service + * @param callable $realInstantiator Zero-argument callback that is capable of producing the real service instance + * + * @return object + */ + public function instantiateProxy(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id, $realInstantiator); +} diff --git a/vendor/symfony/dependency-injection/LazyProxy/Instantiator/RealServiceInstantiator.php b/vendor/symfony/dependency-injection/LazyProxy/Instantiator/RealServiceInstantiator.php index 5a138a55e..62e1d5376 100644 --- a/vendor/symfony/dependency-injection/LazyProxy/Instantiator/RealServiceInstantiator.php +++ b/vendor/symfony/dependency-injection/LazyProxy/Instantiator/RealServiceInstantiator.php @@ -1,31 +1,31 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -/** - * {@inheritdoc} - * - * Noop proxy instantiator - produces the real service instead of a proxy instance. - * - * @author Marco Pivetta - */ -class RealServiceInstantiator implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\InstantiatorInterface -{ - /** - * {@inheritdoc} - */ - public function instantiateProxy(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id, $realInstantiator) - { - return \call_user_func($realInstantiator); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +/** + * {@inheritdoc} + * + * Noop proxy instantiator - produces the real service instead of a proxy instance. + * + * @author Marco Pivetta + */ +class RealServiceInstantiator implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\InstantiatorInterface +{ + /** + * {@inheritdoc} + */ + public function instantiateProxy(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface $container, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id, $realInstantiator) + { + return \call_user_func($realInstantiator); + } +} diff --git a/vendor/symfony/dependency-injection/LazyProxy/Instantiator/index.php b/vendor/symfony/dependency-injection/LazyProxy/Instantiator/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/LazyProxy/Instantiator/index.php +++ b/vendor/symfony/dependency-injection/LazyProxy/Instantiator/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/DumperInterface.php b/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/DumperInterface.php index ec06a642b..fdfcde6e3 100644 --- a/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/DumperInterface.php +++ b/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/DumperInterface.php @@ -1,41 +1,41 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -/** - * Lazy proxy dumper capable of generating the instantiation logic PHP code for proxied services. - * - * @author Marco Pivetta - */ -interface DumperInterface -{ - /** - * Inspects whether the given definitions should produce proxy instantiation logic in the dumped container. - * - * @return bool - */ - public function isProxyCandidate(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition); - /** - * Generates the code to be used to instantiate a proxy in the dumped factory code. - * - * @param string $id Service identifier - * - * @return string - */ - public function getProxyFactoryCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id); - /** - * Generates the code for the lazy proxy. - * - * @return string - */ - public function getProxyCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +/** + * Lazy proxy dumper capable of generating the instantiation logic PHP code for proxied services. + * + * @author Marco Pivetta + */ +interface DumperInterface +{ + /** + * Inspects whether the given definitions should produce proxy instantiation logic in the dumped container. + * + * @return bool + */ + public function isProxyCandidate(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition); + /** + * Generates the code to be used to instantiate a proxy in the dumped factory code. + * + * @param string $id Service identifier + * + * @return string + */ + public function getProxyFactoryCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id); + /** + * Generates the code for the lazy proxy. + * + * @return string + */ + public function getProxyCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition); +} diff --git a/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/NullDumper.php b/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/NullDumper.php index f7db10973..c57003c0d 100644 --- a/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/NullDumper.php +++ b/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/NullDumper.php @@ -1,44 +1,44 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -/** - * Null dumper, negates any proxy code generation for any given service definition. - * - * @author Marco Pivetta - * - * @final since version 3.3 - */ -class NullDumper implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface -{ - /** - * {@inheritdoc} - */ - public function isProxyCandidate(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - return \false; - } - /** - * {@inheritdoc} - */ - public function getProxyFactoryCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id, $factoryCode = null) - { - return ''; - } - /** - * {@inheritdoc} - */ - public function getProxyCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - return ''; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +/** + * Null dumper, negates any proxy code generation for any given service definition. + * + * @author Marco Pivetta + * + * @final since version 3.3 + */ +class NullDumper implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface +{ + /** + * {@inheritdoc} + */ + public function isProxyCandidate(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + return \false; + } + /** + * {@inheritdoc} + */ + public function getProxyFactoryCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id, $factoryCode = null) + { + return ''; + } + /** + * {@inheritdoc} + */ + public function getProxyCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + return ''; + } +} diff --git a/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/index.php b/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/index.php +++ b/vendor/symfony/dependency-injection/LazyProxy/PhpDumper/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/LazyProxy/ProxyHelper.php b/vendor/symfony/dependency-injection/LazyProxy/ProxyHelper.php index c789c53cf..f9bd3449c 100644 --- a/vendor/symfony/dependency-injection/LazyProxy/ProxyHelper.php +++ b/vendor/symfony/dependency-injection/LazyProxy/ProxyHelper.php @@ -1,59 +1,59 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy; - -/** - * @author Nicolas Grekas - * - * @internal - */ -class ProxyHelper -{ - /** - * @return string|null The FQCN or builtin name of the type hint, or null when the type hint references an invalid self|parent context - */ - public static function getTypeHint(\ReflectionFunctionAbstract $r, \ReflectionParameter $p = null, $noBuiltin = \false) - { - if ($p instanceof \ReflectionParameter) { - if (\method_exists($p, 'getType')) { - $type = $p->getType(); - } elseif (\preg_match('/^(?:[^ ]++ ){4}([a-zA-Z_\\x7F-\\xFF][^ ]++)/', $p, $type)) { - $name = $type = $type[1]; - if ('callable' === $name || 'array' === $name) { - return $noBuiltin ? null : $name; - } - } - } else { - $type = \method_exists($r, 'getReturnType') ? $r->getReturnType() : null; - } - if (!$type) { - return null; - } - if (!\is_string($type)) { - $name = $type instanceof \ReflectionNamedType ? $type->getName() : $type->__toString(); - if ($type->isBuiltin()) { - return $noBuiltin ? null : $name; - } - } - $lcName = \strtolower($name); - $prefix = $noBuiltin ? '' : '\\'; - if ('self' !== $lcName && 'parent' !== $lcName) { - return $prefix . $name; - } - if (!$r instanceof \ReflectionMethod) { - return null; - } - if ('self' === $lcName) { - return $prefix . $r->getDeclaringClass()->name; - } - return ($parent = $r->getDeclaringClass()->getParentClass()) ? $prefix . $parent->name : null; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy; + +/** + * @author Nicolas Grekas + * + * @internal + */ +class ProxyHelper +{ + /** + * @return string|null The FQCN or builtin name of the type hint, or null when the type hint references an invalid self|parent context + */ + public static function getTypeHint(\ReflectionFunctionAbstract $r, \ReflectionParameter $p = null, $noBuiltin = \false) + { + if ($p instanceof \ReflectionParameter) { + if (\method_exists($p, 'getType')) { + $type = $p->getType(); + } elseif (\preg_match('/^(?:[^ ]++ ){4}([a-zA-Z_\\x7F-\\xFF][^ ]++)/', $p, $type)) { + $name = $type = $type[1]; + if ('callable' === $name || 'array' === $name) { + return $noBuiltin ? null : $name; + } + } + } else { + $type = \method_exists($r, 'getReturnType') ? $r->getReturnType() : null; + } + if (!$type) { + return null; + } + if (!\is_string($type)) { + $name = $type instanceof \ReflectionNamedType ? $type->getName() : $type->__toString(); + if ($type->isBuiltin()) { + return $noBuiltin ? null : $name; + } + } + $lcName = \strtolower($name); + $prefix = $noBuiltin ? '' : '\\'; + if ('self' !== $lcName && 'parent' !== $lcName) { + return $prefix . $name; + } + if (!$r instanceof \ReflectionMethod) { + return null; + } + if ('self' === $lcName) { + return $prefix . $r->getDeclaringClass()->name; + } + return ($parent = $r->getDeclaringClass()->getParentClass()) ? $prefix . $parent->name : null; + } +} diff --git a/vendor/symfony/dependency-injection/LazyProxy/index.php b/vendor/symfony/dependency-injection/LazyProxy/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/LazyProxy/index.php +++ b/vendor/symfony/dependency-injection/LazyProxy/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/ClosureLoader.php b/vendor/symfony/dependency-injection/Loader/ClosureLoader.php index 58ce783f6..070a84f79 100644 --- a/vendor/symfony/dependency-injection/Loader/ClosureLoader.php +++ b/vendor/symfony/dependency-injection/Loader/ClosureLoader.php @@ -1,43 +1,43 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * ClosureLoader loads service definitions from a PHP closure. - * - * The Closure has access to the container as its first argument. - * - * @author Fabien Potencier - */ -class ClosureLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader -{ - private $container; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $this->container = $container; - } - /** - * {@inheritdoc} - */ - public function load($resource, $type = null) - { - \call_user_func($resource, $this->container); - } - /** - * {@inheritdoc} - */ - public function supports($resource, $type = null) - { - return $resource instanceof \Closure; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * ClosureLoader loads service definitions from a PHP closure. + * + * The Closure has access to the container as its first argument. + * + * @author Fabien Potencier + */ +class ClosureLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\Loader +{ + private $container; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $this->container = $container; + } + /** + * {@inheritdoc} + */ + public function load($resource, $type = null) + { + \call_user_func($resource, $this->container); + } + /** + * {@inheritdoc} + */ + public function supports($resource, $type = null) + { + return $resource instanceof \Closure; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/AbstractConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/AbstractConfigurator.php index 26a2395b5..c5a39b2ad 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/AbstractConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/AbstractConfigurator.php @@ -1,73 +1,73 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -abstract class AbstractConfigurator -{ - const FACTORY = 'unknown'; - /** @internal */ - protected $definition; - public function __call($method, $args) - { - if (\method_exists($this, 'set' . $method)) { - return \call_user_func_array([$this, 'set' . $method], $args); - } - throw new \BadMethodCallException(\sprintf('Call to undefined method "%s::%s()".', static::class, $method)); - } - /** - * Checks that a value is valid, optionally replacing Definition and Reference configurators by their configure value. - * - * @param mixed $value - * @param bool $allowServices whether Definition and Reference are allowed; by default, only scalars and arrays are - * - * @return mixed the value, optionally cast to a Definition/Reference - */ - public static function processValue($value, $allowServices = \false) - { - if (\is_array($value)) { - foreach ($value as $k => $v) { - $value[$k] = static::processValue($v, $allowServices); - } - return $value; - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ReferenceConfigurator) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($value->id, $value->invalidBehavior); - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\InlineServiceConfigurator) { - $def = $value->definition; - $value->definition = null; - return $def; - } - if ($value instanceof self) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"%s()" can be used only at the root of service configuration files.', $value::FACTORY)); - } - switch (\true) { - case null === $value: - case \is_scalar($value): - return $value; - case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface: - case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition: - case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression: - case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter: - case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference: - if ($allowServices) { - return $value; - } - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Cannot use values of type "%s" in service configuration files.', \is_object($value) ? \get_class($value) : \gettype($value))); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +abstract class AbstractConfigurator +{ + const FACTORY = 'unknown'; + /** @internal */ + protected $definition; + public function __call($method, $args) + { + if (\method_exists($this, 'set' . $method)) { + return \call_user_func_array([$this, 'set' . $method], $args); + } + throw new \BadMethodCallException(\sprintf('Call to undefined method "%s::%s()".', static::class, $method)); + } + /** + * Checks that a value is valid, optionally replacing Definition and Reference configurators by their configure value. + * + * @param mixed $value + * @param bool $allowServices whether Definition and Reference are allowed; by default, only scalars and arrays are + * + * @return mixed the value, optionally cast to a Definition/Reference + */ + public static function processValue($value, $allowServices = \false) + { + if (\is_array($value)) { + foreach ($value as $k => $v) { + $value[$k] = static::processValue($v, $allowServices); + } + return $value; + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ReferenceConfigurator) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($value->id, $value->invalidBehavior); + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\InlineServiceConfigurator) { + $def = $value->definition; + $value->definition = null; + return $def; + } + if ($value instanceof self) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"%s()" can be used only at the root of service configuration files.', $value::FACTORY)); + } + switch (\true) { + case null === $value: + case \is_scalar($value): + return $value; + case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface: + case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition: + case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression: + case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter: + case $value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference: + if ($allowServices) { + return $value; + } + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Cannot use values of type "%s" in service configuration files.', \is_object($value) ? \get_class($value) : \gettype($value))); + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/AbstractServiceConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/AbstractServiceConfigurator.php index 1c06edcc8..81869eba9 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/AbstractServiceConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/AbstractServiceConfigurator.php @@ -1,103 +1,103 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; -abstract class AbstractServiceConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator -{ - protected $parent; - protected $id; - private $defaultTags = []; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServicesConfigurator $parent, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id = null, array $defaultTags = []) - { - $this->parent = $parent; - $this->definition = $definition; - $this->id = $id; - $this->defaultTags = $defaultTags; - } - public function __destruct() - { - // default tags should be added last - foreach ($this->defaultTags as $name => $attributes) { - foreach ($attributes as $attributes) { - $this->definition->addTag($name, $attributes); - } - } - $this->defaultTags = []; - } - /** - * Registers a service. - * - * @param string $id - * @param string|null $class - * - * @return ServiceConfigurator - */ - public final function set($id, $class = null) - { - $this->__destruct(); - return $this->parent->set($id, $class); - } - /** - * Creates an alias. - * - * @param string $id - * @param string $referencedId - * - * @return AliasConfigurator - */ - public final function alias($id, $referencedId) - { - $this->__destruct(); - return $this->parent->alias($id, $referencedId); - } - /** - * Registers a PSR-4 namespace using a glob pattern. - * - * @param string $namespace - * @param string $resource - * - * @return PrototypeConfigurator - */ - public final function load($namespace, $resource) - { - $this->__destruct(); - return $this->parent->load($namespace, $resource); - } - /** - * Gets an already defined service definition. - * - * @param string $id - * - * @return ServiceConfigurator - * - * @throws ServiceNotFoundException if the service definition does not exist - */ - public final function get($id) - { - $this->__destruct(); - return $this->parent->get($id); - } - /** - * Registers a service. - * - * @param string $id - * @param string|null $class - * - * @return ServiceConfigurator - */ - public final function __invoke($id, $class = null) - { - $this->__destruct(); - return $this->parent->set($id, $class); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; +abstract class AbstractServiceConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator +{ + protected $parent; + protected $id; + private $defaultTags = []; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServicesConfigurator $parent, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id = null, array $defaultTags = []) + { + $this->parent = $parent; + $this->definition = $definition; + $this->id = $id; + $this->defaultTags = $defaultTags; + } + public function __destruct() + { + // default tags should be added last + foreach ($this->defaultTags as $name => $attributes) { + foreach ($attributes as $attributes) { + $this->definition->addTag($name, $attributes); + } + } + $this->defaultTags = []; + } + /** + * Registers a service. + * + * @param string $id + * @param string|null $class + * + * @return ServiceConfigurator + */ + public final function set($id, $class = null) + { + $this->__destruct(); + return $this->parent->set($id, $class); + } + /** + * Creates an alias. + * + * @param string $id + * @param string $referencedId + * + * @return AliasConfigurator + */ + public final function alias($id, $referencedId) + { + $this->__destruct(); + return $this->parent->alias($id, $referencedId); + } + /** + * Registers a PSR-4 namespace using a glob pattern. + * + * @param string $namespace + * @param string $resource + * + * @return PrototypeConfigurator + */ + public final function load($namespace, $resource) + { + $this->__destruct(); + return $this->parent->load($namespace, $resource); + } + /** + * Gets an already defined service definition. + * + * @param string $id + * + * @return ServiceConfigurator + * + * @throws ServiceNotFoundException if the service definition does not exist + */ + public final function get($id) + { + $this->__destruct(); + return $this->parent->get($id); + } + /** + * Registers a service. + * + * @param string $id + * @param string|null $class + * + * @return ServiceConfigurator + */ + public final function __invoke($id, $class = null) + { + $this->__destruct(); + return $this->parent->set($id, $class); + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/AliasConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/AliasConfigurator.php index 3e902f1e9..7dcead840 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/AliasConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/AliasConfigurator.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -/** - * @author Nicolas Grekas - */ -class AliasConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractServiceConfigurator -{ - const FACTORY = 'alias'; - use Traits\PublicTrait; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServicesConfigurator $parent, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias $alias) - { - $this->parent = $parent; - $this->definition = $alias; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +/** + * @author Nicolas Grekas + */ +class AliasConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractServiceConfigurator +{ + const FACTORY = 'alias'; + use Traits\PublicTrait; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServicesConfigurator $parent, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias $alias) + { + $this->parent = $parent; + $this->definition = $alias; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/ContainerConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/ContainerConfigurator.php index cdf7797f6..d6c4b3432 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/ContainerConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/ContainerConfigurator.php @@ -1,123 +1,123 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -/** - * @author Nicolas Grekas - */ -class ContainerConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator -{ - const FACTORY = 'container'; - private $container; - private $loader; - private $instanceof; - private $path; - private $file; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader $loader, array &$instanceof, $path, $file) - { - $this->container = $container; - $this->loader = $loader; - $this->instanceof =& $instanceof; - $this->path = $path; - $this->file = $file; - } - public final function extension($namespace, array $config) - { - if (!$this->container->hasExtension($namespace)) { - $extensions = \array_filter(\array_map(function ($ext) { - return $ext->getAlias(); - }, $this->container->getExtensions())); - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('There is no extension able to load the configuration for "%s" (in "%s"). Looked for namespace "%s", found "%s".', $namespace, $this->file, $namespace, $extensions ? \implode('", "', $extensions) : 'none')); - } - $this->container->loadFromExtension($namespace, static::processValue($config)); - } - public final function import($resource, $type = null, $ignoreErrors = \false) - { - $this->loader->setCurrentDir(\dirname($this->path)); - $this->loader->import($resource, $type, $ignoreErrors, $this->file); - } - /** - * @return ParametersConfigurator - */ - public final function parameters() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ParametersConfigurator($this->container); - } - /** - * @return ServicesConfigurator - */ - public final function services() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServicesConfigurator($this->container, $this->loader, $this->instanceof); - } -} -/** - * Creates a service reference. - * - * @param string $id - * - * @return ReferenceConfigurator - */ -function ref($id) -{ - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ReferenceConfigurator($id); -} -/** - * Creates an inline service. - * - * @param string|null $class - * - * @return InlineServiceConfigurator - */ -function inline($class = null) -{ - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\InlineServiceConfigurator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($class)); -} -/** - * Creates a lazy iterator. - * - * @param ReferenceConfigurator[] $values - * - * @return IteratorArgument - */ -function iterator(array $values) -{ - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator::processValue($values, \true)); -} -/** - * Creates a lazy iterator by tag name. - * - * @param string $tag - * - * @return TaggedIteratorArgument - */ -function tagged($tag) -{ - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument($tag); -} -/** - * Creates an expression. - * - * @param string $expression an expression - * - * @return Expression - */ -function expr($expression) -{ - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression($expression); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +/** + * @author Nicolas Grekas + */ +class ContainerConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator +{ + const FACTORY = 'container'; + private $container; + private $loader; + private $instanceof; + private $path; + private $file; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader $loader, array &$instanceof, $path, $file) + { + $this->container = $container; + $this->loader = $loader; + $this->instanceof =& $instanceof; + $this->path = $path; + $this->file = $file; + } + public final function extension($namespace, array $config) + { + if (!$this->container->hasExtension($namespace)) { + $extensions = \array_filter(\array_map(function ($ext) { + return $ext->getAlias(); + }, $this->container->getExtensions())); + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('There is no extension able to load the configuration for "%s" (in "%s"). Looked for namespace "%s", found "%s".', $namespace, $this->file, $namespace, $extensions ? \implode('", "', $extensions) : 'none')); + } + $this->container->loadFromExtension($namespace, static::processValue($config)); + } + public final function import($resource, $type = null, $ignoreErrors = \false) + { + $this->loader->setCurrentDir(\dirname($this->path)); + $this->loader->import($resource, $type, $ignoreErrors, $this->file); + } + /** + * @return ParametersConfigurator + */ + public final function parameters() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ParametersConfigurator($this->container); + } + /** + * @return ServicesConfigurator + */ + public final function services() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServicesConfigurator($this->container, $this->loader, $this->instanceof); + } +} +/** + * Creates a service reference. + * + * @param string $id + * + * @return ReferenceConfigurator + */ +function ref($id) +{ + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ReferenceConfigurator($id); +} +/** + * Creates an inline service. + * + * @param string|null $class + * + * @return InlineServiceConfigurator + */ +function inline($class = null) +{ + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\InlineServiceConfigurator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition($class)); +} +/** + * Creates a lazy iterator. + * + * @param ReferenceConfigurator[] $values + * + * @return IteratorArgument + */ +function iterator(array $values) +{ + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator::processValue($values, \true)); +} +/** + * Creates a lazy iterator by tag name. + * + * @param string $tag + * + * @return TaggedIteratorArgument + */ +function tagged($tag) +{ + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument($tag); +} +/** + * Creates an expression. + * + * @param string $expression an expression + * + * @return Expression + */ +function expr($expression) +{ + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression($expression); +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/DefaultsConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/DefaultsConfigurator.php index 0d3a25768..edb4978b5 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/DefaultsConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/DefaultsConfigurator.php @@ -1,60 +1,60 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -/** - * @author Nicolas Grekas - * - * @method InstanceofConfigurator instanceof(string $fqcn) - */ -class DefaultsConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractServiceConfigurator -{ - const FACTORY = 'defaults'; - use Traits\AutoconfigureTrait; - use Traits\AutowireTrait; - use Traits\BindTrait; - use Traits\PublicTrait; - /** - * Adds a tag for this definition. - * - * @param string $name The tag name - * @param array $attributes An array of attributes - * - * @return $this - * - * @throws InvalidArgumentException when an invalid tag name or attribute is provided - */ - public final function tag($name, array $attributes = []) - { - if (!\is_string($name) || '' === $name) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('The tag name in "_defaults" must be a non-empty string.'); - } - foreach ($attributes as $attribute => $value) { - if (!\is_scalar($value) && null !== $value) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Tag "%s", attribute "%s" in "_defaults" must be of a scalar-type.', $name, $attribute)); - } - } - $this->definition->addTag($name, $attributes); - return $this; - } - /** - * Defines an instanceof-conditional to be applied to following service definitions. - * - * @param string $fqcn - * - * @return InstanceofConfigurator - */ - protected final function setInstanceof($fqcn) - { - return $this->parent->instanceof($fqcn); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +/** + * @author Nicolas Grekas + * + * @method InstanceofConfigurator instanceof(string $fqcn) + */ +class DefaultsConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractServiceConfigurator +{ + const FACTORY = 'defaults'; + use Traits\AutoconfigureTrait; + use Traits\AutowireTrait; + use Traits\BindTrait; + use Traits\PublicTrait; + /** + * Adds a tag for this definition. + * + * @param string $name The tag name + * @param array $attributes An array of attributes + * + * @return $this + * + * @throws InvalidArgumentException when an invalid tag name or attribute is provided + */ + public final function tag($name, array $attributes = []) + { + if (!\is_string($name) || '' === $name) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException('The tag name in "_defaults" must be a non-empty string.'); + } + foreach ($attributes as $attribute => $value) { + if (!\is_scalar($value) && null !== $value) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Tag "%s", attribute "%s" in "_defaults" must be of a scalar-type.', $name, $attribute)); + } + } + $this->definition->addTag($name, $attributes); + return $this; + } + /** + * Defines an instanceof-conditional to be applied to following service definitions. + * + * @param string $fqcn + * + * @return InstanceofConfigurator + */ + protected final function setInstanceof($fqcn) + { + return $this->parent->instanceof($fqcn); + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/InlineServiceConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/InlineServiceConfigurator.php index d3a99ab6c..f0f10aac9 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/InlineServiceConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/InlineServiceConfigurator.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -/** - * @author Nicolas Grekas - */ -class InlineServiceConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator -{ - const FACTORY = 'inline'; - use Traits\ArgumentTrait; - use Traits\AutowireTrait; - use Traits\BindTrait; - use Traits\FactoryTrait; - use Traits\FileTrait; - use Traits\LazyTrait; - use Traits\ParentTrait; - use Traits\TagTrait; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - $this->definition = $definition; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +/** + * @author Nicolas Grekas + */ +class InlineServiceConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator +{ + const FACTORY = 'inline'; + use Traits\ArgumentTrait; + use Traits\AutowireTrait; + use Traits\BindTrait; + use Traits\FactoryTrait; + use Traits\FileTrait; + use Traits\LazyTrait; + use Traits\ParentTrait; + use Traits\TagTrait; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + $this->definition = $definition; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/InstanceofConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/InstanceofConfigurator.php index 487d8e904..0622b3e2c 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/InstanceofConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/InstanceofConfigurator.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -/** - * @author Nicolas Grekas - * - * @method InstanceofConfigurator instanceof(string $fqcn) - */ -class InstanceofConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractServiceConfigurator -{ - const FACTORY = 'instanceof'; - use Traits\AutowireTrait; - use Traits\CallTrait; - use Traits\ConfiguratorTrait; - use Traits\LazyTrait; - use Traits\PropertyTrait; - use Traits\PublicTrait; - use Traits\ShareTrait; - use Traits\TagTrait; - /** - * Defines an instanceof-conditional to be applied to following service definitions. - * - * @param string $fqcn - * - * @return self - */ - protected final function setInstanceof($fqcn) - { - return $this->parent->instanceof($fqcn); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +/** + * @author Nicolas Grekas + * + * @method InstanceofConfigurator instanceof(string $fqcn) + */ +class InstanceofConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractServiceConfigurator +{ + const FACTORY = 'instanceof'; + use Traits\AutowireTrait; + use Traits\CallTrait; + use Traits\ConfiguratorTrait; + use Traits\LazyTrait; + use Traits\PropertyTrait; + use Traits\PublicTrait; + use Traits\ShareTrait; + use Traits\TagTrait; + /** + * Defines an instanceof-conditional to be applied to following service definitions. + * + * @param string $fqcn + * + * @return self + */ + protected final function setInstanceof($fqcn) + { + return $this->parent->instanceof($fqcn); + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/ParametersConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/ParametersConfigurator.php index 039f568bf..c29ee251e 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/ParametersConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/ParametersConfigurator.php @@ -1,50 +1,50 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * @author Nicolas Grekas - */ -class ParametersConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator -{ - const FACTORY = 'parameters'; - private $container; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $this->container = $container; - } - /** - * Creates a parameter. - * - * @param string $name - * @param mixed $value - * - * @return $this - */ - public final function set($name, $value) - { - $this->container->setParameter($name, static::processValue($value, \true)); - return $this; - } - /** - * Creates a parameter. - * - * @param string $name - * @param mixed $value - * - * @return $this - */ - public final function __invoke($name, $value) - { - return $this->set($name, $value); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * @author Nicolas Grekas + */ +class ParametersConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator +{ + const FACTORY = 'parameters'; + private $container; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $this->container = $container; + } + /** + * Creates a parameter. + * + * @param string $name + * @param mixed $value + * + * @return $this + */ + public final function set($name, $value) + { + $this->container->setParameter($name, static::processValue($value, \true)); + return $this; + } + /** + * Creates a parameter. + * + * @param string $name + * @param mixed $value + * + * @return $this + */ + public final function __invoke($name, $value) + { + return $this->set($name, $value); + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/PrototypeConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/PrototypeConfigurator.php index 915b20564..65d0ca412 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/PrototypeConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/PrototypeConfigurator.php @@ -1,73 +1,73 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -/** - * @author Nicolas Grekas - */ -class PrototypeConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractServiceConfigurator -{ - const FACTORY = 'load'; - use Traits\AbstractTrait; - use Traits\ArgumentTrait; - use Traits\AutoconfigureTrait; - use Traits\AutowireTrait; - use Traits\BindTrait; - use Traits\CallTrait; - use Traits\ConfiguratorTrait; - use Traits\DeprecateTrait; - use Traits\FactoryTrait; - use Traits\LazyTrait; - use Traits\ParentTrait; - use Traits\PropertyTrait; - use Traits\PublicTrait; - use Traits\ShareTrait; - use Traits\TagTrait; - private $loader; - private $resource; - private $exclude; - private $allowParent; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServicesConfigurator $parent, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader $loader, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $defaults, $namespace, $resource, $allowParent) - { - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $definition->setPublic($defaults->isPublic()); - $definition->setAutowired($defaults->isAutowired()); - $definition->setAutoconfigured($defaults->isAutoconfigured()); - $definition->setBindings($defaults->getBindings()); - $definition->setChanges([]); - $this->loader = $loader; - $this->resource = $resource; - $this->allowParent = $allowParent; - parent::__construct($parent, $definition, $namespace, $defaults->getTags()); - } - public function __destruct() - { - parent::__destruct(); - if ($this->loader) { - $this->loader->registerClasses($this->definition, $this->id, $this->resource, $this->exclude); - } - $this->loader = null; - } - /** - * Excludes files from registration using a glob pattern. - * - * @param string $exclude - * - * @return $this - */ - public final function exclude($exclude) - { - $this->exclude = $exclude; - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; +/** + * @author Nicolas Grekas + */ +class PrototypeConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractServiceConfigurator +{ + const FACTORY = 'load'; + use Traits\AbstractTrait; + use Traits\ArgumentTrait; + use Traits\AutoconfigureTrait; + use Traits\AutowireTrait; + use Traits\BindTrait; + use Traits\CallTrait; + use Traits\ConfiguratorTrait; + use Traits\DeprecateTrait; + use Traits\FactoryTrait; + use Traits\LazyTrait; + use Traits\ParentTrait; + use Traits\PropertyTrait; + use Traits\PublicTrait; + use Traits\ShareTrait; + use Traits\TagTrait; + private $loader; + private $resource; + private $exclude; + private $allowParent; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServicesConfigurator $parent, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader $loader, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $defaults, $namespace, $resource, $allowParent) + { + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $definition->setPublic($defaults->isPublic()); + $definition->setAutowired($defaults->isAutowired()); + $definition->setAutoconfigured($defaults->isAutoconfigured()); + $definition->setBindings($defaults->getBindings()); + $definition->setChanges([]); + $this->loader = $loader; + $this->resource = $resource; + $this->allowParent = $allowParent; + parent::__construct($parent, $definition, $namespace, $defaults->getTags()); + } + public function __destruct() + { + parent::__destruct(); + if ($this->loader) { + $this->loader->registerClasses($this->definition, $this->id, $this->resource, $this->exclude); + } + $this->loader = null; + } + /** + * Excludes files from registration using a glob pattern. + * + * @param string $exclude + * + * @return $this + */ + public final function exclude($exclude) + { + $this->exclude = $exclude; + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/ReferenceConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/ReferenceConfigurator.php index 8e87f08dc..50988970a 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/ReferenceConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/ReferenceConfigurator.php @@ -1,55 +1,55 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -/** - * @author Nicolas Grekas - */ -class ReferenceConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator -{ - /** @internal */ - protected $id; - /** @internal */ - protected $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE; - public function __construct($id) - { - $this->id = $id; - } - /** - * @return $this - */ - public final function ignoreOnInvalid() - { - $this->invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE; - return $this; - } - /** - * @return $this - */ - public final function nullOnInvalid() - { - $this->invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE; - return $this; - } - /** - * @return $this - */ - public final function ignoreOnUninitialized() - { - $this->invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE; - return $this; - } - public function __toString() - { - return $this->id; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +/** + * @author Nicolas Grekas + */ +class ReferenceConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator +{ + /** @internal */ + protected $id; + /** @internal */ + protected $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE; + public function __construct($id) + { + $this->id = $id; + } + /** + * @return $this + */ + public final function ignoreOnInvalid() + { + $this->invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE; + return $this; + } + /** + * @return $this + */ + public final function nullOnInvalid() + { + $this->invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE; + return $this; + } + /** + * @return $this + */ + public final function ignoreOnUninitialized() + { + $this->invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE; + return $this; + } + public function __toString() + { + return $this->id; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/ServiceConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/ServiceConfigurator.php index ca85c4dfa..3ec8fd89f 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/ServiceConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/ServiceConfigurator.php @@ -1,61 +1,61 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -/** - * @author Nicolas Grekas - */ -class ServiceConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractServiceConfigurator -{ - const FACTORY = 'services'; - use Traits\AbstractTrait; - use Traits\ArgumentTrait; - use Traits\AutoconfigureTrait; - use Traits\AutowireTrait; - use Traits\BindTrait; - use Traits\CallTrait; - use Traits\ClassTrait; - use Traits\ConfiguratorTrait; - use Traits\DecorateTrait; - use Traits\DeprecateTrait; - use Traits\FactoryTrait; - use Traits\FileTrait; - use Traits\LazyTrait; - use Traits\ParentTrait; - use Traits\PropertyTrait; - use Traits\PublicTrait; - use Traits\ShareTrait; - use Traits\SyntheticTrait; - use Traits\TagTrait; - private $container; - private $instanceof; - private $allowParent; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, array $instanceof, $allowParent, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServicesConfigurator $parent, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id, array $defaultTags) - { - $this->container = $container; - $this->instanceof = $instanceof; - $this->allowParent = $allowParent; - parent::__construct($parent, $definition, $id, $defaultTags); - } - public function __destruct() - { - parent::__destruct(); - $this->container->removeBindings($this->id); - if (!$this->definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { - $this->container->setDefinition($this->id, $this->definition->setInstanceofConditionals($this->instanceof)); - } else { - $this->container->setDefinition($this->id, $this->definition); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +/** + * @author Nicolas Grekas + */ +class ServiceConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractServiceConfigurator +{ + const FACTORY = 'services'; + use Traits\AbstractTrait; + use Traits\ArgumentTrait; + use Traits\AutoconfigureTrait; + use Traits\AutowireTrait; + use Traits\BindTrait; + use Traits\CallTrait; + use Traits\ClassTrait; + use Traits\ConfiguratorTrait; + use Traits\DecorateTrait; + use Traits\DeprecateTrait; + use Traits\FactoryTrait; + use Traits\FileTrait; + use Traits\LazyTrait; + use Traits\ParentTrait; + use Traits\PropertyTrait; + use Traits\PublicTrait; + use Traits\ShareTrait; + use Traits\SyntheticTrait; + use Traits\TagTrait; + private $container; + private $instanceof; + private $allowParent; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, array $instanceof, $allowParent, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServicesConfigurator $parent, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id, array $defaultTags) + { + $this->container = $container; + $this->instanceof = $instanceof; + $this->allowParent = $allowParent; + parent::__construct($parent, $definition, $id, $defaultTags); + } + public function __destruct() + { + parent::__destruct(); + $this->container->removeBindings($this->id); + if (!$this->definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { + $this->container->setDefinition($this->id, $this->definition->setInstanceofConditionals($this->instanceof)); + } else { + $this->container->setDefinition($this->id, $this->definition); + } + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/ServicesConfigurator.php b/vendor/symfony/dependency-injection/Loader/Configurator/ServicesConfigurator.php index 493c98ca7..11da1f091 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/ServicesConfigurator.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/ServicesConfigurator.php @@ -1,136 +1,136 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -/** - * @author Nicolas Grekas - * - * @method InstanceofConfigurator instanceof($fqcn) - */ -class ServicesConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator -{ - const FACTORY = 'services'; - private $defaults; - private $container; - private $loader; - private $instanceof; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader $loader, array &$instanceof) - { - $this->defaults = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $this->container = $container; - $this->loader = $loader; - $this->instanceof =& $instanceof; - $instanceof = []; - } - /** - * Defines a set of defaults for following service definitions. - * - * @return DefaultsConfigurator - */ - public final function defaults() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\DefaultsConfigurator($this, $this->defaults = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition()); - } - /** - * Defines an instanceof-conditional to be applied to following service definitions. - * - * @param string $fqcn - * - * @return InstanceofConfigurator - */ - protected final function setInstanceof($fqcn) - { - $this->instanceof[$fqcn] = $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\InstanceofConfigurator($this, $definition, $fqcn); - } - /** - * Registers a service. - * - * @param string $id - * @param string|null $class - * - * @return ServiceConfigurator - */ - public final function set($id, $class = null) - { - $defaults = $this->defaults; - $allowParent = !$defaults->getChanges() && empty($this->instanceof); - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $definition->setPublic($defaults->isPublic()); - $definition->setAutowired($defaults->isAutowired()); - $definition->setAutoconfigured($defaults->isAutoconfigured()); - $definition->setBindings($defaults->getBindings()); - $definition->setChanges([]); - $configurator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServiceConfigurator($this->container, $this->instanceof, $allowParent, $this, $definition, $id, $defaults->getTags()); - return null !== $class ? $configurator->class($class) : $configurator; - } - /** - * Creates an alias. - * - * @param string $id - * @param string $referencedId - * - * @return AliasConfigurator - */ - public final function alias($id, $referencedId) - { - $ref = static::processValue($referencedId, \true); - $alias = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias((string) $ref, $this->defaults->isPublic()); - $this->container->setAlias($id, $alias); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AliasConfigurator($this, $alias); - } - /** - * Registers a PSR-4 namespace using a glob pattern. - * - * @param string $namespace - * @param string $resource - * - * @return PrototypeConfigurator - */ - public final function load($namespace, $resource) - { - $allowParent = !$this->defaults->getChanges() && empty($this->instanceof); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\PrototypeConfigurator($this, $this->loader, $this->defaults, $namespace, $resource, $allowParent); - } - /** - * Gets an already defined service definition. - * - * @param string $id - * - * @return ServiceConfigurator - * - * @throws ServiceNotFoundException if the service definition does not exist - */ - public final function get($id) - { - $allowParent = !$this->defaults->getChanges() && empty($this->instanceof); - $definition = $this->container->getDefinition($id); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServiceConfigurator($this->container, $definition->getInstanceofConditionals(), $allowParent, $this, $definition, $id, []); - } - /** - * Registers a service. - * - * @param string $id - * @param string|null $class - * - * @return ServiceConfigurator - */ - public final function __invoke($id, $class = null) - { - return $this->set($id, $class); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; +/** + * @author Nicolas Grekas + * + * @method InstanceofConfigurator instanceof($fqcn) + */ +class ServicesConfigurator extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AbstractConfigurator +{ + const FACTORY = 'services'; + private $defaults; + private $container; + private $loader; + private $instanceof; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader $loader, array &$instanceof) + { + $this->defaults = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $this->container = $container; + $this->loader = $loader; + $this->instanceof =& $instanceof; + $instanceof = []; + } + /** + * Defines a set of defaults for following service definitions. + * + * @return DefaultsConfigurator + */ + public final function defaults() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\DefaultsConfigurator($this, $this->defaults = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition()); + } + /** + * Defines an instanceof-conditional to be applied to following service definitions. + * + * @param string $fqcn + * + * @return InstanceofConfigurator + */ + protected final function setInstanceof($fqcn) + { + $this->instanceof[$fqcn] = $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\InstanceofConfigurator($this, $definition, $fqcn); + } + /** + * Registers a service. + * + * @param string $id + * @param string|null $class + * + * @return ServiceConfigurator + */ + public final function set($id, $class = null) + { + $defaults = $this->defaults; + $allowParent = !$defaults->getChanges() && empty($this->instanceof); + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $definition->setPublic($defaults->isPublic()); + $definition->setAutowired($defaults->isAutowired()); + $definition->setAutoconfigured($defaults->isAutoconfigured()); + $definition->setBindings($defaults->getBindings()); + $definition->setChanges([]); + $configurator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServiceConfigurator($this->container, $this->instanceof, $allowParent, $this, $definition, $id, $defaults->getTags()); + return null !== $class ? $configurator->class($class) : $configurator; + } + /** + * Creates an alias. + * + * @param string $id + * @param string $referencedId + * + * @return AliasConfigurator + */ + public final function alias($id, $referencedId) + { + $ref = static::processValue($referencedId, \true); + $alias = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias((string) $ref, $this->defaults->isPublic()); + $this->container->setAlias($id, $alias); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\AliasConfigurator($this, $alias); + } + /** + * Registers a PSR-4 namespace using a glob pattern. + * + * @param string $namespace + * @param string $resource + * + * @return PrototypeConfigurator + */ + public final function load($namespace, $resource) + { + $allowParent = !$this->defaults->getChanges() && empty($this->instanceof); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\PrototypeConfigurator($this, $this->loader, $this->defaults, $namespace, $resource, $allowParent); + } + /** + * Gets an already defined service definition. + * + * @param string $id + * + * @return ServiceConfigurator + * + * @throws ServiceNotFoundException if the service definition does not exist + */ + public final function get($id) + { + $allowParent = !$this->defaults->getChanges() && empty($this->instanceof); + $definition = $this->container->getDefinition($id); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ServiceConfigurator($this->container, $definition->getInstanceofConditionals(), $allowParent, $this, $definition, $id, []); + } + /** + * Registers a service. + * + * @param string $id + * @param string|null $class + * + * @return ServiceConfigurator + */ + public final function __invoke($id, $class = null) + { + return $this->set($id, $class); + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AbstractTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AbstractTrait.php index ae9a7f1b1..05ab35fa9 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AbstractTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AbstractTrait.php @@ -1,31 +1,31 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -/** - * @method $this abstract(bool $abstract = true) - */ -trait AbstractTrait -{ - /** - * Whether this definition is abstract, that means it merely serves as a - * template for other definitions. - * - * @param bool $abstract - * - * @return $this - */ - protected final function setAbstract($abstract = \true) - { - $this->definition->setAbstract($abstract); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +/** + * @method $this abstract(bool $abstract = true) + */ +trait AbstractTrait +{ + /** + * Whether this definition is abstract, that means it merely serves as a + * template for other definitions. + * + * @param bool $abstract + * + * @return $this + */ + protected final function setAbstract($abstract = \true) + { + $this->definition->setAbstract($abstract); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ArgumentTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ArgumentTrait.php index 9a9a2e31e..2dcfeea6a 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ArgumentTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ArgumentTrait.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -trait ArgumentTrait -{ - /** - * Sets the arguments to pass to the service constructor/factory method. - * - * @param array $arguments An array of arguments - * - * @return $this - */ - public final function args(array $arguments) - { - $this->definition->setArguments(static::processValue($arguments, \true)); - return $this; - } - /** - * Sets one argument to pass to the service constructor/factory method. - * - * @param string|int $key - * @param mixed $value - * - * @return $this - */ - public final function arg($key, $value) - { - $this->definition->setArgument($key, static::processValue($value, \true)); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +trait ArgumentTrait +{ + /** + * Sets the arguments to pass to the service constructor/factory method. + * + * @param array $arguments An array of arguments + * + * @return $this + */ + public final function args(array $arguments) + { + $this->definition->setArguments(static::processValue($arguments, \true)); + return $this; + } + /** + * Sets one argument to pass to the service constructor/factory method. + * + * @param string|int $key + * @param mixed $value + * + * @return $this + */ + public final function arg($key, $value) + { + $this->definition->setArgument($key, static::processValue($value, \true)); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AutoconfigureTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AutoconfigureTrait.php index 0053667f0..28d533b5c 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AutoconfigureTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AutoconfigureTrait.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -trait AutoconfigureTrait -{ - /** - * Sets whether or not instanceof conditionals should be prepended with a global set. - * - * @param bool $autoconfigured - * - * @return $this - * - * @throws InvalidArgumentException when a parent is already set - */ - public final function autoconfigure($autoconfigured = \true) - { - if ($autoconfigured && $this->definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot have a "parent" and also have "autoconfigure". Try disabling autoconfiguration for the service.', $this->id)); - } - $this->definition->setAutoconfigured($autoconfigured); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +trait AutoconfigureTrait +{ + /** + * Sets whether or not instanceof conditionals should be prepended with a global set. + * + * @param bool $autoconfigured + * + * @return $this + * + * @throws InvalidArgumentException when a parent is already set + */ + public final function autoconfigure($autoconfigured = \true) + { + if ($autoconfigured && $this->definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot have a "parent" and also have "autoconfigure". Try disabling autoconfiguration for the service.', $this->id)); + } + $this->definition->setAutoconfigured($autoconfigured); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AutowireTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AutowireTrait.php index 63ba3b656..9f33a0625 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AutowireTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/AutowireTrait.php @@ -1,27 +1,27 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -trait AutowireTrait -{ - /** - * Enables/disables autowiring. - * - * @param bool $autowired - * - * @return $this - */ - public final function autowire($autowired = \true) - { - $this->definition->setAutowired($autowired); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +trait AutowireTrait +{ + /** + * Enables/disables autowiring. + * + * @param bool $autowired + * + * @return $this + */ + public final function autowire($autowired = \true) + { + $this->definition->setAutowired($autowired); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/BindTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/BindTrait.php index 2c70984f6..a1ce2e288 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/BindTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/BindTrait.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -trait BindTrait -{ - /** - * Sets bindings. - * - * Bindings map $named or FQCN arguments to values that should be - * injected in the matching parameters (of the constructor, of methods - * called and of controller actions). - * - * @param string $nameOrFqcn A parameter name with its "$" prefix, or a FQCN - * @param mixed $valueOrRef The value or reference to bind - * - * @return $this - */ - public final function bind($nameOrFqcn, $valueOrRef) - { - $valueOrRef = static::processValue($valueOrRef, \true); - if (isset($nameOrFqcn[0]) && '$' !== $nameOrFqcn[0] && !$valueOrRef instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid binding for service "%s": named arguments must start with a "$", and FQCN must map to references. Neither applies to binding "%s".', $this->id, $nameOrFqcn)); - } - $bindings = $this->definition->getBindings(); - $bindings[$nameOrFqcn] = $valueOrRef; - $this->definition->setBindings($bindings); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +trait BindTrait +{ + /** + * Sets bindings. + * + * Bindings map $named or FQCN arguments to values that should be + * injected in the matching parameters (of the constructor, of methods + * called and of controller actions). + * + * @param string $nameOrFqcn A parameter name with its "$" prefix, or a FQCN + * @param mixed $valueOrRef The value or reference to bind + * + * @return $this + */ + public final function bind($nameOrFqcn, $valueOrRef) + { + $valueOrRef = static::processValue($valueOrRef, \true); + if (isset($nameOrFqcn[0]) && '$' !== $nameOrFqcn[0] && !$valueOrRef instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid binding for service "%s": named arguments must start with a "$", and FQCN must map to references. Neither applies to binding "%s".', $this->id, $nameOrFqcn)); + } + $bindings = $this->definition->getBindings(); + $bindings[$nameOrFqcn] = $valueOrRef; + $this->definition->setBindings($bindings); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/CallTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/CallTrait.php index 4c1a28883..a8d9d63ac 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/CallTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/CallTrait.php @@ -1,31 +1,31 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -trait CallTrait -{ - /** - * Adds a method to call after service initialization. - * - * @param string $method The method name to call - * @param array $arguments An array of arguments to pass to the method call - * - * @return $this - * - * @throws InvalidArgumentException on empty $method param - */ - public final function call($method, array $arguments = []) - { - $this->definition->addMethodCall($method, static::processValue($arguments, \true)); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +trait CallTrait +{ + /** + * Adds a method to call after service initialization. + * + * @param string $method The method name to call + * @param array $arguments An array of arguments to pass to the method call + * + * @return $this + * + * @throws InvalidArgumentException on empty $method param + */ + public final function call($method, array $arguments = []) + { + $this->definition->addMethodCall($method, static::processValue($arguments, \true)); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ClassTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ClassTrait.php index 24ecdc75a..28ba0dee5 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ClassTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ClassTrait.php @@ -1,30 +1,30 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -/** - * @method $this class(string $class) - */ -trait ClassTrait -{ - /** - * Sets the service class. - * - * @param string $class The service class - * - * @return $this - */ - protected final function setClass($class) - { - $this->definition->setClass($class); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +/** + * @method $this class(string $class) + */ +trait ClassTrait +{ + /** + * Sets the service class. + * + * @param string $class The service class + * + * @return $this + */ + protected final function setClass($class) + { + $this->definition->setClass($class); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ConfiguratorTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ConfiguratorTrait.php index 94b394d65..ce0c614f5 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ConfiguratorTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ConfiguratorTrait.php @@ -1,27 +1,27 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -trait ConfiguratorTrait -{ - /** - * Sets a configurator to call after the service is fully initialized. - * - * @param string|array $configurator A PHP callable reference - * - * @return $this - */ - public final function configurator($configurator) - { - $this->definition->setConfigurator(static::processValue($configurator, \true)); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +trait ConfiguratorTrait +{ + /** + * Sets a configurator to call after the service is fully initialized. + * + * @param string|array $configurator A PHP callable reference + * + * @return $this + */ + public final function configurator($configurator) + { + $this->definition->setConfigurator(static::processValue($configurator, \true)); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/DecorateTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/DecorateTrait.php index 1ef5f9d94..793dc553e 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/DecorateTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/DecorateTrait.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -trait DecorateTrait -{ - /** - * Sets the service that this service is decorating. - * - * @param string|null $id The decorated service id, use null to remove decoration - * @param string|null $renamedId The new decorated service id - * @param int $priority The priority of decoration - * - * @return $this - * - * @throws InvalidArgumentException in case the decorated service id and the new decorated service id are equals - */ - public final function decorate($id, $renamedId = null, $priority = 0) - { - $this->definition->setDecoratedService($id, $renamedId, $priority); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +trait DecorateTrait +{ + /** + * Sets the service that this service is decorating. + * + * @param string|null $id The decorated service id, use null to remove decoration + * @param string|null $renamedId The new decorated service id + * @param int $priority The priority of decoration + * + * @return $this + * + * @throws InvalidArgumentException in case the decorated service id and the new decorated service id are equals + */ + public final function decorate($id, $renamedId = null, $priority = 0) + { + $this->definition->setDecoratedService($id, $renamedId, $priority); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/DeprecateTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/DeprecateTrait.php index 68edff99b..ce274f41a 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/DeprecateTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/DeprecateTrait.php @@ -1,30 +1,30 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -trait DeprecateTrait -{ - /** - * Whether this definition is deprecated, that means it should not be called anymore. - * - * @param string $template Template message to use if the definition is deprecated - * - * @return $this - * - * @throws InvalidArgumentException when the message template is invalid - */ - public final function deprecate($template = null) - { - $this->definition->setDeprecated(\true, $template); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +trait DeprecateTrait +{ + /** + * Whether this definition is deprecated, that means it should not be called anymore. + * + * @param string $template Template message to use if the definition is deprecated + * + * @return $this + * + * @throws InvalidArgumentException when the message template is invalid + */ + public final function deprecate($template = null) + { + $this->definition->setDeprecated(\true, $template); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/FactoryTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/FactoryTrait.php index 96849577b..8bf61e4e8 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/FactoryTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/FactoryTrait.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -trait FactoryTrait -{ - /** - * Sets a factory. - * - * @param string|array $factory A PHP callable reference - * - * @return $this - */ - public final function factory($factory) - { - if (\is_string($factory) && 1 === \substr_count($factory, ':')) { - $factoryParts = \explode(':', $factory); - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid factory "%s": the `service:method` notation is not available when using PHP-based DI configuration. Use "[ref(\'%s\'), \'%s\']" instead.', $factory, $factoryParts[0], $factoryParts[1])); - } - $this->definition->setFactory(static::processValue($factory, \true)); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +trait FactoryTrait +{ + /** + * Sets a factory. + * + * @param string|array $factory A PHP callable reference + * + * @return $this + */ + public final function factory($factory) + { + if (\is_string($factory) && 1 === \substr_count($factory, ':')) { + $factoryParts = \explode(':', $factory); + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid factory "%s": the `service:method` notation is not available when using PHP-based DI configuration. Use "[ref(\'%s\'), \'%s\']" instead.', $factory, $factoryParts[0], $factoryParts[1])); + } + $this->definition->setFactory(static::processValue($factory, \true)); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/FileTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/FileTrait.php index 4bbe8aba3..eed66dad6 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/FileTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/FileTrait.php @@ -1,27 +1,27 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -trait FileTrait -{ - /** - * Sets a file to require before creating the service. - * - * @param string $file A full pathname to include - * - * @return $this - */ - public final function file($file) - { - $this->definition->setFile($file); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +trait FileTrait +{ + /** + * Sets a file to require before creating the service. + * + * @param string $file A full pathname to include + * + * @return $this + */ + public final function file($file) + { + $this->definition->setFile($file); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/LazyTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/LazyTrait.php index 8d6313df5..f9264700f 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/LazyTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/LazyTrait.php @@ -1,27 +1,27 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -trait LazyTrait -{ - /** - * Sets the lazy flag of this service. - * - * @param bool $lazy - * - * @return $this - */ - public final function lazy($lazy = \true) - { - $this->definition->setLazy($lazy); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +trait LazyTrait +{ + /** + * Sets the lazy flag of this service. + * + * @param bool $lazy + * + * @return $this + */ + public final function lazy($lazy = \true) + { + $this->definition->setLazy($lazy); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ParentTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ParentTrait.php index c40fbe173..1fd6fa740 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ParentTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ParentTrait.php @@ -1,50 +1,50 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -/** - * @method $this parent(string $parent) - */ -trait ParentTrait -{ - /** - * Sets the Definition to inherit from. - * - * @param string $parent - * - * @return $this - * - * @throws InvalidArgumentException when parent cannot be set - */ - protected final function setParent($parent) - { - if (!$this->allowParent) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A parent cannot be defined when either "_instanceof" or "_defaults" are also defined for service prototype "%s".', $this->id)); - } - if ($this->definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { - $this->definition->setParent($parent); - } elseif ($this->definition->isAutoconfigured()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot have a "parent" and also have "autoconfigure". Try disabling autoconfiguration for the service.', $this->id)); - } elseif ($this->definition->getBindings()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot have a "parent" and also "bind" arguments.', $this->id)); - } else { - // cast Definition to ChildDefinition - $definition = \serialize($this->definition); - $definition = \substr_replace($definition, '53', 2, 2); - $definition = \substr_replace($definition, 'Child', 44, 0); - $definition = \unserialize($definition); - $this->definition = $definition->setParent($parent); - } - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +/** + * @method $this parent(string $parent) + */ +trait ParentTrait +{ + /** + * Sets the Definition to inherit from. + * + * @param string $parent + * + * @return $this + * + * @throws InvalidArgumentException when parent cannot be set + */ + protected final function setParent($parent) + { + if (!$this->allowParent) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A parent cannot be defined when either "_instanceof" or "_defaults" are also defined for service prototype "%s".', $this->id)); + } + if ($this->definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { + $this->definition->setParent($parent); + } elseif ($this->definition->isAutoconfigured()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot have a "parent" and also have "autoconfigure". Try disabling autoconfiguration for the service.', $this->id)); + } elseif ($this->definition->getBindings()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot have a "parent" and also "bind" arguments.', $this->id)); + } else { + // cast Definition to ChildDefinition + $definition = \serialize($this->definition); + $definition = \substr_replace($definition, '53', 2, 2); + $definition = \substr_replace($definition, 'Child', 44, 0); + $definition = \unserialize($definition); + $this->definition = $definition->setParent($parent); + } + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/PropertyTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/PropertyTrait.php index 819ee0efa..b4c7c9125 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/PropertyTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/PropertyTrait.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -trait PropertyTrait -{ - /** - * Sets a specific property. - * - * @param string $name - * @param mixed $value - * - * @return $this - */ - public final function property($name, $value) - { - $this->definition->setProperty($name, static::processValue($value, \true)); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +trait PropertyTrait +{ + /** + * Sets a specific property. + * + * @param string $name + * @param mixed $value + * + * @return $this + */ + public final function property($name, $value) + { + $this->definition->setProperty($name, static::processValue($value, \true)); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/PublicTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/PublicTrait.php index ed312d40a..4226201ef 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/PublicTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/PublicTrait.php @@ -1,35 +1,35 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -/** - * @method $this public() - * @method $this private() - */ -trait PublicTrait -{ - /** - * @return $this - */ - protected final function setPublic() - { - $this->definition->setPublic(\true); - return $this; - } - /** - * @return $this - */ - protected final function setPrivate() - { - $this->definition->setPublic(\false); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +/** + * @method $this public() + * @method $this private() + */ +trait PublicTrait +{ + /** + * @return $this + */ + protected final function setPublic() + { + $this->definition->setPublic(\true); + return $this; + } + /** + * @return $this + */ + protected final function setPrivate() + { + $this->definition->setPublic(\false); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ShareTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ShareTrait.php index 8228ed4ac..ce7f2c142 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ShareTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/ShareTrait.php @@ -1,27 +1,27 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -trait ShareTrait -{ - /** - * Sets if the service must be shared or not. - * - * @param bool $shared Whether the service must be shared or not - * - * @return $this - */ - public final function share($shared = \true) - { - $this->definition->setShared($shared); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +trait ShareTrait +{ + /** + * Sets if the service must be shared or not. + * + * @param bool $shared Whether the service must be shared or not + * + * @return $this + */ + public final function share($shared = \true) + { + $this->definition->setShared($shared); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/SyntheticTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/SyntheticTrait.php index 64bb4bbc3..72b1e76b7 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/SyntheticTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/SyntheticTrait.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -trait SyntheticTrait -{ - /** - * Sets whether this definition is synthetic, that is not constructed by the - * container, but dynamically injected. - * - * @param bool $synthetic - * - * @return $this - */ - public final function synthetic($synthetic = \true) - { - $this->definition->setSynthetic($synthetic); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +trait SyntheticTrait +{ + /** + * Sets whether this definition is synthetic, that is not constructed by the + * container, but dynamically injected. + * + * @param bool $synthetic + * + * @return $this + */ + public final function synthetic($synthetic = \true) + { + $this->definition->setSynthetic($synthetic); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/TagTrait.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/TagTrait.php index de6d2f961..8a1f494dc 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/TagTrait.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/TagTrait.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -trait TagTrait -{ - /** - * Adds a tag for this definition. - * - * @param string $name The tag name - * @param array $attributes An array of attributes - * - * @return $this - */ - public final function tag($name, array $attributes = []) - { - if (!\is_string($name) || '' === $name) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The tag name for service "%s" must be a non-empty string.', $this->id)); - } - foreach ($attributes as $attribute => $value) { - if (!\is_scalar($value) && null !== $value) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A tag attribute must be of a scalar-type for service "%s", tag "%s", attribute "%s".', $this->id, $name, $attribute)); - } - } - $this->definition->addTag($name, $attributes); - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\Traits; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +trait TagTrait +{ + /** + * Adds a tag for this definition. + * + * @param string $name The tag name + * @param array $attributes An array of attributes + * + * @return $this + */ + public final function tag($name, array $attributes = []) + { + if (!\is_string($name) || '' === $name) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The tag name for service "%s" must be a non-empty string.', $this->id)); + } + foreach ($attributes as $attribute => $value) { + if (!\is_scalar($value) && null !== $value) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A tag attribute must be of a scalar-type for service "%s", tag "%s", attribute "%s".', $this->id, $name, $attribute)); + } + } + $this->definition->addTag($name, $attributes); + return $this; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/index.php b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/Traits/index.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/Traits/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/Configurator/index.php b/vendor/symfony/dependency-injection/Loader/Configurator/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Loader/Configurator/index.php +++ b/vendor/symfony/dependency-injection/Loader/Configurator/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/DirectoryLoader.php b/vendor/symfony/dependency-injection/Loader/DirectoryLoader.php index 987e594cd..2109843e7 100644 --- a/vendor/symfony/dependency-injection/Loader/DirectoryLoader.php +++ b/vendor/symfony/dependency-injection/Loader/DirectoryLoader.php @@ -1,49 +1,49 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; - -/** - * DirectoryLoader is a recursive loader to go through directories. - * - * @author Sebastien Lavoie - */ -class DirectoryLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader -{ - /** - * {@inheritdoc} - */ - public function load($file, $type = null) - { - $file = \rtrim($file, '/'); - $path = $this->locator->locate($file); - $this->container->fileExists($path, \false); - foreach (\scandir($path) as $dir) { - if ('.' !== $dir[0]) { - if (\is_dir($path . '/' . $dir)) { - $dir .= '/'; - // append / to allow recursion - } - $this->setCurrentDir($path); - $this->import($dir, null, \false, $path); - } - } - } - /** - * {@inheritdoc} - */ - public function supports($resource, $type = null) - { - if ('directory' === $type) { - return \true; - } - return null === $type && \is_string($resource) && '/' === \substr($resource, -1); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; + +/** + * DirectoryLoader is a recursive loader to go through directories. + * + * @author Sebastien Lavoie + */ +class DirectoryLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader +{ + /** + * {@inheritdoc} + */ + public function load($file, $type = null) + { + $file = \rtrim($file, '/'); + $path = $this->locator->locate($file); + $this->container->fileExists($path, \false); + foreach (\scandir($path) as $dir) { + if ('.' !== $dir[0]) { + if (\is_dir($path . '/' . $dir)) { + $dir .= '/'; + // append / to allow recursion + } + $this->setCurrentDir($path); + $this->import($dir, null, \false, $path); + } + } + } + /** + * {@inheritdoc} + */ + public function supports($resource, $type = null) + { + if ('directory' === $type) { + return \true; + } + return null === $type && \is_string($resource) && '/' === \substr($resource, -1); + } +} diff --git a/vendor/symfony/dependency-injection/Loader/FileLoader.php b/vendor/symfony/dependency-injection/Loader/FileLoader.php index 99d3080ce..666ec46e7 100644 --- a/vendor/symfony/dependency-injection/Loader/FileLoader.php +++ b/vendor/symfony/dependency-injection/Loader/FileLoader.php @@ -1,153 +1,153 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocatorInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\FileLoader as BaseFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -/** - * FileLoader is the abstract class used by all built-in loaders that are file based. - * - * @author Fabien Potencier - */ -abstract class FileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\FileLoader -{ - protected $container; - protected $isLoadingInstanceof = \false; - protected $instanceof = []; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocatorInterface $locator) - { - $this->container = $container; - parent::__construct($locator); - } - /** - * Registers a set of classes as services using PSR-4 for discovery. - * - * @param Definition $prototype A definition to use as template - * @param string $namespace The namespace prefix of classes in the scanned directory - * @param string $resource The directory to look for classes, glob-patterns allowed - * @param string $exclude A globed path of files to exclude - */ - public function registerClasses(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $prototype, $namespace, $resource, $exclude = null) - { - if ('\\' !== \substr($namespace, -1)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Namespace prefix must end with a "\\": "%s".', $namespace)); - } - if (!\preg_match('/^(?:[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+\\\\)++$/', $namespace)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Namespace is not a valid PSR-4 prefix: "%s".', $namespace)); - } - $classes = $this->findClasses($namespace, $resource, $exclude); - // prepare for deep cloning - $serializedPrototype = \serialize($prototype); - $interfaces = []; - $singlyImplemented = []; - foreach ($classes as $class => $errorMessage) { - if (\interface_exists($class, \false)) { - $interfaces[] = $class; - } else { - $this->setDefinition($class, $definition = \unserialize($serializedPrototype)); - if (null !== $errorMessage) { - $definition->addError($errorMessage); - continue; - } - foreach (\class_implements($class, \false) as $interface) { - $singlyImplemented[$interface] = isset($singlyImplemented[$interface]) ? \false : $class; - } - } - } - foreach ($interfaces as $interface) { - if (!empty($singlyImplemented[$interface])) { - $this->container->setAlias($interface, $singlyImplemented[$interface])->setPublic(\false); - } - } - } - /** - * Registers a definition in the container with its instanceof-conditionals. - * - * @param string $id - */ - protected function setDefinition($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - $this->container->removeBindings($id); - if ($this->isLoadingInstanceof) { - if (!$definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid type definition "%s": ChildDefinition expected, "%s" given.', $id, \get_class($definition))); - } - $this->instanceof[$id] = $definition; - } else { - $this->container->setDefinition($id, $definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition ? $definition : $definition->setInstanceofConditionals($this->instanceof)); - } - } - private function findClasses($namespace, $pattern, $excludePattern) - { - $parameterBag = $this->container->getParameterBag(); - $excludePaths = []; - $excludePrefix = null; - if ($excludePattern) { - $excludePattern = $parameterBag->unescapeValue($parameterBag->resolveValue($excludePattern)); - foreach ($this->glob($excludePattern, \true, $resource, \true) as $path => $info) { - if (null === $excludePrefix) { - $excludePrefix = $resource->getPrefix(); - } - // normalize Windows slashes - $excludePaths[\str_replace('\\', '/', $path)] = \true; - } - } - $pattern = $parameterBag->unescapeValue($parameterBag->resolveValue($pattern)); - $classes = []; - $extRegexp = \defined('HHVM_VERSION') ? '/\\.(?:php|hh)$/' : '/\\.php$/'; - $prefixLen = null; - foreach ($this->glob($pattern, \true, $resource) as $path => $info) { - if (null === $prefixLen) { - $prefixLen = \strlen($resource->getPrefix()); - if ($excludePrefix && 0 !== \strpos($excludePrefix, $resource->getPrefix())) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid "exclude" pattern when importing classes for "%s": make sure your "exclude" pattern (%s) is a subset of the "resource" pattern (%s).', $namespace, $excludePattern, $pattern)); - } - } - if (isset($excludePaths[\str_replace('\\', '/', $path)])) { - continue; - } - if (!\preg_match($extRegexp, $path, $m) || !$info->isReadable()) { - continue; - } - $class = $namespace . \ltrim(\str_replace('/', '\\', \substr($path, $prefixLen, -\strlen($m[0]))), '\\'); - if (!\preg_match('/^[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+(?:\\\\[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+)*+$/', $class)) { - continue; - } - try { - $r = $this->container->getReflectionClass($class); - } catch (\ReflectionException $e) { - $classes[$class] = $e->getMessage(); - continue; - } - // check to make sure the expected class exists - if (!$r) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Expected to find class "%s" in file "%s" while importing services from resource "%s", but it was not found! Check the namespace prefix used with the resource.', $class, $path, $pattern)); - } - if ($r->isInstantiable() || $r->isInterface()) { - $classes[$class] = null; - } - } - // track only for new & removed files - if ($resource instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource) { - $this->container->addResource($resource); - } else { - foreach ($resource as $path) { - $this->container->fileExists($path, \false); - } - } - return $classes; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocatorInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\FileLoader as BaseFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +/** + * FileLoader is the abstract class used by all built-in loaders that are file based. + * + * @author Fabien Potencier + */ +abstract class FileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\FileLoader +{ + protected $container; + protected $isLoadingInstanceof = \false; + protected $instanceof = []; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocatorInterface $locator) + { + $this->container = $container; + parent::__construct($locator); + } + /** + * Registers a set of classes as services using PSR-4 for discovery. + * + * @param Definition $prototype A definition to use as template + * @param string $namespace The namespace prefix of classes in the scanned directory + * @param string $resource The directory to look for classes, glob-patterns allowed + * @param string $exclude A globed path of files to exclude + */ + public function registerClasses(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $prototype, $namespace, $resource, $exclude = null) + { + if ('\\' !== \substr($namespace, -1)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Namespace prefix must end with a "\\": "%s".', $namespace)); + } + if (!\preg_match('/^(?:[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+\\\\)++$/', $namespace)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Namespace is not a valid PSR-4 prefix: "%s".', $namespace)); + } + $classes = $this->findClasses($namespace, $resource, $exclude); + // prepare for deep cloning + $serializedPrototype = \serialize($prototype); + $interfaces = []; + $singlyImplemented = []; + foreach ($classes as $class => $errorMessage) { + if (\interface_exists($class, \false)) { + $interfaces[] = $class; + } else { + $this->setDefinition($class, $definition = \unserialize($serializedPrototype)); + if (null !== $errorMessage) { + $definition->addError($errorMessage); + continue; + } + foreach (\class_implements($class, \false) as $interface) { + $singlyImplemented[$interface] = isset($singlyImplemented[$interface]) ? \false : $class; + } + } + } + foreach ($interfaces as $interface) { + if (!empty($singlyImplemented[$interface])) { + $this->container->setAlias($interface, $singlyImplemented[$interface])->setPublic(\false); + } + } + } + /** + * Registers a definition in the container with its instanceof-conditionals. + * + * @param string $id + */ + protected function setDefinition($id, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + $this->container->removeBindings($id); + if ($this->isLoadingInstanceof) { + if (!$definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid type definition "%s": ChildDefinition expected, "%s" given.', $id, \get_class($definition))); + } + $this->instanceof[$id] = $definition; + } else { + $this->container->setDefinition($id, $definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition ? $definition : $definition->setInstanceofConditionals($this->instanceof)); + } + } + private function findClasses($namespace, $pattern, $excludePattern) + { + $parameterBag = $this->container->getParameterBag(); + $excludePaths = []; + $excludePrefix = null; + if ($excludePattern) { + $excludePattern = $parameterBag->unescapeValue($parameterBag->resolveValue($excludePattern)); + foreach ($this->glob($excludePattern, \true, $resource, \true) as $path => $info) { + if (null === $excludePrefix) { + $excludePrefix = $resource->getPrefix(); + } + // normalize Windows slashes + $excludePaths[\str_replace('\\', '/', $path)] = \true; + } + } + $pattern = $parameterBag->unescapeValue($parameterBag->resolveValue($pattern)); + $classes = []; + $extRegexp = \defined('HHVM_VERSION') ? '/\\.(?:php|hh)$/' : '/\\.php$/'; + $prefixLen = null; + foreach ($this->glob($pattern, \true, $resource) as $path => $info) { + if (null === $prefixLen) { + $prefixLen = \strlen($resource->getPrefix()); + if ($excludePrefix && 0 !== \strpos($excludePrefix, $resource->getPrefix())) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid "exclude" pattern when importing classes for "%s": make sure your "exclude" pattern (%s) is a subset of the "resource" pattern (%s).', $namespace, $excludePattern, $pattern)); + } + } + if (isset($excludePaths[\str_replace('\\', '/', $path)])) { + continue; + } + if (!\preg_match($extRegexp, $path, $m) || !$info->isReadable()) { + continue; + } + $class = $namespace . \ltrim(\str_replace('/', '\\', \substr($path, $prefixLen, -\strlen($m[0]))), '\\'); + if (!\preg_match('/^[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+(?:\\\\[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*+)*+$/', $class)) { + continue; + } + try { + $r = $this->container->getReflectionClass($class); + } catch (\ReflectionException $e) { + $classes[$class] = $e->getMessage(); + continue; + } + // check to make sure the expected class exists + if (!$r) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Expected to find class "%s" in file "%s" while importing services from resource "%s", but it was not found! Check the namespace prefix used with the resource.', $class, $path, $pattern)); + } + if ($r->isInstantiable() || $r->isInterface()) { + $classes[$class] = null; + } + } + // track only for new & removed files + if ($resource instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource) { + $this->container->addResource($resource); + } else { + foreach ($resource as $path) { + $this->container->fileExists($path, \false); + } + } + return $classes; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/GlobFileLoader.php b/vendor/symfony/dependency-injection/Loader/GlobFileLoader.php index 519f519fb..5da5994bf 100644 --- a/vendor/symfony/dependency-injection/Loader/GlobFileLoader.php +++ b/vendor/symfony/dependency-injection/Loader/GlobFileLoader.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; - -/** - * GlobFileLoader loads files from a glob pattern. - * - * @author Nicolas Grekas - */ -class GlobFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader -{ - /** - * {@inheritdoc} - */ - public function load($resource, $type = null) - { - foreach ($this->glob($resource, \false, $globResource) as $path => $info) { - $this->import($path); - } - $this->container->addResource($globResource); - } - /** - * {@inheritdoc} - */ - public function supports($resource, $type = null) - { - return 'glob' === $type; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; + +/** + * GlobFileLoader loads files from a glob pattern. + * + * @author Nicolas Grekas + */ +class GlobFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader +{ + /** + * {@inheritdoc} + */ + public function load($resource, $type = null) + { + foreach ($this->glob($resource, \false, $globResource) as $path => $info) { + $this->import($path); + } + $this->container->addResource($globResource); + } + /** + * {@inheritdoc} + */ + public function supports($resource, $type = null) + { + return 'glob' === $type; + } +} diff --git a/vendor/symfony/dependency-injection/Loader/IniFileLoader.php b/vendor/symfony/dependency-injection/Loader/IniFileLoader.php index 9f9b4d7ed..d1b9ab120 100644 --- a/vendor/symfony/dependency-injection/Loader/IniFileLoader.php +++ b/vendor/symfony/dependency-injection/Loader/IniFileLoader.php @@ -1,81 +1,81 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -/** - * IniFileLoader loads parameters from INI files. - * - * @author Fabien Potencier - */ -class IniFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader -{ - /** - * {@inheritdoc} - */ - public function load($resource, $type = null) - { - $path = $this->locator->locate($resource); - $this->container->fileExists($path); - // first pass to catch parsing errors - $result = \parse_ini_file($path, \true); - if (\false === $result || [] === $result) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The "%s" file is not valid.', $resource)); - } - // real raw parsing - $result = \parse_ini_file($path, \true, \INI_SCANNER_RAW); - if (isset($result['parameters']) && \is_array($result['parameters'])) { - foreach ($result['parameters'] as $key => $value) { - $this->container->setParameter($key, $this->phpize($value)); - } - } - } - /** - * {@inheritdoc} - */ - public function supports($resource, $type = null) - { - if (!\is_string($resource)) { - return \false; - } - if (null === $type && 'ini' === \pathinfo($resource, \PATHINFO_EXTENSION)) { - return \true; - } - return 'ini' === $type; - } - /** - * Note that the following features are not supported: - * * strings with escaped quotes are not supported "foo\"bar"; - * * string concatenation ("foo" "bar"). - */ - private function phpize($value) - { - // trim on the right as comments removal keep whitespaces - if ($value !== ($v = \rtrim($value))) { - $value = '""' === \substr_replace($v, '', 1, -1) ? \substr($v, 1, -1) : $v; - } - $lowercaseValue = \strtolower($value); - switch (\true) { - case \defined($value): - return \constant($value); - case 'yes' === $lowercaseValue || 'on' === $lowercaseValue: - return \true; - case 'no' === $lowercaseValue || 'off' === $lowercaseValue || 'none' === $lowercaseValue: - return \false; - case isset($value[1]) && ("'" === $value[0] && "'" === $value[\strlen($value) - 1] || '"' === $value[0] && '"' === $value[\strlen($value) - 1]): - // quoted string - return \substr($value, 1, -1); - default: - return \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +/** + * IniFileLoader loads parameters from INI files. + * + * @author Fabien Potencier + */ +class IniFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader +{ + /** + * {@inheritdoc} + */ + public function load($resource, $type = null) + { + $path = $this->locator->locate($resource); + $this->container->fileExists($path); + // first pass to catch parsing errors + $result = \parse_ini_file($path, \true); + if (\false === $result || [] === $result) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The "%s" file is not valid.', $resource)); + } + // real raw parsing + $result = \parse_ini_file($path, \true, \INI_SCANNER_RAW); + if (isset($result['parameters']) && \is_array($result['parameters'])) { + foreach ($result['parameters'] as $key => $value) { + $this->container->setParameter($key, $this->phpize($value)); + } + } + } + /** + * {@inheritdoc} + */ + public function supports($resource, $type = null) + { + if (!\is_string($resource)) { + return \false; + } + if (null === $type && 'ini' === \pathinfo($resource, \PATHINFO_EXTENSION)) { + return \true; + } + return 'ini' === $type; + } + /** + * Note that the following features are not supported: + * * strings with escaped quotes are not supported "foo\"bar"; + * * string concatenation ("foo" "bar"). + */ + private function phpize($value) + { + // trim on the right as comments removal keep whitespaces + if ($value !== ($v = \rtrim($value))) { + $value = '""' === \substr_replace($v, '', 1, -1) ? \substr($v, 1, -1) : $v; + } + $lowercaseValue = \strtolower($value); + switch (\true) { + case \defined($value): + return \constant($value); + case 'yes' === $lowercaseValue || 'on' === $lowercaseValue: + return \true; + case 'no' === $lowercaseValue || 'off' === $lowercaseValue || 'none' === $lowercaseValue: + return \false; + case isset($value[1]) && ("'" === $value[0] && "'" === $value[\strlen($value) - 1] || '"' === $value[0] && '"' === $value[\strlen($value) - 1]): + // quoted string + return \substr($value, 1, -1); + default: + return \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value); + } + } +} diff --git a/vendor/symfony/dependency-injection/Loader/PhpFileLoader.php b/vendor/symfony/dependency-injection/Loader/PhpFileLoader.php index d5ae7fb3a..1408b5987 100644 --- a/vendor/symfony/dependency-injection/Loader/PhpFileLoader.php +++ b/vendor/symfony/dependency-injection/Loader/PhpFileLoader.php @@ -1,63 +1,63 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator; -/** - * PhpFileLoader loads service definitions from a PHP file. - * - * The PHP file is required and the $container variable can be - * used within the file to change the container. - * - * @author Fabien Potencier - */ -class PhpFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader -{ - /** - * {@inheritdoc} - */ - public function load($resource, $type = null) - { - // the container and loader variables are exposed to the included file below - $container = $this->container; - $loader = $this; - $path = $this->locator->locate($resource); - $this->setCurrentDir(\dirname($path)); - $this->container->fileExists($path); - // the closure forbids access to the private scope in the included file - $load = \Closure::bind(function ($path) use($container, $loader, $resource, $type) { - return include $path; - }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ProtectedPhpFileLoader::class); - $callback = $load($path); - if ($callback instanceof \Closure) { - $callback(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator($this->container, $this, $this->instanceof, $path, $resource), $this->container, $this); - } - } - /** - * {@inheritdoc} - */ - public function supports($resource, $type = null) - { - if (!\is_string($resource)) { - return \false; - } - if (null === $type && 'php' === \pathinfo($resource, \PATHINFO_EXTENSION)) { - return \true; - } - return 'php' === $type; - } -} -/** - * @internal - */ -final class ProtectedPhpFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator; +/** + * PhpFileLoader loads service definitions from a PHP file. + * + * The PHP file is required and the $container variable can be + * used within the file to change the container. + * + * @author Fabien Potencier + */ +class PhpFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader +{ + /** + * {@inheritdoc} + */ + public function load($resource, $type = null) + { + // the container and loader variables are exposed to the included file below + $container = $this->container; + $loader = $this; + $path = $this->locator->locate($resource); + $this->setCurrentDir(\dirname($path)); + $this->container->fileExists($path); + // the closure forbids access to the private scope in the included file + $load = \Closure::bind(function ($path) use($container, $loader, $resource, $type) { + return include $path; + }, $this, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ProtectedPhpFileLoader::class); + $callback = $load($path); + if ($callback instanceof \Closure) { + $callback(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator($this->container, $this, $this->instanceof, $path, $resource), $this->container, $this); + } + } + /** + * {@inheritdoc} + */ + public function supports($resource, $type = null) + { + if (!\is_string($resource)) { + return \false; + } + if (null === $type && 'php' === \pathinfo($resource, \PATHINFO_EXTENSION)) { + return \true; + } + return 'php' === $type; + } +} +/** + * @internal + */ +final class ProtectedPhpFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader +{ +} diff --git a/vendor/symfony/dependency-injection/Loader/XmlFileLoader.php b/vendor/symfony/dependency-injection/Loader/XmlFileLoader.php index c0d4b2cec..52e63b18b 100644 --- a/vendor/symfony/dependency-injection/Loader/XmlFileLoader.php +++ b/vendor/symfony/dependency-injection/Loader/XmlFileLoader.php @@ -1,621 +1,621 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -/** - * XmlFileLoader loads XML files service definitions. - * - * @author Fabien Potencier - */ -class XmlFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader -{ - const NS = 'http://symfony.com/schema/dic/services'; - /** - * {@inheritdoc} - */ - public function load($resource, $type = null) - { - $path = $this->locator->locate($resource); - $xml = $this->parseFileToDOM($path); - $this->container->fileExists($path); - $defaults = $this->getServiceDefaults($xml, $path); - // anonymous services - $this->processAnonymousServices($xml, $path, $defaults); - // imports - $this->parseImports($xml, $path); - // parameters - $this->parseParameters($xml, $path); - // extensions - $this->loadFromExtensions($xml); - // services - try { - $this->parseDefinitions($xml, $path, $defaults); - } finally { - $this->instanceof = []; - } - } - /** - * {@inheritdoc} - */ - public function supports($resource, $type = null) - { - if (!\is_string($resource)) { - return \false; - } - if (null === $type && 'xml' === \pathinfo($resource, \PATHINFO_EXTENSION)) { - return \true; - } - return 'xml' === $type; - } - /** - * Parses parameters. - * - * @param string $file - */ - private function parseParameters(\DOMDocument $xml, $file) - { - if ($parameters = $this->getChildren($xml->documentElement, 'parameters')) { - $this->container->getParameterBag()->add($this->getArgumentsAsPhp($parameters[0], 'parameter', $file)); - } - } - /** - * Parses imports. - * - * @param string $file - */ - private function parseImports(\DOMDocument $xml, $file) - { - $xpath = new \DOMXPath($xml); - $xpath->registerNamespace('container', self::NS); - if (\false === ($imports = $xpath->query('//container:imports/container:import'))) { - return; - } - $defaultDirectory = \dirname($file); - foreach ($imports as $import) { - $this->setCurrentDir($defaultDirectory); - $this->import($import->getAttribute('resource'), \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($import->getAttribute('type')) ?: null, (bool) \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($import->getAttribute('ignore-errors')), $file); - } - } - /** - * Parses multiple definitions. - * - * @param string $file - */ - private function parseDefinitions(\DOMDocument $xml, $file, $defaults) - { - $xpath = new \DOMXPath($xml); - $xpath->registerNamespace('container', self::NS); - if (\false === ($services = $xpath->query('//container:services/container:service|//container:services/container:prototype'))) { - return; - } - $this->setCurrentDir(\dirname($file)); - $this->instanceof = []; - $this->isLoadingInstanceof = \true; - $instanceof = $xpath->query('//container:services/container:instanceof'); - foreach ($instanceof as $service) { - $this->setDefinition((string) $service->getAttribute('id'), $this->parseDefinition($service, $file, [])); - } - $this->isLoadingInstanceof = \false; - foreach ($services as $service) { - if (null !== ($definition = $this->parseDefinition($service, $file, $defaults))) { - if ('prototype' === $service->tagName) { - $this->registerClasses($definition, (string) $service->getAttribute('namespace'), (string) $service->getAttribute('resource'), (string) $service->getAttribute('exclude')); - } else { - $this->setDefinition((string) $service->getAttribute('id'), $definition); - } - } - } - } - /** - * Get service defaults. - * - * @return array - */ - private function getServiceDefaults(\DOMDocument $xml, $file) - { - $xpath = new \DOMXPath($xml); - $xpath->registerNamespace('container', self::NS); - if (null === ($defaultsNode = $xpath->query('//container:services/container:defaults')->item(0))) { - return []; - } - $defaults = ['tags' => $this->getChildren($defaultsNode, 'tag'), 'bind' => \array_map(function ($v) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument($v); - }, $this->getArgumentsAsPhp($defaultsNode, 'bind', $file))]; - foreach ($defaults['tags'] as $tag) { - if ('' === $tag->getAttribute('name')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The tag name for tag "" in "%s" must be a non-empty string.', $file)); - } - } - if ($defaultsNode->hasAttribute('autowire')) { - $defaults['autowire'] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($defaultsNode->getAttribute('autowire')); - } - if ($defaultsNode->hasAttribute('public')) { - $defaults['public'] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($defaultsNode->getAttribute('public')); - } - if ($defaultsNode->hasAttribute('autoconfigure')) { - $defaults['autoconfigure'] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($defaultsNode->getAttribute('autoconfigure')); - } - return $defaults; - } - /** - * Parses an individual Definition. - * - * @param string $file - * - * @return Definition|null - */ - private function parseDefinition(\DOMElement $service, $file, array $defaults) - { - if ($alias = $service->getAttribute('alias')) { - $this->validateAlias($service, $file); - $this->container->setAlias((string) $service->getAttribute('id'), $alias = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($alias)); - if ($publicAttr = $service->getAttribute('public')) { - $alias->setPublic(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($publicAttr)); - } elseif (isset($defaults['public'])) { - $alias->setPublic($defaults['public']); - } - return null; - } - if ($this->isLoadingInstanceof) { - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''); - } elseif ($parent = $service->getAttribute('parent')) { - if (!empty($this->instanceof)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot use the "parent" option in the same file where "instanceof" configuration is defined as using both is not supported. Move your child definitions to a separate file.', $service->getAttribute('id'))); - } - foreach ($defaults as $k => $v) { - if ('tags' === $k) { - // since tags are never inherited from parents, there is no confusion - // thus we can safely add them as defaults to ChildDefinition - continue; - } - if ('bind' === $k) { - if ($defaults['bind']) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Bound values on service "%s" cannot be inherited from "defaults" when a "parent" is set. Move your child definitions to a separate file.', $service->getAttribute('id'))); - } - continue; - } - if (!$service->hasAttribute($k)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Attribute "%s" on service "%s" cannot be inherited from "defaults" when a "parent" is set. Move your child definitions to a separate file or define this attribute explicitly.', $k, $service->getAttribute('id'))); - } - } - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition($parent); - } else { - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - if (isset($defaults['public'])) { - $definition->setPublic($defaults['public']); - } - if (isset($defaults['autowire'])) { - $definition->setAutowired($defaults['autowire']); - } - if (isset($defaults['autoconfigure'])) { - $definition->setAutoconfigured($defaults['autoconfigure']); - } - $definition->setChanges([]); - } - foreach (['class', 'public', 'shared', 'synthetic', 'lazy', 'abstract'] as $key) { - if ($value = $service->getAttribute($key)) { - $method = 'set' . $key; - $definition->{$method}(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value)); - } - } - if ($value = $service->getAttribute('autowire')) { - $definition->setAutowired(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value)); - } - if ($value = $service->getAttribute('autoconfigure')) { - if (!$definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { - $definition->setAutoconfigured(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value)); - } elseif ($value = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot have a "parent" and also have "autoconfigure". Try setting autoconfigure="false" for the service.', $service->getAttribute('id'))); - } - } - if ($files = $this->getChildren($service, 'file')) { - $definition->setFile($files[0]->nodeValue); - } - if ($deprecated = $this->getChildren($service, 'deprecated')) { - $definition->setDeprecated(\true, $deprecated[0]->nodeValue ?: null); - } - $definition->setArguments($this->getArgumentsAsPhp($service, 'argument', $file, $definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition)); - $definition->setProperties($this->getArgumentsAsPhp($service, 'property', $file)); - if ($factories = $this->getChildren($service, 'factory')) { - $factory = $factories[0]; - if ($function = $factory->getAttribute('function')) { - $definition->setFactory($function); - } else { - if ($childService = $factory->getAttribute('service')) { - $class = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($childService, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE); - } else { - $class = $factory->hasAttribute('class') ? $factory->getAttribute('class') : null; - } - $definition->setFactory([$class, $factory->getAttribute('method')]); - } - } - if ($configurators = $this->getChildren($service, 'configurator')) { - $configurator = $configurators[0]; - if ($function = $configurator->getAttribute('function')) { - $definition->setConfigurator($function); - } else { - if ($childService = $configurator->getAttribute('service')) { - $class = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($childService, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE); - } else { - $class = $configurator->getAttribute('class'); - } - $definition->setConfigurator([$class, $configurator->getAttribute('method')]); - } - } - foreach ($this->getChildren($service, 'call') as $call) { - $definition->addMethodCall($call->getAttribute('method'), $this->getArgumentsAsPhp($call, 'argument', $file)); - } - $tags = $this->getChildren($service, 'tag'); - if (!empty($defaults['tags'])) { - $tags = \array_merge($tags, $defaults['tags']); - } - foreach ($tags as $tag) { - $parameters = []; - foreach ($tag->attributes as $name => $node) { - if ('name' === $name) { - continue; - } - if (\false !== \strpos($name, '-') && \false === \strpos($name, '_') && !\array_key_exists($normalizedName = \str_replace('-', '_', $name), $parameters)) { - $parameters[$normalizedName] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($node->nodeValue); - } - // keep not normalized key - $parameters[$name] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($node->nodeValue); - } - if ('' === $tag->getAttribute('name')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The tag name for service "%s" in "%s" must be a non-empty string.', (string) $service->getAttribute('id'), $file)); - } - $definition->addTag($tag->getAttribute('name'), $parameters); - } - foreach ($this->getChildren($service, 'autowiring-type') as $type) { - $definition->addAutowiringType($type->textContent); - } - $bindings = $this->getArgumentsAsPhp($service, 'bind', $file); - if (isset($defaults['bind'])) { - // deep clone, to avoid multiple process of the same instance in the passes - $bindings = \array_merge(\unserialize(\serialize($defaults['bind'])), $bindings); - } - if ($bindings) { - $definition->setBindings($bindings); - } - if ($value = $service->getAttribute('decorates')) { - $renameId = $service->hasAttribute('decoration-inner-name') ? $service->getAttribute('decoration-inner-name') : null; - $priority = $service->hasAttribute('decoration-priority') ? $service->getAttribute('decoration-priority') : 0; - $definition->setDecoratedService($value, $renameId, $priority); - } - return $definition; - } - /** - * Parses a XML file to a \DOMDocument. - * - * @param string $file Path to a file - * - * @return \DOMDocument - * - * @throws InvalidArgumentException When loading of XML file returns error - */ - private function parseFileToDOM($file) - { - try { - $dom = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($file, [$this, 'validateSchema']); - } catch (\InvalidArgumentException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Unable to parse file "%s": "%s".', $file, $e->getMessage()), $e->getCode(), $e); - } - $this->validateExtensions($dom, $file); - return $dom; - } - /** - * Processes anonymous services. - * - * @param string $file - * @param array $defaults - */ - private function processAnonymousServices(\DOMDocument $xml, $file, $defaults) - { - $definitions = []; - $count = 0; - $suffix = '~' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::hash($file); - $xpath = new \DOMXPath($xml); - $xpath->registerNamespace('container', self::NS); - // anonymous services as arguments/properties - if (\false !== ($nodes = $xpath->query('//container:argument[@type="service"][not(@id)]|//container:property[@type="service"][not(@id)]|//container:bind[not(@id)]|//container:factory[not(@service)]|//container:configurator[not(@service)]'))) { - foreach ($nodes as $node) { - if ($services = $this->getChildren($node, 'service')) { - // give it a unique name - $id = \sprintf('%d_%s', ++$count, \preg_replace('/^.*\\\\/', '', $services[0]->getAttribute('class')) . $suffix); - $node->setAttribute('id', $id); - $node->setAttribute('service', $id); - $definitions[$id] = [$services[0], $file, \false]; - $services[0]->setAttribute('id', $id); - // anonymous services are always private - // we could not use the constant false here, because of XML parsing - $services[0]->setAttribute('public', 'false'); - } - } - } - // anonymous services "in the wild" - if (\false !== ($nodes = $xpath->query('//container:services/container:service[not(@id)]'))) { - foreach ($nodes as $node) { - @\trigger_error(\sprintf('Top-level anonymous services are deprecated since Symfony 3.4, the "id" attribute will be required in version 4.0 in %s at line %d.', $file, $node->getLineNo()), \E_USER_DEPRECATED); - // give it a unique name - $id = \sprintf('%d_%s', ++$count, \preg_replace('/^.*\\\\/', '', $node->getAttribute('class')) . $suffix); - $node->setAttribute('id', $id); - $definitions[$id] = [$node, $file, \true]; - } - } - // resolve definitions - \uksort($definitions, 'strnatcmp'); - foreach (\array_reverse($definitions) as $id => list($domElement, $file, $wild)) { - if (null !== ($definition = $this->parseDefinition($domElement, $file, $wild ? $defaults : []))) { - $this->setDefinition($id, $definition); - } - if (\true === $wild) { - $tmpDomElement = new \DOMElement('_services', null, self::NS); - $domElement->parentNode->replaceChild($tmpDomElement, $domElement); - $tmpDomElement->setAttribute('id', $id); - } - } - } - /** - * Returns arguments as valid php types. - * - * @param string $name - * @param string $file - * - * @return mixed - */ - private function getArgumentsAsPhp(\DOMElement $node, $name, $file, $isChildDefinition = \false) - { - $arguments = []; - foreach ($this->getChildren($node, $name) as $arg) { - if ($arg->hasAttribute('name')) { - $arg->setAttribute('key', $arg->getAttribute('name')); - } - // this is used by ChildDefinition to overwrite a specific - // argument of the parent definition - if ($arg->hasAttribute('index')) { - $key = ($isChildDefinition ? 'index_' : '') . $arg->getAttribute('index'); - } elseif (!$arg->hasAttribute('key')) { - // Append an empty argument, then fetch its key to overwrite it later - $arguments[] = null; - $keys = \array_keys($arguments); - $key = \array_pop($keys); - } else { - $key = $arg->getAttribute('key'); - } - $onInvalid = $arg->getAttribute('on-invalid'); - $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE; - if ('ignore' == $onInvalid) { - $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE; - } elseif ('ignore_uninitialized' == $onInvalid) { - $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE; - } elseif ('null' == $onInvalid) { - $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE; - } - switch ($arg->getAttribute('type')) { - case 'service': - if ('' === $arg->getAttribute('id')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Tag "<%s>" with type="service" has no or empty "id" attribute in "%s".', $name, $file)); - } - if ($arg->hasAttribute('strict')) { - @\trigger_error(\sprintf('The "strict" attribute used when referencing the "%s" service is deprecated since Symfony 3.3 and will be removed in 4.0.', $arg->getAttribute('id')), \E_USER_DEPRECATED); - } - $arguments[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($arg->getAttribute('id'), $invalidBehavior); - break; - case 'expression': - if (!\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression::class)) { - throw new \LogicException(\sprintf('The type="expression" attribute cannot be used without the ExpressionLanguage component. Try running "composer require symfony/expression-language".')); - } - $arguments[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression($arg->nodeValue); - break; - case 'collection': - $arguments[$key] = $this->getArgumentsAsPhp($arg, $name, $file); - break; - case 'iterator': - $arg = $this->getArgumentsAsPhp($arg, $name, $file); - try { - $arguments[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument($arg); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Tag "<%s>" with type="iterator" only accepts collections of type="service" references in "%s".', $name, $file)); - } - break; - case 'tagged': - if (!$arg->getAttribute('tag')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Tag "<%s>" with type="tagged" has no or empty "tag" attribute in "%s".', $name, $file)); - } - $arguments[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument($arg->getAttribute('tag')); - break; - case 'string': - $arguments[$key] = $arg->nodeValue; - break; - case 'constant': - $arguments[$key] = \constant(\trim($arg->nodeValue)); - break; - default: - $arguments[$key] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($arg->nodeValue); - } - } - return $arguments; - } - /** - * Get child elements by name. - * - * @param mixed $name - * - * @return \DOMElement[] - */ - private function getChildren(\DOMNode $node, $name) - { - $children = []; - foreach ($node->childNodes as $child) { - if ($child instanceof \DOMElement && $child->localName === $name && self::NS === $child->namespaceURI) { - $children[] = $child; - } - } - return $children; - } - /** - * Validates a documents XML schema. - * - * @return bool - * - * @throws RuntimeException When extension references a non-existent XSD file - */ - public function validateSchema(\DOMDocument $dom) - { - $schemaLocations = ['http://symfony.com/schema/dic/services' => \str_replace('\\', '/', __DIR__ . '/schema/dic/services/services-1.0.xsd')]; - if ($element = $dom->documentElement->getAttributeNS('http://www.w3.org/2001/XMLSchema-instance', 'schemaLocation')) { - $items = \preg_split('/\\s+/', $element); - for ($i = 0, $nb = \count($items); $i < $nb; $i += 2) { - if (!$this->container->hasExtension($items[$i])) { - continue; - } - if (($extension = $this->container->getExtension($items[$i])) && \false !== $extension->getXsdValidationBasePath()) { - $ns = $extension->getNamespace(); - $path = \str_replace([$ns, \str_replace('http://', 'https://', $ns)], \str_replace('\\', '/', $extension->getXsdValidationBasePath()) . '/', $items[$i + 1]); - if (!\is_file($path)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Extension "%s" references a non-existent XSD file "%s".', \get_class($extension), $path)); - } - $schemaLocations[$items[$i]] = $path; - } - } - } - $tmpfiles = []; - $imports = ''; - foreach ($schemaLocations as $namespace => $location) { - $parts = \explode('/', $location); - $locationstart = 'file:///'; - if (0 === \stripos($location, 'phar://')) { - $tmpfile = \tempnam(\sys_get_temp_dir(), 'symfony'); - if ($tmpfile) { - \copy($location, $tmpfile); - $tmpfiles[] = $tmpfile; - $parts = \explode('/', \str_replace('\\', '/', $tmpfile)); - } else { - \array_shift($parts); - $locationstart = 'phar:///'; - } - } - $drive = '\\' === \DIRECTORY_SEPARATOR ? \array_shift($parts) . '/' : ''; - $location = $locationstart . $drive . \implode('/', \array_map('rawurlencode', $parts)); - $imports .= \sprintf(' ' . "\n", $namespace, $location); - } - $source = << - - - -{$imports} - -EOF; - $disableEntities = \libxml_disable_entity_loader(\false); - $valid = @$dom->schemaValidateSource($source); - \libxml_disable_entity_loader($disableEntities); - foreach ($tmpfiles as $tmpfile) { - @\unlink($tmpfile); - } - return $valid; - } - /** - * Validates an alias. - * - * @param string $file - */ - private function validateAlias(\DOMElement $alias, $file) - { - foreach ($alias->attributes as $name => $node) { - if (!\in_array($name, ['alias', 'id', 'public'])) { - @\trigger_error(\sprintf('Using the attribute "%s" is deprecated for the service "%s" which is defined as an alias in "%s". Allowed attributes for service aliases are "alias", "id" and "public". The XmlFileLoader will raise an exception in Symfony 4.0, instead of silently ignoring unsupported attributes.', $name, $alias->getAttribute('id'), $file), \E_USER_DEPRECATED); - } - } - foreach ($alias->childNodes as $child) { - if ($child instanceof \DOMElement && self::NS === $child->namespaceURI) { - @\trigger_error(\sprintf('Using the element "%s" is deprecated for the service "%s" which is defined as an alias in "%s". The XmlFileLoader will raise an exception in Symfony 4.0, instead of silently ignoring unsupported elements.', $child->localName, $alias->getAttribute('id'), $file), \E_USER_DEPRECATED); - } - } - } - /** - * Validates an extension. - * - * @param string $file - * - * @throws InvalidArgumentException When no extension is found corresponding to a tag - */ - private function validateExtensions(\DOMDocument $dom, $file) - { - foreach ($dom->documentElement->childNodes as $node) { - if (!$node instanceof \DOMElement || 'http://symfony.com/schema/dic/services' === $node->namespaceURI) { - continue; - } - // can it be handled by an extension? - if (!$this->container->hasExtension($node->namespaceURI)) { - $extensionNamespaces = \array_filter(\array_map(function ($ext) { - return $ext->getNamespace(); - }, $this->container->getExtensions())); - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('There is no extension able to load the configuration for "%s" (in "%s"). Looked for namespace "%s", found "%s".', $node->tagName, $file, $node->namespaceURI, $extensionNamespaces ? \sprintf('"%s"', \implode('", "', $extensionNamespaces)) : 'none')); - } - } - } - /** - * Loads from an extension. - */ - private function loadFromExtensions(\DOMDocument $xml) - { - foreach ($xml->documentElement->childNodes as $node) { - if (!$node instanceof \DOMElement || self::NS === $node->namespaceURI) { - continue; - } - $values = static::convertDomElementToArray($node); - if (!\is_array($values)) { - $values = []; - } - $this->container->loadFromExtension($node->namespaceURI, $values); - } - } - /** - * Converts a \DOMElement object to a PHP array. - * - * The following rules applies during the conversion: - * - * * Each tag is converted to a key value or an array - * if there is more than one "value" - * - * * The content of a tag is set under a "value" key (bar) - * if the tag also has some nested tags - * - * * The attributes are converted to keys () - * - * * The nested-tags are converted to keys (bar) - * - * @param \DOMElement $element A \DOMElement instance - * - * @return mixed - */ - public static function convertDomElementToArray(\DOMElement $element) - { - return \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::convertDomElementToArray($element); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +/** + * XmlFileLoader loads XML files service definitions. + * + * @author Fabien Potencier + */ +class XmlFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader +{ + const NS = 'http://symfony.com/schema/dic/services'; + /** + * {@inheritdoc} + */ + public function load($resource, $type = null) + { + $path = $this->locator->locate($resource); + $xml = $this->parseFileToDOM($path); + $this->container->fileExists($path); + $defaults = $this->getServiceDefaults($xml, $path); + // anonymous services + $this->processAnonymousServices($xml, $path, $defaults); + // imports + $this->parseImports($xml, $path); + // parameters + $this->parseParameters($xml, $path); + // extensions + $this->loadFromExtensions($xml); + // services + try { + $this->parseDefinitions($xml, $path, $defaults); + } finally { + $this->instanceof = []; + } + } + /** + * {@inheritdoc} + */ + public function supports($resource, $type = null) + { + if (!\is_string($resource)) { + return \false; + } + if (null === $type && 'xml' === \pathinfo($resource, \PATHINFO_EXTENSION)) { + return \true; + } + return 'xml' === $type; + } + /** + * Parses parameters. + * + * @param string $file + */ + private function parseParameters(\DOMDocument $xml, $file) + { + if ($parameters = $this->getChildren($xml->documentElement, 'parameters')) { + $this->container->getParameterBag()->add($this->getArgumentsAsPhp($parameters[0], 'parameter', $file)); + } + } + /** + * Parses imports. + * + * @param string $file + */ + private function parseImports(\DOMDocument $xml, $file) + { + $xpath = new \DOMXPath($xml); + $xpath->registerNamespace('container', self::NS); + if (\false === ($imports = $xpath->query('//container:imports/container:import'))) { + return; + } + $defaultDirectory = \dirname($file); + foreach ($imports as $import) { + $this->setCurrentDir($defaultDirectory); + $this->import($import->getAttribute('resource'), \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($import->getAttribute('type')) ?: null, (bool) \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($import->getAttribute('ignore-errors')), $file); + } + } + /** + * Parses multiple definitions. + * + * @param string $file + */ + private function parseDefinitions(\DOMDocument $xml, $file, $defaults) + { + $xpath = new \DOMXPath($xml); + $xpath->registerNamespace('container', self::NS); + if (\false === ($services = $xpath->query('//container:services/container:service|//container:services/container:prototype'))) { + return; + } + $this->setCurrentDir(\dirname($file)); + $this->instanceof = []; + $this->isLoadingInstanceof = \true; + $instanceof = $xpath->query('//container:services/container:instanceof'); + foreach ($instanceof as $service) { + $this->setDefinition((string) $service->getAttribute('id'), $this->parseDefinition($service, $file, [])); + } + $this->isLoadingInstanceof = \false; + foreach ($services as $service) { + if (null !== ($definition = $this->parseDefinition($service, $file, $defaults))) { + if ('prototype' === $service->tagName) { + $this->registerClasses($definition, (string) $service->getAttribute('namespace'), (string) $service->getAttribute('resource'), (string) $service->getAttribute('exclude')); + } else { + $this->setDefinition((string) $service->getAttribute('id'), $definition); + } + } + } + } + /** + * Get service defaults. + * + * @return array + */ + private function getServiceDefaults(\DOMDocument $xml, $file) + { + $xpath = new \DOMXPath($xml); + $xpath->registerNamespace('container', self::NS); + if (null === ($defaultsNode = $xpath->query('//container:services/container:defaults')->item(0))) { + return []; + } + $defaults = ['tags' => $this->getChildren($defaultsNode, 'tag'), 'bind' => \array_map(function ($v) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument($v); + }, $this->getArgumentsAsPhp($defaultsNode, 'bind', $file))]; + foreach ($defaults['tags'] as $tag) { + if ('' === $tag->getAttribute('name')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The tag name for tag "" in "%s" must be a non-empty string.', $file)); + } + } + if ($defaultsNode->hasAttribute('autowire')) { + $defaults['autowire'] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($defaultsNode->getAttribute('autowire')); + } + if ($defaultsNode->hasAttribute('public')) { + $defaults['public'] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($defaultsNode->getAttribute('public')); + } + if ($defaultsNode->hasAttribute('autoconfigure')) { + $defaults['autoconfigure'] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($defaultsNode->getAttribute('autoconfigure')); + } + return $defaults; + } + /** + * Parses an individual Definition. + * + * @param string $file + * + * @return Definition|null + */ + private function parseDefinition(\DOMElement $service, $file, array $defaults) + { + if ($alias = $service->getAttribute('alias')) { + $this->validateAlias($service, $file); + $this->container->setAlias((string) $service->getAttribute('id'), $alias = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($alias)); + if ($publicAttr = $service->getAttribute('public')) { + $alias->setPublic(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($publicAttr)); + } elseif (isset($defaults['public'])) { + $alias->setPublic($defaults['public']); + } + return null; + } + if ($this->isLoadingInstanceof) { + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''); + } elseif ($parent = $service->getAttribute('parent')) { + if (!empty($this->instanceof)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot use the "parent" option in the same file where "instanceof" configuration is defined as using both is not supported. Move your child definitions to a separate file.', $service->getAttribute('id'))); + } + foreach ($defaults as $k => $v) { + if ('tags' === $k) { + // since tags are never inherited from parents, there is no confusion + // thus we can safely add them as defaults to ChildDefinition + continue; + } + if ('bind' === $k) { + if ($defaults['bind']) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Bound values on service "%s" cannot be inherited from "defaults" when a "parent" is set. Move your child definitions to a separate file.', $service->getAttribute('id'))); + } + continue; + } + if (!$service->hasAttribute($k)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Attribute "%s" on service "%s" cannot be inherited from "defaults" when a "parent" is set. Move your child definitions to a separate file or define this attribute explicitly.', $k, $service->getAttribute('id'))); + } + } + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition($parent); + } else { + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + if (isset($defaults['public'])) { + $definition->setPublic($defaults['public']); + } + if (isset($defaults['autowire'])) { + $definition->setAutowired($defaults['autowire']); + } + if (isset($defaults['autoconfigure'])) { + $definition->setAutoconfigured($defaults['autoconfigure']); + } + $definition->setChanges([]); + } + foreach (['class', 'public', 'shared', 'synthetic', 'lazy', 'abstract'] as $key) { + if ($value = $service->getAttribute($key)) { + $method = 'set' . $key; + $definition->{$method}(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value)); + } + } + if ($value = $service->getAttribute('autowire')) { + $definition->setAutowired(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value)); + } + if ($value = $service->getAttribute('autoconfigure')) { + if (!$definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { + $definition->setAutoconfigured(\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value)); + } elseif ($value = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($value)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot have a "parent" and also have "autoconfigure". Try setting autoconfigure="false" for the service.', $service->getAttribute('id'))); + } + } + if ($files = $this->getChildren($service, 'file')) { + $definition->setFile($files[0]->nodeValue); + } + if ($deprecated = $this->getChildren($service, 'deprecated')) { + $definition->setDeprecated(\true, $deprecated[0]->nodeValue ?: null); + } + $definition->setArguments($this->getArgumentsAsPhp($service, 'argument', $file, $definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition)); + $definition->setProperties($this->getArgumentsAsPhp($service, 'property', $file)); + if ($factories = $this->getChildren($service, 'factory')) { + $factory = $factories[0]; + if ($function = $factory->getAttribute('function')) { + $definition->setFactory($function); + } else { + if ($childService = $factory->getAttribute('service')) { + $class = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($childService, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE); + } else { + $class = $factory->hasAttribute('class') ? $factory->getAttribute('class') : null; + } + $definition->setFactory([$class, $factory->getAttribute('method')]); + } + } + if ($configurators = $this->getChildren($service, 'configurator')) { + $configurator = $configurators[0]; + if ($function = $configurator->getAttribute('function')) { + $definition->setConfigurator($function); + } else { + if ($childService = $configurator->getAttribute('service')) { + $class = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($childService, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE); + } else { + $class = $configurator->getAttribute('class'); + } + $definition->setConfigurator([$class, $configurator->getAttribute('method')]); + } + } + foreach ($this->getChildren($service, 'call') as $call) { + $definition->addMethodCall($call->getAttribute('method'), $this->getArgumentsAsPhp($call, 'argument', $file)); + } + $tags = $this->getChildren($service, 'tag'); + if (!empty($defaults['tags'])) { + $tags = \array_merge($tags, $defaults['tags']); + } + foreach ($tags as $tag) { + $parameters = []; + foreach ($tag->attributes as $name => $node) { + if ('name' === $name) { + continue; + } + if (\false !== \strpos($name, '-') && \false === \strpos($name, '_') && !\array_key_exists($normalizedName = \str_replace('-', '_', $name), $parameters)) { + $parameters[$normalizedName] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($node->nodeValue); + } + // keep not normalized key + $parameters[$name] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($node->nodeValue); + } + if ('' === $tag->getAttribute('name')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The tag name for service "%s" in "%s" must be a non-empty string.', (string) $service->getAttribute('id'), $file)); + } + $definition->addTag($tag->getAttribute('name'), $parameters); + } + foreach ($this->getChildren($service, 'autowiring-type') as $type) { + $definition->addAutowiringType($type->textContent); + } + $bindings = $this->getArgumentsAsPhp($service, 'bind', $file); + if (isset($defaults['bind'])) { + // deep clone, to avoid multiple process of the same instance in the passes + $bindings = \array_merge(\unserialize(\serialize($defaults['bind'])), $bindings); + } + if ($bindings) { + $definition->setBindings($bindings); + } + if ($value = $service->getAttribute('decorates')) { + $renameId = $service->hasAttribute('decoration-inner-name') ? $service->getAttribute('decoration-inner-name') : null; + $priority = $service->hasAttribute('decoration-priority') ? $service->getAttribute('decoration-priority') : 0; + $definition->setDecoratedService($value, $renameId, $priority); + } + return $definition; + } + /** + * Parses a XML file to a \DOMDocument. + * + * @param string $file Path to a file + * + * @return \DOMDocument + * + * @throws InvalidArgumentException When loading of XML file returns error + */ + private function parseFileToDOM($file) + { + try { + $dom = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::loadFile($file, [$this, 'validateSchema']); + } catch (\InvalidArgumentException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Unable to parse file "%s": "%s".', $file, $e->getMessage()), $e->getCode(), $e); + } + $this->validateExtensions($dom, $file); + return $dom; + } + /** + * Processes anonymous services. + * + * @param string $file + * @param array $defaults + */ + private function processAnonymousServices(\DOMDocument $xml, $file, $defaults) + { + $definitions = []; + $count = 0; + $suffix = '~' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::hash($file); + $xpath = new \DOMXPath($xml); + $xpath->registerNamespace('container', self::NS); + // anonymous services as arguments/properties + if (\false !== ($nodes = $xpath->query('//container:argument[@type="service"][not(@id)]|//container:property[@type="service"][not(@id)]|//container:bind[not(@id)]|//container:factory[not(@service)]|//container:configurator[not(@service)]'))) { + foreach ($nodes as $node) { + if ($services = $this->getChildren($node, 'service')) { + // give it a unique name + $id = \sprintf('%d_%s', ++$count, \preg_replace('/^.*\\\\/', '', $services[0]->getAttribute('class')) . $suffix); + $node->setAttribute('id', $id); + $node->setAttribute('service', $id); + $definitions[$id] = [$services[0], $file, \false]; + $services[0]->setAttribute('id', $id); + // anonymous services are always private + // we could not use the constant false here, because of XML parsing + $services[0]->setAttribute('public', 'false'); + } + } + } + // anonymous services "in the wild" + if (\false !== ($nodes = $xpath->query('//container:services/container:service[not(@id)]'))) { + foreach ($nodes as $node) { + @\trigger_error(\sprintf('Top-level anonymous services are deprecated since Symfony 3.4, the "id" attribute will be required in version 4.0 in %s at line %d.', $file, $node->getLineNo()), \E_USER_DEPRECATED); + // give it a unique name + $id = \sprintf('%d_%s', ++$count, \preg_replace('/^.*\\\\/', '', $node->getAttribute('class')) . $suffix); + $node->setAttribute('id', $id); + $definitions[$id] = [$node, $file, \true]; + } + } + // resolve definitions + \uksort($definitions, 'strnatcmp'); + foreach (\array_reverse($definitions) as $id => list($domElement, $file, $wild)) { + if (null !== ($definition = $this->parseDefinition($domElement, $file, $wild ? $defaults : []))) { + $this->setDefinition($id, $definition); + } + if (\true === $wild) { + $tmpDomElement = new \DOMElement('_services', null, self::NS); + $domElement->parentNode->replaceChild($tmpDomElement, $domElement); + $tmpDomElement->setAttribute('id', $id); + } + } + } + /** + * Returns arguments as valid php types. + * + * @param string $name + * @param string $file + * + * @return mixed + */ + private function getArgumentsAsPhp(\DOMElement $node, $name, $file, $isChildDefinition = \false) + { + $arguments = []; + foreach ($this->getChildren($node, $name) as $arg) { + if ($arg->hasAttribute('name')) { + $arg->setAttribute('key', $arg->getAttribute('name')); + } + // this is used by ChildDefinition to overwrite a specific + // argument of the parent definition + if ($arg->hasAttribute('index')) { + $key = ($isChildDefinition ? 'index_' : '') . $arg->getAttribute('index'); + } elseif (!$arg->hasAttribute('key')) { + // Append an empty argument, then fetch its key to overwrite it later + $arguments[] = null; + $keys = \array_keys($arguments); + $key = \array_pop($keys); + } else { + $key = $arg->getAttribute('key'); + } + $onInvalid = $arg->getAttribute('on-invalid'); + $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE; + if ('ignore' == $onInvalid) { + $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE; + } elseif ('ignore_uninitialized' == $onInvalid) { + $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE; + } elseif ('null' == $onInvalid) { + $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE; + } + switch ($arg->getAttribute('type')) { + case 'service': + if ('' === $arg->getAttribute('id')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Tag "<%s>" with type="service" has no or empty "id" attribute in "%s".', $name, $file)); + } + if ($arg->hasAttribute('strict')) { + @\trigger_error(\sprintf('The "strict" attribute used when referencing the "%s" service is deprecated since Symfony 3.3 and will be removed in 4.0.', $arg->getAttribute('id')), \E_USER_DEPRECATED); + } + $arguments[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($arg->getAttribute('id'), $invalidBehavior); + break; + case 'expression': + if (!\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression::class)) { + throw new \LogicException(\sprintf('The type="expression" attribute cannot be used without the ExpressionLanguage component. Try running "composer require symfony/expression-language".')); + } + $arguments[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression($arg->nodeValue); + break; + case 'collection': + $arguments[$key] = $this->getArgumentsAsPhp($arg, $name, $file); + break; + case 'iterator': + $arg = $this->getArgumentsAsPhp($arg, $name, $file); + try { + $arguments[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument($arg); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Tag "<%s>" with type="iterator" only accepts collections of type="service" references in "%s".', $name, $file)); + } + break; + case 'tagged': + if (!$arg->getAttribute('tag')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Tag "<%s>" with type="tagged" has no or empty "tag" attribute in "%s".', $name, $file)); + } + $arguments[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument($arg->getAttribute('tag')); + break; + case 'string': + $arguments[$key] = $arg->nodeValue; + break; + case 'constant': + $arguments[$key] = \constant(\trim($arg->nodeValue)); + break; + default: + $arguments[$key] = \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::phpize($arg->nodeValue); + } + } + return $arguments; + } + /** + * Get child elements by name. + * + * @param mixed $name + * + * @return \DOMElement[] + */ + private function getChildren(\DOMNode $node, $name) + { + $children = []; + foreach ($node->childNodes as $child) { + if ($child instanceof \DOMElement && $child->localName === $name && self::NS === $child->namespaceURI) { + $children[] = $child; + } + } + return $children; + } + /** + * Validates a documents XML schema. + * + * @return bool + * + * @throws RuntimeException When extension references a non-existent XSD file + */ + public function validateSchema(\DOMDocument $dom) + { + $schemaLocations = ['http://symfony.com/schema/dic/services' => \str_replace('\\', '/', __DIR__ . '/schema/dic/services/services-1.0.xsd')]; + if ($element = $dom->documentElement->getAttributeNS('http://www.w3.org/2001/XMLSchema-instance', 'schemaLocation')) { + $items = \preg_split('/\\s+/', $element); + for ($i = 0, $nb = \count($items); $i < $nb; $i += 2) { + if (!$this->container->hasExtension($items[$i])) { + continue; + } + if (($extension = $this->container->getExtension($items[$i])) && \false !== $extension->getXsdValidationBasePath()) { + $ns = $extension->getNamespace(); + $path = \str_replace([$ns, \str_replace('http://', 'https://', $ns)], \str_replace('\\', '/', $extension->getXsdValidationBasePath()) . '/', $items[$i + 1]); + if (!\is_file($path)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('Extension "%s" references a non-existent XSD file "%s".', \get_class($extension), $path)); + } + $schemaLocations[$items[$i]] = $path; + } + } + } + $tmpfiles = []; + $imports = ''; + foreach ($schemaLocations as $namespace => $location) { + $parts = \explode('/', $location); + $locationstart = 'file:///'; + if (0 === \stripos($location, 'phar://')) { + $tmpfile = \tempnam(\sys_get_temp_dir(), 'symfony'); + if ($tmpfile) { + \copy($location, $tmpfile); + $tmpfiles[] = $tmpfile; + $parts = \explode('/', \str_replace('\\', '/', $tmpfile)); + } else { + \array_shift($parts); + $locationstart = 'phar:///'; + } + } + $drive = '\\' === \DIRECTORY_SEPARATOR ? \array_shift($parts) . '/' : ''; + $location = $locationstart . $drive . \implode('/', \array_map('rawurlencode', $parts)); + $imports .= \sprintf(' ' . "\n", $namespace, $location); + } + $source = << + + + +{$imports} + +EOF; + $disableEntities = \libxml_disable_entity_loader(\false); + $valid = @$dom->schemaValidateSource($source); + \libxml_disable_entity_loader($disableEntities); + foreach ($tmpfiles as $tmpfile) { + @\unlink($tmpfile); + } + return $valid; + } + /** + * Validates an alias. + * + * @param string $file + */ + private function validateAlias(\DOMElement $alias, $file) + { + foreach ($alias->attributes as $name => $node) { + if (!\in_array($name, ['alias', 'id', 'public'])) { + @\trigger_error(\sprintf('Using the attribute "%s" is deprecated for the service "%s" which is defined as an alias in "%s". Allowed attributes for service aliases are "alias", "id" and "public". The XmlFileLoader will raise an exception in Symfony 4.0, instead of silently ignoring unsupported attributes.', $name, $alias->getAttribute('id'), $file), \E_USER_DEPRECATED); + } + } + foreach ($alias->childNodes as $child) { + if ($child instanceof \DOMElement && self::NS === $child->namespaceURI) { + @\trigger_error(\sprintf('Using the element "%s" is deprecated for the service "%s" which is defined as an alias in "%s". The XmlFileLoader will raise an exception in Symfony 4.0, instead of silently ignoring unsupported elements.', $child->localName, $alias->getAttribute('id'), $file), \E_USER_DEPRECATED); + } + } + } + /** + * Validates an extension. + * + * @param string $file + * + * @throws InvalidArgumentException When no extension is found corresponding to a tag + */ + private function validateExtensions(\DOMDocument $dom, $file) + { + foreach ($dom->documentElement->childNodes as $node) { + if (!$node instanceof \DOMElement || 'http://symfony.com/schema/dic/services' === $node->namespaceURI) { + continue; + } + // can it be handled by an extension? + if (!$this->container->hasExtension($node->namespaceURI)) { + $extensionNamespaces = \array_filter(\array_map(function ($ext) { + return $ext->getNamespace(); + }, $this->container->getExtensions())); + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('There is no extension able to load the configuration for "%s" (in "%s"). Looked for namespace "%s", found "%s".', $node->tagName, $file, $node->namespaceURI, $extensionNamespaces ? \sprintf('"%s"', \implode('", "', $extensionNamespaces)) : 'none')); + } + } + } + /** + * Loads from an extension. + */ + private function loadFromExtensions(\DOMDocument $xml) + { + foreach ($xml->documentElement->childNodes as $node) { + if (!$node instanceof \DOMElement || self::NS === $node->namespaceURI) { + continue; + } + $values = static::convertDomElementToArray($node); + if (!\is_array($values)) { + $values = []; + } + $this->container->loadFromExtension($node->namespaceURI, $values); + } + } + /** + * Converts a \DOMElement object to a PHP array. + * + * The following rules applies during the conversion: + * + * * Each tag is converted to a key value or an array + * if there is more than one "value" + * + * * The content of a tag is set under a "value" key (bar) + * if the tag also has some nested tags + * + * * The attributes are converted to keys () + * + * * The nested-tags are converted to keys (bar) + * + * @param \DOMElement $element A \DOMElement instance + * + * @return mixed + */ + public static function convertDomElementToArray(\DOMElement $element) + { + return \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Util\XmlUtils::convertDomElementToArray($element); + } +} diff --git a/vendor/symfony/dependency-injection/Loader/YamlFileLoader.php b/vendor/symfony/dependency-injection/Loader/YamlFileLoader.php index 4a1e5e8f6..2a8e9e97f 100644 --- a/vendor/symfony/dependency-injection/Loader/YamlFileLoader.php +++ b/vendor/symfony/dependency-injection/Loader/YamlFileLoader.php @@ -1,662 +1,662 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser as YamlParser; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; -/** - * YamlFileLoader loads YAML files service definitions. - * - * @author Fabien Potencier - */ -class YamlFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader -{ - private static $serviceKeywords = ['alias' => 'alias', 'parent' => 'parent', 'class' => 'class', 'shared' => 'shared', 'synthetic' => 'synthetic', 'lazy' => 'lazy', 'public' => 'public', 'abstract' => 'abstract', 'deprecated' => 'deprecated', 'factory' => 'factory', 'file' => 'file', 'arguments' => 'arguments', 'properties' => 'properties', 'configurator' => 'configurator', 'calls' => 'calls', 'tags' => 'tags', 'decorates' => 'decorates', 'decoration_inner_name' => 'decoration_inner_name', 'decoration_priority' => 'decoration_priority', 'autowire' => 'autowire', 'autowiring_types' => 'autowiring_types', 'autoconfigure' => 'autoconfigure', 'bind' => 'bind']; - private static $prototypeKeywords = ['resource' => 'resource', 'namespace' => 'namespace', 'exclude' => 'exclude', 'parent' => 'parent', 'shared' => 'shared', 'lazy' => 'lazy', 'public' => 'public', 'abstract' => 'abstract', 'deprecated' => 'deprecated', 'factory' => 'factory', 'arguments' => 'arguments', 'properties' => 'properties', 'configurator' => 'configurator', 'calls' => 'calls', 'tags' => 'tags', 'autowire' => 'autowire', 'autoconfigure' => 'autoconfigure', 'bind' => 'bind']; - private static $instanceofKeywords = ['shared' => 'shared', 'lazy' => 'lazy', 'public' => 'public', 'properties' => 'properties', 'configurator' => 'configurator', 'calls' => 'calls', 'tags' => 'tags', 'autowire' => 'autowire']; - private static $defaultsKeywords = ['public' => 'public', 'tags' => 'tags', 'autowire' => 'autowire', 'autoconfigure' => 'autoconfigure', 'bind' => 'bind']; - private $yamlParser; - private $anonymousServicesCount; - private $anonymousServicesSuffix; - /** - * {@inheritdoc} - */ - public function load($resource, $type = null) - { - $path = $this->locator->locate($resource); - $content = $this->loadFile($path); - $this->container->fileExists($path); - // empty file - if (null === $content) { - return; - } - // imports - $this->parseImports($content, $path); - // parameters - if (isset($content['parameters'])) { - if (!\is_array($content['parameters'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The "parameters" key should contain an array in "%s". Check your YAML syntax.', $path)); - } - foreach ($content['parameters'] as $key => $value) { - $this->container->setParameter($key, $this->resolveServices($value, $path, \true)); - } - } - // extensions - $this->loadFromExtensions($content); - // services - $this->anonymousServicesCount = 0; - $this->anonymousServicesSuffix = '~' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::hash($path); - $this->setCurrentDir(\dirname($path)); - try { - $this->parseDefinitions($content, $path); - } finally { - $this->instanceof = []; - } - } - /** - * {@inheritdoc} - */ - public function supports($resource, $type = null) - { - if (!\is_string($resource)) { - return \false; - } - if (null === $type && \in_array(\pathinfo($resource, \PATHINFO_EXTENSION), ['yaml', 'yml'], \true)) { - return \true; - } - return \in_array($type, ['yaml', 'yml'], \true); - } - /** - * Parses all imports. - * - * @param string $file - */ - private function parseImports(array $content, $file) - { - if (!isset($content['imports'])) { - return; - } - if (!\is_array($content['imports'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The "imports" key should contain an array in "%s". Check your YAML syntax.', $file)); - } - $defaultDirectory = \dirname($file); - foreach ($content['imports'] as $import) { - if (!\is_array($import)) { - $import = ['resource' => $import]; - } - if (!isset($import['resource'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('An import should provide a resource in "%s". Check your YAML syntax.', $file)); - } - $this->setCurrentDir($defaultDirectory); - $this->import($import['resource'], isset($import['type']) ? $import['type'] : null, isset($import['ignore_errors']) ? (bool) $import['ignore_errors'] : \false, $file); - } - } - /** - * Parses definitions. - * - * @param string $file - */ - private function parseDefinitions(array $content, $file) - { - if (!isset($content['services'])) { - return; - } - if (!\is_array($content['services'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The "services" key should contain an array in "%s". Check your YAML syntax.', $file)); - } - if (\array_key_exists('_instanceof', $content['services'])) { - $instanceof = $content['services']['_instanceof']; - unset($content['services']['_instanceof']); - if (!\is_array($instanceof)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service "_instanceof" key must be an array, "%s" given in "%s".', \gettype($instanceof), $file)); - } - $this->instanceof = []; - $this->isLoadingInstanceof = \true; - foreach ($instanceof as $id => $service) { - if (!$service || !\is_array($service)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Type definition "%s" must be a non-empty array within "_instanceof" in "%s". Check your YAML syntax.', $id, $file)); - } - if (\is_string($service) && 0 === \strpos($service, '@')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Type definition "%s" cannot be an alias within "_instanceof" in "%s". Check your YAML syntax.', $id, $file)); - } - $this->parseDefinition($id, $service, $file, []); - } - } - $this->isLoadingInstanceof = \false; - $defaults = $this->parseDefaults($content, $file); - foreach ($content['services'] as $id => $service) { - $this->parseDefinition($id, $service, $file, $defaults); - } - } - /** - * @param string $file - * - * @return array - * - * @throws InvalidArgumentException - */ - private function parseDefaults(array &$content, $file) - { - if (!\array_key_exists('_defaults', $content['services'])) { - return []; - } - $defaults = $content['services']['_defaults']; - unset($content['services']['_defaults']); - if (!\is_array($defaults)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service "_defaults" key must be an array, "%s" given in "%s".', \gettype($defaults), $file)); - } - foreach ($defaults as $key => $default) { - if (!isset(self::$defaultsKeywords[$key])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The configuration key "%s" cannot be used to define a default value in "%s". Allowed keys are "%s".', $key, $file, \implode('", "', self::$defaultsKeywords))); - } - } - if (isset($defaults['tags'])) { - if (!\is_array($tags = $defaults['tags'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "tags" in "_defaults" must be an array in "%s". Check your YAML syntax.', $file)); - } - foreach ($tags as $tag) { - if (!\is_array($tag)) { - $tag = ['name' => $tag]; - } - if (!isset($tag['name'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "tags" entry in "_defaults" is missing a "name" key in "%s".', $file)); - } - $name = $tag['name']; - unset($tag['name']); - if (!\is_string($name) || '' === $name) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The tag name in "_defaults" must be a non-empty string in "%s".', $file)); - } - foreach ($tag as $attribute => $value) { - if (!\is_scalar($value) && null !== $value) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Tag "%s", attribute "%s" in "_defaults" must be of a scalar-type in "%s". Check your YAML syntax.', $name, $attribute, $file)); - } - } - } - } - if (isset($defaults['bind'])) { - if (!\is_array($defaults['bind'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "bind" in "_defaults" must be an array in "%s". Check your YAML syntax.', $file)); - } - $defaults['bind'] = \array_map(function ($v) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument($v); - }, $this->resolveServices($defaults['bind'], $file)); - } - return $defaults; - } - /** - * @return bool - */ - private function isUsingShortSyntax(array $service) - { - foreach ($service as $key => $value) { - if (\is_string($key) && ('' === $key || '$' !== $key[0])) { - return \false; - } - } - return \true; - } - /** - * Parses a definition. - * - * @param string $id - * @param array|string $service - * @param string $file - * - * @throws InvalidArgumentException When tags are invalid - */ - private function parseDefinition($id, $service, $file, array $defaults) - { - if (\preg_match('/^_[a-zA-Z0-9_]*$/', $id)) { - @\trigger_error(\sprintf('Service names that start with an underscore are deprecated since Symfony 3.3 and will be reserved in 4.0. Rename the "%s" service or define it in XML instead.', $id), \E_USER_DEPRECATED); - } - if (\is_string($service) && 0 === \strpos($service, '@')) { - $this->container->setAlias($id, $alias = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias(\substr($service, 1))); - if (isset($defaults['public'])) { - $alias->setPublic($defaults['public']); - } - return; - } - if (\is_array($service) && $this->isUsingShortSyntax($service)) { - $service = ['arguments' => $service]; - } - if (null === $service) { - $service = []; - } - if (!\is_array($service)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A service definition must be an array or a string starting with "@" but "%s" found for service "%s" in "%s". Check your YAML syntax.', \gettype($service), $id, $file)); - } - $this->checkDefinition($id, $service, $file); - if (isset($service['alias'])) { - $this->container->setAlias($id, $alias = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($service['alias'])); - if (\array_key_exists('public', $service)) { - $alias->setPublic($service['public']); - } elseif (isset($defaults['public'])) { - $alias->setPublic($defaults['public']); - } - foreach ($service as $key => $value) { - if (!\in_array($key, ['alias', 'public'])) { - @\trigger_error(\sprintf('The configuration key "%s" is unsupported for the service "%s" which is defined as an alias in "%s". Allowed configuration keys for service aliases are "alias" and "public". The YamlFileLoader will raise an exception in Symfony 4.0, instead of silently ignoring unsupported attributes.', $key, $id, $file), \E_USER_DEPRECATED); - } - } - return; - } - if ($this->isLoadingInstanceof) { - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''); - } elseif (isset($service['parent'])) { - if (!empty($this->instanceof)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot use the "parent" option in the same file where "_instanceof" configuration is defined as using both is not supported. Move your child definitions to a separate file.', $id)); - } - foreach ($defaults as $k => $v) { - if ('tags' === $k) { - // since tags are never inherited from parents, there is no confusion - // thus we can safely add them as defaults to ChildDefinition - continue; - } - if ('bind' === $k) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Attribute "bind" on service "%s" cannot be inherited from "_defaults" when a "parent" is set. Move your child definitions to a separate file.', $id)); - } - if (!isset($service[$k])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Attribute "%s" on service "%s" cannot be inherited from "_defaults" when a "parent" is set. Move your child definitions to a separate file or define this attribute explicitly.', $k, $id)); - } - } - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition($service['parent']); - } else { - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - if (isset($defaults['public'])) { - $definition->setPublic($defaults['public']); - } - if (isset($defaults['autowire'])) { - $definition->setAutowired($defaults['autowire']); - } - if (isset($defaults['autoconfigure'])) { - $definition->setAutoconfigured($defaults['autoconfigure']); - } - $definition->setChanges([]); - } - if (isset($service['class'])) { - $definition->setClass($service['class']); - } - if (isset($service['shared'])) { - $definition->setShared($service['shared']); - } - if (isset($service['synthetic'])) { - $definition->setSynthetic($service['synthetic']); - } - if (isset($service['lazy'])) { - $definition->setLazy($service['lazy']); - } - if (isset($service['public'])) { - $definition->setPublic($service['public']); - } - if (isset($service['abstract'])) { - $definition->setAbstract($service['abstract']); - } - if (\array_key_exists('deprecated', $service)) { - $definition->setDeprecated(\true, $service['deprecated']); - } - if (isset($service['factory'])) { - $definition->setFactory($this->parseCallable($service['factory'], 'factory', $id, $file)); - } - if (isset($service['file'])) { - $definition->setFile($service['file']); - } - if (isset($service['arguments'])) { - $definition->setArguments($this->resolveServices($service['arguments'], $file)); - } - if (isset($service['properties'])) { - $definition->setProperties($this->resolveServices($service['properties'], $file)); - } - if (isset($service['configurator'])) { - $definition->setConfigurator($this->parseCallable($service['configurator'], 'configurator', $id, $file)); - } - if (isset($service['calls'])) { - if (!\is_array($service['calls'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "calls" must be an array for service "%s" in "%s". Check your YAML syntax.', $id, $file)); - } - foreach ($service['calls'] as $call) { - if (isset($call['method'])) { - $method = $call['method']; - $args = isset($call['arguments']) ? $this->resolveServices($call['arguments'], $file) : []; - } else { - $method = $call[0]; - $args = isset($call[1]) ? $this->resolveServices($call[1], $file) : []; - } - if (!\is_array($args)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The second parameter for function call "%s" must be an array of its arguments for service "%s" in "%s". Check your YAML syntax.', $method, $id, $file)); - } - $definition->addMethodCall($method, $args); - } - } - $tags = isset($service['tags']) ? $service['tags'] : []; - if (!\is_array($tags)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "tags" must be an array for service "%s" in "%s". Check your YAML syntax.', $id, $file)); - } - if (isset($defaults['tags'])) { - $tags = \array_merge($tags, $defaults['tags']); - } - foreach ($tags as $tag) { - if (!\is_array($tag)) { - $tag = ['name' => $tag]; - } - if (!isset($tag['name'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "tags" entry is missing a "name" key for service "%s" in "%s".', $id, $file)); - } - $name = $tag['name']; - unset($tag['name']); - if (!\is_string($name) || '' === $name) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The tag name for service "%s" in "%s" must be a non-empty string.', $id, $file)); - } - foreach ($tag as $attribute => $value) { - if (!\is_scalar($value) && null !== $value) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "tags" attribute must be of a scalar-type for service "%s", tag "%s", attribute "%s" in "%s". Check your YAML syntax.', $id, $name, $attribute, $file)); - } - } - $definition->addTag($name, $tag); - } - if (isset($service['decorates'])) { - if ('' !== $service['decorates'] && '@' === $service['decorates'][0]) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The value of the "decorates" option for the "%s" service must be the id of the service without the "@" prefix (replace "%s" with "%s").', $id, $service['decorates'], \substr($service['decorates'], 1))); - } - $renameId = isset($service['decoration_inner_name']) ? $service['decoration_inner_name'] : null; - $priority = isset($service['decoration_priority']) ? $service['decoration_priority'] : 0; - $definition->setDecoratedService($service['decorates'], $renameId, $priority); - } - if (isset($service['autowire'])) { - $definition->setAutowired($service['autowire']); - } - if (isset($service['autowiring_types'])) { - if (\is_string($service['autowiring_types'])) { - $definition->addAutowiringType($service['autowiring_types']); - } else { - if (!\is_array($service['autowiring_types'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "autowiring_types" must be a string or an array for service "%s" in "%s". Check your YAML syntax.', $id, $file)); - } - foreach ($service['autowiring_types'] as $autowiringType) { - if (!\is_string($autowiringType)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "autowiring_types" attribute must be of type string for service "%s" in "%s". Check your YAML syntax.', $id, $file)); - } - $definition->addAutowiringType($autowiringType); - } - } - } - if (isset($defaults['bind']) || isset($service['bind'])) { - // deep clone, to avoid multiple process of the same instance in the passes - $bindings = isset($defaults['bind']) ? \unserialize(\serialize($defaults['bind'])) : []; - if (isset($service['bind'])) { - if (!\is_array($service['bind'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "bind" must be an array for service "%s" in "%s". Check your YAML syntax.', $id, $file)); - } - $bindings = \array_merge($bindings, $this->resolveServices($service['bind'], $file)); - } - $definition->setBindings($bindings); - } - if (isset($service['autoconfigure'])) { - if (!$definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { - $definition->setAutoconfigured($service['autoconfigure']); - } elseif ($service['autoconfigure']) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot have a "parent" and also have "autoconfigure". Try setting "autoconfigure: false" for the service.', $id)); - } - } - if (\array_key_exists('namespace', $service) && !\array_key_exists('resource', $service)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "resource" attribute must be set when the "namespace" attribute is set for service "%s" in "%s". Check your YAML syntax.', $id, $file)); - } - if (\array_key_exists('resource', $service)) { - if (!\is_string($service['resource'])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "resource" attribute must be of type string for service "%s" in "%s". Check your YAML syntax.', $id, $file)); - } - $exclude = isset($service['exclude']) ? $service['exclude'] : null; - $namespace = isset($service['namespace']) ? $service['namespace'] : $id; - $this->registerClasses($definition, $namespace, $service['resource'], $exclude); - } else { - $this->setDefinition($id, $definition); - } - } - /** - * Parses a callable. - * - * @param string|array $callable A callable - * @param string $parameter A parameter (e.g. 'factory' or 'configurator') - * @param string $id A service identifier - * @param string $file A parsed file - * - * @throws InvalidArgumentException When errors occur - * - * @return string|array A parsed callable - */ - private function parseCallable($callable, $parameter, $id, $file) - { - if (\is_string($callable)) { - if ('' !== $callable && '@' === $callable[0]) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The value of the "%s" option for the "%s" service must be the id of the service without the "@" prefix (replace "%s" with "%s").', $parameter, $id, $callable, \substr($callable, 1))); - } - if (\false !== \strpos($callable, ':') && \false === \strpos($callable, '::')) { - $parts = \explode(':', $callable); - return [$this->resolveServices('@' . $parts[0], $file), $parts[1]]; - } - return $callable; - } - if (\is_array($callable)) { - if (isset($callable[0]) && isset($callable[1])) { - return [$this->resolveServices($callable[0], $file), $callable[1]]; - } - if ('factory' === $parameter && isset($callable[1]) && null === $callable[0]) { - return $callable; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "%s" must contain an array with two elements for service "%s" in "%s". Check your YAML syntax.', $parameter, $id, $file)); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "%s" must be a string or an array for service "%s" in "%s". Check your YAML syntax.', $parameter, $id, $file)); - } - /** - * Loads a YAML file. - * - * @param string $file - * - * @return array The file content - * - * @throws InvalidArgumentException when the given file is not a local file or when it does not exist - */ - protected function loadFile($file) - { - if (!\class_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Parser')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to load YAML config files as the Symfony Yaml Component is not installed.'); - } - if (!\stream_is_local($file)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('This is not a local file "%s".', $file)); - } - if (!\file_exists($file)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The file "%s" does not exist.', $file)); - } - if (null === $this->yamlParser) { - $this->yamlParser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); - } - $prevErrorHandler = \set_error_handler(function ($level, $message, $script, $line) use($file, &$prevErrorHandler) { - $message = \E_USER_DEPRECATED === $level ? \preg_replace('/ on line \\d+/', ' in "' . $file . '"$0', $message) : $message; - return $prevErrorHandler ? $prevErrorHandler($level, $message, $script, $line) : \false; - }); - try { - $configuration = $this->yamlParser->parseFile($file, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT | \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The file "%s" does not contain valid YAML: %s.', $file, $e->getMessage()), 0, $e); - } finally { - \restore_error_handler(); - } - return $this->validate($configuration, $file); - } - /** - * Validates a YAML file. - * - * @param mixed $content - * @param string $file - * - * @return array - * - * @throws InvalidArgumentException When service file is not valid - */ - private function validate($content, $file) - { - if (null === $content) { - return $content; - } - if (!\is_array($content)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service file "%s" is not valid. It should contain an array. Check your YAML syntax.', $file)); - } - foreach ($content as $namespace => $data) { - if (\in_array($namespace, ['imports', 'parameters', 'services'])) { - continue; - } - if (!$this->container->hasExtension($namespace)) { - $extensionNamespaces = \array_filter(\array_map(function ($ext) { - return $ext->getAlias(); - }, $this->container->getExtensions())); - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('There is no extension able to load the configuration for "%s" (in "%s"). Looked for namespace "%s", found "%s".', $namespace, $file, $namespace, $extensionNamespaces ? \sprintf('"%s"', \implode('", "', $extensionNamespaces)) : 'none')); - } - } - return $content; - } - /** - * Resolves services. - * - * @param mixed $value - * @param string $file - * @param bool $isParameter - * - * @return array|string|Reference|ArgumentInterface - */ - private function resolveServices($value, $file, $isParameter = \false) - { - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue) { - $argument = $value->getValue(); - if ('iterator' === $value->getTag()) { - if (!\is_array($argument)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"!iterator" tag only accepts sequences in "%s".', $file)); - } - $argument = $this->resolveServices($argument, $file, $isParameter); - try { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument($argument); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException $e) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"!iterator" tag only accepts arrays of "@service" references in "%s".', $file)); - } - } - if ('tagged' === $value->getTag()) { - if (!\is_string($argument) || !$argument) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"!tagged" tag only accepts non empty string in "%s".', $file)); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument($argument); - } - if ('service' === $value->getTag()) { - if ($isParameter) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Using an anonymous service in a parameter is not allowed in "%s".', $file)); - } - $isLoadingInstanceof = $this->isLoadingInstanceof; - $this->isLoadingInstanceof = \false; - $instanceof = $this->instanceof; - $this->instanceof = []; - $id = \sprintf('%d_%s', ++$this->anonymousServicesCount, \preg_replace('/^.*\\\\/', '', isset($argument['class']) ? $argument['class'] : '') . $this->anonymousServicesSuffix); - $this->parseDefinition($id, $argument, $file, []); - if (!$this->container->hasDefinition($id)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Creating an alias using the tag "!service" is not allowed in "%s".', $file)); - } - $this->container->getDefinition($id)->setPublic(\false); - $this->isLoadingInstanceof = $isLoadingInstanceof; - $this->instanceof = $instanceof; - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($id); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Unsupported tag "!%s".', $value->getTag())); - } - if (\is_array($value)) { - foreach ($value as $k => $v) { - $value[$k] = $this->resolveServices($v, $file, $isParameter); - } - } elseif (\is_string($value) && 0 === \strpos($value, '@=')) { - if (!\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression::class)) { - throw new \LogicException(\sprintf('The "@=" expression syntax cannot be used without the ExpressionLanguage component. Try running "composer require symfony/expression-language".')); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression(\substr($value, 2)); - } elseif (\is_string($value) && 0 === \strpos($value, '@')) { - if (0 === \strpos($value, '@@')) { - $value = \substr($value, 1); - $invalidBehavior = null; - } elseif (0 === \strpos($value, '@!')) { - $value = \substr($value, 2); - $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE; - } elseif (0 === \strpos($value, '@?')) { - $value = \substr($value, 2); - $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE; - } else { - $value = \substr($value, 1); - $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE; - } - if ('=' === \substr($value, -1)) { - @\trigger_error(\sprintf('The "=" suffix that used to disable strict references in Symfony 2.x is deprecated since Symfony 3.3 and will be unsupported in 4.0. Remove it in "%s".', $value), \E_USER_DEPRECATED); - $value = \substr($value, 0, -1); - } - if (null !== $invalidBehavior) { - $value = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($value, $invalidBehavior); - } - } - return $value; - } - /** - * Loads from Extensions. - */ - private function loadFromExtensions(array $content) - { - foreach ($content as $namespace => $values) { - if (\in_array($namespace, ['imports', 'parameters', 'services'])) { - continue; - } - if (!\is_array($values) && null !== $values) { - $values = []; - } - $this->container->loadFromExtension($namespace, $values); - } - } - /** - * Checks the keywords used to define a service. - * - * @param string $id The service name - * @param array $definition The service definition to check - * @param string $file The loaded YAML file - */ - private function checkDefinition($id, array $definition, $file) - { - if ($throw = $this->isLoadingInstanceof) { - $keywords = self::$instanceofKeywords; - } elseif ($throw = isset($definition['resource']) || isset($definition['namespace'])) { - $keywords = self::$prototypeKeywords; - } else { - $keywords = self::$serviceKeywords; - } - foreach ($definition as $key => $value) { - if (!isset($keywords[$key])) { - if ($throw) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The configuration key "%s" is unsupported for definition "%s" in "%s". Allowed configuration keys are "%s".', $key, $id, $file, \implode('", "', $keywords))); - } - @\trigger_error(\sprintf('The configuration key "%s" is unsupported for service definition "%s" in "%s". Allowed configuration keys are "%s". The YamlFileLoader object will raise an exception instead in Symfony 4.0 when detecting an unsupported service configuration key.', $key, $id, $file, \implode('", "', $keywords)), \E_USER_DEPRECATED); - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ArgumentInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser as YamlParser; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; +/** + * YamlFileLoader loads YAML files service definitions. + * + * @author Fabien Potencier + */ +class YamlFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader +{ + private static $serviceKeywords = ['alias' => 'alias', 'parent' => 'parent', 'class' => 'class', 'shared' => 'shared', 'synthetic' => 'synthetic', 'lazy' => 'lazy', 'public' => 'public', 'abstract' => 'abstract', 'deprecated' => 'deprecated', 'factory' => 'factory', 'file' => 'file', 'arguments' => 'arguments', 'properties' => 'properties', 'configurator' => 'configurator', 'calls' => 'calls', 'tags' => 'tags', 'decorates' => 'decorates', 'decoration_inner_name' => 'decoration_inner_name', 'decoration_priority' => 'decoration_priority', 'autowire' => 'autowire', 'autowiring_types' => 'autowiring_types', 'autoconfigure' => 'autoconfigure', 'bind' => 'bind']; + private static $prototypeKeywords = ['resource' => 'resource', 'namespace' => 'namespace', 'exclude' => 'exclude', 'parent' => 'parent', 'shared' => 'shared', 'lazy' => 'lazy', 'public' => 'public', 'abstract' => 'abstract', 'deprecated' => 'deprecated', 'factory' => 'factory', 'arguments' => 'arguments', 'properties' => 'properties', 'configurator' => 'configurator', 'calls' => 'calls', 'tags' => 'tags', 'autowire' => 'autowire', 'autoconfigure' => 'autoconfigure', 'bind' => 'bind']; + private static $instanceofKeywords = ['shared' => 'shared', 'lazy' => 'lazy', 'public' => 'public', 'properties' => 'properties', 'configurator' => 'configurator', 'calls' => 'calls', 'tags' => 'tags', 'autowire' => 'autowire']; + private static $defaultsKeywords = ['public' => 'public', 'tags' => 'tags', 'autowire' => 'autowire', 'autoconfigure' => 'autoconfigure', 'bind' => 'bind']; + private $yamlParser; + private $anonymousServicesCount; + private $anonymousServicesSuffix; + /** + * {@inheritdoc} + */ + public function load($resource, $type = null) + { + $path = $this->locator->locate($resource); + $content = $this->loadFile($path); + $this->container->fileExists($path); + // empty file + if (null === $content) { + return; + } + // imports + $this->parseImports($content, $path); + // parameters + if (isset($content['parameters'])) { + if (!\is_array($content['parameters'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The "parameters" key should contain an array in "%s". Check your YAML syntax.', $path)); + } + foreach ($content['parameters'] as $key => $value) { + $this->container->setParameter($key, $this->resolveServices($value, $path, \true)); + } + } + // extensions + $this->loadFromExtensions($content); + // services + $this->anonymousServicesCount = 0; + $this->anonymousServicesSuffix = '~' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::hash($path); + $this->setCurrentDir(\dirname($path)); + try { + $this->parseDefinitions($content, $path); + } finally { + $this->instanceof = []; + } + } + /** + * {@inheritdoc} + */ + public function supports($resource, $type = null) + { + if (!\is_string($resource)) { + return \false; + } + if (null === $type && \in_array(\pathinfo($resource, \PATHINFO_EXTENSION), ['yaml', 'yml'], \true)) { + return \true; + } + return \in_array($type, ['yaml', 'yml'], \true); + } + /** + * Parses all imports. + * + * @param string $file + */ + private function parseImports(array $content, $file) + { + if (!isset($content['imports'])) { + return; + } + if (!\is_array($content['imports'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The "imports" key should contain an array in "%s". Check your YAML syntax.', $file)); + } + $defaultDirectory = \dirname($file); + foreach ($content['imports'] as $import) { + if (!\is_array($import)) { + $import = ['resource' => $import]; + } + if (!isset($import['resource'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('An import should provide a resource in "%s". Check your YAML syntax.', $file)); + } + $this->setCurrentDir($defaultDirectory); + $this->import($import['resource'], isset($import['type']) ? $import['type'] : null, isset($import['ignore_errors']) ? (bool) $import['ignore_errors'] : \false, $file); + } + } + /** + * Parses definitions. + * + * @param string $file + */ + private function parseDefinitions(array $content, $file) + { + if (!isset($content['services'])) { + return; + } + if (!\is_array($content['services'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The "services" key should contain an array in "%s". Check your YAML syntax.', $file)); + } + if (\array_key_exists('_instanceof', $content['services'])) { + $instanceof = $content['services']['_instanceof']; + unset($content['services']['_instanceof']); + if (!\is_array($instanceof)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service "_instanceof" key must be an array, "%s" given in "%s".', \gettype($instanceof), $file)); + } + $this->instanceof = []; + $this->isLoadingInstanceof = \true; + foreach ($instanceof as $id => $service) { + if (!$service || !\is_array($service)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Type definition "%s" must be a non-empty array within "_instanceof" in "%s". Check your YAML syntax.', $id, $file)); + } + if (\is_string($service) && 0 === \strpos($service, '@')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Type definition "%s" cannot be an alias within "_instanceof" in "%s". Check your YAML syntax.', $id, $file)); + } + $this->parseDefinition($id, $service, $file, []); + } + } + $this->isLoadingInstanceof = \false; + $defaults = $this->parseDefaults($content, $file); + foreach ($content['services'] as $id => $service) { + $this->parseDefinition($id, $service, $file, $defaults); + } + } + /** + * @param string $file + * + * @return array + * + * @throws InvalidArgumentException + */ + private function parseDefaults(array &$content, $file) + { + if (!\array_key_exists('_defaults', $content['services'])) { + return []; + } + $defaults = $content['services']['_defaults']; + unset($content['services']['_defaults']); + if (!\is_array($defaults)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Service "_defaults" key must be an array, "%s" given in "%s".', \gettype($defaults), $file)); + } + foreach ($defaults as $key => $default) { + if (!isset(self::$defaultsKeywords[$key])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The configuration key "%s" cannot be used to define a default value in "%s". Allowed keys are "%s".', $key, $file, \implode('", "', self::$defaultsKeywords))); + } + } + if (isset($defaults['tags'])) { + if (!\is_array($tags = $defaults['tags'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "tags" in "_defaults" must be an array in "%s". Check your YAML syntax.', $file)); + } + foreach ($tags as $tag) { + if (!\is_array($tag)) { + $tag = ['name' => $tag]; + } + if (!isset($tag['name'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "tags" entry in "_defaults" is missing a "name" key in "%s".', $file)); + } + $name = $tag['name']; + unset($tag['name']); + if (!\is_string($name) || '' === $name) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The tag name in "_defaults" must be a non-empty string in "%s".', $file)); + } + foreach ($tag as $attribute => $value) { + if (!\is_scalar($value) && null !== $value) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Tag "%s", attribute "%s" in "_defaults" must be of a scalar-type in "%s". Check your YAML syntax.', $name, $attribute, $file)); + } + } + } + } + if (isset($defaults['bind'])) { + if (!\is_array($defaults['bind'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "bind" in "_defaults" must be an array in "%s". Check your YAML syntax.', $file)); + } + $defaults['bind'] = \array_map(function ($v) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument($v); + }, $this->resolveServices($defaults['bind'], $file)); + } + return $defaults; + } + /** + * @return bool + */ + private function isUsingShortSyntax(array $service) + { + foreach ($service as $key => $value) { + if (\is_string($key) && ('' === $key || '$' !== $key[0])) { + return \false; + } + } + return \true; + } + /** + * Parses a definition. + * + * @param string $id + * @param array|string $service + * @param string $file + * + * @throws InvalidArgumentException When tags are invalid + */ + private function parseDefinition($id, $service, $file, array $defaults) + { + if (\preg_match('/^_[a-zA-Z0-9_]*$/', $id)) { + @\trigger_error(\sprintf('Service names that start with an underscore are deprecated since Symfony 3.3 and will be reserved in 4.0. Rename the "%s" service or define it in XML instead.', $id), \E_USER_DEPRECATED); + } + if (\is_string($service) && 0 === \strpos($service, '@')) { + $this->container->setAlias($id, $alias = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias(\substr($service, 1))); + if (isset($defaults['public'])) { + $alias->setPublic($defaults['public']); + } + return; + } + if (\is_array($service) && $this->isUsingShortSyntax($service)) { + $service = ['arguments' => $service]; + } + if (null === $service) { + $service = []; + } + if (!\is_array($service)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A service definition must be an array or a string starting with "@" but "%s" found for service "%s" in "%s". Check your YAML syntax.', \gettype($service), $id, $file)); + } + $this->checkDefinition($id, $service, $file); + if (isset($service['alias'])) { + $this->container->setAlias($id, $alias = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias($service['alias'])); + if (\array_key_exists('public', $service)) { + $alias->setPublic($service['public']); + } elseif (isset($defaults['public'])) { + $alias->setPublic($defaults['public']); + } + foreach ($service as $key => $value) { + if (!\in_array($key, ['alias', 'public'])) { + @\trigger_error(\sprintf('The configuration key "%s" is unsupported for the service "%s" which is defined as an alias in "%s". Allowed configuration keys for service aliases are "alias" and "public". The YamlFileLoader will raise an exception in Symfony 4.0, instead of silently ignoring unsupported attributes.', $key, $id, $file), \E_USER_DEPRECATED); + } + } + return; + } + if ($this->isLoadingInstanceof) { + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''); + } elseif (isset($service['parent'])) { + if (!empty($this->instanceof)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot use the "parent" option in the same file where "_instanceof" configuration is defined as using both is not supported. Move your child definitions to a separate file.', $id)); + } + foreach ($defaults as $k => $v) { + if ('tags' === $k) { + // since tags are never inherited from parents, there is no confusion + // thus we can safely add them as defaults to ChildDefinition + continue; + } + if ('bind' === $k) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Attribute "bind" on service "%s" cannot be inherited from "_defaults" when a "parent" is set. Move your child definitions to a separate file.', $id)); + } + if (!isset($service[$k])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Attribute "%s" on service "%s" cannot be inherited from "_defaults" when a "parent" is set. Move your child definitions to a separate file or define this attribute explicitly.', $k, $id)); + } + } + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition($service['parent']); + } else { + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + if (isset($defaults['public'])) { + $definition->setPublic($defaults['public']); + } + if (isset($defaults['autowire'])) { + $definition->setAutowired($defaults['autowire']); + } + if (isset($defaults['autoconfigure'])) { + $definition->setAutoconfigured($defaults['autoconfigure']); + } + $definition->setChanges([]); + } + if (isset($service['class'])) { + $definition->setClass($service['class']); + } + if (isset($service['shared'])) { + $definition->setShared($service['shared']); + } + if (isset($service['synthetic'])) { + $definition->setSynthetic($service['synthetic']); + } + if (isset($service['lazy'])) { + $definition->setLazy($service['lazy']); + } + if (isset($service['public'])) { + $definition->setPublic($service['public']); + } + if (isset($service['abstract'])) { + $definition->setAbstract($service['abstract']); + } + if (\array_key_exists('deprecated', $service)) { + $definition->setDeprecated(\true, $service['deprecated']); + } + if (isset($service['factory'])) { + $definition->setFactory($this->parseCallable($service['factory'], 'factory', $id, $file)); + } + if (isset($service['file'])) { + $definition->setFile($service['file']); + } + if (isset($service['arguments'])) { + $definition->setArguments($this->resolveServices($service['arguments'], $file)); + } + if (isset($service['properties'])) { + $definition->setProperties($this->resolveServices($service['properties'], $file)); + } + if (isset($service['configurator'])) { + $definition->setConfigurator($this->parseCallable($service['configurator'], 'configurator', $id, $file)); + } + if (isset($service['calls'])) { + if (!\is_array($service['calls'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "calls" must be an array for service "%s" in "%s". Check your YAML syntax.', $id, $file)); + } + foreach ($service['calls'] as $call) { + if (isset($call['method'])) { + $method = $call['method']; + $args = isset($call['arguments']) ? $this->resolveServices($call['arguments'], $file) : []; + } else { + $method = $call[0]; + $args = isset($call[1]) ? $this->resolveServices($call[1], $file) : []; + } + if (!\is_array($args)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The second parameter for function call "%s" must be an array of its arguments for service "%s" in "%s". Check your YAML syntax.', $method, $id, $file)); + } + $definition->addMethodCall($method, $args); + } + } + $tags = isset($service['tags']) ? $service['tags'] : []; + if (!\is_array($tags)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "tags" must be an array for service "%s" in "%s". Check your YAML syntax.', $id, $file)); + } + if (isset($defaults['tags'])) { + $tags = \array_merge($tags, $defaults['tags']); + } + foreach ($tags as $tag) { + if (!\is_array($tag)) { + $tag = ['name' => $tag]; + } + if (!isset($tag['name'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "tags" entry is missing a "name" key for service "%s" in "%s".', $id, $file)); + } + $name = $tag['name']; + unset($tag['name']); + if (!\is_string($name) || '' === $name) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The tag name for service "%s" in "%s" must be a non-empty string.', $id, $file)); + } + foreach ($tag as $attribute => $value) { + if (!\is_scalar($value) && null !== $value) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "tags" attribute must be of a scalar-type for service "%s", tag "%s", attribute "%s" in "%s". Check your YAML syntax.', $id, $name, $attribute, $file)); + } + } + $definition->addTag($name, $tag); + } + if (isset($service['decorates'])) { + if ('' !== $service['decorates'] && '@' === $service['decorates'][0]) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The value of the "decorates" option for the "%s" service must be the id of the service without the "@" prefix (replace "%s" with "%s").', $id, $service['decorates'], \substr($service['decorates'], 1))); + } + $renameId = isset($service['decoration_inner_name']) ? $service['decoration_inner_name'] : null; + $priority = isset($service['decoration_priority']) ? $service['decoration_priority'] : 0; + $definition->setDecoratedService($service['decorates'], $renameId, $priority); + } + if (isset($service['autowire'])) { + $definition->setAutowired($service['autowire']); + } + if (isset($service['autowiring_types'])) { + if (\is_string($service['autowiring_types'])) { + $definition->addAutowiringType($service['autowiring_types']); + } else { + if (!\is_array($service['autowiring_types'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "autowiring_types" must be a string or an array for service "%s" in "%s". Check your YAML syntax.', $id, $file)); + } + foreach ($service['autowiring_types'] as $autowiringType) { + if (!\is_string($autowiringType)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "autowiring_types" attribute must be of type string for service "%s" in "%s". Check your YAML syntax.', $id, $file)); + } + $definition->addAutowiringType($autowiringType); + } + } + } + if (isset($defaults['bind']) || isset($service['bind'])) { + // deep clone, to avoid multiple process of the same instance in the passes + $bindings = isset($defaults['bind']) ? \unserialize(\serialize($defaults['bind'])) : []; + if (isset($service['bind'])) { + if (!\is_array($service['bind'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "bind" must be an array for service "%s" in "%s". Check your YAML syntax.', $id, $file)); + } + $bindings = \array_merge($bindings, $this->resolveServices($service['bind'], $file)); + } + $definition->setBindings($bindings); + } + if (isset($service['autoconfigure'])) { + if (!$definition instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition) { + $definition->setAutoconfigured($service['autoconfigure']); + } elseif ($service['autoconfigure']) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service "%s" cannot have a "parent" and also have "autoconfigure". Try setting "autoconfigure: false" for the service.', $id)); + } + } + if (\array_key_exists('namespace', $service) && !\array_key_exists('resource', $service)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "resource" attribute must be set when the "namespace" attribute is set for service "%s" in "%s". Check your YAML syntax.', $id, $file)); + } + if (\array_key_exists('resource', $service)) { + if (!\is_string($service['resource'])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('A "resource" attribute must be of type string for service "%s" in "%s". Check your YAML syntax.', $id, $file)); + } + $exclude = isset($service['exclude']) ? $service['exclude'] : null; + $namespace = isset($service['namespace']) ? $service['namespace'] : $id; + $this->registerClasses($definition, $namespace, $service['resource'], $exclude); + } else { + $this->setDefinition($id, $definition); + } + } + /** + * Parses a callable. + * + * @param string|array $callable A callable + * @param string $parameter A parameter (e.g. 'factory' or 'configurator') + * @param string $id A service identifier + * @param string $file A parsed file + * + * @throws InvalidArgumentException When errors occur + * + * @return string|array A parsed callable + */ + private function parseCallable($callable, $parameter, $id, $file) + { + if (\is_string($callable)) { + if ('' !== $callable && '@' === $callable[0]) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The value of the "%s" option for the "%s" service must be the id of the service without the "@" prefix (replace "%s" with "%s").', $parameter, $id, $callable, \substr($callable, 1))); + } + if (\false !== \strpos($callable, ':') && \false === \strpos($callable, '::')) { + $parts = \explode(':', $callable); + return [$this->resolveServices('@' . $parts[0], $file), $parts[1]]; + } + return $callable; + } + if (\is_array($callable)) { + if (isset($callable[0]) && isset($callable[1])) { + return [$this->resolveServices($callable[0], $file), $callable[1]]; + } + if ('factory' === $parameter && isset($callable[1]) && null === $callable[0]) { + return $callable; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "%s" must contain an array with two elements for service "%s" in "%s". Check your YAML syntax.', $parameter, $id, $file)); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Parameter "%s" must be a string or an array for service "%s" in "%s". Check your YAML syntax.', $parameter, $id, $file)); + } + /** + * Loads a YAML file. + * + * @param string $file + * + * @return array The file content + * + * @throws InvalidArgumentException when the given file is not a local file or when it does not exist + */ + protected function loadFile($file) + { + if (!\class_exists('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Parser')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException('Unable to load YAML config files as the Symfony Yaml Component is not installed.'); + } + if (!\stream_is_local($file)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('This is not a local file "%s".', $file)); + } + if (!\file_exists($file)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The file "%s" does not exist.', $file)); + } + if (null === $this->yamlParser) { + $this->yamlParser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); + } + $prevErrorHandler = \set_error_handler(function ($level, $message, $script, $line) use($file, &$prevErrorHandler) { + $message = \E_USER_DEPRECATED === $level ? \preg_replace('/ on line \\d+/', ' in "' . $file . '"$0', $message) : $message; + return $prevErrorHandler ? $prevErrorHandler($level, $message, $script, $line) : \false; + }); + try { + $configuration = $this->yamlParser->parseFile($file, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT | \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The file "%s" does not contain valid YAML: %s.', $file, $e->getMessage()), 0, $e); + } finally { + \restore_error_handler(); + } + return $this->validate($configuration, $file); + } + /** + * Validates a YAML file. + * + * @param mixed $content + * @param string $file + * + * @return array + * + * @throws InvalidArgumentException When service file is not valid + */ + private function validate($content, $file) + { + if (null === $content) { + return $content; + } + if (!\is_array($content)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The service file "%s" is not valid. It should contain an array. Check your YAML syntax.', $file)); + } + foreach ($content as $namespace => $data) { + if (\in_array($namespace, ['imports', 'parameters', 'services'])) { + continue; + } + if (!$this->container->hasExtension($namespace)) { + $extensionNamespaces = \array_filter(\array_map(function ($ext) { + return $ext->getAlias(); + }, $this->container->getExtensions())); + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('There is no extension able to load the configuration for "%s" (in "%s"). Looked for namespace "%s", found "%s".', $namespace, $file, $namespace, $extensionNamespaces ? \sprintf('"%s"', \implode('", "', $extensionNamespaces)) : 'none')); + } + } + return $content; + } + /** + * Resolves services. + * + * @param mixed $value + * @param string $file + * @param bool $isParameter + * + * @return array|string|Reference|ArgumentInterface + */ + private function resolveServices($value, $file, $isParameter = \false) + { + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue) { + $argument = $value->getValue(); + if ('iterator' === $value->getTag()) { + if (!\is_array($argument)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"!iterator" tag only accepts sequences in "%s".', $file)); + } + $argument = $this->resolveServices($argument, $file, $isParameter); + try { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument($argument); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException $e) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"!iterator" tag only accepts arrays of "@service" references in "%s".', $file)); + } + } + if ('tagged' === $value->getTag()) { + if (!\is_string($argument) || !$argument) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('"!tagged" tag only accepts non empty string in "%s".', $file)); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument($argument); + } + if ('service' === $value->getTag()) { + if ($isParameter) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Using an anonymous service in a parameter is not allowed in "%s".', $file)); + } + $isLoadingInstanceof = $this->isLoadingInstanceof; + $this->isLoadingInstanceof = \false; + $instanceof = $this->instanceof; + $this->instanceof = []; + $id = \sprintf('%d_%s', ++$this->anonymousServicesCount, \preg_replace('/^.*\\\\/', '', isset($argument['class']) ? $argument['class'] : '') . $this->anonymousServicesSuffix); + $this->parseDefinition($id, $argument, $file, []); + if (!$this->container->hasDefinition($id)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Creating an alias using the tag "!service" is not allowed in "%s".', $file)); + } + $this->container->getDefinition($id)->setPublic(\false); + $this->isLoadingInstanceof = $isLoadingInstanceof; + $this->instanceof = $instanceof; + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($id); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Unsupported tag "!%s".', $value->getTag())); + } + if (\is_array($value)) { + foreach ($value as $k => $v) { + $value[$k] = $this->resolveServices($v, $file, $isParameter); + } + } elseif (\is_string($value) && 0 === \strpos($value, '@=')) { + if (!\class_exists(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression::class)) { + throw new \LogicException(\sprintf('The "@=" expression syntax cannot be used without the ExpressionLanguage component. Try running "composer require symfony/expression-language".')); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression(\substr($value, 2)); + } elseif (\is_string($value) && 0 === \strpos($value, '@')) { + if (0 === \strpos($value, '@@')) { + $value = \substr($value, 1); + $invalidBehavior = null; + } elseif (0 === \strpos($value, '@!')) { + $value = \substr($value, 2); + $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE; + } elseif (0 === \strpos($value, '@?')) { + $value = \substr($value, 2); + $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE; + } else { + $value = \substr($value, 1); + $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE; + } + if ('=' === \substr($value, -1)) { + @\trigger_error(\sprintf('The "=" suffix that used to disable strict references in Symfony 2.x is deprecated since Symfony 3.3 and will be unsupported in 4.0. Remove it in "%s".', $value), \E_USER_DEPRECATED); + $value = \substr($value, 0, -1); + } + if (null !== $invalidBehavior) { + $value = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference($value, $invalidBehavior); + } + } + return $value; + } + /** + * Loads from Extensions. + */ + private function loadFromExtensions(array $content) + { + foreach ($content as $namespace => $values) { + if (\in_array($namespace, ['imports', 'parameters', 'services'])) { + continue; + } + if (!\is_array($values) && null !== $values) { + $values = []; + } + $this->container->loadFromExtension($namespace, $values); + } + } + /** + * Checks the keywords used to define a service. + * + * @param string $id The service name + * @param array $definition The service definition to check + * @param string $file The loaded YAML file + */ + private function checkDefinition($id, array $definition, $file) + { + if ($throw = $this->isLoadingInstanceof) { + $keywords = self::$instanceofKeywords; + } elseif ($throw = isset($definition['resource']) || isset($definition['namespace'])) { + $keywords = self::$prototypeKeywords; + } else { + $keywords = self::$serviceKeywords; + } + foreach ($definition as $key => $value) { + if (!isset($keywords[$key])) { + if ($throw) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The configuration key "%s" is unsupported for definition "%s" in "%s". Allowed configuration keys are "%s".', $key, $id, $file, \implode('", "', $keywords))); + } + @\trigger_error(\sprintf('The configuration key "%s" is unsupported for service definition "%s" in "%s". Allowed configuration keys are "%s". The YamlFileLoader object will raise an exception instead in Symfony 4.0 when detecting an unsupported service configuration key.', $key, $id, $file, \implode('", "', $keywords)), \E_USER_DEPRECATED); + } + } + } +} diff --git a/vendor/symfony/dependency-injection/Loader/index.php b/vendor/symfony/dependency-injection/Loader/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Loader/index.php +++ b/vendor/symfony/dependency-injection/Loader/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/schema/dic/index.php b/vendor/symfony/dependency-injection/Loader/schema/dic/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Loader/schema/dic/index.php +++ b/vendor/symfony/dependency-injection/Loader/schema/dic/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/schema/dic/services/index.php b/vendor/symfony/dependency-injection/Loader/schema/dic/services/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Loader/schema/dic/services/index.php +++ b/vendor/symfony/dependency-injection/Loader/schema/dic/services/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Loader/schema/dic/services/services-1.0.xsd b/vendor/symfony/dependency-injection/Loader/schema/dic/services/services-1.0.xsd index 3a55a7df6..f7bad9f19 100644 --- a/vendor/symfony/dependency-injection/Loader/schema/dic/services/services-1.0.xsd +++ b/vendor/symfony/dependency-injection/Loader/schema/dic/services/services-1.0.xsd @@ -1,281 +1,281 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Loader/schema/index.php b/vendor/symfony/dependency-injection/Loader/schema/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Loader/schema/index.php +++ b/vendor/symfony/dependency-injection/Loader/schema/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Parameter.php b/vendor/symfony/dependency-injection/Parameter.php index 56665e46b..a75da0751 100644 --- a/vendor/symfony/dependency-injection/Parameter.php +++ b/vendor/symfony/dependency-injection/Parameter.php @@ -1,35 +1,35 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -/** - * Parameter represents a parameter reference. - * - * @author Fabien Potencier - */ -class Parameter -{ - private $id; - /** - * @param string $id The parameter key - */ - public function __construct($id) - { - $this->id = $id; - } - /** - * @return string The parameter key - */ - public function __toString() - { - return (string) $this->id; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +/** + * Parameter represents a parameter reference. + * + * @author Fabien Potencier + */ +class Parameter +{ + private $id; + /** + * @param string $id The parameter key + */ + public function __construct($id) + { + $this->id = $id; + } + /** + * @return string The parameter key + */ + public function __toString() + { + return (string) $this->id; + } +} diff --git a/vendor/symfony/dependency-injection/ParameterBag/EnvPlaceholderParameterBag.php b/vendor/symfony/dependency-injection/ParameterBag/EnvPlaceholderParameterBag.php index 04d9463a3..072a8f3f4 100644 --- a/vendor/symfony/dependency-injection/ParameterBag/EnvPlaceholderParameterBag.php +++ b/vendor/symfony/dependency-injection/ParameterBag/EnvPlaceholderParameterBag.php @@ -1,108 +1,108 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -/** - * @author Nicolas Grekas - */ -class EnvPlaceholderParameterBag extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag -{ - private $envPlaceholders = []; - private $providedTypes = []; - /** - * {@inheritdoc} - */ - public function get($name) - { - if (0 === \strpos($name, 'env(') && ')' === \substr($name, -1) && 'env()' !== $name) { - $env = \substr($name, 4, -1); - if (isset($this->envPlaceholders[$env])) { - foreach ($this->envPlaceholders[$env] as $placeholder) { - return $placeholder; - // return first result - } - } - if (!\preg_match('/^(?:\\w++:)*+\\w++$/', $env)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid "%s" name: only "word" characters are allowed.', $name)); - } - if ($this->has($name)) { - $defaultValue = parent::get($name); - if (null !== $defaultValue && !\is_scalar($defaultValue)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The default value of an env() parameter must be scalar or null, but "%s" given to "%s".', \gettype($defaultValue), $name)); - } - } - $uniqueName = \md5($name . \uniqid(\mt_rand(), \true)); - $placeholder = \sprintf('env_%s_%s', \str_replace(':', '_', $env), $uniqueName); - $this->envPlaceholders[$env][$placeholder] = $placeholder; - return $placeholder; - } - return parent::get($name); - } - /** - * Returns the map of env vars used in the resolved parameter values to their placeholders. - * - * @return string[][] A map of env var names to their placeholders - */ - public function getEnvPlaceholders() - { - return $this->envPlaceholders; - } - /** - * Merges the env placeholders of another EnvPlaceholderParameterBag. - */ - public function mergeEnvPlaceholders(self $bag) - { - if ($newPlaceholders = $bag->getEnvPlaceholders()) { - $this->envPlaceholders += $newPlaceholders; - foreach ($newPlaceholders as $env => $placeholders) { - $this->envPlaceholders[$env] += $placeholders; - } - } - } - /** - * Maps env prefixes to their corresponding PHP types. - */ - public function setProvidedTypes(array $providedTypes) - { - $this->providedTypes = $providedTypes; - } - /** - * Gets the PHP types corresponding to env() parameter prefixes. - * - * @return string[][] - */ - public function getProvidedTypes() - { - return $this->providedTypes; - } - /** - * {@inheritdoc} - */ - public function resolve() - { - if ($this->resolved) { - return; - } - parent::resolve(); - foreach ($this->envPlaceholders as $env => $placeholders) { - if (!$this->has($name = "env({$env})")) { - continue; - } - if (\is_numeric($default = $this->parameters[$name])) { - $this->parameters[$name] = (string) $default; - } elseif (null !== $default && !\is_scalar($default)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The default value of env parameter "%s" must be scalar or null, "%s" given.', $env, \gettype($default))); - } - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +/** + * @author Nicolas Grekas + */ +class EnvPlaceholderParameterBag extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag +{ + private $envPlaceholders = []; + private $providedTypes = []; + /** + * {@inheritdoc} + */ + public function get($name) + { + if (0 === \strpos($name, 'env(') && ')' === \substr($name, -1) && 'env()' !== $name) { + $env = \substr($name, 4, -1); + if (isset($this->envPlaceholders[$env])) { + foreach ($this->envPlaceholders[$env] as $placeholder) { + return $placeholder; + // return first result + } + } + if (!\preg_match('/^(?:\\w++:)*+\\w++$/', $env)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('Invalid "%s" name: only "word" characters are allowed.', $name)); + } + if ($this->has($name)) { + $defaultValue = parent::get($name); + if (null !== $defaultValue && !\is_scalar($defaultValue)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The default value of an env() parameter must be scalar or null, but "%s" given to "%s".', \gettype($defaultValue), $name)); + } + } + $uniqueName = \md5($name . \uniqid(\mt_rand(), \true)); + $placeholder = \sprintf('env_%s_%s', \str_replace(':', '_', $env), $uniqueName); + $this->envPlaceholders[$env][$placeholder] = $placeholder; + return $placeholder; + } + return parent::get($name); + } + /** + * Returns the map of env vars used in the resolved parameter values to their placeholders. + * + * @return string[][] A map of env var names to their placeholders + */ + public function getEnvPlaceholders() + { + return $this->envPlaceholders; + } + /** + * Merges the env placeholders of another EnvPlaceholderParameterBag. + */ + public function mergeEnvPlaceholders(self $bag) + { + if ($newPlaceholders = $bag->getEnvPlaceholders()) { + $this->envPlaceholders += $newPlaceholders; + foreach ($newPlaceholders as $env => $placeholders) { + $this->envPlaceholders[$env] += $placeholders; + } + } + } + /** + * Maps env prefixes to their corresponding PHP types. + */ + public function setProvidedTypes(array $providedTypes) + { + $this->providedTypes = $providedTypes; + } + /** + * Gets the PHP types corresponding to env() parameter prefixes. + * + * @return string[][] + */ + public function getProvidedTypes() + { + return $this->providedTypes; + } + /** + * {@inheritdoc} + */ + public function resolve() + { + if ($this->resolved) { + return; + } + parent::resolve(); + foreach ($this->envPlaceholders as $env => $placeholders) { + if (!$this->has($name = "env({$env})")) { + continue; + } + if (\is_numeric($default = $this->parameters[$name])) { + $this->parameters[$name] = (string) $default; + } elseif (null !== $default && !\is_scalar($default)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('The default value of env parameter "%s" must be scalar or null, "%s" given.', $env, \gettype($default))); + } + } + } +} diff --git a/vendor/symfony/dependency-injection/ParameterBag/FrozenParameterBag.php b/vendor/symfony/dependency-injection/ParameterBag/FrozenParameterBag.php index c480d1039..dbb0aeb82 100644 --- a/vendor/symfony/dependency-injection/ParameterBag/FrozenParameterBag.php +++ b/vendor/symfony/dependency-injection/ParameterBag/FrozenParameterBag.php @@ -1,62 +1,62 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException; -/** - * Holds read-only parameters. - * - * @author Fabien Potencier - */ -class FrozenParameterBag extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag -{ - /** - * For performance reasons, the constructor assumes that - * all keys are already lowercased. - * - * This is always the case when used internally. - * - * @param array $parameters An array of parameters - */ - public function __construct(array $parameters = []) - { - $this->parameters = $parameters; - $this->resolved = \true; - } - /** - * {@inheritdoc} - */ - public function clear() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call clear() on a frozen ParameterBag.'); - } - /** - * {@inheritdoc} - */ - public function add(array $parameters) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call add() on a frozen ParameterBag.'); - } - /** - * {@inheritdoc} - */ - public function set($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - /** - * {@inheritdoc} - */ - public function remove($name) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call remove() on a frozen ParameterBag.'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException; +/** + * Holds read-only parameters. + * + * @author Fabien Potencier + */ +class FrozenParameterBag extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag +{ + /** + * For performance reasons, the constructor assumes that + * all keys are already lowercased. + * + * This is always the case when used internally. + * + * @param array $parameters An array of parameters + */ + public function __construct(array $parameters = []) + { + $this->parameters = $parameters; + $this->resolved = \true; + } + /** + * {@inheritdoc} + */ + public function clear() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call clear() on a frozen ParameterBag.'); + } + /** + * {@inheritdoc} + */ + public function add(array $parameters) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call add() on a frozen ParameterBag.'); + } + /** + * {@inheritdoc} + */ + public function set($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + /** + * {@inheritdoc} + */ + public function remove($name) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call remove() on a frozen ParameterBag.'); + } +} diff --git a/vendor/symfony/dependency-injection/ParameterBag/ParameterBag.php b/vendor/symfony/dependency-injection/ParameterBag/ParameterBag.php index ac3862db0..5a1353899 100644 --- a/vendor/symfony/dependency-injection/ParameterBag/ParameterBag.php +++ b/vendor/symfony/dependency-injection/ParameterBag/ParameterBag.php @@ -1,263 +1,263 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -/** - * Holds parameters. - * - * @author Fabien Potencier - */ -class ParameterBag implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface -{ - protected $parameters = []; - protected $resolved = \false; - private $normalizedNames = []; - /** - * @param array $parameters An array of parameters - */ - public function __construct(array $parameters = []) - { - $this->add($parameters); - } - /** - * Clears all parameters. - */ - public function clear() - { - $this->parameters = []; - } - /** - * Adds parameters to the service container parameters. - * - * @param array $parameters An array of parameters - */ - public function add(array $parameters) - { - foreach ($parameters as $key => $value) { - $this->set($key, $value); - } - } - /** - * {@inheritdoc} - */ - public function all() - { - return $this->parameters; - } - /** - * {@inheritdoc} - */ - public function get($name) - { - $name = $this->normalizeName($name); - if (!\array_key_exists($name, $this->parameters)) { - if (!$name) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException($name); - } - $alternatives = []; - foreach ($this->parameters as $key => $parameterValue) { - $lev = \levenshtein($name, $key); - if ($lev <= \strlen($name) / 3 || \false !== \strpos($key, $name)) { - $alternatives[] = $key; - } - } - $nonNestedAlternative = null; - if (!\count($alternatives) && \false !== \strpos($name, '.')) { - $namePartsLength = \array_map('strlen', \explode('.', $name)); - $key = \substr($name, 0, -1 * (1 + \array_pop($namePartsLength))); - while (\count($namePartsLength)) { - if ($this->has($key)) { - if (\is_array($this->get($key))) { - $nonNestedAlternative = $key; - } - break; - } - $key = \substr($key, 0, -1 * (1 + \array_pop($namePartsLength))); - } - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException($name, null, null, null, $alternatives, $nonNestedAlternative); - } - return $this->parameters[$name]; - } - /** - * Sets a service container parameter. - * - * @param string $name The parameter name - * @param mixed $value The parameter value - */ - public function set($name, $value) - { - $this->parameters[$this->normalizeName($name)] = $value; - } - /** - * {@inheritdoc} - */ - public function has($name) - { - return \array_key_exists($this->normalizeName($name), $this->parameters); - } - /** - * Removes a parameter. - * - * @param string $name The parameter name - */ - public function remove($name) - { - unset($this->parameters[$this->normalizeName($name)]); - } - /** - * {@inheritdoc} - */ - public function resolve() - { - if ($this->resolved) { - return; - } - $parameters = []; - foreach ($this->parameters as $key => $value) { - try { - $value = $this->resolveValue($value); - $parameters[$key] = $this->unescapeValue($value); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { - $e->setSourceKey($key); - throw $e; - } - } - $this->parameters = $parameters; - $this->resolved = \true; - } - /** - * Replaces parameter placeholders (%name%) by their values. - * - * @param mixed $value A value - * @param array $resolving An array of keys that are being resolved (used internally to detect circular references) - * - * @return mixed The resolved value - * - * @throws ParameterNotFoundException if a placeholder references a parameter that does not exist - * @throws ParameterCircularReferenceException if a circular reference if detected - * @throws RuntimeException when a given parameter has a type problem - */ - public function resolveValue($value, array $resolving = []) - { - if (\is_array($value)) { - $args = []; - foreach ($value as $k => $v) { - $args[\is_string($k) ? $this->resolveValue($k, $resolving) : $k] = $this->resolveValue($v, $resolving); - } - return $args; - } - if (!\is_string($value) || 2 > \strlen($value)) { - return $value; - } - return $this->resolveString($value, $resolving); - } - /** - * Resolves parameters inside a string. - * - * @param string $value The string to resolve - * @param array $resolving An array of keys that are being resolved (used internally to detect circular references) - * - * @return mixed The resolved string - * - * @throws ParameterNotFoundException if a placeholder references a parameter that does not exist - * @throws ParameterCircularReferenceException if a circular reference if detected - * @throws RuntimeException when a given parameter has a type problem - */ - public function resolveString($value, array $resolving = []) - { - // we do this to deal with non string values (Boolean, integer, ...) - // as the preg_replace_callback throw an exception when trying - // a non-string in a parameter value - if (\preg_match('/^%([^%\\s]+)%$/', $value, $match)) { - $key = $match[1]; - $lcKey = \strtolower($key); - // strtolower() to be removed in 4.0 - if (isset($resolving[$lcKey])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException(\array_keys($resolving)); - } - $resolving[$lcKey] = \true; - return $this->resolved ? $this->get($key) : $this->resolveValue($this->get($key), $resolving); - } - return \preg_replace_callback('/%%|%([^%\\s]+)%/', function ($match) use($resolving, $value) { - // skip %% - if (!isset($match[1])) { - return '%%'; - } - $key = $match[1]; - $lcKey = \strtolower($key); - // strtolower() to be removed in 4.0 - if (isset($resolving[$lcKey])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException(\array_keys($resolving)); - } - $resolved = $this->get($key); - if (!\is_string($resolved) && !\is_numeric($resolved)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('A string value must be composed of strings and/or numbers, but found parameter "%s" of type "%s" inside string value "%s".', $key, \gettype($resolved), $value)); - } - $resolved = (string) $resolved; - $resolving[$lcKey] = \true; - return $this->isResolved() ? $resolved : $this->resolveString($resolved, $resolving); - }, $value); - } - public function isResolved() - { - return $this->resolved; - } - /** - * {@inheritdoc} - */ - public function escapeValue($value) - { - if (\is_string($value)) { - return \str_replace('%', '%%', $value); - } - if (\is_array($value)) { - $result = []; - foreach ($value as $k => $v) { - $result[$k] = $this->escapeValue($v); - } - return $result; - } - return $value; - } - /** - * {@inheritdoc} - */ - public function unescapeValue($value) - { - if (\is_string($value)) { - return \str_replace('%%', '%', $value); - } - if (\is_array($value)) { - $result = []; - foreach ($value as $k => $v) { - $result[$k] = $this->unescapeValue($v); - } - return $result; - } - return $value; - } - private function normalizeName($name) - { - if (isset($this->normalizedNames[$normalizedName = \strtolower($name)])) { - $normalizedName = $this->normalizedNames[$normalizedName]; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +/** + * Holds parameters. + * + * @author Fabien Potencier + */ +class ParameterBag implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface +{ + protected $parameters = []; + protected $resolved = \false; + private $normalizedNames = []; + /** + * @param array $parameters An array of parameters + */ + public function __construct(array $parameters = []) + { + $this->add($parameters); + } + /** + * Clears all parameters. + */ + public function clear() + { + $this->parameters = []; + } + /** + * Adds parameters to the service container parameters. + * + * @param array $parameters An array of parameters + */ + public function add(array $parameters) + { + foreach ($parameters as $key => $value) { + $this->set($key, $value); + } + } + /** + * {@inheritdoc} + */ + public function all() + { + return $this->parameters; + } + /** + * {@inheritdoc} + */ + public function get($name) + { + $name = $this->normalizeName($name); + if (!\array_key_exists($name, $this->parameters)) { + if (!$name) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException($name); + } + $alternatives = []; + foreach ($this->parameters as $key => $parameterValue) { + $lev = \levenshtein($name, $key); + if ($lev <= \strlen($name) / 3 || \false !== \strpos($key, $name)) { + $alternatives[] = $key; + } + } + $nonNestedAlternative = null; + if (!\count($alternatives) && \false !== \strpos($name, '.')) { + $namePartsLength = \array_map('strlen', \explode('.', $name)); + $key = \substr($name, 0, -1 * (1 + \array_pop($namePartsLength))); + while (\count($namePartsLength)) { + if ($this->has($key)) { + if (\is_array($this->get($key))) { + $nonNestedAlternative = $key; + } + break; + } + $key = \substr($key, 0, -1 * (1 + \array_pop($namePartsLength))); + } + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException($name, null, null, null, $alternatives, $nonNestedAlternative); + } + return $this->parameters[$name]; + } + /** + * Sets a service container parameter. + * + * @param string $name The parameter name + * @param mixed $value The parameter value + */ + public function set($name, $value) + { + $this->parameters[$this->normalizeName($name)] = $value; + } + /** + * {@inheritdoc} + */ + public function has($name) + { + return \array_key_exists($this->normalizeName($name), $this->parameters); + } + /** + * Removes a parameter. + * + * @param string $name The parameter name + */ + public function remove($name) + { + unset($this->parameters[$this->normalizeName($name)]); + } + /** + * {@inheritdoc} + */ + public function resolve() + { + if ($this->resolved) { + return; + } + $parameters = []; + foreach ($this->parameters as $key => $value) { + try { + $value = $this->resolveValue($value); + $parameters[$key] = $this->unescapeValue($value); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { + $e->setSourceKey($key); + throw $e; + } + } + $this->parameters = $parameters; + $this->resolved = \true; + } + /** + * Replaces parameter placeholders (%name%) by their values. + * + * @param mixed $value A value + * @param array $resolving An array of keys that are being resolved (used internally to detect circular references) + * + * @return mixed The resolved value + * + * @throws ParameterNotFoundException if a placeholder references a parameter that does not exist + * @throws ParameterCircularReferenceException if a circular reference if detected + * @throws RuntimeException when a given parameter has a type problem + */ + public function resolveValue($value, array $resolving = []) + { + if (\is_array($value)) { + $args = []; + foreach ($value as $k => $v) { + $args[\is_string($k) ? $this->resolveValue($k, $resolving) : $k] = $this->resolveValue($v, $resolving); + } + return $args; + } + if (!\is_string($value) || 2 > \strlen($value)) { + return $value; + } + return $this->resolveString($value, $resolving); + } + /** + * Resolves parameters inside a string. + * + * @param string $value The string to resolve + * @param array $resolving An array of keys that are being resolved (used internally to detect circular references) + * + * @return mixed The resolved string + * + * @throws ParameterNotFoundException if a placeholder references a parameter that does not exist + * @throws ParameterCircularReferenceException if a circular reference if detected + * @throws RuntimeException when a given parameter has a type problem + */ + public function resolveString($value, array $resolving = []) + { + // we do this to deal with non string values (Boolean, integer, ...) + // as the preg_replace_callback throw an exception when trying + // a non-string in a parameter value + if (\preg_match('/^%([^%\\s]+)%$/', $value, $match)) { + $key = $match[1]; + $lcKey = \strtolower($key); + // strtolower() to be removed in 4.0 + if (isset($resolving[$lcKey])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException(\array_keys($resolving)); + } + $resolving[$lcKey] = \true; + return $this->resolved ? $this->get($key) : $this->resolveValue($this->get($key), $resolving); + } + return \preg_replace_callback('/%%|%([^%\\s]+)%/', function ($match) use($resolving, $value) { + // skip %% + if (!isset($match[1])) { + return '%%'; + } + $key = $match[1]; + $lcKey = \strtolower($key); + // strtolower() to be removed in 4.0 + if (isset($resolving[$lcKey])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException(\array_keys($resolving)); + } + $resolved = $this->get($key); + if (!\is_string($resolved) && !\is_numeric($resolved)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException(\sprintf('A string value must be composed of strings and/or numbers, but found parameter "%s" of type "%s" inside string value "%s".', $key, \gettype($resolved), $value)); + } + $resolved = (string) $resolved; + $resolving[$lcKey] = \true; + return $this->isResolved() ? $resolved : $this->resolveString($resolved, $resolving); + }, $value); + } + public function isResolved() + { + return $this->resolved; + } + /** + * {@inheritdoc} + */ + public function escapeValue($value) + { + if (\is_string($value)) { + return \str_replace('%', '%%', $value); + } + if (\is_array($value)) { + $result = []; + foreach ($value as $k => $v) { + $result[$k] = $this->escapeValue($v); + } + return $result; + } + return $value; + } + /** + * {@inheritdoc} + */ + public function unescapeValue($value) + { + if (\is_string($value)) { + return \str_replace('%%', '%', $value); + } + if (\is_array($value)) { + $result = []; + foreach ($value as $k => $v) { + $result[$k] = $this->unescapeValue($v); + } + return $result; + } + return $value; + } + private function normalizeName($name) + { + if (isset($this->normalizedNames[$normalizedName = \strtolower($name)])) { + $normalizedName = $this->normalizedNames[$normalizedName]; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } +} diff --git a/vendor/symfony/dependency-injection/ParameterBag/ParameterBagInterface.php b/vendor/symfony/dependency-injection/ParameterBag/ParameterBagInterface.php index c8ca9cfb9..9c750821e 100644 --- a/vendor/symfony/dependency-injection/ParameterBag/ParameterBagInterface.php +++ b/vendor/symfony/dependency-injection/ParameterBag/ParameterBagInterface.php @@ -1,103 +1,103 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; -/** - * ParameterBagInterface. - * - * @author Fabien Potencier - */ -interface ParameterBagInterface -{ - /** - * Clears all parameters. - * - * @throws LogicException if the ParameterBagInterface can not be cleared - */ - public function clear(); - /** - * Adds parameters to the service container parameters. - * - * @param array $parameters An array of parameters - * - * @throws LogicException if the parameter can not be added - */ - public function add(array $parameters); - /** - * Gets the service container parameters. - * - * @return array An array of parameters - */ - public function all(); - /** - * Gets a service container parameter. - * - * @param string $name The parameter name - * - * @return mixed The parameter value - * - * @throws ParameterNotFoundException if the parameter is not defined - */ - public function get($name); - /** - * Removes a parameter. - * - * @param string $name The parameter name - */ - public function remove($name); - /** - * Sets a service container parameter. - * - * @param string $name The parameter name - * @param mixed $value The parameter value - * - * @throws LogicException if the parameter can not be set - */ - public function set($name, $value); - /** - * Returns true if a parameter name is defined. - * - * @param string $name The parameter name - * - * @return bool true if the parameter name is defined, false otherwise - */ - public function has($name); - /** - * Replaces parameter placeholders (%name%) by their values for all parameters. - */ - public function resolve(); - /** - * Replaces parameter placeholders (%name%) by their values. - * - * @param mixed $value A value - * - * @throws ParameterNotFoundException if a placeholder references a parameter that does not exist - */ - public function resolveValue($value); - /** - * Escape parameter placeholders %. - * - * @param mixed $value - * - * @return mixed - */ - public function escapeValue($value); - /** - * Unescape parameter placeholders %. - * - * @param mixed $value - * - * @return mixed - */ - public function unescapeValue($value); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; +/** + * ParameterBagInterface. + * + * @author Fabien Potencier + */ +interface ParameterBagInterface +{ + /** + * Clears all parameters. + * + * @throws LogicException if the ParameterBagInterface can not be cleared + */ + public function clear(); + /** + * Adds parameters to the service container parameters. + * + * @param array $parameters An array of parameters + * + * @throws LogicException if the parameter can not be added + */ + public function add(array $parameters); + /** + * Gets the service container parameters. + * + * @return array An array of parameters + */ + public function all(); + /** + * Gets a service container parameter. + * + * @param string $name The parameter name + * + * @return mixed The parameter value + * + * @throws ParameterNotFoundException if the parameter is not defined + */ + public function get($name); + /** + * Removes a parameter. + * + * @param string $name The parameter name + */ + public function remove($name); + /** + * Sets a service container parameter. + * + * @param string $name The parameter name + * @param mixed $value The parameter value + * + * @throws LogicException if the parameter can not be set + */ + public function set($name, $value); + /** + * Returns true if a parameter name is defined. + * + * @param string $name The parameter name + * + * @return bool true if the parameter name is defined, false otherwise + */ + public function has($name); + /** + * Replaces parameter placeholders (%name%) by their values for all parameters. + */ + public function resolve(); + /** + * Replaces parameter placeholders (%name%) by their values. + * + * @param mixed $value A value + * + * @throws ParameterNotFoundException if a placeholder references a parameter that does not exist + */ + public function resolveValue($value); + /** + * Escape parameter placeholders %. + * + * @param mixed $value + * + * @return mixed + */ + public function escapeValue($value); + /** + * Unescape parameter placeholders %. + * + * @param mixed $value + * + * @return mixed + */ + public function unescapeValue($value); +} diff --git a/vendor/symfony/dependency-injection/ParameterBag/index.php b/vendor/symfony/dependency-injection/ParameterBag/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/ParameterBag/index.php +++ b/vendor/symfony/dependency-injection/ParameterBag/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/README.md b/vendor/symfony/dependency-injection/README.md index cb2d4a11c..08f0a0156 100644 --- a/vendor/symfony/dependency-injection/README.md +++ b/vendor/symfony/dependency-injection/README.md @@ -1,14 +1,14 @@ -DependencyInjection Component -============================= - -The DependencyInjection component allows you to standardize and centralize the -way objects are constructed in your application. - -Resources ---------- - - * [Documentation](https://symfony.com/doc/current/components/dependency_injection.html) - * [Contributing](https://symfony.com/doc/current/contributing/index.html) - * [Report issues](https://github.com/symfony/symfony/issues) and - [send Pull Requests](https://github.com/symfony/symfony/pulls) - in the [main Symfony repository](https://github.com/symfony/symfony) +DependencyInjection Component +============================= + +The DependencyInjection component allows you to standardize and centralize the +way objects are constructed in your application. + +Resources +--------- + + * [Documentation](https://symfony.com/doc/current/components/dependency_injection.html) + * [Contributing](https://symfony.com/doc/current/contributing/index.html) + * [Report issues](https://github.com/symfony/symfony/issues) and + [send Pull Requests](https://github.com/symfony/symfony/pulls) + in the [main Symfony repository](https://github.com/symfony/symfony) diff --git a/vendor/symfony/dependency-injection/Reference.php b/vendor/symfony/dependency-injection/Reference.php index 25772bacb..520c38fa2 100644 --- a/vendor/symfony/dependency-injection/Reference.php +++ b/vendor/symfony/dependency-injection/Reference.php @@ -1,49 +1,49 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -/** - * Reference represents a service reference. - * - * @author Fabien Potencier - */ -class Reference -{ - private $id; - private $invalidBehavior; - /** - * @param string $id The service identifier - * @param int $invalidBehavior The behavior when the service does not exist - * - * @see Container - */ - public function __construct($id, $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE) - { - $this->id = (string) $id; - $this->invalidBehavior = $invalidBehavior; - } - /** - * @return string The service identifier - */ - public function __toString() - { - return $this->id; - } - /** - * Returns the behavior to be used when the service does not exist. - * - * @return int - */ - public function getInvalidBehavior() - { - return $this->invalidBehavior; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +/** + * Reference represents a service reference. + * + * @author Fabien Potencier + */ +class Reference +{ + private $id; + private $invalidBehavior; + /** + * @param string $id The service identifier + * @param int $invalidBehavior The behavior when the service does not exist + * + * @see Container + */ + public function __construct($id, $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE) + { + $this->id = (string) $id; + $this->invalidBehavior = $invalidBehavior; + } + /** + * @return string The service identifier + */ + public function __toString() + { + return $this->id; + } + /** + * Returns the behavior to be used when the service does not exist. + * + * @return int + */ + public function getInvalidBehavior() + { + return $this->invalidBehavior; + } +} diff --git a/vendor/symfony/dependency-injection/ResettableContainerInterface.php b/vendor/symfony/dependency-injection/ResettableContainerInterface.php index f166506cc..52287a95d 100644 --- a/vendor/symfony/dependency-injection/ResettableContainerInterface.php +++ b/vendor/symfony/dependency-injection/ResettableContainerInterface.php @@ -1,30 +1,30 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -/** - * ResettableContainerInterface defines additional resetting functionality - * for containers, allowing to release shared services when the container is - * not needed anymore. - * - * @author Christophe Coevoet - */ -interface ResettableContainerInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface -{ - /** - * Resets shared services from the container. - * - * The container is not intended to be used again after being reset in a normal workflow. This method is - * meant as a way to release references for ref-counting. - * A subsequent call to ContainerInterface::get will recreate a new instance of the shared service. - */ - public function reset(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +/** + * ResettableContainerInterface defines additional resetting functionality + * for containers, allowing to release shared services when the container is + * not needed anymore. + * + * @author Christophe Coevoet + */ +interface ResettableContainerInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface +{ + /** + * Resets shared services from the container. + * + * The container is not intended to be used again after being reset in a normal workflow. This method is + * meant as a way to release references for ref-counting. + * A subsequent call to ContainerInterface::get will recreate a new instance of the shared service. + */ + public function reset(); +} diff --git a/vendor/symfony/dependency-injection/ServiceLocator.php b/vendor/symfony/dependency-injection/ServiceLocator.php index d95019ea6..4e9126f74 100644 --- a/vendor/symfony/dependency-injection/ServiceLocator.php +++ b/vendor/symfony/dependency-injection/ServiceLocator.php @@ -1,127 +1,127 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; -/** - * @author Robin Chalas - * @author Nicolas Grekas - */ -class ServiceLocator implements \_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface -{ - private $factories; - private $loading = []; - private $externalId; - private $container; - /** - * @param callable[] $factories - */ - public function __construct(array $factories) - { - $this->factories = $factories; - } - /** - * {@inheritdoc} - */ - public function has($id) - { - return isset($this->factories[$id]); - } - /** - * {@inheritdoc} - */ - public function get($id) - { - if (!isset($this->factories[$id])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id, \end($this->loading) ?: null, null, [], $this->createServiceNotFoundMessage($id)); - } - if (isset($this->loading[$id])) { - $ids = \array_values($this->loading); - $ids = \array_slice($this->loading, \array_search($id, $ids)); - $ids[] = $id; - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, $ids); - } - $this->loading[$id] = $id; - try { - return $this->factories[$id](); - } finally { - unset($this->loading[$id]); - } - } - public function __invoke($id) - { - return isset($this->factories[$id]) ? $this->get($id) : null; - } - /** - * @internal - */ - public function withContext($externalId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container $container) - { - $locator = clone $this; - $locator->externalId = $externalId; - $locator->container = $container; - return $locator; - } - private function createServiceNotFoundMessage($id) - { - if ($this->loading) { - return \sprintf('The service "%s" has a dependency on a non-existent service "%s". This locator %s', \end($this->loading), $id, $this->formatAlternatives()); - } - $class = \debug_backtrace(\DEBUG_BACKTRACE_PROVIDE_OBJECT | \DEBUG_BACKTRACE_IGNORE_ARGS, 3); - $class = isset($class[2]['object']) ? \get_class($class[2]['object']) : null; - $externalId = $this->externalId ?: $class; - $msg = []; - $msg[] = \sprintf('Service "%s" not found:', $id); - if (!$this->container) { - $class = null; - } elseif ($this->container->has($id) || isset($this->container->getRemovedIds()[$id])) { - $msg[] = 'even though it exists in the app\'s container,'; - } else { - try { - $this->container->get($id); - $class = null; - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException $e) { - if ($e->getAlternatives()) { - $msg[] = \sprintf('did you mean %s? Anyway,', $this->formatAlternatives($e->getAlternatives(), 'or')); - } else { - $class = null; - } - } - } - if ($externalId) { - $msg[] = \sprintf('the container inside "%s" is a smaller service locator that %s', $externalId, $this->formatAlternatives()); - } else { - $msg[] = \sprintf('the current service locator %s', $this->formatAlternatives()); - } - if (!$class) { - // no-op - } elseif (\is_subclass_of($class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class)) { - $msg[] = \sprintf('Unless you need extra laziness, try using dependency injection instead. Otherwise, you need to declare it using "%s::getSubscribedServices()".', \preg_replace('/([^\\\\]++\\\\)++/', '', $class)); - } else { - $msg[] = 'Try using dependency injection instead.'; - } - return \implode(' ', $msg); - } - private function formatAlternatives(array $alternatives = null, $separator = 'and') - { - $format = '"%s"%s'; - if (null === $alternatives) { - if (!($alternatives = \array_keys($this->factories))) { - return 'is empty...'; - } - $format = \sprintf('only knows about the %s service%s.', $format, 1 < \count($alternatives) ? 's' : ''); - } - $last = \array_pop($alternatives); - return \sprintf($format, $alternatives ? \implode('", "', $alternatives) : $last, $alternatives ? \sprintf(' %s "%s"', $separator, $last) : ''); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; +/** + * @author Robin Chalas + * @author Nicolas Grekas + */ +class ServiceLocator implements \_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface +{ + private $factories; + private $loading = []; + private $externalId; + private $container; + /** + * @param callable[] $factories + */ + public function __construct(array $factories) + { + $this->factories = $factories; + } + /** + * {@inheritdoc} + */ + public function has($id) + { + return isset($this->factories[$id]); + } + /** + * {@inheritdoc} + */ + public function get($id) + { + if (!isset($this->factories[$id])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException($id, \end($this->loading) ?: null, null, [], $this->createServiceNotFoundMessage($id)); + } + if (isset($this->loading[$id])) { + $ids = \array_values($this->loading); + $ids = \array_slice($this->loading, \array_search($id, $ids)); + $ids[] = $id; + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException($id, $ids); + } + $this->loading[$id] = $id; + try { + return $this->factories[$id](); + } finally { + unset($this->loading[$id]); + } + } + public function __invoke($id) + { + return isset($this->factories[$id]) ? $this->get($id) : null; + } + /** + * @internal + */ + public function withContext($externalId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container $container) + { + $locator = clone $this; + $locator->externalId = $externalId; + $locator->container = $container; + return $locator; + } + private function createServiceNotFoundMessage($id) + { + if ($this->loading) { + return \sprintf('The service "%s" has a dependency on a non-existent service "%s". This locator %s', \end($this->loading), $id, $this->formatAlternatives()); + } + $class = \debug_backtrace(\DEBUG_BACKTRACE_PROVIDE_OBJECT | \DEBUG_BACKTRACE_IGNORE_ARGS, 3); + $class = isset($class[2]['object']) ? \get_class($class[2]['object']) : null; + $externalId = $this->externalId ?: $class; + $msg = []; + $msg[] = \sprintf('Service "%s" not found:', $id); + if (!$this->container) { + $class = null; + } elseif ($this->container->has($id) || isset($this->container->getRemovedIds()[$id])) { + $msg[] = 'even though it exists in the app\'s container,'; + } else { + try { + $this->container->get($id); + $class = null; + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException $e) { + if ($e->getAlternatives()) { + $msg[] = \sprintf('did you mean %s? Anyway,', $this->formatAlternatives($e->getAlternatives(), 'or')); + } else { + $class = null; + } + } + } + if ($externalId) { + $msg[] = \sprintf('the container inside "%s" is a smaller service locator that %s', $externalId, $this->formatAlternatives()); + } else { + $msg[] = \sprintf('the current service locator %s', $this->formatAlternatives()); + } + if (!$class) { + // no-op + } elseif (\is_subclass_of($class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface::class)) { + $msg[] = \sprintf('Unless you need extra laziness, try using dependency injection instead. Otherwise, you need to declare it using "%s::getSubscribedServices()".', \preg_replace('/([^\\\\]++\\\\)++/', '', $class)); + } else { + $msg[] = 'Try using dependency injection instead.'; + } + return \implode(' ', $msg); + } + private function formatAlternatives(array $alternatives = null, $separator = 'and') + { + $format = '"%s"%s'; + if (null === $alternatives) { + if (!($alternatives = \array_keys($this->factories))) { + return 'is empty...'; + } + $format = \sprintf('only knows about the %s service%s.', $format, 1 < \count($alternatives) ? 's' : ''); + } + $last = \array_pop($alternatives); + return \sprintf($format, $alternatives ? \implode('", "', $alternatives) : $last, $alternatives ? \sprintf(' %s "%s"', $separator, $last) : ''); + } +} diff --git a/vendor/symfony/dependency-injection/ServiceSubscriberInterface.php b/vendor/symfony/dependency-injection/ServiceSubscriberInterface.php index 8c96e72ea..f11407b23 100644 --- a/vendor/symfony/dependency-injection/ServiceSubscriberInterface.php +++ b/vendor/symfony/dependency-injection/ServiceSubscriberInterface.php @@ -1,49 +1,49 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -/** - * A ServiceSubscriber exposes its dependencies via the static {@link getSubscribedServices} method. - * - * The getSubscribedServices method returns an array of service types required by such instances, - * optionally keyed by the service names used internally. Service types that start with an interrogation - * mark "?" are optional, while the other ones are mandatory service dependencies. - * - * The injected service locators SHOULD NOT allow access to any other services not specified by the method. - * - * It is expected that ServiceSubscriber instances consume PSR-11-based service locators internally. - * This interface does not dictate any injection method for these service locators, although constructor - * injection is recommended. - * - * @author Nicolas Grekas - */ -interface ServiceSubscriberInterface -{ - /** - * Returns an array of service types required by such instances, optionally keyed by the service names used internally. - * - * For mandatory dependencies: - * - * * ['logger' => 'Psr\Log\LoggerInterface'] means the objects use the "logger" name - * internally to fetch a service which must implement Psr\Log\LoggerInterface. - * * ['Psr\Log\LoggerInterface'] is a shortcut for - * * ['Psr\Log\LoggerInterface' => 'Psr\Log\LoggerInterface'] - * - * otherwise: - * - * * ['logger' => '?Psr\Log\LoggerInterface'] denotes an optional dependency - * * ['?Psr\Log\LoggerInterface'] is a shortcut for - * * ['Psr\Log\LoggerInterface' => '?Psr\Log\LoggerInterface'] - * - * @return array The required service types, optionally keyed by service names - */ - public static function getSubscribedServices(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +/** + * A ServiceSubscriber exposes its dependencies via the static {@link getSubscribedServices} method. + * + * The getSubscribedServices method returns an array of service types required by such instances, + * optionally keyed by the service names used internally. Service types that start with an interrogation + * mark "?" are optional, while the other ones are mandatory service dependencies. + * + * The injected service locators SHOULD NOT allow access to any other services not specified by the method. + * + * It is expected that ServiceSubscriber instances consume PSR-11-based service locators internally. + * This interface does not dictate any injection method for these service locators, although constructor + * injection is recommended. + * + * @author Nicolas Grekas + */ +interface ServiceSubscriberInterface +{ + /** + * Returns an array of service types required by such instances, optionally keyed by the service names used internally. + * + * For mandatory dependencies: + * + * * ['logger' => 'Psr\Log\LoggerInterface'] means the objects use the "logger" name + * internally to fetch a service which must implement Psr\Log\LoggerInterface. + * * ['Psr\Log\LoggerInterface'] is a shortcut for + * * ['Psr\Log\LoggerInterface' => 'Psr\Log\LoggerInterface'] + * + * otherwise: + * + * * ['logger' => '?Psr\Log\LoggerInterface'] denotes an optional dependency + * * ['?Psr\Log\LoggerInterface'] is a shortcut for + * * ['Psr\Log\LoggerInterface' => '?Psr\Log\LoggerInterface'] + * + * @return array The required service types, optionally keyed by service names + */ + public static function getSubscribedServices(); +} diff --git a/vendor/symfony/dependency-injection/TaggedContainerInterface.php b/vendor/symfony/dependency-injection/TaggedContainerInterface.php index 4b0543344..7027bd882 100644 --- a/vendor/symfony/dependency-injection/TaggedContainerInterface.php +++ b/vendor/symfony/dependency-injection/TaggedContainerInterface.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -/** - * TaggedContainerInterface is the interface implemented when a container knows how to deals with tags. - * - * @author Fabien Potencier - */ -interface TaggedContainerInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface -{ - /** - * Returns service ids for a given tag. - * - * @param string $name The tag name - * - * @return array An array of tags - */ - public function findTaggedServiceIds($name); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +/** + * TaggedContainerInterface is the interface implemented when a container knows how to deals with tags. + * + * @author Fabien Potencier + */ +interface TaggedContainerInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface +{ + /** + * Returns service ids for a given tag. + * + * @param string $name The tag name + * + * @return array An array of tags + */ + public function findTaggedServiceIds($name); +} diff --git a/vendor/symfony/dependency-injection/Tests/Argument/RewindableGeneratorTest.php b/vendor/symfony/dependency-injection/Tests/Argument/RewindableGeneratorTest.php index 554e00f51..ee3dfdfed 100644 --- a/vendor/symfony/dependency-injection/Tests/Argument/RewindableGeneratorTest.php +++ b/vendor/symfony/dependency-injection/Tests/Argument/RewindableGeneratorTest.php @@ -1,44 +1,44 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Argument; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator; -class RewindableGeneratorTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testImplementsCountable() - { - $this->assertInstanceOf(\Countable::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - (yield 1); - }, 1)); - } - public function testCountUsesProvidedValue() - { - $generator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - (yield 1); - }, 3); - $this->assertCount(3, $generator); - } - public function testCountUsesProvidedValueAsCallback() - { - $called = 0; - $generator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - (yield 1); - }, function () use(&$called) { - ++$called; - return 3; - }); - $this->assertSame(0, $called, 'Count callback is called lazily'); - $this->assertCount(3, $generator); - \count($generator); - $this->assertSame(1, $called, 'Count callback is called only once'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Argument; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator; +class RewindableGeneratorTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testImplementsCountable() + { + $this->assertInstanceOf(\Countable::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + (yield 1); + }, 1)); + } + public function testCountUsesProvidedValue() + { + $generator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + (yield 1); + }, 3); + $this->assertCount(3, $generator); + } + public function testCountUsesProvidedValueAsCallback() + { + $called = 0; + $generator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + (yield 1); + }, function () use(&$called) { + ++$called; + return 3; + }); + $this->assertSame(0, $called, 'Count callback is called lazily'); + $this->assertCount(3, $generator); + \count($generator); + $this->assertSame(1, $called, 'Count callback is called only once'); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Argument/index.php b/vendor/symfony/dependency-injection/Tests/Argument/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Argument/index.php +++ b/vendor/symfony/dependency-injection/Tests/Argument/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/ChildDefinitionTest.php b/vendor/symfony/dependency-injection/Tests/ChildDefinitionTest.php index c6bd482fd..b66a2a639 100644 --- a/vendor/symfony/dependency-injection/Tests/ChildDefinitionTest.php +++ b/vendor/symfony/dependency-injection/Tests/ChildDefinitionTest.php @@ -1,116 +1,116 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator; -class ChildDefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructor() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $this->assertSame('foo', $def->getParent()); - $this->assertSame([], $def->getChanges()); - } - /** - * @dataProvider getPropertyTests - */ - public function testSetProperty($property, $changeKey) - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $getter = 'get' . \ucfirst($property); - $setter = 'set' . \ucfirst($property); - $this->assertNull($def->{$getter}()); - $this->assertSame($def, $def->{$setter}('foo')); - $this->assertSame('foo', $def->{$getter}()); - $this->assertSame([$changeKey => \true], $def->getChanges()); - } - public function getPropertyTests() - { - return [['class', 'class'], ['factory', 'factory'], ['configurator', 'configurator'], ['file', 'file']]; - } - public function testSetPublic() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $this->assertTrue($def->isPublic()); - $this->assertSame($def, $def->setPublic(\false)); - $this->assertFalse($def->isPublic()); - $this->assertSame(['public' => \true], $def->getChanges()); - } - public function testSetLazy() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $this->assertFalse($def->isLazy()); - $this->assertSame($def, $def->setLazy(\false)); - $this->assertFalse($def->isLazy()); - $this->assertSame(['lazy' => \true], $def->getChanges()); - } - public function testSetAutowired() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $this->assertFalse($def->isAutowired()); - $this->assertSame($def, $def->setAutowired(\true)); - $this->assertTrue($def->isAutowired()); - $this->assertSame(['autowired' => \true], $def->getChanges()); - } - public function testSetArgument() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $this->assertSame([], $def->getArguments()); - $this->assertSame($def, $def->replaceArgument(0, 'foo')); - $this->assertSame(['index_0' => 'foo'], $def->getArguments()); - } - public function testReplaceArgumentShouldRequireIntegerIndex() - { - $this->expectException('InvalidArgumentException'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $def->replaceArgument('0', 'foo'); - } - public function testReplaceArgument() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $def->setArguments([0 => 'foo', 1 => 'bar']); - $this->assertSame('foo', $def->getArgument(0)); - $this->assertSame('bar', $def->getArgument(1)); - $this->assertSame($def, $def->replaceArgument(1, 'baz')); - $this->assertSame('foo', $def->getArgument(0)); - $this->assertSame('baz', $def->getArgument(1)); - $this->assertSame([0 => 'foo', 1 => 'bar', 'index_1' => 'baz'], $def->getArguments()); - $this->assertSame($def, $def->replaceArgument('$bar', 'val')); - $this->assertSame('val', $def->getArgument('$bar')); - $this->assertSame([0 => 'foo', 1 => 'bar', 'index_1' => 'baz', '$bar' => 'val'], $def->getArguments()); - } - public function testGetArgumentShouldCheckBounds() - { - $this->expectException('OutOfBoundsException'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $def->setArguments([0 => 'foo']); - $def->replaceArgument(0, 'foo'); - $def->getArgument(1); - } - public function testDefinitionDecoratorAliasExistsForBackwardsCompatibility() - { - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo')); - } - public function testCannotCallSetAutoconfigured() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\BadMethodCallException'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $def->setAutoconfigured(\true); - } - public function testCannotCallSetInstanceofConditionals() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\BadMethodCallException'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); - $def->setInstanceofConditionals(['Foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('')]); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator; +class ChildDefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructor() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $this->assertSame('foo', $def->getParent()); + $this->assertSame([], $def->getChanges()); + } + /** + * @dataProvider getPropertyTests + */ + public function testSetProperty($property, $changeKey) + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $getter = 'get' . \ucfirst($property); + $setter = 'set' . \ucfirst($property); + $this->assertNull($def->{$getter}()); + $this->assertSame($def, $def->{$setter}('foo')); + $this->assertSame('foo', $def->{$getter}()); + $this->assertSame([$changeKey => \true], $def->getChanges()); + } + public function getPropertyTests() + { + return [['class', 'class'], ['factory', 'factory'], ['configurator', 'configurator'], ['file', 'file']]; + } + public function testSetPublic() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $this->assertTrue($def->isPublic()); + $this->assertSame($def, $def->setPublic(\false)); + $this->assertFalse($def->isPublic()); + $this->assertSame(['public' => \true], $def->getChanges()); + } + public function testSetLazy() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $this->assertFalse($def->isLazy()); + $this->assertSame($def, $def->setLazy(\false)); + $this->assertFalse($def->isLazy()); + $this->assertSame(['lazy' => \true], $def->getChanges()); + } + public function testSetAutowired() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $this->assertFalse($def->isAutowired()); + $this->assertSame($def, $def->setAutowired(\true)); + $this->assertTrue($def->isAutowired()); + $this->assertSame(['autowired' => \true], $def->getChanges()); + } + public function testSetArgument() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $this->assertSame([], $def->getArguments()); + $this->assertSame($def, $def->replaceArgument(0, 'foo')); + $this->assertSame(['index_0' => 'foo'], $def->getArguments()); + } + public function testReplaceArgumentShouldRequireIntegerIndex() + { + $this->expectException('InvalidArgumentException'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $def->replaceArgument('0', 'foo'); + } + public function testReplaceArgument() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $def->setArguments([0 => 'foo', 1 => 'bar']); + $this->assertSame('foo', $def->getArgument(0)); + $this->assertSame('bar', $def->getArgument(1)); + $this->assertSame($def, $def->replaceArgument(1, 'baz')); + $this->assertSame('foo', $def->getArgument(0)); + $this->assertSame('baz', $def->getArgument(1)); + $this->assertSame([0 => 'foo', 1 => 'bar', 'index_1' => 'baz'], $def->getArguments()); + $this->assertSame($def, $def->replaceArgument('$bar', 'val')); + $this->assertSame('val', $def->getArgument('$bar')); + $this->assertSame([0 => 'foo', 1 => 'bar', 'index_1' => 'baz', '$bar' => 'val'], $def->getArguments()); + } + public function testGetArgumentShouldCheckBounds() + { + $this->expectException('OutOfBoundsException'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $def->setArguments([0 => 'foo']); + $def->replaceArgument(0, 'foo'); + $def->getArgument(1); + } + public function testDefinitionDecoratorAliasExistsForBackwardsCompatibility() + { + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo')); + } + public function testCannotCallSetAutoconfigured() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\BadMethodCallException'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $def->setAutoconfigured(\true); + } + public function testCannotCallSetInstanceofConditionals() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\BadMethodCallException'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo'); + $def->setInstanceofConditionals(['Foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('')]); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/AnalyzeServiceReferencesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/AnalyzeServiceReferencesPassTest.php index 16f18febb..e7a2aa089 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/AnalyzeServiceReferencesPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/AnalyzeServiceReferencesPassTest.php @@ -1,115 +1,115 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class AnalyzeServiceReferencesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->addArgument($ref1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b')->addMethodCall('setA', [$ref2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')]); - $container->register('c')->addArgument($ref3 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'))->addArgument($ref4 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('d')->setProperty('foo', $ref5 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('e')->setConfigurator([$ref6 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), 'methodName']); - $graph = $this->process($container); - $this->assertCount(4, $edges = $graph->getNode('b')->getInEdges()); - $this->assertSame($ref1, $edges[0]->getValue()); - $this->assertSame($ref4, $edges[1]->getValue()); - $this->assertSame($ref5, $edges[2]->getValue()); - $this->assertSame($ref6, $edges[3]->getValue()); - } - public function testProcessMarksEdgesLazyWhenReferencedServiceIsLazy() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->setLazy(\true)->addArgument($ref1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b')->addArgument($ref2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); - $graph = $this->process($container); - $this->assertCount(1, $graph->getNode('b')->getInEdges()); - $this->assertCount(1, $edges = $graph->getNode('a')->getInEdges()); - $this->assertSame($ref2, $edges[0]->getValue()); - $this->assertTrue($edges[0]->isLazy()); - } - public function testProcessMarksEdgesLazyWhenReferencedFromIteratorArgument() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a'); - $container->register('b'); - $container->register('c')->addArgument($ref1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([$ref2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')])); - $graph = $this->process($container); - $this->assertCount(1, $graph->getNode('a')->getInEdges()); - $this->assertCount(1, $graph->getNode('b')->getInEdges()); - $this->assertCount(2, $edges = $graph->getNode('c')->getOutEdges()); - $this->assertSame($ref1, $edges[0]->getValue()); - $this->assertFalse($edges[0]->isLazy()); - $this->assertSame($ref2, $edges[1]->getValue()); - $this->assertTrue($edges[1]->isLazy()); - } - public function testProcessDetectsReferencesFromInlinedDefinitions() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a'); - $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(null, [$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')])); - $graph = $this->process($container); - $this->assertCount(1, $refs = $graph->getNode('a')->getInEdges()); - $this->assertSame($ref, $refs[0]->getValue()); - } - public function testProcessDetectsReferencesFromIteratorArguments() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a'); - $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')])); - $graph = $this->process($container); - $this->assertCount(1, $refs = $graph->getNode('a')->getInEdges()); - $this->assertSame($ref, $refs[0]->getValue()); - } - public function testProcessDetectsReferencesFromInlinedFactoryDefinitions() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a'); - $factory = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $factory->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'), 'a']); - $container->register('b')->addArgument($factory); - $graph = $this->process($container); - $this->assertTrue($graph->hasNode('a')); - $this->assertCount(1, $refs = $graph->getNode('a')->getInEdges()); - } - public function testProcessDoesNotSaveDuplicateReferences() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a'); - $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(null, [$ref1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')]))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(null, [$ref2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')])); - $graph = $this->process($container); - $this->assertCount(2, $graph->getNode('a')->getInEdges()); - } - public function testProcessDetectsFactoryReferences() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setFactory(['stdClass', 'getInstance']); - $container->register('bar', 'stdClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 'getInstance']); - $graph = $this->process($container); - $this->assertTrue($graph->hasNode('foo')); - $this->assertCount(1, $graph->getNode('foo')->getInEdges()); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass()]); - $pass->process($container); - return $container->getCompiler()->getServiceReferenceGraph(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class AnalyzeServiceReferencesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->addArgument($ref1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b')->addMethodCall('setA', [$ref2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')]); + $container->register('c')->addArgument($ref3 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'))->addArgument($ref4 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('d')->setProperty('foo', $ref5 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('e')->setConfigurator([$ref6 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), 'methodName']); + $graph = $this->process($container); + $this->assertCount(4, $edges = $graph->getNode('b')->getInEdges()); + $this->assertSame($ref1, $edges[0]->getValue()); + $this->assertSame($ref4, $edges[1]->getValue()); + $this->assertSame($ref5, $edges[2]->getValue()); + $this->assertSame($ref6, $edges[3]->getValue()); + } + public function testProcessMarksEdgesLazyWhenReferencedServiceIsLazy() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->setLazy(\true)->addArgument($ref1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b')->addArgument($ref2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); + $graph = $this->process($container); + $this->assertCount(1, $graph->getNode('b')->getInEdges()); + $this->assertCount(1, $edges = $graph->getNode('a')->getInEdges()); + $this->assertSame($ref2, $edges[0]->getValue()); + $this->assertTrue($edges[0]->isLazy()); + } + public function testProcessMarksEdgesLazyWhenReferencedFromIteratorArgument() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a'); + $container->register('b'); + $container->register('c')->addArgument($ref1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([$ref2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')])); + $graph = $this->process($container); + $this->assertCount(1, $graph->getNode('a')->getInEdges()); + $this->assertCount(1, $graph->getNode('b')->getInEdges()); + $this->assertCount(2, $edges = $graph->getNode('c')->getOutEdges()); + $this->assertSame($ref1, $edges[0]->getValue()); + $this->assertFalse($edges[0]->isLazy()); + $this->assertSame($ref2, $edges[1]->getValue()); + $this->assertTrue($edges[1]->isLazy()); + } + public function testProcessDetectsReferencesFromInlinedDefinitions() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a'); + $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(null, [$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')])); + $graph = $this->process($container); + $this->assertCount(1, $refs = $graph->getNode('a')->getInEdges()); + $this->assertSame($ref, $refs[0]->getValue()); + } + public function testProcessDetectsReferencesFromIteratorArguments() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a'); + $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')])); + $graph = $this->process($container); + $this->assertCount(1, $refs = $graph->getNode('a')->getInEdges()); + $this->assertSame($ref, $refs[0]->getValue()); + } + public function testProcessDetectsReferencesFromInlinedFactoryDefinitions() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a'); + $factory = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $factory->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'), 'a']); + $container->register('b')->addArgument($factory); + $graph = $this->process($container); + $this->assertTrue($graph->hasNode('a')); + $this->assertCount(1, $refs = $graph->getNode('a')->getInEdges()); + } + public function testProcessDoesNotSaveDuplicateReferences() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a'); + $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(null, [$ref1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')]))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(null, [$ref2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')])); + $graph = $this->process($container); + $this->assertCount(2, $graph->getNode('a')->getInEdges()); + } + public function testProcessDetectsFactoryReferences() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setFactory(['stdClass', 'getInstance']); + $container->register('bar', 'stdClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 'getInstance']); + $graph = $this->process($container); + $this->assertTrue($graph->hasNode('foo')); + $this->assertCount(1, $graph->getNode('foo')->getInEdges()); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass()]); + $pass->process($container); + return $container->getCompiler()->getServiceReferenceGraph(); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/AutoAliasServicePassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/AutoAliasServicePassTest.php index 43e7b1369..ed7a4ca7a 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/AutoAliasServicePassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/AutoAliasServicePassTest.php @@ -1,79 +1,79 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -class AutoAliasServicePassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcessWithMissingParameter() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('example')->addTag('auto_alias', ['format' => '%non_existing%.example']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass(); - $pass->process($container); - } - public function testProcessWithMissingFormat() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('example')->addTag('auto_alias', []); - $container->setParameter('existing', 'mysql'); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass(); - $pass->process($container); - } - public function testProcessWithNonExistingAlias() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassDefault')->addTag('auto_alias', ['format' => '%existing%.example']); - $container->setParameter('existing', 'mysql'); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass(); - $pass->process($container); - $this->assertEquals('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassDefault', $container->getDefinition('example')->getClass()); - } - public function testProcessWithExistingAlias() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassDefault')->addTag('auto_alias', ['format' => '%existing%.example']); - $container->register('mysql.example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassMysql'); - $container->setParameter('existing', 'mysql'); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass(); - $pass->process($container); - $this->assertTrue($container->hasAlias('example')); - $this->assertEquals('mysql.example', $container->getAlias('example')); - $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassMysql', $container->getDefinition('mysql.example')->getClass()); - } - public function testProcessWithManualAlias() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassDefault')->addTag('auto_alias', ['format' => '%existing%.example']); - $container->register('mysql.example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassMysql'); - $container->register('mariadb.example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassMariaDb'); - $container->setAlias('example', 'mariadb.example'); - $container->setParameter('existing', 'mysql'); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass(); - $pass->process($container); - $this->assertTrue($container->hasAlias('example')); - $this->assertEquals('mariadb.example', $container->getAlias('example')); - $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassMariaDb', $container->getDefinition('mariadb.example')->getClass()); - } -} -class ServiceClassDefault -{ -} -class ServiceClassMysql extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassDefault -{ -} -class ServiceClassMariaDb extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassMysql -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +class AutoAliasServicePassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcessWithMissingParameter() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('example')->addTag('auto_alias', ['format' => '%non_existing%.example']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass(); + $pass->process($container); + } + public function testProcessWithMissingFormat() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('example')->addTag('auto_alias', []); + $container->setParameter('existing', 'mysql'); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass(); + $pass->process($container); + } + public function testProcessWithNonExistingAlias() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassDefault')->addTag('auto_alias', ['format' => '%existing%.example']); + $container->setParameter('existing', 'mysql'); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass(); + $pass->process($container); + $this->assertEquals('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassDefault', $container->getDefinition('example')->getClass()); + } + public function testProcessWithExistingAlias() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassDefault')->addTag('auto_alias', ['format' => '%existing%.example']); + $container->register('mysql.example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassMysql'); + $container->setParameter('existing', 'mysql'); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass(); + $pass->process($container); + $this->assertTrue($container->hasAlias('example')); + $this->assertEquals('mysql.example', $container->getAlias('example')); + $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassMysql', $container->getDefinition('mysql.example')->getClass()); + } + public function testProcessWithManualAlias() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassDefault')->addTag('auto_alias', ['format' => '%existing%.example']); + $container->register('mysql.example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassMysql'); + $container->register('mariadb.example', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassMariaDb'); + $container->setAlias('example', 'mariadb.example'); + $container->setParameter('existing', 'mysql'); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutoAliasServicePass(); + $pass->process($container); + $this->assertTrue($container->hasAlias('example')); + $this->assertEquals('mariadb.example', $container->getAlias('example')); + $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\ServiceClassMariaDb', $container->getDefinition('mariadb.example')->getClass()); + } +} +class ServiceClassDefault +{ +} +class ServiceClassMysql extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassDefault +{ +} +class ServiceClassMariaDb extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ServiceClassMysql +{ +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/AutowireExceptionPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/AutowireExceptionPassTest.php index eca212080..d38dcdb17 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/AutowireExceptionPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/AutowireExceptionPassTest.php @@ -1,96 +1,96 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireExceptionPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException; -/** - * @group legacy - */ -class AutowireExceptionPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testThrowsException() - { - $autowirePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::class)->getMock(); - $autowireException = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException('foo_service_id', 'An autowiring exception message'); - $autowirePass->expects($this->any())->method('getAutowiringExceptions')->willReturn([$autowireException]); - $inlinePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass::class)->getMock(); - $inlinePass->expects($this->any())->method('getInlinedServiceIds')->willReturn([]); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo_service_id'); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireExceptionPass($autowirePass, $inlinePass); - try { - $pass->process($container); - $this->fail('->process() should throw the exception if the service id exists'); - } catch (\Exception $e) { - $this->assertSame($autowireException, $e); - } - } - public function testThrowExceptionIfServiceInlined() - { - $autowirePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::class)->getMock(); - $autowireException = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException('a_service', 'An autowiring exception message'); - $autowirePass->expects($this->any())->method('getAutowiringExceptions')->willReturn([$autowireException]); - $inlinePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass::class)->getMock(); - $inlinePass->expects($this->any())->method('getInlinedServiceIds')->willReturn([ - // a_service inlined into b_service - 'a_service' => ['b_service'], - // b_service inlined into c_service - 'b_service' => ['c_service'], - ]); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - // ONLY register c_service in the final container - $container->register('c_service', 'stdClass'); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireExceptionPass($autowirePass, $inlinePass); - try { - $pass->process($container); - $this->fail('->process() should throw the exception if the service id exists'); - } catch (\Exception $e) { - $this->assertSame($autowireException, $e); - } - } - public function testDoNotThrowExceptionIfServiceInlinedButRemoved() - { - $autowirePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::class)->getMock(); - $autowireException = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException('a_service', 'An autowiring exception message'); - $autowirePass->expects($this->any())->method('getAutowiringExceptions')->willReturn([$autowireException]); - $inlinePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass::class)->getMock(); - $inlinePass->expects($this->any())->method('getInlinedServiceIds')->willReturn([ - // a_service inlined into b_service - 'a_service' => ['b_service'], - // b_service inlined into c_service - 'b_service' => ['c_service'], - ]); - // do NOT register c_service in the container - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireExceptionPass($autowirePass, $inlinePass); - $pass->process($container); - // mark the test as passed - $this->assertTrue(\true); - } - public function testNoExceptionIfServiceRemoved() - { - $autowirePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::class)->getMock(); - $autowireException = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException('non_existent_service'); - $autowirePass->expects($this->any())->method('getAutowiringExceptions')->willReturn([$autowireException]); - $inlinePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass::class)->getMock(); - $inlinePass->expects($this->any())->method('getInlinedServiceIds')->willReturn([]); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireExceptionPass($autowirePass, $inlinePass); - $pass->process($container); - // mark the test as passed - $this->assertTrue(\true); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireExceptionPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException; +/** + * @group legacy + */ +class AutowireExceptionPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testThrowsException() + { + $autowirePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::class)->getMock(); + $autowireException = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException('foo_service_id', 'An autowiring exception message'); + $autowirePass->expects($this->any())->method('getAutowiringExceptions')->willReturn([$autowireException]); + $inlinePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass::class)->getMock(); + $inlinePass->expects($this->any())->method('getInlinedServiceIds')->willReturn([]); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo_service_id'); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireExceptionPass($autowirePass, $inlinePass); + try { + $pass->process($container); + $this->fail('->process() should throw the exception if the service id exists'); + } catch (\Exception $e) { + $this->assertSame($autowireException, $e); + } + } + public function testThrowExceptionIfServiceInlined() + { + $autowirePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::class)->getMock(); + $autowireException = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException('a_service', 'An autowiring exception message'); + $autowirePass->expects($this->any())->method('getAutowiringExceptions')->willReturn([$autowireException]); + $inlinePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass::class)->getMock(); + $inlinePass->expects($this->any())->method('getInlinedServiceIds')->willReturn([ + // a_service inlined into b_service + 'a_service' => ['b_service'], + // b_service inlined into c_service + 'b_service' => ['c_service'], + ]); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + // ONLY register c_service in the final container + $container->register('c_service', 'stdClass'); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireExceptionPass($autowirePass, $inlinePass); + try { + $pass->process($container); + $this->fail('->process() should throw the exception if the service id exists'); + } catch (\Exception $e) { + $this->assertSame($autowireException, $e); + } + } + public function testDoNotThrowExceptionIfServiceInlinedButRemoved() + { + $autowirePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::class)->getMock(); + $autowireException = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException('a_service', 'An autowiring exception message'); + $autowirePass->expects($this->any())->method('getAutowiringExceptions')->willReturn([$autowireException]); + $inlinePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass::class)->getMock(); + $inlinePass->expects($this->any())->method('getInlinedServiceIds')->willReturn([ + // a_service inlined into b_service + 'a_service' => ['b_service'], + // b_service inlined into c_service + 'b_service' => ['c_service'], + ]); + // do NOT register c_service in the container + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireExceptionPass($autowirePass, $inlinePass); + $pass->process($container); + // mark the test as passed + $this->assertTrue(\true); + } + public function testNoExceptionIfServiceRemoved() + { + $autowirePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::class)->getMock(); + $autowireException = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException('non_existent_service'); + $autowirePass->expects($this->any())->method('getAutowiringExceptions')->willReturn([$autowireException]); + $inlinePass = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass::class)->getMock(); + $inlinePass->expects($this->any())->method('getInlinedServiceIds')->willReturn([]); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireExceptionPass($autowirePass, $inlinePass); + $pass->process($container); + // mark the test as passed + $this->assertTrue(\true); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/AutowirePassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/AutowirePassTest.php index 149b87dfa..3ae268c86 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/AutowirePassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/AutowirePassTest.php @@ -1,647 +1,647 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\FooVariadic; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; -require_once __DIR__ . '/../Fixtures/includes/autowiring_classes.php'; -/** - * @author Kévin Dunglas - */ -class AutowirePassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $barDefinition = $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class); - $barDefinition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertCount(1, $container->getDefinition('bar')->getArguments()); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, (string) $container->getDefinition('bar')->getArgument(0)); - } - /** - * @requires PHP 5.6 - */ - public function testProcessVariadic() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $definition = $container->register('fooVariadic', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\FooVariadic::class); - $definition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertCount(1, $container->getDefinition('fooVariadic')->getArguments()); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, (string) $container->getDefinition('fooVariadic')->getArgument(0)); - } - /** - * @group legacy - * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. You should alias the "Symfony\Component\DependencyInjection\Tests\Compiler\B" service to "Symfony\Component\DependencyInjection\Tests\Compiler\A" instead. - * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\RuntimeException - * @expectedExceptionMessageInSymfony4 Cannot autowire service "c": argument "$a" of method "Symfony\Component\DependencyInjection\Tests\Compiler\C::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\A" but no such service exists. You should maybe alias this class to the existing "Symfony\Component\DependencyInjection\Tests\Compiler\B" service. - */ - public function testProcessAutowireParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); - $cDefinition = $container->register('c', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\C::class); - $cDefinition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertCount(1, $container->getDefinition('c')->getArguments()); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class, (string) $container->getDefinition('c')->getArgument(0)); - } - /** - * @group legacy - * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. Try changing the type-hint for argument "$a" of method "Symfony\Component\DependencyInjection\Tests\Compiler\C::__construct()" to "Symfony\Component\DependencyInjection\Tests\Compiler\AInterface" instead. - * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\RuntimeException - * @expectedExceptionMessageInSymfony4 Cannot autowire service "c": argument "$a" of method "Symfony\Component\DependencyInjection\Tests\Compiler\C::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\A" but no such service exists. You should maybe alias this class to the existing "Symfony\Component\DependencyInjection\Tests\Compiler\B" service. - */ - public function testProcessLegacyAutowireWithAvailableInterface() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\AInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); - $cDefinition = $container->register('c', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\C::class); - $cDefinition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertCount(1, $container->getDefinition('c')->getArguments()); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class, (string) $container->getDefinition('c')->getArgument(0)); - } - /** - * @group legacy - * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. You should alias the "Symfony\Component\DependencyInjection\Tests\Compiler\F" service to "Symfony\Component\DependencyInjection\Tests\Compiler\DInterface" instead. - * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\RuntimeException - * @expectedExceptionMessageInSymfony4 Cannot autowire service "g": argument "$d" of method "Symfony\Component\DependencyInjection\Tests\Compiler\G::__construct()" references interface "Symfony\Component\DependencyInjection\Tests\Compiler\DInterface" but no such service exists. You should maybe alias this interface to the existing "Symfony\Component\DependencyInjection\Tests\Compiler\F" service. - */ - public function testProcessAutowireInterface() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class); - $gDefinition = $container->register('g', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\G::class); - $gDefinition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertCount(3, $container->getDefinition('g')->getArguments()); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class, (string) $container->getDefinition('g')->getArgument(0)); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class, (string) $container->getDefinition('g')->getArgument(1)); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class, (string) $container->getDefinition('g')->getArgument(2)); - } - public function testCompleteExistingDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('b', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class); - $hDefinition = $container->register('h', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\H::class)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $hDefinition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertCount(2, $container->getDefinition('h')->getArguments()); - $this->assertEquals('b', (string) $container->getDefinition('h')->getArgument(0)); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DInterface::class, (string) $container->getDefinition('h')->getArgument(1)); - } - public function testCompleteExistingDefinitionWithNotDefinedArguments() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class); - $hDefinition = $container->register('h', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\H::class)->addArgument('')->addArgument(''); - $hDefinition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertCount(2, $container->getDefinition('h')->getArguments()); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class, (string) $container->getDefinition('h')->getArgument(0)); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DInterface::class, (string) $container->getDefinition('h')->getArgument(1)); - } - /** - * @group legacy - */ - public function testExceptionsAreStored() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('c1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); - $container->register('c2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); - $container->register('c3', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); - $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CannotBeAutowired::class); - $aDefinition->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(\false); - $pass->process($container); - $this->assertCount(1, $pass->getAutowiringExceptions()); - } - public function testPrivateConstructorThrowsAutowireException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Invalid service "private_service": constructor of class "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\PrivateConstructor" must be public.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->autowire('private_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\PrivateConstructor::class); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(\true); - $pass->process($container); - } - public function testTypeCollision() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Cannot autowire service "a": argument "$collision" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\CannotBeAutowired::__construct()" references interface "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\CollisionInterface" but no such service exists. You should maybe alias this interface to one of these existing services: "c1", "c2", "c3".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('c1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); - $container->register('c2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); - $container->register('c3', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); - $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CannotBeAutowired::class); - $aDefinition->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - public function testTypeNotGuessable() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Cannot autowire service "a": argument "$k" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotGuessableArgument::__construct()" references class "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Foo" but no such service exists. You should maybe alias this class to one of these existing services: "a1", "a2".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register('a2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotGuessableArgument::class); - $aDefinition->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - public function testTypeNotGuessableWithSubclass() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Cannot autowire service "a": argument "$k" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotGuessableArgumentForSubclass::__construct()" references class "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\A" but no such service exists. You should maybe alias this class to one of these existing services: "a1", "a2".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); - $container->register('a2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); - $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotGuessableArgumentForSubclass::class); - $aDefinition->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - public function testTypeNotGuessableNoServicesFound() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Cannot autowire service "a": argument "$collision" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\CannotBeAutowired::__construct()" references interface "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\CollisionInterface" but no such service exists.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CannotBeAutowired::class); - $aDefinition->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - public function testTypeNotGuessableWithTypeSet() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register('a2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotGuessableArgument::class); - $aDefinition->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - $this->assertCount(1, $container->getDefinition('a')->getArguments()); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, (string) $container->getDefinition('a')->getArgument(0)); - } - public function testWithTypeSet() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('c1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); - $container->register('c2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); - $container->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionInterface::class, 'c2'); - $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CannotBeAutowired::class); - $aDefinition->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - $this->assertCount(1, $container->getDefinition('a')->getArguments()); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionInterface::class, (string) $container->getDefinition('a')->getArgument(0)); - } - /** - * @group legacy - * @expectedDeprecation Relying on service auto-registration for type "Symfony\Component\DependencyInjection\Tests\Compiler\Lille" is deprecated since Symfony 3.4 and won't be supported in 4.0. Create a service named "Symfony\Component\DependencyInjection\Tests\Compiler\Lille" instead. - * @expectedDeprecation Relying on service auto-registration for type "Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas" is deprecated since Symfony 3.4 and won't be supported in 4.0. Create a service named "Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas" instead. - */ - public function testCreateDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $coopTilleulsDefinition = $container->register('coop_tilleuls', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\LesTilleuls::class); - $coopTilleulsDefinition->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - $this->assertCount(2, $container->getDefinition('coop_tilleuls')->getArguments()); - $this->assertEquals('_PhpScoper5ea00cc67502b\\autowired.Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Dunglas', $container->getDefinition('coop_tilleuls')->getArgument(0)); - $this->assertEquals('_PhpScoper5ea00cc67502b\\autowired.Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Dunglas', $container->getDefinition('coop_tilleuls')->getArgument(1)); - $dunglasDefinition = $container->getDefinition('_PhpScoper5ea00cc67502b\\autowired.Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Dunglas'); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class, $dunglasDefinition->getClass()); - $this->assertFalse($dunglasDefinition->isPublic()); - $this->assertCount(1, $dunglasDefinition->getArguments()); - $this->assertEquals('_PhpScoper5ea00cc67502b\\autowired.Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Lille', $dunglasDefinition->getArgument(0)); - $lilleDefinition = $container->getDefinition('_PhpScoper5ea00cc67502b\\autowired.Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Lille'); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class, $lilleDefinition->getClass()); - } - public function testResolveParameter() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('class_name', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $barDefinition = $container->register('bar', '%class_name%'); - $barDefinition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, $container->getDefinition('bar')->getArgument(0)); - } - public function testOptionalParameter() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $optDefinition = $container->register('opt', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\OptionalParameter::class); - $optDefinition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $definition = $container->getDefinition('opt'); - $this->assertNull($definition->getArgument(0)); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, $definition->getArgument(1)); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, $definition->getArgument(2)); - } - public function testDontTriggerAutowiring() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertCount(0, $container->getDefinition('bar')->getArguments()); - } - public function testClassNotFoundThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Cannot autowire service "a": argument "$r" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\BadTypeHintedArgument::__construct()" has type "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotARealClass" but this class was not found.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\BadTypeHintedArgument::class); - $aDefinition->setAutowired(\true); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - public function testParentClassNotFoundThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessageRegExp('{^Cannot autowire service "a": argument "\\$r" of method "(Symfony\\\\Component\\\\DependencyInjection\\\\Tests\\\\Compiler\\\\)BadParentTypeHintedArgument::__construct\\(\\)" has type "\\1OptionalServiceClass" but this class is missing a parent class \\(Class "?Symfony\\\\Bug\\\\NotExistClass"? not found}'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\BadParentTypeHintedArgument::class); - $aDefinition->setAutowired(\true); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - /** - * @group legacy - * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. You should rename (or alias) the "foo" service to "Symfony\Component\DependencyInjection\Tests\Compiler\Foo" instead. - * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\AutowiringFailedException - * @expectedExceptionMessageInSymfony4 Cannot autowire service "bar": argument "$foo" of method "Symfony\Component\DependencyInjection\Tests\Compiler\Bar::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\Foo" but this service is abstract. You should maybe alias this class to the existing "foo" service. - */ - public function testDontUseAbstractServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class)->setAbstract(\true); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - } - public function testSomeSpecificArgumentsAreSet() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class); - $container->register('multiple', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArguments::class)->setAutowired(\true)->setArguments([1 => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 3 => ['bar']]); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $definition = $container->getDefinition('multiple'); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArguments::class), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArguments::class), ['bar']], $definition->getArguments()); - } - public function testScalarArgsCannotBeAutowired() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Cannot autowire service "arg_no_type_hint": argument "$bar" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\MultipleArguments::__construct()" is type-hinted "array", you should configure its value explicitly.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class); - $container->register('arg_no_type_hint', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArguments::class)->setArguments([1 => 'foo'])->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - } - public function testNoTypeArgsCannotBeAutowired() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Cannot autowire service "arg_no_type_hint": argument "$foo" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\MultipleArguments::__construct()" has no type-hint, you should configure its value explicitly.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class); - $container->register('arg_no_type_hint', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArguments::class)->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - } - public function testOptionalScalarNotReallyOptionalUsesDefaultValue() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class); - $definition = $container->register('not_really_optional_scalar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalarNotReallyOptional::class)->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertSame('default_val', $definition->getArgument(1)); - } - public function testOptionalScalarArgsDontMessUpOrder() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class); - $container->register('with_optional_scalar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalar::class)->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $definition = $container->getDefinition('with_optional_scalar'); - $this->assertEquals([ - new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalar::class), - // use the default value - 'default_val', - new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class), - ], $definition->getArguments()); - } - public function testOptionalScalarArgsNotPassedIfLast() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class); - $container->register('with_optional_scalar_last', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalarLast::class)->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $definition = $container->getDefinition('with_optional_scalar_last'); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalarLast::class), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalarLast::class)], $definition->getArguments()); - } - public function testOptionalArgsNoRequiredForCoreClasses() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', \SplFileObject::class)->addArgument('foo.txt')->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $definition = $container->getDefinition('foo'); - $this->assertEquals(['foo.txt'], $definition->getArguments()); - } - public function testSetterInjection() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); - // manually configure *one* call, to override autowiring - $container->register('setter_injection', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)->setAutowired(\true)->addMethodCall('setWithCallsConfigured', ['manual_arg1', 'manual_arg2']); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $methodCalls = $container->getDefinition('setter_injection')->getMethodCalls(); - $this->assertEquals(['setWithCallsConfigured', 'setFoo', 'setDependencies', 'setChildMethodWithoutDocBlock'], \array_column($methodCalls, 0)); - // test setWithCallsConfigured args - $this->assertEquals(['manual_arg1', 'manual_arg2'], $methodCalls[0][1]); - // test setFoo args - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)], $methodCalls[1][1]); - } - public function testWithNonExistingSetterAndAutowiring() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Invalid service "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CaseSensitiveClass": method "setLogger()" does not exist.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->setAutowired(\true); - $definition->addMethodCall('setLogger'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - } - public function testExplicitMethodInjection() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); - $container->register('setter_injection', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)->setAutowired(\true)->addMethodCall('notASetter', []); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $methodCalls = $container->getDefinition('setter_injection')->getMethodCalls(); - $this->assertEquals(['notASetter', 'setFoo', 'setDependencies', 'setWithCallsConfigured', 'setChildMethodWithoutDocBlock'], \array_column($methodCalls, 0)); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)], $methodCalls[0][1]); - } - /** - * @group legacy - * @expectedDeprecation Relying on service auto-registration for type "Symfony\Component\DependencyInjection\Tests\Compiler\A" is deprecated since Symfony 3.4 and won't be supported in 4.0. Create a service named "Symfony\Component\DependencyInjection\Tests\Compiler\A" instead. - */ - public function testTypedReference() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)->setProperty('a', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)]); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, $container->getDefinition('autowired.' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class)->getClass()); - } - /** - * @dataProvider getCreateResourceTests - * @group legacy - */ - public function testCreateResourceForClass($className, $isEqual) - { - $startingResource = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::createResourceForClass(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ClassForResource::class)); - $newResource = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::createResourceForClass(new \ReflectionClass(__NAMESPACE__ . '\\' . $className)); - // hack so the objects don't differ by the class name - $startingReflObject = new \ReflectionObject($startingResource); - $reflProp = $startingReflObject->getProperty('class'); - $reflProp->setAccessible(\true); - $reflProp->setValue($startingResource, __NAMESPACE__ . '\\' . $className); - if ($isEqual) { - $this->assertEquals($startingResource, $newResource); - } else { - $this->assertNotEquals($startingResource, $newResource); - } - } - public function getCreateResourceTests() - { - return [['IdenticalClassResource', \true], ['ClassChangedConstructorArgs', \false]]; - } - public function testIgnoreServiceWithClassNotExisting() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('class_not_exist', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\OptionalServiceClass::class); - $barDefinition = $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class); - $barDefinition->setAutowired(\true); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - $this->assertTrue($container->hasDefinition('bar')); - } - public function testSetterInjectionCollisionThrowsException() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('c1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); - $container->register('c2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); - $aDefinition = $container->register('setter_injection_collision', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjectionCollision::class); - $aDefinition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - try { - $pass->process($container); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException $e) { - } - $this->assertNotNull($e); - $this->assertSame('Cannot autowire service "setter_injection_collision": argument "$collision" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\SetterInjectionCollision::setMultipleInstancesForOneArg()" references interface "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\CollisionInterface" but no such service exists. You should maybe alias this interface to one of these existing services: "c1", "c2".', $e->getMessage()); - } - public function testInterfaceWithNoImplementationSuggestToWriteOne() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Cannot autowire service "my_service": argument "$i" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\K::__construct()" references interface "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\IInterface" but no such service exists. Did you create a class that implements this interface?'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $aDefinition = $container->register('my_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\K::class); - $aDefinition->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - /** - * @group legacy - * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. You should rename (or alias) the "foo" service to "Symfony\Component\DependencyInjection\Tests\Compiler\Foo" instead. - * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\AutowiringFailedException - * @expectedExceptionMessageInSymfony4 Cannot autowire service "bar": argument "$foo" of method "Symfony\Component\DependencyInjection\Tests\Compiler\Bar::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\Foo" but no such service exists. You should maybe alias this class to the existing "foo" service. - */ - public function testProcessDoesNotTriggerDeprecations() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('deprecated', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\DeprecatedClass')->setDeprecated(\true); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - $this->assertTrue($container->hasDefinition('deprecated')); - $this->assertTrue($container->hasDefinition('foo')); - $this->assertTrue($container->hasDefinition('bar')); - } - public function testEmptyStringIsKept() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalar::class)->setAutowired(\true)->setArguments(['', '']); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalar::class), '', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class)], $container->getDefinition('foo')->getArguments()); - } - public function testWithFactory() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $definition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class)->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, 'create'])->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class)], $definition->getArguments()); - } - /** - * @dataProvider provideNotWireableCalls - */ - public function testNotWireableCalls($method, $expectedMsg) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $foo = $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotWireable::class)->setAutowired(\true)->addMethodCall('setBar', [])->addMethodCall('setOptionalNotAutowireable', [])->addMethodCall('setOptionalNoTypeHint', [])->addMethodCall('setOptionalArgNoAutowireable', []); - if ($method) { - $foo->addMethodCall($method, []); - } - $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException::class); - $this->expectExceptionMessage($expectedMsg); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); - } - public function provideNotWireableCalls() - { - return [['setNotAutowireable', 'Cannot autowire service "foo": argument "$n" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotWireable::setNotAutowireable()" has type "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotARealClass" but this class was not found.'], ['setDifferentNamespace', 'Cannot autowire service "foo": argument "$n" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotWireable::setDifferentNamespace()" references class "stdClass" but no such service exists. It cannot be auto-registered because it is from a different root namespace.'], [null, 'Invalid service "foo": method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotWireable::setProtectedMethod()" must be public.']]; - } - /** - * @group legacy - * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. Try changing the type-hint for argument "$i" of method "Symfony\Component\DependencyInjection\Tests\Compiler\J::__construct()" to "Symfony\Component\DependencyInjection\Tests\Compiler\IInterface" instead. - * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\AutowiringFailedException - * @expectedExceptionMessageInSymfony4 Cannot autowire service "j": argument "$i" of method "Symfony\Component\DependencyInjection\Tests\Compiler\J::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\I" but no such service exists. Try changing the type-hint to "Symfony\Component\DependencyInjection\Tests\Compiler\IInterface" instead. - */ - public function testByIdAlternative() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IInterface::class, 'i'); - $container->register('i', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\I::class); - $container->register('j', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\J::class)->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - /** - * @group legacy - * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. Try changing the type-hint for "Symfony\Component\DependencyInjection\Tests\Compiler\A" in "Symfony\Component\DependencyInjection\Tests\Compiler\Bar" to "Symfony\Component\DependencyInjection\Tests\Compiler\AInterface" instead. - */ - public function testTypedReferenceDeprecationNotice() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('aClass', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\AInterface::class, 'aClass'); - $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)->setProperty('a', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)]); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - public function testExceptionWhenAliasExists() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Cannot autowire service "j": argument "$i" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\J::__construct()" references class "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\I" but no such service exists. Try changing the type-hint to "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\IInterface" instead.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - // multiple I services... but there *is* IInterface available - $container->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IInterface::class, 'i'); - $container->register('i', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\I::class); - $container->register('i2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\I::class); - // J type-hints against I concretely - $container->register('j', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\J::class)->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - public function testExceptionWhenAliasDoesNotExist() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); - $this->expectExceptionMessage('Cannot autowire service "j": argument "$i" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\J::__construct()" references class "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\I" but no such service exists. You should maybe alias this class to one of these existing services: "i", "i2".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - // multiple I instances... but no IInterface alias - $container->register('i', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\I::class); - $container->register('i2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\I::class); - // J type-hints against I concretely - $container->register('j', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\J::class)->setAutowired(\true); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - } - public function testInlineServicesAreNotCandidates() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(\realpath(__DIR__ . '/../Fixtures/xml'))); - $loader->load('services_inline_not_candidate.xml'); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); - $pass->process($container); - $this->assertSame([], $container->getDefinition('autowired')->getArguments()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\FooVariadic; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; +require_once __DIR__ . '/../Fixtures/includes/autowiring_classes.php'; +/** + * @author Kévin Dunglas + */ +class AutowirePassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $barDefinition = $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class); + $barDefinition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertCount(1, $container->getDefinition('bar')->getArguments()); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, (string) $container->getDefinition('bar')->getArgument(0)); + } + /** + * @requires PHP 5.6 + */ + public function testProcessVariadic() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $definition = $container->register('fooVariadic', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\FooVariadic::class); + $definition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertCount(1, $container->getDefinition('fooVariadic')->getArguments()); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, (string) $container->getDefinition('fooVariadic')->getArgument(0)); + } + /** + * @group legacy + * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. You should alias the "Symfony\Component\DependencyInjection\Tests\Compiler\B" service to "Symfony\Component\DependencyInjection\Tests\Compiler\A" instead. + * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\RuntimeException + * @expectedExceptionMessageInSymfony4 Cannot autowire service "c": argument "$a" of method "Symfony\Component\DependencyInjection\Tests\Compiler\C::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\A" but no such service exists. You should maybe alias this class to the existing "Symfony\Component\DependencyInjection\Tests\Compiler\B" service. + */ + public function testProcessAutowireParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); + $cDefinition = $container->register('c', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\C::class); + $cDefinition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertCount(1, $container->getDefinition('c')->getArguments()); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class, (string) $container->getDefinition('c')->getArgument(0)); + } + /** + * @group legacy + * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. Try changing the type-hint for argument "$a" of method "Symfony\Component\DependencyInjection\Tests\Compiler\C::__construct()" to "Symfony\Component\DependencyInjection\Tests\Compiler\AInterface" instead. + * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\RuntimeException + * @expectedExceptionMessageInSymfony4 Cannot autowire service "c": argument "$a" of method "Symfony\Component\DependencyInjection\Tests\Compiler\C::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\A" but no such service exists. You should maybe alias this class to the existing "Symfony\Component\DependencyInjection\Tests\Compiler\B" service. + */ + public function testProcessLegacyAutowireWithAvailableInterface() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\AInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); + $cDefinition = $container->register('c', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\C::class); + $cDefinition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertCount(1, $container->getDefinition('c')->getArguments()); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class, (string) $container->getDefinition('c')->getArgument(0)); + } + /** + * @group legacy + * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. You should alias the "Symfony\Component\DependencyInjection\Tests\Compiler\F" service to "Symfony\Component\DependencyInjection\Tests\Compiler\DInterface" instead. + * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\RuntimeException + * @expectedExceptionMessageInSymfony4 Cannot autowire service "g": argument "$d" of method "Symfony\Component\DependencyInjection\Tests\Compiler\G::__construct()" references interface "Symfony\Component\DependencyInjection\Tests\Compiler\DInterface" but no such service exists. You should maybe alias this interface to the existing "Symfony\Component\DependencyInjection\Tests\Compiler\F" service. + */ + public function testProcessAutowireInterface() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class); + $gDefinition = $container->register('g', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\G::class); + $gDefinition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertCount(3, $container->getDefinition('g')->getArguments()); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class, (string) $container->getDefinition('g')->getArgument(0)); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class, (string) $container->getDefinition('g')->getArgument(1)); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class, (string) $container->getDefinition('g')->getArgument(2)); + } + public function testCompleteExistingDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('b', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class); + $hDefinition = $container->register('h', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\H::class)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $hDefinition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertCount(2, $container->getDefinition('h')->getArguments()); + $this->assertEquals('b', (string) $container->getDefinition('h')->getArgument(0)); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DInterface::class, (string) $container->getDefinition('h')->getArgument(1)); + } + public function testCompleteExistingDefinitionWithNotDefinedArguments() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\F::class); + $hDefinition = $container->register('h', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\H::class)->addArgument('')->addArgument(''); + $hDefinition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertCount(2, $container->getDefinition('h')->getArguments()); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class, (string) $container->getDefinition('h')->getArgument(0)); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DInterface::class, (string) $container->getDefinition('h')->getArgument(1)); + } + /** + * @group legacy + */ + public function testExceptionsAreStored() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('c1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); + $container->register('c2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); + $container->register('c3', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); + $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CannotBeAutowired::class); + $aDefinition->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(\false); + $pass->process($container); + $this->assertCount(1, $pass->getAutowiringExceptions()); + } + public function testPrivateConstructorThrowsAutowireException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Invalid service "private_service": constructor of class "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\PrivateConstructor" must be public.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->autowire('private_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\PrivateConstructor::class); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(\true); + $pass->process($container); + } + public function testTypeCollision() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Cannot autowire service "a": argument "$collision" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\CannotBeAutowired::__construct()" references interface "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\CollisionInterface" but no such service exists. You should maybe alias this interface to one of these existing services: "c1", "c2", "c3".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('c1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); + $container->register('c2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); + $container->register('c3', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); + $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CannotBeAutowired::class); + $aDefinition->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + public function testTypeNotGuessable() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Cannot autowire service "a": argument "$k" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotGuessableArgument::__construct()" references class "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Foo" but no such service exists. You should maybe alias this class to one of these existing services: "a1", "a2".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register('a2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotGuessableArgument::class); + $aDefinition->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + public function testTypeNotGuessableWithSubclass() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Cannot autowire service "a": argument "$k" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotGuessableArgumentForSubclass::__construct()" references class "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\A" but no such service exists. You should maybe alias this class to one of these existing services: "a1", "a2".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); + $container->register('a2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\B::class); + $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotGuessableArgumentForSubclass::class); + $aDefinition->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + public function testTypeNotGuessableNoServicesFound() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Cannot autowire service "a": argument "$collision" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\CannotBeAutowired::__construct()" references interface "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\CollisionInterface" but no such service exists.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CannotBeAutowired::class); + $aDefinition->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + public function testTypeNotGuessableWithTypeSet() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register('a2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotGuessableArgument::class); + $aDefinition->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + $this->assertCount(1, $container->getDefinition('a')->getArguments()); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, (string) $container->getDefinition('a')->getArgument(0)); + } + public function testWithTypeSet() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('c1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); + $container->register('c2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); + $container->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionInterface::class, 'c2'); + $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CannotBeAutowired::class); + $aDefinition->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + $this->assertCount(1, $container->getDefinition('a')->getArguments()); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionInterface::class, (string) $container->getDefinition('a')->getArgument(0)); + } + /** + * @group legacy + * @expectedDeprecation Relying on service auto-registration for type "Symfony\Component\DependencyInjection\Tests\Compiler\Lille" is deprecated since Symfony 3.4 and won't be supported in 4.0. Create a service named "Symfony\Component\DependencyInjection\Tests\Compiler\Lille" instead. + * @expectedDeprecation Relying on service auto-registration for type "Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas" is deprecated since Symfony 3.4 and won't be supported in 4.0. Create a service named "Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas" instead. + */ + public function testCreateDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $coopTilleulsDefinition = $container->register('coop_tilleuls', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\LesTilleuls::class); + $coopTilleulsDefinition->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + $this->assertCount(2, $container->getDefinition('coop_tilleuls')->getArguments()); + $this->assertEquals('_PhpScoper5ea00cc67502b\\autowired.Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Dunglas', $container->getDefinition('coop_tilleuls')->getArgument(0)); + $this->assertEquals('_PhpScoper5ea00cc67502b\\autowired.Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Dunglas', $container->getDefinition('coop_tilleuls')->getArgument(1)); + $dunglasDefinition = $container->getDefinition('_PhpScoper5ea00cc67502b\\autowired.Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Dunglas'); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class, $dunglasDefinition->getClass()); + $this->assertFalse($dunglasDefinition->isPublic()); + $this->assertCount(1, $dunglasDefinition->getArguments()); + $this->assertEquals('_PhpScoper5ea00cc67502b\\autowired.Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Lille', $dunglasDefinition->getArgument(0)); + $lilleDefinition = $container->getDefinition('_PhpScoper5ea00cc67502b\\autowired.Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\Lille'); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class, $lilleDefinition->getClass()); + } + public function testResolveParameter() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('class_name', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $barDefinition = $container->register('bar', '%class_name%'); + $barDefinition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, $container->getDefinition('bar')->getArgument(0)); + } + public function testOptionalParameter() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $optDefinition = $container->register('opt', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\OptionalParameter::class); + $optDefinition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $definition = $container->getDefinition('opt'); + $this->assertNull($definition->getArgument(0)); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, $definition->getArgument(1)); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, $definition->getArgument(2)); + } + public function testDontTriggerAutowiring() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertCount(0, $container->getDefinition('bar')->getArguments()); + } + public function testClassNotFoundThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Cannot autowire service "a": argument "$r" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\BadTypeHintedArgument::__construct()" has type "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotARealClass" but this class was not found.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\BadTypeHintedArgument::class); + $aDefinition->setAutowired(\true); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + public function testParentClassNotFoundThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessageRegExp('{^Cannot autowire service "a": argument "\\$r" of method "(Symfony\\\\Component\\\\DependencyInjection\\\\Tests\\\\Compiler\\\\)BadParentTypeHintedArgument::__construct\\(\\)" has type "\\1OptionalServiceClass" but this class is missing a parent class \\(Class "?Symfony\\\\Bug\\\\NotExistClass"? not found}'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $aDefinition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\BadParentTypeHintedArgument::class); + $aDefinition->setAutowired(\true); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + /** + * @group legacy + * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. You should rename (or alias) the "foo" service to "Symfony\Component\DependencyInjection\Tests\Compiler\Foo" instead. + * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\AutowiringFailedException + * @expectedExceptionMessageInSymfony4 Cannot autowire service "bar": argument "$foo" of method "Symfony\Component\DependencyInjection\Tests\Compiler\Bar::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\Foo" but this service is abstract. You should maybe alias this class to the existing "foo" service. + */ + public function testDontUseAbstractServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class)->setAbstract(\true); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + } + public function testSomeSpecificArgumentsAreSet() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class); + $container->register('multiple', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArguments::class)->setAutowired(\true)->setArguments([1 => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 3 => ['bar']]); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $definition = $container->getDefinition('multiple'); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArguments::class), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArguments::class), ['bar']], $definition->getArguments()); + } + public function testScalarArgsCannotBeAutowired() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Cannot autowire service "arg_no_type_hint": argument "$bar" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\MultipleArguments::__construct()" is type-hinted "array", you should configure its value explicitly.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class); + $container->register('arg_no_type_hint', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArguments::class)->setArguments([1 => 'foo'])->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + } + public function testNoTypeArgsCannotBeAutowired() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Cannot autowire service "arg_no_type_hint": argument "$foo" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\MultipleArguments::__construct()" has no type-hint, you should configure its value explicitly.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Dunglas::class); + $container->register('arg_no_type_hint', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArguments::class)->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + } + public function testOptionalScalarNotReallyOptionalUsesDefaultValue() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class); + $definition = $container->register('not_really_optional_scalar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalarNotReallyOptional::class)->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertSame('default_val', $definition->getArgument(1)); + } + public function testOptionalScalarArgsDontMessUpOrder() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class); + $container->register('with_optional_scalar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalar::class)->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $definition = $container->getDefinition('with_optional_scalar'); + $this->assertEquals([ + new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalar::class), + // use the default value + 'default_val', + new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class), + ], $definition->getArguments()); + } + public function testOptionalScalarArgsNotPassedIfLast() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class); + $container->register('with_optional_scalar_last', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalarLast::class)->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $definition = $container->getDefinition('with_optional_scalar_last'); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalarLast::class), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalarLast::class)], $definition->getArguments()); + } + public function testOptionalArgsNoRequiredForCoreClasses() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', \SplFileObject::class)->addArgument('foo.txt')->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $definition = $container->getDefinition('foo'); + $this->assertEquals(['foo.txt'], $definition->getArguments()); + } + public function testSetterInjection() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); + // manually configure *one* call, to override autowiring + $container->register('setter_injection', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)->setAutowired(\true)->addMethodCall('setWithCallsConfigured', ['manual_arg1', 'manual_arg2']); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $methodCalls = $container->getDefinition('setter_injection')->getMethodCalls(); + $this->assertEquals(['setWithCallsConfigured', 'setFoo', 'setDependencies', 'setChildMethodWithoutDocBlock'], \array_column($methodCalls, 0)); + // test setWithCallsConfigured args + $this->assertEquals(['manual_arg1', 'manual_arg2'], $methodCalls[0][1]); + // test setFoo args + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)], $methodCalls[1][1]); + } + public function testWithNonExistingSetterAndAutowiring() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Invalid service "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CaseSensitiveClass": method "setLogger()" does not exist.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->setAutowired(\true); + $definition->addMethodCall('setLogger'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + } + public function testExplicitMethodInjection() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); + $container->register('setter_injection', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)->setAutowired(\true)->addMethodCall('notASetter', []); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $methodCalls = $container->getDefinition('setter_injection')->getMethodCalls(); + $this->assertEquals(['notASetter', 'setFoo', 'setDependencies', 'setWithCallsConfigured', 'setChildMethodWithoutDocBlock'], \array_column($methodCalls, 0)); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)], $methodCalls[0][1]); + } + /** + * @group legacy + * @expectedDeprecation Relying on service auto-registration for type "Symfony\Component\DependencyInjection\Tests\Compiler\A" is deprecated since Symfony 3.4 and won't be supported in 4.0. Create a service named "Symfony\Component\DependencyInjection\Tests\Compiler\A" instead. + */ + public function testTypedReference() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)->setProperty('a', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)]); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, $container->getDefinition('autowired.' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class)->getClass()); + } + /** + * @dataProvider getCreateResourceTests + * @group legacy + */ + public function testCreateResourceForClass($className, $isEqual) + { + $startingResource = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::createResourceForClass(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ClassForResource::class)); + $newResource = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::createResourceForClass(new \ReflectionClass(__NAMESPACE__ . '\\' . $className)); + // hack so the objects don't differ by the class name + $startingReflObject = new \ReflectionObject($startingResource); + $reflProp = $startingReflObject->getProperty('class'); + $reflProp->setAccessible(\true); + $reflProp->setValue($startingResource, __NAMESPACE__ . '\\' . $className); + if ($isEqual) { + $this->assertEquals($startingResource, $newResource); + } else { + $this->assertNotEquals($startingResource, $newResource); + } + } + public function getCreateResourceTests() + { + return [['IdenticalClassResource', \true], ['ClassChangedConstructorArgs', \false]]; + } + public function testIgnoreServiceWithClassNotExisting() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('class_not_exist', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\OptionalServiceClass::class); + $barDefinition = $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class); + $barDefinition->setAutowired(\true); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + $this->assertTrue($container->hasDefinition('bar')); + } + public function testSetterInjectionCollisionThrowsException() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('c1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); + $container->register('c2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); + $aDefinition = $container->register('setter_injection_collision', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjectionCollision::class); + $aDefinition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + try { + $pass->process($container); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\AutowiringFailedException $e) { + } + $this->assertNotNull($e); + $this->assertSame('Cannot autowire service "setter_injection_collision": argument "$collision" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\SetterInjectionCollision::setMultipleInstancesForOneArg()" references interface "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\CollisionInterface" but no such service exists. You should maybe alias this interface to one of these existing services: "c1", "c2".', $e->getMessage()); + } + public function testInterfaceWithNoImplementationSuggestToWriteOne() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Cannot autowire service "my_service": argument "$i" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\K::__construct()" references interface "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\IInterface" but no such service exists. Did you create a class that implements this interface?'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $aDefinition = $container->register('my_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\K::class); + $aDefinition->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + /** + * @group legacy + * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. You should rename (or alias) the "foo" service to "Symfony\Component\DependencyInjection\Tests\Compiler\Foo" instead. + * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\AutowiringFailedException + * @expectedExceptionMessageInSymfony4 Cannot autowire service "bar": argument "$foo" of method "Symfony\Component\DependencyInjection\Tests\Compiler\Bar::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\Foo" but no such service exists. You should maybe alias this class to the existing "foo" service. + */ + public function testProcessDoesNotTriggerDeprecations() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('deprecated', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\DeprecatedClass')->setDeprecated(\true); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + $this->assertTrue($container->hasDefinition('deprecated')); + $this->assertTrue($container->hasDefinition('foo')); + $this->assertTrue($container->hasDefinition('bar')); + } + public function testEmptyStringIsKept() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalar::class)->setAutowired(\true)->setArguments(['', '']); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\MultipleArgumentsOptionalScalar::class), '', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Lille::class)], $container->getDefinition('foo')->getArguments()); + } + public function testWithFactory() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $definition = $container->register('a', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class)->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, 'create'])->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class)], $definition->getArguments()); + } + /** + * @dataProvider provideNotWireableCalls + */ + public function testNotWireableCalls($method, $expectedMsg) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $foo = $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotWireable::class)->setAutowired(\true)->addMethodCall('setBar', [])->addMethodCall('setOptionalNotAutowireable', [])->addMethodCall('setOptionalNoTypeHint', [])->addMethodCall('setOptionalArgNoAutowireable', []); + if ($method) { + $foo->addMethodCall($method, []); + } + $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException::class); + $this->expectExceptionMessage($expectedMsg); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass())->process($container); + } + public function provideNotWireableCalls() + { + return [['setNotAutowireable', 'Cannot autowire service "foo": argument "$n" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotWireable::setNotAutowireable()" has type "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotARealClass" but this class was not found.'], ['setDifferentNamespace', 'Cannot autowire service "foo": argument "$n" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotWireable::setDifferentNamespace()" references class "stdClass" but no such service exists. It cannot be auto-registered because it is from a different root namespace.'], [null, 'Invalid service "foo": method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\NotWireable::setProtectedMethod()" must be public.']]; + } + /** + * @group legacy + * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. Try changing the type-hint for argument "$i" of method "Symfony\Component\DependencyInjection\Tests\Compiler\J::__construct()" to "Symfony\Component\DependencyInjection\Tests\Compiler\IInterface" instead. + * @expectedExceptionInSymfony4 \Symfony\Component\DependencyInjection\Exception\AutowiringFailedException + * @expectedExceptionMessageInSymfony4 Cannot autowire service "j": argument "$i" of method "Symfony\Component\DependencyInjection\Tests\Compiler\J::__construct()" references class "Symfony\Component\DependencyInjection\Tests\Compiler\I" but no such service exists. Try changing the type-hint to "Symfony\Component\DependencyInjection\Tests\Compiler\IInterface" instead. + */ + public function testByIdAlternative() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IInterface::class, 'i'); + $container->register('i', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\I::class); + $container->register('j', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\J::class)->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + /** + * @group legacy + * @expectedDeprecation Autowiring services based on the types they implement is deprecated since Symfony 3.3 and won't be supported in version 4.0. Try changing the type-hint for "Symfony\Component\DependencyInjection\Tests\Compiler\A" in "Symfony\Component\DependencyInjection\Tests\Compiler\Bar" to "Symfony\Component\DependencyInjection\Tests\Compiler\AInterface" instead. + */ + public function testTypedReferenceDeprecationNotice() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('aClass', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\AInterface::class, 'aClass'); + $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)->setProperty('a', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Bar::class)]); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + public function testExceptionWhenAliasExists() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Cannot autowire service "j": argument "$i" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\J::__construct()" references class "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\I" but no such service exists. Try changing the type-hint to "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\IInterface" instead.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + // multiple I services... but there *is* IInterface available + $container->setAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IInterface::class, 'i'); + $container->register('i', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\I::class); + $container->register('i2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\I::class); + // J type-hints against I concretely + $container->register('j', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\J::class)->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + public function testExceptionWhenAliasDoesNotExist() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\AutowiringFailedException'); + $this->expectExceptionMessage('Cannot autowire service "j": argument "$i" of method "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\J::__construct()" references class "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\I" but no such service exists. You should maybe alias this class to one of these existing services: "i", "i2".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + // multiple I instances... but no IInterface alias + $container->register('i', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\I::class); + $container->register('i2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\I::class); + // J type-hints against I concretely + $container->register('j', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\J::class)->setAutowired(\true); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + } + public function testInlineServicesAreNotCandidates() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(\realpath(__DIR__ . '/../Fixtures/xml'))); + $loader->load('services_inline_not_candidate.xml'); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass(); + $pass->process($container); + $this->assertSame([], $container->getDefinition('autowired')->getArguments()); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/AutowireRequiredMethodsPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/AutowireRequiredMethodsPassTest.php index c2cc427c9..144832e60 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/AutowireRequiredMethodsPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/AutowireRequiredMethodsPassTest.php @@ -1,52 +1,52 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -require_once __DIR__ . '/../Fixtures/includes/autowiring_classes.php'; -class AutowireRequiredMethodsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testSetterInjection() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); - // manually configure *one* call, to override autowiring - $container->register('setter_injection', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)->setAutowired(\true)->addMethodCall('setWithCallsConfigured', ['manual_arg1', 'manual_arg2']); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); - $methodCalls = $container->getDefinition('setter_injection')->getMethodCalls(); - $this->assertEquals(['setWithCallsConfigured', 'setFoo', 'setDependencies', 'setChildMethodWithoutDocBlock'], \array_column($methodCalls, 0)); - // test setWithCallsConfigured args - $this->assertEquals(['manual_arg1', 'manual_arg2'], $methodCalls[0][1]); - // test setFoo args - $this->assertEquals([], $methodCalls[1][1]); - } - public function testExplicitMethodInjection() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); - $container->register('setter_injection', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)->setAutowired(\true)->addMethodCall('notASetter', []); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); - $methodCalls = $container->getDefinition('setter_injection')->getMethodCalls(); - $this->assertEquals(['notASetter', 'setFoo', 'setDependencies', 'setWithCallsConfigured', 'setChildMethodWithoutDocBlock'], \array_column($methodCalls, 0)); - $this->assertEquals([], $methodCalls[0][1]); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +require_once __DIR__ . '/../Fixtures/includes/autowiring_classes.php'; +class AutowireRequiredMethodsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testSetterInjection() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); + // manually configure *one* call, to override autowiring + $container->register('setter_injection', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)->setAutowired(\true)->addMethodCall('setWithCallsConfigured', ['manual_arg1', 'manual_arg2']); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); + $methodCalls = $container->getDefinition('setter_injection')->getMethodCalls(); + $this->assertEquals(['setWithCallsConfigured', 'setFoo', 'setDependencies', 'setChildMethodWithoutDocBlock'], \array_column($methodCalls, 0)); + // test setWithCallsConfigured args + $this->assertEquals(['manual_arg1', 'manual_arg2'], $methodCalls[0][1]); + // test setFoo args + $this->assertEquals([], $methodCalls[1][1]); + } + public function testExplicitMethodInjection() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\Foo::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionA::class); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CollisionB::class); + $container->register('setter_injection', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SetterInjection::class)->setAutowired(\true)->addMethodCall('notASetter', []); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); + $methodCalls = $container->getDefinition('setter_injection')->getMethodCalls(); + $this->assertEquals(['notASetter', 'setFoo', 'setDependencies', 'setWithCallsConfigured', 'setChildMethodWithoutDocBlock'], \array_column($methodCalls, 0)); + $this->assertEquals([], $methodCalls[0][1]); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/CheckArgumentsValidityPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/CheckArgumentsValidityPassTest.php index 186afd941..9d2c5f5f6 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/CheckArgumentsValidityPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/CheckArgumentsValidityPassTest.php @@ -1,58 +1,58 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckArgumentsValidityPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * @author Kévin Dunglas - */ -class CheckArgumentsValidityPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register('foo'); - $definition->setArguments([null, 1, 'a']); - $definition->setMethodCalls([['bar', ['a', 'b']], ['baz', ['c', 'd']]]); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckArgumentsValidityPass(); - $pass->process($container); - $this->assertEquals([null, 1, 'a'], $container->getDefinition('foo')->getArguments()); - $this->assertEquals([['bar', ['a', 'b']], ['baz', ['c', 'd']]], $container->getDefinition('foo')->getMethodCalls()); - } - /** - * @dataProvider definitionProvider - */ - public function testException(array $arguments, array $methodCalls) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register('foo'); - $definition->setArguments($arguments); - $definition->setMethodCalls($methodCalls); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckArgumentsValidityPass(); - $pass->process($container); - } - public function definitionProvider() - { - return [[[null, 'a' => 'a'], []], [[1 => 1], []], [[], [['baz', [null, 'a' => 'a']]]], [[], [['baz', [1 => 1]]]]]; - } - public function testNoException() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register('foo'); - $definition->setArguments([null, 'a' => 'a']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckArgumentsValidityPass(\false); - $pass->process($container); - $this->assertCount(1, $definition->getErrors()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckArgumentsValidityPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * @author Kévin Dunglas + */ +class CheckArgumentsValidityPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register('foo'); + $definition->setArguments([null, 1, 'a']); + $definition->setMethodCalls([['bar', ['a', 'b']], ['baz', ['c', 'd']]]); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckArgumentsValidityPass(); + $pass->process($container); + $this->assertEquals([null, 1, 'a'], $container->getDefinition('foo')->getArguments()); + $this->assertEquals([['bar', ['a', 'b']], ['baz', ['c', 'd']]], $container->getDefinition('foo')->getMethodCalls()); + } + /** + * @dataProvider definitionProvider + */ + public function testException(array $arguments, array $methodCalls) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register('foo'); + $definition->setArguments($arguments); + $definition->setMethodCalls($methodCalls); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckArgumentsValidityPass(); + $pass->process($container); + } + public function definitionProvider() + { + return [[[null, 'a' => 'a'], []], [[1 => 1], []], [[], [['baz', [null, 'a' => 'a']]]], [[], [['baz', [1 => 1]]]]]; + } + public function testNoException() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register('foo'); + $definition->setArguments([null, 'a' => 'a']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckArgumentsValidityPass(\false); + $pass->process($container); + $this->assertCount(1, $definition->getErrors()); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/CheckCircularReferencesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/CheckCircularReferencesPassTest.php index 2813ba20c..e56ef1094 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/CheckCircularReferencesPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/CheckCircularReferencesPassTest.php @@ -1,108 +1,108 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\Compiler; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class CheckCircularReferencesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); - $this->process($container); - } - public function testProcessWithAliases() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->setAlias('b', 'c'); - $container->setAlias('c', 'a'); - $this->process($container); - } - public function testProcessWithFactory() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a', 'stdClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), 'getInstance']); - $container->register('b', 'stdClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'), 'getInstance']); - $this->process($container); - } - public function testProcessDetectsIndirectCircularReference() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c')); - $container->register('c')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); - $this->process($container); - } - public function testProcessDetectsIndirectCircularReferenceWithFactory() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b', 'stdClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c'), 'getInstance']); - $container->register('c')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); - $this->process($container); - } - public function testDeepCircularReference() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c')); - $container->register('c')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $this->process($container); - } - public function testProcessIgnoresMethodCalls() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b')->addMethodCall('setA', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')]); - $this->process($container); - $this->addToAssertionCount(1); - } - public function testProcessIgnoresLazyServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->setLazy(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); - $this->process($container); - // just make sure that a lazily loaded service does not trigger a CircularReferenceException - $this->addToAssertionCount(1); - } - public function testProcessIgnoresIteratorArguments() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')])); - $this->process($container); - // just make sure that an IteratorArgument does not trigger a CircularReferenceException - $this->addToAssertionCount(1); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $compiler = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\Compiler(); - $passConfig = $compiler->getPassConfig(); - $passConfig->setOptimizationPasses([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass()]); - $passConfig->setRemovingPasses([]); - $compiler->compile($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\Compiler; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class CheckCircularReferencesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); + $this->process($container); + } + public function testProcessWithAliases() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->setAlias('b', 'c'); + $container->setAlias('c', 'a'); + $this->process($container); + } + public function testProcessWithFactory() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a', 'stdClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), 'getInstance']); + $container->register('b', 'stdClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'), 'getInstance']); + $this->process($container); + } + public function testProcessDetectsIndirectCircularReference() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c')); + $container->register('c')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); + $this->process($container); + } + public function testProcessDetectsIndirectCircularReferenceWithFactory() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b', 'stdClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c'), 'getInstance']); + $container->register('c')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); + $this->process($container); + } + public function testDeepCircularReference() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c')); + $container->register('c')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $this->process($container); + } + public function testProcessIgnoresMethodCalls() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b')->addMethodCall('setA', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')]); + $this->process($container); + $this->addToAssertionCount(1); + } + public function testProcessIgnoresLazyServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->setLazy(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); + $this->process($container); + // just make sure that a lazily loaded service does not trigger a CircularReferenceException + $this->addToAssertionCount(1); + } + public function testProcessIgnoresIteratorArguments() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')])); + $this->process($container); + // just make sure that an IteratorArgument does not trigger a CircularReferenceException + $this->addToAssertionCount(1); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $compiler = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\Compiler(); + $passConfig = $compiler->getPassConfig(); + $passConfig->setOptimizationPasses([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckCircularReferencesPass()]); + $passConfig->setRemovingPasses([]); + $compiler->compile($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/CheckDefinitionValidityPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/CheckDefinitionValidityPassTest.php index 859a1ee0f..d821a69c6 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/CheckDefinitionValidityPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/CheckDefinitionValidityPassTest.php @@ -1,89 +1,89 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckDefinitionValidityPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -class CheckDefinitionValidityPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcessDetectsSyntheticNonPublicDefinitions() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->setSynthetic(\true)->setPublic(\false); - $this->process($container); - } - public function testProcessDetectsNonSyntheticNonAbstractDefinitionWithoutClass() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->setSynthetic(\false)->setAbstract(\false); - $this->process($container); - } - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a', 'class'); - $container->register('b', 'class')->setSynthetic(\true)->setPublic(\true); - $container->register('c', 'class')->setAbstract(\true); - $container->register('d', 'class')->setSynthetic(\true); - $this->process($container); - $this->addToAssertionCount(1); - } - public function testValidTags() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a', 'class')->addTag('foo', ['bar' => 'baz']); - $container->register('b', 'class')->addTag('foo', ['bar' => null]); - $container->register('c', 'class')->addTag('foo', ['bar' => 1]); - $container->register('d', 'class')->addTag('foo', ['bar' => 1.1]); - $this->process($container); - $this->addToAssertionCount(1); - } - public function testInvalidTags() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a', 'class')->addTag('foo', ['bar' => ['baz' => 'baz']]); - $this->process($container); - } - public function testDynamicPublicServiceName() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvParameterException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $env = $container->getParameterBag()->get('env(BAR)'); - $container->register("foo.{$env}", 'class')->setPublic(\true); - $this->process($container); - } - public function testDynamicPublicAliasName() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvParameterException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $env = $container->getParameterBag()->get('env(BAR)'); - $container->setAlias("foo.{$env}", 'class')->setPublic(\true); - $this->process($container); - } - public function testDynamicPrivateName() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $env = $container->getParameterBag()->get('env(BAR)'); - $container->register("foo.{$env}", 'class'); - $container->setAlias("bar.{$env}", 'class'); - $this->process($container); - $this->addToAssertionCount(1); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckDefinitionValidityPass(); - $pass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckDefinitionValidityPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +class CheckDefinitionValidityPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcessDetectsSyntheticNonPublicDefinitions() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->setSynthetic(\true)->setPublic(\false); + $this->process($container); + } + public function testProcessDetectsNonSyntheticNonAbstractDefinitionWithoutClass() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->setSynthetic(\false)->setAbstract(\false); + $this->process($container); + } + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a', 'class'); + $container->register('b', 'class')->setSynthetic(\true)->setPublic(\true); + $container->register('c', 'class')->setAbstract(\true); + $container->register('d', 'class')->setSynthetic(\true); + $this->process($container); + $this->addToAssertionCount(1); + } + public function testValidTags() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a', 'class')->addTag('foo', ['bar' => 'baz']); + $container->register('b', 'class')->addTag('foo', ['bar' => null]); + $container->register('c', 'class')->addTag('foo', ['bar' => 1]); + $container->register('d', 'class')->addTag('foo', ['bar' => 1.1]); + $this->process($container); + $this->addToAssertionCount(1); + } + public function testInvalidTags() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a', 'class')->addTag('foo', ['bar' => ['baz' => 'baz']]); + $this->process($container); + } + public function testDynamicPublicServiceName() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvParameterException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $env = $container->getParameterBag()->get('env(BAR)'); + $container->register("foo.{$env}", 'class')->setPublic(\true); + $this->process($container); + } + public function testDynamicPublicAliasName() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvParameterException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $env = $container->getParameterBag()->get('env(BAR)'); + $container->setAlias("foo.{$env}", 'class')->setPublic(\true); + $this->process($container); + } + public function testDynamicPrivateName() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $env = $container->getParameterBag()->get('env(BAR)'); + $container->register("foo.{$env}", 'class'); + $container->setAlias("bar.{$env}", 'class'); + $this->process($container); + $this->addToAssertionCount(1); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckDefinitionValidityPass(); + $pass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/CheckExceptionOnInvalidReferenceBehaviorPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/CheckExceptionOnInvalidReferenceBehaviorPassTest.php index fe6ca3af9..7c8ed3e51 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/CheckExceptionOnInvalidReferenceBehaviorPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/CheckExceptionOnInvalidReferenceBehaviorPassTest.php @@ -1,57 +1,57 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class CheckExceptionOnInvalidReferenceBehaviorPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b', '\\stdClass'); - $this->process($container); - $this->addToAssertionCount(1); - } - public function testProcessThrowsExceptionOnInvalidReference() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $this->process($container); - } - public function testProcessThrowsExceptionOnInvalidReferenceFromInlinedDefinition() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $def->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('a', '\\stdClass')->addArgument($def); - $this->process($container); - } - public function testProcessDefinitionWithBindings() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('b')->setBindings([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'))]); - $this->process($container); - $this->addToAssertionCount(1); - } - private function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass(); - $pass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class CheckExceptionOnInvalidReferenceBehaviorPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b', '\\stdClass'); + $this->process($container); + $this->addToAssertionCount(1); + } + public function testProcessThrowsExceptionOnInvalidReference() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $this->process($container); + } + public function testProcessThrowsExceptionOnInvalidReferenceFromInlinedDefinition() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $def->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('a', '\\stdClass')->addArgument($def); + $this->process($container); + } + public function testProcessDefinitionWithBindings() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('b')->setBindings([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'))]); + $this->process($container); + $this->addToAssertionCount(1); + } + private function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckExceptionOnInvalidReferenceBehaviorPass(); + $pass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/CheckReferenceValidityPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/CheckReferenceValidityPassTest.php index 98628a8a2..c3c7b2ccd 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/CheckReferenceValidityPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/CheckReferenceValidityPassTest.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckReferenceValidityPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class CheckReferenceValidityPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcessDetectsReferenceToAbstractDefinition() - { - $this->expectException('RuntimeException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->setAbstract(\true); - $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); - $this->process($container); - } - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->register('b'); - $this->process($container); - $this->addToAssertionCount(1); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckReferenceValidityPass(); - $pass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckReferenceValidityPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class CheckReferenceValidityPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcessDetectsReferenceToAbstractDefinition() + { + $this->expectException('RuntimeException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->setAbstract(\true); + $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')); + $this->process($container); + } + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->register('b'); + $this->process($container); + $this->addToAssertionCount(1); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CheckReferenceValidityPass(); + $pass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/DecoratorServicePassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/DecoratorServicePassTest.php index 3255b0510..975fadc64 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/DecoratorServicePassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/DecoratorServicePassTest.php @@ -1,107 +1,107 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DecoratorServicePass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -class DecoratorServicePassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcessWithoutAlias() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $fooDefinition = $container->register('foo')->setPublic(\false); - $fooExtendedDefinition = $container->register('foo.extended')->setPublic(\true)->setDecoratedService('foo'); - $barDefinition = $container->register('bar')->setPublic(\true); - $barExtendedDefinition = $container->register('bar.extended')->setPublic(\true)->setDecoratedService('bar', 'bar.yoo'); - $this->process($container); - $this->assertEquals('foo.extended', $container->getAlias('foo')); - $this->assertFalse($container->getAlias('foo')->isPublic()); - $this->assertEquals('bar.extended', $container->getAlias('bar')); - $this->assertTrue($container->getAlias('bar')->isPublic()); - $this->assertSame($fooDefinition, $container->getDefinition('foo.extended.inner')); - $this->assertFalse($container->getDefinition('foo.extended.inner')->isPublic()); - $this->assertSame($barDefinition, $container->getDefinition('bar.yoo')); - $this->assertFalse($container->getDefinition('bar.yoo')->isPublic()); - $this->assertNull($fooExtendedDefinition->getDecoratedService()); - $this->assertNull($barExtendedDefinition->getDecoratedService()); - } - public function testProcessWithAlias() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setPublic(\true); - $container->setAlias('foo.alias', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('foo', \false)); - $fooExtendedDefinition = $container->register('foo.extended')->setPublic(\true)->setDecoratedService('foo.alias'); - $this->process($container); - $this->assertEquals('foo.extended', $container->getAlias('foo.alias')); - $this->assertFalse($container->getAlias('foo.alias')->isPublic()); - $this->assertEquals('foo', $container->getAlias('foo.extended.inner')); - $this->assertFalse($container->getAlias('foo.extended.inner')->isPublic()); - $this->assertNull($fooExtendedDefinition->getDecoratedService()); - } - public function testProcessWithPriority() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $fooDefinition = $container->register('foo')->setPublic(\false); - $barDefinition = $container->register('bar')->setPublic(\true)->setDecoratedService('foo'); - $bazDefinition = $container->register('baz')->setPublic(\true)->setDecoratedService('foo', null, 5); - $quxDefinition = $container->register('qux')->setPublic(\true)->setDecoratedService('foo', null, 3); - $this->process($container); - $this->assertEquals('bar', $container->getAlias('foo')); - $this->assertFalse($container->getAlias('foo')->isPublic()); - $this->assertSame($fooDefinition, $container->getDefinition('baz.inner')); - $this->assertFalse($container->getDefinition('baz.inner')->isPublic()); - $this->assertEquals('qux', $container->getAlias('bar.inner')); - $this->assertFalse($container->getAlias('bar.inner')->isPublic()); - $this->assertEquals('baz', $container->getAlias('qux.inner')); - $this->assertFalse($container->getAlias('qux.inner')->isPublic()); - $this->assertNull($barDefinition->getDecoratedService()); - $this->assertNull($bazDefinition->getDecoratedService()); - $this->assertNull($quxDefinition->getDecoratedService()); - } - public function testProcessMovesTagsFromDecoratedDefinitionToDecoratingDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setTags(['bar' => ['attr' => 'baz']]); - $container->register('baz')->setTags(['foobar' => ['attr' => 'bar']])->setDecoratedService('foo'); - $this->process($container); - $this->assertEmpty($container->getDefinition('baz.inner')->getTags()); - $this->assertEquals(['bar' => ['attr' => 'baz'], 'foobar' => ['attr' => 'bar']], $container->getDefinition('baz')->getTags()); - } - /** - * @group legacy - */ - public function testProcessMergesAutowiringTypesInDecoratingDefinitionAndRemoveThemFromDecoratedDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->addAutowiringType('Bar'); - $container->register('child')->setDecoratedService('parent')->addAutowiringType('Foo'); - $this->process($container); - $this->assertEquals(['Bar', 'Foo'], $container->getDefinition('child')->getAutowiringTypes()); - $this->assertEmpty($container->getDefinition('child.inner')->getAutowiringTypes()); - } - public function testProcessMovesTagsFromDecoratedDefinitionToDecoratingDefinitionMultipleTimes() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setPublic(\true)->setTags(['bar' => ['attr' => 'baz']]); - $container->register('deco1')->setDecoratedService('foo', null, 50); - $container->register('deco2')->setDecoratedService('foo', null, 2); - $this->process($container); - $this->assertEmpty($container->getDefinition('deco1')->getTags()); - $this->assertEquals(['bar' => ['attr' => 'baz']], $container->getDefinition('deco2')->getTags()); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $repeatedPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DecoratorServicePass(); - $repeatedPass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DecoratorServicePass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +class DecoratorServicePassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcessWithoutAlias() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $fooDefinition = $container->register('foo')->setPublic(\false); + $fooExtendedDefinition = $container->register('foo.extended')->setPublic(\true)->setDecoratedService('foo'); + $barDefinition = $container->register('bar')->setPublic(\true); + $barExtendedDefinition = $container->register('bar.extended')->setPublic(\true)->setDecoratedService('bar', 'bar.yoo'); + $this->process($container); + $this->assertEquals('foo.extended', $container->getAlias('foo')); + $this->assertFalse($container->getAlias('foo')->isPublic()); + $this->assertEquals('bar.extended', $container->getAlias('bar')); + $this->assertTrue($container->getAlias('bar')->isPublic()); + $this->assertSame($fooDefinition, $container->getDefinition('foo.extended.inner')); + $this->assertFalse($container->getDefinition('foo.extended.inner')->isPublic()); + $this->assertSame($barDefinition, $container->getDefinition('bar.yoo')); + $this->assertFalse($container->getDefinition('bar.yoo')->isPublic()); + $this->assertNull($fooExtendedDefinition->getDecoratedService()); + $this->assertNull($barExtendedDefinition->getDecoratedService()); + } + public function testProcessWithAlias() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setPublic(\true); + $container->setAlias('foo.alias', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('foo', \false)); + $fooExtendedDefinition = $container->register('foo.extended')->setPublic(\true)->setDecoratedService('foo.alias'); + $this->process($container); + $this->assertEquals('foo.extended', $container->getAlias('foo.alias')); + $this->assertFalse($container->getAlias('foo.alias')->isPublic()); + $this->assertEquals('foo', $container->getAlias('foo.extended.inner')); + $this->assertFalse($container->getAlias('foo.extended.inner')->isPublic()); + $this->assertNull($fooExtendedDefinition->getDecoratedService()); + } + public function testProcessWithPriority() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $fooDefinition = $container->register('foo')->setPublic(\false); + $barDefinition = $container->register('bar')->setPublic(\true)->setDecoratedService('foo'); + $bazDefinition = $container->register('baz')->setPublic(\true)->setDecoratedService('foo', null, 5); + $quxDefinition = $container->register('qux')->setPublic(\true)->setDecoratedService('foo', null, 3); + $this->process($container); + $this->assertEquals('bar', $container->getAlias('foo')); + $this->assertFalse($container->getAlias('foo')->isPublic()); + $this->assertSame($fooDefinition, $container->getDefinition('baz.inner')); + $this->assertFalse($container->getDefinition('baz.inner')->isPublic()); + $this->assertEquals('qux', $container->getAlias('bar.inner')); + $this->assertFalse($container->getAlias('bar.inner')->isPublic()); + $this->assertEquals('baz', $container->getAlias('qux.inner')); + $this->assertFalse($container->getAlias('qux.inner')->isPublic()); + $this->assertNull($barDefinition->getDecoratedService()); + $this->assertNull($bazDefinition->getDecoratedService()); + $this->assertNull($quxDefinition->getDecoratedService()); + } + public function testProcessMovesTagsFromDecoratedDefinitionToDecoratingDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setTags(['bar' => ['attr' => 'baz']]); + $container->register('baz')->setTags(['foobar' => ['attr' => 'bar']])->setDecoratedService('foo'); + $this->process($container); + $this->assertEmpty($container->getDefinition('baz.inner')->getTags()); + $this->assertEquals(['bar' => ['attr' => 'baz'], 'foobar' => ['attr' => 'bar']], $container->getDefinition('baz')->getTags()); + } + /** + * @group legacy + */ + public function testProcessMergesAutowiringTypesInDecoratingDefinitionAndRemoveThemFromDecoratedDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->addAutowiringType('Bar'); + $container->register('child')->setDecoratedService('parent')->addAutowiringType('Foo'); + $this->process($container); + $this->assertEquals(['Bar', 'Foo'], $container->getDefinition('child')->getAutowiringTypes()); + $this->assertEmpty($container->getDefinition('child.inner')->getAutowiringTypes()); + } + public function testProcessMovesTagsFromDecoratedDefinitionToDecoratingDefinitionMultipleTimes() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setPublic(\true)->setTags(['bar' => ['attr' => 'baz']]); + $container->register('deco1')->setDecoratedService('foo', null, 50); + $container->register('deco2')->setDecoratedService('foo', null, 2); + $this->process($container); + $this->assertEmpty($container->getDefinition('deco1')->getTags()); + $this->assertEquals(['bar' => ['attr' => 'baz']], $container->getDefinition('deco2')->getTags()); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $repeatedPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DecoratorServicePass(); + $repeatedPass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/DefinitionErrorExceptionPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/DefinitionErrorExceptionPassTest.php index 127be7a00..9c7c9aa5d 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/DefinitionErrorExceptionPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/DefinitionErrorExceptionPassTest.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -class DefinitionErrorExceptionPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Things went wrong!'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $def->addError('Things went wrong!'); - $def->addError('Now something else!'); - $container->register('foo_service_id')->setArguments([$def]); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass(); - $pass->process($container); - } - public function testNoExceptionThrown() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $container->register('foo_service_id')->setArguments([$def]); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass(); - $pass->process($container); - $this->assertSame($def, $container->getDefinition('foo_service_id')->getArgument(0)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +class DefinitionErrorExceptionPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Things went wrong!'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $def->addError('Things went wrong!'); + $def->addError('Now something else!'); + $container->register('foo_service_id')->setArguments([$def]); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass(); + $pass->process($container); + } + public function testNoExceptionThrown() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $container->register('foo_service_id')->setArguments([$def]); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass(); + $pass->process($container); + $this->assertSame($def, $container->getDefinition('foo_service_id')->getArgument(0)); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ExtensionCompilerPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ExtensionCompilerPassTest.php index 42dc961c4..2700386d7 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ExtensionCompilerPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ExtensionCompilerPassTest.php @@ -1,68 +1,68 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ExtensionCompilerPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension; -/** - * @author Wouter J - */ -class ExtensionCompilerPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - private $container; - private $pass; - protected function setUp() - { - $this->container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $this->pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ExtensionCompilerPass(); - } - public function testProcess() - { - $extension1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CompilerPassExtension('extension1'); - $extension2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DummyExtension('extension2'); - $extension3 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DummyExtension('extension3'); - $extension4 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CompilerPassExtension('extension4'); - $this->container->registerExtension($extension1); - $this->container->registerExtension($extension2); - $this->container->registerExtension($extension3); - $this->container->registerExtension($extension4); - $this->pass->process($this->container); - $this->assertTrue($this->container->hasDefinition('extension1')); - $this->assertFalse($this->container->hasDefinition('extension2')); - $this->assertFalse($this->container->hasDefinition('extension3')); - $this->assertTrue($this->container->hasDefinition('extension4')); - } -} -class DummyExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension -{ - private $alias; - public function __construct($alias) - { - $this->alias = $alias; - } - public function getAlias() - { - return $this->alias; - } - public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - } - public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $container->register($this->alias); - } -} -class CompilerPassExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DummyExtension implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ExtensionCompilerPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension; +/** + * @author Wouter J + */ +class ExtensionCompilerPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + private $container; + private $pass; + protected function setUp() + { + $this->container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $this->pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ExtensionCompilerPass(); + } + public function testProcess() + { + $extension1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CompilerPassExtension('extension1'); + $extension2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DummyExtension('extension2'); + $extension3 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DummyExtension('extension3'); + $extension4 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\CompilerPassExtension('extension4'); + $this->container->registerExtension($extension1); + $this->container->registerExtension($extension2); + $this->container->registerExtension($extension3); + $this->container->registerExtension($extension4); + $this->pass->process($this->container); + $this->assertTrue($this->container->hasDefinition('extension1')); + $this->assertFalse($this->container->hasDefinition('extension2')); + $this->assertFalse($this->container->hasDefinition('extension3')); + $this->assertTrue($this->container->hasDefinition('extension4')); + } +} +class DummyExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension +{ + private $alias; + public function __construct($alias) + { + $this->alias = $alias; + } + public function getAlias() + { + return $this->alias; + } + public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + } + public function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $container->register($this->alias); + } +} +class CompilerPassExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DummyExtension implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface +{ +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/FactoryReturnTypePassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/FactoryReturnTypePassTest.php index 6c17f5d72..64206f386 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/FactoryReturnTypePassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/FactoryReturnTypePassTest.php @@ -1,101 +1,101 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\FactoryReturnTypePass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\factoryFunction; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryParent; -/** - * @author Guilhem N. - * - * @group legacy - */ -class FactoryReturnTypePassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $factory = $container->register('factory'); - $factory->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, 'createFactory']); - $container->setAlias('alias_factory', 'factory'); - $foo = $container->register('foo'); - $foo->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('alias_factory'), 'create']); - $bar = $container->register('bar', __CLASS__); - $bar->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory'), 'create']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\FactoryReturnTypePass(); - $pass->process($container); - if (\method_exists(\ReflectionMethod::class, 'getReturnType')) { - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, $factory->getClass()); - $this->assertEquals(\stdClass::class, $foo->getClass()); - } else { - $this->assertNull($factory->getClass()); - $this->assertNull($foo->getClass()); - } - $this->assertEquals(__CLASS__, $bar->getClass()); - } - /** - * @dataProvider returnTypesProvider - */ - public function testReturnTypes($factory, $returnType, $hhvmSupport = \true) - { - if (!$hhvmSupport && \defined('HHVM_VERSION')) { - $this->markTestSkipped('Scalar typehints not supported by hhvm.'); - } - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $service = $container->register('service'); - $service->setFactory($factory); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\FactoryReturnTypePass(); - $pass->process($container); - if (\method_exists(\ReflectionMethod::class, 'getReturnType')) { - $this->assertEquals($returnType, $service->getClass()); - } else { - $this->assertNull($service->getClass()); - } - } - public function returnTypesProvider() - { - return [ - // must be loaded before the function as they are in the same file - [[\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, 'createBuiltin'], null, \false], - [[\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, 'createParent'], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryParent::class], - [[\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, 'createSelf'], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class], - [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\factoryFunction::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class], - ]; - } - public function testCircularReference() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $factory = $container->register('factory'); - $factory->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory2'), 'createSelf']); - $factory2 = $container->register('factory2'); - $factory2->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory'), 'create']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\FactoryReturnTypePass(); - $pass->process($container); - $this->assertNull($factory->getClass()); - $this->assertNull($factory2->getClass()); - } - /** - * @requires function ReflectionMethod::getReturnType - * @expectedDeprecation Relying on its factory's return-type to define the class of service "factory" is deprecated since Symfony 3.3 and won't work in 4.0. Set the "class" attribute to "Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy" on the service definition instead. - */ - public function testCompile() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $factory = $container->register('factory'); - $factory->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, 'createFactory']); - $container->compile(); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, $container->getDefinition('factory')->getClass()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\FactoryReturnTypePass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\factoryFunction; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryParent; +/** + * @author Guilhem N. + * + * @group legacy + */ +class FactoryReturnTypePassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $factory = $container->register('factory'); + $factory->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, 'createFactory']); + $container->setAlias('alias_factory', 'factory'); + $foo = $container->register('foo'); + $foo->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('alias_factory'), 'create']); + $bar = $container->register('bar', __CLASS__); + $bar->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory'), 'create']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\FactoryReturnTypePass(); + $pass->process($container); + if (\method_exists(\ReflectionMethod::class, 'getReturnType')) { + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, $factory->getClass()); + $this->assertEquals(\stdClass::class, $foo->getClass()); + } else { + $this->assertNull($factory->getClass()); + $this->assertNull($foo->getClass()); + } + $this->assertEquals(__CLASS__, $bar->getClass()); + } + /** + * @dataProvider returnTypesProvider + */ + public function testReturnTypes($factory, $returnType, $hhvmSupport = \true) + { + if (!$hhvmSupport && \defined('HHVM_VERSION')) { + $this->markTestSkipped('Scalar typehints not supported by hhvm.'); + } + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $service = $container->register('service'); + $service->setFactory($factory); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\FactoryReturnTypePass(); + $pass->process($container); + if (\method_exists(\ReflectionMethod::class, 'getReturnType')) { + $this->assertEquals($returnType, $service->getClass()); + } else { + $this->assertNull($service->getClass()); + } + } + public function returnTypesProvider() + { + return [ + // must be loaded before the function as they are in the same file + [[\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, 'createBuiltin'], null, \false], + [[\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, 'createParent'], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryParent::class], + [[\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, 'createSelf'], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class], + [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\factoryFunction::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class], + ]; + } + public function testCircularReference() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $factory = $container->register('factory'); + $factory->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory2'), 'createSelf']); + $factory2 = $container->register('factory2'); + $factory2->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory'), 'create']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\FactoryReturnTypePass(); + $pass->process($container); + $this->assertNull($factory->getClass()); + $this->assertNull($factory2->getClass()); + } + /** + * @requires function ReflectionMethod::getReturnType + * @expectedDeprecation Relying on its factory's return-type to define the class of service "factory" is deprecated since Symfony 3.3 and won't work in 4.0. Set the "class" attribute to "Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy" on the service definition instead. + */ + public function testCompile() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $factory = $container->register('factory'); + $factory->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, 'createFactory']); + $container->compile(); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy::class, $container->getDefinition('factory')->getClass()); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/InlineServiceDefinitionsPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/InlineServiceDefinitionsPassTest.php index ff8ee059d..2aae501ae 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/InlineServiceDefinitionsPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/InlineServiceDefinitionsPassTest.php @@ -1,185 +1,185 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class InlineServiceDefinitionsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('inlinable.service')->setPublic(\false); - $container->register('service')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('inlinable.service')]); - $this->process($container); - $arguments = $container->getDefinition('service')->getArguments(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $arguments[0]); - $this->assertSame($container->getDefinition('inlinable.service'), $arguments[0]); - } - public function testProcessDoesNotInlinesWhenAliasedServiceIsShared() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setPublic(\false); - $container->setAlias('moo', 'foo'); - $container->register('service')->setArguments([$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); - $this->process($container); - $arguments = $container->getDefinition('service')->getArguments(); - $this->assertSame($ref, $arguments[0]); - } - public function testProcessDoesInlineNonSharedService() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setShared(\false); - $container->register('bar')->setPublic(\false)->setShared(\false); - $container->setAlias('moo', 'bar'); - $container->register('service')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), $ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('moo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); - $this->process($container); - $arguments = $container->getDefinition('service')->getArguments(); - $this->assertEquals($container->getDefinition('foo'), $arguments[0]); - $this->assertNotSame($container->getDefinition('foo'), $arguments[0]); - $this->assertSame($ref, $arguments[1]); - $this->assertEquals($container->getDefinition('bar'), $arguments[2]); - $this->assertNotSame($container->getDefinition('bar'), $arguments[2]); - } - public function testProcessDoesNotInlineMixedServicesLoop() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))->setShared(\false); - $container->register('bar')->setPublic(\false)->addMethodCall('setFoo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); - $this->process($container); - $this->assertEquals(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), $container->getDefinition('foo')->getArgument(0)); - } - public function testProcessThrowsOnNonSharedLoops() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $this->expectExceptionMessage('Circular reference detected for service "bar", path: "bar -> foo -> bar".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))->setShared(\false); - $container->register('bar')->setShared(\false)->addMethodCall('setFoo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); - $this->process($container); - } - public function testProcessNestedNonSharedServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar1'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar2')); - $container->register('bar1')->setShared(\false)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')); - $container->register('bar2')->setShared(\false)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')); - $container->register('baz')->setShared(\false); - $this->process($container); - $baz1 = $container->getDefinition('foo')->getArgument(0)->getArgument(0); - $baz2 = $container->getDefinition('foo')->getArgument(1)->getArgument(0); - $this->assertEquals($container->getDefinition('baz'), $baz1); - $this->assertEquals($container->getDefinition('baz'), $baz2); - $this->assertNotSame($baz1, $baz2); - } - public function testProcessInlinesIfMultipleReferencesButAllFromTheSameDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $a = $container->register('a')->setPublic(\false); - $b = $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(null, [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')])); - $this->process($container); - $arguments = $b->getArguments(); - $this->assertSame($a, $arguments[0]); - $inlinedArguments = $arguments[1]->getArguments(); - $this->assertSame($a, $inlinedArguments[0]); - } - public function testProcessInlinesPrivateFactoryReference() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a')->setPublic(\false); - $b = $container->register('b')->setPublic(\false)->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'), 'a']); - $container->register('foo')->setArguments([$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')]); - $this->process($container); - $inlinedArguments = $container->getDefinition('foo')->getArguments(); - $this->assertSame($b, $inlinedArguments[0]); - } - public function testProcessDoesNotInlinePrivateFactoryIfReferencedMultipleTimesWithinTheSameDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a'); - $container->register('b')->setPublic(\false)->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'), 'a']); - $container->register('foo')->setArguments([$ref1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), $ref2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')]); - $this->process($container); - $args = $container->getDefinition('foo')->getArguments(); - $this->assertSame($ref1, $args[0]); - $this->assertSame($ref2, $args[1]); - } - public function testProcessDoesNotInlineReferenceWhenUsedByInlineFactory() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a'); - $container->register('b')->setPublic(\false)->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'), 'a']); - $inlineFactory = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $inlineFactory->setPublic(\false); - $inlineFactory->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), 'b']); - $container->register('foo')->setArguments([$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), $inlineFactory]); - $this->process($container); - $args = $container->getDefinition('foo')->getArguments(); - $this->assertSame($ref, $args[0]); - } - public function testProcessDoesNotInlineWhenServiceIsPrivateButLazy() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setPublic(\false)->setLazy(\true); - $container->register('service')->setArguments([$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); - $this->process($container); - $arguments = $container->getDefinition('service')->getArguments(); - $this->assertSame($ref, $arguments[0]); - } - public function testProcessDoesNotInlineWhenServiceReferencesItself() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setPublic(\false)->addMethodCall('foo', [$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); - $this->process($container); - $calls = $container->getDefinition('foo')->getMethodCalls(); - $this->assertSame($ref, $calls[0][1][0]); - } - public function testProcessDoesNotSetLazyArgumentValuesAfterInlining() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('inline')->setShared(\false); - $container->register('service-closure')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('inline'))]); - $container->register('iterator')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('inline')])]); - $this->process($container); - $values = $container->getDefinition('service-closure')->getArgument(0)->getValues(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $values[0]); - $this->assertSame('inline', (string) $values[0]); - $values = $container->getDefinition('iterator')->getArgument(0)->getValues(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $values[0]); - $this->assertSame('inline', (string) $values[0]); - } - /** - * @group legacy - */ - public function testGetInlinedServiceIdData() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('inlinable.service')->setPublic(\false); - $container->register('non_inlinable.service')->setPublic(\true); - $container->register('other_service')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('inlinable.service')]); - $inlinePass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass(); - $repeatedPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(), $inlinePass]); - $repeatedPass->process($container); - $this->assertEquals(['inlinable.service' => ['other_service']], $inlinePass->getInlinedServiceIds()); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $repeatedPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass()]); - $repeatedPass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class InlineServiceDefinitionsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('inlinable.service')->setPublic(\false); + $container->register('service')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('inlinable.service')]); + $this->process($container); + $arguments = $container->getDefinition('service')->getArguments(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $arguments[0]); + $this->assertSame($container->getDefinition('inlinable.service'), $arguments[0]); + } + public function testProcessDoesNotInlinesWhenAliasedServiceIsShared() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setPublic(\false); + $container->setAlias('moo', 'foo'); + $container->register('service')->setArguments([$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); + $this->process($container); + $arguments = $container->getDefinition('service')->getArguments(); + $this->assertSame($ref, $arguments[0]); + } + public function testProcessDoesInlineNonSharedService() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setShared(\false); + $container->register('bar')->setPublic(\false)->setShared(\false); + $container->setAlias('moo', 'bar'); + $container->register('service')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), $ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('moo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); + $this->process($container); + $arguments = $container->getDefinition('service')->getArguments(); + $this->assertEquals($container->getDefinition('foo'), $arguments[0]); + $this->assertNotSame($container->getDefinition('foo'), $arguments[0]); + $this->assertSame($ref, $arguments[1]); + $this->assertEquals($container->getDefinition('bar'), $arguments[2]); + $this->assertNotSame($container->getDefinition('bar'), $arguments[2]); + } + public function testProcessDoesNotInlineMixedServicesLoop() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))->setShared(\false); + $container->register('bar')->setPublic(\false)->addMethodCall('setFoo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); + $this->process($container); + $this->assertEquals(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), $container->getDefinition('foo')->getArgument(0)); + } + public function testProcessThrowsOnNonSharedLoops() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $this->expectExceptionMessage('Circular reference detected for service "bar", path: "bar -> foo -> bar".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))->setShared(\false); + $container->register('bar')->setShared(\false)->addMethodCall('setFoo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); + $this->process($container); + } + public function testProcessNestedNonSharedServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar1'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar2')); + $container->register('bar1')->setShared(\false)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')); + $container->register('bar2')->setShared(\false)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')); + $container->register('baz')->setShared(\false); + $this->process($container); + $baz1 = $container->getDefinition('foo')->getArgument(0)->getArgument(0); + $baz2 = $container->getDefinition('foo')->getArgument(1)->getArgument(0); + $this->assertEquals($container->getDefinition('baz'), $baz1); + $this->assertEquals($container->getDefinition('baz'), $baz2); + $this->assertNotSame($baz1, $baz2); + } + public function testProcessInlinesIfMultipleReferencesButAllFromTheSameDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $a = $container->register('a')->setPublic(\false); + $b = $container->register('b')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(null, [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')])); + $this->process($container); + $arguments = $b->getArguments(); + $this->assertSame($a, $arguments[0]); + $inlinedArguments = $arguments[1]->getArguments(); + $this->assertSame($a, $inlinedArguments[0]); + } + public function testProcessInlinesPrivateFactoryReference() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a')->setPublic(\false); + $b = $container->register('b')->setPublic(\false)->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'), 'a']); + $container->register('foo')->setArguments([$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')]); + $this->process($container); + $inlinedArguments = $container->getDefinition('foo')->getArguments(); + $this->assertSame($b, $inlinedArguments[0]); + } + public function testProcessDoesNotInlinePrivateFactoryIfReferencedMultipleTimesWithinTheSameDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a'); + $container->register('b')->setPublic(\false)->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'), 'a']); + $container->register('foo')->setArguments([$ref1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), $ref2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')]); + $this->process($container); + $args = $container->getDefinition('foo')->getArguments(); + $this->assertSame($ref1, $args[0]); + $this->assertSame($ref2, $args[1]); + } + public function testProcessDoesNotInlineReferenceWhenUsedByInlineFactory() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a'); + $container->register('b')->setPublic(\false)->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a'), 'a']); + $inlineFactory = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $inlineFactory->setPublic(\false); + $inlineFactory->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), 'b']); + $container->register('foo')->setArguments([$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), $inlineFactory]); + $this->process($container); + $args = $container->getDefinition('foo')->getArguments(); + $this->assertSame($ref, $args[0]); + } + public function testProcessDoesNotInlineWhenServiceIsPrivateButLazy() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setPublic(\false)->setLazy(\true); + $container->register('service')->setArguments([$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); + $this->process($container); + $arguments = $container->getDefinition('service')->getArguments(); + $this->assertSame($ref, $arguments[0]); + } + public function testProcessDoesNotInlineWhenServiceReferencesItself() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setPublic(\false)->addMethodCall('foo', [$ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); + $this->process($container); + $calls = $container->getDefinition('foo')->getMethodCalls(); + $this->assertSame($ref, $calls[0][1][0]); + } + public function testProcessDoesNotSetLazyArgumentValuesAfterInlining() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('inline')->setShared(\false); + $container->register('service-closure')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('inline'))]); + $container->register('iterator')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('inline')])]); + $this->process($container); + $values = $container->getDefinition('service-closure')->getArgument(0)->getValues(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $values[0]); + $this->assertSame('inline', (string) $values[0]); + $values = $container->getDefinition('iterator')->getArgument(0)->getValues(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $values[0]); + $this->assertSame('inline', (string) $values[0]); + } + /** + * @group legacy + */ + public function testGetInlinedServiceIdData() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('inlinable.service')->setPublic(\false); + $container->register('non_inlinable.service')->setPublic(\true); + $container->register('other_service')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('inlinable.service')]); + $inlinePass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass(); + $repeatedPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(), $inlinePass]); + $repeatedPass->process($container); + $this->assertEquals(['inlinable.service' => ['other_service']], $inlinePass->getInlinedServiceIds()); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $repeatedPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\InlineServiceDefinitionsPass()]); + $repeatedPass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/IntegrationTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/IntegrationTest.php index c6d5ad79e..f68544337 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/IntegrationTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/IntegrationTest.php @@ -1,146 +1,146 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface; -/** - * This class tests the integration of the different compiler passes. - */ -class IntegrationTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * This tests that dependencies are correctly processed. - * - * We're checking that: - * - * * A is public, B/C are private - * * A -> C - * * B -> C - */ - public function testProcessRemovesAndInlinesRecursively() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $a = $container->register('a', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c')); - $container->register('b', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c'))->setPublic(\false); - $c = $container->register('c', '\\stdClass')->setPublic(\false); - $container->compile(); - $this->assertTrue($container->hasDefinition('a')); - $arguments = $a->getArguments(); - $this->assertSame($c, $arguments[0]); - $this->assertFalse($container->hasDefinition('b')); - $this->assertFalse($container->hasDefinition('c')); - } - public function testProcessInlinesReferencesToAliases() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $a = $container->register('a', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); - $container->setAlias('b', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('c', \false)); - $c = $container->register('c', '\\stdClass')->setPublic(\false); - $container->compile(); - $this->assertTrue($container->hasDefinition('a')); - $arguments = $a->getArguments(); - $this->assertSame($c, $arguments[0]); - $this->assertFalse($container->hasAlias('b')); - $this->assertFalse($container->hasDefinition('c')); - } - public function testProcessInlinesWhenThereAreMultipleReferencesButFromTheSameDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->register('a', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'))->addMethodCall('setC', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c')]); - $container->register('b', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c'))->setPublic(\false); - $container->register('c', '\\stdClass')->setPublic(\false); - $container->compile(); - $this->assertTrue($container->hasDefinition('a')); - $this->assertFalse($container->hasDefinition('b')); - $this->assertFalse($container->hasDefinition('c'), 'Service C was not inlined.'); - } - public function testCanDecorateServiceSubscriber() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ServiceSubscriberStub::class)->addTag('container.service_subscriber')->setPublic(\true); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DecoratedServiceSubscriber::class)->setDecoratedService(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ServiceSubscriberStub::class); - $container->compile(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DecoratedServiceSubscriber::class, $container->get(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ServiceSubscriberStub::class)); - } - /** - * @dataProvider getYamlCompileTests - */ - public function testYamlContainerCompiles($directory, $actualServiceId, $expectedServiceId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $mainContainer = null) - { - // allow a container to be passed in, which might have autoconfigure settings - $container = $mainContainer ?: new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(__DIR__ . '/../Fixtures/yaml/integration/' . $directory)); - $loader->load('main.yml'); - $container->compile(); - $actualService = $container->getDefinition($actualServiceId); - // create a fresh ContainerBuilder, to avoid autoconfigure stuff - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(__DIR__ . '/../Fixtures/yaml/integration/' . $directory)); - $loader->load('expected.yml'); - $container->compile(); - $expectedService = $container->getDefinition($expectedServiceId); - // reset changes, we don't care if these differ - $actualService->setChanges([]); - $expectedService->setChanges([]); - $this->assertEquals($expectedService, $actualService); - } - public function getYamlCompileTests() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerForAutoconfiguration(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub::class); - (yield ['autoconfigure_child_not_applied', 'child_service', 'child_service_expected', $container]); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerForAutoconfiguration(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub::class); - (yield ['autoconfigure_parent_child', 'child_service', 'child_service_expected', $container]); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerForAutoconfiguration(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub::class)->addTag('from_autoconfigure'); - (yield ['autoconfigure_parent_child_tags', 'child_service', 'child_service_expected', $container]); - (yield ['child_parent', 'child_service', 'child_service_expected']); - (yield ['defaults_child_tags', 'child_service', 'child_service_expected']); - (yield ['defaults_instanceof_importance', 'main_service', 'main_service_expected']); - (yield ['defaults_parent_child', 'child_service', 'child_service_expected']); - (yield ['instanceof_parent_child', 'child_service', 'child_service_expected']); - } -} -class ServiceSubscriberStub implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface -{ - public static function getSubscribedServices() - { - return []; - } -} -class DecoratedServiceSubscriber -{ -} -class IntegrationTestStub extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStubParent -{ -} -class IntegrationTestStubParent -{ - public function enableSummer($enable) - { - // methods used in calls - added here to prevent errors for not existing - } - public function setSunshine($type) - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface; +/** + * This class tests the integration of the different compiler passes. + */ +class IntegrationTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * This tests that dependencies are correctly processed. + * + * We're checking that: + * + * * A is public, B/C are private + * * A -> C + * * B -> C + */ + public function testProcessRemovesAndInlinesRecursively() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $a = $container->register('a', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c')); + $container->register('b', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c'))->setPublic(\false); + $c = $container->register('c', '\\stdClass')->setPublic(\false); + $container->compile(); + $this->assertTrue($container->hasDefinition('a')); + $arguments = $a->getArguments(); + $this->assertSame($c, $arguments[0]); + $this->assertFalse($container->hasDefinition('b')); + $this->assertFalse($container->hasDefinition('c')); + } + public function testProcessInlinesReferencesToAliases() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $a = $container->register('a', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b')); + $container->setAlias('b', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('c', \false)); + $c = $container->register('c', '\\stdClass')->setPublic(\false); + $container->compile(); + $this->assertTrue($container->hasDefinition('a')); + $arguments = $a->getArguments(); + $this->assertSame($c, $arguments[0]); + $this->assertFalse($container->hasAlias('b')); + $this->assertFalse($container->hasDefinition('c')); + } + public function testProcessInlinesWhenThereAreMultipleReferencesButFromTheSameDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->register('a', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'))->addMethodCall('setC', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c')]); + $container->register('b', '\\stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c'))->setPublic(\false); + $container->register('c', '\\stdClass')->setPublic(\false); + $container->compile(); + $this->assertTrue($container->hasDefinition('a')); + $this->assertFalse($container->hasDefinition('b')); + $this->assertFalse($container->hasDefinition('c'), 'Service C was not inlined.'); + } + public function testCanDecorateServiceSubscriber() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ServiceSubscriberStub::class)->addTag('container.service_subscriber')->setPublic(\true); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DecoratedServiceSubscriber::class)->setDecoratedService(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ServiceSubscriberStub::class); + $container->compile(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\DecoratedServiceSubscriber::class, $container->get(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ServiceSubscriberStub::class)); + } + /** + * @dataProvider getYamlCompileTests + */ + public function testYamlContainerCompiles($directory, $actualServiceId, $expectedServiceId, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $mainContainer = null) + { + // allow a container to be passed in, which might have autoconfigure settings + $container = $mainContainer ?: new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(__DIR__ . '/../Fixtures/yaml/integration/' . $directory)); + $loader->load('main.yml'); + $container->compile(); + $actualService = $container->getDefinition($actualServiceId); + // create a fresh ContainerBuilder, to avoid autoconfigure stuff + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(__DIR__ . '/../Fixtures/yaml/integration/' . $directory)); + $loader->load('expected.yml'); + $container->compile(); + $expectedService = $container->getDefinition($expectedServiceId); + // reset changes, we don't care if these differ + $actualService->setChanges([]); + $expectedService->setChanges([]); + $this->assertEquals($expectedService, $actualService); + } + public function getYamlCompileTests() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerForAutoconfiguration(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub::class); + (yield ['autoconfigure_child_not_applied', 'child_service', 'child_service_expected', $container]); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerForAutoconfiguration(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub::class); + (yield ['autoconfigure_parent_child', 'child_service', 'child_service_expected', $container]); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerForAutoconfiguration(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub::class)->addTag('from_autoconfigure'); + (yield ['autoconfigure_parent_child_tags', 'child_service', 'child_service_expected', $container]); + (yield ['child_parent', 'child_service', 'child_service_expected']); + (yield ['defaults_child_tags', 'child_service', 'child_service_expected']); + (yield ['defaults_instanceof_importance', 'main_service', 'main_service_expected']); + (yield ['defaults_parent_child', 'child_service', 'child_service_expected']); + (yield ['instanceof_parent_child', 'child_service', 'child_service_expected']); + } +} +class ServiceSubscriberStub implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface +{ + public static function getSubscribedServices() + { + return []; + } +} +class DecoratedServiceSubscriber +{ +} +class IntegrationTestStub extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStubParent +{ +} +class IntegrationTestStubParent +{ + public function enableSummer($enable) + { + // methods used in calls - added here to prevent errors for not existing + } + public function setSunshine($type) + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/MergeExtensionConfigurationPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/MergeExtensionConfigurationPassTest.php index 0a48710dc..ac0af62b1 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/MergeExtensionConfigurationPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/MergeExtensionConfigurationPassTest.php @@ -1,149 +1,149 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -class MergeExtensionConfigurationPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testExpressionLanguageProviderForwarding() - { - $tmpProviders = []; - $extension = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface')->getMock(); - $extension->expects($this->any())->method('getXsdValidationBasePath')->willReturn(\false); - $extension->expects($this->any())->method('getNamespace')->willReturn('http://example.org/schema/dic/foo'); - $extension->expects($this->any())->method('getAlias')->willReturn('foo'); - $extension->expects($this->once())->method('load')->willReturnCallback(function (array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) use(&$tmpProviders) { - $tmpProviders = $container->getExpressionLanguageProviders(); - }); - $provider = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionFunctionProviderInterface')->getMock(); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag()); - $container->registerExtension($extension); - $container->prependExtensionConfig('foo', ['bar' => \true]); - $container->addExpressionLanguageProvider($provider); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); - $pass->process($container); - $this->assertEquals([$provider], $tmpProviders); - } - public function testExtensionLoadGetAMergeExtensionConfigurationContainerBuilderInstance() - { - $extension = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooExtension::class)->setMethods(['load'])->getMock(); - $extension->expects($this->once())->method('load')->with($this->isType('array'), $this->isInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationContainerBuilder::class)); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag()); - $container->registerExtension($extension); - $container->prependExtensionConfig('foo', []); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); - $pass->process($container); - } - public function testExtensionConfigurationIsTrackedByDefault() - { - $extension = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooExtension::class)->setMethods(['getConfiguration'])->getMock(); - $extension->expects($this->exactly(2))->method('getConfiguration')->willReturn(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooConfiguration()); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag()); - $container->registerExtension($extension); - $container->prependExtensionConfig('foo', ['bar' => \true]); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); - $pass->process($container); - $this->assertContainsEquals(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__FILE__), $container->getResources()); - } - public function testOverriddenEnvsAreMerged() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooExtension()); - $container->prependExtensionConfig('foo', ['bar' => '%env(FOO)%']); - $container->prependExtensionConfig('foo', ['bar' => '%env(BAR)%', 'baz' => '%env(BAZ)%']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); - $pass->process($container); - $this->assertSame(['BAZ', 'FOO'], \array_keys($container->getParameterBag()->getEnvPlaceholders())); - $this->assertSame(['BAZ' => 1, 'FOO' => 0], $container->getEnvCounters()); - } - public function testProcessedEnvsAreIncompatibleWithResolve() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Using a cast in "env(int:FOO)" is incompatible with resolution at compile time in "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\BarExtension". The logic in the extension should be moved to a compiler pass, or an env parameter with no cast should be used instead.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\BarExtension()); - $container->prependExtensionConfig('bar', []); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass())->process($container); - } - public function testThrowingExtensionsGetMergedBag() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ThrowingExtension()); - $container->prependExtensionConfig('throwing', ['bar' => '%env(FOO)%']); - try { - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); - $pass->process($container); - $this->fail('An exception should have been thrown.'); - } catch (\Exception $e) { - } - $this->assertSame(['FOO'], \array_keys($container->getParameterBag()->getEnvPlaceholders())); - } -} -class FooConfiguration implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface -{ - public function getConfigTreeBuilder() - { - $treeBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); - $rootNode = $treeBuilder->root('foo'); - $rootNode->children()->scalarNode('bar')->end()->scalarNode('baz')->end()->end(); - return $treeBuilder; - } -} -class FooExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension -{ - public function getAlias() - { - return 'foo'; - } - public function getConfiguration(array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooConfiguration(); - } - public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $configuration = $this->getConfiguration($configs, $container); - $config = $this->processConfiguration($configuration, $configs); - if (isset($config['baz'])) { - $container->getParameterBag()->get('env(BOZ)'); - $container->resolveEnvPlaceholders($config['baz']); - } - } -} -class BarExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension -{ - public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $container->resolveEnvPlaceholders('%env(int:FOO)%', \true); - } -} -class ThrowingExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension -{ - public function getAlias() - { - return 'throwing'; - } - public function getConfiguration(array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooConfiguration(); - } - public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - throw new \Exception(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; +class MergeExtensionConfigurationPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testExpressionLanguageProviderForwarding() + { + $tmpProviders = []; + $extension = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface')->getMock(); + $extension->expects($this->any())->method('getXsdValidationBasePath')->willReturn(\false); + $extension->expects($this->any())->method('getNamespace')->willReturn('http://example.org/schema/dic/foo'); + $extension->expects($this->any())->method('getAlias')->willReturn('foo'); + $extension->expects($this->once())->method('load')->willReturnCallback(function (array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) use(&$tmpProviders) { + $tmpProviders = $container->getExpressionLanguageProviders(); + }); + $provider = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ExpressionFunctionProviderInterface')->getMock(); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag()); + $container->registerExtension($extension); + $container->prependExtensionConfig('foo', ['bar' => \true]); + $container->addExpressionLanguageProvider($provider); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); + $pass->process($container); + $this->assertEquals([$provider], $tmpProviders); + } + public function testExtensionLoadGetAMergeExtensionConfigurationContainerBuilderInstance() + { + $extension = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooExtension::class)->setMethods(['load'])->getMock(); + $extension->expects($this->once())->method('load')->with($this->isType('array'), $this->isInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationContainerBuilder::class)); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag()); + $container->registerExtension($extension); + $container->prependExtensionConfig('foo', []); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); + $pass->process($container); + } + public function testExtensionConfigurationIsTrackedByDefault() + { + $extension = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooExtension::class)->setMethods(['getConfiguration'])->getMock(); + $extension->expects($this->exactly(2))->method('getConfiguration')->willReturn(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooConfiguration()); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag()); + $container->registerExtension($extension); + $container->prependExtensionConfig('foo', ['bar' => \true]); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); + $pass->process($container); + $this->assertContainsEquals(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__FILE__), $container->getResources()); + } + public function testOverriddenEnvsAreMerged() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooExtension()); + $container->prependExtensionConfig('foo', ['bar' => '%env(FOO)%']); + $container->prependExtensionConfig('foo', ['bar' => '%env(BAR)%', 'baz' => '%env(BAZ)%']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); + $pass->process($container); + $this->assertSame(['BAZ', 'FOO'], \array_keys($container->getParameterBag()->getEnvPlaceholders())); + $this->assertSame(['BAZ' => 1, 'FOO' => 0], $container->getEnvCounters()); + } + public function testProcessedEnvsAreIncompatibleWithResolve() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Using a cast in "env(int:FOO)" is incompatible with resolution at compile time in "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\BarExtension". The logic in the extension should be moved to a compiler pass, or an env parameter with no cast should be used instead.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\BarExtension()); + $container->prependExtensionConfig('bar', []); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass())->process($container); + } + public function testThrowingExtensionsGetMergedBag() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ThrowingExtension()); + $container->prependExtensionConfig('throwing', ['bar' => '%env(FOO)%']); + try { + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\MergeExtensionConfigurationPass(); + $pass->process($container); + $this->fail('An exception should have been thrown.'); + } catch (\Exception $e) { + } + $this->assertSame(['FOO'], \array_keys($container->getParameterBag()->getEnvPlaceholders())); + } +} +class FooConfiguration implements \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\ConfigurationInterface +{ + public function getConfigTreeBuilder() + { + $treeBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Definition\Builder\TreeBuilder(); + $rootNode = $treeBuilder->root('foo'); + $rootNode->children()->scalarNode('bar')->end()->scalarNode('baz')->end()->end(); + return $treeBuilder; + } +} +class FooExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension +{ + public function getAlias() + { + return 'foo'; + } + public function getConfiguration(array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooConfiguration(); + } + public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $configuration = $this->getConfiguration($configs, $container); + $config = $this->processConfiguration($configuration, $configs); + if (isset($config['baz'])) { + $container->getParameterBag()->get('env(BOZ)'); + $container->resolveEnvPlaceholders($config['baz']); + } + } +} +class BarExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension +{ + public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $container->resolveEnvPlaceholders('%env(int:FOO)%', \true); + } +} +class ThrowingExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension +{ + public function getAlias() + { + return 'throwing'; + } + public function getConfiguration(array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\FooConfiguration(); + } + public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + throw new \Exception(); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/OptionalServiceClass.php b/vendor/symfony/dependency-injection/Tests/Compiler/OptionalServiceClass.php index 147af1e25..3deaab677 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/OptionalServiceClass.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/OptionalServiceClass.php @@ -1,16 +1,16 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\Symfony\Bug\NotExistClass; -class OptionalServiceClass extends \_PhpScoper5ea00cc67502b\Symfony\Bug\NotExistClass -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\Symfony\Bug\NotExistClass; +class OptionalServiceClass extends \_PhpScoper5ea00cc67502b\Symfony\Bug\NotExistClass +{ +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/PassConfigTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/PassConfigTest.php index 103262b1e..4ee1023b9 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/PassConfigTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/PassConfigTest.php @@ -1,33 +1,33 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig; -/** - * @author Guilhem N - */ -class PassConfigTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testPassOrdering() - { - $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig(); - $config->setBeforeOptimizationPasses([]); - $pass1 = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface::class)->getMock(); - $config->addPass($pass1, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, 10); - $pass2 = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface::class)->getMock(); - $config->addPass($pass2, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, 30); - $passes = $config->getBeforeOptimizationPasses(); - $this->assertSame($pass2, $passes[0]); - $this->assertSame($pass1, $passes[1]); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig; +/** + * @author Guilhem N + */ +class PassConfigTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testPassOrdering() + { + $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig(); + $config->setBeforeOptimizationPasses([]); + $pass1 = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface::class)->getMock(); + $config->addPass($pass1, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, 10); + $pass2 = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface::class)->getMock(); + $config->addPass($pass2, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, 30); + $passes = $config->getBeforeOptimizationPasses(); + $this->assertSame($pass2, $passes[0]); + $this->assertSame($pass1, $passes[1]); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/PriorityTaggedServiceTraitTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/PriorityTaggedServiceTraitTest.php index 339becfb1..3cbbb0a56 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/PriorityTaggedServiceTraitTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/PriorityTaggedServiceTraitTest.php @@ -1,41 +1,41 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PriorityTaggedServiceTrait; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class PriorityTaggedServiceTraitTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testThatCacheWarmersAreProcessedInPriorityOrder() - { - $services = ['my_service1' => ['my_custom_tag' => ['priority' => 100]], 'my_service2' => ['my_custom_tag' => ['priority' => 200]], 'my_service3' => ['my_custom_tag' => ['priority' => -501]], 'my_service4' => ['my_custom_tag' => []], 'my_service5' => ['my_custom_tag' => ['priority' => -1]], 'my_service6' => ['my_custom_tag' => ['priority' => -500]], 'my_service7' => ['my_custom_tag' => ['priority' => -499]], 'my_service8' => ['my_custom_tag' => ['priority' => 1]], 'my_service9' => ['my_custom_tag' => ['priority' => -2]], 'my_service10' => ['my_custom_tag' => ['priority' => -1000]], 'my_service11' => ['my_custom_tag' => ['priority' => -1001]], 'my_service12' => ['my_custom_tag' => ['priority' => -1002]], 'my_service13' => ['my_custom_tag' => ['priority' => -1003]], 'my_service14' => ['my_custom_tag' => ['priority' => -1000]], 'my_service15' => ['my_custom_tag' => ['priority' => 1]], 'my_service16' => ['my_custom_tag' => ['priority' => -1]], 'my_service17' => ['my_custom_tag' => ['priority' => 200]], 'my_service18' => ['my_custom_tag' => ['priority' => 100]], 'my_service19' => ['my_custom_tag' => []]]; - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - foreach ($services as $id => $tags) { - $definition = $container->register($id); - foreach ($tags as $name => $attributes) { - $definition->addTag($name, $attributes); - } - } - $expected = [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service2'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service17'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service1'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service18'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service8'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service15'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service4'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service19'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service5'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service16'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service9'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service7'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service6'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service3'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service10'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service14'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service11'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service12'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service13')]; - $priorityTaggedServiceTraitImplementation = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\PriorityTaggedServiceTraitImplementation(); - $this->assertEquals($expected, $priorityTaggedServiceTraitImplementation->test('my_custom_tag', $container)); - } -} -class PriorityTaggedServiceTraitImplementation -{ - use PriorityTaggedServiceTrait; - public function test($tagName, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - return $this->findAndSortTaggedServices($tagName, $container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PriorityTaggedServiceTrait; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class PriorityTaggedServiceTraitTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testThatCacheWarmersAreProcessedInPriorityOrder() + { + $services = ['my_service1' => ['my_custom_tag' => ['priority' => 100]], 'my_service2' => ['my_custom_tag' => ['priority' => 200]], 'my_service3' => ['my_custom_tag' => ['priority' => -501]], 'my_service4' => ['my_custom_tag' => []], 'my_service5' => ['my_custom_tag' => ['priority' => -1]], 'my_service6' => ['my_custom_tag' => ['priority' => -500]], 'my_service7' => ['my_custom_tag' => ['priority' => -499]], 'my_service8' => ['my_custom_tag' => ['priority' => 1]], 'my_service9' => ['my_custom_tag' => ['priority' => -2]], 'my_service10' => ['my_custom_tag' => ['priority' => -1000]], 'my_service11' => ['my_custom_tag' => ['priority' => -1001]], 'my_service12' => ['my_custom_tag' => ['priority' => -1002]], 'my_service13' => ['my_custom_tag' => ['priority' => -1003]], 'my_service14' => ['my_custom_tag' => ['priority' => -1000]], 'my_service15' => ['my_custom_tag' => ['priority' => 1]], 'my_service16' => ['my_custom_tag' => ['priority' => -1]], 'my_service17' => ['my_custom_tag' => ['priority' => 200]], 'my_service18' => ['my_custom_tag' => ['priority' => 100]], 'my_service19' => ['my_custom_tag' => []]]; + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + foreach ($services as $id => $tags) { + $definition = $container->register($id); + foreach ($tags as $name => $attributes) { + $definition->addTag($name, $attributes); + } + } + $expected = [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service2'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service17'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service1'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service18'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service8'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service15'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service4'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service19'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service5'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service16'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service9'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service7'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service6'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service3'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service10'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service14'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service11'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service12'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('my_service13')]; + $priorityTaggedServiceTraitImplementation = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\PriorityTaggedServiceTraitImplementation(); + $this->assertEquals($expected, $priorityTaggedServiceTraitImplementation->test('my_custom_tag', $container)); + } +} +class PriorityTaggedServiceTraitImplementation +{ + use PriorityTaggedServiceTrait; + public function test($tagName, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + return $this->findAndSortTaggedServices($tagName, $container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/RegisterEnvVarProcessorsPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/RegisterEnvVarProcessorsPassTest.php index 838dae2d4..8ebdd9cb9 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/RegisterEnvVarProcessorsPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/RegisterEnvVarProcessorsPassTest.php @@ -1,61 +1,61 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterEnvVarProcessorsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface; -class RegisterEnvVarProcessorsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testSimpleProcessor() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SimpleProcessor::class)->addTag('container.env_var_processor'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterEnvVarProcessorsPass())->process($container); - $this->assertTrue($container->has('container.env_var_processors_locator')); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SimpleProcessor::class, $container->get('container.env_var_processors_locator')->get('foo')); - $expected = ['foo' => ['string'], 'base64' => ['string'], 'bool' => ['bool'], 'const' => ['bool', 'int', 'float', 'string', 'array'], 'file' => ['string'], 'float' => ['float'], 'int' => ['int'], 'json' => ['array'], 'resolve' => ['string'], 'string' => ['string']]; - $this->assertSame($expected, $container->getParameterBag()->getProvidedTypes()); - } - public function testNoProcessor() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterEnvVarProcessorsPass())->process($container); - $this->assertFalse($container->has('container.env_var_processors_locator')); - } - public function testBadProcessor() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Invalid type "foo" returned by "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\BadProcessor::getProvidedTypes()", expected one of "array", "bool", "float", "int", "string".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\BadProcessor::class)->addTag('container.env_var_processor'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterEnvVarProcessorsPass())->process($container); - } -} -class SimpleProcessor implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface -{ - public function getEnv($prefix, $name, \Closure $getEnv) - { - return $getEnv($name); - } - public static function getProvidedTypes() - { - return ['foo' => 'string']; - } -} -class BadProcessor extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SimpleProcessor -{ - public static function getProvidedTypes() - { - return ['foo' => 'string|foo']; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterEnvVarProcessorsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface; +class RegisterEnvVarProcessorsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testSimpleProcessor() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SimpleProcessor::class)->addTag('container.env_var_processor'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterEnvVarProcessorsPass())->process($container); + $this->assertTrue($container->has('container.env_var_processors_locator')); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SimpleProcessor::class, $container->get('container.env_var_processors_locator')->get('foo')); + $expected = ['foo' => ['string'], 'base64' => ['string'], 'bool' => ['bool'], 'const' => ['bool', 'int', 'float', 'string', 'array'], 'file' => ['string'], 'float' => ['float'], 'int' => ['int'], 'json' => ['array'], 'resolve' => ['string'], 'string' => ['string']]; + $this->assertSame($expected, $container->getParameterBag()->getProvidedTypes()); + } + public function testNoProcessor() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterEnvVarProcessorsPass())->process($container); + $this->assertFalse($container->has('container.env_var_processors_locator')); + } + public function testBadProcessor() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Invalid type "foo" returned by "Symfony\\Component\\DependencyInjection\\Tests\\Compiler\\BadProcessor::getProvidedTypes()", expected one of "array", "bool", "float", "int", "string".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\BadProcessor::class)->addTag('container.env_var_processor'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterEnvVarProcessorsPass())->process($container); + } +} +class SimpleProcessor implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface +{ + public function getEnv($prefix, $name, \Closure $getEnv) + { + return $getEnv($name); + } + public static function getProvidedTypes() + { + return ['foo' => 'string']; + } +} +class BadProcessor extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\SimpleProcessor +{ + public static function getProvidedTypes() + { + return ['foo' => 'string|foo']; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/RegisterServiceSubscribersPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/RegisterServiceSubscribersPassTest.php index 5193da027..64bb1dd22 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/RegisterServiceSubscribersPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/RegisterServiceSubscribersPassTest.php @@ -1,81 +1,81 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; -require_once __DIR__ . '/../Fixtures/includes/classes.php'; -class RegisterServiceSubscribersPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testInvalidClass() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Service "foo" must implement interface "Symfony\\Component\\DependencyInjection\\ServiceSubscriberInterface".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class)->addTag('container.service_subscriber'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass())->process($container); - } - public function testInvalidAttributes() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The "container.service_subscriber" tag accepts only the "key" and "id" attributes, "bar" given for service "foo".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->addTag('container.service_subscriber', ['bar' => '123']); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass())->process($container); - } - public function testNoAttributes() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class))->addTag('container.service_subscriber'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass())->process($container); - $foo = $container->getDefinition('foo'); - $locator = $container->getDefinition((string) $foo->getArgument(0)); - $this->assertFalse($locator->isPublic()); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class, $locator->getClass()); - $expected = [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)), 'bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)), 'baz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE))]; - $this->assertEquals($expected, $container->getDefinition((string) $locator->getFactory()[0])->getArgument(0)); - } - public function testWithAttributes() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->setAutowired(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class))->addTag('container.service_subscriber', ['key' => 'bar', 'id' => 'bar'])->addTag('container.service_subscriber', ['key' => 'bar', 'id' => 'baz']); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass())->process($container); - $foo = $container->getDefinition('foo'); - $locator = $container->getDefinition((string) $foo->getArgument(0)); - $this->assertFalse($locator->isPublic()); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class, $locator->getClass()); - $expected = [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)), 'bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)), 'baz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE))]; - $this->assertEquals($expected, $container->getDefinition((string) $locator->getFactory()[0])->getArgument(0)); - } - public function testExtraServiceSubscriber() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Service key "test" does not exist in the map returned by "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber::getSubscribedServices()" for service "foo_service".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->setAutowired(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class))->addTag('container.service_subscriber', ['key' => 'test', 'id' => \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class]); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class); - $container->compile(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; +require_once __DIR__ . '/../Fixtures/includes/classes.php'; +class RegisterServiceSubscribersPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testInvalidClass() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Service "foo" must implement interface "Symfony\\Component\\DependencyInjection\\ServiceSubscriberInterface".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class)->addTag('container.service_subscriber'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass())->process($container); + } + public function testInvalidAttributes() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The "container.service_subscriber" tag accepts only the "key" and "id" attributes, "bar" given for service "foo".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->addTag('container.service_subscriber', ['bar' => '123']); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass())->process($container); + } + public function testNoAttributes() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class))->addTag('container.service_subscriber'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass())->process($container); + $foo = $container->getDefinition('foo'); + $locator = $container->getDefinition((string) $foo->getArgument(0)); + $this->assertFalse($locator->isPublic()); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class, $locator->getClass()); + $expected = [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)), 'bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)), 'baz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE))]; + $this->assertEquals($expected, $container->getDefinition((string) $locator->getFactory()[0])->getArgument(0)); + } + public function testWithAttributes() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->setAutowired(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class))->addTag('container.service_subscriber', ['key' => 'bar', 'id' => 'bar'])->addTag('container.service_subscriber', ['key' => 'bar', 'id' => 'baz']); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RegisterServiceSubscribersPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveServiceSubscribersPass())->process($container); + $foo = $container->getDefinition('foo'); + $locator = $container->getDefinition((string) $foo->getArgument(0)); + $this->assertFalse($locator->isPublic()); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class, $locator->getClass()); + $expected = [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)), 'bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)), 'baz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE))]; + $this->assertEquals($expected, $container->getDefinition((string) $locator->getFactory()[0])->getArgument(0)); + } + public function testExtraServiceSubscriber() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Service key "test" does not exist in the map returned by "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber::getSubscribedServices()" for service "foo_service".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->setAutowired(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class))->addTag('container.service_subscriber', ['key' => 'test', 'id' => \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class]); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class); + $container->compile(); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/RemoveUnusedDefinitionsPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/RemoveUnusedDefinitionsPassTest.php index d79ad1b11..277e31027 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/RemoveUnusedDefinitionsPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/RemoveUnusedDefinitionsPassTest.php @@ -1,81 +1,81 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RemoveUnusedDefinitionsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class RemoveUnusedDefinitionsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setPublic(\false); - $container->register('bar')->setPublic(\false); - $container->register('moo')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); - $this->process($container); - $this->assertFalse($container->hasDefinition('foo')); - $this->assertTrue($container->hasDefinition('bar')); - $this->assertTrue($container->hasDefinition('moo')); - } - public function testProcessRemovesUnusedDefinitionsRecursively() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setPublic(\false); - $container->register('bar')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')])->setPublic(\false); - $this->process($container); - $this->assertFalse($container->hasDefinition('foo')); - $this->assertFalse($container->hasDefinition('bar')); - } - public function testProcessWorksWithInlinedDefinitions() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setPublic(\false); - $container->register('bar')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(null, [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')])]); - $this->process($container); - $this->assertTrue($container->hasDefinition('foo')); - $this->assertTrue($container->hasDefinition('bar')); - } - public function testProcessWontRemovePrivateFactory() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setFactory(['stdClass', 'getInstance'])->setPublic(\false); - $container->register('bar', 'stdClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 'getInstance'])->setPublic(\false); - $container->register('foobar')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')); - $this->process($container); - $this->assertTrue($container->hasDefinition('foo')); - $this->assertTrue($container->hasDefinition('bar')); - $this->assertTrue($container->hasDefinition('foobar')); - } - public function testProcessConsiderEnvVariablesAsUsedEvenInPrivateServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('env(FOOBAR)', 'test'); - $container->register('foo')->setArguments(['%env(FOOBAR)%'])->setPublic(\false); - $resolvePass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass(); - $resolvePass->process($container); - $this->process($container); - $this->assertFalse($container->hasDefinition('foo')); - $envCounters = $container->getEnvCounters(); - $this->assertArrayHasKey('FOOBAR', $envCounters); - $this->assertSame(1, $envCounters['FOOBAR']); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $repeatedPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RemoveUnusedDefinitionsPass()]); - $repeatedPass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RemoveUnusedDefinitionsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class RemoveUnusedDefinitionsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setPublic(\false); + $container->register('bar')->setPublic(\false); + $container->register('moo')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); + $this->process($container); + $this->assertFalse($container->hasDefinition('foo')); + $this->assertTrue($container->hasDefinition('bar')); + $this->assertTrue($container->hasDefinition('moo')); + } + public function testProcessRemovesUnusedDefinitionsRecursively() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setPublic(\false); + $container->register('bar')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')])->setPublic(\false); + $this->process($container); + $this->assertFalse($container->hasDefinition('foo')); + $this->assertFalse($container->hasDefinition('bar')); + } + public function testProcessWorksWithInlinedDefinitions() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setPublic(\false); + $container->register('bar')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(null, [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')])]); + $this->process($container); + $this->assertTrue($container->hasDefinition('foo')); + $this->assertTrue($container->hasDefinition('bar')); + } + public function testProcessWontRemovePrivateFactory() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setFactory(['stdClass', 'getInstance'])->setPublic(\false); + $container->register('bar', 'stdClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 'getInstance'])->setPublic(\false); + $container->register('foobar')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')); + $this->process($container); + $this->assertTrue($container->hasDefinition('foo')); + $this->assertTrue($container->hasDefinition('bar')); + $this->assertTrue($container->hasDefinition('foobar')); + } + public function testProcessConsiderEnvVariablesAsUsedEvenInPrivateServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('env(FOOBAR)', 'test'); + $container->register('foo')->setArguments(['%env(FOOBAR)%'])->setPublic(\false); + $resolvePass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass(); + $resolvePass->process($container); + $this->process($container); + $this->assertFalse($container->hasDefinition('foo')); + $envCounters = $container->getEnvCounters(); + $this->assertArrayHasKey('FOOBAR', $envCounters); + $this->assertSame(1, $envCounters['FOOBAR']); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $repeatedPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RepeatedPass([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AnalyzeServiceReferencesPass(), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\RemoveUnusedDefinitionsPass()]); + $repeatedPass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ReplaceAliasByActualDefinitionPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ReplaceAliasByActualDefinitionPassTest.php index 8e5d35eeb..e92104509 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ReplaceAliasByActualDefinitionPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ReplaceAliasByActualDefinitionPassTest.php @@ -1,53 +1,53 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ReplaceAliasByActualDefinitionPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -require_once __DIR__ . '/../Fixtures/includes/foo.php'; -class ReplaceAliasByActualDefinitionPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $aDefinition = $container->register('a', '\\stdClass'); - $aDefinition->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), 'createA']); - $bDefinition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('\\stdClass'); - $bDefinition->setPublic(\false); - $container->setDefinition('b', $bDefinition); - $container->setAlias('a_alias', 'a'); - $container->setAlias('b_alias', 'b'); - $container->setAlias('container', 'service_container'); - $this->process($container); - $this->assertTrue($container->has('a'), '->process() does nothing to public definitions.'); - $this->assertTrue($container->hasAlias('a_alias')); - $this->assertFalse($container->has('b'), '->process() removes non-public definitions.'); - $this->assertTrue($container->has('b_alias') && !$container->hasAlias('b_alias'), '->process() replaces alias to actual.'); - $this->assertTrue($container->has('container')); - $resolvedFactory = $aDefinition->getFactory(); - $this->assertSame('b_alias', (string) $resolvedFactory[0]); - } - public function testProcessWithInvalidAlias() - { - $this->expectException('InvalidArgumentException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setAlias('a_alias', 'a'); - $this->process($container); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ReplaceAliasByActualDefinitionPass(); - $pass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ReplaceAliasByActualDefinitionPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +require_once __DIR__ . '/../Fixtures/includes/foo.php'; +class ReplaceAliasByActualDefinitionPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $aDefinition = $container->register('a', '\\stdClass'); + $aDefinition->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), 'createA']); + $bDefinition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('\\stdClass'); + $bDefinition->setPublic(\false); + $container->setDefinition('b', $bDefinition); + $container->setAlias('a_alias', 'a'); + $container->setAlias('b_alias', 'b'); + $container->setAlias('container', 'service_container'); + $this->process($container); + $this->assertTrue($container->has('a'), '->process() does nothing to public definitions.'); + $this->assertTrue($container->hasAlias('a_alias')); + $this->assertFalse($container->has('b'), '->process() removes non-public definitions.'); + $this->assertTrue($container->has('b_alias') && !$container->hasAlias('b_alias'), '->process() replaces alias to actual.'); + $this->assertTrue($container->has('container')); + $resolvedFactory = $aDefinition->getFactory(); + $this->assertSame('b_alias', (string) $resolvedFactory[0]); + } + public function testProcessWithInvalidAlias() + { + $this->expectException('InvalidArgumentException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setAlias('a_alias', 'a'); + $this->process($container); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ReplaceAliasByActualDefinitionPass(); + $pass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveBindingsPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveBindingsPassTest.php index be86ac262..c075d8e34 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveBindingsPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveBindingsPassTest.php @@ -1,110 +1,110 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; -require_once __DIR__ . '/../Fixtures/includes/autowiring_classes.php'; -class ResolveBindingsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $bindings = [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))]; - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); - $definition->setArguments([1 => '123']); - $definition->addMethodCall('setSensitiveClass'); - $definition->setBindings($bindings); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->setBindings($bindings); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(); - $pass->process($container); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), '123'], $definition->getArguments()); - $this->assertEquals([['setSensitiveClass', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]]], $definition->getMethodCalls()); - } - public function testUnusedBinding() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Unused binding "$quz" in service "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\NamedArgumentsDummy".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); - $definition->setBindings(['$quz' => '123']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(); - $pass->process($container); - } - public function testMissingParent() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/Unused binding "\\$quz" in service [\\s\\S]+/'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists::class); - $definition->setBindings(['$quz' => '123']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(); - $pass->process($container); - } - public function testTypedReferenceSupport() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $bindings = [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))]; - // Explicit service id - $definition1 = $container->register('def1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); - $definition1->addArgument($typedRef = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)); - $definition1->setBindings($bindings); - $definition2 = $container->register('def2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); - $definition2->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)); - $definition2->setBindings($bindings); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(); - $pass->process($container); - $this->assertEquals([$typedRef], $container->getDefinition('def1')->getArguments()); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')], $container->getDefinition('def2')->getArguments()); - } - public function testScalarSetter() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->autowire('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ScalarSetter::class); - $definition->setBindings(['$defaultLocale' => 'fr']); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass())->process($container); - $this->assertEquals([['setDefaultLocale', ['fr']]], $definition->getMethodCalls()); - } - public function testWithNonExistingSetterAndBinding() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Invalid service "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\NamedArgumentsDummy": method "setLogger()" does not exist.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $bindings = ['$c' => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('logger'))->setFactory('logger')]; - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); - $definition->addMethodCall('setLogger'); - $definition->setBindings($bindings); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(); - $pass->process($container); - } - public function testSyntheticServiceWithBind() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $argument = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument('bar'); - $container->register('foo', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('synthetic.service')); - $container->register('synthetic.service')->setSynthetic(\true)->setBindings(['$apiKey' => $argument]); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->setBindings(['$apiKey' => $argument]); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass())->process($container); - $this->assertSame([1 => 'bar'], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getArguments()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; +require_once __DIR__ . '/../Fixtures/includes/autowiring_classes.php'; +class ResolveBindingsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $bindings = [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))]; + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); + $definition->setArguments([1 => '123']); + $definition->addMethodCall('setSensitiveClass'); + $definition->setBindings($bindings); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->setBindings($bindings); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(); + $pass->process($container); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), '123'], $definition->getArguments()); + $this->assertEquals([['setSensitiveClass', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]]], $definition->getMethodCalls()); + } + public function testUnusedBinding() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Unused binding "$quz" in service "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\NamedArgumentsDummy".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); + $definition->setBindings(['$quz' => '123']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(); + $pass->process($container); + } + public function testMissingParent() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/Unused binding "\\$quz" in service [\\s\\S]+/'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists::class); + $definition->setBindings(['$quz' => '123']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(); + $pass->process($container); + } + public function testTypedReferenceSupport() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $bindings = [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))]; + // Explicit service id + $definition1 = $container->register('def1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); + $definition1->addArgument($typedRef = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)); + $definition1->setBindings($bindings); + $definition2 = $container->register('def2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); + $definition2->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)); + $definition2->setBindings($bindings); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(); + $pass->process($container); + $this->assertEquals([$typedRef], $container->getDefinition('def1')->getArguments()); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')], $container->getDefinition('def2')->getArguments()); + } + public function testScalarSetter() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->autowire('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\ScalarSetter::class); + $definition->setBindings(['$defaultLocale' => 'fr']); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowireRequiredMethodsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass())->process($container); + $this->assertEquals([['setDefaultLocale', ['fr']]], $definition->getMethodCalls()); + } + public function testWithNonExistingSetterAndBinding() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Invalid service "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\NamedArgumentsDummy": method "setLogger()" does not exist.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $bindings = ['$c' => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('logger'))->setFactory('logger')]; + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); + $definition->addMethodCall('setLogger'); + $definition->setBindings($bindings); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass(); + $pass->process($container); + } + public function testSyntheticServiceWithBind() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $argument = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument('bar'); + $container->register('foo', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('synthetic.service')); + $container->register('synthetic.service')->setSynthetic(\true)->setBindings(['$apiKey' => $argument]); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->setBindings(['$apiKey' => $argument]); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\DefinitionErrorExceptionPass())->process($container); + $this->assertSame([1 => 'bar'], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getArguments()); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveChildDefinitionsPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveChildDefinitionsPassTest.php index b1cf53cc2..29ea96233 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveChildDefinitionsPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveChildDefinitionsPassTest.php @@ -1,251 +1,251 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -class ResolveChildDefinitionsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'foo')->setArguments(['moo', 'b'])->setProperty('foo', 'moo'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->replaceArgument(0, 'a')->setProperty('foo', 'bar')->setClass('bar'); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertNotInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class, $def); - $this->assertEquals('bar', $def->getClass()); - $this->assertEquals(['a', 'b'], $def->getArguments()); - $this->assertEquals(['foo' => 'bar'], $def->getProperties()); - } - public function testProcessAppendsMethodCallsAlways() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->addMethodCall('foo', ['bar']); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addMethodCall('bar', ['foo']); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertEquals([['foo', ['bar']], ['bar', ['foo']]], $def->getMethodCalls()); - } - public function testProcessDoesNotCopyAbstract() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->setAbstract(\true); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertFalse($def->isAbstract()); - } - public function testProcessDoesNotCopyShared() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->setShared(\false); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertTrue($def->isShared()); - } - public function testProcessDoesNotCopyTags() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->addTag('foo'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertEquals([], $def->getTags()); - } - public function testProcessDoesNotCopyDecoratedService() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->setDecoratedService('foo'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertNull($def->getDecoratedService()); - } - public function testProcessDoesNotDropShared() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setShared(\false); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertFalse($def->isShared()); - } - public function testProcessHandlesMultipleInheritance() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'foo')->setArguments(['foo', 'bar', 'c']); - $container->setDefinition('child2', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('child1'))->replaceArgument(1, 'b'); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->replaceArgument(0, 'a'); - $this->process($container); - $def = $container->getDefinition('child2'); - $this->assertEquals(['a', 'b', 'c'], $def->getArguments()); - $this->assertEquals('foo', $def->getClass()); - } - public function testSetLazyOnServiceHasParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass'); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setLazy(\true); - $this->process($container); - $this->assertTrue($container->getDefinition('child1')->isLazy()); - } - public function testSetLazyOnServiceIsParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass')->setLazy(\true); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $this->assertTrue($container->getDefinition('child1')->isLazy()); - } - public function testSetAutowiredOnServiceHasParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass')->setAutowired(\true); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setAutowired(\false); - $this->process($container); - $this->assertFalse($container->getDefinition('child1')->isAutowired()); - } - public function testSetAutowiredOnServiceIsParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass')->setAutowired(\true); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $this->assertTrue($container->getDefinition('child1')->isAutowired()); - } - public function testDeepDefinitionsResolving() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'parentClass'); - $container->register('sibling', 'siblingClass')->setConfigurator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'), 'foo')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'), 'foo'])->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setProperty('prop', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addMethodCall('meth', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')]); - $this->process($container); - $configurator = $container->getDefinition('sibling')->getConfigurator(); - $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', \get_class($configurator)); - $this->assertSame('parentClass', $configurator->getClass()); - $factory = $container->getDefinition('sibling')->getFactory(); - $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', \get_class($factory[0])); - $this->assertSame('parentClass', $factory[0]->getClass()); - $argument = $container->getDefinition('sibling')->getArgument(0); - $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', \get_class($argument)); - $this->assertSame('parentClass', $argument->getClass()); - $properties = $container->getDefinition('sibling')->getProperties(); - $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', \get_class($properties['prop'])); - $this->assertSame('parentClass', $properties['prop']->getClass()); - $methodCalls = $container->getDefinition('sibling')->getMethodCalls(); - $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', \get_class($methodCalls[0][1][0])); - $this->assertSame('parentClass', $methodCalls[0][1][0]->getClass()); - } - public function testSetDecoratedServiceOnServiceHasParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass'); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setDecoratedService('foo', 'foo_inner', 5); - $this->process($container); - $this->assertEquals(['foo', 'foo_inner', 5], $container->getDefinition('child1')->getDecoratedService()); - } - public function testDecoratedServiceCopiesDeprecatedStatusFromParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('deprecated_parent')->setDeprecated(\true); - $container->setDefinition('decorated_deprecated_parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('deprecated_parent')); - $this->process($container); - $this->assertTrue($container->getDefinition('decorated_deprecated_parent')->isDeprecated()); - } - public function testDecoratedServiceCanOverwriteDeprecatedParentStatus() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('deprecated_parent')->setDeprecated(\true); - $container->setDefinition('decorated_deprecated_parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('deprecated_parent'))->setDeprecated(\false); - $this->process($container); - $this->assertFalse($container->getDefinition('decorated_deprecated_parent')->isDeprecated()); - } - /** - * @group legacy - */ - public function testProcessMergeAutowiringTypes() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->addAutowiringType('Foo'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addAutowiringType('Bar'); - $this->process($container); - $childDef = $container->getDefinition('child'); - $this->assertEquals(['Foo', 'Bar'], $childDef->getAutowiringTypes()); - $parentDef = $container->getDefinition('parent'); - $this->assertSame(['Foo'], $parentDef->getAutowiringTypes()); - } - public function testProcessResolvesAliases() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'ParentClass'); - $container->setAlias('parent_alias', 'parent'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent_alias')); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertSame('ParentClass', $def->getClass()); - } - public function testProcessSetsArguments() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'ParentClass')->setArguments([0]); - $container->setDefinition('child', (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setArguments([1, 'index_0' => 2, 'foo' => 3])); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertSame([2, 1, 'foo' => 3], $def->getArguments()); - } - public function testBindings() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass')->setBindings(['a' => '1', 'b' => '2']); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setBindings(['b' => 'B', 'c' => 'C']); - $this->process($container); - $bindings = []; - foreach ($container->getDefinition('child')->getBindings() as $k => $v) { - $bindings[$k] = $v->getValues()[0]; - } - $this->assertEquals(['b' => 'B', 'c' => 'C', 'a' => '1'], $bindings); - } - public function testSetAutoconfiguredOnServiceIsParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass')->setAutoconfigured(\true); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $this->assertFalse($container->getDefinition('child1')->isAutoconfigured()); - } - /** - * @group legacy - */ - public function testAliasExistsForBackwardsCompatibility() - { - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass()); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass(); - $pass->process($container); - } - public function testProcessDetectsChildDefinitionIndirectCircularReference() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $this->expectExceptionMessageRegExp('/^Circular reference detected for service "c", path: "c -> b -> a -> c"./'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a'); - $container->setDefinition('b', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('a')); - $container->setDefinition('c', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('b')); - $container->setDefinition('a', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('c')); - $this->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +class ResolveChildDefinitionsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'foo')->setArguments(['moo', 'b'])->setProperty('foo', 'moo'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->replaceArgument(0, 'a')->setProperty('foo', 'bar')->setClass('bar'); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertNotInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class, $def); + $this->assertEquals('bar', $def->getClass()); + $this->assertEquals(['a', 'b'], $def->getArguments()); + $this->assertEquals(['foo' => 'bar'], $def->getProperties()); + } + public function testProcessAppendsMethodCallsAlways() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->addMethodCall('foo', ['bar']); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addMethodCall('bar', ['foo']); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertEquals([['foo', ['bar']], ['bar', ['foo']]], $def->getMethodCalls()); + } + public function testProcessDoesNotCopyAbstract() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->setAbstract(\true); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertFalse($def->isAbstract()); + } + public function testProcessDoesNotCopyShared() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->setShared(\false); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertTrue($def->isShared()); + } + public function testProcessDoesNotCopyTags() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->addTag('foo'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertEquals([], $def->getTags()); + } + public function testProcessDoesNotCopyDecoratedService() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->setDecoratedService('foo'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertNull($def->getDecoratedService()); + } + public function testProcessDoesNotDropShared() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setShared(\false); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertFalse($def->isShared()); + } + public function testProcessHandlesMultipleInheritance() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'foo')->setArguments(['foo', 'bar', 'c']); + $container->setDefinition('child2', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('child1'))->replaceArgument(1, 'b'); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->replaceArgument(0, 'a'); + $this->process($container); + $def = $container->getDefinition('child2'); + $this->assertEquals(['a', 'b', 'c'], $def->getArguments()); + $this->assertEquals('foo', $def->getClass()); + } + public function testSetLazyOnServiceHasParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass'); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setLazy(\true); + $this->process($container); + $this->assertTrue($container->getDefinition('child1')->isLazy()); + } + public function testSetLazyOnServiceIsParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass')->setLazy(\true); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $this->assertTrue($container->getDefinition('child1')->isLazy()); + } + public function testSetAutowiredOnServiceHasParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass')->setAutowired(\true); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setAutowired(\false); + $this->process($container); + $this->assertFalse($container->getDefinition('child1')->isAutowired()); + } + public function testSetAutowiredOnServiceIsParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass')->setAutowired(\true); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $this->assertTrue($container->getDefinition('child1')->isAutowired()); + } + public function testDeepDefinitionsResolving() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'parentClass'); + $container->register('sibling', 'siblingClass')->setConfigurator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'), 'foo')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'), 'foo'])->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setProperty('prop', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addMethodCall('meth', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')]); + $this->process($container); + $configurator = $container->getDefinition('sibling')->getConfigurator(); + $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', \get_class($configurator)); + $this->assertSame('parentClass', $configurator->getClass()); + $factory = $container->getDefinition('sibling')->getFactory(); + $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', \get_class($factory[0])); + $this->assertSame('parentClass', $factory[0]->getClass()); + $argument = $container->getDefinition('sibling')->getArgument(0); + $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', \get_class($argument)); + $this->assertSame('parentClass', $argument->getClass()); + $properties = $container->getDefinition('sibling')->getProperties(); + $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', \get_class($properties['prop'])); + $this->assertSame('parentClass', $properties['prop']->getClass()); + $methodCalls = $container->getDefinition('sibling')->getMethodCalls(); + $this->assertSame('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', \get_class($methodCalls[0][1][0])); + $this->assertSame('parentClass', $methodCalls[0][1][0]->getClass()); + } + public function testSetDecoratedServiceOnServiceHasParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass'); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setDecoratedService('foo', 'foo_inner', 5); + $this->process($container); + $this->assertEquals(['foo', 'foo_inner', 5], $container->getDefinition('child1')->getDecoratedService()); + } + public function testDecoratedServiceCopiesDeprecatedStatusFromParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('deprecated_parent')->setDeprecated(\true); + $container->setDefinition('decorated_deprecated_parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('deprecated_parent')); + $this->process($container); + $this->assertTrue($container->getDefinition('decorated_deprecated_parent')->isDeprecated()); + } + public function testDecoratedServiceCanOverwriteDeprecatedParentStatus() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('deprecated_parent')->setDeprecated(\true); + $container->setDefinition('decorated_deprecated_parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('deprecated_parent'))->setDeprecated(\false); + $this->process($container); + $this->assertFalse($container->getDefinition('decorated_deprecated_parent')->isDeprecated()); + } + /** + * @group legacy + */ + public function testProcessMergeAutowiringTypes() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->addAutowiringType('Foo'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addAutowiringType('Bar'); + $this->process($container); + $childDef = $container->getDefinition('child'); + $this->assertEquals(['Foo', 'Bar'], $childDef->getAutowiringTypes()); + $parentDef = $container->getDefinition('parent'); + $this->assertSame(['Foo'], $parentDef->getAutowiringTypes()); + } + public function testProcessResolvesAliases() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'ParentClass'); + $container->setAlias('parent_alias', 'parent'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent_alias')); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertSame('ParentClass', $def->getClass()); + } + public function testProcessSetsArguments() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'ParentClass')->setArguments([0]); + $container->setDefinition('child', (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setArguments([1, 'index_0' => 2, 'foo' => 3])); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertSame([2, 1, 'foo' => 3], $def->getArguments()); + } + public function testBindings() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass')->setBindings(['a' => '1', 'b' => '2']); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setBindings(['b' => 'B', 'c' => 'C']); + $this->process($container); + $bindings = []; + foreach ($container->getDefinition('child')->getBindings() as $k => $v) { + $bindings[$k] = $v->getValues()[0]; + } + $this->assertEquals(['b' => 'B', 'c' => 'C', 'a' => '1'], $bindings); + } + public function testSetAutoconfiguredOnServiceIsParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass')->setAutoconfigured(\true); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $this->assertFalse($container->getDefinition('child1')->isAutoconfigured()); + } + /** + * @group legacy + */ + public function testAliasExistsForBackwardsCompatibility() + { + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass()); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass(); + $pass->process($container); + } + public function testProcessDetectsChildDefinitionIndirectCircularReference() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $this->expectExceptionMessageRegExp('/^Circular reference detected for service "c", path: "c -> b -> a -> c"./'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a'); + $container->setDefinition('b', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('a')); + $container->setDefinition('c', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('b')); + $container->setDefinition('a', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('c')); + $this->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveClassPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveClassPassTest.php index 9105bfd54..bf6d1af4a 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveClassPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveClassPassTest.php @@ -1,78 +1,78 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; -class ResolveClassPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @dataProvider provideValidClassId - */ - public function testResolveClassFromId($serviceId) - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register($serviceId); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - $this->assertSame($serviceId, $def->getClass()); - } - public function provideValidClassId() - { - (yield ['_PhpScoper5ea00cc67502b\\Acme\\UnknownClass']); - (yield [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class]); - } - /** - * @dataProvider provideInvalidClassId - */ - public function testWontResolveClassFromId($serviceId) - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register($serviceId); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - $this->assertNull($def->getClass()); - } - public function provideInvalidClassId() - { - (yield [\stdClass::class]); - (yield ['bar']); - (yield ['\\DateTime']); - } - public function testNonFqcnChildDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $parent = $container->register('_PhpScoper5ea00cc67502b\\App\\Foo', null); - $child = $container->setDefinition('App\\Foo.child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('_PhpScoper5ea00cc67502b\\App\\Foo')); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - $this->assertSame('_PhpScoper5ea00cc67502b\\App\\Foo', $parent->getClass()); - $this->assertNull($child->getClass()); - } - public function testClassFoundChildDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $parent = $container->register('_PhpScoper5ea00cc67502b\\App\\Foo', null); - $child = $container->setDefinition(self::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('_PhpScoper5ea00cc67502b\\App\\Foo')); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - $this->assertSame('_PhpScoper5ea00cc67502b\\App\\Foo', $parent->getClass()); - $this->assertSame(self::class, $child->getClass()); - } - public function testAmbiguousChildDefinition() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Service definition "App\\Foo\\Child" has a parent but no class, and its name looks like a FQCN. Either the class is missing or you want to inherit it from the parent service. To resolve this ambiguity, please rename this service to a non-FQCN (e.g. using dots), or create the missing class.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('_PhpScoper5ea00cc67502b\\App\\Foo', null); - $container->setDefinition('_PhpScoper5ea00cc67502b\\App\\Foo\\Child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('_PhpScoper5ea00cc67502b\\App\\Foo')); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; +class ResolveClassPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @dataProvider provideValidClassId + */ + public function testResolveClassFromId($serviceId) + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register($serviceId); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + $this->assertSame($serviceId, $def->getClass()); + } + public function provideValidClassId() + { + (yield ['_PhpScoper5ea00cc67502b\\Acme\\UnknownClass']); + (yield [\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class]); + } + /** + * @dataProvider provideInvalidClassId + */ + public function testWontResolveClassFromId($serviceId) + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register($serviceId); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + $this->assertNull($def->getClass()); + } + public function provideInvalidClassId() + { + (yield [\stdClass::class]); + (yield ['bar']); + (yield ['\\DateTime']); + } + public function testNonFqcnChildDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $parent = $container->register('_PhpScoper5ea00cc67502b\\App\\Foo', null); + $child = $container->setDefinition('App\\Foo.child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('_PhpScoper5ea00cc67502b\\App\\Foo')); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + $this->assertSame('_PhpScoper5ea00cc67502b\\App\\Foo', $parent->getClass()); + $this->assertNull($child->getClass()); + } + public function testClassFoundChildDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $parent = $container->register('_PhpScoper5ea00cc67502b\\App\\Foo', null); + $child = $container->setDefinition(self::class, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('_PhpScoper5ea00cc67502b\\App\\Foo')); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + $this->assertSame('_PhpScoper5ea00cc67502b\\App\\Foo', $parent->getClass()); + $this->assertSame(self::class, $child->getClass()); + } + public function testAmbiguousChildDefinition() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Service definition "App\\Foo\\Child" has a parent but no class, and its name looks like a FQCN. Either the class is missing or you want to inherit it from the parent service. To resolve this ambiguity, please rename this service to a non-FQCN (e.g. using dots), or create the missing class.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('_PhpScoper5ea00cc67502b\\App\\Foo', null); + $container->setDefinition('_PhpScoper5ea00cc67502b\\App\\Foo\\Child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('_PhpScoper5ea00cc67502b\\App\\Foo')); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveClassPass())->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php index f97e8b110..009f4451a 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveDefinitionTemplatesPassTest.php @@ -1,223 +1,223 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -/** - * @group legacy - */ -class ResolveDefinitionTemplatesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'foo')->setArguments(['moo', 'b'])->setProperty('foo', 'moo'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->replaceArgument(0, 'a')->setProperty('foo', 'bar')->setClass('bar'); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertNotInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class, $def); - $this->assertEquals('bar', $def->getClass()); - $this->assertEquals(['a', 'b'], $def->getArguments()); - $this->assertEquals(['foo' => 'bar'], $def->getProperties()); - } - public function testProcessAppendsMethodCallsAlways() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->addMethodCall('foo', ['bar']); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addMethodCall('bar', ['foo']); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertEquals([['foo', ['bar']], ['bar', ['foo']]], $def->getMethodCalls()); - } - public function testProcessDoesNotCopyAbstract() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->setAbstract(\true); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertFalse($def->isAbstract()); - } - public function testProcessDoesNotCopyShared() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->setShared(\false); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertTrue($def->isShared()); - } - public function testProcessDoesNotCopyTags() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->addTag('foo'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertEquals([], $def->getTags()); - } - public function testProcessDoesNotCopyDecoratedService() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->setDecoratedService('foo'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertNull($def->getDecoratedService()); - } - public function testProcessDoesNotDropShared() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setShared(\false); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertFalse($def->isShared()); - } - public function testProcessHandlesMultipleInheritance() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'foo')->setArguments(['foo', 'bar', 'c']); - $container->setDefinition('child2', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('child1'))->replaceArgument(1, 'b'); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->replaceArgument(0, 'a'); - $this->process($container); - $def = $container->getDefinition('child2'); - $this->assertEquals(['a', 'b', 'c'], $def->getArguments()); - $this->assertEquals('foo', $def->getClass()); - } - public function testSetLazyOnServiceHasParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass'); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setLazy(\true); - $this->process($container); - $this->assertTrue($container->getDefinition('child1')->isLazy()); - } - public function testSetLazyOnServiceIsParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass')->setLazy(\true); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $this->assertTrue($container->getDefinition('child1')->isLazy()); - } - public function testSetAutowiredOnServiceHasParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass')->setAutowired(\true); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setAutowired(\false); - $this->process($container); - $this->assertFalse($container->getDefinition('child1')->isAutowired()); - } - public function testSetAutowiredOnServiceIsParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass')->setAutowired(\true); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $this->assertTrue($container->getDefinition('child1')->isAutowired()); - } - public function testDeepDefinitionsResolving() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'parentClass'); - $container->register('sibling', 'siblingClass')->setConfigurator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'), 'foo')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'), 'foo'])->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setProperty('prop', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addMethodCall('meth', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')]); - $this->process($container); - $configurator = $container->getDefinition('sibling')->getConfigurator(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $configurator); - $this->assertSame('parentClass', $configurator->getClass()); - $factory = $container->getDefinition('sibling')->getFactory(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $factory[0]); - $this->assertSame('parentClass', $factory[0]->getClass()); - $argument = $container->getDefinition('sibling')->getArgument(0); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $argument); - $this->assertSame('parentClass', $argument->getClass()); - $properties = $container->getDefinition('sibling')->getProperties(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $properties['prop']); - $this->assertSame('parentClass', $properties['prop']->getClass()); - $methodCalls = $container->getDefinition('sibling')->getMethodCalls(); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $methodCalls[0][1][0]); - $this->assertSame('parentClass', $methodCalls[0][1][0]->getClass()); - } - public function testSetDecoratedServiceOnServiceHasParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass'); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setDecoratedService('foo', 'foo_inner', 5); - $this->process($container); - $this->assertEquals(['foo', 'foo_inner', 5], $container->getDefinition('child1')->getDecoratedService()); - } - public function testDecoratedServiceCopiesDeprecatedStatusFromParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('deprecated_parent')->setDeprecated(\true); - $container->setDefinition('decorated_deprecated_parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('deprecated_parent')); - $this->process($container); - $this->assertTrue($container->getDefinition('decorated_deprecated_parent')->isDeprecated()); - } - public function testDecoratedServiceCanOverwriteDeprecatedParentStatus() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('deprecated_parent')->setDeprecated(\true); - $container->setDefinition('decorated_deprecated_parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('deprecated_parent'))->setDeprecated(\false); - $this->process($container); - $this->assertFalse($container->getDefinition('decorated_deprecated_parent')->isDeprecated()); - } - /** - * @group legacy - */ - public function testProcessMergeAutowiringTypes() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent')->addAutowiringType('Foo'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addAutowiringType('Bar'); - $this->process($container); - $childDef = $container->getDefinition('child'); - $this->assertEquals(['Foo', 'Bar'], $childDef->getAutowiringTypes()); - $parentDef = $container->getDefinition('parent'); - $this->assertSame(['Foo'], $parentDef->getAutowiringTypes()); - } - public function testProcessResolvesAliases() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'ParentClass'); - $container->setAlias('parent_alias', 'parent'); - $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent_alias')); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertSame('ParentClass', $def->getClass()); - } - public function testProcessSetsArguments() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'ParentClass')->setArguments([0]); - $container->setDefinition('child', (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setArguments([1, 'index_0' => 2, 'foo' => 3])); - $this->process($container); - $def = $container->getDefinition('child'); - $this->assertSame([2, 1, 'foo' => 3], $def->getArguments()); - } - public function testSetAutoconfiguredOnServiceIsParent() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('parent', 'stdClass')->setAutoconfigured(\true); - $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $this->process($container); - $this->assertFalse($container->getDefinition('child1')->isAutoconfigured()); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass(); - $pass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +/** + * @group legacy + */ +class ResolveDefinitionTemplatesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'foo')->setArguments(['moo', 'b'])->setProperty('foo', 'moo'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->replaceArgument(0, 'a')->setProperty('foo', 'bar')->setClass('bar'); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertNotInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class, $def); + $this->assertEquals('bar', $def->getClass()); + $this->assertEquals(['a', 'b'], $def->getArguments()); + $this->assertEquals(['foo' => 'bar'], $def->getProperties()); + } + public function testProcessAppendsMethodCallsAlways() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->addMethodCall('foo', ['bar']); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addMethodCall('bar', ['foo']); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertEquals([['foo', ['bar']], ['bar', ['foo']]], $def->getMethodCalls()); + } + public function testProcessDoesNotCopyAbstract() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->setAbstract(\true); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertFalse($def->isAbstract()); + } + public function testProcessDoesNotCopyShared() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->setShared(\false); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertTrue($def->isShared()); + } + public function testProcessDoesNotCopyTags() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->addTag('foo'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertEquals([], $def->getTags()); + } + public function testProcessDoesNotCopyDecoratedService() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->setDecoratedService('foo'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertNull($def->getDecoratedService()); + } + public function testProcessDoesNotDropShared() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setShared(\false); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertFalse($def->isShared()); + } + public function testProcessHandlesMultipleInheritance() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'foo')->setArguments(['foo', 'bar', 'c']); + $container->setDefinition('child2', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('child1'))->replaceArgument(1, 'b'); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->replaceArgument(0, 'a'); + $this->process($container); + $def = $container->getDefinition('child2'); + $this->assertEquals(['a', 'b', 'c'], $def->getArguments()); + $this->assertEquals('foo', $def->getClass()); + } + public function testSetLazyOnServiceHasParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass'); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setLazy(\true); + $this->process($container); + $this->assertTrue($container->getDefinition('child1')->isLazy()); + } + public function testSetLazyOnServiceIsParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass')->setLazy(\true); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $this->assertTrue($container->getDefinition('child1')->isLazy()); + } + public function testSetAutowiredOnServiceHasParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass')->setAutowired(\true); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setAutowired(\false); + $this->process($container); + $this->assertFalse($container->getDefinition('child1')->isAutowired()); + } + public function testSetAutowiredOnServiceIsParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass')->setAutowired(\true); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $this->assertTrue($container->getDefinition('child1')->isAutowired()); + } + public function testDeepDefinitionsResolving() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'parentClass'); + $container->register('sibling', 'siblingClass')->setConfigurator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'), 'foo')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'), 'foo'])->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setProperty('prop', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addMethodCall('meth', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')]); + $this->process($container); + $configurator = $container->getDefinition('sibling')->getConfigurator(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $configurator); + $this->assertSame('parentClass', $configurator->getClass()); + $factory = $container->getDefinition('sibling')->getFactory(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $factory[0]); + $this->assertSame('parentClass', $factory[0]->getClass()); + $argument = $container->getDefinition('sibling')->getArgument(0); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $argument); + $this->assertSame('parentClass', $argument->getClass()); + $properties = $container->getDefinition('sibling')->getProperties(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $properties['prop']); + $this->assertSame('parentClass', $properties['prop']->getClass()); + $methodCalls = $container->getDefinition('sibling')->getMethodCalls(); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $methodCalls[0][1][0]); + $this->assertSame('parentClass', $methodCalls[0][1][0]->getClass()); + } + public function testSetDecoratedServiceOnServiceHasParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass'); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setDecoratedService('foo', 'foo_inner', 5); + $this->process($container); + $this->assertEquals(['foo', 'foo_inner', 5], $container->getDefinition('child1')->getDecoratedService()); + } + public function testDecoratedServiceCopiesDeprecatedStatusFromParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('deprecated_parent')->setDeprecated(\true); + $container->setDefinition('decorated_deprecated_parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('deprecated_parent')); + $this->process($container); + $this->assertTrue($container->getDefinition('decorated_deprecated_parent')->isDeprecated()); + } + public function testDecoratedServiceCanOverwriteDeprecatedParentStatus() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('deprecated_parent')->setDeprecated(\true); + $container->setDefinition('decorated_deprecated_parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('deprecated_parent'))->setDeprecated(\false); + $this->process($container); + $this->assertFalse($container->getDefinition('decorated_deprecated_parent')->isDeprecated()); + } + /** + * @group legacy + */ + public function testProcessMergeAutowiringTypes() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent')->addAutowiringType('Foo'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->addAutowiringType('Bar'); + $this->process($container); + $childDef = $container->getDefinition('child'); + $this->assertEquals(['Foo', 'Bar'], $childDef->getAutowiringTypes()); + $parentDef = $container->getDefinition('parent'); + $this->assertSame(['Foo'], $parentDef->getAutowiringTypes()); + } + public function testProcessResolvesAliases() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'ParentClass'); + $container->setAlias('parent_alias', 'parent'); + $container->setDefinition('child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent_alias')); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertSame('ParentClass', $def->getClass()); + } + public function testProcessSetsArguments() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'ParentClass')->setArguments([0]); + $container->setDefinition('child', (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setArguments([1, 'index_0' => 2, 'foo' => 3])); + $this->process($container); + $def = $container->getDefinition('child'); + $this->assertSame([2, 1, 'foo' => 3], $def->getArguments()); + } + public function testSetAutoconfiguredOnServiceIsParent() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('parent', 'stdClass')->setAutoconfigured(\true); + $container->setDefinition('child1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $this->process($container); + $this->assertFalse($container->getDefinition('child1')->isAutoconfigured()); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveDefinitionTemplatesPass(); + $pass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveFactoryClassPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveFactoryClassPassTest.php index c6f211f9f..55dde33a7 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveFactoryClassPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveFactoryClassPassTest.php @@ -1,65 +1,65 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class ResolveFactoryClassPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $factory = $container->register('factory', '_PhpScoper5ea00cc67502b\\Foo\\Bar'); - $factory->setFactory([null, 'create']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass(); - $pass->process($container); - $this->assertSame(['_PhpScoper5ea00cc67502b\\Foo\\Bar', 'create'], $factory->getFactory()); - } - public function testInlinedDefinitionFactoryIsProcessed() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $factory = $container->register('factory'); - $factory->setFactory([(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\Baz\\Qux'))->setFactory([null, 'getInstance']), 'create']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass(); - $pass->process($container); - $this->assertSame(['_PhpScoper5ea00cc67502b\\Baz\\Qux', 'getInstance'], $factory->getFactory()[0]->getFactory()); - } - public function provideFulfilledFactories() - { - return [[['_PhpScoper5ea00cc67502b\\Foo\\Bar', 'create']], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 'create']], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Baz'), 'create']]]; - } - /** - * @dataProvider provideFulfilledFactories - */ - public function testIgnoresFulfilledFactories($factory) - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $definition->setFactory($factory); - $container->setDefinition('factory', $definition); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass(); - $pass->process($container); - $this->assertSame($factory, $container->getDefinition('factory')->getFactory()); - } - public function testNotAnyClassThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('The "factory" service is defined to be created by a factory, but is missing the factory class. Did you forget to define the factory or service class?'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $factory = $container->register('factory'); - $factory->setFactory([null, 'create']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass(); - $pass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class ResolveFactoryClassPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $factory = $container->register('factory', '_PhpScoper5ea00cc67502b\\Foo\\Bar'); + $factory->setFactory([null, 'create']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass(); + $pass->process($container); + $this->assertSame(['_PhpScoper5ea00cc67502b\\Foo\\Bar', 'create'], $factory->getFactory()); + } + public function testInlinedDefinitionFactoryIsProcessed() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $factory = $container->register('factory'); + $factory->setFactory([(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\Baz\\Qux'))->setFactory([null, 'getInstance']), 'create']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass(); + $pass->process($container); + $this->assertSame(['_PhpScoper5ea00cc67502b\\Baz\\Qux', 'getInstance'], $factory->getFactory()[0]->getFactory()); + } + public function provideFulfilledFactories() + { + return [[['_PhpScoper5ea00cc67502b\\Foo\\Bar', 'create']], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 'create']], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Baz'), 'create']]]; + } + /** + * @dataProvider provideFulfilledFactories + */ + public function testIgnoresFulfilledFactories($factory) + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $definition->setFactory($factory); + $container->setDefinition('factory', $definition); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass(); + $pass->process($container); + $this->assertSame($factory, $container->getDefinition('factory')->getFactory()); + } + public function testNotAnyClassThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('The "factory" service is defined to be created by a factory, but is missing the factory class. Did you forget to define the factory or service class?'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $factory = $container->register('factory'); + $factory->setFactory([null, 'create']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveFactoryClassPass(); + $pass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveHotPathPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveHotPathPassTest.php index 5571728ca..e6b88a64e 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveHotPathPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveHotPathPassTest.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveHotPathPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class ResolveHotPathPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->addTag('container.hot_path')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('lazy')]))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::IGNORE_ON_UNINITIALIZED_REFERENCE))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('missing')); - $container->register('lazy'); - $container->register('bar')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('buz'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('deprec_ref_notag')); - $container->register('baz')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('lazy'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('lazy')); - $container->register('buz'); - $container->register('deprec_with_tag')->setDeprecated()->addTag('container.hot_path'); - $container->register('deprec_ref_notag')->setDeprecated(); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveHotPathPass())->process($container); - $this->assertFalse($container->getDefinition('lazy')->hasTag('container.hot_path')); - $this->assertTrue($container->getDefinition('bar')->hasTag('container.hot_path')); - $this->assertTrue($container->getDefinition('buz')->hasTag('container.hot_path')); - $this->assertFalse($container->getDefinition('baz')->hasTag('container.hot_path')); - $this->assertFalse($container->getDefinition('service_container')->hasTag('container.hot_path')); - $this->assertFalse($container->getDefinition('deprec_with_tag')->hasTag('container.hot_path')); - $this->assertFalse($container->getDefinition('deprec_ref_notag')->hasTag('container.hot_path')); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveHotPathPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class ResolveHotPathPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->addTag('container.hot_path')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('lazy')]))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::IGNORE_ON_UNINITIALIZED_REFERENCE))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('missing')); + $container->register('lazy'); + $container->register('bar')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('buz'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('deprec_ref_notag')); + $container->register('baz')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('lazy'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('lazy')); + $container->register('buz'); + $container->register('deprec_with_tag')->setDeprecated()->addTag('container.hot_path'); + $container->register('deprec_ref_notag')->setDeprecated(); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveHotPathPass())->process($container); + $this->assertFalse($container->getDefinition('lazy')->hasTag('container.hot_path')); + $this->assertTrue($container->getDefinition('bar')->hasTag('container.hot_path')); + $this->assertTrue($container->getDefinition('buz')->hasTag('container.hot_path')); + $this->assertFalse($container->getDefinition('baz')->hasTag('container.hot_path')); + $this->assertFalse($container->getDefinition('service_container')->hasTag('container.hot_path')); + $this->assertFalse($container->getDefinition('deprec_with_tag')->hasTag('container.hot_path')); + $this->assertFalse($container->getDefinition('deprec_ref_notag')->hasTag('container.hot_path')); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInstanceofConditionalsPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInstanceofConditionalsPassTest.php index 20e0631d7..806f4e4e3 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInstanceofConditionalsPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInstanceofConditionalsPassTest.php @@ -1,169 +1,169 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -class ResolveInstanceofConditionalsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('foo', self::class)->addTag('tag')->setAutowired(\true)->setChanges([]); - $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->setProperty('foo', 'bar')->addTag('baz', ['attr' => 123])]); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - $parent = 'instanceof.' . parent::class . '.0.foo'; - $def = $container->getDefinition('foo'); - $this->assertEmpty($def->getInstanceofConditionals()); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class, $def); - $this->assertTrue($def->isAutowired()); - $this->assertSame($parent, $def->getParent()); - $this->assertSame(['tag' => [[]], 'baz' => [['attr' => 123]]], $def->getTags()); - $parent = $container->getDefinition($parent); - $this->assertSame(['foo' => 'bar'], $parent->getProperties()); - $this->assertSame([], $parent->getTags()); - } - public function testProcessInheritance() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('parent', parent::class)->addMethodCall('foo', ['foo']); - $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addMethodCall('foo', ['bar'])]); - $def = (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setClass(self::class); - $container->setDefinition('child', $def); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass())->process($container); - $expected = [['foo', ['bar']], ['foo', ['foo']]]; - $this->assertSame($expected, $container->getDefinition('parent')->getMethodCalls()); - $this->assertSame($expected, $container->getDefinition('child')->getMethodCalls()); - } - public function testProcessDoesReplaceShared() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('foo', 'stdClass'); - $def->setInstanceofConditionals(['stdClass' => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->setShared(\false)]); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - $def = $container->getDefinition('foo'); - $this->assertFalse($def->isShared()); - } - public function testProcessHandlesMultipleInheritance() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('foo', self::class)->setShared(\true); - $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->setLazy(\true)->setShared(\false), self::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->setAutowired(\true)]); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass())->process($container); - $def = $container->getDefinition('foo'); - $this->assertTrue($def->isAutowired()); - $this->assertTrue($def->isLazy()); - $this->assertTrue($def->isShared()); - } - public function testProcessUsesAutoconfiguredInstanceof() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('normal_service', self::class); - $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addTag('local_instanceof_tag')->setFactory('locally_set_factory')]); - $def->setAutoconfigured(\true); - $container->registerForAutoconfiguration(parent::class)->addTag('autoconfigured_tag')->setAutowired(\true)->setFactory('autoconfigured_factory'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass())->process($container); - $def = $container->getDefinition('normal_service'); - // autowired thanks to the autoconfigured instanceof - $this->assertTrue($def->isAutowired()); - // factory from the specific instanceof overrides global one - $this->assertEquals('locally_set_factory', $def->getFactory()); - // tags are merged, the locally set one is first - $this->assertSame(['local_instanceof_tag' => [[]], 'autoconfigured_tag' => [[]]], $def->getTags()); - } - public function testAutoconfigureInstanceofDoesNotDuplicateTags() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('normal_service', self::class); - $def->addTag('duplicated_tag')->addTag('duplicated_tag', ['and_attributes' => 1]); - $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addTag('duplicated_tag')]); - $def->setAutoconfigured(\true); - $container->registerForAutoconfiguration(parent::class)->addTag('duplicated_tag', ['and_attributes' => 1]); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass())->process($container); - $def = $container->getDefinition('normal_service'); - $this->assertSame(['duplicated_tag' => [[], ['and_attributes' => 1]]], $def->getTags()); - } - public function testProcessDoesNotUseAutoconfiguredInstanceofIfNotEnabled() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('normal_service', self::class); - $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addTag('foo_tag')]); - $container->registerForAutoconfiguration(parent::class)->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass())->process($container); - $def = $container->getDefinition('normal_service'); - $this->assertFalse($def->isAutowired()); - } - public function testBadInterfaceThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('"App\\FakeInterface" is set as an "instanceof" conditional, but it does not exist.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('normal_service', self::class); - $def->setInstanceofConditionals(['_PhpScoper5ea00cc67502b\\App\\FakeInterface' => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addTag('foo_tag')]); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - } - public function testBadInterfaceForAutomaticInstanceofIsOk() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('normal_service', self::class)->setAutoconfigured(\true); - $container->registerForAutoconfiguration('_PhpScoper5ea00cc67502b\\App\\FakeInterface')->setAutowired(\true); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - $this->assertTrue($container->hasDefinition('normal_service')); - } - public function testProcessThrowsExceptionForAutoconfiguredCalls() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/Autoconfigured instanceof for type "PHPUnit[\\\\_]Framework[\\\\_]TestCase" defines method calls but these are not supported and should be removed\\./'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerForAutoconfiguration(parent::class)->addMethodCall('setFoo'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - } - public function testProcessThrowsExceptionForArguments() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/Autoconfigured instanceof for type "PHPUnit[\\\\_]Framework[\\\\_]TestCase" defines arguments but these are not supported and should be removed\\./'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerForAutoconfiguration(parent::class)->addArgument('bar'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - } - public function testMergeReset() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('bar', self::class)->addArgument('a')->addMethodCall('setB')->setDecoratedService('foo')->addTag('t')->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addTag('bar')]); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - $abstract = $container->getDefinition('abstract.instanceof.bar'); - $this->assertEmpty($abstract->getArguments()); - $this->assertEmpty($abstract->getMethodCalls()); - $this->assertNull($abstract->getDecoratedService()); - $this->assertEmpty($abstract->getTags()); - $this->assertTrue($abstract->isAbstract()); - } - public function testBindings() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('foo', self::class)->setBindings(['$toto' => 123]); - $def->setInstanceofConditionals([parent::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('')]); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); - $bindings = $container->getDefinition('foo')->getBindings(); - $this->assertSame(['$toto'], \array_keys($bindings)); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument::class, $bindings['$toto']); - $this->assertSame(123, $bindings['$toto']->getValues()[0]); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +class ResolveInstanceofConditionalsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('foo', self::class)->addTag('tag')->setAutowired(\true)->setChanges([]); + $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->setProperty('foo', 'bar')->addTag('baz', ['attr' => 123])]); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + $parent = 'instanceof.' . parent::class . '.0.foo'; + $def = $container->getDefinition('foo'); + $this->assertEmpty($def->getInstanceofConditionals()); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition::class, $def); + $this->assertTrue($def->isAutowired()); + $this->assertSame($parent, $def->getParent()); + $this->assertSame(['tag' => [[]], 'baz' => [['attr' => 123]]], $def->getTags()); + $parent = $container->getDefinition($parent); + $this->assertSame(['foo' => 'bar'], $parent->getProperties()); + $this->assertSame([], $parent->getTags()); + } + public function testProcessInheritance() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('parent', parent::class)->addMethodCall('foo', ['foo']); + $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addMethodCall('foo', ['bar'])]); + $def = (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent'))->setClass(self::class); + $container->setDefinition('child', $def); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass())->process($container); + $expected = [['foo', ['bar']], ['foo', ['foo']]]; + $this->assertSame($expected, $container->getDefinition('parent')->getMethodCalls()); + $this->assertSame($expected, $container->getDefinition('child')->getMethodCalls()); + } + public function testProcessDoesReplaceShared() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('foo', 'stdClass'); + $def->setInstanceofConditionals(['stdClass' => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->setShared(\false)]); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + $def = $container->getDefinition('foo'); + $this->assertFalse($def->isShared()); + } + public function testProcessHandlesMultipleInheritance() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('foo', self::class)->setShared(\true); + $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->setLazy(\true)->setShared(\false), self::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->setAutowired(\true)]); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass())->process($container); + $def = $container->getDefinition('foo'); + $this->assertTrue($def->isAutowired()); + $this->assertTrue($def->isLazy()); + $this->assertTrue($def->isShared()); + } + public function testProcessUsesAutoconfiguredInstanceof() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('normal_service', self::class); + $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addTag('local_instanceof_tag')->setFactory('locally_set_factory')]); + $def->setAutoconfigured(\true); + $container->registerForAutoconfiguration(parent::class)->addTag('autoconfigured_tag')->setAutowired(\true)->setFactory('autoconfigured_factory'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass())->process($container); + $def = $container->getDefinition('normal_service'); + // autowired thanks to the autoconfigured instanceof + $this->assertTrue($def->isAutowired()); + // factory from the specific instanceof overrides global one + $this->assertEquals('locally_set_factory', $def->getFactory()); + // tags are merged, the locally set one is first + $this->assertSame(['local_instanceof_tag' => [[]], 'autoconfigured_tag' => [[]]], $def->getTags()); + } + public function testAutoconfigureInstanceofDoesNotDuplicateTags() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('normal_service', self::class); + $def->addTag('duplicated_tag')->addTag('duplicated_tag', ['and_attributes' => 1]); + $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addTag('duplicated_tag')]); + $def->setAutoconfigured(\true); + $container->registerForAutoconfiguration(parent::class)->addTag('duplicated_tag', ['and_attributes' => 1]); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass())->process($container); + $def = $container->getDefinition('normal_service'); + $this->assertSame(['duplicated_tag' => [[], ['and_attributes' => 1]]], $def->getTags()); + } + public function testProcessDoesNotUseAutoconfiguredInstanceofIfNotEnabled() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('normal_service', self::class); + $def->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addTag('foo_tag')]); + $container->registerForAutoconfiguration(parent::class)->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveChildDefinitionsPass())->process($container); + $def = $container->getDefinition('normal_service'); + $this->assertFalse($def->isAutowired()); + } + public function testBadInterfaceThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('"App\\FakeInterface" is set as an "instanceof" conditional, but it does not exist.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('normal_service', self::class); + $def->setInstanceofConditionals(['_PhpScoper5ea00cc67502b\\App\\FakeInterface' => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addTag('foo_tag')]); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + } + public function testBadInterfaceForAutomaticInstanceofIsOk() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('normal_service', self::class)->setAutoconfigured(\true); + $container->registerForAutoconfiguration('_PhpScoper5ea00cc67502b\\App\\FakeInterface')->setAutowired(\true); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + $this->assertTrue($container->hasDefinition('normal_service')); + } + public function testProcessThrowsExceptionForAutoconfiguredCalls() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/Autoconfigured instanceof for type "PHPUnit[\\\\_]Framework[\\\\_]TestCase" defines method calls but these are not supported and should be removed\\./'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerForAutoconfiguration(parent::class)->addMethodCall('setFoo'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + } + public function testProcessThrowsExceptionForArguments() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/Autoconfigured instanceof for type "PHPUnit[\\\\_]Framework[\\\\_]TestCase" defines arguments but these are not supported and should be removed\\./'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerForAutoconfiguration(parent::class)->addArgument('bar'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + } + public function testMergeReset() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('bar', self::class)->addArgument('a')->addMethodCall('setB')->setDecoratedService('foo')->addTag('t')->setInstanceofConditionals([parent::class => (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition(''))->addTag('bar')]); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + $abstract = $container->getDefinition('abstract.instanceof.bar'); + $this->assertEmpty($abstract->getArguments()); + $this->assertEmpty($abstract->getMethodCalls()); + $this->assertNull($abstract->getDecoratedService()); + $this->assertEmpty($abstract->getTags()); + $this->assertTrue($abstract->isAbstract()); + } + public function testBindings() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('foo', self::class)->setBindings(['$toto' => 123]); + $def->setInstanceofConditionals([parent::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('')]); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInstanceofConditionalsPass())->process($container); + $bindings = $container->getDefinition('foo')->getBindings(); + $this->assertSame(['$toto'], \array_keys($bindings)); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument::class, $bindings['$toto']); + $this->assertSame(123, $bindings['$toto']->getValues()[0]); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInvalidReferencesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInvalidReferencesPassTest.php index f93f4cf72..2b75b3741 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInvalidReferencesPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveInvalidReferencesPassTest.php @@ -1,76 +1,76 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInvalidReferencesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class ResolveInvalidReferencesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('foo')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)])->addMethodCall('foo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('moo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)]); - $this->process($container); - $arguments = $def->getArguments(); - $this->assertSame([null, null], $arguments); - $this->assertCount(0, $def->getMethodCalls()); - } - public function testProcessIgnoreInvalidArgumentInCollectionArgument() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('baz'); - $def = $container->register('foo')->setArguments([[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE), $baz = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('moo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE)]]); - $this->process($container); - $arguments = $def->getArguments(); - $this->assertSame([$baz, null], $arguments[0]); - } - public function testProcessKeepMethodCallOnInvalidArgumentInCollectionArgument() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('baz'); - $def = $container->register('foo')->addMethodCall('foo', [[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE), $baz = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('moo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE)]]); - $this->process($container); - $calls = $def->getMethodCalls(); - $this->assertCount(1, $def->getMethodCalls()); - $this->assertSame([$baz, null], $calls[0][1][0]); - } - public function testProcessIgnoreNonExistentServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('foo')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); - $this->process($container); - $arguments = $def->getArguments(); - $this->assertEquals('bar', (string) $arguments[0]); - } - public function testProcessRemovesPropertiesOnInvalid() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('foo')->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)); - $this->process($container); - $this->assertEquals([], $def->getProperties()); - } - public function testProcessRemovesArgumentsOnInvalid() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = $container->register('foo')->addArgument([[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE))]]); - $this->process($container); - $this->assertSame([[[]]], $def->getArguments()); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInvalidReferencesPass(); - $pass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInvalidReferencesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class ResolveInvalidReferencesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('foo')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)])->addMethodCall('foo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('moo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)]); + $this->process($container); + $arguments = $def->getArguments(); + $this->assertSame([null, null], $arguments); + $this->assertCount(0, $def->getMethodCalls()); + } + public function testProcessIgnoreInvalidArgumentInCollectionArgument() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('baz'); + $def = $container->register('foo')->setArguments([[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE), $baz = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('moo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE)]]); + $this->process($container); + $arguments = $def->getArguments(); + $this->assertSame([$baz, null], $arguments[0]); + } + public function testProcessKeepMethodCallOnInvalidArgumentInCollectionArgument() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('baz'); + $def = $container->register('foo')->addMethodCall('foo', [[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE), $baz = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('moo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE)]]); + $this->process($container); + $calls = $def->getMethodCalls(); + $this->assertCount(1, $def->getMethodCalls()); + $this->assertSame([$baz, null], $calls[0][1][0]); + } + public function testProcessIgnoreNonExistentServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('foo')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); + $this->process($container); + $arguments = $def->getArguments(); + $this->assertEquals('bar', (string) $arguments[0]); + } + public function testProcessRemovesPropertiesOnInvalid() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('foo')->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)); + $this->process($container); + $this->assertEquals([], $def->getProperties()); + } + public function testProcessRemovesArgumentsOnInvalid() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = $container->register('foo')->addArgument([[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE))]]); + $this->process($container); + $this->assertSame([[[]]], $def->getArguments()); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveInvalidReferencesPass(); + $pass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveNamedArgumentsPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveNamedArgumentsPassTest.php index f74700a3e..e8d1f2d8a 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveNamedArgumentsPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveNamedArgumentsPassTest.php @@ -1,129 +1,129 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummyWithoutReturnTypes; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1; -/** - * @author Kévin Dunglas - */ -class ResolveNamedArgumentsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); - $definition->setArguments([2 => 'http://api.example.com', '$apiKey' => '123', 0 => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); - $definition->addMethodCall('setApiKey', ['$apiKey' => '123']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); - $pass->process($container); - $this->assertEquals([0 => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 1 => '123', 2 => 'http://api.example.com'], $definition->getArguments()); - $this->assertEquals([['setApiKey', ['123']]], $definition->getMethodCalls()); - } - public function testWithFactory() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('factory', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NoConstructor::class); - $definition = $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NoConstructor::class)->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory'), 'create'])->setArguments(['$apiKey' => '123']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); - $pass->process($container); - $this->assertSame([0 => '123'], $definition->getArguments()); - } - public function testClassNull() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); - $definition->setArguments(['$apiKey' => '123']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); - $pass->process($container); - } - public function testClassNotExist() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotExist::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotExist::class); - $definition->setArguments(['$apiKey' => '123']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); - $pass->process($container); - } - public function testClassNoConstructor() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NoConstructor::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NoConstructor::class); - $definition->setArguments(['$apiKey' => '123']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); - $pass->process($container); - } - public function testArgumentNotFound() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Invalid service "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\NamedArgumentsDummy": method "__construct()" has no argument named "$notFound". Check your service definition.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); - $definition->setArguments(['$notFound' => '123']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); - $pass->process($container); - } - public function testCorrectMethodReportedInException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Invalid service "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestDefinition1": method "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\FactoryDummyWithoutReturnTypes::createTestDefinition1()" has no argument named "$notFound". Check your service definition.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummyWithoutReturnTypes::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummyWithoutReturnTypes::class); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1::class); - $definition->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummyWithoutReturnTypes::class, 'createTestDefinition1']); - $definition->setArguments(['$notFound' => '123']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); - $pass->process($container); - } - public function testTypedArgument() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); - $definition->setArguments(['$apiKey' => '123', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); - $pass->process($container); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), '123'], $definition->getArguments()); - } - public function testResolvesMultipleArgumentsOfTheSameType() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy::class); - $definition->setArguments([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), '$token' => 'qwerty']); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); - $pass->process($container); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 'qwerty', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')], $definition->getArguments()); - } - public function testResolvePrioritizeNamedOverType() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy::class); - $definition->setArguments([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), '$token' => 'qwerty', '$class1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); - $pass->process($container); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), 'qwerty', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')], $definition->getArguments()); - } -} -class NoConstructor -{ - public static function create($apiKey) - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummyWithoutReturnTypes; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1; +/** + * @author Kévin Dunglas + */ +class ResolveNamedArgumentsPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); + $definition->setArguments([2 => 'http://api.example.com', '$apiKey' => '123', 0 => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); + $definition->addMethodCall('setApiKey', ['$apiKey' => '123']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); + $pass->process($container); + $this->assertEquals([0 => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 1 => '123', 2 => 'http://api.example.com'], $definition->getArguments()); + $this->assertEquals([['setApiKey', ['123']]], $definition->getMethodCalls()); + } + public function testWithFactory() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('factory', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NoConstructor::class); + $definition = $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NoConstructor::class)->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory'), 'create'])->setArguments(['$apiKey' => '123']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); + $pass->process($container); + $this->assertSame([0 => '123'], $definition->getArguments()); + } + public function testClassNull() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); + $definition->setArguments(['$apiKey' => '123']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); + $pass->process($container); + } + public function testClassNotExist() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotExist::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotExist::class); + $definition->setArguments(['$apiKey' => '123']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); + $pass->process($container); + } + public function testClassNoConstructor() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NoConstructor::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NoConstructor::class); + $definition->setArguments(['$apiKey' => '123']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); + $pass->process($container); + } + public function testArgumentNotFound() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Invalid service "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\NamedArgumentsDummy": method "__construct()" has no argument named "$notFound". Check your service definition.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); + $definition->setArguments(['$notFound' => '123']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); + $pass->process($container); + } + public function testCorrectMethodReportedInException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Invalid service "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestDefinition1": method "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\FactoryDummyWithoutReturnTypes::createTestDefinition1()" has no argument named "$notFound". Check your service definition.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummyWithoutReturnTypes::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummyWithoutReturnTypes::class); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1::class); + $definition->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummyWithoutReturnTypes::class, 'createTestDefinition1']); + $definition->setArguments(['$notFound' => '123']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); + $pass->process($container); + } + public function testTypedArgument() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class); + $definition->setArguments(['$apiKey' => '123', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); + $pass->process($container); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), '123'], $definition->getArguments()); + } + public function testResolvesMultipleArgumentsOfTheSameType() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy::class); + $definition->setArguments([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), '$token' => 'qwerty']); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); + $pass->process($container); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), 'qwerty', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')], $definition->getArguments()); + } + public function testResolvePrioritizeNamedOverType() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy::class); + $definition->setArguments([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), '$token' => 'qwerty', '$class1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveNamedArgumentsPass(); + $pass->process($container); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), 'qwerty', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')], $definition->getArguments()); + } +} +class NoConstructor +{ + public static function create($apiKey) + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveParameterPlaceHoldersPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveParameterPlaceHoldersPassTest.php index 7b5b1908a..8b4c27458 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveParameterPlaceHoldersPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveParameterPlaceHoldersPassTest.php @@ -1,103 +1,103 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; -class ResolveParameterPlaceHoldersPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - private $compilerPass; - private $container; - private $fooDefinition; - protected function setUp() - { - $this->compilerPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass(); - $this->container = $this->createContainerBuilder(); - $this->compilerPass->process($this->container); - $this->fooDefinition = $this->container->getDefinition('foo'); - } - public function testClassParametersShouldBeResolved() - { - $this->assertSame('Foo', $this->fooDefinition->getClass()); - } - public function testFactoryParametersShouldBeResolved() - { - $this->assertSame(['FooFactory', 'getFoo'], $this->fooDefinition->getFactory()); - } - public function testArgumentParametersShouldBeResolved() - { - $this->assertSame(['bar', ['bar' => 'baz']], $this->fooDefinition->getArguments()); - } - public function testMethodCallParametersShouldBeResolved() - { - $this->assertSame([['foobar', ['bar', ['bar' => 'baz']]]], $this->fooDefinition->getMethodCalls()); - } - public function testPropertyParametersShouldBeResolved() - { - $this->assertSame(['bar' => 'baz'], $this->fooDefinition->getProperties()); - } - public function testFileParametersShouldBeResolved() - { - $this->assertSame('foo.php', $this->fooDefinition->getFile()); - } - public function testAliasParametersShouldBeResolved() - { - $this->assertSame('foo', $this->container->getAlias('bar')->__toString()); - } - public function testBindingsShouldBeResolved() - { - list($boundValue) = $this->container->getDefinition('foo')->getBindings()['$baz']->getValues(); - $this->assertSame($this->container->getParameterBag()->resolveValue('%env(BAZ)%'), $boundValue); - } - public function testParameterNotFoundExceptionsIsThrown() - { - $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException::class); - $this->expectExceptionMessage('The service "baz_service_id" has a dependency on a non-existent parameter "non_existent_param".'); - $containerBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $containerBuilder->register('baz_service_id'); - $definition->setArgument(0, '%non_existent_param%'); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass(); - $pass->process($containerBuilder); - } - public function testParameterNotFoundExceptionsIsNotThrown() - { - $containerBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = $containerBuilder->register('baz_service_id'); - $definition->setArgument(0, '%non_existent_param%'); - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass(\true, \false); - $pass->process($containerBuilder); - $this->assertCount(1, $definition->getErrors()); - } - private function createContainerBuilder() - { - $containerBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $containerBuilder->setParameter('foo.class', 'Foo'); - $containerBuilder->setParameter('foo.factory.class', 'FooFactory'); - $containerBuilder->setParameter('foo.arg1', 'bar'); - $containerBuilder->setParameter('foo.arg2', ['%foo.arg1%' => 'baz']); - $containerBuilder->setParameter('foo.method', 'foobar'); - $containerBuilder->setParameter('foo.property.name', 'bar'); - $containerBuilder->setParameter('foo.property.value', 'baz'); - $containerBuilder->setParameter('foo.file', 'foo.php'); - $containerBuilder->setParameter('alias.id', 'bar'); - $fooDefinition = $containerBuilder->register('foo', '%foo.class%'); - $fooDefinition->setFactory(['%foo.factory.class%', 'getFoo']); - $fooDefinition->setArguments(['%foo.arg1%', ['%foo.arg1%' => 'baz']]); - $fooDefinition->addMethodCall('%foo.method%', ['%foo.arg1%', '%foo.arg2%']); - $fooDefinition->setProperty('%foo.property.name%', '%foo.property.value%'); - $fooDefinition->setFile('%foo.file%'); - $fooDefinition->setBindings(['$baz' => '%env(BAZ)%']); - $containerBuilder->setAlias('%alias.id%', 'foo'); - return $containerBuilder; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; +class ResolveParameterPlaceHoldersPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + private $compilerPass; + private $container; + private $fooDefinition; + protected function setUp() + { + $this->compilerPass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass(); + $this->container = $this->createContainerBuilder(); + $this->compilerPass->process($this->container); + $this->fooDefinition = $this->container->getDefinition('foo'); + } + public function testClassParametersShouldBeResolved() + { + $this->assertSame('Foo', $this->fooDefinition->getClass()); + } + public function testFactoryParametersShouldBeResolved() + { + $this->assertSame(['FooFactory', 'getFoo'], $this->fooDefinition->getFactory()); + } + public function testArgumentParametersShouldBeResolved() + { + $this->assertSame(['bar', ['bar' => 'baz']], $this->fooDefinition->getArguments()); + } + public function testMethodCallParametersShouldBeResolved() + { + $this->assertSame([['foobar', ['bar', ['bar' => 'baz']]]], $this->fooDefinition->getMethodCalls()); + } + public function testPropertyParametersShouldBeResolved() + { + $this->assertSame(['bar' => 'baz'], $this->fooDefinition->getProperties()); + } + public function testFileParametersShouldBeResolved() + { + $this->assertSame('foo.php', $this->fooDefinition->getFile()); + } + public function testAliasParametersShouldBeResolved() + { + $this->assertSame('foo', $this->container->getAlias('bar')->__toString()); + } + public function testBindingsShouldBeResolved() + { + list($boundValue) = $this->container->getDefinition('foo')->getBindings()['$baz']->getValues(); + $this->assertSame($this->container->getParameterBag()->resolveValue('%env(BAZ)%'), $boundValue); + } + public function testParameterNotFoundExceptionsIsThrown() + { + $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException::class); + $this->expectExceptionMessage('The service "baz_service_id" has a dependency on a non-existent parameter "non_existent_param".'); + $containerBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $containerBuilder->register('baz_service_id'); + $definition->setArgument(0, '%non_existent_param%'); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass(); + $pass->process($containerBuilder); + } + public function testParameterNotFoundExceptionsIsNotThrown() + { + $containerBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = $containerBuilder->register('baz_service_id'); + $definition->setArgument(0, '%non_existent_param%'); + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveParameterPlaceHoldersPass(\true, \false); + $pass->process($containerBuilder); + $this->assertCount(1, $definition->getErrors()); + } + private function createContainerBuilder() + { + $containerBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $containerBuilder->setParameter('foo.class', 'Foo'); + $containerBuilder->setParameter('foo.factory.class', 'FooFactory'); + $containerBuilder->setParameter('foo.arg1', 'bar'); + $containerBuilder->setParameter('foo.arg2', ['%foo.arg1%' => 'baz']); + $containerBuilder->setParameter('foo.method', 'foobar'); + $containerBuilder->setParameter('foo.property.name', 'bar'); + $containerBuilder->setParameter('foo.property.value', 'baz'); + $containerBuilder->setParameter('foo.file', 'foo.php'); + $containerBuilder->setParameter('alias.id', 'bar'); + $fooDefinition = $containerBuilder->register('foo', '%foo.class%'); + $fooDefinition->setFactory(['%foo.factory.class%', 'getFoo']); + $fooDefinition->setArguments(['%foo.arg1%', ['%foo.arg1%' => 'baz']]); + $fooDefinition->addMethodCall('%foo.method%', ['%foo.arg1%', '%foo.arg2%']); + $fooDefinition->setProperty('%foo.property.name%', '%foo.property.value%'); + $fooDefinition->setFile('%foo.file%'); + $fooDefinition->setBindings(['$baz' => '%env(BAZ)%']); + $containerBuilder->setAlias('%alias.id%', 'foo'); + return $containerBuilder; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolvePrivatesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolvePrivatesPassTest.php index 4cf292128..177e0c9f3 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolvePrivatesPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolvePrivatesPassTest.php @@ -1,27 +1,27 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolvePrivatesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -class ResolvePrivatesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testPrivateHasHigherPrecedenceThanPublic() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setPublic(\true)->setPrivate(\true); - $container->setAlias('bar', 'foo')->setPublic(\false)->setPrivate(\false); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolvePrivatesPass())->process($container); - $this->assertFalse($container->getDefinition('foo')->isPublic()); - $this->assertFalse($container->getAlias('bar')->isPublic()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolvePrivatesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +class ResolvePrivatesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testPrivateHasHigherPrecedenceThanPublic() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setPublic(\true)->setPrivate(\true); + $container->setAlias('bar', 'foo')->setPublic(\false)->setPrivate(\false); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolvePrivatesPass())->process($container); + $this->assertFalse($container->getDefinition('foo')->isPublic()); + $this->assertFalse($container->getAlias('bar')->isPublic()); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveReferencesToAliasesPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveReferencesToAliasesPassTest.php index c12bcbf90..381d38973 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveReferencesToAliasesPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveReferencesToAliasesPassTest.php @@ -1,70 +1,70 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveReferencesToAliasesPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class ResolveReferencesToAliasesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setAlias('bar', 'foo'); - $def = $container->register('moo')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); - $this->process($container); - $arguments = $def->getArguments(); - $this->assertEquals('foo', (string) $arguments[0]); - } - public function testProcessRecursively() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setAlias('bar', 'foo'); - $container->setAlias('moo', 'bar'); - $def = $container->register('foobar')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('moo')]); - $this->process($container); - $arguments = $def->getArguments(); - $this->assertEquals('foo', (string) $arguments[0]); - } - public function testAliasCircularReference() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setAlias('bar', 'foo'); - $container->setAlias('foo', 'bar'); - $this->process($container); - } - public function testResolveFactory() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('factory', 'Factory'); - $container->setAlias('factory_alias', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('factory')); - $foo = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $foo->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory_alias'), 'createFoo']); - $container->setDefinition('foo', $foo); - $bar = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $bar->setFactory(['Factory', 'createFoo']); - $container->setDefinition('bar', $bar); - $this->process($container); - $resolvedFooFactory = $container->getDefinition('foo')->getFactory(); - $resolvedBarFactory = $container->getDefinition('bar')->getFactory(); - $this->assertSame('factory', (string) $resolvedFooFactory[0]); - $this->assertSame('Factory', (string) $resolvedBarFactory[0]); - } - protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveReferencesToAliasesPass(); - $pass->process($container); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveReferencesToAliasesPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class ResolveReferencesToAliasesPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setAlias('bar', 'foo'); + $def = $container->register('moo')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); + $this->process($container); + $arguments = $def->getArguments(); + $this->assertEquals('foo', (string) $arguments[0]); + } + public function testProcessRecursively() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setAlias('bar', 'foo'); + $container->setAlias('moo', 'bar'); + $def = $container->register('foobar')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('moo')]); + $this->process($container); + $arguments = $def->getArguments(); + $this->assertEquals('foo', (string) $arguments[0]); + } + public function testAliasCircularReference() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setAlias('bar', 'foo'); + $container->setAlias('foo', 'bar'); + $this->process($container); + } + public function testResolveFactory() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('factory', 'Factory'); + $container->setAlias('factory_alias', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('factory')); + $foo = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $foo->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory_alias'), 'createFoo']); + $container->setDefinition('foo', $foo); + $bar = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $bar->setFactory(['Factory', 'createFoo']); + $container->setDefinition('bar', $bar); + $this->process($container); + $resolvedFooFactory = $container->getDefinition('foo')->getFactory(); + $resolvedBarFactory = $container->getDefinition('bar')->getFactory(); + $this->assertSame('factory', (string) $resolvedFooFactory[0]); + $this->assertSame('Factory', (string) $resolvedBarFactory[0]); + } + protected function process(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + $pass = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveReferencesToAliasesPass(); + $pass->process($container); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveTaggedIteratorArgumentPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveTaggedIteratorArgumentPassTest.php index fe05cc653..8cca54cd2 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ResolveTaggedIteratorArgumentPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ResolveTaggedIteratorArgumentPassTest.php @@ -1,36 +1,36 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveTaggedIteratorArgumentPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -/** - * @author Roland Franssen - */ -class ResolveTaggedIteratorArgumentPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testProcess() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('a', 'stdClass')->addTag('foo'); - $container->register('b', 'stdClass')->addTag('foo', ['priority' => 20]); - $container->register('c', 'stdClass')->addTag('foo', ['priority' => 10]); - $container->register('d', 'stdClass')->setProperty('foos', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument('foo')); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveTaggedIteratorArgumentPass())->process($container); - $properties = $container->getDefinition('d')->getProperties(); - $expected = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument('foo'); - $expected->setValues([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')]); - $this->assertEquals($expected, $properties['foos']); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveTaggedIteratorArgumentPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +/** + * @author Roland Franssen + */ +class ResolveTaggedIteratorArgumentPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testProcess() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('a', 'stdClass')->addTag('foo'); + $container->register('b', 'stdClass')->addTag('foo', ['priority' => 20]); + $container->register('c', 'stdClass')->addTag('foo', ['priority' => 10]); + $container->register('d', 'stdClass')->setProperty('foos', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument('foo')); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveTaggedIteratorArgumentPass())->process($container); + $properties = $container->getDefinition('d')->getProperties(); + $expected = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument('foo'); + $expected->setValues([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('b'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('c'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('a')]); + $this->assertEquals($expected, $properties['foos']); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/ServiceLocatorTagPassTest.php b/vendor/symfony/dependency-injection/Tests/Compiler/ServiceLocatorTagPassTest.php index f33154e13..749819827 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/ServiceLocatorTagPassTest.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/ServiceLocatorTagPassTest.php @@ -1,87 +1,87 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition2; -require_once __DIR__ . '/../Fixtures/includes/classes.php'; -class ServiceLocatorTagPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testNoServices() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Invalid definition for service "foo": an array of references is expected as first argument when the "container.service_locator" tag is set.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->addTag('container.service_locator'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass())->process($container); - } - public function testInvalidServices() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Invalid definition for service "foo": an array of references is expected as first argument when the "container.service_locator" tag is set, "string" found for key "0".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setArguments([['dummy']])->addTag('container.service_locator'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass())->process($container); - } - public function testProcessValue() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class); - $container->register('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setArguments([[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'some.service' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]])->addTag('container.service_locator'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass())->process($container); - /** @var ServiceLocator $locator */ - $locator = $container->get('foo'); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \get_class($locator('bar'))); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \get_class($locator('baz'))); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \get_class($locator('some.service'))); - } - public function testServiceWithKeyOverwritesPreviousInheritedKey() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1::class); - $container->register('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition2::class); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setArguments([[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), 'bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')]])->addTag('container.service_locator'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass())->process($container); - /** @var ServiceLocator $locator */ - $locator = $container->get('foo'); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition2::class, \get_class($locator('bar'))); - } - public function testInheritedKeyOverwritesPreviousServiceWithKey() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1::class); - $container->register('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition2::class); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setArguments([['bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), 16 => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')]])->addTag('container.service_locator'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass())->process($container); - /** @var ServiceLocator $locator */ - $locator = $container->get('foo'); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1::class, \get_class($locator('bar'))); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition2::class, \get_class($locator(16))); - } - public function testBindingsAreCopied() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo')->setBindings(['foo' => 'foo']); - $locator = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass::register($container, ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')], 'foo'); - $locator = $container->getDefinition($locator); - $locator = $container->getDefinition($locator->getFactory()[0]); - $this->assertSame(['foo'], \array_keys($locator->getBindings())); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument::class, $locator->getBindings()['foo']); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition2; +require_once __DIR__ . '/../Fixtures/includes/classes.php'; +class ServiceLocatorTagPassTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testNoServices() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Invalid definition for service "foo": an array of references is expected as first argument when the "container.service_locator" tag is set.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->addTag('container.service_locator'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass())->process($container); + } + public function testInvalidServices() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Invalid definition for service "foo": an array of references is expected as first argument when the "container.service_locator" tag is set, "string" found for key "0".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setArguments([['dummy']])->addTag('container.service_locator'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass())->process($container); + } + public function testProcessValue() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class); + $container->register('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setArguments([[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'some.service' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]])->addTag('container.service_locator'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass())->process($container); + /** @var ServiceLocator $locator */ + $locator = $container->get('foo'); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \get_class($locator('bar'))); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \get_class($locator('baz'))); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \get_class($locator('some.service'))); + } + public function testServiceWithKeyOverwritesPreviousInheritedKey() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1::class); + $container->register('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition2::class); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setArguments([[new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), 'bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')]])->addTag('container.service_locator'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass())->process($container); + /** @var ServiceLocator $locator */ + $locator = $container->get('foo'); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition2::class, \get_class($locator('bar'))); + } + public function testInheritedKeyOverwritesPreviousServiceWithKey() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1::class); + $container->register('baz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition2::class); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setArguments([['bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), 16 => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')]])->addTag('container.service_locator'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass())->process($container); + /** @var ServiceLocator $locator */ + $locator = $container->get('foo'); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition1::class, \get_class($locator('bar'))); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestDefinition2::class, \get_class($locator(16))); + } + public function testBindingsAreCopied() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo')->setBindings(['foo' => 'foo']); + $locator = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ServiceLocatorTagPass::register($container, ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')], 'foo'); + $locator = $container->getDefinition($locator); + $locator = $container->getDefinition($locator->getFactory()[0]); + $this->assertSame(['foo'], \array_keys($locator->getBindings())); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\BoundArgument::class, $locator->getBindings()['foo']); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Compiler/index.php b/vendor/symfony/dependency-injection/Tests/Compiler/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Compiler/index.php +++ b/vendor/symfony/dependency-injection/Tests/Compiler/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Config/AutowireServiceResourceTest.php b/vendor/symfony/dependency-injection/Tests/Config/AutowireServiceResourceTest.php index b6bce722b..7268a7cb2 100644 --- a/vendor/symfony/dependency-injection/Tests/Config/AutowireServiceResourceTest.php +++ b/vendor/symfony/dependency-injection/Tests/Config/AutowireServiceResourceTest.php @@ -1,90 +1,90 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Config; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource; -/** - * @group legacy - */ -class AutowireServiceResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @var AutowireServiceResource - */ - private $resource; - private $file; - private $class; - private $time; - protected function setUp() - { - $this->file = \realpath(\sys_get_temp_dir()) . '/tmp.php'; - $this->time = \time(); - \touch($this->file, $this->time); - $this->class = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Config\Foo::class; - $this->resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource($this->class, $this->file, []); - } - public function testToString() - { - $this->assertSame('service.autowire.' . $this->class, (string) $this->resource); - } - public function testSerializeUnserialize() - { - $unserialized = \unserialize(\serialize($this->resource)); - $this->assertEquals($this->resource, $unserialized); - } - public function testIsFresh() - { - $this->assertTrue($this->resource->isFresh($this->time), '->isFresh() returns true if the resource has not changed in same second'); - $this->assertTrue($this->resource->isFresh($this->time + 10), '->isFresh() returns true if the resource has not changed'); - $this->assertFalse($this->resource->isFresh($this->time - 86400), '->isFresh() returns false if the resource has been updated'); - } - public function testIsFreshForDeletedResources() - { - \unlink($this->file); - $this->assertFalse($this->resource->isFresh($this->getStaleFileTime()), '->isFresh() returns false if the resource does not exist'); - } - public function testIsNotFreshChangedResource() - { - $oldResource = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource($this->class, $this->file, ['will_be_different']); - // test with a stale file *and* a resource that *will* be different than the actual - $this->assertFalse($oldResource->isFresh($this->getStaleFileTime()), '->isFresh() returns false if the constructor arguments have changed'); - } - public function testIsFreshSameConstructorArgs() - { - $oldResource = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::createResourceForClass(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Config\Foo::class)); - // test with a stale file *but* the resource will not be changed - $this->assertTrue($oldResource->isFresh($this->getStaleFileTime()), '->isFresh() returns false if the constructor arguments have changed'); - } - public function testNotFreshIfClassNotFound() - { - $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource('_PhpScoper5ea00cc67502b\\Some\\Non\\Existent\\Class', $this->file, []); - $this->assertFalse($resource->isFresh($this->getStaleFileTime()), '->isFresh() returns false if the class no longer exists'); - } - protected function tearDown() - { - if (!\file_exists($this->file)) { - return; - } - \unlink($this->file); - } - private function getStaleFileTime() - { - return $this->time - 10; - } -} -class Foo -{ - public function __construct($foo) - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Config; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource; +/** + * @group legacy + */ +class AutowireServiceResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @var AutowireServiceResource + */ + private $resource; + private $file; + private $class; + private $time; + protected function setUp() + { + $this->file = \realpath(\sys_get_temp_dir()) . '/tmp.php'; + $this->time = \time(); + \touch($this->file, $this->time); + $this->class = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Config\Foo::class; + $this->resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource($this->class, $this->file, []); + } + public function testToString() + { + $this->assertSame('service.autowire.' . $this->class, (string) $this->resource); + } + public function testSerializeUnserialize() + { + $unserialized = \unserialize(\serialize($this->resource)); + $this->assertEquals($this->resource, $unserialized); + } + public function testIsFresh() + { + $this->assertTrue($this->resource->isFresh($this->time), '->isFresh() returns true if the resource has not changed in same second'); + $this->assertTrue($this->resource->isFresh($this->time + 10), '->isFresh() returns true if the resource has not changed'); + $this->assertFalse($this->resource->isFresh($this->time - 86400), '->isFresh() returns false if the resource has been updated'); + } + public function testIsFreshForDeletedResources() + { + \unlink($this->file); + $this->assertFalse($this->resource->isFresh($this->getStaleFileTime()), '->isFresh() returns false if the resource does not exist'); + } + public function testIsNotFreshChangedResource() + { + $oldResource = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource($this->class, $this->file, ['will_be_different']); + // test with a stale file *and* a resource that *will* be different than the actual + $this->assertFalse($oldResource->isFresh($this->getStaleFileTime()), '->isFresh() returns false if the constructor arguments have changed'); + } + public function testIsFreshSameConstructorArgs() + { + $oldResource = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\AutowirePass::createResourceForClass(new \ReflectionClass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Config\Foo::class)); + // test with a stale file *but* the resource will not be changed + $this->assertTrue($oldResource->isFresh($this->getStaleFileTime()), '->isFresh() returns false if the constructor arguments have changed'); + } + public function testNotFreshIfClassNotFound() + { + $resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\AutowireServiceResource('_PhpScoper5ea00cc67502b\\Some\\Non\\Existent\\Class', $this->file, []); + $this->assertFalse($resource->isFresh($this->getStaleFileTime()), '->isFresh() returns false if the class no longer exists'); + } + protected function tearDown() + { + if (!\file_exists($this->file)) { + return; + } + \unlink($this->file); + } + private function getStaleFileTime() + { + return $this->time - 10; + } +} +class Foo +{ + public function __construct($foo) + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Config/ContainerParametersResourceCheckerTest.php b/vendor/symfony/dependency-injection/Tests/Config/ContainerParametersResourceCheckerTest.php index 9059d401f..ab07ac50c 100644 --- a/vendor/symfony/dependency-injection/Tests/Config/ContainerParametersResourceCheckerTest.php +++ b/vendor/symfony/dependency-injection/Tests/Config/ContainerParametersResourceCheckerTest.php @@ -1,58 +1,58 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Config; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject; -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResourceChecker; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -class ContainerParametersResourceCheckerTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** @var ContainerParametersResource */ - private $resource; - /** @var ResourceCheckerInterface */ - private $resourceChecker; - /** @var ContainerInterface */ - private $container; - protected function setUp() - { - $this->resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResource(['locales' => ['fr', 'en'], 'default_locale' => 'fr']); - $this->container = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class)->getMock(); - $this->resourceChecker = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResourceChecker($this->container); - } - public function testSupports() - { - $this->assertTrue($this->resourceChecker->supports($this->resource)); - } - /** - * @dataProvider isFreshProvider - */ - public function testIsFresh(callable $mockContainer, $expected) - { - $mockContainer($this->container); - $this->assertSame($expected, $this->resourceChecker->isFresh($this->resource, \time())); - } - public function isFreshProvider() - { - (yield 'not fresh on missing parameter' => [function (\_PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject $container) { - $container->method('hasParameter')->with('locales')->willReturn(\false); - }, \false]); - (yield 'not fresh on different value' => [function (\_PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject $container) { - $container->method('getParameter')->with('locales')->willReturn(['nl', 'es']); - }, \false]); - (yield 'fresh on every identical parameters' => [function (\_PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject $container) { - $container->expects($this->exactly(2))->method('hasParameter')->willReturn(\true); - $container->expects($this->exactly(2))->method('getParameter')->withConsecutive([$this->equalTo('locales')], [$this->equalTo('default_locale')])->willReturnMap([['locales', ['fr', 'en']], ['default_locale', 'fr']]); - }, \true]); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Config; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject; +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\ResourceCheckerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResourceChecker; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +class ContainerParametersResourceCheckerTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** @var ContainerParametersResource */ + private $resource; + /** @var ResourceCheckerInterface */ + private $resourceChecker; + /** @var ContainerInterface */ + private $container; + protected function setUp() + { + $this->resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResource(['locales' => ['fr', 'en'], 'default_locale' => 'fr']); + $this->container = $this->getMockBuilder(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class)->getMock(); + $this->resourceChecker = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResourceChecker($this->container); + } + public function testSupports() + { + $this->assertTrue($this->resourceChecker->supports($this->resource)); + } + /** + * @dataProvider isFreshProvider + */ + public function testIsFresh(callable $mockContainer, $expected) + { + $mockContainer($this->container); + $this->assertSame($expected, $this->resourceChecker->isFresh($this->resource, \time())); + } + public function isFreshProvider() + { + (yield 'not fresh on missing parameter' => [function (\_PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject $container) { + $container->method('hasParameter')->with('locales')->willReturn(\false); + }, \false]); + (yield 'not fresh on different value' => [function (\_PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject $container) { + $container->method('getParameter')->with('locales')->willReturn(['nl', 'es']); + }, \false]); + (yield 'fresh on every identical parameters' => [function (\_PhpScoper5ea00cc67502b\PHPUnit\Framework\MockObject\MockObject $container) { + $container->expects($this->exactly(2))->method('hasParameter')->willReturn(\true); + $container->expects($this->exactly(2))->method('getParameter')->withConsecutive([$this->equalTo('locales')], [$this->equalTo('default_locale')])->willReturnMap([['locales', ['fr', 'en']], ['default_locale', 'fr']]); + }, \true]); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Config/ContainerParametersResourceTest.php b/vendor/symfony/dependency-injection/Tests/Config/ContainerParametersResourceTest.php index a9dfa24aa..adcf711f2 100644 --- a/vendor/symfony/dependency-injection/Tests/Config/ContainerParametersResourceTest.php +++ b/vendor/symfony/dependency-injection/Tests/Config/ContainerParametersResourceTest.php @@ -1,36 +1,36 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Config; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResource; -class ContainerParametersResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** @var ContainerParametersResource */ - private $resource; - protected function setUp() - { - $this->resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResource(['locales' => ['fr', 'en'], 'default_locale' => 'fr']); - } - public function testToString() - { - $this->assertSame('container_parameters_9893d3133814ab03cac3490f36dece77', (string) $this->resource); - } - public function testSerializeUnserialize() - { - $unserialized = \unserialize(\serialize($this->resource)); - $this->assertEquals($this->resource, $unserialized); - } - public function testGetParameters() - { - $this->assertSame(['locales' => ['fr', 'en'], 'default_locale' => 'fr'], $this->resource->getParameters()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Config; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResource; +class ContainerParametersResourceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** @var ContainerParametersResource */ + private $resource; + protected function setUp() + { + $this->resource = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Config\ContainerParametersResource(['locales' => ['fr', 'en'], 'default_locale' => 'fr']); + } + public function testToString() + { + $this->assertSame('container_parameters_9893d3133814ab03cac3490f36dece77', (string) $this->resource); + } + public function testSerializeUnserialize() + { + $unserialized = \unserialize(\serialize($this->resource)); + $this->assertEquals($this->resource, $unserialized); + } + public function testGetParameters() + { + $this->assertSame(['locales' => ['fr', 'en'], 'default_locale' => 'fr'], $this->resource->getParameters()); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Config/index.php b/vendor/symfony/dependency-injection/Tests/Config/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Config/index.php +++ b/vendor/symfony/dependency-injection/Tests/Config/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/ContainerBuilderTest.php b/vendor/symfony/dependency-injection/Tests/ContainerBuilderTest.php index 0ae4b8c1f..1c7bf4254 100644 --- a/vendor/symfony/dependency-injection/Tests/ContainerBuilderTest.php +++ b/vendor/symfony/dependency-injection/Tests/ContainerBuilderTest.php @@ -1,1143 +1,1143 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; - -require_once __DIR__ . '/Fixtures/includes/classes.php'; -require_once __DIR__ . '/Fixtures/includes/ProjectExtension.php'; -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ScalarFactory; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -class ContainerBuilderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testDefaultRegisteredDefinitions() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $this->assertCount(1, $builder->getDefinitions()); - $this->assertTrue($builder->hasDefinition('service_container')); - $definition = $builder->getDefinition('service_container'); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition::class, $definition); - $this->assertTrue($definition->isSynthetic()); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class, $definition->getClass()); - $this->assertTrue($builder->hasAlias(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class)); - $this->assertTrue($builder->hasAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class)); - } - public function testDefinitions() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definitions = ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\Bar\\FooClass'), 'bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BarClass')]; - $builder->setDefinitions($definitions); - $this->assertEquals($definitions, $builder->getDefinitions(), '->setDefinitions() sets the service definitions'); - $this->assertTrue($builder->hasDefinition('foo'), '->hasDefinition() returns true if a service definition exists'); - $this->assertFalse($builder->hasDefinition('foobar'), '->hasDefinition() returns false if a service definition does not exist'); - $builder->setDefinition('foobar', $foo = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooBarClass')); - $this->assertEquals($foo, $builder->getDefinition('foobar'), '->getDefinition() returns a service definition if defined'); - $this->assertSame($builder->setDefinition('foobar', $foo = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooBarClass')), $foo, '->setDefinition() implements a fluid interface by returning the service reference'); - $builder->addDefinitions($defs = ['foobar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooBarClass')]); - $this->assertEquals(\array_merge($definitions, $defs), $builder->getDefinitions(), '->addDefinitions() adds the service definitions'); - try { - $builder->getDefinition('baz'); - $this->fail('->getDefinition() throws a ServiceNotFoundException if the service definition does not exist'); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException $e) { - $this->assertEquals('You have requested a non-existent service "baz".', $e->getMessage(), '->getDefinition() throws a ServiceNotFoundException if the service definition does not exist'); - } - } - /** - * @group legacy - * @expectedDeprecation The "deprecated_foo" service is deprecated. You should stop using it, as it will soon be removed. - */ - public function testCreateDeprecatedService() - { - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $definition->setDeprecated(\true); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setDefinition('deprecated_foo', $definition); - $builder->get('deprecated_foo'); - } - public function testRegister() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); - $this->assertTrue($builder->hasDefinition('foo'), '->register() registers a new service definition'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $builder->getDefinition('foo'), '->register() returns the newly created Definition instance'); - } - public function testAutowire() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->autowire('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); - $this->assertTrue($builder->hasDefinition('foo'), '->autowire() registers a new service definition'); - $this->assertTrue($builder->getDefinition('foo')->isAutowired(), '->autowire() creates autowired definitions'); - } - public function testHas() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $this->assertFalse($builder->has('foo'), '->has() returns false if the service does not exist'); - $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); - $this->assertTrue($builder->has('foo'), '->has() returns true if a service definition exists'); - $builder->set('bar', new \stdClass()); - $this->assertTrue($builder->has('bar'), '->has() returns true if a service exists'); - } - public function testGetThrowsExceptionIfServiceDoesNotExist() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); - $this->expectExceptionMessage('You have requested a non-existent service "foo".'); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->get('foo'); - } - public function testGetReturnsNullIfServiceDoesNotExistAndInvalidReferenceIsUsed() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $this->assertNull($builder->get('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE), '->get() returns null if the service does not exist and NULL_ON_INVALID_REFERENCE is passed as a second argument'); - } - public function testGetThrowsCircularReferenceExceptionIfServiceHasReferenceToItself() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('baz', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')]); - $builder->get('baz'); - } - public function testGetReturnsSameInstanceWhenServiceIsShared() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('bar', 'stdClass'); - $this->assertTrue($builder->get('bar') === $builder->get('bar'), '->get() always returns the same instance if the service is shared'); - } - public function testGetCreatesServiceBasedOnDefinition() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo', 'stdClass'); - $this->assertIsObject($builder->get('foo'), '->get() returns the service definition associated with the id'); - } - public function testGetReturnsRegisteredService() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->set('bar', $bar = new \stdClass()); - $this->assertSame($bar, $builder->get('bar'), '->get() returns the service associated with the id'); - } - public function testRegisterDoesNotOverrideExistingService() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->set('bar', $bar = new \stdClass()); - $builder->register('bar', 'stdClass'); - $this->assertSame($bar, $builder->get('bar'), '->get() returns the service associated with the id even if a definition has been defined'); - } - public function testNonSharedServicesReturnsDifferentInstances() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('bar', 'stdClass')->setShared(\false); - $this->assertNotSame($builder->get('bar'), $builder->get('bar')); - } - /** - * @dataProvider provideBadId - */ - public function testBadAliasId($id) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setAlias($id, 'foo'); - } - /** - * @dataProvider provideBadId - */ - public function testBadDefinitionId($id) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setDefinition($id, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Foo')); - } - public function provideBadId() - { - return [[''], ["\0"], ["\r"], ["\n"], ["'"], ['ab\\']]; - } - public function testGetUnsetLoadingServiceWhenCreateServiceThrowsAnException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('You have requested a synthetic service ("foo"). The DIC does not know how to construct this service.'); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo', 'stdClass')->setSynthetic(\true); - // we expect a RuntimeException here as foo is synthetic - try { - $builder->get('foo'); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { - } - // we must also have the same RuntimeException here - $builder->get('foo'); - } - public function testGetServiceIds() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo', 'stdClass'); - $builder->bar = $bar = new \stdClass(); - $builder->register('bar', 'stdClass'); - $this->assertEquals(['service_container', 'foo', 'bar', '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface'], $builder->getServiceIds(), '->getServiceIds() returns all defined service ids'); - } - public function testAliases() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo', 'stdClass'); - $builder->setAlias('bar', 'foo'); - $this->assertTrue($builder->hasAlias('bar'), '->hasAlias() returns true if the alias exists'); - $this->assertFalse($builder->hasAlias('foobar'), '->hasAlias() returns false if the alias does not exist'); - $this->assertEquals('foo', (string) $builder->getAlias('bar'), '->getAlias() returns the aliased service'); - $this->assertTrue($builder->has('bar'), '->setAlias() defines a new service'); - $this->assertSame($builder->get('bar'), $builder->get('foo'), '->setAlias() creates a service that is an alias to another one'); - try { - $builder->setAlias('foobar', 'foobar'); - $this->fail('->setAlias() throws an InvalidArgumentException if the alias references itself'); - } catch (\InvalidArgumentException $e) { - $this->assertEquals('An alias can not reference itself, got a circular reference on "foobar".', $e->getMessage(), '->setAlias() throws an InvalidArgumentException if the alias references itself'); - } - try { - $builder->getAlias('foobar'); - $this->fail('->getAlias() throws an InvalidArgumentException if the alias does not exist'); - } catch (\InvalidArgumentException $e) { - $this->assertEquals('The service alias "foobar" does not exist.', $e->getMessage(), '->getAlias() throws an InvalidArgumentException if the alias does not exist'); - } - } - public function testGetAliases() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setAlias('bar', 'foo'); - $builder->setAlias('foobar', 'foo'); - $builder->setAlias('moo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('foo', \false)); - $aliases = $builder->getAliases(); - $this->assertEquals('foo', (string) $aliases['bar']); - $this->assertTrue($aliases['bar']->isPublic()); - $this->assertEquals('foo', (string) $aliases['foobar']); - $this->assertEquals('foo', (string) $aliases['moo']); - $this->assertFalse($aliases['moo']->isPublic()); - $builder->register('bar', 'stdClass'); - $this->assertFalse($builder->hasAlias('bar')); - $builder->set('foobar', 'stdClass'); - $builder->set('moo', 'stdClass'); - $this->assertCount(2, $builder->getAliases(), '->getAliases() does not return aliased services that have been overridden'); - } - public function testSetAliases() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setAliases(['bar' => 'foo', 'foobar' => 'foo']); - $aliases = $builder->getAliases(); - $this->assertArrayHasKey('bar', $aliases); - $this->assertArrayHasKey('foobar', $aliases); - } - public function testAddAliases() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setAliases(['bar' => 'foo']); - $builder->addAliases(['foobar' => 'foo']); - $aliases = $builder->getAliases(); - $this->assertArrayHasKey('bar', $aliases); - $this->assertArrayHasKey('foobar', $aliases); - } - public function testSetReplacesAlias() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setAlias('alias', 'aliased'); - $builder->set('aliased', new \stdClass()); - $builder->set('alias', $foo = new \stdClass()); - $this->assertSame($foo, $builder->get('alias'), '->set() replaces an existing alias'); - } - public function testAliasesKeepInvalidBehavior() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $aliased = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $aliased->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)]); - $builder->setDefinition('aliased', $aliased); - $builder->setAlias('alias', 'aliased'); - $this->assertEquals(new \stdClass(), $builder->get('alias')); - } - public function testAddGetCompilerPass() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setResourceTracking(\false); - $defaultPasses = $builder->getCompiler()->getPassConfig()->getPasses(); - $builder->addCompilerPass($pass1 = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CompilerPassInterface')->getMock(), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, -5); - $builder->addCompilerPass($pass2 = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CompilerPassInterface')->getMock(), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, 10); - $passes = $builder->getCompiler()->getPassConfig()->getPasses(); - $this->assertCount(\count($passes) - 2, $defaultPasses); - // Pass 1 is executed later - $this->assertTrue(\array_search($pass1, $passes, \true) > \array_search($pass2, $passes, \true)); - } - public function testCreateService() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFile(__DIR__ . '/Fixtures/includes/foo.php'); - $builder->register('foo2', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFile(__DIR__ . '/Fixtures/includes/%file%.php'); - $builder->setParameter('file', 'foo'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Bar\\FooClass', $builder->get('foo1'), '->createService() requires the file defined by the service definition'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Bar\\FooClass', $builder->get('foo2'), '->createService() replaces parameters in the file provided by the service definition'); - } - public function testCreateProxyWithRealServiceInstantiator() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFile(__DIR__ . '/Fixtures/includes/foo.php'); - $builder->getDefinition('foo1')->setLazy(\true); - $foo1 = $builder->get('foo1'); - $this->assertSame($foo1, $builder->get('foo1'), 'The same proxy is retrieved on multiple subsequent calls'); - $this->assertSame('_PhpScoper5ea00cc67502b\\Bar\\FooClass', \get_class($foo1)); - } - public function testCreateServiceClass() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo1', '%class%'); - $builder->setParameter('class', 'stdClass'); - $this->assertInstanceOf('\\stdClass', $builder->get('foo1'), '->createService() replaces parameters in the class provided by the service definition'); - } - public function testCreateServiceArguments() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('bar', 'stdClass'); - $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addArgument(['foo' => '%value%', '%value%' => 'foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), '%%unescape_it%%']); - $builder->setParameter('value', 'bar'); - $this->assertEquals(['foo' => 'bar', 'bar' => 'foo', $builder->get('bar'), '%unescape_it%'], $builder->get('foo1')->arguments, '->createService() replaces parameters and service references in the arguments provided by the service definition'); - } - public function testCreateServiceFactory() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFactory('Bar\\FooClass::getInstance'); - $builder->register('qux', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFactory(['_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'getInstance']); - $builder->register('bar', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\Bar\\FooClass'), 'getInstance']); - $builder->register('baz', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), 'getInstance']); - $this->assertTrue($builder->get('foo')->called, '->createService() calls the factory method to create the service instance'); - $this->assertTrue($builder->get('qux')->called, '->createService() calls the factory method to create the service instance'); - $this->assertTrue($builder->get('bar')->called, '->createService() uses anonymous service as factory'); - $this->assertTrue($builder->get('baz')->called, '->createService() uses another service as factory'); - } - public function testCreateServiceMethodCalls() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('bar', 'stdClass'); - $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addMethodCall('setBar', [['%value%', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]]); - $builder->setParameter('value', 'bar'); - $this->assertEquals(['bar', $builder->get('bar')], $builder->get('foo1')->bar, '->createService() replaces the values in the method calls arguments'); - } - public function testCreateServiceMethodCallsWithEscapedParam() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('bar', 'stdClass'); - $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addMethodCall('setBar', [['%%unescape_it%%']]); - $builder->setParameter('value', 'bar'); - $this->assertEquals(['%unescape_it%'], $builder->get('foo1')->bar, '->createService() replaces the values in the method calls arguments'); - } - public function testCreateServiceProperties() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('bar', 'stdClass'); - $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setProperty('bar', ['%value%', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), '%%unescape_it%%']); - $builder->setParameter('value', 'bar'); - $this->assertEquals(['bar', $builder->get('bar'), '%unescape_it%'], $builder->get('foo1')->bar, '->createService() replaces the values in the properties'); - } - public function testCreateServiceConfigurator() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setConfigurator('sc_configure'); - $builder->register('foo2', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setConfigurator(['%class%', 'configureStatic']); - $builder->setParameter('class', 'BazClass'); - $builder->register('baz', 'BazClass'); - $builder->register('foo3', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setConfigurator([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'configure']); - $builder->register('foo4', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setConfigurator([$builder->getDefinition('baz'), 'configure']); - $builder->register('foo5', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setConfigurator('foo'); - $this->assertTrue($builder->get('foo1')->configured, '->createService() calls the configurator'); - $this->assertTrue($builder->get('foo2')->configured, '->createService() calls the configurator'); - $this->assertTrue($builder->get('foo3')->configured, '->createService() calls the configurator'); - $this->assertTrue($builder->get('foo4')->configured, '->createService() calls the configurator'); - try { - $builder->get('foo5'); - $this->fail('->createService() throws an InvalidArgumentException if the configure callable is not a valid callable'); - } catch (\InvalidArgumentException $e) { - $this->assertEquals('The configure callable for class "Bar\\FooClass" is not a callable.', $e->getMessage(), '->createService() throws an InvalidArgumentException if the configure callable is not a valid callable'); - } - } - public function testCreateServiceWithIteratorArgument() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('bar', 'stdClass'); - $builder->register('lazy_context', 'LazyContext')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['k1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('invalid', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])]); - $lazyContext = $builder->get('lazy_context'); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator::class, $lazyContext->lazyValues); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator::class, $lazyContext->lazyEmptyValues); - $this->assertCount(1, $lazyContext->lazyValues); - $this->assertCount(0, $lazyContext->lazyEmptyValues); - $i = 0; - foreach ($lazyContext->lazyValues as $k => $v) { - ++$i; - $this->assertEquals('k1', $k); - $this->assertInstanceOf('\\stdClass', $v); - } - // The second argument should have been ignored. - $this->assertEquals(1, $i); - $i = 0; - foreach ($lazyContext->lazyEmptyValues as $k => $v) { - ++$i; - } - $this->assertEquals(0, $i); - } - public function testCreateSyntheticService() - { - $this->expectException('RuntimeException'); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setSynthetic(\true); - $builder->get('foo'); - } - public function testCreateServiceWithExpression() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setParameter('bar', 'bar'); - $builder->register('bar', 'BarClass'); - $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addArgument(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("bar").foo ~ parameter("bar")')]); - $this->assertEquals('foobar', $builder->get('foo')->arguments['foo']); - } - public function testResolveServices() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); - $this->assertEquals($builder->get('foo'), $builder->resolveServices(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')), '->resolveServices() resolves service references to service instances'); - $this->assertEquals(['foo' => ['foo', $builder->get('foo')]], $builder->resolveServices(['foo' => ['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]]), '->resolveServices() resolves service references to service instances in nested arrays'); - $this->assertEquals($builder->get('foo'), $builder->resolveServices(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("foo")')), '->resolveServices() resolves expressions'); - } - public function testResolveServicesWithDecoratedDefinition() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Constructing service "foo" from a parent definition is not supported at build time.'); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setDefinition('grandpa', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass')); - $builder->setDefinition('parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('grandpa')); - $builder->setDefinition('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); - $builder->get('foo'); - } - public function testResolveServicesWithCustomDefinitionClass() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setDefinition('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition('stdClass')); - $this->assertInstanceOf('stdClass', $builder->get('foo')); - } - public function testMerge() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['bar' => 'foo'])); - $container->setResourceTracking(\false); - $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); - $container->merge($config); - $this->assertEquals(['bar' => 'foo', 'foo' => 'bar'], $container->getParameterBag()->all(), '->merge() merges current parameters with the loaded ones'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['bar' => 'foo'])); - $container->setResourceTracking(\false); - $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => '%bar%'])); - $container->merge($config); - $container->compile(); - $this->assertEquals(['bar' => 'foo', 'foo' => 'foo'], $container->getParameterBag()->all(), '->merge() evaluates the values of the parameters towards already defined ones'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['bar' => 'foo'])); - $container->setResourceTracking(\false); - $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => '%bar%', 'baz' => '%foo%'])); - $container->merge($config); - $container->compile(); - $this->assertEquals(['bar' => 'foo', 'foo' => 'foo', 'baz' => 'foo'], $container->getParameterBag()->all(), '->merge() evaluates the values of the parameters towards already defined ones'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); - $container->register('bar', 'BarClass'); - $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $config->setDefinition('baz', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BazClass')); - $config->setAlias('alias_for_foo', 'foo'); - $container->merge($config); - $this->assertEquals(['service_container', 'foo', 'bar', 'baz'], \array_keys($container->getDefinitions()), '->merge() merges definitions already defined ones'); - $aliases = $container->getAliases(); - $this->assertArrayHasKey('alias_for_foo', $aliases); - $this->assertEquals('foo', (string) $aliases['alias_for_foo']); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); - $config->setDefinition('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BazClass')); - $container->merge($config); - $this->assertEquals('BazClass', $container->getDefinition('foo')->getClass(), '->merge() overrides already defined services'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - $bag->get('env(Foo)'); - $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder($bag); - $this->assertSame(['%env(Bar)%'], $config->resolveEnvPlaceholders([$bag->get('env(Bar)')])); - $container->merge($config); - $this->assertEquals(['Foo' => 0, 'Bar' => 1], $container->getEnvCounters()); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $childDefA = $container->registerForAutoconfiguration('AInterface'); - $childDefB = $config->registerForAutoconfiguration('BInterface'); - $container->merge($config); - $this->assertSame(['AInterface' => $childDefA, 'BInterface' => $childDefB], $container->getAutoconfiguredInstanceof()); - } - public function testMergeThrowsExceptionForDuplicateAutomaticInstanceofDefinitions() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('"AInterface" has already been autoconfigured and merge() does not support merging autoconfiguration for the same class/interface.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerForAutoconfiguration('AInterface'); - $config->registerForAutoconfiguration('AInterface'); - $container->merge($config); - } - public function testResolveEnvValues() - { - $_ENV['DUMMY_ENV_VAR'] = 'du%%y'; - $_SERVER['DUMMY_SERVER_VAR'] = 'ABC'; - $_SERVER['HTTP_DUMMY_VAR'] = 'DEF'; - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('bar', '%% %env(DUMMY_ENV_VAR)% %env(DUMMY_SERVER_VAR)% %env(HTTP_DUMMY_VAR)%'); - $container->setParameter('env(HTTP_DUMMY_VAR)', '123'); - $this->assertSame('%% du%%%%y ABC 123', $container->resolveEnvPlaceholders('%bar%', \true)); - unset($_ENV['DUMMY_ENV_VAR'], $_SERVER['DUMMY_SERVER_VAR'], $_SERVER['HTTP_DUMMY_VAR']); - } - public function testResolveEnvValuesWithArray() - { - $_ENV['ANOTHER_DUMMY_ENV_VAR'] = 'dummy'; - $dummyArray = ['1' => 'one', '2' => 'two']; - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('dummy', '%env(ANOTHER_DUMMY_ENV_VAR)%'); - $container->setParameter('dummy2', $dummyArray); - $container->resolveEnvPlaceholders('%dummy%', \true); - $container->resolveEnvPlaceholders('%dummy2%', \true); - $this->assertIsArray($container->resolveEnvPlaceholders('%dummy2%', \true)); - foreach ($dummyArray as $key => $value) { - $this->assertArrayHasKey($key, $container->resolveEnvPlaceholders('%dummy2%', \true)); - } - unset($_ENV['ANOTHER_DUMMY_ENV_VAR']); - } - public function testCompileWithResolveEnv() - { - \putenv('DUMMY_ENV_VAR=du%%y'); - $_SERVER['DUMMY_SERVER_VAR'] = 'ABC'; - $_SERVER['HTTP_DUMMY_VAR'] = 'DEF'; - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('env(FOO)', 'Foo'); - $container->setParameter('env(DUMMY_ENV_VAR)', 'GHI'); - $container->setParameter('bar', '%% %env(DUMMY_ENV_VAR)% %env(DUMMY_SERVER_VAR)% %env(HTTP_DUMMY_VAR)%'); - $container->setParameter('foo', '%env(FOO)%'); - $container->setParameter('baz', '%foo%'); - $container->setParameter('env(HTTP_DUMMY_VAR)', '123'); - $container->register('teatime', 'stdClass')->setProperty('foo', '%env(DUMMY_ENV_VAR)%')->setPublic(\true); - $container->compile(\true); - $this->assertSame('% du%%y ABC 123', $container->getParameter('bar')); - $this->assertSame('Foo', $container->getParameter('baz')); - $this->assertSame('du%%y', $container->get('teatime')->foo); - unset($_SERVER['DUMMY_SERVER_VAR'], $_SERVER['HTTP_DUMMY_VAR']); - \putenv('DUMMY_ENV_VAR'); - } - public function testCompileWithArrayResolveEnv() - { - \putenv('ARRAY={"foo":"bar"}'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('foo', '%env(json:ARRAY)%'); - $container->compile(\true); - $this->assertSame(['foo' => 'bar'], $container->getParameter('foo')); - \putenv('ARRAY'); - } - public function testCompileWithArrayAndAnotherResolveEnv() - { - \putenv('DUMMY_ENV_VAR=abc'); - \putenv('ARRAY={"foo":"bar"}'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('foo', '%env(json:ARRAY)%'); - $container->setParameter('bar', '%env(DUMMY_ENV_VAR)%'); - $container->compile(\true); - $this->assertSame(['foo' => 'bar'], $container->getParameter('foo')); - $this->assertSame('abc', $container->getParameter('bar')); - \putenv('DUMMY_ENV_VAR'); - \putenv('ARRAY'); - } - public function testCompileWithArrayInStringResolveEnv() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('A string value must be composed of strings and/or numbers, but found parameter "env(json:ARRAY)" of type "array" inside string value "ABC %env(json:ARRAY)%".'); - \putenv('ARRAY={"foo":"bar"}'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('foo', 'ABC %env(json:ARRAY)%'); - $container->compile(\true); - \putenv('ARRAY'); - } - public function testCompileWithResolveMissingEnv() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvNotFoundException'); - $this->expectExceptionMessage('Environment variable not found: "FOO".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('foo', '%env(FOO)%'); - $container->compile(\true); - } - public function testDynamicEnv() - { - \putenv('DUMMY_FOO=some%foo%'); - \putenv('DUMMY_BAR=%bar%'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('foo', 'Foo%env(resolve:DUMMY_BAR)%'); - $container->setParameter('bar', 'Bar'); - $container->setParameter('baz', '%env(resolve:DUMMY_FOO)%'); - $container->compile(\true); - \putenv('DUMMY_FOO'); - \putenv('DUMMY_BAR'); - $this->assertSame('someFooBar', $container->getParameter('baz')); - } - public function testCastEnv() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('env(FAKE)', '123'); - $container->register('foo', 'stdClass')->setPublic(\true)->setProperties(['fake' => '%env(int:FAKE)%']); - $container->compile(\true); - $this->assertSame(123, $container->get('foo')->fake); - } - public function testEnvAreNullable() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('env(FAKE)', null); - $container->register('foo', 'stdClass')->setPublic(\true)->setProperties(['fake' => '%env(int:FAKE)%']); - $container->compile(\true); - $this->assertNull($container->get('foo')->fake); - } - public function testEnvInId() - { - $container = (include __DIR__ . '/Fixtures/containers/container_env_in_id.php'); - $container->compile(\true); - $expected = ['service_container', 'foo', 'bar', 'bar_%env(BAR)%']; - $this->assertSame($expected, \array_keys($container->getDefinitions())); - $expected = [\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class => \true, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class => \true, 'baz_%env(BAR)%' => \true, 'bar_%env(BAR)%' => \true]; - $this->assertSame($expected, $container->getRemovedIds()); - $this->assertSame(['baz_bar'], \array_keys($container->getDefinition('foo')->getArgument(1))); - } - public function testCircularDynamicEnv() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterCircularReferenceException'); - $this->expectExceptionMessage('Circular reference detected for parameter "env(resolve:DUMMY_ENV_VAR)" ("env(resolve:DUMMY_ENV_VAR)" > "env(resolve:DUMMY_ENV_VAR)").'); - \putenv('DUMMY_ENV_VAR=some%foo%'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('foo', '%bar%'); - $container->setParameter('bar', '%env(resolve:DUMMY_ENV_VAR)%'); - try { - $container->compile(\true); - } finally { - \putenv('DUMMY_ENV_VAR'); - } - } - public function testMergeLogicException() - { - $this->expectException('LogicException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->compile(); - $container->merge(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); - } - public function testfindTaggedServiceIds() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addTag('foo', ['foo' => 'foo'])->addTag('bar', ['bar' => 'bar'])->addTag('foo', ['foofoo' => 'foofoo']); - $this->assertEquals($builder->findTaggedServiceIds('foo'), ['foo' => [['foo' => 'foo'], ['foofoo' => 'foofoo']]], '->findTaggedServiceIds() returns an array of service ids and its tag attributes'); - $this->assertEquals([], $builder->findTaggedServiceIds('foobar'), '->findTaggedServiceIds() returns an empty array if there is annotated services'); - } - public function testFindUnusedTags() - { - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addTag('kernel.event_listener', ['foo' => 'foo'])->addTag('kenrel.event_listener', ['bar' => 'bar']); - $builder->findTaggedServiceIds('kernel.event_listener'); - $this->assertEquals(['kenrel.event_listener'], $builder->findUnusedTags(), '->findUnusedTags() returns an array with unused tags'); - } - public function testFindDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setDefinition('foo', $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\Bar\\FooClass')); - $container->setAlias('bar', 'foo'); - $container->setAlias('foobar', 'bar'); - $this->assertEquals($definition, $container->findDefinition('foobar'), '->findDefinition() returns a Definition'); - } - public function testAddObjectResource() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->addObjectResource(new \_PhpScoper5ea00cc67502b\BarClass()); - $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); - $container->setResourceTracking(\true); - $container->addObjectResource(new \_PhpScoper5ea00cc67502b\BarClass()); - $resources = $container->getResources(); - $this->assertCount(2, $resources, '2 resources were registered'); - /* @var $resource \Symfony\Component\Config\Resource\FileResource */ - $resource = \end($resources); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileResource', $resource); - $this->assertSame(\realpath(__DIR__ . '/Fixtures/includes/classes.php'), \realpath($resource->getResource())); - } - /** - * @group legacy - */ - public function testAddClassResource() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->addClassResource(new \ReflectionClass('BarClass')); - $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); - $container->setResourceTracking(\true); - $container->addClassResource(new \ReflectionClass('BarClass')); - $resources = $container->getResources(); - $this->assertCount(2, $resources, '2 resources were registered'); - /* @var $resource \Symfony\Component\Config\Resource\FileResource */ - $resource = \end($resources); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileResource', $resource); - $this->assertSame(\realpath(__DIR__ . '/Fixtures/includes/classes.php'), \realpath($resource->getResource())); - } - public function testGetReflectionClass() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $r1 = $container->getReflectionClass('BarClass'); - $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); - $container->setResourceTracking(\true); - $r2 = $container->getReflectionClass('BarClass'); - $r3 = $container->getReflectionClass('BarClass'); - $this->assertNull($container->getReflectionClass('BarMissingClass')); - $this->assertEquals($r1, $r2); - $this->assertSame($r2, $r3); - $resources = $container->getResources(); - $this->assertCount(3, $resources, '3 resources were registered'); - $this->assertSame('reflection.BarClass', (string) $resources[1]); - $this->assertSame('BarMissingClass', (string) \end($resources)); - } - public function testGetReflectionClassOnInternalTypes() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $this->assertNull($container->getReflectionClass('int')); - $this->assertNull($container->getReflectionClass('float')); - $this->assertNull($container->getReflectionClass('string')); - $this->assertNull($container->getReflectionClass('bool')); - $this->assertNull($container->getReflectionClass('resource')); - $this->assertNull($container->getReflectionClass('object')); - $this->assertNull($container->getReflectionClass('array')); - $this->assertNull($container->getReflectionClass('null')); - $this->assertNull($container->getReflectionClass('callable')); - $this->assertNull($container->getReflectionClass('iterable')); - $this->assertNull($container->getReflectionClass('mixed')); - } - public function testCompilesClassDefinitionsOfLazyServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); - $container->register('foo', 'BarClass')->setPublic(\true); - $container->getDefinition('foo')->setLazy(\true); - $container->compile(); - $matchingResources = \array_filter($container->getResources(), function (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $resource) { - return 'reflection.BarClass' === (string) $resource; - }); - $this->assertNotEmpty($matchingResources); - } - public function testResources() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->addResource($a = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__DIR__ . '/Fixtures/xml/services1.xml')); - $container->addResource($b = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__DIR__ . '/Fixtures/xml/services2.xml')); - $resources = []; - foreach ($container->getResources() as $resource) { - if (\false === \strpos($resource, '.php')) { - $resources[] = $resource; - } - } - $this->assertEquals([$a, $b], $resources, '->getResources() returns an array of resources read for the current configuration'); - $this->assertSame($container, $container->setResources([])); - $this->assertEquals([], $container->getResources()); - } - public function testFileExists() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $A = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource(); - $a = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__DIR__ . '/Fixtures/xml/services1.xml'); - $b = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__DIR__ . '/Fixtures/xml/services2.xml'); - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($dir = \dirname($b)); - $this->assertTrue($container->fileExists((string) $a) && $container->fileExists((string) $b) && $container->fileExists($dir)); - $resources = []; - foreach ($container->getResources() as $resource) { - if (\false === \strpos($resource, '.php')) { - $resources[] = $resource; - } - } - $this->assertEquals([$A, $a, $b, $c], $resources, '->getResources() returns an array of resources read for the current configuration'); - } - public function testExtension() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->registerExtension($extension = new \_PhpScoper5ea00cc67502b\ProjectExtension()); - $this->assertSame($container->getExtension('project'), $extension, '->registerExtension() registers an extension'); - $this->expectException('LogicException'); - $container->getExtension('no_registered'); - } - public function testRegisteredButNotLoadedExtension() - { - $extension = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface')->getMock(); - $extension->expects($this->once())->method('getAlias')->willReturn('project'); - $extension->expects($this->never())->method('load'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->registerExtension($extension); - $container->compile(); - } - public function testRegisteredAndLoadedExtension() - { - $extension = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface')->getMock(); - $extension->expects($this->exactly(2))->method('getAlias')->willReturn('project'); - $extension->expects($this->once())->method('load')->with([['foo' => 'bar']]); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->registerExtension($extension); - $container->loadFromExtension('project', ['foo' => 'bar']); - $container->compile(); - } - public function testPrivateServiceUser() - { - $fooDefinition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BarClass'); - $fooUserDefinition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BarUserClass', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $fooDefinition->setPublic(\false); - $container->addDefinitions(['bar' => $fooDefinition, 'bar_user' => $fooUserDefinition->setPublic(\true)]); - $container->compile(); - $this->assertInstanceOf('BarClass', $container->get('bar_user')->bar); - } - public function testThrowsExceptionWhenSetServiceOnACompiledContainer() - { - $this->expectException('BadMethodCallException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->register('a', 'stdClass')->setPublic(\true); - $container->compile(); - $container->set('a', new \stdClass()); - } - public function testNoExceptionWhenAddServiceOnACompiledContainer() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->compile(); - $container->set('a', $foo = new \stdClass()); - $this->assertSame($foo, $container->get('a')); - } - public function testNoExceptionWhenSetSyntheticServiceOnACompiledContainer() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $def->setSynthetic(\true)->setPublic(\true); - $container->setDefinition('a', $def); - $container->compile(); - $container->set('a', $a = new \stdClass()); - $this->assertEquals($a, $container->get('a')); - } - public function testThrowsExceptionWhenSetDefinitionOnACompiledContainer() - { - $this->expectException('BadMethodCallException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->compile(); - $container->setDefinition('a', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition()); - } - public function testExtensionConfig() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $configs = $container->getExtensionConfig('foo'); - $this->assertEmpty($configs); - $first = ['foo' => 'bar']; - $container->prependExtensionConfig('foo', $first); - $configs = $container->getExtensionConfig('foo'); - $this->assertEquals([$first], $configs); - $second = ['ding' => 'dong']; - $container->prependExtensionConfig('foo', $second); - $configs = $container->getExtensionConfig('foo'); - $this->assertEquals([$second, $first], $configs); - } - public function testAbstractAlias() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $abstract = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('AbstractClass'); - $abstract->setAbstract(\true)->setPublic(\true); - $container->setDefinition('abstract_service', $abstract); - $container->setAlias('abstract_alias', 'abstract_service')->setPublic(\true); - $container->compile(); - $this->assertSame('abstract_service', (string) $container->getAlias('abstract_alias')); - } - public function testLazyLoadedService() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); - $loader->load(function (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) { - $container->set('a', new \_PhpScoper5ea00cc67502b\BazClass()); - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BazClass'); - $definition->setLazy(\true); - $definition->setPublic(\true); - $container->setDefinition('a', $definition); - }); - $container->setResourceTracking(\true); - $container->compile(); - $r = new \ReflectionProperty($container, 'resources'); - $r->setAccessible(\true); - $resources = $r->getValue($container); - $classInList = \false; - foreach ($resources as $resource) { - if ('reflection.BazClass' === (string) $resource) { - $classInList = \true; - break; - } - } - $this->assertTrue($classInList); - } - public function testInlinedDefinitions() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BarClass'); - $container->register('bar_user', 'BarUserClass')->addArgument($definition)->setProperty('foo', $definition); - $container->register('bar', 'BarClass')->setProperty('foo', $definition)->addMethodCall('setBaz', [$definition]); - $barUser = $container->get('bar_user'); - $bar = $container->get('bar'); - $this->assertSame($barUser->foo, $barUser->bar); - $this->assertSame($bar->foo, $bar->getBaz()); - $this->assertNotSame($bar->foo, $barUser->foo); - } - public function testThrowsCircularExceptionForCircularAliases() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $this->expectExceptionMessage('Circular reference detected for service "app.test_class", path: "app.test_class -> App\\TestClass -> app.test_class".'); - $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $builder->setAliases(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('app.test_class'), 'app.test_class' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('_PhpScoper5ea00cc67502b\\App\\TestClass'), '_PhpScoper5ea00cc67502b\\App\\TestClass' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('app.test_class')]); - $builder->findDefinition('foo'); - } - public function testInitializePropertiesBeforeMethodCalls() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass'); - $container->register('bar', 'MethodCallClass')->setPublic(\true)->setProperty('simple', 'bar')->setProperty('complex', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))->addMethodCall('callMe'); - $container->compile(); - $this->assertTrue($container->get('bar')->callPassed(), '->compile() initializes properties before method calls'); - } - public function testAutowiring() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\A::class)->setPublic(\true); - $bDefinition = $container->register('b', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\B::class); - $bDefinition->setAutowired(\true); - $bDefinition->setPublic(\true); - $container->compile(); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\A::class, (string) $container->getDefinition('b')->getArgument(0)); - } - public function testClassFromId() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $unknown = $container->register('_PhpScoper5ea00cc67502b\\Acme\\UnknownClass'); - $autoloadClass = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class); - $container->compile(); - $this->assertSame('_PhpScoper5ea00cc67502b\\Acme\\UnknownClass', $unknown->getClass()); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class, $autoloadClass->getClass()); - } - public function testNoClassFromGlobalNamespaceClassId() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('The definition for "DateTime" has no class attribute, and appears to reference a class or interface in the global namespace.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register(\DateTime::class); - $container->compile(); - } - public function testNoClassFromGlobalNamespaceClassIdWithLeadingSlash() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('The definition for "\\DateTime" has no class attribute, and appears to reference a class or interface in the global namespace.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('\\' . \DateTime::class); - $container->compile(); - } - public function testNoClassFromNamespaceClassIdWithLeadingSlash() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('The definition for "\\Symfony\\Component\\DependencyInjection\\Tests\\FooClass" has no class attribute, and appears to reference a class or interface. Please specify the class attribute explicitly or remove the leading backslash by renaming the service to "Symfony\\Component\\DependencyInjection\\Tests\\FooClass" to get rid of this error.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('\\' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\FooClass::class); - $container->compile(); - } - public function testNoClassFromNonClassId() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('The definition for "123_abc" has no class.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('123_abc'); - $container->compile(); - } - public function testNoClassFromNsSeparatorId() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('The definition for "\\foo" has no class.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('\\foo'); - $container->compile(); - } - public function testServiceLocator() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\true)->addArgument(['bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar_service')), 'baz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference('baz_service', 'stdClass'))]); - $container->register('bar_service', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz_service')])->setPublic(\true); - $container->register('baz_service', 'stdClass')->setPublic(\false); - $container->compile(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class, $foo = $container->get('foo_service')); - $this->assertSame($container->get('bar_service'), $foo->get('bar')); - } - public function testUninitializedReference() - { - $container = (include __DIR__ . '/Fixtures/containers/container_uninitialized_ref.php'); - $container->compile(); - $bar = $container->get('bar'); - $this->assertNull($bar->foo1); - $this->assertNull($bar->foo2); - $this->assertNull($bar->foo3); - $this->assertNull($bar->closures[0]()); - $this->assertNull($bar->closures[1]()); - $this->assertNull($bar->closures[2]()); - $this->assertSame([], \iterator_to_array($bar->iter)); - $container = (include __DIR__ . '/Fixtures/containers/container_uninitialized_ref.php'); - $container->compile(); - $container->get('foo1'); - $container->get('baz'); - $bar = $container->get('bar'); - $this->assertEquals(new \stdClass(), $bar->foo1); - $this->assertNull($bar->foo2); - $this->assertEquals(new \stdClass(), $bar->foo3); - $this->assertEquals(new \stdClass(), $bar->closures[0]()); - $this->assertNull($bar->closures[1]()); - $this->assertEquals(new \stdClass(), $bar->closures[2]()); - $this->assertEquals(['foo1' => new \stdClass(), 'foo3' => new \stdClass()], \iterator_to_array($bar->iter)); - } - /** - * @dataProvider provideAlmostCircular - */ - public function testAlmostCircular($visibility) - { - $container = (include __DIR__ . '/Fixtures/containers/container_almost_circular.php'); - $foo = $container->get('foo'); - $this->assertSame($foo, $foo->bar->foobar->foo); - $foo2 = $container->get('foo2'); - $this->assertSame($foo2, $foo2->bar->foobar->foo); - $this->assertSame([], (array) $container->get('foobar4')); - $foo5 = $container->get('foo5'); - $this->assertSame($foo5, $foo5->bar->foo); - $manager = $container->get('manager'); - $this->assertEquals(new \stdClass(), $manager); - $manager = $container->get('manager2'); - $this->assertEquals(new \stdClass(), $manager); - $foo6 = $container->get('foo6'); - $this->assertEquals((object) ['bar6' => (object) []], $foo6); - $this->assertInstanceOf(\stdClass::class, $container->get('root')); - $manager3 = $container->get('manager3'); - $listener3 = $container->get('listener3'); - $this->assertSame($manager3, $listener3->manager, 'Both should identically be the manager3 service'); - $listener4 = $container->get('listener4'); - $this->assertInstanceOf('stdClass', $listener4); - } - public function provideAlmostCircular() - { - (yield ['public']); - (yield ['private']); - } - public function testRegisterForAutoconfiguration() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $childDefA = $container->registerForAutoconfiguration('AInterface'); - $childDefB = $container->registerForAutoconfiguration('BInterface'); - $this->assertSame(['AInterface' => $childDefA, 'BInterface' => $childDefB], $container->getAutoconfiguredInstanceof()); - // when called multiple times, the same instance is returned - $this->assertSame($childDefA, $container->registerForAutoconfiguration('AInterface')); - } - /** - * This test checks the trigger of a deprecation note and should not be removed in major releases. - * - * @group legacy - * @expectedDeprecation The "foo" service is deprecated. You should stop using it, as it will soon be removed. - */ - public function testPrivateServiceTriggersDeprecation() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setPublic(\false)->setDeprecated(\true); - $container->register('bar', 'stdClass')->setPublic(\true)->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')); - $container->compile(); - $container->get('bar'); - } - /** - * @group legacy - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "FOO" instead of "foo" is deprecated since Symfony 3.4. - */ - public function testParameterWithMixedCase() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); - $container->register('foo', 'stdClass')->setPublic(\true)->setProperty('foo', '%FOO%'); - $container->compile(); - $this->assertSame('bar', $container->get('foo')->foo); - } - public function testArgumentsHaveHigherPriorityThanBindings() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('class.via.bindings', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->setArguments(['via-bindings']); - $container->register('class.via.argument', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->setArguments(['via-argument']); - $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy::class)->setPublic(\true)->setBindings([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('class.via.bindings'), '$token' => '1234'])->setArguments(['$class1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('class.via.argument')]); - $this->assertSame(['service_container', 'class.via.bindings', 'class.via.argument', 'foo', '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface'], $container->getServiceIds()); - $container->compile(); - $this->assertSame('via-argument', $container->get('foo')->class1->identifier); - $this->assertSame('via-bindings', $container->get('foo')->class2->identifier); - } - public function testUninitializedSyntheticReference() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setPublic(\true)->setSynthetic(\true); - $container->register('bar', 'stdClass')->setPublic(\true)->setShared(\false)->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE)); - $container->compile(); - $this->assertEquals((object) ['foo' => null], $container->get('bar')); - $container->set('foo', (object) [123]); - $this->assertEquals((object) ['foo' => (object) [123]], $container->get('bar')); - } - public function testDecoratedSelfReferenceInvolvingPrivateServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setPublic(\false)->setProperty('bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')); - $container->register('baz', 'stdClass')->setPublic(\false)->setProperty('inner', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz.inner'))->setDecoratedService('foo'); - $container->compile(); - $this->assertSame(['service_container'], \array_keys($container->getDefinitions())); - } - public function testScalarService() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $c->register('foo', 'string')->setPublic(\true)->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ScalarFactory::class, 'getSomeValue']); - $c->compile(); - $this->assertTrue($c->has('foo')); - $this->assertSame('some value', $c->get('foo')); - } -} -class FooClass -{ -} -class A -{ -} -class B -{ - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\A $a) - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; + +require_once __DIR__ . '/Fixtures/includes/classes.php'; +require_once __DIR__ . '/Fixtures/includes/ProjectExtension.php'; +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ScalarFactory; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +class ContainerBuilderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testDefaultRegisteredDefinitions() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $this->assertCount(1, $builder->getDefinitions()); + $this->assertTrue($builder->hasDefinition('service_container')); + $definition = $builder->getDefinition('service_container'); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition::class, $definition); + $this->assertTrue($definition->isSynthetic()); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class, $definition->getClass()); + $this->assertTrue($builder->hasAlias(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class)); + $this->assertTrue($builder->hasAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class)); + } + public function testDefinitions() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definitions = ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\Bar\\FooClass'), 'bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BarClass')]; + $builder->setDefinitions($definitions); + $this->assertEquals($definitions, $builder->getDefinitions(), '->setDefinitions() sets the service definitions'); + $this->assertTrue($builder->hasDefinition('foo'), '->hasDefinition() returns true if a service definition exists'); + $this->assertFalse($builder->hasDefinition('foobar'), '->hasDefinition() returns false if a service definition does not exist'); + $builder->setDefinition('foobar', $foo = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooBarClass')); + $this->assertEquals($foo, $builder->getDefinition('foobar'), '->getDefinition() returns a service definition if defined'); + $this->assertSame($builder->setDefinition('foobar', $foo = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooBarClass')), $foo, '->setDefinition() implements a fluid interface by returning the service reference'); + $builder->addDefinitions($defs = ['foobar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooBarClass')]); + $this->assertEquals(\array_merge($definitions, $defs), $builder->getDefinitions(), '->addDefinitions() adds the service definitions'); + try { + $builder->getDefinition('baz'); + $this->fail('->getDefinition() throws a ServiceNotFoundException if the service definition does not exist'); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceNotFoundException $e) { + $this->assertEquals('You have requested a non-existent service "baz".', $e->getMessage(), '->getDefinition() throws a ServiceNotFoundException if the service definition does not exist'); + } + } + /** + * @group legacy + * @expectedDeprecation The "deprecated_foo" service is deprecated. You should stop using it, as it will soon be removed. + */ + public function testCreateDeprecatedService() + { + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $definition->setDeprecated(\true); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setDefinition('deprecated_foo', $definition); + $builder->get('deprecated_foo'); + } + public function testRegister() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); + $this->assertTrue($builder->hasDefinition('foo'), '->register() registers a new service definition'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $builder->getDefinition('foo'), '->register() returns the newly created Definition instance'); + } + public function testAutowire() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->autowire('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); + $this->assertTrue($builder->hasDefinition('foo'), '->autowire() registers a new service definition'); + $this->assertTrue($builder->getDefinition('foo')->isAutowired(), '->autowire() creates autowired definitions'); + } + public function testHas() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $this->assertFalse($builder->has('foo'), '->has() returns false if the service does not exist'); + $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); + $this->assertTrue($builder->has('foo'), '->has() returns true if a service definition exists'); + $builder->set('bar', new \stdClass()); + $this->assertTrue($builder->has('bar'), '->has() returns true if a service exists'); + } + public function testGetThrowsExceptionIfServiceDoesNotExist() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); + $this->expectExceptionMessage('You have requested a non-existent service "foo".'); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->get('foo'); + } + public function testGetReturnsNullIfServiceDoesNotExistAndInvalidReferenceIsUsed() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $this->assertNull($builder->get('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE), '->get() returns null if the service does not exist and NULL_ON_INVALID_REFERENCE is passed as a second argument'); + } + public function testGetThrowsCircularReferenceExceptionIfServiceHasReferenceToItself() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('baz', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')]); + $builder->get('baz'); + } + public function testGetReturnsSameInstanceWhenServiceIsShared() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('bar', 'stdClass'); + $this->assertTrue($builder->get('bar') === $builder->get('bar'), '->get() always returns the same instance if the service is shared'); + } + public function testGetCreatesServiceBasedOnDefinition() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo', 'stdClass'); + $this->assertIsObject($builder->get('foo'), '->get() returns the service definition associated with the id'); + } + public function testGetReturnsRegisteredService() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->set('bar', $bar = new \stdClass()); + $this->assertSame($bar, $builder->get('bar'), '->get() returns the service associated with the id'); + } + public function testRegisterDoesNotOverrideExistingService() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->set('bar', $bar = new \stdClass()); + $builder->register('bar', 'stdClass'); + $this->assertSame($bar, $builder->get('bar'), '->get() returns the service associated with the id even if a definition has been defined'); + } + public function testNonSharedServicesReturnsDifferentInstances() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('bar', 'stdClass')->setShared(\false); + $this->assertNotSame($builder->get('bar'), $builder->get('bar')); + } + /** + * @dataProvider provideBadId + */ + public function testBadAliasId($id) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setAlias($id, 'foo'); + } + /** + * @dataProvider provideBadId + */ + public function testBadDefinitionId($id) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setDefinition($id, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Foo')); + } + public function provideBadId() + { + return [[''], ["\0"], ["\r"], ["\n"], ["'"], ['ab\\']]; + } + public function testGetUnsetLoadingServiceWhenCreateServiceThrowsAnException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('You have requested a synthetic service ("foo"). The DIC does not know how to construct this service.'); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo', 'stdClass')->setSynthetic(\true); + // we expect a RuntimeException here as foo is synthetic + try { + $builder->get('foo'); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { + } + // we must also have the same RuntimeException here + $builder->get('foo'); + } + public function testGetServiceIds() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo', 'stdClass'); + $builder->bar = $bar = new \stdClass(); + $builder->register('bar', 'stdClass'); + $this->assertEquals(['service_container', 'foo', 'bar', '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface'], $builder->getServiceIds(), '->getServiceIds() returns all defined service ids'); + } + public function testAliases() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo', 'stdClass'); + $builder->setAlias('bar', 'foo'); + $this->assertTrue($builder->hasAlias('bar'), '->hasAlias() returns true if the alias exists'); + $this->assertFalse($builder->hasAlias('foobar'), '->hasAlias() returns false if the alias does not exist'); + $this->assertEquals('foo', (string) $builder->getAlias('bar'), '->getAlias() returns the aliased service'); + $this->assertTrue($builder->has('bar'), '->setAlias() defines a new service'); + $this->assertSame($builder->get('bar'), $builder->get('foo'), '->setAlias() creates a service that is an alias to another one'); + try { + $builder->setAlias('foobar', 'foobar'); + $this->fail('->setAlias() throws an InvalidArgumentException if the alias references itself'); + } catch (\InvalidArgumentException $e) { + $this->assertEquals('An alias can not reference itself, got a circular reference on "foobar".', $e->getMessage(), '->setAlias() throws an InvalidArgumentException if the alias references itself'); + } + try { + $builder->getAlias('foobar'); + $this->fail('->getAlias() throws an InvalidArgumentException if the alias does not exist'); + } catch (\InvalidArgumentException $e) { + $this->assertEquals('The service alias "foobar" does not exist.', $e->getMessage(), '->getAlias() throws an InvalidArgumentException if the alias does not exist'); + } + } + public function testGetAliases() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setAlias('bar', 'foo'); + $builder->setAlias('foobar', 'foo'); + $builder->setAlias('moo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('foo', \false)); + $aliases = $builder->getAliases(); + $this->assertEquals('foo', (string) $aliases['bar']); + $this->assertTrue($aliases['bar']->isPublic()); + $this->assertEquals('foo', (string) $aliases['foobar']); + $this->assertEquals('foo', (string) $aliases['moo']); + $this->assertFalse($aliases['moo']->isPublic()); + $builder->register('bar', 'stdClass'); + $this->assertFalse($builder->hasAlias('bar')); + $builder->set('foobar', 'stdClass'); + $builder->set('moo', 'stdClass'); + $this->assertCount(2, $builder->getAliases(), '->getAliases() does not return aliased services that have been overridden'); + } + public function testSetAliases() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setAliases(['bar' => 'foo', 'foobar' => 'foo']); + $aliases = $builder->getAliases(); + $this->assertArrayHasKey('bar', $aliases); + $this->assertArrayHasKey('foobar', $aliases); + } + public function testAddAliases() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setAliases(['bar' => 'foo']); + $builder->addAliases(['foobar' => 'foo']); + $aliases = $builder->getAliases(); + $this->assertArrayHasKey('bar', $aliases); + $this->assertArrayHasKey('foobar', $aliases); + } + public function testSetReplacesAlias() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setAlias('alias', 'aliased'); + $builder->set('aliased', new \stdClass()); + $builder->set('alias', $foo = new \stdClass()); + $this->assertSame($foo, $builder->get('alias'), '->set() replaces an existing alias'); + } + public function testAliasesKeepInvalidBehavior() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $aliased = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $aliased->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)]); + $builder->setDefinition('aliased', $aliased); + $builder->setAlias('alias', 'aliased'); + $this->assertEquals(new \stdClass(), $builder->get('alias')); + } + public function testAddGetCompilerPass() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setResourceTracking(\false); + $defaultPasses = $builder->getCompiler()->getPassConfig()->getPasses(); + $builder->addCompilerPass($pass1 = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CompilerPassInterface')->getMock(), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, -5); + $builder->addCompilerPass($pass2 = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Compiler\\CompilerPassInterface')->getMock(), \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, 10); + $passes = $builder->getCompiler()->getPassConfig()->getPasses(); + $this->assertCount(\count($passes) - 2, $defaultPasses); + // Pass 1 is executed later + $this->assertTrue(\array_search($pass1, $passes, \true) > \array_search($pass2, $passes, \true)); + } + public function testCreateService() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFile(__DIR__ . '/Fixtures/includes/foo.php'); + $builder->register('foo2', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFile(__DIR__ . '/Fixtures/includes/%file%.php'); + $builder->setParameter('file', 'foo'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Bar\\FooClass', $builder->get('foo1'), '->createService() requires the file defined by the service definition'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Bar\\FooClass', $builder->get('foo2'), '->createService() replaces parameters in the file provided by the service definition'); + } + public function testCreateProxyWithRealServiceInstantiator() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFile(__DIR__ . '/Fixtures/includes/foo.php'); + $builder->getDefinition('foo1')->setLazy(\true); + $foo1 = $builder->get('foo1'); + $this->assertSame($foo1, $builder->get('foo1'), 'The same proxy is retrieved on multiple subsequent calls'); + $this->assertSame('_PhpScoper5ea00cc67502b\\Bar\\FooClass', \get_class($foo1)); + } + public function testCreateServiceClass() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo1', '%class%'); + $builder->setParameter('class', 'stdClass'); + $this->assertInstanceOf('\\stdClass', $builder->get('foo1'), '->createService() replaces parameters in the class provided by the service definition'); + } + public function testCreateServiceArguments() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('bar', 'stdClass'); + $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addArgument(['foo' => '%value%', '%value%' => 'foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), '%%unescape_it%%']); + $builder->setParameter('value', 'bar'); + $this->assertEquals(['foo' => 'bar', 'bar' => 'foo', $builder->get('bar'), '%unescape_it%'], $builder->get('foo1')->arguments, '->createService() replaces parameters and service references in the arguments provided by the service definition'); + } + public function testCreateServiceFactory() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFactory('Bar\\FooClass::getInstance'); + $builder->register('qux', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFactory(['_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'getInstance']); + $builder->register('bar', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\Bar\\FooClass'), 'getInstance']); + $builder->register('baz', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), 'getInstance']); + $this->assertTrue($builder->get('foo')->called, '->createService() calls the factory method to create the service instance'); + $this->assertTrue($builder->get('qux')->called, '->createService() calls the factory method to create the service instance'); + $this->assertTrue($builder->get('bar')->called, '->createService() uses anonymous service as factory'); + $this->assertTrue($builder->get('baz')->called, '->createService() uses another service as factory'); + } + public function testCreateServiceMethodCalls() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('bar', 'stdClass'); + $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addMethodCall('setBar', [['%value%', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]]); + $builder->setParameter('value', 'bar'); + $this->assertEquals(['bar', $builder->get('bar')], $builder->get('foo1')->bar, '->createService() replaces the values in the method calls arguments'); + } + public function testCreateServiceMethodCallsWithEscapedParam() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('bar', 'stdClass'); + $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addMethodCall('setBar', [['%%unescape_it%%']]); + $builder->setParameter('value', 'bar'); + $this->assertEquals(['%unescape_it%'], $builder->get('foo1')->bar, '->createService() replaces the values in the method calls arguments'); + } + public function testCreateServiceProperties() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('bar', 'stdClass'); + $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setProperty('bar', ['%value%', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), '%%unescape_it%%']); + $builder->setParameter('value', 'bar'); + $this->assertEquals(['bar', $builder->get('bar'), '%unescape_it%'], $builder->get('foo1')->bar, '->createService() replaces the values in the properties'); + } + public function testCreateServiceConfigurator() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setConfigurator('sc_configure'); + $builder->register('foo2', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setConfigurator(['%class%', 'configureStatic']); + $builder->setParameter('class', 'BazClass'); + $builder->register('baz', 'BazClass'); + $builder->register('foo3', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setConfigurator([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'configure']); + $builder->register('foo4', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setConfigurator([$builder->getDefinition('baz'), 'configure']); + $builder->register('foo5', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setConfigurator('foo'); + $this->assertTrue($builder->get('foo1')->configured, '->createService() calls the configurator'); + $this->assertTrue($builder->get('foo2')->configured, '->createService() calls the configurator'); + $this->assertTrue($builder->get('foo3')->configured, '->createService() calls the configurator'); + $this->assertTrue($builder->get('foo4')->configured, '->createService() calls the configurator'); + try { + $builder->get('foo5'); + $this->fail('->createService() throws an InvalidArgumentException if the configure callable is not a valid callable'); + } catch (\InvalidArgumentException $e) { + $this->assertEquals('The configure callable for class "Bar\\FooClass" is not a callable.', $e->getMessage(), '->createService() throws an InvalidArgumentException if the configure callable is not a valid callable'); + } + } + public function testCreateServiceWithIteratorArgument() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('bar', 'stdClass'); + $builder->register('lazy_context', 'LazyContext')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['k1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('invalid', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])]); + $lazyContext = $builder->get('lazy_context'); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator::class, $lazyContext->lazyValues); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator::class, $lazyContext->lazyEmptyValues); + $this->assertCount(1, $lazyContext->lazyValues); + $this->assertCount(0, $lazyContext->lazyEmptyValues); + $i = 0; + foreach ($lazyContext->lazyValues as $k => $v) { + ++$i; + $this->assertEquals('k1', $k); + $this->assertInstanceOf('\\stdClass', $v); + } + // The second argument should have been ignored. + $this->assertEquals(1, $i); + $i = 0; + foreach ($lazyContext->lazyEmptyValues as $k => $v) { + ++$i; + } + $this->assertEquals(0, $i); + } + public function testCreateSyntheticService() + { + $this->expectException('RuntimeException'); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setSynthetic(\true); + $builder->get('foo'); + } + public function testCreateServiceWithExpression() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setParameter('bar', 'bar'); + $builder->register('bar', 'BarClass'); + $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addArgument(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("bar").foo ~ parameter("bar")')]); + $this->assertEquals('foobar', $builder->get('foo')->arguments['foo']); + } + public function testResolveServices() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); + $this->assertEquals($builder->get('foo'), $builder->resolveServices(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')), '->resolveServices() resolves service references to service instances'); + $this->assertEquals(['foo' => ['foo', $builder->get('foo')]], $builder->resolveServices(['foo' => ['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]]), '->resolveServices() resolves service references to service instances in nested arrays'); + $this->assertEquals($builder->get('foo'), $builder->resolveServices(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("foo")')), '->resolveServices() resolves expressions'); + } + public function testResolveServicesWithDecoratedDefinition() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Constructing service "foo" from a parent definition is not supported at build time.'); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setDefinition('grandpa', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass')); + $builder->setDefinition('parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('grandpa')); + $builder->setDefinition('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('parent')); + $builder->get('foo'); + } + public function testResolveServicesWithCustomDefinitionClass() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setDefinition('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition('stdClass')); + $this->assertInstanceOf('stdClass', $builder->get('foo')); + } + public function testMerge() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['bar' => 'foo'])); + $container->setResourceTracking(\false); + $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); + $container->merge($config); + $this->assertEquals(['bar' => 'foo', 'foo' => 'bar'], $container->getParameterBag()->all(), '->merge() merges current parameters with the loaded ones'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['bar' => 'foo'])); + $container->setResourceTracking(\false); + $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => '%bar%'])); + $container->merge($config); + $container->compile(); + $this->assertEquals(['bar' => 'foo', 'foo' => 'foo'], $container->getParameterBag()->all(), '->merge() evaluates the values of the parameters towards already defined ones'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['bar' => 'foo'])); + $container->setResourceTracking(\false); + $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => '%bar%', 'baz' => '%foo%'])); + $container->merge($config); + $container->compile(); + $this->assertEquals(['bar' => 'foo', 'foo' => 'foo', 'baz' => 'foo'], $container->getParameterBag()->all(), '->merge() evaluates the values of the parameters towards already defined ones'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); + $container->register('bar', 'BarClass'); + $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $config->setDefinition('baz', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BazClass')); + $config->setAlias('alias_for_foo', 'foo'); + $container->merge($config); + $this->assertEquals(['service_container', 'foo', 'bar', 'baz'], \array_keys($container->getDefinitions()), '->merge() merges definitions already defined ones'); + $aliases = $container->getAliases(); + $this->assertArrayHasKey('alias_for_foo', $aliases); + $this->assertEquals('foo', (string) $aliases['alias_for_foo']); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass'); + $config->setDefinition('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BazClass')); + $container->merge($config); + $this->assertEquals('BazClass', $container->getDefinition('foo')->getClass(), '->merge() overrides already defined services'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + $bag->get('env(Foo)'); + $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder($bag); + $this->assertSame(['%env(Bar)%'], $config->resolveEnvPlaceholders([$bag->get('env(Bar)')])); + $container->merge($config); + $this->assertEquals(['Foo' => 0, 'Bar' => 1], $container->getEnvCounters()); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $childDefA = $container->registerForAutoconfiguration('AInterface'); + $childDefB = $config->registerForAutoconfiguration('BInterface'); + $container->merge($config); + $this->assertSame(['AInterface' => $childDefA, 'BInterface' => $childDefB], $container->getAutoconfiguredInstanceof()); + } + public function testMergeThrowsExceptionForDuplicateAutomaticInstanceofDefinitions() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('"AInterface" has already been autoconfigured and merge() does not support merging autoconfiguration for the same class/interface.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $config = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerForAutoconfiguration('AInterface'); + $config->registerForAutoconfiguration('AInterface'); + $container->merge($config); + } + public function testResolveEnvValues() + { + $_ENV['DUMMY_ENV_VAR'] = 'du%%y'; + $_SERVER['DUMMY_SERVER_VAR'] = 'ABC'; + $_SERVER['HTTP_DUMMY_VAR'] = 'DEF'; + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('bar', '%% %env(DUMMY_ENV_VAR)% %env(DUMMY_SERVER_VAR)% %env(HTTP_DUMMY_VAR)%'); + $container->setParameter('env(HTTP_DUMMY_VAR)', '123'); + $this->assertSame('%% du%%%%y ABC 123', $container->resolveEnvPlaceholders('%bar%', \true)); + unset($_ENV['DUMMY_ENV_VAR'], $_SERVER['DUMMY_SERVER_VAR'], $_SERVER['HTTP_DUMMY_VAR']); + } + public function testResolveEnvValuesWithArray() + { + $_ENV['ANOTHER_DUMMY_ENV_VAR'] = 'dummy'; + $dummyArray = ['1' => 'one', '2' => 'two']; + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('dummy', '%env(ANOTHER_DUMMY_ENV_VAR)%'); + $container->setParameter('dummy2', $dummyArray); + $container->resolveEnvPlaceholders('%dummy%', \true); + $container->resolveEnvPlaceholders('%dummy2%', \true); + $this->assertIsArray($container->resolveEnvPlaceholders('%dummy2%', \true)); + foreach ($dummyArray as $key => $value) { + $this->assertArrayHasKey($key, $container->resolveEnvPlaceholders('%dummy2%', \true)); + } + unset($_ENV['ANOTHER_DUMMY_ENV_VAR']); + } + public function testCompileWithResolveEnv() + { + \putenv('DUMMY_ENV_VAR=du%%y'); + $_SERVER['DUMMY_SERVER_VAR'] = 'ABC'; + $_SERVER['HTTP_DUMMY_VAR'] = 'DEF'; + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('env(FOO)', 'Foo'); + $container->setParameter('env(DUMMY_ENV_VAR)', 'GHI'); + $container->setParameter('bar', '%% %env(DUMMY_ENV_VAR)% %env(DUMMY_SERVER_VAR)% %env(HTTP_DUMMY_VAR)%'); + $container->setParameter('foo', '%env(FOO)%'); + $container->setParameter('baz', '%foo%'); + $container->setParameter('env(HTTP_DUMMY_VAR)', '123'); + $container->register('teatime', 'stdClass')->setProperty('foo', '%env(DUMMY_ENV_VAR)%')->setPublic(\true); + $container->compile(\true); + $this->assertSame('% du%%y ABC 123', $container->getParameter('bar')); + $this->assertSame('Foo', $container->getParameter('baz')); + $this->assertSame('du%%y', $container->get('teatime')->foo); + unset($_SERVER['DUMMY_SERVER_VAR'], $_SERVER['HTTP_DUMMY_VAR']); + \putenv('DUMMY_ENV_VAR'); + } + public function testCompileWithArrayResolveEnv() + { + \putenv('ARRAY={"foo":"bar"}'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('foo', '%env(json:ARRAY)%'); + $container->compile(\true); + $this->assertSame(['foo' => 'bar'], $container->getParameter('foo')); + \putenv('ARRAY'); + } + public function testCompileWithArrayAndAnotherResolveEnv() + { + \putenv('DUMMY_ENV_VAR=abc'); + \putenv('ARRAY={"foo":"bar"}'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('foo', '%env(json:ARRAY)%'); + $container->setParameter('bar', '%env(DUMMY_ENV_VAR)%'); + $container->compile(\true); + $this->assertSame(['foo' => 'bar'], $container->getParameter('foo')); + $this->assertSame('abc', $container->getParameter('bar')); + \putenv('DUMMY_ENV_VAR'); + \putenv('ARRAY'); + } + public function testCompileWithArrayInStringResolveEnv() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('A string value must be composed of strings and/or numbers, but found parameter "env(json:ARRAY)" of type "array" inside string value "ABC %env(json:ARRAY)%".'); + \putenv('ARRAY={"foo":"bar"}'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('foo', 'ABC %env(json:ARRAY)%'); + $container->compile(\true); + \putenv('ARRAY'); + } + public function testCompileWithResolveMissingEnv() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvNotFoundException'); + $this->expectExceptionMessage('Environment variable not found: "FOO".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('foo', '%env(FOO)%'); + $container->compile(\true); + } + public function testDynamicEnv() + { + \putenv('DUMMY_FOO=some%foo%'); + \putenv('DUMMY_BAR=%bar%'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('foo', 'Foo%env(resolve:DUMMY_BAR)%'); + $container->setParameter('bar', 'Bar'); + $container->setParameter('baz', '%env(resolve:DUMMY_FOO)%'); + $container->compile(\true); + \putenv('DUMMY_FOO'); + \putenv('DUMMY_BAR'); + $this->assertSame('someFooBar', $container->getParameter('baz')); + } + public function testCastEnv() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('env(FAKE)', '123'); + $container->register('foo', 'stdClass')->setPublic(\true)->setProperties(['fake' => '%env(int:FAKE)%']); + $container->compile(\true); + $this->assertSame(123, $container->get('foo')->fake); + } + public function testEnvAreNullable() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('env(FAKE)', null); + $container->register('foo', 'stdClass')->setPublic(\true)->setProperties(['fake' => '%env(int:FAKE)%']); + $container->compile(\true); + $this->assertNull($container->get('foo')->fake); + } + public function testEnvInId() + { + $container = (include __DIR__ . '/Fixtures/containers/container_env_in_id.php'); + $container->compile(\true); + $expected = ['service_container', 'foo', 'bar', 'bar_%env(BAR)%']; + $this->assertSame($expected, \array_keys($container->getDefinitions())); + $expected = [\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class => \true, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class => \true, 'baz_%env(BAR)%' => \true, 'bar_%env(BAR)%' => \true]; + $this->assertSame($expected, $container->getRemovedIds()); + $this->assertSame(['baz_bar'], \array_keys($container->getDefinition('foo')->getArgument(1))); + } + public function testCircularDynamicEnv() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterCircularReferenceException'); + $this->expectExceptionMessage('Circular reference detected for parameter "env(resolve:DUMMY_ENV_VAR)" ("env(resolve:DUMMY_ENV_VAR)" > "env(resolve:DUMMY_ENV_VAR)").'); + \putenv('DUMMY_ENV_VAR=some%foo%'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('foo', '%bar%'); + $container->setParameter('bar', '%env(resolve:DUMMY_ENV_VAR)%'); + try { + $container->compile(\true); + } finally { + \putenv('DUMMY_ENV_VAR'); + } + } + public function testMergeLogicException() + { + $this->expectException('LogicException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->compile(); + $container->merge(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); + } + public function testfindTaggedServiceIds() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addTag('foo', ['foo' => 'foo'])->addTag('bar', ['bar' => 'bar'])->addTag('foo', ['foofoo' => 'foofoo']); + $this->assertEquals($builder->findTaggedServiceIds('foo'), ['foo' => [['foo' => 'foo'], ['foofoo' => 'foofoo']]], '->findTaggedServiceIds() returns an array of service ids and its tag attributes'); + $this->assertEquals([], $builder->findTaggedServiceIds('foobar'), '->findTaggedServiceIds() returns an empty array if there is annotated services'); + } + public function testFindUnusedTags() + { + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addTag('kernel.event_listener', ['foo' => 'foo'])->addTag('kenrel.event_listener', ['bar' => 'bar']); + $builder->findTaggedServiceIds('kernel.event_listener'); + $this->assertEquals(['kenrel.event_listener'], $builder->findUnusedTags(), '->findUnusedTags() returns an array with unused tags'); + } + public function testFindDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setDefinition('foo', $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\Bar\\FooClass')); + $container->setAlias('bar', 'foo'); + $container->setAlias('foobar', 'bar'); + $this->assertEquals($definition, $container->findDefinition('foobar'), '->findDefinition() returns a Definition'); + } + public function testAddObjectResource() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->addObjectResource(new \_PhpScoper5ea00cc67502b\BarClass()); + $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); + $container->setResourceTracking(\true); + $container->addObjectResource(new \_PhpScoper5ea00cc67502b\BarClass()); + $resources = $container->getResources(); + $this->assertCount(2, $resources, '2 resources were registered'); + /* @var $resource \Symfony\Component\Config\Resource\FileResource */ + $resource = \end($resources); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileResource', $resource); + $this->assertSame(\realpath(__DIR__ . '/Fixtures/includes/classes.php'), \realpath($resource->getResource())); + } + /** + * @group legacy + */ + public function testAddClassResource() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->addClassResource(new \ReflectionClass('BarClass')); + $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); + $container->setResourceTracking(\true); + $container->addClassResource(new \ReflectionClass('BarClass')); + $resources = $container->getResources(); + $this->assertCount(2, $resources, '2 resources were registered'); + /* @var $resource \Symfony\Component\Config\Resource\FileResource */ + $resource = \end($resources); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Config\\Resource\\FileResource', $resource); + $this->assertSame(\realpath(__DIR__ . '/Fixtures/includes/classes.php'), \realpath($resource->getResource())); + } + public function testGetReflectionClass() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $r1 = $container->getReflectionClass('BarClass'); + $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); + $container->setResourceTracking(\true); + $r2 = $container->getReflectionClass('BarClass'); + $r3 = $container->getReflectionClass('BarClass'); + $this->assertNull($container->getReflectionClass('BarMissingClass')); + $this->assertEquals($r1, $r2); + $this->assertSame($r2, $r3); + $resources = $container->getResources(); + $this->assertCount(3, $resources, '3 resources were registered'); + $this->assertSame('reflection.BarClass', (string) $resources[1]); + $this->assertSame('BarMissingClass', (string) \end($resources)); + } + public function testGetReflectionClassOnInternalTypes() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $this->assertNull($container->getReflectionClass('int')); + $this->assertNull($container->getReflectionClass('float')); + $this->assertNull($container->getReflectionClass('string')); + $this->assertNull($container->getReflectionClass('bool')); + $this->assertNull($container->getReflectionClass('resource')); + $this->assertNull($container->getReflectionClass('object')); + $this->assertNull($container->getReflectionClass('array')); + $this->assertNull($container->getReflectionClass('null')); + $this->assertNull($container->getReflectionClass('callable')); + $this->assertNull($container->getReflectionClass('iterable')); + $this->assertNull($container->getReflectionClass('mixed')); + } + public function testCompilesClassDefinitionsOfLazyServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $this->assertEmpty($container->getResources(), 'No resources get registered without resource tracking'); + $container->register('foo', 'BarClass')->setPublic(\true); + $container->getDefinition('foo')->setLazy(\true); + $container->compile(); + $matchingResources = \array_filter($container->getResources(), function (\_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ResourceInterface $resource) { + return 'reflection.BarClass' === (string) $resource; + }); + $this->assertNotEmpty($matchingResources); + } + public function testResources() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->addResource($a = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__DIR__ . '/Fixtures/xml/services1.xml')); + $container->addResource($b = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__DIR__ . '/Fixtures/xml/services2.xml')); + $resources = []; + foreach ($container->getResources() as $resource) { + if (\false === \strpos($resource, '.php')) { + $resources[] = $resource; + } + } + $this->assertEquals([$a, $b], $resources, '->getResources() returns an array of resources read for the current configuration'); + $this->assertSame($container, $container->setResources([])); + $this->assertEquals([], $container->getResources()); + } + public function testFileExists() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $A = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\ComposerResource(); + $a = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__DIR__ . '/Fixtures/xml/services1.xml'); + $b = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource(__DIR__ . '/Fixtures/xml/services2.xml'); + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\DirectoryResource($dir = \dirname($b)); + $this->assertTrue($container->fileExists((string) $a) && $container->fileExists((string) $b) && $container->fileExists($dir)); + $resources = []; + foreach ($container->getResources() as $resource) { + if (\false === \strpos($resource, '.php')) { + $resources[] = $resource; + } + } + $this->assertEquals([$A, $a, $b, $c], $resources, '->getResources() returns an array of resources read for the current configuration'); + } + public function testExtension() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->registerExtension($extension = new \_PhpScoper5ea00cc67502b\ProjectExtension()); + $this->assertSame($container->getExtension('project'), $extension, '->registerExtension() registers an extension'); + $this->expectException('LogicException'); + $container->getExtension('no_registered'); + } + public function testRegisteredButNotLoadedExtension() + { + $extension = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface')->getMock(); + $extension->expects($this->once())->method('getAlias')->willReturn('project'); + $extension->expects($this->never())->method('load'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->registerExtension($extension); + $container->compile(); + } + public function testRegisteredAndLoadedExtension() + { + $extension = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface')->getMock(); + $extension->expects($this->exactly(2))->method('getAlias')->willReturn('project'); + $extension->expects($this->once())->method('load')->with([['foo' => 'bar']]); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->registerExtension($extension); + $container->loadFromExtension('project', ['foo' => 'bar']); + $container->compile(); + } + public function testPrivateServiceUser() + { + $fooDefinition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BarClass'); + $fooUserDefinition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BarUserClass', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')]); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $fooDefinition->setPublic(\false); + $container->addDefinitions(['bar' => $fooDefinition, 'bar_user' => $fooUserDefinition->setPublic(\true)]); + $container->compile(); + $this->assertInstanceOf('BarClass', $container->get('bar_user')->bar); + } + public function testThrowsExceptionWhenSetServiceOnACompiledContainer() + { + $this->expectException('BadMethodCallException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->register('a', 'stdClass')->setPublic(\true); + $container->compile(); + $container->set('a', new \stdClass()); + } + public function testNoExceptionWhenAddServiceOnACompiledContainer() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->compile(); + $container->set('a', $foo = new \stdClass()); + $this->assertSame($foo, $container->get('a')); + } + public function testNoExceptionWhenSetSyntheticServiceOnACompiledContainer() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $def->setSynthetic(\true)->setPublic(\true); + $container->setDefinition('a', $def); + $container->compile(); + $container->set('a', $a = new \stdClass()); + $this->assertEquals($a, $container->get('a')); + } + public function testThrowsExceptionWhenSetDefinitionOnACompiledContainer() + { + $this->expectException('BadMethodCallException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->compile(); + $container->setDefinition('a', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition()); + } + public function testExtensionConfig() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $configs = $container->getExtensionConfig('foo'); + $this->assertEmpty($configs); + $first = ['foo' => 'bar']; + $container->prependExtensionConfig('foo', $first); + $configs = $container->getExtensionConfig('foo'); + $this->assertEquals([$first], $configs); + $second = ['ding' => 'dong']; + $container->prependExtensionConfig('foo', $second); + $configs = $container->getExtensionConfig('foo'); + $this->assertEquals([$second, $first], $configs); + } + public function testAbstractAlias() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $abstract = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('AbstractClass'); + $abstract->setAbstract(\true)->setPublic(\true); + $container->setDefinition('abstract_service', $abstract); + $container->setAlias('abstract_alias', 'abstract_service')->setPublic(\true); + $container->compile(); + $this->assertSame('abstract_service', (string) $container->getAlias('abstract_alias')); + } + public function testLazyLoadedService() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); + $loader->load(function (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) { + $container->set('a', new \_PhpScoper5ea00cc67502b\BazClass()); + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BazClass'); + $definition->setLazy(\true); + $definition->setPublic(\true); + $container->setDefinition('a', $definition); + }); + $container->setResourceTracking(\true); + $container->compile(); + $r = new \ReflectionProperty($container, 'resources'); + $r->setAccessible(\true); + $resources = $r->getValue($container); + $classInList = \false; + foreach ($resources as $resource) { + if ('reflection.BazClass' === (string) $resource) { + $classInList = \true; + break; + } + } + $this->assertTrue($classInList); + } + public function testInlinedDefinitions() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BarClass'); + $container->register('bar_user', 'BarUserClass')->addArgument($definition)->setProperty('foo', $definition); + $container->register('bar', 'BarClass')->setProperty('foo', $definition)->addMethodCall('setBaz', [$definition]); + $barUser = $container->get('bar_user'); + $bar = $container->get('bar'); + $this->assertSame($barUser->foo, $barUser->bar); + $this->assertSame($bar->foo, $bar->getBaz()); + $this->assertNotSame($bar->foo, $barUser->foo); + } + public function testThrowsCircularExceptionForCircularAliases() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $this->expectExceptionMessage('Circular reference detected for service "app.test_class", path: "app.test_class -> App\\TestClass -> app.test_class".'); + $builder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $builder->setAliases(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('app.test_class'), 'app.test_class' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('_PhpScoper5ea00cc67502b\\App\\TestClass'), '_PhpScoper5ea00cc67502b\\App\\TestClass' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Alias('app.test_class')]); + $builder->findDefinition('foo'); + } + public function testInitializePropertiesBeforeMethodCalls() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass'); + $container->register('bar', 'MethodCallClass')->setPublic(\true)->setProperty('simple', 'bar')->setProperty('complex', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))->addMethodCall('callMe'); + $container->compile(); + $this->assertTrue($container->get('bar')->callPassed(), '->compile() initializes properties before method calls'); + } + public function testAutowiring() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\A::class)->setPublic(\true); + $bDefinition = $container->register('b', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\B::class); + $bDefinition->setAutowired(\true); + $bDefinition->setPublic(\true); + $container->compile(); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\A::class, (string) $container->getDefinition('b')->getArgument(0)); + } + public function testClassFromId() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $unknown = $container->register('_PhpScoper5ea00cc67502b\\Acme\\UnknownClass'); + $autoloadClass = $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class); + $container->compile(); + $this->assertSame('_PhpScoper5ea00cc67502b\\Acme\\UnknownClass', $unknown->getClass()); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class, $autoloadClass->getClass()); + } + public function testNoClassFromGlobalNamespaceClassId() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('The definition for "DateTime" has no class attribute, and appears to reference a class or interface in the global namespace.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register(\DateTime::class); + $container->compile(); + } + public function testNoClassFromGlobalNamespaceClassIdWithLeadingSlash() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('The definition for "\\DateTime" has no class attribute, and appears to reference a class or interface in the global namespace.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('\\' . \DateTime::class); + $container->compile(); + } + public function testNoClassFromNamespaceClassIdWithLeadingSlash() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('The definition for "\\Symfony\\Component\\DependencyInjection\\Tests\\FooClass" has no class attribute, and appears to reference a class or interface. Please specify the class attribute explicitly or remove the leading backslash by renaming the service to "Symfony\\Component\\DependencyInjection\\Tests\\FooClass" to get rid of this error.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('\\' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\FooClass::class); + $container->compile(); + } + public function testNoClassFromNonClassId() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('The definition for "123_abc" has no class.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('123_abc'); + $container->compile(); + } + public function testNoClassFromNsSeparatorId() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('The definition for "\\foo" has no class.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('\\foo'); + $container->compile(); + } + public function testServiceLocator() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\true)->addArgument(['bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar_service')), 'baz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference('baz_service', 'stdClass'))]); + $container->register('bar_service', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz_service')])->setPublic(\true); + $container->register('baz_service', 'stdClass')->setPublic(\false); + $container->compile(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class, $foo = $container->get('foo_service')); + $this->assertSame($container->get('bar_service'), $foo->get('bar')); + } + public function testUninitializedReference() + { + $container = (include __DIR__ . '/Fixtures/containers/container_uninitialized_ref.php'); + $container->compile(); + $bar = $container->get('bar'); + $this->assertNull($bar->foo1); + $this->assertNull($bar->foo2); + $this->assertNull($bar->foo3); + $this->assertNull($bar->closures[0]()); + $this->assertNull($bar->closures[1]()); + $this->assertNull($bar->closures[2]()); + $this->assertSame([], \iterator_to_array($bar->iter)); + $container = (include __DIR__ . '/Fixtures/containers/container_uninitialized_ref.php'); + $container->compile(); + $container->get('foo1'); + $container->get('baz'); + $bar = $container->get('bar'); + $this->assertEquals(new \stdClass(), $bar->foo1); + $this->assertNull($bar->foo2); + $this->assertEquals(new \stdClass(), $bar->foo3); + $this->assertEquals(new \stdClass(), $bar->closures[0]()); + $this->assertNull($bar->closures[1]()); + $this->assertEquals(new \stdClass(), $bar->closures[2]()); + $this->assertEquals(['foo1' => new \stdClass(), 'foo3' => new \stdClass()], \iterator_to_array($bar->iter)); + } + /** + * @dataProvider provideAlmostCircular + */ + public function testAlmostCircular($visibility) + { + $container = (include __DIR__ . '/Fixtures/containers/container_almost_circular.php'); + $foo = $container->get('foo'); + $this->assertSame($foo, $foo->bar->foobar->foo); + $foo2 = $container->get('foo2'); + $this->assertSame($foo2, $foo2->bar->foobar->foo); + $this->assertSame([], (array) $container->get('foobar4')); + $foo5 = $container->get('foo5'); + $this->assertSame($foo5, $foo5->bar->foo); + $manager = $container->get('manager'); + $this->assertEquals(new \stdClass(), $manager); + $manager = $container->get('manager2'); + $this->assertEquals(new \stdClass(), $manager); + $foo6 = $container->get('foo6'); + $this->assertEquals((object) ['bar6' => (object) []], $foo6); + $this->assertInstanceOf(\stdClass::class, $container->get('root')); + $manager3 = $container->get('manager3'); + $listener3 = $container->get('listener3'); + $this->assertSame($manager3, $listener3->manager, 'Both should identically be the manager3 service'); + $listener4 = $container->get('listener4'); + $this->assertInstanceOf('stdClass', $listener4); + } + public function provideAlmostCircular() + { + (yield ['public']); + (yield ['private']); + } + public function testRegisterForAutoconfiguration() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $childDefA = $container->registerForAutoconfiguration('AInterface'); + $childDefB = $container->registerForAutoconfiguration('BInterface'); + $this->assertSame(['AInterface' => $childDefA, 'BInterface' => $childDefB], $container->getAutoconfiguredInstanceof()); + // when called multiple times, the same instance is returned + $this->assertSame($childDefA, $container->registerForAutoconfiguration('AInterface')); + } + /** + * This test checks the trigger of a deprecation note and should not be removed in major releases. + * + * @group legacy + * @expectedDeprecation The "foo" service is deprecated. You should stop using it, as it will soon be removed. + */ + public function testPrivateServiceTriggersDeprecation() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setPublic(\false)->setDeprecated(\true); + $container->register('bar', 'stdClass')->setPublic(\true)->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')); + $container->compile(); + $container->get('bar'); + } + /** + * @group legacy + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "FOO" instead of "foo" is deprecated since Symfony 3.4. + */ + public function testParameterWithMixedCase() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); + $container->register('foo', 'stdClass')->setPublic(\true)->setProperty('foo', '%FOO%'); + $container->compile(); + $this->assertSame('bar', $container->get('foo')->foo); + } + public function testArgumentsHaveHigherPriorityThanBindings() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('class.via.bindings', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->setArguments(['via-bindings']); + $container->register('class.via.argument', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->setArguments(['via-argument']); + $container->register('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\SimilarArgumentsDummy::class)->setPublic(\true)->setBindings([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('class.via.bindings'), '$token' => '1234'])->setArguments(['$class1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('class.via.argument')]); + $this->assertSame(['service_container', 'class.via.bindings', 'class.via.argument', 'foo', '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface'], $container->getServiceIds()); + $container->compile(); + $this->assertSame('via-argument', $container->get('foo')->class1->identifier); + $this->assertSame('via-bindings', $container->get('foo')->class2->identifier); + } + public function testUninitializedSyntheticReference() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setPublic(\true)->setSynthetic(\true); + $container->register('bar', 'stdClass')->setPublic(\true)->setShared(\false)->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE)); + $container->compile(); + $this->assertEquals((object) ['foo' => null], $container->get('bar')); + $container->set('foo', (object) [123]); + $this->assertEquals((object) ['foo' => (object) [123]], $container->get('bar')); + } + public function testDecoratedSelfReferenceInvolvingPrivateServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setPublic(\false)->setProperty('bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')); + $container->register('baz', 'stdClass')->setPublic(\false)->setProperty('inner', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz.inner'))->setDecoratedService('foo'); + $container->compile(); + $this->assertSame(['service_container'], \array_keys($container->getDefinitions())); + } + public function testScalarService() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $c->register('foo', 'string')->setPublic(\true)->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ScalarFactory::class, 'getSomeValue']); + $c->compile(); + $this->assertTrue($c->has('foo')); + $this->assertSame('some value', $c->get('foo')); + } +} +class FooClass +{ +} +class A +{ +} +class B +{ + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\A $a) + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/ContainerTest.php b/vendor/symfony/dependency-injection/Tests/ContainerTest.php index b0a551e2b..5fba500c1 100644 --- a/vendor/symfony/dependency-injection/Tests/ContainerTest.php +++ b/vendor/symfony/dependency-injection/Tests/ContainerTest.php @@ -1,561 +1,561 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -class ContainerTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructor() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $this->assertSame($sc, $sc->get('service_container'), '__construct() automatically registers itself as a service'); - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); - $this->assertEquals(['foo' => 'bar'], $sc->getParameterBag()->all(), '__construct() takes an array of parameters as its first argument'); - } - /** - * @dataProvider dataForTestCamelize - */ - public function testCamelize($id, $expected) - { - $this->assertEquals($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::camelize($id), \sprintf('Container::camelize("%s")', $id)); - } - public function dataForTestCamelize() - { - return [['foo_bar', 'FooBar'], ['foo.bar', 'Foo_Bar'], ['foo.bar_baz', 'Foo_BarBaz'], ['foo._bar', 'Foo_Bar'], ['foo_.bar', 'Foo_Bar'], ['_foo', 'Foo'], ['.foo', '_Foo'], ['foo_', 'Foo'], ['foo.', 'Foo_'], ['_PhpScoper5ea00cc67502b\\foo\\bar', 'Foo_Bar']]; - } - /** - * @dataProvider dataForTestUnderscore - */ - public function testUnderscore($id, $expected) - { - $this->assertEquals($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::underscore($id), \sprintf('Container::underscore("%s")', $id)); - } - public function dataForTestUnderscore() - { - return [['FooBar', 'foo_bar'], ['Foo_Bar', 'foo.bar'], ['Foo_BarBaz', 'foo.bar_baz'], ['FooBar_BazQux', 'foo_bar.baz_qux'], ['_Foo', '.foo'], ['Foo_', 'foo.']]; - } - public function testCompile() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); - $this->assertFalse($sc->getParameterBag()->isResolved(), '->compile() resolves the parameter bag'); - $sc->compile(); - $this->assertTrue($sc->getParameterBag()->isResolved(), '->compile() resolves the parameter bag'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\FrozenParameterBag', $sc->getParameterBag(), '->compile() changes the parameter bag to a FrozenParameterBag instance'); - $this->assertEquals(['foo' => 'bar'], $sc->getParameterBag()->all(), '->compile() copies the current parameters to the new parameter bag'); - } - /** - * @group legacy - * @expectedDeprecation The Symfony\Component\DependencyInjection\Container::isFrozen() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead. - * @expectedDeprecation The Symfony\Component\DependencyInjection\Container::isFrozen() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead. - */ - public function testIsFrozen() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); - $this->assertFalse($sc->isFrozen(), '->isFrozen() returns false if the parameters are not frozen'); - $sc->compile(); - $this->assertTrue($sc->isFrozen(), '->isFrozen() returns true if the parameters are frozen'); - } - public function testIsCompiled() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); - $this->assertFalse($sc->isCompiled(), '->isCompiled() returns false if the container is not compiled'); - $sc->compile(); - $this->assertTrue($sc->isCompiled(), '->isCompiled() returns true if the container is compiled'); - } - public function testIsCompiledWithFrozenParameters() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag(['foo' => 'bar'])); - $this->assertFalse($sc->isCompiled(), '->isCompiled() returns false if the container is not compiled but the parameter bag is already frozen'); - } - public function testGetParameterBag() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $this->assertEquals([], $sc->getParameterBag()->all(), '->getParameterBag() returns an empty array if no parameter has been defined'); - } - public function testGetSetParameter() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); - $sc->setParameter('bar', 'foo'); - $this->assertEquals('foo', $sc->getParameter('bar'), '->setParameter() sets the value of a new parameter'); - $sc->setParameter('foo', 'baz'); - $this->assertEquals('baz', $sc->getParameter('foo'), '->setParameter() overrides previously set parameter'); - try { - $sc->getParameter('baba'); - $this->fail('->getParameter() thrown an \\InvalidArgumentException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('\\InvalidArgumentException', $e, '->getParameter() thrown an \\InvalidArgumentException if the key does not exist'); - $this->assertEquals('You have requested a non-existent parameter "baba".', $e->getMessage(), '->getParameter() thrown an \\InvalidArgumentException if the key does not exist'); - } - } - /** - * @group legacy - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "Foo" instead of "foo" is deprecated since Symfony 3.4. - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "FOO" instead of "foo" is deprecated since Symfony 3.4. - */ - public function testGetSetParameterWithMixedCase() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); - $sc->setParameter('Foo', 'baz1'); - $this->assertEquals('baz1', $sc->getParameter('foo'), '->setParameter() converts the key to lowercase'); - $this->assertEquals('baz1', $sc->getParameter('FOO'), '->getParameter() converts the key to lowercase'); - } - public function testGetServiceIds() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $sc->set('foo', $obj = new \stdClass()); - $sc->set('bar', $obj = new \stdClass()); - $this->assertEquals(['service_container', 'foo', 'bar'], $sc->getServiceIds(), '->getServiceIds() returns all defined service ids'); - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $sc->set('foo', $obj = new \stdClass()); - $this->assertEquals(['service_container', 'internal', 'bar', 'foo_bar', 'foo.baz', 'circular', 'throw_exception', 'throws_exception_on_service_configuration', 'internal_dependency', 'alias', 'foo'], $sc->getServiceIds(), '->getServiceIds() returns defined service ids by factory methods in the method map, followed by service ids defined by set()'); - } - /** - * @group legacy - * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. - */ - public function testGetLegacyServiceIds() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\LegacyProjectServiceContainer(); - $sc->set('foo', $obj = new \stdClass()); - $this->assertEquals(['internal', 'bar', 'foo_bar', 'foo.baz', 'circular', 'throw_exception', 'throws_exception_on_service_configuration', 'service_container', 'alias', 'foo'], $sc->getServiceIds(), '->getServiceIds() returns defined service ids by getXXXService() methods, followed by service ids defined by set()'); - } - public function testSet() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $sc->set('._. \\o/', $foo = new \stdClass()); - $this->assertSame($foo, $sc->get('._. \\o/'), '->set() sets a service'); - } - public function testSetWithNullResetTheService() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $sc->set('foo', null); - $this->assertFalse($sc->has('foo'), '->set() with null service resets the service'); - } - public function testSetReplacesAlias() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $c->set('alias', $foo = new \stdClass()); - $this->assertSame($foo, $c->get('alias'), '->set() replaces an existing alias'); - } - /** - * @group legacy - * @expectedDeprecation The "bar" service is already initialized, unsetting it is deprecated since Symfony 3.3 and will fail in 4.0. - */ - public function testSetWithNullOnInitializedPredefinedService() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $sc->set('foo', new \stdClass()); - $sc->set('foo', null); - $this->assertFalse($sc->has('foo'), '->set() with null service resets the service'); - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $sc->get('bar'); - $sc->set('bar', null); - $this->assertTrue($sc->has('bar'), '->set() with null service resets the pre-defined service'); - } - public function testSetWithNullOnUninitializedPredefinedService() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $sc->set('foo', new \stdClass()); - $sc->get('foo', null); - $sc->set('foo', null); - $this->assertFalse($sc->has('foo'), '->set() with null service resets the service'); - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $sc->set('bar', null); - $this->assertTrue($sc->has('bar'), '->set() with null service resets the pre-defined service'); - } - public function testGet() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $sc->set('foo', $foo = new \stdClass()); - $this->assertSame($foo, $sc->get('foo'), '->get() returns the service for the given id'); - $this->assertSame($sc->__bar, $sc->get('bar'), '->get() returns the service for the given id'); - $this->assertSame($sc->__foo_bar, $sc->get('foo_bar'), '->get() returns the service if a get*Method() is defined'); - $this->assertSame($sc->__foo_baz, $sc->get('foo.baz'), '->get() returns the service if a get*Method() is defined'); - try { - $sc->get(''); - $this->fail('->get() throws a \\InvalidArgumentException exception if the service is empty'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException', $e, '->get() throws a ServiceNotFoundException exception if the service is empty'); - } - $this->assertNull($sc->get('', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE), '->get() returns null if the service is empty'); - } - /** - * @group legacy - * @expectedDeprecation Service identifiers will be made case sensitive in Symfony 4.0. Using "Foo" instead of "foo" is deprecated since Symfony 3.3. - */ - public function testGetInsensitivity() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $sc->set('foo', $foo = new \stdClass()); - $this->assertSame($foo, $sc->get('Foo'), '->get() returns the service for the given id, and converts id to lowercase'); - } - /** - * @group legacy - * @expectedDeprecation Service identifiers will be made case sensitive in Symfony 4.0. Using "foo" instead of "Foo" is deprecated since Symfony 3.3. - */ - public function testNormalizeIdKeepsCase() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $sc->normalizeId('Foo', \true); - $this->assertSame('Foo', $sc->normalizeId('foo')); - } - /** - * @group legacy - * @expectedDeprecation Service identifiers will be made case sensitive in Symfony 4.0. Using "Foo" instead of "foo" is deprecated since Symfony 3.3. - * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. - * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. - * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. - * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. - */ - public function testLegacyGet() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\LegacyProjectServiceContainer(); - $sc->set('foo', $foo = new \stdClass()); - $this->assertSame($foo, $sc->get('foo'), '->get() returns the service for the given id'); - $this->assertSame($foo, $sc->get('Foo'), '->get() returns the service for the given id, and converts id to lowercase'); - $this->assertSame($sc->__bar, $sc->get('bar'), '->get() returns the service for the given id'); - $this->assertSame($sc->__foo_bar, $sc->get('foo_bar'), '->get() returns the service if a get*Method() is defined'); - $this->assertSame($sc->__foo_baz, $sc->get('foo.baz'), '->get() returns the service if a get*Method() is defined'); - $this->assertSame($sc->__foo_baz, $sc->get('_PhpScoper5ea00cc67502b\\foo\\baz'), '->get() returns the service if a get*Method() is defined'); - $sc->set('bar', $bar = new \stdClass()); - $this->assertSame($bar, $sc->get('bar'), '->get() prefers to return a service defined with set() than one defined with a getXXXMethod()'); - try { - $sc->get(''); - $this->fail('->get() throws a \\InvalidArgumentException exception if the service is empty'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException', $e, '->get() throws a ServiceNotFoundException exception if the service is empty'); - } - $this->assertNull($sc->get('', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE), '->get() returns null if the service is empty'); - } - public function testGetThrowServiceNotFoundException() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $sc->set('foo', $foo = new \stdClass()); - $sc->set('baz', $foo = new \stdClass()); - try { - $sc->get('foo1'); - $this->fail('->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException', $e, '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException if the key does not exist'); - $this->assertEquals('You have requested a non-existent service "foo1". Did you mean this: "foo"?', $e->getMessage(), '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException with some advices'); - } - try { - $sc->get('bag'); - $this->fail('->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException', $e, '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException if the key does not exist'); - $this->assertEquals('You have requested a non-existent service "bag". Did you mean one of these: "bar", "baz"?', $e->getMessage(), '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException with some advices'); - } - } - public function testGetCircularReference() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - try { - $sc->get('circular'); - $this->fail('->get() throws a ServiceCircularReferenceException if it contains circular reference'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException', $e, '->get() throws a ServiceCircularReferenceException if it contains circular reference'); - $this->assertStringStartsWith('Circular reference detected for service "circular"', $e->getMessage(), '->get() throws a \\LogicException if it contains circular reference'); - } - } - public function testGetSyntheticServiceThrows() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); - $this->expectExceptionMessage('The "request" service is synthetic, it needs to be set at boot time before it can be used.'); - require_once __DIR__ . '/Fixtures/php/services9_compiled.php'; - $container = new \_PhpScoper5ea00cc67502b\ProjectServiceContainer(); - $container->get('request'); - } - public function testGetRemovedServiceThrows() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); - $this->expectExceptionMessage('The "inlined" service or alias has been removed or inlined when the container was compiled. You should either make it public, or stop using the container directly and use dependency injection instead.'); - require_once __DIR__ . '/Fixtures/php/services9_compiled.php'; - $container = new \_PhpScoper5ea00cc67502b\ProjectServiceContainer(); - $container->get('inlined'); - } - public function testHas() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $sc->set('foo', new \stdClass()); - $this->assertFalse($sc->has('foo1'), '->has() returns false if the service does not exist'); - $this->assertTrue($sc->has('foo'), '->has() returns true if the service exists'); - $this->assertTrue($sc->has('bar'), '->has() returns true if a get*Method() is defined'); - $this->assertTrue($sc->has('foo_bar'), '->has() returns true if a get*Method() is defined'); - $this->assertTrue($sc->has('foo.baz'), '->has() returns true if a get*Method() is defined'); - } - /** - * @group legacy - * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. - * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. - * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. - * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. - */ - public function testLegacyHas() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\LegacyProjectServiceContainer(); - $sc->set('foo', new \stdClass()); - $this->assertFalse($sc->has('foo1'), '->has() returns false if the service does not exist'); - $this->assertTrue($sc->has('foo'), '->has() returns true if the service exists'); - $this->assertTrue($sc->has('bar'), '->has() returns true if a get*Method() is defined'); - $this->assertTrue($sc->has('foo_bar'), '->has() returns true if a get*Method() is defined'); - $this->assertTrue($sc->has('foo.baz'), '->has() returns true if a get*Method() is defined'); - $this->assertTrue($sc->has('_PhpScoper5ea00cc67502b\\foo\\baz'), '->has() returns true if a get*Method() is defined'); - } - public function testScalarService() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $c->set('foo', 'some value'); - $this->assertTrue($c->has('foo')); - $this->assertSame('some value', $c->get('foo')); - } - public function testInitialized() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $sc->set('foo', new \stdClass()); - $this->assertTrue($sc->initialized('foo'), '->initialized() returns true if service is loaded'); - $this->assertFalse($sc->initialized('foo1'), '->initialized() returns false if service is not loaded'); - $this->assertFalse($sc->initialized('bar'), '->initialized() returns false if a service is defined, but not currently loaded'); - $this->assertFalse($sc->initialized('alias'), '->initialized() returns false if an aliased service is not initialized'); - $sc->get('bar'); - $this->assertTrue($sc->initialized('alias'), '->initialized() returns true for alias if aliased service is initialized'); - } - /** - * @group legacy - * @expectedDeprecation Checking for the initialization of the "internal" private service is deprecated since Symfony 3.4 and won't be supported anymore in Symfony 4.0. - */ - public function testInitializedWithPrivateService() - { - $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $sc->get('internal_dependency'); - $this->assertTrue($sc->initialized('internal')); - } - public function testReset() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $c->set('bar', new \stdClass()); - $c->reset(); - $this->assertNull($c->get('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE)); - } - public function testGetThrowsException() - { - $this->expectException('Exception'); - $this->expectExceptionMessage('Something went terribly wrong!'); - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - try { - $c->get('throw_exception'); - } catch (\Exception $e) { - // Do nothing. - } - // Retry, to make sure that get*Service() will be called. - $c->get('throw_exception'); - } - public function testGetThrowsExceptionOnServiceConfiguration() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - try { - $c->get('throws_exception_on_service_configuration'); - } catch (\Exception $e) { - // Do nothing. - } - $this->assertFalse($c->initialized('throws_exception_on_service_configuration')); - // Retry, to make sure that get*Service() will be called. - try { - $c->get('throws_exception_on_service_configuration'); - } catch (\Exception $e) { - // Do nothing. - } - $this->assertFalse($c->initialized('throws_exception_on_service_configuration')); - } - protected function getField($obj, $field) - { - $reflection = new \ReflectionProperty($obj, $field); - $reflection->setAccessible(\true); - return $reflection->getValue($obj); - } - public function testAlias() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $this->assertTrue($c->has('alias')); - $this->assertSame($c->get('alias'), $c->get('bar')); - } - public function testThatCloningIsNotSupported() - { - $class = new \ReflectionClass('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Container'); - $clone = $class->getMethod('__clone'); - $this->assertFalse($class->isCloneable()); - $this->assertTrue($clone->isPrivate()); - } - /** - * @group legacy - * @expectedDeprecation The "internal" service is private, unsetting it is deprecated since Symfony 3.2 and will fail in 4.0. - */ - public function testUnsetInternalPrivateServiceIsDeprecated() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $c->set('internal', null); - } - /** - * @group legacy - * @expectedDeprecation The "internal" service is private, replacing it is deprecated since Symfony 3.2 and will fail in 4.0. - */ - public function testChangeInternalPrivateServiceIsDeprecated() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $c->set('internal', $internal = new \stdClass()); - $this->assertSame($c->get('internal'), $internal); - } - /** - * @group legacy - * @expectedDeprecation The "internal" service is private, checking for its existence is deprecated since Symfony 3.2 and will fail in 4.0. - */ - public function testCheckExistenceOfAnInternalPrivateServiceIsDeprecated() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $c->get('internal_dependency'); - $this->assertTrue($c->has('internal')); - } - /** - * @group legacy - * @expectedDeprecation The "internal" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. - */ - public function testRequestAnInternalSharedPrivateServiceIsDeprecated() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $c->get('internal_dependency'); - $c->get('internal'); - } - /** - * @group legacy - * @expectedDeprecation The "bar" service is already initialized, replacing it is deprecated since Symfony 3.3 and will fail in 4.0. - */ - public function testReplacingAPreDefinedServiceIsDeprecated() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $c->set('bar', new \stdClass()); - $c->set('bar', $bar = new \stdClass()); - $this->assertSame($bar, $c->get('bar'), '->set() replaces a pre-defined service'); - } - /** - * @group legacy - * @expectedDeprecation The "synthetic" service is private, replacing it is deprecated since Symfony 3.2 and will fail in 4.0. - */ - public function testSetWithPrivateSyntheticServiceThrowsDeprecation() - { - $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); - $c->set('synthetic', new \stdClass()); - } -} -class ProjectServiceContainer extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container -{ - public $__bar; - public $__foo_bar; - public $__foo_baz; - public $__internal; - protected $privates; - protected $methodMap = ['internal' => 'getInternalService', 'bar' => 'getBarService', 'foo_bar' => 'getFooBarService', 'foo.baz' => 'getFoo_BazService', 'circular' => 'getCircularService', 'throw_exception' => 'getThrowExceptionService', 'throws_exception_on_service_configuration' => 'getThrowsExceptionOnServiceConfigurationService', 'internal_dependency' => 'getInternalDependencyService']; - public function __construct() - { - parent::__construct(); - $this->__bar = new \stdClass(); - $this->__foo_bar = new \stdClass(); - $this->__foo_baz = new \stdClass(); - $this->__internal = new \stdClass(); - $this->privates = ['internal' => \true, 'synthetic' => \true]; - $this->aliases = ['alias' => 'bar']; - $this->syntheticIds['synthetic'] = \true; - } - protected function getInternalService() - { - return $this->services['internal'] = $this->__internal; - } - protected function getBarService() - { - return $this->services['bar'] = $this->__bar; - } - protected function getFooBarService() - { - return $this->__foo_bar; - } - protected function getFoo_BazService() - { - return $this->__foo_baz; - } - protected function getCircularService() - { - return $this->get('circular'); - } - protected function getThrowExceptionService() - { - throw new \Exception('Something went terribly wrong!'); - } - protected function getThrowsExceptionOnServiceConfigurationService() - { - $this->services['throws_exception_on_service_configuration'] = $instance = new \stdClass(); - throw new \Exception('Something was terribly wrong while trying to configure the service!'); - } - protected function getInternalDependencyService() - { - $this->services['internal_dependency'] = $instance = new \stdClass(); - $instance->internal = isset($this->services['internal']) ? $this->services['internal'] : $this->getInternalService(); - return $instance; - } -} -class LegacyProjectServiceContainer extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container -{ - public $__bar; - public $__foo_bar; - public $__foo_baz; - public $__internal; - public function __construct() - { - parent::__construct(); - $this->__bar = new \stdClass(); - $this->__foo_bar = new \stdClass(); - $this->__foo_baz = new \stdClass(); - $this->__internal = new \stdClass(); - $this->privates = ['internal' => \true]; - $this->aliases = ['alias' => 'bar']; - } - protected function getInternalService() - { - return $this->__internal; - } - protected function getBarService() - { - return $this->__bar; - } - protected function getFooBarService() - { - return $this->__foo_bar; - } - protected function getFoo_BazService() - { - return $this->__foo_baz; - } - protected function getCircularService() - { - return $this->get('circular'); - } - protected function getThrowExceptionService() - { - throw new \Exception('Something went terribly wrong!'); - } - protected function getThrowsExceptionOnServiceConfigurationService() - { - $this->services['throws_exception_on_service_configuration'] = $instance = new \stdClass(); - throw new \Exception('Something was terribly wrong while trying to configure the service!'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; +class ContainerTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructor() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $this->assertSame($sc, $sc->get('service_container'), '__construct() automatically registers itself as a service'); + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); + $this->assertEquals(['foo' => 'bar'], $sc->getParameterBag()->all(), '__construct() takes an array of parameters as its first argument'); + } + /** + * @dataProvider dataForTestCamelize + */ + public function testCamelize($id, $expected) + { + $this->assertEquals($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::camelize($id), \sprintf('Container::camelize("%s")', $id)); + } + public function dataForTestCamelize() + { + return [['foo_bar', 'FooBar'], ['foo.bar', 'Foo_Bar'], ['foo.bar_baz', 'Foo_BarBaz'], ['foo._bar', 'Foo_Bar'], ['foo_.bar', 'Foo_Bar'], ['_foo', 'Foo'], ['.foo', '_Foo'], ['foo_', 'Foo'], ['foo.', 'Foo_'], ['_PhpScoper5ea00cc67502b\\foo\\bar', 'Foo_Bar']]; + } + /** + * @dataProvider dataForTestUnderscore + */ + public function testUnderscore($id, $expected) + { + $this->assertEquals($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container::underscore($id), \sprintf('Container::underscore("%s")', $id)); + } + public function dataForTestUnderscore() + { + return [['FooBar', 'foo_bar'], ['Foo_Bar', 'foo.bar'], ['Foo_BarBaz', 'foo.bar_baz'], ['FooBar_BazQux', 'foo_bar.baz_qux'], ['_Foo', '.foo'], ['Foo_', 'foo.']]; + } + public function testCompile() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); + $this->assertFalse($sc->getParameterBag()->isResolved(), '->compile() resolves the parameter bag'); + $sc->compile(); + $this->assertTrue($sc->getParameterBag()->isResolved(), '->compile() resolves the parameter bag'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ParameterBag\\FrozenParameterBag', $sc->getParameterBag(), '->compile() changes the parameter bag to a FrozenParameterBag instance'); + $this->assertEquals(['foo' => 'bar'], $sc->getParameterBag()->all(), '->compile() copies the current parameters to the new parameter bag'); + } + /** + * @group legacy + * @expectedDeprecation The Symfony\Component\DependencyInjection\Container::isFrozen() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead. + * @expectedDeprecation The Symfony\Component\DependencyInjection\Container::isFrozen() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead. + */ + public function testIsFrozen() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); + $this->assertFalse($sc->isFrozen(), '->isFrozen() returns false if the parameters are not frozen'); + $sc->compile(); + $this->assertTrue($sc->isFrozen(), '->isFrozen() returns true if the parameters are frozen'); + } + public function testIsCompiled() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); + $this->assertFalse($sc->isCompiled(), '->isCompiled() returns false if the container is not compiled'); + $sc->compile(); + $this->assertTrue($sc->isCompiled(), '->isCompiled() returns true if the container is compiled'); + } + public function testIsCompiledWithFrozenParameters() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag(['foo' => 'bar'])); + $this->assertFalse($sc->isCompiled(), '->isCompiled() returns false if the container is not compiled but the parameter bag is already frozen'); + } + public function testGetParameterBag() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $this->assertEquals([], $sc->getParameterBag()->all(), '->getParameterBag() returns an empty array if no parameter has been defined'); + } + public function testGetSetParameter() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); + $sc->setParameter('bar', 'foo'); + $this->assertEquals('foo', $sc->getParameter('bar'), '->setParameter() sets the value of a new parameter'); + $sc->setParameter('foo', 'baz'); + $this->assertEquals('baz', $sc->getParameter('foo'), '->setParameter() overrides previously set parameter'); + try { + $sc->getParameter('baba'); + $this->fail('->getParameter() thrown an \\InvalidArgumentException if the key does not exist'); + } catch (\Exception $e) { + $this->assertInstanceOf('\\InvalidArgumentException', $e, '->getParameter() thrown an \\InvalidArgumentException if the key does not exist'); + $this->assertEquals('You have requested a non-existent parameter "baba".', $e->getMessage(), '->getParameter() thrown an \\InvalidArgumentException if the key does not exist'); + } + } + /** + * @group legacy + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "Foo" instead of "foo" is deprecated since Symfony 3.4. + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "FOO" instead of "foo" is deprecated since Symfony 3.4. + */ + public function testGetSetParameterWithMixedCase() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); + $sc->setParameter('Foo', 'baz1'); + $this->assertEquals('baz1', $sc->getParameter('foo'), '->setParameter() converts the key to lowercase'); + $this->assertEquals('baz1', $sc->getParameter('FOO'), '->getParameter() converts the key to lowercase'); + } + public function testGetServiceIds() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $sc->set('foo', $obj = new \stdClass()); + $sc->set('bar', $obj = new \stdClass()); + $this->assertEquals(['service_container', 'foo', 'bar'], $sc->getServiceIds(), '->getServiceIds() returns all defined service ids'); + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $sc->set('foo', $obj = new \stdClass()); + $this->assertEquals(['service_container', 'internal', 'bar', 'foo_bar', 'foo.baz', 'circular', 'throw_exception', 'throws_exception_on_service_configuration', 'internal_dependency', 'alias', 'foo'], $sc->getServiceIds(), '->getServiceIds() returns defined service ids by factory methods in the method map, followed by service ids defined by set()'); + } + /** + * @group legacy + * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. + */ + public function testGetLegacyServiceIds() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\LegacyProjectServiceContainer(); + $sc->set('foo', $obj = new \stdClass()); + $this->assertEquals(['internal', 'bar', 'foo_bar', 'foo.baz', 'circular', 'throw_exception', 'throws_exception_on_service_configuration', 'service_container', 'alias', 'foo'], $sc->getServiceIds(), '->getServiceIds() returns defined service ids by getXXXService() methods, followed by service ids defined by set()'); + } + public function testSet() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $sc->set('._. \\o/', $foo = new \stdClass()); + $this->assertSame($foo, $sc->get('._. \\o/'), '->set() sets a service'); + } + public function testSetWithNullResetTheService() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $sc->set('foo', null); + $this->assertFalse($sc->has('foo'), '->set() with null service resets the service'); + } + public function testSetReplacesAlias() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $c->set('alias', $foo = new \stdClass()); + $this->assertSame($foo, $c->get('alias'), '->set() replaces an existing alias'); + } + /** + * @group legacy + * @expectedDeprecation The "bar" service is already initialized, unsetting it is deprecated since Symfony 3.3 and will fail in 4.0. + */ + public function testSetWithNullOnInitializedPredefinedService() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $sc->set('foo', new \stdClass()); + $sc->set('foo', null); + $this->assertFalse($sc->has('foo'), '->set() with null service resets the service'); + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $sc->get('bar'); + $sc->set('bar', null); + $this->assertTrue($sc->has('bar'), '->set() with null service resets the pre-defined service'); + } + public function testSetWithNullOnUninitializedPredefinedService() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $sc->set('foo', new \stdClass()); + $sc->get('foo', null); + $sc->set('foo', null); + $this->assertFalse($sc->has('foo'), '->set() with null service resets the service'); + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $sc->set('bar', null); + $this->assertTrue($sc->has('bar'), '->set() with null service resets the pre-defined service'); + } + public function testGet() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $sc->set('foo', $foo = new \stdClass()); + $this->assertSame($foo, $sc->get('foo'), '->get() returns the service for the given id'); + $this->assertSame($sc->__bar, $sc->get('bar'), '->get() returns the service for the given id'); + $this->assertSame($sc->__foo_bar, $sc->get('foo_bar'), '->get() returns the service if a get*Method() is defined'); + $this->assertSame($sc->__foo_baz, $sc->get('foo.baz'), '->get() returns the service if a get*Method() is defined'); + try { + $sc->get(''); + $this->fail('->get() throws a \\InvalidArgumentException exception if the service is empty'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException', $e, '->get() throws a ServiceNotFoundException exception if the service is empty'); + } + $this->assertNull($sc->get('', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE), '->get() returns null if the service is empty'); + } + /** + * @group legacy + * @expectedDeprecation Service identifiers will be made case sensitive in Symfony 4.0. Using "Foo" instead of "foo" is deprecated since Symfony 3.3. + */ + public function testGetInsensitivity() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $sc->set('foo', $foo = new \stdClass()); + $this->assertSame($foo, $sc->get('Foo'), '->get() returns the service for the given id, and converts id to lowercase'); + } + /** + * @group legacy + * @expectedDeprecation Service identifiers will be made case sensitive in Symfony 4.0. Using "foo" instead of "Foo" is deprecated since Symfony 3.3. + */ + public function testNormalizeIdKeepsCase() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $sc->normalizeId('Foo', \true); + $this->assertSame('Foo', $sc->normalizeId('foo')); + } + /** + * @group legacy + * @expectedDeprecation Service identifiers will be made case sensitive in Symfony 4.0. Using "Foo" instead of "foo" is deprecated since Symfony 3.3. + * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. + * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. + * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. + * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. + */ + public function testLegacyGet() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\LegacyProjectServiceContainer(); + $sc->set('foo', $foo = new \stdClass()); + $this->assertSame($foo, $sc->get('foo'), '->get() returns the service for the given id'); + $this->assertSame($foo, $sc->get('Foo'), '->get() returns the service for the given id, and converts id to lowercase'); + $this->assertSame($sc->__bar, $sc->get('bar'), '->get() returns the service for the given id'); + $this->assertSame($sc->__foo_bar, $sc->get('foo_bar'), '->get() returns the service if a get*Method() is defined'); + $this->assertSame($sc->__foo_baz, $sc->get('foo.baz'), '->get() returns the service if a get*Method() is defined'); + $this->assertSame($sc->__foo_baz, $sc->get('_PhpScoper5ea00cc67502b\\foo\\baz'), '->get() returns the service if a get*Method() is defined'); + $sc->set('bar', $bar = new \stdClass()); + $this->assertSame($bar, $sc->get('bar'), '->get() prefers to return a service defined with set() than one defined with a getXXXMethod()'); + try { + $sc->get(''); + $this->fail('->get() throws a \\InvalidArgumentException exception if the service is empty'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException', $e, '->get() throws a ServiceNotFoundException exception if the service is empty'); + } + $this->assertNull($sc->get('', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE), '->get() returns null if the service is empty'); + } + public function testGetThrowServiceNotFoundException() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $sc->set('foo', $foo = new \stdClass()); + $sc->set('baz', $foo = new \stdClass()); + try { + $sc->get('foo1'); + $this->fail('->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException if the key does not exist'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException', $e, '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException if the key does not exist'); + $this->assertEquals('You have requested a non-existent service "foo1". Did you mean this: "foo"?', $e->getMessage(), '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException with some advices'); + } + try { + $sc->get('bag'); + $this->fail('->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException if the key does not exist'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException', $e, '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException if the key does not exist'); + $this->assertEquals('You have requested a non-existent service "bag". Did you mean one of these: "bar", "baz"?', $e->getMessage(), '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException with some advices'); + } + } + public function testGetCircularReference() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + try { + $sc->get('circular'); + $this->fail('->get() throws a ServiceCircularReferenceException if it contains circular reference'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException', $e, '->get() throws a ServiceCircularReferenceException if it contains circular reference'); + $this->assertStringStartsWith('Circular reference detected for service "circular"', $e->getMessage(), '->get() throws a \\LogicException if it contains circular reference'); + } + } + public function testGetSyntheticServiceThrows() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); + $this->expectExceptionMessage('The "request" service is synthetic, it needs to be set at boot time before it can be used.'); + require_once __DIR__ . '/Fixtures/php/services9_compiled.php'; + $container = new \_PhpScoper5ea00cc67502b\ProjectServiceContainer(); + $container->get('request'); + } + public function testGetRemovedServiceThrows() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); + $this->expectExceptionMessage('The "inlined" service or alias has been removed or inlined when the container was compiled. You should either make it public, or stop using the container directly and use dependency injection instead.'); + require_once __DIR__ . '/Fixtures/php/services9_compiled.php'; + $container = new \_PhpScoper5ea00cc67502b\ProjectServiceContainer(); + $container->get('inlined'); + } + public function testHas() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $sc->set('foo', new \stdClass()); + $this->assertFalse($sc->has('foo1'), '->has() returns false if the service does not exist'); + $this->assertTrue($sc->has('foo'), '->has() returns true if the service exists'); + $this->assertTrue($sc->has('bar'), '->has() returns true if a get*Method() is defined'); + $this->assertTrue($sc->has('foo_bar'), '->has() returns true if a get*Method() is defined'); + $this->assertTrue($sc->has('foo.baz'), '->has() returns true if a get*Method() is defined'); + } + /** + * @group legacy + * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. + * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. + * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. + * @expectedDeprecation Generating a dumped container without populating the method map is deprecated since Symfony 3.2 and will be unsupported in 4.0. Update your dumper to generate the method map. + */ + public function testLegacyHas() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\LegacyProjectServiceContainer(); + $sc->set('foo', new \stdClass()); + $this->assertFalse($sc->has('foo1'), '->has() returns false if the service does not exist'); + $this->assertTrue($sc->has('foo'), '->has() returns true if the service exists'); + $this->assertTrue($sc->has('bar'), '->has() returns true if a get*Method() is defined'); + $this->assertTrue($sc->has('foo_bar'), '->has() returns true if a get*Method() is defined'); + $this->assertTrue($sc->has('foo.baz'), '->has() returns true if a get*Method() is defined'); + $this->assertTrue($sc->has('_PhpScoper5ea00cc67502b\\foo\\baz'), '->has() returns true if a get*Method() is defined'); + } + public function testScalarService() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $c->set('foo', 'some value'); + $this->assertTrue($c->has('foo')); + $this->assertSame('some value', $c->get('foo')); + } + public function testInitialized() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $sc->set('foo', new \stdClass()); + $this->assertTrue($sc->initialized('foo'), '->initialized() returns true if service is loaded'); + $this->assertFalse($sc->initialized('foo1'), '->initialized() returns false if service is not loaded'); + $this->assertFalse($sc->initialized('bar'), '->initialized() returns false if a service is defined, but not currently loaded'); + $this->assertFalse($sc->initialized('alias'), '->initialized() returns false if an aliased service is not initialized'); + $sc->get('bar'); + $this->assertTrue($sc->initialized('alias'), '->initialized() returns true for alias if aliased service is initialized'); + } + /** + * @group legacy + * @expectedDeprecation Checking for the initialization of the "internal" private service is deprecated since Symfony 3.4 and won't be supported anymore in Symfony 4.0. + */ + public function testInitializedWithPrivateService() + { + $sc = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $sc->get('internal_dependency'); + $this->assertTrue($sc->initialized('internal')); + } + public function testReset() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $c->set('bar', new \stdClass()); + $c->reset(); + $this->assertNull($c->get('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE)); + } + public function testGetThrowsException() + { + $this->expectException('Exception'); + $this->expectExceptionMessage('Something went terribly wrong!'); + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + try { + $c->get('throw_exception'); + } catch (\Exception $e) { + // Do nothing. + } + // Retry, to make sure that get*Service() will be called. + $c->get('throw_exception'); + } + public function testGetThrowsExceptionOnServiceConfiguration() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + try { + $c->get('throws_exception_on_service_configuration'); + } catch (\Exception $e) { + // Do nothing. + } + $this->assertFalse($c->initialized('throws_exception_on_service_configuration')); + // Retry, to make sure that get*Service() will be called. + try { + $c->get('throws_exception_on_service_configuration'); + } catch (\Exception $e) { + // Do nothing. + } + $this->assertFalse($c->initialized('throws_exception_on_service_configuration')); + } + protected function getField($obj, $field) + { + $reflection = new \ReflectionProperty($obj, $field); + $reflection->setAccessible(\true); + return $reflection->getValue($obj); + } + public function testAlias() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $this->assertTrue($c->has('alias')); + $this->assertSame($c->get('alias'), $c->get('bar')); + } + public function testThatCloningIsNotSupported() + { + $class = new \ReflectionClass('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Container'); + $clone = $class->getMethod('__clone'); + $this->assertFalse($class->isCloneable()); + $this->assertTrue($clone->isPrivate()); + } + /** + * @group legacy + * @expectedDeprecation The "internal" service is private, unsetting it is deprecated since Symfony 3.2 and will fail in 4.0. + */ + public function testUnsetInternalPrivateServiceIsDeprecated() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $c->set('internal', null); + } + /** + * @group legacy + * @expectedDeprecation The "internal" service is private, replacing it is deprecated since Symfony 3.2 and will fail in 4.0. + */ + public function testChangeInternalPrivateServiceIsDeprecated() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $c->set('internal', $internal = new \stdClass()); + $this->assertSame($c->get('internal'), $internal); + } + /** + * @group legacy + * @expectedDeprecation The "internal" service is private, checking for its existence is deprecated since Symfony 3.2 and will fail in 4.0. + */ + public function testCheckExistenceOfAnInternalPrivateServiceIsDeprecated() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $c->get('internal_dependency'); + $this->assertTrue($c->has('internal')); + } + /** + * @group legacy + * @expectedDeprecation The "internal" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. + */ + public function testRequestAnInternalSharedPrivateServiceIsDeprecated() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $c->get('internal_dependency'); + $c->get('internal'); + } + /** + * @group legacy + * @expectedDeprecation The "bar" service is already initialized, replacing it is deprecated since Symfony 3.3 and will fail in 4.0. + */ + public function testReplacingAPreDefinedServiceIsDeprecated() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $c->set('bar', new \stdClass()); + $c->set('bar', $bar = new \stdClass()); + $this->assertSame($bar, $c->get('bar'), '->set() replaces a pre-defined service'); + } + /** + * @group legacy + * @expectedDeprecation The "synthetic" service is private, replacing it is deprecated since Symfony 3.2 and will fail in 4.0. + */ + public function testSetWithPrivateSyntheticServiceThrowsDeprecation() + { + $c = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ProjectServiceContainer(); + $c->set('synthetic', new \stdClass()); + } +} +class ProjectServiceContainer extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container +{ + public $__bar; + public $__foo_bar; + public $__foo_baz; + public $__internal; + protected $privates; + protected $methodMap = ['internal' => 'getInternalService', 'bar' => 'getBarService', 'foo_bar' => 'getFooBarService', 'foo.baz' => 'getFoo_BazService', 'circular' => 'getCircularService', 'throw_exception' => 'getThrowExceptionService', 'throws_exception_on_service_configuration' => 'getThrowsExceptionOnServiceConfigurationService', 'internal_dependency' => 'getInternalDependencyService']; + public function __construct() + { + parent::__construct(); + $this->__bar = new \stdClass(); + $this->__foo_bar = new \stdClass(); + $this->__foo_baz = new \stdClass(); + $this->__internal = new \stdClass(); + $this->privates = ['internal' => \true, 'synthetic' => \true]; + $this->aliases = ['alias' => 'bar']; + $this->syntheticIds['synthetic'] = \true; + } + protected function getInternalService() + { + return $this->services['internal'] = $this->__internal; + } + protected function getBarService() + { + return $this->services['bar'] = $this->__bar; + } + protected function getFooBarService() + { + return $this->__foo_bar; + } + protected function getFoo_BazService() + { + return $this->__foo_baz; + } + protected function getCircularService() + { + return $this->get('circular'); + } + protected function getThrowExceptionService() + { + throw new \Exception('Something went terribly wrong!'); + } + protected function getThrowsExceptionOnServiceConfigurationService() + { + $this->services['throws_exception_on_service_configuration'] = $instance = new \stdClass(); + throw new \Exception('Something was terribly wrong while trying to configure the service!'); + } + protected function getInternalDependencyService() + { + $this->services['internal_dependency'] = $instance = new \stdClass(); + $instance->internal = isset($this->services['internal']) ? $this->services['internal'] : $this->getInternalService(); + return $instance; + } +} +class LegacyProjectServiceContainer extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container +{ + public $__bar; + public $__foo_bar; + public $__foo_baz; + public $__internal; + public function __construct() + { + parent::__construct(); + $this->__bar = new \stdClass(); + $this->__foo_bar = new \stdClass(); + $this->__foo_baz = new \stdClass(); + $this->__internal = new \stdClass(); + $this->privates = ['internal' => \true]; + $this->aliases = ['alias' => 'bar']; + } + protected function getInternalService() + { + return $this->__internal; + } + protected function getBarService() + { + return $this->__bar; + } + protected function getFooBarService() + { + return $this->__foo_bar; + } + protected function getFoo_BazService() + { + return $this->__foo_baz; + } + protected function getCircularService() + { + return $this->get('circular'); + } + protected function getThrowExceptionService() + { + throw new \Exception('Something went terribly wrong!'); + } + protected function getThrowsExceptionOnServiceConfigurationService() + { + $this->services['throws_exception_on_service_configuration'] = $instance = new \stdClass(); + throw new \Exception('Something was terribly wrong while trying to configure the service!'); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/CrossCheckTest.php b/vendor/symfony/dependency-injection/Tests/CrossCheckTest.php index f8458911c..4f18f2434 100644 --- a/vendor/symfony/dependency-injection/Tests/CrossCheckTest.php +++ b/vendor/symfony/dependency-injection/Tests/CrossCheckTest.php @@ -1,66 +1,66 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -class CrossCheckTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected static $fixturesPath; - public static function setUpBeforeClass() - { - self::$fixturesPath = __DIR__ . '/Fixtures/'; - require_once self::$fixturesPath . '/includes/classes.php'; - require_once self::$fixturesPath . '/includes/foo.php'; - } - /** - * @dataProvider crossCheckLoadersDumpers - */ - public function testCrossCheck($fixture, $type) - { - $loaderClass = 'Symfony\\Component\\DependencyInjection\\Loader\\' . \ucfirst($type) . 'FileLoader'; - $dumperClass = 'Symfony\\Component\\DependencyInjection\\Dumper\\' . \ucfirst($type) . 'Dumper'; - $tmp = \tempnam(\sys_get_temp_dir(), 'sf'); - \copy(self::$fixturesPath . '/' . $type . '/' . $fixture, $tmp); - $container1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader1 = new $loaderClass($container1, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $loader1->load($tmp); - $dumper = new $dumperClass($container1); - \file_put_contents($tmp, $dumper->dump()); - $container2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader2 = new $loaderClass($container2, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $loader2->load($tmp); - \unlink($tmp); - $this->assertEquals($container2->getAliases(), $container1->getAliases(), 'loading a dump from a previously loaded container returns the same container'); - $this->assertEquals($container2->getDefinitions(), $container1->getDefinitions(), 'loading a dump from a previously loaded container returns the same container'); - $this->assertEquals($container2->getParameterBag()->all(), $container1->getParameterBag()->all(), '->getParameterBag() returns the same value for both containers'); - $r = new \ReflectionProperty(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::class, 'normalizedIds'); - $r->setAccessible(\true); - $r->setValue($container2, []); - $r->setValue($container1, []); - $this->assertEquals(\serialize($container2), \serialize($container1), 'loading a dump from a previously loaded container returns the same container'); - $services1 = []; - foreach ($container1 as $id => $service) { - $services1[$id] = \serialize($service); - } - $services2 = []; - foreach ($container2 as $id => $service) { - $services2[$id] = \serialize($service); - } - unset($services1['service_container'], $services2['service_container']); - $this->assertEquals($services2, $services1, 'Iterator on the containers returns the same services'); - } - public function crossCheckLoadersDumpers() - { - return [['services1.xml', 'xml'], ['services2.xml', 'xml'], ['services6.xml', 'xml'], ['services8.xml', 'xml'], ['services9.xml', 'xml'], ['services1.yml', 'yaml'], ['services2.yml', 'yaml'], ['services6.yml', 'yaml'], ['services8.yml', 'yaml'], ['services9.yml', 'yaml']]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +class CrossCheckTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected static $fixturesPath; + public static function setUpBeforeClass() + { + self::$fixturesPath = __DIR__ . '/Fixtures/'; + require_once self::$fixturesPath . '/includes/classes.php'; + require_once self::$fixturesPath . '/includes/foo.php'; + } + /** + * @dataProvider crossCheckLoadersDumpers + */ + public function testCrossCheck($fixture, $type) + { + $loaderClass = 'Symfony\\Component\\DependencyInjection\\Loader\\' . \ucfirst($type) . 'FileLoader'; + $dumperClass = 'Symfony\\Component\\DependencyInjection\\Dumper\\' . \ucfirst($type) . 'Dumper'; + $tmp = \tempnam(\sys_get_temp_dir(), 'sf'); + \copy(self::$fixturesPath . '/' . $type . '/' . $fixture, $tmp); + $container1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader1 = new $loaderClass($container1, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $loader1->load($tmp); + $dumper = new $dumperClass($container1); + \file_put_contents($tmp, $dumper->dump()); + $container2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader2 = new $loaderClass($container2, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $loader2->load($tmp); + \unlink($tmp); + $this->assertEquals($container2->getAliases(), $container1->getAliases(), 'loading a dump from a previously loaded container returns the same container'); + $this->assertEquals($container2->getDefinitions(), $container1->getDefinitions(), 'loading a dump from a previously loaded container returns the same container'); + $this->assertEquals($container2->getParameterBag()->all(), $container1->getParameterBag()->all(), '->getParameterBag() returns the same value for both containers'); + $r = new \ReflectionProperty(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::class, 'normalizedIds'); + $r->setAccessible(\true); + $r->setValue($container2, []); + $r->setValue($container1, []); + $this->assertEquals(\serialize($container2), \serialize($container1), 'loading a dump from a previously loaded container returns the same container'); + $services1 = []; + foreach ($container1 as $id => $service) { + $services1[$id] = \serialize($service); + } + $services2 = []; + foreach ($container2 as $id => $service) { + $services2[$id] = \serialize($service); + } + unset($services1['service_container'], $services2['service_container']); + $this->assertEquals($services2, $services1, 'Iterator on the containers returns the same services'); + } + public function crossCheckLoadersDumpers() + { + return [['services1.xml', 'xml'], ['services2.xml', 'xml'], ['services6.xml', 'xml'], ['services8.xml', 'xml'], ['services9.xml', 'xml'], ['services1.yml', 'yaml'], ['services2.yml', 'yaml'], ['services6.yml', 'yaml'], ['services8.yml', 'yaml'], ['services9.yml', 'yaml']]; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/DefinitionDecoratorTest.php b/vendor/symfony/dependency-injection/Tests/DefinitionDecoratorTest.php index dd90b625e..dcee3454d 100644 --- a/vendor/symfony/dependency-injection/Tests/DefinitionDecoratorTest.php +++ b/vendor/symfony/dependency-injection/Tests/DefinitionDecoratorTest.php @@ -1,99 +1,99 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator; -/** - * @group legacy - */ -class DefinitionDecoratorTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructor() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); - $this->assertEquals('foo', $def->getParent()); - $this->assertEquals([], $def->getChanges()); - } - /** - * @dataProvider getPropertyTests - */ - public function testSetProperty($property, $changeKey) - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); - $getter = 'get' . \ucfirst($property); - $setter = 'set' . \ucfirst($property); - $this->assertNull($def->{$getter}()); - $this->assertSame($def, $def->{$setter}('foo')); - $this->assertEquals('foo', $def->{$getter}()); - $this->assertEquals([$changeKey => \true], $def->getChanges()); - } - public function getPropertyTests() - { - return [['class', 'class'], ['factory', 'factory'], ['configurator', 'configurator'], ['file', 'file']]; - } - public function testSetPublic() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); - $this->assertTrue($def->isPublic()); - $this->assertSame($def, $def->setPublic(\false)); - $this->assertFalse($def->isPublic()); - $this->assertEquals(['public' => \true], $def->getChanges()); - } - public function testSetLazy() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); - $this->assertFalse($def->isLazy()); - $this->assertSame($def, $def->setLazy(\false)); - $this->assertFalse($def->isLazy()); - $this->assertEquals(['lazy' => \true], $def->getChanges()); - } - public function testSetAutowired() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); - $this->assertFalse($def->isAutowired()); - $this->assertSame($def, $def->setAutowired(\true)); - $this->assertTrue($def->isAutowired()); - $this->assertSame(['autowired' => \true], $def->getChanges()); - } - public function testSetArgument() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); - $this->assertEquals([], $def->getArguments()); - $this->assertSame($def, $def->replaceArgument(0, 'foo')); - $this->assertEquals(['index_0' => 'foo'], $def->getArguments()); - } - public function testReplaceArgumentShouldRequireIntegerIndex() - { - $this->expectException('InvalidArgumentException'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); - $def->replaceArgument('0', 'foo'); - } - public function testReplaceArgument() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); - $def->setArguments([0 => 'foo', 1 => 'bar']); - $this->assertEquals('foo', $def->getArgument(0)); - $this->assertEquals('bar', $def->getArgument(1)); - $this->assertSame($def, $def->replaceArgument(1, 'baz')); - $this->assertEquals('foo', $def->getArgument(0)); - $this->assertEquals('baz', $def->getArgument(1)); - $this->assertEquals([0 => 'foo', 1 => 'bar', 'index_1' => 'baz'], $def->getArguments()); - } - public function testGetArgumentShouldCheckBounds() - { - $this->expectException('OutOfBoundsException'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); - $def->setArguments([0 => 'foo']); - $def->replaceArgument(0, 'foo'); - $def->getArgument(1); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator; +/** + * @group legacy + */ +class DefinitionDecoratorTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructor() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); + $this->assertEquals('foo', $def->getParent()); + $this->assertEquals([], $def->getChanges()); + } + /** + * @dataProvider getPropertyTests + */ + public function testSetProperty($property, $changeKey) + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); + $getter = 'get' . \ucfirst($property); + $setter = 'set' . \ucfirst($property); + $this->assertNull($def->{$getter}()); + $this->assertSame($def, $def->{$setter}('foo')); + $this->assertEquals('foo', $def->{$getter}()); + $this->assertEquals([$changeKey => \true], $def->getChanges()); + } + public function getPropertyTests() + { + return [['class', 'class'], ['factory', 'factory'], ['configurator', 'configurator'], ['file', 'file']]; + } + public function testSetPublic() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); + $this->assertTrue($def->isPublic()); + $this->assertSame($def, $def->setPublic(\false)); + $this->assertFalse($def->isPublic()); + $this->assertEquals(['public' => \true], $def->getChanges()); + } + public function testSetLazy() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); + $this->assertFalse($def->isLazy()); + $this->assertSame($def, $def->setLazy(\false)); + $this->assertFalse($def->isLazy()); + $this->assertEquals(['lazy' => \true], $def->getChanges()); + } + public function testSetAutowired() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); + $this->assertFalse($def->isAutowired()); + $this->assertSame($def, $def->setAutowired(\true)); + $this->assertTrue($def->isAutowired()); + $this->assertSame(['autowired' => \true], $def->getChanges()); + } + public function testSetArgument() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); + $this->assertEquals([], $def->getArguments()); + $this->assertSame($def, $def->replaceArgument(0, 'foo')); + $this->assertEquals(['index_0' => 'foo'], $def->getArguments()); + } + public function testReplaceArgumentShouldRequireIntegerIndex() + { + $this->expectException('InvalidArgumentException'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); + $def->replaceArgument('0', 'foo'); + } + public function testReplaceArgument() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); + $def->setArguments([0 => 'foo', 1 => 'bar']); + $this->assertEquals('foo', $def->getArgument(0)); + $this->assertEquals('bar', $def->getArgument(1)); + $this->assertSame($def, $def->replaceArgument(1, 'baz')); + $this->assertEquals('foo', $def->getArgument(0)); + $this->assertEquals('baz', $def->getArgument(1)); + $this->assertEquals([0 => 'foo', 1 => 'bar', 'index_1' => 'baz'], $def->getArguments()); + } + public function testGetArgumentShouldCheckBounds() + { + $this->expectException('OutOfBoundsException'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\DefinitionDecorator('foo'); + $def->setArguments([0 => 'foo']); + $def->replaceArgument(0, 'foo'); + $def->getArgument(1); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/DefinitionTest.php b/vendor/symfony/dependency-injection/Tests/DefinitionTest.php index 49825bd66..da3984988 100644 --- a/vendor/symfony/dependency-injection/Tests/DefinitionTest.php +++ b/vendor/symfony/dependency-injection/Tests/DefinitionTest.php @@ -1,309 +1,309 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -class DefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructor() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertEquals('stdClass', $def->getClass(), '__construct() takes the class name as its first argument'); - $this->assertSame(['class' => \true], $def->getChanges()); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass', ['foo']); - $this->assertEquals(['foo'], $def->getArguments(), '__construct() takes an optional array of arguments as its second argument'); - } - public function testSetGetFactory() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $this->assertSame($def, $def->setFactory('foo'), '->setFactory() implements a fluent interface'); - $this->assertEquals('foo', $def->getFactory(), '->getFactory() returns the factory'); - $def->setFactory('Foo::bar'); - $this->assertEquals(['Foo', 'bar'], $def->getFactory(), '->setFactory() converts string static method call to the array'); - $this->assertSame(['factory' => \true], $def->getChanges()); - } - public function testSetGetClass() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertSame($def, $def->setClass('foo'), '->setClass() implements a fluent interface'); - $this->assertEquals('foo', $def->getClass(), '->getClass() returns the class name'); - } - public function testSetGetDecoratedService() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertNull($def->getDecoratedService()); - $def->setDecoratedService('foo', 'foo.renamed', 5); - $this->assertEquals(['foo', 'foo.renamed', 5], $def->getDecoratedService()); - $def->setDecoratedService(null); - $this->assertNull($def->getDecoratedService()); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertNull($def->getDecoratedService()); - $def->setDecoratedService('foo', 'foo.renamed'); - $this->assertEquals(['foo', 'foo.renamed', 0], $def->getDecoratedService()); - $def->setDecoratedService(null); - $this->assertNull($def->getDecoratedService()); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $def->setDecoratedService('foo'); - $this->assertEquals(['foo', null, 0], $def->getDecoratedService()); - $def->setDecoratedService(null); - $this->assertNull($def->getDecoratedService()); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('The decorated service inner name for "foo" must be different than the service name itself.'); - $def->setDecoratedService('foo', 'foo'); - } - public function testArguments() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertSame($def, $def->setArguments(['foo']), '->setArguments() implements a fluent interface'); - $this->assertEquals(['foo'], $def->getArguments(), '->getArguments() returns the arguments'); - $this->assertSame($def, $def->addArgument('bar'), '->addArgument() implements a fluent interface'); - $this->assertEquals(['foo', 'bar'], $def->getArguments(), '->addArgument() adds an argument'); - } - public function testMethodCalls() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertSame($def, $def->setMethodCalls([['foo', ['foo']]]), '->setMethodCalls() implements a fluent interface'); - $this->assertEquals([['foo', ['foo']]], $def->getMethodCalls(), '->getMethodCalls() returns the methods to call'); - $this->assertSame($def, $def->addMethodCall('bar', ['bar']), '->addMethodCall() implements a fluent interface'); - $this->assertEquals([['foo', ['foo']], ['bar', ['bar']]], $def->getMethodCalls(), '->addMethodCall() adds a method to call'); - $this->assertTrue($def->hasMethodCall('bar'), '->hasMethodCall() returns true if first argument is a method to call registered'); - $this->assertFalse($def->hasMethodCall('no_registered'), '->hasMethodCall() returns false if first argument is not a method to call registered'); - $this->assertSame($def, $def->removeMethodCall('bar'), '->removeMethodCall() implements a fluent interface'); - $this->assertEquals([['foo', ['foo']]], $def->getMethodCalls(), '->removeMethodCall() removes a method to call'); - } - public function testExceptionOnEmptyMethodCall() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Method name cannot be empty.'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $def->addMethodCall(''); - } - public function testSetGetFile() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertSame($def, $def->setFile('foo'), '->setFile() implements a fluent interface'); - $this->assertEquals('foo', $def->getFile(), '->getFile() returns the file to include'); - } - public function testSetIsShared() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertTrue($def->isShared(), '->isShared() returns true by default'); - $this->assertSame($def, $def->setShared(\false), '->setShared() implements a fluent interface'); - $this->assertFalse($def->isShared(), '->isShared() returns false if the instance must not be shared'); - } - public function testSetIsPublic() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertTrue($def->isPublic(), '->isPublic() returns true by default'); - $this->assertSame($def, $def->setPublic(\false), '->setPublic() implements a fluent interface'); - $this->assertFalse($def->isPublic(), '->isPublic() returns false if the instance must not be public.'); - } - public function testSetIsSynthetic() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertFalse($def->isSynthetic(), '->isSynthetic() returns false by default'); - $this->assertSame($def, $def->setSynthetic(\true), '->setSynthetic() implements a fluent interface'); - $this->assertTrue($def->isSynthetic(), '->isSynthetic() returns true if the service is synthetic.'); - } - public function testSetIsLazy() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertFalse($def->isLazy(), '->isLazy() returns false by default'); - $this->assertSame($def, $def->setLazy(\true), '->setLazy() implements a fluent interface'); - $this->assertTrue($def->isLazy(), '->isLazy() returns true if the service is lazy.'); - } - public function testSetIsAbstract() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertFalse($def->isAbstract(), '->isAbstract() returns false by default'); - $this->assertSame($def, $def->setAbstract(\true), '->setAbstract() implements a fluent interface'); - $this->assertTrue($def->isAbstract(), '->isAbstract() returns true if the instance must not be public.'); - } - public function testSetIsDeprecated() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertFalse($def->isDeprecated(), '->isDeprecated() returns false by default'); - $this->assertSame($def, $def->setDeprecated(\true), '->setDeprecated() implements a fluent interface'); - $this->assertTrue($def->isDeprecated(), '->isDeprecated() returns true if the instance should not be used anymore.'); - $this->assertSame('The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed.', $def->getDeprecationMessage('deprecated_service'), '->getDeprecationMessage() should return a formatted message template'); - } - /** - * @dataProvider invalidDeprecationMessageProvider - */ - public function testSetDeprecatedWithInvalidDeprecationTemplate($message) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $def->setDeprecated(\false, $message); - } - public function invalidDeprecationMessageProvider() - { - return ["With \rs" => ["invalid \r message %service_id%"], "With \ns" => ["invalid \n message %service_id%"], 'With */s' => ['invalid */ message %service_id%'], 'message not containing require %service_id% variable' => ['this is deprecated']]; - } - public function testSetGetConfigurator() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertSame($def, $def->setConfigurator('foo'), '->setConfigurator() implements a fluent interface'); - $this->assertEquals('foo', $def->getConfigurator(), '->getConfigurator() returns the configurator'); - } - public function testClearTags() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertSame($def, $def->clearTags(), '->clearTags() implements a fluent interface'); - $def->addTag('foo', ['foo' => 'bar']); - $def->clearTags(); - $this->assertEquals([], $def->getTags(), '->clearTags() removes all current tags'); - } - public function testClearTag() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertSame($def, $def->clearTags(), '->clearTags() implements a fluent interface'); - $def->addTag('1foo1', ['foo1' => 'bar1']); - $def->addTag('2foo2', ['foo2' => 'bar2']); - $def->addTag('3foo3', ['foo3' => 'bar3']); - $def->clearTag('2foo2'); - $this->assertTrue($def->hasTag('1foo1')); - $this->assertFalse($def->hasTag('2foo2')); - $this->assertTrue($def->hasTag('3foo3')); - $def->clearTag('1foo1'); - $this->assertFalse($def->hasTag('1foo1')); - $this->assertTrue($def->hasTag('3foo3')); - } - public function testTags() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertEquals([], $def->getTag('foo'), '->getTag() returns an empty array if the tag is not defined'); - $this->assertFalse($def->hasTag('foo')); - $this->assertSame($def, $def->addTag('foo'), '->addTag() implements a fluent interface'); - $this->assertTrue($def->hasTag('foo')); - $this->assertEquals([[]], $def->getTag('foo'), '->getTag() returns attributes for a tag name'); - $def->addTag('foo', ['foo' => 'bar']); - $this->assertEquals([[], ['foo' => 'bar']], $def->getTag('foo'), '->addTag() can adds the same tag several times'); - $def->addTag('bar', ['bar' => 'bar']); - $this->assertEquals($def->getTags(), ['foo' => [[], ['foo' => 'bar']], 'bar' => [['bar' => 'bar']]], '->getTags() returns all tags'); - } - public function testSetArgument() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $def->addArgument('foo'); - $this->assertSame(['foo'], $def->getArguments()); - $this->assertSame($def, $def->replaceArgument(0, 'moo')); - $this->assertSame(['moo'], $def->getArguments()); - $def->addArgument('moo'); - $def->replaceArgument(0, 'foo')->replaceArgument(1, 'bar'); - $this->assertSame(['foo', 'bar'], $def->getArguments()); - } - public function testGetArgumentShouldCheckBounds() - { - $this->expectException('OutOfBoundsException'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $def->addArgument('foo'); - $def->getArgument(1); - } - public function testReplaceArgumentShouldCheckBounds() - { - $this->expectException('OutOfBoundsException'); - $this->expectExceptionMessage('The index "1" is not in the range [0, 0].'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $def->addArgument('foo'); - $def->replaceArgument(1, 'bar'); - } - public function testReplaceArgumentWithoutExistingArgumentsShouldCheckBounds() - { - $this->expectException('OutOfBoundsException'); - $this->expectExceptionMessage('Cannot replace arguments if none have been configured yet.'); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $def->replaceArgument(0, 'bar'); - } - public function testSetGetProperties() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertEquals([], $def->getProperties()); - $this->assertSame($def, $def->setProperties(['foo' => 'bar'])); - $this->assertEquals(['foo' => 'bar'], $def->getProperties()); - } - public function testSetProperty() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertEquals([], $def->getProperties()); - $this->assertSame($def, $def->setProperty('foo', 'bar')); - $this->assertEquals(['foo' => 'bar'], $def->getProperties()); - } - public function testAutowired() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertFalse($def->isAutowired()); - $def->setAutowired(\true); - $this->assertTrue($def->isAutowired()); - $def->setAutowired(\false); - $this->assertFalse($def->isAutowired()); - } - public function testChangesNoChanges() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $this->assertSame([], $def->getChanges()); - } - public function testGetChangesWithChanges() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass', ['fooarg']); - $def->setAbstract(\true); - $def->setAutowired(\true); - $def->setConfigurator('configuration_func'); - $def->setDecoratedService(null); - $def->setDeprecated(\true); - $def->setFactory('factory_func'); - $def->setFile('foo.php'); - $def->setLazy(\true); - $def->setPublic(\true); - $def->setShared(\true); - $def->setSynthetic(\true); - // changes aren't tracked for these, class or arguments - $def->setInstanceofConditionals([]); - $def->addTag('foo_tag'); - $def->addMethodCall('methodCall'); - $def->setProperty('fooprop', \true); - $def->setAutoconfigured(\true); - $this->assertSame(['class' => \true, 'autowired' => \true, 'configurator' => \true, 'decorated_service' => \true, 'deprecated' => \true, 'factory' => \true, 'file' => \true, 'lazy' => \true, 'public' => \true, 'shared' => \true, 'autoconfigured' => \true], $def->getChanges()); - $def->setChanges([]); - $this->assertSame([], $def->getChanges()); - } - /** - * @group legacy - */ - public function testTypes() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertEquals([], $def->getAutowiringTypes()); - $this->assertSame($def, $def->setAutowiringTypes(['Foo'])); - $this->assertEquals(['Foo'], $def->getAutowiringTypes()); - $this->assertSame($def, $def->addAutowiringType('Bar')); - $this->assertTrue($def->hasAutowiringType('Bar')); - $this->assertSame($def, $def->removeAutowiringType('Foo')); - $this->assertEquals(['Bar'], $def->getAutowiringTypes()); - } - public function testShouldAutoconfigure() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertFalse($def->isAutoconfigured()); - $def->setAutoconfigured(\true); - $this->assertTrue($def->isAutoconfigured()); - } - public function testAddError() - { - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertEmpty($def->getErrors()); - $def->addError('First error'); - $def->addError('Second error'); - $this->assertSame(['First error', 'Second error'], $def->getErrors()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +class DefinitionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructor() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertEquals('stdClass', $def->getClass(), '__construct() takes the class name as its first argument'); + $this->assertSame(['class' => \true], $def->getChanges()); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass', ['foo']); + $this->assertEquals(['foo'], $def->getArguments(), '__construct() takes an optional array of arguments as its second argument'); + } + public function testSetGetFactory() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $this->assertSame($def, $def->setFactory('foo'), '->setFactory() implements a fluent interface'); + $this->assertEquals('foo', $def->getFactory(), '->getFactory() returns the factory'); + $def->setFactory('Foo::bar'); + $this->assertEquals(['Foo', 'bar'], $def->getFactory(), '->setFactory() converts string static method call to the array'); + $this->assertSame(['factory' => \true], $def->getChanges()); + } + public function testSetGetClass() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertSame($def, $def->setClass('foo'), '->setClass() implements a fluent interface'); + $this->assertEquals('foo', $def->getClass(), '->getClass() returns the class name'); + } + public function testSetGetDecoratedService() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertNull($def->getDecoratedService()); + $def->setDecoratedService('foo', 'foo.renamed', 5); + $this->assertEquals(['foo', 'foo.renamed', 5], $def->getDecoratedService()); + $def->setDecoratedService(null); + $this->assertNull($def->getDecoratedService()); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertNull($def->getDecoratedService()); + $def->setDecoratedService('foo', 'foo.renamed'); + $this->assertEquals(['foo', 'foo.renamed', 0], $def->getDecoratedService()); + $def->setDecoratedService(null); + $this->assertNull($def->getDecoratedService()); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $def->setDecoratedService('foo'); + $this->assertEquals(['foo', null, 0], $def->getDecoratedService()); + $def->setDecoratedService(null); + $this->assertNull($def->getDecoratedService()); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('The decorated service inner name for "foo" must be different than the service name itself.'); + $def->setDecoratedService('foo', 'foo'); + } + public function testArguments() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertSame($def, $def->setArguments(['foo']), '->setArguments() implements a fluent interface'); + $this->assertEquals(['foo'], $def->getArguments(), '->getArguments() returns the arguments'); + $this->assertSame($def, $def->addArgument('bar'), '->addArgument() implements a fluent interface'); + $this->assertEquals(['foo', 'bar'], $def->getArguments(), '->addArgument() adds an argument'); + } + public function testMethodCalls() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertSame($def, $def->setMethodCalls([['foo', ['foo']]]), '->setMethodCalls() implements a fluent interface'); + $this->assertEquals([['foo', ['foo']]], $def->getMethodCalls(), '->getMethodCalls() returns the methods to call'); + $this->assertSame($def, $def->addMethodCall('bar', ['bar']), '->addMethodCall() implements a fluent interface'); + $this->assertEquals([['foo', ['foo']], ['bar', ['bar']]], $def->getMethodCalls(), '->addMethodCall() adds a method to call'); + $this->assertTrue($def->hasMethodCall('bar'), '->hasMethodCall() returns true if first argument is a method to call registered'); + $this->assertFalse($def->hasMethodCall('no_registered'), '->hasMethodCall() returns false if first argument is not a method to call registered'); + $this->assertSame($def, $def->removeMethodCall('bar'), '->removeMethodCall() implements a fluent interface'); + $this->assertEquals([['foo', ['foo']]], $def->getMethodCalls(), '->removeMethodCall() removes a method to call'); + } + public function testExceptionOnEmptyMethodCall() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Method name cannot be empty.'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $def->addMethodCall(''); + } + public function testSetGetFile() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertSame($def, $def->setFile('foo'), '->setFile() implements a fluent interface'); + $this->assertEquals('foo', $def->getFile(), '->getFile() returns the file to include'); + } + public function testSetIsShared() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertTrue($def->isShared(), '->isShared() returns true by default'); + $this->assertSame($def, $def->setShared(\false), '->setShared() implements a fluent interface'); + $this->assertFalse($def->isShared(), '->isShared() returns false if the instance must not be shared'); + } + public function testSetIsPublic() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertTrue($def->isPublic(), '->isPublic() returns true by default'); + $this->assertSame($def, $def->setPublic(\false), '->setPublic() implements a fluent interface'); + $this->assertFalse($def->isPublic(), '->isPublic() returns false if the instance must not be public.'); + } + public function testSetIsSynthetic() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertFalse($def->isSynthetic(), '->isSynthetic() returns false by default'); + $this->assertSame($def, $def->setSynthetic(\true), '->setSynthetic() implements a fluent interface'); + $this->assertTrue($def->isSynthetic(), '->isSynthetic() returns true if the service is synthetic.'); + } + public function testSetIsLazy() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertFalse($def->isLazy(), '->isLazy() returns false by default'); + $this->assertSame($def, $def->setLazy(\true), '->setLazy() implements a fluent interface'); + $this->assertTrue($def->isLazy(), '->isLazy() returns true if the service is lazy.'); + } + public function testSetIsAbstract() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertFalse($def->isAbstract(), '->isAbstract() returns false by default'); + $this->assertSame($def, $def->setAbstract(\true), '->setAbstract() implements a fluent interface'); + $this->assertTrue($def->isAbstract(), '->isAbstract() returns true if the instance must not be public.'); + } + public function testSetIsDeprecated() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertFalse($def->isDeprecated(), '->isDeprecated() returns false by default'); + $this->assertSame($def, $def->setDeprecated(\true), '->setDeprecated() implements a fluent interface'); + $this->assertTrue($def->isDeprecated(), '->isDeprecated() returns true if the instance should not be used anymore.'); + $this->assertSame('The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed.', $def->getDeprecationMessage('deprecated_service'), '->getDeprecationMessage() should return a formatted message template'); + } + /** + * @dataProvider invalidDeprecationMessageProvider + */ + public function testSetDeprecatedWithInvalidDeprecationTemplate($message) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $def->setDeprecated(\false, $message); + } + public function invalidDeprecationMessageProvider() + { + return ["With \rs" => ["invalid \r message %service_id%"], "With \ns" => ["invalid \n message %service_id%"], 'With */s' => ['invalid */ message %service_id%'], 'message not containing require %service_id% variable' => ['this is deprecated']]; + } + public function testSetGetConfigurator() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertSame($def, $def->setConfigurator('foo'), '->setConfigurator() implements a fluent interface'); + $this->assertEquals('foo', $def->getConfigurator(), '->getConfigurator() returns the configurator'); + } + public function testClearTags() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertSame($def, $def->clearTags(), '->clearTags() implements a fluent interface'); + $def->addTag('foo', ['foo' => 'bar']); + $def->clearTags(); + $this->assertEquals([], $def->getTags(), '->clearTags() removes all current tags'); + } + public function testClearTag() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertSame($def, $def->clearTags(), '->clearTags() implements a fluent interface'); + $def->addTag('1foo1', ['foo1' => 'bar1']); + $def->addTag('2foo2', ['foo2' => 'bar2']); + $def->addTag('3foo3', ['foo3' => 'bar3']); + $def->clearTag('2foo2'); + $this->assertTrue($def->hasTag('1foo1')); + $this->assertFalse($def->hasTag('2foo2')); + $this->assertTrue($def->hasTag('3foo3')); + $def->clearTag('1foo1'); + $this->assertFalse($def->hasTag('1foo1')); + $this->assertTrue($def->hasTag('3foo3')); + } + public function testTags() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertEquals([], $def->getTag('foo'), '->getTag() returns an empty array if the tag is not defined'); + $this->assertFalse($def->hasTag('foo')); + $this->assertSame($def, $def->addTag('foo'), '->addTag() implements a fluent interface'); + $this->assertTrue($def->hasTag('foo')); + $this->assertEquals([[]], $def->getTag('foo'), '->getTag() returns attributes for a tag name'); + $def->addTag('foo', ['foo' => 'bar']); + $this->assertEquals([[], ['foo' => 'bar']], $def->getTag('foo'), '->addTag() can adds the same tag several times'); + $def->addTag('bar', ['bar' => 'bar']); + $this->assertEquals($def->getTags(), ['foo' => [[], ['foo' => 'bar']], 'bar' => [['bar' => 'bar']]], '->getTags() returns all tags'); + } + public function testSetArgument() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $def->addArgument('foo'); + $this->assertSame(['foo'], $def->getArguments()); + $this->assertSame($def, $def->replaceArgument(0, 'moo')); + $this->assertSame(['moo'], $def->getArguments()); + $def->addArgument('moo'); + $def->replaceArgument(0, 'foo')->replaceArgument(1, 'bar'); + $this->assertSame(['foo', 'bar'], $def->getArguments()); + } + public function testGetArgumentShouldCheckBounds() + { + $this->expectException('OutOfBoundsException'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $def->addArgument('foo'); + $def->getArgument(1); + } + public function testReplaceArgumentShouldCheckBounds() + { + $this->expectException('OutOfBoundsException'); + $this->expectExceptionMessage('The index "1" is not in the range [0, 0].'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $def->addArgument('foo'); + $def->replaceArgument(1, 'bar'); + } + public function testReplaceArgumentWithoutExistingArgumentsShouldCheckBounds() + { + $this->expectException('OutOfBoundsException'); + $this->expectExceptionMessage('Cannot replace arguments if none have been configured yet.'); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $def->replaceArgument(0, 'bar'); + } + public function testSetGetProperties() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertEquals([], $def->getProperties()); + $this->assertSame($def, $def->setProperties(['foo' => 'bar'])); + $this->assertEquals(['foo' => 'bar'], $def->getProperties()); + } + public function testSetProperty() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertEquals([], $def->getProperties()); + $this->assertSame($def, $def->setProperty('foo', 'bar')); + $this->assertEquals(['foo' => 'bar'], $def->getProperties()); + } + public function testAutowired() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertFalse($def->isAutowired()); + $def->setAutowired(\true); + $this->assertTrue($def->isAutowired()); + $def->setAutowired(\false); + $this->assertFalse($def->isAutowired()); + } + public function testChangesNoChanges() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $this->assertSame([], $def->getChanges()); + } + public function testGetChangesWithChanges() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass', ['fooarg']); + $def->setAbstract(\true); + $def->setAutowired(\true); + $def->setConfigurator('configuration_func'); + $def->setDecoratedService(null); + $def->setDeprecated(\true); + $def->setFactory('factory_func'); + $def->setFile('foo.php'); + $def->setLazy(\true); + $def->setPublic(\true); + $def->setShared(\true); + $def->setSynthetic(\true); + // changes aren't tracked for these, class or arguments + $def->setInstanceofConditionals([]); + $def->addTag('foo_tag'); + $def->addMethodCall('methodCall'); + $def->setProperty('fooprop', \true); + $def->setAutoconfigured(\true); + $this->assertSame(['class' => \true, 'autowired' => \true, 'configurator' => \true, 'decorated_service' => \true, 'deprecated' => \true, 'factory' => \true, 'file' => \true, 'lazy' => \true, 'public' => \true, 'shared' => \true, 'autoconfigured' => \true], $def->getChanges()); + $def->setChanges([]); + $this->assertSame([], $def->getChanges()); + } + /** + * @group legacy + */ + public function testTypes() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertEquals([], $def->getAutowiringTypes()); + $this->assertSame($def, $def->setAutowiringTypes(['Foo'])); + $this->assertEquals(['Foo'], $def->getAutowiringTypes()); + $this->assertSame($def, $def->addAutowiringType('Bar')); + $this->assertTrue($def->hasAutowiringType('Bar')); + $this->assertSame($def, $def->removeAutowiringType('Foo')); + $this->assertEquals(['Bar'], $def->getAutowiringTypes()); + } + public function testShouldAutoconfigure() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertFalse($def->isAutoconfigured()); + $def->setAutoconfigured(\true); + $this->assertTrue($def->isAutoconfigured()); + } + public function testAddError() + { + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertEmpty($def->getErrors()); + $def->addError('First error'); + $def->addError('Second error'); + $this->assertSame(['First error', 'Second error'], $def->getErrors()); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Dumper/GraphvizDumperTest.php b/vendor/symfony/dependency-injection/Tests/Dumper/GraphvizDumperTest.php index f1191094d..316caf9c6 100644 --- a/vendor/symfony/dependency-injection/Tests/Dumper/GraphvizDumperTest.php +++ b/vendor/symfony/dependency-injection/Tests/Dumper/GraphvizDumperTest.php @@ -1,65 +1,65 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class GraphvizDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected static $fixturesPath; - public static function setUpBeforeClass() - { - self::$fixturesPath = __DIR__ . '/../Fixtures/'; - } - public function testDump() - { - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); - $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services1.dot', $dumper->dump(), '->dump() dumps an empty container as an empty dot file'); - $container = (include self::$fixturesPath . '/containers/container9.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services9.dot', $dumper->dump(), '->dump() dumps services'); - $container = (include self::$fixturesPath . '/containers/container10.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services10.dot', $dumper->dump(), '->dump() dumps services'); - $container = (include self::$fixturesPath . '/containers/container10.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); - $this->assertEquals($dumper->dump(['graph' => ['ratio' => 'normal'], 'node' => ['fontsize' => 13, 'fontname' => 'Verdana', 'shape' => 'square'], 'edge' => ['fontsize' => 12, 'fontname' => 'Verdana', 'color' => 'white', 'arrowhead' => 'closed', 'arrowsize' => 1], 'node.instance' => ['fillcolor' => 'green', 'style' => 'empty'], 'node.definition' => ['fillcolor' => 'grey'], 'node.missing' => ['fillcolor' => 'red', 'style' => 'empty']]), \file_get_contents(self::$fixturesPath . '/graphviz/services10-1.dot'), '->dump() dumps services'); - } - public function testDumpWithFrozenContainer() - { - $container = (include self::$fixturesPath . '/containers/container13.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services13.dot', $dumper->dump(), '->dump() dumps services'); - } - public function testDumpWithFrozenCustomClassContainer() - { - $container = (include self::$fixturesPath . '/containers/container14.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services14.dot', $dumper->dump(), '->dump() dumps services'); - } - public function testDumpWithUnresolvedParameter() - { - $container = (include self::$fixturesPath . '/containers/container17.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services17.dot', $dumper->dump(), '->dump() dumps services'); - } - public function testDumpWithInlineDefinition() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->addArgument((new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))); - $container->register('bar', 'stdClass'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services_inline.dot', $dumper->dump(), '->dump() dumps nested references'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class GraphvizDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected static $fixturesPath; + public static function setUpBeforeClass() + { + self::$fixturesPath = __DIR__ . '/../Fixtures/'; + } + public function testDump() + { + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); + $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services1.dot', $dumper->dump(), '->dump() dumps an empty container as an empty dot file'); + $container = (include self::$fixturesPath . '/containers/container9.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services9.dot', $dumper->dump(), '->dump() dumps services'); + $container = (include self::$fixturesPath . '/containers/container10.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services10.dot', $dumper->dump(), '->dump() dumps services'); + $container = (include self::$fixturesPath . '/containers/container10.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); + $this->assertEquals($dumper->dump(['graph' => ['ratio' => 'normal'], 'node' => ['fontsize' => 13, 'fontname' => 'Verdana', 'shape' => 'square'], 'edge' => ['fontsize' => 12, 'fontname' => 'Verdana', 'color' => 'white', 'arrowhead' => 'closed', 'arrowsize' => 1], 'node.instance' => ['fillcolor' => 'green', 'style' => 'empty'], 'node.definition' => ['fillcolor' => 'grey'], 'node.missing' => ['fillcolor' => 'red', 'style' => 'empty']]), \file_get_contents(self::$fixturesPath . '/graphviz/services10-1.dot'), '->dump() dumps services'); + } + public function testDumpWithFrozenContainer() + { + $container = (include self::$fixturesPath . '/containers/container13.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services13.dot', $dumper->dump(), '->dump() dumps services'); + } + public function testDumpWithFrozenCustomClassContainer() + { + $container = (include self::$fixturesPath . '/containers/container14.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services14.dot', $dumper->dump(), '->dump() dumps services'); + } + public function testDumpWithUnresolvedParameter() + { + $container = (include self::$fixturesPath . '/containers/container17.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services17.dot', $dumper->dump(), '->dump() dumps services'); + } + public function testDumpWithInlineDefinition() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->addArgument((new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))); + $container->register('bar', 'stdClass'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\GraphvizDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/graphviz/services_inline.dot', $dumper->dump(), '->dump() dumps nested references'); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Dumper/PhpDumperTest.php b/vendor/symfony/dependency-injection/Tests/Dumper/PhpDumperTest.php index 8810a6dee..3cbe50806 100644 --- a/vendor/symfony/dependency-injection/Tests/Dumper/PhpDumperTest.php +++ b/vendor/symfony/dependency-injection/Tests/Dumper/PhpDumperTest.php @@ -1,849 +1,849 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface as SymfonyContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ScalarFactory; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -require_once __DIR__ . '/../Fixtures/includes/classes.php'; -class PhpDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected static $fixturesPath; - public static function setUpBeforeClass() - { - self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); - } - public function testDump() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services1.php', $dumper->dump(), '->dump() dumps an empty container as an empty PHP class'); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services1-1.php', $dumper->dump(['class' => 'Container', 'base_class' => 'AbstractContainer', 'namespace' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dump']), '->dump() takes a class and a base_class options'); - } - public function testDumpOptimizationString() - { - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $definition->setClass('stdClass'); - $definition->addArgument(['only dot' => '.', 'concatenation as value' => '.\'\'.', 'concatenation from the start value' => '\'\'.', '.' => 'dot as a key', '.\'\'.' => 'concatenation as a key', '\'\'.' => 'concatenation from the start key', 'optimize concatenation' => 'string1%some_string%string2', 'optimize concatenation with empty string' => 'string1%empty_value%string2', 'optimize concatenation from the start' => '%empty_value%start', 'optimize concatenation at the end' => 'end%empty_value%', 'new line' => "string with \nnew line"]); - $definition->setPublic(\true); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setResourceTracking(\false); - $container->setDefinition('test', $definition); - $container->setParameter('empty_value', ''); - $container->setParameter('some_string', '-'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services10.php', $dumper->dump(), '->dump() dumps an empty container as an empty PHP class'); - } - public function testDumpRelativeDir() - { - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $definition->setClass('stdClass'); - $definition->addArgument('%foo%'); - $definition->addArgument(['%foo%' => '%buz%/']); - $definition->setPublic(\true); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setDefinition('test', $definition); - $container->setParameter('foo', 'wiz' . \dirname(__DIR__)); - $container->setParameter('bar', __DIR__); - $container->setParameter('baz', '%bar%/PhpDumperTest.php'); - $container->setParameter('buz', \dirname(\dirname(__DIR__))); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services12.php', $dumper->dump(['file' => __FILE__]), '->dump() dumps __DIR__ relative strings'); - } - public function testDumpCustomContainerClassWithoutConstructor() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/custom_container_class_without_constructor.php', $dumper->dump(['base_class' => 'NoConstructorContainer', 'namespace' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Container'])); - } - public function testDumpCustomContainerClassConstructorWithoutArguments() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/custom_container_class_constructor_without_arguments.php', $dumper->dump(['base_class' => 'ConstructorWithoutArgumentsContainer', 'namespace' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Container'])); - } - public function testDumpCustomContainerClassWithOptionalArgumentLessConstructor() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/custom_container_class_with_optional_constructor_arguments.php', $dumper->dump(['base_class' => 'ConstructorWithOptionalArgumentsContainer', 'namespace' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Container'])); - } - public function testDumpCustomContainerClassWithMandatoryArgumentLessConstructor() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/custom_container_class_with_mandatory_constructor_arguments.php', $dumper->dump(['base_class' => 'ConstructorWithMandatoryArgumentsContainer', 'namespace' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Container'])); - } - /** - * @dataProvider provideInvalidParameters - */ - public function testExportParameters($parameters) - { - $this->expectException('InvalidArgumentException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($parameters)); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dumper->dump(); - } - public function provideInvalidParameters() - { - return [[['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass')]], [['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')]], [['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]], [['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable('foo')]]]; - } - public function testAddParameters() - { - $container = (include self::$fixturesPath . '/containers/container8.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services8.php', $dumper->dump(), '->dump() dumps parameters'); - } - /** - * @group legacy - * @expectedDeprecation Dumping an uncompiled ContainerBuilder is deprecated since Symfony 3.3 and will not be supported anymore in 4.0. Compile the container beforehand. - */ - public function testAddServiceWithoutCompilation() - { - $container = (include self::$fixturesPath . '/containers/container9.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services9.php', \str_replace(\str_replace('\\', '\\\\', self::$fixturesPath . \DIRECTORY_SEPARATOR . 'includes' . \DIRECTORY_SEPARATOR), '%path%', $dumper->dump()), '->dump() dumps services'); - } - public function testAddService() - { - $container = (include self::$fixturesPath . '/containers/container9.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services9_compiled.php', \str_replace(\str_replace('\\', '\\\\', self::$fixturesPath . \DIRECTORY_SEPARATOR . 'includes' . \DIRECTORY_SEPARATOR), '%path%', $dumper->dump()), '->dump() dumps services'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'FooClass')->addArgument(new \stdClass())->setPublic(\true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - try { - $dumper->dump(); - $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } - } - public function testDumpAsFiles() - { - $container = (include self::$fixturesPath . '/containers/container9.php'); - $container->getDefinition('bar')->addTag('hot'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dump = \print_r($dumper->dump(['as_files' => \true, 'file' => __DIR__, 'hot_path_tag' => 'hot']), \true); - if ('\\' === \DIRECTORY_SEPARATOR) { - $dump = \str_replace('\\\\Fixtures\\\\includes\\\\foo.php', '/Fixtures/includes/foo.php', $dump); - } - $this->assertStringMatchesFormatFile(self::$fixturesPath . '/php/services9_as_files.txt', $dump); - } - public function testServicesWithAnonymousFactories() - { - $container = (include self::$fixturesPath . '/containers/container19.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services19.php', $dumper->dump(), '->dump() dumps services with anonymous factories'); - } - public function testAddServiceIdWithUnsupportedCharacters() - { - $class = 'Symfony_DI_PhpDumper_Test_Unsupported_Characters'; - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter("'", 'oh-no'); - $container->register('foo*/oh-no', 'FooClass')->setPublic(\true); - $container->register('bar$', 'FooClass')->setPublic(\true); - $container->register('bar$!', 'FooClass')->setPublic(\true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_unsupported_characters.php', $dumper->dump(['class' => $class])); - require_once self::$fixturesPath . '/php/services_unsupported_characters.php'; - $this->assertTrue(\method_exists($class, 'getFooOhNoService')); - $this->assertTrue(\method_exists($class, 'getBarService')); - $this->assertTrue(\method_exists($class, 'getBar2Service')); - } - public function testConflictingServiceIds() - { - $class = 'Symfony_DI_PhpDumper_Test_Conflicting_Service_Ids'; - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo_bar', 'FooClass')->setPublic(\true); - $container->register('foobar', 'FooClass')->setPublic(\true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => $class])); - $this->assertTrue(\method_exists($class, 'getFooBarService')); - $this->assertTrue(\method_exists($class, 'getFoobar2Service')); - } - public function testConflictingMethodsWithParent() - { - $class = 'Symfony_DI_PhpDumper_Test_Conflicting_Method_With_Parent'; - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('bar', 'FooClass')->setPublic(\true); - $container->register('foo_bar', 'FooClass')->setPublic(\true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => $class, 'base_class' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\containers\\CustomContainer'])); - $this->assertTrue(\method_exists($class, 'getBar2Service')); - $this->assertTrue(\method_exists($class, 'getFoobar2Service')); - } - /** - * @dataProvider provideInvalidFactories - */ - public function testInvalidFactories($factory) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Cannot dump definition'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $def->setPublic(\true); - $def->setFactory($factory); - $container->setDefinition('bar', $def); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dumper->dump(); - } - public function provideInvalidFactories() - { - return [[['', 'method']], [['class', '']], [['...', 'method']], [['class', '...']]]; - } - public function testAliases() - { - $container = (include self::$fixturesPath . '/containers/container9.php'); - $container->setParameter('foo_bar', 'foo_bar'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Aliases'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Aliases(); - $foo = $container->get('foo'); - $this->assertSame($foo, $container->get('alias_for_foo')); - $this->assertSame($foo, $container->get('alias_for_alias')); - } - public function testFrozenContainerWithoutAliases() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Frozen_No_Aliases'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Frozen_No_Aliases(); - $this->assertFalse($container->has('foo')); - } - /** - * @group legacy - * @expectedDeprecation The "decorator_service" service is already initialized, replacing it is deprecated since Symfony 3.3 and will fail in 4.0. - */ - public function testOverrideServiceWhenUsingADumpedContainer() - { - require_once self::$fixturesPath . '/php/services9_compiled.php'; - $container = new \_PhpScoper5ea00cc67502b\ProjectServiceContainer(); - $container->get('decorator_service'); - $container->set('decorator_service', $decorator = new \stdClass()); - $this->assertSame($decorator, $container->get('decorator_service'), '->set() overrides an already defined service'); - } - public function testDumpAutowireData() - { - $container = (include self::$fixturesPath . '/containers/container24.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services24.php', $dumper->dump()); - } - public function testEnvInId() - { - $container = (include self::$fixturesPath . '/containers/container_env_in_id.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_env_in_id.php', $dumper->dump()); - } - public function testEnvParameter() - { - $rand = \mt_rand(); - \putenv('Baz=' . $rand); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services26.yml'); - $container->setParameter('env(json_file)', self::$fixturesPath . '/array.json'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services26.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_EnvParameters', 'file' => self::$fixturesPath . '/php/services26.php'])); - require self::$fixturesPath . '/php/services26.php'; - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_EnvParameters(); - $this->assertSame($rand, $container->getParameter('baz')); - $this->assertSame([123, 'abc'], $container->getParameter('json')); - $this->assertSame('sqlite:///foo/bar/var/data.db', $container->getParameter('db_dsn')); - \putenv('Baz'); - } - public function testResolvedBase64EnvParameters() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('env(foo)', \base64_encode('world')); - $container->setParameter('hello', '%env(base64:foo)%'); - $container->compile(\true); - $expected = ['env(foo)' => 'd29ybGQ=', 'hello' => 'world']; - $this->assertSame($expected, $container->getParameterBag()->all()); - } - public function testDumpedBase64EnvParameters() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('env(foo)', \base64_encode('world')); - $container->setParameter('hello', '%env(base64:foo)%'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dumper->dump(); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_base64_env.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Base64Parameters'])); - require self::$fixturesPath . '/php/services_base64_env.php'; - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Base64Parameters(); - $this->assertSame('world', $container->getParameter('hello')); - } - public function testCustomEnvParameters() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('env(foo)', \str_rot13('world')); - $container->setParameter('hello', '%env(rot13:foo)%'); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\Rot13EnvVarProcessor::class)->addTag('container.env_var_processor')->setPublic(\true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dumper->dump(); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_rot13_env.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Rot13Parameters'])); - require self::$fixturesPath . '/php/services_rot13_env.php'; - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Rot13Parameters(); - $this->assertSame('world', $container->getParameter('hello')); - } - public function testFileEnvProcessor() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('env(foo)', __FILE__); - $container->setParameter('random', '%env(file:foo)%'); - $container->compile(\true); - $this->assertStringEqualsFile(__FILE__, $container->getParameter('random')); - } - public function testUnusedEnvParameter() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvParameterException'); - $this->expectExceptionMessage('Environment variables "FOO" are never used. Please, check your container\'s configuration.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->getParameter('env(FOO)'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dumper->dump(); - } - public function testCircularDynamicEnv() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterCircularReferenceException'); - $this->expectExceptionMessage('Circular reference detected for parameter "env(resolve:DUMMY_ENV_VAR)" ("env(resolve:DUMMY_ENV_VAR)" > "env(resolve:DUMMY_ENV_VAR)").'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('foo', '%bar%'); - $container->setParameter('bar', '%env(resolve:DUMMY_ENV_VAR)%'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dump = $dumper->dump(['class' => $class = __FUNCTION__]); - eval('?>' . $dump); - $container = new $class(); - \putenv('DUMMY_ENV_VAR=%foo%'); - try { - $container->getParameter('bar'); - } finally { - \putenv('DUMMY_ENV_VAR'); - } - } - public function testInlinedDefinitionReferencingServiceContainer() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->addMethodCall('add', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')])->setPublic(\false); - $container->register('bar', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))->setPublic(\true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services13.php', $dumper->dump(), '->dump() dumps inline definitions which reference service_container'); - } - public function testNonSharedLazyDefinitionReferences() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setShared(\false)->setLazy(\true); - $container->register('bar', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::EXCEPTION_ON_INVALID_REFERENCE, \false)); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dumper->setProxyDumper(new \_PhpScoper5ea00cc67502b\DummyProxyDumper()); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_non_shared_lazy.php', $dumper->dump()); - } - public function testInitializePropertiesBeforeMethodCalls() - { - require_once self::$fixturesPath . '/includes/classes.php'; - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setPublic(\true); - $container->register('bar', 'MethodCallClass')->setPublic(\true)->setProperty('simple', 'bar')->setProperty('complex', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))->addMethodCall('callMe'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Properties_Before_Method_Calls'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Properties_Before_Method_Calls(); - $this->assertTrue($container->get('bar')->callPassed(), '->dump() initializes properties before method calls'); - } - public function testCircularReferenceAllowanceForLazyServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))->setPublic(\true); - $container->register('bar', 'stdClass')->setLazy(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))->setPublic(\true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dumper->setProxyDumper(new \_PhpScoper5ea00cc67502b\DummyProxyDumper()); - $dumper->dump(); - $this->addToAssertionCount(1); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $message = 'Circular reference detected for service "foo", path: "foo -> bar -> foo". Try running "composer require symfony/proxy-manager-bridge".'; - $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException::class); - $this->expectExceptionMessage($message); - $dumper->dump(); - } - public function testDedupLazyProxy() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setLazy(\true)->setPublic(\true); - $container->register('bar', 'stdClass')->setLazy(\true)->setPublic(\true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dumper->setProxyDumper(new \_PhpScoper5ea00cc67502b\DummyProxyDumper()); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_dedup_lazy_proxy.php', $dumper->dump()); - } - public function testLazyArgumentProvideGenerator() - { - require_once self::$fixturesPath . '/includes/classes.php'; - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('lazy_referenced', 'stdClass')->setPublic(\true); - $container->register('lazy_context', 'LazyContext')->setPublic(\true)->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['k1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('lazy_referenced'), 'k2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])]); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Lazy_Argument_Provide_Generator'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Lazy_Argument_Provide_Generator(); - $lazyContext = $container->get('lazy_context'); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator::class, $lazyContext->lazyValues); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator::class, $lazyContext->lazyEmptyValues); - $this->assertCount(2, $lazyContext->lazyValues); - $this->assertCount(0, $lazyContext->lazyEmptyValues); - $i = -1; - foreach ($lazyContext->lazyValues as $k => $v) { - switch (++$i) { - case 0: - $this->assertEquals('k1', $k); - $this->assertInstanceOf('stdCLass', $v); - break; - case 1: - $this->assertEquals('k2', $k); - $this->assertInstanceOf('Symfony_DI_PhpDumper_Test_Lazy_Argument_Provide_Generator', $v); - break; - } - } - $this->assertEmpty(\iterator_to_array($lazyContext->lazyEmptyValues)); - } - public function testNormalizedId() - { - $container = (include self::$fixturesPath . '/containers/container33.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services33.php', $dumper->dump()); - } - public function testDumpContainerBuilderWithFrozenConstructorIncludingPrivateServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo_service', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz_service')])->setPublic(\true); - $container->register('bar_service', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz_service')])->setPublic(\true); - $container->register('baz_service', 'stdClass')->setPublic(\false); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_private_frozen.php', $dumper->dump()); - } - public function testServiceLocator() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\true)->addArgument(['bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar_service')), 'baz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference('baz_service', 'stdClass')), 'nil' => $nil = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('nil'))]); - // no method calls - $container->register('translator.loader_1', 'stdClass')->setPublic(\true); - $container->register('translator.loader_1_locator', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\false)->addArgument(['translator.loader_1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_1'))]); - $container->register('translator_1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator::class)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_1_locator')); - // one method calls - $container->register('translator.loader_2', 'stdClass')->setPublic(\true); - $container->register('translator.loader_2_locator', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\false)->addArgument(['translator.loader_2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_2'))]); - $container->register('translator_2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator::class)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_2_locator'))->addMethodCall('addResource', ['db', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_2'), 'nl']); - // two method calls - $container->register('translator.loader_3', 'stdClass')->setPublic(\true); - $container->register('translator.loader_3_locator', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\false)->addArgument(['translator.loader_3' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_3'))]); - $container->register('translator_3', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator::class)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_3_locator'))->addMethodCall('addResource', ['db', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_3'), 'nl'])->addMethodCall('addResource', ['db', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_3'), 'en']); - $nil->setValues([null]); - $container->register('bar_service', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz_service')])->setPublic(\true); - $container->register('baz_service', 'stdClass')->setPublic(\false); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_locator.php', $dumper->dump()); - } - public function testServiceSubscriber() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->setPublic(\true)->setAutowired(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class))->addTag('container.service_subscriber', ['key' => 'bar', 'id' => \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class]); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->setPublic(\true); - $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class)->setPublic(\false); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_subscriber.php', $dumper->dump()); - } - public function testPrivateWithIgnoreOnInvalidReference() - { - require_once self::$fixturesPath . '/includes/classes.php'; - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('not_invalid', 'BazClass')->setPublic(\false); - $container->register('bar', 'BarClass')->setPublic(\true)->addMethodCall('setBaz', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('not_invalid', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)]); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Private_With_Ignore_On_Invalid_Reference'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Private_With_Ignore_On_Invalid_Reference(); - $this->assertInstanceOf('BazClass', $container->get('bar')->getBaz()); - } - public function testArrayParameters() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('array_1', [123]); - $container->setParameter('array_2', [__DIR__]); - $container->register('bar', 'BarClass')->setPublic(\true)->addMethodCall('setBaz', ['%array_1%', '%array_2%', '%%array_1%%', [123]]); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_array_params.php', \str_replace('\\\\Dumper', '/Dumper', $dumper->dump(['file' => self::$fixturesPath . '/php/services_array_params.php']))); - } - public function testExpressionReferencingPrivateService() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('private_bar', 'stdClass')->setPublic(\false); - $container->register('private_foo', 'stdClass')->setPublic(\false); - $container->register('public_foo', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("private_foo").bar')); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_private_in_expression.php', $dumper->dump()); - } - public function testUninitializedReference() - { - $container = (include self::$fixturesPath . '/containers/container_uninitialized_ref.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_uninitialized_ref.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Uninitialized_Reference'])); - require self::$fixturesPath . '/php/services_uninitialized_ref.php'; - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Uninitialized_Reference(); - $bar = $container->get('bar'); - $this->assertNull($bar->foo1); - $this->assertNull($bar->foo2); - $this->assertNull($bar->foo3); - $this->assertNull($bar->closures[0]()); - $this->assertNull($bar->closures[1]()); - $this->assertNull($bar->closures[2]()); - $this->assertSame([], \iterator_to_array($bar->iter)); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Uninitialized_Reference(); - $container->get('foo1'); - $container->get('baz'); - $bar = $container->get('bar'); - $this->assertEquals(new \stdClass(), $bar->foo1); - $this->assertNull($bar->foo2); - $this->assertEquals(new \stdClass(), $bar->foo3); - $this->assertEquals(new \stdClass(), $bar->closures[0]()); - $this->assertNull($bar->closures[1]()); - $this->assertEquals(new \stdClass(), $bar->closures[2]()); - $this->assertEquals(['foo1' => new \stdClass(), 'foo3' => new \stdClass()], \iterator_to_array($bar->iter)); - } - /** - * @dataProvider provideAlmostCircular - */ - public function testAlmostCircular($visibility) - { - $container = (include self::$fixturesPath . '/containers/container_almost_circular.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $container = 'Symfony_DI_PhpDumper_Test_Almost_Circular_' . \ucfirst($visibility); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_almost_circular_' . $visibility . '.php', $dumper->dump(['class' => $container])); - require self::$fixturesPath . '/php/services_almost_circular_' . $visibility . '.php'; - $container = new $container(); - $foo = $container->get('foo'); - $this->assertSame($foo, $foo->bar->foobar->foo); - $foo2 = $container->get('foo2'); - $this->assertSame($foo2, $foo2->bar->foobar->foo); - $this->assertSame([], (array) $container->get('foobar4')); - $foo5 = $container->get('foo5'); - $this->assertSame($foo5, $foo5->bar->foo); - $manager = $container->get('manager'); - $this->assertEquals(new \stdClass(), $manager); - $manager = $container->get('manager2'); - $this->assertEquals(new \stdClass(), $manager); - $foo6 = $container->get('foo6'); - $this->assertEquals((object) ['bar6' => (object) []], $foo6); - $this->assertInstanceOf(\stdClass::class, $container->get('root')); - $manager3 = $container->get('manager3'); - $listener3 = $container->get('listener3'); - $this->assertSame($manager3, $listener3->manager); - $listener4 = $container->get('listener4'); - $this->assertInstanceOf('stdClass', $listener4); - } - public function provideAlmostCircular() - { - (yield ['public']); - (yield ['private']); - } - public function testDeepServiceGraph() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_deep_graph.yml'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dumper->dump(); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_deep_graph.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Deep_Graph'])); - require self::$fixturesPath . '/php/services_deep_graph.php'; - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Deep_Graph(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\FooForDeepGraph::class, $container->get('foo')); - $this->assertEquals((object) ['p2' => (object) ['p3' => (object) []]], $container->get('foo')->bClone); - } - public function testInlineSelfRef() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $bar = (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\App\\Bar'))->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('_PhpScoper5ea00cc67502b\\App\\Foo')); - $baz = (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\App\\Baz'))->setProperty('bar', $bar)->addArgument($bar); - $container->register('_PhpScoper5ea00cc67502b\\App\\Foo')->setPublic(\true)->addArgument($baz); - $container->getCompiler()->getPassConfig(); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_inline_self_ref.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Inline_Self_Ref'])); - } - public function testHotPathOptimizations() - { - $container = (include self::$fixturesPath . '/containers/container_inline_requires.php'); - $container->setParameter('inline_requires', \true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dump = $dumper->dump(['hot_path_tag' => 'container.hot_path', 'inline_class_loader_parameter' => 'inline_requires', 'file' => self::$fixturesPath . '/php/services_inline_requires.php']); - if ('\\' === \DIRECTORY_SEPARATOR) { - $dump = \str_replace("'\\\\includes\\\\HotPath\\\\", "'/includes/HotPath/", $dump); - } - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_inline_requires.php', $dump); - } - public function testDumpHandlesLiteralClassWithRootNamespace() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', '\\stdClass')->setPublic(\true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Literal_Class_With_Root_Namespace'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Literal_Class_With_Root_Namespace(); - $this->assertInstanceOf('stdClass', $container->get('foo')); - } - public function testDumpHandlesObjectClassNames() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['class' => 'stdClass'])); - $container->setDefinition('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter('class'))); - $container->setDefinition('bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]))->setPublic(\true); - $container->setParameter('inline_requires', \true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Object_Class_Name', 'inline_class_loader_parameter' => 'inline_requires'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Object_Class_Name(); - $this->assertInstanceOf('stdClass', $container->get('bar')); - } - public function testUninitializedSyntheticReference() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setPublic(\true)->setSynthetic(\true); - $container->register('bar', 'stdClass')->setPublic(\true)->setShared(\false)->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::IGNORE_ON_UNINITIALIZED_REFERENCE)); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_UninitializedSyntheticReference', 'inline_class_loader_parameter' => 'inline_requires'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_UninitializedSyntheticReference(); - $this->assertEquals((object) ['foo' => null], $container->get('bar')); - $container->set('foo', (object) [123]); - $this->assertEquals((object) ['foo' => (object) [123]], $container->get('bar')); - } - public function testAdawsonContainer() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_adawson.yml'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_adawson.php', $dumper->dump()); - } - /** - * @group legacy - * @expectedDeprecation The "private" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. - * @expectedDeprecation The "private_alias" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. - * @expectedDeprecation The "decorated_private" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. - * @expectedDeprecation The "decorated_private_alias" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. - * @expectedDeprecation The "private_not_inlined" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. - * @expectedDeprecation The "private_not_removed" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. - * @expectedDeprecation The "private_child" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. - * @expectedDeprecation The "private_parent" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. - */ - public function testLegacyPrivateServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_legacy_privates.yml'); - $container->setDefinition('private_child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo')); - $container->setDefinition('private_parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('private')); - $container->getDefinition('private')->setPrivate(\true); - $container->getDefinition('private_not_inlined')->setPrivate(\true); - $container->getDefinition('private_not_removed')->setPrivate(\true); - $container->getDefinition('decorated_private')->setPrivate(\true); - $container->getDefinition('private_child')->setPrivate(\true); - $container->getAlias('decorated_private_alias')->setPrivate(\true); - $container->getAlias('private_alias')->setPrivate(\true); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_legacy_privates.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Legacy_Privates', 'file' => self::$fixturesPath . '/php/services_legacy_privates.php'])); - require self::$fixturesPath . '/php/services_legacy_privates.php'; - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Legacy_Privates(); - $container->get('private'); - $container->get('private_alias'); - $container->get('alias_to_private'); - $container->get('decorated_private'); - $container->get('decorated_private_alias'); - $container->get('private_not_inlined'); - $container->get('private_not_removed'); - $container->get('private_child'); - $container->get('private_parent'); - $container->get('public_child'); - } - /** - * This test checks the trigger of a deprecation note and should not be removed in major releases. - * - * @group legacy - * @expectedDeprecation The "foo" service is deprecated. You should stop using it, as it will soon be removed. - */ - public function testPrivateServiceTriggersDeprecation() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setPublic(\false)->setDeprecated(\true); - $container->register('bar', 'stdClass')->setPublic(\true)->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Private_Service_Triggers_Deprecation'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Private_Service_Triggers_Deprecation(); - $container->get('bar'); - } - /** - * @group legacy - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "foo" instead of "Foo" is deprecated since Symfony 3.4. - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "FOO" instead of "Foo" is deprecated since Symfony 3.4. - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "bar" instead of "BAR" is deprecated since Symfony 3.4. - */ - public function testParameterWithMixedCase() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['Foo' => 'bar', 'BAR' => 'foo'])); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Parameter_With_Mixed_Case'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Parameter_With_Mixed_Case(); - $this->assertSame('bar', $container->getParameter('foo')); - $this->assertSame('bar', $container->getParameter('FOO')); - $this->assertSame('foo', $container->getParameter('bar')); - $this->assertSame('foo', $container->getParameter('BAR')); - } - /** - * @group legacy - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "FOO" instead of "foo" is deprecated since Symfony 3.4. - */ - public function testParameterWithLowerCase() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Parameter_With_Lower_Case'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Parameter_With_Lower_Case(); - $this->assertSame('bar', $container->getParameter('FOO')); - } - /** - * @group legacy - * @expectedDeprecation Service identifiers will be made case sensitive in Symfony 4.0. Using "foo" instead of "Foo" is deprecated since Symfony 3.3. - * @expectedDeprecation The "Foo" service is deprecated. You should stop using it, as it will soon be removed. - */ - public function testReferenceWithLowerCaseId() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('Bar', 'stdClass')->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))->setPublic(\true); - $container->register('Foo', 'stdClass')->setDeprecated(); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Reference_With_Lower_Case_Id'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Reference_With_Lower_Case_Id(); - $this->assertEquals((object) ['foo' => (object) []], $container->get('Bar')); - } - public function testScalarService() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'string')->setPublic(\true)->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ScalarFactory::class, 'getSomeValue']); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Scalar_Service'])); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Scalar_Service(); - $this->assertTrue($container->has('foo')); - $this->assertSame('some value', $container->get('foo')); - } - public function testAliasCanBeFoundInTheDumpedContainerWhenBothTheAliasAndTheServiceArePublic() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'stdClass')->setPublic(\true); - $container->setAlias('bar', 'foo')->setPublic(\true); - $container->compile(); - // Bar is found in the compiled container - $service_ids = $container->getServiceIds(); - $this->assertContains('bar', $service_ids); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $dump = $dumper->dump(['class' => 'Symfony_DI_PhpDumper_AliasesCanBeFoundInTheDumpedContainer']); - eval('?>' . $dump); - $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_AliasesCanBeFoundInTheDumpedContainer(); - // Bar should still be found in the compiled container - $service_ids = $container->getServiceIds(); - $this->assertContains('bar', $service_ids); - } -} -class Rot13EnvVarProcessor implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface -{ - public function getEnv($prefix, $name, \Closure $getEnv) - { - return \str_rot13($getEnv($name)); - } - public static function getProvidedTypes() - { - return ['rot13' => 'string']; - } -} -class FooForDeepGraph -{ - public $bClone; - public function __construct(\stdClass $a, \stdClass $b) - { - // clone to verify that $b has been fully initialized before - $this->bClone = clone $b; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface as SymfonyContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ScalarFactory; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +require_once __DIR__ . '/../Fixtures/includes/classes.php'; +class PhpDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected static $fixturesPath; + public static function setUpBeforeClass() + { + self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); + } + public function testDump() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services1.php', $dumper->dump(), '->dump() dumps an empty container as an empty PHP class'); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services1-1.php', $dumper->dump(['class' => 'Container', 'base_class' => 'AbstractContainer', 'namespace' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Dump']), '->dump() takes a class and a base_class options'); + } + public function testDumpOptimizationString() + { + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $definition->setClass('stdClass'); + $definition->addArgument(['only dot' => '.', 'concatenation as value' => '.\'\'.', 'concatenation from the start value' => '\'\'.', '.' => 'dot as a key', '.\'\'.' => 'concatenation as a key', '\'\'.' => 'concatenation from the start key', 'optimize concatenation' => 'string1%some_string%string2', 'optimize concatenation with empty string' => 'string1%empty_value%string2', 'optimize concatenation from the start' => '%empty_value%start', 'optimize concatenation at the end' => 'end%empty_value%', 'new line' => "string with \nnew line"]); + $definition->setPublic(\true); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setResourceTracking(\false); + $container->setDefinition('test', $definition); + $container->setParameter('empty_value', ''); + $container->setParameter('some_string', '-'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services10.php', $dumper->dump(), '->dump() dumps an empty container as an empty PHP class'); + } + public function testDumpRelativeDir() + { + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $definition->setClass('stdClass'); + $definition->addArgument('%foo%'); + $definition->addArgument(['%foo%' => '%buz%/']); + $definition->setPublic(\true); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setDefinition('test', $definition); + $container->setParameter('foo', 'wiz' . \dirname(__DIR__)); + $container->setParameter('bar', __DIR__); + $container->setParameter('baz', '%bar%/PhpDumperTest.php'); + $container->setParameter('buz', \dirname(\dirname(__DIR__))); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services12.php', $dumper->dump(['file' => __FILE__]), '->dump() dumps __DIR__ relative strings'); + } + public function testDumpCustomContainerClassWithoutConstructor() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/custom_container_class_without_constructor.php', $dumper->dump(['base_class' => 'NoConstructorContainer', 'namespace' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Container'])); + } + public function testDumpCustomContainerClassConstructorWithoutArguments() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/custom_container_class_constructor_without_arguments.php', $dumper->dump(['base_class' => 'ConstructorWithoutArgumentsContainer', 'namespace' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Container'])); + } + public function testDumpCustomContainerClassWithOptionalArgumentLessConstructor() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/custom_container_class_with_optional_constructor_arguments.php', $dumper->dump(['base_class' => 'ConstructorWithOptionalArgumentsContainer', 'namespace' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Container'])); + } + public function testDumpCustomContainerClassWithMandatoryArgumentLessConstructor() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/custom_container_class_with_mandatory_constructor_arguments.php', $dumper->dump(['base_class' => 'ConstructorWithMandatoryArgumentsContainer', 'namespace' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Container'])); + } + /** + * @dataProvider provideInvalidParameters + */ + public function testExportParameters($parameters) + { + $this->expectException('InvalidArgumentException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($parameters)); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dumper->dump(); + } + public function provideInvalidParameters() + { + return [[['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass')]], [['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')]], [['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]], [['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Variable('foo')]]]; + } + public function testAddParameters() + { + $container = (include self::$fixturesPath . '/containers/container8.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services8.php', $dumper->dump(), '->dump() dumps parameters'); + } + /** + * @group legacy + * @expectedDeprecation Dumping an uncompiled ContainerBuilder is deprecated since Symfony 3.3 and will not be supported anymore in 4.0. Compile the container beforehand. + */ + public function testAddServiceWithoutCompilation() + { + $container = (include self::$fixturesPath . '/containers/container9.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services9.php', \str_replace(\str_replace('\\', '\\\\', self::$fixturesPath . \DIRECTORY_SEPARATOR . 'includes' . \DIRECTORY_SEPARATOR), '%path%', $dumper->dump()), '->dump() dumps services'); + } + public function testAddService() + { + $container = (include self::$fixturesPath . '/containers/container9.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services9_compiled.php', \str_replace(\str_replace('\\', '\\\\', self::$fixturesPath . \DIRECTORY_SEPARATOR . 'includes' . \DIRECTORY_SEPARATOR), '%path%', $dumper->dump()), '->dump() dumps services'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'FooClass')->addArgument(new \stdClass())->setPublic(\true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + try { + $dumper->dump(); + $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); + $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); + } + } + public function testDumpAsFiles() + { + $container = (include self::$fixturesPath . '/containers/container9.php'); + $container->getDefinition('bar')->addTag('hot'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dump = \print_r($dumper->dump(['as_files' => \true, 'file' => __DIR__, 'hot_path_tag' => 'hot']), \true); + if ('\\' === \DIRECTORY_SEPARATOR) { + $dump = \str_replace('\\\\Fixtures\\\\includes\\\\foo.php', '/Fixtures/includes/foo.php', $dump); + } + $this->assertStringMatchesFormatFile(self::$fixturesPath . '/php/services9_as_files.txt', $dump); + } + public function testServicesWithAnonymousFactories() + { + $container = (include self::$fixturesPath . '/containers/container19.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services19.php', $dumper->dump(), '->dump() dumps services with anonymous factories'); + } + public function testAddServiceIdWithUnsupportedCharacters() + { + $class = 'Symfony_DI_PhpDumper_Test_Unsupported_Characters'; + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter("'", 'oh-no'); + $container->register('foo*/oh-no', 'FooClass')->setPublic(\true); + $container->register('bar$', 'FooClass')->setPublic(\true); + $container->register('bar$!', 'FooClass')->setPublic(\true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_unsupported_characters.php', $dumper->dump(['class' => $class])); + require_once self::$fixturesPath . '/php/services_unsupported_characters.php'; + $this->assertTrue(\method_exists($class, 'getFooOhNoService')); + $this->assertTrue(\method_exists($class, 'getBarService')); + $this->assertTrue(\method_exists($class, 'getBar2Service')); + } + public function testConflictingServiceIds() + { + $class = 'Symfony_DI_PhpDumper_Test_Conflicting_Service_Ids'; + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo_bar', 'FooClass')->setPublic(\true); + $container->register('foobar', 'FooClass')->setPublic(\true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => $class])); + $this->assertTrue(\method_exists($class, 'getFooBarService')); + $this->assertTrue(\method_exists($class, 'getFoobar2Service')); + } + public function testConflictingMethodsWithParent() + { + $class = 'Symfony_DI_PhpDumper_Test_Conflicting_Method_With_Parent'; + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('bar', 'FooClass')->setPublic(\true); + $container->register('foo_bar', 'FooClass')->setPublic(\true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => $class, 'base_class' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\containers\\CustomContainer'])); + $this->assertTrue(\method_exists($class, 'getBar2Service')); + $this->assertTrue(\method_exists($class, 'getFoobar2Service')); + } + /** + * @dataProvider provideInvalidFactories + */ + public function testInvalidFactories($factory) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Cannot dump definition'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $def = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $def->setPublic(\true); + $def->setFactory($factory); + $container->setDefinition('bar', $def); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dumper->dump(); + } + public function provideInvalidFactories() + { + return [[['', 'method']], [['class', '']], [['...', 'method']], [['class', '...']]]; + } + public function testAliases() + { + $container = (include self::$fixturesPath . '/containers/container9.php'); + $container->setParameter('foo_bar', 'foo_bar'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Aliases'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Aliases(); + $foo = $container->get('foo'); + $this->assertSame($foo, $container->get('alias_for_foo')); + $this->assertSame($foo, $container->get('alias_for_alias')); + } + public function testFrozenContainerWithoutAliases() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Frozen_No_Aliases'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Frozen_No_Aliases(); + $this->assertFalse($container->has('foo')); + } + /** + * @group legacy + * @expectedDeprecation The "decorator_service" service is already initialized, replacing it is deprecated since Symfony 3.3 and will fail in 4.0. + */ + public function testOverrideServiceWhenUsingADumpedContainer() + { + require_once self::$fixturesPath . '/php/services9_compiled.php'; + $container = new \_PhpScoper5ea00cc67502b\ProjectServiceContainer(); + $container->get('decorator_service'); + $container->set('decorator_service', $decorator = new \stdClass()); + $this->assertSame($decorator, $container->get('decorator_service'), '->set() overrides an already defined service'); + } + public function testDumpAutowireData() + { + $container = (include self::$fixturesPath . '/containers/container24.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services24.php', $dumper->dump()); + } + public function testEnvInId() + { + $container = (include self::$fixturesPath . '/containers/container_env_in_id.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_env_in_id.php', $dumper->dump()); + } + public function testEnvParameter() + { + $rand = \mt_rand(); + \putenv('Baz=' . $rand); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services26.yml'); + $container->setParameter('env(json_file)', self::$fixturesPath . '/array.json'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services26.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_EnvParameters', 'file' => self::$fixturesPath . '/php/services26.php'])); + require self::$fixturesPath . '/php/services26.php'; + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_EnvParameters(); + $this->assertSame($rand, $container->getParameter('baz')); + $this->assertSame([123, 'abc'], $container->getParameter('json')); + $this->assertSame('sqlite:///foo/bar/var/data.db', $container->getParameter('db_dsn')); + \putenv('Baz'); + } + public function testResolvedBase64EnvParameters() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('env(foo)', \base64_encode('world')); + $container->setParameter('hello', '%env(base64:foo)%'); + $container->compile(\true); + $expected = ['env(foo)' => 'd29ybGQ=', 'hello' => 'world']; + $this->assertSame($expected, $container->getParameterBag()->all()); + } + public function testDumpedBase64EnvParameters() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('env(foo)', \base64_encode('world')); + $container->setParameter('hello', '%env(base64:foo)%'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dumper->dump(); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_base64_env.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Base64Parameters'])); + require self::$fixturesPath . '/php/services_base64_env.php'; + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Base64Parameters(); + $this->assertSame('world', $container->getParameter('hello')); + } + public function testCustomEnvParameters() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('env(foo)', \str_rot13('world')); + $container->setParameter('hello', '%env(rot13:foo)%'); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\Rot13EnvVarProcessor::class)->addTag('container.env_var_processor')->setPublic(\true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dumper->dump(); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_rot13_env.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Rot13Parameters'])); + require self::$fixturesPath . '/php/services_rot13_env.php'; + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Rot13Parameters(); + $this->assertSame('world', $container->getParameter('hello')); + } + public function testFileEnvProcessor() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('env(foo)', __FILE__); + $container->setParameter('random', '%env(file:foo)%'); + $container->compile(\true); + $this->assertStringEqualsFile(__FILE__, $container->getParameter('random')); + } + public function testUnusedEnvParameter() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\EnvParameterException'); + $this->expectExceptionMessage('Environment variables "FOO" are never used. Please, check your container\'s configuration.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->getParameter('env(FOO)'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dumper->dump(); + } + public function testCircularDynamicEnv() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterCircularReferenceException'); + $this->expectExceptionMessage('Circular reference detected for parameter "env(resolve:DUMMY_ENV_VAR)" ("env(resolve:DUMMY_ENV_VAR)" > "env(resolve:DUMMY_ENV_VAR)").'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('foo', '%bar%'); + $container->setParameter('bar', '%env(resolve:DUMMY_ENV_VAR)%'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dump = $dumper->dump(['class' => $class = __FUNCTION__]); + eval('?>' . $dump); + $container = new $class(); + \putenv('DUMMY_ENV_VAR=%foo%'); + try { + $container->getParameter('bar'); + } finally { + \putenv('DUMMY_ENV_VAR'); + } + } + public function testInlinedDefinitionReferencingServiceContainer() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->addMethodCall('add', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')])->setPublic(\false); + $container->register('bar', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))->setPublic(\true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services13.php', $dumper->dump(), '->dump() dumps inline definitions which reference service_container'); + } + public function testNonSharedLazyDefinitionReferences() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setShared(\false)->setLazy(\true); + $container->register('bar', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::EXCEPTION_ON_INVALID_REFERENCE, \false)); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dumper->setProxyDumper(new \_PhpScoper5ea00cc67502b\DummyProxyDumper()); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_non_shared_lazy.php', $dumper->dump()); + } + public function testInitializePropertiesBeforeMethodCalls() + { + require_once self::$fixturesPath . '/includes/classes.php'; + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setPublic(\true); + $container->register('bar', 'MethodCallClass')->setPublic(\true)->setProperty('simple', 'bar')->setProperty('complex', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))->addMethodCall('callMe'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Properties_Before_Method_Calls'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Properties_Before_Method_Calls(); + $this->assertTrue($container->get('bar')->callPassed(), '->dump() initializes properties before method calls'); + } + public function testCircularReferenceAllowanceForLazyServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))->setPublic(\true); + $container->register('bar', 'stdClass')->setLazy(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))->setPublic(\true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dumper->setProxyDumper(new \_PhpScoper5ea00cc67502b\DummyProxyDumper()); + $dumper->dump(); + $this->addToAssertionCount(1); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $message = 'Circular reference detected for service "foo", path: "foo -> bar -> foo". Try running "composer require symfony/proxy-manager-bridge".'; + $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ServiceCircularReferenceException::class); + $this->expectExceptionMessage($message); + $dumper->dump(); + } + public function testDedupLazyProxy() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setLazy(\true)->setPublic(\true); + $container->register('bar', 'stdClass')->setLazy(\true)->setPublic(\true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dumper->setProxyDumper(new \_PhpScoper5ea00cc67502b\DummyProxyDumper()); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_dedup_lazy_proxy.php', $dumper->dump()); + } + public function testLazyArgumentProvideGenerator() + { + require_once self::$fixturesPath . '/includes/classes.php'; + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('lazy_referenced', 'stdClass')->setPublic(\true); + $container->register('lazy_context', 'LazyContext')->setPublic(\true)->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['k1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('lazy_referenced'), 'k2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])]); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Lazy_Argument_Provide_Generator'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Lazy_Argument_Provide_Generator(); + $lazyContext = $container->get('lazy_context'); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator::class, $lazyContext->lazyValues); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator::class, $lazyContext->lazyEmptyValues); + $this->assertCount(2, $lazyContext->lazyValues); + $this->assertCount(0, $lazyContext->lazyEmptyValues); + $i = -1; + foreach ($lazyContext->lazyValues as $k => $v) { + switch (++$i) { + case 0: + $this->assertEquals('k1', $k); + $this->assertInstanceOf('stdCLass', $v); + break; + case 1: + $this->assertEquals('k2', $k); + $this->assertInstanceOf('Symfony_DI_PhpDumper_Test_Lazy_Argument_Provide_Generator', $v); + break; + } + } + $this->assertEmpty(\iterator_to_array($lazyContext->lazyEmptyValues)); + } + public function testNormalizedId() + { + $container = (include self::$fixturesPath . '/containers/container33.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services33.php', $dumper->dump()); + } + public function testDumpContainerBuilderWithFrozenConstructorIncludingPrivateServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo_service', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz_service')])->setPublic(\true); + $container->register('bar_service', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz_service')])->setPublic(\true); + $container->register('baz_service', 'stdClass')->setPublic(\false); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_private_frozen.php', $dumper->dump()); + } + public function testServiceLocator() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\true)->addArgument(['bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar_service')), 'baz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\TypedReference('baz_service', 'stdClass')), 'nil' => $nil = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('nil'))]); + // no method calls + $container->register('translator.loader_1', 'stdClass')->setPublic(\true); + $container->register('translator.loader_1_locator', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\false)->addArgument(['translator.loader_1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_1'))]); + $container->register('translator_1', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator::class)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_1_locator')); + // one method calls + $container->register('translator.loader_2', 'stdClass')->setPublic(\true); + $container->register('translator.loader_2_locator', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\false)->addArgument(['translator.loader_2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_2'))]); + $container->register('translator_2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator::class)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_2_locator'))->addMethodCall('addResource', ['db', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_2'), 'nl']); + // two method calls + $container->register('translator.loader_3', 'stdClass')->setPublic(\true); + $container->register('translator.loader_3_locator', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator::class)->setPublic(\false)->addArgument(['translator.loader_3' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_3'))]); + $container->register('translator_3', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator::class)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_3_locator'))->addMethodCall('addResource', ['db', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_3'), 'nl'])->addMethodCall('addResource', ['db', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('translator.loader_3'), 'en']); + $nil->setValues([null]); + $container->register('bar_service', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz_service')])->setPublic(\true); + $container->register('baz_service', 'stdClass')->setPublic(\false); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_locator.php', $dumper->dump()); + } + public function testServiceSubscriber() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo_service', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->setPublic(\true)->setAutowired(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class))->addTag('container.service_subscriber', ['key' => 'bar', 'id' => \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class]); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber::class)->setPublic(\true); + $container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class)->setPublic(\false); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_subscriber.php', $dumper->dump()); + } + public function testPrivateWithIgnoreOnInvalidReference() + { + require_once self::$fixturesPath . '/includes/classes.php'; + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('not_invalid', 'BazClass')->setPublic(\false); + $container->register('bar', 'BarClass')->setPublic(\true)->addMethodCall('setBaz', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('not_invalid', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)]); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Private_With_Ignore_On_Invalid_Reference'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Private_With_Ignore_On_Invalid_Reference(); + $this->assertInstanceOf('BazClass', $container->get('bar')->getBaz()); + } + public function testArrayParameters() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('array_1', [123]); + $container->setParameter('array_2', [__DIR__]); + $container->register('bar', 'BarClass')->setPublic(\true)->addMethodCall('setBaz', ['%array_1%', '%array_2%', '%%array_1%%', [123]]); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_array_params.php', \str_replace('\\\\Dumper', '/Dumper', $dumper->dump(['file' => self::$fixturesPath . '/php/services_array_params.php']))); + } + public function testExpressionReferencingPrivateService() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('private_bar', 'stdClass')->setPublic(\false); + $container->register('private_foo', 'stdClass')->setPublic(\false); + $container->register('public_foo', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("private_foo").bar')); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_private_in_expression.php', $dumper->dump()); + } + public function testUninitializedReference() + { + $container = (include self::$fixturesPath . '/containers/container_uninitialized_ref.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_uninitialized_ref.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Uninitialized_Reference'])); + require self::$fixturesPath . '/php/services_uninitialized_ref.php'; + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Uninitialized_Reference(); + $bar = $container->get('bar'); + $this->assertNull($bar->foo1); + $this->assertNull($bar->foo2); + $this->assertNull($bar->foo3); + $this->assertNull($bar->closures[0]()); + $this->assertNull($bar->closures[1]()); + $this->assertNull($bar->closures[2]()); + $this->assertSame([], \iterator_to_array($bar->iter)); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Uninitialized_Reference(); + $container->get('foo1'); + $container->get('baz'); + $bar = $container->get('bar'); + $this->assertEquals(new \stdClass(), $bar->foo1); + $this->assertNull($bar->foo2); + $this->assertEquals(new \stdClass(), $bar->foo3); + $this->assertEquals(new \stdClass(), $bar->closures[0]()); + $this->assertNull($bar->closures[1]()); + $this->assertEquals(new \stdClass(), $bar->closures[2]()); + $this->assertEquals(['foo1' => new \stdClass(), 'foo3' => new \stdClass()], \iterator_to_array($bar->iter)); + } + /** + * @dataProvider provideAlmostCircular + */ + public function testAlmostCircular($visibility) + { + $container = (include self::$fixturesPath . '/containers/container_almost_circular.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $container = 'Symfony_DI_PhpDumper_Test_Almost_Circular_' . \ucfirst($visibility); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_almost_circular_' . $visibility . '.php', $dumper->dump(['class' => $container])); + require self::$fixturesPath . '/php/services_almost_circular_' . $visibility . '.php'; + $container = new $container(); + $foo = $container->get('foo'); + $this->assertSame($foo, $foo->bar->foobar->foo); + $foo2 = $container->get('foo2'); + $this->assertSame($foo2, $foo2->bar->foobar->foo); + $this->assertSame([], (array) $container->get('foobar4')); + $foo5 = $container->get('foo5'); + $this->assertSame($foo5, $foo5->bar->foo); + $manager = $container->get('manager'); + $this->assertEquals(new \stdClass(), $manager); + $manager = $container->get('manager2'); + $this->assertEquals(new \stdClass(), $manager); + $foo6 = $container->get('foo6'); + $this->assertEquals((object) ['bar6' => (object) []], $foo6); + $this->assertInstanceOf(\stdClass::class, $container->get('root')); + $manager3 = $container->get('manager3'); + $listener3 = $container->get('listener3'); + $this->assertSame($manager3, $listener3->manager); + $listener4 = $container->get('listener4'); + $this->assertInstanceOf('stdClass', $listener4); + } + public function provideAlmostCircular() + { + (yield ['public']); + (yield ['private']); + } + public function testDeepServiceGraph() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_deep_graph.yml'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dumper->dump(); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_deep_graph.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Deep_Graph'])); + require self::$fixturesPath . '/php/services_deep_graph.php'; + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Deep_Graph(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\FooForDeepGraph::class, $container->get('foo')); + $this->assertEquals((object) ['p2' => (object) ['p3' => (object) []]], $container->get('foo')->bClone); + } + public function testInlineSelfRef() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $bar = (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\App\\Bar'))->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('_PhpScoper5ea00cc67502b\\App\\Foo')); + $baz = (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\App\\Baz'))->setProperty('bar', $bar)->addArgument($bar); + $container->register('_PhpScoper5ea00cc67502b\\App\\Foo')->setPublic(\true)->addArgument($baz); + $container->getCompiler()->getPassConfig(); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_inline_self_ref.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Inline_Self_Ref'])); + } + public function testHotPathOptimizations() + { + $container = (include self::$fixturesPath . '/containers/container_inline_requires.php'); + $container->setParameter('inline_requires', \true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dump = $dumper->dump(['hot_path_tag' => 'container.hot_path', 'inline_class_loader_parameter' => 'inline_requires', 'file' => self::$fixturesPath . '/php/services_inline_requires.php']); + if ('\\' === \DIRECTORY_SEPARATOR) { + $dump = \str_replace("'\\\\includes\\\\HotPath\\\\", "'/includes/HotPath/", $dump); + } + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_inline_requires.php', $dump); + } + public function testDumpHandlesLiteralClassWithRootNamespace() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', '\\stdClass')->setPublic(\true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Literal_Class_With_Root_Namespace'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Literal_Class_With_Root_Namespace(); + $this->assertInstanceOf('stdClass', $container->get('foo')); + } + public function testDumpHandlesObjectClassNames() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['class' => 'stdClass'])); + $container->setDefinition('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter('class'))); + $container->setDefinition('bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')]))->setPublic(\true); + $container->setParameter('inline_requires', \true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Object_Class_Name', 'inline_class_loader_parameter' => 'inline_requires'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Object_Class_Name(); + $this->assertInstanceOf('stdClass', $container->get('bar')); + } + public function testUninitializedSyntheticReference() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setPublic(\true)->setSynthetic(\true); + $container->register('bar', 'stdClass')->setPublic(\true)->setShared(\false)->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder::IGNORE_ON_UNINITIALIZED_REFERENCE)); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_UninitializedSyntheticReference', 'inline_class_loader_parameter' => 'inline_requires'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_UninitializedSyntheticReference(); + $this->assertEquals((object) ['foo' => null], $container->get('bar')); + $container->set('foo', (object) [123]); + $this->assertEquals((object) ['foo' => (object) [123]], $container->get('bar')); + } + public function testAdawsonContainer() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_adawson.yml'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_adawson.php', $dumper->dump()); + } + /** + * @group legacy + * @expectedDeprecation The "private" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. + * @expectedDeprecation The "private_alias" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. + * @expectedDeprecation The "decorated_private" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. + * @expectedDeprecation The "decorated_private_alias" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. + * @expectedDeprecation The "private_not_inlined" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. + * @expectedDeprecation The "private_not_removed" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. + * @expectedDeprecation The "private_child" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. + * @expectedDeprecation The "private_parent" service is private, getting it from the container is deprecated since Symfony 3.2 and will fail in 4.0. You should either make the service public, or stop using the container directly and use dependency injection instead. + */ + public function testLegacyPrivateServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_legacy_privates.yml'); + $container->setDefinition('private_child', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('foo')); + $container->setDefinition('private_parent', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ChildDefinition('private')); + $container->getDefinition('private')->setPrivate(\true); + $container->getDefinition('private_not_inlined')->setPrivate(\true); + $container->getDefinition('private_not_removed')->setPrivate(\true); + $container->getDefinition('decorated_private')->setPrivate(\true); + $container->getDefinition('private_child')->setPrivate(\true); + $container->getAlias('decorated_private_alias')->setPrivate(\true); + $container->getAlias('private_alias')->setPrivate(\true); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_legacy_privates.php', $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Legacy_Privates', 'file' => self::$fixturesPath . '/php/services_legacy_privates.php'])); + require self::$fixturesPath . '/php/services_legacy_privates.php'; + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Legacy_Privates(); + $container->get('private'); + $container->get('private_alias'); + $container->get('alias_to_private'); + $container->get('decorated_private'); + $container->get('decorated_private_alias'); + $container->get('private_not_inlined'); + $container->get('private_not_removed'); + $container->get('private_child'); + $container->get('private_parent'); + $container->get('public_child'); + } + /** + * This test checks the trigger of a deprecation note and should not be removed in major releases. + * + * @group legacy + * @expectedDeprecation The "foo" service is deprecated. You should stop using it, as it will soon be removed. + */ + public function testPrivateServiceTriggersDeprecation() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setPublic(\false)->setDeprecated(\true); + $container->register('bar', 'stdClass')->setPublic(\true)->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Private_Service_Triggers_Deprecation'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Private_Service_Triggers_Deprecation(); + $container->get('bar'); + } + /** + * @group legacy + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "foo" instead of "Foo" is deprecated since Symfony 3.4. + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "FOO" instead of "Foo" is deprecated since Symfony 3.4. + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "bar" instead of "BAR" is deprecated since Symfony 3.4. + */ + public function testParameterWithMixedCase() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['Foo' => 'bar', 'BAR' => 'foo'])); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Parameter_With_Mixed_Case'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Parameter_With_Mixed_Case(); + $this->assertSame('bar', $container->getParameter('foo')); + $this->assertSame('bar', $container->getParameter('FOO')); + $this->assertSame('foo', $container->getParameter('bar')); + $this->assertSame('foo', $container->getParameter('BAR')); + } + /** + * @group legacy + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "FOO" instead of "foo" is deprecated since Symfony 3.4. + */ + public function testParameterWithLowerCase() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar'])); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Parameter_With_Lower_Case'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Parameter_With_Lower_Case(); + $this->assertSame('bar', $container->getParameter('FOO')); + } + /** + * @group legacy + * @expectedDeprecation Service identifiers will be made case sensitive in Symfony 4.0. Using "foo" instead of "Foo" is deprecated since Symfony 3.3. + * @expectedDeprecation The "Foo" service is deprecated. You should stop using it, as it will soon be removed. + */ + public function testReferenceWithLowerCaseId() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('Bar', 'stdClass')->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'))->setPublic(\true); + $container->register('Foo', 'stdClass')->setDeprecated(); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Reference_With_Lower_Case_Id'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Reference_With_Lower_Case_Id(); + $this->assertEquals((object) ['foo' => (object) []], $container->get('Bar')); + } + public function testScalarService() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'string')->setPublic(\true)->setFactory([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ScalarFactory::class, 'getSomeValue']); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + eval('?>' . $dumper->dump(['class' => 'Symfony_DI_PhpDumper_Test_Scalar_Service'])); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_Test_Scalar_Service(); + $this->assertTrue($container->has('foo')); + $this->assertSame('some value', $container->get('foo')); + } + public function testAliasCanBeFoundInTheDumpedContainerWhenBothTheAliasAndTheServiceArePublic() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'stdClass')->setPublic(\true); + $container->setAlias('bar', 'foo')->setPublic(\true); + $container->compile(); + // Bar is found in the compiled container + $service_ids = $container->getServiceIds(); + $this->assertContains('bar', $service_ids); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $dump = $dumper->dump(['class' => 'Symfony_DI_PhpDumper_AliasesCanBeFoundInTheDumpedContainer']); + eval('?>' . $dump); + $container = new \_PhpScoper5ea00cc67502b\Symfony_DI_PhpDumper_AliasesCanBeFoundInTheDumpedContainer(); + // Bar should still be found in the compiled container + $service_ids = $container->getServiceIds(); + $this->assertContains('bar', $service_ids); + } +} +class Rot13EnvVarProcessor implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessorInterface +{ + public function getEnv($prefix, $name, \Closure $getEnv) + { + return \str_rot13($getEnv($name)); + } + public static function getProvidedTypes() + { + return ['rot13' => 'string']; + } +} +class FooForDeepGraph +{ + public $bClone; + public function __construct(\stdClass $a, \stdClass $b) + { + // clone to verify that $b has been fully initialized before + $this->bClone = clone $b; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Dumper/XmlDumperTest.php b/vendor/symfony/dependency-injection/Tests/Dumper/XmlDumperTest.php index 5e00d2525..88a276f68 100644 --- a/vendor/symfony/dependency-injection/Tests/Dumper/XmlDumperTest.php +++ b/vendor/symfony/dependency-injection/Tests/Dumper/XmlDumperTest.php @@ -1,144 +1,144 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class XmlDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected static $fixturesPath; - public static function setUpBeforeClass() - { - self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); - } - public function testDump() - { - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); - $this->assertXmlStringEqualsXmlFile(self::$fixturesPath . '/xml/services1.xml', $dumper->dump(), '->dump() dumps an empty container as an empty XML file'); - } - public function testExportParameters() - { - $container = (include self::$fixturesPath . '//containers/container8.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $this->assertXmlStringEqualsXmlFile(self::$fixturesPath . '/xml/services8.xml', $dumper->dump(), '->dump() dumps parameters'); - } - public function testAddParameters() - { - $container = (include self::$fixturesPath . '//containers/container8.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $this->assertXmlStringEqualsXmlFile(self::$fixturesPath . '/xml/services8.xml', $dumper->dump(), '->dump() dumps parameters'); - } - public function testAddService() - { - $container = (include self::$fixturesPath . '/containers/container9.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $this->assertEquals(\str_replace('%path%', self::$fixturesPath . \DIRECTORY_SEPARATOR . 'includes' . \DIRECTORY_SEPARATOR, \file_get_contents(self::$fixturesPath . '/xml/services9.xml')), $dumper->dump(), '->dump() dumps services'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); - $container->register('foo', 'FooClass')->addArgument(new \stdClass())->setPublic(\true); - try { - $dumper->dump(); - $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } catch (\Exception $e) { - $this->assertInstanceOf('\\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } - } - public function testDumpAnonymousServices() - { - $container = (include self::$fixturesPath . '/containers/container11.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $this->assertEquals(' - - - - - - - - - - - - - - - - -', $dumper->dump()); - } - public function testDumpEntities() - { - $container = (include self::$fixturesPath . '/containers/container12.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $this->assertEquals("\n\n \n \n \n \n foo<>&bar\n \n \n \n \n\n", $dumper->dump()); - } - /** - * @dataProvider provideDecoratedServicesData - */ - public function testDumpDecoratedServices($expectedXmlDump, $container) - { - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $this->assertEquals($expectedXmlDump, $dumper->dump()); - } - public function provideDecoratedServicesData() - { - $fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); - return [["\n\n \n \n \n \n \n \n\n", include $fixturesPath . '/containers/container15.php'], ["\n\n \n \n \n \n \n \n\n", include $fixturesPath . '/containers/container16.php']]; - } - /** - * @dataProvider provideCompiledContainerData - */ - public function testCompiledContainerCanBeDumped($containerFile) - { - $fixturesPath = __DIR__ . '/../Fixtures'; - $container = (require $fixturesPath . '/containers/' . $containerFile . '.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $dumper->dump(); - $this->addToAssertionCount(1); - } - public function provideCompiledContainerData() - { - return [['container8'], ['container9'], ['container11'], ['container12'], ['container14']]; - } - public function testDumpInlinedServices() - { - $container = (include self::$fixturesPath . '/containers/container21.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $this->assertEquals(\file_get_contents(self::$fixturesPath . '/xml/services21.xml'), $dumper->dump()); - } - public function testDumpAutowireData() - { - $container = (include self::$fixturesPath . '/containers/container24.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $this->assertEquals(\file_get_contents(self::$fixturesPath . '/xml/services24.xml'), $dumper->dump()); - } - public function testDumpLoad() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_dump_load.xml'); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE)], $container->getDefinition('foo')->getArguments()); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/xml/services_dump_load.xml', $dumper->dump()); - } - public function testDumpAbstractServices() - { - $container = (include self::$fixturesPath . '/containers/container_abstract.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); - $this->assertEquals(\file_get_contents(self::$fixturesPath . '/xml/services_abstract.xml'), $dumper->dump()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class XmlDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected static $fixturesPath; + public static function setUpBeforeClass() + { + self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); + } + public function testDump() + { + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); + $this->assertXmlStringEqualsXmlFile(self::$fixturesPath . '/xml/services1.xml', $dumper->dump(), '->dump() dumps an empty container as an empty XML file'); + } + public function testExportParameters() + { + $container = (include self::$fixturesPath . '//containers/container8.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $this->assertXmlStringEqualsXmlFile(self::$fixturesPath . '/xml/services8.xml', $dumper->dump(), '->dump() dumps parameters'); + } + public function testAddParameters() + { + $container = (include self::$fixturesPath . '//containers/container8.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $this->assertXmlStringEqualsXmlFile(self::$fixturesPath . '/xml/services8.xml', $dumper->dump(), '->dump() dumps parameters'); + } + public function testAddService() + { + $container = (include self::$fixturesPath . '/containers/container9.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $this->assertEquals(\str_replace('%path%', self::$fixturesPath . \DIRECTORY_SEPARATOR . 'includes' . \DIRECTORY_SEPARATOR, \file_get_contents(self::$fixturesPath . '/xml/services9.xml')), $dumper->dump(), '->dump() dumps services'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); + $container->register('foo', 'FooClass')->addArgument(new \stdClass())->setPublic(\true); + try { + $dumper->dump(); + $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); + } catch (\Exception $e) { + $this->assertInstanceOf('\\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); + $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); + } + } + public function testDumpAnonymousServices() + { + $container = (include self::$fixturesPath . '/containers/container11.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $this->assertEquals(' + + + + + + + + + + + + + + + + +', $dumper->dump()); + } + public function testDumpEntities() + { + $container = (include self::$fixturesPath . '/containers/container12.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $this->assertEquals("\n\n \n \n \n \n foo<>&bar\n \n \n \n \n\n", $dumper->dump()); + } + /** + * @dataProvider provideDecoratedServicesData + */ + public function testDumpDecoratedServices($expectedXmlDump, $container) + { + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $this->assertEquals($expectedXmlDump, $dumper->dump()); + } + public function provideDecoratedServicesData() + { + $fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); + return [["\n\n \n \n \n \n \n \n\n", include $fixturesPath . '/containers/container15.php'], ["\n\n \n \n \n \n \n \n\n", include $fixturesPath . '/containers/container16.php']]; + } + /** + * @dataProvider provideCompiledContainerData + */ + public function testCompiledContainerCanBeDumped($containerFile) + { + $fixturesPath = __DIR__ . '/../Fixtures'; + $container = (require $fixturesPath . '/containers/' . $containerFile . '.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $dumper->dump(); + $this->addToAssertionCount(1); + } + public function provideCompiledContainerData() + { + return [['container8'], ['container9'], ['container11'], ['container12'], ['container14']]; + } + public function testDumpInlinedServices() + { + $container = (include self::$fixturesPath . '/containers/container21.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $this->assertEquals(\file_get_contents(self::$fixturesPath . '/xml/services21.xml'), $dumper->dump()); + } + public function testDumpAutowireData() + { + $container = (include self::$fixturesPath . '/containers/container24.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $this->assertEquals(\file_get_contents(self::$fixturesPath . '/xml/services24.xml'), $dumper->dump()); + } + public function testDumpLoad() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_dump_load.xml'); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE)], $container->getDefinition('foo')->getArguments()); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/xml/services_dump_load.xml', $dumper->dump()); + } + public function testDumpAbstractServices() + { + $container = (include self::$fixturesPath . '/containers/container_abstract.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\XmlDumper($container); + $this->assertEquals(\file_get_contents(self::$fixturesPath . '/xml/services_abstract.xml'), $dumper->dump()); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Dumper/YamlDumperTest.php b/vendor/symfony/dependency-injection/Tests/Dumper/YamlDumperTest.php index a4ecc317e..1496bb60c 100644 --- a/vendor/symfony/dependency-injection/Tests/Dumper/YamlDumperTest.php +++ b/vendor/symfony/dependency-injection/Tests/Dumper/YamlDumperTest.php @@ -1,83 +1,83 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; -class YamlDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected static $fixturesPath; - public static function setUpBeforeClass() - { - self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); - } - public function testDump() - { - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); - $this->assertEqualYamlStructure(\file_get_contents(self::$fixturesPath . '/yaml/services1.yml'), $dumper->dump(), '->dump() dumps an empty container as an empty YAML file'); - } - public function testAddParameters() - { - $container = (include self::$fixturesPath . '/containers/container8.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); - $this->assertEqualYamlStructure(\file_get_contents(self::$fixturesPath . '/yaml/services8.yml'), $dumper->dump(), '->dump() dumps parameters'); - } - public function testAddService() - { - $container = (include self::$fixturesPath . '/containers/container9.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); - $this->assertEqualYamlStructure(\str_replace('%path%', self::$fixturesPath . \DIRECTORY_SEPARATOR . 'includes' . \DIRECTORY_SEPARATOR, \file_get_contents(self::$fixturesPath . '/yaml/services9.yml')), $dumper->dump(), '->dump() dumps services'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); - $container->register('foo', 'FooClass')->addArgument(new \stdClass())->setPublic(\true); - try { - $dumper->dump(); - $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } catch (\Exception $e) { - $this->assertInstanceOf('\\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); - } - } - public function testDumpAutowireData() - { - $container = (include self::$fixturesPath . '/containers/container24.php'); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/yaml/services24.yml', $dumper->dump()); - } - public function testDumpLoad() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_dump_load.yml'); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE)], $container->getDefinition('foo')->getArguments()); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/yaml/services_dump_load.yml', $dumper->dump()); - } - public function testInlineServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->register('foo', 'Class1')->setPublic(\true)->addArgument((new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Class2'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Class2'))); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/yaml/services_inline.yml', $dumper->dump()); - } - private function assertEqualYamlStructure($expected, $yaml, $message = '') - { - $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); - $this->assertEquals($parser->parse($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS), $parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS), $message); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; +class YamlDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected static $fixturesPath; + public static function setUpBeforeClass() + { + self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); + } + public function testDump() + { + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); + $this->assertEqualYamlStructure(\file_get_contents(self::$fixturesPath . '/yaml/services1.yml'), $dumper->dump(), '->dump() dumps an empty container as an empty YAML file'); + } + public function testAddParameters() + { + $container = (include self::$fixturesPath . '/containers/container8.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); + $this->assertEqualYamlStructure(\file_get_contents(self::$fixturesPath . '/yaml/services8.yml'), $dumper->dump(), '->dump() dumps parameters'); + } + public function testAddService() + { + $container = (include self::$fixturesPath . '/containers/container9.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); + $this->assertEqualYamlStructure(\str_replace('%path%', self::$fixturesPath . \DIRECTORY_SEPARATOR . 'includes' . \DIRECTORY_SEPARATOR, \file_get_contents(self::$fixturesPath . '/yaml/services9.yml')), $dumper->dump(), '->dump() dumps services'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); + $container->register('foo', 'FooClass')->addArgument(new \stdClass())->setPublic(\true); + try { + $dumper->dump(); + $this->fail('->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); + } catch (\Exception $e) { + $this->assertInstanceOf('\\RuntimeException', $e, '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); + $this->assertEquals('Unable to dump a service container if a parameter is an object or a resource.', $e->getMessage(), '->dump() throws a RuntimeException if the container to be dumped has reference to objects or resources'); + } + } + public function testDumpAutowireData() + { + $container = (include self::$fixturesPath . '/containers/container24.php'); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/yaml/services24.yml', $dumper->dump()); + } + public function testDumpLoad() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_dump_load.yml'); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_UNINITIALIZED_REFERENCE)], $container->getDefinition('foo')->getArguments()); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/yaml/services_dump_load.yml', $dumper->dump()); + } + public function testInlineServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->register('foo', 'Class1')->setPublic(\true)->addArgument((new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Class2'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Class2'))); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/yaml/services_inline.yml', $dumper->dump()); + } + private function assertEqualYamlStructure($expected, $yaml, $message = '') + { + $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); + $this->assertEquals($parser->parse($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS), $parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS), $message); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Dumper/index.php b/vendor/symfony/dependency-injection/Tests/Dumper/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Dumper/index.php +++ b/vendor/symfony/dependency-injection/Tests/Dumper/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/EnvVarProcessorTest.php b/vendor/symfony/dependency-injection/Tests/EnvVarProcessorTest.php index 3b1bc2597..b08a31256 100644 --- a/vendor/symfony/dependency-injection/Tests/EnvVarProcessorTest.php +++ b/vendor/symfony/dependency-injection/Tests/EnvVarProcessorTest.php @@ -1,200 +1,200 @@ -setParameter('env(foo)', $value); - $container->compile(); - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor($container); - $result = $processor->getEnv('string', 'foo', function () { - $this->fail('Should not be called'); - }); - $this->assertSame($processed, $result); - } - public function validStrings() - { - return [['hello', 'hello'], ['true', 'true'], ['false', 'false'], ['null', 'null'], ['1', '1'], ['0', '0'], ['1.1', '1.1'], ['1e1', '1e1']]; - } - /** - * @dataProvider validBools - */ - public function testGetEnvBool($value, $processed) - { - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $result = $processor->getEnv('bool', 'foo', function ($name) use($value) { - $this->assertSame('foo', $name); - return $value; - }); - $this->assertSame($processed, $result); - } - public function validBools() - { - return [['true', \true], ['false', \false], ['null', \false], ['1', \true], ['0', \false], ['1.1', \true], ['1e1', \true]]; - } - /** - * @dataProvider validInts - */ - public function testGetEnvInt($value, $processed) - { - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $result = $processor->getEnv('int', 'foo', function ($name) use($value) { - $this->assertSame('foo', $name); - return $value; - }); - $this->assertSame($processed, $result); - } - public function validInts() - { - return [['1', 1], ['1.1', 1], ['1e1', 10]]; - } - /** - * @dataProvider invalidInts - */ - public function testGetEnvIntInvalid($value) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Non-numeric env var'); - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $processor->getEnv('int', 'foo', function ($name) use($value) { - $this->assertSame('foo', $name); - return $value; - }); - } - public function invalidInts() - { - return [['foo'], ['true'], ['null']]; - } - /** - * @dataProvider validFloats - */ - public function testGetEnvFloat($value, $processed) - { - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $result = $processor->getEnv('float', 'foo', function ($name) use($value) { - $this->assertSame('foo', $name); - return $value; - }); - $this->assertSame($processed, $result); - } - public function validFloats() - { - return [['1', 1.0], ['1.1', 1.1], ['1e1', 10.0]]; - } - /** - * @dataProvider invalidFloats - */ - public function testGetEnvFloatInvalid($value) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Non-numeric env var'); - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $processor->getEnv('float', 'foo', function ($name) use($value) { - $this->assertSame('foo', $name); - return $value; - }); - } - public function invalidFloats() - { - return [['foo'], ['true'], ['null']]; - } - /** - * @dataProvider validConsts - */ - public function testGetEnvConst($value, $processed) - { - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $result = $processor->getEnv('const', 'foo', function ($name) use($value) { - $this->assertSame('foo', $name); - return $value; - }); - $this->assertSame($processed, $result); - } - public function validConsts() - { - return [['Symfony\\Component\\DependencyInjection\\Tests\\EnvVarProcessorTest::TEST_CONST', self::TEST_CONST], ['E_ERROR', \E_ERROR]]; - } - /** - * @dataProvider invalidConsts - */ - public function testGetEnvConstInvalid($value) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('undefined constant'); - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $processor->getEnv('const', 'foo', function ($name) use($value) { - $this->assertSame('foo', $name); - return $value; - }); - } - public function invalidConsts() - { - return [['Symfony\\Component\\DependencyInjection\\Tests\\EnvVarProcessorTest::UNDEFINED_CONST'], ['UNDEFINED_CONST']]; - } - public function testGetEnvBase64() - { - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $result = $processor->getEnv('base64', 'foo', function ($name) { - $this->assertSame('foo', $name); - return \base64_encode('hello'); - }); - $this->assertSame('hello', $result); - } - public function testGetEnvJson() - { - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $result = $processor->getEnv('json', 'foo', function ($name) { - $this->assertSame('foo', $name); - return \json_encode([1]); - }); - $this->assertSame([1], $result); - } - public function testGetEnvInvalidJson() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Syntax error'); - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $processor->getEnv('json', 'foo', function ($name) { - $this->assertSame('foo', $name); - return 'invalid_json'; - }); - } - /** - * @dataProvider otherJsonValues - */ - public function testGetEnvJsonOther($value) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Invalid JSON env var'); - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $processor->getEnv('json', 'foo', function ($name) use($value) { - $this->assertSame('foo', $name); - return \json_encode($value); - }); - } - public function otherJsonValues() - { - return [[1], [1.1], [\true], [\false]]; - } - public function testGetEnvUnknown() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('Unsupported env var prefix'); - $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); - $processor->getEnv('unknown', 'foo', function ($name) { - $this->assertSame('foo', $name); - return 'foo'; - }); - } -} +setParameter('env(foo)', $value); + $container->compile(); + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor($container); + $result = $processor->getEnv('string', 'foo', function () { + $this->fail('Should not be called'); + }); + $this->assertSame($processed, $result); + } + public function validStrings() + { + return [['hello', 'hello'], ['true', 'true'], ['false', 'false'], ['null', 'null'], ['1', '1'], ['0', '0'], ['1.1', '1.1'], ['1e1', '1e1']]; + } + /** + * @dataProvider validBools + */ + public function testGetEnvBool($value, $processed) + { + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $result = $processor->getEnv('bool', 'foo', function ($name) use($value) { + $this->assertSame('foo', $name); + return $value; + }); + $this->assertSame($processed, $result); + } + public function validBools() + { + return [['true', \true], ['false', \false], ['null', \false], ['1', \true], ['0', \false], ['1.1', \true], ['1e1', \true]]; + } + /** + * @dataProvider validInts + */ + public function testGetEnvInt($value, $processed) + { + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $result = $processor->getEnv('int', 'foo', function ($name) use($value) { + $this->assertSame('foo', $name); + return $value; + }); + $this->assertSame($processed, $result); + } + public function validInts() + { + return [['1', 1], ['1.1', 1], ['1e1', 10]]; + } + /** + * @dataProvider invalidInts + */ + public function testGetEnvIntInvalid($value) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Non-numeric env var'); + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $processor->getEnv('int', 'foo', function ($name) use($value) { + $this->assertSame('foo', $name); + return $value; + }); + } + public function invalidInts() + { + return [['foo'], ['true'], ['null']]; + } + /** + * @dataProvider validFloats + */ + public function testGetEnvFloat($value, $processed) + { + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $result = $processor->getEnv('float', 'foo', function ($name) use($value) { + $this->assertSame('foo', $name); + return $value; + }); + $this->assertSame($processed, $result); + } + public function validFloats() + { + return [['1', 1.0], ['1.1', 1.1], ['1e1', 10.0]]; + } + /** + * @dataProvider invalidFloats + */ + public function testGetEnvFloatInvalid($value) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Non-numeric env var'); + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $processor->getEnv('float', 'foo', function ($name) use($value) { + $this->assertSame('foo', $name); + return $value; + }); + } + public function invalidFloats() + { + return [['foo'], ['true'], ['null']]; + } + /** + * @dataProvider validConsts + */ + public function testGetEnvConst($value, $processed) + { + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $result = $processor->getEnv('const', 'foo', function ($name) use($value) { + $this->assertSame('foo', $name); + return $value; + }); + $this->assertSame($processed, $result); + } + public function validConsts() + { + return [['Symfony\\Component\\DependencyInjection\\Tests\\EnvVarProcessorTest::TEST_CONST', self::TEST_CONST], ['E_ERROR', \E_ERROR]]; + } + /** + * @dataProvider invalidConsts + */ + public function testGetEnvConstInvalid($value) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('undefined constant'); + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $processor->getEnv('const', 'foo', function ($name) use($value) { + $this->assertSame('foo', $name); + return $value; + }); + } + public function invalidConsts() + { + return [['Symfony\\Component\\DependencyInjection\\Tests\\EnvVarProcessorTest::UNDEFINED_CONST'], ['UNDEFINED_CONST']]; + } + public function testGetEnvBase64() + { + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $result = $processor->getEnv('base64', 'foo', function ($name) { + $this->assertSame('foo', $name); + return \base64_encode('hello'); + }); + $this->assertSame('hello', $result); + } + public function testGetEnvJson() + { + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $result = $processor->getEnv('json', 'foo', function ($name) { + $this->assertSame('foo', $name); + return \json_encode([1]); + }); + $this->assertSame([1], $result); + } + public function testGetEnvInvalidJson() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Syntax error'); + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $processor->getEnv('json', 'foo', function ($name) { + $this->assertSame('foo', $name); + return 'invalid_json'; + }); + } + /** + * @dataProvider otherJsonValues + */ + public function testGetEnvJsonOther($value) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Invalid JSON env var'); + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $processor->getEnv('json', 'foo', function ($name) use($value) { + $this->assertSame('foo', $name); + return \json_encode($value); + }); + } + public function otherJsonValues() + { + return [[1], [1.1], [\true], [\false]]; + } + public function testGetEnvUnknown() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('Unsupported env var prefix'); + $processor = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\EnvVarProcessor(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container()); + $processor->getEnv('unknown', 'foo', function ($name) { + $this->assertSame('foo', $name); + return 'foo'; + }); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Extension/ExtensionTest.php b/vendor/symfony/dependency-injection/Tests/Extension/ExtensionTest.php index 32349b4bc..bed22ff2a 100644 --- a/vendor/symfony/dependency-injection/Tests/Extension/ExtensionTest.php +++ b/vendor/symfony/dependency-injection/Tests/Extension/ExtensionTest.php @@ -1,47 +1,47 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Extension; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension; -class ExtensionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @dataProvider getResolvedEnabledFixtures - */ - public function testIsConfigEnabledReturnsTheResolvedValue($enabled) - { - $extension = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Extension\EnableableExtension(); - $this->assertSame($enabled, $extension->isConfigEnabled(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), ['enabled' => $enabled])); - } - public function getResolvedEnabledFixtures() - { - return [[\true], [\false]]; - } - public function testIsConfigEnabledOnNonEnableableConfig() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The config array has no \'enabled\' key.'); - $extension = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Extension\EnableableExtension(); - $extension->isConfigEnabled(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), []); - } -} -class EnableableExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension -{ - public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - } - public function isConfigEnabled(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, array $config) - { - return parent::isConfigEnabled($container, $config); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Extension; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension; +class ExtensionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @dataProvider getResolvedEnabledFixtures + */ + public function testIsConfigEnabledReturnsTheResolvedValue($enabled) + { + $extension = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Extension\EnableableExtension(); + $this->assertSame($enabled, $extension->isConfigEnabled(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), ['enabled' => $enabled])); + } + public function getResolvedEnabledFixtures() + { + return [[\true], [\false]]; + } + public function testIsConfigEnabledOnNonEnableableConfig() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The config array has no \'enabled\' key.'); + $extension = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Extension\EnableableExtension(); + $extension->isConfigEnabled(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), []); + } +} +class EnableableExtension extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Extension\Extension +{ + public function load(array $configs, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + } + public function isConfigEnabled(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container, array $config) + { + return parent::isConfigEnabled($container, $config); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Extension/index.php b/vendor/symfony/dependency-injection/Tests/Extension/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Extension/index.php +++ b/vendor/symfony/dependency-injection/Tests/Extension/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Bar.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Bar.php index 65861af98..36b781764 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Bar.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Bar.php @@ -1,23 +1,23 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -class Bar implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface -{ - public $quz; - public function __construct($quz = null, \_PhpScoper5ea00cc67502b\NonExistent $nonExistent = null, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface $decorated = null, array $foo = []) - { - $this->quz = $quz; - } - public static function create(\_PhpScoper5ea00cc67502b\NonExistent $nonExistent = null, $factory = null) - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +class Bar implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface +{ + public $quz; + public function __construct($quz = null, \_PhpScoper5ea00cc67502b\NonExistent $nonExistent = null, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface $decorated = null, array $foo = []) + { + $this->quz = $quz; + } + public static function create(\_PhpScoper5ea00cc67502b\NonExistent $nonExistent = null, $factory = null) + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/BarInterface.php b/vendor/symfony/dependency-injection/Tests/Fixtures/BarInterface.php index 6e8ef2d07..92b32d693 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/BarInterface.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/BarInterface.php @@ -1,15 +1,15 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -interface BarInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +interface BarInterface +{ +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/CaseSensitiveClass.php b/vendor/symfony/dependency-injection/Tests/Fixtures/CaseSensitiveClass.php index 77ab859e3..6a7f89ee9 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/CaseSensitiveClass.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/CaseSensitiveClass.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -class CaseSensitiveClass -{ - public $identifier; - public function __construct($identifier = null) - { - $this->identifier = $identifier; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +class CaseSensitiveClass +{ + public $identifier; + public function __construct($identifier = null) + { + $this->identifier = $identifier; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Container/ConstructorWithMandatoryArgumentsContainer.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Container/ConstructorWithMandatoryArgumentsContainer.php index 7e613838d..60d0670be 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Container/ConstructorWithMandatoryArgumentsContainer.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Container/ConstructorWithMandatoryArgumentsContainer.php @@ -1,10 +1,10 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/CustomDefinition.php b/vendor/symfony/dependency-injection/Tests/Fixtures/CustomDefinition.php index 3fdf8892d..e0bba4e68 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/CustomDefinition.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/CustomDefinition.php @@ -1,16 +1,16 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -class CustomDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +class CustomDefinition extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition +{ +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/DeprecatedClass.php b/vendor/symfony/dependency-injection/Tests/Fixtures/DeprecatedClass.php index 524ca801c..373115121 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/DeprecatedClass.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/DeprecatedClass.php @@ -1,16 +1,16 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -@\trigger_error('deprecated', \E_USER_DEPRECATED); -class DeprecatedClass -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +@\trigger_error('deprecated', \E_USER_DEPRECATED); +class DeprecatedClass +{ +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/FactoryDummy.php b/vendor/symfony/dependency-injection/Tests/Fixtures/FactoryDummy.php index 89ebd4d63..7087283b9 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/FactoryDummy.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/FactoryDummy.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -class FactoryDummy extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryParent -{ - public static function createFactory() : \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy - { - } - public function create() : \stdClass - { - } - // Not supported by hhvm - public function createBuiltin() : int - { - } - public static function createSelf() : self - { - } - public static function createParent() : \_PhpScoper5ea00cc67502b\parent - { - } -} -class FactoryParent -{ -} -function factoryFunction() : \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +class FactoryDummy extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryParent +{ + public static function createFactory() : \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy + { + } + public function create() : \stdClass + { + } + // Not supported by hhvm + public function createBuiltin() : int + { + } + public static function createSelf() : self + { + } + public static function createParent() : \_PhpScoper5ea00cc67502b\parent + { + } +} +class FactoryParent +{ +} +function factoryFunction() : \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FactoryDummy +{ +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/FactoryDummyWithoutReturnTypes.php b/vendor/symfony/dependency-injection/Tests/Fixtures/FactoryDummyWithoutReturnTypes.php index caf7a4e51..024cf78d9 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/FactoryDummyWithoutReturnTypes.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/FactoryDummyWithoutReturnTypes.php @@ -1,18 +1,18 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -class FactoryDummyWithoutReturnTypes -{ - public function createTestDefinition1() - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +class FactoryDummyWithoutReturnTypes +{ + public function createTestDefinition1() + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/FooForCircularWithAddCalls.php b/vendor/symfony/dependency-injection/Tests/Fixtures/FooForCircularWithAddCalls.php index 51e3ebb7f..e28675e98 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/FooForCircularWithAddCalls.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/FooForCircularWithAddCalls.php @@ -1,18 +1,18 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -class FooForCircularWithAddCalls -{ - public function call(\stdClass $argument) - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +class FooForCircularWithAddCalls +{ + public function call(\stdClass $argument) + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/NamedArgumentsDummy.php b/vendor/symfony/dependency-injection/Tests/Fixtures/NamedArgumentsDummy.php index 281a688dc..dd5312662 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/NamedArgumentsDummy.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/NamedArgumentsDummy.php @@ -1,19 +1,19 @@ - - */ -class NamedArgumentsDummy -{ - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass $c, $apiKey, $hostName) - { - } - public function setApiKey($apiKey) - { - } - public function setSensitiveClass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass $c) - { - } -} + + */ +class NamedArgumentsDummy +{ + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass $c, $apiKey, $hostName) + { + } + public function setApiKey($apiKey) + { + } + public function setSensitiveClass(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass $c) + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ParentNotExists.php b/vendor/symfony/dependency-injection/Tests/Fixtures/ParentNotExists.php index 356610961..299ba5364 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ParentNotExists.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ParentNotExists.php @@ -1,7 +1,7 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Foo.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Foo.php index 318831c01..238897712 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Foo.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Foo.php @@ -1,13 +1,13 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Baz.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Baz.php index 10d41fe05..cf3a4066f 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Baz.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Baz.php @@ -1,7 +1,7 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir2/Service2.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir2/Service2.php index d7d3358a3..5eb9d13a7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir2/Service2.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/Dir2/Service2.php @@ -1,7 +1,7 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component1/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir1/Service4.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir1/Service4.php index c2bb1cc66..2236dd4c0 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir1/Service4.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir1/Service4.php @@ -1,7 +1,7 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir2/Service5.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir2/Service5.php index 94728a571..dfc3f3704 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir2/Service5.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/Dir2/Service5.php @@ -1,7 +1,7 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/Component2/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/OtherDir/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Sub/Bar.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Sub/Bar.php index cdfd5293d..88fd45186 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Sub/Bar.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/Sub/Bar.php @@ -1,7 +1,7 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/Prototype/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ScalarFactory.php b/vendor/symfony/dependency-injection/Tests/Fixtures/ScalarFactory.php index 2ce95f892..60dbc6a54 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ScalarFactory.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ScalarFactory.php @@ -1,14 +1,14 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -class SimilarArgumentsDummy -{ - public $class1; - public $class2; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass $class1, $token, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass $class2) - { - $this->class1 = $class1; - $this->class2 = $class2; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +class SimilarArgumentsDummy +{ + public $class1; + public $class2; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass $class1, $token, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass $class2) + { + $this->class1 = $class1; + $this->class2 = $class2; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/StubbedTranslator.php b/vendor/symfony/dependency-injection/Tests/Fixtures/StubbedTranslator.php index 9b11185e6..119505dfd 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/StubbedTranslator.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/StubbedTranslator.php @@ -1,25 +1,25 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface; -/** - * @author Iltar van der Berg - */ -class StubbedTranslator -{ - public function __construct(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface $container) - { - } - public function addResource($format, $resource, $locale, $domain = null) - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface; +/** + * @author Iltar van der Berg + */ +class StubbedTranslator +{ + public function __construct(\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface $container) + { + } + public function addResource($format, $resource, $locale, $domain = null) + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/TestDefinition1.php b/vendor/symfony/dependency-injection/Tests/Fixtures/TestDefinition1.php index c9bb56dd6..813ce1868 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/TestDefinition1.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/TestDefinition1.php @@ -1,16 +1,16 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; - -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -class TestDefinition1 extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures; + +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +class TestDefinition1 extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition +{ +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/TestDefinition2.php b/vendor/symfony/dependency-injection/Tests/Fixtures/TestDefinition2.php index cbcf5deb7..3df153b9b 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/TestDefinition2.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/TestDefinition2.php @@ -1,8 +1,8 @@ - \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, 'baz' => '?' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class]; - } -} + \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class, 'baz' => '?' . \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition::class]; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/array.json b/vendor/symfony/dependency-injection/Tests/Fixtures/array.json index dc27f0fa1..d7c0adc07 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/array.json +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/array.json @@ -1 +1 @@ -[123, "abc"] +[123, "abc"] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/basic.expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/config/basic.expected.yml index 170ea3356..831770fe1 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/basic.expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/basic.expected.yml @@ -1,10 +1,10 @@ - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - _PhpScoper5ea00cc67502b\App\BarService: - class: _PhpScoper5ea00cc67502b\App\BarService - public: true - arguments: [!service { class: FooClass }] + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + _PhpScoper5ea00cc67502b\App\BarService: + class: _PhpScoper5ea00cc67502b\App\BarService + public: true + arguments: [!service { class: FooClass }] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/basic.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/basic.php index 252eec68c..a720b1ab4 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/basic.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/basic.php @@ -1,9 +1,9 @@ -services(); - $s->set(\_PhpScoper5ea00cc67502b\App\BarService::class)->args([inline('FooClass')]); -}; +services(); + $s->set(\_PhpScoper5ea00cc67502b\App\BarService::class)->args([inline('FooClass')]); +}; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/child.expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/config/child.expected.yml index f82693d7c..417ca359e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/child.expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/child.expected.yml @@ -1,15 +1,15 @@ - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - foo: - class: Class2 - public: true - file: file.php - lazy: true - arguments: [!service { class: Class1, public: false }] - bar: - alias: foo - public: true + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + foo: + class: Class2 + public: true + file: file.php + lazy: true + arguments: [!service { class: Class1, public: false }] + bar: + alias: foo + public: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/child.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/child.php index a7fa866cb..82ac824e0 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/child.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/child.php @@ -1,8 +1,8 @@ -services()->set('bar', 'Class1')->set(\_PhpScoper5ea00cc67502b\App\BarService::class)->abstract(\true)->lazy()->set('foo')->parent(\_PhpScoper5ea00cc67502b\App\BarService::class)->decorate('bar', 'b', 1)->args([ref('b')])->class('Class2')->file('file.php')->parent('bar')->parent(\_PhpScoper5ea00cc67502b\App\BarService::class); -}; +services()->set('bar', 'Class1')->set(\_PhpScoper5ea00cc67502b\App\BarService::class)->abstract(\true)->lazy()->set('foo')->parent(\_PhpScoper5ea00cc67502b\App\BarService::class)->decorate('bar', 'b', 1)->args([ref('b')])->class('Class2')->file('file.php')->parent('bar')->parent(\_PhpScoper5ea00cc67502b\App\BarService::class); +}; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/defaults.expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/config/defaults.expected.yml index 37b995635..9e369f3b4 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/defaults.expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/defaults.expected.yml @@ -1,27 +1,27 @@ - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - _PhpScoper5ea00cc67502b\App\BarService: - class: _PhpScoper5ea00cc67502b\App\BarService - public: true - arguments: [!service { class: FooClass }] - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo - public: true - tags: - - { name: t, a: b } - autowire: true - autoconfigure: true - arguments: ['@bar'] - bar: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo - public: false - tags: - - { name: t, a: b } - autowire: true - calls: - - [setFoo, ['@bar']] - + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + _PhpScoper5ea00cc67502b\App\BarService: + class: _PhpScoper5ea00cc67502b\App\BarService + public: true + arguments: [!service { class: FooClass }] + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo + public: true + tags: + - { name: t, a: b } + autowire: true + autoconfigure: true + arguments: ['@bar'] + bar: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo + public: false + tags: + - { name: t, a: b } + autowire: true + calls: + - [setFoo, ['@bar']] + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/defaults.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/defaults.php index 77f0965d9..bc31012b6 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/defaults.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/defaults.php @@ -1,11 +1,11 @@ -import('basic.php'); - $s = $c->services()->defaults()->public()->private()->autoconfigure()->autowire()->tag('t', ['a' => 'b'])->bind(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class, ref('bar'))->private(); - $s->set(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->args([ref('bar')])->public(); - $s->set('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->call('setFoo')->autoconfigure(\false); -}; +import('basic.php'); + $s = $c->services()->defaults()->public()->private()->autoconfigure()->autowire()->tag('t', ['a' => 'b'])->bind(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class, ref('bar'))->private(); + $s->set(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->args([ref('bar')])->public(); + $s->set('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->call('setFoo')->autoconfigure(\false); +}; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/factory_short_notation.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/factory_short_notation.php index 27ec3bb8a..ae12c23a0 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/factory_short_notation.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/factory_short_notation.php @@ -1,7 +1,7 @@ -services()->set('service', \stdClass::class)->factory('factory:method'); -}; +services()->set('service', \stdClass::class)->factory('factory:method'); +}; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/instanceof.expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/config/instanceof.expected.yml index 888a4ebef..2ac3dfeb6 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/instanceof.expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/instanceof.expected.yml @@ -1,21 +1,21 @@ - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo - public: true - tags: - - { name: tag, k: v } - lazy: true - properties: { p: 1 } - calls: - - [setFoo, ['@foo']] - - shared: false - configurator: c - foo: - class: _PhpScoper5ea00cc67502b\App\FooService - public: true + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo + public: true + tags: + - { name: tag, k: v } + lazy: true + properties: { p: 1 } + calls: + - [setFoo, ['@foo']] + + shared: false + configurator: c + foo: + class: _PhpScoper5ea00cc67502b\App\FooService + public: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/instanceof.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/instanceof.php index 605548b66..b707bb6ed 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/instanceof.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/instanceof.php @@ -1,12 +1,12 @@ -services(); - $s->instanceof(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->property('p', 0)->call('setFoo', [ref('foo')])->tag('tag', ['k' => 'v'])->share(\false)->lazy()->configurator('c')->property('p', 1); - $s->load(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype::class . '\\', '../Prototype')->exclude('../Prototype/*/*'); - $s->set('foo', \_PhpScoper5ea00cc67502b\App\FooService::class); -}; +services(); + $s->instanceof(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->property('p', 0)->call('setFoo', [ref('foo')])->tag('tag', ['k' => 'v'])->share(\false)->lazy()->configurator('c')->property('p', 1); + $s->load(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype::class . '\\', '../Prototype')->exclude('../Prototype/*/*'); + $s->set('foo', \_PhpScoper5ea00cc67502b\App\FooService::class); +}; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/php7.expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/config/php7.expected.yml index 33d7fbb03..4a30dc3b8 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/php7.expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/php7.expected.yml @@ -1,19 +1,19 @@ -parameters: - foo: Foo - bar: Bar - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo - public: true - arguments: ['@bar'] - bar: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo - public: true - calls: - - [setFoo, { }] - +parameters: + foo: Foo + bar: Bar + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo + public: true + arguments: ['@bar'] + bar: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo + public: true + calls: + - [setFoo, { }] + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/php7.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/php7.php index 54291fa5b..f800eedd6 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/php7.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/php7.php @@ -1,9 +1,9 @@ -parameters()('foo', 'Foo')('bar', 'Bar'); - $c->services()(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->arg('$bar', ref('bar'))->public()('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->call('setFoo'); -}; +parameters()('foo', 'Foo')('bar', 'Bar'); + $c->services()(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->arg('$bar', ref('bar'))->public()('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->call('setFoo'); +}; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/prototype.expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/config/prototype.expected.yml index 29d536515..7936dbfb8 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/prototype.expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/prototype.expected.yml @@ -1,25 +1,25 @@ - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo - public: true - tags: - - { name: foo } - - { name: baz } - deprecated: '%service_id%' - arguments: [1] - factory: f - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar - public: true - tags: - - { name: foo } - - { name: baz } - deprecated: '%service_id%' - lazy: true - arguments: [1] - factory: f + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo + public: true + tags: + - { name: foo } + - { name: baz } + deprecated: '%service_id%' + arguments: [1] + factory: f + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar + public: true + tags: + - { name: foo } + - { name: baz } + deprecated: '%service_id%' + lazy: true + arguments: [1] + factory: f diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/prototype.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/prototype.php index fe228e7b7..0efcc66be 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/prototype.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/prototype.php @@ -1,11 +1,11 @@ -services()->defaults()->tag('baz'); - $di->load(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype::class . '\\', '../Prototype')->autoconfigure()->exclude('../Prototype/{OtherDir,BadClasses}')->factory('f')->deprecate('%service_id%')->args([0])->args([1])->autoconfigure(\false)->tag('foo')->parent('foo'); - $di->set('foo')->lazy()->abstract(); - $di->get(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->lazy(\false); -}; +services()->defaults()->tag('baz'); + $di->load(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype::class . '\\', '../Prototype')->autoconfigure()->exclude('../Prototype/{OtherDir,BadClasses}')->factory('f')->deprecate('%service_id%')->args([0])->args([1])->autoconfigure(\false)->tag('foo')->parent('foo'); + $di->set('foo')->lazy()->abstract(); + $di->get(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)->lazy(\false); +}; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/services9.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/services9.php index 1729a3efb..cb1a85229 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/services9.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/services9.php @@ -1,43 +1,43 @@ -parameters(); - $p->set('baz_class', 'BazClass'); - $p->set('foo_class', \_PhpScoper5ea00cc67502b\Bar\FooClass::class)->set('foo', 'bar'); - $s = $c->services(); - $s->set('foo')->args(['foo', ref('foo.baz'), ['%foo%' => 'foo is %foo%', 'foobar' => '%foo%'], \true, ref('service_container')])->class(\_PhpScoper5ea00cc67502b\Bar\FooClass::class)->tag('foo', ['foo' => 'foo'])->tag('foo', ['bar' => 'bar', 'baz' => 'baz'])->factory([\_PhpScoper5ea00cc67502b\Bar\FooClass::class, 'getInstance'])->property('foo', 'bar')->property('moo', ref('foo.baz'))->property('qux', ['%foo%' => 'foo is %foo%', 'foobar' => '%foo%'])->call('setBar', [ref('bar')])->call('initialize')->configurator('sc_configure'); - $s->set('foo.baz', '%baz_class%')->factory(['%baz_class%', 'getInstance'])->configurator(['%baz_class%', 'configureStatic1']); - $s->set('bar', \_PhpScoper5ea00cc67502b\Bar\FooClass::class)->args(['foo', ref('foo.baz'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter('foo_bar')])->configurator([ref('foo.baz'), 'configure']); - $s->set('foo_bar', '%foo_class%')->args([ref('deprecated_service')])->share(\false); - $s->set('method_call1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->file(\realpath(__DIR__ . '/../includes/foo.php'))->call('setBar', [ref('foo')])->call('setBar', [ref('foo2')->nullOnInvalid()])->call('setBar', [ref('foo3')->ignoreOnInvalid()])->call('setBar', [ref('foobaz')->ignoreOnInvalid()])->call('setBar', [expr('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')]); - $s->set('foo_with_inline', 'Foo')->call('setBar', [ref('inlined')]); - $s->set('inlined', 'Bar')->property('pub', 'pub')->call('setBaz', [ref('baz')])->private(); - $s->set('baz', 'Baz')->call('setFoo', [ref('foo_with_inline')]); - $s->set('request', 'Request')->synthetic(); - $s->set('configurator_service', 'ConfClass')->private()->call('setFoo', [ref('baz')]); - $s->set('configured_service', 'stdClass')->configurator([ref('configurator_service'), 'configureStdClass']); - $s->set('configurator_service_simple', 'ConfClass')->args(['bar'])->private(); - $s->set('configured_service_simple', 'stdClass')->configurator([ref('configurator_service_simple'), 'configureStdClass']); - $s->set('decorated', 'stdClass'); - $s->set('decorator_service', 'stdClass')->decorate('decorated'); - $s->set('decorator_service_with_name', 'stdClass')->decorate('decorated', 'decorated.pif-pouf'); - $s->set('deprecated_service', 'stdClass')->deprecate(); - $s->set('new_factory', 'FactoryClass')->property('foo', 'bar')->private(); - $s->set('factory_service', 'Bar')->factory([ref('foo.baz'), 'getInstance']); - $s->set('new_factory_service', 'FooBarBaz')->property('foo', 'bar')->factory([ref('new_factory'), 'getInstance']); - $s->set('service_from_static_method', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->factory(['_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'getInstance']); - $s->set('factory_simple', 'SimpleFactoryClass')->deprecate()->args(['foo'])->private(); - $s->set('factory_service_simple', 'Bar')->factory([ref('factory_simple'), 'getInstance']); - $s->set('lazy_context', 'LazyContext')->args([iterator(['k1' => ref('foo.baz'), 'k2' => ref('service_container')]), iterator([])]); - $s->set('lazy_context_ignore_invalid_ref', 'LazyContext')->args([iterator([ref('foo.baz'), ref('invalid')->ignoreOnInvalid()]), iterator([])]); - $s->set('tagged_iterator_foo', 'Bar')->private()->tag('foo'); - $s->set('tagged_iterator', 'Bar')->public()->args([tagged('foo')]); - $s->alias('alias_for_foo', 'foo')->private()->public(); - $s->alias('alias_for_alias', ref('alias_for_foo')); -}; +parameters(); + $p->set('baz_class', 'BazClass'); + $p->set('foo_class', \_PhpScoper5ea00cc67502b\Bar\FooClass::class)->set('foo', 'bar'); + $s = $c->services(); + $s->set('foo')->args(['foo', ref('foo.baz'), ['%foo%' => 'foo is %foo%', 'foobar' => '%foo%'], \true, ref('service_container')])->class(\_PhpScoper5ea00cc67502b\Bar\FooClass::class)->tag('foo', ['foo' => 'foo'])->tag('foo', ['bar' => 'bar', 'baz' => 'baz'])->factory([\_PhpScoper5ea00cc67502b\Bar\FooClass::class, 'getInstance'])->property('foo', 'bar')->property('moo', ref('foo.baz'))->property('qux', ['%foo%' => 'foo is %foo%', 'foobar' => '%foo%'])->call('setBar', [ref('bar')])->call('initialize')->configurator('sc_configure'); + $s->set('foo.baz', '%baz_class%')->factory(['%baz_class%', 'getInstance'])->configurator(['%baz_class%', 'configureStatic1']); + $s->set('bar', \_PhpScoper5ea00cc67502b\Bar\FooClass::class)->args(['foo', ref('foo.baz'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter('foo_bar')])->configurator([ref('foo.baz'), 'configure']); + $s->set('foo_bar', '%foo_class%')->args([ref('deprecated_service')])->share(\false); + $s->set('method_call1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->file(\realpath(__DIR__ . '/../includes/foo.php'))->call('setBar', [ref('foo')])->call('setBar', [ref('foo2')->nullOnInvalid()])->call('setBar', [ref('foo3')->ignoreOnInvalid()])->call('setBar', [ref('foobaz')->ignoreOnInvalid()])->call('setBar', [expr('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')]); + $s->set('foo_with_inline', 'Foo')->call('setBar', [ref('inlined')]); + $s->set('inlined', 'Bar')->property('pub', 'pub')->call('setBaz', [ref('baz')])->private(); + $s->set('baz', 'Baz')->call('setFoo', [ref('foo_with_inline')]); + $s->set('request', 'Request')->synthetic(); + $s->set('configurator_service', 'ConfClass')->private()->call('setFoo', [ref('baz')]); + $s->set('configured_service', 'stdClass')->configurator([ref('configurator_service'), 'configureStdClass']); + $s->set('configurator_service_simple', 'ConfClass')->args(['bar'])->private(); + $s->set('configured_service_simple', 'stdClass')->configurator([ref('configurator_service_simple'), 'configureStdClass']); + $s->set('decorated', 'stdClass'); + $s->set('decorator_service', 'stdClass')->decorate('decorated'); + $s->set('decorator_service_with_name', 'stdClass')->decorate('decorated', 'decorated.pif-pouf'); + $s->set('deprecated_service', 'stdClass')->deprecate(); + $s->set('new_factory', 'FactoryClass')->property('foo', 'bar')->private(); + $s->set('factory_service', 'Bar')->factory([ref('foo.baz'), 'getInstance']); + $s->set('new_factory_service', 'FooBarBaz')->property('foo', 'bar')->factory([ref('new_factory'), 'getInstance']); + $s->set('service_from_static_method', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->factory(['_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'getInstance']); + $s->set('factory_simple', 'SimpleFactoryClass')->deprecate()->args(['foo'])->private(); + $s->set('factory_service_simple', 'Bar')->factory([ref('factory_simple'), 'getInstance']); + $s->set('lazy_context', 'LazyContext')->args([iterator(['k1' => ref('foo.baz'), 'k2' => ref('service_container')]), iterator([])]); + $s->set('lazy_context_ignore_invalid_ref', 'LazyContext')->args([iterator([ref('foo.baz'), ref('invalid')->ignoreOnInvalid()]), iterator([])]); + $s->set('tagged_iterator_foo', 'Bar')->private()->tag('foo'); + $s->set('tagged_iterator', 'Bar')->public()->args([tagged('foo')]); + $s->alias('alias_for_foo', 'foo')->private()->public(); + $s->alias('alias_for_alias', ref('alias_for_foo')); +}; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/config/services_autoconfigure_with_parent.php b/vendor/symfony/dependency-injection/Tests/Fixtures/config/services_autoconfigure_with_parent.php index 8119eadf2..843238d78 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/config/services_autoconfigure_with_parent.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/config/services_autoconfigure_with_parent.php @@ -1,7 +1,7 @@ -services()->set('parent_service', \stdClass::class)->set('child_service')->parent('parent_service')->autoconfigure(\true); -}; +services()->set('parent_service', \stdClass::class)->set('child_service')->parent('parent_service')->autoconfigure(\true); +}; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/CustomContainer.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/CustomContainer.php index 5ee7f3c4d..65aa1fe14 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/CustomContainer.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/CustomContainer.php @@ -1,15 +1,15 @@ -register('foo', 'FooClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))->setPublic(\true); -return $container; +register('foo', 'FooClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container11.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container11.php index c66adf959..2e9e0db3e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container11.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container11.php @@ -1,9 +1,9 @@ -register('foo', 'FooClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BarClass', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BazClass')]))->setPublic(\true); -return $container; +register('foo', 'FooClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BarClass', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('BazClass')]))->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container12.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container12.php index 849ea332e..08ba3e975 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container12.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container12.php @@ -1,8 +1,8 @@ -register('foo', '_PhpScoper5ea00cc67502b\\FooClass\\Foo')->addArgument('foo<>&bar')->addTag('_PhpScoper5ea00cc67502b\\foo"bar\\bar', ['foo' => 'foo"barřž€'])->setPublic(\true); -return $container; +register('foo', '_PhpScoper5ea00cc67502b\\FooClass\\Foo')->addArgument('foo<>&bar')->addTag('_PhpScoper5ea00cc67502b\\foo"bar\\bar', ['foo' => 'foo"barřž€'])->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container13.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container13.php index 5b7fa14c5..30ac4e7d8 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container13.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container13.php @@ -1,11 +1,11 @@ -register('foo', 'FooClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))->setPublic(\true); -$container->register('bar', 'BarClass')->setPublic(\true); -$container->compile(); -return $container; +register('foo', 'FooClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar'))->setPublic(\true); +$container->register('bar', 'BarClass')->setPublic(\true); +$container->compile(); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container14.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container14.php index 6e31168dc..0a9d4f548 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container14.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container14.php @@ -1,15 +1,15 @@ -register('foo', '_PhpScoper5ea00cc67502b\\FooClass\\Foo')->setDecoratedService('bar', 'bar.woozy')->setPublic(\true); -return $container; +register('foo', '_PhpScoper5ea00cc67502b\\FooClass\\Foo')->setDecoratedService('bar', 'bar.woozy')->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container16.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container16.php index 74b2f61d4..3e28adfd8 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container16.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container16.php @@ -1,8 +1,8 @@ -register('foo', '_PhpScoper5ea00cc67502b\\FooClass\\Foo')->setDecoratedService('bar')->setPublic(\true); -return $container; +register('foo', '_PhpScoper5ea00cc67502b\\FooClass\\Foo')->setDecoratedService('bar')->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container17.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container17.php index eaf2d4ee9..fec4da481 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container17.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container17.php @@ -1,8 +1,8 @@ -register('foo', '%foo.class%')->setPublic(\true); -return $container; +register('foo', '%foo.class%')->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container19.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container19.php index 590c6aab2..176996edd 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container19.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container19.php @@ -1,15 +1,15 @@ -setParameter('env(FOO)', '_PhpScoper5ea00cc67502b\\Bar\\FaooClass'); -$container->setParameter('foo', '%env(FOO)%'); -$container->register('service_from_anonymous_factory', '%foo%')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('%foo%'), 'getInstance'])->setPublic(\true); -$anonymousServiceWithFactory = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\Bar\\FooClass'); -$anonymousServiceWithFactory->setFactory('Bar\\FooClass::getInstance'); -$container->register('service_with_method_call_and_factory', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addMethodCall('setBar', [$anonymousServiceWithFactory])->setPublic(\true); -return $container; +setParameter('env(FOO)', '_PhpScoper5ea00cc67502b\\Bar\\FaooClass'); +$container->setParameter('foo', '%env(FOO)%'); +$container->register('service_from_anonymous_factory', '%foo%')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('%foo%'), 'getInstance'])->setPublic(\true); +$anonymousServiceWithFactory = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('_PhpScoper5ea00cc67502b\\Bar\\FooClass'); +$anonymousServiceWithFactory->setFactory('Bar\\FooClass::getInstance'); +$container->register('service_with_method_call_and_factory', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addMethodCall('setBar', [$anonymousServiceWithFactory])->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container21.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container21.php index 974814b91..551c88db6 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container21.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container21.php @@ -1,13 +1,13 @@ -setConfigurator([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Baz'), 'configureBar']); -$fooFactory = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooFactory'); -$fooFactory->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Foobar'), 'createFooFactory']); -$container->register('foo', 'Foo')->setFactory([$fooFactory, 'createFoo'])->setConfigurator([$bar, 'configureFoo'])->setPublic(\true); -return $container; +setConfigurator([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Baz'), 'configureBar']); +$fooFactory = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooFactory'); +$fooFactory->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('Foobar'), 'createFooFactory']); +$container->register('foo', 'Foo')->setFactory([$fooFactory, 'createFoo'])->setConfigurator([$bar, 'configureFoo'])->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container24.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container24.php index d07ba70d6..2b52dfbe4 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container24.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container24.php @@ -1,8 +1,8 @@ -register('foo', 'Foo')->setAutowired(\true)->setPublic(\true); -return $container; +register('foo', 'Foo')->setAutowired(\true)->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container33.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container33.php index 8f155c3e1..9be8dd5be 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container33.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container33.php @@ -1,9 +1,9 @@ -register(\_PhpScoper5ea00cc67502b\Foo\Foo::class)->setPublic(\true); -$container->register(\_PhpScoper5ea00cc67502b\Bar\Foo::class)->setPublic(\true); -return $container; +register(\_PhpScoper5ea00cc67502b\Foo\Foo::class)->setPublic(\true); +$container->register(\_PhpScoper5ea00cc67502b\Bar\Foo::class)->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container8.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container8.php index edb43c928..ead19aad3 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container8.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container8.php @@ -1,8 +1,8 @@ - '%baz%', 'baz' => 'bar', 'bar' => 'foo is %%foo bar', 'escape' => '@escapeme', 'values' => [\true, \false, null, 0, 1000.3, 'true', 'false', 'null'], 'null string' => 'null', 'string of digits' => '123', 'string of digits prefixed with minus character' => '-123', 'true string' => 'true', 'false string' => 'false', 'binary number string' => '0b0110', 'numeric string' => '-1.2E2', 'hexadecimal number string' => '0xFF', 'float string' => '10100.1', 'positive float string' => '+10100.1', 'negative float string' => '-10100.1'])); -return $container; + '%baz%', 'baz' => 'bar', 'bar' => 'foo is %%foo bar', 'escape' => '@escapeme', 'values' => [\true, \false, null, 0, 1000.3, 'true', 'false', 'null'], 'null string' => 'null', 'string of digits' => '123', 'string of digits prefixed with minus character' => '-123', 'true string' => 'true', 'false string' => 'false', 'binary number string' => '0b0110', 'numeric string' => '-1.2E2', 'hexadecimal number string' => '0xFF', 'float string' => '10100.1', 'positive float string' => '+10100.1', 'negative float string' => '-10100.1'])); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container9.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container9.php index 4cedc76d2..6e955d658 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container9.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container9.php @@ -1,46 +1,46 @@ -register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addTag('foo', ['foo' => 'foo'])->addTag('foo', ['bar' => 'bar', 'baz' => 'baz'])->setFactory(['_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'getInstance'])->setArguments(['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), ['%foo%' => 'foo is %foo%', 'foobar' => '%foo%'], \true, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')])->setProperties(['foo' => 'bar', 'moo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'qux' => ['%foo%' => 'foo is %foo%', 'foobar' => '%foo%']])->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')])->addMethodCall('initialize')->setConfigurator('sc_configure')->setPublic(\true); -$container->register('foo.baz', '%baz_class%')->setFactory(['%baz_class%', 'getInstance'])->setConfigurator(['%baz_class%', 'configureStatic1'])->setPublic(\true); -$container->register('bar', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setArguments(['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter('foo_bar')])->setConfigurator([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'configure'])->setPublic(\true); -$container->register('foo_bar', '%foo_class%')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('deprecated_service'))->setShared(\false)->setPublic(\true); -$container->getParameterBag()->clear(); -$container->getParameterBag()->add(['baz_class' => 'BazClass', 'foo_class' => '_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'foo' => 'bar']); -$container->register('method_call1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFile(\realpath(__DIR__ . '/../includes/foo.php'))->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')])->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE)])->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo3', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)])->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobaz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)])->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')])->setPublic(\true); -$container->register('foo_with_inline', 'Foo')->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('inlined')])->setPublic(\true); -$container->register('inlined', 'Bar')->setProperty('pub', 'pub')->addMethodCall('setBaz', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')])->setPublic(\false); -$container->register('baz', 'Baz')->addMethodCall('setFoo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo_with_inline')])->setPublic(\true); -$container->register('request', 'Request')->setSynthetic(\true)->setPublic(\true); -$container->register('configurator_service', 'ConfClass')->setPublic(\false)->addMethodCall('setFoo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')]); -$container->register('configured_service', 'stdClass')->setConfigurator([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('configurator_service'), 'configureStdClass'])->setPublic(\true); -$container->register('configurator_service_simple', 'ConfClass')->addArgument('bar')->setPublic(\false); -$container->register('configured_service_simple', 'stdClass')->setConfigurator([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('configurator_service_simple'), 'configureStdClass'])->setPublic(\true); -$container->register('decorated', 'stdClass')->setPublic(\true); -$container->register('decorator_service', 'stdClass')->setDecoratedService('decorated')->setPublic(\true); -$container->register('decorator_service_with_name', 'stdClass')->setDecoratedService('decorated', 'decorated.pif-pouf')->setPublic(\true); -$container->register('deprecated_service', 'stdClass')->setDeprecated(\true)->setPublic(\true); -$container->register('new_factory', 'FactoryClass')->setProperty('foo', 'bar')->setPublic(\false); -$container->register('factory_service', 'Bar')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'getInstance'])->setPublic(\true); -$container->register('new_factory_service', 'FooBarBaz')->setProperty('foo', 'bar')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('new_factory'), 'getInstance'])->setPublic(\true); -$container->register('service_from_static_method', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFactory(['_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'getInstance'])->setPublic(\true); -$container->register('factory_simple', 'SimpleFactoryClass')->addArgument('foo')->setDeprecated(\true)->setPublic(\false); -$container->register('factory_service_simple', 'Bar')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory_simple'), 'getInstance'])->setPublic(\true); -$container->register('lazy_context', 'LazyContext')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['k1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'k2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])])->setPublic(\true); -$container->register('lazy_context_ignore_invalid_ref', 'LazyContext')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('invalid', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])])->setPublic(\true); -$container->register('tagged_iterator_foo', 'Bar')->addTag('foo')->setPublic(\false); -$container->register('tagged_iterator', 'Bar')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument('foo'))->setPublic(\true); -$container->setAlias('alias_for_foo', 'foo')->setPublic(\true); -$container->setAlias('alias_for_alias', 'alias_for_foo')->setPublic(\true); -return $container; +register('foo', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->addTag('foo', ['foo' => 'foo'])->addTag('foo', ['bar' => 'bar', 'baz' => 'baz'])->setFactory(['_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'getInstance'])->setArguments(['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), ['%foo%' => 'foo is %foo%', 'foobar' => '%foo%'], \true, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')])->setProperties(['foo' => 'bar', 'moo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'qux' => ['%foo%' => 'foo is %foo%', 'foobar' => '%foo%']])->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')])->addMethodCall('initialize')->setConfigurator('sc_configure')->setPublic(\true); +$container->register('foo.baz', '%baz_class%')->setFactory(['%baz_class%', 'getInstance'])->setConfigurator(['%baz_class%', 'configureStatic1'])->setPublic(\true); +$container->register('bar', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setArguments(['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter('foo_bar')])->setConfigurator([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'configure'])->setPublic(\true); +$container->register('foo_bar', '%foo_class%')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('deprecated_service'))->setShared(\false)->setPublic(\true); +$container->getParameterBag()->clear(); +$container->getParameterBag()->add(['baz_class' => 'BazClass', 'foo_class' => '_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'foo' => 'bar']); +$container->register('method_call1', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFile(\realpath(__DIR__ . '/../includes/foo.php'))->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')])->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::NULL_ON_INVALID_REFERENCE)])->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo3', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)])->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobaz', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)])->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')])->setPublic(\true); +$container->register('foo_with_inline', 'Foo')->addMethodCall('setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('inlined')])->setPublic(\true); +$container->register('inlined', 'Bar')->setProperty('pub', 'pub')->addMethodCall('setBaz', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')])->setPublic(\false); +$container->register('baz', 'Baz')->addMethodCall('setFoo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo_with_inline')])->setPublic(\true); +$container->register('request', 'Request')->setSynthetic(\true)->setPublic(\true); +$container->register('configurator_service', 'ConfClass')->setPublic(\false)->addMethodCall('setFoo', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')]); +$container->register('configured_service', 'stdClass')->setConfigurator([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('configurator_service'), 'configureStdClass'])->setPublic(\true); +$container->register('configurator_service_simple', 'ConfClass')->addArgument('bar')->setPublic(\false); +$container->register('configured_service_simple', 'stdClass')->setConfigurator([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('configurator_service_simple'), 'configureStdClass'])->setPublic(\true); +$container->register('decorated', 'stdClass')->setPublic(\true); +$container->register('decorator_service', 'stdClass')->setDecoratedService('decorated')->setPublic(\true); +$container->register('decorator_service_with_name', 'stdClass')->setDecoratedService('decorated', 'decorated.pif-pouf')->setPublic(\true); +$container->register('deprecated_service', 'stdClass')->setDeprecated(\true)->setPublic(\true); +$container->register('new_factory', 'FactoryClass')->setProperty('foo', 'bar')->setPublic(\false); +$container->register('factory_service', 'Bar')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'getInstance'])->setPublic(\true); +$container->register('new_factory_service', 'FooBarBaz')->setProperty('foo', 'bar')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('new_factory'), 'getInstance'])->setPublic(\true); +$container->register('service_from_static_method', '_PhpScoper5ea00cc67502b\\Bar\\FooClass')->setFactory(['_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'getInstance'])->setPublic(\true); +$container->register('factory_simple', 'SimpleFactoryClass')->addArgument('foo')->setDeprecated(\true)->setPublic(\false); +$container->register('factory_service_simple', 'Bar')->setFactory([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('factory_simple'), 'getInstance'])->setPublic(\true); +$container->register('lazy_context', 'LazyContext')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['k1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'k2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])])->setPublic(\true); +$container->register('lazy_context_ignore_invalid_ref', 'LazyContext')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('invalid', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::IGNORE_ON_INVALID_REFERENCE)]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])])->setPublic(\true); +$container->register('tagged_iterator_foo', 'Bar')->addTag('foo')->setPublic(\false); +$container->register('tagged_iterator', 'Bar')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\TaggedIteratorArgument('foo'))->setPublic(\true); +$container->setAlias('alias_for_foo', 'foo')->setPublic(\true); +$container->setAlias('alias_for_alias', 'alias_for_foo')->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_abstract.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_abstract.php index 850e52984..942594ed9 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_abstract.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_abstract.php @@ -1,8 +1,8 @@ -register('foo', 'Foo')->setAbstract(\true)->setPublic(\true); -return $container; +register('foo', 'Foo')->setAbstract(\true)->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_almost_circular.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_almost_circular.php index bbf4c736c..6e559266b 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_almost_circular.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_almost_circular.php @@ -1,62 +1,62 @@ -register('foo', \_PhpScoper5ea00cc67502b\FooCircular::class)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')); -$container->register('bar', \_PhpScoper5ea00cc67502b\BarCircular::class)->setPublic($public)->addMethodCall('addFoobar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobar')]); -$container->register('foobar', \_PhpScoper5ea00cc67502b\FoobarCircular::class)->setPublic($public)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')); -// mixed visibility for deps -$container->register('foo2', \_PhpScoper5ea00cc67502b\FooCircular::class)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar2')); -$container->register('bar2', \_PhpScoper5ea00cc67502b\BarCircular::class)->setPublic(!$public)->addMethodCall('addFoobar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobar2')]); -$container->register('foobar2', \_PhpScoper5ea00cc67502b\FoobarCircular::class)->setPublic($public)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo2')); -// simple inline setter with internal reference -$container->register('bar3', \_PhpScoper5ea00cc67502b\BarCircular::class)->setPublic(\true)->addMethodCall('addFoobar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobar3'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobar3')]); -$container->register('foobar3', \_PhpScoper5ea00cc67502b\FoobarCircular::class)->setPublic($public); -// loop with non-shared dep -$container->register('foo4', 'stdClass')->setPublic($public)->setShared(\false)->setProperty('foobar', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobar4')); -$container->register('foobar4', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo4')); -// loop on the constructor of a setter-injected dep with property -$container->register('foo5', 'stdClass')->setPublic(\true)->setProperty('bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar5')); -$container->register('bar5', 'stdClass')->setPublic($public)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo5'))->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo5')); -// doctrine-like event system + some extra -$container->register('manager', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection')); -$container->register('logger', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection'))->setProperty('handler', (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager'))); -$container->register('connection', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('dispatcher'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('config')); -$container->register('config', 'stdClass')->setPublic(\false)->setProperty('logger', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('logger')); -$container->register('dispatcher', 'stdClass')->setPublic($public)->setLazy($public)->setProperty('subscriber', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('subscriber')); -$container->register('subscriber', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager')); -// doctrine-like event system + some extra (bis) -$container->register('manager2', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection2')); -$container->register('logger2', 'stdClass')->setPublic(\false)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection2'))->setProperty('handler2', (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager2'))); -$container->register('connection2', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('dispatcher2'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('config2')); -$container->register('config2', 'stdClass')->setPublic(\false)->setProperty('logger2', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('logger2')); -$container->register('dispatcher2', 'stdClass')->setPublic($public)->setLazy($public)->setProperty('subscriber2', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('subscriber2')); -$container->register('subscriber2', 'stdClass')->setPublic(\false)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager2')); -// doctrine-like event system with listener -$container->register('manager3', 'stdClass')->setLazy(\true)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection3')); -$container->register('connection3', 'stdClass')->setPublic($public)->setProperty('listener', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('listener3')]); -$container->register('listener3', 'stdClass')->setPublic(\true)->setProperty('manager', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager3')); -// doctrine-like event system with small differences -$container->register('manager4', 'stdClass')->setLazy(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection4')); -$container->register('connection4', 'stdClass')->setPublic($public)->setProperty('listener', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('listener4')]); -$container->register('listener4', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager4')); -// private service involved in a loop -$container->register('foo6', 'stdClass')->setPublic(\true)->setProperty('bar6', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar6')); -$container->register('bar6', 'stdClass')->setPublic(\false)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo6')); -$container->register('baz6', 'stdClass')->setPublic(\true)->setProperty('bar6', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar6')); -// provided by Christian Schiffler -$container->register('root', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level2'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('multiuse1')])->setPublic(\true); -$container->register('level2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls::class)->addMethodCall('call', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level3')]); -$container->register('multiuse1', 'stdClass'); -$container->register('level3', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level4')); -$container->register('level4', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('multiuse1'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level5')]); -$container->register('level5', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level6')); -$container->register('level6', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls::class)->addMethodCall('call', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level5')]); -return $container; +register('foo', \_PhpScoper5ea00cc67502b\FooCircular::class)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar')); +$container->register('bar', \_PhpScoper5ea00cc67502b\BarCircular::class)->setPublic($public)->addMethodCall('addFoobar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobar')]); +$container->register('foobar', \_PhpScoper5ea00cc67502b\FoobarCircular::class)->setPublic($public)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo')); +// mixed visibility for deps +$container->register('foo2', \_PhpScoper5ea00cc67502b\FooCircular::class)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar2')); +$container->register('bar2', \_PhpScoper5ea00cc67502b\BarCircular::class)->setPublic(!$public)->addMethodCall('addFoobar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobar2')]); +$container->register('foobar2', \_PhpScoper5ea00cc67502b\FoobarCircular::class)->setPublic($public)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo2')); +// simple inline setter with internal reference +$container->register('bar3', \_PhpScoper5ea00cc67502b\BarCircular::class)->setPublic(\true)->addMethodCall('addFoobar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobar3'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobar3')]); +$container->register('foobar3', \_PhpScoper5ea00cc67502b\FoobarCircular::class)->setPublic($public); +// loop with non-shared dep +$container->register('foo4', 'stdClass')->setPublic($public)->setShared(\false)->setProperty('foobar', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foobar4')); +$container->register('foobar4', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo4')); +// loop on the constructor of a setter-injected dep with property +$container->register('foo5', 'stdClass')->setPublic(\true)->setProperty('bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar5')); +$container->register('bar5', 'stdClass')->setPublic($public)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo5'))->setProperty('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo5')); +// doctrine-like event system + some extra +$container->register('manager', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection')); +$container->register('logger', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection'))->setProperty('handler', (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager'))); +$container->register('connection', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('dispatcher'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('config')); +$container->register('config', 'stdClass')->setPublic(\false)->setProperty('logger', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('logger')); +$container->register('dispatcher', 'stdClass')->setPublic($public)->setLazy($public)->setProperty('subscriber', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('subscriber')); +$container->register('subscriber', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager')); +// doctrine-like event system + some extra (bis) +$container->register('manager2', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection2')); +$container->register('logger2', 'stdClass')->setPublic(\false)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection2'))->setProperty('handler2', (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager2'))); +$container->register('connection2', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('dispatcher2'))->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('config2')); +$container->register('config2', 'stdClass')->setPublic(\false)->setProperty('logger2', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('logger2')); +$container->register('dispatcher2', 'stdClass')->setPublic($public)->setLazy($public)->setProperty('subscriber2', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('subscriber2')); +$container->register('subscriber2', 'stdClass')->setPublic(\false)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager2')); +// doctrine-like event system with listener +$container->register('manager3', 'stdClass')->setLazy(\true)->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection3')); +$container->register('connection3', 'stdClass')->setPublic($public)->setProperty('listener', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('listener3')]); +$container->register('listener3', 'stdClass')->setPublic(\true)->setProperty('manager', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager3')); +// doctrine-like event system with small differences +$container->register('manager4', 'stdClass')->setLazy(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('connection4')); +$container->register('connection4', 'stdClass')->setPublic($public)->setProperty('listener', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('listener4')]); +$container->register('listener4', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('manager4')); +// private service involved in a loop +$container->register('foo6', 'stdClass')->setPublic(\true)->setProperty('bar6', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar6')); +$container->register('bar6', 'stdClass')->setPublic(\false)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo6')); +$container->register('baz6', 'stdClass')->setPublic(\true)->setProperty('bar6', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar6')); +// provided by Christian Schiffler +$container->register('root', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level2'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('multiuse1')])->setPublic(\true); +$container->register('level2', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls::class)->addMethodCall('call', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level3')]); +$container->register('multiuse1', 'stdClass'); +$container->register('level3', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level4')); +$container->register('level4', 'stdClass')->setArguments([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('multiuse1'), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level5')]); +$container->register('level5', 'stdClass')->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level6')); +$container->register('level6', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls::class)->addMethodCall('call', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('level5')]); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_env_in_id.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_env_in_id.php index d591a0a80..38ffceb2f 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_env_in_id.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_env_in_id.php @@ -1,15 +1,15 @@ -setParameter('env(BAR)', 'bar'); -$container->register('foo', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar_%env(BAR)%'))->addArgument(['baz_%env(BAR)%' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz_%env(BAR)%')]); -$container->register('bar', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar_%env(BAR)%')); -$container->register('bar_%env(BAR)%', 'stdClass')->setPublic(\false); -$container->register('baz_%env(BAR)%', 'stdClass')->setPublic(\false); -return $container; +setParameter('env(BAR)', 'bar'); +$container->register('foo', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar_%env(BAR)%'))->addArgument(['baz_%env(BAR)%' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz_%env(BAR)%')]); +$container->register('bar', 'stdClass')->setPublic(\true)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('bar_%env(BAR)%')); +$container->register('bar_%env(BAR)%', 'stdClass')->setPublic(\false); +$container->register('baz_%env(BAR)%', 'stdClass')->setPublic(\false); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_inline_requires.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_inline_requires.php index 1c7b6838f..43eae4b13 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_inline_requires.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_inline_requires.php @@ -1,16 +1,16 @@ -register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C1::class)->addTag('container.hot_path')->setPublic(\true); -$container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C2::class)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3::class))->setPublic(\true); -$container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3::class); -$container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists::class)->setPublic(\true); -return $container; +register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C1::class)->addTag('container.hot_path')->setPublic(\true); +$container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C2::class)->addArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3::class))->setPublic(\true); +$container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3::class); +$container->register(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists::class)->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_uninitialized_ref.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_uninitialized_ref.php index 1dea17f6c..75cf060f0 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_uninitialized_ref.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/container_uninitialized_ref.php @@ -1,15 +1,15 @@ -register('foo1', 'stdClass')->setPublic(\true); -$container->register('foo2', 'stdClass')->setPublic(\false); -$container->register('foo3', 'stdClass')->setPublic(\false); -$container->register('baz', 'stdClass')->setProperty('foo3', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo3'))->setPublic(\true); -$container->register('bar', 'stdClass')->setProperty('foo1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo1', $container::IGNORE_ON_UNINITIALIZED_REFERENCE))->setProperty('foo2', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo2', $container::IGNORE_ON_UNINITIALIZED_REFERENCE))->setProperty('foo3', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo3', $container::IGNORE_ON_UNINITIALIZED_REFERENCE))->setProperty('closures', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo1', $container::IGNORE_ON_UNINITIALIZED_REFERENCE)), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo2', $container::IGNORE_ON_UNINITIALIZED_REFERENCE)), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo3', $container::IGNORE_ON_UNINITIALIZED_REFERENCE))])->setProperty('iter', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['foo1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo1', $container::IGNORE_ON_UNINITIALIZED_REFERENCE), 'foo2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo2', $container::IGNORE_ON_UNINITIALIZED_REFERENCE), 'foo3' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo3', $container::IGNORE_ON_UNINITIALIZED_REFERENCE)]))->setPublic(\true); -return $container; +register('foo1', 'stdClass')->setPublic(\true); +$container->register('foo2', 'stdClass')->setPublic(\false); +$container->register('foo3', 'stdClass')->setPublic(\false); +$container->register('baz', 'stdClass')->setProperty('foo3', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo3'))->setPublic(\true); +$container->register('bar', 'stdClass')->setProperty('foo1', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo1', $container::IGNORE_ON_UNINITIALIZED_REFERENCE))->setProperty('foo2', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo2', $container::IGNORE_ON_UNINITIALIZED_REFERENCE))->setProperty('foo3', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo3', $container::IGNORE_ON_UNINITIALIZED_REFERENCE))->setProperty('closures', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo1', $container::IGNORE_ON_UNINITIALIZED_REFERENCE)), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo2', $container::IGNORE_ON_UNINITIALIZED_REFERENCE)), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\ServiceClosureArgument(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo3', $container::IGNORE_ON_UNINITIALIZED_REFERENCE))])->setProperty('iter', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['foo1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo1', $container::IGNORE_ON_UNINITIALIZED_REFERENCE), 'foo2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo2', $container::IGNORE_ON_UNINITIALIZED_REFERENCE), 'foo3' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo3', $container::IGNORE_ON_UNINITIALIZED_REFERENCE)]))->setPublic(\true); +return $container; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/containers/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/containers/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/import.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/import.yml index 35ec4a042..db0b28c27 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/import.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/import.yml @@ -1,2 +1,2 @@ -imports: - - { resource: ../recurse/ } +imports: + - { resource: ../recurse/ } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/import/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/simple.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/simple.ini index 0984cdac7..c55a6923c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/simple.ini +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/simple.ini @@ -1,2 +1,2 @@ -[parameters] - ini = ini +[parameters] + ini = ini diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/simple.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/simple.yml index f98ef12ea..59f90c10c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/simple.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/recurse/simple.yml @@ -1,2 +1,2 @@ -parameters: - yaml: yaml +parameters: + yaml: yaml diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/simple.php b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/simple.php index c214562b8..64ac213a2 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/directory/simple.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/directory/simple.php @@ -1,5 +1,5 @@ -setParameter('php', 'php'); +setParameter('php', 'php'); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services1.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services1.dot index e74010809..6bca57899 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services1.dot +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services1.dot @@ -1,7 +1,7 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; -} +digraph sc { + ratio="compress" + node [fontsize="11" fontname="Arial" shape="record"]; + edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; + + node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10-1.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10-1.dot index 9fdf34106..129b38b2e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10-1.dot +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10-1.dot @@ -1,10 +1,10 @@ -digraph sc { - ratio="normal" - node [fontsize="13" fontname="Verdana" shape="square"]; - edge [fontsize="12" fontname="Verdana" color="white" arrowhead="closed" arrowsize="1"]; - - node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=square, fillcolor="grey", style="filled"]; - node_foo [label="foo\nFooClass\n", shape=square, fillcolor="grey", style="filled"]; - node_bar [label="bar\n\n", shape=square, fillcolor="red", style="empty"]; - node_foo -> node_bar [label="" style="filled"]; -} +digraph sc { + ratio="normal" + node [fontsize="13" fontname="Verdana" shape="square"]; + edge [fontsize="12" fontname="Verdana" color="white" arrowhead="closed" arrowsize="1"]; + + node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=square, fillcolor="grey", style="filled"]; + node_foo [label="foo\nFooClass\n", shape=square, fillcolor="grey", style="filled"]; + node_bar [label="bar\n\n", shape=square, fillcolor="red", style="empty"]; + node_foo -> node_bar [label="" style="filled"]; +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10.dot index 309388eac..05f75bdee 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10.dot +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services10.dot @@ -1,10 +1,10 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo [label="foo\nFooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_bar [label="bar\n\n", shape=record, fillcolor="#ff9999", style="filled"]; - node_foo -> node_bar [label="" style="filled"]; -} +digraph sc { + ratio="compress" + node [fontsize="11" fontname="Arial" shape="record"]; + edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; + + node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo [label="foo\nFooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_bar [label="bar\n\n", shape=record, fillcolor="#ff9999", style="filled"]; + node_foo -> node_bar [label="" style="filled"]; +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services13.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services13.dot index fffe8f1b5..9520150fe 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services13.dot +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services13.dot @@ -1,10 +1,10 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo [label="foo\nFooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_bar [label="bar\nBarClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo -> node_bar [label="" style="filled"]; -} +digraph sc { + ratio="compress" + node [fontsize="11" fontname="Arial" shape="record"]; + edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; + + node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo [label="foo\nFooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_bar [label="bar\nBarClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo -> node_bar [label="" style="filled"]; +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services14.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services14.dot index e74010809..6bca57899 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services14.dot +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services14.dot @@ -1,7 +1,7 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; -} +digraph sc { + ratio="compress" + node [fontsize="11" fontname="Arial" shape="record"]; + edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; + + node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services17.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services17.dot index e177fae2a..a14a6ed79 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services17.dot +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services17.dot @@ -1,8 +1,8 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo [label="foo\n%foo.class%\n", shape=record, fillcolor="#eeeeee", style="filled"]; -} +digraph sc { + ratio="compress" + node [fontsize="11" fontname="Arial" shape="record"]; + edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; + + node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo [label="foo\n%foo.class%\n", shape=record, fillcolor="#eeeeee", style="filled"]; +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services18.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services18.dot index 4fbcceef3..8dcf673fb 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services18.dot +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services18.dot @@ -1,8 +1,8 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_foo [label="foo\nFooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerBuilder\n", shape=record, fillcolor="#9999ff", style="filled"]; -} +digraph sc { + ratio="compress" + node [fontsize="11" fontname="Arial" shape="record"]; + edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; + + node_foo [label="foo\nFooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_service_container [label="service_container\nSymfony\\Component\\DependencyInjection\\ContainerBuilder\n", shape=record, fillcolor="#9999ff", style="filled"]; +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services9.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services9.dot index 6a34c5735..c71101434 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services9.dot +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services9.dot @@ -1,56 +1,56 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo [label="foo (alias_for_foo)\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo_baz [label="foo.baz\nBazClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_bar [label="bar\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo_bar [label="foo_bar\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="dotted"]; - node_method_call1 [label="method_call1\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo_with_inline [label="foo_with_inline\nFoo\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_inlined [label="inlined\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_baz [label="baz\nBaz\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_request [label="request\nRequest\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_configurator_service [label="configurator_service\nConfClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_configured_service [label="configured_service\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_configurator_service_simple [label="configurator_service_simple\nConfClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_configured_service_simple [label="configured_service_simple\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_decorated [label="decorated\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_decorator_service [label="decorator_service\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_decorator_service_with_name [label="decorator_service_with_name\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_deprecated_service [label="deprecated_service\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_new_factory [label="new_factory\nFactoryClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_factory_service [label="factory_service\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_new_factory_service [label="new_factory_service\nFooBarBaz\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_service_from_static_method [label="service_from_static_method\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_factory_simple [label="factory_simple\nSimpleFactoryClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_factory_service_simple [label="factory_service_simple\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_lazy_context [label="lazy_context\nLazyContext\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_lazy_context_ignore_invalid_ref [label="lazy_context_ignore_invalid_ref\nLazyContext\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_tagged_iterator_foo [label="tagged_iterator_foo\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_tagged_iterator [label="tagged_iterator\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo2 [label="foo2\n\n", shape=record, fillcolor="#ff9999", style="filled"]; - node_foo3 [label="foo3\n\n", shape=record, fillcolor="#ff9999", style="filled"]; - node_foobaz [label="foobaz\n\n", shape=record, fillcolor="#ff9999", style="filled"]; - node_invalid [label="invalid\n\n", shape=record, fillcolor="#ff9999", style="filled"]; - node_foo -> node_foo_baz [label="" style="filled"]; - node_foo -> node_service_container [label="" style="filled"]; - node_foo -> node_foo_baz [label="" style="dashed"]; - node_foo -> node_bar [label="setBar()" style="dashed"]; - node_bar -> node_foo_baz [label="" style="filled"]; - node_foo_bar -> node_deprecated_service [label="" style="filled"]; - node_method_call1 -> node_foo [label="setBar()" style="dashed"]; - node_method_call1 -> node_foo2 [label="setBar()" style="dashed"]; - node_method_call1 -> node_foo3 [label="setBar()" style="dashed"]; - node_method_call1 -> node_foobaz [label="setBar()" style="dashed"]; - node_foo_with_inline -> node_inlined [label="setBar()" style="dashed"]; - node_inlined -> node_baz [label="setBaz()" style="dashed"]; - node_baz -> node_foo_with_inline [label="setFoo()" style="dashed"]; - node_configurator_service -> node_baz [label="setFoo()" style="dashed"]; - node_lazy_context -> node_foo_baz [label="" style="filled" color="#9999ff"]; - node_lazy_context -> node_service_container [label="" style="filled" color="#9999ff"]; - node_lazy_context_ignore_invalid_ref -> node_foo_baz [label="" style="filled" color="#9999ff"]; - node_lazy_context_ignore_invalid_ref -> node_invalid [label="" style="filled" color="#9999ff"]; -} +digraph sc { + ratio="compress" + node [fontsize="11" fontname="Arial" shape="record"]; + edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; + + node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo [label="foo (alias_for_foo)\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo_baz [label="foo.baz\nBazClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_bar [label="bar\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo_bar [label="foo_bar\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="dotted"]; + node_method_call1 [label="method_call1\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo_with_inline [label="foo_with_inline\nFoo\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_inlined [label="inlined\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_baz [label="baz\nBaz\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_request [label="request\nRequest\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_configurator_service [label="configurator_service\nConfClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_configured_service [label="configured_service\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_configurator_service_simple [label="configurator_service_simple\nConfClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_configured_service_simple [label="configured_service_simple\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_decorated [label="decorated\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_decorator_service [label="decorator_service\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_decorator_service_with_name [label="decorator_service_with_name\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_deprecated_service [label="deprecated_service\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_new_factory [label="new_factory\nFactoryClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_factory_service [label="factory_service\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_new_factory_service [label="new_factory_service\nFooBarBaz\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_service_from_static_method [label="service_from_static_method\nBar\\FooClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_factory_simple [label="factory_simple\nSimpleFactoryClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_factory_service_simple [label="factory_service_simple\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_lazy_context [label="lazy_context\nLazyContext\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_lazy_context_ignore_invalid_ref [label="lazy_context_ignore_invalid_ref\nLazyContext\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_tagged_iterator_foo [label="tagged_iterator_foo\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_tagged_iterator [label="tagged_iterator\nBar\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo2 [label="foo2\n\n", shape=record, fillcolor="#ff9999", style="filled"]; + node_foo3 [label="foo3\n\n", shape=record, fillcolor="#ff9999", style="filled"]; + node_foobaz [label="foobaz\n\n", shape=record, fillcolor="#ff9999", style="filled"]; + node_invalid [label="invalid\n\n", shape=record, fillcolor="#ff9999", style="filled"]; + node_foo -> node_foo_baz [label="" style="filled"]; + node_foo -> node_service_container [label="" style="filled"]; + node_foo -> node_foo_baz [label="" style="dashed"]; + node_foo -> node_bar [label="setBar()" style="dashed"]; + node_bar -> node_foo_baz [label="" style="filled"]; + node_foo_bar -> node_deprecated_service [label="" style="filled"]; + node_method_call1 -> node_foo [label="setBar()" style="dashed"]; + node_method_call1 -> node_foo2 [label="setBar()" style="dashed"]; + node_method_call1 -> node_foo3 [label="setBar()" style="dashed"]; + node_method_call1 -> node_foobaz [label="setBar()" style="dashed"]; + node_foo_with_inline -> node_inlined [label="setBar()" style="dashed"]; + node_inlined -> node_baz [label="setBaz()" style="dashed"]; + node_baz -> node_foo_with_inline [label="setFoo()" style="dashed"]; + node_configurator_service -> node_baz [label="setFoo()" style="dashed"]; + node_lazy_context -> node_foo_baz [label="" style="filled" color="#9999ff"]; + node_lazy_context -> node_service_container [label="" style="filled" color="#9999ff"]; + node_lazy_context_ignore_invalid_ref -> node_foo_baz [label="" style="filled" color="#9999ff"]; + node_lazy_context_ignore_invalid_ref -> node_invalid [label="" style="filled" color="#9999ff"]; +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services_inline.dot b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services_inline.dot index b430b186d..694a6e041 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services_inline.dot +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/graphviz/services_inline.dot @@ -1,10 +1,10 @@ -digraph sc { - ratio="compress" - node [fontsize="11" fontname="Arial" shape="record"]; - edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; - - node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo [label="foo\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_bar [label="bar\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; - node_foo -> node_bar [label="" style="filled"]; -} +digraph sc { + ratio="compress" + node [fontsize="11" fontname="Arial" shape="record"]; + edge [fontsize="9" fontname="Arial" color="grey" arrowhead="open" arrowsize="0.5"]; + + node_service_container [label="service_container (Psr\Container\ContainerInterface, Symfony\Component\DependencyInjection\ContainerInterface)\nSymfony\\Component\\DependencyInjection\\ContainerInterface\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo [label="foo\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_bar [label="bar\nstdClass\n", shape=record, fillcolor="#eeeeee", style="filled"]; + node_foo -> node_bar [label="" style="filled"]; +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/FooVariadic.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/FooVariadic.php index fcd851aa1..9062886e3 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/FooVariadic.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/FooVariadic.php @@ -1,14 +1,14 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectExtension.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectExtension.php index d1ef2707c..a2703d118 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectExtension.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectExtension.php @@ -1,41 +1,41 @@ -setParameter('project.configs', $configs); - $configs = \array_filter($configs); - if ($configs) { - $config = \call_user_func_array('array_merge', $configs); - } else { - $config = []; - } - $configuration->setDefinition('project.service.bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooClass')); - $configuration->setParameter('project.parameter.bar', isset($config['foo']) ? $config['foo'] : 'foobar'); - $configuration->setDefinition('project.service.foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooClass')); - $configuration->setParameter('project.parameter.foo', isset($config['foo']) ? $config['foo'] : 'foobar'); - return $configuration; - } - public function getXsdValidationBasePath() - { - return \false; - } - public function getNamespace() - { - return 'http://www.example.com/schema/project'; - } - public function getAlias() - { - return 'project'; - } - public function getConfiguration(array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) - { - } -} -\class_alias('_PhpScoper5ea00cc67502b\\ProjectExtension', 'ProjectExtension', \false); +setParameter('project.configs', $configs); + $configs = \array_filter($configs); + if ($configs) { + $config = \call_user_func_array('array_merge', $configs); + } else { + $config = []; + } + $configuration->setDefinition('project.service.bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooClass')); + $configuration->setParameter('project.parameter.bar', isset($config['foo']) ? $config['foo'] : 'foobar'); + $configuration->setDefinition('project.service.foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('FooClass')); + $configuration->setParameter('project.parameter.foo', isset($config['foo']) ? $config['foo'] : 'foobar'); + return $configuration; + } + public function getXsdValidationBasePath() + { + return \false; + } + public function getNamespace() + { + return 'http://www.example.com/schema/project'; + } + public function getAlias() + { + return 'project'; + } + public function getConfiguration(array $config, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder $container) + { + } +} +\class_alias('_PhpScoper5ea00cc67502b\\ProjectExtension', 'ProjectExtension', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectWithXsdExtension.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectWithXsdExtension.php index 034ec9c4f..ced19b33e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectWithXsdExtension.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/ProjectWithXsdExtension.php @@ -1,20 +1,20 @@ - prefix is on purpose */ - public function setWithCallsConfigured(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A $a) - { - } - /** @required */ - public function setChildMethodWithoutDocBlock(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A $a) - { - } -} -class NotWireable -{ - public function setNotAutowireable(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotARealClass $n) - { - } - public function setBar() - { - } - public function setOptionalNotAutowireable(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotARealClass $n = null) - { - } - public function setDifferentNamespace(\stdClass $n) - { - } - public function setOptionalNoTypeHint($foo = null) - { - } - public function setOptionalArgNoAutowireable($other = 'default_val') - { - } - /** @required */ - protected function setProtectedMethod(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A $a) - { - } -} -class PrivateConstructor -{ - private function __construct() - { - } -} -class ScalarSetter -{ - /** - * @required - */ - public function setDefaultLocale($defaultLocale) - { - } -} + prefix is on purpose */ + public function setWithCallsConfigured(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A $a) + { + } + /** @required */ + public function setChildMethodWithoutDocBlock(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A $a) + { + } +} +class NotWireable +{ + public function setNotAutowireable(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotARealClass $n) + { + } + public function setBar() + { + } + public function setOptionalNotAutowireable(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\NotARealClass $n = null) + { + } + public function setDifferentNamespace(\stdClass $n) + { + } + public function setOptionalNoTypeHint($foo = null) + { + } + public function setOptionalArgNoAutowireable($other = 'default_val') + { + } + /** @required */ + protected function setProtectedMethod(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\A $a) + { + } +} +class PrivateConstructor +{ + private function __construct() + { + } +} +class ScalarSetter +{ + /** + * @required + */ + public function setDefaultLocale($defaultLocale) + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/classes.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/classes.php index e200e71ea..fa4088fab 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/classes.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/classes.php @@ -1,124 +1,124 @@ -configure(); -} -class BarClass extends \_PhpScoper5ea00cc67502b\BazClass -{ - protected $baz; - public $foo = 'foo'; - public function setBaz(\_PhpScoper5ea00cc67502b\BazClass $baz) - { - $this->baz = $baz; - } - public function getBaz() - { - return $this->baz; - } -} -\class_alias('_PhpScoper5ea00cc67502b\\BarClass', 'BarClass', \false); -class BazClass -{ - protected $foo; - public function setFoo(\_PhpScoper5ea00cc67502b\Foo $foo) - { - $this->foo = $foo; - } - public function configure($instance) - { - $instance->configure(); - } - public static function getInstance() - { - return new self(); - } - public static function configureStatic($instance) - { - $instance->configure(); - } - public static function configureStatic1() - { - } -} -\class_alias('_PhpScoper5ea00cc67502b\\BazClass', 'BazClass', \false); -class BarUserClass -{ - public $bar; - public function __construct(\_PhpScoper5ea00cc67502b\BarClass $bar) - { - $this->bar = $bar; - } -} -\class_alias('_PhpScoper5ea00cc67502b\\BarUserClass', 'BarUserClass', \false); -class MethodCallClass -{ - public $simple; - public $complex; - private $callPassed = \false; - public function callMe() - { - $this->callPassed = \is_scalar($this->simple) && \is_object($this->complex); - } - public function callPassed() - { - return $this->callPassed; - } -} -\class_alias('_PhpScoper5ea00cc67502b\\MethodCallClass', 'MethodCallClass', \false); -class DummyProxyDumper implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface -{ - public function isProxyCandidate(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - return $definition->isLazy(); - } - public function getProxyFactoryCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id, $factoryCall = null) - { - return " // lazy factory for {$definition->getClass()}\n\n"; - } - public function getProxyCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) - { - return "// proxy code for {$definition->getClass()}\n"; - } -} -\class_alias('_PhpScoper5ea00cc67502b\\DummyProxyDumper', 'DummyProxyDumper', \false); -class LazyContext -{ - public $lazyValues; - public $lazyEmptyValues; - public function __construct($lazyValues, $lazyEmptyValues) - { - $this->lazyValues = $lazyValues; - $this->lazyEmptyValues = $lazyEmptyValues; - } -} -\class_alias('_PhpScoper5ea00cc67502b\\LazyContext', 'LazyContext', \false); -class FoobarCircular -{ - public function __construct(\_PhpScoper5ea00cc67502b\FooCircular $foo) - { - $this->foo = $foo; - } -} -\class_alias('_PhpScoper5ea00cc67502b\\FoobarCircular', 'FoobarCircular', \false); -class FooCircular -{ - public function __construct(\_PhpScoper5ea00cc67502b\BarCircular $bar) - { - $this->bar = $bar; - } -} -\class_alias('_PhpScoper5ea00cc67502b\\FooCircular', 'FooCircular', \false); -class BarCircular -{ - public function addFoobar(\_PhpScoper5ea00cc67502b\FoobarCircular $foobar) - { - $this->foobar = $foobar; - } -} -\class_alias('_PhpScoper5ea00cc67502b\\BarCircular', 'BarCircular', \false); +configure(); +} +class BarClass extends \_PhpScoper5ea00cc67502b\BazClass +{ + protected $baz; + public $foo = 'foo'; + public function setBaz(\_PhpScoper5ea00cc67502b\BazClass $baz) + { + $this->baz = $baz; + } + public function getBaz() + { + return $this->baz; + } +} +\class_alias('_PhpScoper5ea00cc67502b\\BarClass', 'BarClass', \false); +class BazClass +{ + protected $foo; + public function setFoo(\_PhpScoper5ea00cc67502b\Foo $foo) + { + $this->foo = $foo; + } + public function configure($instance) + { + $instance->configure(); + } + public static function getInstance() + { + return new self(); + } + public static function configureStatic($instance) + { + $instance->configure(); + } + public static function configureStatic1() + { + } +} +\class_alias('_PhpScoper5ea00cc67502b\\BazClass', 'BazClass', \false); +class BarUserClass +{ + public $bar; + public function __construct(\_PhpScoper5ea00cc67502b\BarClass $bar) + { + $this->bar = $bar; + } +} +\class_alias('_PhpScoper5ea00cc67502b\\BarUserClass', 'BarUserClass', \false); +class MethodCallClass +{ + public $simple; + public $complex; + private $callPassed = \false; + public function callMe() + { + $this->callPassed = \is_scalar($this->simple) && \is_object($this->complex); + } + public function callPassed() + { + return $this->callPassed; + } +} +\class_alias('_PhpScoper5ea00cc67502b\\MethodCallClass', 'MethodCallClass', \false); +class DummyProxyDumper implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\DumperInterface +{ + public function isProxyCandidate(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + return $definition->isLazy(); + } + public function getProxyFactoryCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition, $id, $factoryCall = null) + { + return " // lazy factory for {$definition->getClass()}\n\n"; + } + public function getProxyCode(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition $definition) + { + return "// proxy code for {$definition->getClass()}\n"; + } +} +\class_alias('_PhpScoper5ea00cc67502b\\DummyProxyDumper', 'DummyProxyDumper', \false); +class LazyContext +{ + public $lazyValues; + public $lazyEmptyValues; + public function __construct($lazyValues, $lazyEmptyValues) + { + $this->lazyValues = $lazyValues; + $this->lazyEmptyValues = $lazyEmptyValues; + } +} +\class_alias('_PhpScoper5ea00cc67502b\\LazyContext', 'LazyContext', \false); +class FoobarCircular +{ + public function __construct(\_PhpScoper5ea00cc67502b\FooCircular $foo) + { + $this->foo = $foo; + } +} +\class_alias('_PhpScoper5ea00cc67502b\\FoobarCircular', 'FoobarCircular', \false); +class FooCircular +{ + public function __construct(\_PhpScoper5ea00cc67502b\BarCircular $bar) + { + $this->bar = $bar; + } +} +\class_alias('_PhpScoper5ea00cc67502b\\FooCircular', 'FooCircular', \false); +class BarCircular +{ + public function addFoobar(\_PhpScoper5ea00cc67502b\FoobarCircular $foobar) + { + $this->foobar = $foobar; + } +} +\class_alias('_PhpScoper5ea00cc67502b\\BarCircular', 'BarCircular', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/createphar.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/createphar.php index e3ef91697..d2b73f009 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/createphar.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/createphar.php @@ -1,49 +1,49 @@ -addFromString('ProjectWithXsdExtensionInPhar.php', <<<'EOT' -addFromString('schema/project-1.0.xsd', <<<'EOT' - - - - - - - - - - -EOT -); -$phar->setStub(''); +addFromString('ProjectWithXsdExtensionInPhar.php', <<<'EOT' +addFromString('schema/project-1.0.xsd', <<<'EOT' + + + + + + + + + + +EOT +); +$phar->setStub(''); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/foo.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/foo.php index fdb938a7d..f1a417a1c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/foo.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/foo.php @@ -1,36 +1,36 @@ -arguments = $arguments; - } - public static function getInstance($arguments = []) - { - $obj = new self($arguments); - $obj->called = \true; - return $obj; - } - public function initialize() - { - $this->initialized = \true; - } - public function configure() - { - $this->configured = \true; - } - public function setBar($value = null) - { - $this->bar = $value; - } -} +arguments = $arguments; + } + public static function getInstance($arguments = []) + { + $obj = new self($arguments); + $obj->called = \true; + return $obj; + } + public function initialize() + { + $this->initialized = \true; + } + public function configure() + { + $this->configured = \true; + } + public function setBar($value = null) + { + $this->bar = $value; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/project-1.0.xsd b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/project-1.0.xsd index 282884e4e..b59969759 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/project-1.0.xsd +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/includes/schema/project-1.0.xsd @@ -1,13 +1,13 @@ - - - - - - - - - - + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/almostvalid.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/almostvalid.ini index 9fdef8558..0a49335b2 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/almostvalid.ini +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/almostvalid.ini @@ -1,2 +1,2 @@ -foo = ' -bar = bar +foo = ' +bar = bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/ini_with_wrong_ext.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/ini_with_wrong_ext.xml index 7f1b4d3dc..0b0edf201 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/ini_with_wrong_ext.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/ini_with_wrong_ext.xml @@ -1,2 +1,2 @@ -[parameters] - with_wrong_ext = 'from ini' +[parameters] + with_wrong_ext = 'from ini' diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/nonvalid.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/nonvalid.ini index 9f84a6087..3f74f80a1 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/nonvalid.ini +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/nonvalid.ini @@ -1,2 +1,2 @@ -{NOT AN INI FILE} -{JUST A PLAIN TEXT FILE} +{NOT AN INI FILE} +{JUST A PLAIN TEXT FILE} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters.ini index df92f7527..b3789df2f 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters.ini +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters.ini @@ -1,3 +1,3 @@ -[parameters] - foo = bar - bar = %foo% +[parameters] + foo = bar + bar = %foo% diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters1.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters1.ini index e50f7222b..7f106eea3 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters1.ini +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters1.ini @@ -1,3 +1,3 @@ -[parameters] - FOO = foo - baz = baz +[parameters] + FOO = foo + baz = baz diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters2.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters2.ini index 75fbac628..eca128444 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters2.ini +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/parameters2.ini @@ -1,2 +1,2 @@ -[parameters] - imported_from_ini = true +[parameters] + imported_from_ini = true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/types.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/types.ini index 75840907d..771c23e7e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/ini/types.ini +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/ini/types.ini @@ -1,28 +1,28 @@ -[parameters] - true = true - true_comment = true ; comment - false = false - null = null - on = on - off = off - yes = yes - no = no - none = none - constant = PHP_VERSION - 12 = 12 - 12_string = '12' - 12_quoted_number = "12" - 12_comment = 12 ; comment - 12_string_comment = '12' ; comment - 12_quoted_number_comment = "12" ; comment - -12 = -12 - 0 = 0 - 1 = 1 - 0b0110 = 0b0110 - 11112222333344445555 = 1111,2222,3333,4444,5555 - 0777 = 0777 - 255 = 0xFF - 100.0 = 1e2 - -120.0 = -1.2E2 - -10100.1 = -10100.1 - -10,100.1 = -10,100.1 +[parameters] + true = true + true_comment = true ; comment + false = false + null = null + on = on + off = off + yes = yes + no = no + none = none + constant = PHP_VERSION + 12 = 12 + 12_string = '12' + 12_quoted_number = "12" + 12_comment = 12 ; comment + 12_string_comment = '12' ; comment + 12_quoted_number_comment = "12" ; comment + -12 = -12 + 0 = 0 + 1 = 1 + 0b0110 = 0b0110 + 11112222333344445555 = 1111,2222,3333,4444,5555 + 0777 = 0777 + 255 = 0xFF + 100.0 = 1e2 + -120.0 = -1.2E2 + -10100.1 = -10100.1 + -10,100.1 = -10,100.1 diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_constructor_without_arguments.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_constructor_without_arguments.php index e7542d193..50e4d1cc5 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_constructor_without_arguments.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_constructor_without_arguments.php @@ -1,46 +1,46 @@ -parameterBag = null; - $this->services = []; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } -} +parameterBag = null; + $this->services = []; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_with_mandatory_constructor_arguments.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_with_mandatory_constructor_arguments.php index 4cf10ca4b..014c18a9c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_with_mandatory_constructor_arguments.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_with_mandatory_constructor_arguments.php @@ -1,44 +1,44 @@ -services = []; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } -} +services = []; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_with_optional_constructor_arguments.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_with_optional_constructor_arguments.php index 6cea63e2a..fc17fd1c8 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_with_optional_constructor_arguments.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_with_optional_constructor_arguments.php @@ -1,46 +1,46 @@ -parameterBag = null; - $this->services = []; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } -} +parameterBag = null; + $this->services = []; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_without_constructor.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_without_constructor.php index f35a26bcb..923fa4d60 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_without_constructor.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/custom_container_class_without_constructor.php @@ -1,44 +1,44 @@ -services = []; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } -} +services = []; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/php_with_wrong_ext.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/php/php_with_wrong_ext.yml index fdd312501..44e02c1e9 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/php_with_wrong_ext.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/php_with_wrong_ext.yml @@ -1,3 +1,3 @@ -setParameter('with_wrong_ext', 'from php'); +setParameter('with_wrong_ext', 'from php'); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1-1.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1-1.php index fb37efbcb..3fbfeeb60 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1-1.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1-1.php @@ -1,44 +1,44 @@ -services = []; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } -} +services = []; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1.php index f19b6e642..0ae3af89e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services1.php @@ -1,51 +1,51 @@ -services = []; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +services = []; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services10.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services10.php index 435d8901c..a89d7bdb7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services10.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services10.php @@ -1,134 +1,134 @@ -parameters = $this->getDefaultParameters(); - $this->services = []; - $this->methodMap = ['test' => 'getTestService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'test' shared service. - * - * @return \stdClass - */ - protected function getTestService() - { - return $this->services['test'] = new \stdClass(['only dot' => '.', 'concatenation as value' => '.\'\'.', 'concatenation from the start value' => '\'\'.', '.' => 'dot as a key', '.\'\'.' => 'concatenation as a key', '\'\'.' => 'concatenation from the start key', 'optimize concatenation' => 'string1-string2', 'optimize concatenation with empty string' => 'string1string2', 'optimize concatenation from the start' => 'start', 'optimize concatenation at the end' => 'end', 'new line' => 'string with ' . "\n" . 'new line']); - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = []; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - private $normalizedParameterNames = []; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['empty_value' => '', 'some_string' => '-']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +parameters = $this->getDefaultParameters(); + $this->services = []; + $this->methodMap = ['test' => 'getTestService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'test' shared service. + * + * @return \stdClass + */ + protected function getTestService() + { + return $this->services['test'] = new \stdClass(['only dot' => '.', 'concatenation as value' => '.\'\'.', 'concatenation from the start value' => '\'\'.', '.' => 'dot as a key', '.\'\'.' => 'concatenation as a key', '\'\'.' => 'concatenation from the start key', 'optimize concatenation' => 'string1-string2', 'optimize concatenation with empty string' => 'string1string2', 'optimize concatenation from the start' => 'start', 'optimize concatenation at the end' => 'end', 'new line' => 'string with ' . "\n" . 'new line']); + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = []; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + private $normalizedParameterNames = []; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['empty_value' => '', 'some_string' => '-']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services12.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services12.php index a0957bfc9..37fa5f0e2 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services12.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services12.php @@ -1,149 +1,149 @@ -targetDirs[$i] = $dir = \dirname($dir); - } - $this->parameters = $this->getDefaultParameters(); - $this->services = []; - $this->methodMap = ['test' => 'getTestService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'test' shared service. - * - * @return \stdClass - */ - protected function getTestService() - { - return $this->services['test'] = new \stdClass('wiz' . $this->targetDirs[1], ['wiz' . $this->targetDirs[1] => $this->targetDirs[2] . '/']); - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = ['foo' => \false, 'buz' => \false]; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - switch ($name) { - case 'foo': - $value = 'wiz' . $this->targetDirs[1]; - break; - case 'buz': - $value = $this->targetDirs[2]; - break; - default: - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - $this->loadedDynamicParameters[$name] = \true; - return $this->dynamicParameters[$name] = $value; - } - private $normalizedParameterNames = []; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['bar' => __DIR__, 'baz' => __DIR__ . '/PhpDumperTest.php']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +targetDirs[$i] = $dir = \dirname($dir); + } + $this->parameters = $this->getDefaultParameters(); + $this->services = []; + $this->methodMap = ['test' => 'getTestService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'test' shared service. + * + * @return \stdClass + */ + protected function getTestService() + { + return $this->services['test'] = new \stdClass('wiz' . $this->targetDirs[1], ['wiz' . $this->targetDirs[1] => $this->targetDirs[2] . '/']); + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = ['foo' => \false, 'buz' => \false]; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + switch ($name) { + case 'foo': + $value = 'wiz' . $this->targetDirs[1]; + break; + case 'buz': + $value = $this->targetDirs[2]; + break; + default: + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + $this->loadedDynamicParameters[$name] = \true; + return $this->dynamicParameters[$name] = $value; + } + private $normalizedParameterNames = []; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['bar' => __DIR__, 'baz' => __DIR__ . '/PhpDumperTest.php']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services13.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services13.php index 0cf165455..23a97c49c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services13.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services13.php @@ -1,63 +1,63 @@ -services = []; - $this->methodMap = ['bar' => 'getBarService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'foo' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar' shared service. - * - * @return \stdClass - */ - protected function getBarService() - { - $a = new \stdClass(); - $a->add($this); - return $this->services['bar'] = new \stdClass($a); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +services = []; + $this->methodMap = ['bar' => 'getBarService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'foo' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar' shared service. + * + * @return \stdClass + */ + protected function getBarService() + { + $a = new \stdClass(); + $a->add($this); + return $this->services['bar'] = new \stdClass($a); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services19.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services19.php index eb672192c..c3b0b25b2 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services19.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services19.php @@ -1,153 +1,153 @@ -parameters = $this->getDefaultParameters(); - $this->services = []; - $this->methodMap = ['service_from_anonymous_factory' => 'getServiceFromAnonymousFactoryService', 'service_with_method_call_and_factory' => 'getServiceWithMethodCallAndFactoryService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'service_from_anonymous_factory' shared service. - * - * @return object A %env(FOO)% instance - */ - protected function getServiceFromAnonymousFactoryService() - { - return $this->services['service_from_anonymous_factory'] = (new ${($_ = $this->getEnv('FOO')) && \false ?: "_"}())->getInstance(); - } - /** - * Gets the public 'service_with_method_call_and_factory' shared service. - * - * @return \Bar\FooClass - */ - protected function getServiceWithMethodCallAndFactoryService() - { - $this->services['service_with_method_call_and_factory'] = $instance = new \_PhpScoper5ea00cc67502b\Bar\FooClass(); - $instance->setBar(\_PhpScoper5ea00cc67502b\Bar\FooClass::getInstance()); - return $instance; - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = ['foo' => \false]; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - switch ($name) { - case 'foo': - $value = $this->getEnv('FOO'); - break; - default: - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - $this->loadedDynamicParameters[$name] = \true; - return $this->dynamicParameters[$name] = $value; - } - private $normalizedParameterNames = ['env(foo)' => 'env(FOO)']; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['env(FOO)' => '_PhpScoper5ea00cc67502b\\Bar\\FaooClass']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +parameters = $this->getDefaultParameters(); + $this->services = []; + $this->methodMap = ['service_from_anonymous_factory' => 'getServiceFromAnonymousFactoryService', 'service_with_method_call_and_factory' => 'getServiceWithMethodCallAndFactoryService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'service_from_anonymous_factory' shared service. + * + * @return object A %env(FOO)% instance + */ + protected function getServiceFromAnonymousFactoryService() + { + return $this->services['service_from_anonymous_factory'] = (new ${($_ = $this->getEnv('FOO')) && \false ?: "_"}())->getInstance(); + } + /** + * Gets the public 'service_with_method_call_and_factory' shared service. + * + * @return \Bar\FooClass + */ + protected function getServiceWithMethodCallAndFactoryService() + { + $this->services['service_with_method_call_and_factory'] = $instance = new \_PhpScoper5ea00cc67502b\Bar\FooClass(); + $instance->setBar(\_PhpScoper5ea00cc67502b\Bar\FooClass::getInstance()); + return $instance; + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = ['foo' => \false]; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + switch ($name) { + case 'foo': + $value = $this->getEnv('FOO'); + break; + default: + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + $this->loadedDynamicParameters[$name] = \true; + return $this->dynamicParameters[$name] = $value; + } + private $normalizedParameterNames = ['env(foo)' => 'env(FOO)']; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['env(FOO)' => '_PhpScoper5ea00cc67502b\\Bar\\FaooClass']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services24.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services24.php index 6d545b587..2ec3648de 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services24.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services24.php @@ -1,61 +1,61 @@ -services = []; - $this->methodMap = ['foo' => 'getFooService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'foo' shared autowired service. - * - * @return \Foo - */ - protected function getFooService() - { - return $this->services['foo'] = new \_PhpScoper5ea00cc67502b\Foo(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +services = []; + $this->methodMap = ['foo' => 'getFooService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'foo' shared autowired service. + * + * @return \Foo + */ + protected function getFooService() + { + return $this->services['foo'] = new \_PhpScoper5ea00cc67502b\Foo(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services26.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services26.php index 8c6293e55..0714794f1 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services26.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services26.php @@ -1,168 +1,168 @@ -targetDirs[$i] = $dir = \dirname($dir); - } - $this->parameters = $this->getDefaultParameters(); - $this->services = []; - $this->methodMap = ['bar' => 'getBarService', 'test' => 'getTestService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\Bar - */ - protected function getBarService() - { - return $this->services['bar'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar($this->getEnv('QUZ')); - } - /** - * Gets the public 'test' shared service. - * - * @return object A %env(FOO)% instance - */ - protected function getTestService() - { - $class = $this->getEnv('FOO'); - return $this->services['test'] = new $class($this->getEnv('Bar'), 'foo' . $this->getEnv('string:FOO') . 'baz', $this->getEnv('int:Baz')); - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = ['bar' => \false, 'baz' => \false, 'json' => \false, 'db_dsn' => \false, 'env(json_file)' => \false]; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - switch ($name) { - case 'bar': - $value = $this->getEnv('FOO'); - break; - case 'baz': - $value = $this->getEnv('int:Baz'); - break; - case 'json': - $value = $this->getEnv('json:file:json_file'); - break; - case 'db_dsn': - $value = $this->getEnv('resolve:DB'); - break; - case 'env(json_file)': - $value = $this->targetDirs[1] . '/array.json'; - break; - default: - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - $this->loadedDynamicParameters[$name] = \true; - return $this->dynamicParameters[$name] = $value; - } - private $normalizedParameterNames = ['env(foo)' => 'env(FOO)', 'env(db)' => 'env(DB)']; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['project_dir' => '/foo/bar', 'env(FOO)' => 'foo', 'env(DB)' => 'sqlite://%project_dir%/var/data.db']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_EnvParameters', 'Symfony_DI_PhpDumper_Test_EnvParameters', \false); +targetDirs[$i] = $dir = \dirname($dir); + } + $this->parameters = $this->getDefaultParameters(); + $this->services = []; + $this->methodMap = ['bar' => 'getBarService', 'test' => 'getTestService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\Bar + */ + protected function getBarService() + { + return $this->services['bar'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar($this->getEnv('QUZ')); + } + /** + * Gets the public 'test' shared service. + * + * @return object A %env(FOO)% instance + */ + protected function getTestService() + { + $class = $this->getEnv('FOO'); + return $this->services['test'] = new $class($this->getEnv('Bar'), 'foo' . $this->getEnv('string:FOO') . 'baz', $this->getEnv('int:Baz')); + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = ['bar' => \false, 'baz' => \false, 'json' => \false, 'db_dsn' => \false, 'env(json_file)' => \false]; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + switch ($name) { + case 'bar': + $value = $this->getEnv('FOO'); + break; + case 'baz': + $value = $this->getEnv('int:Baz'); + break; + case 'json': + $value = $this->getEnv('json:file:json_file'); + break; + case 'db_dsn': + $value = $this->getEnv('resolve:DB'); + break; + case 'env(json_file)': + $value = $this->targetDirs[1] . '/array.json'; + break; + default: + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + $this->loadedDynamicParameters[$name] = \true; + return $this->dynamicParameters[$name] = $value; + } + private $normalizedParameterNames = ['env(foo)' => 'env(FOO)', 'env(db)' => 'env(DB)']; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['project_dir' => '/foo/bar', 'env(FOO)' => 'foo', 'env(DB)' => 'sqlite://%project_dir%/var/data.db']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_EnvParameters', 'Symfony_DI_PhpDumper_Test_EnvParameters', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services33.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services33.php index 5d87dacd2..a67660af9 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services33.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services33.php @@ -1,71 +1,71 @@ -services = []; - $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\bar\\foo' => '_PhpScoper5ea00cc67502b\\Bar\\Foo', '_PhpScoper5ea00cc67502b\\foo\\foo' => '_PhpScoper5ea00cc67502b\\Foo\\Foo']; - $this->methodMap = ['_PhpScoper5ea00cc67502b\\Bar\\Foo' => 'getFooService', '_PhpScoper5ea00cc67502b\\Foo\\Foo' => 'getFoo2Service']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'Bar\Foo' shared service. - * - * @return \Bar\Foo - */ - protected function getFooService() - { - return $this->services['Bar\\Foo'] = new \_PhpScoper5ea00cc67502b\Bar\Foo(); - } - /** - * Gets the public 'Foo\Foo' shared service. - * - * @return \Foo\Foo - */ - protected function getFoo2Service() - { - return $this->services['Foo\\Foo'] = new \_PhpScoper5ea00cc67502b\Foo\Foo(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +services = []; + $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\bar\\foo' => '_PhpScoper5ea00cc67502b\\Bar\\Foo', '_PhpScoper5ea00cc67502b\\foo\\foo' => '_PhpScoper5ea00cc67502b\\Foo\\Foo']; + $this->methodMap = ['_PhpScoper5ea00cc67502b\\Bar\\Foo' => 'getFooService', '_PhpScoper5ea00cc67502b\\Foo\\Foo' => 'getFoo2Service']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'Bar\Foo' shared service. + * + * @return \Bar\Foo + */ + protected function getFooService() + { + return $this->services['Bar\\Foo'] = new \_PhpScoper5ea00cc67502b\Bar\Foo(); + } + /** + * Gets the public 'Foo\Foo' shared service. + * + * @return \Foo\Foo + */ + protected function getFoo2Service() + { + return $this->services['Foo\\Foo'] = new \_PhpScoper5ea00cc67502b\Foo\Foo(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services8.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services8.php index 08efddd67..27135240e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services8.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services8.php @@ -1,124 +1,124 @@ -parameters = $this->getDefaultParameters(); - $this->services = []; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = []; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - private $normalizedParameterNames = []; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['foo' => 'bar', 'baz' => 'bar', 'bar' => 'foo is %foo bar', 'escape' => '@escapeme', 'values' => [0 => \true, 1 => \false, 2 => \NULL, 3 => 0, 4 => 1000.3, 5 => 'true', 6 => 'false', 7 => 'null'], 'null string' => 'null', 'string of digits' => '123', 'string of digits prefixed with minus character' => '-123', 'true string' => 'true', 'false string' => 'false', 'binary number string' => '0b0110', 'numeric string' => '-1.2E2', 'hexadecimal number string' => '0xFF', 'float string' => '10100.1', 'positive float string' => '+10100.1', 'negative float string' => '-10100.1']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +parameters = $this->getDefaultParameters(); + $this->services = []; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = []; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + private $normalizedParameterNames = []; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['foo' => 'bar', 'baz' => 'bar', 'bar' => 'foo is %foo bar', 'escape' => '@escapeme', 'values' => [0 => \true, 1 => \false, 2 => \NULL, 3 => 0, 4 => 1000.3, 5 => 'true', 6 => 'false', 7 => 'null'], 'null string' => 'null', 'string of digits' => '123', 'string of digits prefixed with minus character' => '-123', 'true string' => 'true', 'false string' => 'false', 'binary number string' => '0b0110', 'numeric string' => '-1.2E2', 'hexadecimal number string' => '0xFF', 'float string' => '10100.1', 'positive float string' => '+10100.1', 'negative float string' => '-10100.1']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9.php index 14bfa0ce4..13ee98c53 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9.php @@ -1,361 +1,361 @@ -getDefaultParameters())); - $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\psr\\container\\containerinterface' => '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface', '_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\containerinterface' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface']; - $this->syntheticIds = ['request' => \true]; - $this->methodMap = ['bar' => 'getBarService', 'baz' => 'getBazService', 'configurator_service' => 'getConfiguratorServiceService', 'configurator_service_simple' => 'getConfiguratorServiceSimpleService', 'configured_service' => 'getConfiguredServiceService', 'configured_service_simple' => 'getConfiguredServiceSimpleService', 'decorated' => 'getDecoratedService', 'decorator_service' => 'getDecoratorServiceService', 'decorator_service_with_name' => 'getDecoratorServiceWithNameService', 'deprecated_service' => 'getDeprecatedServiceService', 'factory_service' => 'getFactoryServiceService', 'factory_service_simple' => 'getFactoryServiceSimpleService', 'factory_simple' => 'getFactorySimpleService', 'foo' => 'getFooService', 'foo.baz' => 'getFoo_BazService', 'foo_bar' => 'getFooBarService', 'foo_with_inline' => 'getFooWithInlineService', 'inlined' => 'getInlinedService', 'lazy_context' => 'getLazyContextService', 'lazy_context_ignore_invalid_ref' => 'getLazyContextIgnoreInvalidRefService', 'method_call1' => 'getMethodCall1Service', 'new_factory' => 'getNewFactoryService', 'new_factory_service' => 'getNewFactoryServiceService', 'service_from_static_method' => 'getServiceFromStaticMethodService', 'tagged_iterator' => 'getTaggedIteratorService', 'tagged_iterator_foo' => 'getTaggedIteratorFooService']; - $this->privates = ['configurator_service' => \true, 'configurator_service_simple' => \true, 'factory_simple' => \true, 'inlined' => \true, 'new_factory' => \true, 'tagged_iterator_foo' => \true]; - $this->aliases = ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => 'service_container', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => 'service_container', 'alias_for_alias' => 'foo', 'alias_for_foo' => 'foo']; - } - /** - * Gets the public 'bar' shared service. - * - * @return \Bar\FooClass - */ - protected function getBarService() - { - $a = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}; - $this->services['bar'] = $instance = new \_PhpScoper5ea00cc67502b\Bar\FooClass('foo', $a, $this->getParameter('foo_bar')); - $a->configure($instance); - return $instance; - } - /** - * Gets the public 'baz' shared service. - * - * @return \Baz - */ - protected function getBazService() - { - $this->services['baz'] = $instance = new \_PhpScoper5ea00cc67502b\Baz(); - $instance->setFoo(${($_ = isset($this->services['foo_with_inline']) ? $this->services['foo_with_inline'] : $this->getFooWithInlineService()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the public 'configured_service' shared service. - * - * @return \stdClass - */ - protected function getConfiguredServiceService() - { - $this->services['configured_service'] = $instance = new \stdClass(); - ${($_ = isset($this->services['configurator_service']) ? $this->services['configurator_service'] : $this->getConfiguratorServiceService()) && \false ?: '_'}->configureStdClass($instance); - return $instance; - } - /** - * Gets the public 'configured_service_simple' shared service. - * - * @return \stdClass - */ - protected function getConfiguredServiceSimpleService() - { - $this->services['configured_service_simple'] = $instance = new \stdClass(); - ${($_ = isset($this->services['configurator_service_simple']) ? $this->services['configurator_service_simple'] : ($this->services['configurator_service_simple'] = new \_PhpScoper5ea00cc67502b\ConfClass('bar'))) && \false ?: '_'}->configureStdClass($instance); - return $instance; - } - /** - * Gets the public 'decorated' shared service. - * - * @return \stdClass - */ - protected function getDecoratedService() - { - return $this->services['decorated'] = new \stdClass(); - } - /** - * Gets the public 'decorator_service' shared service. - * - * @return \stdClass - */ - protected function getDecoratorServiceService() - { - return $this->services['decorator_service'] = new \stdClass(); - } - /** - * Gets the public 'decorator_service_with_name' shared service. - * - * @return \stdClass - */ - protected function getDecoratorServiceWithNameService() - { - return $this->services['decorator_service_with_name'] = new \stdClass(); - } - /** - * Gets the public 'deprecated_service' shared service. - * - * @return \stdClass - * - * @deprecated The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed. - */ - protected function getDeprecatedServiceService() - { - @\trigger_error('The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed.', \E_USER_DEPRECATED); - return $this->services['deprecated_service'] = new \stdClass(); - } - /** - * Gets the public 'factory_service' shared service. - * - * @return \Bar - */ - protected function getFactoryServiceService() - { - return $this->services['factory_service'] = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}->getInstance(); - } - /** - * Gets the public 'factory_service_simple' shared service. - * - * @return \Bar - */ - protected function getFactoryServiceSimpleService() - { - return $this->services['factory_service_simple'] = ${($_ = isset($this->services['factory_simple']) ? $this->services['factory_simple'] : $this->getFactorySimpleService()) && \false ?: '_'}->getInstance(); - } - /** - * Gets the public 'foo' shared service. - * - * @return \Bar\FooClass - */ - protected function getFooService() - { - $a = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}; - $this->services['foo'] = $instance = \_PhpScoper5ea00cc67502b\Bar\FooClass::getInstance('foo', $a, [$this->getParameter('foo') => 'foo is ' . $this->getParameter('foo') . '', 'foobar' => $this->getParameter('foo')], \true, $this); - $instance->foo = 'bar'; - $instance->moo = $a; - $instance->qux = [$this->getParameter('foo') => 'foo is ' . $this->getParameter('foo') . '', 'foobar' => $this->getParameter('foo')]; - $instance->setBar(${($_ = isset($this->services['bar']) ? $this->services['bar'] : $this->getBarService()) && \false ?: '_'}); - $instance->initialize(); - \_PhpScoper5ea00cc67502b\sc_configure($instance); - return $instance; - } - /** - * Gets the public 'foo.baz' shared service. - * - * @return object A %baz_class% instance - */ - protected function getFoo_BazService() - { - $this->services['foo.baz'] = $instance = \call_user_func([$this->getParameter('baz_class'), 'getInstance']); - \call_user_func([$this->getParameter('baz_class'), 'configureStatic1'], $instance); - return $instance; - } - /** - * Gets the public 'foo_bar' service. - * - * @return object A %foo_class% instance - */ - protected function getFooBarService() - { - $class = $this->getParameter('foo_class'); - return new $class(${($_ = isset($this->services['deprecated_service']) ? $this->services['deprecated_service'] : $this->getDeprecatedServiceService()) && \false ?: '_'}); - } - /** - * Gets the public 'foo_with_inline' shared service. - * - * @return \Foo - */ - protected function getFooWithInlineService() - { - $this->services['foo_with_inline'] = $instance = new \_PhpScoper5ea00cc67502b\Foo(); - $instance->setBar(${($_ = isset($this->services['inlined']) ? $this->services['inlined'] : $this->getInlinedService()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the public 'lazy_context' shared service. - * - * @return \LazyContext - */ - protected function getLazyContextService() - { - return $this->services['lazy_context'] = new \_PhpScoper5ea00cc67502b\LazyContext(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - (yield 'k1' => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}); - (yield 'k2' => $this); - }, 2), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - return new \EmptyIterator(); - }, 0)); - } - /** - * Gets the public 'lazy_context_ignore_invalid_ref' shared service. - * - * @return \LazyContext - */ - protected function getLazyContextIgnoreInvalidRefService() - { - return $this->services['lazy_context_ignore_invalid_ref'] = new \_PhpScoper5ea00cc67502b\LazyContext(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - (yield 0 => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}); - if ($this->has('invalid')) { - (yield 1 => ${($_ = isset($this->services['invalid']) ? $this->services['invalid'] : $this->get( - 'invalid', - /* ContainerInterface::NULL_ON_INVALID_REFERENCE */ - 2 - )) && \false ?: '_'}); - } - }, function () { - return 1 + (int) $this->has('invalid'); - }), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - return new \EmptyIterator(); - }, 0)); - } - /** - * Gets the public 'method_call1' shared service. - * - * @return \Bar\FooClass - */ - protected function getMethodCall1Service() - { - include_once '%path%foo.php'; - $this->services['method_call1'] = $instance = new \_PhpScoper5ea00cc67502b\Bar\FooClass(); - $instance->setBar(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}); - $instance->setBar(${($_ = isset($this->services['foo2']) ? $this->services['foo2'] : $this->get( - 'foo2', - /* ContainerInterface::NULL_ON_INVALID_REFERENCE */ - 2 - )) && \false ?: '_'}); - if ($this->has('foo3')) { - $instance->setBar(${($_ = isset($this->services['foo3']) ? $this->services['foo3'] : $this->get( - 'foo3', - /* ContainerInterface::NULL_ON_INVALID_REFERENCE */ - 2 - )) && \false ?: '_'}); - } - if ($this->has('foobaz')) { - $instance->setBar(${($_ = isset($this->services['foobaz']) ? $this->services['foobaz'] : $this->get( - 'foobaz', - /* ContainerInterface::NULL_ON_INVALID_REFERENCE */ - 2 - )) && \false ?: '_'}); - } - $instance->setBar(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}->foo() . ($this->hasParameter("foo") ? $this->getParameter("foo") : "default")); - return $instance; - } - /** - * Gets the public 'new_factory_service' shared service. - * - * @return \FooBarBaz - */ - protected function getNewFactoryServiceService() - { - $this->services['new_factory_service'] = $instance = ${($_ = isset($this->services['new_factory']) ? $this->services['new_factory'] : $this->getNewFactoryService()) && \false ?: '_'}->getInstance(); - $instance->foo = 'bar'; - return $instance; - } - /** - * Gets the public 'service_from_static_method' shared service. - * - * @return \Bar\FooClass - */ - protected function getServiceFromStaticMethodService() - { - return $this->services['service_from_static_method'] = \_PhpScoper5ea00cc67502b\Bar\FooClass::getInstance(); - } - /** - * Gets the public 'tagged_iterator' shared service. - * - * @return \Bar - */ - protected function getTaggedIteratorService() - { - return $this->services['tagged_iterator'] = new \_PhpScoper5ea00cc67502b\Bar(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - return new \EmptyIterator(); - }, 0)); - } - /** - * Gets the private 'configurator_service' shared service. - * - * @return \ConfClass - */ - protected function getConfiguratorServiceService() - { - $this->services['configurator_service'] = $instance = new \_PhpScoper5ea00cc67502b\ConfClass(); - $instance->setFoo(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->getBazService()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the private 'configurator_service_simple' shared service. - * - * @return \ConfClass - */ - protected function getConfiguratorServiceSimpleService() - { - return $this->services['configurator_service_simple'] = new \_PhpScoper5ea00cc67502b\ConfClass('bar'); - } - /** - * Gets the private 'factory_simple' shared service. - * - * @return \SimpleFactoryClass - * - * @deprecated The "factory_simple" service is deprecated. You should stop using it, as it will soon be removed. - */ - protected function getFactorySimpleService() - { - @\trigger_error('The "factory_simple" service is deprecated. You should stop using it, as it will soon be removed.', \E_USER_DEPRECATED); - return $this->services['factory_simple'] = new \_PhpScoper5ea00cc67502b\SimpleFactoryClass('foo'); - } - /** - * Gets the private 'inlined' shared service. - * - * @return \Bar - */ - protected function getInlinedService() - { - $this->services['inlined'] = $instance = new \_PhpScoper5ea00cc67502b\Bar(); - $instance->pub = 'pub'; - $instance->setBaz(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->getBazService()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the private 'new_factory' shared service. - * - * @return \FactoryClass - */ - protected function getNewFactoryService() - { - $this->services['new_factory'] = $instance = new \_PhpScoper5ea00cc67502b\FactoryClass(); - $instance->foo = 'bar'; - return $instance; - } - /** - * Gets the private 'tagged_iterator_foo' shared service. - * - * @return \Bar - */ - protected function getTaggedIteratorFooService() - { - return $this->services['tagged_iterator_foo'] = new \_PhpScoper5ea00cc67502b\Bar(); - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['baz_class' => 'BazClass', 'foo_class' => '_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'foo' => 'bar']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +getDefaultParameters())); + $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\psr\\container\\containerinterface' => '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface', '_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\containerinterface' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface']; + $this->syntheticIds = ['request' => \true]; + $this->methodMap = ['bar' => 'getBarService', 'baz' => 'getBazService', 'configurator_service' => 'getConfiguratorServiceService', 'configurator_service_simple' => 'getConfiguratorServiceSimpleService', 'configured_service' => 'getConfiguredServiceService', 'configured_service_simple' => 'getConfiguredServiceSimpleService', 'decorated' => 'getDecoratedService', 'decorator_service' => 'getDecoratorServiceService', 'decorator_service_with_name' => 'getDecoratorServiceWithNameService', 'deprecated_service' => 'getDeprecatedServiceService', 'factory_service' => 'getFactoryServiceService', 'factory_service_simple' => 'getFactoryServiceSimpleService', 'factory_simple' => 'getFactorySimpleService', 'foo' => 'getFooService', 'foo.baz' => 'getFoo_BazService', 'foo_bar' => 'getFooBarService', 'foo_with_inline' => 'getFooWithInlineService', 'inlined' => 'getInlinedService', 'lazy_context' => 'getLazyContextService', 'lazy_context_ignore_invalid_ref' => 'getLazyContextIgnoreInvalidRefService', 'method_call1' => 'getMethodCall1Service', 'new_factory' => 'getNewFactoryService', 'new_factory_service' => 'getNewFactoryServiceService', 'service_from_static_method' => 'getServiceFromStaticMethodService', 'tagged_iterator' => 'getTaggedIteratorService', 'tagged_iterator_foo' => 'getTaggedIteratorFooService']; + $this->privates = ['configurator_service' => \true, 'configurator_service_simple' => \true, 'factory_simple' => \true, 'inlined' => \true, 'new_factory' => \true, 'tagged_iterator_foo' => \true]; + $this->aliases = ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => 'service_container', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => 'service_container', 'alias_for_alias' => 'foo', 'alias_for_foo' => 'foo']; + } + /** + * Gets the public 'bar' shared service. + * + * @return \Bar\FooClass + */ + protected function getBarService() + { + $a = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}; + $this->services['bar'] = $instance = new \_PhpScoper5ea00cc67502b\Bar\FooClass('foo', $a, $this->getParameter('foo_bar')); + $a->configure($instance); + return $instance; + } + /** + * Gets the public 'baz' shared service. + * + * @return \Baz + */ + protected function getBazService() + { + $this->services['baz'] = $instance = new \_PhpScoper5ea00cc67502b\Baz(); + $instance->setFoo(${($_ = isset($this->services['foo_with_inline']) ? $this->services['foo_with_inline'] : $this->getFooWithInlineService()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the public 'configured_service' shared service. + * + * @return \stdClass + */ + protected function getConfiguredServiceService() + { + $this->services['configured_service'] = $instance = new \stdClass(); + ${($_ = isset($this->services['configurator_service']) ? $this->services['configurator_service'] : $this->getConfiguratorServiceService()) && \false ?: '_'}->configureStdClass($instance); + return $instance; + } + /** + * Gets the public 'configured_service_simple' shared service. + * + * @return \stdClass + */ + protected function getConfiguredServiceSimpleService() + { + $this->services['configured_service_simple'] = $instance = new \stdClass(); + ${($_ = isset($this->services['configurator_service_simple']) ? $this->services['configurator_service_simple'] : ($this->services['configurator_service_simple'] = new \_PhpScoper5ea00cc67502b\ConfClass('bar'))) && \false ?: '_'}->configureStdClass($instance); + return $instance; + } + /** + * Gets the public 'decorated' shared service. + * + * @return \stdClass + */ + protected function getDecoratedService() + { + return $this->services['decorated'] = new \stdClass(); + } + /** + * Gets the public 'decorator_service' shared service. + * + * @return \stdClass + */ + protected function getDecoratorServiceService() + { + return $this->services['decorator_service'] = new \stdClass(); + } + /** + * Gets the public 'decorator_service_with_name' shared service. + * + * @return \stdClass + */ + protected function getDecoratorServiceWithNameService() + { + return $this->services['decorator_service_with_name'] = new \stdClass(); + } + /** + * Gets the public 'deprecated_service' shared service. + * + * @return \stdClass + * + * @deprecated The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed. + */ + protected function getDeprecatedServiceService() + { + @\trigger_error('The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed.', \E_USER_DEPRECATED); + return $this->services['deprecated_service'] = new \stdClass(); + } + /** + * Gets the public 'factory_service' shared service. + * + * @return \Bar + */ + protected function getFactoryServiceService() + { + return $this->services['factory_service'] = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}->getInstance(); + } + /** + * Gets the public 'factory_service_simple' shared service. + * + * @return \Bar + */ + protected function getFactoryServiceSimpleService() + { + return $this->services['factory_service_simple'] = ${($_ = isset($this->services['factory_simple']) ? $this->services['factory_simple'] : $this->getFactorySimpleService()) && \false ?: '_'}->getInstance(); + } + /** + * Gets the public 'foo' shared service. + * + * @return \Bar\FooClass + */ + protected function getFooService() + { + $a = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}; + $this->services['foo'] = $instance = \_PhpScoper5ea00cc67502b\Bar\FooClass::getInstance('foo', $a, [$this->getParameter('foo') => 'foo is ' . $this->getParameter('foo') . '', 'foobar' => $this->getParameter('foo')], \true, $this); + $instance->foo = 'bar'; + $instance->moo = $a; + $instance->qux = [$this->getParameter('foo') => 'foo is ' . $this->getParameter('foo') . '', 'foobar' => $this->getParameter('foo')]; + $instance->setBar(${($_ = isset($this->services['bar']) ? $this->services['bar'] : $this->getBarService()) && \false ?: '_'}); + $instance->initialize(); + \_PhpScoper5ea00cc67502b\sc_configure($instance); + return $instance; + } + /** + * Gets the public 'foo.baz' shared service. + * + * @return object A %baz_class% instance + */ + protected function getFoo_BazService() + { + $this->services['foo.baz'] = $instance = \call_user_func([$this->getParameter('baz_class'), 'getInstance']); + \call_user_func([$this->getParameter('baz_class'), 'configureStatic1'], $instance); + return $instance; + } + /** + * Gets the public 'foo_bar' service. + * + * @return object A %foo_class% instance + */ + protected function getFooBarService() + { + $class = $this->getParameter('foo_class'); + return new $class(${($_ = isset($this->services['deprecated_service']) ? $this->services['deprecated_service'] : $this->getDeprecatedServiceService()) && \false ?: '_'}); + } + /** + * Gets the public 'foo_with_inline' shared service. + * + * @return \Foo + */ + protected function getFooWithInlineService() + { + $this->services['foo_with_inline'] = $instance = new \_PhpScoper5ea00cc67502b\Foo(); + $instance->setBar(${($_ = isset($this->services['inlined']) ? $this->services['inlined'] : $this->getInlinedService()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the public 'lazy_context' shared service. + * + * @return \LazyContext + */ + protected function getLazyContextService() + { + return $this->services['lazy_context'] = new \_PhpScoper5ea00cc67502b\LazyContext(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + (yield 'k1' => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}); + (yield 'k2' => $this); + }, 2), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + return new \EmptyIterator(); + }, 0)); + } + /** + * Gets the public 'lazy_context_ignore_invalid_ref' shared service. + * + * @return \LazyContext + */ + protected function getLazyContextIgnoreInvalidRefService() + { + return $this->services['lazy_context_ignore_invalid_ref'] = new \_PhpScoper5ea00cc67502b\LazyContext(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + (yield 0 => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}); + if ($this->has('invalid')) { + (yield 1 => ${($_ = isset($this->services['invalid']) ? $this->services['invalid'] : $this->get( + 'invalid', + /* ContainerInterface::NULL_ON_INVALID_REFERENCE */ + 2 + )) && \false ?: '_'}); + } + }, function () { + return 1 + (int) $this->has('invalid'); + }), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + return new \EmptyIterator(); + }, 0)); + } + /** + * Gets the public 'method_call1' shared service. + * + * @return \Bar\FooClass + */ + protected function getMethodCall1Service() + { + include_once '%path%foo.php'; + $this->services['method_call1'] = $instance = new \_PhpScoper5ea00cc67502b\Bar\FooClass(); + $instance->setBar(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}); + $instance->setBar(${($_ = isset($this->services['foo2']) ? $this->services['foo2'] : $this->get( + 'foo2', + /* ContainerInterface::NULL_ON_INVALID_REFERENCE */ + 2 + )) && \false ?: '_'}); + if ($this->has('foo3')) { + $instance->setBar(${($_ = isset($this->services['foo3']) ? $this->services['foo3'] : $this->get( + 'foo3', + /* ContainerInterface::NULL_ON_INVALID_REFERENCE */ + 2 + )) && \false ?: '_'}); + } + if ($this->has('foobaz')) { + $instance->setBar(${($_ = isset($this->services['foobaz']) ? $this->services['foobaz'] : $this->get( + 'foobaz', + /* ContainerInterface::NULL_ON_INVALID_REFERENCE */ + 2 + )) && \false ?: '_'}); + } + $instance->setBar(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}->foo() . ($this->hasParameter("foo") ? $this->getParameter("foo") : "default")); + return $instance; + } + /** + * Gets the public 'new_factory_service' shared service. + * + * @return \FooBarBaz + */ + protected function getNewFactoryServiceService() + { + $this->services['new_factory_service'] = $instance = ${($_ = isset($this->services['new_factory']) ? $this->services['new_factory'] : $this->getNewFactoryService()) && \false ?: '_'}->getInstance(); + $instance->foo = 'bar'; + return $instance; + } + /** + * Gets the public 'service_from_static_method' shared service. + * + * @return \Bar\FooClass + */ + protected function getServiceFromStaticMethodService() + { + return $this->services['service_from_static_method'] = \_PhpScoper5ea00cc67502b\Bar\FooClass::getInstance(); + } + /** + * Gets the public 'tagged_iterator' shared service. + * + * @return \Bar + */ + protected function getTaggedIteratorService() + { + return $this->services['tagged_iterator'] = new \_PhpScoper5ea00cc67502b\Bar(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + return new \EmptyIterator(); + }, 0)); + } + /** + * Gets the private 'configurator_service' shared service. + * + * @return \ConfClass + */ + protected function getConfiguratorServiceService() + { + $this->services['configurator_service'] = $instance = new \_PhpScoper5ea00cc67502b\ConfClass(); + $instance->setFoo(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->getBazService()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the private 'configurator_service_simple' shared service. + * + * @return \ConfClass + */ + protected function getConfiguratorServiceSimpleService() + { + return $this->services['configurator_service_simple'] = new \_PhpScoper5ea00cc67502b\ConfClass('bar'); + } + /** + * Gets the private 'factory_simple' shared service. + * + * @return \SimpleFactoryClass + * + * @deprecated The "factory_simple" service is deprecated. You should stop using it, as it will soon be removed. + */ + protected function getFactorySimpleService() + { + @\trigger_error('The "factory_simple" service is deprecated. You should stop using it, as it will soon be removed.', \E_USER_DEPRECATED); + return $this->services['factory_simple'] = new \_PhpScoper5ea00cc67502b\SimpleFactoryClass('foo'); + } + /** + * Gets the private 'inlined' shared service. + * + * @return \Bar + */ + protected function getInlinedService() + { + $this->services['inlined'] = $instance = new \_PhpScoper5ea00cc67502b\Bar(); + $instance->pub = 'pub'; + $instance->setBaz(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->getBazService()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the private 'new_factory' shared service. + * + * @return \FactoryClass + */ + protected function getNewFactoryService() + { + $this->services['new_factory'] = $instance = new \_PhpScoper5ea00cc67502b\FactoryClass(); + $instance->foo = 'bar'; + return $instance; + } + /** + * Gets the private 'tagged_iterator_foo' shared service. + * + * @return \Bar + */ + protected function getTaggedIteratorFooService() + { + return $this->services['tagged_iterator_foo'] = new \_PhpScoper5ea00cc67502b\Bar(); + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['baz_class' => 'BazClass', 'foo_class' => '_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'foo' => 'bar']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_as_files.txt b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_as_files.txt index ab7024fa5..d836ec86a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_as_files.txt +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_as_files.txt @@ -1,508 +1,508 @@ -Array -( - [Container%s/removed-ids.php] => true, - 'Symfony\\Component\\DependencyInjection\\ContainerInterface' => true, - 'configurator_service' => true, - 'configurator_service_simple' => true, - 'decorated.pif-pouf' => true, - 'decorator_service.inner' => true, - 'factory_simple' => true, - 'inlined' => true, - 'new_factory' => true, - 'tagged_iterator_foo' => true, -]; - - [Container%s/getBazService.php] => services['baz'] = $instance = new \Baz(); - -$instance->setFoo(${($_ = isset($this->services['foo_with_inline']) ? $this->services['foo_with_inline'] : $this->load('getFooWithInlineService.php')) && false ?: '_'}); - -return $instance; - - [Container%s/getConfiguredServiceService.php] => services['configured_service'] = $instance = new \stdClass(); - -$a = new \ConfClass(); -$a->setFoo(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->load('getBazService.php')) && false ?: '_'}); - -$a->configureStdClass($instance); - -return $instance; - - [Container%s/getConfiguredServiceSimpleService.php] => services['configured_service_simple'] = $instance = new \stdClass(); - -(new \ConfClass('bar'))->configureStdClass($instance); - -return $instance; - - [Container%s/getDecoratorServiceService.php] => services['decorator_service'] = new \stdClass(); - - [Container%s/getDecoratorServiceWithNameService.php] => services['decorator_service_with_name'] = new \stdClass(); - - [Container%s/getDeprecatedServiceService.php] => services['deprecated_service'] = new \stdClass(); - - [Container%s/getFactoryServiceService.php] => services['factory_service'] = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->load('getFoo_BazService.php')) && false ?: '_'}->getInstance(); - - [Container%s/getFactoryServiceSimpleService.php] => services['factory_service_simple'] = ${($_ = isset($this->services['factory_simple']) ? $this->services['factory_simple'] : $this->load('getFactorySimpleService.php')) && false ?: '_'}->getInstance(); - - [Container%s/getFactorySimpleService.php] => services['factory_simple'] = new \SimpleFactoryClass('foo'); - - [Container%s/getFooService.php] => services['foo.baz']) ? $this->services['foo.baz'] : $this->load('getFoo_BazService.php')) && false ?: '_'}; - -$this->services['foo'] = $instance = \Bar\FooClass::getInstance('foo', $a, ['bar' => 'foo is bar', 'foobar' => 'bar'], true, $this); - -$instance->foo = 'bar'; -$instance->moo = $a; -$instance->qux = ['bar' => 'foo is bar', 'foobar' => 'bar']; -$instance->setBar(${($_ = isset($this->services['bar']) ? $this->services['bar'] : $this->getBarService()) && false ?: '_'}); -$instance->initialize(); -sc_configure($instance); - -return $instance; - - [Container%s/getFoo_BazService.php] => services['foo.baz'] = $instance = \BazClass::getInstance(); - -\BazClass::configureStatic1($instance); - -return $instance; - - [Container%s/getFooWithInlineService.php] => services['foo_with_inline'] = $instance = new \Foo(); - -$a = new \Bar(); -$a->pub = 'pub'; -$a->setBaz(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->load('getBazService.php')) && false ?: '_'}); - -$instance->setBar($a); - -return $instance; - - [Container%s/getLazyContextService.php] => services['lazy_context'] = new \LazyContext(new RewindableGenerator(function () { - yield 'k1' => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->load('getFoo_BazService.php')) && false ?: '_'}; - yield 'k2' => $this; -}, 2), new RewindableGenerator(function () { - return new \EmptyIterator(); -}, 0)); - - [Container%s/getLazyContextIgnoreInvalidRefService.php] => services['lazy_context_ignore_invalid_ref'] = new \LazyContext(new RewindableGenerator(function () { - yield 0 => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->load('getFoo_BazService.php')) && false ?: '_'}; -}, 1), new RewindableGenerator(function () { - return new \EmptyIterator(); -}, 0)); - - [Container%s/getMethodCall1Service.php] => targetDirs[0].'/Fixtures/includes/foo.php'); - -$this->services['method_call1'] = $instance = new \Bar\FooClass(); - -$instance->setBar(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->load('getFooService.php')) && false ?: '_'}); -$instance->setBar(NULL); -$instance->setBar((${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->load('getFooService.php')) && false ?: '_'}->foo() . (($this->hasParameter("foo")) ? ($this->getParameter("foo")) : ("default")))); - -return $instance; - - [Container%s/getNewFactoryServiceService.php] => foo = 'bar'; - -$this->services['new_factory_service'] = $instance = $a->getInstance(); - -$instance->foo = 'bar'; - -return $instance; - - [Container%s/getServiceFromStaticMethodService.php] => services['service_from_static_method'] = \Bar\FooClass::getInstance(); - - [Container%s/getTaggedIteratorService.php] => services['tagged_iterator'] = new \Bar(new RewindableGenerator(function () { - yield 0 => ${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->load('getFooService.php')) && false ?: '_'}; - yield 1 => ${($_ = isset($this->services['tagged_iterator_foo']) ? $this->services['tagged_iterator_foo'] : ($this->services['tagged_iterator_foo'] = new \Bar())) && false ?: '_'}; -}, 2)); - - [Container%s/getTaggedIteratorFooService.php] => services['tagged_iterator_foo'] = new \Bar(); - - [Container%s/ProjectServiceContainer.php] => targetDirs[0] = \dirname($containerDir); - for ($i = 1; $i <= 5; ++$i) { - $this->targetDirs[$i] = $dir = \dirname($dir); - } - $this->buildParameters = $buildParameters; - $this->containerDir = $containerDir; - $this->parameters = $this->getDefaultParameters(); - - $this->services = []; - $this->syntheticIds = [ - 'request' => true, - ]; - $this->methodMap = [ - 'bar' => 'getBarService', - 'foo_bar' => 'getFooBarService', - ]; - $this->fileMap = [ - 'baz' => 'getBazService.php', - 'configured_service' => 'getConfiguredServiceService.php', - 'configured_service_simple' => 'getConfiguredServiceSimpleService.php', - 'decorator_service' => 'getDecoratorServiceService.php', - 'decorator_service_with_name' => 'getDecoratorServiceWithNameService.php', - 'deprecated_service' => 'getDeprecatedServiceService.php', - 'factory_service' => 'getFactoryServiceService.php', - 'factory_service_simple' => 'getFactoryServiceSimpleService.php', - 'factory_simple' => 'getFactorySimpleService.php', - 'foo' => 'getFooService.php', - 'foo.baz' => 'getFoo_BazService.php', - 'foo_with_inline' => 'getFooWithInlineService.php', - 'lazy_context' => 'getLazyContextService.php', - 'lazy_context_ignore_invalid_ref' => 'getLazyContextIgnoreInvalidRefService.php', - 'method_call1' => 'getMethodCall1Service.php', - 'new_factory_service' => 'getNewFactoryServiceService.php', - 'service_from_static_method' => 'getServiceFromStaticMethodService.php', - 'tagged_iterator' => 'getTaggedIteratorService.php', - 'tagged_iterator_foo' => 'getTaggedIteratorFooService.php', - ]; - $this->privates = [ - 'factory_simple' => true, - 'tagged_iterator_foo' => true, - ]; - $this->aliases = [ - 'alias_for_alias' => 'foo', - 'alias_for_foo' => 'foo', - 'decorated' => 'decorator_service_with_name', - ]; - } - - public function getRemovedIds() - { - return require $this->containerDir.\DIRECTORY_SEPARATOR.'removed-ids.php'; - } - - public function compile() - { - throw new LogicException('You cannot compile a dumped container that was already compiled.'); - } - - public function isCompiled() - { - return true; - } - - public function isFrozen() - { - @trigger_error(sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), E_USER_DEPRECATED); - - return true; - } - - protected function load($file, $lazyLoad = true) - { - return require $this->containerDir.\DIRECTORY_SEPARATOR.$file; - } - - /** - * Gets the public 'bar' shared service. - * - * @return \Bar\FooClass - */ - protected function getBarService() - { - $a = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->load('getFoo_BazService.php')) && false ?: '_'}; - - $this->services['bar'] = $instance = new \Bar\FooClass('foo', $a, $this->getParameter('foo_bar')); - - $a->configure($instance); - - return $instance; - } - - /** - * Gets the public 'foo_bar' service. - * - * @return \Bar\FooClass - */ - protected function getFooBarService() - { - return new \Bar\FooClass(${($_ = isset($this->services['deprecated_service']) ? $this->services['deprecated_service'] : $this->load('getDeprecatedServiceService.php')) && false ?: '_'}); - } - - public function getParameter($name) - { - $name = (string) $name; - if (isset($this->buildParameters[$name])) { - return $this->buildParameters[$name]; - } - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters))) { - throw new InvalidArgumentException(sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - - return $this->parameters[$name]; - } - - public function hasParameter($name) - { - $name = (string) $name; - if (isset($this->buildParameters[$name])) { - return true; - } - $name = $this->normalizeParameterName($name); - - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters); - } - - public function setParameter($name, $value) - { - throw new LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - foreach ($this->buildParameters as $name => $value) { - $parameters[$name] = $value; - } - $this->parameterBag = new FrozenParameterBag($parameters); - } - - return $this->parameterBag; - } - - private $loadedDynamicParameters = []; - private $dynamicParameters = []; - - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - throw new InvalidArgumentException(sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - - private $normalizedParameterNames = []; - - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = strtolower($name)]) || isset($this->parameters[$normalizedName]) || array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @trigger_error(sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - - return $normalizedName; - } - - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return [ - 'baz_class' => 'BazClass', - 'foo_class' => 'Bar\\FooClass', - 'foo' => 'bar', - ]; - } -} - - [ProjectServiceContainer.php] => '%s', - 'container.build_id' => '%s', - 'container.build_time' => %d, -], __DIR__.\DIRECTORY_SEPARATOR.'Container%s'); - -) +Array +( + [Container%s/removed-ids.php] => true, + 'Symfony\\Component\\DependencyInjection\\ContainerInterface' => true, + 'configurator_service' => true, + 'configurator_service_simple' => true, + 'decorated.pif-pouf' => true, + 'decorator_service.inner' => true, + 'factory_simple' => true, + 'inlined' => true, + 'new_factory' => true, + 'tagged_iterator_foo' => true, +]; + + [Container%s/getBazService.php] => services['baz'] = $instance = new \Baz(); + +$instance->setFoo(${($_ = isset($this->services['foo_with_inline']) ? $this->services['foo_with_inline'] : $this->load('getFooWithInlineService.php')) && false ?: '_'}); + +return $instance; + + [Container%s/getConfiguredServiceService.php] => services['configured_service'] = $instance = new \stdClass(); + +$a = new \ConfClass(); +$a->setFoo(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->load('getBazService.php')) && false ?: '_'}); + +$a->configureStdClass($instance); + +return $instance; + + [Container%s/getConfiguredServiceSimpleService.php] => services['configured_service_simple'] = $instance = new \stdClass(); + +(new \ConfClass('bar'))->configureStdClass($instance); + +return $instance; + + [Container%s/getDecoratorServiceService.php] => services['decorator_service'] = new \stdClass(); + + [Container%s/getDecoratorServiceWithNameService.php] => services['decorator_service_with_name'] = new \stdClass(); + + [Container%s/getDeprecatedServiceService.php] => services['deprecated_service'] = new \stdClass(); + + [Container%s/getFactoryServiceService.php] => services['factory_service'] = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->load('getFoo_BazService.php')) && false ?: '_'}->getInstance(); + + [Container%s/getFactoryServiceSimpleService.php] => services['factory_service_simple'] = ${($_ = isset($this->services['factory_simple']) ? $this->services['factory_simple'] : $this->load('getFactorySimpleService.php')) && false ?: '_'}->getInstance(); + + [Container%s/getFactorySimpleService.php] => services['factory_simple'] = new \SimpleFactoryClass('foo'); + + [Container%s/getFooService.php] => services['foo.baz']) ? $this->services['foo.baz'] : $this->load('getFoo_BazService.php')) && false ?: '_'}; + +$this->services['foo'] = $instance = \Bar\FooClass::getInstance('foo', $a, ['bar' => 'foo is bar', 'foobar' => 'bar'], true, $this); + +$instance->foo = 'bar'; +$instance->moo = $a; +$instance->qux = ['bar' => 'foo is bar', 'foobar' => 'bar']; +$instance->setBar(${($_ = isset($this->services['bar']) ? $this->services['bar'] : $this->getBarService()) && false ?: '_'}); +$instance->initialize(); +sc_configure($instance); + +return $instance; + + [Container%s/getFoo_BazService.php] => services['foo.baz'] = $instance = \BazClass::getInstance(); + +\BazClass::configureStatic1($instance); + +return $instance; + + [Container%s/getFooWithInlineService.php] => services['foo_with_inline'] = $instance = new \Foo(); + +$a = new \Bar(); +$a->pub = 'pub'; +$a->setBaz(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->load('getBazService.php')) && false ?: '_'}); + +$instance->setBar($a); + +return $instance; + + [Container%s/getLazyContextService.php] => services['lazy_context'] = new \LazyContext(new RewindableGenerator(function () { + yield 'k1' => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->load('getFoo_BazService.php')) && false ?: '_'}; + yield 'k2' => $this; +}, 2), new RewindableGenerator(function () { + return new \EmptyIterator(); +}, 0)); + + [Container%s/getLazyContextIgnoreInvalidRefService.php] => services['lazy_context_ignore_invalid_ref'] = new \LazyContext(new RewindableGenerator(function () { + yield 0 => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->load('getFoo_BazService.php')) && false ?: '_'}; +}, 1), new RewindableGenerator(function () { + return new \EmptyIterator(); +}, 0)); + + [Container%s/getMethodCall1Service.php] => targetDirs[0].'/Fixtures/includes/foo.php'); + +$this->services['method_call1'] = $instance = new \Bar\FooClass(); + +$instance->setBar(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->load('getFooService.php')) && false ?: '_'}); +$instance->setBar(NULL); +$instance->setBar((${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->load('getFooService.php')) && false ?: '_'}->foo() . (($this->hasParameter("foo")) ? ($this->getParameter("foo")) : ("default")))); + +return $instance; + + [Container%s/getNewFactoryServiceService.php] => foo = 'bar'; + +$this->services['new_factory_service'] = $instance = $a->getInstance(); + +$instance->foo = 'bar'; + +return $instance; + + [Container%s/getServiceFromStaticMethodService.php] => services['service_from_static_method'] = \Bar\FooClass::getInstance(); + + [Container%s/getTaggedIteratorService.php] => services['tagged_iterator'] = new \Bar(new RewindableGenerator(function () { + yield 0 => ${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->load('getFooService.php')) && false ?: '_'}; + yield 1 => ${($_ = isset($this->services['tagged_iterator_foo']) ? $this->services['tagged_iterator_foo'] : ($this->services['tagged_iterator_foo'] = new \Bar())) && false ?: '_'}; +}, 2)); + + [Container%s/getTaggedIteratorFooService.php] => services['tagged_iterator_foo'] = new \Bar(); + + [Container%s/ProjectServiceContainer.php] => targetDirs[0] = \dirname($containerDir); + for ($i = 1; $i <= 5; ++$i) { + $this->targetDirs[$i] = $dir = \dirname($dir); + } + $this->buildParameters = $buildParameters; + $this->containerDir = $containerDir; + $this->parameters = $this->getDefaultParameters(); + + $this->services = []; + $this->syntheticIds = [ + 'request' => true, + ]; + $this->methodMap = [ + 'bar' => 'getBarService', + 'foo_bar' => 'getFooBarService', + ]; + $this->fileMap = [ + 'baz' => 'getBazService.php', + 'configured_service' => 'getConfiguredServiceService.php', + 'configured_service_simple' => 'getConfiguredServiceSimpleService.php', + 'decorator_service' => 'getDecoratorServiceService.php', + 'decorator_service_with_name' => 'getDecoratorServiceWithNameService.php', + 'deprecated_service' => 'getDeprecatedServiceService.php', + 'factory_service' => 'getFactoryServiceService.php', + 'factory_service_simple' => 'getFactoryServiceSimpleService.php', + 'factory_simple' => 'getFactorySimpleService.php', + 'foo' => 'getFooService.php', + 'foo.baz' => 'getFoo_BazService.php', + 'foo_with_inline' => 'getFooWithInlineService.php', + 'lazy_context' => 'getLazyContextService.php', + 'lazy_context_ignore_invalid_ref' => 'getLazyContextIgnoreInvalidRefService.php', + 'method_call1' => 'getMethodCall1Service.php', + 'new_factory_service' => 'getNewFactoryServiceService.php', + 'service_from_static_method' => 'getServiceFromStaticMethodService.php', + 'tagged_iterator' => 'getTaggedIteratorService.php', + 'tagged_iterator_foo' => 'getTaggedIteratorFooService.php', + ]; + $this->privates = [ + 'factory_simple' => true, + 'tagged_iterator_foo' => true, + ]; + $this->aliases = [ + 'alias_for_alias' => 'foo', + 'alias_for_foo' => 'foo', + 'decorated' => 'decorator_service_with_name', + ]; + } + + public function getRemovedIds() + { + return require $this->containerDir.\DIRECTORY_SEPARATOR.'removed-ids.php'; + } + + public function compile() + { + throw new LogicException('You cannot compile a dumped container that was already compiled.'); + } + + public function isCompiled() + { + return true; + } + + public function isFrozen() + { + @trigger_error(sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), E_USER_DEPRECATED); + + return true; + } + + protected function load($file, $lazyLoad = true) + { + return require $this->containerDir.\DIRECTORY_SEPARATOR.$file; + } + + /** + * Gets the public 'bar' shared service. + * + * @return \Bar\FooClass + */ + protected function getBarService() + { + $a = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->load('getFoo_BazService.php')) && false ?: '_'}; + + $this->services['bar'] = $instance = new \Bar\FooClass('foo', $a, $this->getParameter('foo_bar')); + + $a->configure($instance); + + return $instance; + } + + /** + * Gets the public 'foo_bar' service. + * + * @return \Bar\FooClass + */ + protected function getFooBarService() + { + return new \Bar\FooClass(${($_ = isset($this->services['deprecated_service']) ? $this->services['deprecated_service'] : $this->load('getDeprecatedServiceService.php')) && false ?: '_'}); + } + + public function getParameter($name) + { + $name = (string) $name; + if (isset($this->buildParameters[$name])) { + return $this->buildParameters[$name]; + } + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters))) { + throw new InvalidArgumentException(sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + + return $this->parameters[$name]; + } + + public function hasParameter($name) + { + $name = (string) $name; + if (isset($this->buildParameters[$name])) { + return true; + } + $name = $this->normalizeParameterName($name); + + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || array_key_exists($name, $this->parameters); + } + + public function setParameter($name, $value) + { + throw new LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + foreach ($this->buildParameters as $name => $value) { + $parameters[$name] = $value; + } + $this->parameterBag = new FrozenParameterBag($parameters); + } + + return $this->parameterBag; + } + + private $loadedDynamicParameters = []; + private $dynamicParameters = []; + + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + throw new InvalidArgumentException(sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + + private $normalizedParameterNames = []; + + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = strtolower($name)]) || isset($this->parameters[$normalizedName]) || array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @trigger_error(sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + + return $normalizedName; + } + + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return [ + 'baz_class' => 'BazClass', + 'foo_class' => 'Bar\\FooClass', + 'foo' => 'bar', + ]; + } +} + + [ProjectServiceContainer.php] => '%s', + 'container.build_id' => '%s', + 'container.build_time' => %d, +], __DIR__.\DIRECTORY_SEPARATOR.'Container%s'); + +) diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_compiled.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_compiled.php index 28b9aa24a..bf83203ce 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_compiled.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services9_compiled.php @@ -1,369 +1,369 @@ -parameters = $this->getDefaultParameters(); - $this->services = []; - $this->syntheticIds = ['request' => \true]; - $this->methodMap = ['bar' => 'getBarService', 'baz' => 'getBazService', 'configured_service' => 'getConfiguredServiceService', 'configured_service_simple' => 'getConfiguredServiceSimpleService', 'decorator_service' => 'getDecoratorServiceService', 'decorator_service_with_name' => 'getDecoratorServiceWithNameService', 'deprecated_service' => 'getDeprecatedServiceService', 'factory_service' => 'getFactoryServiceService', 'factory_service_simple' => 'getFactoryServiceSimpleService', 'factory_simple' => 'getFactorySimpleService', 'foo' => 'getFooService', 'foo.baz' => 'getFoo_BazService', 'foo_bar' => 'getFooBarService', 'foo_with_inline' => 'getFooWithInlineService', 'lazy_context' => 'getLazyContextService', 'lazy_context_ignore_invalid_ref' => 'getLazyContextIgnoreInvalidRefService', 'method_call1' => 'getMethodCall1Service', 'new_factory_service' => 'getNewFactoryServiceService', 'service_from_static_method' => 'getServiceFromStaticMethodService', 'tagged_iterator' => 'getTaggedIteratorService', 'tagged_iterator_foo' => 'getTaggedIteratorFooService']; - $this->privates = ['factory_simple' => \true, 'tagged_iterator_foo' => \true]; - $this->aliases = ['alias_for_alias' => 'foo', 'alias_for_foo' => 'foo', 'decorated' => 'decorator_service_with_name']; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'configurator_service' => \true, 'configurator_service_simple' => \true, 'decorated.pif-pouf' => \true, 'decorator_service.inner' => \true, 'factory_simple' => \true, 'inlined' => \true, 'new_factory' => \true, 'tagged_iterator_foo' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar' shared service. - * - * @return \Bar\FooClass - */ - protected function getBarService() - { - $a = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}; - $this->services['bar'] = $instance = new \_PhpScoper5ea00cc67502b\Bar\FooClass('foo', $a, $this->getParameter('foo_bar')); - $a->configure($instance); - return $instance; - } - /** - * Gets the public 'baz' shared service. - * - * @return \Baz - */ - protected function getBazService() - { - $this->services['baz'] = $instance = new \_PhpScoper5ea00cc67502b\Baz(); - $instance->setFoo(${($_ = isset($this->services['foo_with_inline']) ? $this->services['foo_with_inline'] : $this->getFooWithInlineService()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the public 'configured_service' shared service. - * - * @return \stdClass - */ - protected function getConfiguredServiceService() - { - $this->services['configured_service'] = $instance = new \stdClass(); - $a = new \_PhpScoper5ea00cc67502b\ConfClass(); - $a->setFoo(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->getBazService()) && \false ?: '_'}); - $a->configureStdClass($instance); - return $instance; - } - /** - * Gets the public 'configured_service_simple' shared service. - * - * @return \stdClass - */ - protected function getConfiguredServiceSimpleService() - { - $this->services['configured_service_simple'] = $instance = new \stdClass(); - (new \_PhpScoper5ea00cc67502b\ConfClass('bar'))->configureStdClass($instance); - return $instance; - } - /** - * Gets the public 'decorator_service' shared service. - * - * @return \stdClass - */ - protected function getDecoratorServiceService() - { - return $this->services['decorator_service'] = new \stdClass(); - } - /** - * Gets the public 'decorator_service_with_name' shared service. - * - * @return \stdClass - */ - protected function getDecoratorServiceWithNameService() - { - return $this->services['decorator_service_with_name'] = new \stdClass(); - } - /** - * Gets the public 'deprecated_service' shared service. - * - * @return \stdClass - * - * @deprecated The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed. - */ - protected function getDeprecatedServiceService() - { - @\trigger_error('The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed.', \E_USER_DEPRECATED); - return $this->services['deprecated_service'] = new \stdClass(); - } - /** - * Gets the public 'factory_service' shared service. - * - * @return \Bar - */ - protected function getFactoryServiceService() - { - return $this->services['factory_service'] = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}->getInstance(); - } - /** - * Gets the public 'factory_service_simple' shared service. - * - * @return \Bar - */ - protected function getFactoryServiceSimpleService() - { - return $this->services['factory_service_simple'] = ${($_ = isset($this->services['factory_simple']) ? $this->services['factory_simple'] : $this->getFactorySimpleService()) && \false ?: '_'}->getInstance(); - } - /** - * Gets the public 'foo' shared service. - * - * @return \Bar\FooClass - */ - protected function getFooService() - { - $a = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}; - $this->services['foo'] = $instance = \_PhpScoper5ea00cc67502b\Bar\FooClass::getInstance('foo', $a, ['bar' => 'foo is bar', 'foobar' => 'bar'], \true, $this); - $instance->foo = 'bar'; - $instance->moo = $a; - $instance->qux = ['bar' => 'foo is bar', 'foobar' => 'bar']; - $instance->setBar(${($_ = isset($this->services['bar']) ? $this->services['bar'] : $this->getBarService()) && \false ?: '_'}); - $instance->initialize(); - \_PhpScoper5ea00cc67502b\sc_configure($instance); - return $instance; - } - /** - * Gets the public 'foo.baz' shared service. - * - * @return \BazClass - */ - protected function getFoo_BazService() - { - $this->services['foo.baz'] = $instance = \_PhpScoper5ea00cc67502b\BazClass::getInstance(); - \_PhpScoper5ea00cc67502b\BazClass::configureStatic1($instance); - return $instance; - } - /** - * Gets the public 'foo_bar' service. - * - * @return \Bar\FooClass - */ - protected function getFooBarService() - { - return new \_PhpScoper5ea00cc67502b\Bar\FooClass(${($_ = isset($this->services['deprecated_service']) ? $this->services['deprecated_service'] : $this->getDeprecatedServiceService()) && \false ?: '_'}); - } - /** - * Gets the public 'foo_with_inline' shared service. - * - * @return \Foo - */ - protected function getFooWithInlineService() - { - $this->services['foo_with_inline'] = $instance = new \_PhpScoper5ea00cc67502b\Foo(); - $a = new \_PhpScoper5ea00cc67502b\Bar(); - $a->pub = 'pub'; - $a->setBaz(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->getBazService()) && \false ?: '_'}); - $instance->setBar($a); - return $instance; - } - /** - * Gets the public 'lazy_context' shared service. - * - * @return \LazyContext - */ - protected function getLazyContextService() - { - return $this->services['lazy_context'] = new \_PhpScoper5ea00cc67502b\LazyContext(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - (yield 'k1' => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}); - (yield 'k2' => $this); - }, 2), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - return new \EmptyIterator(); - }, 0)); - } - /** - * Gets the public 'lazy_context_ignore_invalid_ref' shared service. - * - * @return \LazyContext - */ - protected function getLazyContextIgnoreInvalidRefService() - { - return $this->services['lazy_context_ignore_invalid_ref'] = new \_PhpScoper5ea00cc67502b\LazyContext(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - (yield 0 => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}); - }, 1), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - return new \EmptyIterator(); - }, 0)); - } - /** - * Gets the public 'method_call1' shared service. - * - * @return \Bar\FooClass - */ - protected function getMethodCall1Service() - { - include_once '%path%foo.php'; - $this->services['method_call1'] = $instance = new \_PhpScoper5ea00cc67502b\Bar\FooClass(); - $instance->setBar(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}); - $instance->setBar(\NULL); - $instance->setBar(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}->foo() . ($this->hasParameter("foo") ? $this->getParameter("foo") : "default")); - return $instance; - } - /** - * Gets the public 'new_factory_service' shared service. - * - * @return \FooBarBaz - */ - protected function getNewFactoryServiceService() - { - $a = new \_PhpScoper5ea00cc67502b\FactoryClass(); - $a->foo = 'bar'; - $this->services['new_factory_service'] = $instance = $a->getInstance(); - $instance->foo = 'bar'; - return $instance; - } - /** - * Gets the public 'service_from_static_method' shared service. - * - * @return \Bar\FooClass - */ - protected function getServiceFromStaticMethodService() - { - return $this->services['service_from_static_method'] = \_PhpScoper5ea00cc67502b\Bar\FooClass::getInstance(); - } - /** - * Gets the public 'tagged_iterator' shared service. - * - * @return \Bar - */ - protected function getTaggedIteratorService() - { - return $this->services['tagged_iterator'] = new \_PhpScoper5ea00cc67502b\Bar(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - (yield 0 => ${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}); - (yield 1 => ${($_ = isset($this->services['tagged_iterator_foo']) ? $this->services['tagged_iterator_foo'] : ($this->services['tagged_iterator_foo'] = new \_PhpScoper5ea00cc67502b\Bar())) && \false ?: '_'}); - }, 2)); - } - /** - * Gets the private 'factory_simple' shared service. - * - * @return \SimpleFactoryClass - * - * @deprecated The "factory_simple" service is deprecated. You should stop using it, as it will soon be removed. - */ - protected function getFactorySimpleService() - { - @\trigger_error('The "factory_simple" service is deprecated. You should stop using it, as it will soon be removed.', \E_USER_DEPRECATED); - return $this->services['factory_simple'] = new \_PhpScoper5ea00cc67502b\SimpleFactoryClass('foo'); - } - /** - * Gets the private 'tagged_iterator_foo' shared service. - * - * @return \Bar - */ - protected function getTaggedIteratorFooService() - { - return $this->services['tagged_iterator_foo'] = new \_PhpScoper5ea00cc67502b\Bar(); - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = []; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - private $normalizedParameterNames = []; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['baz_class' => 'BazClass', 'foo_class' => '_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'foo' => 'bar']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +parameters = $this->getDefaultParameters(); + $this->services = []; + $this->syntheticIds = ['request' => \true]; + $this->methodMap = ['bar' => 'getBarService', 'baz' => 'getBazService', 'configured_service' => 'getConfiguredServiceService', 'configured_service_simple' => 'getConfiguredServiceSimpleService', 'decorator_service' => 'getDecoratorServiceService', 'decorator_service_with_name' => 'getDecoratorServiceWithNameService', 'deprecated_service' => 'getDeprecatedServiceService', 'factory_service' => 'getFactoryServiceService', 'factory_service_simple' => 'getFactoryServiceSimpleService', 'factory_simple' => 'getFactorySimpleService', 'foo' => 'getFooService', 'foo.baz' => 'getFoo_BazService', 'foo_bar' => 'getFooBarService', 'foo_with_inline' => 'getFooWithInlineService', 'lazy_context' => 'getLazyContextService', 'lazy_context_ignore_invalid_ref' => 'getLazyContextIgnoreInvalidRefService', 'method_call1' => 'getMethodCall1Service', 'new_factory_service' => 'getNewFactoryServiceService', 'service_from_static_method' => 'getServiceFromStaticMethodService', 'tagged_iterator' => 'getTaggedIteratorService', 'tagged_iterator_foo' => 'getTaggedIteratorFooService']; + $this->privates = ['factory_simple' => \true, 'tagged_iterator_foo' => \true]; + $this->aliases = ['alias_for_alias' => 'foo', 'alias_for_foo' => 'foo', 'decorated' => 'decorator_service_with_name']; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'configurator_service' => \true, 'configurator_service_simple' => \true, 'decorated.pif-pouf' => \true, 'decorator_service.inner' => \true, 'factory_simple' => \true, 'inlined' => \true, 'new_factory' => \true, 'tagged_iterator_foo' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar' shared service. + * + * @return \Bar\FooClass + */ + protected function getBarService() + { + $a = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}; + $this->services['bar'] = $instance = new \_PhpScoper5ea00cc67502b\Bar\FooClass('foo', $a, $this->getParameter('foo_bar')); + $a->configure($instance); + return $instance; + } + /** + * Gets the public 'baz' shared service. + * + * @return \Baz + */ + protected function getBazService() + { + $this->services['baz'] = $instance = new \_PhpScoper5ea00cc67502b\Baz(); + $instance->setFoo(${($_ = isset($this->services['foo_with_inline']) ? $this->services['foo_with_inline'] : $this->getFooWithInlineService()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the public 'configured_service' shared service. + * + * @return \stdClass + */ + protected function getConfiguredServiceService() + { + $this->services['configured_service'] = $instance = new \stdClass(); + $a = new \_PhpScoper5ea00cc67502b\ConfClass(); + $a->setFoo(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->getBazService()) && \false ?: '_'}); + $a->configureStdClass($instance); + return $instance; + } + /** + * Gets the public 'configured_service_simple' shared service. + * + * @return \stdClass + */ + protected function getConfiguredServiceSimpleService() + { + $this->services['configured_service_simple'] = $instance = new \stdClass(); + (new \_PhpScoper5ea00cc67502b\ConfClass('bar'))->configureStdClass($instance); + return $instance; + } + /** + * Gets the public 'decorator_service' shared service. + * + * @return \stdClass + */ + protected function getDecoratorServiceService() + { + return $this->services['decorator_service'] = new \stdClass(); + } + /** + * Gets the public 'decorator_service_with_name' shared service. + * + * @return \stdClass + */ + protected function getDecoratorServiceWithNameService() + { + return $this->services['decorator_service_with_name'] = new \stdClass(); + } + /** + * Gets the public 'deprecated_service' shared service. + * + * @return \stdClass + * + * @deprecated The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed. + */ + protected function getDeprecatedServiceService() + { + @\trigger_error('The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed.', \E_USER_DEPRECATED); + return $this->services['deprecated_service'] = new \stdClass(); + } + /** + * Gets the public 'factory_service' shared service. + * + * @return \Bar + */ + protected function getFactoryServiceService() + { + return $this->services['factory_service'] = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}->getInstance(); + } + /** + * Gets the public 'factory_service_simple' shared service. + * + * @return \Bar + */ + protected function getFactoryServiceSimpleService() + { + return $this->services['factory_service_simple'] = ${($_ = isset($this->services['factory_simple']) ? $this->services['factory_simple'] : $this->getFactorySimpleService()) && \false ?: '_'}->getInstance(); + } + /** + * Gets the public 'foo' shared service. + * + * @return \Bar\FooClass + */ + protected function getFooService() + { + $a = ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}; + $this->services['foo'] = $instance = \_PhpScoper5ea00cc67502b\Bar\FooClass::getInstance('foo', $a, ['bar' => 'foo is bar', 'foobar' => 'bar'], \true, $this); + $instance->foo = 'bar'; + $instance->moo = $a; + $instance->qux = ['bar' => 'foo is bar', 'foobar' => 'bar']; + $instance->setBar(${($_ = isset($this->services['bar']) ? $this->services['bar'] : $this->getBarService()) && \false ?: '_'}); + $instance->initialize(); + \_PhpScoper5ea00cc67502b\sc_configure($instance); + return $instance; + } + /** + * Gets the public 'foo.baz' shared service. + * + * @return \BazClass + */ + protected function getFoo_BazService() + { + $this->services['foo.baz'] = $instance = \_PhpScoper5ea00cc67502b\BazClass::getInstance(); + \_PhpScoper5ea00cc67502b\BazClass::configureStatic1($instance); + return $instance; + } + /** + * Gets the public 'foo_bar' service. + * + * @return \Bar\FooClass + */ + protected function getFooBarService() + { + return new \_PhpScoper5ea00cc67502b\Bar\FooClass(${($_ = isset($this->services['deprecated_service']) ? $this->services['deprecated_service'] : $this->getDeprecatedServiceService()) && \false ?: '_'}); + } + /** + * Gets the public 'foo_with_inline' shared service. + * + * @return \Foo + */ + protected function getFooWithInlineService() + { + $this->services['foo_with_inline'] = $instance = new \_PhpScoper5ea00cc67502b\Foo(); + $a = new \_PhpScoper5ea00cc67502b\Bar(); + $a->pub = 'pub'; + $a->setBaz(${($_ = isset($this->services['baz']) ? $this->services['baz'] : $this->getBazService()) && \false ?: '_'}); + $instance->setBar($a); + return $instance; + } + /** + * Gets the public 'lazy_context' shared service. + * + * @return \LazyContext + */ + protected function getLazyContextService() + { + return $this->services['lazy_context'] = new \_PhpScoper5ea00cc67502b\LazyContext(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + (yield 'k1' => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}); + (yield 'k2' => $this); + }, 2), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + return new \EmptyIterator(); + }, 0)); + } + /** + * Gets the public 'lazy_context_ignore_invalid_ref' shared service. + * + * @return \LazyContext + */ + protected function getLazyContextIgnoreInvalidRefService() + { + return $this->services['lazy_context_ignore_invalid_ref'] = new \_PhpScoper5ea00cc67502b\LazyContext(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + (yield 0 => ${($_ = isset($this->services['foo.baz']) ? $this->services['foo.baz'] : $this->getFoo_BazService()) && \false ?: '_'}); + }, 1), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + return new \EmptyIterator(); + }, 0)); + } + /** + * Gets the public 'method_call1' shared service. + * + * @return \Bar\FooClass + */ + protected function getMethodCall1Service() + { + include_once '%path%foo.php'; + $this->services['method_call1'] = $instance = new \_PhpScoper5ea00cc67502b\Bar\FooClass(); + $instance->setBar(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}); + $instance->setBar(\NULL); + $instance->setBar(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}->foo() . ($this->hasParameter("foo") ? $this->getParameter("foo") : "default")); + return $instance; + } + /** + * Gets the public 'new_factory_service' shared service. + * + * @return \FooBarBaz + */ + protected function getNewFactoryServiceService() + { + $a = new \_PhpScoper5ea00cc67502b\FactoryClass(); + $a->foo = 'bar'; + $this->services['new_factory_service'] = $instance = $a->getInstance(); + $instance->foo = 'bar'; + return $instance; + } + /** + * Gets the public 'service_from_static_method' shared service. + * + * @return \Bar\FooClass + */ + protected function getServiceFromStaticMethodService() + { + return $this->services['service_from_static_method'] = \_PhpScoper5ea00cc67502b\Bar\FooClass::getInstance(); + } + /** + * Gets the public 'tagged_iterator' shared service. + * + * @return \Bar + */ + protected function getTaggedIteratorService() + { + return $this->services['tagged_iterator'] = new \_PhpScoper5ea00cc67502b\Bar(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + (yield 0 => ${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}); + (yield 1 => ${($_ = isset($this->services['tagged_iterator_foo']) ? $this->services['tagged_iterator_foo'] : ($this->services['tagged_iterator_foo'] = new \_PhpScoper5ea00cc67502b\Bar())) && \false ?: '_'}); + }, 2)); + } + /** + * Gets the private 'factory_simple' shared service. + * + * @return \SimpleFactoryClass + * + * @deprecated The "factory_simple" service is deprecated. You should stop using it, as it will soon be removed. + */ + protected function getFactorySimpleService() + { + @\trigger_error('The "factory_simple" service is deprecated. You should stop using it, as it will soon be removed.', \E_USER_DEPRECATED); + return $this->services['factory_simple'] = new \_PhpScoper5ea00cc67502b\SimpleFactoryClass('foo'); + } + /** + * Gets the private 'tagged_iterator_foo' shared service. + * + * @return \Bar + */ + protected function getTaggedIteratorFooService() + { + return $this->services['tagged_iterator_foo'] = new \_PhpScoper5ea00cc67502b\Bar(); + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = []; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + private $normalizedParameterNames = []; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['baz_class' => 'BazClass', 'foo_class' => '_PhpScoper5ea00cc67502b\\Bar\\FooClass', 'foo' => 'bar']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_adawson.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_adawson.php index 0f839c9c7..838fddd1e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_adawson.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_adawson.php @@ -1,140 +1,140 @@ -services = []; - $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\app\\bus' => '_PhpScoper5ea00cc67502b\\App\\Bus', '_PhpScoper5ea00cc67502b\\app\\db' => '_PhpScoper5ea00cc67502b\\App\\Db', '_PhpScoper5ea00cc67502b\\app\\handler1' => '_PhpScoper5ea00cc67502b\\App\\Handler1', '_PhpScoper5ea00cc67502b\\app\\handler2' => '_PhpScoper5ea00cc67502b\\App\\Handler2', '_PhpScoper5ea00cc67502b\\app\\processor' => '_PhpScoper5ea00cc67502b\\App\\Processor', '_PhpScoper5ea00cc67502b\\app\\registry' => '_PhpScoper5ea00cc67502b\\App\\Registry', '_PhpScoper5ea00cc67502b\\app\\schema' => '_PhpScoper5ea00cc67502b\\App\\Schema']; - $this->methodMap = ['_PhpScoper5ea00cc67502b\\App\\Bus' => 'getBusService', '_PhpScoper5ea00cc67502b\\App\\Db' => 'getDbService', '_PhpScoper5ea00cc67502b\\App\\Handler1' => 'getHandler1Service', '_PhpScoper5ea00cc67502b\\App\\Handler2' => 'getHandler2Service', '_PhpScoper5ea00cc67502b\\App\\Processor' => 'getProcessorService', '_PhpScoper5ea00cc67502b\\App\\Registry' => 'getRegistryService', '_PhpScoper5ea00cc67502b\\App\\Schema' => 'getSchemaService']; - $this->privates = ['_PhpScoper5ea00cc67502b\\App\\Handler1' => \true, '_PhpScoper5ea00cc67502b\\App\\Handler2' => \true, '_PhpScoper5ea00cc67502b\\App\\Processor' => \true, '_PhpScoper5ea00cc67502b\\App\\Registry' => \true, '_PhpScoper5ea00cc67502b\\App\\Schema' => \true]; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\App\\Handler1' => \true, '_PhpScoper5ea00cc67502b\\App\\Handler2' => \true, '_PhpScoper5ea00cc67502b\\App\\Processor' => \true, '_PhpScoper5ea00cc67502b\\App\\Registry' => \true, '_PhpScoper5ea00cc67502b\\App\\Schema' => \true, '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'App\Bus' shared service. - * - * @return \App\Bus - */ - protected function getBusService() - { - $this->services['App\\Bus'] = $instance = new \_PhpScoper5ea00cc67502b\App\Bus(${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}); - $instance->handler1 = ${($_ = isset($this->services['App\\Handler1']) ? $this->services['App\\Handler1'] : $this->getHandler1Service()) && \false ?: '_'}; - $instance->handler2 = ${($_ = isset($this->services['App\\Handler2']) ? $this->services['App\\Handler2'] : $this->getHandler2Service()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'App\Db' shared service. - * - * @return \App\Db - */ - protected function getDbService() - { - $this->services['App\\Db'] = $instance = new \_PhpScoper5ea00cc67502b\App\Db(); - $instance->schema = ${($_ = isset($this->services['App\\Schema']) ? $this->services['App\\Schema'] : $this->getSchemaService()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the private 'App\Handler1' shared service. - * - * @return \App\Handler1 - */ - protected function getHandler1Service() - { - $a = ${($_ = isset($this->services['App\\Processor']) ? $this->services['App\\Processor'] : $this->getProcessorService()) && \false ?: '_'}; - if (isset($this->services['App\\Handler1'])) { - return $this->services['App\\Handler1']; - } - return $this->services['App\\Handler1'] = new \_PhpScoper5ea00cc67502b\App\Handler1(${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}, ${($_ = isset($this->services['App\\Schema']) ? $this->services['App\\Schema'] : $this->getSchemaService()) && \false ?: '_'}, $a); - } - /** - * Gets the private 'App\Handler2' shared service. - * - * @return \App\Handler2 - */ - protected function getHandler2Service() - { - $a = ${($_ = isset($this->services['App\\Processor']) ? $this->services['App\\Processor'] : $this->getProcessorService()) && \false ?: '_'}; - if (isset($this->services['App\\Handler2'])) { - return $this->services['App\\Handler2']; - } - return $this->services['App\\Handler2'] = new \_PhpScoper5ea00cc67502b\App\Handler2(${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}, ${($_ = isset($this->services['App\\Schema']) ? $this->services['App\\Schema'] : $this->getSchemaService()) && \false ?: '_'}, $a); - } - /** - * Gets the private 'App\Processor' shared service. - * - * @return \App\Processor - */ - protected function getProcessorService() - { - $a = ${($_ = isset($this->services['App\\Registry']) ? $this->services['App\\Registry'] : $this->getRegistryService()) && \false ?: '_'}; - if (isset($this->services['App\\Processor'])) { - return $this->services['App\\Processor']; - } - return $this->services['App\\Processor'] = new \_PhpScoper5ea00cc67502b\App\Processor($a, ${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}); - } - /** - * Gets the private 'App\Registry' shared service. - * - * @return \App\Registry - */ - protected function getRegistryService() - { - $this->services['App\\Registry'] = $instance = new \_PhpScoper5ea00cc67502b\App\Registry(); - $instance->processor = [0 => ${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}, 1 => ${($_ = isset($this->services['App\\Bus']) ? $this->services['App\\Bus'] : $this->getBusService()) && \false ?: '_'}]; - return $instance; - } - /** - * Gets the private 'App\Schema' shared service. - * - * @return \App\Schema - */ - protected function getSchemaService() - { - $a = ${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}; - if (isset($this->services['App\\Schema'])) { - return $this->services['App\\Schema']; - } - return $this->services['App\\Schema'] = new \_PhpScoper5ea00cc67502b\App\Schema($a); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +services = []; + $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\app\\bus' => '_PhpScoper5ea00cc67502b\\App\\Bus', '_PhpScoper5ea00cc67502b\\app\\db' => '_PhpScoper5ea00cc67502b\\App\\Db', '_PhpScoper5ea00cc67502b\\app\\handler1' => '_PhpScoper5ea00cc67502b\\App\\Handler1', '_PhpScoper5ea00cc67502b\\app\\handler2' => '_PhpScoper5ea00cc67502b\\App\\Handler2', '_PhpScoper5ea00cc67502b\\app\\processor' => '_PhpScoper5ea00cc67502b\\App\\Processor', '_PhpScoper5ea00cc67502b\\app\\registry' => '_PhpScoper5ea00cc67502b\\App\\Registry', '_PhpScoper5ea00cc67502b\\app\\schema' => '_PhpScoper5ea00cc67502b\\App\\Schema']; + $this->methodMap = ['_PhpScoper5ea00cc67502b\\App\\Bus' => 'getBusService', '_PhpScoper5ea00cc67502b\\App\\Db' => 'getDbService', '_PhpScoper5ea00cc67502b\\App\\Handler1' => 'getHandler1Service', '_PhpScoper5ea00cc67502b\\App\\Handler2' => 'getHandler2Service', '_PhpScoper5ea00cc67502b\\App\\Processor' => 'getProcessorService', '_PhpScoper5ea00cc67502b\\App\\Registry' => 'getRegistryService', '_PhpScoper5ea00cc67502b\\App\\Schema' => 'getSchemaService']; + $this->privates = ['_PhpScoper5ea00cc67502b\\App\\Handler1' => \true, '_PhpScoper5ea00cc67502b\\App\\Handler2' => \true, '_PhpScoper5ea00cc67502b\\App\\Processor' => \true, '_PhpScoper5ea00cc67502b\\App\\Registry' => \true, '_PhpScoper5ea00cc67502b\\App\\Schema' => \true]; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\App\\Handler1' => \true, '_PhpScoper5ea00cc67502b\\App\\Handler2' => \true, '_PhpScoper5ea00cc67502b\\App\\Processor' => \true, '_PhpScoper5ea00cc67502b\\App\\Registry' => \true, '_PhpScoper5ea00cc67502b\\App\\Schema' => \true, '_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'App\Bus' shared service. + * + * @return \App\Bus + */ + protected function getBusService() + { + $this->services['App\\Bus'] = $instance = new \_PhpScoper5ea00cc67502b\App\Bus(${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}); + $instance->handler1 = ${($_ = isset($this->services['App\\Handler1']) ? $this->services['App\\Handler1'] : $this->getHandler1Service()) && \false ?: '_'}; + $instance->handler2 = ${($_ = isset($this->services['App\\Handler2']) ? $this->services['App\\Handler2'] : $this->getHandler2Service()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'App\Db' shared service. + * + * @return \App\Db + */ + protected function getDbService() + { + $this->services['App\\Db'] = $instance = new \_PhpScoper5ea00cc67502b\App\Db(); + $instance->schema = ${($_ = isset($this->services['App\\Schema']) ? $this->services['App\\Schema'] : $this->getSchemaService()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the private 'App\Handler1' shared service. + * + * @return \App\Handler1 + */ + protected function getHandler1Service() + { + $a = ${($_ = isset($this->services['App\\Processor']) ? $this->services['App\\Processor'] : $this->getProcessorService()) && \false ?: '_'}; + if (isset($this->services['App\\Handler1'])) { + return $this->services['App\\Handler1']; + } + return $this->services['App\\Handler1'] = new \_PhpScoper5ea00cc67502b\App\Handler1(${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}, ${($_ = isset($this->services['App\\Schema']) ? $this->services['App\\Schema'] : $this->getSchemaService()) && \false ?: '_'}, $a); + } + /** + * Gets the private 'App\Handler2' shared service. + * + * @return \App\Handler2 + */ + protected function getHandler2Service() + { + $a = ${($_ = isset($this->services['App\\Processor']) ? $this->services['App\\Processor'] : $this->getProcessorService()) && \false ?: '_'}; + if (isset($this->services['App\\Handler2'])) { + return $this->services['App\\Handler2']; + } + return $this->services['App\\Handler2'] = new \_PhpScoper5ea00cc67502b\App\Handler2(${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}, ${($_ = isset($this->services['App\\Schema']) ? $this->services['App\\Schema'] : $this->getSchemaService()) && \false ?: '_'}, $a); + } + /** + * Gets the private 'App\Processor' shared service. + * + * @return \App\Processor + */ + protected function getProcessorService() + { + $a = ${($_ = isset($this->services['App\\Registry']) ? $this->services['App\\Registry'] : $this->getRegistryService()) && \false ?: '_'}; + if (isset($this->services['App\\Processor'])) { + return $this->services['App\\Processor']; + } + return $this->services['App\\Processor'] = new \_PhpScoper5ea00cc67502b\App\Processor($a, ${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}); + } + /** + * Gets the private 'App\Registry' shared service. + * + * @return \App\Registry + */ + protected function getRegistryService() + { + $this->services['App\\Registry'] = $instance = new \_PhpScoper5ea00cc67502b\App\Registry(); + $instance->processor = [0 => ${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}, 1 => ${($_ = isset($this->services['App\\Bus']) ? $this->services['App\\Bus'] : $this->getBusService()) && \false ?: '_'}]; + return $instance; + } + /** + * Gets the private 'App\Schema' shared service. + * + * @return \App\Schema + */ + protected function getSchemaService() + { + $a = ${($_ = isset($this->services['App\\Db']) ? $this->services['App\\Db'] : $this->getDbService()) && \false ?: '_'}; + if (isset($this->services['App\\Schema'])) { + return $this->services['App\\Schema']; + } + return $this->services['App\\Schema'] = new \_PhpScoper5ea00cc67502b\App\Schema($a); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_almost_circular_private.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_almost_circular_private.php index 344947f06..92015f466 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_almost_circular_private.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_almost_circular_private.php @@ -1,368 +1,368 @@ -services = []; - $this->methodMap = ['bar2' => 'getBar2Service', 'bar3' => 'getBar3Service', 'bar6' => 'getBar6Service', 'baz6' => 'getBaz6Service', 'connection' => 'getConnectionService', 'connection2' => 'getConnection2Service', 'foo' => 'getFooService', 'foo2' => 'getFoo2Service', 'foo5' => 'getFoo5Service', 'foo6' => 'getFoo6Service', 'foobar4' => 'getFoobar4Service', 'level2' => 'getLevel2Service', 'level3' => 'getLevel3Service', 'level4' => 'getLevel4Service', 'level5' => 'getLevel5Service', 'level6' => 'getLevel6Service', 'listener3' => 'getListener3Service', 'listener4' => 'getListener4Service', 'logger' => 'getLoggerService', 'manager' => 'getManagerService', 'manager2' => 'getManager2Service', 'manager3' => 'getManager3Service', 'manager4' => 'getManager4Service', 'multiuse1' => 'getMultiuse1Service', 'root' => 'getRootService', 'subscriber' => 'getSubscriberService']; - $this->privates = ['bar6' => \true, 'level2' => \true, 'level3' => \true, 'level4' => \true, 'level5' => \true, 'level6' => \true, 'manager4' => \true, 'multiuse1' => \true]; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'bar' => \true, 'bar5' => \true, 'bar6' => \true, 'config' => \true, 'config2' => \true, 'connection3' => \true, 'connection4' => \true, 'dispatcher' => \true, 'dispatcher2' => \true, 'foo4' => \true, 'foobar' => \true, 'foobar2' => \true, 'foobar3' => \true, 'level2' => \true, 'level3' => \true, 'level4' => \true, 'level5' => \true, 'level6' => \true, 'logger2' => \true, 'manager4' => \true, 'multiuse1' => \true, 'subscriber2' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar2' shared service. - * - * @return \BarCircular - */ - protected function getBar2Service() - { - $this->services['bar2'] = $instance = new \_PhpScoper5ea00cc67502b\BarCircular(); - $instance->addFoobar(new \_PhpScoper5ea00cc67502b\FoobarCircular(${($_ = isset($this->services['foo2']) ? $this->services['foo2'] : $this->getFoo2Service()) && \false ?: '_'})); - return $instance; - } - /** - * Gets the public 'bar3' shared service. - * - * @return \BarCircular - */ - protected function getBar3Service() - { - $this->services['bar3'] = $instance = new \_PhpScoper5ea00cc67502b\BarCircular(); - $a = new \_PhpScoper5ea00cc67502b\FoobarCircular(); - $instance->addFoobar($a, $a); - return $instance; - } - /** - * Gets the public 'baz6' shared service. - * - * @return \stdClass - */ - protected function getBaz6Service() - { - $this->services['baz6'] = $instance = new \stdClass(); - $instance->bar6 = ${($_ = isset($this->services['bar6']) ? $this->services['bar6'] : $this->getBar6Service()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'connection' shared service. - * - * @return \stdClass - */ - protected function getConnectionService() - { - $a = new \stdClass(); - $b = new \stdClass(); - $this->services['connection'] = $instance = new \stdClass($a, $b); - $b->logger = ${($_ = isset($this->services['logger']) ? $this->services['logger'] : $this->getLoggerService()) && \false ?: '_'}; - $a->subscriber = ${($_ = isset($this->services['subscriber']) ? $this->services['subscriber'] : $this->getSubscriberService()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'connection2' shared service. - * - * @return \stdClass - */ - protected function getConnection2Service() - { - $a = new \stdClass(); - $b = new \stdClass(); - $this->services['connection2'] = $instance = new \stdClass($a, $b); - $c = new \stdClass($instance); - $d = ${($_ = isset($this->services['manager2']) ? $this->services['manager2'] : $this->getManager2Service()) && \false ?: '_'}; - $c->handler2 = new \stdClass($d); - $b->logger2 = $c; - $a->subscriber2 = new \stdClass($d); - return $instance; - } - /** - * Gets the public 'foo' shared service. - * - * @return \FooCircular - */ - protected function getFooService() - { - $a = new \_PhpScoper5ea00cc67502b\BarCircular(); - $this->services['foo'] = $instance = new \_PhpScoper5ea00cc67502b\FooCircular($a); - $a->addFoobar(new \_PhpScoper5ea00cc67502b\FoobarCircular($instance)); - return $instance; - } - /** - * Gets the public 'foo2' shared service. - * - * @return \FooCircular - */ - protected function getFoo2Service() - { - $a = ${($_ = isset($this->services['bar2']) ? $this->services['bar2'] : $this->getBar2Service()) && \false ?: '_'}; - if (isset($this->services['foo2'])) { - return $this->services['foo2']; - } - return $this->services['foo2'] = new \_PhpScoper5ea00cc67502b\FooCircular($a); - } - /** - * Gets the public 'foo5' shared service. - * - * @return \stdClass - */ - protected function getFoo5Service() - { - $this->services['foo5'] = $instance = new \stdClass(); - $a = new \stdClass($instance); - $a->foo = $instance; - $instance->bar = $a; - return $instance; - } - /** - * Gets the public 'foo6' shared service. - * - * @return \stdClass - */ - protected function getFoo6Service() - { - $this->services['foo6'] = $instance = new \stdClass(); - $instance->bar6 = ${($_ = isset($this->services['bar6']) ? $this->services['bar6'] : $this->getBar6Service()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'foobar4' shared service. - * - * @return \stdClass - */ - protected function getFoobar4Service() - { - $a = new \stdClass(); - $this->services['foobar4'] = $instance = new \stdClass($a); - $a->foobar = $instance; - return $instance; - } - /** - * Gets the public 'listener3' shared service. - * - * @return \stdClass - */ - protected function getListener3Service() - { - $this->services['listener3'] = $instance = new \stdClass(); - $instance->manager = ${($_ = isset($this->services['manager3']) ? $this->services['manager3'] : $this->getManager3Service()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'listener4' shared service. - * - * @return \stdClass - */ - protected function getListener4Service() - { - $a = ${($_ = isset($this->services['manager4']) ? $this->services['manager4'] : $this->getManager4Service()) && \false ?: '_'}; - if (isset($this->services['listener4'])) { - return $this->services['listener4']; - } - return $this->services['listener4'] = new \stdClass($a); - } - /** - * Gets the public 'logger' shared service. - * - * @return \stdClass - */ - protected function getLoggerService() - { - $a = ${($_ = isset($this->services['connection']) ? $this->services['connection'] : $this->getConnectionService()) && \false ?: '_'}; - if (isset($this->services['logger'])) { - return $this->services['logger']; - } - $this->services['logger'] = $instance = new \stdClass($a); - $instance->handler = new \stdClass(${($_ = isset($this->services['manager']) ? $this->services['manager'] : $this->getManagerService()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the public 'manager' shared service. - * - * @return \stdClass - */ - protected function getManagerService() - { - $a = ${($_ = isset($this->services['connection']) ? $this->services['connection'] : $this->getConnectionService()) && \false ?: '_'}; - if (isset($this->services['manager'])) { - return $this->services['manager']; - } - return $this->services['manager'] = new \stdClass($a); - } - /** - * Gets the public 'manager2' shared service. - * - * @return \stdClass - */ - protected function getManager2Service() - { - $a = ${($_ = isset($this->services['connection2']) ? $this->services['connection2'] : $this->getConnection2Service()) && \false ?: '_'}; - if (isset($this->services['manager2'])) { - return $this->services['manager2']; - } - return $this->services['manager2'] = new \stdClass($a); - } - /** - * Gets the public 'manager3' shared service. - * - * @return \stdClass - */ - protected function getManager3Service($lazyLoad = \true) - { - $a = ${($_ = isset($this->services['listener3']) ? $this->services['listener3'] : $this->getListener3Service()) && \false ?: '_'}; - if (isset($this->services['manager3'])) { - return $this->services['manager3']; - } - $b = new \stdClass(); - $b->listener = [0 => $a]; - return $this->services['manager3'] = new \stdClass($b); - } - /** - * Gets the public 'root' shared service. - * - * @return \stdClass - */ - protected function getRootService() - { - return $this->services['root'] = new \stdClass(${($_ = isset($this->services['level2']) ? $this->services['level2'] : $this->getLevel2Service()) && \false ?: '_'}, ${($_ = isset($this->services['multiuse1']) ? $this->services['multiuse1'] : ($this->services['multiuse1'] = new \stdClass())) && \false ?: '_'}); - } - /** - * Gets the public 'subscriber' shared service. - * - * @return \stdClass - */ - protected function getSubscriberService() - { - $a = ${($_ = isset($this->services['manager']) ? $this->services['manager'] : $this->getManagerService()) && \false ?: '_'}; - if (isset($this->services['subscriber'])) { - return $this->services['subscriber']; - } - return $this->services['subscriber'] = new \stdClass($a); - } - /** - * Gets the private 'bar6' shared service. - * - * @return \stdClass - */ - protected function getBar6Service() - { - $a = ${($_ = isset($this->services['foo6']) ? $this->services['foo6'] : $this->getFoo6Service()) && \false ?: '_'}; - if (isset($this->services['bar6'])) { - return $this->services['bar6']; - } - return $this->services['bar6'] = new \stdClass($a); - } - /** - * Gets the private 'level2' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls - */ - protected function getLevel2Service() - { - $this->services['level2'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls(); - $instance->call(${($_ = isset($this->services['level3']) ? $this->services['level3'] : $this->getLevel3Service()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the private 'level3' shared service. - * - * @return \stdClass - */ - protected function getLevel3Service() - { - return $this->services['level3'] = new \stdClass(${($_ = isset($this->services['level4']) ? $this->services['level4'] : $this->getLevel4Service()) && \false ?: '_'}); - } - /** - * Gets the private 'level4' shared service. - * - * @return \stdClass - */ - protected function getLevel4Service() - { - return $this->services['level4'] = new \stdClass(${($_ = isset($this->services['multiuse1']) ? $this->services['multiuse1'] : ($this->services['multiuse1'] = new \stdClass())) && \false ?: '_'}, ${($_ = isset($this->services['level5']) ? $this->services['level5'] : $this->getLevel5Service()) && \false ?: '_'}); - } - /** - * Gets the private 'level5' shared service. - * - * @return \stdClass - */ - protected function getLevel5Service() - { - $a = ${($_ = isset($this->services['level6']) ? $this->services['level6'] : $this->getLevel6Service()) && \false ?: '_'}; - if (isset($this->services['level5'])) { - return $this->services['level5']; - } - return $this->services['level5'] = new \stdClass($a); - } - /** - * Gets the private 'level6' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls - */ - protected function getLevel6Service() - { - $this->services['level6'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls(); - $instance->call(${($_ = isset($this->services['level5']) ? $this->services['level5'] : $this->getLevel5Service()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the private 'manager4' shared service. - * - * @return \stdClass - */ - protected function getManager4Service($lazyLoad = \true) - { - $a = new \stdClass(); - $this->services['manager4'] = $instance = new \stdClass($a); - $a->listener = [0 => ${($_ = isset($this->services['listener4']) ? $this->services['listener4'] : $this->getListener4Service()) && \false ?: '_'}]; - return $instance; - } - /** - * Gets the private 'multiuse1' shared service. - * - * @return \stdClass - */ - protected function getMultiuse1Service() - { - return $this->services['multiuse1'] = new \stdClass(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Almost_Circular_Private', 'Symfony_DI_PhpDumper_Test_Almost_Circular_Private', \false); +services = []; + $this->methodMap = ['bar2' => 'getBar2Service', 'bar3' => 'getBar3Service', 'bar6' => 'getBar6Service', 'baz6' => 'getBaz6Service', 'connection' => 'getConnectionService', 'connection2' => 'getConnection2Service', 'foo' => 'getFooService', 'foo2' => 'getFoo2Service', 'foo5' => 'getFoo5Service', 'foo6' => 'getFoo6Service', 'foobar4' => 'getFoobar4Service', 'level2' => 'getLevel2Service', 'level3' => 'getLevel3Service', 'level4' => 'getLevel4Service', 'level5' => 'getLevel5Service', 'level6' => 'getLevel6Service', 'listener3' => 'getListener3Service', 'listener4' => 'getListener4Service', 'logger' => 'getLoggerService', 'manager' => 'getManagerService', 'manager2' => 'getManager2Service', 'manager3' => 'getManager3Service', 'manager4' => 'getManager4Service', 'multiuse1' => 'getMultiuse1Service', 'root' => 'getRootService', 'subscriber' => 'getSubscriberService']; + $this->privates = ['bar6' => \true, 'level2' => \true, 'level3' => \true, 'level4' => \true, 'level5' => \true, 'level6' => \true, 'manager4' => \true, 'multiuse1' => \true]; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'bar' => \true, 'bar5' => \true, 'bar6' => \true, 'config' => \true, 'config2' => \true, 'connection3' => \true, 'connection4' => \true, 'dispatcher' => \true, 'dispatcher2' => \true, 'foo4' => \true, 'foobar' => \true, 'foobar2' => \true, 'foobar3' => \true, 'level2' => \true, 'level3' => \true, 'level4' => \true, 'level5' => \true, 'level6' => \true, 'logger2' => \true, 'manager4' => \true, 'multiuse1' => \true, 'subscriber2' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar2' shared service. + * + * @return \BarCircular + */ + protected function getBar2Service() + { + $this->services['bar2'] = $instance = new \_PhpScoper5ea00cc67502b\BarCircular(); + $instance->addFoobar(new \_PhpScoper5ea00cc67502b\FoobarCircular(${($_ = isset($this->services['foo2']) ? $this->services['foo2'] : $this->getFoo2Service()) && \false ?: '_'})); + return $instance; + } + /** + * Gets the public 'bar3' shared service. + * + * @return \BarCircular + */ + protected function getBar3Service() + { + $this->services['bar3'] = $instance = new \_PhpScoper5ea00cc67502b\BarCircular(); + $a = new \_PhpScoper5ea00cc67502b\FoobarCircular(); + $instance->addFoobar($a, $a); + return $instance; + } + /** + * Gets the public 'baz6' shared service. + * + * @return \stdClass + */ + protected function getBaz6Service() + { + $this->services['baz6'] = $instance = new \stdClass(); + $instance->bar6 = ${($_ = isset($this->services['bar6']) ? $this->services['bar6'] : $this->getBar6Service()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'connection' shared service. + * + * @return \stdClass + */ + protected function getConnectionService() + { + $a = new \stdClass(); + $b = new \stdClass(); + $this->services['connection'] = $instance = new \stdClass($a, $b); + $b->logger = ${($_ = isset($this->services['logger']) ? $this->services['logger'] : $this->getLoggerService()) && \false ?: '_'}; + $a->subscriber = ${($_ = isset($this->services['subscriber']) ? $this->services['subscriber'] : $this->getSubscriberService()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'connection2' shared service. + * + * @return \stdClass + */ + protected function getConnection2Service() + { + $a = new \stdClass(); + $b = new \stdClass(); + $this->services['connection2'] = $instance = new \stdClass($a, $b); + $c = new \stdClass($instance); + $d = ${($_ = isset($this->services['manager2']) ? $this->services['manager2'] : $this->getManager2Service()) && \false ?: '_'}; + $c->handler2 = new \stdClass($d); + $b->logger2 = $c; + $a->subscriber2 = new \stdClass($d); + return $instance; + } + /** + * Gets the public 'foo' shared service. + * + * @return \FooCircular + */ + protected function getFooService() + { + $a = new \_PhpScoper5ea00cc67502b\BarCircular(); + $this->services['foo'] = $instance = new \_PhpScoper5ea00cc67502b\FooCircular($a); + $a->addFoobar(new \_PhpScoper5ea00cc67502b\FoobarCircular($instance)); + return $instance; + } + /** + * Gets the public 'foo2' shared service. + * + * @return \FooCircular + */ + protected function getFoo2Service() + { + $a = ${($_ = isset($this->services['bar2']) ? $this->services['bar2'] : $this->getBar2Service()) && \false ?: '_'}; + if (isset($this->services['foo2'])) { + return $this->services['foo2']; + } + return $this->services['foo2'] = new \_PhpScoper5ea00cc67502b\FooCircular($a); + } + /** + * Gets the public 'foo5' shared service. + * + * @return \stdClass + */ + protected function getFoo5Service() + { + $this->services['foo5'] = $instance = new \stdClass(); + $a = new \stdClass($instance); + $a->foo = $instance; + $instance->bar = $a; + return $instance; + } + /** + * Gets the public 'foo6' shared service. + * + * @return \stdClass + */ + protected function getFoo6Service() + { + $this->services['foo6'] = $instance = new \stdClass(); + $instance->bar6 = ${($_ = isset($this->services['bar6']) ? $this->services['bar6'] : $this->getBar6Service()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'foobar4' shared service. + * + * @return \stdClass + */ + protected function getFoobar4Service() + { + $a = new \stdClass(); + $this->services['foobar4'] = $instance = new \stdClass($a); + $a->foobar = $instance; + return $instance; + } + /** + * Gets the public 'listener3' shared service. + * + * @return \stdClass + */ + protected function getListener3Service() + { + $this->services['listener3'] = $instance = new \stdClass(); + $instance->manager = ${($_ = isset($this->services['manager3']) ? $this->services['manager3'] : $this->getManager3Service()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'listener4' shared service. + * + * @return \stdClass + */ + protected function getListener4Service() + { + $a = ${($_ = isset($this->services['manager4']) ? $this->services['manager4'] : $this->getManager4Service()) && \false ?: '_'}; + if (isset($this->services['listener4'])) { + return $this->services['listener4']; + } + return $this->services['listener4'] = new \stdClass($a); + } + /** + * Gets the public 'logger' shared service. + * + * @return \stdClass + */ + protected function getLoggerService() + { + $a = ${($_ = isset($this->services['connection']) ? $this->services['connection'] : $this->getConnectionService()) && \false ?: '_'}; + if (isset($this->services['logger'])) { + return $this->services['logger']; + } + $this->services['logger'] = $instance = new \stdClass($a); + $instance->handler = new \stdClass(${($_ = isset($this->services['manager']) ? $this->services['manager'] : $this->getManagerService()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the public 'manager' shared service. + * + * @return \stdClass + */ + protected function getManagerService() + { + $a = ${($_ = isset($this->services['connection']) ? $this->services['connection'] : $this->getConnectionService()) && \false ?: '_'}; + if (isset($this->services['manager'])) { + return $this->services['manager']; + } + return $this->services['manager'] = new \stdClass($a); + } + /** + * Gets the public 'manager2' shared service. + * + * @return \stdClass + */ + protected function getManager2Service() + { + $a = ${($_ = isset($this->services['connection2']) ? $this->services['connection2'] : $this->getConnection2Service()) && \false ?: '_'}; + if (isset($this->services['manager2'])) { + return $this->services['manager2']; + } + return $this->services['manager2'] = new \stdClass($a); + } + /** + * Gets the public 'manager3' shared service. + * + * @return \stdClass + */ + protected function getManager3Service($lazyLoad = \true) + { + $a = ${($_ = isset($this->services['listener3']) ? $this->services['listener3'] : $this->getListener3Service()) && \false ?: '_'}; + if (isset($this->services['manager3'])) { + return $this->services['manager3']; + } + $b = new \stdClass(); + $b->listener = [0 => $a]; + return $this->services['manager3'] = new \stdClass($b); + } + /** + * Gets the public 'root' shared service. + * + * @return \stdClass + */ + protected function getRootService() + { + return $this->services['root'] = new \stdClass(${($_ = isset($this->services['level2']) ? $this->services['level2'] : $this->getLevel2Service()) && \false ?: '_'}, ${($_ = isset($this->services['multiuse1']) ? $this->services['multiuse1'] : ($this->services['multiuse1'] = new \stdClass())) && \false ?: '_'}); + } + /** + * Gets the public 'subscriber' shared service. + * + * @return \stdClass + */ + protected function getSubscriberService() + { + $a = ${($_ = isset($this->services['manager']) ? $this->services['manager'] : $this->getManagerService()) && \false ?: '_'}; + if (isset($this->services['subscriber'])) { + return $this->services['subscriber']; + } + return $this->services['subscriber'] = new \stdClass($a); + } + /** + * Gets the private 'bar6' shared service. + * + * @return \stdClass + */ + protected function getBar6Service() + { + $a = ${($_ = isset($this->services['foo6']) ? $this->services['foo6'] : $this->getFoo6Service()) && \false ?: '_'}; + if (isset($this->services['bar6'])) { + return $this->services['bar6']; + } + return $this->services['bar6'] = new \stdClass($a); + } + /** + * Gets the private 'level2' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls + */ + protected function getLevel2Service() + { + $this->services['level2'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls(); + $instance->call(${($_ = isset($this->services['level3']) ? $this->services['level3'] : $this->getLevel3Service()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the private 'level3' shared service. + * + * @return \stdClass + */ + protected function getLevel3Service() + { + return $this->services['level3'] = new \stdClass(${($_ = isset($this->services['level4']) ? $this->services['level4'] : $this->getLevel4Service()) && \false ?: '_'}); + } + /** + * Gets the private 'level4' shared service. + * + * @return \stdClass + */ + protected function getLevel4Service() + { + return $this->services['level4'] = new \stdClass(${($_ = isset($this->services['multiuse1']) ? $this->services['multiuse1'] : ($this->services['multiuse1'] = new \stdClass())) && \false ?: '_'}, ${($_ = isset($this->services['level5']) ? $this->services['level5'] : $this->getLevel5Service()) && \false ?: '_'}); + } + /** + * Gets the private 'level5' shared service. + * + * @return \stdClass + */ + protected function getLevel5Service() + { + $a = ${($_ = isset($this->services['level6']) ? $this->services['level6'] : $this->getLevel6Service()) && \false ?: '_'}; + if (isset($this->services['level5'])) { + return $this->services['level5']; + } + return $this->services['level5'] = new \stdClass($a); + } + /** + * Gets the private 'level6' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls + */ + protected function getLevel6Service() + { + $this->services['level6'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls(); + $instance->call(${($_ = isset($this->services['level5']) ? $this->services['level5'] : $this->getLevel5Service()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the private 'manager4' shared service. + * + * @return \stdClass + */ + protected function getManager4Service($lazyLoad = \true) + { + $a = new \stdClass(); + $this->services['manager4'] = $instance = new \stdClass($a); + $a->listener = [0 => ${($_ = isset($this->services['listener4']) ? $this->services['listener4'] : $this->getListener4Service()) && \false ?: '_'}]; + return $instance; + } + /** + * Gets the private 'multiuse1' shared service. + * + * @return \stdClass + */ + protected function getMultiuse1Service() + { + return $this->services['multiuse1'] = new \stdClass(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Almost_Circular_Private', 'Symfony_DI_PhpDumper_Test_Almost_Circular_Private', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_almost_circular_public.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_almost_circular_public.php index 2b6867779..2f00793d7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_almost_circular_public.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_almost_circular_public.php @@ -1,473 +1,473 @@ -services = []; - $this->methodMap = ['bar' => 'getBarService', 'bar3' => 'getBar3Service', 'bar5' => 'getBar5Service', 'bar6' => 'getBar6Service', 'baz6' => 'getBaz6Service', 'connection' => 'getConnectionService', 'connection2' => 'getConnection2Service', 'connection3' => 'getConnection3Service', 'connection4' => 'getConnection4Service', 'dispatcher' => 'getDispatcherService', 'dispatcher2' => 'getDispatcher2Service', 'foo' => 'getFooService', 'foo2' => 'getFoo2Service', 'foo4' => 'getFoo4Service', 'foo5' => 'getFoo5Service', 'foo6' => 'getFoo6Service', 'foobar' => 'getFoobarService', 'foobar2' => 'getFoobar2Service', 'foobar3' => 'getFoobar3Service', 'foobar4' => 'getFoobar4Service', 'level2' => 'getLevel2Service', 'level3' => 'getLevel3Service', 'level4' => 'getLevel4Service', 'level5' => 'getLevel5Service', 'level6' => 'getLevel6Service', 'listener3' => 'getListener3Service', 'listener4' => 'getListener4Service', 'logger' => 'getLoggerService', 'manager' => 'getManagerService', 'manager2' => 'getManager2Service', 'manager3' => 'getManager3Service', 'manager4' => 'getManager4Service', 'multiuse1' => 'getMultiuse1Service', 'root' => 'getRootService', 'subscriber' => 'getSubscriberService']; - $this->privates = ['bar6' => \true, 'level2' => \true, 'level3' => \true, 'level4' => \true, 'level5' => \true, 'level6' => \true, 'manager4' => \true, 'multiuse1' => \true]; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'bar2' => \true, 'bar6' => \true, 'config' => \true, 'config2' => \true, 'level2' => \true, 'level3' => \true, 'level4' => \true, 'level5' => \true, 'level6' => \true, 'logger2' => \true, 'manager4' => \true, 'multiuse1' => \true, 'subscriber2' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar' shared service. - * - * @return \BarCircular - */ - protected function getBarService() - { - $this->services['bar'] = $instance = new \_PhpScoper5ea00cc67502b\BarCircular(); - $instance->addFoobar(${($_ = isset($this->services['foobar']) ? $this->services['foobar'] : $this->getFoobarService()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the public 'bar3' shared service. - * - * @return \BarCircular - */ - protected function getBar3Service() - { - $this->services['bar3'] = $instance = new \_PhpScoper5ea00cc67502b\BarCircular(); - $a = ${($_ = isset($this->services['foobar3']) ? $this->services['foobar3'] : ($this->services['foobar3'] = new \_PhpScoper5ea00cc67502b\FoobarCircular())) && \false ?: '_'}; - $instance->addFoobar($a, $a); - return $instance; - } - /** - * Gets the public 'bar5' shared service. - * - * @return \stdClass - */ - protected function getBar5Service() - { - $a = ${($_ = isset($this->services['foo5']) ? $this->services['foo5'] : $this->getFoo5Service()) && \false ?: '_'}; - if (isset($this->services['bar5'])) { - return $this->services['bar5']; - } - $this->services['bar5'] = $instance = new \stdClass($a); - $instance->foo = $a; - return $instance; - } - /** - * Gets the public 'baz6' shared service. - * - * @return \stdClass - */ - protected function getBaz6Service() - { - $this->services['baz6'] = $instance = new \stdClass(); - $instance->bar6 = ${($_ = isset($this->services['bar6']) ? $this->services['bar6'] : $this->getBar6Service()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'connection' shared service. - * - * @return \stdClass - */ - protected function getConnectionService() - { - $a = ${($_ = isset($this->services['dispatcher']) ? $this->services['dispatcher'] : $this->getDispatcherService()) && \false ?: '_'}; - if (isset($this->services['connection'])) { - return $this->services['connection']; - } - $b = new \stdClass(); - $this->services['connection'] = $instance = new \stdClass($a, $b); - $b->logger = ${($_ = isset($this->services['logger']) ? $this->services['logger'] : $this->getLoggerService()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'connection2' shared service. - * - * @return \stdClass - */ - protected function getConnection2Service() - { - $a = ${($_ = isset($this->services['dispatcher2']) ? $this->services['dispatcher2'] : $this->getDispatcher2Service()) && \false ?: '_'}; - if (isset($this->services['connection2'])) { - return $this->services['connection2']; - } - $b = new \stdClass(); - $this->services['connection2'] = $instance = new \stdClass($a, $b); - $c = new \stdClass($instance); - $c->handler2 = new \stdClass(${($_ = isset($this->services['manager2']) ? $this->services['manager2'] : $this->getManager2Service()) && \false ?: '_'}); - $b->logger2 = $c; - return $instance; - } - /** - * Gets the public 'connection3' shared service. - * - * @return \stdClass - */ - protected function getConnection3Service() - { - $this->services['connection3'] = $instance = new \stdClass(); - $instance->listener = [0 => ${($_ = isset($this->services['listener3']) ? $this->services['listener3'] : $this->getListener3Service()) && \false ?: '_'}]; - return $instance; - } - /** - * Gets the public 'connection4' shared service. - * - * @return \stdClass - */ - protected function getConnection4Service() - { - $this->services['connection4'] = $instance = new \stdClass(); - $instance->listener = [0 => ${($_ = isset($this->services['listener4']) ? $this->services['listener4'] : $this->getListener4Service()) && \false ?: '_'}]; - return $instance; - } - /** - * Gets the public 'dispatcher' shared service. - * - * @return \stdClass - */ - protected function getDispatcherService($lazyLoad = \true) - { - $this->services['dispatcher'] = $instance = new \stdClass(); - $instance->subscriber = ${($_ = isset($this->services['subscriber']) ? $this->services['subscriber'] : $this->getSubscriberService()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'dispatcher2' shared service. - * - * @return \stdClass - */ - protected function getDispatcher2Service($lazyLoad = \true) - { - $this->services['dispatcher2'] = $instance = new \stdClass(); - $instance->subscriber2 = new \stdClass(${($_ = isset($this->services['manager2']) ? $this->services['manager2'] : $this->getManager2Service()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the public 'foo' shared service. - * - * @return \FooCircular - */ - protected function getFooService() - { - $a = ${($_ = isset($this->services['bar']) ? $this->services['bar'] : $this->getBarService()) && \false ?: '_'}; - if (isset($this->services['foo'])) { - return $this->services['foo']; - } - return $this->services['foo'] = new \_PhpScoper5ea00cc67502b\FooCircular($a); - } - /** - * Gets the public 'foo2' shared service. - * - * @return \FooCircular - */ - protected function getFoo2Service() - { - $a = new \_PhpScoper5ea00cc67502b\BarCircular(); - $this->services['foo2'] = $instance = new \_PhpScoper5ea00cc67502b\FooCircular($a); - $a->addFoobar(${($_ = isset($this->services['foobar2']) ? $this->services['foobar2'] : $this->getFoobar2Service()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the public 'foo4' service. - * - * @return \stdClass - */ - protected function getFoo4Service() - { - $instance = new \stdClass(); - $instance->foobar = ${($_ = isset($this->services['foobar4']) ? $this->services['foobar4'] : $this->getFoobar4Service()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'foo5' shared service. - * - * @return \stdClass - */ - protected function getFoo5Service() - { - $this->services['foo5'] = $instance = new \stdClass(); - $instance->bar = ${($_ = isset($this->services['bar5']) ? $this->services['bar5'] : $this->getBar5Service()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'foo6' shared service. - * - * @return \stdClass - */ - protected function getFoo6Service() - { - $this->services['foo6'] = $instance = new \stdClass(); - $instance->bar6 = ${($_ = isset($this->services['bar6']) ? $this->services['bar6'] : $this->getBar6Service()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'foobar' shared service. - * - * @return \FoobarCircular - */ - protected function getFoobarService() - { - $a = ${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}; - if (isset($this->services['foobar'])) { - return $this->services['foobar']; - } - return $this->services['foobar'] = new \_PhpScoper5ea00cc67502b\FoobarCircular($a); - } - /** - * Gets the public 'foobar2' shared service. - * - * @return \FoobarCircular - */ - protected function getFoobar2Service() - { - $a = ${($_ = isset($this->services['foo2']) ? $this->services['foo2'] : $this->getFoo2Service()) && \false ?: '_'}; - if (isset($this->services['foobar2'])) { - return $this->services['foobar2']; - } - return $this->services['foobar2'] = new \_PhpScoper5ea00cc67502b\FoobarCircular($a); - } - /** - * Gets the public 'foobar3' shared service. - * - * @return \FoobarCircular - */ - protected function getFoobar3Service() - { - return $this->services['foobar3'] = new \_PhpScoper5ea00cc67502b\FoobarCircular(); - } - /** - * Gets the public 'foobar4' shared service. - * - * @return \stdClass - */ - protected function getFoobar4Service() - { - $a = new \stdClass(); - $this->services['foobar4'] = $instance = new \stdClass($a); - $a->foobar = $instance; - return $instance; - } - /** - * Gets the public 'listener3' shared service. - * - * @return \stdClass - */ - protected function getListener3Service() - { - $this->services['listener3'] = $instance = new \stdClass(); - $instance->manager = ${($_ = isset($this->services['manager3']) ? $this->services['manager3'] : $this->getManager3Service()) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'listener4' shared service. - * - * @return \stdClass - */ - protected function getListener4Service() - { - $a = ${($_ = isset($this->services['manager4']) ? $this->services['manager4'] : $this->getManager4Service()) && \false ?: '_'}; - if (isset($this->services['listener4'])) { - return $this->services['listener4']; - } - return $this->services['listener4'] = new \stdClass($a); - } - /** - * Gets the public 'logger' shared service. - * - * @return \stdClass - */ - protected function getLoggerService() - { - $a = ${($_ = isset($this->services['connection']) ? $this->services['connection'] : $this->getConnectionService()) && \false ?: '_'}; - if (isset($this->services['logger'])) { - return $this->services['logger']; - } - $this->services['logger'] = $instance = new \stdClass($a); - $instance->handler = new \stdClass(${($_ = isset($this->services['manager']) ? $this->services['manager'] : $this->getManagerService()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the public 'manager' shared service. - * - * @return \stdClass - */ - protected function getManagerService() - { - $a = ${($_ = isset($this->services['connection']) ? $this->services['connection'] : $this->getConnectionService()) && \false ?: '_'}; - if (isset($this->services['manager'])) { - return $this->services['manager']; - } - return $this->services['manager'] = new \stdClass($a); - } - /** - * Gets the public 'manager2' shared service. - * - * @return \stdClass - */ - protected function getManager2Service() - { - $a = ${($_ = isset($this->services['connection2']) ? $this->services['connection2'] : $this->getConnection2Service()) && \false ?: '_'}; - if (isset($this->services['manager2'])) { - return $this->services['manager2']; - } - return $this->services['manager2'] = new \stdClass($a); - } - /** - * Gets the public 'manager3' shared service. - * - * @return \stdClass - */ - protected function getManager3Service($lazyLoad = \true) - { - $a = ${($_ = isset($this->services['connection3']) ? $this->services['connection3'] : $this->getConnection3Service()) && \false ?: '_'}; - if (isset($this->services['manager3'])) { - return $this->services['manager3']; - } - return $this->services['manager3'] = new \stdClass($a); - } - /** - * Gets the public 'root' shared service. - * - * @return \stdClass - */ - protected function getRootService() - { - return $this->services['root'] = new \stdClass(${($_ = isset($this->services['level2']) ? $this->services['level2'] : $this->getLevel2Service()) && \false ?: '_'}, ${($_ = isset($this->services['multiuse1']) ? $this->services['multiuse1'] : ($this->services['multiuse1'] = new \stdClass())) && \false ?: '_'}); - } - /** - * Gets the public 'subscriber' shared service. - * - * @return \stdClass - */ - protected function getSubscriberService() - { - $a = ${($_ = isset($this->services['manager']) ? $this->services['manager'] : $this->getManagerService()) && \false ?: '_'}; - if (isset($this->services['subscriber'])) { - return $this->services['subscriber']; - } - return $this->services['subscriber'] = new \stdClass($a); - } - /** - * Gets the private 'bar6' shared service. - * - * @return \stdClass - */ - protected function getBar6Service() - { - $a = ${($_ = isset($this->services['foo6']) ? $this->services['foo6'] : $this->getFoo6Service()) && \false ?: '_'}; - if (isset($this->services['bar6'])) { - return $this->services['bar6']; - } - return $this->services['bar6'] = new \stdClass($a); - } - /** - * Gets the private 'level2' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls - */ - protected function getLevel2Service() - { - $this->services['level2'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls(); - $instance->call(${($_ = isset($this->services['level3']) ? $this->services['level3'] : $this->getLevel3Service()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the private 'level3' shared service. - * - * @return \stdClass - */ - protected function getLevel3Service() - { - return $this->services['level3'] = new \stdClass(${($_ = isset($this->services['level4']) ? $this->services['level4'] : $this->getLevel4Service()) && \false ?: '_'}); - } - /** - * Gets the private 'level4' shared service. - * - * @return \stdClass - */ - protected function getLevel4Service() - { - return $this->services['level4'] = new \stdClass(${($_ = isset($this->services['multiuse1']) ? $this->services['multiuse1'] : ($this->services['multiuse1'] = new \stdClass())) && \false ?: '_'}, ${($_ = isset($this->services['level5']) ? $this->services['level5'] : $this->getLevel5Service()) && \false ?: '_'}); - } - /** - * Gets the private 'level5' shared service. - * - * @return \stdClass - */ - protected function getLevel5Service() - { - $a = ${($_ = isset($this->services['level6']) ? $this->services['level6'] : $this->getLevel6Service()) && \false ?: '_'}; - if (isset($this->services['level5'])) { - return $this->services['level5']; - } - return $this->services['level5'] = new \stdClass($a); - } - /** - * Gets the private 'level6' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls - */ - protected function getLevel6Service() - { - $this->services['level6'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls(); - $instance->call(${($_ = isset($this->services['level5']) ? $this->services['level5'] : $this->getLevel5Service()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the private 'manager4' shared service. - * - * @return \stdClass - */ - protected function getManager4Service($lazyLoad = \true) - { - $a = ${($_ = isset($this->services['connection4']) ? $this->services['connection4'] : $this->getConnection4Service()) && \false ?: '_'}; - if (isset($this->services['manager4'])) { - return $this->services['manager4']; - } - return $this->services['manager4'] = new \stdClass($a); - } - /** - * Gets the private 'multiuse1' shared service. - * - * @return \stdClass - */ - protected function getMultiuse1Service() - { - return $this->services['multiuse1'] = new \stdClass(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Almost_Circular_Public', 'Symfony_DI_PhpDumper_Test_Almost_Circular_Public', \false); +services = []; + $this->methodMap = ['bar' => 'getBarService', 'bar3' => 'getBar3Service', 'bar5' => 'getBar5Service', 'bar6' => 'getBar6Service', 'baz6' => 'getBaz6Service', 'connection' => 'getConnectionService', 'connection2' => 'getConnection2Service', 'connection3' => 'getConnection3Service', 'connection4' => 'getConnection4Service', 'dispatcher' => 'getDispatcherService', 'dispatcher2' => 'getDispatcher2Service', 'foo' => 'getFooService', 'foo2' => 'getFoo2Service', 'foo4' => 'getFoo4Service', 'foo5' => 'getFoo5Service', 'foo6' => 'getFoo6Service', 'foobar' => 'getFoobarService', 'foobar2' => 'getFoobar2Service', 'foobar3' => 'getFoobar3Service', 'foobar4' => 'getFoobar4Service', 'level2' => 'getLevel2Service', 'level3' => 'getLevel3Service', 'level4' => 'getLevel4Service', 'level5' => 'getLevel5Service', 'level6' => 'getLevel6Service', 'listener3' => 'getListener3Service', 'listener4' => 'getListener4Service', 'logger' => 'getLoggerService', 'manager' => 'getManagerService', 'manager2' => 'getManager2Service', 'manager3' => 'getManager3Service', 'manager4' => 'getManager4Service', 'multiuse1' => 'getMultiuse1Service', 'root' => 'getRootService', 'subscriber' => 'getSubscriberService']; + $this->privates = ['bar6' => \true, 'level2' => \true, 'level3' => \true, 'level4' => \true, 'level5' => \true, 'level6' => \true, 'manager4' => \true, 'multiuse1' => \true]; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'bar2' => \true, 'bar6' => \true, 'config' => \true, 'config2' => \true, 'level2' => \true, 'level3' => \true, 'level4' => \true, 'level5' => \true, 'level6' => \true, 'logger2' => \true, 'manager4' => \true, 'multiuse1' => \true, 'subscriber2' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar' shared service. + * + * @return \BarCircular + */ + protected function getBarService() + { + $this->services['bar'] = $instance = new \_PhpScoper5ea00cc67502b\BarCircular(); + $instance->addFoobar(${($_ = isset($this->services['foobar']) ? $this->services['foobar'] : $this->getFoobarService()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the public 'bar3' shared service. + * + * @return \BarCircular + */ + protected function getBar3Service() + { + $this->services['bar3'] = $instance = new \_PhpScoper5ea00cc67502b\BarCircular(); + $a = ${($_ = isset($this->services['foobar3']) ? $this->services['foobar3'] : ($this->services['foobar3'] = new \_PhpScoper5ea00cc67502b\FoobarCircular())) && \false ?: '_'}; + $instance->addFoobar($a, $a); + return $instance; + } + /** + * Gets the public 'bar5' shared service. + * + * @return \stdClass + */ + protected function getBar5Service() + { + $a = ${($_ = isset($this->services['foo5']) ? $this->services['foo5'] : $this->getFoo5Service()) && \false ?: '_'}; + if (isset($this->services['bar5'])) { + return $this->services['bar5']; + } + $this->services['bar5'] = $instance = new \stdClass($a); + $instance->foo = $a; + return $instance; + } + /** + * Gets the public 'baz6' shared service. + * + * @return \stdClass + */ + protected function getBaz6Service() + { + $this->services['baz6'] = $instance = new \stdClass(); + $instance->bar6 = ${($_ = isset($this->services['bar6']) ? $this->services['bar6'] : $this->getBar6Service()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'connection' shared service. + * + * @return \stdClass + */ + protected function getConnectionService() + { + $a = ${($_ = isset($this->services['dispatcher']) ? $this->services['dispatcher'] : $this->getDispatcherService()) && \false ?: '_'}; + if (isset($this->services['connection'])) { + return $this->services['connection']; + } + $b = new \stdClass(); + $this->services['connection'] = $instance = new \stdClass($a, $b); + $b->logger = ${($_ = isset($this->services['logger']) ? $this->services['logger'] : $this->getLoggerService()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'connection2' shared service. + * + * @return \stdClass + */ + protected function getConnection2Service() + { + $a = ${($_ = isset($this->services['dispatcher2']) ? $this->services['dispatcher2'] : $this->getDispatcher2Service()) && \false ?: '_'}; + if (isset($this->services['connection2'])) { + return $this->services['connection2']; + } + $b = new \stdClass(); + $this->services['connection2'] = $instance = new \stdClass($a, $b); + $c = new \stdClass($instance); + $c->handler2 = new \stdClass(${($_ = isset($this->services['manager2']) ? $this->services['manager2'] : $this->getManager2Service()) && \false ?: '_'}); + $b->logger2 = $c; + return $instance; + } + /** + * Gets the public 'connection3' shared service. + * + * @return \stdClass + */ + protected function getConnection3Service() + { + $this->services['connection3'] = $instance = new \stdClass(); + $instance->listener = [0 => ${($_ = isset($this->services['listener3']) ? $this->services['listener3'] : $this->getListener3Service()) && \false ?: '_'}]; + return $instance; + } + /** + * Gets the public 'connection4' shared service. + * + * @return \stdClass + */ + protected function getConnection4Service() + { + $this->services['connection4'] = $instance = new \stdClass(); + $instance->listener = [0 => ${($_ = isset($this->services['listener4']) ? $this->services['listener4'] : $this->getListener4Service()) && \false ?: '_'}]; + return $instance; + } + /** + * Gets the public 'dispatcher' shared service. + * + * @return \stdClass + */ + protected function getDispatcherService($lazyLoad = \true) + { + $this->services['dispatcher'] = $instance = new \stdClass(); + $instance->subscriber = ${($_ = isset($this->services['subscriber']) ? $this->services['subscriber'] : $this->getSubscriberService()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'dispatcher2' shared service. + * + * @return \stdClass + */ + protected function getDispatcher2Service($lazyLoad = \true) + { + $this->services['dispatcher2'] = $instance = new \stdClass(); + $instance->subscriber2 = new \stdClass(${($_ = isset($this->services['manager2']) ? $this->services['manager2'] : $this->getManager2Service()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the public 'foo' shared service. + * + * @return \FooCircular + */ + protected function getFooService() + { + $a = ${($_ = isset($this->services['bar']) ? $this->services['bar'] : $this->getBarService()) && \false ?: '_'}; + if (isset($this->services['foo'])) { + return $this->services['foo']; + } + return $this->services['foo'] = new \_PhpScoper5ea00cc67502b\FooCircular($a); + } + /** + * Gets the public 'foo2' shared service. + * + * @return \FooCircular + */ + protected function getFoo2Service() + { + $a = new \_PhpScoper5ea00cc67502b\BarCircular(); + $this->services['foo2'] = $instance = new \_PhpScoper5ea00cc67502b\FooCircular($a); + $a->addFoobar(${($_ = isset($this->services['foobar2']) ? $this->services['foobar2'] : $this->getFoobar2Service()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the public 'foo4' service. + * + * @return \stdClass + */ + protected function getFoo4Service() + { + $instance = new \stdClass(); + $instance->foobar = ${($_ = isset($this->services['foobar4']) ? $this->services['foobar4'] : $this->getFoobar4Service()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'foo5' shared service. + * + * @return \stdClass + */ + protected function getFoo5Service() + { + $this->services['foo5'] = $instance = new \stdClass(); + $instance->bar = ${($_ = isset($this->services['bar5']) ? $this->services['bar5'] : $this->getBar5Service()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'foo6' shared service. + * + * @return \stdClass + */ + protected function getFoo6Service() + { + $this->services['foo6'] = $instance = new \stdClass(); + $instance->bar6 = ${($_ = isset($this->services['bar6']) ? $this->services['bar6'] : $this->getBar6Service()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'foobar' shared service. + * + * @return \FoobarCircular + */ + protected function getFoobarService() + { + $a = ${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}; + if (isset($this->services['foobar'])) { + return $this->services['foobar']; + } + return $this->services['foobar'] = new \_PhpScoper5ea00cc67502b\FoobarCircular($a); + } + /** + * Gets the public 'foobar2' shared service. + * + * @return \FoobarCircular + */ + protected function getFoobar2Service() + { + $a = ${($_ = isset($this->services['foo2']) ? $this->services['foo2'] : $this->getFoo2Service()) && \false ?: '_'}; + if (isset($this->services['foobar2'])) { + return $this->services['foobar2']; + } + return $this->services['foobar2'] = new \_PhpScoper5ea00cc67502b\FoobarCircular($a); + } + /** + * Gets the public 'foobar3' shared service. + * + * @return \FoobarCircular + */ + protected function getFoobar3Service() + { + return $this->services['foobar3'] = new \_PhpScoper5ea00cc67502b\FoobarCircular(); + } + /** + * Gets the public 'foobar4' shared service. + * + * @return \stdClass + */ + protected function getFoobar4Service() + { + $a = new \stdClass(); + $this->services['foobar4'] = $instance = new \stdClass($a); + $a->foobar = $instance; + return $instance; + } + /** + * Gets the public 'listener3' shared service. + * + * @return \stdClass + */ + protected function getListener3Service() + { + $this->services['listener3'] = $instance = new \stdClass(); + $instance->manager = ${($_ = isset($this->services['manager3']) ? $this->services['manager3'] : $this->getManager3Service()) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'listener4' shared service. + * + * @return \stdClass + */ + protected function getListener4Service() + { + $a = ${($_ = isset($this->services['manager4']) ? $this->services['manager4'] : $this->getManager4Service()) && \false ?: '_'}; + if (isset($this->services['listener4'])) { + return $this->services['listener4']; + } + return $this->services['listener4'] = new \stdClass($a); + } + /** + * Gets the public 'logger' shared service. + * + * @return \stdClass + */ + protected function getLoggerService() + { + $a = ${($_ = isset($this->services['connection']) ? $this->services['connection'] : $this->getConnectionService()) && \false ?: '_'}; + if (isset($this->services['logger'])) { + return $this->services['logger']; + } + $this->services['logger'] = $instance = new \stdClass($a); + $instance->handler = new \stdClass(${($_ = isset($this->services['manager']) ? $this->services['manager'] : $this->getManagerService()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the public 'manager' shared service. + * + * @return \stdClass + */ + protected function getManagerService() + { + $a = ${($_ = isset($this->services['connection']) ? $this->services['connection'] : $this->getConnectionService()) && \false ?: '_'}; + if (isset($this->services['manager'])) { + return $this->services['manager']; + } + return $this->services['manager'] = new \stdClass($a); + } + /** + * Gets the public 'manager2' shared service. + * + * @return \stdClass + */ + protected function getManager2Service() + { + $a = ${($_ = isset($this->services['connection2']) ? $this->services['connection2'] : $this->getConnection2Service()) && \false ?: '_'}; + if (isset($this->services['manager2'])) { + return $this->services['manager2']; + } + return $this->services['manager2'] = new \stdClass($a); + } + /** + * Gets the public 'manager3' shared service. + * + * @return \stdClass + */ + protected function getManager3Service($lazyLoad = \true) + { + $a = ${($_ = isset($this->services['connection3']) ? $this->services['connection3'] : $this->getConnection3Service()) && \false ?: '_'}; + if (isset($this->services['manager3'])) { + return $this->services['manager3']; + } + return $this->services['manager3'] = new \stdClass($a); + } + /** + * Gets the public 'root' shared service. + * + * @return \stdClass + */ + protected function getRootService() + { + return $this->services['root'] = new \stdClass(${($_ = isset($this->services['level2']) ? $this->services['level2'] : $this->getLevel2Service()) && \false ?: '_'}, ${($_ = isset($this->services['multiuse1']) ? $this->services['multiuse1'] : ($this->services['multiuse1'] = new \stdClass())) && \false ?: '_'}); + } + /** + * Gets the public 'subscriber' shared service. + * + * @return \stdClass + */ + protected function getSubscriberService() + { + $a = ${($_ = isset($this->services['manager']) ? $this->services['manager'] : $this->getManagerService()) && \false ?: '_'}; + if (isset($this->services['subscriber'])) { + return $this->services['subscriber']; + } + return $this->services['subscriber'] = new \stdClass($a); + } + /** + * Gets the private 'bar6' shared service. + * + * @return \stdClass + */ + protected function getBar6Service() + { + $a = ${($_ = isset($this->services['foo6']) ? $this->services['foo6'] : $this->getFoo6Service()) && \false ?: '_'}; + if (isset($this->services['bar6'])) { + return $this->services['bar6']; + } + return $this->services['bar6'] = new \stdClass($a); + } + /** + * Gets the private 'level2' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls + */ + protected function getLevel2Service() + { + $this->services['level2'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls(); + $instance->call(${($_ = isset($this->services['level3']) ? $this->services['level3'] : $this->getLevel3Service()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the private 'level3' shared service. + * + * @return \stdClass + */ + protected function getLevel3Service() + { + return $this->services['level3'] = new \stdClass(${($_ = isset($this->services['level4']) ? $this->services['level4'] : $this->getLevel4Service()) && \false ?: '_'}); + } + /** + * Gets the private 'level4' shared service. + * + * @return \stdClass + */ + protected function getLevel4Service() + { + return $this->services['level4'] = new \stdClass(${($_ = isset($this->services['multiuse1']) ? $this->services['multiuse1'] : ($this->services['multiuse1'] = new \stdClass())) && \false ?: '_'}, ${($_ = isset($this->services['level5']) ? $this->services['level5'] : $this->getLevel5Service()) && \false ?: '_'}); + } + /** + * Gets the private 'level5' shared service. + * + * @return \stdClass + */ + protected function getLevel5Service() + { + $a = ${($_ = isset($this->services['level6']) ? $this->services['level6'] : $this->getLevel6Service()) && \false ?: '_'}; + if (isset($this->services['level5'])) { + return $this->services['level5']; + } + return $this->services['level5'] = new \stdClass($a); + } + /** + * Gets the private 'level6' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls + */ + protected function getLevel6Service() + { + $this->services['level6'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\FooForCircularWithAddCalls(); + $instance->call(${($_ = isset($this->services['level5']) ? $this->services['level5'] : $this->getLevel5Service()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the private 'manager4' shared service. + * + * @return \stdClass + */ + protected function getManager4Service($lazyLoad = \true) + { + $a = ${($_ = isset($this->services['connection4']) ? $this->services['connection4'] : $this->getConnection4Service()) && \false ?: '_'}; + if (isset($this->services['manager4'])) { + return $this->services['manager4']; + } + return $this->services['manager4'] = new \stdClass($a); + } + /** + * Gets the private 'multiuse1' shared service. + * + * @return \stdClass + */ + protected function getMultiuse1Service() + { + return $this->services['multiuse1'] = new \stdClass(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Almost_Circular_Public', 'Symfony_DI_PhpDumper_Test_Almost_Circular_Public', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_array_params.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_array_params.php index dec8f6c42..eb69062cc 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_array_params.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_array_params.php @@ -1,148 +1,148 @@ -targetDirs[$i] = $dir = \dirname($dir); - } - $this->parameters = $this->getDefaultParameters(); - $this->services = []; - $this->methodMap = ['bar' => 'getBarService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar' shared service. - * - * @return \BarClass - */ - protected function getBarService() - { - $this->services['bar'] = $instance = new \_PhpScoper5ea00cc67502b\BarClass(); - $instance->setBaz($this->parameters['array_1'], $this->getParameter('array_2'), '%array_1%', $this->parameters['array_1']); - return $instance; - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = ['array_2' => \false]; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - switch ($name) { - case 'array_2': - $value = [0 => $this->targetDirs[2] . '/Dumper']; - break; - default: - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - $this->loadedDynamicParameters[$name] = \true; - return $this->dynamicParameters[$name] = $value; - } - private $normalizedParameterNames = []; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['array_1' => [0 => 123]]; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +targetDirs[$i] = $dir = \dirname($dir); + } + $this->parameters = $this->getDefaultParameters(); + $this->services = []; + $this->methodMap = ['bar' => 'getBarService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar' shared service. + * + * @return \BarClass + */ + protected function getBarService() + { + $this->services['bar'] = $instance = new \_PhpScoper5ea00cc67502b\BarClass(); + $instance->setBaz($this->parameters['array_1'], $this->getParameter('array_2'), '%array_1%', $this->parameters['array_1']); + return $instance; + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = ['array_2' => \false]; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + switch ($name) { + case 'array_2': + $value = [0 => $this->targetDirs[2] . '/Dumper']; + break; + default: + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + $this->loadedDynamicParameters[$name] = \true; + return $this->dynamicParameters[$name] = $value; + } + private $normalizedParameterNames = []; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['array_1' => [0 => 123]]; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_base64_env.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_base64_env.php index 3b4e7540d..e799e88e7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_base64_env.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_base64_env.php @@ -1,132 +1,132 @@ -parameters = $this->getDefaultParameters(); - $this->services = []; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = ['hello' => \false]; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - switch ($name) { - case 'hello': - $value = $this->getEnv('base64:foo'); - break; - default: - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - $this->loadedDynamicParameters[$name] = \true; - return $this->dynamicParameters[$name] = $value; - } - private $normalizedParameterNames = []; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['env(foo)' => 'd29ybGQ=']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Base64Parameters', 'Symfony_DI_PhpDumper_Test_Base64Parameters', \false); +parameters = $this->getDefaultParameters(); + $this->services = []; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = ['hello' => \false]; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + switch ($name) { + case 'hello': + $value = $this->getEnv('base64:foo'); + break; + default: + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + $this->loadedDynamicParameters[$name] = \true; + return $this->dynamicParameters[$name] = $value; + } + private $normalizedParameterNames = []; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['env(foo)' => 'd29ybGQ=']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Base64Parameters', 'Symfony_DI_PhpDumper_Test_Base64Parameters', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_dedup_lazy_proxy.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_dedup_lazy_proxy.php index e8e2dbfa5..7ccbdd1f5 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_dedup_lazy_proxy.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_dedup_lazy_proxy.php @@ -1,77 +1,77 @@ -services = []; - $this->methodMap = ['bar' => 'getBarService', 'foo' => 'getFooService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - protected function createProxy($class, \Closure $factory) - { - return $factory(); - } - /** - * Gets the public 'bar' shared service. - * - * @return \stdClass - */ - protected function getBarService($lazyLoad = \true) - { - // lazy factory for stdClass - return new \stdClass(); - } - /** - * Gets the public 'foo' shared service. - * - * @return \stdClass - */ - protected function getFooService($lazyLoad = \true) - { - // lazy factory for stdClass - return new \stdClass(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); -// proxy code for stdClass +services = []; + $this->methodMap = ['bar' => 'getBarService', 'foo' => 'getFooService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + protected function createProxy($class, \Closure $factory) + { + return $factory(); + } + /** + * Gets the public 'bar' shared service. + * + * @return \stdClass + */ + protected function getBarService($lazyLoad = \true) + { + // lazy factory for stdClass + return new \stdClass(); + } + /** + * Gets the public 'foo' shared service. + * + * @return \stdClass + */ + protected function getFooService($lazyLoad = \true) + { + // lazy factory for stdClass + return new \stdClass(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +// proxy code for stdClass diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_deep_graph.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_deep_graph.php index cb0ab3e56..1370256d9 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_deep_graph.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_deep_graph.php @@ -1,80 +1,80 @@ -services = []; - $this->methodMap = ['bar' => 'getBarService', 'foo' => 'getFooService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar' shared service. - * - * @return \stdClass - */ - protected function getBarService() - { - $this->services['bar'] = $instance = new \stdClass(); - $instance->p5 = new \stdClass(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}); - return $instance; - } - /** - * Gets the public 'foo' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Dumper\FooForDeepGraph - */ - protected function getFooService() - { - $a = ${($_ = isset($this->services['bar']) ? $this->services['bar'] : $this->getBarService()) && \false ?: '_'}; - if (isset($this->services['foo'])) { - return $this->services['foo']; - } - $b = new \stdClass(); - $c = new \stdClass(); - $c->p3 = new \stdClass(); - $b->p2 = $c; - return $this->services['foo'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\FooForDeepGraph($a, $b); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Deep_Graph', 'Symfony_DI_PhpDumper_Test_Deep_Graph', \false); +services = []; + $this->methodMap = ['bar' => 'getBarService', 'foo' => 'getFooService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar' shared service. + * + * @return \stdClass + */ + protected function getBarService() + { + $this->services['bar'] = $instance = new \stdClass(); + $instance->p5 = new \stdClass(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}); + return $instance; + } + /** + * Gets the public 'foo' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Dumper\FooForDeepGraph + */ + protected function getFooService() + { + $a = ${($_ = isset($this->services['bar']) ? $this->services['bar'] : $this->getBarService()) && \false ?: '_'}; + if (isset($this->services['foo'])) { + return $this->services['foo']; + } + $b = new \stdClass(); + $c = new \stdClass(); + $c->p3 = new \stdClass(); + $b->p2 = $c; + return $this->services['foo'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\FooForDeepGraph($a, $b); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Deep_Graph', 'Symfony_DI_PhpDumper_Test_Deep_Graph', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_env_in_id.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_env_in_id.php index 2d213ba24..cc34b744d 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_env_in_id.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_env_in_id.php @@ -1,154 +1,154 @@ -parameters = $this->getDefaultParameters(); - $this->services = []; - $this->normalizedIds = ['bar_%env(bar)%' => 'bar_%env(BAR)%']; - $this->methodMap = ['bar' => 'getBarService', 'bar_%env(BAR)%' => 'getBarenvBARService', 'foo' => 'getFooService']; - $this->privates = ['bar_%env(BAR)%' => \true]; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'bar_%env(BAR)%' => \true, 'baz_%env(BAR)%' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar' shared service. - * - * @return \stdClass - */ - protected function getBarService() - { - return $this->services['bar'] = new \stdClass(${($_ = isset($this->services['bar_%env(BAR)%']) ? $this->services['bar_%env(BAR)%'] : ($this->services['bar_%env(BAR)%'] = new \stdClass())) && \false ?: '_'}); - } - /** - * Gets the public 'foo' shared service. - * - * @return \stdClass - */ - protected function getFooService() - { - return $this->services['foo'] = new \stdClass(${($_ = isset($this->services['bar_%env(BAR)%']) ? $this->services['bar_%env(BAR)%'] : ($this->services['bar_%env(BAR)%'] = new \stdClass())) && \false ?: '_'}, ['baz_' . $this->getEnv('string:BAR') => new \stdClass()]); - } - /** - * Gets the private 'bar_%env(BAR)%' shared service. - * - * @return \stdClass - */ - protected function getBarenvBARService() - { - return $this->services['bar_%env(BAR)%'] = new \stdClass(); - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = []; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - private $normalizedParameterNames = ['env(bar)' => 'env(BAR)']; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['env(BAR)' => 'bar']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +parameters = $this->getDefaultParameters(); + $this->services = []; + $this->normalizedIds = ['bar_%env(bar)%' => 'bar_%env(BAR)%']; + $this->methodMap = ['bar' => 'getBarService', 'bar_%env(BAR)%' => 'getBarenvBARService', 'foo' => 'getFooService']; + $this->privates = ['bar_%env(BAR)%' => \true]; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'bar_%env(BAR)%' => \true, 'baz_%env(BAR)%' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar' shared service. + * + * @return \stdClass + */ + protected function getBarService() + { + return $this->services['bar'] = new \stdClass(${($_ = isset($this->services['bar_%env(BAR)%']) ? $this->services['bar_%env(BAR)%'] : ($this->services['bar_%env(BAR)%'] = new \stdClass())) && \false ?: '_'}); + } + /** + * Gets the public 'foo' shared service. + * + * @return \stdClass + */ + protected function getFooService() + { + return $this->services['foo'] = new \stdClass(${($_ = isset($this->services['bar_%env(BAR)%']) ? $this->services['bar_%env(BAR)%'] : ($this->services['bar_%env(BAR)%'] = new \stdClass())) && \false ?: '_'}, ['baz_' . $this->getEnv('string:BAR') => new \stdClass()]); + } + /** + * Gets the private 'bar_%env(BAR)%' shared service. + * + * @return \stdClass + */ + protected function getBarenvBARService() + { + return $this->services['bar_%env(BAR)%'] = new \stdClass(); + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = []; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + private $normalizedParameterNames = ['env(bar)' => 'env(BAR)']; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['env(BAR)' => 'bar']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_inline_requires.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_inline_requires.php index fba1411ad..e72f0b258 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_inline_requires.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_inline_requires.php @@ -1,176 +1,176 @@ -targetDirs[$i] = $dir = \dirname($dir); - } - $this->parameters = $this->getDefaultParameters(); - $this->services = []; - $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\includes\\hotpath\\c1' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C1', '_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\includes\\hotpath\\c2' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C2', '_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\includes\\hotpath\\c3' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3', '_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\parentnotexists' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\ParentNotExists']; - $this->methodMap = ['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\ParentNotExists' => 'getParentNotExistsService', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C1' => 'getC1Service', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C2' => 'getC2Service', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3' => 'getC3Service']; - $this->privates = ['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3' => \true]; - $this->aliases = []; - $this->privates['service_container'] = function () { - include_once $this->targetDirs[1] . '/includes/HotPath/I1.php'; - include_once $this->targetDirs[1] . '/includes/HotPath/P1.php'; - include_once $this->targetDirs[1] . '/includes/HotPath/T1.php'; - include_once $this->targetDirs[1] . '/includes/HotPath/C1.php'; - }; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists - */ - protected function getParentNotExistsService() - { - return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\ParentNotExists'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists(); - } - /** - * Gets the public 'Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C1' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C1 - */ - protected function getC1Service() - { - return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C1'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C1(); - } - /** - * Gets the public 'Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C2' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C2 - */ - protected function getC2Service() - { - include_once $this->targetDirs[1] . '/includes/HotPath/C2.php'; - include_once $this->targetDirs[1] . '/includes/HotPath/C3.php'; - return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C2'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C2(${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3())) && \false ?: '_'}); - } - /** - * Gets the private 'Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3 - */ - protected function getC3Service() - { - include_once $this->targetDirs[1] . '/includes/HotPath/C3.php'; - return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3(); - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = []; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - private $normalizedParameterNames = []; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['inline_requires' => \true]; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +targetDirs[$i] = $dir = \dirname($dir); + } + $this->parameters = $this->getDefaultParameters(); + $this->services = []; + $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\includes\\hotpath\\c1' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C1', '_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\includes\\hotpath\\c2' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C2', '_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\includes\\hotpath\\c3' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3', '_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\parentnotexists' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\ParentNotExists']; + $this->methodMap = ['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\ParentNotExists' => 'getParentNotExistsService', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C1' => 'getC1Service', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C2' => 'getC2Service', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3' => 'getC3Service']; + $this->privates = ['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3' => \true]; + $this->aliases = []; + $this->privates['service_container'] = function () { + include_once $this->targetDirs[1] . '/includes/HotPath/I1.php'; + include_once $this->targetDirs[1] . '/includes/HotPath/P1.php'; + include_once $this->targetDirs[1] . '/includes/HotPath/T1.php'; + include_once $this->targetDirs[1] . '/includes/HotPath/C1.php'; + }; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists + */ + protected function getParentNotExistsService() + { + return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\ParentNotExists'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\ParentNotExists(); + } + /** + * Gets the public 'Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C1' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C1 + */ + protected function getC1Service() + { + return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C1'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C1(); + } + /** + * Gets the public 'Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C2' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C2 + */ + protected function getC2Service() + { + include_once $this->targetDirs[1] . '/includes/HotPath/C2.php'; + include_once $this->targetDirs[1] . '/includes/HotPath/C3.php'; + return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C2'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C2(${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3())) && \false ?: '_'}); + } + /** + * Gets the private 'Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3 + */ + protected function getC3Service() + { + include_once $this->targetDirs[1] . '/includes/HotPath/C3.php'; + return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\includes\\HotPath\\C3'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\includes\HotPath\C3(); + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = []; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + private $normalizedParameterNames = []; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['inline_requires' => \true]; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_inline_self_ref.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_inline_self_ref.php index 43617c670..3a1ccc846 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_inline_self_ref.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_inline_self_ref.php @@ -1,67 +1,67 @@ -services = []; - $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\app\\foo' => '_PhpScoper5ea00cc67502b\\App\\Foo']; - $this->methodMap = ['_PhpScoper5ea00cc67502b\\App\\Foo' => 'getFooService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'App\Foo' shared service. - * - * @return \App\Foo - */ - protected function getFooService() - { - $a = new \_PhpScoper5ea00cc67502b\App\Bar(); - $b = new \_PhpScoper5ea00cc67502b\App\Baz($a); - $b->bar = $a; - $this->services['App\\Foo'] = $instance = new \_PhpScoper5ea00cc67502b\App\Foo($b); - $a->foo = $instance; - return $instance; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Inline_Self_Ref', 'Symfony_DI_PhpDumper_Test_Inline_Self_Ref', \false); +services = []; + $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\app\\foo' => '_PhpScoper5ea00cc67502b\\App\\Foo']; + $this->methodMap = ['_PhpScoper5ea00cc67502b\\App\\Foo' => 'getFooService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'App\Foo' shared service. + * + * @return \App\Foo + */ + protected function getFooService() + { + $a = new \_PhpScoper5ea00cc67502b\App\Bar(); + $b = new \_PhpScoper5ea00cc67502b\App\Baz($a); + $b->bar = $a; + $this->services['App\\Foo'] = $instance = new \_PhpScoper5ea00cc67502b\App\Foo($b); + $a->foo = $instance; + return $instance; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Inline_Self_Ref', 'Symfony_DI_PhpDumper_Test_Inline_Self_Ref', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_legacy_privates.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_legacy_privates.php index feaac7043..90a199459 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_legacy_privates.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_legacy_privates.php @@ -1,147 +1,147 @@ -targetDirs[$i] = $dir = \dirname($dir); - } - $this->services = []; - $this->methodMap = ['bar' => 'getBarService', 'private' => 'getPrivateService', 'private_alias' => 'getPrivateAliasService', 'private_alias_decorator' => 'getPrivateAliasDecoratorService', 'private_child' => 'getPrivateChildService', 'private_decorator' => 'getPrivateDecoratorService', 'private_not_inlined' => 'getPrivateNotInlinedService', 'private_not_removed' => 'getPrivateNotRemovedService', 'private_parent' => 'getPrivateParentService', 'public_child' => 'getPublicChildService']; - $this->privates = ['decorated_private' => \true, 'decorated_private_alias' => \true, 'private' => \true, 'private_alias' => \true, 'private_child' => \true, 'private_not_inlined' => \true, 'private_not_removed' => \true, 'private_parent' => \true]; - $this->aliases = ['alias_to_private' => 'private', 'decorated_private' => 'private_decorator', 'decorated_private_alias' => 'private_alias_decorator']; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'decorated_private' => \true, 'decorated_private_alias' => \true, 'foo' => \true, 'private' => \true, 'private_alias' => \true, 'private_alias_decorator.inner' => \true, 'private_child' => \true, 'private_decorator.inner' => \true, 'private_not_inlined' => \true, 'private_not_removed' => \true, 'private_parent' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar' shared service. - * - * @return \stdClass - */ - protected function getBarService() - { - return $this->services['bar'] = new \stdClass(${($_ = isset($this->services['private_not_inlined']) ? $this->services['private_not_inlined'] : ($this->services['private_not_inlined'] = new \stdClass())) && \false ?: '_'}); - } - /** - * Gets the public 'private_alias_decorator' shared service. - * - * @return \stdClass - */ - protected function getPrivateAliasDecoratorService() - { - return $this->services['private_alias_decorator'] = new \stdClass(); - } - /** - * Gets the public 'private_decorator' shared service. - * - * @return \stdClass - */ - protected function getPrivateDecoratorService() - { - return $this->services['private_decorator'] = new \stdClass(); - } - /** - * Gets the public 'public_child' shared service. - * - * @return \stdClass - */ - protected function getPublicChildService() - { - return $this->services['public_child'] = new \stdClass(); - } - /** - * Gets the private 'private' shared service. - * - * @return \stdClass - */ - protected function getPrivateService() - { - return $this->services['private'] = new \stdClass(); - } - /** - * Gets the private 'private_alias' shared service. - * - * @return \stdClass - */ - protected function getPrivateAliasService() - { - return $this->services['private_alias'] = new \stdClass(); - } - /** - * Gets the private 'private_child' shared service. - * - * @return \stdClass - */ - protected function getPrivateChildService() - { - return $this->services['private_child'] = new \stdClass(); - } - /** - * Gets the private 'private_not_inlined' shared service. - * - * @return \stdClass - */ - protected function getPrivateNotInlinedService() - { - return $this->services['private_not_inlined'] = new \stdClass(); - } - /** - * Gets the private 'private_not_removed' shared service. - * - * @return \stdClass - */ - protected function getPrivateNotRemovedService() - { - return $this->services['private_not_removed'] = new \stdClass(); - } - /** - * Gets the private 'private_parent' shared service. - * - * @return \stdClass - */ - protected function getPrivateParentService() - { - return $this->services['private_parent'] = new \stdClass(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Legacy_Privates', 'Symfony_DI_PhpDumper_Test_Legacy_Privates', \false); +targetDirs[$i] = $dir = \dirname($dir); + } + $this->services = []; + $this->methodMap = ['bar' => 'getBarService', 'private' => 'getPrivateService', 'private_alias' => 'getPrivateAliasService', 'private_alias_decorator' => 'getPrivateAliasDecoratorService', 'private_child' => 'getPrivateChildService', 'private_decorator' => 'getPrivateDecoratorService', 'private_not_inlined' => 'getPrivateNotInlinedService', 'private_not_removed' => 'getPrivateNotRemovedService', 'private_parent' => 'getPrivateParentService', 'public_child' => 'getPublicChildService']; + $this->privates = ['decorated_private' => \true, 'decorated_private_alias' => \true, 'private' => \true, 'private_alias' => \true, 'private_child' => \true, 'private_not_inlined' => \true, 'private_not_removed' => \true, 'private_parent' => \true]; + $this->aliases = ['alias_to_private' => 'private', 'decorated_private' => 'private_decorator', 'decorated_private_alias' => 'private_alias_decorator']; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'decorated_private' => \true, 'decorated_private_alias' => \true, 'foo' => \true, 'private' => \true, 'private_alias' => \true, 'private_alias_decorator.inner' => \true, 'private_child' => \true, 'private_decorator.inner' => \true, 'private_not_inlined' => \true, 'private_not_removed' => \true, 'private_parent' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar' shared service. + * + * @return \stdClass + */ + protected function getBarService() + { + return $this->services['bar'] = new \stdClass(${($_ = isset($this->services['private_not_inlined']) ? $this->services['private_not_inlined'] : ($this->services['private_not_inlined'] = new \stdClass())) && \false ?: '_'}); + } + /** + * Gets the public 'private_alias_decorator' shared service. + * + * @return \stdClass + */ + protected function getPrivateAliasDecoratorService() + { + return $this->services['private_alias_decorator'] = new \stdClass(); + } + /** + * Gets the public 'private_decorator' shared service. + * + * @return \stdClass + */ + protected function getPrivateDecoratorService() + { + return $this->services['private_decorator'] = new \stdClass(); + } + /** + * Gets the public 'public_child' shared service. + * + * @return \stdClass + */ + protected function getPublicChildService() + { + return $this->services['public_child'] = new \stdClass(); + } + /** + * Gets the private 'private' shared service. + * + * @return \stdClass + */ + protected function getPrivateService() + { + return $this->services['private'] = new \stdClass(); + } + /** + * Gets the private 'private_alias' shared service. + * + * @return \stdClass + */ + protected function getPrivateAliasService() + { + return $this->services['private_alias'] = new \stdClass(); + } + /** + * Gets the private 'private_child' shared service. + * + * @return \stdClass + */ + protected function getPrivateChildService() + { + return $this->services['private_child'] = new \stdClass(); + } + /** + * Gets the private 'private_not_inlined' shared service. + * + * @return \stdClass + */ + protected function getPrivateNotInlinedService() + { + return $this->services['private_not_inlined'] = new \stdClass(); + } + /** + * Gets the private 'private_not_removed' shared service. + * + * @return \stdClass + */ + protected function getPrivateNotRemovedService() + { + return $this->services['private_not_removed'] = new \stdClass(); + } + /** + * Gets the private 'private_parent' shared service. + * + * @return \stdClass + */ + protected function getPrivateParentService() + { + return $this->services['private_parent'] = new \stdClass(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Legacy_Privates', 'Symfony_DI_PhpDumper_Test_Legacy_Privates', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_locator.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_locator.php index fa8ffa558..537dda67f 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_locator.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_locator.php @@ -1,155 +1,155 @@ -services = []; - $this->methodMap = ['bar_service' => 'getBarServiceService', 'baz_service' => 'getBazServiceService', 'foo_service' => 'getFooServiceService', 'translator.loader_1' => 'getTranslator_Loader1Service', 'translator.loader_2' => 'getTranslator_Loader2Service', 'translator.loader_3' => 'getTranslator_Loader3Service', 'translator_1' => 'getTranslator1Service', 'translator_2' => 'getTranslator2Service', 'translator_3' => 'getTranslator3Service']; - $this->privates = ['baz_service' => \true]; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'baz_service' => \true, 'translator.loader_1_locator' => \true, 'translator.loader_2_locator' => \true, 'translator.loader_3_locator' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar_service' shared service. - * - * @return \stdClass - */ - protected function getBarServiceService() - { - return $this->services['bar_service'] = new \stdClass(${($_ = isset($this->services['baz_service']) ? $this->services['baz_service'] : ($this->services['baz_service'] = new \stdClass())) && \false ?: '_'}); - } - /** - * Gets the public 'foo_service' shared service. - * - * @return \Symfony\Component\DependencyInjection\ServiceLocator - */ - protected function getFooServiceService() - { - return $this->services['foo_service'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['bar' => function () { - return ${($_ = isset($this->services['bar_service']) ? $this->services['bar_service'] : $this->getBarServiceService()) && \false ?: '_'}; - }, 'baz' => function () { - $f = function (\stdClass $v) { - return $v; - }; - return $f(${($_ = isset($this->services['baz_service']) ? $this->services['baz_service'] : ($this->services['baz_service'] = new \stdClass())) && \false ?: '_'}); - }, 'nil' => function () { - return \NULL; - }]); - } - /** - * Gets the public 'translator.loader_1' shared service. - * - * @return \stdClass - */ - protected function getTranslator_Loader1Service() - { - return $this->services['translator.loader_1'] = new \stdClass(); - } - /** - * Gets the public 'translator.loader_2' shared service. - * - * @return \stdClass - */ - protected function getTranslator_Loader2Service() - { - return $this->services['translator.loader_2'] = new \stdClass(); - } - /** - * Gets the public 'translator.loader_3' shared service. - * - * @return \stdClass - */ - protected function getTranslator_Loader3Service() - { - return $this->services['translator.loader_3'] = new \stdClass(); - } - /** - * Gets the public 'translator_1' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator - */ - protected function getTranslator1Service() - { - return $this->services['translator_1'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['translator.loader_1' => function () { - return ${($_ = isset($this->services['translator.loader_1']) ? $this->services['translator.loader_1'] : ($this->services['translator.loader_1'] = new \stdClass())) && \false ?: '_'}; - }])); - } - /** - * Gets the public 'translator_2' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator - */ - protected function getTranslator2Service() - { - $this->services['translator_2'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['translator.loader_2' => function () { - return ${($_ = isset($this->services['translator.loader_2']) ? $this->services['translator.loader_2'] : ($this->services['translator.loader_2'] = new \stdClass())) && \false ?: '_'}; - }])); - $instance->addResource('db', ${($_ = isset($this->services['translator.loader_2']) ? $this->services['translator.loader_2'] : ($this->services['translator.loader_2'] = new \stdClass())) && \false ?: '_'}, 'nl'); - return $instance; - } - /** - * Gets the public 'translator_3' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator - */ - protected function getTranslator3Service() - { - $this->services['translator_3'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['translator.loader_3' => function () { - return ${($_ = isset($this->services['translator.loader_3']) ? $this->services['translator.loader_3'] : ($this->services['translator.loader_3'] = new \stdClass())) && \false ?: '_'}; - }])); - $a = ${($_ = isset($this->services['translator.loader_3']) ? $this->services['translator.loader_3'] : ($this->services['translator.loader_3'] = new \stdClass())) && \false ?: '_'}; - $instance->addResource('db', $a, 'nl'); - $instance->addResource('db', $a, 'en'); - return $instance; - } - /** - * Gets the private 'baz_service' shared service. - * - * @return \stdClass - */ - protected function getBazServiceService() - { - return $this->services['baz_service'] = new \stdClass(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +services = []; + $this->methodMap = ['bar_service' => 'getBarServiceService', 'baz_service' => 'getBazServiceService', 'foo_service' => 'getFooServiceService', 'translator.loader_1' => 'getTranslator_Loader1Service', 'translator.loader_2' => 'getTranslator_Loader2Service', 'translator.loader_3' => 'getTranslator_Loader3Service', 'translator_1' => 'getTranslator1Service', 'translator_2' => 'getTranslator2Service', 'translator_3' => 'getTranslator3Service']; + $this->privates = ['baz_service' => \true]; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'baz_service' => \true, 'translator.loader_1_locator' => \true, 'translator.loader_2_locator' => \true, 'translator.loader_3_locator' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar_service' shared service. + * + * @return \stdClass + */ + protected function getBarServiceService() + { + return $this->services['bar_service'] = new \stdClass(${($_ = isset($this->services['baz_service']) ? $this->services['baz_service'] : ($this->services['baz_service'] = new \stdClass())) && \false ?: '_'}); + } + /** + * Gets the public 'foo_service' shared service. + * + * @return \Symfony\Component\DependencyInjection\ServiceLocator + */ + protected function getFooServiceService() + { + return $this->services['foo_service'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['bar' => function () { + return ${($_ = isset($this->services['bar_service']) ? $this->services['bar_service'] : $this->getBarServiceService()) && \false ?: '_'}; + }, 'baz' => function () { + $f = function (\stdClass $v) { + return $v; + }; + return $f(${($_ = isset($this->services['baz_service']) ? $this->services['baz_service'] : ($this->services['baz_service'] = new \stdClass())) && \false ?: '_'}); + }, 'nil' => function () { + return \NULL; + }]); + } + /** + * Gets the public 'translator.loader_1' shared service. + * + * @return \stdClass + */ + protected function getTranslator_Loader1Service() + { + return $this->services['translator.loader_1'] = new \stdClass(); + } + /** + * Gets the public 'translator.loader_2' shared service. + * + * @return \stdClass + */ + protected function getTranslator_Loader2Service() + { + return $this->services['translator.loader_2'] = new \stdClass(); + } + /** + * Gets the public 'translator.loader_3' shared service. + * + * @return \stdClass + */ + protected function getTranslator_Loader3Service() + { + return $this->services['translator.loader_3'] = new \stdClass(); + } + /** + * Gets the public 'translator_1' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator + */ + protected function getTranslator1Service() + { + return $this->services['translator_1'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['translator.loader_1' => function () { + return ${($_ = isset($this->services['translator.loader_1']) ? $this->services['translator.loader_1'] : ($this->services['translator.loader_1'] = new \stdClass())) && \false ?: '_'}; + }])); + } + /** + * Gets the public 'translator_2' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator + */ + protected function getTranslator2Service() + { + $this->services['translator_2'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['translator.loader_2' => function () { + return ${($_ = isset($this->services['translator.loader_2']) ? $this->services['translator.loader_2'] : ($this->services['translator.loader_2'] = new \stdClass())) && \false ?: '_'}; + }])); + $instance->addResource('db', ${($_ = isset($this->services['translator.loader_2']) ? $this->services['translator.loader_2'] : ($this->services['translator.loader_2'] = new \stdClass())) && \false ?: '_'}, 'nl'); + return $instance; + } + /** + * Gets the public 'translator_3' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator + */ + protected function getTranslator3Service() + { + $this->services['translator_3'] = $instance = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\StubbedTranslator(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['translator.loader_3' => function () { + return ${($_ = isset($this->services['translator.loader_3']) ? $this->services['translator.loader_3'] : ($this->services['translator.loader_3'] = new \stdClass())) && \false ?: '_'}; + }])); + $a = ${($_ = isset($this->services['translator.loader_3']) ? $this->services['translator.loader_3'] : ($this->services['translator.loader_3'] = new \stdClass())) && \false ?: '_'}; + $instance->addResource('db', $a, 'nl'); + $instance->addResource('db', $a, 'en'); + return $instance; + } + /** + * Gets the private 'baz_service' shared service. + * + * @return \stdClass + */ + protected function getBazServiceService() + { + return $this->services['baz_service'] = new \stdClass(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_non_shared_lazy.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_non_shared_lazy.php index 631760f65..2678a6fb8 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_non_shared_lazy.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_non_shared_lazy.php @@ -1,77 +1,77 @@ -services = []; - $this->methodMap = ['bar' => 'getBarService', 'foo' => 'getFooService']; - $this->privates = ['bar' => \true, 'foo' => \true]; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'bar' => \true, 'foo' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - protected function createProxy($class, \Closure $factory) - { - return $factory(); - } - /** - * Gets the private 'bar' shared service. - * - * @return \stdClass - */ - protected function getBarService() - { - return $this->services['bar'] = new \stdClass(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}); - } - /** - * Gets the private 'foo' service. - * - * @return \stdClass - */ - protected function getFooService($lazyLoad = \true) - { - // lazy factory for stdClass - return new \stdClass(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); -// proxy code for stdClass +services = []; + $this->methodMap = ['bar' => 'getBarService', 'foo' => 'getFooService']; + $this->privates = ['bar' => \true, 'foo' => \true]; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'bar' => \true, 'foo' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + protected function createProxy($class, \Closure $factory) + { + return $factory(); + } + /** + * Gets the private 'bar' shared service. + * + * @return \stdClass + */ + protected function getBarService() + { + return $this->services['bar'] = new \stdClass(${($_ = isset($this->services['foo']) ? $this->services['foo'] : $this->getFooService()) && \false ?: '_'}); + } + /** + * Gets the private 'foo' service. + * + * @return \stdClass + */ + protected function getFooService($lazyLoad = \true) + { + // lazy factory for stdClass + return new \stdClass(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +// proxy code for stdClass diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_private_frozen.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_private_frozen.php index e89d8927c..c47b7e921 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_private_frozen.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_private_frozen.php @@ -1,80 +1,80 @@ -services = []; - $this->methodMap = ['bar_service' => 'getBarServiceService', 'baz_service' => 'getBazServiceService', 'foo_service' => 'getFooServiceService']; - $this->privates = ['baz_service' => \true]; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'baz_service' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar_service' shared service. - * - * @return \stdClass - */ - protected function getBarServiceService() - { - return $this->services['bar_service'] = new \stdClass(${($_ = isset($this->services['baz_service']) ? $this->services['baz_service'] : ($this->services['baz_service'] = new \stdClass())) && \false ?: '_'}); - } - /** - * Gets the public 'foo_service' shared service. - * - * @return \stdClass - */ - protected function getFooServiceService() - { - return $this->services['foo_service'] = new \stdClass(${($_ = isset($this->services['baz_service']) ? $this->services['baz_service'] : ($this->services['baz_service'] = new \stdClass())) && \false ?: '_'}); - } - /** - * Gets the private 'baz_service' shared service. - * - * @return \stdClass - */ - protected function getBazServiceService() - { - return $this->services['baz_service'] = new \stdClass(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +services = []; + $this->methodMap = ['bar_service' => 'getBarServiceService', 'baz_service' => 'getBazServiceService', 'foo_service' => 'getFooServiceService']; + $this->privates = ['baz_service' => \true]; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'baz_service' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar_service' shared service. + * + * @return \stdClass + */ + protected function getBarServiceService() + { + return $this->services['bar_service'] = new \stdClass(${($_ = isset($this->services['baz_service']) ? $this->services['baz_service'] : ($this->services['baz_service'] = new \stdClass())) && \false ?: '_'}); + } + /** + * Gets the public 'foo_service' shared service. + * + * @return \stdClass + */ + protected function getFooServiceService() + { + return $this->services['foo_service'] = new \stdClass(${($_ = isset($this->services['baz_service']) ? $this->services['baz_service'] : ($this->services['baz_service'] = new \stdClass())) && \false ?: '_'}); + } + /** + * Gets the private 'baz_service' shared service. + * + * @return \stdClass + */ + protected function getBazServiceService() + { + return $this->services['baz_service'] = new \stdClass(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_private_in_expression.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_private_in_expression.php index c315ec5f7..ed7783067 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_private_in_expression.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_private_in_expression.php @@ -1,71 +1,71 @@ -services = []; - $this->methodMap = ['private_foo' => 'getPrivateFooService', 'public_foo' => 'getPublicFooService']; - $this->privates = ['private_foo' => \true]; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'private_bar' => \true, 'private_foo' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'public_foo' shared service. - * - * @return \stdClass - */ - protected function getPublicFooService() - { - return $this->services['public_foo'] = new \stdClass(${($_ = isset($this->services['private_foo']) ? $this->services['private_foo'] : ($this->services['private_foo'] = new \stdClass())) && \false ?: '_'}->bar); - } - /** - * Gets the private 'private_foo' shared service. - * - * @return \stdClass - */ - protected function getPrivateFooService() - { - return $this->services['private_foo'] = new \stdClass(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +services = []; + $this->methodMap = ['private_foo' => 'getPrivateFooService', 'public_foo' => 'getPublicFooService']; + $this->privates = ['private_foo' => \true]; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'private_bar' => \true, 'private_foo' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'public_foo' shared service. + * + * @return \stdClass + */ + protected function getPublicFooService() + { + return $this->services['public_foo'] = new \stdClass(${($_ = isset($this->services['private_foo']) ? $this->services['private_foo'] : ($this->services['private_foo'] = new \stdClass())) && \false ?: '_'}->bar); + } + /** + * Gets the private 'private_foo' shared service. + * + * @return \stdClass + */ + protected function getPrivateFooService() + { + return $this->services['private_foo'] = new \stdClass(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_rot13_env.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_rot13_env.php index 6787993f6..db5c7324a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_rot13_env.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_rot13_env.php @@ -1,154 +1,154 @@ -parameters = $this->getDefaultParameters(); - $this->services = []; - $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\dumper\\rot13envvarprocessor' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor']; - $this->methodMap = ['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor' => 'getRot13EnvVarProcessorService', 'container.env_var_processors_locator' => 'getContainer_EnvVarProcessorsLocatorService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'Symfony\Component\DependencyInjection\Tests\Dumper\Rot13EnvVarProcessor' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Dumper\Rot13EnvVarProcessor - */ - protected function getRot13EnvVarProcessorService() - { - return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\Rot13EnvVarProcessor(); - } - /** - * Gets the public 'container.env_var_processors_locator' shared service. - * - * @return \Symfony\Component\DependencyInjection\ServiceLocator - */ - protected function getContainer_EnvVarProcessorsLocatorService() - { - return $this->services['container.env_var_processors_locator'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['rot13' => function () { - return ${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\Rot13EnvVarProcessor())) && \false ?: '_'}; - }]); - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = ['hello' => \false]; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - switch ($name) { - case 'hello': - $value = $this->getEnv('rot13:foo'); - break; - default: - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - $this->loadedDynamicParameters[$name] = \true; - return $this->dynamicParameters[$name] = $value; - } - private $normalizedParameterNames = []; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['env(foo)' => 'jbeyq']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Rot13Parameters', 'Symfony_DI_PhpDumper_Test_Rot13Parameters', \false); +parameters = $this->getDefaultParameters(); + $this->services = []; + $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\dumper\\rot13envvarprocessor' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor']; + $this->methodMap = ['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor' => 'getRot13EnvVarProcessorService', 'container.env_var_processors_locator' => 'getContainer_EnvVarProcessorsLocatorService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'Symfony\Component\DependencyInjection\Tests\Dumper\Rot13EnvVarProcessor' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Dumper\Rot13EnvVarProcessor + */ + protected function getRot13EnvVarProcessorService() + { + return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\Rot13EnvVarProcessor(); + } + /** + * Gets the public 'container.env_var_processors_locator' shared service. + * + * @return \Symfony\Component\DependencyInjection\ServiceLocator + */ + protected function getContainer_EnvVarProcessorsLocatorService() + { + return $this->services['container.env_var_processors_locator'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['rot13' => function () { + return ${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Dumper\\Rot13EnvVarProcessor'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\Rot13EnvVarProcessor())) && \false ?: '_'}; + }]); + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = ['hello' => \false]; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + switch ($name) { + case 'hello': + $value = $this->getEnv('rot13:foo'); + break; + default: + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + $this->loadedDynamicParameters[$name] = \true; + return $this->dynamicParameters[$name] = $value; + } + private $normalizedParameterNames = []; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['env(foo)' => 'jbeyq']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Rot13Parameters', 'Symfony_DI_PhpDumper_Test_Rot13Parameters', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_subscriber.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_subscriber.php index 9034ef6e8..4b6907bfd 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_subscriber.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_subscriber.php @@ -1,101 +1,101 @@ -services = []; - $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\customdefinition' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition', '_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\testservicesubscriber' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber']; - $this->methodMap = ['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition' => 'getCustomDefinitionService', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber' => 'getTestServiceSubscriberService', 'foo_service' => 'getFooServiceService']; - $this->privates = ['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition' => \true]; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition' => \true, 'service_locator.jmktfsv' => \true, 'service_locator.jmktfsv.foo_service' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber - */ - protected function getTestServiceSubscriberService() - { - return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber(); - } - /** - * Gets the public 'foo_service' shared autowired service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber - */ - protected function getFooServiceService() - { - return $this->services['foo_service'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber((new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition' => function () { - $f = function (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition $v = null) { - return $v; - }; - return $f(${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition())) && \false ?: '_'}); - }, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber' => function () { - $f = function (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber $v) { - return $v; - }; - return $f(${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber())) && \false ?: '_'}); - }, 'bar' => function () { - $f = function (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition $v) { - return $v; - }; - return $f(${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber())) && \false ?: '_'}); - }, 'baz' => function () { - $f = function (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition $v = null) { - return $v; - }; - return $f(${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition())) && \false ?: '_'}); - }]))->withContext('foo_service', $this)); - } - /** - * Gets the private 'Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition' shared service. - * - * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition - */ - protected function getCustomDefinitionService() - { - return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +services = []; + $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\customdefinition' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition', '_PhpScoper5ea00cc67502b\\symfony\\component\\dependencyinjection\\tests\\fixtures\\testservicesubscriber' => '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber']; + $this->methodMap = ['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition' => 'getCustomDefinitionService', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber' => 'getTestServiceSubscriberService', 'foo_service' => 'getFooServiceService']; + $this->privates = ['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition' => \true]; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition' => \true, 'service_locator.jmktfsv' => \true, 'service_locator.jmktfsv.foo_service' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber + */ + protected function getTestServiceSubscriberService() + { + return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber(); + } + /** + * Gets the public 'foo_service' shared autowired service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber + */ + protected function getFooServiceService() + { + return $this->services['foo_service'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber((new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition' => function () { + $f = function (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition $v = null) { + return $v; + }; + return $f(${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition())) && \false ?: '_'}); + }, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber' => function () { + $f = function (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber $v) { + return $v; + }; + return $f(${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber())) && \false ?: '_'}); + }, 'bar' => function () { + $f = function (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition $v) { + return $v; + }; + return $f(${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\TestServiceSubscriber'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\TestServiceSubscriber())) && \false ?: '_'}); + }, 'baz' => function () { + $f = function (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition $v = null) { + return $v; + }; + return $f(${($_ = isset($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition']) ? $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition'] : ($this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition())) && \false ?: '_'}); + }]))->withContext('foo_service', $this)); + } + /** + * Gets the private 'Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition' shared service. + * + * @return \Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition + */ + protected function getCustomDefinitionService() + { + return $this->services['Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\CustomDefinition'] = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CustomDefinition(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_tsantos.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_tsantos.php index ed4350bc4..23c4bae5d 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_tsantos.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_tsantos.php @@ -1,73 +1,73 @@ -services = []; - $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\tsantos\\serializer\\serializerinterface' => '_PhpScoper5ea00cc67502b\\TSantos\\Serializer\\SerializerInterface']; - $this->methodMap = ['tsantos_serializer' => 'getTsantosSerializerService']; - $this->aliases = ['_PhpScoper5ea00cc67502b\\TSantos\\Serializer\\SerializerInterface' => 'tsantos_serializer']; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'tsantos_serializer' shared service. - * - * @return \TSantos\Serializer\EventEmitterSerializer - */ - protected function getTsantosSerializerService() - { - $a = new \_PhpScoper5ea00cc67502b\TSantos\Serializer\NormalizerRegistry(); - $b = new \_PhpScoper5ea00cc67502b\TSantos\Serializer\Normalizer\CollectionNormalizer(); - $c = new \_PhpScoper5ea00cc67502b\TSantos\Serializer\EventDispatcher\EventDispatcher(); - $c->addSubscriber(new \_PhpScoper5ea00cc67502b\TSantos\SerializerBundle\EventListener\StopwatchListener(new \_PhpScoper5ea00cc67502b\Symfony\Component\Stopwatch\Stopwatch(\true))); - $this->services['tsantos_serializer'] = $instance = new \_PhpScoper5ea00cc67502b\TSantos\Serializer\EventEmitterSerializer(new \_PhpScoper5ea00cc67502b\TSantos\Serializer\Encoder\JsonEncoder(), $a, $c); - $b->setSerializer($instance); - $d = new \_PhpScoper5ea00cc67502b\TSantos\Serializer\Normalizer\JsonNormalizer(); - $d->setSerializer($instance); - $a->add(new \_PhpScoper5ea00cc67502b\TSantos\Serializer\Normalizer\ObjectNormalizer(new \_PhpScoper5ea00cc67502b\TSantos\SerializerBundle\Serializer\CircularReferenceHandler())); - $a->add($b); - $a->add($d); - return $instance; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); +services = []; + $this->normalizedIds = ['_PhpScoper5ea00cc67502b\\tsantos\\serializer\\serializerinterface' => '_PhpScoper5ea00cc67502b\\TSantos\\Serializer\\SerializerInterface']; + $this->methodMap = ['tsantos_serializer' => 'getTsantosSerializerService']; + $this->aliases = ['_PhpScoper5ea00cc67502b\\TSantos\\Serializer\\SerializerInterface' => 'tsantos_serializer']; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'tsantos_serializer' shared service. + * + * @return \TSantos\Serializer\EventEmitterSerializer + */ + protected function getTsantosSerializerService() + { + $a = new \_PhpScoper5ea00cc67502b\TSantos\Serializer\NormalizerRegistry(); + $b = new \_PhpScoper5ea00cc67502b\TSantos\Serializer\Normalizer\CollectionNormalizer(); + $c = new \_PhpScoper5ea00cc67502b\TSantos\Serializer\EventDispatcher\EventDispatcher(); + $c->addSubscriber(new \_PhpScoper5ea00cc67502b\TSantos\SerializerBundle\EventListener\StopwatchListener(new \_PhpScoper5ea00cc67502b\Symfony\Component\Stopwatch\Stopwatch(\true))); + $this->services['tsantos_serializer'] = $instance = new \_PhpScoper5ea00cc67502b\TSantos\Serializer\EventEmitterSerializer(new \_PhpScoper5ea00cc67502b\TSantos\Serializer\Encoder\JsonEncoder(), $a, $c); + $b->setSerializer($instance); + $d = new \_PhpScoper5ea00cc67502b\TSantos\Serializer\Normalizer\JsonNormalizer(); + $d->setSerializer($instance); + $a->add(new \_PhpScoper5ea00cc67502b\TSantos\Serializer\Normalizer\ObjectNormalizer(new \_PhpScoper5ea00cc67502b\TSantos\SerializerBundle\Serializer\CircularReferenceHandler())); + $a->add($b); + $a->add($d); + return $instance; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\ProjectServiceContainer', 'ProjectServiceContainer', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_uninitialized_ref.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_uninitialized_ref.php index 19e8d6f61..d0dec3698 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_uninitialized_ref.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_uninitialized_ref.php @@ -1,115 +1,115 @@ -services = []; - $this->methodMap = ['bar' => 'getBarService', 'baz' => 'getBazService', 'foo1' => 'getFoo1Service', 'foo3' => 'getFoo3Service']; - $this->privates = ['foo3' => \true]; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'foo2' => \true, 'foo3' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar' shared service. - * - * @return \stdClass - */ - protected function getBarService() - { - $this->services['bar'] = $instance = new \stdClass(); - $instance->foo1 = ${($_ = isset($this->services['foo1']) ? $this->services['foo1'] : null) && \false ?: '_'}; - $instance->foo2 = null; - $instance->foo3 = ${($_ = isset($this->services['foo3']) ? $this->services['foo3'] : null) && \false ?: '_'}; - $instance->closures = [0 => function () { - return ${($_ = isset($this->services['foo1']) ? $this->services['foo1'] : null) && \false ?: '_'}; - }, 1 => function () { - return null; - }, 2 => function () { - return ${($_ = isset($this->services['foo3']) ? $this->services['foo3'] : null) && \false ?: '_'}; - }]; - $instance->iter = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { - if (isset($this->services['foo1'])) { - (yield 'foo1' => ${($_ = isset($this->services['foo1']) ? $this->services['foo1'] : null) && \false ?: '_'}); - } - if (\false) { - (yield 'foo2' => null); - } - if (isset($this->services['foo3'])) { - (yield 'foo3' => ${($_ = isset($this->services['foo3']) ? $this->services['foo3'] : null) && \false ?: '_'}); - } - }, function () { - return 0 + (int) isset($this->services['foo1']) + (int) \false + (int) isset($this->services['foo3']); - }); - return $instance; - } - /** - * Gets the public 'baz' shared service. - * - * @return \stdClass - */ - protected function getBazService() - { - $this->services['baz'] = $instance = new \stdClass(); - $instance->foo3 = ${($_ = isset($this->services['foo3']) ? $this->services['foo3'] : ($this->services['foo3'] = new \stdClass())) && \false ?: '_'}; - return $instance; - } - /** - * Gets the public 'foo1' shared service. - * - * @return \stdClass - */ - protected function getFoo1Service() - { - return $this->services['foo1'] = new \stdClass(); - } - /** - * Gets the private 'foo3' shared service. - * - * @return \stdClass - */ - protected function getFoo3Service() - { - return $this->services['foo3'] = new \stdClass(); - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Uninitialized_Reference', 'Symfony_DI_PhpDumper_Test_Uninitialized_Reference', \false); +services = []; + $this->methodMap = ['bar' => 'getBarService', 'baz' => 'getBazService', 'foo1' => 'getFoo1Service', 'foo3' => 'getFoo3Service']; + $this->privates = ['foo3' => \true]; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true, 'foo2' => \true, 'foo3' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar' shared service. + * + * @return \stdClass + */ + protected function getBarService() + { + $this->services['bar'] = $instance = new \stdClass(); + $instance->foo1 = ${($_ = isset($this->services['foo1']) ? $this->services['foo1'] : null) && \false ?: '_'}; + $instance->foo2 = null; + $instance->foo3 = ${($_ = isset($this->services['foo3']) ? $this->services['foo3'] : null) && \false ?: '_'}; + $instance->closures = [0 => function () { + return ${($_ = isset($this->services['foo1']) ? $this->services['foo1'] : null) && \false ?: '_'}; + }, 1 => function () { + return null; + }, 2 => function () { + return ${($_ = isset($this->services['foo3']) ? $this->services['foo3'] : null) && \false ?: '_'}; + }]; + $instance->iter = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\RewindableGenerator(function () { + if (isset($this->services['foo1'])) { + (yield 'foo1' => ${($_ = isset($this->services['foo1']) ? $this->services['foo1'] : null) && \false ?: '_'}); + } + if (\false) { + (yield 'foo2' => null); + } + if (isset($this->services['foo3'])) { + (yield 'foo3' => ${($_ = isset($this->services['foo3']) ? $this->services['foo3'] : null) && \false ?: '_'}); + } + }, function () { + return 0 + (int) isset($this->services['foo1']) + (int) \false + (int) isset($this->services['foo3']); + }); + return $instance; + } + /** + * Gets the public 'baz' shared service. + * + * @return \stdClass + */ + protected function getBazService() + { + $this->services['baz'] = $instance = new \stdClass(); + $instance->foo3 = ${($_ = isset($this->services['foo3']) ? $this->services['foo3'] : ($this->services['foo3'] = new \stdClass())) && \false ?: '_'}; + return $instance; + } + /** + * Gets the public 'foo1' shared service. + * + * @return \stdClass + */ + protected function getFoo1Service() + { + return $this->services['foo1'] = new \stdClass(); + } + /** + * Gets the private 'foo3' shared service. + * + * @return \stdClass + */ + protected function getFoo3Service() + { + return $this->services['foo3'] = new \stdClass(); + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Uninitialized_Reference', 'Symfony_DI_PhpDumper_Test_Uninitialized_Reference', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_unsupported_characters.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_unsupported_characters.php index c8eef1298..e41a600db 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_unsupported_characters.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/services_unsupported_characters.php @@ -1,152 +1,152 @@ -parameters = $this->getDefaultParameters(); - $this->services = []; - $this->methodMap = ['bar$' => 'getBarService', 'bar$!' => 'getBar2Service', 'foo*/oh-no' => 'getFooohnoService']; - $this->aliases = []; - } - public function getRemovedIds() - { - return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; - } - public function compile() - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); - } - public function isCompiled() - { - return \true; - } - public function isFrozen() - { - @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); - return \true; - } - /** - * Gets the public 'bar$' shared service. - * - * @return \FooClass - */ - protected function getBarService() - { - return $this->services['bar$'] = new \_PhpScoper5ea00cc67502b\FooClass(); - } - /** - * Gets the public 'bar$!' shared service. - * - * @return \FooClass - */ - protected function getBar2Service() - { - return $this->services['bar$!'] = new \_PhpScoper5ea00cc67502b\FooClass(); - } - /** - * Gets the public 'foo oh-no' shared service. - * - * @return \FooClass - */ - protected function getFooohnoService() - { - return $this->services['foo*/oh-no'] = new \_PhpScoper5ea00cc67502b\FooClass(); - } - public function getParameter($name) - { - $name = (string) $name; - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - $name = $this->normalizeParameterName($name); - if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); - } - } - if (isset($this->loadedDynamicParameters[$name])) { - return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - return $this->parameters[$name]; - } - public function hasParameter($name) - { - $name = (string) $name; - $name = $this->normalizeParameterName($name); - return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); - } - public function setParameter($name, $value) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); - } - public function getParameterBag() - { - if (null === $this->parameterBag) { - $parameters = $this->parameters; - foreach ($this->loadedDynamicParameters as $name => $loaded) { - $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); - } - $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - } - return $this->parameterBag; - } - private $loadedDynamicParameters = []; - private $dynamicParameters = []; - /** - * Computes a dynamic parameter. - * - * @param string $name The name of the dynamic parameter to load - * - * @return mixed The value of the dynamic parameter - * - * @throws InvalidArgumentException When the dynamic parameter does not exist - */ - private function getDynamicParameter($name) - { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); - } - private $normalizedParameterNames = []; - private function normalizeParameterName($name) - { - if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { - $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; - if ((string) $name !== $normalizedName) { - @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); - } - } else { - $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; - } - return $normalizedName; - } - /** - * Gets the default parameters. - * - * @return array An array of the default parameters - */ - protected function getDefaultParameters() - { - return ['\'' => 'oh-no']; - } -} -/** - * This class has been auto-generated - * by the Symfony Dependency Injection Component. - * - * @final since Symfony 3.3 - */ -\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Unsupported_Characters', 'Symfony_DI_PhpDumper_Test_Unsupported_Characters', \false); +parameters = $this->getDefaultParameters(); + $this->services = []; + $this->methodMap = ['bar$' => 'getBarService', 'bar$!' => 'getBar2Service', 'foo*/oh-no' => 'getFooohnoService']; + $this->aliases = []; + } + public function getRemovedIds() + { + return ['_PhpScoper5ea00cc67502b\\Psr\\Container\\ContainerInterface' => \true, '_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface' => \true]; + } + public function compile() + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('You cannot compile a dumped container that was already compiled.'); + } + public function isCompiled() + { + return \true; + } + public function isFrozen() + { + @\trigger_error(\sprintf('The %s() method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the isCompiled() method instead.', __METHOD__), \E_USER_DEPRECATED); + return \true; + } + /** + * Gets the public 'bar$' shared service. + * + * @return \FooClass + */ + protected function getBarService() + { + return $this->services['bar$'] = new \_PhpScoper5ea00cc67502b\FooClass(); + } + /** + * Gets the public 'bar$!' shared service. + * + * @return \FooClass + */ + protected function getBar2Service() + { + return $this->services['bar$!'] = new \_PhpScoper5ea00cc67502b\FooClass(); + } + /** + * Gets the public 'foo oh-no' shared service. + * + * @return \FooClass + */ + protected function getFooohnoService() + { + return $this->services['foo*/oh-no'] = new \_PhpScoper5ea00cc67502b\FooClass(); + } + public function getParameter($name) + { + $name = (string) $name; + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + $name = $this->normalizeParameterName($name); + if (!(isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The parameter "%s" must be defined.', $name)); + } + } + if (isset($this->loadedDynamicParameters[$name])) { + return $this->loadedDynamicParameters[$name] ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + return $this->parameters[$name]; + } + public function hasParameter($name) + { + $name = (string) $name; + $name = $this->normalizeParameterName($name); + return isset($this->parameters[$name]) || isset($this->loadedDynamicParameters[$name]) || \array_key_exists($name, $this->parameters); + } + public function setParameter($name, $value) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\LogicException('Impossible to call set() on a frozen ParameterBag.'); + } + public function getParameterBag() + { + if (null === $this->parameterBag) { + $parameters = $this->parameters; + foreach ($this->loadedDynamicParameters as $name => $loaded) { + $parameters[$name] = $loaded ? $this->dynamicParameters[$name] : $this->getDynamicParameter($name); + } + $this->parameterBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + } + return $this->parameterBag; + } + private $loadedDynamicParameters = []; + private $dynamicParameters = []; + /** + * Computes a dynamic parameter. + * + * @param string $name The name of the dynamic parameter to load + * + * @return mixed The value of the dynamic parameter + * + * @throws InvalidArgumentException When the dynamic parameter does not exist + */ + private function getDynamicParameter($name) + { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException(\sprintf('The dynamic parameter "%s" must be defined.', $name)); + } + private $normalizedParameterNames = []; + private function normalizeParameterName($name) + { + if (isset($this->normalizedParameterNames[$normalizedName = \strtolower($name)]) || isset($this->parameters[$normalizedName]) || \array_key_exists($normalizedName, $this->parameters)) { + $normalizedName = isset($this->normalizedParameterNames[$normalizedName]) ? $this->normalizedParameterNames[$normalizedName] : $normalizedName; + if ((string) $name !== $normalizedName) { + @\trigger_error(\sprintf('Parameter names will be made case sensitive in Symfony 4.0. Using "%s" instead of "%s" is deprecated since Symfony 3.4.', $name, $normalizedName), \E_USER_DEPRECATED); + } + } else { + $normalizedName = $this->normalizedParameterNames[$normalizedName] = (string) $name; + } + return $normalizedName; + } + /** + * Gets the default parameters. + * + * @return array An array of the default parameters + */ + protected function getDefaultParameters() + { + return ['\'' => 'oh-no']; + } +} +/** + * This class has been auto-generated + * by the Symfony Dependency Injection Component. + * + * @final since Symfony 3.3 + */ +\class_alias('_PhpScoper5ea00cc67502b\\Symfony_DI_PhpDumper_Test_Unsupported_Characters', 'Symfony_DI_PhpDumper_Test_Unsupported_Characters', \false); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/php/simple.php b/vendor/symfony/dependency-injection/Tests/Fixtures/php/simple.php index ca28d0d86..db927c95c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/php/simple.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/php/simple.php @@ -1,5 +1,5 @@ -setParameter('foo', 'foo'); +setParameter('foo', 'foo'); diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/class_from_id.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/class_from_id.xml index 2cebcc137..2c843e1b6 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/class_from_id.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/class_from_id.xml @@ -1,6 +1,6 @@ - - - - - - + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/defaults_bindings.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/defaults_bindings.xml index 7d5a691a5..59663d292 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/defaults_bindings.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/defaults_bindings.xml @@ -1,15 +1,15 @@ - - - - - value - - value - - - - - - - - + + + + + value + + value + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/defaults_bindings2.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/defaults_bindings2.xml index e19cec7ab..f9175942c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/defaults_bindings2.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/defaults_bindings2.xml @@ -1,10 +1,10 @@ - - - - - overridden - - - - - + + + + + overridden + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/services.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/services.xml index 1323dd5f2..055aad8f2 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/services.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension1/services.xml @@ -1,14 +1,14 @@ - - - - - - - - - - - - + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/services.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/services.xml index f9c01225d..8154e33c0 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/services.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extension2/services.xml @@ -1,14 +1,14 @@ - - - - - - - - - - - - + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services1.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services1.xml index 792fa0705..01accb9cc 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services1.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services1.xml @@ -1,19 +1,19 @@ - - - - - - BAR - - - - - - - - - %project.parameter.foo% - - - + + + + + + BAR + + + + + + + + + %project.parameter.foo% + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services2.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services2.xml index 65c90696a..f53e32892 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services2.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services2.xml @@ -1,19 +1,19 @@ - - - - - - BAR - - - - - - - - - + + + + + + BAR + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services3.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services3.xml index 4c8184487..418c2bfbc 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services3.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services3.xml @@ -1,19 +1,19 @@ - - - - - - BAR - - - - - - - - - + + + + + + BAR + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services4.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services4.xml index 2c33c3a7d..93dee6999 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services4.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services4.xml @@ -1,6 +1,6 @@ - - - - - + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services5.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services5.xml index c0343373a..70916cc2a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services5.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services5.xml @@ -1,11 +1,11 @@ - - - - - - - + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services6.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services6.xml index da2b4bf2b..8dc91bde5 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services6.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services6.xml @@ -1,11 +1,11 @@ - - - - - - - + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services7.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services7.xml index fa5c364b3..db59f10da 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services7.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/extensions/services7.xml @@ -1,11 +1,11 @@ - - - - - - - + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy_invalid_alias_definition.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy_invalid_alias_definition.xml index a5387b25a..176d2f2e8 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy_invalid_alias_definition.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/legacy_invalid_alias_definition.xml @@ -1,11 +1,11 @@ - - - - - - - - - - - + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/namespaces.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/namespaces.xml index 9dc27fadb..e78d3b577 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/namespaces.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/namespaces.xml @@ -1,17 +1,17 @@ - - - - - - - - - foo - - - - + + + + + + + + + foo + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nested_service_without_id.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nested_service_without_id.xml index cfeed0ff5..40ebd3c73 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nested_service_without_id.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nested_service_without_id.xml @@ -1,10 +1,10 @@ - - - - - - - - - - + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nonvalid.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nonvalid.xml index e7b5bc973..bf0208081 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nonvalid.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/nonvalid.xml @@ -1,3 +1,3 @@ - - - + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services1.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services1.xml index d406c53e7..f5047890c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services1.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services1.xml @@ -1,8 +1,8 @@ - - - - - - - - + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services10.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services10.xml index 921070e1b..95c0a6da6 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services10.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services10.xml @@ -1,16 +1,16 @@ - - - - - - - - - + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services13.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services13.xml index 9d86b8e51..0cbf62079 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services13.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services13.xml @@ -1,9 +1,9 @@ - - - - - true - - + + + + + true + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services14.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services14.xml index f658adadd..b45bb7241 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services14.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services14.xml @@ -1,19 +1,19 @@ - - - - - app - - - - - - app - - - - - - + + + + + app + + + + + + app + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services2.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services2.xml index 243a289f7..235bb98ea 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services2.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services2.xml @@ -1,31 +1,31 @@ - - - - - a string - bar - - 0 - 4 - null - true - true - false - on - off - 1.3 - 1000.3 - a string - - foo - bar - - - - value - - PHP_EOL - - + + + + + a string + bar + + 0 + 4 + null + true + true + false + on + off + 1.3 + 1000.3 + a string + + foo + bar + + + + value + + PHP_EOL + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services21.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services21.xml index 250a684eb..63970e83c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services21.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services21.xml @@ -1,24 +1,24 @@ - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services22.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services22.xml index 6de7945be..6c4eb5c2d 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services22.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services22.xml @@ -1,9 +1,9 @@ - - - - - Bar - Baz - - - + + + + + Bar + Baz + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services23.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services23.xml index eb56fd11d..5783d189a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services23.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services23.xml @@ -1,6 +1,6 @@ - - - - - - + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services24.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services24.xml index c02c71409..3883812f0 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services24.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services24.xml @@ -1,9 +1,9 @@ - - - - - - - - - + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services28.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services28.xml index 6b53c0989..bb1c68b02 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services28.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services28.xml @@ -1,13 +1,13 @@ - - - - - - - - - - - - - + + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services3.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services3.xml index 5f0afeb49..1823b4e53 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services3.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services3.xml @@ -1,13 +1,13 @@ - - - - - foo - - true - false - - - + + + + + foo + + true + false + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4.xml index 399da8159..2b15dd7e2 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4.xml @@ -1,14 +1,14 @@ - - - - - - - - - - - - + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4_bad_import.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4_bad_import.xml index b30178f9e..aaefbfe43 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4_bad_import.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services4_bad_import.xml @@ -1,9 +1,9 @@ - - - - - - - + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services5.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services5.xml index 6c6a14245..de964eefd 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services5.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services5.xml @@ -1,25 +1,25 @@ - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services6.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services6.xml index 84eb57bbe..7b892e7f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services6.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services6.xml @@ -1,69 +1,69 @@ - - - - - - - - - %path%/foo.php - - - foo - - - true - false - - - - - - - - - - - - - - - service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default") - - - - - foo - - - true - false - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + %path%/foo.php + + + foo + + + true + false + + + + + + + + + + + + + + + service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default") + + + + + foo + + + true + false + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services7.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services7.xml index 5b322105b..f598e5c39 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services7.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services7.xml @@ -1,9 +1,9 @@ - - - - - - - + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services8.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services8.xml index bb30cfa0c..7cf150242 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services8.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services8.xml @@ -1,38 +1,38 @@ - - - - - %baz% - bar - foo is %%foo bar - @escapeme - - true - false - null - 0 - 1000.3 - true - false - null - - null - 123 - -123 - true - false - 0b0110 - -1.2E2 - 0xFF - 10100.1 - +10100.1 - -10100.1 - - - - - - - + + + + + %baz% + bar + foo is %%foo bar + @escapeme + + true + false + null + 0 + 1000.3 + true + false + null + + null + 123 + -123 + true + false + 0b0110 + -1.2E2 + 0xFF + 10100.1 + +10100.1 + -10100.1 + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services9.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services9.xml index 0873a0d60..aa1c502e9 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services9.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services9.xml @@ -1,147 +1,147 @@ - - - - BazClass - _PhpScoper5ea00cc67502b\Bar\FooClass - bar - - - - - - - foo - - - foo is %foo% - %foo% - - true - - bar - - - foo is %foo% - %foo% - - - - - - - - - - - - - - foo - - %foo_bar% - - - - - - - %path%foo.php - - - - - - - - - - - - - - service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default") - - - - - - - - - pub - - - - - - - - - - - - - - - - - - - - bar - - - - - - - - - The "%service_id%" service is deprecated. You should stop using it, as it will soon be removed. - - - bar - - - - - - bar - - - - - - - foo - The "%service_id%" service is deprecated. You should stop using it, as it will soon be removed. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + BazClass + _PhpScoper5ea00cc67502b\Bar\FooClass + bar + + + + + + + foo + + + foo is %foo% + %foo% + + true + + bar + + + foo is %foo% + %foo% + + + + + + + + + + + + + + foo + + %foo_bar% + + + + + + + %path%foo.php + + + + + + + + + + + + + + service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default") + + + + + + + + + pub + + + + + + + + + + + + + + + + + + + + bar + + + + + + + + + The "%service_id%" service is deprecated. You should stop using it, as it will soon be removed. + + + bar + + + + + + bar + + + + + + + foo + The "%service_id%" service is deprecated. You should stop using it, as it will soon be removed. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_abstract.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_abstract.xml index 20744a2e8..6329f762f 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_abstract.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_abstract.xml @@ -1,9 +1,9 @@ - - - - - - - - - + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_autoconfigure.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_autoconfigure.xml index 91cfa5f4d..0e153742c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_autoconfigure.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_autoconfigure.xml @@ -1,9 +1,9 @@ - - - - - - - - - + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_autoconfigure_with_parent.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_autoconfigure_with_parent.xml index 97a8facf4..17abd731e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_autoconfigure_with_parent.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_autoconfigure_with_parent.xml @@ -1,7 +1,7 @@ - - - - - - - + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_bindings.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_bindings.xml index 653be87bd..1ddb511e7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_bindings.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_bindings.xml @@ -1,21 +1,21 @@ - - - - - null - quz - factory - - - - - - null - - - - - - - - + + + + + null + quz + factory + + + + + + null + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_defaults_with_parent.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_defaults_with_parent.xml index bb1511898..dc36c5e3c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_defaults_with_parent.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_defaults_with_parent.xml @@ -1,9 +1,9 @@ - - - - - - - - - + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_deprecated.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_deprecated.xml index ae3a0b089..68ffbe400 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_deprecated.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_deprecated.xml @@ -1,11 +1,11 @@ - - - - - - - - The "%service_id%" service is deprecated. - - - + + + + + + + + The "%service_id%" service is deprecated. + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_dump_load.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_dump_load.xml index 02c38cf1c..c97f76055 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_dump_load.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_dump_load.xml @@ -1,11 +1,11 @@ - - - - - - - - - - - + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_inline_not_candidate.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_inline_not_candidate.xml index ca0d5e48f..906cdab9c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_inline_not_candidate.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_inline_not_candidate.xml @@ -1,11 +1,11 @@ - - - - - - - - - - - + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_instanceof.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_instanceof.xml index 9e292fc75..05db86dbf 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_instanceof.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_instanceof.xml @@ -1,12 +1,12 @@ - - - - - - - - - - - - + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_instanceof_with_parent.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_instanceof_with_parent.xml index c2fce5eb2..3c52e3ee2 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_instanceof_with_parent.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_instanceof_with_parent.xml @@ -1,9 +1,9 @@ - - - - - - - - - + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_named_args.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_named_args.xml index 16db48bb8..bc86f58bc 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_named_args.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_named_args.xml @@ -1,12 +1,12 @@ - - - - - ABCD - null - - 123 - - - - + + + + + ABCD + null + + 123 + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_prototype.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_prototype.xml index 834850aad..c0fde84dd 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_prototype.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_prototype.xml @@ -1,6 +1,6 @@ - - - - - - + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_tsantos.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_tsantos.xml index 3fabdb43f..330af4541 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_tsantos.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_tsantos.xml @@ -1,65 +1,65 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - true - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + true + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_without_id.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_without_id.xml index fe65f08f4..c0b36534b 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_without_id.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/services_without_id.xml @@ -1,12 +1,12 @@ - - - - - - - - - - - - + + + + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/tag_with_empty_name.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/tag_with_empty_name.xml index 08e3e78fa..8e18530cc 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/tag_with_empty_name.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/tag_with_empty_name.xml @@ -1,11 +1,11 @@ - - - - - - - - - + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/tag_without_name.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/tag_without_name.xml index 1ff392903..60f211b68 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/tag_without_name.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/tag_without_name.xml @@ -1,11 +1,11 @@ - - - - - - - - - + + + + + + + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/with_key_outside_collection.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/with_key_outside_collection.xml index 1f6d32079..583cbf27e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/with_key_outside_collection.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/with_key_outside_collection.xml @@ -1,9 +1,9 @@ - - - - - foo - bar - - - + + + + + foo + bar + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/withdoctype.xml b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/withdoctype.xml index f217d5bca..ee20be4c0 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/withdoctype.xml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/withdoctype.xml @@ -1,3 +1,3 @@ - - - + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/xml_with_wrong_ext.php b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/xml_with_wrong_ext.php index 135fd0062..c5d106be8 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/xml/xml_with_wrong_ext.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/xml/xml_with_wrong_ext.php @@ -1,10 +1,10 @@ - - - - - from xml - - - + + + + + from xml + + + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services.yml index fe54b8987..dd297b4ff 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services.yml @@ -1,14 +1,14 @@ -imports: - # Ensure the anonymous services count is reset after importing a file - - { resource: anonymous_services_in_instanceof.yml } - -services: - _defaults: - autowire: true - - Foo: - arguments: - - !service - class: Bar - autowire: true - factory: [ !service { class: Quz }, 'constructFoo' ] +imports: + # Ensure the anonymous services count is reset after importing a file + - { resource: anonymous_services_in_instanceof.yml } + +services: + _defaults: + autowire: true + + Foo: + arguments: + - !service + class: Bar + autowire: true + factory: [ !service { class: Quz }, 'constructFoo' ] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_alias.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_alias.yml index 96546b83a..0b6ffef99 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_alias.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_alias.yml @@ -1,7 +1,7 @@ -services: - Bar: ~ - - Foo: - arguments: - - !service - alias: Bar +services: + Bar: ~ + + Foo: + arguments: + - !service + alias: Bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_in_instanceof.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_in_instanceof.yml index ea0bebaf1..e69ad5f42 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_in_instanceof.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_in_instanceof.yml @@ -1,15 +1,15 @@ -services: - _instanceof: - # Ensure previous conditionals aren't applied on anonymous services - Quz: - autowire: true - - DummyInterface: - properties: - foo: !service { class: Anonymous } - - # Ensure next conditionals are not considered as services - Bar: - autowire: true - - Dummy: ~ +services: + _instanceof: + # Ensure previous conditionals aren't applied on anonymous services + Quz: + autowire: true + + DummyInterface: + properties: + foo: !service { class: Anonymous } + + # Ensure next conditionals are not considered as services + Bar: + autowire: true + + Dummy: ~ diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_in_parameters.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_in_parameters.yml index 9d9bea344..7d78c2eee 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_in_parameters.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/anonymous_services_in_parameters.yml @@ -1,2 +1,2 @@ -parameters: - foo: [ !service { } ] +parameters: + foo: [ !service { } ] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_calls.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_calls.yml index 3f34b07eb..e4bf9ffe9 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_calls.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_calls.yml @@ -1,4 +1,4 @@ -services: - method_call1: - class: FooClass - calls: foo +services: + method_call1: + class: FooClass + calls: foo diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_decorates.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_decorates.yml index 79c048a84..0d5dbddb7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_decorates.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_decorates.yml @@ -1,7 +1,7 @@ -services: - foo: - class: stdClass - bar: - class: stdClass - decorates: "@foo" - arguments: ["@bar.inner"] +services: + foo: + class: stdClass + bar: + class: stdClass + decorates: "@foo" + arguments: ["@bar.inner"] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_empty_defaults.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_empty_defaults.yml index 85d910e3e..e7655e024 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_empty_defaults.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_empty_defaults.yml @@ -1,2 +1,2 @@ -services: - _defaults: +services: + _defaults: diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_empty_instanceof.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_empty_instanceof.yml index 2c8ce09ff..e5f5e881a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_empty_instanceof.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_empty_instanceof.yml @@ -1,2 +1,2 @@ -services: - _instanceof: +services: + _instanceof: diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_format.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_format.yml index 1f58cac6a..eaaa6eadf 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_format.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_format.yml @@ -1,2 +1,2 @@ -parameters: - FOO: bar +parameters: + FOO: bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_import.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_import.yml index 2dbbcbf26..411d4d88a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_import.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_import.yml @@ -1,2 +1,2 @@ -imports: - - { resource: ~ } +imports: + - { resource: ~ } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_imports.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_imports.yml index 1ce9d57c6..0d360b9fe 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_imports.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_imports.yml @@ -1,2 +1,2 @@ -imports: - foo:bar +imports: + foo:bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_parameters.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_parameters.yml index bbd13ac0b..5d1cb9889 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_parameters.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_parameters.yml @@ -1,2 +1,2 @@ -parameters: - foo:bar +parameters: + foo:bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_service.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_service.yml index 811af3c0e..b8def556f 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_service.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_service.yml @@ -1,2 +1,2 @@ -services: - foo: bar +services: + foo: bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_services.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_services.yml index cfbf17ce5..99bb47d7a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_services.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_services.yml @@ -1 +1 @@ -services: foo +services: foo diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_types1.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_types1.yml index 891e01497..dced3067b 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_types1.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_types1.yml @@ -1,5 +1,5 @@ -services: - foo_service: - class: FooClass - # types is not an array - autowiring_types: 1 +services: + foo_service: + class: FooClass + # types is not an array + autowiring_types: 1 diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_types2.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_types2.yml index fb1d53e15..49d70be39 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_types2.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bad_types2.yml @@ -1,5 +1,5 @@ -services: - foo_service: - class: FooClass - # autowiring_types is not a string - autowiring_types: [ 1 ] +services: + foo_service: + class: FooClass + # autowiring_types is not a string + autowiring_types: [ 1 ] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag1.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag1.yml index 14536fdb3..ee9172a14 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag1.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag1.yml @@ -1,5 +1,5 @@ -services: - foo_service: - class: FooClass - # tags is not an array - tags: string +services: + foo_service: + class: FooClass + # tags is not an array + tags: string diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag2.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag2.yml index 90288144c..1be58f4cf 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag2.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag2.yml @@ -1,6 +1,6 @@ -services: - foo_service: - class: FooClass - tags: - # tag is missing the name key - foo_tag: { foo: bar } +services: + foo_service: + class: FooClass + tags: + # tag is missing the name key + foo_tag: { foo: bar } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag3.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag3.yml index 72ec4e8f0..c35a63fb2 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag3.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/badtag3.yml @@ -1,6 +1,6 @@ -services: - foo_service: - class: FooClass - tags: - # tag-attribute is not a scalar - - { name: foo, bar: { foo: foo, bar: bar } } +services: + foo_service: + class: FooClass + tags: + # tag-attribute is not a scalar + - { name: foo, bar: { foo: foo, bar: bar } } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/services.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/services.yml index 72ab679bb..9a1c4cf27 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/services.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/bar/services.yml @@ -1,4 +1,4 @@ -services: - _PhpScoper5ea00cc67502b\AppBundle\Foo: - arguments: - - !service {class: _PhpScoper5ea00cc67502b\AppBundle\Bar } +services: + _PhpScoper5ea00cc67502b\AppBundle\Foo: + arguments: + - !service {class: _PhpScoper5ea00cc67502b\AppBundle\Bar } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/class_from_id.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/class_from_id.yml index 79699706f..ff5692a80 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/class_from_id.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/class_from_id.yml @@ -1,3 +1,3 @@ -services: - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass: - autowire: true +services: + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass: + autowire: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/defaults_bindings.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/defaults_bindings.yml index 6e7c11632..8d9d1ea16 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/defaults_bindings.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/defaults_bindings.yml @@ -1,11 +1,11 @@ -services: - _defaults: - bind: - $quz: value - $foo: [value] - - bar: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar - - foo: - class: stdClass +services: + _defaults: + bind: + $quz: value + $foo: [value] + + bar: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar + + foo: + class: stdClass diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/defaults_bindings2.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/defaults_bindings2.yml index 965ed82f5..bc17bdccc 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/defaults_bindings2.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/defaults_bindings2.yml @@ -1,7 +1,7 @@ -services: - _defaults: - bind: - $quz: overridden - - bar: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar +services: + _defaults: + bind: + $quz: overridden + + bar: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/services.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/services.yml index ecee47c48..6f7e3c75f 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/services.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/foo/services.yml @@ -1,4 +1,4 @@ -services: - _PhpScoper5ea00cc67502b\AppBundle\Hello: - arguments: - - !service {class: _PhpScoper5ea00cc67502b\AppBundle\World} +services: + _PhpScoper5ea00cc67502b\AppBundle\Hello: + arguments: + - !service {class: _PhpScoper5ea00cc67502b\AppBundle\World} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/_child.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/_child.yml index e45ce58bc..2a7059b98 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/_child.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/_child.yml @@ -1,4 +1,4 @@ -services: - child_service: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub - parent: parent_service +services: + child_service: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub + parent: parent_service diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/expected.yml index 9f3db39be..0559ebd29 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/expected.yml @@ -1,10 +1,10 @@ -services: - child_service_expected: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub - # the parent has autoconfigure true, but that does not cascade to the child - autoconfigure: false - # an autoconfigured "instanceof" is setup for IntegrationTestStub - # but its calls are NOT added, because the class was only - # set on the parent, not the child - #calls: - # - [enableSummer, [true]] +services: + child_service_expected: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub + # the parent has autoconfigure true, but that does not cascade to the child + autoconfigure: false + # an autoconfigured "instanceof" is setup for IntegrationTestStub + # but its calls are NOT added, because the class was only + # set on the parent, not the child + #calls: + # - [enableSummer, [true]] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/main.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/main.yml index 02533bf0f..ac514385b 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/main.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_child_not_applied/main.yml @@ -1,7 +1,7 @@ -imports: - - { resource: _child.yml } - -services: - parent_service: - autoconfigure: true - abstract: true +imports: + - { resource: _child.yml } + +services: + parent_service: + autoconfigure: true + abstract: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/_child.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/_child.yml index 5319c2045..58df1da7a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/_child.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/_child.yml @@ -1,3 +1,3 @@ -services: - child_service: - parent: parent_service +services: + child_service: + parent: parent_service diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/expected.yml index bc5d22f09..371fe5821 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/expected.yml @@ -1,5 +1,5 @@ -services: - child_service_expected: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub - # autoconfigure is set on the parent, but not on the child - autoconfigure: false +services: + child_service_expected: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub + # autoconfigure is set on the parent, but not on the child + autoconfigure: false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/main.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/main.yml index e7765a382..c93960fea 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/main.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child/main.yml @@ -1,7 +1,7 @@ -imports: - - { resource: _child.yml } - -services: - parent_service: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub - autoconfigure: true +imports: + - { resource: _child.yml } + +services: + parent_service: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub + autoconfigure: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/_child.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/_child.yml index 5319c2045..58df1da7a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/_child.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/_child.yml @@ -1,3 +1,3 @@ -services: - child_service: - parent: parent_service +services: + child_service: + parent: parent_service diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/expected.yml index 805e13965..ebbebe925 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/expected.yml @@ -1,6 +1,6 @@ -services: - child_service_expected: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub - # from an autoconfigured "instanceof" applied to parent class - # but NOT inherited down to child - # tags: [from_autoconfigure] +services: + child_service_expected: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub + # from an autoconfigured "instanceof" applied to parent class + # but NOT inherited down to child + # tags: [from_autoconfigure] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/main.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/main.yml index e7765a382..c93960fea 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/main.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/autoconfigure_parent_child_tags/main.yml @@ -1,7 +1,7 @@ -imports: - - { resource: _child.yml } - -services: - parent_service: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub - autoconfigure: true +imports: + - { resource: _child.yml } + +services: + parent_service: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub + autoconfigure: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/expected.yml index 54cd91c20..a1b6b8dbd 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/expected.yml @@ -1,9 +1,9 @@ -services: - # child_service in the end should be identical to this - child_service_expected: - class: stdClass - autowire: false - public: true - lazy: true - # ONLY the child tag, the parent tag does not inherit - tags: [from_child] +services: + # child_service in the end should be identical to this + child_service_expected: + class: stdClass + autowire: false + public: true + lazy: true + # ONLY the child tag, the parent tag does not inherit + tags: [from_child] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/main.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/main.yml index edaa3a3b4..21b34f799 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/main.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/child_parent/main.yml @@ -1,13 +1,13 @@ -services: - parent_service: - abstract: true - lazy: true - autowire: false - public: false - tags: [from_parent] - - child_service: - class: stdClass - parent: parent_service - public: true - tags: [from_child] +services: + parent_service: + abstract: true + lazy: true + autowire: false + public: false + tags: [from_parent] + + child_service: + class: stdClass + parent: parent_service + public: true + tags: [from_child] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/expected.yml index cb36636e0..93bec221c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/expected.yml @@ -1,8 +1,8 @@ -services: - child_service_expected: - class: stdClass - # set explicitly on child (not overridden by parent) - autoconfigure: false - # set explicitly on child - autowire: true - tags: [from_defaults] +services: + child_service_expected: + class: stdClass + # set explicitly on child (not overridden by parent) + autoconfigure: false + # set explicitly on child + autowire: true + tags: [from_defaults] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/main.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/main.yml index b5dc66ff0..ddf4232cc 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/main.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_child_tags/main.yml @@ -1,18 +1,18 @@ -services: - _defaults: - autoconfigure: true - autowire: true - tags: [from_defaults] - - parent_service: - class: stdClass - # will not override child - autoconfigure: true - # parent definitions are not applied to children - tags: [from_parent] - - child_service: - parent: parent_service - # _defaults is ok because these are explicitly set - autoconfigure: false - autowire: true +services: + _defaults: + autoconfigure: true + autowire: true + tags: [from_defaults] + + parent_service: + class: stdClass + # will not override child + autoconfigure: true + # parent definitions are not applied to children + tags: [from_parent] + + child_service: + parent: parent_service + # _defaults is ok because these are explicitly set + autoconfigure: false + autowire: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/expected.yml index 0d2c1a4ce..962dac256 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/expected.yml @@ -1,26 +1,26 @@ -services: - # main_service should look like this in the end - main_service_expected: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub - # _instanceof overrides _defaults - autowire: false - # inherited from _defaults - autoconfigure: true - # from _instanceof - shared: false - # service definition overrides _instanceof - public: true - - tags: - - { name: foo_tag, tag_option: from_service } - # these 2 are from instanceof - - { name: foo_tag, tag_option: from_instanceof } - - { name: bar_tag } - - { name: from_defaults } - # calls from instanceof are kept, but this comes later - calls: - # first call is from instanceof - - [setSunshine, [bright]] - # - - [enableSummer, [true]] - - [setSunshine, [warm]] +services: + # main_service should look like this in the end + main_service_expected: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub + # _instanceof overrides _defaults + autowire: false + # inherited from _defaults + autoconfigure: true + # from _instanceof + shared: false + # service definition overrides _instanceof + public: true + + tags: + - { name: foo_tag, tag_option: from_service } + # these 2 are from instanceof + - { name: foo_tag, tag_option: from_instanceof } + - { name: bar_tag } + - { name: from_defaults } + # calls from instanceof are kept, but this comes later + calls: + # first call is from instanceof + - [setSunshine, [bright]] + # + - [enableSummer, [true]] + - [setSunshine, [warm]] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/main.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/main.yml index 26c6d71d7..4d5bf597c 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/main.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_instanceof_importance/main.yml @@ -1,30 +1,30 @@ -services: - _defaults: - autowire: true - autoconfigure: true - public: true - tags: [from_defaults] - - _instanceof: - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStubParent: - autowire: false - shared: false - public: false - tags: - - { name: foo_tag, tag_option: from_instanceof } - calls: - - [setSunshine, [bright]] - - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub: - tags: - - { name: bar_tag } - - main_service: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub - public: true - tags: - - { name: foo_tag, tag_option: from_service } - # calls from instanceof are kept, but this comes later - calls: - - [enableSummer, [true]] - - [setSunshine, [warm]] +services: + _defaults: + autowire: true + autoconfigure: true + public: true + tags: [from_defaults] + + _instanceof: + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStubParent: + autowire: false + shared: false + public: false + tags: + - { name: foo_tag, tag_option: from_instanceof } + calls: + - [setSunshine, [bright]] + + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub: + tags: + - { name: bar_tag } + + main_service: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Compiler\IntegrationTestStub + public: true + tags: + - { name: foo_tag, tag_option: from_service } + # calls from instanceof are kept, but this comes later + calls: + - [enableSummer, [true]] + - [setSunshine, [warm]] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/_child.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/_child.yml index 86ef83c26..4c3542182 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/_child.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/_child.yml @@ -1,4 +1,4 @@ -services: - # loaded here to avoid defaults in other file - child_service: - parent: parent_service +services: + # loaded here to avoid defaults in other file + child_service: + parent: parent_service diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/expected.yml index 012672ff8..b5dbb7447 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/expected.yml @@ -1,6 +1,6 @@ -services: - child_service_expected: - class: stdClass - # _defaults is applied to the parent, but autoconfigure: true - # does not cascade to the child - autoconfigure: false +services: + child_service_expected: + class: stdClass + # _defaults is applied to the parent, but autoconfigure: true + # does not cascade to the child + autoconfigure: false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/main.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/main.yml index 8b90b4e98..09074854a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/main.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/defaults_parent_child/main.yml @@ -1,9 +1,9 @@ -imports: - - { resource: _child.yml } - -services: - _defaults: - autoconfigure: true - - parent_service: - class: stdClass +imports: + - { resource: _child.yml } + +services: + _defaults: + autoconfigure: true + + parent_service: + class: stdClass diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/_child.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/_child.yml index 86ef83c26..4c3542182 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/_child.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/_child.yml @@ -1,4 +1,4 @@ -services: - # loaded here to avoid defaults in other file - child_service: - parent: parent_service +services: + # loaded here to avoid defaults in other file + child_service: + parent: parent_service diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/expected.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/expected.yml index 074ed01d0..074a7ae7a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/expected.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/expected.yml @@ -1,7 +1,7 @@ -services: - child_service_expected: - class: stdClass - # applied to _instanceof of parent - autowire: true - # from _instanceof, applies to parent, but does NOT inherit to here - # tags: [from_instanceof] +services: + child_service_expected: + class: stdClass + # applied to _instanceof of parent + autowire: true + # from _instanceof, applies to parent, but does NOT inherit to here + # tags: [from_instanceof] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/index.php b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/index.php +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/main.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/main.yml index 44cf9b004..731adde78 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/main.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/integration/instanceof_parent_child/main.yml @@ -1,11 +1,11 @@ -imports: - - { resource: _child.yml } - -services: - _instanceof: - stdClass: - autowire: true - tags: [from_instanceof] - - parent_service: - class: stdClass +imports: + - { resource: _child.yml } + +services: + _instanceof: + stdClass: + autowire: true + tags: [from_instanceof] + + parent_service: + class: stdClass diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy_invalid_alias_definition.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy_invalid_alias_definition.yml index 00c011c1d..544785b2d 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy_invalid_alias_definition.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy_invalid_alias_definition.yml @@ -1,5 +1,5 @@ -services: - foo: - alias: bar - factory: foo - parent: quz +services: + foo: + alias: bar + factory: foo + parent: quz diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy_invalid_definition.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy_invalid_definition.yml index 8487e854d..33e30f58a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy_invalid_definition.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/legacy_invalid_definition.yml @@ -1,10 +1,10 @@ -services: - # This definition is valid and should not raise any deprecation notice - foo: - class: stdClass - arguments: [ 'foo', 'bar' ] - - # This definition is invalid and must raise a deprecation notice - bar: - class: stdClass - private: true # the "private" keyword is invalid +services: + # This definition is valid and should not raise any deprecation notice + foo: + class: stdClass + arguments: [ 'foo', 'bar' ] + + # This definition is invalid and must raise a deprecation notice + bar: + class: stdClass + private: true # the "private" keyword is invalid diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid1.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid1.yml index 4eddb872b..a41decc82 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid1.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid1.yml @@ -1,2 +1,2 @@ -foo: - bar +foo: + bar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid2.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid2.yml index c508d5366..1fe92a5d8 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid2.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/nonvalid2.yml @@ -1 +1 @@ -false +false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/null_config.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/null_config.yml index e88e12e2f..90f6f12b4 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/null_config.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/null_config.yml @@ -1 +1 @@ -project: ~ +project: ~ diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services1.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services1.yml index 4babfd453..18683f11d 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services1.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services1.yml @@ -1,11 +1,11 @@ -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: - alias: service_container - public: false - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: - alias: service_container - public: false +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: + alias: service_container + public: false + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: + alias: service_container + public: false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services10.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services10.yml index c66084cdb..7252d9fba 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services10.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services10.yml @@ -1,9 +1,9 @@ -parameters: - project.parameter.foo: BAR - -services: - project.service.foo: - class: BAR - -project: - test: '%project.parameter.foo%' +parameters: + project.parameter.foo: BAR + +services: + project.service.foo: + class: BAR + +project: + test: '%project.parameter.foo%' diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services11.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services11.yml index 40126f005..764e2ed2b 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services11.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services11.yml @@ -1 +1 @@ -foobarfoobar: {} +foobarfoobar: {} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services13.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services13.yml index d52d355c2..c8a607681 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services13.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services13.yml @@ -1,3 +1,3 @@ -# used to test imports in XML -parameters: - imported_from_yaml: true +# used to test imports in XML +parameters: + imported_from_yaml: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services14.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services14.yml index 4c188c5fb..cd51803b7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services14.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services14.yml @@ -1,3 +1,3 @@ -services: - factory: { class: FooBarClass, factory: baz:getClass} - factory_with_static_call: { class: FooBarClass, factory: FooBacFactory::createFooBar} +services: + factory: { class: FooBarClass, factory: baz:getClass} + factory_with_static_call: { class: FooBarClass, factory: FooBacFactory::createFooBar} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services2.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services2.yml index e05d69d77..7ddfe689a 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services2.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services2.yml @@ -1,13 +1,13 @@ -parameters: - foo: bar - values: - - true - - false - - 0 - - 1000.3 - - !php/const PHP_INT_MAX - bar: foo - escape: '@@escapeme' - foo_bar: '@foo_bar' - mixedcase: - MixedCaseKey: value +parameters: + foo: bar + values: + - true + - false + - 0 + - 1000.3 + - !php/const PHP_INT_MAX + bar: foo + escape: '@@escapeme' + foo_bar: '@foo_bar' + mixedcase: + MixedCaseKey: value diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services21.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services21.yml index a2617c168..cc3034b4f 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services21.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services21.yml @@ -1,15 +1,15 @@ -services: - manager: - class: UserManager - arguments: - - true - calls: - - method: setLogger - arguments: - - '@logger' - - method: setClass - arguments: - - User - tags: - - name: manager - alias: user +services: + manager: + class: UserManager + arguments: + - true + calls: + - method: setLogger + arguments: + - '@logger' + - method: setClass + arguments: + - User + tags: + - name: manager + alias: user diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services22.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services22.yml index 55d015bae..be112baec 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services22.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services22.yml @@ -1,8 +1,8 @@ -services: - foo_service: - class: FooClass - autowiring_types: [ Foo, Bar ] - - baz_service: - class: Baz - autowiring_types: Foo +services: + foo_service: + class: FooClass + autowiring_types: [ Foo, Bar ] + + baz_service: + class: Baz + autowiring_types: Foo diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services23.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services23.yml index 1984c1771..3ad706dff 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services23.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services23.yml @@ -1,4 +1,4 @@ -services: - bar_service: - class: BarClass - autowire: true +services: + bar_service: + class: BarClass + autowire: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services24.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services24.yml index 747346006..28fd0243e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services24.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services24.yml @@ -1,16 +1,16 @@ - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - foo: - class: Foo - public: true - autowire: true - _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: - alias: service_container - public: false - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: - alias: service_container - public: false + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + foo: + class: Foo + public: true + autowire: true + _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: + alias: service_container + public: false + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: + alias: service_container + public: false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services26.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services26.yml index c0ed445ee..9d6364088 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services26.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services26.yml @@ -1,22 +1,22 @@ -parameters: - project_dir: '/foo/bar' - env(FOO): foo - env(DB): 'sqlite://%%project_dir%%/var/data.db' - bar: '%env(FOO)%' - baz: '%env(int:Baz)%' - json: '%env(json:file:json_file)%' - db_dsn: '%env(resolve:DB)%' - -services: - test: - public: true - class: '%env(FOO)%' - arguments: - - '%env(Bar)%' - - 'foo%bar%baz' - - '%baz%' - bar: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar - public: true - bind: - $quz: '%env(QUZ)%' +parameters: + project_dir: '/foo/bar' + env(FOO): foo + env(DB): 'sqlite://%%project_dir%%/var/data.db' + bar: '%env(FOO)%' + baz: '%env(int:Baz)%' + json: '%env(json:file:json_file)%' + db_dsn: '%env(resolve:DB)%' + +services: + test: + public: true + class: '%env(FOO)%' + arguments: + - '%env(Bar)%' + - 'foo%bar%baz' + - '%baz%' + bar: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar + public: true + bind: + $quz: '%env(QUZ)%' diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services28.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services28.yml index 2ab0aeec6..393451e3d 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services28.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services28.yml @@ -1,34 +1,34 @@ -services: - _defaults: - public: false - autowire: true - tags: - - name: foo - - _PhpScoper5ea00cc67502b\Acme\Foo: ~ - - with_defaults: - class: Foo - - with_null: - class: Foo - public: true - autowire: ~ - - no_defaults: - class: Foo - public: true - autowire: false - tags: [] - - with_defaults_aliased: - alias: with_defaults - - with_defaults_aliased_short: '@with_defaults' - - _PhpScoper5ea00cc67502b\Acme\WithShortCutArgs: [foo] - - child_def: - parent: with_defaults - public: true - autowire: false +services: + _defaults: + public: false + autowire: true + tags: + - name: foo + + _PhpScoper5ea00cc67502b\Acme\Foo: ~ + + with_defaults: + class: Foo + + with_null: + class: Foo + public: true + autowire: ~ + + no_defaults: + class: Foo + public: true + autowire: false + tags: [] + + with_defaults_aliased: + alias: with_defaults + + with_defaults_aliased_short: '@with_defaults' + + _PhpScoper5ea00cc67502b\Acme\WithShortCutArgs: [foo] + + child_def: + parent: with_defaults + public: true + autowire: false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services3.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services3.yml index 0e92cdf50..ad25ee1f2 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services3.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services3.yml @@ -1,5 +1,5 @@ -parameters: - foo: foo - values: - - true - - false +parameters: + foo: foo + values: + - true + - false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services31_invalid_tags.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services31_invalid_tags.yml index 6c7043b90..fe4abefe7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services31_invalid_tags.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services31_invalid_tags.yml @@ -1,6 +1,6 @@ -services: - _defaults: - tags: ['foo'] - - _PhpScoper5ea00cc67502b\Foo\Bar: - tags: invalid +services: + _defaults: + tags: ['foo'] + + _PhpScoper5ea00cc67502b\Foo\Bar: + tags: invalid diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4.yml index 04c6f6f28..0b17e671e 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4.yml @@ -1,8 +1,8 @@ -imports: - - services2.yml - - { resource: services3.yml } - - { resource: "../php/simple.php" } - - { resource: "../ini/parameters.ini", class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader } - - { resource: "../ini/parameters2.ini" } - - { resource: "../xml/services13.xml" } - - { resource: "../xml/xml_with_wrong_ext.php", type: xml } +imports: + - services2.yml + - { resource: services3.yml } + - { resource: "../php/simple.php" } + - { resource: "../ini/parameters.ini", class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader } + - { resource: "../ini/parameters2.ini" } + - { resource: "../xml/services13.xml" } + - { resource: "../xml/xml_with_wrong_ext.php", type: xml } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4_bad_import.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4_bad_import.yml index f7089fc4d..d66c66c45 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4_bad_import.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services4_bad_import.yml @@ -1,2 +1,2 @@ -imports: - - { resource: foo_fake.yml, ignore_errors: true } +imports: + - { resource: foo_fake.yml, ignore_errors: true } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services6.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services6.yml index d8565710f..ab986fcb5 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services6.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services6.yml @@ -1,43 +1,43 @@ -services: - foo: { class: FooClass } - baz: { class: BazClass } - not_shared: { class: FooClass, shared: false } - file: { class: FooClass, file: '%path%/foo.php' } - arguments: { class: FooClass, arguments: [foo, '@foo', [true, false]] } - configurator1: { class: FooClass, configurator: sc_configure } - configurator2: { class: FooClass, configurator: ['@baz', configure] } - configurator3: { class: FooClass, configurator: [BazClass, configureStatic] } - method_call1: - class: FooClass - calls: - - [ setBar, [] ] - - [ setBar ] - - [ setBar, ['@=service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")'] ] - method_call2: - class: FooClass - calls: - - [ setBar, [ foo, '@foo', [true, false] ] ] - request: - class: Request - synthetic: true - lazy: true - decorator_service: - decorates: decorated - decorator_service_with_name: - decorates: decorated - decoration_inner_name: decorated.pif-pouf - decorator_service_with_name_and_priority: - decorates: decorated - decoration_inner_name: decorated.pif-pouf - decoration_priority: 5 - new_factory1: { class: FooBarClass, factory: factory} - new_factory2: { class: FooBarClass, factory: ['@baz', getClass]} - new_factory3: { class: FooBarClass, factory: [BazClass, getInstance]} - new_factory4: { class: BazClass, factory: [~, getInstance]} - _PhpScoper5ea00cc67502b\Acme\WithShortCutArgs: [foo, '@baz'] - alias_for_foo: '@foo' - another_alias_for_foo: - alias: foo - public: false - another_third_alias_for_foo: - alias: foo +services: + foo: { class: FooClass } + baz: { class: BazClass } + not_shared: { class: FooClass, shared: false } + file: { class: FooClass, file: '%path%/foo.php' } + arguments: { class: FooClass, arguments: [foo, '@foo', [true, false]] } + configurator1: { class: FooClass, configurator: sc_configure } + configurator2: { class: FooClass, configurator: ['@baz', configure] } + configurator3: { class: FooClass, configurator: [BazClass, configureStatic] } + method_call1: + class: FooClass + calls: + - [ setBar, [] ] + - [ setBar ] + - [ setBar, ['@=service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")'] ] + method_call2: + class: FooClass + calls: + - [ setBar, [ foo, '@foo', [true, false] ] ] + request: + class: Request + synthetic: true + lazy: true + decorator_service: + decorates: decorated + decorator_service_with_name: + decorates: decorated + decoration_inner_name: decorated.pif-pouf + decorator_service_with_name_and_priority: + decorates: decorated + decoration_inner_name: decorated.pif-pouf + decoration_priority: 5 + new_factory1: { class: FooBarClass, factory: factory} + new_factory2: { class: FooBarClass, factory: ['@baz', getClass]} + new_factory3: { class: FooBarClass, factory: [BazClass, getInstance]} + new_factory4: { class: BazClass, factory: [~, getInstance]} + _PhpScoper5ea00cc67502b\Acme\WithShortCutArgs: [foo, '@baz'] + alias_for_foo: '@foo' + another_alias_for_foo: + alias: foo + public: false + another_third_alias_for_foo: + alias: foo diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services7.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services7.yml index 09064f200..2dcd29f52 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services7.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services7.yml @@ -1,2 +1,2 @@ -services: - foo: { class: BarClass } +services: + foo: { class: BarClass } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services8.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services8.yml index b2b703d80..eddd822db 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services8.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services8.yml @@ -1,29 +1,29 @@ -parameters: - foo: '%baz%' - baz: bar - bar: 'foo is %%foo bar' - escape: '@@escapeme' - values: [true, false, null, 0, 1000.3, 'true', 'false', 'null'] - null string: 'null' - string of digits: '123' - string of digits prefixed with minus character: '-123' - true string: 'true' - false string: 'false' - binary number string: '0b0110' - numeric string: '-1.2E2' - hexadecimal number string: '0xFF' - float string: '10100.1' - positive float string: '+10100.1' - negative float string: '-10100.1' - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: - alias: service_container - public: false - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: - alias: service_container - public: false +parameters: + foo: '%baz%' + baz: bar + bar: 'foo is %%foo bar' + escape: '@@escapeme' + values: [true, false, null, 0, 1000.3, 'true', 'false', 'null'] + null string: 'null' + string of digits: '123' + string of digits prefixed with minus character: '-123' + true string: 'true' + false string: 'false' + binary number string: '0b0110' + numeric string: '-1.2E2' + hexadecimal number string: '0xFF' + float string: '10100.1' + positive float string: '+10100.1' + negative float string: '-10100.1' + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: + alias: service_container + public: false + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: + alias: service_container + public: false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services9.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services9.yml index ace87e96f..9a56490e4 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services9.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services9.yml @@ -1,163 +1,163 @@ -parameters: - baz_class: BazClass - foo_class: _PhpScoper5ea00cc67502b\Bar\FooClass - foo: bar - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - foo: - class: _PhpScoper5ea00cc67502b\Bar\FooClass - tags: - - { name: foo, foo: foo } - - { name: foo, bar: bar, baz: baz } - arguments: [foo, '@foo.baz', { '%foo%': 'foo is %foo%', foobar: '%foo%' }, true, '@service_container'] - properties: { foo: bar, moo: '@foo.baz', qux: { '%foo%': 'foo is %foo%', foobar: '%foo%' } } - calls: - - [setBar, ['@bar']] - - [initialize, { }] - - factory: [_PhpScoper5ea00cc67502b\Bar\FooClass, getInstance] - configurator: sc_configure - public: true - foo.baz: - class: '%baz_class%' - factory: ['%baz_class%', getInstance] - configurator: ['%baz_class%', configureStatic1] - public: true - bar: - class: _PhpScoper5ea00cc67502b\Bar\FooClass - arguments: [foo, '@foo.baz', '%foo_bar%'] - configurator: ['@foo.baz', configure] - public: true - foo_bar: - class: '%foo_class%' - shared: false - arguments: ['@deprecated_service'] - public: true - method_call1: - class: _PhpScoper5ea00cc67502b\Bar\FooClass - file: '%path%foo.php' - calls: - - [setBar, ['@foo']] - - [setBar, ['@?foo2']] - - [setBar, ['@?foo3']] - - [setBar, ['@?foobaz']] - - [setBar, ['@=service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")']] - public: true - - foo_with_inline: - class: Foo - calls: - - [setBar, ['@inlined']] - public: true - - inlined: - class: Bar - public: false - properties: { pub: pub } - calls: - - [setBaz, ['@baz']] - - baz: - class: Baz - calls: - - [setFoo, ['@foo_with_inline']] - public: true - - request: - class: Request - synthetic: true - public: true - configurator_service: - class: ConfClass - public: false - calls: - - [setFoo, ['@baz']] - - configured_service: - class: stdClass - configurator: ['@configurator_service', configureStdClass] - public: true - configurator_service_simple: - class: ConfClass - public: false - arguments: ['bar'] - configured_service_simple: - class: stdClass - configurator: ['@configurator_service_simple', configureStdClass] - public: true - decorated: - class: stdClass - public: true - decorator_service: - class: stdClass - decorates: decorated - public: true - decorator_service_with_name: - class: stdClass - decorates: decorated - decoration_inner_name: decorated.pif-pouf - public: true - deprecated_service: - class: stdClass - deprecated: The "%service_id%" service is deprecated. You should stop using it, as it will soon be removed. - public: true - new_factory: - class: FactoryClass - public: false - properties: { foo: bar } - factory_service: - class: Bar - factory: ['@foo.baz', getInstance] - public: true - new_factory_service: - class: FooBarBaz - properties: { foo: bar } - factory: ['@new_factory', getInstance] - public: true - service_from_static_method: - class: _PhpScoper5ea00cc67502b\Bar\FooClass - factory: [_PhpScoper5ea00cc67502b\Bar\FooClass, getInstance] - public: true - factory_simple: - class: SimpleFactoryClass - deprecated: The "%service_id%" service is deprecated. You should stop using it, as it will soon be removed. - public: false - arguments: ['foo'] - factory_service_simple: - class: Bar - factory: ['@factory_simple', getInstance] - public: true - lazy_context: - class: LazyContext - arguments: [!iterator {'k1': '@foo.baz', 'k2': '@service_container'}, !iterator []] - public: true - lazy_context_ignore_invalid_ref: - class: LazyContext - arguments: [!iterator ['@foo.baz', '@?invalid'], !iterator []] - public: true - tagged_iterator_foo: - class: Bar - tags: - - { name: foo } - public: false - tagged_iterator: - class: Bar - arguments: - - !tagged foo - public: true - _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: - alias: service_container - public: false - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: - alias: service_container - public: false - alias_for_foo: - alias: 'foo' - public: true - alias_for_alias: - alias: 'foo' - public: true +parameters: + baz_class: BazClass + foo_class: _PhpScoper5ea00cc67502b\Bar\FooClass + foo: bar + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + foo: + class: _PhpScoper5ea00cc67502b\Bar\FooClass + tags: + - { name: foo, foo: foo } + - { name: foo, bar: bar, baz: baz } + arguments: [foo, '@foo.baz', { '%foo%': 'foo is %foo%', foobar: '%foo%' }, true, '@service_container'] + properties: { foo: bar, moo: '@foo.baz', qux: { '%foo%': 'foo is %foo%', foobar: '%foo%' } } + calls: + - [setBar, ['@bar']] + - [initialize, { }] + + factory: [_PhpScoper5ea00cc67502b\Bar\FooClass, getInstance] + configurator: sc_configure + public: true + foo.baz: + class: '%baz_class%' + factory: ['%baz_class%', getInstance] + configurator: ['%baz_class%', configureStatic1] + public: true + bar: + class: _PhpScoper5ea00cc67502b\Bar\FooClass + arguments: [foo, '@foo.baz', '%foo_bar%'] + configurator: ['@foo.baz', configure] + public: true + foo_bar: + class: '%foo_class%' + shared: false + arguments: ['@deprecated_service'] + public: true + method_call1: + class: _PhpScoper5ea00cc67502b\Bar\FooClass + file: '%path%foo.php' + calls: + - [setBar, ['@foo']] + - [setBar, ['@?foo2']] + - [setBar, ['@?foo3']] + - [setBar, ['@?foobaz']] + - [setBar, ['@=service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")']] + public: true + + foo_with_inline: + class: Foo + calls: + - [setBar, ['@inlined']] + public: true + + inlined: + class: Bar + public: false + properties: { pub: pub } + calls: + - [setBaz, ['@baz']] + + baz: + class: Baz + calls: + - [setFoo, ['@foo_with_inline']] + public: true + + request: + class: Request + synthetic: true + public: true + configurator_service: + class: ConfClass + public: false + calls: + - [setFoo, ['@baz']] + + configured_service: + class: stdClass + configurator: ['@configurator_service', configureStdClass] + public: true + configurator_service_simple: + class: ConfClass + public: false + arguments: ['bar'] + configured_service_simple: + class: stdClass + configurator: ['@configurator_service_simple', configureStdClass] + public: true + decorated: + class: stdClass + public: true + decorator_service: + class: stdClass + decorates: decorated + public: true + decorator_service_with_name: + class: stdClass + decorates: decorated + decoration_inner_name: decorated.pif-pouf + public: true + deprecated_service: + class: stdClass + deprecated: The "%service_id%" service is deprecated. You should stop using it, as it will soon be removed. + public: true + new_factory: + class: FactoryClass + public: false + properties: { foo: bar } + factory_service: + class: Bar + factory: ['@foo.baz', getInstance] + public: true + new_factory_service: + class: FooBarBaz + properties: { foo: bar } + factory: ['@new_factory', getInstance] + public: true + service_from_static_method: + class: _PhpScoper5ea00cc67502b\Bar\FooClass + factory: [_PhpScoper5ea00cc67502b\Bar\FooClass, getInstance] + public: true + factory_simple: + class: SimpleFactoryClass + deprecated: The "%service_id%" service is deprecated. You should stop using it, as it will soon be removed. + public: false + arguments: ['foo'] + factory_service_simple: + class: Bar + factory: ['@factory_simple', getInstance] + public: true + lazy_context: + class: LazyContext + arguments: [!iterator {'k1': '@foo.baz', 'k2': '@service_container'}, !iterator []] + public: true + lazy_context_ignore_invalid_ref: + class: LazyContext + arguments: [!iterator ['@foo.baz', '@?invalid'], !iterator []] + public: true + tagged_iterator_foo: + class: Bar + tags: + - { name: foo } + public: false + tagged_iterator: + class: Bar + arguments: + - !tagged foo + public: true + _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: + alias: service_container + public: false + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: + alias: service_container + public: false + alias_for_foo: + alias: 'foo' + public: true + alias_for_alias: + alias: 'foo' + public: true diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_adawson.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_adawson.yml index ed716aeec..eecc96996 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_adawson.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_adawson.yml @@ -1,28 +1,28 @@ -services: - _PhpScoper5ea00cc67502b\App\Db: - public: true - properties: - schema: '@_PhpScoper5ea00cc67502b\App\Schema' - - _PhpScoper5ea00cc67502b\App\Bus: - public: true - arguments: ['@_PhpScoper5ea00cc67502b\App\Db'] - properties: - handler1: '@_PhpScoper5ea00cc67502b\App\Handler1' - handler2: '@_PhpScoper5ea00cc67502b\App\Handler2' - - _PhpScoper5ea00cc67502b\App\Handler1: - ['@_PhpScoper5ea00cc67502b\App\Db', '@_PhpScoper5ea00cc67502b\App\Schema', '@_PhpScoper5ea00cc67502b\App\Processor'] - - _PhpScoper5ea00cc67502b\App\Handler2: - ['@_PhpScoper5ea00cc67502b\App\Db', '@_PhpScoper5ea00cc67502b\App\Schema', '@_PhpScoper5ea00cc67502b\App\Processor'] - - _PhpScoper5ea00cc67502b\App\Processor: - ['@_PhpScoper5ea00cc67502b\App\Registry', '@_PhpScoper5ea00cc67502b\App\Db'] - - _PhpScoper5ea00cc67502b\App\Registry: - properties: - processor: ['@_PhpScoper5ea00cc67502b\App\Db', '@_PhpScoper5ea00cc67502b\App\Bus'] - - _PhpScoper5ea00cc67502b\App\Schema: - arguments: ['@_PhpScoper5ea00cc67502b\App\Db'] +services: + _PhpScoper5ea00cc67502b\App\Db: + public: true + properties: + schema: '@_PhpScoper5ea00cc67502b\App\Schema' + + _PhpScoper5ea00cc67502b\App\Bus: + public: true + arguments: ['@_PhpScoper5ea00cc67502b\App\Db'] + properties: + handler1: '@_PhpScoper5ea00cc67502b\App\Handler1' + handler2: '@_PhpScoper5ea00cc67502b\App\Handler2' + + _PhpScoper5ea00cc67502b\App\Handler1: + ['@_PhpScoper5ea00cc67502b\App\Db', '@_PhpScoper5ea00cc67502b\App\Schema', '@_PhpScoper5ea00cc67502b\App\Processor'] + + _PhpScoper5ea00cc67502b\App\Handler2: + ['@_PhpScoper5ea00cc67502b\App\Db', '@_PhpScoper5ea00cc67502b\App\Schema', '@_PhpScoper5ea00cc67502b\App\Processor'] + + _PhpScoper5ea00cc67502b\App\Processor: + ['@_PhpScoper5ea00cc67502b\App\Registry', '@_PhpScoper5ea00cc67502b\App\Db'] + + _PhpScoper5ea00cc67502b\App\Registry: + properties: + processor: ['@_PhpScoper5ea00cc67502b\App\Db', '@_PhpScoper5ea00cc67502b\App\Bus'] + + _PhpScoper5ea00cc67502b\App\Schema: + arguments: ['@_PhpScoper5ea00cc67502b\App\Db'] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_autoconfigure.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_autoconfigure.yml index 809c9f47d..fce57d264 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_autoconfigure.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_autoconfigure.yml @@ -1,9 +1,9 @@ - -services: - _defaults: - autoconfigure: true - - use_defaults_settings: ~ - - override_defaults_settings_to_false: - autoconfigure: false + +services: + _defaults: + autoconfigure: true + + use_defaults_settings: ~ + + override_defaults_settings_to_false: + autoconfigure: false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_autoconfigure_with_parent.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_autoconfigure_with_parent.yml index c6e308019..5d7a26bfb 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_autoconfigure_with_parent.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_autoconfigure_with_parent.yml @@ -1,8 +1,8 @@ -services: - parent_service: - class: stdClass - - child_service: - class: stdClass - autoconfigure: true - parent: parent_service +services: + parent_service: + class: stdClass + + child_service: + class: stdClass + autoconfigure: true + parent: parent_service diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_bindings.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_bindings.yml index bad65fe31..707e9a853 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_bindings.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_bindings.yml @@ -1,16 +1,16 @@ -services: - _defaults: - bind: - NonExistent: ~ - $quz: quz - $factory: factory - - bar: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar - autowire: true - bind: - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface: '@_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar' - $foo: [ ~ ] - - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar: - factory: [ ~, 'create' ] +services: + _defaults: + bind: + NonExistent: ~ + $quz: quz + $factory: factory + + bar: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar + autowire: true + bind: + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface: '@_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar' + $foo: [ ~ ] + + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar: + factory: [ ~, 'create' ] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_configurator_short_syntax.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_configurator_short_syntax.yml index cc5c2be57..7cacec651 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_configurator_short_syntax.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_configurator_short_syntax.yml @@ -1,8 +1,8 @@ -services: - foo_bar: - class: FooBarClass - configurator: foo_bar_configurator:configure - - foo_bar_with_static_call: - class: FooBarClass - configurator: FooBarConfigurator::configureFooBar +services: + foo_bar: + class: FooBarClass + configurator: foo_bar_configurator:configure + + foo_bar_with_static_call: + class: FooBarClass + configurator: FooBarConfigurator::configureFooBar diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_deep_graph.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_deep_graph.yml index d6d58ad43..ec8c28546 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_deep_graph.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_deep_graph.yml @@ -1,24 +1,24 @@ - -services: - foo: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\FooForDeepGraph - public: true - arguments: - - '@bar' - - !service - class: stdClass - properties: - p2: !service - class: stdClass - properties: - p3: !service - class: stdClass - - bar: - class: stdClass - public: true - properties: - p5: !service - class: stdClass - arguments: ['@foo'] - + +services: + foo: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Dumper\FooForDeepGraph + public: true + arguments: + - '@bar' + - !service + class: stdClass + properties: + p2: !service + class: stdClass + properties: + p3: !service + class: stdClass + + bar: + class: stdClass + public: true + properties: + p5: !service + class: stdClass + arguments: ['@foo'] + diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_defaults_with_parent.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_defaults_with_parent.yml index 28dec4ce9..1cf5ac7d4 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_defaults_with_parent.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_defaults_with_parent.yml @@ -1,10 +1,10 @@ -services: - _defaults: - autowire: true - - parent_service: - class: stdClass - - child_service: - class: stdClass - parent: parent_service +services: + _defaults: + autowire: true + + parent_service: + class: stdClass + + child_service: + class: stdClass + parent: parent_service diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_dump_load.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_dump_load.yml index 7669ebf68..ddde00427 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_dump_load.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_dump_load.yml @@ -1,15 +1,15 @@ - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - synthetic: true - foo: - autoconfigure: true - abstract: true - arguments: ['@!bar'] - _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: - alias: service_container - public: false - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: - alias: service_container - public: false + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + synthetic: true + foo: + autoconfigure: true + abstract: true + arguments: ['@!bar'] + _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: + alias: service_container + public: false + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: + alias: service_container + public: false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_inline.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_inline.yml index e68e0335d..dad7dd542 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_inline.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_inline.yml @@ -1,16 +1,16 @@ - -services: - service_container: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface - public: true - synthetic: true - foo: - class: Class1 - public: true - arguments: [!service { class: Class2, arguments: [!service { class: Class2 }] }] - _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: - alias: service_container - public: false - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: - alias: service_container - public: false + +services: + service_container: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface + public: true + synthetic: true + foo: + class: Class1 + public: true + arguments: [!service { class: Class2, arguments: [!service { class: Class2 }] }] + _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface: + alias: service_container + public: false + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface: + alias: service_container + public: false diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_instanceof.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_instanceof.yml index 193529fd0..a372833ce 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_instanceof.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_instanceof.yml @@ -1,11 +1,11 @@ -services: - _instanceof: - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface: - autowire: true - lazy: true - tags: - - { name: foo } - - { name: bar } - - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar: ~ - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface: '@_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar' +services: + _instanceof: + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface: + autowire: true + lazy: true + tags: + - { name: foo } + - { name: bar } + + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar: ~ + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface: '@_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar' diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_instanceof_with_parent.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_instanceof_with_parent.yml index fb21cdf2f..51ca6860d 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_instanceof_with_parent.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_instanceof_with_parent.yml @@ -1,11 +1,11 @@ -services: - _instanceof: - FooInterface: - autowire: true - - parent_service: - class: stdClass - - child_service: - class: stdClass - parent: parent_service +services: + _instanceof: + FooInterface: + autowire: true + + parent_service: + class: stdClass + + child_service: + class: stdClass + parent: parent_service diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_legacy_privates.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_legacy_privates.yml index 0fd20446e..203c727c2 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_legacy_privates.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_legacy_privates.yml @@ -1,27 +1,27 @@ -services: - _defaults: {public: true} - - foo: {class: stdClass, public: false} - - bar: - class: stdClass - arguments: [ '@private_not_inlined' ] - - private: {class: stdClass, public: false} - decorated_private: {class: stdClass} - decorated_private_alias: '@foo' - alias_to_private: '@private' - private_alias: {alias: foo, public: false} - - private_decorator: - class: stdClass - decorates: 'decorated_private' - - private_alias_decorator: - class: stdClass - decorates: 'decorated_private_alias' - - private_not_inlined: {class: stdClass, public: false} - private_not_removed: {class: stdClass, public: false} - - public_child: {parent: private, public: true} +services: + _defaults: {public: true} + + foo: {class: stdClass, public: false} + + bar: + class: stdClass + arguments: [ '@private_not_inlined' ] + + private: {class: stdClass, public: false} + decorated_private: {class: stdClass} + decorated_private_alias: '@foo' + alias_to_private: '@private' + private_alias: {alias: foo, public: false} + + private_decorator: + class: stdClass + decorates: 'decorated_private' + + private_alias_decorator: + class: stdClass + decorates: 'decorated_private_alias' + + private_not_inlined: {class: stdClass, public: false} + private_not_removed: {class: stdClass, public: false} + + public_child: {parent: private, public: true} diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_named_args.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_named_args.yml index e4078ef04..463853825 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_named_args.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_named_args.yml @@ -1,10 +1,10 @@ -services: - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy: { 0: ~, $apiKey: ABCD } - - another_one: - class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy - arguments: - $apiKey: ABCD - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass: ~ - calls: - - ['setApiKey', { $apiKey: '123' }] +services: + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy: { 0: ~, $apiKey: ABCD } + + another_one: + class: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy + arguments: + $apiKey: ABCD + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass: ~ + calls: + - ['setApiKey', { $apiKey: '123' }] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype.yml index caf458ac6..3b6a5c2b7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype.yml @@ -1,4 +1,4 @@ -services: - _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\: - resource: ../Prototype - exclude: '../Prototype/{OtherDir,BadClasses}' +services: + _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\: + resource: ../Prototype + exclude: '../Prototype/{OtherDir,BadClasses}' diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype_namespace.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype_namespace.yml index 003eda3fc..a8e63c502 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype_namespace.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype_namespace.yml @@ -1,10 +1,10 @@ -services: - dir1: - namespace: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\ - resource: ../Prototype/OtherDir/*/Dir1 - tags: [foo] - - dir2: - namespace: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\ - resource: ../Prototype/OtherDir/*/Dir2 - tags: [bar] +services: + dir1: + namespace: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\ + resource: ../Prototype/OtherDir/*/Dir1 + tags: [foo] + + dir2: + namespace: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\ + resource: ../Prototype/OtherDir/*/Dir2 + tags: [bar] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype_namespace_without_resource.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype_namespace_without_resource.yml index 159e3428e..c17bdbaa7 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype_namespace_without_resource.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_prototype_namespace_without_resource.yml @@ -1,4 +1,4 @@ -services: - dir1: - namespace: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\ - tags: [foo] +services: + dir1: + namespace: _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\ + tags: [foo] diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_underscore.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_underscore.yml index 0cdbf9032..164bd63bb 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_underscore.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/services_underscore.yml @@ -1,3 +1,3 @@ -services: - _foo: - class: Foo +services: + _foo: + class: Foo diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_empty_string.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_empty_string.yml index 0ea5f53da..adb111c28 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_empty_string.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_empty_string.yml @@ -1,6 +1,6 @@ -services: - foo_service: - class: FooClass - tags: - # tag name is an empty string - - { name: '', foo: bar } +services: + foo_service: + class: FooClass + tags: + # tag name is an empty string + - { name: '', foo: bar } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_no_string.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_no_string.yml index f24cafd22..4c00d8689 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_no_string.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_no_string.yml @@ -1,6 +1,6 @@ -services: - foo_service: - class: FooClass - tags: - # tag name is not a string - - { name: [], foo: bar } +services: + foo_service: + class: FooClass + tags: + # tag name is not a string + - { name: [], foo: bar } diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_only.yml b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_only.yml index 90180b0bb..1411b6a14 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_only.yml +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/tag_name_only.yml @@ -1,5 +1,5 @@ -services: - foo_service: - class: FooClass - tags: - - foo +services: + foo_service: + class: FooClass + tags: + - foo diff --git a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/yaml_with_wrong_ext.ini b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/yaml_with_wrong_ext.ini index 1395458bf..9846b6595 100644 --- a/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/yaml_with_wrong_ext.ini +++ b/vendor/symfony/dependency-injection/Tests/Fixtures/yaml/yaml_with_wrong_ext.ini @@ -1,2 +1,2 @@ -parameters: - with_wrong_ext: from yaml +parameters: + with_wrong_ext: from yaml diff --git a/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/RealServiceInstantiatorTest.php b/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/RealServiceInstantiatorTest.php index 89823c242..c47e96035 100644 --- a/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/RealServiceInstantiatorTest.php +++ b/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/RealServiceInstantiatorTest.php @@ -1,33 +1,33 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\LazyProxy\Instantiator; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator; -/** - * Tests for {@see \Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator}. - * - * @author Marco Pivetta - */ -class RealServiceInstantiatorTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testInstantiateProxy() - { - $instantiator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator(); - $instance = new \stdClass(); - $container = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface')->getMock(); - $callback = function () use($instance) { - return $instance; - }; - $this->assertSame($instance, $instantiator->instantiateProxy($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), 'foo', $callback)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\LazyProxy\Instantiator; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator; +/** + * Tests for {@see \Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator}. + * + * @author Marco Pivetta + */ +class RealServiceInstantiatorTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testInstantiateProxy() + { + $instantiator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\Instantiator\RealServiceInstantiator(); + $instance = new \stdClass(); + $container = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\ContainerInterface')->getMock(); + $callback = function () use($instance) { + return $instance; + }; + $this->assertSame($instance, $instantiator->instantiateProxy($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), 'foo', $callback)); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/index.php b/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/index.php +++ b/vendor/symfony/dependency-injection/Tests/LazyProxy/Instantiator/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/NullDumperTest.php b/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/NullDumperTest.php index debb1a85f..3a6f94657 100644 --- a/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/NullDumperTest.php +++ b/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/NullDumperTest.php @@ -1,31 +1,31 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\LazyProxy\PhpDumper; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper; -/** - * Tests for {@see \Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper}. - * - * @author Marco Pivetta - */ -class NullDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testNullDumper() - { - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper(); - $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); - $this->assertFalse($dumper->isProxyCandidate($definition)); - $this->assertSame('', $dumper->getProxyFactoryCode($definition, 'foo', '(false)')); - $this->assertSame('', $dumper->getProxyCode($definition)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\LazyProxy\PhpDumper; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper; +/** + * Tests for {@see \Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper}. + * + * @author Marco Pivetta + */ +class NullDumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testNullDumper() + { + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\LazyProxy\PhpDumper\NullDumper(); + $definition = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition('stdClass'); + $this->assertFalse($dumper->isProxyCandidate($definition)); + $this->assertSame('', $dumper->getProxyFactoryCode($definition, 'foo', '(false)')); + $this->assertSame('', $dumper->getProxyCode($definition)); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/index.php b/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/index.php +++ b/vendor/symfony/dependency-injection/Tests/LazyProxy/PhpDumper/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/LazyProxy/index.php b/vendor/symfony/dependency-injection/Tests/LazyProxy/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/LazyProxy/index.php +++ b/vendor/symfony/dependency-injection/Tests/LazyProxy/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/Loader/ClosureLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/ClosureLoaderTest.php index 6e3924c14..c74a40184 100644 --- a/vendor/symfony/dependency-injection/Tests/Loader/ClosureLoaderTest.php +++ b/vendor/symfony/dependency-injection/Tests/Loader/ClosureLoaderTest.php @@ -1,33 +1,33 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader; -class ClosureLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testSupports() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); - $this->assertTrue($loader->supports(function ($container) { - }), '->supports() returns true if the resource is loadable'); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns true if the resource is loadable'); - } - public function testLoad() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); - $loader->load(function ($container) { - $container->setParameter('foo', 'foo'); - }); - $this->assertEquals('foo', $container->getParameter('foo'), '->load() loads a \\Closure resource'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader; +class ClosureLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testSupports() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); + $this->assertTrue($loader->supports(function ($container) { + }), '->supports() returns true if the resource is loadable'); + $this->assertFalse($loader->supports('foo.foo'), '->supports() returns true if the resource is loadable'); + } + public function testLoad() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder()); + $loader->load(function ($container) { + $container->setParameter('foo', 'foo'); + }); + $this->assertEquals('foo', $container->getParameter('foo'), '->load() loads a \\Closure resource'); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/DirectoryLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/DirectoryLoaderTest.php index f04da7e4f..8e1ae7dca 100644 --- a/vendor/symfony/dependency-injection/Tests/Loader/DirectoryLoaderTest.php +++ b/vendor/symfony/dependency-injection/Tests/Loader/DirectoryLoaderTest.php @@ -1,63 +1,63 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\DirectoryLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; -class DirectoryLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - private static $fixturesPath; - private $container; - private $loader; - public static function setUpBeforeClass() - { - self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); - } - protected function setUp() - { - $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath); - $this->container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $this->loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\DirectoryLoader($this->container, $locator); - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($this->container, $locator), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($this->container, $locator), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($this->container, $locator), $this->loader]); - $this->loader->setResolver($resolver); - } - public function testDirectoryCanBeLoadedRecursively() - { - $this->loader->load('directory/'); - $this->assertEquals(['ini' => 'ini', 'yaml' => 'yaml', 'php' => 'php'], $this->container->getParameterBag()->all(), '->load() takes a single directory'); - } - public function testImports() - { - $this->loader->resolve('directory/import/import.yml')->load('directory/import/import.yml'); - $this->assertEquals(['ini' => 'ini', 'yaml' => 'yaml'], $this->container->getParameterBag()->all(), '->load() takes a single file that imports a directory'); - } - public function testExceptionIsRaisedWhenDirectoryDoesNotExist() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('The file "foo" does not exist (in:'); - $this->loader->load('foo/'); - } - public function testSupports() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\DirectoryLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $this->assertTrue($loader->supports('directory/'), '->supports("directory/") returns true'); - $this->assertTrue($loader->supports('directory/', 'directory'), '->supports("directory/", "directory") returns true'); - $this->assertFalse($loader->supports('directory'), '->supports("directory") returns false'); - $this->assertTrue($loader->supports('directory', 'directory'), '->supports("directory", "directory") returns true'); - $this->assertFalse($loader->supports('directory', 'foo'), '->supports("directory", "foo") returns false'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\DirectoryLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; +class DirectoryLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + private static $fixturesPath; + private $container; + private $loader; + public static function setUpBeforeClass() + { + self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); + } + protected function setUp() + { + $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath); + $this->container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $this->loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\DirectoryLoader($this->container, $locator); + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($this->container, $locator), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($this->container, $locator), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($this->container, $locator), $this->loader]); + $this->loader->setResolver($resolver); + } + public function testDirectoryCanBeLoadedRecursively() + { + $this->loader->load('directory/'); + $this->assertEquals(['ini' => 'ini', 'yaml' => 'yaml', 'php' => 'php'], $this->container->getParameterBag()->all(), '->load() takes a single directory'); + } + public function testImports() + { + $this->loader->resolve('directory/import/import.yml')->load('directory/import/import.yml'); + $this->assertEquals(['ini' => 'ini', 'yaml' => 'yaml'], $this->container->getParameterBag()->all(), '->load() takes a single file that imports a directory'); + } + public function testExceptionIsRaisedWhenDirectoryDoesNotExist() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('The file "foo" does not exist (in:'); + $this->loader->load('foo/'); + } + public function testSupports() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\DirectoryLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $this->assertTrue($loader->supports('directory/'), '->supports("directory/") returns true'); + $this->assertTrue($loader->supports('directory/', 'directory'), '->supports("directory/", "directory") returns true'); + $this->assertFalse($loader->supports('directory'), '->supports("directory") returns false'); + $this->assertTrue($loader->supports('directory', 'directory'), '->supports("directory", "directory") returns true'); + $this->assertFalse($loader->supports('directory', 'foo'), '->supports("directory", "foo") returns false'); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/FileLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/FileLoaderTest.php index d853abc5e..965bf1778 100644 --- a/vendor/symfony/dependency-injection/Tests/Loader/FileLoaderTest.php +++ b/vendor/symfony/dependency-injection/Tests/Loader/FileLoaderTest.php @@ -1,143 +1,143 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\BadClasses\MissingParent; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\FooInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\AnotherSub\DeeperBaz; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Baz; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\BarInterface; -class FileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected static $fixturesPath; - public static function setUpBeforeClass() - { - self::$fixturesPath = \realpath(__DIR__ . '/../'); - } - public function testImportWithGlobPattern() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath)); - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/php')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml'))]); - $loader->setResolver($resolver); - $loader->import('{F}ixtures/{xml,yaml}/services2.{yml,xml}'); - $actual = $container->getParameterBag()->all(); - $expected = ['a string', 'foo' => 'bar', 'values' => [0, 'integer' => 4, 100 => null, 'true', \true, \false, 'on', 'off', 'float' => 1.3, 1000.3, 'a string', ['foo', 'bar']], 'mixedcase' => ['MixedCaseKey' => 'value'], 'constant' => \PHP_EOL, 'bar' => '%foo%', 'escape' => '@escapeme', 'foo_bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo_bar')]; - $this->assertEquals(\array_keys($expected), \array_keys($actual), '->load() imports and merges imported files'); - } - public function testRegisterClasses() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('sub_dir', 'Sub'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); - $loader->registerClasses(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\Sub\\', 'Prototype/%sub_dir%/*'); - $this->assertEquals(['service_container', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar::class], \array_keys($container->getDefinitions())); - $this->assertEquals([\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\BarInterface::class], \array_keys($container->getAliases())); - } - public function testRegisterClassesWithExclude() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('other_dir', 'OtherDir'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); - $loader->registerClasses( - new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), - 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\', - 'Prototype/*', - // load everything, except OtherDir/AnotherSub & Foo.php - 'Prototype/{%other_dir%/AnotherSub,Foo.php}' - ); - $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar::class)); - $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Baz::class)); - $this->assertFalse($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)); - $this->assertFalse($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\AnotherSub\DeeperBaz::class)); - $this->assertEquals([\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\BarInterface::class], \array_keys($container->getAliases())); - $loader->registerClasses(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\', 'Prototype/*', 'Prototype/NotExistingDir'); - } - public function testNestedRegisterClasses() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); - $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); - $prototype->setPublic(\true)->setPrivate(\true); - $loader->registerClasses($prototype, 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\', 'Prototype/*'); - $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar::class)); - $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Baz::class)); - $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)); - $this->assertEquals([\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\FooInterface::class], \array_keys($container->getAliases())); - $alias = $container->getAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\FooInterface::class); - $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class, (string) $alias); - $this->assertFalse($alias->isPublic()); - $this->assertFalse($alias->isPrivate()); - } - public function testMissingParentClass() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->setParameter('bad_classes_dir', 'BadClasses'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); - $loader->registerClasses((new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition())->setPublic(\false), 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\BadClasses\\', 'Prototype/%bad_classes_dir%/*'); - $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\BadClasses\MissingParent::class)); - $this->assertRegExp('{Class "?Symfony\\\\Component\\\\DependencyInjection\\\\Tests\\\\Fixtures\\\\Prototype\\\\BadClasses\\\\MissingClass"? not found}', $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\BadClasses\MissingParent::class)->getErrors()[0]); - } - public function testRegisterClassesWithBadPrefix() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/Expected to find class "Symfony\\\\Component\\\\DependencyInjection\\\\Tests\\\\Fixtures\\\\Prototype\\\\Bar" in file ".+" while importing services from resource "Prototype\\/Sub\\/\\*", but it was not found\\! Check the namespace prefix used with the resource/'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); - // the Sub is missing from namespace prefix - $loader->registerClasses(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\', 'Prototype/Sub/*'); - } - /** - * @dataProvider getIncompatibleExcludeTests - */ - public function testRegisterClassesWithIncompatibleExclude($resourcePattern, $excludePattern) - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); - try { - $loader->registerClasses(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\', $resourcePattern, $excludePattern); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException $e) { - $this->assertEquals(\sprintf('Invalid "exclude" pattern when importing classes for "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\": make sure your "exclude" pattern (%s) is a subset of the "resource" pattern (%s).', $excludePattern, $resourcePattern), $e->getMessage()); - } - } - public function getIncompatibleExcludeTests() - { - (yield ['Prototype/*', 'yaml/*', \false]); - (yield ['Prototype/OtherDir/*', 'Prototype/*', \false]); - } -} -class TestFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader -{ - public function load($resource, $type = null) - { - return $resource; - } - public function supports($resource, $type = null) - { - return \false; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface as PsrContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\BadClasses\MissingParent; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\FooInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\AnotherSub\DeeperBaz; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Baz; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\BarInterface; +class FileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected static $fixturesPath; + public static function setUpBeforeClass() + { + self::$fixturesPath = \realpath(__DIR__ . '/../'); + } + public function testImportWithGlobPattern() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath)); + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/php')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml'))]); + $loader->setResolver($resolver); + $loader->import('{F}ixtures/{xml,yaml}/services2.{yml,xml}'); + $actual = $container->getParameterBag()->all(); + $expected = ['a string', 'foo' => 'bar', 'values' => [0, 'integer' => 4, 100 => null, 'true', \true, \false, 'on', 'off', 'float' => 1.3, 1000.3, 'a string', ['foo', 'bar']], 'mixedcase' => ['MixedCaseKey' => 'value'], 'constant' => \PHP_EOL, 'bar' => '%foo%', 'escape' => '@escapeme', 'foo_bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo_bar')]; + $this->assertEquals(\array_keys($expected), \array_keys($actual), '->load() imports and merges imported files'); + } + public function testRegisterClasses() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('sub_dir', 'Sub'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); + $loader->registerClasses(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\Sub\\', 'Prototype/%sub_dir%/*'); + $this->assertEquals(['service_container', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar::class], \array_keys($container->getDefinitions())); + $this->assertEquals([\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\BarInterface::class], \array_keys($container->getAliases())); + } + public function testRegisterClassesWithExclude() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('other_dir', 'OtherDir'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); + $loader->registerClasses( + new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), + 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\', + 'Prototype/*', + // load everything, except OtherDir/AnotherSub & Foo.php + 'Prototype/{%other_dir%/AnotherSub,Foo.php}' + ); + $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar::class)); + $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Baz::class)); + $this->assertFalse($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)); + $this->assertFalse($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\AnotherSub\DeeperBaz::class)); + $this->assertEquals([\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\BarInterface::class], \array_keys($container->getAliases())); + $loader->registerClasses(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\', 'Prototype/*', 'Prototype/NotExistingDir'); + } + public function testNestedRegisterClasses() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); + $prototype = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(); + $prototype->setPublic(\true)->setPrivate(\true); + $loader->registerClasses($prototype, 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\', 'Prototype/*'); + $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar::class)); + $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Baz::class)); + $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class)); + $this->assertEquals([\_PhpScoper5ea00cc67502b\Psr\Container\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\FooInterface::class], \array_keys($container->getAliases())); + $alias = $container->getAlias(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\FooInterface::class); + $this->assertSame(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class, (string) $alias); + $this->assertFalse($alias->isPublic()); + $this->assertFalse($alias->isPrivate()); + } + public function testMissingParentClass() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->setParameter('bad_classes_dir', 'BadClasses'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); + $loader->registerClasses((new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition())->setPublic(\false), 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\BadClasses\\', 'Prototype/%bad_classes_dir%/*'); + $this->assertTrue($container->has(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\BadClasses\MissingParent::class)); + $this->assertRegExp('{Class "?Symfony\\\\Component\\\\DependencyInjection\\\\Tests\\\\Fixtures\\\\Prototype\\\\BadClasses\\\\MissingClass"? not found}', $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\BadClasses\MissingParent::class)->getErrors()[0]); + } + public function testRegisterClassesWithBadPrefix() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/Expected to find class "Symfony\\\\Component\\\\DependencyInjection\\\\Tests\\\\Fixtures\\\\Prototype\\\\Bar" in file ".+" while importing services from resource "Prototype\\/Sub\\/\\*", but it was not found\\! Check the namespace prefix used with the resource/'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); + // the Sub is missing from namespace prefix + $loader->registerClasses(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\', 'Prototype/Sub/*'); + } + /** + * @dataProvider getIncompatibleExcludeTests + */ + public function testRegisterClassesWithIncompatibleExclude($resourcePattern, $excludePattern) + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\TestFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/Fixtures')); + try { + $loader->registerClasses(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Definition(), 'Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\', $resourcePattern, $excludePattern); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\InvalidArgumentException $e) { + $this->assertEquals(\sprintf('Invalid "exclude" pattern when importing classes for "Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\": make sure your "exclude" pattern (%s) is a subset of the "resource" pattern (%s).', $excludePattern, $resourcePattern), $e->getMessage()); + } + } + public function getIncompatibleExcludeTests() + { + (yield ['Prototype/*', 'yaml/*', \false]); + (yield ['Prototype/OtherDir/*', 'Prototype/*', \false]); + } +} +class TestFileLoader extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\FileLoader +{ + public function load($resource, $type = null) + { + return $resource; + } + public function supports($resource, $type = null) + { + return \false; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/GlobFileLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/GlobFileLoaderTest.php index 4651e4007..97c8c768a 100644 --- a/vendor/symfony/dependency-injection/Tests/Loader/GlobFileLoaderTest.php +++ b/vendor/symfony/dependency-injection/Tests/Loader/GlobFileLoaderTest.php @@ -1,38 +1,38 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\GlobFileLoader; -class GlobFileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testSupports() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\GlobFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $this->assertTrue($loader->supports('any-path', 'glob'), '->supports() returns true if the resource has the glob type'); - $this->assertFalse($loader->supports('any-path'), '->supports() returns false if the resource is not of glob type'); - } - public function testLoadAddsTheGlobResourceToTheContainer() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\GlobFileLoaderWithoutImport($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $loader->load(__DIR__ . '/../Fixtures/config/*'); - $this->assertEquals(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource(__DIR__ . '/../Fixtures/config', '/*', \false), $container->getResources()[1]); - } -} -class GlobFileLoaderWithoutImport extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\GlobFileLoader -{ - public function import($resource, $type = null, $ignoreErrors = \false, $sourceResource = null) - { - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\GlobFileLoader; +class GlobFileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testSupports() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\GlobFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $this->assertTrue($loader->supports('any-path', 'glob'), '->supports() returns true if the resource has the glob type'); + $this->assertFalse($loader->supports('any-path'), '->supports() returns false if the resource is not of glob type'); + } + public function testLoadAddsTheGlobResourceToTheContainer() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader\GlobFileLoaderWithoutImport($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $loader->load(__DIR__ . '/../Fixtures/config/*'); + $this->assertEquals(new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource(__DIR__ . '/../Fixtures/config', '/*', \false), $container->getResources()[1]); + } +} +class GlobFileLoaderWithoutImport extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\GlobFileLoader +{ + public function import($resource, $type = null, $ignoreErrors = \false, $sourceResource = null) + { + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/IniFileLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/IniFileLoaderTest.php index c5627b4f1..24101b6a5 100644 --- a/vendor/symfony/dependency-injection/Tests/Loader/IniFileLoaderTest.php +++ b/vendor/symfony/dependency-injection/Tests/Loader/IniFileLoaderTest.php @@ -1,121 +1,121 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; -class IniFileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected $container; - protected $loader; - protected function setUp() - { - $this->container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $this->loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($this->container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(\realpath(__DIR__ . '/../Fixtures/') . '/ini')); - } - public function testIniFileCanBeLoaded() - { - $this->loader->load('parameters.ini'); - $this->assertEquals(['foo' => 'bar', 'bar' => '%foo%'], $this->container->getParameterBag()->all(), '->load() takes a single file name as its first argument'); - } - /** - * @dataProvider getTypeConversions - */ - public function testTypeConversions($key, $value, $supported) - { - $this->loader->load('types.ini'); - $parameters = $this->container->getParameterBag()->all(); - $this->assertSame($value, $parameters[$key], '->load() converts values to PHP types'); - } - /** - * @dataProvider getTypeConversions - * @requires PHP 5.6.1 - * This test illustrates where our conversions differs from INI_SCANNER_TYPED introduced in PHP 5.6.1 - */ - public function testTypeConversionsWithNativePhp($key, $value, $supported) - { - if (\defined('HHVM_VERSION_ID')) { - $this->markTestSkipped(); - } - if (!$supported) { - $this->markTestSkipped(\sprintf('Converting the value "%s" to "%s" is not supported by the IniFileLoader.', $key, $value)); - } - $expected = \parse_ini_file(__DIR__ . '/../Fixtures/ini/types.ini', \true, \INI_SCANNER_TYPED); - $this->assertSame($value, $expected['parameters'][$key], '->load() converts values to PHP types'); - } - public function getTypeConversions() - { - return [ - ['true_comment', \true, \true], - ['true', \true, \true], - ['false', \false, \true], - ['on', \true, \true], - ['off', \false, \true], - ['yes', \true, \true], - ['no', \false, \true], - ['none', \false, \true], - ['null', null, \true], - ['constant', \PHP_VERSION, \true], - ['12', 12, \true], - ['12_string', '12', \true], - ['12_quoted_number', 12, \false], - // INI_SCANNER_RAW removes the double quotes - ['12_comment', 12, \true], - ['12_string_comment', '12', \true], - ['12_quoted_number_comment', 12, \false], - // INI_SCANNER_RAW removes the double quotes - ['-12', -12, \true], - ['1', 1, \true], - ['0', 0, \true], - ['0b0110', \bindec('0b0110'), \false], - // not supported by INI_SCANNER_TYPED - ['11112222333344445555', '1111,2222,3333,4444,5555', \true], - ['0777', 0777, \false], - // not supported by INI_SCANNER_TYPED - ['255', 0xff, \false], - // not supported by INI_SCANNER_TYPED - ['100.0', 100.0, \false], - // not supported by INI_SCANNER_TYPED - ['-120.0', -120.0, \false], - // not supported by INI_SCANNER_TYPED - ['-10100.1', -10100.1, \false], - // not supported by INI_SCANNER_TYPED - ['-10,100.1', '-10,100.1', \true], - ]; - } - public function testExceptionIsRaisedWhenIniFileDoesNotExist() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('The file "foo.ini" does not exist (in:'); - $this->loader->load('foo.ini'); - } - public function testExceptionIsRaisedWhenIniFileCannotBeParsed() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The "nonvalid.ini" file is not valid.'); - @$this->loader->load('nonvalid.ini'); - } - public function testExceptionIsRaisedWhenIniFileIsAlmostValid() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The "almostvalid.ini" file is not valid.'); - @$this->loader->load('almostvalid.ini'); - } - public function testSupports() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $this->assertTrue($loader->supports('foo.ini'), '->supports() returns true if the resource is loadable'); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns false if the resource is not loadable'); - $this->assertTrue($loader->supports('with_wrong_ext.yml', 'ini'), '->supports() returns true if the resource with forced type is loadable'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; +class IniFileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected $container; + protected $loader; + protected function setUp() + { + $this->container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $this->loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($this->container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(\realpath(__DIR__ . '/../Fixtures/') . '/ini')); + } + public function testIniFileCanBeLoaded() + { + $this->loader->load('parameters.ini'); + $this->assertEquals(['foo' => 'bar', 'bar' => '%foo%'], $this->container->getParameterBag()->all(), '->load() takes a single file name as its first argument'); + } + /** + * @dataProvider getTypeConversions + */ + public function testTypeConversions($key, $value, $supported) + { + $this->loader->load('types.ini'); + $parameters = $this->container->getParameterBag()->all(); + $this->assertSame($value, $parameters[$key], '->load() converts values to PHP types'); + } + /** + * @dataProvider getTypeConversions + * @requires PHP 5.6.1 + * This test illustrates where our conversions differs from INI_SCANNER_TYPED introduced in PHP 5.6.1 + */ + public function testTypeConversionsWithNativePhp($key, $value, $supported) + { + if (\defined('HHVM_VERSION_ID')) { + $this->markTestSkipped(); + } + if (!$supported) { + $this->markTestSkipped(\sprintf('Converting the value "%s" to "%s" is not supported by the IniFileLoader.', $key, $value)); + } + $expected = \parse_ini_file(__DIR__ . '/../Fixtures/ini/types.ini', \true, \INI_SCANNER_TYPED); + $this->assertSame($value, $expected['parameters'][$key], '->load() converts values to PHP types'); + } + public function getTypeConversions() + { + return [ + ['true_comment', \true, \true], + ['true', \true, \true], + ['false', \false, \true], + ['on', \true, \true], + ['off', \false, \true], + ['yes', \true, \true], + ['no', \false, \true], + ['none', \false, \true], + ['null', null, \true], + ['constant', \PHP_VERSION, \true], + ['12', 12, \true], + ['12_string', '12', \true], + ['12_quoted_number', 12, \false], + // INI_SCANNER_RAW removes the double quotes + ['12_comment', 12, \true], + ['12_string_comment', '12', \true], + ['12_quoted_number_comment', 12, \false], + // INI_SCANNER_RAW removes the double quotes + ['-12', -12, \true], + ['1', 1, \true], + ['0', 0, \true], + ['0b0110', \bindec('0b0110'), \false], + // not supported by INI_SCANNER_TYPED + ['11112222333344445555', '1111,2222,3333,4444,5555', \true], + ['0777', 0777, \false], + // not supported by INI_SCANNER_TYPED + ['255', 0xff, \false], + // not supported by INI_SCANNER_TYPED + ['100.0', 100.0, \false], + // not supported by INI_SCANNER_TYPED + ['-120.0', -120.0, \false], + // not supported by INI_SCANNER_TYPED + ['-10100.1', -10100.1, \false], + // not supported by INI_SCANNER_TYPED + ['-10,100.1', '-10,100.1', \true], + ]; + } + public function testExceptionIsRaisedWhenIniFileDoesNotExist() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('The file "foo.ini" does not exist (in:'); + $this->loader->load('foo.ini'); + } + public function testExceptionIsRaisedWhenIniFileCannotBeParsed() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The "nonvalid.ini" file is not valid.'); + @$this->loader->load('nonvalid.ini'); + } + public function testExceptionIsRaisedWhenIniFileIsAlmostValid() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The "almostvalid.ini" file is not valid.'); + @$this->loader->load('almostvalid.ini'); + } + public function testSupports() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $this->assertTrue($loader->supports('foo.ini'), '->supports() returns true if the resource is loadable'); + $this->assertFalse($loader->supports('foo.foo'), '->supports() returns false if the resource is not loadable'); + $this->assertTrue($loader->supports('with_wrong_ext.yml', 'ini'), '->supports() returns true if the resource with forced type is loadable'); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/LoaderResolverTest.php b/vendor/symfony/dependency-injection/Tests/Loader/LoaderResolverTest.php index bf97677e0..ee914ba72 100644 --- a/vendor/symfony/dependency-injection/Tests/Loader/LoaderResolverTest.php +++ b/vendor/symfony/dependency-injection/Tests/Loader/LoaderResolverTest.php @@ -1,44 +1,44 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; -class LoaderResolverTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - private static $fixturesPath; - /** @var LoaderResolver */ - private $resolver; - protected function setUp() - { - self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $this->resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/php')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader($container)]); - } - public function provideResourcesToLoad() - { - return [['ini_with_wrong_ext.xml', 'ini', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader::class], ['xml_with_wrong_ext.php', 'xml', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::class], ['php_with_wrong_ext.yml', 'php', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader::class], ['yaml_with_wrong_ext.ini', 'yaml', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader::class]]; - } - /** - * @dataProvider provideResourcesToLoad - */ - public function testResolvesForcedType($resource, $type, $expectedClass) - { - $this->assertInstanceOf($expectedClass, $this->resolver->resolve($resource, $type)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; +class LoaderResolverTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + private static $fixturesPath; + /** @var LoaderResolver */ + private $resolver; + protected function setUp() + { + self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $this->resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/php')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\ClosureLoader($container)]); + } + public function provideResourcesToLoad() + { + return [['ini_with_wrong_ext.xml', 'ini', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader::class], ['xml_with_wrong_ext.php', 'xml', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::class], ['php_with_wrong_ext.yml', 'php', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader::class], ['yaml_with_wrong_ext.ini', 'yaml', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader::class]]; + } + /** + * @dataProvider provideResourcesToLoad + */ + public function testResolvesForcedType($resource, $type, $expectedClass) + { + $this->assertInstanceOf($expectedClass, $this->resolver->resolve($resource, $type)); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/PhpFileLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/PhpFileLoaderTest.php index 23e73983e..4707a2c6d 100644 --- a/vendor/symfony/dependency-injection/Tests/Loader/PhpFileLoaderTest.php +++ b/vendor/symfony/dependency-injection/Tests/Loader/PhpFileLoaderTest.php @@ -1,86 +1,86 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -class PhpFileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testSupports() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $this->assertTrue($loader->supports('foo.php'), '->supports() returns true if the resource is loadable'); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns false if the resource is not loadable'); - $this->assertTrue($loader->supports('with_wrong_ext.yml', 'php'), '->supports() returns true if the resource with forced type is loadable'); - } - public function testLoad() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $loader->load(__DIR__ . '/../Fixtures/php/simple.php'); - $this->assertEquals('foo', $container->getParameter('foo'), '->load() loads a PHP file resource'); - } - public function testConfigServices() - { - $fixtures = \realpath(__DIR__ . '/../Fixtures'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $loader->load($fixtures . '/config/services9.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile($fixtures . '/php/services9_compiled.php', \str_replace(\str_replace('\\', '\\\\', $fixtures . \DIRECTORY_SEPARATOR . 'includes' . \DIRECTORY_SEPARATOR), '%path%', $dumper->dump())); - } - /** - * @dataProvider provideConfig - */ - public function testConfig($file) - { - $fixtures = \realpath(__DIR__ . '/../Fixtures'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $loader->load($fixtures . '/config/' . $file . '.php'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); - $this->assertStringEqualsFile($fixtures . '/config/' . $file . '.expected.yml', $dumper->dump()); - } - public function provideConfig() - { - (yield ['basic']); - (yield ['defaults']); - (yield ['instanceof']); - (yield ['prototype']); - (yield ['child']); - if (\PHP_VERSION_ID >= 70000) { - (yield ['php7']); - } - } - public function testAutoConfigureAndChildDefinitionNotAllowed() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The service "child_service" cannot have a "parent" and also have "autoconfigure". Try disabling autoconfiguration for the service.'); - $fixtures = \realpath(__DIR__ . '/../Fixtures'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $loader->load($fixtures . '/config/services_autoconfigure_with_parent.php'); - $container->compile(); - } - public function testFactoryShortNotationNotAllowed() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Invalid factory "factory:method": the `service:method` notation is not available when using PHP-based DI configuration. Use "[ref(\'factory\'), \'method\']" instead.'); - $fixtures = \realpath(__DIR__ . '/../Fixtures'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $loader->load($fixtures . '/config/factory_short_notation.php'); - $container->compile(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; +class PhpFileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testSupports() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $this->assertTrue($loader->supports('foo.php'), '->supports() returns true if the resource is loadable'); + $this->assertFalse($loader->supports('foo.foo'), '->supports() returns false if the resource is not loadable'); + $this->assertTrue($loader->supports('with_wrong_ext.yml', 'php'), '->supports() returns true if the resource with forced type is loadable'); + } + public function testLoad() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $loader->load(__DIR__ . '/../Fixtures/php/simple.php'); + $this->assertEquals('foo', $container->getParameter('foo'), '->load() loads a PHP file resource'); + } + public function testConfigServices() + { + $fixtures = \realpath(__DIR__ . '/../Fixtures'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $loader->load($fixtures . '/config/services9.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile($fixtures . '/php/services9_compiled.php', \str_replace(\str_replace('\\', '\\\\', $fixtures . \DIRECTORY_SEPARATOR . 'includes' . \DIRECTORY_SEPARATOR), '%path%', $dumper->dump())); + } + /** + * @dataProvider provideConfig + */ + public function testConfig($file) + { + $fixtures = \realpath(__DIR__ . '/../Fixtures'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $loader->load($fixtures . '/config/' . $file . '.php'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\YamlDumper($container); + $this->assertStringEqualsFile($fixtures . '/config/' . $file . '.expected.yml', $dumper->dump()); + } + public function provideConfig() + { + (yield ['basic']); + (yield ['defaults']); + (yield ['instanceof']); + (yield ['prototype']); + (yield ['child']); + if (\PHP_VERSION_ID >= 70000) { + (yield ['php7']); + } + } + public function testAutoConfigureAndChildDefinitionNotAllowed() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The service "child_service" cannot have a "parent" and also have "autoconfigure". Try disabling autoconfiguration for the service.'); + $fixtures = \realpath(__DIR__ . '/../Fixtures'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $loader->load($fixtures . '/config/services_autoconfigure_with_parent.php'); + $container->compile(); + } + public function testFactoryShortNotationNotAllowed() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Invalid factory "factory:method": the `service:method` notation is not available when using PHP-based DI configuration. Use "[ref(\'factory\'), \'method\']" instead.'); + $fixtures = \realpath(__DIR__ . '/../Fixtures'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $loader->load($fixtures . '/config/factory_short_notation.php'); + $container->compile(); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/XmlFileLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/XmlFileLoaderTest.php index 3a6aae5a9..0dd217eb7 100644 --- a/vendor/symfony/dependency-injection/Tests/Loader/XmlFileLoaderTest.php +++ b/vendor/symfony/dependency-injection/Tests/Loader/XmlFileLoaderTest.php @@ -1,634 +1,634 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -class XmlFileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected static $fixturesPath; - public static function setUpBeforeClass() - { - self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); - require_once self::$fixturesPath . '/includes/foo.php'; - require_once self::$fixturesPath . '/includes/ProjectExtension.php'; - require_once self::$fixturesPath . '/includes/ProjectWithXsdExtension.php'; - } - public function testLoad() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')); - try { - $loader->load('foo.xml'); - $this->fail('->load() throws an InvalidArgumentException if the loaded file does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the loaded file does not exist'); - $this->assertStringStartsWith('The file "foo.xml" does not exist (in:', $e->getMessage(), '->load() throws an InvalidArgumentException if the loaded file does not exist'); - } - } - public function testParseFile() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')); - $r = new \ReflectionObject($loader); - $m = $r->getMethod('parseFileToDOM'); - $m->setAccessible(\true); - try { - $m->invoke($loader, self::$fixturesPath . '/ini/parameters.ini'); - $this->fail('->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - $this->assertRegExp(\sprintf('#^Unable to parse file ".+%s": .+.$#', 'parameters.ini'), $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - $e = $e->getPrevious(); - $this->assertInstanceOf('InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - $this->assertStringStartsWith('[ERROR 4] Start tag expected, \'<\' not found (in', $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - } - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - try { - $m->invoke($loader, self::$fixturesPath . '/xml/nonvalid.xml'); - $this->fail('->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); - $this->assertRegExp(\sprintf('#^Unable to parse file ".+%s": .+.$#', 'nonvalid.xml'), $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); - $e = $e->getPrevious(); - $this->assertInstanceOf('InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); - $this->assertStringStartsWith('[ERROR 1845] Element \'nonvalid\': No matching global declaration available for the validation root. (in', $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); - } - $xml = $m->invoke($loader, self::$fixturesPath . '/xml/services1.xml'); - $this->assertInstanceOf('DOMDocument', $xml, '->parseFileToDOM() returns an SimpleXMLElement object'); - } - public function testLoadWithExternalEntitiesDisabled() - { - $disableEntities = \libxml_disable_entity_loader(\true); - $containerBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($containerBuilder, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services2.xml'); - \libxml_disable_entity_loader($disableEntities); - $this->assertGreaterThan(0, $containerBuilder->getParameterBag()->all(), 'Parameters can be read from the config file.'); - } - public function testLoadParameters() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services2.xml'); - $actual = $container->getParameterBag()->all(); - $expected = ['a string', 'foo' => 'bar', 'values' => [0, 'integer' => 4, 100 => null, 'true', \true, \false, 'on', 'off', 'float' => 1.3, 1000.3, 'a string', ['foo', 'bar']], 'mixedcase' => ['MixedCaseKey' => 'value'], 'constant' => \PHP_EOL]; - $this->assertEquals($expected, $actual, '->load() converts XML values to PHP ones'); - } - public function testLoadImports() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yml')), $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml'))]); - $loader->setResolver($resolver); - $loader->load('services4.xml'); - $actual = $container->getParameterBag()->all(); - $expected = ['a string', 'foo' => 'bar', 'values' => [0, 'integer' => 4, 100 => null, 'true', \true, \false, 'on', 'off', 'float' => 1.3, 1000.3, 'a string', ['foo', 'bar']], 'mixedcase' => ['MixedCaseKey' => 'value'], 'constant' => \PHP_EOL, 'bar' => '%foo%', 'imported_from_ini' => \true, 'imported_from_yaml' => \true, 'with_wrong_ext' => 'from yaml']; - $this->assertEquals(\array_keys($expected), \array_keys($actual), '->load() imports and merges imported files'); - $this->assertTrue($actual['imported_from_ini']); - // Bad import throws no exception due to ignore_errors value. - $loader->load('services4_bad_import.xml'); - } - public function testLoadAnonymousServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services5.xml'); - $services = $container->getDefinitions(); - $this->assertCount(7, $services, '->load() attributes unique ids to anonymous services'); - // anonymous service as an argument - $args = $services['foo']->getArguments(); - $this->assertCount(1, $args, '->load() references anonymous services as "normal" ones'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Reference', $args[0], '->load() converts anonymous services to references to "normal" services'); - $this->assertArrayHasKey((string) $args[0], $services, '->load() makes a reference to the created ones'); - $inner = $services[(string) $args[0]]; - $this->assertEquals('BarClass', $inner->getClass(), '->load() uses the same configuration as for the anonymous ones'); - $this->assertFalse($inner->isPublic()); - // inner anonymous services - $args = $inner->getArguments(); - $this->assertCount(1, $args, '->load() references anonymous services as "normal" ones'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Reference', $args[0], '->load() converts anonymous services to references to "normal" services'); - $this->assertArrayHasKey((string) $args[0], $services, '->load() makes a reference to the created ones'); - $inner = $services[(string) $args[0]]; - $this->assertEquals('BazClass', $inner->getClass(), '->load() uses the same configuration as for the anonymous ones'); - $this->assertFalse($inner->isPublic()); - // anonymous service as a property - $properties = $services['foo']->getProperties(); - $property = $properties['p']; - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Reference', $property, '->load() converts anonymous services to references to "normal" services'); - $this->assertArrayHasKey((string) $property, $services, '->load() makes a reference to the created ones'); - $inner = $services[(string) $property]; - $this->assertEquals('BuzClass', $inner->getClass(), '->load() uses the same configuration as for the anonymous ones'); - $this->assertFalse($inner->isPublic()); - // "wild" service - $service = $container->findTaggedServiceIds('biz_tag'); - $this->assertCount(1, $service); - foreach ($service as $id => $tag) { - $service = $container->getDefinition($id); - } - $this->assertEquals('BizClass', $service->getClass(), '->load() uses the same configuration as for the anonymous ones'); - $this->assertTrue($service->isPublic()); - // anonymous services are shared when using decoration definitions - $container->compile(); - $services = $container->getDefinitions(); - $fooArgs = $services['foo']->getArguments(); - $barArgs = $services['bar']->getArguments(); - $this->assertSame($fooArgs[0], $barArgs[0]); - } - /** - * @group legacy - * @expectedDeprecation Top-level anonymous services are deprecated since Symfony 3.4, the "id" attribute will be required in version 4.0 in %sservices_without_id.xml at line 5. - */ - public function testLoadAnonymousServicesWithoutId() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_without_id.xml'); - } - public function testLoadAnonymousNestedServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('nested_service_without_id.xml'); - $this->assertTrue($container->hasDefinition('FooClass')); - $arguments = $container->getDefinition('FooClass')->getArguments(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, \array_shift($arguments)); - } - public function testLoadServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services6.xml'); - $services = $container->getDefinitions(); - $this->assertArrayHasKey('foo', $services, '->load() parses elements'); - $this->assertFalse($services['not_shared']->isShared(), '->load() parses shared flag'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $services['foo'], '->load() converts element to Definition instances'); - $this->assertEquals('FooClass', $services['foo']->getClass(), '->load() parses the class attribute'); - $this->assertEquals('%path%/foo.php', $services['file']->getFile(), '->load() parses the file tag'); - $this->assertEquals(['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), [\true, \false]], $services['arguments']->getArguments(), '->load() parses the argument tags'); - $this->assertEquals('sc_configure', $services['configurator1']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'configure'], $services['configurator2']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals(['BazClass', 'configureStatic'], $services['configurator3']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals([['setBar', []], ['setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')]]], $services['method_call1']->getMethodCalls(), '->load() parses the method_call tag'); - $this->assertEquals([['setBar', ['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), [\true, \false]]]], $services['method_call2']->getMethodCalls(), '->load() parses the method_call tag'); - $this->assertEquals('factory', $services['new_factory1']->getFactory(), '->load() parses the factory tag'); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'getClass'], $services['new_factory2']->getFactory(), '->load() parses the factory tag'); - $this->assertEquals(['BazClass', 'getInstance'], $services['new_factory3']->getFactory(), '->load() parses the factory tag'); - $this->assertSame([null, 'getInstance'], $services['new_factory4']->getFactory(), '->load() accepts factory tag without class'); - $aliases = $container->getAliases(); - $this->assertArrayHasKey('alias_for_foo', $aliases, '->load() parses elements'); - $this->assertEquals('foo', (string) $aliases['alias_for_foo'], '->load() parses aliases'); - $this->assertTrue($aliases['alias_for_foo']->isPublic()); - $this->assertArrayHasKey('another_alias_for_foo', $aliases); - $this->assertEquals('foo', (string) $aliases['another_alias_for_foo']); - $this->assertFalse($aliases['another_alias_for_foo']->isPublic()); - $this->assertEquals(['decorated', null, 0], $services['decorator_service']->getDecoratedService()); - $this->assertEquals(['decorated', 'decorated.pif-pouf', 0], $services['decorator_service_with_name']->getDecoratedService()); - $this->assertEquals(['decorated', 'decorated.pif-pouf', 5], $services['decorator_service_with_name_and_priority']->getDecoratedService()); - } - public function testParsesIteratorArgument() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services9.xml'); - $lazyDefinition = $container->getDefinition('lazy_context'); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['k1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'k2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])], $lazyDefinition->getArguments(), '->load() parses lazy arguments'); - } - public function testParsesTags() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services10.xml'); - $services = $container->findTaggedServiceIds('foo_tag'); - $this->assertCount(1, $services); - foreach ($services as $id => $tagAttributes) { - foreach ($tagAttributes as $attributes) { - $this->assertArrayHasKey('other_option', $attributes); - $this->assertEquals('lorem', $attributes['other_option']); - $this->assertArrayHasKey('other-option', $attributes, 'unnormalized tag attributes should not be removed'); - $this->assertEquals('ciz', $attributes['some_option'], 'no overriding should be done when normalizing'); - $this->assertEquals('cat', $attributes['some-option']); - $this->assertArrayNotHasKey('an_other_option', $attributes, 'normalization should not be done when an underscore is already found'); - } - } - } - public function testParseTagsWithoutNameThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('tag_without_name.xml'); - } - public function testParseTagWithEmptyNameThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/The tag name for service ".+" in .* must be a non-empty string/'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('tag_with_empty_name.xml'); - } - public function testDeprecated() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_deprecated.xml'); - $this->assertTrue($container->getDefinition('foo')->isDeprecated()); - $message = 'The "foo" service is deprecated. You should stop using it, as it will soon be removed.'; - $this->assertSame($message, $container->getDefinition('foo')->getDeprecationMessage('foo')); - $this->assertTrue($container->getDefinition('bar')->isDeprecated()); - $message = 'The "bar" service is deprecated.'; - $this->assertSame($message, $container->getDefinition('bar')->getDeprecationMessage('bar')); - } - public function testConvertDomElementToArray() - { - $doc = new \DOMDocument('1.0'); - $doc->loadXML('bar'); - $this->assertEquals('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); - $doc = new \DOMDocument('1.0'); - $doc->loadXML(''); - $this->assertEquals(['foo' => 'bar'], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); - $doc = new \DOMDocument('1.0'); - $doc->loadXML('bar'); - $this->assertEquals(['foo' => 'bar'], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); - $doc = new \DOMDocument('1.0'); - $doc->loadXML('barbar'); - $this->assertEquals(['foo' => ['value' => 'bar', 'foo' => 'bar']], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); - $doc = new \DOMDocument('1.0'); - $doc->loadXML(''); - $this->assertEquals(['foo' => null], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); - $doc = new \DOMDocument('1.0'); - $doc->loadXML(''); - $this->assertEquals(['foo' => null], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); - $doc = new \DOMDocument('1.0'); - $doc->loadXML(''); - $this->assertEquals(['foo' => [['foo' => 'bar'], ['foo' => 'bar']]], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); - } - public function testExtensions() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectExtension()); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectWithXsdExtension()); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - // extension without an XSD - $loader->load('extensions/services1.xml'); - $container->compile(); - $services = $container->getDefinitions(); - $parameters = $container->getParameterBag()->all(); - $this->assertArrayHasKey('project.service.bar', $services, '->load() parses extension elements'); - $this->assertArrayHasKey('project.parameter.bar', $parameters, '->load() parses extension elements'); - $this->assertEquals('BAR', $services['project.service.foo']->getClass(), '->load() parses extension elements'); - $this->assertEquals('BAR', $parameters['project.parameter.foo'], '->load() parses extension elements'); - // extension with an XSD - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectExtension()); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectWithXsdExtension()); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('extensions/services2.xml'); - $container->compile(); - $services = $container->getDefinitions(); - $parameters = $container->getParameterBag()->all(); - $this->assertArrayHasKey('project.service.bar', $services, '->load() parses extension elements'); - $this->assertArrayHasKey('project.parameter.bar', $parameters, '->load() parses extension elements'); - $this->assertEquals('BAR', $services['project.service.foo']->getClass(), '->load() parses extension elements'); - $this->assertEquals('BAR', $parameters['project.parameter.foo'], '->load() parses extension elements'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectExtension()); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectWithXsdExtension()); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - // extension with an XSD (does not validate) - try { - $loader->load('extensions/services3.xml'); - $this->fail('->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - $this->assertRegExp(\sprintf('#^Unable to parse file ".+%s": .+.$#', 'services3.xml'), $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - $e = $e->getPrevious(); - $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - $this->assertStringContainsString('The attribute \'bar\' is not allowed', $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - } - // non-registered extension - try { - $loader->load('extensions/services4.xml'); - $this->fail('->load() throws an InvalidArgumentException if the tag is not valid'); - } catch (\Exception $e) { - $this->assertInstanceOf('\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the tag is not valid'); - $this->assertStringStartsWith('There is no extension able to load the configuration for "project:bar" (in', $e->getMessage(), '->load() throws an InvalidArgumentException if the tag is not valid'); - } - } - public function testExtensionInPhar() - { - if (\extension_loaded('suhosin') && \false === \strpos(\ini_get('suhosin.executor.include.whitelist'), 'phar')) { - $this->markTestSkipped('To run this test, add "phar" to the "suhosin.executor.include.whitelist" settings in your php.ini file.'); - } - if (\defined('HHVM_VERSION')) { - $this->markTestSkipped('HHVM makes this test conflict with those run in separate processes.'); - } - require_once self::$fixturesPath . '/includes/ProjectWithXsdExtensionInPhar.phar'; - // extension with an XSD in PHAR archive - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectWithXsdExtensionInPhar()); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('extensions/services6.xml'); - // extension with an XSD in PHAR archive (does not validate) - try { - $loader->load('extensions/services7.xml'); - $this->fail('->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - $this->assertRegExp(\sprintf('#^Unable to parse file ".+%s": .+.$#', 'services7.xml'), $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - $e = $e->getPrevious(); - $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - $this->assertStringContainsString('The attribute \'bar\' is not allowed', $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); - } - } - public function testSupports() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $this->assertTrue($loader->supports('foo.xml'), '->supports() returns true if the resource is loadable'); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns false if the resource is not loadable'); - $this->assertTrue($loader->supports('with_wrong_ext.yml', 'xml'), '->supports() returns true if the resource with forced type is loadable'); - } - public function testNoNamingConflictsForAnonymousServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml/extension1')); - $loader1->load('services.xml'); - $services = $container->getDefinitions(); - $this->assertCount(3, $services, '->load() attributes unique ids to anonymous services'); - $loader2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml/extension2')); - $loader2->load('services.xml'); - $services = $container->getDefinitions(); - $this->assertCount(5, $services, '->load() attributes unique ids to anonymous services'); - $services = $container->getDefinitions(); - $args1 = $services['extension1.foo']->getArguments(); - $inner1 = $services[(string) $args1[0]]; - $this->assertEquals('BarClass1', $inner1->getClass(), '->load() uses the same configuration as for the anonymous ones'); - $args2 = $services['extension2.foo']->getArguments(); - $inner2 = $services[(string) $args2[0]]; - $this->assertEquals('BarClass2', $inner2->getClass(), '->load() uses the same configuration as for the anonymous ones'); - } - public function testDocTypeIsNotAllowed() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - // document types are not allowed. - try { - $loader->load('withdoctype.xml'); - $this->fail('->load() throws an InvalidArgumentException if the configuration contains a document type'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration contains a document type'); - $this->assertRegExp(\sprintf('#^Unable to parse file ".+%s": .+.$#', 'withdoctype.xml'), $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration contains a document type'); - $e = $e->getPrevious(); - $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration contains a document type'); - $this->assertSame('Document types are not allowed.', $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration contains a document type'); - } - } - public function testXmlNamespaces() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('namespaces.xml'); - $services = $container->getDefinitions(); - $this->assertArrayHasKey('foo', $services, '->load() parses elements'); - $this->assertCount(1, $services['foo']->getTag('foo.tag'), '->load parses elements'); - $this->assertEquals([['setBar', ['foo']]], $services['foo']->getMethodCalls(), '->load() parses the tag'); - } - public function testLoadIndexedArguments() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services14.xml'); - $this->assertEquals(['index_0' => 'app'], $container->findDefinition('logger')->getArguments()); - } - public function testLoadInlinedServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services21.xml'); - $foo = $container->getDefinition('foo'); - $fooFactory = $foo->getFactory(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $fooFactory[0]); - $this->assertTrue($container->has((string) $fooFactory[0])); - $fooFactoryDefinition = $container->getDefinition((string) $fooFactory[0]); - $this->assertSame('FooFactory', $fooFactoryDefinition->getClass()); - $this->assertSame('createFoo', $fooFactory[1]); - $fooFactoryFactory = $fooFactoryDefinition->getFactory(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $fooFactoryFactory[0]); - $this->assertTrue($container->has((string) $fooFactoryFactory[0])); - $this->assertSame('Foobar', $container->getDefinition((string) $fooFactoryFactory[0])->getClass()); - $this->assertSame('createFooFactory', $fooFactoryFactory[1]); - $fooConfigurator = $foo->getConfigurator(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $fooConfigurator[0]); - $this->assertTrue($container->has((string) $fooConfigurator[0])); - $fooConfiguratorDefinition = $container->getDefinition((string) $fooConfigurator[0]); - $this->assertSame('Bar', $fooConfiguratorDefinition->getClass()); - $this->assertSame('configureFoo', $fooConfigurator[1]); - $barConfigurator = $fooConfiguratorDefinition->getConfigurator(); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $barConfigurator[0]); - $this->assertSame('Baz', $container->getDefinition((string) $barConfigurator[0])->getClass()); - $this->assertSame('configureBar', $barConfigurator[1]); - } - /** - * @group legacy - */ - public function testType() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services22.xml'); - $this->assertEquals(['Bar', 'Baz'], $container->getDefinition('foo')->getAutowiringTypes()); - } - public function testAutowire() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services23.xml'); - $this->assertTrue($container->getDefinition('bar')->isAutowired()); - } - public function testClassFromId() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('class_from_id.xml'); - $container->compile(); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class, $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->getClass()); - } - public function testPrototype() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_prototype.xml'); - $ids = \array_keys($container->getDefinitions()); - \sort($ids); - $this->assertSame([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar::class, 'service_container'], $ids); - $resources = $container->getResources(); - $fixturesDir = \dirname(__DIR__) . \DIRECTORY_SEPARATOR . 'Fixtures' . \DIRECTORY_SEPARATOR; - $resources = \array_map('strval', $resources); - $this->assertContains((string) new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource($fixturesDir . 'xml' . \DIRECTORY_SEPARATOR . 'services_prototype.xml'), $resources); - $this->assertContains((string) new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($fixturesDir . 'Prototype', '/*', \true), $resources); - $this->assertContains('_PhpScoper5ea00cc67502b\\reflection.Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\Foo', $resources); - $this->assertContains('_PhpScoper5ea00cc67502b\\reflection.Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\Sub\\Bar', $resources); - } - /** - * @group legacy - * @expectedDeprecation Using the attribute "class" is deprecated for the service "bar" which is defined as an alias %s. - * @expectedDeprecation Using the element "tag" is deprecated for the service "bar" which is defined as an alias %s. - * @expectedDeprecation Using the element "factory" is deprecated for the service "bar" which is defined as an alias %s. - */ - public function testAliasDefinitionContainsUnsupportedElements() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('legacy_invalid_alias_definition.xml'); - $this->assertTrue($container->has('bar')); - } - public function testArgumentWithKeyOutsideCollection() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('with_key_outside_collection.xml'); - $this->assertSame(['type' => 'foo', 'bar'], $container->getDefinition('foo')->getArguments()); - } - public function testDefaults() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services28.xml'); - $this->assertFalse($container->getDefinition('with_defaults')->isPublic()); - $this->assertSame(['foo' => [[]]], $container->getDefinition('with_defaults')->getTags()); - $this->assertTrue($container->getDefinition('with_defaults')->isAutowired()); - $this->assertArrayNotHasKey('public', $container->getDefinition('with_defaults')->getChanges()); - $this->assertArrayNotHasKey('autowire', $container->getDefinition('with_defaults')->getChanges()); - $container->compile(); - $this->assertTrue($container->getDefinition('no_defaults')->isPublic()); - $this->assertSame(['foo' => [[]]], $container->getDefinition('no_defaults')->getTags()); - $this->assertFalse($container->getDefinition('no_defaults')->isAutowired()); - $this->assertTrue($container->getDefinition('child_def')->isPublic()); - $this->assertSame(['foo' => [[]]], $container->getDefinition('child_def')->getTags()); - $this->assertFalse($container->getDefinition('child_def')->isAutowired()); - $definitions = $container->getDefinitions(); - $this->assertSame('service_container', \key($definitions)); - \array_shift($definitions); - $anonymous = \current($definitions); - $this->assertSame('bar', \key($definitions)); - $this->assertTrue($anonymous->isPublic()); - $this->assertTrue($anonymous->isAutowired()); - $this->assertSame(['foo' => [[]]], $anonymous->getTags()); - } - public function testNamedArguments() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_named_args.xml'); - $this->assertEquals(['$apiKey' => 'ABCD', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => null], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getArguments()); - $container->compile(); - $this->assertEquals([null, 'ABCD'], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getArguments()); - $this->assertEquals([['setApiKey', ['123']]], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getMethodCalls()); - } - public function testInstanceof() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_instanceof.xml'); - $container->compile(); - $definition = $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class); - $this->assertTrue($definition->isAutowired()); - $this->assertTrue($definition->isLazy()); - $this->assertSame(['foo' => [[]], 'bar' => [[]]], $definition->getTags()); - } - public function testInstanceOfAndChildDefinitionNotAllowed() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The service "child_service" cannot use the "parent" option in the same file where "instanceof" configuration is defined as using both is not supported. Move your child definitions to a separate file.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_instanceof_with_parent.xml'); - $container->compile(); - } - public function testAutoConfigureAndChildDefinitionNotAllowed() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The service "child_service" cannot have a "parent" and also have "autoconfigure". Try setting autoconfigure="false" for the service.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_autoconfigure_with_parent.xml'); - $container->compile(); - } - public function testDefaultsAndChildDefinitionNotAllowed() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Attribute "autowire" on service "child_service" cannot be inherited from "defaults" when a "parent" is set. Move your child definitions to a separate file or define this attribute explicitly.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_defaults_with_parent.xml'); - $container->compile(); - } - public function testAutoConfigureInstanceof() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_autoconfigure.xml'); - $this->assertTrue($container->getDefinition('use_defaults_settings')->isAutoconfigured()); - $this->assertFalse($container->getDefinition('override_defaults_settings_to_false')->isAutoconfigured()); - } - public function testBindings() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_bindings.xml'); - $container->compile(); - $definition = $container->getDefinition('bar'); - $this->assertEquals(['NonExistent' => null, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class), '$foo' => [null], '$quz' => 'quz', '$factory' => 'factory'], \array_map(function ($v) { - return $v->getValues()[0]; - }, $definition->getBindings())); - $this->assertEquals(['quz', null, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class), [null]], $definition->getArguments()); - $definition = $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class); - $this->assertEquals([null, 'factory'], $definition->getArguments()); - $this->assertEquals(['NonExistent' => null, '$quz' => 'quz', '$factory' => 'factory'], \array_map(function ($v) { - return $v->getValues()[0]; - }, $definition->getBindings())); - } - public function testTsantosContainer() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('services_tsantos.xml'); - $container->compile(); - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); - $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_tsantos.php', $dumper->dump()); - } - /** - * The pass may throw an exception, which will cause the test to fail. - */ - public function testOverriddenDefaultsBindings() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); - $loader->load('defaults_bindings.xml'); - $loader->load('defaults_bindings2.xml'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass())->process($container); - $this->assertSame('overridden', $container->get('bar')->quz); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +class XmlFileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected static $fixturesPath; + public static function setUpBeforeClass() + { + self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); + require_once self::$fixturesPath . '/includes/foo.php'; + require_once self::$fixturesPath . '/includes/ProjectExtension.php'; + require_once self::$fixturesPath . '/includes/ProjectWithXsdExtension.php'; + } + public function testLoad() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')); + try { + $loader->load('foo.xml'); + $this->fail('->load() throws an InvalidArgumentException if the loaded file does not exist'); + } catch (\Exception $e) { + $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the loaded file does not exist'); + $this->assertStringStartsWith('The file "foo.xml" does not exist (in:', $e->getMessage(), '->load() throws an InvalidArgumentException if the loaded file does not exist'); + } + } + public function testParseFile() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')); + $r = new \ReflectionObject($loader); + $m = $r->getMethod('parseFileToDOM'); + $m->setAccessible(\true); + try { + $m->invoke($loader, self::$fixturesPath . '/ini/parameters.ini'); + $this->fail('->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); + $this->assertRegExp(\sprintf('#^Unable to parse file ".+%s": .+.$#', 'parameters.ini'), $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); + $e = $e->getPrevious(); + $this->assertInstanceOf('InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); + $this->assertStringStartsWith('[ERROR 4] Start tag expected, \'<\' not found (in', $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); + } + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + try { + $m->invoke($loader, self::$fixturesPath . '/xml/nonvalid.xml'); + $this->fail('->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); + $this->assertRegExp(\sprintf('#^Unable to parse file ".+%s": .+.$#', 'nonvalid.xml'), $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file is not a valid XML file'); + $e = $e->getPrevious(); + $this->assertInstanceOf('InvalidArgumentException', $e, '->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); + $this->assertStringStartsWith('[ERROR 1845] Element \'nonvalid\': No matching global declaration available for the validation root. (in', $e->getMessage(), '->parseFileToDOM() throws an InvalidArgumentException if the loaded file does not validate the XSD'); + } + $xml = $m->invoke($loader, self::$fixturesPath . '/xml/services1.xml'); + $this->assertInstanceOf('DOMDocument', $xml, '->parseFileToDOM() returns an SimpleXMLElement object'); + } + public function testLoadWithExternalEntitiesDisabled() + { + $disableEntities = \libxml_disable_entity_loader(\true); + $containerBuilder = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($containerBuilder, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services2.xml'); + \libxml_disable_entity_loader($disableEntities); + $this->assertGreaterThan(0, $containerBuilder->getParameterBag()->all(), 'Parameters can be read from the config file.'); + } + public function testLoadParameters() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services2.xml'); + $actual = $container->getParameterBag()->all(); + $expected = ['a string', 'foo' => 'bar', 'values' => [0, 'integer' => 4, 100 => null, 'true', \true, \false, 'on', 'off', 'float' => 1.3, 1000.3, 'a string', ['foo', 'bar']], 'mixedcase' => ['MixedCaseKey' => 'value'], 'constant' => \PHP_EOL]; + $this->assertEquals($expected, $actual, '->load() converts XML values to PHP ones'); + } + public function testLoadImports() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yml')), $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml'))]); + $loader->setResolver($resolver); + $loader->load('services4.xml'); + $actual = $container->getParameterBag()->all(); + $expected = ['a string', 'foo' => 'bar', 'values' => [0, 'integer' => 4, 100 => null, 'true', \true, \false, 'on', 'off', 'float' => 1.3, 1000.3, 'a string', ['foo', 'bar']], 'mixedcase' => ['MixedCaseKey' => 'value'], 'constant' => \PHP_EOL, 'bar' => '%foo%', 'imported_from_ini' => \true, 'imported_from_yaml' => \true, 'with_wrong_ext' => 'from yaml']; + $this->assertEquals(\array_keys($expected), \array_keys($actual), '->load() imports and merges imported files'); + $this->assertTrue($actual['imported_from_ini']); + // Bad import throws no exception due to ignore_errors value. + $loader->load('services4_bad_import.xml'); + } + public function testLoadAnonymousServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services5.xml'); + $services = $container->getDefinitions(); + $this->assertCount(7, $services, '->load() attributes unique ids to anonymous services'); + // anonymous service as an argument + $args = $services['foo']->getArguments(); + $this->assertCount(1, $args, '->load() references anonymous services as "normal" ones'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Reference', $args[0], '->load() converts anonymous services to references to "normal" services'); + $this->assertArrayHasKey((string) $args[0], $services, '->load() makes a reference to the created ones'); + $inner = $services[(string) $args[0]]; + $this->assertEquals('BarClass', $inner->getClass(), '->load() uses the same configuration as for the anonymous ones'); + $this->assertFalse($inner->isPublic()); + // inner anonymous services + $args = $inner->getArguments(); + $this->assertCount(1, $args, '->load() references anonymous services as "normal" ones'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Reference', $args[0], '->load() converts anonymous services to references to "normal" services'); + $this->assertArrayHasKey((string) $args[0], $services, '->load() makes a reference to the created ones'); + $inner = $services[(string) $args[0]]; + $this->assertEquals('BazClass', $inner->getClass(), '->load() uses the same configuration as for the anonymous ones'); + $this->assertFalse($inner->isPublic()); + // anonymous service as a property + $properties = $services['foo']->getProperties(); + $property = $properties['p']; + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Reference', $property, '->load() converts anonymous services to references to "normal" services'); + $this->assertArrayHasKey((string) $property, $services, '->load() makes a reference to the created ones'); + $inner = $services[(string) $property]; + $this->assertEquals('BuzClass', $inner->getClass(), '->load() uses the same configuration as for the anonymous ones'); + $this->assertFalse($inner->isPublic()); + // "wild" service + $service = $container->findTaggedServiceIds('biz_tag'); + $this->assertCount(1, $service); + foreach ($service as $id => $tag) { + $service = $container->getDefinition($id); + } + $this->assertEquals('BizClass', $service->getClass(), '->load() uses the same configuration as for the anonymous ones'); + $this->assertTrue($service->isPublic()); + // anonymous services are shared when using decoration definitions + $container->compile(); + $services = $container->getDefinitions(); + $fooArgs = $services['foo']->getArguments(); + $barArgs = $services['bar']->getArguments(); + $this->assertSame($fooArgs[0], $barArgs[0]); + } + /** + * @group legacy + * @expectedDeprecation Top-level anonymous services are deprecated since Symfony 3.4, the "id" attribute will be required in version 4.0 in %sservices_without_id.xml at line 5. + */ + public function testLoadAnonymousServicesWithoutId() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_without_id.xml'); + } + public function testLoadAnonymousNestedServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('nested_service_without_id.xml'); + $this->assertTrue($container->hasDefinition('FooClass')); + $arguments = $container->getDefinition('FooClass')->getArguments(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, \array_shift($arguments)); + } + public function testLoadServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services6.xml'); + $services = $container->getDefinitions(); + $this->assertArrayHasKey('foo', $services, '->load() parses elements'); + $this->assertFalse($services['not_shared']->isShared(), '->load() parses shared flag'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $services['foo'], '->load() converts element to Definition instances'); + $this->assertEquals('FooClass', $services['foo']->getClass(), '->load() parses the class attribute'); + $this->assertEquals('%path%/foo.php', $services['file']->getFile(), '->load() parses the file tag'); + $this->assertEquals(['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), [\true, \false]], $services['arguments']->getArguments(), '->load() parses the argument tags'); + $this->assertEquals('sc_configure', $services['configurator1']->getConfigurator(), '->load() parses the configurator tag'); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'configure'], $services['configurator2']->getConfigurator(), '->load() parses the configurator tag'); + $this->assertEquals(['BazClass', 'configureStatic'], $services['configurator3']->getConfigurator(), '->load() parses the configurator tag'); + $this->assertEquals([['setBar', []], ['setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')]]], $services['method_call1']->getMethodCalls(), '->load() parses the method_call tag'); + $this->assertEquals([['setBar', ['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), [\true, \false]]]], $services['method_call2']->getMethodCalls(), '->load() parses the method_call tag'); + $this->assertEquals('factory', $services['new_factory1']->getFactory(), '->load() parses the factory tag'); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'getClass'], $services['new_factory2']->getFactory(), '->load() parses the factory tag'); + $this->assertEquals(['BazClass', 'getInstance'], $services['new_factory3']->getFactory(), '->load() parses the factory tag'); + $this->assertSame([null, 'getInstance'], $services['new_factory4']->getFactory(), '->load() accepts factory tag without class'); + $aliases = $container->getAliases(); + $this->assertArrayHasKey('alias_for_foo', $aliases, '->load() parses elements'); + $this->assertEquals('foo', (string) $aliases['alias_for_foo'], '->load() parses aliases'); + $this->assertTrue($aliases['alias_for_foo']->isPublic()); + $this->assertArrayHasKey('another_alias_for_foo', $aliases); + $this->assertEquals('foo', (string) $aliases['another_alias_for_foo']); + $this->assertFalse($aliases['another_alias_for_foo']->isPublic()); + $this->assertEquals(['decorated', null, 0], $services['decorator_service']->getDecoratedService()); + $this->assertEquals(['decorated', 'decorated.pif-pouf', 0], $services['decorator_service_with_name']->getDecoratedService()); + $this->assertEquals(['decorated', 'decorated.pif-pouf', 5], $services['decorator_service_with_name_and_priority']->getDecoratedService()); + } + public function testParsesIteratorArgument() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services9.xml'); + $lazyDefinition = $container->getDefinition('lazy_context'); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['k1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'k2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])], $lazyDefinition->getArguments(), '->load() parses lazy arguments'); + } + public function testParsesTags() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services10.xml'); + $services = $container->findTaggedServiceIds('foo_tag'); + $this->assertCount(1, $services); + foreach ($services as $id => $tagAttributes) { + foreach ($tagAttributes as $attributes) { + $this->assertArrayHasKey('other_option', $attributes); + $this->assertEquals('lorem', $attributes['other_option']); + $this->assertArrayHasKey('other-option', $attributes, 'unnormalized tag attributes should not be removed'); + $this->assertEquals('ciz', $attributes['some_option'], 'no overriding should be done when normalizing'); + $this->assertEquals('cat', $attributes['some-option']); + $this->assertArrayNotHasKey('an_other_option', $attributes, 'normalization should not be done when an underscore is already found'); + } + } + } + public function testParseTagsWithoutNameThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('tag_without_name.xml'); + } + public function testParseTagWithEmptyNameThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/The tag name for service ".+" in .* must be a non-empty string/'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('tag_with_empty_name.xml'); + } + public function testDeprecated() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_deprecated.xml'); + $this->assertTrue($container->getDefinition('foo')->isDeprecated()); + $message = 'The "foo" service is deprecated. You should stop using it, as it will soon be removed.'; + $this->assertSame($message, $container->getDefinition('foo')->getDeprecationMessage('foo')); + $this->assertTrue($container->getDefinition('bar')->isDeprecated()); + $message = 'The "bar" service is deprecated.'; + $this->assertSame($message, $container->getDefinition('bar')->getDeprecationMessage('bar')); + } + public function testConvertDomElementToArray() + { + $doc = new \DOMDocument('1.0'); + $doc->loadXML('bar'); + $this->assertEquals('bar', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); + $doc = new \DOMDocument('1.0'); + $doc->loadXML(''); + $this->assertEquals(['foo' => 'bar'], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); + $doc = new \DOMDocument('1.0'); + $doc->loadXML('bar'); + $this->assertEquals(['foo' => 'bar'], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); + $doc = new \DOMDocument('1.0'); + $doc->loadXML('barbar'); + $this->assertEquals(['foo' => ['value' => 'bar', 'foo' => 'bar']], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); + $doc = new \DOMDocument('1.0'); + $doc->loadXML(''); + $this->assertEquals(['foo' => null], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); + $doc = new \DOMDocument('1.0'); + $doc->loadXML(''); + $this->assertEquals(['foo' => null], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); + $doc = new \DOMDocument('1.0'); + $doc->loadXML(''); + $this->assertEquals(['foo' => [['foo' => 'bar'], ['foo' => 'bar']]], \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader::convertDomElementToArray($doc->documentElement), '::convertDomElementToArray() converts a \\DomElement to an array'); + } + public function testExtensions() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectExtension()); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectWithXsdExtension()); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + // extension without an XSD + $loader->load('extensions/services1.xml'); + $container->compile(); + $services = $container->getDefinitions(); + $parameters = $container->getParameterBag()->all(); + $this->assertArrayHasKey('project.service.bar', $services, '->load() parses extension elements'); + $this->assertArrayHasKey('project.parameter.bar', $parameters, '->load() parses extension elements'); + $this->assertEquals('BAR', $services['project.service.foo']->getClass(), '->load() parses extension elements'); + $this->assertEquals('BAR', $parameters['project.parameter.foo'], '->load() parses extension elements'); + // extension with an XSD + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectExtension()); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectWithXsdExtension()); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('extensions/services2.xml'); + $container->compile(); + $services = $container->getDefinitions(); + $parameters = $container->getParameterBag()->all(); + $this->assertArrayHasKey('project.service.bar', $services, '->load() parses extension elements'); + $this->assertArrayHasKey('project.parameter.bar', $parameters, '->load() parses extension elements'); + $this->assertEquals('BAR', $services['project.service.foo']->getClass(), '->load() parses extension elements'); + $this->assertEquals('BAR', $parameters['project.parameter.foo'], '->load() parses extension elements'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectExtension()); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectWithXsdExtension()); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + // extension with an XSD (does not validate) + try { + $loader->load('extensions/services3.xml'); + $this->fail('->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); + $this->assertRegExp(\sprintf('#^Unable to parse file ".+%s": .+.$#', 'services3.xml'), $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); + $e = $e->getPrevious(); + $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); + $this->assertStringContainsString('The attribute \'bar\' is not allowed', $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); + } + // non-registered extension + try { + $loader->load('extensions/services4.xml'); + $this->fail('->load() throws an InvalidArgumentException if the tag is not valid'); + } catch (\Exception $e) { + $this->assertInstanceOf('\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the tag is not valid'); + $this->assertStringStartsWith('There is no extension able to load the configuration for "project:bar" (in', $e->getMessage(), '->load() throws an InvalidArgumentException if the tag is not valid'); + } + } + public function testExtensionInPhar() + { + if (\extension_loaded('suhosin') && \false === \strpos(\ini_get('suhosin.executor.include.whitelist'), 'phar')) { + $this->markTestSkipped('To run this test, add "phar" to the "suhosin.executor.include.whitelist" settings in your php.ini file.'); + } + if (\defined('HHVM_VERSION')) { + $this->markTestSkipped('HHVM makes this test conflict with those run in separate processes.'); + } + require_once self::$fixturesPath . '/includes/ProjectWithXsdExtensionInPhar.phar'; + // extension with an XSD in PHAR archive + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectWithXsdExtensionInPhar()); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('extensions/services6.xml'); + // extension with an XSD in PHAR archive (does not validate) + try { + $loader->load('extensions/services7.xml'); + $this->fail('->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); + $this->assertRegExp(\sprintf('#^Unable to parse file ".+%s": .+.$#', 'services7.xml'), $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); + $e = $e->getPrevious(); + $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); + $this->assertStringContainsString('The attribute \'bar\' is not allowed', $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration does not validate the XSD'); + } + } + public function testSupports() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $this->assertTrue($loader->supports('foo.xml'), '->supports() returns true if the resource is loadable'); + $this->assertFalse($loader->supports('foo.foo'), '->supports() returns false if the resource is not loadable'); + $this->assertTrue($loader->supports('with_wrong_ext.yml', 'xml'), '->supports() returns true if the resource with forced type is loadable'); + } + public function testNoNamingConflictsForAnonymousServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml/extension1')); + $loader1->load('services.xml'); + $services = $container->getDefinitions(); + $this->assertCount(3, $services, '->load() attributes unique ids to anonymous services'); + $loader2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml/extension2')); + $loader2->load('services.xml'); + $services = $container->getDefinitions(); + $this->assertCount(5, $services, '->load() attributes unique ids to anonymous services'); + $services = $container->getDefinitions(); + $args1 = $services['extension1.foo']->getArguments(); + $inner1 = $services[(string) $args1[0]]; + $this->assertEquals('BarClass1', $inner1->getClass(), '->load() uses the same configuration as for the anonymous ones'); + $args2 = $services['extension2.foo']->getArguments(); + $inner2 = $services[(string) $args2[0]]; + $this->assertEquals('BarClass2', $inner2->getClass(), '->load() uses the same configuration as for the anonymous ones'); + } + public function testDocTypeIsNotAllowed() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + // document types are not allowed. + try { + $loader->load('withdoctype.xml'); + $this->fail('->load() throws an InvalidArgumentException if the configuration contains a document type'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration contains a document type'); + $this->assertRegExp(\sprintf('#^Unable to parse file ".+%s": .+.$#', 'withdoctype.xml'), $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration contains a document type'); + $e = $e->getPrevious(); + $this->assertInstanceOf('InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the configuration contains a document type'); + $this->assertSame('Document types are not allowed.', $e->getMessage(), '->load() throws an InvalidArgumentException if the configuration contains a document type'); + } + } + public function testXmlNamespaces() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('namespaces.xml'); + $services = $container->getDefinitions(); + $this->assertArrayHasKey('foo', $services, '->load() parses elements'); + $this->assertCount(1, $services['foo']->getTag('foo.tag'), '->load parses elements'); + $this->assertEquals([['setBar', ['foo']]], $services['foo']->getMethodCalls(), '->load() parses the tag'); + } + public function testLoadIndexedArguments() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services14.xml'); + $this->assertEquals(['index_0' => 'app'], $container->findDefinition('logger')->getArguments()); + } + public function testLoadInlinedServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services21.xml'); + $foo = $container->getDefinition('foo'); + $fooFactory = $foo->getFactory(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $fooFactory[0]); + $this->assertTrue($container->has((string) $fooFactory[0])); + $fooFactoryDefinition = $container->getDefinition((string) $fooFactory[0]); + $this->assertSame('FooFactory', $fooFactoryDefinition->getClass()); + $this->assertSame('createFoo', $fooFactory[1]); + $fooFactoryFactory = $fooFactoryDefinition->getFactory(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $fooFactoryFactory[0]); + $this->assertTrue($container->has((string) $fooFactoryFactory[0])); + $this->assertSame('Foobar', $container->getDefinition((string) $fooFactoryFactory[0])->getClass()); + $this->assertSame('createFooFactory', $fooFactoryFactory[1]); + $fooConfigurator = $foo->getConfigurator(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $fooConfigurator[0]); + $this->assertTrue($container->has((string) $fooConfigurator[0])); + $fooConfiguratorDefinition = $container->getDefinition((string) $fooConfigurator[0]); + $this->assertSame('Bar', $fooConfiguratorDefinition->getClass()); + $this->assertSame('configureFoo', $fooConfigurator[1]); + $barConfigurator = $fooConfiguratorDefinition->getConfigurator(); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $barConfigurator[0]); + $this->assertSame('Baz', $container->getDefinition((string) $barConfigurator[0])->getClass()); + $this->assertSame('configureBar', $barConfigurator[1]); + } + /** + * @group legacy + */ + public function testType() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services22.xml'); + $this->assertEquals(['Bar', 'Baz'], $container->getDefinition('foo')->getAutowiringTypes()); + } + public function testAutowire() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services23.xml'); + $this->assertTrue($container->getDefinition('bar')->isAutowired()); + } + public function testClassFromId() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('class_from_id.xml'); + $container->compile(); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class, $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->getClass()); + } + public function testPrototype() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_prototype.xml'); + $ids = \array_keys($container->getDefinitions()); + \sort($ids); + $this->assertSame([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar::class, 'service_container'], $ids); + $resources = $container->getResources(); + $fixturesDir = \dirname(__DIR__) . \DIRECTORY_SEPARATOR . 'Fixtures' . \DIRECTORY_SEPARATOR; + $resources = \array_map('strval', $resources); + $this->assertContains((string) new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource($fixturesDir . 'xml' . \DIRECTORY_SEPARATOR . 'services_prototype.xml'), $resources); + $this->assertContains((string) new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($fixturesDir . 'Prototype', '/*', \true), $resources); + $this->assertContains('_PhpScoper5ea00cc67502b\\reflection.Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\Foo', $resources); + $this->assertContains('_PhpScoper5ea00cc67502b\\reflection.Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\Sub\\Bar', $resources); + } + /** + * @group legacy + * @expectedDeprecation Using the attribute "class" is deprecated for the service "bar" which is defined as an alias %s. + * @expectedDeprecation Using the element "tag" is deprecated for the service "bar" which is defined as an alias %s. + * @expectedDeprecation Using the element "factory" is deprecated for the service "bar" which is defined as an alias %s. + */ + public function testAliasDefinitionContainsUnsupportedElements() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('legacy_invalid_alias_definition.xml'); + $this->assertTrue($container->has('bar')); + } + public function testArgumentWithKeyOutsideCollection() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('with_key_outside_collection.xml'); + $this->assertSame(['type' => 'foo', 'bar'], $container->getDefinition('foo')->getArguments()); + } + public function testDefaults() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services28.xml'); + $this->assertFalse($container->getDefinition('with_defaults')->isPublic()); + $this->assertSame(['foo' => [[]]], $container->getDefinition('with_defaults')->getTags()); + $this->assertTrue($container->getDefinition('with_defaults')->isAutowired()); + $this->assertArrayNotHasKey('public', $container->getDefinition('with_defaults')->getChanges()); + $this->assertArrayNotHasKey('autowire', $container->getDefinition('with_defaults')->getChanges()); + $container->compile(); + $this->assertTrue($container->getDefinition('no_defaults')->isPublic()); + $this->assertSame(['foo' => [[]]], $container->getDefinition('no_defaults')->getTags()); + $this->assertFalse($container->getDefinition('no_defaults')->isAutowired()); + $this->assertTrue($container->getDefinition('child_def')->isPublic()); + $this->assertSame(['foo' => [[]]], $container->getDefinition('child_def')->getTags()); + $this->assertFalse($container->getDefinition('child_def')->isAutowired()); + $definitions = $container->getDefinitions(); + $this->assertSame('service_container', \key($definitions)); + \array_shift($definitions); + $anonymous = \current($definitions); + $this->assertSame('bar', \key($definitions)); + $this->assertTrue($anonymous->isPublic()); + $this->assertTrue($anonymous->isAutowired()); + $this->assertSame(['foo' => [[]]], $anonymous->getTags()); + } + public function testNamedArguments() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_named_args.xml'); + $this->assertEquals(['$apiKey' => 'ABCD', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => null], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getArguments()); + $container->compile(); + $this->assertEquals([null, 'ABCD'], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getArguments()); + $this->assertEquals([['setApiKey', ['123']]], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getMethodCalls()); + } + public function testInstanceof() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_instanceof.xml'); + $container->compile(); + $definition = $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class); + $this->assertTrue($definition->isAutowired()); + $this->assertTrue($definition->isLazy()); + $this->assertSame(['foo' => [[]], 'bar' => [[]]], $definition->getTags()); + } + public function testInstanceOfAndChildDefinitionNotAllowed() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The service "child_service" cannot use the "parent" option in the same file where "instanceof" configuration is defined as using both is not supported. Move your child definitions to a separate file.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_instanceof_with_parent.xml'); + $container->compile(); + } + public function testAutoConfigureAndChildDefinitionNotAllowed() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The service "child_service" cannot have a "parent" and also have "autoconfigure". Try setting autoconfigure="false" for the service.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_autoconfigure_with_parent.xml'); + $container->compile(); + } + public function testDefaultsAndChildDefinitionNotAllowed() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Attribute "autowire" on service "child_service" cannot be inherited from "defaults" when a "parent" is set. Move your child definitions to a separate file or define this attribute explicitly.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_defaults_with_parent.xml'); + $container->compile(); + } + public function testAutoConfigureInstanceof() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_autoconfigure.xml'); + $this->assertTrue($container->getDefinition('use_defaults_settings')->isAutoconfigured()); + $this->assertFalse($container->getDefinition('override_defaults_settings_to_false')->isAutoconfigured()); + } + public function testBindings() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_bindings.xml'); + $container->compile(); + $definition = $container->getDefinition('bar'); + $this->assertEquals(['NonExistent' => null, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class), '$foo' => [null], '$quz' => 'quz', '$factory' => 'factory'], \array_map(function ($v) { + return $v->getValues()[0]; + }, $definition->getBindings())); + $this->assertEquals(['quz', null, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class), [null]], $definition->getArguments()); + $definition = $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class); + $this->assertEquals([null, 'factory'], $definition->getArguments()); + $this->assertEquals(['NonExistent' => null, '$quz' => 'quz', '$factory' => 'factory'], \array_map(function ($v) { + return $v->getValues()[0]; + }, $definition->getBindings())); + } + public function testTsantosContainer() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('services_tsantos.xml'); + $container->compile(); + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Dumper\PhpDumper($container); + $this->assertStringEqualsFile(self::$fixturesPath . '/php/services_tsantos.php', $dumper->dump()); + } + /** + * The pass may throw an exception, which will cause the test to fail. + */ + public function testOverriddenDefaultsBindings() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')); + $loader->load('defaults_bindings.xml'); + $loader->load('defaults_bindings2.xml'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass())->process($container); + $this->assertSame('overridden', $container->get('bar')->quz); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/YamlFileLoaderTest.php b/vendor/symfony/dependency-injection/Tests/Loader/YamlFileLoaderTest.php index 705604e5d..3e8308fad 100644 --- a/vendor/symfony/dependency-injection/Tests/Loader/YamlFileLoaderTest.php +++ b/vendor/symfony/dependency-injection/Tests/Loader/YamlFileLoaderTest.php @@ -1,580 +1,580 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -class YamlFileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected static $fixturesPath; - public static function setUpBeforeClass() - { - self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); - require_once self::$fixturesPath . '/includes/foo.php'; - require_once self::$fixturesPath . '/includes/ProjectExtension.php'; - } - public function testLoadUnExistFile() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/The file ".+" does not exist./'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')); - $r = new \ReflectionObject($loader); - $m = $r->getMethod('loadFile'); - $m->setAccessible(\true); - $m->invoke($loader, 'foo.yml'); - } - public function testLoadInvalidYamlFile() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/The file ".+" does not contain valid YAML./'); - $path = self::$fixturesPath . '/ini'; - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator($path)); - $r = new \ReflectionObject($loader); - $m = $r->getMethod('loadFile'); - $m->setAccessible(\true); - $m->invoke($loader, $path . '/parameters.ini'); - } - /** - * @dataProvider provideInvalidFiles - */ - public function testLoadInvalidFile($file) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load($file . '.yml'); - } - public function provideInvalidFiles() - { - return [['bad_parameters'], ['bad_imports'], ['bad_import'], ['bad_services'], ['bad_service'], ['bad_calls'], ['bad_format'], ['nonvalid1'], ['nonvalid2']]; - } - public function testLoadParameters() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services2.yml'); - $this->assertEquals(['foo' => 'bar', 'mixedcase' => ['MixedCaseKey' => 'value'], 'values' => [\true, \false, 0, 1000.3, \PHP_INT_MAX], 'bar' => 'foo', 'escape' => '@escapeme', 'foo_bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo_bar')], $container->getParameterBag()->all(), '->load() converts YAML keys to lowercase'); - } - public function testLoadImports() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/php')), $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml'))]); - $loader->setResolver($resolver); - $loader->load('services4.yml'); - $actual = $container->getParameterBag()->all(); - $expected = ['foo' => 'bar', 'values' => [\true, \false, \PHP_INT_MAX], 'bar' => '%foo%', 'escape' => '@escapeme', 'foo_bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo_bar'), 'mixedcase' => ['MixedCaseKey' => 'value'], 'imported_from_ini' => \true, 'imported_from_xml' => \true, 'with_wrong_ext' => 'from yaml']; - $this->assertEquals(\array_keys($expected), \array_keys($actual), '->load() imports and merges imported files'); - $this->assertTrue($actual['imported_from_ini']); - // Bad import throws no exception due to ignore_errors value. - $loader->load('services4_bad_import.yml'); - } - public function testLoadServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services6.yml'); - $services = $container->getDefinitions(); - $this->assertArrayHasKey('foo', $services, '->load() parses service elements'); - $this->assertFalse($services['not_shared']->isShared(), '->load() parses the shared flag'); - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $services['foo'], '->load() converts service element to Definition instances'); - $this->assertEquals('FooClass', $services['foo']->getClass(), '->load() parses the class attribute'); - $this->assertEquals('%path%/foo.php', $services['file']->getFile(), '->load() parses the file tag'); - $this->assertEquals(['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), [\true, \false]], $services['arguments']->getArguments(), '->load() parses the argument tags'); - $this->assertEquals('sc_configure', $services['configurator1']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'configure'], $services['configurator2']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals(['BazClass', 'configureStatic'], $services['configurator3']->getConfigurator(), '->load() parses the configurator tag'); - $this->assertEquals([['setBar', []], ['setBar', []], ['setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')]]], $services['method_call1']->getMethodCalls(), '->load() parses the method_call tag'); - $this->assertEquals([['setBar', ['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), [\true, \false]]]], $services['method_call2']->getMethodCalls(), '->load() parses the method_call tag'); - $this->assertEquals('factory', $services['new_factory1']->getFactory(), '->load() parses the factory tag'); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'getClass'], $services['new_factory2']->getFactory(), '->load() parses the factory tag'); - $this->assertEquals(['BazClass', 'getInstance'], $services['new_factory3']->getFactory(), '->load() parses the factory tag'); - $this->assertSame([null, 'getInstance'], $services['new_factory4']->getFactory(), '->load() accepts factory tag without class'); - $this->assertEquals(['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')], $services['Acme\\WithShortCutArgs']->getArguments(), '->load() parses short service definition'); - $aliases = $container->getAliases(); - $this->assertArrayHasKey('alias_for_foo', $aliases, '->load() parses aliases'); - $this->assertEquals('foo', (string) $aliases['alias_for_foo'], '->load() parses aliases'); - $this->assertTrue($aliases['alias_for_foo']->isPublic()); - $this->assertArrayHasKey('another_alias_for_foo', $aliases); - $this->assertEquals('foo', (string) $aliases['another_alias_for_foo']); - $this->assertFalse($aliases['another_alias_for_foo']->isPublic()); - $this->assertTrue(isset($aliases['another_third_alias_for_foo'])); - $this->assertEquals('foo', (string) $aliases['another_third_alias_for_foo']); - $this->assertTrue($aliases['another_third_alias_for_foo']->isPublic()); - $this->assertEquals(['decorated', null, 0], $services['decorator_service']->getDecoratedService()); - $this->assertEquals(['decorated', 'decorated.pif-pouf', 0], $services['decorator_service_with_name']->getDecoratedService()); - $this->assertEquals(['decorated', 'decorated.pif-pouf', 5], $services['decorator_service_with_name_and_priority']->getDecoratedService()); - } - public function testLoadFactoryShortSyntax() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services14.yml'); - $services = $container->getDefinitions(); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'getClass'], $services['factory']->getFactory(), '->load() parses the factory tag with service:method'); - $this->assertEquals(['FooBacFactory', 'createFooBar'], $services['factory_with_static_call']->getFactory(), '->load() parses the factory tag with Class::method'); - } - public function testLoadConfiguratorShortSyntax() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_configurator_short_syntax.yml'); - $services = $container->getDefinitions(); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo_bar_configurator'), 'configure'], $services['foo_bar']->getConfigurator(), '->load() parses the configurator tag with service:method'); - $this->assertEquals(['FooBarConfigurator', 'configureFooBar'], $services['foo_bar_with_static_call']->getConfigurator(), '->load() parses the configurator tag with Class::method'); - } - public function testExtensions() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectExtension()); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services10.yml'); - $container->compile(); - $services = $container->getDefinitions(); - $parameters = $container->getParameterBag()->all(); - $this->assertArrayHasKey('project.service.bar', $services, '->load() parses extension elements'); - $this->assertArrayHasKey('project.parameter.bar', $parameters, '->load() parses extension elements'); - $this->assertEquals('BAR', $services['project.service.foo']->getClass(), '->load() parses extension elements'); - $this->assertEquals('BAR', $parameters['project.parameter.foo'], '->load() parses extension elements'); - try { - $loader->load('services11.yml'); - $this->fail('->load() throws an InvalidArgumentException if the tag is not valid'); - } catch (\Exception $e) { - $this->assertInstanceOf('\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the tag is not valid'); - $this->assertStringStartsWith('There is no extension able to load the configuration for "foobarfoobar" (in', $e->getMessage(), '->load() throws an InvalidArgumentException if the tag is not valid'); - } - } - public function testExtensionWithNullConfig() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectExtension()); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('null_config.yml'); - $container->compile(); - $this->assertSame([null], $container->getParameter('project.configs')); - } - public function testSupports() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); - $this->assertTrue($loader->supports('foo.yml'), '->supports() returns true if the resource is loadable'); - $this->assertTrue($loader->supports('foo.yaml'), '->supports() returns true if the resource is loadable'); - $this->assertFalse($loader->supports('foo.foo'), '->supports() returns false if the resource is not loadable'); - $this->assertTrue($loader->supports('with_wrong_ext.xml', 'yml'), '->supports() returns true if the resource with forced type is loadable'); - $this->assertTrue($loader->supports('with_wrong_ext.xml', 'yaml'), '->supports() returns true if the resource with forced type is loadable'); - } - public function testNonArrayTagsThrowsException() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - try { - $loader->load('badtag1.yml'); - $this->fail('->load() should throw an exception when the tags key of a service is not an array'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the tags key is not an array'); - $this->assertStringStartsWith('Parameter "tags" must be an array for service', $e->getMessage(), '->load() throws an InvalidArgumentException if the tags key is not an array'); - } - } - public function testTagWithoutNameThrowsException() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - try { - $loader->load('badtag2.yml'); - $this->fail('->load() should throw an exception when a tag is missing the name key'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if a tag is missing the name key'); - $this->assertStringStartsWith('A "tags" entry is missing a "name" key for service ', $e->getMessage(), '->load() throws an InvalidArgumentException if a tag is missing the name key'); - } - } - public function testNameOnlyTagsAreAllowedAsString() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('tag_name_only.yml'); - $this->assertCount(1, $container->getDefinition('foo_service')->getTag('foo')); - } - public function testTagWithAttributeArrayThrowsException() - { - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - try { - $loader->load('badtag3.yml'); - $this->fail('->load() should throw an exception when a tag-attribute is not a scalar'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if a tag-attribute is not a scalar'); - $this->assertStringStartsWith('A "tags" attribute must be of a scalar-type for service "foo_service", tag "foo", attribute "bar"', $e->getMessage(), '->load() throws an InvalidArgumentException if a tag-attribute is not a scalar'); - } - } - public function testLoadYamlOnlyWithKeys() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services21.yml'); - $definition = $container->getDefinition('manager'); - $this->assertEquals([['setLogger', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('logger')]], ['setClass', ['User']]], $definition->getMethodCalls()); - $this->assertEquals([\true], $definition->getArguments()); - $this->assertEquals(['manager' => [['alias' => 'user']]], $definition->getTags()); - } - public function testTagWithEmptyNameThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/The tag name for service ".+" in .+ must be a non-empty string/'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('tag_name_empty_string.yml'); - } - public function testTagWithNonStringNameThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/The tag name for service ".+" in .+ must be a non-empty string/'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('tag_name_no_string.yml'); - } - public function testTypesNotArray() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('bad_types1.yml'); - } - public function testTypeNotString() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('bad_types2.yml'); - } - /** - * @group legacy - */ - public function testTypes() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services22.yml'); - $this->assertEquals(['Foo', 'Bar'], $container->getDefinition('foo_service')->getAutowiringTypes()); - $this->assertEquals(['Foo'], $container->getDefinition('baz_service')->getAutowiringTypes()); - } - public function testParsesIteratorArgument() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services9.yml'); - $lazyDefinition = $container->getDefinition('lazy_context'); - $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['k1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'k2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])], $lazyDefinition->getArguments(), '->load() parses lazy arguments'); - $message = 'The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed.'; - $this->assertSame($message, $container->getDefinition('deprecated_service')->getDeprecationMessage('deprecated_service')); - } - public function testAutowire() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services23.yml'); - $this->assertTrue($container->getDefinition('bar_service')->isAutowired()); - } - public function testClassFromId() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('class_from_id.yml'); - $container->compile(); - $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class, $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->getClass()); - } - public function testPrototype() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_prototype.yml'); - $ids = \array_keys($container->getDefinitions()); - \sort($ids); - $this->assertSame([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar::class, 'service_container'], $ids); - $resources = $container->getResources(); - $fixturesDir = \dirname(__DIR__) . \DIRECTORY_SEPARATOR . 'Fixtures' . \DIRECTORY_SEPARATOR; - $resources = \array_map('strval', $resources); - $this->assertContains((string) new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource($fixturesDir . 'yaml' . \DIRECTORY_SEPARATOR . 'services_prototype.yml'), $resources); - $this->assertContains((string) new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($fixturesDir . 'Prototype', '', \true), $resources); - $this->assertContains('_PhpScoper5ea00cc67502b\\reflection.Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\Foo', $resources); - $this->assertContains('_PhpScoper5ea00cc67502b\\reflection.Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\Sub\\Bar', $resources); - } - public function testPrototypeWithNamespace() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_prototype_namespace.yml'); - $ids = \array_keys($container->getDefinitions()); - \sort($ids); - $this->assertSame([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir1\Service1::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir2\Service2::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir1\Service4::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir2\Service5::class, 'service_container'], $ids); - $this->assertTrue($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir1\Service1::class)->hasTag('foo')); - $this->assertTrue($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir1\Service4::class)->hasTag('foo')); - $this->assertFalse($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir1\Service1::class)->hasTag('bar')); - $this->assertFalse($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir1\Service4::class)->hasTag('bar')); - $this->assertTrue($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir2\Service2::class)->hasTag('bar')); - $this->assertTrue($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir2\Service5::class)->hasTag('bar')); - $this->assertFalse($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir2\Service2::class)->hasTag('foo')); - $this->assertFalse($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir2\Service5::class)->hasTag('foo')); - } - public function testPrototypeWithNamespaceAndNoResource() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/A "resource" attribute must be set when the "namespace" attribute is set for service ".+" in .+/'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_prototype_namespace_without_resource.yml'); - } - public function testDefaults() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services28.yml'); - $this->assertFalse($container->getDefinition('with_defaults')->isPublic()); - $this->assertSame(['foo' => [[]]], $container->getDefinition('with_defaults')->getTags()); - $this->assertTrue($container->getDefinition('with_defaults')->isAutowired()); - $this->assertArrayNotHasKey('public', $container->getDefinition('with_defaults')->getChanges()); - $this->assertArrayNotHasKey('autowire', $container->getDefinition('with_defaults')->getChanges()); - $this->assertFalse($container->getAlias('with_defaults_aliased')->isPublic()); - $this->assertFalse($container->getAlias('with_defaults_aliased_short')->isPublic()); - $this->assertFalse($container->getDefinition('_PhpScoper5ea00cc67502b\\Acme\\WithShortCutArgs')->isPublic()); - $this->assertSame(['foo' => [[]]], $container->getDefinition('_PhpScoper5ea00cc67502b\\Acme\\WithShortCutArgs')->getTags()); - $this->assertTrue($container->getDefinition('_PhpScoper5ea00cc67502b\\Acme\\WithShortCutArgs')->isAutowired()); - $container->compile(); - $this->assertTrue($container->getDefinition('with_null')->isPublic()); - $this->assertTrue($container->getDefinition('no_defaults')->isPublic()); - // foo tag is inherited from defaults - $this->assertSame(['foo' => [[]]], $container->getDefinition('with_null')->getTags()); - $this->assertSame(['foo' => [[]]], $container->getDefinition('no_defaults')->getTags()); - $this->assertTrue($container->getDefinition('with_null')->isAutowired()); - $this->assertFalse($container->getDefinition('no_defaults')->isAutowired()); - $this->assertTrue($container->getDefinition('child_def')->isPublic()); - $this->assertSame(['foo' => [[]]], $container->getDefinition('child_def')->getTags()); - $this->assertFalse($container->getDefinition('child_def')->isAutowired()); - } - public function testNamedArguments() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_named_args.yml'); - $this->assertEquals([null, '$apiKey' => 'ABCD'], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getArguments()); - $this->assertEquals(['$apiKey' => 'ABCD', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => null], $container->getDefinition('another_one')->getArguments()); - $container->compile(); - $this->assertEquals([null, 'ABCD'], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getArguments()); - $this->assertEquals([null, 'ABCD'], $container->getDefinition('another_one')->getArguments()); - $this->assertEquals([['setApiKey', ['123']]], $container->getDefinition('another_one')->getMethodCalls()); - } - public function testInstanceof() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_instanceof.yml'); - $container->compile(); - $definition = $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class); - $this->assertTrue($definition->isAutowired()); - $this->assertTrue($definition->isLazy()); - $this->assertSame(['foo' => [[]], 'bar' => [[]]], $definition->getTags()); - } - public function testInstanceOfAndChildDefinitionNotAllowed() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The service "child_service" cannot use the "parent" option in the same file where "_instanceof" configuration is defined as using both is not supported. Move your child definitions to a separate file.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_instanceof_with_parent.yml'); - $container->compile(); - } - public function testAutoConfigureAndChildDefinitionNotAllowed() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The service "child_service" cannot have a "parent" and also have "autoconfigure". Try setting "autoconfigure: false" for the service.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_autoconfigure_with_parent.yml'); - $container->compile(); - } - public function testDefaultsAndChildDefinitionNotAllowed() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('Attribute "autowire" on service "child_service" cannot be inherited from "_defaults" when a "parent" is set. Move your child definitions to a separate file or define this attribute explicitly.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_defaults_with_parent.yml'); - $container->compile(); - } - public function testDecoratedServicesWithWrongSyntaxThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessage('The value of the "decorates" option for the "bar" service must be the id of the service without the "@" prefix (replace "@foo" with "foo").'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('bad_decorates.yml'); - } - public function testInvalidTagsWithDefaults() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/Parameter "tags" must be an array for service "Foo\\\\Bar" in ".+services31_invalid_tags\\.yml"\\. Check your YAML syntax./'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services31_invalid_tags.yml'); - } - /** - * @group legacy - * @expectedDeprecation Service names that start with an underscore are deprecated since Symfony 3.3 and will be reserved in 4.0. Rename the "_foo" service or define it in XML instead. - */ - public function testUnderscoreServiceId() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_underscore.yml'); - } - public function testAnonymousServices() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('anonymous_services.yml'); - $definition = $container->getDefinition('Foo'); - $this->assertTrue($definition->isAutowired()); - // Anonymous service in an argument - $args = $definition->getArguments(); - $this->assertCount(1, $args); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $args[0]); - $this->assertTrue($container->has((string) $args[0])); - $this->assertRegExp('/^\\d+_Bar~[._A-Za-z0-9]{7}$/', (string) $args[0]); - $anonymous = $container->getDefinition((string) $args[0]); - $this->assertEquals('Bar', $anonymous->getClass()); - $this->assertFalse($anonymous->isPublic()); - $this->assertTrue($anonymous->isAutowired()); - // Anonymous service in a callable - $factory = $definition->getFactory(); - $this->assertIsArray($factory); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $factory[0]); - $this->assertTrue($container->has((string) $factory[0])); - $this->assertRegExp('/^\\d+_Quz~[._A-Za-z0-9]{7}$/', (string) $factory[0]); - $this->assertEquals('constructFoo', $factory[1]); - $anonymous = $container->getDefinition((string) $factory[0]); - $this->assertEquals('Quz', $anonymous->getClass()); - $this->assertFalse($anonymous->isPublic()); - $this->assertFalse($anonymous->isAutowired()); - } - public function testAnonymousServicesInDifferentFilesWithSameNameDoNotConflict() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml/foo')); - $loader->load('services.yml'); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml/bar')); - $loader->load('services.yml'); - $this->assertCount(5, $container->getDefinitions()); - } - public function testAnonymousServicesInInstanceof() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('anonymous_services_in_instanceof.yml'); - $definition = $container->getDefinition('Dummy'); - $instanceof = $definition->getInstanceofConditionals(); - $this->assertCount(3, $instanceof); - $this->assertArrayHasKey('DummyInterface', $instanceof); - $args = $instanceof['DummyInterface']->getProperties(); - $this->assertCount(1, $args); - $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $args['foo']); - $this->assertTrue($container->has((string) $args['foo'])); - $anonymous = $container->getDefinition((string) $args['foo']); - $this->assertEquals('Anonymous', $anonymous->getClass()); - $this->assertFalse($anonymous->isPublic()); - $this->assertEmpty($anonymous->getInstanceofConditionals()); - $this->assertFalse($container->has('Bar')); - } - public function testAnonymousServicesWithAliases() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/Creating an alias using the tag "!service" is not allowed in ".+anonymous_services_alias\\.yml"\\./'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('anonymous_services_alias.yml'); - } - public function testAnonymousServicesInParameters() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/Using an anonymous service in a parameter is not allowed in ".+anonymous_services_in_parameters\\.yml"\\./'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('anonymous_services_in_parameters.yml'); - } - public function testAutoConfigureInstanceof() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_autoconfigure.yml'); - $this->assertTrue($container->getDefinition('use_defaults_settings')->isAutoconfigured()); - $this->assertFalse($container->getDefinition('override_defaults_settings_to_false')->isAutoconfigured()); - } - public function testEmptyDefaultsThrowsClearException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/Service "_defaults" key must be an array, "NULL" given in ".+bad_empty_defaults\\.yml"\\./'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('bad_empty_defaults.yml'); - } - public function testEmptyInstanceofThrowsClearException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $this->expectExceptionMessageRegExp('/Service "_instanceof" key must be an array, "NULL" given in ".+bad_empty_instanceof\\.yml"\\./'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('bad_empty_instanceof.yml'); - } - public function testBindings() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('services_bindings.yml'); - $container->compile(); - $definition = $container->getDefinition('bar'); - $this->assertEquals(['NonExistent' => null, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class), '$foo' => [null], '$quz' => 'quz', '$factory' => 'factory'], \array_map(function ($v) { - return $v->getValues()[0]; - }, $definition->getBindings())); - $this->assertEquals(['quz', null, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class), [null]], $definition->getArguments()); - $definition = $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class); - $this->assertEquals([null, 'factory'], $definition->getArguments()); - $this->assertEquals(['NonExistent' => null, '$quz' => 'quz', '$factory' => 'factory'], \array_map(function ($v) { - return $v->getValues()[0]; - }, $definition->getBindings())); - } - /** - * The pass may throw an exception, which will cause the test to fail. - */ - public function testOverriddenDefaultsBindings() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('defaults_bindings.yml'); - $loader->load('defaults_bindings2.yml'); - (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass())->process($container); - $this->assertSame('overridden', $container->get('bar')->quz); - } - /** - * @group legacy - * @expectedDeprecation The configuration key "factory" is unsupported for the service "foo" which is defined as an alias in %s. - * @expectedDeprecation The configuration key "parent" is unsupported for the service "foo" which is defined as an alias in %s. - */ - public function testAliasDefinitionContainsUnsupportedElements() - { - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); - $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); - $loader->load('legacy_invalid_alias_definition.yml'); - $this->assertTrue($container->has('foo')); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Loader; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +class YamlFileLoaderTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected static $fixturesPath; + public static function setUpBeforeClass() + { + self::$fixturesPath = \realpath(__DIR__ . '/../Fixtures/'); + require_once self::$fixturesPath . '/includes/foo.php'; + require_once self::$fixturesPath . '/includes/ProjectExtension.php'; + } + public function testLoadUnExistFile() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/The file ".+" does not exist./'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')); + $r = new \ReflectionObject($loader); + $m = $r->getMethod('loadFile'); + $m->setAccessible(\true); + $m->invoke($loader, 'foo.yml'); + } + public function testLoadInvalidYamlFile() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/The file ".+" does not contain valid YAML./'); + $path = self::$fixturesPath . '/ini'; + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator($path)); + $r = new \ReflectionObject($loader); + $m = $r->getMethod('loadFile'); + $m->setAccessible(\true); + $m->invoke($loader, $path . '/parameters.ini'); + } + /** + * @dataProvider provideInvalidFiles + */ + public function testLoadInvalidFile($file) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load($file . '.yml'); + } + public function provideInvalidFiles() + { + return [['bad_parameters'], ['bad_imports'], ['bad_import'], ['bad_services'], ['bad_service'], ['bad_calls'], ['bad_format'], ['nonvalid1'], ['nonvalid2']]; + } + public function testLoadParameters() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services2.yml'); + $this->assertEquals(['foo' => 'bar', 'mixedcase' => ['MixedCaseKey' => 'value'], 'values' => [\true, \false, 0, 1000.3, \PHP_INT_MAX], 'bar' => 'foo', 'escape' => '@escapeme', 'foo_bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo_bar')], $container->getParameterBag()->all(), '->load() converts YAML keys to lowercase'); + } + public function testLoadImports() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $resolver = new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Loader\LoaderResolver([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\IniFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/ini')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\XmlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/xml')), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\PhpFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/php')), $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml'))]); + $loader->setResolver($resolver); + $loader->load('services4.yml'); + $actual = $container->getParameterBag()->all(); + $expected = ['foo' => 'bar', 'values' => [\true, \false, \PHP_INT_MAX], 'bar' => '%foo%', 'escape' => '@escapeme', 'foo_bar' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo_bar'), 'mixedcase' => ['MixedCaseKey' => 'value'], 'imported_from_ini' => \true, 'imported_from_xml' => \true, 'with_wrong_ext' => 'from yaml']; + $this->assertEquals(\array_keys($expected), \array_keys($actual), '->load() imports and merges imported files'); + $this->assertTrue($actual['imported_from_ini']); + // Bad import throws no exception due to ignore_errors value. + $loader->load('services4_bad_import.yml'); + } + public function testLoadServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services6.yml'); + $services = $container->getDefinitions(); + $this->assertArrayHasKey('foo', $services, '->load() parses service elements'); + $this->assertFalse($services['not_shared']->isShared(), '->load() parses the shared flag'); + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Definition', $services['foo'], '->load() converts service element to Definition instances'); + $this->assertEquals('FooClass', $services['foo']->getClass(), '->load() parses the class attribute'); + $this->assertEquals('%path%/foo.php', $services['file']->getFile(), '->load() parses the file tag'); + $this->assertEquals(['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), [\true, \false]], $services['arguments']->getArguments(), '->load() parses the argument tags'); + $this->assertEquals('sc_configure', $services['configurator1']->getConfigurator(), '->load() parses the configurator tag'); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'configure'], $services['configurator2']->getConfigurator(), '->load() parses the configurator tag'); + $this->assertEquals(['BazClass', 'configureStatic'], $services['configurator3']->getConfigurator(), '->load() parses the configurator tag'); + $this->assertEquals([['setBar', []], ['setBar', []], ['setBar', [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('service("foo").foo() ~ (container.hasParameter("foo") ? parameter("foo") : "default")')]]], $services['method_call1']->getMethodCalls(), '->load() parses the method_call tag'); + $this->assertEquals([['setBar', ['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'), [\true, \false]]]], $services['method_call2']->getMethodCalls(), '->load() parses the method_call tag'); + $this->assertEquals('factory', $services['new_factory1']->getFactory(), '->load() parses the factory tag'); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'getClass'], $services['new_factory2']->getFactory(), '->load() parses the factory tag'); + $this->assertEquals(['BazClass', 'getInstance'], $services['new_factory3']->getFactory(), '->load() parses the factory tag'); + $this->assertSame([null, 'getInstance'], $services['new_factory4']->getFactory(), '->load() accepts factory tag without class'); + $this->assertEquals(['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz')], $services['Acme\\WithShortCutArgs']->getArguments(), '->load() parses short service definition'); + $aliases = $container->getAliases(); + $this->assertArrayHasKey('alias_for_foo', $aliases, '->load() parses aliases'); + $this->assertEquals('foo', (string) $aliases['alias_for_foo'], '->load() parses aliases'); + $this->assertTrue($aliases['alias_for_foo']->isPublic()); + $this->assertArrayHasKey('another_alias_for_foo', $aliases); + $this->assertEquals('foo', (string) $aliases['another_alias_for_foo']); + $this->assertFalse($aliases['another_alias_for_foo']->isPublic()); + $this->assertTrue(isset($aliases['another_third_alias_for_foo'])); + $this->assertEquals('foo', (string) $aliases['another_third_alias_for_foo']); + $this->assertTrue($aliases['another_third_alias_for_foo']->isPublic()); + $this->assertEquals(['decorated', null, 0], $services['decorator_service']->getDecoratedService()); + $this->assertEquals(['decorated', 'decorated.pif-pouf', 0], $services['decorator_service_with_name']->getDecoratedService()); + $this->assertEquals(['decorated', 'decorated.pif-pouf', 5], $services['decorator_service_with_name_and_priority']->getDecoratedService()); + } + public function testLoadFactoryShortSyntax() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services14.yml'); + $services = $container->getDefinitions(); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('baz'), 'getClass'], $services['factory']->getFactory(), '->load() parses the factory tag with service:method'); + $this->assertEquals(['FooBacFactory', 'createFooBar'], $services['factory_with_static_call']->getFactory(), '->load() parses the factory tag with Class::method'); + } + public function testLoadConfiguratorShortSyntax() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_configurator_short_syntax.yml'); + $services = $container->getDefinitions(); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo_bar_configurator'), 'configure'], $services['foo_bar']->getConfigurator(), '->load() parses the configurator tag with service:method'); + $this->assertEquals(['FooBarConfigurator', 'configureFooBar'], $services['foo_bar_with_static_call']->getConfigurator(), '->load() parses the configurator tag with Class::method'); + } + public function testExtensions() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectExtension()); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services10.yml'); + $container->compile(); + $services = $container->getDefinitions(); + $parameters = $container->getParameterBag()->all(); + $this->assertArrayHasKey('project.service.bar', $services, '->load() parses extension elements'); + $this->assertArrayHasKey('project.parameter.bar', $parameters, '->load() parses extension elements'); + $this->assertEquals('BAR', $services['project.service.foo']->getClass(), '->load() parses extension elements'); + $this->assertEquals('BAR', $parameters['project.parameter.foo'], '->load() parses extension elements'); + try { + $loader->load('services11.yml'); + $this->fail('->load() throws an InvalidArgumentException if the tag is not valid'); + } catch (\Exception $e) { + $this->assertInstanceOf('\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the tag is not valid'); + $this->assertStringStartsWith('There is no extension able to load the configuration for "foobarfoobar" (in', $e->getMessage(), '->load() throws an InvalidArgumentException if the tag is not valid'); + } + } + public function testExtensionWithNullConfig() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $container->registerExtension(new \_PhpScoper5ea00cc67502b\ProjectExtension()); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('null_config.yml'); + $container->compile(); + $this->assertSame([null], $container->getParameter('project.configs')); + } + public function testSupports() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator()); + $this->assertTrue($loader->supports('foo.yml'), '->supports() returns true if the resource is loadable'); + $this->assertTrue($loader->supports('foo.yaml'), '->supports() returns true if the resource is loadable'); + $this->assertFalse($loader->supports('foo.foo'), '->supports() returns false if the resource is not loadable'); + $this->assertTrue($loader->supports('with_wrong_ext.xml', 'yml'), '->supports() returns true if the resource with forced type is loadable'); + $this->assertTrue($loader->supports('with_wrong_ext.xml', 'yaml'), '->supports() returns true if the resource with forced type is loadable'); + } + public function testNonArrayTagsThrowsException() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + try { + $loader->load('badtag1.yml'); + $this->fail('->load() should throw an exception when the tags key of a service is not an array'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if the tags key is not an array'); + $this->assertStringStartsWith('Parameter "tags" must be an array for service', $e->getMessage(), '->load() throws an InvalidArgumentException if the tags key is not an array'); + } + } + public function testTagWithoutNameThrowsException() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + try { + $loader->load('badtag2.yml'); + $this->fail('->load() should throw an exception when a tag is missing the name key'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if a tag is missing the name key'); + $this->assertStringStartsWith('A "tags" entry is missing a "name" key for service ', $e->getMessage(), '->load() throws an InvalidArgumentException if a tag is missing the name key'); + } + } + public function testNameOnlyTagsAreAllowedAsString() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('tag_name_only.yml'); + $this->assertCount(1, $container->getDefinition('foo_service')->getTag('foo')); + } + public function testTagWithAttributeArrayThrowsException() + { + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + try { + $loader->load('badtag3.yml'); + $this->fail('->load() should throw an exception when a tag-attribute is not a scalar'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException', $e, '->load() throws an InvalidArgumentException if a tag-attribute is not a scalar'); + $this->assertStringStartsWith('A "tags" attribute must be of a scalar-type for service "foo_service", tag "foo", attribute "bar"', $e->getMessage(), '->load() throws an InvalidArgumentException if a tag-attribute is not a scalar'); + } + } + public function testLoadYamlOnlyWithKeys() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services21.yml'); + $definition = $container->getDefinition('manager'); + $this->assertEquals([['setLogger', [new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('logger')]], ['setClass', ['User']]], $definition->getMethodCalls()); + $this->assertEquals([\true], $definition->getArguments()); + $this->assertEquals(['manager' => [['alias' => 'user']]], $definition->getTags()); + } + public function testTagWithEmptyNameThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/The tag name for service ".+" in .+ must be a non-empty string/'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('tag_name_empty_string.yml'); + } + public function testTagWithNonStringNameThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/The tag name for service ".+" in .+ must be a non-empty string/'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('tag_name_no_string.yml'); + } + public function testTypesNotArray() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('bad_types1.yml'); + } + public function testTypeNotString() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('bad_types2.yml'); + } + /** + * @group legacy + */ + public function testTypes() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services22.yml'); + $this->assertEquals(['Foo', 'Bar'], $container->getDefinition('foo_service')->getAutowiringTypes()); + $this->assertEquals(['Foo'], $container->getDefinition('baz_service')->getAutowiringTypes()); + } + public function testParsesIteratorArgument() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services9.yml'); + $lazyDefinition = $container->getDefinition('lazy_context'); + $this->assertEquals([new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument(['k1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo.baz'), 'k2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('service_container')]), new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Argument\IteratorArgument([])], $lazyDefinition->getArguments(), '->load() parses lazy arguments'); + $message = 'The "deprecated_service" service is deprecated. You should stop using it, as it will soon be removed.'; + $this->assertSame($message, $container->getDefinition('deprecated_service')->getDeprecationMessage('deprecated_service')); + } + public function testAutowire() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services23.yml'); + $this->assertTrue($container->getDefinition('bar_service')->isAutowired()); + } + public function testClassFromId() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('class_from_id.yml'); + $container->compile(); + $this->assertEquals(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class, $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class)->getClass()); + } + public function testPrototype() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_prototype.yml'); + $ids = \array_keys($container->getDefinitions()); + \sort($ids); + $this->assertSame([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar::class, 'service_container'], $ids); + $resources = $container->getResources(); + $fixturesDir = \dirname(__DIR__) . \DIRECTORY_SEPARATOR . 'Fixtures' . \DIRECTORY_SEPARATOR; + $resources = \array_map('strval', $resources); + $this->assertContains((string) new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\FileResource($fixturesDir . 'yaml' . \DIRECTORY_SEPARATOR . 'services_prototype.yml'), $resources); + $this->assertContains((string) new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\Resource\GlobResource($fixturesDir . 'Prototype', '', \true), $resources); + $this->assertContains('_PhpScoper5ea00cc67502b\\reflection.Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\Foo', $resources); + $this->assertContains('_PhpScoper5ea00cc67502b\\reflection.Symfony\\Component\\DependencyInjection\\Tests\\Fixtures\\Prototype\\Sub\\Bar', $resources); + } + public function testPrototypeWithNamespace() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_prototype_namespace.yml'); + $ids = \array_keys($container->getDefinitions()); + \sort($ids); + $this->assertSame([\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir1\Service1::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir2\Service2::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir1\Service4::class, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir2\Service5::class, 'service_container'], $ids); + $this->assertTrue($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir1\Service1::class)->hasTag('foo')); + $this->assertTrue($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir1\Service4::class)->hasTag('foo')); + $this->assertFalse($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir1\Service1::class)->hasTag('bar')); + $this->assertFalse($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir1\Service4::class)->hasTag('bar')); + $this->assertTrue($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir2\Service2::class)->hasTag('bar')); + $this->assertTrue($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir2\Service5::class)->hasTag('bar')); + $this->assertFalse($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component1\Dir2\Service2::class)->hasTag('foo')); + $this->assertFalse($container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\OtherDir\Component2\Dir2\Service5::class)->hasTag('foo')); + } + public function testPrototypeWithNamespaceAndNoResource() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/A "resource" attribute must be set when the "namespace" attribute is set for service ".+" in .+/'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_prototype_namespace_without_resource.yml'); + } + public function testDefaults() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services28.yml'); + $this->assertFalse($container->getDefinition('with_defaults')->isPublic()); + $this->assertSame(['foo' => [[]]], $container->getDefinition('with_defaults')->getTags()); + $this->assertTrue($container->getDefinition('with_defaults')->isAutowired()); + $this->assertArrayNotHasKey('public', $container->getDefinition('with_defaults')->getChanges()); + $this->assertArrayNotHasKey('autowire', $container->getDefinition('with_defaults')->getChanges()); + $this->assertFalse($container->getAlias('with_defaults_aliased')->isPublic()); + $this->assertFalse($container->getAlias('with_defaults_aliased_short')->isPublic()); + $this->assertFalse($container->getDefinition('_PhpScoper5ea00cc67502b\\Acme\\WithShortCutArgs')->isPublic()); + $this->assertSame(['foo' => [[]]], $container->getDefinition('_PhpScoper5ea00cc67502b\\Acme\\WithShortCutArgs')->getTags()); + $this->assertTrue($container->getDefinition('_PhpScoper5ea00cc67502b\\Acme\\WithShortCutArgs')->isAutowired()); + $container->compile(); + $this->assertTrue($container->getDefinition('with_null')->isPublic()); + $this->assertTrue($container->getDefinition('no_defaults')->isPublic()); + // foo tag is inherited from defaults + $this->assertSame(['foo' => [[]]], $container->getDefinition('with_null')->getTags()); + $this->assertSame(['foo' => [[]]], $container->getDefinition('no_defaults')->getTags()); + $this->assertTrue($container->getDefinition('with_null')->isAutowired()); + $this->assertFalse($container->getDefinition('no_defaults')->isAutowired()); + $this->assertTrue($container->getDefinition('child_def')->isPublic()); + $this->assertSame(['foo' => [[]]], $container->getDefinition('child_def')->getTags()); + $this->assertFalse($container->getDefinition('child_def')->isAutowired()); + } + public function testNamedArguments() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_named_args.yml'); + $this->assertEquals([null, '$apiKey' => 'ABCD'], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getArguments()); + $this->assertEquals(['$apiKey' => 'ABCD', \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\CaseSensitiveClass::class => null], $container->getDefinition('another_one')->getArguments()); + $container->compile(); + $this->assertEquals([null, 'ABCD'], $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\NamedArgumentsDummy::class)->getArguments()); + $this->assertEquals([null, 'ABCD'], $container->getDefinition('another_one')->getArguments()); + $this->assertEquals([['setApiKey', ['123']]], $container->getDefinition('another_one')->getMethodCalls()); + } + public function testInstanceof() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_instanceof.yml'); + $container->compile(); + $definition = $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class); + $this->assertTrue($definition->isAutowired()); + $this->assertTrue($definition->isLazy()); + $this->assertSame(['foo' => [[]], 'bar' => [[]]], $definition->getTags()); + } + public function testInstanceOfAndChildDefinitionNotAllowed() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The service "child_service" cannot use the "parent" option in the same file where "_instanceof" configuration is defined as using both is not supported. Move your child definitions to a separate file.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_instanceof_with_parent.yml'); + $container->compile(); + } + public function testAutoConfigureAndChildDefinitionNotAllowed() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The service "child_service" cannot have a "parent" and also have "autoconfigure". Try setting "autoconfigure: false" for the service.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_autoconfigure_with_parent.yml'); + $container->compile(); + } + public function testDefaultsAndChildDefinitionNotAllowed() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('Attribute "autowire" on service "child_service" cannot be inherited from "_defaults" when a "parent" is set. Move your child definitions to a separate file or define this attribute explicitly.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_defaults_with_parent.yml'); + $container->compile(); + } + public function testDecoratedServicesWithWrongSyntaxThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessage('The value of the "decorates" option for the "bar" service must be the id of the service without the "@" prefix (replace "@foo" with "foo").'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('bad_decorates.yml'); + } + public function testInvalidTagsWithDefaults() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/Parameter "tags" must be an array for service "Foo\\\\Bar" in ".+services31_invalid_tags\\.yml"\\. Check your YAML syntax./'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader(new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(), new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services31_invalid_tags.yml'); + } + /** + * @group legacy + * @expectedDeprecation Service names that start with an underscore are deprecated since Symfony 3.3 and will be reserved in 4.0. Rename the "_foo" service or define it in XML instead. + */ + public function testUnderscoreServiceId() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_underscore.yml'); + } + public function testAnonymousServices() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('anonymous_services.yml'); + $definition = $container->getDefinition('Foo'); + $this->assertTrue($definition->isAutowired()); + // Anonymous service in an argument + $args = $definition->getArguments(); + $this->assertCount(1, $args); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $args[0]); + $this->assertTrue($container->has((string) $args[0])); + $this->assertRegExp('/^\\d+_Bar~[._A-Za-z0-9]{7}$/', (string) $args[0]); + $anonymous = $container->getDefinition((string) $args[0]); + $this->assertEquals('Bar', $anonymous->getClass()); + $this->assertFalse($anonymous->isPublic()); + $this->assertTrue($anonymous->isAutowired()); + // Anonymous service in a callable + $factory = $definition->getFactory(); + $this->assertIsArray($factory); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $factory[0]); + $this->assertTrue($container->has((string) $factory[0])); + $this->assertRegExp('/^\\d+_Quz~[._A-Za-z0-9]{7}$/', (string) $factory[0]); + $this->assertEquals('constructFoo', $factory[1]); + $anonymous = $container->getDefinition((string) $factory[0]); + $this->assertEquals('Quz', $anonymous->getClass()); + $this->assertFalse($anonymous->isPublic()); + $this->assertFalse($anonymous->isAutowired()); + } + public function testAnonymousServicesInDifferentFilesWithSameNameDoNotConflict() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml/foo')); + $loader->load('services.yml'); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml/bar')); + $loader->load('services.yml'); + $this->assertCount(5, $container->getDefinitions()); + } + public function testAnonymousServicesInInstanceof() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('anonymous_services_in_instanceof.yml'); + $definition = $container->getDefinition('Dummy'); + $instanceof = $definition->getInstanceofConditionals(); + $this->assertCount(3, $instanceof); + $this->assertArrayHasKey('DummyInterface', $instanceof); + $args = $instanceof['DummyInterface']->getProperties(); + $this->assertCount(1, $args); + $this->assertInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference::class, $args['foo']); + $this->assertTrue($container->has((string) $args['foo'])); + $anonymous = $container->getDefinition((string) $args['foo']); + $this->assertEquals('Anonymous', $anonymous->getClass()); + $this->assertFalse($anonymous->isPublic()); + $this->assertEmpty($anonymous->getInstanceofConditionals()); + $this->assertFalse($container->has('Bar')); + } + public function testAnonymousServicesWithAliases() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/Creating an alias using the tag "!service" is not allowed in ".+anonymous_services_alias\\.yml"\\./'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('anonymous_services_alias.yml'); + } + public function testAnonymousServicesInParameters() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/Using an anonymous service in a parameter is not allowed in ".+anonymous_services_in_parameters\\.yml"\\./'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('anonymous_services_in_parameters.yml'); + } + public function testAutoConfigureInstanceof() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_autoconfigure.yml'); + $this->assertTrue($container->getDefinition('use_defaults_settings')->isAutoconfigured()); + $this->assertFalse($container->getDefinition('override_defaults_settings_to_false')->isAutoconfigured()); + } + public function testEmptyDefaultsThrowsClearException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/Service "_defaults" key must be an array, "NULL" given in ".+bad_empty_defaults\\.yml"\\./'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('bad_empty_defaults.yml'); + } + public function testEmptyInstanceofThrowsClearException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $this->expectExceptionMessageRegExp('/Service "_instanceof" key must be an array, "NULL" given in ".+bad_empty_instanceof\\.yml"\\./'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('bad_empty_instanceof.yml'); + } + public function testBindings() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('services_bindings.yml'); + $container->compile(); + $definition = $container->getDefinition('bar'); + $this->assertEquals(['NonExistent' => null, \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\BarInterface::class => new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class), '$foo' => [null], '$quz' => 'quz', '$factory' => 'factory'], \array_map(function ($v) { + return $v->getValues()[0]; + }, $definition->getBindings())); + $this->assertEquals(['quz', null, new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class), [null]], $definition->getArguments()); + $definition = $container->getDefinition(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\Fixtures\Bar::class); + $this->assertEquals([null, 'factory'], $definition->getArguments()); + $this->assertEquals(['NonExistent' => null, '$quz' => 'quz', '$factory' => 'factory'], \array_map(function ($v) { + return $v->getValues()[0]; + }, $definition->getBindings())); + } + /** + * The pass may throw an exception, which will cause the test to fail. + */ + public function testOverriddenDefaultsBindings() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('defaults_bindings.yml'); + $loader->load('defaults_bindings2.yml'); + (new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Compiler\ResolveBindingsPass())->process($container); + $this->assertSame('overridden', $container->get('bar')->quz); + } + /** + * @group legacy + * @expectedDeprecation The configuration key "factory" is unsupported for the service "foo" which is defined as an alias in %s. + * @expectedDeprecation The configuration key "parent" is unsupported for the service "foo" which is defined as an alias in %s. + */ + public function testAliasDefinitionContainsUnsupportedElements() + { + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerBuilder(); + $loader = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Loader\YamlFileLoader($container, new \_PhpScoper5ea00cc67502b\Symfony\Component\Config\FileLocator(self::$fixturesPath . '/yaml')); + $loader->load('legacy_invalid_alias_definition.yml'); + $this->assertTrue($container->has('foo')); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/Loader/index.php b/vendor/symfony/dependency-injection/Tests/Loader/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/Loader/index.php +++ b/vendor/symfony/dependency-injection/Tests/Loader/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/ParameterBag/EnvPlaceholderParameterBagTest.php b/vendor/symfony/dependency-injection/Tests/ParameterBag/EnvPlaceholderParameterBagTest.php index bcc311931..1f8f4ae4f 100644 --- a/vendor/symfony/dependency-injection/Tests/ParameterBag/EnvPlaceholderParameterBagTest.php +++ b/vendor/symfony/dependency-injection/Tests/ParameterBag/EnvPlaceholderParameterBagTest.php @@ -1,130 +1,130 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ParameterBag; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; -class EnvPlaceholderParameterBagTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testGetThrowsInvalidArgumentExceptionIfEnvNameContainsNonWordCharacters() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - $bag->get('env(%foo%)'); - } - public function testMergeWillNotDuplicateIdenticalParameters() - { - $envVariableName = 'DB_HOST'; - $parameter = \sprintf('env(%s)', $envVariableName); - $firstBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - // initialize placeholders - $firstBag->get($parameter); - $secondBag = clone $firstBag; - $firstBag->mergeEnvPlaceholders($secondBag); - $mergedPlaceholders = $firstBag->getEnvPlaceholders(); - $placeholderForVariable = $mergedPlaceholders[$envVariableName]; - $placeholder = \array_values($placeholderForVariable)[0]; - $this->assertCount(1, $placeholderForVariable); - $this->assertIsString($placeholder); - $this->assertStringContainsString($envVariableName, $placeholder); - } - public function testMergeWhereFirstBagIsEmptyWillWork() - { - $envVariableName = 'DB_HOST'; - $parameter = \sprintf('env(%s)', $envVariableName); - $firstBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - $secondBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - // initialize placeholder only in second bag - $secondBag->get($parameter); - $this->assertEmpty($firstBag->getEnvPlaceholders()); - $firstBag->mergeEnvPlaceholders($secondBag); - $mergedPlaceholders = $firstBag->getEnvPlaceholders(); - $placeholderForVariable = $mergedPlaceholders[$envVariableName]; - $placeholder = \array_values($placeholderForVariable)[0]; - $this->assertCount(1, $placeholderForVariable); - $this->assertIsString($placeholder); - $this->assertStringContainsString($envVariableName, $placeholder); - } - public function testMergeWherePlaceholderOnlyExistsInSecond() - { - $uniqueEnvName = 'DB_HOST'; - $commonEnvName = 'DB_USER'; - $uniqueParamName = \sprintf('env(%s)', $uniqueEnvName); - $commonParamName = \sprintf('env(%s)', $commonEnvName); - $firstBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - // initialize common placeholder - $firstBag->get($commonParamName); - $secondBag = clone $firstBag; - // initialize unique placeholder - $secondBag->get($uniqueParamName); - $firstBag->mergeEnvPlaceholders($secondBag); - $merged = $firstBag->getEnvPlaceholders(); - $this->assertCount(1, $merged[$uniqueEnvName]); - // second bag has same placeholder for commonEnvName - $this->assertCount(1, $merged[$commonEnvName]); - } - public function testMergeWithDifferentIdentifiersForPlaceholders() - { - $envName = 'DB_USER'; - $paramName = \sprintf('env(%s)', $envName); - $firstBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - $secondBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - // initialize placeholders - $firstPlaceholder = $firstBag->get($paramName); - $secondPlaceholder = $secondBag->get($paramName); - $firstBag->mergeEnvPlaceholders($secondBag); - $merged = $firstBag->getEnvPlaceholders(); - $this->assertNotEquals($firstPlaceholder, $secondPlaceholder); - $this->assertCount(2, $merged[$envName]); - } - public function testResolveEnvCastsIntToString() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - $bag->get('env(INT_VAR)'); - $bag->set('env(INT_VAR)', 2); - $bag->resolve(); - $this->assertSame('2', $bag->all()['env(INT_VAR)']); - } - public function testResolveEnvAllowsNull() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - $bag->get('env(NULL_VAR)'); - $bag->set('env(NULL_VAR)', null); - $bag->resolve(); - $this->assertNull($bag->all()['env(NULL_VAR)']); - } - public function testResolveThrowsOnBadDefaultValue() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('The default value of env parameter "ARRAY_VAR" must be scalar or null, "array" given.'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - $bag->get('env(ARRAY_VAR)'); - $bag->set('env(ARRAY_VAR)', []); - $bag->resolve(); - } - public function testGetEnvAllowsNull() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - $bag->set('env(NULL_VAR)', null); - $bag->get('env(NULL_VAR)'); - $bag->resolve(); - $this->assertNull($bag->all()['env(NULL_VAR)']); - } - public function testGetThrowsOnBadDefaultValue() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); - $this->expectExceptionMessage('The default value of an env() parameter must be scalar or null, but "array" given to "env(ARRAY_VAR)".'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); - $bag->set('env(ARRAY_VAR)', []); - $bag->get('env(ARRAY_VAR)'); - $bag->resolve(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ParameterBag; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag; +class EnvPlaceholderParameterBagTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testGetThrowsInvalidArgumentExceptionIfEnvNameContainsNonWordCharacters() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\InvalidArgumentException'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + $bag->get('env(%foo%)'); + } + public function testMergeWillNotDuplicateIdenticalParameters() + { + $envVariableName = 'DB_HOST'; + $parameter = \sprintf('env(%s)', $envVariableName); + $firstBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + // initialize placeholders + $firstBag->get($parameter); + $secondBag = clone $firstBag; + $firstBag->mergeEnvPlaceholders($secondBag); + $mergedPlaceholders = $firstBag->getEnvPlaceholders(); + $placeholderForVariable = $mergedPlaceholders[$envVariableName]; + $placeholder = \array_values($placeholderForVariable)[0]; + $this->assertCount(1, $placeholderForVariable); + $this->assertIsString($placeholder); + $this->assertStringContainsString($envVariableName, $placeholder); + } + public function testMergeWhereFirstBagIsEmptyWillWork() + { + $envVariableName = 'DB_HOST'; + $parameter = \sprintf('env(%s)', $envVariableName); + $firstBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + $secondBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + // initialize placeholder only in second bag + $secondBag->get($parameter); + $this->assertEmpty($firstBag->getEnvPlaceholders()); + $firstBag->mergeEnvPlaceholders($secondBag); + $mergedPlaceholders = $firstBag->getEnvPlaceholders(); + $placeholderForVariable = $mergedPlaceholders[$envVariableName]; + $placeholder = \array_values($placeholderForVariable)[0]; + $this->assertCount(1, $placeholderForVariable); + $this->assertIsString($placeholder); + $this->assertStringContainsString($envVariableName, $placeholder); + } + public function testMergeWherePlaceholderOnlyExistsInSecond() + { + $uniqueEnvName = 'DB_HOST'; + $commonEnvName = 'DB_USER'; + $uniqueParamName = \sprintf('env(%s)', $uniqueEnvName); + $commonParamName = \sprintf('env(%s)', $commonEnvName); + $firstBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + // initialize common placeholder + $firstBag->get($commonParamName); + $secondBag = clone $firstBag; + // initialize unique placeholder + $secondBag->get($uniqueParamName); + $firstBag->mergeEnvPlaceholders($secondBag); + $merged = $firstBag->getEnvPlaceholders(); + $this->assertCount(1, $merged[$uniqueEnvName]); + // second bag has same placeholder for commonEnvName + $this->assertCount(1, $merged[$commonEnvName]); + } + public function testMergeWithDifferentIdentifiersForPlaceholders() + { + $envName = 'DB_USER'; + $paramName = \sprintf('env(%s)', $envName); + $firstBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + $secondBag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + // initialize placeholders + $firstPlaceholder = $firstBag->get($paramName); + $secondPlaceholder = $secondBag->get($paramName); + $firstBag->mergeEnvPlaceholders($secondBag); + $merged = $firstBag->getEnvPlaceholders(); + $this->assertNotEquals($firstPlaceholder, $secondPlaceholder); + $this->assertCount(2, $merged[$envName]); + } + public function testResolveEnvCastsIntToString() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + $bag->get('env(INT_VAR)'); + $bag->set('env(INT_VAR)', 2); + $bag->resolve(); + $this->assertSame('2', $bag->all()['env(INT_VAR)']); + } + public function testResolveEnvAllowsNull() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + $bag->get('env(NULL_VAR)'); + $bag->set('env(NULL_VAR)', null); + $bag->resolve(); + $this->assertNull($bag->all()['env(NULL_VAR)']); + } + public function testResolveThrowsOnBadDefaultValue() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('The default value of env parameter "ARRAY_VAR" must be scalar or null, "array" given.'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + $bag->get('env(ARRAY_VAR)'); + $bag->set('env(ARRAY_VAR)', []); + $bag->resolve(); + } + public function testGetEnvAllowsNull() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + $bag->set('env(NULL_VAR)', null); + $bag->get('env(NULL_VAR)'); + $bag->resolve(); + $this->assertNull($bag->all()['env(NULL_VAR)']); + } + public function testGetThrowsOnBadDefaultValue() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException'); + $this->expectExceptionMessage('The default value of an env() parameter must be scalar or null, but "array" given to "env(ARRAY_VAR)".'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\EnvPlaceholderParameterBag(); + $bag->set('env(ARRAY_VAR)', []); + $bag->get('env(ARRAY_VAR)'); + $bag->resolve(); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/ParameterBag/FrozenParameterBagTest.php b/vendor/symfony/dependency-injection/Tests/ParameterBag/FrozenParameterBagTest.php index 7b034c985..5691eb54b 100644 --- a/vendor/symfony/dependency-injection/Tests/ParameterBag/FrozenParameterBagTest.php +++ b/vendor/symfony/dependency-injection/Tests/ParameterBag/FrozenParameterBagTest.php @@ -1,47 +1,47 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ParameterBag; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag; -class FrozenParameterBagTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructor() - { - $parameters = ['foo' => 'foo', 'bar' => 'bar']; - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); - $this->assertEquals($parameters, $bag->all(), '__construct() takes an array of parameters as its first argument'); - } - public function testClear() - { - $this->expectException('LogicException'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag([]); - $bag->clear(); - } - public function testSet() - { - $this->expectException('LogicException'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag([]); - $bag->set('foo', 'bar'); - } - public function testAdd() - { - $this->expectException('LogicException'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag([]); - $bag->add([]); - } - public function testRemove() - { - $this->expectException('LogicException'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag(['foo' => 'bar']); - $bag->remove('foo'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ParameterBag; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag; +class FrozenParameterBagTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructor() + { + $parameters = ['foo' => 'foo', 'bar' => 'bar']; + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag($parameters); + $this->assertEquals($parameters, $bag->all(), '__construct() takes an array of parameters as its first argument'); + } + public function testClear() + { + $this->expectException('LogicException'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag([]); + $bag->clear(); + } + public function testSet() + { + $this->expectException('LogicException'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag([]); + $bag->set('foo', 'bar'); + } + public function testAdd() + { + $this->expectException('LogicException'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag([]); + $bag->add([]); + } + public function testRemove() + { + $this->expectException('LogicException'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag(['foo' => 'bar']); + $bag->remove('foo'); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/ParameterBag/ParameterBagTest.php b/vendor/symfony/dependency-injection/Tests/ParameterBag/ParameterBagTest.php index fee97f6ee..765bfcf4b 100644 --- a/vendor/symfony/dependency-injection/Tests/ParameterBag/ParameterBagTest.php +++ b/vendor/symfony/dependency-injection/Tests/ParameterBag/ParameterBagTest.php @@ -1,190 +1,190 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ParameterBag; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; -class ParameterBagTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructor() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($parameters = ['foo' => 'foo', 'bar' => 'bar']); - $this->assertEquals($parameters, $bag->all(), '__construct() takes an array of parameters as its first argument'); - } - public function testClear() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($parameters = ['foo' => 'foo', 'bar' => 'bar']); - $bag->clear(); - $this->assertEquals([], $bag->all(), '->clear() removes all parameters'); - } - public function testRemove() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'foo', 'bar' => 'bar']); - $bag->remove('foo'); - $this->assertEquals(['bar' => 'bar'], $bag->all(), '->remove() removes a parameter'); - } - public function testGetSet() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar']); - $bag->set('bar', 'foo'); - $this->assertEquals('foo', $bag->get('bar'), '->set() sets the value of a new parameter'); - $bag->set('foo', 'baz'); - $this->assertEquals('baz', $bag->get('foo'), '->set() overrides previously set parameter'); - try { - $bag->get('baba'); - $this->fail('->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException if the key does not exist'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException', $e, '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException if the key does not exist'); - $this->assertEquals('You have requested a non-existent parameter "baba".', $e->getMessage(), '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException if the key does not exist'); - } - } - /** - * @dataProvider provideGetThrowParameterNotFoundExceptionData - */ - public function testGetThrowParameterNotFoundException($parameterKey, $exceptionMessage) - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'foo', 'bar' => 'bar', 'baz' => 'baz', 'fiz' => ['bar' => ['boo' => 12]]]); - $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException::class); - $this->expectExceptionMessage($exceptionMessage); - $bag->get($parameterKey); - } - public function provideGetThrowParameterNotFoundExceptionData() - { - return [['foo1', 'You have requested a non-existent parameter "foo1". Did you mean this: "foo"?'], ['bag', 'You have requested a non-existent parameter "bag". Did you mean one of these: "bar", "baz"?'], ['', 'You have requested a non-existent parameter "".'], ['fiz.bar.boo', 'You have requested a non-existent parameter "fiz.bar.boo". You cannot access nested array items, do you want to inject "fiz" instead?']]; - } - public function testHas() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar']); - $this->assertTrue($bag->has('foo'), '->has() returns true if a parameter is defined'); - $this->assertFalse($bag->has('bar'), '->has() returns false if a parameter is not defined'); - } - /** - * @group legacy - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "BAR" instead of "bar" is deprecated since Symfony 3.4. - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "Foo" instead of "foo" is deprecated since Symfony 3.4. - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "FOO" instead of "foo" is deprecated since Symfony 3.4. - * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "Foo" instead of "foo" is deprecated since Symfony 3.4. - */ - public function testMixedCase() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'foo', 'bar' => 'bar']); - $bag->remove('BAR'); - $this->assertEquals(['foo' => 'foo'], $bag->all(), '->remove() converts key to lowercase before removing'); - $bag->set('Foo', 'baz1'); - $this->assertEquals('baz1', $bag->get('foo'), '->set() converts the key to lowercase'); - $this->assertEquals('baz1', $bag->get('FOO'), '->get() converts the key to lowercase'); - $this->assertTrue($bag->has('Foo'), '->has() converts the key to lowercase'); - } - public function testResolveValue() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag([]); - $this->assertEquals('foo', $bag->resolveValue('foo'), '->resolveValue() returns its argument unmodified if no placeholders are found'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar']); - $this->assertEquals('I\'m a bar', $bag->resolveValue('I\'m a %foo%'), '->resolveValue() replaces placeholders by their values'); - $this->assertEquals(['bar' => 'bar'], $bag->resolveValue(['%foo%' => '%foo%']), '->resolveValue() replaces placeholders in keys and values of arrays'); - $this->assertEquals(['bar' => ['bar' => ['bar' => 'bar']]], $bag->resolveValue(['%foo%' => ['%foo%' => ['%foo%' => '%foo%']]]), '->resolveValue() replaces placeholders in nested arrays'); - $this->assertEquals('I\'m a %%foo%%', $bag->resolveValue('I\'m a %%foo%%'), '->resolveValue() supports % escaping by doubling it'); - $this->assertEquals('I\'m a bar %%foo bar', $bag->resolveValue('I\'m a %foo% %%foo %foo%'), '->resolveValue() supports % escaping by doubling it'); - $this->assertEquals(['foo' => ['bar' => ['ding' => 'I\'m a bar %%foo %%bar']]], $bag->resolveValue(['foo' => ['bar' => ['ding' => 'I\'m a bar %%foo %%bar']]]), '->resolveValue() supports % escaping by doubling it'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => \true]); - $this->assertTrue($bag->resolveValue('%foo%'), '->resolveValue() replaces arguments that are just a placeholder by their value without casting them to strings'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => null]); - $this->assertNull($bag->resolveValue('%foo%'), '->resolveValue() replaces arguments that are just a placeholder by their value without casting them to strings'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar', 'baz' => '%%%foo% %foo%%% %%foo%% %%%foo%%%']); - $this->assertEquals('%%bar bar%% %%foo%% %%bar%%', $bag->resolveValue('%baz%'), '->resolveValue() replaces params placed besides escaped %'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['baz' => '%%s?%%s']); - $this->assertEquals('%%s?%%s', $bag->resolveValue('%baz%'), '->resolveValue() is not replacing greedily'); - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag([]); - try { - $bag->resolveValue('%foobar%'); - $this->fail('->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existent parameter'); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { - $this->assertEquals('You have requested a non-existent parameter "foobar".', $e->getMessage(), '->resolveValue() throws a ParameterNotFoundException if a placeholder references a non-existent parameter'); - } - try { - $bag->resolveValue('foo %foobar% bar'); - $this->fail('->resolveValue() throws a ParameterNotFoundException if a placeholder references a non-existent parameter'); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { - $this->assertEquals('You have requested a non-existent parameter "foobar".', $e->getMessage(), '->resolveValue() throws a ParameterNotFoundException if a placeholder references a non-existent parameter'); - } - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'a %bar%', 'bar' => []]); - try { - $bag->resolveValue('%foo%'); - $this->fail('->resolveValue() throws a RuntimeException when a parameter embeds another non-string parameter'); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { - $this->assertEquals('A string value must be composed of strings and/or numbers, but found parameter "bar" of type "array" inside string value "a %bar%".', $e->getMessage(), '->resolveValue() throws a RuntimeException when a parameter embeds another non-string parameter'); - } - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => '%bar%', 'bar' => '%foobar%', 'foobar' => '%foo%']); - try { - $bag->resolveValue('%foo%'); - $this->fail('->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException $e) { - $this->assertEquals('Circular reference detected for parameter "foo" ("foo" > "bar" > "foobar" > "foo").', $e->getMessage(), '->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); - } - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'a %bar%', 'bar' => 'a %foobar%', 'foobar' => 'a %foo%']); - try { - $bag->resolveValue('%foo%'); - $this->fail('->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException $e) { - $this->assertEquals('Circular reference detected for parameter "foo" ("foo" > "bar" > "foobar" > "foo").', $e->getMessage(), '->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); - } - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['host' => 'foo.bar', 'port' => 1337]); - $this->assertEquals('foo.bar:1337', $bag->resolveValue('%host%:%port%')); - } - public function testResolveIndicatesWhyAParameterIsNeeded() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => '%bar%']); - try { - $bag->resolve(); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { - $this->assertEquals('The parameter "foo" has a dependency on a non-existent parameter "bar".', $e->getMessage()); - } - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => '%bar%']); - try { - $bag->resolve(); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { - $this->assertEquals('The parameter "foo" has a dependency on a non-existent parameter "bar".', $e->getMessage()); - } - } - public function testResolveUnescapesValue() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => ['bar' => ['ding' => 'I\'m a bar %%foo %%bar']], 'bar' => 'I\'m a %%foo%%']); - $bag->resolve(); - $this->assertEquals('I\'m a %foo%', $bag->get('bar'), '->resolveValue() supports % escaping by doubling it'); - $this->assertEquals(['bar' => ['ding' => 'I\'m a bar %foo %bar']], $bag->get('foo'), '->resolveValue() supports % escaping by doubling it'); - } - public function testEscapeValue() - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(); - $bag->add(['foo' => $bag->escapeValue(['bar' => ['ding' => 'I\'m a bar %foo %bar', 'zero' => null]]), 'bar' => $bag->escapeValue('I\'m a %foo%')]); - $this->assertEquals('I\'m a %%foo%%', $bag->get('bar'), '->escapeValue() escapes % by doubling it'); - $this->assertEquals(['bar' => ['ding' => 'I\'m a bar %%foo %%bar', 'zero' => null]], $bag->get('foo'), '->escapeValue() escapes % by doubling it'); - } - /** - * @dataProvider stringsWithSpacesProvider - */ - public function testResolveStringWithSpacesReturnsString($expected, $test, $description) - { - $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar']); - try { - $this->assertEquals($expected, $bag->resolveString($test), $description); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { - $this->fail(\sprintf('%s - "%s"', $description, $expected)); - } - } - public function stringsWithSpacesProvider() - { - return [['bar', '%foo%', 'Parameters must be wrapped by %.'], ['% foo %', '% foo %', 'Parameters should not have spaces.'], ['{% set my_template = "foo" %}', '{% set my_template = "foo" %}', 'Twig-like strings are not parameters.'], ['50% is less than 100%', '50% is less than 100%', 'Text between % signs is allowed, if there are spaces.']]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\ParameterBag; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag; +class ParameterBagTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructor() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($parameters = ['foo' => 'foo', 'bar' => 'bar']); + $this->assertEquals($parameters, $bag->all(), '__construct() takes an array of parameters as its first argument'); + } + public function testClear() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag($parameters = ['foo' => 'foo', 'bar' => 'bar']); + $bag->clear(); + $this->assertEquals([], $bag->all(), '->clear() removes all parameters'); + } + public function testRemove() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'foo', 'bar' => 'bar']); + $bag->remove('foo'); + $this->assertEquals(['bar' => 'bar'], $bag->all(), '->remove() removes a parameter'); + } + public function testGetSet() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar']); + $bag->set('bar', 'foo'); + $this->assertEquals('foo', $bag->get('bar'), '->set() sets the value of a new parameter'); + $bag->set('foo', 'baz'); + $this->assertEquals('baz', $bag->get('foo'), '->set() overrides previously set parameter'); + try { + $bag->get('baba'); + $this->fail('->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException if the key does not exist'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException', $e, '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException if the key does not exist'); + $this->assertEquals('You have requested a non-existent parameter "baba".', $e->getMessage(), '->get() throws an Symfony\\Component\\DependencyInjection\\Exception\\ParameterNotFoundException if the key does not exist'); + } + } + /** + * @dataProvider provideGetThrowParameterNotFoundExceptionData + */ + public function testGetThrowParameterNotFoundException($parameterKey, $exceptionMessage) + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'foo', 'bar' => 'bar', 'baz' => 'baz', 'fiz' => ['bar' => ['boo' => 12]]]); + $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException::class); + $this->expectExceptionMessage($exceptionMessage); + $bag->get($parameterKey); + } + public function provideGetThrowParameterNotFoundExceptionData() + { + return [['foo1', 'You have requested a non-existent parameter "foo1". Did you mean this: "foo"?'], ['bag', 'You have requested a non-existent parameter "bag". Did you mean one of these: "bar", "baz"?'], ['', 'You have requested a non-existent parameter "".'], ['fiz.bar.boo', 'You have requested a non-existent parameter "fiz.bar.boo". You cannot access nested array items, do you want to inject "fiz" instead?']]; + } + public function testHas() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar']); + $this->assertTrue($bag->has('foo'), '->has() returns true if a parameter is defined'); + $this->assertFalse($bag->has('bar'), '->has() returns false if a parameter is not defined'); + } + /** + * @group legacy + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "BAR" instead of "bar" is deprecated since Symfony 3.4. + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "Foo" instead of "foo" is deprecated since Symfony 3.4. + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "FOO" instead of "foo" is deprecated since Symfony 3.4. + * @expectedDeprecation Parameter names will be made case sensitive in Symfony 4.0. Using "Foo" instead of "foo" is deprecated since Symfony 3.4. + */ + public function testMixedCase() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'foo', 'bar' => 'bar']); + $bag->remove('BAR'); + $this->assertEquals(['foo' => 'foo'], $bag->all(), '->remove() converts key to lowercase before removing'); + $bag->set('Foo', 'baz1'); + $this->assertEquals('baz1', $bag->get('foo'), '->set() converts the key to lowercase'); + $this->assertEquals('baz1', $bag->get('FOO'), '->get() converts the key to lowercase'); + $this->assertTrue($bag->has('Foo'), '->has() converts the key to lowercase'); + } + public function testResolveValue() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag([]); + $this->assertEquals('foo', $bag->resolveValue('foo'), '->resolveValue() returns its argument unmodified if no placeholders are found'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar']); + $this->assertEquals('I\'m a bar', $bag->resolveValue('I\'m a %foo%'), '->resolveValue() replaces placeholders by their values'); + $this->assertEquals(['bar' => 'bar'], $bag->resolveValue(['%foo%' => '%foo%']), '->resolveValue() replaces placeholders in keys and values of arrays'); + $this->assertEquals(['bar' => ['bar' => ['bar' => 'bar']]], $bag->resolveValue(['%foo%' => ['%foo%' => ['%foo%' => '%foo%']]]), '->resolveValue() replaces placeholders in nested arrays'); + $this->assertEquals('I\'m a %%foo%%', $bag->resolveValue('I\'m a %%foo%%'), '->resolveValue() supports % escaping by doubling it'); + $this->assertEquals('I\'m a bar %%foo bar', $bag->resolveValue('I\'m a %foo% %%foo %foo%'), '->resolveValue() supports % escaping by doubling it'); + $this->assertEquals(['foo' => ['bar' => ['ding' => 'I\'m a bar %%foo %%bar']]], $bag->resolveValue(['foo' => ['bar' => ['ding' => 'I\'m a bar %%foo %%bar']]]), '->resolveValue() supports % escaping by doubling it'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => \true]); + $this->assertTrue($bag->resolveValue('%foo%'), '->resolveValue() replaces arguments that are just a placeholder by their value without casting them to strings'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => null]); + $this->assertNull($bag->resolveValue('%foo%'), '->resolveValue() replaces arguments that are just a placeholder by their value without casting them to strings'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar', 'baz' => '%%%foo% %foo%%% %%foo%% %%%foo%%%']); + $this->assertEquals('%%bar bar%% %%foo%% %%bar%%', $bag->resolveValue('%baz%'), '->resolveValue() replaces params placed besides escaped %'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['baz' => '%%s?%%s']); + $this->assertEquals('%%s?%%s', $bag->resolveValue('%baz%'), '->resolveValue() is not replacing greedily'); + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag([]); + try { + $bag->resolveValue('%foobar%'); + $this->fail('->resolveValue() throws an InvalidArgumentException if a placeholder references a non-existent parameter'); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { + $this->assertEquals('You have requested a non-existent parameter "foobar".', $e->getMessage(), '->resolveValue() throws a ParameterNotFoundException if a placeholder references a non-existent parameter'); + } + try { + $bag->resolveValue('foo %foobar% bar'); + $this->fail('->resolveValue() throws a ParameterNotFoundException if a placeholder references a non-existent parameter'); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { + $this->assertEquals('You have requested a non-existent parameter "foobar".', $e->getMessage(), '->resolveValue() throws a ParameterNotFoundException if a placeholder references a non-existent parameter'); + } + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'a %bar%', 'bar' => []]); + try { + $bag->resolveValue('%foo%'); + $this->fail('->resolveValue() throws a RuntimeException when a parameter embeds another non-string parameter'); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\RuntimeException $e) { + $this->assertEquals('A string value must be composed of strings and/or numbers, but found parameter "bar" of type "array" inside string value "a %bar%".', $e->getMessage(), '->resolveValue() throws a RuntimeException when a parameter embeds another non-string parameter'); + } + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => '%bar%', 'bar' => '%foobar%', 'foobar' => '%foo%']); + try { + $bag->resolveValue('%foo%'); + $this->fail('->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException $e) { + $this->assertEquals('Circular reference detected for parameter "foo" ("foo" > "bar" > "foobar" > "foo").', $e->getMessage(), '->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); + } + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'a %bar%', 'bar' => 'a %foobar%', 'foobar' => 'a %foo%']); + try { + $bag->resolveValue('%foo%'); + $this->fail('->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterCircularReferenceException $e) { + $this->assertEquals('Circular reference detected for parameter "foo" ("foo" > "bar" > "foobar" > "foo").', $e->getMessage(), '->resolveValue() throws a ParameterCircularReferenceException when a parameter has a circular reference'); + } + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['host' => 'foo.bar', 'port' => 1337]); + $this->assertEquals('foo.bar:1337', $bag->resolveValue('%host%:%port%')); + } + public function testResolveIndicatesWhyAParameterIsNeeded() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => '%bar%']); + try { + $bag->resolve(); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { + $this->assertEquals('The parameter "foo" has a dependency on a non-existent parameter "bar".', $e->getMessage()); + } + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => '%bar%']); + try { + $bag->resolve(); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { + $this->assertEquals('The parameter "foo" has a dependency on a non-existent parameter "bar".', $e->getMessage()); + } + } + public function testResolveUnescapesValue() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => ['bar' => ['ding' => 'I\'m a bar %%foo %%bar']], 'bar' => 'I\'m a %%foo%%']); + $bag->resolve(); + $this->assertEquals('I\'m a %foo%', $bag->get('bar'), '->resolveValue() supports % escaping by doubling it'); + $this->assertEquals(['bar' => ['ding' => 'I\'m a bar %foo %bar']], $bag->get('foo'), '->resolveValue() supports % escaping by doubling it'); + } + public function testEscapeValue() + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(); + $bag->add(['foo' => $bag->escapeValue(['bar' => ['ding' => 'I\'m a bar %foo %bar', 'zero' => null]]), 'bar' => $bag->escapeValue('I\'m a %foo%')]); + $this->assertEquals('I\'m a %%foo%%', $bag->get('bar'), '->escapeValue() escapes % by doubling it'); + $this->assertEquals(['bar' => ['ding' => 'I\'m a bar %%foo %%bar', 'zero' => null]], $bag->get('foo'), '->escapeValue() escapes % by doubling it'); + } + /** + * @dataProvider stringsWithSpacesProvider + */ + public function testResolveStringWithSpacesReturnsString($expected, $test, $description) + { + $bag = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ParameterBag\ParameterBag(['foo' => 'bar']); + try { + $this->assertEquals($expected, $bag->resolveString($test), $description); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException $e) { + $this->fail(\sprintf('%s - "%s"', $description, $expected)); + } + } + public function stringsWithSpacesProvider() + { + return [['bar', '%foo%', 'Parameters must be wrapped by %.'], ['% foo %', '% foo %', 'Parameters should not have spaces.'], ['{% set my_template = "foo" %}', '{% set my_template = "foo" %}', 'Twig-like strings are not parameters.'], ['50% is less than 100%', '50% is less than 100%', 'Text between % signs is allowed, if there are spaces.']]; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/ParameterBag/index.php b/vendor/symfony/dependency-injection/Tests/ParameterBag/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/ParameterBag/index.php +++ b/vendor/symfony/dependency-injection/Tests/ParameterBag/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/Tests/ParameterTest.php b/vendor/symfony/dependency-injection/Tests/ParameterTest.php index 669e9bae9..c4954e1ca 100644 --- a/vendor/symfony/dependency-injection/Tests/ParameterTest.php +++ b/vendor/symfony/dependency-injection/Tests/ParameterTest.php @@ -1,22 +1,22 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; -class ParameterTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructor() - { - $ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter('foo'); - $this->assertEquals('foo', (string) $ref, '__construct() sets the id of the parameter, which is used for the __toString() method'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter; +class ParameterTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructor() + { + $ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Parameter('foo'); + $this->assertEquals('foo', (string) $ref, '__construct() sets the id of the parameter, which is used for the __toString() method'); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/ReferenceTest.php b/vendor/symfony/dependency-injection/Tests/ReferenceTest.php index 94ebd0108..5799b6591 100644 --- a/vendor/symfony/dependency-injection/Tests/ReferenceTest.php +++ b/vendor/symfony/dependency-injection/Tests/ReferenceTest.php @@ -1,22 +1,22 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; -class ReferenceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructor() - { - $ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'); - $this->assertEquals('foo', (string) $ref, '__construct() sets the id of the reference, which is used for the __toString() method'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference; +class ReferenceTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructor() + { + $ref = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference('foo'); + $this->assertEquals('foo', (string) $ref, '__construct() sets the id of the reference, which is used for the __toString() method'); + } +} diff --git a/vendor/symfony/dependency-injection/Tests/ServiceLocatorTest.php b/vendor/symfony/dependency-injection/Tests/ServiceLocatorTest.php index 45abab8bc..820be3b94 100644 --- a/vendor/symfony/dependency-injection/Tests/ServiceLocatorTest.php +++ b/vendor/symfony/dependency-injection/Tests/ServiceLocatorTest.php @@ -1,131 +1,131 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; -use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface; -class ServiceLocatorTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testHas() - { - $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () { - return 'bar'; - }, 'bar' => function () { - return 'baz'; - }, function () { - return 'dummy'; - }]); - $this->assertTrue($locator->has('foo')); - $this->assertTrue($locator->has('bar')); - $this->assertFalse($locator->has('dummy')); - } - public function testGet() - { - $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () { - return 'bar'; - }, 'bar' => function () { - return 'baz'; - }]); - $this->assertSame('bar', $locator->get('foo')); - $this->assertSame('baz', $locator->get('bar')); - } - public function testGetDoesNotMemoize() - { - $i = 0; - $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () use(&$i) { - ++$i; - return 'bar'; - }]); - $this->assertSame('bar', $locator->get('foo')); - $this->assertSame('bar', $locator->get('foo')); - $this->assertSame(2, $i); - } - public function testGetThrowsOnUndefinedService() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Psr\\Container\\NotFoundExceptionInterface'); - $this->expectExceptionMessage('Service "dummy" not found: the container inside "Symfony\\Component\\DependencyInjection\\Tests\\ServiceLocatorTest" is a smaller service locator that only knows about the "foo" and "bar" services.'); - $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () { - return 'bar'; - }, 'bar' => function () { - return 'baz'; - }]); - $locator->get('dummy'); - } - public function testThrowsOnUndefinedInternalService() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Psr\\Container\\NotFoundExceptionInterface'); - $this->expectExceptionMessage('The service "foo" has a dependency on a non-existent service "bar". This locator only knows about the "foo" service.'); - $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () use(&$locator) { - return $locator->get('bar'); - }]); - $locator->get('foo'); - } - public function testThrowsOnCircularReference() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); - $this->expectExceptionMessage('Circular reference detected for service "bar", path: "bar -> baz -> bar".'); - $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () use(&$locator) { - return $locator->get('bar'); - }, 'bar' => function () use(&$locator) { - return $locator->get('baz'); - }, 'baz' => function () use(&$locator) { - return $locator->get('bar'); - }]); - $locator->get('foo'); - } - public function testThrowsInServiceSubscriber() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Psr\\Container\\NotFoundExceptionInterface'); - $this->expectExceptionMessage('Service "foo" not found: even though it exists in the app\'s container, the container inside "caller" is a smaller service locator that only knows about the "bar" service. Unless you need extra laziness, try using dependency injection instead. Otherwise, you need to declare it using "SomeServiceSubscriber::getSubscribedServices()".'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $container->set('foo', new \stdClass()); - $subscriber = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\SomeServiceSubscriber(); - $subscriber->container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['bar' => function () { - }]); - $subscriber->container = $subscriber->container->withContext('caller', $container); - $subscriber->getFoo(); - } - public function testGetThrowsServiceNotFoundException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); - $this->expectExceptionMessage('Service "foo" not found: even though it exists in the app\'s container, the container inside "foo" is a smaller service locator that is empty... Try using dependency injection instead.'); - $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); - $container->set('foo', new \stdClass()); - $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator([]); - $locator = $locator->withContext('foo', $container); - $locator->get('foo'); - } - public function testInvoke() - { - $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () { - return 'bar'; - }, 'bar' => function () { - return 'baz'; - }]); - $this->assertSame('bar', $locator('foo')); - $this->assertSame('baz', $locator('bar')); - $this->assertNull($locator('dummy'), '->__invoke() should return null on invalid service'); - } -} -class SomeServiceSubscriber implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface -{ - public $container; - public function getFoo() - { - return $this->container->get('foo'); - } - public static function getSubscribedServices() - { - return ['bar' => 'stdClass']; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator; +use _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface; +class ServiceLocatorTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testHas() + { + $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () { + return 'bar'; + }, 'bar' => function () { + return 'baz'; + }, function () { + return 'dummy'; + }]); + $this->assertTrue($locator->has('foo')); + $this->assertTrue($locator->has('bar')); + $this->assertFalse($locator->has('dummy')); + } + public function testGet() + { + $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () { + return 'bar'; + }, 'bar' => function () { + return 'baz'; + }]); + $this->assertSame('bar', $locator->get('foo')); + $this->assertSame('baz', $locator->get('bar')); + } + public function testGetDoesNotMemoize() + { + $i = 0; + $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () use(&$i) { + ++$i; + return 'bar'; + }]); + $this->assertSame('bar', $locator->get('foo')); + $this->assertSame('bar', $locator->get('foo')); + $this->assertSame(2, $i); + } + public function testGetThrowsOnUndefinedService() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Psr\\Container\\NotFoundExceptionInterface'); + $this->expectExceptionMessage('Service "dummy" not found: the container inside "Symfony\\Component\\DependencyInjection\\Tests\\ServiceLocatorTest" is a smaller service locator that only knows about the "foo" and "bar" services.'); + $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () { + return 'bar'; + }, 'bar' => function () { + return 'baz'; + }]); + $locator->get('dummy'); + } + public function testThrowsOnUndefinedInternalService() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Psr\\Container\\NotFoundExceptionInterface'); + $this->expectExceptionMessage('The service "foo" has a dependency on a non-existent service "bar". This locator only knows about the "foo" service.'); + $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () use(&$locator) { + return $locator->get('bar'); + }]); + $locator->get('foo'); + } + public function testThrowsOnCircularReference() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceCircularReferenceException'); + $this->expectExceptionMessage('Circular reference detected for service "bar", path: "bar -> baz -> bar".'); + $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () use(&$locator) { + return $locator->get('bar'); + }, 'bar' => function () use(&$locator) { + return $locator->get('baz'); + }, 'baz' => function () use(&$locator) { + return $locator->get('bar'); + }]); + $locator->get('foo'); + } + public function testThrowsInServiceSubscriber() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Psr\\Container\\NotFoundExceptionInterface'); + $this->expectExceptionMessage('Service "foo" not found: even though it exists in the app\'s container, the container inside "caller" is a smaller service locator that only knows about the "bar" service. Unless you need extra laziness, try using dependency injection instead. Otherwise, you need to declare it using "SomeServiceSubscriber::getSubscribedServices()".'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $container->set('foo', new \stdClass()); + $subscriber = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Tests\SomeServiceSubscriber(); + $subscriber->container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['bar' => function () { + }]); + $subscriber->container = $subscriber->container->withContext('caller', $container); + $subscriber->getFoo(); + } + public function testGetThrowsServiceNotFoundException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\Exception\\ServiceNotFoundException'); + $this->expectExceptionMessage('Service "foo" not found: even though it exists in the app\'s container, the container inside "foo" is a smaller service locator that is empty... Try using dependency injection instead.'); + $container = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Container(); + $container->set('foo', new \stdClass()); + $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator([]); + $locator = $locator->withContext('foo', $container); + $locator->get('foo'); + } + public function testInvoke() + { + $locator = new \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceLocator(['foo' => function () { + return 'bar'; + }, 'bar' => function () { + return 'baz'; + }]); + $this->assertSame('bar', $locator('foo')); + $this->assertSame('baz', $locator('bar')); + $this->assertNull($locator('dummy'), '->__invoke() should return null on invalid service'); + } +} +class SomeServiceSubscriber implements \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ServiceSubscriberInterface +{ + public $container; + public function getFoo() + { + return $this->container->get('foo'); + } + public static function getSubscribedServices() + { + return ['bar' => 'stdClass']; + } +} diff --git a/vendor/symfony/dependency-injection/Tests/index.php b/vendor/symfony/dependency-injection/Tests/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/Tests/index.php +++ b/vendor/symfony/dependency-injection/Tests/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/TypedReference.php b/vendor/symfony/dependency-injection/TypedReference.php index ca4a288ad..658544eab 100644 --- a/vendor/symfony/dependency-injection/TypedReference.php +++ b/vendor/symfony/dependency-injection/TypedReference.php @@ -1,46 +1,46 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -/** - * Represents a PHP type-hinted service reference. - * - * @author Nicolas Grekas - */ -class TypedReference extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference -{ - private $type; - private $requiringClass; - /** - * @param string $id The service identifier - * @param string $type The PHP type of the identified service - * @param string $requiringClass The class of the service that requires the referenced type - * @param int $invalidBehavior The behavior when the service does not exist - */ - public function __construct($id, $type, $requiringClass = '', $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE) - { - parent::__construct($id, $invalidBehavior); - $this->type = $type; - $this->requiringClass = $requiringClass; - } - public function getType() - { - return $this->type; - } - public function getRequiringClass() - { - return $this->requiringClass; - } - public function canBeAutoregistered() - { - return $this->requiringClass && \false !== ($i = \strpos($this->type, '\\')) && 0 === \strncasecmp($this->type, $this->requiringClass, 1 + $i); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +/** + * Represents a PHP type-hinted service reference. + * + * @author Nicolas Grekas + */ +class TypedReference extends \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\Reference +{ + private $type; + private $requiringClass; + /** + * @param string $id The service identifier + * @param string $type The PHP type of the identified service + * @param string $requiringClass The class of the service that requires the referenced type + * @param int $invalidBehavior The behavior when the service does not exist + */ + public function __construct($id, $type, $requiringClass = '', $invalidBehavior = \_PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection\ContainerInterface::EXCEPTION_ON_INVALID_REFERENCE) + { + parent::__construct($id, $invalidBehavior); + $this->type = $type; + $this->requiringClass = $requiringClass; + } + public function getType() + { + return $this->type; + } + public function getRequiringClass() + { + return $this->requiringClass; + } + public function canBeAutoregistered() + { + return $this->requiringClass && \false !== ($i = \strpos($this->type, '\\')) && 0 === \strncasecmp($this->type, $this->requiringClass, 1 + $i); + } +} diff --git a/vendor/symfony/dependency-injection/Variable.php b/vendor/symfony/dependency-injection/Variable.php index 8c5020e62..a73a243f6 100644 --- a/vendor/symfony/dependency-injection/Variable.php +++ b/vendor/symfony/dependency-injection/Variable.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; - -/** - * Represents a variable. - * - * $var = new Variable('a'); - * - * will be dumped as - * - * $a - * - * by the PHP dumper. - * - * @author Johannes M. Schmitt - */ -class Variable -{ - private $name; - /** - * @param string $name - */ - public function __construct($name) - { - $this->name = $name; - } - public function __toString() - { - return $this->name; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\DependencyInjection; + +/** + * Represents a variable. + * + * $var = new Variable('a'); + * + * will be dumped as + * + * $a + * + * by the PHP dumper. + * + * @author Johannes M. Schmitt + */ +class Variable +{ + private $name; + /** + * @param string $name + */ + public function __construct($name) + { + $this->name = $name; + } + public function __toString() + { + return $this->name; + } +} diff --git a/vendor/symfony/dependency-injection/composer.json b/vendor/symfony/dependency-injection/composer.json index 30bc27af3..6aa5c08e9 100644 --- a/vendor/symfony/dependency-injection/composer.json +++ b/vendor/symfony/dependency-injection/composer.json @@ -1,57 +1,57 @@ -{ - "name": "symfony\/dependency-injection", - "type": "library", - "description": "Symfony DependencyInjection Component", - "keywords": [], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": "^5.5.9|>=7.0.8", - "psr\/container": "^1.0" - }, - "require-dev": { - "symfony\/yaml": "~3.4|~4.0", - "symfony\/config": "~3.3|~4.0", - "symfony\/expression-language": "~2.8|~3.0|~4.0" - }, - "suggest": { - "symfony\/yaml": "", - "symfony\/config": "", - "symfony\/finder": "For using double-star glob patterns or when GLOB_BRACE portability is required", - "symfony\/expression-language": "For using expressions in service container configuration", - "symfony\/proxy-manager-bridge": "Generate service proxies to lazy load them" - }, - "conflict": { - "symfony\/config": "<3.3.7", - "symfony\/finder": "<3.3", - "symfony\/proxy-manager-bridge": "<3.4", - "symfony\/yaml": "<3.4" - }, - "provide": { - "psr\/container-implementation": "1.0" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\": "" - }, - "exclude-from-classmap": [ - "\/Tests\/" - ] - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - } +{ + "name": "symfony\/dependency-injection", + "type": "library", + "description": "Symfony DependencyInjection Component", + "keywords": [], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": "^5.5.9|>=7.0.8", + "psr\/container": "^1.0" + }, + "require-dev": { + "symfony\/yaml": "~3.4|~4.0", + "symfony\/config": "~3.3|~4.0", + "symfony\/expression-language": "~2.8|~3.0|~4.0" + }, + "suggest": { + "symfony\/yaml": "", + "symfony\/config": "", + "symfony\/finder": "For using double-star glob patterns or when GLOB_BRACE portability is required", + "symfony\/expression-language": "For using expressions in service container configuration", + "symfony\/proxy-manager-bridge": "Generate service proxies to lazy load them" + }, + "conflict": { + "symfony\/config": "<3.3.7", + "symfony\/finder": "<3.3", + "symfony\/proxy-manager-bridge": "<3.4", + "symfony\/yaml": "<3.4" + }, + "provide": { + "psr\/container-implementation": "1.0" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Component\\DependencyInjection\\": "" + }, + "exclude-from-classmap": [ + "\/Tests\/" + ] + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/dependency-injection/index.php b/vendor/symfony/dependency-injection/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/dependency-injection/index.php +++ b/vendor/symfony/dependency-injection/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/dependency-injection/phpunit.xml.dist b/vendor/symfony/dependency-injection/phpunit.xml.dist index 21dee2a80..0c098b52b 100644 --- a/vendor/symfony/dependency-injection/phpunit.xml.dist +++ b/vendor/symfony/dependency-injection/phpunit.xml.dist @@ -1,31 +1,31 @@ - - - - - - - - - - ./Tests/ - - - - - - ./ - - ./Resources - ./Tests - ./vendor - - - - + + + + + + + + + + ./Tests/ + + + + + + ./ + + ./Resources + ./Tests + ./vendor + + + + diff --git a/vendor/symfony/expression-language/.gitignore b/vendor/symfony/expression-language/.gitignore index c49a5d8df..e31d97a46 100644 --- a/vendor/symfony/expression-language/.gitignore +++ b/vendor/symfony/expression-language/.gitignore @@ -1,3 +1,3 @@ -vendor/ -composer.lock -phpunit.xml +vendor/ +composer.lock +phpunit.xml diff --git a/vendor/symfony/expression-language/CHANGELOG.md b/vendor/symfony/expression-language/CHANGELOG.md index d00d17c77..ea560b421 100644 --- a/vendor/symfony/expression-language/CHANGELOG.md +++ b/vendor/symfony/expression-language/CHANGELOG.md @@ -1,12 +1,12 @@ -CHANGELOG -========= - -2.6.0 ------ - - * Added ExpressionFunction and ExpressionFunctionProviderInterface - -2.4.0 ------ - - * added the component +CHANGELOG +========= + +2.6.0 +----- + + * Added ExpressionFunction and ExpressionFunctionProviderInterface + +2.4.0 +----- + + * added the component diff --git a/vendor/symfony/expression-language/Compiler.php b/vendor/symfony/expression-language/Compiler.php index 42150ec2a..123ba9427 100644 --- a/vendor/symfony/expression-language/Compiler.php +++ b/vendor/symfony/expression-language/Compiler.php @@ -1,126 +1,126 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -/** - * Compiles a node to PHP code. - * - * @author Fabien Potencier - */ -class Compiler -{ - private $source; - private $functions; - public function __construct(array $functions) - { - $this->functions = $functions; - } - public function getFunction($name) - { - return $this->functions[$name]; - } - /** - * Gets the current PHP code after compilation. - * - * @return string The PHP code - */ - public function getSource() - { - return $this->source; - } - public function reset() - { - $this->source = ''; - return $this; - } - /** - * Compiles a node. - * - * @return $this - */ - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $node) - { - $node->compile($this); - return $this; - } - public function subcompile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $node) - { - $current = $this->source; - $this->source = ''; - $node->compile($this); - $source = $this->source; - $this->source = $current; - return $source; - } - /** - * Adds a raw string to the compiled code. - * - * @param string $string The string - * - * @return $this - */ - public function raw($string) - { - $this->source .= $string; - return $this; - } - /** - * Adds a quoted string to the compiled code. - * - * @param string $value The string - * - * @return $this - */ - public function string($value) - { - $this->source .= \sprintf('"%s"', \addcslashes($value, "\0\t\"\$\\")); - return $this; - } - /** - * Returns a PHP representation of a given value. - * - * @param mixed $value The value to convert - * - * @return $this - */ - public function repr($value) - { - if (\is_int($value) || \is_float($value)) { - if (\false !== ($locale = \setlocale(\LC_NUMERIC, 0))) { - \setlocale(\LC_NUMERIC, 'C'); - } - $this->raw($value); - if (\false !== $locale) { - \setlocale(\LC_NUMERIC, $locale); - } - } elseif (null === $value) { - $this->raw('null'); - } elseif (\is_bool($value)) { - $this->raw($value ? 'true' : 'false'); - } elseif (\is_array($value)) { - $this->raw('['); - $first = \true; - foreach ($value as $key => $value) { - if (!$first) { - $this->raw(', '); - } - $first = \false; - $this->repr($key); - $this->raw(' => '); - $this->repr($value); - } - $this->raw(']'); - } else { - $this->string($value); - } - return $this; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +/** + * Compiles a node to PHP code. + * + * @author Fabien Potencier + */ +class Compiler +{ + private $source; + private $functions; + public function __construct(array $functions) + { + $this->functions = $functions; + } + public function getFunction($name) + { + return $this->functions[$name]; + } + /** + * Gets the current PHP code after compilation. + * + * @return string The PHP code + */ + public function getSource() + { + return $this->source; + } + public function reset() + { + $this->source = ''; + return $this; + } + /** + * Compiles a node. + * + * @return $this + */ + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $node) + { + $node->compile($this); + return $this; + } + public function subcompile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $node) + { + $current = $this->source; + $this->source = ''; + $node->compile($this); + $source = $this->source; + $this->source = $current; + return $source; + } + /** + * Adds a raw string to the compiled code. + * + * @param string $string The string + * + * @return $this + */ + public function raw($string) + { + $this->source .= $string; + return $this; + } + /** + * Adds a quoted string to the compiled code. + * + * @param string $value The string + * + * @return $this + */ + public function string($value) + { + $this->source .= \sprintf('"%s"', \addcslashes($value, "\0\t\"\$\\")); + return $this; + } + /** + * Returns a PHP representation of a given value. + * + * @param mixed $value The value to convert + * + * @return $this + */ + public function repr($value) + { + if (\is_int($value) || \is_float($value)) { + if (\false !== ($locale = \setlocale(\LC_NUMERIC, 0))) { + \setlocale(\LC_NUMERIC, 'C'); + } + $this->raw($value); + if (\false !== $locale) { + \setlocale(\LC_NUMERIC, $locale); + } + } elseif (null === $value) { + $this->raw('null'); + } elseif (\is_bool($value)) { + $this->raw($value ? 'true' : 'false'); + } elseif (\is_array($value)) { + $this->raw('['); + $first = \true; + foreach ($value as $key => $value) { + if (!$first) { + $this->raw(', '); + } + $first = \false; + $this->repr($key); + $this->raw(' => '); + $this->repr($value); + } + $this->raw(']'); + } else { + $this->string($value); + } + return $this; + } +} diff --git a/vendor/symfony/expression-language/Expression.php b/vendor/symfony/expression-language/Expression.php index b41b61d84..acad3d419 100644 --- a/vendor/symfony/expression-language/Expression.php +++ b/vendor/symfony/expression-language/Expression.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -/** - * Represents an expression. - * - * @author Fabien Potencier - */ -class Expression -{ - protected $expression; - /** - * @param string $expression An expression - */ - public function __construct($expression) - { - $this->expression = (string) $expression; - } - /** - * Gets the expression. - * - * @return string The expression - */ - public function __toString() - { - return $this->expression; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +/** + * Represents an expression. + * + * @author Fabien Potencier + */ +class Expression +{ + protected $expression; + /** + * @param string $expression An expression + */ + public function __construct($expression) + { + $this->expression = (string) $expression; + } + /** + * Gets the expression. + * + * @return string The expression + */ + public function __toString() + { + return $this->expression; + } +} diff --git a/vendor/symfony/expression-language/ExpressionFunction.php b/vendor/symfony/expression-language/ExpressionFunction.php index 774cee130..e5f6a2b5c 100644 --- a/vendor/symfony/expression-language/ExpressionFunction.php +++ b/vendor/symfony/expression-language/ExpressionFunction.php @@ -1,89 +1,89 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -/** - * Represents a function that can be used in an expression. - * - * A function is defined by two PHP callables. The callables are used - * by the language to compile and/or evaluate the function. - * - * The "compiler" function is used at compilation time and must return a - * PHP representation of the function call (it receives the function - * arguments as arguments). - * - * The "evaluator" function is used for expression evaluation and must return - * the value of the function call based on the values defined for the - * expression (it receives the values as a first argument and the function - * arguments as remaining arguments). - * - * @author Fabien Potencier - */ -class ExpressionFunction -{ - private $name; - private $compiler; - private $evaluator; - /** - * @param string $name The function name - * @param callable $compiler A callable able to compile the function - * @param callable $evaluator A callable able to evaluate the function - */ - public function __construct($name, callable $compiler, callable $evaluator) - { - $this->name = $name; - $this->compiler = $compiler; - $this->evaluator = $evaluator; - } - public function getName() - { - return $this->name; - } - public function getCompiler() - { - return $this->compiler; - } - public function getEvaluator() - { - return $this->evaluator; - } - /** - * Creates an ExpressionFunction from a PHP function name. - * - * @param string $phpFunctionName The PHP function name - * @param string|null $expressionFunctionName The expression function name (default: same than the PHP function name) - * - * @return self - * - * @throws \InvalidArgumentException if given PHP function name does not exist - * @throws \InvalidArgumentException if given PHP function name is in namespace - * and expression function name is not defined - */ - public static function fromPhp($phpFunctionName, $expressionFunctionName = null) - { - $phpFunctionName = \ltrim($phpFunctionName, '\\'); - if (!\function_exists($phpFunctionName)) { - throw new \InvalidArgumentException(\sprintf('PHP function "%s" does not exist.', $phpFunctionName)); - } - $parts = \explode('\\', $phpFunctionName); - if (!$expressionFunctionName && \count($parts) > 1) { - throw new \InvalidArgumentException(\sprintf('An expression function name must be defined when PHP function "%s" is namespaced.', $phpFunctionName)); - } - $compiler = function () use($phpFunctionName) { - return \sprintf('\\%s(%s)', $phpFunctionName, \implode(', ', \func_get_args())); - }; - $evaluator = function () use($phpFunctionName) { - $args = \func_get_args(); - return \call_user_func_array($phpFunctionName, \array_splice($args, 1)); - }; - return new self($expressionFunctionName ?: \end($parts), $compiler, $evaluator); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +/** + * Represents a function that can be used in an expression. + * + * A function is defined by two PHP callables. The callables are used + * by the language to compile and/or evaluate the function. + * + * The "compiler" function is used at compilation time and must return a + * PHP representation of the function call (it receives the function + * arguments as arguments). + * + * The "evaluator" function is used for expression evaluation and must return + * the value of the function call based on the values defined for the + * expression (it receives the values as a first argument and the function + * arguments as remaining arguments). + * + * @author Fabien Potencier + */ +class ExpressionFunction +{ + private $name; + private $compiler; + private $evaluator; + /** + * @param string $name The function name + * @param callable $compiler A callable able to compile the function + * @param callable $evaluator A callable able to evaluate the function + */ + public function __construct($name, callable $compiler, callable $evaluator) + { + $this->name = $name; + $this->compiler = $compiler; + $this->evaluator = $evaluator; + } + public function getName() + { + return $this->name; + } + public function getCompiler() + { + return $this->compiler; + } + public function getEvaluator() + { + return $this->evaluator; + } + /** + * Creates an ExpressionFunction from a PHP function name. + * + * @param string $phpFunctionName The PHP function name + * @param string|null $expressionFunctionName The expression function name (default: same than the PHP function name) + * + * @return self + * + * @throws \InvalidArgumentException if given PHP function name does not exist + * @throws \InvalidArgumentException if given PHP function name is in namespace + * and expression function name is not defined + */ + public static function fromPhp($phpFunctionName, $expressionFunctionName = null) + { + $phpFunctionName = \ltrim($phpFunctionName, '\\'); + if (!\function_exists($phpFunctionName)) { + throw new \InvalidArgumentException(\sprintf('PHP function "%s" does not exist.', $phpFunctionName)); + } + $parts = \explode('\\', $phpFunctionName); + if (!$expressionFunctionName && \count($parts) > 1) { + throw new \InvalidArgumentException(\sprintf('An expression function name must be defined when PHP function "%s" is namespaced.', $phpFunctionName)); + } + $compiler = function () use($phpFunctionName) { + return \sprintf('\\%s(%s)', $phpFunctionName, \implode(', ', \func_get_args())); + }; + $evaluator = function () use($phpFunctionName) { + $args = \func_get_args(); + return \call_user_func_array($phpFunctionName, \array_splice($args, 1)); + }; + return new self($expressionFunctionName ?: \end($parts), $compiler, $evaluator); + } +} diff --git a/vendor/symfony/expression-language/ExpressionFunctionProviderInterface.php b/vendor/symfony/expression-language/ExpressionFunctionProviderInterface.php index 6d23be0f4..fe8b3a7ea 100644 --- a/vendor/symfony/expression-language/ExpressionFunctionProviderInterface.php +++ b/vendor/symfony/expression-language/ExpressionFunctionProviderInterface.php @@ -1,22 +1,22 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -/** - * @author Fabien Potencier - */ -interface ExpressionFunctionProviderInterface -{ - /** - * @return ExpressionFunction[] An array of Function instances - */ - public function getFunctions(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +/** + * @author Fabien Potencier + */ +interface ExpressionFunctionProviderInterface +{ + /** + * @return ExpressionFunction[] An array of Function instances + */ + public function getFunctions(); +} diff --git a/vendor/symfony/expression-language/ExpressionLanguage.php b/vendor/symfony/expression-language/ExpressionLanguage.php index 5365c7450..cfe7ab9cb 100644 --- a/vendor/symfony/expression-language/ExpressionLanguage.php +++ b/vendor/symfony/expression-language/ExpressionLanguage.php @@ -1,153 +1,153 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheInterface; -/** - * Allows to compile and evaluate expressions written in your own DSL. - * - * @author Fabien Potencier - */ -class ExpressionLanguage -{ - private $cache; - private $lexer; - private $parser; - private $compiler; - protected $functions = []; - /** - * @param CacheItemPoolInterface $cache - * @param ExpressionFunctionProviderInterface[] $providers - */ - public function __construct($cache = null, array $providers = []) - { - if (null !== $cache) { - if ($cache instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheInterface) { - @\trigger_error(\sprintf('Passing an instance of %s as constructor argument for %s is deprecated as of 3.2 and will be removed in 4.0. Pass an instance of %s instead.', \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheInterface::class, self::class, \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface::class), \E_USER_DEPRECATED); - $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($cache); - } elseif (!$cache instanceof \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface) { - throw new \InvalidArgumentException(\sprintf('Cache argument has to implement "%s".', \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface::class)); - } - } - $this->cache = $cache ?: new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter(); - $this->registerFunctions(); - foreach ($providers as $provider) { - $this->registerProvider($provider); - } - } - /** - * Compiles an expression source code. - * - * @param Expression|string $expression The expression to compile - * @param array $names An array of valid names - * - * @return string The compiled PHP source code - */ - public function compile($expression, $names = []) - { - return $this->getCompiler()->compile($this->parse($expression, $names)->getNodes())->getSource(); - } - /** - * Evaluate an expression. - * - * @param Expression|string $expression The expression to compile - * @param array $values An array of values - * - * @return mixed The result of the evaluation of the expression - */ - public function evaluate($expression, $values = []) - { - return $this->parse($expression, \array_keys($values))->getNodes()->evaluate($this->functions, $values); - } - /** - * Parses an expression. - * - * @param Expression|string $expression The expression to parse - * @param array $names An array of valid names - * - * @return ParsedExpression A ParsedExpression instance - */ - public function parse($expression, $names) - { - if ($expression instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression) { - return $expression; - } - \asort($names); - $cacheKeyItems = []; - foreach ($names as $nameKey => $name) { - $cacheKeyItems[] = \is_int($nameKey) ? $name : $nameKey . ':' . $name; - } - $cacheItem = $this->cache->getItem(\rawurlencode($expression . '//' . \implode('|', $cacheKeyItems))); - if (null === ($parsedExpression = $cacheItem->get())) { - $nodes = $this->getParser()->parse($this->getLexer()->tokenize((string) $expression), $names); - $parsedExpression = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression((string) $expression, $nodes); - $cacheItem->set($parsedExpression); - $this->cache->save($cacheItem); - } - return $parsedExpression; - } - /** - * Registers a function. - * - * @param string $name The function name - * @param callable $compiler A callable able to compile the function - * @param callable $evaluator A callable able to evaluate the function - * - * @throws \LogicException when registering a function after calling evaluate(), compile() or parse() - * - * @see ExpressionFunction - */ - public function register($name, callable $compiler, callable $evaluator) - { - if (null !== $this->parser) { - throw new \LogicException('Registering functions after calling evaluate(), compile() or parse() is not supported.'); - } - $this->functions[$name] = ['compiler' => $compiler, 'evaluator' => $evaluator]; - } - public function addFunction(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction $function) - { - $this->register($function->getName(), $function->getCompiler(), $function->getEvaluator()); - } - public function registerProvider(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface $provider) - { - foreach ($provider->getFunctions() as $function) { - $this->addFunction($function); - } - } - protected function registerFunctions() - { - $this->addFunction(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('constant')); - } - private function getLexer() - { - if (null === $this->lexer) { - $this->lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); - } - return $this->lexer; - } - private function getParser() - { - if (null === $this->parser) { - $this->parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser($this->functions); - } - return $this->parser; - } - private function getCompiler() - { - if (null === $this->compiler) { - $this->compiler = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler($this->functions); - } - return $this->compiler->reset(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheInterface; +/** + * Allows to compile and evaluate expressions written in your own DSL. + * + * @author Fabien Potencier + */ +class ExpressionLanguage +{ + private $cache; + private $lexer; + private $parser; + private $compiler; + protected $functions = []; + /** + * @param CacheItemPoolInterface $cache + * @param ExpressionFunctionProviderInterface[] $providers + */ + public function __construct($cache = null, array $providers = []) + { + if (null !== $cache) { + if ($cache instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheInterface) { + @\trigger_error(\sprintf('Passing an instance of %s as constructor argument for %s is deprecated as of 3.2 and will be removed in 4.0. Pass an instance of %s instead.', \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheInterface::class, self::class, \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface::class), \E_USER_DEPRECATED); + $cache = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($cache); + } elseif (!$cache instanceof \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface) { + throw new \InvalidArgumentException(\sprintf('Cache argument has to implement "%s".', \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface::class)); + } + } + $this->cache = $cache ?: new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\Adapter\ArrayAdapter(); + $this->registerFunctions(); + foreach ($providers as $provider) { + $this->registerProvider($provider); + } + } + /** + * Compiles an expression source code. + * + * @param Expression|string $expression The expression to compile + * @param array $names An array of valid names + * + * @return string The compiled PHP source code + */ + public function compile($expression, $names = []) + { + return $this->getCompiler()->compile($this->parse($expression, $names)->getNodes())->getSource(); + } + /** + * Evaluate an expression. + * + * @param Expression|string $expression The expression to compile + * @param array $values An array of values + * + * @return mixed The result of the evaluation of the expression + */ + public function evaluate($expression, $values = []) + { + return $this->parse($expression, \array_keys($values))->getNodes()->evaluate($this->functions, $values); + } + /** + * Parses an expression. + * + * @param Expression|string $expression The expression to parse + * @param array $names An array of valid names + * + * @return ParsedExpression A ParsedExpression instance + */ + public function parse($expression, $names) + { + if ($expression instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression) { + return $expression; + } + \asort($names); + $cacheKeyItems = []; + foreach ($names as $nameKey => $name) { + $cacheKeyItems[] = \is_int($nameKey) ? $name : $nameKey . ':' . $name; + } + $cacheItem = $this->cache->getItem(\rawurlencode($expression . '//' . \implode('|', $cacheKeyItems))); + if (null === ($parsedExpression = $cacheItem->get())) { + $nodes = $this->getParser()->parse($this->getLexer()->tokenize((string) $expression), $names); + $parsedExpression = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression((string) $expression, $nodes); + $cacheItem->set($parsedExpression); + $this->cache->save($cacheItem); + } + return $parsedExpression; + } + /** + * Registers a function. + * + * @param string $name The function name + * @param callable $compiler A callable able to compile the function + * @param callable $evaluator A callable able to evaluate the function + * + * @throws \LogicException when registering a function after calling evaluate(), compile() or parse() + * + * @see ExpressionFunction + */ + public function register($name, callable $compiler, callable $evaluator) + { + if (null !== $this->parser) { + throw new \LogicException('Registering functions after calling evaluate(), compile() or parse() is not supported.'); + } + $this->functions[$name] = ['compiler' => $compiler, 'evaluator' => $evaluator]; + } + public function addFunction(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction $function) + { + $this->register($function->getName(), $function->getCompiler(), $function->getEvaluator()); + } + public function registerProvider(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface $provider) + { + foreach ($provider->getFunctions() as $function) { + $this->addFunction($function); + } + } + protected function registerFunctions() + { + $this->addFunction(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('constant')); + } + private function getLexer() + { + if (null === $this->lexer) { + $this->lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); + } + return $this->lexer; + } + private function getParser() + { + if (null === $this->parser) { + $this->parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser($this->functions); + } + return $this->parser; + } + private function getCompiler() + { + if (null === $this->compiler) { + $this->compiler = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler($this->functions); + } + return $this->compiler->reset(); + } +} diff --git a/vendor/symfony/expression-language/LICENSE b/vendor/symfony/expression-language/LICENSE index 9e936ec04..2bb330476 100644 --- a/vendor/symfony/expression-language/LICENSE +++ b/vendor/symfony/expression-language/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2004-2020 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2004-2020 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/expression-language/Lexer.php b/vendor/symfony/expression-language/Lexer.php index 1e9937a75..77c65dfdc 100644 --- a/vendor/symfony/expression-language/Lexer.php +++ b/vendor/symfony/expression-language/Lexer.php @@ -1,95 +1,95 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -/** - * Lexes an expression. - * - * @author Fabien Potencier - */ -class Lexer -{ - /** - * Tokenizes an expression. - * - * @param string $expression The expression to tokenize - * - * @return TokenStream A token stream instance - * - * @throws SyntaxError - */ - public function tokenize($expression) - { - $expression = \str_replace(["\r", "\n", "\t", "\v", "\f"], ' ', $expression); - $cursor = 0; - $tokens = []; - $brackets = []; - $end = \strlen($expression); - while ($cursor < $end) { - if (' ' == $expression[$cursor]) { - ++$cursor; - continue; - } - if (\preg_match('/[0-9]+(?:\\.[0-9]+)?/A', $expression, $match, 0, $cursor)) { - // numbers - $number = (float) $match[0]; - // floats - if (\preg_match('/^[0-9]+$/', $match[0]) && $number <= \PHP_INT_MAX) { - $number = (int) $match[0]; - // integers lower than the maximum - } - $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NUMBER_TYPE, $number, $cursor + 1); - $cursor += \strlen($match[0]); - } elseif (\false !== \strpos('([{', $expression[$cursor])) { - // opening bracket - $brackets[] = [$expression[$cursor], $cursor]; - $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, $expression[$cursor], $cursor + 1); - ++$cursor; - } elseif (\false !== \strpos(')]}', $expression[$cursor])) { - // closing bracket - if (empty($brackets)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unexpected "%s".', $expression[$cursor]), $cursor, $expression); - } - list($expect, $cur) = \array_pop($brackets); - if ($expression[$cursor] != \strtr($expect, '([{', ')]}')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unclosed "%s".', $expect), $cur, $expression); - } - $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, $expression[$cursor], $cursor + 1); - ++$cursor; - } elseif (\preg_match('/"([^"\\\\]*(?:\\\\.[^"\\\\]*)*)"|\'([^\'\\\\]*(?:\\\\.[^\'\\\\]*)*)\'/As', $expression, $match, 0, $cursor)) { - // strings - $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::STRING_TYPE, \stripcslashes(\substr($match[0], 1, -1)), $cursor + 1); - $cursor += \strlen($match[0]); - } elseif (\preg_match('/(?<=^|[\\s(])not in(?=[\\s(])|\\!\\=\\=|(?<=^|[\\s(])not(?=[\\s(])|(?<=^|[\\s(])and(?=[\\s(])|\\=\\=\\=|\\>\\=|(?<=^|[\\s(])or(?=[\\s(])|\\<\\=|\\*\\*|\\.\\.|(?<=^|[\\s(])in(?=[\\s(])|&&|\\|\\||(?<=^|[\\s(])matches|\\=\\=|\\!\\=|\\*|~|%|\\/|\\>|\\||\\!|\\^|&|\\+|\\<|\\-/A', $expression, $match, 0, $cursor)) { - // operators - $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::OPERATOR_TYPE, $match[0], $cursor + 1); - $cursor += \strlen($match[0]); - } elseif (\false !== \strpos('.,?:', $expression[$cursor])) { - // punctuation - $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, $expression[$cursor], $cursor + 1); - ++$cursor; - } elseif (\preg_match('/[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*/A', $expression, $match, 0, $cursor)) { - // names - $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NAME_TYPE, $match[0], $cursor + 1); - $cursor += \strlen($match[0]); - } else { - // unlexable - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unexpected character "%s".', $expression[$cursor]), $cursor, $expression); - } - } - $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::EOF_TYPE, null, $cursor + 1); - if (!empty($brackets)) { - list($expect, $cur) = \array_pop($brackets); - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unclosed "%s".', $expect), $cur, $expression); - } - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\TokenStream($tokens, $expression); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +/** + * Lexes an expression. + * + * @author Fabien Potencier + */ +class Lexer +{ + /** + * Tokenizes an expression. + * + * @param string $expression The expression to tokenize + * + * @return TokenStream A token stream instance + * + * @throws SyntaxError + */ + public function tokenize($expression) + { + $expression = \str_replace(["\r", "\n", "\t", "\v", "\f"], ' ', $expression); + $cursor = 0; + $tokens = []; + $brackets = []; + $end = \strlen($expression); + while ($cursor < $end) { + if (' ' == $expression[$cursor]) { + ++$cursor; + continue; + } + if (\preg_match('/[0-9]+(?:\\.[0-9]+)?/A', $expression, $match, 0, $cursor)) { + // numbers + $number = (float) $match[0]; + // floats + if (\preg_match('/^[0-9]+$/', $match[0]) && $number <= \PHP_INT_MAX) { + $number = (int) $match[0]; + // integers lower than the maximum + } + $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NUMBER_TYPE, $number, $cursor + 1); + $cursor += \strlen($match[0]); + } elseif (\false !== \strpos('([{', $expression[$cursor])) { + // opening bracket + $brackets[] = [$expression[$cursor], $cursor]; + $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, $expression[$cursor], $cursor + 1); + ++$cursor; + } elseif (\false !== \strpos(')]}', $expression[$cursor])) { + // closing bracket + if (empty($brackets)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unexpected "%s".', $expression[$cursor]), $cursor, $expression); + } + list($expect, $cur) = \array_pop($brackets); + if ($expression[$cursor] != \strtr($expect, '([{', ')]}')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unclosed "%s".', $expect), $cur, $expression); + } + $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, $expression[$cursor], $cursor + 1); + ++$cursor; + } elseif (\preg_match('/"([^"\\\\]*(?:\\\\.[^"\\\\]*)*)"|\'([^\'\\\\]*(?:\\\\.[^\'\\\\]*)*)\'/As', $expression, $match, 0, $cursor)) { + // strings + $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::STRING_TYPE, \stripcslashes(\substr($match[0], 1, -1)), $cursor + 1); + $cursor += \strlen($match[0]); + } elseif (\preg_match('/(?<=^|[\\s(])not in(?=[\\s(])|\\!\\=\\=|(?<=^|[\\s(])not(?=[\\s(])|(?<=^|[\\s(])and(?=[\\s(])|\\=\\=\\=|\\>\\=|(?<=^|[\\s(])or(?=[\\s(])|\\<\\=|\\*\\*|\\.\\.|(?<=^|[\\s(])in(?=[\\s(])|&&|\\|\\||(?<=^|[\\s(])matches|\\=\\=|\\!\\=|\\*|~|%|\\/|\\>|\\||\\!|\\^|&|\\+|\\<|\\-/A', $expression, $match, 0, $cursor)) { + // operators + $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::OPERATOR_TYPE, $match[0], $cursor + 1); + $cursor += \strlen($match[0]); + } elseif (\false !== \strpos('.,?:', $expression[$cursor])) { + // punctuation + $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, $expression[$cursor], $cursor + 1); + ++$cursor; + } elseif (\preg_match('/[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*/A', $expression, $match, 0, $cursor)) { + // names + $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NAME_TYPE, $match[0], $cursor + 1); + $cursor += \strlen($match[0]); + } else { + // unlexable + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unexpected character "%s".', $expression[$cursor]), $cursor, $expression); + } + } + $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::EOF_TYPE, null, $cursor + 1); + if (!empty($brackets)) { + list($expect, $cur) = \array_pop($brackets); + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unclosed "%s".', $expect), $cur, $expression); + } + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\TokenStream($tokens, $expression); + } +} diff --git a/vendor/symfony/expression-language/Node/ArgumentsNode.php b/vendor/symfony/expression-language/Node/ArgumentsNode.php index a19b00333..fc8a7d94d 100644 --- a/vendor/symfony/expression-language/Node/ArgumentsNode.php +++ b/vendor/symfony/expression-language/Node/ArgumentsNode.php @@ -1,35 +1,35 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -/** - * @author Fabien Potencier - * - * @internal - */ -class ArgumentsNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode -{ - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) - { - $this->compileArguments($compiler, \false); - } - public function toArray() - { - $array = []; - foreach ($this->getKeyValuePairs() as $pair) { - $array[] = $pair['value']; - $array[] = ', '; - } - \array_pop($array); - return $array; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +/** + * @author Fabien Potencier + * + * @internal + */ +class ArgumentsNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode +{ + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) + { + $this->compileArguments($compiler, \false); + } + public function toArray() + { + $array = []; + foreach ($this->getKeyValuePairs() as $pair) { + $array[] = $pair['value']; + $array[] = ', '; + } + \array_pop($array); + return $array; + } +} diff --git a/vendor/symfony/expression-language/Node/ArrayNode.php b/vendor/symfony/expression-language/Node/ArrayNode.php index 1241a0b6f..c85350b02 100644 --- a/vendor/symfony/expression-language/Node/ArrayNode.php +++ b/vendor/symfony/expression-language/Node/ArrayNode.php @@ -1,98 +1,98 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -/** - * @author Fabien Potencier - * - * @internal - */ -class ArrayNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node -{ - protected $index; - public function __construct() - { - $this->index = -1; - } - public function addElement(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $value, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $key = null) - { - if (null === $key) { - $key = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(++$this->index); - } - \array_push($this->nodes, $key, $value); - } - /** - * Compiles the node to PHP. - */ - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) - { - $compiler->raw('['); - $this->compileArguments($compiler); - $compiler->raw(']'); - } - public function evaluate($functions, $values) - { - $result = []; - foreach ($this->getKeyValuePairs() as $pair) { - $result[$pair['key']->evaluate($functions, $values)] = $pair['value']->evaluate($functions, $values); - } - return $result; - } - public function toArray() - { - $value = []; - foreach ($this->getKeyValuePairs() as $pair) { - $value[$pair['key']->attributes['value']] = $pair['value']; - } - $array = []; - if ($this->isHash($value)) { - foreach ($value as $k => $v) { - $array[] = ', '; - $array[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode($k); - $array[] = ': '; - $array[] = $v; - } - $array[0] = '{'; - $array[] = '}'; - } else { - foreach ($value as $v) { - $array[] = ', '; - $array[] = $v; - } - $array[0] = '['; - $array[] = ']'; - } - return $array; - } - protected function getKeyValuePairs() - { - $pairs = []; - foreach (\array_chunk($this->nodes, 2) as $pair) { - $pairs[] = ['key' => $pair[0], 'value' => $pair[1]]; - } - return $pairs; - } - protected function compileArguments(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler, $withKeys = \true) - { - $first = \true; - foreach ($this->getKeyValuePairs() as $pair) { - if (!$first) { - $compiler->raw(', '); - } - $first = \false; - if ($withKeys) { - $compiler->compile($pair['key'])->raw(' => '); - } - $compiler->compile($pair['value']); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +/** + * @author Fabien Potencier + * + * @internal + */ +class ArrayNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node +{ + protected $index; + public function __construct() + { + $this->index = -1; + } + public function addElement(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $value, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $key = null) + { + if (null === $key) { + $key = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(++$this->index); + } + \array_push($this->nodes, $key, $value); + } + /** + * Compiles the node to PHP. + */ + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) + { + $compiler->raw('['); + $this->compileArguments($compiler); + $compiler->raw(']'); + } + public function evaluate($functions, $values) + { + $result = []; + foreach ($this->getKeyValuePairs() as $pair) { + $result[$pair['key']->evaluate($functions, $values)] = $pair['value']->evaluate($functions, $values); + } + return $result; + } + public function toArray() + { + $value = []; + foreach ($this->getKeyValuePairs() as $pair) { + $value[$pair['key']->attributes['value']] = $pair['value']; + } + $array = []; + if ($this->isHash($value)) { + foreach ($value as $k => $v) { + $array[] = ', '; + $array[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode($k); + $array[] = ': '; + $array[] = $v; + } + $array[0] = '{'; + $array[] = '}'; + } else { + foreach ($value as $v) { + $array[] = ', '; + $array[] = $v; + } + $array[0] = '['; + $array[] = ']'; + } + return $array; + } + protected function getKeyValuePairs() + { + $pairs = []; + foreach (\array_chunk($this->nodes, 2) as $pair) { + $pairs[] = ['key' => $pair[0], 'value' => $pair[1]]; + } + return $pairs; + } + protected function compileArguments(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler, $withKeys = \true) + { + $first = \true; + foreach ($this->getKeyValuePairs() as $pair) { + if (!$first) { + $compiler->raw(', '); + } + $first = \false; + if ($withKeys) { + $compiler->compile($pair['key'])->raw(' => '); + } + $compiler->compile($pair['value']); + } + } +} diff --git a/vendor/symfony/expression-language/Node/BinaryNode.php b/vendor/symfony/expression-language/Node/BinaryNode.php index 3148b308c..2d47638fa 100644 --- a/vendor/symfony/expression-language/Node/BinaryNode.php +++ b/vendor/symfony/expression-language/Node/BinaryNode.php @@ -1,117 +1,117 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -/** - * @author Fabien Potencier - * - * @internal - */ -class BinaryNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node -{ - private static $operators = ['~' => '.', 'and' => '&&', 'or' => '||']; - private static $functions = ['**' => 'pow', '..' => 'range', 'in' => 'in_array', 'not in' => '!in_array']; - public function __construct($operator, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $left, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $right) - { - parent::__construct(['left' => $left, 'right' => $right], ['operator' => $operator]); - } - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) - { - $operator = $this->attributes['operator']; - if ('matches' == $operator) { - $compiler->raw('preg_match(')->compile($this->nodes['right'])->raw(', ')->compile($this->nodes['left'])->raw(')'); - return; - } - if (isset(self::$functions[$operator])) { - $compiler->raw(\sprintf('%s(', self::$functions[$operator]))->compile($this->nodes['left'])->raw(', ')->compile($this->nodes['right'])->raw(')'); - return; - } - if (isset(self::$operators[$operator])) { - $operator = self::$operators[$operator]; - } - $compiler->raw('(')->compile($this->nodes['left'])->raw(' ')->raw($operator)->raw(' ')->compile($this->nodes['right'])->raw(')'); - } - public function evaluate($functions, $values) - { - $operator = $this->attributes['operator']; - $left = $this->nodes['left']->evaluate($functions, $values); - if (isset(self::$functions[$operator])) { - $right = $this->nodes['right']->evaluate($functions, $values); - if ('not in' === $operator) { - return !\in_array($left, $right); - } - $f = self::$functions[$operator]; - return $f($left, $right); - } - switch ($operator) { - case 'or': - case '||': - return $left || $this->nodes['right']->evaluate($functions, $values); - case 'and': - case '&&': - return $left && $this->nodes['right']->evaluate($functions, $values); - } - $right = $this->nodes['right']->evaluate($functions, $values); - switch ($operator) { - case '|': - return $left | $right; - case '^': - return $left ^ $right; - case '&': - return $left & $right; - case '==': - return $left == $right; - case '===': - return $left === $right; - case '!=': - return $left != $right; - case '!==': - return $left !== $right; - case '<': - return $left < $right; - case '>': - return $left > $right; - case '>=': - return $left >= $right; - case '<=': - return $left <= $right; - case 'not in': - return !\in_array($left, $right); - case 'in': - return \in_array($left, $right); - case '+': - return $left + $right; - case '-': - return $left - $right; - case '~': - return $left . $right; - case '*': - return $left * $right; - case '/': - if (0 == $right) { - throw new \DivisionByZeroError('Division by zero.'); - } - return $left / $right; - case '%': - if (0 == $right) { - throw new \DivisionByZeroError('Modulo by zero.'); - } - return $left % $right; - case 'matches': - return \preg_match($right, $left); - } - } - public function toArray() - { - return ['(', $this->nodes['left'], ' ' . $this->attributes['operator'] . ' ', $this->nodes['right'], ')']; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +/** + * @author Fabien Potencier + * + * @internal + */ +class BinaryNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node +{ + private static $operators = ['~' => '.', 'and' => '&&', 'or' => '||']; + private static $functions = ['**' => 'pow', '..' => 'range', 'in' => 'in_array', 'not in' => '!in_array']; + public function __construct($operator, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $left, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $right) + { + parent::__construct(['left' => $left, 'right' => $right], ['operator' => $operator]); + } + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) + { + $operator = $this->attributes['operator']; + if ('matches' == $operator) { + $compiler->raw('preg_match(')->compile($this->nodes['right'])->raw(', ')->compile($this->nodes['left'])->raw(')'); + return; + } + if (isset(self::$functions[$operator])) { + $compiler->raw(\sprintf('%s(', self::$functions[$operator]))->compile($this->nodes['left'])->raw(', ')->compile($this->nodes['right'])->raw(')'); + return; + } + if (isset(self::$operators[$operator])) { + $operator = self::$operators[$operator]; + } + $compiler->raw('(')->compile($this->nodes['left'])->raw(' ')->raw($operator)->raw(' ')->compile($this->nodes['right'])->raw(')'); + } + public function evaluate($functions, $values) + { + $operator = $this->attributes['operator']; + $left = $this->nodes['left']->evaluate($functions, $values); + if (isset(self::$functions[$operator])) { + $right = $this->nodes['right']->evaluate($functions, $values); + if ('not in' === $operator) { + return !\in_array($left, $right); + } + $f = self::$functions[$operator]; + return $f($left, $right); + } + switch ($operator) { + case 'or': + case '||': + return $left || $this->nodes['right']->evaluate($functions, $values); + case 'and': + case '&&': + return $left && $this->nodes['right']->evaluate($functions, $values); + } + $right = $this->nodes['right']->evaluate($functions, $values); + switch ($operator) { + case '|': + return $left | $right; + case '^': + return $left ^ $right; + case '&': + return $left & $right; + case '==': + return $left == $right; + case '===': + return $left === $right; + case '!=': + return $left != $right; + case '!==': + return $left !== $right; + case '<': + return $left < $right; + case '>': + return $left > $right; + case '>=': + return $left >= $right; + case '<=': + return $left <= $right; + case 'not in': + return !\in_array($left, $right); + case 'in': + return \in_array($left, $right); + case '+': + return $left + $right; + case '-': + return $left - $right; + case '~': + return $left . $right; + case '*': + return $left * $right; + case '/': + if (0 == $right) { + throw new \DivisionByZeroError('Division by zero.'); + } + return $left / $right; + case '%': + if (0 == $right) { + throw new \DivisionByZeroError('Modulo by zero.'); + } + return $left % $right; + case 'matches': + return \preg_match($right, $left); + } + } + public function toArray() + { + return ['(', $this->nodes['left'], ' ' . $this->attributes['operator'] . ' ', $this->nodes['right'], ')']; + } +} diff --git a/vendor/symfony/expression-language/Node/ConditionalNode.php b/vendor/symfony/expression-language/Node/ConditionalNode.php index 029f15673..dbe332b74 100644 --- a/vendor/symfony/expression-language/Node/ConditionalNode.php +++ b/vendor/symfony/expression-language/Node/ConditionalNode.php @@ -1,40 +1,40 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -/** - * @author Fabien Potencier - * - * @internal - */ -class ConditionalNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node -{ - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $expr1, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $expr2, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $expr3) - { - parent::__construct(['expr1' => $expr1, 'expr2' => $expr2, 'expr3' => $expr3]); - } - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) - { - $compiler->raw('((')->compile($this->nodes['expr1'])->raw(') ? (')->compile($this->nodes['expr2'])->raw(') : (')->compile($this->nodes['expr3'])->raw('))'); - } - public function evaluate($functions, $values) - { - if ($this->nodes['expr1']->evaluate($functions, $values)) { - return $this->nodes['expr2']->evaluate($functions, $values); - } - return $this->nodes['expr3']->evaluate($functions, $values); - } - public function toArray() - { - return ['(', $this->nodes['expr1'], ' ? ', $this->nodes['expr2'], ' : ', $this->nodes['expr3'], ')']; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +/** + * @author Fabien Potencier + * + * @internal + */ +class ConditionalNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node +{ + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $expr1, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $expr2, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $expr3) + { + parent::__construct(['expr1' => $expr1, 'expr2' => $expr2, 'expr3' => $expr3]); + } + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) + { + $compiler->raw('((')->compile($this->nodes['expr1'])->raw(') ? (')->compile($this->nodes['expr2'])->raw(') : (')->compile($this->nodes['expr3'])->raw('))'); + } + public function evaluate($functions, $values) + { + if ($this->nodes['expr1']->evaluate($functions, $values)) { + return $this->nodes['expr2']->evaluate($functions, $values); + } + return $this->nodes['expr3']->evaluate($functions, $values); + } + public function toArray() + { + return ['(', $this->nodes['expr1'], ' ? ', $this->nodes['expr2'], ' : ', $this->nodes['expr3'], ')']; + } +} diff --git a/vendor/symfony/expression-language/Node/ConstantNode.php b/vendor/symfony/expression-language/Node/ConstantNode.php index ba1f87653..d29421f67 100644 --- a/vendor/symfony/expression-language/Node/ConstantNode.php +++ b/vendor/symfony/expression-language/Node/ConstantNode.php @@ -1,70 +1,70 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -/** - * @author Fabien Potencier - * - * @internal - */ -class ConstantNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node -{ - private $isIdentifier; - public function __construct($value, $isIdentifier = \false) - { - $this->isIdentifier = $isIdentifier; - parent::__construct([], ['value' => $value]); - } - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) - { - $compiler->repr($this->attributes['value']); - } - public function evaluate($functions, $values) - { - return $this->attributes['value']; - } - public function toArray() - { - $array = []; - $value = $this->attributes['value']; - if ($this->isIdentifier) { - $array[] = $value; - } elseif (\true === $value) { - $array[] = 'true'; - } elseif (\false === $value) { - $array[] = 'false'; - } elseif (null === $value) { - $array[] = 'null'; - } elseif (\is_numeric($value)) { - $array[] = $value; - } elseif (!\is_array($value)) { - $array[] = $this->dumpString($value); - } elseif ($this->isHash($value)) { - foreach ($value as $k => $v) { - $array[] = ', '; - $array[] = new self($k); - $array[] = ': '; - $array[] = new self($v); - } - $array[0] = '{'; - $array[] = '}'; - } else { - foreach ($value as $v) { - $array[] = ', '; - $array[] = new self($v); - } - $array[0] = '['; - $array[] = ']'; - } - return $array; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +/** + * @author Fabien Potencier + * + * @internal + */ +class ConstantNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node +{ + private $isIdentifier; + public function __construct($value, $isIdentifier = \false) + { + $this->isIdentifier = $isIdentifier; + parent::__construct([], ['value' => $value]); + } + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) + { + $compiler->repr($this->attributes['value']); + } + public function evaluate($functions, $values) + { + return $this->attributes['value']; + } + public function toArray() + { + $array = []; + $value = $this->attributes['value']; + if ($this->isIdentifier) { + $array[] = $value; + } elseif (\true === $value) { + $array[] = 'true'; + } elseif (\false === $value) { + $array[] = 'false'; + } elseif (null === $value) { + $array[] = 'null'; + } elseif (\is_numeric($value)) { + $array[] = $value; + } elseif (!\is_array($value)) { + $array[] = $this->dumpString($value); + } elseif ($this->isHash($value)) { + foreach ($value as $k => $v) { + $array[] = ', '; + $array[] = new self($k); + $array[] = ': '; + $array[] = new self($v); + } + $array[0] = '{'; + $array[] = '}'; + } else { + foreach ($value as $v) { + $array[] = ', '; + $array[] = new self($v); + } + $array[0] = '['; + $array[] = ']'; + } + return $array; + } +} diff --git a/vendor/symfony/expression-language/Node/FunctionNode.php b/vendor/symfony/expression-language/Node/FunctionNode.php index 40c4fc39d..3fbd29ce3 100644 --- a/vendor/symfony/expression-language/Node/FunctionNode.php +++ b/vendor/symfony/expression-language/Node/FunctionNode.php @@ -1,54 +1,54 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -/** - * @author Fabien Potencier - * - * @internal - */ -class FunctionNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node -{ - public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $arguments) - { - parent::__construct(['arguments' => $arguments], ['name' => $name]); - } - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) - { - $arguments = []; - foreach ($this->nodes['arguments']->nodes as $node) { - $arguments[] = $compiler->subcompile($node); - } - $function = $compiler->getFunction($this->attributes['name']); - $compiler->raw(\call_user_func_array($function['compiler'], $arguments)); - } - public function evaluate($functions, $values) - { - $arguments = [$values]; - foreach ($this->nodes['arguments']->nodes as $node) { - $arguments[] = $node->evaluate($functions, $values); - } - return \call_user_func_array($functions[$this->attributes['name']]['evaluator'], $arguments); - } - public function toArray() - { - $array = []; - $array[] = $this->attributes['name']; - foreach ($this->nodes['arguments']->nodes as $node) { - $array[] = ', '; - $array[] = $node; - } - $array[1] = '('; - $array[] = ')'; - return $array; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +/** + * @author Fabien Potencier + * + * @internal + */ +class FunctionNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node +{ + public function __construct($name, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $arguments) + { + parent::__construct(['arguments' => $arguments], ['name' => $name]); + } + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) + { + $arguments = []; + foreach ($this->nodes['arguments']->nodes as $node) { + $arguments[] = $compiler->subcompile($node); + } + $function = $compiler->getFunction($this->attributes['name']); + $compiler->raw(\call_user_func_array($function['compiler'], $arguments)); + } + public function evaluate($functions, $values) + { + $arguments = [$values]; + foreach ($this->nodes['arguments']->nodes as $node) { + $arguments[] = $node->evaluate($functions, $values); + } + return \call_user_func_array($functions[$this->attributes['name']]['evaluator'], $arguments); + } + public function toArray() + { + $array = []; + $array[] = $this->attributes['name']; + foreach ($this->nodes['arguments']->nodes as $node) { + $array[] = ', '; + $array[] = $node; + } + $array[1] = '('; + $array[] = ')'; + return $array; + } +} diff --git a/vendor/symfony/expression-language/Node/GetAttrNode.php b/vendor/symfony/expression-language/Node/GetAttrNode.php index 60a34e36d..16a8bf9ce 100644 --- a/vendor/symfony/expression-language/Node/GetAttrNode.php +++ b/vendor/symfony/expression-language/Node/GetAttrNode.php @@ -1,80 +1,80 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -/** - * @author Fabien Potencier - * - * @internal - */ -class GetAttrNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node -{ - const PROPERTY_CALL = 1; - const METHOD_CALL = 2; - const ARRAY_CALL = 3; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $node, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $attribute, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode $arguments, $type) - { - parent::__construct(['node' => $node, 'attribute' => $attribute, 'arguments' => $arguments], ['type' => $type]); - } - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) - { - switch ($this->attributes['type']) { - case self::PROPERTY_CALL: - $compiler->compile($this->nodes['node'])->raw('->')->raw($this->nodes['attribute']->attributes['value']); - break; - case self::METHOD_CALL: - $compiler->compile($this->nodes['node'])->raw('->')->raw($this->nodes['attribute']->attributes['value'])->raw('(')->compile($this->nodes['arguments'])->raw(')'); - break; - case self::ARRAY_CALL: - $compiler->compile($this->nodes['node'])->raw('[')->compile($this->nodes['attribute'])->raw(']'); - break; - } - } - public function evaluate($functions, $values) - { - switch ($this->attributes['type']) { - case self::PROPERTY_CALL: - $obj = $this->nodes['node']->evaluate($functions, $values); - if (!\is_object($obj)) { - throw new \RuntimeException('Unable to get a property on a non-object.'); - } - $property = $this->nodes['attribute']->attributes['value']; - return $obj->{$property}; - case self::METHOD_CALL: - $obj = $this->nodes['node']->evaluate($functions, $values); - if (!\is_object($obj)) { - throw new \RuntimeException('Unable to get a property on a non-object.'); - } - if (!\is_callable($toCall = [$obj, $this->nodes['attribute']->attributes['value']])) { - throw new \RuntimeException(\sprintf('Unable to call method "%s" of object "%s".', $this->nodes['attribute']->attributes['value'], \get_class($obj))); - } - return \call_user_func_array($toCall, $this->nodes['arguments']->evaluate($functions, $values)); - case self::ARRAY_CALL: - $array = $this->nodes['node']->evaluate($functions, $values); - if (!\is_array($array) && !$array instanceof \ArrayAccess) { - throw new \RuntimeException('Unable to get an item on a non-array.'); - } - return $array[$this->nodes['attribute']->evaluate($functions, $values)]; - } - } - public function toArray() - { - switch ($this->attributes['type']) { - case self::PROPERTY_CALL: - return [$this->nodes['node'], '.', $this->nodes['attribute']]; - case self::METHOD_CALL: - return [$this->nodes['node'], '.', $this->nodes['attribute'], '(', $this->nodes['arguments'], ')']; - case self::ARRAY_CALL: - return [$this->nodes['node'], '[', $this->nodes['attribute'], ']']; - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +/** + * @author Fabien Potencier + * + * @internal + */ +class GetAttrNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node +{ + const PROPERTY_CALL = 1; + const METHOD_CALL = 2; + const ARRAY_CALL = 3; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $node, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $attribute, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode $arguments, $type) + { + parent::__construct(['node' => $node, 'attribute' => $attribute, 'arguments' => $arguments], ['type' => $type]); + } + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) + { + switch ($this->attributes['type']) { + case self::PROPERTY_CALL: + $compiler->compile($this->nodes['node'])->raw('->')->raw($this->nodes['attribute']->attributes['value']); + break; + case self::METHOD_CALL: + $compiler->compile($this->nodes['node'])->raw('->')->raw($this->nodes['attribute']->attributes['value'])->raw('(')->compile($this->nodes['arguments'])->raw(')'); + break; + case self::ARRAY_CALL: + $compiler->compile($this->nodes['node'])->raw('[')->compile($this->nodes['attribute'])->raw(']'); + break; + } + } + public function evaluate($functions, $values) + { + switch ($this->attributes['type']) { + case self::PROPERTY_CALL: + $obj = $this->nodes['node']->evaluate($functions, $values); + if (!\is_object($obj)) { + throw new \RuntimeException('Unable to get a property on a non-object.'); + } + $property = $this->nodes['attribute']->attributes['value']; + return $obj->{$property}; + case self::METHOD_CALL: + $obj = $this->nodes['node']->evaluate($functions, $values); + if (!\is_object($obj)) { + throw new \RuntimeException('Unable to get a property on a non-object.'); + } + if (!\is_callable($toCall = [$obj, $this->nodes['attribute']->attributes['value']])) { + throw new \RuntimeException(\sprintf('Unable to call method "%s" of object "%s".', $this->nodes['attribute']->attributes['value'], \get_class($obj))); + } + return \call_user_func_array($toCall, $this->nodes['arguments']->evaluate($functions, $values)); + case self::ARRAY_CALL: + $array = $this->nodes['node']->evaluate($functions, $values); + if (!\is_array($array) && !$array instanceof \ArrayAccess) { + throw new \RuntimeException('Unable to get an item on a non-array.'); + } + return $array[$this->nodes['attribute']->evaluate($functions, $values)]; + } + } + public function toArray() + { + switch ($this->attributes['type']) { + case self::PROPERTY_CALL: + return [$this->nodes['node'], '.', $this->nodes['attribute']]; + case self::METHOD_CALL: + return [$this->nodes['node'], '.', $this->nodes['attribute'], '(', $this->nodes['arguments'], ')']; + case self::ARRAY_CALL: + return [$this->nodes['node'], '[', $this->nodes['attribute'], ']']; + } + } +} diff --git a/vendor/symfony/expression-language/Node/NameNode.php b/vendor/symfony/expression-language/Node/NameNode.php index 2a5ec927b..40b4e1168 100644 --- a/vendor/symfony/expression-language/Node/NameNode.php +++ b/vendor/symfony/expression-language/Node/NameNode.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -/** - * @author Fabien Potencier - * - * @internal - */ -class NameNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node -{ - public function __construct($name) - { - parent::__construct([], ['name' => $name]); - } - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) - { - $compiler->raw('$' . $this->attributes['name']); - } - public function evaluate($functions, $values) - { - return $values[$this->attributes['name']]; - } - public function toArray() - { - return [$this->attributes['name']]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +/** + * @author Fabien Potencier + * + * @internal + */ +class NameNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node +{ + public function __construct($name) + { + parent::__construct([], ['name' => $name]); + } + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) + { + $compiler->raw('$' . $this->attributes['name']); + } + public function evaluate($functions, $values) + { + return $values[$this->attributes['name']]; + } + public function toArray() + { + return [$this->attributes['name']]; + } +} diff --git a/vendor/symfony/expression-language/Node/Node.php b/vendor/symfony/expression-language/Node/Node.php index ae2c90c34..5c35cd084 100644 --- a/vendor/symfony/expression-language/Node/Node.php +++ b/vendor/symfony/expression-language/Node/Node.php @@ -1,91 +1,91 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -/** - * Represents a node in the AST. - * - * @author Fabien Potencier - */ -class Node -{ - public $nodes = []; - public $attributes = []; - /** - * @param array $nodes An array of nodes - * @param array $attributes An array of attributes - */ - public function __construct(array $nodes = [], array $attributes = []) - { - $this->nodes = $nodes; - $this->attributes = $attributes; - } - public function __toString() - { - $attributes = []; - foreach ($this->attributes as $name => $value) { - $attributes[] = \sprintf('%s: %s', $name, \str_replace("\n", '', \var_export($value, \true))); - } - $repr = [\str_replace('Symfony\\Component\\ExpressionLanguage\\Node\\', '', static::class) . '(' . \implode(', ', $attributes)]; - if (\count($this->nodes)) { - foreach ($this->nodes as $node) { - foreach (\explode("\n", (string) $node) as $line) { - $repr[] = ' ' . $line; - } - } - $repr[] = ')'; - } else { - $repr[0] .= ')'; - } - return \implode("\n", $repr); - } - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) - { - foreach ($this->nodes as $node) { - $node->compile($compiler); - } - } - public function evaluate($functions, $values) - { - $results = []; - foreach ($this->nodes as $node) { - $results[] = $node->evaluate($functions, $values); - } - return $results; - } - public function toArray() - { - throw new \BadMethodCallException(\sprintf('Dumping a "%s" instance is not supported yet.', static::class)); - } - public function dump() - { - $dump = ''; - foreach ($this->toArray() as $v) { - $dump .= \is_scalar($v) ? $v : $v->dump(); - } - return $dump; - } - protected function dumpString($value) - { - return \sprintf('"%s"', \addcslashes($value, "\0\t\"\\")); - } - protected function isHash(array $value) - { - $expectedKey = 0; - foreach ($value as $key => $val) { - if ($key !== $expectedKey++) { - return \true; - } - } - return \false; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +/** + * Represents a node in the AST. + * + * @author Fabien Potencier + */ +class Node +{ + public $nodes = []; + public $attributes = []; + /** + * @param array $nodes An array of nodes + * @param array $attributes An array of attributes + */ + public function __construct(array $nodes = [], array $attributes = []) + { + $this->nodes = $nodes; + $this->attributes = $attributes; + } + public function __toString() + { + $attributes = []; + foreach ($this->attributes as $name => $value) { + $attributes[] = \sprintf('%s: %s', $name, \str_replace("\n", '', \var_export($value, \true))); + } + $repr = [\str_replace('Symfony\\Component\\ExpressionLanguage\\Node\\', '', static::class) . '(' . \implode(', ', $attributes)]; + if (\count($this->nodes)) { + foreach ($this->nodes as $node) { + foreach (\explode("\n", (string) $node) as $line) { + $repr[] = ' ' . $line; + } + } + $repr[] = ')'; + } else { + $repr[0] .= ')'; + } + return \implode("\n", $repr); + } + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) + { + foreach ($this->nodes as $node) { + $node->compile($compiler); + } + } + public function evaluate($functions, $values) + { + $results = []; + foreach ($this->nodes as $node) { + $results[] = $node->evaluate($functions, $values); + } + return $results; + } + public function toArray() + { + throw new \BadMethodCallException(\sprintf('Dumping a "%s" instance is not supported yet.', static::class)); + } + public function dump() + { + $dump = ''; + foreach ($this->toArray() as $v) { + $dump .= \is_scalar($v) ? $v : $v->dump(); + } + return $dump; + } + protected function dumpString($value) + { + return \sprintf('"%s"', \addcslashes($value, "\0\t\"\\")); + } + protected function isHash(array $value) + { + $expectedKey = 0; + foreach ($value as $key => $val) { + if ($key !== $expectedKey++) { + return \true; + } + } + return \false; + } +} diff --git a/vendor/symfony/expression-language/Node/UnaryNode.php b/vendor/symfony/expression-language/Node/UnaryNode.php index 8d66eba28..dced2548f 100644 --- a/vendor/symfony/expression-language/Node/UnaryNode.php +++ b/vendor/symfony/expression-language/Node/UnaryNode.php @@ -1,46 +1,46 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -/** - * @author Fabien Potencier - * - * @internal - */ -class UnaryNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node -{ - private static $operators = ['!' => '!', 'not' => '!', '+' => '+', '-' => '-']; - public function __construct($operator, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $node) - { - parent::__construct(['node' => $node], ['operator' => $operator]); - } - public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) - { - $compiler->raw('(')->raw(self::$operators[$this->attributes['operator']])->compile($this->nodes['node'])->raw(')'); - } - public function evaluate($functions, $values) - { - $value = $this->nodes['node']->evaluate($functions, $values); - switch ($this->attributes['operator']) { - case 'not': - case '!': - return !$value; - case '-': - return -$value; - } - return $value; - } - public function toArray() - { - return ['(', $this->attributes['operator'] . ' ', $this->nodes['node'], ')']; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +/** + * @author Fabien Potencier + * + * @internal + */ +class UnaryNode extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node +{ + private static $operators = ['!' => '!', 'not' => '!', '+' => '+', '-' => '-']; + public function __construct($operator, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $node) + { + parent::__construct(['node' => $node], ['operator' => $operator]); + } + public function compile(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler $compiler) + { + $compiler->raw('(')->raw(self::$operators[$this->attributes['operator']])->compile($this->nodes['node'])->raw(')'); + } + public function evaluate($functions, $values) + { + $value = $this->nodes['node']->evaluate($functions, $values); + switch ($this->attributes['operator']) { + case 'not': + case '!': + return !$value; + case '-': + return -$value; + } + return $value; + } + public function toArray() + { + return ['(', $this->attributes['operator'] . ' ', $this->nodes['node'], ')']; + } +} diff --git a/vendor/symfony/expression-language/Node/index.php b/vendor/symfony/expression-language/Node/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/expression-language/Node/index.php +++ b/vendor/symfony/expression-language/Node/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/ParsedExpression.php b/vendor/symfony/expression-language/ParsedExpression.php index 70fb11f9c..46d72f4d0 100644 --- a/vendor/symfony/expression-language/ParsedExpression.php +++ b/vendor/symfony/expression-language/ParsedExpression.php @@ -1,35 +1,35 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node; -/** - * Represents an already parsed expression. - * - * @author Fabien Potencier - */ -class ParsedExpression extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression -{ - private $nodes; - /** - * @param string $expression An expression - * @param Node $nodes A Node representing the expression - */ - public function __construct($expression, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $nodes) - { - parent::__construct($expression); - $this->nodes = $nodes; - } - public function getNodes() - { - return $this->nodes; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node; +/** + * Represents an already parsed expression. + * + * @author Fabien Potencier + */ +class ParsedExpression extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression +{ + private $nodes; + /** + * @param string $expression An expression + * @param Node $nodes A Node representing the expression + */ + public function __construct($expression, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node $nodes) + { + parent::__construct($expression); + $this->nodes = $nodes; + } + public function getNodes() + { + return $this->nodes; + } +} diff --git a/vendor/symfony/expression-language/Parser.php b/vendor/symfony/expression-language/Parser.php index 082c93715..968bc99ff 100644 --- a/vendor/symfony/expression-language/Parser.php +++ b/vendor/symfony/expression-language/Parser.php @@ -1,277 +1,277 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -/** - * Parsers a token stream. - * - * This parser implements a "Precedence climbing" algorithm. - * - * @see http://www.engr.mun.ca/~theo/Misc/exp_parsing.htm - * @see http://en.wikipedia.org/wiki/Operator-precedence_parser - * - * @author Fabien Potencier - */ -class Parser -{ - const OPERATOR_LEFT = 1; - const OPERATOR_RIGHT = 2; - private $stream; - private $unaryOperators; - private $binaryOperators; - private $functions; - private $names; - public function __construct(array $functions) - { - $this->functions = $functions; - $this->unaryOperators = ['not' => ['precedence' => 50], '!' => ['precedence' => 50], '-' => ['precedence' => 500], '+' => ['precedence' => 500]]; - $this->binaryOperators = ['or' => ['precedence' => 10, 'associativity' => self::OPERATOR_LEFT], '||' => ['precedence' => 10, 'associativity' => self::OPERATOR_LEFT], 'and' => ['precedence' => 15, 'associativity' => self::OPERATOR_LEFT], '&&' => ['precedence' => 15, 'associativity' => self::OPERATOR_LEFT], '|' => ['precedence' => 16, 'associativity' => self::OPERATOR_LEFT], '^' => ['precedence' => 17, 'associativity' => self::OPERATOR_LEFT], '&' => ['precedence' => 18, 'associativity' => self::OPERATOR_LEFT], '==' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '===' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '!=' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '!==' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '<' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '>' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '>=' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '<=' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], 'not in' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], 'in' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], 'matches' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '..' => ['precedence' => 25, 'associativity' => self::OPERATOR_LEFT], '+' => ['precedence' => 30, 'associativity' => self::OPERATOR_LEFT], '-' => ['precedence' => 30, 'associativity' => self::OPERATOR_LEFT], '~' => ['precedence' => 40, 'associativity' => self::OPERATOR_LEFT], '*' => ['precedence' => 60, 'associativity' => self::OPERATOR_LEFT], '/' => ['precedence' => 60, 'associativity' => self::OPERATOR_LEFT], '%' => ['precedence' => 60, 'associativity' => self::OPERATOR_LEFT], '**' => ['precedence' => 200, 'associativity' => self::OPERATOR_RIGHT]]; - } - /** - * Converts a token stream to a node tree. - * - * The valid names is an array where the values - * are the names that the user can use in an expression. - * - * If the variable name in the compiled PHP code must be - * different, define it as the key. - * - * For instance, ['this' => 'container'] means that the - * variable 'container' can be used in the expression - * but the compiled code will use 'this'. - * - * @param TokenStream $stream A token stream instance - * @param array $names An array of valid names - * - * @return Node\Node A node tree - * - * @throws SyntaxError - */ - public function parse(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\TokenStream $stream, $names = []) - { - $this->stream = $stream; - $this->names = $names; - $node = $this->parseExpression(); - if (!$stream->isEOF()) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unexpected token "%s" of value "%s".', $stream->current->type, $stream->current->value), $stream->current->cursor, $stream->getExpression()); - } - return $node; - } - public function parseExpression($precedence = 0) - { - $expr = $this->getPrimary(); - $token = $this->stream->current; - while ($token->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::OPERATOR_TYPE) && isset($this->binaryOperators[$token->value]) && $this->binaryOperators[$token->value]['precedence'] >= $precedence) { - $op = $this->binaryOperators[$token->value]; - $this->stream->next(); - $expr1 = $this->parseExpression(self::OPERATOR_LEFT === $op['associativity'] ? $op['precedence'] + 1 : $op['precedence']); - $expr = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode($token->value, $expr, $expr1); - $token = $this->stream->current; - } - if (0 === $precedence) { - return $this->parseConditionalExpression($expr); - } - return $expr; - } - protected function getPrimary() - { - $token = $this->stream->current; - if ($token->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::OPERATOR_TYPE) && isset($this->unaryOperators[$token->value])) { - $operator = $this->unaryOperators[$token->value]; - $this->stream->next(); - $expr = $this->parseExpression($operator['precedence']); - return $this->parsePostfixExpression(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode($token->value, $expr)); - } - if ($token->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '(')) { - $this->stream->next(); - $expr = $this->parseExpression(); - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ')', 'An opened parenthesis is not properly closed'); - return $this->parsePostfixExpression($expr); - } - return $this->parsePrimaryExpression(); - } - protected function parseConditionalExpression($expr) - { - while ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '?')) { - $this->stream->next(); - if (!$this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ':')) { - $expr2 = $this->parseExpression(); - if ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ':')) { - $this->stream->next(); - $expr3 = $this->parseExpression(); - } else { - $expr3 = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null); - } - } else { - $this->stream->next(); - $expr2 = $expr; - $expr3 = $this->parseExpression(); - } - $expr = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode($expr, $expr2, $expr3); - } - return $expr; - } - public function parsePrimaryExpression() - { - $token = $this->stream->current; - switch ($token->type) { - case \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NAME_TYPE: - $this->stream->next(); - switch ($token->value) { - case 'true': - case 'TRUE': - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true); - case 'false': - case 'FALSE': - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false); - case 'null': - case 'NULL': - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null); - default: - if ('(' === $this->stream->current->value) { - if (\false === isset($this->functions[$token->value])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('The function "%s" does not exist.', $token->value), $token->cursor, $this->stream->getExpression(), $token->value, \array_keys($this->functions)); - } - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\FunctionNode($token->value, $this->parseArguments()); - } else { - if (!\in_array($token->value, $this->names, \true)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Variable "%s" is not valid.', $token->value), $token->cursor, $this->stream->getExpression(), $token->value, $this->names); - } - // is the name used in the compiled code different - // from the name used in the expression? - if (\is_int($name = \array_search($token->value, $this->names))) { - $name = $token->value; - } - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode($name); - } - } - break; - case \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NUMBER_TYPE: - case \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::STRING_TYPE: - $this->stream->next(); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode($token->value); - default: - if ($token->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '[')) { - $node = $this->parseArrayExpression(); - } elseif ($token->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '{')) { - $node = $this->parseHashExpression(); - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unexpected token "%s" of value "%s".', $token->type, $token->value), $token->cursor, $this->stream->getExpression()); - } - } - return $this->parsePostfixExpression($node); - } - public function parseArrayExpression() - { - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '[', 'An array element was expected'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); - $first = \true; - while (!$this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ']')) { - if (!$first) { - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ',', 'An array element must be followed by a comma'); - // trailing ,? - if ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ']')) { - break; - } - } - $first = \false; - $node->addElement($this->parseExpression()); - } - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ']', 'An opened array is not properly closed'); - return $node; - } - public function parseHashExpression() - { - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '{', 'A hash element was expected'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); - $first = \true; - while (!$this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '}')) { - if (!$first) { - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ',', 'A hash value must be followed by a comma'); - // trailing ,? - if ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '}')) { - break; - } - } - $first = \false; - // a hash key can be: - // - // * a number -- 12 - // * a string -- 'a' - // * a name, which is equivalent to a string -- a - // * an expression, which must be enclosed in parentheses -- (1 + 2) - if ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::STRING_TYPE) || $this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NAME_TYPE) || $this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NUMBER_TYPE)) { - $key = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode($this->stream->current->value); - $this->stream->next(); - } elseif ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '(')) { - $key = $this->parseExpression(); - } else { - $current = $this->stream->current; - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('A hash key must be a quoted string, a number, a name, or an expression enclosed in parentheses (unexpected token "%s" of value "%s".', $current->type, $current->value), $current->cursor, $this->stream->getExpression()); - } - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ':', 'A hash key must be followed by a colon (:)'); - $value = $this->parseExpression(); - $node->addElement($value, $key); - } - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '}', 'An opened hash is not properly closed'); - return $node; - } - public function parsePostfixExpression($node) - { - $token = $this->stream->current; - while (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE == $token->type) { - if ('.' === $token->value) { - $this->stream->next(); - $token = $this->stream->current; - $this->stream->next(); - if (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NAME_TYPE !== $token->type && (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::OPERATOR_TYPE !== $token->type || !\preg_match('/[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*/A', $token->value))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError('Expected name.', $token->cursor, $this->stream->getExpression()); - } - $arg = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode($token->value, \true); - $arguments = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(); - if ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '(')) { - $type = \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL; - foreach ($this->parseArguments()->nodes as $n) { - $arguments->addElement($n); - } - } else { - $type = \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL; - } - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode($node, $arg, $arguments, $type); - } elseif ('[' === $token->value) { - $this->stream->next(); - $arg = $this->parseExpression(); - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ']'); - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode($node, $arg, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL); - } else { - break; - } - $token = $this->stream->current; - } - return $node; - } - /** - * Parses arguments. - */ - public function parseArguments() - { - $args = []; - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '(', 'A list of arguments must begin with an opening parenthesis'); - while (!$this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ')')) { - if (!empty($args)) { - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ',', 'Arguments must be separated by a comma'); - } - $args[] = $this->parseExpression(); - } - $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ')', 'A list of arguments must be closed by a parenthesis'); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node($args); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +/** + * Parsers a token stream. + * + * This parser implements a "Precedence climbing" algorithm. + * + * @see http://www.engr.mun.ca/~theo/Misc/exp_parsing.htm + * @see http://en.wikipedia.org/wiki/Operator-precedence_parser + * + * @author Fabien Potencier + */ +class Parser +{ + const OPERATOR_LEFT = 1; + const OPERATOR_RIGHT = 2; + private $stream; + private $unaryOperators; + private $binaryOperators; + private $functions; + private $names; + public function __construct(array $functions) + { + $this->functions = $functions; + $this->unaryOperators = ['not' => ['precedence' => 50], '!' => ['precedence' => 50], '-' => ['precedence' => 500], '+' => ['precedence' => 500]]; + $this->binaryOperators = ['or' => ['precedence' => 10, 'associativity' => self::OPERATOR_LEFT], '||' => ['precedence' => 10, 'associativity' => self::OPERATOR_LEFT], 'and' => ['precedence' => 15, 'associativity' => self::OPERATOR_LEFT], '&&' => ['precedence' => 15, 'associativity' => self::OPERATOR_LEFT], '|' => ['precedence' => 16, 'associativity' => self::OPERATOR_LEFT], '^' => ['precedence' => 17, 'associativity' => self::OPERATOR_LEFT], '&' => ['precedence' => 18, 'associativity' => self::OPERATOR_LEFT], '==' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '===' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '!=' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '!==' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '<' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '>' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '>=' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '<=' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], 'not in' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], 'in' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], 'matches' => ['precedence' => 20, 'associativity' => self::OPERATOR_LEFT], '..' => ['precedence' => 25, 'associativity' => self::OPERATOR_LEFT], '+' => ['precedence' => 30, 'associativity' => self::OPERATOR_LEFT], '-' => ['precedence' => 30, 'associativity' => self::OPERATOR_LEFT], '~' => ['precedence' => 40, 'associativity' => self::OPERATOR_LEFT], '*' => ['precedence' => 60, 'associativity' => self::OPERATOR_LEFT], '/' => ['precedence' => 60, 'associativity' => self::OPERATOR_LEFT], '%' => ['precedence' => 60, 'associativity' => self::OPERATOR_LEFT], '**' => ['precedence' => 200, 'associativity' => self::OPERATOR_RIGHT]]; + } + /** + * Converts a token stream to a node tree. + * + * The valid names is an array where the values + * are the names that the user can use in an expression. + * + * If the variable name in the compiled PHP code must be + * different, define it as the key. + * + * For instance, ['this' => 'container'] means that the + * variable 'container' can be used in the expression + * but the compiled code will use 'this'. + * + * @param TokenStream $stream A token stream instance + * @param array $names An array of valid names + * + * @return Node\Node A node tree + * + * @throws SyntaxError + */ + public function parse(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\TokenStream $stream, $names = []) + { + $this->stream = $stream; + $this->names = $names; + $node = $this->parseExpression(); + if (!$stream->isEOF()) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unexpected token "%s" of value "%s".', $stream->current->type, $stream->current->value), $stream->current->cursor, $stream->getExpression()); + } + return $node; + } + public function parseExpression($precedence = 0) + { + $expr = $this->getPrimary(); + $token = $this->stream->current; + while ($token->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::OPERATOR_TYPE) && isset($this->binaryOperators[$token->value]) && $this->binaryOperators[$token->value]['precedence'] >= $precedence) { + $op = $this->binaryOperators[$token->value]; + $this->stream->next(); + $expr1 = $this->parseExpression(self::OPERATOR_LEFT === $op['associativity'] ? $op['precedence'] + 1 : $op['precedence']); + $expr = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode($token->value, $expr, $expr1); + $token = $this->stream->current; + } + if (0 === $precedence) { + return $this->parseConditionalExpression($expr); + } + return $expr; + } + protected function getPrimary() + { + $token = $this->stream->current; + if ($token->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::OPERATOR_TYPE) && isset($this->unaryOperators[$token->value])) { + $operator = $this->unaryOperators[$token->value]; + $this->stream->next(); + $expr = $this->parseExpression($operator['precedence']); + return $this->parsePostfixExpression(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode($token->value, $expr)); + } + if ($token->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '(')) { + $this->stream->next(); + $expr = $this->parseExpression(); + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ')', 'An opened parenthesis is not properly closed'); + return $this->parsePostfixExpression($expr); + } + return $this->parsePrimaryExpression(); + } + protected function parseConditionalExpression($expr) + { + while ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '?')) { + $this->stream->next(); + if (!$this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ':')) { + $expr2 = $this->parseExpression(); + if ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ':')) { + $this->stream->next(); + $expr3 = $this->parseExpression(); + } else { + $expr3 = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null); + } + } else { + $this->stream->next(); + $expr2 = $expr; + $expr3 = $this->parseExpression(); + } + $expr = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode($expr, $expr2, $expr3); + } + return $expr; + } + public function parsePrimaryExpression() + { + $token = $this->stream->current; + switch ($token->type) { + case \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NAME_TYPE: + $this->stream->next(); + switch ($token->value) { + case 'true': + case 'TRUE': + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true); + case 'false': + case 'FALSE': + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false); + case 'null': + case 'NULL': + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null); + default: + if ('(' === $this->stream->current->value) { + if (\false === isset($this->functions[$token->value])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('The function "%s" does not exist.', $token->value), $token->cursor, $this->stream->getExpression(), $token->value, \array_keys($this->functions)); + } + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\FunctionNode($token->value, $this->parseArguments()); + } else { + if (!\in_array($token->value, $this->names, \true)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Variable "%s" is not valid.', $token->value), $token->cursor, $this->stream->getExpression(), $token->value, $this->names); + } + // is the name used in the compiled code different + // from the name used in the expression? + if (\is_int($name = \array_search($token->value, $this->names))) { + $name = $token->value; + } + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode($name); + } + } + break; + case \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NUMBER_TYPE: + case \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::STRING_TYPE: + $this->stream->next(); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode($token->value); + default: + if ($token->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '[')) { + $node = $this->parseArrayExpression(); + } elseif ($token->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '{')) { + $node = $this->parseHashExpression(); + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('Unexpected token "%s" of value "%s".', $token->type, $token->value), $token->cursor, $this->stream->getExpression()); + } + } + return $this->parsePostfixExpression($node); + } + public function parseArrayExpression() + { + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '[', 'An array element was expected'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); + $first = \true; + while (!$this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ']')) { + if (!$first) { + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ',', 'An array element must be followed by a comma'); + // trailing ,? + if ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ']')) { + break; + } + } + $first = \false; + $node->addElement($this->parseExpression()); + } + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ']', 'An opened array is not properly closed'); + return $node; + } + public function parseHashExpression() + { + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '{', 'A hash element was expected'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); + $first = \true; + while (!$this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '}')) { + if (!$first) { + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ',', 'A hash value must be followed by a comma'); + // trailing ,? + if ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '}')) { + break; + } + } + $first = \false; + // a hash key can be: + // + // * a number -- 12 + // * a string -- 'a' + // * a name, which is equivalent to a string -- a + // * an expression, which must be enclosed in parentheses -- (1 + 2) + if ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::STRING_TYPE) || $this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NAME_TYPE) || $this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NUMBER_TYPE)) { + $key = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode($this->stream->current->value); + $this->stream->next(); + } elseif ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '(')) { + $key = $this->parseExpression(); + } else { + $current = $this->stream->current; + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('A hash key must be a quoted string, a number, a name, or an expression enclosed in parentheses (unexpected token "%s" of value "%s".', $current->type, $current->value), $current->cursor, $this->stream->getExpression()); + } + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ':', 'A hash key must be followed by a colon (:)'); + $value = $this->parseExpression(); + $node->addElement($value, $key); + } + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '}', 'An opened hash is not properly closed'); + return $node; + } + public function parsePostfixExpression($node) + { + $token = $this->stream->current; + while (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE == $token->type) { + if ('.' === $token->value) { + $this->stream->next(); + $token = $this->stream->current; + $this->stream->next(); + if (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::NAME_TYPE !== $token->type && (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::OPERATOR_TYPE !== $token->type || !\preg_match('/[a-zA-Z_\\x7f-\\xff][a-zA-Z0-9_\\x7f-\\xff]*/A', $token->value))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError('Expected name.', $token->cursor, $this->stream->getExpression()); + } + $arg = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode($token->value, \true); + $arguments = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(); + if ($this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '(')) { + $type = \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL; + foreach ($this->parseArguments()->nodes as $n) { + $arguments->addElement($n); + } + } else { + $type = \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL; + } + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode($node, $arg, $arguments, $type); + } elseif ('[' === $token->value) { + $this->stream->next(); + $arg = $this->parseExpression(); + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ']'); + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode($node, $arg, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL); + } else { + break; + } + $token = $this->stream->current; + } + return $node; + } + /** + * Parses arguments. + */ + public function parseArguments() + { + $args = []; + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, '(', 'A list of arguments must begin with an opening parenthesis'); + while (!$this->stream->current->test(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ')')) { + if (!empty($args)) { + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ',', 'Arguments must be separated by a comma'); + } + $args[] = $this->parseExpression(); + } + $this->stream->expect(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::PUNCTUATION_TYPE, ')', 'A list of arguments must be closed by a parenthesis'); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node($args); + } +} diff --git a/vendor/symfony/expression-language/ParserCache/ArrayParserCache.php b/vendor/symfony/expression-language/ParserCache/ArrayParserCache.php index e73c1beda..b107ad14c 100644 --- a/vendor/symfony/expression-language/ParserCache/ArrayParserCache.php +++ b/vendor/symfony/expression-language/ParserCache/ArrayParserCache.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache; - -@\trigger_error('The ' . __NAMESPACE__ . '\\ArrayParserCache class is deprecated since Symfony 3.2 and will be removed in 4.0. Use the Symfony\\Component\\Cache\\Adapter\\ArrayAdapter class instead.', \E_USER_DEPRECATED); -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression; -/** - * @author Adrien Brault - * - * @deprecated ArrayParserCache class is deprecated since version 3.2 and will be removed in 4.0. Use the Symfony\Component\Cache\Adapter\ArrayAdapter class instead. - */ -class ArrayParserCache implements \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheInterface -{ - private $cache = []; - /** - * {@inheritdoc} - */ - public function fetch($key) - { - return isset($this->cache[$key]) ? $this->cache[$key] : null; - } - /** - * {@inheritdoc} - */ - public function save($key, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression $expression) - { - $this->cache[$key] = $expression; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache; + +@\trigger_error('The ' . __NAMESPACE__ . '\\ArrayParserCache class is deprecated since Symfony 3.2 and will be removed in 4.0. Use the Symfony\\Component\\Cache\\Adapter\\ArrayAdapter class instead.', \E_USER_DEPRECATED); +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression; +/** + * @author Adrien Brault + * + * @deprecated ArrayParserCache class is deprecated since version 3.2 and will be removed in 4.0. Use the Symfony\Component\Cache\Adapter\ArrayAdapter class instead. + */ +class ArrayParserCache implements \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheInterface +{ + private $cache = []; + /** + * {@inheritdoc} + */ + public function fetch($key) + { + return isset($this->cache[$key]) ? $this->cache[$key] : null; + } + /** + * {@inheritdoc} + */ + public function save($key, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression $expression) + { + $this->cache[$key] = $expression; + } +} diff --git a/vendor/symfony/expression-language/ParserCache/ParserCacheAdapter.php b/vendor/symfony/expression-language/ParserCache/ParserCacheAdapter.php index ec638982e..94578aca2 100644 --- a/vendor/symfony/expression-language/ParserCache/ParserCacheAdapter.php +++ b/vendor/symfony/expression-language/ParserCache/ParserCacheAdapter.php @@ -1,101 +1,101 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache; - -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; -use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; -/** - * @author Alexandre GESLIN - * - * @internal and will be removed in Symfony 4.0. - */ -class ParserCacheAdapter implements \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface -{ - private $pool; - private $createCacheItem; - public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheInterface $pool) - { - $this->pool = $pool; - $this->createCacheItem = \Closure::bind(static function ($key, $value, $isHit) { - $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); - $item->key = $key; - $item->value = $value; - $item->isHit = $isHit; - return $item; - }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); - } - /** - * {@inheritdoc} - */ - public function getItem($key) - { - $value = $this->pool->fetch($key); - $f = $this->createCacheItem; - return $f($key, $value, null !== $value); - } - /** - * {@inheritdoc} - */ - public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - $this->pool->save($item->getKey(), $item->get()); - } - /** - * {@inheritdoc} - */ - public function getItems(array $keys = []) - { - throw new \BadMethodCallException('Not implemented.'); - } - /** - * {@inheritdoc} - */ - public function hasItem($key) - { - throw new \BadMethodCallException('Not implemented.'); - } - /** - * {@inheritdoc} - */ - public function clear() - { - throw new \BadMethodCallException('Not implemented.'); - } - /** - * {@inheritdoc} - */ - public function deleteItem($key) - { - throw new \BadMethodCallException('Not implemented.'); - } - /** - * {@inheritdoc} - */ - public function deleteItems(array $keys) - { - throw new \BadMethodCallException('Not implemented.'); - } - /** - * {@inheritdoc} - */ - public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) - { - throw new \BadMethodCallException('Not implemented.'); - } - /** - * {@inheritdoc} - */ - public function commit() - { - throw new \BadMethodCallException('Not implemented.'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache; + +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface; +use _PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem; +/** + * @author Alexandre GESLIN + * + * @internal and will be removed in Symfony 4.0. + */ +class ParserCacheAdapter implements \_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemPoolInterface +{ + private $pool; + private $createCacheItem; + public function __construct(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheInterface $pool) + { + $this->pool = $pool; + $this->createCacheItem = \Closure::bind(static function ($key, $value, $isHit) { + $item = new \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem(); + $item->key = $key; + $item->value = $value; + $item->isHit = $isHit; + return $item; + }, null, \_PhpScoper5ea00cc67502b\Symfony\Component\Cache\CacheItem::class); + } + /** + * {@inheritdoc} + */ + public function getItem($key) + { + $value = $this->pool->fetch($key); + $f = $this->createCacheItem; + return $f($key, $value, null !== $value); + } + /** + * {@inheritdoc} + */ + public function save(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + $this->pool->save($item->getKey(), $item->get()); + } + /** + * {@inheritdoc} + */ + public function getItems(array $keys = []) + { + throw new \BadMethodCallException('Not implemented.'); + } + /** + * {@inheritdoc} + */ + public function hasItem($key) + { + throw new \BadMethodCallException('Not implemented.'); + } + /** + * {@inheritdoc} + */ + public function clear() + { + throw new \BadMethodCallException('Not implemented.'); + } + /** + * {@inheritdoc} + */ + public function deleteItem($key) + { + throw new \BadMethodCallException('Not implemented.'); + } + /** + * {@inheritdoc} + */ + public function deleteItems(array $keys) + { + throw new \BadMethodCallException('Not implemented.'); + } + /** + * {@inheritdoc} + */ + public function saveDeferred(\_PhpScoper5ea00cc67502b\Psr\Cache\CacheItemInterface $item) + { + throw new \BadMethodCallException('Not implemented.'); + } + /** + * {@inheritdoc} + */ + public function commit() + { + throw new \BadMethodCallException('Not implemented.'); + } +} diff --git a/vendor/symfony/expression-language/ParserCache/ParserCacheInterface.php b/vendor/symfony/expression-language/ParserCache/ParserCacheInterface.php index 2e72ba023..9318b3f12 100644 --- a/vendor/symfony/expression-language/ParserCache/ParserCacheInterface.php +++ b/vendor/symfony/expression-language/ParserCache/ParserCacheInterface.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache; - -@\trigger_error('The ' . __NAMESPACE__ . '\\ParserCacheInterface interface is deprecated since Symfony 3.2 and will be removed in 4.0. Use Psr\\Cache\\CacheItemPoolInterface instead.', \E_USER_DEPRECATED); -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression; -/** - * @author Adrien Brault - * - * @deprecated since version 3.2, to be removed in 4.0. Use Psr\Cache\CacheItemPoolInterface instead. - */ -interface ParserCacheInterface -{ - /** - * Saves an expression in the cache. - * - * @param string $key The cache key - * @param ParsedExpression $expression A ParsedExpression instance to store in the cache - */ - public function save($key, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression $expression); - /** - * Fetches an expression from the cache. - * - * @param string $key The cache key - * - * @return ParsedExpression|null - */ - public function fetch($key); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache; + +@\trigger_error('The ' . __NAMESPACE__ . '\\ParserCacheInterface interface is deprecated since Symfony 3.2 and will be removed in 4.0. Use Psr\\Cache\\CacheItemPoolInterface instead.', \E_USER_DEPRECATED); +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression; +/** + * @author Adrien Brault + * + * @deprecated since version 3.2, to be removed in 4.0. Use Psr\Cache\CacheItemPoolInterface instead. + */ +interface ParserCacheInterface +{ + /** + * Saves an expression in the cache. + * + * @param string $key The cache key + * @param ParsedExpression $expression A ParsedExpression instance to store in the cache + */ + public function save($key, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression $expression); + /** + * Fetches an expression from the cache. + * + * @param string $key The cache key + * + * @return ParsedExpression|null + */ + public function fetch($key); +} diff --git a/vendor/symfony/expression-language/ParserCache/index.php b/vendor/symfony/expression-language/ParserCache/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/expression-language/ParserCache/index.php +++ b/vendor/symfony/expression-language/ParserCache/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/README.md b/vendor/symfony/expression-language/README.md index 08b310d10..ff127bdae 100644 --- a/vendor/symfony/expression-language/README.md +++ b/vendor/symfony/expression-language/README.md @@ -1,15 +1,15 @@ -ExpressionLanguage Component -============================ - -The ExpressionLanguage component provides an engine that can compile and -evaluate expressions. An expression is a one-liner that returns a value -(mostly, but not limited to, Booleans). - -Resources ---------- - - * [Documentation](https://symfony.com/doc/current/components/expression_language/introduction.html) - * [Contributing](https://symfony.com/doc/current/contributing/index.html) - * [Report issues](https://github.com/symfony/symfony/issues) and - [send Pull Requests](https://github.com/symfony/symfony/pulls) - in the [main Symfony repository](https://github.com/symfony/symfony) +ExpressionLanguage Component +============================ + +The ExpressionLanguage component provides an engine that can compile and +evaluate expressions. An expression is a one-liner that returns a value +(mostly, but not limited to, Booleans). + +Resources +--------- + + * [Documentation](https://symfony.com/doc/current/components/expression_language/introduction.html) + * [Contributing](https://symfony.com/doc/current/contributing/index.html) + * [Report issues](https://github.com/symfony/symfony/issues) and + [send Pull Requests](https://github.com/symfony/symfony/pulls) + in the [main Symfony repository](https://github.com/symfony/symfony) diff --git a/vendor/symfony/expression-language/Resources/bin/generate_operator_regex.php b/vendor/symfony/expression-language/Resources/bin/generate_operator_regex.php index 280451388..ccbd16187 100644 --- a/vendor/symfony/expression-language/Resources/bin/generate_operator_regex.php +++ b/vendor/symfony/expression-language/Resources/bin/generate_operator_regex.php @@ -1,23 +1,23 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -$operators = ['not', '!', 'or', '||', '&&', 'and', '|', '^', '&', '==', '===', '!=', '!==', '<', '>', '>=', '<=', 'not in', 'in', '..', '+', '-', '~', '*', '/', '%', 'matches', '**']; -$operators = \array_combine($operators, \array_map('strlen', $operators)); -\arsort($operators); -$regex = []; -foreach ($operators as $operator => $length) { - // Collisions of character operators: - // - an operator that begins with a character must have a space or a parenthesis before or starting at the beginning of a string - // - an operator that ends with a character must be followed by a whitespace or a parenthesis - $regex[] = (\ctype_alpha($operator[0]) ? '(?<=^|[\\s(])' : '') . \preg_quote($operator, '/') . (\ctype_alpha($operator[$length - 1]) ? '(?=[\\s(])' : ''); -} -echo '/' . \implode('|', $regex) . '/A'; + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +$operators = ['not', '!', 'or', '||', '&&', 'and', '|', '^', '&', '==', '===', '!=', '!==', '<', '>', '>=', '<=', 'not in', 'in', '..', '+', '-', '~', '*', '/', '%', 'matches', '**']; +$operators = \array_combine($operators, \array_map('strlen', $operators)); +\arsort($operators); +$regex = []; +foreach ($operators as $operator => $length) { + // Collisions of character operators: + // - an operator that begins with a character must have a space or a parenthesis before or starting at the beginning of a string + // - an operator that ends with a character must be followed by a whitespace or a parenthesis + $regex[] = (\ctype_alpha($operator[0]) ? '(?<=^|[\\s(])' : '') . \preg_quote($operator, '/') . (\ctype_alpha($operator[$length - 1]) ? '(?=[\\s(])' : ''); +} +echo '/' . \implode('|', $regex) . '/A'; diff --git a/vendor/symfony/expression-language/Resources/bin/index.php b/vendor/symfony/expression-language/Resources/bin/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/expression-language/Resources/bin/index.php +++ b/vendor/symfony/expression-language/Resources/bin/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Resources/index.php b/vendor/symfony/expression-language/Resources/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/expression-language/Resources/index.php +++ b/vendor/symfony/expression-language/Resources/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/SerializedParsedExpression.php b/vendor/symfony/expression-language/SerializedParsedExpression.php index 15930dd24..d4a4c05a4 100644 --- a/vendor/symfony/expression-language/SerializedParsedExpression.php +++ b/vendor/symfony/expression-language/SerializedParsedExpression.php @@ -1,34 +1,34 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -/** - * Represents an already parsed expression. - * - * @author Fabien Potencier - */ -class SerializedParsedExpression extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression -{ - private $nodes; - /** - * @param string $expression An expression - * @param string $nodes The serialized nodes for the expression - */ - public function __construct($expression, $nodes) - { - $this->expression = (string) $expression; - $this->nodes = $nodes; - } - public function getNodes() - { - return \unserialize($this->nodes); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +/** + * Represents an already parsed expression. + * + * @author Fabien Potencier + */ +class SerializedParsedExpression extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression +{ + private $nodes; + /** + * @param string $expression An expression + * @param string $nodes The serialized nodes for the expression + */ + public function __construct($expression, $nodes) + { + $this->expression = (string) $expression; + $this->nodes = $nodes; + } + public function getNodes() + { + return \unserialize($this->nodes); + } +} diff --git a/vendor/symfony/expression-language/SyntaxError.php b/vendor/symfony/expression-language/SyntaxError.php index 8c2cf73f7..7bf3d3062 100644 --- a/vendor/symfony/expression-language/SyntaxError.php +++ b/vendor/symfony/expression-language/SyntaxError.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -class SyntaxError extends \LogicException -{ - public function __construct($message, $cursor = 0, $expression = '', $subject = null, array $proposals = null) - { - $message = \sprintf('%s around position %d', \rtrim($message, '.'), $cursor); - if ($expression) { - $message = \sprintf('%s for expression `%s`', $message, $expression); - } - $message .= '.'; - if (null !== $subject && null !== $proposals) { - $minScore = \INF; - foreach ($proposals as $proposal) { - $distance = \levenshtein($subject, $proposal); - if ($distance < $minScore) { - $guess = $proposal; - $minScore = $distance; - } - } - if (isset($guess) && $minScore < 3) { - $message .= \sprintf(' Did you mean "%s"?', $guess); - } - } - parent::__construct($message); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +class SyntaxError extends \LogicException +{ + public function __construct($message, $cursor = 0, $expression = '', $subject = null, array $proposals = null) + { + $message = \sprintf('%s around position %d', \rtrim($message, '.'), $cursor); + if ($expression) { + $message = \sprintf('%s for expression `%s`', $message, $expression); + } + $message .= '.'; + if (null !== $subject && null !== $proposals) { + $minScore = \INF; + foreach ($proposals as $proposal) { + $distance = \levenshtein($subject, $proposal); + if ($distance < $minScore) { + $guess = $proposal; + $minScore = $distance; + } + } + if (isset($guess) && $minScore < 3) { + $message .= \sprintf(' Did you mean "%s"?', $guess); + } + } + parent::__construct($message); + } +} diff --git a/vendor/symfony/expression-language/Tests/ExpressionFunctionTest.php b/vendor/symfony/expression-language/Tests/ExpressionFunctionTest.php index d806a27e3..90a8c6955 100644 --- a/vendor/symfony/expression-language/Tests/ExpressionFunctionTest.php +++ b/vendor/symfony/expression-language/Tests/ExpressionFunctionTest.php @@ -1,37 +1,37 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction; -/** - * Tests ExpressionFunction. - * - * @author Dany Maillard - */ -class ExpressionFunctionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testFunctionDoesNotExist() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('PHP function "fn_does_not_exist" does not exist.'); - \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('fn_does_not_exist'); - } - public function testFunctionNamespaced() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('An expression function name must be defined when PHP function "Symfony\\Component\\ExpressionLanguage\\Tests\\fn_namespaced" is namespaced.'); - \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Tests\\fn_namespaced'); - } -} -function fn_namespaced() -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction; +/** + * Tests ExpressionFunction. + * + * @author Dany Maillard + */ +class ExpressionFunctionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testFunctionDoesNotExist() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('PHP function "fn_does_not_exist" does not exist.'); + \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('fn_does_not_exist'); + } + public function testFunctionNamespaced() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('An expression function name must be defined when PHP function "Symfony\\Component\\ExpressionLanguage\\Tests\\fn_namespaced" is namespaced.'); + \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Tests\\fn_namespaced'); + } +} +function fn_namespaced() +{ +} diff --git a/vendor/symfony/expression-language/Tests/ExpressionLanguageTest.php b/vendor/symfony/expression-language/Tests/ExpressionLanguageTest.php index 09185b93c..0df5d9cdc 100644 --- a/vendor/symfony/expression-language/Tests/ExpressionLanguageTest.php +++ b/vendor/symfony/expression-language/Tests/ExpressionLanguageTest.php @@ -1,208 +1,208 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Fixtures\TestProvider; -class ExpressionLanguageTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testCachedParse() - { - $cacheMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemPoolInterface')->getMock(); - $cacheItemMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface')->getMock(); - $savedParsedExpression = null; - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage($cacheMock); - $cacheMock->expects($this->exactly(2))->method('getItem')->with('1%20%2B%201%2F%2F')->willReturn($cacheItemMock); - $cacheItemMock->expects($this->exactly(2))->method('get')->willReturnCallback(function () use(&$savedParsedExpression) { - return $savedParsedExpression; - }); - $cacheItemMock->expects($this->exactly(1))->method('set')->with($this->isInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression::class))->willReturnCallback(function ($parsedExpression) use(&$savedParsedExpression) { - $savedParsedExpression = $parsedExpression; - }); - $cacheMock->expects($this->exactly(1))->method('save')->with($cacheItemMock); - $parsedExpression = $expressionLanguage->parse('1 + 1', []); - $this->assertSame($savedParsedExpression, $parsedExpression); - $parsedExpression = $expressionLanguage->parse('1 + 1', []); - $this->assertSame($savedParsedExpression, $parsedExpression); - } - /** - * @group legacy - */ - public function testCachedParseWithDeprecatedParserCacheInterface() - { - $cacheMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); - $savedParsedExpression = null; - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage($cacheMock); - $cacheMock->expects($this->exactly(1))->method('fetch')->with('1%20%2B%201%2F%2F')->willReturn($savedParsedExpression); - $cacheMock->expects($this->exactly(1))->method('save')->with('1%20%2B%201%2F%2F', $this->isInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression::class))->willReturnCallback(function ($key, $expression) use(&$savedParsedExpression) { - $savedParsedExpression = $expression; - }); - $parsedExpression = $expressionLanguage->parse('1 + 1', []); - $this->assertSame($savedParsedExpression, $parsedExpression); - } - public function testWrongCacheImplementation() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('Cache argument has to implement "Psr\\Cache\\CacheItemPoolInterface".'); - $cacheMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemSpoolInterface')->getMock(); - new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage($cacheMock); - } - public function testConstantFunction() - { - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $this->assertEquals(\PHP_VERSION, $expressionLanguage->evaluate('constant("PHP_VERSION")')); - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $this->assertEquals('\\constant("PHP_VERSION")', $expressionLanguage->compile('constant("PHP_VERSION")')); - } - public function testProviders() - { - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(null, [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Fixtures\TestProvider()]); - $this->assertEquals('foo', $expressionLanguage->evaluate('identity("foo")')); - $this->assertEquals('"foo"', $expressionLanguage->compile('identity("foo")')); - $this->assertEquals('FOO', $expressionLanguage->evaluate('strtoupper("foo")')); - $this->assertEquals('\\strtoupper("foo")', $expressionLanguage->compile('strtoupper("foo")')); - $this->assertEquals('foo', $expressionLanguage->evaluate('strtolower("FOO")')); - $this->assertEquals('\\strtolower("FOO")', $expressionLanguage->compile('strtolower("FOO")')); - $this->assertTrue($expressionLanguage->evaluate('fn_namespaced()')); - $this->assertEquals('\\Symfony\\Component\\ExpressionLanguage\\Tests\\Fixtures\\fn_namespaced()', $expressionLanguage->compile('fn_namespaced()')); - } - /** - * @dataProvider shortCircuitProviderEvaluate - */ - public function testShortCircuitOperatorsEvaluate($expression, array $values, $expected) - { - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $this->assertEquals($expected, $expressionLanguage->evaluate($expression, $values)); - } - /** - * @dataProvider shortCircuitProviderCompile - */ - public function testShortCircuitOperatorsCompile($expression, array $names, $expected) - { - $result = null; - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - eval(\sprintf('$result = %s;', $expressionLanguage->compile($expression, $names))); - $this->assertSame($expected, $result); - } - public function testParseThrowsInsteadOfNotice() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); - $this->expectExceptionMessage('Unexpected end of expression around position 6 for expression `node.`.'); - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $expressionLanguage->parse('node.', ['node']); - } - public function shortCircuitProviderEvaluate() - { - $object = $this->getMockBuilder('stdClass')->setMethods(['foo'])->getMock(); - $object->expects($this->never())->method('foo'); - return [['false and object.foo()', ['object' => $object], \false], ['false && object.foo()', ['object' => $object], \false], ['true || object.foo()', ['object' => $object], \true], ['true or object.foo()', ['object' => $object], \true]]; - } - public function shortCircuitProviderCompile() - { - return [['false and foo', ['foo' => 'foo'], \false], ['false && foo', ['foo' => 'foo'], \false], ['true || foo', ['foo' => 'foo'], \true], ['true or foo', ['foo' => 'foo'], \true]]; - } - public function testCachingForOverriddenVariableNames() - { - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $expression = 'a + b'; - $expressionLanguage->evaluate($expression, ['a' => 1, 'b' => 1]); - $result = $expressionLanguage->compile($expression, ['a', 'B' => 'b']); - $this->assertSame('($a + $B)', $result); - } - public function testStrictEquality() - { - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $expression = '123 === a'; - $result = $expressionLanguage->compile($expression, ['a']); - $this->assertSame('(123 === $a)', $result); - } - public function testCachingWithDifferentNamesOrder() - { - $cacheMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemPoolInterface')->getMock(); - $cacheItemMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface')->getMock(); - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage($cacheMock); - $savedParsedExpression = null; - $cacheMock->expects($this->exactly(2))->method('getItem')->with('a%20%2B%20b%2F%2Fa%7CB%3Ab')->willReturn($cacheItemMock); - $cacheItemMock->expects($this->exactly(2))->method('get')->willReturnCallback(function () use(&$savedParsedExpression) { - return $savedParsedExpression; - }); - $cacheItemMock->expects($this->exactly(1))->method('set')->with($this->isInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression::class))->willReturnCallback(function ($parsedExpression) use(&$savedParsedExpression) { - $savedParsedExpression = $parsedExpression; - }); - $cacheMock->expects($this->exactly(1))->method('save')->with($cacheItemMock); - $expression = 'a + b'; - $expressionLanguage->compile($expression, ['a', 'B' => 'b']); - $expressionLanguage->compile($expression, ['B' => 'b', 'a']); - } - public function testOperatorCollisions() - { - $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $expression = 'foo.not in [bar]'; - $compiled = $expressionLanguage->compile($expression, ['foo', 'bar']); - $this->assertSame('in_array($foo->not, [0 => $bar])', $compiled); - $result = $expressionLanguage->evaluate($expression, ['foo' => (object) ['not' => 'test'], 'bar' => 'test']); - $this->assertTrue($result); - } - /** - * @dataProvider getRegisterCallbacks - */ - public function testRegisterAfterParse($registerCallback) - { - $this->expectException('LogicException'); - $el = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $el->parse('1 + 1', []); - $registerCallback($el); - } - /** - * @dataProvider getRegisterCallbacks - */ - public function testRegisterAfterEval($registerCallback) - { - $this->expectException('LogicException'); - $el = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $el->evaluate('1 + 1'); - $registerCallback($el); - } - public function testCallBadCallable() - { - $this->expectException('RuntimeException'); - $this->expectExceptionMessageRegExp('/Unable to call method "\\w+" of object "\\w+"./'); - $el = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $el->evaluate('foo.myfunction()', ['foo' => new \stdClass()]); - } - /** - * @dataProvider getRegisterCallbacks - */ - public function testRegisterAfterCompile($registerCallback) - { - $this->expectException('LogicException'); - $el = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); - $el->compile('1 + 1'); - $registerCallback($el); - } - public function getRegisterCallbacks() - { - return [[function (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage $el) { - $el->register('fn', function () { - }, function () { - }); - }], [function (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage $el) { - $el->addFunction(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction('fn', function () { - }, function () { - })); - }], [function (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage $el) { - $el->registerProvider(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Fixtures\TestProvider()); - }]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Fixtures\TestProvider; +class ExpressionLanguageTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testCachedParse() + { + $cacheMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemPoolInterface')->getMock(); + $cacheItemMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface')->getMock(); + $savedParsedExpression = null; + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage($cacheMock); + $cacheMock->expects($this->exactly(2))->method('getItem')->with('1%20%2B%201%2F%2F')->willReturn($cacheItemMock); + $cacheItemMock->expects($this->exactly(2))->method('get')->willReturnCallback(function () use(&$savedParsedExpression) { + return $savedParsedExpression; + }); + $cacheItemMock->expects($this->exactly(1))->method('set')->with($this->isInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression::class))->willReturnCallback(function ($parsedExpression) use(&$savedParsedExpression) { + $savedParsedExpression = $parsedExpression; + }); + $cacheMock->expects($this->exactly(1))->method('save')->with($cacheItemMock); + $parsedExpression = $expressionLanguage->parse('1 + 1', []); + $this->assertSame($savedParsedExpression, $parsedExpression); + $parsedExpression = $expressionLanguage->parse('1 + 1', []); + $this->assertSame($savedParsedExpression, $parsedExpression); + } + /** + * @group legacy + */ + public function testCachedParseWithDeprecatedParserCacheInterface() + { + $cacheMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); + $savedParsedExpression = null; + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage($cacheMock); + $cacheMock->expects($this->exactly(1))->method('fetch')->with('1%20%2B%201%2F%2F')->willReturn($savedParsedExpression); + $cacheMock->expects($this->exactly(1))->method('save')->with('1%20%2B%201%2F%2F', $this->isInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression::class))->willReturnCallback(function ($key, $expression) use(&$savedParsedExpression) { + $savedParsedExpression = $expression; + }); + $parsedExpression = $expressionLanguage->parse('1 + 1', []); + $this->assertSame($savedParsedExpression, $parsedExpression); + } + public function testWrongCacheImplementation() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('Cache argument has to implement "Psr\\Cache\\CacheItemPoolInterface".'); + $cacheMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemSpoolInterface')->getMock(); + new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage($cacheMock); + } + public function testConstantFunction() + { + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $this->assertEquals(\PHP_VERSION, $expressionLanguage->evaluate('constant("PHP_VERSION")')); + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $this->assertEquals('\\constant("PHP_VERSION")', $expressionLanguage->compile('constant("PHP_VERSION")')); + } + public function testProviders() + { + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(null, [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Fixtures\TestProvider()]); + $this->assertEquals('foo', $expressionLanguage->evaluate('identity("foo")')); + $this->assertEquals('"foo"', $expressionLanguage->compile('identity("foo")')); + $this->assertEquals('FOO', $expressionLanguage->evaluate('strtoupper("foo")')); + $this->assertEquals('\\strtoupper("foo")', $expressionLanguage->compile('strtoupper("foo")')); + $this->assertEquals('foo', $expressionLanguage->evaluate('strtolower("FOO")')); + $this->assertEquals('\\strtolower("FOO")', $expressionLanguage->compile('strtolower("FOO")')); + $this->assertTrue($expressionLanguage->evaluate('fn_namespaced()')); + $this->assertEquals('\\Symfony\\Component\\ExpressionLanguage\\Tests\\Fixtures\\fn_namespaced()', $expressionLanguage->compile('fn_namespaced()')); + } + /** + * @dataProvider shortCircuitProviderEvaluate + */ + public function testShortCircuitOperatorsEvaluate($expression, array $values, $expected) + { + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $this->assertEquals($expected, $expressionLanguage->evaluate($expression, $values)); + } + /** + * @dataProvider shortCircuitProviderCompile + */ + public function testShortCircuitOperatorsCompile($expression, array $names, $expected) + { + $result = null; + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + eval(\sprintf('$result = %s;', $expressionLanguage->compile($expression, $names))); + $this->assertSame($expected, $result); + } + public function testParseThrowsInsteadOfNotice() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); + $this->expectExceptionMessage('Unexpected end of expression around position 6 for expression `node.`.'); + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $expressionLanguage->parse('node.', ['node']); + } + public function shortCircuitProviderEvaluate() + { + $object = $this->getMockBuilder('stdClass')->setMethods(['foo'])->getMock(); + $object->expects($this->never())->method('foo'); + return [['false and object.foo()', ['object' => $object], \false], ['false && object.foo()', ['object' => $object], \false], ['true || object.foo()', ['object' => $object], \true], ['true or object.foo()', ['object' => $object], \true]]; + } + public function shortCircuitProviderCompile() + { + return [['false and foo', ['foo' => 'foo'], \false], ['false && foo', ['foo' => 'foo'], \false], ['true || foo', ['foo' => 'foo'], \true], ['true or foo', ['foo' => 'foo'], \true]]; + } + public function testCachingForOverriddenVariableNames() + { + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $expression = 'a + b'; + $expressionLanguage->evaluate($expression, ['a' => 1, 'b' => 1]); + $result = $expressionLanguage->compile($expression, ['a', 'B' => 'b']); + $this->assertSame('($a + $B)', $result); + } + public function testStrictEquality() + { + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $expression = '123 === a'; + $result = $expressionLanguage->compile($expression, ['a']); + $this->assertSame('(123 === $a)', $result); + } + public function testCachingWithDifferentNamesOrder() + { + $cacheMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemPoolInterface')->getMock(); + $cacheItemMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface')->getMock(); + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage($cacheMock); + $savedParsedExpression = null; + $cacheMock->expects($this->exactly(2))->method('getItem')->with('a%20%2B%20b%2F%2Fa%7CB%3Ab')->willReturn($cacheItemMock); + $cacheItemMock->expects($this->exactly(2))->method('get')->willReturnCallback(function () use(&$savedParsedExpression) { + return $savedParsedExpression; + }); + $cacheItemMock->expects($this->exactly(1))->method('set')->with($this->isInstanceOf(\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression::class))->willReturnCallback(function ($parsedExpression) use(&$savedParsedExpression) { + $savedParsedExpression = $parsedExpression; + }); + $cacheMock->expects($this->exactly(1))->method('save')->with($cacheItemMock); + $expression = 'a + b'; + $expressionLanguage->compile($expression, ['a', 'B' => 'b']); + $expressionLanguage->compile($expression, ['B' => 'b', 'a']); + } + public function testOperatorCollisions() + { + $expressionLanguage = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $expression = 'foo.not in [bar]'; + $compiled = $expressionLanguage->compile($expression, ['foo', 'bar']); + $this->assertSame('in_array($foo->not, [0 => $bar])', $compiled); + $result = $expressionLanguage->evaluate($expression, ['foo' => (object) ['not' => 'test'], 'bar' => 'test']); + $this->assertTrue($result); + } + /** + * @dataProvider getRegisterCallbacks + */ + public function testRegisterAfterParse($registerCallback) + { + $this->expectException('LogicException'); + $el = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $el->parse('1 + 1', []); + $registerCallback($el); + } + /** + * @dataProvider getRegisterCallbacks + */ + public function testRegisterAfterEval($registerCallback) + { + $this->expectException('LogicException'); + $el = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $el->evaluate('1 + 1'); + $registerCallback($el); + } + public function testCallBadCallable() + { + $this->expectException('RuntimeException'); + $this->expectExceptionMessageRegExp('/Unable to call method "\\w+" of object "\\w+"./'); + $el = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $el->evaluate('foo.myfunction()', ['foo' => new \stdClass()]); + } + /** + * @dataProvider getRegisterCallbacks + */ + public function testRegisterAfterCompile($registerCallback) + { + $this->expectException('LogicException'); + $el = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage(); + $el->compile('1 + 1'); + $registerCallback($el); + } + public function getRegisterCallbacks() + { + return [[function (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage $el) { + $el->register('fn', function () { + }, function () { + }); + }], [function (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage $el) { + $el->addFunction(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction('fn', function () { + }, function () { + })); + }], [function (\_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionLanguage $el) { + $el->registerProvider(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Fixtures\TestProvider()); + }]]; + } +} diff --git a/vendor/symfony/expression-language/Tests/ExpressionTest.php b/vendor/symfony/expression-language/Tests/ExpressionTest.php index 6a5642e9e..a2d7a9500 100644 --- a/vendor/symfony/expression-language/Tests/ExpressionTest.php +++ b/vendor/symfony/expression-language/Tests/ExpressionTest.php @@ -1,24 +1,24 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; -class ExpressionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testSerialization() - { - $expression = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('kernel.boot()'); - $serializedExpression = \serialize($expression); - $unserializedExpression = \unserialize($serializedExpression); - $this->assertEquals($expression, $unserializedExpression); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression; +class ExpressionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testSerialization() + { + $expression = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Expression('kernel.boot()'); + $serializedExpression = \serialize($expression); + $unserializedExpression = \unserialize($serializedExpression); + $this->assertEquals($expression, $unserializedExpression); + } +} diff --git a/vendor/symfony/expression-language/Tests/Fixtures/TestProvider.php b/vendor/symfony/expression-language/Tests/Fixtures/TestProvider.php index dccc86a51..3e6dcd72b 100644 --- a/vendor/symfony/expression-language/Tests/Fixtures/TestProvider.php +++ b/vendor/symfony/expression-language/Tests/Fixtures/TestProvider.php @@ -1,30 +1,30 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Fixtures; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionPhpFunction; -class TestProvider implements \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface -{ - public function getFunctions() - { - return [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction('identity', function ($input) { - return $input; - }, function (array $values, $input) { - return $input; - }), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('strtoupper'), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('\\strtolower'), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Tests\\Fixtures\\fn_namespaced', 'fn_namespaced')]; - } -} -function fn_namespaced() -{ - return \true; -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Fixtures; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionPhpFunction; +class TestProvider implements \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunctionProviderInterface +{ + public function getFunctions() + { + return [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction('identity', function ($input) { + return $input; + }, function (array $values, $input) { + return $input; + }), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('strtoupper'), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('\\strtolower'), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ExpressionFunction::fromPhp('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\Tests\\Fixtures\\fn_namespaced', 'fn_namespaced')]; + } +} +function fn_namespaced() +{ + return \true; +} diff --git a/vendor/symfony/expression-language/Tests/Fixtures/index.php b/vendor/symfony/expression-language/Tests/Fixtures/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/expression-language/Tests/Fixtures/index.php +++ b/vendor/symfony/expression-language/Tests/Fixtures/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Tests/LexerTest.php b/vendor/symfony/expression-language/Tests/LexerTest.php index 7e0092910..2cff2c992 100644 --- a/vendor/symfony/expression-language/Tests/LexerTest.php +++ b/vendor/symfony/expression-language/Tests/LexerTest.php @@ -1,53 +1,53 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\TokenStream; -class LexerTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @var Lexer - */ - private $lexer; - protected function setUp() - { - $this->lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); - } - /** - * @dataProvider getTokenizeData - */ - public function testTokenize($tokens, $expression) - { - $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('end of expression', null, \strlen($expression) + 1); - $this->assertEquals(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\TokenStream($tokens, $expression), $this->lexer->tokenize($expression)); - } - public function testTokenizeThrowsErrorWithMessage() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); - $this->expectExceptionMessage('Unexpected character "\'" around position 33 for expression `service(faulty.expression.example\').dummyMethod()`.'); - $expression = "service(faulty.expression.example').dummyMethod()"; - $this->lexer->tokenize($expression); - } - public function testTokenizeThrowsErrorOnUnclosedBrace() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); - $this->expectExceptionMessage('Unclosed "(" around position 7 for expression `service(unclosed.expression.dummyMethod()`.'); - $expression = 'service(unclosed.expression.dummyMethod()'; - $this->lexer->tokenize($expression); - } - public function getTokenizeData() - { - return [[[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'a', 3)], ' a '], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'a', 1)], 'a'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('string', 'foo', 1)], '"foo"'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('number', '3', 1)], '3'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('operator', '+', 1)], '+'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '.', 1)], '.'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '(', 1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('number', '3', 2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('operator', '+', 4), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('number', '5', 6), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', ')', 7), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('operator', '~', 9), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'foo', 11), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '(', 14), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('string', 'bar', 15), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', ')', 20), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '.', 21), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'baz', 22), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '[', 25), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('number', '4', 26), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', ']', 27)], '(3 + 5) ~ foo("bar").baz[4]'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('operator', '..', 1)], '..'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('string', '#foo', 1)], "'#foo'"], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('string', '#foo', 1)], '"#foo"'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'foo', 1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '.', 4), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'not', 5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('operator', 'in', 9), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '[', 12), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'bar', 13), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', ']', 16)], 'foo.not in [bar]']]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\TokenStream; +class LexerTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @var Lexer + */ + private $lexer; + protected function setUp() + { + $this->lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); + } + /** + * @dataProvider getTokenizeData + */ + public function testTokenize($tokens, $expression) + { + $tokens[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('end of expression', null, \strlen($expression) + 1); + $this->assertEquals(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\TokenStream($tokens, $expression), $this->lexer->tokenize($expression)); + } + public function testTokenizeThrowsErrorWithMessage() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); + $this->expectExceptionMessage('Unexpected character "\'" around position 33 for expression `service(faulty.expression.example\').dummyMethod()`.'); + $expression = "service(faulty.expression.example').dummyMethod()"; + $this->lexer->tokenize($expression); + } + public function testTokenizeThrowsErrorOnUnclosedBrace() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); + $this->expectExceptionMessage('Unclosed "(" around position 7 for expression `service(unclosed.expression.dummyMethod()`.'); + $expression = 'service(unclosed.expression.dummyMethod()'; + $this->lexer->tokenize($expression); + } + public function getTokenizeData() + { + return [[[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'a', 3)], ' a '], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'a', 1)], 'a'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('string', 'foo', 1)], '"foo"'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('number', '3', 1)], '3'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('operator', '+', 1)], '+'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '.', 1)], '.'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '(', 1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('number', '3', 2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('operator', '+', 4), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('number', '5', 6), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', ')', 7), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('operator', '~', 9), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'foo', 11), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '(', 14), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('string', 'bar', 15), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', ')', 20), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '.', 21), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'baz', 22), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '[', 25), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('number', '4', 26), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', ']', 27)], '(3 + 5) ~ foo("bar").baz[4]'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('operator', '..', 1)], '..'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('string', '#foo', 1)], "'#foo'"], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('string', '#foo', 1)], '"#foo"'], [[new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'foo', 1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '.', 4), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'not', 5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('operator', 'in', 9), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', '[', 12), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('name', 'bar', 13), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token('punctuation', ']', 16)], 'foo.not in [bar]']]; + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/AbstractNodeTest.php b/vendor/symfony/expression-language/Tests/Node/AbstractNodeTest.php index a27a191ea..a9baa1bf2 100644 --- a/vendor/symfony/expression-language/Tests/Node/AbstractNodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/AbstractNodeTest.php @@ -1,43 +1,43 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; -abstract class AbstractNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** - * @dataProvider getEvaluateData - */ - public function testEvaluate($expected, $node, $variables = [], $functions = []) - { - $this->assertSame($expected, $node->evaluate($functions, $variables)); - } - public abstract function getEvaluateData(); - /** - * @dataProvider getCompileData - */ - public function testCompile($expected, $node, $functions = []) - { - $compiler = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler($functions); - $node->compile($compiler); - $this->assertSame($expected, $compiler->getSource()); - } - public abstract function getCompileData(); - /** - * @dataProvider getDumpData - */ - public function testDump($expected, $node) - { - $this->assertSame($expected, $node->dump()); - } - public abstract function getDumpData(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler; +abstract class AbstractNodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** + * @dataProvider getEvaluateData + */ + public function testEvaluate($expected, $node, $variables = [], $functions = []) + { + $this->assertSame($expected, $node->evaluate($functions, $variables)); + } + public abstract function getEvaluateData(); + /** + * @dataProvider getCompileData + */ + public function testCompile($expected, $node, $functions = []) + { + $compiler = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Compiler($functions); + $node->compile($compiler); + $this->assertSame($expected, $compiler->getSource()); + } + public abstract function getCompileData(); + /** + * @dataProvider getDumpData + */ + public function testDump($expected, $node) + { + $this->assertSame($expected, $node->dump()); + } + public abstract function getDumpData(); +} diff --git a/vendor/symfony/expression-language/Tests/Node/ArgumentsNodeTest.php b/vendor/symfony/expression-language/Tests/Node/ArgumentsNodeTest.php index f320bcfa1..f5a5d555d 100644 --- a/vendor/symfony/expression-language/Tests/Node/ArgumentsNodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/ArgumentsNodeTest.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode; -class ArgumentsNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\ArrayNodeTest -{ - public function getCompileData() - { - return [['"a", "b"', $this->getArrayNode()]]; - } - public function getDumpData() - { - return [['"a", "b"', $this->getArrayNode()]]; - } - protected function createArrayNode() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode; +class ArgumentsNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\ArrayNodeTest +{ + public function getCompileData() + { + return [['"a", "b"', $this->getArrayNode()]]; + } + public function getDumpData() + { + return [['"a", "b"', $this->getArrayNode()]]; + } + protected function createArrayNode() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(); + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/ArrayNodeTest.php b/vendor/symfony/expression-language/Tests/Node/ArrayNodeTest.php index 859d5ba0b..0db233ff0 100644 --- a/vendor/symfony/expression-language/Tests/Node/ArrayNodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/ArrayNodeTest.php @@ -1,57 +1,57 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; -class ArrayNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest -{ - public function testSerialization() - { - $node = $this->createArrayNode(); - $node->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo')); - $serializedNode = \serialize($node); - $unserializedNode = \unserialize($serializedNode); - $this->assertEquals($node, $unserializedNode); - $this->assertNotEquals($this->createArrayNode(), $unserializedNode); - } - public function getEvaluateData() - { - return [[['b' => 'a', 'b'], $this->getArrayNode()]]; - } - public function getCompileData() - { - return [['["b" => "a", 0 => "b"]', $this->getArrayNode()]]; - } - public function getDumpData() - { - (yield ['{"b": "a", 0: "b"}', $this->getArrayNode()]); - $array = $this->createArrayNode(); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a"b')); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('d'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('_PhpScoper5ea00cc67502b\\a\\b')); - (yield ['{"a\\"b": "c", "a\\\\b": "d"}', $array]); - $array = $this->createArrayNode(); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c')); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('d')); - (yield ['["c", "d"]', $array]); - } - protected function getArrayNode() - { - $array = $this->createArrayNode(); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); - return $array; - } - protected function createArrayNode() - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; +class ArrayNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest +{ + public function testSerialization() + { + $node = $this->createArrayNode(); + $node->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo')); + $serializedNode = \serialize($node); + $unserializedNode = \unserialize($serializedNode); + $this->assertEquals($node, $unserializedNode); + $this->assertNotEquals($this->createArrayNode(), $unserializedNode); + } + public function getEvaluateData() + { + return [[['b' => 'a', 'b'], $this->getArrayNode()]]; + } + public function getCompileData() + { + return [['["b" => "a", 0 => "b"]', $this->getArrayNode()]]; + } + public function getDumpData() + { + (yield ['{"b": "a", 0: "b"}', $this->getArrayNode()]); + $array = $this->createArrayNode(); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a"b')); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('d'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('_PhpScoper5ea00cc67502b\\a\\b')); + (yield ['{"a\\"b": "c", "a\\\\b": "d"}', $array]); + $array = $this->createArrayNode(); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c')); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('d')); + (yield ['["c", "d"]', $array]); + } + protected function getArrayNode() + { + $array = $this->createArrayNode(); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); + return $array; + } + protected function createArrayNode() + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/BinaryNodeTest.php b/vendor/symfony/expression-language/Tests/Node/BinaryNodeTest.php index c69d7e986..aa960b0be 100644 --- a/vendor/symfony/expression-language/Tests/Node/BinaryNodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/BinaryNodeTest.php @@ -1,39 +1,39 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; -class BinaryNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest -{ - public function getEvaluateData() - { - $array = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a')); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); - return [[\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('or', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('||', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('and', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], [0, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], [6, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('|', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], [6, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('^', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('===', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], [-1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [3, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [4, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('*', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('/', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('%', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [25, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('**', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['ab', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('~', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], [[1, 2, 3], new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('..', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], [1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('matches', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('abc'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('/^[a-z]+$/'))]]; - } - public function getCompileData() - { - $array = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a')); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); - return [['(true || false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('or', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true || false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('||', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true && false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('and', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true && false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(2 & 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(2 | 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('|', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(2 ^ 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('^', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(1 < 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 <= 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 <= 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(1 > 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 >= 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 >= 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(true === true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('===', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(true !== true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(2 == 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(2 != 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(1 - 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 + 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(2 * 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('*', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(2 / 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('/', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(5 % 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('%', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['pow(5, 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('**', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['("a" . "b")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('~', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'))], ['in_array("a", [0 => "a", 1 => "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], ['in_array("c", [0 => "a", 1 => "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], ['!in_array("c", [0 => "a", 1 => "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], ['!in_array("a", [0 => "a", 1 => "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], ['range(1, 3)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('..', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], ['preg_match("/^[a-z]+/i\\$/", "abc")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('matches', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('abc'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('/^[a-z]+/i$/'))]]; - } - public function getDumpData() - { - $array = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a')); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); - return [['(true or false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('or', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true || false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('||', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true and false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('and', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true && false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(2 & 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(2 | 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('|', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(2 ^ 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('^', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(1 < 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 <= 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 <= 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(1 > 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 >= 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 >= 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(true === true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('===', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(true !== true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(2 == 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(2 != 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(1 - 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 + 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(2 * 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('*', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(2 / 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('/', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(5 % 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('%', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(5 ** 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('**', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['("a" ~ "b")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('~', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'))], ['("a" in ["a", "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], ['("c" in ["a", "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], ['("c" not in ["a", "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], ['("a" not in ["a", "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], ['(1 .. 3)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('..', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], ['("abc" matches "/^[a-z]+/i$/")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('matches', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('abc'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('/^[a-z]+/i$/'))]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; +class BinaryNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest +{ + public function getEvaluateData() + { + $array = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a')); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); + return [[\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('or', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('||', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('and', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], [0, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], [6, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('|', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], [6, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('^', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('===', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], [-1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [3, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [4, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('*', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('/', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('%', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [25, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('**', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['ab', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('~', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'))], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], [[1, 2, 3], new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('..', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], [1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('matches', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('abc'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('/^[a-z]+$/'))]]; + } + public function getCompileData() + { + $array = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a')); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); + return [['(true || false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('or', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true || false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('||', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true && false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('and', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true && false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(2 & 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(2 | 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('|', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(2 ^ 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('^', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(1 < 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 <= 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 <= 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(1 > 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 >= 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 >= 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(true === true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('===', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(true !== true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(2 == 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(2 != 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(1 - 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 + 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(2 * 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('*', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(2 / 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('/', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(5 % 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('%', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['pow(5, 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('**', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['("a" . "b")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('~', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'))], ['in_array("a", [0 => "a", 1 => "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], ['in_array("c", [0 => "a", 1 => "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], ['!in_array("c", [0 => "a", 1 => "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], ['!in_array("a", [0 => "a", 1 => "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], ['range(1, 3)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('..', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], ['preg_match("/^[a-z]+/i\\$/", "abc")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('matches', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('abc'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('/^[a-z]+/i$/'))]]; + } + public function getDumpData() + { + $array = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a')); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); + return [['(true or false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('or', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true || false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('||', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true and false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('and', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(true && false)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false))], ['(2 & 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('&', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(2 | 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('|', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(2 ^ 4)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('^', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(4))], ['(1 < 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 <= 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 <= 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('<=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(1 > 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 >= 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 >= 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('>=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(true === true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('===', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(true !== true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(2 == 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('==', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(2 != 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('!=', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(1 - 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(1 + 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(2 * 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('*', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(2 / 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('/', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(5 % 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('%', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(5 ** 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('**', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(5), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['("a" ~ "b")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('~', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'))], ['("a" in ["a", "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], ['("c" in ["a", "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], ['("c" not in ["a", "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('c'), $array)], ['("a" not in ["a", "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('not in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), $array)], ['(1 .. 3)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('..', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], ['("abc" matches "/^[a-z]+/i$/")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('matches', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('abc'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('/^[a-z]+/i$/'))]]; + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/ConditionalNodeTest.php b/vendor/symfony/expression-language/Tests/Node/ConditionalNodeTest.php index bbbbcc1f1..3f79e4dc1 100644 --- a/vendor/symfony/expression-language/Tests/Node/ConditionalNodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/ConditionalNodeTest.php @@ -1,29 +1,29 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; -class ConditionalNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest -{ - public function getEvaluateData() - { - return [[1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [2, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))]]; - } - public function getCompileData() - { - return [['((true) ? (1) : (2))', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['((false) ? (1) : (2))', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))]]; - } - public function getDumpData() - { - return [['(true ? 1 : 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(false ? 1 : 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; +class ConditionalNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest +{ + public function getEvaluateData() + { + return [[1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], [2, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))]]; + } + public function getCompileData() + { + return [['((true) ? (1) : (2))', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['((false) ? (1) : (2))', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))]]; + } + public function getDumpData() + { + return [['(true ? 1 : 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))], ['(false ? 1 : 2)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2))]]; + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/ConstantNodeTest.php b/vendor/symfony/expression-language/Tests/Node/ConstantNodeTest.php index 1ed279aa1..ba32165cd 100644 --- a/vendor/symfony/expression-language/Tests/Node/ConstantNodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/ConstantNodeTest.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; -class ConstantNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest -{ - public function getEvaluateData() - { - return [[\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false)], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true)], [null, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null)], [3, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)], [3.3, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3.3)], ['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo')], [[1, 'b' => 'a'], new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode([1, 'b' => 'a'])]]; - } - public function getCompileData() - { - return [['false', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false)], ['true', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true)], ['null', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null)], ['3', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)], ['3.3', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3.3)], ['"foo"', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo')], ['[0 => 1, "b" => "a"]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode([1, 'b' => 'a'])]]; - } - public function getDumpData() - { - return [['false', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false)], ['true', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true)], ['null', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null)], ['3', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)], ['3.3', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3.3)], ['"foo"', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo')], ['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo', \true)], ['{0: 1, "b": "a", 1: true}', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode([1, 'b' => 'a', \true])], ['{"a\\"b": "c", "a\\\\b": "d"}', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(['a"b' => 'c', '_PhpScoper5ea00cc67502b\\a\\b' => 'd'])], ['["c", "d"]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(['c', 'd'])], ['{"a": ["b"]}', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(['a' => ['b']])]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; +class ConstantNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest +{ + public function getEvaluateData() + { + return [[\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false)], [\true, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true)], [null, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null)], [3, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)], [3.3, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3.3)], ['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo')], [[1, 'b' => 'a'], new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode([1, 'b' => 'a'])]]; + } + public function getCompileData() + { + return [['false', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false)], ['true', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true)], ['null', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null)], ['3', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)], ['3.3', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3.3)], ['"foo"', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo')], ['[0 => 1, "b" => "a"]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode([1, 'b' => 'a'])]]; + } + public function getDumpData() + { + return [['false', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false)], ['true', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true)], ['null', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null)], ['3', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)], ['3.3', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3.3)], ['"foo"', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo')], ['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo', \true)], ['{0: 1, "b": "a", 1: true}', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode([1, 'b' => 'a', \true])], ['{"a\\"b": "c", "a\\\\b": "d"}', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(['a"b' => 'c', '_PhpScoper5ea00cc67502b\\a\\b' => 'd'])], ['["c", "d"]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(['c', 'd'])], ['{"a": ["b"]}', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(['a' => ['b']])]]; + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/FunctionNodeTest.php b/vendor/symfony/expression-language/Tests/Node/FunctionNodeTest.php index f88fad8bf..93111ccda 100644 --- a/vendor/symfony/expression-language/Tests/Node/FunctionNodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/FunctionNodeTest.php @@ -1,38 +1,38 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\FunctionNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node; -class FunctionNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest -{ - public function getEvaluateData() - { - return [['bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\FunctionNode('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node([new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar')])), [], ['foo' => $this->getCallables()]]]; - } - public function getCompileData() - { - return [['foo("bar")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\FunctionNode('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node([new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar')])), ['foo' => $this->getCallables()]]]; - } - public function getDumpData() - { - return [['foo("bar")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\FunctionNode('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node([new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar')])), ['foo' => $this->getCallables()]]]; - } - protected function getCallables() - { - return ['compiler' => function ($arg) { - return \sprintf('foo(%s)', $arg); - }, 'evaluator' => function ($variables, $arg) { - return $arg; - }]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\FunctionNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node; +class FunctionNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest +{ + public function getEvaluateData() + { + return [['bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\FunctionNode('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node([new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar')])), [], ['foo' => $this->getCallables()]]]; + } + public function getCompileData() + { + return [['foo("bar")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\FunctionNode('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node([new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar')])), ['foo' => $this->getCallables()]]]; + } + public function getDumpData() + { + return [['foo("bar")', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\FunctionNode('foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node([new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar')])), ['foo' => $this->getCallables()]]]; + } + protected function getCallables() + { + return ['compiler' => function ($arg) { + return \sprintf('foo(%s)', $arg); + }, 'evaluator' => function ($variables, $arg) { + return $arg; + }]; + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/GetAttrNodeTest.php b/vendor/symfony/expression-language/Tests/Node/GetAttrNodeTest.php index 5ea226864..00e3c22d7 100644 --- a/vendor/symfony/expression-language/Tests/Node/GetAttrNodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/GetAttrNodeTest.php @@ -1,46 +1,46 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode; -class GetAttrNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest -{ - public function getEvaluateData() - { - return [['b', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(0), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL), ['foo' => ['b' => 'a', 'b']]], ['a', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL), ['foo' => ['b' => 'a', 'b']]], ['bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['baz', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['a', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('index'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL), ['foo' => ['b' => 'a', 'b'], 'index' => 'b']]]; - } - public function getCompileData() - { - return [['$foo[0]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(0), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)], ['$foo["b"]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)], ['$foo->foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['$foo->foo(["b" => "a", 0 => "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['$foo[$index]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('index'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)]]; - } - public function getDumpData() - { - return [['foo[0]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(0), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)], ['foo["b"]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)], ['foo.foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['foo.foo({"b": "a", 0: "b"})', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['foo[index]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('index'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)]]; - } - protected function getArrayNode() - { - $array = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); - $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); - return $array; - } -} -class Obj -{ - public $foo = 'bar'; - public function foo() - { - return 'baz'; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode; +class GetAttrNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest +{ + public function getEvaluateData() + { + return [['b', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(0), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL), ['foo' => ['b' => 'a', 'b']]], ['a', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL), ['foo' => ['b' => 'a', 'b']]], ['bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['baz', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['a', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('index'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL), ['foo' => ['b' => 'a', 'b'], 'index' => 'b']]]; + } + public function getCompileData() + { + return [['$foo[0]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(0), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)], ['$foo["b"]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)], ['$foo->foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['$foo->foo(["b" => "a", 0 => "b"])', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['$foo[$index]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('index'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)]]; + } + public function getDumpData() + { + return [['foo[0]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(0), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)], ['foo["b"]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)], ['foo.foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['foo.foo({"b": "a", 0: "b"})', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\Obj()]], ['foo[index]', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('index'), $this->getArrayNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL)]]; + } + protected function getArrayNode() + { + $array = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); + $array->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('b')); + return $array; + } +} +class Obj +{ + public $foo = 'bar'; + public function foo() + { + return 'baz'; + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/NameNodeTest.php b/vendor/symfony/expression-language/Tests/Node/NameNodeTest.php index 9d58d3a22..c7d472153 100644 --- a/vendor/symfony/expression-language/Tests/Node/NameNodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/NameNodeTest.php @@ -1,28 +1,28 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode; -class NameNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest -{ - public function getEvaluateData() - { - return [['bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), ['foo' => 'bar']]]; - } - public function getCompileData() - { - return [['$foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo')]]; - } - public function getDumpData() - { - return [['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo')]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode; +class NameNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest +{ + public function getEvaluateData() + { + return [['bar', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), ['foo' => 'bar']]]; + } + public function getCompileData() + { + return [['$foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo')]]; + } + public function getDumpData() + { + return [['foo', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo')]]; + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/NodeTest.php b/vendor/symfony/expression-language/Tests/Node/NodeTest.php index e220d4008..ea1a4ef1e 100644 --- a/vendor/symfony/expression-language/Tests/Node/NodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/NodeTest.php @@ -1,35 +1,35 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node; -class NodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testToString() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node([new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo')]); - $this->assertEquals(<<<'EOF' -Node( - ConstantNode(value: 'foo') -) -EOF -, (string) $node); - } - public function testSerialization() - { - $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node(['foo' => 'bar'], ['bar' => 'foo']); - $serializedNode = \serialize($node); - $unserializedNode = \unserialize($serializedNode); - $this->assertEquals($node, $unserializedNode); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node; +class NodeTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testToString() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node([new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo')]); + $this->assertEquals(<<<'EOF' +Node( + ConstantNode(value: 'foo') +) +EOF +, (string) $node); + } + public function testSerialization() + { + $node = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node(['foo' => 'bar'], ['bar' => 'foo']); + $serializedNode = \serialize($node); + $unserializedNode = \unserialize($serializedNode); + $this->assertEquals($node, $unserializedNode); + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/UnaryNodeTest.php b/vendor/symfony/expression-language/Tests/Node/UnaryNodeTest.php index f10a76771..00f95097b 100644 --- a/vendor/symfony/expression-language/Tests/Node/UnaryNodeTest.php +++ b/vendor/symfony/expression-language/Tests/Node/UnaryNodeTest.php @@ -1,29 +1,29 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; - -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode; -class UnaryNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest -{ - public function getEvaluateData() - { - return [[-1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], [3, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('!', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('not', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))]]; - } - public function getCompileData() - { - return [['(-1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(+3)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], ['(!true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('!', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(!true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('not', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))]]; - } - public function getDumpData() - { - return [['(- 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(+ 3)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], ['(! true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('!', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(not true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('not', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))]]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node; + +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode; +class UnaryNodeTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests\Node\AbstractNodeTest +{ + public function getEvaluateData() + { + return [[-1, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], [3, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('!', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], [\false, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('not', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))]]; + } + public function getCompileData() + { + return [['(-1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(+3)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], ['(!true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('!', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(!true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('not', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))]]; + } + public function getDumpData() + { + return [['(- 1)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(1))], ['(+ 3)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('+', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3))], ['(! true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('!', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))], ['(not true)', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('not', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true))]]; + } +} diff --git a/vendor/symfony/expression-language/Tests/Node/index.php b/vendor/symfony/expression-language/Tests/Node/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/expression-language/Tests/Node/index.php +++ b/vendor/symfony/expression-language/Tests/Node/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Tests/ParsedExpressionTest.php b/vendor/symfony/expression-language/Tests/ParsedExpressionTest.php index 054ed46a1..061b297e9 100644 --- a/vendor/symfony/expression-language/Tests/ParsedExpressionTest.php +++ b/vendor/symfony/expression-language/Tests/ParsedExpressionTest.php @@ -1,25 +1,25 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression; -class ParsedExpressionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testSerialization() - { - $expression = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression('25', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('25')); - $serializedExpression = \serialize($expression); - $unserializedExpression = \unserialize($serializedExpression); - $this->assertEquals($expression, $unserializedExpression); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression; +class ParsedExpressionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testSerialization() + { + $expression = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression('25', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('25')); + $serializedExpression = \serialize($expression); + $unserializedExpression = \unserialize($serializedExpression); + $this->assertEquals($expression, $unserializedExpression); + } +} diff --git a/vendor/symfony/expression-language/Tests/ParserCache/ParserCacheAdapterTest.php b/vendor/symfony/expression-language/Tests/ParserCache/ParserCacheAdapterTest.php index e5bef075c..3a990beda 100644 --- a/vendor/symfony/expression-language/Tests/ParserCache/ParserCacheAdapterTest.php +++ b/vendor/symfony/expression-language/Tests/ParserCache/ParserCacheAdapterTest.php @@ -1,98 +1,98 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter; -/** - * @group legacy - */ -class ParserCacheAdapterTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testGetItem() - { - $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); - $key = 'key'; - $value = 'value'; - $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); - $poolMock->expects($this->once())->method('fetch')->with($key)->willReturn($value); - $cacheItem = $parserCacheAdapter->getItem($key); - $this->assertEquals($cacheItem->get(), $value); - $this->assertEquals($cacheItem->isHit(), \true); - } - public function testSave() - { - $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); - $cacheItemMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface')->getMock(); - $key = 'key'; - $value = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression('1 + 1', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node([], [])); - $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); - $poolMock->expects($this->once())->method('save')->with($key, $value); - $cacheItemMock->expects($this->once())->method('getKey')->willReturn($key); - $cacheItemMock->expects($this->once())->method('get')->willReturn($value); - $parserCacheAdapter->save($cacheItemMock); - } - public function testGetItems() - { - $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); - $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); - $this->expectException(\BadMethodCallException::class); - $parserCacheAdapter->getItems(); - } - public function testHasItem() - { - $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); - $key = 'key'; - $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); - $this->expectException(\BadMethodCallException::class); - $parserCacheAdapter->hasItem($key); - } - public function testClear() - { - $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); - $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); - $this->expectException(\BadMethodCallException::class); - $parserCacheAdapter->clear(); - } - public function testDeleteItem() - { - $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); - $key = 'key'; - $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); - $this->expectException(\BadMethodCallException::class); - $parserCacheAdapter->deleteItem($key); - } - public function testDeleteItems() - { - $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); - $keys = ['key']; - $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); - $this->expectException(\BadMethodCallException::class); - $parserCacheAdapter->deleteItems($keys); - } - public function testSaveDeferred() - { - $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); - $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); - $cacheItemMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface')->getMock(); - $this->expectException(\BadMethodCallException::class); - $parserCacheAdapter->saveDeferred($cacheItemMock); - } - public function testCommit() - { - $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); - $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); - $this->expectException(\BadMethodCallException::class); - $parserCacheAdapter->commit(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter; +/** + * @group legacy + */ +class ParserCacheAdapterTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testGetItem() + { + $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); + $key = 'key'; + $value = 'value'; + $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); + $poolMock->expects($this->once())->method('fetch')->with($key)->willReturn($value); + $cacheItem = $parserCacheAdapter->getItem($key); + $this->assertEquals($cacheItem->get(), $value); + $this->assertEquals($cacheItem->isHit(), \true); + } + public function testSave() + { + $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); + $cacheItemMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface')->getMock(); + $key = 'key'; + $value = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParsedExpression('1 + 1', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\Node([], [])); + $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); + $poolMock->expects($this->once())->method('save')->with($key, $value); + $cacheItemMock->expects($this->once())->method('getKey')->willReturn($key); + $cacheItemMock->expects($this->once())->method('get')->willReturn($value); + $parserCacheAdapter->save($cacheItemMock); + } + public function testGetItems() + { + $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); + $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); + $this->expectException(\BadMethodCallException::class); + $parserCacheAdapter->getItems(); + } + public function testHasItem() + { + $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); + $key = 'key'; + $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); + $this->expectException(\BadMethodCallException::class); + $parserCacheAdapter->hasItem($key); + } + public function testClear() + { + $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); + $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); + $this->expectException(\BadMethodCallException::class); + $parserCacheAdapter->clear(); + } + public function testDeleteItem() + { + $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); + $key = 'key'; + $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); + $this->expectException(\BadMethodCallException::class); + $parserCacheAdapter->deleteItem($key); + } + public function testDeleteItems() + { + $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); + $keys = ['key']; + $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); + $this->expectException(\BadMethodCallException::class); + $parserCacheAdapter->deleteItems($keys); + } + public function testSaveDeferred() + { + $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); + $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); + $cacheItemMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Psr\\Cache\\CacheItemInterface')->getMock(); + $this->expectException(\BadMethodCallException::class); + $parserCacheAdapter->saveDeferred($cacheItemMock); + } + public function testCommit() + { + $poolMock = $this->getMockBuilder('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\ParserCache\\ParserCacheInterface')->getMock(); + $parserCacheAdapter = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\ParserCache\ParserCacheAdapter($poolMock); + $this->expectException(\BadMethodCallException::class); + $parserCacheAdapter->commit(); + } +} diff --git a/vendor/symfony/expression-language/Tests/ParserCache/index.php b/vendor/symfony/expression-language/Tests/ParserCache/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/expression-language/Tests/ParserCache/index.php +++ b/vendor/symfony/expression-language/Tests/ParserCache/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Tests/ParserTest.php b/vendor/symfony/expression-language/Tests/ParserTest.php index 14b20a3fc..7980477d5 100644 --- a/vendor/symfony/expression-language/Tests/ParserTest.php +++ b/vendor/symfony/expression-language/Tests/ParserTest.php @@ -1,103 +1,103 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; -use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser; -class ParserTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testParseWithInvalidName() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); - $this->expectExceptionMessage('Variable "foo" is not valid around position 1 for expression `foo`.'); - $lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); - $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser([]); - $parser->parse($lexer->tokenize('foo')); - } - public function testParseWithZeroInNames() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); - $this->expectExceptionMessage('Variable "foo" is not valid around position 1 for expression `foo`.'); - $lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); - $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser([]); - $parser->parse($lexer->tokenize('foo'), [0]); - } - /** - * @dataProvider getParseData - */ - public function testParse($node, $expression, $names = []) - { - $lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); - $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser([]); - $this->assertEquals($node, $parser->parse($lexer->tokenize($expression), $names)); - } - public function getParseData() - { - $arguments = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(); - $arguments->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('arg1')); - $arguments->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2)); - $arguments->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true)); - $arrayNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); - $arrayNode->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('bar')); - return [ - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('a'), 'a', ['a']], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), '"a"'], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3), '3'], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false), 'false'], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), 'true'], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null), 'null'], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)), '-3'], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)), '3 - 3'], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('*', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2)), '(3 - 3) * 2'], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar', \true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), 'foo.bar', ['foo']], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar', \true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), 'foo.bar()', ['foo']], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('not', \true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), 'foo.not()', ['foo']], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar', \true), $arguments, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), 'foo.bar("arg1", 2, true)', ['foo']], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL), 'foo[3]', ['foo']], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false)), 'true ? true : false'], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('matches', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('/foo/')), '"foo" matches "/foo/"'], - // chained calls - [$this->createGetAttrNode($this->createGetAttrNode($this->createGetAttrNode($this->createGetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), 'bar', \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), 'foo', \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), 'baz', \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), '3', \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL), 'foo.bar().foo().baz[3]', ['foo']], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), 'bar', ['foo' => 'bar']], - // Operators collisions - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('not', \true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), $arrayNode), 'foo.not in [bar]', ['foo', 'bar']], - [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('or', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('not', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo')), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('not', \true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL)), 'not foo or foo.not', ['foo']], - ]; - } - private function createGetAttrNode($node, $item, $type) - { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode($node, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode($item, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL !== $type), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), $type); - } - /** - * @dataProvider getInvalidPostfixData - */ - public function testParseWithInvalidPostfixData($expr, $names = []) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); - $lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); - $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser([]); - $parser->parse($lexer->tokenize($expr), $names); - } - public function getInvalidPostfixData() - { - return [['foo."#"', ['foo']], ['foo."bar"', ['foo']], ['foo.**', ['foo']], ['foo.123', ['foo']]]; - } - public function testNameProposal() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); - $this->expectExceptionMessage('Did you mean "baz"?'); - $lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); - $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser([]); - $parser->parse($lexer->tokenize('foo > bar'), ['foo', 'baz']); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node; +use _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser; +class ParserTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testParseWithInvalidName() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); + $this->expectExceptionMessage('Variable "foo" is not valid around position 1 for expression `foo`.'); + $lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); + $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser([]); + $parser->parse($lexer->tokenize('foo')); + } + public function testParseWithZeroInNames() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); + $this->expectExceptionMessage('Variable "foo" is not valid around position 1 for expression `foo`.'); + $lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); + $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser([]); + $parser->parse($lexer->tokenize('foo'), [0]); + } + /** + * @dataProvider getParseData + */ + public function testParse($node, $expression, $names = []) + { + $lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); + $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser([]); + $this->assertEquals($node, $parser->parse($lexer->tokenize($expression), $names)); + } + public function getParseData() + { + $arguments = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(); + $arguments->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('arg1')); + $arguments->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2)); + $arguments->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true)); + $arrayNode = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArrayNode(); + $arrayNode->addElement(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('bar')); + return [ + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('a'), 'a', ['a']], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('a'), '"a"'], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3), '3'], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false), 'false'], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), 'true'], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(null), 'null'], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)), '-3'], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)), '3 - 3'], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('*', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('-', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3)), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(2)), '(3 - 3) * 2'], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar', \true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), 'foo.bar', ['foo']], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar', \true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), 'foo.bar()', ['foo']], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('not', \true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), 'foo.not()', ['foo']], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('bar', \true), $arguments, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), 'foo.bar("arg1", 2, true)', ['foo']], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(3), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL), 'foo[3]', ['foo']], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConditionalNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode(\false)), 'true ? true : false'], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('matches', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('/foo/')), '"foo" matches "/foo/"'], + // chained calls + [$this->createGetAttrNode($this->createGetAttrNode($this->createGetAttrNode($this->createGetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), 'bar', \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), 'foo', \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::METHOD_CALL), 'baz', \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), '3', \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL), 'foo.bar().foo().baz[3]', ['foo']], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), 'bar', ['foo' => 'bar']], + // Operators collisions + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('in', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('not', \true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL), $arrayNode), 'foo.not in [bar]', ['foo', 'bar']], + [new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\BinaryNode('or', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\UnaryNode('not', new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo')), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode(new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\NameNode('foo'), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode('not', \true), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::PROPERTY_CALL)), 'not foo or foo.not', ['foo']], + ]; + } + private function createGetAttrNode($node, $item, $type) + { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode($node, new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ConstantNode($item, \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\GetAttrNode::ARRAY_CALL !== $type), new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Node\ArgumentsNode(), $type); + } + /** + * @dataProvider getInvalidPostfixData + */ + public function testParseWithInvalidPostfixData($expr, $names = []) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); + $lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); + $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser([]); + $parser->parse($lexer->tokenize($expr), $names); + } + public function getInvalidPostfixData() + { + return [['foo."#"', ['foo']], ['foo."bar"', ['foo']], ['foo.**', ['foo']], ['foo.123', ['foo']]]; + } + public function testNameProposal() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\SyntaxError'); + $this->expectExceptionMessage('Did you mean "baz"?'); + $lexer = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Lexer(); + $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Parser([]); + $parser->parse($lexer->tokenize('foo > bar'), ['foo', 'baz']); + } +} diff --git a/vendor/symfony/expression-language/Tests/index.php b/vendor/symfony/expression-language/Tests/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/expression-language/Tests/index.php +++ b/vendor/symfony/expression-language/Tests/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/Token.php b/vendor/symfony/expression-language/Token.php index cac2cbea2..ed855054b 100644 --- a/vendor/symfony/expression-language/Token.php +++ b/vendor/symfony/expression-language/Token.php @@ -1,61 +1,61 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -/** - * Represents a Token. - * - * @author Fabien Potencier - */ -class Token -{ - public $value; - public $type; - public $cursor; - const EOF_TYPE = 'end of expression'; - const NAME_TYPE = 'name'; - const NUMBER_TYPE = 'number'; - const STRING_TYPE = 'string'; - const OPERATOR_TYPE = 'operator'; - const PUNCTUATION_TYPE = 'punctuation'; - /** - * @param string $type The type of the token (self::*_TYPE) - * @param string|int|float|null $value The token value - * @param int $cursor The cursor position in the source - */ - public function __construct($type, $value, $cursor) - { - $this->type = $type; - $this->value = $value; - $this->cursor = $cursor; - } - /** - * Returns a string representation of the token. - * - * @return string A string representation of the token - */ - public function __toString() - { - return \sprintf('%3d %-11s %s', $this->cursor, \strtoupper($this->type), $this->value); - } - /** - * Tests the current token for a type and/or a value. - * - * @param array|int $type The type to test - * @param string|null $value The token value - * - * @return bool - */ - public function test($type, $value = null) - { - return $this->type === $type && (null === $value || $this->value == $value); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +/** + * Represents a Token. + * + * @author Fabien Potencier + */ +class Token +{ + public $value; + public $type; + public $cursor; + const EOF_TYPE = 'end of expression'; + const NAME_TYPE = 'name'; + const NUMBER_TYPE = 'number'; + const STRING_TYPE = 'string'; + const OPERATOR_TYPE = 'operator'; + const PUNCTUATION_TYPE = 'punctuation'; + /** + * @param string $type The type of the token (self::*_TYPE) + * @param string|int|float|null $value The token value + * @param int $cursor The cursor position in the source + */ + public function __construct($type, $value, $cursor) + { + $this->type = $type; + $this->value = $value; + $this->cursor = $cursor; + } + /** + * Returns a string representation of the token. + * + * @return string A string representation of the token + */ + public function __toString() + { + return \sprintf('%3d %-11s %s', $this->cursor, \strtoupper($this->type), $this->value); + } + /** + * Tests the current token for a type and/or a value. + * + * @param array|int $type The type to test + * @param string|null $value The token value + * + * @return bool + */ + public function test($type, $value = null) + { + return $this->type === $type && (null === $value || $this->value == $value); + } +} diff --git a/vendor/symfony/expression-language/TokenStream.php b/vendor/symfony/expression-language/TokenStream.php index f45121b7d..ac781614e 100644 --- a/vendor/symfony/expression-language/TokenStream.php +++ b/vendor/symfony/expression-language/TokenStream.php @@ -1,87 +1,87 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; - -/** - * Represents a token stream. - * - * @author Fabien Potencier - */ -class TokenStream -{ - public $current; - private $tokens; - private $position = 0; - private $expression; - /** - * @param array $tokens An array of tokens - * @param string $expression - */ - public function __construct(array $tokens, $expression = '') - { - $this->tokens = $tokens; - $this->current = $tokens[0]; - $this->expression = $expression; - } - /** - * Returns a string representation of the token stream. - * - * @return string - */ - public function __toString() - { - return \implode("\n", $this->tokens); - } - /** - * Sets the pointer to the next token and returns the old one. - */ - public function next() - { - ++$this->position; - if (!isset($this->tokens[$this->position])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError('Unexpected end of expression.', $this->current->cursor, $this->expression); - } - $this->current = $this->tokens[$this->position]; - } - /** - * Tests a token. - * - * @param array|int $type The type to test - * @param string|null $value The token value - * @param string|null $message The syntax error message - */ - public function expect($type, $value = null, $message = null) - { - $token = $this->current; - if (!$token->test($type, $value)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('%sUnexpected token "%s" of value "%s" ("%s" expected%s).', $message ? $message . '. ' : '', $token->type, $token->value, $type, $value ? \sprintf(' with value "%s"', $value) : ''), $token->cursor, $this->expression); - } - $this->next(); - } - /** - * Checks if end of stream was reached. - * - * @return bool - */ - public function isEOF() - { - return \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::EOF_TYPE === $this->current->type; - } - /** - * @internal - * - * @return string - */ - public function getExpression() - { - return $this->expression; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage; + +/** + * Represents a token stream. + * + * @author Fabien Potencier + */ +class TokenStream +{ + public $current; + private $tokens; + private $position = 0; + private $expression; + /** + * @param array $tokens An array of tokens + * @param string $expression + */ + public function __construct(array $tokens, $expression = '') + { + $this->tokens = $tokens; + $this->current = $tokens[0]; + $this->expression = $expression; + } + /** + * Returns a string representation of the token stream. + * + * @return string + */ + public function __toString() + { + return \implode("\n", $this->tokens); + } + /** + * Sets the pointer to the next token and returns the old one. + */ + public function next() + { + ++$this->position; + if (!isset($this->tokens[$this->position])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError('Unexpected end of expression.', $this->current->cursor, $this->expression); + } + $this->current = $this->tokens[$this->position]; + } + /** + * Tests a token. + * + * @param array|int $type The type to test + * @param string|null $value The token value + * @param string|null $message The syntax error message + */ + public function expect($type, $value = null, $message = null) + { + $token = $this->current; + if (!$token->test($type, $value)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\SyntaxError(\sprintf('%sUnexpected token "%s" of value "%s" ("%s" expected%s).', $message ? $message . '. ' : '', $token->type, $token->value, $type, $value ? \sprintf(' with value "%s"', $value) : ''), $token->cursor, $this->expression); + } + $this->next(); + } + /** + * Checks if end of stream was reached. + * + * @return bool + */ + public function isEOF() + { + return \_PhpScoper5ea00cc67502b\Symfony\Component\ExpressionLanguage\Token::EOF_TYPE === $this->current->type; + } + /** + * @internal + * + * @return string + */ + public function getExpression() + { + return $this->expression; + } +} diff --git a/vendor/symfony/expression-language/composer.json b/vendor/symfony/expression-language/composer.json index 300fb8c15..e052c5b3b 100644 --- a/vendor/symfony/expression-language/composer.json +++ b/vendor/symfony/expression-language/composer.json @@ -1,37 +1,37 @@ -{ - "name": "symfony\/expression-language", - "type": "library", - "description": "Symfony ExpressionLanguage Component", - "keywords": [], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": "^5.5.9|>=7.0.8", - "symfony\/cache": "~3.1|~4.0", - "symfony\/polyfill-php70": "~1.6" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\": "" - }, - "exclude-from-classmap": [ - "\/Tests\/" - ] - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - } +{ + "name": "symfony\/expression-language", + "type": "library", + "description": "Symfony ExpressionLanguage Component", + "keywords": [], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": "^5.5.9|>=7.0.8", + "symfony\/cache": "~3.1|~4.0", + "symfony\/polyfill-php70": "~1.6" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Component\\ExpressionLanguage\\": "" + }, + "exclude-from-classmap": [ + "\/Tests\/" + ] + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/expression-language/index.php b/vendor/symfony/expression-language/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/expression-language/index.php +++ b/vendor/symfony/expression-language/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/expression-language/phpunit.xml.dist b/vendor/symfony/expression-language/phpunit.xml.dist index ae84dcd94..afc518f63 100644 --- a/vendor/symfony/expression-language/phpunit.xml.dist +++ b/vendor/symfony/expression-language/phpunit.xml.dist @@ -1,30 +1,30 @@ - - - - - - - - - - ./Tests/ - - - - - - ./ - - ./Tests - ./vendor - - - - + + + + + + + + + + ./Tests/ + + + + + + ./ + + ./Tests + ./vendor + + + + diff --git a/vendor/symfony/filesystem/.gitignore b/vendor/symfony/filesystem/.gitignore index c49a5d8df..e31d97a46 100644 --- a/vendor/symfony/filesystem/.gitignore +++ b/vendor/symfony/filesystem/.gitignore @@ -1,3 +1,3 @@ -vendor/ -composer.lock -phpunit.xml +vendor/ +composer.lock +phpunit.xml diff --git a/vendor/symfony/filesystem/CHANGELOG.md b/vendor/symfony/filesystem/CHANGELOG.md index d01f5f45e..f37c9632e 100644 --- a/vendor/symfony/filesystem/CHANGELOG.md +++ b/vendor/symfony/filesystem/CHANGELOG.md @@ -1,53 +1,53 @@ -CHANGELOG -========= - -3.4.0 ------ - - * support for passing relative paths to `Filesystem::makePathRelative()` is deprecated and will be removed in 4.0 - -3.3.0 ------ - - * added `appendToFile()` to append contents to existing files - -3.2.0 ------ - - * added `readlink()` as a platform independent method to read links - -3.0.0 ------ - - * removed `$mode` argument from `Filesystem::dumpFile()` - -2.8.0 ------ - - * added tempnam() a stream aware version of PHP's native tempnam() - -2.6.0 ------ - - * added LockHandler - -2.3.12 ------- - - * deprecated dumpFile() file mode argument. - -2.3.0 ------ - - * added the dumpFile() method to atomically write files - -2.2.0 ------ - - * added a delete option for the mirror() method - -2.1.0 ------ - - * 24eb396 : BC Break : mkdir() function now throws exception in case of failure instead of returning Boolean value - * created the component +CHANGELOG +========= + +3.4.0 +----- + + * support for passing relative paths to `Filesystem::makePathRelative()` is deprecated and will be removed in 4.0 + +3.3.0 +----- + + * added `appendToFile()` to append contents to existing files + +3.2.0 +----- + + * added `readlink()` as a platform independent method to read links + +3.0.0 +----- + + * removed `$mode` argument from `Filesystem::dumpFile()` + +2.8.0 +----- + + * added tempnam() a stream aware version of PHP's native tempnam() + +2.6.0 +----- + + * added LockHandler + +2.3.12 +------ + + * deprecated dumpFile() file mode argument. + +2.3.0 +----- + + * added the dumpFile() method to atomically write files + +2.2.0 +----- + + * added a delete option for the mirror() method + +2.1.0 +----- + + * 24eb396 : BC Break : mkdir() function now throws exception in case of failure instead of returning Boolean value + * created the component diff --git a/vendor/symfony/filesystem/Exception/ExceptionInterface.php b/vendor/symfony/filesystem/Exception/ExceptionInterface.php index f45e73664..8695375e5 100644 --- a/vendor/symfony/filesystem/Exception/ExceptionInterface.php +++ b/vendor/symfony/filesystem/Exception/ExceptionInterface.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception; - -/** - * Exception interface for all exceptions thrown by the component. - * - * @author Romain Neutron - */ -interface ExceptionInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception; + +/** + * Exception interface for all exceptions thrown by the component. + * + * @author Romain Neutron + */ +interface ExceptionInterface +{ +} diff --git a/vendor/symfony/filesystem/Exception/FileNotFoundException.php b/vendor/symfony/filesystem/Exception/FileNotFoundException.php index a2c36434a..d44d257ed 100644 --- a/vendor/symfony/filesystem/Exception/FileNotFoundException.php +++ b/vendor/symfony/filesystem/Exception/FileNotFoundException.php @@ -1,32 +1,32 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception; - -/** - * Exception class thrown when a file couldn't be found. - * - * @author Fabien Potencier - * @author Christian Gärtner - */ -class FileNotFoundException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException -{ - public function __construct($message = null, $code = 0, \Exception $previous = null, $path = null) - { - if (null === $message) { - if (null === $path) { - $message = 'File could not be found.'; - } else { - $message = \sprintf('File "%s" could not be found.', $path); - } - } - parent::__construct($message, $code, $previous, $path); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception; + +/** + * Exception class thrown when a file couldn't be found. + * + * @author Fabien Potencier + * @author Christian Gärtner + */ +class FileNotFoundException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException +{ + public function __construct($message = null, $code = 0, \Exception $previous = null, $path = null) + { + if (null === $message) { + if (null === $path) { + $message = 'File could not be found.'; + } else { + $message = \sprintf('File "%s" could not be found.', $path); + } + } + parent::__construct($message, $code, $previous, $path); + } +} diff --git a/vendor/symfony/filesystem/Exception/IOException.php b/vendor/symfony/filesystem/Exception/IOException.php index e77c6efe0..0a82a2fc5 100644 --- a/vendor/symfony/filesystem/Exception/IOException.php +++ b/vendor/symfony/filesystem/Exception/IOException.php @@ -1,35 +1,35 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception; - -/** - * Exception class thrown when a filesystem operation failure happens. - * - * @author Romain Neutron - * @author Christian Gärtner - * @author Fabien Potencier - */ -class IOException extends \RuntimeException implements \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOExceptionInterface -{ - private $path; - public function __construct($message, $code = 0, \Exception $previous = null, $path = null) - { - $this->path = $path; - parent::__construct($message, $code, $previous); - } - /** - * {@inheritdoc} - */ - public function getPath() - { - return $this->path; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception; + +/** + * Exception class thrown when a filesystem operation failure happens. + * + * @author Romain Neutron + * @author Christian Gärtner + * @author Fabien Potencier + */ +class IOException extends \RuntimeException implements \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOExceptionInterface +{ + private $path; + public function __construct($message, $code = 0, \Exception $previous = null, $path = null) + { + $this->path = $path; + parent::__construct($message, $code, $previous); + } + /** + * {@inheritdoc} + */ + public function getPath() + { + return $this->path; + } +} diff --git a/vendor/symfony/filesystem/Exception/IOExceptionInterface.php b/vendor/symfony/filesystem/Exception/IOExceptionInterface.php index f39d6e9a0..b663530e9 100644 --- a/vendor/symfony/filesystem/Exception/IOExceptionInterface.php +++ b/vendor/symfony/filesystem/Exception/IOExceptionInterface.php @@ -1,26 +1,26 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception; - -/** - * IOException interface for file and input/output stream related exceptions thrown by the component. - * - * @author Christian Gärtner - */ -interface IOExceptionInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\ExceptionInterface -{ - /** - * Returns the associated path for the exception. - * - * @return string|null The path - */ - public function getPath(); -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception; + +/** + * IOException interface for file and input/output stream related exceptions thrown by the component. + * + * @author Christian Gärtner + */ +interface IOExceptionInterface extends \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\ExceptionInterface +{ + /** + * Returns the associated path for the exception. + * + * @return string|null The path + */ + public function getPath(); +} diff --git a/vendor/symfony/filesystem/Exception/index.php b/vendor/symfony/filesystem/Exception/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/filesystem/Exception/index.php +++ b/vendor/symfony/filesystem/Exception/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/filesystem/Filesystem.php b/vendor/symfony/filesystem/Filesystem.php index fb1127221..bed7b2d9b 100644 --- a/vendor/symfony/filesystem/Filesystem.php +++ b/vendor/symfony/filesystem/Filesystem.php @@ -1,670 +1,670 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException; -/** - * Provides basic utility to manipulate the file system. - * - * @author Fabien Potencier - */ -class Filesystem -{ - private static $lastError; - /** - * Copies a file. - * - * If the target file is older than the origin file, it's always overwritten. - * If the target file is newer, it is overwritten only when the - * $overwriteNewerFiles option is set to true. - * - * @param string $originFile The original filename - * @param string $targetFile The target filename - * @param bool $overwriteNewerFiles If true, target files newer than origin files are overwritten - * - * @throws FileNotFoundException When originFile doesn't exist - * @throws IOException When copy fails - */ - public function copy($originFile, $targetFile, $overwriteNewerFiles = \false) - { - $originIsLocal = \stream_is_local($originFile) || 0 === \stripos($originFile, 'file://'); - if ($originIsLocal && !\is_file($originFile)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException(\sprintf('Failed to copy "%s" because file does not exist.', $originFile), 0, null, $originFile); - } - $this->mkdir(\dirname($targetFile)); - $doCopy = \true; - if (!$overwriteNewerFiles && null === \parse_url($originFile, \PHP_URL_HOST) && \is_file($targetFile)) { - $doCopy = \filemtime($originFile) > \filemtime($targetFile); - } - if ($doCopy) { - // https://bugs.php.net/64634 - if (\false === ($source = @\fopen($originFile, 'r'))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to copy "%s" to "%s" because source file could not be opened for reading.', $originFile, $targetFile), 0, null, $originFile); - } - // Stream context created to allow files overwrite when using FTP stream wrapper - disabled by default - if (\false === ($target = @\fopen($targetFile, 'w', null, \stream_context_create(['ftp' => ['overwrite' => \true]])))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to copy "%s" to "%s" because target file could not be opened for writing.', $originFile, $targetFile), 0, null, $originFile); - } - $bytesCopied = \stream_copy_to_stream($source, $target); - \fclose($source); - \fclose($target); - unset($source, $target); - if (!\is_file($targetFile)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to copy "%s" to "%s".', $originFile, $targetFile), 0, null, $originFile); - } - if ($originIsLocal) { - // Like `cp`, preserve executable permission bits - @\chmod($targetFile, \fileperms($targetFile) | \fileperms($originFile) & 0111); - if ($bytesCopied !== ($bytesOrigin = \filesize($originFile))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to copy the whole content of "%s" to "%s" (%g of %g bytes copied).', $originFile, $targetFile, $bytesCopied, $bytesOrigin), 0, null, $originFile); - } - } - } - } - /** - * Creates a directory recursively. - * - * @param string|iterable $dirs The directory path - * @param int $mode The directory mode - * - * @throws IOException On any directory creation failure - */ - public function mkdir($dirs, $mode = 0777) - { - foreach ($this->toIterable($dirs) as $dir) { - if (\is_dir($dir)) { - continue; - } - if (!self::box('mkdir', $dir, $mode, \true)) { - if (!\is_dir($dir)) { - // The directory was not created by a concurrent process. Let's throw an exception with a developer friendly error message if we have one - if (self::$lastError) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to create "%s": %s.', $dir, self::$lastError), 0, null, $dir); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to create "%s".', $dir), 0, null, $dir); - } - } - } - } - /** - * Checks the existence of files or directories. - * - * @param string|iterable $files A filename, an array of files, or a \Traversable instance to check - * - * @return bool true if the file exists, false otherwise - */ - public function exists($files) - { - $maxPathLength = \PHP_MAXPATHLEN - 2; - foreach ($this->toIterable($files) as $file) { - if (\strlen($file) > $maxPathLength) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Could not check if file exist because path length exceeds %d characters.', $maxPathLength), 0, null, $file); - } - if (!\file_exists($file)) { - return \false; - } - } - return \true; - } - /** - * Sets access and modification time of file. - * - * @param string|iterable $files A filename, an array of files, or a \Traversable instance to create - * @param int|null $time The touch time as a Unix timestamp, if not supplied the current system time is used - * @param int|null $atime The access time as a Unix timestamp, if not supplied the current system time is used - * - * @throws IOException When touch fails - */ - public function touch($files, $time = null, $atime = null) - { - foreach ($this->toIterable($files) as $file) { - $touch = $time ? @\touch($file, $time, $atime) : @\touch($file); - if (\true !== $touch) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to touch "%s".', $file), 0, null, $file); - } - } - } - /** - * Removes files or directories. - * - * @param string|iterable $files A filename, an array of files, or a \Traversable instance to remove - * - * @throws IOException When removal fails - */ - public function remove($files) - { - if ($files instanceof \Traversable) { - $files = \iterator_to_array($files, \false); - } elseif (!\is_array($files)) { - $files = [$files]; - } - $files = \array_reverse($files); - foreach ($files as $file) { - if (\is_link($file)) { - // See https://bugs.php.net/52176 - if (!(self::box('unlink', $file) || '\\' !== \DIRECTORY_SEPARATOR || self::box('rmdir', $file)) && \file_exists($file)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to remove symlink "%s": %s.', $file, self::$lastError)); - } - } elseif (\is_dir($file)) { - $this->remove(new \FilesystemIterator($file, \FilesystemIterator::CURRENT_AS_PATHNAME | \FilesystemIterator::SKIP_DOTS)); - if (!self::box('rmdir', $file) && \file_exists($file)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to remove directory "%s": %s.', $file, self::$lastError)); - } - } elseif (!self::box('unlink', $file) && \file_exists($file)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to remove file "%s": %s.', $file, self::$lastError)); - } - } - } - /** - * Change mode for an array of files or directories. - * - * @param string|iterable $files A filename, an array of files, or a \Traversable instance to change mode - * @param int $mode The new mode (octal) - * @param int $umask The mode mask (octal) - * @param bool $recursive Whether change the mod recursively or not - * - * @throws IOException When the change fails - */ - public function chmod($files, $mode, $umask = 00, $recursive = \false) - { - foreach ($this->toIterable($files) as $file) { - if (\true !== @\chmod($file, $mode & ~$umask)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to chmod file "%s".', $file), 0, null, $file); - } - if ($recursive && \is_dir($file) && !\is_link($file)) { - $this->chmod(new \FilesystemIterator($file), $mode, $umask, \true); - } - } - } - /** - * Change the owner of an array of files or directories. - * - * @param string|iterable $files A filename, an array of files, or a \Traversable instance to change owner - * @param string|int $user A user name or number - * @param bool $recursive Whether change the owner recursively or not - * - * @throws IOException When the change fails - */ - public function chown($files, $user, $recursive = \false) - { - foreach ($this->toIterable($files) as $file) { - if ($recursive && \is_dir($file) && !\is_link($file)) { - $this->chown(new \FilesystemIterator($file), $user, \true); - } - if (\is_link($file) && \function_exists('lchown')) { - if (\true !== @\lchown($file, $user)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to chown file "%s".', $file), 0, null, $file); - } - } else { - if (\true !== @\chown($file, $user)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to chown file "%s".', $file), 0, null, $file); - } - } - } - } - /** - * Change the group of an array of files or directories. - * - * @param string|iterable $files A filename, an array of files, or a \Traversable instance to change group - * @param string|int $group A group name or number - * @param bool $recursive Whether change the group recursively or not - * - * @throws IOException When the change fails - */ - public function chgrp($files, $group, $recursive = \false) - { - foreach ($this->toIterable($files) as $file) { - if ($recursive && \is_dir($file) && !\is_link($file)) { - $this->chgrp(new \FilesystemIterator($file), $group, \true); - } - if (\is_link($file) && \function_exists('lchgrp')) { - if (\true !== @\lchgrp($file, $group) || \defined('HHVM_VERSION') && !\posix_getgrnam($group)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to chgrp file "%s".', $file), 0, null, $file); - } - } else { - if (\true !== @\chgrp($file, $group)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to chgrp file "%s".', $file), 0, null, $file); - } - } - } - } - /** - * Renames a file or a directory. - * - * @param string $origin The origin filename or directory - * @param string $target The new filename or directory - * @param bool $overwrite Whether to overwrite the target if it already exists - * - * @throws IOException When target file or directory already exists - * @throws IOException When origin cannot be renamed - */ - public function rename($origin, $target, $overwrite = \false) - { - // we check that target does not exist - if (!$overwrite && $this->isReadable($target)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Cannot rename because the target "%s" already exists.', $target), 0, null, $target); - } - if (\true !== @\rename($origin, $target)) { - if (\is_dir($origin)) { - // See https://bugs.php.net/54097 & https://php.net/rename#113943 - $this->mirror($origin, $target, null, ['override' => $overwrite, 'delete' => $overwrite]); - $this->remove($origin); - return; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Cannot rename "%s" to "%s".', $origin, $target), 0, null, $target); - } - } - /** - * Tells whether a file exists and is readable. - * - * @param string $filename Path to the file - * - * @return bool - * - * @throws IOException When windows path is longer than 258 characters - */ - private function isReadable($filename) - { - $maxPathLength = \PHP_MAXPATHLEN - 2; - if (\strlen($filename) > $maxPathLength) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Could not check if file is readable because path length exceeds %d characters.', $maxPathLength), 0, null, $filename); - } - return \is_readable($filename); - } - /** - * Creates a symbolic link or copy a directory. - * - * @param string $originDir The origin directory path - * @param string $targetDir The symbolic link name - * @param bool $copyOnWindows Whether to copy files if on Windows - * - * @throws IOException When symlink fails - */ - public function symlink($originDir, $targetDir, $copyOnWindows = \false) - { - if ('\\' === \DIRECTORY_SEPARATOR) { - $originDir = \strtr($originDir, '/', '\\'); - $targetDir = \strtr($targetDir, '/', '\\'); - if ($copyOnWindows) { - $this->mirror($originDir, $targetDir); - return; - } - } - $this->mkdir(\dirname($targetDir)); - if (\is_link($targetDir)) { - if (\readlink($targetDir) === $originDir) { - return; - } - $this->remove($targetDir); - } - if (!self::box('symlink', $originDir, $targetDir)) { - $this->linkException($originDir, $targetDir, 'symbolic'); - } - } - /** - * Creates a hard link, or several hard links to a file. - * - * @param string $originFile The original file - * @param string|string[] $targetFiles The target file(s) - * - * @throws FileNotFoundException When original file is missing or not a file - * @throws IOException When link fails, including if link already exists - */ - public function hardlink($originFile, $targetFiles) - { - if (!$this->exists($originFile)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException(null, 0, null, $originFile); - } - if (!\is_file($originFile)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException(\sprintf('Origin file "%s" is not a file.', $originFile)); - } - foreach ($this->toIterable($targetFiles) as $targetFile) { - if (\is_file($targetFile)) { - if (\fileinode($originFile) === \fileinode($targetFile)) { - continue; - } - $this->remove($targetFile); - } - if (!self::box('link', $originFile, $targetFile)) { - $this->linkException($originFile, $targetFile, 'hard'); - } - } - } - /** - * @param string $origin - * @param string $target - * @param string $linkType Name of the link type, typically 'symbolic' or 'hard' - */ - private function linkException($origin, $target, $linkType) - { - if (self::$lastError) { - if ('\\' === \DIRECTORY_SEPARATOR && \false !== \strpos(self::$lastError, 'error code(1314)')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Unable to create "%s" link due to error code 1314: \'A required privilege is not held by the client\'. Do you have the required Administrator-rights?', $linkType), 0, null, $target); - } - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to create "%s" link from "%s" to "%s".', $linkType, $origin, $target), 0, null, $target); - } - /** - * Resolves links in paths. - * - * With $canonicalize = false (default) - * - if $path does not exist or is not a link, returns null - * - if $path is a link, returns the next direct target of the link without considering the existence of the target - * - * With $canonicalize = true - * - if $path does not exist, returns null - * - if $path exists, returns its absolute fully resolved final version - * - * @param string $path A filesystem path - * @param bool $canonicalize Whether or not to return a canonicalized path - * - * @return string|null - */ - public function readlink($path, $canonicalize = \false) - { - if (!$canonicalize && !\is_link($path)) { - return null; - } - if ($canonicalize) { - if (!$this->exists($path)) { - return null; - } - if ('\\' === \DIRECTORY_SEPARATOR) { - $path = \readlink($path); - } - return \realpath($path); - } - if ('\\' === \DIRECTORY_SEPARATOR) { - return \realpath($path); - } - return \readlink($path); - } - /** - * Given an existing path, convert it to a path relative to a given starting path. - * - * @param string $endPath Absolute path of target - * @param string $startPath Absolute path where traversal begins - * - * @return string Path of target relative to starting path - */ - public function makePathRelative($endPath, $startPath) - { - if (!$this->isAbsolutePath($endPath) || !$this->isAbsolutePath($startPath)) { - @\trigger_error(\sprintf('Support for passing relative paths to %s() is deprecated since Symfony 3.4 and will be removed in 4.0.', __METHOD__), \E_USER_DEPRECATED); - } - // Normalize separators on Windows - if ('\\' === \DIRECTORY_SEPARATOR) { - $endPath = \str_replace('\\', '/', $endPath); - $startPath = \str_replace('\\', '/', $startPath); - } - $stripDriveLetter = function ($path) { - if (\strlen($path) > 2 && ':' === $path[1] && '/' === $path[2] && \ctype_alpha($path[0])) { - return \substr($path, 2); - } - return $path; - }; - $endPath = $stripDriveLetter($endPath); - $startPath = $stripDriveLetter($startPath); - // Split the paths into arrays - $startPathArr = \explode('/', \trim($startPath, '/')); - $endPathArr = \explode('/', \trim($endPath, '/')); - $normalizePathArray = function ($pathSegments, $absolute) { - $result = []; - foreach ($pathSegments as $segment) { - if ('..' === $segment && ($absolute || \count($result))) { - \array_pop($result); - } elseif ('.' !== $segment) { - $result[] = $segment; - } - } - return $result; - }; - $startPathArr = $normalizePathArray($startPathArr, static::isAbsolutePath($startPath)); - $endPathArr = $normalizePathArray($endPathArr, static::isAbsolutePath($endPath)); - // Find for which directory the common path stops - $index = 0; - while (isset($startPathArr[$index]) && isset($endPathArr[$index]) && $startPathArr[$index] === $endPathArr[$index]) { - ++$index; - } - // Determine how deep the start path is relative to the common path (ie, "web/bundles" = 2 levels) - if (1 === \count($startPathArr) && '' === $startPathArr[0]) { - $depth = 0; - } else { - $depth = \count($startPathArr) - $index; - } - // Repeated "../" for each level need to reach the common path - $traverser = \str_repeat('../', $depth); - $endPathRemainder = \implode('/', \array_slice($endPathArr, $index)); - // Construct $endPath from traversing to the common path, then to the remaining $endPath - $relativePath = $traverser . ('' !== $endPathRemainder ? $endPathRemainder . '/' : ''); - return '' === $relativePath ? './' : $relativePath; - } - /** - * Mirrors a directory to another. - * - * Copies files and directories from the origin directory into the target directory. By default: - * - * - existing files in the target directory will be overwritten, except if they are newer (see the `override` option) - * - files in the target directory that do not exist in the source directory will not be deleted (see the `delete` option) - * - * @param string $originDir The origin directory - * @param string $targetDir The target directory - * @param \Traversable|null $iterator Iterator that filters which files and directories to copy, if null a recursive iterator is created - * @param array $options An array of boolean options - * Valid options are: - * - $options['override'] If true, target files newer than origin files are overwritten (see copy(), defaults to false) - * - $options['copy_on_windows'] Whether to copy files instead of links on Windows (see symlink(), defaults to false) - * - $options['delete'] Whether to delete files that are not in the source directory (defaults to false) - * - * @throws IOException When file type is unknown - */ - public function mirror($originDir, $targetDir, \Traversable $iterator = null, $options = []) - { - $targetDir = \rtrim($targetDir, '/\\'); - $originDir = \rtrim($originDir, '/\\'); - $originDirLen = \strlen($originDir); - // Iterate in destination folder to remove obsolete entries - if ($this->exists($targetDir) && isset($options['delete']) && $options['delete']) { - $deleteIterator = $iterator; - if (null === $deleteIterator) { - $flags = \FilesystemIterator::SKIP_DOTS; - $deleteIterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($targetDir, $flags), \RecursiveIteratorIterator::CHILD_FIRST); - } - $targetDirLen = \strlen($targetDir); - foreach ($deleteIterator as $file) { - $origin = $originDir . \substr($file->getPathname(), $targetDirLen); - if (!$this->exists($origin)) { - $this->remove($file); - } - } - } - $copyOnWindows = \false; - if (isset($options['copy_on_windows'])) { - $copyOnWindows = $options['copy_on_windows']; - } - if (null === $iterator) { - $flags = $copyOnWindows ? \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::FOLLOW_SYMLINKS : \FilesystemIterator::SKIP_DOTS; - $iterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($originDir, $flags), \RecursiveIteratorIterator::SELF_FIRST); - } - if ($this->exists($originDir)) { - $this->mkdir($targetDir); - } - foreach ($iterator as $file) { - $target = $targetDir . \substr($file->getPathname(), $originDirLen); - if ($copyOnWindows) { - if (\is_file($file)) { - $this->copy($file, $target, isset($options['override']) ? $options['override'] : \false); - } elseif (\is_dir($file)) { - $this->mkdir($target); - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Unable to guess "%s" file type.', $file), 0, null, $file); - } - } else { - if (\is_link($file)) { - $this->symlink($file->getLinkTarget(), $target); - } elseif (\is_dir($file)) { - $this->mkdir($target); - } elseif (\is_file($file)) { - $this->copy($file, $target, isset($options['override']) ? $options['override'] : \false); - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Unable to guess "%s" file type.', $file), 0, null, $file); - } - } - } - } - /** - * Returns whether the file path is an absolute path. - * - * @param string $file A file path - * - * @return bool - */ - public function isAbsolutePath($file) - { - return \strspn($file, '/\\', 0, 1) || \strlen($file) > 3 && \ctype_alpha($file[0]) && ':' === $file[1] && \strspn($file, '/\\', 2, 1) || null !== \parse_url($file, \PHP_URL_SCHEME); - } - /** - * Creates a temporary file with support for custom stream wrappers. - * - * @param string $dir The directory where the temporary filename will be created - * @param string $prefix The prefix of the generated temporary filename - * Note: Windows uses only the first three characters of prefix - * - * @return string The new temporary filename (with path), or throw an exception on failure - */ - public function tempnam($dir, $prefix) - { - list($scheme, $hierarchy) = $this->getSchemeAndHierarchy($dir); - // If no scheme or scheme is "file" or "gs" (Google Cloud) create temp file in local filesystem - if (null === $scheme || 'file' === $scheme || 'gs' === $scheme) { - $tmpFile = @\tempnam($hierarchy, $prefix); - // If tempnam failed or no scheme return the filename otherwise prepend the scheme - if (\false !== $tmpFile) { - if (null !== $scheme && 'gs' !== $scheme) { - return $scheme . '://' . $tmpFile; - } - return $tmpFile; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException('A temporary file could not be created.'); - } - // Loop until we create a valid temp file or have reached 10 attempts - for ($i = 0; $i < 10; ++$i) { - // Create a unique filename - $tmpFile = $dir . '/' . $prefix . \uniqid(\mt_rand(), \true); - // Use fopen instead of file_exists as some streams do not support stat - // Use mode 'x+' to atomically check existence and create to avoid a TOCTOU vulnerability - $handle = @\fopen($tmpFile, 'x+'); - // If unsuccessful restart the loop - if (\false === $handle) { - continue; - } - // Close the file if it was successfully opened - @\fclose($handle); - return $tmpFile; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException('A temporary file could not be created.'); - } - /** - * Atomically dumps content into a file. - * - * @param string $filename The file to be written to - * @param string $content The data to write into the file - * - * @throws IOException if the file cannot be written to - */ - public function dumpFile($filename, $content) - { - $dir = \dirname($filename); - if (!\is_dir($dir)) { - $this->mkdir($dir); - } - if (!\is_writable($dir)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Unable to write to the "%s" directory.', $dir), 0, null, $dir); - } - // Will create a temp file with 0600 access rights - // when the filesystem supports chmod. - $tmpFile = $this->tempnam($dir, \basename($filename)); - if (\false === @\file_put_contents($tmpFile, $content)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to write file "%s".', $filename), 0, null, $filename); - } - @\chmod($tmpFile, \file_exists($filename) ? \fileperms($filename) : 0666 & ~\umask()); - $this->rename($tmpFile, $filename, \true); - } - /** - * Appends content to an existing file. - * - * @param string $filename The file to which to append content - * @param string $content The content to append - * - * @throws IOException If the file is not writable - */ - public function appendToFile($filename, $content) - { - $dir = \dirname($filename); - if (!\is_dir($dir)) { - $this->mkdir($dir); - } - if (!\is_writable($dir)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Unable to write to the "%s" directory.', $dir), 0, null, $dir); - } - if (\false === @\file_put_contents($filename, $content, \FILE_APPEND)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to write file "%s".', $filename), 0, null, $filename); - } - } - /** - * @param mixed $files - * - * @return array|\Traversable - */ - private function toIterable($files) - { - return \is_array($files) || $files instanceof \Traversable ? $files : [$files]; - } - /** - * Gets a 2-tuple of scheme (may be null) and hierarchical part of a filename (e.g. file:///tmp -> [file, tmp]). - * - * @param string $filename The filename to be parsed - * - * @return array The filename scheme and hierarchical part - */ - private function getSchemeAndHierarchy($filename) - { - $components = \explode('://', $filename, 2); - return 2 === \count($components) ? [$components[0], $components[1]] : [null, $components[0]]; - } - /** - * @param callable $func - * - * @return mixed - */ - private static function box($func) - { - self::$lastError = null; - \set_error_handler(__CLASS__ . '::handleError'); - try { - $result = \call_user_func_array($func, \array_slice(\func_get_args(), 1)); - \restore_error_handler(); - return $result; - } catch (\Throwable $e) { - } catch (\Exception $e) { - } - \restore_error_handler(); - throw $e; - } - /** - * @internal - */ - public static function handleError($type, $msg) - { - self::$lastError = $msg; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException; +/** + * Provides basic utility to manipulate the file system. + * + * @author Fabien Potencier + */ +class Filesystem +{ + private static $lastError; + /** + * Copies a file. + * + * If the target file is older than the origin file, it's always overwritten. + * If the target file is newer, it is overwritten only when the + * $overwriteNewerFiles option is set to true. + * + * @param string $originFile The original filename + * @param string $targetFile The target filename + * @param bool $overwriteNewerFiles If true, target files newer than origin files are overwritten + * + * @throws FileNotFoundException When originFile doesn't exist + * @throws IOException When copy fails + */ + public function copy($originFile, $targetFile, $overwriteNewerFiles = \false) + { + $originIsLocal = \stream_is_local($originFile) || 0 === \stripos($originFile, 'file://'); + if ($originIsLocal && !\is_file($originFile)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException(\sprintf('Failed to copy "%s" because file does not exist.', $originFile), 0, null, $originFile); + } + $this->mkdir(\dirname($targetFile)); + $doCopy = \true; + if (!$overwriteNewerFiles && null === \parse_url($originFile, \PHP_URL_HOST) && \is_file($targetFile)) { + $doCopy = \filemtime($originFile) > \filemtime($targetFile); + } + if ($doCopy) { + // https://bugs.php.net/64634 + if (\false === ($source = @\fopen($originFile, 'r'))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to copy "%s" to "%s" because source file could not be opened for reading.', $originFile, $targetFile), 0, null, $originFile); + } + // Stream context created to allow files overwrite when using FTP stream wrapper - disabled by default + if (\false === ($target = @\fopen($targetFile, 'w', null, \stream_context_create(['ftp' => ['overwrite' => \true]])))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to copy "%s" to "%s" because target file could not be opened for writing.', $originFile, $targetFile), 0, null, $originFile); + } + $bytesCopied = \stream_copy_to_stream($source, $target); + \fclose($source); + \fclose($target); + unset($source, $target); + if (!\is_file($targetFile)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to copy "%s" to "%s".', $originFile, $targetFile), 0, null, $originFile); + } + if ($originIsLocal) { + // Like `cp`, preserve executable permission bits + @\chmod($targetFile, \fileperms($targetFile) | \fileperms($originFile) & 0111); + if ($bytesCopied !== ($bytesOrigin = \filesize($originFile))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to copy the whole content of "%s" to "%s" (%g of %g bytes copied).', $originFile, $targetFile, $bytesCopied, $bytesOrigin), 0, null, $originFile); + } + } + } + } + /** + * Creates a directory recursively. + * + * @param string|iterable $dirs The directory path + * @param int $mode The directory mode + * + * @throws IOException On any directory creation failure + */ + public function mkdir($dirs, $mode = 0777) + { + foreach ($this->toIterable($dirs) as $dir) { + if (\is_dir($dir)) { + continue; + } + if (!self::box('mkdir', $dir, $mode, \true)) { + if (!\is_dir($dir)) { + // The directory was not created by a concurrent process. Let's throw an exception with a developer friendly error message if we have one + if (self::$lastError) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to create "%s": %s.', $dir, self::$lastError), 0, null, $dir); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to create "%s".', $dir), 0, null, $dir); + } + } + } + } + /** + * Checks the existence of files or directories. + * + * @param string|iterable $files A filename, an array of files, or a \Traversable instance to check + * + * @return bool true if the file exists, false otherwise + */ + public function exists($files) + { + $maxPathLength = \PHP_MAXPATHLEN - 2; + foreach ($this->toIterable($files) as $file) { + if (\strlen($file) > $maxPathLength) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Could not check if file exist because path length exceeds %d characters.', $maxPathLength), 0, null, $file); + } + if (!\file_exists($file)) { + return \false; + } + } + return \true; + } + /** + * Sets access and modification time of file. + * + * @param string|iterable $files A filename, an array of files, or a \Traversable instance to create + * @param int|null $time The touch time as a Unix timestamp, if not supplied the current system time is used + * @param int|null $atime The access time as a Unix timestamp, if not supplied the current system time is used + * + * @throws IOException When touch fails + */ + public function touch($files, $time = null, $atime = null) + { + foreach ($this->toIterable($files) as $file) { + $touch = $time ? @\touch($file, $time, $atime) : @\touch($file); + if (\true !== $touch) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to touch "%s".', $file), 0, null, $file); + } + } + } + /** + * Removes files or directories. + * + * @param string|iterable $files A filename, an array of files, or a \Traversable instance to remove + * + * @throws IOException When removal fails + */ + public function remove($files) + { + if ($files instanceof \Traversable) { + $files = \iterator_to_array($files, \false); + } elseif (!\is_array($files)) { + $files = [$files]; + } + $files = \array_reverse($files); + foreach ($files as $file) { + if (\is_link($file)) { + // See https://bugs.php.net/52176 + if (!(self::box('unlink', $file) || '\\' !== \DIRECTORY_SEPARATOR || self::box('rmdir', $file)) && \file_exists($file)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to remove symlink "%s": %s.', $file, self::$lastError)); + } + } elseif (\is_dir($file)) { + $this->remove(new \FilesystemIterator($file, \FilesystemIterator::CURRENT_AS_PATHNAME | \FilesystemIterator::SKIP_DOTS)); + if (!self::box('rmdir', $file) && \file_exists($file)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to remove directory "%s": %s.', $file, self::$lastError)); + } + } elseif (!self::box('unlink', $file) && \file_exists($file)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to remove file "%s": %s.', $file, self::$lastError)); + } + } + } + /** + * Change mode for an array of files or directories. + * + * @param string|iterable $files A filename, an array of files, or a \Traversable instance to change mode + * @param int $mode The new mode (octal) + * @param int $umask The mode mask (octal) + * @param bool $recursive Whether change the mod recursively or not + * + * @throws IOException When the change fails + */ + public function chmod($files, $mode, $umask = 00, $recursive = \false) + { + foreach ($this->toIterable($files) as $file) { + if (\true !== @\chmod($file, $mode & ~$umask)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to chmod file "%s".', $file), 0, null, $file); + } + if ($recursive && \is_dir($file) && !\is_link($file)) { + $this->chmod(new \FilesystemIterator($file), $mode, $umask, \true); + } + } + } + /** + * Change the owner of an array of files or directories. + * + * @param string|iterable $files A filename, an array of files, or a \Traversable instance to change owner + * @param string|int $user A user name or number + * @param bool $recursive Whether change the owner recursively or not + * + * @throws IOException When the change fails + */ + public function chown($files, $user, $recursive = \false) + { + foreach ($this->toIterable($files) as $file) { + if ($recursive && \is_dir($file) && !\is_link($file)) { + $this->chown(new \FilesystemIterator($file), $user, \true); + } + if (\is_link($file) && \function_exists('lchown')) { + if (\true !== @\lchown($file, $user)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to chown file "%s".', $file), 0, null, $file); + } + } else { + if (\true !== @\chown($file, $user)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to chown file "%s".', $file), 0, null, $file); + } + } + } + } + /** + * Change the group of an array of files or directories. + * + * @param string|iterable $files A filename, an array of files, or a \Traversable instance to change group + * @param string|int $group A group name or number + * @param bool $recursive Whether change the group recursively or not + * + * @throws IOException When the change fails + */ + public function chgrp($files, $group, $recursive = \false) + { + foreach ($this->toIterable($files) as $file) { + if ($recursive && \is_dir($file) && !\is_link($file)) { + $this->chgrp(new \FilesystemIterator($file), $group, \true); + } + if (\is_link($file) && \function_exists('lchgrp')) { + if (\true !== @\lchgrp($file, $group) || \defined('HHVM_VERSION') && !\posix_getgrnam($group)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to chgrp file "%s".', $file), 0, null, $file); + } + } else { + if (\true !== @\chgrp($file, $group)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to chgrp file "%s".', $file), 0, null, $file); + } + } + } + } + /** + * Renames a file or a directory. + * + * @param string $origin The origin filename or directory + * @param string $target The new filename or directory + * @param bool $overwrite Whether to overwrite the target if it already exists + * + * @throws IOException When target file or directory already exists + * @throws IOException When origin cannot be renamed + */ + public function rename($origin, $target, $overwrite = \false) + { + // we check that target does not exist + if (!$overwrite && $this->isReadable($target)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Cannot rename because the target "%s" already exists.', $target), 0, null, $target); + } + if (\true !== @\rename($origin, $target)) { + if (\is_dir($origin)) { + // See https://bugs.php.net/54097 & https://php.net/rename#113943 + $this->mirror($origin, $target, null, ['override' => $overwrite, 'delete' => $overwrite]); + $this->remove($origin); + return; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Cannot rename "%s" to "%s".', $origin, $target), 0, null, $target); + } + } + /** + * Tells whether a file exists and is readable. + * + * @param string $filename Path to the file + * + * @return bool + * + * @throws IOException When windows path is longer than 258 characters + */ + private function isReadable($filename) + { + $maxPathLength = \PHP_MAXPATHLEN - 2; + if (\strlen($filename) > $maxPathLength) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Could not check if file is readable because path length exceeds %d characters.', $maxPathLength), 0, null, $filename); + } + return \is_readable($filename); + } + /** + * Creates a symbolic link or copy a directory. + * + * @param string $originDir The origin directory path + * @param string $targetDir The symbolic link name + * @param bool $copyOnWindows Whether to copy files if on Windows + * + * @throws IOException When symlink fails + */ + public function symlink($originDir, $targetDir, $copyOnWindows = \false) + { + if ('\\' === \DIRECTORY_SEPARATOR) { + $originDir = \strtr($originDir, '/', '\\'); + $targetDir = \strtr($targetDir, '/', '\\'); + if ($copyOnWindows) { + $this->mirror($originDir, $targetDir); + return; + } + } + $this->mkdir(\dirname($targetDir)); + if (\is_link($targetDir)) { + if (\readlink($targetDir) === $originDir) { + return; + } + $this->remove($targetDir); + } + if (!self::box('symlink', $originDir, $targetDir)) { + $this->linkException($originDir, $targetDir, 'symbolic'); + } + } + /** + * Creates a hard link, or several hard links to a file. + * + * @param string $originFile The original file + * @param string|string[] $targetFiles The target file(s) + * + * @throws FileNotFoundException When original file is missing or not a file + * @throws IOException When link fails, including if link already exists + */ + public function hardlink($originFile, $targetFiles) + { + if (!$this->exists($originFile)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException(null, 0, null, $originFile); + } + if (!\is_file($originFile)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException(\sprintf('Origin file "%s" is not a file.', $originFile)); + } + foreach ($this->toIterable($targetFiles) as $targetFile) { + if (\is_file($targetFile)) { + if (\fileinode($originFile) === \fileinode($targetFile)) { + continue; + } + $this->remove($targetFile); + } + if (!self::box('link', $originFile, $targetFile)) { + $this->linkException($originFile, $targetFile, 'hard'); + } + } + } + /** + * @param string $origin + * @param string $target + * @param string $linkType Name of the link type, typically 'symbolic' or 'hard' + */ + private function linkException($origin, $target, $linkType) + { + if (self::$lastError) { + if ('\\' === \DIRECTORY_SEPARATOR && \false !== \strpos(self::$lastError, 'error code(1314)')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Unable to create "%s" link due to error code 1314: \'A required privilege is not held by the client\'. Do you have the required Administrator-rights?', $linkType), 0, null, $target); + } + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to create "%s" link from "%s" to "%s".', $linkType, $origin, $target), 0, null, $target); + } + /** + * Resolves links in paths. + * + * With $canonicalize = false (default) + * - if $path does not exist or is not a link, returns null + * - if $path is a link, returns the next direct target of the link without considering the existence of the target + * + * With $canonicalize = true + * - if $path does not exist, returns null + * - if $path exists, returns its absolute fully resolved final version + * + * @param string $path A filesystem path + * @param bool $canonicalize Whether or not to return a canonicalized path + * + * @return string|null + */ + public function readlink($path, $canonicalize = \false) + { + if (!$canonicalize && !\is_link($path)) { + return null; + } + if ($canonicalize) { + if (!$this->exists($path)) { + return null; + } + if ('\\' === \DIRECTORY_SEPARATOR) { + $path = \readlink($path); + } + return \realpath($path); + } + if ('\\' === \DIRECTORY_SEPARATOR) { + return \realpath($path); + } + return \readlink($path); + } + /** + * Given an existing path, convert it to a path relative to a given starting path. + * + * @param string $endPath Absolute path of target + * @param string $startPath Absolute path where traversal begins + * + * @return string Path of target relative to starting path + */ + public function makePathRelative($endPath, $startPath) + { + if (!$this->isAbsolutePath($endPath) || !$this->isAbsolutePath($startPath)) { + @\trigger_error(\sprintf('Support for passing relative paths to %s() is deprecated since Symfony 3.4 and will be removed in 4.0.', __METHOD__), \E_USER_DEPRECATED); + } + // Normalize separators on Windows + if ('\\' === \DIRECTORY_SEPARATOR) { + $endPath = \str_replace('\\', '/', $endPath); + $startPath = \str_replace('\\', '/', $startPath); + } + $stripDriveLetter = function ($path) { + if (\strlen($path) > 2 && ':' === $path[1] && '/' === $path[2] && \ctype_alpha($path[0])) { + return \substr($path, 2); + } + return $path; + }; + $endPath = $stripDriveLetter($endPath); + $startPath = $stripDriveLetter($startPath); + // Split the paths into arrays + $startPathArr = \explode('/', \trim($startPath, '/')); + $endPathArr = \explode('/', \trim($endPath, '/')); + $normalizePathArray = function ($pathSegments, $absolute) { + $result = []; + foreach ($pathSegments as $segment) { + if ('..' === $segment && ($absolute || \count($result))) { + \array_pop($result); + } elseif ('.' !== $segment) { + $result[] = $segment; + } + } + return $result; + }; + $startPathArr = $normalizePathArray($startPathArr, static::isAbsolutePath($startPath)); + $endPathArr = $normalizePathArray($endPathArr, static::isAbsolutePath($endPath)); + // Find for which directory the common path stops + $index = 0; + while (isset($startPathArr[$index]) && isset($endPathArr[$index]) && $startPathArr[$index] === $endPathArr[$index]) { + ++$index; + } + // Determine how deep the start path is relative to the common path (ie, "web/bundles" = 2 levels) + if (1 === \count($startPathArr) && '' === $startPathArr[0]) { + $depth = 0; + } else { + $depth = \count($startPathArr) - $index; + } + // Repeated "../" for each level need to reach the common path + $traverser = \str_repeat('../', $depth); + $endPathRemainder = \implode('/', \array_slice($endPathArr, $index)); + // Construct $endPath from traversing to the common path, then to the remaining $endPath + $relativePath = $traverser . ('' !== $endPathRemainder ? $endPathRemainder . '/' : ''); + return '' === $relativePath ? './' : $relativePath; + } + /** + * Mirrors a directory to another. + * + * Copies files and directories from the origin directory into the target directory. By default: + * + * - existing files in the target directory will be overwritten, except if they are newer (see the `override` option) + * - files in the target directory that do not exist in the source directory will not be deleted (see the `delete` option) + * + * @param string $originDir The origin directory + * @param string $targetDir The target directory + * @param \Traversable|null $iterator Iterator that filters which files and directories to copy, if null a recursive iterator is created + * @param array $options An array of boolean options + * Valid options are: + * - $options['override'] If true, target files newer than origin files are overwritten (see copy(), defaults to false) + * - $options['copy_on_windows'] Whether to copy files instead of links on Windows (see symlink(), defaults to false) + * - $options['delete'] Whether to delete files that are not in the source directory (defaults to false) + * + * @throws IOException When file type is unknown + */ + public function mirror($originDir, $targetDir, \Traversable $iterator = null, $options = []) + { + $targetDir = \rtrim($targetDir, '/\\'); + $originDir = \rtrim($originDir, '/\\'); + $originDirLen = \strlen($originDir); + // Iterate in destination folder to remove obsolete entries + if ($this->exists($targetDir) && isset($options['delete']) && $options['delete']) { + $deleteIterator = $iterator; + if (null === $deleteIterator) { + $flags = \FilesystemIterator::SKIP_DOTS; + $deleteIterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($targetDir, $flags), \RecursiveIteratorIterator::CHILD_FIRST); + } + $targetDirLen = \strlen($targetDir); + foreach ($deleteIterator as $file) { + $origin = $originDir . \substr($file->getPathname(), $targetDirLen); + if (!$this->exists($origin)) { + $this->remove($file); + } + } + } + $copyOnWindows = \false; + if (isset($options['copy_on_windows'])) { + $copyOnWindows = $options['copy_on_windows']; + } + if (null === $iterator) { + $flags = $copyOnWindows ? \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::FOLLOW_SYMLINKS : \FilesystemIterator::SKIP_DOTS; + $iterator = new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($originDir, $flags), \RecursiveIteratorIterator::SELF_FIRST); + } + if ($this->exists($originDir)) { + $this->mkdir($targetDir); + } + foreach ($iterator as $file) { + $target = $targetDir . \substr($file->getPathname(), $originDirLen); + if ($copyOnWindows) { + if (\is_file($file)) { + $this->copy($file, $target, isset($options['override']) ? $options['override'] : \false); + } elseif (\is_dir($file)) { + $this->mkdir($target); + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Unable to guess "%s" file type.', $file), 0, null, $file); + } + } else { + if (\is_link($file)) { + $this->symlink($file->getLinkTarget(), $target); + } elseif (\is_dir($file)) { + $this->mkdir($target); + } elseif (\is_file($file)) { + $this->copy($file, $target, isset($options['override']) ? $options['override'] : \false); + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Unable to guess "%s" file type.', $file), 0, null, $file); + } + } + } + } + /** + * Returns whether the file path is an absolute path. + * + * @param string $file A file path + * + * @return bool + */ + public function isAbsolutePath($file) + { + return \strspn($file, '/\\', 0, 1) || \strlen($file) > 3 && \ctype_alpha($file[0]) && ':' === $file[1] && \strspn($file, '/\\', 2, 1) || null !== \parse_url($file, \PHP_URL_SCHEME); + } + /** + * Creates a temporary file with support for custom stream wrappers. + * + * @param string $dir The directory where the temporary filename will be created + * @param string $prefix The prefix of the generated temporary filename + * Note: Windows uses only the first three characters of prefix + * + * @return string The new temporary filename (with path), or throw an exception on failure + */ + public function tempnam($dir, $prefix) + { + list($scheme, $hierarchy) = $this->getSchemeAndHierarchy($dir); + // If no scheme or scheme is "file" or "gs" (Google Cloud) create temp file in local filesystem + if (null === $scheme || 'file' === $scheme || 'gs' === $scheme) { + $tmpFile = @\tempnam($hierarchy, $prefix); + // If tempnam failed or no scheme return the filename otherwise prepend the scheme + if (\false !== $tmpFile) { + if (null !== $scheme && 'gs' !== $scheme) { + return $scheme . '://' . $tmpFile; + } + return $tmpFile; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException('A temporary file could not be created.'); + } + // Loop until we create a valid temp file or have reached 10 attempts + for ($i = 0; $i < 10; ++$i) { + // Create a unique filename + $tmpFile = $dir . '/' . $prefix . \uniqid(\mt_rand(), \true); + // Use fopen instead of file_exists as some streams do not support stat + // Use mode 'x+' to atomically check existence and create to avoid a TOCTOU vulnerability + $handle = @\fopen($tmpFile, 'x+'); + // If unsuccessful restart the loop + if (\false === $handle) { + continue; + } + // Close the file if it was successfully opened + @\fclose($handle); + return $tmpFile; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException('A temporary file could not be created.'); + } + /** + * Atomically dumps content into a file. + * + * @param string $filename The file to be written to + * @param string $content The data to write into the file + * + * @throws IOException if the file cannot be written to + */ + public function dumpFile($filename, $content) + { + $dir = \dirname($filename); + if (!\is_dir($dir)) { + $this->mkdir($dir); + } + if (!\is_writable($dir)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Unable to write to the "%s" directory.', $dir), 0, null, $dir); + } + // Will create a temp file with 0600 access rights + // when the filesystem supports chmod. + $tmpFile = $this->tempnam($dir, \basename($filename)); + if (\false === @\file_put_contents($tmpFile, $content)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to write file "%s".', $filename), 0, null, $filename); + } + @\chmod($tmpFile, \file_exists($filename) ? \fileperms($filename) : 0666 & ~\umask()); + $this->rename($tmpFile, $filename, \true); + } + /** + * Appends content to an existing file. + * + * @param string $filename The file to which to append content + * @param string $content The content to append + * + * @throws IOException If the file is not writable + */ + public function appendToFile($filename, $content) + { + $dir = \dirname($filename); + if (!\is_dir($dir)) { + $this->mkdir($dir); + } + if (!\is_writable($dir)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Unable to write to the "%s" directory.', $dir), 0, null, $dir); + } + if (\false === @\file_put_contents($filename, $content, \FILE_APPEND)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('Failed to write file "%s".', $filename), 0, null, $filename); + } + } + /** + * @param mixed $files + * + * @return array|\Traversable + */ + private function toIterable($files) + { + return \is_array($files) || $files instanceof \Traversable ? $files : [$files]; + } + /** + * Gets a 2-tuple of scheme (may be null) and hierarchical part of a filename (e.g. file:///tmp -> [file, tmp]). + * + * @param string $filename The filename to be parsed + * + * @return array The filename scheme and hierarchical part + */ + private function getSchemeAndHierarchy($filename) + { + $components = \explode('://', $filename, 2); + return 2 === \count($components) ? [$components[0], $components[1]] : [null, $components[0]]; + } + /** + * @param callable $func + * + * @return mixed + */ + private static function box($func) + { + self::$lastError = null; + \set_error_handler(__CLASS__ . '::handleError'); + try { + $result = \call_user_func_array($func, \array_slice(\func_get_args(), 1)); + \restore_error_handler(); + return $result; + } catch (\Throwable $e) { + } catch (\Exception $e) { + } + \restore_error_handler(); + throw $e; + } + /** + * @internal + */ + public static function handleError($type, $msg) + { + self::$lastError = $msg; + } +} diff --git a/vendor/symfony/filesystem/LICENSE b/vendor/symfony/filesystem/LICENSE index 9e936ec04..2bb330476 100644 --- a/vendor/symfony/filesystem/LICENSE +++ b/vendor/symfony/filesystem/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2004-2020 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2004-2020 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/filesystem/LockHandler.php b/vendor/symfony/filesystem/LockHandler.php index 3623254f1..62f79c631 100644 --- a/vendor/symfony/filesystem/LockHandler.php +++ b/vendor/symfony/filesystem/LockHandler.php @@ -1,106 +1,106 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Lock\Store\FlockStore; -use _PhpScoper5ea00cc67502b\Symfony\Component\Lock\Store\SemaphoreStore; -@\trigger_error(\sprintf('The %s class is deprecated since Symfony 3.4 and will be removed in 4.0. Use %s or %s instead.', \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler::class, \_PhpScoper5ea00cc67502b\Symfony\Component\Lock\Store\SemaphoreStore::class, \_PhpScoper5ea00cc67502b\Symfony\Component\Lock\Store\FlockStore::class), \E_USER_DEPRECATED); -/** - * LockHandler class provides a simple abstraction to lock anything by means of - * a file lock. - * - * A locked file is created based on the lock name when calling lock(). Other - * lock handlers will not be able to lock the same name until it is released - * (explicitly by calling release() or implicitly when the instance holding the - * lock is destroyed). - * - * @author Grégoire Pineau - * @author Romain Neutron - * @author Nicolas Grekas - * - * @deprecated since version 3.4, to be removed in 4.0. Use Symfony\Component\Lock\Store\SemaphoreStore or Symfony\Component\Lock\Store\FlockStore instead. - */ -class LockHandler -{ - private $file; - private $handle; - /** - * @param string $name The lock name - * @param string|null $lockPath The directory to store the lock. Default values will use temporary directory - * - * @throws IOException If the lock directory could not be created or is not writable - */ - public function __construct($name, $lockPath = null) - { - $lockPath = $lockPath ?: \sys_get_temp_dir(); - if (!\is_dir($lockPath)) { - $fs = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem(); - $fs->mkdir($lockPath); - } - if (!\is_writable($lockPath)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('The directory "%s" is not writable.', $lockPath), 0, null, $lockPath); - } - $this->file = \sprintf('%s/sf.%s.%s.lock', $lockPath, \preg_replace('/[^a-z0-9\\._-]+/i', '-', $name), \hash('sha256', $name)); - } - /** - * Lock the resource. - * - * @param bool $blocking Wait until the lock is released - * - * @return bool Returns true if the lock was acquired, false otherwise - * - * @throws IOException If the lock file could not be created or opened - */ - public function lock($blocking = \false) - { - if ($this->handle) { - return \true; - } - $error = null; - // Silence error reporting - \set_error_handler(function ($errno, $msg) use(&$error) { - $error = $msg; - }); - if (!($this->handle = \fopen($this->file, 'r+') ?: \fopen($this->file, 'r'))) { - if ($this->handle = \fopen($this->file, 'x')) { - \chmod($this->file, 0666); - } elseif (!($this->handle = \fopen($this->file, 'r+') ?: \fopen($this->file, 'r'))) { - \usleep(100); - // Give some time for chmod() to complete - $this->handle = \fopen($this->file, 'r+') ?: \fopen($this->file, 'r'); - } - } - \restore_error_handler(); - if (!$this->handle) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException($error, 0, null, $this->file); - } - // On Windows, even if PHP doc says the contrary, LOCK_NB works, see - // https://bugs.php.net/54129 - if (!\flock($this->handle, \LOCK_EX | ($blocking ? 0 : \LOCK_NB))) { - \fclose($this->handle); - $this->handle = null; - return \false; - } - return \true; - } - /** - * Release the resource. - */ - public function release() - { - if ($this->handle) { - \flock($this->handle, \LOCK_UN | \LOCK_NB); - \fclose($this->handle); - $this->handle = null; - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Lock\Store\FlockStore; +use _PhpScoper5ea00cc67502b\Symfony\Component\Lock\Store\SemaphoreStore; +@\trigger_error(\sprintf('The %s class is deprecated since Symfony 3.4 and will be removed in 4.0. Use %s or %s instead.', \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler::class, \_PhpScoper5ea00cc67502b\Symfony\Component\Lock\Store\SemaphoreStore::class, \_PhpScoper5ea00cc67502b\Symfony\Component\Lock\Store\FlockStore::class), \E_USER_DEPRECATED); +/** + * LockHandler class provides a simple abstraction to lock anything by means of + * a file lock. + * + * A locked file is created based on the lock name when calling lock(). Other + * lock handlers will not be able to lock the same name until it is released + * (explicitly by calling release() or implicitly when the instance holding the + * lock is destroyed). + * + * @author Grégoire Pineau + * @author Romain Neutron + * @author Nicolas Grekas + * + * @deprecated since version 3.4, to be removed in 4.0. Use Symfony\Component\Lock\Store\SemaphoreStore or Symfony\Component\Lock\Store\FlockStore instead. + */ +class LockHandler +{ + private $file; + private $handle; + /** + * @param string $name The lock name + * @param string|null $lockPath The directory to store the lock. Default values will use temporary directory + * + * @throws IOException If the lock directory could not be created or is not writable + */ + public function __construct($name, $lockPath = null) + { + $lockPath = $lockPath ?: \sys_get_temp_dir(); + if (!\is_dir($lockPath)) { + $fs = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem(); + $fs->mkdir($lockPath); + } + if (!\is_writable($lockPath)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException(\sprintf('The directory "%s" is not writable.', $lockPath), 0, null, $lockPath); + } + $this->file = \sprintf('%s/sf.%s.%s.lock', $lockPath, \preg_replace('/[^a-z0-9\\._-]+/i', '-', $name), \hash('sha256', $name)); + } + /** + * Lock the resource. + * + * @param bool $blocking Wait until the lock is released + * + * @return bool Returns true if the lock was acquired, false otherwise + * + * @throws IOException If the lock file could not be created or opened + */ + public function lock($blocking = \false) + { + if ($this->handle) { + return \true; + } + $error = null; + // Silence error reporting + \set_error_handler(function ($errno, $msg) use(&$error) { + $error = $msg; + }); + if (!($this->handle = \fopen($this->file, 'r+') ?: \fopen($this->file, 'r'))) { + if ($this->handle = \fopen($this->file, 'x')) { + \chmod($this->file, 0666); + } elseif (!($this->handle = \fopen($this->file, 'r+') ?: \fopen($this->file, 'r'))) { + \usleep(100); + // Give some time for chmod() to complete + $this->handle = \fopen($this->file, 'r+') ?: \fopen($this->file, 'r'); + } + } + \restore_error_handler(); + if (!$this->handle) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException($error, 0, null, $this->file); + } + // On Windows, even if PHP doc says the contrary, LOCK_NB works, see + // https://bugs.php.net/54129 + if (!\flock($this->handle, \LOCK_EX | ($blocking ? 0 : \LOCK_NB))) { + \fclose($this->handle); + $this->handle = null; + return \false; + } + return \true; + } + /** + * Release the resource. + */ + public function release() + { + if ($this->handle) { + \flock($this->handle, \LOCK_UN | \LOCK_NB); + \fclose($this->handle); + $this->handle = null; + } + } +} diff --git a/vendor/symfony/filesystem/README.md b/vendor/symfony/filesystem/README.md index cb03d43c1..270f03dbc 100644 --- a/vendor/symfony/filesystem/README.md +++ b/vendor/symfony/filesystem/README.md @@ -1,13 +1,13 @@ -Filesystem Component -==================== - -The Filesystem component provides basic utilities for the filesystem. - -Resources ---------- - - * [Documentation](https://symfony.com/doc/current/components/filesystem.html) - * [Contributing](https://symfony.com/doc/current/contributing/index.html) - * [Report issues](https://github.com/symfony/symfony/issues) and - [send Pull Requests](https://github.com/symfony/symfony/pulls) - in the [main Symfony repository](https://github.com/symfony/symfony) +Filesystem Component +==================== + +The Filesystem component provides basic utilities for the filesystem. + +Resources +--------- + + * [Documentation](https://symfony.com/doc/current/components/filesystem.html) + * [Contributing](https://symfony.com/doc/current/contributing/index.html) + * [Report issues](https://github.com/symfony/symfony/issues) and + [send Pull Requests](https://github.com/symfony/symfony/pulls) + in the [main Symfony repository](https://github.com/symfony/symfony) diff --git a/vendor/symfony/filesystem/Tests/ExceptionTest.php b/vendor/symfony/filesystem/Tests/ExceptionTest.php index fd2b19328..9f3db28d3 100644 --- a/vendor/symfony/filesystem/Tests/ExceptionTest.php +++ b/vendor/symfony/filesystem/Tests/ExceptionTest.php @@ -1,42 +1,42 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException; -/** - * Test class for Filesystem. - */ -class ExceptionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testGetPath() - { - $e = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException('', 0, null, '/foo'); - $this->assertEquals('/foo', $e->getPath(), 'The pass should be returned.'); - } - public function testGeneratedMessage() - { - $e = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException(null, 0, null, '/foo'); - $this->assertEquals('/foo', $e->getPath()); - $this->assertEquals('File "/foo" could not be found.', $e->getMessage(), 'A message should be generated.'); - } - public function testGeneratedMessageWithoutPath() - { - $e = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException(); - $this->assertEquals('File could not be found.', $e->getMessage(), 'A message should be generated.'); - } - public function testCustomMessage() - { - $e = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException('bar', 0, null, '/foo'); - $this->assertEquals('bar', $e->getMessage(), 'A custom message should be possible still.'); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException; +/** + * Test class for Filesystem. + */ +class ExceptionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testGetPath() + { + $e = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException('', 0, null, '/foo'); + $this->assertEquals('/foo', $e->getPath(), 'The pass should be returned.'); + } + public function testGeneratedMessage() + { + $e = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException(null, 0, null, '/foo'); + $this->assertEquals('/foo', $e->getPath()); + $this->assertEquals('File "/foo" could not be found.', $e->getMessage(), 'A message should be generated.'); + } + public function testGeneratedMessageWithoutPath() + { + $e = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException(); + $this->assertEquals('File could not be found.', $e->getMessage(), 'A message should be generated.'); + } + public function testCustomMessage() + { + $e = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\FileNotFoundException('bar', 0, null, '/foo'); + $this->assertEquals('bar', $e->getMessage(), 'A custom message should be possible still.'); + } +} diff --git a/vendor/symfony/filesystem/Tests/FilesystemTest.php b/vendor/symfony/filesystem/Tests/FilesystemTest.php index c235c2d48..6648ecf31 100644 --- a/vendor/symfony/filesystem/Tests/FilesystemTest.php +++ b/vendor/symfony/filesystem/Tests/FilesystemTest.php @@ -1,1149 +1,1149 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests; - -/** - * Test class for Filesystem. - */ -class FilesystemTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests\FilesystemTestCase -{ - public function testCopyCreatesNewFile() - { - $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; - $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; - \file_put_contents($sourceFilePath, 'SOURCE FILE'); - $this->filesystem->copy($sourceFilePath, $targetFilePath); - $this->assertFileExists($targetFilePath); - $this->assertStringEqualsFile($targetFilePath, 'SOURCE FILE'); - } - public function testCopyFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; - $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; - $this->filesystem->copy($sourceFilePath, $targetFilePath); - } - public function testCopyUnreadableFileFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - // skip test on Windows; PHP can't easily set file as unreadable on Windows - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('This test cannot run on Windows.'); - } - if (!\getenv('USER') || 'root' === \getenv('USER')) { - $this->markTestSkipped('This test will fail if run under superuser'); - } - $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; - $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; - \file_put_contents($sourceFilePath, 'SOURCE FILE'); - // make sure target cannot be read - $this->filesystem->chmod($sourceFilePath, 0222); - $this->filesystem->copy($sourceFilePath, $targetFilePath); - } - public function testCopyOverridesExistingFileIfModified() - { - $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; - $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; - \file_put_contents($sourceFilePath, 'SOURCE FILE'); - \file_put_contents($targetFilePath, 'TARGET FILE'); - \touch($targetFilePath, \time() - 1000); - $this->filesystem->copy($sourceFilePath, $targetFilePath); - $this->assertFileExists($targetFilePath); - $this->assertStringEqualsFile($targetFilePath, 'SOURCE FILE'); - } - public function testCopyDoesNotOverrideExistingFileByDefault() - { - $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; - $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; - \file_put_contents($sourceFilePath, 'SOURCE FILE'); - \file_put_contents($targetFilePath, 'TARGET FILE'); - // make sure both files have the same modification time - $modificationTime = \time() - 1000; - \touch($sourceFilePath, $modificationTime); - \touch($targetFilePath, $modificationTime); - $this->filesystem->copy($sourceFilePath, $targetFilePath); - $this->assertFileExists($targetFilePath); - $this->assertStringEqualsFile($targetFilePath, 'TARGET FILE'); - } - public function testCopyOverridesExistingFileIfForced() - { - $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; - $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; - \file_put_contents($sourceFilePath, 'SOURCE FILE'); - \file_put_contents($targetFilePath, 'TARGET FILE'); - // make sure both files have the same modification time - $modificationTime = \time() - 1000; - \touch($sourceFilePath, $modificationTime); - \touch($targetFilePath, $modificationTime); - $this->filesystem->copy($sourceFilePath, $targetFilePath, \true); - $this->assertFileExists($targetFilePath); - $this->assertStringEqualsFile($targetFilePath, 'SOURCE FILE'); - } - public function testCopyWithOverrideWithReadOnlyTargetFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - // skip test on Windows; PHP can't easily set file as unwritable on Windows - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('This test cannot run on Windows.'); - } - if (!\getenv('USER') || 'root' === \getenv('USER')) { - $this->markTestSkipped('This test will fail if run under superuser'); - } - $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; - $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; - \file_put_contents($sourceFilePath, 'SOURCE FILE'); - \file_put_contents($targetFilePath, 'TARGET FILE'); - // make sure both files have the same modification time - $modificationTime = \time() - 1000; - \touch($sourceFilePath, $modificationTime); - \touch($targetFilePath, $modificationTime); - // make sure target is read-only - $this->filesystem->chmod($targetFilePath, 0444); - $this->filesystem->copy($sourceFilePath, $targetFilePath, \true); - } - public function testCopyCreatesTargetDirectoryIfItDoesNotExist() - { - $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; - $targetFileDirectory = $this->workspace . \DIRECTORY_SEPARATOR . 'directory'; - $targetFilePath = $targetFileDirectory . \DIRECTORY_SEPARATOR . 'copy_target_file'; - \file_put_contents($sourceFilePath, 'SOURCE FILE'); - $this->filesystem->copy($sourceFilePath, $targetFilePath); - $this->assertDirectoryExists($targetFileDirectory); - $this->assertFileExists($targetFilePath); - $this->assertStringEqualsFile($targetFilePath, 'SOURCE FILE'); - } - /** - * @group network - */ - public function testCopyForOriginUrlsAndExistingLocalFileDefaultsToCopy() - { - if (!\in_array('https', \stream_get_wrappers())) { - $this->markTestSkipped('"https" stream wrapper is not enabled.'); - } - $sourceFilePath = 'https://symfony.com/images/common/logo/logo_symfony_header.png'; - $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; - \file_put_contents($targetFilePath, 'TARGET FILE'); - $this->filesystem->copy($sourceFilePath, $targetFilePath, \false); - $this->assertFileExists($targetFilePath); - $this->assertEquals(\file_get_contents($sourceFilePath), \file_get_contents($targetFilePath)); - } - public function testMkdirCreatesDirectoriesRecursively() - { - $directory = $this->workspace . \DIRECTORY_SEPARATOR . 'directory' . \DIRECTORY_SEPARATOR . 'sub_directory'; - $this->filesystem->mkdir($directory); - $this->assertDirectoryExists($directory); - } - public function testMkdirCreatesDirectoriesFromArray() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR; - $directories = [$basePath . '1', $basePath . '2', $basePath . '3']; - $this->filesystem->mkdir($directories); - $this->assertDirectoryExists($basePath . '1'); - $this->assertDirectoryExists($basePath . '2'); - $this->assertDirectoryExists($basePath . '3'); - } - public function testMkdirCreatesDirectoriesFromTraversableObject() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR; - $directories = new \ArrayObject([$basePath . '1', $basePath . '2', $basePath . '3']); - $this->filesystem->mkdir($directories); - $this->assertDirectoryExists($basePath . '1'); - $this->assertDirectoryExists($basePath . '2'); - $this->assertDirectoryExists($basePath . '3'); - } - public function testMkdirCreatesDirectoriesFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $basePath = $this->workspace . \DIRECTORY_SEPARATOR; - $dir = $basePath . '2'; - \file_put_contents($dir, ''); - $this->filesystem->mkdir($dir); - } - public function testTouchCreatesEmptyFile() - { - $file = $this->workspace . \DIRECTORY_SEPARATOR . '1'; - $this->filesystem->touch($file); - $this->assertFileExists($file); - } - public function testTouchFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $file = $this->workspace . \DIRECTORY_SEPARATOR . '1' . \DIRECTORY_SEPARATOR . '2'; - $this->filesystem->touch($file); - } - public function testTouchCreatesEmptyFilesFromArray() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR; - $files = [$basePath . '1', $basePath . '2', $basePath . '3']; - $this->filesystem->touch($files); - $this->assertFileExists($basePath . '1'); - $this->assertFileExists($basePath . '2'); - $this->assertFileExists($basePath . '3'); - } - public function testTouchCreatesEmptyFilesFromTraversableObject() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR; - $files = new \ArrayObject([$basePath . '1', $basePath . '2', $basePath . '3']); - $this->filesystem->touch($files); - $this->assertFileExists($basePath . '1'); - $this->assertFileExists($basePath . '2'); - $this->assertFileExists($basePath . '3'); - } - public function testRemoveCleansFilesAndDirectoriesIteratively() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR . 'directory' . \DIRECTORY_SEPARATOR; - \mkdir($basePath); - \mkdir($basePath . 'dir'); - \touch($basePath . 'file'); - $this->filesystem->remove($basePath); - $this->assertFileNotExists($basePath); - } - public function testRemoveCleansArrayOfFilesAndDirectories() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR; - \mkdir($basePath . 'dir'); - \touch($basePath . 'file'); - $files = [$basePath . 'dir', $basePath . 'file']; - $this->filesystem->remove($files); - $this->assertFileNotExists($basePath . 'dir'); - $this->assertFileNotExists($basePath . 'file'); - } - public function testRemoveCleansTraversableObjectOfFilesAndDirectories() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR; - \mkdir($basePath . 'dir'); - \touch($basePath . 'file'); - $files = new \ArrayObject([$basePath . 'dir', $basePath . 'file']); - $this->filesystem->remove($files); - $this->assertFileNotExists($basePath . 'dir'); - $this->assertFileNotExists($basePath . 'file'); - } - public function testRemoveIgnoresNonExistingFiles() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR; - \mkdir($basePath . 'dir'); - $files = [$basePath . 'dir', $basePath . 'file']; - $this->filesystem->remove($files); - $this->assertFileNotExists($basePath . 'dir'); - } - public function testRemoveCleansInvalidLinks() - { - $this->markAsSkippedIfSymlinkIsMissing(); - $basePath = $this->workspace . \DIRECTORY_SEPARATOR . 'directory' . \DIRECTORY_SEPARATOR; - \mkdir($basePath); - \mkdir($basePath . 'dir'); - // create symlink to nonexistent file - @\symlink($basePath . 'file', $basePath . 'file-link'); - // create symlink to dir using trailing forward slash - $this->filesystem->symlink($basePath . 'dir/', $basePath . 'dir-link'); - $this->assertDirectoryExists($basePath . 'dir-link'); - // create symlink to nonexistent dir - \rmdir($basePath . 'dir'); - $this->assertFalse('\\' === \DIRECTORY_SEPARATOR ? @\readlink($basePath . 'dir-link') : \is_dir($basePath . 'dir-link')); - $this->filesystem->remove($basePath); - $this->assertFileNotExists($basePath); - } - public function testFilesExists() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR . 'directory' . \DIRECTORY_SEPARATOR; - \mkdir($basePath); - \touch($basePath . 'file1'); - \mkdir($basePath . 'folder'); - $this->assertTrue($this->filesystem->exists($basePath . 'file1')); - $this->assertTrue($this->filesystem->exists($basePath . 'folder')); - } - public function testFilesExistsFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - if ('\\' !== \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('Long file names are an issue on Windows'); - } - $basePath = $this->workspace . '\\directory\\'; - $maxPathLength = \PHP_MAXPATHLEN - 2; - $oldPath = \getcwd(); - \mkdir($basePath); - \chdir($basePath); - $file = \str_repeat('T', $maxPathLength - \strlen($basePath) + 1); - $path = $basePath . $file; - \exec('TYPE NUL >>' . $file); - // equivalent of touch, we can not use the php touch() here because it suffers from the same limitation - $this->longPathNamesWindows[] = $path; - // save this so we can clean up later - \chdir($oldPath); - $this->filesystem->exists($path); - } - public function testFilesExistsTraversableObjectOfFilesAndDirectories() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR; - \mkdir($basePath . 'dir'); - \touch($basePath . 'file'); - $files = new \ArrayObject([$basePath . 'dir', $basePath . 'file']); - $this->assertTrue($this->filesystem->exists($files)); - } - public function testFilesNotExistsTraversableObjectOfFilesAndDirectories() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR; - \mkdir($basePath . 'dir'); - \touch($basePath . 'file'); - \touch($basePath . 'file2'); - $files = new \ArrayObject([$basePath . 'dir', $basePath . 'file', $basePath . 'file2']); - \unlink($basePath . 'file'); - $this->assertFalse($this->filesystem->exists($files)); - } - public function testInvalidFileNotExists() - { - $basePath = $this->workspace . \DIRECTORY_SEPARATOR . 'directory' . \DIRECTORY_SEPARATOR; - $this->assertFalse($this->filesystem->exists($basePath . \time())); - } - public function testChmodChangesFileMode() - { - $this->markAsSkippedIfChmodIsMissing(); - $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; - \mkdir($dir); - $file = $dir . \DIRECTORY_SEPARATOR . 'file'; - \touch($file); - $this->filesystem->chmod($file, 0400); - $this->filesystem->chmod($dir, 0753); - $this->assertFilePermissions(753, $dir); - $this->assertFilePermissions(400, $file); - } - public function testChmodWithWrongModLeavesPreviousPermissionsUntouched() - { - $this->markAsSkippedIfChmodIsMissing(); - if (\defined('HHVM_VERSION')) { - $this->markTestSkipped('chmod() changes permissions even when passing invalid modes on HHVM'); - } - $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - \touch($dir); - $permissions = \fileperms($dir); - $this->filesystem->chmod($dir, 'Wrongmode'); - $this->assertSame($permissions, \fileperms($dir)); - } - public function testChmodRecursive() - { - $this->markAsSkippedIfChmodIsMissing(); - $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; - \mkdir($dir); - $file = $dir . \DIRECTORY_SEPARATOR . 'file'; - \touch($file); - $this->filesystem->chmod($file, 0400, 00, \true); - $this->filesystem->chmod($dir, 0753, 00, \true); - $this->assertFilePermissions(753, $dir); - $this->assertFilePermissions(753, $file); - } - public function testChmodAppliesUmask() - { - $this->markAsSkippedIfChmodIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - \touch($file); - $this->filesystem->chmod($file, 0770, 022); - $this->assertFilePermissions(750, $file); - } - public function testChmodChangesModeOfArrayOfFiles() - { - $this->markAsSkippedIfChmodIsMissing(); - $directory = $this->workspace . \DIRECTORY_SEPARATOR . 'directory'; - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $files = [$directory, $file]; - \mkdir($directory); - \touch($file); - $this->filesystem->chmod($files, 0753); - $this->assertFilePermissions(753, $file); - $this->assertFilePermissions(753, $directory); - } - public function testChmodChangesModeOfTraversableFileObject() - { - $this->markAsSkippedIfChmodIsMissing(); - $directory = $this->workspace . \DIRECTORY_SEPARATOR . 'directory'; - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $files = new \ArrayObject([$directory, $file]); - \mkdir($directory); - \touch($file); - $this->filesystem->chmod($files, 0753); - $this->assertFilePermissions(753, $file); - $this->assertFilePermissions(753, $directory); - } - public function testChmodChangesZeroModeOnSubdirectoriesOnRecursive() - { - $this->markAsSkippedIfChmodIsMissing(); - $directory = $this->workspace . \DIRECTORY_SEPARATOR . 'directory'; - $subdirectory = $directory . \DIRECTORY_SEPARATOR . 'subdirectory'; - \mkdir($directory); - \mkdir($subdirectory); - \chmod($subdirectory, 00); - $this->filesystem->chmod($directory, 0753, 00, \true); - $this->assertFilePermissions(753, $subdirectory); - } - public function testChown() - { - $this->markAsSkippedIfPosixIsMissing(); - $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; - \mkdir($dir); - $owner = $this->getFileOwner($dir); - $this->filesystem->chown($dir, $owner); - $this->assertSame($owner, $this->getFileOwner($dir)); - } - public function testChownRecursive() - { - $this->markAsSkippedIfPosixIsMissing(); - $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; - \mkdir($dir); - $file = $dir . \DIRECTORY_SEPARATOR . 'file'; - \touch($file); - $owner = $this->getFileOwner($dir); - $this->filesystem->chown($dir, $owner, \true); - $this->assertSame($owner, $this->getFileOwner($file)); - } - public function testChownSymlink() - { - $this->markAsSkippedIfSymlinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - $this->filesystem->symlink($file, $link); - $owner = $this->getFileOwner($link); - $this->filesystem->chown($link, $owner); - $this->assertSame($owner, $this->getFileOwner($link)); - } - public function testChownLink() - { - $this->markAsSkippedIfLinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - $this->filesystem->hardlink($file, $link); - $owner = $this->getFileOwner($link); - $this->filesystem->chown($link, $owner); - $this->assertSame($owner, $this->getFileOwner($link)); - } - public function testChownSymlinkFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $this->markAsSkippedIfSymlinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - $this->filesystem->symlink($file, $link); - $this->filesystem->chown($link, 'user' . \time() . \mt_rand(1000, 9999)); - } - public function testChownLinkFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $this->markAsSkippedIfLinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - $this->filesystem->hardlink($file, $link); - $this->filesystem->chown($link, 'user' . \time() . \mt_rand(1000, 9999)); - } - public function testChownFail() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $this->markAsSkippedIfPosixIsMissing(); - $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; - \mkdir($dir); - $this->filesystem->chown($dir, 'user' . \time() . \mt_rand(1000, 9999)); - } - public function testChgrp() - { - $this->markAsSkippedIfPosixIsMissing(); - $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; - \mkdir($dir); - $group = $this->getFileGroup($dir); - $this->filesystem->chgrp($dir, $group); - $this->assertSame($group, $this->getFileGroup($dir)); - } - public function testChgrpRecursive() - { - $this->markAsSkippedIfPosixIsMissing(); - $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; - \mkdir($dir); - $file = $dir . \DIRECTORY_SEPARATOR . 'file'; - \touch($file); - $group = $this->getFileGroup($dir); - $this->filesystem->chgrp($dir, $group, \true); - $this->assertSame($group, $this->getFileGroup($file)); - } - public function testChgrpSymlink() - { - $this->markAsSkippedIfSymlinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - $this->filesystem->symlink($file, $link); - $group = $this->getFileGroup($link); - $this->filesystem->chgrp($link, $group); - $this->assertSame($group, $this->getFileGroup($link)); - } - public function testChgrpLink() - { - $this->markAsSkippedIfLinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - $this->filesystem->hardlink($file, $link); - $group = $this->getFileGroup($link); - $this->filesystem->chgrp($link, $group); - $this->assertSame($group, $this->getFileGroup($link)); - } - public function testChgrpSymlinkFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $this->markAsSkippedIfSymlinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - $this->filesystem->symlink($file, $link); - $this->filesystem->chgrp($link, 'user' . \time() . \mt_rand(1000, 9999)); - } - public function testChgrpLinkFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $this->markAsSkippedIfLinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - $this->filesystem->hardlink($file, $link); - $this->filesystem->chgrp($link, 'user' . \time() . \mt_rand(1000, 9999)); - } - public function testChgrpFail() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $this->markAsSkippedIfPosixIsMissing(); - $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; - \mkdir($dir); - $this->filesystem->chgrp($dir, 'user' . \time() . \mt_rand(1000, 9999)); - } - public function testRename() - { - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $newPath = $this->workspace . \DIRECTORY_SEPARATOR . 'new_file'; - \touch($file); - $this->filesystem->rename($file, $newPath); - $this->assertFileNotExists($file); - $this->assertFileExists($newPath); - } - public function testRenameThrowsExceptionIfTargetAlreadyExists() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $newPath = $this->workspace . \DIRECTORY_SEPARATOR . 'new_file'; - \touch($file); - \touch($newPath); - $this->filesystem->rename($file, $newPath); - } - public function testRenameOverwritesTheTargetIfItAlreadyExists() - { - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $newPath = $this->workspace . \DIRECTORY_SEPARATOR . 'new_file'; - \touch($file); - \touch($newPath); - $this->filesystem->rename($file, $newPath, \true); - $this->assertFileNotExists($file); - $this->assertFileExists($newPath); - } - public function testRenameThrowsExceptionOnError() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $file = $this->workspace . \DIRECTORY_SEPARATOR . \uniqid('fs_test_', \true); - $newPath = $this->workspace . \DIRECTORY_SEPARATOR . 'new_file'; - $this->filesystem->rename($file, $newPath); - } - public function testSymlink() - { - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('Windows does not support creating "broken" symlinks'); - } - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - // $file does not exist right now: creating "broken" links is a wanted feature - $this->filesystem->symlink($file, $link); - $this->assertTrue(\is_link($link)); - // Create the linked file AFTER creating the link - \touch($file); - $this->assertEquals($file, \readlink($link)); - } - /** - * @depends testSymlink - */ - public function testRemoveSymlink() - { - $this->markAsSkippedIfSymlinkIsMissing(); - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - $this->filesystem->remove($link); - $this->assertFalse(\is_link($link)); - $this->assertFalse(\is_file($link)); - $this->assertDirectoryNotExists($link); - } - public function testSymlinkIsOverwrittenIfPointsToDifferentTarget() - { - $this->markAsSkippedIfSymlinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - \symlink($this->workspace, $link); - $this->filesystem->symlink($file, $link); - $this->assertTrue(\is_link($link)); - $this->assertEquals($file, \readlink($link)); - } - public function testSymlinkIsNotOverwrittenIfAlreadyCreated() - { - $this->markAsSkippedIfSymlinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - \symlink($file, $link); - $this->filesystem->symlink($file, $link); - $this->assertTrue(\is_link($link)); - $this->assertEquals($file, \readlink($link)); - } - public function testSymlinkCreatesTargetDirectoryIfItDoesNotExist() - { - $this->markAsSkippedIfSymlinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link1 = $this->workspace . \DIRECTORY_SEPARATOR . 'dir' . \DIRECTORY_SEPARATOR . 'link'; - $link2 = $this->workspace . \DIRECTORY_SEPARATOR . 'dir' . \DIRECTORY_SEPARATOR . 'subdir' . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - $this->filesystem->symlink($file, $link1); - $this->filesystem->symlink($file, $link2); - $this->assertTrue(\is_link($link1)); - $this->assertEquals($file, \readlink($link1)); - $this->assertTrue(\is_link($link2)); - $this->assertEquals($file, \readlink($link2)); - } - public function testLink() - { - $this->markAsSkippedIfLinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - $this->filesystem->hardlink($file, $link); - $this->assertTrue(\is_file($link)); - $this->assertEquals(\fileinode($file), \fileinode($link)); - } - /** - * @depends testLink - */ - public function testRemoveLink() - { - $this->markAsSkippedIfLinkIsMissing(); - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - $this->filesystem->remove($link); - $this->assertTrue(!\is_file($link)); - } - public function testLinkIsOverwrittenIfPointsToDifferentTarget() - { - $this->markAsSkippedIfLinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $file2 = $this->workspace . \DIRECTORY_SEPARATOR . 'file2'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - \touch($file2); - \link($file2, $link); - $this->filesystem->hardlink($file, $link); - $this->assertTrue(\is_file($link)); - $this->assertEquals(\fileinode($file), \fileinode($link)); - } - public function testLinkIsNotOverwrittenIfAlreadyCreated() - { - $this->markAsSkippedIfLinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - \link($file, $link); - $this->filesystem->hardlink($file, $link); - $this->assertTrue(\is_file($link)); - $this->assertEquals(\fileinode($file), \fileinode($link)); - } - public function testLinkWithSeveralTargets() - { - $this->markAsSkippedIfLinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link1 = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - $link2 = $this->workspace . \DIRECTORY_SEPARATOR . 'link2'; - \touch($file); - $this->filesystem->hardlink($file, [$link1, $link2]); - $this->assertTrue(\is_file($link1)); - $this->assertEquals(\fileinode($file), \fileinode($link1)); - $this->assertTrue(\is_file($link2)); - $this->assertEquals(\fileinode($file), \fileinode($link2)); - } - public function testLinkWithSameTarget() - { - $this->markAsSkippedIfLinkIsMissing(); - $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; - $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; - \touch($file); - // practically same as testLinkIsNotOverwrittenIfAlreadyCreated - $this->filesystem->hardlink($file, [$link, $link]); - $this->assertTrue(\is_file($link)); - $this->assertEquals(\fileinode($file), \fileinode($link)); - } - public function testReadRelativeLink() - { - $this->markAsSkippedIfSymlinkIsMissing(); - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('Relative symbolic links are not supported on Windows'); - } - $file = $this->workspace . '/file'; - $link1 = $this->workspace . '/dir/link'; - $link2 = $this->workspace . '/dir/link2'; - \touch($file); - $this->filesystem->symlink('../file', $link1); - $this->filesystem->symlink('link', $link2); - $this->assertEquals($this->normalize('../file'), $this->filesystem->readlink($link1)); - $this->assertEquals('link', $this->filesystem->readlink($link2)); - $this->assertEquals($file, $this->filesystem->readlink($link1, \true)); - $this->assertEquals($file, $this->filesystem->readlink($link2, \true)); - $this->assertEquals($file, $this->filesystem->readlink($file, \true)); - } - public function testReadAbsoluteLink() - { - $this->markAsSkippedIfSymlinkIsMissing(); - $file = $this->normalize($this->workspace . '/file'); - $link1 = $this->normalize($this->workspace . '/dir/link'); - $link2 = $this->normalize($this->workspace . '/dir/link2'); - \touch($file); - $this->filesystem->symlink($file, $link1); - $this->filesystem->symlink($link1, $link2); - $this->assertEquals($file, $this->filesystem->readlink($link1)); - $this->assertEquals($link1, $this->filesystem->readlink($link2)); - $this->assertEquals($file, $this->filesystem->readlink($link1, \true)); - $this->assertEquals($file, $this->filesystem->readlink($link2, \true)); - $this->assertEquals($file, $this->filesystem->readlink($file, \true)); - } - public function testReadBrokenLink() - { - $this->markAsSkippedIfSymlinkIsMissing(); - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('Windows does not support creating "broken" symlinks'); - } - $file = $this->workspace . '/file'; - $link = $this->workspace . '/link'; - $this->filesystem->symlink($file, $link); - $this->assertEquals($file, $this->filesystem->readlink($link)); - $this->assertNull($this->filesystem->readlink($link, \true)); - \touch($file); - $this->assertEquals($file, $this->filesystem->readlink($link, \true)); - } - public function testReadLinkDefaultPathDoesNotExist() - { - $this->assertNull($this->filesystem->readlink($this->normalize($this->workspace . '/invalid'))); - } - public function testReadLinkDefaultPathNotLink() - { - $file = $this->normalize($this->workspace . '/file'); - \touch($file); - $this->assertNull($this->filesystem->readlink($file)); - } - public function testReadLinkCanonicalizePath() - { - $this->markAsSkippedIfSymlinkIsMissing(); - $file = $this->normalize($this->workspace . '/file'); - \mkdir($this->normalize($this->workspace . '/dir')); - \touch($file); - $this->assertEquals($file, $this->filesystem->readlink($this->normalize($this->workspace . '/dir/../file'), \true)); - } - public function testReadLinkCanonicalizedPathDoesNotExist() - { - $this->assertNull($this->filesystem->readlink($this->normalize($this->workspace . 'invalid'), \true)); - } - /** - * @dataProvider providePathsForMakePathRelative - */ - public function testMakePathRelative($endPath, $startPath, $expectedPath) - { - $path = $this->filesystem->makePathRelative($endPath, $startPath); - $this->assertEquals($expectedPath, $path); - } - public function providePathsForMakePathRelative() - { - $paths = [['/var/lib/symfony/src/Symfony/', '/var/lib/symfony/src/Symfony/Component', '../'], ['/var/lib/symfony/src/Symfony/', '/var/lib/symfony/src/Symfony/Component/', '../'], ['/var/lib/symfony/src/Symfony', '/var/lib/symfony/src/Symfony/Component', '../'], ['/var/lib/symfony/src/Symfony', '/var/lib/symfony/src/Symfony/Component/', '../'], ['/usr/lib/symfony/', '/var/lib/symfony/src/Symfony/Component', '../../../../../../usr/lib/symfony/'], ['/var/lib/symfony/src/Symfony/', '/var/lib/symfony/', 'src/Symfony/'], ['/aa/bb', '/aa/bb', './'], ['/aa/bb', '/aa/bb/', './'], ['/aa/bb/', '/aa/bb', './'], ['/aa/bb/', '/aa/bb/', './'], ['/aa/bb/cc', '/aa/bb/cc/dd', '../'], ['/aa/bb/cc', '/aa/bb/cc/dd/', '../'], ['/aa/bb/cc/', '/aa/bb/cc/dd', '../'], ['/aa/bb/cc/', '/aa/bb/cc/dd/', '../'], ['/aa/bb/cc', '/aa', 'bb/cc/'], ['/aa/bb/cc', '/aa/', 'bb/cc/'], ['/aa/bb/cc/', '/aa', 'bb/cc/'], ['/aa/bb/cc/', '/aa/', 'bb/cc/'], ['/a/aab/bb', '/a/aa', '../aab/bb/'], ['/a/aab/bb', '/a/aa/', '../aab/bb/'], ['/a/aab/bb/', '/a/aa', '../aab/bb/'], ['/a/aab/bb/', '/a/aa/', '../aab/bb/'], ['/a/aab/bb/', '/', 'a/aab/bb/'], ['/a/aab/bb/', '/b/aab', '../../a/aab/bb/'], ['/aab/bb', '/aa', '../aab/bb/'], ['/aab', '/aa', '../aab/'], ['/aa/bb/cc', '/aa/dd/..', 'bb/cc/'], ['/aa/../bb/cc', '/aa/dd/..', '../bb/cc/'], ['/aa/bb/../../cc', '/aa/../dd/..', 'cc/'], ['/../aa/bb/cc', '/aa/dd/..', 'bb/cc/'], ['/../../aa/../bb/cc', '/aa/dd/..', '../bb/cc/'], ['C:/aa/bb/cc', 'C:/aa/dd/..', 'bb/cc/'], ['c:/aa/../bb/cc', 'c:/aa/dd/..', '../bb/cc/'], ['C:/aa/bb/../../cc', 'C:/aa/../dd/..', 'cc/'], ['C:/../aa/bb/cc', 'C:/aa/dd/..', 'bb/cc/'], ['C:/../../aa/../bb/cc', 'C:/aa/dd/..', '../bb/cc/']]; - if ('\\' === \DIRECTORY_SEPARATOR) { - $paths[] = ['c:\\var\\lib/symfony/src/Symfony/', 'c:/var/lib/symfony/', 'src/Symfony/']; - } - return $paths; - } - /** - * @group legacy - * @dataProvider provideLegacyPathsForMakePathRelativeWithRelativePaths - * @expectedDeprecation Support for passing relative paths to Symfony\Component\Filesystem\Filesystem::makePathRelative() is deprecated since Symfony 3.4 and will be removed in 4.0. - */ - public function testMakePathRelativeWithRelativePaths($endPath, $startPath, $expectedPath) - { - $path = $this->filesystem->makePathRelative($endPath, $startPath); - $this->assertEquals($expectedPath, $path); - } - public function provideLegacyPathsForMakePathRelativeWithRelativePaths() - { - return [['usr/lib/symfony/', 'var/lib/symfony/src/Symfony/Component', '../../../../../../usr/lib/symfony/'], ['aa/bb', 'aa/cc', '../bb/'], ['aa/cc', 'bb/cc', '../../aa/cc/'], ['aa/bb', 'aa/./cc', '../bb/'], ['aa/./bb', 'aa/cc', '../bb/'], ['aa/./bb', 'aa/./cc', '../bb/'], ['../../', '../../', './'], ['../aa/bb/', 'aa/bb/', '../../../aa/bb/'], ['../../../', '../../', '../'], ['', '', './'], ['', 'aa/', '../'], ['aa/', '', 'aa/']]; - } - public function testMirrorCopiesFilesAndDirectoriesRecursively() - { - $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; - $directory = $sourcePath . 'directory' . \DIRECTORY_SEPARATOR; - $file1 = $directory . 'file1'; - $file2 = $sourcePath . 'file2'; - \mkdir($sourcePath); - \mkdir($directory); - \file_put_contents($file1, 'FILE1'); - \file_put_contents($file2, 'FILE2'); - $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; - $this->filesystem->mirror($sourcePath, $targetPath); - $this->assertDirectoryExists($targetPath); - $this->assertDirectoryExists($targetPath . 'directory'); - $this->assertFileEquals($file1, $targetPath . 'directory' . \DIRECTORY_SEPARATOR . 'file1'); - $this->assertFileEquals($file2, $targetPath . 'file2'); - $this->filesystem->remove($file1); - $this->filesystem->mirror($sourcePath, $targetPath, null, ['delete' => \false]); - $this->assertTrue($this->filesystem->exists($targetPath . 'directory' . \DIRECTORY_SEPARATOR . 'file1')); - $this->filesystem->mirror($sourcePath, $targetPath, null, ['delete' => \true]); - $this->assertFalse($this->filesystem->exists($targetPath . 'directory' . \DIRECTORY_SEPARATOR . 'file1')); - \file_put_contents($file1, 'FILE1'); - $this->filesystem->mirror($sourcePath, $targetPath, null, ['delete' => \true]); - $this->assertTrue($this->filesystem->exists($targetPath . 'directory' . \DIRECTORY_SEPARATOR . 'file1')); - $this->filesystem->remove($directory); - $this->filesystem->mirror($sourcePath, $targetPath, null, ['delete' => \true]); - $this->assertFalse($this->filesystem->exists($targetPath . 'directory')); - $this->assertFalse($this->filesystem->exists($targetPath . 'directory' . \DIRECTORY_SEPARATOR . 'file1')); - } - public function testMirrorCreatesEmptyDirectory() - { - $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; - \mkdir($sourcePath); - $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; - $this->filesystem->mirror($sourcePath, $targetPath); - $this->assertDirectoryExists($targetPath); - $this->filesystem->remove($sourcePath); - } - public function testMirrorCopiesLinks() - { - $this->markAsSkippedIfSymlinkIsMissing(); - $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; - \mkdir($sourcePath); - \file_put_contents($sourcePath . 'file1', 'FILE1'); - \symlink($sourcePath . 'file1', $sourcePath . 'link1'); - $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; - $this->filesystem->mirror($sourcePath, $targetPath); - $this->assertDirectoryExists($targetPath); - $this->assertFileEquals($sourcePath . 'file1', $targetPath . 'link1'); - $this->assertTrue(\is_link($targetPath . \DIRECTORY_SEPARATOR . 'link1')); - } - public function testMirrorCopiesLinkedDirectoryContents() - { - $this->markAsSkippedIfSymlinkIsMissing(\true); - $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; - \mkdir($sourcePath . 'nested/', 0777, \true); - \file_put_contents($sourcePath . '/nested/file1.txt', 'FILE1'); - // Note: We symlink directory, not file - \symlink($sourcePath . 'nested', $sourcePath . 'link1'); - $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; - $this->filesystem->mirror($sourcePath, $targetPath); - $this->assertDirectoryExists($targetPath); - $this->assertFileEquals($sourcePath . '/nested/file1.txt', $targetPath . 'link1/file1.txt'); - $this->assertTrue(\is_link($targetPath . \DIRECTORY_SEPARATOR . 'link1')); - } - public function testMirrorCopiesRelativeLinkedContents() - { - $this->markAsSkippedIfSymlinkIsMissing(\true); - $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; - $oldPath = \getcwd(); - \mkdir($sourcePath . 'nested/', 0777, \true); - \file_put_contents($sourcePath . '/nested/file1.txt', 'FILE1'); - // Note: Create relative symlink - \chdir($sourcePath); - \symlink('nested', 'link1'); - \chdir($oldPath); - $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; - $this->filesystem->mirror($sourcePath, $targetPath); - $this->assertDirectoryExists($targetPath); - $this->assertFileEquals($sourcePath . '/nested/file1.txt', $targetPath . 'link1/file1.txt'); - $this->assertTrue(\is_link($targetPath . \DIRECTORY_SEPARATOR . 'link1')); - $this->assertEquals('\\' === \DIRECTORY_SEPARATOR ? \realpath($sourcePath . '\\nested') : 'nested', \readlink($targetPath . \DIRECTORY_SEPARATOR . 'link1')); - } - public function testMirrorContentsWithSameNameAsSourceOrTargetWithoutDeleteOption() - { - $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; - \mkdir($sourcePath); - \touch($sourcePath . 'source'); - \touch($sourcePath . 'target'); - $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; - $oldPath = \getcwd(); - \chdir($this->workspace); - $this->filesystem->mirror('source', $targetPath); - \chdir($oldPath); - $this->assertDirectoryExists($targetPath); - $this->assertFileExists($targetPath . 'source'); - $this->assertFileExists($targetPath . 'target'); - } - public function testMirrorContentsWithSameNameAsSourceOrTargetWithDeleteOption() - { - $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; - \mkdir($sourcePath); - \touch($sourcePath . 'source'); - $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; - \mkdir($targetPath); - \touch($targetPath . 'source'); - \touch($targetPath . 'target'); - $oldPath = \getcwd(); - \chdir($this->workspace); - $this->filesystem->mirror('source', 'target', null, ['delete' => \true]); - \chdir($oldPath); - $this->assertDirectoryExists($targetPath); - $this->assertFileExists($targetPath . 'source'); - $this->assertFileNotExists($targetPath . 'target'); - } - public function testMirrorFromSubdirectoryInToParentDirectory() - { - $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR; - $sourcePath = $targetPath . 'bar' . \DIRECTORY_SEPARATOR; - $file1 = $sourcePath . 'file1'; - $file2 = $sourcePath . 'file2'; - $this->filesystem->mkdir($sourcePath); - \file_put_contents($file1, 'FILE1'); - \file_put_contents($file2, 'FILE2'); - $this->filesystem->mirror($sourcePath, $targetPath); - $this->assertFileEquals($file1, $targetPath . 'file1'); - } - /** - * @dataProvider providePathsForIsAbsolutePath - */ - public function testIsAbsolutePath($path, $expectedResult) - { - $result = $this->filesystem->isAbsolutePath($path); - $this->assertEquals($expectedResult, $result); - } - public function providePathsForIsAbsolutePath() - { - return [['/var/lib', \true], ['_PhpScoper5ea00cc67502b\\c:\\var\\lib', \true], ['_PhpScoper5ea00cc67502b\\var\\lib', \true], ['var/lib', \false], ['../var/lib', \false], ['', \false], [null, \false]]; - } - public function testTempnam() - { - $dirname = $this->workspace; - $filename = $this->filesystem->tempnam($dirname, 'foo'); - $this->assertFileExists($filename); - } - public function testTempnamWithFileScheme() - { - $scheme = 'file://'; - $dirname = $scheme . $this->workspace; - $filename = $this->filesystem->tempnam($dirname, 'foo'); - $this->assertStringStartsWith($scheme, $filename); - $this->assertFileExists($filename); - } - public function testTempnamWithMockScheme() - { - \stream_wrapper_register('mock', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Tests\\Fixtures\\MockStream\\MockStream'); - $scheme = 'mock://'; - $dirname = $scheme . $this->workspace; - $filename = $this->filesystem->tempnam($dirname, 'foo'); - $this->assertStringStartsWith($scheme, $filename); - $this->assertFileExists($filename); - } - public function testTempnamWithZlibSchemeFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $scheme = 'compress.zlib://'; - $dirname = $scheme . $this->workspace; - // The compress.zlib:// stream does not support mode x: creates the file, errors "failed to open stream: operation failed" and returns false - $this->filesystem->tempnam($dirname, 'bar'); - } - public function testTempnamWithPHPTempSchemeFails() - { - $scheme = 'php://temp'; - $dirname = $scheme; - $filename = $this->filesystem->tempnam($dirname, 'bar'); - $this->assertStringStartsWith($scheme, $filename); - // The php://temp stream deletes the file after close - $this->assertFileNotExists($filename); - } - public function testTempnamWithPharSchemeFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - // Skip test if Phar disabled phar.readonly must be 0 in php.ini - if (!\Phar::canWrite()) { - $this->markTestSkipped('This test cannot run when phar.readonly is 1.'); - } - $scheme = 'phar://'; - $dirname = $scheme . $this->workspace; - $pharname = 'foo.phar'; - new \Phar($this->workspace . '/' . $pharname, 0, $pharname); - // The phar:// stream does not support mode x: fails to create file, errors "failed to open stream: phar error: "$filename" is not a file in phar "$pharname"" and returns false - $this->filesystem->tempnam($dirname, $pharname . '/bar'); - } - public function testTempnamWithHTTPSchemeFails() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $scheme = 'http://'; - $dirname = $scheme . $this->workspace; - // The http:// scheme is read-only - $this->filesystem->tempnam($dirname, 'bar'); - } - public function testTempnamOnUnwritableFallsBackToSysTmp() - { - $scheme = 'file://'; - $dirname = $scheme . $this->workspace . \DIRECTORY_SEPARATOR . 'does_not_exist'; - $filename = $this->filesystem->tempnam($dirname, 'bar'); - $realTempDir = \realpath(\sys_get_temp_dir()); - $this->assertStringStartsWith(\rtrim($scheme . $realTempDir, \DIRECTORY_SEPARATOR), $filename); - $this->assertFileExists($filename); - // Tear down - @\unlink($filename); - } - public function testDumpFile() - { - $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; - // skip mode check on Windows - if ('\\' !== \DIRECTORY_SEPARATOR) { - $oldMask = \umask(02); - } - $this->filesystem->dumpFile($filename, 'bar'); - $this->assertFileExists($filename); - $this->assertStringEqualsFile($filename, 'bar'); - // skip mode check on Windows - if ('\\' !== \DIRECTORY_SEPARATOR) { - $this->assertFilePermissions(664, $filename); - \umask($oldMask); - } - } - public function testDumpFileWithArray() - { - $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; - $this->filesystem->dumpFile($filename, ['bar']); - $this->assertFileExists($filename); - $this->assertStringEqualsFile($filename, 'bar'); - } - public function testDumpFileWithResource() - { - $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; - $resource = \fopen('php://memory', 'rw'); - \fwrite($resource, 'bar'); - \fseek($resource, 0); - $this->filesystem->dumpFile($filename, $resource); - \fclose($resource); - $this->assertFileExists($filename); - $this->assertStringEqualsFile($filename, 'bar'); - } - public function testDumpFileOverwritesAnExistingFile() - { - $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo.txt'; - \file_put_contents($filename, 'FOO BAR'); - $this->filesystem->dumpFile($filename, 'bar'); - $this->assertFileExists($filename); - $this->assertStringEqualsFile($filename, 'bar'); - } - public function testDumpFileWithFileScheme() - { - if (\defined('HHVM_VERSION')) { - $this->markTestSkipped('HHVM does not handle the file:// scheme correctly'); - } - $scheme = 'file://'; - $filename = $scheme . $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; - $this->filesystem->dumpFile($filename, 'bar'); - $this->assertFileExists($filename); - $this->assertStringEqualsFile($filename, 'bar'); - } - public function testDumpFileWithZlibScheme() - { - $scheme = 'compress.zlib://'; - $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; - $this->filesystem->dumpFile($filename, 'bar'); - // Zlib stat uses file:// wrapper so remove scheme - $this->assertFileExists(\str_replace($scheme, '', $filename)); - $this->assertStringEqualsFile($filename, 'bar'); - } - public function testAppendToFile() - { - $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'bar.txt'; - // skip mode check on Windows - if ('\\' !== \DIRECTORY_SEPARATOR) { - $oldMask = \umask(02); - } - $this->filesystem->dumpFile($filename, 'foo'); - $this->filesystem->appendToFile($filename, 'bar'); - $this->assertFileExists($filename); - $this->assertStringEqualsFile($filename, 'foobar'); - // skip mode check on Windows - if ('\\' !== \DIRECTORY_SEPARATOR) { - $this->assertFilePermissions(664, $filename); - \umask($oldMask); - } - } - public function testAppendToFileWithScheme() - { - if (\defined('HHVM_VERSION')) { - $this->markTestSkipped('HHVM does not handle the file:// scheme correctly'); - } - $scheme = 'file://'; - $filename = $scheme . $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; - $this->filesystem->dumpFile($filename, 'foo'); - $this->filesystem->appendToFile($filename, 'bar'); - $this->assertFileExists($filename); - $this->assertStringEqualsFile($filename, 'foobar'); - } - public function testAppendToFileWithZlibScheme() - { - $scheme = 'compress.zlib://'; - $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; - $this->filesystem->dumpFile($filename, 'foo'); - // Zlib stat uses file:// wrapper so remove it - $this->assertStringEqualsFile(\str_replace($scheme, '', $filename), 'foo'); - $this->filesystem->appendToFile($filename, 'bar'); - $this->assertFileExists($filename); - $this->assertStringEqualsFile($filename, 'foobar'); - } - public function testAppendToFileCreateTheFileIfNotExists() - { - $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'bar.txt'; - // skip mode check on Windows - if ('\\' !== \DIRECTORY_SEPARATOR) { - $oldMask = \umask(02); - } - $this->filesystem->appendToFile($filename, 'bar'); - // skip mode check on Windows - if ('\\' !== \DIRECTORY_SEPARATOR) { - $this->assertFilePermissions(664, $filename); - \umask($oldMask); - } - $this->assertFileExists($filename); - $this->assertStringEqualsFile($filename, 'bar'); - } - public function testDumpKeepsExistingPermissionsWhenOverwritingAnExistingFile() - { - $this->markAsSkippedIfChmodIsMissing(); - $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo.txt'; - \file_put_contents($filename, 'FOO BAR'); - \chmod($filename, 0745); - $this->filesystem->dumpFile($filename, 'bar', null); - $this->assertFilePermissions(745, $filename); - } - public function testCopyShouldKeepExecutionPermission() - { - $this->markAsSkippedIfChmodIsMissing(); - $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; - $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; - \file_put_contents($sourceFilePath, 'SOURCE FILE'); - \chmod($sourceFilePath, 0745); - $this->filesystem->copy($sourceFilePath, $targetFilePath); - $this->assertFilePermissions(767, $targetFilePath); - } - /** - * Normalize the given path (transform each blackslash into a real directory separator). - * - * @param string $path - * - * @return string - */ - private function normalize($path) - { - return \str_replace('/', \DIRECTORY_SEPARATOR, $path); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests; + +/** + * Test class for Filesystem. + */ +class FilesystemTest extends \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests\FilesystemTestCase +{ + public function testCopyCreatesNewFile() + { + $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; + $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; + \file_put_contents($sourceFilePath, 'SOURCE FILE'); + $this->filesystem->copy($sourceFilePath, $targetFilePath); + $this->assertFileExists($targetFilePath); + $this->assertStringEqualsFile($targetFilePath, 'SOURCE FILE'); + } + public function testCopyFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; + $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; + $this->filesystem->copy($sourceFilePath, $targetFilePath); + } + public function testCopyUnreadableFileFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + // skip test on Windows; PHP can't easily set file as unreadable on Windows + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('This test cannot run on Windows.'); + } + if (!\getenv('USER') || 'root' === \getenv('USER')) { + $this->markTestSkipped('This test will fail if run under superuser'); + } + $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; + $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; + \file_put_contents($sourceFilePath, 'SOURCE FILE'); + // make sure target cannot be read + $this->filesystem->chmod($sourceFilePath, 0222); + $this->filesystem->copy($sourceFilePath, $targetFilePath); + } + public function testCopyOverridesExistingFileIfModified() + { + $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; + $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; + \file_put_contents($sourceFilePath, 'SOURCE FILE'); + \file_put_contents($targetFilePath, 'TARGET FILE'); + \touch($targetFilePath, \time() - 1000); + $this->filesystem->copy($sourceFilePath, $targetFilePath); + $this->assertFileExists($targetFilePath); + $this->assertStringEqualsFile($targetFilePath, 'SOURCE FILE'); + } + public function testCopyDoesNotOverrideExistingFileByDefault() + { + $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; + $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; + \file_put_contents($sourceFilePath, 'SOURCE FILE'); + \file_put_contents($targetFilePath, 'TARGET FILE'); + // make sure both files have the same modification time + $modificationTime = \time() - 1000; + \touch($sourceFilePath, $modificationTime); + \touch($targetFilePath, $modificationTime); + $this->filesystem->copy($sourceFilePath, $targetFilePath); + $this->assertFileExists($targetFilePath); + $this->assertStringEqualsFile($targetFilePath, 'TARGET FILE'); + } + public function testCopyOverridesExistingFileIfForced() + { + $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; + $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; + \file_put_contents($sourceFilePath, 'SOURCE FILE'); + \file_put_contents($targetFilePath, 'TARGET FILE'); + // make sure both files have the same modification time + $modificationTime = \time() - 1000; + \touch($sourceFilePath, $modificationTime); + \touch($targetFilePath, $modificationTime); + $this->filesystem->copy($sourceFilePath, $targetFilePath, \true); + $this->assertFileExists($targetFilePath); + $this->assertStringEqualsFile($targetFilePath, 'SOURCE FILE'); + } + public function testCopyWithOverrideWithReadOnlyTargetFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + // skip test on Windows; PHP can't easily set file as unwritable on Windows + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('This test cannot run on Windows.'); + } + if (!\getenv('USER') || 'root' === \getenv('USER')) { + $this->markTestSkipped('This test will fail if run under superuser'); + } + $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; + $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; + \file_put_contents($sourceFilePath, 'SOURCE FILE'); + \file_put_contents($targetFilePath, 'TARGET FILE'); + // make sure both files have the same modification time + $modificationTime = \time() - 1000; + \touch($sourceFilePath, $modificationTime); + \touch($targetFilePath, $modificationTime); + // make sure target is read-only + $this->filesystem->chmod($targetFilePath, 0444); + $this->filesystem->copy($sourceFilePath, $targetFilePath, \true); + } + public function testCopyCreatesTargetDirectoryIfItDoesNotExist() + { + $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; + $targetFileDirectory = $this->workspace . \DIRECTORY_SEPARATOR . 'directory'; + $targetFilePath = $targetFileDirectory . \DIRECTORY_SEPARATOR . 'copy_target_file'; + \file_put_contents($sourceFilePath, 'SOURCE FILE'); + $this->filesystem->copy($sourceFilePath, $targetFilePath); + $this->assertDirectoryExists($targetFileDirectory); + $this->assertFileExists($targetFilePath); + $this->assertStringEqualsFile($targetFilePath, 'SOURCE FILE'); + } + /** + * @group network + */ + public function testCopyForOriginUrlsAndExistingLocalFileDefaultsToCopy() + { + if (!\in_array('https', \stream_get_wrappers())) { + $this->markTestSkipped('"https" stream wrapper is not enabled.'); + } + $sourceFilePath = 'https://symfony.com/images/common/logo/logo_symfony_header.png'; + $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; + \file_put_contents($targetFilePath, 'TARGET FILE'); + $this->filesystem->copy($sourceFilePath, $targetFilePath, \false); + $this->assertFileExists($targetFilePath); + $this->assertEquals(\file_get_contents($sourceFilePath), \file_get_contents($targetFilePath)); + } + public function testMkdirCreatesDirectoriesRecursively() + { + $directory = $this->workspace . \DIRECTORY_SEPARATOR . 'directory' . \DIRECTORY_SEPARATOR . 'sub_directory'; + $this->filesystem->mkdir($directory); + $this->assertDirectoryExists($directory); + } + public function testMkdirCreatesDirectoriesFromArray() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR; + $directories = [$basePath . '1', $basePath . '2', $basePath . '3']; + $this->filesystem->mkdir($directories); + $this->assertDirectoryExists($basePath . '1'); + $this->assertDirectoryExists($basePath . '2'); + $this->assertDirectoryExists($basePath . '3'); + } + public function testMkdirCreatesDirectoriesFromTraversableObject() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR; + $directories = new \ArrayObject([$basePath . '1', $basePath . '2', $basePath . '3']); + $this->filesystem->mkdir($directories); + $this->assertDirectoryExists($basePath . '1'); + $this->assertDirectoryExists($basePath . '2'); + $this->assertDirectoryExists($basePath . '3'); + } + public function testMkdirCreatesDirectoriesFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $basePath = $this->workspace . \DIRECTORY_SEPARATOR; + $dir = $basePath . '2'; + \file_put_contents($dir, ''); + $this->filesystem->mkdir($dir); + } + public function testTouchCreatesEmptyFile() + { + $file = $this->workspace . \DIRECTORY_SEPARATOR . '1'; + $this->filesystem->touch($file); + $this->assertFileExists($file); + } + public function testTouchFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $file = $this->workspace . \DIRECTORY_SEPARATOR . '1' . \DIRECTORY_SEPARATOR . '2'; + $this->filesystem->touch($file); + } + public function testTouchCreatesEmptyFilesFromArray() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR; + $files = [$basePath . '1', $basePath . '2', $basePath . '3']; + $this->filesystem->touch($files); + $this->assertFileExists($basePath . '1'); + $this->assertFileExists($basePath . '2'); + $this->assertFileExists($basePath . '3'); + } + public function testTouchCreatesEmptyFilesFromTraversableObject() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR; + $files = new \ArrayObject([$basePath . '1', $basePath . '2', $basePath . '3']); + $this->filesystem->touch($files); + $this->assertFileExists($basePath . '1'); + $this->assertFileExists($basePath . '2'); + $this->assertFileExists($basePath . '3'); + } + public function testRemoveCleansFilesAndDirectoriesIteratively() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR . 'directory' . \DIRECTORY_SEPARATOR; + \mkdir($basePath); + \mkdir($basePath . 'dir'); + \touch($basePath . 'file'); + $this->filesystem->remove($basePath); + $this->assertFileNotExists($basePath); + } + public function testRemoveCleansArrayOfFilesAndDirectories() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR; + \mkdir($basePath . 'dir'); + \touch($basePath . 'file'); + $files = [$basePath . 'dir', $basePath . 'file']; + $this->filesystem->remove($files); + $this->assertFileNotExists($basePath . 'dir'); + $this->assertFileNotExists($basePath . 'file'); + } + public function testRemoveCleansTraversableObjectOfFilesAndDirectories() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR; + \mkdir($basePath . 'dir'); + \touch($basePath . 'file'); + $files = new \ArrayObject([$basePath . 'dir', $basePath . 'file']); + $this->filesystem->remove($files); + $this->assertFileNotExists($basePath . 'dir'); + $this->assertFileNotExists($basePath . 'file'); + } + public function testRemoveIgnoresNonExistingFiles() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR; + \mkdir($basePath . 'dir'); + $files = [$basePath . 'dir', $basePath . 'file']; + $this->filesystem->remove($files); + $this->assertFileNotExists($basePath . 'dir'); + } + public function testRemoveCleansInvalidLinks() + { + $this->markAsSkippedIfSymlinkIsMissing(); + $basePath = $this->workspace . \DIRECTORY_SEPARATOR . 'directory' . \DIRECTORY_SEPARATOR; + \mkdir($basePath); + \mkdir($basePath . 'dir'); + // create symlink to nonexistent file + @\symlink($basePath . 'file', $basePath . 'file-link'); + // create symlink to dir using trailing forward slash + $this->filesystem->symlink($basePath . 'dir/', $basePath . 'dir-link'); + $this->assertDirectoryExists($basePath . 'dir-link'); + // create symlink to nonexistent dir + \rmdir($basePath . 'dir'); + $this->assertFalse('\\' === \DIRECTORY_SEPARATOR ? @\readlink($basePath . 'dir-link') : \is_dir($basePath . 'dir-link')); + $this->filesystem->remove($basePath); + $this->assertFileNotExists($basePath); + } + public function testFilesExists() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR . 'directory' . \DIRECTORY_SEPARATOR; + \mkdir($basePath); + \touch($basePath . 'file1'); + \mkdir($basePath . 'folder'); + $this->assertTrue($this->filesystem->exists($basePath . 'file1')); + $this->assertTrue($this->filesystem->exists($basePath . 'folder')); + } + public function testFilesExistsFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + if ('\\' !== \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('Long file names are an issue on Windows'); + } + $basePath = $this->workspace . '\\directory\\'; + $maxPathLength = \PHP_MAXPATHLEN - 2; + $oldPath = \getcwd(); + \mkdir($basePath); + \chdir($basePath); + $file = \str_repeat('T', $maxPathLength - \strlen($basePath) + 1); + $path = $basePath . $file; + \exec('TYPE NUL >>' . $file); + // equivalent of touch, we can not use the php touch() here because it suffers from the same limitation + $this->longPathNamesWindows[] = $path; + // save this so we can clean up later + \chdir($oldPath); + $this->filesystem->exists($path); + } + public function testFilesExistsTraversableObjectOfFilesAndDirectories() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR; + \mkdir($basePath . 'dir'); + \touch($basePath . 'file'); + $files = new \ArrayObject([$basePath . 'dir', $basePath . 'file']); + $this->assertTrue($this->filesystem->exists($files)); + } + public function testFilesNotExistsTraversableObjectOfFilesAndDirectories() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR; + \mkdir($basePath . 'dir'); + \touch($basePath . 'file'); + \touch($basePath . 'file2'); + $files = new \ArrayObject([$basePath . 'dir', $basePath . 'file', $basePath . 'file2']); + \unlink($basePath . 'file'); + $this->assertFalse($this->filesystem->exists($files)); + } + public function testInvalidFileNotExists() + { + $basePath = $this->workspace . \DIRECTORY_SEPARATOR . 'directory' . \DIRECTORY_SEPARATOR; + $this->assertFalse($this->filesystem->exists($basePath . \time())); + } + public function testChmodChangesFileMode() + { + $this->markAsSkippedIfChmodIsMissing(); + $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; + \mkdir($dir); + $file = $dir . \DIRECTORY_SEPARATOR . 'file'; + \touch($file); + $this->filesystem->chmod($file, 0400); + $this->filesystem->chmod($dir, 0753); + $this->assertFilePermissions(753, $dir); + $this->assertFilePermissions(400, $file); + } + public function testChmodWithWrongModLeavesPreviousPermissionsUntouched() + { + $this->markAsSkippedIfChmodIsMissing(); + if (\defined('HHVM_VERSION')) { + $this->markTestSkipped('chmod() changes permissions even when passing invalid modes on HHVM'); + } + $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + \touch($dir); + $permissions = \fileperms($dir); + $this->filesystem->chmod($dir, 'Wrongmode'); + $this->assertSame($permissions, \fileperms($dir)); + } + public function testChmodRecursive() + { + $this->markAsSkippedIfChmodIsMissing(); + $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; + \mkdir($dir); + $file = $dir . \DIRECTORY_SEPARATOR . 'file'; + \touch($file); + $this->filesystem->chmod($file, 0400, 00, \true); + $this->filesystem->chmod($dir, 0753, 00, \true); + $this->assertFilePermissions(753, $dir); + $this->assertFilePermissions(753, $file); + } + public function testChmodAppliesUmask() + { + $this->markAsSkippedIfChmodIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + \touch($file); + $this->filesystem->chmod($file, 0770, 022); + $this->assertFilePermissions(750, $file); + } + public function testChmodChangesModeOfArrayOfFiles() + { + $this->markAsSkippedIfChmodIsMissing(); + $directory = $this->workspace . \DIRECTORY_SEPARATOR . 'directory'; + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $files = [$directory, $file]; + \mkdir($directory); + \touch($file); + $this->filesystem->chmod($files, 0753); + $this->assertFilePermissions(753, $file); + $this->assertFilePermissions(753, $directory); + } + public function testChmodChangesModeOfTraversableFileObject() + { + $this->markAsSkippedIfChmodIsMissing(); + $directory = $this->workspace . \DIRECTORY_SEPARATOR . 'directory'; + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $files = new \ArrayObject([$directory, $file]); + \mkdir($directory); + \touch($file); + $this->filesystem->chmod($files, 0753); + $this->assertFilePermissions(753, $file); + $this->assertFilePermissions(753, $directory); + } + public function testChmodChangesZeroModeOnSubdirectoriesOnRecursive() + { + $this->markAsSkippedIfChmodIsMissing(); + $directory = $this->workspace . \DIRECTORY_SEPARATOR . 'directory'; + $subdirectory = $directory . \DIRECTORY_SEPARATOR . 'subdirectory'; + \mkdir($directory); + \mkdir($subdirectory); + \chmod($subdirectory, 00); + $this->filesystem->chmod($directory, 0753, 00, \true); + $this->assertFilePermissions(753, $subdirectory); + } + public function testChown() + { + $this->markAsSkippedIfPosixIsMissing(); + $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; + \mkdir($dir); + $owner = $this->getFileOwner($dir); + $this->filesystem->chown($dir, $owner); + $this->assertSame($owner, $this->getFileOwner($dir)); + } + public function testChownRecursive() + { + $this->markAsSkippedIfPosixIsMissing(); + $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; + \mkdir($dir); + $file = $dir . \DIRECTORY_SEPARATOR . 'file'; + \touch($file); + $owner = $this->getFileOwner($dir); + $this->filesystem->chown($dir, $owner, \true); + $this->assertSame($owner, $this->getFileOwner($file)); + } + public function testChownSymlink() + { + $this->markAsSkippedIfSymlinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + $this->filesystem->symlink($file, $link); + $owner = $this->getFileOwner($link); + $this->filesystem->chown($link, $owner); + $this->assertSame($owner, $this->getFileOwner($link)); + } + public function testChownLink() + { + $this->markAsSkippedIfLinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + $this->filesystem->hardlink($file, $link); + $owner = $this->getFileOwner($link); + $this->filesystem->chown($link, $owner); + $this->assertSame($owner, $this->getFileOwner($link)); + } + public function testChownSymlinkFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $this->markAsSkippedIfSymlinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + $this->filesystem->symlink($file, $link); + $this->filesystem->chown($link, 'user' . \time() . \mt_rand(1000, 9999)); + } + public function testChownLinkFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $this->markAsSkippedIfLinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + $this->filesystem->hardlink($file, $link); + $this->filesystem->chown($link, 'user' . \time() . \mt_rand(1000, 9999)); + } + public function testChownFail() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $this->markAsSkippedIfPosixIsMissing(); + $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; + \mkdir($dir); + $this->filesystem->chown($dir, 'user' . \time() . \mt_rand(1000, 9999)); + } + public function testChgrp() + { + $this->markAsSkippedIfPosixIsMissing(); + $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; + \mkdir($dir); + $group = $this->getFileGroup($dir); + $this->filesystem->chgrp($dir, $group); + $this->assertSame($group, $this->getFileGroup($dir)); + } + public function testChgrpRecursive() + { + $this->markAsSkippedIfPosixIsMissing(); + $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; + \mkdir($dir); + $file = $dir . \DIRECTORY_SEPARATOR . 'file'; + \touch($file); + $group = $this->getFileGroup($dir); + $this->filesystem->chgrp($dir, $group, \true); + $this->assertSame($group, $this->getFileGroup($file)); + } + public function testChgrpSymlink() + { + $this->markAsSkippedIfSymlinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + $this->filesystem->symlink($file, $link); + $group = $this->getFileGroup($link); + $this->filesystem->chgrp($link, $group); + $this->assertSame($group, $this->getFileGroup($link)); + } + public function testChgrpLink() + { + $this->markAsSkippedIfLinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + $this->filesystem->hardlink($file, $link); + $group = $this->getFileGroup($link); + $this->filesystem->chgrp($link, $group); + $this->assertSame($group, $this->getFileGroup($link)); + } + public function testChgrpSymlinkFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $this->markAsSkippedIfSymlinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + $this->filesystem->symlink($file, $link); + $this->filesystem->chgrp($link, 'user' . \time() . \mt_rand(1000, 9999)); + } + public function testChgrpLinkFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $this->markAsSkippedIfLinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + $this->filesystem->hardlink($file, $link); + $this->filesystem->chgrp($link, 'user' . \time() . \mt_rand(1000, 9999)); + } + public function testChgrpFail() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $this->markAsSkippedIfPosixIsMissing(); + $dir = $this->workspace . \DIRECTORY_SEPARATOR . 'dir'; + \mkdir($dir); + $this->filesystem->chgrp($dir, 'user' . \time() . \mt_rand(1000, 9999)); + } + public function testRename() + { + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $newPath = $this->workspace . \DIRECTORY_SEPARATOR . 'new_file'; + \touch($file); + $this->filesystem->rename($file, $newPath); + $this->assertFileNotExists($file); + $this->assertFileExists($newPath); + } + public function testRenameThrowsExceptionIfTargetAlreadyExists() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $newPath = $this->workspace . \DIRECTORY_SEPARATOR . 'new_file'; + \touch($file); + \touch($newPath); + $this->filesystem->rename($file, $newPath); + } + public function testRenameOverwritesTheTargetIfItAlreadyExists() + { + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $newPath = $this->workspace . \DIRECTORY_SEPARATOR . 'new_file'; + \touch($file); + \touch($newPath); + $this->filesystem->rename($file, $newPath, \true); + $this->assertFileNotExists($file); + $this->assertFileExists($newPath); + } + public function testRenameThrowsExceptionOnError() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $file = $this->workspace . \DIRECTORY_SEPARATOR . \uniqid('fs_test_', \true); + $newPath = $this->workspace . \DIRECTORY_SEPARATOR . 'new_file'; + $this->filesystem->rename($file, $newPath); + } + public function testSymlink() + { + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('Windows does not support creating "broken" symlinks'); + } + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + // $file does not exist right now: creating "broken" links is a wanted feature + $this->filesystem->symlink($file, $link); + $this->assertTrue(\is_link($link)); + // Create the linked file AFTER creating the link + \touch($file); + $this->assertEquals($file, \readlink($link)); + } + /** + * @depends testSymlink + */ + public function testRemoveSymlink() + { + $this->markAsSkippedIfSymlinkIsMissing(); + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + $this->filesystem->remove($link); + $this->assertFalse(\is_link($link)); + $this->assertFalse(\is_file($link)); + $this->assertDirectoryNotExists($link); + } + public function testSymlinkIsOverwrittenIfPointsToDifferentTarget() + { + $this->markAsSkippedIfSymlinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + \symlink($this->workspace, $link); + $this->filesystem->symlink($file, $link); + $this->assertTrue(\is_link($link)); + $this->assertEquals($file, \readlink($link)); + } + public function testSymlinkIsNotOverwrittenIfAlreadyCreated() + { + $this->markAsSkippedIfSymlinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + \symlink($file, $link); + $this->filesystem->symlink($file, $link); + $this->assertTrue(\is_link($link)); + $this->assertEquals($file, \readlink($link)); + } + public function testSymlinkCreatesTargetDirectoryIfItDoesNotExist() + { + $this->markAsSkippedIfSymlinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link1 = $this->workspace . \DIRECTORY_SEPARATOR . 'dir' . \DIRECTORY_SEPARATOR . 'link'; + $link2 = $this->workspace . \DIRECTORY_SEPARATOR . 'dir' . \DIRECTORY_SEPARATOR . 'subdir' . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + $this->filesystem->symlink($file, $link1); + $this->filesystem->symlink($file, $link2); + $this->assertTrue(\is_link($link1)); + $this->assertEquals($file, \readlink($link1)); + $this->assertTrue(\is_link($link2)); + $this->assertEquals($file, \readlink($link2)); + } + public function testLink() + { + $this->markAsSkippedIfLinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + $this->filesystem->hardlink($file, $link); + $this->assertTrue(\is_file($link)); + $this->assertEquals(\fileinode($file), \fileinode($link)); + } + /** + * @depends testLink + */ + public function testRemoveLink() + { + $this->markAsSkippedIfLinkIsMissing(); + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + $this->filesystem->remove($link); + $this->assertTrue(!\is_file($link)); + } + public function testLinkIsOverwrittenIfPointsToDifferentTarget() + { + $this->markAsSkippedIfLinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $file2 = $this->workspace . \DIRECTORY_SEPARATOR . 'file2'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + \touch($file2); + \link($file2, $link); + $this->filesystem->hardlink($file, $link); + $this->assertTrue(\is_file($link)); + $this->assertEquals(\fileinode($file), \fileinode($link)); + } + public function testLinkIsNotOverwrittenIfAlreadyCreated() + { + $this->markAsSkippedIfLinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + \link($file, $link); + $this->filesystem->hardlink($file, $link); + $this->assertTrue(\is_file($link)); + $this->assertEquals(\fileinode($file), \fileinode($link)); + } + public function testLinkWithSeveralTargets() + { + $this->markAsSkippedIfLinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link1 = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + $link2 = $this->workspace . \DIRECTORY_SEPARATOR . 'link2'; + \touch($file); + $this->filesystem->hardlink($file, [$link1, $link2]); + $this->assertTrue(\is_file($link1)); + $this->assertEquals(\fileinode($file), \fileinode($link1)); + $this->assertTrue(\is_file($link2)); + $this->assertEquals(\fileinode($file), \fileinode($link2)); + } + public function testLinkWithSameTarget() + { + $this->markAsSkippedIfLinkIsMissing(); + $file = $this->workspace . \DIRECTORY_SEPARATOR . 'file'; + $link = $this->workspace . \DIRECTORY_SEPARATOR . 'link'; + \touch($file); + // practically same as testLinkIsNotOverwrittenIfAlreadyCreated + $this->filesystem->hardlink($file, [$link, $link]); + $this->assertTrue(\is_file($link)); + $this->assertEquals(\fileinode($file), \fileinode($link)); + } + public function testReadRelativeLink() + { + $this->markAsSkippedIfSymlinkIsMissing(); + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('Relative symbolic links are not supported on Windows'); + } + $file = $this->workspace . '/file'; + $link1 = $this->workspace . '/dir/link'; + $link2 = $this->workspace . '/dir/link2'; + \touch($file); + $this->filesystem->symlink('../file', $link1); + $this->filesystem->symlink('link', $link2); + $this->assertEquals($this->normalize('../file'), $this->filesystem->readlink($link1)); + $this->assertEquals('link', $this->filesystem->readlink($link2)); + $this->assertEquals($file, $this->filesystem->readlink($link1, \true)); + $this->assertEquals($file, $this->filesystem->readlink($link2, \true)); + $this->assertEquals($file, $this->filesystem->readlink($file, \true)); + } + public function testReadAbsoluteLink() + { + $this->markAsSkippedIfSymlinkIsMissing(); + $file = $this->normalize($this->workspace . '/file'); + $link1 = $this->normalize($this->workspace . '/dir/link'); + $link2 = $this->normalize($this->workspace . '/dir/link2'); + \touch($file); + $this->filesystem->symlink($file, $link1); + $this->filesystem->symlink($link1, $link2); + $this->assertEquals($file, $this->filesystem->readlink($link1)); + $this->assertEquals($link1, $this->filesystem->readlink($link2)); + $this->assertEquals($file, $this->filesystem->readlink($link1, \true)); + $this->assertEquals($file, $this->filesystem->readlink($link2, \true)); + $this->assertEquals($file, $this->filesystem->readlink($file, \true)); + } + public function testReadBrokenLink() + { + $this->markAsSkippedIfSymlinkIsMissing(); + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('Windows does not support creating "broken" symlinks'); + } + $file = $this->workspace . '/file'; + $link = $this->workspace . '/link'; + $this->filesystem->symlink($file, $link); + $this->assertEquals($file, $this->filesystem->readlink($link)); + $this->assertNull($this->filesystem->readlink($link, \true)); + \touch($file); + $this->assertEquals($file, $this->filesystem->readlink($link, \true)); + } + public function testReadLinkDefaultPathDoesNotExist() + { + $this->assertNull($this->filesystem->readlink($this->normalize($this->workspace . '/invalid'))); + } + public function testReadLinkDefaultPathNotLink() + { + $file = $this->normalize($this->workspace . '/file'); + \touch($file); + $this->assertNull($this->filesystem->readlink($file)); + } + public function testReadLinkCanonicalizePath() + { + $this->markAsSkippedIfSymlinkIsMissing(); + $file = $this->normalize($this->workspace . '/file'); + \mkdir($this->normalize($this->workspace . '/dir')); + \touch($file); + $this->assertEquals($file, $this->filesystem->readlink($this->normalize($this->workspace . '/dir/../file'), \true)); + } + public function testReadLinkCanonicalizedPathDoesNotExist() + { + $this->assertNull($this->filesystem->readlink($this->normalize($this->workspace . 'invalid'), \true)); + } + /** + * @dataProvider providePathsForMakePathRelative + */ + public function testMakePathRelative($endPath, $startPath, $expectedPath) + { + $path = $this->filesystem->makePathRelative($endPath, $startPath); + $this->assertEquals($expectedPath, $path); + } + public function providePathsForMakePathRelative() + { + $paths = [['/var/lib/symfony/src/Symfony/', '/var/lib/symfony/src/Symfony/Component', '../'], ['/var/lib/symfony/src/Symfony/', '/var/lib/symfony/src/Symfony/Component/', '../'], ['/var/lib/symfony/src/Symfony', '/var/lib/symfony/src/Symfony/Component', '../'], ['/var/lib/symfony/src/Symfony', '/var/lib/symfony/src/Symfony/Component/', '../'], ['/usr/lib/symfony/', '/var/lib/symfony/src/Symfony/Component', '../../../../../../usr/lib/symfony/'], ['/var/lib/symfony/src/Symfony/', '/var/lib/symfony/', 'src/Symfony/'], ['/aa/bb', '/aa/bb', './'], ['/aa/bb', '/aa/bb/', './'], ['/aa/bb/', '/aa/bb', './'], ['/aa/bb/', '/aa/bb/', './'], ['/aa/bb/cc', '/aa/bb/cc/dd', '../'], ['/aa/bb/cc', '/aa/bb/cc/dd/', '../'], ['/aa/bb/cc/', '/aa/bb/cc/dd', '../'], ['/aa/bb/cc/', '/aa/bb/cc/dd/', '../'], ['/aa/bb/cc', '/aa', 'bb/cc/'], ['/aa/bb/cc', '/aa/', 'bb/cc/'], ['/aa/bb/cc/', '/aa', 'bb/cc/'], ['/aa/bb/cc/', '/aa/', 'bb/cc/'], ['/a/aab/bb', '/a/aa', '../aab/bb/'], ['/a/aab/bb', '/a/aa/', '../aab/bb/'], ['/a/aab/bb/', '/a/aa', '../aab/bb/'], ['/a/aab/bb/', '/a/aa/', '../aab/bb/'], ['/a/aab/bb/', '/', 'a/aab/bb/'], ['/a/aab/bb/', '/b/aab', '../../a/aab/bb/'], ['/aab/bb', '/aa', '../aab/bb/'], ['/aab', '/aa', '../aab/'], ['/aa/bb/cc', '/aa/dd/..', 'bb/cc/'], ['/aa/../bb/cc', '/aa/dd/..', '../bb/cc/'], ['/aa/bb/../../cc', '/aa/../dd/..', 'cc/'], ['/../aa/bb/cc', '/aa/dd/..', 'bb/cc/'], ['/../../aa/../bb/cc', '/aa/dd/..', '../bb/cc/'], ['C:/aa/bb/cc', 'C:/aa/dd/..', 'bb/cc/'], ['c:/aa/../bb/cc', 'c:/aa/dd/..', '../bb/cc/'], ['C:/aa/bb/../../cc', 'C:/aa/../dd/..', 'cc/'], ['C:/../aa/bb/cc', 'C:/aa/dd/..', 'bb/cc/'], ['C:/../../aa/../bb/cc', 'C:/aa/dd/..', '../bb/cc/']]; + if ('\\' === \DIRECTORY_SEPARATOR) { + $paths[] = ['c:\\var\\lib/symfony/src/Symfony/', 'c:/var/lib/symfony/', 'src/Symfony/']; + } + return $paths; + } + /** + * @group legacy + * @dataProvider provideLegacyPathsForMakePathRelativeWithRelativePaths + * @expectedDeprecation Support for passing relative paths to Symfony\Component\Filesystem\Filesystem::makePathRelative() is deprecated since Symfony 3.4 and will be removed in 4.0. + */ + public function testMakePathRelativeWithRelativePaths($endPath, $startPath, $expectedPath) + { + $path = $this->filesystem->makePathRelative($endPath, $startPath); + $this->assertEquals($expectedPath, $path); + } + public function provideLegacyPathsForMakePathRelativeWithRelativePaths() + { + return [['usr/lib/symfony/', 'var/lib/symfony/src/Symfony/Component', '../../../../../../usr/lib/symfony/'], ['aa/bb', 'aa/cc', '../bb/'], ['aa/cc', 'bb/cc', '../../aa/cc/'], ['aa/bb', 'aa/./cc', '../bb/'], ['aa/./bb', 'aa/cc', '../bb/'], ['aa/./bb', 'aa/./cc', '../bb/'], ['../../', '../../', './'], ['../aa/bb/', 'aa/bb/', '../../../aa/bb/'], ['../../../', '../../', '../'], ['', '', './'], ['', 'aa/', '../'], ['aa/', '', 'aa/']]; + } + public function testMirrorCopiesFilesAndDirectoriesRecursively() + { + $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; + $directory = $sourcePath . 'directory' . \DIRECTORY_SEPARATOR; + $file1 = $directory . 'file1'; + $file2 = $sourcePath . 'file2'; + \mkdir($sourcePath); + \mkdir($directory); + \file_put_contents($file1, 'FILE1'); + \file_put_contents($file2, 'FILE2'); + $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; + $this->filesystem->mirror($sourcePath, $targetPath); + $this->assertDirectoryExists($targetPath); + $this->assertDirectoryExists($targetPath . 'directory'); + $this->assertFileEquals($file1, $targetPath . 'directory' . \DIRECTORY_SEPARATOR . 'file1'); + $this->assertFileEquals($file2, $targetPath . 'file2'); + $this->filesystem->remove($file1); + $this->filesystem->mirror($sourcePath, $targetPath, null, ['delete' => \false]); + $this->assertTrue($this->filesystem->exists($targetPath . 'directory' . \DIRECTORY_SEPARATOR . 'file1')); + $this->filesystem->mirror($sourcePath, $targetPath, null, ['delete' => \true]); + $this->assertFalse($this->filesystem->exists($targetPath . 'directory' . \DIRECTORY_SEPARATOR . 'file1')); + \file_put_contents($file1, 'FILE1'); + $this->filesystem->mirror($sourcePath, $targetPath, null, ['delete' => \true]); + $this->assertTrue($this->filesystem->exists($targetPath . 'directory' . \DIRECTORY_SEPARATOR . 'file1')); + $this->filesystem->remove($directory); + $this->filesystem->mirror($sourcePath, $targetPath, null, ['delete' => \true]); + $this->assertFalse($this->filesystem->exists($targetPath . 'directory')); + $this->assertFalse($this->filesystem->exists($targetPath . 'directory' . \DIRECTORY_SEPARATOR . 'file1')); + } + public function testMirrorCreatesEmptyDirectory() + { + $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; + \mkdir($sourcePath); + $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; + $this->filesystem->mirror($sourcePath, $targetPath); + $this->assertDirectoryExists($targetPath); + $this->filesystem->remove($sourcePath); + } + public function testMirrorCopiesLinks() + { + $this->markAsSkippedIfSymlinkIsMissing(); + $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; + \mkdir($sourcePath); + \file_put_contents($sourcePath . 'file1', 'FILE1'); + \symlink($sourcePath . 'file1', $sourcePath . 'link1'); + $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; + $this->filesystem->mirror($sourcePath, $targetPath); + $this->assertDirectoryExists($targetPath); + $this->assertFileEquals($sourcePath . 'file1', $targetPath . 'link1'); + $this->assertTrue(\is_link($targetPath . \DIRECTORY_SEPARATOR . 'link1')); + } + public function testMirrorCopiesLinkedDirectoryContents() + { + $this->markAsSkippedIfSymlinkIsMissing(\true); + $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; + \mkdir($sourcePath . 'nested/', 0777, \true); + \file_put_contents($sourcePath . '/nested/file1.txt', 'FILE1'); + // Note: We symlink directory, not file + \symlink($sourcePath . 'nested', $sourcePath . 'link1'); + $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; + $this->filesystem->mirror($sourcePath, $targetPath); + $this->assertDirectoryExists($targetPath); + $this->assertFileEquals($sourcePath . '/nested/file1.txt', $targetPath . 'link1/file1.txt'); + $this->assertTrue(\is_link($targetPath . \DIRECTORY_SEPARATOR . 'link1')); + } + public function testMirrorCopiesRelativeLinkedContents() + { + $this->markAsSkippedIfSymlinkIsMissing(\true); + $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; + $oldPath = \getcwd(); + \mkdir($sourcePath . 'nested/', 0777, \true); + \file_put_contents($sourcePath . '/nested/file1.txt', 'FILE1'); + // Note: Create relative symlink + \chdir($sourcePath); + \symlink('nested', 'link1'); + \chdir($oldPath); + $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; + $this->filesystem->mirror($sourcePath, $targetPath); + $this->assertDirectoryExists($targetPath); + $this->assertFileEquals($sourcePath . '/nested/file1.txt', $targetPath . 'link1/file1.txt'); + $this->assertTrue(\is_link($targetPath . \DIRECTORY_SEPARATOR . 'link1')); + $this->assertEquals('\\' === \DIRECTORY_SEPARATOR ? \realpath($sourcePath . '\\nested') : 'nested', \readlink($targetPath . \DIRECTORY_SEPARATOR . 'link1')); + } + public function testMirrorContentsWithSameNameAsSourceOrTargetWithoutDeleteOption() + { + $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; + \mkdir($sourcePath); + \touch($sourcePath . 'source'); + \touch($sourcePath . 'target'); + $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; + $oldPath = \getcwd(); + \chdir($this->workspace); + $this->filesystem->mirror('source', $targetPath); + \chdir($oldPath); + $this->assertDirectoryExists($targetPath); + $this->assertFileExists($targetPath . 'source'); + $this->assertFileExists($targetPath . 'target'); + } + public function testMirrorContentsWithSameNameAsSourceOrTargetWithDeleteOption() + { + $sourcePath = $this->workspace . \DIRECTORY_SEPARATOR . 'source' . \DIRECTORY_SEPARATOR; + \mkdir($sourcePath); + \touch($sourcePath . 'source'); + $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'target' . \DIRECTORY_SEPARATOR; + \mkdir($targetPath); + \touch($targetPath . 'source'); + \touch($targetPath . 'target'); + $oldPath = \getcwd(); + \chdir($this->workspace); + $this->filesystem->mirror('source', 'target', null, ['delete' => \true]); + \chdir($oldPath); + $this->assertDirectoryExists($targetPath); + $this->assertFileExists($targetPath . 'source'); + $this->assertFileNotExists($targetPath . 'target'); + } + public function testMirrorFromSubdirectoryInToParentDirectory() + { + $targetPath = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR; + $sourcePath = $targetPath . 'bar' . \DIRECTORY_SEPARATOR; + $file1 = $sourcePath . 'file1'; + $file2 = $sourcePath . 'file2'; + $this->filesystem->mkdir($sourcePath); + \file_put_contents($file1, 'FILE1'); + \file_put_contents($file2, 'FILE2'); + $this->filesystem->mirror($sourcePath, $targetPath); + $this->assertFileEquals($file1, $targetPath . 'file1'); + } + /** + * @dataProvider providePathsForIsAbsolutePath + */ + public function testIsAbsolutePath($path, $expectedResult) + { + $result = $this->filesystem->isAbsolutePath($path); + $this->assertEquals($expectedResult, $result); + } + public function providePathsForIsAbsolutePath() + { + return [['/var/lib', \true], ['_PhpScoper5ea00cc67502b\\c:\\var\\lib', \true], ['_PhpScoper5ea00cc67502b\\var\\lib', \true], ['var/lib', \false], ['../var/lib', \false], ['', \false], [null, \false]]; + } + public function testTempnam() + { + $dirname = $this->workspace; + $filename = $this->filesystem->tempnam($dirname, 'foo'); + $this->assertFileExists($filename); + } + public function testTempnamWithFileScheme() + { + $scheme = 'file://'; + $dirname = $scheme . $this->workspace; + $filename = $this->filesystem->tempnam($dirname, 'foo'); + $this->assertStringStartsWith($scheme, $filename); + $this->assertFileExists($filename); + } + public function testTempnamWithMockScheme() + { + \stream_wrapper_register('mock', '_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Tests\\Fixtures\\MockStream\\MockStream'); + $scheme = 'mock://'; + $dirname = $scheme . $this->workspace; + $filename = $this->filesystem->tempnam($dirname, 'foo'); + $this->assertStringStartsWith($scheme, $filename); + $this->assertFileExists($filename); + } + public function testTempnamWithZlibSchemeFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $scheme = 'compress.zlib://'; + $dirname = $scheme . $this->workspace; + // The compress.zlib:// stream does not support mode x: creates the file, errors "failed to open stream: operation failed" and returns false + $this->filesystem->tempnam($dirname, 'bar'); + } + public function testTempnamWithPHPTempSchemeFails() + { + $scheme = 'php://temp'; + $dirname = $scheme; + $filename = $this->filesystem->tempnam($dirname, 'bar'); + $this->assertStringStartsWith($scheme, $filename); + // The php://temp stream deletes the file after close + $this->assertFileNotExists($filename); + } + public function testTempnamWithPharSchemeFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + // Skip test if Phar disabled phar.readonly must be 0 in php.ini + if (!\Phar::canWrite()) { + $this->markTestSkipped('This test cannot run when phar.readonly is 1.'); + } + $scheme = 'phar://'; + $dirname = $scheme . $this->workspace; + $pharname = 'foo.phar'; + new \Phar($this->workspace . '/' . $pharname, 0, $pharname); + // The phar:// stream does not support mode x: fails to create file, errors "failed to open stream: phar error: "$filename" is not a file in phar "$pharname"" and returns false + $this->filesystem->tempnam($dirname, $pharname . '/bar'); + } + public function testTempnamWithHTTPSchemeFails() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $scheme = 'http://'; + $dirname = $scheme . $this->workspace; + // The http:// scheme is read-only + $this->filesystem->tempnam($dirname, 'bar'); + } + public function testTempnamOnUnwritableFallsBackToSysTmp() + { + $scheme = 'file://'; + $dirname = $scheme . $this->workspace . \DIRECTORY_SEPARATOR . 'does_not_exist'; + $filename = $this->filesystem->tempnam($dirname, 'bar'); + $realTempDir = \realpath(\sys_get_temp_dir()); + $this->assertStringStartsWith(\rtrim($scheme . $realTempDir, \DIRECTORY_SEPARATOR), $filename); + $this->assertFileExists($filename); + // Tear down + @\unlink($filename); + } + public function testDumpFile() + { + $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; + // skip mode check on Windows + if ('\\' !== \DIRECTORY_SEPARATOR) { + $oldMask = \umask(02); + } + $this->filesystem->dumpFile($filename, 'bar'); + $this->assertFileExists($filename); + $this->assertStringEqualsFile($filename, 'bar'); + // skip mode check on Windows + if ('\\' !== \DIRECTORY_SEPARATOR) { + $this->assertFilePermissions(664, $filename); + \umask($oldMask); + } + } + public function testDumpFileWithArray() + { + $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; + $this->filesystem->dumpFile($filename, ['bar']); + $this->assertFileExists($filename); + $this->assertStringEqualsFile($filename, 'bar'); + } + public function testDumpFileWithResource() + { + $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; + $resource = \fopen('php://memory', 'rw'); + \fwrite($resource, 'bar'); + \fseek($resource, 0); + $this->filesystem->dumpFile($filename, $resource); + \fclose($resource); + $this->assertFileExists($filename); + $this->assertStringEqualsFile($filename, 'bar'); + } + public function testDumpFileOverwritesAnExistingFile() + { + $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo.txt'; + \file_put_contents($filename, 'FOO BAR'); + $this->filesystem->dumpFile($filename, 'bar'); + $this->assertFileExists($filename); + $this->assertStringEqualsFile($filename, 'bar'); + } + public function testDumpFileWithFileScheme() + { + if (\defined('HHVM_VERSION')) { + $this->markTestSkipped('HHVM does not handle the file:// scheme correctly'); + } + $scheme = 'file://'; + $filename = $scheme . $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; + $this->filesystem->dumpFile($filename, 'bar'); + $this->assertFileExists($filename); + $this->assertStringEqualsFile($filename, 'bar'); + } + public function testDumpFileWithZlibScheme() + { + $scheme = 'compress.zlib://'; + $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; + $this->filesystem->dumpFile($filename, 'bar'); + // Zlib stat uses file:// wrapper so remove scheme + $this->assertFileExists(\str_replace($scheme, '', $filename)); + $this->assertStringEqualsFile($filename, 'bar'); + } + public function testAppendToFile() + { + $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'bar.txt'; + // skip mode check on Windows + if ('\\' !== \DIRECTORY_SEPARATOR) { + $oldMask = \umask(02); + } + $this->filesystem->dumpFile($filename, 'foo'); + $this->filesystem->appendToFile($filename, 'bar'); + $this->assertFileExists($filename); + $this->assertStringEqualsFile($filename, 'foobar'); + // skip mode check on Windows + if ('\\' !== \DIRECTORY_SEPARATOR) { + $this->assertFilePermissions(664, $filename); + \umask($oldMask); + } + } + public function testAppendToFileWithScheme() + { + if (\defined('HHVM_VERSION')) { + $this->markTestSkipped('HHVM does not handle the file:// scheme correctly'); + } + $scheme = 'file://'; + $filename = $scheme . $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; + $this->filesystem->dumpFile($filename, 'foo'); + $this->filesystem->appendToFile($filename, 'bar'); + $this->assertFileExists($filename); + $this->assertStringEqualsFile($filename, 'foobar'); + } + public function testAppendToFileWithZlibScheme() + { + $scheme = 'compress.zlib://'; + $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'baz.txt'; + $this->filesystem->dumpFile($filename, 'foo'); + // Zlib stat uses file:// wrapper so remove it + $this->assertStringEqualsFile(\str_replace($scheme, '', $filename), 'foo'); + $this->filesystem->appendToFile($filename, 'bar'); + $this->assertFileExists($filename); + $this->assertStringEqualsFile($filename, 'foobar'); + } + public function testAppendToFileCreateTheFileIfNotExists() + { + $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo' . \DIRECTORY_SEPARATOR . 'bar.txt'; + // skip mode check on Windows + if ('\\' !== \DIRECTORY_SEPARATOR) { + $oldMask = \umask(02); + } + $this->filesystem->appendToFile($filename, 'bar'); + // skip mode check on Windows + if ('\\' !== \DIRECTORY_SEPARATOR) { + $this->assertFilePermissions(664, $filename); + \umask($oldMask); + } + $this->assertFileExists($filename); + $this->assertStringEqualsFile($filename, 'bar'); + } + public function testDumpKeepsExistingPermissionsWhenOverwritingAnExistingFile() + { + $this->markAsSkippedIfChmodIsMissing(); + $filename = $this->workspace . \DIRECTORY_SEPARATOR . 'foo.txt'; + \file_put_contents($filename, 'FOO BAR'); + \chmod($filename, 0745); + $this->filesystem->dumpFile($filename, 'bar', null); + $this->assertFilePermissions(745, $filename); + } + public function testCopyShouldKeepExecutionPermission() + { + $this->markAsSkippedIfChmodIsMissing(); + $sourceFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_source_file'; + $targetFilePath = $this->workspace . \DIRECTORY_SEPARATOR . 'copy_target_file'; + \file_put_contents($sourceFilePath, 'SOURCE FILE'); + \chmod($sourceFilePath, 0745); + $this->filesystem->copy($sourceFilePath, $targetFilePath); + $this->assertFilePermissions(767, $targetFilePath); + } + /** + * Normalize the given path (transform each blackslash into a real directory separator). + * + * @param string $path + * + * @return string + */ + private function normalize($path) + { + return \str_replace('/', \DIRECTORY_SEPARATOR, $path); + } +} diff --git a/vendor/symfony/filesystem/Tests/FilesystemTestCase.php b/vendor/symfony/filesystem/Tests/FilesystemTestCase.php index 3f9e62e80..7d24a5812 100644 --- a/vendor/symfony/filesystem/Tests/FilesystemTestCase.php +++ b/vendor/symfony/filesystem/Tests/FilesystemTestCase.php @@ -1,136 +1,136 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem; -class FilesystemTestCase extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - private $umask; - protected $longPathNamesWindows = []; - /** - * @var Filesystem - */ - protected $filesystem = null; - /** - * @var string - */ - protected $workspace = null; - /** - * @var bool|null Flag for hard links on Windows - */ - private static $linkOnWindows = null; - /** - * @var bool|null Flag for symbolic links on Windows - */ - private static $symlinkOnWindows = null; - public static function setUpBeforeClass() - { - if ('\\' === \DIRECTORY_SEPARATOR) { - self::$linkOnWindows = \true; - $originFile = \tempnam(\sys_get_temp_dir(), 'li'); - $targetFile = \tempnam(\sys_get_temp_dir(), 'li'); - if (\true !== @\link($originFile, $targetFile)) { - $report = \error_get_last(); - if (\is_array($report) && \false !== \strpos($report['message'], 'error code(1314)')) { - self::$linkOnWindows = \false; - } - } else { - @\unlink($targetFile); - } - self::$symlinkOnWindows = \true; - $originDir = \tempnam(\sys_get_temp_dir(), 'sl'); - $targetDir = \tempnam(\sys_get_temp_dir(), 'sl'); - if (\true !== @\symlink($originDir, $targetDir)) { - $report = \error_get_last(); - if (\is_array($report) && \false !== \strpos($report['message'], 'error code(1314)')) { - self::$symlinkOnWindows = \false; - } - } else { - @\unlink($targetDir); - } - } - } - protected function setUp() - { - $this->umask = \umask(0); - $this->filesystem = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem(); - $this->workspace = \sys_get_temp_dir() . '/' . \microtime(\true) . '.' . \mt_rand(); - \mkdir($this->workspace, 0777, \true); - $this->workspace = \realpath($this->workspace); - } - protected function tearDown() - { - if (!empty($this->longPathNamesWindows)) { - foreach ($this->longPathNamesWindows as $path) { - \exec('DEL ' . $path); - } - $this->longPathNamesWindows = []; - } - $this->filesystem->remove($this->workspace); - \umask($this->umask); - } - /** - * @param int $expectedFilePerms Expected file permissions as three digits (i.e. 755) - * @param string $filePath - */ - protected function assertFilePermissions($expectedFilePerms, $filePath) - { - $actualFilePerms = (int) \substr(\sprintf('%o', \fileperms($filePath)), -3); - $this->assertEquals($expectedFilePerms, $actualFilePerms, \sprintf('File permissions for %s must be %s. Actual %s', $filePath, $expectedFilePerms, $actualFilePerms)); - } - protected function getFileOwner($filepath) - { - $this->markAsSkippedIfPosixIsMissing(); - $infos = \stat($filepath); - return ($datas = \posix_getpwuid($infos['uid'])) ? $datas['name'] : null; - } - protected function getFileGroup($filepath) - { - $this->markAsSkippedIfPosixIsMissing(); - $infos = \stat($filepath); - if ($datas = \posix_getgrgid($infos['gid'])) { - return $datas['name']; - } - $this->markTestSkipped('Unable to retrieve file group name'); - } - protected function markAsSkippedIfLinkIsMissing() - { - if (!\function_exists('link')) { - $this->markTestSkipped('link is not supported'); - } - if ('\\' === \DIRECTORY_SEPARATOR && \false === self::$linkOnWindows) { - $this->markTestSkipped('link requires "Create hard links" privilege on windows'); - } - } - protected function markAsSkippedIfSymlinkIsMissing($relative = \false) - { - if ('\\' === \DIRECTORY_SEPARATOR && \false === self::$symlinkOnWindows) { - $this->markTestSkipped('symlink requires "Create symbolic links" privilege on Windows'); - } - // https://bugs.php.net/69473 - if ($relative && '\\' === \DIRECTORY_SEPARATOR && 1 === \PHP_ZTS) { - $this->markTestSkipped('symlink does not support relative paths on thread safe Windows PHP versions'); - } - } - protected function markAsSkippedIfChmodIsMissing() - { - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('chmod is not supported on Windows'); - } - } - protected function markAsSkippedIfPosixIsMissing() - { - if (!\function_exists('posix_isatty')) { - $this->markTestSkipped('Function posix_isatty is required.'); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem; +class FilesystemTestCase extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + private $umask; + protected $longPathNamesWindows = []; + /** + * @var Filesystem + */ + protected $filesystem = null; + /** + * @var string + */ + protected $workspace = null; + /** + * @var bool|null Flag for hard links on Windows + */ + private static $linkOnWindows = null; + /** + * @var bool|null Flag for symbolic links on Windows + */ + private static $symlinkOnWindows = null; + public static function setUpBeforeClass() + { + if ('\\' === \DIRECTORY_SEPARATOR) { + self::$linkOnWindows = \true; + $originFile = \tempnam(\sys_get_temp_dir(), 'li'); + $targetFile = \tempnam(\sys_get_temp_dir(), 'li'); + if (\true !== @\link($originFile, $targetFile)) { + $report = \error_get_last(); + if (\is_array($report) && \false !== \strpos($report['message'], 'error code(1314)')) { + self::$linkOnWindows = \false; + } + } else { + @\unlink($targetFile); + } + self::$symlinkOnWindows = \true; + $originDir = \tempnam(\sys_get_temp_dir(), 'sl'); + $targetDir = \tempnam(\sys_get_temp_dir(), 'sl'); + if (\true !== @\symlink($originDir, $targetDir)) { + $report = \error_get_last(); + if (\is_array($report) && \false !== \strpos($report['message'], 'error code(1314)')) { + self::$symlinkOnWindows = \false; + } + } else { + @\unlink($targetDir); + } + } + } + protected function setUp() + { + $this->umask = \umask(0); + $this->filesystem = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem(); + $this->workspace = \sys_get_temp_dir() . '/' . \microtime(\true) . '.' . \mt_rand(); + \mkdir($this->workspace, 0777, \true); + $this->workspace = \realpath($this->workspace); + } + protected function tearDown() + { + if (!empty($this->longPathNamesWindows)) { + foreach ($this->longPathNamesWindows as $path) { + \exec('DEL ' . $path); + } + $this->longPathNamesWindows = []; + } + $this->filesystem->remove($this->workspace); + \umask($this->umask); + } + /** + * @param int $expectedFilePerms Expected file permissions as three digits (i.e. 755) + * @param string $filePath + */ + protected function assertFilePermissions($expectedFilePerms, $filePath) + { + $actualFilePerms = (int) \substr(\sprintf('%o', \fileperms($filePath)), -3); + $this->assertEquals($expectedFilePerms, $actualFilePerms, \sprintf('File permissions for %s must be %s. Actual %s', $filePath, $expectedFilePerms, $actualFilePerms)); + } + protected function getFileOwner($filepath) + { + $this->markAsSkippedIfPosixIsMissing(); + $infos = \stat($filepath); + return ($datas = \posix_getpwuid($infos['uid'])) ? $datas['name'] : null; + } + protected function getFileGroup($filepath) + { + $this->markAsSkippedIfPosixIsMissing(); + $infos = \stat($filepath); + if ($datas = \posix_getgrgid($infos['gid'])) { + return $datas['name']; + } + $this->markTestSkipped('Unable to retrieve file group name'); + } + protected function markAsSkippedIfLinkIsMissing() + { + if (!\function_exists('link')) { + $this->markTestSkipped('link is not supported'); + } + if ('\\' === \DIRECTORY_SEPARATOR && \false === self::$linkOnWindows) { + $this->markTestSkipped('link requires "Create hard links" privilege on windows'); + } + } + protected function markAsSkippedIfSymlinkIsMissing($relative = \false) + { + if ('\\' === \DIRECTORY_SEPARATOR && \false === self::$symlinkOnWindows) { + $this->markTestSkipped('symlink requires "Create symbolic links" privilege on Windows'); + } + // https://bugs.php.net/69473 + if ($relative && '\\' === \DIRECTORY_SEPARATOR && 1 === \PHP_ZTS) { + $this->markTestSkipped('symlink does not support relative paths on thread safe Windows PHP versions'); + } + } + protected function markAsSkippedIfChmodIsMissing() + { + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('chmod is not supported on Windows'); + } + } + protected function markAsSkippedIfPosixIsMissing() + { + if (!\function_exists('posix_isatty')) { + $this->markTestSkipped('Function posix_isatty is required.'); + } + } +} diff --git a/vendor/symfony/filesystem/Tests/Fixtures/MockStream/MockStream.php b/vendor/symfony/filesystem/Tests/Fixtures/MockStream/MockStream.php index 85dc59004..f034346b4 100644 --- a/vendor/symfony/filesystem/Tests/Fixtures/MockStream/MockStream.php +++ b/vendor/symfony/filesystem/Tests/Fixtures/MockStream/MockStream.php @@ -1,44 +1,44 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests\Fixtures\MockStream; - -/** - * Mock stream class to be used with stream_wrapper_register. - * stream_wrapper_register('mock', 'Symfony\Component\Filesystem\Tests\Fixtures\MockStream\MockStream'). - */ -class MockStream -{ - /** - * Opens file or URL. - * - * @param string $path Specifies the URL that was passed to the original function - * @param string $mode The mode used to open the file, as detailed for fopen() - * @param int $options Holds additional flags set by the streams API - * @param string $opened_path If the path is opened successfully, and STREAM_USE_PATH is set in options, - * opened_path should be set to the full path of the file/resource that was actually opened - * - * @return bool - */ - public function stream_open($path, $mode, $options, &$opened_path) - { - return \true; - } - /** - * @param string $path The file path or URL to stat - * @param array $flags Holds additional flags set by the streams API - * - * @return array File stats - */ - public function url_stat($path, $flags) - { - return []; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests\Fixtures\MockStream; + +/** + * Mock stream class to be used with stream_wrapper_register. + * stream_wrapper_register('mock', 'Symfony\Component\Filesystem\Tests\Fixtures\MockStream\MockStream'). + */ +class MockStream +{ + /** + * Opens file or URL. + * + * @param string $path Specifies the URL that was passed to the original function + * @param string $mode The mode used to open the file, as detailed for fopen() + * @param int $options Holds additional flags set by the streams API + * @param string $opened_path If the path is opened successfully, and STREAM_USE_PATH is set in options, + * opened_path should be set to the full path of the file/resource that was actually opened + * + * @return bool + */ + public function stream_open($path, $mode, $options, &$opened_path) + { + return \true; + } + /** + * @param string $path The file path or URL to stat + * @param array $flags Holds additional flags set by the streams API + * + * @return array File stats + */ + public function url_stat($path, $flags) + { + return []; + } +} diff --git a/vendor/symfony/filesystem/Tests/Fixtures/MockStream/index.php b/vendor/symfony/filesystem/Tests/Fixtures/MockStream/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/filesystem/Tests/Fixtures/MockStream/index.php +++ b/vendor/symfony/filesystem/Tests/Fixtures/MockStream/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/filesystem/Tests/Fixtures/index.php b/vendor/symfony/filesystem/Tests/Fixtures/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/filesystem/Tests/Fixtures/index.php +++ b/vendor/symfony/filesystem/Tests/Fixtures/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/filesystem/Tests/LockHandlerTest.php b/vendor/symfony/filesystem/Tests/LockHandlerTest.php index b75b61cde..1737fa12a 100644 --- a/vendor/symfony/filesystem/Tests/LockHandlerTest.php +++ b/vendor/symfony/filesystem/Tests/LockHandlerTest.php @@ -1,113 +1,113 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem; -use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler; -/** - * @group legacy - */ -class LockHandlerTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testConstructWhenRepositoryDoesNotExist() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $this->expectExceptionMessage('Failed to create "/a/b/c/d/e": mkdir(): Permission denied.'); - if (!\getenv('USER') || 'root' === \getenv('USER')) { - $this->markTestSkipped('This test will fail if run under superuser'); - } - new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler('lock', '/a/b/c/d/e'); - } - public function testConstructWhenRepositoryIsNotWriteable() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); - $this->expectExceptionMessage('The directory "/" is not writable.'); - if (!\getenv('USER') || 'root' === \getenv('USER')) { - $this->markTestSkipped('This test will fail if run under superuser'); - } - new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler('lock', '/'); - } - public function testErrorHandlingInLockIfLockPathBecomesUnwritable() - { - // skip test on Windows; PHP can't easily set file as unreadable on Windows - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('This test cannot run on Windows.'); - } - if (!\getenv('USER') || 'root' === \getenv('USER')) { - $this->markTestSkipped('This test will fail if run under superuser'); - } - $lockPath = \sys_get_temp_dir() . '/' . \uniqid('', \true); - $e = null; - $wrongMessage = null; - try { - \mkdir($lockPath); - $lockHandler = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler('lock', $lockPath); - \chmod($lockPath, 0444); - $lockHandler->lock(); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException $e) { - if (\false === \strpos($e->getMessage(), 'Permission denied')) { - $wrongMessage = $e->getMessage(); - } else { - $this->addToAssertionCount(1); - } - } catch (\Exception $e) { - } catch (\Throwable $e) { - } - if (\is_dir($lockPath)) { - $fs = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem(); - $fs->remove($lockPath); - } - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException', $e, \sprintf('Expected IOException to be thrown, got %s instead.', \get_class($e))); - $this->assertNull($wrongMessage, \sprintf('Expected exception message to contain "Permission denied", got "%s" instead.', $wrongMessage)); - } - public function testConstructSanitizeName() - { - $lock = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler(''); - $file = \sprintf('%s/sf.-php-echo-hello-word-.4b3d9d0d27ddef3a78a64685dda3a963e478659a9e5240feaf7b4173a8f28d5f.lock', \sys_get_temp_dir()); - // ensure the file does not exist before the lock - @\unlink($file); - $lock->lock(); - $this->assertFileExists($file); - $lock->release(); - } - public function testLockRelease() - { - $name = 'symfony-test-filesystem.lock'; - $l1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler($name); - $l2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler($name); - $this->assertTrue($l1->lock()); - $this->assertFalse($l2->lock()); - $l1->release(); - $this->assertTrue($l2->lock()); - $l2->release(); - } - public function testLockTwice() - { - $name = 'symfony-test-filesystem.lock'; - $lockHandler = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler($name); - $this->assertTrue($lockHandler->lock()); - $this->assertTrue($lockHandler->lock()); - $lockHandler->release(); - } - public function testLockIsReleased() - { - $name = 'symfony-test-filesystem.lock'; - $l1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler($name); - $l2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler($name); - $this->assertTrue($l1->lock()); - $this->assertFalse($l2->lock()); - $l1 = null; - $this->assertTrue($l2->lock()); - $l2->release(); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem; +use _PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler; +/** + * @group legacy + */ +class LockHandlerTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testConstructWhenRepositoryDoesNotExist() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $this->expectExceptionMessage('Failed to create "/a/b/c/d/e": mkdir(): Permission denied.'); + if (!\getenv('USER') || 'root' === \getenv('USER')) { + $this->markTestSkipped('This test will fail if run under superuser'); + } + new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler('lock', '/a/b/c/d/e'); + } + public function testConstructWhenRepositoryIsNotWriteable() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException'); + $this->expectExceptionMessage('The directory "/" is not writable.'); + if (!\getenv('USER') || 'root' === \getenv('USER')) { + $this->markTestSkipped('This test will fail if run under superuser'); + } + new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler('lock', '/'); + } + public function testErrorHandlingInLockIfLockPathBecomesUnwritable() + { + // skip test on Windows; PHP can't easily set file as unreadable on Windows + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('This test cannot run on Windows.'); + } + if (!\getenv('USER') || 'root' === \getenv('USER')) { + $this->markTestSkipped('This test will fail if run under superuser'); + } + $lockPath = \sys_get_temp_dir() . '/' . \uniqid('', \true); + $e = null; + $wrongMessage = null; + try { + \mkdir($lockPath); + $lockHandler = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler('lock', $lockPath); + \chmod($lockPath, 0444); + $lockHandler->lock(); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Exception\IOException $e) { + if (\false === \strpos($e->getMessage(), 'Permission denied')) { + $wrongMessage = $e->getMessage(); + } else { + $this->addToAssertionCount(1); + } + } catch (\Exception $e) { + } catch (\Throwable $e) { + } + if (\is_dir($lockPath)) { + $fs = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\Filesystem(); + $fs->remove($lockPath); + } + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\Exception\\IOException', $e, \sprintf('Expected IOException to be thrown, got %s instead.', \get_class($e))); + $this->assertNull($wrongMessage, \sprintf('Expected exception message to contain "Permission denied", got "%s" instead.', $wrongMessage)); + } + public function testConstructSanitizeName() + { + $lock = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler(''); + $file = \sprintf('%s/sf.-php-echo-hello-word-.4b3d9d0d27ddef3a78a64685dda3a963e478659a9e5240feaf7b4173a8f28d5f.lock', \sys_get_temp_dir()); + // ensure the file does not exist before the lock + @\unlink($file); + $lock->lock(); + $this->assertFileExists($file); + $lock->release(); + } + public function testLockRelease() + { + $name = 'symfony-test-filesystem.lock'; + $l1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler($name); + $l2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler($name); + $this->assertTrue($l1->lock()); + $this->assertFalse($l2->lock()); + $l1->release(); + $this->assertTrue($l2->lock()); + $l2->release(); + } + public function testLockTwice() + { + $name = 'symfony-test-filesystem.lock'; + $lockHandler = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler($name); + $this->assertTrue($lockHandler->lock()); + $this->assertTrue($lockHandler->lock()); + $lockHandler->release(); + } + public function testLockIsReleased() + { + $name = 'symfony-test-filesystem.lock'; + $l1 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler($name); + $l2 = new \_PhpScoper5ea00cc67502b\Symfony\Component\Filesystem\LockHandler($name); + $this->assertTrue($l1->lock()); + $this->assertFalse($l2->lock()); + $l1 = null; + $this->assertTrue($l2->lock()); + $l2->release(); + } +} diff --git a/vendor/symfony/filesystem/Tests/index.php b/vendor/symfony/filesystem/Tests/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/filesystem/Tests/index.php +++ b/vendor/symfony/filesystem/Tests/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/filesystem/composer.json b/vendor/symfony/filesystem/composer.json index 4ce433a4b..525f5f09a 100644 --- a/vendor/symfony/filesystem/composer.json +++ b/vendor/symfony/filesystem/composer.json @@ -1,36 +1,36 @@ -{ - "name": "symfony\/filesystem", - "type": "library", - "description": "Symfony Filesystem Component", - "keywords": [], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": "^5.5.9|>=7.0.8", - "symfony\/polyfill-ctype": "~1.8" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\": "" - }, - "exclude-from-classmap": [ - "\/Tests\/" - ] - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - } +{ + "name": "symfony\/filesystem", + "type": "library", + "description": "Symfony Filesystem Component", + "keywords": [], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": "^5.5.9|>=7.0.8", + "symfony\/polyfill-ctype": "~1.8" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Filesystem\\": "" + }, + "exclude-from-classmap": [ + "\/Tests\/" + ] + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/filesystem/index.php b/vendor/symfony/filesystem/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/filesystem/index.php +++ b/vendor/symfony/filesystem/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/filesystem/phpunit.xml.dist b/vendor/symfony/filesystem/phpunit.xml.dist index 5515fff1a..db17673e6 100644 --- a/vendor/symfony/filesystem/phpunit.xml.dist +++ b/vendor/symfony/filesystem/phpunit.xml.dist @@ -1,30 +1,30 @@ - - - - - - - - - - ./Tests/ - - - - - - ./ - - ./Tests - ./vendor - - - - + + + + + + + + + + ./Tests/ + + + + + + ./ + + ./Tests + ./vendor + + + + diff --git a/vendor/symfony/index.php b/vendor/symfony/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/index.php +++ b/vendor/symfony/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-apcu/Apcu.php b/vendor/symfony/polyfill-apcu/Apcu.php index 7d8945edf..f5cdc37ff 100644 --- a/vendor/symfony/polyfill-apcu/Apcu.php +++ b/vendor/symfony/polyfill-apcu/Apcu.php @@ -1,91 +1,91 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu; - -/** - * Apcu for Zend Server Data Cache. - * - * @author Kate Gray - * @author Nicolas Grekas - * - * @internal - */ -final class Apcu -{ - public static function apcu_add($key, $var = null, $ttl = 0) - { - if (!\is_array($key)) { - return apc_add($key, $var, $ttl); - } - $errors = array(); - foreach ($key as $k => $v) { - if (!apc_add($k, $v, $ttl)) { - $errors[$k] = -1; - } - } - return $errors; - } - public static function apcu_store($key, $var = null, $ttl = 0) - { - if (!\is_array($key)) { - return apc_store($key, $var, $ttl); - } - $errors = array(); - foreach ($key as $k => $v) { - if (!apc_store($k, $v, $ttl)) { - $errors[$k] = -1; - } - } - return $errors; - } - public static function apcu_exists($keys) - { - if (!\is_array($keys)) { - return apc_exists($keys); - } - $existing = array(); - foreach ($keys as $k) { - if (apc_exists($k)) { - $existing[$k] = \true; - } - } - return $existing; - } - public static function apcu_fetch($key, &$success = null) - { - if (!\is_array($key)) { - return apc_fetch($key, $success); - } - $succeeded = \true; - $values = array(); - foreach ($key as $k) { - $v = apc_fetch($k, $success); - if ($success) { - $values[$k] = $v; - } else { - $succeeded = \false; - } - } - $success = $succeeded; - return $values; - } - public static function apcu_delete($key) - { - if (!\is_array($key)) { - return apc_delete($key); - } - $success = \true; - foreach ($key as $k) { - $success = apc_delete($k) && $success; - } - return $success; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu; + +/** + * Apcu for Zend Server Data Cache. + * + * @author Kate Gray + * @author Nicolas Grekas + * + * @internal + */ +final class Apcu +{ + public static function apcu_add($key, $var = null, $ttl = 0) + { + if (!\is_array($key)) { + return apc_add($key, $var, $ttl); + } + $errors = array(); + foreach ($key as $k => $v) { + if (!apc_add($k, $v, $ttl)) { + $errors[$k] = -1; + } + } + return $errors; + } + public static function apcu_store($key, $var = null, $ttl = 0) + { + if (!\is_array($key)) { + return apc_store($key, $var, $ttl); + } + $errors = array(); + foreach ($key as $k => $v) { + if (!apc_store($k, $v, $ttl)) { + $errors[$k] = -1; + } + } + return $errors; + } + public static function apcu_exists($keys) + { + if (!\is_array($keys)) { + return apc_exists($keys); + } + $existing = array(); + foreach ($keys as $k) { + if (apc_exists($k)) { + $existing[$k] = \true; + } + } + return $existing; + } + public static function apcu_fetch($key, &$success = null) + { + if (!\is_array($key)) { + return apc_fetch($key, $success); + } + $succeeded = \true; + $values = array(); + foreach ($key as $k) { + $v = apc_fetch($k, $success); + if ($success) { + $values[$k] = $v; + } else { + $succeeded = \false; + } + } + $success = $succeeded; + return $values; + } + public static function apcu_delete($key) + { + if (!\is_array($key)) { + return apc_delete($key); + } + $success = \true; + foreach ($key as $k) { + $success = apc_delete($k) && $success; + } + return $success; + } +} diff --git a/vendor/symfony/polyfill-apcu/LICENSE b/vendor/symfony/polyfill-apcu/LICENSE index 4cd8bdd30..adb8d6f64 100644 --- a/vendor/symfony/polyfill-apcu/LICENSE +++ b/vendor/symfony/polyfill-apcu/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2015-2019 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2015-2019 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/polyfill-apcu/README.md b/vendor/symfony/polyfill-apcu/README.md index e614bcab5..378340771 100644 --- a/vendor/symfony/polyfill-apcu/README.md +++ b/vendor/symfony/polyfill-apcu/README.md @@ -1,12 +1,12 @@ -Symfony Polyfill / APCu -======================== - -This component provides `apcu_*` functions and the `APCUIterator` class to users of the legacy APC extension. - -More information can be found in the -[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). - -License -======= - -This library is released under the [MIT license](LICENSE). +Symfony Polyfill / APCu +======================== + +This component provides `apcu_*` functions and the `APCUIterator` class to users of the legacy APC extension. + +More information can be found in the +[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). + +License +======= + +This library is released under the [MIT license](LICENSE). diff --git a/vendor/symfony/polyfill-apcu/bootstrap.php b/vendor/symfony/polyfill-apcu/bootstrap.php index 04d6ceb2c..81c68ef0f 100644 --- a/vendor/symfony/polyfill-apcu/bootstrap.php +++ b/vendor/symfony/polyfill-apcu/bootstrap.php @@ -1,94 +1,94 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu as p; -if (!\extension_loaded('apc') && !\extension_loaded('apcu')) { - return; -} -if (!\function_exists('_PhpScoper5ea00cc67502b\\apcu_add')) { - if (\extension_loaded('Zend Data Cache')) { - function apcu_add($key, $var = null, $ttl = 0) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu\Apcu::apcu_add($key, $var, $ttl); - } - function apcu_delete($key) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu\Apcu::apcu_delete($key); - } - function apcu_exists($keys) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu\Apcu::apcu_exists($keys); - } - function apcu_fetch($key, &$success = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu\Apcu::apcu_fetch($key, $success); - } - function apcu_store($key, $var = null, $ttl = 0) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu\Apcu::apcu_store($key, $var, $ttl); - } - } else { - function apcu_add($key, $var = null, $ttl = 0) - { - return \_PhpScoper5ea00cc67502b\apc_add($key, $var, $ttl); - } - function apcu_delete($key) - { - return \_PhpScoper5ea00cc67502b\apc_delete($key); - } - function apcu_exists($keys) - { - return \_PhpScoper5ea00cc67502b\apc_exists($keys); - } - function apcu_fetch($key, &$success = null) - { - return \_PhpScoper5ea00cc67502b\apc_fetch($key, $success); - } - function apcu_store($key, $var = null, $ttl = 0) - { - return \_PhpScoper5ea00cc67502b\apc_store($key, $var, $ttl); - } - } - function apcu_cache_info($limited = \false) - { - return \_PhpScoper5ea00cc67502b\apc_cache_info('user', $limited); - } - function apcu_cas($key, $old, $new) - { - return \_PhpScoper5ea00cc67502b\apc_cas($key, $old, $new); - } - function apcu_clear_cache() - { - return \_PhpScoper5ea00cc67502b\apc_clear_cache('user'); - } - function apcu_dec($key, $step = 1, &$success = \false) - { - return \_PhpScoper5ea00cc67502b\apc_dec($key, $step, $success); - } - function apcu_inc($key, $step = 1, &$success = \false) - { - return \_PhpScoper5ea00cc67502b\apc_inc($key, $step, $success); - } - function apcu_sma_info($limited = \false) - { - return \_PhpScoper5ea00cc67502b\apc_sma_info($limited); - } -} -if (!\class_exists('_PhpScoper5ea00cc67502b\\APCUIterator', \false) && \class_exists('_PhpScoper5ea00cc67502b\\APCIterator', \false)) { - class APCUIterator extends \_PhpScoper5ea00cc67502b\APCIterator - { - public function __construct($search = null, $format = \APC_ITER_ALL, $chunk_size = 100, $list = \APC_LIST_ACTIVE) - { - parent::__construct('user', $search, $format, $chunk_size, $list); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu as p; +if (!\extension_loaded('apc') && !\extension_loaded('apcu')) { + return; +} +if (!\function_exists('_PhpScoper5ea00cc67502b\\apcu_add')) { + if (\extension_loaded('Zend Data Cache')) { + function apcu_add($key, $var = null, $ttl = 0) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu\Apcu::apcu_add($key, $var, $ttl); + } + function apcu_delete($key) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu\Apcu::apcu_delete($key); + } + function apcu_exists($keys) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu\Apcu::apcu_exists($keys); + } + function apcu_fetch($key, &$success = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu\Apcu::apcu_fetch($key, $success); + } + function apcu_store($key, $var = null, $ttl = 0) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Apcu\Apcu::apcu_store($key, $var, $ttl); + } + } else { + function apcu_add($key, $var = null, $ttl = 0) + { + return \_PhpScoper5ea00cc67502b\apc_add($key, $var, $ttl); + } + function apcu_delete($key) + { + return \_PhpScoper5ea00cc67502b\apc_delete($key); + } + function apcu_exists($keys) + { + return \_PhpScoper5ea00cc67502b\apc_exists($keys); + } + function apcu_fetch($key, &$success = null) + { + return \_PhpScoper5ea00cc67502b\apc_fetch($key, $success); + } + function apcu_store($key, $var = null, $ttl = 0) + { + return \_PhpScoper5ea00cc67502b\apc_store($key, $var, $ttl); + } + } + function apcu_cache_info($limited = \false) + { + return \_PhpScoper5ea00cc67502b\apc_cache_info('user', $limited); + } + function apcu_cas($key, $old, $new) + { + return \_PhpScoper5ea00cc67502b\apc_cas($key, $old, $new); + } + function apcu_clear_cache() + { + return \_PhpScoper5ea00cc67502b\apc_clear_cache('user'); + } + function apcu_dec($key, $step = 1, &$success = \false) + { + return \_PhpScoper5ea00cc67502b\apc_dec($key, $step, $success); + } + function apcu_inc($key, $step = 1, &$success = \false) + { + return \_PhpScoper5ea00cc67502b\apc_inc($key, $step, $success); + } + function apcu_sma_info($limited = \false) + { + return \_PhpScoper5ea00cc67502b\apc_sma_info($limited); + } +} +if (!\class_exists('_PhpScoper5ea00cc67502b\\APCUIterator', \false) && \class_exists('_PhpScoper5ea00cc67502b\\APCIterator', \false)) { + class APCUIterator extends \_PhpScoper5ea00cc67502b\APCIterator + { + public function __construct($search = null, $format = \APC_ITER_ALL, $chunk_size = 100, $list = \APC_LIST_ACTIVE) + { + parent::__construct('user', $search, $format, $chunk_size, $list); + } + } +} diff --git a/vendor/symfony/polyfill-apcu/composer.json b/vendor/symfony/polyfill-apcu/composer.json index ffb8a5380..01b25fbaf 100644 --- a/vendor/symfony/polyfill-apcu/composer.json +++ b/vendor/symfony/polyfill-apcu/composer.json @@ -1,41 +1,41 @@ -{ - "name": "symfony\/polyfill-apcu", - "type": "library", - "description": "Symfony polyfill backporting apcu_* functions to lower PHP versions", - "keywords": [ - "polyfill", - "shim", - "compatibility", - "portable", - "apcu" - ], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": ">=5.3.3" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - } +{ + "name": "symfony\/polyfill-apcu", + "type": "library", + "description": "Symfony polyfill backporting apcu_* functions to lower PHP versions", + "keywords": [ + "polyfill", + "shim", + "compatibility", + "portable", + "apcu" + ], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": ">=5.3.3" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Apcu\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/polyfill-apcu/index.php b/vendor/symfony/polyfill-apcu/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/polyfill-apcu/index.php +++ b/vendor/symfony/polyfill-apcu/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-ctype/Ctype.php b/vendor/symfony/polyfill-ctype/Ctype.php index c3b723ce1..3fc58e562 100644 --- a/vendor/symfony/polyfill-ctype/Ctype.php +++ b/vendor/symfony/polyfill-ctype/Ctype.php @@ -1,201 +1,201 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype; - -/** - * Ctype implementation through regex. - * - * @internal - * - * @author Gert de Pagter - */ -final class Ctype -{ - /** - * Returns TRUE if every character in text is either a letter or a digit, FALSE otherwise. - * - * @see https://php.net/ctype-alnum - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_alnum($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^A-Za-z0-9]/', $text); - } - /** - * Returns TRUE if every character in text is a letter, FALSE otherwise. - * - * @see https://php.net/ctype-alpha - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_alpha($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^A-Za-z]/', $text); - } - /** - * Returns TRUE if every character in text is a control character from the current locale, FALSE otherwise. - * - * @see https://php.net/ctype-cntrl - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_cntrl($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^\\x00-\\x1f\\x7f]/', $text); - } - /** - * Returns TRUE if every character in the string text is a decimal digit, FALSE otherwise. - * - * @see https://php.net/ctype-digit - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_digit($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^0-9]/', $text); - } - /** - * Returns TRUE if every character in text is printable and actually creates visible output (no white space), FALSE otherwise. - * - * @see https://php.net/ctype-graph - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_graph($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^!-~]/', $text); - } - /** - * Returns TRUE if every character in text is a lowercase letter. - * - * @see https://php.net/ctype-lower - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_lower($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^a-z]/', $text); - } - /** - * Returns TRUE if every character in text will actually create output (including blanks). Returns FALSE if text contains control characters or characters that do not have any output or control function at all. - * - * @see https://php.net/ctype-print - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_print($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^ -~]/', $text); - } - /** - * Returns TRUE if every character in text is printable, but neither letter, digit or blank, FALSE otherwise. - * - * @see https://php.net/ctype-punct - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_punct($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^!-\\/\\:-@\\[-`\\{-~]/', $text); - } - /** - * Returns TRUE if every character in text creates some sort of white space, FALSE otherwise. Besides the blank character this also includes tab, vertical tab, line feed, carriage return and form feed characters. - * - * @see https://php.net/ctype-space - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_space($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^\\s]/', $text); - } - /** - * Returns TRUE if every character in text is an uppercase letter. - * - * @see https://php.net/ctype-upper - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_upper($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^A-Z]/', $text); - } - /** - * Returns TRUE if every character in text is a hexadecimal 'digit', that is a decimal digit or a character from [A-Fa-f] , FALSE otherwise. - * - * @see https://php.net/ctype-xdigit - * - * @param string|int $text - * - * @return bool - */ - public static function ctype_xdigit($text) - { - $text = self::convert_int_to_char_for_ctype($text); - return \is_string($text) && '' !== $text && !\preg_match('/[^A-Fa-f0-9]/', $text); - } - /** - * Converts integers to their char versions according to normal ctype behaviour, if needed. - * - * If an integer between -128 and 255 inclusive is provided, - * it is interpreted as the ASCII value of a single character - * (negative values have 256 added in order to allow characters in the Extended ASCII range). - * Any other integer is interpreted as a string containing the decimal digits of the integer. - * - * @param string|int $int - * - * @return mixed - */ - private static function convert_int_to_char_for_ctype($int) - { - if (!\is_int($int)) { - return $int; - } - if ($int < -128 || $int > 255) { - return (string) $int; - } - if ($int < 0) { - $int += 256; - } - return \chr($int); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype; + +/** + * Ctype implementation through regex. + * + * @internal + * + * @author Gert de Pagter + */ +final class Ctype +{ + /** + * Returns TRUE if every character in text is either a letter or a digit, FALSE otherwise. + * + * @see https://php.net/ctype-alnum + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_alnum($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^A-Za-z0-9]/', $text); + } + /** + * Returns TRUE if every character in text is a letter, FALSE otherwise. + * + * @see https://php.net/ctype-alpha + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_alpha($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^A-Za-z]/', $text); + } + /** + * Returns TRUE if every character in text is a control character from the current locale, FALSE otherwise. + * + * @see https://php.net/ctype-cntrl + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_cntrl($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^\\x00-\\x1f\\x7f]/', $text); + } + /** + * Returns TRUE if every character in the string text is a decimal digit, FALSE otherwise. + * + * @see https://php.net/ctype-digit + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_digit($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^0-9]/', $text); + } + /** + * Returns TRUE if every character in text is printable and actually creates visible output (no white space), FALSE otherwise. + * + * @see https://php.net/ctype-graph + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_graph($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^!-~]/', $text); + } + /** + * Returns TRUE if every character in text is a lowercase letter. + * + * @see https://php.net/ctype-lower + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_lower($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^a-z]/', $text); + } + /** + * Returns TRUE if every character in text will actually create output (including blanks). Returns FALSE if text contains control characters or characters that do not have any output or control function at all. + * + * @see https://php.net/ctype-print + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_print($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^ -~]/', $text); + } + /** + * Returns TRUE if every character in text is printable, but neither letter, digit or blank, FALSE otherwise. + * + * @see https://php.net/ctype-punct + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_punct($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^!-\\/\\:-@\\[-`\\{-~]/', $text); + } + /** + * Returns TRUE if every character in text creates some sort of white space, FALSE otherwise. Besides the blank character this also includes tab, vertical tab, line feed, carriage return and form feed characters. + * + * @see https://php.net/ctype-space + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_space($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^\\s]/', $text); + } + /** + * Returns TRUE if every character in text is an uppercase letter. + * + * @see https://php.net/ctype-upper + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_upper($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^A-Z]/', $text); + } + /** + * Returns TRUE if every character in text is a hexadecimal 'digit', that is a decimal digit or a character from [A-Fa-f] , FALSE otherwise. + * + * @see https://php.net/ctype-xdigit + * + * @param string|int $text + * + * @return bool + */ + public static function ctype_xdigit($text) + { + $text = self::convert_int_to_char_for_ctype($text); + return \is_string($text) && '' !== $text && !\preg_match('/[^A-Fa-f0-9]/', $text); + } + /** + * Converts integers to their char versions according to normal ctype behaviour, if needed. + * + * If an integer between -128 and 255 inclusive is provided, + * it is interpreted as the ASCII value of a single character + * (negative values have 256 added in order to allow characters in the Extended ASCII range). + * Any other integer is interpreted as a string containing the decimal digits of the integer. + * + * @param string|int $int + * + * @return mixed + */ + private static function convert_int_to_char_for_ctype($int) + { + if (!\is_int($int)) { + return $int; + } + if ($int < -128 || $int > 255) { + return (string) $int; + } + if ($int < 0) { + $int += 256; + } + return \chr($int); + } +} diff --git a/vendor/symfony/polyfill-ctype/LICENSE b/vendor/symfony/polyfill-ctype/LICENSE index 3f853aaf3..24807a665 100644 --- a/vendor/symfony/polyfill-ctype/LICENSE +++ b/vendor/symfony/polyfill-ctype/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2018-2019 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2018-2019 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/polyfill-ctype/README.md b/vendor/symfony/polyfill-ctype/README.md index 8add1ab00..ba8fbea53 100644 --- a/vendor/symfony/polyfill-ctype/README.md +++ b/vendor/symfony/polyfill-ctype/README.md @@ -1,12 +1,12 @@ -Symfony Polyfill / Ctype -======================== - -This component provides `ctype_*` functions to users who run php versions without the ctype extension. - -More information can be found in the -[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). - -License -======= - -This library is released under the [MIT license](LICENSE). +Symfony Polyfill / Ctype +======================== + +This component provides `ctype_*` functions to users who run php versions without the ctype extension. + +More information can be found in the +[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). + +License +======= + +This library is released under the [MIT license](LICENSE). diff --git a/vendor/symfony/polyfill-ctype/bootstrap.php b/vendor/symfony/polyfill-ctype/bootstrap.php index 124f579d0..e4524fa79 100644 --- a/vendor/symfony/polyfill-ctype/bootstrap.php +++ b/vendor/symfony/polyfill-ctype/bootstrap.php @@ -1,59 +1,59 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype as p; -if (!\function_exists('ctype_alnum')) { - function ctype_alnum($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_alnum($text); - } - function ctype_alpha($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_alpha($text); - } - function ctype_cntrl($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_cntrl($text); - } - function ctype_digit($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_digit($text); - } - function ctype_graph($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_graph($text); - } - function ctype_lower($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_lower($text); - } - function ctype_print($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_print($text); - } - function ctype_punct($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_punct($text); - } - function ctype_space($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_space($text); - } - function ctype_upper($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_upper($text); - } - function ctype_xdigit($text) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_xdigit($text); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype as p; +if (!\function_exists('ctype_alnum')) { + function ctype_alnum($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_alnum($text); + } + function ctype_alpha($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_alpha($text); + } + function ctype_cntrl($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_cntrl($text); + } + function ctype_digit($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_digit($text); + } + function ctype_graph($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_graph($text); + } + function ctype_lower($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_lower($text); + } + function ctype_print($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_print($text); + } + function ctype_punct($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_punct($text); + } + function ctype_space($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_space($text); + } + function ctype_upper($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_upper($text); + } + function ctype_xdigit($text) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Ctype\Ctype::ctype_xdigit($text); + } +} diff --git a/vendor/symfony/polyfill-ctype/composer.json b/vendor/symfony/polyfill-ctype/composer.json index e59f9f2cf..53121b207 100644 --- a/vendor/symfony/polyfill-ctype/composer.json +++ b/vendor/symfony/polyfill-ctype/composer.json @@ -1,43 +1,43 @@ -{ - "name": "symfony\/polyfill-ctype", - "type": "library", - "description": "Symfony polyfill for ctype functions", - "keywords": [ - "polyfill", - "compatibility", - "portable", - "ctype" - ], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Gert de Pagter", - "email": "BackEndTea@gmail.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": ">=5.3.3" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "suggest": { - "ext-ctype": "For best performance" - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - } +{ + "name": "symfony\/polyfill-ctype", + "type": "library", + "description": "Symfony polyfill for ctype functions", + "keywords": [ + "polyfill", + "compatibility", + "portable", + "ctype" + ], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Gert de Pagter", + "email": "BackEndTea@gmail.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": ">=5.3.3" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Ctype\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "suggest": { + "ext-ctype": "For best performance" + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/polyfill-ctype/index.php b/vendor/symfony/polyfill-ctype/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/polyfill-ctype/index.php +++ b/vendor/symfony/polyfill-ctype/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-intl-idn/Idn.php b/vendor/symfony/polyfill-intl-idn/Idn.php index b87d9fe49..a2a872adf 100644 --- a/vendor/symfony/polyfill-intl-idn/Idn.php +++ b/vendor/symfony/polyfill-intl-idn/Idn.php @@ -1,213 +1,213 @@ - - * @author Sebastian Kroczek - * @author Dmitry Lukashin - * @author Laurent Bassin - * - * @internal - */ -final class Idn -{ - const INTL_IDNA_VARIANT_2003 = 0; - const INTL_IDNA_VARIANT_UTS46 = 1; - private static $encodeTable = array('a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9'); - private static $decodeTable = array('a' => 0, 'b' => 1, 'c' => 2, 'd' => 3, 'e' => 4, 'f' => 5, 'g' => 6, 'h' => 7, 'i' => 8, 'j' => 9, 'k' => 10, 'l' => 11, 'm' => 12, 'n' => 13, 'o' => 14, 'p' => 15, 'q' => 16, 'r' => 17, 's' => 18, 't' => 19, 'u' => 20, 'v' => 21, 'w' => 22, 'x' => 23, 'y' => 24, 'z' => 25, '0' => 26, '1' => 27, '2' => 28, '3' => 29, '4' => 30, '5' => 31, '6' => 32, '7' => 33, '8' => 34, '9' => 35); - public static function idn_to_ascii($domain, $options, $variant, &$idna_info = array()) - { - if (\PHP_VERSION_ID >= 70200 && self::INTL_IDNA_VARIANT_2003 === $variant) { - @\trigger_error('idn_to_ascii(): INTL_IDNA_VARIANT_2003 is deprecated', \E_USER_DEPRECATED); - } - if (self::INTL_IDNA_VARIANT_UTS46 === $variant) { - $domain = \mb_strtolower($domain, 'utf-8'); - } - $parts = \explode('.', $domain); - foreach ($parts as $i => &$part) { - if ('' === $part && \count($parts) > 1 + $i) { - return \false; - } - if (\false === ($part = self::encodePart($part))) { - return \false; - } - } - $output = \implode('.', $parts); - $idna_info = array('result' => \strlen($output) > 255 ? \false : $output, 'isTransitionalDifferent' => \false, 'errors' => 0); - return $idna_info['result']; - } - public static function idn_to_utf8($domain, $options, $variant, &$idna_info = array()) - { - if (\PHP_VERSION_ID >= 70200 && self::INTL_IDNA_VARIANT_2003 === $variant) { - @\trigger_error('idn_to_utf8(): INTL_IDNA_VARIANT_2003 is deprecated', \E_USER_DEPRECATED); - } - $parts = \explode('.', $domain); - foreach ($parts as &$part) { - $length = \strlen($part); - if ($length < 1 || 63 < $length) { - continue; - } - if (0 !== \strpos($part, 'xn--')) { - continue; - } - $part = \substr($part, 4); - $part = self::decodePart($part); - } - $output = \implode('.', $parts); - $idna_info = array('result' => \strlen($output) > 255 ? \false : $output, 'isTransitionalDifferent' => \false, 'errors' => 0); - return $idna_info['result']; - } - private static function encodePart($input) - { - $codePoints = self::listCodePoints($input); - $n = 128; - $bias = 72; - $delta = 0; - $h = $b = \count($codePoints['basic']); - $output = ''; - foreach ($codePoints['basic'] as $code) { - $output .= mb_chr($code, 'utf-8'); - } - if ($input === $output) { - return $output; - } - if ($b > 0) { - $output .= '-'; - } - $codePoints['nonBasic'] = \array_unique($codePoints['nonBasic']); - \sort($codePoints['nonBasic']); - $i = 0; - $length = \mb_strlen($input, 'utf-8'); - while ($h < $length) { - $m = $codePoints['nonBasic'][$i++]; - $delta += ($m - $n) * ($h + 1); - $n = $m; - foreach ($codePoints['all'] as $c) { - if ($c < $n || $c < 128) { - ++$delta; - } - if ($c === $n) { - $q = $delta; - for ($k = 36;; $k += 36) { - $t = self::calculateThreshold($k, $bias); - if ($q < $t) { - break; - } - $code = $t + ($q - $t) % (36 - $t); - $output .= self::$encodeTable[$code]; - $q = ($q - $t) / (36 - $t); - } - $output .= self::$encodeTable[$q]; - $bias = self::adapt($delta, $h + 1, $h === $b); - $delta = 0; - ++$h; - } - } - ++$delta; - ++$n; - } - $output = 'xn--' . $output; - return \strlen($output) < 1 || 63 < \strlen($output) ? \false : \strtolower($output); - } - private static function listCodePoints($input) - { - $codePoints = array('all' => array(), 'basic' => array(), 'nonBasic' => array()); - $length = \mb_strlen($input, 'utf-8'); - for ($i = 0; $i < $length; ++$i) { - $char = \mb_substr($input, $i, 1, 'utf-8'); - $code = mb_ord($char, 'utf-8'); - if ($code < 128) { - $codePoints['all'][] = $codePoints['basic'][] = $code; - } else { - $codePoints['all'][] = $codePoints['nonBasic'][] = $code; - } - } - return $codePoints; - } - private static function calculateThreshold($k, $bias) - { - if ($k <= $bias + 1) { - return 1; - } - if ($k >= $bias + 26) { - return 26; - } - return $k - $bias; - } - private static function adapt($delta, $numPoints, $firstTime) - { - $delta = (int) ($firstTime ? $delta / 700 : $delta / 2); - $delta += (int) ($delta / $numPoints); - $k = 0; - while ($delta > 35 * 13) { - $delta = (int) ($delta / 35); - $k = $k + 36; - } - return $k + (int) (36 * $delta / ($delta + 38)); - } - private static function decodePart($input) - { - $n = 128; - $i = 0; - $bias = 72; - $output = ''; - $pos = \strrpos($input, '-'); - if (\false !== $pos) { - $output = \substr($input, 0, $pos++); - } else { - $pos = 0; - } - $outputLength = \strlen($output); - $inputLength = \strlen($input); - while ($pos < $inputLength) { - $oldi = $i; - $w = 1; - for ($k = 36;; $k += 36) { - $digit = self::$decodeTable[$input[$pos++]]; - $i += $digit * $w; - $t = self::calculateThreshold($k, $bias); - if ($digit < $t) { - break; - } - $w *= 36 - $t; - } - $bias = self::adapt($i - $oldi, ++$outputLength, 0 === $oldi); - $n = $n + (int) ($i / $outputLength); - $i = $i % $outputLength; - $output = \mb_substr($output, 0, $i, 'utf-8') . mb_chr($n, 'utf-8') . \mb_substr($output, $i, $outputLength - 1, 'utf-8'); - ++$i; - } - return $output; - } -} + + * @author Sebastian Kroczek + * @author Dmitry Lukashin + * @author Laurent Bassin + * + * @internal + */ +final class Idn +{ + const INTL_IDNA_VARIANT_2003 = 0; + const INTL_IDNA_VARIANT_UTS46 = 1; + private static $encodeTable = array('a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9'); + private static $decodeTable = array('a' => 0, 'b' => 1, 'c' => 2, 'd' => 3, 'e' => 4, 'f' => 5, 'g' => 6, 'h' => 7, 'i' => 8, 'j' => 9, 'k' => 10, 'l' => 11, 'm' => 12, 'n' => 13, 'o' => 14, 'p' => 15, 'q' => 16, 'r' => 17, 's' => 18, 't' => 19, 'u' => 20, 'v' => 21, 'w' => 22, 'x' => 23, 'y' => 24, 'z' => 25, '0' => 26, '1' => 27, '2' => 28, '3' => 29, '4' => 30, '5' => 31, '6' => 32, '7' => 33, '8' => 34, '9' => 35); + public static function idn_to_ascii($domain, $options, $variant, &$idna_info = array()) + { + if (\PHP_VERSION_ID >= 70200 && self::INTL_IDNA_VARIANT_2003 === $variant) { + @\trigger_error('idn_to_ascii(): INTL_IDNA_VARIANT_2003 is deprecated', \E_USER_DEPRECATED); + } + if (self::INTL_IDNA_VARIANT_UTS46 === $variant) { + $domain = \mb_strtolower($domain, 'utf-8'); + } + $parts = \explode('.', $domain); + foreach ($parts as $i => &$part) { + if ('' === $part && \count($parts) > 1 + $i) { + return \false; + } + if (\false === ($part = self::encodePart($part))) { + return \false; + } + } + $output = \implode('.', $parts); + $idna_info = array('result' => \strlen($output) > 255 ? \false : $output, 'isTransitionalDifferent' => \false, 'errors' => 0); + return $idna_info['result']; + } + public static function idn_to_utf8($domain, $options, $variant, &$idna_info = array()) + { + if (\PHP_VERSION_ID >= 70200 && self::INTL_IDNA_VARIANT_2003 === $variant) { + @\trigger_error('idn_to_utf8(): INTL_IDNA_VARIANT_2003 is deprecated', \E_USER_DEPRECATED); + } + $parts = \explode('.', $domain); + foreach ($parts as &$part) { + $length = \strlen($part); + if ($length < 1 || 63 < $length) { + continue; + } + if (0 !== \strpos($part, 'xn--')) { + continue; + } + $part = \substr($part, 4); + $part = self::decodePart($part); + } + $output = \implode('.', $parts); + $idna_info = array('result' => \strlen($output) > 255 ? \false : $output, 'isTransitionalDifferent' => \false, 'errors' => 0); + return $idna_info['result']; + } + private static function encodePart($input) + { + $codePoints = self::listCodePoints($input); + $n = 128; + $bias = 72; + $delta = 0; + $h = $b = \count($codePoints['basic']); + $output = ''; + foreach ($codePoints['basic'] as $code) { + $output .= mb_chr($code, 'utf-8'); + } + if ($input === $output) { + return $output; + } + if ($b > 0) { + $output .= '-'; + } + $codePoints['nonBasic'] = \array_unique($codePoints['nonBasic']); + \sort($codePoints['nonBasic']); + $i = 0; + $length = \mb_strlen($input, 'utf-8'); + while ($h < $length) { + $m = $codePoints['nonBasic'][$i++]; + $delta += ($m - $n) * ($h + 1); + $n = $m; + foreach ($codePoints['all'] as $c) { + if ($c < $n || $c < 128) { + ++$delta; + } + if ($c === $n) { + $q = $delta; + for ($k = 36;; $k += 36) { + $t = self::calculateThreshold($k, $bias); + if ($q < $t) { + break; + } + $code = $t + ($q - $t) % (36 - $t); + $output .= self::$encodeTable[$code]; + $q = ($q - $t) / (36 - $t); + } + $output .= self::$encodeTable[$q]; + $bias = self::adapt($delta, $h + 1, $h === $b); + $delta = 0; + ++$h; + } + } + ++$delta; + ++$n; + } + $output = 'xn--' . $output; + return \strlen($output) < 1 || 63 < \strlen($output) ? \false : \strtolower($output); + } + private static function listCodePoints($input) + { + $codePoints = array('all' => array(), 'basic' => array(), 'nonBasic' => array()); + $length = \mb_strlen($input, 'utf-8'); + for ($i = 0; $i < $length; ++$i) { + $char = \mb_substr($input, $i, 1, 'utf-8'); + $code = mb_ord($char, 'utf-8'); + if ($code < 128) { + $codePoints['all'][] = $codePoints['basic'][] = $code; + } else { + $codePoints['all'][] = $codePoints['nonBasic'][] = $code; + } + } + return $codePoints; + } + private static function calculateThreshold($k, $bias) + { + if ($k <= $bias + 1) { + return 1; + } + if ($k >= $bias + 26) { + return 26; + } + return $k - $bias; + } + private static function adapt($delta, $numPoints, $firstTime) + { + $delta = (int) ($firstTime ? $delta / 700 : $delta / 2); + $delta += (int) ($delta / $numPoints); + $k = 0; + while ($delta > 35 * 13) { + $delta = (int) ($delta / 35); + $k = $k + 36; + } + return $k + (int) (36 * $delta / ($delta + 38)); + } + private static function decodePart($input) + { + $n = 128; + $i = 0; + $bias = 72; + $output = ''; + $pos = \strrpos($input, '-'); + if (\false !== $pos) { + $output = \substr($input, 0, $pos++); + } else { + $pos = 0; + } + $outputLength = \strlen($output); + $inputLength = \strlen($input); + while ($pos < $inputLength) { + $oldi = $i; + $w = 1; + for ($k = 36;; $k += 36) { + $digit = self::$decodeTable[$input[$pos++]]; + $i += $digit * $w; + $t = self::calculateThreshold($k, $bias); + if ($digit < $t) { + break; + } + $w *= 36 - $t; + } + $bias = self::adapt($i - $oldi, ++$outputLength, 0 === $oldi); + $n = $n + (int) ($i / $outputLength); + $i = $i % $outputLength; + $output = \mb_substr($output, 0, $i, 'utf-8') . mb_chr($n, 'utf-8') . \mb_substr($output, $i, $outputLength - 1, 'utf-8'); + ++$i; + } + return $output; + } +} diff --git a/vendor/symfony/polyfill-intl-idn/LICENSE b/vendor/symfony/polyfill-intl-idn/LICENSE index 3f853aaf3..24807a665 100644 --- a/vendor/symfony/polyfill-intl-idn/LICENSE +++ b/vendor/symfony/polyfill-intl-idn/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2018-2019 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2018-2019 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/polyfill-intl-idn/README.md b/vendor/symfony/polyfill-intl-idn/README.md index 2e75f2e52..8acd57102 100644 --- a/vendor/symfony/polyfill-intl-idn/README.md +++ b/vendor/symfony/polyfill-intl-idn/README.md @@ -1,12 +1,12 @@ -Symfony Polyfill / Intl: Idn -============================ - -This component provides [`idn_to_ascii`](https://php.net/idn-to-ascii) and [`idn_to_utf8`](https://php.net/idn-to-utf8) functions to users who run php versions without the [Intl](https://php.net/intl) extension. - -More information can be found in the -[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). - -License -======= - -This library is released under the [MIT license](LICENSE). +Symfony Polyfill / Intl: Idn +============================ + +This component provides [`idn_to_ascii`](https://php.net/idn-to-ascii) and [`idn_to_utf8`](https://php.net/idn-to-utf8) functions to users who run php versions without the [Intl](https://php.net/intl) extension. + +More information can be found in the +[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). + +License +======= + +This library is released under the [MIT license](LICENSE). diff --git a/vendor/symfony/polyfill-intl-idn/bootstrap.php b/vendor/symfony/polyfill-intl-idn/bootstrap.php index fdd134bb3..3d4ef9772 100644 --- a/vendor/symfony/polyfill-intl-idn/bootstrap.php +++ b/vendor/symfony/polyfill-intl-idn/bootstrap.php @@ -1,72 +1,72 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Intl\Idn as p; -if (!\defined('IDNA_DEFAULT')) { - \define('U_IDNA_PROHIBITED_ERROR', 66560); - \define('U_IDNA_ERROR_START', 66560); - \define('U_IDNA_UNASSIGNED_ERROR', 66561); - \define('U_IDNA_CHECK_BIDI_ERROR', 66562); - \define('U_IDNA_STD3_ASCII_RULES_ERROR', 66563); - \define('U_IDNA_ACE_PREFIX_ERROR', 66564); - \define('U_IDNA_VERIFICATION_ERROR', 66565); - \define('U_IDNA_LABEL_TOO_LONG_ERROR', 66566); - \define('U_IDNA_ZERO_LENGTH_LABEL_ERROR', 66567); - \define('U_IDNA_DOMAIN_NAME_TOO_LONG_ERROR', 66568); - \define('U_IDNA_ERROR_LIMIT', 66569); - \define('U_STRINGPREP_PROHIBITED_ERROR', 66560); - \define('U_STRINGPREP_UNASSIGNED_ERROR', 66561); - \define('U_STRINGPREP_CHECK_BIDI_ERROR', 66562); - \define('IDNA_DEFAULT', 0); - \define('IDNA_ALLOW_UNASSIGNED', 1); - \define('IDNA_USE_STD3_RULES', 2); - \define('IDNA_CHECK_BIDI', 4); - \define('IDNA_CHECK_CONTEXTJ', 8); - \define('IDNA_NONTRANSITIONAL_TO_ASCII', 16); - \define('IDNA_NONTRANSITIONAL_TO_UNICODE', 32); - \define('INTL_IDNA_VARIANT_2003', 0); - \define('INTL_IDNA_VARIANT_UTS46', 1); - \define('IDNA_ERROR_EMPTY_LABEL', 1); - \define('IDNA_ERROR_LABEL_TOO_LONG', 2); - \define('IDNA_ERROR_DOMAIN_NAME_TOO_LONG', 4); - \define('IDNA_ERROR_LEADING_HYPHEN', 8); - \define('IDNA_ERROR_TRAILING_HYPHEN', 16); - \define('IDNA_ERROR_HYPHEN_3_4', 32); - \define('IDNA_ERROR_LEADING_COMBINING_MARK', 64); - \define('IDNA_ERROR_DISALLOWED', 128); - \define('IDNA_ERROR_PUNYCODE', 256); - \define('IDNA_ERROR_LABEL_HAS_DOT', 512); - \define('IDNA_ERROR_INVALID_ACE_LABEL', 1024); - \define('IDNA_ERROR_BIDI', 2048); - \define('IDNA_ERROR_CONTEXTJ', 4096); -} -if (!\function_exists('idn_to_ascii')) { - if (\PHP_VERSION_ID < 70400) { - function idn_to_ascii($domain, $options = \IDNA_DEFAULT, $variant = \INTL_IDNA_VARIANT_2003, &$idna_info = array()) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Intl\Idn\Idn::idn_to_ascii($domain, $options, $variant, $idna_info); - } - function idn_to_utf8($domain, $options = \IDNA_DEFAULT, $variant = \INTL_IDNA_VARIANT_2003, &$idna_info = array()) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Intl\Idn\Idn::idn_to_utf8($domain, $options, $variant, $idna_info); - } - } else { - function idn_to_ascii($domain, $options = \IDNA_DEFAULT, $variant = \INTL_IDNA_VARIANT_UTS46, &$idna_info = array()) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Intl\Idn\Idn::idn_to_ascii($domain, $options, $variant, $idna_info); - } - function idn_to_utf8($domain, $options = \IDNA_DEFAULT, $variant = \INTL_IDNA_VARIANT_UTS46, &$idna_info = array()) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Intl\Idn\Idn::idn_to_utf8($domain, $options, $variant, $idna_info); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Intl\Idn as p; +if (!\defined('IDNA_DEFAULT')) { + \define('U_IDNA_PROHIBITED_ERROR', 66560); + \define('U_IDNA_ERROR_START', 66560); + \define('U_IDNA_UNASSIGNED_ERROR', 66561); + \define('U_IDNA_CHECK_BIDI_ERROR', 66562); + \define('U_IDNA_STD3_ASCII_RULES_ERROR', 66563); + \define('U_IDNA_ACE_PREFIX_ERROR', 66564); + \define('U_IDNA_VERIFICATION_ERROR', 66565); + \define('U_IDNA_LABEL_TOO_LONG_ERROR', 66566); + \define('U_IDNA_ZERO_LENGTH_LABEL_ERROR', 66567); + \define('U_IDNA_DOMAIN_NAME_TOO_LONG_ERROR', 66568); + \define('U_IDNA_ERROR_LIMIT', 66569); + \define('U_STRINGPREP_PROHIBITED_ERROR', 66560); + \define('U_STRINGPREP_UNASSIGNED_ERROR', 66561); + \define('U_STRINGPREP_CHECK_BIDI_ERROR', 66562); + \define('IDNA_DEFAULT', 0); + \define('IDNA_ALLOW_UNASSIGNED', 1); + \define('IDNA_USE_STD3_RULES', 2); + \define('IDNA_CHECK_BIDI', 4); + \define('IDNA_CHECK_CONTEXTJ', 8); + \define('IDNA_NONTRANSITIONAL_TO_ASCII', 16); + \define('IDNA_NONTRANSITIONAL_TO_UNICODE', 32); + \define('INTL_IDNA_VARIANT_2003', 0); + \define('INTL_IDNA_VARIANT_UTS46', 1); + \define('IDNA_ERROR_EMPTY_LABEL', 1); + \define('IDNA_ERROR_LABEL_TOO_LONG', 2); + \define('IDNA_ERROR_DOMAIN_NAME_TOO_LONG', 4); + \define('IDNA_ERROR_LEADING_HYPHEN', 8); + \define('IDNA_ERROR_TRAILING_HYPHEN', 16); + \define('IDNA_ERROR_HYPHEN_3_4', 32); + \define('IDNA_ERROR_LEADING_COMBINING_MARK', 64); + \define('IDNA_ERROR_DISALLOWED', 128); + \define('IDNA_ERROR_PUNYCODE', 256); + \define('IDNA_ERROR_LABEL_HAS_DOT', 512); + \define('IDNA_ERROR_INVALID_ACE_LABEL', 1024); + \define('IDNA_ERROR_BIDI', 2048); + \define('IDNA_ERROR_CONTEXTJ', 4096); +} +if (!\function_exists('idn_to_ascii')) { + if (\PHP_VERSION_ID < 70400) { + function idn_to_ascii($domain, $options = \IDNA_DEFAULT, $variant = \INTL_IDNA_VARIANT_2003, &$idna_info = array()) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Intl\Idn\Idn::idn_to_ascii($domain, $options, $variant, $idna_info); + } + function idn_to_utf8($domain, $options = \IDNA_DEFAULT, $variant = \INTL_IDNA_VARIANT_2003, &$idna_info = array()) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Intl\Idn\Idn::idn_to_utf8($domain, $options, $variant, $idna_info); + } + } else { + function idn_to_ascii($domain, $options = \IDNA_DEFAULT, $variant = \INTL_IDNA_VARIANT_UTS46, &$idna_info = array()) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Intl\Idn\Idn::idn_to_ascii($domain, $options, $variant, $idna_info); + } + function idn_to_utf8($domain, $options = \IDNA_DEFAULT, $variant = \INTL_IDNA_VARIANT_UTS46, &$idna_info = array()) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Intl\Idn\Idn::idn_to_utf8($domain, $options, $variant, $idna_info); + } + } +} diff --git a/vendor/symfony/polyfill-intl-idn/composer.json b/vendor/symfony/polyfill-intl-idn/composer.json index c55c5e21d..0dd55eb58 100644 --- a/vendor/symfony/polyfill-intl-idn/composer.json +++ b/vendor/symfony/polyfill-intl-idn/composer.json @@ -1,47 +1,47 @@ -{ - "name": "symfony\/polyfill-intl-idn", - "type": "library", - "description": "Symfony polyfill for intl's idn_to_ascii and idn_to_utf8 functions", - "keywords": [ - "polyfill", - "shim", - "compatibility", - "portable", - "intl", - "idn" - ], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Laurent Bassin", - "email": "laurent@bassin.info" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": ">=5.3.3", - "symfony\/polyfill-mbstring": "^1.3", - "symfony\/polyfill-php72": "^1.10" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "suggest": { - "ext-intl": "For best performance" - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - } +{ + "name": "symfony\/polyfill-intl-idn", + "type": "library", + "description": "Symfony polyfill for intl's idn_to_ascii and idn_to_utf8 functions", + "keywords": [ + "polyfill", + "shim", + "compatibility", + "portable", + "intl", + "idn" + ], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Laurent Bassin", + "email": "laurent@bassin.info" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": ">=5.3.3", + "symfony\/polyfill-mbstring": "^1.3", + "symfony\/polyfill-php72": "^1.10" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Intl\\Idn\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "suggest": { + "ext-intl": "For best performance" + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/polyfill-intl-idn/index.php b/vendor/symfony/polyfill-intl-idn/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/polyfill-intl-idn/index.php +++ b/vendor/symfony/polyfill-intl-idn/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-mbstring/LICENSE b/vendor/symfony/polyfill-mbstring/LICENSE index 4cd8bdd30..adb8d6f64 100644 --- a/vendor/symfony/polyfill-mbstring/LICENSE +++ b/vendor/symfony/polyfill-mbstring/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2015-2019 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2015-2019 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/polyfill-mbstring/Mbstring.php b/vendor/symfony/polyfill-mbstring/Mbstring.php index e218d16ba..059fb2308 100644 --- a/vendor/symfony/polyfill-mbstring/Mbstring.php +++ b/vendor/symfony/polyfill-mbstring/Mbstring.php @@ -1,677 +1,677 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring; - -/** - * Partial mbstring implementation in PHP, iconv based, UTF-8 centric. - * - * Implemented: - * - mb_chr - Returns a specific character from its Unicode code point - * - mb_convert_encoding - Convert character encoding - * - mb_convert_variables - Convert character code in variable(s) - * - mb_decode_mimeheader - Decode string in MIME header field - * - mb_encode_mimeheader - Encode string for MIME header XXX NATIVE IMPLEMENTATION IS REALLY BUGGED - * - mb_decode_numericentity - Decode HTML numeric string reference to character - * - mb_encode_numericentity - Encode character to HTML numeric string reference - * - mb_convert_case - Perform case folding on a string - * - mb_detect_encoding - Detect character encoding - * - mb_get_info - Get internal settings of mbstring - * - mb_http_input - Detect HTTP input character encoding - * - mb_http_output - Set/Get HTTP output character encoding - * - mb_internal_encoding - Set/Get internal character encoding - * - mb_list_encodings - Returns an array of all supported encodings - * - mb_ord - Returns the Unicode code point of a character - * - mb_output_handler - Callback function converts character encoding in output buffer - * - mb_scrub - Replaces ill-formed byte sequences with substitute characters - * - mb_strlen - Get string length - * - mb_strpos - Find position of first occurrence of string in a string - * - mb_strrpos - Find position of last occurrence of a string in a string - * - mb_str_split - Convert a string to an array - * - mb_strtolower - Make a string lowercase - * - mb_strtoupper - Make a string uppercase - * - mb_substitute_character - Set/Get substitution character - * - mb_substr - Get part of string - * - mb_stripos - Finds position of first occurrence of a string within another, case insensitive - * - mb_stristr - Finds first occurrence of a string within another, case insensitive - * - mb_strrchr - Finds the last occurrence of a character in a string within another - * - mb_strrichr - Finds the last occurrence of a character in a string within another, case insensitive - * - mb_strripos - Finds position of last occurrence of a string within another, case insensitive - * - mb_strstr - Finds first occurrence of a string within another - * - mb_strwidth - Return width of string - * - mb_substr_count - Count the number of substring occurrences - * - * Not implemented: - * - mb_convert_kana - Convert "kana" one from another ("zen-kaku", "han-kaku" and more) - * - mb_ereg_* - Regular expression with multibyte support - * - mb_parse_str - Parse GET/POST/COOKIE data and set global variable - * - mb_preferred_mime_name - Get MIME charset string - * - mb_regex_encoding - Returns current encoding for multibyte regex as string - * - mb_regex_set_options - Set/Get the default options for mbregex functions - * - mb_send_mail - Send encoded mail - * - mb_split - Split multibyte string using regular expression - * - mb_strcut - Get part of string - * - mb_strimwidth - Get truncated string with specified width - * - * @author Nicolas Grekas - * - * @internal - */ -final class Mbstring -{ - const MB_CASE_FOLD = \PHP_INT_MAX; - private static $encodingList = array('ASCII', 'UTF-8'); - private static $language = 'neutral'; - private static $internalEncoding = 'UTF-8'; - private static $caseFold = array(array('µ', 'Å¿', "Í…", 'Ï‚', "Ï", "Ï‘", "Ï•", "Ï–", "Ï°", "ϱ", "ϵ", "ẛ", "á¾¾"), array('μ', 's', 'ι', 'σ', 'β', 'θ', 'φ', 'Ï€', 'κ', 'Ï', 'ε', "ṡ", 'ι')); - public static function mb_convert_encoding($s, $toEncoding, $fromEncoding = null) - { - if (\is_array($fromEncoding) || \false !== \strpos($fromEncoding, ',')) { - $fromEncoding = self::mb_detect_encoding($s, $fromEncoding); - } else { - $fromEncoding = self::getEncoding($fromEncoding); - } - $toEncoding = self::getEncoding($toEncoding); - if ('BASE64' === $fromEncoding) { - $s = \base64_decode($s); - $fromEncoding = $toEncoding; - } - if ('BASE64' === $toEncoding) { - return \base64_encode($s); - } - if ('HTML-ENTITIES' === $toEncoding || 'HTML' === $toEncoding) { - if ('HTML-ENTITIES' === $fromEncoding || 'HTML' === $fromEncoding) { - $fromEncoding = 'Windows-1252'; - } - if ('UTF-8' !== $fromEncoding) { - $s = \iconv($fromEncoding, 'UTF-8//IGNORE', $s); - } - return \preg_replace_callback('/[\\x80-\\xFF]+/', array(__CLASS__, 'html_encoding_callback'), $s); - } - if ('HTML-ENTITIES' === $fromEncoding) { - $s = \html_entity_decode($s, \ENT_COMPAT, 'UTF-8'); - $fromEncoding = 'UTF-8'; - } - return \iconv($fromEncoding, $toEncoding . '//IGNORE', $s); - } - public static function mb_convert_variables($toEncoding, $fromEncoding, &$a = null, &$b = null, &$c = null, &$d = null, &$e = null, &$f = null) - { - $vars = array(&$a, &$b, &$c, &$d, &$e, &$f); - $ok = \true; - \array_walk_recursive($vars, function (&$v) use(&$ok, $toEncoding, $fromEncoding) { - if (\false === ($v = \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_convert_encoding($v, $toEncoding, $fromEncoding))) { - $ok = \false; - } - }); - return $ok ? $fromEncoding : \false; - } - public static function mb_decode_mimeheader($s) - { - return \iconv_mime_decode($s, 2, self::$internalEncoding); - } - public static function mb_encode_mimeheader($s, $charset = null, $transferEncoding = null, $linefeed = null, $indent = null) - { - \trigger_error('mb_encode_mimeheader() is bugged. Please use iconv_mime_encode() instead', \E_USER_WARNING); - } - public static function mb_decode_numericentity($s, $convmap, $encoding = null) - { - if (null !== $s && !\is_scalar($s) && !(\is_object($s) && \method_exists($s, '__toString'))) { - \trigger_error('mb_decode_numericentity() expects parameter 1 to be string, ' . \gettype($s) . ' given', \E_USER_WARNING); - return null; - } - if (!\is_array($convmap) || !$convmap) { - return \false; - } - if (null !== $encoding && !\is_scalar($encoding)) { - \trigger_error('mb_decode_numericentity() expects parameter 3 to be string, ' . \gettype($s) . ' given', \E_USER_WARNING); - return ''; - // Instead of null (cf. mb_encode_numericentity). - } - $s = (string) $s; - if ('' === $s) { - return ''; - } - $encoding = self::getEncoding($encoding); - if ('UTF-8' === $encoding) { - $encoding = null; - if (!\preg_match('//u', $s)) { - $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s); - } - } else { - $s = \iconv($encoding, 'UTF-8//IGNORE', $s); - } - $cnt = \floor(\count($convmap) / 4) * 4; - for ($i = 0; $i < $cnt; $i += 4) { - // collector_decode_htmlnumericentity ignores $convmap[$i + 3] - $convmap[$i] += $convmap[$i + 2]; - $convmap[$i + 1] += $convmap[$i + 2]; - } - $s = \preg_replace_callback('/&#(?:0*([0-9]+)|x0*([0-9a-fA-F]+))(?!&);?/', function (array $m) use($cnt, $convmap) { - $c = isset($m[2]) ? (int) \hexdec($m[2]) : $m[1]; - for ($i = 0; $i < $cnt; $i += 4) { - if ($c >= $convmap[$i] && $c <= $convmap[$i + 1]) { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_chr($c - $convmap[$i + 2]); - } - } - return $m[0]; - }, $s); - if (null === $encoding) { - return $s; - } - return \iconv('UTF-8', $encoding . '//IGNORE', $s); - } - public static function mb_encode_numericentity($s, $convmap, $encoding = null, $is_hex = \false) - { - if (null !== $s && !\is_scalar($s) && !(\is_object($s) && \method_exists($s, '__toString'))) { - \trigger_error('mb_encode_numericentity() expects parameter 1 to be string, ' . \gettype($s) . ' given', \E_USER_WARNING); - return null; - } - if (!\is_array($convmap) || !$convmap) { - return \false; - } - if (null !== $encoding && !\is_scalar($encoding)) { - \trigger_error('mb_encode_numericentity() expects parameter 3 to be string, ' . \gettype($s) . ' given', \E_USER_WARNING); - return null; - // Instead of '' (cf. mb_decode_numericentity). - } - if (null !== $is_hex && !\is_scalar($is_hex)) { - \trigger_error('mb_encode_numericentity() expects parameter 4 to be boolean, ' . \gettype($s) . ' given', \E_USER_WARNING); - return null; - } - $s = (string) $s; - if ('' === $s) { - return ''; - } - $encoding = self::getEncoding($encoding); - if ('UTF-8' === $encoding) { - $encoding = null; - if (!\preg_match('//u', $s)) { - $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s); - } - } else { - $s = \iconv($encoding, 'UTF-8//IGNORE', $s); - } - static $ulenMask = array("À" => 2, "Ð" => 2, "à" => 3, "ð" => 4); - $cnt = \floor(\count($convmap) / 4) * 4; - $i = 0; - $len = \strlen($s); - $result = ''; - while ($i < $len) { - $ulen = $s[$i] < "€" ? 1 : $ulenMask[$s[$i] & "ð"]; - $uchr = \substr($s, $i, $ulen); - $i += $ulen; - $c = self::mb_ord($uchr); - for ($j = 0; $j < $cnt; $j += 4) { - if ($c >= $convmap[$j] && $c <= $convmap[$j + 1]) { - $cOffset = $c + $convmap[$j + 2] & $convmap[$j + 3]; - $result .= $is_hex ? \sprintf('&#x%X;', $cOffset) : '&#' . $cOffset . ';'; - continue 2; - } - } - $result .= $uchr; - } - if (null === $encoding) { - return $result; - } - return \iconv('UTF-8', $encoding . '//IGNORE', $result); - } - public static function mb_convert_case($s, $mode, $encoding = null) - { - $s = (string) $s; - if ('' === $s) { - return ''; - } - $encoding = self::getEncoding($encoding); - if ('UTF-8' === $encoding) { - $encoding = null; - if (!\preg_match('//u', $s)) { - $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s); - } - } else { - $s = \iconv($encoding, 'UTF-8//IGNORE', $s); - } - if (\MB_CASE_TITLE == $mode) { - static $titleRegexp = null; - if (null === $titleRegexp) { - $titleRegexp = self::getData('titleCaseRegexp'); - } - $s = \preg_replace_callback($titleRegexp, array(__CLASS__, 'title_case'), $s); - } else { - if (\MB_CASE_UPPER == $mode) { - static $upper = null; - if (null === $upper) { - $upper = self::getData('upperCase'); - } - $map = $upper; - } else { - if (self::MB_CASE_FOLD === $mode) { - $s = \str_replace(self::$caseFold[0], self::$caseFold[1], $s); - } - static $lower = null; - if (null === $lower) { - $lower = self::getData('lowerCase'); - } - $map = $lower; - } - static $ulenMask = array("À" => 2, "Ð" => 2, "à" => 3, "ð" => 4); - $i = 0; - $len = \strlen($s); - while ($i < $len) { - $ulen = $s[$i] < "€" ? 1 : $ulenMask[$s[$i] & "ð"]; - $uchr = \substr($s, $i, $ulen); - $i += $ulen; - if (isset($map[$uchr])) { - $uchr = $map[$uchr]; - $nlen = \strlen($uchr); - if ($nlen == $ulen) { - $nlen = $i; - do { - $s[--$nlen] = $uchr[--$ulen]; - } while ($ulen); - } else { - $s = \substr_replace($s, $uchr, $i - $ulen, $ulen); - $len += $nlen - $ulen; - $i += $nlen - $ulen; - } - } - } - } - if (null === $encoding) { - return $s; - } - return \iconv('UTF-8', $encoding . '//IGNORE', $s); - } - public static function mb_internal_encoding($encoding = null) - { - if (null === $encoding) { - return self::$internalEncoding; - } - $encoding = self::getEncoding($encoding); - if ('UTF-8' === $encoding || \false !== @\iconv($encoding, $encoding, ' ')) { - self::$internalEncoding = $encoding; - return \true; - } - return \false; - } - public static function mb_language($lang = null) - { - if (null === $lang) { - return self::$language; - } - switch ($lang = \strtolower($lang)) { - case 'uni': - case 'neutral': - self::$language = $lang; - return \true; - } - return \false; - } - public static function mb_list_encodings() - { - return array('UTF-8'); - } - public static function mb_encoding_aliases($encoding) - { - switch (\strtoupper($encoding)) { - case 'UTF8': - case 'UTF-8': - return array('utf8'); - } - return \false; - } - public static function mb_check_encoding($var = null, $encoding = null) - { - if (null === $encoding) { - if (null === $var) { - return \false; - } - $encoding = self::$internalEncoding; - } - return self::mb_detect_encoding($var, array($encoding)) || \false !== @\iconv($encoding, $encoding, $var); - } - public static function mb_detect_encoding($str, $encodingList = null, $strict = \false) - { - if (null === $encodingList) { - $encodingList = self::$encodingList; - } else { - if (!\is_array($encodingList)) { - $encodingList = \array_map('trim', \explode(',', $encodingList)); - } - $encodingList = \array_map('strtoupper', $encodingList); - } - foreach ($encodingList as $enc) { - switch ($enc) { - case 'ASCII': - if (!\preg_match('/[\\x80-\\xFF]/', $str)) { - return $enc; - } - break; - case 'UTF8': - case 'UTF-8': - if (\preg_match('//u', $str)) { - return 'UTF-8'; - } - break; - default: - if (0 === \strncmp($enc, 'ISO-8859-', 9)) { - return $enc; - } - } - } - return \false; - } - public static function mb_detect_order($encodingList = null) - { - if (null === $encodingList) { - return self::$encodingList; - } - if (!\is_array($encodingList)) { - $encodingList = \array_map('trim', \explode(',', $encodingList)); - } - $encodingList = \array_map('strtoupper', $encodingList); - foreach ($encodingList as $enc) { - switch ($enc) { - default: - if (\strncmp($enc, 'ISO-8859-', 9)) { - return \false; - } - // no break - case 'ASCII': - case 'UTF8': - case 'UTF-8': - } - } - self::$encodingList = $encodingList; - return \true; - } - public static function mb_strlen($s, $encoding = null) - { - $encoding = self::getEncoding($encoding); - if ('CP850' === $encoding || 'ASCII' === $encoding) { - return \strlen($s); - } - return @\iconv_strlen($s, $encoding); - } - public static function mb_strpos($haystack, $needle, $offset = 0, $encoding = null) - { - $encoding = self::getEncoding($encoding); - if ('CP850' === $encoding || 'ASCII' === $encoding) { - return \strpos($haystack, $needle, $offset); - } - $needle = (string) $needle; - if ('' === $needle) { - \trigger_error(__METHOD__ . ': Empty delimiter', \E_USER_WARNING); - return \false; - } - return \iconv_strpos($haystack, $needle, $offset, $encoding); - } - public static function mb_strrpos($haystack, $needle, $offset = 0, $encoding = null) - { - $encoding = self::getEncoding($encoding); - if ('CP850' === $encoding || 'ASCII' === $encoding) { - return \strrpos($haystack, $needle, $offset); - } - if ($offset != (int) $offset) { - $offset = 0; - } elseif ($offset = (int) $offset) { - if ($offset < 0) { - if (0 > ($offset += self::mb_strlen($needle))) { - $haystack = self::mb_substr($haystack, 0, $offset, $encoding); - } - $offset = 0; - } else { - $haystack = self::mb_substr($haystack, $offset, 2147483647, $encoding); - } - } - $pos = \iconv_strrpos($haystack, $needle, $encoding); - return \false !== $pos ? $offset + $pos : \false; - } - public static function mb_str_split($string, $split_length = 1, $encoding = null) - { - if (null !== $string && !\is_scalar($string) && !(\is_object($string) && \method_exists($string, '__toString'))) { - \trigger_error('mb_str_split() expects parameter 1 to be string, ' . \gettype($string) . ' given', \E_USER_WARNING); - return null; - } - if (1 > ($split_length = (int) $split_length)) { - \trigger_error('The length of each segment must be greater than zero', \E_USER_WARNING); - return \false; - } - if (null === $encoding) { - $encoding = \mb_internal_encoding(); - } - if ('UTF-8' === ($encoding = self::getEncoding($encoding))) { - $rx = '/('; - while (65535 < $split_length) { - $rx .= '.{65535}'; - $split_length -= 65535; - } - $rx .= '.{' . $split_length . '})/us'; - return \preg_split($rx, $string, null, \PREG_SPLIT_DELIM_CAPTURE | \PREG_SPLIT_NO_EMPTY); - } - $result = array(); - $length = \mb_strlen($string, $encoding); - for ($i = 0; $i < $length; $i += $split_length) { - $result[] = \mb_substr($string, $i, $split_length, $encoding); - } - return $result; - } - public static function mb_strtolower($s, $encoding = null) - { - return self::mb_convert_case($s, \MB_CASE_LOWER, $encoding); - } - public static function mb_strtoupper($s, $encoding = null) - { - return self::mb_convert_case($s, \MB_CASE_UPPER, $encoding); - } - public static function mb_substitute_character($c = null) - { - if (0 === \strcasecmp($c, 'none')) { - return \true; - } - return null !== $c ? \false : 'none'; - } - public static function mb_substr($s, $start, $length = null, $encoding = null) - { - $encoding = self::getEncoding($encoding); - if ('CP850' === $encoding || 'ASCII' === $encoding) { - return (string) \substr($s, $start, null === $length ? 2147483647 : $length); - } - if ($start < 0) { - $start = \iconv_strlen($s, $encoding) + $start; - if ($start < 0) { - $start = 0; - } - } - if (null === $length) { - $length = 2147483647; - } elseif ($length < 0) { - $length = \iconv_strlen($s, $encoding) + $length - $start; - if ($length < 0) { - return ''; - } - } - return (string) \iconv_substr($s, $start, $length, $encoding); - } - public static function mb_stripos($haystack, $needle, $offset = 0, $encoding = null) - { - $haystack = self::mb_convert_case($haystack, self::MB_CASE_FOLD, $encoding); - $needle = self::mb_convert_case($needle, self::MB_CASE_FOLD, $encoding); - return self::mb_strpos($haystack, $needle, $offset, $encoding); - } - public static function mb_stristr($haystack, $needle, $part = \false, $encoding = null) - { - $pos = self::mb_stripos($haystack, $needle, 0, $encoding); - return self::getSubpart($pos, $part, $haystack, $encoding); - } - public static function mb_strrchr($haystack, $needle, $part = \false, $encoding = null) - { - $encoding = self::getEncoding($encoding); - if ('CP850' === $encoding || 'ASCII' === $encoding) { - return \strrchr($haystack, $needle, $part); - } - $needle = self::mb_substr($needle, 0, 1, $encoding); - $pos = \iconv_strrpos($haystack, $needle, $encoding); - return self::getSubpart($pos, $part, $haystack, $encoding); - } - public static function mb_strrichr($haystack, $needle, $part = \false, $encoding = null) - { - $needle = self::mb_substr($needle, 0, 1, $encoding); - $pos = self::mb_strripos($haystack, $needle, $encoding); - return self::getSubpart($pos, $part, $haystack, $encoding); - } - public static function mb_strripos($haystack, $needle, $offset = 0, $encoding = null) - { - $haystack = self::mb_convert_case($haystack, self::MB_CASE_FOLD, $encoding); - $needle = self::mb_convert_case($needle, self::MB_CASE_FOLD, $encoding); - return self::mb_strrpos($haystack, $needle, $offset, $encoding); - } - public static function mb_strstr($haystack, $needle, $part = \false, $encoding = null) - { - $pos = \strpos($haystack, $needle); - if (\false === $pos) { - return \false; - } - if ($part) { - return \substr($haystack, 0, $pos); - } - return \substr($haystack, $pos); - } - public static function mb_get_info($type = 'all') - { - $info = array('internal_encoding' => self::$internalEncoding, 'http_output' => 'pass', 'http_output_conv_mimetypes' => '^(text/|application/xhtml\\+xml)', 'func_overload' => 0, 'func_overload_list' => 'no overload', 'mail_charset' => 'UTF-8', 'mail_header_encoding' => 'BASE64', 'mail_body_encoding' => 'BASE64', 'illegal_chars' => 0, 'encoding_translation' => 'Off', 'language' => self::$language, 'detect_order' => self::$encodingList, 'substitute_character' => 'none', 'strict_detection' => 'Off'); - if ('all' === $type) { - return $info; - } - if (isset($info[$type])) { - return $info[$type]; - } - return \false; - } - public static function mb_http_input($type = '') - { - return \false; - } - public static function mb_http_output($encoding = null) - { - return null !== $encoding ? 'pass' === $encoding : 'pass'; - } - public static function mb_strwidth($s, $encoding = null) - { - $encoding = self::getEncoding($encoding); - if ('UTF-8' !== $encoding) { - $s = \iconv($encoding, 'UTF-8//IGNORE', $s); - } - $s = \preg_replace('/[\\x{1100}-\\x{115F}\\x{2329}\\x{232A}\\x{2E80}-\\x{303E}\\x{3040}-\\x{A4CF}\\x{AC00}-\\x{D7A3}\\x{F900}-\\x{FAFF}\\x{FE10}-\\x{FE19}\\x{FE30}-\\x{FE6F}\\x{FF00}-\\x{FF60}\\x{FFE0}-\\x{FFE6}\\x{20000}-\\x{2FFFD}\\x{30000}-\\x{3FFFD}]/u', '', $s, -1, $wide); - return ($wide << 1) + \iconv_strlen($s, 'UTF-8'); - } - public static function mb_substr_count($haystack, $needle, $encoding = null) - { - return \substr_count($haystack, $needle); - } - public static function mb_output_handler($contents, $status) - { - return $contents; - } - public static function mb_chr($code, $encoding = null) - { - if (0x80 > ($code %= 0x200000)) { - $s = \chr($code); - } elseif (0x800 > $code) { - $s = \chr(0xc0 | $code >> 6) . \chr(0x80 | $code & 0x3f); - } elseif (0x10000 > $code) { - $s = \chr(0xe0 | $code >> 12) . \chr(0x80 | $code >> 6 & 0x3f) . \chr(0x80 | $code & 0x3f); - } else { - $s = \chr(0xf0 | $code >> 18) . \chr(0x80 | $code >> 12 & 0x3f) . \chr(0x80 | $code >> 6 & 0x3f) . \chr(0x80 | $code & 0x3f); - } - if ('UTF-8' !== ($encoding = self::getEncoding($encoding))) { - $s = \mb_convert_encoding($s, $encoding, 'UTF-8'); - } - return $s; - } - public static function mb_ord($s, $encoding = null) - { - if ('UTF-8' !== ($encoding = self::getEncoding($encoding))) { - $s = \mb_convert_encoding($s, 'UTF-8', $encoding); - } - if (1 === \strlen($s)) { - return \ord($s); - } - $code = ($s = \unpack('C*', \substr($s, 0, 4))) ? $s[1] : 0; - if (0xf0 <= $code) { - return ($code - 0xf0 << 18) + ($s[2] - 0x80 << 12) + ($s[3] - 0x80 << 6) + $s[4] - 0x80; - } - if (0xe0 <= $code) { - return ($code - 0xe0 << 12) + ($s[2] - 0x80 << 6) + $s[3] - 0x80; - } - if (0xc0 <= $code) { - return ($code - 0xc0 << 6) + $s[2] - 0x80; - } - return $code; - } - private static function getSubpart($pos, $part, $haystack, $encoding) - { - if (\false === $pos) { - return \false; - } - if ($part) { - return self::mb_substr($haystack, 0, $pos, $encoding); - } - return self::mb_substr($haystack, $pos, null, $encoding); - } - private static function html_encoding_callback(array $m) - { - $i = 1; - $entities = ''; - $m = \unpack('C*', \htmlentities($m[0], \ENT_COMPAT, 'UTF-8')); - while (isset($m[$i])) { - if (0x80 > $m[$i]) { - $entities .= \chr($m[$i++]); - continue; - } - if (0xf0 <= $m[$i]) { - $c = ($m[$i++] - 0xf0 << 18) + ($m[$i++] - 0x80 << 12) + ($m[$i++] - 0x80 << 6) + $m[$i++] - 0x80; - } elseif (0xe0 <= $m[$i]) { - $c = ($m[$i++] - 0xe0 << 12) + ($m[$i++] - 0x80 << 6) + $m[$i++] - 0x80; - } else { - $c = ($m[$i++] - 0xc0 << 6) + $m[$i++] - 0x80; - } - $entities .= '&#' . $c . ';'; - } - return $entities; - } - private static function title_case(array $s) - { - return self::mb_convert_case($s[1], \MB_CASE_UPPER, 'UTF-8') . self::mb_convert_case($s[2], \MB_CASE_LOWER, 'UTF-8'); - } - private static function getData($file) - { - if (\file_exists($file = __DIR__ . '/Resources/unidata/' . $file . '.php')) { - return require $file; - } - return \false; - } - private static function getEncoding($encoding) - { - if (null === $encoding) { - return self::$internalEncoding; - } - if ('UTF-8' === $encoding) { - return 'UTF-8'; - } - $encoding = \strtoupper($encoding); - if ('8BIT' === $encoding || 'BINARY' === $encoding) { - return 'CP850'; - } - if ('UTF8' === $encoding) { - return 'UTF-8'; - } - return $encoding; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring; + +/** + * Partial mbstring implementation in PHP, iconv based, UTF-8 centric. + * + * Implemented: + * - mb_chr - Returns a specific character from its Unicode code point + * - mb_convert_encoding - Convert character encoding + * - mb_convert_variables - Convert character code in variable(s) + * - mb_decode_mimeheader - Decode string in MIME header field + * - mb_encode_mimeheader - Encode string for MIME header XXX NATIVE IMPLEMENTATION IS REALLY BUGGED + * - mb_decode_numericentity - Decode HTML numeric string reference to character + * - mb_encode_numericentity - Encode character to HTML numeric string reference + * - mb_convert_case - Perform case folding on a string + * - mb_detect_encoding - Detect character encoding + * - mb_get_info - Get internal settings of mbstring + * - mb_http_input - Detect HTTP input character encoding + * - mb_http_output - Set/Get HTTP output character encoding + * - mb_internal_encoding - Set/Get internal character encoding + * - mb_list_encodings - Returns an array of all supported encodings + * - mb_ord - Returns the Unicode code point of a character + * - mb_output_handler - Callback function converts character encoding in output buffer + * - mb_scrub - Replaces ill-formed byte sequences with substitute characters + * - mb_strlen - Get string length + * - mb_strpos - Find position of first occurrence of string in a string + * - mb_strrpos - Find position of last occurrence of a string in a string + * - mb_str_split - Convert a string to an array + * - mb_strtolower - Make a string lowercase + * - mb_strtoupper - Make a string uppercase + * - mb_substitute_character - Set/Get substitution character + * - mb_substr - Get part of string + * - mb_stripos - Finds position of first occurrence of a string within another, case insensitive + * - mb_stristr - Finds first occurrence of a string within another, case insensitive + * - mb_strrchr - Finds the last occurrence of a character in a string within another + * - mb_strrichr - Finds the last occurrence of a character in a string within another, case insensitive + * - mb_strripos - Finds position of last occurrence of a string within another, case insensitive + * - mb_strstr - Finds first occurrence of a string within another + * - mb_strwidth - Return width of string + * - mb_substr_count - Count the number of substring occurrences + * + * Not implemented: + * - mb_convert_kana - Convert "kana" one from another ("zen-kaku", "han-kaku" and more) + * - mb_ereg_* - Regular expression with multibyte support + * - mb_parse_str - Parse GET/POST/COOKIE data and set global variable + * - mb_preferred_mime_name - Get MIME charset string + * - mb_regex_encoding - Returns current encoding for multibyte regex as string + * - mb_regex_set_options - Set/Get the default options for mbregex functions + * - mb_send_mail - Send encoded mail + * - mb_split - Split multibyte string using regular expression + * - mb_strcut - Get part of string + * - mb_strimwidth - Get truncated string with specified width + * + * @author Nicolas Grekas + * + * @internal + */ +final class Mbstring +{ + const MB_CASE_FOLD = \PHP_INT_MAX; + private static $encodingList = array('ASCII', 'UTF-8'); + private static $language = 'neutral'; + private static $internalEncoding = 'UTF-8'; + private static $caseFold = array(array('µ', 'Å¿', "Í…", 'Ï‚', "Ï", "Ï‘", "Ï•", "Ï–", "Ï°", "ϱ", "ϵ", "ẛ", "á¾¾"), array('μ', 's', 'ι', 'σ', 'β', 'θ', 'φ', 'Ï€', 'κ', 'Ï', 'ε', "ṡ", 'ι')); + public static function mb_convert_encoding($s, $toEncoding, $fromEncoding = null) + { + if (\is_array($fromEncoding) || \false !== \strpos($fromEncoding, ',')) { + $fromEncoding = self::mb_detect_encoding($s, $fromEncoding); + } else { + $fromEncoding = self::getEncoding($fromEncoding); + } + $toEncoding = self::getEncoding($toEncoding); + if ('BASE64' === $fromEncoding) { + $s = \base64_decode($s); + $fromEncoding = $toEncoding; + } + if ('BASE64' === $toEncoding) { + return \base64_encode($s); + } + if ('HTML-ENTITIES' === $toEncoding || 'HTML' === $toEncoding) { + if ('HTML-ENTITIES' === $fromEncoding || 'HTML' === $fromEncoding) { + $fromEncoding = 'Windows-1252'; + } + if ('UTF-8' !== $fromEncoding) { + $s = \iconv($fromEncoding, 'UTF-8//IGNORE', $s); + } + return \preg_replace_callback('/[\\x80-\\xFF]+/', array(__CLASS__, 'html_encoding_callback'), $s); + } + if ('HTML-ENTITIES' === $fromEncoding) { + $s = \html_entity_decode($s, \ENT_COMPAT, 'UTF-8'); + $fromEncoding = 'UTF-8'; + } + return \iconv($fromEncoding, $toEncoding . '//IGNORE', $s); + } + public static function mb_convert_variables($toEncoding, $fromEncoding, &$a = null, &$b = null, &$c = null, &$d = null, &$e = null, &$f = null) + { + $vars = array(&$a, &$b, &$c, &$d, &$e, &$f); + $ok = \true; + \array_walk_recursive($vars, function (&$v) use(&$ok, $toEncoding, $fromEncoding) { + if (\false === ($v = \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_convert_encoding($v, $toEncoding, $fromEncoding))) { + $ok = \false; + } + }); + return $ok ? $fromEncoding : \false; + } + public static function mb_decode_mimeheader($s) + { + return \iconv_mime_decode($s, 2, self::$internalEncoding); + } + public static function mb_encode_mimeheader($s, $charset = null, $transferEncoding = null, $linefeed = null, $indent = null) + { + \trigger_error('mb_encode_mimeheader() is bugged. Please use iconv_mime_encode() instead', \E_USER_WARNING); + } + public static function mb_decode_numericentity($s, $convmap, $encoding = null) + { + if (null !== $s && !\is_scalar($s) && !(\is_object($s) && \method_exists($s, '__toString'))) { + \trigger_error('mb_decode_numericentity() expects parameter 1 to be string, ' . \gettype($s) . ' given', \E_USER_WARNING); + return null; + } + if (!\is_array($convmap) || !$convmap) { + return \false; + } + if (null !== $encoding && !\is_scalar($encoding)) { + \trigger_error('mb_decode_numericentity() expects parameter 3 to be string, ' . \gettype($s) . ' given', \E_USER_WARNING); + return ''; + // Instead of null (cf. mb_encode_numericentity). + } + $s = (string) $s; + if ('' === $s) { + return ''; + } + $encoding = self::getEncoding($encoding); + if ('UTF-8' === $encoding) { + $encoding = null; + if (!\preg_match('//u', $s)) { + $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s); + } + } else { + $s = \iconv($encoding, 'UTF-8//IGNORE', $s); + } + $cnt = \floor(\count($convmap) / 4) * 4; + for ($i = 0; $i < $cnt; $i += 4) { + // collector_decode_htmlnumericentity ignores $convmap[$i + 3] + $convmap[$i] += $convmap[$i + 2]; + $convmap[$i + 1] += $convmap[$i + 2]; + } + $s = \preg_replace_callback('/&#(?:0*([0-9]+)|x0*([0-9a-fA-F]+))(?!&);?/', function (array $m) use($cnt, $convmap) { + $c = isset($m[2]) ? (int) \hexdec($m[2]) : $m[1]; + for ($i = 0; $i < $cnt; $i += 4) { + if ($c >= $convmap[$i] && $c <= $convmap[$i + 1]) { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_chr($c - $convmap[$i + 2]); + } + } + return $m[0]; + }, $s); + if (null === $encoding) { + return $s; + } + return \iconv('UTF-8', $encoding . '//IGNORE', $s); + } + public static function mb_encode_numericentity($s, $convmap, $encoding = null, $is_hex = \false) + { + if (null !== $s && !\is_scalar($s) && !(\is_object($s) && \method_exists($s, '__toString'))) { + \trigger_error('mb_encode_numericentity() expects parameter 1 to be string, ' . \gettype($s) . ' given', \E_USER_WARNING); + return null; + } + if (!\is_array($convmap) || !$convmap) { + return \false; + } + if (null !== $encoding && !\is_scalar($encoding)) { + \trigger_error('mb_encode_numericentity() expects parameter 3 to be string, ' . \gettype($s) . ' given', \E_USER_WARNING); + return null; + // Instead of '' (cf. mb_decode_numericentity). + } + if (null !== $is_hex && !\is_scalar($is_hex)) { + \trigger_error('mb_encode_numericentity() expects parameter 4 to be boolean, ' . \gettype($s) . ' given', \E_USER_WARNING); + return null; + } + $s = (string) $s; + if ('' === $s) { + return ''; + } + $encoding = self::getEncoding($encoding); + if ('UTF-8' === $encoding) { + $encoding = null; + if (!\preg_match('//u', $s)) { + $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s); + } + } else { + $s = \iconv($encoding, 'UTF-8//IGNORE', $s); + } + static $ulenMask = array("À" => 2, "Ð" => 2, "à" => 3, "ð" => 4); + $cnt = \floor(\count($convmap) / 4) * 4; + $i = 0; + $len = \strlen($s); + $result = ''; + while ($i < $len) { + $ulen = $s[$i] < "€" ? 1 : $ulenMask[$s[$i] & "ð"]; + $uchr = \substr($s, $i, $ulen); + $i += $ulen; + $c = self::mb_ord($uchr); + for ($j = 0; $j < $cnt; $j += 4) { + if ($c >= $convmap[$j] && $c <= $convmap[$j + 1]) { + $cOffset = $c + $convmap[$j + 2] & $convmap[$j + 3]; + $result .= $is_hex ? \sprintf('&#x%X;', $cOffset) : '&#' . $cOffset . ';'; + continue 2; + } + } + $result .= $uchr; + } + if (null === $encoding) { + return $result; + } + return \iconv('UTF-8', $encoding . '//IGNORE', $result); + } + public static function mb_convert_case($s, $mode, $encoding = null) + { + $s = (string) $s; + if ('' === $s) { + return ''; + } + $encoding = self::getEncoding($encoding); + if ('UTF-8' === $encoding) { + $encoding = null; + if (!\preg_match('//u', $s)) { + $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s); + } + } else { + $s = \iconv($encoding, 'UTF-8//IGNORE', $s); + } + if (\MB_CASE_TITLE == $mode) { + static $titleRegexp = null; + if (null === $titleRegexp) { + $titleRegexp = self::getData('titleCaseRegexp'); + } + $s = \preg_replace_callback($titleRegexp, array(__CLASS__, 'title_case'), $s); + } else { + if (\MB_CASE_UPPER == $mode) { + static $upper = null; + if (null === $upper) { + $upper = self::getData('upperCase'); + } + $map = $upper; + } else { + if (self::MB_CASE_FOLD === $mode) { + $s = \str_replace(self::$caseFold[0], self::$caseFold[1], $s); + } + static $lower = null; + if (null === $lower) { + $lower = self::getData('lowerCase'); + } + $map = $lower; + } + static $ulenMask = array("À" => 2, "Ð" => 2, "à" => 3, "ð" => 4); + $i = 0; + $len = \strlen($s); + while ($i < $len) { + $ulen = $s[$i] < "€" ? 1 : $ulenMask[$s[$i] & "ð"]; + $uchr = \substr($s, $i, $ulen); + $i += $ulen; + if (isset($map[$uchr])) { + $uchr = $map[$uchr]; + $nlen = \strlen($uchr); + if ($nlen == $ulen) { + $nlen = $i; + do { + $s[--$nlen] = $uchr[--$ulen]; + } while ($ulen); + } else { + $s = \substr_replace($s, $uchr, $i - $ulen, $ulen); + $len += $nlen - $ulen; + $i += $nlen - $ulen; + } + } + } + } + if (null === $encoding) { + return $s; + } + return \iconv('UTF-8', $encoding . '//IGNORE', $s); + } + public static function mb_internal_encoding($encoding = null) + { + if (null === $encoding) { + return self::$internalEncoding; + } + $encoding = self::getEncoding($encoding); + if ('UTF-8' === $encoding || \false !== @\iconv($encoding, $encoding, ' ')) { + self::$internalEncoding = $encoding; + return \true; + } + return \false; + } + public static function mb_language($lang = null) + { + if (null === $lang) { + return self::$language; + } + switch ($lang = \strtolower($lang)) { + case 'uni': + case 'neutral': + self::$language = $lang; + return \true; + } + return \false; + } + public static function mb_list_encodings() + { + return array('UTF-8'); + } + public static function mb_encoding_aliases($encoding) + { + switch (\strtoupper($encoding)) { + case 'UTF8': + case 'UTF-8': + return array('utf8'); + } + return \false; + } + public static function mb_check_encoding($var = null, $encoding = null) + { + if (null === $encoding) { + if (null === $var) { + return \false; + } + $encoding = self::$internalEncoding; + } + return self::mb_detect_encoding($var, array($encoding)) || \false !== @\iconv($encoding, $encoding, $var); + } + public static function mb_detect_encoding($str, $encodingList = null, $strict = \false) + { + if (null === $encodingList) { + $encodingList = self::$encodingList; + } else { + if (!\is_array($encodingList)) { + $encodingList = \array_map('trim', \explode(',', $encodingList)); + } + $encodingList = \array_map('strtoupper', $encodingList); + } + foreach ($encodingList as $enc) { + switch ($enc) { + case 'ASCII': + if (!\preg_match('/[\\x80-\\xFF]/', $str)) { + return $enc; + } + break; + case 'UTF8': + case 'UTF-8': + if (\preg_match('//u', $str)) { + return 'UTF-8'; + } + break; + default: + if (0 === \strncmp($enc, 'ISO-8859-', 9)) { + return $enc; + } + } + } + return \false; + } + public static function mb_detect_order($encodingList = null) + { + if (null === $encodingList) { + return self::$encodingList; + } + if (!\is_array($encodingList)) { + $encodingList = \array_map('trim', \explode(',', $encodingList)); + } + $encodingList = \array_map('strtoupper', $encodingList); + foreach ($encodingList as $enc) { + switch ($enc) { + default: + if (\strncmp($enc, 'ISO-8859-', 9)) { + return \false; + } + // no break + case 'ASCII': + case 'UTF8': + case 'UTF-8': + } + } + self::$encodingList = $encodingList; + return \true; + } + public static function mb_strlen($s, $encoding = null) + { + $encoding = self::getEncoding($encoding); + if ('CP850' === $encoding || 'ASCII' === $encoding) { + return \strlen($s); + } + return @\iconv_strlen($s, $encoding); + } + public static function mb_strpos($haystack, $needle, $offset = 0, $encoding = null) + { + $encoding = self::getEncoding($encoding); + if ('CP850' === $encoding || 'ASCII' === $encoding) { + return \strpos($haystack, $needle, $offset); + } + $needle = (string) $needle; + if ('' === $needle) { + \trigger_error(__METHOD__ . ': Empty delimiter', \E_USER_WARNING); + return \false; + } + return \iconv_strpos($haystack, $needle, $offset, $encoding); + } + public static function mb_strrpos($haystack, $needle, $offset = 0, $encoding = null) + { + $encoding = self::getEncoding($encoding); + if ('CP850' === $encoding || 'ASCII' === $encoding) { + return \strrpos($haystack, $needle, $offset); + } + if ($offset != (int) $offset) { + $offset = 0; + } elseif ($offset = (int) $offset) { + if ($offset < 0) { + if (0 > ($offset += self::mb_strlen($needle))) { + $haystack = self::mb_substr($haystack, 0, $offset, $encoding); + } + $offset = 0; + } else { + $haystack = self::mb_substr($haystack, $offset, 2147483647, $encoding); + } + } + $pos = \iconv_strrpos($haystack, $needle, $encoding); + return \false !== $pos ? $offset + $pos : \false; + } + public static function mb_str_split($string, $split_length = 1, $encoding = null) + { + if (null !== $string && !\is_scalar($string) && !(\is_object($string) && \method_exists($string, '__toString'))) { + \trigger_error('mb_str_split() expects parameter 1 to be string, ' . \gettype($string) . ' given', \E_USER_WARNING); + return null; + } + if (1 > ($split_length = (int) $split_length)) { + \trigger_error('The length of each segment must be greater than zero', \E_USER_WARNING); + return \false; + } + if (null === $encoding) { + $encoding = \mb_internal_encoding(); + } + if ('UTF-8' === ($encoding = self::getEncoding($encoding))) { + $rx = '/('; + while (65535 < $split_length) { + $rx .= '.{65535}'; + $split_length -= 65535; + } + $rx .= '.{' . $split_length . '})/us'; + return \preg_split($rx, $string, null, \PREG_SPLIT_DELIM_CAPTURE | \PREG_SPLIT_NO_EMPTY); + } + $result = array(); + $length = \mb_strlen($string, $encoding); + for ($i = 0; $i < $length; $i += $split_length) { + $result[] = \mb_substr($string, $i, $split_length, $encoding); + } + return $result; + } + public static function mb_strtolower($s, $encoding = null) + { + return self::mb_convert_case($s, \MB_CASE_LOWER, $encoding); + } + public static function mb_strtoupper($s, $encoding = null) + { + return self::mb_convert_case($s, \MB_CASE_UPPER, $encoding); + } + public static function mb_substitute_character($c = null) + { + if (0 === \strcasecmp($c, 'none')) { + return \true; + } + return null !== $c ? \false : 'none'; + } + public static function mb_substr($s, $start, $length = null, $encoding = null) + { + $encoding = self::getEncoding($encoding); + if ('CP850' === $encoding || 'ASCII' === $encoding) { + return (string) \substr($s, $start, null === $length ? 2147483647 : $length); + } + if ($start < 0) { + $start = \iconv_strlen($s, $encoding) + $start; + if ($start < 0) { + $start = 0; + } + } + if (null === $length) { + $length = 2147483647; + } elseif ($length < 0) { + $length = \iconv_strlen($s, $encoding) + $length - $start; + if ($length < 0) { + return ''; + } + } + return (string) \iconv_substr($s, $start, $length, $encoding); + } + public static function mb_stripos($haystack, $needle, $offset = 0, $encoding = null) + { + $haystack = self::mb_convert_case($haystack, self::MB_CASE_FOLD, $encoding); + $needle = self::mb_convert_case($needle, self::MB_CASE_FOLD, $encoding); + return self::mb_strpos($haystack, $needle, $offset, $encoding); + } + public static function mb_stristr($haystack, $needle, $part = \false, $encoding = null) + { + $pos = self::mb_stripos($haystack, $needle, 0, $encoding); + return self::getSubpart($pos, $part, $haystack, $encoding); + } + public static function mb_strrchr($haystack, $needle, $part = \false, $encoding = null) + { + $encoding = self::getEncoding($encoding); + if ('CP850' === $encoding || 'ASCII' === $encoding) { + return \strrchr($haystack, $needle, $part); + } + $needle = self::mb_substr($needle, 0, 1, $encoding); + $pos = \iconv_strrpos($haystack, $needle, $encoding); + return self::getSubpart($pos, $part, $haystack, $encoding); + } + public static function mb_strrichr($haystack, $needle, $part = \false, $encoding = null) + { + $needle = self::mb_substr($needle, 0, 1, $encoding); + $pos = self::mb_strripos($haystack, $needle, $encoding); + return self::getSubpart($pos, $part, $haystack, $encoding); + } + public static function mb_strripos($haystack, $needle, $offset = 0, $encoding = null) + { + $haystack = self::mb_convert_case($haystack, self::MB_CASE_FOLD, $encoding); + $needle = self::mb_convert_case($needle, self::MB_CASE_FOLD, $encoding); + return self::mb_strrpos($haystack, $needle, $offset, $encoding); + } + public static function mb_strstr($haystack, $needle, $part = \false, $encoding = null) + { + $pos = \strpos($haystack, $needle); + if (\false === $pos) { + return \false; + } + if ($part) { + return \substr($haystack, 0, $pos); + } + return \substr($haystack, $pos); + } + public static function mb_get_info($type = 'all') + { + $info = array('internal_encoding' => self::$internalEncoding, 'http_output' => 'pass', 'http_output_conv_mimetypes' => '^(text/|application/xhtml\\+xml)', 'func_overload' => 0, 'func_overload_list' => 'no overload', 'mail_charset' => 'UTF-8', 'mail_header_encoding' => 'BASE64', 'mail_body_encoding' => 'BASE64', 'illegal_chars' => 0, 'encoding_translation' => 'Off', 'language' => self::$language, 'detect_order' => self::$encodingList, 'substitute_character' => 'none', 'strict_detection' => 'Off'); + if ('all' === $type) { + return $info; + } + if (isset($info[$type])) { + return $info[$type]; + } + return \false; + } + public static function mb_http_input($type = '') + { + return \false; + } + public static function mb_http_output($encoding = null) + { + return null !== $encoding ? 'pass' === $encoding : 'pass'; + } + public static function mb_strwidth($s, $encoding = null) + { + $encoding = self::getEncoding($encoding); + if ('UTF-8' !== $encoding) { + $s = \iconv($encoding, 'UTF-8//IGNORE', $s); + } + $s = \preg_replace('/[\\x{1100}-\\x{115F}\\x{2329}\\x{232A}\\x{2E80}-\\x{303E}\\x{3040}-\\x{A4CF}\\x{AC00}-\\x{D7A3}\\x{F900}-\\x{FAFF}\\x{FE10}-\\x{FE19}\\x{FE30}-\\x{FE6F}\\x{FF00}-\\x{FF60}\\x{FFE0}-\\x{FFE6}\\x{20000}-\\x{2FFFD}\\x{30000}-\\x{3FFFD}]/u', '', $s, -1, $wide); + return ($wide << 1) + \iconv_strlen($s, 'UTF-8'); + } + public static function mb_substr_count($haystack, $needle, $encoding = null) + { + return \substr_count($haystack, $needle); + } + public static function mb_output_handler($contents, $status) + { + return $contents; + } + public static function mb_chr($code, $encoding = null) + { + if (0x80 > ($code %= 0x200000)) { + $s = \chr($code); + } elseif (0x800 > $code) { + $s = \chr(0xc0 | $code >> 6) . \chr(0x80 | $code & 0x3f); + } elseif (0x10000 > $code) { + $s = \chr(0xe0 | $code >> 12) . \chr(0x80 | $code >> 6 & 0x3f) . \chr(0x80 | $code & 0x3f); + } else { + $s = \chr(0xf0 | $code >> 18) . \chr(0x80 | $code >> 12 & 0x3f) . \chr(0x80 | $code >> 6 & 0x3f) . \chr(0x80 | $code & 0x3f); + } + if ('UTF-8' !== ($encoding = self::getEncoding($encoding))) { + $s = \mb_convert_encoding($s, $encoding, 'UTF-8'); + } + return $s; + } + public static function mb_ord($s, $encoding = null) + { + if ('UTF-8' !== ($encoding = self::getEncoding($encoding))) { + $s = \mb_convert_encoding($s, 'UTF-8', $encoding); + } + if (1 === \strlen($s)) { + return \ord($s); + } + $code = ($s = \unpack('C*', \substr($s, 0, 4))) ? $s[1] : 0; + if (0xf0 <= $code) { + return ($code - 0xf0 << 18) + ($s[2] - 0x80 << 12) + ($s[3] - 0x80 << 6) + $s[4] - 0x80; + } + if (0xe0 <= $code) { + return ($code - 0xe0 << 12) + ($s[2] - 0x80 << 6) + $s[3] - 0x80; + } + if (0xc0 <= $code) { + return ($code - 0xc0 << 6) + $s[2] - 0x80; + } + return $code; + } + private static function getSubpart($pos, $part, $haystack, $encoding) + { + if (\false === $pos) { + return \false; + } + if ($part) { + return self::mb_substr($haystack, 0, $pos, $encoding); + } + return self::mb_substr($haystack, $pos, null, $encoding); + } + private static function html_encoding_callback(array $m) + { + $i = 1; + $entities = ''; + $m = \unpack('C*', \htmlentities($m[0], \ENT_COMPAT, 'UTF-8')); + while (isset($m[$i])) { + if (0x80 > $m[$i]) { + $entities .= \chr($m[$i++]); + continue; + } + if (0xf0 <= $m[$i]) { + $c = ($m[$i++] - 0xf0 << 18) + ($m[$i++] - 0x80 << 12) + ($m[$i++] - 0x80 << 6) + $m[$i++] - 0x80; + } elseif (0xe0 <= $m[$i]) { + $c = ($m[$i++] - 0xe0 << 12) + ($m[$i++] - 0x80 << 6) + $m[$i++] - 0x80; + } else { + $c = ($m[$i++] - 0xc0 << 6) + $m[$i++] - 0x80; + } + $entities .= '&#' . $c . ';'; + } + return $entities; + } + private static function title_case(array $s) + { + return self::mb_convert_case($s[1], \MB_CASE_UPPER, 'UTF-8') . self::mb_convert_case($s[2], \MB_CASE_LOWER, 'UTF-8'); + } + private static function getData($file) + { + if (\file_exists($file = __DIR__ . '/Resources/unidata/' . $file . '.php')) { + return require $file; + } + return \false; + } + private static function getEncoding($encoding) + { + if (null === $encoding) { + return self::$internalEncoding; + } + if ('UTF-8' === $encoding) { + return 'UTF-8'; + } + $encoding = \strtoupper($encoding); + if ('8BIT' === $encoding || 'BINARY' === $encoding) { + return 'CP850'; + } + if ('UTF8' === $encoding) { + return 'UTF-8'; + } + return $encoding; + } +} diff --git a/vendor/symfony/polyfill-mbstring/README.md b/vendor/symfony/polyfill-mbstring/README.md index 4efb599d8..6dc3d123e 100644 --- a/vendor/symfony/polyfill-mbstring/README.md +++ b/vendor/symfony/polyfill-mbstring/README.md @@ -1,13 +1,13 @@ -Symfony Polyfill / Mbstring -=========================== - -This component provides a partial, native PHP implementation for the -[Mbstring](https://php.net/mbstring) extension. - -More information can be found in the -[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). - -License -======= - -This library is released under the [MIT license](LICENSE). +Symfony Polyfill / Mbstring +=========================== + +This component provides a partial, native PHP implementation for the +[Mbstring](https://php.net/mbstring) extension. + +More information can be found in the +[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). + +License +======= + +This library is released under the [MIT license](LICENSE). diff --git a/vendor/symfony/polyfill-mbstring/Resources/index.php b/vendor/symfony/polyfill-mbstring/Resources/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/polyfill-mbstring/Resources/index.php +++ b/vendor/symfony/polyfill-mbstring/Resources/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-mbstring/Resources/unidata/index.php b/vendor/symfony/polyfill-mbstring/Resources/unidata/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/polyfill-mbstring/Resources/unidata/index.php +++ b/vendor/symfony/polyfill-mbstring/Resources/unidata/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-mbstring/Resources/unidata/lowerCase.php b/vendor/symfony/polyfill-mbstring/Resources/unidata/lowerCase.php index f176f0e8a..df048692a 100644 --- a/vendor/symfony/polyfill-mbstring/Resources/unidata/lowerCase.php +++ b/vendor/symfony/polyfill-mbstring/Resources/unidata/lowerCase.php @@ -1,5 +1,5 @@ - 'a', 'B' => 'b', 'C' => 'c', 'D' => 'd', 'E' => 'e', 'F' => 'f', 'G' => 'g', 'H' => 'h', 'I' => 'i', 'J' => 'j', 'K' => 'k', 'L' => 'l', 'M' => 'm', 'N' => 'n', 'O' => 'o', 'P' => 'p', 'Q' => 'q', 'R' => 'r', 'S' => 's', 'T' => 't', 'U' => 'u', 'V' => 'v', 'W' => 'w', 'X' => 'x', 'Y' => 'y', 'Z' => 'z', 'À' => 'à', 'Ã' => 'á', 'Â' => 'â', 'Ã' => 'ã', 'Ä' => 'ä', 'Ã…' => 'Ã¥', 'Æ' => 'æ', 'Ç' => 'ç', 'È' => 'è', 'É' => 'é', 'Ê' => 'ê', 'Ë' => 'ë', 'ÃŒ' => 'ì', 'Ã' => 'í', 'ÃŽ' => 'î', 'Ã' => 'ï', 'Ã' => 'ð', 'Ñ' => 'ñ', 'Ã’' => 'ò', 'Ó' => 'ó', 'Ô' => 'ô', 'Õ' => 'õ', 'Ö' => 'ö', 'Ø' => 'ø', 'Ù' => 'ù', 'Ú' => 'ú', 'Û' => 'û', 'Ãœ' => 'ü', 'Ã' => 'ý', 'Þ' => 'þ', 'Ä€' => 'Ä', 'Ä‚' => 'ă', 'Ä„' => 'Ä…', 'Ć' => 'ć', 'Ĉ' => 'ĉ', 'ÄŠ' => 'Ä‹', 'ÄŒ' => 'Ä', 'ÄŽ' => 'Ä', 'Ä' => 'Ä‘', 'Ä’' => 'Ä“', 'Ä”' => 'Ä•', 'Ä–' => 'Ä—', 'Ę' => 'Ä™', 'Äš' => 'Ä›', 'Äœ' => 'Ä', 'Äž' => 'ÄŸ', 'Ä ' => 'Ä¡', 'Ä¢' => 'Ä£', 'Ĥ' => 'Ä¥', 'Ħ' => 'ħ', 'Ĩ' => 'Ä©', 'Ī' => 'Ä«', 'Ĭ' => 'Ä­', 'Ä®' => 'į', 'Ä°' => 'i', 'IJ' => 'ij', 'Ä´' => 'ĵ', 'Ķ' => 'Ä·', 'Ĺ' => 'ĺ', 'Ä»' => 'ļ', 'Ľ' => 'ľ', 'Ä¿' => 'Å€', 'Å' => 'Å‚', 'Ń' => 'Å„', 'Å…' => 'ņ', 'Ň' => 'ň', 'ÅŠ' => 'Å‹', 'ÅŒ' => 'Å', 'ÅŽ' => 'Å', 'Å' => 'Å‘', 'Å’' => 'Å“', 'Å”' => 'Å•', 'Å–' => 'Å—', 'Ř' => 'Å™', 'Åš' => 'Å›', 'Åœ' => 'Å', 'Åž' => 'ÅŸ', 'Å ' => 'Å¡', 'Å¢' => 'Å£', 'Ť' => 'Å¥', 'Ŧ' => 'ŧ', 'Ũ' => 'Å©', 'Ū' => 'Å«', 'Ŭ' => 'Å­', 'Å®' => 'ů', 'Å°' => 'ű', 'Ų' => 'ų', 'Å´' => 'ŵ', 'Ŷ' => 'Å·', 'Ÿ' => 'ÿ', 'Ź' => 'ź', 'Å»' => 'ż', 'Ž' => 'ž', 'Æ' => 'É“', 'Æ‚' => 'ƃ', 'Æ„' => 'Æ…', 'Ɔ' => 'É”', 'Ƈ' => 'ƈ', 'Ɖ' => 'É–', 'ÆŠ' => 'É—', 'Æ‹' => 'ÆŒ', 'ÆŽ' => 'Ç', 'Æ' => 'É™', 'Æ' => 'É›', 'Æ‘' => 'Æ’', 'Æ“' => 'É ', 'Æ”' => 'É£', 'Æ–' => 'É©', 'Æ—' => 'ɨ', 'Ƙ' => 'Æ™', 'Æœ' => 'ɯ', 'Æ' => 'ɲ', 'ÆŸ' => 'ɵ', 'Æ ' => 'Æ¡', 'Æ¢' => 'Æ£', 'Ƥ' => 'Æ¥', 'Ʀ' => 'Ê€', 'Ƨ' => 'ƨ', 'Æ©' => 'ʃ', 'Ƭ' => 'Æ­', 'Æ®' => 'ʈ', 'Ư' => 'Æ°', 'Ʊ' => 'ÊŠ', 'Ʋ' => 'Ê‹', 'Ƴ' => 'Æ´', 'Ƶ' => 'ƶ', 'Æ·' => 'Ê’', 'Ƹ' => 'ƹ', 'Ƽ' => 'ƽ', 'Ç„' => 'dž', 'Ç…' => 'dž', 'LJ' => 'lj', 'Lj' => 'lj', 'ÇŠ' => 'ÇŒ', 'Ç‹' => 'ÇŒ', 'Ç' => 'ÇŽ', 'Ç' => 'Ç', 'Ç‘' => 'Ç’', 'Ç“' => 'Ç”', 'Ç•' => 'Ç–', 'Ç—' => 'ǘ', 'Ç™' => 'Çš', 'Ç›' => 'Çœ', 'Çž' => 'ÇŸ', 'Ç ' => 'Ç¡', 'Ç¢' => 'Ç£', 'Ǥ' => 'Ç¥', 'Ǧ' => 'ǧ', 'Ǩ' => 'Ç©', 'Ǫ' => 'Ç«', 'Ǭ' => 'Ç­', 'Ç®' => 'ǯ', 'DZ' => 'dz', 'Dz' => 'dz', 'Ç´' => 'ǵ', 'Ƕ' => 'Æ•', 'Ç·' => 'Æ¿', 'Ǹ' => 'ǹ', 'Ǻ' => 'Ç»', 'Ǽ' => 'ǽ', 'Ǿ' => 'Ç¿', 'È€' => 'È', 'È‚' => 'ȃ', 'È„' => 'È…', 'Ȇ' => 'ȇ', 'Ȉ' => 'ȉ', 'ÈŠ' => 'È‹', 'ÈŒ' => 'È', 'ÈŽ' => 'È', 'È' => 'È‘', 'È’' => 'È“', 'È”' => 'È•', 'È–' => 'È—', 'Ș' => 'È™', 'Èš' => 'È›', 'Èœ' => 'È', 'Èž' => 'ÈŸ', 'È ' => 'Æž', 'È¢' => 'È£', 'Ȥ' => 'È¥', 'Ȧ' => 'ȧ', 'Ȩ' => 'È©', 'Ȫ' => 'È«', 'Ȭ' => 'È­', 'È®' => 'ȯ', 'È°' => 'ȱ', 'Ȳ' => 'ȳ', 'Ⱥ' => 'â±¥', 'È»' => 'ȼ', 'Ƚ' => 'Æš', 'Ⱦ' => 'ⱦ', 'É' => 'É‚', 'Ƀ' => 'Æ€', 'É„' => 'ʉ', 'É…' => 'ÊŒ', 'Ɇ' => 'ɇ', 'Ɉ' => 'ɉ', 'ÉŠ' => 'É‹', 'ÉŒ' => 'É', 'ÉŽ' => 'É', 'Í°' => 'ͱ', 'Ͳ' => 'ͳ', 'Ͷ' => 'Í·', 'Í¿' => 'ϳ', 'Ά' => 'ά', 'Έ' => 'έ', 'Ή' => 'ή', 'Ί' => 'ί', 'ÎŒ' => 'ÏŒ', 'ÎŽ' => 'Ï', 'Î' => 'ÏŽ', 'Α' => 'α', 'Î’' => 'β', 'Γ' => 'γ', 'Δ' => 'δ', 'Ε' => 'ε', 'Ζ' => 'ζ', 'Η' => 'η', 'Θ' => 'θ', 'Ι' => 'ι', 'Κ' => 'κ', 'Λ' => 'λ', 'Îœ' => 'μ', 'Î' => 'ν', 'Ξ' => 'ξ', 'Ο' => 'ο', 'Π' => 'Ï€', 'Ρ' => 'Ï', 'Σ' => 'σ', 'Τ' => 'Ï„', 'Î¥' => 'Ï…', 'Φ' => 'φ', 'Χ' => 'χ', 'Ψ' => 'ψ', 'Ω' => 'ω', 'Ϊ' => 'ÏŠ', 'Ϋ' => 'Ï‹', 'Ï' => 'Ï—', 'Ϙ' => 'Ï™', 'Ïš' => 'Ï›', 'Ïœ' => 'Ï', 'Ïž' => 'ÏŸ', 'Ï ' => 'Ï¡', 'Ï¢' => 'Ï£', 'Ϥ' => 'Ï¥', 'Ϧ' => 'ϧ', 'Ϩ' => 'Ï©', 'Ϫ' => 'Ï«', 'Ϭ' => 'Ï­', 'Ï®' => 'ϯ', 'Ï´' => 'θ', 'Ï·' => 'ϸ', 'Ϲ' => 'ϲ', 'Ϻ' => 'Ï»', 'Ͻ' => 'Í»', 'Ͼ' => 'ͼ', 'Ï¿' => 'ͽ', 'Ѐ' => 'Ñ', 'Ð' => 'Ñ‘', 'Ђ' => 'Ñ’', 'Ѓ' => 'Ñ“', 'Є' => 'Ñ”', 'Ð…' => 'Ñ•', 'І' => 'Ñ–', 'Ї' => 'Ñ—', 'Ј' => 'ј', 'Љ' => 'Ñ™', 'Њ' => 'Ñš', 'Ћ' => 'Ñ›', 'ÐŒ' => 'Ñœ', 'Ð' => 'Ñ', 'ÐŽ' => 'Ñž', 'Ð' => 'ÑŸ', 'Ð' => 'а', 'Б' => 'б', 'Ð’' => 'в', 'Г' => 'г', 'Д' => 'д', 'Е' => 'е', 'Ж' => 'ж', 'З' => 'з', 'И' => 'и', 'Й' => 'й', 'К' => 'к', 'Л' => 'л', 'Ðœ' => 'м', 'Ð' => 'н', 'О' => 'о', 'П' => 'п', 'Р' => 'Ñ€', 'С' => 'Ñ', 'Т' => 'Ñ‚', 'У' => 'у', 'Ф' => 'Ñ„', 'Ð¥' => 'Ñ…', 'Ц' => 'ц', 'Ч' => 'ч', 'Ш' => 'ш', 'Щ' => 'щ', 'Ъ' => 'ÑŠ', 'Ы' => 'Ñ‹', 'Ь' => 'ÑŒ', 'Э' => 'Ñ', 'Ю' => 'ÑŽ', 'Я' => 'Ñ', 'Ñ ' => 'Ñ¡', 'Ñ¢' => 'Ñ£', 'Ѥ' => 'Ñ¥', 'Ѧ' => 'ѧ', 'Ѩ' => 'Ñ©', 'Ѫ' => 'Ñ«', 'Ѭ' => 'Ñ­', 'Ñ®' => 'ѯ', 'Ñ°' => 'ѱ', 'Ѳ' => 'ѳ', 'Ñ´' => 'ѵ', 'Ѷ' => 'Ñ·', 'Ѹ' => 'ѹ', 'Ѻ' => 'Ñ»', 'Ѽ' => 'ѽ', 'Ѿ' => 'Ñ¿', 'Ò€' => 'Ò', 'ÒŠ' => 'Ò‹', 'ÒŒ' => 'Ò', 'ÒŽ' => 'Ò', 'Ò' => 'Ò‘', 'Ò’' => 'Ò“', 'Ò”' => 'Ò•', 'Ò–' => 'Ò—', 'Ò˜' => 'Ò™', 'Òš' => 'Ò›', 'Òœ' => 'Ò', 'Òž' => 'ÒŸ', 'Ò ' => 'Ò¡', 'Ò¢' => 'Ò£', 'Ò¤' => 'Ò¥', 'Ò¦' => 'Ò§', 'Ò¨' => 'Ò©', 'Òª' => 'Ò«', 'Ò¬' => 'Ò­', 'Ò®' => 'Ò¯', 'Ò°' => 'Ò±', 'Ò²' => 'Ò³', 'Ò´' => 'Òµ', 'Ò¶' => 'Ò·', 'Ò¸' => 'Ò¹', 'Òº' => 'Ò»', 'Ò¼' => 'Ò½', 'Ò¾' => 'Ò¿', 'Ó€' => 'Ó', 'Ó' => 'Ó‚', 'Óƒ' => 'Ó„', 'Ó…' => 'Ó†', 'Ó‡' => 'Óˆ', 'Ó‰' => 'ÓŠ', 'Ó‹' => 'ÓŒ', 'Ó' => 'ÓŽ', 'Ó' => 'Ó‘', 'Ó’' => 'Ó“', 'Ó”' => 'Ó•', 'Ó–' => 'Ó—', 'Ó˜' => 'Ó™', 'Óš' => 'Ó›', 'Óœ' => 'Ó', 'Óž' => 'ÓŸ', 'Ó ' => 'Ó¡', 'Ó¢' => 'Ó£', 'Ó¤' => 'Ó¥', 'Ó¦' => 'Ó§', 'Ó¨' => 'Ó©', 'Óª' => 'Ó«', 'Ó¬' => 'Ó­', 'Ó®' => 'Ó¯', 'Ó°' => 'Ó±', 'Ó²' => 'Ó³', 'Ó´' => 'Óµ', 'Ó¶' => 'Ó·', 'Ó¸' => 'Ó¹', 'Óº' => 'Ó»', 'Ó¼' => 'Ó½', 'Ó¾' => 'Ó¿', 'Ô€' => 'Ô', 'Ô‚' => 'Ôƒ', 'Ô„' => 'Ô…', 'Ô†' => 'Ô‡', 'Ôˆ' => 'Ô‰', 'ÔŠ' => 'Ô‹', 'ÔŒ' => 'Ô', 'ÔŽ' => 'Ô', 'Ô' => 'Ô‘', 'Ô’' => 'Ô“', 'Ô”' => 'Ô•', 'Ô–' => 'Ô—', 'Ô˜' => 'Ô™', 'Ôš' => 'Ô›', 'Ôœ' => 'Ô', 'Ôž' => 'ÔŸ', 'Ô ' => 'Ô¡', 'Ô¢' => 'Ô£', 'Ô¤' => 'Ô¥', 'Ô¦' => 'Ô§', 'Ô¨' => 'Ô©', 'Ôª' => 'Ô«', 'Ô¬' => 'Ô­', 'Ô®' => 'Ô¯', 'Ô±' => 'Õ¡', 'Ô²' => 'Õ¢', 'Ô³' => 'Õ£', 'Ô´' => 'Õ¤', 'Ôµ' => 'Õ¥', 'Ô¶' => 'Õ¦', 'Ô·' => 'Õ§', 'Ô¸' => 'Õ¨', 'Ô¹' => 'Õ©', 'Ôº' => 'Õª', 'Ô»' => 'Õ«', 'Ô¼' => 'Õ¬', 'Ô½' => 'Õ­', 'Ô¾' => 'Õ®', 'Ô¿' => 'Õ¯', 'Õ€' => 'Õ°', 'Õ' => 'Õ±', 'Õ‚' => 'Õ²', 'Õƒ' => 'Õ³', 'Õ„' => 'Õ´', 'Õ…' => 'Õµ', 'Õ†' => 'Õ¶', 'Õ‡' => 'Õ·', 'Õˆ' => 'Õ¸', 'Õ‰' => 'Õ¹', 'ÕŠ' => 'Õº', 'Õ‹' => 'Õ»', 'ÕŒ' => 'Õ¼', 'Õ' => 'Õ½', 'ÕŽ' => 'Õ¾', 'Õ' => 'Õ¿', 'Õ' => 'Ö€', 'Õ‘' => 'Ö', 'Õ’' => 'Ö‚', 'Õ“' => 'Öƒ', 'Õ”' => 'Ö„', 'Õ•' => 'Ö…', 'Õ–' => 'Ö†', 'á‚ ' => 'â´€', 'á‚¡' => 'â´', 'á‚¢' => 'â´‚', 'á‚£' => 'â´ƒ', 'Ⴄ' => 'â´„', 'á‚¥' => 'â´…', 'Ⴆ' => 'â´†', 'Ⴇ' => 'â´‡', 'Ⴈ' => 'â´ˆ', 'á‚©' => 'â´‰', 'Ⴊ' => 'â´Š', 'á‚«' => 'â´‹', 'Ⴌ' => 'â´Œ', 'á‚­' => 'â´', 'á‚®' => 'â´Ž', 'Ⴏ' => 'â´', 'á‚°' => 'â´', 'Ⴑ' => 'â´‘', 'Ⴒ' => 'â´’', 'Ⴓ' => 'â´“', 'á‚´' => 'â´”', 'Ⴕ' => 'â´•', 'Ⴖ' => 'â´–', 'á‚·' => 'â´—', 'Ⴘ' => 'â´˜', 'Ⴙ' => 'â´™', 'Ⴚ' => 'â´š', 'á‚»' => 'â´›', 'Ⴜ' => 'â´œ', 'Ⴝ' => 'â´', 'Ⴞ' => 'â´ž', 'á‚¿' => 'â´Ÿ', 'Ⴠ' => 'â´ ', 'áƒ' => 'â´¡', 'Ⴢ' => 'â´¢', 'Ⴣ' => 'â´£', 'Ⴤ' => 'â´¤', 'Ⴥ' => 'â´¥', 'Ⴧ' => 'â´§', 'áƒ' => 'â´­', 'Ḁ' => 'á¸', 'Ḃ' => 'ḃ', 'Ḅ' => 'ḅ', 'Ḇ' => 'ḇ', 'Ḉ' => 'ḉ', 'Ḋ' => 'ḋ', 'Ḍ' => 'á¸', 'Ḏ' => 'á¸', 'á¸' => 'ḑ', 'Ḓ' => 'ḓ', 'Ḕ' => 'ḕ', 'Ḗ' => 'ḗ', 'Ḙ' => 'ḙ', 'Ḛ' => 'ḛ', 'Ḝ' => 'á¸', 'Ḟ' => 'ḟ', 'Ḡ' => 'ḡ', 'Ḣ' => 'ḣ', 'Ḥ' => 'ḥ', 'Ḧ' => 'ḧ', 'Ḩ' => 'ḩ', 'Ḫ' => 'ḫ', 'Ḭ' => 'ḭ', 'Ḯ' => 'ḯ', 'Ḱ' => 'ḱ', 'Ḳ' => 'ḳ', 'Ḵ' => 'ḵ', 'Ḷ' => 'ḷ', 'Ḹ' => 'ḹ', 'Ḻ' => 'ḻ', 'Ḽ' => 'ḽ', 'Ḿ' => 'ḿ', 'á¹€' => 'á¹', 'Ṃ' => 'ṃ', 'Ṅ' => 'á¹…', 'Ṇ' => 'ṇ', 'Ṉ' => 'ṉ', 'Ṋ' => 'ṋ', 'Ṍ' => 'á¹', 'Ṏ' => 'á¹', 'á¹' => 'ṑ', 'á¹’' => 'ṓ', 'á¹”' => 'ṕ', 'á¹–' => 'á¹—', 'Ṙ' => 'á¹™', 'Ṛ' => 'á¹›', 'Ṝ' => 'á¹', 'Ṟ' => 'ṟ', 'á¹ ' => 'ṡ', 'á¹¢' => 'á¹£', 'Ṥ' => 'á¹¥', 'Ṧ' => 'ṧ', 'Ṩ' => 'ṩ', 'Ṫ' => 'ṫ', 'Ṭ' => 'á¹­', 'á¹®' => 'ṯ', 'á¹°' => 'á¹±', 'á¹²' => 'á¹³', 'á¹´' => 'á¹µ', 'Ṷ' => 'á¹·', 'Ṹ' => 'á¹¹', 'Ṻ' => 'á¹»', 'á¹¼' => 'á¹½', 'á¹¾' => 'ṿ', 'Ẁ' => 'áº', 'Ẃ' => 'ẃ', 'Ẅ' => 'ẅ', 'Ẇ' => 'ẇ', 'Ẉ' => 'ẉ', 'Ẋ' => 'ẋ', 'Ẍ' => 'áº', 'Ẏ' => 'áº', 'áº' => 'ẑ', 'Ẓ' => 'ẓ', 'Ẕ' => 'ẕ', 'ẞ' => 'ß', 'Ạ' => 'ạ', 'Ả' => 'ả', 'Ấ' => 'ấ', 'Ầ' => 'ầ', 'Ẩ' => 'ẩ', 'Ẫ' => 'ẫ', 'Ậ' => 'ậ', 'Ắ' => 'ắ', 'Ằ' => 'ằ', 'Ẳ' => 'ẳ', 'Ẵ' => 'ẵ', 'Ặ' => 'ặ', 'Ẹ' => 'ẹ', 'Ẻ' => 'ẻ', 'Ẽ' => 'ẽ', 'Ế' => 'ế', 'Ề' => 'á»', 'Ể' => 'ể', 'Ễ' => 'á»…', 'Ệ' => 'ệ', 'Ỉ' => 'ỉ', 'Ị' => 'ị', 'Ọ' => 'á»', 'Ỏ' => 'á»', 'á»' => 'ố', 'á»’' => 'ồ', 'á»”' => 'ổ', 'á»–' => 'á»—', 'Ộ' => 'á»™', 'Ớ' => 'á»›', 'Ờ' => 'á»', 'Ở' => 'ở', 'á» ' => 'ỡ', 'Ợ' => 'ợ', 'Ụ' => 'ụ', 'Ủ' => 'ủ', 'Ứ' => 'ứ', 'Ừ' => 'ừ', 'Ử' => 'á»­', 'á»®' => 'ữ', 'á»°' => 'á»±', 'Ỳ' => 'ỳ', 'á»´' => 'ỵ', 'Ỷ' => 'á»·', 'Ỹ' => 'ỹ', 'Ỻ' => 'á»»', 'Ỽ' => 'ỽ', 'Ỿ' => 'ỿ', 'Ἀ' => 'á¼€', 'Ἁ' => 'á¼', 'Ἂ' => 'ἂ', 'Ἃ' => 'ἃ', 'Ἄ' => 'ἄ', 'á¼' => 'á¼…', 'Ἆ' => 'ἆ', 'á¼' => 'ἇ', 'Ἐ' => 'á¼', 'á¼™' => 'ἑ', 'Ἒ' => 'á¼’', 'á¼›' => 'ἓ', 'Ἔ' => 'á¼”', 'á¼' => 'ἕ', 'Ἠ' => 'á¼ ', 'Ἡ' => 'ἡ', 'Ἢ' => 'á¼¢', 'Ἣ' => 'á¼£', 'Ἤ' => 'ἤ', 'á¼­' => 'á¼¥', 'á¼®' => 'ἦ', 'Ἧ' => 'ἧ', 'Ἰ' => 'á¼°', 'á¼¹' => 'á¼±', 'Ἲ' => 'á¼²', 'á¼»' => 'á¼³', 'á¼¼' => 'á¼´', 'á¼½' => 'á¼µ', 'á¼¾' => 'ἶ', 'Ἷ' => 'á¼·', 'Ὀ' => 'á½€', 'Ὁ' => 'á½', 'Ὂ' => 'ὂ', 'Ὃ' => 'ὃ', 'Ὄ' => 'ὄ', 'á½' => 'á½…', 'á½™' => 'ὑ', 'á½›' => 'ὓ', 'á½' => 'ὕ', 'Ὗ' => 'á½—', 'Ὠ' => 'á½ ', 'Ὡ' => 'ὡ', 'Ὢ' => 'á½¢', 'Ὣ' => 'á½£', 'Ὤ' => 'ὤ', 'á½­' => 'á½¥', 'á½®' => 'ὦ', 'Ὧ' => 'ὧ', 'ᾈ' => 'á¾€', 'ᾉ' => 'á¾', 'ᾊ' => 'ᾂ', 'ᾋ' => 'ᾃ', 'ᾌ' => 'ᾄ', 'á¾' => 'á¾…', 'ᾎ' => 'ᾆ', 'á¾' => 'ᾇ', 'ᾘ' => 'á¾', 'á¾™' => 'ᾑ', 'ᾚ' => 'á¾’', 'á¾›' => 'ᾓ', 'ᾜ' => 'á¾”', 'á¾' => 'ᾕ', 'ᾞ' => 'á¾–', 'ᾟ' => 'á¾—', 'ᾨ' => 'á¾ ', 'ᾩ' => 'ᾡ', 'ᾪ' => 'á¾¢', 'ᾫ' => 'á¾£', 'ᾬ' => 'ᾤ', 'á¾­' => 'á¾¥', 'á¾®' => 'ᾦ', 'ᾯ' => 'ᾧ', 'Ᾰ' => 'á¾°', 'á¾¹' => 'á¾±', 'Ὰ' => 'á½°', 'á¾»' => 'á½±', 'á¾¼' => 'á¾³', 'Ὲ' => 'á½²', 'Έ' => 'á½³', 'á¿Š' => 'á½´', 'á¿‹' => 'á½µ', 'á¿Œ' => 'ῃ', 'Ῐ' => 'á¿', 'á¿™' => 'á¿‘', 'á¿š' => 'ὶ', 'á¿›' => 'á½·', 'Ῠ' => 'á¿ ', 'á¿©' => 'á¿¡', 'Ὺ' => 'ὺ', 'á¿«' => 'á½»', 'Ῥ' => 'á¿¥', 'Ὸ' => 'ὸ', 'Ό' => 'á½¹', 'Ὼ' => 'á½¼', 'á¿»' => 'á½½', 'ῼ' => 'ῳ', 'Ω' => 'ω', 'K' => 'k', 'â„«' => 'Ã¥', 'Ⅎ' => 'â…Ž', 'â… ' => 'â…°', 'â…¡' => 'â…±', 'â…¢' => 'â…²', 'â…£' => 'â…³', 'â…¤' => 'â…´', 'â…¥' => 'â…µ', 'â…¦' => 'â…¶', 'â…§' => 'â…·', 'â…¨' => 'â…¸', 'â…©' => 'â…¹', 'â…ª' => 'â…º', 'â…«' => 'â…»', 'â…¬' => 'â…¼', 'â…­' => 'â…½', 'â…®' => 'â…¾', 'â…¯' => 'â…¿', 'Ↄ' => 'ↄ', 'â’¶' => 'â“', 'â’·' => 'â“‘', 'â’¸' => 'â“’', 'â’¹' => 'â““', 'â’º' => 'â“”', 'â’»' => 'â“•', 'â’¼' => 'â“–', 'â’½' => 'â“—', 'â’¾' => 'ⓘ', 'â’¿' => 'â“™', 'â“€' => 'â“š', 'â“' => 'â“›', 'â“‚' => 'â“œ', 'Ⓝ' => 'â“', 'â“„' => 'â“ž', 'â“…' => 'â“Ÿ', 'Ⓠ' => 'â“ ', 'Ⓡ' => 'â“¡', 'Ⓢ' => 'â“¢', 'Ⓣ' => 'â“£', 'â“Š' => 'ⓤ', 'â“‹' => 'â“¥', 'â“Œ' => 'ⓦ', 'â“' => 'ⓧ', 'â“Ž' => 'ⓨ', 'â“' => 'â“©', 'â°€' => 'â°°', 'â°' => 'â°±', 'â°‚' => 'â°²', 'â°ƒ' => 'â°³', 'â°„' => 'â°´', 'â°…' => 'â°µ', 'â°†' => 'â°¶', 'â°‡' => 'â°·', 'â°ˆ' => 'â°¸', 'â°‰' => 'â°¹', 'â°Š' => 'â°º', 'â°‹' => 'â°»', 'â°Œ' => 'â°¼', 'â°' => 'â°½', 'â°Ž' => 'â°¾', 'â°' => 'â°¿', 'â°' => 'â±€', 'â°‘' => 'â±', 'â°’' => 'ⱂ', 'â°“' => 'ⱃ', 'â°”' => 'ⱄ', 'â°•' => 'â±…', 'â°–' => 'ⱆ', 'â°—' => 'ⱇ', 'â°˜' => 'ⱈ', 'â°™' => 'ⱉ', 'â°š' => 'ⱊ', 'â°›' => 'ⱋ', 'â°œ' => 'ⱌ', 'â°' => 'â±', 'â°ž' => 'ⱎ', 'â°Ÿ' => 'â±', 'â° ' => 'â±', 'â°¡' => 'ⱑ', 'â°¢' => 'â±’', 'â°£' => 'ⱓ', 'â°¤' => 'â±”', 'â°¥' => 'ⱕ', 'â°¦' => 'â±–', 'â°§' => 'â±—', 'â°¨' => 'ⱘ', 'â°©' => 'â±™', 'â°ª' => 'ⱚ', 'â°«' => 'â±›', 'â°¬' => 'ⱜ', 'â°­' => 'â±', 'â°®' => 'ⱞ', 'â± ' => 'ⱡ', 'â±¢' => 'É«', 'â±£' => 'áµ½', 'Ɽ' => 'ɽ', 'Ⱨ' => 'ⱨ', 'Ⱪ' => 'ⱪ', 'Ⱬ' => 'ⱬ', 'â±­' => 'É‘', 'â±®' => 'ɱ', 'Ɐ' => 'É', 'â±°' => 'É’', 'â±²' => 'â±³', 'â±µ' => 'ⱶ', 'â±¾' => 'È¿', 'Ɀ' => 'É€', 'â²€' => 'â²', 'Ⲃ' => 'ⲃ', 'Ⲅ' => 'â²…', 'Ⲇ' => 'ⲇ', 'Ⲉ' => 'ⲉ', 'Ⲋ' => 'ⲋ', 'Ⲍ' => 'â²', 'Ⲏ' => 'â²', 'â²' => 'ⲑ', 'â²’' => 'ⲓ', 'â²”' => 'ⲕ', 'â²–' => 'â²—', 'Ⲙ' => 'â²™', 'Ⲛ' => 'â²›', 'Ⲝ' => 'â²', 'Ⲟ' => 'ⲟ', 'â² ' => 'ⲡ', 'â²¢' => 'â²£', 'Ⲥ' => 'â²¥', 'Ⲧ' => 'ⲧ', 'Ⲩ' => 'ⲩ', 'Ⲫ' => 'ⲫ', 'Ⲭ' => 'â²­', 'â²®' => 'ⲯ', 'â²°' => 'â²±', 'â²²' => 'â²³', 'â²´' => 'â²µ', 'Ⲷ' => 'â²·', 'Ⲹ' => 'â²¹', 'Ⲻ' => 'â²»', 'â²¼' => 'â²½', 'â²¾' => 'ⲿ', 'â³€' => 'â³', 'Ⳃ' => 'ⳃ', 'Ⳅ' => 'â³…', 'Ⳇ' => 'ⳇ', 'Ⳉ' => 'ⳉ', 'Ⳋ' => 'ⳋ', 'Ⳍ' => 'â³', 'Ⳏ' => 'â³', 'â³' => 'ⳑ', 'â³’' => 'ⳓ', 'â³”' => 'ⳕ', 'â³–' => 'â³—', 'Ⳙ' => 'â³™', 'Ⳛ' => 'â³›', 'Ⳝ' => 'â³', 'Ⳟ' => 'ⳟ', 'â³ ' => 'ⳡ', 'â³¢' => 'â³£', 'Ⳬ' => 'ⳬ', 'â³­' => 'â³®', 'â³²' => 'â³³', 'Ꙁ' => 'ê™', 'Ꙃ' => 'ꙃ', 'Ꙅ' => 'ê™…', 'Ꙇ' => 'ꙇ', 'Ꙉ' => 'ꙉ', 'Ꙋ' => 'ꙋ', 'Ꙍ' => 'ê™', 'Ꙏ' => 'ê™', 'ê™' => 'ꙑ', 'ê™’' => 'ꙓ', 'ê™”' => 'ꙕ', 'ê™–' => 'ê™—', 'Ꙙ' => 'ê™™', 'Ꙛ' => 'ê™›', 'Ꙝ' => 'ê™', 'Ꙟ' => 'ꙟ', 'ê™ ' => 'ꙡ', 'Ꙣ' => 'ꙣ', 'Ꙥ' => 'ꙥ', 'Ꙧ' => 'ꙧ', 'Ꙩ' => 'ꙩ', 'Ꙫ' => 'ꙫ', 'Ꙭ' => 'ê™­', 'Ꚁ' => 'êš', 'êš‚' => 'ꚃ', 'êš„' => 'êš…', 'Ꚇ' => 'ꚇ', 'Ꚉ' => 'ꚉ', 'Ꚋ' => 'êš‹', 'Ꚍ' => 'êš', 'Ꚏ' => 'êš', 'êš' => 'êš‘', 'êš’' => 'êš“', 'êš”' => 'êš•', 'êš–' => 'êš—', 'Ꚙ' => 'êš™', 'êšš' => 'êš›', 'Ꜣ' => 'ꜣ', 'Ꜥ' => 'ꜥ', 'Ꜧ' => 'ꜧ', 'Ꜩ' => 'ꜩ', 'Ꜫ' => 'ꜫ', 'Ꜭ' => 'ꜭ', 'Ꜯ' => 'ꜯ', 'Ꜳ' => 'ꜳ', 'Ꜵ' => 'ꜵ', 'Ꜷ' => 'ꜷ', 'Ꜹ' => 'ꜹ', 'Ꜻ' => 'ꜻ', 'Ꜽ' => 'ꜽ', 'Ꜿ' => 'ꜿ', 'ê€' => 'ê', 'ê‚' => 'êƒ', 'ê„' => 'ê…', 'ê†' => 'ê‡', 'êˆ' => 'ê‰', 'êŠ' => 'ê‹', 'êŒ' => 'ê', 'êŽ' => 'ê', 'ê' => 'ê‘', 'ê’' => 'ê“', 'ê”' => 'ê•', 'ê–' => 'ê—', 'ê˜' => 'ê™', 'êš' => 'ê›', 'êœ' => 'ê', 'êž' => 'êŸ', 'ê ' => 'ê¡', 'ê¢' => 'ê£', 'ê¤' => 'ê¥', 'ê¦' => 'ê§', 'ê¨' => 'ê©', 'êª' => 'ê«', 'ê¬' => 'ê­', 'ê®' => 'ê¯', 'ê¹' => 'êº', 'ê»' => 'ê¼', 'ê½' => 'áµ¹', 'ê¾' => 'ê¿', 'Ꞁ' => 'êž', 'êž‚' => 'ꞃ', 'êž„' => 'êž…', 'Ꞇ' => 'ꞇ', 'êž‹' => 'ꞌ', 'êž' => 'É¥', 'êž' => 'êž‘', 'êž’' => 'êž“', 'êž–' => 'êž—', 'Ꞙ' => 'êž™', 'êžš' => 'êž›', 'êžœ' => 'êž', 'êžž' => 'ꞟ', 'êž ' => 'êž¡', 'Ꞣ' => 'ꞣ', 'Ꞥ' => 'ꞥ', 'Ꞧ' => 'ꞧ', 'Ꞩ' => 'êž©', 'Ɦ' => 'ɦ', 'êž«' => 'Éœ', 'Ɡ' => 'É¡', 'êž­' => 'ɬ', 'êž°' => 'Êž', 'êž±' => 'ʇ', 'A' => 'ï½', 'ï¼¢' => 'b', 'ï¼£' => 'c', 'D' => 'd', 'ï¼¥' => 'ï½…', 'F' => 'f', 'G' => 'g', 'H' => 'h', 'I' => 'i', 'J' => 'j', 'K' => 'k', 'L' => 'l', 'ï¼­' => 'ï½', 'ï¼®' => 'n', 'O' => 'ï½', 'ï¼°' => 'ï½', 'ï¼±' => 'q', 'ï¼²' => 'ï½’', 'ï¼³' => 's', 'ï¼´' => 'ï½”', 'ï¼µ' => 'u', 'V' => 'ï½–', 'ï¼·' => 'ï½—', 'X' => 'x', 'ï¼¹' => 'ï½™', 'Z' => 'z', 'ð€' => 'ð¨', 'ð' => 'ð©', 'ð‚' => 'ðª', 'ðƒ' => 'ð«', 'ð„' => 'ð¬', 'ð…' => 'ð­', 'ð†' => 'ð®', 'ð‡' => 'ð¯', 'ðˆ' => 'ð°', 'ð‰' => 'ð±', 'ðŠ' => 'ð²', 'ð‹' => 'ð³', 'ðŒ' => 'ð´', 'ð' => 'ðµ', 'ðŽ' => 'ð¶', 'ð' => 'ð·', 'ð' => 'ð¸', 'ð‘' => 'ð¹', 'ð’' => 'ðº', 'ð“' => 'ð»', 'ð”' => 'ð¼', 'ð•' => 'ð½', 'ð–' => 'ð¾', 'ð—' => 'ð¿', 'ð˜' => 'ð‘€', 'ð™' => 'ð‘', 'ðš' => 'ð‘‚', 'ð›' => 'ð‘ƒ', 'ðœ' => 'ð‘„', 'ð' => 'ð‘…', 'ðž' => 'ð‘†', 'ðŸ' => 'ð‘‡', 'ð ' => 'ð‘ˆ', 'ð¡' => 'ð‘‰', 'ð¢' => 'ð‘Š', 'ð£' => 'ð‘‹', 'ð¤' => 'ð‘Œ', 'ð¥' => 'ð‘', 'ð¦' => 'ð‘Ž', 'ð§' => 'ð‘', 'ð‘¢ ' => 'ð‘£€', '𑢡' => 'ð‘£', 'ð‘¢¢' => '𑣂', 'ð‘¢£' => '𑣃', '𑢤' => '𑣄', 'ð‘¢¥' => 'ð‘£…', '𑢦' => '𑣆', '𑢧' => '𑣇', '𑢨' => '𑣈', '𑢩' => '𑣉', '𑢪' => '𑣊', '𑢫' => '𑣋', '𑢬' => '𑣌', 'ð‘¢­' => 'ð‘£', 'ð‘¢®' => '𑣎', '𑢯' => 'ð‘£', 'ð‘¢°' => 'ð‘£', 'ð‘¢±' => '𑣑', 'ð‘¢²' => 'ð‘£’', 'ð‘¢³' => '𑣓', 'ð‘¢´' => 'ð‘£”', 'ð‘¢µ' => '𑣕', '𑢶' => 'ð‘£–', 'ð‘¢·' => 'ð‘£—', '𑢸' => '𑣘', 'ð‘¢¹' => 'ð‘£™', '𑢺' => '𑣚', 'ð‘¢»' => 'ð‘£›', 'ð‘¢¼' => '𑣜', 'ð‘¢½' => 'ð‘£', 'ð‘¢¾' => '𑣞', '𑢿' => '𑣟'); + 'a', 'B' => 'b', 'C' => 'c', 'D' => 'd', 'E' => 'e', 'F' => 'f', 'G' => 'g', 'H' => 'h', 'I' => 'i', 'J' => 'j', 'K' => 'k', 'L' => 'l', 'M' => 'm', 'N' => 'n', 'O' => 'o', 'P' => 'p', 'Q' => 'q', 'R' => 'r', 'S' => 's', 'T' => 't', 'U' => 'u', 'V' => 'v', 'W' => 'w', 'X' => 'x', 'Y' => 'y', 'Z' => 'z', 'À' => 'à', 'Ã' => 'á', 'Â' => 'â', 'Ã' => 'ã', 'Ä' => 'ä', 'Ã…' => 'Ã¥', 'Æ' => 'æ', 'Ç' => 'ç', 'È' => 'è', 'É' => 'é', 'Ê' => 'ê', 'Ë' => 'ë', 'ÃŒ' => 'ì', 'Ã' => 'í', 'ÃŽ' => 'î', 'Ã' => 'ï', 'Ã' => 'ð', 'Ñ' => 'ñ', 'Ã’' => 'ò', 'Ó' => 'ó', 'Ô' => 'ô', 'Õ' => 'õ', 'Ö' => 'ö', 'Ø' => 'ø', 'Ù' => 'ù', 'Ú' => 'ú', 'Û' => 'û', 'Ãœ' => 'ü', 'Ã' => 'ý', 'Þ' => 'þ', 'Ä€' => 'Ä', 'Ä‚' => 'ă', 'Ä„' => 'Ä…', 'Ć' => 'ć', 'Ĉ' => 'ĉ', 'ÄŠ' => 'Ä‹', 'ÄŒ' => 'Ä', 'ÄŽ' => 'Ä', 'Ä' => 'Ä‘', 'Ä’' => 'Ä“', 'Ä”' => 'Ä•', 'Ä–' => 'Ä—', 'Ę' => 'Ä™', 'Äš' => 'Ä›', 'Äœ' => 'Ä', 'Äž' => 'ÄŸ', 'Ä ' => 'Ä¡', 'Ä¢' => 'Ä£', 'Ĥ' => 'Ä¥', 'Ħ' => 'ħ', 'Ĩ' => 'Ä©', 'Ī' => 'Ä«', 'Ĭ' => 'Ä­', 'Ä®' => 'į', 'Ä°' => 'i', 'IJ' => 'ij', 'Ä´' => 'ĵ', 'Ķ' => 'Ä·', 'Ĺ' => 'ĺ', 'Ä»' => 'ļ', 'Ľ' => 'ľ', 'Ä¿' => 'Å€', 'Å' => 'Å‚', 'Ń' => 'Å„', 'Å…' => 'ņ', 'Ň' => 'ň', 'ÅŠ' => 'Å‹', 'ÅŒ' => 'Å', 'ÅŽ' => 'Å', 'Å' => 'Å‘', 'Å’' => 'Å“', 'Å”' => 'Å•', 'Å–' => 'Å—', 'Ř' => 'Å™', 'Åš' => 'Å›', 'Åœ' => 'Å', 'Åž' => 'ÅŸ', 'Å ' => 'Å¡', 'Å¢' => 'Å£', 'Ť' => 'Å¥', 'Ŧ' => 'ŧ', 'Ũ' => 'Å©', 'Ū' => 'Å«', 'Ŭ' => 'Å­', 'Å®' => 'ů', 'Å°' => 'ű', 'Ų' => 'ų', 'Å´' => 'ŵ', 'Ŷ' => 'Å·', 'Ÿ' => 'ÿ', 'Ź' => 'ź', 'Å»' => 'ż', 'Ž' => 'ž', 'Æ' => 'É“', 'Æ‚' => 'ƃ', 'Æ„' => 'Æ…', 'Ɔ' => 'É”', 'Ƈ' => 'ƈ', 'Ɖ' => 'É–', 'ÆŠ' => 'É—', 'Æ‹' => 'ÆŒ', 'ÆŽ' => 'Ç', 'Æ' => 'É™', 'Æ' => 'É›', 'Æ‘' => 'Æ’', 'Æ“' => 'É ', 'Æ”' => 'É£', 'Æ–' => 'É©', 'Æ—' => 'ɨ', 'Ƙ' => 'Æ™', 'Æœ' => 'ɯ', 'Æ' => 'ɲ', 'ÆŸ' => 'ɵ', 'Æ ' => 'Æ¡', 'Æ¢' => 'Æ£', 'Ƥ' => 'Æ¥', 'Ʀ' => 'Ê€', 'Ƨ' => 'ƨ', 'Æ©' => 'ʃ', 'Ƭ' => 'Æ­', 'Æ®' => 'ʈ', 'Ư' => 'Æ°', 'Ʊ' => 'ÊŠ', 'Ʋ' => 'Ê‹', 'Ƴ' => 'Æ´', 'Ƶ' => 'ƶ', 'Æ·' => 'Ê’', 'Ƹ' => 'ƹ', 'Ƽ' => 'ƽ', 'Ç„' => 'dž', 'Ç…' => 'dž', 'LJ' => 'lj', 'Lj' => 'lj', 'ÇŠ' => 'ÇŒ', 'Ç‹' => 'ÇŒ', 'Ç' => 'ÇŽ', 'Ç' => 'Ç', 'Ç‘' => 'Ç’', 'Ç“' => 'Ç”', 'Ç•' => 'Ç–', 'Ç—' => 'ǘ', 'Ç™' => 'Çš', 'Ç›' => 'Çœ', 'Çž' => 'ÇŸ', 'Ç ' => 'Ç¡', 'Ç¢' => 'Ç£', 'Ǥ' => 'Ç¥', 'Ǧ' => 'ǧ', 'Ǩ' => 'Ç©', 'Ǫ' => 'Ç«', 'Ǭ' => 'Ç­', 'Ç®' => 'ǯ', 'DZ' => 'dz', 'Dz' => 'dz', 'Ç´' => 'ǵ', 'Ƕ' => 'Æ•', 'Ç·' => 'Æ¿', 'Ǹ' => 'ǹ', 'Ǻ' => 'Ç»', 'Ǽ' => 'ǽ', 'Ǿ' => 'Ç¿', 'È€' => 'È', 'È‚' => 'ȃ', 'È„' => 'È…', 'Ȇ' => 'ȇ', 'Ȉ' => 'ȉ', 'ÈŠ' => 'È‹', 'ÈŒ' => 'È', 'ÈŽ' => 'È', 'È' => 'È‘', 'È’' => 'È“', 'È”' => 'È•', 'È–' => 'È—', 'Ș' => 'È™', 'Èš' => 'È›', 'Èœ' => 'È', 'Èž' => 'ÈŸ', 'È ' => 'Æž', 'È¢' => 'È£', 'Ȥ' => 'È¥', 'Ȧ' => 'ȧ', 'Ȩ' => 'È©', 'Ȫ' => 'È«', 'Ȭ' => 'È­', 'È®' => 'ȯ', 'È°' => 'ȱ', 'Ȳ' => 'ȳ', 'Ⱥ' => 'â±¥', 'È»' => 'ȼ', 'Ƚ' => 'Æš', 'Ⱦ' => 'ⱦ', 'É' => 'É‚', 'Ƀ' => 'Æ€', 'É„' => 'ʉ', 'É…' => 'ÊŒ', 'Ɇ' => 'ɇ', 'Ɉ' => 'ɉ', 'ÉŠ' => 'É‹', 'ÉŒ' => 'É', 'ÉŽ' => 'É', 'Í°' => 'ͱ', 'Ͳ' => 'ͳ', 'Ͷ' => 'Í·', 'Í¿' => 'ϳ', 'Ά' => 'ά', 'Έ' => 'έ', 'Ή' => 'ή', 'Ί' => 'ί', 'ÎŒ' => 'ÏŒ', 'ÎŽ' => 'Ï', 'Î' => 'ÏŽ', 'Α' => 'α', 'Î’' => 'β', 'Γ' => 'γ', 'Δ' => 'δ', 'Ε' => 'ε', 'Ζ' => 'ζ', 'Η' => 'η', 'Θ' => 'θ', 'Ι' => 'ι', 'Κ' => 'κ', 'Λ' => 'λ', 'Îœ' => 'μ', 'Î' => 'ν', 'Ξ' => 'ξ', 'Ο' => 'ο', 'Π' => 'Ï€', 'Ρ' => 'Ï', 'Σ' => 'σ', 'Τ' => 'Ï„', 'Î¥' => 'Ï…', 'Φ' => 'φ', 'Χ' => 'χ', 'Ψ' => 'ψ', 'Ω' => 'ω', 'Ϊ' => 'ÏŠ', 'Ϋ' => 'Ï‹', 'Ï' => 'Ï—', 'Ϙ' => 'Ï™', 'Ïš' => 'Ï›', 'Ïœ' => 'Ï', 'Ïž' => 'ÏŸ', 'Ï ' => 'Ï¡', 'Ï¢' => 'Ï£', 'Ϥ' => 'Ï¥', 'Ϧ' => 'ϧ', 'Ϩ' => 'Ï©', 'Ϫ' => 'Ï«', 'Ϭ' => 'Ï­', 'Ï®' => 'ϯ', 'Ï´' => 'θ', 'Ï·' => 'ϸ', 'Ϲ' => 'ϲ', 'Ϻ' => 'Ï»', 'Ͻ' => 'Í»', 'Ͼ' => 'ͼ', 'Ï¿' => 'ͽ', 'Ѐ' => 'Ñ', 'Ð' => 'Ñ‘', 'Ђ' => 'Ñ’', 'Ѓ' => 'Ñ“', 'Є' => 'Ñ”', 'Ð…' => 'Ñ•', 'І' => 'Ñ–', 'Ї' => 'Ñ—', 'Ј' => 'ј', 'Љ' => 'Ñ™', 'Њ' => 'Ñš', 'Ћ' => 'Ñ›', 'ÐŒ' => 'Ñœ', 'Ð' => 'Ñ', 'ÐŽ' => 'Ñž', 'Ð' => 'ÑŸ', 'Ð' => 'а', 'Б' => 'б', 'Ð’' => 'в', 'Г' => 'г', 'Д' => 'д', 'Е' => 'е', 'Ж' => 'ж', 'З' => 'з', 'И' => 'и', 'Й' => 'й', 'К' => 'к', 'Л' => 'л', 'Ðœ' => 'м', 'Ð' => 'н', 'О' => 'о', 'П' => 'п', 'Р' => 'Ñ€', 'С' => 'Ñ', 'Т' => 'Ñ‚', 'У' => 'у', 'Ф' => 'Ñ„', 'Ð¥' => 'Ñ…', 'Ц' => 'ц', 'Ч' => 'ч', 'Ш' => 'ш', 'Щ' => 'щ', 'Ъ' => 'ÑŠ', 'Ы' => 'Ñ‹', 'Ь' => 'ÑŒ', 'Э' => 'Ñ', 'Ю' => 'ÑŽ', 'Я' => 'Ñ', 'Ñ ' => 'Ñ¡', 'Ñ¢' => 'Ñ£', 'Ѥ' => 'Ñ¥', 'Ѧ' => 'ѧ', 'Ѩ' => 'Ñ©', 'Ѫ' => 'Ñ«', 'Ѭ' => 'Ñ­', 'Ñ®' => 'ѯ', 'Ñ°' => 'ѱ', 'Ѳ' => 'ѳ', 'Ñ´' => 'ѵ', 'Ѷ' => 'Ñ·', 'Ѹ' => 'ѹ', 'Ѻ' => 'Ñ»', 'Ѽ' => 'ѽ', 'Ѿ' => 'Ñ¿', 'Ò€' => 'Ò', 'ÒŠ' => 'Ò‹', 'ÒŒ' => 'Ò', 'ÒŽ' => 'Ò', 'Ò' => 'Ò‘', 'Ò’' => 'Ò“', 'Ò”' => 'Ò•', 'Ò–' => 'Ò—', 'Ò˜' => 'Ò™', 'Òš' => 'Ò›', 'Òœ' => 'Ò', 'Òž' => 'ÒŸ', 'Ò ' => 'Ò¡', 'Ò¢' => 'Ò£', 'Ò¤' => 'Ò¥', 'Ò¦' => 'Ò§', 'Ò¨' => 'Ò©', 'Òª' => 'Ò«', 'Ò¬' => 'Ò­', 'Ò®' => 'Ò¯', 'Ò°' => 'Ò±', 'Ò²' => 'Ò³', 'Ò´' => 'Òµ', 'Ò¶' => 'Ò·', 'Ò¸' => 'Ò¹', 'Òº' => 'Ò»', 'Ò¼' => 'Ò½', 'Ò¾' => 'Ò¿', 'Ó€' => 'Ó', 'Ó' => 'Ó‚', 'Óƒ' => 'Ó„', 'Ó…' => 'Ó†', 'Ó‡' => 'Óˆ', 'Ó‰' => 'ÓŠ', 'Ó‹' => 'ÓŒ', 'Ó' => 'ÓŽ', 'Ó' => 'Ó‘', 'Ó’' => 'Ó“', 'Ó”' => 'Ó•', 'Ó–' => 'Ó—', 'Ó˜' => 'Ó™', 'Óš' => 'Ó›', 'Óœ' => 'Ó', 'Óž' => 'ÓŸ', 'Ó ' => 'Ó¡', 'Ó¢' => 'Ó£', 'Ó¤' => 'Ó¥', 'Ó¦' => 'Ó§', 'Ó¨' => 'Ó©', 'Óª' => 'Ó«', 'Ó¬' => 'Ó­', 'Ó®' => 'Ó¯', 'Ó°' => 'Ó±', 'Ó²' => 'Ó³', 'Ó´' => 'Óµ', 'Ó¶' => 'Ó·', 'Ó¸' => 'Ó¹', 'Óº' => 'Ó»', 'Ó¼' => 'Ó½', 'Ó¾' => 'Ó¿', 'Ô€' => 'Ô', 'Ô‚' => 'Ôƒ', 'Ô„' => 'Ô…', 'Ô†' => 'Ô‡', 'Ôˆ' => 'Ô‰', 'ÔŠ' => 'Ô‹', 'ÔŒ' => 'Ô', 'ÔŽ' => 'Ô', 'Ô' => 'Ô‘', 'Ô’' => 'Ô“', 'Ô”' => 'Ô•', 'Ô–' => 'Ô—', 'Ô˜' => 'Ô™', 'Ôš' => 'Ô›', 'Ôœ' => 'Ô', 'Ôž' => 'ÔŸ', 'Ô ' => 'Ô¡', 'Ô¢' => 'Ô£', 'Ô¤' => 'Ô¥', 'Ô¦' => 'Ô§', 'Ô¨' => 'Ô©', 'Ôª' => 'Ô«', 'Ô¬' => 'Ô­', 'Ô®' => 'Ô¯', 'Ô±' => 'Õ¡', 'Ô²' => 'Õ¢', 'Ô³' => 'Õ£', 'Ô´' => 'Õ¤', 'Ôµ' => 'Õ¥', 'Ô¶' => 'Õ¦', 'Ô·' => 'Õ§', 'Ô¸' => 'Õ¨', 'Ô¹' => 'Õ©', 'Ôº' => 'Õª', 'Ô»' => 'Õ«', 'Ô¼' => 'Õ¬', 'Ô½' => 'Õ­', 'Ô¾' => 'Õ®', 'Ô¿' => 'Õ¯', 'Õ€' => 'Õ°', 'Õ' => 'Õ±', 'Õ‚' => 'Õ²', 'Õƒ' => 'Õ³', 'Õ„' => 'Õ´', 'Õ…' => 'Õµ', 'Õ†' => 'Õ¶', 'Õ‡' => 'Õ·', 'Õˆ' => 'Õ¸', 'Õ‰' => 'Õ¹', 'ÕŠ' => 'Õº', 'Õ‹' => 'Õ»', 'ÕŒ' => 'Õ¼', 'Õ' => 'Õ½', 'ÕŽ' => 'Õ¾', 'Õ' => 'Õ¿', 'Õ' => 'Ö€', 'Õ‘' => 'Ö', 'Õ’' => 'Ö‚', 'Õ“' => 'Öƒ', 'Õ”' => 'Ö„', 'Õ•' => 'Ö…', 'Õ–' => 'Ö†', 'á‚ ' => 'â´€', 'á‚¡' => 'â´', 'á‚¢' => 'â´‚', 'á‚£' => 'â´ƒ', 'Ⴄ' => 'â´„', 'á‚¥' => 'â´…', 'Ⴆ' => 'â´†', 'Ⴇ' => 'â´‡', 'Ⴈ' => 'â´ˆ', 'á‚©' => 'â´‰', 'Ⴊ' => 'â´Š', 'á‚«' => 'â´‹', 'Ⴌ' => 'â´Œ', 'á‚­' => 'â´', 'á‚®' => 'â´Ž', 'Ⴏ' => 'â´', 'á‚°' => 'â´', 'Ⴑ' => 'â´‘', 'Ⴒ' => 'â´’', 'Ⴓ' => 'â´“', 'á‚´' => 'â´”', 'Ⴕ' => 'â´•', 'Ⴖ' => 'â´–', 'á‚·' => 'â´—', 'Ⴘ' => 'â´˜', 'Ⴙ' => 'â´™', 'Ⴚ' => 'â´š', 'á‚»' => 'â´›', 'Ⴜ' => 'â´œ', 'Ⴝ' => 'â´', 'Ⴞ' => 'â´ž', 'á‚¿' => 'â´Ÿ', 'Ⴠ' => 'â´ ', 'áƒ' => 'â´¡', 'Ⴢ' => 'â´¢', 'Ⴣ' => 'â´£', 'Ⴤ' => 'â´¤', 'Ⴥ' => 'â´¥', 'Ⴧ' => 'â´§', 'áƒ' => 'â´­', 'Ḁ' => 'á¸', 'Ḃ' => 'ḃ', 'Ḅ' => 'ḅ', 'Ḇ' => 'ḇ', 'Ḉ' => 'ḉ', 'Ḋ' => 'ḋ', 'Ḍ' => 'á¸', 'Ḏ' => 'á¸', 'á¸' => 'ḑ', 'Ḓ' => 'ḓ', 'Ḕ' => 'ḕ', 'Ḗ' => 'ḗ', 'Ḙ' => 'ḙ', 'Ḛ' => 'ḛ', 'Ḝ' => 'á¸', 'Ḟ' => 'ḟ', 'Ḡ' => 'ḡ', 'Ḣ' => 'ḣ', 'Ḥ' => 'ḥ', 'Ḧ' => 'ḧ', 'Ḩ' => 'ḩ', 'Ḫ' => 'ḫ', 'Ḭ' => 'ḭ', 'Ḯ' => 'ḯ', 'Ḱ' => 'ḱ', 'Ḳ' => 'ḳ', 'Ḵ' => 'ḵ', 'Ḷ' => 'ḷ', 'Ḹ' => 'ḹ', 'Ḻ' => 'ḻ', 'Ḽ' => 'ḽ', 'Ḿ' => 'ḿ', 'á¹€' => 'á¹', 'Ṃ' => 'ṃ', 'Ṅ' => 'á¹…', 'Ṇ' => 'ṇ', 'Ṉ' => 'ṉ', 'Ṋ' => 'ṋ', 'Ṍ' => 'á¹', 'Ṏ' => 'á¹', 'á¹' => 'ṑ', 'á¹’' => 'ṓ', 'á¹”' => 'ṕ', 'á¹–' => 'á¹—', 'Ṙ' => 'á¹™', 'Ṛ' => 'á¹›', 'Ṝ' => 'á¹', 'Ṟ' => 'ṟ', 'á¹ ' => 'ṡ', 'á¹¢' => 'á¹£', 'Ṥ' => 'á¹¥', 'Ṧ' => 'ṧ', 'Ṩ' => 'ṩ', 'Ṫ' => 'ṫ', 'Ṭ' => 'á¹­', 'á¹®' => 'ṯ', 'á¹°' => 'á¹±', 'á¹²' => 'á¹³', 'á¹´' => 'á¹µ', 'Ṷ' => 'á¹·', 'Ṹ' => 'á¹¹', 'Ṻ' => 'á¹»', 'á¹¼' => 'á¹½', 'á¹¾' => 'ṿ', 'Ẁ' => 'áº', 'Ẃ' => 'ẃ', 'Ẅ' => 'ẅ', 'Ẇ' => 'ẇ', 'Ẉ' => 'ẉ', 'Ẋ' => 'ẋ', 'Ẍ' => 'áº', 'Ẏ' => 'áº', 'áº' => 'ẑ', 'Ẓ' => 'ẓ', 'Ẕ' => 'ẕ', 'ẞ' => 'ß', 'Ạ' => 'ạ', 'Ả' => 'ả', 'Ấ' => 'ấ', 'Ầ' => 'ầ', 'Ẩ' => 'ẩ', 'Ẫ' => 'ẫ', 'Ậ' => 'ậ', 'Ắ' => 'ắ', 'Ằ' => 'ằ', 'Ẳ' => 'ẳ', 'Ẵ' => 'ẵ', 'Ặ' => 'ặ', 'Ẹ' => 'ẹ', 'Ẻ' => 'ẻ', 'Ẽ' => 'ẽ', 'Ế' => 'ế', 'Ề' => 'á»', 'Ể' => 'ể', 'Ễ' => 'á»…', 'Ệ' => 'ệ', 'Ỉ' => 'ỉ', 'Ị' => 'ị', 'Ọ' => 'á»', 'Ỏ' => 'á»', 'á»' => 'ố', 'á»’' => 'ồ', 'á»”' => 'ổ', 'á»–' => 'á»—', 'Ộ' => 'á»™', 'Ớ' => 'á»›', 'Ờ' => 'á»', 'Ở' => 'ở', 'á» ' => 'ỡ', 'Ợ' => 'ợ', 'Ụ' => 'ụ', 'Ủ' => 'ủ', 'Ứ' => 'ứ', 'Ừ' => 'ừ', 'Ử' => 'á»­', 'á»®' => 'ữ', 'á»°' => 'á»±', 'Ỳ' => 'ỳ', 'á»´' => 'ỵ', 'Ỷ' => 'á»·', 'Ỹ' => 'ỹ', 'Ỻ' => 'á»»', 'Ỽ' => 'ỽ', 'Ỿ' => 'ỿ', 'Ἀ' => 'á¼€', 'Ἁ' => 'á¼', 'Ἂ' => 'ἂ', 'Ἃ' => 'ἃ', 'Ἄ' => 'ἄ', 'á¼' => 'á¼…', 'Ἆ' => 'ἆ', 'á¼' => 'ἇ', 'Ἐ' => 'á¼', 'á¼™' => 'ἑ', 'Ἒ' => 'á¼’', 'á¼›' => 'ἓ', 'Ἔ' => 'á¼”', 'á¼' => 'ἕ', 'Ἠ' => 'á¼ ', 'Ἡ' => 'ἡ', 'Ἢ' => 'á¼¢', 'Ἣ' => 'á¼£', 'Ἤ' => 'ἤ', 'á¼­' => 'á¼¥', 'á¼®' => 'ἦ', 'Ἧ' => 'ἧ', 'Ἰ' => 'á¼°', 'á¼¹' => 'á¼±', 'Ἲ' => 'á¼²', 'á¼»' => 'á¼³', 'á¼¼' => 'á¼´', 'á¼½' => 'á¼µ', 'á¼¾' => 'ἶ', 'Ἷ' => 'á¼·', 'Ὀ' => 'á½€', 'Ὁ' => 'á½', 'Ὂ' => 'ὂ', 'Ὃ' => 'ὃ', 'Ὄ' => 'ὄ', 'á½' => 'á½…', 'á½™' => 'ὑ', 'á½›' => 'ὓ', 'á½' => 'ὕ', 'Ὗ' => 'á½—', 'Ὠ' => 'á½ ', 'Ὡ' => 'ὡ', 'Ὢ' => 'á½¢', 'Ὣ' => 'á½£', 'Ὤ' => 'ὤ', 'á½­' => 'á½¥', 'á½®' => 'ὦ', 'Ὧ' => 'ὧ', 'ᾈ' => 'á¾€', 'ᾉ' => 'á¾', 'ᾊ' => 'ᾂ', 'ᾋ' => 'ᾃ', 'ᾌ' => 'ᾄ', 'á¾' => 'á¾…', 'ᾎ' => 'ᾆ', 'á¾' => 'ᾇ', 'ᾘ' => 'á¾', 'á¾™' => 'ᾑ', 'ᾚ' => 'á¾’', 'á¾›' => 'ᾓ', 'ᾜ' => 'á¾”', 'á¾' => 'ᾕ', 'ᾞ' => 'á¾–', 'ᾟ' => 'á¾—', 'ᾨ' => 'á¾ ', 'ᾩ' => 'ᾡ', 'ᾪ' => 'á¾¢', 'ᾫ' => 'á¾£', 'ᾬ' => 'ᾤ', 'á¾­' => 'á¾¥', 'á¾®' => 'ᾦ', 'ᾯ' => 'ᾧ', 'Ᾰ' => 'á¾°', 'á¾¹' => 'á¾±', 'Ὰ' => 'á½°', 'á¾»' => 'á½±', 'á¾¼' => 'á¾³', 'Ὲ' => 'á½²', 'Έ' => 'á½³', 'á¿Š' => 'á½´', 'á¿‹' => 'á½µ', 'á¿Œ' => 'ῃ', 'Ῐ' => 'á¿', 'á¿™' => 'á¿‘', 'á¿š' => 'ὶ', 'á¿›' => 'á½·', 'Ῠ' => 'á¿ ', 'á¿©' => 'á¿¡', 'Ὺ' => 'ὺ', 'á¿«' => 'á½»', 'Ῥ' => 'á¿¥', 'Ὸ' => 'ὸ', 'Ό' => 'á½¹', 'Ὼ' => 'á½¼', 'á¿»' => 'á½½', 'ῼ' => 'ῳ', 'Ω' => 'ω', 'K' => 'k', 'â„«' => 'Ã¥', 'Ⅎ' => 'â…Ž', 'â… ' => 'â…°', 'â…¡' => 'â…±', 'â…¢' => 'â…²', 'â…£' => 'â…³', 'â…¤' => 'â…´', 'â…¥' => 'â…µ', 'â…¦' => 'â…¶', 'â…§' => 'â…·', 'â…¨' => 'â…¸', 'â…©' => 'â…¹', 'â…ª' => 'â…º', 'â…«' => 'â…»', 'â…¬' => 'â…¼', 'â…­' => 'â…½', 'â…®' => 'â…¾', 'â…¯' => 'â…¿', 'Ↄ' => 'ↄ', 'â’¶' => 'â“', 'â’·' => 'â“‘', 'â’¸' => 'â“’', 'â’¹' => 'â““', 'â’º' => 'â“”', 'â’»' => 'â“•', 'â’¼' => 'â“–', 'â’½' => 'â“—', 'â’¾' => 'ⓘ', 'â’¿' => 'â“™', 'â“€' => 'â“š', 'â“' => 'â“›', 'â“‚' => 'â“œ', 'Ⓝ' => 'â“', 'â“„' => 'â“ž', 'â“…' => 'â“Ÿ', 'Ⓠ' => 'â“ ', 'Ⓡ' => 'â“¡', 'Ⓢ' => 'â“¢', 'Ⓣ' => 'â“£', 'â“Š' => 'ⓤ', 'â“‹' => 'â“¥', 'â“Œ' => 'ⓦ', 'â“' => 'ⓧ', 'â“Ž' => 'ⓨ', 'â“' => 'â“©', 'â°€' => 'â°°', 'â°' => 'â°±', 'â°‚' => 'â°²', 'â°ƒ' => 'â°³', 'â°„' => 'â°´', 'â°…' => 'â°µ', 'â°†' => 'â°¶', 'â°‡' => 'â°·', 'â°ˆ' => 'â°¸', 'â°‰' => 'â°¹', 'â°Š' => 'â°º', 'â°‹' => 'â°»', 'â°Œ' => 'â°¼', 'â°' => 'â°½', 'â°Ž' => 'â°¾', 'â°' => 'â°¿', 'â°' => 'â±€', 'â°‘' => 'â±', 'â°’' => 'ⱂ', 'â°“' => 'ⱃ', 'â°”' => 'ⱄ', 'â°•' => 'â±…', 'â°–' => 'ⱆ', 'â°—' => 'ⱇ', 'â°˜' => 'ⱈ', 'â°™' => 'ⱉ', 'â°š' => 'ⱊ', 'â°›' => 'ⱋ', 'â°œ' => 'ⱌ', 'â°' => 'â±', 'â°ž' => 'ⱎ', 'â°Ÿ' => 'â±', 'â° ' => 'â±', 'â°¡' => 'ⱑ', 'â°¢' => 'â±’', 'â°£' => 'ⱓ', 'â°¤' => 'â±”', 'â°¥' => 'ⱕ', 'â°¦' => 'â±–', 'â°§' => 'â±—', 'â°¨' => 'ⱘ', 'â°©' => 'â±™', 'â°ª' => 'ⱚ', 'â°«' => 'â±›', 'â°¬' => 'ⱜ', 'â°­' => 'â±', 'â°®' => 'ⱞ', 'â± ' => 'ⱡ', 'â±¢' => 'É«', 'â±£' => 'áµ½', 'Ɽ' => 'ɽ', 'Ⱨ' => 'ⱨ', 'Ⱪ' => 'ⱪ', 'Ⱬ' => 'ⱬ', 'â±­' => 'É‘', 'â±®' => 'ɱ', 'Ɐ' => 'É', 'â±°' => 'É’', 'â±²' => 'â±³', 'â±µ' => 'ⱶ', 'â±¾' => 'È¿', 'Ɀ' => 'É€', 'â²€' => 'â²', 'Ⲃ' => 'ⲃ', 'Ⲅ' => 'â²…', 'Ⲇ' => 'ⲇ', 'Ⲉ' => 'ⲉ', 'Ⲋ' => 'ⲋ', 'Ⲍ' => 'â²', 'Ⲏ' => 'â²', 'â²' => 'ⲑ', 'â²’' => 'ⲓ', 'â²”' => 'ⲕ', 'â²–' => 'â²—', 'Ⲙ' => 'â²™', 'Ⲛ' => 'â²›', 'Ⲝ' => 'â²', 'Ⲟ' => 'ⲟ', 'â² ' => 'ⲡ', 'â²¢' => 'â²£', 'Ⲥ' => 'â²¥', 'Ⲧ' => 'ⲧ', 'Ⲩ' => 'ⲩ', 'Ⲫ' => 'ⲫ', 'Ⲭ' => 'â²­', 'â²®' => 'ⲯ', 'â²°' => 'â²±', 'â²²' => 'â²³', 'â²´' => 'â²µ', 'Ⲷ' => 'â²·', 'Ⲹ' => 'â²¹', 'Ⲻ' => 'â²»', 'â²¼' => 'â²½', 'â²¾' => 'ⲿ', 'â³€' => 'â³', 'Ⳃ' => 'ⳃ', 'Ⳅ' => 'â³…', 'Ⳇ' => 'ⳇ', 'Ⳉ' => 'ⳉ', 'Ⳋ' => 'ⳋ', 'Ⳍ' => 'â³', 'Ⳏ' => 'â³', 'â³' => 'ⳑ', 'â³’' => 'ⳓ', 'â³”' => 'ⳕ', 'â³–' => 'â³—', 'Ⳙ' => 'â³™', 'Ⳛ' => 'â³›', 'Ⳝ' => 'â³', 'Ⳟ' => 'ⳟ', 'â³ ' => 'ⳡ', 'â³¢' => 'â³£', 'Ⳬ' => 'ⳬ', 'â³­' => 'â³®', 'â³²' => 'â³³', 'Ꙁ' => 'ê™', 'Ꙃ' => 'ꙃ', 'Ꙅ' => 'ê™…', 'Ꙇ' => 'ꙇ', 'Ꙉ' => 'ꙉ', 'Ꙋ' => 'ꙋ', 'Ꙍ' => 'ê™', 'Ꙏ' => 'ê™', 'ê™' => 'ꙑ', 'ê™’' => 'ꙓ', 'ê™”' => 'ꙕ', 'ê™–' => 'ê™—', 'Ꙙ' => 'ê™™', 'Ꙛ' => 'ê™›', 'Ꙝ' => 'ê™', 'Ꙟ' => 'ꙟ', 'ê™ ' => 'ꙡ', 'Ꙣ' => 'ꙣ', 'Ꙥ' => 'ꙥ', 'Ꙧ' => 'ꙧ', 'Ꙩ' => 'ꙩ', 'Ꙫ' => 'ꙫ', 'Ꙭ' => 'ê™­', 'Ꚁ' => 'êš', 'êš‚' => 'ꚃ', 'êš„' => 'êš…', 'Ꚇ' => 'ꚇ', 'Ꚉ' => 'ꚉ', 'Ꚋ' => 'êš‹', 'Ꚍ' => 'êš', 'Ꚏ' => 'êš', 'êš' => 'êš‘', 'êš’' => 'êš“', 'êš”' => 'êš•', 'êš–' => 'êš—', 'Ꚙ' => 'êš™', 'êšš' => 'êš›', 'Ꜣ' => 'ꜣ', 'Ꜥ' => 'ꜥ', 'Ꜧ' => 'ꜧ', 'Ꜩ' => 'ꜩ', 'Ꜫ' => 'ꜫ', 'Ꜭ' => 'ꜭ', 'Ꜯ' => 'ꜯ', 'Ꜳ' => 'ꜳ', 'Ꜵ' => 'ꜵ', 'Ꜷ' => 'ꜷ', 'Ꜹ' => 'ꜹ', 'Ꜻ' => 'ꜻ', 'Ꜽ' => 'ꜽ', 'Ꜿ' => 'ꜿ', 'ê€' => 'ê', 'ê‚' => 'êƒ', 'ê„' => 'ê…', 'ê†' => 'ê‡', 'êˆ' => 'ê‰', 'êŠ' => 'ê‹', 'êŒ' => 'ê', 'êŽ' => 'ê', 'ê' => 'ê‘', 'ê’' => 'ê“', 'ê”' => 'ê•', 'ê–' => 'ê—', 'ê˜' => 'ê™', 'êš' => 'ê›', 'êœ' => 'ê', 'êž' => 'êŸ', 'ê ' => 'ê¡', 'ê¢' => 'ê£', 'ê¤' => 'ê¥', 'ê¦' => 'ê§', 'ê¨' => 'ê©', 'êª' => 'ê«', 'ê¬' => 'ê­', 'ê®' => 'ê¯', 'ê¹' => 'êº', 'ê»' => 'ê¼', 'ê½' => 'áµ¹', 'ê¾' => 'ê¿', 'Ꞁ' => 'êž', 'êž‚' => 'ꞃ', 'êž„' => 'êž…', 'Ꞇ' => 'ꞇ', 'êž‹' => 'ꞌ', 'êž' => 'É¥', 'êž' => 'êž‘', 'êž’' => 'êž“', 'êž–' => 'êž—', 'Ꞙ' => 'êž™', 'êžš' => 'êž›', 'êžœ' => 'êž', 'êžž' => 'ꞟ', 'êž ' => 'êž¡', 'Ꞣ' => 'ꞣ', 'Ꞥ' => 'ꞥ', 'Ꞧ' => 'ꞧ', 'Ꞩ' => 'êž©', 'Ɦ' => 'ɦ', 'êž«' => 'Éœ', 'Ɡ' => 'É¡', 'êž­' => 'ɬ', 'êž°' => 'Êž', 'êž±' => 'ʇ', 'A' => 'ï½', 'ï¼¢' => 'b', 'ï¼£' => 'c', 'D' => 'd', 'ï¼¥' => 'ï½…', 'F' => 'f', 'G' => 'g', 'H' => 'h', 'I' => 'i', 'J' => 'j', 'K' => 'k', 'L' => 'l', 'ï¼­' => 'ï½', 'ï¼®' => 'n', 'O' => 'ï½', 'ï¼°' => 'ï½', 'ï¼±' => 'q', 'ï¼²' => 'ï½’', 'ï¼³' => 's', 'ï¼´' => 'ï½”', 'ï¼µ' => 'u', 'V' => 'ï½–', 'ï¼·' => 'ï½—', 'X' => 'x', 'ï¼¹' => 'ï½™', 'Z' => 'z', 'ð€' => 'ð¨', 'ð' => 'ð©', 'ð‚' => 'ðª', 'ðƒ' => 'ð«', 'ð„' => 'ð¬', 'ð…' => 'ð­', 'ð†' => 'ð®', 'ð‡' => 'ð¯', 'ðˆ' => 'ð°', 'ð‰' => 'ð±', 'ðŠ' => 'ð²', 'ð‹' => 'ð³', 'ðŒ' => 'ð´', 'ð' => 'ðµ', 'ðŽ' => 'ð¶', 'ð' => 'ð·', 'ð' => 'ð¸', 'ð‘' => 'ð¹', 'ð’' => 'ðº', 'ð“' => 'ð»', 'ð”' => 'ð¼', 'ð•' => 'ð½', 'ð–' => 'ð¾', 'ð—' => 'ð¿', 'ð˜' => 'ð‘€', 'ð™' => 'ð‘', 'ðš' => 'ð‘‚', 'ð›' => 'ð‘ƒ', 'ðœ' => 'ð‘„', 'ð' => 'ð‘…', 'ðž' => 'ð‘†', 'ðŸ' => 'ð‘‡', 'ð ' => 'ð‘ˆ', 'ð¡' => 'ð‘‰', 'ð¢' => 'ð‘Š', 'ð£' => 'ð‘‹', 'ð¤' => 'ð‘Œ', 'ð¥' => 'ð‘', 'ð¦' => 'ð‘Ž', 'ð§' => 'ð‘', 'ð‘¢ ' => 'ð‘£€', '𑢡' => 'ð‘£', 'ð‘¢¢' => '𑣂', 'ð‘¢£' => '𑣃', '𑢤' => '𑣄', 'ð‘¢¥' => 'ð‘£…', '𑢦' => '𑣆', '𑢧' => '𑣇', '𑢨' => '𑣈', '𑢩' => '𑣉', '𑢪' => '𑣊', '𑢫' => '𑣋', '𑢬' => '𑣌', 'ð‘¢­' => 'ð‘£', 'ð‘¢®' => '𑣎', '𑢯' => 'ð‘£', 'ð‘¢°' => 'ð‘£', 'ð‘¢±' => '𑣑', 'ð‘¢²' => 'ð‘£’', 'ð‘¢³' => '𑣓', 'ð‘¢´' => 'ð‘£”', 'ð‘¢µ' => '𑣕', '𑢶' => 'ð‘£–', 'ð‘¢·' => 'ð‘£—', '𑢸' => '𑣘', 'ð‘¢¹' => 'ð‘£™', '𑢺' => '𑣚', 'ð‘¢»' => 'ð‘£›', 'ð‘¢¼' => '𑣜', 'ð‘¢½' => 'ð‘£', 'ð‘¢¾' => '𑣞', '𑢿' => '𑣟'); diff --git a/vendor/symfony/polyfill-mbstring/Resources/unidata/titleCaseRegexp.php b/vendor/symfony/polyfill-mbstring/Resources/unidata/titleCaseRegexp.php index 16284af71..e46c3fb00 100644 --- a/vendor/symfony/polyfill-mbstring/Resources/unidata/titleCaseRegexp.php +++ b/vendor/symfony/polyfill-mbstring/Resources/unidata/titleCaseRegexp.php @@ -1,6 +1,6 @@ - 'A', 'b' => 'B', 'c' => 'C', 'd' => 'D', 'e' => 'E', 'f' => 'F', 'g' => 'G', 'h' => 'H', 'i' => 'I', 'j' => 'J', 'k' => 'K', 'l' => 'L', 'm' => 'M', 'n' => 'N', 'o' => 'O', 'p' => 'P', 'q' => 'Q', 'r' => 'R', 's' => 'S', 't' => 'T', 'u' => 'U', 'v' => 'V', 'w' => 'W', 'x' => 'X', 'y' => 'Y', 'z' => 'Z', 'µ' => 'Îœ', 'à' => 'À', 'á' => 'Ã', 'â' => 'Â', 'ã' => 'Ã', 'ä' => 'Ä', 'Ã¥' => 'Ã…', 'æ' => 'Æ', 'ç' => 'Ç', 'è' => 'È', 'é' => 'É', 'ê' => 'Ê', 'ë' => 'Ë', 'ì' => 'ÃŒ', 'í' => 'Ã', 'î' => 'ÃŽ', 'ï' => 'Ã', 'ð' => 'Ã', 'ñ' => 'Ñ', 'ò' => 'Ã’', 'ó' => 'Ó', 'ô' => 'Ô', 'õ' => 'Õ', 'ö' => 'Ö', 'ø' => 'Ø', 'ù' => 'Ù', 'ú' => 'Ú', 'û' => 'Û', 'ü' => 'Ãœ', 'ý' => 'Ã', 'þ' => 'Þ', 'ÿ' => 'Ÿ', 'Ä' => 'Ä€', 'ă' => 'Ä‚', 'Ä…' => 'Ä„', 'ć' => 'Ć', 'ĉ' => 'Ĉ', 'Ä‹' => 'ÄŠ', 'Ä' => 'ÄŒ', 'Ä' => 'ÄŽ', 'Ä‘' => 'Ä', 'Ä“' => 'Ä’', 'Ä•' => 'Ä”', 'Ä—' => 'Ä–', 'Ä™' => 'Ę', 'Ä›' => 'Äš', 'Ä' => 'Äœ', 'ÄŸ' => 'Äž', 'Ä¡' => 'Ä ', 'Ä£' => 'Ä¢', 'Ä¥' => 'Ĥ', 'ħ' => 'Ħ', 'Ä©' => 'Ĩ', 'Ä«' => 'Ī', 'Ä­' => 'Ĭ', 'į' => 'Ä®', 'ı' => 'I', 'ij' => 'IJ', 'ĵ' => 'Ä´', 'Ä·' => 'Ķ', 'ĺ' => 'Ĺ', 'ļ' => 'Ä»', 'ľ' => 'Ľ', 'Å€' => 'Ä¿', 'Å‚' => 'Å', 'Å„' => 'Ń', 'ņ' => 'Å…', 'ň' => 'Ň', 'Å‹' => 'ÅŠ', 'Å' => 'ÅŒ', 'Å' => 'ÅŽ', 'Å‘' => 'Å', 'Å“' => 'Å’', 'Å•' => 'Å”', 'Å—' => 'Å–', 'Å™' => 'Ř', 'Å›' => 'Åš', 'Å' => 'Åœ', 'ÅŸ' => 'Åž', 'Å¡' => 'Å ', 'Å£' => 'Å¢', 'Å¥' => 'Ť', 'ŧ' => 'Ŧ', 'Å©' => 'Ũ', 'Å«' => 'Ū', 'Å­' => 'Ŭ', 'ů' => 'Å®', 'ű' => 'Å°', 'ų' => 'Ų', 'ŵ' => 'Å´', 'Å·' => 'Ŷ', 'ź' => 'Ź', 'ż' => 'Å»', 'ž' => 'Ž', 'Å¿' => 'S', 'Æ€' => 'Ƀ', 'ƃ' => 'Æ‚', 'Æ…' => 'Æ„', 'ƈ' => 'Ƈ', 'ÆŒ' => 'Æ‹', 'Æ’' => 'Æ‘', 'Æ•' => 'Ƕ', 'Æ™' => 'Ƙ', 'Æš' => 'Ƚ', 'Æž' => 'È ', 'Æ¡' => 'Æ ', 'Æ£' => 'Æ¢', 'Æ¥' => 'Ƥ', 'ƨ' => 'Ƨ', 'Æ­' => 'Ƭ', 'Æ°' => 'Ư', 'Æ´' => 'Ƴ', 'ƶ' => 'Ƶ', 'ƹ' => 'Ƹ', 'ƽ' => 'Ƽ', 'Æ¿' => 'Ç·', 'Ç…' => 'Ç„', 'dž' => 'Ç„', 'Lj' => 'LJ', 'lj' => 'LJ', 'Ç‹' => 'ÇŠ', 'ÇŒ' => 'ÇŠ', 'ÇŽ' => 'Ç', 'Ç' => 'Ç', 'Ç’' => 'Ç‘', 'Ç”' => 'Ç“', 'Ç–' => 'Ç•', 'ǘ' => 'Ç—', 'Çš' => 'Ç™', 'Çœ' => 'Ç›', 'Ç' => 'ÆŽ', 'ÇŸ' => 'Çž', 'Ç¡' => 'Ç ', 'Ç£' => 'Ç¢', 'Ç¥' => 'Ǥ', 'ǧ' => 'Ǧ', 'Ç©' => 'Ǩ', 'Ç«' => 'Ǫ', 'Ç­' => 'Ǭ', 'ǯ' => 'Ç®', 'Dz' => 'DZ', 'dz' => 'DZ', 'ǵ' => 'Ç´', 'ǹ' => 'Ǹ', 'Ç»' => 'Ǻ', 'ǽ' => 'Ǽ', 'Ç¿' => 'Ǿ', 'È' => 'È€', 'ȃ' => 'È‚', 'È…' => 'È„', 'ȇ' => 'Ȇ', 'ȉ' => 'Ȉ', 'È‹' => 'ÈŠ', 'È' => 'ÈŒ', 'È' => 'ÈŽ', 'È‘' => 'È', 'È“' => 'È’', 'È•' => 'È”', 'È—' => 'È–', 'È™' => 'Ș', 'È›' => 'Èš', 'È' => 'Èœ', 'ÈŸ' => 'Èž', 'È£' => 'È¢', 'È¥' => 'Ȥ', 'ȧ' => 'Ȧ', 'È©' => 'Ȩ', 'È«' => 'Ȫ', 'È­' => 'Ȭ', 'ȯ' => 'È®', 'ȱ' => 'È°', 'ȳ' => 'Ȳ', 'ȼ' => 'È»', 'È¿' => 'â±¾', 'É€' => 'Ɀ', 'É‚' => 'É', 'ɇ' => 'Ɇ', 'ɉ' => 'Ɉ', 'É‹' => 'ÉŠ', 'É' => 'ÉŒ', 'É' => 'ÉŽ', 'É' => 'Ɐ', 'É‘' => 'â±­', 'É’' => 'â±°', 'É“' => 'Æ', 'É”' => 'Ɔ', 'É–' => 'Ɖ', 'É—' => 'ÆŠ', 'É™' => 'Æ', 'É›' => 'Æ', 'Éœ' => 'êž«', 'É ' => 'Æ“', 'É¡' => 'Ɡ', 'É£' => 'Æ”', 'É¥' => 'êž', 'ɦ' => 'Ɦ', 'ɨ' => 'Æ—', 'É©' => 'Æ–', 'É«' => 'â±¢', 'ɬ' => 'êž­', 'ɯ' => 'Æœ', 'ɱ' => 'â±®', 'ɲ' => 'Æ', 'ɵ' => 'ÆŸ', 'ɽ' => 'Ɽ', 'Ê€' => 'Ʀ', 'ʃ' => 'Æ©', 'ʇ' => 'êž±', 'ʈ' => 'Æ®', 'ʉ' => 'É„', 'ÊŠ' => 'Ʊ', 'Ê‹' => 'Ʋ', 'ÊŒ' => 'É…', 'Ê’' => 'Æ·', 'Êž' => 'êž°', 'Í…' => 'Ι', 'ͱ' => 'Í°', 'ͳ' => 'Ͳ', 'Í·' => 'Ͷ', 'Í»' => 'Ͻ', 'ͼ' => 'Ͼ', 'ͽ' => 'Ï¿', 'ά' => 'Ά', 'έ' => 'Έ', 'ή' => 'Ή', 'ί' => 'Ί', 'α' => 'Α', 'β' => 'Î’', 'γ' => 'Γ', 'δ' => 'Δ', 'ε' => 'Ε', 'ζ' => 'Ζ', 'η' => 'Η', 'θ' => 'Θ', 'ι' => 'Ι', 'κ' => 'Κ', 'λ' => 'Λ', 'μ' => 'Îœ', 'ν' => 'Î', 'ξ' => 'Ξ', 'ο' => 'Ο', 'Ï€' => 'Π', 'Ï' => 'Ρ', 'Ï‚' => 'Σ', 'σ' => 'Σ', 'Ï„' => 'Τ', 'Ï…' => 'Î¥', 'φ' => 'Φ', 'χ' => 'Χ', 'ψ' => 'Ψ', 'ω' => 'Ω', 'ÏŠ' => 'Ϊ', 'Ï‹' => 'Ϋ', 'ÏŒ' => 'ÎŒ', 'Ï' => 'ÎŽ', 'ÏŽ' => 'Î', 'Ï' => 'Î’', 'Ï‘' => 'Θ', 'Ï•' => 'Φ', 'Ï–' => 'Π', 'Ï—' => 'Ï', 'Ï™' => 'Ϙ', 'Ï›' => 'Ïš', 'Ï' => 'Ïœ', 'ÏŸ' => 'Ïž', 'Ï¡' => 'Ï ', 'Ï£' => 'Ï¢', 'Ï¥' => 'Ϥ', 'ϧ' => 'Ϧ', 'Ï©' => 'Ϩ', 'Ï«' => 'Ϫ', 'Ï­' => 'Ϭ', 'ϯ' => 'Ï®', 'Ï°' => 'Κ', 'ϱ' => 'Ρ', 'ϲ' => 'Ϲ', 'ϳ' => 'Í¿', 'ϵ' => 'Ε', 'ϸ' => 'Ï·', 'Ï»' => 'Ϻ', 'а' => 'Ð', 'б' => 'Б', 'в' => 'Ð’', 'г' => 'Г', 'д' => 'Д', 'е' => 'Е', 'ж' => 'Ж', 'з' => 'З', 'и' => 'И', 'й' => 'Й', 'к' => 'К', 'л' => 'Л', 'м' => 'Ðœ', 'н' => 'Ð', 'о' => 'О', 'п' => 'П', 'Ñ€' => 'Р', 'Ñ' => 'С', 'Ñ‚' => 'Т', 'у' => 'У', 'Ñ„' => 'Ф', 'Ñ…' => 'Ð¥', 'ц' => 'Ц', 'ч' => 'Ч', 'ш' => 'Ш', 'щ' => 'Щ', 'ÑŠ' => 'Ъ', 'Ñ‹' => 'Ы', 'ÑŒ' => 'Ь', 'Ñ' => 'Э', 'ÑŽ' => 'Ю', 'Ñ' => 'Я', 'Ñ' => 'Ѐ', 'Ñ‘' => 'Ð', 'Ñ’' => 'Ђ', 'Ñ“' => 'Ѓ', 'Ñ”' => 'Є', 'Ñ•' => 'Ð…', 'Ñ–' => 'І', 'Ñ—' => 'Ї', 'ј' => 'Ј', 'Ñ™' => 'Љ', 'Ñš' => 'Њ', 'Ñ›' => 'Ћ', 'Ñœ' => 'ÐŒ', 'Ñ' => 'Ð', 'Ñž' => 'ÐŽ', 'ÑŸ' => 'Ð', 'Ñ¡' => 'Ñ ', 'Ñ£' => 'Ñ¢', 'Ñ¥' => 'Ѥ', 'ѧ' => 'Ѧ', 'Ñ©' => 'Ѩ', 'Ñ«' => 'Ѫ', 'Ñ­' => 'Ѭ', 'ѯ' => 'Ñ®', 'ѱ' => 'Ñ°', 'ѳ' => 'Ѳ', 'ѵ' => 'Ñ´', 'Ñ·' => 'Ѷ', 'ѹ' => 'Ѹ', 'Ñ»' => 'Ѻ', 'ѽ' => 'Ѽ', 'Ñ¿' => 'Ѿ', 'Ò' => 'Ò€', 'Ò‹' => 'ÒŠ', 'Ò' => 'ÒŒ', 'Ò' => 'ÒŽ', 'Ò‘' => 'Ò', 'Ò“' => 'Ò’', 'Ò•' => 'Ò”', 'Ò—' => 'Ò–', 'Ò™' => 'Ò˜', 'Ò›' => 'Òš', 'Ò' => 'Òœ', 'ÒŸ' => 'Òž', 'Ò¡' => 'Ò ', 'Ò£' => 'Ò¢', 'Ò¥' => 'Ò¤', 'Ò§' => 'Ò¦', 'Ò©' => 'Ò¨', 'Ò«' => 'Òª', 'Ò­' => 'Ò¬', 'Ò¯' => 'Ò®', 'Ò±' => 'Ò°', 'Ò³' => 'Ò²', 'Òµ' => 'Ò´', 'Ò·' => 'Ò¶', 'Ò¹' => 'Ò¸', 'Ò»' => 'Òº', 'Ò½' => 'Ò¼', 'Ò¿' => 'Ò¾', 'Ó‚' => 'Ó', 'Ó„' => 'Óƒ', 'Ó†' => 'Ó…', 'Óˆ' => 'Ó‡', 'ÓŠ' => 'Ó‰', 'ÓŒ' => 'Ó‹', 'ÓŽ' => 'Ó', 'Ó' => 'Ó€', 'Ó‘' => 'Ó', 'Ó“' => 'Ó’', 'Ó•' => 'Ó”', 'Ó—' => 'Ó–', 'Ó™' => 'Ó˜', 'Ó›' => 'Óš', 'Ó' => 'Óœ', 'ÓŸ' => 'Óž', 'Ó¡' => 'Ó ', 'Ó£' => 'Ó¢', 'Ó¥' => 'Ó¤', 'Ó§' => 'Ó¦', 'Ó©' => 'Ó¨', 'Ó«' => 'Óª', 'Ó­' => 'Ó¬', 'Ó¯' => 'Ó®', 'Ó±' => 'Ó°', 'Ó³' => 'Ó²', 'Óµ' => 'Ó´', 'Ó·' => 'Ó¶', 'Ó¹' => 'Ó¸', 'Ó»' => 'Óº', 'Ó½' => 'Ó¼', 'Ó¿' => 'Ó¾', 'Ô' => 'Ô€', 'Ôƒ' => 'Ô‚', 'Ô…' => 'Ô„', 'Ô‡' => 'Ô†', 'Ô‰' => 'Ôˆ', 'Ô‹' => 'ÔŠ', 'Ô' => 'ÔŒ', 'Ô' => 'ÔŽ', 'Ô‘' => 'Ô', 'Ô“' => 'Ô’', 'Ô•' => 'Ô”', 'Ô—' => 'Ô–', 'Ô™' => 'Ô˜', 'Ô›' => 'Ôš', 'Ô' => 'Ôœ', 'ÔŸ' => 'Ôž', 'Ô¡' => 'Ô ', 'Ô£' => 'Ô¢', 'Ô¥' => 'Ô¤', 'Ô§' => 'Ô¦', 'Ô©' => 'Ô¨', 'Ô«' => 'Ôª', 'Ô­' => 'Ô¬', 'Ô¯' => 'Ô®', 'Õ¡' => 'Ô±', 'Õ¢' => 'Ô²', 'Õ£' => 'Ô³', 'Õ¤' => 'Ô´', 'Õ¥' => 'Ôµ', 'Õ¦' => 'Ô¶', 'Õ§' => 'Ô·', 'Õ¨' => 'Ô¸', 'Õ©' => 'Ô¹', 'Õª' => 'Ôº', 'Õ«' => 'Ô»', 'Õ¬' => 'Ô¼', 'Õ­' => 'Ô½', 'Õ®' => 'Ô¾', 'Õ¯' => 'Ô¿', 'Õ°' => 'Õ€', 'Õ±' => 'Õ', 'Õ²' => 'Õ‚', 'Õ³' => 'Õƒ', 'Õ´' => 'Õ„', 'Õµ' => 'Õ…', 'Õ¶' => 'Õ†', 'Õ·' => 'Õ‡', 'Õ¸' => 'Õˆ', 'Õ¹' => 'Õ‰', 'Õº' => 'ÕŠ', 'Õ»' => 'Õ‹', 'Õ¼' => 'ÕŒ', 'Õ½' => 'Õ', 'Õ¾' => 'ÕŽ', 'Õ¿' => 'Õ', 'Ö€' => 'Õ', 'Ö' => 'Õ‘', 'Ö‚' => 'Õ’', 'Öƒ' => 'Õ“', 'Ö„' => 'Õ”', 'Ö…' => 'Õ•', 'Ö†' => 'Õ–', 'áµ¹' => 'ê½', 'áµ½' => 'â±£', 'á¸' => 'Ḁ', 'ḃ' => 'Ḃ', 'ḅ' => 'Ḅ', 'ḇ' => 'Ḇ', 'ḉ' => 'Ḉ', 'ḋ' => 'Ḋ', 'á¸' => 'Ḍ', 'á¸' => 'Ḏ', 'ḑ' => 'á¸', 'ḓ' => 'Ḓ', 'ḕ' => 'Ḕ', 'ḗ' => 'Ḗ', 'ḙ' => 'Ḙ', 'ḛ' => 'Ḛ', 'á¸' => 'Ḝ', 'ḟ' => 'Ḟ', 'ḡ' => 'Ḡ', 'ḣ' => 'Ḣ', 'ḥ' => 'Ḥ', 'ḧ' => 'Ḧ', 'ḩ' => 'Ḩ', 'ḫ' => 'Ḫ', 'ḭ' => 'Ḭ', 'ḯ' => 'Ḯ', 'ḱ' => 'Ḱ', 'ḳ' => 'Ḳ', 'ḵ' => 'Ḵ', 'ḷ' => 'Ḷ', 'ḹ' => 'Ḹ', 'ḻ' => 'Ḻ', 'ḽ' => 'Ḽ', 'ḿ' => 'Ḿ', 'á¹' => 'á¹€', 'ṃ' => 'Ṃ', 'á¹…' => 'Ṅ', 'ṇ' => 'Ṇ', 'ṉ' => 'Ṉ', 'ṋ' => 'Ṋ', 'á¹' => 'Ṍ', 'á¹' => 'Ṏ', 'ṑ' => 'á¹', 'ṓ' => 'á¹’', 'ṕ' => 'á¹”', 'á¹—' => 'á¹–', 'á¹™' => 'Ṙ', 'á¹›' => 'Ṛ', 'á¹' => 'Ṝ', 'ṟ' => 'Ṟ', 'ṡ' => 'á¹ ', 'á¹£' => 'á¹¢', 'á¹¥' => 'Ṥ', 'ṧ' => 'Ṧ', 'ṩ' => 'Ṩ', 'ṫ' => 'Ṫ', 'á¹­' => 'Ṭ', 'ṯ' => 'á¹®', 'á¹±' => 'á¹°', 'á¹³' => 'á¹²', 'á¹µ' => 'á¹´', 'á¹·' => 'Ṷ', 'á¹¹' => 'Ṹ', 'á¹»' => 'Ṻ', 'á¹½' => 'á¹¼', 'ṿ' => 'á¹¾', 'áº' => 'Ẁ', 'ẃ' => 'Ẃ', 'ẅ' => 'Ẅ', 'ẇ' => 'Ẇ', 'ẉ' => 'Ẉ', 'ẋ' => 'Ẋ', 'áº' => 'Ẍ', 'áº' => 'Ẏ', 'ẑ' => 'áº', 'ẓ' => 'Ẓ', 'ẕ' => 'Ẕ', 'ẛ' => 'á¹ ', 'ạ' => 'Ạ', 'ả' => 'Ả', 'ấ' => 'Ấ', 'ầ' => 'Ầ', 'ẩ' => 'Ẩ', 'ẫ' => 'Ẫ', 'ậ' => 'Ậ', 'ắ' => 'Ắ', 'ằ' => 'Ằ', 'ẳ' => 'Ẳ', 'ẵ' => 'Ẵ', 'ặ' => 'Ặ', 'ẹ' => 'Ẹ', 'ẻ' => 'Ẻ', 'ẽ' => 'Ẽ', 'ế' => 'Ế', 'á»' => 'Ề', 'ể' => 'Ể', 'á»…' => 'Ễ', 'ệ' => 'Ệ', 'ỉ' => 'Ỉ', 'ị' => 'Ị', 'á»' => 'Ọ', 'á»' => 'Ỏ', 'ố' => 'á»', 'ồ' => 'á»’', 'ổ' => 'á»”', 'á»—' => 'á»–', 'á»™' => 'Ộ', 'á»›' => 'Ớ', 'á»' => 'Ờ', 'ở' => 'Ở', 'ỡ' => 'á» ', 'ợ' => 'Ợ', 'ụ' => 'Ụ', 'ủ' => 'Ủ', 'ứ' => 'Ứ', 'ừ' => 'Ừ', 'á»­' => 'Ử', 'ữ' => 'á»®', 'á»±' => 'á»°', 'ỳ' => 'Ỳ', 'ỵ' => 'á»´', 'á»·' => 'Ỷ', 'ỹ' => 'Ỹ', 'á»»' => 'Ỻ', 'ỽ' => 'Ỽ', 'ỿ' => 'Ỿ', 'á¼€' => 'Ἀ', 'á¼' => 'Ἁ', 'ἂ' => 'Ἂ', 'ἃ' => 'Ἃ', 'ἄ' => 'Ἄ', 'á¼…' => 'á¼', 'ἆ' => 'Ἆ', 'ἇ' => 'á¼', 'á¼' => 'Ἐ', 'ἑ' => 'á¼™', 'á¼’' => 'Ἒ', 'ἓ' => 'á¼›', 'á¼”' => 'Ἔ', 'ἕ' => 'á¼', 'á¼ ' => 'Ἠ', 'ἡ' => 'Ἡ', 'á¼¢' => 'Ἢ', 'á¼£' => 'Ἣ', 'ἤ' => 'Ἤ', 'á¼¥' => 'á¼­', 'ἦ' => 'á¼®', 'ἧ' => 'Ἧ', 'á¼°' => 'Ἰ', 'á¼±' => 'á¼¹', 'á¼²' => 'Ἲ', 'á¼³' => 'á¼»', 'á¼´' => 'á¼¼', 'á¼µ' => 'á¼½', 'ἶ' => 'á¼¾', 'á¼·' => 'Ἷ', 'á½€' => 'Ὀ', 'á½' => 'Ὁ', 'ὂ' => 'Ὂ', 'ὃ' => 'Ὃ', 'ὄ' => 'Ὄ', 'á½…' => 'á½', 'ὑ' => 'á½™', 'ὓ' => 'á½›', 'ὕ' => 'á½', 'á½—' => 'Ὗ', 'á½ ' => 'Ὠ', 'ὡ' => 'Ὡ', 'á½¢' => 'Ὢ', 'á½£' => 'Ὣ', 'ὤ' => 'Ὤ', 'á½¥' => 'á½­', 'ὦ' => 'á½®', 'ὧ' => 'Ὧ', 'á½°' => 'Ὰ', 'á½±' => 'á¾»', 'á½²' => 'Ὲ', 'á½³' => 'Έ', 'á½´' => 'á¿Š', 'á½µ' => 'á¿‹', 'ὶ' => 'á¿š', 'á½·' => 'á¿›', 'ὸ' => 'Ὸ', 'á½¹' => 'Ό', 'ὺ' => 'Ὺ', 'á½»' => 'á¿«', 'á½¼' => 'Ὼ', 'á½½' => 'á¿»', 'á¾€' => 'ᾈ', 'á¾' => 'ᾉ', 'ᾂ' => 'ᾊ', 'ᾃ' => 'ᾋ', 'ᾄ' => 'ᾌ', 'á¾…' => 'á¾', 'ᾆ' => 'ᾎ', 'ᾇ' => 'á¾', 'á¾' => 'ᾘ', 'ᾑ' => 'á¾™', 'á¾’' => 'ᾚ', 'ᾓ' => 'á¾›', 'á¾”' => 'ᾜ', 'ᾕ' => 'á¾', 'á¾–' => 'ᾞ', 'á¾—' => 'ᾟ', 'á¾ ' => 'ᾨ', 'ᾡ' => 'ᾩ', 'á¾¢' => 'ᾪ', 'á¾£' => 'ᾫ', 'ᾤ' => 'ᾬ', 'á¾¥' => 'á¾­', 'ᾦ' => 'á¾®', 'ᾧ' => 'ᾯ', 'á¾°' => 'Ᾰ', 'á¾±' => 'á¾¹', 'á¾³' => 'á¾¼', 'á¾¾' => 'Ι', 'ῃ' => 'á¿Œ', 'á¿' => 'Ῐ', 'á¿‘' => 'á¿™', 'á¿ ' => 'Ῠ', 'á¿¡' => 'á¿©', 'á¿¥' => 'Ῥ', 'ῳ' => 'ῼ', 'â…Ž' => 'Ⅎ', 'â…°' => 'â… ', 'â…±' => 'â…¡', 'â…²' => 'â…¢', 'â…³' => 'â…£', 'â…´' => 'â…¤', 'â…µ' => 'â…¥', 'â…¶' => 'â…¦', 'â…·' => 'â…§', 'â…¸' => 'â…¨', 'â…¹' => 'â…©', 'â…º' => 'â…ª', 'â…»' => 'â…«', 'â…¼' => 'â…¬', 'â…½' => 'â…­', 'â…¾' => 'â…®', 'â…¿' => 'â…¯', 'ↄ' => 'Ↄ', 'â“' => 'â’¶', 'â“‘' => 'â’·', 'â“’' => 'â’¸', 'â““' => 'â’¹', 'â“”' => 'â’º', 'â“•' => 'â’»', 'â“–' => 'â’¼', 'â“—' => 'â’½', 'ⓘ' => 'â’¾', 'â“™' => 'â’¿', 'â“š' => 'â“€', 'â“›' => 'â“', 'â“œ' => 'â“‚', 'â“' => 'Ⓝ', 'â“ž' => 'â“„', 'â“Ÿ' => 'â“…', 'â“ ' => 'Ⓠ', 'â“¡' => 'Ⓡ', 'â“¢' => 'Ⓢ', 'â“£' => 'Ⓣ', 'ⓤ' => 'â“Š', 'â“¥' => 'â“‹', 'ⓦ' => 'â“Œ', 'ⓧ' => 'â“', 'ⓨ' => 'â“Ž', 'â“©' => 'â“', 'â°°' => 'â°€', 'â°±' => 'â°', 'â°²' => 'â°‚', 'â°³' => 'â°ƒ', 'â°´' => 'â°„', 'â°µ' => 'â°…', 'â°¶' => 'â°†', 'â°·' => 'â°‡', 'â°¸' => 'â°ˆ', 'â°¹' => 'â°‰', 'â°º' => 'â°Š', 'â°»' => 'â°‹', 'â°¼' => 'â°Œ', 'â°½' => 'â°', 'â°¾' => 'â°Ž', 'â°¿' => 'â°', 'â±€' => 'â°', 'â±' => 'â°‘', 'ⱂ' => 'â°’', 'ⱃ' => 'â°“', 'ⱄ' => 'â°”', 'â±…' => 'â°•', 'ⱆ' => 'â°–', 'ⱇ' => 'â°—', 'ⱈ' => 'â°˜', 'ⱉ' => 'â°™', 'ⱊ' => 'â°š', 'ⱋ' => 'â°›', 'ⱌ' => 'â°œ', 'â±' => 'â°', 'ⱎ' => 'â°ž', 'â±' => 'â°Ÿ', 'â±' => 'â° ', 'ⱑ' => 'â°¡', 'â±’' => 'â°¢', 'ⱓ' => 'â°£', 'â±”' => 'â°¤', 'ⱕ' => 'â°¥', 'â±–' => 'â°¦', 'â±—' => 'â°§', 'ⱘ' => 'â°¨', 'â±™' => 'â°©', 'ⱚ' => 'â°ª', 'â±›' => 'â°«', 'ⱜ' => 'â°¬', 'â±' => 'â°­', 'ⱞ' => 'â°®', 'ⱡ' => 'â± ', 'â±¥' => 'Ⱥ', 'ⱦ' => 'Ⱦ', 'ⱨ' => 'Ⱨ', 'ⱪ' => 'Ⱪ', 'ⱬ' => 'Ⱬ', 'â±³' => 'â±²', 'ⱶ' => 'â±µ', 'â²' => 'â²€', 'ⲃ' => 'Ⲃ', 'â²…' => 'Ⲅ', 'ⲇ' => 'Ⲇ', 'ⲉ' => 'Ⲉ', 'ⲋ' => 'Ⲋ', 'â²' => 'Ⲍ', 'â²' => 'Ⲏ', 'ⲑ' => 'â²', 'ⲓ' => 'â²’', 'ⲕ' => 'â²”', 'â²—' => 'â²–', 'â²™' => 'Ⲙ', 'â²›' => 'Ⲛ', 'â²' => 'Ⲝ', 'ⲟ' => 'Ⲟ', 'ⲡ' => 'â² ', 'â²£' => 'â²¢', 'â²¥' => 'Ⲥ', 'ⲧ' => 'Ⲧ', 'ⲩ' => 'Ⲩ', 'ⲫ' => 'Ⲫ', 'â²­' => 'Ⲭ', 'ⲯ' => 'â²®', 'â²±' => 'â²°', 'â²³' => 'â²²', 'â²µ' => 'â²´', 'â²·' => 'Ⲷ', 'â²¹' => 'Ⲹ', 'â²»' => 'Ⲻ', 'â²½' => 'â²¼', 'ⲿ' => 'â²¾', 'â³' => 'â³€', 'ⳃ' => 'Ⳃ', 'â³…' => 'Ⳅ', 'ⳇ' => 'Ⳇ', 'ⳉ' => 'Ⳉ', 'ⳋ' => 'Ⳋ', 'â³' => 'Ⳍ', 'â³' => 'Ⳏ', 'ⳑ' => 'â³', 'ⳓ' => 'â³’', 'ⳕ' => 'â³”', 'â³—' => 'â³–', 'â³™' => 'Ⳙ', 'â³›' => 'Ⳛ', 'â³' => 'Ⳝ', 'ⳟ' => 'Ⳟ', 'ⳡ' => 'â³ ', 'â³£' => 'â³¢', 'ⳬ' => 'Ⳬ', 'â³®' => 'â³­', 'â³³' => 'â³²', 'â´€' => 'á‚ ', 'â´' => 'á‚¡', 'â´‚' => 'á‚¢', 'â´ƒ' => 'á‚£', 'â´„' => 'Ⴄ', 'â´…' => 'á‚¥', 'â´†' => 'Ⴆ', 'â´‡' => 'Ⴇ', 'â´ˆ' => 'Ⴈ', 'â´‰' => 'á‚©', 'â´Š' => 'Ⴊ', 'â´‹' => 'á‚«', 'â´Œ' => 'Ⴌ', 'â´' => 'á‚­', 'â´Ž' => 'á‚®', 'â´' => 'Ⴏ', 'â´' => 'á‚°', 'â´‘' => 'Ⴑ', 'â´’' => 'Ⴒ', 'â´“' => 'Ⴓ', 'â´”' => 'á‚´', 'â´•' => 'Ⴕ', 'â´–' => 'Ⴖ', 'â´—' => 'á‚·', 'â´˜' => 'Ⴘ', 'â´™' => 'Ⴙ', 'â´š' => 'Ⴚ', 'â´›' => 'á‚»', 'â´œ' => 'Ⴜ', 'â´' => 'Ⴝ', 'â´ž' => 'Ⴞ', 'â´Ÿ' => 'á‚¿', 'â´ ' => 'Ⴠ', 'â´¡' => 'áƒ', 'â´¢' => 'Ⴢ', 'â´£' => 'Ⴣ', 'â´¤' => 'Ⴤ', 'â´¥' => 'Ⴥ', 'â´§' => 'Ⴧ', 'â´­' => 'áƒ', 'ê™' => 'Ꙁ', 'ꙃ' => 'Ꙃ', 'ê™…' => 'Ꙅ', 'ꙇ' => 'Ꙇ', 'ꙉ' => 'Ꙉ', 'ꙋ' => 'Ꙋ', 'ê™' => 'Ꙍ', 'ê™' => 'Ꙏ', 'ꙑ' => 'ê™', 'ꙓ' => 'ê™’', 'ꙕ' => 'ê™”', 'ê™—' => 'ê™–', 'ê™™' => 'Ꙙ', 'ê™›' => 'Ꙛ', 'ê™' => 'Ꙝ', 'ꙟ' => 'Ꙟ', 'ꙡ' => 'ê™ ', 'ꙣ' => 'Ꙣ', 'ꙥ' => 'Ꙥ', 'ꙧ' => 'Ꙧ', 'ꙩ' => 'Ꙩ', 'ꙫ' => 'Ꙫ', 'ê™­' => 'Ꙭ', 'êš' => 'Ꚁ', 'ꚃ' => 'êš‚', 'êš…' => 'êš„', 'ꚇ' => 'Ꚇ', 'ꚉ' => 'Ꚉ', 'êš‹' => 'Ꚋ', 'êš' => 'Ꚍ', 'êš' => 'Ꚏ', 'êš‘' => 'êš', 'êš“' => 'êš’', 'êš•' => 'êš”', 'êš—' => 'êš–', 'êš™' => 'Ꚙ', 'êš›' => 'êšš', 'ꜣ' => 'Ꜣ', 'ꜥ' => 'Ꜥ', 'ꜧ' => 'Ꜧ', 'ꜩ' => 'Ꜩ', 'ꜫ' => 'Ꜫ', 'ꜭ' => 'Ꜭ', 'ꜯ' => 'Ꜯ', 'ꜳ' => 'Ꜳ', 'ꜵ' => 'Ꜵ', 'ꜷ' => 'Ꜷ', 'ꜹ' => 'Ꜹ', 'ꜻ' => 'Ꜻ', 'ꜽ' => 'Ꜽ', 'ꜿ' => 'Ꜿ', 'ê' => 'ê€', 'êƒ' => 'ê‚', 'ê…' => 'ê„', 'ê‡' => 'ê†', 'ê‰' => 'êˆ', 'ê‹' => 'êŠ', 'ê' => 'êŒ', 'ê' => 'êŽ', 'ê‘' => 'ê', 'ê“' => 'ê’', 'ê•' => 'ê”', 'ê—' => 'ê–', 'ê™' => 'ê˜', 'ê›' => 'êš', 'ê' => 'êœ', 'êŸ' => 'êž', 'ê¡' => 'ê ', 'ê£' => 'ê¢', 'ê¥' => 'ê¤', 'ê§' => 'ê¦', 'ê©' => 'ê¨', 'ê«' => 'êª', 'ê­' => 'ê¬', 'ê¯' => 'ê®', 'êº' => 'ê¹', 'ê¼' => 'ê»', 'ê¿' => 'ê¾', 'êž' => 'Ꞁ', 'ꞃ' => 'êž‚', 'êž…' => 'êž„', 'ꞇ' => 'Ꞇ', 'ꞌ' => 'êž‹', 'êž‘' => 'êž', 'êž“' => 'êž’', 'êž—' => 'êž–', 'êž™' => 'Ꞙ', 'êž›' => 'êžš', 'êž' => 'êžœ', 'ꞟ' => 'êžž', 'êž¡' => 'êž ', 'ꞣ' => 'Ꞣ', 'ꞥ' => 'Ꞥ', 'ꞧ' => 'Ꞧ', 'êž©' => 'Ꞩ', 'ï½' => 'A', 'b' => 'ï¼¢', 'c' => 'ï¼£', 'd' => 'D', 'ï½…' => 'ï¼¥', 'f' => 'F', 'g' => 'G', 'h' => 'H', 'i' => 'I', 'j' => 'J', 'k' => 'K', 'l' => 'L', 'ï½' => 'ï¼­', 'n' => 'ï¼®', 'ï½' => 'O', 'ï½' => 'ï¼°', 'q' => 'ï¼±', 'ï½’' => 'ï¼²', 's' => 'ï¼³', 'ï½”' => 'ï¼´', 'u' => 'ï¼µ', 'ï½–' => 'V', 'ï½—' => 'ï¼·', 'x' => 'X', 'ï½™' => 'ï¼¹', 'z' => 'Z', 'ð¨' => 'ð€', 'ð©' => 'ð', 'ðª' => 'ð‚', 'ð«' => 'ðƒ', 'ð¬' => 'ð„', 'ð­' => 'ð…', 'ð®' => 'ð†', 'ð¯' => 'ð‡', 'ð°' => 'ðˆ', 'ð±' => 'ð‰', 'ð²' => 'ðŠ', 'ð³' => 'ð‹', 'ð´' => 'ðŒ', 'ðµ' => 'ð', 'ð¶' => 'ðŽ', 'ð·' => 'ð', 'ð¸' => 'ð', 'ð¹' => 'ð‘', 'ðº' => 'ð’', 'ð»' => 'ð“', 'ð¼' => 'ð”', 'ð½' => 'ð•', 'ð¾' => 'ð–', 'ð¿' => 'ð—', 'ð‘€' => 'ð˜', 'ð‘' => 'ð™', 'ð‘‚' => 'ðš', 'ð‘ƒ' => 'ð›', 'ð‘„' => 'ðœ', 'ð‘…' => 'ð', 'ð‘†' => 'ðž', 'ð‘‡' => 'ðŸ', 'ð‘ˆ' => 'ð ', 'ð‘‰' => 'ð¡', 'ð‘Š' => 'ð¢', 'ð‘‹' => 'ð£', 'ð‘Œ' => 'ð¤', 'ð‘' => 'ð¥', 'ð‘Ž' => 'ð¦', 'ð‘' => 'ð§', 'ð‘£€' => 'ð‘¢ ', 'ð‘£' => '𑢡', '𑣂' => 'ð‘¢¢', '𑣃' => 'ð‘¢£', '𑣄' => '𑢤', 'ð‘£…' => 'ð‘¢¥', '𑣆' => '𑢦', '𑣇' => '𑢧', '𑣈' => '𑢨', '𑣉' => '𑢩', '𑣊' => '𑢪', '𑣋' => '𑢫', '𑣌' => '𑢬', 'ð‘£' => 'ð‘¢­', '𑣎' => 'ð‘¢®', 'ð‘£' => '𑢯', 'ð‘£' => 'ð‘¢°', '𑣑' => 'ð‘¢±', 'ð‘£’' => 'ð‘¢²', '𑣓' => 'ð‘¢³', 'ð‘£”' => 'ð‘¢´', '𑣕' => 'ð‘¢µ', 'ð‘£–' => '𑢶', 'ð‘£—' => 'ð‘¢·', '𑣘' => '𑢸', 'ð‘£™' => 'ð‘¢¹', '𑣚' => '𑢺', 'ð‘£›' => 'ð‘¢»', '𑣜' => 'ð‘¢¼', 'ð‘£' => 'ð‘¢½', '𑣞' => 'ð‘¢¾', '𑣟' => '𑢿'); + 'A', 'b' => 'B', 'c' => 'C', 'd' => 'D', 'e' => 'E', 'f' => 'F', 'g' => 'G', 'h' => 'H', 'i' => 'I', 'j' => 'J', 'k' => 'K', 'l' => 'L', 'm' => 'M', 'n' => 'N', 'o' => 'O', 'p' => 'P', 'q' => 'Q', 'r' => 'R', 's' => 'S', 't' => 'T', 'u' => 'U', 'v' => 'V', 'w' => 'W', 'x' => 'X', 'y' => 'Y', 'z' => 'Z', 'µ' => 'Îœ', 'à' => 'À', 'á' => 'Ã', 'â' => 'Â', 'ã' => 'Ã', 'ä' => 'Ä', 'Ã¥' => 'Ã…', 'æ' => 'Æ', 'ç' => 'Ç', 'è' => 'È', 'é' => 'É', 'ê' => 'Ê', 'ë' => 'Ë', 'ì' => 'ÃŒ', 'í' => 'Ã', 'î' => 'ÃŽ', 'ï' => 'Ã', 'ð' => 'Ã', 'ñ' => 'Ñ', 'ò' => 'Ã’', 'ó' => 'Ó', 'ô' => 'Ô', 'õ' => 'Õ', 'ö' => 'Ö', 'ø' => 'Ø', 'ù' => 'Ù', 'ú' => 'Ú', 'û' => 'Û', 'ü' => 'Ãœ', 'ý' => 'Ã', 'þ' => 'Þ', 'ÿ' => 'Ÿ', 'Ä' => 'Ä€', 'ă' => 'Ä‚', 'Ä…' => 'Ä„', 'ć' => 'Ć', 'ĉ' => 'Ĉ', 'Ä‹' => 'ÄŠ', 'Ä' => 'ÄŒ', 'Ä' => 'ÄŽ', 'Ä‘' => 'Ä', 'Ä“' => 'Ä’', 'Ä•' => 'Ä”', 'Ä—' => 'Ä–', 'Ä™' => 'Ę', 'Ä›' => 'Äš', 'Ä' => 'Äœ', 'ÄŸ' => 'Äž', 'Ä¡' => 'Ä ', 'Ä£' => 'Ä¢', 'Ä¥' => 'Ĥ', 'ħ' => 'Ħ', 'Ä©' => 'Ĩ', 'Ä«' => 'Ī', 'Ä­' => 'Ĭ', 'į' => 'Ä®', 'ı' => 'I', 'ij' => 'IJ', 'ĵ' => 'Ä´', 'Ä·' => 'Ķ', 'ĺ' => 'Ĺ', 'ļ' => 'Ä»', 'ľ' => 'Ľ', 'Å€' => 'Ä¿', 'Å‚' => 'Å', 'Å„' => 'Ń', 'ņ' => 'Å…', 'ň' => 'Ň', 'Å‹' => 'ÅŠ', 'Å' => 'ÅŒ', 'Å' => 'ÅŽ', 'Å‘' => 'Å', 'Å“' => 'Å’', 'Å•' => 'Å”', 'Å—' => 'Å–', 'Å™' => 'Ř', 'Å›' => 'Åš', 'Å' => 'Åœ', 'ÅŸ' => 'Åž', 'Å¡' => 'Å ', 'Å£' => 'Å¢', 'Å¥' => 'Ť', 'ŧ' => 'Ŧ', 'Å©' => 'Ũ', 'Å«' => 'Ū', 'Å­' => 'Ŭ', 'ů' => 'Å®', 'ű' => 'Å°', 'ų' => 'Ų', 'ŵ' => 'Å´', 'Å·' => 'Ŷ', 'ź' => 'Ź', 'ż' => 'Å»', 'ž' => 'Ž', 'Å¿' => 'S', 'Æ€' => 'Ƀ', 'ƃ' => 'Æ‚', 'Æ…' => 'Æ„', 'ƈ' => 'Ƈ', 'ÆŒ' => 'Æ‹', 'Æ’' => 'Æ‘', 'Æ•' => 'Ƕ', 'Æ™' => 'Ƙ', 'Æš' => 'Ƚ', 'Æž' => 'È ', 'Æ¡' => 'Æ ', 'Æ£' => 'Æ¢', 'Æ¥' => 'Ƥ', 'ƨ' => 'Ƨ', 'Æ­' => 'Ƭ', 'Æ°' => 'Ư', 'Æ´' => 'Ƴ', 'ƶ' => 'Ƶ', 'ƹ' => 'Ƹ', 'ƽ' => 'Ƽ', 'Æ¿' => 'Ç·', 'Ç…' => 'Ç„', 'dž' => 'Ç„', 'Lj' => 'LJ', 'lj' => 'LJ', 'Ç‹' => 'ÇŠ', 'ÇŒ' => 'ÇŠ', 'ÇŽ' => 'Ç', 'Ç' => 'Ç', 'Ç’' => 'Ç‘', 'Ç”' => 'Ç“', 'Ç–' => 'Ç•', 'ǘ' => 'Ç—', 'Çš' => 'Ç™', 'Çœ' => 'Ç›', 'Ç' => 'ÆŽ', 'ÇŸ' => 'Çž', 'Ç¡' => 'Ç ', 'Ç£' => 'Ç¢', 'Ç¥' => 'Ǥ', 'ǧ' => 'Ǧ', 'Ç©' => 'Ǩ', 'Ç«' => 'Ǫ', 'Ç­' => 'Ǭ', 'ǯ' => 'Ç®', 'Dz' => 'DZ', 'dz' => 'DZ', 'ǵ' => 'Ç´', 'ǹ' => 'Ǹ', 'Ç»' => 'Ǻ', 'ǽ' => 'Ǽ', 'Ç¿' => 'Ǿ', 'È' => 'È€', 'ȃ' => 'È‚', 'È…' => 'È„', 'ȇ' => 'Ȇ', 'ȉ' => 'Ȉ', 'È‹' => 'ÈŠ', 'È' => 'ÈŒ', 'È' => 'ÈŽ', 'È‘' => 'È', 'È“' => 'È’', 'È•' => 'È”', 'È—' => 'È–', 'È™' => 'Ș', 'È›' => 'Èš', 'È' => 'Èœ', 'ÈŸ' => 'Èž', 'È£' => 'È¢', 'È¥' => 'Ȥ', 'ȧ' => 'Ȧ', 'È©' => 'Ȩ', 'È«' => 'Ȫ', 'È­' => 'Ȭ', 'ȯ' => 'È®', 'ȱ' => 'È°', 'ȳ' => 'Ȳ', 'ȼ' => 'È»', 'È¿' => 'â±¾', 'É€' => 'Ɀ', 'É‚' => 'É', 'ɇ' => 'Ɇ', 'ɉ' => 'Ɉ', 'É‹' => 'ÉŠ', 'É' => 'ÉŒ', 'É' => 'ÉŽ', 'É' => 'Ɐ', 'É‘' => 'â±­', 'É’' => 'â±°', 'É“' => 'Æ', 'É”' => 'Ɔ', 'É–' => 'Ɖ', 'É—' => 'ÆŠ', 'É™' => 'Æ', 'É›' => 'Æ', 'Éœ' => 'êž«', 'É ' => 'Æ“', 'É¡' => 'Ɡ', 'É£' => 'Æ”', 'É¥' => 'êž', 'ɦ' => 'Ɦ', 'ɨ' => 'Æ—', 'É©' => 'Æ–', 'É«' => 'â±¢', 'ɬ' => 'êž­', 'ɯ' => 'Æœ', 'ɱ' => 'â±®', 'ɲ' => 'Æ', 'ɵ' => 'ÆŸ', 'ɽ' => 'Ɽ', 'Ê€' => 'Ʀ', 'ʃ' => 'Æ©', 'ʇ' => 'êž±', 'ʈ' => 'Æ®', 'ʉ' => 'É„', 'ÊŠ' => 'Ʊ', 'Ê‹' => 'Ʋ', 'ÊŒ' => 'É…', 'Ê’' => 'Æ·', 'Êž' => 'êž°', 'Í…' => 'Ι', 'ͱ' => 'Í°', 'ͳ' => 'Ͳ', 'Í·' => 'Ͷ', 'Í»' => 'Ͻ', 'ͼ' => 'Ͼ', 'ͽ' => 'Ï¿', 'ά' => 'Ά', 'έ' => 'Έ', 'ή' => 'Ή', 'ί' => 'Ί', 'α' => 'Α', 'β' => 'Î’', 'γ' => 'Γ', 'δ' => 'Δ', 'ε' => 'Ε', 'ζ' => 'Ζ', 'η' => 'Η', 'θ' => 'Θ', 'ι' => 'Ι', 'κ' => 'Κ', 'λ' => 'Λ', 'μ' => 'Îœ', 'ν' => 'Î', 'ξ' => 'Ξ', 'ο' => 'Ο', 'Ï€' => 'Π', 'Ï' => 'Ρ', 'Ï‚' => 'Σ', 'σ' => 'Σ', 'Ï„' => 'Τ', 'Ï…' => 'Î¥', 'φ' => 'Φ', 'χ' => 'Χ', 'ψ' => 'Ψ', 'ω' => 'Ω', 'ÏŠ' => 'Ϊ', 'Ï‹' => 'Ϋ', 'ÏŒ' => 'ÎŒ', 'Ï' => 'ÎŽ', 'ÏŽ' => 'Î', 'Ï' => 'Î’', 'Ï‘' => 'Θ', 'Ï•' => 'Φ', 'Ï–' => 'Π', 'Ï—' => 'Ï', 'Ï™' => 'Ϙ', 'Ï›' => 'Ïš', 'Ï' => 'Ïœ', 'ÏŸ' => 'Ïž', 'Ï¡' => 'Ï ', 'Ï£' => 'Ï¢', 'Ï¥' => 'Ϥ', 'ϧ' => 'Ϧ', 'Ï©' => 'Ϩ', 'Ï«' => 'Ϫ', 'Ï­' => 'Ϭ', 'ϯ' => 'Ï®', 'Ï°' => 'Κ', 'ϱ' => 'Ρ', 'ϲ' => 'Ϲ', 'ϳ' => 'Í¿', 'ϵ' => 'Ε', 'ϸ' => 'Ï·', 'Ï»' => 'Ϻ', 'а' => 'Ð', 'б' => 'Б', 'в' => 'Ð’', 'г' => 'Г', 'д' => 'Д', 'е' => 'Е', 'ж' => 'Ж', 'з' => 'З', 'и' => 'И', 'й' => 'Й', 'к' => 'К', 'л' => 'Л', 'м' => 'Ðœ', 'н' => 'Ð', 'о' => 'О', 'п' => 'П', 'Ñ€' => 'Р', 'Ñ' => 'С', 'Ñ‚' => 'Т', 'у' => 'У', 'Ñ„' => 'Ф', 'Ñ…' => 'Ð¥', 'ц' => 'Ц', 'ч' => 'Ч', 'ш' => 'Ш', 'щ' => 'Щ', 'ÑŠ' => 'Ъ', 'Ñ‹' => 'Ы', 'ÑŒ' => 'Ь', 'Ñ' => 'Э', 'ÑŽ' => 'Ю', 'Ñ' => 'Я', 'Ñ' => 'Ѐ', 'Ñ‘' => 'Ð', 'Ñ’' => 'Ђ', 'Ñ“' => 'Ѓ', 'Ñ”' => 'Є', 'Ñ•' => 'Ð…', 'Ñ–' => 'І', 'Ñ—' => 'Ї', 'ј' => 'Ј', 'Ñ™' => 'Љ', 'Ñš' => 'Њ', 'Ñ›' => 'Ћ', 'Ñœ' => 'ÐŒ', 'Ñ' => 'Ð', 'Ñž' => 'ÐŽ', 'ÑŸ' => 'Ð', 'Ñ¡' => 'Ñ ', 'Ñ£' => 'Ñ¢', 'Ñ¥' => 'Ѥ', 'ѧ' => 'Ѧ', 'Ñ©' => 'Ѩ', 'Ñ«' => 'Ѫ', 'Ñ­' => 'Ѭ', 'ѯ' => 'Ñ®', 'ѱ' => 'Ñ°', 'ѳ' => 'Ѳ', 'ѵ' => 'Ñ´', 'Ñ·' => 'Ѷ', 'ѹ' => 'Ѹ', 'Ñ»' => 'Ѻ', 'ѽ' => 'Ѽ', 'Ñ¿' => 'Ѿ', 'Ò' => 'Ò€', 'Ò‹' => 'ÒŠ', 'Ò' => 'ÒŒ', 'Ò' => 'ÒŽ', 'Ò‘' => 'Ò', 'Ò“' => 'Ò’', 'Ò•' => 'Ò”', 'Ò—' => 'Ò–', 'Ò™' => 'Ò˜', 'Ò›' => 'Òš', 'Ò' => 'Òœ', 'ÒŸ' => 'Òž', 'Ò¡' => 'Ò ', 'Ò£' => 'Ò¢', 'Ò¥' => 'Ò¤', 'Ò§' => 'Ò¦', 'Ò©' => 'Ò¨', 'Ò«' => 'Òª', 'Ò­' => 'Ò¬', 'Ò¯' => 'Ò®', 'Ò±' => 'Ò°', 'Ò³' => 'Ò²', 'Òµ' => 'Ò´', 'Ò·' => 'Ò¶', 'Ò¹' => 'Ò¸', 'Ò»' => 'Òº', 'Ò½' => 'Ò¼', 'Ò¿' => 'Ò¾', 'Ó‚' => 'Ó', 'Ó„' => 'Óƒ', 'Ó†' => 'Ó…', 'Óˆ' => 'Ó‡', 'ÓŠ' => 'Ó‰', 'ÓŒ' => 'Ó‹', 'ÓŽ' => 'Ó', 'Ó' => 'Ó€', 'Ó‘' => 'Ó', 'Ó“' => 'Ó’', 'Ó•' => 'Ó”', 'Ó—' => 'Ó–', 'Ó™' => 'Ó˜', 'Ó›' => 'Óš', 'Ó' => 'Óœ', 'ÓŸ' => 'Óž', 'Ó¡' => 'Ó ', 'Ó£' => 'Ó¢', 'Ó¥' => 'Ó¤', 'Ó§' => 'Ó¦', 'Ó©' => 'Ó¨', 'Ó«' => 'Óª', 'Ó­' => 'Ó¬', 'Ó¯' => 'Ó®', 'Ó±' => 'Ó°', 'Ó³' => 'Ó²', 'Óµ' => 'Ó´', 'Ó·' => 'Ó¶', 'Ó¹' => 'Ó¸', 'Ó»' => 'Óº', 'Ó½' => 'Ó¼', 'Ó¿' => 'Ó¾', 'Ô' => 'Ô€', 'Ôƒ' => 'Ô‚', 'Ô…' => 'Ô„', 'Ô‡' => 'Ô†', 'Ô‰' => 'Ôˆ', 'Ô‹' => 'ÔŠ', 'Ô' => 'ÔŒ', 'Ô' => 'ÔŽ', 'Ô‘' => 'Ô', 'Ô“' => 'Ô’', 'Ô•' => 'Ô”', 'Ô—' => 'Ô–', 'Ô™' => 'Ô˜', 'Ô›' => 'Ôš', 'Ô' => 'Ôœ', 'ÔŸ' => 'Ôž', 'Ô¡' => 'Ô ', 'Ô£' => 'Ô¢', 'Ô¥' => 'Ô¤', 'Ô§' => 'Ô¦', 'Ô©' => 'Ô¨', 'Ô«' => 'Ôª', 'Ô­' => 'Ô¬', 'Ô¯' => 'Ô®', 'Õ¡' => 'Ô±', 'Õ¢' => 'Ô²', 'Õ£' => 'Ô³', 'Õ¤' => 'Ô´', 'Õ¥' => 'Ôµ', 'Õ¦' => 'Ô¶', 'Õ§' => 'Ô·', 'Õ¨' => 'Ô¸', 'Õ©' => 'Ô¹', 'Õª' => 'Ôº', 'Õ«' => 'Ô»', 'Õ¬' => 'Ô¼', 'Õ­' => 'Ô½', 'Õ®' => 'Ô¾', 'Õ¯' => 'Ô¿', 'Õ°' => 'Õ€', 'Õ±' => 'Õ', 'Õ²' => 'Õ‚', 'Õ³' => 'Õƒ', 'Õ´' => 'Õ„', 'Õµ' => 'Õ…', 'Õ¶' => 'Õ†', 'Õ·' => 'Õ‡', 'Õ¸' => 'Õˆ', 'Õ¹' => 'Õ‰', 'Õº' => 'ÕŠ', 'Õ»' => 'Õ‹', 'Õ¼' => 'ÕŒ', 'Õ½' => 'Õ', 'Õ¾' => 'ÕŽ', 'Õ¿' => 'Õ', 'Ö€' => 'Õ', 'Ö' => 'Õ‘', 'Ö‚' => 'Õ’', 'Öƒ' => 'Õ“', 'Ö„' => 'Õ”', 'Ö…' => 'Õ•', 'Ö†' => 'Õ–', 'áµ¹' => 'ê½', 'áµ½' => 'â±£', 'á¸' => 'Ḁ', 'ḃ' => 'Ḃ', 'ḅ' => 'Ḅ', 'ḇ' => 'Ḇ', 'ḉ' => 'Ḉ', 'ḋ' => 'Ḋ', 'á¸' => 'Ḍ', 'á¸' => 'Ḏ', 'ḑ' => 'á¸', 'ḓ' => 'Ḓ', 'ḕ' => 'Ḕ', 'ḗ' => 'Ḗ', 'ḙ' => 'Ḙ', 'ḛ' => 'Ḛ', 'á¸' => 'Ḝ', 'ḟ' => 'Ḟ', 'ḡ' => 'Ḡ', 'ḣ' => 'Ḣ', 'ḥ' => 'Ḥ', 'ḧ' => 'Ḧ', 'ḩ' => 'Ḩ', 'ḫ' => 'Ḫ', 'ḭ' => 'Ḭ', 'ḯ' => 'Ḯ', 'ḱ' => 'Ḱ', 'ḳ' => 'Ḳ', 'ḵ' => 'Ḵ', 'ḷ' => 'Ḷ', 'ḹ' => 'Ḹ', 'ḻ' => 'Ḻ', 'ḽ' => 'Ḽ', 'ḿ' => 'Ḿ', 'á¹' => 'á¹€', 'ṃ' => 'Ṃ', 'á¹…' => 'Ṅ', 'ṇ' => 'Ṇ', 'ṉ' => 'Ṉ', 'ṋ' => 'Ṋ', 'á¹' => 'Ṍ', 'á¹' => 'Ṏ', 'ṑ' => 'á¹', 'ṓ' => 'á¹’', 'ṕ' => 'á¹”', 'á¹—' => 'á¹–', 'á¹™' => 'Ṙ', 'á¹›' => 'Ṛ', 'á¹' => 'Ṝ', 'ṟ' => 'Ṟ', 'ṡ' => 'á¹ ', 'á¹£' => 'á¹¢', 'á¹¥' => 'Ṥ', 'ṧ' => 'Ṧ', 'ṩ' => 'Ṩ', 'ṫ' => 'Ṫ', 'á¹­' => 'Ṭ', 'ṯ' => 'á¹®', 'á¹±' => 'á¹°', 'á¹³' => 'á¹²', 'á¹µ' => 'á¹´', 'á¹·' => 'Ṷ', 'á¹¹' => 'Ṹ', 'á¹»' => 'Ṻ', 'á¹½' => 'á¹¼', 'ṿ' => 'á¹¾', 'áº' => 'Ẁ', 'ẃ' => 'Ẃ', 'ẅ' => 'Ẅ', 'ẇ' => 'Ẇ', 'ẉ' => 'Ẉ', 'ẋ' => 'Ẋ', 'áº' => 'Ẍ', 'áº' => 'Ẏ', 'ẑ' => 'áº', 'ẓ' => 'Ẓ', 'ẕ' => 'Ẕ', 'ẛ' => 'á¹ ', 'ạ' => 'Ạ', 'ả' => 'Ả', 'ấ' => 'Ấ', 'ầ' => 'Ầ', 'ẩ' => 'Ẩ', 'ẫ' => 'Ẫ', 'ậ' => 'Ậ', 'ắ' => 'Ắ', 'ằ' => 'Ằ', 'ẳ' => 'Ẳ', 'ẵ' => 'Ẵ', 'ặ' => 'Ặ', 'ẹ' => 'Ẹ', 'ẻ' => 'Ẻ', 'ẽ' => 'Ẽ', 'ế' => 'Ế', 'á»' => 'Ề', 'ể' => 'Ể', 'á»…' => 'Ễ', 'ệ' => 'Ệ', 'ỉ' => 'Ỉ', 'ị' => 'Ị', 'á»' => 'Ọ', 'á»' => 'Ỏ', 'ố' => 'á»', 'ồ' => 'á»’', 'ổ' => 'á»”', 'á»—' => 'á»–', 'á»™' => 'Ộ', 'á»›' => 'Ớ', 'á»' => 'Ờ', 'ở' => 'Ở', 'ỡ' => 'á» ', 'ợ' => 'Ợ', 'ụ' => 'Ụ', 'ủ' => 'Ủ', 'ứ' => 'Ứ', 'ừ' => 'Ừ', 'á»­' => 'Ử', 'ữ' => 'á»®', 'á»±' => 'á»°', 'ỳ' => 'Ỳ', 'ỵ' => 'á»´', 'á»·' => 'Ỷ', 'ỹ' => 'Ỹ', 'á»»' => 'Ỻ', 'ỽ' => 'Ỽ', 'ỿ' => 'Ỿ', 'á¼€' => 'Ἀ', 'á¼' => 'Ἁ', 'ἂ' => 'Ἂ', 'ἃ' => 'Ἃ', 'ἄ' => 'Ἄ', 'á¼…' => 'á¼', 'ἆ' => 'Ἆ', 'ἇ' => 'á¼', 'á¼' => 'Ἐ', 'ἑ' => 'á¼™', 'á¼’' => 'Ἒ', 'ἓ' => 'á¼›', 'á¼”' => 'Ἔ', 'ἕ' => 'á¼', 'á¼ ' => 'Ἠ', 'ἡ' => 'Ἡ', 'á¼¢' => 'Ἢ', 'á¼£' => 'Ἣ', 'ἤ' => 'Ἤ', 'á¼¥' => 'á¼­', 'ἦ' => 'á¼®', 'ἧ' => 'Ἧ', 'á¼°' => 'Ἰ', 'á¼±' => 'á¼¹', 'á¼²' => 'Ἲ', 'á¼³' => 'á¼»', 'á¼´' => 'á¼¼', 'á¼µ' => 'á¼½', 'ἶ' => 'á¼¾', 'á¼·' => 'Ἷ', 'á½€' => 'Ὀ', 'á½' => 'Ὁ', 'ὂ' => 'Ὂ', 'ὃ' => 'Ὃ', 'ὄ' => 'Ὄ', 'á½…' => 'á½', 'ὑ' => 'á½™', 'ὓ' => 'á½›', 'ὕ' => 'á½', 'á½—' => 'Ὗ', 'á½ ' => 'Ὠ', 'ὡ' => 'Ὡ', 'á½¢' => 'Ὢ', 'á½£' => 'Ὣ', 'ὤ' => 'Ὤ', 'á½¥' => 'á½­', 'ὦ' => 'á½®', 'ὧ' => 'Ὧ', 'á½°' => 'Ὰ', 'á½±' => 'á¾»', 'á½²' => 'Ὲ', 'á½³' => 'Έ', 'á½´' => 'á¿Š', 'á½µ' => 'á¿‹', 'ὶ' => 'á¿š', 'á½·' => 'á¿›', 'ὸ' => 'Ὸ', 'á½¹' => 'Ό', 'ὺ' => 'Ὺ', 'á½»' => 'á¿«', 'á½¼' => 'Ὼ', 'á½½' => 'á¿»', 'á¾€' => 'ᾈ', 'á¾' => 'ᾉ', 'ᾂ' => 'ᾊ', 'ᾃ' => 'ᾋ', 'ᾄ' => 'ᾌ', 'á¾…' => 'á¾', 'ᾆ' => 'ᾎ', 'ᾇ' => 'á¾', 'á¾' => 'ᾘ', 'ᾑ' => 'á¾™', 'á¾’' => 'ᾚ', 'ᾓ' => 'á¾›', 'á¾”' => 'ᾜ', 'ᾕ' => 'á¾', 'á¾–' => 'ᾞ', 'á¾—' => 'ᾟ', 'á¾ ' => 'ᾨ', 'ᾡ' => 'ᾩ', 'á¾¢' => 'ᾪ', 'á¾£' => 'ᾫ', 'ᾤ' => 'ᾬ', 'á¾¥' => 'á¾­', 'ᾦ' => 'á¾®', 'ᾧ' => 'ᾯ', 'á¾°' => 'Ᾰ', 'á¾±' => 'á¾¹', 'á¾³' => 'á¾¼', 'á¾¾' => 'Ι', 'ῃ' => 'á¿Œ', 'á¿' => 'Ῐ', 'á¿‘' => 'á¿™', 'á¿ ' => 'Ῠ', 'á¿¡' => 'á¿©', 'á¿¥' => 'Ῥ', 'ῳ' => 'ῼ', 'â…Ž' => 'Ⅎ', 'â…°' => 'â… ', 'â…±' => 'â…¡', 'â…²' => 'â…¢', 'â…³' => 'â…£', 'â…´' => 'â…¤', 'â…µ' => 'â…¥', 'â…¶' => 'â…¦', 'â…·' => 'â…§', 'â…¸' => 'â…¨', 'â…¹' => 'â…©', 'â…º' => 'â…ª', 'â…»' => 'â…«', 'â…¼' => 'â…¬', 'â…½' => 'â…­', 'â…¾' => 'â…®', 'â…¿' => 'â…¯', 'ↄ' => 'Ↄ', 'â“' => 'â’¶', 'â“‘' => 'â’·', 'â“’' => 'â’¸', 'â““' => 'â’¹', 'â“”' => 'â’º', 'â“•' => 'â’»', 'â“–' => 'â’¼', 'â“—' => 'â’½', 'ⓘ' => 'â’¾', 'â“™' => 'â’¿', 'â“š' => 'â“€', 'â“›' => 'â“', 'â“œ' => 'â“‚', 'â“' => 'Ⓝ', 'â“ž' => 'â“„', 'â“Ÿ' => 'â“…', 'â“ ' => 'Ⓠ', 'â“¡' => 'Ⓡ', 'â“¢' => 'Ⓢ', 'â“£' => 'Ⓣ', 'ⓤ' => 'â“Š', 'â“¥' => 'â“‹', 'ⓦ' => 'â“Œ', 'ⓧ' => 'â“', 'ⓨ' => 'â“Ž', 'â“©' => 'â“', 'â°°' => 'â°€', 'â°±' => 'â°', 'â°²' => 'â°‚', 'â°³' => 'â°ƒ', 'â°´' => 'â°„', 'â°µ' => 'â°…', 'â°¶' => 'â°†', 'â°·' => 'â°‡', 'â°¸' => 'â°ˆ', 'â°¹' => 'â°‰', 'â°º' => 'â°Š', 'â°»' => 'â°‹', 'â°¼' => 'â°Œ', 'â°½' => 'â°', 'â°¾' => 'â°Ž', 'â°¿' => 'â°', 'â±€' => 'â°', 'â±' => 'â°‘', 'ⱂ' => 'â°’', 'ⱃ' => 'â°“', 'ⱄ' => 'â°”', 'â±…' => 'â°•', 'ⱆ' => 'â°–', 'ⱇ' => 'â°—', 'ⱈ' => 'â°˜', 'ⱉ' => 'â°™', 'ⱊ' => 'â°š', 'ⱋ' => 'â°›', 'ⱌ' => 'â°œ', 'â±' => 'â°', 'ⱎ' => 'â°ž', 'â±' => 'â°Ÿ', 'â±' => 'â° ', 'ⱑ' => 'â°¡', 'â±’' => 'â°¢', 'ⱓ' => 'â°£', 'â±”' => 'â°¤', 'ⱕ' => 'â°¥', 'â±–' => 'â°¦', 'â±—' => 'â°§', 'ⱘ' => 'â°¨', 'â±™' => 'â°©', 'ⱚ' => 'â°ª', 'â±›' => 'â°«', 'ⱜ' => 'â°¬', 'â±' => 'â°­', 'ⱞ' => 'â°®', 'ⱡ' => 'â± ', 'â±¥' => 'Ⱥ', 'ⱦ' => 'Ⱦ', 'ⱨ' => 'Ⱨ', 'ⱪ' => 'Ⱪ', 'ⱬ' => 'Ⱬ', 'â±³' => 'â±²', 'ⱶ' => 'â±µ', 'â²' => 'â²€', 'ⲃ' => 'Ⲃ', 'â²…' => 'Ⲅ', 'ⲇ' => 'Ⲇ', 'ⲉ' => 'Ⲉ', 'ⲋ' => 'Ⲋ', 'â²' => 'Ⲍ', 'â²' => 'Ⲏ', 'ⲑ' => 'â²', 'ⲓ' => 'â²’', 'ⲕ' => 'â²”', 'â²—' => 'â²–', 'â²™' => 'Ⲙ', 'â²›' => 'Ⲛ', 'â²' => 'Ⲝ', 'ⲟ' => 'Ⲟ', 'ⲡ' => 'â² ', 'â²£' => 'â²¢', 'â²¥' => 'Ⲥ', 'ⲧ' => 'Ⲧ', 'ⲩ' => 'Ⲩ', 'ⲫ' => 'Ⲫ', 'â²­' => 'Ⲭ', 'ⲯ' => 'â²®', 'â²±' => 'â²°', 'â²³' => 'â²²', 'â²µ' => 'â²´', 'â²·' => 'Ⲷ', 'â²¹' => 'Ⲹ', 'â²»' => 'Ⲻ', 'â²½' => 'â²¼', 'ⲿ' => 'â²¾', 'â³' => 'â³€', 'ⳃ' => 'Ⳃ', 'â³…' => 'Ⳅ', 'ⳇ' => 'Ⳇ', 'ⳉ' => 'Ⳉ', 'ⳋ' => 'Ⳋ', 'â³' => 'Ⳍ', 'â³' => 'Ⳏ', 'ⳑ' => 'â³', 'ⳓ' => 'â³’', 'ⳕ' => 'â³”', 'â³—' => 'â³–', 'â³™' => 'Ⳙ', 'â³›' => 'Ⳛ', 'â³' => 'Ⳝ', 'ⳟ' => 'Ⳟ', 'ⳡ' => 'â³ ', 'â³£' => 'â³¢', 'ⳬ' => 'Ⳬ', 'â³®' => 'â³­', 'â³³' => 'â³²', 'â´€' => 'á‚ ', 'â´' => 'á‚¡', 'â´‚' => 'á‚¢', 'â´ƒ' => 'á‚£', 'â´„' => 'Ⴄ', 'â´…' => 'á‚¥', 'â´†' => 'Ⴆ', 'â´‡' => 'Ⴇ', 'â´ˆ' => 'Ⴈ', 'â´‰' => 'á‚©', 'â´Š' => 'Ⴊ', 'â´‹' => 'á‚«', 'â´Œ' => 'Ⴌ', 'â´' => 'á‚­', 'â´Ž' => 'á‚®', 'â´' => 'Ⴏ', 'â´' => 'á‚°', 'â´‘' => 'Ⴑ', 'â´’' => 'Ⴒ', 'â´“' => 'Ⴓ', 'â´”' => 'á‚´', 'â´•' => 'Ⴕ', 'â´–' => 'Ⴖ', 'â´—' => 'á‚·', 'â´˜' => 'Ⴘ', 'â´™' => 'Ⴙ', 'â´š' => 'Ⴚ', 'â´›' => 'á‚»', 'â´œ' => 'Ⴜ', 'â´' => 'Ⴝ', 'â´ž' => 'Ⴞ', 'â´Ÿ' => 'á‚¿', 'â´ ' => 'Ⴠ', 'â´¡' => 'áƒ', 'â´¢' => 'Ⴢ', 'â´£' => 'Ⴣ', 'â´¤' => 'Ⴤ', 'â´¥' => 'Ⴥ', 'â´§' => 'Ⴧ', 'â´­' => 'áƒ', 'ê™' => 'Ꙁ', 'ꙃ' => 'Ꙃ', 'ê™…' => 'Ꙅ', 'ꙇ' => 'Ꙇ', 'ꙉ' => 'Ꙉ', 'ꙋ' => 'Ꙋ', 'ê™' => 'Ꙍ', 'ê™' => 'Ꙏ', 'ꙑ' => 'ê™', 'ꙓ' => 'ê™’', 'ꙕ' => 'ê™”', 'ê™—' => 'ê™–', 'ê™™' => 'Ꙙ', 'ê™›' => 'Ꙛ', 'ê™' => 'Ꙝ', 'ꙟ' => 'Ꙟ', 'ꙡ' => 'ê™ ', 'ꙣ' => 'Ꙣ', 'ꙥ' => 'Ꙥ', 'ꙧ' => 'Ꙧ', 'ꙩ' => 'Ꙩ', 'ꙫ' => 'Ꙫ', 'ê™­' => 'Ꙭ', 'êš' => 'Ꚁ', 'ꚃ' => 'êš‚', 'êš…' => 'êš„', 'ꚇ' => 'Ꚇ', 'ꚉ' => 'Ꚉ', 'êš‹' => 'Ꚋ', 'êš' => 'Ꚍ', 'êš' => 'Ꚏ', 'êš‘' => 'êš', 'êš“' => 'êš’', 'êš•' => 'êš”', 'êš—' => 'êš–', 'êš™' => 'Ꚙ', 'êš›' => 'êšš', 'ꜣ' => 'Ꜣ', 'ꜥ' => 'Ꜥ', 'ꜧ' => 'Ꜧ', 'ꜩ' => 'Ꜩ', 'ꜫ' => 'Ꜫ', 'ꜭ' => 'Ꜭ', 'ꜯ' => 'Ꜯ', 'ꜳ' => 'Ꜳ', 'ꜵ' => 'Ꜵ', 'ꜷ' => 'Ꜷ', 'ꜹ' => 'Ꜹ', 'ꜻ' => 'Ꜻ', 'ꜽ' => 'Ꜽ', 'ꜿ' => 'Ꜿ', 'ê' => 'ê€', 'êƒ' => 'ê‚', 'ê…' => 'ê„', 'ê‡' => 'ê†', 'ê‰' => 'êˆ', 'ê‹' => 'êŠ', 'ê' => 'êŒ', 'ê' => 'êŽ', 'ê‘' => 'ê', 'ê“' => 'ê’', 'ê•' => 'ê”', 'ê—' => 'ê–', 'ê™' => 'ê˜', 'ê›' => 'êš', 'ê' => 'êœ', 'êŸ' => 'êž', 'ê¡' => 'ê ', 'ê£' => 'ê¢', 'ê¥' => 'ê¤', 'ê§' => 'ê¦', 'ê©' => 'ê¨', 'ê«' => 'êª', 'ê­' => 'ê¬', 'ê¯' => 'ê®', 'êº' => 'ê¹', 'ê¼' => 'ê»', 'ê¿' => 'ê¾', 'êž' => 'Ꞁ', 'ꞃ' => 'êž‚', 'êž…' => 'êž„', 'ꞇ' => 'Ꞇ', 'ꞌ' => 'êž‹', 'êž‘' => 'êž', 'êž“' => 'êž’', 'êž—' => 'êž–', 'êž™' => 'Ꞙ', 'êž›' => 'êžš', 'êž' => 'êžœ', 'ꞟ' => 'êžž', 'êž¡' => 'êž ', 'ꞣ' => 'Ꞣ', 'ꞥ' => 'Ꞥ', 'ꞧ' => 'Ꞧ', 'êž©' => 'Ꞩ', 'ï½' => 'A', 'b' => 'ï¼¢', 'c' => 'ï¼£', 'd' => 'D', 'ï½…' => 'ï¼¥', 'f' => 'F', 'g' => 'G', 'h' => 'H', 'i' => 'I', 'j' => 'J', 'k' => 'K', 'l' => 'L', 'ï½' => 'ï¼­', 'n' => 'ï¼®', 'ï½' => 'O', 'ï½' => 'ï¼°', 'q' => 'ï¼±', 'ï½’' => 'ï¼²', 's' => 'ï¼³', 'ï½”' => 'ï¼´', 'u' => 'ï¼µ', 'ï½–' => 'V', 'ï½—' => 'ï¼·', 'x' => 'X', 'ï½™' => 'ï¼¹', 'z' => 'Z', 'ð¨' => 'ð€', 'ð©' => 'ð', 'ðª' => 'ð‚', 'ð«' => 'ðƒ', 'ð¬' => 'ð„', 'ð­' => 'ð…', 'ð®' => 'ð†', 'ð¯' => 'ð‡', 'ð°' => 'ðˆ', 'ð±' => 'ð‰', 'ð²' => 'ðŠ', 'ð³' => 'ð‹', 'ð´' => 'ðŒ', 'ðµ' => 'ð', 'ð¶' => 'ðŽ', 'ð·' => 'ð', 'ð¸' => 'ð', 'ð¹' => 'ð‘', 'ðº' => 'ð’', 'ð»' => 'ð“', 'ð¼' => 'ð”', 'ð½' => 'ð•', 'ð¾' => 'ð–', 'ð¿' => 'ð—', 'ð‘€' => 'ð˜', 'ð‘' => 'ð™', 'ð‘‚' => 'ðš', 'ð‘ƒ' => 'ð›', 'ð‘„' => 'ðœ', 'ð‘…' => 'ð', 'ð‘†' => 'ðž', 'ð‘‡' => 'ðŸ', 'ð‘ˆ' => 'ð ', 'ð‘‰' => 'ð¡', 'ð‘Š' => 'ð¢', 'ð‘‹' => 'ð£', 'ð‘Œ' => 'ð¤', 'ð‘' => 'ð¥', 'ð‘Ž' => 'ð¦', 'ð‘' => 'ð§', 'ð‘£€' => 'ð‘¢ ', 'ð‘£' => '𑢡', '𑣂' => 'ð‘¢¢', '𑣃' => 'ð‘¢£', '𑣄' => '𑢤', 'ð‘£…' => 'ð‘¢¥', '𑣆' => '𑢦', '𑣇' => '𑢧', '𑣈' => '𑢨', '𑣉' => '𑢩', '𑣊' => '𑢪', '𑣋' => '𑢫', '𑣌' => '𑢬', 'ð‘£' => 'ð‘¢­', '𑣎' => 'ð‘¢®', 'ð‘£' => '𑢯', 'ð‘£' => 'ð‘¢°', '𑣑' => 'ð‘¢±', 'ð‘£’' => 'ð‘¢²', '𑣓' => 'ð‘¢³', 'ð‘£”' => 'ð‘¢´', '𑣕' => 'ð‘¢µ', 'ð‘£–' => '𑢶', 'ð‘£—' => 'ð‘¢·', '𑣘' => '𑢸', 'ð‘£™' => 'ð‘¢¹', '𑣚' => '𑢺', 'ð‘£›' => 'ð‘¢»', '𑣜' => 'ð‘¢¼', 'ð‘£' => 'ð‘¢½', '𑣞' => 'ð‘¢¾', '𑣟' => '𑢿'); diff --git a/vendor/symfony/polyfill-mbstring/bootstrap.php b/vendor/symfony/polyfill-mbstring/bootstrap.php index f2462fc52..773a21cba 100644 --- a/vendor/symfony/polyfill-mbstring/bootstrap.php +++ b/vendor/symfony/polyfill-mbstring/bootstrap.php @@ -1,177 +1,177 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring as p; -if (!\defined('MB_CASE_UPPER')) { - \define('MB_CASE_UPPER', 0); - \define('MB_CASE_LOWER', 1); - \define('MB_CASE_TITLE', 2); -} -if (!\function_exists('mb_strlen')) { - function mb_convert_encoding($s, $to, $from = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_convert_encoding($s, $to, $from); - } - function mb_decode_mimeheader($s) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_decode_mimeheader($s); - } - function mb_encode_mimeheader($s, $charset = null, $transferEnc = null, $lf = null, $indent = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_encode_mimeheader($s, $charset, $transferEnc, $lf, $indent); - } - function mb_decode_numericentity($s, $convmap, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_decode_numericentity($s, $convmap, $enc); - } - function mb_encode_numericentity($s, $convmap, $enc = null, $is_hex = \false) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_encode_numericentity($s, $convmap, $enc, $is_hex); - } - function mb_convert_case($s, $mode, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_convert_case($s, $mode, $enc); - } - function mb_internal_encoding($enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_internal_encoding($enc); - } - function mb_language($lang = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_language($lang); - } - function mb_list_encodings() - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_list_encodings(); - } - function mb_encoding_aliases($encoding) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_encoding_aliases($encoding); - } - function mb_check_encoding($var = null, $encoding = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_check_encoding($var, $encoding); - } - function mb_detect_encoding($str, $encodingList = null, $strict = \false) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_detect_encoding($str, $encodingList, $strict); - } - function mb_detect_order($encodingList = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_detect_order($encodingList); - } - function mb_parse_str($s, &$result = array()) - { - \parse_str($s, $result); - } - function mb_strlen($s, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strlen($s, $enc); - } - function mb_strpos($s, $needle, $offset = 0, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strpos($s, $needle, $offset, $enc); - } - function mb_strtolower($s, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strtolower($s, $enc); - } - function mb_strtoupper($s, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strtoupper($s, $enc); - } - function mb_substitute_character($char = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_substitute_character($char); - } - function mb_substr($s, $start, $length = 2147483647, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_substr($s, $start, $length, $enc); - } - function mb_stripos($s, $needle, $offset = 0, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_stripos($s, $needle, $offset, $enc); - } - function mb_stristr($s, $needle, $part = \false, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_stristr($s, $needle, $part, $enc); - } - function mb_strrchr($s, $needle, $part = \false, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strrchr($s, $needle, $part, $enc); - } - function mb_strrichr($s, $needle, $part = \false, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strrichr($s, $needle, $part, $enc); - } - function mb_strripos($s, $needle, $offset = 0, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strripos($s, $needle, $offset, $enc); - } - function mb_strrpos($s, $needle, $offset = 0, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strrpos($s, $needle, $offset, $enc); - } - function mb_strstr($s, $needle, $part = \false, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strstr($s, $needle, $part, $enc); - } - function mb_get_info($type = 'all') - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_get_info($type); - } - function mb_http_output($enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_http_output($enc); - } - function mb_strwidth($s, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strwidth($s, $enc); - } - function mb_substr_count($haystack, $needle, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_substr_count($haystack, $needle, $enc); - } - function mb_output_handler($contents, $status) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_output_handler($contents, $status); - } - function mb_http_input($type = '') - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_http_input($type); - } - function mb_convert_variables($toEncoding, $fromEncoding, &$a = null, &$b = null, &$c = null, &$d = null, &$e = null, &$f = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_convert_variables($toEncoding, $fromEncoding, $a, $b, $c, $d, $e, $f); - } -} -if (!\function_exists('_PhpScoper5ea00cc67502b\\mb_chr')) { - function mb_ord($s, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_ord($s, $enc); - } - function mb_chr($code, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_chr($code, $enc); - } - function mb_scrub($s, $enc = null) - { - $enc = null === $enc ? \mb_internal_encoding() : $enc; - return \mb_convert_encoding($s, $enc, $enc); - } -} -if (!\function_exists('_PhpScoper5ea00cc67502b\\mb_str_split')) { - function mb_str_split($string, $split_length = 1, $encoding = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_str_split($string, $split_length, $encoding); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring as p; +if (!\defined('MB_CASE_UPPER')) { + \define('MB_CASE_UPPER', 0); + \define('MB_CASE_LOWER', 1); + \define('MB_CASE_TITLE', 2); +} +if (!\function_exists('mb_strlen')) { + function mb_convert_encoding($s, $to, $from = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_convert_encoding($s, $to, $from); + } + function mb_decode_mimeheader($s) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_decode_mimeheader($s); + } + function mb_encode_mimeheader($s, $charset = null, $transferEnc = null, $lf = null, $indent = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_encode_mimeheader($s, $charset, $transferEnc, $lf, $indent); + } + function mb_decode_numericentity($s, $convmap, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_decode_numericentity($s, $convmap, $enc); + } + function mb_encode_numericentity($s, $convmap, $enc = null, $is_hex = \false) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_encode_numericentity($s, $convmap, $enc, $is_hex); + } + function mb_convert_case($s, $mode, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_convert_case($s, $mode, $enc); + } + function mb_internal_encoding($enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_internal_encoding($enc); + } + function mb_language($lang = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_language($lang); + } + function mb_list_encodings() + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_list_encodings(); + } + function mb_encoding_aliases($encoding) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_encoding_aliases($encoding); + } + function mb_check_encoding($var = null, $encoding = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_check_encoding($var, $encoding); + } + function mb_detect_encoding($str, $encodingList = null, $strict = \false) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_detect_encoding($str, $encodingList, $strict); + } + function mb_detect_order($encodingList = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_detect_order($encodingList); + } + function mb_parse_str($s, &$result = array()) + { + \parse_str($s, $result); + } + function mb_strlen($s, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strlen($s, $enc); + } + function mb_strpos($s, $needle, $offset = 0, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strpos($s, $needle, $offset, $enc); + } + function mb_strtolower($s, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strtolower($s, $enc); + } + function mb_strtoupper($s, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strtoupper($s, $enc); + } + function mb_substitute_character($char = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_substitute_character($char); + } + function mb_substr($s, $start, $length = 2147483647, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_substr($s, $start, $length, $enc); + } + function mb_stripos($s, $needle, $offset = 0, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_stripos($s, $needle, $offset, $enc); + } + function mb_stristr($s, $needle, $part = \false, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_stristr($s, $needle, $part, $enc); + } + function mb_strrchr($s, $needle, $part = \false, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strrchr($s, $needle, $part, $enc); + } + function mb_strrichr($s, $needle, $part = \false, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strrichr($s, $needle, $part, $enc); + } + function mb_strripos($s, $needle, $offset = 0, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strripos($s, $needle, $offset, $enc); + } + function mb_strrpos($s, $needle, $offset = 0, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strrpos($s, $needle, $offset, $enc); + } + function mb_strstr($s, $needle, $part = \false, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strstr($s, $needle, $part, $enc); + } + function mb_get_info($type = 'all') + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_get_info($type); + } + function mb_http_output($enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_http_output($enc); + } + function mb_strwidth($s, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_strwidth($s, $enc); + } + function mb_substr_count($haystack, $needle, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_substr_count($haystack, $needle, $enc); + } + function mb_output_handler($contents, $status) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_output_handler($contents, $status); + } + function mb_http_input($type = '') + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_http_input($type); + } + function mb_convert_variables($toEncoding, $fromEncoding, &$a = null, &$b = null, &$c = null, &$d = null, &$e = null, &$f = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_convert_variables($toEncoding, $fromEncoding, $a, $b, $c, $d, $e, $f); + } +} +if (!\function_exists('_PhpScoper5ea00cc67502b\\mb_chr')) { + function mb_ord($s, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_ord($s, $enc); + } + function mb_chr($code, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_chr($code, $enc); + } + function mb_scrub($s, $enc = null) + { + $enc = null === $enc ? \mb_internal_encoding() : $enc; + return \mb_convert_encoding($s, $enc, $enc); + } +} +if (!\function_exists('_PhpScoper5ea00cc67502b\\mb_str_split')) { + function mb_str_split($string, $split_length = 1, $encoding = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Mbstring\Mbstring::mb_str_split($string, $split_length, $encoding); + } +} diff --git a/vendor/symfony/polyfill-mbstring/composer.json b/vendor/symfony/polyfill-mbstring/composer.json index 399a49b5a..cb4b2a1bd 100644 --- a/vendor/symfony/polyfill-mbstring/composer.json +++ b/vendor/symfony/polyfill-mbstring/composer.json @@ -1,44 +1,44 @@ -{ - "name": "symfony\/polyfill-mbstring", - "type": "library", - "description": "Symfony polyfill for the Mbstring extension", - "keywords": [ - "polyfill", - "shim", - "compatibility", - "portable", - "mbstring" - ], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": ">=5.3.3" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "suggest": { - "ext-mbstring": "For best performance" - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - } +{ + "name": "symfony\/polyfill-mbstring", + "type": "library", + "description": "Symfony polyfill for the Mbstring extension", + "keywords": [ + "polyfill", + "shim", + "compatibility", + "portable", + "mbstring" + ], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": ">=5.3.3" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Mbstring\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "suggest": { + "ext-mbstring": "For best performance" + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/polyfill-mbstring/index.php b/vendor/symfony/polyfill-mbstring/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/polyfill-mbstring/index.php +++ b/vendor/symfony/polyfill-mbstring/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-php70/LICENSE b/vendor/symfony/polyfill-php70/LICENSE index 4cd8bdd30..adb8d6f64 100644 --- a/vendor/symfony/polyfill-php70/LICENSE +++ b/vendor/symfony/polyfill-php70/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2015-2019 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2015-2019 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/polyfill-php70/Php70.php b/vendor/symfony/polyfill-php70/Php70.php index abc2c140d..63a980e5d 100644 --- a/vendor/symfony/polyfill-php70/Php70.php +++ b/vendor/symfony/polyfill-php70/Php70.php @@ -1,67 +1,67 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Polyfill\Php70; - -/** - * @author Nicolas Grekas - * - * @internal - */ -final class Php70 -{ - public static function intdiv($dividend, $divisor) - { - $dividend = self::intArg($dividend, __FUNCTION__, 1); - $divisor = self::intArg($divisor, __FUNCTION__, 2); - if (0 === $divisor) { - throw new \DivisionByZeroError('Division by zero'); - } - if (-1 === $divisor && ~\PHP_INT_MAX === $dividend) { - throw new \ArithmeticError('Division of PHP_INT_MIN by -1 is not an integer'); - } - return ($dividend - $dividend % $divisor) / $divisor; - } - public static function preg_replace_callback_array(array $patterns, $subject, $limit = -1, &$count = 0) - { - $count = 0; - $result = (string) $subject; - if (0 === ($limit = self::intArg($limit, __FUNCTION__, 3))) { - return $result; - } - foreach ($patterns as $pattern => $callback) { - $result = \preg_replace_callback($pattern, $callback, $result, $limit, $c); - $count += $c; - } - return $result; - } - public static function error_clear_last() - { - static $handler; - if (!$handler) { - $handler = function () { - return \false; - }; - } - \set_error_handler($handler); - @\trigger_error(''); - \restore_error_handler(); - } - private static function intArg($value, $caller, $pos) - { - if (\is_int($value)) { - return $value; - } - if (!\is_numeric($value) || \PHP_INT_MAX <= ($value += 0) || ~\PHP_INT_MAX >= $value) { - throw new \TypeError(\sprintf('%s() expects parameter %d to be integer, %s given', $caller, $pos, \gettype($value))); - } - return (int) $value; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Polyfill\Php70; + +/** + * @author Nicolas Grekas + * + * @internal + */ +final class Php70 +{ + public static function intdiv($dividend, $divisor) + { + $dividend = self::intArg($dividend, __FUNCTION__, 1); + $divisor = self::intArg($divisor, __FUNCTION__, 2); + if (0 === $divisor) { + throw new \DivisionByZeroError('Division by zero'); + } + if (-1 === $divisor && ~\PHP_INT_MAX === $dividend) { + throw new \ArithmeticError('Division of PHP_INT_MIN by -1 is not an integer'); + } + return ($dividend - $dividend % $divisor) / $divisor; + } + public static function preg_replace_callback_array(array $patterns, $subject, $limit = -1, &$count = 0) + { + $count = 0; + $result = (string) $subject; + if (0 === ($limit = self::intArg($limit, __FUNCTION__, 3))) { + return $result; + } + foreach ($patterns as $pattern => $callback) { + $result = \preg_replace_callback($pattern, $callback, $result, $limit, $c); + $count += $c; + } + return $result; + } + public static function error_clear_last() + { + static $handler; + if (!$handler) { + $handler = function () { + return \false; + }; + } + \set_error_handler($handler); + @\trigger_error(''); + \restore_error_handler(); + } + private static function intArg($value, $caller, $pos) + { + if (\is_int($value)) { + return $value; + } + if (!\is_numeric($value) || \PHP_INT_MAX <= ($value += 0) || ~\PHP_INT_MAX >= $value) { + throw new \TypeError(\sprintf('%s() expects parameter %d to be integer, %s given', $caller, $pos, \gettype($value))); + } + return (int) $value; + } +} diff --git a/vendor/symfony/polyfill-php70/README.md b/vendor/symfony/polyfill-php70/README.md index abd548823..7b66c37df 100644 --- a/vendor/symfony/polyfill-php70/README.md +++ b/vendor/symfony/polyfill-php70/README.md @@ -1,28 +1,28 @@ -Symfony Polyfill / Php70 -======================== - -This component provides features unavailable in releases prior to PHP 7.0: - -- [`intdiv`](https://php.net/intdiv) -- [`preg_replace_callback_array`](https://php.net/preg_replace_callback_array) -- [`error_clear_last`](https://php.net/error_clear_last) -- `random_bytes` and `random_int` (from [paragonie/random_compat](https://github.com/paragonie/random_compat)) -- [`*Error` throwable classes](https://php.net/Error) -- [`PHP_INT_MIN`](https://php.net/reserved.constants#constant.php-int-min) -- `SessionUpdateTimestampHandlerInterface` - -More information can be found in the -[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). - -Compatibility notes -=================== - -To write portable code between PHP5 and PHP7, some care must be taken: -- `\*Error` exceptions must be caught before `\Exception`; -- after calling `error_clear_last()`, the result of `$e = error_get_last()` must be - verified using `isset($e['message'][0])` instead of `null !== $e`. - -License -======= - -This library is released under the [MIT license](LICENSE). +Symfony Polyfill / Php70 +======================== + +This component provides features unavailable in releases prior to PHP 7.0: + +- [`intdiv`](https://php.net/intdiv) +- [`preg_replace_callback_array`](https://php.net/preg_replace_callback_array) +- [`error_clear_last`](https://php.net/error_clear_last) +- `random_bytes` and `random_int` (from [paragonie/random_compat](https://github.com/paragonie/random_compat)) +- [`*Error` throwable classes](https://php.net/Error) +- [`PHP_INT_MIN`](https://php.net/reserved.constants#constant.php-int-min) +- `SessionUpdateTimestampHandlerInterface` + +More information can be found in the +[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). + +Compatibility notes +=================== + +To write portable code between PHP5 and PHP7, some care must be taken: +- `\*Error` exceptions must be caught before `\Exception`; +- after calling `error_clear_last()`, the result of `$e = error_get_last()` must be + verified using `isset($e['message'][0])` instead of `null !== $e`. + +License +======= + +This library is released under the [MIT license](LICENSE). diff --git a/vendor/symfony/polyfill-php70/Resources/index.php b/vendor/symfony/polyfill-php70/Resources/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/polyfill-php70/Resources/index.php +++ b/vendor/symfony/polyfill-php70/Resources/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-php70/Resources/stubs/ArithmeticError.php b/vendor/symfony/polyfill-php70/Resources/stubs/ArithmeticError.php index c0d3c34b6..61d4a2be2 100644 --- a/vendor/symfony/polyfill-php70/Resources/stubs/ArithmeticError.php +++ b/vendor/symfony/polyfill-php70/Resources/stubs/ArithmeticError.php @@ -1,8 +1,8 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-php70/bootstrap.php b/vendor/symfony/polyfill-php70/bootstrap.php index 764dbbb95..88c2a0056 100644 --- a/vendor/symfony/polyfill-php70/bootstrap.php +++ b/vendor/symfony/polyfill-php70/bootstrap.php @@ -1,36 +1,36 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Php70 as p; -if (\PHP_VERSION_ID < 70000) { - if (!\defined('PHP_INT_MIN')) { - \define('PHP_INT_MIN', ~\PHP_INT_MAX); - } - if (!\function_exists('intdiv')) { - function intdiv($dividend, $divisor) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php70\Php70::intdiv($dividend, $divisor); - } - } - if (!\function_exists('preg_replace_callback_array')) { - function preg_replace_callback_array(array $patterns, $subject, $limit = -1, &$count = 0) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php70\Php70::preg_replace_callback_array($patterns, $subject, $limit, $count); - } - } - if (!\function_exists('error_clear_last')) { - function error_clear_last() - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php70\Php70::error_clear_last(); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Php70 as p; +if (\PHP_VERSION_ID < 70000) { + if (!\defined('PHP_INT_MIN')) { + \define('PHP_INT_MIN', ~\PHP_INT_MAX); + } + if (!\function_exists('intdiv')) { + function intdiv($dividend, $divisor) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php70\Php70::intdiv($dividend, $divisor); + } + } + if (!\function_exists('preg_replace_callback_array')) { + function preg_replace_callback_array(array $patterns, $subject, $limit = -1, &$count = 0) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php70\Php70::preg_replace_callback_array($patterns, $subject, $limit, $count); + } + } + if (!\function_exists('error_clear_last')) { + function error_clear_last() + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php70\Php70::error_clear_last(); + } + } +} diff --git a/vendor/symfony/polyfill-php70/composer.json b/vendor/symfony/polyfill-php70/composer.json index 391943529..5a990673e 100644 --- a/vendor/symfony/polyfill-php70/composer.json +++ b/vendor/symfony/polyfill-php70/composer.json @@ -1,44 +1,44 @@ -{ - "name": "symfony\/polyfill-php70", - "type": "library", - "description": "Symfony polyfill backporting some PHP 7.0+ features to lower PHP versions", - "keywords": [ - "polyfill", - "shim", - "compatibility", - "portable" - ], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": ">=5.3.3", - "paragonie\/random_compat": "~1.0|~2.0|~9.99" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\": "" - }, - "files": [ - "bootstrap.php" - ], - "classmap": [ - "Resources\/stubs" - ] - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - } +{ + "name": "symfony\/polyfill-php70", + "type": "library", + "description": "Symfony polyfill backporting some PHP 7.0+ features to lower PHP versions", + "keywords": [ + "polyfill", + "shim", + "compatibility", + "portable" + ], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": ">=5.3.3", + "paragonie\/random_compat": "~1.0|~2.0|~9.99" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php70\\": "" + }, + "files": [ + "bootstrap.php" + ], + "classmap": [ + "Resources\/stubs" + ] + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/polyfill-php70/index.php b/vendor/symfony/polyfill-php70/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/polyfill-php70/index.php +++ b/vendor/symfony/polyfill-php70/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/polyfill-php72/LICENSE b/vendor/symfony/polyfill-php72/LICENSE index 4cd8bdd30..adb8d6f64 100644 --- a/vendor/symfony/polyfill-php72/LICENSE +++ b/vendor/symfony/polyfill-php72/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2015-2019 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2015-2019 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/polyfill-php72/Php72.php b/vendor/symfony/polyfill-php72/Php72.php index 0839d20ca..3c1214587 100644 --- a/vendor/symfony/polyfill-php72/Php72.php +++ b/vendor/symfony/polyfill-php72/Php72.php @@ -1,175 +1,175 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72; - -/** - * @author Nicolas Grekas - * @author Dariusz RumiÅ„ski - * - * @internal - */ -final class Php72 -{ - private static $hashMask; - public static function utf8_encode($s) - { - $s .= $s; - $len = \strlen($s); - for ($i = $len >> 1, $j = 0; $i < $len; ++$i, ++$j) { - switch (\true) { - case $s[$i] < "€": - $s[$j] = $s[$i]; - break; - case $s[$i] < "À": - $s[$j] = "Â"; - $s[++$j] = $s[$i]; - break; - default: - $s[$j] = "Ã"; - $s[++$j] = \chr(\ord($s[$i]) - 64); - break; - } - } - return \substr($s, 0, $j); - } - public static function utf8_decode($s) - { - $s = (string) $s; - $len = \strlen($s); - for ($i = 0, $j = 0; $i < $len; ++$i, ++$j) { - switch ($s[$i] & "ð") { - case "À": - case "Ð": - $c = \ord($s[$i] & "\37") << 6 | \ord($s[++$i] & "?"); - $s[$j] = $c < 256 ? \chr($c) : '?'; - break; - case "ð": - ++$i; - // no break - case "à": - $s[$j] = '?'; - $i += 2; - break; - default: - $s[$j] = $s[$i]; - } - } - return \substr($s, 0, $j); - } - public static function php_os_family() - { - if ('\\' === \DIRECTORY_SEPARATOR) { - return 'Windows'; - } - $map = array('Darwin' => 'Darwin', 'DragonFly' => 'BSD', 'FreeBSD' => 'BSD', 'NetBSD' => 'BSD', 'OpenBSD' => 'BSD', 'Linux' => 'Linux', 'SunOS' => 'Solaris'); - return isset($map[\PHP_OS]) ? $map[\PHP_OS] : 'Unknown'; - } - public static function spl_object_id($object) - { - if (null === self::$hashMask) { - self::initHashMask(); - } - if (null === ($hash = \spl_object_hash($object))) { - return; - } - return self::$hashMask ^ \hexdec(\substr($hash, 16 - \PHP_INT_SIZE, \PHP_INT_SIZE)); - } - public static function sapi_windows_vt100_support($stream, $enable = null) - { - if (!\is_resource($stream)) { - \trigger_error('sapi_windows_vt100_support() expects parameter 1 to be resource, ' . \gettype($stream) . ' given', \E_USER_WARNING); - return \false; - } - $meta = \stream_get_meta_data($stream); - if ('STDIO' !== $meta['stream_type']) { - \trigger_error('sapi_windows_vt100_support() was not able to analyze the specified stream', \E_USER_WARNING); - return \false; - } - // We cannot actually disable vt100 support if it is set - if (\false === $enable || !self::stream_isatty($stream)) { - return \false; - } - // The native function does not apply to stdin - $meta = \array_map('strtolower', $meta); - $stdin = 'php://stdin' === $meta['uri'] || 'php://fd/0' === $meta['uri']; - return !$stdin && (\false !== \getenv('ANSICON') || 'ON' === \getenv('ConEmuANSI') || 'xterm' === \getenv('TERM') || 'Hyper' === \getenv('TERM_PROGRAM')); - } - public static function stream_isatty($stream) - { - if (!\is_resource($stream)) { - \trigger_error('stream_isatty() expects parameter 1 to be resource, ' . \gettype($stream) . ' given', \E_USER_WARNING); - return \false; - } - if ('\\' === \DIRECTORY_SEPARATOR) { - $stat = @\fstat($stream); - // Check if formatted mode is S_IFCHR - return $stat ? 020000 === ($stat['mode'] & 0170000) : \false; - } - return \function_exists('posix_isatty') && @\posix_isatty($stream); - } - private static function initHashMask() - { - $obj = (object) array(); - self::$hashMask = -1; - // check if we are nested in an output buffering handler to prevent a fatal error with ob_start() below - $obFuncs = array('ob_clean', 'ob_end_clean', 'ob_flush', 'ob_end_flush', 'ob_get_contents', 'ob_get_flush'); - foreach (\debug_backtrace(\PHP_VERSION_ID >= 50400 ? \DEBUG_BACKTRACE_IGNORE_ARGS : \false) as $frame) { - if (isset($frame['function'][0]) && !isset($frame['class']) && 'o' === $frame['function'][0] && \in_array($frame['function'], $obFuncs)) { - $frame['line'] = 0; - break; - } - } - if (!empty($frame['line'])) { - \ob_start(); - \debug_zval_dump($obj); - self::$hashMask = (int) \substr(\ob_get_clean(), 17); - } - self::$hashMask ^= \hexdec(\substr(\spl_object_hash($obj), 16 - \PHP_INT_SIZE, \PHP_INT_SIZE)); - } - public static function mb_chr($code, $encoding = null) - { - if (0x80 > ($code %= 0x200000)) { - $s = \chr($code); - } elseif (0x800 > $code) { - $s = \chr(0xc0 | $code >> 6) . \chr(0x80 | $code & 0x3f); - } elseif (0x10000 > $code) { - $s = \chr(0xe0 | $code >> 12) . \chr(0x80 | $code >> 6 & 0x3f) . \chr(0x80 | $code & 0x3f); - } else { - $s = \chr(0xf0 | $code >> 18) . \chr(0x80 | $code >> 12 & 0x3f) . \chr(0x80 | $code >> 6 & 0x3f) . \chr(0x80 | $code & 0x3f); - } - if ('UTF-8' !== $encoding) { - $s = \mb_convert_encoding($s, $encoding, 'UTF-8'); - } - return $s; - } - public static function mb_ord($s, $encoding = null) - { - if (null == $encoding) { - $s = \mb_convert_encoding($s, 'UTF-8'); - } elseif ('UTF-8' !== $encoding) { - $s = \mb_convert_encoding($s, 'UTF-8', $encoding); - } - if (1 === \strlen($s)) { - return \ord($s); - } - $code = ($s = \unpack('C*', \substr($s, 0, 4))) ? $s[1] : 0; - if (0xf0 <= $code) { - return ($code - 0xf0 << 18) + ($s[2] - 0x80 << 12) + ($s[3] - 0x80 << 6) + $s[4] - 0x80; - } - if (0xe0 <= $code) { - return ($code - 0xe0 << 12) + ($s[2] - 0x80 << 6) + $s[3] - 0x80; - } - if (0xc0 <= $code) { - return ($code - 0xc0 << 6) + $s[2] - 0x80; - } - return $code; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72; + +/** + * @author Nicolas Grekas + * @author Dariusz RumiÅ„ski + * + * @internal + */ +final class Php72 +{ + private static $hashMask; + public static function utf8_encode($s) + { + $s .= $s; + $len = \strlen($s); + for ($i = $len >> 1, $j = 0; $i < $len; ++$i, ++$j) { + switch (\true) { + case $s[$i] < "€": + $s[$j] = $s[$i]; + break; + case $s[$i] < "À": + $s[$j] = "Â"; + $s[++$j] = $s[$i]; + break; + default: + $s[$j] = "Ã"; + $s[++$j] = \chr(\ord($s[$i]) - 64); + break; + } + } + return \substr($s, 0, $j); + } + public static function utf8_decode($s) + { + $s = (string) $s; + $len = \strlen($s); + for ($i = 0, $j = 0; $i < $len; ++$i, ++$j) { + switch ($s[$i] & "ð") { + case "À": + case "Ð": + $c = \ord($s[$i] & "\37") << 6 | \ord($s[++$i] & "?"); + $s[$j] = $c < 256 ? \chr($c) : '?'; + break; + case "ð": + ++$i; + // no break + case "à": + $s[$j] = '?'; + $i += 2; + break; + default: + $s[$j] = $s[$i]; + } + } + return \substr($s, 0, $j); + } + public static function php_os_family() + { + if ('\\' === \DIRECTORY_SEPARATOR) { + return 'Windows'; + } + $map = array('Darwin' => 'Darwin', 'DragonFly' => 'BSD', 'FreeBSD' => 'BSD', 'NetBSD' => 'BSD', 'OpenBSD' => 'BSD', 'Linux' => 'Linux', 'SunOS' => 'Solaris'); + return isset($map[\PHP_OS]) ? $map[\PHP_OS] : 'Unknown'; + } + public static function spl_object_id($object) + { + if (null === self::$hashMask) { + self::initHashMask(); + } + if (null === ($hash = \spl_object_hash($object))) { + return; + } + return self::$hashMask ^ \hexdec(\substr($hash, 16 - \PHP_INT_SIZE, \PHP_INT_SIZE)); + } + public static function sapi_windows_vt100_support($stream, $enable = null) + { + if (!\is_resource($stream)) { + \trigger_error('sapi_windows_vt100_support() expects parameter 1 to be resource, ' . \gettype($stream) . ' given', \E_USER_WARNING); + return \false; + } + $meta = \stream_get_meta_data($stream); + if ('STDIO' !== $meta['stream_type']) { + \trigger_error('sapi_windows_vt100_support() was not able to analyze the specified stream', \E_USER_WARNING); + return \false; + } + // We cannot actually disable vt100 support if it is set + if (\false === $enable || !self::stream_isatty($stream)) { + return \false; + } + // The native function does not apply to stdin + $meta = \array_map('strtolower', $meta); + $stdin = 'php://stdin' === $meta['uri'] || 'php://fd/0' === $meta['uri']; + return !$stdin && (\false !== \getenv('ANSICON') || 'ON' === \getenv('ConEmuANSI') || 'xterm' === \getenv('TERM') || 'Hyper' === \getenv('TERM_PROGRAM')); + } + public static function stream_isatty($stream) + { + if (!\is_resource($stream)) { + \trigger_error('stream_isatty() expects parameter 1 to be resource, ' . \gettype($stream) . ' given', \E_USER_WARNING); + return \false; + } + if ('\\' === \DIRECTORY_SEPARATOR) { + $stat = @\fstat($stream); + // Check if formatted mode is S_IFCHR + return $stat ? 020000 === ($stat['mode'] & 0170000) : \false; + } + return \function_exists('posix_isatty') && @\posix_isatty($stream); + } + private static function initHashMask() + { + $obj = (object) array(); + self::$hashMask = -1; + // check if we are nested in an output buffering handler to prevent a fatal error with ob_start() below + $obFuncs = array('ob_clean', 'ob_end_clean', 'ob_flush', 'ob_end_flush', 'ob_get_contents', 'ob_get_flush'); + foreach (\debug_backtrace(\PHP_VERSION_ID >= 50400 ? \DEBUG_BACKTRACE_IGNORE_ARGS : \false) as $frame) { + if (isset($frame['function'][0]) && !isset($frame['class']) && 'o' === $frame['function'][0] && \in_array($frame['function'], $obFuncs)) { + $frame['line'] = 0; + break; + } + } + if (!empty($frame['line'])) { + \ob_start(); + \debug_zval_dump($obj); + self::$hashMask = (int) \substr(\ob_get_clean(), 17); + } + self::$hashMask ^= \hexdec(\substr(\spl_object_hash($obj), 16 - \PHP_INT_SIZE, \PHP_INT_SIZE)); + } + public static function mb_chr($code, $encoding = null) + { + if (0x80 > ($code %= 0x200000)) { + $s = \chr($code); + } elseif (0x800 > $code) { + $s = \chr(0xc0 | $code >> 6) . \chr(0x80 | $code & 0x3f); + } elseif (0x10000 > $code) { + $s = \chr(0xe0 | $code >> 12) . \chr(0x80 | $code >> 6 & 0x3f) . \chr(0x80 | $code & 0x3f); + } else { + $s = \chr(0xf0 | $code >> 18) . \chr(0x80 | $code >> 12 & 0x3f) . \chr(0x80 | $code >> 6 & 0x3f) . \chr(0x80 | $code & 0x3f); + } + if ('UTF-8' !== $encoding) { + $s = \mb_convert_encoding($s, $encoding, 'UTF-8'); + } + return $s; + } + public static function mb_ord($s, $encoding = null) + { + if (null == $encoding) { + $s = \mb_convert_encoding($s, 'UTF-8'); + } elseif ('UTF-8' !== $encoding) { + $s = \mb_convert_encoding($s, 'UTF-8', $encoding); + } + if (1 === \strlen($s)) { + return \ord($s); + } + $code = ($s = \unpack('C*', \substr($s, 0, 4))) ? $s[1] : 0; + if (0xf0 <= $code) { + return ($code - 0xf0 << 18) + ($s[2] - 0x80 << 12) + ($s[3] - 0x80 << 6) + $s[4] - 0x80; + } + if (0xe0 <= $code) { + return ($code - 0xe0 << 12) + ($s[2] - 0x80 << 6) + $s[3] - 0x80; + } + if (0xc0 <= $code) { + return ($code - 0xc0 << 6) + $s[2] - 0x80; + } + return $code; + } +} diff --git a/vendor/symfony/polyfill-php72/README.md b/vendor/symfony/polyfill-php72/README.md index 8ac181e43..7e5668179 100644 --- a/vendor/symfony/polyfill-php72/README.md +++ b/vendor/symfony/polyfill-php72/README.md @@ -1,27 +1,27 @@ -Symfony Polyfill / Php72 -======================== - -This component provides functions added to PHP 7.2 core: - -- [`spl_object_id`](https://php.net/spl_object_id) -- [`stream_isatty`](https://php.net/stream_isatty) - -On Windows only: - -- [`sapi_windows_vt100_support`](https://php.net/sapi_windows_vt100_support) - -Moved to core since 7.2 (was in the optional XML extension earlier): - -- [`utf8_encode`](https://php.net/utf8_encode) -- [`utf8_decode`](https://php.net/utf8_decode) - -Also, it provides a constant added to PHP 7.2: -- [`PHP_OS_FAMILY`](https://php.net/reserved.constants#constant.php-os-family) - -More information can be found in the -[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). - -License -======= - -This library is released under the [MIT license](LICENSE). +Symfony Polyfill / Php72 +======================== + +This component provides functions added to PHP 7.2 core: + +- [`spl_object_id`](https://php.net/spl_object_id) +- [`stream_isatty`](https://php.net/stream_isatty) + +On Windows only: + +- [`sapi_windows_vt100_support`](https://php.net/sapi_windows_vt100_support) + +Moved to core since 7.2 (was in the optional XML extension earlier): + +- [`utf8_encode`](https://php.net/utf8_encode) +- [`utf8_decode`](https://php.net/utf8_decode) + +Also, it provides a constant added to PHP 7.2: +- [`PHP_OS_FAMILY`](https://php.net/reserved.constants#constant.php-os-family) + +More information can be found in the +[main Polyfill README](https://github.com/symfony/polyfill/blob/master/README.md). + +License +======= + +This library is released under the [MIT license](LICENSE). diff --git a/vendor/symfony/polyfill-php72/bootstrap.php b/vendor/symfony/polyfill-php72/bootstrap.php index 54227492a..e4fa12daa 100644 --- a/vendor/symfony/polyfill-php72/bootstrap.php +++ b/vendor/symfony/polyfill-php72/bootstrap.php @@ -1,61 +1,61 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72 as p; -if (\PHP_VERSION_ID < 70200) { - if ('\\' === \DIRECTORY_SEPARATOR && !\function_exists('sapi_windows_vt100_support')) { - function sapi_windows_vt100_support($stream, $enable = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::sapi_windows_vt100_support($stream, $enable); - } - } - if (!\function_exists('stream_isatty')) { - function stream_isatty($stream) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::stream_isatty($stream); - } - } - if (!\function_exists('utf8_encode')) { - function utf8_encode($s) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::utf8_encode($s); - } - function utf8_decode($s) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::utf8_decode($s); - } - } - if (!\function_exists('spl_object_id')) { - function spl_object_id($s) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::spl_object_id($s); - } - } - if (!\defined('PHP_OS_FAMILY')) { - \define('PHP_OS_FAMILY', \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::php_os_family()); - } - if (!\function_exists('_PhpScoper5ea00cc67502b\\mb_chr')) { - function mb_ord($s, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::mb_ord($s, $enc); - } - function mb_chr($code, $enc = null) - { - return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::mb_chr($code, $enc); - } - function mb_scrub($s, $enc = null) - { - $enc = null === $enc ? \mb_internal_encoding() : $enc; - return \mb_convert_encoding($s, $enc, $enc); - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +use _PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72 as p; +if (\PHP_VERSION_ID < 70200) { + if ('\\' === \DIRECTORY_SEPARATOR && !\function_exists('sapi_windows_vt100_support')) { + function sapi_windows_vt100_support($stream, $enable = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::sapi_windows_vt100_support($stream, $enable); + } + } + if (!\function_exists('stream_isatty')) { + function stream_isatty($stream) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::stream_isatty($stream); + } + } + if (!\function_exists('utf8_encode')) { + function utf8_encode($s) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::utf8_encode($s); + } + function utf8_decode($s) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::utf8_decode($s); + } + } + if (!\function_exists('spl_object_id')) { + function spl_object_id($s) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::spl_object_id($s); + } + } + if (!\defined('PHP_OS_FAMILY')) { + \define('PHP_OS_FAMILY', \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::php_os_family()); + } + if (!\function_exists('_PhpScoper5ea00cc67502b\\mb_chr')) { + function mb_ord($s, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::mb_ord($s, $enc); + } + function mb_chr($code, $enc = null) + { + return \_PhpScoper5ea00cc67502b\Symfony\Polyfill\Php72\Php72::mb_chr($code, $enc); + } + function mb_scrub($s, $enc = null) + { + $enc = null === $enc ? \mb_internal_encoding() : $enc; + return \mb_convert_encoding($s, $enc, $enc); + } + } +} diff --git a/vendor/symfony/polyfill-php72/composer.json b/vendor/symfony/polyfill-php72/composer.json index ac035ec0c..72ce70824 100644 --- a/vendor/symfony/polyfill-php72/composer.json +++ b/vendor/symfony/polyfill-php72/composer.json @@ -1,40 +1,40 @@ -{ - "name": "symfony\/polyfill-php72", - "type": "library", - "description": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", - "keywords": [ - "polyfill", - "shim", - "compatibility", - "portable" - ], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": ">=5.3.3" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "1.15-dev" - } - } +{ + "name": "symfony\/polyfill-php72", + "type": "library", + "description": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", + "keywords": [ + "polyfill", + "shim", + "compatibility", + "portable" + ], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": ">=5.3.3" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Polyfill\\Php72\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "1.15-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/polyfill-php72/index.php b/vendor/symfony/polyfill-php72/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/polyfill-php72/index.php +++ b/vendor/symfony/polyfill-php72/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/.gitignore b/vendor/symfony/yaml/.gitignore index c49a5d8df..e31d97a46 100644 --- a/vendor/symfony/yaml/.gitignore +++ b/vendor/symfony/yaml/.gitignore @@ -1,3 +1,3 @@ -vendor/ -composer.lock -phpunit.xml +vendor/ +composer.lock +phpunit.xml diff --git a/vendor/symfony/yaml/CHANGELOG.md b/vendor/symfony/yaml/CHANGELOG.md index fd41c9dd2..ea015eb1b 100644 --- a/vendor/symfony/yaml/CHANGELOG.md +++ b/vendor/symfony/yaml/CHANGELOG.md @@ -1,149 +1,149 @@ -CHANGELOG -========= - -3.4.0 ------ - - * added support for parsing YAML files using the `Yaml::parseFile()` or `Parser::parseFile()` method - - * the `Dumper`, `Parser`, and `Yaml` classes are marked as final - - * Deprecated the `!php/object:` tag which will be replaced by the - `!php/object` tag (without the colon) in 4.0. - - * Deprecated the `!php/const:` tag which will be replaced by the - `!php/const` tag (without the colon) in 4.0. - - * Support for the `!str` tag is deprecated, use the `!!str` tag instead. - - * Deprecated using the non-specific tag `!` as its behavior will change in 4.0. - It will force non-evaluating your values in 4.0. Use plain integers or `!!float` instead. - -3.3.0 ------ - - * Starting an unquoted string with a question mark followed by a space is - deprecated and will throw a `ParseException` in Symfony 4.0. - - * Deprecated support for implicitly parsing non-string mapping keys as strings. - Mapping keys that are no strings will lead to a `ParseException` in Symfony - 4.0. Use quotes to opt-in for keys to be parsed as strings. - - Before: - - ```php - $yaml = << new A(), 'bar' => 1], 0, 0, Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE | Yaml::DUMP_OBJECT); - ``` - -3.0.0 ------ - - * Yaml::parse() now throws an exception when a blackslash is not escaped - in double-quoted strings - -2.8.0 ------ - - * Deprecated usage of a colon in an unquoted mapping value - * Deprecated usage of @, \`, | and > at the beginning of an unquoted string - * When surrounding strings with double-quotes, you must now escape `\` characters. Not - escaping those characters (when surrounded by double-quotes) is deprecated. - - Before: - - ```yml - class: "Foo\Var" - ``` - - After: - - ```yml - class: "Foo\\Var" - ``` - -2.1.0 ------ - - * Yaml::parse() does not evaluate loaded files as PHP files by default - anymore (call Yaml::enablePhpParsing() to get back the old behavior) +CHANGELOG +========= + +3.4.0 +----- + + * added support for parsing YAML files using the `Yaml::parseFile()` or `Parser::parseFile()` method + + * the `Dumper`, `Parser`, and `Yaml` classes are marked as final + + * Deprecated the `!php/object:` tag which will be replaced by the + `!php/object` tag (without the colon) in 4.0. + + * Deprecated the `!php/const:` tag which will be replaced by the + `!php/const` tag (without the colon) in 4.0. + + * Support for the `!str` tag is deprecated, use the `!!str` tag instead. + + * Deprecated using the non-specific tag `!` as its behavior will change in 4.0. + It will force non-evaluating your values in 4.0. Use plain integers or `!!float` instead. + +3.3.0 +----- + + * Starting an unquoted string with a question mark followed by a space is + deprecated and will throw a `ParseException` in Symfony 4.0. + + * Deprecated support for implicitly parsing non-string mapping keys as strings. + Mapping keys that are no strings will lead to a `ParseException` in Symfony + 4.0. Use quotes to opt-in for keys to be parsed as strings. + + Before: + + ```php + $yaml = << new A(), 'bar' => 1], 0, 0, Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE | Yaml::DUMP_OBJECT); + ``` + +3.0.0 +----- + + * Yaml::parse() now throws an exception when a blackslash is not escaped + in double-quoted strings + +2.8.0 +----- + + * Deprecated usage of a colon in an unquoted mapping value + * Deprecated usage of @, \`, | and > at the beginning of an unquoted string + * When surrounding strings with double-quotes, you must now escape `\` characters. Not + escaping those characters (when surrounded by double-quotes) is deprecated. + + Before: + + ```yml + class: "Foo\Var" + ``` + + After: + + ```yml + class: "Foo\\Var" + ``` + +2.1.0 +----- + + * Yaml::parse() does not evaluate loaded files as PHP files by default + anymore (call Yaml::enablePhpParsing() to get back the old behavior) diff --git a/vendor/symfony/yaml/Command/LintCommand.php b/vendor/symfony/yaml/Command/LintCommand.php index 9c34ad2fa..3faf5413a 100644 --- a/vendor/symfony/yaml/Command/LintCommand.php +++ b/vendor/symfony/yaml/Command/LintCommand.php @@ -1,204 +1,204 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Command; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Command\Command; -use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Exception\InvalidArgumentException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Exception\RuntimeException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Input\InputInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Input\InputOption; -use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Style\SymfonyStyle; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; -/** - * Validates YAML files syntax and outputs encountered errors. - * - * @author Grégoire Pineau - * @author Robin Chalas - */ -class LintCommand extends \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Command\Command -{ - protected static $defaultName = 'lint:yaml'; - private $parser; - private $format; - private $displayCorrectFiles; - private $directoryIteratorProvider; - private $isReadableProvider; - public function __construct($name = null, $directoryIteratorProvider = null, $isReadableProvider = null) - { - parent::__construct($name); - $this->directoryIteratorProvider = $directoryIteratorProvider; - $this->isReadableProvider = $isReadableProvider; - } - /** - * {@inheritdoc} - */ - protected function configure() - { - $this->setDescription('Lints a file and outputs encountered errors')->addArgument('filename', null, 'A file or a directory or STDIN')->addOption('format', null, \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Input\InputOption::VALUE_REQUIRED, 'The output format', 'txt')->addOption('parse-tags', null, \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Input\InputOption::VALUE_NONE, 'Parse custom tags')->setHelp(<<%command.name% command lints a YAML file and outputs to STDOUT -the first encountered syntax error. - -You can validates YAML contents passed from STDIN: - - cat filename | php %command.full_name% - -You can also validate the syntax of a file: - - php %command.full_name% filename - -Or of a whole directory: - - php %command.full_name% dirname - php %command.full_name% dirname --format=json - -EOF -); - } - protected function execute(\_PhpScoper5ea00cc67502b\Symfony\Component\Console\Input\InputInterface $input, \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface $output) - { - $io = new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Style\SymfonyStyle($input, $output); - $filename = $input->getArgument('filename'); - $this->format = $input->getOption('format'); - $this->displayCorrectFiles = $output->isVerbose(); - $flags = $input->getOption('parse-tags') ? \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS : 0; - if (!$filename) { - if (!($stdin = $this->getStdin())) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Exception\RuntimeException('Please provide a filename or pipe file content to STDIN.'); - } - return $this->display($io, [$this->validate($stdin, $flags)]); - } - if (!$this->isReadable($filename)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Exception\RuntimeException(\sprintf('File or directory "%s" is not readable.', $filename)); - } - $filesInfo = []; - foreach ($this->getFiles($filename) as $file) { - $filesInfo[] = $this->validate(\file_get_contents($file), $flags, $file); - } - return $this->display($io, $filesInfo); - } - private function validate($content, $flags, $file = null) - { - $prevErrorHandler = \set_error_handler(function ($level, $message, $file, $line) use(&$prevErrorHandler) { - if (\E_USER_DEPRECATED === $level) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException($message, $this->getParser()->getRealCurrentLineNb() + 1); - } - return $prevErrorHandler ? $prevErrorHandler($level, $message, $file, $line) : \false; - }); - try { - $this->getParser()->parse($content, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT | $flags); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { - return ['file' => $file, 'line' => $e->getParsedLine(), 'valid' => \false, 'message' => $e->getMessage()]; - } finally { - \restore_error_handler(); - } - return ['file' => $file, 'valid' => \true]; - } - private function display(\_PhpScoper5ea00cc67502b\Symfony\Component\Console\Style\SymfonyStyle $io, array $files) - { - switch ($this->format) { - case 'txt': - return $this->displayTxt($io, $files); - case 'json': - return $this->displayJson($io, $files); - default: - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Exception\InvalidArgumentException(\sprintf('The format "%s" is not supported.', $this->format)); - } - } - private function displayTxt(\_PhpScoper5ea00cc67502b\Symfony\Component\Console\Style\SymfonyStyle $io, array $filesInfo) - { - $countFiles = \count($filesInfo); - $erroredFiles = 0; - foreach ($filesInfo as $info) { - if ($info['valid'] && $this->displayCorrectFiles) { - $io->comment('OK' . ($info['file'] ? \sprintf(' in %s', $info['file']) : '')); - } elseif (!$info['valid']) { - ++$erroredFiles; - $io->text(' ERROR ' . ($info['file'] ? \sprintf(' in %s', $info['file']) : '')); - $io->text(\sprintf(' >> %s', $info['message'])); - } - } - if (0 === $erroredFiles) { - $io->success(\sprintf('All %d YAML files contain valid syntax.', $countFiles)); - } else { - $io->warning(\sprintf('%d YAML files have valid syntax and %d contain errors.', $countFiles - $erroredFiles, $erroredFiles)); - } - return \min($erroredFiles, 1); - } - private function displayJson(\_PhpScoper5ea00cc67502b\Symfony\Component\Console\Style\SymfonyStyle $io, array $filesInfo) - { - $errors = 0; - \array_walk($filesInfo, function (&$v) use(&$errors) { - $v['file'] = (string) $v['file']; - if (!$v['valid']) { - ++$errors; - } - }); - $io->writeln(\json_encode($filesInfo, \JSON_PRETTY_PRINT | \JSON_UNESCAPED_SLASHES)); - return \min($errors, 1); - } - private function getFiles($fileOrDirectory) - { - if (\is_file($fileOrDirectory)) { - (yield new \SplFileInfo($fileOrDirectory)); - return; - } - foreach ($this->getDirectoryIterator($fileOrDirectory) as $file) { - if (!\in_array($file->getExtension(), ['yml', 'yaml'])) { - continue; - } - (yield $file); - } - } - /** - * @return string|null - */ - private function getStdin() - { - if (0 !== \ftell(\STDIN)) { - return null; - } - $inputs = ''; - while (!\feof(\STDIN)) { - $inputs .= \fread(\STDIN, 1024); - } - return $inputs; - } - private function getParser() - { - if (!$this->parser) { - $this->parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); - } - return $this->parser; - } - private function getDirectoryIterator($directory) - { - $default = function ($directory) { - return new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($directory, \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::FOLLOW_SYMLINKS), \RecursiveIteratorIterator::LEAVES_ONLY); - }; - if (null !== $this->directoryIteratorProvider) { - return \call_user_func($this->directoryIteratorProvider, $directory, $default); - } - return $default($directory); - } - private function isReadable($fileOrDirectory) - { - $default = function ($fileOrDirectory) { - return \is_readable($fileOrDirectory); - }; - if (null !== $this->isReadableProvider) { - return \call_user_func($this->isReadableProvider, $fileOrDirectory, $default); - } - return $default($fileOrDirectory); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Command; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Command\Command; +use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Exception\InvalidArgumentException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Exception\RuntimeException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Input\InputInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Input\InputOption; +use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Style\SymfonyStyle; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; +/** + * Validates YAML files syntax and outputs encountered errors. + * + * @author Grégoire Pineau + * @author Robin Chalas + */ +class LintCommand extends \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Command\Command +{ + protected static $defaultName = 'lint:yaml'; + private $parser; + private $format; + private $displayCorrectFiles; + private $directoryIteratorProvider; + private $isReadableProvider; + public function __construct($name = null, $directoryIteratorProvider = null, $isReadableProvider = null) + { + parent::__construct($name); + $this->directoryIteratorProvider = $directoryIteratorProvider; + $this->isReadableProvider = $isReadableProvider; + } + /** + * {@inheritdoc} + */ + protected function configure() + { + $this->setDescription('Lints a file and outputs encountered errors')->addArgument('filename', null, 'A file or a directory or STDIN')->addOption('format', null, \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Input\InputOption::VALUE_REQUIRED, 'The output format', 'txt')->addOption('parse-tags', null, \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Input\InputOption::VALUE_NONE, 'Parse custom tags')->setHelp(<<%command.name% command lints a YAML file and outputs to STDOUT +the first encountered syntax error. + +You can validates YAML contents passed from STDIN: + + cat filename | php %command.full_name% + +You can also validate the syntax of a file: + + php %command.full_name% filename + +Or of a whole directory: + + php %command.full_name% dirname + php %command.full_name% dirname --format=json + +EOF +); + } + protected function execute(\_PhpScoper5ea00cc67502b\Symfony\Component\Console\Input\InputInterface $input, \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface $output) + { + $io = new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Style\SymfonyStyle($input, $output); + $filename = $input->getArgument('filename'); + $this->format = $input->getOption('format'); + $this->displayCorrectFiles = $output->isVerbose(); + $flags = $input->getOption('parse-tags') ? \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS : 0; + if (!$filename) { + if (!($stdin = $this->getStdin())) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Exception\RuntimeException('Please provide a filename or pipe file content to STDIN.'); + } + return $this->display($io, [$this->validate($stdin, $flags)]); + } + if (!$this->isReadable($filename)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Exception\RuntimeException(\sprintf('File or directory "%s" is not readable.', $filename)); + } + $filesInfo = []; + foreach ($this->getFiles($filename) as $file) { + $filesInfo[] = $this->validate(\file_get_contents($file), $flags, $file); + } + return $this->display($io, $filesInfo); + } + private function validate($content, $flags, $file = null) + { + $prevErrorHandler = \set_error_handler(function ($level, $message, $file, $line) use(&$prevErrorHandler) { + if (\E_USER_DEPRECATED === $level) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException($message, $this->getParser()->getRealCurrentLineNb() + 1); + } + return $prevErrorHandler ? $prevErrorHandler($level, $message, $file, $line) : \false; + }); + try { + $this->getParser()->parse($content, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT | $flags); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { + return ['file' => $file, 'line' => $e->getParsedLine(), 'valid' => \false, 'message' => $e->getMessage()]; + } finally { + \restore_error_handler(); + } + return ['file' => $file, 'valid' => \true]; + } + private function display(\_PhpScoper5ea00cc67502b\Symfony\Component\Console\Style\SymfonyStyle $io, array $files) + { + switch ($this->format) { + case 'txt': + return $this->displayTxt($io, $files); + case 'json': + return $this->displayJson($io, $files); + default: + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Exception\InvalidArgumentException(\sprintf('The format "%s" is not supported.', $this->format)); + } + } + private function displayTxt(\_PhpScoper5ea00cc67502b\Symfony\Component\Console\Style\SymfonyStyle $io, array $filesInfo) + { + $countFiles = \count($filesInfo); + $erroredFiles = 0; + foreach ($filesInfo as $info) { + if ($info['valid'] && $this->displayCorrectFiles) { + $io->comment('OK' . ($info['file'] ? \sprintf(' in %s', $info['file']) : '')); + } elseif (!$info['valid']) { + ++$erroredFiles; + $io->text(' ERROR ' . ($info['file'] ? \sprintf(' in %s', $info['file']) : '')); + $io->text(\sprintf(' >> %s', $info['message'])); + } + } + if (0 === $erroredFiles) { + $io->success(\sprintf('All %d YAML files contain valid syntax.', $countFiles)); + } else { + $io->warning(\sprintf('%d YAML files have valid syntax and %d contain errors.', $countFiles - $erroredFiles, $erroredFiles)); + } + return \min($erroredFiles, 1); + } + private function displayJson(\_PhpScoper5ea00cc67502b\Symfony\Component\Console\Style\SymfonyStyle $io, array $filesInfo) + { + $errors = 0; + \array_walk($filesInfo, function (&$v) use(&$errors) { + $v['file'] = (string) $v['file']; + if (!$v['valid']) { + ++$errors; + } + }); + $io->writeln(\json_encode($filesInfo, \JSON_PRETTY_PRINT | \JSON_UNESCAPED_SLASHES)); + return \min($errors, 1); + } + private function getFiles($fileOrDirectory) + { + if (\is_file($fileOrDirectory)) { + (yield new \SplFileInfo($fileOrDirectory)); + return; + } + foreach ($this->getDirectoryIterator($fileOrDirectory) as $file) { + if (!\in_array($file->getExtension(), ['yml', 'yaml'])) { + continue; + } + (yield $file); + } + } + /** + * @return string|null + */ + private function getStdin() + { + if (0 !== \ftell(\STDIN)) { + return null; + } + $inputs = ''; + while (!\feof(\STDIN)) { + $inputs .= \fread(\STDIN, 1024); + } + return $inputs; + } + private function getParser() + { + if (!$this->parser) { + $this->parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); + } + return $this->parser; + } + private function getDirectoryIterator($directory) + { + $default = function ($directory) { + return new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($directory, \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::FOLLOW_SYMLINKS), \RecursiveIteratorIterator::LEAVES_ONLY); + }; + if (null !== $this->directoryIteratorProvider) { + return \call_user_func($this->directoryIteratorProvider, $directory, $default); + } + return $default($directory); + } + private function isReadable($fileOrDirectory) + { + $default = function ($fileOrDirectory) { + return \is_readable($fileOrDirectory); + }; + if (null !== $this->isReadableProvider) { + return \call_user_func($this->isReadableProvider, $fileOrDirectory, $default); + } + return $default($fileOrDirectory); + } +} diff --git a/vendor/symfony/yaml/Command/index.php b/vendor/symfony/yaml/Command/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/yaml/Command/index.php +++ b/vendor/symfony/yaml/Command/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Dumper.php b/vendor/symfony/yaml/Dumper.php index b19940d1e..59100a87e 100644 --- a/vendor/symfony/yaml/Dumper.php +++ b/vendor/symfony/yaml/Dumper.php @@ -1,128 +1,128 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; -/** - * Dumper dumps PHP variables to YAML strings. - * - * @author Fabien Potencier - * - * @final since version 3.4 - */ -class Dumper -{ - /** - * The amount of spaces to use for indentation of nested nodes. - * - * @var int - */ - protected $indentation; - /** - * @param int $indentation - */ - public function __construct($indentation = 4) - { - if ($indentation < 1) { - throw new \InvalidArgumentException('The indentation must be greater than zero.'); - } - $this->indentation = $indentation; - } - /** - * Sets the indentation. - * - * @param int $num The amount of spaces to use for indentation of nested nodes - * - * @deprecated since version 3.1, to be removed in 4.0. Pass the indentation to the constructor instead. - */ - public function setIndentation($num) - { - @\trigger_error('The ' . __METHOD__ . ' method is deprecated since Symfony 3.1 and will be removed in 4.0. Pass the indentation to the constructor instead.', \E_USER_DEPRECATED); - $this->indentation = (int) $num; - } - /** - * Dumps a PHP value to YAML. - * - * @param mixed $input The PHP value - * @param int $inline The level where you switch to inline YAML - * @param int $indent The level of indentation (used internally) - * @param int $flags A bit field of Yaml::DUMP_* constants to customize the dumped YAML string - * - * @return string The YAML representation of the PHP value - */ - public function dump($input, $inline = 0, $indent = 0, $flags = 0) - { - if (\is_bool($flags)) { - @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); - if ($flags) { - $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE; - } else { - $flags = 0; - } - } - if (\func_num_args() >= 5) { - @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::DUMP_OBJECT flag instead.', \E_USER_DEPRECATED); - if (\func_get_arg(4)) { - $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT; - } - } - $output = ''; - $prefix = $indent ? \str_repeat(' ', $indent) : ''; - $dumpObjectAsInlineMap = \true; - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP & $flags && ($input instanceof \ArrayObject || $input instanceof \stdClass)) { - $dumpObjectAsInlineMap = empty((array) $input); - } - if ($inline <= 0 || !\is_array($input) && !$input instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue && $dumpObjectAsInlineMap || empty($input)) { - $output .= $prefix . \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($input, $flags); - } else { - $dumpAsMap = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::isHash($input); - foreach ($input as $key => $value) { - if ($inline >= 1 && \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK & $flags && \is_string($value) && \false !== \strpos($value, "\n") && \false === \strpos($value, "\r")) { - // If the first line starts with a space character, the spec requires a blockIndicationIndicator - // http://www.yaml.org/spec/1.2/spec.html#id2793979 - $blockIndentationIndicator = ' ' === \substr($value, 0, 1) ? (string) $this->indentation : ''; - $output .= \sprintf("%s%s%s |%s\n", $prefix, $dumpAsMap ? \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($key, $flags) . ':' : '-', '', $blockIndentationIndicator); - foreach (\explode("\n", $value) as $row) { - $output .= \sprintf("%s%s%s\n", $prefix, \str_repeat(' ', $this->indentation), $row); - } - continue; - } - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue) { - $output .= \sprintf('%s%s !%s', $prefix, $dumpAsMap ? \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($key, $flags) . ':' : '-', $value->getTag()); - if ($inline >= 1 && \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK & $flags && \is_string($value->getValue()) && \false !== \strpos($value->getValue(), "\n") && \false === \strpos($value->getValue(), "\r\n")) { - // If the first line starts with a space character, the spec requires a blockIndicationIndicator - // http://www.yaml.org/spec/1.2/spec.html#id2793979 - $blockIndentationIndicator = ' ' === \substr($value->getValue(), 0, 1) ? (string) $this->indentation : ''; - $output .= \sprintf(" |%s\n", $blockIndentationIndicator); - foreach (\explode("\n", $value->getValue()) as $row) { - $output .= \sprintf("%s%s%s\n", $prefix, \str_repeat(' ', $this->indentation), $row); - } - continue; - } - if ($inline - 1 <= 0 || null === $value->getValue() || \is_scalar($value->getValue())) { - $output .= ' ' . $this->dump($value->getValue(), $inline - 1, 0, $flags) . "\n"; - } else { - $output .= "\n"; - $output .= $this->dump($value->getValue(), $inline - 1, $dumpAsMap ? $indent + $this->indentation : $indent + 2, $flags); - } - continue; - } - $dumpObjectAsInlineMap = \true; - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP & $flags && ($value instanceof \ArrayObject || $value instanceof \stdClass)) { - $dumpObjectAsInlineMap = empty((array) $value); - } - $willBeInlined = $inline - 1 <= 0 || !\is_array($value) && $dumpObjectAsInlineMap || empty($value); - $output .= \sprintf('%s%s%s%s', $prefix, $dumpAsMap ? \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($key, $flags) . ':' : '-', $willBeInlined ? ' ' : "\n", $this->dump($value, $inline - 1, $willBeInlined ? 0 : $indent + $this->indentation, $flags)) . ($willBeInlined ? "\n" : ''); - } - } - return $output; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; +/** + * Dumper dumps PHP variables to YAML strings. + * + * @author Fabien Potencier + * + * @final since version 3.4 + */ +class Dumper +{ + /** + * The amount of spaces to use for indentation of nested nodes. + * + * @var int + */ + protected $indentation; + /** + * @param int $indentation + */ + public function __construct($indentation = 4) + { + if ($indentation < 1) { + throw new \InvalidArgumentException('The indentation must be greater than zero.'); + } + $this->indentation = $indentation; + } + /** + * Sets the indentation. + * + * @param int $num The amount of spaces to use for indentation of nested nodes + * + * @deprecated since version 3.1, to be removed in 4.0. Pass the indentation to the constructor instead. + */ + public function setIndentation($num) + { + @\trigger_error('The ' . __METHOD__ . ' method is deprecated since Symfony 3.1 and will be removed in 4.0. Pass the indentation to the constructor instead.', \E_USER_DEPRECATED); + $this->indentation = (int) $num; + } + /** + * Dumps a PHP value to YAML. + * + * @param mixed $input The PHP value + * @param int $inline The level where you switch to inline YAML + * @param int $indent The level of indentation (used internally) + * @param int $flags A bit field of Yaml::DUMP_* constants to customize the dumped YAML string + * + * @return string The YAML representation of the PHP value + */ + public function dump($input, $inline = 0, $indent = 0, $flags = 0) + { + if (\is_bool($flags)) { + @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); + if ($flags) { + $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE; + } else { + $flags = 0; + } + } + if (\func_num_args() >= 5) { + @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::DUMP_OBJECT flag instead.', \E_USER_DEPRECATED); + if (\func_get_arg(4)) { + $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT; + } + } + $output = ''; + $prefix = $indent ? \str_repeat(' ', $indent) : ''; + $dumpObjectAsInlineMap = \true; + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP & $flags && ($input instanceof \ArrayObject || $input instanceof \stdClass)) { + $dumpObjectAsInlineMap = empty((array) $input); + } + if ($inline <= 0 || !\is_array($input) && !$input instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue && $dumpObjectAsInlineMap || empty($input)) { + $output .= $prefix . \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($input, $flags); + } else { + $dumpAsMap = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::isHash($input); + foreach ($input as $key => $value) { + if ($inline >= 1 && \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK & $flags && \is_string($value) && \false !== \strpos($value, "\n") && \false === \strpos($value, "\r")) { + // If the first line starts with a space character, the spec requires a blockIndicationIndicator + // http://www.yaml.org/spec/1.2/spec.html#id2793979 + $blockIndentationIndicator = ' ' === \substr($value, 0, 1) ? (string) $this->indentation : ''; + $output .= \sprintf("%s%s%s |%s\n", $prefix, $dumpAsMap ? \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($key, $flags) . ':' : '-', '', $blockIndentationIndicator); + foreach (\explode("\n", $value) as $row) { + $output .= \sprintf("%s%s%s\n", $prefix, \str_repeat(' ', $this->indentation), $row); + } + continue; + } + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue) { + $output .= \sprintf('%s%s !%s', $prefix, $dumpAsMap ? \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($key, $flags) . ':' : '-', $value->getTag()); + if ($inline >= 1 && \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK & $flags && \is_string($value->getValue()) && \false !== \strpos($value->getValue(), "\n") && \false === \strpos($value->getValue(), "\r\n")) { + // If the first line starts with a space character, the spec requires a blockIndicationIndicator + // http://www.yaml.org/spec/1.2/spec.html#id2793979 + $blockIndentationIndicator = ' ' === \substr($value->getValue(), 0, 1) ? (string) $this->indentation : ''; + $output .= \sprintf(" |%s\n", $blockIndentationIndicator); + foreach (\explode("\n", $value->getValue()) as $row) { + $output .= \sprintf("%s%s%s\n", $prefix, \str_repeat(' ', $this->indentation), $row); + } + continue; + } + if ($inline - 1 <= 0 || null === $value->getValue() || \is_scalar($value->getValue())) { + $output .= ' ' . $this->dump($value->getValue(), $inline - 1, 0, $flags) . "\n"; + } else { + $output .= "\n"; + $output .= $this->dump($value->getValue(), $inline - 1, $dumpAsMap ? $indent + $this->indentation : $indent + 2, $flags); + } + continue; + } + $dumpObjectAsInlineMap = \true; + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP & $flags && ($value instanceof \ArrayObject || $value instanceof \stdClass)) { + $dumpObjectAsInlineMap = empty((array) $value); + } + $willBeInlined = $inline - 1 <= 0 || !\is_array($value) && $dumpObjectAsInlineMap || empty($value); + $output .= \sprintf('%s%s%s%s', $prefix, $dumpAsMap ? \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($key, $flags) . ':' : '-', $willBeInlined ? ' ' : "\n", $this->dump($value, $inline - 1, $willBeInlined ? 0 : $indent + $this->indentation, $flags)) . ($willBeInlined ? "\n" : ''); + } + } + return $output; + } +} diff --git a/vendor/symfony/yaml/Escaper.php b/vendor/symfony/yaml/Escaper.php index 72649c2bb..a33429990 100644 --- a/vendor/symfony/yaml/Escaper.php +++ b/vendor/symfony/yaml/Escaper.php @@ -1,82 +1,82 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; - -/** - * Escaper encapsulates escaping rules for single and double-quoted - * YAML strings. - * - * @author Matthew Lewinski - * - * @internal - */ -class Escaper -{ - // Characters that would cause a dumped string to require double quoting. - const REGEX_CHARACTER_TO_ESCAPE = "[\\x00-\\x1f]|Â…| |
|
"; - // Mapping arrays for escaping a double quoted string. The backslash is - // first to ensure proper escaping because str_replace operates iteratively - // on the input arrays. This ordering of the characters avoids the use of strtr, - // which performs more slowly. - private static $escapees = ['\\', '\\\\', '\\"', '"', "\0", "\1", "\2", "\3", "\4", "\5", "\6", "\7", "\10", "\t", "\n", "\v", "\f", "\r", "\16", "\17", "\20", "\21", "\22", "\23", "\24", "\25", "\26", "\27", "\30", "\31", "\32", "\33", "\34", "\35", "\36", "\37", "Â…", " ", "
", "
"]; - private static $escaped = ['\\\\', '\\"', '\\\\', '\\"', '\\0', '\\x01', '\\x02', '\\x03', '\\x04', '\\x05', '\\x06', '\\a', '\\b', '\\t', '\\n', '\\v', '\\f', '\\r', '\\x0e', '\\x0f', '\\x10', '\\x11', '\\x12', '\\x13', '\\x14', '\\x15', '\\x16', '\\x17', '\\x18', '\\x19', '\\x1a', '\\e', '\\x1c', '\\x1d', '\\x1e', '\\x1f', '\\N', '\\_', '\\L', '\\P']; - /** - * Determines if a PHP value would require double quoting in YAML. - * - * @param string $value A PHP value - * - * @return bool True if the value would require double quotes - */ - public static function requiresDoubleQuoting($value) - { - return 0 < \preg_match('/' . self::REGEX_CHARACTER_TO_ESCAPE . '/u', $value); - } - /** - * Escapes and surrounds a PHP value with double quotes. - * - * @param string $value A PHP value - * - * @return string The quoted, escaped string - */ - public static function escapeWithDoubleQuotes($value) - { - return \sprintf('"%s"', \str_replace(self::$escapees, self::$escaped, $value)); - } - /** - * Determines if a PHP value would require single quoting in YAML. - * - * @param string $value A PHP value - * - * @return bool True if the value would require single quotes - */ - public static function requiresSingleQuoting($value) - { - // Determines if a PHP value is entirely composed of a value that would - // require single quoting in YAML. - if (\in_array(\strtolower($value), ['null', '~', 'true', 'false', 'y', 'n', 'yes', 'no', 'on', 'off'])) { - return \true; - } - // Determines if the PHP value contains any single characters that would - // cause it to require single quoting in YAML. - return 0 < \preg_match('/[ \\s \' " \\: \\{ \\} \\[ \\] , & \\* \\# \\?] | \\A[ \\- ? | < > = ! % @ ` ]/x', $value); - } - /** - * Escapes and surrounds a PHP value with single quotes. - * - * @param string $value A PHP value - * - * @return string The quoted, escaped string - */ - public static function escapeWithSingleQuotes($value) - { - return \sprintf("'%s'", \str_replace('\'', '\'\'', $value)); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; + +/** + * Escaper encapsulates escaping rules for single and double-quoted + * YAML strings. + * + * @author Matthew Lewinski + * + * @internal + */ +class Escaper +{ + // Characters that would cause a dumped string to require double quoting. + const REGEX_CHARACTER_TO_ESCAPE = "[\\x00-\\x1f]|Â…| |
|
"; + // Mapping arrays for escaping a double quoted string. The backslash is + // first to ensure proper escaping because str_replace operates iteratively + // on the input arrays. This ordering of the characters avoids the use of strtr, + // which performs more slowly. + private static $escapees = ['\\', '\\\\', '\\"', '"', "\0", "\1", "\2", "\3", "\4", "\5", "\6", "\7", "\10", "\t", "\n", "\v", "\f", "\r", "\16", "\17", "\20", "\21", "\22", "\23", "\24", "\25", "\26", "\27", "\30", "\31", "\32", "\33", "\34", "\35", "\36", "\37", "Â…", " ", "
", "
"]; + private static $escaped = ['\\\\', '\\"', '\\\\', '\\"', '\\0', '\\x01', '\\x02', '\\x03', '\\x04', '\\x05', '\\x06', '\\a', '\\b', '\\t', '\\n', '\\v', '\\f', '\\r', '\\x0e', '\\x0f', '\\x10', '\\x11', '\\x12', '\\x13', '\\x14', '\\x15', '\\x16', '\\x17', '\\x18', '\\x19', '\\x1a', '\\e', '\\x1c', '\\x1d', '\\x1e', '\\x1f', '\\N', '\\_', '\\L', '\\P']; + /** + * Determines if a PHP value would require double quoting in YAML. + * + * @param string $value A PHP value + * + * @return bool True if the value would require double quotes + */ + public static function requiresDoubleQuoting($value) + { + return 0 < \preg_match('/' . self::REGEX_CHARACTER_TO_ESCAPE . '/u', $value); + } + /** + * Escapes and surrounds a PHP value with double quotes. + * + * @param string $value A PHP value + * + * @return string The quoted, escaped string + */ + public static function escapeWithDoubleQuotes($value) + { + return \sprintf('"%s"', \str_replace(self::$escapees, self::$escaped, $value)); + } + /** + * Determines if a PHP value would require single quoting in YAML. + * + * @param string $value A PHP value + * + * @return bool True if the value would require single quotes + */ + public static function requiresSingleQuoting($value) + { + // Determines if a PHP value is entirely composed of a value that would + // require single quoting in YAML. + if (\in_array(\strtolower($value), ['null', '~', 'true', 'false', 'y', 'n', 'yes', 'no', 'on', 'off'])) { + return \true; + } + // Determines if the PHP value contains any single characters that would + // cause it to require single quoting in YAML. + return 0 < \preg_match('/[ \\s \' " \\: \\{ \\} \\[ \\] , & \\* \\# \\?] | \\A[ \\- ? | < > = ! % @ ` ]/x', $value); + } + /** + * Escapes and surrounds a PHP value with single quotes. + * + * @param string $value A PHP value + * + * @return string The quoted, escaped string + */ + public static function escapeWithSingleQuotes($value) + { + return \sprintf("'%s'", \str_replace('\'', '\'\'', $value)); + } +} diff --git a/vendor/symfony/yaml/Exception/DumpException.php b/vendor/symfony/yaml/Exception/DumpException.php index 602df6d67..95abafe72 100644 --- a/vendor/symfony/yaml/Exception/DumpException.php +++ b/vendor/symfony/yaml/Exception/DumpException.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception; - -/** - * Exception class thrown when an error occurs during dumping. - * - * @author Fabien Potencier - */ -class DumpException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\RuntimeException -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception; + +/** + * Exception class thrown when an error occurs during dumping. + * + * @author Fabien Potencier + */ +class DumpException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\RuntimeException +{ +} diff --git a/vendor/symfony/yaml/Exception/ExceptionInterface.php b/vendor/symfony/yaml/Exception/ExceptionInterface.php index 276817ac4..45b119730 100644 --- a/vendor/symfony/yaml/Exception/ExceptionInterface.php +++ b/vendor/symfony/yaml/Exception/ExceptionInterface.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception; - -/** - * Exception interface for all exceptions thrown by the component. - * - * @author Fabien Potencier - */ -interface ExceptionInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception; + +/** + * Exception interface for all exceptions thrown by the component. + * + * @author Fabien Potencier + */ +interface ExceptionInterface +{ +} diff --git a/vendor/symfony/yaml/Exception/ParseException.php b/vendor/symfony/yaml/Exception/ParseException.php index d457fdd02..d0524b8cd 100644 --- a/vendor/symfony/yaml/Exception/ParseException.php +++ b/vendor/symfony/yaml/Exception/ParseException.php @@ -1,120 +1,120 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception; - -/** - * Exception class thrown when an error occurs during parsing. - * - * @author Fabien Potencier - */ -class ParseException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\RuntimeException -{ - private $parsedFile; - private $parsedLine; - private $snippet; - private $rawMessage; - /** - * @param string $message The error message - * @param int $parsedLine The line where the error occurred - * @param string|null $snippet The snippet of code near the problem - * @param string|null $parsedFile The file name where the error occurred - * @param \Exception|null $previous The previous exception - */ - public function __construct($message, $parsedLine = -1, $snippet = null, $parsedFile = null, \Exception $previous = null) - { - $this->parsedFile = $parsedFile; - $this->parsedLine = $parsedLine; - $this->snippet = $snippet; - $this->rawMessage = $message; - $this->updateRepr(); - parent::__construct($this->message, 0, $previous); - } - /** - * Gets the snippet of code near the error. - * - * @return string The snippet of code - */ - public function getSnippet() - { - return $this->snippet; - } - /** - * Sets the snippet of code near the error. - * - * @param string $snippet The code snippet - */ - public function setSnippet($snippet) - { - $this->snippet = $snippet; - $this->updateRepr(); - } - /** - * Gets the filename where the error occurred. - * - * This method returns null if a string is parsed. - * - * @return string The filename - */ - public function getParsedFile() - { - return $this->parsedFile; - } - /** - * Sets the filename where the error occurred. - * - * @param string $parsedFile The filename - */ - public function setParsedFile($parsedFile) - { - $this->parsedFile = $parsedFile; - $this->updateRepr(); - } - /** - * Gets the line where the error occurred. - * - * @return int The file line - */ - public function getParsedLine() - { - return $this->parsedLine; - } - /** - * Sets the line where the error occurred. - * - * @param int $parsedLine The file line - */ - public function setParsedLine($parsedLine) - { - $this->parsedLine = $parsedLine; - $this->updateRepr(); - } - private function updateRepr() - { - $this->message = $this->rawMessage; - $dot = \false; - if ('.' === \substr($this->message, -1)) { - $this->message = \substr($this->message, 0, -1); - $dot = \true; - } - if (null !== $this->parsedFile) { - $this->message .= \sprintf(' in %s', \json_encode($this->parsedFile, \JSON_UNESCAPED_SLASHES | \JSON_UNESCAPED_UNICODE)); - } - if ($this->parsedLine >= 0) { - $this->message .= \sprintf(' at line %d', $this->parsedLine); - } - if ($this->snippet) { - $this->message .= \sprintf(' (near "%s")', $this->snippet); - } - if ($dot) { - $this->message .= '.'; - } - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception; + +/** + * Exception class thrown when an error occurs during parsing. + * + * @author Fabien Potencier + */ +class ParseException extends \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\RuntimeException +{ + private $parsedFile; + private $parsedLine; + private $snippet; + private $rawMessage; + /** + * @param string $message The error message + * @param int $parsedLine The line where the error occurred + * @param string|null $snippet The snippet of code near the problem + * @param string|null $parsedFile The file name where the error occurred + * @param \Exception|null $previous The previous exception + */ + public function __construct($message, $parsedLine = -1, $snippet = null, $parsedFile = null, \Exception $previous = null) + { + $this->parsedFile = $parsedFile; + $this->parsedLine = $parsedLine; + $this->snippet = $snippet; + $this->rawMessage = $message; + $this->updateRepr(); + parent::__construct($this->message, 0, $previous); + } + /** + * Gets the snippet of code near the error. + * + * @return string The snippet of code + */ + public function getSnippet() + { + return $this->snippet; + } + /** + * Sets the snippet of code near the error. + * + * @param string $snippet The code snippet + */ + public function setSnippet($snippet) + { + $this->snippet = $snippet; + $this->updateRepr(); + } + /** + * Gets the filename where the error occurred. + * + * This method returns null if a string is parsed. + * + * @return string The filename + */ + public function getParsedFile() + { + return $this->parsedFile; + } + /** + * Sets the filename where the error occurred. + * + * @param string $parsedFile The filename + */ + public function setParsedFile($parsedFile) + { + $this->parsedFile = $parsedFile; + $this->updateRepr(); + } + /** + * Gets the line where the error occurred. + * + * @return int The file line + */ + public function getParsedLine() + { + return $this->parsedLine; + } + /** + * Sets the line where the error occurred. + * + * @param int $parsedLine The file line + */ + public function setParsedLine($parsedLine) + { + $this->parsedLine = $parsedLine; + $this->updateRepr(); + } + private function updateRepr() + { + $this->message = $this->rawMessage; + $dot = \false; + if ('.' === \substr($this->message, -1)) { + $this->message = \substr($this->message, 0, -1); + $dot = \true; + } + if (null !== $this->parsedFile) { + $this->message .= \sprintf(' in %s', \json_encode($this->parsedFile, \JSON_UNESCAPED_SLASHES | \JSON_UNESCAPED_UNICODE)); + } + if ($this->parsedLine >= 0) { + $this->message .= \sprintf(' at line %d', $this->parsedLine); + } + if ($this->snippet) { + $this->message .= \sprintf(' (near "%s")', $this->snippet); + } + if ($dot) { + $this->message .= '.'; + } + } +} diff --git a/vendor/symfony/yaml/Exception/RuntimeException.php b/vendor/symfony/yaml/Exception/RuntimeException.php index 1c91873eb..0ad974e7e 100644 --- a/vendor/symfony/yaml/Exception/RuntimeException.php +++ b/vendor/symfony/yaml/Exception/RuntimeException.php @@ -1,20 +1,20 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception; - -/** - * Exception class thrown when an error occurs during parsing. - * - * @author Romain Neutron - */ -class RuntimeException extends \RuntimeException implements \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ExceptionInterface -{ -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception; + +/** + * Exception class thrown when an error occurs during parsing. + * + * @author Romain Neutron + */ +class RuntimeException extends \RuntimeException implements \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ExceptionInterface +{ +} diff --git a/vendor/symfony/yaml/Exception/index.php b/vendor/symfony/yaml/Exception/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/yaml/Exception/index.php +++ b/vendor/symfony/yaml/Exception/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Inline.php b/vendor/symfony/yaml/Inline.php index d75af79bb..ee754cd00 100644 --- a/vendor/symfony/yaml/Inline.php +++ b/vendor/symfony/yaml/Inline.php @@ -1,792 +1,792 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\DumpException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; -/** - * Inline implements a YAML parser/dumper for the YAML inline syntax. - * - * @author Fabien Potencier - * - * @internal - */ -class Inline -{ - const REGEX_QUOTED_STRING = '(?:"([^"\\\\]*+(?:\\\\.[^"\\\\]*+)*+)"|\'([^\']*+(?:\'\'[^\']*+)*+)\')'; - public static $parsedLineNumber = -1; - public static $parsedFilename; - private static $exceptionOnInvalidType = \false; - private static $objectSupport = \false; - private static $objectForMap = \false; - private static $constantSupport = \false; - /** - * @param int $flags - * @param int|null $parsedLineNumber - * @param string|null $parsedFilename - */ - public static function initialize($flags, $parsedLineNumber = null, $parsedFilename = null) - { - self::$exceptionOnInvalidType = (bool) (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE & $flags); - self::$objectSupport = (bool) (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT & $flags); - self::$objectForMap = (bool) (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags); - self::$constantSupport = (bool) (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT & $flags); - self::$parsedFilename = $parsedFilename; - if (null !== $parsedLineNumber) { - self::$parsedLineNumber = $parsedLineNumber; - } - } - /** - * Converts a YAML string to a PHP value. - * - * @param string $value A YAML string - * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior - * @param array $references Mapping of variable names to values - * - * @return mixed A PHP value - * - * @throws ParseException - */ - public static function parse($value, $flags = 0, $references = []) - { - if (\is_bool($flags)) { - @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); - if ($flags) { - $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE; - } else { - $flags = 0; - } - } - if (\func_num_args() >= 3 && !\is_array($references)) { - @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_OBJECT flag instead.', \E_USER_DEPRECATED); - if ($references) { - $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT; - } - if (\func_num_args() >= 4) { - @\trigger_error('Passing a boolean flag to toggle object for map support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_OBJECT_FOR_MAP flag instead.', \E_USER_DEPRECATED); - if (\func_get_arg(3)) { - $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP; - } - } - if (\func_num_args() >= 5) { - $references = \func_get_arg(4); - } else { - $references = []; - } - } - self::initialize($flags); - $value = \trim($value); - if ('' === $value) { - return ''; - } - if (2 & (int) \ini_get('mbstring.func_overload')) { - $mbEncoding = \mb_internal_encoding(); - \mb_internal_encoding('ASCII'); - } - try { - $i = 0; - $tag = self::parseTag($value, $i, $flags); - switch ($value[$i]) { - case '[': - $result = self::parseSequence($value, $flags, $i, $references); - ++$i; - break; - case '{': - $result = self::parseMapping($value, $flags, $i, $references); - ++$i; - break; - default: - $result = self::parseScalar($value, $flags, null, $i, null === $tag, $references); - } - // some comments are allowed at the end - if (\preg_replace('/\\s+#.*$/A', '', \substr($value, $i))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Unexpected characters near "%s".', \substr($value, $i)), self::$parsedLineNumber + 1, $value, self::$parsedFilename); - } - if (null !== $tag) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $result); - } - return $result; - } finally { - if (isset($mbEncoding)) { - \mb_internal_encoding($mbEncoding); - } - } - } - /** - * Dumps a given PHP variable to a YAML string. - * - * @param mixed $value The PHP variable to convert - * @param int $flags A bit field of Yaml::DUMP_* constants to customize the dumped YAML string - * - * @return string The YAML string representing the PHP value - * - * @throws DumpException When trying to dump PHP resource - */ - public static function dump($value, $flags = 0) - { - if (\is_bool($flags)) { - @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); - if ($flags) { - $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE; - } else { - $flags = 0; - } - } - if (\func_num_args() >= 3) { - @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::DUMP_OBJECT flag instead.', \E_USER_DEPRECATED); - if (\func_get_arg(2)) { - $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT; - } - } - switch (\true) { - case \is_resource($value): - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE & $flags) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\DumpException(\sprintf('Unable to dump PHP resources in a YAML file ("%s").', \get_resource_type($value))); - } - return 'null'; - case $value instanceof \DateTimeInterface: - return $value->format('c'); - case \is_object($value): - if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue) { - return '!' . $value->getTag() . ' ' . self::dump($value->getValue(), $flags); - } - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT & $flags) { - return '!php/object ' . self::dump(\serialize($value)); - } - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP & $flags && ($value instanceof \stdClass || $value instanceof \ArrayObject)) { - return self::dumpArray($value, $flags & ~\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE); - } - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE & $flags) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\DumpException('Object support when dumping a YAML file has been disabled.'); - } - return 'null'; - case \is_array($value): - return self::dumpArray($value, $flags); - case null === $value: - return 'null'; - case \true === $value: - return 'true'; - case \false === $value: - return 'false'; - case \ctype_digit($value): - return \is_string($value) ? "'{$value}'" : (int) $value; - case \is_numeric($value): - $locale = \setlocale(\LC_NUMERIC, 0); - if (\false !== $locale) { - \setlocale(\LC_NUMERIC, 'C'); - } - if (\is_float($value)) { - $repr = (string) $value; - if (\is_infinite($value)) { - $repr = \str_ireplace('INF', '.Inf', $repr); - } elseif (\floor($value) == $value && $repr == $value) { - // Preserve float data type since storing a whole number will result in integer value. - $repr = '!!float ' . $repr; - } - } else { - $repr = \is_string($value) ? "'{$value}'" : (string) $value; - } - if (\false !== $locale) { - \setlocale(\LC_NUMERIC, $locale); - } - return $repr; - case '' == $value: - return "''"; - case self::isBinaryString($value): - return '!!binary ' . \base64_encode($value); - case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Escaper::requiresDoubleQuoting($value): - return \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Escaper::escapeWithDoubleQuotes($value); - case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Escaper::requiresSingleQuoting($value): - case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('{^[0-9]+[_0-9]*$}', $value): - case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match(self::getHexRegex(), $value): - case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match(self::getTimestampRegex(), $value): - return \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Escaper::escapeWithSingleQuotes($value); - default: - return $value; - } - } - /** - * Check if given array is hash or just normal indexed array. - * - * @internal - * - * @param array|\ArrayObject|\stdClass $value The PHP array or array-like object to check - * - * @return bool true if value is hash array, false otherwise - */ - public static function isHash($value) - { - if ($value instanceof \stdClass || $value instanceof \ArrayObject) { - return \true; - } - $expectedKey = 0; - foreach ($value as $key => $val) { - if ($key !== $expectedKey++) { - return \true; - } - } - return \false; - } - /** - * Dumps a PHP array to a YAML string. - * - * @param array $value The PHP array to dump - * @param int $flags A bit field of Yaml::DUMP_* constants to customize the dumped YAML string - * - * @return string The YAML string representing the PHP array - */ - private static function dumpArray($value, $flags) - { - // array - if (($value || \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE & $flags) && !self::isHash($value)) { - $output = []; - foreach ($value as $val) { - $output[] = self::dump($val, $flags); - } - return \sprintf('[%s]', \implode(', ', $output)); - } - // hash - $output = []; - foreach ($value as $key => $val) { - $output[] = \sprintf('%s: %s', self::dump($key, $flags), self::dump($val, $flags)); - } - return \sprintf('{ %s }', \implode(', ', $output)); - } - /** - * Parses a YAML scalar. - * - * @param string $scalar - * @param int $flags - * @param string[] $delimiters - * @param int &$i - * @param bool $evaluate - * @param array $references - * - * @return string - * - * @throws ParseException When malformed inline YAML string is parsed - * - * @internal - */ - public static function parseScalar($scalar, $flags = 0, $delimiters = null, &$i = 0, $evaluate = \true, $references = [], $legacyOmittedKeySupport = \false) - { - if (\in_array($scalar[$i], ['"', "'"])) { - // quoted scalar - $output = self::parseQuotedScalar($scalar, $i); - if (null !== $delimiters) { - $tmp = \ltrim(\substr($scalar, $i), ' '); - if ('' === $tmp) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Unexpected end of line, expected one of "%s".', \implode('', $delimiters)), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - if (!\in_array($tmp[0], $delimiters)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Unexpected characters (%s).', \substr($scalar, $i)), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - } - } else { - // "normal" string - if (!$delimiters) { - $output = \substr($scalar, $i); - $i += \strlen($output); - // remove comments - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('/[ \\t]+#/', $output, $match, \PREG_OFFSET_CAPTURE)) { - $output = \substr($output, 0, $match[0][1]); - } - } elseif (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('/^(.' . ($legacyOmittedKeySupport ? '+' : '*') . '?)(' . \implode('|', $delimiters) . ')/', \substr($scalar, $i), $match)) { - $output = $match[1]; - $i += \strlen($output); - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Malformed inline YAML string: "%s".', $scalar), self::$parsedLineNumber + 1, null, self::$parsedFilename); - } - // a non-quoted string cannot start with @ or ` (reserved) nor with a scalar indicator (| or >) - if ($output && ('@' === $output[0] || '`' === $output[0] || '|' === $output[0] || '>' === $output[0])) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The reserved indicator "%s" cannot start a plain scalar; you need to quote the scalar.', $output[0]), self::$parsedLineNumber + 1, $output, self::$parsedFilename); - } - if ($output && '%' === $output[0]) { - @\trigger_error(self::getDeprecationMessage(\sprintf('Not quoting the scalar "%s" starting with the "%%" indicator character is deprecated since Symfony 3.1 and will throw a ParseException in 4.0.', $output)), \E_USER_DEPRECATED); - } - if ($evaluate) { - $output = self::evaluateScalar($output, $flags, $references); - } - } - return $output; - } - /** - * Parses a YAML quoted scalar. - * - * @param string $scalar - * @param int &$i - * - * @return string - * - * @throws ParseException When malformed inline YAML string is parsed - */ - private static function parseQuotedScalar($scalar, &$i) - { - if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('/' . self::REGEX_QUOTED_STRING . '/Au', \substr($scalar, $i), $match)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Malformed inline YAML string: "%s".', \substr($scalar, $i)), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - $output = \substr($match[0], 1, \strlen($match[0]) - 2); - $unescaper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Unescaper(); - if ('"' == $scalar[$i]) { - $output = $unescaper->unescapeDoubleQuotedString($output); - } else { - $output = $unescaper->unescapeSingleQuotedString($output); - } - $i += \strlen($match[0]); - return $output; - } - /** - * Parses a YAML sequence. - * - * @param string $sequence - * @param int $flags - * @param int &$i - * @param array $references - * - * @return array - * - * @throws ParseException When malformed inline YAML string is parsed - */ - private static function parseSequence($sequence, $flags, &$i = 0, $references = []) - { - $output = []; - $len = \strlen($sequence); - ++$i; - // [foo, bar, ...] - while ($i < $len) { - if (']' === $sequence[$i]) { - return $output; - } - if (',' === $sequence[$i] || ' ' === $sequence[$i]) { - ++$i; - continue; - } - $tag = self::parseTag($sequence, $i, $flags); - switch ($sequence[$i]) { - case '[': - // nested sequence - $value = self::parseSequence($sequence, $flags, $i, $references); - break; - case '{': - // nested mapping - $value = self::parseMapping($sequence, $flags, $i, $references); - break; - default: - $isQuoted = \in_array($sequence[$i], ['"', "'"]); - $value = self::parseScalar($sequence, $flags, [',', ']'], $i, null === $tag, $references); - // the value can be an array if a reference has been resolved to an array var - if (\is_string($value) && !$isQuoted && \false !== \strpos($value, ': ')) { - // embedded mapping? - try { - $pos = 0; - $value = self::parseMapping('{' . $value . '}', $flags, $pos, $references); - } catch (\InvalidArgumentException $e) { - // no, it's not - } - } - --$i; - } - if (null !== $tag) { - $value = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $value); - } - $output[] = $value; - ++$i; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Malformed inline YAML string: "%s".', $sequence), self::$parsedLineNumber + 1, null, self::$parsedFilename); - } - /** - * Parses a YAML mapping. - * - * @param string $mapping - * @param int $flags - * @param int &$i - * @param array $references - * - * @return array|\stdClass - * - * @throws ParseException When malformed inline YAML string is parsed - */ - private static function parseMapping($mapping, $flags, &$i = 0, $references = []) - { - $output = []; - $len = \strlen($mapping); - ++$i; - $allowOverwrite = \false; - // {foo: bar, bar:foo, ...} - while ($i < $len) { - switch ($mapping[$i]) { - case ' ': - case ',': - ++$i; - continue 2; - case '}': - if (self::$objectForMap) { - return (object) $output; - } - return $output; - } - // key - $isKeyQuoted = \in_array($mapping[$i], ['"', "'"], \true); - $key = self::parseScalar($mapping, $flags, [':', ' '], $i, \false, [], \true); - if ('!php/const' === $key) { - $key .= self::parseScalar($mapping, $flags, [':', ' '], $i, \false, [], \true); - if ('!php/const:' === $key && ':' !== $mapping[$i]) { - $key = ''; - --$i; - } else { - $key = self::evaluateScalar($key, $flags); - } - } - if (':' !== $key && \false === ($i = \strpos($mapping, ':', $i))) { - break; - } - if (':' === $key) { - @\trigger_error(self::getDeprecationMessage('Omitting the key of a mapping is deprecated and will throw a ParseException in 4.0.'), \E_USER_DEPRECATED); - } - if (!$isKeyQuoted) { - $evaluatedKey = self::evaluateScalar($key, $flags, $references); - if ('' !== $key && $evaluatedKey !== $key && !\is_string($evaluatedKey) && !\is_int($evaluatedKey)) { - @\trigger_error(self::getDeprecationMessage('Implicit casting of incompatible mapping keys to strings is deprecated since Symfony 3.3 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0. Quote your evaluable mapping keys instead.'), \E_USER_DEPRECATED); - } - } - if (':' !== $key && !$isKeyQuoted && (!isset($mapping[$i + 1]) || !\in_array($mapping[$i + 1], [' ', ',', '[', ']', '{', '}'], \true))) { - @\trigger_error(self::getDeprecationMessage('Using a colon after an unquoted mapping key that is not followed by an indication character (i.e. " ", ",", "[", "]", "{", "}") is deprecated since Symfony 3.2 and will throw a ParseException in 4.0.'), \E_USER_DEPRECATED); - } - if ('<<' === $key) { - $allowOverwrite = \true; - } - while ($i < $len) { - if (':' === $mapping[$i] || ' ' === $mapping[$i]) { - ++$i; - continue; - } - $tag = self::parseTag($mapping, $i, $flags); - switch ($mapping[$i]) { - case '[': - // nested sequence - $value = self::parseSequence($mapping, $flags, $i, $references); - // Spec: Keys MUST be unique; first one wins. - // Parser cannot abort this mapping earlier, since lines - // are processed sequentially. - // But overwriting is allowed when a merge node is used in current block. - if ('<<' === $key) { - foreach ($value as $parsedValue) { - $output += $parsedValue; - } - } elseif ($allowOverwrite || !isset($output[$key])) { - if (null !== $tag) { - $output[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $value); - } else { - $output[$key] = $value; - } - } elseif (isset($output[$key])) { - @\trigger_error(self::getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); - } - break; - case '{': - // nested mapping - $value = self::parseMapping($mapping, $flags, $i, $references); - // Spec: Keys MUST be unique; first one wins. - // Parser cannot abort this mapping earlier, since lines - // are processed sequentially. - // But overwriting is allowed when a merge node is used in current block. - if ('<<' === $key) { - $output += $value; - } elseif ($allowOverwrite || !isset($output[$key])) { - if (null !== $tag) { - $output[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $value); - } else { - $output[$key] = $value; - } - } elseif (isset($output[$key])) { - @\trigger_error(self::getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); - } - break; - default: - $value = self::parseScalar($mapping, $flags, [',', '}'], $i, null === $tag, $references); - // Spec: Keys MUST be unique; first one wins. - // Parser cannot abort this mapping earlier, since lines - // are processed sequentially. - // But overwriting is allowed when a merge node is used in current block. - if ('<<' === $key) { - $output += $value; - } elseif ($allowOverwrite || !isset($output[$key])) { - if (null !== $tag) { - $output[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $value); - } else { - $output[$key] = $value; - } - } elseif (isset($output[$key])) { - @\trigger_error(self::getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); - } - --$i; - } - ++$i; - continue 2; - } - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Malformed inline YAML string: "%s".', $mapping), self::$parsedLineNumber + 1, null, self::$parsedFilename); - } - /** - * Evaluates scalars and replaces magic values. - * - * @param string $scalar - * @param int $flags - * @param array $references - * - * @return mixed The evaluated YAML string - * - * @throws ParseException when object parsing support was disabled and the parser detected a PHP object or when a reference could not be resolved - */ - private static function evaluateScalar($scalar, $flags, $references = []) - { - $scalar = \trim($scalar); - $scalarLower = \strtolower($scalar); - if (0 === \strpos($scalar, '*')) { - if (\false !== ($pos = \strpos($scalar, '#'))) { - $value = \substr($scalar, 1, $pos - 2); - } else { - $value = \substr($scalar, 1); - } - // an unquoted * - if (\false === $value || '' === $value) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('A reference must contain at least one character.', self::$parsedLineNumber + 1, $value, self::$parsedFilename); - } - if (!\array_key_exists($value, $references)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Reference "%s" does not exist.', $value), self::$parsedLineNumber + 1, $value, self::$parsedFilename); - } - return $references[$value]; - } - switch (\true) { - case 'null' === $scalarLower: - case '' === $scalar: - case '~' === $scalar: - return null; - case 'true' === $scalarLower: - return \true; - case 'false' === $scalarLower: - return \false; - case '!' === $scalar[0]: - switch (\true) { - case 0 === \strpos($scalar, '!str'): - @\trigger_error(self::getDeprecationMessage('Support for the !str tag is deprecated since Symfony 3.4. Use the !!str tag instead.'), \E_USER_DEPRECATED); - return (string) \substr($scalar, 5); - case 0 === \strpos($scalar, '!!str '): - return (string) \substr($scalar, 6); - case 0 === \strpos($scalar, '! '): - @\trigger_error(self::getDeprecationMessage('Using the non-specific tag "!" is deprecated since Symfony 3.4 as its behavior will change in 4.0. It will force non-evaluating your values in 4.0. Use plain integers or !!float instead.'), \E_USER_DEPRECATED); - return (int) self::parseScalar(\substr($scalar, 2), $flags); - case 0 === \strpos($scalar, '!php/object:'): - if (self::$objectSupport) { - @\trigger_error(self::getDeprecationMessage('The !php/object: tag to indicate dumped PHP objects is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/object (without the colon) tag instead.'), \E_USER_DEPRECATED); - return \unserialize(\substr($scalar, 12)); - } - if (self::$exceptionOnInvalidType) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Object support when parsing a YAML file has been disabled.', self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - return null; - case 0 === \strpos($scalar, '!!php/object:'): - if (self::$objectSupport) { - @\trigger_error(self::getDeprecationMessage('The !!php/object: tag to indicate dumped PHP objects is deprecated since Symfony 3.1 and will be removed in 4.0. Use the !php/object (without the colon) tag instead.'), \E_USER_DEPRECATED); - return \unserialize(\substr($scalar, 13)); - } - if (self::$exceptionOnInvalidType) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Object support when parsing a YAML file has been disabled.', self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - return null; - case 0 === \strpos($scalar, '!php/object'): - if (self::$objectSupport) { - if (!isset($scalar[12])) { - return \false; - } - return \unserialize(self::parseScalar(\substr($scalar, 12))); - } - if (self::$exceptionOnInvalidType) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Object support when parsing a YAML file has been disabled.', self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - return null; - case 0 === \strpos($scalar, '!php/const:'): - if (self::$constantSupport) { - @\trigger_error(self::getDeprecationMessage('The !php/const: tag to indicate dumped PHP constants is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/const (without the colon) tag instead.'), \E_USER_DEPRECATED); - if (\defined($const = \substr($scalar, 11))) { - return \constant($const); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The constant "%s" is not defined.', $const), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - if (self::$exceptionOnInvalidType) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The string "%s" could not be parsed as a constant. Have you forgotten to pass the "Yaml::PARSE_CONSTANT" flag to the parser?', $scalar), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - return null; - case 0 === \strpos($scalar, '!php/const'): - if (self::$constantSupport) { - if (!isset($scalar[11])) { - return ''; - } - $i = 0; - if (\defined($const = self::parseScalar(\substr($scalar, 11), 0, null, $i, \false))) { - return \constant($const); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The constant "%s" is not defined.', $const), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - if (self::$exceptionOnInvalidType) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The string "%s" could not be parsed as a constant. Have you forgotten to pass the "Yaml::PARSE_CONSTANT" flag to the parser?', $scalar), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - return null; - case 0 === \strpos($scalar, '!!float '): - return (float) \substr($scalar, 8); - case 0 === \strpos($scalar, '!!binary '): - return self::evaluateBinaryScalar(\substr($scalar, 9)); - default: - @\trigger_error(self::getDeprecationMessage(\sprintf('Using the unquoted scalar value "%s" is deprecated since Symfony 3.3 and will be considered as a tagged value in 4.0. You must quote it.', $scalar)), \E_USER_DEPRECATED); - } - // Optimize for returning strings. - // no break - case '+' === $scalar[0] || '-' === $scalar[0] || '.' === $scalar[0] || \is_numeric($scalar[0]): - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('{^[+-]?[0-9][0-9_]*$}', $scalar)) { - $scalar = \str_replace('_', '', (string) $scalar); - } - switch (\true) { - case \ctype_digit($scalar): - $raw = $scalar; - $cast = (int) $scalar; - return '0' == $scalar[0] ? \octdec($scalar) : ((string) $raw == (string) $cast ? $cast : $raw); - case '-' === $scalar[0] && \ctype_digit(\substr($scalar, 1)): - $raw = $scalar; - $cast = (int) $scalar; - return '0' == $scalar[1] ? -\octdec(\substr($scalar, 1)) : ($raw === (string) $cast ? $cast : $raw); - case \is_numeric($scalar): - case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match(self::getHexRegex(), $scalar): - $scalar = \str_replace('_', '', $scalar); - return '0x' === $scalar[0] . $scalar[1] ? \hexdec($scalar) : (float) $scalar; - case '.inf' === $scalarLower: - case '.nan' === $scalarLower: - return -\log(0); - case '-.inf' === $scalarLower: - return \log(0); - case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('/^(-|\\+)?[0-9][0-9,]*(\\.[0-9_]+)?$/', $scalar): - case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('/^(-|\\+)?[0-9][0-9_]*(\\.[0-9_]+)?$/', $scalar): - if (\false !== \strpos($scalar, ',')) { - @\trigger_error(self::getDeprecationMessage('Using the comma as a group separator for floats is deprecated since Symfony 3.2 and will be removed in 4.0.'), \E_USER_DEPRECATED); - } - return (float) \str_replace([',', '_'], '', $scalar); - case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match(self::getTimestampRegex(), $scalar): - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_DATETIME & $flags) { - // When no timezone is provided in the parsed date, YAML spec says we must assume UTC. - return new \DateTime($scalar, new \DateTimeZone('UTC')); - } - $timeZone = \date_default_timezone_get(); - \date_default_timezone_set('UTC'); - $time = \strtotime($scalar); - \date_default_timezone_set($timeZone); - return $time; - } - } - return (string) $scalar; - } - /** - * @param string $value - * @param int &$i - * @param int $flags - * - * @return string|null - */ - private static function parseTag($value, &$i, $flags) - { - if ('!' !== $value[$i]) { - return null; - } - $tagLength = \strcspn($value, " \t\n", $i + 1); - $tag = \substr($value, $i + 1, $tagLength); - $nextOffset = $i + $tagLength + 1; - $nextOffset += \strspn($value, ' ', $nextOffset); - // Is followed by a scalar - if ((!isset($value[$nextOffset]) || !\in_array($value[$nextOffset], ['[', '{'], \true)) && 'tagged' !== $tag) { - // Manage non-whitelisted scalars in {@link self::evaluateScalar()} - return null; - } - // Built-in tags - if ($tag && '!' === $tag[0]) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The built-in tag "!%s" is not implemented.', $tag), self::$parsedLineNumber + 1, $value, self::$parsedFilename); - } - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS & $flags) { - $i = $nextOffset; - return $tag; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Tags support is not enabled. Enable the `Yaml::PARSE_CUSTOM_TAGS` flag to use "!%s".', $tag), self::$parsedLineNumber + 1, $value, self::$parsedFilename); - } - /** - * @param string $scalar - * - * @return string - * - * @internal - */ - public static function evaluateBinaryScalar($scalar) - { - $parsedBinaryData = self::parseScalar(\preg_replace('/\\s/', '', $scalar)); - if (0 !== \strlen($parsedBinaryData) % 4) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The normalized base64 encoded data (data without whitespace characters) length must be a multiple of four (%d bytes given).', \strlen($parsedBinaryData)), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('#^[A-Z0-9+/]+={0,2}$#i', $parsedBinaryData)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The base64 encoded data (%s) contains invalid characters.', $parsedBinaryData), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); - } - return \base64_decode($parsedBinaryData, \true); - } - private static function isBinaryString($value) - { - return !\preg_match('//u', $value) || \preg_match('/[^\\x00\\x07-\\x0d\\x1B\\x20-\\xff]/', $value); - } - /** - * Gets a regex that matches a YAML date. - * - * @return string The regular expression - * - * @see http://www.yaml.org/spec/1.2/spec.html#id2761573 - */ - private static function getTimestampRegex() - { - return <<[0-9][0-9][0-9][0-9]) - -(?P[0-9][0-9]?) - -(?P[0-9][0-9]?) - (?:(?:[Tt]|[ \t]+) - (?P[0-9][0-9]?) - :(?P[0-9][0-9]) - :(?P[0-9][0-9]) - (?:\\.(?P[0-9]*))? - (?:[ \t]*(?PZ|(?P[-+])(?P[0-9][0-9]?) - (?::(?P[0-9][0-9]))?))?)? - \$~x -EOF; - } - /** - * Gets a regex that matches a YAML number in hexadecimal notation. - * - * @return string - */ - private static function getHexRegex() - { - return '~^0x[0-9a-f_]++$~i'; - } - private static function getDeprecationMessage($message) - { - $message = \rtrim($message, '.'); - if (null !== self::$parsedFilename) { - $message .= ' in ' . self::$parsedFilename; - } - if (-1 !== self::$parsedLineNumber) { - $message .= ' on line ' . (self::$parsedLineNumber + 1); - } - return $message . '.'; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\DumpException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; +/** + * Inline implements a YAML parser/dumper for the YAML inline syntax. + * + * @author Fabien Potencier + * + * @internal + */ +class Inline +{ + const REGEX_QUOTED_STRING = '(?:"([^"\\\\]*+(?:\\\\.[^"\\\\]*+)*+)"|\'([^\']*+(?:\'\'[^\']*+)*+)\')'; + public static $parsedLineNumber = -1; + public static $parsedFilename; + private static $exceptionOnInvalidType = \false; + private static $objectSupport = \false; + private static $objectForMap = \false; + private static $constantSupport = \false; + /** + * @param int $flags + * @param int|null $parsedLineNumber + * @param string|null $parsedFilename + */ + public static function initialize($flags, $parsedLineNumber = null, $parsedFilename = null) + { + self::$exceptionOnInvalidType = (bool) (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE & $flags); + self::$objectSupport = (bool) (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT & $flags); + self::$objectForMap = (bool) (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags); + self::$constantSupport = (bool) (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT & $flags); + self::$parsedFilename = $parsedFilename; + if (null !== $parsedLineNumber) { + self::$parsedLineNumber = $parsedLineNumber; + } + } + /** + * Converts a YAML string to a PHP value. + * + * @param string $value A YAML string + * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior + * @param array $references Mapping of variable names to values + * + * @return mixed A PHP value + * + * @throws ParseException + */ + public static function parse($value, $flags = 0, $references = []) + { + if (\is_bool($flags)) { + @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); + if ($flags) { + $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE; + } else { + $flags = 0; + } + } + if (\func_num_args() >= 3 && !\is_array($references)) { + @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_OBJECT flag instead.', \E_USER_DEPRECATED); + if ($references) { + $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT; + } + if (\func_num_args() >= 4) { + @\trigger_error('Passing a boolean flag to toggle object for map support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_OBJECT_FOR_MAP flag instead.', \E_USER_DEPRECATED); + if (\func_get_arg(3)) { + $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP; + } + } + if (\func_num_args() >= 5) { + $references = \func_get_arg(4); + } else { + $references = []; + } + } + self::initialize($flags); + $value = \trim($value); + if ('' === $value) { + return ''; + } + if (2 & (int) \ini_get('mbstring.func_overload')) { + $mbEncoding = \mb_internal_encoding(); + \mb_internal_encoding('ASCII'); + } + try { + $i = 0; + $tag = self::parseTag($value, $i, $flags); + switch ($value[$i]) { + case '[': + $result = self::parseSequence($value, $flags, $i, $references); + ++$i; + break; + case '{': + $result = self::parseMapping($value, $flags, $i, $references); + ++$i; + break; + default: + $result = self::parseScalar($value, $flags, null, $i, null === $tag, $references); + } + // some comments are allowed at the end + if (\preg_replace('/\\s+#.*$/A', '', \substr($value, $i))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Unexpected characters near "%s".', \substr($value, $i)), self::$parsedLineNumber + 1, $value, self::$parsedFilename); + } + if (null !== $tag) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $result); + } + return $result; + } finally { + if (isset($mbEncoding)) { + \mb_internal_encoding($mbEncoding); + } + } + } + /** + * Dumps a given PHP variable to a YAML string. + * + * @param mixed $value The PHP variable to convert + * @param int $flags A bit field of Yaml::DUMP_* constants to customize the dumped YAML string + * + * @return string The YAML string representing the PHP value + * + * @throws DumpException When trying to dump PHP resource + */ + public static function dump($value, $flags = 0) + { + if (\is_bool($flags)) { + @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); + if ($flags) { + $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE; + } else { + $flags = 0; + } + } + if (\func_num_args() >= 3) { + @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::DUMP_OBJECT flag instead.', \E_USER_DEPRECATED); + if (\func_get_arg(2)) { + $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT; + } + } + switch (\true) { + case \is_resource($value): + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE & $flags) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\DumpException(\sprintf('Unable to dump PHP resources in a YAML file ("%s").', \get_resource_type($value))); + } + return 'null'; + case $value instanceof \DateTimeInterface: + return $value->format('c'); + case \is_object($value): + if ($value instanceof \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue) { + return '!' . $value->getTag() . ' ' . self::dump($value->getValue(), $flags); + } + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT & $flags) { + return '!php/object ' . self::dump(\serialize($value)); + } + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP & $flags && ($value instanceof \stdClass || $value instanceof \ArrayObject)) { + return self::dumpArray($value, $flags & ~\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE); + } + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE & $flags) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\DumpException('Object support when dumping a YAML file has been disabled.'); + } + return 'null'; + case \is_array($value): + return self::dumpArray($value, $flags); + case null === $value: + return 'null'; + case \true === $value: + return 'true'; + case \false === $value: + return 'false'; + case \ctype_digit($value): + return \is_string($value) ? "'{$value}'" : (int) $value; + case \is_numeric($value): + $locale = \setlocale(\LC_NUMERIC, 0); + if (\false !== $locale) { + \setlocale(\LC_NUMERIC, 'C'); + } + if (\is_float($value)) { + $repr = (string) $value; + if (\is_infinite($value)) { + $repr = \str_ireplace('INF', '.Inf', $repr); + } elseif (\floor($value) == $value && $repr == $value) { + // Preserve float data type since storing a whole number will result in integer value. + $repr = '!!float ' . $repr; + } + } else { + $repr = \is_string($value) ? "'{$value}'" : (string) $value; + } + if (\false !== $locale) { + \setlocale(\LC_NUMERIC, $locale); + } + return $repr; + case '' == $value: + return "''"; + case self::isBinaryString($value): + return '!!binary ' . \base64_encode($value); + case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Escaper::requiresDoubleQuoting($value): + return \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Escaper::escapeWithDoubleQuotes($value); + case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Escaper::requiresSingleQuoting($value): + case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('{^[0-9]+[_0-9]*$}', $value): + case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match(self::getHexRegex(), $value): + case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match(self::getTimestampRegex(), $value): + return \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Escaper::escapeWithSingleQuotes($value); + default: + return $value; + } + } + /** + * Check if given array is hash or just normal indexed array. + * + * @internal + * + * @param array|\ArrayObject|\stdClass $value The PHP array or array-like object to check + * + * @return bool true if value is hash array, false otherwise + */ + public static function isHash($value) + { + if ($value instanceof \stdClass || $value instanceof \ArrayObject) { + return \true; + } + $expectedKey = 0; + foreach ($value as $key => $val) { + if ($key !== $expectedKey++) { + return \true; + } + } + return \false; + } + /** + * Dumps a PHP array to a YAML string. + * + * @param array $value The PHP array to dump + * @param int $flags A bit field of Yaml::DUMP_* constants to customize the dumped YAML string + * + * @return string The YAML string representing the PHP array + */ + private static function dumpArray($value, $flags) + { + // array + if (($value || \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE & $flags) && !self::isHash($value)) { + $output = []; + foreach ($value as $val) { + $output[] = self::dump($val, $flags); + } + return \sprintf('[%s]', \implode(', ', $output)); + } + // hash + $output = []; + foreach ($value as $key => $val) { + $output[] = \sprintf('%s: %s', self::dump($key, $flags), self::dump($val, $flags)); + } + return \sprintf('{ %s }', \implode(', ', $output)); + } + /** + * Parses a YAML scalar. + * + * @param string $scalar + * @param int $flags + * @param string[] $delimiters + * @param int &$i + * @param bool $evaluate + * @param array $references + * + * @return string + * + * @throws ParseException When malformed inline YAML string is parsed + * + * @internal + */ + public static function parseScalar($scalar, $flags = 0, $delimiters = null, &$i = 0, $evaluate = \true, $references = [], $legacyOmittedKeySupport = \false) + { + if (\in_array($scalar[$i], ['"', "'"])) { + // quoted scalar + $output = self::parseQuotedScalar($scalar, $i); + if (null !== $delimiters) { + $tmp = \ltrim(\substr($scalar, $i), ' '); + if ('' === $tmp) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Unexpected end of line, expected one of "%s".', \implode('', $delimiters)), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + if (!\in_array($tmp[0], $delimiters)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Unexpected characters (%s).', \substr($scalar, $i)), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + } + } else { + // "normal" string + if (!$delimiters) { + $output = \substr($scalar, $i); + $i += \strlen($output); + // remove comments + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('/[ \\t]+#/', $output, $match, \PREG_OFFSET_CAPTURE)) { + $output = \substr($output, 0, $match[0][1]); + } + } elseif (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('/^(.' . ($legacyOmittedKeySupport ? '+' : '*') . '?)(' . \implode('|', $delimiters) . ')/', \substr($scalar, $i), $match)) { + $output = $match[1]; + $i += \strlen($output); + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Malformed inline YAML string: "%s".', $scalar), self::$parsedLineNumber + 1, null, self::$parsedFilename); + } + // a non-quoted string cannot start with @ or ` (reserved) nor with a scalar indicator (| or >) + if ($output && ('@' === $output[0] || '`' === $output[0] || '|' === $output[0] || '>' === $output[0])) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The reserved indicator "%s" cannot start a plain scalar; you need to quote the scalar.', $output[0]), self::$parsedLineNumber + 1, $output, self::$parsedFilename); + } + if ($output && '%' === $output[0]) { + @\trigger_error(self::getDeprecationMessage(\sprintf('Not quoting the scalar "%s" starting with the "%%" indicator character is deprecated since Symfony 3.1 and will throw a ParseException in 4.0.', $output)), \E_USER_DEPRECATED); + } + if ($evaluate) { + $output = self::evaluateScalar($output, $flags, $references); + } + } + return $output; + } + /** + * Parses a YAML quoted scalar. + * + * @param string $scalar + * @param int &$i + * + * @return string + * + * @throws ParseException When malformed inline YAML string is parsed + */ + private static function parseQuotedScalar($scalar, &$i) + { + if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('/' . self::REGEX_QUOTED_STRING . '/Au', \substr($scalar, $i), $match)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Malformed inline YAML string: "%s".', \substr($scalar, $i)), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + $output = \substr($match[0], 1, \strlen($match[0]) - 2); + $unescaper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Unescaper(); + if ('"' == $scalar[$i]) { + $output = $unescaper->unescapeDoubleQuotedString($output); + } else { + $output = $unescaper->unescapeSingleQuotedString($output); + } + $i += \strlen($match[0]); + return $output; + } + /** + * Parses a YAML sequence. + * + * @param string $sequence + * @param int $flags + * @param int &$i + * @param array $references + * + * @return array + * + * @throws ParseException When malformed inline YAML string is parsed + */ + private static function parseSequence($sequence, $flags, &$i = 0, $references = []) + { + $output = []; + $len = \strlen($sequence); + ++$i; + // [foo, bar, ...] + while ($i < $len) { + if (']' === $sequence[$i]) { + return $output; + } + if (',' === $sequence[$i] || ' ' === $sequence[$i]) { + ++$i; + continue; + } + $tag = self::parseTag($sequence, $i, $flags); + switch ($sequence[$i]) { + case '[': + // nested sequence + $value = self::parseSequence($sequence, $flags, $i, $references); + break; + case '{': + // nested mapping + $value = self::parseMapping($sequence, $flags, $i, $references); + break; + default: + $isQuoted = \in_array($sequence[$i], ['"', "'"]); + $value = self::parseScalar($sequence, $flags, [',', ']'], $i, null === $tag, $references); + // the value can be an array if a reference has been resolved to an array var + if (\is_string($value) && !$isQuoted && \false !== \strpos($value, ': ')) { + // embedded mapping? + try { + $pos = 0; + $value = self::parseMapping('{' . $value . '}', $flags, $pos, $references); + } catch (\InvalidArgumentException $e) { + // no, it's not + } + } + --$i; + } + if (null !== $tag) { + $value = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $value); + } + $output[] = $value; + ++$i; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Malformed inline YAML string: "%s".', $sequence), self::$parsedLineNumber + 1, null, self::$parsedFilename); + } + /** + * Parses a YAML mapping. + * + * @param string $mapping + * @param int $flags + * @param int &$i + * @param array $references + * + * @return array|\stdClass + * + * @throws ParseException When malformed inline YAML string is parsed + */ + private static function parseMapping($mapping, $flags, &$i = 0, $references = []) + { + $output = []; + $len = \strlen($mapping); + ++$i; + $allowOverwrite = \false; + // {foo: bar, bar:foo, ...} + while ($i < $len) { + switch ($mapping[$i]) { + case ' ': + case ',': + ++$i; + continue 2; + case '}': + if (self::$objectForMap) { + return (object) $output; + } + return $output; + } + // key + $isKeyQuoted = \in_array($mapping[$i], ['"', "'"], \true); + $key = self::parseScalar($mapping, $flags, [':', ' '], $i, \false, [], \true); + if ('!php/const' === $key) { + $key .= self::parseScalar($mapping, $flags, [':', ' '], $i, \false, [], \true); + if ('!php/const:' === $key && ':' !== $mapping[$i]) { + $key = ''; + --$i; + } else { + $key = self::evaluateScalar($key, $flags); + } + } + if (':' !== $key && \false === ($i = \strpos($mapping, ':', $i))) { + break; + } + if (':' === $key) { + @\trigger_error(self::getDeprecationMessage('Omitting the key of a mapping is deprecated and will throw a ParseException in 4.0.'), \E_USER_DEPRECATED); + } + if (!$isKeyQuoted) { + $evaluatedKey = self::evaluateScalar($key, $flags, $references); + if ('' !== $key && $evaluatedKey !== $key && !\is_string($evaluatedKey) && !\is_int($evaluatedKey)) { + @\trigger_error(self::getDeprecationMessage('Implicit casting of incompatible mapping keys to strings is deprecated since Symfony 3.3 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0. Quote your evaluable mapping keys instead.'), \E_USER_DEPRECATED); + } + } + if (':' !== $key && !$isKeyQuoted && (!isset($mapping[$i + 1]) || !\in_array($mapping[$i + 1], [' ', ',', '[', ']', '{', '}'], \true))) { + @\trigger_error(self::getDeprecationMessage('Using a colon after an unquoted mapping key that is not followed by an indication character (i.e. " ", ",", "[", "]", "{", "}") is deprecated since Symfony 3.2 and will throw a ParseException in 4.0.'), \E_USER_DEPRECATED); + } + if ('<<' === $key) { + $allowOverwrite = \true; + } + while ($i < $len) { + if (':' === $mapping[$i] || ' ' === $mapping[$i]) { + ++$i; + continue; + } + $tag = self::parseTag($mapping, $i, $flags); + switch ($mapping[$i]) { + case '[': + // nested sequence + $value = self::parseSequence($mapping, $flags, $i, $references); + // Spec: Keys MUST be unique; first one wins. + // Parser cannot abort this mapping earlier, since lines + // are processed sequentially. + // But overwriting is allowed when a merge node is used in current block. + if ('<<' === $key) { + foreach ($value as $parsedValue) { + $output += $parsedValue; + } + } elseif ($allowOverwrite || !isset($output[$key])) { + if (null !== $tag) { + $output[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $value); + } else { + $output[$key] = $value; + } + } elseif (isset($output[$key])) { + @\trigger_error(self::getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); + } + break; + case '{': + // nested mapping + $value = self::parseMapping($mapping, $flags, $i, $references); + // Spec: Keys MUST be unique; first one wins. + // Parser cannot abort this mapping earlier, since lines + // are processed sequentially. + // But overwriting is allowed when a merge node is used in current block. + if ('<<' === $key) { + $output += $value; + } elseif ($allowOverwrite || !isset($output[$key])) { + if (null !== $tag) { + $output[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $value); + } else { + $output[$key] = $value; + } + } elseif (isset($output[$key])) { + @\trigger_error(self::getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); + } + break; + default: + $value = self::parseScalar($mapping, $flags, [',', '}'], $i, null === $tag, $references); + // Spec: Keys MUST be unique; first one wins. + // Parser cannot abort this mapping earlier, since lines + // are processed sequentially. + // But overwriting is allowed when a merge node is used in current block. + if ('<<' === $key) { + $output += $value; + } elseif ($allowOverwrite || !isset($output[$key])) { + if (null !== $tag) { + $output[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $value); + } else { + $output[$key] = $value; + } + } elseif (isset($output[$key])) { + @\trigger_error(self::getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); + } + --$i; + } + ++$i; + continue 2; + } + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Malformed inline YAML string: "%s".', $mapping), self::$parsedLineNumber + 1, null, self::$parsedFilename); + } + /** + * Evaluates scalars and replaces magic values. + * + * @param string $scalar + * @param int $flags + * @param array $references + * + * @return mixed The evaluated YAML string + * + * @throws ParseException when object parsing support was disabled and the parser detected a PHP object or when a reference could not be resolved + */ + private static function evaluateScalar($scalar, $flags, $references = []) + { + $scalar = \trim($scalar); + $scalarLower = \strtolower($scalar); + if (0 === \strpos($scalar, '*')) { + if (\false !== ($pos = \strpos($scalar, '#'))) { + $value = \substr($scalar, 1, $pos - 2); + } else { + $value = \substr($scalar, 1); + } + // an unquoted * + if (\false === $value || '' === $value) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('A reference must contain at least one character.', self::$parsedLineNumber + 1, $value, self::$parsedFilename); + } + if (!\array_key_exists($value, $references)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Reference "%s" does not exist.', $value), self::$parsedLineNumber + 1, $value, self::$parsedFilename); + } + return $references[$value]; + } + switch (\true) { + case 'null' === $scalarLower: + case '' === $scalar: + case '~' === $scalar: + return null; + case 'true' === $scalarLower: + return \true; + case 'false' === $scalarLower: + return \false; + case '!' === $scalar[0]: + switch (\true) { + case 0 === \strpos($scalar, '!str'): + @\trigger_error(self::getDeprecationMessage('Support for the !str tag is deprecated since Symfony 3.4. Use the !!str tag instead.'), \E_USER_DEPRECATED); + return (string) \substr($scalar, 5); + case 0 === \strpos($scalar, '!!str '): + return (string) \substr($scalar, 6); + case 0 === \strpos($scalar, '! '): + @\trigger_error(self::getDeprecationMessage('Using the non-specific tag "!" is deprecated since Symfony 3.4 as its behavior will change in 4.0. It will force non-evaluating your values in 4.0. Use plain integers or !!float instead.'), \E_USER_DEPRECATED); + return (int) self::parseScalar(\substr($scalar, 2), $flags); + case 0 === \strpos($scalar, '!php/object:'): + if (self::$objectSupport) { + @\trigger_error(self::getDeprecationMessage('The !php/object: tag to indicate dumped PHP objects is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/object (without the colon) tag instead.'), \E_USER_DEPRECATED); + return \unserialize(\substr($scalar, 12)); + } + if (self::$exceptionOnInvalidType) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Object support when parsing a YAML file has been disabled.', self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + return null; + case 0 === \strpos($scalar, '!!php/object:'): + if (self::$objectSupport) { + @\trigger_error(self::getDeprecationMessage('The !!php/object: tag to indicate dumped PHP objects is deprecated since Symfony 3.1 and will be removed in 4.0. Use the !php/object (without the colon) tag instead.'), \E_USER_DEPRECATED); + return \unserialize(\substr($scalar, 13)); + } + if (self::$exceptionOnInvalidType) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Object support when parsing a YAML file has been disabled.', self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + return null; + case 0 === \strpos($scalar, '!php/object'): + if (self::$objectSupport) { + if (!isset($scalar[12])) { + return \false; + } + return \unserialize(self::parseScalar(\substr($scalar, 12))); + } + if (self::$exceptionOnInvalidType) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Object support when parsing a YAML file has been disabled.', self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + return null; + case 0 === \strpos($scalar, '!php/const:'): + if (self::$constantSupport) { + @\trigger_error(self::getDeprecationMessage('The !php/const: tag to indicate dumped PHP constants is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/const (without the colon) tag instead.'), \E_USER_DEPRECATED); + if (\defined($const = \substr($scalar, 11))) { + return \constant($const); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The constant "%s" is not defined.', $const), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + if (self::$exceptionOnInvalidType) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The string "%s" could not be parsed as a constant. Have you forgotten to pass the "Yaml::PARSE_CONSTANT" flag to the parser?', $scalar), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + return null; + case 0 === \strpos($scalar, '!php/const'): + if (self::$constantSupport) { + if (!isset($scalar[11])) { + return ''; + } + $i = 0; + if (\defined($const = self::parseScalar(\substr($scalar, 11), 0, null, $i, \false))) { + return \constant($const); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The constant "%s" is not defined.', $const), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + if (self::$exceptionOnInvalidType) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The string "%s" could not be parsed as a constant. Have you forgotten to pass the "Yaml::PARSE_CONSTANT" flag to the parser?', $scalar), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + return null; + case 0 === \strpos($scalar, '!!float '): + return (float) \substr($scalar, 8); + case 0 === \strpos($scalar, '!!binary '): + return self::evaluateBinaryScalar(\substr($scalar, 9)); + default: + @\trigger_error(self::getDeprecationMessage(\sprintf('Using the unquoted scalar value "%s" is deprecated since Symfony 3.3 and will be considered as a tagged value in 4.0. You must quote it.', $scalar)), \E_USER_DEPRECATED); + } + // Optimize for returning strings. + // no break + case '+' === $scalar[0] || '-' === $scalar[0] || '.' === $scalar[0] || \is_numeric($scalar[0]): + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('{^[+-]?[0-9][0-9_]*$}', $scalar)) { + $scalar = \str_replace('_', '', (string) $scalar); + } + switch (\true) { + case \ctype_digit($scalar): + $raw = $scalar; + $cast = (int) $scalar; + return '0' == $scalar[0] ? \octdec($scalar) : ((string) $raw == (string) $cast ? $cast : $raw); + case '-' === $scalar[0] && \ctype_digit(\substr($scalar, 1)): + $raw = $scalar; + $cast = (int) $scalar; + return '0' == $scalar[1] ? -\octdec(\substr($scalar, 1)) : ($raw === (string) $cast ? $cast : $raw); + case \is_numeric($scalar): + case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match(self::getHexRegex(), $scalar): + $scalar = \str_replace('_', '', $scalar); + return '0x' === $scalar[0] . $scalar[1] ? \hexdec($scalar) : (float) $scalar; + case '.inf' === $scalarLower: + case '.nan' === $scalarLower: + return -\log(0); + case '-.inf' === $scalarLower: + return \log(0); + case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('/^(-|\\+)?[0-9][0-9,]*(\\.[0-9_]+)?$/', $scalar): + case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('/^(-|\\+)?[0-9][0-9_]*(\\.[0-9_]+)?$/', $scalar): + if (\false !== \strpos($scalar, ',')) { + @\trigger_error(self::getDeprecationMessage('Using the comma as a group separator for floats is deprecated since Symfony 3.2 and will be removed in 4.0.'), \E_USER_DEPRECATED); + } + return (float) \str_replace([',', '_'], '', $scalar); + case \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match(self::getTimestampRegex(), $scalar): + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_DATETIME & $flags) { + // When no timezone is provided in the parsed date, YAML spec says we must assume UTC. + return new \DateTime($scalar, new \DateTimeZone('UTC')); + } + $timeZone = \date_default_timezone_get(); + \date_default_timezone_set('UTC'); + $time = \strtotime($scalar); + \date_default_timezone_set($timeZone); + return $time; + } + } + return (string) $scalar; + } + /** + * @param string $value + * @param int &$i + * @param int $flags + * + * @return string|null + */ + private static function parseTag($value, &$i, $flags) + { + if ('!' !== $value[$i]) { + return null; + } + $tagLength = \strcspn($value, " \t\n", $i + 1); + $tag = \substr($value, $i + 1, $tagLength); + $nextOffset = $i + $tagLength + 1; + $nextOffset += \strspn($value, ' ', $nextOffset); + // Is followed by a scalar + if ((!isset($value[$nextOffset]) || !\in_array($value[$nextOffset], ['[', '{'], \true)) && 'tagged' !== $tag) { + // Manage non-whitelisted scalars in {@link self::evaluateScalar()} + return null; + } + // Built-in tags + if ($tag && '!' === $tag[0]) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The built-in tag "!%s" is not implemented.', $tag), self::$parsedLineNumber + 1, $value, self::$parsedFilename); + } + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS & $flags) { + $i = $nextOffset; + return $tag; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Tags support is not enabled. Enable the `Yaml::PARSE_CUSTOM_TAGS` flag to use "!%s".', $tag), self::$parsedLineNumber + 1, $value, self::$parsedFilename); + } + /** + * @param string $scalar + * + * @return string + * + * @internal + */ + public static function evaluateBinaryScalar($scalar) + { + $parsedBinaryData = self::parseScalar(\preg_replace('/\\s/', '', $scalar)); + if (0 !== \strlen($parsedBinaryData) % 4) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The normalized base64 encoded data (data without whitespace characters) length must be a multiple of four (%d bytes given).', \strlen($parsedBinaryData)), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + if (!\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser::preg_match('#^[A-Z0-9+/]+={0,2}$#i', $parsedBinaryData)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The base64 encoded data (%s) contains invalid characters.', $parsedBinaryData), self::$parsedLineNumber + 1, $scalar, self::$parsedFilename); + } + return \base64_decode($parsedBinaryData, \true); + } + private static function isBinaryString($value) + { + return !\preg_match('//u', $value) || \preg_match('/[^\\x00\\x07-\\x0d\\x1B\\x20-\\xff]/', $value); + } + /** + * Gets a regex that matches a YAML date. + * + * @return string The regular expression + * + * @see http://www.yaml.org/spec/1.2/spec.html#id2761573 + */ + private static function getTimestampRegex() + { + return <<[0-9][0-9][0-9][0-9]) + -(?P[0-9][0-9]?) + -(?P[0-9][0-9]?) + (?:(?:[Tt]|[ \t]+) + (?P[0-9][0-9]?) + :(?P[0-9][0-9]) + :(?P[0-9][0-9]) + (?:\\.(?P[0-9]*))? + (?:[ \t]*(?PZ|(?P[-+])(?P[0-9][0-9]?) + (?::(?P[0-9][0-9]))?))?)? + \$~x +EOF; + } + /** + * Gets a regex that matches a YAML number in hexadecimal notation. + * + * @return string + */ + private static function getHexRegex() + { + return '~^0x[0-9a-f_]++$~i'; + } + private static function getDeprecationMessage($message) + { + $message = \rtrim($message, '.'); + if (null !== self::$parsedFilename) { + $message .= ' in ' . self::$parsedFilename; + } + if (-1 !== self::$parsedLineNumber) { + $message .= ' on line ' . (self::$parsedLineNumber + 1); + } + return $message . '.'; + } +} diff --git a/vendor/symfony/yaml/LICENSE b/vendor/symfony/yaml/LICENSE index 9e936ec04..2bb330476 100644 --- a/vendor/symfony/yaml/LICENSE +++ b/vendor/symfony/yaml/LICENSE @@ -1,19 +1,19 @@ -Copyright (c) 2004-2020 Fabien Potencier - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +Copyright (c) 2004-2020 Fabien Potencier + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is furnished +to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vendor/symfony/yaml/Parser.php b/vendor/symfony/yaml/Parser.php index 78f419230..34a0eefb6 100644 --- a/vendor/symfony/yaml/Parser.php +++ b/vendor/symfony/yaml/Parser.php @@ -1,950 +1,950 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; -/** - * Parser parses YAML strings to convert them to PHP arrays. - * - * @author Fabien Potencier - * - * @final since version 3.4 - */ -class Parser -{ - const TAG_PATTERN = '(?P![\\w!.\\/:-]+)'; - const BLOCK_SCALAR_HEADER_PATTERN = '(?P\\||>)(?P\\+|\\-|\\d+|\\+\\d+|\\-\\d+|\\d+\\+|\\d+\\-)?(?P +#.*)?'; - private $filename; - private $offset = 0; - private $totalNumberOfLines; - private $lines = []; - private $currentLineNb = -1; - private $currentLine = ''; - private $refs = []; - private $skippedLineNumbers = []; - private $locallySkippedLineNumbers = []; - private $refsBeingParsed = []; - public function __construct() - { - if (\func_num_args() > 0) { - @\trigger_error(\sprintf('The constructor arguments $offset, $totalNumberOfLines, $skippedLineNumbers of %s are deprecated and will be removed in 4.0', self::class), \E_USER_DEPRECATED); - $this->offset = \func_get_arg(0); - if (\func_num_args() > 1) { - $this->totalNumberOfLines = \func_get_arg(1); - } - if (\func_num_args() > 2) { - $this->skippedLineNumbers = \func_get_arg(2); - } - } - } - /** - * Parses a YAML file into a PHP value. - * - * @param string $filename The path to the YAML file to be parsed - * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior - * - * @return mixed The YAML converted to a PHP value - * - * @throws ParseException If the file could not be read or the YAML is not valid - */ - public function parseFile($filename, $flags = 0) - { - if (!\is_file($filename)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('File "%s" does not exist.', $filename)); - } - if (!\is_readable($filename)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('File "%s" cannot be read.', $filename)); - } - $this->filename = $filename; - try { - return $this->parse(\file_get_contents($filename), $flags); - } finally { - $this->filename = null; - } - } - /** - * Parses a YAML string to a PHP value. - * - * @param string $value A YAML string - * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior - * - * @return mixed A PHP value - * - * @throws ParseException If the YAML is not valid - */ - public function parse($value, $flags = 0) - { - if (\is_bool($flags)) { - @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); - if ($flags) { - $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE; - } else { - $flags = 0; - } - } - if (\func_num_args() >= 3) { - @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_OBJECT flag instead.', \E_USER_DEPRECATED); - if (\func_get_arg(2)) { - $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT; - } - } - if (\func_num_args() >= 4) { - @\trigger_error('Passing a boolean flag to toggle object for map support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_OBJECT_FOR_MAP flag instead.', \E_USER_DEPRECATED); - if (\func_get_arg(3)) { - $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP; - } - } - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_KEYS_AS_STRINGS & $flags) { - @\trigger_error('Using the Yaml::PARSE_KEYS_AS_STRINGS flag is deprecated since Symfony 3.4 as it will be removed in 4.0. Quote your keys when they are evaluable instead.', \E_USER_DEPRECATED); - } - if (\false === \preg_match('//u', $value)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('The YAML value does not appear to be valid UTF-8.', -1, null, $this->filename); - } - $this->refs = []; - $mbEncoding = null; - $e = null; - $data = null; - if (2 & (int) \ini_get('mbstring.func_overload')) { - $mbEncoding = \mb_internal_encoding(); - \mb_internal_encoding('UTF-8'); - } - try { - $data = $this->doParse($value, $flags); - } catch (\Exception $e) { - } catch (\Throwable $e) { - } - if (null !== $mbEncoding) { - \mb_internal_encoding($mbEncoding); - } - $this->lines = []; - $this->currentLine = ''; - $this->refs = []; - $this->skippedLineNumbers = []; - $this->locallySkippedLineNumbers = []; - if (null !== $e) { - throw $e; - } - return $data; - } - private function doParse($value, $flags) - { - $this->currentLineNb = -1; - $this->currentLine = ''; - $value = $this->cleanup($value); - $this->lines = \explode("\n", $value); - $this->locallySkippedLineNumbers = []; - if (null === $this->totalNumberOfLines) { - $this->totalNumberOfLines = \count($this->lines); - } - if (!$this->moveToNextLine()) { - return null; - } - $data = []; - $context = null; - $allowOverwrite = \false; - while ($this->isCurrentLineEmpty()) { - if (!$this->moveToNextLine()) { - return null; - } - } - // Resolves the tag and returns if end of the document - if (null !== ($tag = $this->getLineTag($this->currentLine, $flags, \false)) && !$this->moveToNextLine()) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, ''); - } - do { - if ($this->isCurrentLineEmpty()) { - continue; - } - // tab? - if ("\t" === $this->currentLine[0]) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('A YAML file cannot contain tabs as indentation.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); - } - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::initialize($flags, $this->getRealCurrentLineNb(), $this->filename); - $isRef = $mergeNode = \false; - if (self::preg_match('#^\\-((?P\\s+)(?P.+))?$#u', \rtrim($this->currentLine), $values)) { - if ($context && 'mapping' == $context) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('You cannot define a sequence item when in a mapping.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); - } - $context = 'sequence'; - if (isset($values['value']) && self::preg_match('#^&(?P[^ ]+) *(?P.*)#u', $values['value'], $matches)) { - $isRef = $matches['ref']; - $this->refsBeingParsed[] = $isRef; - $values['value'] = $matches['value']; - } - if (isset($values['value'][1]) && '?' === $values['value'][0] && ' ' === $values['value'][1]) { - @\trigger_error($this->getDeprecationMessage('Starting an unquoted string with a question mark followed by a space is deprecated since Symfony 3.3 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.'), \E_USER_DEPRECATED); - } - // array - if (!isset($values['value']) || '' == \trim($values['value'], ' ') || 0 === \strpos(\ltrim($values['value'], ' '), '#')) { - $data[] = $this->parseBlock($this->getRealCurrentLineNb() + 1, $this->getNextEmbedBlock(null, \true), $flags); - } elseif (null !== ($subTag = $this->getLineTag(\ltrim($values['value'], ' '), $flags))) { - $data[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($subTag, $this->parseBlock($this->getRealCurrentLineNb() + 1, $this->getNextEmbedBlock(null, \true), $flags)); - } else { - if (isset($values['leadspaces']) && self::preg_match('#^(?P' . \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::REGEX_QUOTED_STRING . '|[^ \'"\\{\\[].*?) *\\:(\\s+(?P.+?))?\\s*$#u', $this->trimTag($values['value']), $matches)) { - // this is a compact notation element, add to next block and parse - $block = $values['value']; - if ($this->isNextLineIndented()) { - $block .= "\n" . $this->getNextEmbedBlock($this->getCurrentLineIndentation() + \strlen($values['leadspaces']) + 1); - } - $data[] = $this->parseBlock($this->getRealCurrentLineNb(), $block, $flags); - } else { - $data[] = $this->parseValue($values['value'], $flags, $context); - } - } - if ($isRef) { - $this->refs[$isRef] = \end($data); - \array_pop($this->refsBeingParsed); - } - } elseif (self::preg_match('#^(?P(?:![^\\s]++\\s++)?(?:' . \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::REGEX_QUOTED_STRING . '|(?:!?!php/const:)?[^ \'"\\[\\{!].*?)) *\\:(\\s++(?P.+))?$#u', \rtrim($this->currentLine), $values) && (\false === \strpos($values['key'], ' #') || \in_array($values['key'][0], ['"', "'"]))) { - if ($context && 'sequence' == $context) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('You cannot define a mapping item when in a sequence.', $this->currentLineNb + 1, $this->currentLine, $this->filename); - } - $context = 'mapping'; - try { - $i = 0; - $evaluateKey = !(\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_KEYS_AS_STRINGS & $flags); - // constants in key will be evaluated anyway - if (isset($values['key'][0]) && '!' === $values['key'][0] && \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT & $flags) { - $evaluateKey = \true; - } - $key = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parseScalar($values['key'], 0, null, $i, $evaluateKey); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { - $e->setParsedLine($this->getRealCurrentLineNb() + 1); - $e->setSnippet($this->currentLine); - throw $e; - } - if (!\is_string($key) && !\is_int($key)) { - $keyType = \is_numeric($key) ? 'numeric key' : 'non-string key'; - @\trigger_error($this->getDeprecationMessage(\sprintf('Implicit casting of %s to string is deprecated since Symfony 3.3 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0. Quote your evaluable mapping keys instead.', $keyType)), \E_USER_DEPRECATED); - } - // Convert float keys to strings, to avoid being converted to integers by PHP - if (\is_float($key)) { - $key = (string) $key; - } - if ('<<' === $key && (!isset($values['value']) || !self::preg_match('#^&(?P[^ ]+)#u', $values['value'], $refMatches))) { - $mergeNode = \true; - $allowOverwrite = \true; - if (isset($values['value'][0]) && '*' === $values['value'][0]) { - $refName = \substr(\rtrim($values['value']), 1); - if (!\array_key_exists($refName, $this->refs)) { - if (\false !== ($pos = \array_search($refName, $this->refsBeingParsed, \true))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Circular reference [%s, %s] detected for reference "%s".', \implode(', ', \array_slice($this->refsBeingParsed, $pos)), $refName, $refName), $this->currentLineNb + 1, $this->currentLine, $this->filename); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Reference "%s" does not exist.', $refName), $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); - } - $refValue = $this->refs[$refName]; - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags && $refValue instanceof \stdClass) { - $refValue = (array) $refValue; - } - if (!\is_array($refValue)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('YAML merge keys used with a scalar value instead of an array.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); - } - $data += $refValue; - // array union - } else { - if (isset($values['value']) && '' !== $values['value']) { - $value = $values['value']; - } else { - $value = $this->getNextEmbedBlock(); - } - $parsed = $this->parseBlock($this->getRealCurrentLineNb() + 1, $value, $flags); - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags && $parsed instanceof \stdClass) { - $parsed = (array) $parsed; - } - if (!\is_array($parsed)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('YAML merge keys used with a scalar value instead of an array.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); - } - if (isset($parsed[0])) { - // If the value associated with the merge key is a sequence, then this sequence is expected to contain mapping nodes - // and each of these nodes is merged in turn according to its order in the sequence. Keys in mapping nodes earlier - // in the sequence override keys specified in later mapping nodes. - foreach ($parsed as $parsedItem) { - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags && $parsedItem instanceof \stdClass) { - $parsedItem = (array) $parsedItem; - } - if (!\is_array($parsedItem)) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Merge items must be arrays.', $this->getRealCurrentLineNb() + 1, $parsedItem, $this->filename); - } - $data += $parsedItem; - // array union - } - } else { - // If the value associated with the key is a single mapping node, each of its key/value pairs is inserted into the - // current mapping, unless the key already exists in it. - $data += $parsed; - // array union - } - } - } elseif ('<<' !== $key && isset($values['value']) && self::preg_match('#^&(?P[^ ]++) *+(?P.*)#u', $values['value'], $matches)) { - $isRef = $matches['ref']; - $this->refsBeingParsed[] = $isRef; - $values['value'] = $matches['value']; - } - $subTag = null; - if ($mergeNode) { - // Merge keys - } elseif (!isset($values['value']) || '' === $values['value'] || 0 === \strpos($values['value'], '#') || null !== ($subTag = $this->getLineTag($values['value'], $flags)) || '<<' === $key) { - // hash - // if next line is less indented or equal, then it means that the current value is null - if (!$this->isNextLineIndented() && !$this->isNextLineUnIndentedCollection()) { - // Spec: Keys MUST be unique; first one wins. - // But overwriting is allowed when a merge node is used in current block. - if ($allowOverwrite || !isset($data[$key])) { - if (null !== $subTag) { - $data[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($subTag, ''); - } else { - $data[$key] = null; - } - } else { - @\trigger_error($this->getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); - } - } else { - $value = $this->parseBlock($this->getRealCurrentLineNb() + 1, $this->getNextEmbedBlock(), $flags); - if ('<<' === $key) { - $this->refs[$refMatches['ref']] = $value; - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags && $value instanceof \stdClass) { - $value = (array) $value; - } - $data += $value; - } elseif ($allowOverwrite || !isset($data[$key])) { - // Spec: Keys MUST be unique; first one wins. - // But overwriting is allowed when a merge node is used in current block. - if (null !== $subTag) { - $data[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($subTag, $value); - } else { - $data[$key] = $value; - } - } else { - @\trigger_error($this->getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); - } - } - } else { - $value = $this->parseValue(\rtrim($values['value']), $flags, $context); - // Spec: Keys MUST be unique; first one wins. - // But overwriting is allowed when a merge node is used in current block. - if ($allowOverwrite || !isset($data[$key])) { - $data[$key] = $value; - } else { - @\trigger_error($this->getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); - } - } - if ($isRef) { - $this->refs[$isRef] = $data[$key]; - \array_pop($this->refsBeingParsed); - } - } else { - // multiple documents are not supported - if ('---' === $this->currentLine) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Multiple documents are not supported.', $this->currentLineNb + 1, $this->currentLine, $this->filename); - } - if ($deprecatedUsage = isset($this->currentLine[1]) && '?' === $this->currentLine[0] && ' ' === $this->currentLine[1]) { - @\trigger_error($this->getDeprecationMessage('Starting an unquoted string with a question mark followed by a space is deprecated since Symfony 3.3 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.'), \E_USER_DEPRECATED); - } - // 1-liner optionally followed by newline(s) - if (\is_string($value) && $this->lines[0] === \trim($value)) { - try { - $value = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($this->lines[0], $flags, $this->refs); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { - $e->setParsedLine($this->getRealCurrentLineNb() + 1); - $e->setSnippet($this->currentLine); - throw $e; - } - return $value; - } - // try to parse the value as a multi-line string as a last resort - if (0 === $this->currentLineNb) { - $previousLineWasNewline = \false; - $previousLineWasTerminatedWithBackslash = \false; - $value = ''; - foreach ($this->lines as $line) { - if ('' !== \ltrim($line) && '#' === \ltrim($line)[0]) { - continue; - } - // If the indentation is not consistent at offset 0, it is to be considered as a ParseError - if (0 === $this->offset && !$deprecatedUsage && isset($line[0]) && ' ' === $line[0]) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Unable to parse.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); - } - if ('' === \trim($line)) { - $value .= "\n"; - } elseif (!$previousLineWasNewline && !$previousLineWasTerminatedWithBackslash) { - $value .= ' '; - } - if ('' !== \trim($line) && '\\' === \substr($line, -1)) { - $value .= \ltrim(\substr($line, 0, -1)); - } elseif ('' !== \trim($line)) { - $value .= \trim($line); - } - if ('' === \trim($line)) { - $previousLineWasNewline = \true; - $previousLineWasTerminatedWithBackslash = \false; - } elseif ('\\' === \substr($line, -1)) { - $previousLineWasNewline = \false; - $previousLineWasTerminatedWithBackslash = \true; - } else { - $previousLineWasNewline = \false; - $previousLineWasTerminatedWithBackslash = \false; - } - } - try { - return \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse(\trim($value)); - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { - // fall-through to the ParseException thrown below - } - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Unable to parse.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); - } - } while ($this->moveToNextLine()); - if (null !== $tag) { - $data = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $data); - } - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags && !\is_object($data) && 'mapping' === $context) { - $object = new \stdClass(); - foreach ($data as $key => $value) { - $object->{$key} = $value; - } - $data = $object; - } - return empty($data) ? null : $data; - } - private function parseBlock($offset, $yaml, $flags) - { - $skippedLineNumbers = $this->skippedLineNumbers; - foreach ($this->locallySkippedLineNumbers as $lineNumber) { - if ($lineNumber < $offset) { - continue; - } - $skippedLineNumbers[] = $lineNumber; - } - $parser = new self(); - $parser->offset = $offset; - $parser->totalNumberOfLines = $this->totalNumberOfLines; - $parser->skippedLineNumbers = $skippedLineNumbers; - $parser->refs =& $this->refs; - $parser->refsBeingParsed = $this->refsBeingParsed; - return $parser->doParse($yaml, $flags); - } - /** - * Returns the current line number (takes the offset into account). - * - * @internal - * - * @return int The current line number - */ - public function getRealCurrentLineNb() - { - $realCurrentLineNumber = $this->currentLineNb + $this->offset; - foreach ($this->skippedLineNumbers as $skippedLineNumber) { - if ($skippedLineNumber > $realCurrentLineNumber) { - break; - } - ++$realCurrentLineNumber; - } - return $realCurrentLineNumber; - } - /** - * Returns the current line indentation. - * - * @return int The current line indentation - */ - private function getCurrentLineIndentation() - { - return \strlen($this->currentLine) - \strlen(\ltrim($this->currentLine, ' ')); - } - /** - * Returns the next embed block of YAML. - * - * @param int $indentation The indent level at which the block is to be read, or null for default - * @param bool $inSequence True if the enclosing data structure is a sequence - * - * @return string A YAML string - * - * @throws ParseException When indentation problem are detected - */ - private function getNextEmbedBlock($indentation = null, $inSequence = \false) - { - $oldLineIndentation = $this->getCurrentLineIndentation(); - if (!$this->moveToNextLine()) { - return ''; - } - if (null === $indentation) { - $newIndent = null; - $movements = 0; - do { - $EOF = \false; - // empty and comment-like lines do not influence the indentation depth - if ($this->isCurrentLineEmpty() || $this->isCurrentLineComment()) { - $EOF = !$this->moveToNextLine(); - if (!$EOF) { - ++$movements; - } - } else { - $newIndent = $this->getCurrentLineIndentation(); - } - } while (!$EOF && null === $newIndent); - for ($i = 0; $i < $movements; ++$i) { - $this->moveToPreviousLine(); - } - $unindentedEmbedBlock = $this->isStringUnIndentedCollectionItem(); - if (!$this->isCurrentLineEmpty() && 0 === $newIndent && !$unindentedEmbedBlock) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Indentation problem.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); - } - } else { - $newIndent = $indentation; - } - $data = []; - if ($this->getCurrentLineIndentation() >= $newIndent) { - $data[] = \substr($this->currentLine, $newIndent); - } elseif ($this->isCurrentLineEmpty() || $this->isCurrentLineComment()) { - $data[] = $this->currentLine; - } else { - $this->moveToPreviousLine(); - return ''; - } - if ($inSequence && $oldLineIndentation === $newIndent && isset($data[0][0]) && '-' === $data[0][0]) { - // the previous line contained a dash but no item content, this line is a sequence item with the same indentation - // and therefore no nested list or mapping - $this->moveToPreviousLine(); - return ''; - } - $isItUnindentedCollection = $this->isStringUnIndentedCollectionItem(); - while ($this->moveToNextLine()) { - $indent = $this->getCurrentLineIndentation(); - if ($isItUnindentedCollection && !$this->isCurrentLineEmpty() && !$this->isStringUnIndentedCollectionItem() && $newIndent === $indent) { - $this->moveToPreviousLine(); - break; - } - if ($this->isCurrentLineBlank()) { - $data[] = \substr($this->currentLine, $newIndent); - continue; - } - if ($indent >= $newIndent) { - $data[] = \substr($this->currentLine, $newIndent); - } elseif ($this->isCurrentLineComment()) { - $data[] = $this->currentLine; - } elseif (0 == $indent) { - $this->moveToPreviousLine(); - break; - } else { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Indentation problem.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); - } - } - return \implode("\n", $data); - } - /** - * Moves the parser to the next line. - * - * @return bool - */ - private function moveToNextLine() - { - if ($this->currentLineNb >= \count($this->lines) - 1) { - return \false; - } - $this->currentLine = $this->lines[++$this->currentLineNb]; - return \true; - } - /** - * Moves the parser to the previous line. - * - * @return bool - */ - private function moveToPreviousLine() - { - if ($this->currentLineNb < 1) { - return \false; - } - $this->currentLine = $this->lines[--$this->currentLineNb]; - return \true; - } - /** - * Parses a YAML value. - * - * @param string $value A YAML value - * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior - * @param string $context The parser context (either sequence or mapping) - * - * @return mixed A PHP value - * - * @throws ParseException When reference does not exist - */ - private function parseValue($value, $flags, $context) - { - if (0 === \strpos($value, '*')) { - if (\false !== ($pos = \strpos($value, '#'))) { - $value = \substr($value, 1, $pos - 2); - } else { - $value = \substr($value, 1); - } - if (!\array_key_exists($value, $this->refs)) { - if (\false !== ($pos = \array_search($value, $this->refsBeingParsed, \true))) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Circular reference [%s, %s] detected for reference "%s".', \implode(', ', \array_slice($this->refsBeingParsed, $pos)), $value, $value), $this->currentLineNb + 1, $this->currentLine, $this->filename); - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Reference "%s" does not exist.', $value), $this->currentLineNb + 1, $this->currentLine, $this->filename); - } - return $this->refs[$value]; - } - if (self::preg_match('/^(?:' . self::TAG_PATTERN . ' +)?' . self::BLOCK_SCALAR_HEADER_PATTERN . '$/', $value, $matches)) { - $modifiers = isset($matches['modifiers']) ? $matches['modifiers'] : ''; - $data = $this->parseBlockScalar($matches['separator'], \preg_replace('#\\d+#', '', $modifiers), (int) \abs((int) $modifiers)); - if ('' !== $matches['tag']) { - if ('!!binary' === $matches['tag']) { - return \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::evaluateBinaryScalar($data); - } elseif ('tagged' === $matches['tag']) { - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue(\substr($matches['tag'], 1), $data); - } elseif ('!' !== $matches['tag']) { - @\trigger_error($this->getDeprecationMessage(\sprintf('Using the custom tag "%s" for the value "%s" is deprecated since Symfony 3.3. It will be replaced by an instance of %s in 4.0.', $matches['tag'], $data, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue::class)), \E_USER_DEPRECATED); - } - } - return $data; - } - try { - $quotation = '' !== $value && ('"' === $value[0] || "'" === $value[0]) ? $value[0] : null; - // do not take following lines into account when the current line is a quoted single line value - if (null !== $quotation && self::preg_match('/^' . $quotation . '.*' . $quotation . '(\\s*#.*)?$/', $value)) { - return \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value, $flags, $this->refs); - } - $lines = []; - while ($this->moveToNextLine()) { - // unquoted strings end before the first unindented line - if (null === $quotation && 0 === $this->getCurrentLineIndentation()) { - $this->moveToPreviousLine(); - break; - } - $lines[] = \trim($this->currentLine); - // quoted string values end with a line that is terminated with the quotation character - if ('' !== $this->currentLine && \substr($this->currentLine, -1) === $quotation) { - break; - } - } - for ($i = 0, $linesCount = \count($lines), $previousLineBlank = \false; $i < $linesCount; ++$i) { - if ('' === $lines[$i]) { - $value .= "\n"; - $previousLineBlank = \true; - } elseif ($previousLineBlank) { - $value .= $lines[$i]; - $previousLineBlank = \false; - } else { - $value .= ' ' . $lines[$i]; - $previousLineBlank = \false; - } - } - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::$parsedLineNumber = $this->getRealCurrentLineNb(); - $parsedValue = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value, $flags, $this->refs); - if ('mapping' === $context && \is_string($parsedValue) && '"' !== $value[0] && "'" !== $value[0] && '[' !== $value[0] && '{' !== $value[0] && '!' !== $value[0] && \false !== \strpos($parsedValue, ': ')) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('A colon cannot be used in an unquoted mapping value.', $this->getRealCurrentLineNb() + 1, $value, $this->filename); - } - return $parsedValue; - } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { - $e->setParsedLine($this->getRealCurrentLineNb() + 1); - $e->setSnippet($this->currentLine); - throw $e; - } - } - /** - * Parses a block scalar. - * - * @param string $style The style indicator that was used to begin this block scalar (| or >) - * @param string $chomping The chomping indicator that was used to begin this block scalar (+ or -) - * @param int $indentation The indentation indicator that was used to begin this block scalar - * - * @return string The text value - */ - private function parseBlockScalar($style, $chomping = '', $indentation = 0) - { - $notEOF = $this->moveToNextLine(); - if (!$notEOF) { - return ''; - } - $isCurrentLineBlank = $this->isCurrentLineBlank(); - $blockLines = []; - // leading blank lines are consumed before determining indentation - while ($notEOF && $isCurrentLineBlank) { - // newline only if not EOF - if ($notEOF = $this->moveToNextLine()) { - $blockLines[] = ''; - $isCurrentLineBlank = $this->isCurrentLineBlank(); - } - } - // determine indentation if not specified - if (0 === $indentation) { - if (self::preg_match('/^ +/', $this->currentLine, $matches)) { - $indentation = \strlen($matches[0]); - } - } - if ($indentation > 0) { - $pattern = \sprintf('/^ {%d}(.*)$/', $indentation); - while ($notEOF && ($isCurrentLineBlank || self::preg_match($pattern, $this->currentLine, $matches))) { - if ($isCurrentLineBlank && \strlen($this->currentLine) > $indentation) { - $blockLines[] = \substr($this->currentLine, $indentation); - } elseif ($isCurrentLineBlank) { - $blockLines[] = ''; - } else { - $blockLines[] = $matches[1]; - } - // newline only if not EOF - if ($notEOF = $this->moveToNextLine()) { - $isCurrentLineBlank = $this->isCurrentLineBlank(); - } - } - } elseif ($notEOF) { - $blockLines[] = ''; - } - if ($notEOF) { - $blockLines[] = ''; - $this->moveToPreviousLine(); - } elseif (!$notEOF && !$this->isCurrentLineLastLineInDocument()) { - $blockLines[] = ''; - } - // folded style - if ('>' === $style) { - $text = ''; - $previousLineIndented = \false; - $previousLineBlank = \false; - for ($i = 0, $blockLinesCount = \count($blockLines); $i < $blockLinesCount; ++$i) { - if ('' === $blockLines[$i]) { - $text .= "\n"; - $previousLineIndented = \false; - $previousLineBlank = \true; - } elseif (' ' === $blockLines[$i][0]) { - $text .= "\n" . $blockLines[$i]; - $previousLineIndented = \true; - $previousLineBlank = \false; - } elseif ($previousLineIndented) { - $text .= "\n" . $blockLines[$i]; - $previousLineIndented = \false; - $previousLineBlank = \false; - } elseif ($previousLineBlank || 0 === $i) { - $text .= $blockLines[$i]; - $previousLineIndented = \false; - $previousLineBlank = \false; - } else { - $text .= ' ' . $blockLines[$i]; - $previousLineIndented = \false; - $previousLineBlank = \false; - } - } - } else { - $text = \implode("\n", $blockLines); - } - // deal with trailing newlines - if ('' === $chomping) { - $text = \preg_replace('/\\n+$/', "\n", $text); - } elseif ('-' === $chomping) { - $text = \preg_replace('/\\n+$/', '', $text); - } - return $text; - } - /** - * Returns true if the next line is indented. - * - * @return bool Returns true if the next line is indented, false otherwise - */ - private function isNextLineIndented() - { - $currentIndentation = $this->getCurrentLineIndentation(); - $movements = 0; - do { - $EOF = !$this->moveToNextLine(); - if (!$EOF) { - ++$movements; - } - } while (!$EOF && ($this->isCurrentLineEmpty() || $this->isCurrentLineComment())); - if ($EOF) { - return \false; - } - $ret = $this->getCurrentLineIndentation() > $currentIndentation; - for ($i = 0; $i < $movements; ++$i) { - $this->moveToPreviousLine(); - } - return $ret; - } - /** - * Returns true if the current line is blank or if it is a comment line. - * - * @return bool Returns true if the current line is empty or if it is a comment line, false otherwise - */ - private function isCurrentLineEmpty() - { - return $this->isCurrentLineBlank() || $this->isCurrentLineComment(); - } - /** - * Returns true if the current line is blank. - * - * @return bool Returns true if the current line is blank, false otherwise - */ - private function isCurrentLineBlank() - { - return '' == \trim($this->currentLine, ' '); - } - /** - * Returns true if the current line is a comment line. - * - * @return bool Returns true if the current line is a comment line, false otherwise - */ - private function isCurrentLineComment() - { - //checking explicitly the first char of the trim is faster than loops or strpos - $ltrimmedLine = \ltrim($this->currentLine, ' '); - return '' !== $ltrimmedLine && '#' === $ltrimmedLine[0]; - } - private function isCurrentLineLastLineInDocument() - { - return $this->offset + $this->currentLineNb >= $this->totalNumberOfLines - 1; - } - /** - * Cleanups a YAML string to be parsed. - * - * @param string $value The input YAML string - * - * @return string A cleaned up YAML string - */ - private function cleanup($value) - { - $value = \str_replace(["\r\n", "\r"], "\n", $value); - // strip YAML header - $count = 0; - $value = \preg_replace('#^\\%YAML[: ][\\d\\.]+.*\\n#u', '', $value, -1, $count); - $this->offset += $count; - // remove leading comments - $trimmedValue = \preg_replace('#^(\\#.*?\\n)+#s', '', $value, -1, $count); - if (1 === $count) { - // items have been removed, update the offset - $this->offset += \substr_count($value, "\n") - \substr_count($trimmedValue, "\n"); - $value = $trimmedValue; - } - // remove start of the document marker (---) - $trimmedValue = \preg_replace('#^\\-\\-\\-.*?\\n#s', '', $value, -1, $count); - if (1 === $count) { - // items have been removed, update the offset - $this->offset += \substr_count($value, "\n") - \substr_count($trimmedValue, "\n"); - $value = $trimmedValue; - // remove end of the document marker (...) - $value = \preg_replace('#\\.\\.\\.\\s*$#', '', $value); - } - return $value; - } - /** - * Returns true if the next line starts unindented collection. - * - * @return bool Returns true if the next line starts unindented collection, false otherwise - */ - private function isNextLineUnIndentedCollection() - { - $currentIndentation = $this->getCurrentLineIndentation(); - $movements = 0; - do { - $EOF = !$this->moveToNextLine(); - if (!$EOF) { - ++$movements; - } - } while (!$EOF && ($this->isCurrentLineEmpty() || $this->isCurrentLineComment())); - if ($EOF) { - return \false; - } - $ret = $this->getCurrentLineIndentation() === $currentIndentation && $this->isStringUnIndentedCollectionItem(); - for ($i = 0; $i < $movements; ++$i) { - $this->moveToPreviousLine(); - } - return $ret; - } - /** - * Returns true if the string is un-indented collection item. - * - * @return bool Returns true if the string is un-indented collection item, false otherwise - */ - private function isStringUnIndentedCollectionItem() - { - return '-' === \rtrim($this->currentLine) || 0 === \strpos($this->currentLine, '- '); - } - /** - * A local wrapper for `preg_match` which will throw a ParseException if there - * is an internal error in the PCRE engine. - * - * This avoids us needing to check for "false" every time PCRE is used - * in the YAML engine - * - * @throws ParseException on a PCRE internal error - * - * @see preg_last_error() - * - * @internal - */ - public static function preg_match($pattern, $subject, &$matches = null, $flags = 0, $offset = 0) - { - if (\false === ($ret = \preg_match($pattern, $subject, $matches, $flags, $offset))) { - switch (\preg_last_error()) { - case \PREG_INTERNAL_ERROR: - $error = 'Internal PCRE error.'; - break; - case \PREG_BACKTRACK_LIMIT_ERROR: - $error = 'pcre.backtrack_limit reached.'; - break; - case \PREG_RECURSION_LIMIT_ERROR: - $error = 'pcre.recursion_limit reached.'; - break; - case \PREG_BAD_UTF8_ERROR: - $error = 'Malformed UTF-8 data.'; - break; - case \PREG_BAD_UTF8_OFFSET_ERROR: - $error = 'Offset doesn\'t correspond to the begin of a valid UTF-8 code point.'; - break; - default: - $error = 'Error.'; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException($error); - } - return $ret; - } - /** - * Trim the tag on top of the value. - * - * Prevent values such as `!foo {quz: bar}` to be considered as - * a mapping block. - */ - private function trimTag($value) - { - if ('!' === $value[0]) { - return \ltrim(\substr($value, 1, \strcspn($value, " \r\n", 1)), ' '); - } - return $value; - } - /** - * @return string|null - */ - private function getLineTag($value, $flags, $nextLineCheck = \true) - { - if ('' === $value || '!' !== $value[0] || 1 !== self::preg_match('/^' . self::TAG_PATTERN . ' *( +#.*)?$/', $value, $matches)) { - return null; - } - if ($nextLineCheck && !$this->isNextLineIndented()) { - return null; - } - $tag = \substr($matches['tag'], 1); - // Built-in tags - if ($tag && '!' === $tag[0]) { - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The built-in tag "!%s" is not implemented.', $tag), $this->getRealCurrentLineNb() + 1, $value, $this->filename); - } - if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS & $flags) { - return $tag; - } - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Tags support is not enabled. You must use the flag `Yaml::PARSE_CUSTOM_TAGS` to use "%s".', $matches['tag']), $this->getRealCurrentLineNb() + 1, $value, $this->filename); - } - private function getDeprecationMessage($message) - { - $message = \rtrim($message, '.'); - if (null !== $this->filename) { - $message .= ' in ' . $this->filename; - } - $message .= ' on line ' . ($this->getRealCurrentLineNb() + 1); - return $message . '.'; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; +/** + * Parser parses YAML strings to convert them to PHP arrays. + * + * @author Fabien Potencier + * + * @final since version 3.4 + */ +class Parser +{ + const TAG_PATTERN = '(?P![\\w!.\\/:-]+)'; + const BLOCK_SCALAR_HEADER_PATTERN = '(?P\\||>)(?P\\+|\\-|\\d+|\\+\\d+|\\-\\d+|\\d+\\+|\\d+\\-)?(?P +#.*)?'; + private $filename; + private $offset = 0; + private $totalNumberOfLines; + private $lines = []; + private $currentLineNb = -1; + private $currentLine = ''; + private $refs = []; + private $skippedLineNumbers = []; + private $locallySkippedLineNumbers = []; + private $refsBeingParsed = []; + public function __construct() + { + if (\func_num_args() > 0) { + @\trigger_error(\sprintf('The constructor arguments $offset, $totalNumberOfLines, $skippedLineNumbers of %s are deprecated and will be removed in 4.0', self::class), \E_USER_DEPRECATED); + $this->offset = \func_get_arg(0); + if (\func_num_args() > 1) { + $this->totalNumberOfLines = \func_get_arg(1); + } + if (\func_num_args() > 2) { + $this->skippedLineNumbers = \func_get_arg(2); + } + } + } + /** + * Parses a YAML file into a PHP value. + * + * @param string $filename The path to the YAML file to be parsed + * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior + * + * @return mixed The YAML converted to a PHP value + * + * @throws ParseException If the file could not be read or the YAML is not valid + */ + public function parseFile($filename, $flags = 0) + { + if (!\is_file($filename)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('File "%s" does not exist.', $filename)); + } + if (!\is_readable($filename)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('File "%s" cannot be read.', $filename)); + } + $this->filename = $filename; + try { + return $this->parse(\file_get_contents($filename), $flags); + } finally { + $this->filename = null; + } + } + /** + * Parses a YAML string to a PHP value. + * + * @param string $value A YAML string + * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior + * + * @return mixed A PHP value + * + * @throws ParseException If the YAML is not valid + */ + public function parse($value, $flags = 0) + { + if (\is_bool($flags)) { + @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); + if ($flags) { + $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE; + } else { + $flags = 0; + } + } + if (\func_num_args() >= 3) { + @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_OBJECT flag instead.', \E_USER_DEPRECATED); + if (\func_get_arg(2)) { + $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT; + } + } + if (\func_num_args() >= 4) { + @\trigger_error('Passing a boolean flag to toggle object for map support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_OBJECT_FOR_MAP flag instead.', \E_USER_DEPRECATED); + if (\func_get_arg(3)) { + $flags |= \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP; + } + } + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_KEYS_AS_STRINGS & $flags) { + @\trigger_error('Using the Yaml::PARSE_KEYS_AS_STRINGS flag is deprecated since Symfony 3.4 as it will be removed in 4.0. Quote your keys when they are evaluable instead.', \E_USER_DEPRECATED); + } + if (\false === \preg_match('//u', $value)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('The YAML value does not appear to be valid UTF-8.', -1, null, $this->filename); + } + $this->refs = []; + $mbEncoding = null; + $e = null; + $data = null; + if (2 & (int) \ini_get('mbstring.func_overload')) { + $mbEncoding = \mb_internal_encoding(); + \mb_internal_encoding('UTF-8'); + } + try { + $data = $this->doParse($value, $flags); + } catch (\Exception $e) { + } catch (\Throwable $e) { + } + if (null !== $mbEncoding) { + \mb_internal_encoding($mbEncoding); + } + $this->lines = []; + $this->currentLine = ''; + $this->refs = []; + $this->skippedLineNumbers = []; + $this->locallySkippedLineNumbers = []; + if (null !== $e) { + throw $e; + } + return $data; + } + private function doParse($value, $flags) + { + $this->currentLineNb = -1; + $this->currentLine = ''; + $value = $this->cleanup($value); + $this->lines = \explode("\n", $value); + $this->locallySkippedLineNumbers = []; + if (null === $this->totalNumberOfLines) { + $this->totalNumberOfLines = \count($this->lines); + } + if (!$this->moveToNextLine()) { + return null; + } + $data = []; + $context = null; + $allowOverwrite = \false; + while ($this->isCurrentLineEmpty()) { + if (!$this->moveToNextLine()) { + return null; + } + } + // Resolves the tag and returns if end of the document + if (null !== ($tag = $this->getLineTag($this->currentLine, $flags, \false)) && !$this->moveToNextLine()) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, ''); + } + do { + if ($this->isCurrentLineEmpty()) { + continue; + } + // tab? + if ("\t" === $this->currentLine[0]) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('A YAML file cannot contain tabs as indentation.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); + } + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::initialize($flags, $this->getRealCurrentLineNb(), $this->filename); + $isRef = $mergeNode = \false; + if (self::preg_match('#^\\-((?P\\s+)(?P.+))?$#u', \rtrim($this->currentLine), $values)) { + if ($context && 'mapping' == $context) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('You cannot define a sequence item when in a mapping.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); + } + $context = 'sequence'; + if (isset($values['value']) && self::preg_match('#^&(?P[^ ]+) *(?P.*)#u', $values['value'], $matches)) { + $isRef = $matches['ref']; + $this->refsBeingParsed[] = $isRef; + $values['value'] = $matches['value']; + } + if (isset($values['value'][1]) && '?' === $values['value'][0] && ' ' === $values['value'][1]) { + @\trigger_error($this->getDeprecationMessage('Starting an unquoted string with a question mark followed by a space is deprecated since Symfony 3.3 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.'), \E_USER_DEPRECATED); + } + // array + if (!isset($values['value']) || '' == \trim($values['value'], ' ') || 0 === \strpos(\ltrim($values['value'], ' '), '#')) { + $data[] = $this->parseBlock($this->getRealCurrentLineNb() + 1, $this->getNextEmbedBlock(null, \true), $flags); + } elseif (null !== ($subTag = $this->getLineTag(\ltrim($values['value'], ' '), $flags))) { + $data[] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($subTag, $this->parseBlock($this->getRealCurrentLineNb() + 1, $this->getNextEmbedBlock(null, \true), $flags)); + } else { + if (isset($values['leadspaces']) && self::preg_match('#^(?P' . \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::REGEX_QUOTED_STRING . '|[^ \'"\\{\\[].*?) *\\:(\\s+(?P.+?))?\\s*$#u', $this->trimTag($values['value']), $matches)) { + // this is a compact notation element, add to next block and parse + $block = $values['value']; + if ($this->isNextLineIndented()) { + $block .= "\n" . $this->getNextEmbedBlock($this->getCurrentLineIndentation() + \strlen($values['leadspaces']) + 1); + } + $data[] = $this->parseBlock($this->getRealCurrentLineNb(), $block, $flags); + } else { + $data[] = $this->parseValue($values['value'], $flags, $context); + } + } + if ($isRef) { + $this->refs[$isRef] = \end($data); + \array_pop($this->refsBeingParsed); + } + } elseif (self::preg_match('#^(?P(?:![^\\s]++\\s++)?(?:' . \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::REGEX_QUOTED_STRING . '|(?:!?!php/const:)?[^ \'"\\[\\{!].*?)) *\\:(\\s++(?P.+))?$#u', \rtrim($this->currentLine), $values) && (\false === \strpos($values['key'], ' #') || \in_array($values['key'][0], ['"', "'"]))) { + if ($context && 'sequence' == $context) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('You cannot define a mapping item when in a sequence.', $this->currentLineNb + 1, $this->currentLine, $this->filename); + } + $context = 'mapping'; + try { + $i = 0; + $evaluateKey = !(\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_KEYS_AS_STRINGS & $flags); + // constants in key will be evaluated anyway + if (isset($values['key'][0]) && '!' === $values['key'][0] && \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT & $flags) { + $evaluateKey = \true; + } + $key = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parseScalar($values['key'], 0, null, $i, $evaluateKey); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { + $e->setParsedLine($this->getRealCurrentLineNb() + 1); + $e->setSnippet($this->currentLine); + throw $e; + } + if (!\is_string($key) && !\is_int($key)) { + $keyType = \is_numeric($key) ? 'numeric key' : 'non-string key'; + @\trigger_error($this->getDeprecationMessage(\sprintf('Implicit casting of %s to string is deprecated since Symfony 3.3 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0. Quote your evaluable mapping keys instead.', $keyType)), \E_USER_DEPRECATED); + } + // Convert float keys to strings, to avoid being converted to integers by PHP + if (\is_float($key)) { + $key = (string) $key; + } + if ('<<' === $key && (!isset($values['value']) || !self::preg_match('#^&(?P[^ ]+)#u', $values['value'], $refMatches))) { + $mergeNode = \true; + $allowOverwrite = \true; + if (isset($values['value'][0]) && '*' === $values['value'][0]) { + $refName = \substr(\rtrim($values['value']), 1); + if (!\array_key_exists($refName, $this->refs)) { + if (\false !== ($pos = \array_search($refName, $this->refsBeingParsed, \true))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Circular reference [%s, %s] detected for reference "%s".', \implode(', ', \array_slice($this->refsBeingParsed, $pos)), $refName, $refName), $this->currentLineNb + 1, $this->currentLine, $this->filename); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Reference "%s" does not exist.', $refName), $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); + } + $refValue = $this->refs[$refName]; + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags && $refValue instanceof \stdClass) { + $refValue = (array) $refValue; + } + if (!\is_array($refValue)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('YAML merge keys used with a scalar value instead of an array.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); + } + $data += $refValue; + // array union + } else { + if (isset($values['value']) && '' !== $values['value']) { + $value = $values['value']; + } else { + $value = $this->getNextEmbedBlock(); + } + $parsed = $this->parseBlock($this->getRealCurrentLineNb() + 1, $value, $flags); + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags && $parsed instanceof \stdClass) { + $parsed = (array) $parsed; + } + if (!\is_array($parsed)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('YAML merge keys used with a scalar value instead of an array.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); + } + if (isset($parsed[0])) { + // If the value associated with the merge key is a sequence, then this sequence is expected to contain mapping nodes + // and each of these nodes is merged in turn according to its order in the sequence. Keys in mapping nodes earlier + // in the sequence override keys specified in later mapping nodes. + foreach ($parsed as $parsedItem) { + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags && $parsedItem instanceof \stdClass) { + $parsedItem = (array) $parsedItem; + } + if (!\is_array($parsedItem)) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Merge items must be arrays.', $this->getRealCurrentLineNb() + 1, $parsedItem, $this->filename); + } + $data += $parsedItem; + // array union + } + } else { + // If the value associated with the key is a single mapping node, each of its key/value pairs is inserted into the + // current mapping, unless the key already exists in it. + $data += $parsed; + // array union + } + } + } elseif ('<<' !== $key && isset($values['value']) && self::preg_match('#^&(?P[^ ]++) *+(?P.*)#u', $values['value'], $matches)) { + $isRef = $matches['ref']; + $this->refsBeingParsed[] = $isRef; + $values['value'] = $matches['value']; + } + $subTag = null; + if ($mergeNode) { + // Merge keys + } elseif (!isset($values['value']) || '' === $values['value'] || 0 === \strpos($values['value'], '#') || null !== ($subTag = $this->getLineTag($values['value'], $flags)) || '<<' === $key) { + // hash + // if next line is less indented or equal, then it means that the current value is null + if (!$this->isNextLineIndented() && !$this->isNextLineUnIndentedCollection()) { + // Spec: Keys MUST be unique; first one wins. + // But overwriting is allowed when a merge node is used in current block. + if ($allowOverwrite || !isset($data[$key])) { + if (null !== $subTag) { + $data[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($subTag, ''); + } else { + $data[$key] = null; + } + } else { + @\trigger_error($this->getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); + } + } else { + $value = $this->parseBlock($this->getRealCurrentLineNb() + 1, $this->getNextEmbedBlock(), $flags); + if ('<<' === $key) { + $this->refs[$refMatches['ref']] = $value; + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags && $value instanceof \stdClass) { + $value = (array) $value; + } + $data += $value; + } elseif ($allowOverwrite || !isset($data[$key])) { + // Spec: Keys MUST be unique; first one wins. + // But overwriting is allowed when a merge node is used in current block. + if (null !== $subTag) { + $data[$key] = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($subTag, $value); + } else { + $data[$key] = $value; + } + } else { + @\trigger_error($this->getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); + } + } + } else { + $value = $this->parseValue(\rtrim($values['value']), $flags, $context); + // Spec: Keys MUST be unique; first one wins. + // But overwriting is allowed when a merge node is used in current block. + if ($allowOverwrite || !isset($data[$key])) { + $data[$key] = $value; + } else { + @\trigger_error($this->getDeprecationMessage(\sprintf('Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated since Symfony 3.2 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.', $key)), \E_USER_DEPRECATED); + } + } + if ($isRef) { + $this->refs[$isRef] = $data[$key]; + \array_pop($this->refsBeingParsed); + } + } else { + // multiple documents are not supported + if ('---' === $this->currentLine) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Multiple documents are not supported.', $this->currentLineNb + 1, $this->currentLine, $this->filename); + } + if ($deprecatedUsage = isset($this->currentLine[1]) && '?' === $this->currentLine[0] && ' ' === $this->currentLine[1]) { + @\trigger_error($this->getDeprecationMessage('Starting an unquoted string with a question mark followed by a space is deprecated since Symfony 3.3 and will throw \\Symfony\\Component\\Yaml\\Exception\\ParseException in 4.0.'), \E_USER_DEPRECATED); + } + // 1-liner optionally followed by newline(s) + if (\is_string($value) && $this->lines[0] === \trim($value)) { + try { + $value = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($this->lines[0], $flags, $this->refs); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { + $e->setParsedLine($this->getRealCurrentLineNb() + 1); + $e->setSnippet($this->currentLine); + throw $e; + } + return $value; + } + // try to parse the value as a multi-line string as a last resort + if (0 === $this->currentLineNb) { + $previousLineWasNewline = \false; + $previousLineWasTerminatedWithBackslash = \false; + $value = ''; + foreach ($this->lines as $line) { + if ('' !== \ltrim($line) && '#' === \ltrim($line)[0]) { + continue; + } + // If the indentation is not consistent at offset 0, it is to be considered as a ParseError + if (0 === $this->offset && !$deprecatedUsage && isset($line[0]) && ' ' === $line[0]) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Unable to parse.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); + } + if ('' === \trim($line)) { + $value .= "\n"; + } elseif (!$previousLineWasNewline && !$previousLineWasTerminatedWithBackslash) { + $value .= ' '; + } + if ('' !== \trim($line) && '\\' === \substr($line, -1)) { + $value .= \ltrim(\substr($line, 0, -1)); + } elseif ('' !== \trim($line)) { + $value .= \trim($line); + } + if ('' === \trim($line)) { + $previousLineWasNewline = \true; + $previousLineWasTerminatedWithBackslash = \false; + } elseif ('\\' === \substr($line, -1)) { + $previousLineWasNewline = \false; + $previousLineWasTerminatedWithBackslash = \true; + } else { + $previousLineWasNewline = \false; + $previousLineWasTerminatedWithBackslash = \false; + } + } + try { + return \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse(\trim($value)); + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { + // fall-through to the ParseException thrown below + } + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Unable to parse.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); + } + } while ($this->moveToNextLine()); + if (null !== $tag) { + $data = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue($tag, $data); + } + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP & $flags && !\is_object($data) && 'mapping' === $context) { + $object = new \stdClass(); + foreach ($data as $key => $value) { + $object->{$key} = $value; + } + $data = $object; + } + return empty($data) ? null : $data; + } + private function parseBlock($offset, $yaml, $flags) + { + $skippedLineNumbers = $this->skippedLineNumbers; + foreach ($this->locallySkippedLineNumbers as $lineNumber) { + if ($lineNumber < $offset) { + continue; + } + $skippedLineNumbers[] = $lineNumber; + } + $parser = new self(); + $parser->offset = $offset; + $parser->totalNumberOfLines = $this->totalNumberOfLines; + $parser->skippedLineNumbers = $skippedLineNumbers; + $parser->refs =& $this->refs; + $parser->refsBeingParsed = $this->refsBeingParsed; + return $parser->doParse($yaml, $flags); + } + /** + * Returns the current line number (takes the offset into account). + * + * @internal + * + * @return int The current line number + */ + public function getRealCurrentLineNb() + { + $realCurrentLineNumber = $this->currentLineNb + $this->offset; + foreach ($this->skippedLineNumbers as $skippedLineNumber) { + if ($skippedLineNumber > $realCurrentLineNumber) { + break; + } + ++$realCurrentLineNumber; + } + return $realCurrentLineNumber; + } + /** + * Returns the current line indentation. + * + * @return int The current line indentation + */ + private function getCurrentLineIndentation() + { + return \strlen($this->currentLine) - \strlen(\ltrim($this->currentLine, ' ')); + } + /** + * Returns the next embed block of YAML. + * + * @param int $indentation The indent level at which the block is to be read, or null for default + * @param bool $inSequence True if the enclosing data structure is a sequence + * + * @return string A YAML string + * + * @throws ParseException When indentation problem are detected + */ + private function getNextEmbedBlock($indentation = null, $inSequence = \false) + { + $oldLineIndentation = $this->getCurrentLineIndentation(); + if (!$this->moveToNextLine()) { + return ''; + } + if (null === $indentation) { + $newIndent = null; + $movements = 0; + do { + $EOF = \false; + // empty and comment-like lines do not influence the indentation depth + if ($this->isCurrentLineEmpty() || $this->isCurrentLineComment()) { + $EOF = !$this->moveToNextLine(); + if (!$EOF) { + ++$movements; + } + } else { + $newIndent = $this->getCurrentLineIndentation(); + } + } while (!$EOF && null === $newIndent); + for ($i = 0; $i < $movements; ++$i) { + $this->moveToPreviousLine(); + } + $unindentedEmbedBlock = $this->isStringUnIndentedCollectionItem(); + if (!$this->isCurrentLineEmpty() && 0 === $newIndent && !$unindentedEmbedBlock) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Indentation problem.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); + } + } else { + $newIndent = $indentation; + } + $data = []; + if ($this->getCurrentLineIndentation() >= $newIndent) { + $data[] = \substr($this->currentLine, $newIndent); + } elseif ($this->isCurrentLineEmpty() || $this->isCurrentLineComment()) { + $data[] = $this->currentLine; + } else { + $this->moveToPreviousLine(); + return ''; + } + if ($inSequence && $oldLineIndentation === $newIndent && isset($data[0][0]) && '-' === $data[0][0]) { + // the previous line contained a dash but no item content, this line is a sequence item with the same indentation + // and therefore no nested list or mapping + $this->moveToPreviousLine(); + return ''; + } + $isItUnindentedCollection = $this->isStringUnIndentedCollectionItem(); + while ($this->moveToNextLine()) { + $indent = $this->getCurrentLineIndentation(); + if ($isItUnindentedCollection && !$this->isCurrentLineEmpty() && !$this->isStringUnIndentedCollectionItem() && $newIndent === $indent) { + $this->moveToPreviousLine(); + break; + } + if ($this->isCurrentLineBlank()) { + $data[] = \substr($this->currentLine, $newIndent); + continue; + } + if ($indent >= $newIndent) { + $data[] = \substr($this->currentLine, $newIndent); + } elseif ($this->isCurrentLineComment()) { + $data[] = $this->currentLine; + } elseif (0 == $indent) { + $this->moveToPreviousLine(); + break; + } else { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Indentation problem.', $this->getRealCurrentLineNb() + 1, $this->currentLine, $this->filename); + } + } + return \implode("\n", $data); + } + /** + * Moves the parser to the next line. + * + * @return bool + */ + private function moveToNextLine() + { + if ($this->currentLineNb >= \count($this->lines) - 1) { + return \false; + } + $this->currentLine = $this->lines[++$this->currentLineNb]; + return \true; + } + /** + * Moves the parser to the previous line. + * + * @return bool + */ + private function moveToPreviousLine() + { + if ($this->currentLineNb < 1) { + return \false; + } + $this->currentLine = $this->lines[--$this->currentLineNb]; + return \true; + } + /** + * Parses a YAML value. + * + * @param string $value A YAML value + * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior + * @param string $context The parser context (either sequence or mapping) + * + * @return mixed A PHP value + * + * @throws ParseException When reference does not exist + */ + private function parseValue($value, $flags, $context) + { + if (0 === \strpos($value, '*')) { + if (\false !== ($pos = \strpos($value, '#'))) { + $value = \substr($value, 1, $pos - 2); + } else { + $value = \substr($value, 1); + } + if (!\array_key_exists($value, $this->refs)) { + if (\false !== ($pos = \array_search($value, $this->refsBeingParsed, \true))) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Circular reference [%s, %s] detected for reference "%s".', \implode(', ', \array_slice($this->refsBeingParsed, $pos)), $value, $value), $this->currentLineNb + 1, $this->currentLine, $this->filename); + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Reference "%s" does not exist.', $value), $this->currentLineNb + 1, $this->currentLine, $this->filename); + } + return $this->refs[$value]; + } + if (self::preg_match('/^(?:' . self::TAG_PATTERN . ' +)?' . self::BLOCK_SCALAR_HEADER_PATTERN . '$/', $value, $matches)) { + $modifiers = isset($matches['modifiers']) ? $matches['modifiers'] : ''; + $data = $this->parseBlockScalar($matches['separator'], \preg_replace('#\\d+#', '', $modifiers), (int) \abs((int) $modifiers)); + if ('' !== $matches['tag']) { + if ('!!binary' === $matches['tag']) { + return \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::evaluateBinaryScalar($data); + } elseif ('tagged' === $matches['tag']) { + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue(\substr($matches['tag'], 1), $data); + } elseif ('!' !== $matches['tag']) { + @\trigger_error($this->getDeprecationMessage(\sprintf('Using the custom tag "%s" for the value "%s" is deprecated since Symfony 3.3. It will be replaced by an instance of %s in 4.0.', $matches['tag'], $data, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue::class)), \E_USER_DEPRECATED); + } + } + return $data; + } + try { + $quotation = '' !== $value && ('"' === $value[0] || "'" === $value[0]) ? $value[0] : null; + // do not take following lines into account when the current line is a quoted single line value + if (null !== $quotation && self::preg_match('/^' . $quotation . '.*' . $quotation . '(\\s*#.*)?$/', $value)) { + return \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value, $flags, $this->refs); + } + $lines = []; + while ($this->moveToNextLine()) { + // unquoted strings end before the first unindented line + if (null === $quotation && 0 === $this->getCurrentLineIndentation()) { + $this->moveToPreviousLine(); + break; + } + $lines[] = \trim($this->currentLine); + // quoted string values end with a line that is terminated with the quotation character + if ('' !== $this->currentLine && \substr($this->currentLine, -1) === $quotation) { + break; + } + } + for ($i = 0, $linesCount = \count($lines), $previousLineBlank = \false; $i < $linesCount; ++$i) { + if ('' === $lines[$i]) { + $value .= "\n"; + $previousLineBlank = \true; + } elseif ($previousLineBlank) { + $value .= $lines[$i]; + $previousLineBlank = \false; + } else { + $value .= ' ' . $lines[$i]; + $previousLineBlank = \false; + } + } + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::$parsedLineNumber = $this->getRealCurrentLineNb(); + $parsedValue = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value, $flags, $this->refs); + if ('mapping' === $context && \is_string($parsedValue) && '"' !== $value[0] && "'" !== $value[0] && '[' !== $value[0] && '{' !== $value[0] && '!' !== $value[0] && \false !== \strpos($parsedValue, ': ')) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('A colon cannot be used in an unquoted mapping value.', $this->getRealCurrentLineNb() + 1, $value, $this->filename); + } + return $parsedValue; + } catch (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException $e) { + $e->setParsedLine($this->getRealCurrentLineNb() + 1); + $e->setSnippet($this->currentLine); + throw $e; + } + } + /** + * Parses a block scalar. + * + * @param string $style The style indicator that was used to begin this block scalar (| or >) + * @param string $chomping The chomping indicator that was used to begin this block scalar (+ or -) + * @param int $indentation The indentation indicator that was used to begin this block scalar + * + * @return string The text value + */ + private function parseBlockScalar($style, $chomping = '', $indentation = 0) + { + $notEOF = $this->moveToNextLine(); + if (!$notEOF) { + return ''; + } + $isCurrentLineBlank = $this->isCurrentLineBlank(); + $blockLines = []; + // leading blank lines are consumed before determining indentation + while ($notEOF && $isCurrentLineBlank) { + // newline only if not EOF + if ($notEOF = $this->moveToNextLine()) { + $blockLines[] = ''; + $isCurrentLineBlank = $this->isCurrentLineBlank(); + } + } + // determine indentation if not specified + if (0 === $indentation) { + if (self::preg_match('/^ +/', $this->currentLine, $matches)) { + $indentation = \strlen($matches[0]); + } + } + if ($indentation > 0) { + $pattern = \sprintf('/^ {%d}(.*)$/', $indentation); + while ($notEOF && ($isCurrentLineBlank || self::preg_match($pattern, $this->currentLine, $matches))) { + if ($isCurrentLineBlank && \strlen($this->currentLine) > $indentation) { + $blockLines[] = \substr($this->currentLine, $indentation); + } elseif ($isCurrentLineBlank) { + $blockLines[] = ''; + } else { + $blockLines[] = $matches[1]; + } + // newline only if not EOF + if ($notEOF = $this->moveToNextLine()) { + $isCurrentLineBlank = $this->isCurrentLineBlank(); + } + } + } elseif ($notEOF) { + $blockLines[] = ''; + } + if ($notEOF) { + $blockLines[] = ''; + $this->moveToPreviousLine(); + } elseif (!$notEOF && !$this->isCurrentLineLastLineInDocument()) { + $blockLines[] = ''; + } + // folded style + if ('>' === $style) { + $text = ''; + $previousLineIndented = \false; + $previousLineBlank = \false; + for ($i = 0, $blockLinesCount = \count($blockLines); $i < $blockLinesCount; ++$i) { + if ('' === $blockLines[$i]) { + $text .= "\n"; + $previousLineIndented = \false; + $previousLineBlank = \true; + } elseif (' ' === $blockLines[$i][0]) { + $text .= "\n" . $blockLines[$i]; + $previousLineIndented = \true; + $previousLineBlank = \false; + } elseif ($previousLineIndented) { + $text .= "\n" . $blockLines[$i]; + $previousLineIndented = \false; + $previousLineBlank = \false; + } elseif ($previousLineBlank || 0 === $i) { + $text .= $blockLines[$i]; + $previousLineIndented = \false; + $previousLineBlank = \false; + } else { + $text .= ' ' . $blockLines[$i]; + $previousLineIndented = \false; + $previousLineBlank = \false; + } + } + } else { + $text = \implode("\n", $blockLines); + } + // deal with trailing newlines + if ('' === $chomping) { + $text = \preg_replace('/\\n+$/', "\n", $text); + } elseif ('-' === $chomping) { + $text = \preg_replace('/\\n+$/', '', $text); + } + return $text; + } + /** + * Returns true if the next line is indented. + * + * @return bool Returns true if the next line is indented, false otherwise + */ + private function isNextLineIndented() + { + $currentIndentation = $this->getCurrentLineIndentation(); + $movements = 0; + do { + $EOF = !$this->moveToNextLine(); + if (!$EOF) { + ++$movements; + } + } while (!$EOF && ($this->isCurrentLineEmpty() || $this->isCurrentLineComment())); + if ($EOF) { + return \false; + } + $ret = $this->getCurrentLineIndentation() > $currentIndentation; + for ($i = 0; $i < $movements; ++$i) { + $this->moveToPreviousLine(); + } + return $ret; + } + /** + * Returns true if the current line is blank or if it is a comment line. + * + * @return bool Returns true if the current line is empty or if it is a comment line, false otherwise + */ + private function isCurrentLineEmpty() + { + return $this->isCurrentLineBlank() || $this->isCurrentLineComment(); + } + /** + * Returns true if the current line is blank. + * + * @return bool Returns true if the current line is blank, false otherwise + */ + private function isCurrentLineBlank() + { + return '' == \trim($this->currentLine, ' '); + } + /** + * Returns true if the current line is a comment line. + * + * @return bool Returns true if the current line is a comment line, false otherwise + */ + private function isCurrentLineComment() + { + //checking explicitly the first char of the trim is faster than loops or strpos + $ltrimmedLine = \ltrim($this->currentLine, ' '); + return '' !== $ltrimmedLine && '#' === $ltrimmedLine[0]; + } + private function isCurrentLineLastLineInDocument() + { + return $this->offset + $this->currentLineNb >= $this->totalNumberOfLines - 1; + } + /** + * Cleanups a YAML string to be parsed. + * + * @param string $value The input YAML string + * + * @return string A cleaned up YAML string + */ + private function cleanup($value) + { + $value = \str_replace(["\r\n", "\r"], "\n", $value); + // strip YAML header + $count = 0; + $value = \preg_replace('#^\\%YAML[: ][\\d\\.]+.*\\n#u', '', $value, -1, $count); + $this->offset += $count; + // remove leading comments + $trimmedValue = \preg_replace('#^(\\#.*?\\n)+#s', '', $value, -1, $count); + if (1 === $count) { + // items have been removed, update the offset + $this->offset += \substr_count($value, "\n") - \substr_count($trimmedValue, "\n"); + $value = $trimmedValue; + } + // remove start of the document marker (---) + $trimmedValue = \preg_replace('#^\\-\\-\\-.*?\\n#s', '', $value, -1, $count); + if (1 === $count) { + // items have been removed, update the offset + $this->offset += \substr_count($value, "\n") - \substr_count($trimmedValue, "\n"); + $value = $trimmedValue; + // remove end of the document marker (...) + $value = \preg_replace('#\\.\\.\\.\\s*$#', '', $value); + } + return $value; + } + /** + * Returns true if the next line starts unindented collection. + * + * @return bool Returns true if the next line starts unindented collection, false otherwise + */ + private function isNextLineUnIndentedCollection() + { + $currentIndentation = $this->getCurrentLineIndentation(); + $movements = 0; + do { + $EOF = !$this->moveToNextLine(); + if (!$EOF) { + ++$movements; + } + } while (!$EOF && ($this->isCurrentLineEmpty() || $this->isCurrentLineComment())); + if ($EOF) { + return \false; + } + $ret = $this->getCurrentLineIndentation() === $currentIndentation && $this->isStringUnIndentedCollectionItem(); + for ($i = 0; $i < $movements; ++$i) { + $this->moveToPreviousLine(); + } + return $ret; + } + /** + * Returns true if the string is un-indented collection item. + * + * @return bool Returns true if the string is un-indented collection item, false otherwise + */ + private function isStringUnIndentedCollectionItem() + { + return '-' === \rtrim($this->currentLine) || 0 === \strpos($this->currentLine, '- '); + } + /** + * A local wrapper for `preg_match` which will throw a ParseException if there + * is an internal error in the PCRE engine. + * + * This avoids us needing to check for "false" every time PCRE is used + * in the YAML engine + * + * @throws ParseException on a PCRE internal error + * + * @see preg_last_error() + * + * @internal + */ + public static function preg_match($pattern, $subject, &$matches = null, $flags = 0, $offset = 0) + { + if (\false === ($ret = \preg_match($pattern, $subject, $matches, $flags, $offset))) { + switch (\preg_last_error()) { + case \PREG_INTERNAL_ERROR: + $error = 'Internal PCRE error.'; + break; + case \PREG_BACKTRACK_LIMIT_ERROR: + $error = 'pcre.backtrack_limit reached.'; + break; + case \PREG_RECURSION_LIMIT_ERROR: + $error = 'pcre.recursion_limit reached.'; + break; + case \PREG_BAD_UTF8_ERROR: + $error = 'Malformed UTF-8 data.'; + break; + case \PREG_BAD_UTF8_OFFSET_ERROR: + $error = 'Offset doesn\'t correspond to the begin of a valid UTF-8 code point.'; + break; + default: + $error = 'Error.'; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException($error); + } + return $ret; + } + /** + * Trim the tag on top of the value. + * + * Prevent values such as `!foo {quz: bar}` to be considered as + * a mapping block. + */ + private function trimTag($value) + { + if ('!' === $value[0]) { + return \ltrim(\substr($value, 1, \strcspn($value, " \r\n", 1)), ' '); + } + return $value; + } + /** + * @return string|null + */ + private function getLineTag($value, $flags, $nextLineCheck = \true) + { + if ('' === $value || '!' !== $value[0] || 1 !== self::preg_match('/^' . self::TAG_PATTERN . ' *( +#.*)?$/', $value, $matches)) { + return null; + } + if ($nextLineCheck && !$this->isNextLineIndented()) { + return null; + } + $tag = \substr($matches['tag'], 1); + // Built-in tags + if ($tag && '!' === $tag[0]) { + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('The built-in tag "!%s" is not implemented.', $tag), $this->getRealCurrentLineNb() + 1, $value, $this->filename); + } + if (\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS & $flags) { + return $tag; + } + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Tags support is not enabled. You must use the flag `Yaml::PARSE_CUSTOM_TAGS` to use "%s".', $matches['tag']), $this->getRealCurrentLineNb() + 1, $value, $this->filename); + } + private function getDeprecationMessage($message) + { + $message = \rtrim($message, '.'); + if (null !== $this->filename) { + $message .= ' in ' . $this->filename; + } + $message .= ' on line ' . ($this->getRealCurrentLineNb() + 1); + return $message . '.'; + } +} diff --git a/vendor/symfony/yaml/README.md b/vendor/symfony/yaml/README.md index b914e7836..9404ac84f 100644 --- a/vendor/symfony/yaml/README.md +++ b/vendor/symfony/yaml/README.md @@ -1,13 +1,13 @@ -Yaml Component -============== - -The Yaml component loads and dumps YAML files. - -Resources ---------- - - * [Documentation](https://symfony.com/doc/current/components/yaml.html) - * [Contributing](https://symfony.com/doc/current/contributing/index.html) - * [Report issues](https://github.com/symfony/symfony/issues) and - [send Pull Requests](https://github.com/symfony/symfony/pulls) - in the [main Symfony repository](https://github.com/symfony/symfony) +Yaml Component +============== + +The Yaml component loads and dumps YAML files. + +Resources +--------- + + * [Documentation](https://symfony.com/doc/current/components/yaml.html) + * [Contributing](https://symfony.com/doc/current/contributing/index.html) + * [Report issues](https://github.com/symfony/symfony/issues) and + [send Pull Requests](https://github.com/symfony/symfony/pulls) + in the [main Symfony repository](https://github.com/symfony/symfony) diff --git a/vendor/symfony/yaml/Tag/TaggedValue.php b/vendor/symfony/yaml/Tag/TaggedValue.php index 11a71e257..c6e07c4a1 100644 --- a/vendor/symfony/yaml/Tag/TaggedValue.php +++ b/vendor/symfony/yaml/Tag/TaggedValue.php @@ -1,44 +1,44 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag; - -/** - * @author Nicolas Grekas - * @author Guilhem N. - */ -final class TaggedValue -{ - private $tag; - private $value; - /** - * @param string $tag - * @param mixed $value - */ - public function __construct($tag, $value) - { - $this->tag = $tag; - $this->value = $value; - } - /** - * @return string - */ - public function getTag() - { - return $this->tag; - } - /** - * @return mixed - */ - public function getValue() - { - return $this->value; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag; + +/** + * @author Nicolas Grekas + * @author Guilhem N. + */ +final class TaggedValue +{ + private $tag; + private $value; + /** + * @param string $tag + * @param mixed $value + */ + public function __construct($tag, $value) + { + $this->tag = $tag; + $this->value = $value; + } + /** + * @return string + */ + public function getTag() + { + return $this->tag; + } + /** + * @return mixed + */ + public function getValue() + { + return $this->value; + } +} diff --git a/vendor/symfony/yaml/Tag/index.php b/vendor/symfony/yaml/Tag/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/yaml/Tag/index.php +++ b/vendor/symfony/yaml/Tag/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Tests/Command/LintCommandTest.php b/vendor/symfony/yaml/Tests/Command/LintCommandTest.php index f4464cb8a..c8d08a748 100644 --- a/vendor/symfony/yaml/Tests/Command/LintCommandTest.php +++ b/vendor/symfony/yaml/Tests/Command/LintCommandTest.php @@ -1,115 +1,115 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\Command; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Application; -use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface; -use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Tester\CommandTester; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Command\LintCommand; -/** - * Tests the YamlLintCommand. - * - * @author Robin Chalas - */ -class LintCommandTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - private $files; - public function testLintCorrectFile() - { - $tester = $this->createCommandTester(); - $filename = $this->createFile('foo: bar'); - $ret = $tester->execute(['filename' => $filename], ['verbosity' => \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface::VERBOSITY_VERBOSE, 'decorated' => \false]); - $this->assertEquals(0, $ret, 'Returns 0 in case of success'); - $this->assertRegExp('/^\\/\\/ OK in /', \trim($tester->getDisplay())); - } - public function testLintIncorrectFile() - { - $incorrectContent = ' -foo: -bar'; - $tester = $this->createCommandTester(); - $filename = $this->createFile($incorrectContent); - $ret = $tester->execute(['filename' => $filename], ['decorated' => \false]); - $this->assertEquals(1, $ret, 'Returns 1 in case of error'); - $this->assertStringContainsString('Unable to parse at line 3 (near "bar").', \trim($tester->getDisplay())); - } - public function testConstantAsKey() - { - $yaml = <<createCommandTester()->execute(['filename' => $this->createFile($yaml)], ['verbosity' => \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface::VERBOSITY_VERBOSE, 'decorated' => \false]); - $this->assertSame(0, $ret, 'lint:yaml exits with code 0 in case of success'); - } - public function testCustomTags() - { - $yaml = <<createCommandTester()->execute(['filename' => $this->createFile($yaml), '--parse-tags' => \true], ['verbosity' => \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface::VERBOSITY_VERBOSE, 'decorated' => \false]); - $this->assertSame(0, $ret, 'lint:yaml exits with code 0 in case of success'); - } - public function testCustomTagsError() - { - $yaml = <<createCommandTester()->execute(['filename' => $this->createFile($yaml)], ['verbosity' => \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface::VERBOSITY_VERBOSE, 'decorated' => \false]); - $this->assertSame(1, $ret, 'lint:yaml exits with code 1 in case of error'); - } - public function testLintFileNotReadable() - { - $this->expectException('RuntimeException'); - $tester = $this->createCommandTester(); - $filename = $this->createFile(''); - \unlink($filename); - $tester->execute(['filename' => $filename], ['decorated' => \false]); - } - /** - * @return string Path to the new file - */ - private function createFile($content) - { - $filename = \tempnam(\sys_get_temp_dir() . '/framework-yml-lint-test', 'sf-'); - \file_put_contents($filename, $content); - $this->files[] = $filename; - return $filename; - } - /** - * @return CommandTester - */ - protected function createCommandTester() - { - $application = new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Application(); - $application->add(new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Command\LintCommand()); - $command = $application->find('lint:yaml'); - return new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Tester\CommandTester($command); - } - protected function setUp() - { - $this->files = []; - @\mkdir(\sys_get_temp_dir() . '/framework-yml-lint-test'); - } - protected function tearDown() - { - foreach ($this->files as $file) { - if (\file_exists($file)) { - \unlink($file); - } - } - \rmdir(\sys_get_temp_dir() . '/framework-yml-lint-test'); - } -} -class Foo -{ - const TEST = 'foo'; -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\Command; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Application; +use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface; +use _PhpScoper5ea00cc67502b\Symfony\Component\Console\Tester\CommandTester; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Command\LintCommand; +/** + * Tests the YamlLintCommand. + * + * @author Robin Chalas + */ +class LintCommandTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + private $files; + public function testLintCorrectFile() + { + $tester = $this->createCommandTester(); + $filename = $this->createFile('foo: bar'); + $ret = $tester->execute(['filename' => $filename], ['verbosity' => \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface::VERBOSITY_VERBOSE, 'decorated' => \false]); + $this->assertEquals(0, $ret, 'Returns 0 in case of success'); + $this->assertRegExp('/^\\/\\/ OK in /', \trim($tester->getDisplay())); + } + public function testLintIncorrectFile() + { + $incorrectContent = ' +foo: +bar'; + $tester = $this->createCommandTester(); + $filename = $this->createFile($incorrectContent); + $ret = $tester->execute(['filename' => $filename], ['decorated' => \false]); + $this->assertEquals(1, $ret, 'Returns 1 in case of error'); + $this->assertStringContainsString('Unable to parse at line 3 (near "bar").', \trim($tester->getDisplay())); + } + public function testConstantAsKey() + { + $yaml = <<createCommandTester()->execute(['filename' => $this->createFile($yaml)], ['verbosity' => \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface::VERBOSITY_VERBOSE, 'decorated' => \false]); + $this->assertSame(0, $ret, 'lint:yaml exits with code 0 in case of success'); + } + public function testCustomTags() + { + $yaml = <<createCommandTester()->execute(['filename' => $this->createFile($yaml), '--parse-tags' => \true], ['verbosity' => \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface::VERBOSITY_VERBOSE, 'decorated' => \false]); + $this->assertSame(0, $ret, 'lint:yaml exits with code 0 in case of success'); + } + public function testCustomTagsError() + { + $yaml = <<createCommandTester()->execute(['filename' => $this->createFile($yaml)], ['verbosity' => \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Output\OutputInterface::VERBOSITY_VERBOSE, 'decorated' => \false]); + $this->assertSame(1, $ret, 'lint:yaml exits with code 1 in case of error'); + } + public function testLintFileNotReadable() + { + $this->expectException('RuntimeException'); + $tester = $this->createCommandTester(); + $filename = $this->createFile(''); + \unlink($filename); + $tester->execute(['filename' => $filename], ['decorated' => \false]); + } + /** + * @return string Path to the new file + */ + private function createFile($content) + { + $filename = \tempnam(\sys_get_temp_dir() . '/framework-yml-lint-test', 'sf-'); + \file_put_contents($filename, $content); + $this->files[] = $filename; + return $filename; + } + /** + * @return CommandTester + */ + protected function createCommandTester() + { + $application = new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Application(); + $application->add(new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Command\LintCommand()); + $command = $application->find('lint:yaml'); + return new \_PhpScoper5ea00cc67502b\Symfony\Component\Console\Tester\CommandTester($command); + } + protected function setUp() + { + $this->files = []; + @\mkdir(\sys_get_temp_dir() . '/framework-yml-lint-test'); + } + protected function tearDown() + { + foreach ($this->files as $file) { + if (\file_exists($file)) { + \unlink($file); + } + } + \rmdir(\sys_get_temp_dir() . '/framework-yml-lint-test'); + } +} +class Foo +{ + const TEST = 'foo'; +} diff --git a/vendor/symfony/yaml/Tests/Command/index.php b/vendor/symfony/yaml/Tests/Command/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/yaml/Tests/Command/index.php +++ b/vendor/symfony/yaml/Tests/Command/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Tests/DumperTest.php b/vendor/symfony/yaml/Tests/DumperTest.php index 4abb432f6..eb8ce5f81 100644 --- a/vendor/symfony/yaml/Tests/DumperTest.php +++ b/vendor/symfony/yaml/Tests/DumperTest.php @@ -1,481 +1,481 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; -class DumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected $parser; - protected $dumper; - protected $path; - protected $array = ['' => 'bar', 'foo' => '#bar', 'foo\'bar' => [], 'bar' => [1, 'foo'], 'foobar' => ['foo' => 'bar', 'bar' => [1, 'foo'], 'foobar' => ['foo' => 'bar', 'bar' => [1, 'foo']]]]; - protected function setUp() - { - $this->parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); - $this->dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper(); - $this->path = __DIR__ . '/Fixtures'; - } - protected function tearDown() - { - $this->parser = null; - $this->dumper = null; - $this->path = null; - $this->array = null; - } - public function testIndentationInConstructor() - { - $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper(7); - $expected = <<<'EOF' -'': bar -foo: '#bar' -'foo''bar': { } -bar: - - 1 - - foo -foobar: - foo: bar - bar: - - 1 - - foo - foobar: - foo: bar - bar: - - 1 - - foo - -EOF; - $this->assertEquals($expected, $dumper->dump($this->array, 4, 0)); - } - /** - * @group legacy - */ - public function testSetIndentation() - { - $this->dumper->setIndentation(7); - $expected = <<<'EOF' -'': bar -foo: '#bar' -'foo''bar': { } -bar: - - 1 - - foo -foobar: - foo: bar - bar: - - 1 - - foo - foobar: - foo: bar - bar: - - 1 - - foo - -EOF; - $this->assertEquals($expected, $this->dumper->dump($this->array, 4, 0)); - } - public function testSpecifications() - { - $files = $this->parser->parse(\file_get_contents($this->path . '/index.yml')); - foreach ($files as $file) { - $yamls = \file_get_contents($this->path . '/' . $file . '.yml'); - // split YAMLs documents - foreach (\preg_split('/^---( %YAML\\:1\\.0)?/m', $yamls) as $yaml) { - if (!$yaml) { - continue; - } - $test = $this->parser->parse($yaml); - if (isset($test['dump_skip']) && $test['dump_skip']) { - continue; - } elseif (isset($test['todo']) && $test['todo']) { - // TODO - } else { - eval('$expected = ' . \trim($test['php']) . ';'); - $this->assertSame($expected, $this->parser->parse($this->dumper->dump($expected, 10)), $test['test']); - } - } - } - } - public function testInlineLevel() - { - $expected = <<<'EOF' -{ '': bar, foo: '#bar', 'foo''bar': { }, bar: [1, foo], foobar: { foo: bar, bar: [1, foo], foobar: { foo: bar, bar: [1, foo] } } } -EOF; - $this->assertEquals($expected, $this->dumper->dump($this->array, -10), '->dump() takes an inline level argument'); - $this->assertEquals($expected, $this->dumper->dump($this->array, 0), '->dump() takes an inline level argument'); - $expected = <<<'EOF' -'': bar -foo: '#bar' -'foo''bar': { } -bar: [1, foo] -foobar: { foo: bar, bar: [1, foo], foobar: { foo: bar, bar: [1, foo] } } - -EOF; - $this->assertEquals($expected, $this->dumper->dump($this->array, 1), '->dump() takes an inline level argument'); - $expected = <<<'EOF' -'': bar -foo: '#bar' -'foo''bar': { } -bar: - - 1 - - foo -foobar: - foo: bar - bar: [1, foo] - foobar: { foo: bar, bar: [1, foo] } - -EOF; - $this->assertEquals($expected, $this->dumper->dump($this->array, 2), '->dump() takes an inline level argument'); - $expected = <<<'EOF' -'': bar -foo: '#bar' -'foo''bar': { } -bar: - - 1 - - foo -foobar: - foo: bar - bar: - - 1 - - foo - foobar: - foo: bar - bar: [1, foo] - -EOF; - $this->assertEquals($expected, $this->dumper->dump($this->array, 3), '->dump() takes an inline level argument'); - $expected = <<<'EOF' -'': bar -foo: '#bar' -'foo''bar': { } -bar: - - 1 - - foo -foobar: - foo: bar - bar: - - 1 - - foo - foobar: - foo: bar - bar: - - 1 - - foo - -EOF; - $this->assertEquals($expected, $this->dumper->dump($this->array, 4), '->dump() takes an inline level argument'); - $this->assertEquals($expected, $this->dumper->dump($this->array, 10), '->dump() takes an inline level argument'); - } - public function testObjectSupportEnabled() - { - $dump = $this->dumper->dump(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(), 'bar' => 1], 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT); - $this->assertEquals('{ foo: !php/object \'O:30:"Symfony\\Component\\Yaml\\Tests\\A":1:{s:1:"a";s:3:"foo";}\', bar: 1 }', $dump, '->dump() is able to dump objects'); - } - /** - * @group legacy - */ - public function testObjectSupportEnabledPassingTrue() - { - $dump = $this->dumper->dump(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(), 'bar' => 1], 0, 0, \false, \true); - $this->assertEquals('{ foo: !php/object \'O:30:"Symfony\\Component\\Yaml\\Tests\\A":1:{s:1:"a";s:3:"foo";}\', bar: 1 }', $dump, '->dump() is able to dump objects'); - } - public function testObjectSupportDisabledButNoExceptions() - { - $dump = $this->dumper->dump(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(), 'bar' => 1]); - $this->assertEquals('{ foo: null, bar: 1 }', $dump, '->dump() does not dump objects when disabled'); - } - public function testObjectSupportDisabledWithExceptions() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\DumpException'); - $this->dumper->dump(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(), 'bar' => 1], 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE); - } - /** - * @group legacy - */ - public function testObjectSupportDisabledWithExceptionsPassingTrue() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\DumpException'); - $this->dumper->dump(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(), 'bar' => 1], 0, 0, \true); - } - public function testEmptyArray() - { - $dump = $this->dumper->dump([]); - $this->assertEquals('{ }', $dump); - $dump = $this->dumper->dump([], 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE); - $this->assertEquals('[]', $dump); - $dump = $this->dumper->dump([], 9, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE); - $this->assertEquals('[]', $dump); - $dump = $this->dumper->dump(new \ArrayObject(), 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE | \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); - $this->assertEquals('{ }', $dump); - $dump = $this->dumper->dump(new \stdClass(), 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE | \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); - $this->assertEquals('{ }', $dump); - } - /** - * @dataProvider getEscapeSequences - */ - public function testEscapedEscapeSequencesInQuotedScalar($input, $expected) - { - $this->assertEquals($expected, $this->dumper->dump($input)); - } - public function getEscapeSequences() - { - return ['empty string' => ['', "''"], 'null' => ["\0", '"\\0"'], 'bell' => ["\7", '"\\a"'], 'backspace' => ["\10", '"\\b"'], 'horizontal-tab' => ["\t", '"\\t"'], 'line-feed' => ["\n", '"\\n"'], 'vertical-tab' => ["\v", '"\\v"'], 'form-feed' => ["\f", '"\\f"'], 'carriage-return' => ["\r", '"\\r"'], 'escape' => ["\33", '"\\e"'], 'space' => [' ', "' '"], 'double-quote' => ['"', "'\"'"], 'slash' => ['/', '/'], 'backslash' => ['\\', '\\'], 'next-line' => ["Â…", '"\\N"'], 'non-breaking-space' => [" ", '"\\_"'], 'line-separator' => ["
", '"\\L"'], 'paragraph-separator' => ["
", '"\\P"'], 'colon' => [':', "':'"]]; - } - public function testBinaryDataIsDumpedBase64Encoded() - { - $binaryData = \file_get_contents(__DIR__ . '/Fixtures/arrow.gif'); - $expected = '{ data: !!binary ' . \base64_encode($binaryData) . ' }'; - $this->assertSame($expected, $this->dumper->dump(['data' => $binaryData])); - } - public function testNonUtf8DataIsDumpedBase64Encoded() - { - // "für" (ISO-8859-1 encoded) - $this->assertSame('!!binary ZsM/cg==', $this->dumper->dump("fÃ?r")); - } - /** - * @dataProvider objectAsMapProvider - */ - public function testDumpObjectAsMap($object, $expected) - { - $yaml = $this->dumper->dump($object, 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); - $this->assertEquals($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP)); - } - public function objectAsMapProvider() - { - $tests = []; - $bar = new \stdClass(); - $bar->class = 'classBar'; - $bar->args = ['bar']; - $zar = new \stdClass(); - $foo = new \stdClass(); - $foo->bar = $bar; - $foo->zar = $zar; - $object = new \stdClass(); - $object->foo = $foo; - $tests['stdClass'] = [$object, $object]; - $arrayObject = new \ArrayObject(); - $arrayObject['foo'] = 'bar'; - $arrayObject['baz'] = 'foobar'; - $parsedArrayObject = new \stdClass(); - $parsedArrayObject->foo = 'bar'; - $parsedArrayObject->baz = 'foobar'; - $tests['ArrayObject'] = [$arrayObject, $parsedArrayObject]; - $a = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(); - $tests['arbitrary-object'] = [$a, null]; - return $tests; - } - public function testDumpingArrayObjectInstancesRespectsInlineLevel() - { - $deep = new \ArrayObject(['deep1' => 'd', 'deep2' => 'e']); - $inner = new \ArrayObject(['inner1' => 'b', 'inner2' => 'c', 'inner3' => $deep]); - $outer = new \ArrayObject(['outer1' => 'a', 'outer2' => $inner]); - $yaml = $this->dumper->dump($outer, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); - $expected = <<assertSame($expected, $yaml); - } - public function testDumpingArrayObjectInstancesWithNumericKeysInlined() - { - $deep = new \ArrayObject(['d', 'e']); - $inner = new \ArrayObject(['b', 'c', $deep]); - $outer = new \ArrayObject(['a', $inner]); - $yaml = $this->dumper->dump($outer, 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); - $expected = <<assertSame($expected, $yaml); - } - public function testDumpingArrayObjectInstancesWithNumericKeysRespectsInlineLevel() - { - $deep = new \ArrayObject(['d', 'e']); - $inner = new \ArrayObject(['b', 'c', $deep]); - $outer = new \ArrayObject(['a', $inner]); - $yaml = $this->dumper->dump($outer, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); - $expected = <<assertEquals($expected, $yaml); - } - public function testDumpEmptyArrayObjectInstanceAsMap() - { - $this->assertSame('{ }', $this->dumper->dump(new \ArrayObject(), 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP)); - } - public function testDumpEmptyStdClassInstanceAsMap() - { - $this->assertSame('{ }', $this->dumper->dump(new \stdClass(), 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP)); - } - public function testDumpingStdClassInstancesRespectsInlineLevel() - { - $deep = new \stdClass(); - $deep->deep1 = 'd'; - $deep->deep2 = 'e'; - $inner = new \stdClass(); - $inner->inner1 = 'b'; - $inner->inner2 = 'c'; - $inner->inner3 = $deep; - $outer = new \stdClass(); - $outer->outer1 = 'a'; - $outer->outer2 = $inner; - $yaml = $this->dumper->dump($outer, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); - $expected = <<assertSame($expected, $yaml); - } - public function testDumpingTaggedValueSequenceRespectsInlineLevel() - { - $data = [new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'jane']), new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'john'])]; - $yaml = $this->dumper->dump($data, 2); - $expected = <<assertSame($expected, $yaml); - } - public function testDumpingTaggedValueSequenceWithInlinedTagValues() - { - $data = [new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'jane']), new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'john'])]; - $yaml = $this->dumper->dump($data, 1); - $expected = <<assertSame($expected, $yaml); - } - public function testDumpingTaggedValueMapRespectsInlineLevel() - { - $data = ['user1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'jane']), 'user2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'john'])]; - $yaml = $this->dumper->dump($data, 2); - $expected = <<assertSame($expected, $yaml); - } - public function testDumpingTaggedValueMapWithInlinedTagValues() - { - $data = ['user1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'jane']), 'user2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'john'])]; - $yaml = $this->dumper->dump($data, 1); - $expected = <<assertSame($expected, $yaml); - } - public function testDumpingNotInlinedScalarTaggedValue() - { - $data = ['user1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', 'jane'), 'user2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', 'john')]; - $expected = <<assertSame($expected, $this->dumper->dump($data, 2)); - } - public function testDumpingNotInlinedNullTaggedValue() - { - $data = ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('bar', null)]; - $expected = <<assertSame($expected, $this->dumper->dump($data, 2)); - } - public function testDumpingMultiLineStringAsScalarBlockTaggedValue() - { - $data = ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('bar', "foo\nline with trailing spaces:\n \nbar\ninteger like line:\n123456789\nempty line:\n\nbaz")]; - $expected = <<assertSame($expected, $this->dumper->dump($data, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); - } - public function testDumpingInlinedMultiLineIfRnBreakLineInTaggedValue() - { - $data = ['data' => ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('bar', "foo\r\nline with trailing spaces:\n \nbar\ninteger like line:\n123456789\nempty line:\n\nbaz")]]; - $this->assertSame(\file_get_contents(__DIR__ . '/Fixtures/multiple_lines_as_literal_block_for_tagged_values.yml'), $this->dumper->dump($data, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); - } - public function testDumpMultiLineStringAsScalarBlock() - { - $data = ['data' => ['single_line' => 'foo bar baz', 'multi_line' => "foo\nline with trailing spaces:\n \nbar\ninteger like line:\n123456789\nempty line:\n\nbaz", 'multi_line_with_carriage_return' => "foo\nbar\r\nbaz", 'nested_inlined_multi_line_string' => ['inlined_multi_line' => "foo\nbar\r\nempty line:\n\nbaz"]]]; - $this->assertSame(\file_get_contents(__DIR__ . '/Fixtures/multiple_lines_as_literal_block.yml'), $this->dumper->dump($data, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); - } - public function testDumpMultiLineStringAsScalarBlockWhenFirstLineHasLeadingSpace() - { - $data = ['data' => ['multi_line' => " the first line has leading spaces\nThe second line does not."]]; - $this->assertSame(\file_get_contents(__DIR__ . '/Fixtures/multiple_lines_as_literal_block_leading_space_in_first_line.yml'), $this->dumper->dump($data, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); - } - public function testCarriageReturnFollowedByNewlineIsMaintainedWhenDumpingAsMultiLineLiteralBlock() - { - $this->assertSame("- \"a\\r\\nb\\nc\"\n", $this->dumper->dump(["a\r\nb\nc"], 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); - } - public function testCarriageReturnNotFollowedByNewlineIsPreservedWhenDumpingAsMultiLineLiteralBlock() - { - $expected = <<<'YAML' -parent: - foo: "bar\n\rbaz: qux" - -YAML; - $this->assertSame($expected, $this->dumper->dump(['parent' => ['foo' => "bar\n\rbaz: qux"]], 4, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); - } - public function testZeroIndentationThrowsException() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('The indentation must be greater than zero'); - new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper(0); - } - public function testNegativeIndentationThrowsException() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('The indentation must be greater than zero'); - new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper(-4); - } -} -class A -{ - public $a = 'foo'; -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; +class DumperTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected $parser; + protected $dumper; + protected $path; + protected $array = ['' => 'bar', 'foo' => '#bar', 'foo\'bar' => [], 'bar' => [1, 'foo'], 'foobar' => ['foo' => 'bar', 'bar' => [1, 'foo'], 'foobar' => ['foo' => 'bar', 'bar' => [1, 'foo']]]]; + protected function setUp() + { + $this->parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); + $this->dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper(); + $this->path = __DIR__ . '/Fixtures'; + } + protected function tearDown() + { + $this->parser = null; + $this->dumper = null; + $this->path = null; + $this->array = null; + } + public function testIndentationInConstructor() + { + $dumper = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper(7); + $expected = <<<'EOF' +'': bar +foo: '#bar' +'foo''bar': { } +bar: + - 1 + - foo +foobar: + foo: bar + bar: + - 1 + - foo + foobar: + foo: bar + bar: + - 1 + - foo + +EOF; + $this->assertEquals($expected, $dumper->dump($this->array, 4, 0)); + } + /** + * @group legacy + */ + public function testSetIndentation() + { + $this->dumper->setIndentation(7); + $expected = <<<'EOF' +'': bar +foo: '#bar' +'foo''bar': { } +bar: + - 1 + - foo +foobar: + foo: bar + bar: + - 1 + - foo + foobar: + foo: bar + bar: + - 1 + - foo + +EOF; + $this->assertEquals($expected, $this->dumper->dump($this->array, 4, 0)); + } + public function testSpecifications() + { + $files = $this->parser->parse(\file_get_contents($this->path . '/index.yml')); + foreach ($files as $file) { + $yamls = \file_get_contents($this->path . '/' . $file . '.yml'); + // split YAMLs documents + foreach (\preg_split('/^---( %YAML\\:1\\.0)?/m', $yamls) as $yaml) { + if (!$yaml) { + continue; + } + $test = $this->parser->parse($yaml); + if (isset($test['dump_skip']) && $test['dump_skip']) { + continue; + } elseif (isset($test['todo']) && $test['todo']) { + // TODO + } else { + eval('$expected = ' . \trim($test['php']) . ';'); + $this->assertSame($expected, $this->parser->parse($this->dumper->dump($expected, 10)), $test['test']); + } + } + } + } + public function testInlineLevel() + { + $expected = <<<'EOF' +{ '': bar, foo: '#bar', 'foo''bar': { }, bar: [1, foo], foobar: { foo: bar, bar: [1, foo], foobar: { foo: bar, bar: [1, foo] } } } +EOF; + $this->assertEquals($expected, $this->dumper->dump($this->array, -10), '->dump() takes an inline level argument'); + $this->assertEquals($expected, $this->dumper->dump($this->array, 0), '->dump() takes an inline level argument'); + $expected = <<<'EOF' +'': bar +foo: '#bar' +'foo''bar': { } +bar: [1, foo] +foobar: { foo: bar, bar: [1, foo], foobar: { foo: bar, bar: [1, foo] } } + +EOF; + $this->assertEquals($expected, $this->dumper->dump($this->array, 1), '->dump() takes an inline level argument'); + $expected = <<<'EOF' +'': bar +foo: '#bar' +'foo''bar': { } +bar: + - 1 + - foo +foobar: + foo: bar + bar: [1, foo] + foobar: { foo: bar, bar: [1, foo] } + +EOF; + $this->assertEquals($expected, $this->dumper->dump($this->array, 2), '->dump() takes an inline level argument'); + $expected = <<<'EOF' +'': bar +foo: '#bar' +'foo''bar': { } +bar: + - 1 + - foo +foobar: + foo: bar + bar: + - 1 + - foo + foobar: + foo: bar + bar: [1, foo] + +EOF; + $this->assertEquals($expected, $this->dumper->dump($this->array, 3), '->dump() takes an inline level argument'); + $expected = <<<'EOF' +'': bar +foo: '#bar' +'foo''bar': { } +bar: + - 1 + - foo +foobar: + foo: bar + bar: + - 1 + - foo + foobar: + foo: bar + bar: + - 1 + - foo + +EOF; + $this->assertEquals($expected, $this->dumper->dump($this->array, 4), '->dump() takes an inline level argument'); + $this->assertEquals($expected, $this->dumper->dump($this->array, 10), '->dump() takes an inline level argument'); + } + public function testObjectSupportEnabled() + { + $dump = $this->dumper->dump(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(), 'bar' => 1], 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT); + $this->assertEquals('{ foo: !php/object \'O:30:"Symfony\\Component\\Yaml\\Tests\\A":1:{s:1:"a";s:3:"foo";}\', bar: 1 }', $dump, '->dump() is able to dump objects'); + } + /** + * @group legacy + */ + public function testObjectSupportEnabledPassingTrue() + { + $dump = $this->dumper->dump(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(), 'bar' => 1], 0, 0, \false, \true); + $this->assertEquals('{ foo: !php/object \'O:30:"Symfony\\Component\\Yaml\\Tests\\A":1:{s:1:"a";s:3:"foo";}\', bar: 1 }', $dump, '->dump() is able to dump objects'); + } + public function testObjectSupportDisabledButNoExceptions() + { + $dump = $this->dumper->dump(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(), 'bar' => 1]); + $this->assertEquals('{ foo: null, bar: 1 }', $dump, '->dump() does not dump objects when disabled'); + } + public function testObjectSupportDisabledWithExceptions() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\DumpException'); + $this->dumper->dump(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(), 'bar' => 1], 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EXCEPTION_ON_INVALID_TYPE); + } + /** + * @group legacy + */ + public function testObjectSupportDisabledWithExceptionsPassingTrue() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\DumpException'); + $this->dumper->dump(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(), 'bar' => 1], 0, 0, \true); + } + public function testEmptyArray() + { + $dump = $this->dumper->dump([]); + $this->assertEquals('{ }', $dump); + $dump = $this->dumper->dump([], 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE); + $this->assertEquals('[]', $dump); + $dump = $this->dumper->dump([], 9, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE); + $this->assertEquals('[]', $dump); + $dump = $this->dumper->dump(new \ArrayObject(), 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE | \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); + $this->assertEquals('{ }', $dump); + $dump = $this->dumper->dump(new \stdClass(), 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_EMPTY_ARRAY_AS_SEQUENCE | \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); + $this->assertEquals('{ }', $dump); + } + /** + * @dataProvider getEscapeSequences + */ + public function testEscapedEscapeSequencesInQuotedScalar($input, $expected) + { + $this->assertEquals($expected, $this->dumper->dump($input)); + } + public function getEscapeSequences() + { + return ['empty string' => ['', "''"], 'null' => ["\0", '"\\0"'], 'bell' => ["\7", '"\\a"'], 'backspace' => ["\10", '"\\b"'], 'horizontal-tab' => ["\t", '"\\t"'], 'line-feed' => ["\n", '"\\n"'], 'vertical-tab' => ["\v", '"\\v"'], 'form-feed' => ["\f", '"\\f"'], 'carriage-return' => ["\r", '"\\r"'], 'escape' => ["\33", '"\\e"'], 'space' => [' ', "' '"], 'double-quote' => ['"', "'\"'"], 'slash' => ['/', '/'], 'backslash' => ['\\', '\\'], 'next-line' => ["Â…", '"\\N"'], 'non-breaking-space' => [" ", '"\\_"'], 'line-separator' => ["
", '"\\L"'], 'paragraph-separator' => ["
", '"\\P"'], 'colon' => [':', "':'"]]; + } + public function testBinaryDataIsDumpedBase64Encoded() + { + $binaryData = \file_get_contents(__DIR__ . '/Fixtures/arrow.gif'); + $expected = '{ data: !!binary ' . \base64_encode($binaryData) . ' }'; + $this->assertSame($expected, $this->dumper->dump(['data' => $binaryData])); + } + public function testNonUtf8DataIsDumpedBase64Encoded() + { + // "für" (ISO-8859-1 encoded) + $this->assertSame('!!binary ZsM/cg==', $this->dumper->dump("fÃ?r")); + } + /** + * @dataProvider objectAsMapProvider + */ + public function testDumpObjectAsMap($object, $expected) + { + $yaml = $this->dumper->dump($object, 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); + $this->assertEquals($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP)); + } + public function objectAsMapProvider() + { + $tests = []; + $bar = new \stdClass(); + $bar->class = 'classBar'; + $bar->args = ['bar']; + $zar = new \stdClass(); + $foo = new \stdClass(); + $foo->bar = $bar; + $foo->zar = $zar; + $object = new \stdClass(); + $object->foo = $foo; + $tests['stdClass'] = [$object, $object]; + $arrayObject = new \ArrayObject(); + $arrayObject['foo'] = 'bar'; + $arrayObject['baz'] = 'foobar'; + $parsedArrayObject = new \stdClass(); + $parsedArrayObject->foo = 'bar'; + $parsedArrayObject->baz = 'foobar'; + $tests['ArrayObject'] = [$arrayObject, $parsedArrayObject]; + $a = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\A(); + $tests['arbitrary-object'] = [$a, null]; + return $tests; + } + public function testDumpingArrayObjectInstancesRespectsInlineLevel() + { + $deep = new \ArrayObject(['deep1' => 'd', 'deep2' => 'e']); + $inner = new \ArrayObject(['inner1' => 'b', 'inner2' => 'c', 'inner3' => $deep]); + $outer = new \ArrayObject(['outer1' => 'a', 'outer2' => $inner]); + $yaml = $this->dumper->dump($outer, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); + $expected = <<assertSame($expected, $yaml); + } + public function testDumpingArrayObjectInstancesWithNumericKeysInlined() + { + $deep = new \ArrayObject(['d', 'e']); + $inner = new \ArrayObject(['b', 'c', $deep]); + $outer = new \ArrayObject(['a', $inner]); + $yaml = $this->dumper->dump($outer, 0, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); + $expected = <<assertSame($expected, $yaml); + } + public function testDumpingArrayObjectInstancesWithNumericKeysRespectsInlineLevel() + { + $deep = new \ArrayObject(['d', 'e']); + $inner = new \ArrayObject(['b', 'c', $deep]); + $outer = new \ArrayObject(['a', $inner]); + $yaml = $this->dumper->dump($outer, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); + $expected = <<assertEquals($expected, $yaml); + } + public function testDumpEmptyArrayObjectInstanceAsMap() + { + $this->assertSame('{ }', $this->dumper->dump(new \ArrayObject(), 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP)); + } + public function testDumpEmptyStdClassInstanceAsMap() + { + $this->assertSame('{ }', $this->dumper->dump(new \stdClass(), 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP)); + } + public function testDumpingStdClassInstancesRespectsInlineLevel() + { + $deep = new \stdClass(); + $deep->deep1 = 'd'; + $deep->deep2 = 'e'; + $inner = new \stdClass(); + $inner->inner1 = 'b'; + $inner->inner2 = 'c'; + $inner->inner3 = $deep; + $outer = new \stdClass(); + $outer->outer1 = 'a'; + $outer->outer2 = $inner; + $yaml = $this->dumper->dump($outer, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_OBJECT_AS_MAP); + $expected = <<assertSame($expected, $yaml); + } + public function testDumpingTaggedValueSequenceRespectsInlineLevel() + { + $data = [new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'jane']), new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'john'])]; + $yaml = $this->dumper->dump($data, 2); + $expected = <<assertSame($expected, $yaml); + } + public function testDumpingTaggedValueSequenceWithInlinedTagValues() + { + $data = [new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'jane']), new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'john'])]; + $yaml = $this->dumper->dump($data, 1); + $expected = <<assertSame($expected, $yaml); + } + public function testDumpingTaggedValueMapRespectsInlineLevel() + { + $data = ['user1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'jane']), 'user2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'john'])]; + $yaml = $this->dumper->dump($data, 2); + $expected = <<assertSame($expected, $yaml); + } + public function testDumpingTaggedValueMapWithInlinedTagValues() + { + $data = ['user1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'jane']), 'user2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', ['username' => 'john'])]; + $yaml = $this->dumper->dump($data, 1); + $expected = <<assertSame($expected, $yaml); + } + public function testDumpingNotInlinedScalarTaggedValue() + { + $data = ['user1' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', 'jane'), 'user2' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('user', 'john')]; + $expected = <<assertSame($expected, $this->dumper->dump($data, 2)); + } + public function testDumpingNotInlinedNullTaggedValue() + { + $data = ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('bar', null)]; + $expected = <<assertSame($expected, $this->dumper->dump($data, 2)); + } + public function testDumpingMultiLineStringAsScalarBlockTaggedValue() + { + $data = ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('bar', "foo\nline with trailing spaces:\n \nbar\ninteger like line:\n123456789\nempty line:\n\nbaz")]; + $expected = <<assertSame($expected, $this->dumper->dump($data, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); + } + public function testDumpingInlinedMultiLineIfRnBreakLineInTaggedValue() + { + $data = ['data' => ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('bar', "foo\r\nline with trailing spaces:\n \nbar\ninteger like line:\n123456789\nempty line:\n\nbaz")]]; + $this->assertSame(\file_get_contents(__DIR__ . '/Fixtures/multiple_lines_as_literal_block_for_tagged_values.yml'), $this->dumper->dump($data, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); + } + public function testDumpMultiLineStringAsScalarBlock() + { + $data = ['data' => ['single_line' => 'foo bar baz', 'multi_line' => "foo\nline with trailing spaces:\n \nbar\ninteger like line:\n123456789\nempty line:\n\nbaz", 'multi_line_with_carriage_return' => "foo\nbar\r\nbaz", 'nested_inlined_multi_line_string' => ['inlined_multi_line' => "foo\nbar\r\nempty line:\n\nbaz"]]]; + $this->assertSame(\file_get_contents(__DIR__ . '/Fixtures/multiple_lines_as_literal_block.yml'), $this->dumper->dump($data, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); + } + public function testDumpMultiLineStringAsScalarBlockWhenFirstLineHasLeadingSpace() + { + $data = ['data' => ['multi_line' => " the first line has leading spaces\nThe second line does not."]]; + $this->assertSame(\file_get_contents(__DIR__ . '/Fixtures/multiple_lines_as_literal_block_leading_space_in_first_line.yml'), $this->dumper->dump($data, 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); + } + public function testCarriageReturnFollowedByNewlineIsMaintainedWhenDumpingAsMultiLineLiteralBlock() + { + $this->assertSame("- \"a\\r\\nb\\nc\"\n", $this->dumper->dump(["a\r\nb\nc"], 2, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); + } + public function testCarriageReturnNotFollowedByNewlineIsPreservedWhenDumpingAsMultiLineLiteralBlock() + { + $expected = <<<'YAML' +parent: + foo: "bar\n\rbaz: qux" + +YAML; + $this->assertSame($expected, $this->dumper->dump(['parent' => ['foo' => "bar\n\rbaz: qux"]], 4, 0, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::DUMP_MULTI_LINE_LITERAL_BLOCK)); + } + public function testZeroIndentationThrowsException() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('The indentation must be greater than zero'); + new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper(0); + } + public function testNegativeIndentationThrowsException() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('The indentation must be greater than zero'); + new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper(-4); + } +} +class A +{ + public $a = 'foo'; +} diff --git a/vendor/symfony/yaml/Tests/Fixtures/YtsAnchorAlias.yml b/vendor/symfony/yaml/Tests/Fixtures/YtsAnchorAlias.yml index 81b4129aa..bf54e8004 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/YtsAnchorAlias.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/YtsAnchorAlias.yml @@ -1,31 +1,31 @@ ---- %YAML:1.0 -test: Simple Alias Example -brief: > - If you need to refer to the same item of data twice, - you can give that item an alias. The alias is a plain - string, starting with an ampersand. The item may then - be referred to by the alias throughout your document - by using an asterisk before the name of the alias. - This is called an anchor. -yaml: | - - &showell Steve - - Clark - - Brian - - Oren - - *showell -php: | - ['Steve', 'Clark', 'Brian', 'Oren', 'Steve'] - ---- -test: Alias of a Mapping -brief: > - An alias can be used on any item of data, including - sequences, mappings, and other complex data types. -yaml: | - - &hello - Meat: pork - Starch: potato - - banana - - *hello -php: | - [['Meat'=>'pork', 'Starch'=>'potato'], 'banana', ['Meat'=>'pork', 'Starch'=>'potato']] +--- %YAML:1.0 +test: Simple Alias Example +brief: > + If you need to refer to the same item of data twice, + you can give that item an alias. The alias is a plain + string, starting with an ampersand. The item may then + be referred to by the alias throughout your document + by using an asterisk before the name of the alias. + This is called an anchor. +yaml: | + - &showell Steve + - Clark + - Brian + - Oren + - *showell +php: | + ['Steve', 'Clark', 'Brian', 'Oren', 'Steve'] + +--- +test: Alias of a Mapping +brief: > + An alias can be used on any item of data, including + sequences, mappings, and other complex data types. +yaml: | + - &hello + Meat: pork + Starch: potato + - banana + - *hello +php: | + [['Meat'=>'pork', 'Starch'=>'potato'], 'banana', ['Meat'=>'pork', 'Starch'=>'potato']] diff --git a/vendor/symfony/yaml/Tests/Fixtures/YtsBasicTests.yml b/vendor/symfony/yaml/Tests/Fixtures/YtsBasicTests.yml index 1a08d8ea9..8bf81f072 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/YtsBasicTests.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/YtsBasicTests.yml @@ -1,202 +1,202 @@ ---- %YAML:1.0 -test: Simple Sequence -brief: | - You can specify a list in YAML by placing each - member of the list on a new line with an opening - dash. These lists are called sequences. -yaml: | - - apple - - banana - - carrot -php: | - ['apple', 'banana', 'carrot'] ---- -test: Sequence With Item Being Null In The Middle -brief: | - You can specify a list in YAML by placing each - member of the list on a new line with an opening - dash. These lists are called sequences. -yaml: | - - apple - - - - carrot -php: | - ['apple', null, 'carrot'] ---- -test: Sequence With Last Item Being Null -brief: | - You can specify a list in YAML by placing each - member of the list on a new line with an opening - dash. These lists are called sequences. -yaml: | - - apple - - banana - - -php: | - ['apple', 'banana', null] ---- -test: Nested Sequences -brief: | - You can include a sequence within another - sequence by giving the sequence an empty - dash, followed by an indented list. -yaml: | - - - - foo - - bar - - baz -php: | - [['foo', 'bar', 'baz']] ---- -test: Mixed Sequences -brief: | - Sequences can contain any YAML data, - including strings and other sequences. -yaml: | - - apple - - - - foo - - bar - - x123 - - banana - - carrot -php: | - ['apple', ['foo', 'bar', 'x123'], 'banana', 'carrot'] ---- -test: Deeply Nested Sequences -brief: | - Sequences can be nested even deeper, with each - level of indentation representing a level of - depth. -yaml: | - - - - - - uno - - dos -php: | - [[['uno', 'dos']]] ---- -test: Simple Mapping -brief: | - You can add a keyed list (also known as a dictionary or - hash) to your document by placing each member of the - list on a new line, with a colon separating the key - from its value. In YAML, this type of list is called - a mapping. -yaml: | - foo: whatever - bar: stuff -php: | - ['foo' => 'whatever', 'bar' => 'stuff'] ---- -test: Sequence in a Mapping -brief: | - A value in a mapping can be a sequence. -yaml: | - foo: whatever - bar: - - uno - - dos -php: | - ['foo' => 'whatever', 'bar' => ['uno', 'dos']] ---- -test: Nested Mappings -brief: | - A value in a mapping can be another mapping. -yaml: | - foo: whatever - bar: - fruit: apple - name: steve - sport: baseball -php: | - [ - 'foo' => 'whatever', - 'bar' => [ - 'fruit' => 'apple', - 'name' => 'steve', - 'sport' => 'baseball' - ] - ] ---- -test: Mixed Mapping -brief: | - A mapping can contain any assortment - of mappings and sequences as values. -yaml: | - foo: whatever - bar: - - - fruit: apple - name: steve - sport: baseball - - more - - - python: rocks - perl: papers - ruby: scissorses -php: | - [ - 'foo' => 'whatever', - 'bar' => [ - [ - 'fruit' => 'apple', - 'name' => 'steve', - 'sport' => 'baseball' - ], - 'more', - [ - 'python' => 'rocks', - 'perl' => 'papers', - 'ruby' => 'scissorses' - ] - ] - ] ---- -test: Mapping-in-Sequence Shortcut -todo: true -brief: | - If you are adding a mapping to a sequence, you - can place the mapping on the same line as the - dash as a shortcut. -yaml: | - - work on YAML.py: - - work on Store -php: | - [['work on YAML.py' => ['work on Store']]] ---- -test: Sequence-in-Mapping Shortcut -todo: true -brief: | - The dash in a sequence counts as indentation, so - you can add a sequence inside of a mapping without - needing spaces as indentation. -yaml: | - allow: - - 'localhost' - - '%.sourceforge.net' - - '%.freepan.org' -php: | - ['allow' => ['localhost', '%.sourceforge.net', '%.freepan.org']] ---- -todo: true -test: Merge key -brief: | - A merge key ('<<') can be used in a mapping to insert other mappings. If - the value associated with the merge key is a mapping, each of its key/value - pairs is inserted into the current mapping. -yaml: | - mapping: - name: Joe - job: Accountant - <<: - age: 38 -php: | - [ - 'mapping' => - [ - 'name' => 'Joe', - 'job' => 'Accountant', - 'age' => 38 - ] - ] +--- %YAML:1.0 +test: Simple Sequence +brief: | + You can specify a list in YAML by placing each + member of the list on a new line with an opening + dash. These lists are called sequences. +yaml: | + - apple + - banana + - carrot +php: | + ['apple', 'banana', 'carrot'] +--- +test: Sequence With Item Being Null In The Middle +brief: | + You can specify a list in YAML by placing each + member of the list on a new line with an opening + dash. These lists are called sequences. +yaml: | + - apple + - + - carrot +php: | + ['apple', null, 'carrot'] +--- +test: Sequence With Last Item Being Null +brief: | + You can specify a list in YAML by placing each + member of the list on a new line with an opening + dash. These lists are called sequences. +yaml: | + - apple + - banana + - +php: | + ['apple', 'banana', null] +--- +test: Nested Sequences +brief: | + You can include a sequence within another + sequence by giving the sequence an empty + dash, followed by an indented list. +yaml: | + - + - foo + - bar + - baz +php: | + [['foo', 'bar', 'baz']] +--- +test: Mixed Sequences +brief: | + Sequences can contain any YAML data, + including strings and other sequences. +yaml: | + - apple + - + - foo + - bar + - x123 + - banana + - carrot +php: | + ['apple', ['foo', 'bar', 'x123'], 'banana', 'carrot'] +--- +test: Deeply Nested Sequences +brief: | + Sequences can be nested even deeper, with each + level of indentation representing a level of + depth. +yaml: | + - + - + - uno + - dos +php: | + [[['uno', 'dos']]] +--- +test: Simple Mapping +brief: | + You can add a keyed list (also known as a dictionary or + hash) to your document by placing each member of the + list on a new line, with a colon separating the key + from its value. In YAML, this type of list is called + a mapping. +yaml: | + foo: whatever + bar: stuff +php: | + ['foo' => 'whatever', 'bar' => 'stuff'] +--- +test: Sequence in a Mapping +brief: | + A value in a mapping can be a sequence. +yaml: | + foo: whatever + bar: + - uno + - dos +php: | + ['foo' => 'whatever', 'bar' => ['uno', 'dos']] +--- +test: Nested Mappings +brief: | + A value in a mapping can be another mapping. +yaml: | + foo: whatever + bar: + fruit: apple + name: steve + sport: baseball +php: | + [ + 'foo' => 'whatever', + 'bar' => [ + 'fruit' => 'apple', + 'name' => 'steve', + 'sport' => 'baseball' + ] + ] +--- +test: Mixed Mapping +brief: | + A mapping can contain any assortment + of mappings and sequences as values. +yaml: | + foo: whatever + bar: + - + fruit: apple + name: steve + sport: baseball + - more + - + python: rocks + perl: papers + ruby: scissorses +php: | + [ + 'foo' => 'whatever', + 'bar' => [ + [ + 'fruit' => 'apple', + 'name' => 'steve', + 'sport' => 'baseball' + ], + 'more', + [ + 'python' => 'rocks', + 'perl' => 'papers', + 'ruby' => 'scissorses' + ] + ] + ] +--- +test: Mapping-in-Sequence Shortcut +todo: true +brief: | + If you are adding a mapping to a sequence, you + can place the mapping on the same line as the + dash as a shortcut. +yaml: | + - work on YAML.py: + - work on Store +php: | + [['work on YAML.py' => ['work on Store']]] +--- +test: Sequence-in-Mapping Shortcut +todo: true +brief: | + The dash in a sequence counts as indentation, so + you can add a sequence inside of a mapping without + needing spaces as indentation. +yaml: | + allow: + - 'localhost' + - '%.sourceforge.net' + - '%.freepan.org' +php: | + ['allow' => ['localhost', '%.sourceforge.net', '%.freepan.org']] +--- +todo: true +test: Merge key +brief: | + A merge key ('<<') can be used in a mapping to insert other mappings. If + the value associated with the merge key is a mapping, each of its key/value + pairs is inserted into the current mapping. +yaml: | + mapping: + name: Joe + job: Accountant + <<: + age: 38 +php: | + [ + 'mapping' => + [ + 'name' => 'Joe', + 'job' => 'Accountant', + 'age' => 38 + ] + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/YtsBlockMapping.yml b/vendor/symfony/yaml/Tests/Fixtures/YtsBlockMapping.yml index 1f3a2e544..82479b6e0 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/YtsBlockMapping.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/YtsBlockMapping.yml @@ -1,51 +1,51 @@ ---- -test: One Element Mapping -brief: | - A mapping with one key/value pair -yaml: | - foo: bar -php: | - ['foo' => 'bar'] ---- -test: Multi Element Mapping -brief: | - More than one key/value pair -yaml: | - red: baron - white: walls - blue: berries -php: | - [ - 'red' => 'baron', - 'white' => 'walls', - 'blue' => 'berries', - ] ---- -test: Values aligned -brief: | - Often times human editors of documents will align the values even - though YAML emitters generally don't. -yaml: | - red: baron - white: walls - blue: berries -php: | - [ - 'red' => 'baron', - 'white' => 'walls', - 'blue' => 'berries', - ] ---- -test: Colons aligned -brief: | - Spaces can come before the ': ' key/value separator. -yaml: | - red : baron - white : walls - blue : berries -php: | - [ - 'red' => 'baron', - 'white' => 'walls', - 'blue' => 'berries', - ] +--- +test: One Element Mapping +brief: | + A mapping with one key/value pair +yaml: | + foo: bar +php: | + ['foo' => 'bar'] +--- +test: Multi Element Mapping +brief: | + More than one key/value pair +yaml: | + red: baron + white: walls + blue: berries +php: | + [ + 'red' => 'baron', + 'white' => 'walls', + 'blue' => 'berries', + ] +--- +test: Values aligned +brief: | + Often times human editors of documents will align the values even + though YAML emitters generally don't. +yaml: | + red: baron + white: walls + blue: berries +php: | + [ + 'red' => 'baron', + 'white' => 'walls', + 'blue' => 'berries', + ] +--- +test: Colons aligned +brief: | + Spaces can come before the ': ' key/value separator. +yaml: | + red : baron + white : walls + blue : berries +php: | + [ + 'red' => 'baron', + 'white' => 'walls', + 'blue' => 'berries', + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/YtsDocumentSeparator.yml b/vendor/symfony/yaml/Tests/Fixtures/YtsDocumentSeparator.yml index f5d40395c..a72764d09 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/YtsDocumentSeparator.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/YtsDocumentSeparator.yml @@ -1,85 +1,85 @@ ---- %YAML:1.0 -test: Trailing Document Separator -todo: true -brief: > - You can separate YAML documents - with a string of three dashes. -yaml: | - - foo: 1 - bar: 2 - --- - more: stuff -python: | - [ - [ { 'foo': 1, 'bar': 2 } ], - { 'more': 'stuff' } - ] -ruby: | - [ { 'foo' => 1, 'bar' => 2 } ] - ---- -test: Leading Document Separator -todo: true -brief: > - You can explicitly give an opening - document separator to your YAML stream. -yaml: | - --- - - foo: 1 - bar: 2 - --- - more: stuff -python: | - [ - [ {'foo': 1, 'bar': 2}], - {'more': 'stuff'} - ] -ruby: | - [ { 'foo' => 1, 'bar' => 2 } ] - ---- -test: YAML Header -todo: true -brief: > - The opening separator can contain directives - to the YAML parser, such as the version - number. -yaml: | - --- %YAML:1.0 - foo: 1 - bar: 2 -php: | - ['foo' => 1, 'bar' => 2] -documents: 1 - ---- -test: Red Herring Document Separator -brief: > - Separators included in blocks or strings - are treated as blocks or strings, as the - document separator should have no indentation - preceding it. -yaml: | - foo: | - --- -php: | - ['foo' => "---\n"] - ---- -test: Multiple Document Separators in Block -brief: > - This technique allows you to embed other YAML - documents within literal blocks. -yaml: | - foo: | - --- - foo: bar - --- - yo: baz - bar: | - fooness -php: | - [ - 'foo' => "---\nfoo: _PhpScoper5ea00cc67502b\bar\n---\nyo: _PhpScoper5ea00cc67502b\baz\n", - 'bar' => "_PhpScoper5ea00cc67502b\fooness\n" - ] +--- %YAML:1.0 +test: Trailing Document Separator +todo: true +brief: > + You can separate YAML documents + with a string of three dashes. +yaml: | + - foo: 1 + bar: 2 + --- + more: stuff +python: | + [ + [ { 'foo': 1, 'bar': 2 } ], + { 'more': 'stuff' } + ] +ruby: | + [ { 'foo' => 1, 'bar' => 2 } ] + +--- +test: Leading Document Separator +todo: true +brief: > + You can explicitly give an opening + document separator to your YAML stream. +yaml: | + --- + - foo: 1 + bar: 2 + --- + more: stuff +python: | + [ + [ {'foo': 1, 'bar': 2}], + {'more': 'stuff'} + ] +ruby: | + [ { 'foo' => 1, 'bar' => 2 } ] + +--- +test: YAML Header +todo: true +brief: > + The opening separator can contain directives + to the YAML parser, such as the version + number. +yaml: | + --- %YAML:1.0 + foo: 1 + bar: 2 +php: | + ['foo' => 1, 'bar' => 2] +documents: 1 + +--- +test: Red Herring Document Separator +brief: > + Separators included in blocks or strings + are treated as blocks or strings, as the + document separator should have no indentation + preceding it. +yaml: | + foo: | + --- +php: | + ['foo' => "---\n"] + +--- +test: Multiple Document Separators in Block +brief: > + This technique allows you to embed other YAML + documents within literal blocks. +yaml: | + foo: | + --- + foo: bar + --- + yo: baz + bar: | + fooness +php: | + [ + 'foo' => "---\nfoo: _PhpScoper5ea00cc67502b\bar\n---\nyo: _PhpScoper5ea00cc67502b\baz\n", + 'bar' => "_PhpScoper5ea00cc67502b\fooness\n" + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/YtsErrorTests.yml b/vendor/symfony/yaml/Tests/Fixtures/YtsErrorTests.yml index e8697f931..30592f1e7 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/YtsErrorTests.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/YtsErrorTests.yml @@ -1,25 +1,25 @@ ---- -test: Missing value for hash item -todo: true -brief: | - Third item in this hash doesn't have a value -yaml: | - okay: value - also okay: ~ - causes error because no value specified - last key: value okay here too -python-error: causes error because no value specified - ---- -test: Not indenting enough -brief: | - There was a bug in PyYaml where it was off by one - in the indentation check. It was allowing the YAML - below. -# This is actually valid YAML now. Someone should tell showell. -yaml: | - foo: - firstline: 1 - secondline: 2 -php: | - ['foo' => null, 'firstline' => 1, 'secondline' => 2] +--- +test: Missing value for hash item +todo: true +brief: | + Third item in this hash doesn't have a value +yaml: | + okay: value + also okay: ~ + causes error because no value specified + last key: value okay here too +python-error: causes error because no value specified + +--- +test: Not indenting enough +brief: | + There was a bug in PyYaml where it was off by one + in the indentation check. It was allowing the YAML + below. +# This is actually valid YAML now. Someone should tell showell. +yaml: | + foo: + firstline: 1 + secondline: 2 +php: | + ['foo' => null, 'firstline' => 1, 'secondline' => 2] diff --git a/vendor/symfony/yaml/Tests/Fixtures/YtsFlowCollections.yml b/vendor/symfony/yaml/Tests/Fixtures/YtsFlowCollections.yml index cc562cd9d..faff710f1 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/YtsFlowCollections.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/YtsFlowCollections.yml @@ -1,60 +1,60 @@ ---- -test: Simple Inline Array -brief: > - Sequences can be contained on a - single line, using the inline syntax. - Separate each entry with commas and - enclose in square brackets. -yaml: | - seq: [ a, b, c ] -php: | - ['seq' => ['a', 'b', 'c']] ---- -test: Simple Inline Hash -brief: > - Mapping can also be contained on - a single line, using the inline - syntax. Each key-value pair is - separated by a colon, with a comma - between each entry in the mapping. - Enclose with curly braces. -yaml: | - hash: { name: Steve, foo: bar } -php: | - ['hash' => ['name' => 'Steve', 'foo' => 'bar']] ---- -test: Multi-line Inline Collections -todo: true -brief: > - Both inline sequences and inline mappings - can span multiple lines, provided that you - indent the additional lines. -yaml: | - languages: [ Ruby, - Perl, - Python ] - websites: { YAML: yaml.org, - Ruby: ruby-lang.org, - Python: python.org, - Perl: use.perl.org } -php: | - [ - 'languages' => ['Ruby', 'Perl', 'Python'], - 'websites' => [ - 'YAML' => 'yaml.org', - 'Ruby' => 'ruby-lang.org', - 'Python' => 'python.org', - 'Perl' => 'use.perl.org' - ] - ] ---- -test: Commas in Values (not in the spec!) -todo: true -brief: > - List items in collections are delimited by commas, but - there must be a space after each comma. This allows you - to add numbers without quoting. -yaml: | - attendances: [ 45,123, 70,000, 17,222 ] -php: | - ['attendances' => [45123, 70000, 17222]] +--- +test: Simple Inline Array +brief: > + Sequences can be contained on a + single line, using the inline syntax. + Separate each entry with commas and + enclose in square brackets. +yaml: | + seq: [ a, b, c ] +php: | + ['seq' => ['a', 'b', 'c']] +--- +test: Simple Inline Hash +brief: > + Mapping can also be contained on + a single line, using the inline + syntax. Each key-value pair is + separated by a colon, with a comma + between each entry in the mapping. + Enclose with curly braces. +yaml: | + hash: { name: Steve, foo: bar } +php: | + ['hash' => ['name' => 'Steve', 'foo' => 'bar']] +--- +test: Multi-line Inline Collections +todo: true +brief: > + Both inline sequences and inline mappings + can span multiple lines, provided that you + indent the additional lines. +yaml: | + languages: [ Ruby, + Perl, + Python ] + websites: { YAML: yaml.org, + Ruby: ruby-lang.org, + Python: python.org, + Perl: use.perl.org } +php: | + [ + 'languages' => ['Ruby', 'Perl', 'Python'], + 'websites' => [ + 'YAML' => 'yaml.org', + 'Ruby' => 'ruby-lang.org', + 'Python' => 'python.org', + 'Perl' => 'use.perl.org' + ] + ] +--- +test: Commas in Values (not in the spec!) +todo: true +brief: > + List items in collections are delimited by commas, but + there must be a space after each comma. This allows you + to add numbers without quoting. +yaml: | + attendances: [ 45,123, 70,000, 17,222 ] +php: | + ['attendances' => [45123, 70000, 17222]] diff --git a/vendor/symfony/yaml/Tests/Fixtures/YtsFoldedScalars.yml b/vendor/symfony/yaml/Tests/Fixtures/YtsFoldedScalars.yml index 8961e7e75..7f2eec0b7 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/YtsFoldedScalars.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/YtsFoldedScalars.yml @@ -1,176 +1,176 @@ ---- %YAML:1.0 -test: Single ending newline -brief: > - A pipe character, followed by an indented - block of text is treated as a literal - block, in which newlines are preserved - throughout the block, including the final - newline. -yaml: | - --- - this: | - Foo - Bar -php: | - ['this' => "_PhpScoper5ea00cc67502b\Foo\nBar\n"] ---- -test: The '+' indicator -brief: > - The '+' indicator says to keep newlines at the end of text - blocks. -yaml: | - normal: | - extra new lines not kept - - preserving: |+ - extra new lines are kept - - - dummy: value -php: | - [ - 'normal' => "extra new lines not _PhpScoper5ea00cc67502b\kept\n", - 'preserving' => "extra new lines are _PhpScoper5ea00cc67502b\kept\n\n\n", - 'dummy' => 'value' - ] ---- -test: Three trailing newlines in literals -brief: > - To give you more control over how space - is preserved in text blocks, YAML has - the keep '+' and chomp '-' indicators. - The keep indicator will preserve all - ending newlines, while the chomp indicator - will strip all ending newlines. -yaml: | - clipped: | - This has one newline. - - - - same as "clipped" above: "This has one newline.\n" - - stripped: |- - This has no newline. - - - - same as "stripped" above: "This has no newline." - - kept: |+ - This has four newlines. - - - - same as "kept" above: "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n" -php: | - [ - 'clipped' => "This has one newline.\n", - 'same as "clipped" above' => "This has one newline.\n", - 'stripped' => 'This has no newline.', - 'same as "stripped" above' => 'This has no newline.', - 'kept' => "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n", - 'same as "kept" above' => "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n" - ] ---- -test: Extra trailing newlines with spaces -todo: true -brief: > - Normally, only a single newline is kept - from the end of a literal block, unless the - keep '+' character is used in combination - with the pipe. The following example - will preserve all ending whitespace - since the last line of both literal blocks - contains spaces which extend past the indentation - level. -yaml: | - --- - this: | - Foo - - - kept: |+ - Foo - - -php: | - ['this' => "_PhpScoper5ea00cc67502b\Foo\n\n \n", - 'kept' => "_PhpScoper5ea00cc67502b\Foo\n\n \n"] - ---- -test: Folded Block in a Sequence -brief: > - A greater-then character, followed by an indented - block of text is treated as a folded block, in - which lines of text separated by a single newline - are concatenated as a single line. -yaml: | - --- - - apple - - banana - - > - can't you see - the beauty of yaml? - hmm - - dog -php: | - [ - 'apple', - 'banana', - "can't you see the beauty of yaml? _PhpScoper5ea00cc67502b\hmm\n", - 'dog' - ] ---- -test: Folded Block as a Mapping Value -brief: > - Both literal and folded blocks can be - used in collections, as values in a - sequence or a mapping. -yaml: | - --- - quote: > - Mark McGwire's - year was crippled - by a knee injury. - source: espn -php: | - [ - 'quote' => "Mark McGwire's year was crippled by a knee injury.\n", - 'source' => 'espn' - ] ---- -test: Three trailing newlines in folded blocks -brief: > - The keep and chomp indicators can also - be applied to folded blocks. -yaml: | - clipped: > - This has one newline. - - - - same as "clipped" above: "This has one newline.\n" - - stripped: >- - This has no newline. - - - - same as "stripped" above: "This has no newline." - - kept: >+ - This has four newlines. - - - - same as "kept" above: "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n" -php: | - [ - 'clipped' => "This has one newline.\n", - 'same as "clipped" above' => "This has one newline.\n", - 'stripped' => 'This has no newline.', - 'same as "stripped" above' => 'This has no newline.', - 'kept' => "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n", - 'same as "kept" above' => "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n" - ] +--- %YAML:1.0 +test: Single ending newline +brief: > + A pipe character, followed by an indented + block of text is treated as a literal + block, in which newlines are preserved + throughout the block, including the final + newline. +yaml: | + --- + this: | + Foo + Bar +php: | + ['this' => "_PhpScoper5ea00cc67502b\Foo\nBar\n"] +--- +test: The '+' indicator +brief: > + The '+' indicator says to keep newlines at the end of text + blocks. +yaml: | + normal: | + extra new lines not kept + + preserving: |+ + extra new lines are kept + + + dummy: value +php: | + [ + 'normal' => "extra new lines not _PhpScoper5ea00cc67502b\kept\n", + 'preserving' => "extra new lines are _PhpScoper5ea00cc67502b\kept\n\n\n", + 'dummy' => 'value' + ] +--- +test: Three trailing newlines in literals +brief: > + To give you more control over how space + is preserved in text blocks, YAML has + the keep '+' and chomp '-' indicators. + The keep indicator will preserve all + ending newlines, while the chomp indicator + will strip all ending newlines. +yaml: | + clipped: | + This has one newline. + + + + same as "clipped" above: "This has one newline.\n" + + stripped: |- + This has no newline. + + + + same as "stripped" above: "This has no newline." + + kept: |+ + This has four newlines. + + + + same as "kept" above: "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n" +php: | + [ + 'clipped' => "This has one newline.\n", + 'same as "clipped" above' => "This has one newline.\n", + 'stripped' => 'This has no newline.', + 'same as "stripped" above' => 'This has no newline.', + 'kept' => "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n", + 'same as "kept" above' => "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n" + ] +--- +test: Extra trailing newlines with spaces +todo: true +brief: > + Normally, only a single newline is kept + from the end of a literal block, unless the + keep '+' character is used in combination + with the pipe. The following example + will preserve all ending whitespace + since the last line of both literal blocks + contains spaces which extend past the indentation + level. +yaml: | + --- + this: | + Foo + + + kept: |+ + Foo + + +php: | + ['this' => "_PhpScoper5ea00cc67502b\Foo\n\n \n", + 'kept' => "_PhpScoper5ea00cc67502b\Foo\n\n \n"] + +--- +test: Folded Block in a Sequence +brief: > + A greater-then character, followed by an indented + block of text is treated as a folded block, in + which lines of text separated by a single newline + are concatenated as a single line. +yaml: | + --- + - apple + - banana + - > + can't you see + the beauty of yaml? + hmm + - dog +php: | + [ + 'apple', + 'banana', + "can't you see the beauty of yaml? _PhpScoper5ea00cc67502b\hmm\n", + 'dog' + ] +--- +test: Folded Block as a Mapping Value +brief: > + Both literal and folded blocks can be + used in collections, as values in a + sequence or a mapping. +yaml: | + --- + quote: > + Mark McGwire's + year was crippled + by a knee injury. + source: espn +php: | + [ + 'quote' => "Mark McGwire's year was crippled by a knee injury.\n", + 'source' => 'espn' + ] +--- +test: Three trailing newlines in folded blocks +brief: > + The keep and chomp indicators can also + be applied to folded blocks. +yaml: | + clipped: > + This has one newline. + + + + same as "clipped" above: "This has one newline.\n" + + stripped: >- + This has no newline. + + + + same as "stripped" above: "This has no newline." + + kept: >+ + This has four newlines. + + + + same as "kept" above: "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n" +php: | + [ + 'clipped' => "This has one newline.\n", + 'same as "clipped" above' => "This has one newline.\n", + 'stripped' => 'This has no newline.', + 'same as "stripped" above' => 'This has no newline.', + 'kept' => "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n", + 'same as "kept" above' => "This has four newlines.\_PhpScoper5ea00cc67502b\n\n\n\n" + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/YtsNullsAndEmpties.yml b/vendor/symfony/yaml/Tests/Fixtures/YtsNullsAndEmpties.yml index ea8e36ed0..f017a75d4 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/YtsNullsAndEmpties.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/YtsNullsAndEmpties.yml @@ -1,45 +1,45 @@ ---- %YAML:1.0 -test: Empty Sequence -brief: > - You can represent the empty sequence - with an empty inline sequence. -yaml: | - empty: [] -php: | - ['empty' => []] ---- -test: Empty Mapping -brief: > - You can represent the empty mapping - with an empty inline mapping. -yaml: | - empty: {} -php: | - ['empty' => []] ---- -test: Empty Sequence as Entire Document -yaml: | - [] -php: | - [] ---- -test: Empty Mapping as Entire Document -yaml: | - {} -php: | - [] ---- -test: Null as Document -yaml: | - ~ -php: | - null ---- -test: Empty String -brief: > - You can represent an empty string - with a pair of quotes. -yaml: | - '' -php: | - '' +--- %YAML:1.0 +test: Empty Sequence +brief: > + You can represent the empty sequence + with an empty inline sequence. +yaml: | + empty: [] +php: | + ['empty' => []] +--- +test: Empty Mapping +brief: > + You can represent the empty mapping + with an empty inline mapping. +yaml: | + empty: {} +php: | + ['empty' => []] +--- +test: Empty Sequence as Entire Document +yaml: | + [] +php: | + [] +--- +test: Empty Mapping as Entire Document +yaml: | + {} +php: | + [] +--- +test: Null as Document +yaml: | + ~ +php: | + null +--- +test: Empty String +brief: > + You can represent an empty string + with a pair of quotes. +yaml: | + '' +php: | + '' diff --git a/vendor/symfony/yaml/Tests/Fixtures/YtsSpecificationExamples.yml b/vendor/symfony/yaml/Tests/Fixtures/YtsSpecificationExamples.yml index 1c7fae0b8..e37717c04 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/YtsSpecificationExamples.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/YtsSpecificationExamples.yml @@ -1,1701 +1,1701 @@ ---- %YAML:1.0 -test: Sequence of scalars -spec: 2.1 -yaml: | - - Mark McGwire - - Sammy Sosa - - Ken Griffey -php: | - ['Mark McGwire', 'Sammy Sosa', 'Ken Griffey'] ---- -test: Mapping of scalars to scalars -spec: 2.2 -yaml: | - hr: 65 - avg: 0.278 - rbi: 147 -php: | - ['hr' => 65, 'avg' => 0.278, 'rbi' => 147] ---- -test: Mapping of scalars to sequences -spec: 2.3 -yaml: | - american: - - Boston Red Sox - - Detroit Tigers - - New York Yankees - national: - - New York Mets - - Chicago Cubs - - Atlanta Braves -php: | - ['american' => - ['Boston Red Sox', 'Detroit Tigers', - 'New York Yankees'], - 'national' => - ['New York Mets', 'Chicago Cubs', - 'Atlanta Braves'] - ] ---- -test: Sequence of mappings -spec: 2.4 -yaml: | - - - name: Mark McGwire - hr: 65 - avg: 0.278 - - - name: Sammy Sosa - hr: 63 - avg: 0.288 -php: | - [ - ['name' => 'Mark McGwire', 'hr' => 65, 'avg' => 0.278], - ['name' => 'Sammy Sosa', 'hr' => 63, 'avg' => 0.288] - ] ---- -test: Legacy A5 -todo: true -spec: legacy_A5 -yaml: | - ? - - New York Yankees - - Atlanta Braves - : - - 2001-07-02 - - 2001-08-12 - - 2001-08-14 - ? - - Detroit Tigers - - Chicago Cubs - : - - 2001-07-23 -perl-busted: > - YAML.pm will be able to emulate this behavior soon. In this regard - it may be somewhat more correct than Python's native behavior which - can only use tuples as mapping keys. PyYAML will also need to figure - out some clever way to roundtrip structured keys. -python: | - [ - { - ('New York Yankees', 'Atlanta Braves'): - [yaml.timestamp('2001-07-02'), - yaml.timestamp('2001-08-12'), - yaml.timestamp('2001-08-14')], - ('Detroit Tigers', 'Chicago Cubs'): - [yaml.timestamp('2001-07-23')] - } - ] -ruby: | - { - [ 'New York Yankees', 'Atlanta Braves' ] => - [ Date.new( 2001, 7, 2 ), Date.new( 2001, 8, 12 ), Date.new( 2001, 8, 14 ) ], - [ 'Detroit Tigers', 'Chicago Cubs' ] => - [ Date.new( 2001, 7, 23 ) ] - } -syck: | - struct test_node seq1[] = { - { T_STR, 0, "New York Yankees" }, - { T_STR, 0, "Atlanta Braves" }, - end_node - }; - struct test_node seq2[] = { - { T_STR, 0, "2001-07-02" }, - { T_STR, 0, "2001-08-12" }, - { T_STR, 0, "2001-08-14" }, - end_node - }; - struct test_node seq3[] = { - { T_STR, 0, "Detroit Tigers" }, - { T_STR, 0, "Chicago Cubs" }, - end_node - }; - struct test_node seq4[] = { - { T_STR, 0, "2001-07-23" }, - end_node - }; - struct test_node map[] = { - { T_SEQ, 0, 0, seq1 }, - { T_SEQ, 0, 0, seq2 }, - { T_SEQ, 0, 0, seq3 }, - { T_SEQ, 0, 0, seq4 }, - end_node - }; - struct test_node stream[] = { - { T_MAP, 0, 0, map }, - end_node - }; - ---- -test: Sequence of sequences -spec: 2.5 -yaml: | - - [ name , hr , avg ] - - [ Mark McGwire , 65 , 0.278 ] - - [ Sammy Sosa , 63 , 0.288 ] -php: | - [ - [ 'name', 'hr', 'avg' ], - [ 'Mark McGwire', 65, 0.278 ], - [ 'Sammy Sosa', 63, 0.288 ] - ] ---- -test: Mapping of mappings -todo: true -spec: 2.6 -yaml: | - Mark McGwire: {hr: 65, avg: 0.278} - Sammy Sosa: { - hr: 63, - avg: 0.288 - } -php: | - [ - 'Mark McGwire' => - [ 'hr' => 65, 'avg' => 0.278 ], - 'Sammy Sosa' => - [ 'hr' => 63, 'avg' => 0.288 ] - ] ---- -test: Two documents in a stream each with a leading comment -todo: true -spec: 2.7 -yaml: | - # Ranking of 1998 home runs - --- - - Mark McGwire - - Sammy Sosa - - Ken Griffey - - # Team ranking - --- - - Chicago Cubs - - St Louis Cardinals -ruby: | - y = YAML::Stream.new - y.add( [ 'Mark McGwire', 'Sammy Sosa', 'Ken Griffey' ] ) - y.add( [ 'Chicago Cubs', 'St Louis Cardinals' ] ) -documents: 2 - ---- -test: Play by play feed from a game -todo: true -spec: 2.8 -yaml: | - --- - time: 20:03:20 - player: Sammy Sosa - action: strike (miss) - ... - --- - time: 20:03:47 - player: Sammy Sosa - action: grand slam - ... -perl: | - [ 'Mark McGwire', 'Sammy Sosa', 'Ken Griffey' ] -documents: 2 - ---- -test: Single document with two comments -spec: 2.9 -yaml: | - hr: # 1998 hr ranking - - Mark McGwire - - Sammy Sosa - rbi: - # 1998 rbi ranking - - Sammy Sosa - - Ken Griffey -php: | - [ - 'hr' => [ 'Mark McGwire', 'Sammy Sosa' ], - 'rbi' => [ 'Sammy Sosa', 'Ken Griffey' ] - ] ---- -test: Node for Sammy Sosa appears twice in this document -spec: 2.10 -yaml: | - --- - hr: - - Mark McGwire - # Following node labeled SS - - &SS Sammy Sosa - rbi: - - *SS # Subsequent occurrence - - Ken Griffey -php: | - [ - 'hr' => - ['Mark McGwire', 'Sammy Sosa'], - 'rbi' => - ['Sammy Sosa', 'Ken Griffey'] - ] ---- -test: Mapping between sequences -todo: true -spec: 2.11 -yaml: | - ? # PLAY SCHEDULE - - Detroit Tigers - - Chicago Cubs - : - - 2001-07-23 - - ? [ New York Yankees, - Atlanta Braves ] - : [ 2001-07-02, 2001-08-12, - 2001-08-14 ] -ruby: | - { - [ 'Detroit Tigers', 'Chicago Cubs' ] => [ Date.new( 2001, 7, 23 ) ], - [ 'New York Yankees', 'Atlanta Braves' ] => [ Date.new( 2001, 7, 2 ), Date.new( 2001, 8, 12 ), Date.new( 2001, 8, 14 ) ] - } -syck: | - struct test_node seq1[] = { - { T_STR, 0, "New York Yankees" }, - { T_STR, 0, "Atlanta Braves" }, - end_node - }; - struct test_node seq2[] = { - { T_STR, 0, "2001-07-02" }, - { T_STR, 0, "2001-08-12" }, - { T_STR, 0, "2001-08-14" }, - end_node - }; - struct test_node seq3[] = { - { T_STR, 0, "Detroit Tigers" }, - { T_STR, 0, "Chicago Cubs" }, - end_node - }; - struct test_node seq4[] = { - { T_STR, 0, "2001-07-23" }, - end_node - }; - struct test_node map[] = { - { T_SEQ, 0, 0, seq3 }, - { T_SEQ, 0, 0, seq4 }, - { T_SEQ, 0, 0, seq1 }, - { T_SEQ, 0, 0, seq2 }, - end_node - }; - struct test_node stream[] = { - { T_MAP, 0, 0, map }, - end_node - }; - ---- -test: Sequence key shortcut -spec: 2.12 -yaml: | - --- - # products purchased - - item : Super Hoop - quantity: 1 - - item : Basketball - quantity: 4 - - item : Big Shoes - quantity: 1 -php: | - [ - [ - 'item' => 'Super Hoop', - 'quantity' => 1, - ], - [ - 'item' => 'Basketball', - 'quantity' => 4, - ], - [ - 'item' => 'Big Shoes', - 'quantity' => 1, - ] - ] -perl: | - [ - { item => 'Super Hoop', quantity => 1 }, - { item => 'Basketball', quantity => 4 }, - { item => 'Big Shoes', quantity => 1 } - ] - -ruby: | - [ - { 'item' => 'Super Hoop', 'quantity' => 1 }, - { 'item' => 'Basketball', 'quantity' => 4 }, - { 'item' => 'Big Shoes', 'quantity' => 1 } - ] -python: | - [ - { 'item': 'Super Hoop', 'quantity': 1 }, - { 'item': 'Basketball', 'quantity': 4 }, - { 'item': 'Big Shoes', 'quantity': 1 } - ] -syck: | - struct test_node map1[] = { - { T_STR, 0, "item" }, - { T_STR, 0, "Super Hoop" }, - { T_STR, 0, "quantity" }, - { T_STR, 0, "1" }, - end_node - }; - struct test_node map2[] = { - { T_STR, 0, "item" }, - { T_STR, 0, "Basketball" }, - { T_STR, 0, "quantity" }, - { T_STR, 0, "4" }, - end_node - }; - struct test_node map3[] = { - { T_STR, 0, "item" }, - { T_STR, 0, "Big Shoes" }, - { T_STR, 0, "quantity" }, - { T_STR, 0, "1" }, - end_node - }; - struct test_node seq[] = { - { T_MAP, 0, 0, map1 }, - { T_MAP, 0, 0, map2 }, - { T_MAP, 0, 0, map3 }, - end_node - }; - struct test_node stream[] = { - { T_SEQ, 0, 0, seq }, - end_node - }; - - ---- -test: Literal perserves newlines -todo: true -spec: 2.13 -yaml: | - # ASCII Art - --- | - \//||\/|| - // || ||_ -perl: | - "\\//||\\/||\n// || ||_PhpScoper5ea00cc67502b\_\n" -ruby: | - "\\//||\\/||\n// || ||_PhpScoper5ea00cc67502b\_\n" -python: | - [ - flushLeft( - """ - \//||\/|| - // || ||_ - """ - ) - ] -syck: | - struct test_node stream[] = { - { T_STR, 0, "\\//||\\/||\n// || ||_PhpScoper5ea00cc67502b\_\n" }, - end_node - }; - ---- -test: Folded treats newlines as a space -todo: true -spec: 2.14 -yaml: | - --- - Mark McGwire's - year was crippled - by a knee injury. -perl: | - "Mark McGwire's year was crippled by a knee injury." -ruby: | - "Mark McGwire's year was crippled by a knee injury." -python: | - [ "Mark McGwire's year was crippled by a knee injury." ] -syck: | - struct test_node stream[] = { - { T_STR, 0, "Mark McGwire's year was crippled by a knee injury." }, - end_node - }; - ---- -test: Newlines preserved for indented and blank lines -todo: true -spec: 2.15 -yaml: | - --- > - Sammy Sosa completed another - fine season with great stats. - - 63 Home Runs - 0.288 Batting Average - - What a year! -perl: | - "Sammy Sosa completed another fine season with great stats.\_PhpScoper5ea00cc67502b\n\n 63 Home _PhpScoper5ea00cc67502b\Runs\n 0.288 Batting _PhpScoper5ea00cc67502b\Average\n\nWhat a year!\n" -ruby: | - "Sammy Sosa completed another fine season with great stats.\_PhpScoper5ea00cc67502b\n\n 63 Home _PhpScoper5ea00cc67502b\Runs\n 0.288 Batting _PhpScoper5ea00cc67502b\Average\n\nWhat a year!\n" -python: | - [ - flushLeft( - """ - Sammy Sosa completed another fine season with great stats. - - 63 Home Runs - 0.288 Batting Average - - What a year! - """ - ) - ] -syck: | - struct test_node stream[] = { - { T_STR, 0, "Sammy Sosa completed another fine season with great stats.\_PhpScoper5ea00cc67502b\n\n 63 Home _PhpScoper5ea00cc67502b\Runs\n 0.288 Batting _PhpScoper5ea00cc67502b\Average\n\nWhat a year!\n" }, - end_node - }; - - ---- -test: Indentation determines scope -spec: 2.16 -yaml: | - name: Mark McGwire - accomplishment: > - Mark set a major league - home run record in 1998. - stats: | - 65 Home Runs - 0.278 Batting Average -php: | - [ - 'name' => 'Mark McGwire', - 'accomplishment' => "Mark set a major league home run record in 1998.\n", - 'stats' => "65 Home _PhpScoper5ea00cc67502b\Runs\n0.278 Batting _PhpScoper5ea00cc67502b\Average\n" - ] ---- -test: Quoted scalars -todo: true -spec: 2.17 -yaml: | - unicode: "Sosa did fine.\u263A" - control: "\_PhpScoper5ea00cc67502b\b1998\t1999\t2000\n" - hexesc: "\_PhpScoper5ea00cc67502b\x0D\x0A is \_PhpScoper5ea00cc67502b\r\n" - - single: '"Howdy!" he cried.' - quoted: ' # not a ''comment''.' - tie-fighter: '|\-*-/|' -ruby: | - { - "tie-fighter" => "|\\-*-/|", - "control"=>"\_PhpScoper5ea00cc67502b\0101998\t1999\t2000\n", - "unicode"=>"Sosa did fine." + ["263A".hex ].pack('U*'), - "quoted"=>" # not a 'comment'.", - "single"=>"\"Howdy!\" he cried.", - "hexesc"=>"\_PhpScoper5ea00cc67502b\r\n is \_PhpScoper5ea00cc67502b\r\n" - } ---- -test: Multiline flow scalars -todo: true -spec: 2.18 -yaml: | - plain: - This unquoted scalar - spans many lines. - - quoted: "So does this - quoted scalar.\n" -ruby: | - { - 'plain' => 'This unquoted scalar spans many lines.', - 'quoted' => "So does this quoted scalar.\n" - } ---- -test: Integers -spec: 2.19 -yaml: | - canonical: 12345 - octal: 014 - hexadecimal: 0xC -php: | - [ - 'canonical' => 12345, - 'octal' => 014, - 'hexadecimal' => 0xC - ] ---- -test: Decimal Integer -deprecated: true -spec: 2.19 -yaml: | - decimal: +12,345 -php: | - [ - 'decimal' => 12345.0, - ] ---- -# FIX: spec shows parens around -inf and NaN -test: Floating point -spec: 2.20 -yaml: | - canonical: 1.23015e+3 - exponential: 12.3015e+02 - negative infinity: -.inf - not a number: .NaN - float as whole number: !!float 1 -php: | - [ - 'canonical' => 1230.15, - 'exponential' => 1230.15, - 'negative infinity' => log(0), - 'not a number' => -log(0), - 'float as whole number' => (float) 1 - ] ---- -test: Fixed Floating point -deprecated: true -spec: 2.20 -yaml: | - fixed: 1,230.15 -php: | - [ - 'fixed' => 1230.15, - ] ---- -test: Timestamps -todo: true -spec: 2.22 -yaml: | - canonical: 2001-12-15T02:59:43.1Z - iso8601: 2001-12-14t21:59:43.10-05:00 - spaced: 2001-12-14 21:59:43.10 -05:00 - date: 2002-12-14 # Time is noon UTC -php: | - [ - 'canonical' => YAML::mktime( 2001, 12, 15, 2, 59, 43, 0.10 ), - 'iso8601' => YAML::mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ), - 'spaced' => YAML::mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ), - 'date' => Date.new( 2002, 12, 14 ) - ] ---- -test: legacy Timestamps test -todo: true -spec: legacy D4 -yaml: | - canonical: 2001-12-15T02:59:43.00Z - iso8601: 2001-02-28t21:59:43.00-05:00 - spaced: 2001-12-14 21:59:43.00 -05:00 - date: 2002-12-14 -php: | - [ - 'canonical' => Time::utc( 2001, 12, 15, 2, 59, 43, 0 ), - 'iso8601' => YAML::mktime( 2001, 2, 28, 21, 59, 43, 0, "-05:00" ), - 'spaced' => YAML::mktime( 2001, 12, 14, 21, 59, 43, 0, "-05:00" ), - 'date' => Date.new( 2002, 12, 14 ) - ] ---- -test: Various explicit families -todo: true -spec: 2.23 -yaml: | - not-date: !!str 2002-04-28 - picture: !binary | - R0lGODlhDAAMAIQAAP//9/X - 17unp5WZmZgAAAOfn515eXv - Pz7Y6OjuDg4J+fn5OTk6enp - 56enmleECcgggoBADs= - - application specific tag: !!something | - The semantics of the tag - above may be different for - different documents. - -ruby-setup: | - YAML.add_private_type( "something" ) do |type, val| - "SOMETHING: #{val}" - end -ruby: | - { - 'not-date' => '2002-04-28', - 'picture' => "_PhpScoper5ea00cc67502b\GIF89a\f\000\f\000\204\000\000\377\377\367\365\365\356\351\351\345fff\000\000\000\347\347\347^^^\_PhpScoper5ea00cc67502b\363\363\355\216\216\216\340\340\340\237\237\237\223\223\223\247\247\247\236\236\236i^\020' \_PhpScoper5ea00cc67502b\202\n\001\000;", - 'application specific tag' => "SOMETHING: The semantics of the _PhpScoper5ea00cc67502b\tag\nabove may be different _PhpScoper5ea00cc67502b\for\ndifferent documents.\n" - } ---- -test: Application specific family -todo: true -spec: 2.24 -yaml: | - # Establish a tag prefix - --- !clarkevans.com,2002/graph/^shape - # Use the prefix: shorthand for - # !clarkevans.com,2002/graph/circle - - !^circle - center: &ORIGIN {x: 73, 'y': 129} - radius: 7 - - !^line # !clarkevans.com,2002/graph/line - start: *ORIGIN - finish: { x: 89, 'y': 102 } - - !^label - start: *ORIGIN - color: 0xFFEEBB - value: Pretty vector drawing. -ruby-setup: | - YAML.add_domain_type( "clarkevans.com,2002", 'graph/shape' ) { |type, val| - if Array === val - val << "Shape Container" - val - else - raise YAML::Error, "Invalid graph of class #{ val.class }: " + val.inspect - end - } - one_shape_proc = Proc.new { |type, val| - scheme, domain, type = type.split( /:/, 3 ) - if val.is_a? ::Hash - val['TYPE'] = "Shape: #{type}" - val - else - raise YAML::Error, "Invalid graph of class #{ val.class }: " + val.inspect - end - } - YAML.add_domain_type( "clarkevans.com,2002", 'graph/circle', &one_shape_proc ) - YAML.add_domain_type( "clarkevans.com,2002", 'graph/line', &one_shape_proc ) - YAML.add_domain_type( "clarkevans.com,2002", 'graph/label', &one_shape_proc ) -ruby: | - [ - { - "radius" => 7, - "center"=> - { - "x" => 73, - "y" => 129 - }, - "TYPE" => "Shape: graph/circle" - }, { - "finish" => - { - "x" => 89, - "y" => 102 - }, - "TYPE" => "Shape: graph/line", - "start" => - { - "x" => 73, - "y" => 129 - } - }, { - "TYPE" => "Shape: graph/label", - "value" => "Pretty vector drawing.", - "start" => - { - "x" => 73, - "y" => 129 - }, - "color" => 16772795 - }, - "Shape Container" - ] -# --- -# test: Unordered set -# spec: 2.25 -# yaml: | -# # sets are represented as a -# # mapping where each key is -# # associated with the empty string -# --- !set -# ? Mark McGwire -# ? Sammy Sosa -# ? Ken Griff ---- -test: Ordered mappings -todo: true -spec: 2.26 -yaml: | - # ordered maps are represented as - # a sequence of mappings, with - # each mapping having one key - --- !omap - - Mark McGwire: 65 - - Sammy Sosa: 63 - - Ken Griffy: 58 -ruby: | - YAML::Omap[ - 'Mark McGwire', 65, - 'Sammy Sosa', 63, - 'Ken Griffy', 58 - ] ---- -test: Invoice -dump_skip: true -spec: 2.27 -yaml: | - --- !clarkevans.com,2002/^invoice - invoice: 34843 - date : 2001-01-23 - bill-to: &id001 - given : Chris - family : Dumars - address: - lines: | - 458 Walkman Dr. - Suite #292 - city : Royal Oak - state : MI - postal : 48046 - ship-to: *id001 - product: - - - sku : BL394D - quantity : 4 - description : Basketball - price : 450.00 - - - sku : BL4438H - quantity : 1 - description : Super Hoop - price : 2392.00 - tax : 251.42 - total: 4443.52 - comments: > - Late afternoon is best. - Backup contact is Nancy - Billsmer @ 338-4338. -php: | - [ - 'invoice' => 34843, 'date' => gmmktime(0, 0, 0, 1, 23, 2001), - 'bill-to' => - [ 'given' => 'Chris', 'family' => 'Dumars', 'address' => [ 'lines' => "458 Walkman Dr.\nSuite #_PhpScoper5ea00cc67502b\292\n", 'city' => 'Royal Oak', 'state' => 'MI', 'postal' => 48046 ] ] - , 'ship-to' => - [ 'given' => 'Chris', 'family' => 'Dumars', 'address' => [ 'lines' => "458 Walkman Dr.\nSuite #_PhpScoper5ea00cc67502b\292\n", 'city' => 'Royal Oak', 'state' => 'MI', 'postal' => 48046 ] ] - , 'product' => - [ - [ 'sku' => 'BL394D', 'quantity' => 4, 'description' => 'Basketball', 'price' => 450.00 ], - [ 'sku' => 'BL4438H', 'quantity' => 1, 'description' => 'Super Hoop', 'price' => 2392.00 ] - ], - 'tax' => 251.42, 'total' => 4443.52, - 'comments' => "Late afternoon is best. Backup contact is Nancy Billsmer @ 338-4338.\n" - ] ---- -test: Log file -todo: true -spec: 2.28 -yaml: | - --- - Time: 2001-11-23 15:01:42 -05:00 - User: ed - Warning: > - This is an error message - for the log file - --- - Time: 2001-11-23 15:02:31 -05:00 - User: ed - Warning: > - A slightly different error - message. - --- - Date: 2001-11-23 15:03:17 -05:00 - User: ed - Fatal: > - Unknown variable "bar" - Stack: - - file: TopClass.py - line: 23 - code: | - x = MoreObject("_PhpScoper5ea00cc67502b\345\n") - - file: MoreClass.py - line: 58 - code: |- - foo = bar -ruby: | - y = YAML::Stream.new - y.add( { 'Time' => YAML::mktime( 2001, 11, 23, 15, 01, 42, 00, "-05:00" ), - 'User' => 'ed', 'Warning' => "This is an error message for the log _PhpScoper5ea00cc67502b\file\n" } ) - y.add( { 'Time' => YAML::mktime( 2001, 11, 23, 15, 02, 31, 00, "-05:00" ), - 'User' => 'ed', 'Warning' => "A slightly different error message.\n" } ) - y.add( { 'Date' => YAML::mktime( 2001, 11, 23, 15, 03, 17, 00, "-05:00" ), - 'User' => 'ed', 'Fatal' => "Unknown variable \"bar\"\n", - 'Stack' => [ - { 'file' => 'TopClass.py', 'line' => 23, 'code' => "x = MoreObject(\"_PhpScoper5ea00cc67502b\\345\\n\")\n" }, - { 'file' => 'MoreClass.py', 'line' => 58, 'code' => "foo = bar" } ] } ) -documents: 3 - ---- -test: Throwaway comments -yaml: | - ### These are four throwaway comment ### - - ### lines (the second line is empty). ### - this: | # Comments may trail lines. - contains three lines of text. - The third one starts with a - # character. This isn't a comment. - - # These are three throwaway comment - # lines (the first line is empty). -php: | - [ - 'this' => "contains three lines of text.\nThe third one starts with _PhpScoper5ea00cc67502b\a\n# character. This isn't a comment.\n" - ] ---- -test: Document with a single value -todo: true -yaml: | - --- > - This YAML stream contains a single text value. - The next stream is a log file - a sequence of - log entries. Adding an entry to the log is a - simple matter of appending it at the end. -ruby: | - "This YAML stream contains a single text value. The next stream is a log file - a sequence of log entries. Adding an entry to the log is a simple matter of appending it at the end.\n" ---- -test: Document stream -todo: true -yaml: | - --- - at: 2001-08-12 09:25:00.00 Z - type: GET - HTTP: '1.0' - url: '/index.html' - --- - at: 2001-08-12 09:25:10.00 Z - type: GET - HTTP: '1.0' - url: '/toc.html' -ruby: | - y = YAML::Stream.new - y.add( { - 'at' => Time::utc( 2001, 8, 12, 9, 25, 00 ), - 'type' => 'GET', - 'HTTP' => '1.0', - 'url' => '/index.html' - } ) - y.add( { - 'at' => Time::utc( 2001, 8, 12, 9, 25, 10 ), - 'type' => 'GET', - 'HTTP' => '1.0', - 'url' => '/toc.html' - } ) -documents: 2 - ---- -test: Top level mapping -yaml: | - # This stream is an example of a top-level mapping. - invoice : 34843 - date : 2001-01-23 - total : 4443.52 -php: | - [ - 'invoice' => 34843, - 'date' => gmmktime(0, 0, 0, 1, 23, 2001), - 'total' => 4443.52 - ] ---- -test: Single-line documents -todo: true -yaml: | - # The following is a sequence of three documents. - # The first contains an empty mapping, the second - # an empty sequence, and the last an empty string. - --- {} - --- [ ] - --- '' -ruby: | - y = YAML::Stream.new - y.add( {} ) - y.add( [] ) - y.add( '' ) -documents: 3 - ---- -test: Document with pause -todo: true -yaml: | - # A communication channel based on a YAML stream. - --- - sent at: 2002-06-06 11:46:25.10 Z - payload: Whatever - # Receiver can process this as soon as the following is sent: - ... - # Even if the next message is sent long after: - --- - sent at: 2002-06-06 12:05:53.47 Z - payload: Whatever - ... -ruby: | - y = YAML::Stream.new - y.add( - { 'sent at' => YAML::mktime( 2002, 6, 6, 11, 46, 25, 0.10 ), - 'payload' => 'Whatever' } - ) - y.add( - { "payload" => "Whatever", "sent at" => YAML::mktime( 2002, 6, 6, 12, 5, 53, 0.47 ) } - ) -documents: 2 - ---- -test: Explicit typing -deprecated: Using the non-specific tag "!" is deprecated since Symfony 3.4 as its behavior will change in 4.0. -yaml: | - integer: 12 - also int: ! "12" - string: !!str 12 -php: | - [ 'integer' => 12, 'also int' => 12, 'string' => '12' ] ---- -test: Private types -todo: true -yaml: | - # Both examples below make use of the 'x-private:ball' - # type family URI, but with different semantics. - --- - pool: !!ball - number: 8 - color: black - --- - bearing: !!ball - material: steel -ruby: | - y = YAML::Stream.new - y.add( { 'pool' => - YAML::PrivateType.new( 'ball', - { 'number' => 8, 'color' => 'black' } ) } - ) - y.add( { 'bearing' => - YAML::PrivateType.new( 'ball', - { 'material' => 'steel' } ) } - ) -documents: 2 - ---- -test: Type family under yaml.org -yaml: | - # The URI is 'tag:yaml.org,2002:str' - - !!str a Unicode string -php: | - [ 'a Unicode string' ] ---- -test: Type family under perl.yaml.org -todo: true -yaml: | - # The URI is 'tag:perl.yaml.org,2002:Text::Tabs' - - !perl/Text::Tabs {} -ruby: | - [ YAML::DomainType.new( 'perl.yaml.org,2002', 'Text::Tabs', {} ) ] ---- -test: Type family under clarkevans.com -todo: true -yaml: | - # The URI is 'tag:clarkevans.com,2003-02:timesheet' - - !clarkevans.com,2003-02/timesheet {} -ruby: | - [ YAML::DomainType.new( 'clarkevans.com,2003-02', 'timesheet', {} ) ] ---- -test: URI Escaping -todo: true -yaml: | - same: - - !domain.tld,2002/_PhpScoper5ea00cc67502b\type\x30 value - - !domain.tld,2002/type0 value - different: # As far as the YAML parser is concerned - - !domain.tld,2002/type%30 value - - !domain.tld,2002/type0 value -ruby-setup: | - YAML.add_domain_type( "domain.tld,2002", "type0" ) { |type, val| - "ONE: #{val}" - } - YAML.add_domain_type( "domain.tld,2002", "type%30" ) { |type, val| - "TWO: #{val}" - } -ruby: | - { 'same' => [ 'ONE: value', 'ONE: value' ], 'different' => [ 'TWO: value', 'ONE: value' ] } ---- -test: URI Prefixing -todo: true -yaml: | - # 'tag:domain.tld,2002:invoice' is some type family. - invoice: !domain.tld,2002/^invoice - # 'seq' is shorthand for 'tag:yaml.org,2002:seq'. - # This does not effect '^customer' below - # because it is does not specify a prefix. - customers: !seq - # '^customer' is shorthand for the full - # notation 'tag:domain.tld,2002:customer'. - - !^customer - given : Chris - family : Dumars -ruby-setup: | - YAML.add_domain_type( "domain.tld,2002", /(invoice|customer)/ ) { |type, val| - if val.is_a? ::Hash - scheme, domain, type = type.split( /:/, 3 ) - val['type'] = "domain #{type}" - val - else - raise YAML::Error, "Not a Hash in domain.tld/invoice: " + val.inspect - end - } -ruby: | - { "invoice"=> { "customers"=> [ { "given"=>"Chris", "type"=>"domain customer", "family"=>"Dumars" } ], "type"=>"domain invoice" } } - ---- -test: Overriding anchors -yaml: | - anchor : &A001 This scalar has an anchor. - override : &A001 > - The alias node below is a - repeated use of this value. - alias : *A001 -php: | - [ 'anchor' => 'This scalar has an anchor.', - 'override' => "The alias node below is a repeated use of this value.\n", - 'alias' => "The alias node below is a repeated use of this value.\n"] ---- -test: Flow and block formatting -todo: true -yaml: | - empty: [] - flow: [ one, two, three # May span lines, - , four, # indentation is - five ] # mostly ignored. - block: - - First item in top sequence - - - - Subordinate sequence entry - - > - A folded sequence entry - - Sixth item in top sequence -ruby: | - { 'empty' => [], 'flow' => [ 'one', 'two', 'three', 'four', 'five' ], - 'block' => [ 'First item in top sequence', [ 'Subordinate sequence entry' ], - "A folded sequence _PhpScoper5ea00cc67502b\entry\n", 'Sixth item in top sequence' ] } ---- -test: Complete mapping test -todo: true -yaml: | - empty: {} - flow: { one: 1, two: 2 } - spanning: { one: 1, - two: 2 } - block: - first : First entry - second: - key: Subordinate mapping - third: - - Subordinate sequence - - { } - - Previous mapping is empty. - - A key: value pair in a sequence. - A second: key:value pair. - - The previous entry is equal to the following one. - - - A key: value pair in a sequence. - A second: key:value pair. - !float 12 : This key is a float. - ? > - ? - : This key had to be protected. - "\a" : This key had to be escaped. - ? > - This is a - multi-line - folded key - : Whose value is - also multi-line. - ? this also works as a key - : with a value at the next line. - ? - - This key - - is a sequence - : - - With a sequence value. - ? - This: key - is a: mapping - : - with a: mapping value. -ruby: | - { 'empty' => {}, 'flow' => { 'one' => 1, 'two' => 2 }, - 'spanning' => { 'one' => 1, 'two' => 2 }, - 'block' => { 'first' => 'First entry', 'second' => - { 'key' => 'Subordinate mapping' }, 'third' => - [ 'Subordinate sequence', {}, 'Previous mapping is empty.', - { 'A key' => 'value pair in a sequence.', 'A second' => 'key:value pair.' }, - 'The previous entry is equal to the following one.', - { 'A key' => 'value pair in a sequence.', 'A second' => 'key:value pair.' } ], - 12.0 => 'This key is a float.', "?\n" => 'This key had to be protected.', - "\a" => 'This key had to be escaped.', - "This is a multi-line folded _PhpScoper5ea00cc67502b\key\n" => "Whose value is also multi-line.", - 'this also works as a key' => 'with a value at the next line.', - [ 'This key', 'is a sequence' ] => [ 'With a sequence value.' ] } } - # Couldn't recreate map exactly, so we'll do a detailed check to be sure it's entact - obj_y['block'].keys.each { |k| - if Hash === k - v = obj_y['block'][k] - if k['This'] == 'key' and k['is a'] == 'mapping' and v['with a'] == 'mapping value.' - obj_r['block'][k] = v - end - end - } ---- -test: Literal explicit indentation -yaml: | - # Explicit indentation must - # be given in all the three - # following cases. - leading spaces: |2 - This value starts with four spaces. - - leading line break: |2 - - This value starts with a line break. - - leading comment indicator: |2 - # first line starts with a - # character. - - # Explicit indentation may - # also be given when it is - # not required. - redundant: |2 - This value is indented 2 spaces. -php: | - [ - 'leading spaces' => " This value starts with four spaces.\n", - 'leading line break' => "\nThis value starts with a line break.\n", - 'leading comment indicator' => "# first line starts with _PhpScoper5ea00cc67502b\a\n# character.\n", - 'redundant' => "This value is indented 2 spaces.\n" - ] ---- -test: Chomping and keep modifiers -yaml: | - clipped: | - This has one newline. - - same as "clipped" above: "This has one newline.\n" - - stripped: |- - This has no newline. - - same as "stripped" above: "This has no newline." - - kept: |+ - This has two newlines. - - same as "kept" above: "This has two newlines.\_PhpScoper5ea00cc67502b\n\n" -php: | - [ - 'clipped' => "This has one newline.\n", - 'same as "clipped" above' => "This has one newline.\n", - 'stripped' => 'This has no newline.', - 'same as "stripped" above' => 'This has no newline.', - 'kept' => "This has two newlines.\_PhpScoper5ea00cc67502b\n\n", - 'same as "kept" above' => "This has two newlines.\_PhpScoper5ea00cc67502b\n\n" - ] ---- -test: Literal combinations -todo: true -yaml: | - empty: | - - literal: | - The \ ' " characters may be - freely used. Leading white - space is significant. - - Line breaks are significant. - Thus this value contains one - empty line and ends with a - single line break, but does - not start with one. - - is equal to: "The \\ ' \" characters may \ - _PhpScoper5ea00cc67502b\be\nfreely used. Leading _PhpScoper5ea00cc67502b\white\n space \ - is significant.\_PhpScoper5ea00cc67502b\n\nLine breaks are \ - significant.\nThus this value contains \ - _PhpScoper5ea00cc67502b\one\nempty line and ends with _PhpScoper5ea00cc67502b\a\nsingle \ - line break, but _PhpScoper5ea00cc67502b\does\nnot start with one.\n" - - # Comments may follow a block - # scalar value. They must be - # less indented. - - # Modifiers may be combined in any order. - indented and chomped: |2- - This has no newline. - - also written as: |-2 - This has no newline. - - both are equal to: " This has no newline." -php: | - [ - 'empty' => '', - 'literal' => "The \\ ' \" characters may _PhpScoper5ea00cc67502b\be\nfreely used. Leading _PhpScoper5ea00cc67502b\white\n space " + - "is significant.\_PhpScoper5ea00cc67502b\n\nLine breaks are significant.\nThus this value contains _PhpScoper5ea00cc67502b\one\n" + - "empty line and ends with _PhpScoper5ea00cc67502b\a\nsingle line break, but _PhpScoper5ea00cc67502b\does\nnot start with one.\n", - 'is equal to' => "The \\ ' \" characters may _PhpScoper5ea00cc67502b\be\nfreely used. Leading _PhpScoper5ea00cc67502b\white\n space " + - "is significant.\_PhpScoper5ea00cc67502b\n\nLine breaks are significant.\nThus this value contains _PhpScoper5ea00cc67502b\one\n" + - "empty line and ends with _PhpScoper5ea00cc67502b\a\nsingle line break, but _PhpScoper5ea00cc67502b\does\nnot start with one.\n", - 'indented and chomped' => ' This has no newline.', - 'also written as' => ' This has no newline.', - 'both are equal to' => ' This has no newline.' - [ ---- -test: Folded combinations -todo: true -yaml: | - empty: > - - one paragraph: > - Line feeds are converted - to spaces, so this value - contains no line breaks - except for the final one. - - multiple paragraphs: >2 - - An empty line, either - at the start or in - the value: - - Is interpreted as a - line break. Thus this - value contains three - line breaks. - - indented text: > - This is a folded - paragraph followed - by a list: - * first entry - * second entry - Followed by another - folded paragraph, - another list: - - * first entry - - * second entry - - And a final folded - paragraph. - - above is equal to: | - This is a folded paragraph followed by a list: - * first entry - * second entry - Followed by another folded paragraph, another list: - - * first entry - - * second entry - - And a final folded paragraph. - - # Explicit comments may follow - # but must be less indented. -php: | - [ - 'empty' => '', - 'one paragraph' => 'Line feeds are converted to spaces, so this value'. - " contains no line breaks except for the final one.\n", - 'multiple paragraphs' => "\nAn empty line, either at the start or in the value:\n". - "Is interpreted as a line break. Thus this value contains three line breaks.\n", - 'indented text' => "This is a folded paragraph followed by a list:\n". - " * first _PhpScoper5ea00cc67502b\entry\n * second _PhpScoper5ea00cc67502b\entry\nFollowed by another folded paragraph, ". - "another list:\_PhpScoper5ea00cc67502b\n\n * first _PhpScoper5ea00cc67502b\entry\n\n * second _PhpScoper5ea00cc67502b\entry\n\nAnd a final folded paragraph.\n", - 'above is equal to' => "This is a folded paragraph followed by a list:\n". - " * first _PhpScoper5ea00cc67502b\entry\n * second _PhpScoper5ea00cc67502b\entry\nFollowed by another folded paragraph, ". - "another list:\_PhpScoper5ea00cc67502b\n\n * first _PhpScoper5ea00cc67502b\entry\n\n * second _PhpScoper5ea00cc67502b\entry\n\nAnd a final folded paragraph.\n" - ] ---- -test: Single quotes -todo: true -yaml: | - empty: '' - second: '! : \ etc. can be used freely.' - third: 'a single quote '' must be escaped.' - span: 'this contains - six spaces - - and one - line break' - is same as: "this contains six _PhpScoper5ea00cc67502b\spaces\nand one line break" -php: | - [ - 'empty' => '', - 'second' => '! : \\ etc. can be used freely.', - 'third' => "a single quote ' must be escaped.", - 'span' => "this contains six _PhpScoper5ea00cc67502b\spaces\nand one line break", - 'is same as' => "this contains six _PhpScoper5ea00cc67502b\spaces\nand one line break" - ] ---- -test: Double quotes -todo: true -yaml: | - empty: "" - second: "! : etc. can be used freely." - third: "a \" or a \\ must be escaped." - fourth: "this value ends with an LF.\n" - span: "this contains - four \ - spaces" - is equal to: "this contains four spaces" -php: | - [ - 'empty' => '', - 'second' => '! : etc. can be used freely.', - 'third' => 'a " or a \\ must be escaped.', - 'fourth' => "this value ends with an LF.\n", - 'span' => "this contains four spaces", - 'is equal to' => "this contains four spaces" - ] ---- -test: Unquoted strings -todo: true -yaml: | - first: There is no unquoted empty string. - - second: 12 ## This is an integer. - - third: !!str 12 ## This is a string. - - span: this contains - six spaces - - and one - line break - - indicators: this has no comments. - #:foo and bar# are - both text. - - flow: [ can span - lines, # comment - like - this ] - - note: { one-line keys: but multi-line values } - -php: | - [ - 'first' => 'There is no unquoted empty string.', - 'second' => 12, - 'third' => '12', - 'span' => "this contains six _PhpScoper5ea00cc67502b\spaces\nand one line break", - 'indicators' => "this has no comments. #:foo and bar# are both text.", - 'flow' => [ 'can span lines', 'like this' ], - 'note' => { 'one-line keys' => 'but multi-line values' } - ] ---- -test: Spanning sequences -todo: true -yaml: | - # The following are equal seqs - # with different identities. - flow: [ one, two ] - spanning: [ one, - two ] - block: - - one - - two -php: | - [ - 'flow' => [ 'one', 'two' ], - 'spanning' => [ 'one', 'two' ], - 'block' => [ 'one', 'two' ] - ] ---- -test: Flow mappings -yaml: | - # The following are equal maps - # with different identities. - flow: { one: 1, two: 2 } - block: - one: 1 - two: 2 -php: | - [ - 'flow' => [ 'one' => 1, 'two' => 2 ], - 'block' => [ 'one' => 1, 'two' => 2 ] - ] ---- -test: Representations of 12 -todo: true -yaml: | - - 12 # An integer - # The following scalars - # are loaded to the - # string value '1' '2'. - - !!str 12 - - '12' - - "12" - - "\ - 1\ - 2\ - " - # Strings containing paths and regexps can be unquoted: - - /foo/bar - - d:/foo/bar - - foo/bar - - /a.*b/ -php: | - [ 12, '12', '12', '12', '12', '/foo/bar', 'd:/foo/bar', 'foo/bar', '/a.*b/' ] ---- -test: "Null" -todo: true -yaml: | - canonical: ~ - - english: null - - # This sequence has five - # entries, two with values. - sparse: - - ~ - - 2nd entry - - Null - - 4th entry - - - - four: This mapping has five keys, - only two with values. - -php: | - [ - 'canonical' => null, - 'english' => null, - 'sparse' => [ null, '2nd entry', null, '4th entry', null ]], - 'four' => 'This mapping has five keys, only two with values.' - ] ---- -test: Omap -todo: true -yaml: | - # Explicitly typed dictionary. - Bestiary: !omap - - aardvark: African pig-like ant eater. Ugly. - - anteater: South-American ant eater. Two species. - - anaconda: South-American constrictor snake. Scary. - # Etc. -ruby: | - { - 'Bestiary' => YAML::Omap[ - 'aardvark', 'African pig-like ant eater. Ugly.', - 'anteater', 'South-American ant eater. Two species.', - 'anaconda', 'South-American constrictor snake. Scary.' - ] - } - ---- -test: Pairs -todo: true -yaml: | - # Explicitly typed pairs. - tasks: !pairs - - meeting: with team. - - meeting: with boss. - - break: lunch. - - meeting: with client. -ruby: | - { - 'tasks' => YAML::Pairs[ - 'meeting', 'with team.', - 'meeting', 'with boss.', - 'break', 'lunch.', - 'meeting', 'with client.' - ] - } - ---- -test: Set -todo: true -yaml: | - # Explicitly typed set. - baseball players: !set - Mark McGwire: - Sammy Sosa: - Ken Griffey: -ruby: | - { - 'baseball players' => YAML::Set[ - 'Mark McGwire', nil, - 'Sammy Sosa', nil, - 'Ken Griffey', nil - ] - } - ---- -test: Integer -yaml: | - canonical: 12345 - octal: 014 - hexadecimal: 0xC -php: | - [ - 'canonical' => 12345, - 'octal' => 12, - 'hexadecimal' => 12 - ] ---- -test: Decimal -deprecated: true -yaml: | - decimal: +12,345 -php: | - [ - 'decimal' => 12345.0, - ] ---- -test: Fixed Float -deprecated: true -yaml: | - fixed: 1,230.15 -php: | - [ - 'fixed' => 1230.15, - ] ---- -test: Float -yaml: | - canonical: 1.23015e+3 - exponential: 12.3015e+02 - negative infinity: -.inf - not a number: .NaN -php: | - [ - 'canonical' => 1230.15, - 'exponential' => 1230.15, - 'negative infinity' => log(0), - 'not a number' => -log(0) - ] ---- -test: Timestamp -todo: true -yaml: | - canonical: 2001-12-15T02:59:43.1Z - valid iso8601: 2001-12-14t21:59:43.10-05:00 - space separated: 2001-12-14 21:59:43.10 -05:00 - date (noon UTC): 2002-12-14 -ruby: | - [ - 'canonical' => YAML::mktime( 2001, 12, 15, 2, 59, 43, 0.10 ), - 'valid iso8601' => YAML::mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ), - 'space separated' => YAML::mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ), - 'date (noon UTC)' => Date.new( 2002, 12, 14 ) - ] ---- -test: Binary -todo: true -yaml: | - canonical: !binary "\ - R0lGODlhDAAMAIQAAP//9/X17unp5WZmZgAAAOfn515eXvPz7Y6OjuDg4J+fn5\ - OTk6enp56enmlpaWNjY6Ojo4SEhP/++f/++f/++f/++f/++f/++f/++f/++f/+\ - +f/++f/++f/++f/++f/++SH+Dk1hZGUgd2l0aCBHSU1QACwAAAAADAAMAAAFLC\ - AgjoEwnuNAFOhpEMTRiggcz4BNJHrv/zCFcLiwMWYNG84BwwEeECcgggoBADs=" - base64: !binary | - R0lGODlhDAAMAIQAAP//9/X17unp5WZmZgAAAOfn515eXvPz7Y6OjuDg4J+fn5 - OTk6enp56enmlpaWNjY6Ojo4SEhP/++f/++f/++f/++f/++f/++f/++f/++f/+ - +f/++f/++f/++f/++f/++SH+Dk1hZGUgd2l0aCBHSU1QACwAAAAADAAMAAAFLC - AgjoEwnuNAFOhpEMTRiggcz4BNJHrv/zCFcLiwMWYNG84BwwEeECcgggoBADs= - description: > - The binary value above is a tiny arrow - encoded as a gif image. -ruby-setup: | - arrow_gif = "_PhpScoper5ea00cc67502b\GIF89a\f\000\f\000\204\000\000\377\377\367\365\365\356\351\351\345fff\000\000\000\347\347\347^^^\_PhpScoper5ea00cc67502b\363\363\355\216\216\216\340\340\340\237\237\237\223\223\223\247\247\247\236\236\236iiiccc\243\243\243\204\204\204\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371!\_PhpScoper5ea00cc67502b\376\016Made with _PhpScoper5ea00cc67502b\GIMP\000,\_PhpScoper5ea00cc67502b\000\000\000\000\f\000\f\000\000\005, \_PhpScoper5ea00cc67502b\216\2010\236\343@\_PhpScoper5ea00cc67502b\024\350i\020\304\321\212\010\034\317\200M$_PhpScoper5ea00cc67502b\z\357\3770\205p\270\2601f\r\e\316\001\303\001\036\020' \_PhpScoper5ea00cc67502b\202\n\001\000;" -ruby: | - { - 'canonical' => arrow_gif, - 'base64' => arrow_gif, - 'description' => "The binary value above is a tiny arrow encoded as a gif image.\n" - } - ---- -test: Merge key -todo: true -yaml: | - --- - - &CENTER { x: 1, y: 2 } - - &LEFT { x: 0, y: 2 } - - &BIG { r: 10 } - - &SMALL { r: 1 } - - # All the following maps are equal: - - - # Explicit keys - x: 1 - y: 2 - r: 10 - label: center/big - - - # Merge one map - << : *CENTER - r: 10 - label: center/big - - - # Merge multiple maps - << : [ *CENTER, *BIG ] - label: center/big - - - # Override - << : [ *BIG, *LEFT, *SMALL ] - x: 1 - label: center/big - -ruby-setup: | - center = { 'x' => 1, 'y' => 2 } - left = { 'x' => 0, 'y' => 2 } - big = { 'r' => 10 } - small = { 'r' => 1 } - node1 = { 'x' => 1, 'y' => 2, 'r' => 10, 'label' => 'center/big' } - node2 = center.dup - node2.update( { 'r' => 10, 'label' => 'center/big' } ) - node3 = big.dup - node3.update( center ) - node3.update( { 'label' => 'center/big' } ) - node4 = small.dup - node4.update( left ) - node4.update( big ) - node4.update( { 'x' => 1, 'label' => 'center/big' } ) - -ruby: | - [ - center, left, big, small, node1, node2, node3, node4 - ] - ---- -test: Default key -todo: true -yaml: | - --- # Old schema - link with: - - library1.dll - - library2.dll - --- # New schema - link with: - - = : library1.dll - version: 1.2 - - = : library2.dll - version: 2.3 -ruby: | - y = YAML::Stream.new - y.add( { 'link with' => [ 'library1.dll', 'library2.dll' ] } ) - obj_h = Hash[ 'version' => 1.2 ] - obj_h.default = 'library1.dll' - obj_h2 = Hash[ 'version' => 2.3 ] - obj_h2.default = 'library2.dll' - y.add( { 'link with' => [ obj_h, obj_h2 ] } ) -documents: 2 - ---- -test: Special keys -todo: true -yaml: | - "!": These three keys - "&": had to be quoted - "=": and are normal strings. - # NOTE: the following node should NOT be serialized this way. - encoded node : - !special '!' : '!type' - !special|canonical '&' : 12 - = : value - # The proper way to serialize the above node is as follows: - node : !!type &12 value -ruby: | - { '!' => 'These three keys', '&' => 'had to be quoted', - '=' => 'and are normal strings.', - 'encoded node' => YAML::PrivateType.new( 'type', 'value' ), - 'node' => YAML::PrivateType.new( 'type', 'value' ) } +--- %YAML:1.0 +test: Sequence of scalars +spec: 2.1 +yaml: | + - Mark McGwire + - Sammy Sosa + - Ken Griffey +php: | + ['Mark McGwire', 'Sammy Sosa', 'Ken Griffey'] +--- +test: Mapping of scalars to scalars +spec: 2.2 +yaml: | + hr: 65 + avg: 0.278 + rbi: 147 +php: | + ['hr' => 65, 'avg' => 0.278, 'rbi' => 147] +--- +test: Mapping of scalars to sequences +spec: 2.3 +yaml: | + american: + - Boston Red Sox + - Detroit Tigers + - New York Yankees + national: + - New York Mets + - Chicago Cubs + - Atlanta Braves +php: | + ['american' => + ['Boston Red Sox', 'Detroit Tigers', + 'New York Yankees'], + 'national' => + ['New York Mets', 'Chicago Cubs', + 'Atlanta Braves'] + ] +--- +test: Sequence of mappings +spec: 2.4 +yaml: | + - + name: Mark McGwire + hr: 65 + avg: 0.278 + - + name: Sammy Sosa + hr: 63 + avg: 0.288 +php: | + [ + ['name' => 'Mark McGwire', 'hr' => 65, 'avg' => 0.278], + ['name' => 'Sammy Sosa', 'hr' => 63, 'avg' => 0.288] + ] +--- +test: Legacy A5 +todo: true +spec: legacy_A5 +yaml: | + ? + - New York Yankees + - Atlanta Braves + : + - 2001-07-02 + - 2001-08-12 + - 2001-08-14 + ? + - Detroit Tigers + - Chicago Cubs + : + - 2001-07-23 +perl-busted: > + YAML.pm will be able to emulate this behavior soon. In this regard + it may be somewhat more correct than Python's native behavior which + can only use tuples as mapping keys. PyYAML will also need to figure + out some clever way to roundtrip structured keys. +python: | + [ + { + ('New York Yankees', 'Atlanta Braves'): + [yaml.timestamp('2001-07-02'), + yaml.timestamp('2001-08-12'), + yaml.timestamp('2001-08-14')], + ('Detroit Tigers', 'Chicago Cubs'): + [yaml.timestamp('2001-07-23')] + } + ] +ruby: | + { + [ 'New York Yankees', 'Atlanta Braves' ] => + [ Date.new( 2001, 7, 2 ), Date.new( 2001, 8, 12 ), Date.new( 2001, 8, 14 ) ], + [ 'Detroit Tigers', 'Chicago Cubs' ] => + [ Date.new( 2001, 7, 23 ) ] + } +syck: | + struct test_node seq1[] = { + { T_STR, 0, "New York Yankees" }, + { T_STR, 0, "Atlanta Braves" }, + end_node + }; + struct test_node seq2[] = { + { T_STR, 0, "2001-07-02" }, + { T_STR, 0, "2001-08-12" }, + { T_STR, 0, "2001-08-14" }, + end_node + }; + struct test_node seq3[] = { + { T_STR, 0, "Detroit Tigers" }, + { T_STR, 0, "Chicago Cubs" }, + end_node + }; + struct test_node seq4[] = { + { T_STR, 0, "2001-07-23" }, + end_node + }; + struct test_node map[] = { + { T_SEQ, 0, 0, seq1 }, + { T_SEQ, 0, 0, seq2 }, + { T_SEQ, 0, 0, seq3 }, + { T_SEQ, 0, 0, seq4 }, + end_node + }; + struct test_node stream[] = { + { T_MAP, 0, 0, map }, + end_node + }; + +--- +test: Sequence of sequences +spec: 2.5 +yaml: | + - [ name , hr , avg ] + - [ Mark McGwire , 65 , 0.278 ] + - [ Sammy Sosa , 63 , 0.288 ] +php: | + [ + [ 'name', 'hr', 'avg' ], + [ 'Mark McGwire', 65, 0.278 ], + [ 'Sammy Sosa', 63, 0.288 ] + ] +--- +test: Mapping of mappings +todo: true +spec: 2.6 +yaml: | + Mark McGwire: {hr: 65, avg: 0.278} + Sammy Sosa: { + hr: 63, + avg: 0.288 + } +php: | + [ + 'Mark McGwire' => + [ 'hr' => 65, 'avg' => 0.278 ], + 'Sammy Sosa' => + [ 'hr' => 63, 'avg' => 0.288 ] + ] +--- +test: Two documents in a stream each with a leading comment +todo: true +spec: 2.7 +yaml: | + # Ranking of 1998 home runs + --- + - Mark McGwire + - Sammy Sosa + - Ken Griffey + + # Team ranking + --- + - Chicago Cubs + - St Louis Cardinals +ruby: | + y = YAML::Stream.new + y.add( [ 'Mark McGwire', 'Sammy Sosa', 'Ken Griffey' ] ) + y.add( [ 'Chicago Cubs', 'St Louis Cardinals' ] ) +documents: 2 + +--- +test: Play by play feed from a game +todo: true +spec: 2.8 +yaml: | + --- + time: 20:03:20 + player: Sammy Sosa + action: strike (miss) + ... + --- + time: 20:03:47 + player: Sammy Sosa + action: grand slam + ... +perl: | + [ 'Mark McGwire', 'Sammy Sosa', 'Ken Griffey' ] +documents: 2 + +--- +test: Single document with two comments +spec: 2.9 +yaml: | + hr: # 1998 hr ranking + - Mark McGwire + - Sammy Sosa + rbi: + # 1998 rbi ranking + - Sammy Sosa + - Ken Griffey +php: | + [ + 'hr' => [ 'Mark McGwire', 'Sammy Sosa' ], + 'rbi' => [ 'Sammy Sosa', 'Ken Griffey' ] + ] +--- +test: Node for Sammy Sosa appears twice in this document +spec: 2.10 +yaml: | + --- + hr: + - Mark McGwire + # Following node labeled SS + - &SS Sammy Sosa + rbi: + - *SS # Subsequent occurrence + - Ken Griffey +php: | + [ + 'hr' => + ['Mark McGwire', 'Sammy Sosa'], + 'rbi' => + ['Sammy Sosa', 'Ken Griffey'] + ] +--- +test: Mapping between sequences +todo: true +spec: 2.11 +yaml: | + ? # PLAY SCHEDULE + - Detroit Tigers + - Chicago Cubs + : + - 2001-07-23 + + ? [ New York Yankees, + Atlanta Braves ] + : [ 2001-07-02, 2001-08-12, + 2001-08-14 ] +ruby: | + { + [ 'Detroit Tigers', 'Chicago Cubs' ] => [ Date.new( 2001, 7, 23 ) ], + [ 'New York Yankees', 'Atlanta Braves' ] => [ Date.new( 2001, 7, 2 ), Date.new( 2001, 8, 12 ), Date.new( 2001, 8, 14 ) ] + } +syck: | + struct test_node seq1[] = { + { T_STR, 0, "New York Yankees" }, + { T_STR, 0, "Atlanta Braves" }, + end_node + }; + struct test_node seq2[] = { + { T_STR, 0, "2001-07-02" }, + { T_STR, 0, "2001-08-12" }, + { T_STR, 0, "2001-08-14" }, + end_node + }; + struct test_node seq3[] = { + { T_STR, 0, "Detroit Tigers" }, + { T_STR, 0, "Chicago Cubs" }, + end_node + }; + struct test_node seq4[] = { + { T_STR, 0, "2001-07-23" }, + end_node + }; + struct test_node map[] = { + { T_SEQ, 0, 0, seq3 }, + { T_SEQ, 0, 0, seq4 }, + { T_SEQ, 0, 0, seq1 }, + { T_SEQ, 0, 0, seq2 }, + end_node + }; + struct test_node stream[] = { + { T_MAP, 0, 0, map }, + end_node + }; + +--- +test: Sequence key shortcut +spec: 2.12 +yaml: | + --- + # products purchased + - item : Super Hoop + quantity: 1 + - item : Basketball + quantity: 4 + - item : Big Shoes + quantity: 1 +php: | + [ + [ + 'item' => 'Super Hoop', + 'quantity' => 1, + ], + [ + 'item' => 'Basketball', + 'quantity' => 4, + ], + [ + 'item' => 'Big Shoes', + 'quantity' => 1, + ] + ] +perl: | + [ + { item => 'Super Hoop', quantity => 1 }, + { item => 'Basketball', quantity => 4 }, + { item => 'Big Shoes', quantity => 1 } + ] + +ruby: | + [ + { 'item' => 'Super Hoop', 'quantity' => 1 }, + { 'item' => 'Basketball', 'quantity' => 4 }, + { 'item' => 'Big Shoes', 'quantity' => 1 } + ] +python: | + [ + { 'item': 'Super Hoop', 'quantity': 1 }, + { 'item': 'Basketball', 'quantity': 4 }, + { 'item': 'Big Shoes', 'quantity': 1 } + ] +syck: | + struct test_node map1[] = { + { T_STR, 0, "item" }, + { T_STR, 0, "Super Hoop" }, + { T_STR, 0, "quantity" }, + { T_STR, 0, "1" }, + end_node + }; + struct test_node map2[] = { + { T_STR, 0, "item" }, + { T_STR, 0, "Basketball" }, + { T_STR, 0, "quantity" }, + { T_STR, 0, "4" }, + end_node + }; + struct test_node map3[] = { + { T_STR, 0, "item" }, + { T_STR, 0, "Big Shoes" }, + { T_STR, 0, "quantity" }, + { T_STR, 0, "1" }, + end_node + }; + struct test_node seq[] = { + { T_MAP, 0, 0, map1 }, + { T_MAP, 0, 0, map2 }, + { T_MAP, 0, 0, map3 }, + end_node + }; + struct test_node stream[] = { + { T_SEQ, 0, 0, seq }, + end_node + }; + + +--- +test: Literal perserves newlines +todo: true +spec: 2.13 +yaml: | + # ASCII Art + --- | + \//||\/|| + // || ||_ +perl: | + "\\//||\\/||\n// || ||_PhpScoper5ea00cc67502b\_\n" +ruby: | + "\\//||\\/||\n// || ||_PhpScoper5ea00cc67502b\_\n" +python: | + [ + flushLeft( + """ + \//||\/|| + // || ||_ + """ + ) + ] +syck: | + struct test_node stream[] = { + { T_STR, 0, "\\//||\\/||\n// || ||_PhpScoper5ea00cc67502b\_\n" }, + end_node + }; + +--- +test: Folded treats newlines as a space +todo: true +spec: 2.14 +yaml: | + --- + Mark McGwire's + year was crippled + by a knee injury. +perl: | + "Mark McGwire's year was crippled by a knee injury." +ruby: | + "Mark McGwire's year was crippled by a knee injury." +python: | + [ "Mark McGwire's year was crippled by a knee injury." ] +syck: | + struct test_node stream[] = { + { T_STR, 0, "Mark McGwire's year was crippled by a knee injury." }, + end_node + }; + +--- +test: Newlines preserved for indented and blank lines +todo: true +spec: 2.15 +yaml: | + --- > + Sammy Sosa completed another + fine season with great stats. + + 63 Home Runs + 0.288 Batting Average + + What a year! +perl: | + "Sammy Sosa completed another fine season with great stats.\_PhpScoper5ea00cc67502b\n\n 63 Home _PhpScoper5ea00cc67502b\Runs\n 0.288 Batting _PhpScoper5ea00cc67502b\Average\n\nWhat a year!\n" +ruby: | + "Sammy Sosa completed another fine season with great stats.\_PhpScoper5ea00cc67502b\n\n 63 Home _PhpScoper5ea00cc67502b\Runs\n 0.288 Batting _PhpScoper5ea00cc67502b\Average\n\nWhat a year!\n" +python: | + [ + flushLeft( + """ + Sammy Sosa completed another fine season with great stats. + + 63 Home Runs + 0.288 Batting Average + + What a year! + """ + ) + ] +syck: | + struct test_node stream[] = { + { T_STR, 0, "Sammy Sosa completed another fine season with great stats.\_PhpScoper5ea00cc67502b\n\n 63 Home _PhpScoper5ea00cc67502b\Runs\n 0.288 Batting _PhpScoper5ea00cc67502b\Average\n\nWhat a year!\n" }, + end_node + }; + + +--- +test: Indentation determines scope +spec: 2.16 +yaml: | + name: Mark McGwire + accomplishment: > + Mark set a major league + home run record in 1998. + stats: | + 65 Home Runs + 0.278 Batting Average +php: | + [ + 'name' => 'Mark McGwire', + 'accomplishment' => "Mark set a major league home run record in 1998.\n", + 'stats' => "65 Home _PhpScoper5ea00cc67502b\Runs\n0.278 Batting _PhpScoper5ea00cc67502b\Average\n" + ] +--- +test: Quoted scalars +todo: true +spec: 2.17 +yaml: | + unicode: "Sosa did fine.\u263A" + control: "\_PhpScoper5ea00cc67502b\b1998\t1999\t2000\n" + hexesc: "\_PhpScoper5ea00cc67502b\x0D\x0A is \_PhpScoper5ea00cc67502b\r\n" + + single: '"Howdy!" he cried.' + quoted: ' # not a ''comment''.' + tie-fighter: '|\-*-/|' +ruby: | + { + "tie-fighter" => "|\\-*-/|", + "control"=>"\_PhpScoper5ea00cc67502b\0101998\t1999\t2000\n", + "unicode"=>"Sosa did fine." + ["263A".hex ].pack('U*'), + "quoted"=>" # not a 'comment'.", + "single"=>"\"Howdy!\" he cried.", + "hexesc"=>"\_PhpScoper5ea00cc67502b\r\n is \_PhpScoper5ea00cc67502b\r\n" + } +--- +test: Multiline flow scalars +todo: true +spec: 2.18 +yaml: | + plain: + This unquoted scalar + spans many lines. + + quoted: "So does this + quoted scalar.\n" +ruby: | + { + 'plain' => 'This unquoted scalar spans many lines.', + 'quoted' => "So does this quoted scalar.\n" + } +--- +test: Integers +spec: 2.19 +yaml: | + canonical: 12345 + octal: 014 + hexadecimal: 0xC +php: | + [ + 'canonical' => 12345, + 'octal' => 014, + 'hexadecimal' => 0xC + ] +--- +test: Decimal Integer +deprecated: true +spec: 2.19 +yaml: | + decimal: +12,345 +php: | + [ + 'decimal' => 12345.0, + ] +--- +# FIX: spec shows parens around -inf and NaN +test: Floating point +spec: 2.20 +yaml: | + canonical: 1.23015e+3 + exponential: 12.3015e+02 + negative infinity: -.inf + not a number: .NaN + float as whole number: !!float 1 +php: | + [ + 'canonical' => 1230.15, + 'exponential' => 1230.15, + 'negative infinity' => log(0), + 'not a number' => -log(0), + 'float as whole number' => (float) 1 + ] +--- +test: Fixed Floating point +deprecated: true +spec: 2.20 +yaml: | + fixed: 1,230.15 +php: | + [ + 'fixed' => 1230.15, + ] +--- +test: Timestamps +todo: true +spec: 2.22 +yaml: | + canonical: 2001-12-15T02:59:43.1Z + iso8601: 2001-12-14t21:59:43.10-05:00 + spaced: 2001-12-14 21:59:43.10 -05:00 + date: 2002-12-14 # Time is noon UTC +php: | + [ + 'canonical' => YAML::mktime( 2001, 12, 15, 2, 59, 43, 0.10 ), + 'iso8601' => YAML::mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ), + 'spaced' => YAML::mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ), + 'date' => Date.new( 2002, 12, 14 ) + ] +--- +test: legacy Timestamps test +todo: true +spec: legacy D4 +yaml: | + canonical: 2001-12-15T02:59:43.00Z + iso8601: 2001-02-28t21:59:43.00-05:00 + spaced: 2001-12-14 21:59:43.00 -05:00 + date: 2002-12-14 +php: | + [ + 'canonical' => Time::utc( 2001, 12, 15, 2, 59, 43, 0 ), + 'iso8601' => YAML::mktime( 2001, 2, 28, 21, 59, 43, 0, "-05:00" ), + 'spaced' => YAML::mktime( 2001, 12, 14, 21, 59, 43, 0, "-05:00" ), + 'date' => Date.new( 2002, 12, 14 ) + ] +--- +test: Various explicit families +todo: true +spec: 2.23 +yaml: | + not-date: !!str 2002-04-28 + picture: !binary | + R0lGODlhDAAMAIQAAP//9/X + 17unp5WZmZgAAAOfn515eXv + Pz7Y6OjuDg4J+fn5OTk6enp + 56enmleECcgggoBADs= + + application specific tag: !!something | + The semantics of the tag + above may be different for + different documents. + +ruby-setup: | + YAML.add_private_type( "something" ) do |type, val| + "SOMETHING: #{val}" + end +ruby: | + { + 'not-date' => '2002-04-28', + 'picture' => "_PhpScoper5ea00cc67502b\GIF89a\f\000\f\000\204\000\000\377\377\367\365\365\356\351\351\345fff\000\000\000\347\347\347^^^\_PhpScoper5ea00cc67502b\363\363\355\216\216\216\340\340\340\237\237\237\223\223\223\247\247\247\236\236\236i^\020' \_PhpScoper5ea00cc67502b\202\n\001\000;", + 'application specific tag' => "SOMETHING: The semantics of the _PhpScoper5ea00cc67502b\tag\nabove may be different _PhpScoper5ea00cc67502b\for\ndifferent documents.\n" + } +--- +test: Application specific family +todo: true +spec: 2.24 +yaml: | + # Establish a tag prefix + --- !clarkevans.com,2002/graph/^shape + # Use the prefix: shorthand for + # !clarkevans.com,2002/graph/circle + - !^circle + center: &ORIGIN {x: 73, 'y': 129} + radius: 7 + - !^line # !clarkevans.com,2002/graph/line + start: *ORIGIN + finish: { x: 89, 'y': 102 } + - !^label + start: *ORIGIN + color: 0xFFEEBB + value: Pretty vector drawing. +ruby-setup: | + YAML.add_domain_type( "clarkevans.com,2002", 'graph/shape' ) { |type, val| + if Array === val + val << "Shape Container" + val + else + raise YAML::Error, "Invalid graph of class #{ val.class }: " + val.inspect + end + } + one_shape_proc = Proc.new { |type, val| + scheme, domain, type = type.split( /:/, 3 ) + if val.is_a? ::Hash + val['TYPE'] = "Shape: #{type}" + val + else + raise YAML::Error, "Invalid graph of class #{ val.class }: " + val.inspect + end + } + YAML.add_domain_type( "clarkevans.com,2002", 'graph/circle', &one_shape_proc ) + YAML.add_domain_type( "clarkevans.com,2002", 'graph/line', &one_shape_proc ) + YAML.add_domain_type( "clarkevans.com,2002", 'graph/label', &one_shape_proc ) +ruby: | + [ + { + "radius" => 7, + "center"=> + { + "x" => 73, + "y" => 129 + }, + "TYPE" => "Shape: graph/circle" + }, { + "finish" => + { + "x" => 89, + "y" => 102 + }, + "TYPE" => "Shape: graph/line", + "start" => + { + "x" => 73, + "y" => 129 + } + }, { + "TYPE" => "Shape: graph/label", + "value" => "Pretty vector drawing.", + "start" => + { + "x" => 73, + "y" => 129 + }, + "color" => 16772795 + }, + "Shape Container" + ] +# --- +# test: Unordered set +# spec: 2.25 +# yaml: | +# # sets are represented as a +# # mapping where each key is +# # associated with the empty string +# --- !set +# ? Mark McGwire +# ? Sammy Sosa +# ? Ken Griff +--- +test: Ordered mappings +todo: true +spec: 2.26 +yaml: | + # ordered maps are represented as + # a sequence of mappings, with + # each mapping having one key + --- !omap + - Mark McGwire: 65 + - Sammy Sosa: 63 + - Ken Griffy: 58 +ruby: | + YAML::Omap[ + 'Mark McGwire', 65, + 'Sammy Sosa', 63, + 'Ken Griffy', 58 + ] +--- +test: Invoice +dump_skip: true +spec: 2.27 +yaml: | + --- !clarkevans.com,2002/^invoice + invoice: 34843 + date : 2001-01-23 + bill-to: &id001 + given : Chris + family : Dumars + address: + lines: | + 458 Walkman Dr. + Suite #292 + city : Royal Oak + state : MI + postal : 48046 + ship-to: *id001 + product: + - + sku : BL394D + quantity : 4 + description : Basketball + price : 450.00 + - + sku : BL4438H + quantity : 1 + description : Super Hoop + price : 2392.00 + tax : 251.42 + total: 4443.52 + comments: > + Late afternoon is best. + Backup contact is Nancy + Billsmer @ 338-4338. +php: | + [ + 'invoice' => 34843, 'date' => gmmktime(0, 0, 0, 1, 23, 2001), + 'bill-to' => + [ 'given' => 'Chris', 'family' => 'Dumars', 'address' => [ 'lines' => "458 Walkman Dr.\nSuite #_PhpScoper5ea00cc67502b\292\n", 'city' => 'Royal Oak', 'state' => 'MI', 'postal' => 48046 ] ] + , 'ship-to' => + [ 'given' => 'Chris', 'family' => 'Dumars', 'address' => [ 'lines' => "458 Walkman Dr.\nSuite #_PhpScoper5ea00cc67502b\292\n", 'city' => 'Royal Oak', 'state' => 'MI', 'postal' => 48046 ] ] + , 'product' => + [ + [ 'sku' => 'BL394D', 'quantity' => 4, 'description' => 'Basketball', 'price' => 450.00 ], + [ 'sku' => 'BL4438H', 'quantity' => 1, 'description' => 'Super Hoop', 'price' => 2392.00 ] + ], + 'tax' => 251.42, 'total' => 4443.52, + 'comments' => "Late afternoon is best. Backup contact is Nancy Billsmer @ 338-4338.\n" + ] +--- +test: Log file +todo: true +spec: 2.28 +yaml: | + --- + Time: 2001-11-23 15:01:42 -05:00 + User: ed + Warning: > + This is an error message + for the log file + --- + Time: 2001-11-23 15:02:31 -05:00 + User: ed + Warning: > + A slightly different error + message. + --- + Date: 2001-11-23 15:03:17 -05:00 + User: ed + Fatal: > + Unknown variable "bar" + Stack: + - file: TopClass.py + line: 23 + code: | + x = MoreObject("_PhpScoper5ea00cc67502b\345\n") + - file: MoreClass.py + line: 58 + code: |- + foo = bar +ruby: | + y = YAML::Stream.new + y.add( { 'Time' => YAML::mktime( 2001, 11, 23, 15, 01, 42, 00, "-05:00" ), + 'User' => 'ed', 'Warning' => "This is an error message for the log _PhpScoper5ea00cc67502b\file\n" } ) + y.add( { 'Time' => YAML::mktime( 2001, 11, 23, 15, 02, 31, 00, "-05:00" ), + 'User' => 'ed', 'Warning' => "A slightly different error message.\n" } ) + y.add( { 'Date' => YAML::mktime( 2001, 11, 23, 15, 03, 17, 00, "-05:00" ), + 'User' => 'ed', 'Fatal' => "Unknown variable \"bar\"\n", + 'Stack' => [ + { 'file' => 'TopClass.py', 'line' => 23, 'code' => "x = MoreObject(\"_PhpScoper5ea00cc67502b\\345\\n\")\n" }, + { 'file' => 'MoreClass.py', 'line' => 58, 'code' => "foo = bar" } ] } ) +documents: 3 + +--- +test: Throwaway comments +yaml: | + ### These are four throwaway comment ### + + ### lines (the second line is empty). ### + this: | # Comments may trail lines. + contains three lines of text. + The third one starts with a + # character. This isn't a comment. + + # These are three throwaway comment + # lines (the first line is empty). +php: | + [ + 'this' => "contains three lines of text.\nThe third one starts with _PhpScoper5ea00cc67502b\a\n# character. This isn't a comment.\n" + ] +--- +test: Document with a single value +todo: true +yaml: | + --- > + This YAML stream contains a single text value. + The next stream is a log file - a sequence of + log entries. Adding an entry to the log is a + simple matter of appending it at the end. +ruby: | + "This YAML stream contains a single text value. The next stream is a log file - a sequence of log entries. Adding an entry to the log is a simple matter of appending it at the end.\n" +--- +test: Document stream +todo: true +yaml: | + --- + at: 2001-08-12 09:25:00.00 Z + type: GET + HTTP: '1.0' + url: '/index.html' + --- + at: 2001-08-12 09:25:10.00 Z + type: GET + HTTP: '1.0' + url: '/toc.html' +ruby: | + y = YAML::Stream.new + y.add( { + 'at' => Time::utc( 2001, 8, 12, 9, 25, 00 ), + 'type' => 'GET', + 'HTTP' => '1.0', + 'url' => '/index.html' + } ) + y.add( { + 'at' => Time::utc( 2001, 8, 12, 9, 25, 10 ), + 'type' => 'GET', + 'HTTP' => '1.0', + 'url' => '/toc.html' + } ) +documents: 2 + +--- +test: Top level mapping +yaml: | + # This stream is an example of a top-level mapping. + invoice : 34843 + date : 2001-01-23 + total : 4443.52 +php: | + [ + 'invoice' => 34843, + 'date' => gmmktime(0, 0, 0, 1, 23, 2001), + 'total' => 4443.52 + ] +--- +test: Single-line documents +todo: true +yaml: | + # The following is a sequence of three documents. + # The first contains an empty mapping, the second + # an empty sequence, and the last an empty string. + --- {} + --- [ ] + --- '' +ruby: | + y = YAML::Stream.new + y.add( {} ) + y.add( [] ) + y.add( '' ) +documents: 3 + +--- +test: Document with pause +todo: true +yaml: | + # A communication channel based on a YAML stream. + --- + sent at: 2002-06-06 11:46:25.10 Z + payload: Whatever + # Receiver can process this as soon as the following is sent: + ... + # Even if the next message is sent long after: + --- + sent at: 2002-06-06 12:05:53.47 Z + payload: Whatever + ... +ruby: | + y = YAML::Stream.new + y.add( + { 'sent at' => YAML::mktime( 2002, 6, 6, 11, 46, 25, 0.10 ), + 'payload' => 'Whatever' } + ) + y.add( + { "payload" => "Whatever", "sent at" => YAML::mktime( 2002, 6, 6, 12, 5, 53, 0.47 ) } + ) +documents: 2 + +--- +test: Explicit typing +deprecated: Using the non-specific tag "!" is deprecated since Symfony 3.4 as its behavior will change in 4.0. +yaml: | + integer: 12 + also int: ! "12" + string: !!str 12 +php: | + [ 'integer' => 12, 'also int' => 12, 'string' => '12' ] +--- +test: Private types +todo: true +yaml: | + # Both examples below make use of the 'x-private:ball' + # type family URI, but with different semantics. + --- + pool: !!ball + number: 8 + color: black + --- + bearing: !!ball + material: steel +ruby: | + y = YAML::Stream.new + y.add( { 'pool' => + YAML::PrivateType.new( 'ball', + { 'number' => 8, 'color' => 'black' } ) } + ) + y.add( { 'bearing' => + YAML::PrivateType.new( 'ball', + { 'material' => 'steel' } ) } + ) +documents: 2 + +--- +test: Type family under yaml.org +yaml: | + # The URI is 'tag:yaml.org,2002:str' + - !!str a Unicode string +php: | + [ 'a Unicode string' ] +--- +test: Type family under perl.yaml.org +todo: true +yaml: | + # The URI is 'tag:perl.yaml.org,2002:Text::Tabs' + - !perl/Text::Tabs {} +ruby: | + [ YAML::DomainType.new( 'perl.yaml.org,2002', 'Text::Tabs', {} ) ] +--- +test: Type family under clarkevans.com +todo: true +yaml: | + # The URI is 'tag:clarkevans.com,2003-02:timesheet' + - !clarkevans.com,2003-02/timesheet {} +ruby: | + [ YAML::DomainType.new( 'clarkevans.com,2003-02', 'timesheet', {} ) ] +--- +test: URI Escaping +todo: true +yaml: | + same: + - !domain.tld,2002/_PhpScoper5ea00cc67502b\type\x30 value + - !domain.tld,2002/type0 value + different: # As far as the YAML parser is concerned + - !domain.tld,2002/type%30 value + - !domain.tld,2002/type0 value +ruby-setup: | + YAML.add_domain_type( "domain.tld,2002", "type0" ) { |type, val| + "ONE: #{val}" + } + YAML.add_domain_type( "domain.tld,2002", "type%30" ) { |type, val| + "TWO: #{val}" + } +ruby: | + { 'same' => [ 'ONE: value', 'ONE: value' ], 'different' => [ 'TWO: value', 'ONE: value' ] } +--- +test: URI Prefixing +todo: true +yaml: | + # 'tag:domain.tld,2002:invoice' is some type family. + invoice: !domain.tld,2002/^invoice + # 'seq' is shorthand for 'tag:yaml.org,2002:seq'. + # This does not effect '^customer' below + # because it is does not specify a prefix. + customers: !seq + # '^customer' is shorthand for the full + # notation 'tag:domain.tld,2002:customer'. + - !^customer + given : Chris + family : Dumars +ruby-setup: | + YAML.add_domain_type( "domain.tld,2002", /(invoice|customer)/ ) { |type, val| + if val.is_a? ::Hash + scheme, domain, type = type.split( /:/, 3 ) + val['type'] = "domain #{type}" + val + else + raise YAML::Error, "Not a Hash in domain.tld/invoice: " + val.inspect + end + } +ruby: | + { "invoice"=> { "customers"=> [ { "given"=>"Chris", "type"=>"domain customer", "family"=>"Dumars" } ], "type"=>"domain invoice" } } + +--- +test: Overriding anchors +yaml: | + anchor : &A001 This scalar has an anchor. + override : &A001 > + The alias node below is a + repeated use of this value. + alias : *A001 +php: | + [ 'anchor' => 'This scalar has an anchor.', + 'override' => "The alias node below is a repeated use of this value.\n", + 'alias' => "The alias node below is a repeated use of this value.\n"] +--- +test: Flow and block formatting +todo: true +yaml: | + empty: [] + flow: [ one, two, three # May span lines, + , four, # indentation is + five ] # mostly ignored. + block: + - First item in top sequence + - + - Subordinate sequence entry + - > + A folded sequence entry + - Sixth item in top sequence +ruby: | + { 'empty' => [], 'flow' => [ 'one', 'two', 'three', 'four', 'five' ], + 'block' => [ 'First item in top sequence', [ 'Subordinate sequence entry' ], + "A folded sequence _PhpScoper5ea00cc67502b\entry\n", 'Sixth item in top sequence' ] } +--- +test: Complete mapping test +todo: true +yaml: | + empty: {} + flow: { one: 1, two: 2 } + spanning: { one: 1, + two: 2 } + block: + first : First entry + second: + key: Subordinate mapping + third: + - Subordinate sequence + - { } + - Previous mapping is empty. + - A key: value pair in a sequence. + A second: key:value pair. + - The previous entry is equal to the following one. + - + A key: value pair in a sequence. + A second: key:value pair. + !float 12 : This key is a float. + ? > + ? + : This key had to be protected. + "\a" : This key had to be escaped. + ? > + This is a + multi-line + folded key + : Whose value is + also multi-line. + ? this also works as a key + : with a value at the next line. + ? + - This key + - is a sequence + : + - With a sequence value. + ? + This: key + is a: mapping + : + with a: mapping value. +ruby: | + { 'empty' => {}, 'flow' => { 'one' => 1, 'two' => 2 }, + 'spanning' => { 'one' => 1, 'two' => 2 }, + 'block' => { 'first' => 'First entry', 'second' => + { 'key' => 'Subordinate mapping' }, 'third' => + [ 'Subordinate sequence', {}, 'Previous mapping is empty.', + { 'A key' => 'value pair in a sequence.', 'A second' => 'key:value pair.' }, + 'The previous entry is equal to the following one.', + { 'A key' => 'value pair in a sequence.', 'A second' => 'key:value pair.' } ], + 12.0 => 'This key is a float.', "?\n" => 'This key had to be protected.', + "\a" => 'This key had to be escaped.', + "This is a multi-line folded _PhpScoper5ea00cc67502b\key\n" => "Whose value is also multi-line.", + 'this also works as a key' => 'with a value at the next line.', + [ 'This key', 'is a sequence' ] => [ 'With a sequence value.' ] } } + # Couldn't recreate map exactly, so we'll do a detailed check to be sure it's entact + obj_y['block'].keys.each { |k| + if Hash === k + v = obj_y['block'][k] + if k['This'] == 'key' and k['is a'] == 'mapping' and v['with a'] == 'mapping value.' + obj_r['block'][k] = v + end + end + } +--- +test: Literal explicit indentation +yaml: | + # Explicit indentation must + # be given in all the three + # following cases. + leading spaces: |2 + This value starts with four spaces. + + leading line break: |2 + + This value starts with a line break. + + leading comment indicator: |2 + # first line starts with a + # character. + + # Explicit indentation may + # also be given when it is + # not required. + redundant: |2 + This value is indented 2 spaces. +php: | + [ + 'leading spaces' => " This value starts with four spaces.\n", + 'leading line break' => "\nThis value starts with a line break.\n", + 'leading comment indicator' => "# first line starts with _PhpScoper5ea00cc67502b\a\n# character.\n", + 'redundant' => "This value is indented 2 spaces.\n" + ] +--- +test: Chomping and keep modifiers +yaml: | + clipped: | + This has one newline. + + same as "clipped" above: "This has one newline.\n" + + stripped: |- + This has no newline. + + same as "stripped" above: "This has no newline." + + kept: |+ + This has two newlines. + + same as "kept" above: "This has two newlines.\_PhpScoper5ea00cc67502b\n\n" +php: | + [ + 'clipped' => "This has one newline.\n", + 'same as "clipped" above' => "This has one newline.\n", + 'stripped' => 'This has no newline.', + 'same as "stripped" above' => 'This has no newline.', + 'kept' => "This has two newlines.\_PhpScoper5ea00cc67502b\n\n", + 'same as "kept" above' => "This has two newlines.\_PhpScoper5ea00cc67502b\n\n" + ] +--- +test: Literal combinations +todo: true +yaml: | + empty: | + + literal: | + The \ ' " characters may be + freely used. Leading white + space is significant. + + Line breaks are significant. + Thus this value contains one + empty line and ends with a + single line break, but does + not start with one. + + is equal to: "The \\ ' \" characters may \ + _PhpScoper5ea00cc67502b\be\nfreely used. Leading _PhpScoper5ea00cc67502b\white\n space \ + is significant.\_PhpScoper5ea00cc67502b\n\nLine breaks are \ + significant.\nThus this value contains \ + _PhpScoper5ea00cc67502b\one\nempty line and ends with _PhpScoper5ea00cc67502b\a\nsingle \ + line break, but _PhpScoper5ea00cc67502b\does\nnot start with one.\n" + + # Comments may follow a block + # scalar value. They must be + # less indented. + + # Modifiers may be combined in any order. + indented and chomped: |2- + This has no newline. + + also written as: |-2 + This has no newline. + + both are equal to: " This has no newline." +php: | + [ + 'empty' => '', + 'literal' => "The \\ ' \" characters may _PhpScoper5ea00cc67502b\be\nfreely used. Leading _PhpScoper5ea00cc67502b\white\n space " + + "is significant.\_PhpScoper5ea00cc67502b\n\nLine breaks are significant.\nThus this value contains _PhpScoper5ea00cc67502b\one\n" + + "empty line and ends with _PhpScoper5ea00cc67502b\a\nsingle line break, but _PhpScoper5ea00cc67502b\does\nnot start with one.\n", + 'is equal to' => "The \\ ' \" characters may _PhpScoper5ea00cc67502b\be\nfreely used. Leading _PhpScoper5ea00cc67502b\white\n space " + + "is significant.\_PhpScoper5ea00cc67502b\n\nLine breaks are significant.\nThus this value contains _PhpScoper5ea00cc67502b\one\n" + + "empty line and ends with _PhpScoper5ea00cc67502b\a\nsingle line break, but _PhpScoper5ea00cc67502b\does\nnot start with one.\n", + 'indented and chomped' => ' This has no newline.', + 'also written as' => ' This has no newline.', + 'both are equal to' => ' This has no newline.' + [ +--- +test: Folded combinations +todo: true +yaml: | + empty: > + + one paragraph: > + Line feeds are converted + to spaces, so this value + contains no line breaks + except for the final one. + + multiple paragraphs: >2 + + An empty line, either + at the start or in + the value: + + Is interpreted as a + line break. Thus this + value contains three + line breaks. + + indented text: > + This is a folded + paragraph followed + by a list: + * first entry + * second entry + Followed by another + folded paragraph, + another list: + + * first entry + + * second entry + + And a final folded + paragraph. + + above is equal to: | + This is a folded paragraph followed by a list: + * first entry + * second entry + Followed by another folded paragraph, another list: + + * first entry + + * second entry + + And a final folded paragraph. + + # Explicit comments may follow + # but must be less indented. +php: | + [ + 'empty' => '', + 'one paragraph' => 'Line feeds are converted to spaces, so this value'. + " contains no line breaks except for the final one.\n", + 'multiple paragraphs' => "\nAn empty line, either at the start or in the value:\n". + "Is interpreted as a line break. Thus this value contains three line breaks.\n", + 'indented text' => "This is a folded paragraph followed by a list:\n". + " * first _PhpScoper5ea00cc67502b\entry\n * second _PhpScoper5ea00cc67502b\entry\nFollowed by another folded paragraph, ". + "another list:\_PhpScoper5ea00cc67502b\n\n * first _PhpScoper5ea00cc67502b\entry\n\n * second _PhpScoper5ea00cc67502b\entry\n\nAnd a final folded paragraph.\n", + 'above is equal to' => "This is a folded paragraph followed by a list:\n". + " * first _PhpScoper5ea00cc67502b\entry\n * second _PhpScoper5ea00cc67502b\entry\nFollowed by another folded paragraph, ". + "another list:\_PhpScoper5ea00cc67502b\n\n * first _PhpScoper5ea00cc67502b\entry\n\n * second _PhpScoper5ea00cc67502b\entry\n\nAnd a final folded paragraph.\n" + ] +--- +test: Single quotes +todo: true +yaml: | + empty: '' + second: '! : \ etc. can be used freely.' + third: 'a single quote '' must be escaped.' + span: 'this contains + six spaces + + and one + line break' + is same as: "this contains six _PhpScoper5ea00cc67502b\spaces\nand one line break" +php: | + [ + 'empty' => '', + 'second' => '! : \\ etc. can be used freely.', + 'third' => "a single quote ' must be escaped.", + 'span' => "this contains six _PhpScoper5ea00cc67502b\spaces\nand one line break", + 'is same as' => "this contains six _PhpScoper5ea00cc67502b\spaces\nand one line break" + ] +--- +test: Double quotes +todo: true +yaml: | + empty: "" + second: "! : etc. can be used freely." + third: "a \" or a \\ must be escaped." + fourth: "this value ends with an LF.\n" + span: "this contains + four \ + spaces" + is equal to: "this contains four spaces" +php: | + [ + 'empty' => '', + 'second' => '! : etc. can be used freely.', + 'third' => 'a " or a \\ must be escaped.', + 'fourth' => "this value ends with an LF.\n", + 'span' => "this contains four spaces", + 'is equal to' => "this contains four spaces" + ] +--- +test: Unquoted strings +todo: true +yaml: | + first: There is no unquoted empty string. + + second: 12 ## This is an integer. + + third: !!str 12 ## This is a string. + + span: this contains + six spaces + + and one + line break + + indicators: this has no comments. + #:foo and bar# are + both text. + + flow: [ can span + lines, # comment + like + this ] + + note: { one-line keys: but multi-line values } + +php: | + [ + 'first' => 'There is no unquoted empty string.', + 'second' => 12, + 'third' => '12', + 'span' => "this contains six _PhpScoper5ea00cc67502b\spaces\nand one line break", + 'indicators' => "this has no comments. #:foo and bar# are both text.", + 'flow' => [ 'can span lines', 'like this' ], + 'note' => { 'one-line keys' => 'but multi-line values' } + ] +--- +test: Spanning sequences +todo: true +yaml: | + # The following are equal seqs + # with different identities. + flow: [ one, two ] + spanning: [ one, + two ] + block: + - one + - two +php: | + [ + 'flow' => [ 'one', 'two' ], + 'spanning' => [ 'one', 'two' ], + 'block' => [ 'one', 'two' ] + ] +--- +test: Flow mappings +yaml: | + # The following are equal maps + # with different identities. + flow: { one: 1, two: 2 } + block: + one: 1 + two: 2 +php: | + [ + 'flow' => [ 'one' => 1, 'two' => 2 ], + 'block' => [ 'one' => 1, 'two' => 2 ] + ] +--- +test: Representations of 12 +todo: true +yaml: | + - 12 # An integer + # The following scalars + # are loaded to the + # string value '1' '2'. + - !!str 12 + - '12' + - "12" + - "\ + 1\ + 2\ + " + # Strings containing paths and regexps can be unquoted: + - /foo/bar + - d:/foo/bar + - foo/bar + - /a.*b/ +php: | + [ 12, '12', '12', '12', '12', '/foo/bar', 'd:/foo/bar', 'foo/bar', '/a.*b/' ] +--- +test: "Null" +todo: true +yaml: | + canonical: ~ + + english: null + + # This sequence has five + # entries, two with values. + sparse: + - ~ + - 2nd entry + - Null + - 4th entry + - + + four: This mapping has five keys, + only two with values. + +php: | + [ + 'canonical' => null, + 'english' => null, + 'sparse' => [ null, '2nd entry', null, '4th entry', null ]], + 'four' => 'This mapping has five keys, only two with values.' + ] +--- +test: Omap +todo: true +yaml: | + # Explicitly typed dictionary. + Bestiary: !omap + - aardvark: African pig-like ant eater. Ugly. + - anteater: South-American ant eater. Two species. + - anaconda: South-American constrictor snake. Scary. + # Etc. +ruby: | + { + 'Bestiary' => YAML::Omap[ + 'aardvark', 'African pig-like ant eater. Ugly.', + 'anteater', 'South-American ant eater. Two species.', + 'anaconda', 'South-American constrictor snake. Scary.' + ] + } + +--- +test: Pairs +todo: true +yaml: | + # Explicitly typed pairs. + tasks: !pairs + - meeting: with team. + - meeting: with boss. + - break: lunch. + - meeting: with client. +ruby: | + { + 'tasks' => YAML::Pairs[ + 'meeting', 'with team.', + 'meeting', 'with boss.', + 'break', 'lunch.', + 'meeting', 'with client.' + ] + } + +--- +test: Set +todo: true +yaml: | + # Explicitly typed set. + baseball players: !set + Mark McGwire: + Sammy Sosa: + Ken Griffey: +ruby: | + { + 'baseball players' => YAML::Set[ + 'Mark McGwire', nil, + 'Sammy Sosa', nil, + 'Ken Griffey', nil + ] + } + +--- +test: Integer +yaml: | + canonical: 12345 + octal: 014 + hexadecimal: 0xC +php: | + [ + 'canonical' => 12345, + 'octal' => 12, + 'hexadecimal' => 12 + ] +--- +test: Decimal +deprecated: true +yaml: | + decimal: +12,345 +php: | + [ + 'decimal' => 12345.0, + ] +--- +test: Fixed Float +deprecated: true +yaml: | + fixed: 1,230.15 +php: | + [ + 'fixed' => 1230.15, + ] +--- +test: Float +yaml: | + canonical: 1.23015e+3 + exponential: 12.3015e+02 + negative infinity: -.inf + not a number: .NaN +php: | + [ + 'canonical' => 1230.15, + 'exponential' => 1230.15, + 'negative infinity' => log(0), + 'not a number' => -log(0) + ] +--- +test: Timestamp +todo: true +yaml: | + canonical: 2001-12-15T02:59:43.1Z + valid iso8601: 2001-12-14t21:59:43.10-05:00 + space separated: 2001-12-14 21:59:43.10 -05:00 + date (noon UTC): 2002-12-14 +ruby: | + [ + 'canonical' => YAML::mktime( 2001, 12, 15, 2, 59, 43, 0.10 ), + 'valid iso8601' => YAML::mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ), + 'space separated' => YAML::mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ), + 'date (noon UTC)' => Date.new( 2002, 12, 14 ) + ] +--- +test: Binary +todo: true +yaml: | + canonical: !binary "\ + R0lGODlhDAAMAIQAAP//9/X17unp5WZmZgAAAOfn515eXvPz7Y6OjuDg4J+fn5\ + OTk6enp56enmlpaWNjY6Ojo4SEhP/++f/++f/++f/++f/++f/++f/++f/++f/+\ + +f/++f/++f/++f/++f/++SH+Dk1hZGUgd2l0aCBHSU1QACwAAAAADAAMAAAFLC\ + AgjoEwnuNAFOhpEMTRiggcz4BNJHrv/zCFcLiwMWYNG84BwwEeECcgggoBADs=" + base64: !binary | + R0lGODlhDAAMAIQAAP//9/X17unp5WZmZgAAAOfn515eXvPz7Y6OjuDg4J+fn5 + OTk6enp56enmlpaWNjY6Ojo4SEhP/++f/++f/++f/++f/++f/++f/++f/++f/+ + +f/++f/++f/++f/++f/++SH+Dk1hZGUgd2l0aCBHSU1QACwAAAAADAAMAAAFLC + AgjoEwnuNAFOhpEMTRiggcz4BNJHrv/zCFcLiwMWYNG84BwwEeECcgggoBADs= + description: > + The binary value above is a tiny arrow + encoded as a gif image. +ruby-setup: | + arrow_gif = "_PhpScoper5ea00cc67502b\GIF89a\f\000\f\000\204\000\000\377\377\367\365\365\356\351\351\345fff\000\000\000\347\347\347^^^\_PhpScoper5ea00cc67502b\363\363\355\216\216\216\340\340\340\237\237\237\223\223\223\247\247\247\236\236\236iiiccc\243\243\243\204\204\204\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371\377\376\371!\_PhpScoper5ea00cc67502b\376\016Made with _PhpScoper5ea00cc67502b\GIMP\000,\_PhpScoper5ea00cc67502b\000\000\000\000\f\000\f\000\000\005, \_PhpScoper5ea00cc67502b\216\2010\236\343@\_PhpScoper5ea00cc67502b\024\350i\020\304\321\212\010\034\317\200M$_PhpScoper5ea00cc67502b\z\357\3770\205p\270\2601f\r\e\316\001\303\001\036\020' \_PhpScoper5ea00cc67502b\202\n\001\000;" +ruby: | + { + 'canonical' => arrow_gif, + 'base64' => arrow_gif, + 'description' => "The binary value above is a tiny arrow encoded as a gif image.\n" + } + +--- +test: Merge key +todo: true +yaml: | + --- + - &CENTER { x: 1, y: 2 } + - &LEFT { x: 0, y: 2 } + - &BIG { r: 10 } + - &SMALL { r: 1 } + + # All the following maps are equal: + + - # Explicit keys + x: 1 + y: 2 + r: 10 + label: center/big + + - # Merge one map + << : *CENTER + r: 10 + label: center/big + + - # Merge multiple maps + << : [ *CENTER, *BIG ] + label: center/big + + - # Override + << : [ *BIG, *LEFT, *SMALL ] + x: 1 + label: center/big + +ruby-setup: | + center = { 'x' => 1, 'y' => 2 } + left = { 'x' => 0, 'y' => 2 } + big = { 'r' => 10 } + small = { 'r' => 1 } + node1 = { 'x' => 1, 'y' => 2, 'r' => 10, 'label' => 'center/big' } + node2 = center.dup + node2.update( { 'r' => 10, 'label' => 'center/big' } ) + node3 = big.dup + node3.update( center ) + node3.update( { 'label' => 'center/big' } ) + node4 = small.dup + node4.update( left ) + node4.update( big ) + node4.update( { 'x' => 1, 'label' => 'center/big' } ) + +ruby: | + [ + center, left, big, small, node1, node2, node3, node4 + ] + +--- +test: Default key +todo: true +yaml: | + --- # Old schema + link with: + - library1.dll + - library2.dll + --- # New schema + link with: + - = : library1.dll + version: 1.2 + - = : library2.dll + version: 2.3 +ruby: | + y = YAML::Stream.new + y.add( { 'link with' => [ 'library1.dll', 'library2.dll' ] } ) + obj_h = Hash[ 'version' => 1.2 ] + obj_h.default = 'library1.dll' + obj_h2 = Hash[ 'version' => 2.3 ] + obj_h2.default = 'library2.dll' + y.add( { 'link with' => [ obj_h, obj_h2 ] } ) +documents: 2 + +--- +test: Special keys +todo: true +yaml: | + "!": These three keys + "&": had to be quoted + "=": and are normal strings. + # NOTE: the following node should NOT be serialized this way. + encoded node : + !special '!' : '!type' + !special|canonical '&' : 12 + = : value + # The proper way to serialize the above node is as follows: + node : !!type &12 value +ruby: | + { '!' => 'These three keys', '&' => 'had to be quoted', + '=' => 'and are normal strings.', + 'encoded node' => YAML::PrivateType.new( 'type', 'value' ), + 'node' => YAML::PrivateType.new( 'type', 'value' ) } diff --git a/vendor/symfony/yaml/Tests/Fixtures/YtsTypeTransfers.yml b/vendor/symfony/yaml/Tests/Fixtures/YtsTypeTransfers.yml index 2a0a9f416..de429b16a 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/YtsTypeTransfers.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/YtsTypeTransfers.yml @@ -1,266 +1,266 @@ ---- %YAML:1.0 -test: Strings -brief: > - Any group of characters beginning with an - alphabetic or numeric character is a string, - unless it belongs to one of the groups below - (such as an Integer or Time). -yaml: | - String -php: | - 'String' ---- -test: String characters -brief: > - A string can contain any alphabetic or - numeric character, along with many - punctuation characters, including the - period, dash, space, quotes, exclamation, and - question mark. -yaml: | - - What's Yaml? - - It's for writing data structures in plain text. - - And? - - And what? That's not good enough for you? - - No, I mean, "And what about Yaml?" - - Oh, oh yeah. Uh.. Yaml for Ruby. -php: | - [ - "What's Yaml?", - "It's for writing data structures in plain text.", - "And?", - "And what? That's not good enough for you?", - "No, I mean, \"And what about Yaml?\"", - "Oh, oh yeah. Uh.. Yaml for Ruby." - ] ---- -test: Indicators in Strings -brief: > - Be careful using indicators in strings. In particular, - the comma, colon, and pound sign must be used carefully. -yaml: | - the colon followed by space is an indicator: but is a string:right here - same for the pound sign: here we have it#in a string - the comma can, honestly, be used in most cases: [ but not in, inline collections ] -php: | - [ - 'the colon followed by space is an indicator' => 'but is a string:right here', - 'same for the pound sign' => 'here we have it#in a string', - 'the comma can, honestly, be used in most cases' => ['but not in', 'inline collections'] - ] ---- -test: Forcing Strings -brief: > - Any YAML type can be forced into a string using the - explicit !!str method. -yaml: | - date string: !!str 2001-08-01 - number string: !!str 192 -php: | - [ - 'date string' => '2001-08-01', - 'number string' => '192' - ] ---- -test: Single-quoted Strings -brief: > - You can also enclose your strings within single quotes, - which allows use of slashes, colons, and other indicators - freely. Inside single quotes, you can represent a single - quote in your string by using two single quotes next to - each other. -yaml: | - all my favorite symbols: '#:!/%.)' - a few i hate: '&(*' - why do i hate them?: 'it''s very hard to explain' - entities: '£ me' -php: | - [ - 'all my favorite symbols' => '#:!/%.)', - 'a few i hate' => '&(*', - 'why do i hate them?' => 'it\'s very hard to explain', - 'entities' => '£ me' - ] ---- -test: Double-quoted Strings -brief: > - Enclosing strings in double quotes allows you - to use escapings to represent ASCII and - Unicode characters. -yaml: | - i know where i want my line breaks: "one _PhpScoper5ea00cc67502b\here\nand another _PhpScoper5ea00cc67502b\here\n" -php: | - [ - 'i know where i want my line breaks' => "one _PhpScoper5ea00cc67502b\here\nand another _PhpScoper5ea00cc67502b\here\n" - ] ---- -test: Multi-line Quoted Strings -todo: true -brief: > - Both single- and double-quoted strings may be - carried on to new lines in your YAML document. - They must be indented a step and indentation - is interpreted as a single space. -yaml: | - i want a long string: "so i'm going to - let it go on and on to other lines - until i end it with a quote." -php: | - ['i want a long string' => "so i'm going to ". - "let it go on and on to other lines ". - "until i end it with a quote." - ] - ---- -test: Plain scalars -todo: true -brief: > - Unquoted strings may also span multiple lines, if they - are free of YAML space indicators and indented. -yaml: | - - My little toe is broken in two places; - - I'm crazy to have skied this way; - - I'm not the craziest he's seen, since there was always the German guy - who skied for 3 hours on a broken shin bone (just below the kneecap); - - Nevertheless, second place is respectable, and he doesn't - recommend going for the record; - - He's going to put my foot in plaster for a month; - - This would impair my skiing ability somewhat for the - duration, as can be imagined. -php: | - [ - "My little toe is broken in two places;", - "I'm crazy to have skied this way;", - "I'm not the craziest he's seen, since there was always ". - "the German guy who skied for 3 hours on a broken shin ". - "bone (just below the kneecap);", - "Nevertheless, second place is respectable, and he doesn't ". - "recommend going for the record;", - "He's going to put my foot in plaster for a month;", - "This would impair my skiing ability somewhat for the duration, ". - "as can be imagined." - ] ---- -test: 'Null' -brief: > - You can use the tilde '~' character for a null value. -yaml: | - name: Mr. Show - hosted by: Bob and David - date of next season: ~ -php: | - [ - 'name' => 'Mr. Show', - 'hosted by' => 'Bob and David', - 'date of next season' => null - ] ---- -test: Boolean -brief: > - You can use 'true' and 'false' for Boolean values. -yaml: | - Is Gus a Liar?: true - Do I rely on Gus for Sustenance?: false -php: | - [ - 'Is Gus a Liar?' => true, - 'Do I rely on Gus for Sustenance?' => false - ] ---- -test: Integers -dump_skip: true -brief: > - An integer is a series of numbers, optionally - starting with a positive or negative sign. Integers - may also contain commas for readability. -yaml: | - zero: 0 - simple: 12 -php: | - [ - 'zero' => 0, - 'simple' => 12, - ] ---- -test: Positive Big Integer -deprecated: true -dump_skip: true -brief: > - An integer is a series of numbers, optionally - starting with a positive or negative sign. Integers - may also contain commas for readability. -yaml: | - one-thousand: 1,000 -php: | - [ - 'one-thousand' => 1000.0, - ] ---- -test: Negative Big Integer -deprecated: true -dump_skip: true -brief: > - An integer is a series of numbers, optionally - starting with a positive or negative sign. Integers - may also contain commas for readability. -yaml: | - negative one-thousand: -1,000 -php: | - [ - 'negative one-thousand' => -1000.0 - ] ---- -test: Floats -dump_skip: true -brief: > - Floats are represented by numbers with decimals, - allowing for scientific notation, as well as - positive and negative infinity and "not a number." -yaml: | - a simple float: 2.00 - scientific notation: 1.00009e+3 -php: | - [ - 'a simple float' => 2.0, - 'scientific notation' => 1000.09 - ] ---- -test: Larger Float -dump_skip: true -deprecated: true -brief: > - Floats are represented by numbers with decimals, - allowing for scientific notation, as well as - positive and negative infinity and "not a number." -yaml: | - larger float: 1,000.09 -php: | - [ - 'larger float' => 1000.09, - ] ---- -test: Time -todo: true -brief: > - You can represent timestamps by using - ISO8601 format, or a variation which - allows spaces between the date, time and - time zone. -yaml: | - iso8601: 2001-12-14t21:59:43.10-05:00 - space separated: 2001-12-14 21:59:43.10 -05:00 -php: | - [ - 'iso8601' => mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ), - 'space separated' => mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ) - ] ---- -test: Date -todo: true -brief: > - A date can be represented by its year, - month and day in ISO8601 order. -yaml: | - 1976-07-31 -php: | - date( 1976, 7, 31 ) +--- %YAML:1.0 +test: Strings +brief: > + Any group of characters beginning with an + alphabetic or numeric character is a string, + unless it belongs to one of the groups below + (such as an Integer or Time). +yaml: | + String +php: | + 'String' +--- +test: String characters +brief: > + A string can contain any alphabetic or + numeric character, along with many + punctuation characters, including the + period, dash, space, quotes, exclamation, and + question mark. +yaml: | + - What's Yaml? + - It's for writing data structures in plain text. + - And? + - And what? That's not good enough for you? + - No, I mean, "And what about Yaml?" + - Oh, oh yeah. Uh.. Yaml for Ruby. +php: | + [ + "What's Yaml?", + "It's for writing data structures in plain text.", + "And?", + "And what? That's not good enough for you?", + "No, I mean, \"And what about Yaml?\"", + "Oh, oh yeah. Uh.. Yaml for Ruby." + ] +--- +test: Indicators in Strings +brief: > + Be careful using indicators in strings. In particular, + the comma, colon, and pound sign must be used carefully. +yaml: | + the colon followed by space is an indicator: but is a string:right here + same for the pound sign: here we have it#in a string + the comma can, honestly, be used in most cases: [ but not in, inline collections ] +php: | + [ + 'the colon followed by space is an indicator' => 'but is a string:right here', + 'same for the pound sign' => 'here we have it#in a string', + 'the comma can, honestly, be used in most cases' => ['but not in', 'inline collections'] + ] +--- +test: Forcing Strings +brief: > + Any YAML type can be forced into a string using the + explicit !!str method. +yaml: | + date string: !!str 2001-08-01 + number string: !!str 192 +php: | + [ + 'date string' => '2001-08-01', + 'number string' => '192' + ] +--- +test: Single-quoted Strings +brief: > + You can also enclose your strings within single quotes, + which allows use of slashes, colons, and other indicators + freely. Inside single quotes, you can represent a single + quote in your string by using two single quotes next to + each other. +yaml: | + all my favorite symbols: '#:!/%.)' + a few i hate: '&(*' + why do i hate them?: 'it''s very hard to explain' + entities: '£ me' +php: | + [ + 'all my favorite symbols' => '#:!/%.)', + 'a few i hate' => '&(*', + 'why do i hate them?' => 'it\'s very hard to explain', + 'entities' => '£ me' + ] +--- +test: Double-quoted Strings +brief: > + Enclosing strings in double quotes allows you + to use escapings to represent ASCII and + Unicode characters. +yaml: | + i know where i want my line breaks: "one _PhpScoper5ea00cc67502b\here\nand another _PhpScoper5ea00cc67502b\here\n" +php: | + [ + 'i know where i want my line breaks' => "one _PhpScoper5ea00cc67502b\here\nand another _PhpScoper5ea00cc67502b\here\n" + ] +--- +test: Multi-line Quoted Strings +todo: true +brief: > + Both single- and double-quoted strings may be + carried on to new lines in your YAML document. + They must be indented a step and indentation + is interpreted as a single space. +yaml: | + i want a long string: "so i'm going to + let it go on and on to other lines + until i end it with a quote." +php: | + ['i want a long string' => "so i'm going to ". + "let it go on and on to other lines ". + "until i end it with a quote." + ] + +--- +test: Plain scalars +todo: true +brief: > + Unquoted strings may also span multiple lines, if they + are free of YAML space indicators and indented. +yaml: | + - My little toe is broken in two places; + - I'm crazy to have skied this way; + - I'm not the craziest he's seen, since there was always the German guy + who skied for 3 hours on a broken shin bone (just below the kneecap); + - Nevertheless, second place is respectable, and he doesn't + recommend going for the record; + - He's going to put my foot in plaster for a month; + - This would impair my skiing ability somewhat for the + duration, as can be imagined. +php: | + [ + "My little toe is broken in two places;", + "I'm crazy to have skied this way;", + "I'm not the craziest he's seen, since there was always ". + "the German guy who skied for 3 hours on a broken shin ". + "bone (just below the kneecap);", + "Nevertheless, second place is respectable, and he doesn't ". + "recommend going for the record;", + "He's going to put my foot in plaster for a month;", + "This would impair my skiing ability somewhat for the duration, ". + "as can be imagined." + ] +--- +test: 'Null' +brief: > + You can use the tilde '~' character for a null value. +yaml: | + name: Mr. Show + hosted by: Bob and David + date of next season: ~ +php: | + [ + 'name' => 'Mr. Show', + 'hosted by' => 'Bob and David', + 'date of next season' => null + ] +--- +test: Boolean +brief: > + You can use 'true' and 'false' for Boolean values. +yaml: | + Is Gus a Liar?: true + Do I rely on Gus for Sustenance?: false +php: | + [ + 'Is Gus a Liar?' => true, + 'Do I rely on Gus for Sustenance?' => false + ] +--- +test: Integers +dump_skip: true +brief: > + An integer is a series of numbers, optionally + starting with a positive or negative sign. Integers + may also contain commas for readability. +yaml: | + zero: 0 + simple: 12 +php: | + [ + 'zero' => 0, + 'simple' => 12, + ] +--- +test: Positive Big Integer +deprecated: true +dump_skip: true +brief: > + An integer is a series of numbers, optionally + starting with a positive or negative sign. Integers + may also contain commas for readability. +yaml: | + one-thousand: 1,000 +php: | + [ + 'one-thousand' => 1000.0, + ] +--- +test: Negative Big Integer +deprecated: true +dump_skip: true +brief: > + An integer is a series of numbers, optionally + starting with a positive or negative sign. Integers + may also contain commas for readability. +yaml: | + negative one-thousand: -1,000 +php: | + [ + 'negative one-thousand' => -1000.0 + ] +--- +test: Floats +dump_skip: true +brief: > + Floats are represented by numbers with decimals, + allowing for scientific notation, as well as + positive and negative infinity and "not a number." +yaml: | + a simple float: 2.00 + scientific notation: 1.00009e+3 +php: | + [ + 'a simple float' => 2.0, + 'scientific notation' => 1000.09 + ] +--- +test: Larger Float +dump_skip: true +deprecated: true +brief: > + Floats are represented by numbers with decimals, + allowing for scientific notation, as well as + positive and negative infinity and "not a number." +yaml: | + larger float: 1,000.09 +php: | + [ + 'larger float' => 1000.09, + ] +--- +test: Time +todo: true +brief: > + You can represent timestamps by using + ISO8601 format, or a variation which + allows spaces between the date, time and + time zone. +yaml: | + iso8601: 2001-12-14t21:59:43.10-05:00 + space separated: 2001-12-14 21:59:43.10 -05:00 +php: | + [ + 'iso8601' => mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ), + 'space separated' => mktime( 2001, 12, 14, 21, 59, 43, 0.10, "-05:00" ) + ] +--- +test: Date +todo: true +brief: > + A date can be represented by its year, + month and day in ISO8601 order. +yaml: | + 1976-07-31 +php: | + date( 1976, 7, 31 ) diff --git a/vendor/symfony/yaml/Tests/Fixtures/booleanMappingKeys.yml b/vendor/symfony/yaml/Tests/Fixtures/booleanMappingKeys.yml index 88287f1b9..febf67fdc 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/booleanMappingKeys.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/booleanMappingKeys.yml @@ -1,11 +1,11 @@ ---- %YAML:1.0 -test: Miscellaneous -spec: 2.21 -yaml: | - true: true - false: false -php: | - [ - 'true' => true, - 'false' => false, - ] +--- %YAML:1.0 +test: Miscellaneous +spec: 2.21 +yaml: | + true: true + false: false +php: | + [ + 'true' => true, + 'false' => false, + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/embededPhp.yml b/vendor/symfony/yaml/Tests/Fixtures/embededPhp.yml index ec456ed09..55be52a32 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/embededPhp.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/embededPhp.yml @@ -1 +1 @@ -value: +value: diff --git a/vendor/symfony/yaml/Tests/Fixtures/escapedCharacters.yml b/vendor/symfony/yaml/Tests/Fixtures/escapedCharacters.yml index 376ba8183..f34357dce 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/escapedCharacters.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/escapedCharacters.yml @@ -1,155 +1,155 @@ -test: outside double quotes -yaml: | - \0 \ \a \b \n -php: | - "\\0 \\ \\a \\b \\n" ---- -test: 'null' -yaml: | - "\0" -php: | - "\x00" ---- -test: bell -yaml: | - "\a" -php: | - "\x07" ---- -test: backspace -yaml: | - "\b" -php: | - "\x08" ---- -test: horizontal tab (1) -yaml: | - "\t" -php: | - "\x09" ---- -test: horizontal tab (2) -yaml: | - "\ " -php: | - "\x09" ---- -test: line feed -yaml: | - "\n" -php: | - "\x0a" ---- -test: vertical tab -yaml: | - "\v" -php: | - "\x0b" ---- -test: form feed -yaml: | - "\f" -php: | - "\x0c" ---- -test: carriage return -yaml: | - "\r" -php: | - "\x0d" ---- -test: escape -yaml: | - "\e" -php: | - "\x1b" ---- -test: space -yaml: | - "\ " -php: | - "\x20" ---- -test: slash -yaml: | - "\/" -php: | - "\x2f" ---- -test: backslash -yaml: | - "\\" -php: | - "\\" ---- -test: Unicode next line -yaml: | - "\N" -php: | - "\_PhpScoper5ea00cc67502b\xc2\x85" ---- -test: Unicode non-breaking space -yaml: | - "\_" -php: | - "\_PhpScoper5ea00cc67502b\xc2\xa0" ---- -test: Unicode line separator -yaml: | - "\L" -php: | - "\_PhpScoper5ea00cc67502b\xe2\x80\xa8" ---- -test: Unicode paragraph separator -yaml: | - "\P" -php: | - "\_PhpScoper5ea00cc67502b\xe2\x80\xa9" ---- -test: Escaped 8-bit Unicode -yaml: | - "\x42" -php: | - "B" ---- -test: Escaped 16-bit Unicode -yaml: | - "\u20ac" -php: | - "\_PhpScoper5ea00cc67502b\xe2\x82\xac" ---- -test: Escaped 32-bit Unicode -yaml: | - "\U00000043" -php: | - "C" ---- -test: Example 5.13 Escaped Characters -note: | - Currently throws an error parsing first line. Maybe Symfony Yaml doesn't support - continuation of string across multiple lines? Keeping test here but disabled. -todo: true -yaml: | - "Fun with \\ - \" \a \b \e \f \ - \n \r \t \v \0 \ - \ \_ \N \L \P \ - \x41 \u0041 \U00000041" -php: | - "Fun with \_PhpScoper5ea00cc67502b\x5C\n\x22 \x07 \x08 \x1B \_PhpScoper5ea00cc67502b\x0C\n\x0A \x0D \x09 \x0B \_PhpScoper5ea00cc67502b\x00\n\x20 \xA0 \x85 \_PhpScoper5ea00cc67502b\xe2\x80\xa8 \_PhpScoper5ea00cc67502b\xe2\x80\xa9\nA A A" ---- -test: Double quotes with a line feed -yaml: | - { double: "some _PhpScoper5ea00cc67502b\value\n \"some quoted string\" and 'some single quotes one'" } -php: | - [ - 'double' => "some _PhpScoper5ea00cc67502b\value\n \"some quoted string\" and 'some single quotes one'" - ] ---- -test: Backslashes -yaml: | - { single: '_PhpScoper5ea00cc67502b\foo\Var', no-quotes: _PhpScoper5ea00cc67502b\foo\Var, double: "_PhpScoper5ea00cc67502b\\foo\\Var" } -php: | - [ - 'single' => '_PhpScoper5ea00cc67502b\foo\Var', 'no-quotes' => '_PhpScoper5ea00cc67502b\foo\Var', 'double' => '_PhpScoper5ea00cc67502b\foo\Var' - ] +test: outside double quotes +yaml: | + \0 \ \a \b \n +php: | + "\\0 \\ \\a \\b \\n" +--- +test: 'null' +yaml: | + "\0" +php: | + "\x00" +--- +test: bell +yaml: | + "\a" +php: | + "\x07" +--- +test: backspace +yaml: | + "\b" +php: | + "\x08" +--- +test: horizontal tab (1) +yaml: | + "\t" +php: | + "\x09" +--- +test: horizontal tab (2) +yaml: | + "\ " +php: | + "\x09" +--- +test: line feed +yaml: | + "\n" +php: | + "\x0a" +--- +test: vertical tab +yaml: | + "\v" +php: | + "\x0b" +--- +test: form feed +yaml: | + "\f" +php: | + "\x0c" +--- +test: carriage return +yaml: | + "\r" +php: | + "\x0d" +--- +test: escape +yaml: | + "\e" +php: | + "\x1b" +--- +test: space +yaml: | + "\ " +php: | + "\x20" +--- +test: slash +yaml: | + "\/" +php: | + "\x2f" +--- +test: backslash +yaml: | + "\\" +php: | + "\\" +--- +test: Unicode next line +yaml: | + "\N" +php: | + "\_PhpScoper5ea00cc67502b\xc2\x85" +--- +test: Unicode non-breaking space +yaml: | + "\_" +php: | + "\_PhpScoper5ea00cc67502b\xc2\xa0" +--- +test: Unicode line separator +yaml: | + "\L" +php: | + "\_PhpScoper5ea00cc67502b\xe2\x80\xa8" +--- +test: Unicode paragraph separator +yaml: | + "\P" +php: | + "\_PhpScoper5ea00cc67502b\xe2\x80\xa9" +--- +test: Escaped 8-bit Unicode +yaml: | + "\x42" +php: | + "B" +--- +test: Escaped 16-bit Unicode +yaml: | + "\u20ac" +php: | + "\_PhpScoper5ea00cc67502b\xe2\x82\xac" +--- +test: Escaped 32-bit Unicode +yaml: | + "\U00000043" +php: | + "C" +--- +test: Example 5.13 Escaped Characters +note: | + Currently throws an error parsing first line. Maybe Symfony Yaml doesn't support + continuation of string across multiple lines? Keeping test here but disabled. +todo: true +yaml: | + "Fun with \\ + \" \a \b \e \f \ + \n \r \t \v \0 \ + \ \_ \N \L \P \ + \x41 \u0041 \U00000041" +php: | + "Fun with \_PhpScoper5ea00cc67502b\x5C\n\x22 \x07 \x08 \x1B \_PhpScoper5ea00cc67502b\x0C\n\x0A \x0D \x09 \x0B \_PhpScoper5ea00cc67502b\x00\n\x20 \xA0 \x85 \_PhpScoper5ea00cc67502b\xe2\x80\xa8 \_PhpScoper5ea00cc67502b\xe2\x80\xa9\nA A A" +--- +test: Double quotes with a line feed +yaml: | + { double: "some _PhpScoper5ea00cc67502b\value\n \"some quoted string\" and 'some single quotes one'" } +php: | + [ + 'double' => "some _PhpScoper5ea00cc67502b\value\n \"some quoted string\" and 'some single quotes one'" + ] +--- +test: Backslashes +yaml: | + { single: '_PhpScoper5ea00cc67502b\foo\Var', no-quotes: _PhpScoper5ea00cc67502b\foo\Var, double: "_PhpScoper5ea00cc67502b\\foo\\Var" } +php: | + [ + 'single' => '_PhpScoper5ea00cc67502b\foo\Var', 'no-quotes' => '_PhpScoper5ea00cc67502b\foo\Var', 'double' => '_PhpScoper5ea00cc67502b\foo\Var' + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/index.php b/vendor/symfony/yaml/Tests/Fixtures/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/index.php +++ b/vendor/symfony/yaml/Tests/Fixtures/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Tests/Fixtures/index.yml b/vendor/symfony/yaml/Tests/Fixtures/index.yml index 3216a89eb..26ab46a2d 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/index.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/index.yml @@ -1,18 +1,18 @@ -- escapedCharacters -- sfComments -- sfCompact -- sfTests -- sfObjects -- sfMergeKey -- sfQuotes -- YtsAnchorAlias -- YtsBasicTests -- YtsBlockMapping -- YtsDocumentSeparator -- YtsErrorTests -- YtsFlowCollections -- YtsFoldedScalars -- YtsNullsAndEmpties -- YtsSpecificationExamples -- YtsTypeTransfers -- unindentedCollections +- escapedCharacters +- sfComments +- sfCompact +- sfTests +- sfObjects +- sfMergeKey +- sfQuotes +- YtsAnchorAlias +- YtsBasicTests +- YtsBlockMapping +- YtsDocumentSeparator +- YtsErrorTests +- YtsFlowCollections +- YtsFoldedScalars +- YtsNullsAndEmpties +- YtsSpecificationExamples +- YtsTypeTransfers +- unindentedCollections diff --git a/vendor/symfony/yaml/Tests/Fixtures/legacyBooleanMappingKeys.yml b/vendor/symfony/yaml/Tests/Fixtures/legacyBooleanMappingKeys.yml index db950165e..43b507084 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/legacyBooleanMappingKeys.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/legacyBooleanMappingKeys.yml @@ -1,23 +1,23 @@ ---- %YAML:1.0 -test: Miscellaneous -spec: 2.21 -yaml: | - true: true - false: false -php: | - [ - 1 => true, - 0 => false, - ] ---- -test: Boolean -yaml: | - false: used as key - logical: true - answer: false -php: | - [ - false => 'used as key', - 'logical' => true, - 'answer' => false - ] +--- %YAML:1.0 +test: Miscellaneous +spec: 2.21 +yaml: | + true: true + false: false +php: | + [ + 1 => true, + 0 => false, + ] +--- +test: Boolean +yaml: | + false: used as key + logical: true + answer: false +php: | + [ + false => 'used as key', + 'logical' => true, + 'answer' => false + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/legacyNonStringKeys.yml b/vendor/symfony/yaml/Tests/Fixtures/legacyNonStringKeys.yml index 4e2820185..f0fa18327 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/legacyNonStringKeys.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/legacyNonStringKeys.yml @@ -1,2 +1,2 @@ -- legacyBooleanMappingKeys -- legacyNullMappingKey +- legacyBooleanMappingKeys +- legacyNullMappingKey diff --git a/vendor/symfony/yaml/Tests/Fixtures/legacyNullMappingKey.yml b/vendor/symfony/yaml/Tests/Fixtures/legacyNullMappingKey.yml index 14f93c2d1..0ac772965 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/legacyNullMappingKey.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/legacyNullMappingKey.yml @@ -1,9 +1,9 @@ ---- %YAML:1.0 -test: Miscellaneous -spec: 2.21 -yaml: | - null: ~ -php: | - [ - '' => null, - ] +--- %YAML:1.0 +test: Miscellaneous +spec: 2.21 +yaml: | + null: ~ +php: | + [ + '' => null, + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block.yml b/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block.yml index d5ac01436..e7fd69da2 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block.yml @@ -1,14 +1,14 @@ -data: - single_line: 'foo bar baz' - multi_line: | - foo - line with trailing spaces: - - bar - integer like line: - 123456789 - empty line: - - baz - multi_line_with_carriage_return: "_PhpScoper5ea00cc67502b\foo\nbar\r\nbaz" - nested_inlined_multi_line_string: { inlined_multi_line: "_PhpScoper5ea00cc67502b\foo\nbar\r\nempty line:\_PhpScoper5ea00cc67502b\n\nbaz" } +data: + single_line: 'foo bar baz' + multi_line: | + foo + line with trailing spaces: + + bar + integer like line: + 123456789 + empty line: + + baz + multi_line_with_carriage_return: "_PhpScoper5ea00cc67502b\foo\nbar\r\nbaz" + nested_inlined_multi_line_string: { inlined_multi_line: "_PhpScoper5ea00cc67502b\foo\nbar\r\nempty line:\_PhpScoper5ea00cc67502b\n\nbaz" } diff --git a/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block_for_tagged_values.yml b/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block_for_tagged_values.yml index 7023d27ab..b755c5f02 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block_for_tagged_values.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block_for_tagged_values.yml @@ -1,2 +1,2 @@ -data: - foo: !bar "_PhpScoper5ea00cc67502b\foo\r\nline with trailing spaces:\n \_PhpScoper5ea00cc67502b\nbar\ninteger like line:\_PhpScoper5ea00cc67502b\n123456789\nempty line:\_PhpScoper5ea00cc67502b\n\nbaz" +data: + foo: !bar "_PhpScoper5ea00cc67502b\foo\r\nline with trailing spaces:\n \_PhpScoper5ea00cc67502b\nbar\ninteger like line:\_PhpScoper5ea00cc67502b\n123456789\nempty line:\_PhpScoper5ea00cc67502b\n\nbaz" diff --git a/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block_leading_space_in_first_line.yml b/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block_leading_space_in_first_line.yml index 3f2dedd10..949aad9f0 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block_leading_space_in_first_line.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/multiple_lines_as_literal_block_leading_space_in_first_line.yml @@ -1,4 +1,4 @@ -data: - multi_line: |4 - the first line has leading spaces - The second line does not. +data: + multi_line: |4 + the first line has leading spaces + The second line does not. diff --git a/vendor/symfony/yaml/Tests/Fixtures/nonStringKeys.yml b/vendor/symfony/yaml/Tests/Fixtures/nonStringKeys.yml index 354b0791e..840cba968 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/nonStringKeys.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/nonStringKeys.yml @@ -1,3 +1,3 @@ -- booleanMappingKeys -- numericMappingKeys -- nullMappingKey +- booleanMappingKeys +- numericMappingKeys +- nullMappingKey diff --git a/vendor/symfony/yaml/Tests/Fixtures/not_readable.yml b/vendor/symfony/yaml/Tests/Fixtures/not_readable.yml index 3216a89eb..26ab46a2d 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/not_readable.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/not_readable.yml @@ -1,18 +1,18 @@ -- escapedCharacters -- sfComments -- sfCompact -- sfTests -- sfObjects -- sfMergeKey -- sfQuotes -- YtsAnchorAlias -- YtsBasicTests -- YtsBlockMapping -- YtsDocumentSeparator -- YtsErrorTests -- YtsFlowCollections -- YtsFoldedScalars -- YtsNullsAndEmpties -- YtsSpecificationExamples -- YtsTypeTransfers -- unindentedCollections +- escapedCharacters +- sfComments +- sfCompact +- sfTests +- sfObjects +- sfMergeKey +- sfQuotes +- YtsAnchorAlias +- YtsBasicTests +- YtsBlockMapping +- YtsDocumentSeparator +- YtsErrorTests +- YtsFlowCollections +- YtsFoldedScalars +- YtsNullsAndEmpties +- YtsSpecificationExamples +- YtsTypeTransfers +- unindentedCollections diff --git a/vendor/symfony/yaml/Tests/Fixtures/nullMappingKey.yml b/vendor/symfony/yaml/Tests/Fixtures/nullMappingKey.yml index cd90f7b4c..57545ebee 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/nullMappingKey.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/nullMappingKey.yml @@ -1,9 +1,9 @@ ---- %YAML:1.0 -test: Miscellaneous -spec: 2.21 -yaml: | - null: ~ -php: | - [ - 'null' => null, - ] +--- %YAML:1.0 +test: Miscellaneous +spec: 2.21 +yaml: | + null: ~ +php: | + [ + 'null' => null, + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/numericMappingKeys.yml b/vendor/symfony/yaml/Tests/Fixtures/numericMappingKeys.yml index 246447e4d..0227ae7f8 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/numericMappingKeys.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/numericMappingKeys.yml @@ -1,23 +1,23 @@ ---- %YAML:1.0 -test: A sequence with an unordered array -brief: > - A sequence with an unordered array -yaml: | - 1: foo - 0: bar -php: | - [1 => 'foo', 0 => 'bar'] ---- -test: Integers as Map Keys -brief: > - An integer can be used as dictionary key. -yaml: | - 1: one - 2: two - 3: three -php: | - [ - 1 => 'one', - 2 => 'two', - 3 => 'three' - ] +--- %YAML:1.0 +test: A sequence with an unordered array +brief: > + A sequence with an unordered array +yaml: | + 1: foo + 0: bar +php: | + [1 => 'foo', 0 => 'bar'] +--- +test: Integers as Map Keys +brief: > + An integer can be used as dictionary key. +yaml: | + 1: one + 2: two + 3: three +php: | + [ + 1 => 'one', + 2 => 'two', + 3 => 'three' + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/sfComments.yml b/vendor/symfony/yaml/Tests/Fixtures/sfComments.yml index af3ab3859..32202b0b3 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/sfComments.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/sfComments.yml @@ -1,76 +1,76 @@ ---- %YAML:1.0 -test: Comments at the end of a line -brief: > - Comments at the end of a line -yaml: | - ex1: "foo # bar" - ex2: "foo # bar" # comment - ex3: 'foo # bar' # comment - ex4: foo # comment - ex5: foo # comment with tab before - ex6: foo#foo # comment here - ex7: foo # ignore me # and me -php: | - ['ex1' => 'foo # bar', 'ex2' => 'foo # bar', 'ex3' => 'foo # bar', 'ex4' => 'foo', 'ex5' => 'foo', 'ex6' => 'foo#foo', 'ex7' => 'foo'] ---- -test: Comments in the middle -brief: > - Comments in the middle -yaml: | - foo: - # some comment - # some comment - bar: foo - # some comment - # some comment -php: | - ['foo' => ['bar' => 'foo']] ---- -test: Comments on a hash line -brief: > - Comments on a hash line -yaml: | - foo: # a comment - foo: bar # a comment -php: | - ['foo' => ['foo' => 'bar']] ---- -test: 'Value starting with a #' -brief: > - 'Value starting with a #' -yaml: | - foo: '#bar' -php: | - ['foo' => '#bar'] ---- -test: Document starting with a comment and a separator -brief: > - Commenting before document start is allowed -yaml: | - # document comment - --- - foo: bar # a comment -php: | - ['foo' => 'bar'] ---- -test: Comment containing a colon on a hash line -brief: > - Comment containing a colon on a scalar line -yaml: 'foo # comment: this is also part of the comment' -php: | - 'foo' ---- -test: 'Hash key containing a #' -brief: > - 'Hash key containing a #' -yaml: 'foo#bar: baz' -php: | - ['foo#bar' => 'baz'] ---- -test: 'Hash key ending with a space and a #' -brief: > - 'Hash key ending with a space and a #' -yaml: | - 'foo #': baz -php: | - ['foo #' => 'baz'] +--- %YAML:1.0 +test: Comments at the end of a line +brief: > + Comments at the end of a line +yaml: | + ex1: "foo # bar" + ex2: "foo # bar" # comment + ex3: 'foo # bar' # comment + ex4: foo # comment + ex5: foo # comment with tab before + ex6: foo#foo # comment here + ex7: foo # ignore me # and me +php: | + ['ex1' => 'foo # bar', 'ex2' => 'foo # bar', 'ex3' => 'foo # bar', 'ex4' => 'foo', 'ex5' => 'foo', 'ex6' => 'foo#foo', 'ex7' => 'foo'] +--- +test: Comments in the middle +brief: > + Comments in the middle +yaml: | + foo: + # some comment + # some comment + bar: foo + # some comment + # some comment +php: | + ['foo' => ['bar' => 'foo']] +--- +test: Comments on a hash line +brief: > + Comments on a hash line +yaml: | + foo: # a comment + foo: bar # a comment +php: | + ['foo' => ['foo' => 'bar']] +--- +test: 'Value starting with a #' +brief: > + 'Value starting with a #' +yaml: | + foo: '#bar' +php: | + ['foo' => '#bar'] +--- +test: Document starting with a comment and a separator +brief: > + Commenting before document start is allowed +yaml: | + # document comment + --- + foo: bar # a comment +php: | + ['foo' => 'bar'] +--- +test: Comment containing a colon on a hash line +brief: > + Comment containing a colon on a scalar line +yaml: 'foo # comment: this is also part of the comment' +php: | + 'foo' +--- +test: 'Hash key containing a #' +brief: > + 'Hash key containing a #' +yaml: 'foo#bar: baz' +php: | + ['foo#bar' => 'baz'] +--- +test: 'Hash key ending with a space and a #' +brief: > + 'Hash key ending with a space and a #' +yaml: | + 'foo #': baz +php: | + ['foo #' => 'baz'] diff --git a/vendor/symfony/yaml/Tests/Fixtures/sfCompact.yml b/vendor/symfony/yaml/Tests/Fixtures/sfCompact.yml index 8cadae2c1..1e5f9a27c 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/sfCompact.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/sfCompact.yml @@ -1,159 +1,159 @@ ---- %YAML:1.0 -test: Compact notation -brief: | - Compact notation for sets of mappings with single element -yaml: | - --- - # products purchased - - item : Super Hoop - - item : Basketball - quantity: 1 - - item: - name: Big Shoes - nick: Biggies - quantity: 1 -php: | - [ - [ - 'item' => 'Super Hoop', - ], - [ - 'item' => 'Basketball', - 'quantity' => 1, - ], - [ - 'item' => [ - 'name' => 'Big Shoes', - 'nick' => 'Biggies' - ], - 'quantity' => 1 - ] - ] ---- -test: Compact notation combined with inline notation -brief: | - Combinations of compact and inline notation are allowed -yaml: | - --- - items: - - { item: Super Hoop, quantity: 1 } - - [ Basketball, Big Shoes ] -php: | - [ - 'items' => [ - [ - 'item' => 'Super Hoop', - 'quantity' => 1, - ], - [ - 'Basketball', - 'Big Shoes' - ] - ] - ] ---- %YAML:1.0 -test: Compact notation -brief: | - Compact notation for sets of mappings with single element -yaml: | - --- - # products purchased - - item : Super Hoop - - item : Basketball - quantity: 1 - - item: - name: Big Shoes - nick: Biggies - quantity: 1 -php: | - [ - [ - 'item' => 'Super Hoop', - ], - [ - 'item' => 'Basketball', - 'quantity' => 1, - ], - [ - 'item' => [ - 'name' => 'Big Shoes', - 'nick' => 'Biggies' - ], - 'quantity' => 1 - ] - ] ---- -test: Compact notation combined with inline notation -brief: | - Combinations of compact and inline notation are allowed -yaml: | - --- - items: - - { item: Super Hoop, quantity: 1 } - - [ Basketball, Big Shoes ] -php: | - [ - 'items' => [ - [ - 'item' => 'Super Hoop', - 'quantity' => 1, - ], - [ - 'Basketball', - 'Big Shoes' - ] - ] - ] ---- %YAML:1.0 -test: Compact notation -brief: | - Compact notation for sets of mappings with single element -yaml: | - --- - # products purchased - - item : Super Hoop - - item : Basketball - quantity: 1 - - item: - name: Big Shoes - nick: Biggies - quantity: 1 -php: | - [ - [ - 'item' => 'Super Hoop', - ], - [ - 'item' => 'Basketball', - 'quantity' => 1, - ], - [ - 'item' => [ - 'name' => 'Big Shoes', - 'nick' => 'Biggies' - ], - 'quantity' => 1 - ] - ] ---- -test: Compact notation combined with inline notation -brief: | - Combinations of compact and inline notation are allowed -yaml: | - --- - items: - - { item: Super Hoop, quantity: 1 } - - [ Basketball, Big Shoes ] -php: | - [ - 'items' => [ - [ - 'item' => 'Super Hoop', - 'quantity' => 1, - ], - [ - 'Basketball', - 'Big Shoes' - ] - ] - ] +--- %YAML:1.0 +test: Compact notation +brief: | + Compact notation for sets of mappings with single element +yaml: | + --- + # products purchased + - item : Super Hoop + - item : Basketball + quantity: 1 + - item: + name: Big Shoes + nick: Biggies + quantity: 1 +php: | + [ + [ + 'item' => 'Super Hoop', + ], + [ + 'item' => 'Basketball', + 'quantity' => 1, + ], + [ + 'item' => [ + 'name' => 'Big Shoes', + 'nick' => 'Biggies' + ], + 'quantity' => 1 + ] + ] +--- +test: Compact notation combined with inline notation +brief: | + Combinations of compact and inline notation are allowed +yaml: | + --- + items: + - { item: Super Hoop, quantity: 1 } + - [ Basketball, Big Shoes ] +php: | + [ + 'items' => [ + [ + 'item' => 'Super Hoop', + 'quantity' => 1, + ], + [ + 'Basketball', + 'Big Shoes' + ] + ] + ] +--- %YAML:1.0 +test: Compact notation +brief: | + Compact notation for sets of mappings with single element +yaml: | + --- + # products purchased + - item : Super Hoop + - item : Basketball + quantity: 1 + - item: + name: Big Shoes + nick: Biggies + quantity: 1 +php: | + [ + [ + 'item' => 'Super Hoop', + ], + [ + 'item' => 'Basketball', + 'quantity' => 1, + ], + [ + 'item' => [ + 'name' => 'Big Shoes', + 'nick' => 'Biggies' + ], + 'quantity' => 1 + ] + ] +--- +test: Compact notation combined with inline notation +brief: | + Combinations of compact and inline notation are allowed +yaml: | + --- + items: + - { item: Super Hoop, quantity: 1 } + - [ Basketball, Big Shoes ] +php: | + [ + 'items' => [ + [ + 'item' => 'Super Hoop', + 'quantity' => 1, + ], + [ + 'Basketball', + 'Big Shoes' + ] + ] + ] +--- %YAML:1.0 +test: Compact notation +brief: | + Compact notation for sets of mappings with single element +yaml: | + --- + # products purchased + - item : Super Hoop + - item : Basketball + quantity: 1 + - item: + name: Big Shoes + nick: Biggies + quantity: 1 +php: | + [ + [ + 'item' => 'Super Hoop', + ], + [ + 'item' => 'Basketball', + 'quantity' => 1, + ], + [ + 'item' => [ + 'name' => 'Big Shoes', + 'nick' => 'Biggies' + ], + 'quantity' => 1 + ] + ] +--- +test: Compact notation combined with inline notation +brief: | + Combinations of compact and inline notation are allowed +yaml: | + --- + items: + - { item: Super Hoop, quantity: 1 } + - [ Basketball, Big Shoes ] +php: | + [ + 'items' => [ + [ + 'item' => 'Super Hoop', + 'quantity' => 1, + ], + [ + 'Basketball', + 'Big Shoes' + ] + ] + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/sfMergeKey.yml b/vendor/symfony/yaml/Tests/Fixtures/sfMergeKey.yml index af787ae43..d1d512741 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/sfMergeKey.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/sfMergeKey.yml @@ -1,61 +1,61 @@ ---- %YAML:1.0 -test: Simple In Place Substitution -brief: > - If you want to reuse an entire alias, only overwriting what is different - you can use a << in place substitution. This is not part of the official - YAML spec, but a widely implemented extension. See the following URL for - details: http://yaml.org/type/merge.html -yaml: | - foo: &foo - a: Steve - b: Clark - c: Brian - e: notnull - bar: - a: before - d: other - e: ~ - <<: *foo - b: new - x: Oren - c: - foo: bar - bar: foo - bar_inline: {a: before, d: other, <<: *foo, b: new, x: Oren, c: { foo: bar, bar: foo}} - foo2: &foo2 - a: Ballmer - ding: &dong [ fi, fei, fo, fam] - check: - <<: - - *foo - - *dong - isit: tested - head: - <<: [ *foo , *dong , *foo2 ] - taz: &taz - a: Steve - w: - p: 1234 - nested: - <<: *taz - d: Doug - w: &nestedref - p: 12345 - z: - <<: *nestedref - head_inline: &head_inline { <<: [ *foo , *dong , *foo2 ] } - recursive_inline: { <<: *head_inline, c: { <<: *foo2 } } -php: | - [ - 'foo' => ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian', 'e' => 'notnull'], - 'bar' => ['a' => 'before', 'd' => 'other', 'e' => null, 'b' => 'new', 'c' => ['foo' => 'bar', 'bar' => 'foo'], 'x' => 'Oren'], - 'bar_inline' => ['a' => 'before', 'd' => 'other', 'b' => 'new', 'c' => ['foo' => 'bar', 'bar' => 'foo'], 'e' => 'notnull', 'x' => 'Oren'], - 'foo2' => ['a' => 'Ballmer'], - 'ding' => ['fi', 'fei', 'fo', 'fam'], - 'check' => ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian', 'e' => 'notnull', 'fi', 'fei', 'fo', 'fam', 'isit' => 'tested'], - 'head' => ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian', 'e' => 'notnull', 'fi', 'fei', 'fo', 'fam'], - 'taz' => ['a' => 'Steve', 'w' => ['p' => 1234]], - 'nested' => ['a' => 'Steve', 'w' => ['p' => 12345], 'd' => 'Doug', 'z' => ['p' => 12345]], - 'head_inline' => ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian', 'e' => 'notnull', 'fi', 'fei', 'fo', 'fam'], - 'recursive_inline' => ['a' => 'Steve', 'b' => 'Clark', 'c' => ['a' => 'Ballmer'], 'e' => 'notnull', 'fi', 'fei', 'fo', 'fam'], - ] +--- %YAML:1.0 +test: Simple In Place Substitution +brief: > + If you want to reuse an entire alias, only overwriting what is different + you can use a << in place substitution. This is not part of the official + YAML spec, but a widely implemented extension. See the following URL for + details: http://yaml.org/type/merge.html +yaml: | + foo: &foo + a: Steve + b: Clark + c: Brian + e: notnull + bar: + a: before + d: other + e: ~ + <<: *foo + b: new + x: Oren + c: + foo: bar + bar: foo + bar_inline: {a: before, d: other, <<: *foo, b: new, x: Oren, c: { foo: bar, bar: foo}} + foo2: &foo2 + a: Ballmer + ding: &dong [ fi, fei, fo, fam] + check: + <<: + - *foo + - *dong + isit: tested + head: + <<: [ *foo , *dong , *foo2 ] + taz: &taz + a: Steve + w: + p: 1234 + nested: + <<: *taz + d: Doug + w: &nestedref + p: 12345 + z: + <<: *nestedref + head_inline: &head_inline { <<: [ *foo , *dong , *foo2 ] } + recursive_inline: { <<: *head_inline, c: { <<: *foo2 } } +php: | + [ + 'foo' => ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian', 'e' => 'notnull'], + 'bar' => ['a' => 'before', 'd' => 'other', 'e' => null, 'b' => 'new', 'c' => ['foo' => 'bar', 'bar' => 'foo'], 'x' => 'Oren'], + 'bar_inline' => ['a' => 'before', 'd' => 'other', 'b' => 'new', 'c' => ['foo' => 'bar', 'bar' => 'foo'], 'e' => 'notnull', 'x' => 'Oren'], + 'foo2' => ['a' => 'Ballmer'], + 'ding' => ['fi', 'fei', 'fo', 'fam'], + 'check' => ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian', 'e' => 'notnull', 'fi', 'fei', 'fo', 'fam', 'isit' => 'tested'], + 'head' => ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian', 'e' => 'notnull', 'fi', 'fei', 'fo', 'fam'], + 'taz' => ['a' => 'Steve', 'w' => ['p' => 1234]], + 'nested' => ['a' => 'Steve', 'w' => ['p' => 12345], 'd' => 'Doug', 'z' => ['p' => 12345]], + 'head_inline' => ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian', 'e' => 'notnull', 'fi', 'fei', 'fo', 'fam'], + 'recursive_inline' => ['a' => 'Steve', 'b' => 'Clark', 'c' => ['a' => 'Ballmer'], 'e' => 'notnull', 'fi', 'fei', 'fo', 'fam'], + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/sfObjects.yml b/vendor/symfony/yaml/Tests/Fixtures/sfObjects.yml index 144615f2a..37879ae0e 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/sfObjects.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/sfObjects.yml @@ -1,11 +1,11 @@ ---- %YAML:1.0 -test: Objects -brief: > - Comments at the end of a line -yaml: | - ex1: "foo # bar" - ex2: "foo # bar" # comment - ex3: 'foo # bar' # comment - ex4: foo # comment -php: | - ['ex1' => 'foo # bar', 'ex2' => 'foo # bar', 'ex3' => 'foo # bar', 'ex4' => 'foo'] +--- %YAML:1.0 +test: Objects +brief: > + Comments at the end of a line +yaml: | + ex1: "foo # bar" + ex2: "foo # bar" # comment + ex3: 'foo # bar' # comment + ex4: foo # comment +php: | + ['ex1' => 'foo # bar', 'ex2' => 'foo # bar', 'ex3' => 'foo # bar', 'ex4' => 'foo'] diff --git a/vendor/symfony/yaml/Tests/Fixtures/sfQuotes.yml b/vendor/symfony/yaml/Tests/Fixtures/sfQuotes.yml index c8326fdb2..98b9db868 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/sfQuotes.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/sfQuotes.yml @@ -1,33 +1,33 @@ ---- %YAML:1.0 -test: Some characters at the beginning of a string must be escaped -brief: > - Some characters at the beginning of a string must be escaped -yaml: | - foo: '| bar' -php: | - ['foo' => '| bar'] ---- -test: A key can be a quoted string -brief: > - A key can be a quoted string -yaml: | - "foo1": bar - 'foo2': bar - "foo \" bar": bar - 'foo '' bar': bar - 'foo3: ': bar - "foo4: ": bar - foo5: { "foo \" bar: ": bar, 'foo '' bar: ': bar } -php: | - [ - 'foo1' => 'bar', - 'foo2' => 'bar', - 'foo " bar' => 'bar', - 'foo \' bar' => 'bar', - 'foo3: ' => 'bar', - 'foo4: ' => 'bar', - 'foo5' => [ - 'foo " bar: ' => 'bar', - 'foo \' bar: ' => 'bar', - ], - ] +--- %YAML:1.0 +test: Some characters at the beginning of a string must be escaped +brief: > + Some characters at the beginning of a string must be escaped +yaml: | + foo: '| bar' +php: | + ['foo' => '| bar'] +--- +test: A key can be a quoted string +brief: > + A key can be a quoted string +yaml: | + "foo1": bar + 'foo2': bar + "foo \" bar": bar + 'foo '' bar': bar + 'foo3: ': bar + "foo4: ": bar + foo5: { "foo \" bar: ": bar, 'foo '' bar: ': bar } +php: | + [ + 'foo1' => 'bar', + 'foo2' => 'bar', + 'foo " bar' => 'bar', + 'foo \' bar' => 'bar', + 'foo3: ' => 'bar', + 'foo4: ' => 'bar', + 'foo5' => [ + 'foo " bar: ' => 'bar', + 'foo \' bar: ' => 'bar', + ], + ] diff --git a/vendor/symfony/yaml/Tests/Fixtures/sfTests.yml b/vendor/symfony/yaml/Tests/Fixtures/sfTests.yml index 1aff37473..2204fe4d2 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/sfTests.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/sfTests.yml @@ -1,140 +1,140 @@ ---- %YAML:1.0 -test: Multiple quoted string on one line -brief: > - Multiple quoted string on one line -yaml: | - stripped_title: { name: "foo bar", help: "bar foo" } -php: | - ['stripped_title' => ['name' => 'foo bar', 'help' => 'bar foo']] ---- -test: Empty sequence -yaml: | - foo: [ ] -php: | - ['foo' => []] ---- -test: Empty value -yaml: | - foo: -php: | - ['foo' => null] ---- -test: Inline string parsing -brief: > - Inline string parsing -yaml: | - test: ['complex: string', 'another [string]'] -php: | - ['test' => ['complex: string', 'another [string]']] ---- -test: Boolean -brief: > - Boolean -yaml: | - - false - - true - - null - - ~ - - 'false' - - 'true' - - 'null' - - '~' -php: | - [ - false, - true, - null, - null, - 'false', - 'true', - 'null', - '~', - ] ---- -test: Empty lines in literal blocks -brief: > - Empty lines in literal blocks -yaml: | - foo: - bar: | - foo - - - - bar -php: | - ['foo' => ['bar' => "_PhpScoper5ea00cc67502b\foo\n\n\n \_PhpScoper5ea00cc67502b\nbar\n"]] ---- -test: Empty lines in folded blocks -brief: > - Empty lines in folded blocks -yaml: | - foo: - bar: > - - foo - - - bar -php: | - ['foo' => ['bar' => "\_PhpScoper5ea00cc67502b\nfoo\n\nbar\n"]] ---- -test: IP addresses -brief: > - IP addresses -yaml: | - foo: 10.0.0.2 -php: | - ['foo' => '10.0.0.2'] ---- -test: A sequence with an embedded mapping -brief: > - A sequence with an embedded mapping -yaml: | - - foo - - bar: { bar: foo } -php: | - ['foo', ['bar' => ['bar' => 'foo']]] ---- -test: Octal -brief: as in spec example 2.19, octal value is converted -yaml: | - foo: 0123 -php: | - ['foo' => 83] ---- -test: Octal strings -brief: Octal notation in a string must remain a string -yaml: | - foo: "0123" -php: | - ['foo' => '0123'] ---- -test: Octal strings -brief: Octal notation in a string must remain a string -yaml: | - foo: '0123' -php: | - ['foo' => '0123'] ---- -test: Octal strings -brief: Octal notation in a string must remain a string -yaml: | - foo: | - 0123 -php: | - ['foo' => "_PhpScoper5ea00cc67502b\0123\n"] ---- -test: Document as a simple hash -brief: Document as a simple hash -yaml: | - { foo: bar } -php: | - ['foo' => 'bar'] ---- -test: Document as a simple array -brief: Document as a simple array -yaml: | - [ foo, bar ] -php: | - ['foo', 'bar'] +--- %YAML:1.0 +test: Multiple quoted string on one line +brief: > + Multiple quoted string on one line +yaml: | + stripped_title: { name: "foo bar", help: "bar foo" } +php: | + ['stripped_title' => ['name' => 'foo bar', 'help' => 'bar foo']] +--- +test: Empty sequence +yaml: | + foo: [ ] +php: | + ['foo' => []] +--- +test: Empty value +yaml: | + foo: +php: | + ['foo' => null] +--- +test: Inline string parsing +brief: > + Inline string parsing +yaml: | + test: ['complex: string', 'another [string]'] +php: | + ['test' => ['complex: string', 'another [string]']] +--- +test: Boolean +brief: > + Boolean +yaml: | + - false + - true + - null + - ~ + - 'false' + - 'true' + - 'null' + - '~' +php: | + [ + false, + true, + null, + null, + 'false', + 'true', + 'null', + '~', + ] +--- +test: Empty lines in literal blocks +brief: > + Empty lines in literal blocks +yaml: | + foo: + bar: | + foo + + + + bar +php: | + ['foo' => ['bar' => "_PhpScoper5ea00cc67502b\foo\n\n\n \_PhpScoper5ea00cc67502b\nbar\n"]] +--- +test: Empty lines in folded blocks +brief: > + Empty lines in folded blocks +yaml: | + foo: + bar: > + + foo + + + bar +php: | + ['foo' => ['bar' => "\_PhpScoper5ea00cc67502b\nfoo\n\nbar\n"]] +--- +test: IP addresses +brief: > + IP addresses +yaml: | + foo: 10.0.0.2 +php: | + ['foo' => '10.0.0.2'] +--- +test: A sequence with an embedded mapping +brief: > + A sequence with an embedded mapping +yaml: | + - foo + - bar: { bar: foo } +php: | + ['foo', ['bar' => ['bar' => 'foo']]] +--- +test: Octal +brief: as in spec example 2.19, octal value is converted +yaml: | + foo: 0123 +php: | + ['foo' => 83] +--- +test: Octal strings +brief: Octal notation in a string must remain a string +yaml: | + foo: "0123" +php: | + ['foo' => '0123'] +--- +test: Octal strings +brief: Octal notation in a string must remain a string +yaml: | + foo: '0123' +php: | + ['foo' => '0123'] +--- +test: Octal strings +brief: Octal notation in a string must remain a string +yaml: | + foo: | + 0123 +php: | + ['foo' => "_PhpScoper5ea00cc67502b\0123\n"] +--- +test: Document as a simple hash +brief: Document as a simple hash +yaml: | + { foo: bar } +php: | + ['foo' => 'bar'] +--- +test: Document as a simple array +brief: Document as a simple array +yaml: | + [ foo, bar ] +php: | + ['foo', 'bar'] diff --git a/vendor/symfony/yaml/Tests/Fixtures/unindentedCollections.yml b/vendor/symfony/yaml/Tests/Fixtures/unindentedCollections.yml index c85952df4..35cc946b9 100644 --- a/vendor/symfony/yaml/Tests/Fixtures/unindentedCollections.yml +++ b/vendor/symfony/yaml/Tests/Fixtures/unindentedCollections.yml @@ -1,82 +1,82 @@ ---- %YAML:1.0 -test: Unindented collection -brief: > - Unindented collection -yaml: | - collection: - - item1 - - item2 - - item3 -php: | - ['collection' => ['item1', 'item2', 'item3']] ---- -test: Nested unindented collection (two levels) -brief: > - Nested unindented collection -yaml: | - collection: - key: - - a - - b - - c -php: | - ['collection' => ['key' => ['a', 'b', 'c']]] ---- -test: Nested unindented collection (three levels) -brief: > - Nested unindented collection -yaml: | - collection: - key: - subkey: - - one - - two - - three -php: | - ['collection' => ['key' => ['subkey' => ['one', 'two', 'three']]]] ---- -test: Key/value after unindented collection (1) -brief: > - Key/value after unindented collection (1) -yaml: | - collection: - key: - - a - - b - - c - foo: bar -php: | - ['collection' => ['key' => ['a', 'b', 'c']], 'foo' => 'bar'] ---- -test: Key/value after unindented collection (at the same level) -brief: > - Key/value after unindented collection -yaml: | - collection: - key: - - a - - b - - c - foo: bar -php: | - ['collection' => ['key' => ['a', 'b', 'c'], 'foo' => 'bar']] ---- -test: Shortcut Key after unindented collection -brief: > - Key/value after unindented collection -yaml: | - collection: - - key: foo - foo: bar -php: | - ['collection' => [['key' => 'foo', 'foo' => 'bar']]] ---- -test: Shortcut Key after unindented collection with custom spaces -brief: > - Key/value after unindented collection -yaml: | - collection: - - key: foo - foo: bar -php: | - ['collection' => [['key' => 'foo', 'foo' => 'bar']]] +--- %YAML:1.0 +test: Unindented collection +brief: > + Unindented collection +yaml: | + collection: + - item1 + - item2 + - item3 +php: | + ['collection' => ['item1', 'item2', 'item3']] +--- +test: Nested unindented collection (two levels) +brief: > + Nested unindented collection +yaml: | + collection: + key: + - a + - b + - c +php: | + ['collection' => ['key' => ['a', 'b', 'c']]] +--- +test: Nested unindented collection (three levels) +brief: > + Nested unindented collection +yaml: | + collection: + key: + subkey: + - one + - two + - three +php: | + ['collection' => ['key' => ['subkey' => ['one', 'two', 'three']]]] +--- +test: Key/value after unindented collection (1) +brief: > + Key/value after unindented collection (1) +yaml: | + collection: + key: + - a + - b + - c + foo: bar +php: | + ['collection' => ['key' => ['a', 'b', 'c']], 'foo' => 'bar'] +--- +test: Key/value after unindented collection (at the same level) +brief: > + Key/value after unindented collection +yaml: | + collection: + key: + - a + - b + - c + foo: bar +php: | + ['collection' => ['key' => ['a', 'b', 'c'], 'foo' => 'bar']] +--- +test: Shortcut Key after unindented collection +brief: > + Key/value after unindented collection +yaml: | + collection: + - key: foo + foo: bar +php: | + ['collection' => [['key' => 'foo', 'foo' => 'bar']]] +--- +test: Shortcut Key after unindented collection with custom spaces +brief: > + Key/value after unindented collection +yaml: | + collection: + - key: foo + foo: bar +php: | + ['collection' => [['key' => 'foo', 'foo' => 'bar']]] diff --git a/vendor/symfony/yaml/Tests/InlineTest.php b/vendor/symfony/yaml/Tests/InlineTest.php index 2c3870226..59a6a1a39 100644 --- a/vendor/symfony/yaml/Tests/InlineTest.php +++ b/vendor/symfony/yaml/Tests/InlineTest.php @@ -1,644 +1,644 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; -class InlineTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - protected function setUp() - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::initialize(0, 0); - } - /** - * @dataProvider getTestsForParse - */ - public function testParse($yaml, $value, $flags = 0) - { - $this->assertSame($value, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, $flags), \sprintf('::parse() converts an inline YAML to a PHP structure (%s)', $yaml)); - } - /** - * @dataProvider getTestsForParseWithMapObjects - */ - public function testParseWithMapObjects($yaml, $value, $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP) - { - $actual = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, $flags); - $this->assertSame(\serialize($value), \serialize($actual)); - } - /** - * @dataProvider getTestsForParsePhpConstants - */ - public function testParsePhpConstants($yaml, $value) - { - $actual = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT); - $this->assertSame($value, $actual); - } - public function getTestsForParsePhpConstants() - { - return [['!php/const Symfony\\Component\\Yaml\\Yaml::PARSE_CONSTANT', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT], ['!php/const PHP_INT_MAX', \PHP_INT_MAX], ['[!php/const PHP_INT_MAX]', [\PHP_INT_MAX]], ['{ foo: !php/const PHP_INT_MAX }', ['foo' => \PHP_INT_MAX]], ['{ !php/const PHP_INT_MAX: foo }', [\PHP_INT_MAX => 'foo']], ['!php/const NULL', null]]; - } - public function testParsePhpConstantThrowsExceptionWhenUndefined() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('The constant "WRONG_CONSTANT" is not defined'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('!php/const WRONG_CONSTANT', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT); - } - public function testParsePhpConstantThrowsExceptionOnInvalidType() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessageRegExp('#The string "!php/const PHP_INT_MAX" could not be parsed as a constant.*#'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('!php/const PHP_INT_MAX', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE); - } - /** - * @group legacy - * @expectedDeprecation The !php/const: tag to indicate dumped PHP constants is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/const (without the colon) tag instead on line 1. - * @dataProvider getTestsForParseLegacyPhpConstants - */ - public function testDeprecatedConstantTag($yaml, $expectedValue) - { - $this->assertSame($expectedValue, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT)); - } - public function getTestsForParseLegacyPhpConstants() - { - return [['!php/const:Symfony\\Component\\Yaml\\Yaml::PARSE_CONSTANT', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT], ['!php/const:PHP_INT_MAX', \PHP_INT_MAX], ['[!php/const:PHP_INT_MAX]', [\PHP_INT_MAX]], ['{ foo: !php/const:PHP_INT_MAX }', ['foo' => \PHP_INT_MAX]], ['{ !php/const:PHP_INT_MAX: foo }', [\PHP_INT_MAX => 'foo']], ['!php/const:NULL', null]]; - } - /** - * @group legacy - * @dataProvider getTestsForParseWithMapObjects - */ - public function testParseWithMapObjectsPassingTrue($yaml, $value) - { - $actual = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, \false, \false, \true); - $this->assertSame(\serialize($value), \serialize($actual)); - } - /** - * @dataProvider getTestsForDump - */ - public function testDump($yaml, $value, $parseFlags = 0) - { - $this->assertEquals($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($value), \sprintf('::dump() converts a PHP structure to an inline YAML (%s)', $yaml)); - $this->assertSame($value, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse(\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($value), $parseFlags), 'check consistency'); - } - public function testDumpNumericValueWithLocale() - { - $locale = \setlocale(\LC_NUMERIC, 0); - if (\false === $locale) { - $this->markTestSkipped('Your platform does not support locales.'); - } - try { - $requiredLocales = ['fr_FR.UTF-8', 'fr_FR.UTF8', 'fr_FR.utf-8', 'fr_FR.utf8', 'French_France.1252']; - if (\false === \setlocale(\LC_NUMERIC, $requiredLocales)) { - $this->markTestSkipped('Could not set any of required locales: ' . \implode(', ', $requiredLocales)); - } - $this->assertEquals('1.2', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump(1.2)); - $this->assertStringContainsStringIgnoringCase('fr', \setlocale(\LC_NUMERIC, 0)); - } finally { - \setlocale(\LC_NUMERIC, $locale); - } - } - public function testHashStringsResemblingExponentialNumericsShouldNotBeChangedToINF() - { - $value = '686e444'; - $this->assertSame($value, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse(\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($value))); - } - public function testParseScalarWithNonEscapedBlackslashShouldThrowException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('Found unknown escape character "\\V".'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('"Foo\\Var"'); - } - public function testParseScalarWithNonEscapedBlackslashAtTheEndShouldThrowException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('"Foo\\"'); - } - public function testParseScalarWithIncorrectlyQuotedStringShouldThrowException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $value = "'don't do somthin' like that'"; - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value); - } - public function testParseScalarWithIncorrectlyDoubleQuotedStringShouldThrowException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $value = '"don"t do somthin" like that"'; - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value); - } - public function testParseInvalidMappingKeyShouldThrowException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $value = '{ "foo " bar": "bar" }'; - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value); - } - /** - * @group legacy - * @expectedDeprecation Using a colon after an unquoted mapping key that is not followed by an indication character (i.e. " ", ",", "[", "]", "{", "}") is deprecated since Symfony 3.2 and will throw a ParseException in 4.0 on line 1. - * throws \Symfony\Component\Yaml\Exception\ParseException in 4.0 - */ - public function testParseMappingKeyWithColonNotFollowedBySpace() - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{1:""}'); - } - public function testParseInvalidMappingShouldThrowException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('[foo] bar'); - } - public function testParseInvalidSequenceShouldThrowException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ foo: bar } bar'); - } - public function testParseInvalidTaggedSequenceShouldThrowException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('!foo { bar: baz } qux', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS); - } - public function testParseScalarWithCorrectlyQuotedStringShouldReturnString() - { - $value = "'don''t do somthin'' like that'"; - $expect = "don't do somthin' like that"; - $this->assertSame($expect, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parseScalar($value)); - } - /** - * @dataProvider getDataForParseReferences - */ - public function testParseReferences($yaml, $expected) - { - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, 0, ['var' => 'var-value'])); - } - /** - * @group legacy - * @dataProvider getDataForParseReferences - */ - public function testParseReferencesAsFifthArgument($yaml, $expected) - { - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, \false, \false, \false, ['var' => 'var-value'])); - } - public function getDataForParseReferences() - { - return ['scalar' => ['*var', 'var-value'], 'list' => ['[ *var ]', ['var-value']], 'list-in-list' => ['[[ *var ]]', [['var-value']]], 'map-in-list' => ['[ { key: *var } ]', [['key' => 'var-value']]], 'embedded-mapping-in-list' => ['[ key: *var ]', [['key' => 'var-value']]], 'map' => ['{ key: *var }', ['key' => 'var-value']], 'list-in-map' => ['{ key: [*var] }', ['key' => ['var-value']]], 'map-in-map' => ['{ foo: { bar: *var } }', ['foo' => ['bar' => 'var-value']]]]; - } - public function testParseMapReferenceInSequence() - { - $foo = ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian']; - $this->assertSame([$foo], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('[*foo]', 0, ['foo' => $foo])); - } - /** - * @group legacy - */ - public function testParseMapReferenceInSequenceAsFifthArgument() - { - $foo = ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian']; - $this->assertSame([$foo], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('[*foo]', \false, \false, \false, ['foo' => $foo])); - } - public function testParseUnquotedAsterisk() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('A reference must contain at least one character at line 1.'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ foo: * }'); - } - public function testParseUnquotedAsteriskFollowedByAComment() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('A reference must contain at least one character at line 1.'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ foo: * #foo }'); - } - /** - * @dataProvider getReservedIndicators - */ - public function testParseUnquotedScalarStartingWithReservedIndicator($indicator) - { - $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException::class); - $this->expectExceptionMessage(\sprintf('cannot start a plain scalar; you need to quote the scalar at line 1 (near "%sfoo ").', $indicator)); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse(\sprintf('{ foo: %sfoo }', $indicator)); - } - public function getReservedIndicators() - { - return [['@'], ['`']]; - } - /** - * @dataProvider getScalarIndicators - */ - public function testParseUnquotedScalarStartingWithScalarIndicator($indicator) - { - $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException::class); - $this->expectExceptionMessage(\sprintf('cannot start a plain scalar; you need to quote the scalar at line 1 (near "%sfoo ").', $indicator)); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse(\sprintf('{ foo: %sfoo }', $indicator)); - } - public function getScalarIndicators() - { - return [['|'], ['>']]; - } - /** - * @group legacy - * @expectedDeprecation Not quoting the scalar "%bar " starting with the "%" indicator character is deprecated since Symfony 3.1 and will throw a ParseException in 4.0 on line 1. - * throws \Symfony\Component\Yaml\Exception\ParseException in 4.0 - */ - public function testParseUnquotedScalarStartingWithPercentCharacter() - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ foo: %bar }'); - } - /** - * @dataProvider getDataForIsHash - */ - public function testIsHash($array, $expected) - { - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::isHash($array)); - } - public function getDataForIsHash() - { - return [[[], \false], [[1, 2, 3], \false], [[2 => 1, 1 => 2, 0 => 3], \true], [['foo' => 1, 'bar' => 2], \true]]; - } - public function getTestsForParse() - { - return [ - ['', ''], - ['null', null], - ['false', \false], - ['true', \true], - ['12', 12], - ['-12', -12], - ['1_2', 12], - ['_12', '_12'], - ['12_', 12], - ['"quoted string"', 'quoted string'], - ["'quoted string'", 'quoted string'], - ['12.30e+02', 1230.0], - ['123.45_67', 123.4567], - ['0x4D2', 0x4d2], - ['0x_4_D_2_', 0x4d2], - ['02333', 02333], - ['0_2_3_3_3', 02333], - ['.Inf', -\log(0)], - ['-.Inf', \log(0)], - ["'686e444'", '686e444'], - ['686e444', \INF], - ['123456789123456789123456789123456789', '123456789123456789123456789123456789'], - ['"foo\\r\\nbar"', "foo\r\nbar"], - ["'foo#bar'", 'foo#bar'], - ["'foo # bar'", 'foo # bar'], - ["'#cfcfcf'", '#cfcfcf'], - ['::form_base.html.twig', '::form_base.html.twig'], - // Pre-YAML-1.2 booleans - ["'y'", 'y'], - ["'n'", 'n'], - ["'yes'", 'yes'], - ["'no'", 'no'], - ["'on'", 'on'], - ["'off'", 'off'], - ['2007-10-30', \gmmktime(0, 0, 0, 10, 30, 2007)], - ['2007-10-30T02:59:43Z', \gmmktime(2, 59, 43, 10, 30, 2007)], - ['2007-10-30 02:59:43 Z', \gmmktime(2, 59, 43, 10, 30, 2007)], - ['1960-10-30 02:59:43 Z', \gmmktime(2, 59, 43, 10, 30, 1960)], - ['1730-10-30T02:59:43Z', \gmmktime(2, 59, 43, 10, 30, 1730)], - ['"a \\"string\\" with \'quoted strings inside\'"', 'a "string" with \'quoted strings inside\''], - ["'a \"string\" with ''quoted strings inside'''", 'a "string" with \'quoted strings inside\''], - // sequences - // urls are no key value mapping. see #3609. Valid yaml "key: value" mappings require a space after the colon - ['[foo, http://urls.are/no/mappings, false, null, 12]', ['foo', 'http://urls.are/no/mappings', \false, null, 12]], - ['[ foo , bar , false , null , 12 ]', ['foo', 'bar', \false, null, 12]], - ['[\'foo,bar\', \'foo bar\']', ['foo,bar', 'foo bar']], - // mappings - ['{foo: bar,bar: foo,"false": false, "null": null,integer: 12}', ['foo' => 'bar', 'bar' => 'foo', 'false' => \false, 'null' => null, 'integer' => 12]], - ['{ foo : bar, bar : foo, "false" : false, "null" : null, integer : 12 }', ['foo' => 'bar', 'bar' => 'foo', 'false' => \false, 'null' => null, 'integer' => 12]], - ['{foo: \'bar\', bar: \'foo: bar\'}', ['foo' => 'bar', 'bar' => 'foo: bar']], - ['{\'foo\': \'bar\', "bar": \'foo: bar\'}', ['foo' => 'bar', 'bar' => 'foo: bar']], - ['{\'foo\'\'\': \'bar\', "bar\\"": \'foo: bar\'}', ['foo\'' => 'bar', 'bar"' => 'foo: bar']], - ['{\'foo: \': \'bar\', "bar: ": \'foo: bar\'}', ['foo: ' => 'bar', 'bar: ' => 'foo: bar']], - ['{"foo:bar": "baz"}', ['foo:bar' => 'baz']], - ['{"foo":"bar"}', ['foo' => 'bar']], - // nested sequences and mappings - ['[foo, [bar, foo]]', ['foo', ['bar', 'foo']]], - ['[foo, {bar: foo}]', ['foo', ['bar' => 'foo']]], - ['{ foo: {bar: foo} }', ['foo' => ['bar' => 'foo']]], - ['{ foo: [bar, foo] }', ['foo' => ['bar', 'foo']]], - ['{ foo:{bar: foo} }', ['foo' => ['bar' => 'foo']]], - ['{ foo:[bar, foo] }', ['foo' => ['bar', 'foo']]], - ['[ foo, [ bar, foo ] ]', ['foo', ['bar', 'foo']]], - ['[{ foo: {bar: foo} }]', [['foo' => ['bar' => 'foo']]]], - ['[foo, [bar, [foo, [bar, foo]], foo]]', ['foo', ['bar', ['foo', ['bar', 'foo']], 'foo']]], - ['[foo, {bar: foo, foo: [foo, {bar: foo}]}, [foo, {bar: foo}]]', ['foo', ['bar' => 'foo', 'foo' => ['foo', ['bar' => 'foo']]], ['foo', ['bar' => 'foo']]]], - ['[foo, bar: { foo: bar }]', ['foo', '1' => ['bar' => ['foo' => 'bar']]]], - ['[foo, \'@foo.baz\', { \'%foo%\': \'foo is %foo%\', bar: \'%foo%\' }, true, \'@service_container\']', ['foo', '@foo.baz', ['%foo%' => 'foo is %foo%', 'bar' => '%foo%'], \true, '@service_container']], - ]; - } - public function getTestsForParseWithMapObjects() - { - return [ - ['', ''], - ['null', null], - ['false', \false], - ['true', \true], - ['12', 12], - ['-12', -12], - ['"quoted string"', 'quoted string'], - ["'quoted string'", 'quoted string'], - ['12.30e+02', 1230.0], - ['0x4D2', 0x4d2], - ['02333', 02333], - ['.Inf', -\log(0)], - ['-.Inf', \log(0)], - ["'686e444'", '686e444'], - ['686e444', \INF], - ['123456789123456789123456789123456789', '123456789123456789123456789123456789'], - ['"foo\\r\\nbar"', "foo\r\nbar"], - ["'foo#bar'", 'foo#bar'], - ["'foo # bar'", 'foo # bar'], - ["'#cfcfcf'", '#cfcfcf'], - ['::form_base.html.twig', '::form_base.html.twig'], - ['2007-10-30', \gmmktime(0, 0, 0, 10, 30, 2007)], - ['2007-10-30T02:59:43Z', \gmmktime(2, 59, 43, 10, 30, 2007)], - ['2007-10-30 02:59:43 Z', \gmmktime(2, 59, 43, 10, 30, 2007)], - ['1960-10-30 02:59:43 Z', \gmmktime(2, 59, 43, 10, 30, 1960)], - ['1730-10-30T02:59:43Z', \gmmktime(2, 59, 43, 10, 30, 1730)], - ['"a \\"string\\" with \'quoted strings inside\'"', 'a "string" with \'quoted strings inside\''], - ["'a \"string\" with ''quoted strings inside'''", 'a "string" with \'quoted strings inside\''], - // sequences - // urls are no key value mapping. see #3609. Valid yaml "key: value" mappings require a space after the colon - ['[foo, http://urls.are/no/mappings, false, null, 12]', ['foo', 'http://urls.are/no/mappings', \false, null, 12]], - ['[ foo , bar , false , null , 12 ]', ['foo', 'bar', \false, null, 12]], - ['[\'foo,bar\', \'foo bar\']', ['foo,bar', 'foo bar']], - // mappings - ['{foo: bar,bar: foo,"false": false,"null": null,integer: 12}', (object) ['foo' => 'bar', 'bar' => 'foo', 'false' => \false, 'null' => null, 'integer' => 12], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP], - ['{ foo : bar, bar : foo, "false" : false, "null" : null, integer : 12 }', (object) ['foo' => 'bar', 'bar' => 'foo', 'false' => \false, 'null' => null, 'integer' => 12], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP], - ['{foo: \'bar\', bar: \'foo: bar\'}', (object) ['foo' => 'bar', 'bar' => 'foo: bar']], - ['{\'foo\': \'bar\', "bar": \'foo: bar\'}', (object) ['foo' => 'bar', 'bar' => 'foo: bar']], - ['{\'foo\'\'\': \'bar\', "bar\\"": \'foo: bar\'}', (object) ['foo\'' => 'bar', 'bar"' => 'foo: bar']], - ['{\'foo: \': \'bar\', "bar: ": \'foo: bar\'}', (object) ['foo: ' => 'bar', 'bar: ' => 'foo: bar']], - ['{"foo:bar": "baz"}', (object) ['foo:bar' => 'baz']], - ['{"foo":"bar"}', (object) ['foo' => 'bar']], - // nested sequences and mappings - ['[foo, [bar, foo]]', ['foo', ['bar', 'foo']]], - ['[foo, {bar: foo}]', ['foo', (object) ['bar' => 'foo']]], - ['{ foo: {bar: foo} }', (object) ['foo' => (object) ['bar' => 'foo']]], - ['{ foo: [bar, foo] }', (object) ['foo' => ['bar', 'foo']]], - ['[ foo, [ bar, foo ] ]', ['foo', ['bar', 'foo']]], - ['[{ foo: {bar: foo} }]', [(object) ['foo' => (object) ['bar' => 'foo']]]], - ['[foo, [bar, [foo, [bar, foo]], foo]]', ['foo', ['bar', ['foo', ['bar', 'foo']], 'foo']]], - ['[foo, {bar: foo, foo: [foo, {bar: foo}]}, [foo, {bar: foo}]]', ['foo', (object) ['bar' => 'foo', 'foo' => ['foo', (object) ['bar' => 'foo']]], ['foo', (object) ['bar' => 'foo']]]], - ['[foo, bar: { foo: bar }]', ['foo', '1' => (object) ['bar' => (object) ['foo' => 'bar']]]], - ['[foo, \'@foo.baz\', { \'%foo%\': \'foo is %foo%\', bar: \'%foo%\' }, true, \'@service_container\']', ['foo', '@foo.baz', (object) ['%foo%' => 'foo is %foo%', 'bar' => '%foo%'], \true, '@service_container']], - ['{}', new \stdClass()], - ['{ foo : bar, bar : {} }', (object) ['foo' => 'bar', 'bar' => new \stdClass()]], - ['{ foo : [], bar : {} }', (object) ['foo' => [], 'bar' => new \stdClass()]], - ['{foo: \'bar\', bar: {} }', (object) ['foo' => 'bar', 'bar' => new \stdClass()]], - ['{\'foo\': \'bar\', "bar": {}}', (object) ['foo' => 'bar', 'bar' => new \stdClass()]], - ['{\'foo\': \'bar\', "bar": \'{}\'}', (object) ['foo' => 'bar', 'bar' => '{}']], - ['[foo, [{}, {}]]', ['foo', [new \stdClass(), new \stdClass()]]], - ['[foo, [[], {}]]', ['foo', [[], new \stdClass()]]], - ['[foo, [[{}, {}], {}]]', ['foo', [[new \stdClass(), new \stdClass()], new \stdClass()]]], - ['[foo, {bar: {}}]', ['foo', '1' => (object) ['bar' => new \stdClass()]]], - ]; - } - public function getTestsForDump() - { - return [ - ['null', null], - ['false', \false], - ['true', \true], - ['12', 12], - ["'1_2'", '1_2'], - ['_12', '_12'], - ["'12_'", '12_'], - ["'quoted string'", 'quoted string'], - ['!!float 1230', 1230.0], - ['1234', 0x4d2], - ['1243', 02333], - ["'0x_4_D_2_'", '0x_4_D_2_'], - ["'0_2_3_3_3'", '0_2_3_3_3'], - ['.Inf', -\log(0)], - ['-.Inf', \log(0)], - ["'686e444'", '686e444'], - ['"foo\\r\\nbar"', "foo\r\nbar"], - ["'foo#bar'", 'foo#bar'], - ["'foo # bar'", 'foo # bar'], - ["'#cfcfcf'", '#cfcfcf'], - ["'a \"string\" with ''quoted strings inside'''", 'a "string" with \'quoted strings inside\''], - ["'-dash'", '-dash'], - ["'-'", '-'], - // Pre-YAML-1.2 booleans - ["'y'", 'y'], - ["'n'", 'n'], - ["'yes'", 'yes'], - ["'no'", 'no'], - ["'on'", 'on'], - ["'off'", 'off'], - // sequences - ['[foo, bar, false, null, 12]', ['foo', 'bar', \false, null, 12]], - ['[\'foo,bar\', \'foo bar\']', ['foo,bar', 'foo bar']], - // mappings - ['{ foo: bar, bar: foo, \'false\': false, \'null\': null, integer: 12 }', ['foo' => 'bar', 'bar' => 'foo', 'false' => \false, 'null' => null, 'integer' => 12]], - ['{ foo: bar, bar: \'foo: bar\' }', ['foo' => 'bar', 'bar' => 'foo: bar']], - // nested sequences and mappings - ['[foo, [bar, foo]]', ['foo', ['bar', 'foo']]], - ['[foo, [bar, [foo, [bar, foo]], foo]]', ['foo', ['bar', ['foo', ['bar', 'foo']], 'foo']]], - ['{ foo: { bar: foo } }', ['foo' => ['bar' => 'foo']]], - ['[foo, { bar: foo }]', ['foo', ['bar' => 'foo']]], - ['[foo, { bar: foo, foo: [foo, { bar: foo }] }, [foo, { bar: foo }]]', ['foo', ['bar' => 'foo', 'foo' => ['foo', ['bar' => 'foo']]], ['foo', ['bar' => 'foo']]]], - ['[foo, \'@foo.baz\', { \'%foo%\': \'foo is %foo%\', bar: \'%foo%\' }, true, \'@service_container\']', ['foo', '@foo.baz', ['%foo%' => 'foo is %foo%', 'bar' => '%foo%'], \true, '@service_container']], - ['{ foo: { bar: { 1: 2, baz: 3 } } }', ['foo' => ['bar' => [1 => 2, 'baz' => 3]]]], - ]; - } - /** - * @dataProvider getTimestampTests - */ - public function testParseTimestampAsUnixTimestampByDefault($yaml, $year, $month, $day, $hour, $minute, $second) - { - $this->assertSame(\gmmktime($hour, $minute, $second, $month, $day, $year), \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml)); - } - /** - * @dataProvider getTimestampTests - */ - public function testParseTimestampAsDateTimeObject($yaml, $year, $month, $day, $hour, $minute, $second, $timezone) - { - $expected = new \DateTime($yaml); - $expected->setTimeZone(new \DateTimeZone('UTC')); - $expected->setDate($year, $month, $day); - if (\PHP_VERSION_ID >= 70100) { - $expected->setTime($hour, $minute, $second, 1000000 * ($second - (int) $second)); - } else { - $expected->setTime($hour, $minute, $second); - } - $date = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_DATETIME); - $this->assertEquals($expected, $date); - $this->assertSame($timezone, $date->format('O')); - } - public function getTimestampTests() - { - return ['canonical' => ['2001-12-15T02:59:43.1Z', 2001, 12, 15, 2, 59, 43.1, '+0000'], 'ISO-8601' => ['2001-12-15t21:59:43.10-05:00', 2001, 12, 16, 2, 59, 43.1, '-0500'], 'spaced' => ['2001-12-15 21:59:43.10 -5', 2001, 12, 16, 2, 59, 43.1, '-0500'], 'date' => ['2001-12-15', 2001, 12, 15, 0, 0, 0, '+0000']]; - } - /** - * @dataProvider getTimestampTests - */ - public function testParseNestedTimestampListAsDateTimeObject($yaml, $year, $month, $day, $hour, $minute, $second) - { - $expected = new \DateTime($yaml); - $expected->setTimeZone(new \DateTimeZone('UTC')); - $expected->setDate($year, $month, $day); - if (\PHP_VERSION_ID >= 70100) { - $expected->setTime($hour, $minute, $second, 1000000 * ($second - (int) $second)); - } else { - $expected->setTime($hour, $minute, $second); - } - $expectedNested = ['nested' => [$expected]]; - $yamlNested = "{nested: [{$yaml}]}"; - $this->assertEquals($expectedNested, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yamlNested, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_DATETIME)); - } - /** - * @dataProvider getDateTimeDumpTests - */ - public function testDumpDateTime($dateTime, $expected) - { - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($dateTime)); - } - public function getDateTimeDumpTests() - { - $tests = []; - $dateTime = new \DateTime('2001-12-15 21:59:43', new \DateTimeZone('UTC')); - $tests['date-time-utc'] = [$dateTime, '2001-12-15T21:59:43+00:00']; - $dateTime = new \DateTimeImmutable('2001-07-15 21:59:43', new \DateTimeZone('Europe/Berlin')); - $tests['immutable-date-time-europe-berlin'] = [$dateTime, '2001-07-15T21:59:43+02:00']; - return $tests; - } - /** - * @dataProvider getBinaryData - */ - public function testParseBinaryData($data) - { - $this->assertSame('Hello world', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($data)); - } - public function getBinaryData() - { - return ['enclosed with double quotes' => ['!!binary "SGVsbG8gd29ybGQ="'], 'enclosed with single quotes' => ["!!binary 'SGVsbG8gd29ybGQ='"], 'containing spaces' => ['!!binary "SGVs bG8gd 29ybGQ="']]; - } - /** - * @dataProvider getInvalidBinaryData - */ - public function testParseInvalidBinaryData($data, $expectedMessage) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessageRegExp($expectedMessage); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($data); - } - public function getInvalidBinaryData() - { - return ['length not a multiple of four' => ['!!binary "SGVsbG8d29ybGQ="', '/The normalized base64 encoded data \\(data without whitespace characters\\) length must be a multiple of four \\(\\d+ bytes given\\)/'], 'invalid characters' => ['!!binary "SGVsbG8#d29ybGQ="', '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'too many equals characters' => ['!!binary "SGVsbG8gd29yb==="', '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'misplaced equals character' => ['!!binary "SGVsbG8gd29ybG=Q"', '/The base64 encoded data \\(.*\\) contains invalid characters/']]; - } - public function testNotSupportedMissingValue() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('Malformed inline YAML string: "{this, is not, supported}" at line 1.'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{this, is not, supported}'); - } - public function testVeryLongQuotedStrings() - { - $longStringWithQuotes = \str_repeat("x\r\n\\\"x\"x", 1000); - $yamlString = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump(['longStringWithQuotes' => $longStringWithQuotes]); - $arrayFromYaml = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yamlString); - $this->assertEquals($longStringWithQuotes, $arrayFromYaml['longStringWithQuotes']); - } - /** - * @group legacy - * @expectedDeprecation Omitting the key of a mapping is deprecated and will throw a ParseException in 4.0 on line 1. - */ - public function testOmittedMappingKeyIsParsedAsColon() - { - $this->assertSame([':' => 'foo'], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{: foo}')); - } - /** - * @dataProvider getTestsForNullValues - */ - public function testParseMissingMappingValueAsNull($yaml, $expected) - { - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml)); - } - public function getTestsForNullValues() - { - return ['null before closing curly brace' => ['{foo:}', ['foo' => null]], 'null before comma' => ['{foo:, bar: baz}', ['foo' => null, 'bar' => 'baz']]]; - } - public function testTheEmptyStringIsAValidMappingKey() - { - $this->assertSame(['' => 'foo'], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ "": foo }')); - } - /** - * @group legacy - * @expectedDeprecation Implicit casting of incompatible mapping keys to strings is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0. Quote your evaluable mapping keys instead on line 1. - * @dataProvider getNotPhpCompatibleMappingKeyData - */ - public function testImplicitStringCastingOfMappingKeysIsDeprecated($yaml, $expected) - { - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml)); - } - /** - * @group legacy - * @expectedDeprecation Using the Yaml::PARSE_KEYS_AS_STRINGS flag is deprecated since Symfony 3.4 as it will be removed in 4.0. Quote your keys when they are evaluable instead. - * @expectedDeprecation Implicit casting of incompatible mapping keys to strings is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0. Quote your evaluable mapping keys instead on line 1. - * @dataProvider getNotPhpCompatibleMappingKeyData - */ - public function testExplicitStringCastingOfMappingKeys($yaml, $expected) - { - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_KEYS_AS_STRINGS)); - } - public function getNotPhpCompatibleMappingKeyData() - { - return ['boolean-true' => ['{true: "foo"}', ['true' => 'foo']], 'boolean-false' => ['{false: "foo"}', ['false' => 'foo']], 'null' => ['{null: "foo"}', ['null' => 'foo']], 'float' => ['{0.25: "foo"}', ['0.25' => 'foo']]]; - } - /** - * @group legacy - * @expectedDeprecation Support for the !str tag is deprecated since Symfony 3.4. Use the !!str tag instead on line 1. - */ - public function testDeprecatedStrTag() - { - $this->assertSame(['foo' => 'bar'], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ foo: !str bar }')); - } - public function testUnfinishedInlineMap() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('Unexpected end of line, expected one of ",}" at line 1 (near "{abc: \'def\'").'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse("{abc: 'def'"); - } - /** - * @dataProvider getTestsForOctalNumbers - */ - public function testParseOctalNumbers($expected, $yaml) - { - self::assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml)); - } - public function getTestsForOctalNumbers() - { - return ['positive octal number' => [28, '034'], 'negative octal number' => [-28, '-034']]; - } - /** - * @dataProvider phpObjectTagWithEmptyValueProvider - */ - public function testPhpObjectWithEmptyValue($expected, $value) - { - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT)); - } - public function phpObjectTagWithEmptyValueProvider() - { - return [[\false, '!php/object'], [\false, '!php/object '], [\false, '!php/object '], [[\false], '[!php/object]'], [[\false], '[!php/object ]'], [[\false, 'foo'], '[!php/object , foo]']]; - } - /** - * @dataProvider phpConstTagWithEmptyValueProvider - */ - public function testPhpConstTagWithEmptyValue($expected, $value) - { - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT)); - } - public function phpConstTagWithEmptyValueProvider() - { - return [['', '!php/const'], ['', '!php/const '], ['', '!php/const '], [[''], '[!php/const]'], [[''], '[!php/const ]'], [['', 'foo'], '[!php/const , foo]'], [['' => 'foo'], '{!php/const: foo}'], [['' => 'foo'], '{!php/const : foo}'], [['' => 'foo', 'bar' => 'ccc'], '{!php/const : foo, bar: ccc}']]; - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; +class InlineTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + protected function setUp() + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::initialize(0, 0); + } + /** + * @dataProvider getTestsForParse + */ + public function testParse($yaml, $value, $flags = 0) + { + $this->assertSame($value, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, $flags), \sprintf('::parse() converts an inline YAML to a PHP structure (%s)', $yaml)); + } + /** + * @dataProvider getTestsForParseWithMapObjects + */ + public function testParseWithMapObjects($yaml, $value, $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP) + { + $actual = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, $flags); + $this->assertSame(\serialize($value), \serialize($actual)); + } + /** + * @dataProvider getTestsForParsePhpConstants + */ + public function testParsePhpConstants($yaml, $value) + { + $actual = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT); + $this->assertSame($value, $actual); + } + public function getTestsForParsePhpConstants() + { + return [['!php/const Symfony\\Component\\Yaml\\Yaml::PARSE_CONSTANT', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT], ['!php/const PHP_INT_MAX', \PHP_INT_MAX], ['[!php/const PHP_INT_MAX]', [\PHP_INT_MAX]], ['{ foo: !php/const PHP_INT_MAX }', ['foo' => \PHP_INT_MAX]], ['{ !php/const PHP_INT_MAX: foo }', [\PHP_INT_MAX => 'foo']], ['!php/const NULL', null]]; + } + public function testParsePhpConstantThrowsExceptionWhenUndefined() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('The constant "WRONG_CONSTANT" is not defined'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('!php/const WRONG_CONSTANT', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT); + } + public function testParsePhpConstantThrowsExceptionOnInvalidType() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessageRegExp('#The string "!php/const PHP_INT_MAX" could not be parsed as a constant.*#'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('!php/const PHP_INT_MAX', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE); + } + /** + * @group legacy + * @expectedDeprecation The !php/const: tag to indicate dumped PHP constants is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/const (without the colon) tag instead on line 1. + * @dataProvider getTestsForParseLegacyPhpConstants + */ + public function testDeprecatedConstantTag($yaml, $expectedValue) + { + $this->assertSame($expectedValue, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT)); + } + public function getTestsForParseLegacyPhpConstants() + { + return [['!php/const:Symfony\\Component\\Yaml\\Yaml::PARSE_CONSTANT', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT], ['!php/const:PHP_INT_MAX', \PHP_INT_MAX], ['[!php/const:PHP_INT_MAX]', [\PHP_INT_MAX]], ['{ foo: !php/const:PHP_INT_MAX }', ['foo' => \PHP_INT_MAX]], ['{ !php/const:PHP_INT_MAX: foo }', [\PHP_INT_MAX => 'foo']], ['!php/const:NULL', null]]; + } + /** + * @group legacy + * @dataProvider getTestsForParseWithMapObjects + */ + public function testParseWithMapObjectsPassingTrue($yaml, $value) + { + $actual = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, \false, \false, \true); + $this->assertSame(\serialize($value), \serialize($actual)); + } + /** + * @dataProvider getTestsForDump + */ + public function testDump($yaml, $value, $parseFlags = 0) + { + $this->assertEquals($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($value), \sprintf('::dump() converts a PHP structure to an inline YAML (%s)', $yaml)); + $this->assertSame($value, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse(\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($value), $parseFlags), 'check consistency'); + } + public function testDumpNumericValueWithLocale() + { + $locale = \setlocale(\LC_NUMERIC, 0); + if (\false === $locale) { + $this->markTestSkipped('Your platform does not support locales.'); + } + try { + $requiredLocales = ['fr_FR.UTF-8', 'fr_FR.UTF8', 'fr_FR.utf-8', 'fr_FR.utf8', 'French_France.1252']; + if (\false === \setlocale(\LC_NUMERIC, $requiredLocales)) { + $this->markTestSkipped('Could not set any of required locales: ' . \implode(', ', $requiredLocales)); + } + $this->assertEquals('1.2', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump(1.2)); + $this->assertStringContainsStringIgnoringCase('fr', \setlocale(\LC_NUMERIC, 0)); + } finally { + \setlocale(\LC_NUMERIC, $locale); + } + } + public function testHashStringsResemblingExponentialNumericsShouldNotBeChangedToINF() + { + $value = '686e444'; + $this->assertSame($value, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse(\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($value))); + } + public function testParseScalarWithNonEscapedBlackslashShouldThrowException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('Found unknown escape character "\\V".'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('"Foo\\Var"'); + } + public function testParseScalarWithNonEscapedBlackslashAtTheEndShouldThrowException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('"Foo\\"'); + } + public function testParseScalarWithIncorrectlyQuotedStringShouldThrowException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $value = "'don't do somthin' like that'"; + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value); + } + public function testParseScalarWithIncorrectlyDoubleQuotedStringShouldThrowException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $value = '"don"t do somthin" like that"'; + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value); + } + public function testParseInvalidMappingKeyShouldThrowException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $value = '{ "foo " bar": "bar" }'; + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value); + } + /** + * @group legacy + * @expectedDeprecation Using a colon after an unquoted mapping key that is not followed by an indication character (i.e. " ", ",", "[", "]", "{", "}") is deprecated since Symfony 3.2 and will throw a ParseException in 4.0 on line 1. + * throws \Symfony\Component\Yaml\Exception\ParseException in 4.0 + */ + public function testParseMappingKeyWithColonNotFollowedBySpace() + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{1:""}'); + } + public function testParseInvalidMappingShouldThrowException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('[foo] bar'); + } + public function testParseInvalidSequenceShouldThrowException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ foo: bar } bar'); + } + public function testParseInvalidTaggedSequenceShouldThrowException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('!foo { bar: baz } qux', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS); + } + public function testParseScalarWithCorrectlyQuotedStringShouldReturnString() + { + $value = "'don''t do somthin'' like that'"; + $expect = "don't do somthin' like that"; + $this->assertSame($expect, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parseScalar($value)); + } + /** + * @dataProvider getDataForParseReferences + */ + public function testParseReferences($yaml, $expected) + { + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, 0, ['var' => 'var-value'])); + } + /** + * @group legacy + * @dataProvider getDataForParseReferences + */ + public function testParseReferencesAsFifthArgument($yaml, $expected) + { + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, \false, \false, \false, ['var' => 'var-value'])); + } + public function getDataForParseReferences() + { + return ['scalar' => ['*var', 'var-value'], 'list' => ['[ *var ]', ['var-value']], 'list-in-list' => ['[[ *var ]]', [['var-value']]], 'map-in-list' => ['[ { key: *var } ]', [['key' => 'var-value']]], 'embedded-mapping-in-list' => ['[ key: *var ]', [['key' => 'var-value']]], 'map' => ['{ key: *var }', ['key' => 'var-value']], 'list-in-map' => ['{ key: [*var] }', ['key' => ['var-value']]], 'map-in-map' => ['{ foo: { bar: *var } }', ['foo' => ['bar' => 'var-value']]]]; + } + public function testParseMapReferenceInSequence() + { + $foo = ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian']; + $this->assertSame([$foo], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('[*foo]', 0, ['foo' => $foo])); + } + /** + * @group legacy + */ + public function testParseMapReferenceInSequenceAsFifthArgument() + { + $foo = ['a' => 'Steve', 'b' => 'Clark', 'c' => 'Brian']; + $this->assertSame([$foo], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('[*foo]', \false, \false, \false, ['foo' => $foo])); + } + public function testParseUnquotedAsterisk() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('A reference must contain at least one character at line 1.'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ foo: * }'); + } + public function testParseUnquotedAsteriskFollowedByAComment() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('A reference must contain at least one character at line 1.'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ foo: * #foo }'); + } + /** + * @dataProvider getReservedIndicators + */ + public function testParseUnquotedScalarStartingWithReservedIndicator($indicator) + { + $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException::class); + $this->expectExceptionMessage(\sprintf('cannot start a plain scalar; you need to quote the scalar at line 1 (near "%sfoo ").', $indicator)); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse(\sprintf('{ foo: %sfoo }', $indicator)); + } + public function getReservedIndicators() + { + return [['@'], ['`']]; + } + /** + * @dataProvider getScalarIndicators + */ + public function testParseUnquotedScalarStartingWithScalarIndicator($indicator) + { + $this->expectException(\_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException::class); + $this->expectExceptionMessage(\sprintf('cannot start a plain scalar; you need to quote the scalar at line 1 (near "%sfoo ").', $indicator)); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse(\sprintf('{ foo: %sfoo }', $indicator)); + } + public function getScalarIndicators() + { + return [['|'], ['>']]; + } + /** + * @group legacy + * @expectedDeprecation Not quoting the scalar "%bar " starting with the "%" indicator character is deprecated since Symfony 3.1 and will throw a ParseException in 4.0 on line 1. + * throws \Symfony\Component\Yaml\Exception\ParseException in 4.0 + */ + public function testParseUnquotedScalarStartingWithPercentCharacter() + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ foo: %bar }'); + } + /** + * @dataProvider getDataForIsHash + */ + public function testIsHash($array, $expected) + { + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::isHash($array)); + } + public function getDataForIsHash() + { + return [[[], \false], [[1, 2, 3], \false], [[2 => 1, 1 => 2, 0 => 3], \true], [['foo' => 1, 'bar' => 2], \true]]; + } + public function getTestsForParse() + { + return [ + ['', ''], + ['null', null], + ['false', \false], + ['true', \true], + ['12', 12], + ['-12', -12], + ['1_2', 12], + ['_12', '_12'], + ['12_', 12], + ['"quoted string"', 'quoted string'], + ["'quoted string'", 'quoted string'], + ['12.30e+02', 1230.0], + ['123.45_67', 123.4567], + ['0x4D2', 0x4d2], + ['0x_4_D_2_', 0x4d2], + ['02333', 02333], + ['0_2_3_3_3', 02333], + ['.Inf', -\log(0)], + ['-.Inf', \log(0)], + ["'686e444'", '686e444'], + ['686e444', \INF], + ['123456789123456789123456789123456789', '123456789123456789123456789123456789'], + ['"foo\\r\\nbar"', "foo\r\nbar"], + ["'foo#bar'", 'foo#bar'], + ["'foo # bar'", 'foo # bar'], + ["'#cfcfcf'", '#cfcfcf'], + ['::form_base.html.twig', '::form_base.html.twig'], + // Pre-YAML-1.2 booleans + ["'y'", 'y'], + ["'n'", 'n'], + ["'yes'", 'yes'], + ["'no'", 'no'], + ["'on'", 'on'], + ["'off'", 'off'], + ['2007-10-30', \gmmktime(0, 0, 0, 10, 30, 2007)], + ['2007-10-30T02:59:43Z', \gmmktime(2, 59, 43, 10, 30, 2007)], + ['2007-10-30 02:59:43 Z', \gmmktime(2, 59, 43, 10, 30, 2007)], + ['1960-10-30 02:59:43 Z', \gmmktime(2, 59, 43, 10, 30, 1960)], + ['1730-10-30T02:59:43Z', \gmmktime(2, 59, 43, 10, 30, 1730)], + ['"a \\"string\\" with \'quoted strings inside\'"', 'a "string" with \'quoted strings inside\''], + ["'a \"string\" with ''quoted strings inside'''", 'a "string" with \'quoted strings inside\''], + // sequences + // urls are no key value mapping. see #3609. Valid yaml "key: value" mappings require a space after the colon + ['[foo, http://urls.are/no/mappings, false, null, 12]', ['foo', 'http://urls.are/no/mappings', \false, null, 12]], + ['[ foo , bar , false , null , 12 ]', ['foo', 'bar', \false, null, 12]], + ['[\'foo,bar\', \'foo bar\']', ['foo,bar', 'foo bar']], + // mappings + ['{foo: bar,bar: foo,"false": false, "null": null,integer: 12}', ['foo' => 'bar', 'bar' => 'foo', 'false' => \false, 'null' => null, 'integer' => 12]], + ['{ foo : bar, bar : foo, "false" : false, "null" : null, integer : 12 }', ['foo' => 'bar', 'bar' => 'foo', 'false' => \false, 'null' => null, 'integer' => 12]], + ['{foo: \'bar\', bar: \'foo: bar\'}', ['foo' => 'bar', 'bar' => 'foo: bar']], + ['{\'foo\': \'bar\', "bar": \'foo: bar\'}', ['foo' => 'bar', 'bar' => 'foo: bar']], + ['{\'foo\'\'\': \'bar\', "bar\\"": \'foo: bar\'}', ['foo\'' => 'bar', 'bar"' => 'foo: bar']], + ['{\'foo: \': \'bar\', "bar: ": \'foo: bar\'}', ['foo: ' => 'bar', 'bar: ' => 'foo: bar']], + ['{"foo:bar": "baz"}', ['foo:bar' => 'baz']], + ['{"foo":"bar"}', ['foo' => 'bar']], + // nested sequences and mappings + ['[foo, [bar, foo]]', ['foo', ['bar', 'foo']]], + ['[foo, {bar: foo}]', ['foo', ['bar' => 'foo']]], + ['{ foo: {bar: foo} }', ['foo' => ['bar' => 'foo']]], + ['{ foo: [bar, foo] }', ['foo' => ['bar', 'foo']]], + ['{ foo:{bar: foo} }', ['foo' => ['bar' => 'foo']]], + ['{ foo:[bar, foo] }', ['foo' => ['bar', 'foo']]], + ['[ foo, [ bar, foo ] ]', ['foo', ['bar', 'foo']]], + ['[{ foo: {bar: foo} }]', [['foo' => ['bar' => 'foo']]]], + ['[foo, [bar, [foo, [bar, foo]], foo]]', ['foo', ['bar', ['foo', ['bar', 'foo']], 'foo']]], + ['[foo, {bar: foo, foo: [foo, {bar: foo}]}, [foo, {bar: foo}]]', ['foo', ['bar' => 'foo', 'foo' => ['foo', ['bar' => 'foo']]], ['foo', ['bar' => 'foo']]]], + ['[foo, bar: { foo: bar }]', ['foo', '1' => ['bar' => ['foo' => 'bar']]]], + ['[foo, \'@foo.baz\', { \'%foo%\': \'foo is %foo%\', bar: \'%foo%\' }, true, \'@service_container\']', ['foo', '@foo.baz', ['%foo%' => 'foo is %foo%', 'bar' => '%foo%'], \true, '@service_container']], + ]; + } + public function getTestsForParseWithMapObjects() + { + return [ + ['', ''], + ['null', null], + ['false', \false], + ['true', \true], + ['12', 12], + ['-12', -12], + ['"quoted string"', 'quoted string'], + ["'quoted string'", 'quoted string'], + ['12.30e+02', 1230.0], + ['0x4D2', 0x4d2], + ['02333', 02333], + ['.Inf', -\log(0)], + ['-.Inf', \log(0)], + ["'686e444'", '686e444'], + ['686e444', \INF], + ['123456789123456789123456789123456789', '123456789123456789123456789123456789'], + ['"foo\\r\\nbar"', "foo\r\nbar"], + ["'foo#bar'", 'foo#bar'], + ["'foo # bar'", 'foo # bar'], + ["'#cfcfcf'", '#cfcfcf'], + ['::form_base.html.twig', '::form_base.html.twig'], + ['2007-10-30', \gmmktime(0, 0, 0, 10, 30, 2007)], + ['2007-10-30T02:59:43Z', \gmmktime(2, 59, 43, 10, 30, 2007)], + ['2007-10-30 02:59:43 Z', \gmmktime(2, 59, 43, 10, 30, 2007)], + ['1960-10-30 02:59:43 Z', \gmmktime(2, 59, 43, 10, 30, 1960)], + ['1730-10-30T02:59:43Z', \gmmktime(2, 59, 43, 10, 30, 1730)], + ['"a \\"string\\" with \'quoted strings inside\'"', 'a "string" with \'quoted strings inside\''], + ["'a \"string\" with ''quoted strings inside'''", 'a "string" with \'quoted strings inside\''], + // sequences + // urls are no key value mapping. see #3609. Valid yaml "key: value" mappings require a space after the colon + ['[foo, http://urls.are/no/mappings, false, null, 12]', ['foo', 'http://urls.are/no/mappings', \false, null, 12]], + ['[ foo , bar , false , null , 12 ]', ['foo', 'bar', \false, null, 12]], + ['[\'foo,bar\', \'foo bar\']', ['foo,bar', 'foo bar']], + // mappings + ['{foo: bar,bar: foo,"false": false,"null": null,integer: 12}', (object) ['foo' => 'bar', 'bar' => 'foo', 'false' => \false, 'null' => null, 'integer' => 12], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP], + ['{ foo : bar, bar : foo, "false" : false, "null" : null, integer : 12 }', (object) ['foo' => 'bar', 'bar' => 'foo', 'false' => \false, 'null' => null, 'integer' => 12], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP], + ['{foo: \'bar\', bar: \'foo: bar\'}', (object) ['foo' => 'bar', 'bar' => 'foo: bar']], + ['{\'foo\': \'bar\', "bar": \'foo: bar\'}', (object) ['foo' => 'bar', 'bar' => 'foo: bar']], + ['{\'foo\'\'\': \'bar\', "bar\\"": \'foo: bar\'}', (object) ['foo\'' => 'bar', 'bar"' => 'foo: bar']], + ['{\'foo: \': \'bar\', "bar: ": \'foo: bar\'}', (object) ['foo: ' => 'bar', 'bar: ' => 'foo: bar']], + ['{"foo:bar": "baz"}', (object) ['foo:bar' => 'baz']], + ['{"foo":"bar"}', (object) ['foo' => 'bar']], + // nested sequences and mappings + ['[foo, [bar, foo]]', ['foo', ['bar', 'foo']]], + ['[foo, {bar: foo}]', ['foo', (object) ['bar' => 'foo']]], + ['{ foo: {bar: foo} }', (object) ['foo' => (object) ['bar' => 'foo']]], + ['{ foo: [bar, foo] }', (object) ['foo' => ['bar', 'foo']]], + ['[ foo, [ bar, foo ] ]', ['foo', ['bar', 'foo']]], + ['[{ foo: {bar: foo} }]', [(object) ['foo' => (object) ['bar' => 'foo']]]], + ['[foo, [bar, [foo, [bar, foo]], foo]]', ['foo', ['bar', ['foo', ['bar', 'foo']], 'foo']]], + ['[foo, {bar: foo, foo: [foo, {bar: foo}]}, [foo, {bar: foo}]]', ['foo', (object) ['bar' => 'foo', 'foo' => ['foo', (object) ['bar' => 'foo']]], ['foo', (object) ['bar' => 'foo']]]], + ['[foo, bar: { foo: bar }]', ['foo', '1' => (object) ['bar' => (object) ['foo' => 'bar']]]], + ['[foo, \'@foo.baz\', { \'%foo%\': \'foo is %foo%\', bar: \'%foo%\' }, true, \'@service_container\']', ['foo', '@foo.baz', (object) ['%foo%' => 'foo is %foo%', 'bar' => '%foo%'], \true, '@service_container']], + ['{}', new \stdClass()], + ['{ foo : bar, bar : {} }', (object) ['foo' => 'bar', 'bar' => new \stdClass()]], + ['{ foo : [], bar : {} }', (object) ['foo' => [], 'bar' => new \stdClass()]], + ['{foo: \'bar\', bar: {} }', (object) ['foo' => 'bar', 'bar' => new \stdClass()]], + ['{\'foo\': \'bar\', "bar": {}}', (object) ['foo' => 'bar', 'bar' => new \stdClass()]], + ['{\'foo\': \'bar\', "bar": \'{}\'}', (object) ['foo' => 'bar', 'bar' => '{}']], + ['[foo, [{}, {}]]', ['foo', [new \stdClass(), new \stdClass()]]], + ['[foo, [[], {}]]', ['foo', [[], new \stdClass()]]], + ['[foo, [[{}, {}], {}]]', ['foo', [[new \stdClass(), new \stdClass()], new \stdClass()]]], + ['[foo, {bar: {}}]', ['foo', '1' => (object) ['bar' => new \stdClass()]]], + ]; + } + public function getTestsForDump() + { + return [ + ['null', null], + ['false', \false], + ['true', \true], + ['12', 12], + ["'1_2'", '1_2'], + ['_12', '_12'], + ["'12_'", '12_'], + ["'quoted string'", 'quoted string'], + ['!!float 1230', 1230.0], + ['1234', 0x4d2], + ['1243', 02333], + ["'0x_4_D_2_'", '0x_4_D_2_'], + ["'0_2_3_3_3'", '0_2_3_3_3'], + ['.Inf', -\log(0)], + ['-.Inf', \log(0)], + ["'686e444'", '686e444'], + ['"foo\\r\\nbar"', "foo\r\nbar"], + ["'foo#bar'", 'foo#bar'], + ["'foo # bar'", 'foo # bar'], + ["'#cfcfcf'", '#cfcfcf'], + ["'a \"string\" with ''quoted strings inside'''", 'a "string" with \'quoted strings inside\''], + ["'-dash'", '-dash'], + ["'-'", '-'], + // Pre-YAML-1.2 booleans + ["'y'", 'y'], + ["'n'", 'n'], + ["'yes'", 'yes'], + ["'no'", 'no'], + ["'on'", 'on'], + ["'off'", 'off'], + // sequences + ['[foo, bar, false, null, 12]', ['foo', 'bar', \false, null, 12]], + ['[\'foo,bar\', \'foo bar\']', ['foo,bar', 'foo bar']], + // mappings + ['{ foo: bar, bar: foo, \'false\': false, \'null\': null, integer: 12 }', ['foo' => 'bar', 'bar' => 'foo', 'false' => \false, 'null' => null, 'integer' => 12]], + ['{ foo: bar, bar: \'foo: bar\' }', ['foo' => 'bar', 'bar' => 'foo: bar']], + // nested sequences and mappings + ['[foo, [bar, foo]]', ['foo', ['bar', 'foo']]], + ['[foo, [bar, [foo, [bar, foo]], foo]]', ['foo', ['bar', ['foo', ['bar', 'foo']], 'foo']]], + ['{ foo: { bar: foo } }', ['foo' => ['bar' => 'foo']]], + ['[foo, { bar: foo }]', ['foo', ['bar' => 'foo']]], + ['[foo, { bar: foo, foo: [foo, { bar: foo }] }, [foo, { bar: foo }]]', ['foo', ['bar' => 'foo', 'foo' => ['foo', ['bar' => 'foo']]], ['foo', ['bar' => 'foo']]]], + ['[foo, \'@foo.baz\', { \'%foo%\': \'foo is %foo%\', bar: \'%foo%\' }, true, \'@service_container\']', ['foo', '@foo.baz', ['%foo%' => 'foo is %foo%', 'bar' => '%foo%'], \true, '@service_container']], + ['{ foo: { bar: { 1: 2, baz: 3 } } }', ['foo' => ['bar' => [1 => 2, 'baz' => 3]]]], + ]; + } + /** + * @dataProvider getTimestampTests + */ + public function testParseTimestampAsUnixTimestampByDefault($yaml, $year, $month, $day, $hour, $minute, $second) + { + $this->assertSame(\gmmktime($hour, $minute, $second, $month, $day, $year), \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml)); + } + /** + * @dataProvider getTimestampTests + */ + public function testParseTimestampAsDateTimeObject($yaml, $year, $month, $day, $hour, $minute, $second, $timezone) + { + $expected = new \DateTime($yaml); + $expected->setTimeZone(new \DateTimeZone('UTC')); + $expected->setDate($year, $month, $day); + if (\PHP_VERSION_ID >= 70100) { + $expected->setTime($hour, $minute, $second, 1000000 * ($second - (int) $second)); + } else { + $expected->setTime($hour, $minute, $second); + } + $date = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_DATETIME); + $this->assertEquals($expected, $date); + $this->assertSame($timezone, $date->format('O')); + } + public function getTimestampTests() + { + return ['canonical' => ['2001-12-15T02:59:43.1Z', 2001, 12, 15, 2, 59, 43.1, '+0000'], 'ISO-8601' => ['2001-12-15t21:59:43.10-05:00', 2001, 12, 16, 2, 59, 43.1, '-0500'], 'spaced' => ['2001-12-15 21:59:43.10 -5', 2001, 12, 16, 2, 59, 43.1, '-0500'], 'date' => ['2001-12-15', 2001, 12, 15, 0, 0, 0, '+0000']]; + } + /** + * @dataProvider getTimestampTests + */ + public function testParseNestedTimestampListAsDateTimeObject($yaml, $year, $month, $day, $hour, $minute, $second) + { + $expected = new \DateTime($yaml); + $expected->setTimeZone(new \DateTimeZone('UTC')); + $expected->setDate($year, $month, $day); + if (\PHP_VERSION_ID >= 70100) { + $expected->setTime($hour, $minute, $second, 1000000 * ($second - (int) $second)); + } else { + $expected->setTime($hour, $minute, $second); + } + $expectedNested = ['nested' => [$expected]]; + $yamlNested = "{nested: [{$yaml}]}"; + $this->assertEquals($expectedNested, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yamlNested, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_DATETIME)); + } + /** + * @dataProvider getDateTimeDumpTests + */ + public function testDumpDateTime($dateTime, $expected) + { + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump($dateTime)); + } + public function getDateTimeDumpTests() + { + $tests = []; + $dateTime = new \DateTime('2001-12-15 21:59:43', new \DateTimeZone('UTC')); + $tests['date-time-utc'] = [$dateTime, '2001-12-15T21:59:43+00:00']; + $dateTime = new \DateTimeImmutable('2001-07-15 21:59:43', new \DateTimeZone('Europe/Berlin')); + $tests['immutable-date-time-europe-berlin'] = [$dateTime, '2001-07-15T21:59:43+02:00']; + return $tests; + } + /** + * @dataProvider getBinaryData + */ + public function testParseBinaryData($data) + { + $this->assertSame('Hello world', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($data)); + } + public function getBinaryData() + { + return ['enclosed with double quotes' => ['!!binary "SGVsbG8gd29ybGQ="'], 'enclosed with single quotes' => ["!!binary 'SGVsbG8gd29ybGQ='"], 'containing spaces' => ['!!binary "SGVs bG8gd 29ybGQ="']]; + } + /** + * @dataProvider getInvalidBinaryData + */ + public function testParseInvalidBinaryData($data, $expectedMessage) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessageRegExp($expectedMessage); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($data); + } + public function getInvalidBinaryData() + { + return ['length not a multiple of four' => ['!!binary "SGVsbG8d29ybGQ="', '/The normalized base64 encoded data \\(data without whitespace characters\\) length must be a multiple of four \\(\\d+ bytes given\\)/'], 'invalid characters' => ['!!binary "SGVsbG8#d29ybGQ="', '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'too many equals characters' => ['!!binary "SGVsbG8gd29yb==="', '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'misplaced equals character' => ['!!binary "SGVsbG8gd29ybG=Q"', '/The base64 encoded data \\(.*\\) contains invalid characters/']]; + } + public function testNotSupportedMissingValue() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('Malformed inline YAML string: "{this, is not, supported}" at line 1.'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{this, is not, supported}'); + } + public function testVeryLongQuotedStrings() + { + $longStringWithQuotes = \str_repeat("x\r\n\\\"x\"x", 1000); + $yamlString = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::dump(['longStringWithQuotes' => $longStringWithQuotes]); + $arrayFromYaml = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yamlString); + $this->assertEquals($longStringWithQuotes, $arrayFromYaml['longStringWithQuotes']); + } + /** + * @group legacy + * @expectedDeprecation Omitting the key of a mapping is deprecated and will throw a ParseException in 4.0 on line 1. + */ + public function testOmittedMappingKeyIsParsedAsColon() + { + $this->assertSame([':' => 'foo'], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{: foo}')); + } + /** + * @dataProvider getTestsForNullValues + */ + public function testParseMissingMappingValueAsNull($yaml, $expected) + { + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml)); + } + public function getTestsForNullValues() + { + return ['null before closing curly brace' => ['{foo:}', ['foo' => null]], 'null before comma' => ['{foo:, bar: baz}', ['foo' => null, 'bar' => 'baz']]]; + } + public function testTheEmptyStringIsAValidMappingKey() + { + $this->assertSame(['' => 'foo'], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ "": foo }')); + } + /** + * @group legacy + * @expectedDeprecation Implicit casting of incompatible mapping keys to strings is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0. Quote your evaluable mapping keys instead on line 1. + * @dataProvider getNotPhpCompatibleMappingKeyData + */ + public function testImplicitStringCastingOfMappingKeysIsDeprecated($yaml, $expected) + { + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml)); + } + /** + * @group legacy + * @expectedDeprecation Using the Yaml::PARSE_KEYS_AS_STRINGS flag is deprecated since Symfony 3.4 as it will be removed in 4.0. Quote your keys when they are evaluable instead. + * @expectedDeprecation Implicit casting of incompatible mapping keys to strings is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0. Quote your evaluable mapping keys instead on line 1. + * @dataProvider getNotPhpCompatibleMappingKeyData + */ + public function testExplicitStringCastingOfMappingKeys($yaml, $expected) + { + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_KEYS_AS_STRINGS)); + } + public function getNotPhpCompatibleMappingKeyData() + { + return ['boolean-true' => ['{true: "foo"}', ['true' => 'foo']], 'boolean-false' => ['{false: "foo"}', ['false' => 'foo']], 'null' => ['{null: "foo"}', ['null' => 'foo']], 'float' => ['{0.25: "foo"}', ['0.25' => 'foo']]]; + } + /** + * @group legacy + * @expectedDeprecation Support for the !str tag is deprecated since Symfony 3.4. Use the !!str tag instead on line 1. + */ + public function testDeprecatedStrTag() + { + $this->assertSame(['foo' => 'bar'], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse('{ foo: !str bar }')); + } + public function testUnfinishedInlineMap() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('Unexpected end of line, expected one of ",}" at line 1 (near "{abc: \'def\'").'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse("{abc: 'def'"); + } + /** + * @dataProvider getTestsForOctalNumbers + */ + public function testParseOctalNumbers($expected, $yaml) + { + self::assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($yaml)); + } + public function getTestsForOctalNumbers() + { + return ['positive octal number' => [28, '034'], 'negative octal number' => [-28, '-034']]; + } + /** + * @dataProvider phpObjectTagWithEmptyValueProvider + */ + public function testPhpObjectWithEmptyValue($expected, $value) + { + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT)); + } + public function phpObjectTagWithEmptyValueProvider() + { + return [[\false, '!php/object'], [\false, '!php/object '], [\false, '!php/object '], [[\false], '[!php/object]'], [[\false], '[!php/object ]'], [[\false, 'foo'], '[!php/object , foo]']]; + } + /** + * @dataProvider phpConstTagWithEmptyValueProvider + */ + public function testPhpConstTagWithEmptyValue($expected, $value) + { + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Inline::parse($value, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT)); + } + public function phpConstTagWithEmptyValueProvider() + { + return [['', '!php/const'], ['', '!php/const '], ['', '!php/const '], [[''], '[!php/const]'], [[''], '[!php/const ]'], [['', 'foo'], '[!php/const , foo]'], [['' => 'foo'], '{!php/const: foo}'], [['' => 'foo'], '{!php/const : foo}'], [['' => 'foo', 'bar' => 'ccc'], '{!php/const : foo, bar: ccc}']]; + } +} diff --git a/vendor/symfony/yaml/Tests/ParseExceptionTest.php b/vendor/symfony/yaml/Tests/ParseExceptionTest.php index b6a251998..9f6075c27 100644 --- a/vendor/symfony/yaml/Tests/ParseExceptionTest.php +++ b/vendor/symfony/yaml/Tests/ParseExceptionTest.php @@ -1,29 +1,29 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; -class ParseExceptionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testGetMessage() - { - $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Error message', 42, 'foo: bar', '/var/www/app/config.yml'); - $message = 'Error message in "/var/www/app/config.yml" at line 42 (near "foo: bar")'; - $this->assertEquals($message, $exception->getMessage()); - } - public function testGetMessageWithUnicodeInFilename() - { - $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Error message', 42, 'foo: bar', 'äöü.yml'); - $message = 'Error message in "äöü.yml" at line 42 (near "foo: bar")'; - $this->assertEquals($message, $exception->getMessage()); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; +class ParseExceptionTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testGetMessage() + { + $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Error message', 42, 'foo: bar', '/var/www/app/config.yml'); + $message = 'Error message in "/var/www/app/config.yml" at line 42 (near "foo: bar")'; + $this->assertEquals($message, $exception->getMessage()); + } + public function testGetMessageWithUnicodeInFilename() + { + $exception = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException('Error message', 42, 'foo: bar', 'äöü.yml'); + $message = 'Error message in "äöü.yml" at line 42 (near "foo: bar")'; + $this->assertEquals($message, $exception->getMessage()); + } +} diff --git a/vendor/symfony/yaml/Tests/ParserTest.php b/vendor/symfony/yaml/Tests/ParserTest.php index f2fc03105..6c1de18cd 100644 --- a/vendor/symfony/yaml/Tests/ParserTest.php +++ b/vendor/symfony/yaml/Tests/ParserTest.php @@ -1,1717 +1,1717 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; -class ParserTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - /** @var Parser */ - protected $parser; - protected function setUp() - { - $this->parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); - } - protected function tearDown() - { - $this->parser = null; - \chmod(__DIR__ . '/Fixtures/not_readable.yml', 0644); - } - /** - * @dataProvider getDataFormSpecifications - */ - public function testSpecifications($expected, $yaml, $comment, $deprecated) - { - $deprecations = []; - if ($deprecated) { - \set_error_handler(function ($type, $msg) use(&$deprecations) { - if (\E_USER_DEPRECATED !== $type) { - \restore_error_handler(); - return \call_user_func_array('PHPUnit\\Util\\ErrorHandler::handleError', \func_get_args()); - } - $deprecations[] = $msg; - return null; - }); - } - $this->assertEquals($expected, \var_export($this->parser->parse($yaml), \true), $comment); - if ($deprecated) { - \restore_error_handler(); - $this->assertCount(1, $deprecations); - $this->assertStringContainsString(\true !== $deprecated ? $deprecated : 'Using the comma as a group separator for floats is deprecated since Symfony 3.2 and will be removed in 4.0 on line 1.', $deprecations[0]); - } - } - public function getDataFormSpecifications() - { - return $this->loadTestsFromFixtureFiles('index.yml'); - } - /** - * @group legacy - * @expectedDeprecationMessage Using the Yaml::PARSE_KEYS_AS_STRINGS flag is deprecated since Symfony 3.4 as it will be removed in 4.0. Quote your keys when they are evaluable - * @dataProvider getNonStringMappingKeysData - */ - public function testNonStringMappingKeys($expected, $yaml, $comment) - { - $this->assertSame($expected, \var_export($this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_KEYS_AS_STRINGS), \true), $comment); - } - public function getNonStringMappingKeysData() - { - return $this->loadTestsFromFixtureFiles('nonStringKeys.yml'); - } - /** - * @group legacy - * @dataProvider getLegacyNonStringMappingKeysData - */ - public function testLegacyNonStringMappingKeys($expected, $yaml, $comment) - { - $this->assertSame($expected, \var_export($this->parser->parse($yaml), \true), $comment); - } - public function getLegacyNonStringMappingKeysData() - { - return $this->loadTestsFromFixtureFiles('legacyNonStringKeys.yml'); - } - public function testTabsInYaml() - { - // test tabs in YAML - $yamls = ["foo:\n\tbar", "foo:\n \tbar", "foo:\n\t bar", "foo:\n \t bar"]; - foreach ($yamls as $yaml) { - try { - $this->parser->parse($yaml); - $this->fail('YAML files must not contain tabs'); - } catch (\Exception $e) { - $this->assertInstanceOf('\\Exception', $e, 'YAML files must not contain tabs'); - $this->assertEquals('A YAML file cannot contain tabs as indentation at line 2 (near "' . \strpbrk($yaml, "\t") . '").', $e->getMessage(), 'YAML files must not contain tabs'); - } - } - } - public function testEndOfTheDocumentMarker() - { - $yaml = <<<'EOF' ---- %YAML:1.0 -foo -... -EOF; - $this->assertEquals('foo', $this->parser->parse($yaml)); - } - public function getBlockChompingTests() - { - $tests = []; - $yaml = <<<'EOF' -foo: |- - one - two -bar: |- - one - two - -EOF; - $expected = ['foo' => "one\ntwo", 'bar' => "one\ntwo"]; - $tests['Literal block chomping strip with single trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: |- - one - two - -bar: |- - one - two - - -EOF; - $expected = ['foo' => "one\ntwo", 'bar' => "one\ntwo"]; - $tests['Literal block chomping strip with multiple trailing newlines'] = [$expected, $yaml]; - $yaml = <<<'EOF' -{} - - -EOF; - $expected = []; - $tests['Literal block chomping strip with multiple trailing newlines after a 1-liner'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: |- - one - two -bar: |- - one - two -EOF; - $expected = ['foo' => "one\ntwo", 'bar' => "one\ntwo"]; - $tests['Literal block chomping strip without trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: | - one - two -bar: | - one - two - -EOF; - $expected = ['foo' => "one\ntwo\n", 'bar' => "one\ntwo\n"]; - $tests['Literal block chomping clip with single trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: | - one - two - -bar: | - one - two - - -EOF; - $expected = ['foo' => "one\ntwo\n", 'bar' => "one\ntwo\n"]; - $tests['Literal block chomping clip with multiple trailing newlines'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: -- bar: | - one - - two -EOF; - $expected = ['foo' => [['bar' => "one\n\ntwo"]]]; - $tests['Literal block chomping clip with embedded blank line inside unindented collection'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: | - one - two -bar: | - one - two -EOF; - $expected = ['foo' => "one\ntwo\n", 'bar' => "one\ntwo"]; - $tests['Literal block chomping clip without trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: |+ - one - two -bar: |+ - one - two - -EOF; - $expected = ['foo' => "one\ntwo\n", 'bar' => "one\ntwo\n"]; - $tests['Literal block chomping keep with single trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: |+ - one - two - -bar: |+ - one - two - - -EOF; - $expected = ['foo' => "one\ntwo\n\n", 'bar' => "one\ntwo\n\n"]; - $tests['Literal block chomping keep with multiple trailing newlines'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: |+ - one - two -bar: |+ - one - two -EOF; - $expected = ['foo' => "one\ntwo\n", 'bar' => "one\ntwo"]; - $tests['Literal block chomping keep without trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: >- - one - two -bar: >- - one - two - -EOF; - $expected = ['foo' => 'one two', 'bar' => 'one two']; - $tests['Folded block chomping strip with single trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: >- - one - two - -bar: >- - one - two - - -EOF; - $expected = ['foo' => 'one two', 'bar' => 'one two']; - $tests['Folded block chomping strip with multiple trailing newlines'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: >- - one - two -bar: >- - one - two -EOF; - $expected = ['foo' => 'one two', 'bar' => 'one two']; - $tests['Folded block chomping strip without trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: > - one - two -bar: > - one - two - -EOF; - $expected = ['foo' => "one two\n", 'bar' => "one two\n"]; - $tests['Folded block chomping clip with single trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: > - one - two - -bar: > - one - two - - -EOF; - $expected = ['foo' => "one two\n", 'bar' => "one two\n"]; - $tests['Folded block chomping clip with multiple trailing newlines'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: > - one - two -bar: > - one - two -EOF; - $expected = ['foo' => "one two\n", 'bar' => 'one two']; - $tests['Folded block chomping clip without trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: >+ - one - two -bar: >+ - one - two - -EOF; - $expected = ['foo' => "one two\n", 'bar' => "one two\n"]; - $tests['Folded block chomping keep with single trailing newline'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: >+ - one - two - -bar: >+ - one - two - - -EOF; - $expected = ['foo' => "one two\n\n", 'bar' => "one two\n\n"]; - $tests['Folded block chomping keep with multiple trailing newlines'] = [$expected, $yaml]; - $yaml = <<<'EOF' -foo: >+ - one - two -bar: >+ - one - two -EOF; - $expected = ['foo' => "one two\n", 'bar' => 'one two']; - $tests['Folded block chomping keep without trailing newline'] = [$expected, $yaml]; - return $tests; - } - /** - * @dataProvider getBlockChompingTests - */ - public function testBlockChomping($expected, $yaml) - { - $this->assertSame($expected, $this->parser->parse($yaml)); - } - /** - * Regression test for issue #7989. - * - * @see https://github.com/symfony/symfony/issues/7989 - */ - public function testBlockLiteralWithLeadingNewlines() - { - $yaml = <<<'EOF' -foo: |- - - - bar - -EOF; - $expected = ['foo' => "\n\nbar"]; - $this->assertSame($expected, $this->parser->parse($yaml)); - } - public function testObjectSupportEnabled() - { - $input = <<<'EOF' -foo: !php/object O:30:"Symfony\Component\Yaml\Tests\B":1:{s:1:"b";s:3:"foo";} -bar: 1 -EOF; - $this->assertEquals(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\B(), 'bar' => 1], $this->parser->parse($input, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT), '->parse() is able to parse objects'); - } - /** - * @group legacy - */ - public function testObjectSupportEnabledPassingTrue() - { - $input = <<<'EOF' -foo: !php/object:O:30:"Symfony\Component\Yaml\Tests\B":1:{s:1:"b";s:3:"foo";} -bar: 1 -EOF; - $this->assertEquals(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\B(), 'bar' => 1], $this->parser->parse($input, \false, \true), '->parse() is able to parse objects'); - } - /** - * @group legacy - * @dataProvider deprecatedObjectValueProvider - */ - public function testObjectSupportEnabledWithDeprecatedTag($yaml) - { - $this->assertEquals(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\B(), 'bar' => 1], $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT), '->parse() is able to parse objects'); - } - public function deprecatedObjectValueProvider() - { - return [[<<assertEquals(['foo' => null, 'bar' => 1], $this->parser->parse($input), '->parse() does not parse objects'); - } - /** - * @dataProvider getObjectForMapTests - */ - public function testObjectForMap($yaml, $expected) - { - $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP; - $this->assertEquals($expected, $this->parser->parse($yaml, $flags)); - } - /** - * @group legacy - * @dataProvider getObjectForMapTests - */ - public function testObjectForMapEnabledWithMappingUsingBooleanToggles($yaml, $expected) - { - $this->assertEquals($expected, $this->parser->parse($yaml, \false, \false, \true)); - } - public function getObjectForMapTests() - { - $tests = []; - $yaml = <<<'EOF' -foo: - fiz: [cat] -EOF; - $expected = new \stdClass(); - $expected->foo = new \stdClass(); - $expected->foo->fiz = ['cat']; - $tests['mapping'] = [$yaml, $expected]; - $yaml = '{ "foo": "bar", "fiz": "cat" }'; - $expected = new \stdClass(); - $expected->foo = 'bar'; - $expected->fiz = 'cat'; - $tests['inline-mapping'] = [$yaml, $expected]; - $yaml = "foo: bar\nbaz: foobar"; - $expected = new \stdClass(); - $expected->foo = 'bar'; - $expected->baz = 'foobar'; - $tests['object-for-map-is-applied-after-parsing'] = [$yaml, $expected]; - $yaml = <<<'EOT' -array: - - key: one - - key: two -EOT; - $expected = new \stdClass(); - $expected->array = []; - $expected->array[0] = new \stdClass(); - $expected->array[0]->key = 'one'; - $expected->array[1] = new \stdClass(); - $expected->array[1]->key = 'two'; - $tests['nest-map-and-sequence'] = [$yaml, $expected]; - $yaml = <<<'YAML' -map: - 1: one - 2: two -YAML; - $expected = new \stdClass(); - $expected->map = new \stdClass(); - $expected->map->{1} = 'one'; - $expected->map->{2} = 'two'; - $tests['numeric-keys'] = [$yaml, $expected]; - $yaml = <<<'YAML' -map: - '0': one - '1': two -YAML; - $expected = new \stdClass(); - $expected->map = new \stdClass(); - $expected->map->{0} = 'one'; - $expected->map->{1} = 'two'; - $tests['zero-indexed-numeric-keys'] = [$yaml, $expected]; - return $tests; - } - /** - * @dataProvider invalidDumpedObjectProvider - */ - public function testObjectsSupportDisabledWithExceptions($yaml) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE); - } - public function testCanParseContentWithTrailingSpaces() - { - $yaml = "items: \n foo: bar"; - $expected = ['items' => ['foo' => 'bar']]; - $this->assertSame($expected, $this->parser->parse($yaml)); - } - /** - * @group legacy - * @dataProvider invalidDumpedObjectProvider - */ - public function testObjectsSupportDisabledWithExceptionsUsingBooleanToggles($yaml) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->parser->parse($yaml, \true); - } - public function invalidDumpedObjectProvider() - { - $yamlTag = <<<'EOF' -foo: !!php/object:O:30:"Symfony\Tests\Component\Yaml\B":1:{s:1:"b";s:3:"foo";} -bar: 1 -EOF; - $localTag = <<<'EOF' -foo: !php/object:O:30:"Symfony\Tests\Component\Yaml\B":1:{s:1:"b";s:3:"foo";} -bar: 1 -EOF; - return ['yaml-tag' => [$yamlTag], 'local-tag' => [$localTag]]; - } - /** - * @requires extension iconv - */ - public function testNonUtf8Exception() - { - $yamls = [\iconv('UTF-8', 'ISO-8859-1', "foo: 'äöüß'"), \iconv('UTF-8', 'ISO-8859-15', "euro: '€'"), \iconv('UTF-8', 'CP1252', "cp1252: '©ÉÇáñ'")]; - foreach ($yamls as $yaml) { - try { - $this->parser->parse($yaml); - $this->fail('charsets other than UTF-8 are rejected.'); - } catch (\Exception $e) { - $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException', $e, 'charsets other than UTF-8 are rejected.'); - } - } - } - public function testUnindentedCollectionException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $yaml = <<<'EOF' - -collection: --item1 --item2 --item3 - -EOF; - $this->parser->parse($yaml); - } - public function testShortcutKeyUnindentedCollectionException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $yaml = <<<'EOF' - -collection: -- key: foo - foo: bar - -EOF; - $this->parser->parse($yaml); - } - public function testMultipleDocumentsNotSupportedException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessageRegExp('/^Multiple documents are not supported.+/'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOL' -# Ranking of 1998 home runs ---- -- Mark McGwire -- Sammy Sosa -- Ken Griffey - -# Team ranking ---- -- Chicago Cubs -- St Louis Cardinals -EOL -); - } - public function testSequenceInAMapping() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' -yaml: - hash: me - - array stuff -EOF -); - } - public function testSequenceInMappingStartedBySingleDashLine() - { - $yaml = <<<'EOT' -a: -- - b: - - - bar: baz -- foo -d: e -EOT; - $expected = ['a' => [['b' => [['bar' => 'baz']]], 'foo'], 'd' => 'e']; - $this->assertSame($expected, $this->parser->parse($yaml)); - } - public function testSequenceFollowedByCommentEmbeddedInMapping() - { - $yaml = <<<'EOT' -a: - b: - - c -# comment - d: e -EOT; - $expected = ['a' => ['b' => ['c'], 'd' => 'e']]; - $this->assertSame($expected, $this->parser->parse($yaml)); - } - public function testNonStringFollowedByCommentEmbeddedInMapping() - { - $yaml = <<<'EOT' -a: - b: - {} -# comment - d: - 1.1 -# another comment -EOT; - $expected = ['a' => ['b' => [], 'd' => 1.1]]; - $this->assertSame($expected, $this->parser->parse($yaml)); - } - public function getParseExceptionNotAffectedMultiLineStringLastResortParsing() - { - $tests = []; - $yaml = <<<'EOT' -a - b: -EOT; - $tests['parse error on first line'] = [$yaml]; - $yaml = <<<'EOT' -a - -b - c: -EOT; - $tests['parse error due to inconsistent indentation'] = [$yaml]; - $yaml = <<<'EOT' - & * ! | > ' " % @ ` #, { asd a;sdasd }-@^qw3 -EOT; - $tests['symfony/symfony/issues/22967#issuecomment-322067742'] = [$yaml]; - return $tests; - } - /** - * @dataProvider getParseExceptionNotAffectedMultiLineStringLastResortParsing - */ - public function testParseExceptionNotAffectedByMultiLineStringLastResortParsing($yaml) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->parser->parse($yaml); - } - public function testMultiLineStringLastResortParsing() - { - $yaml = <<<'EOT' -test: - You can have things that don't look like strings here - true - yes you can -EOT; - $expected = ['test' => 'You can have things that don\'t look like strings here true yes you can']; - $this->assertSame($expected, $this->parser->parse($yaml)); - $yaml = <<<'EOT' -a: - b - c -EOT; - $expected = ['a' => 'b c']; - $this->assertSame($expected, $this->parser->parse($yaml)); - } - public function testMappingInASequence() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' -yaml: - - array stuff - hash: me -EOF -); - } - public function testScalarInSequence() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('missing colon'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' -foo: - - bar -"missing colon" - foo: bar -EOF -); - } - /** - * > It is an error for two equal keys to appear in the same mapping node. - * > In such a case the YAML processor may continue, ignoring the second - * > `key: value` pair and issuing an appropriate warning. This strategy - * > preserves a consistent information model for one-pass and random access - * > applications. - * - * @see http://yaml.org/spec/1.2/spec.html#id2759572 - * @see http://yaml.org/spec/1.1/#id932806 - * @group legacy - */ - public function testMappingDuplicateKeyBlock() - { - $input = <<<'EOD' -parent: - child: first - child: duplicate -parent: - child: duplicate - child: duplicate -EOD; - $expected = ['parent' => ['child' => 'first']]; - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($input)); - } - /** - * @group legacy - */ - public function testMappingDuplicateKeyFlow() - { - $input = <<<'EOD' -parent: { child: first, child: duplicate } -parent: { child: duplicate, child: duplicate } -EOD; - $expected = ['parent' => ['child' => 'first']]; - $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($input)); - } - /** - * @group legacy - * @dataProvider getParseExceptionOnDuplicateData - * @expectedDeprecation Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated %s and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0 on line %d. - * throws \Symfony\Component\Yaml\Exception\ParseException in 4.0 - */ - public function testParseExceptionOnDuplicate($input, $duplicateKey, $lineNumber) - { - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($input); - } - public function getParseExceptionOnDuplicateData() - { - $tests = []; - $yaml = <<assertEquals(['hash' => null], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($input)); - } - public function testCommentAtTheRootIndent() - { - $this->assertEquals(['services' => ['app.foo_service' => ['class' => 'Foo'], 'app/bar_service' => ['class' => 'Bar']]], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' -# comment 1 -services: -# comment 2 - # comment 3 - app.foo_service: - class: Foo -# comment 4 - # comment 5 - app/bar_service: - class: Bar -EOF -)); - } - public function testStringBlockWithComments() - { - $this->assertEquals(['content' => <<<'EOT' -# comment 1 -header - - # comment 2 - -

    title

    - - -footer # comment3 -EOT -], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' -content: | - # comment 1 - header - - # comment 2 - -

    title

    - - - footer # comment3 -EOF -)); - } - public function testFoldedStringBlockWithComments() - { - $this->assertEquals([['content' => <<<'EOT' -# comment 1 -header - - # comment 2 - -

    title

    - - -footer # comment3 -EOT -]], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' -- - content: | - # comment 1 - header - - # comment 2 - -

    title

    - - - footer # comment3 -EOF -)); - } - public function testNestedFoldedStringBlockWithComments() - { - $this->assertEquals([['title' => 'some title', 'content' => <<<'EOT' -# comment 1 -header - - # comment 2 - -

    title

    - - -footer # comment3 -EOT -]], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' -- - title: some title - content: | - # comment 1 - header - - # comment 2 - -

    title

    - - - footer # comment3 -EOF -)); - } - public function testReferenceResolvingInInlineStrings() - { - $this->assertEquals(['var' => 'var-value', 'scalar' => 'var-value', 'list' => ['var-value'], 'list_in_list' => [['var-value']], 'map_in_list' => [['key' => 'var-value']], 'embedded_mapping' => [['key' => 'var-value']], 'map' => ['key' => 'var-value'], 'list_in_map' => ['key' => ['var-value']], 'map_in_map' => ['foo' => ['bar' => 'var-value']]], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' -var: &var var-value -scalar: *var -list: [ *var ] -list_in_list: [[ *var ]] -map_in_list: [ { key: *var } ] -embedded_mapping: [ key: *var ] -map: { key: *var } -list_in_map: { key: [*var] } -map_in_map: { foo: { bar: *var } } -EOF -)); - } - public function testYamlDirective() - { - $yaml = <<<'EOF' -%YAML 1.2 ---- -foo: 1 -bar: 2 -EOF; - $this->assertEquals(['foo' => 1, 'bar' => 2], $this->parser->parse($yaml)); - } - /** - * @group legacy - * @expectedDeprecation Implicit casting of numeric key to string is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0. Quote your evaluable mapping keys instead on line 2. - */ - public function testFloatKeys() - { - $yaml = <<<'EOF' -foo: - 1.2: "bar" - 1.3: "baz" -EOF; - $expected = ['foo' => ['1.2' => 'bar', '1.3' => 'baz']]; - $this->assertEquals($expected, $this->parser->parse($yaml)); - } - /** - * @group legacy - * @expectedDeprecation Implicit casting of non-string key to string is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0. Quote your evaluable mapping keys instead on line 1. - */ - public function testBooleanKeys() - { - $yaml = <<<'EOF' -true: foo -false: bar -EOF; - $expected = [1 => 'foo', 0 => 'bar']; - $this->assertEquals($expected, $this->parser->parse($yaml)); - } - public function testExplicitStringCasting() - { - $yaml = <<<'EOF' -'1.2': "bar" -!!str 1.3: "baz" - -'true': foo -!!str false: bar - -!!str null: 'null' -'~': 'null' -EOF; - $expected = ['1.2' => 'bar', '1.3' => 'baz', 'true' => 'foo', 'false' => 'bar', 'null' => 'null', '~' => 'null']; - $this->assertEquals($expected, $this->parser->parse($yaml)); - } - public function testColonInMappingValueException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('A colon cannot be used in an unquoted mapping value'); - $yaml = <<<'EOF' -foo: bar: baz -EOF; - $this->parser->parse($yaml); - } - public function testColonInMappingValueExceptionNotTriggeredByColonInComment() - { - $yaml = <<<'EOT' -foo: - bar: foobar # Note: a comment after a colon -EOT; - $this->assertSame(['foo' => ['bar' => 'foobar']], $this->parser->parse($yaml)); - } - /** - * @dataProvider getCommentLikeStringInScalarBlockData - */ - public function testCommentLikeStringsAreNotStrippedInBlockScalars($yaml, $expectedParserResult) - { - $this->assertSame($expectedParserResult, $this->parser->parse($yaml)); - } - public function getCommentLikeStringInScalarBlockData() - { - $tests = []; - $yaml = <<<'EOT' -pages: - - - title: some title - content: | - # comment 1 - header - - # comment 2 - -

    title

    - - - footer # comment3 -EOT; - $expected = ['pages' => [['title' => 'some title', 'content' => <<<'EOT' -# comment 1 -header - - # comment 2 - -

    title

    - - -footer # comment3 -EOT -]]]; - $tests[] = [$yaml, $expected]; - $yaml = <<<'EOT' -test: | - foo - # bar - baz -collection: - - one: | - foo - # bar - baz - - two: | - foo - # bar - baz -EOT; - $expected = ['test' => <<<'EOT' -foo -# bar -baz - -EOT -, 'collection' => [['one' => <<<'EOT' -foo -# bar -baz - -EOT -], ['two' => <<<'EOT' -foo -# bar -baz -EOT -]]]; - $tests[] = [$yaml, $expected]; - $yaml = <<<'EOT' -foo: - bar: - scalar-block: > - line1 - line2> - baz: -# comment - foobar: ~ -EOT; - $expected = ['foo' => ['bar' => ['scalar-block' => "line1 line2>\n"], 'baz' => ['foobar' => null]]]; - $tests[] = [$yaml, $expected]; - $yaml = <<<'EOT' -a: - b: hello -# c: | -# first row -# second row - d: hello -EOT; - $expected = ['a' => ['b' => 'hello', 'd' => 'hello']]; - $tests[] = [$yaml, $expected]; - return $tests; - } - public function testBlankLinesAreParsedAsNewLinesInFoldedBlocks() - { - $yaml = <<<'EOT' -test: > -

    A heading

    - -
      -
    • a list
    • -
    • may be a good example
    • -
    -EOT; - $this->assertSame(['test' => <<<'EOT' -

    A heading

    -
    • a list
    • may be a good example
    -EOT -], $this->parser->parse($yaml)); - } - public function testAdditionallyIndentedLinesAreParsedAsNewLinesInFoldedBlocks() - { - $yaml = <<<'EOT' -test: > -

    A heading

    - -
      -
    • a list
    • -
    • may be a good example
    • -
    -EOT; - $this->assertSame(['test' => <<<'EOT' -

    A heading

    -
      -
    • a list
    • -
    • may be a good example
    • -
    -EOT -], $this->parser->parse($yaml)); - } - /** - * @dataProvider getBinaryData - */ - public function testParseBinaryData($data) - { - $this->assertSame(['data' => 'Hello world'], $this->parser->parse($data)); - } - public function getBinaryData() - { - return ['enclosed with double quotes' => ['data: !!binary "SGVsbG8gd29ybGQ="'], 'enclosed with single quotes' => ["data: !!binary 'SGVsbG8gd29ybGQ='"], 'containing spaces' => ['data: !!binary "SGVs bG8gd 29ybGQ="'], 'in block scalar' => [<<<'EOT' -data: !!binary | - SGVsbG8gd29ybGQ= -EOT -], 'containing spaces in block scalar' => [<<<'EOT' -data: !!binary | - SGVs bG8gd 29ybGQ= -EOT -]]; - } - /** - * @dataProvider getInvalidBinaryData - */ - public function testParseInvalidBinaryData($data, $expectedMessage) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessageRegExp($expectedMessage); - $this->parser->parse($data); - } - public function getInvalidBinaryData() - { - return ['length not a multiple of four' => ['data: !!binary "SGVsbG8d29ybGQ="', '/The normalized base64 encoded data \\(data without whitespace characters\\) length must be a multiple of four \\(\\d+ bytes given\\)/'], 'invalid characters' => ['!!binary "SGVsbG8#d29ybGQ="', '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'too many equals characters' => ['data: !!binary "SGVsbG8gd29yb==="', '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'misplaced equals character' => ['data: !!binary "SGVsbG8gd29ybG=Q"', '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'length not a multiple of four in block scalar' => [<<<'EOT' -data: !!binary | - SGVsbG8d29ybGQ= -EOT -, '/The normalized base64 encoded data \\(data without whitespace characters\\) length must be a multiple of four \\(\\d+ bytes given\\)/'], 'invalid characters in block scalar' => [<<<'EOT' -data: !!binary | - SGVsbG8#d29ybGQ= -EOT -, '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'too many equals characters in block scalar' => [<<<'EOT' -data: !!binary | - SGVsbG8gd29yb=== -EOT -, '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'misplaced equals character in block scalar' => [<<<'EOT' -data: !!binary | - SGVsbG8gd29ybG=Q -EOT -, '/The base64 encoded data \\(.*\\) contains invalid characters/']]; - } - public function testParseDateAsMappingValue() - { - $yaml = <<<'EOT' -date: 2002-12-14 -EOT; - $expectedDate = new \DateTime(); - $expectedDate->setTimeZone(new \DateTimeZone('UTC')); - $expectedDate->setDate(2002, 12, 14); - $expectedDate->setTime(0, 0, 0); - $this->assertEquals(['date' => $expectedDate], $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_DATETIME)); - } - /** - * @param $lineNumber - * @param $yaml - * @dataProvider parserThrowsExceptionWithCorrectLineNumberProvider - */ - public function testParserThrowsExceptionWithCorrectLineNumber($lineNumber, $yaml) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage(\sprintf('Unexpected characters near "," at line %d (near "bar: "123",").', $lineNumber)); - $this->parser->parse($yaml); - } - public function parserThrowsExceptionWithCorrectLineNumberProvider() - { - return [[4, <<<'YAML' -foo: - - - # bar - bar: "123", -YAML -], [5, <<<'YAML' -foo: - - - # bar - # bar - bar: "123", -YAML -], [8, <<<'YAML' -foo: - - - # foobar - baz: 123 -bar: - - - # bar - bar: "123", -YAML -], [10, <<<'YAML' -foo: - - - # foobar - # foobar - baz: 123 -bar: - - - # bar - # bar - bar: "123", -YAML -]]; - } - public function testParseMultiLineQuotedString() - { - $yaml = <<assertSame(['foo' => 'bar baz foobar foo', 'bar' => 'baz'], $this->parser->parse($yaml)); - } - public function testMultiLineQuotedStringWithTrailingBackslash() - { - $yaml = <<assertSame(['foobar' => 'foobar'], $this->parser->parse($yaml)); - } - public function testCommentCharactersInMultiLineQuotedStrings() - { - $yaml = << ['foobar' => 'foo #bar', 'bar' => 'baz']]; - $this->assertSame($expected, $this->parser->parse($yaml)); - } - public function testBlankLinesInQuotedMultiLineString() - { - $yaml = << "foo\nbar"]; - $this->assertSame($expected, $this->parser->parse($yaml)); - } - public function testParseMultiLineUnquotedString() - { - $yaml = <<assertSame(['foo' => 'bar baz foobar foo', 'bar' => 'baz'], $this->parser->parse($yaml)); - } - public function testParseMultiLineString() - { - $this->assertEquals("foo bar\nbaz", $this->parser->parse("foo\nbar\n\nbaz")); - } - /** - * @dataProvider multiLineDataProvider - */ - public function testParseMultiLineMappingValue($yaml, $expected, $parseError) - { - $this->assertEquals($expected, $this->parser->parse($yaml)); - } - public function multiLineDataProvider() - { - $tests = []; - $yaml = <<<'EOF' -foo: -- bar: - one - - two - three -EOF; - $expected = ['foo' => [['bar' => "one\ntwo three"]]]; - $tests[] = [$yaml, $expected, \false]; - $yaml = <<<'EOF' -bar -"foo" -EOF; - $expected = 'bar "foo"'; - $tests[] = [$yaml, $expected, \false]; - $yaml = <<<'EOF' -bar -"foo -EOF; - $expected = 'bar "foo'; - $tests[] = [$yaml, $expected, \false]; - $yaml = <<<'EOF' -bar - -'foo' -EOF; - $expected = "bar\n'foo'"; - $tests[] = [$yaml, $expected, \false]; - $yaml = <<<'EOF' -bar - -foo' -EOF; - $expected = "bar\nfoo'"; - $tests[] = [$yaml, $expected, \false]; - return $tests; - } - public function testTaggedInlineMapping() - { - $this->assertEquals(new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('foo', ['foo' => 'bar']), $this->parser->parse('!foo {foo: bar}', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS)); - } - /** - * @dataProvider taggedValuesProvider - */ - public function testCustomTagSupport($expected, $yaml) - { - $this->assertEquals($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS)); - } - public function taggedValuesProvider() - { - return ['sequences' => [[new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('foo', ['yaml']), new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('quz', ['bar'])], << [new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('foo', ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('quz', ['bar']), 'quz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('foo', ['quz' => 'bar'])]), << [[new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('foo', ['foo', 'bar']), new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('quz', ['foo' => 'bar', 'quz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('bar', ['one' => 'bar'])])], <<expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('Tags support is not enabled. Enable the `Yaml::PARSE_CUSTOM_TAGS` flag to use "!iterator" at line 1 (near "!iterator [foo]").'); - $this->parser->parse('!iterator [foo]'); - } - /** - * @group legacy - * @expectedDeprecation Using the unquoted scalar value "!iterator foo" is deprecated since Symfony 3.3 and will be considered as a tagged value in 4.0. You must quote it on line 1. - */ - public function testUnsupportedTagWithScalar() - { - $this->assertEquals('!iterator foo', $this->parser->parse('!iterator foo')); - } - public function testExceptionWhenUsingUnsupportedBuiltInTags() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('The built-in tag "!!foo" is not implemented at line 1 (near "!!foo").'); - $this->parser->parse('!!foo'); - } - /** - * @group legacy - * @expectedDeprecation Starting an unquoted string with a question mark followed by a space is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0 on line 1. - */ - public function testComplexMappingThrowsParseException() - { - $yaml = <<parser->parse($yaml); - } - /** - * @group legacy - * @expectedDeprecation Starting an unquoted string with a question mark followed by a space is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0 on line 2. - */ - public function testComplexMappingNestedInMappingThrowsParseException() - { - $yaml = <<parser->parse($yaml); - } - /** - * @group legacy - * @expectedDeprecation Starting an unquoted string with a question mark followed by a space is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0 on line 1. - */ - public function testComplexMappingNestedInSequenceThrowsParseException() - { - $yaml = <<parser->parse($yaml); - } - public function testParsingIniThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('Unable to parse at line 1 (near "[parameters]").'); - $ini = <<parser->parse($ini); - } - private function loadTestsFromFixtureFiles($testsFile) - { - $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); - $tests = []; - $files = $parser->parseFile(__DIR__ . '/Fixtures/' . $testsFile); - foreach ($files as $file) { - $yamls = \file_get_contents(__DIR__ . '/Fixtures/' . $file . '.yml'); - // split YAMLs documents - foreach (\preg_split('/^---( %YAML\\:1\\.0)?/m', $yamls) as $yaml) { - if (!$yaml) { - continue; - } - $test = $parser->parse($yaml); - if (isset($test['todo']) && $test['todo']) { - // TODO - } else { - eval('$expected = ' . \trim($test['php']) . ';'); - $tests[] = [\var_export($expected, \true), $test['yaml'], $test['test'], isset($test['deprecated']) ? $test['deprecated'] : \false]; - } - } - } - return $tests; - } - public function testCanParseVeryLongValue() - { - $longStringWithSpaces = \str_repeat('xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx ', 20000); - $trickyVal = ['x' => $longStringWithSpaces]; - $yamlString = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::dump($trickyVal); - $arrayFromYaml = $this->parser->parse($yamlString); - $this->assertEquals($trickyVal, $arrayFromYaml); - } - public function testParserCleansUpReferencesBetweenRuns() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('Reference "foo" does not exist at line 2'); - $yaml = <<parser->parse($yaml); - $yaml = <<parser->parse($yaml); - } - public function testPhpConstantTagMappingKey() - { - $yaml = << ['foo' => ['from' => ['bar'], 'to' => 'baz']]]; - $this->assertSame($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT)); - } - /** - * @group legacy - * @expectedDeprecation The !php/const: tag to indicate dumped PHP constants is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/const (without the colon) tag instead on line 2. - * @expectedDeprecation The !php/const: tag to indicate dumped PHP constants is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/const (without the colon) tag instead on line 4. - * @expectedDeprecation The !php/const: tag to indicate dumped PHP constants is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/const (without the colon) tag instead on line 5. - */ - public function testDeprecatedPhpConstantTagMappingKey() - { - $yaml = << ['foo' => ['from' => ['bar'], 'to' => 'baz']]]; - $this->assertSame($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT)); - } - /** - * @group legacy - * @expectedDeprecation Using the Yaml::PARSE_KEYS_AS_STRINGS flag is deprecated since Symfony 3.4 as it will be removed in 4.0. Quote your keys when they are evaluable instead. - */ - public function testPhpConstantTagMappingKeyWithKeysCastToStrings() - { - $yaml = << ['foo' => ['from' => ['bar'], 'to' => 'baz']]]; - $this->assertSame($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT | \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_KEYS_AS_STRINGS)); - } - public function testMergeKeysWhenMappingsAreParsedAsObjects() - { - $yaml = << (object) ['bar' => 1], 'bar' => (object) ['baz' => 2, 'bar' => 1], 'baz' => (object) ['baz_foo' => 3, 'baz_bar' => 4], 'foobar' => (object) ['bar' => null, 'baz' => 2]]; - $this->assertEquals($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP)); - } - public function testFilenamesAreParsedAsStringsWithoutFlag() - { - $file = __DIR__ . '/Fixtures/index.yml'; - $this->assertSame($file, $this->parser->parse($file)); - } - public function testParseFile() - { - $this->assertIsArray($this->parser->parseFile(__DIR__ . '/Fixtures/index.yml')); - } - public function testParsingNonExistentFilesThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessageRegExp('#^File ".+/Fixtures/nonexistent.yml" does not exist\\.$#'); - $this->parser->parseFile(__DIR__ . '/Fixtures/nonexistent.yml'); - } - public function testParsingNotReadableFilesThrowsException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessageRegExp('#^File ".+/Fixtures/not_readable.yml" cannot be read\\.$#'); - if ('\\' === \DIRECTORY_SEPARATOR) { - $this->markTestSkipped('chmod is not supported on Windows'); - } - if (!\getenv('USER') || 'root' === \getenv('USER')) { - $this->markTestSkipped('This test will fail if run under superuser'); - } - $file = __DIR__ . '/Fixtures/not_readable.yml'; - \chmod($file, 0200); - $this->parser->parseFile($file); - } - public function testParseReferencesOnMergeKeys() - { - $yaml = << ['a' => 'foo', 'b' => 'bar', 'c' => 'baz'], 'mergekeyderef' => ['d' => 'quux', 'b' => 'bar', 'c' => 'baz']]; - $this->assertSame($expected, $this->parser->parse($yaml)); - } - public function testParseReferencesOnMergeKeysWithMappingsParsedAsObjects() - { - $yaml = << (object) ['a' => 'foo', 'b' => 'bar', 'c' => 'baz'], 'mergekeyderef' => (object) ['d' => 'quux', 'b' => 'bar', 'c' => 'baz']]; - $this->assertEquals($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP)); - } - public function testEvalRefException() - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('Reference "foo" does not exist'); - $yaml = <<parser->parse($yaml); - } - /** - * @dataProvider circularReferenceProvider - */ - public function testDetectCircularReferences($yaml) - { - $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); - $this->expectExceptionMessage('Circular reference [foo, bar, foo] detected'); - $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS); - } - public function circularReferenceProvider() - { - $tests = []; - $yaml = <<assertSame($expected, $this->parser->parse($yaml)); - } - public function indentedMappingData() - { - $tests = []; - $yaml = << [['bar' => 'foobar', 'baz' => 'foobaz']]]; - $tests['comment line is first line in indented block'] = [$yaml, $expected]; - $yaml = << [['bar' => ['baz' => [1, 2, 3]]]]]; - $tests['mapping value on new line starting with a comment line'] = [$yaml, $expected]; - $yaml = << [['bar' => 'foobar']]]; - $tests['mapping in sequence starting on a new line'] = [$yaml, $expected]; - $yaml = << ['bar' => 'baz']]; - $tests['blank line at the beginning of an indented mapping value'] = [$yaml, $expected]; - return $tests; - } - public function testMultiLineComment() - { - $yaml = <<assertSame(['parameters' => 'abc'], $this->parser->parse($yaml)); - } - public function testParseValueWithModifiers() - { - $yaml = <<assertSame(['parameters' => ['abc' => \implode("\n", ['one', 'two', 'three', 'four', 'five'])]], $this->parser->parse($yaml)); - } - public function testParseValueWithNegativeModifiers() - { - $yaml = <<assertSame(['parameters' => ['abc' => \implode("\n", ['one', 'two', 'three', 'four', 'five'])]], $this->parser->parse($yaml)); - } -} -class B -{ - public $b = 'foo'; - const FOO = 'foo'; - const BAR = 'bar'; - const BAZ = 'baz'; -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; +class ParserTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + /** @var Parser */ + protected $parser; + protected function setUp() + { + $this->parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); + } + protected function tearDown() + { + $this->parser = null; + \chmod(__DIR__ . '/Fixtures/not_readable.yml', 0644); + } + /** + * @dataProvider getDataFormSpecifications + */ + public function testSpecifications($expected, $yaml, $comment, $deprecated) + { + $deprecations = []; + if ($deprecated) { + \set_error_handler(function ($type, $msg) use(&$deprecations) { + if (\E_USER_DEPRECATED !== $type) { + \restore_error_handler(); + return \call_user_func_array('PHPUnit\\Util\\ErrorHandler::handleError', \func_get_args()); + } + $deprecations[] = $msg; + return null; + }); + } + $this->assertEquals($expected, \var_export($this->parser->parse($yaml), \true), $comment); + if ($deprecated) { + \restore_error_handler(); + $this->assertCount(1, $deprecations); + $this->assertStringContainsString(\true !== $deprecated ? $deprecated : 'Using the comma as a group separator for floats is deprecated since Symfony 3.2 and will be removed in 4.0 on line 1.', $deprecations[0]); + } + } + public function getDataFormSpecifications() + { + return $this->loadTestsFromFixtureFiles('index.yml'); + } + /** + * @group legacy + * @expectedDeprecationMessage Using the Yaml::PARSE_KEYS_AS_STRINGS flag is deprecated since Symfony 3.4 as it will be removed in 4.0. Quote your keys when they are evaluable + * @dataProvider getNonStringMappingKeysData + */ + public function testNonStringMappingKeys($expected, $yaml, $comment) + { + $this->assertSame($expected, \var_export($this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_KEYS_AS_STRINGS), \true), $comment); + } + public function getNonStringMappingKeysData() + { + return $this->loadTestsFromFixtureFiles('nonStringKeys.yml'); + } + /** + * @group legacy + * @dataProvider getLegacyNonStringMappingKeysData + */ + public function testLegacyNonStringMappingKeys($expected, $yaml, $comment) + { + $this->assertSame($expected, \var_export($this->parser->parse($yaml), \true), $comment); + } + public function getLegacyNonStringMappingKeysData() + { + return $this->loadTestsFromFixtureFiles('legacyNonStringKeys.yml'); + } + public function testTabsInYaml() + { + // test tabs in YAML + $yamls = ["foo:\n\tbar", "foo:\n \tbar", "foo:\n\t bar", "foo:\n \t bar"]; + foreach ($yamls as $yaml) { + try { + $this->parser->parse($yaml); + $this->fail('YAML files must not contain tabs'); + } catch (\Exception $e) { + $this->assertInstanceOf('\\Exception', $e, 'YAML files must not contain tabs'); + $this->assertEquals('A YAML file cannot contain tabs as indentation at line 2 (near "' . \strpbrk($yaml, "\t") . '").', $e->getMessage(), 'YAML files must not contain tabs'); + } + } + } + public function testEndOfTheDocumentMarker() + { + $yaml = <<<'EOF' +--- %YAML:1.0 +foo +... +EOF; + $this->assertEquals('foo', $this->parser->parse($yaml)); + } + public function getBlockChompingTests() + { + $tests = []; + $yaml = <<<'EOF' +foo: |- + one + two +bar: |- + one + two + +EOF; + $expected = ['foo' => "one\ntwo", 'bar' => "one\ntwo"]; + $tests['Literal block chomping strip with single trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: |- + one + two + +bar: |- + one + two + + +EOF; + $expected = ['foo' => "one\ntwo", 'bar' => "one\ntwo"]; + $tests['Literal block chomping strip with multiple trailing newlines'] = [$expected, $yaml]; + $yaml = <<<'EOF' +{} + + +EOF; + $expected = []; + $tests['Literal block chomping strip with multiple trailing newlines after a 1-liner'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: |- + one + two +bar: |- + one + two +EOF; + $expected = ['foo' => "one\ntwo", 'bar' => "one\ntwo"]; + $tests['Literal block chomping strip without trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: | + one + two +bar: | + one + two + +EOF; + $expected = ['foo' => "one\ntwo\n", 'bar' => "one\ntwo\n"]; + $tests['Literal block chomping clip with single trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: | + one + two + +bar: | + one + two + + +EOF; + $expected = ['foo' => "one\ntwo\n", 'bar' => "one\ntwo\n"]; + $tests['Literal block chomping clip with multiple trailing newlines'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: +- bar: | + one + + two +EOF; + $expected = ['foo' => [['bar' => "one\n\ntwo"]]]; + $tests['Literal block chomping clip with embedded blank line inside unindented collection'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: | + one + two +bar: | + one + two +EOF; + $expected = ['foo' => "one\ntwo\n", 'bar' => "one\ntwo"]; + $tests['Literal block chomping clip without trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: |+ + one + two +bar: |+ + one + two + +EOF; + $expected = ['foo' => "one\ntwo\n", 'bar' => "one\ntwo\n"]; + $tests['Literal block chomping keep with single trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: |+ + one + two + +bar: |+ + one + two + + +EOF; + $expected = ['foo' => "one\ntwo\n\n", 'bar' => "one\ntwo\n\n"]; + $tests['Literal block chomping keep with multiple trailing newlines'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: |+ + one + two +bar: |+ + one + two +EOF; + $expected = ['foo' => "one\ntwo\n", 'bar' => "one\ntwo"]; + $tests['Literal block chomping keep without trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: >- + one + two +bar: >- + one + two + +EOF; + $expected = ['foo' => 'one two', 'bar' => 'one two']; + $tests['Folded block chomping strip with single trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: >- + one + two + +bar: >- + one + two + + +EOF; + $expected = ['foo' => 'one two', 'bar' => 'one two']; + $tests['Folded block chomping strip with multiple trailing newlines'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: >- + one + two +bar: >- + one + two +EOF; + $expected = ['foo' => 'one two', 'bar' => 'one two']; + $tests['Folded block chomping strip without trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: > + one + two +bar: > + one + two + +EOF; + $expected = ['foo' => "one two\n", 'bar' => "one two\n"]; + $tests['Folded block chomping clip with single trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: > + one + two + +bar: > + one + two + + +EOF; + $expected = ['foo' => "one two\n", 'bar' => "one two\n"]; + $tests['Folded block chomping clip with multiple trailing newlines'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: > + one + two +bar: > + one + two +EOF; + $expected = ['foo' => "one two\n", 'bar' => 'one two']; + $tests['Folded block chomping clip without trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: >+ + one + two +bar: >+ + one + two + +EOF; + $expected = ['foo' => "one two\n", 'bar' => "one two\n"]; + $tests['Folded block chomping keep with single trailing newline'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: >+ + one + two + +bar: >+ + one + two + + +EOF; + $expected = ['foo' => "one two\n\n", 'bar' => "one two\n\n"]; + $tests['Folded block chomping keep with multiple trailing newlines'] = [$expected, $yaml]; + $yaml = <<<'EOF' +foo: >+ + one + two +bar: >+ + one + two +EOF; + $expected = ['foo' => "one two\n", 'bar' => 'one two']; + $tests['Folded block chomping keep without trailing newline'] = [$expected, $yaml]; + return $tests; + } + /** + * @dataProvider getBlockChompingTests + */ + public function testBlockChomping($expected, $yaml) + { + $this->assertSame($expected, $this->parser->parse($yaml)); + } + /** + * Regression test for issue #7989. + * + * @see https://github.com/symfony/symfony/issues/7989 + */ + public function testBlockLiteralWithLeadingNewlines() + { + $yaml = <<<'EOF' +foo: |- + + + bar + +EOF; + $expected = ['foo' => "\n\nbar"]; + $this->assertSame($expected, $this->parser->parse($yaml)); + } + public function testObjectSupportEnabled() + { + $input = <<<'EOF' +foo: !php/object O:30:"Symfony\Component\Yaml\Tests\B":1:{s:1:"b";s:3:"foo";} +bar: 1 +EOF; + $this->assertEquals(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\B(), 'bar' => 1], $this->parser->parse($input, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT), '->parse() is able to parse objects'); + } + /** + * @group legacy + */ + public function testObjectSupportEnabledPassingTrue() + { + $input = <<<'EOF' +foo: !php/object:O:30:"Symfony\Component\Yaml\Tests\B":1:{s:1:"b";s:3:"foo";} +bar: 1 +EOF; + $this->assertEquals(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\B(), 'bar' => 1], $this->parser->parse($input, \false, \true), '->parse() is able to parse objects'); + } + /** + * @group legacy + * @dataProvider deprecatedObjectValueProvider + */ + public function testObjectSupportEnabledWithDeprecatedTag($yaml) + { + $this->assertEquals(['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests\B(), 'bar' => 1], $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT), '->parse() is able to parse objects'); + } + public function deprecatedObjectValueProvider() + { + return [[<<assertEquals(['foo' => null, 'bar' => 1], $this->parser->parse($input), '->parse() does not parse objects'); + } + /** + * @dataProvider getObjectForMapTests + */ + public function testObjectForMap($yaml, $expected) + { + $flags = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP; + $this->assertEquals($expected, $this->parser->parse($yaml, $flags)); + } + /** + * @group legacy + * @dataProvider getObjectForMapTests + */ + public function testObjectForMapEnabledWithMappingUsingBooleanToggles($yaml, $expected) + { + $this->assertEquals($expected, $this->parser->parse($yaml, \false, \false, \true)); + } + public function getObjectForMapTests() + { + $tests = []; + $yaml = <<<'EOF' +foo: + fiz: [cat] +EOF; + $expected = new \stdClass(); + $expected->foo = new \stdClass(); + $expected->foo->fiz = ['cat']; + $tests['mapping'] = [$yaml, $expected]; + $yaml = '{ "foo": "bar", "fiz": "cat" }'; + $expected = new \stdClass(); + $expected->foo = 'bar'; + $expected->fiz = 'cat'; + $tests['inline-mapping'] = [$yaml, $expected]; + $yaml = "foo: bar\nbaz: foobar"; + $expected = new \stdClass(); + $expected->foo = 'bar'; + $expected->baz = 'foobar'; + $tests['object-for-map-is-applied-after-parsing'] = [$yaml, $expected]; + $yaml = <<<'EOT' +array: + - key: one + - key: two +EOT; + $expected = new \stdClass(); + $expected->array = []; + $expected->array[0] = new \stdClass(); + $expected->array[0]->key = 'one'; + $expected->array[1] = new \stdClass(); + $expected->array[1]->key = 'two'; + $tests['nest-map-and-sequence'] = [$yaml, $expected]; + $yaml = <<<'YAML' +map: + 1: one + 2: two +YAML; + $expected = new \stdClass(); + $expected->map = new \stdClass(); + $expected->map->{1} = 'one'; + $expected->map->{2} = 'two'; + $tests['numeric-keys'] = [$yaml, $expected]; + $yaml = <<<'YAML' +map: + '0': one + '1': two +YAML; + $expected = new \stdClass(); + $expected->map = new \stdClass(); + $expected->map->{0} = 'one'; + $expected->map->{1} = 'two'; + $tests['zero-indexed-numeric-keys'] = [$yaml, $expected]; + return $tests; + } + /** + * @dataProvider invalidDumpedObjectProvider + */ + public function testObjectsSupportDisabledWithExceptions($yaml) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_EXCEPTION_ON_INVALID_TYPE); + } + public function testCanParseContentWithTrailingSpaces() + { + $yaml = "items: \n foo: bar"; + $expected = ['items' => ['foo' => 'bar']]; + $this->assertSame($expected, $this->parser->parse($yaml)); + } + /** + * @group legacy + * @dataProvider invalidDumpedObjectProvider + */ + public function testObjectsSupportDisabledWithExceptionsUsingBooleanToggles($yaml) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->parser->parse($yaml, \true); + } + public function invalidDumpedObjectProvider() + { + $yamlTag = <<<'EOF' +foo: !!php/object:O:30:"Symfony\Tests\Component\Yaml\B":1:{s:1:"b";s:3:"foo";} +bar: 1 +EOF; + $localTag = <<<'EOF' +foo: !php/object:O:30:"Symfony\Tests\Component\Yaml\B":1:{s:1:"b";s:3:"foo";} +bar: 1 +EOF; + return ['yaml-tag' => [$yamlTag], 'local-tag' => [$localTag]]; + } + /** + * @requires extension iconv + */ + public function testNonUtf8Exception() + { + $yamls = [\iconv('UTF-8', 'ISO-8859-1', "foo: 'äöüß'"), \iconv('UTF-8', 'ISO-8859-15', "euro: '€'"), \iconv('UTF-8', 'CP1252', "cp1252: '©ÉÇáñ'")]; + foreach ($yamls as $yaml) { + try { + $this->parser->parse($yaml); + $this->fail('charsets other than UTF-8 are rejected.'); + } catch (\Exception $e) { + $this->assertInstanceOf('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException', $e, 'charsets other than UTF-8 are rejected.'); + } + } + } + public function testUnindentedCollectionException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $yaml = <<<'EOF' + +collection: +-item1 +-item2 +-item3 + +EOF; + $this->parser->parse($yaml); + } + public function testShortcutKeyUnindentedCollectionException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $yaml = <<<'EOF' + +collection: +- key: foo + foo: bar + +EOF; + $this->parser->parse($yaml); + } + public function testMultipleDocumentsNotSupportedException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessageRegExp('/^Multiple documents are not supported.+/'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOL' +# Ranking of 1998 home runs +--- +- Mark McGwire +- Sammy Sosa +- Ken Griffey + +# Team ranking +--- +- Chicago Cubs +- St Louis Cardinals +EOL +); + } + public function testSequenceInAMapping() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' +yaml: + hash: me + - array stuff +EOF +); + } + public function testSequenceInMappingStartedBySingleDashLine() + { + $yaml = <<<'EOT' +a: +- + b: + - + bar: baz +- foo +d: e +EOT; + $expected = ['a' => [['b' => [['bar' => 'baz']]], 'foo'], 'd' => 'e']; + $this->assertSame($expected, $this->parser->parse($yaml)); + } + public function testSequenceFollowedByCommentEmbeddedInMapping() + { + $yaml = <<<'EOT' +a: + b: + - c +# comment + d: e +EOT; + $expected = ['a' => ['b' => ['c'], 'd' => 'e']]; + $this->assertSame($expected, $this->parser->parse($yaml)); + } + public function testNonStringFollowedByCommentEmbeddedInMapping() + { + $yaml = <<<'EOT' +a: + b: + {} +# comment + d: + 1.1 +# another comment +EOT; + $expected = ['a' => ['b' => [], 'd' => 1.1]]; + $this->assertSame($expected, $this->parser->parse($yaml)); + } + public function getParseExceptionNotAffectedMultiLineStringLastResortParsing() + { + $tests = []; + $yaml = <<<'EOT' +a + b: +EOT; + $tests['parse error on first line'] = [$yaml]; + $yaml = <<<'EOT' +a + +b + c: +EOT; + $tests['parse error due to inconsistent indentation'] = [$yaml]; + $yaml = <<<'EOT' + & * ! | > ' " % @ ` #, { asd a;sdasd }-@^qw3 +EOT; + $tests['symfony/symfony/issues/22967#issuecomment-322067742'] = [$yaml]; + return $tests; + } + /** + * @dataProvider getParseExceptionNotAffectedMultiLineStringLastResortParsing + */ + public function testParseExceptionNotAffectedByMultiLineStringLastResortParsing($yaml) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->parser->parse($yaml); + } + public function testMultiLineStringLastResortParsing() + { + $yaml = <<<'EOT' +test: + You can have things that don't look like strings here + true + yes you can +EOT; + $expected = ['test' => 'You can have things that don\'t look like strings here true yes you can']; + $this->assertSame($expected, $this->parser->parse($yaml)); + $yaml = <<<'EOT' +a: + b + c +EOT; + $expected = ['a' => 'b c']; + $this->assertSame($expected, $this->parser->parse($yaml)); + } + public function testMappingInASequence() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' +yaml: + - array stuff + hash: me +EOF +); + } + public function testScalarInSequence() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('missing colon'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' +foo: + - bar +"missing colon" + foo: bar +EOF +); + } + /** + * > It is an error for two equal keys to appear in the same mapping node. + * > In such a case the YAML processor may continue, ignoring the second + * > `key: value` pair and issuing an appropriate warning. This strategy + * > preserves a consistent information model for one-pass and random access + * > applications. + * + * @see http://yaml.org/spec/1.2/spec.html#id2759572 + * @see http://yaml.org/spec/1.1/#id932806 + * @group legacy + */ + public function testMappingDuplicateKeyBlock() + { + $input = <<<'EOD' +parent: + child: first + child: duplicate +parent: + child: duplicate + child: duplicate +EOD; + $expected = ['parent' => ['child' => 'first']]; + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($input)); + } + /** + * @group legacy + */ + public function testMappingDuplicateKeyFlow() + { + $input = <<<'EOD' +parent: { child: first, child: duplicate } +parent: { child: duplicate, child: duplicate } +EOD; + $expected = ['parent' => ['child' => 'first']]; + $this->assertSame($expected, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($input)); + } + /** + * @group legacy + * @dataProvider getParseExceptionOnDuplicateData + * @expectedDeprecation Duplicate key "%s" detected whilst parsing YAML. Silent handling of duplicate mapping keys in YAML is deprecated %s and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0 on line %d. + * throws \Symfony\Component\Yaml\Exception\ParseException in 4.0 + */ + public function testParseExceptionOnDuplicate($input, $duplicateKey, $lineNumber) + { + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($input); + } + public function getParseExceptionOnDuplicateData() + { + $tests = []; + $yaml = <<assertEquals(['hash' => null], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($input)); + } + public function testCommentAtTheRootIndent() + { + $this->assertEquals(['services' => ['app.foo_service' => ['class' => 'Foo'], 'app/bar_service' => ['class' => 'Bar']]], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' +# comment 1 +services: +# comment 2 + # comment 3 + app.foo_service: + class: Foo +# comment 4 + # comment 5 + app/bar_service: + class: Bar +EOF +)); + } + public function testStringBlockWithComments() + { + $this->assertEquals(['content' => <<<'EOT' +# comment 1 +header + + # comment 2 + +

    title

    + + +footer # comment3 +EOT +], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' +content: | + # comment 1 + header + + # comment 2 + +

    title

    + + + footer # comment3 +EOF +)); + } + public function testFoldedStringBlockWithComments() + { + $this->assertEquals([['content' => <<<'EOT' +# comment 1 +header + + # comment 2 + +

    title

    + + +footer # comment3 +EOT +]], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' +- + content: | + # comment 1 + header + + # comment 2 + +

    title

    + + + footer # comment3 +EOF +)); + } + public function testNestedFoldedStringBlockWithComments() + { + $this->assertEquals([['title' => 'some title', 'content' => <<<'EOT' +# comment 1 +header + + # comment 2 + +

    title

    + + +footer # comment3 +EOT +]], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' +- + title: some title + content: | + # comment 1 + header + + # comment 2 + +

    title

    + + + footer # comment3 +EOF +)); + } + public function testReferenceResolvingInInlineStrings() + { + $this->assertEquals(['var' => 'var-value', 'scalar' => 'var-value', 'list' => ['var-value'], 'list_in_list' => [['var-value']], 'map_in_list' => [['key' => 'var-value']], 'embedded_mapping' => [['key' => 'var-value']], 'map' => ['key' => 'var-value'], 'list_in_map' => ['key' => ['var-value']], 'map_in_map' => ['foo' => ['bar' => 'var-value']]], \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse(<<<'EOF' +var: &var var-value +scalar: *var +list: [ *var ] +list_in_list: [[ *var ]] +map_in_list: [ { key: *var } ] +embedded_mapping: [ key: *var ] +map: { key: *var } +list_in_map: { key: [*var] } +map_in_map: { foo: { bar: *var } } +EOF +)); + } + public function testYamlDirective() + { + $yaml = <<<'EOF' +%YAML 1.2 +--- +foo: 1 +bar: 2 +EOF; + $this->assertEquals(['foo' => 1, 'bar' => 2], $this->parser->parse($yaml)); + } + /** + * @group legacy + * @expectedDeprecation Implicit casting of numeric key to string is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0. Quote your evaluable mapping keys instead on line 2. + */ + public function testFloatKeys() + { + $yaml = <<<'EOF' +foo: + 1.2: "bar" + 1.3: "baz" +EOF; + $expected = ['foo' => ['1.2' => 'bar', '1.3' => 'baz']]; + $this->assertEquals($expected, $this->parser->parse($yaml)); + } + /** + * @group legacy + * @expectedDeprecation Implicit casting of non-string key to string is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0. Quote your evaluable mapping keys instead on line 1. + */ + public function testBooleanKeys() + { + $yaml = <<<'EOF' +true: foo +false: bar +EOF; + $expected = [1 => 'foo', 0 => 'bar']; + $this->assertEquals($expected, $this->parser->parse($yaml)); + } + public function testExplicitStringCasting() + { + $yaml = <<<'EOF' +'1.2': "bar" +!!str 1.3: "baz" + +'true': foo +!!str false: bar + +!!str null: 'null' +'~': 'null' +EOF; + $expected = ['1.2' => 'bar', '1.3' => 'baz', 'true' => 'foo', 'false' => 'bar', 'null' => 'null', '~' => 'null']; + $this->assertEquals($expected, $this->parser->parse($yaml)); + } + public function testColonInMappingValueException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('A colon cannot be used in an unquoted mapping value'); + $yaml = <<<'EOF' +foo: bar: baz +EOF; + $this->parser->parse($yaml); + } + public function testColonInMappingValueExceptionNotTriggeredByColonInComment() + { + $yaml = <<<'EOT' +foo: + bar: foobar # Note: a comment after a colon +EOT; + $this->assertSame(['foo' => ['bar' => 'foobar']], $this->parser->parse($yaml)); + } + /** + * @dataProvider getCommentLikeStringInScalarBlockData + */ + public function testCommentLikeStringsAreNotStrippedInBlockScalars($yaml, $expectedParserResult) + { + $this->assertSame($expectedParserResult, $this->parser->parse($yaml)); + } + public function getCommentLikeStringInScalarBlockData() + { + $tests = []; + $yaml = <<<'EOT' +pages: + - + title: some title + content: | + # comment 1 + header + + # comment 2 + +

    title

    + + + footer # comment3 +EOT; + $expected = ['pages' => [['title' => 'some title', 'content' => <<<'EOT' +# comment 1 +header + + # comment 2 + +

    title

    + + +footer # comment3 +EOT +]]]; + $tests[] = [$yaml, $expected]; + $yaml = <<<'EOT' +test: | + foo + # bar + baz +collection: + - one: | + foo + # bar + baz + - two: | + foo + # bar + baz +EOT; + $expected = ['test' => <<<'EOT' +foo +# bar +baz + +EOT +, 'collection' => [['one' => <<<'EOT' +foo +# bar +baz + +EOT +], ['two' => <<<'EOT' +foo +# bar +baz +EOT +]]]; + $tests[] = [$yaml, $expected]; + $yaml = <<<'EOT' +foo: + bar: + scalar-block: > + line1 + line2> + baz: +# comment + foobar: ~ +EOT; + $expected = ['foo' => ['bar' => ['scalar-block' => "line1 line2>\n"], 'baz' => ['foobar' => null]]]; + $tests[] = [$yaml, $expected]; + $yaml = <<<'EOT' +a: + b: hello +# c: | +# first row +# second row + d: hello +EOT; + $expected = ['a' => ['b' => 'hello', 'd' => 'hello']]; + $tests[] = [$yaml, $expected]; + return $tests; + } + public function testBlankLinesAreParsedAsNewLinesInFoldedBlocks() + { + $yaml = <<<'EOT' +test: > +

    A heading

    + +
      +
    • a list
    • +
    • may be a good example
    • +
    +EOT; + $this->assertSame(['test' => <<<'EOT' +

    A heading

    +
    • a list
    • may be a good example
    +EOT +], $this->parser->parse($yaml)); + } + public function testAdditionallyIndentedLinesAreParsedAsNewLinesInFoldedBlocks() + { + $yaml = <<<'EOT' +test: > +

    A heading

    + +
      +
    • a list
    • +
    • may be a good example
    • +
    +EOT; + $this->assertSame(['test' => <<<'EOT' +

    A heading

    +
      +
    • a list
    • +
    • may be a good example
    • +
    +EOT +], $this->parser->parse($yaml)); + } + /** + * @dataProvider getBinaryData + */ + public function testParseBinaryData($data) + { + $this->assertSame(['data' => 'Hello world'], $this->parser->parse($data)); + } + public function getBinaryData() + { + return ['enclosed with double quotes' => ['data: !!binary "SGVsbG8gd29ybGQ="'], 'enclosed with single quotes' => ["data: !!binary 'SGVsbG8gd29ybGQ='"], 'containing spaces' => ['data: !!binary "SGVs bG8gd 29ybGQ="'], 'in block scalar' => [<<<'EOT' +data: !!binary | + SGVsbG8gd29ybGQ= +EOT +], 'containing spaces in block scalar' => [<<<'EOT' +data: !!binary | + SGVs bG8gd 29ybGQ= +EOT +]]; + } + /** + * @dataProvider getInvalidBinaryData + */ + public function testParseInvalidBinaryData($data, $expectedMessage) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessageRegExp($expectedMessage); + $this->parser->parse($data); + } + public function getInvalidBinaryData() + { + return ['length not a multiple of four' => ['data: !!binary "SGVsbG8d29ybGQ="', '/The normalized base64 encoded data \\(data without whitespace characters\\) length must be a multiple of four \\(\\d+ bytes given\\)/'], 'invalid characters' => ['!!binary "SGVsbG8#d29ybGQ="', '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'too many equals characters' => ['data: !!binary "SGVsbG8gd29yb==="', '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'misplaced equals character' => ['data: !!binary "SGVsbG8gd29ybG=Q"', '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'length not a multiple of four in block scalar' => [<<<'EOT' +data: !!binary | + SGVsbG8d29ybGQ= +EOT +, '/The normalized base64 encoded data \\(data without whitespace characters\\) length must be a multiple of four \\(\\d+ bytes given\\)/'], 'invalid characters in block scalar' => [<<<'EOT' +data: !!binary | + SGVsbG8#d29ybGQ= +EOT +, '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'too many equals characters in block scalar' => [<<<'EOT' +data: !!binary | + SGVsbG8gd29yb=== +EOT +, '/The base64 encoded data \\(.*\\) contains invalid characters/'], 'misplaced equals character in block scalar' => [<<<'EOT' +data: !!binary | + SGVsbG8gd29ybG=Q +EOT +, '/The base64 encoded data \\(.*\\) contains invalid characters/']]; + } + public function testParseDateAsMappingValue() + { + $yaml = <<<'EOT' +date: 2002-12-14 +EOT; + $expectedDate = new \DateTime(); + $expectedDate->setTimeZone(new \DateTimeZone('UTC')); + $expectedDate->setDate(2002, 12, 14); + $expectedDate->setTime(0, 0, 0); + $this->assertEquals(['date' => $expectedDate], $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_DATETIME)); + } + /** + * @param $lineNumber + * @param $yaml + * @dataProvider parserThrowsExceptionWithCorrectLineNumberProvider + */ + public function testParserThrowsExceptionWithCorrectLineNumber($lineNumber, $yaml) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage(\sprintf('Unexpected characters near "," at line %d (near "bar: "123",").', $lineNumber)); + $this->parser->parse($yaml); + } + public function parserThrowsExceptionWithCorrectLineNumberProvider() + { + return [[4, <<<'YAML' +foo: + - + # bar + bar: "123", +YAML +], [5, <<<'YAML' +foo: + - + # bar + # bar + bar: "123", +YAML +], [8, <<<'YAML' +foo: + - + # foobar + baz: 123 +bar: + - + # bar + bar: "123", +YAML +], [10, <<<'YAML' +foo: + - + # foobar + # foobar + baz: 123 +bar: + - + # bar + # bar + bar: "123", +YAML +]]; + } + public function testParseMultiLineQuotedString() + { + $yaml = <<assertSame(['foo' => 'bar baz foobar foo', 'bar' => 'baz'], $this->parser->parse($yaml)); + } + public function testMultiLineQuotedStringWithTrailingBackslash() + { + $yaml = <<assertSame(['foobar' => 'foobar'], $this->parser->parse($yaml)); + } + public function testCommentCharactersInMultiLineQuotedStrings() + { + $yaml = << ['foobar' => 'foo #bar', 'bar' => 'baz']]; + $this->assertSame($expected, $this->parser->parse($yaml)); + } + public function testBlankLinesInQuotedMultiLineString() + { + $yaml = << "foo\nbar"]; + $this->assertSame($expected, $this->parser->parse($yaml)); + } + public function testParseMultiLineUnquotedString() + { + $yaml = <<assertSame(['foo' => 'bar baz foobar foo', 'bar' => 'baz'], $this->parser->parse($yaml)); + } + public function testParseMultiLineString() + { + $this->assertEquals("foo bar\nbaz", $this->parser->parse("foo\nbar\n\nbaz")); + } + /** + * @dataProvider multiLineDataProvider + */ + public function testParseMultiLineMappingValue($yaml, $expected, $parseError) + { + $this->assertEquals($expected, $this->parser->parse($yaml)); + } + public function multiLineDataProvider() + { + $tests = []; + $yaml = <<<'EOF' +foo: +- bar: + one + + two + three +EOF; + $expected = ['foo' => [['bar' => "one\ntwo three"]]]; + $tests[] = [$yaml, $expected, \false]; + $yaml = <<<'EOF' +bar +"foo" +EOF; + $expected = 'bar "foo"'; + $tests[] = [$yaml, $expected, \false]; + $yaml = <<<'EOF' +bar +"foo +EOF; + $expected = 'bar "foo'; + $tests[] = [$yaml, $expected, \false]; + $yaml = <<<'EOF' +bar + +'foo' +EOF; + $expected = "bar\n'foo'"; + $tests[] = [$yaml, $expected, \false]; + $yaml = <<<'EOF' +bar + +foo' +EOF; + $expected = "bar\nfoo'"; + $tests[] = [$yaml, $expected, \false]; + return $tests; + } + public function testTaggedInlineMapping() + { + $this->assertEquals(new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('foo', ['foo' => 'bar']), $this->parser->parse('!foo {foo: bar}', \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS)); + } + /** + * @dataProvider taggedValuesProvider + */ + public function testCustomTagSupport($expected, $yaml) + { + $this->assertEquals($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS)); + } + public function taggedValuesProvider() + { + return ['sequences' => [[new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('foo', ['yaml']), new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('quz', ['bar'])], << [new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('foo', ['foo' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('quz', ['bar']), 'quz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('foo', ['quz' => 'bar'])]), << [[new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('foo', ['foo', 'bar']), new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('quz', ['foo' => 'bar', 'quz' => new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tag\TaggedValue('bar', ['one' => 'bar'])])], <<expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('Tags support is not enabled. Enable the `Yaml::PARSE_CUSTOM_TAGS` flag to use "!iterator" at line 1 (near "!iterator [foo]").'); + $this->parser->parse('!iterator [foo]'); + } + /** + * @group legacy + * @expectedDeprecation Using the unquoted scalar value "!iterator foo" is deprecated since Symfony 3.3 and will be considered as a tagged value in 4.0. You must quote it on line 1. + */ + public function testUnsupportedTagWithScalar() + { + $this->assertEquals('!iterator foo', $this->parser->parse('!iterator foo')); + } + public function testExceptionWhenUsingUnsupportedBuiltInTags() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('The built-in tag "!!foo" is not implemented at line 1 (near "!!foo").'); + $this->parser->parse('!!foo'); + } + /** + * @group legacy + * @expectedDeprecation Starting an unquoted string with a question mark followed by a space is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0 on line 1. + */ + public function testComplexMappingThrowsParseException() + { + $yaml = <<parser->parse($yaml); + } + /** + * @group legacy + * @expectedDeprecation Starting an unquoted string with a question mark followed by a space is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0 on line 2. + */ + public function testComplexMappingNestedInMappingThrowsParseException() + { + $yaml = <<parser->parse($yaml); + } + /** + * @group legacy + * @expectedDeprecation Starting an unquoted string with a question mark followed by a space is deprecated since Symfony 3.3 and will throw \Symfony\Component\Yaml\Exception\ParseException in 4.0 on line 1. + */ + public function testComplexMappingNestedInSequenceThrowsParseException() + { + $yaml = <<parser->parse($yaml); + } + public function testParsingIniThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('Unable to parse at line 1 (near "[parameters]").'); + $ini = <<parser->parse($ini); + } + private function loadTestsFromFixtureFiles($testsFile) + { + $parser = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); + $tests = []; + $files = $parser->parseFile(__DIR__ . '/Fixtures/' . $testsFile); + foreach ($files as $file) { + $yamls = \file_get_contents(__DIR__ . '/Fixtures/' . $file . '.yml'); + // split YAMLs documents + foreach (\preg_split('/^---( %YAML\\:1\\.0)?/m', $yamls) as $yaml) { + if (!$yaml) { + continue; + } + $test = $parser->parse($yaml); + if (isset($test['todo']) && $test['todo']) { + // TODO + } else { + eval('$expected = ' . \trim($test['php']) . ';'); + $tests[] = [\var_export($expected, \true), $test['yaml'], $test['test'], isset($test['deprecated']) ? $test['deprecated'] : \false]; + } + } + } + return $tests; + } + public function testCanParseVeryLongValue() + { + $longStringWithSpaces = \str_repeat('xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx ', 20000); + $trickyVal = ['x' => $longStringWithSpaces]; + $yamlString = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::dump($trickyVal); + $arrayFromYaml = $this->parser->parse($yamlString); + $this->assertEquals($trickyVal, $arrayFromYaml); + } + public function testParserCleansUpReferencesBetweenRuns() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('Reference "foo" does not exist at line 2'); + $yaml = <<parser->parse($yaml); + $yaml = <<parser->parse($yaml); + } + public function testPhpConstantTagMappingKey() + { + $yaml = << ['foo' => ['from' => ['bar'], 'to' => 'baz']]]; + $this->assertSame($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT)); + } + /** + * @group legacy + * @expectedDeprecation The !php/const: tag to indicate dumped PHP constants is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/const (without the colon) tag instead on line 2. + * @expectedDeprecation The !php/const: tag to indicate dumped PHP constants is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/const (without the colon) tag instead on line 4. + * @expectedDeprecation The !php/const: tag to indicate dumped PHP constants is deprecated since Symfony 3.4 and will be removed in 4.0. Use the !php/const (without the colon) tag instead on line 5. + */ + public function testDeprecatedPhpConstantTagMappingKey() + { + $yaml = << ['foo' => ['from' => ['bar'], 'to' => 'baz']]]; + $this->assertSame($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT)); + } + /** + * @group legacy + * @expectedDeprecation Using the Yaml::PARSE_KEYS_AS_STRINGS flag is deprecated since Symfony 3.4 as it will be removed in 4.0. Quote your keys when they are evaluable instead. + */ + public function testPhpConstantTagMappingKeyWithKeysCastToStrings() + { + $yaml = << ['foo' => ['from' => ['bar'], 'to' => 'baz']]]; + $this->assertSame($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CONSTANT | \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_KEYS_AS_STRINGS)); + } + public function testMergeKeysWhenMappingsAreParsedAsObjects() + { + $yaml = << (object) ['bar' => 1], 'bar' => (object) ['baz' => 2, 'bar' => 1], 'baz' => (object) ['baz_foo' => 3, 'baz_bar' => 4], 'foobar' => (object) ['bar' => null, 'baz' => 2]]; + $this->assertEquals($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP)); + } + public function testFilenamesAreParsedAsStringsWithoutFlag() + { + $file = __DIR__ . '/Fixtures/index.yml'; + $this->assertSame($file, $this->parser->parse($file)); + } + public function testParseFile() + { + $this->assertIsArray($this->parser->parseFile(__DIR__ . '/Fixtures/index.yml')); + } + public function testParsingNonExistentFilesThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessageRegExp('#^File ".+/Fixtures/nonexistent.yml" does not exist\\.$#'); + $this->parser->parseFile(__DIR__ . '/Fixtures/nonexistent.yml'); + } + public function testParsingNotReadableFilesThrowsException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessageRegExp('#^File ".+/Fixtures/not_readable.yml" cannot be read\\.$#'); + if ('\\' === \DIRECTORY_SEPARATOR) { + $this->markTestSkipped('chmod is not supported on Windows'); + } + if (!\getenv('USER') || 'root' === \getenv('USER')) { + $this->markTestSkipped('This test will fail if run under superuser'); + } + $file = __DIR__ . '/Fixtures/not_readable.yml'; + \chmod($file, 0200); + $this->parser->parseFile($file); + } + public function testParseReferencesOnMergeKeys() + { + $yaml = << ['a' => 'foo', 'b' => 'bar', 'c' => 'baz'], 'mergekeyderef' => ['d' => 'quux', 'b' => 'bar', 'c' => 'baz']]; + $this->assertSame($expected, $this->parser->parse($yaml)); + } + public function testParseReferencesOnMergeKeysWithMappingsParsedAsObjects() + { + $yaml = << (object) ['a' => 'foo', 'b' => 'bar', 'c' => 'baz'], 'mergekeyderef' => (object) ['d' => 'quux', 'b' => 'bar', 'c' => 'baz']]; + $this->assertEquals($expected, $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_OBJECT_FOR_MAP)); + } + public function testEvalRefException() + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('Reference "foo" does not exist'); + $yaml = <<parser->parse($yaml); + } + /** + * @dataProvider circularReferenceProvider + */ + public function testDetectCircularReferences($yaml) + { + $this->expectException('_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\Exception\\ParseException'); + $this->expectExceptionMessage('Circular reference [foo, bar, foo] detected'); + $this->parser->parse($yaml, \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::PARSE_CUSTOM_TAGS); + } + public function circularReferenceProvider() + { + $tests = []; + $yaml = <<assertSame($expected, $this->parser->parse($yaml)); + } + public function indentedMappingData() + { + $tests = []; + $yaml = << [['bar' => 'foobar', 'baz' => 'foobaz']]]; + $tests['comment line is first line in indented block'] = [$yaml, $expected]; + $yaml = << [['bar' => ['baz' => [1, 2, 3]]]]]; + $tests['mapping value on new line starting with a comment line'] = [$yaml, $expected]; + $yaml = << [['bar' => 'foobar']]]; + $tests['mapping in sequence starting on a new line'] = [$yaml, $expected]; + $yaml = << ['bar' => 'baz']]; + $tests['blank line at the beginning of an indented mapping value'] = [$yaml, $expected]; + return $tests; + } + public function testMultiLineComment() + { + $yaml = <<assertSame(['parameters' => 'abc'], $this->parser->parse($yaml)); + } + public function testParseValueWithModifiers() + { + $yaml = <<assertSame(['parameters' => ['abc' => \implode("\n", ['one', 'two', 'three', 'four', 'five'])]], $this->parser->parse($yaml)); + } + public function testParseValueWithNegativeModifiers() + { + $yaml = <<assertSame(['parameters' => ['abc' => \implode("\n", ['one', 'two', 'three', 'four', 'five'])]], $this->parser->parse($yaml)); + } +} +class B +{ + public $b = 'foo'; + const FOO = 'foo'; + const BAR = 'bar'; + const BAZ = 'baz'; +} diff --git a/vendor/symfony/yaml/Tests/YamlTest.php b/vendor/symfony/yaml/Tests/YamlTest.php index 47d2bd11b..5668bd4b7 100644 --- a/vendor/symfony/yaml/Tests/YamlTest.php +++ b/vendor/symfony/yaml/Tests/YamlTest.php @@ -1,36 +1,36 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests; - -use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; -class YamlTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase -{ - public function testParseAndDump() - { - $data = ['lorem' => 'ipsum', 'dolor' => 'sit']; - $yml = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::dump($data); - $parsed = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($yml); - $this->assertEquals($data, $parsed); - } - public function testZeroIndentationThrowsException() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('The indentation must be greater than zero'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::dump(['lorem' => 'ipsum', 'dolor' => 'sit'], 2, 0); - } - public function testNegativeIndentationThrowsException() - { - $this->expectException('InvalidArgumentException'); - $this->expectExceptionMessage('The indentation must be greater than zero'); - \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::dump(['lorem' => 'ipsum', 'dolor' => 'sit'], 2, -4); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Tests; + +use _PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase; +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml; +class YamlTest extends \_PhpScoper5ea00cc67502b\PHPUnit\Framework\TestCase +{ + public function testParseAndDump() + { + $data = ['lorem' => 'ipsum', 'dolor' => 'sit']; + $yml = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::dump($data); + $parsed = \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::parse($yml); + $this->assertEquals($data, $parsed); + } + public function testZeroIndentationThrowsException() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('The indentation must be greater than zero'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::dump(['lorem' => 'ipsum', 'dolor' => 'sit'], 2, 0); + } + public function testNegativeIndentationThrowsException() + { + $this->expectException('InvalidArgumentException'); + $this->expectExceptionMessage('The indentation must be greater than zero'); + \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Yaml::dump(['lorem' => 'ipsum', 'dolor' => 'sit'], 2, -4); + } +} diff --git a/vendor/symfony/yaml/Tests/index.php b/vendor/symfony/yaml/Tests/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/yaml/Tests/index.php +++ b/vendor/symfony/yaml/Tests/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/Unescaper.php b/vendor/symfony/yaml/Unescaper.php index abab3d800..efb3eb047 100644 --- a/vendor/symfony/yaml/Unescaper.php +++ b/vendor/symfony/yaml/Unescaper.php @@ -1,134 +1,134 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; -/** - * Unescaper encapsulates unescaping rules for single and double-quoted - * YAML strings. - * - * @author Matthew Lewinski - * - * @internal - */ -class Unescaper -{ - /** - * Regex fragment that matches an escaped character in a double quoted string. - */ - const REGEX_ESCAPED_CHARACTER = '\\\\(x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|U[0-9a-fA-F]{8}|.)'; - /** - * Unescapes a single quoted string. - * - * @param string $value A single quoted string - * - * @return string The unescaped string - */ - public function unescapeSingleQuotedString($value) - { - return \str_replace('\'\'', '\'', $value); - } - /** - * Unescapes a double quoted string. - * - * @param string $value A double quoted string - * - * @return string The unescaped string - */ - public function unescapeDoubleQuotedString($value) - { - $callback = function ($match) { - return $this->unescapeCharacter($match[0]); - }; - // evaluate the string - return \preg_replace_callback('/' . self::REGEX_ESCAPED_CHARACTER . '/u', $callback, $value); - } - /** - * Unescapes a character that was found in a double-quoted string. - * - * @param string $value An escaped character - * - * @return string The unescaped character - */ - private function unescapeCharacter($value) - { - switch ($value[1]) { - case '0': - return "\0"; - case 'a': - return "\7"; - case 'b': - return "\10"; - case 't': - return "\t"; - case "\t": - return "\t"; - case 'n': - return "\n"; - case 'v': - return "\v"; - case 'f': - return "\f"; - case 'r': - return "\r"; - case 'e': - return "\33"; - case ' ': - return ' '; - case '"': - return '"'; - case '/': - return '/'; - case '\\': - return '\\'; - case 'N': - // U+0085 NEXT LINE - return "…"; - case '_': - // U+00A0 NO-BREAK SPACE - return " "; - case 'L': - // U+2028 LINE SEPARATOR - return "
"; - case 'P': - // U+2029 PARAGRAPH SEPARATOR - return "
"; - case 'x': - return self::utf8chr(\hexdec(\substr($value, 2, 2))); - case 'u': - return self::utf8chr(\hexdec(\substr($value, 2, 4))); - case 'U': - return self::utf8chr(\hexdec(\substr($value, 2, 8))); - default: - throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Found unknown escape character "%s".', $value)); - } - } - /** - * Get the UTF-8 character for the given code point. - * - * @param int $c The unicode code point - * - * @return string The corresponding UTF-8 character - */ - private static function utf8chr($c) - { - if (0x80 > ($c %= 0x200000)) { - return \chr($c); - } - if (0x800 > $c) { - return \chr(0xc0 | $c >> 6) . \chr(0x80 | $c & 0x3f); - } - if (0x10000 > $c) { - return \chr(0xe0 | $c >> 12) . \chr(0x80 | $c >> 6 & 0x3f) . \chr(0x80 | $c & 0x3f); - } - return \chr(0xf0 | $c >> 18) . \chr(0x80 | $c >> 12 & 0x3f) . \chr(0x80 | $c >> 6 & 0x3f) . \chr(0x80 | $c & 0x3f); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; +/** + * Unescaper encapsulates unescaping rules for single and double-quoted + * YAML strings. + * + * @author Matthew Lewinski + * + * @internal + */ +class Unescaper +{ + /** + * Regex fragment that matches an escaped character in a double quoted string. + */ + const REGEX_ESCAPED_CHARACTER = '\\\\(x[0-9a-fA-F]{2}|u[0-9a-fA-F]{4}|U[0-9a-fA-F]{8}|.)'; + /** + * Unescapes a single quoted string. + * + * @param string $value A single quoted string + * + * @return string The unescaped string + */ + public function unescapeSingleQuotedString($value) + { + return \str_replace('\'\'', '\'', $value); + } + /** + * Unescapes a double quoted string. + * + * @param string $value A double quoted string + * + * @return string The unescaped string + */ + public function unescapeDoubleQuotedString($value) + { + $callback = function ($match) { + return $this->unescapeCharacter($match[0]); + }; + // evaluate the string + return \preg_replace_callback('/' . self::REGEX_ESCAPED_CHARACTER . '/u', $callback, $value); + } + /** + * Unescapes a character that was found in a double-quoted string. + * + * @param string $value An escaped character + * + * @return string The unescaped character + */ + private function unescapeCharacter($value) + { + switch ($value[1]) { + case '0': + return "\0"; + case 'a': + return "\7"; + case 'b': + return "\10"; + case 't': + return "\t"; + case "\t": + return "\t"; + case 'n': + return "\n"; + case 'v': + return "\v"; + case 'f': + return "\f"; + case 'r': + return "\r"; + case 'e': + return "\33"; + case ' ': + return ' '; + case '"': + return '"'; + case '/': + return '/'; + case '\\': + return '\\'; + case 'N': + // U+0085 NEXT LINE + return "…"; + case '_': + // U+00A0 NO-BREAK SPACE + return " "; + case 'L': + // U+2028 LINE SEPARATOR + return "
"; + case 'P': + // U+2029 PARAGRAPH SEPARATOR + return "
"; + case 'x': + return self::utf8chr(\hexdec(\substr($value, 2, 2))); + case 'u': + return self::utf8chr(\hexdec(\substr($value, 2, 4))); + case 'U': + return self::utf8chr(\hexdec(\substr($value, 2, 8))); + default: + throw new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException(\sprintf('Found unknown escape character "%s".', $value)); + } + } + /** + * Get the UTF-8 character for the given code point. + * + * @param int $c The unicode code point + * + * @return string The corresponding UTF-8 character + */ + private static function utf8chr($c) + { + if (0x80 > ($c %= 0x200000)) { + return \chr($c); + } + if (0x800 > $c) { + return \chr(0xc0 | $c >> 6) . \chr(0x80 | $c & 0x3f); + } + if (0x10000 > $c) { + return \chr(0xe0 | $c >> 12) . \chr(0x80 | $c >> 6 & 0x3f) . \chr(0x80 | $c & 0x3f); + } + return \chr(0xf0 | $c >> 18) . \chr(0x80 | $c >> 12 & 0x3f) . \chr(0x80 | $c >> 6 & 0x3f) . \chr(0x80 | $c & 0x3f); + } +} diff --git a/vendor/symfony/yaml/Yaml.php b/vendor/symfony/yaml/Yaml.php index 8c8aa0202..2d3d50a79 100644 --- a/vendor/symfony/yaml/Yaml.php +++ b/vendor/symfony/yaml/Yaml.php @@ -1,131 +1,131 @@ - - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ -namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; - -use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; -/** - * Yaml offers convenience methods to load and dump YAML. - * - * @author Fabien Potencier - * - * @final since version 3.4 - */ -class Yaml -{ - const DUMP_OBJECT = 1; - const PARSE_EXCEPTION_ON_INVALID_TYPE = 2; - const PARSE_OBJECT = 4; - const PARSE_OBJECT_FOR_MAP = 8; - const DUMP_EXCEPTION_ON_INVALID_TYPE = 16; - const PARSE_DATETIME = 32; - const DUMP_OBJECT_AS_MAP = 64; - const DUMP_MULTI_LINE_LITERAL_BLOCK = 128; - const PARSE_CONSTANT = 256; - const PARSE_CUSTOM_TAGS = 512; - const DUMP_EMPTY_ARRAY_AS_SEQUENCE = 1024; - /** - * @deprecated since version 3.4, to be removed in 4.0. Quote your evaluable keys instead. - */ - const PARSE_KEYS_AS_STRINGS = 2048; - /** - * Parses a YAML file into a PHP value. - * - * Usage: - * - * $array = Yaml::parseFile('config.yml'); - * print_r($array); - * - * @param string $filename The path to the YAML file to be parsed - * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior - * - * @return mixed The YAML converted to a PHP value - * - * @throws ParseException If the file could not be read or the YAML is not valid - */ - public static function parseFile($filename, $flags = 0) - { - $yaml = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); - return $yaml->parseFile($filename, $flags); - } - /** - * Parses YAML into a PHP value. - * - * Usage: - * - * $array = Yaml::parse(file_get_contents('config.yml')); - * print_r($array); - * - * - * @param string $input A string containing YAML - * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior - * - * @return mixed The YAML converted to a PHP value - * - * @throws ParseException If the YAML is not valid - */ - public static function parse($input, $flags = 0) - { - if (\is_bool($flags)) { - @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the PARSE_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); - if ($flags) { - $flags = self::PARSE_EXCEPTION_ON_INVALID_TYPE; - } else { - $flags = 0; - } - } - if (\func_num_args() >= 3) { - @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the PARSE_OBJECT flag instead.', \E_USER_DEPRECATED); - if (\func_get_arg(2)) { - $flags |= self::PARSE_OBJECT; - } - } - if (\func_num_args() >= 4) { - @\trigger_error('Passing a boolean flag to toggle object for map support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_OBJECT_FOR_MAP flag instead.', \E_USER_DEPRECATED); - if (\func_get_arg(3)) { - $flags |= self::PARSE_OBJECT_FOR_MAP; - } - } - $yaml = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); - return $yaml->parse($input, $flags); - } - /** - * Dumps a PHP value to a YAML string. - * - * The dump method, when supplied with an array, will do its best - * to convert the array into friendly YAML. - * - * @param mixed $input The PHP value - * @param int $inline The level where you switch to inline YAML - * @param int $indent The amount of spaces to use for indentation of nested nodes - * @param int $flags A bit field of DUMP_* constants to customize the dumped YAML string - * - * @return string A YAML string representing the original PHP value - */ - public static function dump($input, $inline = 2, $indent = 4, $flags = 0) - { - if (\is_bool($flags)) { - @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the DUMP_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); - if ($flags) { - $flags = self::DUMP_EXCEPTION_ON_INVALID_TYPE; - } else { - $flags = 0; - } - } - if (\func_num_args() >= 5) { - @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the DUMP_OBJECT flag instead.', \E_USER_DEPRECATED); - if (\func_get_arg(4)) { - $flags |= self::DUMP_OBJECT; - } - } - $yaml = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper($indent); - return $yaml->dump($input, $inline, 0, $flags); - } -} + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ +namespace _PhpScoper5ea00cc67502b\Symfony\Component\Yaml; + +use _PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Exception\ParseException; +/** + * Yaml offers convenience methods to load and dump YAML. + * + * @author Fabien Potencier + * + * @final since version 3.4 + */ +class Yaml +{ + const DUMP_OBJECT = 1; + const PARSE_EXCEPTION_ON_INVALID_TYPE = 2; + const PARSE_OBJECT = 4; + const PARSE_OBJECT_FOR_MAP = 8; + const DUMP_EXCEPTION_ON_INVALID_TYPE = 16; + const PARSE_DATETIME = 32; + const DUMP_OBJECT_AS_MAP = 64; + const DUMP_MULTI_LINE_LITERAL_BLOCK = 128; + const PARSE_CONSTANT = 256; + const PARSE_CUSTOM_TAGS = 512; + const DUMP_EMPTY_ARRAY_AS_SEQUENCE = 1024; + /** + * @deprecated since version 3.4, to be removed in 4.0. Quote your evaluable keys instead. + */ + const PARSE_KEYS_AS_STRINGS = 2048; + /** + * Parses a YAML file into a PHP value. + * + * Usage: + * + * $array = Yaml::parseFile('config.yml'); + * print_r($array); + * + * @param string $filename The path to the YAML file to be parsed + * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior + * + * @return mixed The YAML converted to a PHP value + * + * @throws ParseException If the file could not be read or the YAML is not valid + */ + public static function parseFile($filename, $flags = 0) + { + $yaml = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); + return $yaml->parseFile($filename, $flags); + } + /** + * Parses YAML into a PHP value. + * + * Usage: + * + * $array = Yaml::parse(file_get_contents('config.yml')); + * print_r($array); + * + * + * @param string $input A string containing YAML + * @param int $flags A bit field of PARSE_* constants to customize the YAML parser behavior + * + * @return mixed The YAML converted to a PHP value + * + * @throws ParseException If the YAML is not valid + */ + public static function parse($input, $flags = 0) + { + if (\is_bool($flags)) { + @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the PARSE_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); + if ($flags) { + $flags = self::PARSE_EXCEPTION_ON_INVALID_TYPE; + } else { + $flags = 0; + } + } + if (\func_num_args() >= 3) { + @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the PARSE_OBJECT flag instead.', \E_USER_DEPRECATED); + if (\func_get_arg(2)) { + $flags |= self::PARSE_OBJECT; + } + } + if (\func_num_args() >= 4) { + @\trigger_error('Passing a boolean flag to toggle object for map support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the Yaml::PARSE_OBJECT_FOR_MAP flag instead.', \E_USER_DEPRECATED); + if (\func_get_arg(3)) { + $flags |= self::PARSE_OBJECT_FOR_MAP; + } + } + $yaml = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Parser(); + return $yaml->parse($input, $flags); + } + /** + * Dumps a PHP value to a YAML string. + * + * The dump method, when supplied with an array, will do its best + * to convert the array into friendly YAML. + * + * @param mixed $input The PHP value + * @param int $inline The level where you switch to inline YAML + * @param int $indent The amount of spaces to use for indentation of nested nodes + * @param int $flags A bit field of DUMP_* constants to customize the dumped YAML string + * + * @return string A YAML string representing the original PHP value + */ + public static function dump($input, $inline = 2, $indent = 4, $flags = 0) + { + if (\is_bool($flags)) { + @\trigger_error('Passing a boolean flag to toggle exception handling is deprecated since Symfony 3.1 and will be removed in 4.0. Use the DUMP_EXCEPTION_ON_INVALID_TYPE flag instead.', \E_USER_DEPRECATED); + if ($flags) { + $flags = self::DUMP_EXCEPTION_ON_INVALID_TYPE; + } else { + $flags = 0; + } + } + if (\func_num_args() >= 5) { + @\trigger_error('Passing a boolean flag to toggle object support is deprecated since Symfony 3.1 and will be removed in 4.0. Use the DUMP_OBJECT flag instead.', \E_USER_DEPRECATED); + if (\func_get_arg(4)) { + $flags |= self::DUMP_OBJECT; + } + } + $yaml = new \_PhpScoper5ea00cc67502b\Symfony\Component\Yaml\Dumper($indent); + return $yaml->dump($input, $inline, 0, $flags); + } +} diff --git a/vendor/symfony/yaml/composer.json b/vendor/symfony/yaml/composer.json index 127989915..1e121e730 100644 --- a/vendor/symfony/yaml/composer.json +++ b/vendor/symfony/yaml/composer.json @@ -1,45 +1,45 @@ -{ - "name": "symfony\/yaml", - "type": "library", - "description": "Symfony Yaml Component", - "keywords": [], - "homepage": "https:\/\/symfony.com", - "license": "MIT", - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https:\/\/symfony.com\/contributors" - } - ], - "require": { - "php": "^5.5.9|>=7.0.8", - "symfony\/polyfill-ctype": "~1.8" - }, - "require-dev": { - "symfony\/console": "~3.4|~4.0" - }, - "conflict": { - "symfony\/console": "<3.4" - }, - "suggest": { - "symfony\/console": "For validating YAML files using the lint command" - }, - "autoload": { - "psr-4": { - "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\": "" - }, - "exclude-from-classmap": [ - "\/Tests\/" - ] - }, - "minimum-stability": "dev", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - } +{ + "name": "symfony\/yaml", + "type": "library", + "description": "Symfony Yaml Component", + "keywords": [], + "homepage": "https:\/\/symfony.com", + "license": "MIT", + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https:\/\/symfony.com\/contributors" + } + ], + "require": { + "php": "^5.5.9|>=7.0.8", + "symfony\/polyfill-ctype": "~1.8" + }, + "require-dev": { + "symfony\/console": "~3.4|~4.0" + }, + "conflict": { + "symfony\/console": "<3.4" + }, + "suggest": { + "symfony\/console": "For validating YAML files using the lint command" + }, + "autoload": { + "psr-4": { + "_PhpScoper5ea00cc67502b\\Symfony\\Component\\Yaml\\": "" + }, + "exclude-from-classmap": [ + "\/Tests\/" + ] + }, + "minimum-stability": "dev", + "extra": { + "branch-alias": { + "dev-master": "3.4-dev" + } + } } \ No newline at end of file diff --git a/vendor/symfony/yaml/index.php b/vendor/symfony/yaml/index.php index 97775fe0f..d4a3735f7 100644 --- a/vendor/symfony/yaml/index.php +++ b/vendor/symfony/yaml/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/vendor/symfony/yaml/phpunit.xml.dist b/vendor/symfony/yaml/phpunit.xml.dist index b5d4d914f..432d67d4f 100644 --- a/vendor/symfony/yaml/phpunit.xml.dist +++ b/vendor/symfony/yaml/phpunit.xml.dist @@ -1,30 +1,30 @@ - - - - - - - - - - ./Tests/ - - - - - - ./ - - ./Tests - ./vendor - - - - + + + + + + + + + + ./Tests/ + + + + + + ./ + + ./Tests + ./vendor + + + + diff --git a/views/css/front.css b/views/css/front.css index f81d5e3bb..7677ea08c 100644 --- a/views/css/front.css +++ b/views/css/front.css @@ -1,168 +1,168 @@ -.mollie-reset-this * { - animation: none; - animation-delay: 0s; - animation-direction: normal; - animation-duration: 0s; - animation-fill-mode: none; - animation-iteration-count: 1; - animation-name: none; - animation-play-state: running; - animation-timing-function: ease; - backface-visibility: visible; - background-clip: border-box; - background-origin: padding-box; - background-position-x: 0; - background-position-y: 0; - background: transparent none repeat scroll 0 0; - background-size: auto auto; - border-collapse: separate; - border-image: none; - border-spacing: 0; - border-radius: 0; - border: medium none inherit; - bottom: auto; - box-shadow: none; - box-sizing: content-box; - caption-side: top; - clear: none; - clip: auto; - color: inherit; - columns: auto; - column-count: auto; - column-fill: balance; - column-gap: normal; - column-rule: medium none currentColor; - column-rule-color: currentColor; - column-rule-style: none; - column-rule-width: unset; - column-span: 1; - column-width: auto; - content: normal; - counter-increment: none; - counter-reset: none; - cursor: auto; - direction: ltr; - display: block; - empty-cells: show; - float: none; - font-weight: normal; - font-variant: normal; - font-style: normal; - font-size: medium; - height: auto; - hyphens: none; - left: auto; - letter-spacing: normal; - line-height: normal; - list-style: disc outside none; - margin: 0; - max-height: none; - max-width: none; - min-height: 0; - min-width: 0; - opacity: 1; - orphans: 0; - outline: none; - overflow: visible; - padding: 0; - page-break-after: auto; - page-break-before: auto; - page-break-inside: auto; - perspective: none; - perspective-origin: 50% 50%; - position: static; - quotes: "\201C" "\201D" "\2018" "\2019"; - right: auto; - tab-size: 8; - table-layout: auto; - text-align: inherit; - text-align-last: auto; - text-decoration: none; - text-decoration-color: inherit; - text-decoration-style: solid; - text-indent: 0; - text-shadow: none; - text-transform: none; - top: auto; - transform: none; - transform-style: flat; - transition: none; - transition-delay: 0s; - transition-duration: 0s; - transition-property: none; - transition-timing-function: ease; - unicode-bidi: normal; - vertical-align: baseline; - visibility: visible; - white-space: normal; - widows: 0; - width: auto; - word-spacing: normal; - word-break: break-word; - z-index: auto; -} - -.mollie-reset-this script, .mollie-reset-this style { - display: none; -} - -.mollie-title { - font-size: 16px; - font-weight: 700; -} - -.mollie_btn_primary { - font-size: 16px!important; - color: white!important; - background-color: #2fb5d2; - max-width: 200px; - margin: 0 auto; - text-decoration: none!important; - font-weight: 700!important; - padding: 5px; -} - -.mollie_btn_primary:hover { - background-color: #2592a9!important; - cursor: pointer; -} - -.mollie_text_center { - text-align: center; -} - -.mollie_button { - box-shadow: 2px 2px 4px 0 rgba(0, 0, 0, .2); - text-transform: uppercase; - width: 150px; - display: inline-block; - font-weight: 400; - line-height: 1.25; - text-align: center; - white-space: nowrap; - margin: 2px; - vertical-align: middle; - cursor: pointer; - -webkit-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; - padding: .5rem 1rem; - font-size: 1rem; - border-radius: 0; - border: 2px solid #fff; - background: border-box; -} - -.mollie_button:hover { - cursor: pointer; - box-shadow: 2px 2px 4px 0 rgba(0, 0, 0, .6); -} - -.mollie_button > img { - margin: 0 auto; -} - -.mollie_button * { - cursor: pointer; -} +.mollie-reset-this * { + animation: none; + animation-delay: 0s; + animation-direction: normal; + animation-duration: 0s; + animation-fill-mode: none; + animation-iteration-count: 1; + animation-name: none; + animation-play-state: running; + animation-timing-function: ease; + backface-visibility: visible; + background-clip: border-box; + background-origin: padding-box; + background-position-x: 0; + background-position-y: 0; + background: transparent none repeat scroll 0 0; + background-size: auto auto; + border-collapse: separate; + border-image: none; + border-spacing: 0; + border-radius: 0; + border: medium none inherit; + bottom: auto; + box-shadow: none; + box-sizing: content-box; + caption-side: top; + clear: none; + clip: auto; + color: inherit; + columns: auto; + column-count: auto; + column-fill: balance; + column-gap: normal; + column-rule: medium none currentColor; + column-rule-color: currentColor; + column-rule-style: none; + column-rule-width: unset; + column-span: 1; + column-width: auto; + content: normal; + counter-increment: none; + counter-reset: none; + cursor: auto; + direction: ltr; + display: block; + empty-cells: show; + float: none; + font-weight: normal; + font-variant: normal; + font-style: normal; + font-size: medium; + height: auto; + hyphens: none; + left: auto; + letter-spacing: normal; + line-height: normal; + list-style: disc outside none; + margin: 0; + max-height: none; + max-width: none; + min-height: 0; + min-width: 0; + opacity: 1; + orphans: 0; + outline: none; + overflow: visible; + padding: 0; + page-break-after: auto; + page-break-before: auto; + page-break-inside: auto; + perspective: none; + perspective-origin: 50% 50%; + position: static; + quotes: "\201C" "\201D" "\2018" "\2019"; + right: auto; + tab-size: 8; + table-layout: auto; + text-align: inherit; + text-align-last: auto; + text-decoration: none; + text-decoration-color: inherit; + text-decoration-style: solid; + text-indent: 0; + text-shadow: none; + text-transform: none; + top: auto; + transform: none; + transform-style: flat; + transition: none; + transition-delay: 0s; + transition-duration: 0s; + transition-property: none; + transition-timing-function: ease; + unicode-bidi: normal; + vertical-align: baseline; + visibility: visible; + white-space: normal; + widows: 0; + width: auto; + word-spacing: normal; + word-break: break-word; + z-index: auto; +} + +.mollie-reset-this script, .mollie-reset-this style { + display: none; +} + +.mollie-title { + font-size: 16px; + font-weight: 700; +} + +.mollie_btn_primary { + font-size: 16px!important; + color: white!important; + background-color: #2fb5d2; + max-width: 200px; + margin: 0 auto; + text-decoration: none!important; + font-weight: 700!important; + padding: 5px; +} + +.mollie_btn_primary:hover { + background-color: #2592a9!important; + cursor: pointer; +} + +.mollie_text_center { + text-align: center; +} + +.mollie_button { + box-shadow: 2px 2px 4px 0 rgba(0, 0, 0, .2); + text-transform: uppercase; + width: 150px; + display: inline-block; + font-weight: 400; + line-height: 1.25; + text-align: center; + white-space: nowrap; + margin: 2px; + vertical-align: middle; + cursor: pointer; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + padding: .5rem 1rem; + font-size: 1rem; + border-radius: 0; + border: 2px solid #fff; + background: border-box; +} + +.mollie_button:hover { + cursor: pointer; + box-shadow: 2px 2px 4px 0 rgba(0, 0, 0, .6); +} + +.mollie_button > img { + margin: 0 auto; +} + +.mollie_button * { + cursor: pointer; +} diff --git a/views/css/index.php b/views/css/index.php index 729abf520..a950d02f4 100644 --- a/views/css/index.php +++ b/views/css/index.php @@ -1,11 +1,11 @@ - - - - - - image/svg+xml - - icon-32x32-cartasi - - - - - - icon-32x32-cartasi - Created with Sketch. - - - - - - - - - - + + + + + + image/svg+xml + + icon-32x32-cartasi + + + + + + icon-32x32-cartasi + Created with Sketch. + + + + + + + + + + diff --git a/views/img/cartesbancaires.svg b/views/img/cartesbancaires.svg index 6215ec8fe..9f26c36a3 100644 --- a/views/img/cartesbancaires.svg +++ b/views/img/cartesbancaires.svg @@ -1,119 +1,119 @@ - - - - - - image/svg+xml - - icon-32x32-cartebancare - - - - - - icon-32x32-cartebancare - Created with Sketch. - - - - - - - - - - - - - - - - - - - - - - + + + + + + image/svg+xml + + icon-32x32-cartebancare + + + + + + icon-32x32-cartebancare + Created with Sketch. + + + + + + + + + + + + + + + + + + + + + + diff --git a/views/img/index.php b/views/img/index.php index 729abf520..a950d02f4 100644 --- a/views/img/index.php +++ b/views/img/index.php @@ -1,11 +1,11 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ - -header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); -header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); - -header('Cache-Control: no-store, no-cache, must-revalidate'); -header('Cache-Control: post-check=0, pre-check=0', false); -header('Pragma: no-cache'); - -header('Location: ../'); -exit; + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ + +header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); +header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT'); + +header('Cache-Control: no-store, no-cache, must-revalidate'); +header('Cache-Control: post-check=0, pre-check=0', false); +header('Pragma: no-cache'); + +header('Location: ../'); +exit; diff --git a/views/js/.babelrc b/views/js/.babelrc index f10cfd9ac..dcba0494a 100644 --- a/views/js/.babelrc +++ b/views/js/.babelrc @@ -1,22 +1,22 @@ -{ - "plugins": [ - "@babel/plugin-syntax-dynamic-import", - [ - "module-resolver", - { - "root": [ - "." - ], - "alias": { - "@carrierconfig": "./src/back/carrierconfig", - "@methodconfig": "./src/back/methodconfig", - "@transaction": "./src/back/transaction", - "@updater": "./src/back/updater", - "@banks": "./src/front/banks", - "@qrcode": "./src/front/qrcode", - "@shared": "./src/shared" - } - } - ] - ] -} +{ + "plugins": [ + "@babel/plugin-syntax-dynamic-import", + [ + "module-resolver", + { + "root": [ + "." + ], + "alias": { + "@carrierconfig": "./src/back/carrierconfig", + "@methodconfig": "./src/back/methodconfig", + "@transaction": "./src/back/transaction", + "@updater": "./src/back/updater", + "@banks": "./src/front/banks", + "@qrcode": "./src/front/qrcode", + "@shared": "./src/shared" + } + } + ] + ] +} diff --git a/views/js/.eslintrc b/views/js/.eslintrc index 25d382ba0..481feb6a5 100644 --- a/views/js/.eslintrc +++ b/views/js/.eslintrc @@ -1,56 +1,56 @@ -{ - "extends": [ - "plugin:@typescript-eslint/recommended", - "@mollie/eslint-config-react" - ], - "parser": "@typescript-eslint/parser", - "parserOptions": { - "jsx": true, - "useJSXTextNode": true - }, - "settings": { - "react": { - "version": "detect" - }, - "import/resolver": { - "node": { - "extensions": [ - ".js", - ".jsx", - ".ts", - ".tsx" - ] - } - } - }, - "plugins": [ - "import", - "@typescript-eslint", - "react-hooks" - ], - "rules": { - "@typescript-eslint/interface-name-prefix": [ - "error", - "always" - ], - "@typescript-eslint/indent": [ - "error", - 2 - ], - "@typescript-eslint/array-type": [ - "error", - "generic" - ], - "@typescript-eslint/no-explicit-any": "off", - "react-hooks/rules-of-hooks": "error", - "no-console": "off" - }, - "overrides": [ - { - "files": "*.[jt]s" - }, - { - "files": "*.[jt]sx" - } - ] -} +{ + "extends": [ + "plugin:@typescript-eslint/recommended", + "@mollie/eslint-config-react" + ], + "parser": "@typescript-eslint/parser", + "parserOptions": { + "jsx": true, + "useJSXTextNode": true + }, + "settings": { + "react": { + "version": "detect" + }, + "import/resolver": { + "node": { + "extensions": [ + ".js", + ".jsx", + ".ts", + ".tsx" + ] + } + } + }, + "plugins": [ + "import", + "@typescript-eslint", + "react-hooks" + ], + "rules": { + "@typescript-eslint/interface-name-prefix": [ + "error", + "always" + ], + "@typescript-eslint/indent": [ + "error", + 2 + ], + "@typescript-eslint/array-type": [ + "error", + "generic" + ], + "@typescript-eslint/no-explicit-any": "off", + "react-hooks/rules-of-hooks": "error", + "no-console": "off" + }, + "overrides": [ + { + "files": "*.[jt]s" + }, + { + "files": "*.[jt]sx" + } + ] +} diff --git a/views/js/.gitignore b/views/js/.gitignore index b05624204..ee389b8ee 100644 --- a/views/js/.gitignore +++ b/views/js/.gitignore @@ -1,3 +1,3 @@ -*.css.d.ts -ignoreme/** -node_modules/** +*.css.d.ts +ignoreme/** +node_modules/** diff --git a/views/js/admin/index.php b/views/js/admin/index.php index 97775fe0f..d4a3735f7 100644 --- a/views/js/admin/index.php +++ b/views/js/admin/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/views/js/admin/settings.js b/views/js/admin/settings.js index 98c62e9f4..c81a34ca8 100644 --- a/views/js/admin/settings.js +++ b/views/js/admin/settings.js @@ -1,47 +1,47 @@ -/** - * Copyright (c) 2012-2020, Mollie B.V. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * - Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH - * DAMAGE. - * - * @author Mollie B.V. - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ -$(document).ready(function() { - $('.js-mollie-amount').keypress(function(event) { - if ((event.which != 46 || $(this).val().indexOf('.') != -1) && (event.which < 48 || event.which > 57)) { - event.preventDefault(); - } - }); - $('select[name^="MOLLIE_CARRIER_URL_SOURCE"]').on('change', function () { - var customUrlDisabled = true; - if($(this).val() === 'custom_url') { - customUrlDisabled = false; - } - $(this).closest('tr').find('input').attr('disabled', customUrlDisabled); - }) +/** + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ +$(document).ready(function() { + $('.js-mollie-amount').keypress(function(event) { + if ((event.which != 46 || $(this).val().indexOf('.') != -1) && (event.which < 48 || event.which > 57)) { + event.preventDefault(); + } + }); + $('select[name^="MOLLIE_CARRIER_URL_SOURCE"]').on('change', function () { + var customUrlDisabled = true; + if($(this).val() === 'custom_url') { + customUrlDisabled = false; + } + $(this).closest('tr').find('input').attr('disabled', customUrlDisabled); + }) }); \ No newline at end of file diff --git a/views/js/apple_payment.js b/views/js/apple_payment.js index 4e0acf512..bdaa2cc73 100644 --- a/views/js/apple_payment.js +++ b/views/js/apple_payment.js @@ -1,39 +1,39 @@ -/** - * Copyright (c) 2012-2020, Mollie B.V. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * - Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH - * DAMAGE. - * - * @author Mollie B.V. - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ -$(document).ready(function() { - document.cookie = 'isApplePayMethod = 0'; - if (window.ApplePaySession && window.ApplePaySession.canMakePayments()) { - document.cookie = 'isApplePayMethod = 1'; - } +/** + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ +$(document).ready(function() { + document.cookie = 'isApplePayMethod = 0'; + if (window.ApplePaySession && window.ApplePaySession.canMakePayments()) { + document.cookie = 'isApplePayMethod = 1'; + } }); \ No newline at end of file diff --git a/views/js/dist/0.min.js b/views/js/dist/0.min.js index b9e660989..c03f8cfdb 100644 --- a/views/js/dist/0.min.js +++ b/views/js/dist/0.min.js @@ -1,33 +1,33 @@ -/*! - * Copyright (c) 2012-2020, Mollie B.V. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * - Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH - * DAMAGE. - * - * @author Mollie B.V. - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ (window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([[0],{203:function(e,n,t){"use strict";t.r(n),t.d(n,"default",(function(){return d}));var a=t(56),r=t.n(a),l=t(59),u=t(83),o=Object(a.lazy)((function(){return Promise.all([t.e("vendors~transactionOrder~transactionRefund~updater"),t.e("vendors~transactionOrder~transactionRefund"),t.e("transactionRefund")]).then(t.bind(null,271))})),c=Object(a.lazy)((function(){return Promise.all([t.e("vendors~transactionOrder~transactionRefund~updater"),t.e("vendors~transactionOrder~transactionRefund"),t.e("vendors~transactionOrder"),t.e("transactionOrder")]).then(t.bind(null,270))}));function d(){var e=Object(a.useMemo)((function(){return u.default.getState()}),[]),n=e.payment,t=e.order;return r.a.createElement(l.a.Provider,{value:u.default},r.a.createElement(r.a.Fragment,null,n&&r.a.createElement(a.Suspense,{fallback:null},r.a.createElement(o,null)),t&&r.a.createElement(a.Suspense,{fallback:null},r.a.createElement(c,null))))}}}]); \ No newline at end of file diff --git a/views/js/dist/app.min.js b/views/js/dist/app.min.js index 24eba1e8a..253c3d25a 100644 --- a/views/js/dist/app.min.js +++ b/views/js/dist/app.min.js @@ -1,33 +1,33 @@ -/*! - * Copyright (c) 2012-2020, Mollie B.V. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * - Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH - * DAMAGE. - * - * @author Mollie B.V. - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ var MollieModule="object"==typeof MollieModule?MollieModule:{};MollieModule.app=function(r){function n(n){for(var t,c,s=n[0],u=n[1],d=n[2],f=n[3]||[],p=0,g=[];p - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ (window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["banks","vendors~transactionOrder~transactionRefund~updater","vendors~sweetalert"],{100:function(t,e,n){var r=n(3),o=n(10),i=n(1)("match");t.exports=function(t){var e;return r(t)&&(void 0!==(e=t[i])?!!e:"RegExp"==o(t))}},104:function(t,e,n){var r=n(25),o=n(113)(!1);r(r.S,"Object",{values:function(t){return o(t)}})},105:function(t,e,n){(function(e,n){t.exports=function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};return e.m=t,e.c=n,e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=8)}([function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r="swal-button";e.CLASS_NAMES={MODAL:"swal-modal",OVERLAY:"swal-overlay",SHOW_MODAL:"swal-overlay--show-modal",MODAL_TITLE:"swal-title",MODAL_TEXT:"swal-text",ICON:"swal-icon",ICON_CUSTOM:"swal-icon--custom",CONTENT:"swal-content",FOOTER:"swal-footer",BUTTON_CONTAINER:"swal-button-container",BUTTON:r,CONFIRM_BUTTON:r+"--confirm",CANCEL_BUTTON:r+"--cancel",DANGER_BUTTON:r+"--danger",BUTTON_LOADING:r+"--loading",BUTTON_LOADER:r+"__loader"},e.default=e.CLASS_NAMES},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getNode=function(t){var e="."+t;return document.querySelector(e)},e.stringToNode=function(t){var e=document.createElement("div");return e.innerHTML=t.trim(),e.firstChild},e.insertAfter=function(t,e){var n=e.nextSibling;e.parentNode.insertBefore(t,n)},e.removeNode=function(t){t.parentElement.removeChild(t)},e.throwErr=function(t){throw"SweetAlert: "+(t=t.replace(/ +(?= )/g,"")).trim()},e.isPlainObject=function(t){if("[object Object]"!==Object.prototype.toString.call(t))return!1;var e=Object.getPrototypeOf(t);return null===e||e===Object.prototype},e.ordinalSuffixOf=function(t){var e=t%10,n=t%100;return 1===e&&11!==n?t+"st":2===e&&12!==n?t+"nd":3===e&&13!==n?t+"rd":t+"th"}},function(t,e,n){"use strict";function r(t){for(var n in t)e.hasOwnProperty(n)||(e[n]=t[n])}Object.defineProperty(e,"__esModule",{value:!0}),r(n(25));var o=n(26);e.overlayMarkup=o.default,r(n(27)),r(n(28)),r(n(29));var i=n(0),a=i.default.MODAL_TITLE,s=i.default.MODAL_TEXT,c=i.default.ICON,l=i.default.FOOTER;e.iconMarkup='\n
    ',e.titleMarkup='\n
    \n',e.textMarkup='\n
    ',e.footerMarkup='\n
    \n'},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1);e.CONFIRM_KEY="confirm",e.CANCEL_KEY="cancel";var o={visible:!0,text:null,value:null,className:"",closeModal:!0},i=Object.assign({},o,{visible:!1,text:"Cancel",value:null}),a=Object.assign({},o,{text:"OK",value:!0});e.defaultButtonList={cancel:i,confirm:a};var s=function(t){switch(t){case e.CONFIRM_KEY:return a;case e.CANCEL_KEY:return i;default:var n=t.charAt(0).toUpperCase()+t.slice(1);return Object.assign({},o,{text:n,value:t})}},c=function(t,e){var n=s(t);return!0===e?Object.assign({},n,{visible:!0}):"string"==typeof e?Object.assign({},n,{visible:!0,text:e}):r.isPlainObject(e)?Object.assign({visible:!0},n,e):Object.assign({},n,{visible:!1})},l=function(t){var n={};switch(t.length){case 1:n[e.CANCEL_KEY]=Object.assign({},i,{visible:!1});break;case 2:n[e.CANCEL_KEY]=c(e.CANCEL_KEY,t[0]),n[e.CONFIRM_KEY]=c(e.CONFIRM_KEY,t[1]);break;default:r.throwErr("Invalid number of 'buttons' in array ("+t.length+").\n If you want more than 2 buttons, you need to use an object!")}return n};e.getButtonListOpts=function(t){var n=e.defaultButtonList;return"string"==typeof t?n[e.CONFIRM_KEY]=c(e.CONFIRM_KEY,t):Array.isArray(t)?n=l(t):r.isPlainObject(t)?n=function(t){for(var e={},n=0,r=Object.keys(t);n=0&&w.splice(e,1)}function s(t){var e=document.createElement("style");return t.attrs.type="text/css",l(e,t.attrs),i(t,e),e}function c(t){var e=document.createElement("link");return t.attrs.type="text/css",t.attrs.rel="stylesheet",l(e,t.attrs),i(t,e),e}function l(t,e){Object.keys(e).forEach((function(n){t.setAttribute(n,e[n])}))}function u(t,e){var n,r,o,i;if(e.transform&&t.css){if(!(i=e.transform(t.css)))return function(){};t.css=i}if(e.singleton){var l=v++;n=b||(b=s(e)),r=f.bind(null,n,l,!1),o=f.bind(null,n,l,!0)}else t.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(n=c(e),r=p.bind(null,n,e),o=function(){a(n),n.href&&URL.revokeObjectURL(n.href)}):(n=s(e),r=d.bind(null,n),o=function(){a(n)});return r(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;r(t=e)}else o()}}function f(t,e,n,r){var o=n?"":r.css;if(t.styleSheet)t.styleSheet.cssText=x(e,o);else{var i=document.createTextNode(o),a=t.childNodes;a[e]&&t.removeChild(a[e]),a.length?t.insertBefore(i,a[e]):t.appendChild(i)}}function d(t,e){var n=e.css,r=e.media;if(r&&t.setAttribute("media",r),t.styleSheet)t.styleSheet.cssText=n;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(n))}}function p(t,e,n){var r=n.css,o=n.sourceMap,i=void 0===e.convertToAbsoluteUrls&&o;(e.convertToAbsoluteUrls||i)&&(r=y(r)),o&&(r+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(o))))+" */");var a=new Blob([r],{type:"text/css"}),s=t.href;t.href=URL.createObjectURL(a),s&&URL.revokeObjectURL(s)}var m={},h=function(t){var e;return function(){return void 0===e&&(e=t.apply(this,arguments)),e}}((function(){return window&&document&&document.all&&!window.atob})),g=function(t){var e={};return function(n){return void 0===e[n]&&(e[n]=t.call(this,n)),e[n]}}((function(t){return document.querySelector(t)})),b=null,v=0,w=[],y=n(15);t.exports=function(t,e){if("undefined"!=typeof DEBUG&&DEBUG&&"object"!=typeof document)throw new Error("The style-loader cannot be used in a non-browser environment");(e=e||{}).attrs="object"==typeof e.attrs?e.attrs:{},e.singleton||(e.singleton=h()),e.insertInto||(e.insertInto="head"),e.insertAt||(e.insertAt="bottom");var n=o(t,e);return r(n,e),function(t){for(var i=[],a=0;athis.length)&&-1!==this.indexOf(t,e)}),Array.prototype.includes||Object.defineProperty(Array.prototype,"includes",{value:function(t,e){if(null==this)throw new TypeError('"this" is null or not defined');var n=Object(this),r=n.length>>>0;if(0===r)return!1;for(var o=0|e,i=Math.max(o>=0?o:r-Math.abs(o),0);i=0&&(t._idleTimeoutId=setTimeout((function(){t._onTimeout&&t._onTimeout()}),e))},o(19),r.setImmediate=e,r.clearImmediate=n},function(t,e,n){(function(t,e){!function(t,n){"use strict";function r(t){delete s[t]}function o(t){if(c)setTimeout(o,0,t);else{var e=s[t];if(e){c=!0;try{!function(t){var e=t.callback,n=t.args;switch(n.length){case 0:e();break;case 1:e(n[0]);break;case 2:e(n[0],n[1]);break;case 3:e(n[0],n[1],n[2]);break;default:e.apply(void 0,n)}}(e)}finally{r(t),c=!1}}}}if(!t.setImmediate){var i,a=1,s={},c=!1,l=t.document,u=Object.getPrototypeOf&&Object.getPrototypeOf(t);u=u&&u.setTimeout?u:t,"[object process]"==={}.toString.call(t.process)?i=function(t){e.nextTick((function(){o(t)}))}:function(){if(t.postMessage&&!t.importScripts){var e=!0,n=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=n,e}}()?function(){var e="setImmediate$"+Math.random()+"$",n=function(n){n.source===t&&"string"==typeof n.data&&0===n.data.indexOf(e)&&o(+n.data.slice(e.length))};t.addEventListener?t.addEventListener("message",n,!1):t.attachEvent("onmessage",n),i=function(n){t.postMessage(e+n,"*")}}():t.MessageChannel?function(){var t=new MessageChannel;t.port1.onmessage=function(t){o(t.data)},i=function(e){t.port2.postMessage(e)}}():l&&"onreadystatechange"in l.createElement("script")?function(){var t=l.documentElement;i=function(e){var n=l.createElement("script");n.onreadystatechange=function(){o(e),n.onreadystatechange=null,t.removeChild(n),n=null},t.appendChild(n)}}():i=function(t){setTimeout(o,0,t)},u.setImmediate=function(t){"function"!=typeof t&&(t=new Function(""+t));for(var e=new Array(arguments.length-1),n=0;n1)for(var n=1;n
    ',e.default=e.modalMarkup},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r='
    \n
    ';e.default=r},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(0).default.ICON;e.errorIconMarkup=function(){var t=r+"--error",e=t+"__line";return'\n
    \n \n \n
    \n '},e.warningIconMarkup=function(){var t=r+"--warning";return'\n \n \n \n '},e.successIconMarkup=function(){var t=r+"--success";return'\n \n \n\n
    \n
    \n '}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(0).default.CONTENT;e.contentMarkup='\n
    \n\n
    \n'},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(0),o=r.default.BUTTON_CONTAINER,i=r.default.BUTTON,a=r.default.BUTTON_LOADER;e.buttonMarkup='\n
    \n\n \n\n
    \n
    \n
    \n
    \n
    \n\n
    \n'},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(4),o=n(2),i=n(0),a=i.default.ICON,s=i.default.ICON_CUSTOM,c=["error","warning","success","info"],l={error:o.errorIconMarkup(),warning:o.warningIconMarkup(),success:o.successIconMarkup()};e.default=function(t){if(t){var e=r.injectElIntoModal(o.iconMarkup);c.includes(t)?function(t,e){var n=a+"--"+t;e.classList.add(n);var r=l[t];r&&(e.innerHTML=r)}(t,e):function(t,e){e.classList.add(s);var n=document.createElement("img");n.src=t,e.appendChild(n)}(t,e)}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2),o=n(4),i=function(t){navigator.userAgent.includes("AppleWebKit")&&(t.style.display="none",t.offsetHeight,t.style.display="")};e.initTitle=function(t){if(t){var e=o.injectElIntoModal(r.titleMarkup);e.textContent=t,i(e)}},e.initText=function(t){if(t){var e=document.createDocumentFragment();t.split("\n").forEach((function(t,n,r){e.appendChild(document.createTextNode(t)),n0})).forEach((function(t){h.classList.add(t)})),n&&t===c.CONFIRM_KEY&&h.classList.add(s),h.textContent=o;var b={};return b[t]=i,f.setActionValue(b),f.setActionOptionsFor(t,{closeModal:p}),h.addEventListener("click",(function(){return u.onAction(t)})),m};e.default=function(t,e){var n=o.injectElIntoModal(l.footerMarkup);for(var r in t){var i=t[r],a=d(r,i,e);i.visible&&n.appendChild(a)}0===n.children.length&&n.remove()}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(3),o=n(4),i=n(2),a=n(5),s=n(6),c=n(0).default.CONTENT,l=function(t){t.addEventListener("input",(function(t){var e=t.target.value;a.setActionValue(e)})),t.addEventListener("keyup",(function(t){if("Enter"===t.key)return s.onAction(r.CONFIRM_KEY)})),setTimeout((function(){t.focus(),a.setActionValue("")}),0)};e.default=function(t){if(t){var e=o.injectElIntoModal(i.contentMarkup),n=t.element,r=t.attributes;"string"==typeof n?function(t,e,n){var r=document.createElement(e),o=c+"__"+e;for(var i in r.classList.add(o),n){var a=n[i];r[i]=a}"input"===e&&l(r),t.appendChild(r)}(e,n,r):e.appendChild(n)}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1),o=n(2);e.default=function(){var t=r.stringToNode(o.overlayMarkup);document.body.appendChild(t)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(5),o=n(6),i=n(1),a=n(3),s=n(0),c=s.default.MODAL,l=s.default.BUTTON,u=s.default.OVERLAY,f=function(t){if(r.default.isOpen)switch(t.key){case"Escape":return o.onAction(a.CANCEL_KEY)}},d=function(t){if(r.default.isOpen)switch(t.key){case"Tab":return function(t){t.preventDefault(),m()}(t)}},p=function(t){if(r.default.isOpen)return"Tab"===t.key&&t.shiftKey?function(t){t.preventDefault(),h()}(t):void 0},m=function(){var t=i.getNode(l);t&&(t.tabIndex=0,t.focus())},h=function(){var t=i.getNode(c).querySelectorAll("."+l),e=t[t.length-1];e&&e.focus()},g=function(){var t=i.getNode(c).querySelectorAll("."+l);t.length&&(function(t){t[t.length-1].addEventListener("keydown",d)}(t),function(t){t[0].addEventListener("keydown",p)}(t))},b=function(t){if(i.getNode(u)===t.target)return o.onAction(a.CANCEL_KEY)};e.default=function(t){t.closeOnEsc?document.addEventListener("keyup",f):document.removeEventListener("keyup",f),t.dangerMode?m():h(),g(),function(t){var e=i.getNode(u);e.removeEventListener("click",b),t&&e.addEventListener("click",b)}(t.closeOnClickOutside),function(t){r.default.timer&&clearTimeout(r.default.timer),t&&(r.default.timer=window.setTimeout((function(){return o.onAction(a.CANCEL_KEY)}),t))}(t.timer)}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1),o=n(3),i=n(37),a=n(38),s={title:null,text:null,icon:null,buttons:o.defaultButtonList,content:null,className:null,closeOnClickOutside:!0,closeOnEsc:!0,dangerMode:!1,timer:null},c=Object.assign({},s);e.setDefaults=function(t){c=Object.assign({},s,t)};var l=function(t){var e=t&&t.button,n=t&&t.buttons;return void 0!==e&&void 0!==n&&r.throwErr("Cannot set both 'button' and 'buttons' options!"),void 0!==e?{confirm:e}:n},u=function(t){return r.ordinalSuffixOf(t+1)},f=function(t,e){r.throwErr(u(e)+" argument ('"+t+"') is invalid")},d=function(t,e){var n=t+1,o=e[n];r.isPlainObject(o)||void 0===o||r.throwErr("Expected "+u(n)+" argument ('"+o+"') to be a plain object")},p=function(t,e,n,o){var i=e instanceof Element;if("string"==typeof e){if(0===n)return{text:e};if(1===n)return{text:e,title:o[0]};if(2===n)return d(n,o),{icon:e};f(e,n)}else{if(i&&0===n)return d(n,o),{content:e};if(r.isPlainObject(e))return function(t,e){var n=t+1,o=e[n];void 0!==o&&r.throwErr("Unexpected "+u(n)+" argument ("+o+")")}(n,o),e;f(e,n)}};e.getOpts=function(){for(var t=[],e=0;e1||"".split(/.?/)[p]?function(t,e){var o=String(this);if(void 0===t&&0===e)return[];if(!r(t))return n.call(o,t,e);for(var i,a,s,c=[],u=(t.ignoreCase?"i":"")+(t.multiline?"m":"")+(t.unicode?"u":"")+(t.sticky?"y":""),f=0,m=void 0===e?4294967295:e>>>0,h=new RegExp(t.source,u+"g");(i=l.call(h,o))&&!((a=h.lastIndex)>f&&(c.push(o.slice(f,i.index)),i[p]>1&&i.index=m));)h.lastIndex===i.index&&h.lastIndex++;return f===o[p]?!s&&h.test("")||c.push(""):c.push(o.slice(f)),c[p]>m?c.slice(0,m):c}:"0".split(void 0,0)[p]?function(t,e){return void 0===t&&0===e?[]:n.call(this,t,e)}:n,[function(n,r){var o=t(this),i=null==n?void 0:n[e];return void 0!==i?i.call(n,o,r):h.call(String(o),n,r)},function(t,e){var r=u(h,t,this,e,h!==n);if(r.done)return r.value;var l=o(t),d=String(this),p=i(l,RegExp),g=l.unicode,b=(l.ignoreCase?"i":"")+(l.multiline?"m":"")+(l.unicode?"u":"")+(m?"y":"g"),v=new p(m?l:"^(?:"+l.source+")",b),w=void 0===e?4294967295:e>>>0;if(0===w)return[];if(0===d.length)return null===c(v,d)?[d]:[];for(var y=0,x=0,k=[];xu;)n=c[u++],r&&!a.call(s,n)||f.push(t?[n,s[n]]:s[n]);return f}}},114:function(t,e,n){var r=n(95),o=n(115);n(96);function i(t){return null==t}function a(t){(t=function(t){var e={};for(var n in t)e[n]=t[n];return e}(t||{})).whiteList=t.whiteList||r.whiteList,t.onAttr=t.onAttr||r.onAttr,t.onIgnoreAttr=t.onIgnoreAttr||r.onIgnoreAttr,t.safeAttrValue=t.safeAttrValue||r.safeAttrValue,this.options=t}a.prototype.process=function(t){if(!(t=(t=t||"").toString()))return"";var e=this.options,n=e.whiteList,r=e.onAttr,a=e.onIgnoreAttr,s=e.safeAttrValue;return o(t,(function(t,e,o,c,l){var u=n[o],f=!1;if(!0===u?f=u:"function"==typeof u?f=u(c):u instanceof RegExp&&(f=u.test(c)),!0!==f&&(f=!1),c=s(o,c)){var d,p={position:e,sourcePosition:t,source:l,isWhite:f};return f?i(d=r(o,c,p))?o+":"+c:d:i(d=a(o,c,p))?void 0:d}}))},t.exports=a},115:function(t,e,n){var r=n(96);t.exports=function(t,e){";"!==(t=r.trimRight(t))[t.length-1]&&(t+=";");var n=t.length,o=!1,i=0,a=0,s="";function c(){if(!o){var n=r.trim(t.slice(i,a)),c=n.indexOf(":");if(-1!==c){var l=r.trim(n.slice(0,c)),u=r.trim(n.slice(c+1));if(l){var f=e(i,s.length,l,u,n);f&&(s+=f+"; ")}}}i=a+1}for(;a";var v=function(t){var e=c.spaceIndex(t);if(-1===e)return{html:"",closing:"/"===t[t.length-2]};var n="/"===(t=c.trim(t.slice(e+1,-1)))[t.length-1];return n&&(t=c.trim(t.slice(0,-1))),{html:t,closing:n}}(a),w=n[o],y=s(v.html,(function(t,e){var n,r=-1!==c.indexOf(w,t);return l(n=u(o,t,e,r))?r?(e=d(o,t,e,m))?t+'="'+e+'"':t:l(n=f(o,t,e,r))?void 0:n:n}));a="<"+o;return y&&(a+=" "+y),v.closing&&(a+=" /"),a+=">"}return l(g=i(o,a,b))?p(a):g}),p);return h&&(g=h.remove(g)),g},t.exports=u},117:function(t,e,n){"use strict";n.d(e,"a",(function(){return s}));n(62);var r=n(56),o=n.n(r);function i(){var t=function(t,e){e||(e=t.slice(0));return Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(e)}}))}(["\n&&&& {\n position: absolute;\n top: 110px;\n left: 90px;\n}\n\n&&&& > div {\n width: 18px;\n height: 18px;\n background-color: #333;\n\n border-radius: 100%;\n display: inline-block;\n -webkit-animation: sk-bouncedelay 1.4s infinite ease-in-out both;\n animation: sk-bouncedelay 1.4s infinite ease-in-out both;\n}\n\n&&&& .bounce1 {\n -webkit-animation-delay: -0.32s;\n animation-delay: -0.32s;\n}\n\n&&&& .bounce2 {\n -webkit-animation-delay: -0.16s;\n animation-delay: -0.16s;\n}\n\n@-webkit-keyframes sk-bouncedelay {\n 0%, 80%, 100% { -webkit-transform: scale(0) }\n 40% { -webkit-transform: scale(1.0) }\n}\n\n@keyframes sk-bouncedelay {\n0%, 80%, 100% {\n -webkit-transform: scale(0);\n transform: scale(0);\n } 40% {\n -webkit-transform: scale(1.0);\n transform: scale(1.0);\n }\n}\n"]);return i=function(){return t},t}var a=n(60).default.div(i());function s(){return o.a.createElement(a,null,o.a.createElement("div",{className:"bounce1"}),o.a.createElement("div",{className:"bounce2"}),o.a.createElement("div",{className:"bounce3"}))}},152:function(t,e,n){"use strict";n.r(e),n.d(e,"default",(function(){return x}));n(23),n(72),n(69),n(65),n(70),n(71),n(22),n(61),n(66),n(67),n(62),n(109),n(24),n(194);var r,o=n(56),i=n.n(o),a=n(60),s=n(63),c=n(117),l=n(79);function u(t,e,n,r,o,i,a){try{var s=t[i](a),c=s.value}catch(t){return void n(t)}s.done?e(c):Promise.resolve(c).then(r,o)}function f(t){return function(){var e=this,n=arguments;return new Promise((function(r,o){var i=t.apply(e,n);function a(t){u(i,r,o,a,s,"next",t)}function s(t){u(i,r,o,a,s,"throw",t)}a(void 0)}))}}function d(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(t)))return;var n=[],r=!0,o=!1,i=void 0;try{for(var a,s=t[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{r||null==s.return||s.return()}finally{if(o)throw i}}return n}(t,e)||function(t,e){if(!t)return;if("string"==typeof t)return p(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);"Object"===n&&t.constructor&&(n=t.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return p(t,e)}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function p(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n-1&&window.localStorage.removeItem(t)}function C(){p(window.innerWidth>800&&window.innerHeight>860)}function L(){return S.apply(this,arguments)}function S(){return(S=f(regeneratorRuntime.mark((function t(){var e,n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,l.a.get(window.MollieModule.urls.qrCodeNew);case 3:return e=t.sent,n=e.data,window.localStorage.setItem("mollieqrcache-"+n.expires+"-"+n.amount,JSON.stringify({url:n.href,idTransaction:n.idTransaction})),_(n.href),t.abrupt("return",n.idTransaction);case 10:t.prev=10,t.t0=t.catch(0),console.error(t.t0);case 13:case"end":return t.stop()}}),t,null,[[0,10]])})))).apply(this,arguments)}function N(t){A&&setTimeout(f(regeneratorRuntime.mark((function e(){var n,o,i;return regeneratorRuntime.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,l.a.get("".concat(window.MollieModule.urls.qrCodeStatus,"&transaction_id=").concat(t));case 3:n=e.sent,(o=n.data).status===r.success?(M(),(i=document.createElement("A")).href=o.href,i.hostname===window.location.hostname&&(window.location.href=o.href)):o.status===r.refresh?(M(),L().then()):o.status===r.pending?N(t):console.error("Invalid payment status"),e.next=11;break;case 8:e.prev=8,e.t0=e.catch(0),N(t);case 11:case"end":return e.stop()}}),e,null,[[0,8]])}))),5e3)}function R(){return(R=f(regeneratorRuntime.mark((function t(){var e,n;return regeneratorRuntime.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,l.a.get(window.MollieModule.urls.cartAmount);case 3:return e=t.sent,n=e.data.amount,t.abrupt("return",n);case 8:t.prev=8,t.t0=t.catch(0),console.error(t.t0);case 11:case"end":return t.stop()}}),t,null,[[0,8]])})))).apply(this,arguments)}function P(t){var e=null,n=null;if(void 0!==window.localStorage){for(var r in window.localStorage)if(r.indexOf("mollieqrcache")>-1){var o=r.split("-");if(parseInt(o[1],10)>+new Date+6e4&&parseInt(o[2],10)===t){var i=JSON.parse(window.localStorage.getItem(r)),a=document.createElement("A");if(a.href=i.url,!/\.ideal\.nl$/i.test(a.hostname)||"https:"!==a.protocol){window.localStorage.removeItem(r);continue}e=i.url,n=i.idTransaction;break}window.localStorage.removeItem(r)}e&&n?(_(e),N(n)):L().then(N)}}var F=Object(o.useRef)(null),z=Object(s.throttle)((function(){C()}),200);return Object(o.useEffect)((function(){j(!0);var t=new IntersectionObserver((function(e){e.forEach((function(e){var n=e.isIntersecting,r=e.intersectionRatio;(!0===n||r>0)&&(g(!0),t.disconnect(),t=null)}))}),{});return t.observe(F.current),C(),window.addEventListener("resize",z),function(){j(!1),null!=t&&(t.disconnect(),t=null),window.removeEventListener("resize",z)}}),[]),Object(o.useEffect)((function(){u&&h&&!k&&!T&&(E(!0),function(){return R.apply(this,arguments)}().then(P))}),[u,h,k,T]),u&&h&&!b?i.a.createElement(i.a.Fragment,null,i.a.createElement(v,null,e),i.a.createElement(w,{center:n},!k&&i.a.createElement(c.a,null),k&&i.a.createElement(y,{src:k,center:n}))):i.a.createElement("p",{ref:F,style:{width:"20px"}}," ")}},193:function(t,e,n){"use strict";n.r(e),n.d(e,"default",(function(){return d}));n(62),n(65),n(61),n(68),n(22),n(104);var r=n(56),o=n.n(r),i=n(90),a=n.n(i),s=n(60),c=n(117);function l(){var t=function(t,e){e||(e=t.slice(0));return Object.freeze(Object.defineProperties(t,{raw:{value:Object.freeze(e)}}))}(['\n&&&& {\n padding-left: 80px;\n cursor: pointer;\n text-align: left;\n}\n\n&&&& label {\n display: inline-block;\n position: relative;\n padding-left: 5px;\n cursor: pointer;\n}\n\n&&&& label::before {\n content: "";\n display: inline-block;\n position: absolute;\n width: 17px;\n height: 17px;\n left: 0;\n top: 7px;\n margin-left: -20px;\n border: 1px solid #cccccc;\n border-radius: 50%;\n background-color: #fff;\n -webkit-transition: border 0.15s ease-in-out;\n -o-transition: border 0.15s ease-in-out;\n transition: border 0.15s ease-in-out;\n}\n\n&&&& label::after {\n display: inline-block;\n position: absolute;\n content: " ";\n width: 11px;\n height: 11px;\n left: 3px;\n top: 10px;\n margin-left: -20px;\n border-radius: 50%;\n background-color: #555555;\n -webkit-transform: scale(0, 0);\n -ms-transform: scale(0, 0);\n -o-transform: scale(0, 0);\n transform: scale(0, 0);\n -webkit-transition: -webkit-transform 0.1s cubic-bezier(0.8, -0.33, 0.2, 1.33);\n -moz-transition: -moz-transform 0.1s cubic-bezier(0.8, -0.33, 0.2, 1.33);\n -o-transition: -o-transform 0.1s cubic-bezier(0.8, -0.33, 0.2, 1.33);\n transition: transform 0.1s cubic-bezier(0.8, -0.33, 0.2, 1.33);\n}\n\n&&&& input[type="radio"] {\n opacity: 0;\n}\n\n&&&& input[type="radio"]:focus + label::before {\n outline: 5px auto -webkit-focus-ring-color;\n outline-offset: -2px;\n}\n\n&&&& input[type="radio"]:checked + label::after {\n -webkit-transform: scale(1, 1);\n -ms-transform: scale(1, 1);\n -o-transform: scale(1, 1);\n transform: scale(1, 1);\n}\n\n&&&& input[type="radio"]:disabled + label {\n opacity: 0.65;\n}\n\n&&&& input[type="radio"]:disabled + label::before {\n cursor: not-allowed;\n}\n\n&&&&&&&&-inline {\n margin-top: 0;\n}\n\n&&&& input[type="radio"] + label::after {\n background-color: #7cd1f9;\n}\n\n&&&& input[type="radio"]:checked + label::before {\n border-color: #7cd1f9;\n}\n\n&&&& input[type="radio"]:checked + label::after {\n background-color: #7cd1f9;\n}\n']);return l=function(){return t},t}var u=Object(r.lazy)((function(){return Promise.resolve().then(n.bind(null,152))})),f=s.default.div(l());function d(t){var e=t.banks,n=t.translations,i=t.setIssuer;function s(t){var e=t.target.value;i(e)}var l=Object.values(e)[0].id;return o.a.createElement("div",null,o.a.createElement("ul",null,Object.values(e).map((function(t){return o.a.createElement(f,{key:t.id},o.a.createElement("input",{type:"radio",defaultChecked:t.id===l,id:t.id,name:"mollie-bank",value:t.id,onChange:s}),o.a.createElement("label",{htmlFor:t.id,style:{lineHeight:"24px"}},o.a.createElement("img",{src:t.image.size2x,alt:a()(t.name),style:{height:"24px",width:"auto"}})," ",t.name))}))),window.mollieQrEnabled&&o.a.createElement(r.Suspense,{fallback:o.a.createElement(c.a,null)},o.a.createElement(u,{title:n.orPayByIdealQr,center:!0})))}},194:function(t,e){!function(t,e){"use strict";if("IntersectionObserver"in t&&"IntersectionObserverEntry"in t&&"intersectionRatio"in t.IntersectionObserverEntry.prototype)"isIntersecting"in t.IntersectionObserverEntry.prototype||Object.defineProperty(t.IntersectionObserverEntry.prototype,"isIntersecting",{get:function(){return this.intersectionRatio>0}});else{var n=[];o.prototype.THROTTLE_TIMEOUT=100,o.prototype.POLL_INTERVAL=null,o.prototype.USE_MUTATION_OBSERVER=!0,o.prototype.observe=function(t){if(!this._observationTargets.some((function(e){return e.element==t}))){if(!t||1!=t.nodeType)throw new Error("target must be an Element");this._registerInstance(),this._observationTargets.push({element:t,entry:null}),this._monitorIntersections(),this._checkForIntersections()}},o.prototype.unobserve=function(t){this._observationTargets=this._observationTargets.filter((function(e){return e.element!=t})),this._observationTargets.length||(this._unmonitorIntersections(),this._unregisterInstance())},o.prototype.disconnect=function(){this._observationTargets=[],this._unmonitorIntersections(),this._unregisterInstance()},o.prototype.takeRecords=function(){var t=this._queuedEntries.slice();return this._queuedEntries=[],t},o.prototype._initThresholds=function(t){var e=t||[0];return Array.isArray(e)||(e=[e]),e.sort().filter((function(t,e,n){if("number"!=typeof t||isNaN(t)||t<0||t>1)throw new Error("threshold must be a number between 0 and 1 inclusively");return t!==n[e-1]}))},o.prototype._parseRootMargin=function(t){var e=(t||"0px").split(/\s+/).map((function(t){var e=/^(-?\d*\.?\d+)(px|%)$/.exec(t);if(!e)throw new Error("rootMargin must be specified in pixels or percent");return{value:parseFloat(e[1]),unit:e[2]}}));return e[1]=e[1]||e[0],e[2]=e[2]||e[0],e[3]=e[3]||e[1],e},o.prototype._monitorIntersections=function(){this._monitoringIntersections||(this._monitoringIntersections=!0,this.POLL_INTERVAL?this._monitoringInterval=setInterval(this._checkForIntersections,this.POLL_INTERVAL):(i(t,"resize",this._checkForIntersections,!0),i(e,"scroll",this._checkForIntersections,!0),this.USE_MUTATION_OBSERVER&&"MutationObserver"in t&&(this._domObserver=new MutationObserver(this._checkForIntersections),this._domObserver.observe(e,{attributes:!0,childList:!0,characterData:!0,subtree:!0}))))},o.prototype._unmonitorIntersections=function(){this._monitoringIntersections&&(this._monitoringIntersections=!1,clearInterval(this._monitoringInterval),this._monitoringInterval=null,a(t,"resize",this._checkForIntersections,!0),a(e,"scroll",this._checkForIntersections,!0),this._domObserver&&(this._domObserver.disconnect(),this._domObserver=null))},o.prototype._checkForIntersections=function(){var e=this._rootIsInDom(),n=e?this._getRootRect():{top:0,bottom:0,left:0,right:0,width:0,height:0};this._observationTargets.forEach((function(o){var i=o.element,a=s(i),c=this._rootContainsTarget(i),l=o.entry,u=e&&c&&this._computeTargetAndRootIntersection(i,n),f=o.entry=new r({time:t.performance&&performance.now&&performance.now(),target:i,boundingClientRect:a,rootBounds:n,intersectionRect:u});l?e&&c?this._hasCrossedThreshold(l,f)&&this._queuedEntries.push(f):l&&l.isIntersecting&&this._queuedEntries.push(f):this._queuedEntries.push(f)}),this),this._queuedEntries.length&&this._callback(this.takeRecords(),this)},o.prototype._computeTargetAndRootIntersection=function(n,r){if("none"!=t.getComputedStyle(n).display){for(var o,i,a,c,u,f,d,p,m=s(n),h=l(n),g=!1;!g;){var b=null,v=1==h.nodeType?t.getComputedStyle(h):{};if("none"==v.display)return;if(h==this.root||h==e?(g=!0,b=r):h!=e.body&&h!=e.documentElement&&"visible"!=v.overflow&&(b=s(h)),b&&(o=b,i=m,a=void 0,c=void 0,u=void 0,f=void 0,d=void 0,p=void 0,a=Math.max(o.top,i.top),c=Math.min(o.bottom,i.bottom),u=Math.max(o.left,i.left),f=Math.min(o.right,i.right),p=c-a,!(m=(d=f-u)>=0&&p>=0&&{top:a,bottom:c,left:u,right:f,width:d,height:p})))break;h=l(h)}return m}},o.prototype._getRootRect=function(){var t;if(this.root)t=s(this.root);else{var n=e.documentElement,r=e.body;t={top:0,left:0,right:n.clientWidth||r.clientWidth,width:n.clientWidth||r.clientWidth,bottom:n.clientHeight||r.clientHeight,height:n.clientHeight||r.clientHeight}}return this._expandRectByRootMargin(t)},o.prototype._expandRectByRootMargin=function(t){var e=this._rootMarginValues.map((function(e,n){return"px"==e.unit?e.value:e.value*(n%2?t.width:t.height)/100})),n={top:t.top-e[0],right:t.right+e[1],bottom:t.bottom+e[2],left:t.left-e[3]};return n.width=n.right-n.left,n.height=n.bottom-n.top,n},o.prototype._hasCrossedThreshold=function(t,e){var n=t&&t.isIntersecting?t.intersectionRatio||0:-1,r=e.isIntersecting?e.intersectionRatio||0:-1;if(n!==r)for(var o=0;o=0&&(t._idleTimeoutId=setTimeout((function(){t._onTimeout&&t._onTimeout()}),e))},n(78),e.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==t&&t.setImmediate||this&&this.setImmediate,e.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==t&&t.clearImmediate||this&&this.clearImmediate}).call(this,n(64))},78:function(t,e,n){(function(t,e){!function(t,n){"use strict";if(!t.setImmediate){var r,o,i,a,s,c=1,l={},u=!1,f=t.document,d=Object.getPrototypeOf&&Object.getPrototypeOf(t);d=d&&d.setTimeout?d:t,"[object process]"==={}.toString.call(t.process)?r=function(t){e.nextTick((function(){m(t)}))}:!function(){if(t.postMessage&&!t.importScripts){var e=!0,n=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=n,e}}()?t.MessageChannel?((i=new MessageChannel).port1.onmessage=function(t){m(t.data)},r=function(t){i.port2.postMessage(t)}):f&&"onreadystatechange"in f.createElement("script")?(o=f.documentElement,r=function(t){var e=f.createElement("script");e.onreadystatechange=function(){m(t),e.onreadystatechange=null,o.removeChild(e),e=null},o.appendChild(e)}):r=function(t){setTimeout(m,0,t)}:(a="setImmediate$"+Math.random()+"$",s=function(e){e.source===t&&"string"==typeof e.data&&0===e.data.indexOf(a)&&m(+e.data.slice(a.length))},t.addEventListener?t.addEventListener("message",s,!1):t.attachEvent("onmessage",s),r=function(e){t.postMessage(a+e,"*")}),d.setImmediate=function(t){"function"!=typeof t&&(t=new Function(""+t));for(var e=new Array(arguments.length-1),n=0;n/g,f=/"/g,d=/"/g,p=/&#([a-zA-Z0-9]*);?/gim,m=/:?/gim,h=/&newline;?/gim,g=/((j\s*a\s*v\s*a|v\s*b|l\s*i\s*v\s*e)\s*s\s*c\s*r\s*i\s*p\s*t\s*|m\s*o\s*c\s*h\s*a)\:/gi,b=/e\s*x\s*p\s*r\s*e\s*s\s*s\s*i\s*o\s*n\s*\(.*/gi,v=/u\s*r\s*l\s*\(.*/gi;function w(t){return t.replace(f,""")}function y(t){return t.replace(d,'"')}function x(t){return t.replace(p,(function(t,e){return"x"===e[0]||"X"===e[0]?String.fromCharCode(parseInt(e.substr(1),16)):String.fromCharCode(parseInt(e,10))}))}function k(t){return t.replace(m,":").replace(h," ")}function _(t){for(var e="",n=0,r=t.length;n/g;e.whiteList={a:["target","href","title"],abbr:["title"],address:[],area:["shape","coords","href","alt"],article:[],aside:[],audio:["autoplay","controls","loop","preload","src"],b:[],bdi:["dir"],bdo:["dir"],big:[],blockquote:["cite"],br:[],caption:[],center:[],cite:[],code:[],col:["align","valign","span","width"],colgroup:["align","valign","span","width"],dd:[],del:["datetime"],details:["open"],div:[],dl:[],dt:[],em:[],font:["color","size","face"],footer:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],header:[],hr:[],i:[],img:["src","alt","title","width","height"],ins:["datetime"],li:[],mark:[],nav:[],ol:[],p:[],pre:[],s:[],section:[],small:[],span:[],sub:[],sup:[],strong:[],table:["width","border","align","valign"],tbody:["align","valign"],td:["width","rowspan","colspan","align","valign"],tfoot:["align","valign"],th:["width","rowspan","colspan","align","valign"],thead:["align","valign"],tr:["rowspan","align","valign"],tt:[],u:[],ul:[],video:["autoplay","controls","loop","preload","src","height","width"]},e.getDefaultWhiteList=a,e.onTag=function(t,e,n){},e.onIgnoreTag=function(t,e,n){},e.onTagAttr=function(t,e,n){},e.onIgnoreTagAttr=function(t,e,n){},e.safeAttrValue=function(t,e,n,r){if(n=O(n),"href"===e||"src"===e){if("#"===(n=i.trim(n)))return"#";if("http://"!==n.substr(0,7)&&"https://"!==n.substr(0,8)&&"mailto:"!==n.substr(0,7)&&"tel:"!==n.substr(0,4)&&"#"!==n[0]&&"/"!==n[0])return""}else if("background"===e){if(g.lastIndex=0,g.test(n))return""}else if("style"===e){if(b.lastIndex=0,b.test(n))return"";if(v.lastIndex=0,v.test(n)&&(g.lastIndex=0,g.test(n)))return"";!1!==r&&(n=(r=r||s).process(n))}return n=T(n)},e.escapeHtml=c,e.escapeQuote=w,e.unescapeQuote=y,e.escapeHtmlEntities=x,e.escapeDangerHtml5Entities=k,e.clearNonPrintableCharacter=_,e.friendlyAttrValue=O,e.escapeAttrValue=T,e.onIgnoreTagStripAll=function(){return""},e.StripTagBody=function(t,e){"function"!=typeof e&&(e=function(){});var n=!Array.isArray(t),r=[],o=!1;return{onIgnoreTag:function(a,s,c){if(function(e){return!!n||-1!==i.indexOf(t,e)}(a)){if(c.isClosing){var l="[/removed]",u=c.position+l.length;return r.push([!1!==o?o:c.position,u]),o=!1,l}return o||(o=c.position),"[removed]"}return e(a,s,c)},remove:function(t){var e="",n=0;return i.forEach(r,(function(r){e+=t.slice(n,r[0]),n=r[1]})),e+=t.slice(n)}}},e.stripCommentTag=function(t){return t.replace(E,"")},e.stripBlankChar=function(t){var e=t.split("");return(e=e.filter((function(t){var e=t.charCodeAt(0);return 127!==e&&(!(e<=31)||(10===e||13===e))}))).join("")},e.cssFilter=s,e.getDefaultCSSWhiteList=o},95:function(t,e){function n(){var t={"align-content":!1,"align-items":!1,"align-self":!1,"alignment-adjust":!1,"alignment-baseline":!1,all:!1,"anchor-point":!1,animation:!1,"animation-delay":!1,"animation-direction":!1,"animation-duration":!1,"animation-fill-mode":!1,"animation-iteration-count":!1,"animation-name":!1,"animation-play-state":!1,"animation-timing-function":!1,azimuth:!1,"backface-visibility":!1,background:!0,"background-attachment":!0,"background-clip":!0,"background-color":!0,"background-image":!0,"background-origin":!0,"background-position":!0,"background-repeat":!0,"background-size":!0,"baseline-shift":!1,binding:!1,bleed:!1,"bookmark-label":!1,"bookmark-level":!1,"bookmark-state":!1,border:!0,"border-bottom":!0,"border-bottom-color":!0,"border-bottom-left-radius":!0,"border-bottom-right-radius":!0,"border-bottom-style":!0,"border-bottom-width":!0,"border-collapse":!0,"border-color":!0,"border-image":!0,"border-image-outset":!0,"border-image-repeat":!0,"border-image-slice":!0,"border-image-source":!0,"border-image-width":!0,"border-left":!0,"border-left-color":!0,"border-left-style":!0,"border-left-width":!0,"border-radius":!0,"border-right":!0,"border-right-color":!0,"border-right-style":!0,"border-right-width":!0,"border-spacing":!0,"border-style":!0,"border-top":!0,"border-top-color":!0,"border-top-left-radius":!0,"border-top-right-radius":!0,"border-top-style":!0,"border-top-width":!0,"border-width":!0,bottom:!1,"box-decoration-break":!0,"box-shadow":!0,"box-sizing":!0,"box-snap":!0,"box-suppress":!0,"break-after":!0,"break-before":!0,"break-inside":!0,"caption-side":!1,chains:!1,clear:!0,clip:!1,"clip-path":!1,"clip-rule":!1,color:!0,"color-interpolation-filters":!0,"column-count":!1,"column-fill":!1,"column-gap":!1,"column-rule":!1,"column-rule-color":!1,"column-rule-style":!1,"column-rule-width":!1,"column-span":!1,"column-width":!1,columns:!1,contain:!1,content:!1,"counter-increment":!1,"counter-reset":!1,"counter-set":!1,crop:!1,cue:!1,"cue-after":!1,"cue-before":!1,cursor:!1,direction:!1,display:!0,"display-inside":!0,"display-list":!0,"display-outside":!0,"dominant-baseline":!1,elevation:!1,"empty-cells":!1,filter:!1,flex:!1,"flex-basis":!1,"flex-direction":!1,"flex-flow":!1,"flex-grow":!1,"flex-shrink":!1,"flex-wrap":!1,float:!1,"float-offset":!1,"flood-color":!1,"flood-opacity":!1,"flow-from":!1,"flow-into":!1,font:!0,"font-family":!0,"font-feature-settings":!0,"font-kerning":!0,"font-language-override":!0,"font-size":!0,"font-size-adjust":!0,"font-stretch":!0,"font-style":!0,"font-synthesis":!0,"font-variant":!0,"font-variant-alternates":!0,"font-variant-caps":!0,"font-variant-east-asian":!0,"font-variant-ligatures":!0,"font-variant-numeric":!0,"font-variant-position":!0,"font-weight":!0,grid:!1,"grid-area":!1,"grid-auto-columns":!1,"grid-auto-flow":!1,"grid-auto-rows":!1,"grid-column":!1,"grid-column-end":!1,"grid-column-start":!1,"grid-row":!1,"grid-row-end":!1,"grid-row-start":!1,"grid-template":!1,"grid-template-areas":!1,"grid-template-columns":!1,"grid-template-rows":!1,"hanging-punctuation":!1,height:!0,hyphens:!1,icon:!1,"image-orientation":!1,"image-resolution":!1,"ime-mode":!1,"initial-letters":!1,"inline-box-align":!1,"justify-content":!1,"justify-items":!1,"justify-self":!1,left:!1,"letter-spacing":!0,"lighting-color":!0,"line-box-contain":!1,"line-break":!1,"line-grid":!1,"line-height":!1,"line-snap":!1,"line-stacking":!1,"line-stacking-ruby":!1,"line-stacking-shift":!1,"line-stacking-strategy":!1,"list-style":!0,"list-style-image":!0,"list-style-position":!0,"list-style-type":!0,margin:!0,"margin-bottom":!0,"margin-left":!0,"margin-right":!0,"margin-top":!0,"marker-offset":!1,"marker-side":!1,marks:!1,mask:!1,"mask-box":!1,"mask-box-outset":!1,"mask-box-repeat":!1,"mask-box-slice":!1,"mask-box-source":!1,"mask-box-width":!1,"mask-clip":!1,"mask-image":!1,"mask-origin":!1,"mask-position":!1,"mask-repeat":!1,"mask-size":!1,"mask-source-type":!1,"mask-type":!1,"max-height":!0,"max-lines":!1,"max-width":!0,"min-height":!0,"min-width":!0,"move-to":!1,"nav-down":!1,"nav-index":!1,"nav-left":!1,"nav-right":!1,"nav-up":!1,"object-fit":!1,"object-position":!1,opacity:!1,order:!1,orphans:!1,outline:!1,"outline-color":!1,"outline-offset":!1,"outline-style":!1,"outline-width":!1,overflow:!1,"overflow-wrap":!1,"overflow-x":!1,"overflow-y":!1,padding:!0,"padding-bottom":!0,"padding-left":!0,"padding-right":!0,"padding-top":!0,page:!1,"page-break-after":!1,"page-break-before":!1,"page-break-inside":!1,"page-policy":!1,pause:!1,"pause-after":!1,"pause-before":!1,perspective:!1,"perspective-origin":!1,pitch:!1,"pitch-range":!1,"play-during":!1,position:!1,"presentation-level":!1,quotes:!1,"region-fragment":!1,resize:!1,rest:!1,"rest-after":!1,"rest-before":!1,richness:!1,right:!1,rotation:!1,"rotation-point":!1,"ruby-align":!1,"ruby-merge":!1,"ruby-position":!1,"shape-image-threshold":!1,"shape-outside":!1,"shape-margin":!1,size:!1,speak:!1,"speak-as":!1,"speak-header":!1,"speak-numeral":!1,"speak-punctuation":!1,"speech-rate":!1,stress:!1,"string-set":!1,"tab-size":!1,"table-layout":!1,"text-align":!0,"text-align-last":!0,"text-combine-upright":!0,"text-decoration":!0,"text-decoration-color":!0,"text-decoration-line":!0,"text-decoration-skip":!0,"text-decoration-style":!0,"text-emphasis":!0,"text-emphasis-color":!0,"text-emphasis-position":!0,"text-emphasis-style":!0,"text-height":!0,"text-indent":!0,"text-justify":!0,"text-orientation":!0,"text-overflow":!0,"text-shadow":!0,"text-space-collapse":!0,"text-transform":!0,"text-underline-position":!0,"text-wrap":!0,top:!1,transform:!1,"transform-origin":!1,"transform-style":!1,transition:!1,"transition-delay":!1,"transition-duration":!1,"transition-property":!1,"transition-timing-function":!1,"unicode-bidi":!1,"vertical-align":!1,visibility:!1,"voice-balance":!1,"voice-duration":!1,"voice-family":!1,"voice-pitch":!1,"voice-range":!1,"voice-rate":!1,"voice-stress":!1,"voice-volume":!1,volume:!1,"white-space":!1,widows:!1,width:!0,"will-change":!1,"word-break":!0,"word-spacing":!0,"word-wrap":!0,"wrap-flow":!1,"wrap-through":!1,"writing-mode":!1,"z-index":!1};return t}var r=/javascript\s*\:/gim;e.whiteList=n(),e.getDefaultWhiteList=n,e.onAttr=function(t,e,n){},e.onIgnoreAttr=function(t,e,n){},e.safeAttrValue=function(t,e){return r.test(e)?"":e}},96:function(t,e){t.exports={indexOf:function(t,e){var n,r;if(Array.prototype.indexOf)return t.indexOf(e);for(n=0,r=t.length;n0;e--){var n=t[e];if(" "!==n)return"="===n?e:-1}}function l(t){return function(t){return'"'===t[0]&&'"'===t[t.length-1]||"'"===t[0]&&"'"===t[t.length-1]}(t)?t.substr(1,t.length-2):t}e.parseTag=function(t,e,n){var r="",a=0,s=!1,c=!1,l=0,u=t.length,f="",d="";for(l=0;l"===p){r+=n(t.slice(a,s)),f=o(d=t.slice(s,l+1)),r+=e(s,r.length,f,d,i(d)),a=l+1,s=!1;continue}if(('"'===p||"'"===p)&&"="===t.charAt(l-1)){c=p;continue}}else if(p===c){c=!1;continue}}return a - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ -(window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["carrierconfig"],{101:function(e,t,n){"use strict";n.d(t,"a",(function(){return l})),n.d(t,"b",(function(){return c}));var r=n(124),a=function(){return Math.random().toString(36).substring(7).split("").join(".")},i={INIT:"@@redux/INIT"+a(),REPLACE:"@@redux/REPLACE"+a(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+a()}};function o(e){if("object"!=typeof e||null===e)return!1;for(var t=e;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function c(e,t,n){var a;if("function"==typeof t&&"function"==typeof n||"function"==typeof n&&"function"==typeof arguments[3])throw new Error("It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function.");if("function"==typeof t&&void 0===n&&(n=t,t=void 0),void 0!==n){if("function"!=typeof n)throw new Error("Expected the enhancer to be a function.");return n(c)(e,t)}if("function"!=typeof e)throw new Error("Expected the reducer to be a function.");var s=e,l=t,f=[],u=f,d=!1;function m(){u===f&&(u=f.slice())}function p(){if(d)throw new Error("You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return l}function h(e){if("function"!=typeof e)throw new Error("Expected the listener to be a function.");if(d)throw new Error("You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api-reference/store#subscribelistener for more details.");var t=!0;return m(),u.push(e),function(){if(t){if(d)throw new Error("You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api-reference/store#subscribelistener for more details.");t=!1,m();var n=u.indexOf(e);u.splice(n,1),f=null}}}function y(e){if(!o(e))throw new Error("Actions must be plain objects. Use custom middleware for async actions.");if(void 0===e.type)throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?');if(d)throw new Error("Reducers may not dispatch actions.");try{d=!0,l=s(l,e)}finally{d=!1}for(var t=f=u,n=0;n-1;a--){var i=n[a],o=(i.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(o)>-1&&(r=i)}return y.head.insertBefore(t,r),e}}function B(){for(var e=12,t="";e-- >0;)t+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[62*Math.random()|0];return t}function G(e){return"".concat(e).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(//g,">")}function J(e){return Object.keys(e||{}).reduce((function(t,n){return t+"".concat(n,": ").concat(e[n],";")}),"")}function K(e){return e.size!==q.size||e.x!==q.x||e.y!==q.y||e.rotate!==q.rotate||e.flipX||e.flipY}function $(e){var t=e.transform,n=e.containerWidth,r=e.iconWidth,a={transform:"translate(".concat(n/2," 256)")},i="translate(".concat(32*t.x,", ").concat(32*t.y,") "),o="scale(".concat(t.size/16*(t.flipX?-1:1),", ").concat(t.size/16*(t.flipY?-1:1),") "),c="rotate(".concat(t.rotate," 0 0)");return{outer:a,inner:{transform:"".concat(i," ").concat(o," ").concat(c)},path:{transform:"translate(".concat(r/2*-1," -256)")}}}var Q={x:0,y:0,width:"100%",height:"100%"};function Z(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return e.attributes&&(e.attributes.fill||t)&&(e.attributes.fill="black"),e}function ee(e){var t=e.icons,n=t.main,r=t.mask,a=e.prefix,i=e.iconName,o=e.transform,s=e.symbol,l=e.title,f=e.maskId,u=e.titleId,d=e.extra,m=e.watchable,p=void 0!==m&&m,h=r.found?r:n,y=h.width,g=h.height,b="fa-w-".concat(Math.ceil(y/g*16)),v=[k.replacementClass,i?"".concat(k.familyPrefix,"-").concat(i):"",b].filter((function(e){return-1===d.classes.indexOf(e)})).concat(d.classes).join(" "),w={children:[],attributes:c({},d.attributes,{"data-prefix":a,"data-icon":i,class:v,role:d.attributes.role||"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(y," ").concat(g)})};p&&(w.attributes["data-fa-i2svg"]=""),l&&w.children.push({tag:"title",attributes:{id:w.attributes["aria-labelledby"]||"title-".concat(u||B())},children:[l]});var O=c({},w,{prefix:a,iconName:i,main:n,mask:r,maskId:f,transform:o,symbol:s,styles:d.styles}),x=r.found&&n.found?function(e){var t,n=e.children,r=e.attributes,a=e.main,i=e.mask,o=e.maskId,s=e.transform,l=a.width,f=a.icon,u=i.width,d=i.icon,m=$({transform:s,containerWidth:u,iconWidth:l}),p={tag:"rect",attributes:c({},Q,{fill:"white"})},h=f.children?{children:f.children.map(Z)}:{},y={tag:"g",attributes:c({},m.inner),children:[Z(c({tag:f.tag,attributes:c({},f.attributes,m.path)},h))]},g={tag:"g",attributes:c({},m.outer),children:[y]},b="mask-".concat(o||B()),v="clip-".concat(o||B()),w={tag:"mask",attributes:c({},Q,{id:b,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[p,g]},O={tag:"defs",children:[{tag:"clipPath",attributes:{id:v},children:(t=d,"g"===t.tag?t.children:[t])},w]};return n.push(O,{tag:"rect",attributes:c({fill:"currentColor","clip-path":"url(#".concat(v,")"),mask:"url(#".concat(b,")")},Q)}),{children:n,attributes:r}}(O):function(e){var t=e.children,n=e.attributes,r=e.main,a=e.transform,i=J(e.styles);if(i.length>0&&(n.style=i),K(a)){var o=$({transform:a,containerWidth:r.width,iconWidth:r.width});t.push({tag:"g",attributes:c({},o.outer),children:[{tag:"g",attributes:c({},o.inner),children:[{tag:r.icon.tag,children:r.icon.children,attributes:c({},r.icon.attributes,o.path)}]}]})}else t.push(r.icon);return{children:t,attributes:n}}(O),E=x.children,_=x.attributes;return O.children=E,O.attributes=_,s?function(e){var t=e.prefix,n=e.iconName,r=e.children,a=e.attributes,i=e.symbol;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:c({},a,{id:!0===i?"".concat(t,"-").concat(k.familyPrefix,"-").concat(n):i}),children:r}]}]}(O):function(e){var t=e.children,n=e.main,r=e.mask,a=e.attributes,i=e.styles,o=e.transform;if(K(o)&&n.found&&!r.found){var s={x:n.width/n.height/2,y:.5};a.style=J(c({},i,{"transform-origin":"".concat(s.x+o.x/16,"em ").concat(s.y+o.y/16,"em")}))}return[{tag:"svg",attributes:a,children:t}]}(O)}var te=function(){},ne=(k.measurePerformance&&g&&g.mark&&g.measure,function(e,t,n,r){var a,i,o,c=Object.keys(e),s=c.length,l=void 0!==r?function(e,t){return function(n,r,a,i){return e.call(t,n,r,a,i)}}(t,r):t;for(void 0===n?(a=1,o=e[c[0]]):(a=0,o=n);a2&&void 0!==arguments[2]?arguments[2]:{},r=n.skipHooks,a=void 0!==r&&r,i=Object.keys(t).reduce((function(e,n){var r=t[n];return!!r.icon?e[r.iconName]=r.icon:e[n]=r,e}),{});"function"!=typeof j.hooks.addPack||a?j.styles[e]=c({},j.styles[e]||{},i):j.hooks.addPack(e,i),"fas"===e&&re("fa",t)}var ae=j.styles,ie=j.shims,oe=function(){var e=function(e){return ne(ae,(function(t,n,r){return t[r]=ne(n,e,{}),t}),{})};e((function(e,t,n){return t[3]&&(e[t[3]]=n),e})),e((function(e,t,n){var r=t[2];return e[n]=n,r.forEach((function(t){e[t]=n})),e}));var t="far"in ae;ne(ie,(function(e,n){var r=n[0],a=n[1],i=n[2];return"far"!==a||t||(a="fas"),e[r]={prefix:a,iconName:i},e}),{})};oe();j.styles;function ce(e,t,n){if(e&&e[t]&&e[t][n])return{prefix:t,iconName:n,icon:e[t][n]}}function se(e){var t=e.tag,n=e.attributes,r=void 0===n?{}:n,a=e.children,i=void 0===a?[]:a;return"string"==typeof e?G(e):"<".concat(t," ").concat(function(e){return Object.keys(e||{}).reduce((function(t,n){return t+"".concat(n,'="').concat(G(e[n]),'" ')}),"").trim()}(r),">").concat(i.map(se).join(""),"")}var le=function(e){var t={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0};return e?e.toLowerCase().split(" ").reduce((function(e,t){var n=t.toLowerCase().split("-"),r=n[0],a=n.slice(1).join("-");if(r&&"h"===a)return e.flipX=!0,e;if(r&&"v"===a)return e.flipY=!0,e;if(a=parseFloat(a),isNaN(a))return e;switch(r){case"grow":e.size=e.size+a;break;case"shrink":e.size=e.size-a;break;case"left":e.x=e.x-a;break;case"right":e.x=e.x+a;break;case"up":e.y=e.y-a;break;case"down":e.y=e.y+a;break;case"rotate":e.rotate=e.rotate+a}return e}),t):t};function fe(e){this.name="MissingIcon",this.message=e||"Icon unavailable",this.stack=(new Error).stack}fe.prototype=Object.create(Error.prototype),fe.prototype.constructor=fe;var ue={fill:"currentColor"},de={attributeType:"XML",repeatCount:"indefinite",dur:"2s"},me={tag:"path",attributes:c({},ue,{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})},pe=c({},de,{attributeName:"opacity"});c({},ue,{cx:"256",cy:"364",r:"28"}),c({},de,{attributeName:"r",values:"28;14;28;28;14;28;"}),c({},pe,{values:"1;0;1;1;0;1;"}),c({},ue,{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),c({},pe,{values:"1;0;0;0;0;1;"}),c({},ue,{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),c({},pe,{values:"0;0;1;1;0;0;"}),j.styles;function he(e){var t=e[0],n=e[1],r=s(e.slice(4),1)[0];return{found:!0,width:t,height:n,icon:Array.isArray(r)?{tag:"g",attributes:{class:"".concat(k.familyPrefix,"-").concat(O.GROUP)},children:[{tag:"path",attributes:{class:"".concat(k.familyPrefix,"-").concat(O.SECONDARY),fill:"currentColor",d:r[0]}},{tag:"path",attributes:{class:"".concat(k.familyPrefix,"-").concat(O.PRIMARY),fill:"currentColor",d:r[1]}}]}:{tag:"path",attributes:{fill:"currentColor",d:r}}}}j.styles;function ye(){var e="svg-inline--fa",t=k.familyPrefix,n=k.replacementClass,r='svg:not(:root).svg-inline--fa {\n overflow: visible;\n}\n\n.svg-inline--fa {\n display: inline-block;\n font-size: inherit;\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.225em;\n}\n.svg-inline--fa.fa-w-1 {\n width: 0.0625em;\n}\n.svg-inline--fa.fa-w-2 {\n width: 0.125em;\n}\n.svg-inline--fa.fa-w-3 {\n width: 0.1875em;\n}\n.svg-inline--fa.fa-w-4 {\n width: 0.25em;\n}\n.svg-inline--fa.fa-w-5 {\n width: 0.3125em;\n}\n.svg-inline--fa.fa-w-6 {\n width: 0.375em;\n}\n.svg-inline--fa.fa-w-7 {\n width: 0.4375em;\n}\n.svg-inline--fa.fa-w-8 {\n width: 0.5em;\n}\n.svg-inline--fa.fa-w-9 {\n width: 0.5625em;\n}\n.svg-inline--fa.fa-w-10 {\n width: 0.625em;\n}\n.svg-inline--fa.fa-w-11 {\n width: 0.6875em;\n}\n.svg-inline--fa.fa-w-12 {\n width: 0.75em;\n}\n.svg-inline--fa.fa-w-13 {\n width: 0.8125em;\n}\n.svg-inline--fa.fa-w-14 {\n width: 0.875em;\n}\n.svg-inline--fa.fa-w-15 {\n width: 0.9375em;\n}\n.svg-inline--fa.fa-w-16 {\n width: 1em;\n}\n.svg-inline--fa.fa-w-17 {\n width: 1.0625em;\n}\n.svg-inline--fa.fa-w-18 {\n width: 1.125em;\n}\n.svg-inline--fa.fa-w-19 {\n width: 1.1875em;\n}\n.svg-inline--fa.fa-w-20 {\n width: 1.25em;\n}\n.svg-inline--fa.fa-pull-left {\n margin-right: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-pull-right {\n margin-left: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-border {\n height: 1.5em;\n}\n.svg-inline--fa.fa-li {\n width: 2em;\n}\n.svg-inline--fa.fa-fw {\n width: 1.25em;\n}\n\n.fa-layers svg.svg-inline--fa {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: 1em;\n}\n.fa-layers svg.svg-inline--fa {\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n -webkit-transform: translate(-50%, -50%);\n transform: translate(-50%, -50%);\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: #ff253a;\n border-radius: 1em;\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: #fff;\n height: 1.5em;\n line-height: 1;\n max-width: 5em;\n min-width: 1.5em;\n overflow: hidden;\n padding: 0.25em;\n right: 0;\n text-overflow: ellipsis;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: 0;\n right: 0;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom right;\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: 0;\n left: 0;\n right: auto;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom left;\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n right: 0;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: 0;\n right: auto;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top left;\n transform-origin: top left;\n}\n\n.fa-lg {\n font-size: 1.3333333333em;\n line-height: 0.75em;\n vertical-align: -0.0667em;\n}\n\n.fa-xs {\n font-size: 0.75em;\n}\n\n.fa-sm {\n font-size: 0.875em;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-fw {\n text-align: center;\n width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-left: 2.5em;\n padding-left: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n left: -2em;\n position: absolute;\n text-align: center;\n width: 2em;\n line-height: inherit;\n}\n\n.fa-border {\n border: solid 0.08em #eee;\n border-radius: 0.1em;\n padding: 0.2em 0.25em 0.15em;\n}\n\n.fa-pull-left {\n float: left;\n}\n\n.fa-pull-right {\n float: right;\n}\n\n.fa.fa-pull-left,\n.fas.fa-pull-left,\n.far.fa-pull-left,\n.fal.fa-pull-left,\n.fab.fa-pull-left {\n margin-right: 0.3em;\n}\n.fa.fa-pull-right,\n.fas.fa-pull-right,\n.far.fa-pull-right,\n.fal.fa-pull-right,\n.fab.fa-pull-right {\n margin-left: 0.3em;\n}\n\n.fa-spin {\n -webkit-animation: fa-spin 2s infinite linear;\n animation: fa-spin 2s infinite linear;\n}\n\n.fa-pulse {\n -webkit-animation: fa-spin 1s infinite steps(8);\n animation: fa-spin 1s infinite steps(8);\n}\n\n@-webkit-keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n\n@keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";\n -webkit-transform: rotate(90deg);\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";\n -webkit-transform: rotate(180deg);\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";\n -webkit-transform: rotate(270deg);\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";\n -webkit-transform: scale(-1, 1);\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(1, -1);\n transform: scale(1, -1);\n}\n\n.fa-flip-both, .fa-flip-horizontal.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(-1, -1);\n transform: scale(-1, -1);\n}\n\n:root .fa-rotate-90,\n:root .fa-rotate-180,\n:root .fa-rotate-270,\n:root .fa-flip-horizontal,\n:root .fa-flip-vertical,\n:root .fa-flip-both {\n -webkit-filter: none;\n filter: none;\n}\n\n.fa-stack {\n display: inline-block;\n height: 2em;\n position: relative;\n width: 2.5em;\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.svg-inline--fa.fa-stack-1x {\n height: 1em;\n width: 1.25em;\n}\n.svg-inline--fa.fa-stack-2x {\n height: 2em;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: #fff;\n}\n\n.sr-only {\n border: 0;\n clip: rect(0, 0, 0, 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n width: 1px;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n clip: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n position: static;\n width: auto;\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.fad.fa-inverse {\n color: #fff;\n}';if("fa"!==t||n!==e){var a=new RegExp("\\.".concat("fa","\\-"),"g"),i=new RegExp("\\--".concat("fa","\\-"),"g"),o=new RegExp("\\.".concat(e),"g");r=r.replace(a,".".concat(t,"-")).replace(i,"--".concat(t,"-")).replace(o,".".concat(n))}return r}function ge(){k.autoAddCss&&!xe&&(V(ye()),xe=!0)}function be(e,t){return Object.defineProperty(e,"abstract",{get:t}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map((function(e){return se(e)}))}}),Object.defineProperty(e,"node",{get:function(){if(b){var t=y.createElement("div");return t.innerHTML=e.html,t.children}}}),e}function ve(e){var t=e.prefix,n=void 0===t?"fa":t,r=e.iconName;if(r)return ce(Oe.definitions,n,r)||ce(j.styles,n,r)}var we,Oe=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.definitions={}}var t,n,r;return t=e,(n=[{key:"add",value:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r1&&void 0!==arguments[1]?arguments[1]:{},n=t.transform,r=void 0===n?q:n,a=t.symbol,i=void 0!==a&&a,o=t.mask,s=void 0===o?null:o,l=t.maskId,f=void 0===l?null:l,u=t.title,d=void 0===u?null:u,m=t.titleId,p=void 0===m?null:m,h=t.classes,y=void 0===h?[]:h,g=t.attributes,b=void 0===g?{}:g,v=t.styles,w=void 0===v?{}:v;if(e){var O=e.prefix,x=e.iconName,E=e.icon;return be(c({type:"icon"},e),(function(){return ge(),k.autoA11y&&(d?b["aria-labelledby"]="".concat(k.replacementClass,"-title-").concat(p||B()):(b["aria-hidden"]="true",b.focusable="false")),ee({icons:{main:he(E),mask:s?he(s.icon):{found:!1,width:null,height:null,icon:{}}},prefix:O,iconName:x,transform:c({},q,r),symbol:i,title:d,maskId:f,titleId:p,extra:{attributes:b,styles:w,classes:y}})}))}},function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=(e||{}).icon?e:ve(e||{}),r=t.mask;return r&&(r=(r||{}).icon?r:ve(r||{})),we(n,c({},t,{mask:r}))})}).call(this,n(64),n(74).setImmediate)},124:function(e,t,n){"use strict";(function(e,r){var a,i=n(126);a="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==e?e:r;var o=Object(i.a)(a);t.a=o}).call(this,n(64),n(125)(e))},125:function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},126:function(e,t,n){"use strict";function r(e){var t,n=e.Symbol;return"function"==typeof n?n.observable?t=n.observable:(t=n("observable"),n.observable=t):t="@@observable",t}n.d(t,"a",(function(){return r}))},148:function(e,t,n){"use strict";var r;function a(e){return{type:r.updateTranslations,translations:e}}function i(e){return{type:r.updateConfig,config:e}}n.r(t),n.d(t,"ReduxActionTypes",(function(){return r})),n.d(t,"updateTranslations",(function(){return a})),n.d(t,"updateConfig",(function(){return i})),function(e){e.updateTranslations="UPDATE_MOLLIE_CARRIER_TRANSLATIONS",e.updateConfig="UPDATE_MOLLIE_CARRIER_CONFIG"}(r||(r={}))},195:function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return h}));n(23),n(72),n(69),n(70),n(71),n(22),n(61),n(66),n(67),n(24),n(65);var r=n(56),a=n.n(r),i=n(76),o=n.n(i),c=n(63),s=n(79),l=n(88);function f(e,t,n,r,a,i,o){try{var c=e[i](o),s=c.value}catch(e){return void n(e)}c.done?t(s):Promise.resolve(s).then(r,a)}function u(e){return function(){var t=this,n=arguments;return new Promise((function(r,a){var i=e.apply(t,n);function o(e){f(i,r,a,o,c,"next",e)}function c(e){f(i,r,a,o,c,"throw",e)}o(void 0)}))}}function d(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,a=!1,i=void 0;try{for(var o,c=e[Symbol.iterator]();!(r=(o=c.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){a=!0,i=e}finally{try{r||null==c.return||c.return()}finally{if(a)throw i}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return m(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return m(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function m(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case i.ReduxActionTypes.updateTranslations:return t.translations;default:return e}},config:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case i.ReduxActionTypes.updateConfig:return t.config;default:return e}}}),c=window.__REDUX_DEVTOOLS_EXTENSION__;r=Object(a.b)(o,c&&c());t.default=r},52:function(e,t,n){"use strict";n.r(t);n(69),n(65),n(70),n(71),n(66),n(67),n(23),n(61),n(68),n(22),n(72),n(24);var r=n(56),a=n.n(r),i=n(59),o=n(84);function c(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,a=!1,i=void 0;try{for(var o,c=e[Symbol.iterator]();!(r=(o=c.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){a=!0,i=e}finally{try{r||null==c.return||c.return()}finally{if(a)throw i}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return s(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n")||this}return function(e,t){function n(){this.constructor=e}a(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}(t,e),t}(Error);function f(e){return e+1}var u=(c=function(){var e=Object(r.createContext)(null);return{StoreContext:e,useDispatch:function(){var t=Object(r.useContext)(e);if(!t)throw new l;return t.dispatch},useMappedState:function(t){var n=Object(r.useContext)(e);if(!n)throw new l;var a=Object(r.useMemo)((function(){return e=t,function(t){return r!==t&&(r=t,n=e(t)),n};var e,n,r}),[t]),c=n.getState(),u=a(c),d=Object(r.useState)(0)[1],m=Object(r.useRef)(u),p=Object(r.useRef)(a);return s((function(){m.current=u,p.current=a})),s((function(){var e=!1,t=function(){e||(function(e,t){if(o(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var a=0;a=0&&(e._idleTimeoutId=setTimeout((function(){e._onTimeout&&e._onTimeout()}),t))},n(78),t.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||this&&this.setImmediate,t.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||this&&this.clearImmediate}).call(this,n(64))},76:function(e,t,n){var r; -/*! - Copyright (c) 2017 Jed Watson. - Licensed under the MIT License (MIT), see - http://jedwatson.github.io/classnames +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ +(window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["carrierconfig"],{101:function(e,t,n){"use strict";n.d(t,"a",(function(){return l})),n.d(t,"b",(function(){return c}));var r=n(124),a=function(){return Math.random().toString(36).substring(7).split("").join(".")},i={INIT:"@@redux/INIT"+a(),REPLACE:"@@redux/REPLACE"+a(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+a()}};function o(e){if("object"!=typeof e||null===e)return!1;for(var t=e;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function c(e,t,n){var a;if("function"==typeof t&&"function"==typeof n||"function"==typeof n&&"function"==typeof arguments[3])throw new Error("It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function.");if("function"==typeof t&&void 0===n&&(n=t,t=void 0),void 0!==n){if("function"!=typeof n)throw new Error("Expected the enhancer to be a function.");return n(c)(e,t)}if("function"!=typeof e)throw new Error("Expected the reducer to be a function.");var s=e,l=t,f=[],u=f,d=!1;function m(){u===f&&(u=f.slice())}function p(){if(d)throw new Error("You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return l}function h(e){if("function"!=typeof e)throw new Error("Expected the listener to be a function.");if(d)throw new Error("You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api-reference/store#subscribelistener for more details.");var t=!0;return m(),u.push(e),function(){if(t){if(d)throw new Error("You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api-reference/store#subscribelistener for more details.");t=!1,m();var n=u.indexOf(e);u.splice(n,1),f=null}}}function y(e){if(!o(e))throw new Error("Actions must be plain objects. Use custom middleware for async actions.");if(void 0===e.type)throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?');if(d)throw new Error("Reducers may not dispatch actions.");try{d=!0,l=s(l,e)}finally{d=!1}for(var t=f=u,n=0;n-1;a--){var i=n[a],o=(i.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(o)>-1&&(r=i)}return y.head.insertBefore(t,r),e}}function B(){for(var e=12,t="";e-- >0;)t+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[62*Math.random()|0];return t}function G(e){return"".concat(e).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(//g,">")}function J(e){return Object.keys(e||{}).reduce((function(t,n){return t+"".concat(n,": ").concat(e[n],";")}),"")}function K(e){return e.size!==q.size||e.x!==q.x||e.y!==q.y||e.rotate!==q.rotate||e.flipX||e.flipY}function $(e){var t=e.transform,n=e.containerWidth,r=e.iconWidth,a={transform:"translate(".concat(n/2," 256)")},i="translate(".concat(32*t.x,", ").concat(32*t.y,") "),o="scale(".concat(t.size/16*(t.flipX?-1:1),", ").concat(t.size/16*(t.flipY?-1:1),") "),c="rotate(".concat(t.rotate," 0 0)");return{outer:a,inner:{transform:"".concat(i," ").concat(o," ").concat(c)},path:{transform:"translate(".concat(r/2*-1," -256)")}}}var Q={x:0,y:0,width:"100%",height:"100%"};function Z(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return e.attributes&&(e.attributes.fill||t)&&(e.attributes.fill="black"),e}function ee(e){var t=e.icons,n=t.main,r=t.mask,a=e.prefix,i=e.iconName,o=e.transform,s=e.symbol,l=e.title,f=e.maskId,u=e.titleId,d=e.extra,m=e.watchable,p=void 0!==m&&m,h=r.found?r:n,y=h.width,g=h.height,b="fa-w-".concat(Math.ceil(y/g*16)),v=[k.replacementClass,i?"".concat(k.familyPrefix,"-").concat(i):"",b].filter((function(e){return-1===d.classes.indexOf(e)})).concat(d.classes).join(" "),w={children:[],attributes:c({},d.attributes,{"data-prefix":a,"data-icon":i,class:v,role:d.attributes.role||"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(y," ").concat(g)})};p&&(w.attributes["data-fa-i2svg"]=""),l&&w.children.push({tag:"title",attributes:{id:w.attributes["aria-labelledby"]||"title-".concat(u||B())},children:[l]});var O=c({},w,{prefix:a,iconName:i,main:n,mask:r,maskId:f,transform:o,symbol:s,styles:d.styles}),x=r.found&&n.found?function(e){var t,n=e.children,r=e.attributes,a=e.main,i=e.mask,o=e.maskId,s=e.transform,l=a.width,f=a.icon,u=i.width,d=i.icon,m=$({transform:s,containerWidth:u,iconWidth:l}),p={tag:"rect",attributes:c({},Q,{fill:"white"})},h=f.children?{children:f.children.map(Z)}:{},y={tag:"g",attributes:c({},m.inner),children:[Z(c({tag:f.tag,attributes:c({},f.attributes,m.path)},h))]},g={tag:"g",attributes:c({},m.outer),children:[y]},b="mask-".concat(o||B()),v="clip-".concat(o||B()),w={tag:"mask",attributes:c({},Q,{id:b,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[p,g]},O={tag:"defs",children:[{tag:"clipPath",attributes:{id:v},children:(t=d,"g"===t.tag?t.children:[t])},w]};return n.push(O,{tag:"rect",attributes:c({fill:"currentColor","clip-path":"url(#".concat(v,")"),mask:"url(#".concat(b,")")},Q)}),{children:n,attributes:r}}(O):function(e){var t=e.children,n=e.attributes,r=e.main,a=e.transform,i=J(e.styles);if(i.length>0&&(n.style=i),K(a)){var o=$({transform:a,containerWidth:r.width,iconWidth:r.width});t.push({tag:"g",attributes:c({},o.outer),children:[{tag:"g",attributes:c({},o.inner),children:[{tag:r.icon.tag,children:r.icon.children,attributes:c({},r.icon.attributes,o.path)}]}]})}else t.push(r.icon);return{children:t,attributes:n}}(O),E=x.children,_=x.attributes;return O.children=E,O.attributes=_,s?function(e){var t=e.prefix,n=e.iconName,r=e.children,a=e.attributes,i=e.symbol;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:c({},a,{id:!0===i?"".concat(t,"-").concat(k.familyPrefix,"-").concat(n):i}),children:r}]}]}(O):function(e){var t=e.children,n=e.main,r=e.mask,a=e.attributes,i=e.styles,o=e.transform;if(K(o)&&n.found&&!r.found){var s={x:n.width/n.height/2,y:.5};a.style=J(c({},i,{"transform-origin":"".concat(s.x+o.x/16,"em ").concat(s.y+o.y/16,"em")}))}return[{tag:"svg",attributes:a,children:t}]}(O)}var te=function(){},ne=(k.measurePerformance&&g&&g.mark&&g.measure,function(e,t,n,r){var a,i,o,c=Object.keys(e),s=c.length,l=void 0!==r?function(e,t){return function(n,r,a,i){return e.call(t,n,r,a,i)}}(t,r):t;for(void 0===n?(a=1,o=e[c[0]]):(a=0,o=n);a2&&void 0!==arguments[2]?arguments[2]:{},r=n.skipHooks,a=void 0!==r&&r,i=Object.keys(t).reduce((function(e,n){var r=t[n];return!!r.icon?e[r.iconName]=r.icon:e[n]=r,e}),{});"function"!=typeof j.hooks.addPack||a?j.styles[e]=c({},j.styles[e]||{},i):j.hooks.addPack(e,i),"fas"===e&&re("fa",t)}var ae=j.styles,ie=j.shims,oe=function(){var e=function(e){return ne(ae,(function(t,n,r){return t[r]=ne(n,e,{}),t}),{})};e((function(e,t,n){return t[3]&&(e[t[3]]=n),e})),e((function(e,t,n){var r=t[2];return e[n]=n,r.forEach((function(t){e[t]=n})),e}));var t="far"in ae;ne(ie,(function(e,n){var r=n[0],a=n[1],i=n[2];return"far"!==a||t||(a="fas"),e[r]={prefix:a,iconName:i},e}),{})};oe();j.styles;function ce(e,t,n){if(e&&e[t]&&e[t][n])return{prefix:t,iconName:n,icon:e[t][n]}}function se(e){var t=e.tag,n=e.attributes,r=void 0===n?{}:n,a=e.children,i=void 0===a?[]:a;return"string"==typeof e?G(e):"<".concat(t," ").concat(function(e){return Object.keys(e||{}).reduce((function(t,n){return t+"".concat(n,'="').concat(G(e[n]),'" ')}),"").trim()}(r),">").concat(i.map(se).join(""),"")}var le=function(e){var t={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0};return e?e.toLowerCase().split(" ").reduce((function(e,t){var n=t.toLowerCase().split("-"),r=n[0],a=n.slice(1).join("-");if(r&&"h"===a)return e.flipX=!0,e;if(r&&"v"===a)return e.flipY=!0,e;if(a=parseFloat(a),isNaN(a))return e;switch(r){case"grow":e.size=e.size+a;break;case"shrink":e.size=e.size-a;break;case"left":e.x=e.x-a;break;case"right":e.x=e.x+a;break;case"up":e.y=e.y-a;break;case"down":e.y=e.y+a;break;case"rotate":e.rotate=e.rotate+a}return e}),t):t};function fe(e){this.name="MissingIcon",this.message=e||"Icon unavailable",this.stack=(new Error).stack}fe.prototype=Object.create(Error.prototype),fe.prototype.constructor=fe;var ue={fill:"currentColor"},de={attributeType:"XML",repeatCount:"indefinite",dur:"2s"},me={tag:"path",attributes:c({},ue,{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})},pe=c({},de,{attributeName:"opacity"});c({},ue,{cx:"256",cy:"364",r:"28"}),c({},de,{attributeName:"r",values:"28;14;28;28;14;28;"}),c({},pe,{values:"1;0;1;1;0;1;"}),c({},ue,{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),c({},pe,{values:"1;0;0;0;0;1;"}),c({},ue,{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),c({},pe,{values:"0;0;1;1;0;0;"}),j.styles;function he(e){var t=e[0],n=e[1],r=s(e.slice(4),1)[0];return{found:!0,width:t,height:n,icon:Array.isArray(r)?{tag:"g",attributes:{class:"".concat(k.familyPrefix,"-").concat(O.GROUP)},children:[{tag:"path",attributes:{class:"".concat(k.familyPrefix,"-").concat(O.SECONDARY),fill:"currentColor",d:r[0]}},{tag:"path",attributes:{class:"".concat(k.familyPrefix,"-").concat(O.PRIMARY),fill:"currentColor",d:r[1]}}]}:{tag:"path",attributes:{fill:"currentColor",d:r}}}}j.styles;function ye(){var e="svg-inline--fa",t=k.familyPrefix,n=k.replacementClass,r='svg:not(:root).svg-inline--fa {\n overflow: visible;\n}\n\n.svg-inline--fa {\n display: inline-block;\n font-size: inherit;\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.225em;\n}\n.svg-inline--fa.fa-w-1 {\n width: 0.0625em;\n}\n.svg-inline--fa.fa-w-2 {\n width: 0.125em;\n}\n.svg-inline--fa.fa-w-3 {\n width: 0.1875em;\n}\n.svg-inline--fa.fa-w-4 {\n width: 0.25em;\n}\n.svg-inline--fa.fa-w-5 {\n width: 0.3125em;\n}\n.svg-inline--fa.fa-w-6 {\n width: 0.375em;\n}\n.svg-inline--fa.fa-w-7 {\n width: 0.4375em;\n}\n.svg-inline--fa.fa-w-8 {\n width: 0.5em;\n}\n.svg-inline--fa.fa-w-9 {\n width: 0.5625em;\n}\n.svg-inline--fa.fa-w-10 {\n width: 0.625em;\n}\n.svg-inline--fa.fa-w-11 {\n width: 0.6875em;\n}\n.svg-inline--fa.fa-w-12 {\n width: 0.75em;\n}\n.svg-inline--fa.fa-w-13 {\n width: 0.8125em;\n}\n.svg-inline--fa.fa-w-14 {\n width: 0.875em;\n}\n.svg-inline--fa.fa-w-15 {\n width: 0.9375em;\n}\n.svg-inline--fa.fa-w-16 {\n width: 1em;\n}\n.svg-inline--fa.fa-w-17 {\n width: 1.0625em;\n}\n.svg-inline--fa.fa-w-18 {\n width: 1.125em;\n}\n.svg-inline--fa.fa-w-19 {\n width: 1.1875em;\n}\n.svg-inline--fa.fa-w-20 {\n width: 1.25em;\n}\n.svg-inline--fa.fa-pull-left {\n margin-right: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-pull-right {\n margin-left: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-border {\n height: 1.5em;\n}\n.svg-inline--fa.fa-li {\n width: 2em;\n}\n.svg-inline--fa.fa-fw {\n width: 1.25em;\n}\n\n.fa-layers svg.svg-inline--fa {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: 1em;\n}\n.fa-layers svg.svg-inline--fa {\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n -webkit-transform: translate(-50%, -50%);\n transform: translate(-50%, -50%);\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: #ff253a;\n border-radius: 1em;\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: #fff;\n height: 1.5em;\n line-height: 1;\n max-width: 5em;\n min-width: 1.5em;\n overflow: hidden;\n padding: 0.25em;\n right: 0;\n text-overflow: ellipsis;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: 0;\n right: 0;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom right;\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: 0;\n left: 0;\n right: auto;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom left;\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n right: 0;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: 0;\n right: auto;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top left;\n transform-origin: top left;\n}\n\n.fa-lg {\n font-size: 1.3333333333em;\n line-height: 0.75em;\n vertical-align: -0.0667em;\n}\n\n.fa-xs {\n font-size: 0.75em;\n}\n\n.fa-sm {\n font-size: 0.875em;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-fw {\n text-align: center;\n width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-left: 2.5em;\n padding-left: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n left: -2em;\n position: absolute;\n text-align: center;\n width: 2em;\n line-height: inherit;\n}\n\n.fa-border {\n border: solid 0.08em #eee;\n border-radius: 0.1em;\n padding: 0.2em 0.25em 0.15em;\n}\n\n.fa-pull-left {\n float: left;\n}\n\n.fa-pull-right {\n float: right;\n}\n\n.fa.fa-pull-left,\n.fas.fa-pull-left,\n.far.fa-pull-left,\n.fal.fa-pull-left,\n.fab.fa-pull-left {\n margin-right: 0.3em;\n}\n.fa.fa-pull-right,\n.fas.fa-pull-right,\n.far.fa-pull-right,\n.fal.fa-pull-right,\n.fab.fa-pull-right {\n margin-left: 0.3em;\n}\n\n.fa-spin {\n -webkit-animation: fa-spin 2s infinite linear;\n animation: fa-spin 2s infinite linear;\n}\n\n.fa-pulse {\n -webkit-animation: fa-spin 1s infinite steps(8);\n animation: fa-spin 1s infinite steps(8);\n}\n\n@-webkit-keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n\n@keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";\n -webkit-transform: rotate(90deg);\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";\n -webkit-transform: rotate(180deg);\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";\n -webkit-transform: rotate(270deg);\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";\n -webkit-transform: scale(-1, 1);\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(1, -1);\n transform: scale(1, -1);\n}\n\n.fa-flip-both, .fa-flip-horizontal.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(-1, -1);\n transform: scale(-1, -1);\n}\n\n:root .fa-rotate-90,\n:root .fa-rotate-180,\n:root .fa-rotate-270,\n:root .fa-flip-horizontal,\n:root .fa-flip-vertical,\n:root .fa-flip-both {\n -webkit-filter: none;\n filter: none;\n}\n\n.fa-stack {\n display: inline-block;\n height: 2em;\n position: relative;\n width: 2.5em;\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.svg-inline--fa.fa-stack-1x {\n height: 1em;\n width: 1.25em;\n}\n.svg-inline--fa.fa-stack-2x {\n height: 2em;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: #fff;\n}\n\n.sr-only {\n border: 0;\n clip: rect(0, 0, 0, 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n width: 1px;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n clip: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n position: static;\n width: auto;\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.fad.fa-inverse {\n color: #fff;\n}';if("fa"!==t||n!==e){var a=new RegExp("\\.".concat("fa","\\-"),"g"),i=new RegExp("\\--".concat("fa","\\-"),"g"),o=new RegExp("\\.".concat(e),"g");r=r.replace(a,".".concat(t,"-")).replace(i,"--".concat(t,"-")).replace(o,".".concat(n))}return r}function ge(){k.autoAddCss&&!xe&&(V(ye()),xe=!0)}function be(e,t){return Object.defineProperty(e,"abstract",{get:t}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map((function(e){return se(e)}))}}),Object.defineProperty(e,"node",{get:function(){if(b){var t=y.createElement("div");return t.innerHTML=e.html,t.children}}}),e}function ve(e){var t=e.prefix,n=void 0===t?"fa":t,r=e.iconName;if(r)return ce(Oe.definitions,n,r)||ce(j.styles,n,r)}var we,Oe=new(function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.definitions={}}var t,n,r;return t=e,(n=[{key:"add",value:function(){for(var e=this,t=arguments.length,n=new Array(t),r=0;r1&&void 0!==arguments[1]?arguments[1]:{},n=t.transform,r=void 0===n?q:n,a=t.symbol,i=void 0!==a&&a,o=t.mask,s=void 0===o?null:o,l=t.maskId,f=void 0===l?null:l,u=t.title,d=void 0===u?null:u,m=t.titleId,p=void 0===m?null:m,h=t.classes,y=void 0===h?[]:h,g=t.attributes,b=void 0===g?{}:g,v=t.styles,w=void 0===v?{}:v;if(e){var O=e.prefix,x=e.iconName,E=e.icon;return be(c({type:"icon"},e),(function(){return ge(),k.autoA11y&&(d?b["aria-labelledby"]="".concat(k.replacementClass,"-title-").concat(p||B()):(b["aria-hidden"]="true",b.focusable="false")),ee({icons:{main:he(E),mask:s?he(s.icon):{found:!1,width:null,height:null,icon:{}}},prefix:O,iconName:x,transform:c({},q,r),symbol:i,title:d,maskId:f,titleId:p,extra:{attributes:b,styles:w,classes:y}})}))}},function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=(e||{}).icon?e:ve(e||{}),r=t.mask;return r&&(r=(r||{}).icon?r:ve(r||{})),we(n,c({},t,{mask:r}))})}).call(this,n(64),n(74).setImmediate)},124:function(e,t,n){"use strict";(function(e,r){var a,i=n(126);a="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==e?e:r;var o=Object(i.a)(a);t.a=o}).call(this,n(64),n(125)(e))},125:function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},126:function(e,t,n){"use strict";function r(e){var t,n=e.Symbol;return"function"==typeof n?n.observable?t=n.observable:(t=n("observable"),n.observable=t):t="@@observable",t}n.d(t,"a",(function(){return r}))},148:function(e,t,n){"use strict";var r;function a(e){return{type:r.updateTranslations,translations:e}}function i(e){return{type:r.updateConfig,config:e}}n.r(t),n.d(t,"ReduxActionTypes",(function(){return r})),n.d(t,"updateTranslations",(function(){return a})),n.d(t,"updateConfig",(function(){return i})),function(e){e.updateTranslations="UPDATE_MOLLIE_CARRIER_TRANSLATIONS",e.updateConfig="UPDATE_MOLLIE_CARRIER_CONFIG"}(r||(r={}))},195:function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return h}));n(23),n(72),n(69),n(70),n(71),n(22),n(61),n(66),n(67),n(24),n(65);var r=n(56),a=n.n(r),i=n(76),o=n.n(i),c=n(63),s=n(79),l=n(88);function f(e,t,n,r,a,i,o){try{var c=e[i](o),s=c.value}catch(e){return void n(e)}c.done?t(s):Promise.resolve(s).then(r,a)}function u(e){return function(){var t=this,n=arguments;return new Promise((function(r,a){var i=e.apply(t,n);function o(e){f(i,r,a,o,c,"next",e)}function c(e){f(i,r,a,o,c,"throw",e)}o(void 0)}))}}function d(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,a=!1,i=void 0;try{for(var o,c=e[Symbol.iterator]();!(r=(o=c.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){a=!0,i=e}finally{try{r||null==c.return||c.return()}finally{if(a)throw i}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return m(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return m(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function m(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case i.ReduxActionTypes.updateTranslations:return t.translations;default:return e}},config:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case i.ReduxActionTypes.updateConfig:return t.config;default:return e}}}),c=window.__REDUX_DEVTOOLS_EXTENSION__;r=Object(a.b)(o,c&&c());t.default=r},52:function(e,t,n){"use strict";n.r(t);n(69),n(65),n(70),n(71),n(66),n(67),n(23),n(61),n(68),n(22),n(72),n(24);var r=n(56),a=n.n(r),i=n(59),o=n(84);function c(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,a=!1,i=void 0;try{for(var o,c=e[Symbol.iterator]();!(r=(o=c.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(e){a=!0,i=e}finally{try{r||null==c.return||c.return()}finally{if(a)throw i}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return s(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n")||this}return function(e,t){function n(){this.constructor=e}a(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}(t,e),t}(Error);function f(e){return e+1}var u=(c=function(){var e=Object(r.createContext)(null);return{StoreContext:e,useDispatch:function(){var t=Object(r.useContext)(e);if(!t)throw new l;return t.dispatch},useMappedState:function(t){var n=Object(r.useContext)(e);if(!n)throw new l;var a=Object(r.useMemo)((function(){return e=t,function(t){return r!==t&&(r=t,n=e(t)),n};var e,n,r}),[t]),c=n.getState(),u=a(c),d=Object(r.useState)(0)[1],m=Object(r.useRef)(u),p=Object(r.useRef)(a);return s((function(){m.current=u,p.current=a})),s((function(){var e=!1,t=function(){e||(function(e,t){if(o(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(var a=0;a=0&&(e._idleTimeoutId=setTimeout((function(){e._onTimeout&&e._onTimeout()}),t))},n(78),t.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||this&&this.setImmediate,t.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||this&&this.clearImmediate}).call(this,n(64))},76:function(e,t,n){var r; +/*! + Copyright (c) 2017 Jed Watson. + Licensed under the MIT License (MIT), see + http://jedwatson.github.io/classnames */!function(){"use strict";var n={}.hasOwnProperty;function a(){for(var e=[],t=0;t=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}function m(e){return function(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t0||!Array.isArray(t)&&t?l({},e,t):{}}function v(e){var t=e.icon,n=e.mask,a=e.symbol,i=e.className,o=e.title,c=g(t),s=b("classes",[].concat(m(function(e){var t,n=e.spin,r=e.pulse,a=e.fixedWidth,i=e.inverse,o=e.border,c=e.listItem,s=e.flip,f=e.size,u=e.rotation,d=e.pull,m=(l(t={"fa-spin":n,"fa-pulse":r,"fa-fw":a,"fa-inverse":i,"fa-border":o,"fa-li":c,"fa-flip-horizontal":"horizontal"===s||"both"===s,"fa-flip-vertical":"vertical"===s||"both"===s},"fa-".concat(f),null!=f),l(t,"fa-rotate-".concat(u),null!=u),l(t,"fa-pull-".concat(d),null!=d),l(t,"fa-swap-opacity",e.swapOpacity),t);return Object.keys(m).map((function(e){return m[e]?e:null})).filter((function(e){return e}))}(e)),m(i.split(" ")))),f=b("transform","string"==typeof e.transform?r.b.transform(e.transform):e.transform),d=b("mask",g(n)),p=Object(r.a)(c,u({},s,{},f,{},d,{symbol:a,title:o}));if(!p)return function(){var e;!y&&console&&"function"==typeof console.error&&(e=console).error.apply(e,arguments)}("Could not find icon",c),null;var h=p.abstract,O={};return Object.keys(e).forEach((function(t){v.defaultProps.hasOwnProperty(t)||(O[t]=e[t])})),w(h[0],O)}v.displayName="FontAwesomeIcon",v.propTypes={border:i.a.bool,className:i.a.string,mask:i.a.oneOfType([i.a.object,i.a.array,i.a.string]),fixedWidth:i.a.bool,inverse:i.a.bool,flip:i.a.oneOf(["horizontal","vertical","both"]),icon:i.a.oneOfType([i.a.object,i.a.array,i.a.string]),listItem:i.a.bool,pull:i.a.oneOf(["right","left"]),pulse:i.a.bool,rotation:i.a.oneOf([90,180,270]),size:i.a.oneOf(["lg","xs","sm","1x","2x","3x","4x","5x","6x","7x","8x","9x","10x"]),spin:i.a.bool,symbol:i.a.oneOfType([i.a.bool,i.a.string]),title:i.a.string,transform:i.a.oneOfType([i.a.string,i.a.object]),swapOpacity:i.a.bool},v.defaultProps={border:!1,className:"",mask:null,fixedWidth:!1,inverse:!1,flip:null,icon:null,listItem:!1,pull:null,pulse:!1,rotation:null,size:null,spin:!1,symbol:!1,title:"",transform:null,swapOpacity:!1};var w=function e(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if("string"==typeof n)return n;var a=(n.children||[]).map((function(n){return e(t,n)})),i=Object.keys(n.attributes||{}).reduce((function(e,t){var r=n.attributes[t];switch(t){case"class":e.attrs.className=r,delete n.attributes.class;break;case"style":e.attrs.style=h(r);break;default:0===t.indexOf("aria-")||0===t.indexOf("data-")?e.attrs[t.toLowerCase()]=r:e.attrs[p(t)]=r}return e}),{attrs:{}}),o=r.style,c=void 0===o?{}:o,s=d(r,["style"]);return i.attrs.style=u({},i.attrs.style,{},c),t.apply(void 0,[n.tag,u({},i.attrs,{},s)].concat(m(a)))}.bind(null,c.a.createElement)},82:function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a})),n.d(t,"c",(function(){return i})),n.d(t,"d",(function(){return o})),n.d(t,"e",(function(){return c})),n.d(t,"f",(function(){return s})),n.d(t,"g",(function(){return l})),n.d(t,"h",(function(){return f})),n.d(t,"i",(function(){return u})),n.d(t,"j",(function(){return d}));var r={prefix:"fas",iconName:"chevron-down",icon:[448,512,[],"f078","M207.029 381.476L12.686 187.132c-9.373-9.373-9.373-24.569 0-33.941l22.667-22.667c9.357-9.357 24.522-9.375 33.901-.04L224 284.505l154.745-154.021c9.379-9.335 24.544-9.317 33.901.04l22.667 22.667c9.373 9.373 9.373 24.569 0 33.941L240.971 381.476c-9.373 9.372-24.569 9.372-33.942 0z"]},a={prefix:"fas",iconName:"chevron-up",icon:[448,512,[],"f077","M240.971 130.524l194.343 194.343c9.373 9.373 9.373 24.569 0 33.941l-22.667 22.667c-9.357 9.357-24.522 9.375-33.901.04L224 227.495 69.255 381.516c-9.379 9.335-24.544 9.317-33.901-.04l-22.667-22.667c-9.373-9.373-9.373-24.569 0-33.941L207.03 130.525c9.372-9.373 24.568-9.373 33.941-.001z"]},i={prefix:"fas",iconName:"circle-notch",icon:[512,512,[],"f1ce","M288 39.056v16.659c0 10.804 7.281 20.159 17.686 23.066C383.204 100.434 440 171.518 440 256c0 101.689-82.295 184-184 184-101.689 0-184-82.295-184-184 0-84.47 56.786-155.564 134.312-177.219C216.719 75.874 224 66.517 224 55.712V39.064c0-15.709-14.834-27.153-30.046-23.234C86.603 43.482 7.394 141.206 8.003 257.332c.72 137.052 111.477 246.956 248.531 246.667C393.255 503.711 504 392.788 504 256c0-115.633-79.14-212.779-186.211-240.236C302.678 11.889 288 23.456 288 39.056z"]},o={prefix:"fas",iconName:"exclamation-triangle",icon:[576,512,[],"f071","M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"]},c={prefix:"fas",iconName:"redo-alt",icon:[512,512,[],"f2f9","M256.455 8c66.269.119 126.437 26.233 170.859 68.685l35.715-35.715C478.149 25.851 504 36.559 504 57.941V192c0 13.255-10.745 24-24 24H345.941c-21.382 0-32.09-25.851-16.971-40.971l41.75-41.75c-30.864-28.899-70.801-44.907-113.23-45.273-92.398-.798-170.283 73.977-169.484 169.442C88.764 348.009 162.184 424 256 424c41.127 0 79.997-14.678 110.629-41.556 4.743-4.161 11.906-3.908 16.368.553l39.662 39.662c4.872 4.872 4.631 12.815-.482 17.433C378.202 479.813 319.926 504 256 504 119.034 504 8.001 392.967 8 256.002 7.999 119.193 119.646 7.755 256.455 8z"]},s={prefix:"fas",iconName:"times",icon:[352,512,[],"f00d","M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z"]},l={prefix:"fas",iconName:"times-circle",icon:[512,512,[],"f057","M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zm121.6 313.1c4.7 4.7 4.7 12.3 0 17L338 377.6c-4.7 4.7-12.3 4.7-17 0L256 312l-65.1 65.6c-4.7 4.7-12.3 4.7-17 0L134.4 338c-4.7-4.7-4.7-12.3 0-17l65.6-65-65.6-65.1c-4.7-4.7-4.7-12.3 0-17l39.6-39.6c4.7-4.7 12.3-4.7 17 0l65 65.7 65.1-65.6c4.7-4.7 12.3-4.7 17 0l39.6 39.6c4.7 4.7 4.7 12.3 0 17L312 256l65.6 65.1z"]},f={prefix:"fas",iconName:"truck",icon:[640,512,[],"f0d1","M624 352h-16V243.9c0-12.7-5.1-24.9-14.1-33.9L494 110.1c-9-9-21.2-14.1-33.9-14.1H416V48c0-26.5-21.5-48-48-48H48C21.5 0 0 21.5 0 48v320c0 26.5 21.5 48 48 48h16c0 53 43 96 96 96s96-43 96-96h128c0 53 43 96 96 96s96-43 96-96h48c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zM160 464c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zm320 0c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zm80-208H416V144h44.1l99.9 99.9V256z"]},u={prefix:"fas",iconName:"undo",icon:[512,512,[],"f0e2","M212.333 224.333H12c-6.627 0-12-5.373-12-12V12C0 5.373 5.373 0 12 0h48c6.627 0 12 5.373 12 12v78.112C117.773 39.279 184.26 7.47 258.175 8.007c136.906.994 246.448 111.623 246.157 248.532C504.041 393.258 393.12 504 256.333 504c-64.089 0-122.496-24.313-166.51-64.215-5.099-4.622-5.334-12.554-.467-17.42l33.967-33.967c4.474-4.474 11.662-4.717 16.401-.525C170.76 415.336 211.58 432 256.333 432c97.268 0 176-78.716 176-176 0-97.267-78.716-176-176-176-58.496 0-110.28 28.476-142.274 72.333h98.274c6.627 0 12 5.373 12 12v48c0 6.627-5.373 12-12 12z"]},d={prefix:"fas",iconName:"undo-alt",icon:[512,512,[],"f2ea","M255.545 8c-66.269.119-126.438 26.233-170.86 68.685L48.971 40.971C33.851 25.851 8 36.559 8 57.941V192c0 13.255 10.745 24 24 24h134.059c21.382 0 32.09-25.851 16.971-40.971l-41.75-41.75c30.864-28.899 70.801-44.907 113.23-45.273 92.398-.798 170.283 73.977 169.484 169.442C423.236 348.009 349.816 424 256 424c-41.127 0-79.997-14.678-110.63-41.556-4.743-4.161-11.906-3.908-16.368.553L89.34 422.659c-4.872 4.872-4.631 12.815.482 17.433C133.798 479.813 192.074 504 256 504c136.966 0 247.999-111.033 248-247.998C504.001 119.193 392.354 7.755 255.545 8z"]}},88:function(e,t,n){"use strict";n(62);var r=n(56),a=n.n(r),i=n(60);function o(){var e=l(["\n background-color: black;\n border-radius: 50%;\n width: 10px;\n height: 10px;\n margin: 0 5px;\n opacity: 0.7;\n /* Animation */\n animation: "," 0.5s linear infinite;\n animation-delay: ",";\n"]);return o=function(){return e},e}function c(){var e=l(["\n display: flex;\n align-items: flex-end;\n min-height: 30px;\n"]);return c=function(){return e},e}function s(){var e=l(["\n 0% { margin-bottom: 0; }\n 50% { margin-bottom: 15px }\n 100% { margin-bottom: 0 }\n"]);return s=function(){return e},e}function l(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var f=Object(i.keyframes)(s()),u=i.default.div(c()),d=i.default.div(o(),f,(function(e){return e.delay}));t.a=function(){return a.a.createElement(u,null,a.a.createElement(d,{delay:"0s"}),a.a.createElement(d,{delay:".1s"}),a.a.createElement(d,{delay:".2s"}))}}}]); \ No newline at end of file diff --git a/views/js/dist/index.php b/views/js/dist/index.php index 97775fe0f..d4a3735f7 100644 --- a/views/js/dist/index.php +++ b/views/js/dist/index.php @@ -1,36 +1,36 @@ - -* @copyright 2007-2016 PrestaShop SA -* @version Release: $Revision$ -* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -* International Registered Trademark & Property of PrestaShop SA -*/ - -header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); - -header("Cache-Control: no-store, no-cache, must-revalidate"); -header("Cache-Control: post-check=0, pre-check=0", false); -header("Pragma: no-cache"); - -header("Location: ../"); -exit; + +* @copyright 2007-2016 PrestaShop SA +* @version Release: $Revision$ +* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) +* International Registered Trademark & Property of PrestaShop SA +*/ + +header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); +header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT"); + +header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: post-check=0, pre-check=0", false); +header("Pragma: no-cache"); + +header("Location: ../"); +exit; diff --git a/views/js/dist/manifest.php b/views/js/dist/manifest.php index 1d4090b03..2f0c7c1ce 100644 --- a/views/js/dist/manifest.php +++ b/views/js/dist/manifest.php @@ -1,36 +1,36 @@ - - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - * @codingStandardsIgnoreStart - */ - -return json_decode("[{\"name\":\"app\",\"files\":[\"vendors~app.min.js\",\"app.min.js\"]}]", true); + + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + * @codingStandardsIgnoreStart + */ + +return json_decode("[{\"name\":\"app\",\"files\":[\"vendors~app.min.js\",\"app.min.js\"]}]", true); diff --git a/views/js/dist/methodconfig.min.js b/views/js/dist/methodconfig.min.js index da38cfb26..53472a79f 100644 --- a/views/js/dist/methodconfig.min.js +++ b/views/js/dist/methodconfig.min.js @@ -1,38 +1,38 @@ -/*! - * Copyright (c) 2012-2020, Mollie B.V. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * - Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH - * DAMAGE. - * - * @author Mollie B.V. - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ -(window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["methodconfig"],{100:function(e,n,t){var r=t(3),a=t(10),o=t(1)("match");e.exports=function(e){var n;return r(e)&&(void 0!==(n=e[o])?!!n:"RegExp"==a(e))}},102:function(e,n,t){"use strict";(function(e,r){function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e,n){for(var t=0;t-1;a--){var o=t[a],i=(o.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(i)>-1&&(r=o)}return g.head.insertBefore(n,r),e}}function X(){for(var e=12,n="";e-- >0;)n+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[62*Math.random()|0];return n}function G(e){return"".concat(e).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(//g,">")}function $(e){return Object.keys(e||{}).reduce((function(n,t){return n+"".concat(t,": ").concat(e[t],";")}),"")}function V(e){return e.size!==Y.size||e.x!==Y.x||e.y!==Y.y||e.rotate!==Y.rotate||e.flipX||e.flipY}function J(e){var n=e.transform,t=e.containerWidth,r=e.iconWidth,a={transform:"translate(".concat(t/2," 256)")},o="translate(".concat(32*n.x,", ").concat(32*n.y,") "),i="scale(".concat(n.size/16*(n.flipX?-1:1),", ").concat(n.size/16*(n.flipY?-1:1),") "),l="rotate(".concat(n.rotate," 0 0)");return{outer:a,inner:{transform:"".concat(o," ").concat(i," ").concat(l)},path:{transform:"translate(".concat(r/2*-1," -256)")}}}var Q={x:0,y:0,width:"100%",height:"100%"};function Z(e){var n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return e.attributes&&(e.attributes.fill||n)&&(e.attributes.fill="black"),e}function ee(e){var n=e.icons,t=n.main,r=n.mask,a=e.prefix,o=e.iconName,i=e.transform,s=e.symbol,c=e.title,f=e.maskId,u=e.titleId,d=e.extra,p=e.watchable,h=void 0!==p&&p,m=r.found?r:t,g=m.width,b=m.height,y="fa-w-".concat(Math.ceil(g/b*16)),v=[E.replacementClass,o?"".concat(E.familyPrefix,"-").concat(o):"",y].filter((function(e){return-1===d.classes.indexOf(e)})).concat(d.classes).join(" "),w={children:[],attributes:l({},d.attributes,{"data-prefix":a,"data-icon":o,class:v,role:d.attributes.role||"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(g," ").concat(b)})};h&&(w.attributes["data-fa-i2svg"]=""),c&&w.children.push({tag:"title",attributes:{id:w.attributes["aria-labelledby"]||"title-".concat(u||X())},children:[c]});var x=l({},w,{prefix:a,iconName:o,main:t,mask:r,maskId:f,transform:i,symbol:s,styles:d.styles}),O=r.found&&t.found?function(e){var n,t=e.children,r=e.attributes,a=e.main,o=e.mask,i=e.maskId,s=e.transform,c=a.width,f=a.icon,u=o.width,d=o.icon,p=J({transform:s,containerWidth:u,iconWidth:c}),h={tag:"rect",attributes:l({},Q,{fill:"white"})},m=f.children?{children:f.children.map(Z)}:{},g={tag:"g",attributes:l({},p.inner),children:[Z(l({tag:f.tag,attributes:l({},f.attributes,p.path)},m))]},b={tag:"g",attributes:l({},p.outer),children:[g]},y="mask-".concat(i||X()),v="clip-".concat(i||X()),w={tag:"mask",attributes:l({},Q,{id:y,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[h,b]},x={tag:"defs",children:[{tag:"clipPath",attributes:{id:v},children:(n=d,"g"===n.tag?n.children:[n])},w]};return t.push(x,{tag:"rect",attributes:l({fill:"currentColor","clip-path":"url(#".concat(v,")"),mask:"url(#".concat(y,")")},Q)}),{children:t,attributes:r}}(x):function(e){var n=e.children,t=e.attributes,r=e.main,a=e.transform,o=$(e.styles);if(o.length>0&&(t.style=o),V(a)){var i=J({transform:a,containerWidth:r.width,iconWidth:r.width});n.push({tag:"g",attributes:l({},i.outer),children:[{tag:"g",attributes:l({},i.inner),children:[{tag:r.icon.tag,children:r.icon.children,attributes:l({},r.icon.attributes,i.path)}]}]})}else n.push(r.icon);return{children:n,attributes:t}}(x),k=O.children,S=O.attributes;return x.children=k,x.attributes=S,s?function(e){var n=e.prefix,t=e.iconName,r=e.children,a=e.attributes,o=e.symbol;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:l({},a,{id:!0===o?"".concat(n,"-").concat(E.familyPrefix,"-").concat(t):o}),children:r}]}]}(x):function(e){var n=e.children,t=e.main,r=e.mask,a=e.attributes,o=e.styles,i=e.transform;if(V(i)&&t.found&&!r.found){var s={x:t.width/t.height/2,y:.5};a.style=$(l({},o,{"transform-origin":"".concat(s.x+i.x/16,"em ").concat(s.y+i.y/16,"em")}))}return[{tag:"svg",attributes:a,children:n}]}(x)}var ne=function(){},te=(E.measurePerformance&&b&&b.mark&&b.measure,function(e,n,t,r){var a,o,i,l=Object.keys(e),s=l.length,c=void 0!==r?function(e,n){return function(t,r,a,o){return e.call(n,t,r,a,o)}}(n,r):n;for(void 0===t?(a=1,i=e[l[0]]):(a=0,i=t);a2&&void 0!==arguments[2]?arguments[2]:{},r=t.skipHooks,a=void 0!==r&&r,o=Object.keys(n).reduce((function(e,t){var r=n[t];return!!r.icon?e[r.iconName]=r.icon:e[t]=r,e}),{});"function"!=typeof I.hooks.addPack||a?I.styles[e]=l({},I.styles[e]||{},o):I.hooks.addPack(e,o),"fas"===e&&re("fa",n)}var ae=I.styles,oe=I.shims,ie=function(){var e=function(e){return te(ae,(function(n,t,r){return n[r]=te(t,e,{}),n}),{})};e((function(e,n,t){return n[3]&&(e[n[3]]=t),e})),e((function(e,n,t){var r=n[2];return e[t]=t,r.forEach((function(n){e[n]=t})),e}));var n="far"in ae;te(oe,(function(e,t){var r=t[0],a=t[1],o=t[2];return"far"!==a||n||(a="fas"),e[r]={prefix:a,iconName:o},e}),{})};ie();I.styles;function le(e,n,t){if(e&&e[n]&&e[n][t])return{prefix:n,iconName:t,icon:e[n][t]}}function se(e){var n=e.tag,t=e.attributes,r=void 0===t?{}:t,a=e.children,o=void 0===a?[]:a;return"string"==typeof e?G(e):"<".concat(n," ").concat(function(e){return Object.keys(e||{}).reduce((function(n,t){return n+"".concat(t,'="').concat(G(e[t]),'" ')}),"").trim()}(r),">").concat(o.map(se).join(""),"")}var ce=function(e){var n={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0};return e?e.toLowerCase().split(" ").reduce((function(e,n){var t=n.toLowerCase().split("-"),r=t[0],a=t.slice(1).join("-");if(r&&"h"===a)return e.flipX=!0,e;if(r&&"v"===a)return e.flipY=!0,e;if(a=parseFloat(a),isNaN(a))return e;switch(r){case"grow":e.size=e.size+a;break;case"shrink":e.size=e.size-a;break;case"left":e.x=e.x-a;break;case"right":e.x=e.x+a;break;case"up":e.y=e.y-a;break;case"down":e.y=e.y+a;break;case"rotate":e.rotate=e.rotate+a}return e}),n):n};function fe(e){this.name="MissingIcon",this.message=e||"Icon unavailable",this.stack=(new Error).stack}fe.prototype=Object.create(Error.prototype),fe.prototype.constructor=fe;var ue={fill:"currentColor"},de={attributeType:"XML",repeatCount:"indefinite",dur:"2s"},pe={tag:"path",attributes:l({},ue,{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})},he=l({},de,{attributeName:"opacity"});l({},ue,{cx:"256",cy:"364",r:"28"}),l({},de,{attributeName:"r",values:"28;14;28;28;14;28;"}),l({},he,{values:"1;0;1;1;0;1;"}),l({},ue,{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),l({},he,{values:"1;0;0;0;0;1;"}),l({},ue,{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),l({},he,{values:"0;0;1;1;0;0;"}),I.styles;function me(e){var n=e[0],t=e[1],r=s(e.slice(4),1)[0];return{found:!0,width:n,height:t,icon:Array.isArray(r)?{tag:"g",attributes:{class:"".concat(E.familyPrefix,"-").concat(x.GROUP)},children:[{tag:"path",attributes:{class:"".concat(E.familyPrefix,"-").concat(x.SECONDARY),fill:"currentColor",d:r[0]}},{tag:"path",attributes:{class:"".concat(E.familyPrefix,"-").concat(x.PRIMARY),fill:"currentColor",d:r[1]}}]}:{tag:"path",attributes:{fill:"currentColor",d:r}}}}I.styles;function ge(){var e="svg-inline--fa",n=E.familyPrefix,t=E.replacementClass,r='svg:not(:root).svg-inline--fa {\n overflow: visible;\n}\n\n.svg-inline--fa {\n display: inline-block;\n font-size: inherit;\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.225em;\n}\n.svg-inline--fa.fa-w-1 {\n width: 0.0625em;\n}\n.svg-inline--fa.fa-w-2 {\n width: 0.125em;\n}\n.svg-inline--fa.fa-w-3 {\n width: 0.1875em;\n}\n.svg-inline--fa.fa-w-4 {\n width: 0.25em;\n}\n.svg-inline--fa.fa-w-5 {\n width: 0.3125em;\n}\n.svg-inline--fa.fa-w-6 {\n width: 0.375em;\n}\n.svg-inline--fa.fa-w-7 {\n width: 0.4375em;\n}\n.svg-inline--fa.fa-w-8 {\n width: 0.5em;\n}\n.svg-inline--fa.fa-w-9 {\n width: 0.5625em;\n}\n.svg-inline--fa.fa-w-10 {\n width: 0.625em;\n}\n.svg-inline--fa.fa-w-11 {\n width: 0.6875em;\n}\n.svg-inline--fa.fa-w-12 {\n width: 0.75em;\n}\n.svg-inline--fa.fa-w-13 {\n width: 0.8125em;\n}\n.svg-inline--fa.fa-w-14 {\n width: 0.875em;\n}\n.svg-inline--fa.fa-w-15 {\n width: 0.9375em;\n}\n.svg-inline--fa.fa-w-16 {\n width: 1em;\n}\n.svg-inline--fa.fa-w-17 {\n width: 1.0625em;\n}\n.svg-inline--fa.fa-w-18 {\n width: 1.125em;\n}\n.svg-inline--fa.fa-w-19 {\n width: 1.1875em;\n}\n.svg-inline--fa.fa-w-20 {\n width: 1.25em;\n}\n.svg-inline--fa.fa-pull-left {\n margin-right: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-pull-right {\n margin-left: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-border {\n height: 1.5em;\n}\n.svg-inline--fa.fa-li {\n width: 2em;\n}\n.svg-inline--fa.fa-fw {\n width: 1.25em;\n}\n\n.fa-layers svg.svg-inline--fa {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: 1em;\n}\n.fa-layers svg.svg-inline--fa {\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n -webkit-transform: translate(-50%, -50%);\n transform: translate(-50%, -50%);\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: #ff253a;\n border-radius: 1em;\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: #fff;\n height: 1.5em;\n line-height: 1;\n max-width: 5em;\n min-width: 1.5em;\n overflow: hidden;\n padding: 0.25em;\n right: 0;\n text-overflow: ellipsis;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: 0;\n right: 0;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom right;\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: 0;\n left: 0;\n right: auto;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom left;\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n right: 0;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: 0;\n right: auto;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top left;\n transform-origin: top left;\n}\n\n.fa-lg {\n font-size: 1.3333333333em;\n line-height: 0.75em;\n vertical-align: -0.0667em;\n}\n\n.fa-xs {\n font-size: 0.75em;\n}\n\n.fa-sm {\n font-size: 0.875em;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-fw {\n text-align: center;\n width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-left: 2.5em;\n padding-left: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n left: -2em;\n position: absolute;\n text-align: center;\n width: 2em;\n line-height: inherit;\n}\n\n.fa-border {\n border: solid 0.08em #eee;\n border-radius: 0.1em;\n padding: 0.2em 0.25em 0.15em;\n}\n\n.fa-pull-left {\n float: left;\n}\n\n.fa-pull-right {\n float: right;\n}\n\n.fa.fa-pull-left,\n.fas.fa-pull-left,\n.far.fa-pull-left,\n.fal.fa-pull-left,\n.fab.fa-pull-left {\n margin-right: 0.3em;\n}\n.fa.fa-pull-right,\n.fas.fa-pull-right,\n.far.fa-pull-right,\n.fal.fa-pull-right,\n.fab.fa-pull-right {\n margin-left: 0.3em;\n}\n\n.fa-spin {\n -webkit-animation: fa-spin 2s infinite linear;\n animation: fa-spin 2s infinite linear;\n}\n\n.fa-pulse {\n -webkit-animation: fa-spin 1s infinite steps(8);\n animation: fa-spin 1s infinite steps(8);\n}\n\n@-webkit-keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n\n@keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";\n -webkit-transform: rotate(90deg);\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";\n -webkit-transform: rotate(180deg);\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";\n -webkit-transform: rotate(270deg);\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";\n -webkit-transform: scale(-1, 1);\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(1, -1);\n transform: scale(1, -1);\n}\n\n.fa-flip-both, .fa-flip-horizontal.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(-1, -1);\n transform: scale(-1, -1);\n}\n\n:root .fa-rotate-90,\n:root .fa-rotate-180,\n:root .fa-rotate-270,\n:root .fa-flip-horizontal,\n:root .fa-flip-vertical,\n:root .fa-flip-both {\n -webkit-filter: none;\n filter: none;\n}\n\n.fa-stack {\n display: inline-block;\n height: 2em;\n position: relative;\n width: 2.5em;\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.svg-inline--fa.fa-stack-1x {\n height: 1em;\n width: 1.25em;\n}\n.svg-inline--fa.fa-stack-2x {\n height: 2em;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: #fff;\n}\n\n.sr-only {\n border: 0;\n clip: rect(0, 0, 0, 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n width: 1px;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n clip: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n position: static;\n width: auto;\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.fad.fa-inverse {\n color: #fff;\n}';if("fa"!==n||t!==e){var a=new RegExp("\\.".concat("fa","\\-"),"g"),o=new RegExp("\\--".concat("fa","\\-"),"g"),i=new RegExp("\\.".concat(e),"g");r=r.replace(a,".".concat(n,"-")).replace(o,"--".concat(n,"-")).replace(i,".".concat(t))}return r}function be(){E.autoAddCss&&!Oe&&(q(ge()),Oe=!0)}function ye(e,n){return Object.defineProperty(e,"abstract",{get:n}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map((function(e){return se(e)}))}}),Object.defineProperty(e,"node",{get:function(){if(y){var n=g.createElement("div");return n.innerHTML=e.html,n.children}}}),e}function ve(e){var n=e.prefix,t=void 0===n?"fa":n,r=e.iconName;if(r)return le(xe.definitions,t,r)||le(I.styles,t,r)}var we,xe=new(function(){function e(){!function(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}(this,e),this.definitions={}}var n,t,r;return n=e,(t=[{key:"add",value:function(){for(var e=this,n=arguments.length,t=new Array(n),r=0;r1&&void 0!==arguments[1]?arguments[1]:{},t=n.transform,r=void 0===t?Y:t,a=n.symbol,o=void 0!==a&&a,i=n.mask,s=void 0===i?null:i,c=n.maskId,f=void 0===c?null:c,u=n.title,d=void 0===u?null:u,p=n.titleId,h=void 0===p?null:p,m=n.classes,g=void 0===m?[]:m,b=n.attributes,y=void 0===b?{}:b,v=n.styles,w=void 0===v?{}:v;if(e){var x=e.prefix,O=e.iconName,k=e.icon;return ye(l({type:"icon"},e),(function(){return be(),E.autoA11y&&(d?y["aria-labelledby"]="".concat(E.replacementClass,"-title-").concat(h||X()):(y["aria-hidden"]="true",y.focusable="false")),ee({icons:{main:me(k),mask:s?me(s.icon):{found:!1,width:null,height:null,icon:{}}},prefix:x,iconName:O,transform:l({},Y,r),symbol:o,title:d,maskId:f,titleId:h,extra:{attributes:y,styles:w,classes:g}})}))}},function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=(e||{}).icon?e:ve(e||{}),r=n.mask;return r&&(r=(r||{}).icon?r:ve(r||{})),we(t,l({},n,{mask:r}))})}).call(this,t(64),t(74).setImmediate)},110:function(e,n,t){var r=t(89),a=t(80);t(118)("keys",(function(){return function(e){return a(r(e))}}))},196:function(e,n,t){var r=t(25),a=t(197),o=t(77),i=t(140),l=t(137);r(r.S,"Object",{getOwnPropertyDescriptors:function(e){for(var n,t,r=o(e),s=i.f,c=a(r),f={},u=0;c.length>u;)void 0!==(t=s(r,n=c[u++]))&&l(f,n,t);return f}})},197:function(e,n,t){var r=t(121),a=t(120),o=t(2),i=t(0).Reflect;e.exports=i&&i.ownKeys||function(e){var n=r.f(o(e)),t=a.f;return t?n.concat(t(e)):n}},198:function(e,n,t){"use strict";var r=t(25),a=t(134)(!0);r(r.P,"Array",{includes:function(e){return a(this,e,arguments.length>1?arguments[1]:void 0)}}),t(130)("includes")},199:function(e,n,t){"use strict";var r=t(25),a=t(200);r(r.P+r.F*t(201)("includes"),"String",{includes:function(e){return!!~a(this,e,"includes").indexOf(e,arguments.length>1?arguments[1]:void 0)}})},200:function(e,n,t){var r=t(100),a=t(92);e.exports=function(e,n,t){if(r(n))throw TypeError("String#"+t+" doesn't accept regex!");return String(a(e))}},201:function(e,n,t){var r=t(1)("match");e.exports=function(e){var n=/./;try{"/./"[e](n)}catch(t){try{return n[r]=!1,!"/./"[e](n)}catch(e){}}return!0}},202:function(e,n,t){"use strict";e.exports=function(e,n,t,r,a,o,i,l){if(!e){var s;if(void 0===n)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[t,r,a,o,i,l],f=0;(s=new Error(n.replace(/%s/g,(function(){return c[f++]})))).name="Invariant Violation"}throw s.framesToPop=1,s}}},269:function(e,n,t){"use strict";t.r(n),t.d(n,"default",(function(){return Wn}));t(23),t(72),t(69),t(65),t(70),t(71),t(22),t(61),t(66),t(67),t(24);var r=t(56),a=t.n(r),o=t(63);t(196),t(68),t(110),t(62),t(198),t(199);function i(){return(i=Object.assign||function(e){for(var n=1;ne.length)&&(n=e.length);for(var t=0,r=new Array(n);t0&&void 0!==arguments[0]?arguments[0]:this.active.collection;return this.refs[e].sort(j)}}]),e}();function j(e,n){return e.node.sortableInfo.index-n.node.sortableInfo.index}function T(e,n,t){return(e=e.slice()).splice(t<0?e.length+t:t,0,e.splice(n,1)[0]),e}function _(e,n){return Object.keys(e).reduce((function(t,r){return-1===n.indexOf(r)&&(t[r]=e[r]),t}),{})}var A={end:["touchend","touchcancel","mouseup"],move:["touchmove","mousemove"],start:["touchstart","mousedown"]},M=function(){if("undefined"==typeof window||"undefined"==typeof document)return"";var e=window.getComputedStyle(document.documentElement,"")||["-moz-hidden-iframe"],n=(Array.prototype.slice.call(e).join("").match(/-(moz|webkit|ms)-/)||""===e.OLink&&["","o"])[1];switch(n){case"ms":return"ms";default:return n&&n.length?n[0].toUpperCase()+n.substr(1):""}}();function P(e,n){Object.keys(n).forEach((function(t){e.style[t]=n[t]}))}function L(e,n){e.style["".concat(M,"Transform")]=null==n?"":"translate3d(".concat(n.x,"px,").concat(n.y,"px,0)")}function N(e,n){e.style["".concat(M,"TransitionDuration")]=null==n?"":"".concat(n,"ms")}function z(e,n){for(;e;){if(n(e))return e;e=e.parentNode}return null}function D(e,n,t){return Math.max(e,Math.min(t,n))}function R(e){return"px"===e.substr(-2)?parseFloat(e):0}function W(e){var n=window.getComputedStyle(e);return{bottom:R(n.marginBottom),left:R(n.marginLeft),right:R(n.marginRight),top:R(n.marginTop)}}function F(e,n){var t=n.displayName||n.name;return t?"".concat(e,"(").concat(t,")"):e}function H(e,n){var t=e.getBoundingClientRect();return{top:t.top+n.top,left:t.left+n.left}}function B(e){return e.touches&&e.touches.length?{x:e.touches[0].pageX,y:e.touches[0].pageY}:e.changedTouches&&e.changedTouches.length?{x:e.changedTouches[0].pageX,y:e.changedTouches[0].pageY}:{x:e.pageX,y:e.pageY}}function U(e){return e.touches&&e.touches.length||e.changedTouches&&e.changedTouches.length}function K(e,n){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{left:0,top:0};if(e){var r={left:t.left+e.offsetLeft,top:t.top+e.offsetTop};return e.parentNode===n?r:K(e.parentNode,n,r)}}function Y(e,n,t){return en?e-1:e>t&&e0&&t[n].height>0)&&e.getContext("2d").drawImage(t[n],0,0)})),r}function ue(e){return null!=e.sortableHandle}var de=function(){function e(n,t){d(this,e),this.container=n,this.onScrollCallback=t}return h(e,[{key:"clear",value:function(){null!=this.interval&&(clearInterval(this.interval),this.interval=null)}},{key:"update",value:function(e){var n=this,t=e.translate,r=e.minTranslate,a=e.maxTranslate,o=e.width,i=e.height,l={x:0,y:0},s={x:1,y:1},c=10,f=10,u=this.container,d=u.scrollTop,p=u.scrollLeft,h=u.scrollHeight,m=u.scrollWidth,g=0===d,b=h-d-u.clientHeight==0,y=0===p,v=m-p-u.clientWidth==0;t.y>=a.y-i/2&&!b?(l.y=1,s.y=f*Math.abs((a.y-i/2-t.y)/i)):t.x>=a.x-o/2&&!v?(l.x=1,s.x=c*Math.abs((a.x-o/2-t.x)/o)):t.y<=r.y+i/2&&!g?(l.y=-1,s.y=f*Math.abs((t.y-i/2-r.y)/i)):t.x<=r.x+o/2&&!y&&(l.x=-1,s.x=c*Math.abs((t.x-o/2-r.x)/o)),this.interval&&(this.clear(),this.isAutoScrolling=!1),0===l.x&&0===l.y||(this.interval=setInterval((function(){n.isAutoScrolling=!0;var e={left:s.x*l.x,top:s.y*l.y};n.container.scrollTop+=e.top,n.container.scrollLeft+=e.left,n.onScrollCallback(e)}),5))}}]),e}();var pe={axis:O.a.oneOf(["x","y","xy"]),contentWindow:O.a.any,disableAutoscroll:O.a.bool,distance:O.a.number,getContainer:O.a.func,getHelperDimensions:O.a.func,helperClass:O.a.string,helperContainer:O.a.oneOfType([O.a.func,"undefined"==typeof HTMLElement?O.a.any:O.a.instanceOf(HTMLElement)]),hideSortableGhost:O.a.bool,keyboardSortingTransitionDuration:O.a.number,lockAxis:O.a.string,lockOffset:O.a.oneOfType([O.a.number,O.a.string,O.a.arrayOf(O.a.oneOfType([O.a.number,O.a.string]))]),lockToContainerEdges:O.a.bool,onSortEnd:O.a.func,onSortMove:O.a.func,onSortOver:O.a.func,onSortStart:O.a.func,pressDelay:O.a.number,pressThreshold:O.a.number,keyCodes:O.a.shape({lift:O.a.arrayOf(O.a.number),drop:O.a.arrayOf(O.a.number),cancel:O.a.arrayOf(O.a.number),up:O.a.arrayOf(O.a.number),down:O.a.arrayOf(O.a.number)}),shouldCancelStart:O.a.func,transitionDuration:O.a.number,updateBeforeSortStart:O.a.func,useDragHandle:O.a.bool,useWindowAsScrollContainer:O.a.bool},he={lift:[Q],drop:[Q],cancel:[J],up:[ee,Z],down:[te,ne]},me={axis:"y",disableAutoscroll:!1,distance:0,getHelperDimensions:function(e){var n=e.node;return{height:n.offsetHeight,width:n.offsetWidth}},hideSortableGhost:!0,lockOffset:"50%",lockToContainerEdges:!1,pressDelay:0,pressThreshold:5,keyCodes:he,shouldCancelStart:function(e){return-1!==[ie,se,ce,le,ae].indexOf(e.target.tagName)||!!z(e.target,(function(e){return"true"===e.contentEditable}))},transitionDuration:300,useWindowAsScrollContainer:!1},ge=Object.keys(pe);function be(e){S()(!(e.distance&&e.pressDelay),"Attempted to set both `pressDelay` and `distance` on SortableContainer, you may only use one or the other, not both at the same time.")}function ye(e,n){try{var t=e()}catch(e){return n(!0,e)}return t&&t.then?t.then(n.bind(null,!1),n.bind(null,!0)):n(!1,value)}var ve={index:O.a.number.isRequired,collection:O.a.oneOfType([O.a.number,O.a.string]),disabled:O.a.bool},we=Object.keys(ve);var xe=t(60),Oe=t(81),ke=t(82);function Ee(e){return Math.round(255*e)}function Se(e,n,t){return Ee(e)+","+Ee(n)+","+Ee(t)}function Ie(e,n,t,r){if(void 0===r&&(r=Se),0===n)return r(t,t,t);var a=e%360/60,o=(1-Math.abs(2*t-1))*n,i=o*(1-Math.abs(a%2-1)),l=0,s=0,c=0;a>=0&&a<1?(l=o,s=i):a>=1&&a<2?(l=i,s=o):a>=2&&a<3?(s=o,c=i):a>=3&&a<4?(s=i,c=o):a>=4&&a<5?(l=i,c=o):a>=5&&a<6&&(l=o,c=i);var f=t-o/2;return r(l+f,s+f,c+f)}var Ce={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};var je=/^#[a-fA-F0-9]{6}$/,Te=/^#[a-fA-F0-9]{8}$/,_e=/^#[a-fA-F0-9]{3}$/,Ae=/^#[a-fA-F0-9]{4}$/,Me=/^rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/,Pe=/^rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*([-+]?[0-9]*[.]?[0-9]+)\s*\)$/,Le=/^hsl\(\s*(\d{0,3}[.]?[0-9]+)\s*,\s*(\d{1,3})%\s*,\s*(\d{1,3})%\s*\)$/,Ne=/^hsla\(\s*(\d{0,3}[.]?[0-9]+)\s*,\s*(\d{1,3})%\s*,\s*(\d{1,3})%\s*,\s*([-+]?[0-9]*[.]?[0-9]+)\s*\)$/;function ze(e){if("string"!=typeof e)throw new Error("Passed an incorrect argument to a color function, please pass a string representation of a color.");var n=function(e){if("string"!=typeof e)return e;var n=e.toLowerCase();return Ce[n]?"#"+Ce[n]:e}(e);if(n.match(je))return{red:parseInt(""+n[1]+n[2],16),green:parseInt(""+n[3]+n[4],16),blue:parseInt(""+n[5]+n[6],16)};if(n.match(Te)){var t=parseFloat((parseInt(""+n[7]+n[8],16)/255).toFixed(2));return{red:parseInt(""+n[1]+n[2],16),green:parseInt(""+n[3]+n[4],16),blue:parseInt(""+n[5]+n[6],16),alpha:t}}if(n.match(_e))return{red:parseInt(""+n[1]+n[1],16),green:parseInt(""+n[2]+n[2],16),blue:parseInt(""+n[3]+n[3],16)};if(n.match(Ae)){var r=parseFloat((parseInt(""+n[4]+n[4],16)/255).toFixed(2));return{red:parseInt(""+n[1]+n[1],16),green:parseInt(""+n[2]+n[2],16),blue:parseInt(""+n[3]+n[3],16),alpha:r}}var a=Me.exec(n);if(a)return{red:parseInt(""+a[1],10),green:parseInt(""+a[2],10),blue:parseInt(""+a[3],10)};var o=Pe.exec(n);if(o)return{red:parseInt(""+o[1],10),green:parseInt(""+o[2],10),blue:parseInt(""+o[3],10),alpha:parseFloat(""+o[4])};var i=Le.exec(n);if(i){var l="rgb("+Ie(parseInt(""+i[1],10),parseInt(""+i[2],10)/100,parseInt(""+i[3],10)/100)+")",s=Me.exec(l);if(!s)throw new Error("Couldn't generate valid rgb string from "+n+", it returned "+l+".");return{red:parseInt(""+s[1],10),green:parseInt(""+s[2],10),blue:parseInt(""+s[3],10)}}var c=Ne.exec(n);if(c){var f="rgb("+Ie(parseInt(""+c[1],10),parseInt(""+c[2],10)/100,parseInt(""+c[3],10)/100)+")",u=Me.exec(f);if(!u)throw new Error("Couldn't generate valid rgb string from "+n+", it returned "+f+".");return{red:parseInt(""+u[1],10),green:parseInt(""+u[2],10),blue:parseInt(""+u[3],10),alpha:parseFloat(""+c[4])}}throw new Error("Couldn't parse the color string. Please provide the color as a string in hex, rgb, rgba, hsl or hsla notation.")}function De(e){return function(e){var n,t=e.red/255,r=e.green/255,a=e.blue/255,o=Math.max(t,r,a),i=Math.min(t,r,a),l=(o+i)/2;if(o===i)return void 0!==e.alpha?{hue:0,saturation:0,lightness:l,alpha:e.alpha}:{hue:0,saturation:0,lightness:l};var s=o-i,c=l>.5?s/(2-o-i):s/(o+i);switch(o){case t:n=(r-a)/s+(r=1?Ue(e,n,t):"rgba("+e+","+n+","+t+","+r+")";if("object"==typeof e&&void 0===n&&void 0===t&&void 0===r)return e.alpha>=1?Ue(e.red,e.green,e.blue):"rgba("+e.red+","+e.green+","+e.blue+","+e.alpha+")";throw new Error("Passed invalid arguments to rgba, please pass multiple numbers e.g. rgb(255, 205, 100, 0.75) or an object e.g. rgb({ red: 255, green: 205, blue: 100, alpha: 0.75 }).")}var Ye="Passed invalid argument to toColorString, please pass a RgbColor, RgbaColor, HslColor or HslaColor object.";function qe(e){if("object"!=typeof e)throw new Error(Ye);if(function(e){return"number"==typeof e.red&&"number"==typeof e.green&&"number"==typeof e.blue&&"number"==typeof e.alpha}(e))return Ke(e);if(function(e){return"number"==typeof e.red&&"number"==typeof e.green&&"number"==typeof e.blue&&("number"!=typeof e.alpha||void 0===e.alpha)}(e))return Ue(e);if(function(e){return"number"==typeof e.hue&&"number"==typeof e.saturation&&"number"==typeof e.lightness&&"number"==typeof e.alpha}(e))return function(e,n,t,r){if("number"==typeof e&&"number"==typeof n&&"number"==typeof t&&"number"==typeof r)return r>=1?Be(e,n,t):"rgba("+Ie(e,n,t)+","+r+")";if("object"==typeof e&&void 0===n&&void 0===t&&void 0===r)return e.alpha>=1?Be(e.hue,e.saturation,e.lightness):"rgba("+Ie(e.hue,e.saturation,e.lightness)+","+e.alpha+")";throw new Error("Passed invalid arguments to hsla, please pass multiple numbers e.g. hsl(360, 0.75, 0.4, 0.7) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75, alpha: 0.7 }).")}(e);if(function(e){return"number"==typeof e.hue&&"number"==typeof e.saturation&&"number"==typeof e.lightness&&("number"!=typeof e.alpha||void 0===e.alpha)}(e))return function(e,n,t){if("number"==typeof e&&"number"==typeof n&&"number"==typeof t)return Be(e,n,t);if("object"==typeof e&&void 0===n&&void 0===t)return Be(e.hue,e.saturation,e.lightness);throw new Error("Passed invalid arguments to hsl, please pass multiple numbers e.g. hsl(360, 0.75, 0.4) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75 }).")}(e);throw new Error(Ye)}function Xe(e){return function e(n,t,r){return function(){var a=r.concat(Array.prototype.slice.call(arguments));return a.length>=t?n.apply(this,a):e(n,t,a)}}(e,e.length,[])}function Ge(e,n,t){return Math.max(e,Math.min(n,t))}function $e(e,n){var t=De(n);return qe(i({},t,{lightness:Ge(0,1,t.lightness+parseFloat(e))}))}var Ve=Xe($e);function Je(){var e=function(e,n){n||(n=e.slice(0));return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}(["\ndisplay: block;\nheight: 26px;\nfloat: right;\nwidth: 100px;\nright: 20px;\n\na {\n display: block;\n transition: all 0.3s ease-out;\n}\nlabel,\n> span {\n line-height: 26px;\n vertical-align: middle;\n}\n\n* {\n box-sizing: border-box; \n outline: 0!important\n}\n\nposition: relative;\ninput {\n position: absolute;\n opacity: 0;\n}\n\nlabel {\n position: relative;\n z-index: 2;\n width: 50%;\n height: 100%;\n margin: "," 0 0 0;\n text-align: center;\n float: left;\n}\n\na {\n position: absolute;\n top: 0;\n padding: 0;\n z-index: 1;\n width: 50%;\n height: 100%;\n color: white;\n border: solid 1px #279CBB!important;\n background-color: #2EACCE!important;\n left: 0;\n border-radius: 3px!important;\n}\n\ninput:last-of-type:checked ~ a {\n border: solid 1px #CA6F6F!important;\n background-color: #E08F95!important;\n left: 50% ;\n border-radius: 3px!important;\n}\n\ninput:disabled ~ a {\n border: solid 1px lighten(gray,20%) !important;\n background-color: lighten(gray,30%)\t!important;\n // box-shadow: "," 0 -1px 0 inset !important;\n}\n\nmargin-top: ",";\nbackground-color: #eee;\nborder-radius: 3px!important;\ncolor: #555;\ntext-align: center;\nbox-shadow: "," 0 1px 4px 1px inset;\n\nlabel {\n text-transform: uppercase;\n color: #bbb;\n font-weight: 400;\n cursor: pointer;\n transition: color 0.2s ease-out;\n}\n\ninput:checked + label {\n color: white\n}\n\n> span {\n color: #666;\n text-transform: uppercase;\n cursor: pointer;\n}\n"]);return Je=function(){return e},e}var Qe=xe.default.span(Je(),(function(e){return e.legacy?"-2px":"0"}),Ve(.2,"gray"),(function(e){return e.legacy?"0":"3px"}),Ke("black",.15));function Ze(e){var n=e.enabled,t=e.onChange,r=e.id,o=e.translations;return a.a.createElement(Qe,e,a.a.createElement("input",{type:"radio","data-mollie-check":"",name:"MOLLIE_METHOD_ENABLED_".concat(r),id:"MOLLIE_METHOD_ENABLED_on_".concat(r),value:"1",checked:n,onChange:t}),a.a.createElement("label",{htmlFor:"MOLLIE_METHOD_ENABLED_on_".concat(r)},o.yes.toUpperCase()),a.a.createElement("input",{type:"radio",name:"MOLLIE_METHOD_ENABLED_".concat(r),id:"MOLLIE_METHOD_ENABLED_off_".concat(r),value:"",checked:!n,onChange:t}),a.a.createElement("label",{htmlFor:"MOLLIE_METHOD_ENABLED_off_".concat(r)},o.no.toUpperCase())," "," ",a.a.createElement("a",{className:"slide-button btn"}))}function en(){var e=sn(["\nmargin: 0 auto;\ntext-align: center;\n"]);return en=function(){return e},e}function nn(){var e=sn(["\npadding: 1px 5px;\nfont-size: 11px;\nline-height: 1.5;\nborder-radius: 3px;\ncolor: #363A41;\ndisplay: inline-block;\nmargin-bottom: 0;\nfont-weight: normal;\ntext-align: center;\nvertical-align: middle;\ncursor: pointer;\nbackground: #2eacce none;\nborder: 1px solid #0000;\nwhite-space: nowrap;\nfont-family: inherit;\nwidth: 26px!important;\nmargin-top: 6px!important;\nmargin-right: 2px!important;\n\n:hover {\n background-color: #008abd;\n -webkit-box-shadow: none;\n box-shadow: none;\n}\n\n:disabled {\n background-color: #2eacce;\n border-color: #2eacce;\n cursor: not-allowed;\n opacity: .65;\n filter: alpha(opacity=65);\n -webkit-box-shadow: none;\n box-shadow: none;\n}\n","\n"]);return nn=function(){return e},e}function tn(){var e=sn(["\nborder: solid 1px #ccc;\nbackground-color: #eee;\npadding: 0;\nfont-size: 1.4em;\ncolor: #aaa;\ncursor: move;\ntext-shadow: #fff 1px 1px;\n-webkit-border-radius: 3px;\nborder-radius: 3px;\n-webkit-box-shadow: rgba(0,0,0,0.2) 0 1px 3px inset;\nbox-shadow: rgba(0,0,0,0.2) 0 1px 3px inset;\ndisplay: block;\nwidth: 40px;\ntext-align: center;\nmargin: 0 auto;\n","\n"]);return tn=function(){return e},e}function rn(){var e=sn(["\ndisplay: table-cell;\nheight: 50px;\nvertical-align: middle;\nbox-sizing: border-box;\n"]);return rn=function(){return e},e}function an(){var e=sn(["\ndisplay: table-cell;\nwidth: 75px;\ntext-align: left;\nvertical-align: middle;\n"]);return an=function(){return e},e}function on(){var e=sn(["\ndisplay: table-cell;\nwidth: 80px!important;\nvertical-align: middle!important;\ntext-align: right!important;\n"]);return on=function(){return e},e}function ln(){var e=sn(["\ncursor: move!important;\n-webkit-touch-callout: none; /* iOS Safari */\n -webkit-user-select: none; /* Safari */\n -khtml-user-select: none; /* Konqueror HTML */\n -moz-user-select: none; /* Firefox */\n -ms-user-select: none; /* Internet Explorer/Edge */\n user-select: none; /* Non-prefixed version, currently\n supported by Chrome and Opera */\n \nborder: 1px solid #0c95fd;\nborder-bottom-width: ",";\nbackground-color: #fff;\ndisplay: table;\nwidth: 100%;\npadding: 5px 0;\nmargin-bottom: -1px;\n","\n"]);return ln=function(){return e},e}function sn(e,n){return n||(n=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}var cn=xe.default.li(ln(),(function(e){return e.last?"1px":"2px"}),(function(e){return e.legacy?"width: calc(100% - 2px);":""})),fn=xe.default.div(on()),un=xe.default.div(an()),dn=xe.default.div(rn()),pn=xe.default.span(tn(),(function(e){return e.legacy?"height: 24px;line-height: 24px;":""})),hn=xe.default.button(nn(),(function(e){return e.legacy?"height: 20px;line-height: 20px;":""})),mn=xe.default.div(en());var gn=function(e){var n,t,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{withRef:!1};return t=n=function(n){function t(){return d(this,t),b(this,y(t).apply(this,arguments))}return w(t,n),h(t,[{key:"componentDidMount",value:function(){this.register()}},{key:"componentDidUpdate",value:function(e){this.node&&(e.index!==this.props.index&&(this.node.sortableInfo.index=this.props.index),e.disabled!==this.props.disabled&&(this.node.sortableInfo.disabled=this.props.disabled)),e.collection!==this.props.collection&&(this.unregister(e.collection),this.register())}},{key:"componentWillUnmount",value:function(){this.unregister()}},{key:"register",value:function(){var e=this.props,n=e.collection,t=e.disabled,r=e.index,a=Object(k.findDOMNode)(this);a.sortableInfo={collection:n,disabled:t,index:r,manager:this.context.manager},this.node=a,this.ref={node:a},this.context.manager.add(n,this.ref)}},{key:"unregister",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.props.collection;this.context.manager.remove(e,this.ref)}},{key:"getWrappedInstance",value:function(){return S()(a.withRef,"To access the wrapped instance, you need to pass in {withRef: true} as the second argument of the SortableElement() call"),this.refs.wrappedInstance}},{key:"render",value:function(){var n=a.withRef?"wrappedInstance":null;return Object(r.createElement)(e,i({ref:n},_(this.props,we)))}}]),t}(r.Component),f(n,"displayName",F("sortableElement",e)),f(n,"contextTypes",{manager:O.a.object.isRequired}),f(n,"propTypes",ve),f(n,"defaultProps",{collection:0}),t}((function(e){var n=e.enabled,t=e.onToggle,o=e.code,i=e.translations,l=e.position,s=e.max,c=e.name,f=e.imageUrl,u=e.moveMethod,d=e.available,p=e.tipEnableSSL,h=e.config.legacy;return Object(r.useEffect)((function(){"undefined"!=typeof $&&"function"==typeof $.prototype.tooltip&&$("[data-toggle=tooltip]").tooltip()})),a.a.createElement(cn,{last:l>=s,legacy:h},a.a.createElement(fn,null,a.a.createElement(pn,{legacy:h},l+1),a.a.createElement(mn,null,a.a.createElement(hn,{legacy:h,disabled:l<=0,onClick:function(e){e.preventDefault(),u({oldIndex:l-1,newIndex:l})}},a.a.createElement(Oe.a,{icon:ke.b,style:{color:"white",pointerEvents:"none"}})),a.a.createElement(hn,{legacy:h,disabled:l>=s,onClick:function(e){e.preventDefault(),u({oldIndex:l+1,newIndex:l})}},a.a.createElement(Oe.a,{icon:ke.a,style:{color:"white",pointerEvents:"none"}})))),a.a.createElement(un,null,a.a.createElement("img",{width:"57",src:f,alt:c,style:{width:"57px"}})),a.a.createElement(dn,null,a.a.createElement("div",{style:{display:"inline-block",marginTop:"5px"}},a.a.createElement("span",null,c)),!d&&p&&a.a.createElement("p",{style:{float:"right",marginRight:"20px"},title:i.thisPaymentMethodNeedsSSLEnabled,"data-toggle":"tooltip"},a.a.createElement(Oe.a,{icon:ke.d})," ",i.notAvailable),!d&&!p&&a.a.createElement("p",{style:{float:"right",marginRight:"20px"},title:i.thisPaymentMethodIsNotAvailableOnPaymentsApi,"data-toggle":"tooltip"},a.a.createElement(Oe.a,{icon:ke.d})," ",i.notAvailable),d&&a.a.createElement(Ze,{id:o,translations:i,enabled:n,onChange:function(e){return function(e){t(o,e)}(!!e.target.value)},legacy:h})))}));function bn(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function yn(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function vn(e,n){return function(e){if(Array.isArray(e))return e}(e)||function(e,n){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var t=[],r=!0,a=!1,o=void 0;try{for(var i,l=e[Symbol.iterator]();!(r=(i=l.next()).done)&&(t.push(i.value),!n||t.length!==n);r=!0);}catch(e){a=!0,o=e}finally{try{r||null==l.return||l.return()}finally{if(a)throw o}}return t}(e,n)||function(e,n){if(!e)return;if("string"==typeof e)return wn(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);"Object"===t&&e.constructor&&(t=e.constructor.name);if("Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return wn(e,n)}(e,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function wn(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,r=new Array(n);t1&&void 0!==arguments[1]?arguments[1]:{withRef:!1};return t=n=function(n){function t(e){var n;return d(this,t),f(g(g(n=b(this,y(t).call(this,e)))),"state",{}),f(g(g(n)),"handleStart",(function(e){var t=n.props,r=t.distance,a=t.shouldCancelStart;if(2!==e.button&&!a(e)){n.touched=!0,n.position=B(e);var o=z(e.target,(function(e){return null!=e.sortableInfo}));if(o&&o.sortableInfo&&n.nodeIsChild(o)&&!n.state.sorting){var i=n.props.useDragHandle,l=o.sortableInfo,s=l.index,c=l.collection;if(l.disabled)return;if(i&&!z(e.target,ue))return;n.manager.active={collection:c,index:s},U(e)||e.target.tagName!==re||e.preventDefault(),r||(0===n.props.pressDelay?n.handlePress(e):n.pressTimer=setTimeout((function(){return n.handlePress(e)}),n.props.pressDelay))}}})),f(g(g(n)),"nodeIsChild",(function(e){return e.sortableInfo.manager===n.manager})),f(g(g(n)),"handleMove",(function(e){var t=n.props,r=t.distance,a=t.pressThreshold;if(!n.state.sorting&&n.touched&&!n._awaitingUpdateBeforeSortStart){var o=B(e),i={x:n.position.x-o.x,y:n.position.y-o.y},l=Math.abs(i.x)+Math.abs(i.y);n.delta=i,r||a&&!(l>=a)?r&&l>=r&&n.manager.isActive()&&n.handlePress(e):(clearTimeout(n.cancelTimer),n.cancelTimer=setTimeout(n.cancel,0))}})),f(g(g(n)),"handleEnd",(function(){n.touched=!1,n.cancel()})),f(g(g(n)),"cancel",(function(){var e=n.props.distance;n.state.sorting||(e||clearTimeout(n.pressTimer),n.manager.active=null)})),f(g(g(n)),"handlePress",(function(e){try{var t=n.manager.getActive(),r=function(){if(t){var r=function(){var t=p.sortableInfo.index,r=W(p),a=V(n.container),c=n.scrollContainer.getBoundingClientRect(),g=i({index:t,node:p,collection:h});if(n.node=p,n.margin=r,n.gridGap=a,n.width=g.width,n.height=g.height,n.marginOffset={x:n.margin.left+n.margin.right+n.gridGap.x,y:Math.max(n.margin.top,n.margin.bottom,n.gridGap.y)},n.boundingClientRect=p.getBoundingClientRect(),n.containerBoundingRect=c,n.index=t,n.newIndex=t,n.axis={x:o.indexOf("x")>=0,y:o.indexOf("y")>=0},n.offsetEdge=K(p,n.container),n.initialOffset=B(m?u({},e,{pageX:n.boundingClientRect.left,pageY:n.boundingClientRect.top}):e),n.initialScroll={left:n.scrollContainer.scrollLeft,top:n.scrollContainer.scrollTop},n.initialWindowScroll={left:window.pageXOffset,top:window.pageYOffset},n.helper=n.helperContainer.appendChild(fe(p)),P(n.helper,{boxSizing:"border-box",height:"".concat(n.height,"px"),left:"".concat(n.boundingClientRect.left-r.left,"px"),pointerEvents:"none",position:"fixed",top:"".concat(n.boundingClientRect.top-r.top,"px"),width:"".concat(n.width,"px")}),m&&n.helper.focus(),s&&(n.sortableGhost=p,P(p,{opacity:0,visibility:"hidden"})),n.minTranslate={},n.maxTranslate={},m){var b=d?{top:0,left:0,width:n.contentWindow.innerWidth,height:n.contentWindow.innerHeight}:n.containerBoundingRect,y=b.top,v=b.left,w=b.width,x=y+b.height,O=v+w;n.axis.x&&(n.minTranslate.x=v-n.boundingClientRect.left,n.maxTranslate.x=O-(n.boundingClientRect.left+n.width)),n.axis.y&&(n.minTranslate.y=y-n.boundingClientRect.top,n.maxTranslate.y=x-(n.boundingClientRect.top+n.height))}else n.axis.x&&(n.minTranslate.x=(d?0:c.left)-n.boundingClientRect.left-n.width/2,n.maxTranslate.x=(d?n.contentWindow.innerWidth:c.left+c.width)-n.boundingClientRect.left-n.width/2),n.axis.y&&(n.minTranslate.y=(d?0:c.top)-n.boundingClientRect.top-n.height/2,n.maxTranslate.y=(d?n.contentWindow.innerHeight:c.top+c.height)-n.boundingClientRect.top-n.height/2);l&&l.split(" ").forEach((function(e){return n.helper.classList.add(e)})),n.listenerNode=e.touches?p:n.contentWindow,m?(n.listenerNode.addEventListener("wheel",n.handleKeyEnd,!0),n.listenerNode.addEventListener("mousedown",n.handleKeyEnd,!0),n.listenerNode.addEventListener("keydown",n.handleKeyDown)):(A.move.forEach((function(e){return n.listenerNode.addEventListener(e,n.handleSortMove,!1)})),A.end.forEach((function(e){return n.listenerNode.addEventListener(e,n.handleSortEnd,!1)}))),n.setState({sorting:!0,sortingIndex:t}),f&&f({node:p,index:t,collection:h,isKeySorting:m,nodes:n.manager.getOrderedRefs(),helper:n.helper},e),m&&n.keyMove(0)},a=n.props,o=a.axis,i=a.getHelperDimensions,l=a.helperClass,s=a.hideSortableGhost,c=a.updateBeforeSortStart,f=a.onSortStart,d=a.useWindowAsScrollContainer,p=t.node,h=t.collection,m=n.manager.isKeySorting,g=function(){if("function"==typeof c){n._awaitingUpdateBeforeSortStart=!0;var t=ye((function(){var n=p.sortableInfo.index;return Promise.resolve(c({collection:h,index:n,node:p,isKeySorting:m},e)).then((function(){}))}),(function(e,t){if(n._awaitingUpdateBeforeSortStart=!1,e)throw t;return t}));if(t&&t.then)return t.then((function(){}))}}();return g&&g.then?g.then(r):r()}}();return Promise.resolve(r&&r.then?r.then((function(){})):void 0)}catch(e){return Promise.reject(e)}})),f(g(g(n)),"handleSortMove",(function(e){var t=n.props.onSortMove;"function"==typeof e.preventDefault&&e.preventDefault(),n.updateHelperPosition(e),n.animateNodes(),n.autoscroll(),t&&t(e)})),f(g(g(n)),"handleSortEnd",(function(e){var t=n.props,r=t.hideSortableGhost,a=t.onSortEnd,o=n.manager,i=o.active.collection,l=o.isKeySorting,s=n.manager.getOrderedRefs();n.listenerNode&&(l?(n.listenerNode.removeEventListener("wheel",n.handleKeyEnd,!0),n.listenerNode.removeEventListener("mousedown",n.handleKeyEnd,!0),n.listenerNode.removeEventListener("keydown",n.handleKeyDown)):(A.move.forEach((function(e){return n.listenerNode.removeEventListener(e,n.handleSortMove)})),A.end.forEach((function(e){return n.listenerNode.removeEventListener(e,n.handleSortEnd)})))),n.helper.parentNode.removeChild(n.helper),r&&n.sortableGhost&&P(n.sortableGhost,{opacity:"",visibility:""});for(var c=0,f=s.length;cr)){n.prevIndex=o,n.newIndex=a;var i=Y(n.newIndex,n.prevIndex,n.index),l=t.find((function(e){return e.node.sortableInfo.index===i})),s=l.node,c=n.containerScrollDelta,f=l.boundingClientRect||H(s,c),u=l.translate||{x:0,y:0},d=f.top+u.y-c.top,p=f.left+u.x-c.left,h=og?g/2:this.height/2,width:this.width>m?m/2:this.width/2},y=c&&h>this.index&&h<=f,v=c&&h=f,w={x:0,y:0},x=i[u].edgeOffset;x||(x=K(p,this.container),i[u].edgeOffset=x,c&&(i[u].boundingClientRect=H(p,a)));var O=u0&&i[u-1];O&&!O.edgeOffset&&(O.edgeOffset=K(O.node,this.container),c&&(O.boundingClientRect=H(O.node,a))),h!==this.index?(n&&N(p,n),this.axis.x?this.axis.y?v||hthis.containerBoundingRect.width-b.width&&O&&(w.x=O.edgeOffset.left-x.left,w.y=O.edgeOffset.top-x.top),null===this.newIndex&&(this.newIndex=h)):(y||h>this.index&&(l+o.left+b.width>=x.left&&s+o.top+b.height>=x.top||s+o.top+b.height>=x.top+g))&&(w.x=-(this.width+this.marginOffset.x),x.left+w.xthis.index&&l+o.left+b.width>=x.left?(w.x=-(this.width+this.marginOffset.x),this.newIndex=h):(v||hthis.index&&s+o.top+b.height>=x.top?(w.y=-(this.height+this.marginOffset.y),this.newIndex=h):(v||he.length)&&(n=e.length);for(var t=0,r=new Array(n);te.length)&&(n=e.length);for(var t=0,r=new Array(n);t=0&&(e._idleTimeoutId=setTimeout((function(){e._onTimeout&&e._onTimeout()}),n))},t(78),n.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||this&&this.setImmediate,n.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||this&&this.clearImmediate}).call(this,t(64))},76:function(e,n,t){var r; -/*! - Copyright (c) 2017 Jed Watson. - Licensed under the MIT License (MIT), see - http://jedwatson.github.io/classnames +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ +(window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["methodconfig"],{100:function(e,n,t){var r=t(3),a=t(10),o=t(1)("match");e.exports=function(e){var n;return r(e)&&(void 0!==(n=e[o])?!!n:"RegExp"==a(e))}},102:function(e,n,t){"use strict";(function(e,r){function a(e){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e,n){for(var t=0;t-1;a--){var o=t[a],i=(o.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(i)>-1&&(r=o)}return g.head.insertBefore(n,r),e}}function X(){for(var e=12,n="";e-- >0;)n+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[62*Math.random()|0];return n}function G(e){return"".concat(e).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(//g,">")}function $(e){return Object.keys(e||{}).reduce((function(n,t){return n+"".concat(t,": ").concat(e[t],";")}),"")}function V(e){return e.size!==Y.size||e.x!==Y.x||e.y!==Y.y||e.rotate!==Y.rotate||e.flipX||e.flipY}function J(e){var n=e.transform,t=e.containerWidth,r=e.iconWidth,a={transform:"translate(".concat(t/2," 256)")},o="translate(".concat(32*n.x,", ").concat(32*n.y,") "),i="scale(".concat(n.size/16*(n.flipX?-1:1),", ").concat(n.size/16*(n.flipY?-1:1),") "),l="rotate(".concat(n.rotate," 0 0)");return{outer:a,inner:{transform:"".concat(o," ").concat(i," ").concat(l)},path:{transform:"translate(".concat(r/2*-1," -256)")}}}var Q={x:0,y:0,width:"100%",height:"100%"};function Z(e){var n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return e.attributes&&(e.attributes.fill||n)&&(e.attributes.fill="black"),e}function ee(e){var n=e.icons,t=n.main,r=n.mask,a=e.prefix,o=e.iconName,i=e.transform,s=e.symbol,c=e.title,f=e.maskId,u=e.titleId,d=e.extra,p=e.watchable,h=void 0!==p&&p,m=r.found?r:t,g=m.width,b=m.height,y="fa-w-".concat(Math.ceil(g/b*16)),v=[E.replacementClass,o?"".concat(E.familyPrefix,"-").concat(o):"",y].filter((function(e){return-1===d.classes.indexOf(e)})).concat(d.classes).join(" "),w={children:[],attributes:l({},d.attributes,{"data-prefix":a,"data-icon":o,class:v,role:d.attributes.role||"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(g," ").concat(b)})};h&&(w.attributes["data-fa-i2svg"]=""),c&&w.children.push({tag:"title",attributes:{id:w.attributes["aria-labelledby"]||"title-".concat(u||X())},children:[c]});var x=l({},w,{prefix:a,iconName:o,main:t,mask:r,maskId:f,transform:i,symbol:s,styles:d.styles}),O=r.found&&t.found?function(e){var n,t=e.children,r=e.attributes,a=e.main,o=e.mask,i=e.maskId,s=e.transform,c=a.width,f=a.icon,u=o.width,d=o.icon,p=J({transform:s,containerWidth:u,iconWidth:c}),h={tag:"rect",attributes:l({},Q,{fill:"white"})},m=f.children?{children:f.children.map(Z)}:{},g={tag:"g",attributes:l({},p.inner),children:[Z(l({tag:f.tag,attributes:l({},f.attributes,p.path)},m))]},b={tag:"g",attributes:l({},p.outer),children:[g]},y="mask-".concat(i||X()),v="clip-".concat(i||X()),w={tag:"mask",attributes:l({},Q,{id:y,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[h,b]},x={tag:"defs",children:[{tag:"clipPath",attributes:{id:v},children:(n=d,"g"===n.tag?n.children:[n])},w]};return t.push(x,{tag:"rect",attributes:l({fill:"currentColor","clip-path":"url(#".concat(v,")"),mask:"url(#".concat(y,")")},Q)}),{children:t,attributes:r}}(x):function(e){var n=e.children,t=e.attributes,r=e.main,a=e.transform,o=$(e.styles);if(o.length>0&&(t.style=o),V(a)){var i=J({transform:a,containerWidth:r.width,iconWidth:r.width});n.push({tag:"g",attributes:l({},i.outer),children:[{tag:"g",attributes:l({},i.inner),children:[{tag:r.icon.tag,children:r.icon.children,attributes:l({},r.icon.attributes,i.path)}]}]})}else n.push(r.icon);return{children:n,attributes:t}}(x),k=O.children,S=O.attributes;return x.children=k,x.attributes=S,s?function(e){var n=e.prefix,t=e.iconName,r=e.children,a=e.attributes,o=e.symbol;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:l({},a,{id:!0===o?"".concat(n,"-").concat(E.familyPrefix,"-").concat(t):o}),children:r}]}]}(x):function(e){var n=e.children,t=e.main,r=e.mask,a=e.attributes,o=e.styles,i=e.transform;if(V(i)&&t.found&&!r.found){var s={x:t.width/t.height/2,y:.5};a.style=$(l({},o,{"transform-origin":"".concat(s.x+i.x/16,"em ").concat(s.y+i.y/16,"em")}))}return[{tag:"svg",attributes:a,children:n}]}(x)}var ne=function(){},te=(E.measurePerformance&&b&&b.mark&&b.measure,function(e,n,t,r){var a,o,i,l=Object.keys(e),s=l.length,c=void 0!==r?function(e,n){return function(t,r,a,o){return e.call(n,t,r,a,o)}}(n,r):n;for(void 0===t?(a=1,i=e[l[0]]):(a=0,i=t);a2&&void 0!==arguments[2]?arguments[2]:{},r=t.skipHooks,a=void 0!==r&&r,o=Object.keys(n).reduce((function(e,t){var r=n[t];return!!r.icon?e[r.iconName]=r.icon:e[t]=r,e}),{});"function"!=typeof I.hooks.addPack||a?I.styles[e]=l({},I.styles[e]||{},o):I.hooks.addPack(e,o),"fas"===e&&re("fa",n)}var ae=I.styles,oe=I.shims,ie=function(){var e=function(e){return te(ae,(function(n,t,r){return n[r]=te(t,e,{}),n}),{})};e((function(e,n,t){return n[3]&&(e[n[3]]=t),e})),e((function(e,n,t){var r=n[2];return e[t]=t,r.forEach((function(n){e[n]=t})),e}));var n="far"in ae;te(oe,(function(e,t){var r=t[0],a=t[1],o=t[2];return"far"!==a||n||(a="fas"),e[r]={prefix:a,iconName:o},e}),{})};ie();I.styles;function le(e,n,t){if(e&&e[n]&&e[n][t])return{prefix:n,iconName:t,icon:e[n][t]}}function se(e){var n=e.tag,t=e.attributes,r=void 0===t?{}:t,a=e.children,o=void 0===a?[]:a;return"string"==typeof e?G(e):"<".concat(n," ").concat(function(e){return Object.keys(e||{}).reduce((function(n,t){return n+"".concat(t,'="').concat(G(e[t]),'" ')}),"").trim()}(r),">").concat(o.map(se).join(""),"")}var ce=function(e){var n={size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0};return e?e.toLowerCase().split(" ").reduce((function(e,n){var t=n.toLowerCase().split("-"),r=t[0],a=t.slice(1).join("-");if(r&&"h"===a)return e.flipX=!0,e;if(r&&"v"===a)return e.flipY=!0,e;if(a=parseFloat(a),isNaN(a))return e;switch(r){case"grow":e.size=e.size+a;break;case"shrink":e.size=e.size-a;break;case"left":e.x=e.x-a;break;case"right":e.x=e.x+a;break;case"up":e.y=e.y-a;break;case"down":e.y=e.y+a;break;case"rotate":e.rotate=e.rotate+a}return e}),n):n};function fe(e){this.name="MissingIcon",this.message=e||"Icon unavailable",this.stack=(new Error).stack}fe.prototype=Object.create(Error.prototype),fe.prototype.constructor=fe;var ue={fill:"currentColor"},de={attributeType:"XML",repeatCount:"indefinite",dur:"2s"},pe={tag:"path",attributes:l({},ue,{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})},he=l({},de,{attributeName:"opacity"});l({},ue,{cx:"256",cy:"364",r:"28"}),l({},de,{attributeName:"r",values:"28;14;28;28;14;28;"}),l({},he,{values:"1;0;1;1;0;1;"}),l({},ue,{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),l({},he,{values:"1;0;0;0;0;1;"}),l({},ue,{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),l({},he,{values:"0;0;1;1;0;0;"}),I.styles;function me(e){var n=e[0],t=e[1],r=s(e.slice(4),1)[0];return{found:!0,width:n,height:t,icon:Array.isArray(r)?{tag:"g",attributes:{class:"".concat(E.familyPrefix,"-").concat(x.GROUP)},children:[{tag:"path",attributes:{class:"".concat(E.familyPrefix,"-").concat(x.SECONDARY),fill:"currentColor",d:r[0]}},{tag:"path",attributes:{class:"".concat(E.familyPrefix,"-").concat(x.PRIMARY),fill:"currentColor",d:r[1]}}]}:{tag:"path",attributes:{fill:"currentColor",d:r}}}}I.styles;function ge(){var e="svg-inline--fa",n=E.familyPrefix,t=E.replacementClass,r='svg:not(:root).svg-inline--fa {\n overflow: visible;\n}\n\n.svg-inline--fa {\n display: inline-block;\n font-size: inherit;\n height: 1em;\n overflow: visible;\n vertical-align: -0.125em;\n}\n.svg-inline--fa.fa-lg {\n vertical-align: -0.225em;\n}\n.svg-inline--fa.fa-w-1 {\n width: 0.0625em;\n}\n.svg-inline--fa.fa-w-2 {\n width: 0.125em;\n}\n.svg-inline--fa.fa-w-3 {\n width: 0.1875em;\n}\n.svg-inline--fa.fa-w-4 {\n width: 0.25em;\n}\n.svg-inline--fa.fa-w-5 {\n width: 0.3125em;\n}\n.svg-inline--fa.fa-w-6 {\n width: 0.375em;\n}\n.svg-inline--fa.fa-w-7 {\n width: 0.4375em;\n}\n.svg-inline--fa.fa-w-8 {\n width: 0.5em;\n}\n.svg-inline--fa.fa-w-9 {\n width: 0.5625em;\n}\n.svg-inline--fa.fa-w-10 {\n width: 0.625em;\n}\n.svg-inline--fa.fa-w-11 {\n width: 0.6875em;\n}\n.svg-inline--fa.fa-w-12 {\n width: 0.75em;\n}\n.svg-inline--fa.fa-w-13 {\n width: 0.8125em;\n}\n.svg-inline--fa.fa-w-14 {\n width: 0.875em;\n}\n.svg-inline--fa.fa-w-15 {\n width: 0.9375em;\n}\n.svg-inline--fa.fa-w-16 {\n width: 1em;\n}\n.svg-inline--fa.fa-w-17 {\n width: 1.0625em;\n}\n.svg-inline--fa.fa-w-18 {\n width: 1.125em;\n}\n.svg-inline--fa.fa-w-19 {\n width: 1.1875em;\n}\n.svg-inline--fa.fa-w-20 {\n width: 1.25em;\n}\n.svg-inline--fa.fa-pull-left {\n margin-right: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-pull-right {\n margin-left: 0.3em;\n width: auto;\n}\n.svg-inline--fa.fa-border {\n height: 1.5em;\n}\n.svg-inline--fa.fa-li {\n width: 2em;\n}\n.svg-inline--fa.fa-fw {\n width: 1.25em;\n}\n\n.fa-layers svg.svg-inline--fa {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.fa-layers {\n display: inline-block;\n height: 1em;\n position: relative;\n text-align: center;\n vertical-align: -0.125em;\n width: 1em;\n}\n.fa-layers svg.svg-inline--fa {\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter, .fa-layers-text {\n display: inline-block;\n position: absolute;\n text-align: center;\n}\n\n.fa-layers-text {\n left: 50%;\n top: 50%;\n -webkit-transform: translate(-50%, -50%);\n transform: translate(-50%, -50%);\n -webkit-transform-origin: center center;\n transform-origin: center center;\n}\n\n.fa-layers-counter {\n background-color: #ff253a;\n border-radius: 1em;\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n color: #fff;\n height: 1.5em;\n line-height: 1;\n max-width: 5em;\n min-width: 1.5em;\n overflow: hidden;\n padding: 0.25em;\n right: 0;\n text-overflow: ellipsis;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n bottom: 0;\n right: 0;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom right;\n transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n bottom: 0;\n left: 0;\n right: auto;\n top: auto;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: bottom left;\n transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n right: 0;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top right;\n transform-origin: top right;\n}\n\n.fa-layers-top-left {\n left: 0;\n right: auto;\n top: 0;\n -webkit-transform: scale(0.25);\n transform: scale(0.25);\n -webkit-transform-origin: top left;\n transform-origin: top left;\n}\n\n.fa-lg {\n font-size: 1.3333333333em;\n line-height: 0.75em;\n vertical-align: -0.0667em;\n}\n\n.fa-xs {\n font-size: 0.75em;\n}\n\n.fa-sm {\n font-size: 0.875em;\n}\n\n.fa-1x {\n font-size: 1em;\n}\n\n.fa-2x {\n font-size: 2em;\n}\n\n.fa-3x {\n font-size: 3em;\n}\n\n.fa-4x {\n font-size: 4em;\n}\n\n.fa-5x {\n font-size: 5em;\n}\n\n.fa-6x {\n font-size: 6em;\n}\n\n.fa-7x {\n font-size: 7em;\n}\n\n.fa-8x {\n font-size: 8em;\n}\n\n.fa-9x {\n font-size: 9em;\n}\n\n.fa-10x {\n font-size: 10em;\n}\n\n.fa-fw {\n text-align: center;\n width: 1.25em;\n}\n\n.fa-ul {\n list-style-type: none;\n margin-left: 2.5em;\n padding-left: 0;\n}\n.fa-ul > li {\n position: relative;\n}\n\n.fa-li {\n left: -2em;\n position: absolute;\n text-align: center;\n width: 2em;\n line-height: inherit;\n}\n\n.fa-border {\n border: solid 0.08em #eee;\n border-radius: 0.1em;\n padding: 0.2em 0.25em 0.15em;\n}\n\n.fa-pull-left {\n float: left;\n}\n\n.fa-pull-right {\n float: right;\n}\n\n.fa.fa-pull-left,\n.fas.fa-pull-left,\n.far.fa-pull-left,\n.fal.fa-pull-left,\n.fab.fa-pull-left {\n margin-right: 0.3em;\n}\n.fa.fa-pull-right,\n.fas.fa-pull-right,\n.far.fa-pull-right,\n.fal.fa-pull-right,\n.fab.fa-pull-right {\n margin-left: 0.3em;\n}\n\n.fa-spin {\n -webkit-animation: fa-spin 2s infinite linear;\n animation: fa-spin 2s infinite linear;\n}\n\n.fa-pulse {\n -webkit-animation: fa-spin 1s infinite steps(8);\n animation: fa-spin 1s infinite steps(8);\n}\n\n@-webkit-keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n\n@keyframes fa-spin {\n 0% {\n -webkit-transform: rotate(0deg);\n transform: rotate(0deg);\n }\n 100% {\n -webkit-transform: rotate(360deg);\n transform: rotate(360deg);\n }\n}\n.fa-rotate-90 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";\n -webkit-transform: rotate(90deg);\n transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";\n -webkit-transform: rotate(180deg);\n transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";\n -webkit-transform: rotate(270deg);\n transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";\n -webkit-transform: scale(-1, 1);\n transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(1, -1);\n transform: scale(1, -1);\n}\n\n.fa-flip-both, .fa-flip-horizontal.fa-flip-vertical {\n -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";\n -webkit-transform: scale(-1, -1);\n transform: scale(-1, -1);\n}\n\n:root .fa-rotate-90,\n:root .fa-rotate-180,\n:root .fa-rotate-270,\n:root .fa-flip-horizontal,\n:root .fa-flip-vertical,\n:root .fa-flip-both {\n -webkit-filter: none;\n filter: none;\n}\n\n.fa-stack {\n display: inline-block;\n height: 2em;\n position: relative;\n width: 2.5em;\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n bottom: 0;\n left: 0;\n margin: auto;\n position: absolute;\n right: 0;\n top: 0;\n}\n\n.svg-inline--fa.fa-stack-1x {\n height: 1em;\n width: 1.25em;\n}\n.svg-inline--fa.fa-stack-2x {\n height: 2em;\n width: 2.5em;\n}\n\n.fa-inverse {\n color: #fff;\n}\n\n.sr-only {\n border: 0;\n clip: rect(0, 0, 0, 0);\n height: 1px;\n margin: -1px;\n overflow: hidden;\n padding: 0;\n position: absolute;\n width: 1px;\n}\n\n.sr-only-focusable:active, .sr-only-focusable:focus {\n clip: auto;\n height: auto;\n margin: 0;\n overflow: visible;\n position: static;\n width: auto;\n}\n\n.svg-inline--fa .fa-primary {\n fill: var(--fa-primary-color, currentColor);\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n fill: var(--fa-secondary-color, currentColor);\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n opacity: 0.4;\n opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n opacity: 1;\n opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n fill: black;\n}\n\n.fad.fa-inverse {\n color: #fff;\n}';if("fa"!==n||t!==e){var a=new RegExp("\\.".concat("fa","\\-"),"g"),o=new RegExp("\\--".concat("fa","\\-"),"g"),i=new RegExp("\\.".concat(e),"g");r=r.replace(a,".".concat(n,"-")).replace(o,"--".concat(n,"-")).replace(i,".".concat(t))}return r}function be(){E.autoAddCss&&!Oe&&(q(ge()),Oe=!0)}function ye(e,n){return Object.defineProperty(e,"abstract",{get:n}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map((function(e){return se(e)}))}}),Object.defineProperty(e,"node",{get:function(){if(y){var n=g.createElement("div");return n.innerHTML=e.html,n.children}}}),e}function ve(e){var n=e.prefix,t=void 0===n?"fa":n,r=e.iconName;if(r)return le(xe.definitions,t,r)||le(I.styles,t,r)}var we,xe=new(function(){function e(){!function(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}(this,e),this.definitions={}}var n,t,r;return n=e,(t=[{key:"add",value:function(){for(var e=this,n=arguments.length,t=new Array(n),r=0;r1&&void 0!==arguments[1]?arguments[1]:{},t=n.transform,r=void 0===t?Y:t,a=n.symbol,o=void 0!==a&&a,i=n.mask,s=void 0===i?null:i,c=n.maskId,f=void 0===c?null:c,u=n.title,d=void 0===u?null:u,p=n.titleId,h=void 0===p?null:p,m=n.classes,g=void 0===m?[]:m,b=n.attributes,y=void 0===b?{}:b,v=n.styles,w=void 0===v?{}:v;if(e){var x=e.prefix,O=e.iconName,k=e.icon;return ye(l({type:"icon"},e),(function(){return be(),E.autoA11y&&(d?y["aria-labelledby"]="".concat(E.replacementClass,"-title-").concat(h||X()):(y["aria-hidden"]="true",y.focusable="false")),ee({icons:{main:me(k),mask:s?me(s.icon):{found:!1,width:null,height:null,icon:{}}},prefix:x,iconName:O,transform:l({},Y,r),symbol:o,title:d,maskId:f,titleId:h,extra:{attributes:y,styles:w,classes:g}})}))}},function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=(e||{}).icon?e:ve(e||{}),r=n.mask;return r&&(r=(r||{}).icon?r:ve(r||{})),we(t,l({},n,{mask:r}))})}).call(this,t(64),t(74).setImmediate)},110:function(e,n,t){var r=t(89),a=t(80);t(118)("keys",(function(){return function(e){return a(r(e))}}))},196:function(e,n,t){var r=t(25),a=t(197),o=t(77),i=t(140),l=t(137);r(r.S,"Object",{getOwnPropertyDescriptors:function(e){for(var n,t,r=o(e),s=i.f,c=a(r),f={},u=0;c.length>u;)void 0!==(t=s(r,n=c[u++]))&&l(f,n,t);return f}})},197:function(e,n,t){var r=t(121),a=t(120),o=t(2),i=t(0).Reflect;e.exports=i&&i.ownKeys||function(e){var n=r.f(o(e)),t=a.f;return t?n.concat(t(e)):n}},198:function(e,n,t){"use strict";var r=t(25),a=t(134)(!0);r(r.P,"Array",{includes:function(e){return a(this,e,arguments.length>1?arguments[1]:void 0)}}),t(130)("includes")},199:function(e,n,t){"use strict";var r=t(25),a=t(200);r(r.P+r.F*t(201)("includes"),"String",{includes:function(e){return!!~a(this,e,"includes").indexOf(e,arguments.length>1?arguments[1]:void 0)}})},200:function(e,n,t){var r=t(100),a=t(92);e.exports=function(e,n,t){if(r(n))throw TypeError("String#"+t+" doesn't accept regex!");return String(a(e))}},201:function(e,n,t){var r=t(1)("match");e.exports=function(e){var n=/./;try{"/./"[e](n)}catch(t){try{return n[r]=!1,!"/./"[e](n)}catch(e){}}return!0}},202:function(e,n,t){"use strict";e.exports=function(e,n,t,r,a,o,i,l){if(!e){var s;if(void 0===n)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[t,r,a,o,i,l],f=0;(s=new Error(n.replace(/%s/g,(function(){return c[f++]})))).name="Invariant Violation"}throw s.framesToPop=1,s}}},269:function(e,n,t){"use strict";t.r(n),t.d(n,"default",(function(){return Wn}));t(23),t(72),t(69),t(65),t(70),t(71),t(22),t(61),t(66),t(67),t(24);var r=t(56),a=t.n(r),o=t(63);t(196),t(68),t(110),t(62),t(198),t(199);function i(){return(i=Object.assign||function(e){for(var n=1;ne.length)&&(n=e.length);for(var t=0,r=new Array(n);t0&&void 0!==arguments[0]?arguments[0]:this.active.collection;return this.refs[e].sort(j)}}]),e}();function j(e,n){return e.node.sortableInfo.index-n.node.sortableInfo.index}function T(e,n,t){return(e=e.slice()).splice(t<0?e.length+t:t,0,e.splice(n,1)[0]),e}function _(e,n){return Object.keys(e).reduce((function(t,r){return-1===n.indexOf(r)&&(t[r]=e[r]),t}),{})}var A={end:["touchend","touchcancel","mouseup"],move:["touchmove","mousemove"],start:["touchstart","mousedown"]},M=function(){if("undefined"==typeof window||"undefined"==typeof document)return"";var e=window.getComputedStyle(document.documentElement,"")||["-moz-hidden-iframe"],n=(Array.prototype.slice.call(e).join("").match(/-(moz|webkit|ms)-/)||""===e.OLink&&["","o"])[1];switch(n){case"ms":return"ms";default:return n&&n.length?n[0].toUpperCase()+n.substr(1):""}}();function P(e,n){Object.keys(n).forEach((function(t){e.style[t]=n[t]}))}function L(e,n){e.style["".concat(M,"Transform")]=null==n?"":"translate3d(".concat(n.x,"px,").concat(n.y,"px,0)")}function N(e,n){e.style["".concat(M,"TransitionDuration")]=null==n?"":"".concat(n,"ms")}function z(e,n){for(;e;){if(n(e))return e;e=e.parentNode}return null}function D(e,n,t){return Math.max(e,Math.min(t,n))}function R(e){return"px"===e.substr(-2)?parseFloat(e):0}function W(e){var n=window.getComputedStyle(e);return{bottom:R(n.marginBottom),left:R(n.marginLeft),right:R(n.marginRight),top:R(n.marginTop)}}function F(e,n){var t=n.displayName||n.name;return t?"".concat(e,"(").concat(t,")"):e}function H(e,n){var t=e.getBoundingClientRect();return{top:t.top+n.top,left:t.left+n.left}}function B(e){return e.touches&&e.touches.length?{x:e.touches[0].pageX,y:e.touches[0].pageY}:e.changedTouches&&e.changedTouches.length?{x:e.changedTouches[0].pageX,y:e.changedTouches[0].pageY}:{x:e.pageX,y:e.pageY}}function U(e){return e.touches&&e.touches.length||e.changedTouches&&e.changedTouches.length}function K(e,n){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{left:0,top:0};if(e){var r={left:t.left+e.offsetLeft,top:t.top+e.offsetTop};return e.parentNode===n?r:K(e.parentNode,n,r)}}function Y(e,n,t){return en?e-1:e>t&&e0&&t[n].height>0)&&e.getContext("2d").drawImage(t[n],0,0)})),r}function ue(e){return null!=e.sortableHandle}var de=function(){function e(n,t){d(this,e),this.container=n,this.onScrollCallback=t}return h(e,[{key:"clear",value:function(){null!=this.interval&&(clearInterval(this.interval),this.interval=null)}},{key:"update",value:function(e){var n=this,t=e.translate,r=e.minTranslate,a=e.maxTranslate,o=e.width,i=e.height,l={x:0,y:0},s={x:1,y:1},c=10,f=10,u=this.container,d=u.scrollTop,p=u.scrollLeft,h=u.scrollHeight,m=u.scrollWidth,g=0===d,b=h-d-u.clientHeight==0,y=0===p,v=m-p-u.clientWidth==0;t.y>=a.y-i/2&&!b?(l.y=1,s.y=f*Math.abs((a.y-i/2-t.y)/i)):t.x>=a.x-o/2&&!v?(l.x=1,s.x=c*Math.abs((a.x-o/2-t.x)/o)):t.y<=r.y+i/2&&!g?(l.y=-1,s.y=f*Math.abs((t.y-i/2-r.y)/i)):t.x<=r.x+o/2&&!y&&(l.x=-1,s.x=c*Math.abs((t.x-o/2-r.x)/o)),this.interval&&(this.clear(),this.isAutoScrolling=!1),0===l.x&&0===l.y||(this.interval=setInterval((function(){n.isAutoScrolling=!0;var e={left:s.x*l.x,top:s.y*l.y};n.container.scrollTop+=e.top,n.container.scrollLeft+=e.left,n.onScrollCallback(e)}),5))}}]),e}();var pe={axis:O.a.oneOf(["x","y","xy"]),contentWindow:O.a.any,disableAutoscroll:O.a.bool,distance:O.a.number,getContainer:O.a.func,getHelperDimensions:O.a.func,helperClass:O.a.string,helperContainer:O.a.oneOfType([O.a.func,"undefined"==typeof HTMLElement?O.a.any:O.a.instanceOf(HTMLElement)]),hideSortableGhost:O.a.bool,keyboardSortingTransitionDuration:O.a.number,lockAxis:O.a.string,lockOffset:O.a.oneOfType([O.a.number,O.a.string,O.a.arrayOf(O.a.oneOfType([O.a.number,O.a.string]))]),lockToContainerEdges:O.a.bool,onSortEnd:O.a.func,onSortMove:O.a.func,onSortOver:O.a.func,onSortStart:O.a.func,pressDelay:O.a.number,pressThreshold:O.a.number,keyCodes:O.a.shape({lift:O.a.arrayOf(O.a.number),drop:O.a.arrayOf(O.a.number),cancel:O.a.arrayOf(O.a.number),up:O.a.arrayOf(O.a.number),down:O.a.arrayOf(O.a.number)}),shouldCancelStart:O.a.func,transitionDuration:O.a.number,updateBeforeSortStart:O.a.func,useDragHandle:O.a.bool,useWindowAsScrollContainer:O.a.bool},he={lift:[Q],drop:[Q],cancel:[J],up:[ee,Z],down:[te,ne]},me={axis:"y",disableAutoscroll:!1,distance:0,getHelperDimensions:function(e){var n=e.node;return{height:n.offsetHeight,width:n.offsetWidth}},hideSortableGhost:!0,lockOffset:"50%",lockToContainerEdges:!1,pressDelay:0,pressThreshold:5,keyCodes:he,shouldCancelStart:function(e){return-1!==[ie,se,ce,le,ae].indexOf(e.target.tagName)||!!z(e.target,(function(e){return"true"===e.contentEditable}))},transitionDuration:300,useWindowAsScrollContainer:!1},ge=Object.keys(pe);function be(e){S()(!(e.distance&&e.pressDelay),"Attempted to set both `pressDelay` and `distance` on SortableContainer, you may only use one or the other, not both at the same time.")}function ye(e,n){try{var t=e()}catch(e){return n(!0,e)}return t&&t.then?t.then(n.bind(null,!1),n.bind(null,!0)):n(!1,value)}var ve={index:O.a.number.isRequired,collection:O.a.oneOfType([O.a.number,O.a.string]),disabled:O.a.bool},we=Object.keys(ve);var xe=t(60),Oe=t(81),ke=t(82);function Ee(e){return Math.round(255*e)}function Se(e,n,t){return Ee(e)+","+Ee(n)+","+Ee(t)}function Ie(e,n,t,r){if(void 0===r&&(r=Se),0===n)return r(t,t,t);var a=e%360/60,o=(1-Math.abs(2*t-1))*n,i=o*(1-Math.abs(a%2-1)),l=0,s=0,c=0;a>=0&&a<1?(l=o,s=i):a>=1&&a<2?(l=i,s=o):a>=2&&a<3?(s=o,c=i):a>=3&&a<4?(s=i,c=o):a>=4&&a<5?(l=i,c=o):a>=5&&a<6&&(l=o,c=i);var f=t-o/2;return r(l+f,s+f,c+f)}var Ce={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"639",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};var je=/^#[a-fA-F0-9]{6}$/,Te=/^#[a-fA-F0-9]{8}$/,_e=/^#[a-fA-F0-9]{3}$/,Ae=/^#[a-fA-F0-9]{4}$/,Me=/^rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/,Pe=/^rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*([-+]?[0-9]*[.]?[0-9]+)\s*\)$/,Le=/^hsl\(\s*(\d{0,3}[.]?[0-9]+)\s*,\s*(\d{1,3})%\s*,\s*(\d{1,3})%\s*\)$/,Ne=/^hsla\(\s*(\d{0,3}[.]?[0-9]+)\s*,\s*(\d{1,3})%\s*,\s*(\d{1,3})%\s*,\s*([-+]?[0-9]*[.]?[0-9]+)\s*\)$/;function ze(e){if("string"!=typeof e)throw new Error("Passed an incorrect argument to a color function, please pass a string representation of a color.");var n=function(e){if("string"!=typeof e)return e;var n=e.toLowerCase();return Ce[n]?"#"+Ce[n]:e}(e);if(n.match(je))return{red:parseInt(""+n[1]+n[2],16),green:parseInt(""+n[3]+n[4],16),blue:parseInt(""+n[5]+n[6],16)};if(n.match(Te)){var t=parseFloat((parseInt(""+n[7]+n[8],16)/255).toFixed(2));return{red:parseInt(""+n[1]+n[2],16),green:parseInt(""+n[3]+n[4],16),blue:parseInt(""+n[5]+n[6],16),alpha:t}}if(n.match(_e))return{red:parseInt(""+n[1]+n[1],16),green:parseInt(""+n[2]+n[2],16),blue:parseInt(""+n[3]+n[3],16)};if(n.match(Ae)){var r=parseFloat((parseInt(""+n[4]+n[4],16)/255).toFixed(2));return{red:parseInt(""+n[1]+n[1],16),green:parseInt(""+n[2]+n[2],16),blue:parseInt(""+n[3]+n[3],16),alpha:r}}var a=Me.exec(n);if(a)return{red:parseInt(""+a[1],10),green:parseInt(""+a[2],10),blue:parseInt(""+a[3],10)};var o=Pe.exec(n);if(o)return{red:parseInt(""+o[1],10),green:parseInt(""+o[2],10),blue:parseInt(""+o[3],10),alpha:parseFloat(""+o[4])};var i=Le.exec(n);if(i){var l="rgb("+Ie(parseInt(""+i[1],10),parseInt(""+i[2],10)/100,parseInt(""+i[3],10)/100)+")",s=Me.exec(l);if(!s)throw new Error("Couldn't generate valid rgb string from "+n+", it returned "+l+".");return{red:parseInt(""+s[1],10),green:parseInt(""+s[2],10),blue:parseInt(""+s[3],10)}}var c=Ne.exec(n);if(c){var f="rgb("+Ie(parseInt(""+c[1],10),parseInt(""+c[2],10)/100,parseInt(""+c[3],10)/100)+")",u=Me.exec(f);if(!u)throw new Error("Couldn't generate valid rgb string from "+n+", it returned "+f+".");return{red:parseInt(""+u[1],10),green:parseInt(""+u[2],10),blue:parseInt(""+u[3],10),alpha:parseFloat(""+c[4])}}throw new Error("Couldn't parse the color string. Please provide the color as a string in hex, rgb, rgba, hsl or hsla notation.")}function De(e){return function(e){var n,t=e.red/255,r=e.green/255,a=e.blue/255,o=Math.max(t,r,a),i=Math.min(t,r,a),l=(o+i)/2;if(o===i)return void 0!==e.alpha?{hue:0,saturation:0,lightness:l,alpha:e.alpha}:{hue:0,saturation:0,lightness:l};var s=o-i,c=l>.5?s/(2-o-i):s/(o+i);switch(o){case t:n=(r-a)/s+(r=1?Ue(e,n,t):"rgba("+e+","+n+","+t+","+r+")";if("object"==typeof e&&void 0===n&&void 0===t&&void 0===r)return e.alpha>=1?Ue(e.red,e.green,e.blue):"rgba("+e.red+","+e.green+","+e.blue+","+e.alpha+")";throw new Error("Passed invalid arguments to rgba, please pass multiple numbers e.g. rgb(255, 205, 100, 0.75) or an object e.g. rgb({ red: 255, green: 205, blue: 100, alpha: 0.75 }).")}var Ye="Passed invalid argument to toColorString, please pass a RgbColor, RgbaColor, HslColor or HslaColor object.";function qe(e){if("object"!=typeof e)throw new Error(Ye);if(function(e){return"number"==typeof e.red&&"number"==typeof e.green&&"number"==typeof e.blue&&"number"==typeof e.alpha}(e))return Ke(e);if(function(e){return"number"==typeof e.red&&"number"==typeof e.green&&"number"==typeof e.blue&&("number"!=typeof e.alpha||void 0===e.alpha)}(e))return Ue(e);if(function(e){return"number"==typeof e.hue&&"number"==typeof e.saturation&&"number"==typeof e.lightness&&"number"==typeof e.alpha}(e))return function(e,n,t,r){if("number"==typeof e&&"number"==typeof n&&"number"==typeof t&&"number"==typeof r)return r>=1?Be(e,n,t):"rgba("+Ie(e,n,t)+","+r+")";if("object"==typeof e&&void 0===n&&void 0===t&&void 0===r)return e.alpha>=1?Be(e.hue,e.saturation,e.lightness):"rgba("+Ie(e.hue,e.saturation,e.lightness)+","+e.alpha+")";throw new Error("Passed invalid arguments to hsla, please pass multiple numbers e.g. hsl(360, 0.75, 0.4, 0.7) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75, alpha: 0.7 }).")}(e);if(function(e){return"number"==typeof e.hue&&"number"==typeof e.saturation&&"number"==typeof e.lightness&&("number"!=typeof e.alpha||void 0===e.alpha)}(e))return function(e,n,t){if("number"==typeof e&&"number"==typeof n&&"number"==typeof t)return Be(e,n,t);if("object"==typeof e&&void 0===n&&void 0===t)return Be(e.hue,e.saturation,e.lightness);throw new Error("Passed invalid arguments to hsl, please pass multiple numbers e.g. hsl(360, 0.75, 0.4) or an object e.g. rgb({ hue: 255, saturation: 0.4, lightness: 0.75 }).")}(e);throw new Error(Ye)}function Xe(e){return function e(n,t,r){return function(){var a=r.concat(Array.prototype.slice.call(arguments));return a.length>=t?n.apply(this,a):e(n,t,a)}}(e,e.length,[])}function Ge(e,n,t){return Math.max(e,Math.min(n,t))}function $e(e,n){var t=De(n);return qe(i({},t,{lightness:Ge(0,1,t.lightness+parseFloat(e))}))}var Ve=Xe($e);function Je(){var e=function(e,n){n||(n=e.slice(0));return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}(["\ndisplay: block;\nheight: 26px;\nfloat: right;\nwidth: 100px;\nright: 20px;\n\na {\n display: block;\n transition: all 0.3s ease-out;\n}\nlabel,\n> span {\n line-height: 26px;\n vertical-align: middle;\n}\n\n* {\n box-sizing: border-box; \n outline: 0!important\n}\n\nposition: relative;\ninput {\n position: absolute;\n opacity: 0;\n}\n\nlabel {\n position: relative;\n z-index: 2;\n width: 50%;\n height: 100%;\n margin: "," 0 0 0;\n text-align: center;\n float: left;\n}\n\na {\n position: absolute;\n top: 0;\n padding: 0;\n z-index: 1;\n width: 50%;\n height: 100%;\n color: white;\n border: solid 1px #279CBB!important;\n background-color: #2EACCE!important;\n left: 0;\n border-radius: 3px!important;\n}\n\ninput:last-of-type:checked ~ a {\n border: solid 1px #CA6F6F!important;\n background-color: #E08F95!important;\n left: 50% ;\n border-radius: 3px!important;\n}\n\ninput:disabled ~ a {\n border: solid 1px lighten(gray,20%) !important;\n background-color: lighten(gray,30%)\t!important;\n // box-shadow: "," 0 -1px 0 inset !important;\n}\n\nmargin-top: ",";\nbackground-color: #eee;\nborder-radius: 3px!important;\ncolor: #555;\ntext-align: center;\nbox-shadow: "," 0 1px 4px 1px inset;\n\nlabel {\n text-transform: uppercase;\n color: #bbb;\n font-weight: 400;\n cursor: pointer;\n transition: color 0.2s ease-out;\n}\n\ninput:checked + label {\n color: white\n}\n\n> span {\n color: #666;\n text-transform: uppercase;\n cursor: pointer;\n}\n"]);return Je=function(){return e},e}var Qe=xe.default.span(Je(),(function(e){return e.legacy?"-2px":"0"}),Ve(.2,"gray"),(function(e){return e.legacy?"0":"3px"}),Ke("black",.15));function Ze(e){var n=e.enabled,t=e.onChange,r=e.id,o=e.translations;return a.a.createElement(Qe,e,a.a.createElement("input",{type:"radio","data-mollie-check":"",name:"MOLLIE_METHOD_ENABLED_".concat(r),id:"MOLLIE_METHOD_ENABLED_on_".concat(r),value:"1",checked:n,onChange:t}),a.a.createElement("label",{htmlFor:"MOLLIE_METHOD_ENABLED_on_".concat(r)},o.yes.toUpperCase()),a.a.createElement("input",{type:"radio",name:"MOLLIE_METHOD_ENABLED_".concat(r),id:"MOLLIE_METHOD_ENABLED_off_".concat(r),value:"",checked:!n,onChange:t}),a.a.createElement("label",{htmlFor:"MOLLIE_METHOD_ENABLED_off_".concat(r)},o.no.toUpperCase())," "," ",a.a.createElement("a",{className:"slide-button btn"}))}function en(){var e=sn(["\nmargin: 0 auto;\ntext-align: center;\n"]);return en=function(){return e},e}function nn(){var e=sn(["\npadding: 1px 5px;\nfont-size: 11px;\nline-height: 1.5;\nborder-radius: 3px;\ncolor: #363A41;\ndisplay: inline-block;\nmargin-bottom: 0;\nfont-weight: normal;\ntext-align: center;\nvertical-align: middle;\ncursor: pointer;\nbackground: #2eacce none;\nborder: 1px solid #0000;\nwhite-space: nowrap;\nfont-family: inherit;\nwidth: 26px!important;\nmargin-top: 6px!important;\nmargin-right: 2px!important;\n\n:hover {\n background-color: #008abd;\n -webkit-box-shadow: none;\n box-shadow: none;\n}\n\n:disabled {\n background-color: #2eacce;\n border-color: #2eacce;\n cursor: not-allowed;\n opacity: .65;\n filter: alpha(opacity=65);\n -webkit-box-shadow: none;\n box-shadow: none;\n}\n","\n"]);return nn=function(){return e},e}function tn(){var e=sn(["\nborder: solid 1px #ccc;\nbackground-color: #eee;\npadding: 0;\nfont-size: 1.4em;\ncolor: #aaa;\ncursor: move;\ntext-shadow: #fff 1px 1px;\n-webkit-border-radius: 3px;\nborder-radius: 3px;\n-webkit-box-shadow: rgba(0,0,0,0.2) 0 1px 3px inset;\nbox-shadow: rgba(0,0,0,0.2) 0 1px 3px inset;\ndisplay: block;\nwidth: 40px;\ntext-align: center;\nmargin: 0 auto;\n","\n"]);return tn=function(){return e},e}function rn(){var e=sn(["\ndisplay: table-cell;\nheight: 50px;\nvertical-align: middle;\nbox-sizing: border-box;\n"]);return rn=function(){return e},e}function an(){var e=sn(["\ndisplay: table-cell;\nwidth: 75px;\ntext-align: left;\nvertical-align: middle;\n"]);return an=function(){return e},e}function on(){var e=sn(["\ndisplay: table-cell;\nwidth: 80px!important;\nvertical-align: middle!important;\ntext-align: right!important;\n"]);return on=function(){return e},e}function ln(){var e=sn(["\ncursor: move!important;\n-webkit-touch-callout: none; /* iOS Safari */\n -webkit-user-select: none; /* Safari */\n -khtml-user-select: none; /* Konqueror HTML */\n -moz-user-select: none; /* Firefox */\n -ms-user-select: none; /* Internet Explorer/Edge */\n user-select: none; /* Non-prefixed version, currently\n supported by Chrome and Opera */\n \nborder: 1px solid #0c95fd;\nborder-bottom-width: ",";\nbackground-color: #fff;\ndisplay: table;\nwidth: 100%;\npadding: 5px 0;\nmargin-bottom: -1px;\n","\n"]);return ln=function(){return e},e}function sn(e,n){return n||(n=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}var cn=xe.default.li(ln(),(function(e){return e.last?"1px":"2px"}),(function(e){return e.legacy?"width: calc(100% - 2px);":""})),fn=xe.default.div(on()),un=xe.default.div(an()),dn=xe.default.div(rn()),pn=xe.default.span(tn(),(function(e){return e.legacy?"height: 24px;line-height: 24px;":""})),hn=xe.default.button(nn(),(function(e){return e.legacy?"height: 20px;line-height: 20px;":""})),mn=xe.default.div(en());var gn=function(e){var n,t,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{withRef:!1};return t=n=function(n){function t(){return d(this,t),b(this,y(t).apply(this,arguments))}return w(t,n),h(t,[{key:"componentDidMount",value:function(){this.register()}},{key:"componentDidUpdate",value:function(e){this.node&&(e.index!==this.props.index&&(this.node.sortableInfo.index=this.props.index),e.disabled!==this.props.disabled&&(this.node.sortableInfo.disabled=this.props.disabled)),e.collection!==this.props.collection&&(this.unregister(e.collection),this.register())}},{key:"componentWillUnmount",value:function(){this.unregister()}},{key:"register",value:function(){var e=this.props,n=e.collection,t=e.disabled,r=e.index,a=Object(k.findDOMNode)(this);a.sortableInfo={collection:n,disabled:t,index:r,manager:this.context.manager},this.node=a,this.ref={node:a},this.context.manager.add(n,this.ref)}},{key:"unregister",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.props.collection;this.context.manager.remove(e,this.ref)}},{key:"getWrappedInstance",value:function(){return S()(a.withRef,"To access the wrapped instance, you need to pass in {withRef: true} as the second argument of the SortableElement() call"),this.refs.wrappedInstance}},{key:"render",value:function(){var n=a.withRef?"wrappedInstance":null;return Object(r.createElement)(e,i({ref:n},_(this.props,we)))}}]),t}(r.Component),f(n,"displayName",F("sortableElement",e)),f(n,"contextTypes",{manager:O.a.object.isRequired}),f(n,"propTypes",ve),f(n,"defaultProps",{collection:0}),t}((function(e){var n=e.enabled,t=e.onToggle,o=e.code,i=e.translations,l=e.position,s=e.max,c=e.name,f=e.imageUrl,u=e.moveMethod,d=e.available,p=e.tipEnableSSL,h=e.config.legacy;return Object(r.useEffect)((function(){"undefined"!=typeof $&&"function"==typeof $.prototype.tooltip&&$("[data-toggle=tooltip]").tooltip()})),a.a.createElement(cn,{last:l>=s,legacy:h},a.a.createElement(fn,null,a.a.createElement(pn,{legacy:h},l+1),a.a.createElement(mn,null,a.a.createElement(hn,{legacy:h,disabled:l<=0,onClick:function(e){e.preventDefault(),u({oldIndex:l-1,newIndex:l})}},a.a.createElement(Oe.a,{icon:ke.b,style:{color:"white",pointerEvents:"none"}})),a.a.createElement(hn,{legacy:h,disabled:l>=s,onClick:function(e){e.preventDefault(),u({oldIndex:l+1,newIndex:l})}},a.a.createElement(Oe.a,{icon:ke.a,style:{color:"white",pointerEvents:"none"}})))),a.a.createElement(un,null,a.a.createElement("img",{width:"57",src:f,alt:c,style:{width:"57px"}})),a.a.createElement(dn,null,a.a.createElement("div",{style:{display:"inline-block",marginTop:"5px"}},a.a.createElement("span",null,c)),!d&&p&&a.a.createElement("p",{style:{float:"right",marginRight:"20px"},title:i.thisPaymentMethodNeedsSSLEnabled,"data-toggle":"tooltip"},a.a.createElement(Oe.a,{icon:ke.d})," ",i.notAvailable),!d&&!p&&a.a.createElement("p",{style:{float:"right",marginRight:"20px"},title:i.thisPaymentMethodIsNotAvailableOnPaymentsApi,"data-toggle":"tooltip"},a.a.createElement(Oe.a,{icon:ke.d})," ",i.notAvailable),d&&a.a.createElement(Ze,{id:o,translations:i,enabled:n,onChange:function(e){return function(e){t(o,e)}(!!e.target.value)},legacy:h})))}));function bn(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function yn(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function vn(e,n){return function(e){if(Array.isArray(e))return e}(e)||function(e,n){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var t=[],r=!0,a=!1,o=void 0;try{for(var i,l=e[Symbol.iterator]();!(r=(i=l.next()).done)&&(t.push(i.value),!n||t.length!==n);r=!0);}catch(e){a=!0,o=e}finally{try{r||null==l.return||l.return()}finally{if(a)throw o}}return t}(e,n)||function(e,n){if(!e)return;if("string"==typeof e)return wn(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);"Object"===t&&e.constructor&&(t=e.constructor.name);if("Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return wn(e,n)}(e,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function wn(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,r=new Array(n);t1&&void 0!==arguments[1]?arguments[1]:{withRef:!1};return t=n=function(n){function t(e){var n;return d(this,t),f(g(g(n=b(this,y(t).call(this,e)))),"state",{}),f(g(g(n)),"handleStart",(function(e){var t=n.props,r=t.distance,a=t.shouldCancelStart;if(2!==e.button&&!a(e)){n.touched=!0,n.position=B(e);var o=z(e.target,(function(e){return null!=e.sortableInfo}));if(o&&o.sortableInfo&&n.nodeIsChild(o)&&!n.state.sorting){var i=n.props.useDragHandle,l=o.sortableInfo,s=l.index,c=l.collection;if(l.disabled)return;if(i&&!z(e.target,ue))return;n.manager.active={collection:c,index:s},U(e)||e.target.tagName!==re||e.preventDefault(),r||(0===n.props.pressDelay?n.handlePress(e):n.pressTimer=setTimeout((function(){return n.handlePress(e)}),n.props.pressDelay))}}})),f(g(g(n)),"nodeIsChild",(function(e){return e.sortableInfo.manager===n.manager})),f(g(g(n)),"handleMove",(function(e){var t=n.props,r=t.distance,a=t.pressThreshold;if(!n.state.sorting&&n.touched&&!n._awaitingUpdateBeforeSortStart){var o=B(e),i={x:n.position.x-o.x,y:n.position.y-o.y},l=Math.abs(i.x)+Math.abs(i.y);n.delta=i,r||a&&!(l>=a)?r&&l>=r&&n.manager.isActive()&&n.handlePress(e):(clearTimeout(n.cancelTimer),n.cancelTimer=setTimeout(n.cancel,0))}})),f(g(g(n)),"handleEnd",(function(){n.touched=!1,n.cancel()})),f(g(g(n)),"cancel",(function(){var e=n.props.distance;n.state.sorting||(e||clearTimeout(n.pressTimer),n.manager.active=null)})),f(g(g(n)),"handlePress",(function(e){try{var t=n.manager.getActive(),r=function(){if(t){var r=function(){var t=p.sortableInfo.index,r=W(p),a=V(n.container),c=n.scrollContainer.getBoundingClientRect(),g=i({index:t,node:p,collection:h});if(n.node=p,n.margin=r,n.gridGap=a,n.width=g.width,n.height=g.height,n.marginOffset={x:n.margin.left+n.margin.right+n.gridGap.x,y:Math.max(n.margin.top,n.margin.bottom,n.gridGap.y)},n.boundingClientRect=p.getBoundingClientRect(),n.containerBoundingRect=c,n.index=t,n.newIndex=t,n.axis={x:o.indexOf("x")>=0,y:o.indexOf("y")>=0},n.offsetEdge=K(p,n.container),n.initialOffset=B(m?u({},e,{pageX:n.boundingClientRect.left,pageY:n.boundingClientRect.top}):e),n.initialScroll={left:n.scrollContainer.scrollLeft,top:n.scrollContainer.scrollTop},n.initialWindowScroll={left:window.pageXOffset,top:window.pageYOffset},n.helper=n.helperContainer.appendChild(fe(p)),P(n.helper,{boxSizing:"border-box",height:"".concat(n.height,"px"),left:"".concat(n.boundingClientRect.left-r.left,"px"),pointerEvents:"none",position:"fixed",top:"".concat(n.boundingClientRect.top-r.top,"px"),width:"".concat(n.width,"px")}),m&&n.helper.focus(),s&&(n.sortableGhost=p,P(p,{opacity:0,visibility:"hidden"})),n.minTranslate={},n.maxTranslate={},m){var b=d?{top:0,left:0,width:n.contentWindow.innerWidth,height:n.contentWindow.innerHeight}:n.containerBoundingRect,y=b.top,v=b.left,w=b.width,x=y+b.height,O=v+w;n.axis.x&&(n.minTranslate.x=v-n.boundingClientRect.left,n.maxTranslate.x=O-(n.boundingClientRect.left+n.width)),n.axis.y&&(n.minTranslate.y=y-n.boundingClientRect.top,n.maxTranslate.y=x-(n.boundingClientRect.top+n.height))}else n.axis.x&&(n.minTranslate.x=(d?0:c.left)-n.boundingClientRect.left-n.width/2,n.maxTranslate.x=(d?n.contentWindow.innerWidth:c.left+c.width)-n.boundingClientRect.left-n.width/2),n.axis.y&&(n.minTranslate.y=(d?0:c.top)-n.boundingClientRect.top-n.height/2,n.maxTranslate.y=(d?n.contentWindow.innerHeight:c.top+c.height)-n.boundingClientRect.top-n.height/2);l&&l.split(" ").forEach((function(e){return n.helper.classList.add(e)})),n.listenerNode=e.touches?p:n.contentWindow,m?(n.listenerNode.addEventListener("wheel",n.handleKeyEnd,!0),n.listenerNode.addEventListener("mousedown",n.handleKeyEnd,!0),n.listenerNode.addEventListener("keydown",n.handleKeyDown)):(A.move.forEach((function(e){return n.listenerNode.addEventListener(e,n.handleSortMove,!1)})),A.end.forEach((function(e){return n.listenerNode.addEventListener(e,n.handleSortEnd,!1)}))),n.setState({sorting:!0,sortingIndex:t}),f&&f({node:p,index:t,collection:h,isKeySorting:m,nodes:n.manager.getOrderedRefs(),helper:n.helper},e),m&&n.keyMove(0)},a=n.props,o=a.axis,i=a.getHelperDimensions,l=a.helperClass,s=a.hideSortableGhost,c=a.updateBeforeSortStart,f=a.onSortStart,d=a.useWindowAsScrollContainer,p=t.node,h=t.collection,m=n.manager.isKeySorting,g=function(){if("function"==typeof c){n._awaitingUpdateBeforeSortStart=!0;var t=ye((function(){var n=p.sortableInfo.index;return Promise.resolve(c({collection:h,index:n,node:p,isKeySorting:m},e)).then((function(){}))}),(function(e,t){if(n._awaitingUpdateBeforeSortStart=!1,e)throw t;return t}));if(t&&t.then)return t.then((function(){}))}}();return g&&g.then?g.then(r):r()}}();return Promise.resolve(r&&r.then?r.then((function(){})):void 0)}catch(e){return Promise.reject(e)}})),f(g(g(n)),"handleSortMove",(function(e){var t=n.props.onSortMove;"function"==typeof e.preventDefault&&e.preventDefault(),n.updateHelperPosition(e),n.animateNodes(),n.autoscroll(),t&&t(e)})),f(g(g(n)),"handleSortEnd",(function(e){var t=n.props,r=t.hideSortableGhost,a=t.onSortEnd,o=n.manager,i=o.active.collection,l=o.isKeySorting,s=n.manager.getOrderedRefs();n.listenerNode&&(l?(n.listenerNode.removeEventListener("wheel",n.handleKeyEnd,!0),n.listenerNode.removeEventListener("mousedown",n.handleKeyEnd,!0),n.listenerNode.removeEventListener("keydown",n.handleKeyDown)):(A.move.forEach((function(e){return n.listenerNode.removeEventListener(e,n.handleSortMove)})),A.end.forEach((function(e){return n.listenerNode.removeEventListener(e,n.handleSortEnd)})))),n.helper.parentNode.removeChild(n.helper),r&&n.sortableGhost&&P(n.sortableGhost,{opacity:"",visibility:""});for(var c=0,f=s.length;cr)){n.prevIndex=o,n.newIndex=a;var i=Y(n.newIndex,n.prevIndex,n.index),l=t.find((function(e){return e.node.sortableInfo.index===i})),s=l.node,c=n.containerScrollDelta,f=l.boundingClientRect||H(s,c),u=l.translate||{x:0,y:0},d=f.top+u.y-c.top,p=f.left+u.x-c.left,h=og?g/2:this.height/2,width:this.width>m?m/2:this.width/2},y=c&&h>this.index&&h<=f,v=c&&h=f,w={x:0,y:0},x=i[u].edgeOffset;x||(x=K(p,this.container),i[u].edgeOffset=x,c&&(i[u].boundingClientRect=H(p,a)));var O=u0&&i[u-1];O&&!O.edgeOffset&&(O.edgeOffset=K(O.node,this.container),c&&(O.boundingClientRect=H(O.node,a))),h!==this.index?(n&&N(p,n),this.axis.x?this.axis.y?v||hthis.containerBoundingRect.width-b.width&&O&&(w.x=O.edgeOffset.left-x.left,w.y=O.edgeOffset.top-x.top),null===this.newIndex&&(this.newIndex=h)):(y||h>this.index&&(l+o.left+b.width>=x.left&&s+o.top+b.height>=x.top||s+o.top+b.height>=x.top+g))&&(w.x=-(this.width+this.marginOffset.x),x.left+w.xthis.index&&l+o.left+b.width>=x.left?(w.x=-(this.width+this.marginOffset.x),this.newIndex=h):(v||hthis.index&&s+o.top+b.height>=x.top?(w.y=-(this.height+this.marginOffset.y),this.newIndex=h):(v||he.length)&&(n=e.length);for(var t=0,r=new Array(n);te.length)&&(n=e.length);for(var t=0,r=new Array(n);t=0&&(e._idleTimeoutId=setTimeout((function(){e._onTimeout&&e._onTimeout()}),n))},t(78),n.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||this&&this.setImmediate,n.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||this&&this.clearImmediate}).call(this,t(64))},76:function(e,n,t){var r; +/*! + Copyright (c) 2017 Jed Watson. + Licensed under the MIT License (MIT), see + http://jedwatson.github.io/classnames */!function(){"use strict";var t={}.hasOwnProperty;function a(){for(var e=[],n=0;n=0||(a[t]=e[t]);return a}(e,n);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(a[t]=e[t])}return a}function p(e){return function(e){if(Array.isArray(e)){for(var n=0,t=new Array(e.length);n0||!Array.isArray(n)&&n?c({},e,n):{}}function v(e){var n=e.icon,t=e.mask,a=e.symbol,o=e.className,i=e.title,l=b(n),s=y("classes",[].concat(p(function(e){var n,t=e.spin,r=e.pulse,a=e.fixedWidth,o=e.inverse,i=e.border,l=e.listItem,s=e.flip,f=e.size,u=e.rotation,d=e.pull,p=(c(n={"fa-spin":t,"fa-pulse":r,"fa-fw":a,"fa-inverse":o,"fa-border":i,"fa-li":l,"fa-flip-horizontal":"horizontal"===s||"both"===s,"fa-flip-vertical":"vertical"===s||"both"===s},"fa-".concat(f),null!=f),c(n,"fa-rotate-".concat(u),null!=u),c(n,"fa-pull-".concat(d),null!=d),c(n,"fa-swap-opacity",e.swapOpacity),n);return Object.keys(p).map((function(e){return p[e]?e:null})).filter((function(e){return e}))}(e)),p(o.split(" ")))),f=y("transform","string"==typeof e.transform?r.b.transform(e.transform):e.transform),d=y("mask",b(t)),h=Object(r.a)(l,u({},s,{},f,{},d,{symbol:a,title:i}));if(!h)return function(){var e;!g&&console&&"function"==typeof console.error&&(e=console).error.apply(e,arguments)}("Could not find icon",l),null;var m=h.abstract,x={};return Object.keys(e).forEach((function(n){v.defaultProps.hasOwnProperty(n)||(x[n]=e[n])})),w(m[0],x)}v.displayName="FontAwesomeIcon",v.propTypes={border:o.a.bool,className:o.a.string,mask:o.a.oneOfType([o.a.object,o.a.array,o.a.string]),fixedWidth:o.a.bool,inverse:o.a.bool,flip:o.a.oneOf(["horizontal","vertical","both"]),icon:o.a.oneOfType([o.a.object,o.a.array,o.a.string]),listItem:o.a.bool,pull:o.a.oneOf(["right","left"]),pulse:o.a.bool,rotation:o.a.oneOf([90,180,270]),size:o.a.oneOf(["lg","xs","sm","1x","2x","3x","4x","5x","6x","7x","8x","9x","10x"]),spin:o.a.bool,symbol:o.a.oneOfType([o.a.bool,o.a.string]),title:o.a.string,transform:o.a.oneOfType([o.a.string,o.a.object]),swapOpacity:o.a.bool},v.defaultProps={border:!1,className:"",mask:null,fixedWidth:!1,inverse:!1,flip:null,icon:null,listItem:!1,pull:null,pulse:!1,rotation:null,size:null,spin:!1,symbol:!1,title:"",transform:null,swapOpacity:!1};var w=function e(n,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if("string"==typeof t)return t;var a=(t.children||[]).map((function(t){return e(n,t)})),o=Object.keys(t.attributes||{}).reduce((function(e,n){var r=t.attributes[n];switch(n){case"class":e.attrs.className=r,delete t.attributes.class;break;case"style":e.attrs.style=m(r);break;default:0===n.indexOf("aria-")||0===n.indexOf("data-")?e.attrs[n.toLowerCase()]=r:e.attrs[h(n)]=r}return e}),{attrs:{}}),i=r.style,l=void 0===i?{}:i,s=d(r,["style"]);return o.attrs.style=u({},o.attrs.style,{},l),n.apply(void 0,[t.tag,u({},o.attrs,{},s)].concat(p(a)))}.bind(null,l.a.createElement)},82:function(e,n,t){"use strict";t.d(n,"a",(function(){return r})),t.d(n,"b",(function(){return a})),t.d(n,"c",(function(){return o})),t.d(n,"d",(function(){return i})),t.d(n,"e",(function(){return l})),t.d(n,"f",(function(){return s})),t.d(n,"g",(function(){return c})),t.d(n,"h",(function(){return f})),t.d(n,"i",(function(){return u})),t.d(n,"j",(function(){return d}));var r={prefix:"fas",iconName:"chevron-down",icon:[448,512,[],"f078","M207.029 381.476L12.686 187.132c-9.373-9.373-9.373-24.569 0-33.941l22.667-22.667c9.357-9.357 24.522-9.375 33.901-.04L224 284.505l154.745-154.021c9.379-9.335 24.544-9.317 33.901.04l22.667 22.667c9.373 9.373 9.373 24.569 0 33.941L240.971 381.476c-9.373 9.372-24.569 9.372-33.942 0z"]},a={prefix:"fas",iconName:"chevron-up",icon:[448,512,[],"f077","M240.971 130.524l194.343 194.343c9.373 9.373 9.373 24.569 0 33.941l-22.667 22.667c-9.357 9.357-24.522 9.375-33.901.04L224 227.495 69.255 381.516c-9.379 9.335-24.544 9.317-33.901-.04l-22.667-22.667c-9.373-9.373-9.373-24.569 0-33.941L207.03 130.525c9.372-9.373 24.568-9.373 33.941-.001z"]},o={prefix:"fas",iconName:"circle-notch",icon:[512,512,[],"f1ce","M288 39.056v16.659c0 10.804 7.281 20.159 17.686 23.066C383.204 100.434 440 171.518 440 256c0 101.689-82.295 184-184 184-101.689 0-184-82.295-184-184 0-84.47 56.786-155.564 134.312-177.219C216.719 75.874 224 66.517 224 55.712V39.064c0-15.709-14.834-27.153-30.046-23.234C86.603 43.482 7.394 141.206 8.003 257.332c.72 137.052 111.477 246.956 248.531 246.667C393.255 503.711 504 392.788 504 256c0-115.633-79.14-212.779-186.211-240.236C302.678 11.889 288 23.456 288 39.056z"]},i={prefix:"fas",iconName:"exclamation-triangle",icon:[576,512,[],"f071","M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"]},l={prefix:"fas",iconName:"redo-alt",icon:[512,512,[],"f2f9","M256.455 8c66.269.119 126.437 26.233 170.859 68.685l35.715-35.715C478.149 25.851 504 36.559 504 57.941V192c0 13.255-10.745 24-24 24H345.941c-21.382 0-32.09-25.851-16.971-40.971l41.75-41.75c-30.864-28.899-70.801-44.907-113.23-45.273-92.398-.798-170.283 73.977-169.484 169.442C88.764 348.009 162.184 424 256 424c41.127 0 79.997-14.678 110.629-41.556 4.743-4.161 11.906-3.908 16.368.553l39.662 39.662c4.872 4.872 4.631 12.815-.482 17.433C378.202 479.813 319.926 504 256 504 119.034 504 8.001 392.967 8 256.002 7.999 119.193 119.646 7.755 256.455 8z"]},s={prefix:"fas",iconName:"times",icon:[352,512,[],"f00d","M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z"]},c={prefix:"fas",iconName:"times-circle",icon:[512,512,[],"f057","M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zm121.6 313.1c4.7 4.7 4.7 12.3 0 17L338 377.6c-4.7 4.7-12.3 4.7-17 0L256 312l-65.1 65.6c-4.7 4.7-12.3 4.7-17 0L134.4 338c-4.7-4.7-4.7-12.3 0-17l65.6-65-65.6-65.1c-4.7-4.7-4.7-12.3 0-17l39.6-39.6c4.7-4.7 12.3-4.7 17 0l65 65.7 65.1-65.6c4.7-4.7 12.3-4.7 17 0l39.6 39.6c4.7 4.7 4.7 12.3 0 17L312 256l65.6 65.1z"]},f={prefix:"fas",iconName:"truck",icon:[640,512,[],"f0d1","M624 352h-16V243.9c0-12.7-5.1-24.9-14.1-33.9L494 110.1c-9-9-21.2-14.1-33.9-14.1H416V48c0-26.5-21.5-48-48-48H48C21.5 0 0 21.5 0 48v320c0 26.5 21.5 48 48 48h16c0 53 43 96 96 96s96-43 96-96h128c0 53 43 96 96 96s96-43 96-96h48c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zM160 464c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zm320 0c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zm80-208H416V144h44.1l99.9 99.9V256z"]},u={prefix:"fas",iconName:"undo",icon:[512,512,[],"f0e2","M212.333 224.333H12c-6.627 0-12-5.373-12-12V12C0 5.373 5.373 0 12 0h48c6.627 0 12 5.373 12 12v78.112C117.773 39.279 184.26 7.47 258.175 8.007c136.906.994 246.448 111.623 246.157 248.532C504.041 393.258 393.12 504 256.333 504c-64.089 0-122.496-24.313-166.51-64.215-5.099-4.622-5.334-12.554-.467-17.42l33.967-33.967c4.474-4.474 11.662-4.717 16.401-.525C170.76 415.336 211.58 432 256.333 432c97.268 0 176-78.716 176-176 0-97.267-78.716-176-176-176-58.496 0-110.28 28.476-142.274 72.333h98.274c6.627 0 12 5.373 12 12v48c0 6.627-5.373 12-12 12z"]},d={prefix:"fas",iconName:"undo-alt",icon:[512,512,[],"f2ea","M255.545 8c-66.269.119-126.438 26.233-170.86 68.685L48.971 40.971C33.851 25.851 8 36.559 8 57.941V192c0 13.255 10.745 24 24 24h134.059c21.382 0 32.09-25.851 16.971-40.971l-41.75-41.75c30.864-28.899 70.801-44.907 113.23-45.273 92.398-.798 170.283 73.977 169.484 169.442C423.236 348.009 349.816 424 256 424c-41.127 0-79.997-14.678-110.63-41.556-4.743-4.161-11.906-3.908-16.368.553L89.34 422.659c-4.872 4.872-4.631 12.815.482 17.433C133.798 479.813 192.074 504 256 504c136.966 0 247.999-111.033 248-247.998C504.001 119.193 392.354 7.755 255.545 8z"]}},88:function(e,n,t){"use strict";t(62);var r=t(56),a=t.n(r),o=t(60);function i(){var e=c(["\n background-color: black;\n border-radius: 50%;\n width: 10px;\n height: 10px;\n margin: 0 5px;\n opacity: 0.7;\n /* Animation */\n animation: "," 0.5s linear infinite;\n animation-delay: ",";\n"]);return i=function(){return e},e}function l(){var e=c(["\n display: flex;\n align-items: flex-end;\n min-height: 30px;\n"]);return l=function(){return e},e}function s(){var e=c(["\n 0% { margin-bottom: 0; }\n 50% { margin-bottom: 15px }\n 100% { margin-bottom: 0 }\n"]);return s=function(){return e},e}function c(e,n){return n||(n=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}var f=Object(o.keyframes)(s()),u=o.default.div(l()),d=o.default.div(i(),f,(function(e){return e.delay}));n.a=function(){return a.a.createElement(u,null,a.a.createElement(d,{delay:"0s"}),a.a.createElement(d,{delay:".1s"}),a.a.createElement(d,{delay:".2s"}))}}},0,["vendors~banks~carrierconfig~methodconfig~qrcode~transaction~updater","vendors~banks~carrierconfig~methodconfig~transaction~updater","vendors~banks~carrierconfig~methodconfig~qrcode~transaction","vendors~banks~carrierconfig~methodconfig~transaction","methodconfig"]]); \ No newline at end of file diff --git a/views/js/dist/qrcode.min.js b/views/js/dist/qrcode.min.js index d0c5ea338..10c590831 100644 --- a/views/js/dist/qrcode.min.js +++ b/views/js/dist/qrcode.min.js @@ -1,33 +1,33 @@ -/*! - * Copyright (c) 2012-2020, Mollie B.V. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * - Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH - * DAMAGE. - * - * @author Mollie B.V. - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ (window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["qrcode"],{51:function(r,n,e){"use strict";e.r(n);e(69),e(65),e(70),e(71),e(66),e(67),e(23),e(61),e(68),e(22),e(72),e(24);var t=e(56),o=e.n(t),a=e(84);function i(r,n){return function(r){if(Array.isArray(r))return r}(r)||function(r,n){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(r)))return;var e=[],t=!0,o=!1,a=void 0;try{for(var i,c=r[Symbol.iterator]();!(t=(i=c.next()).done)&&(e.push(i.value),!n||e.length!==n);t=!0);}catch(r){o=!0,a=r}finally{try{t||null==c.return||c.return()}finally{if(o)throw a}}return e}(r,n)||function(r,n){if(!r)return;if("string"==typeof r)return c(r,n);var e=Object.prototype.toString.call(r).slice(8,-1);"Object"===e&&r.constructor&&(e=r.constructor.name);if("Map"===e||"Set"===e)return Array.from(e);if("Arguments"===e||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e))return c(r,n)}(r,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function c(r,n){(null==n||n>r.length)&&(n=r.length);for(var e=0,t=new Array(n);e - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ (window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["transaction"],{101:function(e,t,r){"use strict";r.d(t,"a",(function(){return s})),r.d(t,"b",(function(){return i}));var n=r(124),o=function(){return Math.random().toString(36).substring(7).split("").join(".")},u={INIT:"@@redux/INIT"+o(),REPLACE:"@@redux/REPLACE"+o(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+o()}};function a(e){if("object"!=typeof e||null===e)return!1;for(var t=e;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function i(e,t,r){var o;if("function"==typeof t&&"function"==typeof r||"function"==typeof r&&"function"==typeof arguments[3])throw new Error("It looks like you are passing several store enhancers to createStore(). This is not supported. Instead, compose them together to a single function.");if("function"==typeof t&&void 0===r&&(r=t,t=void 0),void 0!==r){if("function"!=typeof r)throw new Error("Expected the enhancer to be a function.");return r(i)(e,t)}if("function"!=typeof e)throw new Error("Expected the reducer to be a function.");var c=e,s=t,f=[],d=f,l=!1;function p(){d===f&&(d=f.slice())}function h(){if(l)throw new Error("You may not call store.getState() while the reducer is executing. The reducer has already received the state as an argument. Pass it down from the top reducer instead of reading it from the store.");return s}function y(e){if("function"!=typeof e)throw new Error("Expected the listener to be a function.");if(l)throw new Error("You may not call store.subscribe() while the reducer is executing. If you would like to be notified after the store has been updated, subscribe from a component and invoke store.getState() in the callback to access the latest state. See https://redux.js.org/api-reference/store#subscribelistener for more details.");var t=!0;return p(),d.push(e),function(){if(t){if(l)throw new Error("You may not unsubscribe from a store listener while the reducer is executing. See https://redux.js.org/api-reference/store#subscribelistener for more details.");t=!1,p();var r=d.indexOf(e);d.splice(r,1),f=null}}}function v(e){if(!a(e))throw new Error("Actions must be plain objects. Use custom middleware for async actions.");if(void 0===e.type)throw new Error('Actions may not have an undefined "type" property. Have you misspelled a constant?');if(l)throw new Error("Reducers may not dispatch actions.");try{l=!0,s=c(s,e)}finally{l=!1}for(var t=f=d,r=0;re.length)&&(t=e.length);for(var r=0,n=new Array(t);re.length)&&(t=e.length);for(var r=0,n=new Array(t);r")||this}return function(e,t){function r(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}(t,e),t}(Error);function f(e){return e+1}var d=(i=function(){var e=Object(n.createContext)(null);return{StoreContext:e,useDispatch:function(){var t=Object(n.useContext)(e);if(!t)throw new s;return t.dispatch},useMappedState:function(t){var r=Object(n.useContext)(e);if(!r)throw new s;var o=Object(n.useMemo)((function(){return e=t,function(t){return n!==t&&(n=t,r=e(t)),r};var e,r,n}),[t]),i=r.getState(),d=o(i),l=Object(n.useState)(0)[1],p=Object(n.useRef)(d),h=Object(n.useRef)(o);return c((function(){p.current=d,h.current=o})),c((function(){var e=!1,t=function(){e||(function(e,t){if(a(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(var o=0;o0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case u.ReduxActionTypes.updateTranslations:return t.translations;default:return e}},config:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case u.ReduxActionTypes.updateConfig:return t.config;default:return e}},order:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case u.ReduxActionTypes.updateOrder:return t.order;default:return e}},payment:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case u.ReduxActionTypes.updatePayment:return t.payment;default:return e}},currencies:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case u.ReduxActionTypes.updateCurrencies:return t.currencies;default:return e}},viewportWidth:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:a,t=arguments.length>1?arguments[1]:void 0;switch(t.type){case u.ReduxActionTypes.updateViewportWidth:return t.width;default:return e}},orderWarning:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;switch(t.type){case u.ReduxActionTypes.updateWarning:return t.orderWarning;default:return e}}}),c=window.__REDUX_DEVTOOLS_EXTENSION__;n=Object(o.b)(i,c&&c());t.default=n},88:function(e,t,r){"use strict";r(62);var n=r(56),o=r.n(n),u=r(60);function a(){var e=s(["\n background-color: black;\n border-radius: 50%;\n width: 10px;\n height: 10px;\n margin: 0 5px;\n opacity: 0.7;\n /* Animation */\n animation: "," 0.5s linear infinite;\n animation-delay: ",";\n"]);return a=function(){return e},e}function i(){var e=s(["\n display: flex;\n align-items: flex-end;\n min-height: 30px;\n"]);return i=function(){return e},e}function c(){var e=s(["\n 0% { margin-bottom: 0; }\n 50% { margin-bottom: 15px }\n 100% { margin-bottom: 0 }\n"]);return c=function(){return e},e}function s(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}var f=Object(u.keyframes)(c()),d=u.default.div(i()),l=u.default.div(a(),f,(function(e){return e.delay}));t.a=function(){return o.a.createElement(d,null,o.a.createElement(l,{delay:"0s"}),o.a.createElement(l,{delay:".1s"}),o.a.createElement(l,{delay:".2s"}))}}}]); \ No newline at end of file diff --git a/views/js/dist/transactionOrder.min.js b/views/js/dist/transactionOrder.min.js index 83c04eeb0..87133a379 100644 --- a/views/js/dist/transactionOrder.min.js +++ b/views/js/dist/transactionOrder.min.js @@ -1,33 +1,33 @@ -/*! - * Copyright (c) 2012-2020, Mollie B.V. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * - Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH - * DAMAGE. - * - * @author Mollie B.V. - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ (window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["transactionOrder"],{129:function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(56),a=n.n(r),l=n(59);function c(){var e=Object(l.c)((function(e){return{orderWarning:e.orderWarning,translations:e.translations}})),t=e.orderWarning,n=e.translations,r="";switch(t){case"refunded":r=n.refundWarning;break;case"shipped":r=n.shipmentWarning;break;case"canceled":r=n.cancelWarning;break;default:r=""}return r?a.a.createElement(a.a.Fragment,null,a.a.createElement("div",{className:"alert alert-success"},r)):a.a.createElement(a.a.Fragment,null)}},270:function(e,t,n){"use strict";n.r(t),n.d(t,"default",(function(){return fe}));n(61),n(68),n(22),n(110);var r=n(56),a=n.n(r),l=n(59),c=n(76),i=n.n(c),o=(n(62),n(60)),u=n(128),s=n.n(u),d=n(63),f=n(91);function m(){var e=Object(l.c)((function(e){return{order:e.order,currencies:e.currencies,translations:e.translations,config:e.config}})),t=e.translations,n=e.order,r=e.currencies,c=e.config.legacy;return a.a.createElement(a.a.Fragment,null,c&&a.a.createElement("h3",null,t.transactionInfo),!c&&a.a.createElement("h4",null,t.transactionInfo),a.a.createElement("strong",null,t.transactionId),": ",a.a.createElement("span",null,n.id),a.a.createElement("br",null),a.a.createElement("strong",null,t.date),": ",a.a.createElement("span",null,s()(n.createdAt).format("YYYY-MM-DD HH:mm:ss")),a.a.createElement("br",null),a.a.createElement("strong",null,t.amount),": ",a.a.createElement("span",null,Object(f.a)(parseFloat(n.amount.value),Object(d.get)(r,n.amount.currency))),a.a.createElement("br",null))}function p(){var e=function(e,t){t||(t=e.slice(0));return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}(["\n@media only screen and (min-width: 992px) {\n margin-left: -5px!important;\n margin-right: 5px!important;\n}\n"]);return p=function(){return e},e}var b=o.default.div(p());function y(){var e=Object(l.c)((function(e){return{translations:e.translations,order:e.order,currencies:e.currencies,config:e.config}})),t=e.translations;return e.config.legacy?a.a.createElement(m,null):a.a.createElement(b,{className:"col-md-3 panel"},a.a.createElement("div",{className:"panel-heading"},t.paymentInfo),a.a.createElement(m,null))}n(69),n(70),n(71),n(66),n(67),n(23),n(72),n(75),n(24),n(65);var g=n(84),h=n(90),v=n.n(h);function E(){var e=Object(r.useCallback)(Object(l.c)((function(e){return{translations:e.translations,viewportWidth:e.viewportWidth}})),[]),t=e.translations,n=e.viewportWidth;return a.a.createElement("thead",null,a.a.createElement("tr",null,a.a.createElement("th",null,a.a.createElement("span",{className:"title_box"},a.a.createElement("strong",null,t.product))),a.a.createElement("th",null,a.a.createElement("span",{className:"title_box"},t.status)),n<1390&&a.a.createElement("th",null,a.a.createElement("span",{className:"title_box"},a.a.createElement("span",null,t.shipped),a.a.createElement("br",null)," ",a.a.createElement("span",{style:{whiteSpace:"nowrap"}},"/ ",t.canceled),a.a.createElement("br",null)," ",a.a.createElement("span",{style:{whiteSpace:"nowrap"}},"/ ",t.refunded))),n>=1390&&a.a.createElement(a.a.Fragment,null,a.a.createElement("th",null,a.a.createElement("span",{className:"title_box"},t.shipped)),a.a.createElement("th",null,a.a.createElement("span",{className:"title_box"},t.canceled)),a.a.createElement("th",null,a.a.createElement("span",{className:"title_box"},t.refunded))),a.a.createElement("th",null,a.a.createElement("span",{className:"title_box"},t.unitPrice)),a.a.createElement("th",null,a.a.createElement("span",{className:"title_box"},t.vatAmount)),a.a.createElement("th",null,a.a.createElement("span",{className:"title_box"},t.totalAmount)),a.a.createElement("th",null)))}n(104);var w=n(81),O=n(82);function j(e){var t=e.loading,n=e.ship,r=e.cancel,c=e.refund,i=Object(l.c)((function(e){return{translations:e.translations,order:e.order,config:e.config}})),o=i.translations,u=i.order,s=i.config.legacy;function f(){for(var e=0,t=Object.values(u.lines.filter((function(e){return"discount"!==e.type})));e=1)return!0}return!1}function m(){for(var e=0,t=Object.values(u.lines.filter((function(e){return"discount"!==e.type})));e=1)return!0}return!1}function p(){for(var e=0,t=Object.values(u.lines.filter((function(e){return"discount"!==e.type})));e=1)return!0}return!1}return a.a.createElement("tfoot",null,a.a.createElement("tr",null,a.a.createElement("td",{colSpan:10},a.a.createElement("div",{className:"btn-group",role:"group"},a.a.createElement("button",{type:"button",onClick:function(){return n(Object(d.compact)(u.lines.filter((function(e){return"discount"!==e.type}))))},className:"btn btn-primary",disabled:t||!m(),style:{cursor:t||!m()?"not-allowed":"pointer",opacity:t||!m()?.8:1}},s&&a.a.createElement("img",{src:"../img/admin/delivery.gif",alt:"",style:{filter:t||!m()?"grayscale(100%)":null,WebkitFilter:t||!m()?"grayscale(100%)":null}}),!s&&a.a.createElement(w.a,{icon:t?O.c:O.h,spin:t})," ",o.shipAll),a.a.createElement("button",{type:"button",onClick:function(){return c(Object(d.compact)(u.lines.filter((function(e){return"discount"!==e.type}))))},className:"btn btn-default",disabled:t||!p(),style:{cursor:t||!p()?"not-allowed":"pointer",opacity:t||!p()?.8:1}},s&&a.a.createElement("img",{src:"../img/admin/money.gif",alt:"",style:{filter:t||!p()?"grayscale(100%)":null,WebkitFilter:t||!p()?"grayscale(100%)":null}}),!s&&a.a.createElement(w.a,{icon:t?O.c:O.j,spin:t})," ",o.refundAll),a.a.createElement("button",{type:"button",onClick:function(){return r(Object(d.compact)(u.lines.filter((function(e){return"discount"!==e.type}))))},className:"btn btn-default",disabled:t||!f(),style:{cursor:t||!f()?"not-allowed":"pointer",opacity:t||!f()?.8:1}},s&&a.a.createElement("img",{src:"../img/admin/disabled.gif",alt:"",style:{filter:t||!f()?"grayscale(100%)":null,WebkitFilter:t||!f()?"grayscale(100%)":null}}),!s&&a.a.createElement(w.a,{icon:t?O.c:O.f,spin:t})," ",o.cancelAll)))))}var x=n(206);function k(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,a=!1,l=void 0;try{for(var c,i=e[Symbol.iterator]();!(r=(c=i.next()).done)&&(n.push(c.value),!t||n.length!==t);r=!0);}catch(e){a=!0,l=e}finally{try{r||null==i.return||i.return()}finally{if(a)throw l}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return S(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return S(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function S(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n0}));var a=Object(d.findIndex)(r,(function(t){return t.id===e}));a<0||(n>0?r[a].newQuantity=n:r.length>1&&r.splice(a,1),o(Object(d.cloneDeep)(r)),Object(d.forEach)(r,(function(e){void 0!==e.quantity&&(e.quantity=e.newQuantity,delete e.newQuantity)})),t(r))}Object(r.useEffect)((function(){u(n[0].id,n[0]["".concat(l,"Quantity")])}),[]);var s=Object(d.cloneDeep)(i);return Object(d.remove)(s,(function(e){return e["".concat(l,"Quantity")]<1})),a.a.createElement(x.Table,{bordered:!0},a.a.createElement("tbody",null,i.map((function(e){return a.a.createElement(x.Tr,{key:e.id,light:!0},a.a.createElement("td",{style:{color:"#555"}},e.name),a.a.createElement("td",{style:{color:"#555"}},a.a.createElement(A,{value:e.newQuantity||e["".concat(l,"Quantity")],onChange:function(t){var n=t.target.value;return u(e.id,parseInt(n,10))}},Object(d.range)(1,e["".concat(l,"Quantity")]+1).map((function(e){return a.a.createElement(F,{key:e,value:e},e,"x")}))),a.a.createElement(w.a,{icon:O.a,style:{marginLeft:"-20px",pointerEvents:"none"}})),a.a.createElement("td",{style:{display:i.length>1?"auto":"none"}},a.a.createElement(Q,{icon:O.g,onClick:function(){return u(e.id,0)}})))}))))}function P(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,a=!1,l=void 0;try{for(var c,i=e[Symbol.iterator]();!(r=(c=i.next()).done)&&(n.push(c.value),!t||n.length!==t);r=!0);}catch(e){a=!0,l=e}finally{try{r||null==i.return||i.return()}finally{if(a)throw l}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return W(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return W(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function W(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n0&&u([t])},role:"button"},a.a.createElement(w.a,{icon:n?O.c:O.i,spin:n})," ",f.refund),b=d?a.a.createElement("button",{style:{cursor:t.cancelableQuantity<1?"not-allowed":"pointer",width:"100px",textAlign:"left",opacity:n||t.refundableQuantity<1||"discount"===t.type?.8:1},title:"",disabled:n||t.cancelableQuantity<1||"discount"===t.type,onClick:function(){return o([t])}},a.a.createElement("img",{src:"../img/admin/disabled.gif",alt:f.cancel,style:{filter:n||t.cancelableQuantity<1||"discount"===t.type?"grayscale(100%)":void 0,WebkitFilter:n||t.cancelableQuantity<1||"discount"===t.type?"grayscale(100%)":void 0}})," ",f.cancel):a.a.createElement("a",{style:{cursor:n||t.cancelableQuantity<1||"discount"===t.type?"not-allowed":"pointer",opacity:n||t.cancelableQuantity<1||"discount"===t.type?.8:1},onClick:function(){return t.cancelableQuantity>0&&o([t])},role:"button"},a.a.createElement(w.a,{icon:n?O.c:O.f,spin:n})," ",f.cancel),y=d?a.a.createElement("div",null,m,a.a.createElement("br",null),p,a.a.createElement("br",null),b):a.a.createElement("div",{className:i()({"btn-group":!d})},m,a.a.createElement("button",{type:"button",className:i()({btn:!d,"btn-default":!d,"dropdown-toggle":!d}),"data-toggle":d?null:"dropdown",disabled:n||t.refundableQuantity<1&&t.cancelableQuantity<1||"discount"===t.type},a.a.createElement("span",{className:"caret"}," ")),a.a.createElement("ul",{className:"dropdown-menu"},a.a.createElement("li",null,p),a.a.createElement("li",null,b)));return a.a.createElement("div",{className:i()({"btn-group-action":!d})},y)}function X(e,t,n,r,a,l,c){try{var i=e[l](c),o=i.value}catch(e){return void n(e)}i.done?t(o):Promise.resolve(o).then(r,a)}function Z(e){return function(){var t=this,n=arguments;return new Promise((function(r,a){var l=e.apply(t,n);function c(e){X(l,r,a,c,i,"next",e)}function i(e){X(l,r,a,c,i,"throw",e)}c(void 0)}))}}function ee(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,a=!1,l=void 0;try{for(var c,i=e[Symbol.iterator]();!(r=(c=i.next()).done)&&(n.push(c.value),!t||n.length!==t);r=!0);}catch(e){a=!0,l=e}finally{try{r||null==i.return||i.return()}finally{if(a)throw l}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return te(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return te(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function te(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n=1390&&a.a.createElement("td",null,e.quantityShipped),y>=1390&&a.a.createElement("td",null,e.quantityCanceled),y>=1390&&a.a.createElement("td",null,e.quantityRefunded),a.a.createElement("td",null,Object(f.a)(parseFloat(e.unitPrice.value),Object(d.get)(m,e.unitPrice.currency))),a.a.createElement("td",null,Object(f.a)(parseFloat(e.vatAmount.value),Object(d.get)(m,e.vatAmount.currency))," (",e.vatRate,"%)"),a.a.createElement("td",null,Object(f.a)(parseFloat(e.totalAmount.value),Object(d.get)(m,e.totalAmount.currency))),a.a.createElement("td",{className:i()({actions:!p})},a.a.createElement(G,{loading:t,line:e,refundLine:x,shipLine:w,cancelLine:S})))}))),a.a.createElement(j,{loading:t,ship:w,refund:x,cancel:S})))}function le(){var e=Object(r.useCallback)(Object(l.c)((function(e){return{translations:e.translations,config:e.config}})),[]),t=e.translations;return e.config.legacy?a.a.createElement("div",{className:"error"},t.thereAreNoProducts):a.a.createElement("div",{className:"table-responsive"},a.a.createElement("table",{className:"table"},a.a.createElement(E,null),a.a.createElement("tbody",null,a.a.createElement("tr",null,a.a.createElement("td",{className:"list-empty hidden-print",colSpan:3},a.a.createElement("div",{className:"list-empty-msg"},a.a.createElement("i",{className:"icon-warning-sign list-empty-icon"}),t.thereAreNoProducts))))))}function ce(){var e=function(e,t){t||(t=e.slice(0));return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}(["\n@media only screen and (min-width: 992px) {\n margin-left: 5px!important;\n margin-right: -5px!important;\n}\n"]);return ce=function(){return e},e}var ie=o.default.div(ce());function oe(){var e=Object(l.c)((function(e){return{translations:e.translations,order:e.order,config:e.config}})),t=e.translations,n=e.order,r=e.config.legacy;return r?a.a.createElement(a.a.Fragment,null,r&&a.a.createElement("h3",null,t.products),!r&&a.a.createElement("h4",null,t.products),!n||!n.lines.length&&a.a.createElement(le,null),!!n&&!!n.lines.length&&a.a.createElement(ae,null)):a.a.createElement(ie,{className:"col-md-9 panel"},a.a.createElement("div",{className:"panel-heading"},t.products),!n||!n.lines.length&&a.a.createElement(le,null),!!n&&!!n.lines.length&&a.a.createElement(ae,null))}var ue=n(88);function se(){var e=Object(r.useCallback)(Object(l.c)((function(e){return{order:e.order,config:e.config}})),[]),t=e.order,n=e.config.legacy;return a.a.createElement(a.a.Fragment,null,!t&&a.a.createElement(ue.a,null),!!t&&t.status&&a.a.createElement("div",{className:i()({"panel-body":!n,row:!n})},a.a.createElement(y,null),a.a.createElement(oe,null)))}var de=n(129);function fe(){var e=Object(r.useCallback)(Object(l.c)((function(e){return{translations:e.translations,config:e.config,order:e.order}})),[]),t=e.config,n=t.legacy,c=t.moduleDir,i=e.config;return Object.keys(i).length<=0?null:n?a.a.createElement("fieldset",{style:{marginTop:"14px"}},a.a.createElement("legend",null,a.a.createElement("img",{src:"".concat(c,"views/img/logo_small.png"),width:"32",height:"32",alt:"Mollie logo",style:{height:"16px",width:"16px",opacity:.8}})," ",a.a.createElement("span",null,"Mollie")," "),a.a.createElement(de.a,null),a.a.createElement(se,null)):a.a.createElement("div",{className:"panel"},a.a.createElement("div",{className:"panel-heading"},a.a.createElement("img",{src:"".concat(c,"views/img/mollie_panel_icon.png"),width:"32",height:"32",alt:"Mollie logo",style:{height:"16px",width:"16px",opacity:.8}})," ",a.a.createElement("span",null,"Mollie")," "),a.a.createElement(de.a,null),a.a.createElement(se,null))}},91:function(e,t,n){"use strict";n.d(t,"a",(function(){return s}));n(66),n(67),n(149),n(109),n(75);var r=n(150),a=n.n(r),l=n(63);function c(e){return(c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var i=function(e,t,n,r){"string"==typeof t&&(t=parseInt(t,10)),"string"==typeof e&&(e=parseFloat(e));for(var a=(e=e.toFixed(t))+"",l=a.split("."),c=2===l.length?l[0]:a,i=("0."+(2===l.length?l[1]:0)).substr(2),o=c.length,u=1;u<4;u++)parseFloat(e)>=Math.pow(10,3*u)&&(c=c.substring(0,o-3*u)+n+c.substring(o-3*u));return 0===t?c:c+r+(i||"00")};function o(e,t){var n;return e>=0?(n=Math.floor(e+.5),(3===t&&e===-.5+n||4===t&&e===.5+2*Math.floor(n/2)||5===t&&e===.5+2*Math.floor(n/2)-1)&&(n-=1)):(n=Math.ceil(e-.5),(3===t&&e===.5+n||4===t&&e===2*Math.ceil(n/2)-.5||5===t&&e===2*Math.ceil(n/2)-.5+1)&&(n+=1)),n}var u=function(e,t){var n,r;if("string"==typeof e&&(e=parseFloat(e)),void 0===t&&(t=2),0===(n=void 0===window.roundMode?2:window.roundMode))return function(e,t){void 0===t&&(t=0);var n=0===t?1:Math.pow(10,t),r=String(e*n);return"0"===r[r.length-1]?e:Math.ceil(e*n)/n}(e,t);if(1===n)return function(e,t){void 0===t&&(t=0);var n=0===t?1:Math.pow(10,t),r=String(e*n);return"0"===r[r.length-1]?e:Math.floor(e*n)/n}(e,t);if(2===n)return function(e,t){var n=Math.pow(10,t),r=e*n;return(r=Math.floor(10*r)-10*Math.floor(r)>=5?Math.ceil(r):Math.floor(r))/n}(e,t);if(3==n||4==n||5==n){var a=14-Math.floor(function(e){return Math.log(e)/Math.LN10}(Math.abs(e))),l=Math.pow(10,Math.abs(t));if(a>t&&a-t<15){var c=Math.pow(10,Math.abs(a));r=o(r=a>=0?e*c:e/c,n),r/=c=Math.pow(10,Math.abs(t-a))}else if(r=t>=0?e*l:e/l,Math.abs(r)>=1e15)return e;return r=o(r,n),t>0?r/=l:r*=l,r}},s=function(e,t){return void 0===t?(console.error("Currency undefined"),""):"string"==typeof window._PS_VERSION_&&a()(window._PS_VERSION_,"1.7.0.0",">=")||void 0!==window.formatCurrencyCldr?new Intl.NumberFormat(Object(l.get)(document.documentElement,"lang"),{style:"currency",currency:t.iso_code}).format(e):function(e,t,n,r){"string"==typeof e&&(e=parseFloat(e));var a,l="EUR";void 0!==window.currency_iso_code&&3===window.currency_iso_code.length?l=window.currency_iso_code:"object"===c(window.currency)&&void 0!==window.currency.iso_code&&3===window.currency.iso_code.length&&(l=window.currency.iso_code),void 0!==window.priceDisplayPrecision&&(a=window.priceDisplayPrecision);try{if(void 0!==window.currencyModes&&void 0!==window.currencyModes[l]&&window.currencyModes[l]){e=u(e.toFixed(10),a);var o=document.documentElement.lang;5===o.length?o=o.substring(0,2).toLowerCase()+"-"+o.substring(3,5).toUpperCase():void 0!==window.full_language_code&&5===window.full_language_code.length?o=window.full_language_code.substring(0,2).toLowerCase()+"-"+window.full_language_code.substring(3,5).toUpperCase():5===window.getBrowserLocale().length&&(o=window.getBrowserLocale().substring(0,2).toLowerCase()+"-"+window.getBrowserLocale().substring(3,5).toUpperCase());var s=e.toLocaleString(o,{style:"currency",currency:"USD",currencyDisplay:"code"});return n&&(s=s.replace("USD",n)),s}}catch(e){}var d="";return e=u(e.toFixed(10),a),void 0!==r&&r&&(d=" "),1==t?n+d+i(e,a,",","."):2==t?i(e,a," ",",")+d+n:3==t?n+d+i(e,a,".",","):4==t?i(e,a,",",".")+d+n:5==t?n+d+i(e,a,"'","."):String(e)}(e,t.format,t.sign,t.blank)}}},0,["vendors~sweetalert"]]); \ No newline at end of file diff --git a/views/js/dist/transactionRefund.min.js b/views/js/dist/transactionRefund.min.js index 6583c6152..544bdde1d 100644 --- a/views/js/dist/transactionRefund.min.js +++ b/views/js/dist/transactionRefund.min.js @@ -1,33 +1,33 @@ -/*! - * Copyright (c) 2012-2020, Mollie B.V. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * - Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH - * DAMAGE. - * - * @author Mollie B.V. - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ (window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["transactionRefund"],{129:function(e,n,t){"use strict";t.d(n,"a",(function(){return o}));var a=t(56),r=t.n(a),l=t(59);function o(){var e=Object(l.c)((function(e){return{orderWarning:e.orderWarning,translations:e.translations}})),n=e.orderWarning,t=e.translations,a="";switch(n){case"refunded":a=t.refundWarning;break;case"shipped":a=t.shipmentWarning;break;case"canceled":a=t.cancelWarning;break;default:a=""}return a?r.a.createElement(r.a.Fragment,null,r.a.createElement("div",{className:"alert alert-success"},a)):r.a.createElement(r.a.Fragment,null)}},271:function(e,n,t){"use strict";t.r(n),t.d(n,"default",(function(){return Y}));t(61),t(68),t(22),t(110);var a=t(56),r=t.n(a),l=t(59),o=(t(62),t(60)),c=t(128),i=t.n(c),u=t(63),s=t(91);function m(){var e=Object(l.c)((function(e){return{payment:e.payment,currencies:e.currencies,translations:e.translations,config:e.config}})),n=e.translations,t=e.payment,a=e.currencies,o=e.config.legacy;return r.a.createElement(r.a.Fragment,null,o&&r.a.createElement("h3",null,n.transactionInfo),!o&&r.a.createElement("h4",null,n.transactionInfo),r.a.createElement("strong",null,n.transactionId),": ",r.a.createElement("span",null,t.id),r.a.createElement("br",null),r.a.createElement("strong",null,n.date),": ",r.a.createElement("span",null,i()(t.createdAt).format("YYYY-MM-DD HH:mm:ss")),r.a.createElement("br",null),r.a.createElement("strong",null,n.amount),": ",r.a.createElement("span",null,Object(s.a)(parseFloat(t.amount.value),Object(u.get)(a,t.amount.currency))),r.a.createElement("br",null))}function d(){var e=function(e,n){n||(n=e.slice(0));return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}(["\n@media only screen and (min-width: 992px) {\n margin-left: -5px!important;\n margin-right: 5px!important;\n}\n"]);return d=function(){return e},e}var f=o.default.div(d());function p(){var e=Object(l.c)((function(e){return{translations:e.translations,config:e.config}})),n=e.translations;return e.config.legacy?r.a.createElement(r.a.Fragment,null,r.a.createElement(m,null),r.a.createElement("br",null)):r.a.createElement(f,{className:"col-md-3 panel"},r.a.createElement("div",{className:"panel-heading"},n.paymentInfo),r.a.createElement(m,null))}function g(){var e=Object(l.c)((function(e){return{translations:e.translations}})).translations;return r.a.createElement("thead",null,r.a.createElement("tr",null,r.a.createElement("th",null,r.a.createElement("span",{className:"title_box"},r.a.createElement("strong",null,e.ID))),r.a.createElement("th",null,r.a.createElement("span",{className:"title_box"},e.date)),r.a.createElement("th",null,r.a.createElement("span",{className:"title_box"},e.amount))))}function y(){var e=Object(l.c)((function(e){return{translations:e.translations}})).translations;return r.a.createElement("div",{className:"table-responsive"},r.a.createElement("table",{className:"table"},r.a.createElement(g,null),r.a.createElement("tbody",null,r.a.createElement("tr",null,r.a.createElement("td",{className:"list-empty hidden-print",colSpan:3},r.a.createElement("div",{className:"list-empty-msg"},r.a.createElement("i",{className:"icon-warning-sign list-empty-icon"}),e.thereAreNoRefunds))))))}function b(){var e=Object(l.c)((function(e){return{payment:e.payment,currencies:e.currencies}})),n=e.payment,t=e.currencies;return r.a.createElement("div",{className:"table-responsive"},r.a.createElement("table",{className:"table"},r.a.createElement(g,null),r.a.createElement("tbody",null,n.refunds.map((function(e){return r.a.createElement("tr",{key:e.id,style:{marginBottom:"100px"}},r.a.createElement("td",{style:{width:"100px"}},r.a.createElement("strong",null,e.id)),r.a.createElement("td",null,i()(e.createdAt).format("YYYY-MM-DD HH:mm:ss")),r.a.createElement("td",null,Object(s.a)(parseFloat(e.amount.value),Object(u.get)(t,e.amount.currency))))})))))}function v(){var e=Object(l.c)((function(e){return{translations:e.translations,payment:e.payment}})),n=e.translations,t=e.payment;return r.a.createElement(r.a.Fragment,null,r.a.createElement("h4",null,n.refundHistory),!t.refunds.length&&r.a.createElement(y,null),!!t.refunds.length&&r.a.createElement(b,null))}t(23),t(72),t(69),t(65),t(70),t(71),t(66),t(67),t(75),t(24);var h=t(90),E=t.n(h),w=t(103),x=t(76),M=t.n(x);function N(e){var n=e.loading,t=e.disabled,a=e.refundPayment,o=Object(l.c)((function(e){return{translations:e.translations}})).translations;return r.a.createElement("button",{type:"button",className:"btn btn-default",disabled:n||t,onClick:function(){return a(!1)},style:{marginRight:"10px"}},r.a.createElement("i",{className:M()({icon:!0,"icon-undo":!n,"icon-circle-o-notch":n,"icon-spin":n})})," ",o.refundOrder)}function O(e){var n=e.loading,t=e.disabled,a=e.refundPayment,o=Object(l.c)((function(e){return{translations:e.translations,config:e.config}})),c=o.translations,i=o.config.legacy,u=r.a.createElement("button",{className:"btn btn-default",type:"button",disabled:n||t,onClick:function(){return a(!0)}},!i&&r.a.createElement("i",{className:M()({icon:!0,"icon-undo":!n,"icon-circle-o-notch":n,"icon-spin":n})})," ",c.partialRefund);return i?u:r.a.createElement("div",{className:"input-group-btn"},u)}var j=t(127);function _(e,n,t,a,r,l,o){try{var c=e[l](o),i=c.value}catch(e){return void t(e)}c.done?n(i):Promise.resolve(i).then(a,r)}function F(e){return function(){var n=this,t=arguments;return new Promise((function(a,r){var l=e.apply(n,t);function o(e){_(l,a,r,o,c,"next",e)}function c(e){_(l,a,r,o,c,"throw",e)}o(void 0)}))}}function S(e,n){return function(e){if(Array.isArray(e))return e}(e)||function(e,n){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var t=[],a=!0,r=!1,l=void 0;try{for(var o,c=e[Symbol.iterator]();!(a=(o=c.next()).done)&&(t.push(o.value),!n||t.length!==n);a=!0);}catch(e){r=!0,l=e}finally{try{a||null==c.return||c.return()}finally{if(r)throw l}}return t}(e,n)||function(e,n){if(!e)return;if("string"==typeof e)return R(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);"Object"===t&&e.constructor&&(t=e.constructor.name);if("Map"===t||"Set"===t)return Array.from(t);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return R(e,n)}(e,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function R(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,a=new Array(n);t0&&void 0!==f[0]&&f[0])){e.next=6;break}if(n=parseFloat(m.replace(/[^0-9.,]/g,"").replace(",",".")),!isNaN(n)){e.next=6;break}return t.e("vendors~sweetalert").then(t.t.bind(null,105,7)).then((function(e){(0,e.default)({icon:"error",title:p.invalidAmount,text:p.notAValidAmount}).then()})),e.abrupt("return",!1);case 6:return e.next=8,t.e("vendors~sweetalert").then(t.t.bind(null,105,7));case 8:return a=e.sent,r=a.default,e.next=12,r({dangerMode:!0,icon:"warning",title:E()(p.areYouSure),text:E()(p.areYouSureYouWantToRefund),buttons:{cancel:{text:E()(p.cancel),visible:!0},confirm:{text:E()(p.refund)}}});case 12:if(!e.sent){e.next=32;break}return e.prev=14,c(!0),e.next=18,Object(j.refundPayment)(g,n);case 18:l=e.sent,o=l.success,i=void 0!==o&&o,u=l.payment,s=void 0===u?null:u,i?s&&(h(Object(w.updateWarning)("refunded")),h(Object(w.updatePayment)(s)),d("")):r({icon:"error",title:p.refundFailed,text:p.unableToRefund}).then(),e.next=29;break;case 26:e.prev=26,e.t0=e.catch(14),console.error(e.t0);case 29:return e.prev=29,c(!1),e.finish(29);case 32:case"end":return e.stop()}}),e,null,[[14,26,29,32]])})))).apply(this,arguments)}return v?r.a.createElement(r.a.Fragment,null,r.a.createElement("h3",null,p.refund),r.a.createElement("span",null,r.a.createElement(N,{refundPayment:x,loading:o,disabled:parseFloat(y.settlementAmount.value)<=parseFloat(y.amountRefunded.value)}),r.a.createElement("span",null,p.remaining,":"),r.a.createElement("input",{type:"text",placeholder:Object(s.a)(parseFloat(y.amountRemaining.value),Object(u.get)(b,y.amountRemaining.currency)),disabled:o,value:m,onChange:function(e){var n=e.target.value;return d(n)},style:{width:"80px",height:"15px",margin:"-2px 4px 0 4px"}}),r.a.createElement(O,{refundPayment:x,loading:o,disabled:parseFloat(y.amountRemaining.value)<=0}))):(e=y.settlementAmount?r.a.createElement(N,{refundPayment:x,loading:o,disabled:parseFloat(y.settlementAmount.value)<=parseFloat(y.amountRefunded.value)}):"",r.a.createElement(r.a.Fragment,null,r.a.createElement("h4",null,p.refund),r.a.createElement("div",{className:"well well-sm"},r.a.createElement("div",{className:"form-inline"},r.a.createElement("div",{className:"form-group"},e),r.a.createElement("div",{className:"form-group"},r.a.createElement("div",{className:"input-group",style:{minWidth:"100px"}},r.a.createElement("div",{className:"input-group-addon"},p.remaining,":"),r.a.createElement("input",{type:"text",className:"form-control",placeholder:Object(s.a)(parseFloat(y.amountRemaining.value),Object(u.get)(b,y.amountRemaining.currency)),disabled:o,value:m,onChange:function(e){var n=e.target.value;return d(n)},style:{width:"80px"}}),r.a.createElement(O,{refundPayment:x,loading:o,disabled:parseFloat(y.amountRemaining.value)<=0})))))))}function A(){var e=function(e,n){n||(n=e.slice(0));return Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(n)}}))}(["\n@media only screen and (min-width: 992px) {\n margin-left: 5px!important;\n margin-right: -5px!important;\n}\n"]);return A=function(){return e},e}var C=o.default.div(A());function k(){var e=Object(l.c)((function(e){return{payment:e.payment,translations:e.translations,config:e.config}})),n=e.translations,t=e.config.legacy,a=e.payment;return t?r.a.createElement(r.a.Fragment,null,r.a.createElement("h3",null,n.refunds),a.amountRefunded&&r.a.createElement(v,null),a.amountRefunded&&r.a.createElement(P,null),!a.amountRefunded&&r.a.createElement("div",{className:"warn"},n.refundsAreCurrentlyUnavailable)):r.a.createElement(C,{className:"col-md-6 panel"},r.a.createElement("div",{className:"panel-heading"},n.refunds),a.amountRefunded&&r.a.createElement(v,null),a.amountRefunded&&r.a.createElement(P,null),!a.amountRefunded&&r.a.createElement("div",{className:"alert alert-warning"},n.refundsAreCurrentlyUnavailable))}var I=t(88),D=t(129);function Y(){var e=Object(l.c)((function(e){return{config:e.config,payment:e.payment}})),n=e.payment,t=e.config;if(Object.keys(t).length<=0)return null;var a=t.moduleDir;return t.legacy?r.a.createElement("fieldset",{style:{marginTop:"14px"}},r.a.createElement("legend",{className:"panel-heading"},r.a.createElement("img",{src:"".concat(a,"views/img/logo_small.png"),width:"32",height:"32",alt:"",style:{height:"16px",width:"16px",opacity:.8}}),r.a.createElement("span",null,"Mollie")," "),r.a.createElement(D.a,null),!n&&r.a.createElement(I.a,null),!!n&&n.status&&r.a.createElement(r.a.Fragment,null,r.a.createElement(p,null),r.a.createElement(k,null))):r.a.createElement("div",{className:"panel"},r.a.createElement("div",{className:"panel-heading"},r.a.createElement("img",{src:"".concat(a,"views/img/mollie_panel_icon.png"),width:"32",height:"32",alt:"",style:{height:"16px",width:"16px",opacity:.8}})," ",r.a.createElement("span",null,"Mollie")," "),r.a.createElement(D.a,null),!n&&r.a.createElement(I.a,null),!!n&&n.status&&r.a.createElement("div",{className:"panel-body row"},r.a.createElement(p,null),r.a.createElement(k,null)))}},91:function(e,n,t){"use strict";t.d(n,"a",(function(){return s}));t(66),t(67),t(149),t(109),t(75);var a=t(150),r=t.n(a),l=t(63);function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var c=function(e,n,t,a){"string"==typeof n&&(n=parseInt(n,10)),"string"==typeof e&&(e=parseFloat(e));for(var r=(e=e.toFixed(n))+"",l=r.split("."),o=2===l.length?l[0]:r,c=("0."+(2===l.length?l[1]:0)).substr(2),i=o.length,u=1;u<4;u++)parseFloat(e)>=Math.pow(10,3*u)&&(o=o.substring(0,i-3*u)+t+o.substring(i-3*u));return 0===n?o:o+a+(c||"00")};function i(e,n){var t;return e>=0?(t=Math.floor(e+.5),(3===n&&e===-.5+t||4===n&&e===.5+2*Math.floor(t/2)||5===n&&e===.5+2*Math.floor(t/2)-1)&&(t-=1)):(t=Math.ceil(e-.5),(3===n&&e===.5+t||4===n&&e===2*Math.ceil(t/2)-.5||5===n&&e===2*Math.ceil(t/2)-.5+1)&&(t+=1)),t}var u=function(e,n){var t,a;if("string"==typeof e&&(e=parseFloat(e)),void 0===n&&(n=2),0===(t=void 0===window.roundMode?2:window.roundMode))return function(e,n){void 0===n&&(n=0);var t=0===n?1:Math.pow(10,n),a=String(e*t);return"0"===a[a.length-1]?e:Math.ceil(e*t)/t}(e,n);if(1===t)return function(e,n){void 0===n&&(n=0);var t=0===n?1:Math.pow(10,n),a=String(e*t);return"0"===a[a.length-1]?e:Math.floor(e*t)/t}(e,n);if(2===t)return function(e,n){var t=Math.pow(10,n),a=e*t;return(a=Math.floor(10*a)-10*Math.floor(a)>=5?Math.ceil(a):Math.floor(a))/t}(e,n);if(3==t||4==t||5==t){var r=14-Math.floor(function(e){return Math.log(e)/Math.LN10}(Math.abs(e))),l=Math.pow(10,Math.abs(n));if(r>n&&r-n<15){var o=Math.pow(10,Math.abs(r));a=i(a=r>=0?e*o:e/o,t),a/=o=Math.pow(10,Math.abs(n-r))}else if(a=n>=0?e*l:e/l,Math.abs(a)>=1e15)return e;return a=i(a,t),n>0?a/=l:a*=l,a}},s=function(e,n){return void 0===n?(console.error("Currency undefined"),""):"string"==typeof window._PS_VERSION_&&r()(window._PS_VERSION_,"1.7.0.0",">=")||void 0!==window.formatCurrencyCldr?new Intl.NumberFormat(Object(l.get)(document.documentElement,"lang"),{style:"currency",currency:n.iso_code}).format(e):function(e,n,t,a){"string"==typeof e&&(e=parseFloat(e));var r,l="EUR";void 0!==window.currency_iso_code&&3===window.currency_iso_code.length?l=window.currency_iso_code:"object"===o(window.currency)&&void 0!==window.currency.iso_code&&3===window.currency.iso_code.length&&(l=window.currency.iso_code),void 0!==window.priceDisplayPrecision&&(r=window.priceDisplayPrecision);try{if(void 0!==window.currencyModes&&void 0!==window.currencyModes[l]&&window.currencyModes[l]){e=u(e.toFixed(10),r);var i=document.documentElement.lang;5===i.length?i=i.substring(0,2).toLowerCase()+"-"+i.substring(3,5).toUpperCase():void 0!==window.full_language_code&&5===window.full_language_code.length?i=window.full_language_code.substring(0,2).toLowerCase()+"-"+window.full_language_code.substring(3,5).toUpperCase():5===window.getBrowserLocale().length&&(i=window.getBrowserLocale().substring(0,2).toLowerCase()+"-"+window.getBrowserLocale().substring(3,5).toUpperCase());var s=e.toLocaleString(i,{style:"currency",currency:"USD",currencyDisplay:"code"});return t&&(s=s.replace("USD",t)),s}}catch(e){}var m="";return e=u(e.toFixed(10),r),void 0!==a&&a&&(m=" "),1==n?t+m+c(e,r,",","."):2==n?c(e,r," ",",")+m+t:3==n?t+m+c(e,r,".",","):4==n?c(e,r,",",".")+m+t:5==n?t+m+c(e,r,"'","."):String(e)}(e,n.format,n.sign,n.blank)}}},0,["vendors~sweetalert"]]); \ No newline at end of file diff --git a/views/js/dist/updater.min.js b/views/js/dist/updater.min.js index 08b271dfb..4a56c6b9d 100644 --- a/views/js/dist/updater.min.js +++ b/views/js/dist/updater.min.js @@ -1,33 +1,33 @@ -/*! - * Copyright (c) 2012-2020, Mollie B.V. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * - Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH - * DAMAGE. - * - * @author Mollie B.V. - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ (window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["updater"],{55:function(e,t,n){"use strict";n.r(t);n(69),n(65),n(70),n(71),n(66),n(67),n(23),n(61),n(68),n(22),n(72),n(24);var r=n(90),o=n.n(r),a=n(63),c=n(79);function u(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"==typeof Symbol||!(Symbol.iterator in Object(e)))return;var n=[],r=!0,o=!1,a=void 0;try{for(var c,u=e[Symbol.iterator]();!(r=(c=u.next()).done)&&(n.push(c.value),!t||n.length!==t);r=!0);}catch(e){o=!0,a=e}finally{try{r||null==u.return||u.return()}finally{if(o)throw a}}return n}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return i(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return i(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ (window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["vendors~app"],[function(t,n){var r=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=r)},function(t,n,r){var e=r(18)("wks"),o=r(16),i=r(0).Symbol,c="function"==typeof i;(t.exports=function(t){return e[t]||(e[t]=c&&i[t]||(c?i:o)("Symbol."+t))}).store=e},function(t,n,r){var e=r(3);t.exports=function(t){if(!e(t))throw TypeError(t+" is not an object!");return t}},function(t,n){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,n){var r=t.exports={version:"2.6.11"};"number"==typeof __e&&(__e=r)},function(t,n,r){t.exports=!r(12)((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a}))},function(t,n,r){var e=r(7);t.exports=function(t,n,r){if(e(t),void 0===n)return t;switch(r){case 1:return function(r){return t.call(n,r)};case 2:return function(r,e){return t.call(n,r,e)};case 3:return function(r,e,o){return t.call(n,r,e,o)}}return function(){return t.apply(n,arguments)}}},function(t,n){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,n,r){var e=r(2),o=r(32),i=r(30),c=Object.defineProperty;n.f=r(5)?Object.defineProperty:function(t,n,r){if(e(t),n=i(n,!0),e(r),o)try{return c(t,n,r)}catch(t){}if("get"in r||"set"in r)throw TypeError("Accessors not supported!");return"value"in r&&(t[n]=r.value),t}},function(t,n,r){var e=r(0),o=r(13),i=r(14),c=r(16)("src"),u=r(40),a=(""+u).split("toString");r(4).inspectSource=function(t){return u.call(t)},(t.exports=function(t,n,r,u){var f="function"==typeof r;f&&(i(r,"name")||o(r,"name",n)),t[n]!==r&&(f&&(i(r,c)||o(r,c,t[n]?""+t[n]:a.join(String(n)))),t===e?t[n]=r:u?t[n]?t[n]=r:o(t,n,r):(delete t[n],o(t,n,r)))})(Function.prototype,"toString",(function(){return"function"==typeof this&&this[c]||u.call(this)}))},function(t,n){var r={}.toString;t.exports=function(t){return r.call(t).slice(8,-1)}},function(t,n,r){var e=r(10),o=r(1)("toStringTag"),i="Arguments"==e(function(){return arguments}());t.exports=function(t){var n,r,c;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(r=function(t,n){try{return t[n]}catch(t){}}(n=Object(t),o))?r:i?e(n):"Object"==(c=e(n))&&"function"==typeof n.callee?"Arguments":c}},function(t,n){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,n,r){var e=r(8),o=r(27);t.exports=r(5)?function(t,n,r){return e.f(t,n,o(1,r))}:function(t,n,r){return t[n]=r,t}},function(t,n){var r={}.hasOwnProperty;t.exports=function(t,n){return r.call(t,n)}},function(t,n){t.exports=!1},function(t,n){var r=0,e=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++r+e).toString(36))}},function(t,n){t.exports={}},function(t,n,r){var e=r(4),o=r(0),i=o["__core-js_shared__"]||(o["__core-js_shared__"]={});(t.exports=function(t,n){return i[t]||(i[t]=void 0!==n?n:{})})("versions",[]).push({version:e.version,mode:r(15)?"pure":"global",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})},function(t,n,r){var e=r(3),o=r(0).document,i=e(o)&&e(o.createElement);t.exports=function(t){return i?o.createElement(t):{}}},function(t,n,r){var e,o,i,c=r(6),u=r(43),a=r(36),f=r(19),s=r(0),l=s.process,h=s.setImmediate,p=s.clearImmediate,v=s.MessageChannel,d=s.Dispatch,y=0,m={},g=function(){var t=+this;if(m.hasOwnProperty(t)){var n=m[t];delete m[t],n()}},w=function(t){g.call(t.data)};h&&p||(h=function(t){for(var n=[],r=1;arguments.length>r;)n.push(arguments[r++]);return m[++y]=function(){u("function"==typeof t?t:Function(t),n)},e(y),y},p=function(t){delete m[t]},"process"==r(10)(l)?e=function(t){l.nextTick(c(g,t,1))}:d&&d.now?e=function(t){d.now(c(g,t,1))}:v?(i=(o=new v).port2,o.port1.onmessage=w,e=c(i.postMessage,i,1)):s.addEventListener&&"function"==typeof postMessage&&!s.importScripts?(e=function(t){s.postMessage(t+"","*")},s.addEventListener("message",w,!1)):e="onreadystatechange"in f("script")?function(t){a.appendChild(f("script")).onreadystatechange=function(){a.removeChild(this),g.call(t)}}:function(t){setTimeout(c(g,t,1),0)}),t.exports={set:h,clear:p}},function(t,n,r){"use strict";var e=r(7);function o(t){var n,r;this.promise=new t((function(t,e){if(void 0!==n||void 0!==r)throw TypeError("Bad Promise constructor");n=t,r=e})),this.resolve=e(n),this.reject=e(r)}t.exports.f=function(t){return new o(t)}},function(t,n,r){"use strict";var e=r(11),o={};o[r(1)("toStringTag")]="z",o+""!="[object z]"&&r(9)(Object.prototype,"toString",(function(){return"[object "+e(this)+"]"}),!0)},function(t,n,r){"use strict";var e,o,i,c,u=r(15),a=r(0),f=r(6),s=r(11),l=r(25),h=r(3),p=r(7),v=r(41),d=r(42),y=r(31),m=r(20).set,g=r(44)(),w=r(21),x=r(45),_=r(46),b=r(47),j=a.TypeError,E=a.process,L=E&&E.versions,P=L&&L.v8||"",S=a.Promise,O="process"==s(E),T=function(){},k=o=w.f,F=!!function(){try{var t=S.resolve(1),n=(t.constructor={})[r(1)("species")]=function(t){t(T,T)};return(O||"function"==typeof PromiseRejectionEvent)&&t.then(T)instanceof n&&0!==P.indexOf("6.6")&&-1===_.indexOf("Chrome/66")}catch(t){}}(),M=function(t){var n;return!(!h(t)||"function"!=typeof(n=t.then))&&n},N=function(t,n){if(!t._n){t._n=!0;var r=t._c;g((function(){for(var e=t._v,o=1==t._s,i=0,c=function(n){var r,i,c,u=o?n.ok:n.fail,a=n.resolve,f=n.reject,s=n.domain;try{u?(o||(2==t._h&&R(t),t._h=1),!0===u?r=e:(s&&s.enter(),r=u(e),s&&(s.exit(),c=!0)),r===n.promise?f(j("Promise-chain cycle")):(i=M(r))?i.call(r,a,f):a(r)):f(e)}catch(t){s&&!c&&s.exit(),f(t)}};r.length>i;)c(r[i++]);t._c=[],t._n=!1,n&&!t._h&&G(t)}))}},G=function(t){m.call(a,(function(){var n,r,e,o=t._v,i=A(t);if(i&&(n=x((function(){O?E.emit("unhandledRejection",o,t):(r=a.onunhandledrejection)?r({promise:t,reason:o}):(e=a.console)&&e.error&&e.error("Unhandled promise rejection",o)})),t._h=O||A(t)?2:1),t._a=void 0,i&&n.e)throw n.v}))},A=function(t){return 1!==t._h&&0===(t._a||t._c).length},R=function(t){m.call(a,(function(){var n;O?E.emit("rejectionHandled",t):(n=a.onrejectionhandled)&&n({promise:t,reason:t._v})}))},I=function(t){var n=this;n._d||(n._d=!0,(n=n._w||n)._v=t,n._s=2,n._a||(n._a=n._c.slice()),N(n,!0))},C=function(t){var n,r=this;if(!r._d){r._d=!0,r=r._w||r;try{if(r===t)throw j("Promise can't be resolved itself");(n=M(t))?g((function(){var e={_w:r,_d:!1};try{n.call(t,f(C,e,1),f(I,e,1))}catch(t){I.call(e,t)}})):(r._v=t,r._s=1,N(r,!1))}catch(t){I.call({_w:r,_d:!1},t)}}};F||(S=function(t){v(this,S,"Promise","_h"),p(t),e.call(this);try{t(f(C,this,1),f(I,this,1))}catch(t){I.call(this,t)}},(e=function(t){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1}).prototype=r(48)(S.prototype,{then:function(t,n){var r=k(y(this,S));return r.ok="function"!=typeof t||t,r.fail="function"==typeof n&&n,r.domain=O?E.domain:void 0,this._c.push(r),this._a&&this._a.push(r),this._s&&N(this,!1),r.promise},catch:function(t){return this.then(void 0,t)}}),i=function(){var t=new e;this.promise=t,this.resolve=f(C,t,1),this.reject=f(I,t,1)},w.f=k=function(t){return t===S||t===c?new i(t):o(t)}),l(l.G+l.W+l.F*!F,{Promise:S}),r(29)(S,"Promise"),r(49)("Promise"),c=r(4).Promise,l(l.S+l.F*!F,"Promise",{reject:function(t){var n=k(this);return(0,n.reject)(t),n.promise}}),l(l.S+l.F*(u||!F),"Promise",{resolve:function(t){return b(u&&this===c?S:this,t)}}),l(l.S+l.F*!(F&&r(37)((function(t){S.all(t).catch(T)}))),"Promise",{all:function(t){var n=this,r=k(n),e=r.resolve,o=r.reject,i=x((function(){var r=[],i=0,c=1;d(t,!1,(function(t){var u=i++,a=!1;r.push(void 0),c++,n.resolve(t).then((function(t){a||(a=!0,r[u]=t,--c||e(r))}),o)})),--c||e(r)}));return i.e&&o(i.v),r.promise},race:function(t){var n=this,r=k(n),e=r.reject,o=x((function(){d(t,!1,(function(t){n.resolve(t).then(r.resolve,e)}))}));return o.e&&e(o.v),r.promise}})},function(t,n,r){var e=function(t){"use strict";var n=Object.prototype,r=n.hasOwnProperty,e="function"==typeof Symbol?Symbol:{},o=e.iterator||"@@iterator",i=e.asyncIterator||"@@asyncIterator",c=e.toStringTag||"@@toStringTag";function u(t,n,r,e){var o=n&&n.prototype instanceof s?n:s,i=Object.create(o.prototype),c=new b(e||[]);return i._invoke=function(t,n,r){var e="suspendedStart";return function(o,i){if("executing"===e)throw new Error("Generator is already running");if("completed"===e){if("throw"===o)throw i;return E()}for(r.method=o,r.arg=i;;){var c=r.delegate;if(c){var u=w(c,r);if(u){if(u===f)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===e)throw e="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);e="executing";var s=a(t,n,r);if("normal"===s.type){if(e=r.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(e="completed",r.method="throw",r.arg=s.arg)}}}(t,r,c),i}function a(t,n,r){try{return{type:"normal",arg:t.call(n,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=u;var f={};function s(){}function l(){}function h(){}var p={};p[o]=function(){return this};var v=Object.getPrototypeOf,d=v&&v(v(j([])));d&&d!==n&&r.call(d,o)&&(p=d);var y=h.prototype=s.prototype=Object.create(p);function m(t){["next","throw","return"].forEach((function(n){t[n]=function(t){return this._invoke(n,t)}}))}function g(t,n){var e;this._invoke=function(o,i){function c(){return new n((function(e,c){!function e(o,i,c,u){var f=a(t[o],t,i);if("throw"!==f.type){var s=f.arg,l=s.value;return l&&"object"==typeof l&&r.call(l,"__await")?n.resolve(l.__await).then((function(t){e("next",t,c,u)}),(function(t){e("throw",t,c,u)})):n.resolve(l).then((function(t){s.value=t,c(s)}),(function(t){return e("throw",t,c,u)}))}u(f.arg)}(o,i,e,c)}))}return e=e?e.then(c,c):c()}}function w(t,n){var r=t.iterator[n.method];if(void 0===r){if(n.delegate=null,"throw"===n.method){if(t.iterator.return&&(n.method="return",n.arg=void 0,w(t,n),"throw"===n.method))return f;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return f}var e=a(r,t.iterator,n.arg);if("throw"===e.type)return n.method="throw",n.arg=e.arg,n.delegate=null,f;var o=e.arg;return o?o.done?(n[t.resultName]=o.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=void 0),n.delegate=null,f):o:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,f)}function x(t){var n={tryLoc:t[0]};1 in t&&(n.catchLoc=t[1]),2 in t&&(n.finallyLoc=t[2],n.afterLoc=t[3]),this.tryEntries.push(n)}function _(t){var n=t.completion||{};n.type="normal",delete n.arg,t.completion=n}function b(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(x,this),this.reset(!0)}function j(t){if(t){var n=t[o];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var e=-1,i=function n(){for(;++e=0;--o){var i=this.tryEntries[o],c=i.completion;if("root"===i.tryLoc)return e("end");if(i.tryLoc<=this.prev){var u=r.call(i,"catchLoc"),a=r.call(i,"finallyLoc");if(u&&a){if(this.prev=0;--e){var o=this.tryEntries[e];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev=0;--n){var r=this.tryEntries[n];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),_(r),f}},catch:function(t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc===t){var e=r.completion;if("throw"===e.type){var o=e.arg;_(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:j(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}(t.exports);try{regeneratorRuntime=e}catch(t){Function("r","regeneratorRuntime = r")(e)}},function(t,n,r){var e=r(0),o=r(4),i=r(13),c=r(9),u=r(6),a=function(t,n,r){var f,s,l,h,p=t&a.F,v=t&a.G,d=t&a.S,y=t&a.P,m=t&a.B,g=v?e:d?e[n]||(e[n]={}):(e[n]||{}).prototype,w=v?o:o[n]||(o[n]={}),x=w.prototype||(w.prototype={});for(f in v&&(r=n),r)l=((s=!p&&g&&void 0!==g[f])?g:r)[f],h=m&&s?u(l,e):y&&"function"==typeof l?u(Function.call,l):l,g&&c(g,f,l,t&a.U),w[f]!=l&&i(w,f,h),y&&x[f]!=l&&(x[f]=l)};e.core=o,a.F=1,a.G=2,a.S=4,a.P=8,a.B=16,a.W=32,a.U=64,a.R=128,t.exports=a},function(t,n,r){var e=r(28),o=Math.min;t.exports=function(t){return t>0?o(e(t),9007199254740991):0}},function(t,n){t.exports=function(t,n){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:n}}},function(t,n){var r=Math.ceil,e=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?e:r)(t)}},function(t,n,r){var e=r(8).f,o=r(14),i=r(1)("toStringTag");t.exports=function(t,n,r){t&&!o(t=r?t:t.prototype,i)&&e(t,i,{configurable:!0,value:n})}},function(t,n,r){var e=r(3);t.exports=function(t,n){if(!e(t))return t;var r,o;if(n&&"function"==typeof(r=t.toString)&&!e(o=r.call(t)))return o;if("function"==typeof(r=t.valueOf)&&!e(o=r.call(t)))return o;if(!n&&"function"==typeof(r=t.toString)&&!e(o=r.call(t)))return o;throw TypeError("Can't convert object to primitive value")}},function(t,n,r){var e=r(2),o=r(7),i=r(1)("species");t.exports=function(t,n){var r,c=e(t).constructor;return void 0===c||null==(r=e(c)[i])?n:o(r)}},function(t,n,r){t.exports=!r(5)&&!r(12)((function(){return 7!=Object.defineProperty(r(19)("div"),"a",{get:function(){return 7}}).a}))},function(t,n,r){var e=r(2);t.exports=function(t,n,r,o){try{return o?n(e(r)[0],r[1]):n(r)}catch(n){var i=t.return;throw void 0!==i&&e(i.call(t)),n}}},function(t,n,r){var e=r(17),o=r(1)("iterator"),i=Array.prototype;t.exports=function(t){return void 0!==t&&(e.Array===t||i[o]===t)}},function(t,n,r){var e=r(11),o=r(1)("iterator"),i=r(17);t.exports=r(4).getIteratorMethod=function(t){if(null!=t)return t[o]||t["@@iterator"]||i[e(t)]}},function(t,n,r){var e=r(0).document;t.exports=e&&e.documentElement},function(t,n,r){var e=r(1)("iterator"),o=!1;try{var i=[7][e]();i.return=function(){o=!0},Array.from(i,(function(){throw 2}))}catch(t){}t.exports=function(t,n){if(!n&&!o)return!1;var r=!1;try{var i=[7],c=i[e]();c.next=function(){return{done:r=!0}},i[e]=function(){return c},t(i)}catch(t){}return r}},,,function(t,n,r){t.exports=r(18)("native-function-to-string",Function.toString)},function(t,n){t.exports=function(t,n,r,e){if(!(t instanceof n)||void 0!==e&&e in t)throw TypeError(r+": incorrect invocation!");return t}},function(t,n,r){var e=r(6),o=r(33),i=r(34),c=r(2),u=r(26),a=r(35),f={},s={};(n=t.exports=function(t,n,r,l,h){var p,v,d,y,m=h?function(){return t}:a(t),g=e(r,l,n?2:1),w=0;if("function"!=typeof m)throw TypeError(t+" is not iterable!");if(i(m)){for(p=u(t.length);p>w;w++)if((y=n?g(c(v=t[w])[0],v[1]):g(t[w]))===f||y===s)return y}else for(d=m.call(t);!(v=d.next()).done;)if((y=o(d,g,v.value,n))===f||y===s)return y}).BREAK=f,n.RETURN=s},function(t,n){t.exports=function(t,n,r){var e=void 0===r;switch(n.length){case 0:return e?t():t.call(r);case 1:return e?t(n[0]):t.call(r,n[0]);case 2:return e?t(n[0],n[1]):t.call(r,n[0],n[1]);case 3:return e?t(n[0],n[1],n[2]):t.call(r,n[0],n[1],n[2]);case 4:return e?t(n[0],n[1],n[2],n[3]):t.call(r,n[0],n[1],n[2],n[3])}return t.apply(r,n)}},function(t,n,r){var e=r(0),o=r(20).set,i=e.MutationObserver||e.WebKitMutationObserver,c=e.process,u=e.Promise,a="process"==r(10)(c);t.exports=function(){var t,n,r,f=function(){var e,o;for(a&&(e=c.domain)&&e.exit();t;){o=t.fn,t=t.next;try{o()}catch(e){throw t?r():n=void 0,e}}n=void 0,e&&e.enter()};if(a)r=function(){c.nextTick(f)};else if(!i||e.navigator&&e.navigator.standalone)if(u&&u.resolve){var s=u.resolve(void 0);r=function(){s.then(f)}}else r=function(){o.call(e,f)};else{var l=!0,h=document.createTextNode("");new i(f).observe(h,{characterData:!0}),r=function(){h.data=l=!l}}return function(e){var o={fn:e,next:void 0};n&&(n.next=o),t||(t=o,r()),n=o}}},function(t,n){t.exports=function(t){try{return{e:!1,v:t()}}catch(t){return{e:!0,v:t}}}},function(t,n,r){var e=r(0).navigator;t.exports=e&&e.userAgent||""},function(t,n,r){var e=r(2),o=r(3),i=r(21);t.exports=function(t,n){if(e(t),o(n)&&n.constructor===t)return n;var r=i.f(t);return(0,r.resolve)(n),r.promise}},function(t,n,r){var e=r(9);t.exports=function(t,n,r){for(var o in n)e(t,o,n[o],r);return t}},function(t,n,r){"use strict";var e=r(0),o=r(8),i=r(5),c=r(1)("species");t.exports=function(t){var n=e[t];i&&n&&!n[c]&&o.f(n,c,{configurable:!0,get:function(){return this}})}}]]); \ No newline at end of file diff --git a/views/js/dist/vendors~banks~carrierconfig~methodconfig~qrcode~transaction.min.js b/views/js/dist/vendors~banks~carrierconfig~methodconfig~qrcode~transaction.min.js index f340e6d94..2a8a1d3fa 100644 --- a/views/js/dist/vendors~banks~carrierconfig~methodconfig~qrcode~transaction.min.js +++ b/views/js/dist/vendors~banks~carrierconfig~methodconfig~qrcode~transaction.min.js @@ -1,33 +1,33 @@ -/*! - * Copyright (c) 2012-2020, Mollie B.V. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions are met: - * - * - Redistributions of source code must retain the above copyright notice, - * this list of conditions and the following disclaimer. - * - Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY - * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED - * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY - * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES - * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH - * DAMAGE. - * - * @author Mollie B.V. - * @copyright Mollie B.V. - * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php - * @category Mollie - * @package Mollie - * @link https://www.mollie.nl - */ +/*! + * Copyright (c) 2012-2020, Mollie B.V. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * - Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * - Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY + * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES + * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH + * DAMAGE. + * + * @author Mollie B.V. + * @copyright Mollie B.V. + * @license Berkeley Software Distribution License (BSD-License 2) http://www.opensource.org/licenses/bsd-license.php + * @category Mollie + * @package Mollie + * @link https://www.mollie.nl + */ (window.webpackJsonP_mollie=window.webpackJsonP_mollie||[]).push([["vendors~banks~carrierconfig~methodconfig~qrcode~transaction"],{135:function(e,t,n){"use strict";var r=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function a(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,o,u=a(e),c=1;cz.length&&z.push(e)}function R(e,t,n){return null==e?0:function e(t,n,r,l){var o=typeof t;"undefined"!==o&&"boolean"!==o||(t=null);var u=!1;if(null===t)u=!0;else switch(o){case"string":case"number":u=!0;break;case"object":switch(t.$$typeof){case i:case a:u=!0}}if(u)return r(l,t,""===n?"."+I(t,0):n),1;if(u=0,n=""===n?".":n+":",Array.isArray(t))for(var c=0;c